/* =============================================================================
   OPERATION REBOOT - Main Stylesheet
   
   Clean dark theme for the operation-reboot.
   Based on Hochschule München colors (HM Red)
   ============================================================================= */

/* -----------------------------------------------------------------------------
   CSS Variables
   ----------------------------------------------------------------------------- */
:root {
    /* HM Brand Colors */
    --color-hm-red: #e63946;
    --color-hm-red-light: #ff6b6b;
    --color-hm-red-dark: #c1121f;
    
    /* Background Colors */
    --color-bg-dark: #1a1a2e;
    --color-bg-darker: #12121f;
    --color-bg-card: #252542;
    --color-bg-card-hover: #2f2f52;
    --color-bg-input: #1e1e35;
    
    /* Text Colors - HIGH CONTRAST for readability */
    --color-text: #f8f9fa;
    --color-text-bright: #ffffff;
    --color-text-muted: #a8a8c0;
    --color-text-on-primary: #ffffff;
    
    /* Accent Colors */
    --color-primary: #e63946;
    --color-secondary: #4cc9f0;
    --color-success: #06d6a0;
    --color-warning: #ffd166;
    --color-danger: #ef476f;
    --color-info: #118ab2;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #e63946 0%, #ff6b6b 100%);
    --gradient-card: linear-gradient(160deg, #252542 0%, #1e1e35 100%);
    
    /* Shadows */
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.3);
    --shadow-button: 0 2px 10px rgba(230, 57, 70, 0.3);
    
    /* Fonts - Clean, readable fonts */
    --font-main: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'SF Mono', 'Fira Code', Consolas, monospace;
    
    /* Spacing */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
}

/* -----------------------------------------------------------------------------
   Base Styles
   ----------------------------------------------------------------------------- */
* {
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--color-bg-darker);
    color: var(--color-text);
    min-height: 100vh;
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

/* Subtle background gradient */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at 20% 0%, rgba(230, 57, 70, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(76, 201, 240, 0.05) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* -----------------------------------------------------------------------------
   Typography - Clean and readable, NO UPPERCASE
   ----------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-main);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--color-text-bright);
}

h1 { font-size: 2rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }

p {
    color: var(--color-text);
    margin-bottom: 1rem;
}

a {
    color: var(--color-secondary);
    text-decoration: none;
}

a:hover {
    color: var(--color-text-bright);
    text-decoration: underline;
}

.text-primary { color: var(--color-primary) !important; }
.text-success { color: var(--color-success) !important; }
.text-warning { color: var(--color-warning) !important; }
.text-danger { color: var(--color-danger) !important; }
.text-muted { color: var(--color-text-muted) !important; }
.text-bright { color: var(--color-text-bright) !important; }

/* -----------------------------------------------------------------------------
   Flash Messages
   ----------------------------------------------------------------------------- */
.flash-container {
    position: fixed;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    width: 90%;
    max-width: 500px;
}

.flash-container .alert {
    border: none;
    border-radius: var(--radius-md);
    color: var(--color-text-bright);
    animation: slideDown 0.3s ease-out;
}

.flash-container .alert-success {
    background: rgba(6, 214, 160, 0.9);
    color: #000;
}

.flash-container .alert-danger {
    background: rgba(239, 71, 111, 0.9);
}

.flash-container .alert-warning {
    background: rgba(255, 209, 102, 0.9);
    color: #000;
}

