@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700;800;900&family=Space+Grotesk:wght@300;500;700&display=swap');

:root {
    /* Colors - Ultra Premium HSL Palette */
    --bg: #030014;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-border: rgba(255, 255, 255, 0.08);
    --surface-hover: rgba(255, 255, 255, 0.07);
    
    --text: #ffffff;
    --text-dim: rgba(255, 255, 255, 0.6);
    
    --accent-primary: #8b5cf6; /* Violet */
    --accent-secondary: #06b6d4; /* Cyan */
    --accent-tertiary: #ec4899; /* Pink */
    
    --accent-gradient: linear-gradient(135deg, #8b5cf6 0%, #06b6d4 100%);
    --accent-gradient-hover: linear-gradient(135deg, #a78bfa 0%, #22d3ee 100%);
    
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    
    --transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    --radius-lg: 24px;
    --radius-xl: 32px;
    --shadow-premium: 0 20px 40px rgba(0, 0, 0, 0.4);
    
    --glass-blur: blur(20px);
    
    --premium-gold: #ffd700;
    --premium-gradient: linear-gradient(135deg, #ffd700 0%, #ff8c00 100%);
    --premium-glow: 0 0 25px rgba(255, 215, 0, 0.4);
}

[data-theme="light"] {
    --bg: #f8fafc;
    --surface: rgba(255, 255, 255, 0.7);
    --surface-border: rgba(0, 0, 0, 0.08);
    --surface-hover: rgba(255, 255, 255, 0.9);
    --text: #0f172a;
    --text-dim: #64748b;
}

/* Premium Polish - Global Transitions */
* {
    transition: background-color 0.3s ease, border-color 0.3s ease, transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

body {
    font-family: 'Outfit', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
    transition: background 0.6s ease;
    font-size: 1rem;
}

/* Enhanced Zoom Animation */
@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}
.animate-zoom-in { animation: zoomIn 0.4s forwards; }

@media (max-width: 1024px) {
    .dashboard-layout {
        grid-template-columns: 1fr !important;
        padding: 10px !important;
    }
    .stat-sidebar { display: none !important; }
}

body.premium-active {
    --accent-primary: #ffd700;
    --accent-gradient: var(--premium-gradient);
}

.premium-badge {
    background: var(--premium-gradient);
    color: #000;
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.7rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: var(--premium-glow);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.premium-badge::before {
    content: '👑';
    font-size: 0.8rem;
}

/* Enhanced Reliability UI: Notification & Status */
.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-dim);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 10px var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.5); opacity: 0.5; }
    100% { transform: scale(1); opacity: 1; }
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: var(--accent-gradient);
    z-index: 9999;
    transition: width 0.1s linear;
}

/* Background Animated Orbs */
.orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    pointer-events: none;
    z-index: -1;
    opacity: 0.3;
    animation: orbMotion 25s infinite alternate ease-in-out;
}

.orb-1 { 
    width: 800px; height: 800px; 
    background: radial-gradient(circle, var(--accent-primary) 0%, transparent 70%); 
    top: -200px; left: -200px; 
}

.orb-2 { 
    width: 600px; height: 600px; 
    background: radial-gradient(circle, var(--accent-secondary) 0%, transparent 70%); 
    bottom: -100px; right: -100px; 
    animation-delay: -7s;
}

@keyframes orbMotion {
    0% { transform: translate(0, 0) rotate(0deg) scale(1); }
    33% { transform: translate(100px, 50px) rotate(120deg) scale(1.1); }
    66% { transform: translate(-50px, 150px) rotate(240deg) scale(0.9); }
    100% { transform: translate(0, 0) rotate(360deg) scale(1); }
}

/* Mouse Glow Effect */
.mouse-glow {
    position: fixed;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    transform: translate(-50%, -50%);
    transition: transform 0.1s ease-out;
}

/* Typography */
h1, h2, h3, h4 { 
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700; 
    letter-spacing: -0.02em; 
    line-height: 1.1; 
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

/* Layout */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Modern Glass Cards */
.glass-card {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2), inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

.glass-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, transparent 100%);
    pointer-events: none;
}

.glass-card:hover {
    background: var(--surface-hover);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), 0 0 25px rgba(139, 92, 246, 0.3), inset 0 1px 1px rgba(255, 255, 255, 0.2);
}

