/* ==========================================================================
   Ace Trail redesign (Option E). Spec: REDESIGN.md.
   Mobile-first; breakpoints at 768px and 992px.
   ========================================================================== */

/* Tokens (REDESIGN.md §3)
   ========================================================================== */

:root {
  /* colour */
  --bg: #F6F3EB;          /* page off-white */
  --ink: #111111;         /* text, dark sections, lines */
  --yellow: #FFD300;      /* Ace Trail yellow: primary buttons, accents */
  --yellow-pale: #FFF3C4; /* closing CTA background */
  --text: #3d3b36;        /* body copy on light */
  --muted: #6b6860;       /* captions on light */
  --meta: #8a857a;        /* labels, column headers */
  --on-dark-muted: #b8b3a7;
  --line-soft: #d9d3c4;   /* inactive timeline */
  --skeleton: #e7e2d6;    /* placeholder bars in the resource card */
  --row-hover: #EFEADF;   /* class row hover */
  --surface-dark: #1c1c1c;/* image placeholder on dark */
  --white: #ffffff;

  /* motion */
  --ease: cubic-bezier(.2,.7,.2,1);
  --ease-spring: cubic-bezier(.34,1.3,.5,1); /* CTA shapes settle */

  /* layout */
  --gutter: 20px;         /* mobile */
  --col-gap: 12px;
  --header-h: 56px;
  --focus: var(--ink);

  /* type: clamp() hits the exact px at 390 and 1440 */
  --font: Figtree, system-ui, -apple-system, "Segoe UI", sans-serif;
  --fs-h1: clamp(48px, 36.22857px + 6.095238vw, 124px);
  --fs-h2: clamp(42px, 30.85714px + 2.857143vw, 72px);
  --fs-lead: clamp(15px, 14.25714px + 0.190476vw, 17px);
  --fs-body: 15px;
}

@media (min-width: 992px) {
  :root { --gutter: 32px; --col-gap: 24px; --header-h: 64px; }
}

/* Reset
   ========================================================================== */

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

* { margin: 0; }

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

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--fs-body);
  font-weight: 500;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

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

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

button { background: none; border: 0; padding: 0; cursor: pointer; text-align: inherit; }

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

:where(ul, ol)[role="list"] { list-style: none; padding: 0; }

p, h1, h2, h3, h4, h5, h6 { overflow-wrap: break-word; }

h1, h2, h3, h4, h5, h6 { font-weight: 800; line-height: 1; }

[hidden] { display: none !important; }

/* Anchors clear the header */
[id] { scroll-margin-top: var(--header-h); }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

/* Base typography
   ========================================================================== */

.h1 {
  font-size: var(--fs-h1);
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 0.92;
}

.h2 {
  font-size: var(--fs-h2);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1;
}

@media (min-width: 992px) {
  .h1 { line-height: 0.9; }
  .h2 { line-height: 0.98; }
}

.lead {
  font-size: var(--fs-lead);
  font-weight: 600;
  line-height: 1.5;
  color: var(--text);
}

.meta {
  font-size: 11px;
  font-weight: 600;
  color: var(--meta);
}

@media (min-width: 992px) {
  .meta { font-size: 12px; }
}

.nowrap { white-space: nowrap; }

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

/* Layout: sections, container, 12-col grid
   ========================================================================== */

.section,
.container {
  padding-inline: var(--gutter);
}

.section { position: relative; }

.is-dark {
  --focus: var(--yellow);
  background: var(--ink);
  color: var(--bg);
}

/* Legacy IDs (#about-us, #our-team, #testimonials) that land on the new sections */
.anchor-alias {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  overflow: hidden;
  pointer-events: none;
}

/* Children stack full-width on mobile. From 992px they take
   --col-start / --col-span (set per component) on 12 columns. */
.grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  column-gap: var(--col-gap);
}

@media (min-width: 992px) {
  .grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .grid > * { grid-column: var(--col-start, auto) / span var(--col-span, 12); }
}

/* Components
   ========================================================================== */

/* Buttons. Heights: 44 (--sm), 52 (default), 58 (--lg) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 44px;
  height: 52px;
  padding: 0 20px;
  border: 0;
  background: var(--yellow);
  color: var(--ink);
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}

.btn--sm { height: 44px; padding: 0 18px; font-size: 14px; }
.btn--lg { height: 58px; }

.btn--secondary {
  background: var(--ink);
  color: var(--white);
}

.btn .arr {
  display: inline-block;
  transition: transform .4s var(--ease);
}

@media (hover: hover) {
  .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px -10px rgba(17,17,17,.45);
  }
  .btn:hover .arr { transform: translateX(4px); }
}

/* Status chips ("Open", "Coming soon") */
.chip {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border: 1px solid currentColor;
  font-size: 11px;
  font-weight: 700;
  line-height: normal;
  white-space: nowrap;
}

@media (min-width: 992px) {
  .chip { padding: 3px 7px; font-size: 12px; }
}

/* Text links: underline grows 0 → 100% on hover */
.link {
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 1px;
  transition: background-size .45s var(--ease);
}

.link:hover,
.link:focus-visible {
  background-size: 100% 1px;
}

/* Focus
   ========================================================================== */

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

:focus:not(:focus-visible) { outline: none; }

/* Reveal on enter (driven by js/redesign.js)
   [data-reveal]        fade up 24px, 1s
   [data-reveal="fade"] fade only, --reveal-dur (default 1s)
   [data-reveal="rule"] draw scaleX 0 → 1, 1.2s
   Delay comes from --reveal-delay, set by the script.
   Hidden only when JS is running (html.js), so no-JS visitors see everything.
   ========================================================================== */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 1s var(--ease) var(--reveal-delay, 0s),
    transform 1s var(--ease) var(--reveal-delay, 0s);
}

.js [data-reveal="rule"] {
  opacity: 1;
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 1.2s var(--ease) var(--reveal-delay, 0s);
}

.js [data-reveal="fade"] {
  transform: none;
  transition: opacity var(--reveal-dur, 1s) var(--ease) var(--reveal-delay, 0s);
}

