/* ============================================================
   THEME PRIMITIVES
   ------------------------------------------------------------
   The raw, brand-level values that change per client theme.
   Switching theme = setting data-theme on <html> (done centrally
   in fragments/shared/head.html from the server `themeKey`).

   This is the ONLY place brand primitives are defined. Everything
   else (semantic aliases, components) consumes them via var() in
   tokens-base.css / company-ui.css, so a theme only has to redeclare
   the primitives below — exactly like a light/dark mode swap.

   Rules:
   - Add a new client theme by copying a full block and changing the
     values, scoped to [data-theme="<client-key>"].
   - Keep every primitive key present in every theme block.
   - Do NOT add semantic aliases or component styles here.
   ============================================================ */

/* CL Energy house theme — the product default until a tenant gets its own
   [data-theme="<client-key>"] block. :root covers missing data-theme.
   default / beebeeone are aliases so older keys still resolve.

   Replace the primitive values here when the CL Energy design lands.
   Components read semantic aliases only, so editing this block reskins
   the whole UI. */
:root,
[data-theme="cl-energy"],
[data-theme="default"],
[data-theme="beebeeone"] {
  /* Core brand colors */
  --bb-blue: #18426e;
  --bb-yellow: #fddd01;
  --bb-black: #090a09;
  --bb-accent: #2563eb;
  --bb-white: #ffffff;

  /* Brand tonal scale */
  --bb-lightblue: #99c6d9;
  --bb-lightblue-50: #ccdeec;
  --bb-lightblue-25: #e5eef6;
  --bb-paper: #f6f5f1;

  /* Ink neutrals */
  --bb-ink-80: #2f3a47;
  --bb-ink-60: #5a6775;
  --bb-ink-40: #8b95a0;
  --bb-ink-20: #c9cfd5;
  --bb-ink-10: #e6e9ec;

  /* Functional heat hue, taken from the brand's own icon set (assets/icons/*.svg use #e8704a
     for flame/heat) — the corporate palette carries no warm colour, and the prototype needs one
     for gas/boiler/discharge data series. Chrome never uses it. Ink that stays legible on a
     yellow fill, for the same reason. Previously cl-v2-only; the prototype uses both. */
  --bb-heat: #e8704a;
  --bb-yellow-ink: #6f5e00;
}

/* Frosted language — icy palette so the picker swap is obvious vs cl-energy.
   Surfaces/blur live on [data-visual="glass"] in tokens-base.css. */
[data-theme="glass"] {
  --bb-blue: #0e7490;
  --bb-yellow: #a5f3fc;
  --bb-black: #0c1222;
  --bb-accent: #22d3ee;
  --bb-white: #f8fbff;

  --bb-lightblue: #67e8f9;
  --bb-lightblue-50: #a5f3fc;
  --bb-lightblue-25: #ecfeff;
  --bb-paper: #e0f2fe;

  --bb-ink-80: #155e75;
  --bb-ink-60: #0e7490;
  --bb-ink-40: #67a8b8;
  --bb-ink-20: #bae6fd;
  --bb-ink-10: #e0f2fe;
}

/* Warm contrast to both house navy and glass cyan — espresso chrome, gold
   highlight, terracotta accent. Stays on elevated material (solid cards). */
[data-theme="ember"] {
  --bb-blue: #4a2519;
  --bb-yellow: #f5b942;
  --bb-black: #1a100c;
  --bb-accent: #e85d4c;
  --bb-white: #fffaf5;

  --bb-lightblue: #e8b48a;
  --bb-lightblue-50: #f3d4b8;
  --bb-lightblue-25: #faf0e4;
  --bb-paper: #f7efe6;

  --bb-ink-80: #5c3d32;
  --bb-ink-60: #8a6558;
  --bb-ink-40: #b08a7c;
  --bb-ink-20: #e4cfc6;
  --bb-ink-10: #f3e6df;
}

/* cl-v2 — elevated, flat white cards, no gradients (per the source HTML demo's own
   "no gradients, no neons" rule). Shares the house palette; adds a heat/cost
   data-series hue and a legible ink for text on yellow fills — both cl-v2-only,
   not promoted to the shared base, so cl-energy/glass/ember are unaffected. */
[data-theme="cl-v2"] {
  --bb-blue: #18426e;
  --bb-yellow: #fddd01;
  --bb-black: #090a09;
  --bb-accent: #2563eb;
  --bb-white: #ffffff;

  --bb-lightblue: #99c6d9;
  --bb-lightblue-50: #ccdeec;
  --bb-lightblue-25: #e5eef6;
  --bb-paper: #f6f5f1;

  --bb-ink-80: #2f3a47;
  --bb-ink-60: #5a6775;
  --bb-ink-40: #8b95a0;
  --bb-ink-20: #c9cfd5;
  --bb-ink-10: #e6e9ec;

  /* cl-v2 only */
  --bb-heat: #e8704a;
  --bb-yellow-ink: #6f5e00;
}
