/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

html {
    -webkit-text-size-adjust: 100%;
}

button, a, .lesson-node {
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
}

:root {
    --primary: #1CB0F6; /* Duolingo Sky Blue */
    --primary-dark: #1899D6;
    --primary-glow: rgba(28, 176, 246, 0.4);
    --secondary: #58CC02; /* Vibrant Emerald Green */
    --secondary-dark: #46A302;
    --secondary-glow: rgba(88, 204, 2, 0.4);
    --danger: #FF4B4B; /* Crimson Red */
    --danger-dark: #EA2B2B;
    --danger-glow: rgba(255, 75, 75, 0.4);
    --warning: #FFC800; /* Gold */
    --warning-dark: #D4A600;
    --warning-glow: rgba(255, 200, 0, 0.4);
    --orange: #FF9600; /* Fire Orange */
    --purple: #A855F7; /* Neon Violet */
    --pink: #EC4899; /* Sakura Pink */
    --cyan: #06B6D4; /* Ocean Cyan */
    --bg-color: #0f1720; /* Deep ambient slate */
    --bg-surface: #14212d; /* Surface dark */
    --bg-surface-elevated: #1a2c3a; /* Elevated surface */
    --text-main: #FFFFFF;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    --card-bg: rgba(22, 36, 49, 0.7);
    --card-border: rgba(255, 255, 255, 0.1);
    --card-border-glow: rgba(28, 176, 246, 0.3);
    --border-radius: 18px;
    --border-radius-sm: 12px;
    --border-radius-lg: 24px;
    --shadow-soft: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 25px rgba(28, 176, 246, 0.25);
    --shadow-glow-gold: 0 0 25px rgba(255, 200, 0, 0.3);
}

body {
    font-family: 'Be Vietnam Pro', 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(circle at 50% 0%, rgba(28, 176, 246, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 85% 30%, rgba(168, 85, 247, 0.08) 0%, transparent 45%),
        radial-gradient(circle at 15% 70%, rgba(88, 204, 2, 0.06) 0%, transparent 45%);
    background-attachment: fixed;
    background-size: 100% 100%;
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    font-feature-settings: 'kern' 1, 'liga' 1;
    letter-spacing: -0.01em;
}

h1, h2, h3 {
    font-family: 'Montserrat', 'Outfit', system-ui, sans-serif;
    letter-spacing: -0.02em;
    font-weight: 700;
}

/* Glassmorphism Panel */
.glass-panel {
    background: var(--card-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    box-shadow: 0 12px 36px 0 rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.12);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

/* Navbar */
.navbar {
    background: rgba(19, 31, 36, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 2px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    padding-top: env(safe-area-inset-top);
}

.nav-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 0.5rem;
}

.logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.logo-text {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: -0.5px;
}

.nav-actions {
    display: flex;
    gap: 0.8rem;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
}

#user-stats {
    display: flex;
    gap: 0.4rem;
    font-weight: 600;
    align-items: center;
    flex-wrap: nowrap !important;
    justify-content: flex-end;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 255, 255, 0.1);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.85rem;
    white-space: nowrap;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, background 0.2s ease;
    cursor: default;
}

.stat-item:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.15);
}

.stat-streak span { color: #ff9600; }
.stat-freeze span { color: #1CB0F6; }
.stat-hearts span { color: #FF4B4B; }
.stat-xp span { color: #FFC800; }
.stat-coins span { color: #FFD700; }
.stat-grade span { color: #a55eea; }

.stat-item span {
    font-weight: bold;
}

#user-menu {
    display: flex;
    gap: 1rem;
    align-items: center;
    font-size: 0.9rem;
}

/* Buttons */
.btn {
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: linear-gradient(180deg, #25baff 0%, #1cb0f6 60%, #149edc 100%);
    color: white;
    box-shadow: 0 4px 0 #0d83b9, 0 6px 20px rgba(28, 176, 246, 0.4);
    position: relative;
    overflow: hidden;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 0; left: -100%; width: 60%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
    transform: skewX(-20deg);
    transition: 0.75s;
}

.btn-primary:hover:not(:disabled)::after {
    left: 140%;
}

.btn-primary:hover:not(:disabled) {
    filter: brightness(1.08);
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #0d83b9, 0 8px 25px rgba(28, 176, 246, 0.5);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(2px);
    box-shadow: 0 2px 0 #0d83b9, 0 3px 10px rgba(28, 176, 246, 0.3);
}

.btn-primary:disabled {
    background-color: #37464F;
    color: #78858F;
    box-shadow: 0 4px 0 #202F36;
    cursor: not-allowed;
    filter: none;
}

.btn-success {
    background: linear-gradient(180deg, #66db08 0%, #58cc02 60%, #46a302 100%);
    color: white;
    box-shadow: 0 4px 0 #367d02, 0 6px 20px rgba(88, 204, 2, 0.4);
    position: relative;
    overflow: hidden;
}

.btn-success:hover:not(:disabled) {
    filter: brightness(1.08);
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #367d02, 0 8px 25px rgba(88, 204, 2, 0.5);
}

.btn-success:active:not(:disabled) {
    transform: translateY(2px);
    box-shadow: 0 2px 0 #367d02;
}

.btn-outline {
    background: rgba(255, 255, 255, 0.05);
    color: white;
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 0 rgba(0, 0, 0, 0.25);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
    box-shadow: 0 6px 0 rgba(0, 0, 0, 0.3);
}

.btn-outline:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.3);
}

.btn-full {
    width: 100%;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    border-radius: 8px;
}

/* Layout */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    flex-grow: 1;
    width: 100%;
}

.hidden {
    display: none !important;
}

/* Screen Management */
.screen {
    animation: fadeIn 0.3s ease;
}

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

/* ------------------------------------- */
/* SCREEN 1: ONBOARDING (Login / Grade)  */
/* ------------------------------------- */
.onboarding-card {
    padding: 2.5rem;
    text-align: center;
    max-width: 500px;
    margin: 1rem auto;
    position: relative;
}

/* Auth Page Dedicated Scroll & Layout */
html:has(body.auth-page),
body.auth-page {
    position: static !important;
    height: auto !important;
    min-height: 100% !important;
    min-height: 100dvh !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

body.auth-page {
    display: flex !important;
    flex-direction: column !important;
}

body.auth-page .container {
    overflow-y: visible !important;
    height: auto !important;
    min-height: auto !important;
    padding-bottom: 6rem !important;
}

body.auth-page #screen-onboarding .onboarding-card,
body.auth-page .onboarding-card {
    max-height: none !important;
    height: auto !important;
    overflow: visible !important;
    margin: 1.5rem auto 4rem auto !important;
}

.hero-title {
    font-size: clamp(1.5rem, 5vw + 1rem, 2.5rem);
    margin-bottom: 0.5rem;
}

.hero-title span {
    color: var(--secondary);
}

.hero-subtitle {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.auth-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid rgba(255,255,255,0.1);
}

.auth-tab {
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 0.75rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    position: relative;
}

.auth-tab.active {
    color: var(--primary);
}

.auth-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary);
    border-radius: 3px 3px 0 0;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

input {
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s;
}

input:focus {
    border-color: var(--secondary);
}

.grade-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.grade-btn {
    background: rgba(255,255,255,0.05);
    border: 2px solid rgba(255,255,255,0.1);
    color: white;
    padding: 1.5rem 1rem;
    border-radius: 16px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

.grade-btn:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-2px);
    border-color: var(--primary);
}

/* ------------------------------------- */
/* PLACEMENT TEST / THI THỬ TRÌNH ĐỘ      */
/* ------------------------------------- */
.placement-cta-card {
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.15), rgba(88, 204, 2, 0.15));
    border: 2px solid rgba(28, 176, 246, 0.4);
    border-radius: 20px;
    padding: 1.5rem;
    margin: 1.5rem 0;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    position: relative;
    overflow: hidden;
}

.placement-cta-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary);
    box-shadow: 0 12px 30px rgba(28, 176, 246, 0.3);
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.22), rgba(88, 204, 2, 0.22));
}

.placement-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(90deg, #ffd700, #ff9800);
    color: #000;
    font-size: 0.8rem;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.placement-card-body {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    text-align: left;
}

.placement-card-icon {
    width: 60px;
    height: 60px;
    min-width: 60px;
    border-radius: 16px;
    background: rgba(28, 176, 246, 0.2);
    border: 1.5px solid rgba(28, 176, 246, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary);
}

.placement-card-info h3 {
    margin: 0 0 6px 0;
    font-size: 1.3rem;
    color: #fff;
    display: flex;
    align-items: center;
}

.placement-card-info p {
    margin: 0;
    font-size: 0.92rem;
    color: #cbd5e1;
    line-height: 1.4;
}

.placement-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 2rem 0 1rem 0;
}

.placement-divider::before,
.placement-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.placement-divider span {
    padding: 0 1rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.placement-option-btn {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 1rem 1.2rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    color: #fff;
    font-size: 1.05rem;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
}

.placement-option-btn:hover {
    background: rgba(28, 176, 246, 0.15);
    border-color: var(--primary);
    transform: translateX(4px);
}

.placement-option-btn.selected {
    background: rgba(88, 204, 2, 0.2);
    border-color: #58cc02;
    color: #4ade80;
    font-weight: 700;
}

.placement-option-key {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.85rem;
    margin-right: 12px;
}

/* ------------------------------------- */
/* SCREEN 2: ROADMAP                     */
/* ------------------------------------- */
.roadmap-header {
    text-align: center;
    margin-bottom: 3rem;
}

.roadmap-header h2 {
    color: var(--secondary);
    font-size: 2rem;
}

.roadmap-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
}

.topic-section {
    width: 100%;
    margin-bottom: 4rem;
    position: relative;
}

.topic-title {
    background: var(--primary);
    color: white;
    padding: 1rem 2rem;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 2rem;
    font-size: 1.2rem;
    box-shadow: 0 4px 0 var(--primary-dark);
}

/* Winding Path Layout */
.lessons-path {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    position: relative;
}

/* The actual lesson node */
.lesson-node {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    position: relative;
    z-index: 2;
    background-color: var(--secondary);
    color: white;
    box-shadow: 0 6px 0 var(--secondary-dark);
    transition: transform 0.2s;
}

.lesson-node:hover:not(.locked) {
    transform: scale(1.1);
}

.lesson-node:active:not(.locked) {
    transform: translateY(4px) scale(1.05);
    box-shadow: 0 2px 0 var(--secondary-dark);
}

/* States */
.lesson-node.completed {
    background-color: var(--warning);
    box-shadow: 0 6px 0 var(--warning-dark);
    color: white;
}

.lesson-node.locked {
    background-color: #37464F;
    box-shadow: 0 6px 0 #202F36;
    color: #78858F;
    cursor: not-allowed;
}

/* Winding logic */
.lesson-node:nth-child(even) {
    transform: translateX(40px);
}
.lesson-node:nth-child(odd) {
    transform: translateX(-40px);
}
.lesson-node.completed:nth-child(even), .lesson-node.locked:nth-child(even) { transform: translateX(40px); }
.lesson-node.completed:nth-child(odd), .lesson-node.locked:nth-child(odd) { transform: translateX(-40px); }

.lesson-node:hover:not(.locked):nth-child(even) { transform: translateX(40px) scale(1.1); }
.lesson-node:hover:not(.locked):nth-child(odd) { transform: translateX(-40px) scale(1.1); }

/* Crown / Star icon for completed */
.lesson-node.completed::after {
    content: '⭐';
    position: absolute;
    top: -15px;
    right: -10px;
    font-size: 1.5rem;
}

/* ------------------------------------- */
/* SCREEN 3: QUIZ MODE                   */
/* ------------------------------------- */
.quiz-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 2rem;
}

.btn-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
}

.btn-close:hover {
    color: white;
}

.progress-bar-container {
    flex-grow: 1;
    height: 16px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--primary);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 8px;
}

.quiz-hearts {
    font-size: 1.2rem;
    color: var(--danger);
    font-weight: bold;
}

.quiz-body {
    padding: 3rem 2rem 10rem 2rem;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-bottom: 2rem;
}

.quiz-prompt {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

textarea {
    width: 100%;
    height: 120px;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.1rem;
    resize: none;
    outline: none;
    font-family: inherit;
    transition: border-color 0.3s;
}

textarea:focus {
    border-color: var(--secondary);
}

.btn-audio, .btn-record {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--secondary);
    color: white;
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    font-size: 1.1rem;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
    margin-bottom: 1rem;
    width: 100%;
}

.btn-audio:hover, .btn-record:hover {
    background: rgba(28, 176, 246, 0.1);
}

.recording-status {
    color: var(--danger);
    font-weight: bold;
    text-align: center;
    margin-bottom: 1rem;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

/* Quiz Footer & Results */
.quiz-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: var(--bg-color);
    border-top: 2px solid rgba(255, 255, 255, 0.08);
    z-index: 50;
    box-sizing: border-box;
    padding: 1.25rem 2rem;
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.quiz-footer > * {
    width: 100%;
    max-width: 800px;
}

#quiz-check-btn {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    justify-content: center;
    font-size: 1.15rem;
    font-weight: 700;
    padding: 1rem 1.5rem;
    border-radius: 16px;
    letter-spacing: 0.5px;
}

.quiz-result-box {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    box-sizing: border-box;
    padding: 1.25rem 1.5rem;
    border-radius: var(--border-radius);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.1rem;
    animation: slideUp 0.3s ease;
}

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

.quiz-result-box.correct {
    background-color: rgba(28, 176, 246, 0.2);
    border: 2px solid var(--primary);
    color: var(--primary);
}

.quiz-result-box.incorrect {
    background-color: rgba(255, 75, 75, 0.2);
    border: 2px solid var(--danger);
    color: #ff7979;
}

.quiz-result-box .btn {
    width: auto;
}

/* Loader */
.loader {
    text-align: center;
    color: var(--secondary);
    font-weight: bold;
    font-size: 1.2rem;
    animation: pulse 1s infinite;
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100dvh;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.modal.hidden {
    display: none;
}
.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    max-width: 90%;
    width: 400px;
    text-align: center;
}

/* Bottom Navigation */
/* ========================================================= */
/* APP TOP HEADER & FLOATING ISLAND BOTTOM NAVIGATION        */
/* ========================================================= */

.navbar.app-header {
    background: rgba(15, 23, 36, 0.85) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.35) !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 100 !important;
}

.stat-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.06);
    padding: 6px 11px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}

.stat-pill:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}

.stat-pill:active {
    transform: translateY(1px);
}

/* Floating Island Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 28px);
    max-width: 660px;
    background: rgba(15, 23, 36, 0.88);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    border-radius: 30px;
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.55), 0 0 25px rgba(28, 176, 246, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 6px 8px;
    z-index: 1000;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.bottom-nav.hidden,
#bottom-nav.hidden,
body.in-quiz #bottom-nav,
body.in-game #bottom-nav,
body:has(#screen-quiz:not(.hidden)) #bottom-nav,
body:has(#screen-snake:not(.hidden)) #bottom-nav,
body:has(#screen-hangman:not(.hidden)) #bottom-nav,
body:has(#screen-flappy:not(.hidden)) #bottom-nav,
body:has(#screen-worddrop:not(.hidden)) #bottom-nav,
body:has(#screen-memory:not(.hidden)) #bottom-nav,
body:has(#screen-ninja:not(.hidden)) #bottom-nav,
body:has(#screen-bubble:not(.hidden)) #bottom-nav,
body:has(#screen-racer:not(.hidden)) #bottom-nav,
body:has(#screen-scramble:not(.hidden)) #bottom-nav,
body:has(#screen-whack:not(.hidden)) #bottom-nav {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.nav-item {
    background: none;
    border: none;
    color: #94a3b8;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    font-size: 0.76rem;
    font-weight: 700;
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 18px;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    font-family: inherit;
    position: relative;
    flex: 1;
    max-width: 95px;
}

.nav-item:hover {
    color: #ffffff;
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.06);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.24), rgba(168, 85, 247, 0.2)) !important;
    color: #38bdf8 !important;
    border: 1px solid rgba(56, 189, 248, 0.4) !important;
    box-shadow: 0 4px 16px rgba(28, 176, 246, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

.nav-item.active .nav-icon {
    transform: scale(1.15);
    color: #38bdf8;
    filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.7));
}

.nav-icon {
    font-size: 1.25rem;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.2s ease, filter 0.2s ease;
}

/* ==========================================
   MINIGAMES STYLES (Memory & Hangman)
   ========================================== */

/* Memory Game */
.memory-card {
    position: relative;
    width: 100%;
    aspect-ratio: 3/4;
    transform-style: preserve-3d;
    transition: transform 0.5s cubic-bezier(0.4, 0.2, 0.2, 1);
    cursor: pointer;
}
.memory-card.flipped {
    transform: rotateY(180deg);
}
.memory-card.matched {
    visibility: hidden;
    opacity: 0;
    transition: visibility 0s 0.5s, opacity 0.5s linear;
}
.memory-face {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-weight: bold;
    text-align: center;
    padding: 5px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    word-break: break-word;
}
.memory-front {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    font-size: 2rem;
}
.memory-back {
    background: white;
    color: #121927;
    transform: rotateY(180deg);
    font-size: 1rem;
    border: 2px solid var(--primary);
}

/* Hangman Game */
.hangman-letter {
    width: 35px;
    height: 45px;
    border-bottom: 3px solid white;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--warning);
    text-transform: uppercase;
}
.hangman-key {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    font-family: inherit;
}
.hangman-key:hover:not(:disabled) {
    background: var(--primary);
    transform: translateY(-2px);
}
.hangman-key:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    background: transparent;
}
.hangman-key.wrong {
    background: #ff4b4b;
    border-color: #ff4b4b;
    opacity: 0.6;
}
.hangman-key.correct {
    background: #1cb0f6;
    border-color: #1cb0f6;
}

/* Admin Table */
.admin-table tbody tr {
    border-bottom: 1px solid rgba(255,255,255,0.1);
    transition: background 0.2s;
}
.admin-table tbody tr:hover {
    background: rgba(255,255,255,0.05);
}
.admin-table td {
    padding: 1rem 0.5rem;
    color: #e0e0e0;
}

/* ==========================================================================
   1. CHUẨN DESKTOP WEB APP (Màn hình máy tính & Laptop: min-width: 769px)
   ========================================================================== */
@media (min-width: 769px) {
    /* Khung sườn ứng dụng Web Desktop */
    .container {
        max-width: 1100px !important;
        margin: 0 auto !important;
        padding: 1.75rem 2rem calc(100px + env(safe-area-inset-bottom)) 2rem !important;
        width: 100% !important;
    }

    .nav-container {
        max-width: 1100px !important;
        padding: 0.75rem 2rem !important;
    }

    /* Thanh Điều Hướng Đáy: Biến thành Dock Nổi (Floating Dock / Command Bar) */
    .bottom-nav:not(.hidden) {
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: auto !important;
        min-width: 620px !important;
        max-width: 780px !important;
        bottom: 20px !important;
        border-radius: 30px !important;
        padding: 6px 14px !important;
        background: rgba(18, 28, 34, 0.9) !important;
        backdrop-filter: blur(24px) !important;
        -webkit-backdrop-filter: blur(24px) !important;
        border: 1px solid rgba(255, 255, 255, 0.15) !important;
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55), 0 0 25px rgba(28, 176, 246, 0.15) !important;
        gap: 8px !important;
    }

    .nav-item {
        padding: 8px 16px !important;
        border-radius: 18px !important;
        transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1) !important;
        min-width: 76px !important;
    }

    .nav-item:hover {
        background: rgba(255, 255, 255, 0.08) !important;
        transform: translateY(-2px) !important;
        color: #ffffff !important;
    }

    .nav-item.active {
        background: rgba(28, 176, 246, 0.18) !important;
        color: var(--primary) !important;
        box-shadow: inset 0 0 12px rgba(28, 176, 246, 0.22) !important;
    }

    /* Lưới Game & Nội dung Desktop: 3-4 cột rộng rãi */
    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)) !important;
        gap: 1.5rem !important;
    }

    .game-card {
        padding: 2rem 1.5rem !important;
        transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease, border-color 0.25s ease !important;
    }

    .game-card:hover {
        transform: translateY(-6px) scale(1.02) !important;
        border-color: rgba(28, 176, 246, 0.5) !important;
        box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4), 0 0 20px rgba(28, 176, 246, 0.25) !important;
    }

    /* Modal Hộp thoại trên Desktop: Căn giữa sang trọng, kích thước chuẩn */
    .modal {
        align-items: center !important;
        justify-content: center !important;
    }

    .modal-content, .avatar-modal-box, .story-dialog-content {
        max-width: 540px !important;
        border-radius: 24px !important;
        border: 1.5px solid rgba(28, 176, 246, 0.4) !important;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(28, 176, 246, 0.2) !important;
        animation: zoomInDesktop 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
    }

    @keyframes zoomInDesktop {
        from { opacity: 0; transform: scale(0.95); }
        to { opacity: 1; transform: scale(1); }
    }

    /* Thanh cuộn cao cấp chuẩn Desktop Web App */
    ::-webkit-scrollbar {
        width: 8px;
        height: 8px;
    }
    ::-webkit-scrollbar-track {
        background: rgba(15, 23, 42, 0.6);
    }
    ::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.2);
        border-radius: 8px;
    }
    ::-webkit-scrollbar-thumb:hover {
        background: rgba(28, 176, 246, 0.6);
    }

    /* Nút bấm Desktop: Hiệu ứng hover nổi bật */
    .btn:hover:not(:disabled) {
        transform: translateY(-2px);
        filter: brightness(1.08);
    }
}

/* ==========================================================================
   2. CHUẨN MOBILE NATIVE APP (Điện thoại & Touch Devices: max-width: 768px)
   ========================================================================== */
