/* ============================================
   NomadBridge: Sections CSS
   Titan-inspired editorial layout
   Each section has a unique structure
   ============================================ */

/* ================================================
   1. TITAN HERO: Static, editorial, white bg
   ================================================ */

.titan-hero {
  padding: var(--shell-top) 0 var(--space-9);
  background: var(--pure-white);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  position: relative;
  overflow: visible;
}

.hero-card {
  background: var(--hero-card-bg);
  border: 1px solid var(--sand-deep);
  border-bottom: none;
  border-radius: var(--shell-radius) var(--shell-radius) 0 0;
  width: var(--shell-width);
  margin: 0 auto;
  min-height: 75vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  z-index: 1;
}

/* Grid layout (original hero: index.html) */
.titan-hero--grid {
  min-height: 85vh;
  padding: var(--space-9) 0 var(--space-7);
}

.titan-hero__inner {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: var(--space-8);
  align-items: center;
}

.titan-hero__image {
  position: relative;
}

.titan-hero__image img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-card);
  object-fit: cover;
  aspect-ratio: 4/5;
}

/* Centered layout (v2 hero: index-v2.html) */
.titan-hero__center {
  text-align: center;
  max-width: 680px;
  margin: 0 auto;
  position: relative;
  z-index: 10;
}

.titan-hero__headline {
  margin-bottom: var(--space-5);
}

.titan-hero__body {
  font-size: var(--text-md);
  color: var(--muted);
  line-height: var(--leading-relaxed);
  max-width: 440px;
  margin-bottom: var(--space-5);
}

/* Override body text for centered v2 layout */
.titan-hero__center .titan-hero__body {
  font-size: var(--text-lg);
  max-width: 600px;
  margin: 0 auto var(--space-6);
  color: var(--ink-soft);      /* darker, owner request */
  line-height: 1.4;            /* tighter, owner request (was 1.65) */
}

.titan-hero__cta {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 550;
  color: var(--white);
  background-color: var(--forest);
  padding: 10px 24px;
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: background-color var(--duration-normal) var(--ease-out);
}

.titan-hero__cta:hover {
  background-color: var(--terracotta-dark);
  color: var(--white);
}

/* Two hero actions: book (filled) and explore the services (outlined) */
.titan-hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-3);
}

.titan-hero__cta--secondary {
  color: var(--forest);
  background-color: transparent;
  box-shadow: inset 0 0 0 1.5px var(--forest);
  transition: background-color var(--duration-normal) var(--ease-out), color var(--duration-normal) var(--ease-out);
}

.titan-hero__cta--secondary:hover {
  color: var(--white);
  background-color: var(--forest);
}

.titan-hero__cta:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 3px;
  border-radius: var(--radius-full);
}

/* ---- Scroll stage wrapper ---- */
.scroll-stage {
  position: relative;
}

/* ---- Showcase / Bento section ---- */
.showcase {
  padding: var(--space-7) 0 var(--space-4);
  background: var(--pure-white);
  position: relative;
  z-index: 1;
}

.showcase__card {
  background: var(--sand);
  border-radius: var(--radius-card-lg);
  padding: var(--space-5);
  border: 1px solid var(--sand-deep);
}

/* Four tiles, one per service, in nav order. Each tile is a link to
   its service page; the photo flies onto it from the hero and its
   pointer-events pass clicks through to the link underneath. */
.showcase__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: 440px;
  gap: 12px;
}

.showcase__slot {
  display: block;
  border-radius: var(--radius-card);
  background: var(--sand-deep);
  overflow: hidden;
}

.showcase__slot:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 3px;
  border-radius: var(--radius-card);
}

/* ---- Flying images ---- */
.fly-img {
  position: fixed;
  z-index: 5;
  pointer-events: none;
  will-change: transform, width, height, left, top;
}

.fly-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
  display: block;
  /* js/parallax.js eases --fly-shadow-alpha to 0 as the photo lands */
  box-shadow: 0 8px 30px rgb(var(--ink-rgb) / var(--fly-shadow-alpha, var(--shadow-fly-alpha)));
}