.js [data-reveal].is-revealed {
  opacity: 1;
  transform: none;
}

/* Intro on load: .rise with delays .d1–.d4 */
.rise { animation: rise 1s var(--ease) both; }
.d1 { animation-delay: .1s; }
.d2 { animation-delay: .2s; }
.d3 { animation-delay: .32s; }
.d4 { animation-delay: .45s; }

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

/* Scroll lock while the mobile menu is open */
html.is-locked { overflow: hidden; }

/* Header (§5.1). Fixed at every width.
   Mobile: logo left, Get started + Menu right. Desktop: 3-col grid.
   The background fades in once the hero morph is done (.is-solid).
   ========================================================================== */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  height: var(--header-h);
  padding: 0 12px 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
  line-height: normal;
}

.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--bg);
  box-shadow: inset 0 -1px 0 rgba(17,17,17,.12);
  opacity: 0;
  transition: opacity .4s ease;
}

.site-header.is-solid::before { opacity: 1; }

.site-header__nav,
.site-header__resource { display: none; }

.site-header__logo { display: flex; }
.site-header__logo img { width: 88px; }

.site-header__actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.site-header__cta.btn {
  position: relative;
  height: auto;
  min-height: 0;
  padding: 6px 10px;
  font-size: 12px;
  line-height: normal;
}

/* 44px touch target around the small button */
.site-header__cta::after {
  content: "";
  position: absolute;
  inset: -9px 0;
}

.site-header__menu {
  height: 44px;
  padding: 0 8px;
  font-size: 13px;
  font-weight: 600;
}

@media (min-width: 992px) {
  .site-header {
    padding: 0 var(--gutter);
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    font-weight: 500;
  }

  .site-header__nav { display: flex; gap: 20px; }
  .site-header__resource { display: inline; }
  .site-header__logo { justify-self: center; }
  .site-header__logo img { width: 92px; }
  .site-header__actions { justify-self: end; gap: 16px; }
  .site-header__cta.btn { padding: 6px 12px; font-size: 13px; }
  .site-header__cta::after { content: none; }
  .site-header__menu { display: none; }
}

/* Hero (§5.1)
   A sticky stage inside a taller runway. js/redesign.js measures the media's
   start rect ([data-hero-start]) and end rect (.hero__box as laid out), then
   tweens between them with transforms only.
   ========================================================================== */

.hero {
  position: relative;
  /* 620px of scroll at 844, scaled with the viewport; whole px so the
     sections below start on the pixel grid */
  height: calc(100svh * 1464 / 844);
  height: round(100svh * 1464 / 844, 1px);
}

.hero__stage {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: hidden;
}

.hero__text {
  position: absolute;
  inset: var(--header-h) 0 0;
  z-index: 1;
  padding: 28px var(--gutter) 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: normal;
}

.hero__eyebrow {
  height: 28px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.hero__intro {
  margin-top: 45.6px;
  max-width: 330px;
  font-size: var(--fs-lead);
  line-height: 1.45;
  font-weight: 600;
}

/* Below 992 the gaps and the media's start box give way on short screens;
   at 844px tall they hit the design exactly. */
.hero__aside {
  flex: 1 1 auto;
  min-height: 0;
  align-self: stretch;
  display: flex;
  flex-direction: column;
}

.hero__cta {
  margin-top: clamp(24px, 100svh - 761.25px, 82.75px);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hero__btn.btn { height: 50px; padding: 0 18px; }

.hero__price {
  font-size: 12px;
  font-weight: 400;
  color: var(--muted);
}

.hero__price .link {
  color: var(--ink);
  font-weight: 600;
}

.hero__media-start {
  flex: 1 1 auto;
  min-height: 100px;
  max-height: 264px;
  margin: 12px 0 clamp(16px, 100svh - 764px, 80px);
}

@media (min-width: 768px) {
  .hero__cta { max-width: 420px; }
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  font-weight: 400;
  line-height: normal;
}

.hero__box,
.hero__frame {
  position: absolute;
  inset: var(--header-h) 0 0;
}

.hero__box {
  overflow: hidden;
  background: var(--ink);
  transform-origin: 0 0;
  will-change: transform;
}

.hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  object-fit: cover;
  object-position: 50% 55%;
  transform-origin: 0 0;
  will-change: transform;
}

.hero__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,.6) 100%);
  opacity: 0;
}

.hero__proof {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 8px 12px 8px 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--white);
  font-size: 12px;
  line-height: 1.3;
}

.hero__proof strong { font-size: 15px; font-weight: 700; }
.hero__proof span { color: var(--muted); }

.hero__avatars { display: flex; }

.hero__avatars img {
  width: 32px;
  height: 32px;
  border: 2px solid var(--white);
  border-radius: 50%;
  object-fit: cover;
}

.hero__avatars img + img { margin-left: -9px; }

.hero__caption {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 76px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: var(--white);
  opacity: 0;
}

