/* ==========================================================================
   ElevatteLife — 01. Design Tokens
   Single source of truth for colour, type, space, radius and elevation.
   Every other stylesheet consumes these variables only.
   ========================================================================== */

:root {
  /* ---------------------------------------------------------------------
     Raw palette — Green (primary, dominant brand colour)
     --------------------------------------------------------------------- */
  --p-green-950: #031C10;
  --p-green-900: #0B3D28;
  --p-green-800: #176242;
  --p-green-700: #24895F;
  --p-green-600: #32B27C;
  --p-green-500: #41DD9C;
  --p-green-100: #AFFDD4;

  /* Raw palette — Secondary green (cooler, brighter accents) */
  --s-green-950: #032818;
  --s-green-900: #0A4B30;
  --s-green-800: #14714A;
  --s-green-700: #1F9966;
  --s-green-600: #2AC483;
  --s-green-500: #36F0A2;
  --s-green-100: #C2FEDC;

  /* Raw palette — Orange (controlled accent only) */
  --orange-50: #FDECE7;
  --orange-200: #F8B9A2;
  --orange-500: #F1833E;
  --orange-700: #BB642E;
  --orange-800: #87471E;
  --orange-900: #572B10;
  --orange-950: #2B1304;

  /* Raw palette — Yellow (controlled accent only) */
  --yellow-50: #FFEED9;
  --yellow-500: #FCC013;
  --yellow-600: #CC9B0D;
  --yellow-700: #9E7708;
  --yellow-800: #725504;
  --yellow-900: #493601;
  --yellow-950: #241900;

  /* Raw palette — Neutral */
  --neutral-100: #E9EEEB;
  --neutral-300: #BEC7C1;
  --neutral-400: #98A09B;
  --neutral-500: #757B77;
  --neutral-600: #535754;
  --neutral-700: #333634;
  --neutral-900: #161817;

  /* ---------------------------------------------------------------------
     Semantic — brand & surface
     --------------------------------------------------------------------- */
  --brand: var(--p-green-900);          /* #0B3D28 — primary brand */
  --brand-deep: var(--p-green-950);     /* #031C10 — near-black green, small anchors only */
  --brand-mid: #0E7C40;                 /* brand middle tone */
  --brand-soft: var(--p-green-600);
  --brand-tint: var(--bg-tint);         /* light green wash — supporting brand layer */
  --brand-tint-strong: #CFE6D8;         /* deeper green wash for stronger accents */

  --accent: var(--orange-500);          /* #F1833E */
  --accent-soft: var(--orange-50);
  --accent-deep: var(--orange-800);
  --gold: var(--yellow-500);            /* #FCC013 — highlights only */
  --gold-soft: var(--yellow-50);

  --bg: #E7F2EA;                        /* fresh botanical green — the page's default surface, the brand's visual atmosphere */
  --bg-warm: #F1F7F2;                   /* very light green accent band — beige retired */
  --bg-tint: #DCEDE2;                   /* supporting green — deeper alternating band */
  --bg-tint-strong: hsl(143, 68%, 4%);            /* deeper green wash */
  --bg-sand: var(--bg-warm);            /* legacy alias — beige retired, green band now */
  --surface: #FFFFFF;
  --surface-alt: var(--bg-tint);
  --surface-deep: var(--brand);         /* #0B3D28 — dark green sections (CTA), not near-black */
  --surface-glass: rgba(255, 255, 255, 0.72);

  /* ---------------------------------------------------------------------
     Semantic — text & lines
     --------------------------------------------------------------------- */
  --ink: var(--neutral-900);            /* #161817 */
  --ink-2: var(--neutral-700);
  --ink-muted: var(--neutral-600);
  --ink-faint: var(--neutral-500);
  --ink-invert: #FFFFFF;
  --ink-invert-soft: rgba(255, 255, 255, 0.74);

  --line: var(--neutral-100);
  --line-mid: var(--neutral-300);
  --line-invert: rgba(255, 255, 255, 0.16);
  --line-brand: rgba(11, 61, 40, 0.12);

  /* ---------------------------------------------------------------------
     Typography
     --------------------------------------------------------------------- */
  --font-display: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;

  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  --lh-tight: 1.06;
  --lh-snug: 1.18;
  --lh-heading: 1.25;
  --lh-body: 1.7;

  /* Fluid type scale */
  --fs-display: clamp(2.5rem, 1.35rem + 4.6vw, 4.5rem);
  --fs-h1: clamp(2.125rem, 1.35rem + 2.9vw, 3.375rem);
  --fs-h2: clamp(1.65rem, 1.2rem + 1.8vw, 2.5rem);
  --fs-h3: clamp(1.25rem, 1.08rem + 0.65vw, 1.5rem);
  --fs-h4: clamp(1.0625rem, 1rem + 0.28vw, 1.1875rem);
  --fs-lead: clamp(1.0625rem, 1rem + 0.34vw, 1.25rem);
  --fs-body: 1rem;
  --fs-sm: 0.9375rem;
  --fs-caption: 0.8125rem;
  --fs-eyebrow: 0.75rem;

  --tr-tight: -0.02em;
  --tr-display: -0.025em;
  --tr-caps: 0.14em;

  /* ---------------------------------------------------------------------
     Spacing scale (8pt base, fluid section rhythm)
     --------------------------------------------------------------------- */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  --section-y: clamp(3.75rem, 2rem + 6vw, 7.5rem);
  --section-y-sm: clamp(2.75rem, 1.6rem + 4vw, 5rem);
  --stack-sm: var(--space-4);
  --stack: var(--space-6);
  --stack-lg: var(--space-10);

  /* Layout widths */
  --container: 1200px;
  --container-wide: 1320px;
  --container-narrow: 760px;
  --container-text: 62ch;
  --gutter: clamp(1.25rem, 0.65rem + 2.6vw, 2.5rem);

  /* ---------------------------------------------------------------------
     Radius — subtle and premium, never pill-shaped by default
     --------------------------------------------------------------------- */
  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;
  --r-media: 18px;         /* image frames */

  /* ---------------------------------------------------------------------
     Elevation — soft, low-contrast, layered
     --------------------------------------------------------------------- */
  --shadow-xs: 0 1px 2px rgba(3, 28, 16, 0.05);
  --shadow-sm: 0 1px 2px rgba(3, 28, 16, 0.05), 0 2px 8px rgba(3, 28, 16, 0.05);
  --shadow-md: 0 2px 4px rgba(3, 28, 16, 0.04), 0 10px 26px -12px rgba(3, 28, 16, 0.18);
  --shadow-lg: 0 4px 10px rgba(3, 28, 16, 0.05), 0 28px 56px -24px rgba(3, 28, 16, 0.24);
  --shadow-focus: 0 0 0 3px rgba(14, 124, 64, 0.28);
  --shadow-focus-invert: 0 0 0 3px rgba(175, 253, 212, 0.42);

  /* ---------------------------------------------------------------------
     Motion
     --------------------------------------------------------------------- */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 160ms;
  --dur: 260ms;
  --dur-slow: 520ms;

  /* ---------------------------------------------------------------------
     Control sizing — buttons stay proportional, never giant blocks
     --------------------------------------------------------------------- */
  --control-h: 48px;
  --control-h-sm: 42px;
  --control-px: 1.375rem;

  /* Layering */
  --z-base: 1;
  --z-sticky: 100;
  --z-nav: 200;
  --z-drawer: 300;
  --z-overlay: 290;
}

/* Respect users who prefer reduced motion at the token level too. */
@media (prefers-reduced-motion: reduce) {
  :root {
    --dur-fast: 1ms;
    --dur: 1ms;
    --dur-slow: 1ms;
  }
}