/* Service name on each photo; fades in once the photo has landed
   (js/parallax.js adds .fly-img--landed, or .fly-img--placed) */
.fly-img__label {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--glass-bg);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  line-height: 1.3;
  color: var(--forest);
  white-space: nowrap;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity var(--duration-normal) var(--ease-out), transform var(--duration-normal) var(--ease-out);
}

.fly-img--landed .fly-img__label,
.fly-img--placed .fly-img__label {
  opacity: 1;
  transform: none;
}

/* Reduced motion: js/parallax.js moves each photo into its slot */
.fly-img--placed {
  position: relative;
  width: 100%;
  height: 100%;
  will-change: auto;
}

.fly-img--placed img {
  border-radius: 0;
  box-shadow: none;
}

/* Before the 768px rules, so phones keep their two-by-two grid */
@media (max-width: 1200px) {
  .showcase__grid { grid-template-rows: 360px; }
}

@media (max-width: 768px) {
  /* No empty sand boxes in the first screen before the photos land:
     each photo covers its slot exactly, so slots and frame stay clear */
  .showcase__slot { background: transparent; }
  .showcase__card { background: transparent; border-color: transparent; padding: 0; }
  .titan-hero { min-height: 80vh; padding: var(--shell-top) 0 0; }
  /* Fixed room above and below the hero text for the photos, so on short
     phones the text never slides under the nav and the photos never
     shrink into it (js/parallax.js fits them into these bands) */
  .hero-card {
    min-height: auto;
    padding: calc(var(--nav-clearance) + 7.5rem) 0 8rem;
  }
  .fly-img img {
    border-radius: 12px;
    box-shadow: 0 4px 16px rgb(var(--ink-rgb) / var(--fly-shadow-alpha, var(--shadow-fly-alpha-mobile)));
  }
  .showcase__grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 240px 240px;
  }
  .fly-img__label {
    left: 8px;
    bottom: 8px;
    padding: 4px 10px;
    font-size: var(--text-xs);
  }
}

/* ================================================
   2. MISSION CARD: the mission line as the heading of
   one rounded card, a single supporting sentence and
   the photo. The longer brand story lives on About.
   ================================================ */

.brand-card-section {
  padding: var(--space-9) 0;
  background: var(--pure-white);
}

/* Straight after the photo tiles: one continuing story, so the card
   follows the tiles with a tile-sized gap instead of two section paddings */
.scroll-stage + .brand-card-section {
  padding-top: 0;
}

.brand-card {
  background: var(--sand);
  border-radius: var(--radius-card-lg);
  overflow: hidden;
}

.brand-card__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.brand-card__text {
  padding: var(--space-8) var(--space-8);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
}

.brand-card__title {
  font-size: var(--text-statement);
  line-height: 1.1;
  letter-spacing: -0.015em;
  text-wrap: balance;
  margin-bottom: var(--space-5);
}

/* Key words in brand colour (both pass 4.5:1 on sand) */
.brand-card__word--roots {
  color: var(--forest);
}

.brand-card__word--route {
  color: var(--terracotta-dark);
}

.brand-card__body {
  font-size: var(--text-md);
  color: var(--muted-strong);
  line-height: var(--leading-normal);
  max-width: 44ch;
  margin-bottom: var(--space-6);
}

/* About: the brand story moved from the home page */
.about-intro {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--space-5) var(--space-9);
  align-items: start;
}

.about-intro h2 {
  margin-bottom: 0;
}

.about-intro__body p {
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
  color: var(--ink);
  max-width: 60ch;
}

.brand-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-height: 400px;
}

/* ================================================
   4. EDITORIAL BREAK: Full-bleed image
   ================================================ */

.editorial-break {
  padding: 0;
  overflow: hidden;
}

.editorial-break__image {
  width: 100%;
  position: relative;
}

.editorial-break__image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  aspect-ratio: 16/6;
  filter: grayscale(20%) contrast(1.05);
}

