/* ================================================================
   UMass Amherst — Global Design Tokens, v2.0
   Canonical source: static repo /global/2.0/variables-global.css
   Served from: https://www.umass.edu/static/global/2.0/variables-global.css

   Scope of 2.0: colors, layout, spacing, animation, font family and
   weights.
   Brand colors: https://www.umass.edu/brand/visual-identity/brand-colors

   2.0 is a breaking release over 1.1 (changed values, one removed
   token); see the changelog in /global/readme.md.

   Type sizes, line heights, and other token groups live in each platform's
   variables-local.css until promoted to a future global version. See
   https://www.umass.edu/static/global/readme.md
   for the versioning policy and the sync process for consumers
   (Ecosystem, Drupal Framework, Homepage, Magazine).

   Breaking changes get a new /global/{version}/ folder; platforms
   pin a version and upgrade via ticket. Do not edit vendored copies
   in platform repos directly — change this file first.
   ================================================================ */

:root {
  /* --------------------------------------------------------------
     LAYOUT
     -------------------------------------------------------------- */

  /* Container max width */
  --max-width: 1800px;

  /* Spacing — modular scale, 1rem base, 1.5 ratio */
  --ratio: 1.5;
  --s-5: calc(var(--s-4) / var(--ratio)); /* ~2.11px */
  --s-4: calc(var(--s-3) / var(--ratio)); /* ~3.16px */
  --s-3: calc(var(--s-2) / var(--ratio)); /* ~4.74px */
  --s-2: calc(var(--s-1) / var(--ratio)); /* ~7.11px */
  --s-1: calc(var(--s0) / var(--ratio));  /* ~10.67px */
  --s0: 1rem;                             /* 16px */
  --s1: calc(var(--s0) * var(--ratio));   /* 24px */
  --s2: calc(var(--s1) * var(--ratio));   /* 36px */
  --s3: calc(var(--s2) * var(--ratio));   /* 54px */
  --s4: calc(var(--s3) * var(--ratio));   /* 81px */
  --s5: calc(var(--s4) * var(--ratio));   /* ~121.5px */

  /* Borders */
  --border-thin: 0.15rem;  /* 2.4px */
  --border-thick: 0.5rem;  /* 8px */

  /* --------------------------------------------------------------
     ANIMATION
     -------------------------------------------------------------- */

  /* Transition durations */
  --transition-duration-fast: 0.1s;    /* color/border changes on hover and focus */
  --transition-duration-medium: 0.2s;  /* slide-ins, fades, overlays */
  --transition-duration-default: 0.3s; /* movement: lift, shadow, zoom */
  --transition-duration-slow: 0.5s;    /* expand/collapse of large regions */

  /* Transition easings */
  --transition-easing-default: ease-in-out;

  /* --------------------------------------------------------------
     TYPOGRAPHY
     -------------------------------------------------------------- */

  --font-family-sans: 'Open Sans', Arial, Helvetica, sans-serif;

  --font-weight-light: 300;
  --font-weight-regular: 400;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;

  /* --------------------------------------------------------------
     COLORS — primitives
     -------------------------------------------------------------- */

  /* Brand — all three pass WCAG AA as text on white
     (10.4:1, 14.4:1, 4.6:1) */
  --color-brand: #840028;
  --color-brand-dark: #5a011c;
  --color-brand-light: #e51453;

  /* Neutrals */
  --color-black: #212721;
  --color-white: #fff;

  /* Gray ramp — anchored on the brand neutrals: 300, 700, and 800 are
     brand Light, Medium, and Dark Gray at exact values; the steps
     between are interpolated from them, so the ramp is slightly
     tinted rather than pure neutral. gray-500 is the lightest step that
     passes WCAG AA as text on white (4.5:1). 050 and 150 are CIELAB
     half-steps for light backgrounds and borders. */
  --color-gray-050: #f4f5f5;
  --color-gray-100: #eaecec;
  --color-gray-150: #dde0e0;
  --color-gray-200: #d0d4d5;
  --color-gray-300: #a2aaad; /* brand Light Gray */
  --color-gray-400: #8d9497;
  --color-gray-500: #70787a; /* lightest AA text on white */
  --color-gray-600: #646b6d;
  --color-gray-700: #505759; /* brand Medium Gray */
  --color-gray-800: #373a36; /* brand Dark Gray */

  /* Brand neutral palette — names for the brand grays (same values
     as gray-800/700/300). Dark and medium pass WCAG AA as text on
     white (11.5:1, 7.4:1); light does not (2.4:1) — use it for
     borders and backgrounds, never text. */
  --color-gray-dark: #373a36;
  --color-gray-medium: #505759;
  --color-gray-light: #a2aaad;

  /* UMass gold — NOT in the brand palette. Darkened from #827853 so
     it passes WCAG AA as text on white (4.58:1). */
  --color-umass-gold: #807552;

  /* Secondary colors — brand secondary palette */
  --color-yellow: #ffc72c;
  --color-orange: #ff9e1b;
  --color-purple: #615e9b;
  --color-green-dark: #44693d;
  --color-brown: #5e4b3c;
  --color-blue-dark: #002554;
  --color-blue-bright: #00aec7;
  --color-green-soft: #86c8bc;
  --color-green-leaf: #6ba539;
  --color-green-neon: #c4d600;
  --color-rust: #cb6015;
  --color-red-bright: #fe3b1f;

  /* --------------------------------------------------------------
     COLORS — semantic
     Reconcile platform styles against these where possible;
     reach for primitives only when no semantic token fits.
     -------------------------------------------------------------- */

  --color-text: var(--color-black);
  --color-text-muted: var(--color-gray-medium);
  --color-background: var(--color-white);
  --color-link: var(--color-brand);
  --color-link-hover: var(--color-brand-dark);

  /* Feedback — status, warning, and error messages. Text passes WCAG
     AA on its background; accents are for bars and icons, not text. */
  --color-status-text: #325e1c;
  --color-status-border: #c9e1bd;
  --color-status-background: #f3faef;
  --color-status-accent: #77b259;

  --color-warning-text: #734c00;
  --color-warning-border: #f4daa6;
  --color-warning-background: #fdf8ed;
  --color-warning-accent: #e09600;

  --color-error-text: #a51b00;
  --color-error-border: #f9c9bf;
  --color-error-background: #fcf4f2;
  --color-error-accent: #e62600;
}
