/* Wiring map and guide components. Generated; the site look is in site.css. */

/* Layout idea: a workshop sheet. One wiring map that the steps drive, then the same steps as a tick-off sheet, then reference tables. */
:root{
  --bg:#FBF6EC; --panel:#FFFFFF; --ink:#1C2C4C; --muted:#5B667C; --line:#E4DAC6;
  --accent:#2F7F7C; --gold:#A87C22; --warn:#A8452B; --ok:#2C7A57;
  --paper:#FBF6EC; --paper-ink:#1C2C4C;
  --display:"Cormorant Garamond", Georgia, "Times New Roman", serif;
  --body:"Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --bg:#111A2E; --panel:#19243F; --ink:#F5E9D4; --muted:#A9B3C7; --line:#2E3C61;
    --accent:#63BAB5; --gold:#D9B15A; --warn:#F0906F; --ok:#73CBA0; color-scheme:dark;
  }
}
:root[data-theme="dark"]{
  --bg:#111A2E; --panel:#19243F; --ink:#F5E9D4; --muted:#A9B3C7; --line:#2E3C61;
  --accent:#63BAB5; --gold:#D9B15A; --warn:#F0906F; --ok:#73CBA0; color-scheme:dark;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--ink);font-family:var(--body);font-size:16px;line-height:1.55}
.wrap{max-width:1160px;margin:0 auto;padding:28px 20px 72px;display:flex;flex-direction:column;gap:36px}
h1,h2,h3{margin:0;text-wrap:balance}
h1{font-family:var(--display);font-style:italic;font-weight:600;font-size:clamp(2.2rem,5vw,3.3rem);line-height:1.05;letter-spacing:-.01em}
h2{font-size:1.28rem;font-weight:800;letter-spacing:-.01em}
h3{font-size:1.05rem;font-weight:800}
p{margin:0}
a{color:var(--accent)}
.eyebrow{font-size:.78rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--gold)}
.lede{max-width:66ch;color:var(--muted);font-size:1.05rem}
header{display:flex;flex-direction:column;gap:12px}
section{display:flex;flex-direction:column;gap:16px}
.card{background:var(--panel);border:1px solid var(--line);border-radius:16px;padding:20px}
.muted{color:var(--muted)}
.num{font-variant-numeric:tabular-nums}

