@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,600;0,700;1,400&family=Work+Sans:wght@300;400;500;600&display=swap');

:root {
    --bg-main: #012b22;
    --bg-darker: #011e18;
    --bg-forest: #013d30;
    --bg-forest-light: #01503f;
    --accent-gold: #d9a128;
    --accent-gold-hover: #c28e1f;
    --accent-gold-rgb: 217, 161, 40;
    --text-light: #f3f2f2;
    --text-muted: #a8bab4;
    --text-dark: #012b22;
    --border-light: rgba(217, 161, 40, 0.15);
    --border-focus: rgba(217, 161, 40, 0.5);
    --glass-bg: rgba(1, 43, 34, 0.5);
    --glass-blur: blur(12px);
    --shadow-glow: 0 0 15px rgba(217, 161, 40, 0.2);
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Work Sans', sans-serif;
    --font-serif: 'Playfair Display', serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: radial-gradient(circle at top, #014a3a 0%, var(--bg-main) 100%);
    color: var(--text-light);
    font-family: var(--font-body);
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden; /* Avoid main window scrollbar */
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    letter-spacing: -0.02em;
}

.brand-font {
    font-family: var(--font-serif);
    font-weight: 700;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-darker);
}
::-webkit-scrollbar-thumb {
    background: var(--bg-forest-light);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-gold);
}

/* Glass Card */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card:hover {
    border-color: rgba(217, 161, 40, 0.3);
    box-shadow: var(--shadow-glow), 0 8px 32px 0 rgba(0, 0, 0, 0.45);
    transform: translateY(-2px);
}

/* Sticky Layout Architecture */
.app-header {
    height: 70px;
    width: 100%;
    background: rgba(1, 30, 24, 0.95);
    backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    flex-shrink: 0;
    z-index: 1000;
}

.app-footer {
    height: 50px;
    width: 100%;
    background: rgba(3, 8, 6, 0.95);
    backdrop-filter: var(--glass-blur);
    border-top: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    flex-shrink: 0;
    z-index: 1000;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.layout-wrapper {
    flex: 1;
    display: flex;
    overflow: hidden; /* Prevent vertical double scrollbars */
    width: 100%;
}

.sidebar {
    width: 280px;
    height: 100%;
    background: rgba(3, 8, 6, 0.85);
    backdrop-filter: var(--glass-blur);
    border-right: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    overflow-y: auto; /* Independent left navigation scroll view */
    flex-shrink: 0;
}

.sidebar-menu {
    list-style: none;
    padding: 24px 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-group-header {
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent-gold);
    padding: 16px 16px 6px 16px;
    margin-top: 14px;
    border-bottom: 1px dashed rgba(217, 161, 40, 0.2);
    margin-bottom: 6px;
}

.sidebar-group-header span {
    display: inline;
}

.sidebar-menu li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.sidebar-menu li a:hover, .sidebar-menu li.active a {
    color: var(--text-light);
    background: rgba(217, 161, 40, 0.15);
    border-left: 3px solid var(--accent-gold);
    padding-left: 13px;
}

.main-content {
    flex: 1;
    height: 100%;
    overflow-y: auto; /* Independent content scroll view */
    padding: 40px;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-family: var(--font-heading);
    font-weight: 500;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-gold) 0%, #c28e1f 100%);
    color: var(--bg-darker);
    font-weight: 600;
    box-shadow: 0 4px 14px 0 rgba(217, 161, 40, 0.3);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px 0 rgba(217, 161, 40, 0.4);
    background: linear-gradient(135deg, #e8b83a 0%, var(--accent-gold) 100%);
}

.btn-secondary {
    background: rgba(217, 161, 40, 0.1);
    border: 1px solid var(--border-light);
    color: var(--text-light);
}

.btn-secondary:hover {
    background: rgba(217, 161, 40, 0.2);
    border-color: var(--accent-gold);
}

.btn-danger {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #ff858d;
}

.btn-danger:hover {
    background: rgba(220, 53, 69, 0.4);
    border-color: #ff5c67;
}

/* Badge */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-gold {
    background: rgba(217, 161, 40, 0.15);
    color: var(--accent-gold);
    border: 1px solid rgba(217, 161, 40, 0.3);
}

.badge-green {
    background: rgba(40, 167, 69, 0.15);
    color: #4cd964;
    border: 1px solid rgba(40, 167, 69, 0.3);
}

.badge-info {
    background: rgba(0, 122, 255, 0.15);
    color: #5ac8fa;
    border: 1px solid rgba(0, 122, 255, 0.3);
}

/* Alert styling */
.alert {
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 24px;
    border-left: 4px solid transparent;
}

.alert-success {
    background: rgba(40, 167, 69, 0.15);
    border-left-color: #28a745;
    color: #d4edda;
}

.alert-danger {
    background: rgba(220, 53, 69, 0.15);
    border-left-color: #dc3545;
    color: #f8d7da;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-muted);
}

.form-control {
    width: 100%;
    background: rgba(3, 8, 6, 0.5);
    border: 1px solid var(--border-light);
    color: var(--text-light);
    padding: 12px 16px;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 8px rgba(217, 161, 40, 0.25);
    background: rgba(3, 8, 6, 0.8);
}

/* Progress bar */
.progress-bar-wrapper {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    height: 10px;
    overflow: hidden;
    margin: 8px 0;
}

.progress-bar-fill {
    background: linear-gradient(90deg, var(--accent-gold) 0%, #e8b83a 100%);
    height: 100%;
    border-radius: 8px;
    transition: width 0.6s ease;
}

/* Dashboard Grid */
.dashboard-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.metric-card {
    text-align: center;
}

.metric-value {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text-light);
    margin: 10px 0;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.1);
}