/* Buttons */
.btn {
    padding: 14px 32px;
    border-radius: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-decoration: none;
    font-family: inherit;
    font-size: 1rem;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 10px 25px rgba(139, 92, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.4);
    background: var(--accent-gradient-hover);
}

.btn-secondary {
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--surface-border);
    backdrop-filter: var(--glass-blur);
}

.btn-secondary:hover {
    background: var(--surface-hover);
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

/* Quiz Options */
.quiz-option {
    width: 100%;
    padding: 20px 30px;
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    color: var(--text);
    font-family: inherit;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.quiz-option:hover {
    background: var(--surface-hover);
    border-color: var(--accent-primary);
    transform: translateX(10px);
}

.quiz-option.correct {
    background: rgba(16, 185, 129, 0.15);
    border-color: var(--success);
    color: var(--success);
}

.quiz-option.incorrect {
    background: rgba(239, 68, 68, 0.15);
    border-color: var(--error);
    color: var(--error);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    background: rgba(139, 92, 246, 0.1);
    color: var(--accent-primary);
    border: 1px solid rgba(139, 92, 246, 0.2);
}

/* Toasts */
.toast {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--surface-border);
    padding: 16px 32px;
    border-radius: 100px;
    z-index: 10000;
    color: #fff;
    font-weight: 700;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    pointer-events: none;
    display: flex;
    align-items: center;
    gap: 12px;
}

.animate-slide-in {
    animation: toastIn 0.5s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

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

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: var(--bg);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 3px solid var(--surface-border);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s infinite linear;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Grid System */
.grid-main {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 32px;
}

/* Navigation */
nav {
    position: sticky;
    top: 15px;
    z-index: 10000;
    margin: 0 auto 50px;
    width: 100%;
    max-width: 1400px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    border-radius: var(--radius-lg);
    background: transparent;
    border: 1px solid transparent;
    transition: padding 0.4s ease, background 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.logo {
    font-size: 1.8rem;
    font-weight: 900;
    text-decoration: none;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Space Grotesk', sans-serif;
}

/* Animations */
.animate-fade-in { animation: fadeIn 1s ease forwards; }
.animate-slide-up { animation: slideUp 1s cubic-bezier(0.23, 1, 0.32, 1) forwards; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.shake { animation: shake 0.4s ease-in-out; }

/* Custom Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { 
    background: var(--surface-border); 
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover { background: var(--accent-primary); }

/* Theme Toggle */
.theme-toggle {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--surface);
    border: 1px solid var(--surface-border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition);
    color: var(--text);
}

.theme-toggle:hover {
    border-color: var(--accent-primary);
    transform: rotate(20deg) scale(1.1);
    background: var(--surface-hover);
}

/* ── Language Switcher ─────────────────────────────── */
#lang-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 100px;
    backdrop-filter: var(--glass-blur);
}

.lang-btn {
    padding: 5px 12px;
    border-radius: 100px;
    border: 1px solid transparent;
    background: transparent;
    color: var(--text-dim);
    font-family: 'Outfit', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 0.03em;
    transition: var(--transition);
    white-space: nowrap;
    line-height: 1;
}

.lang-btn:hover {
    color: var(--text);
    background: var(--surface-hover);
    border-color: var(--surface-border);
    transform: scale(1.08);
}

.lang-btn-active {
    background: var(--accent-gradient);
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.35);
    transform: scale(1.05);
}

/* Toast for language switch */
.lang-toast {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(20px);
    border: 1px solid var(--surface-border);
    padding: 12px 28px;
    border-radius: 100px;
    z-index: 10001;
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    pointer-events: none;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    display: flex;
    align-items: center;
    gap: 10px;
}

.lang-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Mobile: hide lang labels on tiny screens */
@media (max-width: 480px) {
    #lang-switcher { padding: 4px 6px; gap: 2px; }
    .lang-btn { padding: 4px 8px; font-size: 0.72rem; }
}

/* Ad Placeholders */
.ad-slot {
    width: 100%;
    margin: 50px 0;
    background: rgba(0, 0, 0, 0.15);
    border: 1px dashed rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 150px;
    padding: 20px;
    text-align: center;
}

.ad-label {
    font-size: 0.65rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
    opacity: 0.5;
}

/* Footer */
footer {
    margin-top: 120px;
    padding: 80px 0 50px;
    border-top: 1px solid var(--surface-border);
}

.footer-links a {
    color: var(--text-dim);
    text-decoration: none;
    transition: var(--transition);
    font-weight: 600;
}

.footer-links a:hover {
    color: var(--accent-primary);
}

/* Flash Animations for Quiz */
.flash-correct { animation: flashGreen 0.5s ease; }
.flash-wrong   { animation: flashRed 0.5s ease; }

@keyframes flashGreen {
    0%, 100% { background: var(--surface); }
    50% { background: rgba(16, 185, 129, 0.2); box-shadow: 0 0 40px rgba(16, 185, 129, 0.3); }
}

@keyframes flashRed {
    0%, 100% { background: var(--surface); }
    50% { background: rgba(239, 68, 68, 0.2); box-shadow: 0 0 40px rgba(239, 68, 68, 0.3); }
}

/* Meme Badge */
.meme-badge {
    background: linear-gradient(135deg, #ff00cc, #3333ff);
    color: #fff;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: inline-block;
    box-shadow: 0 5px 15px rgba(255, 0, 204, 0.4);
}

/* Form Inputs */
input, textarea, select {
    width: 100%;
    padding: 16px 20px;
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 14px;
    color: var(--text);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    outline: none;
}

input:focus, textarea:focus, select:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.8rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

/* Responsive */
@media (max-width: 1024px) {
    .academy-grid { grid-template-columns: 1fr; height: auto; }
}

@media (max-width: 768px) {
    .container { padding: 0 16px; }
    h1 { font-size: clamp(2.5rem, 8vw, 4rem); }
    .grid-main { grid-template-columns: 1fr; }
    nav { padding: 20px 0; margin-bottom: 40px; }
    .glass-card { padding: 24px; border-radius: 20px; }
    .glass-card:hover { transform: translateY(-4px) scale(1.01); }
}

/* Global Preloader */
#global-preloader {
    position: fixed;
    inset: 0;
    background: var(--bg);
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#global-preloader.fade-out {
    opacity: 0;
    visibility: hidden;
}

.preloader-brain {
    font-size: 4rem;
    animation: preloaderPulse 1.5s infinite ease-in-out;
    margin-bottom: 20px;
}

@keyframes preloaderPulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 10px var(--accent-primary)); }
    50% { transform: scale(1.1); filter: drop-shadow(0 0 25px var(--accent-secondary)); }
}

