/* Sock Tumble landing, variant "The Laundry Cycle".
   Scrolling runs one load: Wash (sky), Tumble (pink), Pair (coral), Fold (grape), Put away (mint).
   Bands meet at a clothesline; the sticky washer dial tracks the stage. Mobile-first. */

:root {
  --bar: 64px;
  --peg-src: url("/assets/props/clothesline.webp");
}

html { scroll-padding-top: calc(var(--bar) + env(safe-area-inset-top) + 12px); }
@media (min-width: 960px) { html { scroll-padding-top: calc(var(--bar) + env(safe-area-inset-top) + 40px); } }
body { background: var(--mint-deep); }

/* ================================================================
   Control panel (sticky top bar) and the cycle dial
   ================================================================ */
.panel {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 8px;
  height: calc(var(--bar) + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) max(12px, env(safe-area-inset-right)) 0 max(12px, env(safe-area-inset-left));
  background: var(--cream);
  border-bottom: 4px solid var(--ink);
  box-shadow: 0 5px 0 rgb(43 36 64 / 0.16);
}

.panel-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
  text-decoration: none;
  color: var(--ink);
}
.panel-brand img {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 3px solid var(--ink);
}
.panel-brand span {
  display: none;
  font-family: var(--font-display);
  font-size: 1.35rem;
  line-height: 1;
}

/* The dial. Pointer angles (0deg = grip vertical, clockwise): the top is the "off" gap,
   the programme runs from lower left round to lower right. */
.dial {
  --turn: -125deg;
  --now: var(--sky);
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  flex: 1 1 auto;
  justify-content: center;
}
.dial[data-stage="1"] { --turn: -70deg; --now: var(--pink); }
.dial[data-stage="2"] { --turn: 60deg; --now: var(--coral); }
.dial[data-stage="3"] { --turn: 100deg; --now: var(--grape); }
.dial[data-stage="4"] { --turn: 130deg; --now: var(--mint); }

