/* ==============================================
   A PLUS PLATFORM - Mobile-First Optimized
   ============================================== */

/* ---- Variables ---- */
:root {
    --primary: #6C63FF;
    --primary-dark: #5A52D5;
    --primary-light: #8B83FF;
    --primary-glow: rgba(108, 99, 255, 0.3);
    --secondary: #00D2FF;
    --success: #00E676;
    --success-bg: rgba(0, 230, 118, 0.12);
    --success-border: rgba(0, 230, 118, 0.4);
    --error: #FF5252;
    --error-bg: rgba(255, 82, 82, 0.12);
    --error-border: rgba(255, 82, 82, 0.4);
    --bg-primary: #0B0B1A;
    --bg-card: rgba(255, 255, 255, 0.05);
    --bg-card-hover: rgba(255, 255, 255, 0.08);
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --text: #FFFFFF;
    --text-secondary: rgba(255, 255, 255, 0.65);
    --text-muted: rgba(255, 255, 255, 0.4);
    --radius-sm: 12px;
    --radius: 16px;
    --radius-lg: 20px;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.35);
}

/* ---- Reset & Base ---- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    background: var(--bg-primary);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    width: 100%;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
}

a {
    text-decoration: none;
    color: inherit;
    -webkit-tap-highlight-color: transparent;
}

button {
    cursor: pointer;
    font-family: inherit;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

img {
    max-width: 100%;
    display: block;
    margin: 0 auto;
}

/* ---- Container ---- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ===================== BACKGROUND ===================== */
.bg-animation {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    will-change: transform;
    transform: translateZ(0);
}

.bg-orb-1 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(108, 99, 255, 0.2), transparent 70%);
    top: -150px;
    left: -150px;
    animation: orb1 20s ease-in-out infinite;
}

.bg-orb-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0, 210, 255, 0.15), transparent 70%);
    bottom: -100px;
    right: -100px;
    animation: orb2 25s ease-in-out infinite;
}

@keyframes orb1 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(40px, 60px); }
}

@keyframes orb2 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-50px, -40px); }
}

/* ===================== NAVBAR ===================== */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(11, 11, 26, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 12px 0;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.1rem;
    font-weight: 700;
}

.logo-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 32px;
    padding: 0 8px;
    border-radius: 10px;
    background: linear-gradient(135deg, #FFB300 0%, #F57C00 100%);
    border: 1px solid rgba(0, 0, 0, 0.15);
    color: #fff;
    font-weight: 900;
    font-size: 1rem;
    line-height: 1;
    letter-spacing: 0.5px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 3px 12px rgba(245, 124, 0, 0.4);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.35);
}

.logo-img {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: contain;
    background: transparent;
    flex-shrink: 0;
    display: block;
    filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.18));
}

.logo-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    background: none;
    border: none;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.nav-back:active {
    background: rgba(255, 255, 255, 0.05);
    transform: scale(0.95);
}

.nav-back svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ===================== HERO ===================== */
.hero {
    text-align: center;
    padding: 40px 0 24px;
}

.hero-badge {
    display: inline-block;
    background: rgba(108, 99, 255, 0.12);
    border: 1px solid rgba(108, 99, 255, 0.25);
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--primary-light);
    margin-bottom: 16px;
    animation: fadeInUp 0.5s ease;
}

.hero-title {
    font-size: 1.85rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 12px;
    animation: fadeInUp 0.5s ease 0.1s both;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    font-weight: 400;
    animation: fadeInUp 0.5s ease 0.2s both;
}

.hero-description {
    font-size: 0.88rem;
    color: var(--text-muted);
    max-width: 480px;
    margin: 0 auto;
    animation: fadeInUp 0.5s ease 0.3s both;
    display: none;
}

/* ===================== CATEGORIES ===================== */
.categories-section {
    padding: 20px 0 60px;
    flex: 1;
}

.categories-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

.category-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    text-align: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    animation: fadeInUp 0.5s ease both;
    display: block;
    will-change: transform;
}

.category-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.02), transparent);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.category-card:active {
    transform: scale(0.97);
}

