/* ==========================================================================
   Design tokens — couleurs, typographie, espacements, rayons
   Palette « Graphite & Burnt Orange ».
   Deux thèmes : sombre (par défaut) et clair, via [data-theme].
   ========================================================================== */

:root {
  color-scheme: dark;

  /* Typographie */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas,
    "Liberation Mono", monospace;

  /* Mise en page */
  --container: 1120px;
  --container-pad: clamp(1.25rem, 4vw, 2.5rem);
  --header-height: 4.5rem;

  /* Espacements */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4.5rem;

  /* Rayons */
  --radius-sm: 0.5rem;
  --radius: 0.875rem;
  --radius-lg: 1.25rem;
  --radius-full: 999px;

  /* Couleurs — thème sombre */
  --bg: #111111;
  --bg-soft: #161616;
  --surface: #1a1a1a;
  --surface-2: #1f1f1f;
  --surface-3: #242424;
  --border: #2a2a2a;
  --border-strong: #3a3a3a;
  --text: #f5f5f5;
  --text-soft: #d4d4d4;
  --text-muted: #a3a3a3;
  --accent: #f97316;
  --accent-strong: #ea580c;
  --accent-ink: #1a0f04;
  --accent-soft: rgba(249, 115, 22, 0.12);
  --accent-line: rgba(249, 115, 22, 0.38);
  --accent-glow: rgba(249, 115, 22, 0.16);

  /* Fond décoratif */
  --grid-line: rgba(255, 255, 255, 0.04);
  --glow: rgba(249, 115, 22, 0.09);
  --noise: rgba(255, 255, 255, 0.025);

  /* Ombres */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow: 0 18px 40px -24px rgba(0, 0, 0, 0.85);
  --shadow-lift: 0 26px 55px -28px rgba(0, 0, 0, 0.9);

  /* Terminal — suit le thème actif */
  --term-bg: #171717;
  --term-border: #2a2a2a;
  --term-text: #e5e5e5;
  --term-muted: #a3a3a3;
  --term-accent: #f97316;
  --term-error: #fca5a5;

  /* Transitions */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --t-fast: 150ms var(--ease);
  --t-base: 260ms var(--ease);
  --t-slow: 600ms var(--ease);
}

[data-theme="light"] {
  color-scheme: light;

  --bg: #fafafa;
  --bg-soft: #f3f3f3;
  --surface: #ffffff;
  --surface-2: #f6f6f6;
  --surface-3: #eeeeee;
  --border: #e5e5e5;
  --border-strong: #d4d4d4;
  --text: #171717;
  --text-soft: #404040;
  --text-muted: #737373;
  --accent: #c2410c;
  --accent-strong: #9a3412;
  --accent-ink: #ffffff;
  --accent-soft: rgba(234, 88, 12, 0.09);
  --accent-line: rgba(194, 65, 12, 0.4);
  --accent-glow: rgba(249, 115, 22, 0.1);

  --grid-line: rgba(17, 17, 17, 0.05);
  --glow: rgba(249, 115, 22, 0.08);
  --noise: rgba(17, 17, 17, 0.02);

  --shadow-sm: 0 1px 2px rgba(16, 16, 16, 0.06);
  --shadow: 0 18px 40px -28px rgba(16, 16, 16, 0.35);
  --shadow-lift: 0 26px 55px -32px rgba(16, 16, 16, 0.4);

  --term-bg: #ffffff;
  --term-border: #e5e5e5;
  --term-text: #262626;
  --term-muted: #737373;
  --term-accent: #c2410c;
  --term-error: #b42318;
}
