:root {
    /* Background */
    --bg-primary: #000000;
    --bg-elevated: #0a0f14;
    --bg-surface: #111820;
    --bg-card: rgba(10, 15, 20, 0.85);
    --bg-card-hover: rgba(15, 22, 30, 0.9);
    
    /* Text */
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.4);
    --text-disabled: rgba(255, 255, 255, 0.2);
    
    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-default: rgba(255, 255, 255, 0.1);
    --border-accent: rgba(255, 255, 255, 0.15);
    --border-strong: rgba(255, 255, 255, 0.25);

    /* Module Colors */
    /* Teal - AI Chat Basics */
    --teal-50: #f0fdfa;
    --teal-100: #ccfbf1;
    --teal-200: #99f6e4;
    --teal-300: #5eead4;
    --teal-400: #2dd4bf;
    --teal-500: #14b8a6;
    --teal-600: #0d9488;
    --teal-700: #0f766e;
    --teal-800: #115e59;
    --teal-900: #134e4a;
    --teal-glow: rgba(20, 184, 166, 0.3);
    
    /* Blue - Model Selection */
    --blue-50: #eff6ff;
    --blue-100: #dbeafe;
    --blue-200: #bfdbfe;
    --blue-300: #93c5fd;
    --blue-400: #60a5fa;
    --blue-500: #3b82f6;
    --blue-600: #2563eb;
    --blue-700: #1d4ed8;
    --blue-800: #1e40af;
    --blue-900: #1e3a8a;
    --blue-glow: rgba(59, 130, 246, 0.3);
    
    /* Purple - Multimodal */
    --purple-50: #faf5ff;
    --purple-100: #f3e8ff;
    --purple-200: #e9d5ff;
    --purple-300: #d8b4fe;
    --purple-400: #c084fc;
    --purple-500: #a855f7;
    --purple-600: #9333ea;
    --purple-700: #7e22ce;
    --purple-800: #6b21a8;
    --purple-900: #581c87;
    --purple-glow: rgba(168, 85, 247, 0.3);
    --purple-muted: #a78bfa;
    
    /* Yellow - Prompt Craft (Bright Lemon) */
    --amber-50: #fefce8;
    --amber-100: #fef9c3;
    --amber-200: #fef08a;
    --amber-300: #fde047;
    --amber-400: #fde047;
    --amber-500: #facc15;
    --amber-600: #eab308;
    --amber-700: #ca8a04;
    --amber-800: #a16207;
    --amber-900: #854d0e;
    --amber-glow: rgba(253, 224, 71, 0.45);

    /* Yellow - Pro Tips / Anyra Pro (Gold) */
    --yellow-300: #fde047;
    --yellow-400: #facc15;
    --yellow-500: #eab308;
    --yellow-glow: rgba(250, 204, 21, 0.3);
    
    /* Orange - Gemini in Classroom (Vibrant Coral) */
    --orange-50: #fff7ed;
    --orange-100: #ffedd5;
    --orange-200: #fed7aa;
    --orange-300: #fdba74;
    --orange-400: #fb923c;
    --orange-500: #fb923c;
    --orange-600: #f97316;
    --orange-700: #ea580c;
    --orange-800: #c2410c;
    --orange-900: #9a3412;
    --orange-glow: rgba(251, 146, 60, 0.35);
    
    /* Pink - Custom Gems */
    --pink-50: #fdf2f8;
    --pink-100: #fce7f3;
    --pink-200: #fbcfe8;
    --pink-300: #f9a8d4;
    --pink-400: #f472b6;
    --pink-500: #ec4899;
    --pink-600: #db2777;
    --pink-700: #be185d;
    --pink-800: #9d174d;
    --pink-900: #831843;
    --pink-glow: rgba(236, 72, 153, 0.3);
    
    /* Green - NotebookLM */
    --green-50: #f0fdf4;
    --green-100: #dcfce7;
    --green-200: #bbf7d0;
    --green-300: #86efac;
    --green-400: #4ade80;
    --green-500: #22c55e;
    --green-600: #16a34a;
    --green-700: #15803d;
    --green-800: #166534;
    --green-900: #14532d;
    --green-glow: rgba(34, 197, 94, 0.3);
    
    /* Slate - Privacy & Security */
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-800: #1e293b;
    --slate-900: #0f172a;
    --slate-glow: rgba(100, 116, 139, 0.3);

    /* n8n-Style Colors - Pro Tips / Power User */
    --n8n-orange: #ff6b00;
    --n8n-orange-light: #ff8a3d;
    --n8n-orange-bright: #ffb366;
    --n8n-coral: #fb923c;
    --n8n-glow: rgba(255, 107, 0, 0.4);
    --n8n-glow-soft: rgba(255, 107, 0, 0.2);
    --n8n-bg-dark: #0a0a0b;
    --n8n-bg-card: rgba(20, 18, 25, 0.95);
    --n8n-bg-card-alt: rgba(30, 25, 35, 0.95);
    --n8n-purple-accent: rgba(139, 92, 246, 0.3);
    --n8n-border: rgba(255, 107, 0, 0.3);

    /* Semantic Colors */
    --success: #22c55e;
    --success-muted: rgba(34, 197, 94, 0.15);
    --warning: #f59e0b;
    --warning-muted: rgba(245, 158, 11, 0.15);
    --error: #ef4444;
    --error-muted: rgba(239, 68, 68, 0.15);
    --info: #3b82f6;
    --info-muted: rgba(59, 130, 246, 0.15);
    
    /* Interactive */
    --focus-ring: rgba(59, 130, 246, 0.5);
    --hover-overlay: rgba(255, 255, 255, 0.05);
    --active-overlay: rgba(255, 255, 255, 0.1);

    /* Typography */
    --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;

    /* Type Scale - Mobile First (slightly larger for readability) */
    --text-xs: 0.8125rem;    /* 13px, was 12px */
    --text-sm: 0.9375rem;    /* 15px, was 14px */
    --text-base: 1.0625rem;  /* 17px, was 16px */
    --text-lg: 1.1875rem;    /* 19px, was 18px */
    --text-xl: 1.375rem;     /* 22px, was 20px */
    --text-2xl: 1.625rem;    /* 26px, was 24px */
    --text-3xl: 2rem;        /* 32px, was 30px */
    --text-4xl: 2.5rem;      /* 40px, was 36px */
    --text-5xl: 3.25rem;     /* 52px, was 48px */
    --text-6xl: 4rem;        /* 64px, was 60px */

    /* Line Heights */
    --leading-none: 1;
    --leading-tight: 1.15;
    --leading-snug: 1.3;
    --leading-normal: 1.5;
    --leading-relaxed: 1.65;

    /* Letter Spacing */
    --tracking-tighter: -0.03em;
    --tracking-tight: -0.02em;
    --tracking-normal: 0;
    --tracking-wide: 0.02em;
    --tracking-wider: 0.05em;
    --tracking-widest: 0.1em;

    /* Spacing */
    --space-0: 0;
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 24px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.6);
    
    /* Animation Tokens */
    --duration-fast: 150ms;
    --duration-normal: 300ms;
    --duration-slow: 500ms;
    --duration-slower: 800ms;
    
    --ease-out: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease-spring: cubic-bezier(0.175, 0.885, 0.32, 1.275);

    /* Breakpoints */
    --breakpoint-sm: 640px;
    --breakpoint-md: 768px;
    --breakpoint-lg: 1024px;
    --breakpoint-xl: 1280px;
    --breakpoint-2xl: 1536px;
}