.flash-container .alert-info {
    background: rgba(76, 201, 240, 0.9);
    color: #000;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* -----------------------------------------------------------------------------
   Cards - Dark with good contrast
   ----------------------------------------------------------------------------- */
.card {
    background: var(--gradient-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    color: var(--color-text);
}

.card-header {
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--color-text-bright);
    font-weight: 600;
    padding: 1rem 1.25rem;
}

.card-body {
    padding: 1.25rem;
}

.card-title {
    color: var(--color-text-bright);
    margin-bottom: 0.75rem;
}

/* -----------------------------------------------------------------------------
   Buttons - Consistent dark theme, NO UPPERCASE
   ----------------------------------------------------------------------------- */
.btn {
    font-family: var(--font-main);
    font-weight: 500;
    font-size: 1rem;
    border-radius: var(--radius-md);
    padding: 0.65rem 1.25rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

/* Primary Button - HM Red */
.btn-primary {
    background: var(--color-primary);
    color: var(--color-text-on-primary);
    box-shadow: var(--shadow-button);
}

.btn-primary:hover,
.btn-primary:focus {
    background: var(--color-hm-red-light);
    color: var(--color-text-on-primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(230, 57, 70, 0.4);
}

/* Success Button */
.btn-success {
    background: var(--color-success);
    color: #000;
}

.btn-success:hover,
.btn-success:focus {
    background: #05c795;
    color: #000;
}

/* Secondary/Outline Buttons - Dark themed */
.btn-secondary {
    background: var(--color-bg-card);
    color: var(--color-text);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-secondary:hover,
.btn-secondary:focus {
    background: var(--color-bg-card-hover);
    color: var(--color-text-bright);
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-outline-primary {
    background: transparent;
    color: var(--color-primary);
    border: 2px solid var(--color-primary);
}

.btn-outline-primary:hover {
    background: var(--color-primary);
    color: var(--color-text-on-primary);
}

.btn-outline-light {
    background: transparent;
    color: var(--color-text);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-text-bright);
    border-color: rgba(255, 255, 255, 0.3);
}

.btn-outline-secondary {
    background: transparent;
    color: var(--color-text-muted);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-outline-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--color-text);
}

.btn-danger {
    background: var(--color-danger);
    color: white;
}

.btn-danger:hover {
    background: #d63d5c;
    color: white;
}

.btn-warning {
    background: var(--color-warning);
    color: #000;
}

.btn-warning:hover {
    background: #ebc35a;
    color: #000;
}

.btn-info {
    background: var(--color-info);
    color: white;
}

.btn-info:hover {
    background: #0e7aa3;
    color: white;
}

.btn-link {
    background: none;
    color: var(--color-text-muted);
    padding: 0.5rem;
}

.btn-link:hover {
    color: var(--color-text-bright);
    text-decoration: none;
}

.btn-lg {
    padding: 0.85rem 1.75rem;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.875rem;
}

/* Action Button - Full width */
.btn-action {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
}

/* -----------------------------------------------------------------------------
   Forms - Dark inputs with good contrast
   ----------------------------------------------------------------------------- */
.form-control {
    background: var(--color-bg-input);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    color: var(--color-text-bright);
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.form-control:focus {
    background: var(--color-bg-input);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.15);
    color: var(--color-text-bright);
    outline: none;
}

.form-control::placeholder {
    color: var(--color-text-muted);
}

.form-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-text);
    margin-bottom: 0.5rem;
}

.form-text {
    color: var(--color-text-muted);
    font-size: 0.85rem;
}

.form-select {
    background-color: var(--color-bg-input);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    color: var(--color-text-bright);
    padding: 0.75rem 1rem;
}

.form-select:focus {
    background-color: var(--color-bg-input);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.15);
    color: var(--color-text-bright);
}

.form-check-input {
    background-color: var(--color-bg-input);
    border-color: rgba(255, 255, 255, 0.2);
}

.form-check-input:checked {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
}

.form-check-label {
    color: var(--color-text);
}

/* Disabled and readonly inputs - Dark themed */
.form-control:disabled,
.form-control[readonly] {
    background: var(--color-bg-darker);
    border-color: rgba(255, 255, 255, 0.05);
    color: var(--color-text-muted);
    opacity: 1;
    cursor: not-allowed;
}

.form-control:disabled::placeholder,
.form-control[readonly]::placeholder {
    color: var(--color-text-muted);
}

/* Input group dark theme fix */
.input-group .form-control:disabled,
.input-group .form-control[readonly] {
    background: var(--color-bg-darker);
    color: var(--color-text-muted);
}

/* Radio buttons as answer cards */
.answer-option {
    position: relative;
    margin-bottom: 0.75rem;
}

.answer-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.answer-option label {
    display: block;
    background: var(--color-bg-card);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: 1rem 1.25rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 1rem;
    color: var(--color-text);
}

.answer-option label:hover {
    background: var(--color-bg-card-hover);
    border-color: rgba(255, 255, 255, 0.2);
}

.answer-option input[type="radio"]:checked + label {
    background: rgba(230, 57, 70, 0.15);
    border-color: var(--color-primary);
    color: var(--color-text-bright);
}

.answer-option input[type="radio"]:checked + label::after {
    content: '✓';
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-primary);
    font-weight: bold;
}

