/* Design tokens — aligned with the waldersloff.no theme (warm charcoal / paper,
   copper accent, Manrope, monospace labels, hairlines, square corners). */

/* Manrope is loaded by boot.js only when served from waldersloff.no (the main site hosts the
   font file). Elsewhere the system sans stack below is used, so no font request can 404. */

:root {
  color-scheme: dark;
  --paper: #111110;
  --ink: #f1eee8;
  --muted: #b5afa6;
  --faint: #8a847b;
  --line: #393631;
  --line-soft: #2a2825;
  --surface: #1a1917;
  --raised: #24211e;
  --accent: #d6a284;
  --accent-hover: #e9bfa5;
  --accent-contrast: #17120f;
  --accent-soft: rgba(214, 162, 132, 0.12);
  --warm: #9b6e53;
  --overlay: rgba(8, 8, 7, 0.72);
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);

  /* Reserved status tones (never reused as series colours). */
  --ok: #8fc49a;      --ok-soft: rgba(143, 196, 154, 0.12);
  --warn: #e0b860;    --warn-soft: rgba(224, 184, 96, 0.13);
  --serious: #ec9a68; --serious-soft: rgba(236, 154, 104, 0.14);
  --danger: #f08372;  --danger-soft: rgba(240, 131, 114, 0.14);
  --info: #94b2cc;    --info-soft: rgba(148, 178, 204, 0.13);
  --neutral: #8f8a82; --neutral-soft: rgba(181, 175, 166, 0.10);

  --body: 'Manrope', 'Segoe UI Variable', 'Segoe UI', system-ui, -apple-system, Roboto, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, 'Cascadia Mono', Consolas, 'Liberation Mono', monospace;

  --gutter: clamp(1rem, 3vw, 2.5rem);
  --topbar-h: 60px;
  --sidebar-w: 248px;
  --radius: 0px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

:root[data-theme="light"] {
  color-scheme: light;
  --paper: #f0ede6;
  --ink: #22221f;
  --muted: #5b5b52;
  --faint: #64625a; /* v8.5: was #77756b (3.6:1 on surface); now ≥ 4.5:1 for small notes */
  --line: #c7c2b7;
  --line-soft: #d9d4ca;
  --surface: #e6e1d7;
  --raised: #ded7cb;
  --accent: #815032;
  --accent-hover: #673d24;
  --accent-contrast: #fffaf3;
  --accent-soft: rgba(129, 80, 50, 0.09);
  --warm: #97684c;
  --overlay: rgba(34, 34, 31, 0.45);
  --shadow: 0 18px 50px rgba(40, 32, 24, 0.18);

  --ok: #2f6b3c;      --ok-soft: rgba(47, 107, 60, 0.10);
  --warn: #7c5a0b; /* v8.5: was #85600c (4.4:1 on surface) */    --warn-soft: rgba(176, 128, 20, 0.13);
  --serious: #9a4a1c; --serious-soft: rgba(154, 74, 28, 0.10);
  --danger: #a3302a;  --danger-soft: rgba(163, 48, 42, 0.10);
  --info: #345e85;    --info-soft: rgba(52, 94, 133, 0.10);
  --neutral: #6c6a62; --neutral-soft: rgba(92, 91, 82, 0.09);
}

:root[data-density="compact"] {
  --topbar-h: 52px;
}
