/* ==========================================================================
   01-tokens.css
   Brand-agnostic tokens: spacing, type scale, radii, motion, layout.
   This file holds no brand values. Colors and fonts are declared here as a
   semantic contract with neutral defaults, and each theme (02-theme.*.css)
   overrides them. Components (03) read only these semantic names.
   ========================================================================== */

:root {
  /* Spacing: 8px base */
  --space-0-5: 4px;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 40px;
  --space-6: 48px;
  --space-8: 64px;
  --space-10: 80px;
  --space-12: 96px;
  --space-16: 128px;

  /* Layout */
  --container-max: 1200px;
  --container-narrow: 760px;
  --gutter: clamp(20px, 4vw, 40px);
  --section-pad: clamp(64px, 9vw, 128px);
  --header-h: 72px;
  --media-h-md: clamp(240px, 24vw, 340px);
  --media-h-lg: clamp(280px, 34vw, 480px);

  /* Type scale */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-md: 1.125rem;
  --text-lg: 1.25rem;
  --text-xl: clamp(1.375rem, 1.1rem + 0.9vw, 1.75rem);
  --text-2xl: clamp(1.75rem, 1.3rem + 1.6vw, 2.5rem);
  --text-3xl: clamp(2.25rem, 1.5rem + 2.8vw, 3.5rem);
  --text-4xl: clamp(2.75rem, 1.6rem + 4.2vw, 4.75rem);
  --text-5xl: clamp(2.5rem, 1.5rem + 3.8vw, 4.25rem);

  --leading-tight: 0.95;
  --leading-snug: 1.12;
  --leading-normal: 1.6;

  --tracking-tight: -0.01em;
  --tracking-normal: 0;
  --tracking-wide: 0.06em;
  --tracking-wider: 0.14em;

  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;

  /* Shape */
  --radius-0: 0;
  --radius-1: 4px;
  --radius-2: 8px;
  --radius-pill: 999px;
  --chamfer-sm: 8px;
  --chamfer-md: 14px;
  --chamfer-lg: 28px;
  --border-w: 1px;
  --rule-w: 2px;

  /* Motion */
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --dur-1: 150ms;
  --dur-2: 300ms;
  --dur-3: 600ms;
  --reveal-shift: 16px;

  /* Layers */
  --z-base: 1;
  --z-header: 50;
  --z-menu: 60;
  --z-dev: 90;

  /* Semantic contract (neutral defaults; themes override) */
  --font-display: system-ui, sans-serif;
  --font-body: system-ui, sans-serif;
  --font-label: system-ui, sans-serif;

  --color-bg: #ffffff;
  --color-bg-raised: #f4f4f4;
  --color-bg-sunken: #eaeaea;
  --color-border: #d6d6d6;
  --color-border-strong: #a8a8a8;
  --color-text: #111111;
  --color-text-muted: #444444;
  --color-text-subtle: #6b6b6b;
  --color-accent: #111111;
  --color-accent-hover: #333333;
  --color-accent-contrast: #ffffff;
  --color-highlight: #111111;
  --color-highlight-hover: #333333;
  --color-highlight-contrast: #ffffff;
  --color-focus: #0066ff;
  --color-flag: #ffb000;
  --color-input-bg: #ffffff;
  --color-input-border: #a8a8a8;
  --color-error: #c00020;
  --color-success: #0a7a3d;

  --numeral-fill: var(--color-text);
  --numeral-gap: var(--color-bg);
  --numeral-outline: var(--color-highlight);
}
