/**
 * Workbench - Design Tokens
 *
 * Farverne fra version 1: varm offwhite, marineblå topbar, rust som accent, mos som "færdig".
 * Ret tokens her, ikke i komponenterne. Mørkt tema følger systemet, medmindre data-theme er sat.
 */

:root {
  /* -------- Flader -------- */
  --bg: #F3F0E8;
  --surface: #FBFAF6;
  --surface-2: #F1EDE3;
  --col: #EBE7DC;
  --hover: #F1EDE3;

  /* -------- Linjer -------- */
  --line: #E7E1D4;
  --line-2: #DCD5C6;

  /* -------- Tekst -------- */
  --ink: #1D2621;
  --ink-2: #3A423C;
  --muted: #646A62;
  --dim: #8D9187;

  /* -------- Accent og status -------- */
  --accent: #B4532C;
  --accent-weak: #F4E6DC;
  --accent-ink: #FFFAF4;
  --moss: #2F5E44;
  --ok: #2F7D5B;
  --ok-bg: #E4F1EA;
  --warn: #B97A1E;
  --warn-bg: #F8EDD8;
  --crit: #B23A2C;
  --crit-bg: #F7E2DE;
  --flow: #5B3FA3;

  /* -------- Topbar -------- */
  --nav: #0E2536;
  --nav-ink: #E9EEF0;
  --nav-muted: #9FB2BC;

  /* -------- Tonede eksempler (tomme tilstande på Dokumenter, t-126) -------- */
  --ghost: rgba(29, 38, 33, .07);
  --ghost-2: rgba(29, 38, 33, .12);
  --ghost-line: rgba(29, 38, 33, .18);
  --ghost-accent: rgba(180, 83, 44, .28);
  --ghost-ok: rgba(47, 125, 91, .25);
  --ghost-dot: rgba(29, 38, 33, .09);

  /* -------- Typografi -------- */
  --sans: 'Schibsted Grotesk', system-ui, -apple-system, sans-serif;
  --nav-sans: 'Instrument Sans', system-ui, -apple-system, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Consolas, monospace;

  /* -------- Form -------- */
  --radius: 10px;
  --shadow: 0 1px 2px rgba(40, 30, 10, .06), 0 6px 20px rgba(40, 30, 10, .07);
  --shadow-card: 0 1px 0 rgba(40, 30, 10, .06), 0 1px 3px rgba(40, 30, 10, .05);
  --drawer-w: 600px;
  --ai-panel-w: 440px;
  --topbar-h: 54px;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121613; --surface: #1B201C; --surface-2: #222823; --col: #171B18; --hover: #222823;
    --line: #232A25; --line-2: #2B332D;
    --ink: #E8E5DA; --ink-2: #C9C8BD; --muted: #A2A69B; --dim: #7C8177;
    --accent: #E2794B; --accent-weak: #33221A; --accent-ink: #1A0F08; --moss: #8DBB9C;
    --ok: #5CC08F; --ok-bg: #163327; --warn: #E0A64C; --warn-bg: #36291A; --crit: #E8786A; --crit-bg: #3A1F1C; --flow: #B9A4F0;
    --nav: #0A1A27; --nav-ink: #E9EEF0; --nav-muted: #8FA3AF;
    --ghost: rgba(232, 229, 218, .06); --ghost-2: rgba(232, 229, 218, .11); --ghost-line: rgba(232, 229, 218, .2);
    --ghost-accent: rgba(226, 121, 75, .32); --ghost-ok: rgba(92, 192, 143, .28); --ghost-dot: rgba(232, 229, 218, .08);
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
    --shadow-card: 0 1px 0 rgba(0, 0, 0, .3);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #121613; --surface: #1B201C; --surface-2: #222823; --col: #171B18; --hover: #222823;
  --line: #232A25; --line-2: #2B332D;
  --ink: #E8E5DA; --ink-2: #C9C8BD; --muted: #A2A69B; --dim: #7C8177;
  --accent: #E2794B; --accent-weak: #33221A; --accent-ink: #1A0F08; --moss: #8DBB9C;
  --ok: #5CC08F; --ok-bg: #163327; --warn: #E0A64C; --warn-bg: #36291A; --crit: #E8786A; --crit-bg: #3A1F1C; --flow: #B9A4F0;
  --nav: #0A1A27; --nav-ink: #E9EEF0; --nav-muted: #8FA3AF;
  --ghost: rgba(232, 229, 218, .06); --ghost-2: rgba(232, 229, 218, .11); --ghost-line: rgba(232, 229, 218, .2);
  --ghost-accent: rgba(226, 121, 75, .32); --ghost-ok: rgba(92, 192, 143, .28); --ghost-dot: rgba(232, 229, 218, .08);
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
  --shadow-card: 0 1px 0 rgba(0, 0, 0, .3);
  color-scheme: dark;
}
