  :root{
    --bg:#0f1115; --bg2:#161a22; --card:#1b202b; --card2:#222836;
    --line:#2a3140; --txt:#e8edf5; --mut:#8b95a7; --mut2:#5d6677;
    --acc:#2dd4bf; --acc2:#1fae9d; --acctxt:#04130f;
    --good:#34d399; --warn:#fbbf24; --bad:#f87171; --blue:#38bdf8;
    --r:14px;
  }
  *{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
  html,body{margin:0;padding:0}
  body{
    background:var(--bg); color:var(--txt);
    font:15px/1.45 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
    padding-bottom:env(safe-area-inset-bottom);
    -webkit-text-size-adjust:100%;
  }
  a{color:inherit;text-decoration:none}
  button{font:inherit;color:inherit;border:0;background:none;cursor:pointer}
  input{font:inherit}

  /* ---- top bar ---- */
  header{
    position:sticky; top:0; z-index:20;
    background:rgba(15,17,21,.92); backdrop-filter:blur(10px);
    border-bottom:1px solid var(--line);
    display:flex; align-items:center; gap:10px;
    padding:max(10px,env(safe-area-inset-top)) 14px 10px;
  }
  header .back{font-size:22px; width:34px; height:34px; display:flex; align-items:center; justify-content:center; border-radius:9px; color:var(--mut)}
  header .back:active{background:var(--card)}
  header .title{flex:1; min-width:0}
  header .title b{display:block; font-size:17px; font-weight:700; white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
  header .title span{display:block; font-size:12px; color:var(--mut); white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
  header .menu{font-size:20px; width:34px; height:34px; display:flex; align-items:center; justify-content:center; border-radius:9px; color:var(--mut)}
  header .menu:active{background:var(--card)}

  #app{max-width:760px; margin:0 auto; padding:14px 14px calc(84px + env(safe-area-inset-bottom)); transition:padding-bottom .2s ease}
  body.rest-on #app{padding-bottom:calc(150px + env(safe-area-inset-bottom))}

  /* ---- bottom tab bar (3 icons) ---- */
  .tabbar{position:fixed; left:0; right:0; bottom:0; z-index:30; display:flex;
    background:rgba(15,17,21,.95); backdrop-filter:blur(12px); border-top:1px solid var(--line);
    padding-bottom:env(safe-area-inset-bottom); max-width:760px; margin:0 auto}
  .tabbar .tab{flex:1; display:flex; flex-direction:column; align-items:center; gap:4px; padding:9px 0 8px; color:var(--mut); font-size:11px; font-weight:600; transition:color .15s}
  .tabbar .tab .ti{line-height:0}
  .tabbar .tab .ti svg{width:25px; height:25px; display:block}
  .tabbar .tab.on{color:var(--acc)}
  .tabbar .tab:active{background:var(--card)}

  /* ---- generic card ---- */
  .card{
    background:var(--card); border:1px solid var(--line); border-radius:var(--r);
    padding:14px; margin-bottom:10px; display:block;
  }
  .card.tap:active{background:var(--card2)}
  .row{display:flex; align-items:center; gap:12px}
  .grow{flex:1; min-width:0}
  .ell{white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
  .mut{color:var(--mut)} .sm{font-size:13px} .xs{font-size:11.5px}

  .yr{font-size:12px; font-weight:700; letter-spacing:.08em; text-transform:uppercase; color:var(--mut2); margin:18px 4px 8px}
  .yr:first-child{margin-top:4px}

  .badge{font-size:11px; font-weight:700; padding:2px 8px; border-radius:999px; white-space:nowrap}
  .badge.now{background:var(--acc); color:var(--acctxt)}
  .badge.done{background:rgba(52,211,153,.15); color:var(--good)}
  .badge.prog{background:rgba(56,189,248,.14); color:var(--blue)}

  .wk-title{font-size:16px; font-weight:600}
  .chev{color:var(--mut2); font-size:20px}

  /* ---- program switch (Gym / Dumbbell) ---- */
  .progtabs{display:flex; gap:6px; background:var(--bg2); border:1px solid var(--line); border-radius:13px; padding:5px; margin:0 0 16px}
  .progtabs .pt{flex:1 1 0; min-width:0; white-space:nowrap; text-align:center; padding:11px 5px; border-radius:9px; font-weight:700; font-size:13px; color:var(--mut); transition:background .15s}
  .progtabs .pt.on{background:var(--acc); color:var(--acctxt)}
  .progtabs .pt:active{background:var(--card2)}
  .progtabs .pt.on:active{background:var(--acc2)}

  /* ---- dashboard ---- */
  .sec-h{font-size:12.5px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--mut2); margin:20px 4px 9px}
  .hero{display:block; background:linear-gradient(135deg,rgba(45,212,191,.18),rgba(45,212,191,.04)); border:1px solid rgba(45,212,191,.30); border-radius:16px; padding:16px}
  .hero:active{background:rgba(45,212,191,.1)}
  .hero-top{display:flex; justify-content:space-between; align-items:center}
  .hero-eyebrow{font-size:11.5px; font-weight:700; letter-spacing:.08em; color:var(--acc)}
  .hero-title{font-size:20px; font-weight:700; margin:6px 0 12px}
  .hero-bar{height:8px; background:rgba(255,255,255,.08); border-radius:99px; overflow:hidden}
  .hero-fill{height:100%; background:var(--acc); border-radius:99px}
  .hero-sub{font-size:13px; color:var(--mut); margin-top:8px}
  .stat-grid{display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-top:12px}
  .stat{background:var(--card); border:1px solid var(--line); border-radius:14px; padding:14px}
  .stat-ic{font-size:18px}
  .stat-val{font-size:24px; font-weight:800; margin-top:4px; line-height:1.05}
  .stat-lbl{font-size:12px; color:var(--mut); margin-top:3px}
  .startbtn{background:var(--acc); color:var(--acctxt); font-weight:700; font-size:13px; padding:8px 14px; border-radius:10px; white-space:nowrap; align-self:center}

  .pill{display:inline-flex; align-items:center; gap:5px; font-size:12px; color:var(--mut); background:var(--bg2); border:1px solid var(--line); padding:3px 9px; border-radius:999px}

  .wkout-name{font-size:16px; font-weight:600; margin-bottom:3px}
  .tags{display:flex; flex-wrap:wrap; gap:6px; margin-top:8px}

  /* ---- workout / blocks ---- */
  .blk{margin:0 0 14px}
  .blk-head{display:flex; align-items:center; gap:8px; margin:18px 2px 8px; color:var(--acc); font-size:12.5px; font-weight:700; letter-spacing:.04em; text-transform:uppercase}
  .blk-head .ln{flex:1; height:1px; background:linear-gradient(90deg,var(--line),transparent)}
  /* Superset / circuit / rounds: an accent line down the left groups the exercises that go together */
  .superset{border-left:3px solid var(--acc); padding-left:12px; margin-left:3px; box-shadow:-5px 0 14px -7px rgba(45,212,191,.6)}

  .instr{background:linear-gradient(180deg,rgba(45,212,191,.10),rgba(45,212,191,.03)); border:1px solid rgba(45,212,191,.28); border-left:3px solid var(--acc); border-radius:12px; padding:12px 14px; margin-bottom:14px}
  .instr h4{margin:0 0 6px; font-size:12px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--acc); display:flex; align-items:center; gap:6px}
  .instr p{margin:0; font-size:14px; line-height:1.5; color:var(--txt); white-space:pre-line}
  .wkmeta{display:flex; flex-wrap:wrap; gap:6px; margin:-2px 0 12px}
  .equip{display:flex; flex-wrap:wrap; gap:6px; align-items:center; margin:-2px 0 14px}
  .equip-h{font-size:12px; color:var(--mut); font-weight:700; margin-right:2px}
  .equip .pill{border-color:rgba(45,212,191,.3); color:var(--txt)}

  .ex{background:var(--card); border:1px solid var(--line); border-radius:var(--r); padding:12px; margin-bottom:10px}
  .ex-top{display:flex; gap:12px; align-items:flex-start; cursor:pointer}
  /* collapse/expand: tap the header row; the caret rotates, the body hides */
  .ex .caret{align-self:center; color:var(--mut2); transition:transform .18s; flex:none}
  .ex.clps .caret{transform:rotate(-90deg)}
  .ex.clps .ex-body{display:none}
  .thumb{width:54px; height:54px; border-radius:10px; object-fit:cover; background:var(--bg2); flex:none}
  .thumb.ph{display:flex; align-items:center; justify-content:center; font-size:22px; color:var(--mut2)}
  .thumb.ph .ic{width:30px; height:30px; color:var(--blue)}
  .ex-name{font-size:15.5px; font-weight:600; line-height:1.25}
  .ex-target{font-size:12.5px; color:var(--mut); margin-top:3px}
  .ex-target b{color:var(--txt); font-weight:600}
  /* "How to & muscles" reference card (data scraped from the coach's exercise library) */
  .exinfo{margin:8px 0 2px; border:1px solid var(--line); border-radius:10px; background:rgba(255,255,255,.02); overflow:hidden}
  .exinfo summary{cursor:pointer; list-style:none; padding:8px 12px; font-size:12.5px; font-weight:600; color:var(--blue); user-select:none}
  .exinfo summary::-webkit-details-marker{display:none}
  .exinfo[open] summary{border-bottom:1px solid var(--line)}
  .exinfo-body{padding:10px 12px}
  .exinfo-mus{display:flex; flex-wrap:wrap; gap:6px; margin-bottom:8px}
  .exinfo-mus:last-child{margin-bottom:0}
  .mtag{font-size:10.5px; font-weight:600; text-transform:capitalize; color:var(--txt); background:rgba(45,212,191,.12); border:1px solid rgba(45,212,191,.3); padding:2px 8px; border-radius:999px}
  .exinfo-how{margin:0; font-size:12.5px; line-height:1.5; color:var(--mut); white-space:pre-line}
  .exinfo-steps{margin:0; padding-left:20px; font-size:12.5px; line-height:1.55; color:var(--mut)}
  .exinfo-steps li{margin:0 0 5px} .exinfo-steps li:last-child{margin-bottom:0}
  .vbtn{flex:none; display:flex; align-items:center; gap:5px; font-size:12px; color:var(--blue); background:rgba(56,189,248,.1); border:1px solid rgba(56,189,248,.2); padding:5px 9px; border-radius:9px}
  .vbtn:active{background:rgba(56,189,248,.2)}

  .last{display:flex; align-items:center; gap:7px; margin-top:9px; font-size:12.5px; color:var(--mut)}
  .last .dot{width:6px; height:6px; border-radius:50%; background:var(--mut2); flex:none}
  .last b{color:var(--acc); font-weight:600}
  .last.none{color:var(--mut2)}
  .last .hbtn{margin-left:auto; color:var(--blue); font-size:12px; padding:2px 6px; border-radius:7px}
  .hist{margin-top:8px; padding:8px 10px; background:var(--bg2); border:1px solid var(--line); border-radius:10px; font-size:12.5px}
  .hist .h{display:flex; justify-content:space-between; gap:10px; padding:3px 0; color:var(--mut)}
  .hist .h span:first-child{color:var(--txt)}

  /* ---- set logging grid ---- */
  .sets{margin-top:11px}
  .sets-hd,.setrow{display:grid; grid-template-columns:34px 1fr 1fr 46px; gap:8px; align-items:center}
  .sets-hd{font-size:11px; color:var(--mut2); text-transform:uppercase; letter-spacing:.05em; margin-bottom:5px; padding:0 2px}
  .sets-hd span:first-child,.setrow .sn{text-align:center}
  .setrow{margin-bottom:7px}
  .setrow .sn{font-size:13px; color:var(--mut); font-weight:600}
  .setrow input{
    width:100%; text-align:center; background:var(--bg2); border:1px solid var(--line);
    color:var(--txt); border-radius:10px; padding:11px 4px; font-size:16px; font-weight:600;
    -moz-appearance:textfield; outline:none;
  }
  .setrow input::-webkit-outer-spin-button,.setrow input::-webkit-inner-spin-button{-webkit-appearance:none; margin:0}
  .setrow input:focus{border-color:var(--acc); background:#10161b}
  .setrow input::placeholder{color:var(--mut2); font-weight:400}
  .chk{
    height:42px; border-radius:10px; background:var(--bg2); border:1px solid var(--line);
    color:var(--mut2); font-size:18px; display:flex; align-items:center; justify-content:center;
  }
  .chk.on{background:var(--good); border-color:var(--good); color:#04130f}
  .row-done input{border-color:rgba(52,211,153,.4)}

  .ex-actions{display:flex; gap:8px; margin-top:4px}
  .lnk{font-size:12.5px; color:var(--mut); padding:6px 8px; border-radius:8px}
  .lnk:active{background:var(--bg2)}
  .lnk.del{color:var(--mut2)}

  .rest{display:inline-flex; align-items:center; gap:6px; font-size:12px; color:var(--mut2); background:var(--bg2); border:1px dashed var(--line); padding:5px 10px; border-radius:999px; margin:2px 0 10px}

  /* ---- finish (sits at the end, after all exercises) ---- */
  .finishrow{margin:22px 0 10px; display:flex; flex-direction:column; gap:10px}
  .btn{width:100%; text-align:center; padding:15px; border-radius:12px; font-weight:700; font-size:15px}
  .btn.primary{background:var(--acc); color:var(--acctxt)}
  .btn.primary:active{background:var(--acc2)}
  .btn.isdone{background:rgba(52,211,153,.16); color:var(--good); border:1px solid rgba(52,211,153,.4)}

  .progress{font-size:12.5px; color:var(--mut); text-align:center}
  .progress b{color:var(--txt)}

  .empty{text-align:center; color:var(--mut2); padding:60px 20px}
  .empty .big{font-size:40px; margin-bottom:10px}

  /* ---- sheet (menu) ---- */
  .scrim{position:fixed; inset:0; background:rgba(0,0,0,.5); z-index:40; opacity:0; pointer-events:none; transition:opacity .2s}
  .scrim.on{opacity:1; pointer-events:auto}
  .sheet{position:fixed; left:0; right:0; bottom:0; z-index:41; background:var(--bg2); border-top:1px solid var(--line); border-radius:18px 18px 0 0; padding:8px 14px calc(18px + env(safe-area-inset-bottom)); transform:translateY(110%); transition:transform .24s ease}
  .sheet.on{transform:none}
  .sheet .grab{width:38px; height:4px; border-radius:99px; background:var(--line); margin:8px auto 12px}
  .sheet h3{margin:2px 4px 10px; font-size:14px; color:var(--mut)}
  .mi{display:flex; align-items:center; gap:12px; padding:14px 8px; border-radius:11px; font-size:15px}
  .mi:active{background:var(--card)}
  .mi .ic{font-size:18px; width:24px; text-align:center}
  .mi.danger{color:var(--bad)}
  .mi small{display:block; color:var(--mut); font-size:12px; font-weight:400}

  .toast{position:fixed; left:50%; bottom:86px; transform:translateX(-50%) translateY(20px); background:var(--card2); border:1px solid var(--line); color:var(--txt); padding:11px 16px; border-radius:12px; font-size:13.5px; z-index:60; opacity:0; transition:.22s; pointer-events:none; max-width:90vw; text-align:center}
  .toast.on{opacity:1; transform:translateX(-50%) translateY(0)}

  /* ---- in-app video player ---- */
  .vmodal{position:fixed; inset:0; z-index:50; background:rgba(0,0,0,.93); display:none; flex-direction:column}
  .vmodal.on{display:flex}
  .vmodal-bar{display:flex; align-items:center; justify-content:space-between; gap:10px; padding:max(10px,env(safe-area-inset-top)) 16px 10px; color:#fff}
  .vmodal-bar .vt{font-size:14px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
  .vmodal-bar button{color:#fff; background:rgba(255,255,255,.14); border-radius:10px; padding:9px 14px; font-size:15px; font-weight:600; flex:none}
  .vmodal-bar button:active{background:rgba(255,255,255,.26)}
  .vmodal-body{flex:1; display:flex; align-items:center; justify-content:center; padding:0 12px 24px}
  .vwrap{width:100%; max-width:880px; aspect-ratio:16/9; background:#000; border-radius:12px; overflow:hidden}
  .vwrap iframe,.vwrap video{width:100%; height:100%; border:0; display:block; background:#000}

  /* ---- copy-last button ---- */
  .last .cpy{margin-left:auto; color:var(--acc); font-size:12px; font-weight:600; padding:3px 9px; border-radius:8px; border:1px solid rgba(45,212,191,.4)}
  .last .cpy:active{background:rgba(45,212,191,.16)}
  .last .hbtn{margin-left:8px}

  /* ---- rest timer bar ---- */
  #restbar{position:fixed; left:12px; right:12px; bottom:calc(72px + env(safe-area-inset-bottom)); z-index:55; display:none; align-items:center; gap:8px; background:var(--card2); border:1px solid var(--acc); border-radius:14px; padding:8px 10px; box-shadow:0 10px 34px rgba(0,0,0,.55)}
  #restbar.on{display:flex}
  #restbar .rb-b{background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:9px; padding:10px 11px; font-size:13px; font-weight:600; flex:none}
  #restbar .rb-skip{background:var(--acc); color:var(--acctxt); border-color:var(--acc)}
  #restbar .rb-mid{flex:1; min-width:0}
  #restbar .rb-t{font-size:14px; font-weight:700}
  #restbar .rb-p{height:5px; background:rgba(255,255,255,.1); border-radius:99px; margin-top:5px; overflow:hidden}
  #restbar .rb-p i{display:block; height:100%; width:0; background:var(--acc); border-radius:99px; transition:width .2s linear}
  #restbar.work .rb-t{color:var(--acc)}   /* same bar counting WORK (the "1 min" button on timed exercises) */

  /* ---- interval timer ---- */
  #itimer{position:fixed; inset:0; z-index:60; display:none; align-items:center; justify-content:center; background:rgba(0,0,0,.62); padding:16px}
  #itimer.on{display:flex}
  #itimer .it-card,#itimer .it-run{background:var(--bg2); border:1px solid var(--line); border-radius:18px; padding:20px; width:100%; max-width:380px; text-align:center}
  #itimer .it-h{font-size:18px; font-weight:700; margin-bottom:14px}
  #itimer .it-modes{display:flex; gap:6px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:4px; margin-bottom:14px}
  #itimer .it-mode{flex:1; padding:10px 6px; border-radius:9px; font-size:13px; font-weight:700; color:var(--mut)}
  #itimer .it-mode.on{background:var(--acc); color:var(--acctxt)}
  #itimer .it-stp{margin-bottom:11px}
  #itimer .it-stp-lbl{display:block; font-size:11px; color:var(--mut); text-transform:uppercase; letter-spacing:.04em; text-align:left; margin:0 2px 5px}
  #itimer .it-stp-ctl{display:flex; align-items:stretch; gap:8px}
  #itimer .it-stp-btn{width:56px; flex:none; background:var(--card); border:1px solid var(--line); color:var(--txt); border-radius:12px; font-size:28px; font-weight:700; line-height:1; touch-action:manipulation}
  #itimer .it-stp-btn:active{background:var(--acc); color:var(--acctxt); border-color:var(--acc)}
  #itimer .it-stp-val{flex:1; display:flex; align-items:center; justify-content:center; gap:3px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:8px}
  #itimer .it-stp-val input{width:100%; min-width:0; background:transparent; border:none; color:var(--txt); font-size:26px; font-weight:800; text-align:center; -moz-appearance:textfield; outline:none; padding:0}
  #itimer .it-stp-val input::-webkit-outer-spin-button,#itimer .it-stp-val input::-webkit-inner-spin-button{-webkit-appearance:none; margin:0}
  #itimer .it-stp-val span{font-size:14px; color:var(--mut); font-weight:600}
  #itimer .it-computed{font-size:13px; color:var(--acc); font-weight:600; text-align:center; margin:-3px 0 14px}
  #itimer .it-presets{display:flex; flex-wrap:wrap; gap:6px; justify-content:center; margin-bottom:16px}
  #itimer .it-presets button{background:var(--card); border:1px solid var(--line); color:var(--txt); border-radius:99px; padding:7px 12px; font-size:12.5px; font-weight:600}
  #itimer .it-presets button:active{background:var(--card2)}
  #itimer .it-row{display:flex; gap:10px}
  #itimer .it-go{flex:1; background:var(--acc); color:var(--acctxt); font-weight:800; font-size:16px; padding:15px; border-radius:12px}
  #itimer .it-x{background:var(--card); border:1px solid var(--line); color:var(--txt); font-weight:700; padding:15px 18px; border-radius:12px}
  #itimer .it-run{transition:background .25s}
  #itimer .it-phase{font-size:20px; font-weight:800; letter-spacing:.12em}
  #itimer .it-big{font-size:92px; font-weight:800; line-height:1.15; font-variant-numeric:tabular-nums}
  #itimer .it-meta{font-size:14px; color:var(--mut); margin-bottom:18px}

  /* ---- exercise swapper ---- */
  .swapnote{display:flex; align-items:center; gap:8px; margin-top:9px; font-size:12.5px; color:var(--warn)}
  .swapnote .undo{margin-left:auto; color:var(--blue); font-size:12px; padding:3px 9px; border-radius:7px}
  .swapnote .undo:active{background:var(--bg2)}
  .swapwrap{position:fixed; inset:0; z-index:58; background:rgba(0,0,0,.55); display:none; align-items:flex-end; justify-content:center}
  .swapwrap.on{display:flex}
  .swap-card{background:var(--bg2); border:1px solid var(--line); border-radius:18px 18px 0 0; width:100%; max-width:620px; max-height:82vh; display:flex; flex-direction:column; padding:14px 14px calc(14px + env(safe-area-inset-bottom))}
  .swap-h{display:flex; align-items:center; justify-content:space-between; font-size:16px; font-weight:700; margin-bottom:4px}
  .swap-h button{color:var(--mut); font-size:18px; width:32px; height:32px; border-radius:8px}
  .swap-h button:active{background:var(--card)}
  .swap-sub{font-size:12.5px; color:var(--mut); margin-bottom:10px}
  #swap-q{width:100%; background:var(--bg); border:1px solid var(--line); color:var(--txt); border-radius:11px; padding:12px 13px; font-size:15px; outline:none; margin-bottom:10px}
  #swap-q:focus{border-color:var(--acc)}
  .swap-list{overflow:auto; -webkit-overflow-scrolling:touch}
  .swap-it{display:flex; align-items:center; gap:10px; padding:13px 10px; border-radius:10px; font-size:14.5px; border-bottom:1px solid var(--line)}
  .swap-it:active{background:var(--card)}
  .swap-it.custom{color:var(--acc); font-weight:600}
  .swap-grp{font-size:11px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--mut2); padding:12px 10px 4px}
  .swap-it.sug{color:var(--acc); font-weight:600}
  .swap-empty{color:var(--mut2); text-align:center; padding:24px}

  /* ---- personal-best celebration ---- */
  .prpop{position:fixed; inset:0; z-index:70; display:none; align-items:center; justify-content:center; background:rgba(0,0,0,.45)}
  .prpop.on{display:flex; animation:prfade .25s}
  @keyframes prfade{from{opacity:0}to{opacity:1}}
  .prpop-c{position:relative; overflow:hidden; background:linear-gradient(160deg,#10302b,#162033); border:1px solid var(--acc); border-radius:20px; padding:26px 36px; text-align:center; box-shadow:0 18px 60px rgba(0,0,0,.6); animation:prpop .42s cubic-bezier(.2,1.3,.5,1)}
  @keyframes prpop{0%{transform:scale(.6); opacity:0}100%{transform:scale(1); opacity:1}}
  .prpop-emoji{font-size:48px; line-height:1}
  .prpop-t{font-size:13px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; color:var(--acc); margin-top:8px}
  .prpop-kg{font-size:40px; font-weight:900; margin:2px 0 1px}
  .prpop-n{font-size:14px; color:var(--mut); max-width:240px; margin:0 auto}
  .cft{position:absolute; top:-12px; width:8px; height:13px; border-radius:2px; opacity:.95; animation:cfall 1.5s linear forwards}
  @keyframes cfall{0%{transform:translateY(0) rotate(0); opacity:1}100%{transform:translateY(340px) rotate(560deg); opacity:0}}

  /* ---- progress charts ---- */
  .spark{width:100%; height:92px; display:block; margin:2px 0}

  /* ---- inline line icons (modern) ---- */
  .ic{width:16px; height:16px; display:inline-block; vertical-align:-3px; flex:none}
  .pill .ic{width:13px; height:13px; vertical-align:-2px}
  .stat-ic .ic{width:20px; height:20px; color:var(--acc)}
  .prpop-emoji .ic{width:46px; height:46px; color:var(--acc); stroke-width:1.7}

  /* ---- daily habits ---- */
  .habits{padding:4px 14px 12px}
  .hab-top{display:flex; align-items:center; justify-content:space-between; padding:8px 0 4px}
  .hab-sum{font-size:12.5px; color:var(--mut); font-weight:600}
  .hab-edit{font-size:12.5px; color:var(--acc); font-weight:700; padding:4px 8px; border-radius:8px}
  .hab-edit:active{background:var(--bg2)}
  .hab-row{display:flex; align-items:center; gap:12px; padding:10px 0}
  .hab-row + .hab-row{border-top:1px solid var(--line)}
  .hab-chk{width:27px; height:27px; flex:none; border-radius:50%; border:2px solid var(--line); background:var(--bg2); display:flex; align-items:center; justify-content:center; color:#04130f}
  .hab-chk.on{background:var(--good); border-color:var(--good)}
  .hab-chk .ic{width:15px; height:15px; stroke-width:3.2}
  .hab-del{width:27px; height:27px; flex:none; border-radius:50%; border:1px solid rgba(248,113,113,.5); color:var(--bad); display:flex; align-items:center; justify-content:center; background:transparent}
  .hab-del .ic{width:13px; height:13px}
  .hab-name{font-size:14.5px; font-weight:500}
  .hab-add{display:flex; gap:8px; align-items:center; padding-top:11px; margin-top:4px; border-top:1px solid var(--line)}
  .hab-add-in{flex:1; min-width:0; background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:10px; padding:11px 12px; font-size:14px; outline:none}
  .hab-add-in:focus{border-color:var(--acc)}
  .hab-add-btn{width:42px; height:42px; flex:none; border-radius:10px; background:var(--acc); color:var(--acctxt); display:flex; align-items:center; justify-content:center}
  .hab-add-btn .ic{width:18px; height:18px; stroke-width:2.6}

  /* ---- collapsible section header ---- */
  .sec-toggle{width:100%; display:flex; align-items:center; justify-content:space-between; background:none; margin:22px 4px 9px; padding:0; font-size:12.5px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--mut2)}
  .sec-toggle:active{opacity:.7}
  .sec-toggle .st-r{display:flex; align-items:center; gap:7px; color:var(--mut)}
  .sec-toggle .st-count{background:var(--bg2); border:1px solid var(--line); border-radius:999px; padding:2px 9px; font-size:11px; font-weight:700; color:var(--mut)}
  .sec-toggle .ic{width:16px; height:16px; transition:transform .2s}
  .sec-toggle.open .ic{transform:rotate(180deg)}
  .instr h4 .ic{width:14px; height:14px; color:var(--acc)}

  /* ---- today nudge card ---- */
  .today-card{display:flex; align-items:center; gap:11px; background:linear-gradient(135deg,rgba(45,212,191,.16),rgba(45,212,191,.04)); border:1px solid rgba(45,212,191,.3); border-radius:14px; padding:13px 14px; margin-top:10px}
  .today-card:active{background:rgba(45,212,191,.1)}
  .today-card > .ic{width:22px; height:22px; color:var(--acc)}
  .today-card .tc-lbl{font-size:10.5px; font-weight:800; letter-spacing:.09em; color:var(--acc)}
  .today-card .tc-name{font-size:15px; font-weight:700; margin-top:1px}

  /* ---- calendar ---- */
  .cal-nav{display:flex; align-items:center; justify-content:space-between; margin:2px 2px 14px}
  .cal-arrow{width:40px; height:40px; border-radius:11px; background:var(--card); border:1px solid var(--line); color:var(--txt); display:flex; align-items:center; justify-content:center}
  .cal-arrow:active{background:var(--card2)}
  .cal-arrow[data-cal=prev] .ic{transform:rotate(90deg)}
  .cal-arrow[data-cal=next] .ic{transform:rotate(-90deg)}
  .cal-range{font-weight:700; font-size:15px}
  .cal-day{display:flex; gap:12px; padding:12px 6px; border-bottom:1px solid var(--line)}
  .cal-day.today{background:linear-gradient(90deg,rgba(45,212,191,.08),transparent); border-radius:12px}
  .cal-d{width:42px; flex:none; text-align:center; padding-top:2px}
  .cal-dow{display:block; font-size:11px; color:var(--mut2); text-transform:uppercase; font-weight:700}
  .cal-num{display:block; font-size:20px; font-weight:800}
  .cal-day.today .cal-num{color:var(--acc)}
  .cal-items{flex:1; min-width:0; display:flex; flex-direction:column; gap:7px}
  .cal-chip{display:flex; align-items:center; gap:6px; background:var(--card); border:1px solid var(--line); border-radius:10px; padding:8px 8px 8px 11px}
  .cal-chip.done{border-color:rgba(52,211,153,.4)}
  .cal-open{flex:1; min-width:0; display:flex; align-items:center; gap:7px; color:var(--txt); font-weight:600; font-size:14px; text-align:left}
  .cal-open .ic{color:var(--good); width:15px; height:15px; flex:none}
  .cal-prog-tag{flex:none; font-size:10px; font-weight:700; color:var(--acc); background:rgba(45,212,191,.12); border:1px solid rgba(45,212,191,.3); padding:1px 6px; border-radius:999px}
  .cal-x{flex:none; color:var(--mut2); width:26px; height:26px; display:flex; align-items:center; justify-content:center; border-radius:7px}
  .cal-x:active{background:var(--bg2)}
  .cal-x .ic{width:13px; height:13px}
  .cal-add{align-self:flex-start; display:inline-flex; align-items:center; gap:5px; color:var(--mut); font-size:12.5px; font-weight:600; padding:6px 2px}
  .cal-add .ic{width:14px; height:14px; color:var(--acc)}

  /* ---- body weight log ---- */
  .wt-now{font-size:32px; font-weight:800; line-height:1}
  .wt-now span{font-size:15px; font-weight:600; color:var(--mut)}
  .wt-add{display:flex; gap:8px; margin-top:13px}
  .wt-add input{flex:1; min-width:0; background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:11px; padding:12px 13px; font-size:16px; font-weight:600; outline:none; -moz-appearance:textfield}
  .wt-add input::-webkit-outer-spin-button,.wt-add input::-webkit-inner-spin-button{-webkit-appearance:none; margin:0}
  .wt-add input::placeholder{color:var(--mut2); font-weight:400}
  .wt-add input:focus{border-color:var(--acc)}
  .wt-add button{flex:none; background:var(--acc); color:var(--acctxt); font-weight:700; padding:0 18px; border-radius:11px}
  .wt-add button:active{background:var(--acc2)}
  .wt-list{margin-top:6px}
  .wt-row{display:flex; align-items:center; gap:10px; padding:9px 0; border-top:1px solid var(--line); font-size:13.5px}
  .wt-row .wt-d{color:var(--mut); flex:1}
  .wt-row .wt-k{font-weight:700}
  .wt-row .wt-x{flex:none; color:var(--mut2); width:28px; height:28px; display:flex; align-items:center; justify-content:center; border-radius:8px}
  .wt-row .wt-x:active{background:var(--bg2)}
  .wt-row .wt-x .ic{width:13px; height:13px}

  /* ---- how did it go? (effort + notes) ---- */
  .feel-h{font-weight:700; margin-bottom:3px}
  .feel-lbl{margin-bottom:7px}
  .rpe{display:flex; gap:6px; flex-wrap:wrap; margin-bottom:12px}
  .rpe-b{flex:1 1 0; min-width:28px; padding:11px 0; border-radius:9px; background:var(--bg2); border:1px solid var(--line); color:var(--mut); font-weight:700; font-size:14px}
  .rpe-b.on{background:var(--acc); border-color:var(--acc); color:var(--acctxt)}
  .rpe-b:active{background:var(--card2)}
  .sessnote{display:block; width:100%; min-height:62px; resize:vertical; background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:11px; padding:11px 12px; font-size:14.5px; line-height:1.45; outline:none; font-family:inherit}
  .sessnote:focus{border-color:var(--acc)}
  .sessnote::placeholder{color:var(--mut2)}

  /* ---- end-of-workout summary ---- */
  .summ{position:fixed; inset:0; z-index:65; display:none; align-items:center; justify-content:center; background:rgba(0,0,0,.55); padding:18px}
  .summ.on{display:flex}
  /* Slide/scale only — never animate opacity, so the card is always visible even if the animation is skipped or throttled. */
  .summ-c{background:linear-gradient(160deg,#10302b,#162033); border:1px solid var(--acc); border-radius:20px; padding:22px 22px 18px; width:100%; max-width:360px; text-align:center; box-shadow:0 18px 60px rgba(0,0,0,.6); animation:summpop .42s cubic-bezier(.2,1.3,.5,1)}
  @keyframes summpop{from{transform:translateY(12px) scale(.97)}to{transform:none}}
  .summ-emoji{font-size:40px; line-height:1}
  .summ-t{font-size:13px; font-weight:800; letter-spacing:.06em; text-transform:uppercase; color:var(--acc); margin-top:6px}
  .summ-vol{font-size:40px; font-weight:900; margin:6px 0 2px; line-height:1}
  .summ-vol span{font-size:16px; color:var(--mut); font-weight:700}
  .summ-hi{font-size:23px; font-weight:800; margin:8px 0 2px; line-height:1.15}
  .summ-sub{font-size:13px; color:var(--mut)}
  .summ-grid{display:flex; flex-wrap:wrap; gap:9px; margin:15px 0 4px}
  .summ-stat{flex:1 1 64px; min-width:64px; background:rgba(255,255,255,.05); border:1px solid var(--line); border-radius:12px; padding:11px 6px}
  .summ-stat b{display:block; font-size:21px; font-weight:800}
  .summ-stat span{font-size:11px; color:var(--mut)}
  .summ-prs{margin:12px 0 4px; font-size:13.5px}
  .summ-pr{display:flex; align-items:center; justify-content:center; gap:6px; color:var(--good); font-weight:700; padding:4px 0}
  .summ-pr .ic{width:15px; height:15px}
  .summ-btn{width:100%; background:var(--acc); color:var(--acctxt); font-weight:800; padding:14px; border-radius:12px; font-size:15px; margin-top:14px}
  .summ-btn:active{background:var(--acc2)}

  /* ---- quick 1RM calculator ---- */
  .orm-row{display:flex; align-items:flex-end; gap:10px}
  .orm-f{flex:1; min-width:0}
  .orm-f label{display:block; font-size:11px; color:var(--mut); text-transform:uppercase; letter-spacing:.04em; margin:0 2px 5px}
  .orm-f input{width:100%; background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:11px; padding:12px 10px; font-size:18px; font-weight:700; text-align:center; outline:none; -moz-appearance:textfield}
  .orm-f input::-webkit-outer-spin-button,.orm-f input::-webkit-inner-spin-button{-webkit-appearance:none; margin:0}
  .orm-f input::placeholder{color:var(--mut2); font-weight:400}
  .orm-f input:focus{border-color:var(--acc)}
  .orm-x{font-size:18px; color:var(--mut2); font-weight:700; padding-bottom:12px}
  .orm-out{margin-top:13px; text-align:center; font-size:15px; color:var(--mut)}
  .orm-out.on{color:var(--txt)}
  .orm-out b{color:var(--acc); font-size:22px; font-weight:800}

  /* ---- workout duration timer ---- */
  .wtimer{margin:-2px 0 14px; width:100%; border-radius:12px; padding:13px 14px; font-size:14px; display:flex; align-items:center; gap:10px}
  .wtimer.start{background:var(--acc); color:var(--acctxt); font-weight:800; font-size:15px; justify-content:center}
  .wtimer.start:active{background:var(--acc2)}
  .wtimer.on{background:var(--card2); border:1px solid var(--acc); position:sticky; top:var(--hh,58px); z-index:18; box-shadow:0 8px 22px rgba(0,0,0,.5)}
  .wtimer.on .wt-ic{font-size:16px}
  .wtimer.on .wt-run{font-size:21px; font-weight:800; font-variant-numeric:tabular-nums}
  .wtimer.on .wt-lbl{color:var(--mut); font-size:12.5px}
  .wtimer.on .wt-reset{margin-left:auto; color:var(--mut); font-size:12px; padding:5px 10px; border-radius:8px; border:1px solid var(--line)}
  .wtimer.on .wt-reset:active{background:var(--bg2)}
  .wtimer.done{background:var(--bg2); border:1px solid var(--line); color:var(--mut); justify-content:center}
  .wtimer.done b{color:var(--txt)}

  /* ---- cardio movement tag ---- */
  .cardio-badge{display:inline-block; font-size:10.5px; font-weight:700; color:var(--blue); background:rgba(56,189,248,.12); border:1px solid rgba(56,189,248,.3); padding:1px 7px; border-radius:999px; margin-left:7px; vertical-align:middle}
  .pb-badge{display:inline-block; font-size:10.5px; font-weight:800; color:var(--warn); background:rgba(251,191,36,.12); border:1px solid rgba(251,191,36,.35); padding:1px 7px; border-radius:999px; margin-left:7px; vertical-align:middle; white-space:nowrap}
  /* cardio cards keep the standard border — the 🏃 badge is the cardio signal (no per-box glow) */

  /* ---- favourite (save workout) ---- */
  .pill.fav-pill{cursor:pointer; font-weight:700}
  .pill.fav-pill.on{color:#ff4d6d; border-color:rgba(255,77,109,.5); background:rgba(255,77,109,.1)}

  /* ================= EvolveYou section ================= */
  /* workout section divider (Warm-up / Stretch / Finisher) */
  .wsection{margin:18px 2px 8px; font-size:12px; font-weight:700; letter-spacing:.08em; text-transform:uppercase; color:var(--warn)}
  /* progtabs: EvolveYou chip */
  .progtabs .pt.ev{color:#a78bfa}
  .progtabs .pt.ev.on{background:linear-gradient(135deg,#a855f7,#6366f1); color:#fff}
  .progtabs .pt.ev.on:active{filter:brightness(.92)}
  /* explore hub */
  .ev-intro{font-size:13px; line-height:1.5; color:var(--mut); margin:2px 2px 14px}
  .ev-hub{display:flex; flex-direction:column; gap:10px; margin-bottom:6px}
  .ev-hubcard{display:flex; align-items:center; gap:13px; background:var(--card); border:1px solid var(--line); border-radius:var(--r); padding:15px 14px}
  .ev-hubcard:active{background:var(--card2)}
  .ev-hubcard .ev-emo{flex:none; width:30px; display:flex; justify-content:center; color:var(--acc)}
  .ev-hubcard .ev-emo .ic{width:24px; height:24px}
  .ev-hubcard .ev-emo.ev-emoji{font-size:22px; line-height:1}
  .recipe-img.ph .ic{width:34px; height:34px; color:var(--mut2)}
  /* follow-along class: play button + empty-day note */
  .playclass{display:flex; align-items:center; justify-content:center; gap:9px; width:100%; margin:2px 0 6px; padding:15px; border-radius:var(--r); background:linear-gradient(135deg,var(--acc),var(--acc2)); color:var(--acctxt); font-weight:700; font-size:15px}
  .playclass:active{filter:brightness(.94)}
  .playclass .ic{width:20px; height:20px}
  .playclass.hero{flex-direction:column; gap:7px; padding:30px 16px; font-size:16px; margin:2px 0 10px}
  .playclass.hero .ic{width:38px; height:38px}
  .playclass.hero small{font-weight:600; font-size:12px; opacity:.92}
  .emptywk{display:flex; align-items:center; gap:13px; background:var(--card); border:1px solid var(--line); border-radius:var(--r); padding:16px 14px; margin:4px 0}
  .emptywk .ic{width:26px; height:26px; color:var(--mut2); flex:none}
  .emptywk b{display:block; font-size:14px} .emptywk small{display:block; color:var(--mut); font-size:12.5px; margin-top:2px}
  .ev-hubcard b{display:block; font-size:15px; font-weight:700}
  .ev-hubcard small{display:block; font-size:12.5px; color:var(--mut); margin-top:2px}
  .ev-trainer-h{font-size:13px; font-weight:700; color:var(--acc); margin:14px 4px 8px}
  .prog-about{background:var(--card); border:1px solid var(--line); border-radius:var(--r); padding:16px 15px; margin:2px 0 14px}
  .pa-level{font-size:11.5px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--acc); margin-bottom:4px}
  .pa-name{font-size:20px; font-weight:800; line-height:1.15}
  .pa-with{font-size:13px; color:var(--mut); margin:3px 0 11px}
  .prog-about p{font-size:13.5px; line-height:1.55; color:var(--mut); margin:0 0 9px}
  .prog-about p:last-child{margin-bottom:0}
  .ev-heart{flex:none; background:none; border:none; font-size:21px; line-height:1; color:var(--mut2); padding:2px 6px; cursor:pointer; -webkit-tap-highlight-color:transparent}
  .ev-heart.on{color:#ff5a7a}
  .ev-heart:active{transform:scale(.85)}
  .ev-searchbar{display:flex; align-items:center; gap:10px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:12px 14px; margin:0 0 14px; color:var(--mut)}
  .ev-searchbar .ic{width:19px; height:19px; color:var(--mut2); flex:none}
  .ev-searchbar span{font-size:14px}
  .ev-search-input{width:100%; box-sizing:border-box; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:13px 14px; margin:2px 0 12px; font-size:16px; color:var(--txt)}
  .ev-search-input:focus{outline:none; border-color:var(--acc)}
  .ev-prog .pill.lvl{color:#c4b5fd; border-color:rgba(168,85,247,.4); background:rgba(168,85,247,.12)}
  /* backup reminder card (dashboard) */
  .backup-nudge{display:flex; align-items:center; gap:13px; border-color:rgba(251,191,36,.4); background:rgba(251,191,36,.07)}
  .backup-nudge .bn-ic{flex:none; width:34px; height:34px; display:flex; align-items:center; justify-content:center; border-radius:9px; background:rgba(251,191,36,.14); color:var(--warn)}
  .backup-nudge .bn-ic .ic{width:20px; height:20px}
  .backup-nudge .bn-t{font-weight:700; color:var(--warn)}
  /* "About this program" inline dropdown on a program card */
  .prog-drop{margin-top:11px; border-top:1px solid var(--line)}
  .prog-drop summary{list-style:none; display:flex; align-items:center; gap:7px; padding:10px 2px 2px; font-size:13px; font-weight:700; color:var(--acc); cursor:pointer}
  .prog-drop summary::-webkit-details-marker{display:none}
  .prog-drop summary .ic{width:15px; height:15px; flex:none}
  .prog-drop .pd-caret{margin-left:auto; color:var(--mut2); transition:transform .2s}
  .prog-drop[open] .pd-caret{transform:rotate(180deg)}
  .prog-drop-body{padding:6px 2px 2px}
  .prog-drop-body p{margin:0 0 8px; font-size:13px; line-height:1.55; color:var(--mut)}
  .prog-drop-body p:last-child{margin-bottom:2px}
  /* meal-type tabs */
  .ev-tabs{display:flex; gap:7px; overflow-x:auto; padding:2px 2px 10px; -webkit-overflow-scrolling:touch; scrollbar-width:none}
  .ev-tabs::-webkit-scrollbar{display:none}
  .ev-tab{flex:none; padding:8px 13px; border-radius:999px; font-size:13px; font-weight:600; color:var(--mut); background:var(--bg2); border:1px solid var(--line); white-space:nowrap}
  .ev-tab.on{background:var(--acc); color:var(--acctxt); border-color:var(--acc)}
  /* filter / quiz toggle chips */
  .fchips{display:flex; flex-wrap:wrap; gap:8px; margin:2px 2px 6px}
  .fchip{padding:9px 13px; border-radius:999px; font-size:13px; font-weight:600; color:var(--txt); background:var(--bg2); border:1px solid var(--line); white-space:nowrap; transition:background .12s, border-color .12s}
  .fchip:active{transform:scale(.96)}
  .fchip.on{background:var(--acc); color:var(--acctxt); border-color:var(--acc)}
  .fresult-h{display:flex; align-items:center; justify-content:space-between; gap:10px; margin:20px 2px 2px}
  .fclear{font-size:13px; font-weight:700; color:var(--acc); padding:4px 2px}
  .fclear:active{opacity:.6}
  .quiz-why{display:flex; align-items:center; gap:6px; font-size:12.5px; font-weight:600; color:var(--good); margin:12px 2px 6px}
  .quiz-why .ic{width:15px; height:15px; flex:none}
  .ev-morelink{display:block; text-align:center; font-size:13px; font-weight:700; color:var(--acc); padding:10px 0 4px}
  .ev-morelink:active{opacity:.6}
  /* shopping list */
  .shop-bar{margin:0 0 12px}
  .shop-bar .chev{margin-left:auto}
  .shop-recipes{display:flex; flex-wrap:wrap; gap:7px; margin:2px 2px 6px}
  .shop-rchip{font-size:12.5px; font-weight:600; color:var(--mut); background:var(--bg2); border:1px solid var(--line); padding:6px 11px; border-radius:999px}
  .shop-list{display:flex; flex-direction:column; gap:8px}
  .shop-item{display:flex; align-items:center; gap:11px; width:100%; text-align:left; background:var(--card); border:1px solid var(--line); border-radius:11px; padding:12px 13px; font-size:14px; color:var(--txt)}
  .shop-item:active{background:var(--card2)}
  .shop-item .shop-check{flex:none; width:22px; height:22px; border-radius:6px; border:1.5px solid var(--line); display:flex; align-items:center; justify-content:center; color:var(--acctxt)}
  .shop-item .shop-check .ic{width:15px; height:15px}
  .shop-item.on{color:var(--mut2)}
  .shop-item.on .shop-name{text-decoration:line-through}
  .shop-item.on .shop-check{background:var(--acc); border-color:var(--acc)}
  /* recipe grid */
  .recipe-grid{display:grid; grid-template-columns:1fr 1fr; gap:11px}
  .recipe-card{position:relative; background:var(--card); border:1px solid var(--line); border-radius:var(--r); overflow:hidden; display:flex; flex-direction:column}
  .recipe-card:active{background:var(--card2)}
  .recipe-heart{position:absolute; top:6px; right:6px; z-index:2; width:32px; height:32px; border-radius:999px; background:rgba(10,12,16,.55); backdrop-filter:blur(3px); color:#fff; font-size:18px; line-height:1; display:flex; align-items:center; justify-content:center; -webkit-tap-highlight-color:transparent}
  .recipe-heart.on{color:#ff5a7a}
  .recipe-heart:active{transform:scale(.85)}
  .recipe-img{aspect-ratio:4/3; background:var(--bg2); overflow:hidden}
  .recipe-img img{width:100%; height:100%; object-fit:cover}
  .recipe-img.ph{display:flex; align-items:center; justify-content:center; font-size:30px; color:var(--mut2)}
  .recipe-body{padding:9px 10px 11px}
  .recipe-name{font-size:13px; font-weight:600; line-height:1.3}
  .recipe-meta{display:flex; flex-wrap:wrap; gap:4px 10px; margin-top:6px; font-size:11px; color:var(--mut)}
  /* recipe detail */
  .recipe-hero{border-radius:var(--r); overflow:hidden; margin-bottom:14px; aspect-ratio:16/10; background:var(--bg2)}
  .recipe-hero img{width:100%; height:100%; object-fit:cover}
  .macros{display:grid; grid-template-columns:repeat(4,1fr); gap:8px; margin-bottom:12px}
  .macro{background:var(--card); border:1px solid var(--line); border-radius:12px; padding:11px 6px; text-align:center}
  .macro-v{font-size:17px; font-weight:800; color:var(--acc)}
  .macro-l{font-size:10.5px; color:var(--mut); margin-top:3px}
  .recipe-facts{display:flex; flex-wrap:wrap; gap:7px; margin-bottom:10px}
  .ingredients{margin:0 0 6px; padding:0; list-style:none}
  .ingredients li{padding:9px 2px; border-bottom:1px solid var(--line); font-size:14px}
  .ingredients li:last-child{border-bottom:none}
  .ing-amt{display:inline-block; min-width:70px; font-weight:700; color:var(--txt)}
  .method{margin:0; padding-left:22px}
  .method li{margin:0 0 10px; font-size:14px; line-height:1.55}

  /* ---- "My data" tab: Garmin snapshot + food tracker ---- */
  .md-asof{background:var(--bg2); border:1px solid var(--line); border-radius:12px; padding:10px 12px; font-size:12.5px; font-weight:600; color:var(--mut); margin-bottom:14px}
  .md-asof small{display:block; font-weight:500; color:var(--mut2); font-size:11px; margin-top:2px}
  .md-stats{display:grid; grid-template-columns:1fr 1fr; gap:9px}
  .md-stat{background:var(--card); border:1px solid var(--line); border-radius:14px; padding:12px}
  .md-stat.good{border-color:rgba(52,211,153,.4)}
  .md-stat.warn{border-color:rgba(245,158,11,.4)}
  .md-stat.stale{opacity:.72}
  .md-stat-l{font-size:11px; font-weight:700; letter-spacing:.03em; text-transform:uppercase; color:var(--mut2)}
  .md-stat-v{font-size:22px; font-weight:800; margin:4px 0 2px}
  .md-stat-s{font-size:11.5px; color:var(--mut); line-height:1.35}
  .md-sec{font-size:12.5px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--mut2); margin:22px 4px 9px}
  .md-sec-top{margin-top:26px}
  .md-spark{display:flex; align-items:flex-end; gap:3px; height:52px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:8px 10px}
  .md-spark i{flex:1; background:linear-gradient(180deg,var(--acc),rgba(45,212,191,.25)); border-radius:3px 3px 0 0; min-height:3px}
  .md-acts{display:flex; flex-direction:column; gap:7px}
  .md-act{display:flex; align-items:center; gap:11px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:11px 12px}
  .md-act-i{font-size:18px}
  .md-act b{display:block; font-size:14px; font-weight:600}
  .md-act small{display:block; color:var(--mut); font-size:11.5px; margin-top:1px}
  .md-act-d{font-size:11.5px; color:var(--mut2); font-weight:600; white-space:nowrap}
  .md-daynav{display:flex; align-items:center; justify-content:space-between; background:var(--bg2); border:1px solid var(--line); border-radius:12px; padding:7px 8px; margin-bottom:9px}
  .md-daynav b{font-size:14.5px}
  .md-daynav button{padding:4px 14px; font-size:19px; color:var(--mut); border-radius:8px}
  .md-daynav button:disabled{opacity:.25}
  .md-daytype{display:flex; align-items:center; gap:7px; flex-wrap:wrap; margin-bottom:12px}
  .md-dt{flex:1 1 0; min-width:0; padding:10px 6px; border-radius:10px; background:var(--bg2); border:1px solid var(--line); font-size:13px; font-weight:700; color:var(--mut); white-space:nowrap}
  .md-dt.on{background:var(--acc); border-color:var(--acc); color:var(--acctxt)}
  .md-dt-auto{flex:0 0 100%; font-size:11.5px; color:var(--mut2); text-align:center; padding:2px}
  .md-nudge{background:rgba(245,158,11,.10); border:1px solid rgba(245,158,11,.35); border-radius:12px; padding:11px 13px; font-size:13px; line-height:1.45; margin-bottom:13px}
  .md-nudge.ok{background:rgba(52,211,153,.10); border-color:rgba(52,211,153,.35)}
  .md-bars{display:flex; flex-direction:column; gap:13px}
  .md-bar-t{display:flex; justify-content:space-between; font-size:13px; font-weight:600; margin-bottom:5px}
  .md-bar-t b{font-size:15px}
  .md-bar-track{height:9px; background:var(--bg2); border-radius:999px; overflow:hidden}
  .md-bar-fill{height:100%; background:linear-gradient(90deg,var(--acc),#38bdf8); border-radius:999px; transition:width .25s}
  .md-bar.hit .md-bar-fill{background:linear-gradient(90deg,#34d399,#2dd4bf)}
  .md-bar-s{font-size:11.5px; color:var(--mut); margin-top:4px}
  .md-bar.hit .md-bar-s{color:var(--good)}
  .md-items{display:flex; flex-direction:column; gap:7px; margin-top:16px}
  .md-item{display:flex; align-items:center; gap:10px; background:var(--card); border:1px solid var(--line); border-radius:12px; padding:10px 12px}
  .md-item b{display:block; font-size:14px; font-weight:600}
  .md-item small{display:block; color:var(--mut); font-size:11.5px; margin-top:1px}
  .md-x{color:var(--mut2); padding:6px 8px; font-size:14px}
  .md-add{width:100%; margin-top:16px; padding:14px; border-radius:14px; background:var(--acc); color:var(--acctxt); font-weight:700; font-size:15px}
  .md-addpanel{margin-top:12px; background:var(--card); border:1px solid var(--line); border-radius:14px; padding:13px}
  .md-sub{font-size:11px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--mut2); margin:12px 2px 7px}
  .md-sub:first-child{margin-top:0}
  .md-chips{display:flex; flex-wrap:wrap; gap:6px}
  .md-chip{background:var(--bg2); border:1px solid var(--line); border-radius:999px; padding:7px 12px; font-size:12.5px; font-weight:600; color:var(--txt)}
  .md-search,.md-manual input{width:100%; background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:11px; padding:11px 12px; font-size:15px; outline:none}
  .md-search:focus,.md-manual input:focus{border-color:var(--acc)}
  .md-res{display:flex; flex-direction:column; gap:6px; margin-top:8px}
  .md-res-row{display:flex; align-items:center; gap:10px; text-align:left; background:var(--bg2); border:1px solid var(--line); border-radius:11px; padding:10px 12px; color:var(--txt)}
  .md-res-row b{display:block; font-size:13.5px; font-weight:600}
  .md-res-row small{display:block; color:var(--mut); font-size:11px; margin-top:1px}
  .md-res-row span{color:var(--acc); font-size:18px; font-weight:700}
  .md-manual{display:flex; flex-direction:column; gap:8px}
  .md-mrow{display:grid; grid-template-columns:1fr 1fr; gap:8px}
  .md-mrow label{font-size:11px; font-weight:700; letter-spacing:.03em; text-transform:uppercase; color:var(--mut2)}
  .md-mrow input{margin-top:3px}
  .md-save{padding:12px; border-radius:11px; background:var(--acc); color:var(--acctxt); font-weight:700; font-size:14.5px}
  .md-stat.tapcard{text-align:left; width:100%; display:block}
  .md-stat.tapcard:active{background:var(--card2)}
  .md-stat-go{font-size:11px; font-weight:700; color:var(--acc); margin-top:6px}
  .md-tag{float:right; font-size:9.5px; font-weight:800; letter-spacing:.04em; padding:1px 6px; border-radius:999px}
  .md-tag.good{background:rgba(52,211,153,.18); color:var(--good)}
  .md-tag.warn{background:rgba(245,158,11,.18); color:var(--warn)}
  .md-key{font-size:11.5px; line-height:1.5; color:var(--mut); background:var(--bg2); border:1px solid var(--line); border-radius:11px; padding:9px 11px; margin-top:10px}
  .md-key .k-good{color:var(--good)} .md-key .k-warn{color:var(--warn)}
  .md-chart{display:flex; gap:8px; align-items:stretch}
  .md-chart-y{display:flex; flex-direction:column; justify-content:space-between; font-size:10px; color:var(--mut2); font-weight:600; padding:2px 0; white-space:nowrap}
  .md-chart .md-spark{flex:1; height:74px}
  .md-cap{font-size:12px; line-height:1.5; color:var(--mut); margin:8px 2px 0}
  .md-cap b{color:var(--txt)}
  .md-wform{margin-top:2px}
  .md-wrow{display:grid; grid-template-columns:1fr 1fr auto; gap:8px; align-items:end}
  .md-wrow label{font-size:11px; font-weight:700; letter-spacing:.03em; text-transform:uppercase; color:var(--mut2)}
  .md-wrow input{width:100%; background:var(--bg2); border:1px solid var(--line); color:var(--txt); border-radius:11px; padding:11px 12px; font-size:16px; outline:none; margin-top:3px}
  .md-wrow input:focus{border-color:var(--acc)}
  .md-wrow .md-save{padding:12px 16px}
  #mdWeight{background:var(--card); border:1px solid var(--line); border-radius:14px; padding:13px; margin-top:11px}
  /* line icons standing in for the old emoji — keep them the same size as the text they sit beside */
  .cardio-badge .ic,.swapnote .ic,.lnk .ic,.swap-h .ic{width:14px; height:14px; vertical-align:-2px}
  .empty .big .ic{width:34px; height:34px}
  .md-act-i .ic{width:19px; height:19px; color:var(--mut); display:block}
