/* Faros platform visual language, shared by the gallery and embedded charts. */
@font-face { font-family: "Waldenburg"; src: url("/assets/fonts/kmrwaldenburg-regular.woff2") format("woff2"); font-style: normal; font-weight: 400; font-display: swap; }
@font-face { font-family: "Waldenburg"; src: url("/assets/fonts/kmrwaldenburg-medium.woff2") format("woff2"); font-style: normal; font-weight: 500 600; font-display: swap; }
@font-face { font-family: "Waldenburg"; src: url("/assets/fonts/kmrwaldenburg-heavy.woff2") format("woff2"); font-style: normal; font-weight: 700 800; font-display: swap; }
@font-face { font-family: "Carbon"; src: url("/assets/fonts/CarbonOT-Bold.otf") format("opentype"); font-style: normal; font-weight: 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/assets/fonts/IBMPlexMono-400.woff2") format("woff2"); font-style: normal; font-weight: 400; font-display: swap; }

:root {
  --faros-font-sans: "Waldenburg", Arial, sans-serif;
  --faros-font-display: "Carbon", "Waldenburg", Arial, sans-serif;
  --faros-font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --faros-radius-control: 6px;
  --faros-radius-panel: 14px;
}

:root, [data-theme="light"] {
  color-scheme: light;
  --faros-background: #f5f5f5;
  --faros-foreground: #0a0a0a;
  --faros-muted: #6b6b6b;
  --faros-border: #e5e5e5;
  --faros-card: #ffffff;
  --faros-subtle: #f5f5f5;
  --faros-hover: #e5e5e5;
  --faros-primary: #e10014;
  --faros-primary-text: #b7091b;
  --faros-focus: #b7091b;
  --faros-positive: #287f3f;
  --faros-negative: #c03807;
  --faros-tooltip-bg: #ffffff;
  --faros-tooltip-ink: #0a0a0a;
  /* Light variants preserve platform hues with >= 3:1 mark contrast. */
  --faros-chart-1: #a62efe;
  --faros-chart-2: #158f95;
  --faros-chart-3: #008ac8;
  --faros-chart-4: #009477;
  --faros-chart-5: #a57b0f;
  --faros-chart-6: #e05151;
  --faros-chart-7: #707fc1;
  --faros-chart-8: #478c90;
  --faros-chart-9: #3e8aac;
  --faros-chart-10: #428f80;
  --faros-chart-11: #aa7750;
  --faros-chart-12: #578e68;
  --faros-chart-13: #828286;
  --faros-chart-14: #625afe;
  --faros-chart-sequential-low: #f0f6fe;
  --faros-chart-sequential-high: #530ef3;
  --faros-chart-diverging-low: #c03807;
  --faros-chart-diverging-mid: #f5f5f5;
  --faros-chart-diverging-high: #287f3f;
}

[data-theme="dark"] {
  color-scheme: dark;
  --faros-background: #171717;
  --faros-foreground: #fafafa;
  --faros-muted: #a3a3a3;
  --faros-border: #404040;
  --faros-card: #262626;
  --faros-subtle: #171717;
  --faros-hover: #333333;
  --faros-primary: #e10014;
  --faros-primary-text: #ff5c5c;
  --faros-focus: #ff5c5c;
  --faros-positive: #57da7e;
  --faros-negative: #f98233;
  --faros-tooltip-bg: #262626;
  --faros-tooltip-ink: #fafafa;
  --faros-chart-1: #a62efe;
  --faros-chart-2: #1ecdd5;
  --faros-chart-3: #00b0ff;
  --faros-chart-4: #00a483;
  --faros-chart-5: #fabb17;
  --faros-chart-6: #ff5c5c;
  --faros-chart-7: #94a7fe;
  --faros-chart-8: #70dfe5;
  --faros-chart-9: #5cccff;
  --faros-chart-10: #5cc8b3;
  --faros-chart-11: #fcb076;
  --faros-chart-12: #91edae;
  --faros-chart-13: #cac9cf;
  --faros-chart-14: #625afe;
  --faros-chart-sequential-low: #262626;
  --faros-chart-sequential-high: #94a7fe;
  --faros-chart-diverging-low: #f98233;
  --faros-chart-diverging-mid: #262626;
  --faros-chart-diverging-high: #57da7e;
}

/* A quiet, shared appearance control with a full-size touch target. */
.header-actions .theme-toggle {
  display: inline-grid;
  place-items: center;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--faros-radius-control);
  background: transparent;
  color: var(--faros-muted);
}
.header-actions .theme-toggle:hover {
  background: var(--faros-hover);
  color: var(--faros-foreground);
}
.theme-toggle svg {
  display: block;
  width: 20px;
  height: 20px;
}
.theme-toggle .theme-icon-dark,
[data-theme="light"] .theme-toggle .theme-icon-light {
  display: none;
}
[data-theme="light"] .theme-toggle .theme-icon-dark {
  display: block;
}