.knob {
  position: relative;
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  filter: drop-shadow(0 3px 0 rgb(43 36 64 / 0.35));
}
.knob img { width: 100%; height: 100%; }
.knob-cap {
  position: absolute;
  inset: 0;
  transform: rotate(var(--turn));
  /* the click-turn: a quick overshoot that settles, like a detent catching */
  transition: transform 0.75s cubic-bezier(0.3, 1.75, 0.45, 1);
}
/* pointer notch on the grip's top end, so the bar reads one way */
.knob-cap::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 27%;
  width: 11%;
  height: 11%;
  translate: -50% -50%;
  border-radius: 50%;
  background: var(--ink);
  box-shadow: 0 0 0 1.5px rgb(255 255 255 / 0.85);
}
.dial.thunk .knob { animation: thunk 0.32s var(--ease-out); }
@keyframes thunk {
  0% { transform: scale(1); }
  35% { transform: scale(0.92) rotate(-3deg); }
  100% { transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .knob-cap { transition: none; }
  .dial.thunk .knob { animation: none; }
}

/* Legend: a programme list, not tabs. Tick in the band colour, name in ink when current. */
.stages { display: flex; gap: 2px; margin: 0; }
.stages a {
  display: inline-flex;
  align-items: center;
  gap: 0.62em;
  min-height: 26px;
  padding: 2px;
  font-family: var(--font-display);
  font-size: 1rem;
  line-height: 1;
  white-space: nowrap;
  color: #655d80;               /* 5.3:1 on cream */
  text-decoration: none;
  border-radius: 6px;
  transition: color 0.25s;
}
.stages a::before {
  content: "";
  width: 12px;
  height: 12px;
  flex: none;
  border-radius: 50%;
  background: var(--c);
  border: 2px solid var(--ink);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s;
}
.stages a:hover { color: var(--ink); }
.stages a[aria-current] {
  color: var(--ink);
  -webkit-text-stroke: 0.035em var(--ink);
}
.stages a[aria-current]::before {
  transform: scale(1.25);
  box-shadow: 0 0 0 2px var(--cream), 0 0 0 4px var(--ink);
}

/* The compact stage read-out (below desktop, JS only): current name beside the knob. */
.dial-now:not([hidden]) {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  min-height: 44px;
  padding: 0 4px;
  font-family: var(--font-display);
  font-size: 1.08rem;
  line-height: 1;
  white-space: nowrap;
  color: var(--ink);
  background: none;
  border: 0;
  cursor: pointer;
}
.dial-now::before {
  content: "";
  width: 12px;
  height: 12px;
  flex: none;
  border-radius: 50%;
  background: var(--now);
  border: 2px solid var(--ink);
  transition: background-color 0.45s;
}
.dial-now::after {
  content: "";
  width: 0.42em;
  height: 0.42em;
  border-right: 3px solid var(--ink);
  border-bottom: 3px solid var(--ink);
  transform: translateY(-0.15em) rotate(45deg);
  transition: transform 0.25s var(--ease-out);
}
.dial-now[aria-expanded="true"]::after { transform: translateY(0.1em) rotate(-135deg); }

.panel-cta {
  flex: none;
  font-size: 0.9rem;
  padding: 0.5em 0.8em 0.45em;
}

/* Below desktop. No JS: knob + a strip of legend links you can scroll sideways.
   Once the script reveals the read-out, the legend folds into its drop-down. */
@media (max-width: 959.98px) {
  .stages {
    min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 4px 2px;
    gap: 10px;
  }
  .stages::-webkit-scrollbar { display: none; }

  .dial-now:not([hidden]) ~ .stages {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    translate: -50% 0;
    width: min(240px, calc(100vw - 24px));
    flex-direction: column;
    gap: 2px;
    padding: 12px 16px;
    background: var(--cream);
    border: 4px solid var(--ink);
    border-radius: 22px;
    box-shadow: 0 6px 0 var(--ink), 0 20px 40px -12px rgb(43 36 64 / 0.5);
  }
  .dial.open .dial-now:not([hidden]) ~ .stages { display: flex; }
  .dial-now:not([hidden]) ~ .stages a { font-size: 1.3rem; min-height: 44px; gap: 0.55em; width: 100%; }
}

/* Desktop: the knob sits on a dial plate that hangs just below the bar; the legend fans round it. */
@media (min-width: 960px) {
  .panel { padding-inline: max(var(--gutter), env(safe-area-inset-right)) max(var(--gutter), env(safe-area-inset-left)); gap: 16px; }
  .dial {
    --cx: 150px;
    --cy: 42px;
    position: relative;
    flex: none;
    width: 300px;
    height: 60px;
    align-self: flex-start;
    margin-top: env(safe-area-inset-top);
    margin-inline: auto;
  }
  .dial::before {
    content: "";
    position: absolute;
    left: 6px;
    right: 6px;
    top: 56px;
    height: 36px;
    background: var(--cream);
    border: 4px solid var(--ink);
    border-top: 0;
    border-radius: 0 0 34px 34px;
    box-shadow: 0 5px 0 rgb(43 36 64 / 0.16);
  }
  .knob {
    position: absolute;
    width: 80px;
    height: 80px;
    left: calc(var(--cx) - 40px);
    top: calc(var(--cy) - 40px);
    cursor: pointer;
  }
  .stages { position: absolute; inset: 0; display: block; }
  .stages li {
    position: absolute;
    top: calc(var(--cy) + var(--ty) * 1px);
    left: calc(var(--cx) + var(--tx) * 1px - 8px);
    translate: 0 -50%;
  }
  .stages li.l { left: auto; right: calc(100% - var(--cx) - var(--tx) * 1px - 8px); }
  .stages li.l a { flex-direction: row-reverse; }
  .panel-cta { font-size: 1.05rem; padding: 0.55em 1.05em 0.5em; align-self: center; }
  .dial-now:not([hidden]) { display: none; }
}
@media (min-width: 1120px) {
  .panel-brand span { display: inline; }
  .panel-brand img { width: 42px; height: 42px; }
}
/* ================================================================
   Bands
   ================================================================ */
.band {
  position: relative;
  overflow-x: clip;               /* props bleed sideways and get clipped; vertical stays open for the seams */
  color: var(--ink);
  scroll-margin-top: 34px;          /* added to the html scroll-padding so the clothesline shows after a jump */
  --s: 0.28;                        /* clothesline scale, shared by seams, pegged tags and the theme line */
  --rx: 50%;
  --ry: 40%;
  --ray-a: 0.13;
  --ray-r: 62%;
}
/* soft sunburst rays */
.band::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-conic-gradient(from 4deg at var(--rx) var(--ry), rgb(255 255 255 / var(--ray-a)) 0deg 7deg, transparent 7deg 18deg);
  -webkit-mask-image: radial-gradient(circle at var(--rx) var(--ry), #000 0, transparent var(--ray-r));
  mask-image: radial-gradient(circle at var(--rx) var(--ry), #000 0, transparent var(--ray-r));
}
.band > .inner,
.wash {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding-inline: var(--gutter);
}

.band-title {
  font-size: clamp(2.7rem, 11vw, 5.6rem);
  text-transform: uppercase;
}
.band p { max-width: 62ch; }
.band > .tag-row + .inner { margin-top: clamp(36px, 5vw, 60px); }

/* ---------------- Seams: the clothesline across each band top ---------------- */
@media (min-width: 760px) { .band { --s: 0.34; } }
@media (min-width: 1180px) { .band { --s: 0.38; } }
.seam {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(var(--s) * -250px);   /* the rope sits right on the colour boundary */
  height: calc(var(--s) * 357px);
  pointer-events: none;
}
.seam::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background: var(--peg-src) repeat-x;
  background-size: calc(var(--s) * 2400px) auto;
  background-position: 50% calc(var(--s) * -199px);
  filter: drop-shadow(0 5px 0 rgb(43 36 64 / 0.22));
}
.pin {
  position: absolute;
  z-index: 1;
  top: calc(var(--s) * 238px);
  left: calc(50% + var(--at) * var(--s) * 1px);
  translate: -50% 0;
  transform-origin: 50% 0;
}
.pin--far, .pin--wide { display: none; }
@media (min-width: 560px) { .pin--wide { display: block; } .pin--mobile { display: none; } }
@media (min-width: 1180px) { .pin--far { display: block; } }
/* tablet: the tags hang centred, so keep the middle pegs clear of the caption */
@media (min-width: 760px) and (max-width: 1179.98px) { .pin--near { display: none; } }

/* The band heading IS the pegged tag: stage name on top, the section heading under it.
   It hangs from a peg of the seam line (the row is centred on the band, then nudged to a peg). */
.tag-row {
  position: relative;
  z-index: 1;
  width: fit-content;
  max-width: calc(100vw - 24px);
  margin: calc(var(--s) * -12px) auto 0;
  translate: calc(var(--at-m, var(--at)) * var(--s) * 1px) 0;
}
@media (min-width: 1180px) { .tag-row { translate: calc(var(--at) * var(--s) * 1px) 0; } }
.tag {
  display: grid;
  justify-items: center;
  font-weight: 400;
  text-align: center;
}
/* the pegged plate: number + stage word */
.tag-plate {
  display: flex;
  align-items: center;
  gap: 0.25em;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 6.4vw, 2.7rem);
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  white-space: nowrap;
  color: var(--ink);
  background: var(--yellow);
  border: 4px solid var(--ink);
  border-radius: 16px;
  padding: calc(var(--s) * 132px + 2px) 0.5em 0.3em 0.4em;
  box-shadow: 0 6px 0 var(--ink);
  rotate: -2.5deg;
  transform-origin: 50% 0;
}
.band--pair .tag-plate, .band--away .tag-plate { rotate: 2deg; }
.tag-no {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 1.2em;
  height: 1.2em;
  font-size: 0.55em;
  border-radius: 50%;
  background: var(--white);
  border: 3px solid var(--ink);
  padding-top: 0.08em;
}
/* the caption hangs from the plate, overlapping its lower edge: the App Store caption look */
.tag-cap {
  position: relative;
  display: block;
  margin-top: -0.16em;
  font-size: clamp(2.75rem, 12.5vw, 5.6rem);
  text-transform: uppercase;
  max-width: min(12ch, calc(100vw - 2 * var(--gutter)));
  rotate: -1.5deg;
}
.band--pair .tag-cap, .band--away .tag-cap { rotate: 1.5deg; }
.tag--big .tag-cap { font-size: clamp(3.1rem, 14vw, 6.6rem); max-width: 10ch; }