.metric-value.gold {
    color: var(--accent-gold);
    text-shadow: var(--shadow-glow);
}

/* Course storefront & list */
.course-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

.course-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.course-cover {
    height: 180px;
    background: linear-gradient(135deg, var(--bg-forest-light) 0%, var(--bg-darker) 100%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 2px solid var(--border-light);
    margin-bottom: 16px;
    position: relative;
    overflow: hidden;
}

.course-cover::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(217, 161, 40, 0.08) 0%, transparent 70%);
}

.course-cover-text {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    text-align: center;
    padding: 0 20px;
    color: var(--accent-gold);
    text-shadow: var(--shadow-glow);
}

.course-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.course-description {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 12px 0;
    flex: 1;
}

.course-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent-gold);
    margin-bottom: 16px;
}

/* Course Player */
.player-container {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 30px;
    height: calc(100vh - 160px);
}

.player-main {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding-right: 10px;
}

.video-container {
    background: #000;
    aspect-ratio: 16/9;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-light);
    margin-bottom: 24px;
    position: relative;
}

.video-stream-mock {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle, #013d30 0%, #011e18 100%);
    color: var(--text-light);
    padding: 40px;
    text-align: center;
}

.video-stream-mock i {
    font-size: 3rem;
    color: var(--accent-gold);
    margin-bottom: 16px;
    filter: drop-shadow(var(--shadow-glow));
}

.player-sidebar {
    background: var(--glass-bg);
    border-left: 1px solid var(--border-light);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: 100%;
}

.syllabus-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-light);
    background: rgba(3, 8, 6, 0.4);
}

.syllabus-body {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.module-title {
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--accent-gold);
    font-weight: 600;
    margin: 15px 10px 8px 10px;
    letter-spacing: 0.05em;
}

.lesson-list {
    list-style: none;
}

.lesson-item a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: 6px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.lesson-item a:hover {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-light);
}

.lesson-item.active a {
    background: rgba(217, 161, 40, 0.12);
    color: var(--text-light);
    border-left: 3px solid var(--accent-gold);
}

.lesson-item.completed a i {
    color: #4cd964;
}

/* Resource List */
.resource-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
}

.resource-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Assessment UI */
.assessment-wizard {
    max-width: 800px;
    margin: 0 auto;
}

