/* SoloRep site. The page has its own look: a dim blue-grey ground, near-white
   ink, a cyan accent and red for the one action (Join the beta). The app appears
   only as real screenshots, shown like product shots on the page. Hairlines and
   soft shadows, no glows. */

@font-face {
  font-family: "Barlow Condensed";
  font-style: italic;
  font-weight: 900;
  font-display: swap;
  src: url("/fonts/barlow-condensed-latin-900-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-style: italic;
  font-weight: 800;
  font-display: swap;
  src: url("/fonts/barlow-condensed-latin-800-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/barlow-condensed-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Press Start 2P";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/press-start-2p-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/inter-latin-wght-normal.woff2") format("woff2");
}

/* Metric-matched fallbacks, so the poster headline and body text hold their
   line breaks and height while the real faces load. */
@font-face {
  font-family: "Barlow Condensed Fallback";
  font-style: italic;
  font-weight: 900;
  src: local("Arial Bold Italic"), local("Arial-BoldItalicMT");
  size-adjust: 77.3%;
  ascent-override: 129.3%;
  descent-override: 25.9%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Barlow Condensed Fallback";
  font-style: italic;
  font-weight: 800;
  src: local("Arial Bold Italic"), local("Arial-BoldItalicMT");
  size-adjust: 75.9%;
  ascent-override: 131.8%;
  descent-override: 26.4%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Barlow Condensed Fallback";
  font-style: normal;
  font-weight: 700;
  src: local("Arial Bold"), local("Arial-BoldMT");
  size-adjust: 76.5%;
  ascent-override: 130.7%;
  descent-override: 26.2%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Inter Fallback";
  font-style: normal;
  font-weight: 100 900;
  src: local("Arial"), local("ArialMT");
  size-adjust: 107.6%;
  ascent-override: 90%;
  descent-override: 22.4%;
  line-gap-override: 0%;
}

/* Dim ground (owner pick, 2026-10-04): a dark page lighter than the app.
   Contrast on the ground: ink 13.0, muted 8.4, accent 9.0; on the band: muted 6.7,
   accent 7.2. The red label on the button is 3.7, so it stays large bold text. */
:root {
  color-scheme: dark;

  --ground: oklch(28% 0.026 262);
  --band: oklch(34% 0.030 262);
  --card: oklch(31% 0.030 262);
  --ink: oklch(96% 0.008 262);
  --muted: oklch(82% 0.020 262);
  --hairline: oklch(40% 0.030 262);
  --hairline-strong: oklch(52% 0.040 262);
  --accent: oklch(83% 0.110 210);
  --accent-soft: oklch(38% 0.050 225);
  --heat: oklch(63% 0.235 27);
  --on-heat: oklch(98.5% 0.008 27);
  --heat-shadow: oklch(63% 0.235 27 / 0.3);
  --grey: oklch(36% 0.022 262);
  --grey-line: oklch(50% 0.030 262);
  --device: oklch(14% 0.030 265);       /* phone bezel around the real screenshots */
  --shadow: oklch(10% 0.030 265 / 0.55);
  --wash: oklch(40% 0.070 250 / 0.35);

  --font-display: "Barlow Condensed", "Barlow Condensed Fallback", "Arial Narrow", sans-serif;
  --font-body: "Inter", "Inter Fallback", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-pixel: "Press Start 2P", ui-monospace, monospace;

  /* Type scale, ratio 1.25 from 17px */
  --step-0: 1.0625rem;
  --step-1: 1.328rem;
  --step-3: 2.075rem;
  --step-4: 2.594rem;
  --step-6: 4.054rem;

  --pad: 20px;
}

@media (min-width: 720px) {
  :root { --pad: 32px; }
}
@media (min-width: 1100px) {
  :root { --pad: 48px; }
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(90% 520px at 50% 0, var(--wash), transparent 75%) no-repeat,
    var(--ground);
  color: var(--ink);
  font: 400 var(--step-0) / 1.55 var(--font-body);
  -webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }
img { display: block; max-width: 100%; height: auto; }
p { margin: 0; max-width: 62ch; }
h1, h2, h3 { margin: 0; font-weight: 400; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: var(--accent); text-underline-offset: 4px; }
a:hover { color: var(--ink); }

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

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* Illustrations that look like UI but are not controls. */
.mock { pointer-events: none; user-select: none; -webkit-user-select: none; }

.page {
  width: 100%;
  max-width: 1320px;
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* ---------- Header ---------- */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding-block: 14px;
}
.brand {
  display: inline-flex; align-items: center; gap: 12px; min-height: 44px;
  color: var(--ink); text-decoration: none;
}
.brand img { width: 40px; height: 40px; border-radius: 6px; }
.wordmark {
  font-family: var(--font-display); font-weight: 900; font-style: italic;
  font-size: 1.9rem; line-height: 1;
}
.head-join {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 6px;
  font: 600 0.9375rem / 1 var(--font-body); color: var(--accent); text-decoration: none;
  box-shadow: inset 0 0 0 1.5px var(--accent);
}
.head-join:hover { color: var(--ink); background: var(--accent-soft); }

/* ---------- Shared type ---------- */
.kicker {
  font-family: var(--font-pixel); font-size: 12px; line-height: 1.7; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--accent);
}

/* Poster headline. Phones: four short lines, big. From 640px: two lines that
   run the full width. --fit is the widest line in em at that layout. */
.h1 {
  --fit: 4.4;
  font-family: var(--font-display); font-weight: 900; font-style: italic;
  font-size: clamp(2.6rem, calc((100vw - 2 * var(--pad)) / var(--fit)), 6.5rem);
  line-height: 0.92;
  color: var(--ink);
}
.h1 .old, .h1 .new, .h1 .hl { display: block; }
.h1 .old { font-size: 0.8em; line-height: 1; margin-bottom: 0.03em; color: var(--muted); }
.h1.is-shared { --fit: 3.55; }
.h1.is-shared .old { font-size: 0.55em; }
.h1.is-lost { --fit: 3.4; }

.h2 {
  font-family: var(--font-display); font-weight: 900; font-style: italic;
  font-size: clamp(var(--step-4), 1.5rem + 4vw, var(--step-6));
  line-height: 0.96;
}
.h2 span { display: block; }
.h2 .old { color: var(--muted); }

.lede {
  font-size: clamp(1.125rem, 1rem + 0.55vw, var(--step-1));
  line-height: 1.45;
  color: var(--muted);
}

@media (min-width: 640px) {
  .h1 {
    --fit: 6.9;
    font-size: clamp(3.4rem, calc((100vw - 2 * var(--pad)) / var(--fit)), 11rem);
  }
  .h1 .hl { display: inline; }
  .h1.is-shared { --fit: 6.9; }
  .h1.is-lost { --fit: 6.1; font-size: clamp(3.4rem, calc((100vw - 2 * var(--pad)) / var(--fit)), 9rem); }
}
@media (min-width: 1100px) {
  .h1 { font-size: clamp(5rem, min(calc((100vw - 2 * var(--pad)) / var(--fit)), 26svh), 11rem); }
}

/* ---------- Actions ---------- */
.cta { display: grid; gap: 14px; max-width: 420px; }
.beta { display: grid; gap: 8px; }

.join {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 60px; padding: 0 28px; border-radius: 6px;
  background: var(--heat); color: var(--on-heat);
  font-family: var(--font-display); font-weight: 800; font-style: italic;
  font-size: 1.625rem; line-height: 1; text-decoration: none;
  box-shadow: 0 8px 18px -10px var(--heat-shadow);
}
.join:hover { color: var(--on-heat); box-shadow: 0 12px 22px -10px var(--heat-shadow); }
.join svg { width: 22px; height: 22px; flex: none; }

.beta-note { font-size: 0.875rem; line-height: 1.5; color: var(--muted); }
.beta-note a {
  display: inline-flex; align-items: center; min-height: 44px;
  overflow-wrap: anywhere; max-width: 100%;
}

.downloads { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.store {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  min-height: 56px; padding: 8px 12px; border: 0; border-radius: 6px;
  background: var(--grey); color: var(--muted);
  font: 600 0.9375rem / 1.2 var(--font-body); text-align: center; text-decoration: none;
  box-shadow: inset 0 0 0 1px var(--grey-line);
}
.store small { font-size: 0.75rem; font-weight: 500; color: var(--muted); }
.store:disabled { cursor: not-allowed; }
a.store { color: var(--ink); }
a.store:hover { background: var(--band); color: var(--ink); }

/* The quiet "Already have SoloRep?" button on the shared-link page */
.button {
  display: flex; align-items: center; justify-content: center; min-height: 48px; padding: 8px 16px;
  border-radius: 6px; font: 600 0.9375rem / 1.2 var(--font-body); text-align: center; text-decoration: none;
  color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent);
}
.button:hover { color: var(--ink); background: var(--accent-soft); }

/* ---------- Kai ---------- */
/* Integer scales only: the sprite is 92px, shown at 2x or 3x, cropped to the
   figure so it stands exactly where it is placed. */
.kai {
  --k: 2;
  position: relative; display: block; flex: none; overflow: hidden;
  width: calc(52px * var(--k)); height: calc(78px * var(--k));
  pointer-events: none; user-select: none; -webkit-user-select: none;
}
.kai img {
  position: absolute; max-width: none;
  left: calc(-20px * var(--k)); top: calc(-5px * var(--k));
  width: calc(92px * var(--k)); height: calc(92px * var(--k));
  image-rendering: pixelated;
}
/* Kai standing on the top edge of the thing next to it */
.perch {
  position: absolute; z-index: 1; right: 40px;
  bottom: calc(100% - var(--k) * 1px + 1px);
}

/* ---------- Real app screenshots, shown like product shots ---------- */
.phone-wrap { position: relative; width: 100%; }
.phone {
  padding: 6px; border-radius: 30px; background: var(--device);
  box-shadow:
    0 0 0 1px var(--hairline-strong),
    0 28px 48px -26px var(--shadow),
    0 4px 10px -4px var(--shadow);
}
.screen {
  position: relative; display: block; overflow: hidden; border-radius: 24px;
  aspect-ratio: 720 / 1280; background: oklch(17% 0.02 265);
}
.screen img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 0; -webkit-user-drag: none;
}
.screen.is-top { aspect-ratio: 720 / 920; }
.screen.is-lifts { aspect-ratio: 720 / 660; }
.screen.is-lifts img { object-position: 50% 66.6%; }