@media (max-width: 768px) {
    /* Khung sườn Native App di động: Tràn viền và chống giật nảy */
    :root {
        --mobile-tab-height: 58px;
    }

    body:has(.bottom-nav) {
        height: 100dvh;
        width: 100vw;
        position: fixed;
        overflow: hidden;
        overscroll-behavior: none;
        -webkit-user-select: none;
        user-select: none;
    }

    body:has(.landing-container) {
        position: static !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        height: auto !important;
        min-height: 100% !important;
        width: 100% !important;
        -webkit-user-select: auto !important;
        user-select: auto !important;
    }

    body:has(.landing-container) .landing-container {
        height: auto !important;
        min-height: 100vh !important;
        overflow-y: visible !important;
        padding-bottom: 6.5rem !important;
    }

    .container {
        margin: 0 auto;
        padding: 0.75rem 12px calc(var(--mobile-tab-height) + env(safe-area-inset-bottom) + 18px) 12px !important;
        overflow-y: auto !important;
        overscroll-behavior-y: contain !important;
        -webkit-overflow-scrolling: touch !important;
    }

    /* Thanh Header Top App: Gọn nhẹ, hỗ trợ tai thỏ / notch */
    .navbar.app-header {
        padding-top: max(8px, env(safe-area-inset-top)) !important;
        padding-bottom: 6px !important;
        padding-left: 10px !important;
        padding-right: 10px !important;
    }

    .nav-container {
        padding: 0 !important;
    }

    .logo-text {
        font-size: 1.05rem !important;
    }

    .logo-icon {
        width: 32px !important;
        height: 32px !important;
    }

    .stat-pill {
        padding: 4px 7px !important;
        font-size: 0.76rem !important;
        gap: 3px !important;
        flex-shrink: 0 !important;
        white-space: nowrap !important;
    }

    .top-nav-stats {
        gap: 4px !important;
        flex-wrap: nowrap !important;
    }

    .navbar.app-header .logo-subtext {
        display: none !important;
    }

    /* Thanh Bottom Tab Bar: Floating Island Dock trên Mobile */
    .bottom-nav:not(.hidden),
    .bottom-nav {
        position: fixed !important;
        bottom: 8px !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        width: calc(100% - 16px) !important;
        max-width: 480px !important;
        border-radius: 28px !important;
        border: 1px solid rgba(255, 255, 255, 0.14) !important;
        height: auto !important;
        padding: 5px 8px !important;
        background: rgba(15, 23, 36, 0.92) !important;
        backdrop-filter: blur(20px) !important;
        -webkit-backdrop-filter: blur(20px) !important;
        display: flex !important;
        justify-content: space-around !important;
        align-items: center !important;
        z-index: 1000 !important;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(28, 176, 246, 0.18) !important;
    }

    .nav-item {
        flex: 1 !important;
        padding: 3px 2px !important;
        font-size: 0.72rem !important;
        gap: 2px !important;
        min-height: 48px !important; /* Đạt chuẩn Touch Target 48px của Apple/Google */
        justify-content: center !important;
    }

    .nav-icon {
        font-size: 1.25rem !important;
        width: 24px !important;
        height: 24px !important;
    }

    /* Phản hồi xúc giác Haptic Touch khi chạm (:active) */
    button:active, 
    .btn:active, 
    .nav-item:active, 
    .lesson-node:active, 
    .game-card:active, 
    .stat-pill:active, 
    .feedback-topic-chip:active,
    .feature-card:active {
        transform: scale(0.94) !important;
        transition: transform 0.08s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
    }

    /* Triệt tiêu độ trễ chạm và viền highlight màu xanh của Webkit */
    * {
        -webkit-tap-highlight-color: transparent !important;
    }

    /* Cho phép bôi đen, chọn văn bản và gõ mượt mà trên mobile */
    input, textarea, select, [contenteditable="true"] {
        -webkit-user-select: text !important;
        user-select: text !important;
        font-size: 16px !important; /* Ngăn chặn Safari iOS tự động phóng to (Auto-zoom) khi gõ phím */
    }

    /* Modal dạng Bottom Sheet chuẩn Native App di động */
    .modal {
        align-items: flex-end !important;
        padding: 0 !important;
    }

    .modal-content, 
    .avatar-modal-box, 
    .story-dialog-content,
    #modal-feedback > .glass-panel,
    #modal-report-question > .glass-panel,
    #modal-my-feedbacks > .glass-panel,
    #modal-change-password > .glass-panel,
    #modal-avatar-crop > .glass-panel {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        border-bottom-left-radius: 0 !important;
        border-bottom-right-radius: 0 !important;
        border-top-left-radius: 24px !important;
        border-top-right-radius: 24px !important;
        max-height: 88dvh !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        padding: 1.25rem 1.1rem calc(22px + env(safe-area-inset-bottom)) 1.1rem !important;
        box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(28, 176, 246, 0.2) !important;
        animation: slideUpMobile 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
    }

    /* Thanh chỉ thị kéo thả (Drag handle) ở đầu Bottom Sheet */
    .modal-drag-indicator {
        width: 44px;
        height: 5px;
        background: rgba(255, 255, 255, 0.3);
        border-radius: 3px;
        margin: -4px auto 14px auto;
        display: block !important;
    }

    /* Tối ưu Feedback components trên Mobile */
    #feedback-categories-box {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }

    .feedback-topic-chip {
        padding: 8px 10px !important;
        font-size: 0.82rem !important;
        justify-content: center !important;
        min-height: 38px !important;
        border-radius: 12px !important;
    }

    .star-rating-container {
        gap: 12px !important;
        margin: 8px 0 !important;
    }

    .star-btn {
        font-size: 2.1rem !important;
        min-width: 44px !important;
        min-height: 44px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .feedback-input {
        font-size: 16px !important;
        padding: 12px 14px !important;
        border-radius: 12px !important;
        background: rgba(15, 23, 42, 0.8) !important;
        border: 1px solid rgba(255, 255, 255, 0.18) !important;
    }

    .report-reason-grid {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }

    .report-reason-btn {
        min-height: 44px !important;
        font-size: 0.86rem !important;
        padding: 10px 14px !important;
    }

    /* Chế độ xem Admin Feedbacks: ẩn bảng rộng, hiện thẻ card tiện lợi trên mobile */
    .admin-fb-desktop-view {
        display: none !important;
    }

    .admin-fb-mobile-view {
        display: flex !important;
    }

    @keyframes slideUpMobile {
        from { transform: translateY(100%); opacity: 0.6; }
        to { transform: translateY(0); opacity: 1; }
    }

    /* Bố cục Game trên Mobile */
    .games-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        margin-top: 1rem !important;
    }

    .game-card {
        padding: 1.2rem 0.75rem !important;
    }

    .game-icon {
        font-size: 2.4rem !important;
        margin-bottom: 0.5rem !important;
    }

    .game-card h3 {
        font-size: 0.95rem !important;
    }

    .game-card p {
        font-size: 0.75rem !important;
        line-height: 1.25 !important;
    }

    /* Học tập & Bài Quiz */
    .lesson-node {
        width: 58px;
        height: 58px;
        font-size: 1.15rem;
    }

    .quiz-body {
        padding: 1rem 0.5rem 6rem 0.5rem !important;
    }

    .quiz-prompt {
        font-size: 1.15rem !important;
    }

    .roadmap-header h2 {
        font-size: 1.35rem !important;
    }

    .glass-panel {
        padding: 1rem !important;
    }
}

/* ==========================================================================
   3. MOBILE MÀN HÌNH NHỎ (Dưới 480px)
   ========================================================================== */
@media (max-width: 480px) {
    .logo-text {
        font-size: 0.95rem !important;
    }
    
    .logo-icon {
        width: 28px !important;
        height: 28px !important;
    }
    
    .onboarding-card {
        padding: 1rem 0.75rem !important;
    }

    .lesson-node {
        width: 50px !important;
        height: 50px !important;
        font-size: 1rem !important;
    }
    
    .quiz-result-box {
        flex-direction: column !important;
        text-align: center !important;
        gap: 0.75rem !important;
    }
    
    .quiz-result-box .btn {
        width: 100% !important;
    }

    .top-nav-stats {
        gap: 4px !important;
    }
}

/* ==========================================================================
   4. CHẾ ĐỘ CÀI ĐẶT PWA NATIVE (Standalone Display Mode)
   ========================================================================== */
@media (display-mode: standalone) {
    body {
        -webkit-touch-callout: none !important;
    }

    .navbar.app-header {
        padding-top: calc(12px + env(safe-area-inset-top)) !important;
    }

    .bottom-nav {
        padding-bottom: calc(6px + env(safe-area-inset-bottom)) !important;
    }
}

/* ==========================================
   APP-LIKE FULLSCREEN FIX (NO SCROLL)
   ========================================== */
html:not(:has(body.auth-page)):not(:has(.landing-container)) {
    height: 100dvh;
    margin: 0;
    overflow: hidden;
}

body:not(.auth-page):not(:has(.landing-container)) {
    height: 100dvh;
    margin: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.container {
    flex-grow: 1;
    overflow-y: auto;
    padding-bottom: calc(80px + env(safe-area-inset-bottom));
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
}

/* Make Canvas games fill available space exactly without breaking coordinates */
canvas {
    width: 100% !important;
    height: auto !important;
    max-height: calc(100dvh - 220px) !important;
    aspect-ratio: 320 / 480;
    margin: 0 auto !important;
    display: block !important;
}

#snake-canvas {
    aspect-ratio: 320 / 400 !important;
}

/* Make Memory Game more compact */
#memory-grid {
    grid-template-columns: repeat(4, 1fr) !important;
    max-width: 500px !important;
    gap: 8px !important;
}
.memory-card {
    aspect-ratio: 1/1 !important;
}

/* Mascot Float Animation */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* Leaderboard Table Styles */
#screen-leaderboard table td {
    border-bottom: 1px solid rgba(255,255,255,0.08);
    vertical-align: middle;
}
#screen-leaderboard table tr:hover {
    background: rgba(255,255,255,0.05);
}

.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.9rem;
    margin: 0 auto;
}
.rank-badge.rank-1 {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.25), rgba(255, 170, 0, 0.35));
    border: 1.5px solid #ffd700;
    color: #ffd700;
    box-shadow: 0 0 12px rgba(255, 215, 0, 0.35);
}
.rank-badge.rank-2 {
    background: linear-gradient(135deg, rgba(192, 192, 192, 0.25), rgba(220, 220, 220, 0.35));
    border: 1.5px solid #c0c0c0;
    color: #e2e8f0;
    box-shadow: 0 0 10px rgba(192, 192, 192, 0.25);
}
.rank-badge.rank-3 {
    background: linear-gradient(135deg, rgba(205, 127, 50, 0.25), rgba(184, 115, 51, 0.35));
    border: 1.5px solid #cd7f32;
    color: #f6ad55;
    box-shadow: 0 0 10px rgba(205, 127, 50, 0.25);
}
.rank-badge.rank-normal {
    background: rgba(255, 255, 255, 0.06);
    color: #a0aec0;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.leaderboard-row-me {
    background: rgba(28, 176, 246, 0.12) !important;
    border-left: 3px solid var(--primary) !important;
}
.leaderboard-row-me:hover {
    background: rgba(28, 176, 246, 0.2) !important;
}

/* ========================================================= */
/* LANDING PAGE MODERN OVERHAUL STYLES                       */
/* ========================================================= */

#screen-landing {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 2rem;
    padding-bottom: 5rem;
    animation: fadeIn 0.6s ease;
    width: 100%;
}

.landing-container {
    max-width: 1180px !important;
    padding: 1rem 1.5rem 4rem 1.5rem !important;
}

.landing-navbar {
    background: rgba(15, 23, 42, 0.8) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.landing-hero {
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 40px;
    margin-bottom: 70px;
    padding-top: 1rem;
}

@media(min-width: 900px) {
    .landing-hero {
        flex-direction: row;
        text-align: left;
        gap: 60px;
    }

    .landing-text {
        align-items: flex-start !important;
        text-align: left !important;
    }
}

.landing-text {
    flex: 1.1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0;
}

/* Badge lấp lánh */
.landing-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.15), rgba(168, 85, 247, 0.2));
    border: 1px solid rgba(56, 189, 248, 0.35);
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.8px;
    color: #38bdf8;
    margin-bottom: 1.2rem;
    box-shadow: 0 4px 15px rgba(28, 176, 246, 0.2);
    animation: pulseBadge 3s ease-in-out infinite;
}

@keyframes pulseBadge {
    0%, 100% { transform: scale(1); box-shadow: 0 4px 15px rgba(28, 176, 246, 0.2); }
    50% { transform: scale(1.02); box-shadow: 0 6px 22px rgba(56, 189, 248, 0.4); }
}

.landing-title {
    font-family: 'Montserrat', 'Outfit', sans-serif;
    font-size: clamp(2.2rem, 5vw + 1rem, 3.8rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 1.2rem;
    letter-spacing: -0.03em;
    background: linear-gradient(135deg, #ffffff 40%, #7dd3fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 4px 20px rgba(56, 189, 248, 0.25));
}

.landing-subtitle {
    font-size: 1.12rem;
    color: #cbd5e1;
    margin-bottom: 2rem;
    line-height: 1.7;
    max-width: 520px;
}

.landing-subtitle strong {
    color: #fff;
    font-weight: 600;
}

.landing-cta-group {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    width: 100%;
    max-width: 460px;
    margin-bottom: 2.5rem;
}

.landing-btn {
    flex: 1 1 200px;
    padding: 14px 24px;
    font-size: 1.05rem;
    font-weight: 700;
    border-radius: 16px;
    min-height: 52px;
}

.landing-btn-secondary {
    flex: 1 1 180px;
    padding: 14px 20px;
    font-size: 0.98rem;
    font-weight: 600;
    border-radius: 16px;
    min-height: 52px;
}

/* Social Proof Metric Bar */
.landing-metrics-bar {
    display: flex;
    align-items: center;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px 20px;
    gap: 14px;
    width: 100%;
    max-width: 580px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

@media (max-width: 540px) {
    .landing-metrics-bar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 12px 10px;
        padding: 14px;
    }
    .landing-metrics-bar .metric-divider {
        display: none;
    }
}

.metric-item {
    display: flex;
    flex-direction: column;
    flex: 1;
    text-align: center;
}

.metric-value {
    font-size: 1.15rem;
    font-weight: 800;
    color: #38bdf8;
    line-height: 1.2;
}

.metric-label {
    font-size: 0.72rem;
    color: #94a3b8;
    font-weight: 500;
    white-space: nowrap;
}

.metric-divider {
    width: 1px;
    height: 28px;
    background: rgba(255, 255, 255, 0.12);
}

/* Hero Mascot Card */
.landing-image {
    flex: 0.9;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.landing-hero-card {
    position: relative;
    border-radius: 28px;
    padding: 10px;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.15);
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.7), 0 0 40px rgba(28, 176, 246, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-card-glow {
    position: absolute;
    top: -20px; left: -20px; right: -20px; bottom: -20px;
    background: radial-gradient(circle, rgba(28, 176, 246, 0.25) 0%, rgba(168, 85, 247, 0.15) 50%, transparent 70%);
    filter: blur(30px);
    z-index: 0;
    pointer-events: none;
}

.landing-hero-img {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
    border-radius: 22px;
    animation: floatMascot 4.5s ease-in-out infinite;
    display: block;
}

.hero-floating-badge {
    position: absolute;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(15, 23, 42, 0.88);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    white-space: nowrap;
}

.hero-badge-top {
    top: 20px;
    left: -20px;
    animation: floatSlow 5s ease-in-out infinite;
}

.hero-badge-bottom {
    bottom: 25px;
    right: -15px;
    animation: floatSlow 5s ease-in-out infinite 2.5s;
}

@keyframes floatSlow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* Bento Grid Tính Năng (Số chẵn: 6 thẻ cân xứng 3x2 hoặc 2x3) */
.landing-bento-section {
    width: 100%;
    margin-top: 1rem;
}

.sub-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    color: #ffd700;
    background: rgba(255, 215, 0, 0.12);
    border: 1px solid rgba(255, 215, 0, 0.3);
    padding: 4px 12px;
    border-radius: 20px;
}

.section-title {
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.02em;
}

.bento-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    width: 100%;
}

@media(min-width: 680px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(min-width: 1080px) {
    .bento-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.bento-card {
    background: rgba(20, 33, 45, 0.75);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 26px 24px;
    display: flex;
    gap: 18px;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease, border-color 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.bento-card:hover {
    transform: translateY(-6px);
    border-color: rgba(56, 189, 248, 0.4);
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.5), 0 0 30px rgba(56, 189, 248, 0.15);
}

.bento-icon-wrapper {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.icon-blue { background: rgba(28, 176, 246, 0.15); color: #38bdf8; border: 1px solid rgba(28, 176, 246, 0.3); }
.icon-green { background: rgba(88, 204, 2, 0.15); color: #4ade80; border: 1px solid rgba(88, 204, 2, 0.3); }
.icon-orange { background: rgba(255, 150, 0, 0.15); color: #fb923c; border: 1px solid rgba(255, 150, 0, 0.3); }
.icon-purple { background: rgba(168, 85, 247, 0.15); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.3); }
.icon-gold { background: rgba(255, 200, 0, 0.15); color: #fbbf24; border: 1px solid rgba(255, 200, 0, 0.3); }
.icon-cyan { background: rgba(6, 182, 212, 0.15); color: #22d3ee; border: 1px solid rgba(6, 182, 212, 0.3); }

.bento-content h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 8px;
}

.bento-content p {
    color: #94a3b8;
    font-size: 0.95rem;
    line-height: 1.6;
}

.bento-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.tag-pill {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #38bdf8;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.78rem;
    font-weight: 600;
}

/* ==========================================================================
   LANDING PAGE MOBILE OPTIMIZATION (max-width: 768px & 480px)
   ========================================================================== */
@media (max-width: 768px) {
    /* Thanh Navbar Landing Page trên điện thoại: Gọn 1 hàng, chống vỡ layout */
    .landing-navbar {
        padding: 0 !important;
        position: sticky !important;
        top: 0 !important;
        z-index: 1000 !important;
    }

    .landing-navbar .nav-container {
        padding: 0.4rem 0.5rem !important;
        gap: 4px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .landing-navbar .logo {
        gap: 4px !important;
        flex-shrink: 0 !important;
    }

    .landing-navbar .logo-icon {
        width: 26px !important;
        height: 26px !important;
    }

    .landing-navbar .logo-text {
        font-size: 0.9rem !important;
        line-height: 1.1 !important;
    }

    .landing-navbar .logo-subtext {
        display: none !important;
    }

    /* Giữ tất cả nút điều hướng trên 1 hàng duy nhất (không bị rớt dòng thành 3 tầng) */
    .landing-navbar .nav-actions {
        display: flex !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 4px !important;
        justify-content: flex-end !important;
        flex-shrink: 1 !important;
    }

    /* Nút đổi Theme: Ẩn chữ "Disney Sáng", biến thành nút tròn 28px thanh lịch */
    .landing-navbar .theme-toggle-btn {
        width: 28px !important;
        height: 28px !important;
        min-width: 28px !important;
        padding: 0 !important;
        border-radius: 50% !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        flex-shrink: 0 !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25) !important;
    }

    .landing-navbar .theme-toggle-btn .theme-btn-text {
        display: none !important;
    }

    .landing-navbar .theme-toggle-btn i {
        font-size: 0.82rem !important;
        margin: 0 !important;
    }

    /* Nút Học Thử Ngay */
    .landing-navbar .landing-nav-trial-btn {
        padding: 4px 6px !important;
        font-size: 0.72rem !important;
        font-weight: 700 !important;
        text-transform: none !important;
        letter-spacing: 0 !important;
        border-radius: 8px !important;
        white-space: nowrap !important;
        display: inline-flex !important;
        align-items: center !important;
        gap: 3px !important;
        box-shadow: 0 2px 0 #0284c7 !important;
    }

    .landing-navbar .landing-nav-trial-btn i {
        font-size: 0.68rem !important;
        margin-right: 0 !important;
    }

    /* Nút Đăng Nhập */
    .landing-navbar #nav-login-btn {
        padding: 4px 6px !important;
        font-size: 0.72rem !important;
        font-weight: 600 !important;
        text-transform: none !important;
        letter-spacing: 0 !important;
        border-radius: 8px !important;
        white-space: nowrap !important;
        display: inline-flex !important;
        align-items: center !important;
        gap: 3px !important;
    }

    .landing-navbar #nav-login-btn i {
        font-size: 0.68rem !important;
        margin-right: 0 !important;
    }

    /* Hero section: Tối ưu khoảng cách và tỷ lệ */
    .landing-hero {
        flex-direction: column-reverse !important;
        gap: 20px !important;
        margin-bottom: 30px !important;
        padding-top: 0.5rem !important;
    }

    .landing-image {
        width: 100% !important;
        max-width: 290px !important;
        margin: 0 auto !important;
    }

    .landing-hero-card {
        border-radius: 20px !important;
        padding: 6px !important;
        width: 100% !important;
        max-width: 280px !important;
        box-shadow: 0 16px 36px -10px rgba(0, 0, 0, 0.65), 0 0 24px rgba(28, 176, 246, 0.2) !important;
    }

    .landing-hero-img {
        max-width: 268px !important;
        border-radius: 16px !important;
    }

    .hero-floating-badge {
        padding: 5px 10px !important;
        font-size: 0.72rem !important;
        gap: 5px !important;
        border-radius: 14px !important;
    }

    .hero-badge-top {
        top: 8px !important;
        left: -6px !important;
    }

    .hero-badge-bottom {
        bottom: 8px !important;
        right: -6px !important;
    }

    .landing-text {
        width: 100% !important;
    }

    .landing-badge {
        font-size: 0.72rem !important;
        padding: 4px 10px !important;
        margin-bottom: 0.75rem !important;
    }

    .landing-title {
        font-size: 1.65rem !important;
        line-height: 1.22 !important;
        margin-bottom: 0.75rem !important;
    }

    .landing-subtitle {
        font-size: 0.88rem !important;
        line-height: 1.55 !important;
        margin-bottom: 1.25rem !important;
    }

    .landing-cta-group {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 8px !important;
        margin-bottom: 1.5rem !important;
    }

    .landing-btn {
        width: 100% !important;
        min-height: 46px !important;
        padding: 10px 16px !important;
        font-size: 0.95rem !important;
        border-radius: 12px !important;
    }

    .landing-btn-secondary {
        width: 100% !important;
        min-height: 44px !important;
        padding: 10px 16px !important;
        font-size: 0.88rem !important;
        border-radius: 12px !important;
    }

    .landing-metrics-bar {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px 10px !important;
        padding: 10px 12px !important;
    }

    .metric-value {
        font-size: 1rem !important;
    }

    .metric-label {
        font-size: 0.68rem !important;
    }

    .metric-divider {
        display: none !important;
    }

    .bento-card {
        padding: 18px 16px !important;
        border-radius: 18px !important;
    }

    .bento-content h3 {
        font-size: 1.1rem !important;
    }

    .bento-content p {
        font-size: 0.85rem !important;
    }
}

@media (max-width: 380px) {
    .landing-navbar .logo-subtext {
        display: none !important;
    }
    .landing-navbar .logo-text {
        font-size: 0.95rem !important;
    }
    .landing-navbar .landing-nav-trial-btn {
        padding: 5px 7px !important;
        font-size: 0.7rem !important;
    }
    .landing-navbar #nav-login-btn {
        padding: 5px 7px !important;
        font-size: 0.7rem !important;
    }
    .landing-title {
        font-size: 1.45rem !important;
    }
}

/* ============================================== */
/* QUESTION ILLUSTRATION / IMAGE CARD             */
/* ============================================== */
.quiz-image-container {
    width: 100%;
    max-width: 540px;
    margin: 0 auto 1.4rem auto;
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInZoom 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.quiz-image-card {
    position: relative;
    width: 100%;
    background: rgba(15, 23, 42, 0.75);
    border: 2px solid rgba(56, 189, 248, 0.3);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45), 0 0 25px rgba(28, 176, 246, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
    backdrop-filter: blur(12px);
    transition: all 0.3s ease;
}

.quiz-image-card:hover {
    border-color: var(--primary);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55), 0 0 30px rgba(28, 176, 246, 0.35);
    transform: translateY(-2px);
}

.quiz-question-img {
    max-width: 100%;
    max-height: 220px;
    width: auto;
    height: auto;
    border-radius: 14px;
    object-fit: contain;
    display: block;
    cursor: pointer;
    transition: transform 0.25s ease;
}

.quiz-question-img:hover {
    transform: scale(1.02);
}

.quiz-image-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    background: rgba(15, 23, 42, 0.88);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.45);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.3px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
    pointer-events: none;
    z-index: 2;
}

.quiz-image-zoom-btn {
    position: absolute;
    bottom: 14px;
    right: 14px;
    background: rgba(15, 23, 42, 0.85);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.88rem;
    cursor: pointer;
    transition: all 0.2s;
    z-index: 2;
}

.quiz-image-zoom-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: scale(1.12);
}

@keyframes fadeInZoom {
    from {
        opacity: 0;
        transform: scale(0.96) translateY(6px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@media (max-width: 640px) {
    .quiz-question-img {
        max-height: 180px;
    }
    .quiz-image-container {
        margin-bottom: 1rem;
    }
}

/* ============================================== */
/* MULTIPLE CHOICE QUESTIONS (MCQ) - DUOLINGO STYLE */
/* ============================================== */
.mcq-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 14px;
    width: 100%;
    max-width: 650px;
    margin: 1.5rem auto;
}

.mcq-card {
    background: rgba(255, 255, 255, 0.07);
    border: 2px solid rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 0 rgba(0, 0, 0, 0.2);
    user-select: none;
}

.mcq-card:hover {
    background: rgba(28, 176, 246, 0.1);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 0 rgba(0, 0, 0, 0.3), 0 0 14px rgba(28, 176, 246, 0.25);
}

.mcq-card:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.3);
}

/* Selected option: Brand Primary Blue (#1CB0F6) */
.mcq-card.selected {
    background: rgba(28, 176, 246, 0.18) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 4px 0 var(--primary-dark), 0 0 16px var(--primary-glow) !important;
}

/* Confirmed Correct option: Emerald Green (#58CC02) */
.mcq-card.correct {
    background: rgba(88, 204, 2, 0.22) !important;
    border-color: var(--secondary) !important;
    box-shadow: 0 4px 0 var(--secondary-dark), 0 0 16px var(--secondary-glow) !important;
}

/* Confirmed Incorrect option: Crimson Red (#FF4B4B) */
.mcq-card.incorrect {
    background: rgba(255, 75, 75, 0.22) !important;
    border-color: var(--danger) !important;
    box-shadow: 0 4px 0 var(--danger-dark), 0 0 16px var(--danger-glow) !important;
}

.mcq-badge {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    flex-shrink: 0;
    transition: all 0.2s;
}

.mcq-card.selected .mcq-badge {
    background: var(--primary) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 0 var(--primary-dark);
}

.mcq-card.correct .mcq-badge {
    background: var(--secondary) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 0 var(--secondary-dark);
}

.mcq-card.incorrect .mcq-badge {
    background: var(--danger) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 0 var(--danger-dark);
}

.mcq-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
    text-align: left;
    flex: 1;
    word-break: break-word;
}

