/* Design tokens — loaded first. Every other stylesheet uses these via var(). See DESIGN.md. */

/* Type: Onest for everything people read (calm, exact, tabular figures, Latin + Cyrillic);
   Small meta (dates, currency, counts, chart labels): Onest with tabular figures (IBM Plex Mono dropped 01.12.2026).
   Self-hosted, OFL, from Fontsource. Geist was dropped: too common to feel like ours. */
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../assets/fonts/onest-latin.woff2') format('woff2');
  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;
}
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../assets/fonts/onest-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

:root {
  /* Solid surfaces (dialogs, inputs, menus) — warm white like the room light */
  --paper-0: #fffdf9; /* card / dialog */
  --paper-1: #f2eee7; /* page fallback under the backdrop */
  --paper-2: #f1ede6; /* raised: active row, input */
  --paper-deep: #fffdf9;
  --rule-1: #e6e0d6;
  --rule-2: #d6cfc3;
  /* Text roles (warm graphite) */
  --ink-4: #68625a;
  --ink-3: #57524b;
  --ink-2: #3d3934;
  --ink-1: #23201c;
  --ink-0: #14120f;
  /* Accent: the brand blue */
  --accent-soft: #e9efff;
  --accent-mid: #c6d3ff;
  --accent: #2f5bff;
  --accent-strong: #1f45e0;
  --accent-fill: #2f5bff;
  --accent-hi: #5b7fff; /* top of accent gradients */
  --accent-glow: rgba(47, 91, 255, 0.28);
  --accent-on: #ffffff; /* text on the accent */

  --ok: #116a33;
  --ok-soft: #e7f4ec;
  --ok-line: #b9dfc8;
  --ok-solid: #16a34a;
  --bad: #c42b2b;
  --bad-soft: #fbecea;
  --bad-line: #efc5c1;
  --bad-solid: #dc2626;
  --warn: #855500;
  --warn-soft: #f8efdc;
  --warn-line: #e6cf9e;
  --warn-solid: #b7791f;

  color-scheme: light;
  --font-ui: 'Onest', 'Segoe UI', -apple-system, sans-serif;
  --font-num: 'Onest', 'Segoe UI', sans-serif;
  /* Small labels use the UI face with tabular figures (owner, 01.12.2026: the typewriter face looked scattered on desktop). */
  --font-meta: 'Onest', 'Segoe UI', sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-card: 0 1px 2px rgba(60, 48, 30, 0.05), 0 10px 30px rgba(60, 48, 30, 0.08);
  --shadow-lift: 0 2px 6px rgba(60, 48, 30, 0.08), 0 18px 44px rgba(60, 48, 30, 0.16);
  /* Glass */
  --glass: rgba(255, 253, 249, 0.5);
  --glass-strong: rgba(255, 253, 249, 0.78);
  --glass-hover: rgba(255, 253, 249, 0.62);
  --glass-line: rgba(255, 255, 255, 0.65);
  --glass-blur: blur(26px) saturate(1.5);
  --radius-card: 22px;
}

/* Dark ("video 5"): slate-blue glass over a room at night, bright red accent. Losses keep their own pink-red and a minus sign. */
:root[data-theme='dark'] {
  color-scheme: dark;
  --paper-deep: #11151b;
  --paper-1: #0e1116;
  --paper-0: #1c2129;
  --paper-2: #262c36;
  --rule-1: #2e3540;
  --rule-2: #3d4552;
  --ink-4: #8d96a3;
  --ink-3: #a9b1bc;
  --ink-2: #cfd5dc;
  --ink-1: #eef1f4;
  --ink-0: #ffffff;
  --accent-soft: #3b1714;
  --accent-mid: #7a2a24;
  --accent: #ff6a5f;
  --accent-strong: #ffb4ad;
  --accent-fill: #d92d24;
  --accent-hi: #ff5a4f;
  --accent-glow: rgba(255, 69, 58, 0.35);
  --accent-on: #ffffff;
  --ok: #4cd08a;
  --ok-soft: #10261b;
  --ok-line: #24563b;
  --ok-solid: #2f9e68;
  --bad: #ff8094;
  --bad-soft: #2c1519;
  --bad-line: #5e2a33;
  --bad-solid: #d9364a;
  --warn: #f0be5c;
  --warn-soft: #2a2213;
  --warn-line: #5a4823;
  --warn-solid: #c48d2c;
  --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.07), 0 18px 44px rgba(0, 0, 0, 0.38);
  --shadow-lift: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 24px 60px rgba(0, 0, 0, 0.55);
  --glass: rgba(44, 51, 61, 0.58);
  --glass-strong: rgba(36, 42, 51, 0.9);
  --glass-hover: rgba(52, 60, 72, 0.64);
  --glass-line: rgba(255, 255, 255, 0.11);
  --glass-blur: blur(28px) saturate(1.5);
  --radius-card: 20px;
}
