/* Repz.pro
   Layout idea: one gym session from door to done. Captions sit left, one big stage per scene,
   and every moving picture reads a single number, --p (0 to 1), set by scroll or by entering view. */

@property --p { syntax: '<number>'; inherits: true; initial-value: 1; }

:root {
  --canvas: #0C0F13;
  --surface: #161A20;
  --raised: #1E232B;
  --hairline: #2A303A;
  --ink: #FFFFFF;
  --body: #A7AFBC;
  --muted: #7B8391;
  --green: #30A83C;
  --green-strong: #5BD667;
  --mint: #12301A;
  --hot: #FF4D40;
  --cold: #4C9DFF;
  --warm: #FF8A1F;
  --violet: #A67CFF;

  --display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", "Helvetica Neue", Arial, sans-serif;
  --text: "Mulish", "Nunito Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --pill: 540px;
  --card: 8px;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1180px;
  --nav-h: 61px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 72px; }
body { margin: 0; background: var(--canvas); color: var(--ink); font: 500 16px/1.5 var(--text); overflow-x: clip; }
h1, h2, h3, p, figure, ul, ol { margin: 0; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--green-strong); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: -999px; top: 12px; z-index: 100; padding: 10px 16px; border-radius: var(--pill); background: var(--green); font-weight: 700; text-decoration: none; }
.skip:focus { left: 12px; }

#dust { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
main, .foot { position: relative; z-index: 1; }

/* ---------------------------------------------------------------- type */
.d1, .d2, .d3 { font-family: var(--display); font-weight: 800; text-transform: uppercase; text-wrap: balance; }
.d1 { font-size: clamp(3.4rem, 12.5vw, 8.2rem); line-height: .9; }
.d2 { font-size: clamp(2.7rem, 8vw, 5.2rem); line-height: .93; }
.d3 { font-size: clamp(1.7rem, 3.8vw, 2.4rem); line-height: 1; font-weight: 700; }
.lead { font-size: clamp(1.05rem, 2.1vw, 1.3rem); line-height: 1.45; color: var(--body); max-width: 36ch; }
.small { font-size: .875rem; color: var(--muted); }
.kicker { display: block; font: 700 clamp(.95rem, 1.6vw, 1.1rem)/1.3 var(--text); color: var(--green-strong); text-transform: none; margin-bottom: 14px; }
.num { font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- buttons, pills, badges */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border-radius: var(--pill); border: 1px solid var(--hairline); background: var(--surface); color: var(--ink); font: 700 15px/1 var(--text); text-decoration: none; cursor: pointer; transition: transform .15s ease, background-color .15s ease, border-color .15s ease; }
.btn:hover { transform: translateY(-2px); border-color: var(--muted); }
.btn--primary { background: var(--green); border-color: var(--green); }
.btn--primary:hover { background: #37ba44; border-color: #37ba44; }
.btn--line { border-color: var(--green); color: var(--green-strong); }
.btn--sm { min-height: 40px; padding: 0 16px; font-size: 14px; }
.btn--block { width: 100%; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.textlink { color: var(--green-strong); font-weight: 700; text-decoration: none; border-bottom: 1px solid transparent; }
.textlink:hover { border-bottom-color: currentColor; }

.badge { display: inline-flex; align-items: center; gap: .35em; padding: .3em .6em; border-radius: 4px; border: 1px solid var(--hairline); background: var(--surface); font: 700 .8em/1.2 var(--text); white-space: nowrap; }
.badge svg { width: 1em; height: 1em; }
.badge--pr { color: var(--violet); }
.badge--mint { background: var(--mint); border-color: var(--mint); color: var(--green-strong); }
.badge--hot { color: var(--hot); }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: var(--pill); border: 1px solid var(--hairline); background: var(--surface); color: var(--ink); font: 700 14px/1 var(--text); text-decoration: none; transition: border-color .15s ease, color .15s ease; }
a.chip:hover { border-color: var(--green); color: var(--green-strong); }

/* ---------------------------------------------------------------- nav */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 60; display: flex; align-items: center; gap: 12px; height: var(--nav-h); padding: 0 var(--gutter); background: rgba(12, 15, 19, .86); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom: 1px solid var(--hairline); }
.brand { font: 800 28px/1 var(--display); text-transform: uppercase; text-decoration: none; letter-spacing: .01em; }
.brand i { font-style: normal; color: var(--green-strong); }
.nav__links { display: flex; gap: 2px; margin-left: auto; list-style: none; padding: 0; }
.nav__links a { display: block; padding: 10px 12px; border-radius: var(--pill); color: var(--body); font: 700 14px/1 var(--text); text-decoration: none; }
.nav__links a:hover, .nav__links a[aria-current="page"] { color: var(--ink); background: var(--surface); }
.nav__toggle { display: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--hairline); background: var(--surface); color: var(--ink); cursor: pointer; place-items: center; }
.nav__toggle svg { width: 20px; height: 20px; }
@media (max-width: 900px) {
  .nav__cta { margin-left: auto; }
  .nav__toggle { display: grid; }
  .nav__links { position: fixed; inset: var(--nav-h) 0 0 0; flex-direction: column; gap: 0; margin: 0; padding: 20px var(--gutter); background: var(--canvas); transform: translateY(-12px); opacity: 0; visibility: hidden; transition: opacity .2s ease, transform .2s ease, visibility .2s; }
  .nav.open .nav__links { transform: none; opacity: 1; visibility: visible; }
  .nav__links a { padding: 14px 0; border-radius: 0; border-bottom: 1px solid var(--hairline); color: var(--ink); font: 800 2.2rem/1 var(--display); text-transform: uppercase; }
  .nav__links a:hover, .nav__links a[aria-current="page"] { background: none; color: var(--green-strong); }
}