/* ---------- Page-look cards (illustrations, not app screens) ---------- */
.card {
  position: relative; display: flow-root; border-radius: 14px; background: var(--card); color: var(--ink);
  box-shadow: 0 0 0 1px var(--hairline), 0 18px 36px -22px var(--shadow);
}
.card-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px 0; }
.card-kicker {
  flex: none; font-family: var(--font-pixel); font-size: 12px; line-height: 1.6; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--accent);
}
.card-rule { flex: 1; min-width: 8px; height: 1px; background: var(--hairline-strong); }
.card-meta { flex: none; font-size: 0.75rem; color: var(--muted); }
.card-body { padding: 14px 18px 18px; }
.cname {
  font-family: var(--font-display); font-weight: 800; font-style: italic;
  font-size: var(--step-3); line-height: 0.98; color: var(--ink);
}
.wmeta {
  margin-top: 6px; font-size: 0.875rem; line-height: 1.4; color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.outline-btn {
  display: flex; align-items: center; justify-content: center; height: 48px; margin-top: 16px;
  border-radius: 8px; color: var(--accent);
  font-family: var(--font-display); font-style: italic; font-weight: 800; font-size: 1.375rem;
  box-shadow: inset 0 0 0 1.5px var(--accent);
}

/* ---------- Hero ---------- */
.hero { display: grid; gap: 20px; padding-block: 14px 40px; }
.hero-copy { display: grid; gap: 22px; align-content: start; }

/* ---------- The move: saved video to workout ---------- */
.move {
  --clip-w: 140px;
  display: grid; grid-template-columns: minmax(0, 1fr); justify-items: start;
  margin-top: 8px;
}
.move .phone-wrap { max-width: 360px; }
.example-note { margin-top: 10px; font-size: 0.8125rem; color: var(--muted); }

/* The saved reel: a still life of a loaded barbell on a rack, built in CSS,
   with the platform label as text. All sizes are in cqw of the card width. */
.clip {
  position: relative; container-type: inline-size;
  width: var(--clip-w); aspect-ratio: 9 / 16; overflow: hidden; border-radius: 14px;
  background: radial-gradient(130% 62% at 50% 34%, oklch(33% 0.075 268) 0%, oklch(19% 0.05 272) 48%, oklch(9% 0.03 275) 100%);
  box-shadow:
    0 0 0 1px var(--hairline-strong),
    0 24px 40px -24px var(--shadow);
}
.clip > span { position: absolute; display: block; }
.reel-glow {
  left: 50%; top: 106cqw; width: 98cqw; height: 18cqw; transform: translateX(-50%);
  background: radial-gradient(closest-side, oklch(62% 0.16 272 / 0.5), transparent);
  filter: blur(1.5cqw);
}
.reel-floor {
  left: 0; right: 0; top: 111cqw; bottom: 0;
  background: linear-gradient(oklch(16% 0.04 273), oklch(8% 0.028 275));
  box-shadow: inset 0 0.35cqw 0 oklch(58% 0.09 272 / 0.55);
}
.reel-post {
  top: 42cqw; height: 69.5cqw; width: 4.6cqw; border-radius: 0.8cqw 0.8cqw 0 0;
  background:
    repeating-linear-gradient(180deg, transparent 0 3.2cqw, oklch(10% 0.03 275 / 0.9) 3.2cqw 4.2cqw),
    linear-gradient(90deg, oklch(22% 0.035 270), oklch(40% 0.05 270) 42%, oklch(19% 0.03 270));
}
.reel-post.is-l { left: 27.7cqw; }
.reel-post.is-r { left: 67.7cqw; }
.reel-bar {
  left: -2cqw; right: -2cqw; top: 60.8cqw; height: 2.4cqw;
  background: linear-gradient(180deg, oklch(80% 0.02 270), oklch(50% 0.025 270) 45%, oklch(28% 0.025 270));
}
.reel-plates {
  top: 62cqw; transform: translateY(-50%); display: flex; align-items: center; gap: 0.5cqw;
}
.reel-plates.is-l { right: 74cqw; flex-direction: row-reverse; }
.reel-plates.is-r { left: 74cqw; }
.reel-plates i {
  display: block; border-radius: 0.9cqw;
  background: linear-gradient(90deg, oklch(24% 0.035 270), oklch(46% 0.05 270) 38%, oklch(21% 0.03 270));
  box-shadow: inset 0 0.5cqw 0 oklch(74% 0.12 272 / 0.55), inset 0 -0.4cqw 0 oklch(10% 0.03 275 / 0.6);
}
.reel-plates i:nth-child(1) { width: 5cqw; height: 46cqw; }
.reel-plates i:nth-child(2) { width: 4.2cqw; height: 34cqw; }
.reel-plates i:nth-child(3) { width: 3.4cqw; height: 23cqw; }
.reel-top {
  left: 0; right: 0; top: 0; height: 28cqw;
  background: linear-gradient(oklch(6% 0.03 275 / 0.7), transparent);
}
.reel-bottom {
  left: 0; right: 0; bottom: 0; height: 52cqw;
  background: linear-gradient(transparent, oklch(6% 0.03 275 / 0.88));
}
.clip-src {
  top: 7cqw; left: 7cqw;
  padding: 0.42em 0.8em; border-radius: 999px;
  font: 600 max(11px, 8.2cqw) / 1 var(--font-body); color: oklch(96% 0.012 270);
  background: oklch(9% 0.03 275 / 0.78);
  box-shadow: inset 0 0 0 1px oklch(43% 0.075 273);
}
.clip-play {
  left: 50%; top: 99cqw; width: 22cqw; aspect-ratio: 1;
  transform: translate(-50%, -50%); display: grid; place-items: center; border-radius: 50%;
  color: oklch(96% 0.012 270);
  background: oklch(96% 0.012 270 / 0.16);
  box-shadow: inset 0 0 0 1.5px oklch(96% 0.012 270 / 0.55);
}
.clip-play svg { width: 9cqw; height: 9cqw; margin-left: 1cqw; }
.reel-text {
  left: 7cqw; right: 7cqw; bottom: 17cqw;
  font: 600 max(11px, 8cqw) / 1.25 var(--font-body); color: oklch(96% 0.012 270);
  text-shadow: 0 1px 2px oklch(5% 0.03 275 / 0.85);
}
.clip-scrub {
  left: 7cqw; right: 7cqw; bottom: 8cqw; height: 1.8cqw; border-radius: 1cqw;
  background: oklch(45% 0.04 270 / 0.6);
}
.clip-scrub::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 38%; border-radius: 1cqw;
  background: oklch(96% 0.012 270);
}

