/* =========================================================================
   LAYOUT: page shell, section rhythm, container widths, header, footer
   ========================================================================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-overlay);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
  padding: var(--space-3) var(--gutter);
  display: none; /* hidden during intro; shown after handoff */
}

.site-header.is-visible {
  display: block;
  animation: fadeSlideDown var(--dur) var(--ease-smooth) both;
}

.site-header__inner {
  max-width: var(--content-max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
}

.site-header__logo img {
  height: 36px;
  width: auto;
}

.site-header__nav {
  display: flex;
  gap: var(--space-5);
  align-items: center;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
}

.site-header__nav a {
  color: var(--text-primary);
  border-bottom: none;
}

.site-header__cta {
  background: var(--navy);
  color: var(--white);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-pill);
  font-size: var(--fs-sm);
  transition: background var(--dur-fast) var(--ease-standard);
  border-bottom: none;
}

.site-header__cta:hover {
  background: var(--navy-800);
  border-bottom: none;
}

@media (max-width: 700px) {
  .site-header__nav { display: none; }
}

/* ---------- main paper container (revealed after intro) ---------- */

.main-paper {
  display: none;
  padding: var(--space-8) var(--gutter) var(--space-12);
}

.main-paper.is-visible {
  display: block;
}

.section {
  max-width: var(--content-max);
  margin: 0 auto var(--space-11);
  scroll-margin-top: 96px;
}

/* Prose sections that follow a full-width coloured panel need extra top
   breathing room so their headlines don't crowd the panel edge. */
.guess-section + .section,
.keyhole-section + .section,
.vendors-section + .section,
.calc-section + .section,
.cases-section + .section,
.cta-section + .section {
  margin-top: var(--space-8);
}

.section--prose {
  max-width: var(--prose-max);
}

.section--wide {
  max-width: var(--content-max);
}

.section-eyebrow {
  display: inline-block;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-weight: var(--fw-semibold);
  color: var(--text-accent);
  margin-bottom: var(--space-3);
}

.section-headline {
  font-size: var(--fs-3xl);
  color: var(--text-primary);
  margin-bottom: var(--space-6);
}

.section-subhead {
  font-size: var(--fs-lg);
  color: var(--text-body);
  margin-bottom: var(--space-6);
  max-width: 42rem;
}

/* ---------- footer ---------- */

.site-footer {
  display: none;
  padding: var(--space-9) var(--gutter) var(--space-7);
  background: var(--navy);
  color: var(--navy-200);
  font-size: var(--fs-sm);
}

.site-footer.is-visible {
  display: block;
}

.site-footer__inner {
  max-width: var(--content-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-7);
}

.site-footer h4 {
  color: var(--white);
  font-size: var(--fs-base);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-3);
}

.site-footer a {
  color: var(--cyan-100);
}

.site-footer__bottom {
  max-width: var(--content-max);
  margin: var(--space-8) auto 0;
  padding-top: var(--space-5);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  color: var(--navy-400);
}

@media (max-width: 700px) {
  .site-footer__inner {
    grid-template-columns: 1fr;
  }
  .site-footer__bottom {
    flex-direction: column;
    text-align: center;
  }
}

@keyframes fadeSlideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
  from { opacity: 0; transform: scale(0.94); }
  to   { opacity: 1; transform: scale(1); }
}