.sock {
  width: calc(var(--s) * 290px);
  max-width: none;
  rotate: 4deg;
  transform-origin: 50% 0;
  filter: drop-shadow(0 8px 0 rgb(43 36 64 / 0.2));
}
.sock--flip { scale: -1 1; rotate: -4deg; }
.sock--side { width: calc(var(--s) * 360px); rotate: 62deg; translate: 22% 0; }
.sock--boxers, .sock--shirt { width: calc(var(--s) * 380px); rotate: -2deg; }

/* ================================================================
   1. WASH: hero
   ================================================================ */
.band--wash {
  --rx: 72%;
  --ry: 48%;
  --ray-a: 0.16;
  --ray-r: 70%;
  background: radial-gradient(125% 100% at 32% 42%, #6fd2ff 0%, #5cc8ff 34%, #4fb2f9 72%, #47a3f6 100%);
  padding-bottom: 82px;
}
.wash {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "word" "promise" "art" "copy";
  padding-top: clamp(18px, 4vw, 28px);
}
.wordmark {
  grid-area: word;
  position: relative;
  z-index: 1;
  font-size: clamp(3.8rem, 18.5vw, 6.4rem);
  line-height: 0.86;
  text-transform: uppercase;
  letter-spacing: 0.015em;
}
.wordmark span { display: block; }
.wm-tumble { rotate: -2.5deg; transform-origin: 0 50%; margin-top: 0.02em; }
.promise {
  grid-area: promise;
  position: relative;
  z-index: 1;
  margin-top: 0.4em;
  font-size: clamp(1.55rem, 7vw, 2.2rem);
}
.promise .pop { white-space: nowrap; }

.wash-art {
  grid-area: art;
  position: relative;
  width: min(70%, 380px);
  justify-self: end;
  margin: -8px calc(-1 * var(--gutter) - 4px) 0 0;
}
.burst {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 14px 0 rgb(43 36 64 / 0.16));
}
.bubbles {
  position: absolute;
  width: 18%;
  left: 2%;
  top: 4%;
  opacity: 0.9;
}