.card-icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    transition: transform 0.25s ease;
}

.card-icon {
    font-size: 1.7rem;
    line-height: 1;
}

.card-title {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.card-description {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 14px;
    line-height: 1.4;
}

.card-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 50%;
    font-size: 0.9rem;
    transition: all 0.25s ease;
}

/* ===================== CATEGORY PAGE ===================== */
.category-header {
    text-align: center;
    padding: 40px 0 28px;
}

.category-header-icon {
    width: 70px;
    height: 70px;
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    font-size: 2.2rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    animation: fadeInUp 0.4s ease;
}

.category-header h1 {
    font-size: 1.7rem;
    font-weight: 800;
    margin-bottom: 10px;
    animation: fadeInUp 0.4s ease 0.1s both;
}

.category-header p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    max-width: 400px;
    margin: 0 auto;
    animation: fadeInUp 0.4s ease 0.2s both;
}

.quizzes-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    padding-bottom: 60px;
}

/* تنسيق نافذة السنة الدراسية */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(5px);
    display: flex; justify-content: center; align-items: center;
    z-index: 1000; opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
.modal-overlay.active { opacity: 1; pointer-events: auto; }
.modal-content {
    background: #ffffff; padding: 35px 25px; border-radius: var(--radius);
    width: 90%; max-width: 420px; text-align: center;
    box-shadow: 0 15px 50px rgba(0,0,0,0.3); transform: translateY(20px);
    transition: transform 0.3s ease; border: 2px solid #3B82F6;
}
.modal-overlay.active .modal-content { transform: translateY(0); }
.modal-title { font-size: 1.5rem; margin-bottom: 10px; color: #1e293b; font-weight: 800;}
.modal-subtitle { font-size: 0.95rem; color: #64748b; margin-bottom: 25px;}
.year-btn {
    display: block; width: 100%; padding: 14px; margin-bottom: 12px;
    background: #f8fafc; border: 2px solid #e2e8f0;
    border-radius: 12px; color: #1e293b; font-weight: bold;
    font-size: 1.1rem; cursor: pointer; transition: all 0.2s;
}
html[data-theme="dark"] .modal-content {
    background: #1e293b; /* خلفية النافذة شيك ومريحة للعين */
    border: 1px solid #334155;
}
html[data-theme="dark"] .year-btn {
    background: #0f172a; /* لون الزراير رمادي داكن فخم */
    border: 1px solid #334155; 
    color: #ffffff !important; /* إجبار المتصفح على الأبيض الناصع */
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}
html[data-theme="dark"] .year-btn:hover {
    background: #3B82F6; 
    border-color: #3B82F6;
}
html[data-theme="dark"] .modal-title {
    color: #ffffff !important;
}
html[data-theme="dark"] .modal-subtitle {
    color: #94a3b8 !important;
}
.year-btn:hover { background: #3B82F6; color: white; border-color: #3B82F6; transform: translateY(-3px); box-shadow: 0 8px 15px rgba(59, 130, 246, 0.3);}
.year-btn:hover { background: #3B82F6; color: white; border-color: #3B82F6; transform: translateY(-2px);}

/* زر تعديل السنة */
.current-year-badge {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 20px;
    background: rgba(59, 130, 246, 0.1); color: #3B82F6; font-weight: bold;
    border-radius: 30px; font-size: 1rem; cursor: pointer; margin-bottom: 20px;
    border: 1px solid rgba(59, 130, 246, 0.2); transition: all 0.2s;
}
.current-year-badge:hover { background: #3B82F6; color: white; }

/* تنسيق شاشة الاختيارات الافتتاحية */
.track-selection-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 65vh;
    padding: 40px 20px;
    animation: fadeInUp 0.5s ease both;
}
.track-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 35px;
    color: var(--text-primary);
    text-align: center;
}
.track-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
    width: 100%;
    max-width: 850px;
}
.track-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 35px 25px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-sm);
}
.track-card:hover {
    transform: translateY(-6px);
    border-color: #3B82F6;
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.1);
}
.track-icon-wrapper {
    width: 70px;
    height: 70px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    color: white;
    box-shadow: 0 6px 15px rgba(0,0,0,0.15);
}
.track-card-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* زر العودة لاختيار القسم */
.back-to-tracks-btn {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border);
    padding: 8px 18px;
    border-radius: 25px;
    font-weight: bold;
    cursor: pointer;
    margin-bottom: 25px;
    transition: all 0.2s;
    box-shadow: var(--shadow-sm);
    display: inline-flex;
    align-items: center;
    font-family: inherit;
    font-size: 0.95rem;
}
.back-to-tracks-btn:hover {
    background: var(--border);
}