/* five segments, one per scene: scrolling the page is doing your sets */
.rail { position: fixed; top: var(--nav-h); left: 0; right: 0; z-index: 59; display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; height: 3px; }
.rail i { background: var(--hairline); overflow: hidden; }
.rail i::after { content: ""; display: block; height: 100%; background: var(--green); transform-origin: 0 50%; transform: scaleX(var(--f, 0)); }
html:not(.js) .rail { display: none; }

/* ---------------------------------------------------------------- layout blocks */
.wrap { max-width: var(--max); margin-inline: auto; }
.band { padding: clamp(56px, 9vw, 120px) var(--gutter); }
.band--surface { background: var(--surface); border-block: 1px solid var(--hairline); }
.stack { display: grid; gap: 16px; align-content: start; }
.stack--lg { gap: 28px; }
.center { text-align: center; justify-items: center; }

/* ---------------------------------------------------------------- hero */
.hero { position: relative; display: grid; gap: 28px; align-items: center; min-height: min(100svh, 920px); padding: calc(var(--nav-h) + 36px) var(--gutter) 40px; overflow: clip; }
.hero__copy { position: relative; z-index: 2; display: grid; gap: 20px; }
.hero__stage { position: relative; display: grid; place-items: center; min-height: 300px; }
.hero__lifter { position: relative; width: min(100%, 520px); }
.hero__price { color: var(--body); font-weight: 700; }
@media (min-width: 900px) {
  .hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); padding-inline: max(var(--gutter), calc((100vw - var(--max)) / 2)); }
}

.ring { position: absolute; width: min(120vw, 900px); aspect-ratio: 1; right: -32%; top: 50%; translate: 0 -50%; color: var(--hairline); animation: spin 90s linear infinite; pointer-events: none; }
.ring circle, .ring line { fill: none; stroke: currentColor; stroke-width: 1; vector-effect: non-scaling-stroke; }
@keyframes spin { to { rotate: 360deg; } }

.counter { position: absolute; left: 0; top: 4%; display: grid; line-height: 1; }
.counter b { font: 800 clamp(4.5rem, 15vw, 8.5rem)/.85 var(--display); font-variant-numeric: tabular-nums; }
.counter b.pop { animation: pop .35s ease; }
.counter span { color: var(--body); font-weight: 700; }
@keyframes pop { 0% { scale: 1.25; color: var(--green-strong); } 100% { scale: 1; } }
.sets { position: absolute; right: 0; bottom: 6%; display: grid; gap: 8px; list-style: none; padding: 0; }
.sets li { display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 14px 0 6px; border-radius: var(--pill); border: 1px solid var(--hairline); background: var(--surface); color: var(--body); font: 700 13px/1 var(--text); transition: background-color .3s ease, color .3s ease, border-color .3s ease; }
.sets li::before { content: ""; width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--hairline); background: var(--canvas) center / 14px no-repeat; transition: inherit; }
.sets li.done { background: var(--mint); border-color: var(--mint); color: var(--green-strong); }
.sets li.done::before { border-color: var(--green); background-color: var(--green); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='%23fff' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }

