/* GoldBook console. Plain ASCII only.
   One light, calm surface. Colour carries meaning, never decoration: each hue is a cue from cues.js, drawn as a
   class, and always paired with an icon or a word. No inline style reaches the page (the server's policy refuses
   it), so every colour a mark takes is a class here, and a measured width is set through the CSSOM. No web font
   is loaded: GoldBook runs inside the laboratory and fetches nothing from outside it. */
:root{
  color-scheme: light;
  --page:#f4f6f9; --surface:#ffffff; --surface-2:#f8fafc; --surface-3:#eef2f6;
  --line:#e3e8ee; --line-2:#d3dae3; --grid:#e8ecf1;
  /* --muted is measured against the DARKEST surface it sits on, not against white: #6f7d8b read
     4.22:1 on --surface but 3.75:1 on --surface-3, so a value chosen for white would have left most
     of its uses failing. #636f7c is the same hue and saturation, one step darker in value, and
     clears 4.5:1 on all four: 5.13 on --surface, 4.90 on --surface-2, 4.74 on --page, 4.56 on
     --surface-3. --faint stays where it is: it is the fourth step of ink -> ink-2 -> muted -> faint
     and its remaining uses are a separator, a hover border and an arrow, none of which are text. */
  --ink:#10202c; --ink-2:#435363; --muted:#636f7c; --faint:#9aa5b1;
  --gold:#b08a2e; --gold-ink:#7a5c12; --gold-bg:#f8f0dc;
  --p-user:#1baf7a; --p-user-ink:#0b6b4b; --p-user-bg:#e2f5ec;
  --c1:#2a78d6; --c3:#1baf7a; --c4:#eda100;
  --good:#0ca30c; --good-ink:#006300; --good-bg:#e7f5e7;
  --warn:#fab219; --warn-ink:#7a5200; --warn-bg:#fdf4de;
  --serious:#ec835a; --serious-ink:#9a4521; --serious-bg:#fcede6;
  --crit:#d03b3b; --crit-ink:#a32626; --crit-bg:#fbe8e8;
  --neutral:#98a2ad; --neutral-ink:#52606d; --neutral-bg:#eef1f4;
  --info:#2a78d6; --info-ink:#1f5c9e; --info-bg:#e8f1fb;
  --wait:#4a3aa7; --wait-ink:#3a2e86; --wait-bg:#eeebf8;
  --q1:#cde2fb; --q2:#9ec5f4; --q3:#6da7ec; --q4:#3987e5; --q5:#256abf; --q6:#184f95; --q7:#0d366b;
  --r:14px; --r-sm:10px;
  --sh-1:0 1px 2px rgba(16,32,44,.05),0 1px 1px rgba(16,32,44,.03);
  --sh-2:0 1px 2px rgba(16,32,44,.05),0 8px 24px rgba(16,32,44,.07);
  --font:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --mono:ui-monospace,SFMono-Regular,Menlo,Consolas,"Liberation Mono",monospace;
  --rail:252px; --top:58px;
}
*{box-sizing:border-box}
html,body{margin:0;height:100%;background:var(--page);color:var(--ink);font:14.5px/1.55 var(--font);-webkit-font-smoothing:antialiased}
button,input,select,textarea{font:inherit;color:inherit}
a{color:var(--info-ink);text-decoration:none}
code{font-family:var(--mono);font-size:.86em;background:var(--surface-3);border-radius:5px;padding:1px 5px;color:var(--ink-2)}
.num{font-variant-numeric:tabular-nums}
.muted{color:var(--muted)} .ink2{color:var(--ink-2)} .small{font-size:12px}
[hidden]{display:none!important}
:focus{outline:none}
:focus-visible{outline:2px solid var(--info);outline-offset:2px;border-radius:8px}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{transition:none!important;animation:none!important}}
.skip{position:absolute;left:-999px;top:8px;background:var(--ink);color:#fff;padding:6px 10px;border-radius:8px;z-index:100}
.skip:focus{left:8px}

/* shell */
.shell{display:grid;grid-template-columns:var(--rail) minmax(0,1fr) 0;height:100vh;transition:grid-template-columns .28s ease}
.rail{height:100vh;overflow:auto;background:var(--surface);border-right:1px solid var(--line);display:flex;flex-direction:column}
.mainwrap{display:flex;flex-direction:column;min-width:0;height:100vh}
#main{flex:1;overflow:auto;overscroll-behavior:contain}
.brand{display:flex;align-items:center;gap:11px;padding:16px 18px 14px}
.brand .gem{width:30px;height:30px;border-radius:9px;background:linear-gradient(135deg,#d8b454,#9c7420)}
.brand b{font-weight:700;font-size:16px;line-height:1.1;display:block}
.brand span{font-size:11px;color:var(--muted)}
.who-am-i{padding:4px 18px 12px;border-bottom:1px solid var(--line);font-size:12.5px;color:var(--ink-2)}
.who-am-i b{color:var(--ink)}
.nav{padding:10px 10px 18px;flex:1}
.nav .grp{margin:14px 6px 4px;font-size:10.5px;letter-spacing:.9px;text-transform:uppercase;color:var(--muted);font-weight:650}
.nav a{display:flex;align-items:center;gap:10px;padding:7px 10px;margin:1px 0;border-radius:9px;color:var(--ink-2);font-size:13.5px}
.nav a svg{width:16px;height:16px;flex:none;stroke:currentColor;opacity:.75}
.nav a:hover{background:var(--surface-2);color:var(--ink)}
.nav a.on{background:var(--p-user-bg);color:var(--p-user-ink);font-weight:600}
.top{height:var(--top);flex:none;display:flex;align-items:center;gap:8px;padding:0 22px;background:var(--surface);border-bottom:1px solid var(--line);font-size:13px;color:var(--muted)}
.top b{color:var(--ink);font-weight:600}
.top .sep{color:var(--muted)}

/* buttons and forms */
.btn{display:inline-flex;align-items:center;gap:7px;border-radius:var(--r-sm);padding:7px 13px;font-size:13px;font-weight:600;border:1px solid var(--line-2);background:var(--surface);cursor:pointer;color:var(--ink)}
.btn:hover{border-color:var(--faint);background:var(--surface-2)}
.btn.primary{background:var(--ink);border-color:var(--ink);color:#fff}
.btn.sm{padding:4px 9px;font-size:12px;border-radius:8px}
.btn.ghost{border-color:transparent;background:transparent;color:var(--ink-2)}
.txt{width:100%;border:1px solid var(--line-2);border-radius:var(--r-sm);padding:8px 10px;background:var(--surface);font-size:13.5px}
.formrow{display:grid;gap:4px;margin-bottom:12px}
.formrow label{font-size:12px;color:var(--muted)}
.formrow .hint{font-size:12px;line-height:1.4;color:var(--muted)}
.signin{max-width:420px;margin:12vh auto 0}
.signin h1{font-size:22px;margin:0 0 14px}

/* page */
.page{max-width:1380px;margin:0 auto;padding:22px 28px 64px}
.head{margin-bottom:18px}
.kicker{font-size:12px;font-weight:650;letter-spacing:.3px;color:var(--p-user-ink);margin-bottom:6px}
.head h1{font-weight:750;font-size:28px;line-height:1.15;letter-spacing:-.6px;margin:0}
.head .lead{margin:8px 0 0;max-width:78ch;color:var(--ink-2)}
.grid{display:grid;gap:16px}
.g2{grid-template-columns:repeat(2,minmax(0,1fr))}
.g75{grid-template-columns:minmax(0,7fr) minmax(0,5fr)}
.mt{margin-top:16px}

/* cards and tiles */
.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--r);box-shadow:var(--sh-1);min-width:0}
.card-h{display:flex;align-items:flex-start;gap:12px;padding:15px 18px 0}
.card-h h2,.card-h h3{font-weight:700;font-size:14px;line-height:1.3;margin:0}
.card-h .sub{font-size:12px;color:var(--muted);margin-top:2px}
.card-h .tools{margin-left:auto;display:flex;gap:6px;align-items:center}
.card-b{padding:14px 18px 18px}
.card.flush .card-b{padding:6px 8px 8px}
.kpis{display:grid;gap:14px;grid-template-columns:repeat(auto-fit,minmax(190px,1fr))}
.kpi{position:relative;background:var(--surface);border:1px solid var(--line);border-radius:var(--r);padding:14px 16px 13px;box-shadow:var(--sh-1);overflow:hidden;display:flex;flex-direction:column;gap:2px}
.kpi::before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--hc,transparent)}
.kpi .k{display:flex;align-items:center;gap:7px;font-size:12px;font-weight:600;color:var(--ink-2)}
.kpi .k svg{width:14px;height:14px;stroke:var(--hc,var(--muted))}
.kpi .v{font-weight:750;font-size:27px;line-height:1.15;letter-spacing:-.6px;color:var(--hi,var(--ink));margin-top:4px}
.kpi .s{font-size:12px;color:var(--muted);line-height:1.4}
.kpi .foot{margin-top:8px}
.kpi.go{cursor:pointer}
.kpi.go:hover{box-shadow:var(--sh-2);border-color:var(--line-2)}
.kpi.shut{border-style:dashed;box-shadow:none}
.kpi .why{display:flex;align-items:center;gap:5px;margin-top:6px;font-size:12px;color:var(--muted)}
.kpi .why svg{width:12px;height:12px;stroke:var(--muted)}
[data-anchor][tabindex="-1"]:focus{outline:2px solid var(--info);outline-offset:3px}