/* تنسيق شارة A+ */
.a-plus-badge {
    display: inline-block;
    background: linear-gradient(135deg, #FFD700, #FF8C00);
    color: #fff;
    font-size: 1.2rem;
    font-weight: 900;
    padding: 4px 16px;
    border-radius: 12px;
    margin-bottom: 10px;
    box-shadow: 0 4px 10px rgba(255, 140, 0, 0.3);
    text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
    letter-spacing: 1px;
}

.quiz-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 16px;
    transition: all 0.25s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 14px;
    animation: fadeInUp 0.4s ease both;
    min-width: 0;
}

.quiz-card:active {
    transform: scale(0.98);
}

.quiz-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
    background: rgba(108, 99, 255, 0.12);
}

.quiz-card-content {
    flex: 1;
    min-width: 0;
}

.quiz-card-title {
    font-size: 0.98rem;
    font-weight: 600;
    margin-bottom: 2px;
}

.quiz-card-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.quiz-card-meta {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 3px;
}

.quiz-card-arrow {
    color: var(--text-muted);
    font-size: 1.15rem;
    transition: all 0.25s ease;
    flex-shrink: 0;
}

/* ===================== QUIZ PAGE ===================== */
.quiz-wrapper {
    max-width: 700px;
    margin: 24px auto;
    padding: 0 16px 60px;
}

.quiz-header {
    margin-bottom: 24px;
}

.quiz-title-text {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.quiz-progress {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 100px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 100px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0;
}

.quiz-content {
    animation: slideIn 0.35s ease;
}

.question-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    margin-bottom: 20px;
}

.question-number {
    font-size: 0.75rem;
    color: var(--primary-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.question-text {
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.6;
}

.options-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.option-btn {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-size: 0.92rem;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    touch-action: manipulation;
}

.option-letter {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.06);
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.option-text {
    flex: 1;
}

.option-btn:active {
    transform: scale(0.98);
}

.option-btn:disabled {
    cursor: default;
    pointer-events: none;
}

.option-btn.correct {
    background: var(--success-bg);
    border-color: var(--success-border);
    animation: popIn 0.3s ease;
}

.option-btn.correct .option-letter {
    background: var(--success);
    color: #000;
}

.option-btn.incorrect {
    background: var(--error-bg);
    border-color: var(--error-border);
    animation: shake 0.35s ease;
}

.option-btn.incorrect .option-letter {
    background: var(--error);
    color: #fff;
}

.option-btn.dimmed {
    opacity: 0.35;
}

.next-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border: none;
    border-radius: var(--radius);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 4px 16px var(--primary-glow);
    display: none;
    touch-action: manipulation;
}

.next-btn:active {
    transform: scale(0.97);
}

.next-btn.visible {
    display: block;
    animation: fadeInUp 0.3s ease;
}

/* ===================== RESULTS ===================== */
.results-container {
    text-align: center;
    animation: fadeInUp 0.5s ease;
}

.results-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px 20px;
    margin-bottom: 20px;
}

.results-emoji {
    font-size: 3.5rem;
    margin-bottom: 10px;
    animation: bounceIn 0.5s ease;
}

.score-ring-wrap {
    position: relative;
    width: 140px;
    height: 140px;
    margin: 0 auto 24px;
}

.score-ring {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.score-ring-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.06);
    stroke-width: 10;
}