/* The bridge between the two halves. Vertical on phones, horizontal from 600px. */
.bridge {
  --line: var(--hairline-strong);
  position: relative; display: flex; align-items: center; gap: 14px;
  height: 72px; padding-left: calc(var(--clip-w) / 2 - 1px);
}
.move .bridge { --line: var(--accent); }
.bridge-rail {
  position: relative; align-self: stretch; flex: none; width: 2px; border-radius: 1px;
  background: var(--line);
}
.bridge-rail::after {
  content: ""; position: absolute; left: 50%; bottom: 1px; width: 10px; height: 10px;
  border-right: 2px solid var(--line); border-bottom: 2px solid var(--line);
  transform: translate(-50%, 0) rotate(45deg);
}
.bridge-label { font-size: 0.8125rem; font-weight: 600; line-height: 1.3; color: var(--muted); text-wrap: balance; }

@media (min-width: 600px) {
  .move:not(.is-link) {
    --clip-w: 150px;
    grid-template-columns: var(--clip-w) minmax(96px, 1fr) minmax(0, 300px);
    align-items: center; justify-items: stretch; max-width: 720px;
  }
  .move:not(.is-link) .bridge {
    flex-direction: column-reverse; justify-content: center; align-items: stretch;
    height: auto; padding: 0 8px; gap: 10px; text-align: center;
  }
  .move:not(.is-link) .bridge-rail { align-self: auto; width: auto; height: 2px; }
  .move:not(.is-link) .bridge-rail::after {
    left: auto; right: 0; top: 50%; bottom: auto;
    transform: translate(0, -50%) rotate(-45deg);
  }
  .move:not(.is-link) .phone-wrap { margin-top: 156px; }
}
@media (min-width: 720px) {
  .move.is-link {
    --clip-w: 190px;
    grid-template-columns: var(--clip-w) minmax(96px, 1fr) minmax(0, 300px);
    align-items: center; justify-items: stretch; max-width: 720px;
  }
  .move.is-link .bridge {
    flex-direction: column-reverse; justify-content: center; align-items: stretch;
    height: auto; padding: 0 8px; gap: 10px; text-align: center;
  }
  .move.is-link .bridge-rail { align-self: auto; width: auto; height: 2px; }
  .move.is-link .bridge-rail::after {
    left: auto; right: 0; top: 50%; bottom: auto;
    transform: translate(0, -50%) rotate(-45deg);
  }
  .move.is-link .phone-wrap { margin-top: 156px; }
}