/* ---------------------------------------------------------------- the lifter */
.lf { width: 100%; height: auto; overflow: visible; --phi: 58deg; --dur: 2.7s; }
.lf-floor { stroke: var(--hairline); stroke-width: 2; }
.lf-shadow { fill: #000; opacity: .45; }
.lf-limb line, .lf-limb polyline { fill: none; stroke: var(--ink); stroke-width: 12; stroke-linecap: round; stroke-linejoin: round; }
.lf-limb .lf-torso { fill: var(--ink); stroke: var(--ink); stroke-width: 12; stroke-linejoin: round; }
.lf-limb .lf-head { fill: var(--ink); }
.lf-limb .lf-bar { stroke: var(--body); stroke-width: 5; }
.lf-limb .lf-dbbar { stroke: var(--body); stroke-width: 4; }
.lf-limb .lf-plate { fill: var(--green); }
.lf-limb .lf-plate--in { fill: var(--green-strong); }

.lf-shin-l, .lf-thigh-l, .lf-upper, .lf-shin-r, .lf-thigh-r, .lf-arm-l, .lf-arm-r, .lf-fore-l, .lf-fore-r { animation: var(--dur) cubic-bezier(.45, 0, .55, 1) infinite; }
.lf-shin-l { transform-origin: 98px 232px; }
.lf-thigh-l { transform-origin: 98px 188px; }
.lf-upper { transform-origin: 98px 144px; }
.lf-shin-r { transform-origin: 142px 232px; }
.lf-thigh-r { transform-origin: 142px 188px; }
/* squat: each leg folds like a hinge so the hips drop straight down and the feet stay planted */
.lf--squat .lf-shin-l, .lf--squat .lf-upper { animation-name: lf-neg; }
.lf--squat .lf-thigh-l { animation-name: lf-pos2; }
.lf--squat .lf-shin-r { animation-name: lf-pos; }
.lf--squat .lf-thigh-r { animation-name: lf-neg2; }
.lf--squat .lf-shadow { animation: lf-shadow var(--dur) cubic-bezier(.45, 0, .55, 1) infinite; transform-origin: 120px 244px; }
@keyframes lf-neg { 0%, 12%, 100% { transform: rotate(0deg); } 50%, 62% { transform: rotate(calc(var(--phi) * -1)); } }
@keyframes lf-pos { 0%, 12%, 100% { transform: rotate(0deg); } 50%, 62% { transform: rotate(var(--phi)); } }
@keyframes lf-pos2 { 0%, 12%, 100% { transform: rotate(0deg); } 50%, 62% { transform: rotate(calc(var(--phi) * 2)); } }
@keyframes lf-neg2 { 0%, 12%, 100% { transform: rotate(0deg); } 50%, 62% { transform: rotate(calc(var(--phi) * -2)); } }
@keyframes lf-shadow { 0%, 12%, 100% { transform: scaleX(.86); } 50%, 62% { transform: scaleX(1.12); } }
/* lateral raise */
.lf-arm-l { transform-origin: 95px 100px; }
.lf-arm-r { transform-origin: 145px 100px; }
.lf--raise { --phi: 80deg; --dur: 2.4s; }
.lf--raise .lf-arm-l { animation-name: lf-pos; }
.lf--raise .lf-arm-r { animation-name: lf-neg; }
/* curl, one arm after the other */
.lf-fore-l { transform-origin: 90px 126px; }
.lf-fore-r { transform-origin: 150px 126px; }
.lf--curl { --phi: 145deg; --dur: 2.2s; }
.lf--curl .lf-fore-l { animation-name: lf-neg; }
.lf--curl .lf-fore-r { animation-name: lf-pos; animation-delay: calc(var(--dur) / -2); }

/* ---------------------------------------------------------------- marquee */
.marquee { position: relative; z-index: 1; overflow: hidden; padding: 16px 0; border-block: 1px solid var(--hairline); background: var(--surface); }
.marquee__track { display: flex; gap: 40px; width: max-content; font: 800 clamp(2.2rem, 6vw, 4.2rem)/1 var(--display); text-transform: uppercase; color: transparent; -webkit-text-stroke: 1px var(--muted); animation: marquee 30s linear infinite; }
.marquee__track b { color: var(--green); -webkit-text-stroke: 0; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------------------------------------------------------------- scroll scenes */
.scene { position: relative; }
.scene__pin { position: relative; display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: 18px; padding: calc(var(--nav-h) + 24px) var(--gutter) 28px; overflow: clip; }
.js:not(.reduce) .scene { height: calc(var(--len, 2.6) * 100svh); }
.js:not(.reduce) .scene__pin { position: sticky; top: 0; height: 100svh; }
.scene__stage { position: relative; z-index: 1; display: grid; place-items: center; min-height: 0; }
.scene__copy { position: relative; z-index: 1; display: grid; gap: 8px; }
.scene__copy .lead { max-width: 30ch; }
.scene__step { color: var(--green-strong); font-weight: 700; font-size: .95rem; }
.scene__bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
@media (min-width: 900px) {
  .scene__pin { grid-template-rows: none; grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); align-items: center; gap: 48px; padding-inline: max(var(--gutter), calc((100vw - var(--max)) / 2)); }
  .scene__copy { order: -1; gap: 14px; }
}

/* background: graph paper drifting */
.bg-grid { background: linear-gradient(var(--hairline) 1px, transparent 1px) 0 0 / 100% 56px, linear-gradient(90deg, var(--hairline) 1px, transparent 1px) 0 0 / 56px 100%; opacity: .35; animation: grid-drift 14s linear infinite; -webkit-mask-image: radial-gradient(closest-side, #000 30%, transparent); mask-image: radial-gradient(closest-side, #000 30%, transparent); }
@keyframes grid-drift { to { background-position: 0 56px, 56px 0; } }
/* background: numbers rising, the weight going up */
.bg-rise span { position: absolute; bottom: -12%; left: var(--x); color: var(--c, var(--hot)); font: 800 var(--s, 2.6rem)/1 var(--display); opacity: 0; animation: rise var(--t, 9s) linear var(--d, 0s) infinite; }
@keyframes rise { 0% { transform: translateY(0); opacity: 0; } 12% { opacity: .26; } 80% { opacity: .2; } 100% { transform: translateY(-115svh); opacity: 0; } }
/* background: orbit rings, the AI thinking */
.bg-orbit i { position: absolute; left: 50%; top: 50%; width: var(--w); aspect-ratio: 1; translate: -50% -50%; border: 1px dashed var(--hairline); border-radius: 50%; animation: spin var(--t) linear infinite; }
.bg-orbit i::after { content: ""; position: absolute; top: -5px; left: 50%; width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--green)); }
.bg-orbit i:nth-child(even) { animation-direction: reverse; }
/* ---------------------------------------------------------------- pictures driven by --p */
.viz { position: relative; font-size: min(1.5svh, 3.5vw, 15px); }
@media (min-width: 900px) { .viz { font-size: min(1.9svh, 1.35vw, 19px); } }
.viz--static { font-size: clamp(12px, 3.4vw, 17px); }

/* the door */
.viz--door { width: min(100%, 30em); aspect-ratio: 4 / 5; border-radius: 1em; border: 1px solid var(--hairline); background: #06080B; overflow: hidden; }
.gym { position: absolute; inset: 0; transform: scale(calc(1 + var(--p) * .3)); transform-origin: 50% 64%; }
.gym__floor { position: absolute; left: -60%; right: -60%; bottom: -4%; height: 44%; transform: perspective(16em) rotateX(64deg); transform-origin: 50% 0; background: linear-gradient(var(--hairline) 2px, transparent 2px) 0 calc(var(--p) * 9em) / 100% 3em, linear-gradient(90deg, var(--hairline) 2px, transparent 2px) 50% 0 / 3em 100%; }
.gym__light { position: absolute; top: 0; width: 34%; height: 78%; left: var(--x); background: linear-gradient(rgba(255, 255, 255, .2), rgba(255, 255, 255, 0) 88%); clip-path: polygon(42% 0, 58% 0, 100% 100%, 0 100%); opacity: clamp(0, calc((var(--p) - var(--at)) * 12), 1); }
.gym__light::before { content: ""; position: absolute; top: 0; left: 38%; width: 24%; height: .5em; background: #fff; }
.gym__rack { position: absolute; left: 6%; right: 6%; bottom: 12%; opacity: calc(.25 + clamp(0, calc((var(--p) - .3) * 4), 1) * .75); }
.gym__rack .st { fill: none; stroke: #3B4350; stroke-width: 6; stroke-linecap: round; }
.gym__rack .bar { stroke: var(--body); stroke-width: 4; }
.gym__rack .pl { fill: var(--green); }
.gym__rack .pl2 { fill: var(--green-strong); }
.door { position: absolute; top: 0; bottom: 0; width: 50.4%; display: grid; align-items: center; background: var(--surface); border: 1px solid var(--hairline); --a: clamp(0, calc(var(--p) * 2.5), 1); }
.door--l { left: 0; justify-items: end; transform: translateX(calc(var(--a) * -101%)); }
.door--r { right: 0; justify-items: start; transform: translateX(calc(var(--a) * 101%)); }
.door b { font: 800 7.5em/1 var(--display); color: var(--raised); -webkit-text-stroke: 1px var(--hairline); padding: 0 .04em; }
.door::after { content: ""; position: absolute; top: 40%; width: .5em; height: 20%; border-radius: 1em; background: var(--hairline); }
.door--l::after { right: 1em; }
.door--r::after { left: 1em; }
.today { position: absolute; left: 6%; right: 6%; bottom: 5%; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: .2em 1em; padding: 1em 1.1em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); --c: clamp(0, calc((var(--p) - .6) * 4), 1); transform: translateY(calc((1 - var(--c)) * 140%)); }
.today small { grid-column: 1 / -1; color: var(--green-strong); font: 700 .8em var(--text); }
.today strong { font: 800 2.2em/1 var(--display); text-transform: uppercase; }
.today span { grid-column: 1; color: var(--body); font-size: .85em; }
.today em { grid-row: 2 / 4; grid-column: 2; align-self: center; font-style: normal; padding: .8em 1.1em; border-radius: 3em; background: var(--green); font: 700 .85em/1 var(--text); }

/* the phone and the log */
.viz--log { display: grid; grid-template-columns: auto auto; align-items: end; justify-content: center; }
.viz--log .lf { width: 12em; margin-right: -2.5em; }
.phone { position: relative; z-index: 1; display: flex; flex-direction: column; gap: .7em; width: 16em; min-height: 29em; padding: 1.1em .8em 1em; border-radius: 2.1em; border: .14em solid var(--hairline); background: var(--canvas); box-shadow: 0 1.6em 3.2em rgba(0, 0, 0, .55); }
.phone::before { content: ""; align-self: center; width: 4.2em; height: .34em; border-radius: 1em; background: var(--hairline); }
.phone__bar { display: flex; justify-content: space-between; align-items: center; font-size: .78em; color: var(--body); }
.phone__bar b { color: var(--green); }
.phone__bar span { padding: .3em .6em; border-radius: .6em; background: var(--surface); }
.phone__card { display: grid; gap: .55em; padding: .8em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); }
.phone__ex { font: 700 1.05em/1.2 var(--text); }
.phone__last { justify-self: start; padding: .3em .55em; border-radius: .5em; background: var(--canvas); color: var(--body); font-size: .72em; }
.setrow { position: relative; display: grid; grid-template-columns: 1.1em 1.15fr .85fr 2.3em; align-items: center; gap: .4em; padding: .12em; border-radius: 3em; --t: clamp(0, calc((var(--p) - var(--at)) * 14), 1); --b: clamp(0, calc((var(--p) - var(--at) + .1) * 14), 1); }
.setrow::before { content: ""; position: absolute; inset: 0; border-radius: inherit; background: var(--mint); opacity: var(--t); }
.setrow > * { position: relative; }
.setrow__n { text-align: center; color: var(--body); font: 700 .85em var(--text); }
.temp, .reps { display: flex; align-items: center; justify-content: space-between; height: 2.3em; padding: 0 .55em; border-radius: 3em; border: 1px solid var(--hairline); background: var(--canvas); font: 700 .95em/1 var(--text); }
.temp svg, .reps svg { width: .9em; height: .9em; flex: none; }
.temp__down { color: var(--cold); }
.temp__up { color: var(--hot); scale: calc(1 + var(--b) * (1 - var(--b)) * 2.4); }
.temp__val { display: grid; color: var(--hot); text-align: center; }
.temp__val span { grid-area: 1 / 1; }
.temp__val span:first-child { opacity: calc(1 - var(--b)); }
.temp__val span:last-child { opacity: var(--b); transform: translateY(calc((1 - var(--b)) * .7em)); }
.reps { justify-content: center; gap: .3em; }
.reps small { color: var(--muted); font-size: .7em; }
.check { position: relative; display: grid; place-items: center; width: 2.3em; height: 2.3em; border-radius: 50%; border: 1px solid var(--hairline); background: var(--canvas); }
.check::before { content: ""; position: absolute; inset: -1px; border-radius: 50%; background: var(--green); opacity: var(--t); transform: scale(calc(.4 + var(--t) * .6)); }
.check svg { position: relative; width: 1.15em; height: 1.15em; color: #fff; opacity: calc(.22 + var(--t) * .78); }
.rest { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: .6em; color: var(--body); font: 700 .72em var(--text); }
.rest i { height: .4em; border-radius: 1em; background: var(--raised); overflow: hidden; }
.rest i::after { content: ""; display: block; height: 100%; border-radius: 1em; background: var(--green); transform-origin: 0 50%; transform: scaleX(calc(1 - clamp(0, calc((var(--p) - .3) * 2.2), 1))); }
.phone .badge { align-self: center; margin-top: auto; --t: clamp(0, calc((var(--p) - .8) * 9), 1); opacity: var(--t); transform: scale(calc(.6 + var(--t) * .4)); }

/* the AI workout plan */
.viz--plan { display: grid; gap: .9em; width: min(100%, 25em); }
.prompt { display: flex; align-items: center; gap: .6em; padding: .85em 1.1em; border-radius: 3em; border: 1px solid var(--hairline); background: var(--surface); font: 500 1em/1.2 var(--text); }
.prompt svg { width: 1.25em; height: 1.25em; flex: none; color: var(--green-strong); }
.prompt span { white-space: nowrap; --t: clamp(0, calc(var(--p) * 4.2), 1); clip-path: inset(0 calc((1 - var(--t)) * 100%) 0 0); }
.plan { display: grid; gap: .5em; list-style: none; padding: 0; counter-reset: n; }
.plan li { display: flex; align-items: center; gap: .7em; padding: .75em .9em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); --t: clamp(0, calc((var(--p) - .26 - var(--i) * .085) * 7), 1); opacity: var(--t); transform: translate(calc((1 - var(--t)) * var(--x)), calc((1 - var(--t)) * var(--y))) rotate(calc((1 - var(--t)) * var(--r))); }
.plan li::before { counter-increment: n; content: counter(n); display: grid; place-items: center; min-width: 1.9em; height: 1.6em; border-radius: 4px; background: var(--canvas); color: var(--body); font: 700 .72em/1 var(--text); }
.plan b { flex: 1; font: 700 .95em/1.2 var(--text); }
.plan span { color: var(--body); font-size: .85em; white-space: nowrap; }
.plan__note { justify-self: start; --t: clamp(0, calc((var(--p) - .82) * 8), 1); opacity: var(--t); transform: translateY(calc((1 - var(--t)) * .8em)); }

/* the plate */
.viz--meal { display: grid; gap: .8em; justify-items: center; width: min(100%, 25em); }
.viz--meal .prompt { justify-self: stretch; }
.platebox { position: relative; width: 15.5em; }
.plate { width: 100%; overflow: visible; }
.plate .rim { fill: var(--surface); stroke: var(--hairline); stroke-width: 2; }
.plate .well { fill: var(--raised); }
.food { transform-box: fill-box; transform-origin: 50% 50%; --t: clamp(0, calc((var(--p) - .22 - var(--i) * .1) * 8), 1); opacity: var(--t); transform: translateY(calc((1 - var(--t)) * -3.5em)) scale(calc(.6 + var(--t) * .4)); }
.steam path { fill: none; stroke: var(--muted); stroke-width: 2.5; stroke-linecap: round; opacity: 0; animation: steam 3.2s ease-in-out infinite; }
.steam path:nth-child(2) { animation-delay: -1.1s; }
.steam path:nth-child(3) { animation-delay: -2.1s; }
@keyframes steam { 0% { transform: translateY(6px); opacity: 0; } 40% { opacity: .55; } 100% { transform: translateY(-16px); opacity: 0; } }
.kcal { position: absolute; right: -1.2em; top: -.4em; display: grid; justify-items: center; padding: .5em .8em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); color: var(--body); font: 700 .75em var(--text); --t: clamp(0, calc((var(--p) - .58) * 8), 1); opacity: var(--t); transform: scale(calc(.6 + var(--t) * .4)); }
.kcal b { color: var(--green); font: 800 2.6em/.9 var(--display); }
.macros { display: grid; gap: .5em; width: 100%; list-style: none; padding: 0; }
.macros li { display: grid; grid-template-columns: 4.4em 1fr 3em; align-items: center; gap: .6em; color: var(--body); font-size: .85em; --t: clamp(0, calc((var(--p) - .62 - var(--i) * .07) * 6), 1); }
.macros i { height: .5em; border-radius: 1em; background: var(--raised); overflow: hidden; }
.macros i::after { content: ""; display: block; height: 100%; border-radius: 1em; background: var(--c, var(--green)); transform-origin: 0 50%; transform: scaleX(calc(var(--t) * var(--w))); }
.macros b { color: var(--ink); text-align: right; }

/* the progress */
.viz--track { display: grid; gap: .8em; width: min(100%, 26em); }
.chartcard { display: grid; gap: .2em; padding: 1em 1.1em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); }
.chartcard__label { color: var(--body); font-size: .8em; }
.chartcard__row { display: flex; align-items: center; gap: .7em; flex-wrap: wrap; }
.chartcard__num { color: var(--green); font: 800 3.2em/1 var(--display); }
.chartcard__num small { font: 700 .32em var(--text); }
.chartcard .badge { --t: clamp(0, calc((var(--p) - .62) * 8), 1); opacity: var(--t); transform: scale(calc(.6 + var(--t) * .4)); }
.line { width: 100%; overflow: visible; --t: clamp(0, calc(var(--p) * 1.7), 1); }
.line__grid { stroke: var(--hairline); stroke-width: 1; }
.line__path { fill: none; stroke: var(--green); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1px; stroke-dashoffset: calc((1 - var(--t)) * 1px); }
.line__area { fill: var(--green); opacity: calc(var(--t) * .12); }
.line__dot { fill: var(--green); stroke: var(--surface); stroke-width: 3; opacity: clamp(0, calc((var(--p) - .52) * 12), 1); }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: .8em; }
.bars { display: grid; grid-template-columns: repeat(7, 1fr); align-items: end; gap: .35em; height: 6.5em; padding: .8em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); }
.bars i { height: calc(var(--h) * 100%); border-radius: 4px 4px 0 0; background: var(--green); transform-origin: 50% 100%; transform: scaleY(clamp(0, calc((var(--p) - .4 - var(--i) * .035) * 6), 1)); }
.thenow { display: grid; grid-template-columns: 1fr 1fr; gap: .35em; padding: .5em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); }
.thenow figure { display: grid; gap: .2em; justify-items: center; --t: clamp(0, calc((var(--p) - .7 - var(--i) * .08) * 6), 1); opacity: var(--t); transform: translateY(calc((1 - var(--t)) * 1.2em)); }
.thenow svg { width: 100%; border-radius: .4em; background: var(--raised); }
.thenow svg path, .thenow svg circle { fill: var(--muted); }
.thenow figcaption { color: var(--body); font: 700 .65em var(--text); }

