/* Design tokens, fluid typography, and base resets */

:root {
  /* Color */
  --color-charcoal: #000000;
  --color-charcoal-92: rgba(0, 0, 0, 0.92);
  --color-charcoal-80: rgba(0, 0, 0, 0.80);
  --color-charcoal-60: rgba(0, 0, 0, 0.60);
  --color-text: #444444;
  --color-text-muted: #6b6b6b;
  --color-surface: #ffffff;
  --color-surface-alt: #f7f7f7;
  --color-border: #e4e4e4;
  --color-brand-red: #e9352e;
  --color-brand-red-hover: #c5251f;

  /* Fluid typography — smooth scale across breakpoints */
  --fs-xxl: clamp(2.5rem, 1.6rem + 4.2vw, 5.25rem);   /* hero headline */
  --fs-xl:  clamp(1.75rem, 1.2rem + 2.4vw, 3rem);     /* section heads */
  --fs-lg:  clamp(1.25rem, 1rem + 1vw, 1.625rem);     /* subheads */
  --fs-md:  clamp(1rem, 0.95rem + 0.3vw, 1.125rem);   /* body */
  --fs-sm:  clamp(0.875rem, 0.85rem + 0.15vw, 1rem);  /* secondary */
  --fs-xs:  clamp(0.75rem, 0.72rem + 0.15vw, 0.875rem); /* legal/labels */

  /* Spacing scale */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4rem;
  --sp-9: 6rem;

  /* Layout */
  --container-max: 1400px;
  --container-pad: clamp(1.25rem, 4vw, 3rem);

  /* Motion */
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --dur-fast: 160ms;
  --dur-med: 280ms;
  --dur-slow: 480ms;

  /* Radius + shadow */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.06), 0 2px 6px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 10px rgba(0, 0, 0, 0.06), 0 12px 28px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 10px 24px rgba(0, 0, 0, 0.10), 0 24px 48px rgba(0, 0, 0, 0.12);
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html {
  /* Near-zero readability nudge — practically the browser default. */
  font-size: 100.5%;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

/* The HTML `hidden` attribute must always win — author class display rules
   (e.g. .btn { display: inline-flex }) tie on specificity and would otherwise
   override the UA `[hidden] { display: none }` default. */
[hidden] { display: none !important; }
body {
  font-family: 'Lato', 'Raleway', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-weight: 400;
  font-size: var(--fs-md);
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-surface);
  overflow-x: hidden; /* PRD 6.7 — no horizontal scroll */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg, video { max-width: 100%; height: auto; display: block; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input, select, textarea { font: inherit; color: inherit; }
a { color: var(--color-brand-red); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Typography */
h1, h2, h3, h4 {
  font-family: 'Montserrat', system-ui, sans-serif;
  font-weight: 700;
  color: var(--color-charcoal);
  line-height: 1.15;
  margin: 0 0 var(--sp-4);
  letter-spacing: -0.01em;
}
h1 { font-size: var(--fs-xxl); letter-spacing: -0.02em; }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); }
p  { margin: 0 0 var(--sp-4); }

/* Playfair Display ONLY for ampersands (per brand) */
.amp {
  font-family: 'Playfair Display', 'Source Serif 4', Georgia, serif;
  font-weight: 400;
  font-style: italic;
}

/* Focus — visible for keyboard, subtle for mouse */
:focus-visible {
  outline: 2px solid var(--color-brand-red);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* Utility */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