/* A friend's message holding the share link */
.bubble {
  position: relative; display: grid; gap: 6px; width: min(100%, 320px);
  padding: 12px 16px; border-radius: 18px 18px 18px 4px; background: var(--band);
  box-shadow: inset 0 0 0 1px var(--hairline-strong);
}
.bubble p { font-size: 1rem; line-height: 1.35; color: var(--ink); }
.bubble-link { font-size: 0.9375rem; color: var(--accent); text-decoration: underline; text-underline-offset: 4px; overflow-wrap: anywhere; }

/* ---------- One line for the lifter who already logs ---------- */
.vet {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 20px;
  padding: 20px 22px; border-radius: 12px; background: var(--band);
}
.vet p { color: var(--muted); }

/* ---------- Loop ---------- */
.loop { padding-block: clamp(56px, 9vw, 112px) clamp(8px, 2vw, 24px); }
.loop-head { display: grid; gap: 14px; padding-bottom: clamp(8px, 2vw, 24px); }

.step {
  display: grid; gap: 28px; padding-block: 48px;
  border-top: 1px solid var(--hairline);
}
.step-copy { display: grid; gap: 12px; align-content: center; }
.step-kicker {
  font-family: var(--font-pixel); font-size: 12px; line-height: 1.6; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--accent);
}
.step h3 {
  font-family: var(--font-display); font-weight: 800; font-style: italic;
  font-size: clamp(var(--step-3), 1.4rem + 2.2vw, var(--step-4)); line-height: 1;
  text-wrap: balance;
}
.step-copy p { color: var(--muted); }
.step-vis { display: grid; justify-items: center; min-width: 0; }
.step-vis > .card, .step-vis > .share, .step-vis > .phone-wrap { width: 100%; max-width: 440px; }