.hero__caption-title {
  font-size: 28px;
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.hero__caption-stats {
  font-size: 13px;
  color: rgba(255,255,255,.8);
}

@media (min-width: 992px) {
  .hero { /* 740px of scroll at 900 */
    height: calc(100svh * 1640 / 900);
    height: round(100svh * 1640 / 900, 1px);
  }

  .hero__text { padding-top: 0; }
  .hero__eyebrow { display: none; }
  .hero__title { margin-top: 104px; animation-delay: 0s; }
  .hero__intro { margin-top: 31.8px; max-width: 380px; }

  /* Right column: CTA row above the media's start rect, anchored to the bottom */
  .hero__aside {
    position: absolute;
    right: var(--gutter);
    bottom: 28px;
    width: 37.2222vw; /* 536 at 1440 */
    gap: 16px;
  }

  .hero__cta {
    margin-top: 0;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .hero__btn.btn { height: 44px; font-size: 14px; }
  .hero__price { font-size: 13px; }
  .hero__price-extra { display: none; }

  .hero__aside { flex: none; }
  .hero__cta { max-width: none; }

  .hero__media-start {
    flex: none;
    min-height: 0;
    max-height: none;
    margin: 0;
    aspect-ratio: 536 / 316;
  }

  .hero__box,
  .hero__frame { inset: calc(var(--header-h) + 8px) 16px 16px; }

  .hero__caption {
    left: auto;
    right: 40px;
    bottom: 12px;
    width: 460px;
  }

  .hero__caption-title { font-size: 40px; line-height: 1.05; }
  .hero__caption-stats { font-size: 15px; }
}

/* Until the script has placed the media, keep it hidden. Without JS the hero
   is just the text. */
.js .hero__media:not(.is-ready) { visibility: hidden; }
html:not(.js) .hero__media { display: none; }
html:not(.js) .hero { height: 100svh; }

/* Mobile menu (§5.1), below 992px
   ========================================================================== */

.menu {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  line-height: normal;
  clip-path: inset(0 0 100% 0);
  visibility: hidden;
  transition: clip-path .55s var(--ease) .1s, visibility 0s linear .65s;
}

.menu.is-open {
  clip-path: inset(0);
  visibility: visible;
  transition: clip-path .75s var(--ease), visibility 0s;
}

.menu__bar {
  flex-shrink: 0;
  height: 56px;
  padding: 0 12px 0 20px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.menu__logo { justify-self: start; display: flex; }
.menu__logo img { width: 88px; }

.menu__tag {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--meta);
}

.menu__close {
  justify-self: end;
  height: 44px;
  padding: 0 8px;
  font-size: 13px;
  font-weight: 600;
}

.menu__body {
  flex-grow: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
}

.menu__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--meta);
}

.menu__nav {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
}

.menu__item {
  display: flex;
  overflow: hidden;
}

.menu__item.is-current { color: var(--meta); }

.menu__item-inner {
  display: flex;
  align-items: baseline;
  gap: 10px;
  transform: translateY(105%);
  transition: transform .35s ease;
}

.menu__item-text {
  font-size: 44px;
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.menu__item-num {
  font-size: 11px;
  font-weight: 600;
  color: var(--meta);
}

.menu__rule {
  flex-shrink: 0;
  margin: 24px -20px 0;
  height: 1px;
  background: rgba(246,243,235,.18);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform .2s ease;
}

.menu__fade {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .2s ease, transform .2s ease;
}

.menu.is-open .menu__item-inner {
  transform: none;
  transition: transform .9s var(--ease) calc(.18s + var(--i) * .05s);
}

.menu.is-open .menu__rule {
  transform: none;
  transition: transform 1s var(--ease) .35s;
}

.menu.is-open .menu__fade {
  opacity: 1;
  transform: none;
  transition:
    opacity .7s ease calc(.4s + var(--i) * .08s),
    transform .8s var(--ease) calc(.4s + var(--i) * .08s);
}

.menu__classes {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
}

.menu__row {
  min-height: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.menu__row.is-soon { color: var(--meta); }

.menu__cols {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 16px;
}

.menu__cols > div { display: flex; flex-direction: column; }
.menu__cols .menu__label { margin-bottom: 8px; }

.menu__foot {
  margin-top: auto;
  padding-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.menu__foot .btn { padding: 0 18px; }

.menu__small {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--meta);
}

@media (min-width: 992px) {
  .menu { display: none; }
}

/* Classes (§5.2)
   Accordion: one row open at a time. The panel opens with grid-template-rows
   0fr → 1fr. Mobile/tablet stack per ClassesEMobile; 12-col from 992px.
   ========================================================================== */

.classes {
  padding-block: 72px 64px;
  line-height: normal;
}

.classes__head { row-gap: 16px; }
.classes__intro { line-height: 1.5; }

.classes__cols { display: none; }

.classes__list {
  margin-top: 48px;
  display: flex;
  flex-direction: column;
}

.classes__rule {
  height: 1px;
  background: var(--ink);
}

.classes__heading {
  font: inherit;
  --reveal-dur: .9s;
}

.classes__row {
  position: relative;
  isolation: isolate;
  width: 100%;
  min-height: 96px;
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  line-height: normal;
}

/* Hover fill as an opacity fade on a pseudo-element */
.classes__row::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--row-hover);
  opacity: 0;
  transition: opacity .4s ease;
}

.classes__label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.classes__meta {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.classes__name {
  font-size: 26px;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.035em;
  transition: transform .5s var(--ease);
}

.classes__side {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.classes__price {
  font-size: 17px;
  font-weight: 800;
}

.classes__status {
  display: flex;
  align-items: center;
  gap: 8px;
}

.classes__icon {
  width: 16px;
  height: 16px;
  transition: transform .5s var(--ease);
}

.classes__item.is-open .classes__icon { transform: rotate(45deg); }

.classes__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .75s var(--ease);
}

.classes__item.is-open .classes__panel { grid-template-rows: 1fr; }

.classes__clip {
  min-height: 0;
  overflow: hidden;
}

.classes__body {
  min-height: 660px;
  padding: 4px 0 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  opacity: 0;
  transition: opacity .6s ease .15s;
}

.classes__item.is-open .classes__body { opacity: 1; }

.classes__media {
  position: relative;
  height: 200px;
  overflow: hidden;
  background: var(--ink);
}

.classes__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 55%;
  transform: scale(1.08);
  transition: transform 1.2s var(--ease);
}

.classes__item.is-open .classes__media img { transform: none; }

.classes__tag {
  position: absolute;
  left: 10px;
  bottom: 10px;
  padding: 4px 8px;
  background: var(--white);
  font-size: 11px;
  font-weight: 600;
}

/* "Coming soon" placeholder: blurred photo, 45% dark tint, label + headline */
.classes__media--soon {
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.classes__media--soon img,
.classes__item.is-open .classes__media--soon img {
  position: absolute;
  inset: 0;
  filter: blur(14px) grayscale(.2);
  transform: scale(1.15);
}

.classes__media--soon::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(17,17,17,.45);
}

.classes__soon-label,
.classes__soon-title {
  position: relative;
  z-index: 1;
}

.classes__soon-label {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,.8);
}