.score-ring-fill {
    fill: none;
    stroke-width: 10;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.score-value {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.score-percent {
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1;
}

.score-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 3px;
}

.results-title {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.results-message {
    color: var(--text-secondary);
    margin-bottom: 24px;
    font-size: 0.9rem;
    padding: 0 10px;
}

.results-stats {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-bottom: 30px;
}

.stat-item {
    text-align: center;
}

.stat-num {
    font-size: 1.5rem;
    font-weight: 700;
}

.stat-num.green {
    color: var(--success);
}

.stat-num.red {
    color: var(--error);
}

.stat-lbl {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.results-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
}

.btn {
    padding: 14px 28px;
    border: none;
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    touch-action: manipulation;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    box-shadow: 0 4px 16px var(--primary-glow);
}

.btn-primary:active {
    transform: scale(0.97);
}

.btn-warn {
    background: rgba(255, 171, 64, 0.15);
    color: #FFAB40;
    border: 1px solid rgba(255, 171, 64, 0.35);
}

.btn-ghost {
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text);
}

.btn-ghost:active {
    transform: scale(0.98);
    background: var(--bg-card-hover);
}

/* ===================== LOADING & ERROR ===================== */
.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 0;
    animation: fadeIn 0.3s ease;
}

.spinner {
    width: 42px;
    height: 42px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin-bottom: 16px;
}

.loading-text {
    color: var(--text-secondary);
    font-size: 0.88rem;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.error-container {
    text-align: center;
    padding: 80px 20px;
    animation: fadeIn 0.3s ease;
}

.error-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.error-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.error-message {
    color: var(--text-secondary);
    margin-bottom: 24px;
    font-size: 0.9rem;
}

/* ===================== FOOTER ===================== */
.footer {
    text-align: center;
    padding: 24px 0;
    color: var(--text-muted);
    font-size: 0.78rem;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

/* ===================== ANIMATIONS ===================== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes popIn {
    0% { transform: scale(0.98); }
    50% { transform: scale(1.01); }
    100% { transform: scale(1); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    75% { transform: translateX(-3px); }
}

@keyframes bounceIn {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ===================== TABLET (min-width: 640px) ===================== */
@media (min-width: 640px) {
    .container {
        padding: 0 24px;
    }
    
    .hero {
        padding: 50px 0 30px;
    }
    
    .hero-title {
        font-size: 2.3rem;
    }
    
    .hero-subtitle {
        font-size: 1.15rem;
    }
    
    .hero-description {
        display: block;
    }
    
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    
    .category-card {
        padding: 28px 24px;
    }
    
    .card-icon-wrapper {
        width: 68px;
        height: 68px;
    }
    
    .card-icon {
        font-size: 1.9rem;
    }
    
    .quizzes-grid {
        gap: 14px;
    }
    
    .quiz-card {
        padding: 20px 20px;
    }
    
    .question-card {
        padding: 32px 28px;
    }
    
    .question-text {
        font-size: 1.1rem;
    }
    
    .option-btn {
        padding: 15px 18px;
        font-size: 0.95rem;
    }
    
    .results-card {
        padding: 46px 28px;
    }
    
    .score-ring-wrap {
        width: 160px;
        height: 160px;
    }
    
    .score-percent {
        font-size: 2.6rem;
    }
    
    .results-actions {
        flex-direction: row;
        justify-content: center;
    }
}

/* ===================== DESKTOP (min-width: 1024px) ===================== */
@media (min-width: 1024px) {
    .hero {
        padding: 70px 0 36px;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.35rem;
    }
    
    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
        max-width: 960px;
        margin: 0 auto;
    }
    
    .category-card {
        padding: 32px 26px;
    }
    
    .category-card:hover {
        transform: translateY(-6px) scale(1.02);
        border-color: var(--border-hover);
        box-shadow: var(--shadow-lg);
    }
    
    .category-card:hover::before {
        opacity: 1;
    }
    
    .category-card:hover .card-icon-wrapper {
        transform: scale(1.06) rotate(-2deg);
    }
    
    .category-card:hover .card-arrow {
        background: var(--primary);
        border-color: var(--primary);
        transform: translateX(4px);
        color: #fff;
    }
    
    .card-icon-wrapper {
        width: 74px;
        height: 74px;
    }
    
    .card-icon {
        font-size: 2rem;
    }
    
    .quizzes-grid {
        max-width: 780px;
        margin: 0 auto;
    }
    
    .quiz-card:hover {
        transform: translateY(-3px);
        border-color: var(--border-hover);
        box-shadow: var(--shadow);
        background: var(--bg-card-hover);
    }
    
    .quiz-card:hover .quiz-card-arrow {
        color: var(--primary);
        transform: translateX(4px);
    }
    
    .option-btn:hover:not(:disabled) {
        background: var(--bg-card-hover);
        border-color: var(--border-hover);
        transform: translateX(3px);
    }
    
    .option-btn:hover:not(:disabled) .option-letter {
        background: rgba(108, 99, 255, 0.2);
        color: var(--primary-light);
    }
    
    .next-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 24px var(--primary-glow);
    }
    
    .btn-primary:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 24px var(--primary-glow);
    }
    
    .btn-ghost:hover {
        background: var(--bg-card-hover);
        border-color: var(--border-hover);
    }
}