/* -----------------------------------------------------------------------------
   Progress Bar
   ----------------------------------------------------------------------------- */
.progress {
    height: 1.25rem;
    background: var(--color-bg-card);
    border-radius: var(--radius-lg);
    overflow: visible;
    position: relative;
}

.progress-bar {
    background: linear-gradient(90deg, var(--color-success) 0%, #4cc9f0 100%);
    border-radius: var(--radius-lg);
    transition: width 0.5s ease;
}

.progress-label {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-text-bright);
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
    z-index: 1;
}

/* -----------------------------------------------------------------------------
   Game Logo - HM Logo Image
   ----------------------------------------------------------------------------- */
.game-logo {
    align-items: center;
    justify-content: center;
}

.game-logo-img {
    flex-shrink: 0;
}

.game-logo-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-text-bright);
    letter-spacing: -0.3px;
}

/* Large logo for login/intro */
.game-logo-large {
    flex-direction: column;
}

.game-logo-large .game-logo-text {
    font-size: 1.6rem;
}

/* -----------------------------------------------------------------------------
   Game Container & Layout
   ----------------------------------------------------------------------------- */
.game-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 1rem;
    max-width: 600px;
    margin: 0 auto;
}

.game-header {
    text-align: center;
    padding: 1rem 0;
    margin-bottom: 1rem;
}

.game-header .text-muted {
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

/* Question card */
.question-card {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.question-number {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin-bottom: 0.5rem;
}

.question-text {
    font-size: 1.2rem;
    font-weight: 500;
    line-height: 1.5;
    margin-bottom: 1.5rem;
    color: var(--color-text-bright);
}

.hint {
    background: rgba(76, 201, 240, 0.1);
    border-left: 3px solid var(--color-secondary);
    padding: 0.75rem 1rem;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    color: var(--color-text);
}

.hint i {
    color: var(--color-secondary);
}

.answers-container {
    margin-bottom: 1.5rem;
}

.skip-info {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.85rem;
    color: var(--color-text-muted);
}

/* Success toast */
.success-toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--color-success);
    color: #000;
    padding: 1rem 2rem;
    border-radius: var(--radius-lg);
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(6, 214, 160, 0.4);
    animation: toastIn 0.3s ease-out, toastOut 0.3s ease-in 2s forwards;
    z-index: 1000;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translate(-50%, 20px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

@keyframes toastOut {
    to {
        opacity: 0;
        transform: translate(-50%, 20px);
    }
}

/* -----------------------------------------------------------------------------
   Victory Screen
   ----------------------------------------------------------------------------- */
.victory-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
}

.victory-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: bounce 1s ease infinite;
}

@keyframes bounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.reward-code {
    background: var(--color-bg-card);
    border: 2px solid var(--color-success);
    border-radius: var(--radius-lg);
    padding: 1.25rem 2rem;
    margin: 1.5rem 0;
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-success);
    letter-spacing: 2px;
}

/* Treasure chest animation */
.chest-container {
    position: relative;
    width: 180px;
    height: 180px;
    margin: 2rem auto;
}