.classes__soon-title {
  font-size: 32px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--white);
}

.classes__stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.classes__stat {
  font-size: 44px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.classes__stat-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
}

.classes__desktop { display: none; }

.classes__details {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.classes__bullets {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
}

.classes__bullets li {
  display: flex;
  gap: 10px;
}

.classes__bullets li::before {
  content: "";
  flex-shrink: 0;
  width: 5px;
  height: 5px;
  margin-top: 7px;
  background: var(--ink);
}

.classes__details .btn {
  margin-top: auto;
  padding: 0 18px;
}

.classes__foot {
  margin-top: 89.8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: var(--text);
}

.classes__faq {
  min-height: 44px;
  display: flex;
  align-items: center;
  align-self: flex-start;
  color: var(--ink);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (hover: hover) {
  .classes__item:not(.is-open) .classes__row:hover::before { opacity: 1; }
  .classes__item:not(.is-open) .classes__row:hover .classes__name { transform: translateX(10px); }
}

@media (min-width: 992px) {
  .classes { padding-block: 120px 112px; }

  .classes__head { row-gap: 28px; }
  .classes__title { --col-span: 6; }
  .classes__intro { --col-start: 1; --col-span: 4; }

  .classes__cols,
  .classes__row,
  .classes__body {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
  }

  .classes__cols {
    margin-top: 88px;
    padding-bottom: 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--meta);
  }

  .classes__cols > span { grid-column: span 2; }
  .classes__cols > span:first-child { grid-column: span 6; }
  .classes__cols-end { text-align: right; }

  .classes__list { margin-top: 0; }

  .classes__row {
    height: 104px;
    min-height: 0;
    padding: 0;
  }

  .classes__label,
  .classes__meta,
  .classes__side { display: contents; }

  .classes__num { display: none; }

  .classes__name,
  .classes__format,
  .classes__price,
  .classes__status { grid-row: 1; }

  .classes__name {
    grid-column: 1 / span 6;
    font-size: 40px;
    line-height: normal;
  }

  .classes__format {
    grid-column: 7 / span 2;
    font-size: 15px;
    font-weight: 500;
    color: var(--text);
  }

  .classes__price {
    grid-column: 9 / span 2;
    font-size: 24px;
    letter-spacing: -0.02em;
  }

  .classes__status {
    grid-column: 11 / span 2;
    justify-self: end;
    gap: 12px;
  }

  .classes__icon { width: 18px; height: 18px; }

  .classes__body {
    min-height: 400px;
    padding: 8px 0 40px;
    row-gap: 0;
  }

  .classes__media {
    grid-column: 1 / span 5;
    height: auto;
    min-height: 352px;
  }

  .classes__media img { position: absolute; inset: 0; }

  .classes__tag { left: 12px; bottom: 12px; font-size: 12px; }

  .classes__media--soon { padding: 24px; }
  .classes__soon-label { font-size: 12px; }
  .classes__soon-title { font-size: 44px; }

  .classes__stats {
    grid-column: 7 / span 2;
    display: flex;
    flex-direction: column;
    gap: 40px;
  }

  .classes__stats--spread { justify-content: space-between; gap: 0; }

  .classes__stat { font-size: 64px; }
  .classes__stat-label { font-size: 13px; }
  .classes__desktop { display: inline; }

  .classes__details {
    grid-column: 9 / span 4;
    justify-content: space-between;
  }

  .classes__bullets { gap: 12px; font-size: 15px; }

  .classes__bullets li::before {
    width: 6px;
    height: 6px;
    margin-top: 8px;
  }

  .classes__details .btn { padding: 0 20px; }

  .classes__foot {
    margin-top: 102.9px;
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
  }

  .classes__foot p { grid-column: 1 / span 6; }

  .classes__faq {
    grid-column: 10 / span 3;
    justify-self: end;
    min-height: 0;
  }
}

/* Results (§5.3), dark
   Click/tap-only tabs. The active student's quote, band caption and photo
   are shown; quotes slide ±14px in the direction of travel (.is-before /
   .is-after), photos wipe up with clip-path.
   ========================================================================== */

.results {
  padding-block: 72px 64px;
  line-height: normal;
}

.results__body {
  margin-top: 48px;
  display: flex;
  flex-direction: column;
}

.results__left {
  display: flex;
  flex-direction: column;
}

.results__band {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.results__band-num {
  font-size: 132px;
  line-height: .8;
  font-weight: 800;
  letter-spacing: -0.06em;
  color: var(--yellow);
}

.results__band-of {
  padding-top: 4px;
  font-size: 18px;
  font-weight: 700;
}

.results__band-label { display: none; }

/* Captions that swap in place (desktop band label, mobile photo caption) */
.results__band-label span,
.results__caption span {
  position: absolute;
  left: 0;
  opacity: 0;
  transition: opacity .5s ease;
}

.results__band-label span.is-active,
.results__caption span.is-active { opacity: 1; }

.results__tabs {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
}

.results__tab {
  width: 100%;
  min-height: 60px;
  border-top: 1px solid rgba(246,243,235,.18);
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  opacity: .45;
  transition: opacity .4s ease;
}

.results__tab:last-child { border-bottom: 1px solid rgba(246,243,235,.18); }
.results__tab[aria-selected="true"] { opacity: 1; }

.results__marker {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  background: var(--yellow);
  transform: scale(0);
  transition: transform .45s var(--ease);
}

.results__tab[aria-selected="true"] .results__marker { transform: none; }

.results__name {
  flex-grow: 1;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.results__type {
  font-size: 12px;
  font-weight: 600;
  text-align: right;
  white-space: nowrap;
}

.results__desktop { display: none; }

.results__right {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* All quotes share one grid cell, so the block is as tall as the longest */
.results__quotes { display: grid; }

/* Phones: the design reserves 330px for the longest quote; wider layouts
   size to the text so tablets don't get a gap under shorter quotes */
@media (max-width: 767px) {
  .results__quotes { min-height: 330px; }
}

.results__quote {
  grid-area: 1 / 1;
  font-size: 19px;
  line-height: 1.45;
  font-weight: 600;
  letter-spacing: -0.01em;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .6s ease, transform .8s var(--ease);
}

.results__quote.is-before { transform: translateY(-14px); }
.results__quote.is-active { opacity: 1; transform: none; }

.results__foot {
  display: flex;
  flex-direction: column;
}

.results__who {
  display: flex;
  align-items: flex-end;
  gap: 16px;
}

.results__photos {
  position: relative;
  flex-shrink: 0;
  width: 88px;
  height: 110px;
  overflow: hidden;
  background: #222222;
}

.results__photos img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1);
  clip-path: inset(100% 0 0 0);
  transition: clip-path .8s var(--ease);
}

.results__photos img.is-active { clip-path: inset(0 0 0 0); }

.results__hint { display: none; }

.results__caption {
  position: relative;
  flex-grow: 1;
  height: 40px;
  font-size: 13px;
  font-weight: 600;
  color: var(--on-dark-muted);
}

.results__caption span { bottom: 0; }

/* The design's CTA ends in an empty arrow slot after the gap (10px mobile,
   12px desktop); keep that offset so the label sits where it's drawn. */
.results__cta.btn {
  margin-top: 124.4px;
  padding: 0 28px 0 18px;
}

@media (min-width: 992px) {
  .results { padding-block: 120px 112px; }

  /* 6 of 12 columns */
  .results__title { width: calc(50% - var(--col-gap) / 2); }

  .results__body {
    margin-top: 88px;
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
  }

  .results__left {
    grid-column: 1 / span 5;
    justify-content: space-between;
  }

  .results__band { gap: 12px; }
  .results__band-num { font-size: 220px; }
  .results__band-of { padding-top: 8px; font-size: 24px; }

  .results__band-label {
    display: block;
    position: relative;
    margin-top: 20px;
    height: 20px;
    font-size: 14px;
    font-weight: 600;
    color: var(--on-dark-muted);
  }

  .results__band-label span { top: 0; }

  .results__tab {
    height: 72px;
    min-height: 0;
    gap: 16px;
  }

  .results__marker { width: 10px; height: 10px; }
  .results__name { font-size: 24px; }
  .results__type { font-size: 14px; }
  .results__desktop { display: inline; }
  .results__mobile { display: none; }

  .results__right {
    grid-column: 7 / span 6;
    margin-top: 0;
    gap: 0;
  }

  .results__quotes { min-height: 380px; }

  .results__quote {
    font-size: 27px;
    line-height: 1.38;
  }

  .results__foot {
    margin-top: 104.4px;
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
  }

  .results__who { gap: 20px; }
  .results__photos { width: 132px; height: 164px; }

  .results__hint {
    display: block;
    font-size: 13px;
    line-height: 1.5;
    font-weight: 500;
    color: var(--on-dark-muted);
  }

  .results__caption { display: none; }

  .results__cta.btn {
    margin-top: 0;
    padding: 0 34px 0 22px;
  }
}

/* How it works (§5.4)
   The step crossing the middle of the viewport is active (js sets
   --how-active on [data-how] and data-state="past|active|next" on every
   [data-how-index]). Desktop: sticky numeral roll + title + segments.
   Mobile/tablet: vertical timeline with dots and a fill line.
   ========================================================================== */

.how {
  --how-active: 0;
  padding-block: 72px 64px;
  line-height: normal;
}

.how__head { row-gap: 16px; }
.how__intro { line-height: 1.5; }

.how__body { margin-top: 48px; }

.how__aside { display: none; }

.how__steps {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 44px;
}

/* Timeline track and fill (fill scales to active / 4) */
.how__steps::before,
.how__steps::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 10px;
  bottom: 120px;
  width: 2px;
  background: var(--line-soft);
}

.how__steps::after {
  background: var(--ink);
  transform: scaleY(calc(var(--how-active) / 4));
  transform-origin: 50% 0;
  transition: transform .8s var(--ease);
}

.how__step {
  position: relative;
  z-index: 1;
  padding-left: 36px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  opacity: .3;
  transition: opacity .6s ease;
}

.how__step[data-state="past"] { opacity: .55; }
.how__step[data-state="active"] { opacity: 1; }

.how__dot {
  position: absolute;
  left: 0;
  top: 3px;
  width: 14px;
  height: 14px;
  border: 2px solid var(--ink);
  background: var(--bg);
}

.how__dot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--ink);
  opacity: 0;
  transition: opacity .5s ease;
}