/* play-once versions used outside the scroll story */
.js:not(.reduce) [data-play] { --p: 0; }
.js:not(.reduce) [data-play].in { --p: 1; transition: --p 2.2s cubic-bezier(.25, .6, .25, 1); }

/* ---------------------------------------------------------------- inner pages */
.sub-hero { position: relative; display: grid; gap: 32px; align-items: center; padding: calc(var(--nav-h) + 48px) var(--gutter) 56px; overflow: clip; }
.sub-hero__copy { position: relative; z-index: 1; display: grid; gap: 18px; }
.sub-hero__viz { position: relative; z-index: 1; display: grid; place-items: center; }
@media (min-width: 900px) {
  .sub-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: min(88svh, 780px); padding-inline: max(var(--gutter), calc((100vw - var(--max)) / 2)); }
}
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; color: var(--muted); font-size: .85rem; }
.crumbs li + li::before { content: "/"; margin-right: 6px; }
.crumbs a { color: var(--body); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }

.feature { display: grid; gap: 28px; align-items: center; padding: clamp(40px, 7vw, 88px) 0; border-top: 1px solid var(--hairline); }
.feature__viz { display: grid; place-items: center; }
@media (min-width: 900px) {
  .feature { grid-template-columns: 1fr 1fr; gap: 64px; }
  .feature:nth-of-type(even) .feature__viz { order: -1; }
}

