/* =========================================================
   Design tokens — Cobalt (Hallmark catalog theme)
   Cool cobalt-on-light, one electric-blue signal, engineered.
   ========================================================= */

:root {
  /* ---- Fonts ---- */
  --font-display: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
  --font-body:    "Inter", ui-sans-serif, system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* ---- Type scale (1.25 major third, 16px base) ---- */
  --text-xs:      0.75rem;
  --text-sm:      0.875rem;
  --text-base:    1rem;
  --text-md:      1.125rem;
  --text-lg:      1.375rem;
  --text-xl:      1.75rem;
  --text-2xl:     clamp(1.75rem, 1.3rem + 1.6vw, 2.375rem);
  --text-3xl:     clamp(2.25rem, 1.4rem + 3vw, 3.25rem);
  --text-display: clamp(2.75rem, 1.6rem + 5vw, 5.25rem);

  /* ---- Spacing (4pt scale, named by role) ---- */
  --space-3xs: 0.125rem;
  --space-2xs: 0.25rem;
  --space-xs:  0.5rem;
  --space-sm:  0.75rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2.5rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;
  --space-4xl: 9rem;

  /* ---- Radii — tight, ruler-drawn ---- */
  --radius-control: 6px;
  --radius-card:    10px;
  --radius-photo:   14px;

  /* ---- Motion ---- */
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in:     cubic-bezier(0.7, 0, 0.84, 0);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --dur-micro: 120ms;
  --dur-short: 220ms;
  --dur-long:  420ms;

  /* ---- Z-scale ---- */
  --z-base:     1;
  --z-raised:   10;
  --z-dropdown: 100;
  --z-sticky:   200;
  --z-modal:    400;
  --z-toast:    500;

  /* ---- Layout ---- */
  --page-max: 1160px;
  --page-gutter: clamp(1.25rem, 4vw, 2.5rem);
  --rule-hair: 1px;
}

/* Axes — paper: cool light · display: grotesk-sans · accent: electric cobalt */
:root,
:root[data-theme="light"] {
  color-scheme: light;

  --color-paper:      oklch(98.5% 0.004 250);
  --color-paper-2:    oklch(96%   0.006 250);
  --color-rule:       oklch(88%   0.007 250);
  --color-rule-2:     oklch(80%   0.009 250);

  --color-ink:        oklch(24%   0.020 258);
  --color-ink-2:      oklch(36%   0.018 257);
  --color-muted:      oklch(52%   0.014 255);

  --color-accent:        oklch(58% 0.20 256);
  --color-accent-strong: oklch(46% 0.18 256);
  --color-accent-ink:    oklch(99% 0.006 256);
  --color-accent-soft:   oklch(58% 0.20 256 / 0.10);
  --color-focus:         oklch(58% 0.20 256);

  --color-error:      oklch(55% 0.20 25);
  --color-error-soft:  oklch(55% 0.20 25 / 0.10);
  --color-success:    oklch(58% 0.15 152);

  --color-graphite:      oklch(22% 0.016 260);
  --color-graphite-2:    oklch(27% 0.018 260);
  --color-graphite-rule: oklch(34% 0.020 260);
  --color-graphite-ink:  oklch(94% 0.010 258);
  --color-graphite-muted: oklch(72% 0.014 258);

  --shadow-whisper: 0 1px 2px oklch(24% 0.02 258 / 0.06);
  --shadow-lift:    0 12px 32px -20px oklch(24% 0.02 258 / 0.28);
}

:root[data-theme="dark"] {
  color-scheme: dark;

  --color-paper:      oklch(15%   0.014 258);
  --color-paper-2:    oklch(19%   0.016 258);
  --color-rule:       oklch(30%   0.016 258);
  --color-rule-2:     oklch(38%   0.018 258);

  --color-ink:        oklch(95%   0.008 258);
  --color-ink-2:      oklch(86%   0.010 257);
  --color-muted:      oklch(66%   0.012 255);

  --color-accent:        oklch(70% 0.17 256);
  --color-accent-strong: oklch(64% 0.18 256);
  --color-accent-ink:    oklch(14% 0.012 258);
  --color-accent-soft:   oklch(70% 0.17 256 / 0.14);
  --color-focus:         oklch(70% 0.17 256);

  --color-error:      oklch(68% 0.18 25);
  --color-error-soft:  oklch(68% 0.18 25 / 0.14);
  --color-success:    oklch(70% 0.14 152);

  --color-graphite:      oklch(9%  0.012 260);
  --color-graphite-2:    oklch(13% 0.014 260);
  --color-graphite-rule: oklch(24% 0.016 260);
  --color-graphite-ink:  oklch(95% 0.008 258);
  --color-graphite-muted: oklch(70% 0.012 258);

  --shadow-whisper: 0 1px 2px oklch(0% 0 0 / 0.5);
  --shadow-lift:    0 12px 32px -20px oklch(0% 0 0 / 0.6);
}