.wash-copy { grid-area: copy; }
.wash .lede {
  font-size: clamp(1.06rem, 0.98rem + 0.45vw, 1.28rem);
  font-weight: 700;
  max-width: 38ch;
}
.cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  margin-top: 1.3rem;
}
.cta .store { font-size: 1.08rem; }
.band .cta .fineprint { max-width: 30ch; }

/* socks flying out of the hero and across the seam */
.fly {
  position: absolute;
  z-index: 3;
  width: clamp(78px, 10vw, 140px);
  pointer-events: none;
  filter: drop-shadow(0 10px 0 rgb(43 36 64 / 0.2));
}
.fly--a { display: none; right: 1%; bottom: -58px; rotate: 22deg; }
.fly--b { left: 1%; bottom: -40px; rotate: -28deg; width: clamp(66px, 8vw, 120px); }
.fly--c { right: 1%; bottom: -42px; rotate: 16deg; width: clamp(62px, 7vw, 110px); }
@media (min-width: 760px) {
  .fly--a { display: block; }
  .fly--b { left: 9%; bottom: -52px; }
  .fly--c { right: auto; left: 63%; bottom: -44px; }
}
@media (prefers-reduced-motion: no-preference) {
  .fly--a { animation: drift-a 7s ease-in-out infinite; }
  .fly--b { animation: drift-b 8.5s ease-in-out infinite; }
  .fly--c { animation: drift-a 9.5s ease-in-out -3s infinite; }
}
@keyframes drift-a { 50% { transform: translate(-10px, -14px) rotate(-6deg); } }
@keyframes drift-b { 50% { transform: translate(8px, -10px) rotate(7deg); } }