.trio { display: grid; gap: 12px; }
@media (min-width: 760px) { .trio { grid-template-columns: repeat(3, 1fr); } }
.card { display: grid; gap: 10px; align-content: start; padding: 24px; border-radius: var(--card); border: 1px solid var(--hairline); background: var(--surface); }
.card__icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--mint); color: var(--green-strong); }
.card__icon svg { width: 24px; height: 24px; }
.card h3 { font: 700 1.15rem/1.25 var(--text); }
.card p { color: var(--body); }
a.card { text-decoration: none; transition: border-color .15s ease, transform .15s ease; }
a.card:hover { border-color: var(--green); transform: translateY(-2px); }

/* rest ring */
.ringtimer { position: relative; width: min(60vw, 240px); aspect-ratio: 1; display: grid; place-items: center; }
.ringtimer svg { position: absolute; inset: 0; rotate: -90deg; }
.ringtimer circle { fill: none; stroke-width: 10; }
.ringtimer .track { stroke: var(--raised); }
.ringtimer .run { stroke: var(--green); stroke-linecap: round; stroke-dasharray: 100px; animation: ring-run 6s linear infinite; }
.ringtimer b { font: 800 4.6rem/1 var(--display); font-variant-numeric: tabular-nums; }
.ringtimer span { position: absolute; bottom: 24%; color: var(--body); font: 700 .85rem var(--text); }
@keyframes ring-run { from { stroke-dashoffset: 0; } to { stroke-dashoffset: 100px; } }

