/* material3-dark-overrides.css -- EW UI dark theme as a token override layer. Keyed on
   html[data-theme="dark"] (specificity 0,1,1) so it beats the licensed base AND the SDK light
   :root overrides regardless of link order -- a plain :root dark block would tie the light override
   and lose by source order. Foundation tokens (base ramp, surfaces, text, semantic) live here; dark
   BRAND (primary) lives in each palette's html[data-theme="dark"] block. Neutral ramp + text are
   verbatim from material3-dark-base.css :root; base-lighter is an elevated dark surface (licensed
   base uses #ffffff -- wrong for a surface token here). Custom-property indirection means input
   borders / field-bg auto-follow this ramp.
   Semantic families are the EdWise tone-grammar ramps at their DARK assignments (anchor T80,
   container T30, emphasis T70, deep T20; on-anchor T20) -- generated, same provenance as the light
   swatch: .tooling/theme-gen + docs/superpowers/specs/2026-06-09-edwise-theme-design.md.
   Plain-ASCII only. */
html[data-theme="dark"] {
  /* Neutral ramp (inverted) -- verbatim from material3-dark-base.css :root */
  --rz-white: #ffffff;
  --rz-base: #45494f;
  --rz-base-50: #e0e4e9;
  --rz-base-100: #c4c9d0;
  --rz-base-200: #8f9399;
  --rz-base-300: #45494f;
  --rz-base-400: #383b3e;
  --rz-base-500: #34373b;
  --rz-base-600: #292c30;
  --rz-base-700: #1f2226;
  --rz-base-800: #1b1d20;
  --rz-base-900: #121518;
  --rz-base-light: #8f9399;
  --rz-base-dark: #121518;
  --rz-base-darker: #000000;
  /* base-lighter = elevated dark surface (NOT the licensed #ffffff -- it backs cards/fields) */
  --rz-base-lighter: #1f2226;

  /* Surfaces */
  --rz-base-background-color: #1b1d20;
  --rz-body-background-color: #1f2226;
  --rz-panel-background-color: #1b1d20;

  /* Text (point at the inverted ramp -- light on dark) */
  --rz-text-color: var(--rz-base-50);
  --rz-text-secondary-color: var(--rz-base-100);
  --rz-text-tertiary-color: var(--rz-base-200);
  --rz-text-disabled-color: var(--rz-base-300);
  --rz-text-title-color: var(--rz-base-50);

  /* Secondary family -- dark tone assignments (S2 ramp, H276 C16). */
  --rz-secondary: #c2c5dd;
  --rz-secondary-light: #424659;
  --rz-secondary-lighter: rgba(194, 197, 221, 0.16);
  --rz-secondary-dark: #a7aac1;
  --rz-secondary-darker: #2c2f42;
  --rz-on-secondary: #2c2f42;
  --rz-on-secondary-light: #dfe1f9;
  --rz-on-secondary-lighter: #dfe1f9;
  --rz-on-secondary-dark: #2c2f42;
  --rz-on-secondary-darker: #dfe1f9;

  /* Severity families -- the same four MCU ramps as light, flipped to dark tones. */
  --rz-info: #6bd3f9;
  --rz-info-light: #004d62;
  --rz-info-lighter: rgba(107, 211, 249, 0.16);
  --rz-info-dark: #4bb7dc;
  --rz-info-darker: #003544;
  --rz-on-info: #003544;
  --rz-on-info-light: #b9eaff;
  --rz-on-info-lighter: #b9eaff;
  --rz-on-info-dark: #003544;
  --rz-on-info-darker: #b9eaff;
  --rz-success: #84d994;
  --rz-success-light: #005323;
  --rz-success-lighter: rgba(132, 217, 148, 0.16);
  --rz-success-dark: #69bd7a;
  --rz-success-darker: #003916;
  --rz-on-success: #003916;
  --rz-on-success-light: #a0f6ae;
  --rz-on-success-lighter: #a0f6ae;
  --rz-on-success-dark: #003916;
  --rz-on-success-darker: #a0f6ae;
  --rz-warning: #ffba3e;
  --rz-warning-light: #604100;
  --rz-warning-lighter: rgba(255, 186, 62, 0.16);
  --rz-warning-dark: #e39e00;
  --rz-warning-darker: #432c00;
  --rz-on-warning: #352200;
  --rz-on-warning-light: #ffdeae;
  --rz-on-warning-lighter: #ffdeae;
  --rz-on-warning-dark: #352200;
  --rz-on-warning-darker: #ffdeae;
  --rz-danger: #ffb4ab;
  --rz-danger-light: #93000a;
  --rz-danger-lighter: rgba(255, 180, 171, 0.16);
  --rz-danger-dark: #ff897d;
  --rz-danger-darker: #690005;
  --rz-on-danger: #690005;
  --rz-on-danger-light: #ffdad6;
  --rz-on-danger-lighter: #ffdad6;
  --rz-on-danger-dark: #690005;
  --rz-on-danger-darker: #ffdad6;

  /* Chart series 1-8 -- brighter dark variants (T70-80) of the brand-harmonized light set. */
  --rz-series-1: #73adff;
  --rz-series-2: #b8c4ff;
  --rz-series-3: #63c8cc;
  --rz-series-4: #f1bf52;
  --rz-series-5: #e2a6d6;
  --rz-series-6: #89c78d;
  --rz-series-7: #ff9f94;
  --rz-series-8: #b5b7cf;

  /* Button interaction state layers: white scrims on dark (light scheme uses ink scrims). */
  --rz-button-hover-gradient: linear-gradient(rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.08));
  --rz-button-focus-gradient: linear-gradient(rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.10));
  --rz-button-active-gradient: linear-gradient(rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.12));

  /* Outlined-button border: the dark outline role (= the dark ramp's base-200, written as a
     literal -- a var(base-200) fallback here would be flagged by the light-value fallback
     police, and the indirection buys nothing inside the file that declares the ramp). */
  --ew-button-outline: #8f9399;

  /* Chrome (sidebar colors come from the palette's dark block; topbar darkens). field-bg
     auto-follows base-lighter; only the disabled field surface needs a darker explicit value. */
  --ew-topbar-bg: #1b1d20;
  --ew-topbar-fg: var(--rz-base-50);
  --ew-topbar-border: var(--rz-base-600);
  --ew-field-bg-disabled: var(--rz-base-800);
  /* Content canvas: the deepest dark surface, so panels/cards (#1b1d20/#1f2226) sit elevated
     above it (dark elevation = lighter surface, not bigger shadow). */
  --ew-content-bg: #121518;
}
