/* The LEAN App: quiz, checkout and member area. Loads after style.css. */
.app-body { background: var(--paper); min-height: 100vh; }
.narrow { max-width: 720px; margin: 0 auto; padding: clamp(32px, 6vw, 64px) var(--gutter) 96px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.center { text-align: center; }
.stack > * + * { margin-top: 16px; }
.hint { color: var(--muted); margin: 6px 0 24px; }
.card h2 { font-family: var(--display); text-transform: uppercase; font-size: clamp(28px, 4vw, 38px); line-height: 1; margin-bottom: 4px; }
.choice small { display: block; font-weight: 400; color: var(--muted); font-size: 14px; margin-top: 2px; }
.choice span { align-items: flex-start; }
.choice span > div { flex: 1; }
label.lbl, .lbl { display: block; font-weight: 700; font-size: 14px; margin-bottom: 8px; }
.input, select.input, textarea.input { width: 100%; padding: 13px 14px; font: 500 16px var(--body); border: 1.5px solid #cfcfcc; border-radius: var(--radius); background: var(--white); color: var(--black); }
.input:focus { outline: none; border-color: var(--black); }
textarea.input { min-height: 90px; resize: vertical; }
.row3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 560px) { .row3 { grid-template-columns: 1fr 1fr; } }
.choices.three { grid-template-columns: repeat(3, 1fr); }
.choices.four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 560px) { .choices.three, .choices.four { grid-template-columns: 1fr 1fr; } }
.msg { margin-top: 14px; font-weight: 600; font-size: 15px; color: var(--red); min-height: 1em; }
.msg.ok { color: #13803b; }
.notice { padding: 14px 16px; border-left: 3px solid var(--red); background: #fff6f5; font-size: 15px; margin: 16px 0; }
.btn.block { width: 100%; justify-content: center; }
.btn.sm { padding: 10px 16px; font-size: 13px; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--red); font-weight: 700; cursor: pointer; text-decoration: underline; }

/* Sales page */
.banner { background: var(--red); color: var(--white); text-align: center; padding: 10px var(--gutter); font-weight: 700; font-size: 14px; letter-spacing: .04em; }
.banner a { color: inherit; }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.feature { background: var(--white); padding: 32px 28px; }
.feature h3 { font-family: var(--display); text-transform: uppercase; font-size: 26px; line-height: 1.05; margin-bottom: 10px; }
.feature p { color: var(--muted); margin: 0; }
@media (max-width: 900px) { .features { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .features { grid-template-columns: 1fr; } }
.prices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.prices.two { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 820px; margin: 0 auto; }
@media (max-width: 860px) { .prices, .prices.two { grid-template-columns: 1fr; } }
.price { position: relative; display: flex; flex-direction: column; background: var(--white); color: var(--black); border: 2px solid var(--line); padding: 32px 28px; }
.price.best { border-color: var(--red); }
.price .tag { position: absolute; top: -13px; left: 24px; background: var(--red); color: var(--white); font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; padding: 4px 10px; }
.price .amt { font-family: var(--display); font-size: 56px; line-height: 1; margin: 12px 0 4px; }
.price .amt small { font-family: var(--body); font-size: 16px; color: var(--muted); font-weight: 600; }
.price p { color: var(--muted); flex: 1; }
.price .btn { margin-top: 16px; justify-content: center; }
.phone.phone-shot { padding: 0; overflow: hidden; background: #0b0b0d; border-color: #1c1c21; box-shadow: 0 30px 70px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.06), 0 0 80px rgba(255,40,30,.18); }
.phone.phone-shot img { display: block; width: 100%; height: auto; max-height: 620px; object-fit: cover; object-position: top; }
.phone { max-width: 340px; margin: 0 auto; border: 10px solid var(--black); border-radius: 32px; background: var(--paper); padding: 18px 14px; box-shadow: 0 30px 60px rgba(0,0,0,.35); color: var(--black); }

/* Plan picker on /join */
.plan-pick { display: grid; gap: 12px; margin: 20px 0; }
.plan-pick label { display: flex; align-items: center; gap: 14px; padding: 18px; border: 2px solid var(--line); border-radius: var(--radius); background: var(--white); cursor: pointer; }
.plan-pick input { accent-color: var(--red); width: 20px; height: 20px; }
.plan-pick label:has(input:checked) { border-color: var(--red); }
.plan-pick .pp-price { margin-left: auto; text-align: right; font-weight: 800; font-size: 20px; }
.plan-pick .pp-price small { display: block; font-size: 13px; color: var(--muted); font-weight: 600; }
.preview { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 18px 0; }
.preview div { background: var(--paper); padding: 14px; text-align: center; }
.preview b { display: block; font-family: var(--display); font-size: 30px; line-height: 1; }
.preview span { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* Member app */
.app-top { position: sticky; top: 0; z-index: 40; background: var(--black); color: var(--white); }
.app-top .wrap { display: flex; align-items: center; justify-content: space-between; height: 56px; }
.app-top .logo { font-size: 20px; }
.app-main { max-width: 760px; margin: 0 auto; padding: 20px 16px 110px; }
.tabs { position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; display: flex; background: var(--white); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
.tabs button { flex: 1; background: none; border: 0; padding: 10px 4px 12px; font: 700 11px var(--body); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.tabs button svg { width: 22px; height: 22px; }
.tabs button.on { color: var(--red); }
@media (min-width: 900px) { .tabs { max-width: 760px; margin: 0 auto; border: 1px solid var(--line); border-bottom: 0; } }
.panel { background: var(--white); border: 1px solid var(--line); padding: 20px; margin-bottom: 14px; }
.panel h3 { font-family: var(--display); text-transform: uppercase; font-size: 24px; line-height: 1.05; margin-bottom: 6px; }
.panel h4 { margin: 0 0 6px; font-size: 16px; }
.kicker { font-size: 12px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--red); }
.big-title { font-family: var(--display); text-transform: uppercase; font-size: clamp(34px, 7vw, 48px); line-height: .95; margin: 4px 0 10px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stats div { background: var(--paper); padding: 12px 8px; text-align: center; }
.stats b { display: block; font-size: 22px; font-weight: 800; }
.stats span { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.day-list { display: grid; gap: 8px; }
.day-item { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 14px; border: 1.5px solid var(--line); background: var(--white); border-radius: var(--radius); font: inherit; cursor: pointer; }
.day-item:hover { border-color: var(--black); }
.day-item .dot { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #c9c9c6; flex: none; display: flex; align-items: center; justify-content: center; color: var(--white); font-size: 14px; }
.day-item.done .dot { background: var(--red); border-color: var(--red); }
.day-item .grow { flex: 1; }
.day-item small { display: block; color: var(--muted); }
.ex { border-top: 1px solid var(--line); padding: 16px 0; }
.ex:first-of-type { border-top: 0; }
.ex-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.ex-name { font-weight: 800; font-size: 17px; }
.ex-rx { font-weight: 700; color: var(--red); white-space: nowrap; font-size: 15px; }
.ex-meta { font-size: 14px; color: var(--muted); margin: 4px 0 10px; }
.suggest { font-size: 14px; background: var(--paper); padding: 10px 12px; margin-bottom: 10px; border-left: 3px solid var(--black); }
.sets { display: grid; gap: 6px; }
.set-row { display: grid; grid-template-columns: 34px 1fr 1fr 46px; gap: 8px; align-items: center; }
.set-row .n { font-weight: 800; color: var(--muted); text-align: center; }
.set-row input { padding: 10px; font: 600 16px var(--body); border: 1.5px solid #cfcfcc; border-radius: var(--radius); width: 100%; text-align: center; }
.set-row .tick { height: 42px; border: 1.5px solid #cfcfcc; background: var(--white); border-radius: var(--radius); cursor: pointer; font-size: 18px; }
.set-row .tick.on { background: var(--red); border-color: var(--red); color: var(--white); }
.set-head { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.cues { margin: 8px 0 0; padding-left: 18px; font-size: 14px; color: var(--muted); }
details summary { cursor: pointer; font-size: 14px; font-weight: 700; }
.warm li { margin-bottom: 4px; }
.timer { position: fixed; left: 50%; transform: translateX(-50%); bottom: 84px; z-index: 45; background: var(--black); color: var(--white); padding: 12px 18px; border-radius: 40px; font-weight: 800; display: flex; gap: 14px; align-items: center; box-shadow: 0 10px 30px rgba(0,0,0,.3); }
.timer button { background: none; border: 1px solid #555; color: var(--white); border-radius: 20px; padding: 4px 12px; cursor: pointer; font: 700 13px var(--body); }
.habit-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.habit-row:first-child { border-top: 0; }
.habit-row input[type=checkbox] { width: 24px; height: 24px; accent-color: var(--red); flex: none; }
.habit-row .grow { flex: 1; }
.habit-row small { display: block; color: var(--muted); }
.week-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; text-align: center; font-size: 12px; font-weight: 700; }
.week-grid .cell { padding: 8px 0; background: var(--paper); }
.week-grid .cell b { display: block; font-size: 15px; }
.week-grid .cell.l1 { background: #fde3e1; } .week-grid .cell.l2 { background: #f8a59f; } .week-grid .cell.l3 { background: var(--red); color: var(--white); }
.datebar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.datebar button { background: var(--white); border: 1px solid var(--line); width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 18px; }
.notes li { margin-bottom: 8px; }
.chart { width: 100%; height: auto; display: block; }
.lift { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); gap: 10px; font-size: 15px; }
.lift:first-child { border-top: 0; }
.up { color: #13803b; font-weight: 800; }
.scale { display: flex; gap: 6px; }
.scale label { flex: 1; }
.scale input { display: none; }
.scale span { display: block; text-align: center; padding: 10px 0; border: 1.5px solid #cfcfcc; border-radius: var(--radius); font-weight: 700; cursor: pointer; }
.scale input:checked + span { background: var(--black); color: var(--white); border-color: var(--black); }
.table-wrap { overflow-x: auto; }
table.members { width: 100%; border-collapse: collapse; font-size: 14px; }
table.members th, table.members td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; white-space: nowrap; }
table.members th { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.pill { text-transform: capitalize; display: inline-block; padding: 2px 8px; border-radius: 20px; font-size: 12px; font-weight: 700; background: var(--paper); }
.pill.active, .pill.comp { background: #dcf5e4; color: #13803b; }
.pill.pending, .pill.suspended { background: #fff1d6; color: #8a5a00; }
.pill.canceled, .pill.expired { background: #fde3e1; color: var(--red-dark); }
.spinner { padding: 60px 0; text-align: center; color: var(--muted); }

/* Show/hide password */
.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 48px; }
.pw-eye { position: absolute; top: 50%; right: 6px; transform: translateY(-50%); width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; background: none; border: 0; color: var(--muted); cursor: pointer; border-radius: var(--radius); }
.pw-eye:hover { color: var(--black); }

/* Swap and rest controls */
.ex-tools { display: flex; justify-content: space-between; align-items: center; margin: 2px 0 10px; }
.rest-ctl { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.rest-ctl b { color: var(--black); min-width: 38px; text-align: center; }
.rest-btn { width: 30px; height: 30px; border: 1.5px solid #cfcfcc; background: var(--white); border-radius: 50%; font-size: 16px; line-height: 1; cursor: pointer; }
.swap-btn { border: 1.5px solid var(--black); background: var(--white); padding: 6px 12px; border-radius: 20px; font: 700 13px var(--body); cursor: pointer; }
.swap-panel { background: var(--paper); padding: 12px; margin-bottom: 10px; }
.swap-opt { display: block; width: 100%; text-align: left; padding: 11px 12px; margin-top: 6px; background: var(--white); border: 1.5px solid var(--line); border-radius: var(--radius); font: 600 15px var(--body); cursor: pointer; }
.swap-opt:hover { border-color: var(--black); }
.wclock { font-weight: 800; font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.rest-timer #timer-text { font-size: 22px; font-variant-numeric: tabular-nums; min-width: 58px; text-align: center; }
.rest-timer.ending { background: var(--red); }

/* Exercise demo clips */
.ex-clip { float: right; width: 92px; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 6px; margin: 0 0 8px 12px; background: var(--paper); cursor: zoom-in; }
.ex-clip.big { float: none; display: block; width: 100%; max-width: 320px; margin: 0 auto 12px; cursor: zoom-out; }
.ex .ex-tools, .ex .swap-panel, .ex .suggest, .ex .set-row.set-head, .ex .sets, .ex details { clear: both; }
.ex-clip ~ .ex-head { display: block; }
.ex-clip ~ .ex-head .ex-rx { display: block; margin-top: 4px; }

/* Founder pricing countdown */
.countdown { text-align: center; margin: 0 auto 28px; }
.countdown .cd-label { display: block; font-size: 13px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--red); margin-bottom: 10px; }
.cd-boxes { display: inline-flex; gap: 10px; }
.cd-boxes div { min-width: 74px; padding: 12px 8px 10px; background: var(--black); color: var(--white); border-radius: 10px; }
.cd-boxes b { display: block; font: 400 34px/1 var(--display); font-variant-numeric: tabular-nums; }
.cd-boxes small { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted-dark); }
@media (max-width: 420px) { .cd-boxes div { min-width: 62px; } .cd-boxes b { font-size: 28px; } }
.price s { color: var(--muted); font-weight: 700; margin-right: 4px; }

/* Energy check before a workout */
.energy-q { font-weight: 800; margin-bottom: 8px; }
.energy-btns { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.energy-btn { padding: 10px 6px; font: 700 15px var(--body); border: 1.5px solid #cfcfcc; border-radius: var(--radius); background: var(--white); color: var(--ink); cursor: pointer; }
.energy-btn.on { background: var(--red); border-color: var(--red); color: #fff; }
.energy-note { margin: 8px 0 0; }