/* ═══════════════════════════════════════════
   GAMIFICATION SYSTEM STYLES
   ═══════════════════════════════════════════ */

/* Badge Unlock Overlay */
.badge-unlock-overlay {
    position: fixed; inset: 0; z-index: 100002;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(15px);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transition: opacity 0.4s ease;
}
.badge-unlock-overlay.active { opacity: 1; }

.badge-unlock-modal {
    text-align: center; padding: 50px 40px;
    background: var(--surface); border: 1px solid rgba(139,92,246,0.4);
    border-radius: var(--radius-xl); position: relative;
    max-width: 420px; width: 90%;
    box-shadow: 0 40px 80px rgba(0,0,0,0.6), 0 0 60px rgba(139,92,246,0.3);
    animation: badgeModalIn 0.6s cubic-bezier(0.23,1,0.32,1) forwards;
}

.badge-unlock-glow {
    position: absolute; inset: -40px; border-radius: 50%;
    background: radial-gradient(circle, rgba(139,92,246,0.25) 0%, transparent 70%);
    animation: glowPulse 2s infinite ease-in-out; pointer-events: none;
}

.badge-unlock-icon {
    font-size: 5rem; margin-bottom: 10px;
    animation: badgeIconBounce 0.8s cubic-bezier(0.68,-0.55,0.27,1.55) 0.3s both;
    filter: drop-shadow(0 10px 30px rgba(139,92,246,0.5));
}

.badge-unlock-label {
    font-size: 0.8rem; font-weight: 900; letter-spacing: 4px;
    text-transform: uppercase; color: var(--accent-secondary);
    margin-bottom: 8px;
}

.badge-unlock-name {
    font-size: 2rem; font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    background: var(--accent-gradient);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text; margin-bottom: 8px;
}

.badge-unlock-desc {
    color: var(--text-dim); font-size: 0.95rem; margin-bottom: 25px;
}

