/* ==========================================================================
   DESIGN TOKENS
   ========================================================================== */

:root {
  /* Palette — client-specified, exact hex values used throughout */
  --navy-900: #0B2545;
  --navy-800: #10263F;
  --navy-700: #163157;
  --navy-600: #1D3F6E;

  --blue-300: #A9CBE8;
  --blue-400: #8FBADD;
  --blue-500: #6FA8D8;

  --gold-500: #C9A227;
  --gold-400: #D4AF5A;
  --gold-300: #E3C77E;

  --white: #FFFFFF;
  --off-white: #FAFAF8;

  --silver-300: #C7CDD3;
  --silver-400: #B0B7BD;
  --silver-600: #899198;

  --ink: #1A2230;

  /* Semantic aliases */
  --color-bg: var(--white);
  --color-bg-alt: var(--off-white);
  --color-text: var(--ink);
  /*
    The client's silver swatch (#B0B7BD–#C7CDD3) is used verbatim for
    borders and hairline dividers below, where contrast rules don't apply.
    For actual muted *text* on white/off-white, that swatch tops out at
    ~3.2:1 against white — under the WCAG AA 4.5:1 minimum for body copy.
    This is a darker, same-family cool gray used only for text, so
    secondary copy stays legible without touching the brand palette.
  */
  --color-text-muted: #63696F;
  --color-border: var(--silver-300);
  --color-primary: var(--navy-900);
  --color-accent: var(--gold-500);
  /*
    Gold reads at only ~2.4:1 on white/off-white — well under both the
    4.5:1 (text) and 3:1 (UI/focus) AA minimums, so it's reserved for use
    on the navy background (7.4:1+) and for purely decorative accents
    (dividers, underlines) where contrast rules don't apply. Text and
    focus outlines on light backgrounds use navy instead — see .eyebrow
    and :focus-visible below.
  */

  /* Typography */
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Spacing scale */
  --space-3xs: 0.25rem;
  --space-2xs: 0.5rem;
  --space-xs: 0.75rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 8rem;

  /* Layout */
  --container-width: 1240px;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;

  /* Motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --duration-fast: 180ms;
  --duration-base: 320ms;
  --duration-slow: 640ms;

  /* Elevation */
  --shadow-sm: 0 1px 2px rgba(11, 37, 69, 0.06), 0 1px 1px rgba(11, 37, 69, 0.04);
  --shadow-md: 0 8px 24px rgba(11, 37, 69, 0.10), 0 2px 8px rgba(11, 37, 69, 0.06);
  --shadow-lg: 0 24px 48px rgba(11, 37, 69, 0.16), 0 8px 16px rgba(11, 37, 69, 0.08);
}

/* ==========================================================================
   RESET
   ========================================================================== */

*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, picture, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

input, button, textarea, select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: none;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
  padding: 0;
}

address {
  font-style: normal;
}

/* ==========================================================================
   TYPOGRAPHY
   ========================================================================== */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  color: var(--navy-900);
  text-wrap: balance;
}

h1 { font-size: clamp(2.5rem, 4.5vw + 1rem, 4.25rem); font-weight: 500; }
h2 { font-size: clamp(1.9rem, 2.8vw + 1rem, 2.75rem); }
h3 { font-size: clamp(1.25rem, 1vw + 1rem, 1.5rem); font-weight: 600; }
h4 { font-size: 1.05rem; font-weight: 600; }

p {
  color: var(--color-text);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs);
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy-700);
  margin-bottom: var(--space-sm);
}

.eyebrow::before {
  content: '';
  width: 28px;
  height: 2px;
  background: var(--gold-500);
  display: inline-block;
}

.eyebrow--light {
  color: var(--blue-300);
}

.eyebrow--light::before {
  background: var(--gold-400);
}

/* ==========================================================================
   LAYOUT UTILITIES
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

@media (min-width: 768px) {
  .container {
    padding-inline: var(--space-lg);
  }
}

.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;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-md);
  background: var(--navy-900);
  color: var(--white);
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--radius-sm);
  z-index: 1000;
  transition: top var(--duration-fast) var(--ease-out);
}

.skip-link:focus {
  top: var(--space-md);
}

/* ==========================================================================
   FOCUS & ACCESSIBILITY
   ========================================================================== */

:focus-visible {
  /*
    Navy is the default focus-ring color because it's the only palette
    color that clears the WCAG 3:1 non-text contrast minimum against
    white, off-white, silver, blue, AND gold — every light background
    this ring can land on. Gold clears 3:1 only against navy, so it's
    used exclusively inside dark sections below.
  */
  outline: 3px solid var(--navy-800);
  outline-offset: 3px;
  border-radius: 2px;
}

.hero :focus-visible,
.trust-bar :focus-visible,
.process :focus-visible,
.site-footer :focus-visible,
.info-card :focus-visible {
  outline-color: var(--gold-400);
}

/* ==========================================================================
   SCROLL-REVEAL (progressive enhancement — see js/main.js)
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   REDUCED MOTION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