/* cues: one class per documented cue */
.cue-heat-good,.cue-stage-complete{--hc:var(--good);--hb:var(--good-bg);--hi:var(--good-ink)}
.cue-heat-warning{--hc:var(--warn);--hb:var(--warn-bg);--hi:var(--warn-ink)}
.cue-heat-serious,.cue-stage-attention{--hc:var(--serious);--hb:var(--serious-bg);--hi:var(--serious-ink)}
.cue-heat-critical,.cue-stage-blocked{--hc:var(--crit);--hb:var(--crit-bg);--hi:var(--crit-ink)}
.cue-heat-neutral,.cue-stage-none{--hc:var(--neutral);--hb:var(--neutral-bg);--hi:var(--neutral-ink)}
.cue-heat-info,.cue-stage-active{--hc:var(--info);--hb:var(--info-bg);--hi:var(--info-ink)}
.cue-stage-waiting{--hc:var(--wait);--hb:var(--wait-bg);--hi:var(--wait-ink)}
.cue-severity-critical{--hc:var(--crit);--hb:var(--crit-bg);--hi:var(--crit-ink)}
.cue-severity-warning{--hc:var(--c4);--hb:var(--warn-bg);--hi:var(--warn-ink)}
.cue-severity-info{--hc:var(--c3);--hb:#e2f5ec;--hi:#0b6b4b}
.pill{display:inline-flex;align-items:center;gap:5px;font-size:11.5px;font-weight:650;border-radius:999px;padding:2px 9px 2px 7px;white-space:nowrap;background:var(--hb);color:var(--hi);line-height:1.5}
.pill svg{width:12px;height:12px;stroke:var(--hc)}
.chips{display:flex;gap:6px;flex-wrap:wrap}
.fchip{display:inline-flex;align-items:center;gap:6px;border:1px solid var(--line-2);background:var(--surface);border-radius:999px;padding:4px 11px;font-size:12.5px;cursor:pointer;color:var(--ink-2)}
.fchip b{font-weight:650;color:var(--ink)}
.fchip.on{background:var(--ink);border-color:var(--ink);color:#fff}
.fchip.on b{color:#fff}

/* tables */
/* A table wider than its card says so (UX-13): edge shadows that follow the scroll, drawn by the background alone. */
.tscroll{overflow-x:auto;background:linear-gradient(to right,var(--surface) 30%,transparent) left center/28px 100% no-repeat local,linear-gradient(to left,var(--surface) 30%,transparent) right center/28px 100% no-repeat local,radial-gradient(farthest-side at 0 50%,rgba(16,32,44,.22),transparent) left center/14px 100% no-repeat scroll,radial-gradient(farthest-side at 100% 50%,rgba(16,32,44,.22),transparent) right center/14px 100% no-repeat scroll}
table.t{width:100%;border-collapse:separate;border-spacing:0;font-size:13.5px}
table.t th{text-align:left;font-size:11px;letter-spacing:.6px;text-transform:uppercase;color:var(--muted);font-weight:650;padding:10px 12px;border-bottom:1px solid var(--line);white-space:nowrap}
table.t td{padding:10px 12px;border-bottom:1px solid var(--line);vertical-align:middle}
table.t tr:last-child td{border-bottom:0}
table.t .sub{font-size:12px;color:var(--muted);margin-top:1px}
table.t tr.grp td{background:var(--surface-2);font-size:12.5px;padding:8px 12px}

/* marks and charts */
.stages{display:flex;align-items:center}
.stages .ln{height:2px;flex:1;min-width:10px;background:var(--line-2)}
.smark{width:22px;height:22px;border-radius:50%;display:inline-grid;place-items:center;background:var(--hb);box-shadow:inset 0 0 0 1.6px var(--hc);flex:none}
.smark svg{width:12px;height:12px;stroke:var(--hc)}
.meter{height:8px;border-radius:5px;background:var(--surface-3);overflow:hidden}
.meter i{display:block;height:100%;background:var(--hc,var(--good));border-radius:5px;width:0}
.track{display:flex;gap:2px;height:14px;background:var(--surface-3);border-radius:4px;overflow:hidden;width:0}
.track i{display:block;height:100%;min-width:3px;background:var(--hc)}
.hbar.go{cursor:pointer}.hbar.go:hover .lab{color:var(--ink)}
/* A bar's label takes what it needs up to 40% of the row and wraps to two lines before it is cut (UX-16). */
.hbar{display:grid;grid-template-columns:fit-content(40%) minmax(0,1fr) 64px;gap:12px;align-items:center;padding:6px 0}
.hbar .lab{min-width:90px;font-size:13px;line-height:1.3;color:var(--ink-2);overflow:hidden;overflow-wrap:break-word;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.hbar .val{text-align:right;font-size:12.5px;color:var(--ink-2)}
.legend{display:flex;gap:14px;flex-wrap:wrap;font-size:12px;color:var(--ink-2);margin-top:8px}
.legend span{display:inline-flex;align-items:center;gap:6px}
.legend i{width:10px;height:10px;border-radius:3px;background:var(--hc)}
.heat{border-collapse:separate;border-spacing:3px;font-size:12px;width:100%}
.heat th{font-weight:600;color:var(--ink-2);padding:4px 6px;text-align:left;white-space:nowrap}
.heat th.col{text-align:center;font-size:11px;color:var(--muted);white-space:normal;min-width:64px}
.heat td{height:34px;min-width:44px;border-radius:6px;text-align:center;font-weight:650;font-variant-numeric:tabular-nums}
.heat td.go{cursor:pointer}
.heat td.go:hover{box-shadow:inset 0 0 0 2px var(--ink)}
.heat td.zero{background:var(--surface-2);color:var(--muted);font-weight:500}
.ramp-0{background:var(--q1)}.ramp-1{background:var(--q2)}.ramp-2{background:var(--q3)}.ramp-3{background:var(--q4)}
.ramp-4{background:var(--q5);color:#fff}.ramp-5{background:var(--q6);color:#fff}.ramp-6{background:var(--q7);color:#fff}

/* callouts and empty states */
.callout{display:flex;gap:11px;align-items:flex-start;border-radius:var(--r-sm);padding:11px 14px;background:var(--hb);color:var(--hi);font-size:13.5px;margin-bottom:12px}
.callout svg{width:17px;height:17px;stroke:var(--hc);flex:none;margin-top:1px}
.empty{display:grid;place-items:center;text-align:center;gap:4px;padding:30px 16px;color:var(--ink-2);border:1.5px dashed var(--line-2);border-radius:12px;background:var(--surface-2);font-size:13px}
.empty svg{width:22px;height:22px;stroke:var(--muted)}
.empty b{color:var(--ink);font-size:14px}
.alist{list-style:none;margin:0;padding:0}
.alist li{padding:9px 4px;border-bottom:1px solid var(--line)}
.alist li:last-child{border-bottom:0}
.alist b{font-weight:600}
.alist small{display:block;color:var(--muted);font-size:12.5px;margin-top:1px}

/* drills, tabs and record pages */
table.t tr.go{cursor:pointer}
table.t a.rowlink{color:inherit;display:block}
table.t tr.go:hover td{background:var(--surface-2)}
table.t tr.grp.go:hover td{background:var(--surface-3)}
.tabs{display:flex;gap:4px;flex-wrap:wrap;border-bottom:1px solid var(--line);margin:0 0 16px}
.tab{border:0;background:none;padding:8px 12px;font-size:13.5px;color:var(--ink-2);cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-1px}
.tab.on{color:var(--ink);font-weight:650;border-bottom-color:var(--ink)}
.meta{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin:-6px 0 16px;color:var(--ink-2);font-size:13px}
.mini{margin-bottom:8px}
.mini:last-child{margin-bottom:0}

/* filters and pages */
.filterbar{display:flex;flex-wrap:wrap;gap:10px 18px;align-items:center;padding:8px 10px 12px;border-bottom:1px solid var(--line)}
.filtergroup,.pick{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.lbl{font-size:11px;letter-spacing:.6px;text-transform:uppercase;color:var(--muted);font-weight:650}
.pick select{width:auto;max-width:260px;padding:5px 8px;font-size:12.5px}
.fchip svg{width:12px;height:12px;stroke:currentColor}
.pager{display:flex;align-items:center;gap:8px;padding:10px 12px 4px;font-size:12.5px;color:var(--muted)}
.pager span{margin-right:auto}
.hbar.go{cursor:pointer;border-radius:6px}
.hbar.go:hover .lab{color:var(--ink)}

@media (max-width:1180px){.g75{grid-template-columns:minmax(0,1fr)}}
.navbtn{display:none}
@media (max-width:860px){.shell{grid-template-columns:minmax(0,1fr) 0}.rail{display:none}
  body.ask-half .mainwrap,body.ask-full .mainwrap{display:none}.g2{grid-template-columns:minmax(0,1fr)}.page{padding:18px 16px 48px}
  .navbtn{display:inline-flex}.rail.open{display:flex;position:fixed;top:0;bottom:0;left:0;width:min(320px,90vw);z-index:60;box-shadow:0 0 0 100vw rgba(0,0,0,.35)}
  .kpis{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* record pages (wave 3 stage 3d): a changed cell, and the revision that last touched one */
.ba{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-variant-numeric:tabular-nums}
/* The row through the revisions (pages/finding.js): one step per comparison in version order. The steps hold still; the
   viewed step carries the mark (a bar and a tint) and the viewed finding says Viewing. Three columns, stacked at phone width. */
.rowhist{list-style:none;margin:0;padding:0}
.rh-step{display:grid;grid-template-columns:120px minmax(0,1fr) minmax(0,.9fr);gap:14px;padding:12px 14px 12px 16px;border-top:1px solid var(--line);border-left:3px solid transparent}
.rh-step:first-child{border-top:0}
.rh-step.here{border-left-color:var(--gold);background:var(--gold-bg)}
.rh-when{font-weight:650;font-variant-numeric:tabular-nums;white-space:nowrap}
/* A CAS number is one token: broken at its hyphens it reads as two numbers. */
.cas{white-space:nowrap}
.rh-cells,.rh-found{list-style:none;margin:0;padding:0;display:grid;gap:8px}
.rh-cells li{display:grid;gap:3px}
.rh-col{font-size:12px;font-weight:650;color:var(--ink-2)}
.rh-cells .pill{justify-self:start}
.rh-found li,.rh-found a{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.rh-found a{color:inherit;text-decoration:none;border-radius:8px;padding:2px 4px;margin:-2px -4px}
.rh-found a:hover span:not(.pill){text-decoration:underline}
.rh-found a:focus-visible,.rh-found li.self:focus-visible{outline:2px solid var(--info);outline-offset:2px}
.rh-found li.self{font-weight:650}
.rh-more{margin-top:8px}.rh-more summary{cursor:pointer;color:var(--info-ink);font-size:12.5px}.rh-more .rh-cells{margin-top:8px}
@media (max-width:860px){.rh-step{grid-template-columns:minmax(0,1fr);gap:8px}}
.ba .o{color:var(--muted);text-decoration:line-through}
.ba .ar{color:var(--muted)}
.ba .n{font-weight:650}
.mark{display:inline-flex;align-items:center;gap:6px}
.mark .sw{width:12px;height:12px;border-radius:3px;border:1px solid var(--faint);flex:none}
.ba code{font-size:.82em}
.rev{display:inline-block;padding:1px 7px;border-radius:6px;font-size:11.5px;font-weight:650;background:var(--rb);color:var(--ri)}
.rev-0{--rb:var(--neutral-bg);--ri:var(--neutral-ink)} .rev-1{--rb:var(--q1);--ri:var(--q7)} .rev-2{--rb:var(--q2);--ri:var(--q7)}
.rev-3{--rb:var(--q3);--ri:var(--ink)} .rev-4{--rb:var(--q4);--ri:var(--ink)} .rev-5{--rb:var(--q5);--ri:#fff} .rev-6{--rb:var(--q6);--ri:#fff}
.rev-7{--rb:var(--q7);--ri:#fff}
td.revcell{border-left:3px solid var(--rb)}
/* In a narrow card the label column gives way (to 35%) and a value with no space in it breaks rather than widen the
   page (UX-12: an incident's rule code pushed the page to 680px inside 508). */
.kv{display:grid;grid-template-columns:minmax(min(120px,35%),min(180px,40%)) minmax(0,1fr);gap:8px 14px;font-size:13.5px}
.kv dt{color:var(--muted)} .kv dd{margin:0;min-width:0;overflow-wrap:break-word}
.actrow{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:10px}
.note{font-size:12.5px;color:var(--ink-2);margin-top:8px}
.btn:disabled{opacity:.5;cursor:default}
video.reel{width:100%;border-radius:10px;background:#000;max-height:360px}

/* the admin portal (wave 4) */
.nav .portal{margin:18px 6px 2px;padding-top:12px;border-top:1px solid var(--line)}
.nav .portal:first-child{margin-top:4px;padding-top:0;border-top:0}
.nav .portal b{display:block;font-size:12.5px;color:var(--ink)}
.nav .portal span{display:block;font-size:11px;color:var(--muted)}
.who-am-i .sub{color:var(--muted);font-size:11.5px}
.who-am-i .acting{margin-top:6px;padding:5px 8px;border-radius:8px;background:var(--warn-bg);color:var(--warn-ink);font-size:12px;display:flex;gap:6px;align-items:center}
.who-am-i .acting svg{width:14px;height:14px;stroke:currentColor}
.who-am-i a{display:inline-block;margin-top:6px;font-size:12px}
.who-am-i a.on{font-weight:600}
.lane{display:flex;gap:10px;align-items:flex-start}
.lane>span{flex:none;writing-mode:vertical-rl;transform:rotate(180deg);font-size:10.5px;letter-spacing:.9px;text-transform:uppercase;color:var(--muted)}
.lane .row{display:flex;gap:10px;flex-wrap:wrap}
.stepbox{flex:1 1 180px;min-width:160px;max-width:240px;border:1px solid var(--line);border-radius:var(--r-sm);padding:10px 12px;background:var(--surface-2);display:flex;flex-direction:column;gap:3px}
.stepbox b{font-size:13px}
.stepbox small{font-size:11.5px;color:var(--ink-2)}
.stepbox.go{cursor:pointer}
.stepbox.go:hover{border-color:var(--line-2);background:var(--surface)}
.stepbox.dim{opacity:.35}
.stepbox.outside{border-style:dashed;background:var(--surface)}
.cards{display:grid;gap:14px;grid-template-columns:repeat(auto-fill,minmax(270px,1fr))}
.cardlet{position:relative;overflow:hidden}
.cardlet::before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--hc,transparent)}
.cardlet.go{cursor:pointer}
.cardlet.go:hover{box-shadow:var(--sh-2);border-color:var(--line-2)}
.cardlet .card-h{padding:13px 16px 0}
.cardlet .card-b{padding:10px 16px 14px}
.cardlet .facts{display:flex;flex-wrap:wrap;gap:6px 14px;font-size:12.5px;color:var(--ink-2);margin-top:8px}
.cardlet .facts b{color:var(--ink);font-weight:650}
.cardlet .foot{margin-top:8px;font-size:12px;color:var(--muted)}
/* drill cards (kit.drill): the summary is the card's head and only toggles; an open card spans its row of the grid */
.drill>summary{list-style:none;cursor:pointer;display:flex;align-items:flex-start;gap:8px;padding:0 14px 13px 0;border-radius:var(--r)}
.drill>summary::-webkit-details-marker{display:none}
.drill>summary>.card-h{flex:1;min-width:0}
.drill>summary>svg{flex:none;width:16px;height:16px;margin-top:14px;stroke:var(--muted);transition:transform .15s}
.drill[open]>summary>svg{transform:rotate(90deg)}
.drill>summary:focus-visible{outline:2px solid var(--info);outline-offset:-2px}
.drills>.drill[open]{grid-column:1/-1}
.drill>.card-b{border-top:1px solid var(--line);padding:6px 8px 8px}
.drill>.card-b>.actrow{padding:4px 8px}
.defs{display:grid;grid-template-columns:max-content 1fr;gap:4px 12px;margin:14px 0 0}.defs dt{font-weight:600;font-size:13px}.defs dd{margin:0}
@media (max-width:600px){.defs{grid-template-columns:1fr}}
.card-p{padding:10px 14px 4px;margin:0}
.finder{display:flex;flex-direction:column;gap:6px;min-width:0}.finder .finder-sug{margin-top:2px}.finder .finder-none .empty{padding:14px}
.track.full{width:100%}
.pick{min-width:0;max-width:100%}.pick select{max-width:100%;min-width:0}
.card-h{flex-wrap:wrap}.card-h .tools{flex-wrap:wrap;justify-content:flex-end;min-width:0;max-width:100%}
.chips{min-width:0;max-width:100%}.chips .fchip{max-width:100%;min-width:0;white-space:normal;text-align:left;overflow-wrap:break-word}
.facts{overflow-wrap:break-word}.cardlet h3,.cardlet .sub{overflow-wrap:break-word}
/* Demo mode's "Viewing as" switch: the first thing in the top bar's tools, drawn in the brand's gold so a visitor finds it. */
.top .viewas{display:inline-flex;align-items:center;gap:8px;min-width:0;padding:4px 6px 4px 10px;border:1px solid var(--gold);border-radius:var(--r-sm);background:var(--gold-bg)}
.top .viewas label{font-size:11px;font-weight:700;letter-spacing:.8px;text-transform:uppercase;color:var(--gold-ink);white-space:nowrap}
.top .viewas select{min-width:0;max-width:340px;font:600 13px var(--font);color:var(--ink);padding:5px 8px;border:1px solid var(--line-2);border-radius:8px;background:var(--surface)}
.signin select.txt{width:100%}
/* Preview mode: the banner above every page. The shell gives up the banner's height, however many lines it wraps to. */
.preview-banner{flex:none;padding:7px 16px;border-bottom:1px solid var(--gold);background:var(--gold-bg);color:var(--gold-ink);font-size:13px;font-weight:600;text-align:center}
body.preview{display:flex;flex-direction:column;height:100vh}
body.preview .shell{flex:1 1 auto;min-height:0;height:auto;grid-template-rows:minmax(0,1fr)}
body.preview .rail,body.preview .mainwrap,body.preview #dock{height:100%}
.signin .terms label{display:flex;gap:8px;align-items:flex-start;font-size:13px;color:var(--ink)}
.signin .terms input{margin-top:3px;flex:none}
.crumbs{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-bottom:12px}
.crumbs .sep{color:var(--muted);font-size:12px}
.swim{display:grid;gap:6px;grid-auto-rows:auto;overflow-x:auto;padding-bottom:6px;align-items:stretch}
.swim.n1{grid-template-columns:150px repeat(1,176px)}
.swim.n2{grid-template-columns:150px repeat(2,176px)}
.swim.n3{grid-template-columns:150px repeat(3,176px)}
.swim.n4{grid-template-columns:150px repeat(4,176px)}
.swim.n5{grid-template-columns:150px repeat(5,176px)}
.swim.n6{grid-template-columns:150px repeat(6,176px)}
.swim.n7{grid-template-columns:150px repeat(7,176px)}
.swim.n8{grid-template-columns:150px repeat(8,176px)}
.swim.n9{grid-template-columns:150px repeat(9,176px)}
.swim.n10{grid-template-columns:150px repeat(10,176px)}
.swim.n11{grid-template-columns:150px repeat(11,176px)}
.swim.n12{grid-template-columns:150px repeat(12,176px)}
.swim.n13{grid-template-columns:150px repeat(13,176px)}
.swim.n14{grid-template-columns:150px repeat(14,176px)}
.swim.n15{grid-template-columns:150px repeat(15,176px)}
.swim.n16{grid-template-columns:150px repeat(16,176px)}
.swim .lane-lab{display:flex;align-items:center;border-right:2px solid var(--line-2);padding-right:10px}
.swim .lane-lab span{font-size:10.5px;letter-spacing:.8px;text-transform:uppercase;color:var(--muted);line-height:1.3}
.swim .swimcell{min-width:0}
.swim .stepbox{max-width:none;min-width:0;height:100%;box-sizing:border-box}
.swim .swimcell{display:flex}
.swim .who{display:none}
/* kit.fit: what does not fit its card is drawn down the page, not across it. */
.swim.stack{display:flex;flex-direction:column;overflow:visible;gap:8px;counter-reset:step}
.swim.stack .lane-lab{display:none}
.swim.stack .swimcell{counter-increment:step;display:grid;grid-template-columns:minmax(120px,28%) minmax(0,1fr);gap:12px;align-items:start}
.swim.stack .who::before{content:counter(step) ". "}
.swim.stack .who{display:block;font-size:11px;letter-spacing:.6px;text-transform:uppercase;color:var(--muted);font-weight:600;padding-top:8px;overflow-wrap:break-word}
.tscroll.stack{overflow:visible;background:none;position:relative;container-type:inline-size}
.tscroll.stack table,.tscroll.stack tbody,.tscroll.stack tr,.tscroll.stack td{display:block;width:auto}
.tscroll.stack thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.tscroll.stack tr{padding:8px 12px;border-bottom:1px solid var(--line)}
.tscroll.stack tr:last-child{border-bottom:0}
.tscroll.stack td{display:grid;grid-template-columns:minmax(96px,32%) minmax(0,1fr);gap:10px;padding:3px 0;border:0;text-align:left;min-width:0;overflow-wrap:break-word}
.tscroll.stack td:not([data-h]){grid-template-columns:minmax(0,1fr)}
.tscroll.stack td[data-h]::before{content:attr(data-h) / "";font-size:11.5px;color:var(--muted);font-weight:600}
.tscroll.stack td:empty{display:none}
.tscroll.stack tr.grp td{display:block;font-weight:600}
/* A card too narrow to set a name beside its value sets it above: the value has the card's width, and a long word fits. */
@container (max-width: 380px){.tscroll.stack td{grid-template-columns:minmax(0,1fr);gap:0}.tscroll.stack td[data-h]::before{margin-top:4px}}
.r1{grid-row:1}.r2{grid-row:2}.r3{grid-row:3}.r4{grid-row:4}.r5{grid-row:5}.r6{grid-row:6}.r7{grid-row:7}.r8{grid-row:8}
.c1{grid-column:1}.c2{grid-column:2}.c3{grid-column:3}.c4{grid-column:4}.c5{grid-column:5}.c6{grid-column:6}.c7{grid-column:7}.c8{grid-column:8}
.c9{grid-column:9}.c10{grid-column:10}.c11{grid-column:11}.c12{grid-column:12}.c13{grid-column:13}.c14{grid-column:14}.c15{grid-column:15}.c16{grid-column:16}.c17{grid-column:17}
.stepbox .pill{align-self:flex-start;margin-top:4px}
table.matrix th{white-space:nowrap;text-align:center}
table.matrix th:first-child{text-align:left}
table.matrix td{text-align:center;vertical-align:middle}
table.matrix td:first-child{text-align:left}
table.matrix td.indent{padding-left:28px;color:var(--ink-2)}
.nocell{color:var(--muted);font-size:11.5px}
.acell{display:inline-flex;flex-direction:column;gap:2px;align-items:center;padding:4px 8px;border-radius:8px;background:var(--info-bg);color:var(--info-ink)}
.acell.over{background:var(--crit-bg);color:var(--crit-ink)}
.acell small{font-size:11px}
.dbars{display:inline-flex;align-items:center;gap:2px}
.dbars i{display:inline-block;width:6px;height:10px;border-radius:2px;background:var(--line-2)}
.dbars i.on{background:var(--info)}
.dbars.over i.on{background:var(--crit)}
.dbars b{margin-left:4px;font-size:11.5px}
.rec{display:block;color:var(--ink-2);font-size:12px;margin-top:2px}

/* The assistant's panel (dock.js): the shell's third column. Closed, the column is nothing; open, it is docked
   at 380px, half the window, or the whole of it, one set of body classes driving the grid. The anatomy is the
   tariff platform's assistant panel, drawn in the console's own tokens: a launcher at rest in the corner, the
   modes and the minimize control on one row, the context line and the sizes on the next, the log, the input. */
.top-tools{margin-left:auto;display:flex;align-items:center;gap:8px;min-width:0}
@media (max-width:860px){.top:has(.viewas)>span:not(.top-tools),.top:has(.viewas)>b,.top .viewas label{display:none}.top .viewas select{max-width:min(340px,calc(100vw - 150px))}}
body.ask-open .shell{grid-template-columns:var(--rail) minmax(0,1fr) 380px}
/* Half is half the window up to 520px (UX-12): at 1280, half left the page 388px and 49 of 291 routes overflowed it. */
body.ask-half .shell{grid-template-columns:var(--rail) minmax(0,1fr) min(50vw,520px)}
body.ask-full .shell{grid-template-columns:minmax(0,1fr)}
body.ask-full .rail,body.ask-full .mainwrap{display:none}
#dock{display:none;flex-direction:column;min-width:0;min-height:0;height:100vh;background:var(--surface);border-left:1px solid var(--line);box-shadow:var(--sh-2)}
#dock.open{display:flex}
/* Opening, the column grows over .28s. The panel does not grow with it: it is laid out at the width it opens to from the
   first frame, standing at its final place at the window's right edge over the page the column is taking, so nothing in
   it reflows or moves while a person reaches for it (a panel riding the column's edge put a suggestion's centre outside
   the window 50ms after opening, measured 2026-09-16). Above the page's positioned marks while it covers them. */
body.ask-open #dock{justify-self:end;width:380px;position:relative;z-index:1}
body.ask-half #dock{width:min(50vw,520px)}
body.ask-full #dock{justify-self:stretch;width:auto}
/* Narrow, the rail is gone: the page and a 300px panel, or the panel alone. After the wide rules above, which would
   otherwise win and put the page in the rail's track and the panel in the page's. */
@media (max-width:860px){body.ask-open .shell{grid-template-columns:minmax(0,1fr) 300px}body.ask-half .shell,body.ask-full .shell{grid-template-columns:minmax(0,1fr)}
  body.ask-open #dock{width:300px}body.ask-half #dock,body.ask-full #dock{justify-self:stretch;width:auto}}
/* Below the width where the page can still have the 300px this design gives it, the dock takes the
   screen, as half and full already do. The width is not a guess: the panel is 300px at narrow widths
   and tests/test_console.py pins 600px to "300px 300px", page beside dock -- so the page keeps its
   300px down to 600px, and under that it cannot. At 400px it was being left 100px: a column of single
   words with the assistant on top of it. */
@media (max-width:599px){
  body.ask-open .shell{grid-template-columns:minmax(0,1fr)}
  body.ask-open .mainwrap{display:none}
  body.ask-open #dock{justify-self:stretch;width:auto}}
.dock-h{position:relative;display:flex;align-items:center;gap:8px;padding:8px 44px 0 10px;border-bottom:1px solid var(--line)}
.pmodes{display:flex;gap:2px}
.pmode{background:none;border:0;color:var(--muted);padding:8px 13px;font-size:13px;cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-1px}
.pmode:hover{color:var(--ink)}
.pmode.on{color:var(--gold-ink);border-bottom-color:var(--gold);font-weight:700}
.pclose{position:absolute;top:9px;right:10px;background:none;border:1px solid var(--line-2);color:var(--muted);border-radius:6px;padding:4px 6px;cursor:pointer;line-height:0}
.pclose:hover{color:var(--gold-ink);border-color:var(--gold)}
.dock-h2{display:flex;align-items:center;gap:8px;padding:6px 10px 6px 14px;border-bottom:1px solid var(--line)}
.dock-h2 .ctx{flex:1;min-width:0;color:var(--muted);font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.psize{display:flex;gap:3px;margin-left:auto}
.szbtn{background:none;border:1px solid var(--line-2);color:var(--muted);font-size:10.5px;letter-spacing:.02em;padding:3px 8px;border-radius:5px;cursor:pointer}
.szbtn:hover{color:var(--ink);border-color:var(--neutral)}
.szbtn.on{background:var(--gold);color:#fff;border-color:var(--gold);font-weight:700}
#askbody{flex:1;min-height:0;display:flex;flex-direction:column}
#askseeds{padding:10px 14px 0}
#askseeds .rl{font-size:10.5px;letter-spacing:.9px;text-transform:uppercase;color:var(--muted);margin-bottom:6px}
#askseeds summary.rl{cursor:pointer}#askseeds details:not([open]) summary.rl{margin-bottom:0}
#asklog{flex:1;overflow:auto;padding:10px 14px;display:flex;flex-direction:column;gap:10px}
#asklog .msg{padding:10px 12px;border-radius:var(--r-sm);font-size:13.5px;line-height:1.5}
#asklog .msg.me{background:var(--info-bg);color:var(--info-ink);align-self:flex-end;max-width:90%}
#asklog .msg.gb{background:var(--surface-2);border:1px solid var(--line)}
#asklog .msg.no{background:var(--warn-bg);color:var(--warn-ink);border-left:3px solid var(--warn)}
#asklog .msg.no.held{background:var(--crit-bg);color:var(--crit-ink);border-left-color:var(--crit)}
#asklog .prov{margin-top:6px;font-size:11.5px;color:var(--muted)}
.fups{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.fup{border:1px solid var(--line-2);background:var(--surface);border-radius:999px;padding:4px 10px;font-size:12px;cursor:pointer;color:var(--ink-2);text-align:left}
.fup:hover{background:var(--surface-2);color:var(--ink);border-color:var(--gold)}
.recs>span{display:flex;align-items:center;gap:6px;min-width:0;max-width:100%}
#askform{display:flex;gap:8px;padding:10px 14px 4px;border-top:1px solid var(--line)}
#askform .txt{flex:1}
.dock-note{color:var(--muted);font-size:10.5px;text-align:center;padding:2px 12px 8px}
.spin{display:inline-block;width:12px;height:12px;border:2px solid var(--line-2);border-top-color:var(--info);border-radius:50%;animation:spin 1s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}
/* the Guide side: the registry guide of the screen in view, as sections */
.pscroll{flex:1;min-height:0;overflow:auto;padding:8px 16px 16px}
.gkick{color:var(--gold-ink);font-size:10px;letter-spacing:.09em;font-weight:700;text-transform:uppercase}
.gh1{font-size:15px;line-height:1.3;margin:2px 0 10px;padding-bottom:8px;border-bottom:1px solid var(--line)}
.gsec{margin-bottom:14px}
.gsec h3{font-size:12px;color:var(--gold-ink);margin:0 0 4px}
/* The three portals card on the help screens (kit.portals): a portal, then its sections. */
.portals h3{font-size:14px;margin:14px 0 2px} .portals h3:first-child{margin-top:0}
.portals h4{font-size:12px;color:var(--muted);margin:10px 0 2px}
.gsec>div{font-size:12.5px;line-height:1.55;color:var(--ink-2)}
.gsec .alist{margin:0;padding-left:18px}
.gmore{font-size:12px;margin:6px 0 0}
.gmore a{display:inline-flex;align-items:center;gap:6px}
/* the launcher: the mark at rest, bottom-right, hidden while the panel is open */
.asklaunch{position:fixed;right:20px;bottom:20px;z-index:70;display:inline-flex;align-items:center;gap:9px;padding:9px 16px 9px 12px;
  border:1px solid var(--gold);border-radius:26px;cursor:pointer;background:linear-gradient(180deg,#1f2d4d,#10202c);color:#e6c874;
  box-shadow:0 6px 20px rgba(16,32,44,.32);transition:transform .14s ease,box-shadow .18s ease,border-color .18s}
.asklaunch:hover{transform:translateY(-2px);box-shadow:0 10px 26px rgba(16,32,44,.4);border-color:#e6c874}
.asklaunch:focus-visible{outline:2px solid #e6c874;outline-offset:3px}
.asklaunch .emblem{display:block;filter:drop-shadow(0 1px 2px rgba(0,0,0,.4))}
.asklaunch.compact{padding:10px;border-radius:50%}.asklaunch.compact .altxt{display:none}
.altxt{font-size:12px;font-weight:700;letter-spacing:.05em;text-transform:uppercase}
@media (max-width:520px){.altxt{display:none}.asklaunch{padding:10px;border-radius:50%}}

/* the record and the work around it (wave 5) */
ol.turns{list-style:none;margin:0;padding:0}
.turn{display:flex;flex-direction:column;gap:6px;margin-bottom:12px}
.turn .msg{padding:10px 12px;border-radius:var(--r-sm);font-size:13.5px;line-height:1.5}
.turn .msg.me{background:var(--info-bg);color:var(--info-ink);align-self:flex-end;max-width:80%}
.turn .msg.gb{background:var(--surface-2);border:1px solid var(--line)}
.turn .msg.no{background:var(--warn-bg);color:var(--warn-ink)}
.turn .prov{margin-top:6px;font-size:11.5px;color:var(--muted)}


/* The second factor's setup address as a code (wave 8): drawn by qr.js, sized here. */
#sf_qr svg{display:block;width:200px;height:200px;margin:6px 0 10px}

/* A text under change control, drawn whole (wave 6). */
pre.detail { white-space: pre-wrap; word-break: break-word; font-size: 12px; line-height: 1.45; background: var(--well, #f6f7f9); padding: 10px 12px; border-radius: 6px; margin: 0; }
/* The welcome tour (demo mode only, welcome.js): an overlay over the page, the reel at the width of its box. */
.welcome{position:fixed;inset:0;z-index:90;display:flex;align-items:center;justify-content:center;padding:16px;background:rgba(16,32,44,.55)}
.welcome-box{background:var(--surface);border-radius:var(--r);box-shadow:var(--sh-2);padding:18px 20px;width:min(880px,100%);max-height:100%;overflow:auto}
.welcome-box h2{font-size:20px;margin:0 0 6px}
.welcome-box video{display:block;width:100%;aspect-ratio:16/9;background:var(--ink);border-radius:var(--r-sm);margin-top:10px}
.welcome-chapters{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.welcome-chapters .btn[aria-current]{background:var(--gold-bg);border-color:var(--gold);color:var(--gold-ink)}
.welcome-dismiss{display:inline-flex;align-items:center;gap:6px;font-size:13px;color:var(--ink-2);margin-left:auto}

/* At 860px and narrower Half is Full (both take the screen), so its button goes (UX-15). Long identifiers and pills
   in the page wrap rather than run out of their cell at narrow widths (UX-12). */
@media (max-width:860px){.szbtn[data-z="half"]{display:none}}
#main code,#main .pill{overflow-wrap:break-word}
#main .pill{white-space:normal;max-width:100%}
/* The shared reel player (kit.player, Keith 10-07): the video, its bar, and full screen with the bar kept. The clock and
   the speed are drawn from data-clock and data-rate, a medium's own state, never page text (kit.js says why). */
.rp{position:relative;background:#000;border-radius:var(--r-sm);overflow:hidden;margin-top:10px}
.rp video{display:block;width:100%;aspect-ratio:16/9;background:#000;margin:0;border-radius:0}
.rp.reel video{max-height:360px}
.rp-bar{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:6px 8px;background:var(--surface);border-top:1px solid var(--line-2)}
.rp-b svg{width:16px;height:16px}
.rp-seek{flex:1 1 160px;min-width:120px}
.rp-vol{width:84px}
.rp-seek,.rp-vol{accent-color:var(--ink)}
.rp-clock::after{content:attr(data-clock);font-variant-numeric:tabular-nums;font-size:12.5px;color:var(--ink-2);white-space:nowrap}
.rp-rate{min-width:44px}
.rp-rate::after{content:attr(data-rate);font-size:12.5px}
.rp:fullscreen{display:flex;flex-direction:column;border-radius:0;margin:0}
.rp:fullscreen video{flex:1 1 auto;height:100%;max-height:none;aspect-ratio:auto}