/* ================================================
   5. CHALLENGES: four PRD 5.3 figures, four across
   ================================================ */

.challenges {
  padding: var(--space-9) 0;
  background: var(--sand);
}

/* Heading with its intro line directly below */
.challenges__head {
  margin-bottom: var(--space-8);
}

.challenges__head h2 {
  margin-bottom: var(--space-5);
}

.challenges__head p {
  font-size: var(--text-md);
  color: var(--muted-strong);
  max-width: 52ch;
  margin: 0;
}

/* Scroll entrance (js/challenges.js adds .is-armed to the section and
   .is-in to each column as it arrives): the column rises in, its
   figure counts up and its top hairline draws in */
.challenges.is-armed .challenge {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 120ms);
}

.challenges.is-armed .challenge.is-in {
  opacity: 1;
  transform: none;
}

.challenge {
  position: relative;
}

.challenges.is-armed .challenge::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--forest);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1.1s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 120ms + 150ms);
}

.challenges.is-armed .challenge.is-in::before {
  transform: scaleX(1);
}

.challenge__count {
  font-variant-numeric: tabular-nums lining-nums;
}

/* Four columns split by hairlines. Subgrid lines up the figures,
   titles, text, sources and links across all four columns. */
.challenge-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(5, auto);
  border-top: 1px solid var(--sand-deep);
}

.challenge {
  display: grid;
  grid-row: span 5;
  grid-template-rows: subgrid;
  row-gap: var(--space-3);
  align-content: start;
  padding: var(--space-6) var(--space-5) 0;
  border-left: 1px solid var(--sand-deep);
}

.challenge:first-child {
  padding-left: 0;
  border-left: 0;
}

.challenge:last-child {
  padding-right: 0;
}

.challenge__stat {
  font-family: var(--font-display);
  font-size: var(--text-display-2);
  font-weight: var(--weight-semibold);
  line-height: 1;
  color: var(--forest);
  margin: 0 0 var(--space-2);
}

.challenge__title {
  font-size: var(--text-display-4);
  line-height: var(--leading-tight);
  margin: 0;
}

.challenge__title::after {
  display: none;
}

.challenge__text {
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--ink);
  margin: 0;
}

.challenge__source {
  padding-top: var(--space-3);
  font-size: var(--text-xs);
  line-height: var(--leading-snug);
  color: var(--muted-strong);
  margin: 0;
}

/* "Solved by" link: muted lead-in, the service name as the action,
   an arrow that nudges on hover, and 8px extra hit area above and below */
.challenge__link {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0 var(--space-2);
  justify-self: start;
  padding: var(--space-2) 0;
  font-size: var(--text-sm);
  line-height: var(--leading-snug);
  color: var(--forest);
  text-decoration: none;
}

.challenge__link-label {
  color: var(--muted-strong);
}

.challenge__link-name {
  font-weight: var(--weight-semibold);
  text-decoration: underline;
  text-decoration-color: var(--sand-deep);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
  transition: text-decoration-color var(--duration-fast) var(--ease-out);
}

.challenge__link svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  flex-shrink: 0;
  transition: transform var(--duration-fast) var(--ease-out);
}

.challenge__link:hover {
  color: var(--forest);
}

.challenge__link:hover .challenge__link-name {
  text-decoration-color: currentColor;
}

.challenge__link:hover svg {
  transform: translateX(3px);
}

@media (prefers-reduced-motion: reduce) {
  .challenge__link:hover svg {
    transform: none;
  }
}

/* ================================================
   6. SERVICES: vertical showcase (js/services.js)
   One service open at a time beside a large photo
   that crossfades. From 769px the section holds in
   place while the page scrolls through the four
   services; the rail fills with that scroll like a
   loader. Phones: a plain accordion.
   ================================================ */

.services-showcase {
  padding: var(--space-9) 0;
  background: var(--pure-white);
}

.services-showcase__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-5);
  margin-bottom: var(--space-7);
}

.services-showcase__head h2 {
  margin-bottom: 0;
}

