/* Charts — data-visualisation tokens. Consumed by ECharts via tokens/echarts-theme.js
   and by the reference renderer in guidelines/chart-kit.js. */
:root, [data-theme="light"] {
  /* Categorical — assign in this order; never skip or reorder between charts */
  --chart-1: #3580BB; --chart-2: #f76707; --chart-3: #2fb344; --chart-4: #ae3ec9;
  --chart-5: #17a2b8; --chart-6: #f59f00; --chart-7: #d6336c; --chart-8: #4263eb;
  --chart-other: #c0c7cf;            /* "Other", de-emphasised, no-data */

  /* Sequential (low → high), single hue from --primary */
  --chart-seq-1: #e3eef7; --chart-seq-2: #b3d0e8; --chart-seq-3: #7aacd4; --chart-seq-4: #3580BB; --chart-seq-5: #1f5683;

  /* Diverging (negative ← mid → positive) */
  --chart-div-neg-2: #d63939; --chart-div-neg-1: #ef9a9a; --chart-div-mid: #eef1f4; --chart-div-pos-1: #9cc3e3; --chart-div-pos-2: #3580BB;

  /* Meaning — only when the colour itself carries status */
  --chart-positive: var(--green); --chart-negative: var(--red); --chart-warning: var(--yellow);
  --chart-neutral: var(--text-disabled); --chart-target: var(--text);

  /* Structure */
  --chart-grid: var(--border-color-light); --chart-grid-dash: 4 3; /* @kind other */ --chart-axis: var(--border-color);
  --chart-label: var(--text-muted); --chart-label-size: 10px; --chart-legend-size: 11.5px;
  --chart-title-size: 14px; --chart-stat-size: 24px;

  /* Marks */
  --chart-line-width: 1.5px; --chart-point-r: 3; /* @kind other */
  --chart-area-opacity: .06; /* @kind other */ --chart-area-stacked-opacity: .55; /* @kind other */
  --chart-bar-radius: 3; /* @kind other */ --chart-bar-gap: 2; /* @kind other */ --chart-band-padding: .35; /* @kind other */
  --chart-donut-thickness: .16; /* @kind other */ --chart-slice-gap: 2; /* @kind other */

  /* Tooltip */
  --chart-tooltip-bg: #1a2332; --chart-tooltip-text: #ffffff; --chart-tooltip-muted: #b3bccb;

  /* Heights */
  --chart-height-sm: 120px; --chart-height-md: 200px; --chart-height-lg: 300px; --chart-spark-h: 32px;
}
[data-theme="dark"] {
  --chart-other: #5a6473;
  --chart-seq-1: #1d2d40; --chart-seq-2: #24496b; --chart-seq-3: #2f6a9a; --chart-seq-4: #3f8fd0; --chart-seq-5: #7fbfff;
  --chart-div-neg-1: #8a3a3a; --chart-div-mid: #263244; --chart-div-pos-1: #2f5f8a;
  --chart-grid: rgba(255,255,255,0.06); --chart-axis: rgba(255,255,255,0.12);
  --chart-area-opacity: .14; /* @kind other */ --chart-tooltip-bg: #0b111b;
}
