/* ==========================================================================
   Metalinq brand tokens: the single source of truth for every colour.
   Every page (concepts, Drafts menu, globe canvas, colour guide) reads these.
   Change a value here and it changes everywhere. Never hard-code a colour.

   Each colour is defined exactly once. Transparent variants are derived from it:
     color-mix(in srgb, var(--ink) 6%, transparent)   instead of   rgba(17,17,19,.06)

   After changing a base colour, re-run the checks in Mock/tools/README.md
   (contrast, colour-blind separation, print). Measured values in the guide
   (Pantone ΔE, CMYK) are dated and must be re-measured.
   ========================================================================== */
:root{
  /* Core */
  --red:#D52B1E;      /* Metalinq Red · Pantone 485 C */
  --ink:#111113;       /* text, primary buttons, Night background */
  --ink-2:#3A3A3F;     /* body copy */
  --mute:#6E6E73;   /* labels, captions, sources */
  --line:#E2E2DE;   /* hairlines, dividers */
  --paper:#F5F5F3;  /* page background */
  --white:#FFFFFF;  /* cards, glass */

  /* Supporting light tones */
  --mist:#ECECE9;   /* photo backdrops, placeholders */
  --soft:#76767C;                                   /* second line of large headlines */
  --unlit:#C9C9CC;                                  /* statement words before they light up */

  /* Dark section (Insights) */
  --night:var(--ink);
  --night-card:#1C1C1F;
  --night-line:#2A2A2E;
  --night-text:#B8B8BD;
  --night-mute:#9A9AA0;

  /* Effects */
  --glow:#FF6046;                                   /* alpenglow: light only, never a fill */
  --glass:color-mix(in srgb, var(--white) 62%, transparent);
  --glass-line:color-mix(in srgb, var(--white) 85%, transparent);

  /* Mock only: dashed underline on details the client still has to supply */
  --tbc:#B9B9BD;

  /* Semantic: one family per state. Identity tone is identical in both modes. */
  --success:#359B49;  --success-text:#057E2D;  --success-bg:#E4F6E5;  --success-border:#A8D5AB;
  --warning:#FEAA1F;  --warning-text:#976207;  --warning-bg:#FFF1E1;  --warning-border:#FEC57E;
  --info:#517FFE;     --info-text:#3962DF;     --info-bg:#EAF0FE;     --info-border:#B1C7F9;
  --danger:#E4536B;   --danger-text:#A40838;   --danger-bg:#FFEBEC;   --danger-border:#F4B4B9;
  --on-semantic:var(--ink);                         /* badge text on every identity tone */

  /* Chart series: fixed order, never cycled */
  --series-1:#3D6FA8; /* Steel */
  --series-2:#C2662B; /* Copper */
  --series-3:#008A7C; /* Patina */
  --series-4:#A98112; /* Brass */
  --series-5:#8E5BA8; /* Anodized */
  --series-6:#5E8F3A; /* Moss */

  /* Magnitude ramp: one hue, light to dark */
  --ramp-1:#93B0D6; --ramp-2:#6E93C3; --ramp-3:#4B73AA; --ramp-4:#335A8F; --ramp-5:#223F68;
}

/* Dark mode: semantic identity tones stay; only text and tints change */
[data-theme="dark"]{
  --success-text:var(--success); --success-bg:#0E2411; --success-border:#27532D;
  --warning-text:var(--warning); --warning-bg:#301D02; --warning-border:#744C0E;
  --info-text:var(--info);       --info-bg:#141D33;    --info-border:#334673;
  --danger-text:var(--danger);   --danger-bg:#301418;  --danger-border:#6C343A;
}