.services-showcase__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--space-8);
  align-items: start;
}

/* ---- The list and its rail ---- */
/* The rail is a 3px track; on the open item it fills like a loader
   while auto-advance counts down to the next service */
.svc {
  position: relative;
  padding-left: var(--space-5);
  border-left: 3px solid var(--sand-deep);
}

.svc::before {
  content: '';
  position: absolute;
  left: -3px;
  top: 0;
  bottom: 0;
  width: 3px;
  border-radius: 3px;
  background: var(--forest);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform var(--duration-normal) var(--ease-out);
}

.svc--active::before {
  transform: scaleY(1);
}

/* While auto-advancing, the open item's rail fills over the interval;
   its animationend opens the next service (js/services.js) */
/* Scroll-driven (wide screens): each item's rail fills with scroll,
   so the rail reads as a loader for the move to the next service */
.is-scrolly .svc::before,
.is-scrolly .svc--active::before {
  transform: scaleY(var(--svc-fill, 0));
  transition: none;
}

/* The block that holds in place while the four services scroll past */
.is-scrolly .svc-sticky {
  position: sticky;
  top: calc(var(--nav-clearance) + var(--space-5));
}

.is-scrolly .svc-media {
  position: relative;
  top: auto;
  max-height: calc(100vh - var(--nav-clearance) - 200px);
}

.svc__heading {
  margin: 0;
  font-size: var(--text-display-4);
  line-height: var(--leading-tight);
}

.svc__heading::after {
  display: none;
}

.svc__trigger {
  display: block;
  width: 100%;
  padding: var(--space-4) 0;
  background: none;
  border: 0;
  font: inherit;
  color: var(--muted-strong);
  text-align: left;
  cursor: pointer;
  transition: color var(--duration-fast) var(--ease-out);
}

.svc__trigger:hover,
.svc--active .svc__trigger {
  color: var(--ink);
}

.svc__trigger:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 4px;
  border-radius: var(--radius-sm);
}

.svc__panel {
  padding-bottom: var(--space-6);
}

.svc__panel:not([hidden]) {
  animation: svc-reveal var(--duration-normal) var(--ease-out);
}

@keyframes svc-reveal {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: none; }
}

/* Photo inside each item: phones only (the big frame shows it on wide screens) */
.svc__photo {
  display: none;
}

.svc__tagline {
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  color: var(--muted-strong);
  max-width: 46ch;
  margin-bottom: var(--space-5);
}

.fact-list {
  margin-bottom: var(--space-6);
  border-top: 1px solid var(--sand-deep);
}

.fact-list__row {
  display: grid;
  grid-template-columns: 6.5rem minmax(0, 1fr);
  gap: var(--space-4);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--sand-deep);
  font-size: var(--text-sm);
  line-height: var(--leading-snug);
}

.fact-list dt {
  font-weight: var(--weight-medium);
  color: var(--ink);
}

.fact-list dd {
  color: var(--muted-strong);
}

.svc__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

/* ---- The photo frame ---- */
.svc-media {
  position: sticky;
  top: calc(var(--nav-clearance) + var(--space-5));
  aspect-ratio: 5 / 4;
  border-radius: var(--radius-card-lg);
  overflow: hidden;
  background: var(--sand);
}

.svc-media__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.6s var(--ease-out);
}

.svc-media__img--active {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .svc::before,
  .svc-media__img {
    transition: none;
  }
  .svc__panel:not([hidden]) {
    animation: none;
  }
}

/* ================================================
   7. CLIENT STORIES: quote cards
   ================================================ */

.stories-section {
  padding: var(--space-9) 0;
  background: var(--pure-white);
  border-top: 1px solid var(--sand-deep);
  border-bottom: 1px solid var(--sand-deep);
}

.stories-section__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-5);
  margin-bottom: var(--space-7);
}

.stories-section__header h2 {
  margin-bottom: var(--space-4);
}

.stories-section__lede {
  font-size: var(--text-md);
  color: var(--muted-strong);
  margin: 0;
}

