:root {
  --bg: #F4F3EF;
  --card: #FFFFFF;
  --ink: #1B1B18;
  --muted: #65645D;
  --faint: #9A988F;
  --line: #E2E0D8;
  --line-2: #EEEDE7;
  --field: #FAFAF7;
  --field-line: #D4D2C9;
  --accent: #2F6B4F;
  --accent-ink: #FFFFFF;
  --accent-soft: #EAF2ED;
  --warn-soft: #FBEBDD;
  --warn: #9A4A12;
  --btn: #1B1B18;
  --btn-ink: #FFFFFF;
  --font: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
  --mono: "Cascadia Mono", "SF Mono", ui-monospace, Menlo, Consolas, monospace;
  --radius: 14px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151513;
    --card: #1E1E1B;
    --ink: #EDECE6;
    --muted: #A6A59C;
    --faint: #75746C;
    --line: #2F2F2B;
    --line-2: #292925;
    --field: #191917;
    --field-line: #3C3C37;
    --accent: #6FBF94;
    --accent-ink: #0F1A14;
    --accent-soft: #1F3328;
    --warn-soft: #3A2A1C;
    --warn: #F0B27A;
    --btn: #EDECE6;
    --btn-ink: #151513;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.45; -webkit-text-size-adjust: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); }
h1, h2, h3 { margin: 0; line-height: 1.2; }
h1 { font-size: 28px; font-weight: 600; }
h2 { font-size: 16px; font-weight: 600; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.eyebrow { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.eyebrow.accent { color: var(--accent); font-weight: 600; }
.hidden { display: none !important; }

/* ---------- layout */
#shell { display: flex; min-height: 100vh; }
#side { width: 220px; flex-shrink: 0; border-right: 1px solid var(--line); padding: 28px 16px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; height: 100vh; }
.brand { font-size: 17px; font-weight: 600; letter-spacing: .02em; padding: 0 12px 22px; }
#side-links { display: flex; flex-direction: column; gap: 2px; }
.navlink { text-decoration: none; color: var(--ink); padding: 9px 12px; border-radius: 8px; font-size: 14px; display: block; }
.navlink:hover { background: var(--line-2); }
.navlink.on { background: var(--btn); color: var(--btn-ink); font-weight: 500; }
.navsep { height: 1px; background: var(--line); margin: 10px 12px; }
.side-foot { margin-top: auto; padding: 0 12px; font-size: 12px; color: var(--muted); display: flex; flex-direction: column; gap: 6px; }
.side-foot a { color: var(--muted); }
#main { flex: 1; min-width: 0; padding: 32px 40px 48px; outline: none; }
#tabbar { display: none; }

.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; align-items: start; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; gap: 12px; align-items: center; }
.between { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.pagehead { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.pagehead .titles { display: flex; flex-direction: column; gap: 4px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.card.tight { gap: 10px; }
.kv { display: flex; justify-content: space-between; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--line-2); gap: 12px; }
.kv:last-child { border-bottom: 0; padding-bottom: 0; }
.kv .v { font-family: var(--mono); font-size: 18px; font-weight: 500; }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 4px 10px; border-radius: 999px; background: var(--line-2); color: var(--muted); white-space: nowrap; }
.pill.ok { background: var(--accent-soft); color: var(--accent); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

/* ---------- controls */
label.f { display: flex; flex-direction: column; gap: 6px; font-size: 14px; min-width: 0; }
.input { height: 46px; border: 1px solid var(--field-line); border-radius: 10px; padding: 0 14px; font-size: 16px; background: var(--field); width: 100%; min-width: 0; }
.input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.btn { height: 46px; padding: 0 18px; border: 0; border-radius: 10px; background: var(--btn); color: var(--btn-ink); font-size: 15px; font-weight: 500; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; white-space: nowrap; }
.btn:disabled { opacity: .45; cursor: default; }
.btn.accent { background: var(--accent); color: var(--accent-ink); }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--field-line); }
.btn.dashed { background: transparent; color: var(--ink); border: 1px dashed var(--field-line); height: 42px; font-size: 14px; }
.btn.big { height: 52px; font-size: 16px; width: 100%; }
.btn.sm { height: 36px; padding: 0 12px; font-size: 13px; }
.seg { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 5px; }
.seg button { height: 42px; border: 1px solid var(--field-line); border-radius: 9px; background: var(--card); cursor: pointer; font-size: 14px; padding: 0; }
.seg button.on { background: var(--btn); color: var(--btn-ink); border-color: var(--btn); }
.linkbtn { background: none; border: 0; padding: 8px 0; color: var(--accent); cursor: pointer; font-size: 14px; text-align: left; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- today */
.fields2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.chipgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.chip { padding: 12px; border-radius: 10px; background: var(--accent-soft); display: flex; flex-direction: column; gap: 2px; }
.chip .l { font-size: 12px; color: var(--accent); }
.chip .v { font-family: var(--mono); font-size: 19px; font-weight: 500; }
.chip.empty { background: var(--line-2); }
.chip.empty .l { color: var(--muted); }
.chip.empty .v { color: var(--faint); }
.ev { display: flex; gap: 14px; align-items: flex-start; }
.ev .t { width: 48px; flex-shrink: 0; font-family: var(--mono); font-size: 13px; color: var(--muted); padding-top: 2px; }
.ev.past .title { color: var(--muted); text-decoration: line-through; }
.ev.next { background: var(--accent-soft); margin: 0 -12px; padding: 10px 12px; border-radius: 10px; }
.ev.next .t { color: var(--accent); }
.ev.next .title { font-weight: 500; }
.tabs { display: flex; gap: 4px; background: var(--line-2); padding: 3px; border-radius: 9px; }
.tabs button { border: 0; background: transparent; padding: 5px 10px; border-radius: 7px; font-size: 12px; cursor: pointer; color: var(--muted); }
.tabs button.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.spark { width: 100%; height: 64px; display: block; overflow: visible; }
.spark .ln { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.spark .ln.ink { stroke: var(--ink); }
.spark .pt { fill: var(--card); stroke-width: 2; }
.spark .hit { fill: transparent; cursor: default; }
.spark .hit:hover + .pt, .spark .pt.hl { r: 5; }
.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.week .d { height: 30px; border-radius: 6px; background: var(--line-2); display: flex; align-items: center; justify-content: center; font-size: 11px; color: var(--muted); }
.week .d.done { background: var(--accent); color: var(--accent-ink); }
.week .d.plan { background: var(--card); border: 1px dashed var(--field-line); }
.week .d.today { outline: 2px solid var(--ink); outline-offset: 1px; }

/* ---------- gym */
.gymwrap { max-width: 640px; }
.excard { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.exhead { width: 100%; background: none; border: 0; text-align: left; cursor: pointer; padding: 16px 18px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.exhead .name { font-size: 16px; font-weight: 600; }
.exhead .sum { font-family: var(--mono); font-size: 13px; color: var(--muted); white-space: nowrap; }
.excard.complete .exhead .name { color: var(--muted); }
.excard.complete .exhead .sum { color: var(--accent); }
.exbody { padding: 0 18px 18px; display: flex; flex-direction: column; gap: 12px; }
.exmeta { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.exmeta b { color: var(--ink); font-weight: 500; }
.setrow { display: grid; grid-template-columns: 34px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .8fr) 48px; gap: 8px; align-items: center; }
.setrow.head { font-size: 12px; color: var(--muted); }
.setrow .n { font-family: var(--mono); font-size: 14px; color: var(--muted); }
.setrow .cell { height: 46px; display: flex; align-items: center; padding: 0 12px; border-radius: 10px; background: var(--accent-soft); font-family: var(--mono); font-size: 16px; }
.setrow .cell.pending { background: var(--line-2); }
.setrow .input { font-family: var(--mono); padding: 0 10px; }
.setrow .ok { font-size: 12px; color: var(--accent); font-weight: 600; text-align: center; }
.setrow .ok.pending { color: var(--muted); font-weight: 400; }
.checkbtn { width: 48px; height: 46px; border: 0; border-radius: 10px; background: var(--btn); color: var(--btn-ink); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.restbar { position: sticky; top: 0; z-index: 5; background: var(--bg); padding: 8px 0; display: flex; justify-content: space-between; align-items: center; }
.sheet-bg { position: fixed; inset: 0; background: rgba(20,20,18,.45); z-index: 40; display: flex; align-items: flex-end; justify-content: center; }
.sheet { background: var(--bg); width: 100%; max-width: 520px; border-radius: 20px 20px 0 0; padding: 12px 20px calc(24px + var(--safe-b)); display: flex; flex-direction: column; gap: 10px; max-height: 85vh; overflow: auto; }
.sheet .grab { width: 40px; height: 4px; border-radius: 2px; background: var(--field-line); align-self: center; }
.pick { text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; width: 100%; gap: 12px; }
.pick.on { border: 2px solid var(--ink); }
.pick .t { font-size: 16px; font-weight: 600; display: block; }
@media (min-width: 900px) { .sheet-bg { align-items: center; } .sheet { border-radius: 20px; } }

/* ---------- plan */
.plangrid { display: grid; grid-template-columns: 100px repeat(7, minmax(0, 1fr)); gap: 6px; }
.plangrid .wk { display: flex; flex-direction: column; justify-content: center; }
.plangrid .wk b { font-size: 13px; }
.plangrid .wk span { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.pc { min-height: 60px; border-radius: 8px; padding: 6px 8px; display: flex; flex-direction: column; justify-content: space-between; font-size: 13px; text-decoration: none; color: var(--ink); }

.pc .sh { display: none; }
.pc .dt { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.pc.rest { background: transparent; border: 1px solid var(--line-2); }
.pc.rest .dt { color: var(--faint); }
.pc.plan { background: var(--card); border: 1px solid var(--field-line); font-weight: 500; }
.pc.opt { background: var(--card); border: 1px dashed var(--field-line); color: var(--muted); }
.pc.done { background: var(--accent); color: var(--accent-ink); font-weight: 500; }
.pc.done .dt { color: var(--accent-ink); opacity: .8; }
.pc.miss { background: var(--warn-soft); color: var(--warn); }
.pc.miss .dt { color: var(--warn); }
.pc.today { outline: 2px solid var(--ink); outline-offset: 1px; }
.legend { display: flex; gap: 18px; font-size: 13px; color: var(--muted); flex-wrap: wrap; align-items: center; }
.legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; vertical-align: -2px; margin-right: 6px; }
.planlayout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 20px; align-items: start; }

/* ---------- files */
.filelist { display: flex; flex-direction: column; }
.filelist a { display: flex; justify-content: space-between; gap: 12px; padding: 11px 4px; border-bottom: 1px solid var(--line-2); text-decoration: none; color: var(--ink); font-size: 14px; }
.filelist a:hover { background: var(--line-2); }
.filelist .dir { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; padding: 18px 4px 6px; }
.doc { max-width: 780px; }
.doc .md { font-size: 15px; line-height: 1.6; overflow-wrap: anywhere; }
.md h1 { font-size: 26px; margin: 8px 0 14px; }
.md h2 { font-size: 20px; margin: 26px 0 10px; }
.md h3 { font-size: 16px; margin: 20px 0 8px; }
.md p, .md ul, .md ol { margin: 0 0 12px; }
.md li { margin: 3px 0; }
.md code { font-family: var(--mono); font-size: 13px; background: var(--line-2); padding: 1px 5px; border-radius: 5px; }
.md pre { background: var(--line-2); padding: 12px 14px; border-radius: 10px; overflow: auto; }
.md pre code { background: none; padding: 0; }
.md table, .csvt { border-collapse: collapse; font-size: 13px; margin: 0 0 14px; display: block; overflow-x: auto; max-width: 100%; }
.md th, .md td, .csvt th, .csvt td { border: 1px solid var(--line); padding: 6px 10px; text-align: left; vertical-align: top; }
.md th, .csvt th { background: var(--line-2); font-weight: 600; }
.csvt td { font-family: var(--mono); white-space: nowrap; }
.md blockquote { margin: 0 0 12px; padding: 4px 14px; border-left: 3px solid var(--line); color: var(--muted); }
.md hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }

#toast { position: fixed; left: 50%; bottom: calc(90px + var(--safe-b)); transform: translateX(-50%) translateY(20px); background: var(--btn); color: var(--btn-ink); padding: 10px 16px; border-radius: 10px; font-size: 14px; opacity: 0; pointer-events: none; transition: .2s; z-index: 60; max-width: calc(100vw - 32px); }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
@media (min-width: 900px) { #toast { bottom: 28px; } }

/* ---------- phone */
@media (max-width: 899px) {
  #side { display: none; }
  #main { padding: calc(20px + env(safe-area-inset-top, 0px)) 16px calc(96px + var(--safe-b)); }
  h1 { font-size: 26px; }
  .pagehead { margin-bottom: 16px; }
  .grid3, .planlayout { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .card { padding: 18px; gap: 14px; }
  #tabbar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: fixed; left: 0; right: 0; bottom: 0; background: var(--card); border-top: 1px solid var(--line); padding: 6px 8px calc(8px + var(--safe-b)); z-index: 30; }
  #tabbar a { height: 48px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 12px; color: var(--muted); text-decoration: none; }
  #tabbar a svg { width: 22px; height: 22px; }
  #tabbar a.on { color: var(--ink); font-weight: 600; }
  .seg { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .plangrid { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
  .plangrid .wk { grid-column: 1 / -1; flex-direction: row; gap: 8px; align-items: baseline; padding-top: 8px; }
  .plangrid .hdr0 { display: none; }
  .pc { min-height: 52px; padding: 4px 5px; font-size: 11px; }
  .pc .dt { font-size: 10px; }
  .pc .lg { display: none; }
  .pc .sh { display: inline; }
  .setrow { grid-template-columns: 26px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .8fr) 46px; gap: 6px; }
}

/* phase / week (plans/phases.csv + weeks-current.csv) */
.phase .phname { font-size: 20px; font-weight: 600; line-height: 1.2; }
.pbar { height: 6px; border-radius: 999px; background: var(--line-2); overflow: hidden; }
.pbar i { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.phase .focus { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 10px; background: var(--accent-soft); }
.phase .focus span:last-child { font-size: 14px; font-weight: 500; }
.wkrow { display: flex; gap: 12px; align-items: flex-start; padding: 8px 10px; border-radius: 10px; }
.wkrow .n { font-family: var(--mono); font-size: 13px; font-weight: 600; min-width: 26px; color: var(--muted); padding-top: 1px; }
.wkrow.on { background: var(--accent-soft); }
.wkrow.on .n { color: var(--accent); }
.wkrow.past { opacity: .55; }
.weekline { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; margin-bottom: 12px; border-radius: 10px; background: var(--accent-soft); }

/* plan: phase colours, timeline, month calendar */
:root { --ph1: #E4F0E8; --ph1-s: #2F6B4F; --ph2: #E3ECF7; --ph2-s: #2C5A8C; --ph3: #F8E9DA; --ph3-s: #A2551B; --ph4: #EEE6F5; --ph4-s: #6A4A8C; }
@media (prefers-color-scheme: dark) { :root { --ph1: #1D2E24; --ph1-s: #6FBF94; --ph2: #1B2635; --ph2-s: #7FA9D9; --ph3: #33251A; --ph3-s: #E0A06A; --ph4: #2A2233; --ph4-s: #B79AD8; } }
.ph1 { --pbg: var(--ph1); --pst: var(--ph1-s); } .ph2 { --pbg: var(--ph2); --pst: var(--ph2-s); } .ph3 { --pbg: var(--ph3); --pst: var(--ph3-s); } .ph4 { --pbg: var(--ph4); --pst: var(--ph4-s); } .ph0 { --pbg: transparent; --pst: var(--line); }
.tline { position: relative; height: 46px; margin-top: 16px; }
.tseg { position: absolute; top: 0; height: 22px; border-radius: 6px; background: var(--pst); opacity: .55; }
.tseg.on { opacity: 1; }
.ty { position: absolute; top: 28px; transform: translateX(-50%); font-family: var(--mono); font-size: 11px; color: var(--muted); border-left: 1px solid var(--line); padding-left: 4px; }
.there { position: absolute; top: -8px; height: 32px; width: 2px; background: var(--ink); }
.there span { position: absolute; top: -14px; left: -10px; font-size: 11px; font-weight: 700; }
.tlegend { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.tl { display: flex; gap: 8px; align-items: flex-start; padding: 8px; border-radius: 10px; min-width: 0; }
.tl.on { background: var(--line-2); }
.tl i { flex: 0 0 12px; height: 12px; border-radius: 3px; background: var(--pst); margin-top: 3px; }
.target { color: var(--ink); font-weight: 600; }
.mgrid { display: grid; grid-template-columns: 34px repeat(7, minmax(0, 1fr)); gap: 5px; }
.mwk { display: flex; align-items: center; font-family: var(--mono); font-size: 11px; }
.mc { min-height: 70px; border-radius: 8px; padding: 5px 6px; display: flex; flex-direction: column; gap: 4px; background: var(--pbg); border: 1px solid var(--line-2); text-decoration: none; color: var(--ink); min-width: 0; }
.mc.ph0 { background: transparent; }
.mc.out { opacity: .4; }
.mc.today { outline: 2px solid var(--ink); outline-offset: 1px; }
.mc .dn { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.mc .sess { font-size: 12px; font-weight: 600; border-radius: 6px; padding: 3px 6px; background: var(--card); border: 1px solid var(--field-line); line-height: 1.2; overflow: hidden; }
.mc .sess .sh { display: none; }
.mc .sess.opt { border-style: dashed; font-weight: 400; color: var(--muted); }
.mc .sess.done { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.mc .sess.miss { background: var(--warn-soft); border-color: transparent; color: var(--warn); }
.legend i.lg-done { background: var(--accent); } .legend i.lg-plan { background: var(--card); border: 1px solid var(--field-line); } .legend i.lg-miss { background: var(--warn-soft); } .legend i.lg-today { background: transparent; outline: 2px solid var(--ink); outline-offset: -2px; }
.btn.sm { height: 32px; padding: 0 12px; font-size: 15px; }
.phase[class*="-edge"] { border-left: 4px solid var(--ph1-s); }
.ph2-edge { border-left-color: var(--ph2-s) !important; } .ph3-edge { border-left-color: var(--ph3-s) !important; } .ph4-edge { border-left-color: var(--ph4-s) !important; }
.howto { font-size: 11px; font-weight: 600; margin-left: 4px; white-space: nowrap; }
@media (max-width: 900px) {
  .tlegend { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mgrid { grid-template-columns: 22px repeat(7, minmax(0, 1fr)); gap: 3px; }
  .mc { min-height: 54px; padding: 3px; }
  .mc .sess { padding: 2px 3px; font-size: 10px; }
  .mc .sess .lg { display: none; } .mc .sess .sh { display: inline; }
}

/* ---------- network view */
:root { --d1: #2a78d6; --d2: #eb6834; --d3: #1baf7a; --d4: #eda100; --d5: #e87ba4; --d6: #4a3aa7; --d7: #e34948; --d8: #9A988F; }
@media (prefers-color-scheme: dark) {
  :root { --d1: #3987e5; --d2: #d95926; --d3: #199e70; --d4: #c98500; --d5: #d55181; --d6: #9085e9; --d7: #e66767; --d8: #75746C; }
}
.netbar { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.netbar .input { width: 240px; height: 40px; font-size: 14px; }
.netlegend { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.nw-leg { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); font-size: 13px; cursor: pointer; }
.nw-leg.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.nw-sw { display: inline-block; width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; margin-right: 6px; vertical-align: 0; }
.nw-leg .nw-sw { margin-right: 0; }
.nw-shapes { display: inline-flex; align-items: center; gap: 5px; margin-left: 6px; }
.nw-dot, .nw-sq { display: inline-block; width: 9px; height: 9px; background: var(--muted); }
.nw-dot { border-radius: 50%; }
.nw-sq { border-radius: 2px; margin-left: 6px; }
.netstage { position: relative; height: calc(100vh - 230px); min-height: 440px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); overflow: hidden; }
#netcv { width: 100%; height: 100%; display: block; touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.netstage.panning #netcv { cursor: grabbing !important; }
.netmsg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 14px; pointer-events: none; padding: 24px; text-align: center; }
.netmsg:empty { display: none; }
.netzoom { position: absolute; right: 12px; bottom: 12px; display: flex; flex-direction: column; gap: 6px; }
.netzoom button { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); font-size: 18px; cursor: pointer; color: var(--ink); }
.netzoom button[data-net="fit"] { font-size: 12px; }
.netinfo { position: absolute; top: 12px; right: 12px; width: 270px; max-height: calc(100% - 24px); overflow: auto; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; box-shadow: 0 6px 24px rgba(0,0,0,.08); }
.netinfo[hidden] { display: none; }
.netinfo .eyebrow { display: flex; align-items: center; }
.netinfo .btn { margin-top: 8px; align-self: flex-start; }
.nw-title { font-size: 16px; font-weight: 600; overflow-wrap: anywhere; }
.nw-x { position: absolute; top: 6px; right: 6px; width: 32px; height: 32px; border: 0; background: none; font-size: 20px; cursor: pointer; color: var(--muted); border-radius: 8px; }
.nw-links-list { display: flex; flex-direction: column; gap: 2px; margin-top: 2px; }
.nw-link { display: flex; align-items: center; text-align: left; border: 0; background: none; padding: 6px 4px; border-radius: 6px; font-size: 13px; cursor: pointer; color: var(--ink); }
.nw-link:hover { background: var(--line-2); }

#networld { --lk: 1; }
.nw-rings circle { fill: none; stroke: var(--line-2); stroke-width: 1; stroke-dasharray: 3 5; vector-effect: non-scaling-stroke; }
.nw-sectors path { fill: none; stroke-width: 3; stroke-linecap: round; opacity: .55; vector-effect: non-scaling-stroke; }
.nw-tree line { stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.nw-links path { fill: none; stroke: var(--muted); stroke-width: 1.2; opacity: .45; vector-effect: non-scaling-stroke; }
.nw-n { cursor: pointer; }
.nw-n circle:not(.nw-hit), .nw-n rect { stroke: var(--card); stroke-width: 2; vector-effect: non-scaling-stroke; }
.nw-hit { fill: transparent; }
.nw-me rect { fill: var(--ink); }
.nw-me-t { fill: var(--card); font-size: 20px; font-weight: 700; text-anchor: middle; pointer-events: none; }
.nw-glyph { fill: #FFFFFF; opacity: .92; pointer-events: none; }
.nw-lbl { paint-order: stroke; stroke: var(--card); stroke-width: 3.5px; stroke-linejoin: round; pointer-events: none; }
.nw-hub-l { font-size: calc(13px * var(--lk)); font-weight: 600; fill: var(--ink); }
.nw-cnt { font-weight: 400; fill: var(--muted); }
.nw-below { transform: translateY(calc(17px * var(--lk))); }
.nw-sub-l { font-size: calc(11px * var(--lk)); fill: var(--muted); display: none; }
.show-sub-labels .nw-sub-l { display: inline; }
.nw-file-l { font-size: calc(11px * var(--lk)); fill: var(--muted); display: none; }
.show-file-labels .nw-file-l, .nw-file.sel .nw-file-l, .nw-file.hit .nw-file-l, .filemode .nw-file.lit .nw-file-l, .nw-file:hover .nw-file-l { display: inline; }
.nw-file.sel .nw-file-l, .nw-file.hit .nw-file-l, .nw-file:hover .nw-file-l { fill: var(--ink); font-weight: 600; }
.dimming .nw-n:not(.lit) { opacity: .14; }
.dimming .nw-tree line:not(.lit) { opacity: .25; }
.dimming .nw-links path:not(.lit) { opacity: .06; }
.dimming .nw-sectors path:not(.lit) { opacity: .15; }
.nw-tree line.lit { stroke: var(--muted); }
.nw-links path.lit { stroke: var(--ink); opacity: .9; stroke-width: 1.6; }
.nw-file.sel circle:not(.nw-hit), .nw-file.sel rect { stroke: var(--ink); stroke-width: 2.5; }
.nw-n, .nw-tree line, .nw-links path { transition: opacity .15s; }

@media (max-width: 899px) {
  .netbar { gap: 8px; }
  .netbar .input { width: 100%; }
  .netlegend { flex-wrap: nowrap; overflow-x: auto; width: 100%; padding-bottom: 2px; scrollbar-width: none; }
  .nw-leg { flex-shrink: 0; }
  .nw-shapes { flex-shrink: 0; }
  #netstats { font-size: 12px; }
  .nw-hub-l { font-size: calc(11.5px * var(--lk)); }
  .netstage { height: calc(100dvh - 330px - var(--safe-b) - env(safe-area-inset-top, 0px)); min-height: 340px; }
  .netinfo { top: auto; bottom: 10px; left: 10px; right: 62px; width: auto; max-height: 55%; }
}

/* ---------- modal window */
body.modal-open { overflow: hidden; }
.modal-bg { position: fixed; inset: 0; z-index: 80; background: rgba(20,20,18,0); display: flex; align-items: center; justify-content: center; padding: 24px; transition: background .2s ease; }
.modal-bg.open { background: rgba(20,20,18,.42); }
.modal { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: 18px; width: 100%; max-width: 520px; max-height: calc(100vh - 48px); overflow: auto; padding: 24px; box-shadow: 0 24px 60px rgba(0,0,0,.18); opacity: 0; transform: translateY(10px) scale(.98); transition: opacity .2s ease, transform .22s cubic-bezier(.2,.8,.2,1); }
.modal.wide { max-width: 780px; }
.modal-bg.open .modal { opacity: 1; transform: none; }
.modal-x { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border: 0; border-radius: 10px; background: var(--line-2); color: var(--ink); font-size: 22px; line-height: 1; cursor: pointer; z-index: 2; }
.modal-x:hover { background: var(--line); }
.modal-body { display: flex; flex-direction: column; gap: 12px; }
.modal-title { font-size: 22px; padding-right: 44px; overflow-wrap: break-word; }
.modal-doc { border-top: 1px solid var(--line-2); padding-top: 12px; }
.dm-sess { display: flex; flex-direction: column; gap: 3px; }
.dm-title { font-size: 18px; font-weight: 600; }
.dm-list { display: flex; flex-direction: column; gap: 8px; }
.dm-hist { display: flex; flex-direction: column; gap: 10px; }
.dm-ex { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border-radius: 10px; background: var(--line-2); }
.dm-sets { display: flex; flex-wrap: wrap; gap: 6px; }
.dm-sets span { font-size: 13px; padding: 3px 8px; border-radius: 6px; background: var(--card); }
@media (max-width: 899px) {
  .modal-bg { align-items: flex-end; padding: 0; }
  .modal, .modal.wide { max-width: none; border-radius: 20px 20px 0 0; max-height: 88vh; padding: 20px 18px calc(24px + var(--safe-b)); transform: translateY(40px); }
}
@media (prefers-reduced-motion: reduce) { .modal, .modal-bg { transition: none; } }

/* ---------- plan calendar cells are buttons now */
button.mc { font: inherit; text-align: left; cursor: pointer; width: 100%; transition: transform .12s ease, box-shadow .12s ease; }
button.mc:hover { box-shadow: 0 2px 10px rgba(0,0,0,.08); transform: translateY(-1px); }
.mc .sub { font-size: 10px; color: var(--muted); line-height: 1.1; }
.mc .sess.moved { background: transparent; border-style: dashed; color: var(--muted); font-weight: 500; text-decoration: line-through; text-decoration-color: var(--faint); }
.mc .sess.makeup { border: 2px solid var(--warn); }
.legend i.lg-moved { background: transparent; border: 1px dashed var(--field-line); }
.gymfocus { display: block; margin-top: 4px; max-width: 520px; }

/* ---------- health dashboard */
.hgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; align-items: start; }
.hgrid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
.goal { display: flex; flex-direction: column; gap: 5px; padding: 6px 0; }
.st { display: inline-flex; width: 18px; height: 18px; border-radius: 50%; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; background: var(--line-2); color: var(--muted); vertical-align: -3px; margin-right: 4px; font-family: var(--font); }
.st.ok { background: var(--accent-soft); color: var(--accent); }
.st.warn { background: var(--warn-soft); color: var(--warn); }
.an { display: flex; gap: 8px; align-items: flex-start; padding: 6px 0; border-bottom: 1px solid var(--line-2); }
.an:last-of-type { border-bottom: 0; }
.an .st { flex-shrink: 0; margin-top: 1px; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid { stroke: var(--line-2); stroke-width: 1; }
.chart .ax { font-size: 11px; fill: var(--muted); font-family: var(--mono); }
.chart .band { fill: var(--accent-soft); }
.chart .gl { stroke: var(--muted); stroke-width: 1.2; stroke-dasharray: 4 4; }
.chart .gl-t { font-size: 11px; fill: var(--muted); }
.chart .ln { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart.ink .ln { stroke: var(--ink); }
.chart .pt { fill: var(--accent); stroke: var(--card); stroke-width: 2; }
.chart.ink .pt { fill: var(--ink); }
.chart .pt.test { fill: var(--card); stroke: var(--accent); stroke-width: 2; }
.chart .hit { fill: transparent; }
.chart .pt-g:hover .pt { r: 5.5; }
.chart .val { font-size: 12px; font-weight: 600; fill: var(--ink); font-family: var(--mono); }
.chart-empty { padding: 26px 0; text-align: center; border: 1px dashed var(--line); border-radius: 10px; }
.smgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 24px; }
.sm { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.bignum { font-size: 24px; font-weight: 600; }
.hm-wrap { display: flex; gap: 6px; overflow-x: auto; }
.hm-days { display: grid; grid-template-rows: 14px repeat(7, 18px); gap: 4px; padding-top: 0; }
.hm-days span:first-child { grid-row: 2; }
.hm { display: flex; gap: 4px; }
.hm-col { display: grid; grid-template-rows: 14px repeat(7, 18px); gap: 4px; }
.hm-m { white-space: nowrap; font-size: 10px; height: 14px; }
.hm-c { width: 18px; height: 18px; border-radius: 4px; border: 0; padding: 0; cursor: pointer; background: var(--line-2); }
.hm-c.done { background: var(--accent); }
.hm-c.plan { background: var(--card); box-shadow: inset 0 0 0 1px var(--field-line); }
.hm-c.opt { background: var(--card); box-shadow: inset 0 0 0 1px var(--line); }
.hm-c.skip { background: var(--warn-soft); box-shadow: inset 0 0 0 1px var(--warn); }
.hm-c.moved { background: transparent; box-shadow: inset 0 0 0 1px var(--field-line); background-image: repeating-linear-gradient(45deg, transparent 0 3px, var(--line) 3px 4px); }
.hm-c.today { outline: 2px solid var(--ink); outline-offset: 1px; }
.hm-c:hover { transform: scale(1.15); }
.fields3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.jt summary { cursor: pointer; padding: 6px 0; }
@media (max-width: 1180px) { .hgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .smgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 899px) {
  .hgrid, .hgrid2 { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .hgrid2[style] { margin-top: 14px !important; }
  .smgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .fields3 { grid-template-columns: minmax(0, 1fr); }
  #tabbar { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .hm-c { width: 16px; height: 16px; } .hm-col, .hm-days { grid-template-rows: 14px repeat(7, 16px); }
}

/* network: motion + window */
.nw-n, .nw-tree line, .nw-links path, .nw-sectors path { transition: opacity .28s ease; }
.nw-n circle:not(.nw-hit), .nw-n rect { transition: stroke-width .2s ease; }
.netinfo { animation: nwPanel .2s ease; }
@keyframes nwPanel { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@keyframes nwIn { from { opacity: 0; } to { opacity: 1; } }
.enter .nw-rings, .enter .nw-me { animation: nwIn .5s ease both; }
.enter .nw-hub { animation: nwIn .5s .12s ease both; }
.enter .nw-tree, .enter .nw-sub { animation: nwIn .6s .25s ease both; }
.enter .nw-file, .enter .nw-sectors { animation: nwIn .7s .38s ease both; }
.enter .nw-links { animation: nwIn .8s .6s ease both; }
.nw-mmeta { display: flex; flex-direction: column; gap: 8px; }
.nw-mmeta .nw-sw { margin-right: 6px; }
.nw-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.nw-chip { display: inline-flex; align-items: center; height: 32px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); font-size: 13px; cursor: pointer; color: var(--ink); }
.nw-chip:hover { background: var(--line-2); }
.nw-chip .nw-sw { margin-right: 6px; }
@media (prefers-reduced-motion: reduce) { .enter * { animation: none !important; } .nw-n, .nw-tree line, .nw-links path { transition: none; } }

.modal-body > .between { flex-wrap: wrap; row-gap: 6px; }
.md .wl { color: var(--accent); border-bottom: 1px dotted var(--accent); }
.md .wl.go { cursor: pointer; border-bottom-style: solid; }

/* ================= Health section ================= */
.hpage { max-width: 1240px; }
.hhead { margin-bottom: 14px; }
.subtabs { display: flex; gap: 4px; padding: 4px; background: var(--line-2); border-radius: 12px; width: max-content; max-width: 100%; overflow-x: auto; margin-bottom: 22px; scrollbar-width: none; }
.subtabs a { padding: 9px 16px; border-radius: 9px; font-size: 14px; color: var(--muted); text-decoration: none; white-space: nowrap; transition: background .15s, color .15s; }
.subtabs a:hover { color: var(--ink); }
.subtabs a.on { background: var(--card); color: var(--ink); font-weight: 600; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.hbody { display: flex; flex-direction: column; gap: 20px; }

.ogrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; align-items: start; }
.tile { gap: 10px; }
.tile-go { text-decoration: none; color: var(--ink); transition: box-shadow .15s, transform .15s, border-color .15s; }
.tile-go:hover { border-color: var(--field-line); box-shadow: 0 6px 20px rgba(0,0,0,.06); transform: translateY(-1px); }
.tile-title { font-size: 20px; font-weight: 600; line-height: 1.25; }
.tile.big .tile-title { font-size: 24px; }
.tile .btn { align-self: flex-start; margin-top: 4px; }
.tile-prog { display: flex; flex-direction: column; gap: 6px; }
.minis { display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }
.mini { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; align-items: center; }
.mini .pbar { grid-column: 1 / -1; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; }
.kpi { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 12px; background: var(--line-2); }
.kpi-v { font-size: 24px; font-weight: 600; line-height: 1.15; }
.kpi-v small { font-size: 13px; font-weight: 400; color: var(--muted); }

.tgrid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; align-items: start; }
.wstrip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.wday { display: flex; flex-direction: column; gap: 3px; text-align: left; padding: 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); cursor: pointer; font: inherit; color: var(--ink); min-width: 0; transition: transform .12s, box-shadow .12s; }
.wday:hover { transform: translateY(-1px); box-shadow: 0 3px 10px rgba(0,0,0,.06); }
.wday b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wday.done { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.wday.done .muted { color: var(--accent-ink); opacity: .8; }
.wday.miss { background: var(--warn-soft); border-color: transparent; color: var(--warn); }
.wday.moved { border-style: dashed; color: var(--muted); }
.wday.opt { border-style: dashed; }
.wday.rest { background: transparent; border-color: var(--line-2); color: var(--faint); }
.wday.today { outline: 2px solid var(--ink); outline-offset: 1px; }
.bigpic summary { cursor: pointer; list-style: none; }
.bigpic summary::-webkit-details-marker { display: none; }
.bigpic summary::after { content: ' +'; color: var(--muted); }
.bigpic[open] summary::after { content: ' -'; }
.bigpic > .card { border: 0; padding: 12px 0 0; }

/* workout */
.whead { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.gymwrap { max-width: 680px; }
.excard { transition: opacity .25s ease; }
.excard.complete:not(.open) { opacity: .5; }
.excard .exhead { gap: 14px; }
.exn { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 600; background: var(--line-2); color: var(--muted); flex-shrink: 0; font-family: var(--mono); }
.exn svg { width: 16px; height: 16px; }
.exn.ok { background: var(--accent); color: var(--accent-ink); }
.excard.open { border-color: var(--field-line); box-shadow: 0 4px 18px rgba(0,0,0,.05); }
.exmeta .why, .why { font-size: 12px; padding: 3px 8px; border-radius: 6px; background: var(--line-2); color: var(--muted); align-self: flex-start; }
.why.ok { background: var(--accent-soft); color: var(--accent); }
.why.warn { background: var(--warn-soft); color: var(--warn); }
.srow { display: grid; grid-template-columns: 28px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .7fr) 54px; gap: 8px; align-items: center; }
.srow.head { font-size: 12px; color: var(--muted); }
.srow .sn { font-family: var(--mono); font-size: 14px; color: var(--muted); text-align: center; }
.srow .input { height: 50px; font-family: var(--mono); font-size: 18px; text-align: center; padding: 0 8px; }
.srow.next .input { border-color: var(--ink); background: var(--card); }
.srow.done .input { background: var(--accent-soft); border-color: transparent; color: var(--ink); }
.srow.done .sn { color: var(--accent); font-weight: 600; }
.tick { width: 54px; height: 50px; border-radius: 12px; border: 1.5px solid var(--field-line); background: var(--card); color: var(--muted); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background .15s, color .15s, transform .1s; }
.tick svg { width: 22px; height: 22px; }
.srow.next .tick { border-color: var(--ink); color: var(--ink); }
.tick:active { transform: scale(.94); }
.tick.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.checks { display: flex; flex-direction: column; gap: 6px; }
.chk { display: flex; gap: 12px; align-items: flex-start; text-align: left; width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); cursor: pointer; font: inherit; color: var(--ink); }
.chk .box { width: 24px; height: 24px; border-radius: 7px; border: 1.5px solid var(--field-line); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; color: transparent; }
.chk .box svg { width: 15px; height: 15px; }
.chk.on { background: var(--line-2); }
.chk.on .box { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.chk.on .small { color: var(--muted); text-decoration: line-through; }
.wcard summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.wcard summary::-webkit-details-marker { display: none; }
.wcard summary::after { content: '+'; font-size: 20px; color: var(--muted); }
.wcard[open] summary::after { content: '-'; }
.wcard .checks { margin-top: 12px; }
.sum-ex { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 10px; background: var(--line-2); }
.sum-ex .why { background: var(--card); }
.sum-ex .why.ok { background: var(--accent-soft); }

/* analysis */
.agrid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.nw-group { display: flex; flex-direction: column; gap: 2px; padding-top: 10px; }
.nrow { display: grid; grid-template-columns: minmax(0, 1fr) 70px; gap: 2px 12px; padding: 7px 0; border-bottom: 1px solid var(--line-2); align-items: center; }
.nrow .why { grid-column: 1 / -1; }
.nrow .mono { text-align: right; font-weight: 600; }
.rrow { display: flex; justify-content: space-between; gap: 12px; padding: 10px 4px; border: 0; border-bottom: 1px solid var(--line-2); background: none; width: 100%; text-align: left; cursor: pointer; font: inherit; color: var(--ink); }
.rrow:hover { background: var(--line-2); }
.goalgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 24px; }

@media (max-width: 1180px) { .ogrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .goalgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 899px) {
  .ogrid, .tgrid, .agrid, .goalgrid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .hbody { gap: 14px; }
  .subtabs { margin-bottom: 16px; width: 100%; }
  .subtabs a { padding: 8px 12px; font-size: 13px; }
  .wstrip { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
  .wday { padding: 6px 4px; }
  .wday b { font-size: 11px; }
  .wday .tiny:last-child { display: none; }
  #tabbar { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .srow { grid-template-columns: 22px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .7fr) 50px; gap: 6px; }
  .srow .tick { width: 50px; }
  .erow { grid-template-columns: 22px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .8fr) 52px; gap: 6px; }
}

/* 4b gym app v2 (2026-10-09): RIR column, variant tag, exercise note, finished card, edit a day */
.srow .input.rir { font-size: 16px; }
.srow .sn { position: relative; }
.srow .sn .vt { position: absolute; right: -2px; top: -8px; font-style: normal; font-size: 10px; font-weight: 600; color: var(--warn); }
.vsel { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.vsel .input { height: 38px; padding: 0 8px; font-size: 16px; width: auto; }
.exnote textarea { min-height: 60px; resize: vertical; font-family: inherit; font-size: 16px; padding: 8px 10px; height: auto; }
.finished { border-color: var(--accent); }
.erow { display: grid; grid-template-columns: 28px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .8fr) 64px; gap: 8px; align-items: center; }
.erow.head { font-size: 12px; color: var(--muted); }
.erow .sn { font-family: var(--mono); font-size: 13px; color: var(--muted); text-align: center; }
.erow .input { height: 40px; font-family: var(--mono); font-size: 16px; text-align: center; padding: 0 6px; }
.erow .erm { display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer; color: var(--muted); }
.erow .enote { grid-column: 2 / -1; }
.dm-sets small { font-size: 11px; color: var(--muted); }