.how__step:not([data-state="next"]) .how__dot::after { opacity: 1; }

.how__step-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.how__num {
  position: relative;
  font-size: 12px;
  font-weight: 600;
}

/* 44px touch target */
.how__num::after {
  content: "";
  position: absolute;
  inset: -15px -12px;
}

.how__tag {
  padding: 2px 7px;
  background: #ebe6da;
  font-size: 11px;
  font-weight: 600;
}

.how__step-title {
  font-size: 26px;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.035em;
}

.how__step-text {
  font-size: 15px;
  line-height: 1.5;
  font-weight: 500;
  color: var(--text);
}

/* The design's CTA ends in an empty arrow slot after a 12px gap */
.how__cta.btn {
  margin-top: 8px;
  padding: 0 32px 0 20px;
}

@media (min-width: 992px) {
  .how { padding-block: 120px; }

  .how__head { row-gap: 28px; }
  .how__title { --col-span: 9; }
  .how__intro { --col-start: 1; --col-span: 4; }

  .how__body {
    margin-top: 96px;
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
    align-items: start;
  }

  .how__aside {
    grid-column: 1 / span 5;
    position: sticky;
    top: 96px;
    display: flex;
    flex-direction: column;
    gap: 20px;
  }

  .how__roll {
    height: 200px;
    overflow: hidden;
  }

  .how__roll-track {
    transform: translateY(calc(var(--how-active) * -200px));
    transition: transform .8s var(--ease);
  }

  .how__roll-track span {
    display: block;
    height: 200px;
    font-size: 220px;
    line-height: 200px;
    font-weight: 800;
    letter-spacing: -0.06em;
  }

  .how__aside-title {
    position: relative;
    height: 34px;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.02em;
  }

  .how__aside-title span {
    position: absolute;
    left: 0;
    top: 0;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .5s ease, transform .7s var(--ease);
  }

  .how__aside-title span[data-state="past"] { transform: translateY(-10px); }
  .how__aside-title span[data-state="active"] { opacity: 1; transform: none; }

  .how__segments {
    max-width: 440px;
    display: flex;
    gap: 6px;
  }

  .how__segments span {
    position: relative;
    flex-grow: 1;
    height: 3px;
    background: var(--line-soft);
  }

  .how__segments span::after {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--ink);
    opacity: 0;
    transition: opacity .5s ease;
  }

  .how__segments span:not([data-state="next"])::after { opacity: 1; }

  .how__aside-meta {
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
  }

  .how__steps {
    grid-column: 7 / span 6;
    gap: 0;
  }

  .how__steps::before,
  .how__steps::after,
  .how__dot { display: none; }

  .how__step {
    min-height: 280px;
    padding: 24px 0 0;
    border-top: 1px solid var(--ink);
    gap: 16px;
  }

  .how__num {
    min-height: 44px;
    font-size: 13px;
  }

  .how__num::after { content: none; }

  .how__tag {
    padding: 3px 8px;
    font-size: 12px;
  }

  .how__step-title { font-size: 40px; }

  .how__step-text {
    max-width: 520px;
    font-size: 18px;
  }

  .how__cta.btn {
    margin-top: 16px;
    align-self: flex-start;
  }
}