/* ---------------------------------------------------------------- pricing */
.plans { display: grid; gap: 16px; }
@media (min-width: 800px) { .plans { grid-template-columns: 1.12fr .88fr; } }
.plancard { position: relative; display: grid; gap: 14px; align-content: start; padding: clamp(22px, 4vw, 36px); border-radius: var(--card); border: 1px solid var(--hairline); background: var(--surface); }
.plancard--best { border-color: var(--green); }
.plancard h3 { font: 700 1.1rem var(--text); color: var(--body); }
.price { display: flex; align-items: baseline; gap: 10px; color: var(--green); font: 800 clamp(4.6rem, 15vw, 8rem)/.85 var(--display); font-variant-numeric: tabular-nums; }
.price small { color: var(--body); font: 700 1rem/1.2 var(--text); }
.ticks { display: grid; gap: 8px; list-style: none; padding: 0; color: var(--body); }
.ticks li { display: grid; grid-template-columns: 20px 1fr; gap: 10px; align-items: start; }
.ticks li::before { content: ""; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%; background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4L18 8' fill='none' stroke='%235BD667' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 13px no-repeat; }

.even { display: grid; gap: 18px; padding: clamp(22px, 4vw, 36px); border-radius: var(--card); border: 1px solid var(--hairline); background: var(--surface); }
.even label { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; font-weight: 700; }
.even output { color: var(--hot); font: 800 1.6rem/1 var(--display); font-variant-numeric: tabular-nums; }
.even input[type="range"] { width: 100%; height: 44px; margin: 0; background: none; accent-color: var(--green); cursor: pointer; }
.even__row { display: grid; grid-template-columns: 5.2em 1fr 4.6em; align-items: center; gap: 12px; color: var(--body); }
.even__row i { height: 12px; border-radius: 0 6px 6px 0; background: var(--muted); transform-origin: 0 50%; transform: scaleX(var(--w, 1)); transition: transform .25s ease; }
.even__row--life i { background: var(--green); }
.even__row b { color: var(--ink); text-align: right; font-variant-numeric: tabular-nums; }
.even__line { color: var(--ink); font-weight: 700; }

/* ---------------------------------------------------------------- faq, tables, compare */
.faq { display: grid; gap: 8px; max-width: 780px; }
.faq details { border-radius: var(--card); border: 1px solid var(--hairline); background: var(--surface); }
.faq summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 20px; font-weight: 700; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 12px; height: 12px; border-right: 2px solid var(--green-strong); border-bottom: 2px solid var(--green-strong); rotate: 45deg; transition: rotate .2s ease; }
.faq details[open] summary::after { rotate: 225deg; }
.faq p { padding: 0 20px 18px; color: var(--body); max-width: 62ch; }