.srcline { margin-top: 14px; font-size: 0.875rem; color: var(--muted); }
.srcline .is-on { color: var(--accent); font-weight: 700; }

.field-label { font-size: 0.875rem; font-weight: 500; color: var(--muted); margin-bottom: 8px; }
.field {
  display: flex; align-items: center; min-height: 52px; padding: 0 14px; border-radius: 8px;
  background: var(--ground); font-size: 1rem; color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--hairline-strong); overflow: hidden; white-space: nowrap;
}
.field::after { content: ""; flex: none; width: 2px; height: 22px; margin-left: 3px; background: var(--ink); }

/* Kai on a ground rail under the step copy */
.stage {
  display: flex; justify-content: flex-end; align-items: flex-end; margin-top: 12px;
  border-bottom: 2px solid var(--hairline-strong);
}
.stage .kai { margin-right: 16px; margin-bottom: calc(var(--k) * -1px); }

/* Set logging: the real screen with plain callouts. */
.moment { display: grid; gap: 24px; justify-items: center; }
.moment .phone-wrap { width: min(100%, 336px); }
.notes { width: min(100%, 336px); display: grid; }
.notes li { padding-block: 14px; border-top: 1px solid var(--hairline); }
.notes b { display: block; font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; line-height: 1.2; color: var(--ink); }
.notes span { display: block; margin-top: 2px; font-size: 0.9375rem; line-height: 1.45; color: var(--muted); }

