/* ============================================
   DESIGN TOKENS — Mike Anderson / Serious Fun in Business
   Palette sampled directly from the book cover artwork:
   Navy #072891, Cream #F5F0EC, Ink #0A0A0A
   ============================================ */

:root {
  /* Type scale — fluid clamp() */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 5rem);
  --text-hero: clamp(2.75rem, 0.5rem + 6.5vw, 7rem);

  /* Spacing (4px system) */
  --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;
  --space-32: 8rem;

  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.9rem;
  --radius-xl: 1.4rem;
  --radius-full: 9999px;

  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  --content-narrow: 640px;
  --content-default: 780px;
  --content-wide: 1180px;
  --content-full: 100%;

  --font-display: 'Clash Grotesk', 'Arial Black', sans-serif;
  --font-body: 'Satoshi', 'Helvetica Neue', sans-serif;
  --font-hand: 'Caveat', cursive;
}

:root,
[data-theme='light'] {
  /* Surfaces — warm cream from book cover bg */
  --color-bg: #f5f0ec;
  --color-surface: #faf7f3;
  --color-surface-2: #ffffff;
  --color-surface-offset: #ece5db;
  --color-surface-offset-2: #e2d9cb;
  --color-surface-dynamic: #d8ccba;
  --color-divider: #ddd3c3;
  --color-border: #c9bda7;

  /* Text — ink black from cover */
  --color-text: #0a0a0a;
  --color-text-muted: #56524a;
  --color-text-faint: #9a9188;
  --color-text-inverse: #f5f0ec;

  /* Primary — navy from cover */
  --color-primary: #072891;
  --color-primary-hover: #051d6e;
  --color-primary-active: #04154f;
  --color-primary-highlight: #dbe0f2;

  --shadow-sm: 0 1px 2px rgba(10, 10, 10, 0.06);
  --shadow-md: 0 6px 20px rgba(7, 40, 145, 0.1);
  --shadow-lg: 0 20px 48px rgba(7, 40, 145, 0.16);
}

[data-theme='dark'] {
  --color-bg: #0a0e1e;
  --color-surface: #10142a;
  --color-surface-2: #141930;
  --color-surface-offset: #151a32;
  --color-surface-offset-2: #1b2140;
  --color-surface-dynamic: #232a4d;
  --color-divider: #24294a;
  --color-border: #323a63;

  --color-text: #ece7de;
  --color-text-muted: #a7abc6;
  --color-text-faint: #666c92;
  --color-text-inverse: #0a0e1e;

  --color-primary: #7d95e8;
  --color-primary-hover: #9caef0;
  --color-primary-active: #b7c3f4;
  --color-primary-highlight: #1e2450;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.5);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #0a0e1e;
    --color-surface: #10142a;
    --color-surface-2: #141930;
    --color-surface-offset: #151a32;
    --color-surface-offset-2: #1b2140;
    --color-surface-dynamic: #232a4d;
    --color-divider: #24294a;
    --color-border: #323a63;
    --color-text: #ece7de;
    --color-text-muted: #a7abc6;
    --color-text-faint: #666c92;
    --color-text-inverse: #0a0e1e;
    --color-primary: #7d95e8;
    --color-primary-hover: #9caef0;
    --color-primary-active: #b7c3f4;
    --color-primary-highlight: #1e2450;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.5);
  }
}
