/* Colours of Essen and Schlafen – this file is byte-identical in both apps (test/themetokens.test.ts
   checks the values; copy it over when it changes). Two themes, chosen per device in Einstellungen →
   Darstellung (Auto follows the phone, Tag, Nacht – public/js/appearance.js; the inline script in
   index.html sets data-theme on <html> before the first paint):
   – Tag (default): the pastel light design.
   – Nacht: dark blue (navy/indigo, never black) with light text, every pairing ≥ 4.5:1 (WCAG AA).
   A person's own accent colour (Einstellungen → Farbe) overrides the --accent… values on <html>
   with public/js/accent.js palette() / nightPalette(); the defaults here are those of the original
   blue (hue 224). */
:root {
  color-scheme: light;
  --bg: #f7f7fc;
  --card: #fff;
  --ink: #1b2447;
  --muted: #5f6683; /* ≥ 4.5:1 on bg, card and accent-soft */
  --faint: #686e8c; /* secondary notes, still ≥ 4.5:1 */
  --warn: #b85a00; /* orange text (amount still to buy), ≥ 4.5:1 */
  --line: #eceef6;
  --line-strong: #d6dbea; /* dashed drop zones, dividers that must show */
  --surface-2: #eef0f6; /* quiet fills: skeletons, chips, inactive segments */
  --tile-base: #fff; /* what the pastel Art/kid tints are mixed into */
  --overlay: rgba(10, 14, 30, 0.35); /* behind sheets */
  --shadow-rgb: 27 36 71; /* rgb(var(--shadow-rgb) / a) */

  --accent: #2f5bd3;
  --accent-hover: #2951c0;
  --accent-pressed: #2448ab;
  --accent-rgb: 47 91 211; /* for shadows: rgb(var(--accent-rgb) / 0.3) */
  --accent-soft: #e8eefc;
  --accent-softer: #d6e0fa; /* soft, pressed */
  --accent-line: #a9bdf2;
  --accent-wash: #fbfcff;
  --accent-ink: #22408f; /* text on --accent-soft (notes) */
  --accent-hi: #4f7cf0; /* light end of accent gradients */
  --accent-deep: #1b2447; /* dark end of the ✨ gradients */
  --accent-grad: linear-gradient(135deg, var(--accent-deep), var(--accent));
  --accent-text: var(--accent); /* accent-coloured text and outlines on the page */

  /* „erledigt / vorrätig“ – semantic, not the accent */
  --ok: #1f7a3d;
  --ok-soft: #e3f4e8;
  --ok-line: #9fd6b0;
  --ok-wash: #eef6f0;
  --gold: #f2b53a;
  --gold-soft: #fff4dc;
  --gold-ink: #8a5a00; /* text on --gold-soft */
  --danger: #bf3434;
  --danger-soft: #fdecec;
  --danger-line: #f3caca;
  --lilac-soft: #f1e8fb;
  --mint-soft: #e3f5ee;
}

html[data-theme="night"] {
  color-scheme: dark;
  --bg: #0f1a33;
  --card: #16213f;
  --ink: #e7ebff; /* 14:1 on card */
  --muted: #a9b2d6; /* 7.6:1 on card */
  --faint: #9aa3c9;
  --warn: #ffb36b;
  --line: #24305a;
  --line-strong: #34437a;
  --surface-2: #1d2a4d;
  --tile-base: #16213f;
  --overlay: rgba(3, 6, 18, 0.6);
  --shadow-rgb: 2 5 16;

  --accent: #355fd4;
  --accent-hover: #466dd8;
  --accent-pressed: #2b55ca;
  --accent-rgb: 53 95 212;
  --accent-soft: #212d50;
  --accent-softer: #283967;
  --accent-line: #3e5698;
  --accent-wash: #181f35;
  --accent-ink: #8ca7f2;
  --accent-hi: #5f86f1;
  --accent-deep: #1b2346;
  --accent-text: #6f92f3;

  --ok: #4dcb77;
  --ok-soft: #1d3a26;
  --ok-line: #3d7b51;
  --ok-wash: #172b1e;
  --gold: #f2b53a;
  --gold-soft: #3a2f14;
  --gold-ink: #ffd27a;
  --danger: #ff8080;
  --danger-soft: #3a1c26;
  --danger-line: #6b2d3c;
  --lilac-soft: #2b2450;
  --mint-soft: #173a33;
}