@media (max-width: 429px) {
  .moment .phone-wrap { width: 100%; }
  .notes { width: 100%; }
}

/* Sharing: a message and the card it opens. */
.share { display: grid; justify-items: stretch; }
.share-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; }
.share-top .bubble { flex: 1; min-width: 0; max-width: 300px; }
.share .bridge { height: 56px; padding-left: 24px; }

/* ---------- Closing ---------- */
.close { padding-block: clamp(32px, 6vw, 64px) clamp(56px, 9vw, 120px); }
.panel {
  position: relative; display: flow-root; border-radius: 16px; background: var(--band);
  box-shadow: 0 0 0 1px var(--hairline), 0 24px 40px -28px var(--shadow);
}
.close-panel { --s: 2; margin-top: calc(78px * var(--s)); }
.close-panel .kai-stand {
  --k: var(--s);
  position: absolute; z-index: 1; right: calc(14px * var(--s));
  bottom: calc(100% - var(--s) * 1px + 1px);
}
.close-body { display: grid; gap: 20px; padding: 14px 18px 26px; }
.close-body .cta { margin-top: 4px; }
.close-panel .store { background: var(--card); }

/* ---------- Shared-link and 404 pages ---------- */
.next { padding-block: clamp(8px, 2vw, 24px) clamp(48px, 8vw, 96px); }
.next ol { counter-reset: next; }
.next li {
  display: grid; gap: 8px; padding-block: 22px; border-top: 1px solid var(--hairline);
  counter-increment: next;
}
.next .step-kicker { display: block; }
.next .step-kicker::before { content: "Step " counter(next); }
.next h3 {
  margin-top: 6px; font-family: var(--font-display); font-weight: 800; font-style: italic;
  font-size: var(--step-3); line-height: 1;
}
.next p { color: var(--muted); }
.lost { display: grid; gap: 22px; align-content: start; padding-block: 14px clamp(48px, 9vw, 96px); }
.lost .cta { max-width: 320px; }

/* ---------- Footer ---------- */
.foot {
  border-top: 1px solid var(--hairline); padding-block: 20px 44px;
  color: var(--muted); font-size: 0.875rem;
}
.foot nav { display: flex; flex-wrap: wrap; gap: 0 28px; }
.foot a {
  display: inline-flex; align-items: center; min-height: 44px; max-width: 100%;
  overflow-wrap: anywhere; color: var(--muted);
}
.foot a:hover { color: var(--ink); }
.foot p { margin-top: 6px; }

