/*
 * theme.css — shared CSS token layer for RebelDrift.
 * Generated from design/tokens/tokens.json (v0.1.0-placeholder, 2026-07-17) — do not edit values by hand;
 * regenerate from tokens.json after any token change.
 * Colors are PLACEHOLDER pending the visual-direction reset (01-discovery-notes.md, round-2 q3).
 * System-font-only by design for now: no @font-face until typography is decided.
 */

@layer tokens, base;

@layer tokens {
  :root {
    /* Color */
    --color-primary: #339895;
    --color-primary-on: #0E1113;
    --color-secondary: #257370;
    --color-secondary-on: #F2F4F5;
    --color-accent: #4AC2BE;
    --color-accent-on: #0E1113;
    --color-surface: #14171A;
    --color-surface-on: #F2F4F5;
    --color-surface-alt: #1C2126;
    --color-surface-alt-on: #F2F4F5;
    --color-text: #F2F4F5;
    --color-text-on: #14171A;
    --color-text-muted: #A6ADB4;
    --color-text-muted-on: #14171A;
    --color-border: #2C3238;
    --color-border-on: #F2F4F5;
    --color-success: #7ED6A0;
    --color-success-on: #0E1113;
    --color-warning: #E2B93B;
    --color-warning-on: #0E1113;
    --color-error: #F28B82;
    --color-error-on: #0E1113;

    /* Typography */
    --font-heading: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --font-body: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --font-mono: ui-monospace, 'SFMono-Regular', 'Menlo', monospace;

    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-md: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.375rem;
    --font-size-2xl: 2rem;
    --font-size-3xl: 3rem;

    --line-tight: 1.1;
    --line-snug: 1.4;
    --line-normal: 1.6;

    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-bold: 700;

    /* Spacing (4px base) */
    --space-3xs: 0.25rem;
    --space-2xs: 0.5rem;
    --space-xs: 0.75rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;
    --space-3xl: 6rem;

    /* Radius */
    --radius-none: 0;
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --radius-full: 9999px;

    /* Shadow */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.35);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.40);
    --shadow-lg: 0 12px 32px rgba(0,0,0,0.50);

    /* Breakpoints (for reference in JS/container queries) */
    --breakpoint-sm: 640px;
    --breakpoint-md: 1024px;
    --breakpoint-lg: 1280px;
    --breakpoint-xl: 1536px;

    /* Layout (content width constraints) */
    --content-width: 720px;
    --wide-width: 1200px;
  }
}

@layer base {
  *, *::before, *::after { box-sizing: border-box; }

  body {
    margin: 0;
    font-family: var(--font-body);
    font-size: var(--font-size-md);
    line-height: var(--line-normal);
    color: var(--color-text);
    background: var(--color-surface);
  }

  h1, h2, h3, h4 {
    font-family: var(--font-heading);
    line-height: var(--line-tight);
    color: var(--color-text);
  }

  a { color: var(--color-accent); }

  :focus-visible {
    outline: 3px solid var(--color-accent);
    outline-offset: 2px;
  }

  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
      scroll-behavior: auto !important;
    }
  }
}