/* ============================================== */
/* CRYSTAL-CLEAR AUDIO CONTROLS                   */
/* ============================================== */
.audio-controls-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin: 1.2rem 0;
    flex-wrap: wrap;
}

.btn-audio-main {
    background: linear-gradient(135deg, #1CB0F6, #0D8BD9);
    border: none;
    color: white;
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 1.15rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 0 #0968A5, 0 10px 20px rgba(28, 176, 246, 0.3);
    transition: all 0.15s ease;
}

.btn-audio-main:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 0 #0968A5, 0 12px 25px rgba(28, 176, 246, 0.4);
}

.btn-audio-main:active {
    transform: translateY(3px);
    box-shadow: 0 2px 0 #0968A5;
}

.btn-audio-slow {
    background: rgba(255, 200, 0, 0.15);
    border: 2px solid var(--warning);
    color: var(--warning);
    padding: 12px 22px;
    border-radius: 30px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 0 rgba(212, 166, 0, 0.6);
    transition: all 0.15s ease;
}

.btn-audio-slow:hover {
    background: rgba(255, 200, 0, 0.25);
    transform: translateY(-2px);
}

.btn-audio-slow:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 rgba(212, 166, 0, 0.6);
}

/* ============================================== */
/* SINGLE-WORD FILL-IN-THE-BLANK                 */
/* ============================================== */
.fill-blank-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 24px;
    margin: 1.5rem auto;
    max-width: 600px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.fill-blank-sentence {
    font-size: 1.35rem;
    font-weight: 600;
    line-height: 2;
    color: #fff;
    margin-bottom: 1.5rem;
    text-align: center;
}

.single-blank-input {
    display: inline-block;
    width: 220px;
    max-width: 90%;
    margin: 0 8px;
    padding: 10px 16px;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--warning);
    background: rgba(0, 0, 0, 0.4);
    border: 2px dashed var(--secondary);
    border-radius: 12px;
    text-align: center;
    outline: none;
    transition: all 0.2s ease;
}

.single-blank-input:focus {
    border-style: solid;
    border-color: var(--primary);
    background: rgba(0, 0, 0, 0.6);
    box-shadow: 0 0 15px rgba(28, 176, 246, 0.4);
}

/* ============================================== */
/* LISTENING REPOSITORY HUB                       */
/* ============================================== */
.listening-hub-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.listening-hub-header h2 {
    font-size: 2.2rem;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

/* ==========================================================================
   DUOLINGO x ELSA SPEAK HYBRID LISTENING HUB & CARDS
   ========================================================================== */
.listening-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 1.5rem;
    background: rgba(22, 36, 49, 0.85);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    padding: 10px 16px;
    border-radius: 20px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-bottom: 4px solid rgba(11, 18, 25, 0.85);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .listening-toolbar {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #e2e8f0;
    border-bottom: 4px solid #cbd5e1;
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.04);
}

.grade-filter-scroll {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 4px 2px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    flex: 1;
}

.grade-filter-scroll::-webkit-scrollbar {
    display: none;
}

.grade-pill {
    padding: 7px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(255, 255, 255, 0.12);
    border-bottom: 3px solid rgba(0, 0, 0, 0.5);
    color: #cbd5e1;
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.15s ease;
    user-select: none;
}

.grade-pill:hover {
    background: rgba(28, 176, 246, 0.25);
    color: #38bdf8;
    transform: translateY(-1px);
}

.grade-pill:active {
    transform: translateY(2px);
    border-bottom-width: 1px;
}

.grade-pill.active {
    background: #58cc02;
    border-color: #46a302;
    border-bottom: 4px solid #388401;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(88, 204, 2, 0.35);
}

[data-theme="light"] .grade-pill {
    background: #f1f5f9;
    border: 2px solid #e2e8f0;
    border-bottom: 3px solid #cbd5e1;
    color: #475569;
}

[data-theme="light"] .grade-pill:hover {
    background: #e2e8f0;
    color: #0284c7;
}

[data-theme="light"] .grade-pill.active {
    background: #58cc02;
    border-color: #46a302;
    border-bottom: 4px solid #388401;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(88, 204, 2, 0.25);
}

/* AI Generate Button - Duolingo Diamond League */
.btn-ai-listening {
    background: linear-gradient(135deg, #8b5cf6, #d946ef);
    color: white;
    border: none;
    border-bottom: 4px solid #7c3aed;
    padding: 8px 18px;
    border-radius: 16px;
    font-size: 0.88rem;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.35);
    transition: all 0.15s ease;
    white-space: nowrap;
    user-select: none;
}

.btn-ai-listening:hover {
    background: linear-gradient(135deg, #9333ea, #e879f9);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5);
}

.btn-ai-listening:active {
    transform: translateY(2px);
    border-bottom-width: 1px;
}

.btn-ai-listening:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Listening Grid */
.listening-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 22px;
    margin-top: 1.25rem;
    align-items: stretch;
}

/* Listening Card (Duolingo 3D Tactile x ELSA Sleek Minimal) */
.listening-card {
    background: rgba(22, 36, 49, 0.92);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-bottom: 5px solid rgba(11, 18, 25, 0.95);
    border-radius: 24px;
    padding: 22px 20px 18px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    overflow: hidden;
}

/* Remove old clunky left bar */
.listening-card::before {
    display: none !important;
}

.listening-card:hover {
    transform: translateY(-5px);
    border-color: #38bdf8;
    border-bottom-color: #0284c7;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55), 0 0 25px rgba(28, 176, 246, 0.2);
}

/* Light Theme Overrides for Listening Card */
[data-theme="light"] .listening-card {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-bottom: 5px solid #cbd5e1;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

[data-theme="light"] .listening-card:hover {
    border-color: #38bdf8;
    border-bottom-color: #0284c7;
    box-shadow: 0 16px 36px rgba(2, 132, 199, 0.14), 0 0 0 1px rgba(56, 189, 248, 0.2);
}

/* Card Header */
.listening-card-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}