.badge-unlock-rewards {
    display: flex; gap: 12px; justify-content: center; margin-bottom: 30px;
}

.reward-chip {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 18px; border-radius: 100px;
    background: rgba(255,255,255,0.05); border: 1px solid var(--surface-border);
    font-weight: 800; font-size: 0.9rem;
}

.reward-icon { font-size: 1.1rem; }

.badge-unlock-btn {
    width: 100%; justify-content: center; font-size: 1.1rem; padding: 16px;
}

@keyframes badgeModalIn {
    from { transform: scale(0.5) translateY(50px); opacity: 0; }
    to { transform: scale(1) translateY(0); opacity: 1; }
}

@keyframes badgeIconBounce {
    from { transform: scale(0) rotate(-30deg); }
    to { transform: scale(1) rotate(0deg); }
}

@keyframes glowPulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.15); opacity: 1; }
}

/* Floating Reward Indicator */
.floating-reward {
    position: fixed; top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem; font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    pointer-events: none; z-index: 100003;
    animation: floatUp 1.4s cubic-bezier(0.23,1,0.32,1) forwards;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

@keyframes floatUp {
    0% { opacity: 1; transform: translate(-50%, -50%) scale(0.5); }
    30% { opacity: 1; transform: translate(-50%, -70%) scale(1.2); }
    100% { opacity: 0; transform: translate(-50%, -150%) scale(0.8); }
}

/* Achievement Badge Cards */
.ach-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.ach-card {
    padding: 30px 24px; text-align: center;
    border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    transition: var(--transition);
    position: relative; overflow: hidden;
}

.ach-card.locked {
    filter: grayscale(0.8); opacity: 0.5;
}

.ach-card.locked .ach-icon { filter: brightness(0.4); }

.ach-card.unlocked {
    border-color: rgba(139,92,246,0.4);
    box-shadow: 0 10px 30px rgba(139,92,246,0.15);
}

.ach-card.unlocked::before {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(139,92,246,0.08) 0%, transparent 60%);
    pointer-events: none;
}

.ach-card.unlocked:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 20px 40px rgba(139,92,246,0.25);
}

.ach-card .ach-icon {
    font-size: 3.5rem; margin-bottom: 15px;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.3));
    transition: transform 0.4s ease;
}

.ach-card.unlocked:hover .ach-icon {
    transform: scale(1.2) rotate(5deg);
}

.ach-card .ach-name {
    font-weight: 800; font-size: 1.15rem; margin-bottom: 6px;
    font-family: 'Space Grotesk', sans-serif;
}

.ach-card .ach-desc {
    font-size: 0.85rem; color: var(--text-dim); margin-bottom: 12px;
}

.ach-card .ach-rewards {
    display: flex; gap: 8px; justify-content: center;
    font-size: 0.75rem; font-weight: 700;
}

.ach-card .ach-rewards span {
    padding: 4px 10px; border-radius: 100px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--surface-border);
}

.ach-card .ach-status {
    margin-top: 12px; font-size: 0.8rem; font-weight: 800;
    text-transform: uppercase; letter-spacing: 1px;
}

.ach-card.unlocked .ach-status { color: var(--success); }
.ach-card.locked .ach-status { color: var(--text-dim); }

/* Shimmer effect on unlocked badges */
.ach-card.unlocked::after {
    content: ''; position: absolute; top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.05) 50%, transparent 60%);
    animation: shimmer 3s infinite;
    pointer-events: none;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

/* Rank Badge Display */
.rank-badge {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 20px; border-radius: 100px;
    font-weight: 800; font-size: 0.9rem;
    text-transform: uppercase; letter-spacing: 1px;
    border: 2px solid currentColor;
}

/* Profile Gamification Stats */
.gami-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 16px; margin-bottom: 30px;
}

.gami-stat {
    padding: 20px 16px; text-align: center;
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 20px; transition: var(--transition);
}

.gami-stat:hover {
    background: var(--surface-hover);
    border-color: rgba(139,92,246,0.3);
    transform: translateY(-4px);
}

.gami-stat .gami-val {
    font-size: 2rem; font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    line-height: 1; margin-bottom: 6px;
}

.gami-stat .gami-label {
    font-size: 0.75rem; color: var(--text-dim);
    text-transform: uppercase; letter-spacing: 1px; font-weight: 700;
}