.question-card {
    margin-bottom: 30px;
    display: none;
}

.question-card.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

.option-button {
    width: 100%;
    text-align: left;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    color: var(--text-light);
    padding: 16px 20px;
    border-radius: 8px;
    margin-top: 12px;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.2s ease;
}

.option-button:hover {
    background: rgba(217, 161, 40, 0.08);
    border-color: var(--accent-gold);
    transform: translateX(4px);
}

.option-button.selected {
    background: rgba(217, 161, 40, 0.2);
    border-color: var(--accent-gold);
    box-shadow: var(--shadow-glow);
}

/* Table */
.custom-table-wrapper {
    overflow-x: auto;
    margin-top: 20px;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.custom-table th {
    padding: 14px 16px;
    border-bottom: 2px solid var(--border-light);
    color: var(--accent-gold);
    font-weight: 600;
}

.custom-table td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-light);
}

.custom-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

/* Certificate Layout */
.certificate-frame {
    background: #011e18;
    padding: 40px;
    border: 12px double var(--accent-gold);
    border-radius: 4px;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.8), inset 0 0 20px rgba(217, 161, 40, 0.1);
    max-width: 900px;
    margin: 40px auto;
    text-align: center;
    position: relative;
    color: #e8e8e8;
}

.certificate-seal {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px double var(--accent-gold);
    background: radial-gradient(circle, #01503f 0%, #012b22 100%);
    margin: 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-serif);
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--accent-gold);
    box-shadow: var(--shadow-glow);
}