.tablebox { overflow-x: auto; border-radius: var(--card); border: 1px solid var(--hairline); background: var(--surface); }
table { width: 100%; min-width: 560px; border-collapse: collapse; }
caption { padding: 16px 20px; text-align: left; color: var(--muted); font-size: .875rem; caption-side: bottom; }
th, td { padding: 16px 20px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--hairline); }
thead th { color: var(--body); font-size: .875rem; }
tbody th { font-weight: 700; white-space: nowrap; }
td { color: var(--body); }
tr.us th, tr.us td { color: var(--ink); background: var(--mint); }
tr.us th { color: var(--green-strong); }

.versus { display: grid; gap: 12px; }
@media (min-width: 800px) { .versus { grid-template-columns: 1fr 1fr; } }
.versus .card--us { border-color: var(--green); }
.versus h2 { font: 700 1.25rem/1.25 var(--text); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------------------------------------------------------------- closing call and footer */
.final { position: relative; display: grid; gap: 22px; justify-items: center; text-align: center; padding: clamp(72px, 12vw, 150px) var(--gutter); overflow: clip; }
.final .lead { max-width: 30ch; }
.foot { padding: 48px var(--gutter) 40px; border-top: 1px solid var(--hairline); background: var(--surface); color: var(--body); }
.foot__grid { display: grid; gap: 32px; }
@media (min-width: 760px) { .foot__grid { grid-template-columns: 1.2fr 1fr 1fr; } }
.foot h2 { margin-bottom: 10px; color: var(--ink); font: 700 .95rem var(--text); }
.foot ul { display: grid; gap: 4px; list-style: none; padding: 0; }
.foot a { display: inline-block; padding: 6px 0; text-decoration: none; }
.foot a:hover { color: var(--ink); }
.foot__small { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--hairline); color: var(--muted); font-size: .8rem; max-width: 80ch; }

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

