/* ============================================================
   CSS VARIABLES — Design Tokens
   All colors, spacing, typography, and effects live here.
   ============================================================ */

:root {
  /* --- Color Palette: Dark Mode (default) --- */
  --color-bg:           #0a0a0f;
  --color-bg-secondary: #111118;
  --color-bg-card:      #13131a;
  --color-bg-elevated:  #1a1a24;
  --color-border:       rgba(255,255,255,0.08);
  --color-border-hover: rgba(255,255,255,0.15);

  --color-text:         #e8e8f0;
  --color-text-muted:   #8888a8;
  --color-text-subtle:  #55556a;

  /* TypeScript Blue Accent System */
  --color-accent:       #3178c6;
  --color-accent-light: #4a9eff;
  --color-accent-glow:  rgba(49, 120, 198, 0.35);
  --color-accent-dim:   rgba(49, 120, 198, 0.12);

  /* Level Colors */
  --color-beginner:     #22c55e;
  --color-beginner-dim: rgba(34, 197, 94, 0.12);
  --color-intermediate: #f59e0b;
  --color-intermediate-dim: rgba(245, 158, 11, 0.12);
  --color-advanced:     #ef4444;
  --color-advanced-dim: rgba(239, 68, 68, 0.12);

  /* Code Block */
  --color-code-bg:      #0d0d14;
  --color-code-border:  rgba(49, 120, 198, 0.25);

  /* --- Typography --- */
  --font-display:  'Syne', sans-serif;
  --font-body:     'Inter', sans-serif;
  --font-mono:     'JetBrains Mono', monospace;

  --text-xs:    0.75rem;
  --text-sm:    0.875rem;
  --text-base:  1rem;
  --text-lg:    1.125rem;
  --text-xl:    1.25rem;
  --text-2xl:   1.5rem;
  --text-3xl:   1.875rem;
  --text-4xl:   2.25rem;
  --text-5xl:   3rem;
  --text-6xl:   3.75rem;
  --text-7xl:   4.5rem;

  /* --- Spacing --- */
  --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;

  /* --- Radii --- */
  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  12px;
  --radius-xl:  16px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* --- Shadows --- */
  --shadow-sm:  0 1px 3px rgba(0,0,0,0.4);
  --shadow-md:  0 4px 16px rgba(0,0,0,0.5);
  --shadow-lg:  0 8px 32px rgba(0,0,0,0.6);
  --shadow-glow: 0 0 40px var(--color-accent-glow);

  /* --- Transitions --- */
  --transition-fast:   150ms ease;
  --transition-base:   250ms ease;
  --transition-slow:   400ms ease;

  /* --- Layout --- */
  --nav-height:    64px;
  --sidebar-width: 280px;
  --content-max:   860px;
  --container-max: 1200px;
}

/* Light Mode Overrides */
[data-theme="light"] {
  --color-bg:           #f8f8fc;
  --color-bg-secondary: #f0f0f8;
  --color-bg-card:      #ffffff;
  --color-bg-elevated:  #f5f5fc;
  --color-border:       rgba(0,0,0,0.08);
  --color-border-hover: rgba(0,0,0,0.15);

  --color-text:         #111120;
  --color-text-muted:   #555570;
  --color-text-subtle:  #9999b0;

  --color-accent:       #2563eb;
  --color-accent-light: #3b82f6;
  --color-accent-glow:  rgba(37, 99, 235, 0.25);
  --color-accent-dim:   rgba(37, 99, 235, 0.08);

  --color-code-bg:      #f0f0f8;
  --color-code-border:  rgba(37, 99, 235, 0.2);

  --shadow-sm:  0 1px 3px rgba(0,0,0,0.1);
  --shadow-md:  0 4px 16px rgba(0,0,0,0.12);
  --shadow-lg:  0 8px 32px rgba(0,0,0,0.15);
}