/* Reduced motion: every step at full opacity */
@media (prefers-reduced-motion: reduce) {
  .how__step,
  .how__step[data-state] { opacity: 1; }
}

/* Team (§5.5), dark
   Photos wipe up on reveal ([data-reveal="wipe"]). Desktop hover: the
   hovered photo scales to 1.045, the other cards dim to .5 (no underline
   bar). Mobile/tablet: scroll-snap carousel of 280px cards.
   ========================================================================== */

.team {
  padding: 72px 0 64px;
  line-height: normal;
}

.team__head {
  padding-inline: var(--gutter);
  row-gap: 16px;
}

.team__intro {
  font-size: 15px;
  line-height: 1.5;
  font-weight: 500;
  color: var(--on-dark-muted);
}

.team__cards {
  margin-top: 40px;
  padding: 0 20px 4px;
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-left: 20px;
  scrollbar-width: none;
}

.team__cards::-webkit-scrollbar { display: none; }

.team__card {
  flex-shrink: 0;
  width: 280px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  gap: 18px;
  transition: opacity .5s ease;
}

.team__photo {
  height: 340px;
  overflow: hidden;
  background: var(--surface-dark);
}

.team__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1);
  transition: transform 1.4s var(--ease);
}

.team__info {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.team__who {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.team__name {
  font-size: 22px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.team__role {
  font-size: 14px;
  font-weight: 600;
  color: var(--on-dark-muted);
}

.team__link {
  min-height: 48px;
  padding-top: 4px;
  display: flex;
  align-items: flex-start;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.team__swipe {
  margin-top: 20px;
  padding-inline: 20px;
  font-size: 12px;
  font-weight: 600;
  color: var(--on-dark-muted);
}

/* Reveal: photos wipe up (clip-path) while the image settles 1.12 → 1 */
.js [data-reveal="wipe"] {
  opacity: 1;
  transform: none;
  clip-path: inset(100% 0 0 0);
  transition: clip-path 1.2s var(--ease) var(--reveal-delay, 0s);
}

.js [data-reveal="wipe"] img { transform: scale(1.12); }
.js [data-reveal="wipe"].is-revealed { clip-path: inset(0 0 0 0); }
.js [data-reveal="wipe"].is-revealed img { transform: none; }

@media (min-width: 992px) {
  .team { padding: 120px var(--gutter) 112px; }

  .team__head {
    padding-inline: 0;
    align-items: end;
  }

  .team__title { --col-span: 6; }

  .team__intro {
    --col-start: 10;
    --col-span: 3;
    text-align: right;
  }

  .team__cards {
    margin-top: 88px;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    overflow: visible;
  }

  .team__card { width: auto; }
  .team__photo { height: 560px; }
  .team__name { font-size: 28px; }
  .team__swipe { display: none; }
}

@media (min-width: 992px) and (hover: hover) {
  .team__cards:has(.team__card:hover) .team__card:not(:hover) { opacity: .5; }

  .team__card:hover .team__photo img,
  .js .team__card:hover [data-reveal="wipe"].is-revealed img { transform: scale(1.045); }
}

@media (prefers-reduced-motion: reduce) {
  .js [data-reveal="wipe"] { clip-path: none; }
  .js [data-reveal="wipe"] img { transform: none; }
}

/* FAQs (§5.6)
   Collapsible accordion: first item open, one at a time, the open one can
   be closed. Answer opens with grid-template-rows over .65s and fades in.
   Desktop: sticky intro column (cols 1-4) + list (cols 6-12).
   Mobile: stacked, "Contact us" after the list.
   ========================================================================== */

.faq {
  padding-block: 72px 64px;
  line-height: normal;
}

.faq__body {
  display: flex;
  flex-direction: column;
}

.faq__aside { display: contents; }

.faq__title {
  font-size: var(--fs-h2);
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.045em;
}

.faq__intro {
  margin-top: 16px;
  line-height: 1.5;
}

/* The design's mobile CTA ends in an empty arrow slot after a 10px gap */
.faq__cta.btn {
  order: 1;
  margin-top: 40px;
  padding: 0 28px 0 18px;
}

.faq__list {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
}

.faq__rule {
  height: 1px;
  background: var(--ink);
}

.faq__heading {
  font: inherit;
  --reveal-dur: .8s;
}

.faq__q {
  width: 100%;
  min-height: 72px;
  padding: 18px 0;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  text-align: left;
}

.faq__q-text {
  flex-grow: 1;
  font-size: 17px;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: -0.015em;
  transition: transform .5s var(--ease);
}

.faq__icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 4px;
  transition: transform .5s var(--ease);
}

.faq__item.is-open .faq__icon { transform: rotate(45deg); }

.faq__a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .65s var(--ease);
}

.faq__item.is-open .faq__a { grid-template-rows: 1fr; }

.faq__clip {
  min-height: 0;
  overflow: hidden;
}

.faq__a-text {
  padding: 0 8px 24px 38px;
  font-size: 15px;
  line-height: 1.55;
  font-weight: 500;
  color: var(--text);
  opacity: 0;
  transition: opacity .5s ease .1s;
}

.faq__item.is-open .faq__a-text { opacity: 1; }

@media (hover: hover) {
  .faq__item:not(.is-open) .faq__q:hover .faq__q-text { transform: translateX(8px); }
}

@media (min-width: 992px) {
  .faq { padding-block: 120px 112px; }

  .faq__body {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
    align-items: start;
  }

  .faq__aside {
    grid-column: 1 / span 4;
    position: sticky;
    top: 96px;
    display: flex;
    flex-direction: column;
    gap: 28px;
  }

  .faq__title {
    font-size: 64px;
    line-height: .98;
  }

  .faq__intro {
    margin-top: 0;
    max-width: 340px;
  }

  .faq__cta.btn {
    align-self: flex-start;
    margin-top: 0;
    padding: 0 20px;
  }

  .faq__list {
    grid-column: 6 / span 7;
    margin-top: 0;
  }

  .faq__q { padding: 22px 0; }
  .faq__q-text { font-size: 22px; }
  .faq__icon { width: 20px; height: 20px; }

  .faq__a-text {
    padding: 0 40px 28px 56px;
    font-size: 17px;
  }
}

/* Closing CTA (§5.7) — #start, form block #resource
   Mailchimp form + a whimsical composition. The composition is drawn at
   660×600 and sized in --u (1/660 of its container), so the mobile version
   is the same art at the container's width. Pieces enter with a spring
   (scale .7, rotate r-10deg → rest, staggered per the design's LAY array);
   on desktop they follow the pointer by --px/--py * depth * 14px.
   ========================================================================== */

.closing {
  padding-block: 72px 56px;
  background: var(--yellow-pale);
  line-height: normal;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.closing__main {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.closing__title {
  font-size: clamp(58px, 52.8px + 1.3333vw, 72px);
  line-height: .94;
  font-weight: 800;
  letter-spacing: -0.05em;
}

/* Mobile: one masked line each, sliding up on reveal */
.closing__line {
  display: block;
  overflow: hidden;
  padding-bottom: .06em;
}

.closing__line > span { display: block; }

.js [data-reveal="line"] {
  opacity: 1;
  transform: translateY(110%);
  transition: transform 1.1s var(--ease) var(--reveal-delay, 0s);
}

.closing__underline {
  background-image: linear-gradient(var(--ink), var(--ink));
  background-repeat: no-repeat;
  background-position: 0 92%;
  background-size: 100% .1em;
}

.js .closing__underline {
  background-size: 0% .1em;
  transition: background-size 1s var(--ease) .55s;
}

.js .is-revealed .closing__underline { background-size: 100% .1em; }

.closing__intro {
  font-size: 16px;
  line-height: 1.5;
  font-weight: 500;
  color: var(--text);
}

.closing__form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.closing__fields {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.closing__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.closing__field label {
  font-size: 13px;
  font-weight: 600;
}

.closing__field input {
  width: 100%;
  height: 56px;
  padding: 0 16px;
  border: 0;
  border-radius: 0;
  background: var(--white);
  font-size: 15px;
}

.closing__hp {
  position: absolute;
  left: -5000px;
}

.closing__submit.btn {
  margin-top: 6px;
  height: 58px;
  padding: 0 22px;
  font-size: 16px;
}

.closing__consent {
  font-size: 12px;
  color: var(--muted);
}

/* Composition */
.closing__art-wrap {
  margin-top: 12px;
  align-self: center;
  width: min(350px, 100%);
  container-type: inline-size;
}

.closing__art {
  --u: calc(100cqw / 660);
  --px: 0;
  --py: 0;
  position: relative;
  height: calc(603.43 * var(--u)); /* drawn 350×320 on mobile */
}

.js [data-reveal="art"] {
  opacity: 1;
  transform: none;
  transition: none;
}

.closing__piece {
  position: absolute;
  left: calc(var(--x, 0) * var(--u));
  top: calc(var(--y, 0) * var(--u));
  transform:
    translate(calc(var(--px) * var(--d) * 14px), calc(var(--py) * var(--d) * 14px))
    rotate(var(--r));
  transition:
    transform 1.1s var(--ease-spring) var(--delay),
    opacity .8s ease var(--delay);
}

.js .closing__art:not(.is-revealed) .closing__piece {
  opacity: 0;
  transform: rotate(calc(var(--r) - 10deg)) scale(.7);
}

.closing__art.is-moving .closing__piece {
  transition:
    transform .7s var(--ease),
    opacity .8s ease var(--delay);
}

.closing__circle {
  --x: 70; --y: 10;
  width: calc(270 * var(--u));
  height: calc(270 * var(--u));
  border-radius: 50%;
  background: var(--yellow);
}

.closing__quarter {
  left: auto;
  top: auto;
  right: 0;
  bottom: calc(20 * var(--u));
  width: calc(240 * var(--u));
  height: calc(240 * var(--u));
  border-radius: calc(240 * var(--u)) 0 0 0;
  background: var(--white);
}

.closing__card-pos { --x: 210; --y: 80; }

.closing__card {
  width: calc(300 * var(--u));
  height: calc(390 * var(--u));
  padding: calc(26 * var(--u));
  display: flex;
  flex-direction: column;
  gap: calc(20 * var(--u));
  background: var(--white);
  box-shadow: 0 calc(30 * var(--u)) calc(60 * var(--u)) calc(-24 * var(--u)) rgba(17,17,17,.35);
}

.closing__card-top {
  display: flex;
  justify-content: space-between;
  font-size: calc(11 * var(--u));
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}

.closing__card-title {
  font-size: calc(30 * var(--u));
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.closing__card-sec {
  display: flex;
  flex-direction: column;
  gap: calc(8 * var(--u));
}

.closing__card-label {
  position: relative;
  font-size: calc(14 * var(--u));
  font-weight: 700;
}

.closing__card-label--hl { isolation: isolate; }

.closing__card-label--hl::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: calc(-4 * var(--u));
  top: calc(6 * var(--u));
  width: calc(150 * var(--u));
  height: calc(12 * var(--u));
  background: var(--yellow);
  opacity: .9;
}

.closing__bar {
  display: block;
  height: calc(6 * var(--u));
  background: var(--skeleton);
}

.closing__stamp {
  --x: 450; --y: 40;
  width: calc(128 * var(--u));
  height: calc(128 * var(--u));
  border-radius: 50%;
  background: var(--ink);
  color: var(--yellow);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.closing__stamp-num {
  font-size: calc(44 * var(--u));
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.closing__stamp-band {
  font-size: calc(11 * var(--u));
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--bg);
}

.closing__chip {
  padding: calc(8 * var(--u)) calc(16 * var(--u));
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--white);
  font-size: calc(15 * var(--u));
  font-weight: 700;
  white-space: nowrap;
}

.closing__sparkle {
  width: calc(var(--s) * var(--u));
  height: calc(var(--s) * var(--u));
  fill: var(--ink);
}

.closing__sparkle--yellow { fill: var(--yellow); }

@media (min-width: 992px) {
  .closing {
    padding-block: 120px;
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
    align-items: center;
  }

  .closing__main {
    grid-column: 1 / span 5;
    gap: 28px;
  }

  /* Desktop: one heading that wraps naturally, no line masks */
  .closing__title { padding-bottom: .06em; }
  .closing__line,
  .closing__line > span { display: inline; overflow: visible; padding: 0; }
  .closing__underline,
  .js .closing__underline { background: none; }

  .closing__intro {
    max-width: 460px;
    font-size: 18px;
  }

  .closing__fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  /* The design's submit ends in an empty arrow slot after a 10px gap */
  .closing__submit.btn { padding: 0 32px 0 22px; }

  .closing__art { height: calc(600 * var(--u)); }

  .closing__art-wrap {
    grid-column: 7 / span 6;
    justify-self: end;
    margin-top: 0;
    width: min(660px, 100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .js [data-reveal="line"] { transform: none; }
  .js .closing__underline { background-size: 100% .1em; }
  .js .closing__art:not(.is-revealed) .closing__piece { opacity: 1; transform: rotate(var(--r)); }
}

/* Footer (§5.7)
   ========================================================================== */

.footer {
  padding: 56px var(--gutter) 24px;
  display: flex;
  flex-direction: column;
  line-height: normal;
}

.footer__top {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 16px;
}

.footer__brand {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Keeps the line box of the drawn 24px text wordmark (29px), so the
   blurb and everything below sit where the design has them */
.footer__logo {
  align-self: flex-start;
  min-height: 29px;
  display: flex;
  align-items: center;
}

.footer__logo img { width: 120px; }

.footer__blurb {
  font-size: 14px;
  line-height: 1.5;
  color: var(--on-dark-muted);
}

.footer__col {
  margin-top: 36px;
  display: flex;
  flex-direction: column;
}

.footer__label {
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--meta);
}

.footer__link {
  align-self: flex-start;
  min-height: 40px;
  display: flex;
  align-items: center;
  font-size: 15px;
  font-weight: 500;
}

@media (hover: hover) {
  .footer__link:hover { text-decoration: underline; text-underline-offset: 4px; }
}

.footer__totop {
  grid-column: 1 / -1;
  margin-top: 28px;
  justify-self: start;
  min-height: 44px;
  display: flex;
  align-items: center;
  font-size: 14px;
  font-weight: 600;
}

.footer__arrow {
  width: 30px;
  height: 30px;
  border: 1px solid var(--bg);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform .4s var(--ease);
}

.footer__mark {
  margin-top: 76.2px;
  overflow: hidden;
}

.footer__mark img { width: 100%; }

.js [data-reveal="mark"] {
  opacity: 1;
  transform: none;
  transition: none;
}

.js [data-reveal="mark"] img {
  transform: translateY(100%);
  transition: transform 1.4s var(--ease);
}

.js [data-reveal="mark"].is-revealed img { transform: none; }

.footer__bar {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(246,243,235,.18);
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--on-dark-muted);
}

@media (min-width: 992px) {
  .footer { padding: 80px var(--gutter) 32px; }

  .footer__top {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--col-gap);
    align-items: start;
  }

  .footer__brand { grid-column: 1 / span 4; gap: 12px; }
  .footer__blurb { max-width: 300px; }

  .footer__col {
    grid-column: 7 / span 2;
    margin-top: 0;
    gap: 4px;
  }

  .footer__col + .footer__col { grid-column: 9 / span 2; }
  .footer__label { margin-bottom: 8px; }
  .footer__link { min-height: 32px; }

  .footer__totop {
    grid-column: 11 / span 2;
    grid-row: 1;
    justify-self: end;
    margin-top: 0;
  }

  /* Drawn lifted 4px; hover lifts it further */
  .footer__arrow {
    width: 32px;
    height: 32px;
    transform: translateY(-4px);
  }

  .footer__mark { margin-top: 47.9px; }

  .footer__bar {
    margin-top: 24px;
    padding-top: 20px;
    flex-direction: row;
    justify-content: space-between;
    font-size: 13px;
  }
}

@media (min-width: 992px) and (hover: hover) {
  .footer__totop:hover .footer__arrow { transform: translateY(-8px); }
}

@media (prefers-reduced-motion: reduce) {
  .js [data-reveal="mark"] img { transform: none; }
}

/* Reduced motion: render the settled state, no motion
   ========================================================================== */

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

  .js [data-reveal],
  .js [data-reveal="rule"] {
    opacity: 1;
    transform: none;
  }
}