/* Topic Icon Bubble (Duolingo 3D Badge) */
.listening-topic-bubble {
    width: 48px;
    height: 48px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex-shrink: 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.listening-card:hover .listening-topic-bubble {
    transform: scale(1.1) rotate(6deg);
}

/* Topic Colors with Rich Pastel Gradients (Dark Mode default) */
.topic-emerald { background: rgba(34, 197, 94, 0.16); color: #4ade80; border: 1.5px solid rgba(74, 222, 128, 0.3); }
.topic-violet  { background: rgba(168, 85, 247, 0.16); color: #c084fc; border: 1.5px solid rgba(192, 132, 252, 0.3); }
.topic-amber   { background: rgba(245, 158, 11, 0.16); color: #fbbf24; border: 1.5px solid rgba(251, 191, 36, 0.3); }
.topic-rose    { background: rgba(244, 63, 94, 0.16); color: #fb7185; border: 1.5px solid rgba(251, 113, 133, 0.3); }
.topic-orange  { background: rgba(249, 115, 22, 0.16); color: #fb923c; border: 1.5px solid rgba(251, 146, 60, 0.3); }
.topic-sky     { background: rgba(14, 165, 233, 0.16); color: #38bdf8; border: 1.5px solid rgba(56, 189, 248, 0.3); }
.topic-cyan    { background: rgba(6, 182, 212, 0.16); color: #22d3ee; border: 1.5px solid rgba(34, 211, 238, 0.3); }
.topic-blue    { background: rgba(59, 130, 246, 0.16); color: #60a5fa; border: 1.5px solid rgba(96, 165, 250, 0.3); }

/* Topic Colors in Light Theme (Disney Pastel Gradients) */
[data-theme="light"] .topic-emerald { background: linear-gradient(135deg, #dcfce7, #bbf7d0); color: #16a34a; border: 1.5px solid #86efac; }
[data-theme="light"] .topic-violet  { background: linear-gradient(135deg, #f3e8ff, #e9d5ff); color: #9333ea; border: 1.5px solid #d8b4fe; }
[data-theme="light"] .topic-amber   { background: linear-gradient(135deg, #fef3c7, #fde68a); color: #d97706; border: 1.5px solid #fcd34d; }
[data-theme="light"] .topic-rose    { background: linear-gradient(135deg, #ffe4e6, #fecdd3); color: #e11d48; border: 1.5px solid #fda4af; }
[data-theme="light"] .topic-orange  { background: linear-gradient(135deg, #ffedd5, #fed7aa); color: #ea580c; border: 1.5px solid #fdba74; }
[data-theme="light"] .topic-sky     { background: linear-gradient(135deg, #e0f2fe, #bae6fd); color: #0284c7; border: 1.5px solid #7dd3fc; }
[data-theme="light"] .topic-cyan    { background: linear-gradient(135deg, #cffafe, #a5f3fc); color: #0891b2; border: 1.5px solid #67e8f9; }
[data-theme="light"] .topic-blue    { background: linear-gradient(135deg, #dbeafe, #bfdbfe); color: #2563eb; border: 1.5px solid #93c5fd; }

/* Header Meta */
.listening-header-meta {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.listening-tag-row {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

/* Unit Badge */
.listening-unit-badge {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.6px;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.15);
    padding: 3px 8px;
    border-radius: 8px;
    text-transform: uppercase;
}

[data-theme="light"] .listening-unit-badge {
    color: #0284c7;
    background: rgba(2, 132, 199, 0.1);
}

/* Category Pill */
.listening-category-pill {
    font-size: 0.74rem;
    font-weight: 700;
    color: #cbd5e1;
    background: rgba(255, 255, 255, 0.08);
    padding: 3px 9px;
    border-radius: 8px;
    white-space: nowrap;
}

[data-theme="light"] .listening-category-pill {
    color: #475569;
    background: #f1f5f9;
}

/* XP Badge (Duolingo style) */
.listening-xp-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    font-weight: 800;
    color: #fbbf24;
    background: rgba(245, 158, 11, 0.18);
    border: 1px solid rgba(251, 191, 36, 0.3);
    padding: 4px 9px;
    border-radius: 12px;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .listening-xp-badge {
    color: #d97706;
    background: linear-gradient(135deg, rgba(254, 243, 199, 0.9), rgba(253, 230, 138, 0.9));
    border-color: rgba(245, 158, 11, 0.35);
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.15);
}

/* Card Body & Title */
.listening-card-body {
    flex: 1;
    margin-bottom: 14px;
}

.listening-title {
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.35;
    margin-bottom: 8px;
    color: #ffffff;
}

[data-theme="light"] .listening-title {
    color: #0f2b48;
}

.listening-vn-title {
    display: block;
}

.listening-en-sub {
    display: block;
    font-size: 0.84rem;
    font-weight: 600;
    color: #38bdf8;
    font-style: italic;
    margin-top: 3px;
    letter-spacing: -0.1px;
}

[data-theme="light"] .listening-en-sub {
    color: #0284c7;
}

.listening-desc {
    font-size: 0.88rem;
    color: #94a3b8;
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

[data-theme="light"] .listening-desc {
    color: #475569;
}

/* ELSA Style Micro Chips Row */
.listening-chips-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    padding-top: 10px;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

[data-theme="light"] .listening-chips-row {
    border-top-color: #e2e8f0;
}

.listening-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.76rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: #cbd5e1;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="light"] .listening-chip {
    background: #f8fafc;
    color: #64748b;
    border-color: #e2e8f0;
}

.level-indicator-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10b981;
}

.chip-level.level-medium .level-indicator-dot { background: #38bdf8; }
.chip-level.level-hard .level-indicator-dot { background: #f97316; }
.chip-level.level-expert .level-indicator-dot { background: #ef4444; }

/* Duolingo Chunky 3D Action Button */
.listening-card-footer {
    padding-top: 2px;
}

.btn-start-listening {
    width: 100%;
    background: #1cb0f6;
    color: #ffffff;
    border: none;
    border-bottom: 4px solid #1899d6;
    padding: 11px 20px;
    border-radius: 16px;
    font-weight: 800;
    font-size: 0.92rem;
    letter-spacing: 0.5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(28, 176, 246, 0.25);
    transition: all 0.15s ease;
    user-select: none;
    -webkit-user-select: none;
}

.btn-start-listening:hover {
    background: #23bbf8;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(28, 176, 246, 0.35);
}

.btn-start-listening:active {
    transform: translateY(3px);
    border-bottom-width: 1px;
    box-shadow: 0 2px 6px rgba(28, 176, 246, 0.2);
}

.btn-start-listening i {
    font-size: 0.85rem;
    transition: transform 0.2s ease;
}

.btn-start-listening:hover i {
    transform: translateX(3px);
}

/* ============================================== */
/* QUIZ HEADER RIGHT & REGEN BUTTON               */
/* ============================================== */
.quiz-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-quiz-speech-toggle {
    background: rgba(28, 176, 246, 0.12);
    border: 1.5px solid rgba(28, 176, 246, 0.4);
    color: var(--primary);
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    user-select: none;
}

.btn-quiz-speech-toggle:hover {
    background: rgba(28, 176, 246, 0.22);
    border-color: var(--primary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(28, 176, 246, 0.3);
}

.btn-quiz-speech-toggle:not(.active) {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.15);
    color: var(--text-muted);
}

[data-theme="light"] .btn-quiz-speech-toggle {
    background: rgba(2, 132, 199, 0.08);
    border-color: rgba(2, 132, 199, 0.35);
    color: #0284c7;
}

[data-theme="light"] .btn-quiz-speech-toggle:not(.active) {
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: #64748b;
}

@media (max-width: 600px) {
    .btn-quiz-speech-toggle .speech-toggle-text {
        display: none;
    }
    .btn-quiz-speech-toggle {
        padding: 6px 10px;
    }
}

.btn-quiz-regen {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffd700;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-quiz-regen:hover {
    background: rgba(255, 215, 0, 0.15);
    border-color: #ffd700;
    transform: translateY(-1px);
}

/* ============================================== */
/* DUOLINGO-STYLE WORD BANK FOR SENTENCE BUILDING */
/* ============================================== */
.word-bank-container {
    width: 100%;
    max-width: 650px;
    margin: 1.5rem auto 0.5rem auto;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.word-bank-target-wrapper {
    min-height: 85px;
    padding: 14px 18px;
    background: rgba(0, 0, 0, 0.35);
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    display: flex;
    align-items: center;
    transition: all 0.2s ease;
}

.word-bank-target-wrapper:hover,
.word-bank-target-wrapper.active {
    border-color: var(--primary);
    background: rgba(0, 0, 0, 0.45);
}

.word-bank-target {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 48px;
}

.word-bank-placeholder {
    color: var(--text-muted);
    font-size: 0.95rem;
    font-style: italic;
    user-select: none;
}

.word-bank-pool {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    padding: 10px 0;
    min-height: 80px;
}

.word-chip {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    font-size: 1.05rem;
    font-weight: 700;
    padding: 10px 18px;
    border-radius: 14px;
    cursor: pointer;
    user-select: none;
    box-shadow: 0 4px 0 rgba(0, 0, 0, 0.3);
    transition: all 0.12s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.word-chip:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: translateY(-2px);
    box-shadow: 0 6px 0 rgba(0, 0, 0, 0.35);
}

.word-chip:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.3);
}

.word-chip.placed-in-target {
    background: var(--secondary);
    border-color: #0d8bd9;
    color: #fff;
    box-shadow: 0 4px 0 #0968a5;
    animation: popIn 0.15s ease-out;
}

.word-chip.placed-in-target:hover {
    background: #0ea5e9;
}

.word-chip.used-in-pool {
    opacity: 0.25;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.05);
    box-shadow: none;
    border-color: transparent;
}

.word-bank-toggle-row {
    display: flex;
    justify-content: center;
    margin-top: 4px;
}

.btn-word-bank-toggle {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.btn-word-bank-toggle:hover {
    color: var(--secondary);
}

@keyframes popIn {
    0% { transform: scale(0.85); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* ============================================== */
/* ROADMAP HEADER & AI MASCOT DIALOGUE CARD       */
/* ============================================== */
.roadmap-header {
    padding: 1.25rem 1rem 0.75rem 1rem;
    text-align: center;
}

.roadmap-header h2 {
    font-size: 1.7rem;
    font-weight: 800;
    margin-bottom: 0.35rem;
    background: linear-gradient(135deg, #ffffff 40%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

.roadmap-header p {
    color: #94a3b8;
    font-size: 0.92rem;
    margin: 0;
}

.ai-mascot-dialogue-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.1) 0%, rgba(88, 204, 2, 0.08) 100%);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(28, 176, 246, 0.28);
    border-radius: 18px;
    padding: 14px 18px;
    margin: 0 1rem 1.25rem 1rem;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25), inset 0 0 15px rgba(28, 176, 246, 0.04);
    position: relative;
    transition: all 0.25s ease;
}

.ai-mascot-dialogue-card:hover {
    border-color: rgba(88, 204, 2, 0.45);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3), 0 0 20px rgba(88, 204, 2, 0.12);
    transform: translateY(-2px);
}

.mascot-avatar-wrap {
    position: relative;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1cb0f6, #58cc02);
    padding: 2.5px;
    box-shadow: 0 0 16px rgba(88, 204, 2, 0.45), 0 0 10px rgba(28, 176, 246, 0.35);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: float 3.5s ease-in-out infinite;
}

.mascot-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    background: #131f24;
}

.mascot-live-dot {
    position: absolute;
    bottom: 0px;
    right: 0px;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #58cc02;
    border: 2.5px solid #131f24;
    box-shadow: 0 0 8px #58cc02;
    animation: livePulse 2s infinite;
}

@keyframes livePulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.85); }
}

.mascot-speech-body {
    flex: 1;
    min-width: 0;
}

.mascot-header-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.mascot-name-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.mascot-badge-pill {
    background: rgba(28, 176, 246, 0.2);
    color: #38bdf8;
    border: 1px solid rgba(28, 176, 246, 0.35);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
    letter-spacing: 0.2px;
}

.mascot-sub-label {
    font-size: 0.76rem;
    color: #94a3b8;
    font-weight: 500;
}

.mascot-speech-bubble {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-left: 3px solid var(--secondary);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 0.92rem;
    color: #f1f5f9;
    line-height: 1.45;
    position: relative;
    word-break: break-word;
}

/* ============================================== */
/* AI DAILY SPOTLIGHT WIDGET                      */
/* ============================================== */
.daily-spotlight-card {
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.12), rgba(139, 92, 246, 0.15));
    border: 1.5px solid rgba(28, 176, 246, 0.4);
    border-radius: 20px;
    padding: 20px 24px;
    margin: 0 1rem 1.5rem 1rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25), inset 0 0 20px rgba(28, 176, 246, 0.05);
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.4s ease-out;
}

.daily-spotlight-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.25) 0%, transparent 70%);
    pointer-events: none;
}

.daily-spotlight-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 8px;
}

.daily-spotlight-badge {
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    color: white;
    font-size: 0.82rem;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.daily-spotlight-session {
    font-size: 0.85rem;
    color: var(--secondary);
    font-weight: 700;
}

.daily-spotlight-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 12px;
    line-height: 1.3;
}

.daily-spotlight-word-box {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 10px 16px;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.95rem;
}

.daily-spotlight-word-box .word-tag {
    color: var(--warning);
    font-weight: 700;
}

.daily-spotlight-word-box strong {
    color: #38bdf8;
    font-size: 1.15rem;
}

.daily-spotlight-word-box .word-phonetic {
    color: #94a3b8;
    font-style: italic;
}

.btn-word-audio {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 1.1rem;
    padding: 4px 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-word-audio:hover {
    background: var(--secondary);
    transform: scale(1.1);
}

.daily-spotlight-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.btn-spotlight-quiz {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
    padding: 10px 22px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    box-shadow: 0 4px 0 #047857, 0 8px 15px rgba(16, 185, 129, 0.3);
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-spotlight-quiz:hover {
    background: #34d399;
    transform: translateY(-2px);
}

.btn-spotlight-quiz:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 #047857;
}

.btn-spotlight-story {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 10px 18px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-spotlight-story:hover {
    background: rgba(255, 255, 255, 0.18);
    border-color: var(--secondary);
}

/* AI Daily Spotlight Story Modal */
.story-dialog-content {
    background: #15222b !important;
    border: 1.5px solid rgba(28, 176, 246, 0.35) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 30px rgba(28, 176, 246, 0.2) !important;
    border-radius: 20px !important;
    max-width: 680px !important;
    width: 100% !important;
    max-height: 88vh !important;
    max-height: 88dvh !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    padding: 1.5rem !important;
    text-align: left !important;
    color: #ffffff !important;
    animation: slideUp 0.3s ease-out;
}

.story-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 0.8rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.story-header-title-box {
    flex: 1;
}

.story-badge-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.25);
    padding: 4px 10px;
    border-radius: 20px;
    margin-bottom: 6px;
}

.story-header-title {
    color: #ffffff;
    font-size: 1.3rem;
    font-weight: 800;
    line-height: 1.35;
    margin: 0;
}

.story-audio-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 1rem;
    background: rgba(255, 255, 255, 0.04);
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.btn-story-audio-play {
    background: linear-gradient(135deg, #1cb0f6, #0284c7);
    color: white;
    border: none;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    box-shadow: 0 3px 0 #0369a1, 0 6px 12px rgba(28, 176, 246, 0.3);
    transition: all 0.15s ease;
}

.btn-story-audio-play:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.btn-story-audio-play:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 #0369a1;
}

.story-audio-hint {
    font-size: 0.8rem;
    color: #94a3b8;
    margin-left: auto;
}

.story-voice-selector {
    display: inline-flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 3px;
    gap: 3px;
}

.btn-voice-toggle {
    background: transparent;
    color: #94a3b8;
    border: none;
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-voice-toggle:hover {
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.08);
}

.btn-voice-toggle.active {
    background: linear-gradient(135deg, #ec4899, #db2777);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(236, 72, 153, 0.35);
}

.btn-voice-toggle#btn-voice-namminh.active {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.35);
}

.story-body-scrollable {
    flex: 1;
    overflow-y: auto;
    padding-right: 6px;
    margin-bottom: 1rem;
}

.story-body-scrollable::-webkit-scrollbar {
    width: 6px;
}
.story-body-scrollable::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}
.story-body-scrollable::-webkit-scrollbar-thumb {
    background: rgba(28, 176, 246, 0.4);
    border-radius: 4px;
}
.story-body-scrollable::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

.story-section-label {
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #38bdf8;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.story-text-eng {
    font-size: 1.05rem;
    line-height: 1.75;
    color: #ffffff !important;
    margin-bottom: 1.2rem;
    background: rgba(28, 176, 246, 0.08) !important;
    padding: 16px;
    border-radius: 14px;
    border: 1px solid rgba(28, 176, 246, 0.25) !important;
    border-left: 4px solid var(--secondary) !important;
    white-space: pre-line;
    word-break: break-word;
}

.story-text-vi {
    font-size: 0.95rem;
    line-height: 1.68;
    color: #cbd5e1 !important;
    margin-bottom: 0.5rem;
    background: rgba(255, 255, 255, 0.03) !important;
    padding: 15px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-left: 4px solid #10b981 !important;
    white-space: pre-line;
    word-break: break-word;
}

.story-footer-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    align-items: center;
    margin-top: auto;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}




/* CHỈ HIỆN XU VÀ KHIÊN TRÊN HEADER KHI VÀO CỬA HÀNG */
body:not(.in-store-tab) .stat-shop-only {
    display: none !important;
}

/* User Dropdown */
.user-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    position: absolute;
    right: 0;
    top: calc(100% + 5px);
    background-color: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    min-width: 150px;
    z-index: 1000;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.dropdown-content.hidden {
    display: none !important;
}

.dropdown-item {
    background: none;
    border: none;
    padding: 12px 16px;
    text-align: left;
    color: var(--text-color);
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* ==========================================
   SHOP & AVATAR STORE REDESIGN (PC & MOBILE)
   ========================================== */
.shop-container {
    display: flex;
    flex-direction: column;
    gap: 1.35rem;
    margin-top: 1rem;
    max-width: 820px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 1rem;
    width: 100%;
}

/* Wallet Banner */
.shop-wallet-panel {
    padding: 1rem 1.25rem;
    display: flex;
    justify-content: space-around;
    align-items: center;
    background: linear-gradient(135deg, rgba(255, 200, 0, 0.08) 0%, rgba(56, 189, 248, 0.08) 100%);
    border: 1px solid rgba(255, 200, 0, 0.28);
    border-radius: 18px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.shop-wallet-stat {
    text-align: center;
    flex: 1;
    min-width: 0;
}

.shop-wallet-val {
    font-size: 1.25rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    line-height: 1.2;
}

.shop-wallet-val.coin-val { color: #ffc800; }
.shop-wallet-val.xp-val { color: #ffd700; }
.shop-wallet-val.freeze-val { color: #38bdf8; }
.shop-wallet-val.heart-val { color: #ff4b4b; }

.shop-wallet-lbl {
    font-size: 0.75rem;
    color: #cbd5e1;
    margin-top: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.shop-wallet-divider {
    width: 1px;
    height: 32px;
    background: rgba(255, 255, 255, 0.14);
    flex-shrink: 0;
}

/* Shop Section Header */
.shop-section-title {
    font-weight: 700;
    color: #38bdf8;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 0.85rem;
}

.shop-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
    flex-wrap: wrap;
    gap: 6px;
}

.shop-avatar-section {
    padding: 1.5rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.shop-avatar-title {
    color: var(--primary, #1cb0f6);
    margin: 0;
    font-size: 1.1rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
}

.shop-avatar-subtitle {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 500;
}

.shop-avatar-desc {
    font-size: 0.85rem;
    color: #cbd5e1;
    margin-bottom: 16px;
    line-height: 1.45;
}

/* Utility Cards */
.shop-utility-card {
    padding: 1.2rem 1.4rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.25s ease;
    margin-bottom: 0.85rem;
}

.shop-utility-card:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.18);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.shop-utility-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    flex-shrink: 0;
}

.shop-utility-icon.freeze-icon {
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.shop-utility-icon.heart-icon {
    background: rgba(255, 75, 75, 0.15);
    color: #ff4b4b;
    border: 1px solid rgba(255, 75, 75, 0.3);
}

.shop-utility-icon.boost-icon {
    background: rgba(255, 215, 0, 0.15);
    color: #ffd700;
    border: 1px solid rgba(255, 215, 0, 0.3);
}

.shop-utility-body {
    flex: 1;
    min-width: 0;
}

.shop-utility-title {
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 4px 0;
}

.shop-utility-desc {
    font-size: 0.82rem;
    color: #cbd5e1;
    margin: 0 0 8px 0;
    line-height: 1.35;
}

.shop-utility-pricing {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.shop-utility-or {
    font-size: 0.78rem;
    color: #94a3b8;
}

.shop-utility-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex-shrink: 0;
}

.btn-utility-buy {
    white-space: nowrap;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    padding: 8px 14px;
    font-size: 0.82rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.btn-utility-buy:active {
    transform: scale(0.97);
}

.btn-buy-coins {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.35);
}
.btn-buy-coins:hover {
    filter: brightness(1.12);
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.5);
}

.btn-buy-xp {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e2e8f0;
}
.btn-buy-xp:hover {
    background: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.35);
}

.btn-buy-heart {
    background: linear-gradient(135deg, #ff4b4b, #dc2626);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(255, 75, 75, 0.35);
}
.btn-buy-heart:hover {
    filter: brightness(1.12);
    box-shadow: 0 4px 14px rgba(255, 75, 75, 0.5);
}

.btn-buy-boost {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.35);
}
.btn-buy-boost:hover {
    filter: brightness(1.12);
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.5);
}

/* ==========================================
   AVATAR SHOP GRID & CARDS
   ========================================== */
.avatar-shop-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 12px;
}

.avatar-item {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 14px 10px 12px;
    text-align: center;
    transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    min-height: 184px;
    position: relative;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

.avatar-item:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0.04) 100%);
    border-color: rgba(56, 189, 248, 0.45);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.avatar-item.is-equipped {
    border-color: #22c55e !important;
    background: linear-gradient(180deg, rgba(34, 197, 94, 0.14) 0%, rgba(34, 197, 94, 0.03) 100%);
    box-shadow: 0 4px 16px rgba(34, 197, 94, 0.18);
}

.avatar-item.is-unlocked:not(.is-equipped) {
    border-color: rgba(56, 189, 248, 0.35);
}

.avatar-item .avatar-emoji {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.55rem;
    margin: 0 auto 6px auto;
    transition: transform 0.22s ease;
    flex-shrink: 0;
}

.avatar-item:hover .avatar-emoji {
    transform: scale(1.08);
}

.avatar-item .avatar-emoji.photo-avatar {
    border: 2.5px solid #22c55e;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.avatar-item .avatar-emoji.photo-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.avatar-item-name {
    font-size: 0.88rem;
    font-weight: 700;
    color: #f1f5f9;
    margin-bottom: 6px;
    text-align: center;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 2px;
}

/* Pricing Group & Pills */
.avatar-pricing-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-bottom: 8px;
    width: 100%;
    flex-wrap: nowrap;
}

.price-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 3px 7px;
    border-radius: 12px;
    font-size: 0.74rem;
    font-weight: 700;
    white-space: nowrap;
    line-height: 1.1;
    flex-shrink: 0;
}

.price-pill i {
    font-size: 0.72rem;
}

.price-pill.pill-xp {
    background: rgba(28, 176, 246, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.35);
}

.price-pill.pill-coins {
    background: rgba(255, 200, 0, 0.15);
    color: #ffc800;
    border: 1px solid rgba(255, 200, 0, 0.35);
}

.price-pill.pill-owned {
    background: rgba(148, 163, 184, 0.14);
    color: #cbd5e1;
    border: 1px solid rgba(148, 163, 184, 0.25);
    font-size: 0.7rem;
    padding: 3px 8px;
}

.price-pill.pill-photo {
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.35);
    font-size: 0.7rem;
}

/* Avatar Card Footer Actions */
.avatar-item-footer {
    width: 100%;
    margin-top: auto;
}

.avatar-btn-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
    width: 100%;
}

.btn-avatar-buy {
    border: none;
    border-radius: 8px;
    padding: 6px 3px;
    font-size: 0.74rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    white-space: nowrap;
    text-decoration: none;
    transition: all 0.18s ease;
    min-height: 30px;
}

.btn-avatar-buy:active {
    transform: scale(0.95);
}

.btn-avatar-buy.btn-buy-xp {
    background: linear-gradient(135deg, #0284c7, #0369a1);
    color: #ffffff;
    box-shadow: 0 2px 6px rgba(2, 132, 199, 0.35);
}

.btn-avatar-buy.btn-buy-xp:hover {
    filter: brightness(1.15);
    box-shadow: 0 3px 10px rgba(2, 132, 199, 0.55);
}

.btn-avatar-buy.btn-buy-coins {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #ffffff;
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.35);
}

.btn-avatar-buy.btn-buy-coins:hover {
    filter: brightness(1.15);
    box-shadow: 0 3px 10px rgba(245, 158, 11, 0.55);
}

.btn-avatar-equip {
    width: 100%;
    border: 1.5px solid #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    color: #38bdf8;
    border-radius: 8px;
    padding: 6px 8px;
    font-size: 0.76rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: all 0.18s ease;
    min-height: 30px;
}

.btn-avatar-equip:hover {
    background: #38bdf8;
    color: #0f172a;
}

.badge-avatar-equipped {
    width: 100%;
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.4);
    color: #4ade80;
    border-radius: 8px;
    padding: 5px 6px;
    font-size: 0.74rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-height: 30px;
}

/* ==========================================
   RESPONSIVE MEDIA QUERIES
   ========================================== */
@media (max-width: 680px) {
    .shop-utility-card {
        padding: 1rem;
        gap: 0.9rem;
    }
    .shop-utility-icon {
        width: 44px;
        height: 44px;
        font-size: 1.45rem;
    }
    .shop-utility-title {
        font-size: 0.94rem;
    }
}

@media (max-width: 520px) {
    .shop-container {
        padding: 0 10px;
        gap: 1rem;
    }
    .shop-wallet-panel {
        padding: 0.75rem 0.6rem;
        border-radius: 14px;
    }
    .shop-wallet-val {
        font-size: 1.05rem;
        gap: 4px;
    }
    .shop-wallet-lbl {
        font-size: 0.68rem;
    }
    .shop-wallet-divider {
        height: 24px;
    }

    .shop-utility-card {
        flex-direction: column;
        align-items: stretch;
        gap: 0.8rem;
    }
    .shop-utility-card > div:first-child {
        display: flex;
        align-items: center;
        gap: 10px;
    }
    .shop-utility-actions {
        flex-direction: row;
        width: 100%;
    }
    .btn-utility-buy {
        flex: 1;
    }

    .shop-avatar-section {
        padding: 1.1rem 0.85rem;
    }

    /* 2 COLUMNS ON MOBILE - ROOMY & NEVER BREAKS */
    .avatar-shop-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    .avatar-item {
        padding: 12px 8px 10px;
        min-height: 176px;
    }
    .avatar-item .avatar-emoji {
        width: 48px;
        height: 48px;
        font-size: 1.45rem;
    }
    .avatar-item-name {
        font-size: 0.84rem;
    }
    .price-pill {
        font-size: 0.72rem;
        padding: 3px 6px;
    }
    .btn-avatar-buy {
        font-size: 0.72rem;
        padding: 6px 2px;
    }
}

@media (max-width: 350px) {
    .avatar-shop-grid {
        gap: 6px;
    }
    .avatar-item {
        padding: 10px 5px 8px;
    }
    .avatar-pricing-group {
        gap: 3px;
    }
    .price-pill {
        font-size: 0.68rem;
        padding: 2px 4px;
    }
    .btn-avatar-buy {
        font-size: 0.68rem;
    }
}

/* ==========================================
   CAMERA & REAL PHOTO AVATAR STYLES
   ========================================== */
.account-avatar-wrapper {
    position: relative;
    width: 110px;
    height: 110px;
    margin: 0 auto 1rem auto;
    cursor: pointer;
    transition: transform 0.25s ease;
}

.account-avatar-wrapper:hover {
    transform: scale(1.05);
}

.account-avatar-circle {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.2), rgba(88, 204, 2, 0.2));
    border: 3px solid var(--primary);
    box-shadow: 0 0 20px rgba(28, 176, 246, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
    overflow: hidden;
    position: relative;
}

.account-avatar-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.avatar-edit-badge {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    border: 2px solid var(--bg-color);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.account-avatar-wrapper:hover .avatar-edit-badge {
    transform: scale(1.15) rotate(10deg);
    background: #1899D6;
}

.avatar-action-buttons {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-bottom: 1.2rem;
    flex-wrap: wrap;
}

.btn-avatar-action {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s ease;
    font-family: inherit;
}

.btn-avatar-action:hover {
    background: rgba(28, 176, 246, 0.25);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.avatar-modal-tabs .tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 8px 12px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-family: inherit;
}

.avatar-modal-tabs .tab-btn.active {
    background: rgba(28, 176, 246, 0.2);
    color: var(--primary);
}

.camera-viewport-container {
    animation: fadeIn 0.3s ease;
}

/* Vector Icons Utility & Color Tokens */
.text-orange { color: #ff9600 !important; }
.text-heart { color: #ff4b4b !important; }
.text-coin { color: #ffc800 !important; }
.text-bolt { color: #ffd700 !important; }
.text-gold { color: #ffd700 !important; }
.text-silver { color: #c0c0c0 !important; }
.text-bronze { color: #cd7f32 !important; }
.text-primary { color: var(--primary) !important; }
.text-success { color: #58cc02 !important; }
.text-secondary { color: var(--secondary) !important; }

.nav-icon {
    font-size: 1.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.nav-item.active .nav-icon {
    transform: scale(1.18);
    color: var(--primary);
}

.game-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
    margin-bottom: 1rem;
    transition: transform 0.3s ease;
}

.game-card:hover .game-icon {
    transform: scale(1.15) rotate(3deg);
}

.account-avatar-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
    color: var(--text-muted);
}

.avatar-edit-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}

/* App Top Header Bar */
.app-header {
    background: rgba(19, 31, 36, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.stat-pill {
    transition: all 0.2s ease;
    user-select: none;
}
.stat-pill:hover {
    background: rgba(255, 255, 255, 0.14) !important;
    transform: translateY(-1px);
}

/* Feedback & Suggestions Components */
.feedback-topic-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 5px 11px;
    border-radius: 20px;
    font-size: 0.82rem;
    color: #e2e8f0;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}
.feedback-topic-chip:hover, .feedback-topic-chip.selected {
    background: rgba(28, 176, 246, 0.25);
    border-color: var(--primary);
    color: #fff;
    transform: translateY(-1px);
}
.feedback-topic-chip.selected {
    box-shadow: 0 0 10px rgba(28, 176, 246, 0.3);
}

.star-rating-container {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    margin: 10px 0;
}
.star-btn {
    background: transparent;
    border: none;
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: transform 0.15s ease, color 0.15s ease;
    padding: 2px 4px;
}
.star-btn.active, .star-btn.hover {
    color: #ffd700;
    transform: scale(1.18);
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
}
.star-rating-label {
    text-align: center;
    font-size: 0.9rem;
    color: #ffc800;
    font-weight: 600;
    min-height: 22px;
}

.feedback-input {
    width: 100%;
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.2s;
}
.feedback-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(28, 176, 246, 0.2);
}

.feedback-history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 4px;
}
.feedback-card-item {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 14px;
    text-align: left;
    transition: background 0.2s;
}
.feedback-card-item:hover {
    background: rgba(255, 255, 255, 0.07);
}
.badge-status {
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
}
.badge-status-pending {
    background: rgba(255, 200, 0, 0.2);
    color: #ffc800;
    border: 1px solid rgba(255, 200, 0, 0.4);
}
.badge-status-reviewing {
    background: rgba(28, 176, 246, 0.2);
    color: #1cb0f6;
    border: 1px solid rgba(28, 176, 246, 0.4);
}
.badge-status-resolved {
    background: rgba(88, 204, 2, 0.2);
    color: #58cc02;
    border: 1px solid rgba(88, 204, 2, 0.4);
}

.admin-fb-desktop-view {
    display: block;
}
.admin-fb-mobile-view {
    display: none;
}
.modal-drag-indicator {
    display: none;
}

/* Landing Hero Image & Layout */
.landing-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2.5rem;
    margin: 2rem 0 3rem 0;
    flex-wrap: wrap;
}
.landing-text {
    flex: 1.2;
    min-width: 300px;
}
.landing-image {
    flex: 1;
    min-width: 280px;
    max-width: 440px;
    display: flex;
    justify-content: center;
}
.landing-hero-img {
    width: 100%;
    max-width: 420px;
    height: auto;
    border-radius: 24px;
    box-shadow: 0 12px 40px rgba(28, 176, 246, 0.38), 0 0 25px rgba(0, 0, 0, 0.5);
    border: 2px solid rgba(28, 176, 246, 0.45);
    animation: float 4s ease-in-out infinite;
    object-fit: cover;
}
/* ==============================================================================
   QUESTION ERROR REPORTING & AI AUTO-FIX STYLES
   ============================================================================== */
.btn-quiz-report {
    background: rgba(255, 150, 0, 0.12);
    border: 1.5px solid rgba(255, 150, 0, 0.4);
    color: #ff9600;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Outfit', sans-serif;
}
.btn-quiz-report:hover {
    background: rgba(255, 150, 0, 0.22);
    border-color: #ff9600;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 150, 0, 0.25);
}

.report-reason-btn {
    background: rgba(255, 255, 255, 0.04);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 0.84rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    text-align: left;
    transition: all 0.2s ease;
    font-family: 'Outfit', sans-serif;
}
.report-reason-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
}
.report-reason-btn.active {
    background: rgba(255, 150, 0, 0.15);
    border-color: #ff9600;
    color: #fff;
    box-shadow: 0 0 10px rgba(255, 150, 0, 0.2);
}

.ai-pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
}
.ai-pill-badge.verified {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}
.ai-pill-badge.pending {
    background: rgba(255, 150, 0, 0.15);
    color: #ff9600;
    border: 1px solid rgba(255, 150, 0, 0.3);
}
.ai-pill-badge.valid {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

/* ==============================================================================
   CURRICULUM SELECTION & CAMBRIDGE STYLES
   ============================================================================== */
.curriculum-tab-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.curriculum-tab-btn {
    flex: 1;
    min-width: 220px;
    max-width: 320px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    color: #cbd5e1;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Outfit', sans-serif;
}

.curriculum-tab-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.curriculum-tab-btn.active {
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.2), rgba(88, 204, 2, 0.15));
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 8px 24px rgba(28, 176, 246, 0.25);
}

.curriculum-tab-btn .tab-flag {
    font-size: 2rem;
    line-height: 1;
    flex-shrink: 0;
}

.cambridge-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
    margin-top: 1rem;
}

.cambridge-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: left;
    position: relative;
    overflow: hidden;
}

.cambridge-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.cambridge-card.active {
    border-color: #58cc02;
    background: rgba(88, 204, 2, 0.12);
    box-shadow: 0 0 20px rgba(88, 204, 2, 0.3);
}

.cambridge-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cambridge-cefr {
    font-size: 0.78rem;
    font-weight: 700;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    padding: 2px 6px;
    border-radius: 6px;
    margin-left: 6px;
}

.curriculum-pill-header {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(28, 176, 246, 0.15);
    border: 1px solid rgba(28, 176, 246, 0.35);
    color: #38bdf8;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
}

/* ==========================================================================
   QUIZ FULLSCREEN, MODALS & BOTTOM NAV VISIBILITY ENFORCEMENT
   ========================================================================== */
#bottom-nav.hidden,
.bottom-nav.hidden,
body.in-quiz #bottom-nav,
body:has(#screen-quiz:not(.hidden)) #bottom-nav {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* Modals must ALWAYS be on top of all footers and buttons */
.modal:not(.hidden) {
    z-index: 10000 !important;
}

/* When any modal is active, hide the quiz footer completely so it never covers buttons */
body:has(.modal:not(.hidden)) .quiz-footer,
body.modal-open .quiz-footer {
    display: none !important;
    pointer-events: none !important;
}

body.in-quiz .quiz-footer,
body:has(#screen-quiz:not(.hidden)) .quiz-footer {
    display: flex;
    z-index: 50;
}

/* ==========================================================================
   CUSTOM TOAST NOTIFICATION SYSTEM (GLASSMORPHISM & ANIMATIONS)
   ========================================================================== */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 999999 !important;
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 380px;
    max-width: calc(100vw - 32px);
    pointer-events: none;
}

.app-toast {
    pointer-events: auto;
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: rgba(19, 31, 36, 0.94);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 16px;
    padding: 14px 16px 16px 14px;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1);
    color: #ffffff;
    overflow: hidden;
    animation: toastSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.app-toast:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 42px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.app-toast.toast-dismissing {
    animation: toastSlideOut 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
}

/* Left vertical glowing indicator */
.toast-indicator {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 4px;
    border-radius: 4px 0 0 4px;
}

/* Icon badge */
.toast-icon-wrap {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
    margin-top: 1px;
}

/* Toast Body */
.toast-body {
    flex: 1;
    min-width: 0;
    padding-right: 6px;
}

.toast-title {
    font-family: 'Outfit', sans-serif;
    font-size: 0.96rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 3px;
    letter-spacing: -0.2px;
}

.toast-message {
    font-size: 0.88rem;
    line-height: 1.45;
    color: #e2e8f0;
    word-break: break-word;
}

/* Close button */
.toast-close {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.45);
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    padding: 2px 6px;
    border-radius: 8px;
    transition: color 0.15s ease, background 0.15s ease;
    flex-shrink: 0;
}

.toast-close:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

/* Progress bar */
.toast-progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    animation: toastProgress linear forwards;
    transform-origin: left;
}

/* Color Variants */
/* Success */
.toast-success .toast-indicator {
    background: #58cc02;
    box-shadow: 0 0 10px rgba(88, 204, 2, 0.6);
}
.toast-success .toast-icon-wrap {
    background: rgba(88, 204, 2, 0.16);
    color: #58cc02;
    border: 1px solid rgba(88, 204, 2, 0.35);
}
.toast-success .toast-title {
    color: #58cc02;
}
.toast-success .toast-progress-bar {
    background: linear-gradient(90deg, #58cc02, #22c55e);
}

/* Error */
.toast-error .toast-indicator {
    background: #ff4b4b;
    box-shadow: 0 0 10px rgba(255, 75, 75, 0.6);
}
.toast-error .toast-icon-wrap {
    background: rgba(255, 75, 75, 0.16);
    color: #ff4b4b;
    border: 1px solid rgba(255, 75, 75, 0.35);
}
.toast-error .toast-title {
    color: #ff4b4b;
}
.toast-error .toast-progress-bar {
    background: linear-gradient(90deg, #ff4b4b, #ef4444);
}

/* Warning */
.toast-warning .toast-indicator {
    background: #ff9600;
    box-shadow: 0 0 10px rgba(255, 150, 0, 0.6);
}
.toast-warning .toast-icon-wrap {
    background: rgba(255, 150, 0, 0.16);
    color: #ff9600;
    border: 1px solid rgba(255, 150, 0, 0.35);
}
.toast-warning .toast-title {
    color: #ff9600;
}
.toast-warning .toast-progress-bar {
    background: linear-gradient(90deg, #ff9600, #f59e0b);
}

/* Info */
.toast-info .toast-indicator {
    background: #1cb0f6;
    box-shadow: 0 0 10px rgba(28, 176, 246, 0.6);
}
.toast-info .toast-icon-wrap {
    background: rgba(28, 176, 246, 0.16);
    color: #1cb0f6;
    border: 1px solid rgba(28, 176, 246, 0.35);
}
.toast-info .toast-title {
    color: #1cb0f6;
}
.toast-info .toast-progress-bar {
    background: linear-gradient(90deg, #1cb0f6, #0ea5e9);
}

/* Animations */
@keyframes toastSlideIn {
    0% {
        opacity: 0;
        transform: translateY(-24px) scale(0.92);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toastSlideOut {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-20px) scale(0.9);
    }
}

@keyframes toastProgress {
    0% {
        width: 100%;
    }
    100% {
        width: 0%;
    }
}

/* Mobile responsive positioning */
@media (max-width: 600px) {
    .toast-container {
        top: 14px;
        left: 50%;
        transform: translateX(-50%);
        right: auto;
        width: calc(100vw - 28px);
    }
    .app-toast {
        padding: 12px 14px;
    }
    .toast-icon-wrap {
        width: 34px;
        height: 34px;
        font-size: 1.1rem;
    }
    .toast-title {
        font-size: 0.92rem;
    }
    .toast-message {
        font-size: 0.84rem;
    }
}

/* ==========================================================================
   PWA MOBILE APP INSTALLATION BANNER & MODAL
   ========================================================================== */
.pwa-bottom-banner {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(120%);
    width: 92%;
    max-width: 520px;
    z-index: 99998 !important;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    opacity: 0;
    pointer-events: none;
}

.pwa-bottom-banner.banner-visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.pwa-bottom-banner.banner-hiding {
    transform: translateX(-50%) translateY(120%);
    opacity: 0;
    pointer-events: none;
}

/* Kéo banner lên trên bottom nav nếu đang hiển thị trên mobile */
body:has(.bottom-nav:not(.hidden)) .pwa-bottom-banner {
    bottom: 82px;
}

/* Ẩn PWA banner khi có bất kỳ Modal nào đang mở để không che chắn nội dung */
body:has(.modal:not(.hidden)) .pwa-bottom-banner {
    display: none !important;
}

.modal {
    z-index: 100000 !important;
}

.pwa-banner-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(19, 31, 36, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1.5px solid rgba(28, 176, 246, 0.45);
    border-radius: 18px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(28, 176, 246, 0.2);
}

.pwa-btn-close-corner {
    position: absolute;
    top: 4px;
    right: 6px;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 0.8rem;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.2s ease;
    z-index: 10;
}

.pwa-btn-close-corner:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
}

.pwa-banner-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.pwa-banner-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    object-fit: cover;
    border: 2px solid var(--primary);
    box-shadow: 0 4px 12px rgba(28, 176, 246, 0.4);
    flex-shrink: 0;
}

.pwa-banner-info {
    flex: 1;
    min-width: 0;
}

.pwa-banner-title {
    font-family: 'Outfit', sans-serif;
    font-size: 0.95rem;
    font-weight: 800;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 1.2;
    margin-bottom: 2px;
    white-space: nowrap;
}

.pwa-badge-pill {
    background: rgba(88, 204, 2, 0.18);
    color: #58cc02;
    border: 1px solid rgba(88, 204, 2, 0.4);
    font-size: 0.68rem;
    font-weight: 700;
    padding: 1px 7px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pwa-banner-desc {
    font-size: 0.8rem;
    color: #cbd5e1;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pwa-banner-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.pwa-btn-install {
    padding: 8px 14px;
    font-size: 0.86rem;
    font-weight: 700;
    border-radius: 10px;
    white-space: nowrap;
    background: #58cc02;
    border: 1px solid #46a302;
    box-shadow: 0 3px 0 #3a8c02;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pwa-btn-install:active {
    transform: translateY(2px);
    box-shadow: none;
}

.pwa-btn-dismiss {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 0.76rem;
    font-weight: 600;
    cursor: pointer;
    padding: 2px 6px;
    text-decoration: underline;
    transition: color 0.15s ease;
}

.pwa-btn-dismiss:hover {
    color: #ffffff;
}

/* PWA Guide Modal */
.pwa-guide-card {
    width: 100%;
    max-width: 480px;
    padding: 1.8rem;
    border: 2px solid var(--primary);
    position: relative;
    border-radius: 20px;
    animation: pwaSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes pwaSlideUp {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.pwa-guide-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.pwa-guide-header h3 {
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    margin: 0;
}

.pwa-guide-icon-badge {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

.pwa-guide-icon-badge.apple {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.pwa-guide-icon-badge.android {
    background: rgba(88, 204, 2, 0.2);
    color: #58cc02;
    border: 1px solid rgba(88, 204, 2, 0.4);
}

.pwa-guide-icon-badge.warning {
    background: rgba(255, 150, 0, 0.2);
    color: #ff9600;
    border: 1px solid rgba(255, 150, 0, 0.4);
}

.pwa-guide-lead {
    color: #cbd5e1;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 16px;
}

.pwa-guide-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.pwa-step-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.pwa-step-num {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--primary);
    color: #ffffff;
    font-weight: 800;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.pwa-step-text {
    font-size: 0.9rem;
    color: #e2e8f0;
    line-height: 1.45;
}

.pwa-guide-tip {
    margin-top: 14px;
    padding: 10px 14px;
    background: rgba(28, 176, 246, 0.12);
    border: 1px dashed rgba(28, 176, 246, 0.4);
    border-radius: 12px;
    font-size: 0.84rem;
    color: #7dd3fc;
    line-height: 1.4;
}

@media (max-width: 480px) {
    .pwa-bottom-banner {
        bottom: max(10px, env(safe-area-inset-bottom)) !important;
        width: calc(100% - 16px) !important;
        max-width: 420px !important;
    }
    .pwa-banner-card {
        padding: 8px 10px !important;
        gap: 8px !important;
        border-radius: 14px !important;
    }
    .pwa-banner-icon {
        width: 36px !important;
        height: 36px !important;
        border-radius: 10px !important;
    }
    .pwa-banner-title {
        font-size: 0.82rem !important;
        line-height: 1.2 !important;
        gap: 4px !important;
    }
    .pwa-badge-pill {
        font-size: 0.6rem !important;
        padding: 1px 5px !important;
    }
    .pwa-banner-desc {
        font-size: 0.68rem !important;
        line-height: 1.25 !important;
        -webkit-line-clamp: 1 !important;
    }
    .pwa-banner-actions {
        gap: 3px !important;
    }
    .pwa-btn-install {
        padding: 5px 9px !important;
        font-size: 0.72rem !important;
        border-radius: 8px !important;
        gap: 4px !important;
    }
    .pwa-btn-dismiss {
        font-size: 0.68rem !important;
        padding: 1px 4px !important;
    }
}

/* High-Fidelity Audio Playing & Loading Pulse */
.audio-playing-pulse {
    animation: audioPulseGlow 1.2s infinite ease-in-out !important;
    border-color: #38bdf8 !important;
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.45) !important;
}

@keyframes audioPulseGlow {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 8px rgba(56, 189, 248, 0.35);
    }
    50% {
        transform: scale(1.04);
        box-shadow: 0 0 18px rgba(56, 189, 248, 0.65);
    }
}

/* ==========================================================================
   NEW MINI-GAMES STYLES (Bubble Pop, Vocab Racer, Scramble, Whack-a-Mole)
   ========================================================================== */

/* Word Scramble */
.scramble-slot {
    width: 44px;
    height: 48px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
    border: 2px dashed rgba(255, 255, 255, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 800;
    color: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}
.scramble-slot.filled {
    border-style: solid;
    border-color: #38bdf8;
    background: rgba(56, 189, 248, 0.2);
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.3);
}
.scramble-slot.correct {
    border-color: #22c55e !important;
    background: rgba(34, 197, 94, 0.35) !important;
    color: #4ade80 !important;
    animation: scrambleSuccess 0.4s ease;
}
.scramble-slot.wrong {
    border-color: #ef4444 !important;
    background: rgba(239, 68, 68, 0.35) !important;
    animation: scrambleShake 0.4s ease;
}
.scramble-tile {
    width: 44px;
    height: 48px;
    border-radius: 10px;
    background: linear-gradient(180deg, #3b82f6 0%, #1d4ed8 100%);
    border: none;
    box-shadow: 0 4px 0 #1e40af, 0 6px 14px rgba(0, 0, 0, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 800;
    color: #fff;
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.1s ease, opacity 0.2s;
    user-select: none;
}
.scramble-tile:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1e40af;
}
.scramble-tile.used {
    opacity: 0.25;
    pointer-events: none;
    transform: scale(0.9);
}
@keyframes scrambleSuccess {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}
@keyframes scrambleShake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

/* Whack-a-Mole */
.whack-hole {
    aspect-ratio: 1 / 1;
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle, #292524 30%, #1c1917 80%);
    border-radius: 50%;
    border: 5px solid #78350f;
    box-shadow: inset 0 8px 16px rgba(0,0,0,0.8), 0 4px 8px rgba(0,0,0,0.4);
    touch-action: manipulation;
}
.whack-mole {
    position: absolute;
    bottom: -110%;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    cursor: pointer;
    transition: bottom 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}
.whack-mole.up {
    bottom: 0%;
}
.mole-sign {
    background: #fef08a;
    color: #854d0e;
    font-weight: 800;
    font-size: 0.72rem;
    padding: 3px 6px;
    border-radius: 6px;
    border: 2px solid #ca8a04;
    max-width: 92%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: 0 2px 4px rgba(0,0,0,0.35);
    margin-bottom: 2px;
    pointer-events: none;
}
.mole-body {
    font-size: 2.3rem;
    line-height: 1;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.5));
    pointer-events: none;
    transition: transform 0.15s ease;
}
.whack-mole.hit .mole-body {
    transform: scale(0.8) rotate(15deg);
}
.mole-hit-effect {
    position: absolute;
    top: 20%;
    font-weight: 900;
    font-size: 1.1rem;
    pointer-events: none;
    animation: moleFloatUp 0.6s ease forwards;
}
@keyframes moleFloatUp {
    0% { transform: translateY(0) scale(0.7); opacity: 1; }
    100% { transform: translateY(-24px) scale(1.2); opacity: 0; }
}

/* 4 NEW MINI-GAMES STYLES */
.space-touch-controls button,
.archer-touch-controls button,
.diver-touch-controls button,
.pizza-touch-controls button {
    touch-action: manipulation;
    user-select: none;
    transition: transform 0.1s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.space-touch-controls button:active,
.archer-touch-controls button:active,
.diver-touch-controls button:active,
.pizza-touch-controls button:active {
    transform: scale(0.94);
    filter: brightness(1.2);
}

#space-canvas,
#archer-canvas,
#diver-canvas,
#pizza-canvas {
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}

/* ==========================================================================
   NOTIFICATION & EMAIL SETTINGS STYLES (GLASSMORPHISM & ACCESSIBLE TOGGLE)
   ========================================================================== */
.setting-notif-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.setting-notif-card:hover {
    border-color: rgba(88, 204, 2, 0.45) !important;
    box-shadow: 0 6px 20px rgba(88, 204, 2, 0.12);
}

.setting-notif-card.setting-highlight-pulse {
    animation: settingPulseHighlight 2.5s ease-out;
}

@keyframes settingPulseHighlight {
    0% {
        box-shadow: 0 0 0 0 rgba(88, 204, 2, 0.7);
        border-color: #58cc02 !important;
        transform: scale(1.02);
    }
    50% {
        box-shadow: 0 0 25px 6px rgba(88, 204, 2, 0.5);
        border-color: #58cc02 !important;
        transform: scale(1.02);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(88, 204, 2, 0);
        transform: scale(1);
    }
}

.setting-notif-icon-box {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(88, 204, 2, 0.14);
    border: 1px solid rgba(88, 204, 2, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.25s ease;
}

.setting-notif-icon-box.disabled {
    background: rgba(148, 163, 184, 0.12);
    border-color: rgba(148, 163, 184, 0.25);
}

.badge-notif-status {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
    transition: all 0.25s ease;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.badge-notif-status.active {
    background: rgba(88, 204, 2, 0.2);
    color: #4ade80;
    border: 1px solid rgba(88, 204, 2, 0.45);
}

.badge-notif-status.inactive {
    background: rgba(148, 163, 184, 0.18);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.3);
}

/* Custom iOS/Modern Toggle Switch */
.custom-switch {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 28px;
    flex-shrink: 0;
    cursor: pointer;
}

.custom-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.custom-switch .slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(100, 116, 139, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 34px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.custom-switch .slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 2px;
    background-color: #ffffff;
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.custom-switch input:checked + .slider {
    background: linear-gradient(135deg, #58cc02, #22c55e);
    border-color: rgba(88, 204, 2, 0.8);
    box-shadow: 0 0 12px rgba(88, 204, 2, 0.45), inset 0 1px 2px rgba(255, 255, 255, 0.2);
}

.custom-switch input:checked + .slider:before {
    transform: translateX(23px);
    background-color: #ffffff;
}

.custom-switch:hover .slider {
    border-color: rgba(255, 255, 255, 0.35);
}

.custom-switch input:disabled + .slider {
    opacity: 0.5;
    cursor: not-allowed;
}

/* =================================================== */
/* ONBOARDING MODAL & STARTER GUIDE STYLES             */
/* =================================================== */
#modal-onboarding {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 18, 22, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 2800;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    animation: fadeIn 0.25s ease-out;
}

#modal-onboarding.hidden {
    display: none !important;
}

#modal-onboarding .onboarding-card {
    position: relative;
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(145deg, rgba(19, 31, 36, 0.96), rgba(15, 23, 42, 0.96));
    border: 2px solid rgba(28, 176, 246, 0.55);
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.75), 0 0 35px rgba(28, 176, 246, 0.2);
    overflow: hidden;
    animation: slideUpScale 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.onboarding-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.4rem 0.5rem 1.4rem;
}

.onboarding-step-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(28, 176, 246, 0.15);
    border: 1px solid rgba(28, 176, 246, 0.3);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #38bdf8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.onboarding-close-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    font-size: 1.2rem;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.onboarding-close-btn:hover {
    background: rgba(255, 75, 75, 0.2);
    color: #ff4b4b;
    border-color: rgba(255, 75, 75, 0.4);
}

.onboarding-body {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 1.4rem 1rem 1.4rem;
}

.onboarding-slide {
    display: none;
    animation: fadeInScale 0.3s ease;
}

.onboarding-slide.active {
    display: block;
}

.onboarding-hero-icon {
    width: 72px;
    height: 72px;
    margin: 0.4rem auto 1rem auto;
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.onboarding-hero-blue {
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.25), rgba(2, 132, 199, 0.4));
    border: 2px solid #1cb0f6;
    color: #38bdf8;
}

.onboarding-hero-green {
    background: linear-gradient(135deg, rgba(88, 204, 2, 0.25), rgba(34, 197, 94, 0.4));
    border: 2px solid #58cc02;
    color: #4ade80;
}

.onboarding-hero-orange {
    background: linear-gradient(135deg, rgba(255, 150, 0, 0.25), rgba(234, 88, 12, 0.4));
    border: 2px solid #ff9600;
    color: #fb923c;
}

.onboarding-hero-purple {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.25), rgba(126, 34, 206, 0.4));
    border: 2px solid #a855f7;
    color: #c084fc;
}

.onboarding-title {
    font-size: 1.28rem;
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    margin-bottom: 0.6rem;
    line-height: 1.35;
}

.onboarding-subtitle {
    font-size: 0.9rem;
    color: #cbd5e1;
    text-align: center;
    margin-bottom: 1.2rem;
    line-height: 1.5;
}

.onboarding-feature-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 0.5rem;
}

.onboarding-feature-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 10px 14px;
}

.onboarding-feature-icon {
    font-size: 1.25rem;
    margin-top: 2px;
    flex-shrink: 0;
}

.onboarding-feature-text h4 {
    font-size: 0.92rem;
    font-weight: 700;
    color: #f8fafc;
    margin-bottom: 2px;
}

.onboarding-feature-text p {
    font-size: 0.8rem;
    color: #94a3b8;
    line-height: 1.4;
    margin: 0;
}

.onboarding-footer {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0.8rem 1.4rem 1.2rem 1.4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.2);
}

.onboarding-dots-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
}

.onboarding-dot {
    width: 8px;
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: all 0.25s ease;
}

.onboarding-dot.active {
    width: 22px;
    background: var(--primary, #1cb0f6);
    box-shadow: 0 0 8px rgba(28, 176, 246, 0.6);
}

.onboarding-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.btn-onboarding-skip {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
    transition: color 0.2s;
}

.btn-onboarding-skip:hover {
    color: #ffffff;
    text-decoration: underline;
}

.btn-onboarding-next {
    background: linear-gradient(135deg, #1cb0f6, #0284c7);
    border: none;
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 700;
    padding: 10px 22px;
    border-radius: 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(28, 176, 246, 0.4);
    transition: all 0.2s;
    min-width: 120px;
    justify-content: center;
}

.btn-onboarding-next:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(28, 176, 246, 0.6);
}

.btn-onboarding-prev {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 10px 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-onboarding-prev:hover {
    background: rgba(255, 255, 255, 0.15);
}

@keyframes slideUpScale {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.98);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@media (max-width: 480px) {
#modal-onboarding .onboarding-card {
        border-radius: 18px;
    }
    .onboarding-header {
        padding: 0.8rem 1rem 0.4rem 1rem;
    }
    .onboarding-body {
        padding: 0.4rem 1rem 0.8rem 1rem;
    }
    .onboarding-footer {
        padding: 0.8rem 1rem 1rem 1rem;
    }
    .onboarding-title {
        font-size: 1.15rem;
    }
    .header-help-text {
        display: none;
    }
}

/* ========================================================= */
/* GAME HUB 2.0 - RICH GAMIFIED CARDS                        */
/* ========================================================= */

.games-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
    gap: 20px !important;
    margin-top: 1.5rem !important;
    width: 100% !important;
}

@media(max-width: 640px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
    }
}

.game-card-v2 {
    background: rgba(22, 36, 49, 0.92) !important;
    backdrop-filter: blur(14px) !important;
    border: 2px solid rgba(255, 255, 255, 0.1) !important;
    border-bottom: 5px solid rgba(11, 18, 25, 0.95) !important;
    border-radius: 24px !important;
    padding: 20px 18px 18px 18px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    position: relative !important;
    overflow: hidden !important;
    cursor: pointer !important;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
}

.game-card-v2:hover {
    transform: translateY(-6px) !important;
    border-color: #38bdf8 !important;
    border-bottom-color: #0284c7 !important;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55), 0 0 25px rgba(28, 176, 246, 0.25) !important;
}

.game-card-v2:active {
    transform: translateY(2px) !important;
    border-bottom-width: 2px !important;
}

.game-card-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 10px;
    gap: 6px;
}