.chest-body {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 60%;
    background: linear-gradient(145deg, #8B4513 0%, #654321 100%);
    border-radius: 8px;
    border: 3px solid #5D3A1A;
}

.chest-lid {
    position: absolute;
    bottom: 55%;
    width: 100%;
    height: 45%;
    background: linear-gradient(145deg, #A0522D 0%, #8B4513 100%);
    border-radius: 16px 16px 0 0;
    border: 3px solid #5D3A1A;
    transform-origin: bottom center;
    animation: openChest 1s ease forwards;
    animation-delay: 0.5s;
}

@keyframes openChest {
    from { transform: rotateX(0deg); }
    to { transform: rotateX(-110deg); }
}

.chest-glow {
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 60%;
    background: radial-gradient(ellipse, var(--color-success) 0%, transparent 70%);
    opacity: 0;
    animation: glowIn 0.5s ease forwards;
    animation-delay: 1s;
}

@keyframes glowIn {
    to { opacity: 0.6; }
}

/* -----------------------------------------------------------------------------
   Login Page
   ----------------------------------------------------------------------------- */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.login-card {
    width: 100%;
    max-width: 400px;
}

.login-logo {
    text-align: center;
    margin-bottom: 2rem;
}

.login-logo h1 {
    font-size: 1.5rem;
    color: var(--color-text-bright);
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.login-logo p {
    color: var(--color-text-muted);
    font-size: 0.95rem;
    margin: 0;
}

/* -----------------------------------------------------------------------------
   Admin Layout
   ----------------------------------------------------------------------------- */
.admin-container {
    min-height: 100vh;
    background: var(--color-bg-darker);
}

.admin-sidebar {
    background: var(--color-bg-dark);
    min-height: 100vh;
    padding: 1.5rem;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-nav .nav-link {
    color: var(--color-text-muted);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 0.25rem;
    transition: all 0.2s ease;
}

.admin-nav .nav-link:hover {
    color: var(--color-text-bright);
    background: rgba(255, 255, 255, 0.05);
}

.admin-nav .nav-link.active {
    color: var(--color-primary);
    background: rgba(230, 57, 70, 0.1);
    border-left: 3px solid var(--color-primary);
    margin-left: -3px;
}

.admin-nav .nav-link i {
    width: 24px;
    margin-right: 0.5rem;
}

.admin-content {
    padding: 2rem;
}

.admin-header {
    margin-bottom: 2rem;
}

.admin-header h1 {
    color: var(--color-text-bright);
    margin-bottom: 0.5rem;
}

/* Stat cards */
.stat-card {
    background: var(--gradient-card);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.stat-card .stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1;
}

.stat-card .stat-label {
    color: var(--color-text-muted);
    font-size: 0.85rem;
    margin-top: 0.5rem;
}

/* -----------------------------------------------------------------------------
   Tables - Dark themed (Override Bootstrap defaults)
   ----------------------------------------------------------------------------- */
.table {
    --bs-table-bg: transparent;
    --bs-table-color: var(--color-text);
    --bs-table-border-color: rgba(255, 255, 255, 0.08);
    --bs-table-striped-bg: rgba(255, 255, 255, 0.03);
    --bs-table-striped-color: var(--color-text);
    --bs-table-active-bg: rgba(255, 255, 255, 0.05);
    --bs-table-active-color: var(--color-text);
    --bs-table-hover-bg: rgba(255, 255, 255, 0.05);
    --bs-table-hover-color: var(--color-text-bright);
    color: var(--color-text);
    margin-bottom: 0;
    background-color: transparent;
}

.table > :not(caption) > * > * {
    background-color: transparent;
    color: var(--color-text);
}

.table thead {
    background: rgba(255, 255, 255, 0.03);
}

.table thead th {
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    border-top: none;
    color: var(--color-text-muted);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 1rem;
}

.table tbody tr {
    background-color: transparent;
}

.table tbody td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    border-top: none;
    color: var(--color-text);
    vertical-align: middle;
    background-color: transparent;
}

.table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.03) !important;
}

.table tbody tr:hover td {
    color: var(--color-text-bright);
}

.table-hover > tbody > tr:hover > * {
    --bs-table-bg-state: rgba(255, 255, 255, 0.03);
    --bs-table-accent-bg: rgba(255, 255, 255, 0.03);
    background-color: rgba(255, 255, 255, 0.03);
    color: var(--color-text-bright);
}

/* Ensure table-responsive container is transparent */
.table-responsive {
    background-color: transparent;
}

.table-dark,
.table-striped,
.table-bordered {
    --bs-table-bg: transparent;
    --bs-table-color: var(--color-text);
}

/* -----------------------------------------------------------------------------
   Badges
   ----------------------------------------------------------------------------- */
.badge {
    font-weight: 500;
    padding: 0.4rem 0.7rem;
    font-size: 0.8rem;
    border-radius: var(--radius-sm);
}

.badge-status-not_started {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-text-muted);
}

.badge-status-in_progress {
    background: rgba(76, 201, 240, 0.2);
    color: var(--color-secondary);
}

.badge-status-completed {
    background: rgba(6, 214, 160, 0.2);
    color: var(--color-success);
}

