/* ==========================================================================
   Claim Pilot — Design System & Styles
   ========================================================================== */

:root {
  --navy: #0D1B3D;
  --navy-light: #16295c;
  --grey: #F2F5F9;
  --pale-blue: #E8F1FC;
  --white: #FFFFFF;
  --text-body: #2b3245;
  --text-muted: #55607a;
  --border: #dde3ee;
  --success: #1f8a5f;

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;

  --shadow-sm: 0 1px 2px rgba(13, 27, 61, 0.06);
  --shadow-md: 0 8px 24px rgba(13, 27, 61, 0.10);

  --container-width: 1120px;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 40px;
  --space-5: 64px;
  --space-6: 96px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text-body);
  background: var(--white);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; }

h1, h2, h3, h4 { color: var(--navy); line-height: 1.2; margin: 0 0 var(--space-2); }
h1 { font-size: clamp(2rem, 4vw, 2.75rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }
p { margin: 0 0 var(--space-2); color: var(--text-body); }

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

.section { padding: var(--space-5) 0; }
.section--tight { padding: var(--space-4) 0; }
.section--grey { background: var(--grey); }
.section--pale-blue { background: var(--pale-blue); }
.section--navy { background: var(--navy); color: var(--white); }
.section--navy h2, .section--navy h3 { color: var(--white); }
.section--navy p { color: rgba(255,255,255,0.85); }

.eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: var(--space-2);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible {
  outline: 3px solid #7fb2ff;
  outline-offset: 2px;
}
.btn--primary {
  background: var(--white);
  color: var(--navy);
  box-shadow: var(--shadow-sm);
}
.btn--primary:hover { box-shadow: var(--shadow-md); background: var(--white); }
.btn--solid-navy {
  background: var(--navy);
  color: var(--white);
}
.btn--solid-navy:hover { background: var(--navy-light); }
.btn--outline {
  background: transparent;
  border-color: var(--navy);
  color: var(--navy);
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -999px;
  top: auto;
  background: var(--navy);
  color: var(--white);
  padding: 12px 20px;
  z-index: 1000;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
  top: 0;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px var(--space-3);
  max-width: var(--container-width);
  margin: 0 auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--white);
  font-weight: 800;
  font-size: 1.05rem;
}
.brand__mark {
  display: inline-flex;
  width: 34px;
  height: 34px;
  background: var(--white);
  border-radius: 8px;
  align-items: center;
  justify-content: center;
}
.brand__mark svg { width: 22px; height: 22px; }

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.main-nav__links {
  list-style: none;
  display: flex;
  gap: var(--space-3);
  margin: 0;
  padding: 0;
}
.main-nav__links a {
  color: rgba(255,255,255,0.88);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 8px 2px;
  border-bottom: 2px solid transparent;
}
.main-nav__links a:hover,
.main-nav__links a:focus-visible {
  color: var(--white);
  border-bottom-color: rgba(255,255,255,0.6);
}
.main-nav__links a:focus-visible { outline: none; }

/* The Start Claim button lives inside .main-nav__links — its own button
   colours must win over the plain nav-link colour rules above. */
.main-nav__links a.btn--primary,
.main-nav__links a.btn--primary:hover,
.main-nav__links a.btn--primary:focus-visible {
  color: var(--navy);
  border-bottom-color: transparent;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
}
.nav-toggle:focus-visible { outline: 3px solid #7fb2ff; outline-offset: 2px; }
.nav-toggle svg { width: 26px; height: 26px; }

/* Hero */
.hero {
  background: linear-gradient(160deg, var(--navy) 0%, #142449 60%, #1a2f5c 100%);
  color: var(--white);
  padding: var(--space-6) 0 var(--space-5);
}
.hero__grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-4);
  align-items: center;
}
.hero h1 { color: var(--white); margin-bottom: var(--space-2); }
.hero__lede {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.88);
  max-width: 46ch;
}
.hero__points {
  list-style: none;
  padding: 0;
  margin: var(--space-3) 0 var(--space-4);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
}
.hero__points li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--white);
  font-size: 0.95rem;
}
.hero__points svg { width: 18px; height: 18px; flex-shrink: 0; }
.hero__art {
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero__art svg { width: 100%; max-width: 320px; height: auto; opacity: 0.9; }

/* Trust / intro cards */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
}
.card--flat { background: var(--pale-blue); border: none; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--text-muted); margin-bottom: 0; }
.card__icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-2);
}
.card__icon svg { width: 24px; height: 24px; color: var(--white); }

/* Steps */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
  counter-reset: step;
}
.step {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  position: relative;
}
.step__number {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  margin-bottom: var(--space-2);
}
.step h3 { margin-bottom: 6px; }
.step p { color: var(--text-muted); margin-bottom: 0; }