/* One row of cards that moves right to left without end. js/stories.js
   drives it with scrollLeft, so people can also take over: trackpad or
   touch swipe, mouse drag, the arrow buttons, or the arrow keys once the
   row has focus. A hidden copy of the six cards makes the loop seamless.
   Auto-scroll pauses on hover, focus, any manual move (resuming a few
   seconds later) and with the Pause button; never with reduced motion. */
.stories-marquee {
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  padding: 0 var(--gutter);
  cursor: grab;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 4%, #000 96%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 4%, #000 96%, transparent);
}

.stories-marquee::-webkit-scrollbar {
  display: none;
}

.stories-marquee.is-dragging {
  cursor: grabbing;
  user-select: none;
}

.stories-marquee:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 4px;
}

.stories__grid {
  display: flex;
  gap: var(--space-4);
  width: max-content;
}

.stories__grid .story-card {
  flex: none;
  width: 360px;
}

.stories-controls {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-shrink: 0;
}

/* Previous / next: 44px round buttons */
.stories-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--sand-deep);
  border-radius: var(--radius-full);
  background: var(--white);
  color: var(--forest);
  cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-out);
}

.stories-arrow:hover {
  background: var(--sand);
}

.stories-arrow svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stories-arrow:focus-visible,
.stories-toggle:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 3px;
}

/* Pause / Play for the moving row (WCAG 2.2.2) */
.stories-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  flex-shrink: 0;
  padding: 8px 14px;
  border: 1px solid var(--sand-deep);
  border-radius: var(--radius-full);
  background: var(--white);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--forest);
  cursor: pointer;
}

.stories-toggle[hidden] {
  display: none;
}

.stories-toggle:hover {
  background: var(--sand);
}

.stories-toggle svg {
  width: 12px;
  height: 12px;
  fill: currentColor;
}

.stories-toggle__play,
.stories-toggle--paused .stories-toggle__pause {
  display: none;
}

.stories-toggle--paused .stories-toggle__play {
  display: block;
}

/* Named-client story card: quote and attribution only, no portrait.
   Stock photos must never stand in for real clients. */
.story-card {
  border-radius: var(--radius-card);
}

.story-card--quote {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-7);
  padding: var(--space-6);
  background: var(--sand);   /* warm tint on the white section, no border */
  color: var(--ink);
}

/* Colours run sand, green, terracotta, gold, sand, green: no two
   neighbouring cards match at three, two or one column */
.story-card--quote:nth-child(4n + 2) { background: var(--tint-forest); }
.story-card--quote:nth-child(4n + 3) { background: var(--tint-terracotta); }
.story-card--quote:nth-child(4n + 4) { background: var(--tint-gold); }

.story-card__quote p {
  font-family: var(--font-display);
  font-size: var(--text-lg);   /* 18-21px, down from 22-28px (owner request) */
  font-weight: var(--weight-regular);
  line-height: 1.3;
  color: var(--ink);
  text-wrap: pretty;
}

.story-card__meta {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding-top: var(--space-4);
  border-top: 1px solid var(--ink-12);
}

.story-card__name {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: var(--weight-medium);
  line-height: 1.3;
  color: var(--ink);
}

/* Roles reserve two lines, so every name sits at the same height
   whether its role wraps or not */
.story-card__role {
  min-height: calc(2 * var(--leading-snug) * 1em);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  line-height: var(--leading-snug);
  color: var(--muted-strong);   /* 5.30 on sand */
}

/* ================================================
   9. FINAL CTA
   ================================================ */

.final-cta {
  padding: var(--space-9) 0;
  background: var(--pure-white);
}

.final-cta__grid {
  display: grid;
  grid-template-columns: 65fr 35fr;
  gap: var(--space-8);
  align-items: center;
}

.final-cta__headline {
  margin-bottom: var(--space-5);
}

.final-cta__text p {
  font-size: var(--text-md);
  color: var(--muted);
  margin-bottom: var(--space-6);
  max-width: 440px;
}

