/* ==========================================================================
   Mogahid Sabeel — site v3 "Desktop, Reissued" — design tokens
   Light = "beige case", dark = "teal desktop at night". Proposed in the brief
   (2026-11-06); every value is open to the owner's review in Phase 2.
   ========================================================================== */

/* ---------- Fonts (self-hosted, SIL OFL) ---------- */
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("../fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("../fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
/* VT323 (SIL OFL, licence in assets/fonts/OFL-VT323.txt) for window titles and terminal lines. Latin subset; download approved by the owner on 2026-11-07. */
@font-face { font-family: "VT323"; src: url("../fonts/vt323-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  /* Light theme — "beige case" */
  --bg: #E9E4D6;            /* case plastic */
  --bg-grid: rgba(30, 27, 22, .06);
  --surface: #F7F4EC;       /* window surface */
  --surface-2: #EFEADD;     /* inset panels, toolbars */
  --ink: #1E1B16;
  --ink-2: #5B564C;         /* muted text */
  --line: rgba(30, 27, 22, .18);
  --amber: #9A5B00;         /* accent on light surfaces */
  --amber-bright: #FFB000;  /* large decorative fills only */
  --teal: #0E6F6E;          /* links, active items */
  --teal-ink: #0E6F6E;
  --link: var(--teal);
  --bevel-l: #FFFFFF;
  --bevel-d: #8A857A;
  --bevel-dd: #4A463F;
  --bar-a: #0E6F6E;         /* active title bar gradient */
  --bar-b: #083F3E;
  --bar-ink: #FFFFFF;
  --bar-off: #B9B3A6;       /* inactive title bar */
  --bar-off-ink: #1E1B16;
  --term-bg: #1A1612;       /* terminal body */
  --term-ink: #FFB000;      /* amber phosphor */
  --term-text: #ECE7D9;
  --term-dim: #B8B2A3;
  --focus: #0E6F6E;
  --sel-bg: #0E6F6E;
  --sel-ink: #FFFFFF;
  --tag-delivered: #CFE6E4;
  --tag-strategy: #D6E0EC;
  --tag-practice: #F1E2C5;
  --tag-learning: #E6E2D8;
  --tag-ink: #1E1B16;
  --ok: #0E6F6E;
  --warn: #9A5B00;
  --icon-2: #9A5B00;        /* second icon tone */
  --icon-3: #F7F4EC;        /* paper / lens tone */
  --icon-4: #1A1612;        /* terminal screen tone */
  --shadow: 2px 2px 0 var(--bevel-dd);

  --f-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
  --f-term: "VT323", "IBM Plex Mono", ui-monospace, Consolas, monospace;

  --ease: cubic-bezier(.2, .7, .1, 1);
  --t-fast: 120ms;
  --t-win: 180ms;
  --taskbar-h: 48px;
  --bar-h: 32px;
  --maxw: 1180px;
  --gutter: clamp(16px, 3vw, 32px);
  color-scheme: light;
}

/* Dark theme — "teal desktop at night" */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #062B2A; --bg-grid: rgba(236, 231, 217, .05);
    --surface: #0F1F1E; --surface-2: #142827;
    --ink: #ECE7D9; --ink-2: #B8B2A3; --line: rgba(236, 231, 217, .18);
    --amber: #FFB000; --teal: #5CC8C6; --teal-ink: #5CC8C6; --link: #5CC8C6;
    --bevel-l: #2A3F3E; --bevel-d: #000000; --bevel-dd: #000000;
    --bar-a: #0E6F6E; --bar-b: #083F3E; --bar-ink: #ECE7D9;
    --bar-off: #2A3F3E; --bar-off-ink: #ECE7D9;
    --term-bg: #070A09; --term-ink: #FFB000; --term-text: #ECE7D9; --term-dim: #B8B2A3;
    --focus: #FFB000; --sel-bg: #FFB000; --sel-ink: #1E1B16;
    --tag-delivered: #123C3B; --tag-strategy: #1C2E40; --tag-practice: #3F2E10; --tag-learning: #26302F; --tag-ink: #ECE7D9;
    --ok: #5CFF7A; --warn: #FFB000;
    --icon-2: #FFB000; --icon-3: #0F1F1E; --icon-4: #070A09;
    --shadow: 2px 2px 0 #000;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #062B2A; --bg-grid: rgba(236, 231, 217, .05);
  --surface: #0F1F1E; --surface-2: #142827;
  --ink: #ECE7D9; --ink-2: #B8B2A3; --line: rgba(236, 231, 217, .18);
  --amber: #FFB000; --teal: #5CC8C6; --teal-ink: #5CC8C6; --link: #5CC8C6;
  --bevel-l: #2A3F3E; --bevel-d: #000000; --bevel-dd: #000000;
  --bar-a: #0E6F6E; --bar-b: #083F3E; --bar-ink: #ECE7D9;
  --bar-off: #2A3F3E; --bar-off-ink: #ECE7D9;
  --term-bg: #070A09; --term-ink: #FFB000; --term-text: #ECE7D9; --term-dim: #B8B2A3;
  --focus: #FFB000; --sel-bg: #FFB000; --sel-ink: #1E1B16;
  --tag-delivered: #123C3B; --tag-strategy: #1C2E40; --tag-practice: #3F2E10; --tag-learning: #26302F; --tag-ink: #ECE7D9;
  --ok: #5CFF7A; --warn: #FFB000;
  --icon-2: #FFB000; --icon-3: #0F1F1E; --icon-4: #070A09;
  --shadow: 2px 2px 0 #000;
  color-scheme: dark;
}
