/* ==========================================================================
   Gesuntech design tokens — v1.0
   Source of truth for colour, type, spacing, radius, shadow and motion.
   Import this file first; never hard-code these values elsewhere.
   ========================================================================== */

/* Fonts are loaded from fonts.css (embedded, self-hosted). */

:root {
  /* ---------- Brand palette (from the brand board) ---------- */
  --gt-deep-teal:   #0E3F3A;  /* Primary. Logo, nav, primary buttons, headings */
  --gt-teal-mist:   #4E9E8E;  /* Secondary. Highlights, graphs, focus rings — NOT for text on light */
  --gt-soft-green:  #D5E7D2;  /* Light surfaces, secondary buttons, subtle emphasis */
  --gt-warm-white:  #F8F9F5;  /* Page background */
  --gt-charcoal:    #1B2B2A;  /* Body text */
  --gt-sand:        #E6DCC6;  /* Warm neutral: cards, tags, badges */
  --gt-clay:        #D97E6B;  /* Accent. Alerts, rare highlights, illustration — NOT for text on light */

  /* ---------- Logo-only colours (sampled from the emblem) ---------- */
  --gt-logo-leaf:   #A9CB94;
  --gt-logo-overlap:#7FAF76;

  /* ---------- Supporting shades (added for accessibility & UI states) ---------- */
  --gt-teal-mist-ink: #2F7A6C; /* Text-safe Teal Mist: 4.8:1 on Warm White */
  --gt-clay-ink:      #B4533F; /* Text-safe Clay: 4.7:1 on Warm White (error text) */
  --gt-deep-teal-hover:#0A302C; /* Primary button hover */
  --gt-muted:         #45524F; /* Secondary text: 7.7:1 on Warm White */
  --gt-subtle:        #5F6B68; /* Captions/meta, min 14px: 5.2:1 */
  --gt-line:          #DDE3DA; /* Hairlines, dividers, input borders (decorative) */
  --gt-line-strong:   #9AA5A1; /* Input borders that must be seen */
  --gt-surface:       #FFFFFF; /* Raised cards on Warm White */

  /* ---------- Semantic roles (use these in components) ---------- */
  --color-bg:            var(--gt-warm-white);
  --color-surface:       var(--gt-surface);
  --color-surface-soft:  var(--gt-soft-green);
  --color-surface-warm:  var(--gt-sand);
  --color-surface-inverse: var(--gt-deep-teal);
  --color-text:          var(--gt-charcoal);
  --color-text-muted:    var(--gt-muted);
  --color-text-subtle:   var(--gt-subtle);
  --color-heading:       var(--gt-deep-teal);
  --color-text-inverse:  var(--gt-warm-white);
  --color-text-inverse-muted: var(--gt-soft-green);
  --color-link:          var(--gt-deep-teal);
  --color-primary:       var(--gt-deep-teal);
  --color-primary-hover: var(--gt-deep-teal-hover);
  --color-on-primary:    var(--gt-warm-white);
  --color-accent:        var(--gt-teal-mist);
  --color-accent-text:   var(--gt-teal-mist-ink);
  --color-alert:         var(--gt-clay);
  --color-alert-text:    var(--gt-clay-ink);
  --color-border:        var(--gt-line);
  --color-border-strong: var(--gt-line-strong);
  --color-focus:         var(--gt-teal-mist);

  /* ---------- Typography ---------- */
  --font-display: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body:    "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  /* Fluid sizes: min at 375px viewport, max at 1280px */
  --text-display: clamp(2.75rem, 1.6rem + 4.9vw, 4.75rem);  /* 44 → 76px  hero h1 */
  --text-h1:      clamp(2.25rem, 1.6rem + 2.8vw, 3.5rem);   /* 36 → 56px  page titles */
  --text-h2:      clamp(1.875rem, 1.45rem + 1.8vw, 2.75rem);/* 30 → 44px  section titles */
  --text-h3:      clamp(1.375rem, 1.2rem + 0.7vw, 1.75rem); /* 22 → 28px */
  --text-h4:      1.25rem;   /* 20px */
  --text-lead:    1.125rem;  /* 18px intro paragraphs */
  --text-body:    1rem;      /* 16px */
  --text-small:   0.875rem;  /* 14px */
  --text-eyebrow: 0.8125rem; /* 13px, uppercase */

  --leading-tight: 1.04;  /* display */
  --leading-snug:  1.2;   /* h2–h4 */
  --leading-body:  1.6;

  --tracking-display: -0.035em;
  --tracking-heading: -0.02em;
  --tracking-eyebrow:  0.08em;

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

  --measure: 34rem; /* max line length for body copy (~65ch) */

  /* ---------- Spacing (4px base) ---------- */
  --space-1: 0.25rem;  /*  4 */
  --space-2: 0.5rem;   /*  8 */
  --space-3: 0.75rem;  /* 12 */
  --space-4: 1rem;     /* 16 */
  --space-5: 1.5rem;   /* 24 */
  --space-6: 2rem;     /* 32 */
  --space-7: 2.5rem;   /* 40 */
  --space-8: 3rem;     /* 48 */
  --space-9: 4rem;     /* 64 */
  --space-10: 6rem;    /* 96 */
  --space-11: 8rem;    /* 128 */
  --section-y: clamp(4rem, 2.5rem + 6vw, 8rem); /* vertical padding of page sections */

  /* ---------- Layout ---------- */
  --container: 80rem;        /* 1280px */
  --container-narrow: 45rem; /* 720px, for text pages (privacy, articles) */
  --gutter: clamp(1rem, 0.5rem + 2.2vw, 2rem); /* 16 → 32px side padding */

  /* ---------- Radius ---------- */
  --radius-sm: 6px;    /* inputs, small tags */
  --radius-md: 8px;    /* buttons */
  --radius-lg: 16px;   /* cards, images */
  --radius-xl: 24px;   /* large feature panels */
  --radius-pill: 999px;
  --radius-leaf: 999px 12px 999px 12px; /* signature leaf shape — decorative only, sparingly */

  /* ---------- Elevation (soft, teal-tinted; most UI should be flat) ---------- */
  --shadow-sm: 0 1px 2px rgba(14, 63, 58, 0.06);
  --shadow-md: 0 4px 16px -4px rgba(14, 63, 58, 0.10), 0 1px 2px rgba(14, 63, 58, 0.06);
  --shadow-lg: 0 24px 48px -16px rgba(14, 63, 58, 0.18);

  /* ---------- Motion (subtle — the site should feel calm, not busy) ---------- */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --dur-fast: 150ms;  /* hovers, colour changes */
  --dur-base: 250ms;  /* small movements */
  --dur-slow: 600ms;  /* scroll reveals */

  /* ---------- Gradient (optional — hero/marketing only, sparingly) ---------- */
  --gradient-brand: linear-gradient(100deg, #0E3F3A 0%, #4E9E8E 45%, #D5E7D2 80%, #F1EEE4 100%);
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur-fast: 0ms; --dur-base: 0ms; --dur-slow: 0ms; }
}