.final-cta__image img {
  width: 100%;
  border-radius: var(--radius-card);
  object-fit: cover;
  aspect-ratio: 6/5;
}

/* ================================================
   BOOK A CALL (contact.html): text left, form right
   ================================================ */

.contact-section {
  margin-top: var(--nav-height);
  padding-top: var(--space-9);
}

.cta-section__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 460px);
  gap: var(--space-9);
  align-items: start;
}

.cta-section__text {
  max-width: 600px;
}

.cta-section__text h1 {
  max-width: 14ch;
  margin-bottom: var(--space-5);
  text-wrap: balance;
}

.contact-lede {
  font-size: var(--text-md);
  color: var(--muted);
  max-width: 46ch;
  margin-bottom: var(--space-6);
  text-wrap: pretty;
}

/* Four points in two rows of two */
.contact-trust {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, max-content));
  gap: var(--space-3) var(--space-7);
  margin-bottom: var(--space-7);
}

/* The form sits in a quiet frame with its own heading */
.cta-section__form-wrap {
  align-self: start;
  border: 1px solid var(--sand-deep);
  border-radius: var(--radius-card);
  padding: var(--space-7);
  background-color: var(--white);
}

/* Headings for the two ways to book: "Book a call" and the form */
.panel-title {
  font-size: var(--text-display-4);
  line-height: var(--leading-tight);
  margin-bottom: var(--space-5);
}

/* ================================================
   SCROLL REVEAL ANIMATION
   ================================================ */

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

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

/* ================================================
   LEGACY: Service pages (page-hero, etc.)
   Keep these for language-program.html, etc.
   ================================================ */

.page-hero {
  position: relative;
  padding: var(--space-10) 0;
  overflow: hidden;
  min-height: 420px;
  display: flex;
  align-items: center;
}

/* Full-bleed heroes start at the very top; the fixed nav floats over
   them, so the top padding adds the nav's space to the usual padding. */
.page-hero--bg {
  padding-top: calc(var(--nav-clearance) + var(--space-10));
  min-height: calc(420px + var(--nav-clearance));
  background-image: var(--hero-bg-image);
  background-size: cover;
  background-position: center;
}

.page-hero--bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, var(--hero-color-start) 0%, var(--hero-color-start) 35%, var(--hero-color-end) 100%);
  z-index: 1;
}

.page-hero--bg > .container {
  position: relative;
  z-index: 2;
}

.page-hero--language { --hero-color-start: var(--hero-language-start); --hero-color-end: var(--hero-language-end); }
.page-hero--rooted { --hero-color-start: var(--hero-rooted-start); --hero-color-end: var(--hero-rooted-end); }
.page-hero--women { --hero-color-start: var(--hero-women-start); --hero-color-end: var(--hero-women-end); }
.page-hero--family { --hero-color-start: var(--hero-family-start); --hero-color-end: var(--hero-family-end); }
.page-hero--about { --hero-color-start: var(--hero-about-start); --hero-color-end: var(--hero-about-end); }

.page-hero--cream {
  background-color: var(--sand);
}

.page-hero__content {
  max-width: 640px;
  color: var(--pure-white);
  position: relative;
  z-index: 2;
}

.page-hero__content--centered {
  max-width: 720px;
}

.page-hero--cream .page-hero__content { color: var(--ink); }
.page-hero--cream h1 { color: var(--ink); }
.page-hero__content h1 { color: var(--pure-white); margin: var(--space-4) 0 var(--space-5); }
.page-hero--cream .page-hero__content h1 { color: var(--ink); }

.page-hero__tagline {
  font-size: var(--text-lg);
  color: var(--white-80);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-7);
  max-width: 560px;
}

.page-hero--cream .page-hero__tagline { color: var(--muted-strong); }


/* Legacy service page grid */
.service-page-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: var(--space-9);
  align-items: start;
}