@media (min-width: 600px) and (max-width: 899.98px) {
  .wash {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "word word" "promise art" "copy art";
    grid-template-rows: auto auto 1fr;
  }
  .wash-art { width: 118%; max-width: none; margin: -56px calc(-1 * var(--gutter) - 2vw) 0 5%; justify-self: start; align-self: start; }
  .wash-copy { margin-top: 1rem; }
}
@media (min-width: 900px) {
  .wash {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
    grid-template-areas: "word art" "promise art" "copy art";
    grid-template-rows: auto auto 1fr;
    align-content: center;
    min-height: clamp(540px, calc(100svh - var(--bar) - 156px), 700px);
    padding-top: clamp(28px, 4vw, 56px);
  }
  .band--wash { padding-bottom: 104px; }
  .wordmark { font-size: clamp(5.4rem, 10.2vw, 9.6rem); align-self: end; }
  .promise { font-size: clamp(2rem, 2.9vw, 2.75rem); }
  .wash-copy { margin-top: 1.6rem; }
  .wash-art {
    width: 138%;
    max-width: 940px;
    align-self: center;
    justify-self: start;
    margin: -96px 0 -120px -9%;
  }
}

/* ================================================================
   2. TUMBLE: how to play
   ================================================================ */
.band--tumble {
  --rx: 30%;
  --ry: 46%;
  background: radial-gradient(120% 85% at 55% 40%, #ff80bf 0%, #ff6fb5 48%, #f45ba5 100%);
  padding: 0 0 clamp(110px, 12vw, 160px);
}
.tumble {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "copy" "phones" "spin";
  gap: 40px;
}
.tumble-copy { grid-area: copy; }
.tumble-copy .band-title { font-size: clamp(2.7rem, 11vw, 4.7rem); }
.tumble-phones {
  grid-area: phones;
  display: grid;
  justify-items: center;
  padding: 10px 0 20px;
}
.tumble-phones .phone { grid-area: 1 / 1; margin: 0; }
.phone--front { width: min(270px, 64vw); rotate: -5deg; translate: -14% 0; }
.phone--back { width: min(225px, 52vw); rotate: 8deg; translate: 34% 9%; box-shadow: var(--shadow-lift); }

.steps {
  display: grid;
  gap: 26px;
  margin-top: 28px;
  counter-reset: none;
}
.steps li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 16px;
  align-items: start;
}
.step-no {
  grid-row: span 2;
  font-family: var(--font-display);
  font-size: 3.6rem;
  line-height: 0.9;
  color: var(--yellow);
  -webkit-text-stroke: 0.1em var(--ink);
  paint-order: stroke fill;
  text-shadow: 0 0.07em 0 var(--ink);
  min-width: 0.75em;
  text-align: center;
}
.steps h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.55rem, 1.2rem + 1.2vw, 2rem);
  line-height: 1.05;
}
.band .steps p { margin-top: 4px; max-width: 44ch; }

.spin {
  grid-area: spin;
  position: relative;
}
.spin-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.45rem, 1.1rem + 1.1vw, 1.9rem);
  line-height: 1.1;
}
.spin-list {
  margin-top: 14px;
  column-gap: 40px;
}
.spin-list li {
  position: relative;
  padding-left: 30px;
  max-width: 48ch;
  margin-bottom: 10px;
  break-inside: avoid;
}
.spin-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.32em;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--yellow);
  border: 3px solid var(--ink);
}

@media (min-width: 900px) {
  .tumble {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    grid-template-areas: "phones copy" "spin spin";
    column-gap: clamp(32px, 5vw, 80px);
    row-gap: 56px;
    align-items: center;
  }
  .phone--front { width: min(310px, 26vw); }
  .phone--back { width: min(250px, 21vw); }
  .spin-list { columns: 2; }
  .spin {
    padding-top: 30px;
    border-top: 4px dashed rgb(43 36 64 / 0.55);
  }
}

/* ================================================================
   3. PAIR: two modes
   ================================================================ */