.game-tag {
    font-size: 0.74rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    letter-spacing: 0.3px;
    background: rgba(255, 255, 255, 0.08);
    color: #94a3b8;
}

.tag-reflex { background: rgba(56, 189, 248, 0.15); color: #38bdf8; border: 1px solid rgba(56, 189, 248, 0.3); }
.tag-vocab { background: rgba(74, 222, 128, 0.15); color: #4ade80; border: 1px solid rgba(74, 222, 128, 0.3); }
.tag-speed { background: rgba(251, 146, 60, 0.15); color: #fb923c; border: 1px solid rgba(251, 146, 60, 0.3); }
.tag-memory { background: rgba(192, 132, 252, 0.15); color: #c084fc; border: 1px solid rgba(192, 132, 252, 0.3); }
.tag-action { background: rgba(248, 113, 113, 0.15); color: #f87171; border: 1px solid rgba(248, 113, 113, 0.3); }
.tag-spelling { background: rgba(244, 114, 182, 0.15); color: #f472b6; border: 1px solid rgba(244, 114, 182, 0.3); }
.tag-relax { background: rgba(34, 211, 238, 0.15); color: #22d3ee; border: 1px solid rgba(34, 211, 238, 0.3); }
.tag-focus { background: rgba(251, 113, 133, 0.15); color: #fb7185; border: 1px solid rgba(251, 113, 133, 0.3); }
.tag-adventure { background: rgba(14, 165, 233, 0.15); color: #38bdf8; border: 1px solid rgba(14, 165, 233, 0.3); }

.game-badge-xp {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    font-weight: 800;
    color: #fbbf24;
    background: rgba(245, 158, 11, 0.18);
    border: 1px solid rgba(251, 191, 36, 0.3);
    padding: 3px 8px;
    border-radius: 10px;
    white-space: nowrap;
}

[data-theme="light"] .game-badge-xp {
    color: #d97706;
    background: linear-gradient(135deg, rgba(254, 243, 199, 0.9), rgba(253, 230, 138, 0.9));
    border-color: rgba(245, 158, 11, 0.35);
}

.game-badge-hot {
    background: linear-gradient(135deg, #ef4444, #f97316);
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
    animation: hotGlow 2s ease-in-out infinite;
}

@keyframes hotGlow {
    0%, 100% { transform: scale(1); opacity: 0.95; }
    50% { transform: scale(1.05); opacity: 1; }
}

.game-icon-box {
    width: 68px;
    height: 68px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.1rem;
    margin: 8px 0 12px 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

.game-card-v2:hover .game-icon-box {
    transform: scale(1.15) rotate(4deg);
}

.game-box-flappy { background: rgba(28, 176, 246, 0.18); color: #38bdf8; border: 1px solid rgba(28, 176, 246, 0.4); box-shadow: 0 0 20px rgba(28, 176, 246, 0.25); }
.game-box-snake { background: rgba(88, 204, 2, 0.18); color: #4ade80; border: 1px solid rgba(88, 204, 2, 0.4); box-shadow: 0 0 20px rgba(88, 204, 2, 0.25); }
.game-box-worddrop { background: rgba(255, 150, 0, 0.18); color: #fb923c; border: 1px solid rgba(255, 150, 0, 0.4); box-shadow: 0 0 20px rgba(255, 150, 0, 0.25); }
.game-box-memory { background: rgba(168, 85, 247, 0.18); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.4); box-shadow: 0 0 20px rgba(168, 85, 247, 0.25); }
.game-box-ninja { background: rgba(239, 68, 68, 0.18); color: #f87171; border: 1px solid rgba(239, 68, 68, 0.4); box-shadow: 0 0 20px rgba(239, 68, 68, 0.25); }
.game-box-rescue { background: rgba(236, 72, 153, 0.18); color: #f472b6; border: 1px solid rgba(236, 72, 153, 0.4); box-shadow: 0 0 20px rgba(236, 72, 153, 0.25); }
.game-box-bubble { background: rgba(6, 182, 212, 0.18); color: #22d3ee; border: 1px solid rgba(6, 182, 212, 0.4); box-shadow: 0 0 20px rgba(6, 182, 212, 0.25); }
.game-box-racer { background: rgba(245, 158, 11, 0.18); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.4); box-shadow: 0 0 20px rgba(245, 158, 11, 0.25); }
.game-box-scramble { background: rgba(16, 185, 129, 0.18); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.4); box-shadow: 0 0 20px rgba(16, 185, 129, 0.25); }
.game-box-whack { background: rgba(251, 146, 60, 0.18); color: #fb923c; border: 1px solid rgba(251, 146, 60, 0.4); box-shadow: 0 0 20px rgba(251, 146, 60, 0.25); }
.game-box-space { background: rgba(129, 140, 248, 0.18); color: #a5b4fc; border: 1px solid rgba(129, 140, 248, 0.4); box-shadow: 0 0 20px rgba(129, 140, 248, 0.25); }
.game-box-archer { background: rgba(244, 63, 94, 0.18); color: #fb7185; border: 1px solid rgba(244, 63, 94, 0.4); box-shadow: 0 0 20px rgba(244, 63, 94, 0.25); }
.game-box-diver { background: rgba(2, 132, 199, 0.18); color: #38bdf8; border: 1px solid rgba(2, 132, 199, 0.4); box-shadow: 0 0 20px rgba(2, 132, 199, 0.25); }
.game-box-pizza { background: rgba(234, 179, 8, 0.18); color: #fde047; border: 1px solid rgba(234, 179, 8, 0.4); box-shadow: 0 0 20px rgba(234, 179, 8, 0.25); }

/* Game Icon Box Pastels in Light Theme */
[data-theme="light"] .game-box-flappy { background: linear-gradient(135deg, #e0f2fe, #bae6fd); color: #0284c7; border: 1.5px solid #7dd3fc; }
[data-theme="light"] .game-box-snake { background: linear-gradient(135deg, #dcfce7, #bbf7d0); color: #16a34a; border: 1.5px solid #86efac; }
[data-theme="light"] .game-box-worddrop { background: linear-gradient(135deg, #ffedd5, #fed7aa); color: #ea580c; border: 1.5px solid #fdba74; }
[data-theme="light"] .game-box-memory { background: linear-gradient(135deg, #f3e8ff, #e9d5ff); color: #9333ea; border: 1.5px solid #d8b4fe; }
[data-theme="light"] .game-box-ninja { background: linear-gradient(135deg, #ffe4e6, #fecdd3); color: #e11d48; border: 1.5px solid #fda4af; }
[data-theme="light"] .game-box-rescue { background: linear-gradient(135deg, #fce7f3, #fbcfe8); color: #db2777; border: 1.5px solid #f9a8d4; }
[data-theme="light"] .game-box-bubble { background: linear-gradient(135deg, #cffafe, #a5f3fc); color: #0891b2; border: 1.5px solid #67e8f9; }
[data-theme="light"] .game-box-racer { background: linear-gradient(135deg, #fef3c7, #fde68a); color: #d97706; border: 1.5px solid #fcd34d; }
[data-theme="light"] .game-box-scramble { background: linear-gradient(135deg, #d1fae5, #a7f3d0); color: #059669; border: 1.5px solid #6ee7b7; }
[data-theme="light"] .game-box-whack { background: linear-gradient(135deg, #ffedd5, #fed7aa); color: #c2410c; border: 1.5px solid #fdba74; }
[data-theme="light"] .game-box-space { background: linear-gradient(135deg, #e0e7ff, #c7d2fe); color: #4f46e5; border: 1.5px solid #a5b4fc; }
[data-theme="light"] .game-box-archer { background: linear-gradient(135deg, #ffe4e6, #fecdd3); color: #be123c; border: 1.5px solid #fda4af; }
[data-theme="light"] .game-box-diver { background: linear-gradient(135deg, #e0f2fe, #bae6fd); color: #0369a1; border: 1.5px solid #7dd3fc; }
[data-theme="light"] .game-box-pizza { background: linear-gradient(135deg, #fef9c3, #fef08a); color: #ca8a04; border: 1.5px solid #fde047; }

.game-card-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 6px;
    letter-spacing: -0.01em;
}

.game-card-desc {
    font-size: 0.84rem;
    color: #94a3b8;
    line-height: 1.45;
    margin-bottom: 14px;
    flex-grow: 1;
}

/* Duolingo 3D Chunky Action Button */
.game-card-cta {
    width: 100%;
    padding: 10px 16px;
    border-radius: 16px;
    background: #1cb0f6;
    border: none;
    border-bottom: 4px solid #1899d6;
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(28, 176, 246, 0.25);
    transition: all 0.15s ease;
    user-select: none;
    text-transform: uppercase;
}

.game-card-v2:hover .game-card-cta {
    background: #23bbf8;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(28, 176, 246, 0.4);
}

.game-card-v2:active .game-card-cta {
    transform: translateY(2px);
    border-bottom-width: 1px;
}

/* ========================================================= */
/* LEADERBOARD 3D PODIUM STYLES                              */
/* ========================================================= */

.leaderboard-podium-container {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 14px;
    margin: 1.5rem auto 1.5rem auto;
    max-width: 580px;
    padding: 10px 10px 0 10px;
}

.podium-slot {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.podium-slot-1 { order: 2; z-index: 3; }
.podium-slot-2 { order: 1; z-index: 2; }
.podium-slot-3 { order: 3; z-index: 1; }

.podium-user-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 8px;
    position: relative;
    width: 100%;
}

.podium-crown-icon {
    position: absolute;
    top: -24px;
    font-size: 1.6rem;
    color: #ffd700;
    filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.8));
    animation: crownFloat 2.5s ease-in-out infinite;
}

@keyframes crownFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

.podium-avatar-ring {
    position: relative;
    border-radius: 50%;
    padding: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
}

.podium-slot-1 .podium-avatar-ring {
    background: linear-gradient(135deg, #ffd700, #ff9600);
    box-shadow: 0 0 25px rgba(255, 215, 0, 0.6);
}

.podium-slot-2 .podium-avatar-ring {
    background: linear-gradient(135deg, #e2e8f0, #94a3b8);
    box-shadow: 0 0 16px rgba(226, 232, 240, 0.4);
}

.podium-slot-3 .podium-avatar-ring {
    background: linear-gradient(135deg, #f97316, #b45309);
    box-shadow: 0 0 16px rgba(249, 115, 22, 0.4);
}

.podium-user-name {
    font-size: 0.86rem;
    font-weight: 700;
    color: #ffffff;
    max-width: 110px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.2;
}

.podium-user-grade {
    font-size: 0.7rem;
    color: #94a3b8;
    margin-top: 2px;
}

.podium-user-xp {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 10px;
    margin-top: 4px;
}

.podium-slot-1 .podium-user-xp { background: rgba(255, 215, 0, 0.2); color: #ffd700; border: 1px solid rgba(255, 215, 0, 0.4); }
.podium-slot-2 .podium-user-xp { background: rgba(226, 232, 240, 0.15); color: #e2e8f0; border: 1px solid rgba(226, 232, 240, 0.3); }
.podium-slot-3 .podium-user-xp { background: rgba(249, 115, 22, 0.15); color: #fb923c; border: 1px solid rgba(249, 115, 22, 0.3); }

/* Bục 3D */
.podium-pillar {
    width: 100%;
    border-radius: 16px 16px 0 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 10px;
    font-weight: 900;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 2px 0 rgba(255, 255, 255, 0.25);
}

.podium-slot-1 .podium-pillar {
    height: 110px;
    background: linear-gradient(180deg, rgba(255, 215, 0, 0.4) 0%, rgba(180, 83, 9, 0.6) 100%);
    border: 1.5px solid rgba(255, 215, 0, 0.5);
    border-bottom: none;
    color: #ffd700;
    font-size: 2.2rem;
}

.podium-slot-2 .podium-pillar {
    height: 80px;
    background: linear-gradient(180deg, rgba(226, 232, 240, 0.3) 0%, rgba(100, 116, 139, 0.5) 100%);
    border: 1.5px solid rgba(226, 232, 240, 0.4);
    border-bottom: none;
    color: #e2e8f0;
    font-size: 1.8rem;
}

.podium-slot-3 .podium-pillar {
    height: 65px;
    background: linear-gradient(180deg, rgba(249, 115, 22, 0.3) 0%, rgba(154, 52, 18, 0.5) 100%);
    border: 1.5px solid rgba(249, 115, 22, 0.4);
    border-bottom: none;
    color: #fb923c;
    font-size: 1.6rem;
}

.podium-pillar-num {
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* Danh sách rank 4-10 */
.leaderboard-list-card {
    background: rgba(20, 33, 45, 0.75);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 10px;
    max-width: 580px;
    margin: 0 auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.leaderboard-item-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-radius: 14px;
    margin-bottom: 4px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.leaderboard-item-row:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(3px);
}

.leaderboard-item-me {
    background: rgba(28, 176, 246, 0.15) !important;
    border: 1px solid rgba(28, 176, 246, 0.35) !important;
}

.leaderboard-rank-col {
    display: flex;
    align-items: center;
    gap: 12px;
}

.leaderboard-rank-num {
    font-size: 0.95rem;
    font-weight: 800;
    color: #94a3b8;
    width: 24px;
    text-align: center;
}

.leaderboard-info-col {
    display: flex;
    align-items: center;
    gap: 10px;
}

.leaderboard-name-text {
    font-size: 0.92rem;
    font-weight: 700;
    color: #ffffff;
}

.leaderboard-grade-pill {
    font-size: 0.7rem;
    color: #94a3b8;
    background: rgba(255, 255, 255, 0.06);
    padding: 2px 6px;
    border-radius: 8px;
    margin-left: 6px;
}

.leaderboard-xp-col {
    font-size: 1rem;
    font-weight: 800;
    color: #38bdf8;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Responsive polish for Floating Island Navigation on Mobile */
@media (max-width: 480px) {
    .bottom-nav {
        width: calc(100% - 16px) !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        bottom: 8px !important;
        padding: 5px 6px !important;
        gap: 2px !important;
        border-radius: 24px !important;
    }
    .bottom-nav .nav-item {
        padding: 6px 4px !important;
        gap: 2px !important;
        min-width: 0 !important;
        flex: 1 !important;
    }
    .bottom-nav .nav-icon {
        font-size: 1.05rem !important;
    }
    .bottom-nav .nav-item span:not(.nav-icon) {
        font-size: 0.62rem !important;
        letter-spacing: -0.2px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        max-width: 100% !important;
    }
}

/* ==========================================
   AUTH PAGE DEDICATED SCROLL OVERRIDE
   ========================================== */
html:has(body.auth-page),
body.auth-page {
    height: auto !important;
    min-height: 100% !important;
    min-height: 100dvh !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    position: static !important;
}

body.auth-page {
    display: flex !important;
    flex-direction: column !important;
}

body.auth-page .container {
    flex-grow: 1 !important;
    height: auto !important;
    min-height: auto !important;
    overflow: visible !important;
    padding-bottom: 6rem !important;
}

body.auth-page .onboarding-card {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    margin-bottom: 4rem !important;
}

/* ==========================================================================
   THEME SWITCHER TOGGLE SYSTEM (DARK / DISNEY MAGIC LIGHT)
   ========================================================================== */
.theme-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    background: rgba(255, 255, 255, 0.08);
    border: 1.5px solid rgba(255, 200, 0, 0.45);
    color: #fbbf24;
    padding: 7px 15px;
    border-radius: 22px;
    font-size: 0.86rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.2);
    user-select: none;
    -webkit-user-select: none;
    white-space: nowrap;
}

.theme-toggle-btn:hover {
    transform: translateY(-2px) scale(1.04);
    border-color: #f59e0b;
    box-shadow: 0 6px 22px rgba(245, 158, 11, 0.4);
}

.theme-toggle-btn:active {
    transform: translateY(1px) scale(0.97);
}

.theme-toggle-btn i {
    font-size: 1rem;
    transition: transform 0.4s ease;
}

.theme-toggle-btn:hover i {
    transform: rotate(30deg);
}

.theme-toggle-btn.app-theme-toggle-pill {
    padding: 5px 11px;
    border-radius: 20px;
    font-size: 0.84rem;
}

/* Settings Tab Theme Visual Selection Grid */
.theme-selection-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 10px;
}

@media (max-width: 480px) {
    .theme-selection-grid {
        grid-template-columns: 1fr;
    }
}

.theme-option-box {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.25s ease;
}

.theme-option-box:hover {
    transform: translateY(-2px);
    border-color: rgba(28, 176, 246, 0.45);
}

.theme-option-box.active-theme {
    border-color: #1cb0f6;
    background: rgba(28, 176, 246, 0.15);
    box-shadow: 0 0 18px rgba(28, 176, 246, 0.25);
}

.theme-option-preview {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.dark-preview {
    background: #0f1720;
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.35);
}

.light-preview {
    background: linear-gradient(135deg, #f0f9ff, #fef3c7);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.4);
}

.theme-option-info {
    display: flex;
    flex-direction: column;
}

.theme-option-info strong {
    font-size: 0.92rem;
    color: var(--text-main);
}

.theme-option-info span {
    font-size: 0.74rem;
    color: var(--text-muted);
}

/* ==========================================================================
   DISNEY MAGIC LIGHT THEME ([data-theme="light"])
   Dreamy fairytale sky, glowing stardust, frosted crystal glass, rich contrast
   ========================================================================== */
[data-theme="light"] {
    --primary: #0284c7;
    --primary-dark: #0369a1;
    --primary-glow: rgba(2, 132, 199, 0.25);
    --secondary: #10b981;
    --secondary-dark: #059669;
    --secondary-glow: rgba(16, 185, 129, 0.25);
    --danger: #ef4444;
    --danger-dark: #dc2626;
    --danger-glow: rgba(239, 68, 68, 0.25);
    --warning: #f59e0b;
    --warning-dark: #d97706;
    --warning-glow: rgba(245, 158, 11, 0.35);
    --orange: #f97316;
    --purple: #8b5cf6;
    --pink: #ec4899;
    --cyan: #06b6d4;
    --bg-color: #f0f7ff;
    --bg-surface: #ffffff;
    --bg-surface-elevated: #f8fafc;
    --text-main: #0f2b48;
    --text-muted: #475569;
    --text-dim: #64748b;
    --card-bg: rgba(255, 255, 255, 0.9);
    --card-border: rgba(2, 132, 199, 0.16);
    --card-border-glow: rgba(245, 158, 11, 0.35);
    --shadow-soft: 0 12px 36px -10px rgba(14, 116, 144, 0.12), 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 25px rgba(2, 132, 199, 0.2);
    --shadow-glow-gold: 0 0 25px rgba(245, 158, 11, 0.3);
}

[data-theme="light"] body {
    background-color: #f0f7ff !important;
    background-image: 
        radial-gradient(circle at 85% 12%, rgba(251, 191, 36, 0.2) 0%, transparent 40%),
        radial-gradient(circle at 15% 25%, rgba(56, 189, 248, 0.22) 0%, transparent 45%),
        radial-gradient(circle at 50% 80%, rgba(192, 132, 252, 0.16) 0%, transparent 50%),
        linear-gradient(180deg, #f0f7ff 0%, #e8f4fc 35%, #fdf4ff 70%, #fefce8 100%) !important;
    background-attachment: fixed !important;
    color: #0f2b48 !important;
}

/* Light Theme Toggle Button Appearance */
[data-theme="light"] .theme-toggle-btn {
    background: rgba(255, 255, 255, 0.95) !important;
    border: 1.5px solid rgba(139, 92, 246, 0.45) !important;
    color: #7c3aed !important;
    box-shadow: 0 4px 14px rgba(139, 92, 246, 0.22) !important;
}

[data-theme="light"] .theme-toggle-btn:hover {
    border-color: #8b5cf6 !important;
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.38) !important;
}

/* Light Navbar */
[data-theme="light"] .navbar {
    background: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
    border-bottom: 2px solid rgba(2, 132, 199, 0.15) !important;
    box-shadow: 0 4px 20px rgba(2, 132, 199, 0.08) !important;
}

[data-theme="light"] .logo-text {
    color: #0284c7 !important;
}

[data-theme="light"] .logo-subtext {
    color: #64748b !important;
}

/* Headings & Text */
[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] .section-title,
[data-theme="light"] .landing-title,
[data-theme="light"] .hero-title,
[data-theme="light"] .roadmap-header h2,
[data-theme="light"] .tab-header h2 {
    color: #0f2b48 !important;
}

[data-theme="light"] .landing-subtitle,
[data-theme="light"] .section-desc,
[data-theme="light"] .hero-subtitle,
[data-theme="light"] .roadmap-header p,
[data-theme="light"] .tab-header p {
    color: #475569 !important;
}

/* Landing Badge */
[data-theme="light"] .landing-badge {
    background: linear-gradient(135deg, rgba(2, 132, 199, 0.12), rgba(245, 158, 11, 0.16)) !important;
    border: 1px solid rgba(2, 132, 199, 0.28) !important;
    color: #0284c7 !important;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.15) !important;
}

/* Social Proof Metric Bar */
[data-theme="light"] .landing-metrics-bar {
    background: rgba(255, 255, 255, 0.92) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.22) !important;
    box-shadow: 0 10px 30px rgba(2, 132, 199, 0.1) !important;
}

[data-theme="light"] .metric-value {
    color: #0284c7 !important;
}

[data-theme="light"] .metric-label {
    color: #64748b !important;
}

[data-theme="light"] .metric-divider {
    background: rgba(2, 132, 199, 0.2) !important;
}

/* Floating Badges */
[data-theme="light"] .hero-floating-badge {
    background: rgba(255, 255, 255, 0.95) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.25) !important;
    color: #0f2b48 !important;
    box-shadow: 0 8px 24px rgba(2, 132, 199, 0.14) !important;
}

/* Bento Feature Cards */
[data-theme="light"] .bento-card {
    background: rgba(255, 255, 255, 0.94) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.16) !important;
    box-shadow: 0 12px 32px rgba(14, 116, 144, 0.08), 0 2px 6px rgba(0, 0, 0, 0.03) !important;
}

[data-theme="light"] .bento-card:hover {
    transform: translateY(-6px);
    border-color: rgba(2, 132, 199, 0.5) !important;
    box-shadow: 0 20px 42px rgba(2, 132, 199, 0.16), 0 0 25px rgba(245, 158, 11, 0.2) !important;
}

[data-theme="light"] .bento-content h3 {
    color: #0f2b48 !important;
}

[data-theme="light"] .bento-content p {
    color: #475569 !important;
}

[data-theme="light"] .bento-card .tag-pill {
    background: #f1f5f9 !important;
    border: 1px solid #e2e8f0 !important;
    color: #0284c7 !important;
}

/* Bento Icons Light Mode */
[data-theme="light"] .icon-blue { background: #e0f2fe !important; color: #0284c7 !important; border-color: #bae6fd !important; }
[data-theme="light"] .icon-green { background: #dcfce7 !important; color: #16a34a !important; border-color: #bbf7d0 !important; }
[data-theme="light"] .icon-orange { background: #ffedd5 !important; color: #ea580c !important; border-color: #fed7aa !important; }
[data-theme="light"] .icon-purple { background: #f3e8ff !important; color: #9333ea !important; border-color: #e9d5ff !important; }
[data-theme="light"] .icon-gold { background: #fef9c3 !important; color: #ca8a04 !important; border-color: #fef08a !important; }
[data-theme="light"] .icon-cyan { background: #cffafe !important; color: #0891b2 !important; border-color: #a5f3fc !important; }

/* Buttons in Disney Light Mode */
[data-theme="light"] .btn-primary,
[data-theme="light"] .landing-btn {
    background: linear-gradient(135deg, #0ea5e9, #0284c7) !important;
    box-shadow: 0 4px 0 #0369a1, 0 8px 20px rgba(14, 165, 233, 0.35) !important;
    color: #ffffff !important;
}

[data-theme="light"] .btn-outline,
[data-theme="light"] .landing-btn-secondary {
    background: rgba(255, 255, 255, 0.92) !important;
    border: 2px solid rgba(2, 132, 199, 0.35) !important;
    color: #0284c7 !important;
    box-shadow: 0 4px 0 rgba(2, 132, 199, 0.12) !important;
}

[data-theme="light"] .btn-outline:hover,
[data-theme="light"] .landing-btn-secondary:hover {
    background: #f0f9ff !important;
    border-color: #0284c7 !important;
}

/* Glass Panels in Light Mode */
[data-theme="light"] .glass-panel {
    background: rgba(255, 255, 255, 0.94) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.16) !important;
    box-shadow: 0 12px 36px rgba(14, 116, 144, 0.08) !important;
}

/* Stat Pills in Header */
[data-theme="light"] .stat-pill {
    background: rgba(255, 255, 255, 0.9) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.22) !important;
    color: #0f2b48 !important;
    box-shadow: 0 2px 8px rgba(2, 132, 199, 0.08) !important;
}

/* Game Cards in Disney Light Mode */
[data-theme="light"] .game-card-v2 {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    border-radius: 24px !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06) !important;
}

[data-theme="light"] .game-card-v2:hover {
    border-color: #38bdf8 !important;
    border-bottom-color: #0284c7 !important;
    box-shadow: 0 16px 36px rgba(2, 132, 199, 0.15), 0 0 0 1px rgba(56, 189, 248, 0.2) !important;
}

[data-theme="light"] .game-card-title {
    color: #0f2b48 !important;
}

[data-theme="light"] .game-card-desc {
    color: #475569 !important;
}

[data-theme="light"] .game-card-cta {
    background: #1cb0f6 !important;
    color: #ffffff !important;
    border: none !important;
    border-bottom: 4px solid #1899d6 !important;
    box-shadow: 0 4px 14px rgba(28, 176, 246, 0.3) !important;
}

[data-theme="light"] .game-card-v2:hover .game-card-cta {
    background: #23bbf8 !important;
    box-shadow: 0 6px 18px rgba(28, 176, 246, 0.45) !important;
}

/* Bottom Navigation */
[data-theme="light"] .bottom-nav {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(14px) !important;
    border-top: 1.5px solid rgba(2, 132, 199, 0.18) !important;
    box-shadow: 0 -4px 20px rgba(2, 132, 199, 0.08) !important;
}

[data-theme="light"] .bottom-nav .nav-item {
    color: #64748b !important;
}

[data-theme="light"] .bottom-nav .nav-item.active {
    color: #0284c7 !important;
}

/* RPG Mascot Dialogue Box */
[data-theme="light"] .ai-mascot-dialogue-card {
    background: rgba(255, 255, 255, 0.94) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.22) !important;
    box-shadow: 0 12px 32px rgba(2, 132, 199, 0.1) !important;
}

[data-theme="light"] .roadmap-header h2 {
    background: linear-gradient(135deg, #0f2b48 30%, #0284c7 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    color: #0f2b48 !important;
}

[data-theme="light"] .mascot-name-title {
    color: #0f2b48 !important;
}

[data-theme="light"] .mascot-speech-bubble {
    background: #ffffff !important;
    border: 1.5px solid rgba(245, 158, 11, 0.35) !important;
    color: #0f2b48 !important;
    box-shadow: 0 6px 18px rgba(245, 158, 11, 0.12) !important;
}

/* Daily Spotlight Card */
[data-theme="light"] .daily-spotlight-card {
    background: linear-gradient(135deg, #ffffff 0%, #fffbeb 60%, #f0fdf4 100%) !important;
    border: 1.5px solid rgba(245, 158, 11, 0.4) !important;
    box-shadow: 0 12px 32px rgba(245, 158, 11, 0.14) !important;
}

[data-theme="light"] .daily-spotlight-title {
    color: #0f2b48 !important;
}

[data-theme="light"] .daily-spotlight-word-box {
    background: rgba(255, 255, 255, 0.95) !important;
    border: 1.5px solid rgba(245, 158, 11, 0.3) !important;
    color: #0f2b48 !important;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.1) !important;
}

[data-theme="light"] .daily-spotlight-word-box strong {
    color: #0284c7 !important;
}

[data-theme="light"] .daily-spotlight-word-box .word-phonetic {
    color: #64748b !important;
}

[data-theme="light"] .btn-word-audio {
    background: rgba(2, 132, 199, 0.12) !important;
    color: #0284c7 !important;
    border: 1px solid rgba(2, 132, 199, 0.25) !important;
}

/* Modals */
[data-theme="light"] .modal-content,
[data-theme="light"] .modal-card {
    background: rgba(255, 255, 255, 0.98) !important;
    border: 1.5px solid rgba(2, 132, 199, 0.25) !important;
    box-shadow: 0 24px 60px rgba(14, 116, 144, 0.16) !important;
    color: #0f2b48 !important;
}

[data-theme="light"] input[type="text"],
[data-theme="light"] input[type="password"],
[data-theme="light"] input[type="email"],
[data-theme="light"] textarea,
[data-theme="light"] select {
    background: #ffffff !important;
    border: 1.5px solid #cbd5e1 !important;
    color: #0f2b48 !important;
}

[data-theme="light"] input:focus,
[data-theme="light"] textarea:focus,
[data-theme="light"] select:focus {
    border-color: #0284c7 !important;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.2) !important;
}

/* Auth Page specific light overrides */
[data-theme="light"] .auth-tabs {
    background: #e2e8f0 !important;
}

[data-theme="light"] .auth-tab {
    color: #64748b !important;
}

[data-theme="light"] .auth-tab.active {
    background: #ffffff !important;
    color: #0284c7 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

/* ==========================================================================
   DUOLINGO x ELSA SPEAK HYBRID: MULTI-TAB UNIVERSAL POLISH
   Roadmap, Quests, Shop, Leaderboard, Account
   ========================================================================== */

/* 1. QUESTS TAB (STARTER QUESTS & DAILY MISSIONS) */
.starter-quests-card {
    background: rgba(22, 36, 49, 0.92) !important;
    border: 2px solid rgba(255, 255, 255, 0.1) !important;
    border-bottom: 5px solid rgba(11, 18, 25, 0.95) !important;
    border-radius: 24px !important;
    padding: 22px 20px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
    margin-bottom: 1.5rem !important;
}

[data-theme="light"] .starter-quests-card {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06) !important;
}

.starter-quests-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    flex-wrap: wrap;
    gap: 10px;
}

.starter-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.starter-gift-bubble {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(135deg, #1cb0f6, #0284c7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: #fff;
    box-shadow: 0 4px 14px rgba(28, 176, 246, 0.35);
    flex-shrink: 0;
}

.starter-title {
    margin: 0;
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 800;
}

[data-theme="light"] .starter-title {
    color: #0f2b48 !important;
}

.starter-subtitle {
    margin: 3px 0 0 0;
    color: #94a3b8;
    font-size: 0.82rem;
}

[data-theme="light"] .starter-subtitle {
    color: #475569 !important;
}

.starter-count-badge {
    background: rgba(88, 204, 2, 0.2);
    color: #4ade80;
    border: 1.5px solid rgba(88, 204, 2, 0.4);
    font-weight: 800;
    padding: 5px 12px;
    border-radius: 14px;
    font-size: 0.82rem;
    white-space: nowrap;
}

[data-theme="light"] .starter-count-badge {
    background: #dcfce7 !important;
    color: #16a34a !important;
    border-color: #86efac !important;
}

/* 3D Progress Bar */
.starter-progress-track {
    height: 12px;
    margin-bottom: 1.25rem;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

[data-theme="light"] .starter-progress-track {
    background: #e2e8f0 !important;
    border-color: #cbd5e1 !important;
}

.starter-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #1cb0f6, #58cc02);
    border-radius: 10px;
    box-shadow: 0 0 12px rgba(88, 204, 2, 0.5);
    transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Quest Items */
.starter-quests-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.starter-quest-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 2px solid rgba(255, 255, 255, 0.08);
    border-bottom: 3px solid rgba(0, 0, 0, 0.4);
    border-radius: 18px;
    padding: 12px 16px;
    flex-wrap: wrap;
    transition: all 0.2s ease;
}

.starter-quest-item:hover {
    transform: translateY(-2px);
    border-color: rgba(56, 189, 248, 0.4);
}

.starter-quest-item.is-completed {
    background: rgba(88, 204, 2, 0.05);
    border-color: rgba(88, 204, 2, 0.25);
}

[data-theme="light"] .starter-quest-item {
    background: #f8fafc !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 3px solid #cbd5e1 !important;
}

[data-theme="light"] .starter-quest-item:hover {
    border-color: #38bdf8 !important;
    background: #f0f9ff !important;
}

[data-theme="light"] .starter-quest-item.is-completed {
    background: #f0fdf4 !important;
    border-color: #86efac !important;
}

.quest-item-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 200px;
}

.quest-icon-bubble {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.quest-icon-bubble.bubble-active {
    background: rgba(28, 176, 246, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(28, 176, 246, 0.3);
}

.quest-icon-bubble.bubble-done {
    background: rgba(88, 204, 2, 0.18);
    color: #4ade80;
    border: 1px solid rgba(88, 204, 2, 0.35);
}

[data-theme="light"] .quest-icon-bubble.bubble-active {
    background: #e0f2fe !important;
    color: #0284c7 !important;
    border-color: #7dd3fc !important;
}

[data-theme="light"] .quest-icon-bubble.bubble-done {
    background: #dcfce7 !important;
    color: #16a34a !important;
    border-color: #86efac !important;
}

.quest-text-block {
    flex: 1;
}

.quest-title {
    margin: 0;
    color: #ffffff;
    font-size: 0.96rem;
    font-weight: 700;
}

.starter-quest-item.is-completed .quest-title {
    color: #94a3b8;
    text-decoration: line-through;
}

[data-theme="light"] .quest-title {
    color: #0f2b48 !important;
}

[data-theme="light"] .starter-quest-item.is-completed .quest-title {
    color: #64748b !important;
}

.quest-desc {
    margin: 3px 0 0 0;
    color: #64748b;
    font-size: 0.8rem;
}

[data-theme="light"] .quest-desc {
    color: #64748b !important;
}

.quest-item-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.quest-reward-pill {
    font-size: 0.82rem;
    font-weight: 800;
    color: #fbbf24;
    background: rgba(245, 158, 11, 0.16);
    border: 1px solid rgba(251, 191, 36, 0.3);
    padding: 4px 10px;
    border-radius: 12px;
    white-space: nowrap;
}

[data-theme="light"] .quest-reward-pill {
    color: #d97706 !important;
    background: #fef3c7 !important;
    border-color: #fcd34d !important;
}

/* Duolingo 3D Quest Button */
.btn-quest-action {
    background: #1cb0f6;
    color: #ffffff;
    border: none;
    border-bottom: 3px solid #1899d6;
    font-size: 0.84rem;
    font-weight: 800;
    padding: 7px 16px;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(28, 176, 246, 0.25);
    transition: all 0.15s ease;
    user-select: none;
    white-space: nowrap;
}

.btn-quest-action:hover {
    background: #23bbf8;
    transform: translateY(-1px);
    box-shadow: 0 5px 12px rgba(28, 176, 246, 0.35);
}

.btn-quest-action:active {
    transform: translateY(2px);
    border-bottom-width: 1px;
}

.quest-claimed-chip {
    font-size: 0.8rem;
    font-weight: 800;
    color: #4ade80;
    background: rgba(88, 204, 2, 0.15);
    padding: 5px 12px;
    border-radius: 12px;
    border: 1.5px solid rgba(88, 204, 2, 0.35);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

[data-theme="light"] .quest-claimed-chip {
    background: #dcfce7 !important;
    color: #16a34a !important;
    border-color: #86efac !important;
}

/* 2. LEADERBOARD TAB (PODIUM CONTRAST & DUOLINGO LEAGUE ROWS) */
.leaderboard-student-name {
    font-weight: 700;
    color: #ffffff;
    font-size: 0.96rem;
}

.leaderboard-student-name.is-me {
    color: #38bdf8;
}

.leaderboard-student-grade {
    font-size: 0.78rem;
    color: #94a3b8;
}

[data-theme="light"] .podium-user-name {
    color: #0f2b48 !important;
}

[data-theme="light"] .podium-user-grade {
    color: #475569 !important;
}

[data-theme="light"] .podium-user-xp {
    color: #0284c7 !important;
    background: rgba(2, 132, 199, 0.1) !important;
}

[data-theme="light"] .leaderboard-student-name {
    color: #0f2b48 !important;
}

[data-theme="light"] .leaderboard-student-name.is-me {
    color: #0284c7 !important;
}

[data-theme="light"] .leaderboard-student-grade {
    color: #64748b !important;
}

[data-theme="light"] #screen-leaderboard .table-container {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    border-radius: 24px !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06) !important;
    overflow: hidden !important;
}

[data-theme="light"] #screen-leaderboard th {
    color: #475569 !important;
    border-bottom: 2px solid #e2e8f0 !important;
    background: #f8fafc !important;
}

[data-theme="light"] #screen-leaderboard td {
    border-bottom: 1px solid #f1f5f9 !important;
}

[data-theme="light"] #screen-leaderboard tr.leaderboard-row-me {
    background: #f0f9ff !important;
}

/* 3. SHOP TAB (WALLET BAR & DUOLINGO 3D BUTTONS) */
.shop-wallet-panel {
    background: rgba(22, 36, 49, 0.92) !important;
    border: 2px solid rgba(255, 255, 255, 0.1) !important;
    border-bottom: 5px solid rgba(11, 18, 25, 0.95) !important;
    border-radius: 24px !important;
    padding: 18px 24px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
}

[data-theme="light"] .shop-wallet-panel {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05) !important;
}

[data-theme="light"] .shop-wallet-lbl {
    color: #475569 !important;
}

.shop-utility-card {
    background: rgba(22, 36, 49, 0.92) !important;
    border: 2px solid rgba(255, 255, 255, 0.1) !important;
    border-bottom: 5px solid rgba(11, 18, 25, 0.95) !important;
    border-radius: 24px !important;
    padding: 20px 22px !important;
    margin-bottom: 1.1rem !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.shop-utility-card:hover {
    transform: translateY(-4px) !important;
    border-color: #38bdf8 !important;
}

[data-theme="light"] .shop-utility-card {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05) !important;
}

[data-theme="light"] .shop-utility-card:hover {
    border-color: #38bdf8 !important;
    box-shadow: 0 14px 32px rgba(2, 132, 199, 0.12) !important;
}

.shop-utility-title {
    color: #ffffff !important;
    font-size: 1.15rem !important;
    font-weight: 800 !important;
}

[data-theme="light"] .shop-utility-title {
    color: #0f2b48 !important;
}

.shop-utility-desc {
    color: #94a3b8 !important;
    font-size: 0.86rem !important;
}

[data-theme="light"] .shop-utility-desc {
    color: #475569 !important;
}

/* Duolingo 3D Buttons for Shop */
.btn-utility-buy {
    font-family: inherit;
    font-weight: 800 !important;
    font-size: 0.88rem !important;
    padding: 10px 18px !important;
    border-radius: 16px !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.15s ease !important;
    user-select: none !important;
}

.btn-buy-coins {
    background: #f59e0b !important;
    border-bottom: 4px solid #d97706 !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3) !important;
}

.btn-buy-coins:hover {
    background: #fbbf24 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 18px rgba(245, 158, 11, 0.45) !important;
}

.btn-buy-coins:active {
    transform: translateY(2px) !important;
    border-bottom-width: 1px !important;
}

.btn-buy-heart {
    background: #ef4444 !important;
    border-bottom: 4px solid #dc2626 !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3) !important;
}

.btn-buy-heart:hover {
    background: #f87171 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 18px rgba(239, 68, 68, 0.45) !important;
}

.btn-buy-heart:active {
    transform: translateY(2px) !important;
    border-bottom-width: 1px !important;
}

.btn-buy-xp {
    background: #10b981 !important;
    border-bottom: 4px solid #059669 !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3) !important;
}

.btn-buy-xp:hover {
    background: #34d399 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.45) !important;
}

.btn-buy-xp:active {
    transform: translateY(2px) !important;
    border-bottom-width: 1px !important;
}

/* 4. ROADMAP TAB (UNIT BANNER, LESSON NODES & SPOTLIGHT BUTTONS) */
.topic-title {
    background: linear-gradient(135deg, #0284c7, #0ea5e9) !important;
    color: #ffffff !important;
    padding: 14px 28px !important;
    border-radius: 22px !important;
    border-bottom: 5px solid #0369a1 !important;
    box-shadow: 0 8px 24px rgba(2, 132, 199, 0.35) !important;
    font-weight: 800 !important;
    font-size: 1.15rem !important;
    letter-spacing: 0.4px !important;
    margin-bottom: 2rem !important;
    display: inline-block !important;
}

.lesson-node {
    width: 74px !important;
    height: 74px !important;
    border-radius: 50% !important;
    font-size: 1.6rem !important;
    font-weight: 900 !important;
    background-color: #58cc02 !important;
    box-shadow: 0 7px 0 #46a302, 0 10px 24px rgba(0, 0, 0, 0.25) !important;
    border: 3px solid rgba(255, 255, 255, 0.3) !important;
    transition: transform 0.15s ease, box-shadow 0.15s ease !important;
}

.lesson-node:hover:not(.locked) {
    transform: scale(1.08) translateY(-2px) !important;
    box-shadow: 0 9px 0 #46a302, 0 14px 28px rgba(88, 204, 2, 0.4) !important;
}

.lesson-node:active:not(.locked) {
    transform: translateY(5px) !important;
    box-shadow: 0 2px 0 #46a302 !important;
}

.lesson-node.completed {
    background-color: #f59e0b !important;
    box-shadow: 0 7px 0 #d97706, 0 10px 24px rgba(245, 158, 11, 0.35) !important;
}

.lesson-node.completed:active {
    box-shadow: 0 2px 0 #d97706 !important;
}

/* Daily Spotlight 3D Buttons & Fix */
.btn-spotlight-quiz {
    background: #10b981 !important;
    border: none !important;
    border-bottom: 4px solid #059669 !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    border-radius: 16px !important;
    padding: 11px 20px !important;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3) !important;
    transition: all 0.15s ease !important;
    cursor: pointer !important;
}

.btn-spotlight-quiz:hover {
    background: #34d399 !important;
    transform: translateY(-2px) !important;
}

.btn-spotlight-quiz:active {
    transform: translateY(2px) !important;
    border-bottom-width: 1px !important;
}

.btn-spotlight-story {
    background: #0284c7 !important;
    border: none !important;
    border-bottom: 4px solid #0369a1 !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    border-radius: 16px !important;
    padding: 11px 20px !important;
    box-shadow: 0 4px 14px rgba(2, 132, 199, 0.3) !important;
    transition: all 0.15s ease !important;
    cursor: pointer !important;
}

.btn-spotlight-story:hover {
    background: #38bdf8 !important;
    transform: translateY(-2px) !important;
}

.btn-spotlight-story:active {
    transform: translateY(2px) !important;
    border-bottom-width: 1px !important;
}

[data-theme="light"] .btn-spotlight-story {
    background: #0284c7 !important;
    color: #ffffff !important;
    border: none !important;
    border-bottom: 4px solid #0369a1 !important;
}

/* 5. ACCOUNT TAB (AVATAR ACTIONS & CARDS POLISH) */
.btn-avatar-action {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1.5px solid rgba(255, 255, 255, 0.15) !important;
    border-bottom: 3px solid rgba(0, 0, 0, 0.4) !important;
    color: #ffffff !important;
    padding: 8px 16px !important;
    border-radius: 16px !important;
    font-size: 0.86rem !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    transition: all 0.15s ease !important;
}

.btn-avatar-action:hover {
    background: rgba(28, 176, 246, 0.25) !important;
    border-color: #38bdf8 !important;
    transform: translateY(-1px) !important;
}

[data-theme="light"] .btn-avatar-action {
    background: #f1f5f9 !important;
    border: 1.5px solid #cbd5e1 !important;
    border-bottom: 3px solid #94a3b8 !important;
    color: #0f2b48 !important;
}

[data-theme="light"] .btn-avatar-action:hover {
    background: #e2e8f0 !important;
    color: #0284c7 !important;
}

[data-theme="light"] .feedback-account-card {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    border-radius: 24px !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06) !important;
}

[data-theme="light"] .feedback-account-card h3 {
    color: #0f2b48 !important;
}

[data-theme="light"] .feedback-account-card p {
    color: #475569 !important;
}

[data-theme="light"] .setting-notif-card {
    background: #ffffff !important;
    border: 2px solid #e2e8f0 !important;
    border-bottom: 5px solid #cbd5e1 !important;
    border-radius: 24px !important;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06) !important;
}

[data-theme="light"] .setting-notif-card h4 {
    color: #0f2b48 !important;
}

[data-theme="light"] .setting-notif-card p {
    color: #475569 !important;
}




/* ==========================================================================
   SMART AUTO-HIDE / REVEAL NAVIGATION ON SCROLL (MOBILE & DESKTOP)
   ========================================================================== */
.navbar.app-header {
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1), margin-top 0.32s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
    will-change: transform, margin-top;
}

.navbar.landing-navbar {
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
    will-change: transform;
}

.bottom-nav {
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease !important;
    will-change: transform;
}

/* Hidden state on scroll down */
.navbar.app-header.nav-scrolled-hidden {
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.navbar.landing-navbar.nav-scrolled-hidden {
    transform: translateY(-115%) !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.bottom-nav.nav-scrolled-hidden {
    transform: translate(-50%, calc(100% + 40px)) !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Move AI Assistant launcher down gracefully when bottom nav is hidden on mobile */
@media (max-width: 600px) {
    body:has(.bottom-nav.nav-scrolled-hidden) #mrphuoc-ai-container,
    #mrphuoc-ai-container.nav-scrolled-down {
        bottom: calc(18px + env(safe-area-inset-bottom, 0px)) !important;
        transition: bottom 0.32s cubic-bezier(0.16, 1, 0.3, 1) !important;
    }
}


/* ==========================================================================
   LIGHTWEIGHT STREAK CELEBRATION & EXTENSION EFFECTS (ZERO SERVER LOAD)
   ========================================================================== */
#stat-pill-streak {
    cursor: pointer !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

#stat-pill-streak:hover {
    transform: scale(1.05);
    border-color: rgba(255, 150, 0, 0.4) !important;
    box-shadow: 0 0 12px rgba(255, 150, 0, 0.3) !important;
}

/* Header pill ignited burst animation */
.streak-ignited {
    animation: streakPillIgnite 0.9s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards !important;
}

@keyframes streakPillIgnite {
    0% { transform: scale(1); }
    35% { transform: scale(1.22); border-color: #ff9600 !important; box-shadow: 0 0 25px rgba(255, 150, 0, 0.85), inset 0 0 10px rgba(255, 200, 0, 0.5) !important; }
    70% { transform: scale(0.96); }
    100% { transform: scale(1); border-color: rgba(255, 150, 0, 0.4) !important; box-shadow: 0 0 15px rgba(255, 150, 0, 0.4) !important; }
}

/* Floating "+1 Ngày 🔥" badge above header pill */
.streak-float-badge {
    background: linear-gradient(135deg, #ff9600, #ff5722);
    color: #ffffff;
    font-weight: 800;
    font-size: 0.78rem;
    padding: 3px 9px;
    border-radius: 14px;
    box-shadow: 0 4px 15px rgba(255, 87, 34, 0.5);
    pointer-events: none;
    animation: streakFloatUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    white-space: nowrap;
}

@keyframes streakFloatUp {
    0% { opacity: 0; transform: translate(-50%, 4px) scale(0.8); }
    20% { opacity: 1; transform: translate(-50%, -8px) scale(1.1); }
    60% { opacity: 1; transform: translate(-50%, -22px) scale(1); }
    100% { opacity: 0; transform: translate(-50%, -36px) scale(0.9); }
}

/* Streak Celebration Modal */
#modal-streak-celebration {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 15, 26, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    transition: opacity 0.3s ease;
}

#modal-streak-celebration.hidden {
    display: none !important;
}

.streak-modal-box {
    width: 100%;
    max-width: 410px;
    background: linear-gradient(180deg, #1c2738 0%, #0f1724 100%);
    border: 2px solid rgba(255, 150, 0, 0.4);
    border-radius: 28px;
    padding: 2rem 1.6rem 1.8rem 1.6rem;
    text-align: center;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.65), 0 0 45px rgba(255, 150, 0, 0.25);
    position: relative;
    animation: streakModalPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes streakModalPop {
    0% { transform: scale(0.85) translateY(20px); opacity: 0; }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}

.streak-modal-pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 150, 0, 0.15);
    border: 1px solid rgba(255, 150, 0, 0.4);
    color: #ff9600;
    font-size: 0.76rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.streak-flame-hero {
    position: relative;
    width: 90px;
    height: 108px;
    margin: 8px auto 14px auto;
}

.streak-flame-svg {
    filter: drop-shadow(0 0 20px rgba(255, 150, 0, 0.65));
    animation: flamePulse 1.8s ease-in-out infinite alternate;
}

@keyframes flamePulse {
    0% { transform: scale(1); filter: drop-shadow(0 0 16px rgba(255, 150, 0, 0.55)); }
    100% { transform: scale(1.06); filter: drop-shadow(0 0 26px rgba(255, 90, 0, 0.85)); }
}

.streak-big-number {
    font-size: 3.6rem;
    font-weight: 900;
    line-height: 1;
    background: linear-gradient(135deg, #ffd000, #ff6b00);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -1px;
}

.streak-pop-text {
    animation: streakPopText 0.35s ease;
}

@keyframes streakPopText {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.streak-days-label {
    font-size: 0.88rem;
    font-weight: 800;
    color: #94a3b8;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-top: 4px;
    margin-bottom: 16px;
}

/* 7-Day Weekly Tracker */
.streak-week-tracker {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    padding: 10px 8px;
    margin-bottom: 18px;
}

.streak-day-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    flex: 1;
}

.streak-day-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: #94a3b8;
}

.streak-day-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.82rem;
    transition: all 0.3s ease;
}

/* Day states */
.streak-day-col.streak-day-today .streak-day-circle {
    background: linear-gradient(135deg, #ff9600, #ff5722);
    color: #ffffff;
    box-shadow: 0 0 14px rgba(255, 150, 0, 0.7);
    border: 1.5px solid #ffe600;
    transform: scale(1.08);
}

.streak-day-col.streak-day-past .streak-day-circle {
    background: rgba(255, 150, 0, 0.16);
    border: 1.5px solid #ff9600;
    color: #ff9600;
}

.streak-day-col.streak-day-upcoming .streak-day-circle {
    background: rgba(255, 255, 255, 0.03);
    border: 1px dashed rgba(255, 255, 255, 0.18);
    color: rgba(255, 255, 255, 0.2);
}

.streak-modal-msg {
    color: #cbd5e1;
    font-size: 0.92rem;
    line-height: 1.45;
    margin-bottom: 16px;
    padding: 0 8px;
}

.streak-freeze-info {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.25);
    border-radius: 12px;
    padding: 4px 10px;
    margin-bottom: 18px;
}

.streak-continue-btn {
    width: 100%;
    background: linear-gradient(135deg, #ff9600, #ff6b00);
    color: #ffffff !important;
    font-weight: 800;
    font-size: 1rem;
    padding: 12px 20px;
    border-radius: 16px;
    border: none;
    box-shadow: 0 4px 0 #d46000, 0 10px 25px rgba(255, 107, 0, 0.35);
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.1s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.streak-continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #d46000, 0 14px 30px rgba(255, 107, 0, 0.45);
}

.streak-continue-btn:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 #d46000, 0 6px 15px rgba(255, 107, 0, 0.35);
}

/* Disney Magic Light Mode overrides */
[data-theme="light"] #modal-streak-celebration {
    background: rgba(240, 247, 255, 0.88);
}

[data-theme="light"] .streak-modal-box {
    background: linear-gradient(180deg, #ffffff 0%, #f4f8ff 100%);
    border: 2px solid rgba(255, 150, 0, 0.5);
    box-shadow: 0 20px 60px rgba(28, 176, 246, 0.18), 0 0 35px rgba(255, 150, 0, 0.25);
    color: #0f172a;
}

[data-theme="light"] .streak-modal-msg {
    color: #334155;
}

[data-theme="light"] .streak-days-label {
    color: #64748b;
}

[data-theme="light"] .streak-week-tracker {
    background: rgba(28, 176, 246, 0.05);
    border: 1px solid rgba(28, 176, 246, 0.18);
}

[data-theme="light"] .streak-day-label {
    color: #64748b;
}

[data-theme="light"] .streak-day-col.streak-day-upcoming .streak-day-circle {
    background: rgba(0, 0, 0, 0.03);
    border: 1px dashed rgba(0, 0, 0, 0.18);
    color: rgba(0, 0, 0, 0.2);
}


/* ==========================================================================
   PHASE 19: ZERO-FRICTION 30S HERO CHALLENGE WIDGET (LANDING PAGE)
   ========================================================================== */
.landing-quick-challenge-card {
    background: linear-gradient(135deg, rgba(28, 176, 246, 0.12) 0%, rgba(20, 33, 45, 0.88) 100%);
    border: 1.5px solid rgba(28, 176, 246, 0.35);
    border-radius: 24px;
    padding: 1.4rem 1.5rem;
    margin: 1.8rem 0;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45), 0 0 25px rgba(28, 176, 246, 0.15);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    position: relative;
    overflow: hidden;
}

.landing-quick-challenge-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #1cb0f6, #58cc02, #ffd700);
}

.quick-challenge-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    gap: 8px;
    flex-wrap: wrap;
}

.quick-challenge-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.6px;
    color: #ffd700;
    background: rgba(255, 215, 0, 0.15);
    border: 1px solid rgba(255, 215, 0, 0.35);
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
}

.quick-challenge-score {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.86rem;
    font-weight: 800;
    color: #ffc800;
    background: rgba(255, 200, 0, 0.12);
    border: 1px solid rgba(255, 200, 0, 0.3);
    padding: 4px 10px;
    border-radius: 16px;
}

.score-pop {
    animation: scorePopAnim 0.35s ease;
}

@keyframes scorePopAnim {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); color: #58cc02; }
    100% { transform: scale(1); }
}

.quick-challenge-prompt {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 10px 14px;
    margin-bottom: 1rem;
}

.prompt-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.prompt-text-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.prompt-sub {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 600;
}

.prompt-word-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.challenge-speak-btn {
    background: linear-gradient(135deg, #1cb0f6, #0284c7);
    color: #ffffff;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 3px 0 #0369a1, 0 4px 10px rgba(2, 132, 199, 0.35);
    transition: transform 0.1s ease, box-shadow 0.1s ease;
    flex-shrink: 0;
}

.challenge-speak-btn:hover {
    transform: scale(1.08);
}

.challenge-speak-btn:active,
.speaker-bounce {
    animation: speakerBounceAnim 0.35s ease;
}

@keyframes speakerBounceAnim {
    0% { transform: scale(1); }
    50% { transform: scale(1.25); }
    100% { transform: scale(1); }
}

.prompt-word {
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.3px;
}

.prompt-phonetic {
    font-size: 0.85rem;
    color: #38bdf8;
    font-family: monospace;
    font-weight: 600;
}

/* 3D Tactile Option Buttons (Duolingo Style) */
.quick-challenge-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 0.8rem;
}

.challenge-opt-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(255, 255, 255, 0.15);
    border-bottom: 5px solid rgba(255, 255, 255, 0.25);
    border-radius: 18px;
    padding: 12px 8px;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: transform 0.1s ease, background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    user-select: none;
}

.challenge-opt-btn:hover {
    background: rgba(28, 176, 246, 0.15);
    border-color: rgba(28, 176, 246, 0.4);
    border-bottom-color: #0284c7;
    transform: translateY(-2px);
}

.challenge-opt-btn:active {
    transform: translateY(3px);
    border-bottom-width: 2px;
}

.opt-emoji {
    font-size: 2rem;
    line-height: 1;
}

.opt-label {
    font-size: 0.95rem;
    font-weight: 700;
    color: #e2e8f0;
}

.challenge-opt-btn.opt-correct {
    background: linear-gradient(135deg, rgba(88, 204, 2, 0.25), rgba(70, 163, 2, 0.35)) !important;
    border-color: #58cc02 !important;
    border-bottom-color: #3d8c02 !important;
    box-shadow: 0 0 20px rgba(88, 204, 2, 0.45) !important;
    animation: correctPulse 0.4s ease;
}

@keyframes correctPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.08); }
    100% { transform: scale(1); }
}

.challenge-opt-btn.opt-shake {
    animation: optShakeAnim 0.45s ease;
    border-color: #ef4444 !important;
    background: rgba(239, 68, 68, 0.18) !important;
}

@keyframes optShakeAnim {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

/* Feedback Box */
.quick-challenge-feedback {
    border-radius: 16px;
    padding: 12px 14px;
    margin-top: 10px;
    animation: fadeInDown 0.3s ease;
}

.feedback-correct {
    background: rgba(88, 204, 2, 0.12);
    border: 1.5px solid rgba(88, 204, 2, 0.4);
}

.feedback-incorrect {
    background: rgba(239, 68, 68, 0.12);
    border: 1.5px solid rgba(239, 68, 68, 0.4);
}

.feedback-badge {
    font-size: 0.88rem;
    font-weight: 800;
    color: #58cc02;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.feedback-incorrect .feedback-badge {
    color: #ef4444;
}

.feedback-text {
    font-size: 0.86rem;
    color: #cbd5e1;
    line-height: 1.4;
    margin-bottom: 8px;
}

.feedback-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.challenge-save-btn {
    flex: 2;
    min-width: 200px;
    font-weight: 800;
    font-size: 0.88rem;
    padding: 8px 14px;
}

.challenge-next-btn {
    flex: 1;
    font-size: 0.82rem;
    padding: 8px 10px;
    border-radius: 14px;
}

/* ==========================================================================
   PHASE 19: REWARD CONFETTI & STAR SPARKLE BURST ENGINE
   ========================================================================== */
.reward-confetti-container {
    pointer-events: none;
    z-index: 999999;
}

.confetti-star-particle {
    user-select: none;
    pointer-events: none;
    will-change: transform, opacity;
}

/* ==========================================================================
   PHASE 19: SHAREABLE ACHIEVEMENT STORY CARD MODAL (FOR PARENTS/STUDENTS)
   ========================================================================== */
#modal-share-story {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 15, 26, 0.88);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 21000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

#modal-share-story.hidden {
    display: none !important;
}

.story-modal-box {
    width: 100%;
    max-width: 440px;
    max-height: 92vh;
    overflow-y: auto;
    background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
    border: 2px solid rgba(255, 215, 0, 0.4);
    border-radius: 28px;
    padding: 1.6rem 1.4rem;
    text-align: center;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.7), 0 0 45px rgba(255, 215, 0, 0.25);
    animation: streakModalPop 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.story-preview-container {
    width: 100%;
    max-width: 320px;
    margin: 12px auto;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5), 0 0 20px rgba(255, 215, 0, 0.3);
    border: 2px solid rgba(255, 215, 0, 0.3);
}

.story-preview-canvas {
    width: 100%;
    height: auto;
    display: block;
}

.story-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 14px;
}

.story-btn-download {
    width: 100%;
    background: linear-gradient(135deg, #ffd700, #ff9600);
    color: #0f172a !important;
    font-weight: 800;
    font-size: 1rem;
    padding: 12px 20px;
    border-radius: 16px;
    border: none;
    box-shadow: 0 4px 0 #d97706, 0 10px 25px rgba(245, 158, 11, 0.35);
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.story-btn-download:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #d97706, 0 14px 30px rgba(245, 158, 11, 0.45);
}

.story-btn-download:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 #d97706;
}

.story-btn-share {
    width: 100%;
    background: rgba(28, 176, 246, 0.15);
    color: #1cb0f6 !important;
    border: 1.5px solid rgba(28, 176, 246, 0.4);
    font-weight: 700;
    font-size: 0.92rem;
    padding: 10px 18px;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.story-btn-share:hover {
    background: rgba(28, 176, 246, 0.25);
    border-color: #1cb0f6;
}

/* Light mode overrides for Phase 19 */
[data-theme="light"] .landing-quick-challenge-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(240, 247, 255, 0.9) 100%);
    border-color: rgba(28, 176, 246, 0.4);
    box-shadow: 0 16px 40px rgba(28, 176, 246, 0.15), 0 0 25px rgba(255, 200, 0, 0.1);
}

[data-theme="light"] .prompt-word {
    color: #0f172a;
}

[data-theme="light"] .prompt-sub {
    color: #64748b;
}

[data-theme="light"] .challenge-opt-btn {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-bottom: 5px solid #cbd5e1;
    color: #0f172a;
}

[data-theme="light"] .challenge-opt-btn .opt-label {
    color: #1e293b;
}

[data-theme="light"] .challenge-opt-btn:hover {
    background: rgba(28, 176, 246, 0.08);
    border-color: #38bdf8;
    border-bottom-color: #0284c7;
}

[data-theme="light"] .feedback-text {
    color: #334155;
}

[data-theme="light"] .story-modal-box {
    background: linear-gradient(180deg, #ffffff 0%, #f4f8ff 100%);
    color: #0f172a;
}


/* MCQ Quiz Cards Light Mode */
[data-theme="light"] .mcq-card {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    box-shadow: 0 4px 0 #cbd5e1;
}

[data-theme="light"] .mcq-card:hover {
    background: rgba(28, 176, 246, 0.08);
    border-color: var(--primary);
    box-shadow: 0 6px 0 rgba(24, 153, 214, 0.35);
}

[data-theme="light"] .mcq-card.selected {
    background: rgba(28, 176, 246, 0.12) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 4px 0 var(--primary-dark), 0 0 16px var(--primary-glow) !important;
}

[data-theme="light"] .mcq-card.selected .mcq-badge {
    background: var(--primary) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 0 var(--primary-dark);
}

[data-theme="light"] .mcq-card.correct {
    background: rgba(88, 204, 2, 0.15) !important;
    border-color: var(--secondary) !important;
    box-shadow: 0 4px 0 var(--secondary-dark), 0 0 16px var(--secondary-glow) !important;
}

[data-theme="light"] .mcq-card.correct .mcq-badge {
    background: var(--secondary) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 0 var(--secondary-dark);
}

[data-theme="light"] .mcq-card.incorrect {
    background: rgba(255, 75, 75, 0.12) !important;
    border-color: var(--danger) !important;
    box-shadow: 0 4px 0 var(--danger-dark), 0 0 16px var(--danger-glow) !important;
}

[data-theme="light"] .mcq-card.incorrect .mcq-badge {
    background: var(--danger) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 0 var(--danger-dark);
}

[data-theme="light"] .mcq-badge {
    background: #f1f5f9;
    color: #475569;
}

[data-theme="light"] .mcq-text {
    color: #0f172a;
}

@media (max-width: 600px) {
    .quick-challenge-options {
        grid-template-columns: repeat(3, 1fr);
        gap: 6px;
    }
    .challenge-opt-btn {
        padding: 8px 4px;
    }
    .opt-emoji {
        font-size: 1.6rem;
    }
    .opt-label {
        font-size: 0.8rem;
    }
}

/* ====================================================================
 * PHASE 20: ZERO-SERVER-LAG INTERACTIVE FEATURES
 * 1. ROADMAP MISTAKE VAULT WIDGET
 * 2. MISTAKE VAULT MODAL & CARDS
 * 3. PRONUNCIATION COACH 2.0 & AUDIO WAVE VISUALIZER
 * ==================================================================== */

/* --- 1. ROADMAP MISTAKE WIDGET --- */
.roadmap-mistake-widget-card {
    background: linear-gradient(135deg, rgba(255, 75, 75, 0.12), rgba(255, 150, 0, 0.08));
    border: 1.5px solid rgba(255, 75, 75, 0.35);
    border-bottom: 4px solid rgba(230, 50, 50, 0.8);
    border-radius: 20px;
    padding: 16px 20px;
    margin: 14px auto 20px auto;
    max-width: 720px;
    box-shadow: 0 8px 24px rgba(255, 75, 75, 0.12);
    backdrop-filter: blur(12px);
    transition: all 0.25s ease;
}

.roadmap-mistake-widget-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(255, 75, 75, 0.2);
}

.roadmap-mistake-widget-card.all-clear {
    background: linear-gradient(135deg, rgba(88, 204, 2, 0.12), rgba(28, 176, 246, 0.08));
    border-color: rgba(88, 204, 2, 0.4);
    border-bottom-color: rgba(70, 163, 2, 0.8);
    box-shadow: 0 8px 24px rgba(88, 204, 2, 0.12);
}

.mistake-widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.mistake-widget-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #ff4b4b, #ff9600);
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    padding: 5px 12px;
    border-radius: 20px;
    box-shadow: 0 3px 0 #cc3333;
}

.roadmap-mistake-widget-card.all-clear .mistake-widget-badge {
    background: linear-gradient(135deg, #58cc02, #20bf6b);
    box-shadow: 0 3px 0 #46a302;
}

.mistake-widget-counter {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-color);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.mistake-widget-body p {
    font-size: 0.92rem;
    line-height: 1.45;
    color: var(--text-color);
    margin: 0 0 14px 0;
}

.mistake-widget-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-mistake-revenge {
    flex: 1;
    min-width: 170px;
    background: linear-gradient(180deg, #ff9600 0%, #e67e00 100%);
    border: none;
    border-bottom: 4px solid #b36200;
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 800;
    padding: 10px 18px;
    border-radius: 16px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(255, 150, 0, 0.35);
    transition: all 0.15s ease;
}

.btn-mistake-revenge:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(255, 150, 0, 0.45);
}

.btn-mistake-revenge:active:not(:disabled) {
    transform: translateY(3px);
    border-bottom-width: 1px;
}

.btn-mistake-revenge:disabled {
    background: rgba(255, 255, 255, 0.12);
    border-bottom-color: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.5);
    box-shadow: none;
    cursor: not-allowed;
}

.btn-mistake-open {
    background: rgba(255, 255, 255, 0.08);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    border-bottom: 3px solid rgba(255, 255, 255, 0.3);
    color: var(--text-color);
    font-size: 0.9rem;
    font-weight: 700;
    padding: 10px 16px;
    border-radius: 16px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.15s ease;
}

.btn-mistake-open:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

/* Light mode adjustments for widget */
[data-theme="light"] .roadmap-mistake-widget-card {
    background: #ffffff;
    border-color: #fca5a5;
    border-bottom-color: #ef4444;
    box-shadow: 0 10px 25px rgba(239, 68, 68, 0.12);
}

[data-theme="light"] .roadmap-mistake-widget-card.all-clear {
    background: #ffffff;
    border-color: #86efac;
    border-bottom-color: #22c55e;
    box-shadow: 0 10px 25px rgba(34, 197, 94, 0.12);
}

[data-theme="light"] .btn-mistake-open {
    background: #f8fafc;
    border-color: #cbd5e1;
    border-bottom-color: #94a3b8;
    color: #1e293b;
}

/* --- 2. MISTAKE VAULT MODAL & CARDS --- */
.mistake-modal-content {
    background: var(--surface-color, #1a1e29);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    width: 94vw;
    max-width: 660px;
    max-height: 88vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
}

[data-theme="light"] .mistake-modal-content {
    background: #ffffff;
    border-color: #e2e8f0;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.mistake-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="light"] .mistake-modal-header {
    border-bottom-color: #f1f5f9;
}

.mistake-modal-title {
    font-size: 1.2rem;
    font-weight: 800;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-color);
}

.mistake-filter-tabs {
    display: flex;
    gap: 8px;
    padding: 12px 20px 4px 20px;
    overflow-x: auto;
}

.mistake-tab-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-color);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.mistake-tab-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 2px 8px var(--primary-glow);
}

[data-theme="light"] .mistake-tab-btn {
    background: #f1f5f9;
    border-color: #e2e8f0;
    color: #475569;
}

[data-theme="light"] .mistake-tab-btn.active {
    background: var(--primary);
    color: #ffffff;
}

.mistake-vault-list {
    padding: 16px 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1;
}

.mistake-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-left: 5px solid #ff4b4b;
    border-radius: 18px;
    padding: 14px 16px;
    transition: all 0.2s ease;
}

.mistake-card.mastered {
    border-left-color: #58cc02;
    opacity: 0.85;
}

[data-theme="light"] .mistake-card {
    background: #f8fafc;
    border-color: #e2e8f0;
    border-left-color: #ef4444;
}

[data-theme="light"] .mistake-card.mastered {
    border-left-color: #22c55e;
}

.mistake-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    gap: 8px;
    flex-wrap: wrap;
}

.mistake-topic-pill {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--primary);
    background: rgba(28, 176, 246, 0.12);
    padding: 3px 10px;
    border-radius: 12px;
}

.status-badge-pending {
    font-size: 0.75rem;
    font-weight: 700;
    color: #ff4b4b;
    background: rgba(255, 75, 75, 0.12);
    padding: 3px 8px;
    border-radius: 10px;
}

.status-badge-conquered {
    font-size: 0.75rem;
    font-weight: 700;
    color: #58cc02;
    background: rgba(88, 204, 2, 0.12);
    padding: 3px 8px;
    border-radius: 10px;
}

.mistake-question-text {
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 10px;
    line-height: 1.45;
}

.mistake-answers-box {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 12px;
    padding: 8px 12px;
    margin-bottom: 8px;
    font-size: 0.88rem;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

[data-theme="light"] .mistake-answers-box {
    background: #edf2f7;
}

.ans-row.correct {
    color: #58cc02;
}

[data-theme="light"] .ans-row.correct {
    color: #16a34a;
}

.ans-row.wrong {
    color: #ff4b4b;
}

[data-theme="light"] .ans-row.wrong {
    color: #dc2626;
}

.mistake-explanation {
    font-size: 0.82rem;
    color: #ffb800;
    margin-bottom: 10px;
    line-height: 1.4;
}

[data-theme="light"] .mistake-explanation {
    color: #b45309;
}

.mistake-card-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    margin-top: 6px;
}

.btn-vault-action-speak, .btn-vault-action-practice, .btn-vault-action-delete {
    border-radius: 12px;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 6px 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.15s ease;
}

.btn-vault-action-speak {
    background: rgba(28, 176, 246, 0.12);
    border: 1px solid rgba(28, 176, 246, 0.3);
    color: var(--primary);
}

.btn-vault-action-practice {
    background: linear-gradient(180deg, #ff9600, #e67e00);
    border: none;
    border-bottom: 2px solid #b36200;
    color: #ffffff;
}

.btn-vault-action-delete {
    background: rgba(255, 75, 75, 0.1);
    border: 1px solid rgba(255, 75, 75, 0.25);
    color: #ff4b4b;
    padding: 6px 10px;
}

.mistake-empty-state {
    text-align: center;
    padding: 36px 20px;
    color: var(--text-color);
}

.mistake-empty-state .empty-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.mistake-empty-state h4 {
    margin: 0 0 8px 0;
    font-size: 1.15rem;
}

.mistake-empty-state p {
    font-size: 0.88rem;
    opacity: 0.75;
    margin: 0;
}

.mistake-modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 10px;
    flex-wrap: wrap;
}

[data-theme="light"] .mistake-modal-footer {
    border-top-color: #f1f5f9;
}

/* --- 3. PRONUNCIATION COACH 2.0 & AUDIO WAVE --- */
.pronounce-modal-content {
    background: var(--surface-color, #1a1e29);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    width: 92vw;
    max-width: 580px;
    padding: 24px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(14px);
    text-align: center;
}

[data-theme="light"] .pronounce-modal-content {
    background: #ffffff;
    border-color: #e2e8f0;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.2);
}

.pronounce-target-card {
    background: rgba(28, 176, 246, 0.08);
    border: 1.5px solid rgba(28, 176, 246, 0.3);
    border-radius: 20px;
    padding: 18px 20px;
    margin: 16px 0;
}

[data-theme="light"] .pronounce-target-card {
    background: #f0f9ff;
    border-color: #bae6fd;
}

.pronounce-target-phrase {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-color);
    margin: 0 0 10px 0;
    line-height: 1.4;
}

.btn-target-audio {
    background: rgba(28, 176, 246, 0.15);
    border: 1px solid rgba(28, 176, 246, 0.35);
    color: var(--primary);
    border-radius: 16px;
    padding: 6px 14px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
}

.btn-target-audio:hover {
    background: rgba(28, 176, 246, 0.25);
    transform: scale(1.02);
}

.pronounce-mic-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 20px 0;
}

.btn-pronounce-mic {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1cb0f6, #0084d1);
    border: none;
    border-bottom: 5px solid #006099;
    color: #ffffff;
    font-size: 1.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(28, 176, 246, 0.4);
    transition: all 0.15s ease;
    position: relative;
}

.btn-pronounce-mic:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(28, 176, 246, 0.5);
}

.btn-pronounce-mic:active {
    transform: translateY(3px);
    border-bottom-width: 2px;
}

.btn-pronounce-mic.recording {
    background: linear-gradient(135deg, #ff4b4b, #d91414);
    border-bottom-color: #990000;
    box-shadow: 0 0 25px rgba(255, 75, 75, 0.65);
    animation: micPulse 1.2s infinite alternate;
}

@keyframes micPulse {
    0% { transform: scale(1); box-shadow: 0 0 10px rgba(255, 75, 75, 0.4); }
    100% { transform: scale(1.08); box-shadow: 0 0 30px rgba(255, 75, 75, 0.8); }
}

/* Audio wave animation bars */
.audio-wave-animation {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 24px;
    margin: 12px 0 6px 0;
}

.audio-wave-bar {
    width: 4px;
    height: 100%;
    background: #ff4b4b;
    border-radius: 3px;
    animation: waveBounce 0.8s ease-in-out infinite alternate;
}

.audio-wave-bar:nth-child(2) { animation-delay: 0.15s; }
.audio-wave-bar:nth-child(3) { animation-delay: 0.3s; }
.audio-wave-bar:nth-child(4) { animation-delay: 0.45s; }
.audio-wave-bar:nth-child(5) { animation-delay: 0.6s; }

@keyframes waveBounce {
    0% { height: 6px; }
    100% { height: 24px; }
}

.pronounce-status-text {
    font-size: 0.9rem;
    color: var(--text-color);
    min-height: 24px;
    margin-top: 8px;
}

.pronounce-status-text .status-listening {
    color: #ff9600;
    font-weight: 700;
}

.pronounce-status-text .status-error {
    color: #ff4b4b;
    font-weight: 700;
}

.pronounce-result-container {
    background: rgba(255, 255, 255, 0.05);
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    padding: 16px;
    margin-top: 14px;
}

[data-theme="light"] .pronounce-result-container {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.pronounce-score-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 12px;
}

.pronounce-score-number {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--primary);
    font-family: 'Din Round Pro', var(--font-main);
}

.pronounce-badge-pill {
    padding: 4px 12px;
    border-radius: 14px;
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
}

.pronounce-badge-pill.gold {
    background: linear-gradient(135deg, #ffc800, #ff9600);
    color: #000000;
}

.pronounce-badge-pill.green {
    background: linear-gradient(135deg, #58cc02, #20bf6b);
    color: #ffffff;
}

.pronounce-badge-pill.orange {
    background: linear-gradient(135deg, #ff9600, #ff4b4b);
    color: #ffffff;
}

.pronounce-tokens-display {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 10px;
}

.pronounce-token {
    font-size: 1.05rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.pronounce-token.correct {
    background: rgba(88, 204, 2, 0.18);
    border: 1px solid #58cc02;
    color: #58cc02;
}

[data-theme="light"] .pronounce-token.correct {
    color: #16a34a;
    border-color: #22c55e;
}

.pronounce-token.warning {
    background: rgba(255, 150, 0, 0.18);
    border: 1px solid #ff9600;
    color: #ff9600;
}

[data-theme="light"] .pronounce-token.warning {
    color: #d97706;
    border-color: #f59e0b;
}

.pronounce-token.missed {
    background: rgba(255, 75, 75, 0.18);
    border: 1px solid #ff4b4b;
    color: #ff4b4b;
}

[data-theme="light"] .pronounce-token.missed {
    color: #dc2626;
    border-color: #ef4444;
}

.token-ico {
    font-size: 0.8rem;
}

.pronounce-feedback-msg {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 4px;
}

.pronounce-spoken-display {
    font-size: 0.82rem;
    color: var(--text-color);
    opacity: 0.75;
}