/* Rank Progress Bar */
.rank-progress-wrap {
    width: 100%; height: 12px;
    background: var(--surface-border);
    border-radius: 100px; overflow: hidden;
    position: relative;
}

.rank-progress-fill {
    height: 100%; border-radius: 100px;
    transition: width 1s cubic-bezier(0.23,1,0.32,1);
    position: relative;
}

.rank-progress-fill::after {
    content: ''; position: absolute;
    right: 0; top: 50%; transform: translateY(-50%);
    width: 18px; height: 18px; border-radius: 50%;
    background: inherit; border: 3px solid var(--bg);
    box-shadow: 0 0 10px currentColor;
}

/* Coins display in nav */
.coins-display {
    display: flex; align-items: center; gap: 6px;
    padding: 8px 16px; background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 100px; font-weight: 800;
    font-size: 0.9rem; backdrop-filter: var(--glass-blur);
}

/* Profile Badge Showcase */
.badge-showcase {
    display: flex; gap: 12px; flex-wrap: wrap;
    justify-content: center; margin: 20px 0;
}

.badge-showcase .mini-badge {
    width: 50px; height: 50px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem; border-radius: 16px;
    background: var(--surface); border: 1px solid var(--surface-border);
    transition: var(--transition); cursor: default;
    position: relative;
}

.badge-showcase .mini-badge:hover {
    transform: scale(1.2) rotate(5deg);
    border-color: var(--accent-primary);
    box-shadow: 0 8px 20px rgba(139,92,246,0.3);
}

.badge-showcase .mini-badge .mini-badge-tip {
    position: absolute; bottom: calc(100% + 8px);
    left: 50%; transform: translateX(-50%);
    background: rgba(0,0,0,0.9); color: #fff;
    padding: 6px 12px; border-radius: 8px;
    font-size: 0.7rem; font-weight: 700;
    white-space: nowrap; pointer-events: none;
    opacity: 0; transition: opacity 0.2s;
}

.badge-showcase .mini-badge:hover .mini-badge-tip { opacity: 1; }

/* Progress ring for achievements page header */
.progress-ring { position: relative; display: inline-flex; }
.progress-ring svg { transform: rotate(-90deg); }
.progress-ring .ring-text {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-weight: 900; font-size: 1.8rem;
    font-family: 'Space Grotesk', sans-serif;
}

@media (max-width: 768px) {
    .ach-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .ach-card { padding: 20px 14px; }
    .ach-card .ach-icon { font-size: 2.5rem; }
    .gami-stats { grid-template-columns: repeat(2, 1fr); }
    .badge-unlock-modal { padding: 35px 25px; }
    .badge-unlock-icon { font-size: 4rem; }
    .badge-unlock-name { font-size: 1.5rem; }
}
/* AI Chat & Processing UI */
.ai-chat-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 10px;
}

.ai-message {
    padding: 15px 20px;
    border-radius: 18px;
    max-width: 85%;
    font-size: 0.95rem;
    line-height: 1.5;
    animation: fadeIn 0.4s ease;
}

.ai-message.user {
    align-self: flex-end;
    background: var(--surface-hover);
    border: 1px solid var(--accent-primary);
    border-bottom-right-radius: 4px;
}

.ai-message.ai {
    align-self: flex-start;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid var(--surface-border);
    border-bottom-left-radius: 4px;
}

.ai-typing-indicator {
    display: flex;
    gap: 4px;
    padding: 10px 15px;
    background: var(--surface);
    border-radius: 100px;
    width: fit-content;
}

.typing-dot {
    width: 6px;
    height: 6px;
    background: var(--accent-primary);
    border-radius: 50%;
    animation: typingBounce 1.4s infinite ease-in-out both;
}

.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

/* Premium Verification Styles */
.transaction-input-group {
    margin-top: 25px;
    text-align: left;
}

.transaction-status {
    margin-top: 15px;
    font-size: 0.85rem;
    font-weight: 700;
    text-align: center;
    padding: 10px;
    border-radius: 8px;
    display: none;
}

.transaction-status.verifying {
    display: block;
    background: rgba(139, 92, 246, 0.1);
    color: var(--accent-primary);
    border: 1px dashed var(--accent-primary);
}

.hub-card-tag {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(139, 92, 246, 0.2);
    color: var(--accent-primary);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 800;
}

/* ── Dashboard Enhancements ──────────────────────────────── */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 30px;
    margin-top: 40px;
}