.band--pair {
  --rx: 50%;
  --ry: 34%;
  background: radial-gradient(120% 90% at 50% 38%, #ff9a70 0%, #ff8a5c 45%, #f6714a 100%);
  padding: 0 0 clamp(120px, 13vw, 170px);
}
.pair .band-title { text-align: center; }
.modes {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 28px;
  margin-top: clamp(28px, 4vw, 48px);
}
.mode {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 14px;
}
.mode-show {
  position: relative;
  margin-bottom: 14px;
}
.mode-show .phone { width: min(240px, 58vw); margin: 0; }
.mode--timed .phone { rotate: -4deg; }
.mode--moves .phone { rotate: 4deg; }
.mode-prop {
  position: absolute;
  width: 52%;
  left: -26%;
  bottom: 4%;
  rotate: -12deg;
  filter: drop-shadow(0 10px 0 rgb(43 36 64 / 0.22));
}
.mode-prop--sock {
  left: auto;
  right: -22%;
  bottom: 8%;
  width: 44%;
  rotate: 14deg;
}
.mode-title { font-size: clamp(1.7rem, 1.2rem + 1.8vw, 2.4rem); max-width: 14ch; }
.band .mode p { max-width: 38ch; }

/* Adventure leads: one wide card above Endless and Moves */
.modes.modes--lead { grid-template-columns: minmax(0, 1fr); }
.mode--adventure .mode-title { max-width: 18ch; }
.band .mode--adventure p { max-width: 46ch; }
/* the sock stack sits low and wide so the map's level bubbles stay visible */
.mode--adventure .mode-prop--sock { right: -32%; bottom: -3%; }
.modes-more {
  margin: clamp(40px, 6vw, 72px) auto 0;
  text-align: center;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 1.1rem + 1.2vw, 2rem);
  line-height: 1.1;
}
.band .mode .fineprint { max-width: 30ch; font-weight: 800; }

.or {
  display: grid;
  place-items: center;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: var(--yellow);
  border: 4px solid var(--ink);
  box-shadow: 0 5px 0 var(--ink);
  font-family: var(--font-display);
  font-size: 2rem;
  line-height: 1;
  padding-top: 4px;
  text-transform: uppercase;
  rotate: -8deg;
}

@media (min-width: 860px) {
  .modes {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: start;
    column-gap: clamp(20px, 3vw, 48px);
  }
  .or { align-self: center; margin-top: -120px; }
  .mode-show .phone { width: min(270px, 24vw); }
}

/* ================================================================
   4. FOLD: power-ups, extras, shop and themes
   ================================================================ */
.band--fold {
  --rx: 50%;
  --ry: 6%;
  --ray-a: 0.07;
  background: radial-gradient(120% 70% at 50% 0%, #744fde 0%, #6643d6 45%, #5b36c9 100%);
  color: var(--white);
  padding: 0 0 0;
}
.fold {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "head" "pile" "phone" "pocket" "shop";
  gap: 36px;
}
.fold-head { grid-area: head; }
.fold .fold-lede {
  margin-top: 16px;
  font-size: clamp(1.06rem, 0.98rem + 0.4vw, 1.25rem);
  font-weight: 700;
  max-width: 44ch;
}

/* the folded stack */
.pile {
  grid-area: pile;
  display: grid;
  gap: 0;
  max-width: 560px;
  width: 100%;
}
.pile li {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-left: var(--x);
  margin-top: -4px;
  padding: 12px 18px 18px 12px;
  background: var(--c);
  color: var(--ink);
  border: 4px solid var(--ink);
  border-radius: 20px;
  box-shadow: inset 0 -9px 0 rgb(43 36 64 / 0.13), 0 5px 0 var(--ink);
  rotate: var(--r);
  position: relative;
}
.pile li:first-child { margin-top: 0; }
.pile img { width: 58px; height: 58px; flex: none; }
.pile p { font-size: 1.02rem; line-height: 1.35; }
.pile b { font-family: var(--font-display); font-weight: 400; font-size: 1.2em; letter-spacing: 0.01em; }

.fold-phone {
  grid-area: phone;
  justify-self: center;
  width: min(240px, 58vw);
  rotate: 5deg;
  margin: 0;
}

/* pocket note: what else lands on the table */
.pocket {
  grid-area: pocket;
  align-self: start;
  background: var(--cream);
  color: var(--ink);
  border: 4px solid var(--ink);
  border-radius: 14px;
  box-shadow: 0 7px 0 var(--ink);
  padding: 22px 20px 12px;
  rotate: -1.2deg;
  position: relative;
  max-width: 520px;
}
.pocket::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 2px dashed rgb(43 36 64 / 0.35);
  border-radius: 8px;
  pointer-events: none;
}
.pocket-title { font-size: clamp(1.5rem, 1.2rem + 1vw, 1.9rem); }
.pocket-list { margin: 12px 0 0; }
.pocket-list div {
  display: grid;
  grid-template-columns: minmax(0, 9.5rem) minmax(0, 1fr);
  gap: 4px 12px;
  align-items: center;
  padding: 10px 0;
  border-top: 2px dashed rgb(43 36 64 / 0.3);
}
.pocket-list dt {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 900;
  line-height: 1.15;
}
.pocket-list dt img { width: 38px; height: 38px; object-fit: contain; flex: none; }
.pocket-list dd { margin: 0; font-size: 0.98rem; line-height: 1.4; }

