/* Design tokens — single source of truth for node pages. Referenced by
   layouts/default.ejs on every page. Flutter mirror: flutter-app/lib/theme.dart
   (keep the two files in sync by hand — update BOTH when a token changes).
   Contrast values are documented in docs/node-flutter/accessibility.md; new
   colors must be AA-checked against #faf6ef / #f7f4ee / #fff before landing.
   Per docs/node-flutter/design-consistency-plan.md (D1): the brand has TWO
   official golds — do not invent a third:
   - --color-primary  #c9a14a  muted "action gold" (Lese-family pages:
     ordbok, books, login, minside, progress, arbeidsnorsk, organization…)
   - --accent         #fbc24b  bright "brand gold" (hero, home, chat, skrive,
     teaching, speaking, Flutter app)
   Page CSS must consume these vars, never re-declare local gold/brown sets. */
:root {
  /* Brand accent A — muted action gold (Lese-family) */
  --color-primary:       #c9a14a;
  --color-primary-hover: #b08e3f;
  --color-primary-ink:   #ffffff;
  --color-primary-soft:  #fff8e8;   /* selected gold wash */

  /* Brand accent B — bright brand gold (hero/home/chat/Flutter) */
  --accent:       #fbc24b;
  --accent-hover: #eea94d;
  --accent-deep:  #d4a017;   /* darker gold for icons/borders on light bg */
  --accent-soft:  #fef6dd;   /* pale gold wash */
  --accent-ink:   #3d2e14;   /* dark warm ink for text ON --accent fills */
  --accent-on:    #7a6f5f;   /* alt text-on-accent (accessibility.md, 5.0:1) */
  --accent-text:  #7d6428;   /* gold-toned TEXT on white/cream (AA; ordbok pass) */

  /* Text — warm browns. --color-text* are the legacy names; the --text-*
     aliases match accessibility.md's contrast table (vs cream):
     strong 12.5:1 · default 9.7:1 · muted 6.3:1 · soft ~4.6:1 · cool 5.6:1 */
  --color-text:        #6d5f4a;     /* body (legacy pages) */
  --color-text-strong: #222222;     /* headings (legacy pages) */
  --color-text-muted:  #5f5238;     /* was #827153 — AA bump (4.26:1 → 6.3:1) */
  --text-strong:  #3d342a;
  --text-default: #4a4540;
  --text-muted:   #5f5238;
  --text-soft:    #6d655b;   /* lightest allowed body/caption color */
  --text-cool:    #5e6470;   /* cool-gray secondary */

  /* Surfaces */
  --color-bg:       #ffffff;
  --color-bg-soft:  #faf6ef;        /* page cream (legacy) */
  --color-bg-card:  #ffffff;
  --color-border:   #e0dbd4;        /* warm hairline (legacy) */
  --bg-cream:       #f7f4ee;        /* app cream (home/chat/Flutter) */
  --border-warm:    #e7ddcc;        /* chat/skrive-family hairline */
  --border-soft:    #ece6da;        /* home/skrive-family hairline */

  /* CEFR level badge colors — ONE scheme, warm ramp, never blue
     (brand rule). White badge text; A0/A1 pair with dark text if small. */
  --level-a0: #8BC34A;
  --level-a1: #4CAF50;
  --level-a2: #D4A017;   /* was #2196F3 — blue is off-brand */
  --level-b1: #FF9800;
  --level-b2: #f44336;

  /* Status — dark enough for text on white/cream (AA) */
  --color-success:      #3e7c5a;   /* was #4caf50 (text failed AA) */
  --color-success-deep: #1f5e3c;
  --color-success-soft: #e8f5e9;
  --color-error:        #b42318;   /* was #e57373 (text failed AA) */
  --color-error-soft:   #fdecea;
  --color-warn:         #b45309;
  --focus-ring:         #7d5f1c;   /* matches base.css :focus-visible */

  /* Spacing */
  --space-1: 4px;  --space-2: 8px;  --space-3: 12px;  --space-4: 16px;
  --space-6: 24px; --space-8: 32px;

  /* Radius */
  --radius-default: 8px;
  --radius-lg: 12px;
  --radius-card: 14px;
  --radius-pill: 999px;

  /* Layout */
  --nav-clearance: 74px;        /* fixed 50px nav + breathing room */
  --container-narrow:  640px;   /* single tool/form pages */
  --container-content: 900px;   /* reading/detail pages */
  --container-wide:   1100px;   /* browse grids/dashboards */

  /* Typography — proxima-nova body (Typekit), Fraunces display serif
     (self-hosted, /css/fonts.css). --font-display stays proxima for legacy
     headings; pages that use the serif look opt in via --font-serif. */
  --font-family:  'proxima-nova', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'proxima-nova', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-serif:   'Fraunces', Georgia, serif;
  --font-size-base: 16px;
  --font-size-lg:   20px;
  --font-size-xl:   26px;
}