@media (max-width: 1024px) {
    .dashboard-grid { grid-template-columns: 1fr; }
}

.stat-card {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    transition: var(--transition);
}

.stat-card:hover {
    border-color: var(--accent-primary);
    background: var(--surface-hover);
    transform: translateY(-5px);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.stat-value {
    font-size: 2.2rem;
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    line-height: 1;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 700;
}

.streak-calendar {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin: 20px 0;
}

.streak-day {
    flex: 1;
    aspect-ratio: 1;
    background: var(--surface-border);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 800;
}

.streak-day.active {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.streak-day.completed {
    background: var(--success);
    color: white;
}

.skill-row {
    margin-bottom: 20px;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-weight: 700;
    font-size: 0.9rem;
}

.skill-bar-outer {
    height: 10px;
    background: var(--surface-border);
    border-radius: 100px;
    overflow: hidden;
}

.skill-bar-inner {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 100px;
    width: 0;
    transition: width 1s cubic-bezier(0.23, 1, 0.32, 1);
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255,255,255,0.02);
    border-radius: 16px;
    margin-bottom: 12px;
    border: 1px solid transparent;
    transition: var(--transition);
}

.activity-item:hover {
    background: rgba(255,255,255,0.05);
    border-color: var(--surface-border);
}

.activity-icon {
    width: 40px;
    height: 40px;
    background: var(--surface-border);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.activity-details h4 {
    font-size: 0.95rem;
    margin-bottom: 2px;
}

.activity-details p {
    font-size: 0.8rem;
    color: var(--text-dim);
}

.premium-card {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1) 0%, rgba(255, 140, 0, 0.1) 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
    padding: 30px;
    border-radius: var(--radius-xl);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.premium-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 57c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23ffd700' fill-opacity='0.05' fill-rule='evenodd'/%3E%3C/svg%3E");
    opacity: 0.5;
}

.radar-wrap {
    width: 100%;
    max-width: 300px;
    margin: 40px auto;
    aspect-ratio: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ==========================================
   PREMIUM HERO SECTION REDESIGN (Steps 1 & 2)
   ========================================== */
.hero-section {
    position: relative;
    padding: 100px 0 60px;
    margin: 0 auto 60px;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: rgba(3, 0, 20, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
}

/* Atmospheric Aurora Animation Group */
.hero-aurora-bg {
    position: absolute;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
    opacity: 0.85;
}

.hero-aurora-bg::before,
.hero-aurora-bg::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    filter: blur(140px);
    mix-blend-mode: screen;
}

.hero-aurora-bg::before {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.25) 0%, rgba(6, 182, 212, 0.05) 50%, transparent 100%);
    top: -200px;
    left: -100px;
    animation: auroraMovement1 30s infinite alternate ease-in-out;
}

.hero-aurora-bg::after {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.25) 0%, rgba(236, 72, 153, 0.05) 50%, transparent 100%);
    bottom: -150px;
    right: -100px;
    animation: auroraMovement2 25s infinite alternate ease-in-out;
}

@keyframes auroraMovement1 {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); }
    50% { transform: translate(150px, 100px) scale(1.2) rotate(180deg); }
    100% { transform: translate(-50px, -50px) scale(0.9) rotate(360deg); }
}

@keyframes auroraMovement2 {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); }
    50% { transform: translate(-100px, -150px) scale(1.1) rotate(-180deg); }
    100% { transform: translate(80px, 50px) scale(0.85) rotate(-360deg); }
}

/* Hero Content Grid (2 Columns) */
.hero-content {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 40px;
    align-items: center;
    position: relative;
    z-index: 2;
    padding: 0 40px;
}

.hero-text-col {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    transform-style: preserve-3d;
    transition: transform 0.2s ease-out;
}

.hero-badge {
    margin-bottom: 20px;
    font-size: 0.85rem;
    padding: 6px 16px;
    background: rgba(139, 92, 246, 0.12);
    border: 1px solid rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.1);
}

.hero-title {
    font-size: clamp(2.8rem, 5vw, 4.5rem);
    line-height: 1.15;
    margin-bottom: 25px;
    font-weight: 900;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: clamp(1.05rem, 1.8vw, 1.25rem);
    line-height: 1.65;
    margin-bottom: 35px;
    color: var(--text-dim);
    max-width: 620px;
}

