/* ============================================================
   theme.css — canonical EAI portal design tokens (light + dark).

   One source of truth for the CSS custom properties that every page used to
   re-declare inline in its own <style> block. Those inline copies had DRIFTED
   (same token, different value across pages), so a color change meant editing
   ~30 files and the pages already disagreed with each other.

   Canonical values below match index.html verbatim (the primary account page),
   plus the admin-only "tint-client/perf" tokens added as purely-additive names.
   A page whose historical value differs for a token keeps a tiny inline override
   during migration so its appearance is UNCHANGED; those stragglers get
   reconciled deliberately in a later pass.

   Usage: <link rel="stylesheet" href="/theme.css" />  (before the page's own
   <style>), then delete that page's inline :root / [data-theme="dark"] block.
   ============================================================ */

:root {
  /* Surfaces & text */
  --bg: #f7f8fa;
  --surface: #ffffff;
  --surface-2: #f0f2f5;
  /* The sweep across a loading skeleton. Must CONTRAST with --surface-2, so it
     darkens in light mode and lightens in dark. The original shimmer used a
     white band unconditionally, which on a #f0f2f5 bar is white-on-white and
     rendered as a completely still, blank box. */
  --shimmer: rgba(20, 22, 29, .09);
  --border: #e3e6eb;
  --border-hover: #cdd2da;
  --text: #14161d;
  --text-dim: #5a616e;
  --text-faint: #9097a3;

  /* Brand */
  --grad: linear-gradient(135deg, #1a9fe0 0%, #16c79a 100%);
  --accent: #0e9ac4;
  --glow1: rgba(26, 159, 224, .08);
  --glow2: rgba(22, 199, 154, .07);

  /* Status badges */
  --badge-neutral-bg: rgba(14, 154, 196, 0.12); --badge-neutral-fg: #0c7ba0;
  --badge-info-bg: rgba(26, 159, 224, 0.12);    --badge-info-fg: #1378ad;
  --badge-success-bg: rgba(22, 199, 154, 0.14); --badge-success-fg: #0e8c6b;
  --badge-danger-bg: rgba(224, 70, 70, 0.12);   --badge-danger-fg: #b53030;
  --badge-muted-bg: rgba(120, 130, 150, 0.12);  --badge-muted-fg: #5a616e;
  --badge-warn-bg: rgba(240, 160, 40, 0.14);    --badge-warn-fg: #b06a10;

  /* Checkmarks / overlays */
  --check-bg: rgba(22, 199, 154, 0.14);         --check-fg: #0e8c6b;
  --overlay: rgba(20, 22, 29, 0.45);

  /* Row/card tints */
  --tint-inquiry: rgba(123, 97, 255, .05); --tint-inquiry-bd: rgba(123, 97, 255, .22); --tint-inquiry-h: #6a5acd;
  /* additive (admin control-center rows) — new names, invisible to pages that don't use them */
  --tint-client: rgba(26, 159, 224, .06);  --tint-client-bd: rgba(26, 159, 224, .24);  --tint-client-h: #1378ad;
  --tint-perf: rgba(240, 140, 40, .08);    --tint-perf-bd: rgba(240, 140, 40, .30);    --tint-perf-h: #b06a10;
}

[data-theme="dark"] {
  /* Surfaces & text */
  --bg: #0a0b0f;
  --surface: #14161d;
  --surface-2: #1b1e27;
  --shimmer: rgba(255, 255, 255, .07);
  --border: #262a36;
  --border-hover: #363b4a;
  --text: #f2f3f7;
  --text-dim: #9aa0ae;
  --text-faint: #646a78;

  /* Brand */
  --grad: linear-gradient(135deg, #3bb6ff 0%, #2ce0a8 100%);
  --accent: #36c6e0;
  --glow1: rgba(59, 182, 255, .10);
  --glow2: rgba(44, 224, 168, .08);

  /* Status badges */
  --badge-neutral-bg: rgba(54, 198, 224, 0.14); --badge-neutral-fg: #6fd6e8;
  --badge-info-bg: rgba(59, 182, 255, 0.14);    --badge-info-fg: #7cc4ff;
  --badge-success-bg: rgba(45, 224, 168, 0.14); --badge-success-fg: #4fe0b0;
  --badge-danger-bg: rgba(240, 90, 90, 0.14);   --badge-danger-fg: #f08a8a;
  --badge-muted-bg: rgba(150, 160, 180, 0.12);  --badge-muted-fg: #9aa0ae;
  --badge-warn-bg: rgba(255, 180, 70, 0.14);    --badge-warn-fg: #f0b860;

  /* Checkmarks / overlays */
  --check-bg: rgba(45, 224, 168, 0.12);         --check-fg: #4fe0b0;
  --overlay: rgba(0, 0, 0, 0.6);

  /* Row/card tints — additive (admin control-center rows) */
  --tint-client: rgba(90, 190, 255, .055); --tint-client-bd: rgba(90, 190, 255, .22); --tint-client-h: #8fcdff;
  --tint-perf: rgba(245, 178, 100, .06);   --tint-perf-bd: rgba(245, 178, 100, .26);  --tint-perf-h: #f3b873;
}