@media print {
    /* Hide all layout decoration & navigation */
    .app-header,
    .app-footer,
    .sidebar,
    .mobile-bottom-nav,
    .drawer-overlay,
    .top-bar,
    .no-print,
    .btn,
    .alert {
        display: none !important;
    }

    body, html, .layout-wrapper, .main-content {
        background: #ffffff !important;
        color: #000000 !important;
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        height: auto !important;
        box-shadow: none !important;
    }

    .main-content {
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        float: none !important;
    }

    .certificate-frame {
        border: 8px double #d9a128 !important;
        background: #ffffff !important;
        color: #000000 !important;
        box-shadow: none !important;
        margin: 0 auto !important;
        padding: 20px !important;
        width: 100% !important;
        max-width: 800px !important;
        page-break-inside: avoid;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .certificate-frame * {
        color: #000000 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .certificate-frame div {
        border-color: #d9a128 !important;
    }

    .brand-font, .certificate-seal, .certificate-frame h2, .certificate-frame h4 {
        color: #d9a128 !important;
    }

    .certificate-seal {
        border-color: #d9a128 !important;
        background: transparent !important;
    }

    /* Print styling for custom tables and other list views */
    .glass-card {
        background: transparent !important;
        border: 1px solid #ccc !important;
        box-shadow: none !important;
        padding: 0 !important;
        color: #000000 !important;
    }

    .custom-table {
        border: 1px solid #ccc !important;
        width: 100% !important;
        border-collapse: collapse !important;
    }

    .custom-table th, .custom-table td {
        border: 1px solid #ccc !important;
        color: #000000 !important;
        background: transparent !important;
        padding: 8px !important;
    }

    .badge {
        border: 1px solid #000 !important;
        background: transparent !important;
        color: #000 !important;
    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Mobile Bottom Nav Bar styling */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60px;
    background: rgba(3, 8, 6, 0.95);
    backdrop-filter: var(--glass-blur);
    border-top: 1px solid var(--border-light);
    z-index: 1060;
    justify-content: space-around;
    align-items: center;
    padding: 0 10px;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
}

.mobile-bottom-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.7rem;
    font-family: var(--font-heading);
    gap: 4px;
    transition: color 0.2s ease;
    cursor: pointer;
    background: none;
    border: none;
    padding: 6px;
    width: 20%;
}

.mobile-bottom-item i {
    font-size: 1.25rem;
}

.mobile-bottom-item:hover,
.mobile-bottom-item.active {
    color: var(--accent-gold);
}

/* ========================================
   LIGHT THEME
   Dark mode is default. Apply via data-theme="light" on <html>.
   ======================================== */
[data-theme="light"] {
    --bg-main: #f3f2f2;
    --bg-darker: #e8e7e7;
    --bg-forest: #ffffff;
    --bg-forest-light: #f9f9f8;
    --accent-gold: #d9a128;
    --accent-gold-hover: #c28e1f;
    --accent-gold-rgb: 217, 161, 40;
    --text-light: #012b22;
    --text-muted: #4a6a60;
    --text-dark: #012b22;
    --border-light: rgba(1, 43, 34, 0.12);
    --border-focus: rgba(217, 161, 40, 0.5);
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-blur: blur(12px);
    --shadow-glow: 0 0 15px rgba(217, 161, 40, 0.15);
}

[data-theme="light"] body {
    background: #f3f2f2;
}

[data-theme="light"] .app-header {
    background: #ffffff;
    border-bottom: 1px solid #e0dfdf;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .app-footer {
    background: #ffffff;
    border-top: 1px solid #e0dfdf;
}

[data-theme="light"] .sidebar {
    background: #ffffff;
    border-right: 1px solid #e0dfdf;
}

[data-theme="light"] .sidebar-menu li a:hover,
[data-theme="light"] .sidebar-menu li.active a {
    background: rgba(217, 161, 40, 0.1);
}

[data-theme="light"] .glass-card {
    background: #ffffff;
    border: 1px solid #e0dfdf;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .glass-card:hover {
    border-color: rgba(217, 161, 40, 0.4);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .form-control {
    background: #f9f9f8;
    border: 1px solid #d4d3d3;
    color: #012b22;
}

[data-theme="light"] .form-control:focus {
    background: #ffffff;
    border-color: var(--accent-gold);
}

[data-theme="light"] .btn-secondary {
    background: rgba(1, 43, 34, 0.06);
    border: 1px solid rgba(1, 43, 34, 0.15);
    color: #012b22;
}

[data-theme="light"] .btn-secondary:hover {
    background: rgba(1, 43, 34, 0.12);
    border-color: rgba(1, 43, 34, 0.3);
}

[data-theme="light"] .btn-danger {
    background: rgba(220, 53, 69, 0.08);
    border: 1px solid rgba(220, 53, 69, 0.25);
    color: #dc3545;
}

[data-theme="light"] .btn-danger:hover {
    background: rgba(220, 53, 69, 0.15);
}

[data-theme="light"] .badge-gold {
    background: rgba(217, 161, 40, 0.12);
    border: 1px solid rgba(217, 161, 40, 0.3);
}

[data-theme="light"] .badge-green {
    background: rgba(40, 167, 69, 0.1);
    color: #1e7e34;
    border: 1px solid rgba(40, 167, 69, 0.25);
}

[data-theme="light"] .badge-info {
    background: rgba(0, 122, 255, 0.08);
    color: #0056b3;
    border: 1px solid rgba(0, 122, 255, 0.2);
}

[data-theme="light"] .alert-success {
    background: rgba(40, 167, 69, 0.08);
    color: #155724;
}

[data-theme="light"] .alert-danger {
    background: rgba(220, 53, 69, 0.08);
    color: #721c24;
}

[data-theme="light"] .custom-table td {
    border-bottom: 1px solid #eee;
    color: #012b22;
}

[data-theme="light"] .custom-table tr:hover td {
    background: rgba(217, 161, 40, 0.04);
}

[data-theme="light"] .option-button {
    background: #ffffff;
    border: 1px solid #d4d3d3;
    color: #012b22;
}

[data-theme="light"] .option-button:hover {
    background: rgba(217, 161, 40, 0.06);
    border-color: var(--accent-gold);
}

[data-theme="light"] .option-button.selected {
    background: rgba(217, 161, 40, 0.12);
}

[data-theme="light"] .course-cover {
    background: linear-gradient(135deg, #f0efe9 0%, #e8e7e7 100%);
}

[data-theme="light"] .course-cover::before {
    background: radial-gradient(circle, rgba(217, 161, 40, 0.06) 0%, transparent 70%);
}

[data-theme="light"] .video-stream-mock {
    background: radial-gradient(circle, #e0dfdf 0%, #f3f2f2 100%);
}

[data-theme="light"] .player-sidebar {
    background: #ffffff;
    border-left: 1px solid #e0dfdf;
}

[data-theme="light"] .syllabus-header {
    background: #f9f9f8;
}

[data-theme="light"] .lesson-item a:hover {
    background: rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .lesson-item.active a {
    background: rgba(217, 161, 40, 0.08);
}

[data-theme="light"] .resource-item {
    background: #f9f9f8;
    border: 1px solid #e0dfdf;
}

[data-theme="light"] .certificate-frame {
    background: #ffffff;
    color: #012b22;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.08), inset 0 0 20px rgba(217, 161, 40, 0.05);
}

[data-theme="light"] .certificate-seal {
    background: radial-gradient(circle, #f9f9f8 0%, #ffffff 100%);
}

[data-theme="light"] .mobile-bottom-nav {
    background: #ffffff;
    border-top: 1px solid #e0dfdf;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .progress-bar-wrapper {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] ::-webkit-scrollbar-track {
    background: #f3f2f2;
}

[data-theme="light"] ::-webkit-scrollbar-thumb {
    background: #ccc;
}

[data-theme="light"] .drawer-overlay {
    background: rgba(0, 0, 0, 0.25);
}

/* Theme Toggle Button */
.theme-toggle {
    background: none;
    border: 1px solid var(--border-light);
    color: var(--text-muted);
    border-radius: 50%;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.theme-toggle:hover {
    color: var(--accent-gold);
    border-color: var(--accent-gold);
    transform: rotate(30deg);
}

/* Responsive Grid Utilities */
.responsive-grid-sidebar {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 30px;
}

.responsive-grid-2col {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
}

.responsive-grid-1-2fr {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 30px;
}

.responsive-grid-2-1fr {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

.responsive-grid-1-1fr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    /* Hide desktop sidebar placement and make it a slide-out drawer */
    .sidebar {
        position: fixed;
        top: 70px;
        left: 0;
        bottom: 60px; /* Leave space for bottom nav bar */
        width: 280px;
        height: auto;
        z-index: 1050;
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.5);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .sidebar-menu span {
        display: inline !important; /* Force labels to show in mobile drawer list */
    }
    
    /* Overlay for drawer */
    .drawer-overlay {
        display: none;
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(4px);
        z-index: 1040;
    }
    
    .drawer-overlay.active {
        display: block;
    }
    
    /* Hamburger menu toggle button in header */
    .menu-toggle {
        display: inline-flex !important;
    }
    
    /* Mobile bottom navigation menu */
    .mobile-bottom-nav {
        display: flex !important;
    }
    
    /* Adjust main content padding and margins on mobile */
    .main-content {
        padding: 15px 15px 90px 15px !important; /* Space for mobile bottom bar */
        overflow-y: auto;
    }
    
    /* Hide footer on mobile */
    .app-footer {
        display: none !important;
    }
    
    .player-container {
        grid-template-columns: 1fr;
        height: auto;
    }

    .responsive-grid-sidebar,
    .responsive-grid-2col,
    .responsive-grid-1-2fr,
    .responsive-grid-2-1fr,
    .responsive-grid-1-1fr {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    
    .app-header {
        padding: 0 15px !important;
    }
    
    .header-right {
        gap: 12px !important;
    }
    
    .header-currency {
        display: none !important;
    }
    
    .header-user-info {
        display: none !important;
    }
    
    .header-logout-form {
        display: none !important;
    }
    
    .header-brand img {
        height: 28px !important;
    }
}

.likert-options {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    margin-top: 20px;
}

@media (max-width: 576px) {
    .likert-options {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }
}