.hero-ctas {
    display: flex;
    gap: 16px;
    margin-bottom: 45px;
    flex-wrap: wrap;
}

/* Glowing primary CTA */
.btn-glow {
    position: relative;
    overflow: hidden;
}

.btn-glow::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 45%,
        rgba(255, 255, 255, 0.25) 50%,
        transparent 55%
    );
    transform: rotate(-45deg);
    transition: none;
    animation: shineSweep 4s infinite linear;
}

@keyframes shineSweep {
    0% { transform: translate(-30%, -30%) rotate(-45deg); }
    30%, 100% { transform: translate(120%, 120%) rotate(-45deg); }
}

/* Hero Stats Row */
.hero-stats {
    display: flex;
    gap: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 30px;
    width: 100%;
    flex-wrap: wrap;
}

.hero-stat-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.hero-stat-item .stat-num {
    font-size: 1.8rem;
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    line-height: 1;
}

.hero-stat-item .stat-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-dim);
    font-weight: 600;
}

/* Hero 3D Center Object Wrap */
.hero-visual-col {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    height: 480px;
    transform-style: preserve-3d;
    transition: transform 0.2s ease-out;
}

#hero-3d-canvas-wrap {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

#hero-3d-canvas {
    width: 100%;
    height: 100%;
    outline: none;
    z-index: 10;
}

/* Light orbs behind biological canvas object */
.glow-orb-center {
    position: absolute;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.25) 0%, transparent 70%);
    filter: blur(40px);
    z-index: 1;
    pointer-events: none;
    animation: pulseGlow 5s infinite alternate ease-in-out;
}

@keyframes pulseGlow {
    0% { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(1.3); opacity: 0.9; }
}

/* Watch Demo Modal design */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000000;
    background: rgba(3, 0, 20, 0.8);
    backdrop-filter: blur(25px);
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-card {
    position: relative;
    max-width: 700px;
    width: 90%;
    background: rgba(13, 10, 36, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.6), 0 0 40px rgba(139, 92, 246, 0.2);
    border-radius: var(--radius-xl);
    padding: 40px;
    transform: scale(0.9);
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    backdrop-filter: blur(20px);
}

.modal-overlay.active .modal-card {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 25px;
    right: 25px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text);
    font-size: 1.5rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.modal-close:hover {
    background: #ef4444;
    color: white;
    border-color: transparent;
    transform: rotate(90deg);
}

.demo-video-placeholder {
    width: 100%;
    margin-top: 20px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Parallax responsive stacking */
@media (max-width: 991px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 50px;
        padding: 0 10px;
        text-align: center;
    }
    
    .hero-text-col {
        align-items: center;
        text-align: center;
    }
    
    .hero-stats {
        justify-content: center;
        gap: 30px;
    }
    
    .hero-visual-col {
        height: 380px;
    }
}

/* ==========================================
   SCROLL REVEALS & NAVBAR TRANSITIONS (Step 2)
   ========================================== */
html.lenis {
    height: auto;
}

.lenis-smooth {
    scroll-behavior: auto;
}

.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

.lenis-stopped {
    overflow: hidden;
}

.lenis-scrolling iframe {
    pointer-events: none;
}

/* Staged reveals */
.scroll-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.reveal-active {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger grids reveals */
.stagger-grid > * {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-active.stagger-grid > * {
    opacity: 1;
    transform: translateY(0);
}

.reveal-active.stagger-grid > *:nth-child(1) { transition-delay: 0.1s; }
.reveal-active.stagger-grid > *:nth-child(2) { transition-delay: 0.2s; }
.reveal-active.stagger-grid > *:nth-child(3) { transition-delay: 0.3s; }
.reveal-active.stagger-grid > *:nth-child(4) { transition-delay: 0.4s; }
.reveal-active.stagger-grid > *:nth-child(5) { transition-delay: 0.5s; }
.reveal-active.stagger-grid > *:nth-child(6) { transition-delay: 0.6s; }

/* Dynamic Image zooming */
.zoom-on-scroll {
    transform: scale(0.95);
    transition: transform 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-active .zoom-on-scroll {
    transform: scale(1);
}

nav.scrolled {
    padding: 14px 30px;
    background: rgba(13, 10, 36, 0.85);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-color: rgba(255, 255, 255, 0.05);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.04);
}