/* Desktop: Larger typography for accessibility (age 50+ friendly) */
@media (min-width: 1024px) {
    :root {
        --text-xs: 1rem;         /* 16px - minimum readable */
        --text-sm: 1.125rem;     /* 18px */
        --text-base: 1.25rem;    /* 20px */
        --text-lg: 1.375rem;     /* 22px */
        --text-xl: 1.625rem;     /* 26px */
        --text-2xl: 2rem;        /* 32px */
        --text-3xl: 2.5rem;      /* 40px */
        --text-4xl: 3rem;        /* 48px */
        --text-5xl: 3.75rem;     /* 60px */
        --text-6xl: 4.5rem;      /* 72px */
    }
}

/* ==========================================
   Light Mode Theme
   ========================================== */

.light-mode {
    --bg-primary: #f8fafc;
    --bg-elevated: #ffffff;
    --bg-surface: #f1f5f9;
    --bg-card: rgba(255, 255, 255, 0.9);
    --bg-card-hover: rgba(255, 255, 255, 0.95);

    --text-primary: #0f172a;
    --text-secondary: rgba(15, 23, 42, 0.7);
    --text-muted: rgba(15, 23, 42, 0.5);
    --text-disabled: rgba(15, 23, 42, 0.3);

    --border-subtle: rgba(15, 23, 42, 0.08);
    --border-default: rgba(15, 23, 42, 0.12);
    --border-accent: rgba(15, 23, 42, 0.18);
    --border-strong: rgba(15, 23, 42, 0.25);

    --hover-overlay: rgba(0, 0, 0, 0.03);
    --active-overlay: rgba(0, 0, 0, 0.06);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.16);
}

/* Light mode background adjustments */
.light-mode .bg-grid {
    background-color: var(--bg-primary);
    background-image:
        linear-gradient(rgba(15, 23, 42, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.03) 1px, transparent 1px);
}

.light-mode .bg-ambient {
    background: radial-gradient(ellipse at 30% 20%, rgba(20, 184, 166, 0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 70% 80%, rgba(59, 130, 246, 0.06) 0%, transparent 50%);
}