@media (max-width: 359px) {
  .card-meta { display: none; }
}

/* ---------- Wider screens ---------- */
@media (min-width: 720px) {
  .close-panel { --s: 3; }
  .close-body { padding: 18px 36px 36px; }
}

@media (min-width: 900px) {
  .next li { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: 32px; align-items: center; padding-block: 32px; }
  .step {
    grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 32px; align-items: center;
    padding-block: 88px;
  }
  .step-copy { grid-column: 1 / span 5; }
  .step-vis { grid-column: 7 / span 6; }
  .step.is-flip .step-copy { grid-column: 8 / span 5; grid-row: 1; }
  .step.is-flip .step-vis { grid-column: 1 / span 6; grid-row: 1; }

  .close-body {
    grid-template-columns: minmax(0, 1fr) minmax(0, 420px);
    grid-template-areas: "title cta" "lede cta";
    column-gap: 64px; row-gap: 16px; align-items: center;
  }
  .close-body .h2 { grid-area: title; align-self: end; }
  .close-body .lede { grid-area: lede; align-self: start; }
  .close-body .cta { grid-area: cta; margin-top: 0; }
}

@media (min-width: 1100px) {
  .step.is-wide .step-copy { grid-column: 1 / span 4; }
  .step.is-wide .step-vis { grid-column: 5 / span 8; }
  .moment {
    grid-template-columns: 336px minmax(0, 1fr); column-gap: 52px; justify-items: stretch; align-items: stretch;
    width: 100%;
  }
  .moment .phone-wrap { width: 336px; }
  .notes { position: relative; display: block; width: auto; }
  .notes li {
    position: absolute; left: 0; width: 100%; max-width: 260px;
    padding: 0; border-top: 0; transform: translateY(-50%);
  }
  .notes li:nth-child(1) { top: 22.8%; }
  .notes li:nth-child(2) { top: 51.5%; }
  .notes li:nth-child(3) { top: 80%; }
  .notes li::before {
    content: ""; position: absolute; right: 100%; top: 50%; width: 52px; height: 2px; margin-top: -1px;
    background: var(--accent);
  }
  .notes li::after {
    content: ""; position: absolute; right: calc(100% + 46px); top: 50%; width: 8px; height: 8px; margin-top: -4px;
    border-radius: 50%; background: var(--accent);
  }

  .hero {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    grid-template-areas:
      "kick kick"
      "title title"
      "copy move";
    column-gap: 56px; row-gap: 24px; align-items: center; padding-block: 20px 64px;
  }
  .hero > .kicker { grid-area: kick; }
  .hero > .h1 { grid-area: title; }
  .hero > .hero-copy { grid-area: copy; }
  .hero > .move { grid-area: move; margin-top: 0; max-width: none; --clip-w: clamp(140px, 11.5vw, 168px); }
  .hero > .move.is-link { --clip-w: clamp(176px, 14vw, 200px); }
}

/* ---------- Motion: one orchestrated page load, nothing else ---------- */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  @keyframes rise { from { opacity: 0; transform: translateY(14px); } }
  @keyframes draw-x { from { transform: scale(0, 1); } }
  @keyframes draw-y { from { transform: scale(1, 0); } }

  .hero > .kicker, .hero > .h1, .hero-copy, .lost > * { animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
  .hero > .h1 { animation-delay: 0.08s; }
  .hero-copy { animation-delay: 0.2s; }
  .clip, .move .bubble { animation: rise 0.6s 0.35s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
  .move .bridge-rail { transform-origin: top center; animation: draw-y 0.45s 0.8s ease-out backwards; }
  .move .phone-wrap { animation: rise 0.6s 1.1s cubic-bezier(0.22, 1, 0.36, 1) backwards; }

  .join { transition: transform 0.15s ease, box-shadow 0.15s ease; }
  .join:hover { transform: translateY(-1px); }
  .join:active { transform: translateY(0); }
}
@media (prefers-reduced-motion: no-preference) and (min-width: 600px) {
  .move:not(.is-link) .bridge-rail { transform-origin: left center; animation-name: draw-x; }
}
@media (prefers-reduced-motion: no-preference) and (min-width: 720px) {
  .move.is-link .bridge-rail { transform-origin: left center; animation-name: draw-x; }
}