.bg-primary { background-color: var(--color-primary) !important; }
.bg-success { background-color: var(--color-success) !important; color: #000 !important; }
.bg-warning { background-color: var(--color-warning) !important; color: #000 !important; }
.bg-danger { background-color: var(--color-danger) !important; }
.bg-secondary { background-color: var(--color-bg-card) !important; }

/* -----------------------------------------------------------------------------
   QR Code Pages
   ----------------------------------------------------------------------------- */
.qr-result {
    text-align: center;
    padding: 2rem;
}

.qr-result-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.qr-result-content {
    background: var(--color-bg-card);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin: 1.5rem 0;
    font-size: 1.1rem;
    line-height: 1.6;
    white-space: pre-line;
    color: var(--color-text);
}

/* -----------------------------------------------------------------------------
   Modal overrides for dark theme
   ----------------------------------------------------------------------------- */
.modal-content {
    background: var(--color-bg-dark);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--color-text);
}

.modal-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.modal-header .modal-title {
    color: var(--color-text-bright);
}

.modal-header .btn-close {
    filter: invert(1);
}

.modal-footer {
    border-top-color: rgba(255, 255, 255, 0.1);
}

/* -----------------------------------------------------------------------------
   Dropdown Menu - Dark theme
   ----------------------------------------------------------------------------- */
.dropdown-menu {
    background: var(--color-bg-dark);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    padding: 0.5rem 0;
}

.dropdown-menu .dropdown-item {
    color: var(--color-text);
    padding: 0.6rem 1rem;
    transition: all 0.15s ease;
}

.dropdown-menu .dropdown-item:hover,
.dropdown-menu .dropdown-item:focus {
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-text-bright);
}

.dropdown-menu .dropdown-item:active {
    background: var(--color-primary);
    color: var(--color-text-on-primary);
}

.dropdown-menu .dropdown-item i {
    opacity: 0.7;
}

.dropdown-menu .dropdown-item:hover i {
    opacity: 1;
}

.dropdown-divider {
    border-top-color: rgba(255, 255, 255, 0.1);
    margin: 0.5rem 0;
}

/* -----------------------------------------------------------------------------
   File Input - Dark theme
   ----------------------------------------------------------------------------- */
.form-control[type="file"] {
    background: var(--color-bg-input);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--color-text);
}

.form-control[type="file"]:hover {
    border-color: rgba(255, 255, 255, 0.25);
}

.form-control[type="file"]:focus {
    background: var(--color-bg-input);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.15);
    color: var(--color-text);
}

/* File input button (::file-selector-button) */
.form-control[type="file"]::file-selector-button {
    background: var(--color-bg-card);
    border: none;
    border-right: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--color-text);
    padding: 0.65rem 1rem;
    margin-right: 1rem;
    transition: all 0.2s ease;
    cursor: pointer;
}

.form-control[type="file"]:hover::file-selector-button {
    background: var(--color-bg-card-hover);
    color: var(--color-text-bright);
}

/* Webkit browsers (Chrome, Safari, Edge) */
.form-control[type="file"]::-webkit-file-upload-button {
    background: var(--color-bg-card);
    border: none;
    border-right: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--color-text);
    padding: 0.65rem 1rem;
    margin-right: 1rem;
    transition: all 0.2s ease;
    cursor: pointer;
}

.form-control[type="file"]:hover::-webkit-file-upload-button {
    background: var(--color-bg-card-hover);
    color: var(--color-text-bright);
}

/* -----------------------------------------------------------------------------
   Responsive
   ----------------------------------------------------------------------------- */
@media (max-width: 768px) {
    h1 { font-size: 1.6rem; }
    h2 { font-size: 1.4rem; }

    .game-container {
        padding: 0.75rem;
    }

    .question-text {
        font-size: 1.1rem;
    }

    .btn {
        padding: 0.6rem 1rem;
    }

    .admin-sidebar {
        position: fixed;
        left: -280px;
        top: 0;
        width: 280px;
        z-index: 1000;
        transition: left 0.3s ease;
    }

    .admin-sidebar.show {
        left: 0;
    }

    .reward-code {
        font-size: 1.2rem;
        letter-spacing: 1px;
    }

    .game-logo-text {
        font-size: 1.1rem;
    }

    .game-logo-large .game-logo-text {
        font-size: 1.3rem;
    }

    .game-logo-img {
        max-height: 40px;
    }
}

/* -----------------------------------------------------------------------------
   Utilities
   ----------------------------------------------------------------------------- */
.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 0.25rem !important; }
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-3 { margin-bottom: 1rem !important; }
.mb-4 { margin-bottom: 1.5rem !important; }
.mb-5 { margin-bottom: 3rem !important; }

.mt-auto { margin-top: auto !important; }
.text-center { text-align: center !important; }

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* Remove any Bootstrap uppercase */
.text-uppercase {
    text-transform: none !important;
}