/* The first page's tour of the app (index.html #showcase, public/showcase.js): numbers, a workout log, progress charts,
   the calorie calculator, a weekly plan and an Iron AI chat. Each screen animates once as it comes into view (brand.js
   adds .is-in to .if-chart); with animations off, everything simply shows. */
@property --sc-p{syntax:'<number>';inherits:false;initial-value:0}
.showcase{max-width:1250px;margin:0 auto;padding:30px 5vw 70px}
.showcase-head{margin-bottom:30px}
.showcase-head p{color:var(--muted)}

/* Numbers that count up */
.sc-numbers{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));border:1px solid var(--line);border-radius:14px;background:#11120f;margin:0 0 22px;overflow:hidden}
.sc-numbers .stat{padding:22px 20px;text-align:center;border-inline-start:1px solid var(--line)}
.sc-numbers .stat:first-child{border-inline-start:0}
.sc-numbers .stat strong{display:block;font-size:44px;line-height:1.05;color:var(--gold2)}
.sc-numbers .stat small{margin-top:6px;font-size:13px}

/* The cards: two a row on a wide screen, the calculator across both */
.sc-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.sc-card{display:flex;flex-direction:column;gap:16px;min-width:0;padding:24px;border:1px solid var(--line);border-radius:16px;background:linear-gradient(180deg,#141511,#0f100d)}
.sc-card.sc-wide,.sc-card.sc-alone{grid-column:1/-1}
.sc-card[hidden],.sc-numbers[hidden]{display:none}
.sc-copy h3{margin:6px 0 6px;font-size:23px;font-weight:700;line-height:1.2}
.sc-copy p:not(.eyebrow){margin:0;color:var(--muted);font-size:14px;line-height:1.5;max-width:560px}
.sc-copy .eyebrow{margin:0}

/* A phone-like screen inside each card */
.sc-screen{flex:1;margin:0;padding:16px;border:1px solid #2f3027;border-radius:14px;background:#0b0c0a;box-shadow:0 18px 40px rgba(0,0,0,.35),inset 0 1px 0 rgba(255,255,255,.03)}
.sc-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.sc-bar>span:first-child{display:grid;gap:2px;min-width:0}
.sc-bar b{font-size:15px;font-weight:750}
.sc-bar small{color:var(--muted);font-size:12px}

/* Tables (the workout and the week) */
.sc-table{width:100%;border-collapse:collapse;font-size:13px}
.sc-table th{padding:0 6px 8px;color:var(--muted);font-size:11px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;text-align:start;border-bottom:1px solid var(--line)}
.sc-table td{padding:9px 6px;border-bottom:1px solid #1d1e19;white-space:nowrap}
.sc-table td:first-child{white-space:normal;font-weight:650}
.sc-table tr:last-child td{border-bottom:0}
.sc-table td:last-child,.sc-table th:last-child{width:28px;text-align:center}
.sc-tick{display:inline-grid;place-items:center;width:22px;height:22px;border-radius:50%;background:rgba(120,197,141,.16);color:var(--green);font-style:normal;font-size:12px;font-weight:900}
.sc-dot{display:inline-block;width:10px;height:10px;border-radius:50%;background:var(--gold);box-shadow:0 0 0 0 rgba(217,180,74,.6)}
.sc-pr{margin-inline-start:6px;padding:1px 5px;border-radius:4px;background:var(--gold);color:#15120a;font-style:normal;font-size:9px;font-weight:900;letter-spacing:.04em;vertical-align:2px}
.sc-now td{background:rgba(217,180,74,.07)}
.sc-now td:first-child{color:var(--gold2)}
.sc-foot{display:flex;align-items:center;gap:12px;margin-top:12px;color:var(--muted);font-size:12px}
.sc-meter{flex:1;height:6px;border-radius:6px;background:#22231d;overflow:hidden}
.sc-meter i{display:block;height:100%;width:calc(var(--w)*100%);border-radius:inherit;background:linear-gradient(90deg,#8a6d22,var(--gold2))}
.sc-total b{color:var(--text);font-size:14px}

/* Rest timer */
.sc-timer{display:flex;align-items:center;gap:8px;flex:none}
.sc-timer svg{width:38px;height:38px;transform:rotate(-90deg)}
.sc-timer circle{fill:none;stroke:#26271f;stroke-width:3.5}
.sc-timer .sc-timer-ring{stroke:var(--gold);stroke-linecap:round;stroke-dasharray:100;stroke-dashoffset:0;transition:stroke-dashoffset 1s linear}
.sc-timer>span{display:grid;line-height:1.1}
.sc-timer b{font-size:16px;font-variant-numeric:tabular-nums}

/* Progress: a line that draws itself, dots, bars that grow */
.sc-up{flex:none;color:var(--green);font-weight:800;font-size:14px}
.sc-up b{font-size:20px}
.sc-line{display:block;width:100%;height:auto;overflow:visible;direction:ltr}
.sc-grid-lines line{stroke:#1f201b;stroke-width:1}
.sc-axis text{fill:#6c6e66;font-size:9px;text-anchor:end}
.sc-area{fill:rgba(217,180,74,.12);transition:opacity 1s ease .6s}
.sc-path{fill:none;stroke:var(--gold);stroke-width:2.8;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:1;stroke-dashoffset:0;transition:stroke-dashoffset 1.6s cubic-bezier(.3,.6,.2,1)}
.sc-dots circle{fill:var(--gold2);stroke:#0b0c0a;stroke-width:2;transform-box:fill-box;transform-origin:center;transition:transform .35s cubic-bezier(.3,1.6,.5,1) calc(.2s + var(--i)*.18s)}
.sc-mini{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:14px;align-items:end;margin-top:12px}
.sc-mini small{color:var(--muted);font-size:11px}
.sc-bars{display:flex;align-items:flex-end;gap:5px;height:58px;margin-top:6px;direction:ltr}
.sc-bars i{flex:1;height:calc(var(--h)*100%);border-radius:4px 4px 2px 2px;background:linear-gradient(180deg,var(--gold2),#8a6d22);transform-origin:bottom;transition:transform .55s cubic-bezier(.2,.8,.3,1) calc(.5s + var(--i)*.07s)}
.sc-chips{display:grid;gap:8px}
.sc-chips>span{display:flex;align-items:baseline;gap:6px;padding:8px 10px;border:1px solid var(--line);border-radius:10px;background:#11120f}
.sc-chips b{color:var(--gold2);font-size:19px}

/* The calculator */
.sc-calc{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.1fr);gap:22px;align-items:start}
.sc-form{display:grid;gap:14px;padding:18px;border:1px solid var(--line);border-radius:14px;background:#0f100d}
.sc-field{border:0;margin:0;padding:0;min-width:0}
.sc-field legend,.sc-field>span:first-child,.sc-inputs label>span{display:block;margin-bottom:7px;color:#c9c8bf;font-size:12px;font-weight:700}
.sc-chips-pick{display:flex;flex-wrap:wrap;gap:8px}
.sc-chips-pick label{position:relative;cursor:pointer}
.sc-chips-pick input{position:absolute;opacity:0;pointer-events:none}
.sc-chips-pick span{display:inline-block;padding:9px 14px;border:1px solid #3a3b32;border-radius:999px;color:#d7d6cd;font-size:13px;font-weight:700;transition:background .2s ease,border-color .2s ease,color .2s ease}
.sc-chips-pick input:checked+span{background:var(--gold);border-color:var(--gold);color:#15120a}
.sc-chips-pick input:focus-visible+span{outline:2px solid var(--gold2);outline-offset:2px}
.sc-inputs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.sc-inputs input{width:100%;box-sizing:border-box;padding:10px 12px;border:1px solid #3a3b32;border-radius:9px;background:#151612;color:var(--text);font-size:15px}
.sc-inputs input:focus{outline:2px solid var(--gold);outline-offset:1px;border-color:transparent}
.sc-range{display:flex;align-items:center;gap:12px}
.sc-range input{flex:1;accent-color:var(--gold)}
.sc-range output{display:grid;place-items:center;min-width:34px;height:34px;border-radius:9px;background:#1d1e19;color:var(--gold2);font-weight:800}
.sc-form .gold-btn{justify-self:start;padding:12px 20px}
.sc-error{margin:0;color:var(--red);font-size:13px}
.sc-result{display:grid;gap:16px;padding:6px 0}
.sc-label{margin:0;color:var(--gold);font-size:11px;font-weight:800;letter-spacing:.08em;text-transform:uppercase}
.sc-kcal{display:flex;align-items:center;gap:20px}
.sc-kcal p{margin:0 0 6px;color:#c9c8bf;font-size:14px}
.sc-change{color:var(--green)!important;font-weight:700}
.sc-ring{--sc-p:var(--to);flex:none;display:grid;place-items:center;width:86px;height:86px;border-radius:50%;background:conic-gradient(var(--ring,var(--gold)) calc(var(--sc-p)*1%),#24251f 0);transition:--sc-p 1.4s cubic-bezier(.3,.6,.2,1)}
.sc-ring>span{display:grid;place-items:center;width:calc(100% - 14px);height:calc(100% - 14px);border-radius:50%;background:#0b0c0a;text-align:center;line-height:1.05;align-content:center}
.sc-ring b{font-size:20px;font-weight:800;font-variant-numeric:tabular-nums}
.sc-ring small{color:var(--muted);font-size:10px}
.sc-ring.big{width:150px;height:150px}
.sc-ring.big>span{width:calc(100% - 20px);height:calc(100% - 20px)}
.sc-ring.big b{font-size:32px;color:var(--gold2)}
.sc-ring.big small{font-size:12px}
.sc-ring.carbs{--ring:#c9a24c}
.sc-ring.fat{--ring:#8a6d22}
.sc-macros{display:flex;flex-wrap:wrap;gap:18px}
.sc-macro{display:grid;justify-items:center;gap:6px;color:#c9c8bf;font-size:13px;font-weight:700}
.sc-actions{display:flex;flex-wrap:wrap;align-items:center;gap:14px}
.sc-actions .gold-btn{padding:12px 18px}
.sc-link{color:var(--gold);font-weight:750;text-decoration:none}
.sc-link:hover{text-decoration:underline}

/* The week */
.sc-weekdone{flex:none;padding:5px 10px;border-radius:999px;background:rgba(120,197,141,.14);color:var(--green);font-size:12px;font-weight:800}
.sc-weekdone:empty{display:none}
.sc-week td:nth-child(2){color:#d7d6cd}
.sc-week .sc-rest td:nth-child(2){color:var(--muted)}
.sc-pbar{display:inline-block;width:64px;height:6px;margin-inline-end:8px;border-radius:6px;background:#22231d;overflow:hidden;vertical-align:middle}
.sc-pbar i{display:block;height:100%;width:calc(var(--w)*100%);border-radius:inherit;background:var(--gold);transition:width .7s cubic-bezier(.2,.8,.3,1) calc(.35s + var(--i)*.09s)}
.sc-week td small{color:var(--muted);font-size:12px}

/* Iron AI */
.sc-pro{flex:none;padding:5px 10px;border-radius:999px;background:var(--gold);color:#15120a;font-size:11px;font-weight:900}
.sc-msgs{display:grid;gap:10px}
.sc-msg{position:relative;max-width:86%;margin:0;padding:10px 13px;border:1px solid transparent;border-radius:14px;font-size:13px;line-height:1.45}
.sc-msg.me{justify-self:end;background:var(--gold);color:#15120a;border-end-end-radius:4px;font-weight:600}
.sc-msg.ai{justify-self:start;background:#1a1b17;border-color:#2c2d25;color:#dedcd3;border-end-start-radius:4px}

.sc-cta{justify-content:center;flex-wrap:wrap;margin:30px 0 0}
.sc-cta .outline-btn{display:inline-flex;align-items:center;text-decoration:none}

/* Animations, only while they're on (html.if-motion) */
@keyframes sc-pop{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}
@keyframes sc-reveal{from{color:transparent;background-color:transparent;border-color:transparent}}
@keyframes sc-typing{0%,100%{opacity:1}50%{opacity:.35}}
@keyframes sc-gone{to{opacity:0;visibility:hidden}}
@keyframes sc-pulse{0%{box-shadow:0 0 0 0 rgba(217,180,74,.55)}70%,100%{box-shadow:0 0 0 9px rgba(217,180,74,0)}}
html.if-motion .sc-table tbody tr{transition:opacity .45s ease calc(var(--i)*.11s),transform .45s cubic-bezier(.2,.8,.3,1) calc(var(--i)*.11s)}
html.if-motion .if-chart:not(.is-in) .sc-table tbody tr{opacity:0;transform:translateY(10px)}
html.if-motion .sc-tick{transition:transform .35s cubic-bezier(.3,1.6,.5,1) calc(.3s + var(--i,0)*.11s)}
html.if-motion .if-chart:not(.is-in) .sc-tick{transform:scale(0)}
html.if-motion .sc-dot{animation:sc-pulse 1.6s ease-out infinite}
html.if-motion .sc-meter i{transition:width 1.1s cubic-bezier(.2,.8,.3,1) .7s}
html.if-motion .if-chart:not(.is-in) .sc-meter i{width:0}
html.if-motion .sc-progress:not(.is-in) .sc-path{stroke-dashoffset:1}
html.if-motion .sc-progress:not(.is-in) .sc-area{opacity:0}
html.if-motion .sc-progress:not(.is-in) .sc-dots circle{transform:scale(0)}
html.if-motion .sc-progress:not(.is-in) .sc-bars i{transform:scaleY(0)}
html.if-motion .sc-result:not(.is-in) .sc-ring{--sc-p:0}
html.if-motion .sc-week:not(.is-in) .sc-pbar i{width:0}
html.if-motion .sc-chat:not(.is-in) .sc-msg{opacity:0}
html.if-motion .sc-chat.is-in .sc-msg{animation:sc-pop .45s ease var(--d) both}
html.if-motion .sc-chat.is-in .sc-msg.ai{animation:sc-pop .45s ease var(--d) both,sc-reveal .4s ease calc(var(--d) + 1.5s) both}
html.if-motion .sc-chat.is-in .sc-msg.ai:before{content:"";position:absolute;top:0;inset-inline-start:0;width:50px;height:34px;border:1px solid #2c2d25;border-radius:14px;border-end-start-radius:4px;background:radial-gradient(circle,var(--gold) 0 2.6px,transparent 3.2px) 9px 50%/11px 100% repeat-x content-box,#1a1b17;padding:0 7px;box-sizing:border-box;animation:sc-typing .7s ease-in-out var(--d) 2 alternate,sc-gone .2s ease calc(var(--d) + 1.45s) both}

@media(max-width:980px){
  .sc-grid{grid-template-columns:minmax(0,1fr)}
  .sc-calc{grid-template-columns:minmax(0,1fr)}
}
@media(max-width:700px){
  .showcase{padding:10px 16px 50px}
  .sc-numbers{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sc-numbers .stat{padding:16px 12px}
  .sc-numbers .stat:nth-child(3){border-inline-start:0}
  .sc-numbers .stat:nth-child(n+3){border-top:1px solid var(--line)}
  .sc-numbers .stat strong{font-size:34px}
  .sc-card{padding:16px;gap:14px}
  .sc-copy h3{font-size:20px}
  .sc-screen{padding:12px}
  .sc-table{font-size:12px}
  .sc-table td{padding:8px 4px}
  .sc-table th{padding:0 4px 8px}
  .sc-form{padding:14px}
  .sc-kcal{gap:14px}
  .sc-ring.big{width:124px;height:124px}
  .sc-ring.big b{font-size:26px}
  .sc-ring{width:76px;height:76px}
  .sc-ring b{font-size:17px}
  .sc-macros{justify-content:space-between;gap:10px}
  .sc-mini{grid-template-columns:minmax(0,1fr)}
  .sc-chips{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sc-pbar{width:44px}
  .sc-actions .gold-btn{width:100%}
}
@media(max-width:380px){
  .sc-inputs{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sc-inputs label:first-child{grid-column:1/-1}
  .sc-pbar{display:none}
}