/* at a glance */
.glance{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}
.glance div{background:var(--panel);border:1px solid var(--line);border-radius:14px;padding:14px 16px;display:flex;flex-direction:column;gap:4px}
.glance .k{font-size:.76rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.glance .v{font-weight:800;font-size:1.06rem;line-height:1.25}
.glance .n{font-size:.88rem;color:var(--muted)}
.chip{display:inline-block;width:.8em;height:.8em;border-radius:50%;margin-right:.4em;vertical-align:-.05em;border:1.5px solid var(--ink)}
.c-red{background:#D4433A}.c-blk{background:#15171c}.c-wht{background:#fff}.c-vio{background:#7B4FA6}
.note{border-left:4px solid var(--gold);background:var(--panel);border-radius:0 12px 12px 0;padding:12px 16px;max-width:80ch}

/* parts */
.parts{display:grid;grid-template-columns:1fr 1fr;gap:6px 32px;margin:0;padding:0;list-style:none}
.parts.card{padding:10px 22px}
.parts li{padding:9px 0;border-bottom:1px solid var(--line)}
.parts b{font-weight:700}

/* player */
.player{display:grid;grid-template-columns:minmax(0,1.9fr) minmax(0,1fr);gap:0;padding:0;overflow:hidden}
.stage{background:var(--paper);color:var(--paper-ink);border-right:1px solid var(--line);display:flex;flex-direction:column}
.stage svg{display:block;width:100%;height:auto;aspect-ratio:8/5;cursor:zoom-in;touch-action:pan-y;-webkit-user-select:none;user-select:none}
.stage svg.zoomed{touch-action:none}
.stage svg.atmax{cursor:grab}
.stage svg.dragging{cursor:grabbing}
.mapwrap{margin:0;position:relative}
.zoomctl{position:absolute;right:10px;bottom:10px;display:flex;gap:6px}
.zoomctl button{min-width:38px;height:38px;border-radius:10px;border:1.5px solid #1C2C4C;background:#FFFDF7;color:#1C2C4C;font-weight:800;font-size:1.05rem;line-height:1;padding:0 11px;box-shadow:0 1px 3px rgba(16,25,44,.2)}
.zoomctl #zreset{font-size:.86rem}
.zoomctl button:disabled{opacity:.45;cursor:default}
.maphint{margin:0;padding:0 16px 14px;font-size:.82rem;color:#5B667C}
.pedal{display:grid;grid-template-columns:auto minmax(120px,1fr) auto;gap:10px 16px;align-items:center;padding:12px 16px;border-top:1px solid #E4DAC6;font-size:.9rem;color:#1C2C4C}
.pedal label{font-weight:700}
.pedal input{width:100%;accent-color:#2F7F7C}
.pedal output{font-variant-numeric:tabular-nums;font-weight:700;min-width:13ch;text-align:right}
.pedal .sub{grid-column:1/-1;color:#5B667C;font-size:.84rem}
.side{display:flex;flex-direction:column;min-width:0}
.side .now{padding:20px 20px 8px;display:flex;flex-direction:column;gap:10px;flex:1}
.side .stepno{font-size:.78rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase;color:var(--gold)}
.side ul{margin:0;padding-left:1.15em;display:flex;flex-direction:column;gap:7px}
.side .check,.side .caution{font-size:.93rem}
.controls{display:flex;gap:8px;padding:12px 20px 16px;flex-wrap:wrap;align-items:center}
button{font:inherit;color:inherit;cursor:pointer}
.btn{border:1.5px solid var(--ink);background:transparent;border-radius:999px;padding:8px 16px;font-weight:700;font-size:.92rem}
.btn.primary{background:var(--ink);color:var(--bg)}
.btn:disabled{opacity:.4;cursor:default}
.btn:focus-visible,.dot:focus-visible,input:focus-visible,a:focus-visible{outline:3px solid var(--accent);outline-offset:2px}
.dots{display:flex;flex-wrap:wrap;gap:6px;padding:4px 16px 16px}
.dot{width:32px;height:32px;border-radius:50%;border:1.5px solid #CFC4AC;background:transparent;font-weight:700;font-size:.85rem;font-variant-numeric:tabular-nums;color:#5B667C}
.dot[aria-current="step"]{background:#2F7F7C;border-color:#2F7F7C;color:#fff}
.dot.wide{width:auto;padding:0 12px;border-radius:999px}

/* steps sheet */
.steps{display:flex;flex-direction:column;gap:12px;counter-reset:s}
.step{display:grid;grid-template-columns:52px minmax(0,1fr);gap:4px 16px;background:var(--panel);border:1px solid var(--line);border-radius:16px;padding:18px 20px}
.step .n{grid-row:1/3;width:44px;height:44px;border-radius:50%;border:2px solid var(--accent);color:var(--accent);display:grid;place-items:center;font-weight:800;font-size:1.05rem;font-variant-numeric:tabular-nums}
.step .head{display:flex;gap:12px;align-items:center;justify-content:space-between;flex-wrap:wrap}
.step-body{display:flex;flex-direction:column;gap:10px;max-width:74ch}
.step-body ul{margin:0;padding-left:1.15em;display:flex;flex-direction:column;gap:6px}
.check,.caution{padding:8px 12px;border-radius:10px;border:1px solid var(--line)}
.check{border-left:4px solid var(--ok)}
.caution{border-left:4px solid var(--warn)}
.check b{color:var(--ok)}.caution b{color:var(--warn)}
.tick{display:inline-flex;gap:8px;align-items:center;font-size:.88rem;font-weight:700;color:var(--muted)}
.tick input{width:18px;height:18px;accent-color:var(--accent)}
.show{border:0;background:none;color:var(--accent);font-weight:700;font-size:.88rem;padding:4px 0;text-decoration:underline;text-underline-offset:3px}
kbd{font-family:var(--body);font-weight:700;border:1px solid var(--line);border-bottom-width:2px;border-radius:6px;padding:1px 6px;font-size:.9em;white-space:nowrap}
.leds{display:flex;gap:22px;flex-wrap:wrap;align-items:center}
.leddemo{display:inline-flex;gap:8px;align-items:center;font-size:.9rem;font-weight:700}
.leddemo i{width:14px;height:14px;border-radius:50%;background:#33503f;border:1.5px solid var(--ink);display:inline-block}
.leddemo i.on{background:#3CDC7C;box-shadow:0 0 10px #3CDC7C}

.shot{margin:2px 0 0;border:1px solid var(--line);border-radius:12px;overflow:hidden;background:var(--panel)}
.shot svg{display:block;width:100%;height:auto}
.shot figcaption{font-size:.84rem;color:var(--muted);padding:8px 12px}
.shot .fring{fill:none;stroke:#F2C14E;stroke-width:8}
.shot .fring.no{stroke:#fff;stroke-width:6;stroke-dasharray:16 11}
.shot text{font-family:var(--body);font-weight:800;font-size:30px;fill:#fff;paint-order:stroke;stroke:#10192c;stroke-width:8px;stroke-linejoin:round}

/* tables */
.tablewrap{overflow-x:auto}
table{border-collapse:collapse;width:100%;font-size:.94rem}
th,td{text-align:left;padding:9px 12px;border-bottom:1px solid var(--line);vertical-align:top}
th{font-size:.76rem;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700}
td.num{white-space:nowrap;font-weight:700}
.two{display:grid;grid-template-columns:1fr 1fr;gap:20px}
.why{display:grid;grid-template-columns:repeat(2,1fr);gap:12px 28px;margin:0;padding:0;list-style:none}
.why li{padding-top:10px;border-top:1px solid var(--line)}
.sources{margin:0;padding-left:1.15em;display:flex;flex-direction:column;gap:6px;font-size:.93rem}

/* diagram (fixed paper palette: wire colors are literal) */
#wiring text{font-family:var(--body);fill:#1C2C4C}
.zone{font-size:11px;font-weight:800;letter-spacing:.14em;fill:#A87C22 !important}
.t-cap{font-size:12px;font-weight:800;letter-spacing:.1em}
.t-note{font-size:11.5px;fill:#5B667C !important}
.t-lbl{font-size:13px;font-weight:700}
.t-title{font-size:15px;font-weight:800}
.t-term{font-size:11px;font-weight:800}
.t-on{font-size:12px;font-weight:700;fill:#F5E9D4 !important}
.t-on.small{font-size:10px}
.t-on.b{font-weight:800}
.t-brand{font-size:21px;font-weight:800;letter-spacing:.14em;fill:#F5E9D4 !important;opacity:.9}
.t-warn{font-size:12px;font-weight:700;fill:#A8452B !important}
.t-ok{font-size:12px;font-weight:700;fill:#2C7A57 !important}
.box{fill:#fff;stroke:#1C2C4C;stroke-width:1.6}
.sw{fill:#EFE7D6;stroke:#1C2C4C;stroke-width:1.6}
.slot{fill:#1C2C4C}
.exist-thin{fill:none;stroke:#5B667C;stroke-width:1.6}
.dashed{stroke-dasharray:5 4}
.oldbox{fill:#5E7DB8;stroke:#1C2C4C;stroke-width:1.6;opacity:.75}
.oldsock{fill:#1b1e25}
.bundle{fill:none;stroke:#9AA1AE;stroke-width:7;stroke-linecap:round}
.plug{fill:#1b1e25;stroke:#1C2C4C;stroke-width:1.6}
.pin{fill:#8b909b}
.cap{fill:#2C7A57;stroke:#fff;stroke-width:2}
.alu{fill:#CBD0D8;stroke:#1C2C4C;stroke-width:1.8}
.pivot{fill:#1C2C4C}
.armline{stroke:#1C2C4C;stroke-width:9;stroke-linecap:round;fill:none}
.armtip{fill:#C79A3B;stroke:#1C2C4C;stroke-width:1.2}
.rod{stroke:#5B667C;stroke-width:4;stroke-linecap:round;fill:none}
.guide{fill:none;stroke:#C79A3B;stroke-width:2;stroke-dasharray:4 5}
.conn{fill:#2a2e37;stroke:#1C2C4C;stroke-width:1.4}
.convbox{fill:#fff;stroke:#1C2C4C;stroke-width:1.8}
.term{fill:#C79A3B;stroke:#1C2C4C;stroke-width:1}
.ctrl{fill:#2D4C9C;stroke:#1C2C4C;stroke-width:1.8}
.ctrl-top{fill:#3A5CB4}
.fin{stroke:#1C2C4C;stroke-width:2;opacity:.35;fill:none}
.j1{fill:#1b1e25}
.tab{stroke:#0d0f13;stroke-width:1}
.t-sol{fill:#0b0c0f;stroke:#8b909b}.t-rev{fill:#3D7BFF}.t-user{fill:#35B36A}.t-ksi{fill:#E0453A}.t-thr{fill:#CBD0D8}
.stud{fill:#CBD0D8;stroke:#1C2C4C;stroke-width:1.6}
.usb{fill:#E8E4DA;stroke:#1C2C4C;stroke-width:1.2}
.led{fill:#3CDC7C;opacity:0;transition:opacity .08s}
.led.on{opacity:1;filter:drop-shadow(0 0 5px #3CDC7C) drop-shadow(0 0 10px #3CDC7C)}
.packbox{fill:#F0A45B;stroke:#1C2C4C;stroke-width:1.8}
.heavy{fill:none;stroke:#8C929E;stroke-width:9;stroke-linecap:round;stroke-linejoin:round}
.lap{fill:#1C2C4C}.lapbase{fill:#5B667C}
.usbcable{fill:none;stroke:#E8E4DA;stroke-width:4;stroke-linecap:round;filter:drop-shadow(0 0 1px #10192c)}
.wire{fill:none;stroke-width:3.6;stroke-linecap:round;stroke-linejoin:round}
.wire.ksi{stroke:#7B4FA6;stroke-width:2.4}
.wire.ksi.old{stroke-dasharray:5 4;stroke-width:2}
.wire.w5{stroke:#D4433A}
.wire.wg{stroke:#15171c}
.wire.wv{stroke:#7B4FA6}
.wire.so{stroke:#15171c;stroke-width:6}
.wire.si{stroke:#fff;stroke-width:3}
.oldsig{fill:none;stroke:#E0862A;stroke-width:3.4;stroke-linecap:round;stroke-dasharray:6 4}
.jdot{fill:#1C2C4C}
.fuse{fill:#FBF6EC;stroke:#1C2C4C;stroke-width:1.6}
.pshadow{fill:#1C2C4C;opacity:.18}
.pframe{fill:none;stroke:#1C2C4C;stroke-width:1.4}
.tag rect{fill:#FFFDF7;stroke:#1C2C4C;stroke-width:.8;opacity:.96}
.tag text{font-size:9.5px;font-weight:800}
.tag.dark rect{fill:#1C2C4C;stroke:#F5E9D4;stroke-width:.6}
.tag.dark text{fill:#F5E9D4 !important;font-size:8.6px;letter-spacing:.07em}
.lead{fill:none;stroke:#FFFDF7;stroke-width:1.5;stroke-linecap:round}
.ring{fill:none;stroke:#F2C14E;stroke-width:2.2}
.ring.gray{stroke:#fff;stroke-width:1.6;stroke-dasharray:3 2.4}
.t-photo.sm{font-size:8.5px;stroke-width:2.6px}
.t-photo{font-size:10.5px;font-weight:800;fill:#fff !important;paint-order:stroke;stroke:#10192c;stroke-width:3px;stroke-linejoin:round}
.wire.new,.wire.ksi{filter:drop-shadow(0 0 .7px #fff) drop-shadow(0 0 .7px #fff)}
.is-hidden{opacity:0 !important}
.part{transition:opacity .5s}
.part.dim{opacity:.28}
.fade{transition:opacity .5s}
#old-sig{transition:transform .9s ease, opacity .9s ease}
#old-sig.gone{transform:translate(-16px,26px);opacity:.55}
#plug-cap{transition:opacity .6s}
.halo{fill:none;stroke:#C79A3B;stroke-width:3;opacity:0}
.halo.on{opacity:1;animation:pulse 1.6s ease-in-out infinite}
@keyframes pulse{0%,100%{stroke-opacity:.95;stroke-width:3}50%{stroke-opacity:.25;stroke-width:7}}
.flow{fill:none;stroke:#fff;stroke-width:2;stroke-linecap:round;stroke-dasharray:2 16;opacity:0}
.flow.dark{stroke:#2F7F7C}
#wiring.live .flow:not(.is-hidden){opacity:.95;animation:flow 1s linear infinite}
@keyframes flow{to{stroke-dashoffset:-18}}
@media (prefers-reduced-motion: reduce){
  .halo.on{animation:none}
  #wiring.live .flow:not(.is-hidden){animation:none;opacity:0}
  .part,.fade,#old-sig,#plug-cap{transition:none}
}
@media (max-width: 900px){
  .player{grid-template-columns:1fr}
  .stage{border-right:0;border-bottom:1px solid var(--line)}
  .glance{grid-template-columns:1fr 1fr}
  .two,.why,.parts{grid-template-columns:1fr}
}
@media (max-width: 600px){
  .stage svg{aspect-ratio:1/1}
}
@media (max-width: 520px){
  .glance{grid-template-columns:1fr}
  .step{grid-template-columns:1fr}
  .step .n{grid-row:auto}
  .pedal{grid-template-columns:1fr auto}
  .pedal input{grid-column:1/-1;grid-row:2}
}
@media print{
  .controls,.dots,.show,.pedal{display:none}
  .card,.step{break-inside:avoid}
  body{background:#fff}
}

/* ---------- whole-system views ---------- */
[hidden]{display:none !important}
.stage{--panel:#FFFFFF;--ink:#1C2C4C;--muted:#5B667C;--line:#E4DAC6;--accent:#2F7F7C;--gold:#A87C22;--warn:#A8452B;--ok:#2C7A57;--bg:#FBF6EC}
.modes{display:flex;flex-wrap:wrap;gap:8px}
.modes button{border:1.5px solid var(--ink);background:transparent;border-radius:999px;padding:9px 16px;font-weight:700;font-size:.93rem}
.modes button[aria-pressed="true"]{background:var(--ink);color:var(--bg)}
.modes button:focus-visible,.seg button:focus-visible,.viewbar button:focus-visible,.symlist button:focus-visible,.symgo:focus-visible,.linkbtn:focus-visible,.pin:focus-visible{outline:3px solid var(--accent);outline-offset:2px}
.modehint{color:var(--muted);max-width:84ch;font-size:.95rem}
.player[data-mode="explore"],.player[data-mode="trouble"]{grid-template-columns:minmax(0,1fr)}
.player[data-mode="explore"] .stage,.player[data-mode="trouble"] .stage{border-right:0;border-bottom:1px solid var(--line)}
.player[data-mode="explore"] .stage svg#wiring,.player[data-mode="trouble"] .stage svg#wiring{aspect-ratio:11/5}
.player:not([data-mode="install"]) .dots{display:none}
.player[data-mode="trouble"] .pedal,.player[data-mode="locate"] .pedal{display:none}
.player:not([data-mode="explore"]) .simbar{display:none}
.player[data-mode="install"] .viewbar,.player[data-mode="locate"] .viewbar,.player[data-mode="tour"] .viewbar{display:none}
.tdots{display:flex;flex-wrap:wrap;gap:6px;padding:4px 20px 6px}
.tourbtns{display:flex;flex-wrap:wrap;gap:8px}
.tourbtns .btn[aria-pressed="true"]{background:var(--ink);color:var(--bg)}
.player[data-mode="locate"] .maphint{display:none}
.stage svg#carmap{aspect-ratio:16/9;cursor:default;touch-action:auto}
.carwrap{margin:0}
.player[data-mode="explore"] .zoomctl,.player[data-mode="trouble"] .zoomctl{position:static;justify-content:flex-end;padding:10px 12px 12px}
.carwrap figcaption{font-size:.84rem;color:#5B667C;padding:10px 16px 14px}

.simbar,.viewbar{display:flex;flex-wrap:wrap;gap:10px 26px;align-items:center;padding:12px 16px;border-top:1px solid var(--line);color:var(--ink)}
.viewbar{gap:8px;border-top:0;padding-top:0}
.seg{display:inline-flex;align-items:center;flex-wrap:wrap}
.seglbl{font-weight:700;font-size:.9rem;margin-right:10px}
.seg button{border:1.5px solid var(--ink);background:transparent;padding:7px 14px;font-weight:700;font-size:.88rem;margin-left:-1.5px}
.seg button:first-of-type{border-radius:999px 0 0 999px;margin-left:0}
.seg button:last-of-type{border-radius:0 999px 999px 0}
.seg button[aria-pressed="true"]{background:var(--ink);color:var(--bg)}
.seg button.hot[aria-pressed="true"]{background:var(--warn);border-color:var(--warn);color:#fff}
.viewbar button{border:1.5px solid var(--line);background:#fff;border-radius:999px;padding:6px 12px;font-weight:700;font-size:.84rem;color:var(--ink)}

.partcard{border-top:1px solid var(--line);padding:16px;display:flex;flex-direction:column;gap:12px;color:var(--ink);background:#fff}
.pc-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}
.pc-head .eyebrow{font-size:.72rem;margin-bottom:2px}
.pc-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px 22px}
.pc-grid h4,.pane h4{margin:0 0 4px;font-size:.76rem;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700}
.pc-grid p,.pc-where{font-size:.93rem}
.partcard table{font-size:.88rem}
.pc-foot{font-size:.84rem;color:var(--muted)}

.pane{display:flex;flex-direction:column;min-width:0;flex:1}
.side .pane .now{flex:0 0 auto}
.side .pane.grow .now{flex:1}
.panegrid{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);gap:20px 32px;padding:6px 20px 22px}
.panegrid>div{display:flex;flex-direction:column;gap:10px;min-width:0}
.livel{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:9px;font-size:.93rem}
.livel li{display:grid;grid-template-columns:auto minmax(0,1fr);gap:10px;align-items:baseline}
.livel .dotl{width:.7em;height:.7em;border-radius:50%;border:1.5px solid var(--muted);display:inline-block}
.livel li.on .dotl{background:var(--gold);border-color:var(--gold)}
.livel b{display:block}
.livel span.v{color:var(--muted)}
.livel li.on span.v{color:var(--ink)}
.lays{display:flex;flex-direction:column;gap:7px;font-size:.93rem}
.lays label{display:flex;gap:9px;align-items:center;font-weight:700}
.lays input{width:18px;height:18px;accent-color:var(--accent)}
.key{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 16px;font-size:.88rem}
.key li{display:flex;gap:8px;align-items:center}
.sw{flex:none;width:32px;height:14px;border-radius:4px;border:1px solid #CFC4AC;background:linear-gradient(var(--c),var(--c)) center/22px 4px no-repeat,#FBF6EC}
.sw.fat{background-size:22px 8px,auto}
.sw.dash{background:repeating-linear-gradient(90deg,var(--c) 0 4px,transparent 4px 8px) center/22px 3px no-repeat,#FBF6EC}
.sw.out{background:linear-gradient(#fff,#fff) center/20px 3px no-repeat,linear-gradient(#15171c,#15171c) center/22px 6px no-repeat,#FBF6EC}

.symlist{display:flex;flex-direction:column;gap:6px}
.symlist button{text-align:left;border:1.5px solid var(--line);background:transparent;border-radius:12px;padding:9px 12px;font-weight:700;font-size:.92rem}
.symlist button[aria-pressed="true"]{border-color:var(--warn);box-shadow:inset 4px 0 0 var(--warn)}
.symsteps{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:12px}
.symsteps li{display:grid;grid-template-columns:auto minmax(0,1fr);gap:12px;align-items:start;font-size:.94rem}
.symgo{width:32px;height:32px;border-radius:50%;border:0;background:var(--warn);color:var(--bg);font-weight:800;font-variant-numeric:tabular-nums}
.expect{display:block;color:var(--muted);font-size:.9rem;margin-top:2px}
.expect b{color:var(--ok)}

.pinlist{list-style:none;margin:0;padding:0 20px 20px;display:flex;flex-direction:column;gap:14px}
.pinlist li{display:grid;grid-template-columns:auto minmax(0,1fr);gap:12px;align-items:start;font-size:.94rem}
.pinlist li.sel .pinnum{background:#F2C14E}
.pinnum{width:30px;height:30px;border-radius:50%;background:#C79A3B;color:#1C2C4C;display:grid;place-items:center;font-weight:800}
.pinlist span.w{display:block;color:var(--muted)}
.linkbtn{border:0;background:none;color:var(--accent);font-weight:700;font-size:.86rem;padding:3px 0;text-decoration:underline;text-underline-offset:3px;display:inline-block}

/* wire list */
.wirelist td:first-child,.wirelist td:last-child{white-space:nowrap}
.wirelist .linkbtn{display:block;text-align:left}
.statkey{display:flex;flex-wrap:wrap;gap:6px 22px;font-size:.88rem;color:var(--muted);margin:0;padding:0;list-style:none}
.statkey .stat{display:inline;color:var(--ink)}
.wirelist tr.grp th{padding-top:18px;font-size:.8rem;color:var(--gold)}
.lab{display:inline-block;border:1.5px solid #1C2C4C;border-radius:6px;padding:2px 8px;font-weight:800;font-size:.8rem;letter-spacing:.04em;background:#FFFDF7;color:#1C2C4C;white-space:nowrap}
.stat{display:block;font-size:.82rem;font-weight:700}
.stat::before{content:"";display:inline-block;width:.6em;height:.6em;border-radius:50%;margin-right:.45em;background:var(--muted)}
.stat.s-seen::before{background:var(--ok)}
.stat.s-part::before{background:var(--gold)}
.stat.s-todo::before{background:var(--warn)}
.stat.s-new::before{background:var(--accent)}
.labels{display:flex;flex-wrap:wrap;gap:8px 18px}
.labels span.pair{display:inline-flex;gap:4px}
.trace{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:2px}
.trace li{display:grid;grid-template-columns:auto minmax(0,1fr);gap:12px;align-items:start;padding:9px 0;border-bottom:1px solid var(--line)}
.trace li:last-child{border-bottom:0}
.trace input{width:18px;height:18px;accent-color:var(--accent);margin-top:3px}
.trace li.flash{animation:flashrow 1.6s ease 1}
@keyframes flashrow{0%,60%{background:color-mix(in srgb, var(--gold) 28%, transparent)}100%{background:transparent}}
.trace li.done label{color:var(--muted);text-decoration:line-through}
.small{font-size:.93rem}

/* map additions */
.wire.cw{stroke-width:2.4;filter:drop-shadow(0 0 .7px #fff) drop-shadow(0 0 .7px #fff)}
.wire.red{stroke:#D4433A}.wire.vio{stroke:#7B4FA6}.wire.grn{stroke:#2E9B57}.wire.blu{stroke:#2F5FD0}.wire.yel{stroke:#E6C23A}.wire.org{stroke:#E0862A}
.wire.cwo{stroke:#15171c;stroke-width:4.6}
.wire.cwi{stroke:#fff;stroke-width:2.4}
.wire.ret{stroke:#15171c;stroke-width:2;stroke-dasharray:4 4}
.hvo{fill:none;stroke:#1C2C4C;stroke-width:8.5;stroke-linecap:round;stroke-linejoin:round}
.hv{fill:none;stroke-width:5.5;stroke-linecap:round;stroke-linejoin:round}
.hv.red{stroke:#C8433A}.hv.gry{stroke:#A3A9B5}.hv.wht{stroke:#fff}.hv.grn{stroke:#3E9B5F}.hv.yel{stroke:#E6C23A}.hv.blk{stroke:#2a2e37}
.flow.heavy{stroke-width:3.2;stroke-dasharray:3 20}
@keyframes flowh{to{stroke-dashoffset:-23}}
.wid rect{fill:#FFFDF7;stroke:#1C2C4C;stroke-width:.8}
.wid text{font-size:9px;font-weight:800;letter-spacing:.03em;text-anchor:middle}
.q{cursor:help}
.q circle{fill:#F2C14E;stroke:#1C2C4C;stroke-width:1.2}
.q text{font-size:10.5px;font-weight:800;text-anchor:middle}
.q.done circle{fill:#2C7A57}
#wiring .q.done text{fill:#fff}
.fuse.dashed{stroke-dasharray:4 3}
.loom{fill:rgba(28,44,76,.07);stroke:#1C2C4C;stroke-width:1;stroke-dasharray:2 4;opacity:.8}
.st rect{fill:#1C2C4C;stroke:#F5E9D4;stroke-width:.6;opacity:1}
#wiring .st text{fill:#F5E9D4;font-size:8.6px;letter-spacing:.07em}
.st.on rect{fill:#A8452B}
#wiring:not(.sim) .st{display:none}
#wiring.no-control .layer[data-layer="control"],#wiring.no-control .wids [data-layer="control"],
#wiring.no-power .layer[data-layer="power"],#wiring.no-power .wids [data-layer="power"],
#wiring.no-throttle [data-wire],#wiring.no-names .wids,#wiring.no-q .qs,
#wiring.no-drive .part[data-part="mainc"],#wiring.no-drive .part[data-part="rev"],#wiring.no-drive .part[data-part="motor"],#wiring.no-drive .pz{display:none}
.hlglow{fill:none;stroke:#F2C14E;stroke-width:12;stroke-linecap:round;stroke-linejoin:round;opacity:.8;animation:glow 1.1s ease-in-out infinite}
@keyframes glow{50%{opacity:.3}}
.sus{fill:none;stroke:#A8452B;stroke-width:3;stroke-dasharray:9 6}
.sus.pulse{animation:susp .5s ease-in-out 4;stroke-dasharray:none}
@keyframes susp{50%{stroke-width:8}}
.susb rect{fill:#A8452B;stroke:#fff;stroke-width:2}
#wiring .susb text{fill:#fff;font-size:14px;font-weight:800;text-anchor:middle}
#carmap .pin{cursor:pointer}
#carmap .pin circle{fill:#C79A3B;stroke:#fff;stroke-width:6}
#carmap .pin.sel circle{fill:#F2C14E;stroke:#1C2C4C}
#carmap .pin text{font-family:var(--body);font-size:38px;font-weight:800;fill:#1C2C4C;text-anchor:middle}
#carmap .pinlbl{font-family:var(--body);font-size:34px;font-weight:800;fill:#fff;paint-order:stroke;stroke:#10192c;stroke-width:9px;stroke-linejoin:round}

/* live-wire simulation */
#wiring.sim .flow{opacity:0;animation:none}
#wiring.sim .flow[data-live="always"],
#wiring.sim.k-on .flow[data-live="key"],
#wiring.sim.k-on.d-f .flow[data-live="f"],
#wiring.sim.k-on.d-r .flow[data-live="r"]{opacity:.95;animation:flow 1s linear infinite}
#wiring.sim .flow.heavy[data-live="always"]{animation:flowh 1.5s linear infinite}
#wiring.sim.drive .flow.heavy{opacity:.95;animation:flowh var(--spd,.8s) linear infinite}
#wiring.sim.drive.d-r .flow.heavy[data-fld]{animation-direction:reverse}

@media (min-width: 901px){
  .player[data-mode="explore"] .pc-grid,.player[data-mode="trouble"] .pc-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
}
@media (max-width: 900px){
  .panegrid{grid-template-columns:1fr}
}
@media (max-width: 600px){
  .player[data-mode] .stage svg#wiring{aspect-ratio:1/1}
  .pc-grid,.key{grid-template-columns:1fr}
  .modes button{padding:8px 13px;font-size:.88rem}
  .seg{flex-wrap:nowrap}
  .seg button{padding:7px 10px;font-size:.84rem}
  .simbar{gap:10px 18px}
}
@media (prefers-reduced-motion: reduce){
  #wiring.sim .flow[data-live="always"],
  #wiring.sim.k-on .flow[data-live="key"],
  #wiring.sim.k-on.d-f .flow[data-live="f"],
  #wiring.sim.k-on.d-r .flow[data-live="r"],
  #wiring.sim.drive .flow.heavy,#wiring.sim .flow.heavy[data-live="always"]{animation:none;opacity:.95}
  .hlglow,.sus.pulse,.trace li.flash{animation:none}
}