/* ===================== ACCESSIBILITY ===================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===================== HIGH CONTRAST ===================== */
@media (prefers-contrast: high) {
    :root {
        --border: rgba(255, 255, 255, 0.2);
        --bg-card: rgba(255, 255, 255, 0.1);
    }
}

/* ===================== SCROLL QUIZ MODE ===================== */

.quiz-header-top {
    text-align: center;
    margin-bottom: 32px;
    animation: fadeInUp 0.5s ease;
}

.quiz-title-main {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.progress-bar-top {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 100px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill-top {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 100px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0;
}

.progress-text-top {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Questions Scroll Container */
.questions-scroll-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 32px;
}

.question-card-scroll {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    scroll-margin-top: 80px;
    animation: fadeInUp 0.5s ease both;
}

.question-number-scroll {
    font-size: 0.75rem;
    color: var(--primary-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.question-text-scroll {
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.6;
    margin-bottom: 20px;
    color: var(--text);
}

.options-list-scroll {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

.option-btn-scroll {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-size: 0.92rem;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    touch-action: manipulation;
}

.option-btn-scroll:active {
    transform: scale(0.98);
}

.option-btn-scroll:disabled {
    cursor: default;
    pointer-events: none;
}

.option-btn-scroll.correct {
    background: var(--success-bg);
    border-color: var(--success-border);
    animation: popIn 0.3s ease;
}

.option-btn-scroll.correct .option-letter {
    background: var(--success);
    color: #000;
}

.option-btn-scroll.incorrect {
    background: var(--error-bg);
    border-color: var(--error-border);
    animation: shake 0.35s ease;
}

.option-btn-scroll.incorrect .option-letter {
    background: var(--error);
    color: #fff;
}

.option-btn-scroll.dimmed {
    opacity: 0.35;
}

/* Explanation Box */
.explanation-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    padding: 16px;
    margin-top: 16px;
    animation: fadeInUp 0.4s ease;
}

.explanation-box.exp-correct {
    background: rgba(0, 230, 118, 0.08);
    border-color: rgba(0, 230, 118, 0.3);
}

.explanation-box.exp-incorrect {
    background: rgba(255, 82, 82, 0.08);
    border-color: rgba(255, 82, 82, 0.3);
}

.explanation-icon {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.explanation-title {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
}

.explanation-text {
    font-size: 0.88rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Submit Container */
.submit-container {
    text-align: center;
    margin: 32px 0;
    padding: 24px 0;
    animation: fadeInUp 0.5s ease;
}

.btn-large {
    padding: 16px 40px;
    font-size: 1.05rem;
    min-width: 200px;
}

/* Results Screen Large */
.results-screen {
    animation: fadeInUp 0.6s ease;
}

.results-card-big {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px 20px;
    margin-bottom: 20px;
    text-align: center;
}

/* Hidden utility */
.hidden {
    display: none !important;
}

/* Tablet */
@media (min-width: 640px) {
    .quiz-title-main {
        font-size: 1.8rem;
    }
    
    .question-card-scroll {
        padding: 32px 28px;
    }
    
    .question-text-scroll {
        font-size: 1.15rem;
    }
    
    .option-btn-scroll {
        padding: 16px 20px;
        font-size: 0.95rem;
    }
    
    .explanation-box {
        padding: 20px;
    }
}

/* Desktop */
@media (min-width: 1024px) {
    .questions-scroll-container {
        max-width: 800px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .submit-container {
        max-width: 800px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .option-btn-scroll:hover:not(:disabled) {
        background: var(--bg-card-hover);
        border-color: var(--border-hover);
        transform: translateX(3px);
    }
    
    .option-btn-scroll:hover:not(:disabled) .option-letter {
        background: rgba(108, 99, 255, 0.2);
        color: var(--primary-light);
    }
}

/* ===================== LIGHT MODE (COMPLETE) ===================== */

[data-theme="light"] {
    --bg-primary: #F4F6F9;
    --bg-card: rgba(0, 0, 0, 0.03);
    --bg-card-hover: rgba(0, 0, 0, 0.06);
    --border: rgba(0, 0, 0, 0.08);
    --border-hover: rgba(0, 0, 0, 0.15);
    --text: #1A1A2E;
    --text-secondary: rgba(0, 0, 0, 0.6);
    --text-muted: rgba(0, 0, 0, 0.4);
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.1);
    --primary-glow: rgba(108, 99, 255, 0.2);
    --success-bg: rgba(0, 200, 100, 0.1);
    --success-border: rgba(0, 200, 100, 0.4);
    --error-bg: rgba(255, 50, 50, 0.1);
    --error-border: rgba(255, 50, 50, 0.4);
}

/* Body Light */
[data-theme="light"] body {
    background: var(--bg-primary);
    color: var(--text);
}

/* Navbar Light */
[data-theme="light"] .navbar {
    background: rgba(244, 246, 249, 0.95);
    border-bottom-color: rgba(0, 0, 0, 0.08);
}

/* Logo Light */
[data-theme="light"] .logo-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Gradient Text Light */
[data-theme="light"] .gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Background Orbs Light */
[data-theme="light"] .bg-orb-1 {
    background: radial-gradient(circle, rgba(108, 99, 255, 0.08), transparent 70%);
}
[data-theme="light"] .bg-orb-2 {
    background: radial-gradient(circle, rgba(0, 210, 255, 0.08), transparent 70%);
}

/* All Cards Light */
[data-theme="light"] .category-card,
[data-theme="light"] .quiz-card,
[data-theme="light"] .question-card-scroll,
[data-theme="light"] .question-card,
[data-theme="light"] .results-card-big,
[data-theme="light"] .results-card {
    background: #FFFFFF;
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .category-card:hover,
[data-theme="light"] .quiz-card:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    border-color: rgba(0, 0, 0, 0.15);
}

/* Hero Badge Light */
[data-theme="light"] .hero-badge {
    background: rgba(108, 99, 255, 0.1);
    border-color: rgba(108, 99, 255, 0.2);
    color: var(--primary);
}

/* Hero Title Light */
[data-theme="light"] .hero-title {
    color: var(--text);
}

/* Hero Subtitle Light */
[data-theme="light"] .hero-subtitle,
[data-theme="light"] .hero-description {
    color: var(--text-secondary);
}

/* Card Title & Description Light */
[data-theme="light"] .card-title,
[data-theme="light"] .quiz-card-title,
[data-theme="light"] .question-text-scroll,
[data-theme="light"] .question-text {
    color: var(--text);
}

[data-theme="light"] .card-description,
[data-theme="light"] .quiz-card-desc {
    color: var(--text-secondary);
}

/* Quiz Card Meta Light */
[data-theme="light"] .quiz-card-meta {
    color: var(--text-muted);
}

/* Options Light */
[data-theme="light"] .option-btn-scroll,
[data-theme="light"] .option-btn {
    background: #FFFFFF;
    border-color: rgba(0, 0, 0, 0.1);
    color: var(--text);
}

[data-theme="light"] .option-btn-scroll:hover:not(:disabled),
[data-theme="light"] .option-btn:hover:not(:disabled) {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .option-letter {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text);
}

[data-theme="light"] .option-text {
    color: var(--text);
}

/* Correct/Incorrect States Light */
[data-theme="light"] .option-btn-scroll.correct,
[data-theme="light"] .option-btn.correct {
    background: var(--success-bg);
    border-color: var(--success-border);
}

[data-theme="light"] .option-btn-scroll.incorrect,
[data-theme="light"] .option-btn.incorrect {
    background: var(--error-bg);
    border-color: var(--error-border);
}

/* Explanation Light */
[data-theme="light"] .explanation-box {
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .explanation-box.exp-correct {
    background: rgba(0, 200, 100, 0.08);
    border-color: rgba(0, 200, 100, 0.3);
}

[data-theme="light"] .explanation-box.exp-incorrect {
    background: rgba(255, 50, 50, 0.08);
    border-color: rgba(255, 50, 50, 0.3);
}

[data-theme="light"] .explanation-title {
    color: var(--text);
}

[data-theme="light"] .explanation-text {
    color: var(--text-secondary);
}

/* Progress Bar Light */
[data-theme="light"] .progress-bar-top,
[data-theme="light"] .progress-bar {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .progress-text-top,
[data-theme="light"] .quiz-progress {
    color: var(--text-muted);
}

/* Quiz Title Light */
[data-theme="light"] .quiz-title-main,
[data-theme="light"] .quiz-title-text {
    color: var(--text);
}

/* Question Number Light */
[data-theme="light"] .question-number-scroll,
[data-theme="light"] .question-number {
    color: var(--primary-light);
}

/* Score Ring Light */
[data-theme="light"] .score-ring-bg {
    stroke: rgba(0, 0, 0, 0.06);
}

/* Results Light */
[data-theme="light"] .results-title {
    color: var(--text);
}

[data-theme="light"] .results-message {
    color: var(--text-secondary);
}

[data-theme="light"] .score-label {
    color: var(--text-muted);
}

[data-theme="light"] .stat-num {
    color: var(--text);
}

[data-theme="light"] .stat-lbl {
    color: var(--text-muted);
}

/* Spinner Light */
[data-theme="light"] .spinner {
    border-color: rgba(0, 0, 0, 0.1);
    border-top-color: var(--primary);
}

[data-theme="light"] .loading-text {
    color: var(--text-secondary);
}

/* Error Light */
[data-theme="light"] .error-title {
    color: var(--text);
}

[data-theme="light"] .error-message {
    color: var(--text-secondary);
}

/* Footer Light */
[data-theme="light"] .footer {
    border-top-color: rgba(0, 0, 0, 0.08);
    color: var(--text-muted);
}

/* Buttons Light */
[data-theme="light"] .btn-ghost {
    background: #FFFFFF;
    border-color: rgba(0, 0, 0, 0.1);
    color: var(--text);
}

[data-theme="light"] .btn-ghost:active {
    background: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .btn-ghost:hover {
    background: rgba(0, 0, 0, 0.06);
    border-color: rgba(0, 0, 0, 0.15);
}

/* nav-back light */
[data-theme="light"] .nav-back {
    color: var(--text-secondary);
}

[data-theme="light"] .nav-back:active {
    background: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .nav-back svg {
    stroke: var(--text-secondary);
}

/* Quiz card icon light */
[data-theme="light"] .quiz-card-icon {
    background: rgba(108, 99, 255, 0.1);
}

/* Card arrow light */
[data-theme="light"] .card-arrow,
[data-theme="light"] .quiz-card-arrow {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.08);
    color: var(--text-muted);
}

/* Category header light */
[data-theme="light"] .category-header h1 {
    color: var(--text);
}

[data-theme="light"] .category-header p {
    color: var(--text-secondary);
}

[data-theme="light"] .category-header-icon {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* Section Title Light */
[data-theme="light"] .section-title {
    color: var(--text-secondary);
}

/* Submit Button Container Light */
[data-theme="light"] .submit-container {
    color: var(--text);
}

/* Theme Toggle Button */
.theme-toggle {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text);
    padding: 0;
    line-height: 1;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

[data-theme="light"] .theme-toggle {
    background: #FFFFFF;
    border-color: rgba(0, 0, 0, 0.1);
}

.theme-toggle:active {
    transform: scale(0.9);
}

@media (min-width: 1024px) {
    .theme-toggle:hover {
        background: var(--bg-card-hover);
        border-color: var(--border-hover);
        transform: rotate(15deg);
    }
    
    [data-theme="light"] .theme-toggle:hover {
        background: rgba(0, 0, 0, 0.06);
        border-color: rgba(0, 0, 0, 0.15);
    }
}

/* ===================== COLLEGE LANDING ===================== */
.college-landing {
    padding: 40px 0 60px;
    flex: 1;
    animation: fadeInUp 0.5s ease both;
}

.college-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    max-width: 560px;
    margin: 28px auto 0;
}

.college-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    animation: fadeInUp 0.5s ease both;
}

.college-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
}

.college-icon {
    font-size: 2.6rem;
    line-height: 1;
    margin-bottom: 12px;
}

.college-name {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text);
    margin-bottom: 6px;
}

.college-domain {
    font-size: 0.78rem;
    color: var(--text-muted);
    direction: ltr;
}

@media (min-width: 640px) {
    .college-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

/* ==========================================
   Video Modal & Dual-Action Cards
   ========================================== */
.quiz-actions {
    display: flex;
    gap: 10px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.btn-watch-video {
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
    border: 1px solid rgba(96, 165, 250, 0.3);
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.btn-watch-video:hover {
    background: rgba(59, 130, 246, 0.3);
    transform: translateY(-2px);
}

.video-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    padding: 15px;
}

.video-modal-content {
    position: relative;
    width: 100%;
    max-width: 800px;
    background: #181824;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.close-modal-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: #fff;
    font-size: 26px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.close-modal-btn:hover {
    background: var(--error);
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    background: #000;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.modal-footer-actions {
    padding: 15px;
    text-align: center;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--border);
}

.btn-start-quiz-from-modal {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px var(--primary-glow);
}

.btn-start-quiz-from-modal:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 20px var(--primary-glow);
}
/* ==============================================
   MOBILE RESPONSIVE & OVERFLOW FIXES (Screens <= 640px)
   ============================================== */
html, body {
    max-width: 100vw !important;
    overflow-x: hidden !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

*, *::before, *::after {
    box-sizing: border-box !important;
}

.container {
    width: 100% !important;
    max-width: 1200px !important;
    padding: 0 12px !important;
    box-sizing: border-box !important;
}

@media (max-width: 639px) {
    .track-selection-container {
        padding: 20px 10px !important;
        min-height: auto !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .track-title {
        font-size: 1.35rem !important;
        margin-bottom: 20px !important;
        word-break: break-word !important;
    }

    .track-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .track-card {
        padding: 20px 10px !important;
        gap: 12px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .track-icon-wrapper {
        width: 52px !important;
        height: 52px !important;
        font-size: 1.6rem !important;
        border-radius: 14px !important;
    }

    .track-card-title {
        font-size: 1.05rem !important;
        text-align: center !important;
    }

    .hero {
        padding: 24px 0 16px !important;
        width: 100% !important;
    }

    .hero-title {
        font-size: 1.5rem !important;
        line-height: 1.3 !important;
        word-break: break-word !important;
    }

    .hero-subtitle {
        font-size: 0.95rem !important;
    }

    .hero-badge {
        font-size: 0.75rem !important;
        padding: 4px 12px !important;
    }

    .categories-grid, .quizzes-grid {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
        width: 100% !important;
    }

    .category-card, .quiz-card {
        padding: 18px 14px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .modal-content, .video-modal-content {
        width: 94% !important;
        max-width: 100% !important;
        padding: 20px 14px !important;
        box-sizing: border-box !important;
    }

    .current-year-badge {
        font-size: 0.9rem !important;
        padding: 6px 14px !important;
        margin-bottom: 16px !important;
    }
}