/* Who we help / claim types grids */
.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-3);
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
.tile {
  text-align: center;
  padding: var(--space-3);
}
.tile__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-2);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--pale-blue);
}
.tile__icon svg { width: 28px; height: 28px; color: var(--navy); }
.tile h3 { font-size: 1.05rem; margin-bottom: 6px; }
.tile p { color: var(--text-muted); font-size: 0.92rem; margin-bottom: 0; }

.claim-type {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-3);
}
.claim-type h3 { font-size: 1.05rem; }
.claim-type p { color: var(--text-muted); font-size: 0.92rem; margin-bottom: 0; }

/* Suitability */
.suitability-box {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
}
.suitability-box ul {
  margin: var(--space-2) 0 0;
  padding-left: 1.2em;
}
.suitability-box li { margin-bottom: 8px; color: var(--text-body); }

/* Coming soon banner */
.coming-soon {
  background: var(--pale-blue);
  border: 1px solid #cfe2f7;
  border-radius: var(--radius-lg);
  padding: var(--space-4);
}
.coming-soon__eyebrow {
  display: inline-block;
  background: var(--navy);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: var(--space-2);
}
.coming-soon h3 { margin-bottom: 8px; }
.coming-soon p { color: var(--text-muted); margin-bottom: 0; max-width: 70ch; }

/* Important notice */
.notice {
  background: var(--grey);
  border-left: 4px solid var(--navy);
  border-radius: var(--radius-sm);
  padding: var(--space-4);
}
.notice p:last-child { margin-bottom: 0; }
.notice p { color: var(--text-muted); }

/* FAQ */
.faq { max-width: 780px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid var(--border);
}
.faq-item__question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 20px 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  font-weight: 700;
  font-size: 1rem;
  color: var(--navy);
  cursor: pointer;
}
.faq-item__question:focus-visible {
  outline: 3px solid #7fb2ff;
  outline-offset: -2px;
}
.faq-item__icon {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  transition: transform 0.2s ease;
}
.faq-item[data-open="true"] .faq-item__icon { transform: rotate(180deg); }
.faq-item__answer {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.25s ease;
}
.faq-item__answer p {
  padding: 0 4px 20px;
  color: var(--text-muted);
  margin: 0;
}

/* Footer */
.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.85);
  padding: var(--space-5) 0 var(--space-3);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: var(--space-3);
}
.footer-brand__mark {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 8px;
}
.footer-brand__mark .brand__mark { background: var(--white); }
.footer-tagline { color: rgba(255,255,255,0.65); font-size: 0.9rem; max-width: 28ch; }
.footer-col h4 {
  color: var(--white);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-2);
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  font-size: 0.92rem;
}
.footer-col a:hover, .footer-col a:focus-visible { color: var(--white); text-decoration: underline; }
.footer-note { color: rgba(255,255,255,0.55); font-size: 0.85rem; margin-top: 4px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.12);
  margin-top: var(--space-4);
  padding-top: var(--space-2);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  text-align: center;
}

/* Legal pages */
.legal-hero {
  background: var(--navy);
  color: var(--white);
  padding: var(--space-5) 0 var(--space-4);
}
.legal-hero h1 { color: var(--white); margin-bottom: 4px; }
.legal-hero p { color: rgba(255,255,255,0.7); margin: 0; }
.legal-content { max-width: 780px; margin: 0 auto; padding: var(--space-5) var(--space-3); }
.legal-content h2 { margin-top: var(--space-4); font-size: 1.15rem; }
.legal-content h2:first-of-type { margin-top: 0; }
.legal-content p { color: var(--text-body); }
.legal-content .back-home { display: inline-block; margin-bottom: var(--space-3); font-weight: 600; color: var(--navy); text-decoration: none; }
.legal-content .back-home:hover { text-decoration: underline; }

/* 404 */
.error-page {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-6) var(--space-3);
}
.error-page__code {
  font-size: 4rem;
  font-weight: 900;
  color: var(--navy);
  margin-bottom: 0;
}

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

/* Responsive */
@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__art { order: -1; max-width: 220px; margin: 0 auto var(--space-3); }
  .trust-grid, .steps-grid, .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; row-gap: var(--space-4); }
}

@media (max-width: 640px) {
  .main-nav__links { display: none; }
  .main-nav.is-open .main-nav__links {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--navy);
    padding: var(--space-2) var(--space-3) var(--space-3);
    gap: var(--space-1);
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }
  .nav-toggle { display: inline-flex; }
  .site-header__inner { position: relative; }
  .trust-grid, .steps-grid, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; text-align: left; }
  .hero { padding: var(--space-5) 0 var(--space-4); }
  .btn { width: 100%; }
  .hero .btn { width: auto; }
}