/* ---------------------------------------------------------------- late additions */
.js:not(.reduce) .scene { height: calc(var(--len, 2.3) * 100svh); }
.reduce .rail { display: none; }
.reduce .scene__pin { padding-block: clamp(56px, 9vw, 120px); }
.gym__rack { left: 6%; right: auto; width: 88%; height: auto; bottom: 27%; }
.phone__bar b { color: var(--ink); font-size: 1.15em; }
.hero__lifter { width: min(78vw, 36svh, 520px); }
@media (min-width: 900px) { .hero__lifter { width: min(100%, 62svh, 520px); } }

.buy-note { min-height: 1.4em; color: var(--warm); font-size: .875rem; font-weight: 700; }
.note { color: var(--muted); font-size: .8rem; }
.gymrow { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; width: min(100%, 560px); }
.gymrow .lf { width: 100%; }
.split { display: grid; gap: 28px; align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; gap: 64px; } }
.pricepair { display: grid; gap: 20px; }
.pricepair .price small b { display: block; color: var(--ink); }
.foods { display: flex; flex-wrap: wrap; gap: 8px; max-width: 26em; list-style: none; padding: 0; }
.foods li { --t: clamp(0, calc((var(--p) - var(--i) * .07) * 6), 1); opacity: var(--t); transform: scale(calc(.7 + var(--t) * .3)); }
.panel { width: min(100%, 26em); padding: 1.2em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); }
.section-head { display: grid; gap: 12px; margin-bottom: 32px; }
.lf--solo { width: min(70vw, 300px); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.viz--log .lf { width: 15em; margin-right: -4em; }
.phone { width: 17em; min-height: 0; }
.temp svg path { stroke-width: 3.6; }
.temp svg { width: 1em; height: 1em; }
.phone__next { display: flex; justify-content: space-between; align-items: center; padding: .7em .8em; border-radius: .6em; border: 1px solid var(--hairline); background: var(--surface); font: 700 .9em/1.2 var(--text); }
.phone__next small { color: var(--muted); font-size: .8em; }
.phone .badge { margin-top: .2em; }
.bg-rise { -webkit-mask-image: linear-gradient(to bottom, #000 45%, transparent 66%); mask-image: linear-gradient(to bottom, #000 45%, transparent 66%); }
@media (min-width: 900px) { .bg-rise { -webkit-mask-image: linear-gradient(to left, #000 48%, transparent 70%); mask-image: linear-gradient(to left, #000 48%, transparent 70%); } }

.viz--log { grid-template-columns: 11em 17em; }
.viz--log .lf { width: 15em; max-width: none; margin-right: 0; }
.platebox { width: 18em; }
.door b { color: transparent; -webkit-text-stroke: 1.5px var(--muted); }
.door::after { top: 60%; height: 13%; }
.bg-rise span svg { width: var(--s); height: var(--s); }
.nav > nav { margin-left: auto; }
.d1 { font-size: clamp(3.2rem, 11.5vw, 6.8rem); }
.viz--log { grid-template-columns: 11em 17em; }
.viz--log .lf { width: 11em; }
@media (min-width: 900px) { .viz--log { grid-template-columns: 16em 17em; gap: 1em; } .viz--log .lf { width: 16em; } }
.viz--static { font-size: clamp(11px, 3.1vw, 17px); }
@media (max-width: 640px) {
  table { min-width: 0; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  tbody tr { display: grid; gap: 6px; padding: 18px 20px; border-bottom: 1px solid var(--hairline); }
  tbody th, tbody td { display: block; padding: 0; border: 0; }
  tbody th { font-size: 1.15rem; }
  tbody td::before { content: attr(data-label); display: block; color: var(--muted); font-size: .8rem; font-weight: 700; }
  tr.us th, tr.us td { background: none; }
  tr.us { background: var(--mint); }
}
main { overflow-x: clip; }
@media (max-width: 900px) {
  /* the bar's blur makes it the anchor for anything fixed inside it, so the menu hangs off the bar instead */
  .nav__links { position: absolute; inset: 100% 0 auto 0; height: calc(100dvh - var(--nav-h)); overflow-y: auto; }
}
@media (min-width: 900px) { .gymrow { width: min(100%, 760px); } }
@media (prefers-reduced-motion: reduce) { .counter, .sets { display: none; } }
