/* AAPL Equity Research Dashboard, per-dashboard theme (color/font tokens).
   Loaded AFTER /assets/css/01..07. Edit AAPL's palette and typeface here only.
   Three brand-color tokens drive every hero/header/hover/highlight in the shared engine:
     --accent          primary brand color (used everywhere)
     --accent-deep     darker shade, hero gradient end stop, hover states
     --accent-bright   editorial highlight, ticker callouts, byline strong, eyebrows */
:root{
  color-scheme:light;
  /* Neutral canvas, Apple's own light design-system greys (F5F5F7 / 1D1D1F / 6E6E73). */
  --bg:#F5F5F7;
  --panel:#FFFFFF;
  --ink:#1D1D1F;
  --muted:#6E6E73;
  --line:#E3E3E6;
  --chip:#ECECEF;

  /* Brand accents, Apple keyline blue (#0071E3) preserved */
  --accent:#0071E3;
  --accent-soft:#D6E7FA;
  --accent-deep:#0058B9;
  --accent-bright:#c98a2b;

  /* Status colors */
  --green:#1f8a4c;  --green-soft:#D8ECDF;
  --red:#c0362c;    --red-soft:#F3D9D5;
  --amber:#b8730f;  --amber-soft:#F2E2C4;
  --blue:#0071E3;   --teal:#2c8f86;

  --font-serif:"Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  --font-sans:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;

  /* Chart palette, read by assets/js/charts-core.js#getChartPalette() and
     spread into the dashboard.js `colors` map. Namespacing under --chart-*
     keeps chart roles (primary/secondary/warm/cool/positive/negative/neutral)
     decoupled from semantic body tokens (--accent, --green, --red). Apple-flavoured
     professional palette: keyline blue primary + a muted indigo secondary. */
  --chart-primary:#0071E3;
  --chart-secondary:#5b52b5;
  --chart-warm:#b8730f;
  --chart-cool:#2c8f86;
  --chart-positive:#1f8a4c;
  --chart-negative:#c0362c;
  --chart-neutral:#6E6E73;
  --chart-fill-alpha:0.12;
}
/* AAPL dark-mode tokens, override shared 05-dark-mode-and-modes.css to keep
   the Apple "space black" palette internally consistent (cool near-black, not
   MU's warm charcoal). */
body.dark{
  --bg:#0A0A0C;
  --panel:#161618;
  --ink:#F5F5F7;
  --muted:#98989D;
  --line:#2A2A2E;
  --chip:#242428;

  --accent:#2E9BFF;
  --accent-soft:#16283A;
  --accent-deep:#0058B9;
  --accent-bright:#e6b455;

  --green:#4CC978;   --green-soft:#12291B;
  --red:#F0665C;     --red-soft:#3A1E1B;
  --amber:#E0A040;   --amber-soft:#3A2C12;
  --blue:#4AA3FF;    --teal:#4FB6AC;

  /* Chart palette, dark-mode shifts. Tracks the role tokens redefined above;
     --chart-fill-alpha bumps to 0.18 because the 12% under-area fill washes out
     against the near-black canvas. */
  --chart-primary:#4AA3FF;
  --chart-secondary:#8B82E8;
  --chart-warm:#E0A040;
  --chart-cool:#4FB6AC;
  --chart-positive:#4CC978;
  --chart-negative:#F0665C;
  --chart-neutral:#98989D;
  --chart-fill-alpha:0.18;
}
/* Pin sticky header and footer flush with the page --bg so AAPL's dark mode reads
   seamless with the space-black chrome (06 defaults header.top to #16130E and
   footer.site-footer to #100D08; this keeps both flush with AAPL's --bg). */
body.dark header.top { background: #0A0A0C !important; }
body.dark footer.site-footer { background: #0A0A0C; }

/* AA contrast: the Apple keyline blue (#0071E3) is only ~4.3:1 on the #F5F5F7
   calc-card background, so accent-coloured small text/badges that sit on --bg
   (the calc titles and slider value-badges) use a deeper blue in light mode
   (~6.1:1 on #F5F5F7). Dark mode keeps the bright accent (fine on near-black). */
:root { --accent-on-surface: #0058B9; }
body.dark { --accent-on-surface: #2E9BFF; }
.calc h4, .calc-row .val-badge { color: var(--accent-on-surface); }