.service-page-main h2 { margin-bottom: var(--space-4); }
.service-page-main > p { color: var(--muted); font-size: var(--text-md); margin-bottom: var(--space-6); max-width: 560px; }
.service-page-sidebar { position: sticky; top: calc(var(--nav-height) + var(--space-6)); }

.cefr-levels { display: flex; gap: var(--space-4); margin-bottom: var(--space-5); }
.cefr-level { display: flex; flex-direction: column; align-items: center; gap: var(--space-1); }
.cefr-level__code { width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; background-color: var(--forest); color: var(--pure-white); font-family: var(--font-display); font-size: var(--text-lg); font-weight: var(--weight-semibold); border-radius: var(--radius-md); }
.cefr-level__name { font-size: var(--text-xs); color: var(--muted); font-weight: var(--weight-medium); }

/* Legacy about page */
.about-block { max-width: 640px; }
.about-block h2 { margin-bottom: var(--space-5); }
.about-block p { font-size: var(--text-md); color: var(--muted); line-height: var(--leading-relaxed); }

/* Closing call to action on a forest band (service pages, About) */
/* Headline on the left, the supporting line and button on the right */
.cta-band__inner {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: var(--space-6) var(--space-9);
  align-items: center;
}
.cta-band__title {
  color: var(--white);
  max-width: 20ch;
  margin-bottom: 0;
}
.cta-band__body {
  color: var(--white-80);
  font-size: var(--text-md);
  max-width: 44ch;
  margin-bottom: var(--space-6);
}
.about-approach-card { background-color: var(--white); border-radius: var(--radius-lg); padding: var(--space-7); border: 1px solid var(--sand-deep); }
.about-approach-card h3 { margin-bottom: var(--space-3); }
.about-approach-card__lede { color: var(--muted); margin-bottom: var(--space-5); }
.about-service-link { padding: var(--space-4) 0; border-bottom: 1px solid var(--sand-deep); }
.about-service-link:last-child { border-bottom: none; padding-bottom: 0; }
.about-service-link h4 { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-base); margin-bottom: var(--space-1); }
.about-service-link h4 a { color: var(--forest); font-weight: var(--weight-medium); }
.about-service-link h4 a:hover { color: var(--terracotta-dark); }
.about-service-link p { font-size: var(--text-sm); color: var(--muted); padding-left: 26px; }

/* Service page facts band: the PRD figures and facts as one plain list */
.stats__facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: var(--space-4) var(--space-8);
}

.stats__facts li {
  display: flex;
  align-items: baseline;
  gap: var(--space-3);
  font-size: var(--text-base);
  line-height: var(--leading-snug);
  color: var(--white);
}

.stats__facts svg {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  transform: translateY(2px);
  stroke: var(--gold-light);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* ================================================
   LEGAL PAGES (privacy policy)
   ================================================ */

.legal {
  margin-top: var(--nav-height);
  padding-top: var(--space-9);
}

.legal .container--text {
  max-width: 68ch;
}

.legal__header {
  margin-bottom: var(--space-6);
}

.legal__header h1 {
  font-size: var(--text-display-2);
  color: var(--forest);
  margin-bottom: var(--space-3);
}

.legal__updated {
  font-size: var(--text-sm);
  color: var(--muted);
}

.legal__lede {
  font-size: var(--text-md);
  line-height: var(--leading-relaxed);
  color: var(--ink);
}

.legal__section {
  margin-top: var(--space-7);
}

.legal__section h2 {
  font-size: var(--text-display-4);
  color: var(--forest);
  margin-bottom: var(--space-4);
  scroll-margin-top: calc(var(--nav-height) + var(--space-5));
}

.legal__section p,
.legal__list {
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--ink);
  margin-bottom: var(--space-4);
}

.legal__list {
  padding-left: var(--space-5);
  list-style: disc;
}

.legal__list li + li {
  margin-top: var(--space-2);
}

.legal__section a {
  color: var(--forest);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Spots the owner still has to fill in or confirm before launch */
.legal__todo {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: var(--sand-deep);
  color: var(--ink);
  font-size: var(--text-sm);
}
