/* CRASA Digital Anchor Ecosystem — token layer.
 *
 * This file is the single source of truth for colour, type, spacing, radius,
 * elevation and easing. Adjusting it restyles the whole platform. No screen
 * defines its own values, and no screen adds one here without a decision.
 *
 * Colour, type, spacing, radius and easing are reproduced verbatim from
 * CLAUDE.md. The type scale below carries the names and values printed in
 * .design/screens/01-design-foundations.dc.html, section 02.
 */

:root {
  /* Colour */
  --c-green:#1A8C5A; --c-green-dark:#0E5536; --c-green-light:#E8F4EC;
  --c-navy:#0F1B2D; --c-navy-mid:#1A2742; --c-navy-line:#2C3A55;
  --c-charcoal:#1F2937; --c-slate:#5C6B7E;
  --c-cream:#F8F6F1; --c-sand:#E5E0D5;
  --c-amber:#C2710C; --c-white:#FFFFFF;
  --c-red:#9B2226; --c-red-light:#FBEDED;

  /* CRASA blue, the navy of the crasa.org buttons (Learn More, Extranet,
     Contact), sampled from that site's stylesheet on 29 October 2026
     (.button background, --primary-1). The secondary colour of the
     platform: primary buttons and the current sidebar item in the member
     area and the back office, the public footer and closing bands, event
     date blocks, the second series of a chart. Green stays the public
     identity colour. Pairs measured in docs/accessibility/contrast-crasa-blue.md:
     white on it 13.94, it on white 13.94. */
  --c-crasa-blue:#052D53;

  /* Neutrals. Borders and disabled text on light surfaces, and the
     pressed and border tones used on navy surfaces. */
  /* --c-border and --c-border-input both had to reach 3:1 against white for
     SC 1.4.11, and both land on the same value, so they were never two
     tokens. One border neutral now, set against cream rather than white:
     cream is the darker of the two public grounds a control sits on. The
     back office ground, --c-admin-bg, is darker again: #958E7E reached only
     2.93:1 there, so the value is darkened once more to #908977, which
     clears 3:1 on all three (white 3.48, cream 3.22, admin ground 3.14). --c-navy-edge is lightened to clear 3:1
     against navy. See the disclosed variation in docs/OPEN_ITEMS.md. */
  --c-border:#908977; --c-disabled:#6E7A85;
  --c-navy-deep:#050D18; --c-navy-edge:#5A6680; --c-navy-soft:#6B7691;

  /* Notice tints. Ground, rule and text for the amber, green and red
     notices. They carry the same meanings as the status colours above:
     amber pending, green validated, red error. */
  --c-amber-light:#FDF0DC; --c-amber-mid:#E5BE87; --c-amber-dark:#5C3404;
  --c-green-mid:#B6DCC5;
  --c-red-mid:#E3B7B8; --c-red-dark:#6E1A1D;

  /* Newsroom type badges: public consultation (purple) and communique (grey). */
  --c-purple-light:#EFEAF7; --c-purple-dark:#45306E; --c-grey-light:#ECEEF1;

  /* Choropleth steps. RegionMap.dc.html:
       SHADES = ["#E8F4EC", "#9CCFB2", "#4FA97B", "#0E5536"]
     One hue in four steps, the ends of which are --c-green-light and
     --c-green-dark. The two middles are new tokens because the screen
     draws them and nothing else on the platform did.

     --c-hatch is the second tone of the "not reported" hatch, from the
     same screen: repeating-linear-gradient(135deg,#E5E0D5 0 4px,#CFC8B8
     4px 8px). A missing figure has to be visibly a different kind of
     thing from a low one, not merely a paler one. */
  --c-green-step-1:#9CCFB2; --c-green-step-2:#4FA97B; --c-hatch:#CFC8B8;

  /* Administration surfaces. Both values are drawn in screen 09:
     --c-admin-bg is the page ground behind the back office, --c-line the
     rule between panels, table rows and header. --c-line is a decorative
     boundary, not the boundary of a control, so SC 1.4.11 does not apply
     to it; controls inside the back office take --c-border, which is
     measured. The input border screen 09 draws, #B9B2A2, reaches only
     2.11:1 on white and is not used for that reason. */
  --c-admin-bg:#F4F3F0; --c-line:#DFDBD1;

  /* Dark surface set. Screen 09: "the same tokens with a different set of
     surface and ink values, not a second design". The green is raised so
     it clears AA against the dark surface, which is the screen's own
     wording and its own value. */
  --d-bg:#0B1220; --d-surface:#141E30; --d-line:#26334A;
  --d-ink:#E8EDF4; --d-ink-dim:#9DAABF; --d-green:#2FA76F; --d-current:#1D3A2B;

  /* Typeface roles. Lora for public headings, IBM Plex Sans for body,
     Inter for administration and dense data. */
  --f-head:'Lora',Georgia,'Times New Roman',serif;
  --f-body:'IBM Plex Sans',system-ui,sans-serif;
  --f-admin:'Inter',system-ui,sans-serif;

  /* Spacing, 4px base */
  --s-1:4px; --s-2:8px; --s-3:12px; --s-4:16px; --s-5:24px;
  --s-6:32px; --s-7:48px; --s-8:64px; --s-9:96px; --s-10:128px;

  /* Radius. These carry meaning: xs on inputs and table cells, sm on buttons,
     md on panels and cards, lg on modals, pill on status badges only.

     The foundations summary reads "lg on cards and modals". The drawings do
     not: screen 01 line 754 sets the news, publication and event cards to
     --r-md and gives --r-lg only to the modal at line 745, and screen 02
     uses --r-lg nowhere at all across 125 radius declarations. The screens
     govern, so cards are --r-md and --r-lg is the modal radius. Nothing on
     the public site is a modal, so --r-lg currently has no users here. */
  --r-xs:2px; --r-sm:4px; --r-md:8px; --r-lg:14px; --r-pill:999px;

  /* Elevation. Three levels, used to encode hierarchy, not to decorate. */
  --e-1:0 1px 2px rgba(15,27,45,.06), 0 1px 3px rgba(15,27,45,.08);
  --e-2:0 2px 4px rgba(15,27,45,.06), 0 6px 16px rgba(15,27,45,.08);
  --e-3:0 12px 32px rgba(15,27,45,.16);

  /* Easing */
  --ease-in:cubic-bezier(.2,.8,.2,1);
  --ease-out:cubic-bezier(.4,0,1,1);

  /* Type scale, from design foundations section 02.
     Each token pairs a size with the line height and weight it is set at. */
  --t-display-size:64px;  --t-display-line:1.05; --t-display-weight:600;
  --t-h1-size:44px;       --t-h1-line:1.12;      --t-h1-weight:600;
  --t-h2-size:34px;       --t-h2-line:1.2;       --t-h2-weight:600;
  --t-h3-size:24px;       --t-h3-line:1.3;       --t-h3-weight:600;
  --t-lead-size:21px;     --t-lead-line:1.55;    --t-lead-weight:400;
  --t-body-size:17px;     --t-body-line:1.65;    --t-body-weight:400;
  --t-small-size:15px;    --t-small-line:1.55;   --t-small-weight:400;
  --t-eyebrow-size:13px;  --t-eyebrow-line:1.3;  --t-eyebrow-weight:600;

  /* Layout. Section rhythm is 96px on desktop and 48px on mobile;
     the extranet and back office step down one level throughout. */
  --w-page:1440px;
  --w-reading:1240px;
  --section-y:var(--s-9);
  --page-x:var(--s-7);
}

@media (max-width: 767px) {
  :root {
    --t-display-size:40px; --t-display-line:1.1;
    --t-h1-size:32px;
    --t-h2-size:26px;
    --section-y:var(--s-7);
    --page-x:var(--s-4);
  }
}