.shop { grid-area: shop; align-self: center; }
.shop-title { font-size: clamp(2rem, 1.4rem + 2.4vw, 3.2rem); }
.band .shop p {
  margin-top: 14px;
  font-size: clamp(1.06rem, 0.98rem + 0.4vw, 1.22rem);
  font-weight: 700;
  max-width: 40ch;
}

/* themes hanging on a line, same peg scale as the seams. Each item carries its own rope segment
   with a peg at its centre; the peg grips only the phone's top bezel, never the screen. */
.line-wrap {
  position: relative;
  margin-top: clamp(24px, 3vw, 40px);
  padding: 0 0 clamp(120px, 13vw, 170px);
}
.line {
  --w: min(calc(var(--s) * 590px), calc((100vw - 2 * var(--gutter)) / 2 - 2px));
  display: grid;
  grid-template-columns: repeat(2, var(--w));
  justify-content: center;
  row-gap: 30px;
}
.line li {
  position: relative;
  padding-top: calc(var(--s) * 357px - 12px);
}
.line li::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: 0;
  left: 0;
  right: 0;
  height: calc(var(--s) * 357px);
  background: var(--peg-src) no-repeat;
  background-size: calc(var(--s) * 2400px) auto;
  background-position: calc(var(--w) / 2 - var(--s) * 1395px) calc(var(--s) * -199px);
  filter: drop-shadow(0 5px 0 rgb(43 36 64 / 0.25));
  pointer-events: none;
}
.line figure {
  display: grid;
  justify-items: center;
  gap: 14px;
  transform-origin: 50% 0;
  rotate: 2deg;
}
.line li:nth-child(even) figure { rotate: -2.5deg; }
.line .phone {
  width: calc(var(--w) - 30px);
  box-shadow: 0 8px 0 -2px rgb(18 14 31 / 0.9), 0 18px 30px -12px rgb(18 14 31 / 0.6);
}
.line figcaption {
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1;
  color: var(--ink);
  background: var(--cream);
  border: 3px solid var(--ink);
  border-radius: 999px;
  padding: 0.42em 0.8em 0.36em;
  box-shadow: 0 4px 0 var(--ink);
  white-space: nowrap;
}
@media (min-width: 900px) {
  .line { grid-template-columns: repeat(4, var(--w)); }
}
/* the rope ends fade out instead of stopping on a hard edge */
.line li:nth-child(odd)::before {
  -webkit-mask-image: linear-gradient(to right, transparent, #000 34%);
  mask-image: linear-gradient(to right, transparent, #000 34%);
}
.line li:nth-child(even)::before {
  -webkit-mask-image: linear-gradient(to left, transparent, #000 34%);
  mask-image: linear-gradient(to left, transparent, #000 34%);
}
@media (min-width: 900px) {
  .line li:nth-child(n)::before { -webkit-mask-image: none; mask-image: none; }
  .line li:first-child::before {
    -webkit-mask-image: linear-gradient(to right, transparent, #000 34%);
    mask-image: linear-gradient(to right, transparent, #000 34%);
  }
  .line li:last-child::before {
    -webkit-mask-image: linear-gradient(to left, transparent, #000 34%);
    mask-image: linear-gradient(to left, transparent, #000 34%);
  }
}
@media (min-width: 1280px) {
  .line figcaption { font-size: 1.3rem; }
}

@media (min-width: 900px) {
  .fold {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.95fr) minmax(0, 0.7fr);
    grid-template-areas:
      "head head phone"
      "pile pocket phone"
      "shop shop shop";
    column-gap: clamp(24px, 3vw, 48px);
    row-gap: 40px;
    align-items: start;
  }
  .fold-phone { width: min(260px, 100%); align-self: center; }
  .pocket-list div { grid-template-columns: minmax(0, 1fr); }
  .pocket-list dd { padding-left: 46px; }
  .shop { margin-top: 24px; }
}

/* ================================================================
   5. PUT AWAY: closing CTA and FAQ
   ================================================================ */
.band--away {
  --rx: 28%;
  --ry: 30%;
  background: radial-gradient(120% 80% at 30% 22%, #6cefb4 0%, #5be3a6 35%, #34c08b 75%, #1fa77a 100%);
  padding: 0 0 clamp(80px, 10vw, 130px);
}
.away {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "cta" "art" "faq";
  gap: 32px;
}
.away-cta { grid-area: cta; }
.away-title { font-size: clamp(3rem, 13vw, 6.6rem); max-width: 9ch; }
.away-art {
  grid-area: art;
  position: relative;
  width: min(420px, 86vw);
  justify-self: center;
}
.away-basket { position: relative; width: 82%; filter: drop-shadow(0 12px 0 rgb(43 36 64 / 0.2)); }
.away-art { padding-top: 14%; }
.away-sparkle { position: absolute; width: 46%; right: 0; top: -2%; }
.away-stack { position: absolute; width: 36%; right: 2%; bottom: 4%; rotate: 8deg; filter: drop-shadow(0 10px 0 rgb(43 36 64 / 0.2)); }

.faq {
  grid-area: faq;
  margin-top: clamp(24px, 5vw, 64px);
  display: grid;
  gap: 24px;
}
.faq-title { font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3.4rem); }
.faq-list { display: grid; gap: 16px; }
.faq details {
  background: var(--cream);
  border: 4px solid var(--ink);
  border-radius: 18px;
  box-shadow: 0 6px 0 var(--ink);
  rotate: -0.5deg;
}
.faq details:nth-child(even) { rotate: 0.6deg; }
.faq summary {
  position: relative;
  list-style: none;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 1.05rem + 0.5vw, 1.45rem);
  line-height: 1.15;
  padding: 18px 64px 16px 22px;
  border-radius: 14px;
}
.faq summary::-webkit-details-marker { display: none; }
/* drawn open/close mark: two bars in a yellow disc, the cross turns as it opens */
.faq summary::after {
  content: "";
  position: absolute;
  right: 16px;
  top: 50%;
  width: 32px;
  height: 32px;
  margin-top: -16px;
  border-radius: 50%;
  border: 3px solid var(--ink);
  background:
    linear-gradient(var(--ink), var(--ink)) center / 14px 3.5px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 3.5px 14px no-repeat,
    var(--yellow);
  transition: rotate 0.3s var(--ease-out);
}
.faq details[open] summary::after { rotate: 135deg; }
.faq summary:hover::after { background-color: #ffd666; }
.faq details p {
  padding: 0 24px 20px 22px;
  max-width: 62ch;
  font-weight: 600;
}

/* FAQ and Support stack in one grid cell */
.away-more { grid-area: faq; display: grid; gap: clamp(48px, 8vw, 96px); }
.away-more .faq { grid-area: auto; }
.support-contact { font-weight: 700; max-width: 62ch; }
.support-contact a { text-decoration: underline; text-underline-offset: 3px; }

@media (min-width: 900px) {
  .away {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    grid-template-areas: "cta art" "faq faq";
    column-gap: 48px;
    align-items: center;
  }
  .away-art { width: 100%; max-width: 440px; align-self: center; }
  .away-cta { align-self: start; }
  .faq {
    grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr);
    align-items: start;
    column-gap: 48px;
  }
  .faq-title { position: sticky; top: calc(var(--bar) + 32px); }
}
