/* ============================================================
   BRAND TOKENS
   Biostream signal colours carried onto a light board. The dark
   field interface belongs on the device and in the operational
   product. A trusted research environment is used for hours at a
   time, on university and institutional desktops, often beside
   printed material, so the environment reads as paper rather than
   as a cockpit. The five brand colours below are unchanged in
   role and darkened only enough to hold contrast on white.
   Replace them with the exact brand guide values and every
   screen in this deck updates.
   ============================================================ */
:root{
  --brand-teal:#16686D;      /* primary action (POC design) */
  --brand-teal-lift:#0F5257; /* hover, focus, small text (POC design) */
  --control:#A87A22;         /* reserved: perimeter, suppression, airlock */
  --blocked:#AF432B;         /* reserved: a check that did not pass */
  --cleared:#2E7A59;         /* reserved: a check that passed */
  --paper:#10222A;           /* high emphasis text, the ink */

  /* The signal colours as text (BIO-126): the same hue, deep enough to
     read at 7.0 on every light ground. Fills and borders keep the originals. */
  --control-ink:#644815;
  --blocked-ink:#843321;
  --cleared-ink:#20543D;

  /* tints, used behind the signal colours */
  --teal-wash:#E2EFEF;
  --control-wash:#F8F0DE;
  --blocked-wash:#F9E8E3;
  --cleared-wash:#E5F0EA;

  /* environment chrome */
  --base:#EFF4F6;
  --surface:#FFFFFF;
  --surface-2:#F7FAFB;
  --surface-3:#EDF3F5;
  --hairline:#D4E0E4;
  --hairline-soft:#E6EDEF;
  --text:#33474F;
  --muted:#3C4C52; /* BIO-126: 7.0 or more on every light ground */
  --dim:#3C4C52;   /* BIO-126: as --muted; nothing lighter clears 7.0 */
  /* Sample text in an empty field (BIO-151): as light as the 7.0 floor allows
     on the two grounds an input sits on (7.39 on white, 7.05 on surface-2),
     and italic, so a sample reads as a sample rather than as typed text. */
  --placeholder:#49585E;

  --ui:"Inter",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  --label:"Barlow Condensed","Inter",sans-serif;
  --mono:"JetBrains Mono",ui-monospace,Menlo,monospace;
}

*{box-sizing:border-box;}
/* Not smooth. Smooth scrolling on the root swallows the scroll a browser does
   when it lands on a fragment: `/instructions/?open=ask#ask` opened the right
   section and stayed at the top of the page, so every deep link on the platform
   arrived looking like it had done nothing. Measured rather than guessed at:
   with smooth, a fresh load left scrollY at 0 with the target 485px down; with
   auto it landed on it. The animation was worth less than working deep links. */
html{scroll-behavior:auto;}
body{
  margin:0;background:var(--base);color:var(--text);
  font-family:var(--ui);font-size:15px;font-weight:400;line-height:1.62;
  -webkit-font-smoothing:antialiased;
}
h1,h2,h3,h4{margin:0;font-weight:500;color:var(--paper);letter-spacing:-.01em;}
p{margin:0 0 12px;}
button{font-family:inherit;cursor:pointer;}
:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}



.stage{max-width:1360px;margin:0 auto;padding:34px 26px 0;}
/* Sign in card fades and lifts away as the code is accepted... */
@keyframes appleave{from{opacity:1;transform:none;}to{opacity:0;transform:translateY(-14px);}}
.app.leaving{animation:appleave .5s ease both;pointer-events:none;}
/* ...then the environment fades and rises in on the first page after sign in. */
@keyframes appenter{from{opacity:0;transform:translateY(20px);}to{opacity:1;transform:none;}}
.stage.entering{animation:appenter .5s cubic-bezier(.33,.68,.28,1) both;}
@media (prefers-reduced-motion:reduce){.app.leaving,.stage.entering{animation:none;}}
.caption{
  display:flex;gap:16px;align-items:baseline;flex-wrap:wrap;
  margin:0 0 18px;padding-bottom:14px;border-bottom:1px solid var(--hairline-soft);
}
.caption h2{font-size:22px;}
.caption span{font-size:13px;color:var(--dim);max-width:62ch;}

/* ---------- app shell ---------- */
.app{
  border:1px solid var(--hairline);background:var(--surface);
  border-radius:12px;overflow:hidden;
  box-shadow:0 18px 44px rgba(16,34,42,.10);
}
.topbar{
  display:flex;align-items:center;gap:14px 18px;flex-wrap:wrap;
  padding:14px 20px;background:var(--surface-2);border-bottom:1px solid var(--hairline);
}
.wordmark{
  display:inline-block;width:101.5px;height:15.4px;
  background:url("../images/text-logo-dark.3dbc3100a7cf.png") left center/contain no-repeat;
  font-size:0;text-indent:-9999px;overflow:hidden;
}
.env{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.16em;
  font-size:12px;color:var(--muted);padding-left:18px;border-left:1px solid var(--hairline);
}
.who{margin-left:auto;display:flex;align-items:center;gap:12px;font-size:13px;color:var(--text);font-weight:500;}
.who form{margin:0;display:inline-flex;}
.whoemail{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:220px;}
.pill{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12px;
  border:1px solid var(--hairline);padding:3px 9px;border-radius:6px;color:var(--muted);
}
.pill.admin{border-color:var(--control);color:var(--control-ink);}
/* What an agreement does not record yet (BIO-191), in the amber the chart
   notes use, so it reads as something to do rather than an error. */
.pill.warn{border-color:var(--amber-line,#ecdca6);background:var(--amber-wash,#fbf3dd);color:var(--text);}

/* An agreement's governance (BIO-191): the six fields on the grant form when
   it makes the agreement, and each agreement's record on the owner's page. */
.govfields{border:1px solid var(--hairline);border-radius:8px;padding:10px 12px 4px;margin:0 0 12px;}
.govfields legend{font-weight:600;padding:0 4px;}
.govlist{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:8px 16px;margin:0;}
.govlist dt{font-size:12px;color:var(--muted);}
.govlist dd{margin:2px 0 0;overflow-wrap:anywhere;}
.govcomplete{margin-top:8px;border-top:1px solid var(--hairline);padding-top:4px;}

/* The notice band, used by the audit trail ("Append only") and the
   password screen ("Account"). The perimeter band that was on every
   screen was removed on 15 October 2026 (ISSUES.md BIO-151). */
.perimeter{
  display:flex;align-items:center;gap:14px;
  padding:9px 20px 9px 17px;
  background:linear-gradient(90deg,rgba(168,122,34,.11),rgba(168,122,34,0) 62%);
  border-bottom:1px solid var(--hairline);
  border-left:3px solid var(--control);
}

.perimeter .tag{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.2em;
  font-size:12px;color:var(--control-ink);font-weight:600;white-space:nowrap;
}
.perimeter .say{font-size:13px;color:var(--muted);}
.perimeter.gate{border-left-color:var(--blocked);background:linear-gradient(90deg,rgba(175,67,43,.11),rgba(175,67,43,0) 62%);}
.perimeter.gate .tag{color:var(--blocked-ink);}
.perimeter.pass{border-left-color:var(--cleared);background:linear-gradient(90deg,rgba(46,122,89,.11),rgba(46,122,89,0) 62%);}
.perimeter.pass .tag{color:var(--cleared-ink);}

.body{display:grid;grid-template-columns:214px 1fr;min-height:520px;}
/* A page with no navigation rail: the error pages, which cannot render the rail
   because building it reads the session and therefore the database.
   
   Without this the single .main lands in the 214px column the grid reserves for
   the rail, so the content sits in a fifth of the page with the rest empty. It
   looked correct below 1040px, where the grid already collapses to one column,
   and broken on every desktop (ISSUES.md BIO-36). */
.body-solo{grid-template-columns:1fr;}
.rail{background:var(--surface-2);border-right:1px solid var(--hairline);padding:16px 0;}
.rail-h{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.18em;
  font-size:12px;color:var(--dim);padding:0 18px;margin-bottom:10px;
}
.rail a{
  display:block;padding:10px 18px;color:var(--text);text-decoration:none;
  font-size:14px;font-weight:500;border-left:3px solid transparent;
}
.rail a:hover{color:var(--paper);background:rgba(16,34,42,.04);}
.rail a.on{color:var(--brand-teal-lift);border-left-color:var(--brand-teal);background:var(--teal-wash);font-weight:600;}
.rail hr{border:none;border-top:1px solid var(--hairline-soft);margin:16px 0;}

/* min-width:0 lets the main column be narrower than its widest content, so a
   wide table scrolls inside its own box rather than widening the page. As a
   grid item it otherwise grew to fit, which at phone width made the browser
   lay the whole page out wider than the screen (ISSUES.md BIO-75). */
.main{padding:26px 28px 34px;min-width:0;}
.eyebrow{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.1em;
  font-size:13px;font-weight:600;color:var(--brand-teal-lift);margin:0 0 8px;
}
.main h3{font-size:20px;margin-bottom:6px;}
.lede{font-size:14px;color:var(--muted);max-width:70ch;margin-bottom:22px;}

/* ---------- shared parts ----------
   Text floors (BIO-126): labels and axis text at least 12px, help lines,
   captions and legends at least 13px, in colours that clear 7.0. Guarded by
   apps/screens/tests_readable_text.py. */
.card{background:var(--surface-2);border:1px solid var(--hairline);border-radius:10px;padding:20px;}
/* Wraps a data table: no padding and clipped corners so the header band
   fills to the edges instead of leaving a strip of card colour above it. */
.tablecard{background:var(--surface);border:1px solid var(--hairline);border-radius:10px;overflow:hidden;}
/* Field dictionary revealed inside a dataset card. */
.dict{margin-top:18px;background:var(--surface);border:1px solid var(--hairline);border-radius:10px;overflow-x:auto;}
.dict[hidden]{display:none;}
.dict table{min-width:460px;}
/* Fields banded, generalised or pseudonymised at ingest. The treatment cell is
   tinted so the recoded rows stand out from the ones stored as recorded. */
.dict tr.recoded td:last-child{color:var(--control-ink);font-weight:500;}
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:18px;}
.grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;}
.grid4{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;}
.statcard{background:var(--surface);border:1px solid var(--hairline-soft);border-radius:9px;padding:13px 15px;}
.statcard p{margin:0 0 3px;font-size:12.5px;color:var(--muted);font-weight:500;}
.statcard .v{font-family:var(--mono);font-weight:600;font-size:19px;color:var(--paper);}
.statcard .sub{display:block;margin-top:4px;font-size:12px;line-height:1.35;color:var(--muted);}

.field{margin-bottom:16px;}
.field label{
  display:block;font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;
  font-size:12px;color:var(--muted);margin-bottom:6px;font-weight:600;}
.input,.ta,.sel{
  width:100%;background:var(--surface);border:1px solid var(--hairline);border-radius:8px;
  color:var(--paper);font-family:var(--ui);font-size:14px;padding:10px 12px;
}
.ta{min-height:96px;resize:vertical;line-height:1.55;}
/* A select is as wide as its widest option wants to be, and in WebKit that
   width reaches the page's scroll area even when the control itself has been
   laid out narrower: the Invitations group picker put 132 px of option text
   into a 249 px box and ran the whole page 79 px off the right at 1280, in
   WebKit and not in Chromium (17 November 2026). Hiding the select's own
   overflow stops it propagating. The control is not resized by this, because
   it was already drawing its options clipped to its box; what changes is only
   what the page counts as its own width. Measured in both engines. */
select.sel,select.input{overflow:hidden;}
input::placeholder,textarea::placeholder{color:var(--placeholder);font-style:italic;opacity:1;}

.btn{
  display:inline-block;text-decoration:none;
  background:var(--brand-teal);border:1px solid var(--brand-teal);color:#FFFFFF;
  font-weight:600;font-size:14px;padding:10px 18px;border-radius:8px;transition:.16s;
}
.btn:hover{background:var(--brand-teal-lift);border-color:var(--brand-teal-lift);}
.btn.ghost{background:transparent;color:var(--text);border-color:var(--hairline);font-weight:400;}
.btn.ghost:hover{border-color:var(--muted);color:var(--paper);}
.btn.danger{background:transparent;border-color:var(--blocked);color:var(--blocked-ink);font-weight:500;}
/* A small button (BIO-149): used in 29 places and defined nowhere until now,
   so each drew at the full 40px. 30px, the height of the controls beside it;
   min-height rather than height, so a label that wraps on a phone grows the
   button instead of spilling out of it. */
.btn.small{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;
  min-height:30px;padding:4px 12px;font-size:12.5px;line-height:1.2;}
.btn.danger:hover{background:var(--blocked-wash);}
.row{display:flex;gap:10px;align-items:center;flex-wrap:wrap;}

.hint{font-size:13px;color:var(--dim);}
.meta{font-family:var(--mono);font-size:12px;color:var(--dim);}

table{width:100%;border-collapse:collapse;font-size:13.5px;}
th{
  text-align:left;font-family:var(--label);text-transform:uppercase;letter-spacing:.12em;
  font-size:14px;font-weight:600;color:var(--text);background:var(--surface-3);
  padding:9px 12px;border-bottom:1.5px solid var(--hairline);
}
td{padding:10px 12px;border-bottom:1px solid var(--hairline-soft);color:var(--text);vertical-align:top;}
tr:last-child td{border-bottom:none;}
td.n{font-family:var(--mono);font-size:12.5px;}

/* SIGNATURE: withheld values read as a deliberate control */
.withheld{
  display:inline-flex;align-items:center;gap:7px;
  font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12px;
  color:var(--control-ink);border:1px dashed var(--control);border-radius:6px;padding:2px 8px;
  background:var(--control-wash);
}
.withheld::before{content:"";width:5px;height:5px;background:var(--control);transform:rotate(45deg);}

.state{
  display:inline-flex;align-items:center;gap:7px;font-family:var(--label);
  text-transform:uppercase;letter-spacing:.14em;font-size:12px;font-weight:500;
}
.state::before{content:"";width:7px;height:7px;border-radius:50%;}
.state.ok{
  color:var(--cleared-ink);background:var(--cleared-wash);
  border:1px solid rgba(46,122,89,.3);border-radius:6px;padding:4px 10px;
}
.state.ok::before{background:var(--cleared);}
.state.bad{color:var(--blocked-ink);}
.state.bad::before{background:var(--blocked);}
.state.wait{color:var(--control-ink);}
.state.wait::before{background:var(--control);}

.note{
  border-left:3px solid var(--control);background:var(--control-wash);
  border-radius:0 8px 8px 0;padding:11px 14px;
  font-size:13px;color:var(--text);margin:16px 0;
}
.note strong{color:var(--paper);font-weight:600;}
/* A positive note, for an outcome that is good news but still not a clearance,
   so passing the checks reads apart from a warning without reading as approval. */
.note.ok{border-left-color:var(--cleared);}

/* ---------- staged processing ----------
   The four steps shown while a run is built. States reuse the signal colours:
   a running step is teal and pulses, a done step is the cleared green, a failed
   step is the blocked red. Queued steps are dim so the eye lands on the one that
   is live. */
.proc-steps{list-style:none;margin:0;padding:0;}
/* The steps only when the work is slow (BIO-167): a working line first, the
   steps after the quiet time, in the place they will be, so nothing moves. */
/* The bar along the top while the next page is on its way (BIO-167). It
   creeps towards the right and never arrives: the next page replacing this
   one is what ends it. Without motion it is shown whole and still. */
.page-progress{position:fixed;top:0;left:0;height:3px;width:0;z-index:9999;pointer-events:none;
  background:var(--brand-teal-lift);opacity:0;}
.page-progress.is-on{opacity:1;animation:page-progress 8s cubic-bezier(.1,.6,.3,1) forwards;}
@keyframes page-progress{0%{width:0}10%{width:35%}100%{width:90%}}
@media (prefers-reduced-motion: reduce){.page-progress.is-on{animation:none;width:100%;}}
.proc{position:relative;}
.proc-working{display:none;margin:0;align-items:center;gap:8px;color:var(--text);
  position:absolute;top:20px;left:20px;}
.proc.is-quiet .proc-working{display:flex;}
.proc.is-quiet .proc-steps{visibility:hidden;}
.proc-step{
  display:flex;align-items:center;gap:12px;padding:12px 2px;
  border-bottom:1px solid var(--hairline-soft);
}
.proc-step:last-child{border-bottom:none;}
.proc-dot{width:9px;height:9px;border-radius:50%;background:var(--dim);flex:none;}
.proc-label{flex:1;font-family:var(--ui);font-size:14.5px;font-weight:500;color:var(--muted);}
.proc-tag{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;
  font-size:12.5px;font-weight:600;color:var(--dim);
}
.proc-step.is-running .proc-dot{background:var(--brand-teal);animation:procpulse 1s ease-in-out infinite;}
.proc-step.is-running .proc-label{color:var(--paper);}
.proc-step.is-running .proc-tag{color:var(--brand-teal-lift);}
.proc-step.is-done .proc-dot{background:var(--cleared);}
.proc-step.is-done .proc-label{color:var(--paper);}
.proc-step.is-done .proc-tag{color:var(--cleared-ink);}
.proc-step.is-failed .proc-dot{background:var(--blocked);}
.proc-step.is-failed .proc-label{color:var(--paper);}
.proc-step.is-failed .proc-tag{color:var(--blocked-ink);}
.proc-fail{margin-top:16px;}
.proc-note{border-left-color:var(--blocked);background:var(--blocked-wash);}
@keyframes procpulse{0%,100%{opacity:1;}50%{opacity:.35;}}
/* Reduced motion still shows every state change, it just does not pulse. */
@media (prefers-reduced-motion:reduce){
  .proc-step.is-running .proc-dot{animation:none;}
}

/* ---------- sign in ---------- */
.brand{
  background:var(--surface-2);border-bottom:1px solid var(--hairline-soft);
  padding:24px 30px 20px;
}
.brand .wordmark{display:block;width:184px;height:28px;margin-bottom:8px;}
.brand span{
  display:block;font-family:var(--label);text-transform:uppercase;letter-spacing:.2em;
  font-size:12.5px;color:var(--muted);
}
.signinbody{padding:30px 34px 36px;}
.codeboxes{display:flex;gap:9px;margin-bottom:8px;}
.codeboxes span{
  width:46px;height:56px;border:1px solid var(--hairline);border-radius:2px;background:var(--surface);
  display:flex;align-items:center;justify-content:center;
  font-family:var(--mono);font-size:22px;color:var(--paper);
}
.codeboxes span.empty{color:var(--muted);}
.codeboxes span.cursor{border-color:var(--brand-teal-lift);}

/* ---------- filter builder ---------- */
.frow{
  display:grid;grid-template-columns:1.2fr .8fr 1.2fr auto;gap:10px;align-items:center;
  padding:10px 0;border-bottom:1px solid var(--hairline-soft);
}
.frow .join{
  font-family:var(--label);text-transform:uppercase;letter-spacing:.16em;font-size:12px;color:var(--dim);
  grid-column:1 / -1;padding-top:4px;
}
/* The query's match, all of or any of (BIO-152), above the conditions. */
.frow.matchrow{display:flex;align-items:center;gap:10px;flex-wrap:wrap;}
.matchlabel{font-weight:600;color:var(--paper);}
.matchsel{width:auto;min-width:9rem;}
.matchsay{margin:0;}
.condproblem{margin:0 0 12px;}
.askcompare-problem{margin:8px 0 0;}
.condmatch{margin:10px 0 4px;}
.x{
  background:var(--surface);border:1.5px solid var(--hairline);border-radius:8px;
  color:var(--muted);font-size:16px;line-height:1;padding:9px 12px;cursor:pointer;
}
.x:hover{border-color:var(--blocked);color:var(--blocked-ink);}

/* Editing an existing analysis: banner above the cohort builder. */
.editnote{
  display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;
  margin:0 0 20px;padding:11px 14px;border-radius:8px;
  background:var(--teal-wash);border:1px solid var(--brand-teal);
  font-size:13px;color:var(--text);
}
.editnote strong{color:var(--paper);font-weight:600;}

/* Query mode tabs. Only Manual is built for the POC; the others are inert. */
.qtabs{display:flex;gap:6px;margin-bottom:-1px;position:relative;z-index:1;}
.qtab{
  display:inline-flex;align-items:center;font-family:var(--label);font-weight:600;
  text-transform:uppercase;letter-spacing:.14em;font-size:12.5px;padding:9px 16px;
  border:1px solid transparent;border-radius:8px 8px 0 0;
}
/* The four tabs are equal citizens: Manual runs the query, the other three show
   it as code. Nothing here is greyed out any more. */
.qtab{background:var(--surface);color:var(--muted);cursor:pointer;font-family:var(--label);
  text-decoration:none;border-color:var(--hairline-soft);}
.qtab:hover{color:var(--paper);}
.qtab.on{background:var(--surface-2);border-color:var(--hairline);border-bottom:none;color:var(--paper);}
/* Greyed, as the code workspace greys R (#137): not a link, no hover. */
.qtab.is-off,.qtab.is-off:hover,body.research .qtab.is-off:hover{cursor:default;opacity:.55;background:transparent;color:var(--muted);}

/* The help control, shown only while a code tab is open, since it is the code
   that needs explaining. */
.qhelp{
  display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;
  align-self:center;margin-left:6px;border:1px solid var(--hairline);border-radius:50%;
  background:var(--surface);color:var(--brand-teal-lift);font-size:12px;font-weight:600;
  text-decoration:none;
}
.qhelp:hover{border-color:var(--brand-teal);background:var(--teal-wash);}
.card.qcard{border-radius:0 10px 10px 10px;}

/* A rendered code panel. Read only text, never an editor: there is nothing to
   type into and nothing here executes. */
.codehost{margin-bottom:20px;}
.codepanel-top{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:10px;}
.codeblock{
  margin:0;padding:14px 16px;background:var(--surface-3);border:1px solid var(--hairline);
  border-radius:8px;overflow-x:auto;font-family:var(--mono);font-size:12.5px;line-height:1.65;
}
.codeblock code{display:block;white-space:pre;}

/* Code panel themes.
   Two palettes for the same markup. The light one belongs to the rest of the
   environment; the dark one is genuinely dark rather than a tinted light theme,
   because a near white panel in a dark room is the thing people turn a dark mode
   on to escape. Both were checked for contrast against their own background.
   Only the panel changes, never the page around it. */
.codeblock.theme-light{
  background:var(--surface);border:1px solid var(--hairline);color:#243b44;
}
/* Plain text is coloured explicitly in both themes rather than inherited. It
   used to inherit, and .codeall sets the ink for an unthemed panel, so in the
   dark theme everything that was not a keyword, a string or a comment came out
   near black on near black. Setting it per theme means a rule elsewhere cannot
   quietly take it back. */
.codeblock.theme-light .tok-plain,
.codeblock.theme-light code{color:#243b44;}
.codeblock.theme-dark .tok-plain,
.codeblock.theme-dark code{color:#d6e3e8;}
.codeblock.theme-light .tok-keyword{color:#6E448F;font-weight:600;}
.codeblock.theme-light .tok-string{color:#1B633A;}
.codeblock.theme-light .tok-number{color:#7E4B0E;}
.codeblock.theme-light .tok-comment{color:#4B5860;font-style:italic;}
.codeblock.theme-light .tok-field{color:#0f5257;font-weight:600;}
.codeblock.theme-light .tok-function{color:#1f4f9c;}

.codeblock.theme-dark{
  background:#0e1b21;border:1px solid #1e343e;color:#d6e3e8;
}
.codeblock.theme-dark .tok-keyword{color:#c8a2f0;font-weight:600;}
.codeblock.theme-dark .tok-string{color:#8fd6a4;}
.codeblock.theme-dark .tok-number{color:#f0be7a;}
.codeblock.theme-dark .tok-comment{color:#99ACB5;font-style:italic;}
.codeblock.theme-dark .tok-field{color:#5fd4d9;font-weight:600;}
.codeblock.theme-dark .tok-function{color:#8ab6f0;}

/* ---------- the code window (12 November 2026) ----------
   Every window that shows code is the same editor (static/js/code-editor.js),
   Monaco from our own files, with a slim bar of tools across the top. Until
   the editor arrives, or without scripts, the window is exactly what the
   server drew: the highlighted panel or the text area above. The editor's
   own colours are in that script, from the same palette as the panel themes
   here, each checked at 7:1 against its ground. */
.codewin [hidden]{display:none !important;}
/* The panel's Copy code, shown only where the browser can copy, and the
   controls the editor's bar takes over: a button's own display would
   otherwise outweigh the hidden attribute. */
.codepanel-top .codecopy[hidden],.cw-bar .btn[hidden]{display:none;}
.codewin.is-editor{border:1px solid var(--hairline);border-radius:8px;overflow:hidden;background:#FFFFFF;}
.codewin.is-editor.theme-dark{border-color:#1E343E;background:#0E1B21;}
.codewin-bar{display:flex;align-items:center;gap:2px;flex-wrap:wrap;min-height:38px;padding:3px 6px;
  border-bottom:1px solid var(--hairline);background:var(--surface-2);}
.codewin.theme-dark .codewin-bar{background:#14262E;border-bottom-color:#1E343E;}
.codewin-tool{display:inline-flex;align-items:center;justify-content:center;gap:4px;min-width:32px;height:30px;
  margin:0;padding:0 7px;border:1px solid transparent;border-radius:6px;background:none;color:var(--muted);
  font:inherit;font-size:13px;line-height:1;cursor:pointer;}
.codewin-tool:hover{background:var(--teal-wash);color:var(--paper);}
.codewin-tool[aria-pressed="true"]{background:var(--teal-wash);border-color:var(--hairline);color:var(--brand-teal-lift);}
.codewin-tool:disabled{opacity:.55;cursor:default;}
.codewin-tool-text{font-weight:600;}
.codewin.theme-dark .codewin-tool{color:#C4D2D8;}
.codewin.theme-dark .codewin-tool:hover,
.codewin.theme-dark .codewin-tool[aria-pressed="true"]{background:#1E343E;border-color:#2A4652;color:#FFFFFF;}
.codewin-sep{width:1px;height:18px;margin:0 4px;background:var(--hairline);}
.codewin.theme-dark .codewin-sep{background:#2A4652;}
.codewin-said{margin-left:auto;padding:0 8px;font-size:13px;color:var(--muted);}
.codewin.theme-dark .codewin-said{color:#C4D2D8;}
.codewin-body{width:100%;min-height:40px;}
/* Full screen: the window over the page, the page itself not scrolled. */
.codewin.is-full{position:fixed;inset:12px;z-index:10001;display:flex;flex-direction:column;
  box-shadow:0 20px 60px rgba(16,34,42,.35);}
.codewin.is-full .codewin-body{flex:1;min-height:0;}
html.codewin-open,html.codewin-open body{overflow:hidden;}
/* A dictionary field, coloured for being a field as the server's panel does. */
.codewin .codewin-field{font-weight:600;}
.codewin.theme-light .monaco-editor .codewin-field{color:#0F5257;}
.codewin.theme-dark .monaco-editor .codewin-field{color:#5FD4D9;}
/* The line a refusal points at. */
.codewin .codewin-bad-line{background:rgba(175,67,43,.10);}
.codewin .codewin-bad-gutter{background:var(--blocked);width:3px !important;margin-left:3px;}
/* Test's answer, under Check and run. */
.codetest{margin-top:10px;padding:10px 12px;border-radius:8px;border:1px solid var(--hairline);background:var(--surface);}
.codetest p{margin:0 0 6px;}
.codetest .codetest-note{margin:6px 0 0;}
.codetest-ok{border-color:var(--cleared);background:var(--cleared-wash);color:var(--cleared-ink);}
.codetest-no{border-color:var(--blocked);background:var(--blocked-wash);color:var(--blocked-ink);}
.codetest-summary{margin:0 0 6px;padding-left:18px;}
/* Save as and Open, on any code window that can keep scripts. */
.codedialog{border:1px solid var(--hairline);border-radius:10px;padding:18px 20px;max-width:460px;width:calc(100% - 32px);
  color:var(--text);background:var(--surface);box-shadow:0 20px 60px rgba(16,34,42,.3);}
.codedialog::backdrop{background:rgba(16,34,42,.35);}
.codedialog h4{margin:0 0 12px;}
.codedialog .field{margin-bottom:12px;}
.codedialog-list{list-style:none;margin:0 0 12px;padding:0;max-height:50vh;overflow:auto;border:1px solid var(--hairline-soft);border-radius:6px;}
.codedialog-list li{border-bottom:1px solid var(--hairline-soft);}
.codedialog-list li:last-child{border-bottom:0;}
.codedialog-list button{display:block;width:100%;text-align:left;padding:8px 10px;border:0;background:none;font:inherit;
  color:var(--paper);cursor:pointer;}
.codedialog-list button:hover{background:var(--teal-wash);}
.codedialog-path{display:block;font-size:12px;color:var(--muted);}
.codedialog-said{min-height:1.4em;margin:0 0 10px;font-size:14px;color:var(--blocked-ink);}

/* The theme control sits with the copy control rather than above the code, so
   the panel's top row reads as one set of things you can do to the panel. */
.paneltheme{display:inline-flex;margin:0;}

/* A label that belongs to a screen reader rather than to the layout. The code
   editor's textarea has one: the panel heading names the language above it, but
   a control with no label of its own is a control nobody navigating by keyboard
   can identify. */
.visually-hidden{
  position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;
  clip:rect(0 0 0 0);white-space:nowrap;border:0;
}

/* The code editor. Same box as the read only panel so switching between them
   does not move the page, and monospaced so the code a researcher edits lines up
   the way the code they were shown did. Resizable vertically only: sideways
   would break out of the panel. */
/* The editor: a gutter of line numbers and the textarea, sharing one box that
   carries the theme. The gutter is separate elements rather than text inside the
   field, so the numbers are never part of the value, never posted and never
   copied with the code.

   The textarea does not wrap. One logical line is one visual row, so a number
   cannot drift from the line it belongs to, which is the way a gutter usually
   goes wrong. */
/* Two boxes, not one. The outer box is the one scroller; the inner row holds
   the gutter and the textarea and is as tall as its content, so the two stretch
   only to each other and are always the same height.

   This used to be one flex box with the height cap on it, and stretch sized
   the textarea to the cap rather than to its rows: the code was cut off at the
   cap with half a line showing, while the gutter's numbers spilled out of their
   own box and were the only thing the box scrolled (BIO-115). A cap belongs on
   a box whose children are sized by their content, never on the flex row that
   stretches them. */
.editorwrap{display:block;padding:0;overflow-x:hidden;overflow-y:auto;
  /* The wheel carries on to the page at either end of the inner scroll. */
  overscroll-behavior:auto;}
/* The cap only once the script is there to keep the rows right; without it the
   editor is as tall as the query and the page is the only scroller. */
.editorwrap.is-capped{max-height:70vh;}
.editorwrap:focus-within{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}
.editorrows{display:flex;align-items:stretch;
  /* Twelve lines at least: 12 x 1.65 x 12.5px, plus the 28px of padding. */
  min-height:calc(12 * 1.65 * 12.5px + 28px);}
.editorgutter{
  flex:none;padding:14px 10px 14px 14px;text-align:right;
  /* Not selectable, so a drag across the code does not pick the numbers up,
     and not copied with it. */
  user-select:none;-webkit-user-select:none;
  /* No scrollbar of its own. It is as tall as the row it shares with the
     textarea and moves only when the editor box scrolls, which is the whole
     reason it cannot drift. */
  overflow:hidden;
  /* Every metric that decides where a line sits is shared with the textarea.
     If these two ever disagree the numbers slide by a fraction of a line per
     row, which looks fine at the top of a short query and is a line out by the
     bottom of a long one. */
  font-family:var(--mono);font-size:12.5px;line-height:1.65;
  border-right:1px solid var(--hairline);
}
.codeblock.theme-dark .editorgutter{border-right-color:#1e343e;color:#9BAAB2;}
.codeblock.theme-light .editorgutter{color:var(--muted);}
.editorgutter .editorline{display:block;}
/* The line a refusal points at, so the message and the code line up without
   anybody counting. */
.editorline-bad{
  font-weight:700;color:var(--blocked-ink);position:relative;
}
.editorline-bad::after{
  content:"";position:absolute;right:-11px;top:0;bottom:0;width:2px;
  background:var(--blocked);
}
.editorarea{
  flex:1;border:0;background:transparent;color:inherit;padding:14px 16px;
  /* The ring goes round the whole editor instead, gutter and code together. */
  outline:none;
  font-family:var(--mono);font-size:12.5px;line-height:1.65;white-space:pre;
  /* Sideways only. The rows attribute holds every line, so there is nothing to
     scroll vertically and no second scroll position for the gutter to fall out
     of step with. Not resizable for the same reason: dragging the handle would
     create the inner scroller this design exists to avoid. */
  overflow-x:auto;overflow-y:hidden;resize:none;
}

textarea.codeblock{
  display:block;width:100%;box-sizing:border-box;resize:vertical;min-height:220px;
  font-family:var(--mono);font-size:12.5px;line-height:1.65;
}
/* The comment block reads as an aside, and the copy control leaves it behind. */
/* One block: the comment header travels with the code when it is copied,
   because reaching a researcher who has taken the query elsewhere is the whole
   point of that comment. */
/* The base ink for a panel with no theme on it. A themed panel sets its own,
   below, on the tokens rather than on the element, so nothing inherits a colour
   from outside the panel. */
.codeall{color:var(--paper);}
.codepanel-top{align-items:flex-start;}

/* Controls for features not built yet. Rendered as a span or an href-less link,
   so neither takes keyboard focus nor does anything when clicked; hovering shows
   why. Same tooltip as the query tabs above. */
.soon{cursor:not-allowed;position:relative;opacity:.55;}
.soon::after{
  content:attr(data-soon);position:absolute;bottom:calc(100% + 8px);left:50%;transform:translateX(-50%);
  white-space:nowrap;background:var(--paper);color:#FFFFFF;font-family:var(--ui);
  text-transform:none;letter-spacing:0;font-weight:500;font-size:12px;padding:6px 10px;border-radius:6px;
  box-shadow:0 8px 18px rgba(16,34,42,.25);opacity:0;pointer-events:none;transition:opacity .12s;
}
.soon:hover::after{opacity:1;}
.rail a.soon{opacity:1;color:var(--dim);}
.rail a.soon:hover{background:transparent;color:var(--dim);}

.count{
  display:flex;align-items:baseline;gap:14px;padding:18px 20px;
  background:var(--surface-3);border:1px solid var(--hairline);border-radius:10px;
}
.count b{font-family:var(--mono);font-size:34px;font-weight:500;color:var(--paper);letter-spacing:-.02em;}
.count span{font-family:var(--label);text-transform:uppercase;letter-spacing:.16em;font-size:12px;color:var(--muted);}

/* ---------- checks ---------- */
.check{
  display:grid;grid-template-columns:26px 1fr auto;gap:14px;align-items:start;
  padding:14px 0;border-bottom:1px solid var(--hairline-soft);
}
.check:last-child{border-bottom:none;}
.check .idx{font-family:var(--mono);font-size:12px;color:var(--dim);padding-top:2px;}
.check h4{font-size:14.5px;margin-bottom:3px;}
.check p{font-size:13px;color:var(--muted);margin:0;}
.finding{
  font-family:var(--mono);font-size:12px;color:var(--blocked-ink);
  background:var(--blocked-wash);border:1px solid rgba(175,67,43,.35);
  border-radius:2px;padding:6px 10px;margin-top:8px;display:inline-block;
}

.banner{
  display:flex;gap:16px;align-items:flex-start;padding:16px 18px;border-radius:3px;
  border:1px solid rgba(175,67,43,.45);background:var(--blocked-wash);margin-bottom:22px;
}
.banner .bar{width:3px;align-self:stretch;background:var(--blocked);}
.banner h4{color:var(--blocked-ink);font-size:15px;margin-bottom:4px;}
.banner p{font-size:13.5px;color:var(--text);margin:0;}

/* ---------- queue ---------- */
.queue{display:grid;grid-template-columns:1.15fr 1fr;gap:18px;}
.qitem{
  padding:13px 14px;border:1px solid var(--hairline);border-radius:3px;
  background:var(--surface-2);margin-bottom:10px;
}
.qitem.sel{border-color:var(--brand-teal);background:var(--surface-3);}
.qitem .top{display:flex;justify-content:space-between;align-items:baseline;gap:10px;margin-bottom:5px;}
.qitem h4{font-size:14.5px;}
.qitem .sub{font-size:12.5px;color:var(--muted);}

.quote{
  border-left:2px solid var(--hairline);padding:2px 0 2px 14px;
  font-size:13.5px;color:var(--text);font-style:italic;
}

/* ---------- SIGNATURE: audit thread ---------- */
.thread{position:relative;padding-left:132px;}
.thread::before{
  content:"";position:absolute;left:118px;top:6px;bottom:6px;width:1px;background:var(--hairline);
}
.ev{position:relative;padding:0 0 20px;}
.ev .t{
  position:absolute;left:-132px;width:104px;text-align:right;
  font-family:var(--mono);font-size:12px;color:var(--dim);line-height:1.5;padding-top:1px;
}
.ev::before{
  content:"";position:absolute;left:-18px;top:6px;width:7px;height:7px;
  background:var(--surface);border:1px solid var(--muted);border-radius:50%;
}
.ev.amber::before{border-color:var(--control);background:var(--control);}
.ev.red::before{border-color:var(--blocked);background:var(--blocked);}
.ev.green::before{border-color:var(--cleared);background:var(--cleared);}
.ev h4{font-size:14px;margin-bottom:2px;}
.ev p{font-size:13px;color:var(--muted);margin:0;}
.ev .who2{font-family:var(--mono);font-size:12px;color:var(--dim);margin-top:4px;}

/* ---------- screens ---------- */


@keyframes in{from{opacity:0;transform:translateY(8px);}to{opacity:1;transform:none;}}
@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto;}
}

footer{
  max-width:1360px;margin:0 auto;padding:20px 26px 44px;
  font-size:12.5px;color:var(--dim);
}

@media (max-width:1040px){
  /* The rail stacks above the content but keeps its vertical, full-width menu
     with the Project and Admin groups intact, matching the mobile design
     rather than collapsing into a horizontal strip. */
  .body{grid-template-columns:1fr;}
  .rail{border-right:none;border-bottom:1px solid var(--hairline);}
  .signin,.grid2,.queue,.charts{grid-template-columns:1fr;}
  .grid3{grid-template-columns:1fr;}
  .grid4{grid-template-columns:repeat(2,1fr);}
}
@media (max-width:620px){
  .stage{padding:22px 14px 60px;}
  .main{padding:20px 16px 26px;}
  .frow{grid-template-columns:1fr;}
  .thread{padding-left:0;}
  .thread::before{display:none;}
  .ev .t{position:static;width:auto;text-align:left;display:block;margin-bottom:2px;}
  .ev::before{display:none;}
  .ev{border-left:2px solid var(--hairline);padding-left:14px;}
}

/* ------------------------------------------------------------
   Added for the Django build. Not part of the original deck.
   ------------------------------------------------------------ */
.staticmark{
  max-width:1360px;margin:0 auto;padding:10px 26px;
  font-family:var(--label);text-transform:uppercase;letter-spacing:.16em;
  font-size:12px;color:var(--control-ink);background:var(--control-wash);
  border-bottom:1px solid rgba(168,122,34,.35);
}
.errors{
  border:1px solid rgba(175,67,43,.45);background:var(--blocked-wash);
  border-radius:2px;padding:10px 14px;margin-bottom:16px;
  font-size:13.5px;color:var(--blocked-ink);
}
.errors ul{margin:0;padding-left:18px;}
.codeinput{
  width:100%;font-family:var(--mono);font-size:26px;letter-spacing:.42em;
  text-align:center;padding:14px 12px;background:var(--surface);
  border:1px solid var(--hairline);border-radius:2px;color:var(--paper);
}
.codeinput:focus{border-color:var(--brand-teal-lift);}
.linkbtn{
  background:none;border:none;padding:0;color:var(--brand-teal-lift);
  font-size:13px;text-decoration:underline;cursor:pointer;
}
.linkbtn:disabled{color:var(--dim);text-decoration:none;cursor:not-allowed;}
/* Deliberately understated so it sits quietly under the sign-in form. */
.forgotlink{
  appearance:none;-webkit-appearance:none;
  background:none;border:none;padding:0;margin-top:16px;
  color:var(--dim);font-size:13px;text-decoration:underline;cursor:pointer;
}
.forgotlink:hover{color:var(--muted);}
.signout{
  background:none;border:1px solid var(--hairline);border-radius:6px;
  padding:5px 11px;color:var(--text);font-size:13px;font-weight:500;
  text-decoration:none;cursor:pointer;
}
.signout:hover{border-color:var(--muted);color:var(--paper);}
/* POC scope note in the project rail. */
.rail .scope{margin:18px 18px 0;padding-top:16px;border-top:1px solid var(--hairline-soft);}
.rail .scope .rail-h{padding:0;margin:0 0 6px;}
.rail .scope-note{margin:0;font-size:12.5px;color:var(--muted);line-height:1.5;}
/* Build version, sat faint at the foot of the rail. */
.rail-version{margin:18px 0 0;padding:0 18px;font-family:var(--mono);font-size:12px;color:var(--dim);}

/* ---------- results: saved list, back link and charts ---------- */
.backlink{
  display:inline-flex;align-items:center;gap:6px;background:none;border:none;
  color:var(--muted);font-size:13.5px;text-decoration:none;margin-bottom:14px;
}
.backlink:hover{color:var(--paper);}
.runitem{
  display:block;background:var(--surface);border:1px solid var(--hairline);border-radius:10px;
  padding:16px 18px;margin-bottom:12px;text-decoration:none;transition:border-color .14s;
}
.runitem:hover{border-color:var(--brand-teal);}
/* Since the row carries tags (BIO-103) it is a box with a link in it rather
   than one link: the link covers everything above the tags. */
.runitem-open{display:block;color:inherit;text-decoration:none;}
.runitem-open:focus-visible{outline-offset:4px;}
.runitem .tagbar{margin-top:10px;}
.runitem-top{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:5px;}
.runitem-top h4{font-size:16px;color:var(--paper);}
.runitem-sub{margin:0 0 6px;font-size:13px;color:var(--muted);}
.runitem-n{font-family:var(--mono);font-size:12.5px;color:var(--brand-teal-lift);}

/* Narrowing the saved results. The filter sits on the subtitle's row, aligned
   right, so it reads as part of the content rather than as a toolbar laid across
   the top of the screen. It wraps under the subtitle when there is no room. */
.savedbar{
  display:flex;justify-content:space-between;align-items:flex-end;gap:18px;
  flex-wrap:wrap;margin-bottom:18px;
}
.savedbar .lede{max-width:40ch;}
/* Pushed right whether it shares the subtitle's row or wraps under it, so it
   stays aligned to the content edge instead of drifting left when it wraps. */
.savedfilter{display:flex;align-items:flex-end;gap:8px;flex-wrap:wrap;margin-left:auto;}
.savedfilter .field{margin:0;}
.savedfilter label{
  display:block;font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;
  font-size:12px;color:var(--muted);margin-bottom:4px;
}
.savedfilter .input{height:34px;padding:0 9px;font-size:13px;}
.savedfilter input[type="search"]{width:170px;}
.savedfilter input[type="date"]{width:132px;}
.savedfilter .btn{height:34px;padding:0 13px;}
.savedcount{margin:-6px 0 14px;}

.charts{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-bottom:18px;}
.chartcard{position:relative;background:var(--surface);border:1px solid var(--hairline);border-radius:12px;padding:20px 22px;min-width:0;}
/* The results table (Sprint Enchilada E09): the first card in the grid.
   Wider spans both columns of the grid and moves the cards after it; at 1040px
   and below the grid is one column already, so there is nothing to widen and
   the control is not offered. Every background here is light enough to keep
   the research text colour at 7.0 or better (tests_result_table measures it).
   The shading is a second signal only: every cell prints its number. */
.rtable-wide,.rtable-open{grid-column:1 / -1;}
@media (max-width:1040px){ .rtable [data-rtable-form="size"]{display:none;} }
.rtable-sizes{display:flex;gap:6px;flex:none;}
.rtable-controls{display:flex;flex-direction:column;gap:8px;margin:8px 0 10px;}
.rtable-fields,.rtable-tools{display:flex;flex-wrap:wrap;gap:8px 12px;align-items:center;}
.rtable-field{display:inline-flex;align-items:center;gap:4px;border:1px solid var(--hairline);border-radius:999px;
  padding:2px 4px 2px 10px;font-size:12.5px;color:var(--text);background:var(--surface);margin:0;}
.rtable-x{border:0;background:none;color:var(--text);font-size:15px;line-height:1;cursor:pointer;padding:0 5px;}
.rtable-add,.rtable-inline{display:flex;flex-wrap:wrap;gap:6px;align-items:center;font-size:12.5px;color:var(--text);margin:0;}
.rtable-warn,.rtable-cap{margin:0;}
/* The Apply buttons are for JavaScript off; `.btn` sets display, so hidden needs saying. */
.rtable [data-rtable-apply][hidden],.rtable-dialog [data-rtable-apply][hidden],
.chart-rtable [data-rtable-apply][hidden]{display:none;}
/* A chart drawn as a table: the results table's controls and grid, under the
   chart's own header. */
.chart-rtable .rtable-tools{margin:4px 0 10px;}
/* One height for the table's controls (BIO-148): the selects and the search
   were the browser's own, about 18px. The buttons beside them are `.btn.small`,
   30px since BIO-149. */
.rtable-controls select,.rtable-controls input[type=search],.rtable-tools select,.rtable-tools input[type=search]{
  height:30px;box-sizing:border-box;padding:0 8px;border:1px solid var(--hairline);border-radius:6px;
  background:var(--surface);color:var(--paper);font:inherit;font-size:12.5px;}
.rtable-scroll{overflow:auto;max-height:420px;border:1px solid var(--hairline);border-radius:8px;background:var(--surface);}
.rtable-wide .rtable-scroll,.rtable-open .rtable-scroll{max-height:560px;}
.rtable-grid{border-collapse:separate;border-spacing:0;min-width:100%;font-size:12.5px;color:var(--text);}
.rtable-grid th,.rtable-grid td{border-right:1px solid var(--hairline);border-bottom:1px solid var(--hairline);padding:5px 9px;white-space:nowrap;}
.rtable-grid thead{position:sticky;top:0;z-index:3;}
.rtable-grid thead th,.rtable-grid thead td{background:#EEF4F5;font-weight:600;text-align:left;}
.rtable-grid tr > :first-child{position:sticky;left:0;z-index:1;background:#F7FAFB;}
.rtable-grid thead tr > :first-child{z-index:4;background:#EEF4F5;}
.rtable-grid tbody th,.rtable-grid tfoot th{font-weight:500;text-align:left;}
.rt-across{text-align:center;}
.rt-num{text-align:right;font-variant-numeric:tabular-nums;}
.rtable-grid thead .rt-num{text-align:right;}
.rt-share{display:block;font-size:12px;}
.rt-partial{font-size:12px;font-style:italic;}
.rt-total{font-weight:600;background:#F4F8F9;}
/* The row total column stays in view while the counts scroll sideways
   (14 November 2026), as the label column already does on the left: on a
   card at laptop width a wide cross tabulation cut it off at the edge, and
   with the scrollbar hidden nothing said the column was there. The last
   cell of each row only, so a column total in the footer scrolls with its
   column; nothing moves where the table already fits. */
.rtable-grid tr > .rt-total:last-child,.rtable-grid tr > .rt-corner:last-child{position:sticky;right:0;z-index:1;
  box-shadow:inset 1px 0 0 var(--hairline);}
.rtable-grid tbody tr > .rt-total:last-child,.rtable-grid tfoot tr > .rt-total:last-child{background:#F4F8F9;}
.rtable-grid thead tr > .rt-total:last-child,.rtable-grid thead tr > .rt-corner:last-child{z-index:4;background:#EEF4F5;}
.rt-b1{background:#F5FAFA;}
.rt-b2{background:#EBF5F6;}
.rt-b3{background:#E0EFF1;}
.rt-b4{background:#D3E8EB;}
.rt-b5{background:#C6E2E5;}
.rt-bw{font-style:italic;background:repeating-linear-gradient(135deg,#FFFFFF 0 5px,#EAF0F2 5px 10px);}
.rt-sortbtn{font:inherit;color:inherit;background:none;border:0;padding:0;cursor:pointer;text-align:inherit;}
.rt-sortbtn:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}
th[aria-sort="ascending"] .rt-sortbtn::after{content:" \25B2";font-size:9px;}
th[aria-sort="descending"] .rt-sortbtn::after{content:" \25BC";font-size:9px;}
.rtable-status{min-height:1em;margin:4px 0 0;}
.rtable-foot{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:8px;}
.rtable-reset{margin:0 0 0 auto;}
.rtable-dialog{border:0;border-radius:12px;padding:18px 22px;width:min(1100px,96vw);max-height:92vh;
  background:var(--surface);color:var(--text);}
.rtable-dialog::backdrop{background:rgba(16,34,42,.55);}
.rtable-dialog-head{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:8px;}
.rtable-dialog-head h2{margin:0;font-size:18px;color:var(--text);}
.rtable-dialog .rtable-scroll{max-height:calc(92vh - 260px);}
/* Placeholder for a later "open this chart in detail" view. Deliberately
   disabled and greyed for the POC, kept only as a visible reminder. */
.chart-soon{position:absolute;top:16px;right:16px;display:inline-flex;align-items:center;
  background:var(--surface-3);border:1px solid var(--hairline-soft);color:var(--muted);
  font-family:var(--label);font-size:12px;font-weight:600;text-transform:uppercase;letter-spacing:.14em;
  padding:6px 12px;border-radius:7px;cursor:not-allowed;}
.chart-soon::after{
  content:attr(data-soon);position:absolute;bottom:calc(100% + 8px);left:50%;transform:translateX(-50%);
  white-space:nowrap;background:var(--paper);color:#FFFFFF;font-family:var(--ui);
  text-transform:none;letter-spacing:0;font-weight:500;font-size:12px;padding:6px 10px;border-radius:6px;
  box-shadow:0 8px 18px rgba(16,34,42,.25);opacity:0;pointer-events:none;transition:opacity .12s;}
.chart-soon:hover::after{opacity:1;}
.chart-k{font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12.5px;font-weight:600;color:var(--muted);margin:0 0 3px;}
.chartcard h4{font-size:16px;color:var(--paper);margin-bottom:4px;}
.chart-sub{margin:0 0 16px;font-size:13px;color:var(--muted);}
.chart-legend{display:flex;gap:16px;margin-top:14px;font-size:13px;color:var(--text);}
.chart-legend span{display:inline-flex;align-items:center;gap:6px;}
.cdot{width:11px;height:11px;border-radius:4px;display:inline-block;}
.cdot.teal{background:var(--brand-teal);}
.cdot.red{background:var(--blocked);}
/* chart 1: stacked outcome bars */
.ebar{margin-bottom:13px;}
.ebar-top{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:5px;font-size:13px;color:var(--text);}
.ebar-track{display:flex;height:20px;border-radius:6px;overflow:hidden;background:var(--teal-wash);}
.ebar-stab{background:var(--brand-teal);color:#FFFFFF;font-size:12px;font-weight:600;display:flex;align-items:center;padding-left:8px;white-space:nowrap;}
.ebar-det{background:var(--blocked);}
/* chart 3: mechanism bars */
.mbar{display:grid;grid-template-columns:112px 1fr 64px;gap:10px;align-items:center;margin-bottom:11px;}
.mbar-label{font-size:13px;color:var(--text);}
.mbar-track{height:18px;background:var(--teal-wash);border-radius:6px;overflow:hidden;}
.mbar-fill{height:100%;background:#3E8A8E;border-radius:6px;}
.mbar-fill.first{background:var(--brand-teal);}
.mbar-n{font-family:var(--mono);font-size:12.5px;color:var(--paper);text-align:right;}
.mbar-n .mbar-share{display:block;font-style:normal;font-size:12px;color:var(--muted);}

/* A value axis under a horizontal bar style chart. Faint gridlines are drawn as
   a repeating background on each track, self aligning to the axis because a
   track runs zero to the ceiling, so no pixel width has to be known here. */
.plot-h{position:relative;}
.gridded{
  background-image:repeating-linear-gradient(90deg,
    var(--hairline) 0, var(--hairline) 1px, transparent 1px, transparent var(--tick));
  background-position:0 0;
}
.va-h{display:grid;grid-template-columns:112px 1fr 64px;gap:10px;margin-top:6px;}
.va-unit{font-family:var(--label);text-transform:uppercase;letter-spacing:.1em;font-size:12px;
  color:var(--muted);align-self:center;}
.va-track{position:relative;height:16px;}
.va-t{position:absolute;top:0;transform:translateX(-50%);font-family:var(--mono);font-size:12px;
  color:var(--muted);white-space:nowrap;}
.va-track .va-t:first-child{transform:none;}
.va-track .va-t:last-child{transform:translateX(-100%);}
.axis-caption{margin:10px 0 0;font-size:13px;color:var(--muted);}
.axis-unit-line{margin:8px 0 0;font-family:var(--label);text-transform:uppercase;letter-spacing:.1em;
  font-size:13px;color:var(--muted);}
/* chart 4: quartile bars */
.qbars{display:flex;align-items:flex-end;gap:16px;height:170px;padding:0 4px;}
.qbar{flex:1;display:flex;flex-direction:column;align-items:center;gap:8px;height:100%;justify-content:flex-end;}
.qbar-n{font-family:var(--mono);font-size:12.5px;color:var(--paper);font-weight:500;}
.qbar-fill{width:100%;background:#4E9599;border-radius:8px 8px 4px 4px;}
.qbar-fill.hi{background:var(--brand-teal);}
.qbar-label{font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12.5px;color:var(--text);}
/* chart hover tooltip */
.ebar,.mbar,.qbar{cursor:default;}
.charts [data-tip]:hover .ebar-track,.charts [data-tip]:hover .mbar-track{filter:brightness(.96);}
.charttip{
  position:fixed;z-index:60;pointer-events:none;background:var(--paper);color:#FFFFFF;
  font-family:var(--ui);font-size:12px;font-weight:500;padding:6px 10px;border-radius:6px;
  white-space:nowrap;box-shadow:0 8px 18px rgba(16,34,42,.25);
}
.charttip[hidden]{display:none;}

/* Value controls in the builder: a set of ticks for "is one of", a pair of
   menus for "is between". Both sit in the value cell of the condition row. */
.vmulti{display:flex;flex-wrap:wrap;gap:6px;}
.vchip{
  display:inline-flex;align-items:center;gap:6px;font-size:12.5px;color:var(--text);
  background:var(--surface);border:1px solid var(--hairline);border-radius:7px;padding:5px 9px;cursor:pointer;
}
.vchip input{accent-color:var(--brand-teal);}
.vbetween{display:flex;align-items:center;gap:8px;}
.vbetween .join{grid-column:auto;padding:0;color:var(--dim);}
.vbetween .sel{flex:1;min-width:0;}

/* A withheld bar is shown as a small hatched stub, so the chart admits a value
   was there without hinting at its size. */
.mbar-fill.withheld-fill{
  background:repeating-linear-gradient(45deg,var(--control) 0,var(--control) 2px,transparent 2px,transparent 5px);
  border-radius:6px;
}

/* Chart controls. Print sends the single chart to its own printable page (and
   to the audit trail); the expand icon takes it to the full window. */
.chart-actions{display:flex;gap:8px;align-items:center;flex:none;}
.chart-print{
  font-family:var(--label);font-size:12px;font-weight:600;text-transform:uppercase;letter-spacing:.12em;
  padding:6px 12px;border-radius:7px;text-decoration:none;cursor:pointer;
  border:1px solid var(--hairline);background:var(--surface);color:var(--brand-teal-lift);
}
.chart-print:hover{border-color:var(--brand-teal);}
.chart-expand{
  width:32px;height:32px;display:inline-flex;align-items:center;justify-content:center;
  border:1px solid var(--hairline);background:var(--surface);color:var(--brand-teal-lift);
  border-radius:8px;cursor:pointer;font-size:17px;line-height:1;
}
.chart-expand:hover{border-color:var(--brand-teal);}
.chartbars{min-width:0;}

/* The chart selector, a dropdown at the top right of the charts. It is a display
   preference: it never changes what is counted or suppressed. */
.chartpicker{position:relative;}
.chartpicker > summary{
  list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:8px;
  border:1px solid var(--hairline);border-radius:8px;padding:7px 13px;background:var(--surface);
  font-family:var(--label);text-transform:uppercase;letter-spacing:.12em;font-size:12px;font-weight:600;
  color:var(--brand-teal-lift);
}
.chartpicker > summary::-webkit-details-marker{display:none;}
.chartpicker > summary::after{content:"▾";font-size:11px;color:var(--muted);}
.chartpicker[open] > summary{border-color:var(--brand-teal);}
.chartpicker > form{
  position:absolute;right:0;top:calc(100% + 6px);z-index:30;width:320px;max-width:88vw;
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:16px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);
}
.picker-row{display:flex;gap:10px;align-items:flex-start;padding:8px 0;border-bottom:1px solid var(--hairline-soft);font-size:13px;color:var(--text);cursor:pointer;}
.picker-row:last-of-type{border-bottom:none;}
.picker-row input{margin-top:3px;accent-color:var(--brand-teal);}

/* The expanded chart takes the full window. It scales to the space it is given,
   so it reads on a small laptop and fills a large monitor without a fixed size,
   and it shows the per band numbers the card only summarises. */
.chart-overlay{
  position:fixed;inset:0;z-index:50;background:rgba(16,34,42,.55);
  display:flex;align-items:flex-start;justify-content:center;padding:min(5vh,48px) 4vw;overflow-y:auto;
}
.chart-overlay[hidden]{display:none;}
.chart-sheet{
  position:relative;background:var(--surface);border-radius:14px;padding:clamp(20px,4vw,44px);
  width:min(1100px,96vw);box-shadow:0 30px 70px rgba(16,34,42,.3);
}
.chart-close{
  position:absolute;top:16px;right:16px;border:1px solid var(--hairline);background:var(--surface);
  color:var(--text);border-radius:8px;padding:7px 12px;cursor:pointer;font-size:13px;
}
.chart-close:hover{border-color:var(--brand-teal);color:var(--paper);}
.expanded-title{font-size:clamp(22px,3vw,32px);color:var(--paper);margin:2px 0 4px;}
.expanded-sub{color:var(--muted);margin:0 0 6px;font-size:15px;}
.expanded-meta{margin:0 0 20px;}
.expanded-bars{display:grid;gap:14px;}
.ebar-row{
  display:grid;grid-template-columns:minmax(140px,1.4fr) 3fr 90px 72px;gap:clamp(10px,1.5vw,22px);align-items:center;
}
.ebar-cat{font-size:clamp(14px,1.4vw,17px);color:var(--text);}
.ebar-track{height:clamp(20px,2.4vw,30px);background:var(--teal-wash);border-radius:7px;overflow:hidden;}
.ebar-fill{height:100%;background:#3E8A8E;border-radius:7px;}
.ebar-fill.first{background:var(--brand-teal);}
.ebar-n{font-family:var(--mono);font-size:clamp(13px,1.3vw,16px);color:var(--paper);text-align:right;}
.ebar-share{font-family:var(--mono);font-size:clamp(12px,1.2vw,15px);color:var(--muted);text-align:right;}
.expanded-note{margin-top:22px;}
.expanded-print{margin-top:24px;}
@media (max-width:560px){
  .ebar-row{grid-template-columns:1fr 60px 56px;}
  .ebar-row .ebar-track{display:none;}
}

/* Standalone print sheet for a single chart. */
.printsheet{max-width:820px;margin:0 auto;padding:28px;color:var(--paper);}
.printhead{border-bottom:2px solid var(--hairline);padding-bottom:14px;margin-bottom:16px;}
.printmeta{display:grid;grid-template-columns:1fr 1fr;gap:24px;}
.printbars{width:100%;border-collapse:collapse;}
.printbars th,.printbars td{text-align:left;padding:8px 10px;border-bottom:1px solid var(--hairline-soft);font-size:13px;}
.printbars th{font-family:var(--label);text-transform:uppercase;letter-spacing:.1em;font-size:12px;color:var(--muted);}
.printbars td.n{font-family:var(--mono);text-align:right;}
.printbars th:not(:first-child){text-align:right;}
@media (max-width:640px){.printmeta{grid-template-columns:1fr;}}

/* Per chart controls: the type and the field or fields it is drawn from, so a
   researcher builds their own analysis rather than picking from a fixed set. */
/* The card header row: chart number on the left, the form, expand and remove on
   the right. One row of a fixed height, so cards line up next to each other
   whatever the form label reads, and the space below it is the same on every
   card. Clear space separates it from the selector strip. */
.chart-head{display:flex;justify-content:space-between;align-items:center;gap:12px;
  min-height:32px;margin-bottom:14px;}
.chart-k{margin:0;}

/* A compact strip of controls, in its own space between the header and the
   chart. The type and field selectors sit side by side at their natural width,
   wrapping only when a narrow card cannot hold them on one row. The visible
   labels are gone; each control keeps an accessible name. */
.chart-editor{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0 0 16px;padding:8px 10px;
  background:var(--surface-2,var(--surface));border:1px solid var(--hairline-soft);border-radius:9px;}
.chart-editor .sel{width:auto;min-width:0;max-width:230px;padding:7px 10px;font-size:13px;}
.chart-editor .ctrl-fields{display:flex;align-items:center;gap:8px;min-width:0;flex-wrap:wrap;}
.chart-editor .ctrl-cap{font-family:var(--label);text-transform:uppercase;letter-spacing:.12em;
  font-size:12px;font-weight:600;color:var(--muted);}
.chart-editor .vmulti{max-width:100%;}
.chart-note{margin:0 0 12px;font-size:13px;color:var(--control-ink);
  background:var(--amber-wash,#fbf3dd);border:1px solid var(--amber-line,#ecdca6);
  border-radius:7px;padding:7px 10px;}

/* The remove control sits with the expand icon. The last remaining chart cannot
   be removed, so its control is disabled rather than hidden, making the minimum
   of one clear. */
.chart-remove-form{display:inline-flex;margin:0;}
.chart-remove{width:32px;height:32px;display:inline-flex;align-items:center;justify-content:center;
  border:1px solid var(--hairline);background:var(--surface);color:var(--blocked-ink);border-radius:8px;
  cursor:pointer;font-size:17px;line-height:1;}
.chart-remove:hover{border-color:var(--blocked);}
.chart-remove[disabled]{color:var(--muted);cursor:not-allowed;border-color:var(--hairline-soft);}

/* Table charts: cross tabulation and the numeric summary. */
.charttable-wrap{overflow-x:auto;border:1px solid var(--hairline);border-radius:10px;}
.charttable{width:100%;border-collapse:collapse;font-size:13px;}
.charttable th,.charttable td{padding:8px 12px;text-align:right;white-space:nowrap;
  border-bottom:1px solid var(--hairline-soft);}
.charttable th:first-child,.charttable td.rowhead{text-align:left;color:var(--text);}
.charttable thead th{font-family:var(--label);text-transform:uppercase;letter-spacing:.1em;
  font-size:12px;color:var(--muted);}
.charttable td{font-family:var(--mono);color:var(--paper);}
.charttable td.rowhead{font-family:var(--ui);}

/* The per band share in the expanded and printed bar views. */

/* In place chart updates. The Apply button is the fallback for when JavaScript
   is off; with it on the change applies on its own, so the button is hidden. */
.js .chart-apply{display:none;}
/* While a card redraws it shows a working state and its controls are inert, so a
   second change cannot be submitted for it. The other cards stay usable. */
.chart-busy{
  position:absolute;inset:0;z-index:6;display:none;align-items:center;justify-content:center;gap:9px;
  background:rgba(247,250,250,.72);border-radius:12px;
  font-family:var(--label);text-transform:uppercase;letter-spacing:.12em;font-size:12px;color:var(--muted);
}
.chartcard.is-updating .chart-busy{display:flex;}
.chartcard.is-updating .chart-actions,
.chartcard.is-updating .chart-editor{opacity:.5;pointer-events:none;}
/* A failed redraw leaves the previous chart in place and says so. */
.chart-error{margin:10px 0 0;font-size:12.5px;color:var(--blocked-ink);}

/* Under a tablet width, one chart card fills the row rather than two side by
   side, so the forms stay readable on a narrow screen. */
@media (max-width:900px){.charts{grid-template-columns:1fr;}}

/* The visual form picker, top right of the card before expand and remove. A
   greyed form states on hover, and inline, what the analysis would need. */
.formpicker{position:relative;}
/* Every other control in a card header is the form picker's height, so the
   results table's Wider and Open sit on one row with the chart cards' controls. */
.chart-btn{
  display:inline-flex;align-items:center;height:32px;padding:0 11px;border:1px solid var(--hairline);
  border-radius:8px;background:var(--surface);font-family:var(--ui);font-size:12px;font-weight:600;
  line-height:1;color:var(--brand-teal-lift);text-decoration:none;cursor:pointer;white-space:nowrap;
}
.chart-btn:hover{border-color:var(--brand-teal);}
.chart-actions form{margin:0;display:inline-flex;}
/* About these numbers: one line when something is withheld, the rest behind
   a toggle closed by default. */
.about-numbers{margin-top:10px;}
.about-line{margin:0 0 4px;font-size:12.5px;color:var(--text);}
.about-toggle > summary{list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:6px;
  font-size:12px;font-weight:600;color:var(--brand-teal-lift);}
.about-toggle > summary::-webkit-details-marker{display:none;}
.about-toggle > summary::after{content:"\25be";font-size:10px;}
.about-toggle[open] > summary::after{content:"\25b4";}
.about-body p{margin:6px 0 0;max-width:72ch;font-size:12px;line-height:1.6;color:var(--text);}
.formpicker > summary{
  list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:6px;height:32px;
  border:1px solid var(--hairline);border-radius:8px;padding:0 11px;background:var(--surface);
  font-size:12px;font-weight:600;color:var(--brand-teal-lift);white-space:nowrap;
}
.formpicker > summary::-webkit-details-marker{display:none;}
.formpicker > summary::after{content:"\25be";color:var(--muted);font-size:10px;}
.formpicker[open] > summary{border-color:var(--brand-teal);}
.formpicker-menu{
  position:absolute;right:0;top:calc(100% + 6px);z-index:35;width:280px;max-width:86vw;
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:12px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);display:flex;flex-direction:column;gap:2px;
  animation:menuin .12s ease both;
}
@keyframes menuin{from{opacity:0;transform:translateY(-3px);}to{opacity:1;transform:none;}}
/* A menu too tall for the window scrolls inside itself (static/js/menu-place.js),
   and its description stays at the top while it does. */
.formpicker-menu > .hint{position:sticky;top:-12px;z-index:1;background:var(--surface);
  margin:-12px -12px 6px !important;padding:12px 12px 6px;}

/* Confirming a chart removal. The house error colours, because this is the one
   control on the card that loses work, and cancel is the safe default: it takes
   focus, so a stray Enter cancels, and Escape cancels too. */
.chart-confirm{
  border:1px solid var(--blocked);background:var(--blocked-wash);border-radius:8px;
  padding:12px 14px;margin-bottom:12px;animation:menuin .12s ease both;
}
.chart-confirm-q{margin:0 0 10px;font-size:13px;color:var(--text);}
.chart-confirm-q strong{color:var(--paper);font-weight:600;}
@media (prefers-reduced-motion:reduce){
  .formpicker-menu,.chart-confirm{animation:none;}
}
.formopt{
  text-align:left;border:none;background:none;border-radius:7px;padding:7px 9px;cursor:pointer;
  font-size:13px;color:var(--text);font-family:var(--ui);
}
.formopt:hover{background:var(--teal-wash);}

/* The regression card's boxes as list boxes (static/js/reg-picker.js). A
   greyed field keeps its text at the page's text colour, so it clears the
   7.0 floor: it is set apart by italic, a tint and the "?", not by fading. */
.lbox{position:relative;}
/* Update choices is for JavaScript off; the list boxes update themselves. */
[data-reg-update][hidden],[data-reg-nojs][hidden]{display:none;}
.lbox-button{display:flex;align-items:center;justify-content:space-between;gap:8px;text-align:left;cursor:pointer;}
.lbox-button::after{content:"\25be";font-size:11px;color:var(--text);}
.lbox-list{position:absolute;left:0;right:0;top:calc(100% + 4px);z-index:40;margin:0;padding:4px;list-style:none;
  max-height:300px;overflow:auto;background:var(--surface);border:1px solid var(--hairline);border-radius:10px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);}
.lbox-list:focus{outline:2px solid var(--brand-teal);outline-offset:2px;}
.lbox-list li{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:7px 9px;border-radius:7px;
  font-size:13px;color:var(--paper);cursor:pointer;}
.lbox-list li[aria-selected="true"]{font-weight:600;}
.lbox-list li.lbox-active{background:var(--teal-wash);box-shadow:inset 0 0 0 2px var(--brand-teal);}
.lbox-list li.lbox-off{color:var(--text);font-style:italic;background:#F3F6F7;cursor:not-allowed;}
.lbox-list li.lbox-off.lbox-active{background:#E8EEF0;}
.lbox-q{position:relative;flex:none;display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;
  border:1px solid var(--text);border-radius:50%;font-size:12px;font-style:normal;font-weight:600;color:var(--text);}
.lbox-q:hover::after{content:attr(data-why);position:absolute;right:0;top:calc(100% + 6px);z-index:41;width:max-content;
  max-width:260px;padding:6px 9px;border-radius:6px;background:var(--paper);color:#FFFFFF;font-size:12px;
  font-weight:400;line-height:1.4;white-space:normal;}
.lbox-why{min-height:1em;margin:4px 0 0;font-size:12px;color:var(--text);}

/* The restrictions panel on a catalogue card: one line closed, every rule open. */
.restrictions-panel{margin-top:14px;border:1px solid var(--hairline);border-radius:10px;background:var(--surface);}
.restrictions-panel > summary{list-style:none;cursor:pointer;display:flex;flex-wrap:wrap;align-items:baseline;gap:6px 10px;padding:10px 14px;font-size:13px;color:var(--text);}
.restrictions-panel > summary::-webkit-details-marker{display:none;}
.restrictions-panel > summary .eyebrow{margin:0;}
.restrictions-more{margin-left:auto;font-size:12.5px;font-weight:600;color:var(--brand-teal-lift);white-space:nowrap;}
.restrictions-more::after{content:" \25be";}
.restrictions-panel[open] .restrictions-more::after{content:" \25b4";}
.restrictions-body{padding:0 14px 14px;}
/* Relative, so the visually hidden labels of the owner's forms, which are
   absolutely positioned, scroll with the table instead of widening the page. */
.restrictions-scroll{position:relative;}  /* with .rowtable-wrap, which scrolls; relative so the
   absolutely positioned visually hidden labels of the owner's forms scroll with the table
   instead of widening the page. */

/* The catalogue card's buttons. One line height, so the field dictionary's
   <button>, a dashboard <a> and the dashboard menu's <summary> are one height:
   a button's line height is otherwise "normal" and a link's the body's 1.62. */
.catactions .btn{line-height:20px;}
/* The dashboard menu, when a card offers two or more dashboards. */
.dashpick{position:relative;}
.dashpick > summary{list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:8px;white-space:nowrap;}
.dashpick > summary::-webkit-details-marker{display:none;}
.dashpick > summary::after{content:"\25be";font-size:11px;}
.dashpick[open] > summary{border-color:var(--brand-teal);}
.dashpick-menu{
  position:absolute;left:0;top:calc(100% + 6px);z-index:35;width:320px;max-width:86vw;
  margin:0;padding:6px;list-style:none;background:var(--surface);border:1px solid var(--hairline);
  border-radius:10px;box-shadow:0 18px 40px rgba(16,34,42,.18);animation:menuin .12s ease both;
}
.dashpick-menu a{display:flex;flex-direction:column;gap:2px;padding:9px 10px;border-radius:7px;text-decoration:none;}
.dashpick-menu a:hover{background:var(--teal-wash);}
.dashpick-menu a:focus-visible{outline:2px solid var(--brand-teal);outline-offset:-2px;}
.dashpick-name{font-size:14px;font-weight:600;color:var(--paper);}
.dashpick-says{font-size:13px;color:var(--text);}
@media (prefers-reduced-motion:reduce){.dashpick-menu{animation:none;}}
.formopt.on{background:var(--teal-wash);color:var(--brand-teal-lift);font-weight:600;}
/* Chart type first (BIO-120): every type can be chosen, each with a line on
   what it shows. Nothing is greyed. */
.formopt{display:flex;flex-direction:column;gap:1px;}
.formopt-name{font-size:13px;}
.formopt-what{font-size:12px;color:var(--text);font-weight:400;}
/* The chart type select is the choice with scripts off; with them the menu is. */
.js .chart-formsel{display:none;}
/* Add a chart, as a menu of chart types (BIO-120). */
.chartadd{position:relative;}
.chartadd > summary{list-style:none;cursor:pointer;}
.chartadd > summary::-webkit-details-marker{display:none;}
.chartadd-menu{position:absolute;right:0;top:calc(100% + 6px);z-index:35;width:280px;max-width:86vw;
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:12px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);display:flex;flex-direction:column;gap:2px;}
.chartadd-menu > .hint{position:sticky;top:-12px;z-index:1;background:var(--surface);
  margin:-12px -12px 6px !important;padding:12px 12px 6px;}
.chart-fixed{display:inline-flex;align-items:center;font-size:13px;color:var(--text);padding:0 4px;}
.chart-chose{margin:0 0 10px;font-size:13px;color:var(--paper);background:var(--teal-wash);
  border-radius:6px;padding:5px 9px;}
.chart-unavailable{border:1px dashed var(--hairline);border-radius:8px;padding:16px;margin:4px 0 8px;
  font-size:13.5px;color:var(--paper);}
.chart-unavailable p{margin:0 0 8px;max-width:60ch;}
.chart-unavailable a{color:var(--brand-teal-lift);font-weight:600;}

/* A small colour cycle for the parts of stacked, grouped and heat map charts. */
.seg-0{background:var(--brand-teal);}
.seg-1{background:#3E8A8E;}
.seg-2{background:#7BB2A6;}
.seg-3{background:#C7A15A;}
.seg-4{background:#9A6DB0;}
.seg-5{background:#5B7C99;}
.chart-legend{display:flex;flex-wrap:wrap;gap:8px 14px;margin-top:12px;font-size:13px;color:var(--text);}
.chart-legend .leg{display:inline-flex;align-items:center;gap:6px;}
.swatch{width:11px;height:11px;border-radius:3px;display:inline-block;}

/* Vertical columns. */
/* Vertical value charts share a y-axis on the left with tick labels and faint
   horizontal gridlines behind the columns, so a height can be read as a number. */
/* The unit sits in its own band above the top tick (BIO-148): the top tick is
   centred on the top edge, so it reaches 8px above it, and the unit at -16px
   overprinted it. The band is the plot's own padding, so it pushes nothing. */
.plot-v{display:flex;gap:8px;align-items:stretch;padding-top:26px;}
.yaxis{position:relative;width:44px;flex:none;height:200px;}
.ya-tick{position:absolute;right:0;transform:translateY(50%);font-family:var(--mono);font-size:12px;
  color:var(--muted);white-space:nowrap;}
.ya-unit{position:absolute;left:0;top:-28px;font-family:var(--label);text-transform:uppercase;
  letter-spacing:.1em;font-size:12px;line-height:14px;color:var(--muted);white-space:nowrap;}
.gridded-v{
  background-image:repeating-linear-gradient(0deg,
    var(--hairline) 0, var(--hairline) 1px, transparent 1px, transparent var(--tick));
  background-position:left bottom;
}
.colchart{flex:1;display:flex;align-items:flex-end;gap:10px;height:200px;overflow-x:auto;}
.col{flex:1 0 44px;display:flex;flex-direction:column;align-items:center;gap:6px;height:100%;
  justify-content:flex-end;min-width:44px;}
.col-track{width:100%;flex:1;display:flex;align-items:flex-end;}
.col-fill{width:100%;background:#3E8A8E;border-radius:6px 6px 3px 3px;min-height:2px;}
.col-fill.first,.colchart .col:first-child .col-fill{background:var(--brand-teal);}
.col-n{font-family:var(--mono);font-size:12px;color:var(--paper);}
.col-label{font-size:12px;color:var(--text);text-align:center;word-break:break-word;}

/* Dot plot: a value on a shared axis, read where bars would crowd. */
.dotplot{display:flex;flex-direction:column;gap:9px;}
.dotrow{display:grid;grid-template-columns:112px 1fr 64px;gap:10px;align-items:center;}
.dot-label{font-size:13px;color:var(--text);}
.dot-track{position:relative;height:20px;border-bottom:1px solid var(--hairline);}
.dot-track.gridded{background-color:var(--surface-2);}
/* Half the radius it was drawn at, matching the line and area marker, so a point
   reads as a point rather than as the main object on the track. */
.dot{position:absolute;top:7px;width:6px;height:6px;border-radius:50%;background:var(--brand-teal);
  transform:translateX(-50%);}
.dot-withheld{font-size:12px;}
/* A chart with nothing left to draw says so, rather than leaving an empty plot
   that reads as a rendering fault. */
.chart-empty{
  margin:8px 0 0;font-size:12px;line-height:1.5;color:var(--muted);
  display:flex;align-items:baseline;gap:8px;
}
.dot-n{font-family:var(--mono);font-size:12px;color:var(--paper);text-align:right;}

/* Line and area over an ordered sequence. */
.linechart{width:100%;height:auto;display:block;overflow:hidden;}
.line-axis{stroke:var(--hairline);stroke-width:1;}
.line-stroke{fill:none;stroke:var(--brand-teal);stroke-width:2.5;stroke-linejoin:round;stroke-linecap:round;}
.area-fill{fill:rgba(22,104,109,.14);stroke:none;}
/* The stroke comes down with the radius. At the old 2.5 a halved marker would
   close up into a solid blob and lose the ring that marks the point. */
.line-dot{fill:#fff;stroke:var(--brand-teal);stroke-width:1.5;}
.withheld-tick{fill:var(--control);}
.line-label{fill:var(--muted);font-size:12px;font-family:var(--ui);}
.line-grid{stroke:var(--hairline);stroke-width:1;}
.axis-label{fill:var(--muted);font-size:12px;font-family:var(--ui);}
.point-value{fill:var(--paper);font-size:12px;font-family:var(--mono);}

/* Comparative statistics panel. A researcher reads figures, an interval, a p
   value and the n, so it is set as plain tables rather than a picture. */
.statspanel{background:var(--surface);border:1px solid var(--hairline);border-radius:12px;
  padding:18px 20px;margin-bottom:16px;min-width:0;}
.stats-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:10px;}
.stats-head h4{font-size:15px;color:var(--paper);margin:0;}
.crosstab em{display:block;font-style:normal;font-size:12px;color:var(--dim);font-family:var(--mono);}
.stats-figures{width:100%;border-collapse:collapse;margin:14px 0 6px;font-size:13px;}
.stats-figures th{text-align:left;color:var(--muted);font-weight:600;font-size:12px;
  text-transform:uppercase;letter-spacing:.08em;padding:6px 10px;border-bottom:1px solid var(--hairline);}
.stats-figures td{padding:7px 10px;border-bottom:1px solid var(--hairline);color:var(--text);}
.stats-figures td:first-child{color:var(--paper);}
.stats-context{margin-top:12px;border-top:1px solid var(--hairline);padding-top:10px;}
.stats-context ul{margin:0;padding-left:18px;}
.stats-context li{font-size:12px;color:var(--dim);margin:2px 0;}

/* Stacked and proportional bars, one row per group. */
.stackchart{display:flex;flex-direction:column;gap:10px;}
.stackrow{display:grid;grid-template-columns:112px 1fr;gap:10px;align-items:center;}
.stackchart + .va-h,.stackchart ~ .va-h{grid-template-columns:112px 1fr;}
.stack-label{font-size:13px;color:var(--text);}
.stack-track{display:flex;height:22px;border-radius:6px;overflow:hidden;background:var(--teal-wash);}
.stack-seg{height:100%;display:flex;align-items:center;justify-content:center;overflow:hidden;}
.seg-n{font-family:var(--mono);font-size:12px;color:#fff;white-space:nowrap;}

/* Grouped bars, a small cluster of columns per group. */
.groupchart{flex:1;display:flex;gap:16px;height:200px;align-items:stretch;overflow-x:auto;}
.grouprow{flex:1 0 60px;display:flex;flex-direction:column;gap:6px;min-width:60px;}
.group-bars{flex:1;display:flex;align-items:flex-end;justify-content:center;gap:5px;
  border-bottom:1px solid var(--hairline);}
.gbar{flex:1;max-width:36px;min-width:8px;border-radius:4px 4px 0 0;min-height:2px;position:relative;
  display:flex;align-items:flex-start;justify-content:center;}
.gbar-n{position:absolute;top:-15px;font-family:var(--mono);font-size:12px;color:var(--paper);white-space:nowrap;}
.group-label{font-size:12.5px;color:var(--text);text-align:center;}

/* Heat map: two categorical fields as shaded cells. A withheld cell is hatched,
   never shaded, so a light shade cannot imply a small number. */
.heatmap{width:100%;border-collapse:separate;border-spacing:3px;font-size:12px;}
.heatmap th{font-family:var(--label);text-transform:uppercase;letter-spacing:.08em;font-size:12px;
  color:var(--muted);font-weight:600;padding:2px 4px;text-align:center;}
.heatmap th.rowhead{text-align:right;color:var(--text);text-transform:none;letter-spacing:0;font-size:12px;}
.heatcell{width:44px;height:30px;border-radius:4px;text-align:center;vertical-align:middle;}
.heat-n{font-family:var(--mono);font-size:12px;color:var(--paper);}
.heat-3 .heat-n,.heat-4 .heat-n{color:#fff;}
.heat-0{background:#EAF2F2;}
.heat-1{background:#BEDAD9;}
.heat-2{background:#7FB6B4;}
.heat-3{background:#3E8A8E;}
.heat-4{background:var(--brand-teal);}
.heat-withheld{background:repeating-linear-gradient(45deg,var(--control) 0,var(--control) 2px,transparent 2px,transparent 5px);}
.heat-key{display:flex;align-items:center;gap:5px;margin-top:12px;font-size:13px;color:var(--muted);}
.heat-key i{width:16px;height:12px;border-radius:2px;display:inline-block;}

/* Box plot: median and quartiles across a categorical split. A group below the
   threshold is withheld whole, since quartiles on a few records identify them. */
.boxchart{display:flex;flex-direction:column;gap:12px;}
.boxrow{display:grid;grid-template-columns:112px 1fr;gap:12px;align-items:center;}
.box-label{font-size:13px;color:var(--text);}
.box-track{position:relative;height:24px;}
.box-grid{position:absolute;inset:0;pointer-events:none;}
.box-grid .bg{position:absolute;top:0;bottom:0;width:1px;background:var(--hairline);}
.box-whisker{position:absolute;top:11px;height:2px;background:var(--muted);}
.box-iqr{position:absolute;top:3px;height:18px;background:var(--teal-wash);border:1.5px solid var(--brand-teal);border-radius:3px;}
.box-median{position:absolute;top:3px;height:18px;width:2px;background:var(--brand-teal);}
.box-withheld{font-size:12px;}
.box-axisrow{display:grid;grid-template-columns:112px 1fr;gap:12px;}
.box-ticks{position:relative;height:16px;}
.box-ticks span{position:absolute;top:0;transform:translateX(-50%);font-family:var(--mono);font-size:12px;color:var(--muted);}
.box-axis{display:flex;justify-content:space-between;font-family:var(--mono);font-size:12px;
  color:var(--dim);margin-top:4px;padding-left:calc(25% + 12px);}

/* Treemap: nested rectangles by count, area proportional. */
.treemap{position:relative;width:100%;height:280px;background:var(--teal-wash);border-radius:10px;overflow:hidden;}
.tile{position:absolute;border:2px solid var(--surface);border-radius:4px;background:#4E9599;
  padding:5px 7px;overflow:hidden;display:flex;flex-direction:column;gap:1px;color:#fff;}
.tile:nth-child(3n){background:#3E8A8E;}
.tile:nth-child(3n+1){background:var(--brand-teal);}
.tile-label{font-size:12px;line-height:1.15;}
.tile-n{font-family:var(--mono);font-size:12px;opacity:.85;}
.tile.withheld-fill{color:var(--text);}

/* Name-this-analysis modal. */
.modal-overlay{
  position:fixed;inset:0;z-index:40;background:rgba(16,34,42,.45);
  display:flex;align-items:center;justify-content:center;padding:20px;overflow-y:auto;
}
.modal-overlay[hidden]{display:none;}
.modal{
  background:var(--surface);border-radius:12px;padding:26px 28px;max-width:460px;width:100%;
  box-shadow:0 24px 60px rgba(16,34,42,.28);max-height:90vh;overflow-y:auto;margin:auto;
}
.modal h3{font-size:19px;margin-bottom:6px;}

/* Audit trail: filter chips. */
.filterbar{display:flex;flex-wrap:wrap;gap:8px;margin:2px 0 4px;}
.chip{
  display:inline-flex;align-items:center;gap:8px;text-decoration:none;
  border:1px solid var(--hairline);border-radius:20px;padding:6px 14px;
  font-size:13px;color:var(--text);background:var(--surface);
}
.chip:hover{border-color:var(--muted);color:var(--paper);}
.chip.on{background:var(--teal-wash);border-color:var(--brand-teal);color:var(--brand-teal-lift);font-weight:600;}
.chip .chipn{font-family:var(--mono);font-size:12px;color:var(--dim);}
.chip.on .chipn{color:var(--brand-teal-lift);}

/* Audit trail: older activity folded away by day. */
.daygroup{border-top:1px solid var(--hairline-soft);}
.daygroup summary{
  list-style:none;cursor:pointer;display:flex;align-items:center;gap:12px;
  padding:14px 2px;font-family:var(--label);text-transform:uppercase;
  letter-spacing:.14em;font-size:12.5px;color:var(--text);font-weight:600;
}
.daygroup summary::-webkit-details-marker{display:none;}
.daygroup summary::before{
  content:"▸";color:var(--muted);font-size:11px;transition:transform .15s;
}
.daygroup[open] summary::before{transform:rotate(90deg);}
.daygroup .daycount{
  margin-left:auto;font-family:var(--mono);text-transform:none;letter-spacing:0;
  font-size:12px;color:var(--dim);font-weight:400;
}
.daygroup[open] summary{color:var(--paper);}
.daygroup > .thread{padding-bottom:8px;}

/* Sign in step indicator (POC design). */
.step{display:flex;align-items:center;gap:9px;margin-bottom:14px;}
.step .num{
  width:22px;height:22px;border-radius:11px;background:var(--brand-teal);color:#fff;
  font-size:12px;font-weight:700;display:flex;align-items:center;justify-content:center;flex:none;
}
.step .lbl{
  font-family:var(--label);font-weight:600;text-transform:uppercase;letter-spacing:.16em;
  font-size:12.5px;color:var(--muted);
}

/* Submitting state (progressive enhancement). These styles are only ever
   applied by submit-guard.js while a form is on its way, so a slow submit
   cannot be pressed twice. Nothing here appears without JavaScript. */
.btn.is-submitting{cursor:progress;}
.btn.is-submitting[disabled]{opacity:.92;color:#FFFFFF;cursor:progress;}
.btn-spinner{
  display:inline-block;vertical-align:-2px;width:13px;height:13px;margin-right:9px;
  border:2px solid rgba(255,255,255,.4);border-top-color:#FFFFFF;border-radius:50%;
  animation:btnspin .7s linear infinite;
}
@keyframes btnspin{to{transform:rotate(360deg);}}
/* Respect a reduced motion preference: hold the ring still so it reads as a
   static indicator, and let the changed label carry the state instead. */
@media (prefers-reduced-motion:reduce){
  .btn-spinner{animation:none;}
}

/* Visually hidden, still read by a screen reader. Used for the polite live
   region that announces the submitting state. */
.sr-only{
  position:absolute;width:1px;height:1px;padding:0;margin:-1px;
  overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;
}

/* Printing a result (also the path to "save as PDF"). Strip the chrome so the
   page prints as the charts, the table and the information alone. */
@media print{
  .topbar,.rail,.perimeter,.backlink,.chart-soon,.charttip,.chart-actions{display:none !important;}
  .row .btn,.row a.btn{display:none !important;}
  .app,.body,.main{display:block;background:#FFFFFF;}
  .chartcard,.card{break-inside:avoid;}
}

/* The printed analysis: the whole thing as one document, landscape, a chart to
   a page. It shares the sheet, meta and chart treatment of a single printed
   chart rather than introducing a second one; what is added here is the page
   geometry and the running header, neither of which a one page print needs.

   The header is fixed rather than written into each page, because a header
   repeated by hand drifts the moment a chart changes height, which is the same
   reasoning that removed the editor's second scroller (constraint 22). A fixed
   box in print context is painted on every sheet by the browser. */
.printdoc .printrun{
  display:flex;justify-content:space-between;gap:16px;
  font-size:12px;color:var(--muted);
  padding-bottom:6px;border-bottom:1px solid var(--hairline);
  margin-bottom:14px;
}
.printsigfacts{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));
  gap:10px 20px;margin:0 0 12px;
}
.printsigfacts dt{font-size:12px;color:var(--muted);text-transform:uppercase;letter-spacing:0.04em;}
.printsigfacts dd{margin:2px 0 0;font-size:14px;color:var(--text);}
.printsig{
  margin-top:18px;padding:16px;
  border:1px solid var(--hairline);border-left:3px solid var(--brand-teal);
  border-radius:10px;background:var(--surface);
}
.printcaveat{
  background:var(--surface-3);border-radius:8px;padding:12px 14px;
  font-size:13px;line-height:1.5;color:var(--text);max-width:66ch;margin:0;
}
.printpara{
  margin:14px 0 0;font-size:13px;line-height:1.6;color:var(--text);max-width:90ch;
}
.printchart{margin-top:14px;}
.printchart svg{width:100%;height:auto;}

@media print{
  /* Landscape, so a wide chart is wide on paper rather than shrunk to fit a
     portrait column. */
  @page{size:A4 landscape;margin:12mm;}
  .printdoc{background:#FFFFFF;}
  /* One chart to a page. `break-after` on every sheet but the last, so the
     document does not end on a blank page. */
  .printdoc .printpage{break-after:page;}
  .printdoc .printpage:last-of-type{break-after:auto;}
  .printdoc .printpage{break-inside:avoid;}
  /* Repeated on every sheet. */
  .printdoc .printrun{
    position:fixed;top:0;left:0;right:0;
    background:#FFFFFF;
  }
  .printdoc .printsheet{padding-top:26px;}
  /* Print colours: the browser drops backgrounds by default, and a caveat that
     loses its panel loses the thing that marks it as a qualification. */
  .printsig,.printcaveat{
    -webkit-print-color-adjust:exact;print-color-adjust:exact;
  }
}

/* The analysis title and its rename control. The form is visible by default so
   the control works with JavaScript off; the script hides it and reveals the
   Rename button, which is the enhancement rather than the baseline. */
.renameform[hidden]{display:none;}
.analysistitle .renameopen{padding:4px 10px;font-size:12px;}

/* The instructions page. Seven collapsed sections, so the shape of what is
   documented fits on a screen before anything is opened.

   details and summary rather than a scripted disclosure: they open and close
   with JavaScript off, they are focusable and operable from the keyboard, and
   they report their own expanded state to a screen reader without any of it
   being added by hand. */
.guide{
  border:1px solid var(--hairline);border-radius:10px;
  margin-bottom:10px;background:var(--surface);
}
.guide > summary{
  cursor:pointer;padding:14px 16px;list-style:none;
  display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 12px;
}
/* The default disclosure triangle is replaced, so the marker has to be removed
   in both the standard and the WebKit spelling or two markers appear. */
.guide > summary::-webkit-details-marker{display:none;}
.guide > summary::marker{content:"";}
.guide > summary::before{
  content:"+";font-family:var(--mono);font-size:14px;line-height:1;
  color:var(--muted);flex:none;width:14px;
}
.guide[open] > summary::before{content:"−";}
.guide > summary:hover{background:var(--hover,rgba(0,0,0,0.02));}
/* Focus has to remain visible: this is the control a keyboard reader uses to
   move through the page. */
.guide > summary:focus-visible{outline:2px solid var(--focus,#2b6cb0);outline-offset:-2px;}
.guide-title{font-weight:600;font-size:15px;color:var(--text);}
.guide-hint{color:var(--muted);font-size:13px;}
.guide-body{padding:0 16px 14px 42px;}
.guide-body .hint{margin:0 0 10px;}
.guide-body .plain{margin:0 0 10px;padding-left:18px;}
.guide-body .plain li{margin-bottom:4px;color:var(--muted);font-size:13px;}
/* A language inside the code section. Indented and quieter than a top level
   section so the nesting reads. */
.guide-nested{margin:10px 0 0;background:transparent;}
.guide-nested > summary{padding:10px 12px;}
.guide-nested .guide-body{padding:0 12px 10px 38px;}


/* The catalogue dataset on a saved result card, under the date. */
.runitem-dataset{
  margin:2px 0 0;font-size:12px;color:var(--muted);
}
/* An analysis whose access has ended. Inert: it explains an absence rather than
   offering a way in, so it is not a link and does not respond to a hover. */
.runitem-lapsed{
  opacity:0.72;cursor:default;
}
.runitem-lapsed:hover{background:inherit;border-color:var(--hairline);}
/* The catalogue dataset filter is a select, sized so the row sits on one line
   with the three fields beside it. It was a fieldset of stacked tick boxes,
   which set its own height and left nothing in the row aligned. */
.savedfilter select.input{
  width:210px;max-width:100%;
  background:var(--surface);color:var(--text);
  border:1px solid var(--hairline);border-radius:7px;
}
/* Below this the row wraps, and a filter whose fields are each a different
   width wraps into a ragged block. Full width from here, so a wrapped row is
   a clean stack. */
@media (max-width:640px){
  .savedfilter{width:100%;margin-left:0;}
  .savedfilter .field{flex:1 1 100%;}
  .savedfilter .input,
  .savedfilter select.input,
  .savedfilter input[type="search"],
  .savedfilter input[type="date"]{width:100%;}
}

/* A chart group that can be narrowed to. It is a button, so it is reachable and
   operable from the keyboard without anything added, and it keeps the bar's own
   layout rather than looking like a form control. The columns and gap are
   .mbar's, named again here: `inherit` read them from the chart's own box,
   which has none, so a drillable chart stacked its bars and they no longer
   met the value axis's ticks (11 November 2026). */
button.mbar-drill{
  display:grid;grid-template-columns:112px 1fr 64px;align-items:center;gap:10px;
  width:100%;text-align:left;background:none;border:0;padding:2px 0;
  font:inherit;color:inherit;cursor:pointer;border-radius:4px;
}
button.mbar-drill:hover .mbar-label{text-decoration:underline;}
button.mbar-drill:focus-visible{outline:2px solid var(--focus,#2b6cb0);outline-offset:1px;}
/* A group that cannot be narrowed to. Not a control, and it carries the reason
   on the element so hovering or focusing says why. */
.mbar-nodrill{cursor:help;}

/* The drill path. */
.drillpath{margin:10px 0 16px;}
.drillpath-form{display:flex;flex-wrap:wrap;align-items:center;gap:4px 6px;}
.crumb{
  background:none;border:0;padding:2px 6px;font:inherit;font-size:13px;
  color:var(--link,#2b6cb0);cursor:pointer;border-radius:4px;
}
.crumb:hover{text-decoration:underline;}
.crumb:focus-visible{outline:2px solid var(--focus,#2b6cb0);outline-offset:1px;}
.crumb-here{color:var(--text);cursor:default;font-weight:600;}
.crumb-sep{color:var(--muted);font-size:12px;}

/* The context table on the contact page: four labelled values a researcher
   copies into an email. Monospaced values so a reference is readable and
   selectable as one run of characters. */
.ctxtable{width:100%;border-collapse:collapse;}
.ctxtable th{
  text-align:left;font-weight:500;font-size:13px;color:var(--muted);
  padding:5px 14px 5px 0;white-space:nowrap;vertical-align:top;width:1%;
}
.ctxtable td{
  font-family:var(--mono);font-size:12.5px;color:var(--text);
  padding:5px 0;word-break:break-all;
}

/* The role preview toggle. A demonstration control in the header, shown only to
   the account named in ROLE_PREVIEW_ACCOUNT. Presentation only: it redraws the
   interface as a researcher sees it and changes nothing the server authorises.

   The mode is readable as a word as well as by knob position, because position
   alone is exactly the kind of thing somebody misreads in a screenshot. */
.roleview { margin: 0; display: flex; align-items: center; }
.roleswitch {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--hairline);
  border-radius: 999px; padding: 4px 10px 4px 10px; cursor: pointer;
  font: inherit; font-size: 12px; color: var(--paper); line-height: 1;
}
.roleswitch:hover { border-color: var(--brand-teal); }
.roleswitch-label { opacity: .62; }
.roleswitch-mode { font-weight: 600; letter-spacing: .01em; }
.roleswitch-track {
  position: relative; width: 30px; height: 16px; border-radius: 999px;
  background: var(--hairline); flex: 0 0 auto; transition: background .15s;
}
.roleswitch-knob {
  position: absolute; top: 2px; left: 2px; width: 12px; height: 12px;
  border-radius: 50%; background: #fff; transition: transform .15s;
  box-shadow: 0 1px 2px rgba(0,0,0,.25);
}
/* Left for researcher, right for administrator. */
.roleswitch.as-admin .roleswitch-track { background: var(--brand-teal); }
.roleswitch.as-admin .roleswitch-knob { transform: translateX(14px); }
.roleswitch.as-researcher .roleswitch-track { background: var(--hairline); }
.roleswitch.as-researcher .roleswitch-knob { transform: none; }

/* The standing note in the rail while researcher view is on. It says what the
   control does not do, which is the half a reader otherwise supplies wrongly. */
.previewnote {
  margin: 14px 10px 0; padding: 10px 12px; border-radius: 8px;
  border: 1px dashed var(--hairline);
}

/* Tables with a row per thing, as opposed to .ctxtable which is a key and value
   list. Everything is centred on the y axis so a row with a control in it reads
   level with a row without one, and the control is sized to the text rather than
   to the default button padding, which was making the rows tall and uneven. */
.rowtable{width:100%;border-collapse:collapse;}
.rowtable th{
  text-align:left;font-weight:500;font-size:12px;color:var(--muted);
  letter-spacing:.04em;text-transform:uppercase;
  padding:0 14px 6px 0;white-space:nowrap;vertical-align:middle;
}
.rowtable td{
  font-size:13px;color:var(--text);
  padding:7px 14px 7px 0;vertical-align:middle;
  border-top:1px solid var(--hairline);
}
.rowtable td:last-child,.rowtable th:last-child{padding-right:0;text-align:right;}
.rowtable .rt-mono{font-family:var(--mono);font-size:12.5px;}
.rowtable .rt-quiet{color:var(--muted);}
/* The control in a row. Height comes from the line box plus small padding, so it
   sits inside the row rather than setting the row's height. */
.btn.rowbtn{
  padding:4px 10px;font-size:12px;line-height:1.3;border-radius:6px;
  min-height:0;height:auto;white-space:nowrap;
}
.rowtable form{margin:0;display:inline-block;}
/* A control that ends somebody's access reads as heavier than one that
   withdraws an unused invitation, because it is. */
.btn.rowbtn.heavy{border-color:var(--blocked);color:var(--blocked-ink);}
.btn.rowbtn.heavy:hover{background:var(--blocked);color:#fff;}
/* The dataset list under an accepted account. A details element, so it needs no
   script and opens with JavaScript off. */
.seelist{margin:4px 0 0;font-size:12.5px;}
.seelist summary{cursor:pointer;color:var(--muted);}
.seelist ul{margin:6px 0 0 0;padding-left:16px;}
.seelist li{margin:0 0 3px;}

/* The access period editor, inside the Ends cell of the memberships table.
   A details element, so it opens with no script and the table grows in one
   place rather than jumping. Closed by default. */
.endedit > summary{
  cursor:pointer;font-size:13px;color:var(--text);list-style:none;
  display:inline-flex;align-items:center;gap:6px;
}
.endedit > summary::-webkit-details-marker{display:none;}
.endedit > summary::after{content:"edit";font-size:11px;color:var(--muted);
  border:1px solid var(--hairline);border-radius:5px;padding:1px 5px;}
.endedit[open] > summary::after{content:"close";}
.endedit[open] > summary{margin-bottom:8px;}
/* A row whose period opens its editor keeps its cells at the top, so the
   period's own line stays where it was when the editor opens under it: with
   the cells centred, opening it moved the line up by half the row it had
   been centred in (12 November 2026, the No jumps work). */
.rowtable td:has(> details.endedit),.rowtable tr:has(details.endedit) > td{vertical-align:top;}
/* Record with a box left empty: the box is marked and a line under Record
   names it, rather than the browser bringing the box into view. */
.govcomplete .input[aria-invalid="true"]{border-color:var(--err-edge);}
.govcomplete .govmissing{margin:8px 0 0;}
.endform{
  margin:0;padding:10px 12px;border:1px solid var(--hairline);border-radius:8px;
  background:var(--surface);min-width:260px;
}
.endform label{display:block;font-size:12px;letter-spacing:.04em;
  text-transform:uppercase;color:var(--muted);margin-bottom:4px;}
.endform .input{max-width:190px;}
.endpresets{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px;}

/* Significance testing at the foot of a chart. The sentence first, the
   supporting detail under it, and the p value last rather than first, because a
   researcher reading a p value first reads the rest as decoration. */
.sigtest{margin:14px 0 0;padding:12px 14px;border-top:1px solid var(--hairline);}
.sigtest-sentence{margin:0 0 10px;font-size:14px;line-height:1.55;}
.sigtest-refused{margin:0;font-size:13px;line-height:1.55;color:var(--text);}
.sigtest-detail{display:grid;grid-template-columns:auto 1fr;gap:2px 14px;margin:0 0 10px;font-size:12.5px;}
.sigtest-detail dt{color:var(--muted);}
.sigtest-detail dd{margin:0;font-family:var(--mono);}
/* The half a reader supplies for themselves and gets wrong, so it is not a
   footnote. */
.sigtest-caveat{margin:0;font-size:12.5px;line-height:1.6;color:var(--muted);
  border-left:2px solid var(--hairline);padding-left:10px;}

/* Significance, at the foot of a chart that can carry a test. The sentence
   first and the p value last, because a researcher who reads the p value first
   reads it as the finding. */
.sigfoot{margin-top:14px;padding-top:12px;border-top:1px solid var(--hairline);}
.sigpanel{font-size:13px;}
.sigsentence{margin:0 0 10px;font-size:14px;line-height:1.55;color:var(--text);}
.sigdetail{display:grid;grid-template-columns:auto 1fr;gap:2px 14px;margin:0 0 10px;}
.sigdetail dt{font-size:12px;letter-spacing:.04em;text-transform:uppercase;
  color:var(--muted);align-self:center;}
.sigdetail dd{margin:0;font-family:var(--mono);font-size:12.5px;}
/* The half a reader supplies for themselves and gets wrong, so it is not a
   footnote and is not smaller than the finding. */
.sigcaveat{margin:0;padding:10px 12px;border-radius:8px;
  border:1px dashed var(--hairline);font-size:12.5px;line-height:1.6;color:var(--muted);}
.sigrefused .hint{line-height:1.6;}

/* The naming styles in the run dialogue. Each option shows the name it would
   actually produce, so the choice is made by reading. */
.namestyles{border:none;padding:0;margin:0 0 16px;}
.namestyles legend{font-size:13px;letter-spacing:.04em;text-transform:uppercase;
  color:var(--muted);padding:0;margin-bottom:6px;}
.namestyle{display:grid;grid-template-columns:auto auto 1fr;gap:8px;
  align-items:baseline;padding:6px 8px;border-radius:6px;cursor:pointer;}
.namestyle:hover{background:var(--surface-2);}
.namestyle-key{font-size:13px;letter-spacing:.04em;text-transform:uppercase;
  color:var(--muted);min-width:56px;}
.namestyle-name{font-size:12.5px;font-family:var(--mono);word-break:break-word;}
.namestyle-default{display:flex;gap:8px;align-items:center;margin-top:8px;
  font-size:12.5px;color:var(--muted);}

/* The significance card, ahead of the descriptive ones.

   Same surface, hairline and radius as a chart card so it reads as the first of
   four, with a teal rule down the left and its own heading because it is an
   inference rather than a count.

   It uses its width rather than running everything down the left: the heading
   and the collapse control sit apart, the supporting rows lay out across the
   card, and only the sentence and the caveat keep a reading measure, because
   those are prose and the rest is not. */
.sigcard{
  /* The caveat's columns depend on how wide the card is, not on how wide the
     window is: the card sits inside a main column whose width the viewport
     does not predict. A viewport breakpoint got this wrong at 1024, where the
     window is wide and the card is not. */
  container-type:inline-size;
  --sigcard-pad-x:22px;
  --sigcard-pad-b:20px;
  background:var(--surface);
  border:1px solid var(--hairline);
  border-left:3px solid var(--brand-teal);
  border-radius:12px;
  padding:20px var(--sigcard-pad-x) var(--sigcard-pad-b);
  margin:0 0 18px;
}
.sigcard-head{
  display:flex;align-items:flex-start;justify-content:space-between;
  gap:16px;margin-bottom:6px;
}
.sigcard-eyebrow{color:var(--brand-teal-lift);margin:0 0 4px;}
.sigcard-title{margin:0;font-size:19px;color:var(--paper);}
.sigcard-toggle{margin:0;flex:0 0 auto;}
/* 36em is about 75 characters in this typeface, at any size in this card. It
   replaces the `ch` caps, which were set by eye and measured wrong: `ch` is the
   advance of a zero, which is wider than the average letter here, so a 66ch cap
   produced 88 characters on the line rather than the 71 it was meant to be. */
.sigcard-lede{margin:6px 0 16px;font-size:13px;line-height:1.6;color:var(--muted);max-width:36em;}
.sigcard-body{margin:0 0 16px;}
.sigcard-body:last-child{margin-bottom:0;}
/* The finding, so it takes the largest size in the card. 18px rather than 16
   both suits what it is and buys width: 75 characters occupies 650px at this
   size against 565px at the old one. It still does not reach the card edge, and
   nothing sensible would: a single column filling 992px runs to 128 characters,
   and holding 75 across that width would need 27px type. */
.sigcard-sentence{
  margin:0 0 14px;font-size:18px;line-height:1.5;
  color:var(--paper);max-width:36em;
}
/* Across the card rather than down the left. Auto fitting columns, so four
   items sit in a row on a wide screen and fold to two and then one as the card
   narrows, without a breakpoint for each. */
.sigcard-detail{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));
  gap:12px 24px;margin:0 0 16px;
  padding:12px 0;border-top:1px solid var(--hairline-soft);
  border-bottom:1px solid var(--hairline-soft);
}
.sigcard-detail dt{
  font-size:12px;letter-spacing:.04em;text-transform:uppercase;
  color:var(--muted);margin:0 0 2px;
}
.sigcard-detail dd{margin:0;font-family:var(--mono);font-size:13px;color:var(--text);}
/* A light panel, not a dark one. The dark treatment measured 3.8 to 1, below
   the 4.5 minimum for body text, and read as something switched off rather
   than something to read. This is 8.7 to 1 with the heading at 14.6, and it
   reads as part of the finding rather than as a warning or an aside. */
/* Part of the card, not an attachment to it. It was an inset box stopping
   short of the card on every side, which read as an aside, and it is half the
   finding. So it runs out to the card's own edges by a negative margin equal to
   the card's padding, and takes that padding back, which puts its text on the
   same left edge as the text above it and closes the card off at the bottom.
   The teal rule on the left runs past it unbroken.

   Two columns, because that is the only way prose fills 992px and stays
   readable. `column-width` rather than a breakpoint, so the browser takes two
   columns where they fit and one where they do not, and the card can be any
   width. At 14px each column holds about 75 characters, which is why the size
   went up rather than down: at 13.5px a 480px column runs to 77. */
.sigcard-caveat{
  /* Out to the card's edges, and the padding taken back, so its text sits on
     the same left edge as the text above it. */
  margin:0 calc(-1 * var(--sigcard-pad-x));
  padding:16px var(--sigcard-pad-x);
  border:0;
  border-top:1px solid var(--hairline-soft);
  border-bottom:1px solid var(--hairline-soft);
  background:var(--surface-3);
  font-size:14px;line-height:1.65;color:var(--text);
  /* The panel itself is never capped: it spans the card at every width, which
     is what makes it read as part of the card rather than an inset note. */
  max-width:none;
}
/* The measure lives on the text, not on the panel. One column with a cap is the
   default and the fallback: a browser without container queries, or a card too
   narrow for two columns, gets readable text rather than a line the width of
   the card, which measured 110 characters and was worse than the inset box it
   replaced. 34em is about 74 characters at this size. */
.sigcard-caveat-text{margin:0;max-width:34em;}
/* Two columns once the card can give each one a proper measure. The number is
   the card's content box, and it is set from the arithmetic rather than picked:
   at 880 each column holds about 65 characters, and below that they get too
   narrow to read comfortably, so one measured column is the better answer.
   920 was wrong by eight pixels, which cost the two column layout at a 1280
   window, where the card's content box is 912. */
@container (min-width:880px){
  .sigcard-caveat-text{max-width:none;columns:2;column-gap:36px;}
}
/* Where the caveat is the last thing in the card, which is the shut state and
   any state with no controls under it, it closes the card off rather than
   ending in a rule with a strip of card below it. The bottom padding is taken
   from the card so the two cannot fall out of step. */
.sigcard-body:last-child .sigcard-caveat{
  margin-bottom:calc(-1 * var(--sigcard-pad-b));
  padding-bottom:var(--sigcard-pad-b);
  border-bottom:0;
  border-radius:0 0 10px 10px;
}
/* A heading orphaned at the foot of the first column reads as a new section. */
.sigcard-caveat strong{color:var(--paper);font-weight:600;break-after:avoid;}
.sigcard-refused{font-size:14px;line-height:1.65;color:var(--text);max-width:36em;}
.sigcard-refused .eyebrow{color:var(--control-ink);}
.sigcard-form{margin:0;}
/* Two ways to save an edited analysis (Sprint Enchilada E02). */
.savechoice{border:1px solid var(--hairline);border-radius:8px;padding:14px 16px;margin:16px 0 0;display:grid;gap:14px;background:var(--surface);}
.savechoice legend{font-weight:600;color:var(--paper);padding:0 4px;}
.savechoice-option{display:grid;gap:6px;margin:0;}
.savechoice-option .btn{justify-self:start;}
.savechoice-note{margin:0;max-width:40em;}
/* The history of an analysis. */
.history{margin-top:18px;border-top:1px solid var(--hairline-soft);padding-top:12px;}
.history summary{cursor:pointer;font-weight:600;color:var(--paper);}
.history-list{list-style:none;margin:12px 0 0;padding:0;display:grid;gap:12px;}
.history-event{border-left:2px solid var(--hairline);padding:2px 0 2px 12px;}
.history-when,.history-what,.history-conditions,.history-diff,.history-reopen{margin:0 0 4px;}
/* The regression card sits under the significance card and reads as its pair. */
.regcard{margin-top:16px;}
.regtable-wrap{overflow-x:auto;margin:0 0 14px;}
.regtable{min-width:520px;}
.regtable th,.regtable td{text-align:left;padding:6px 10px;border-bottom:1px solid var(--hairline-soft);}
.regtable .num{text-align:right;font-family:var(--mono);font-variant-numeric:tabular-nums;white-space:nowrap;}
/* The controls grid (BIO-127), for the significance card, the regression
   card and the regression chart's settings. Three rows per line of controls:
   labels, then the menus and the button with their tops on one line, then
   each menu's help in one wrapper under it. A field is display:contents, so
   its label, menu and help are cells of the grid and a long help line makes
   its own row taller without moving any menu. The layout follows the card's
   own width, never the window's: one line where they fit, two menus a row
   with the button at the end of the last row where they do not, stacked on a
   phone. Each slot's column and rows are set below, so nothing is placed by
   the order the markup happens to be in. */
.ctlwrap{container:ctl / inline-size;}
.ctlgrid{
  --ctl-h:42px;
  display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto;
  column-gap:14px;row-gap:0;align-items:start;
}
.ctlgrid > .field{display:contents;}
.ctlgrid > .field > *{grid-column:var(--col);min-width:0;}
.ctlgrid > .field > label,.ctlgrid > .field > .ctllabel{grid-row:var(--rl);align-self:end;}
.ctllabel{display:flex;align-items:center;gap:6px;}
.regref{margin-top:14px;}
.regref-row{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px 14px;}
.regref-row > .field{margin:0;min-width:min(220px,100%);}
.ctllabel > label{margin-bottom:0;}
.helptip-icon > summary{min-width:24px;min-height:24px;justify-content:center;}
.ctlgrid > .field > .sel,.ctlgrid > .field > .input,.ctlgrid > .field > .lbox{grid-row:var(--rc);}
.ctlgrid > .field > .ctlhelp{grid-row:var(--rh);}
.ctlgrid > .ctlgo{grid-column:-2 / -1;grid-row:var(--go-row);white-space:nowrap;}
.ctlgrid > .ctlafter{grid-column:-2 / -1;grid-row:calc(var(--go-row) + 1);margin-top:8px;}
.ctlgrid > .ctlafter:has(> [hidden]),.ctlgrid [hidden]{display:none;}
/* Two menus a row, the default. */
.ctlgrid > [data-slot="1"]{--col:1;--rl:1;--rc:2;--rh:3;}
.ctlgrid > [data-slot="2"]{--col:2;--rl:1;--rc:2;--rh:3;}
.ctlgrid > [data-slot="3"]{--col:1;--rl:4;--rc:5;--rh:6;}
.ctlgrid > [data-slot="4"]{--col:2;--rl:4;--rc:5;--rh:6;}
.ctlgrid > [data-slot="5"]{--col:1;--rl:7;--rc:8;--rh:9;}
.ctlgrid[data-slots="2"]{--go-row:2;}
.ctlgrid[data-slots="3"],.ctlgrid[data-slots="4"]{--go-row:5;}
.ctlgrid[data-slots="5"]{--go-row:8;}
.ctlgrid > .field > .ctlhelp{margin-bottom:10px;}
.ctlgrid > .field > .ctlhelp > :first-child{margin-top:6px;}
/* One height and one chevron for every menu and button on the line, the
   native menus (scripts off, and the significance card) and the list boxes
   alike. */
.ctlgrid .sel,.ctlgrid .input,.ctlgrid > .ctlgo{
  height:var(--ctl-h);box-sizing:border-box;font-size:14px;padding:0 12px;margin:0;
  width:100%;max-width:none;}
.ctlgrid > .ctlgo{width:auto;padding:0 18px;}
.ctlgrid select.sel,.ctlgrid .lbox-button{
  appearance:none;-webkit-appearance:none;padding-right:34px;
  background:var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%2317262C' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.ctlgrid .lbox-button::after{content:none;}
.ctlgrid .lbox-button{display:block;text-align:left;}
.ctlgrid select.sel:disabled,.ctlgrid .lbox-button:disabled{background-color:var(--surface-3);color:var(--muted);opacity:1;cursor:not-allowed;
  border-style:dashed;font-style:italic;}
/* Greyed until the outcome is chosen (BIO-158): a dashed edge and italic words as well as the
   ground, so it reads as not yet open without relying on a shade. */
.ctlsmall{font-size:13px;padding:6px 12px;}
/* One line where everything fits. */
@container ctl (min-width:32rem){
  .ctlgrid[data-slots="2"]{grid-template-columns:repeat(2,minmax(0,1fr)) auto;}
}
@container ctl (min-width:50rem){
  .ctlgrid[data-slots="3"],.ctlgrid[data-slots="4"]{--go-row:2;grid-template-columns:repeat(var(--n,4),minmax(0,1fr)) auto;}
  .ctlgrid[data-slots="3"]{--n:3;}
  .ctlgrid[data-slots="3"] > [data-slot="3"],.ctlgrid[data-slots="4"] > [data-slot="3"]{--col:3;--rl:1;--rc:2;--rh:3;}
  .ctlgrid[data-slots="4"] > [data-slot="4"]{--col:4;--rl:1;--rc:2;--rh:3;}
}
@container ctl (min-width:62rem){
  .ctlgrid[data-slots="5"]{--go-row:2;grid-template-columns:repeat(5,minmax(0,1fr)) auto;}
  .ctlgrid[data-slots="5"] > [data-slot="3"]{--col:3;--rl:1;--rc:2;--rh:3;}
  .ctlgrid[data-slots="5"] > [data-slot="4"]{--col:4;--rl:1;--rc:2;--rh:3;}
  .ctlgrid[data-slots="5"] > [data-slot="5"]{--col:5;--rl:1;--rc:2;--rh:3;}
}
/* A phone: one control under another, the button last and full width. */
@container ctl (max-width:26rem){
  .ctlgrid{display:flex;flex-direction:column;align-items:stretch;}
  .ctlgrid > .field{display:block;margin:0 0 4px;}
  .ctlgrid > .ctlgo{width:100%;}
}
.sigcard-controls .field{margin:0;min-width:0;}
.sigcard-controls label,.ctlgrid label{
  display:block;font-size:12px;letter-spacing:.04em;
  text-transform:uppercase;color:var(--muted);margin-bottom:4px;font-weight:600;}
/* The last ch cap on the card. 80ch measured 107 characters, for the same
   reason the others did: ch is the advance of a zero, wider than the average
   letter in this face, so a ch cap runs about a third longer than it reads. */
.sigcard-note{margin:10px 0 0;max-width:36em;}
/* Collapsed. The head stays, and so does anything already found: a result keeps
   its sentence and its caveat, and a refusal keeps its reason. */
.sigcard-shut{--sigcard-pad-b:16px;}
.sigcard-shut .sigcard-body{margin-bottom:0;}

@media (max-width:900px){
  /* Through the variables, so the caveat's bleed stays exactly one padding
     wide. Setting `padding` here directly left it overhanging the card by six
     pixels each side. */
  .sigcard{--sigcard-pad-x:16px;--sigcard-pad-b:16px;padding-top:16px;}
  /* The measure caps stay. Removing them let the sentence run to 95 characters
     on a laptop, which is worse than the desktop measure and the opposite of
     what a narrow rule is for. A ch cap never exceeds the available width. */
  .sigcard-sentence{font-size:15px;}
  .sigcard-head{flex-wrap:wrap;}
}

/* --- the question reader -------------------------------------------------- */
/* House treatment throughout. The tab's development badge is the same shape as
   the other small status pills on the platform rather than an invented style,
   because a marker that looks bespoke reads as decoration and this one is a
   statement of fact: the model is not part of the deployed environment. */
.qtab-dev{
  margin-left:6px;padding:1px 5px;border-radius:4px;
  font-family:var(--label);font-size:12px;font-weight:600;
  text-transform:uppercase;letter-spacing:.1em;
  background:var(--surface-3);color:var(--muted);
  border:1px solid var(--hairline-soft);
  vertical-align:middle;
}
.asknote{margin:0 0 16px;}
/* The info line and its account (23 October): one line beside the question
   mark, on its baseline, the icon at the line's end opening a small panel. */
.askinforow{gap:8px;flex:none;align-items:center;position:relative;}
/* The AI tab's heading (24 October): the label and the info line share the
   first row on one baseline; the title and the description below it are the
   panel's full width. Narrow, the info line wraps under the label, its text
   wrapping before the icon and "?" are parted. */
.qai .askhead-top{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:baseline;
  gap:6px 16px;margin-bottom:6px;}
.qai .askhead-label{margin:0;}
.qai .askinforow{flex:0 1 auto;min-width:0;align-items:baseline;}
.qai .askinfo{min-width:0;}
.qai .askinfo-controls{display:inline-flex;align-items:center;gap:8px;flex:none;align-self:center;}
.qai .askhead-title{margin:0 0 6px;}
.qai .askmeasure{max-width:none;margin:0;}
.askinfo{margin:0;font-size:13px;color:var(--muted);line-height:22px;}
.askinfo-more{position:relative;}
.askinfo-i{list-style:none;display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;
  border:1px solid var(--hairline);border-radius:50%;font-size:12px;font-weight:700;font-style:italic;
  color:var(--muted);cursor:pointer;font-family:Georgia,serif;}
.askinfo-i::-webkit-details-marker{display:none;}
.askinfo-i:hover,.askinfo-more[open] .askinfo-i{color:var(--paper);border-color:var(--muted);}
.askinfo-pop{position:absolute;right:0;top:30px;z-index:20;width:min(420px,80vw);padding:12px 14px;
  background:var(--surface);border:1px solid var(--hairline);border-radius:8px;box-shadow:0 8px 24px rgba(0,0,0,.18);
  font-size:13px;line-height:1.5;color:var(--text);}
.askinfo-pop p{margin:0;}
.askinfo-pop p + p{margin-top:8px;color:var(--muted);}
.askhead{margin-bottom:14px;}
/* The same measure the significance card settled on: 36em is about 75
   characters in this face at any size. */
.askmeasure{max-width:36em;}
.askform{margin:0 0 16px;}
.askinput{
  width:100%;min-height:76px;padding:10px 12px;font-size:14px;line-height:1.5;
  font-family:inherit;resize:vertical;
}
/* The question box on the Query datasets AI tab (.qai): one grey border in
   every state, the page's input border, and no green anywhere in the asking
   area (23 October). Focused, by keyboard, by a click or by an example
   filling it, the same border darkens to the ink grey in place of the
   outline drawn around it, which read as a second border. Focus stays
   visible: hairline to --muted is the strongest grey step the page has. */
.qai .askinput:focus,.qai .askinput:focus-visible{outline:none;border-color:var(--muted);box-shadow:none;}
.askrow{gap:10px;align-items:center;margin-top:10px;}
.askreading,.askrefusal{margin:0 0 16px;padding:16px 18px;}
.askreading{border-left:3px solid var(--brand-teal);}
.askrefusal{border-left:3px solid var(--control);}
.askconditions{margin:0;padding-left:18px;}
.askconditions li{margin-bottom:4px;font-size:14px;color:var(--text);}
.askrule{margin:0;font-size:12px;color:var(--muted);}
.askrule code{font-family:var(--mono);font-size:12px;}
.askexamples{margin:0 0 16px;}
.askexamples .plain{margin:0;padding-left:18px;}
.askexamples .plain li{
  margin-bottom:5px;font-size:13px;color:var(--muted);
  /* Copyable, so it reads as text to take rather than prose to skim. */
  font-family:var(--mono);
}
/* The AI tab's one result card (BIO-142): the conditions as the live
   result's chips, each with an x that drops it, at most two one line notes,
   and one row of actions. Ink on wash throughout, from the same tokens the
   rest of the platform holds at 7.0 or more. */
.askcard{margin:0 0 16px;padding:16px 18px;border-left:3px solid var(--brand-teal);}
.askcard-h{margin:0 0 10px;font-size:15px;font-weight:600;color:var(--paper);}
.askchips{margin:0 0 10px;}
.askchip{display:inline-flex;align-items:center;gap:4px;padding-right:4px;}
.askchip-x{border:0;background:none;color:var(--paper);font-size:15px;line-height:1;cursor:pointer;
  width:22px;height:22px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;}
.askchip-x:hover{background:var(--surface-3);}
.askchip-x:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:1px;}
.askwarn{margin:8px 0 0;font-size:13px;color:var(--control-ink);background:var(--control-wash);
  border:1px solid var(--control);border-radius:7px;padding:6px 10px;}
.askapprox{margin:8px 0 0;}
.askcontrols{margin-top:14px;flex-wrap:wrap;}
.asklink{border:0;background:none;padding:0;font:inherit;font-size:14px;color:var(--paper);
  text-decoration:underline;text-underline-offset:2px;cursor:pointer;}
.asklink:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}
.askerror{display:flex;flex-wrap:wrap;gap:6px 12px;align-items:baseline;margin:0 0 16px;padding:8px 12px;
  font-size:14px;color:var(--blocked-ink);background:var(--blocked-wash);border:1px solid var(--blocked);
  border-radius:7px;}
.askerror .asklink{color:var(--blocked-ink);}
.askexamples-fold > summary{cursor:pointer;font-size:13px;color:var(--paper);text-decoration:underline;
  text-underline-offset:2px;width:max-content;}
.askexamples-fold[open] > summary{margin-bottom:6px;}
.askexamples a,.askretry a{color:var(--paper);text-decoration:underline;text-underline-offset:2px;}
.askretry{margin:0;padding-left:18px;}
.askretry li{margin-bottom:5px;font-size:13px;}
.askearlier{margin:0 0 16px;}
.askearlier > summary{cursor:pointer;font-size:13px;color:var(--paper);text-decoration:underline;
  text-underline-offset:2px;width:max-content;}
.askearlier .plain{margin:8px 0 0;padding:0;list-style:none;}
.askearlier li{display:flex;flex-wrap:wrap;gap:4px 10px;align-items:baseline;padding:4px 0;font-size:13.5px;
  border-bottom:1px solid var(--hairline-soft);}
.askearlier-q{color:var(--text);min-width:0;overflow-wrap:anywhere;}

@media (max-width:900px){
  .askrow{flex-wrap:wrap;}
}
.askcompare{margin-top:14px;padding-top:12px;border-top:1px solid var(--hairline-soft);}
.askcompare-label{
  display:block;font-size:12px;letter-spacing:.04em;text-transform:uppercase;
  color:var(--muted);margin-bottom:6px;
}
.askcompare-input{flex:1 1 260px;min-width:0;height:34px;font-size:13px;}
.asked-note{margin-top:10px;}
/* The version, in the catalogue card's heading. Quieter than the name because
   the name is what a researcher looks for and the version is what tells two
   cards apart once they have found it. */
.cardversion{
  font-family:var(--mono);font-size:13px;font-weight:400;color:var(--muted);
  margin-left:6px;
}
.cardolder{margin:12px 0 0;max-width:36em;}
.askambig{
  margin:14px 0 0;padding:14px 16px;border-radius:10px;
  background:var(--surface-3);border:1px solid var(--hairline-soft);
}
.askambig-set{border:0;padding:0;margin:0 0 12px;}
.askambig-set legend{padding:0;margin-bottom:8px;font-size:13.5px;color:var(--text);max-width:36em;}
.askambig-choice{
  display:flex;align-items:center;gap:8px;padding:5px 0;
  font-family:var(--mono);font-size:12.5px;color:var(--text);
}
.askcontrols{align-items:center;gap:12px;flex-wrap:wrap;}
.askcontrols form{margin:0;}
.askblocked{max-width:36em;}

/* --- how a fragment control looks while it works -------------------------- */
/* House tokens throughout. The spinner is a rotating arc rather than an image
   or a library, and it is decorative: the disabled state and the live region
   carry the meaning for anybody not looking at it. */
.cspin{
  display:inline-block;width:11px;height:11px;margin-right:7px;
  vertical-align:-1px;
  border:2px solid currentColor;border-right-color:transparent;border-radius:50%;
  animation:cspin .6s linear infinite;
}
@keyframes cspin{to{transform:rotate(360deg);}}
/* Beside a menu or field that is updating (BIO-153). */
.cspin-beside{margin:0 0 0 8px;color:var(--brand-teal-lift);align-self:center;flex:none;}
select[aria-busy="true"],input[aria-busy="true"]{cursor:progress;}
.btn.is-working{opacity:.75;cursor:progress;}
.btn:disabled{cursor:not-allowed;}
@media (prefers-reduced-motion:reduce){
  /* A spinner that does not spin still says the control is working, because it
     appears only while it is. Motion is the part that is optional. */
  .cspin{animation:none;}
}

/* The line at the foot of the screen. Fixed, so it does not move the page and
   does not push anything about: it reports and gets out of the way. Never
   modal, never covering a control, and it disappears on its own. */
.panelmessage{
  position:fixed;left:50%;bottom:18px;transform:translateX(-50%);
  z-index:60;max-width:min(46em,calc(100vw - 32px));
  padding:11px 16px;border-radius:9px;
  background:var(--surface);border:1px solid var(--hairline);
  border-left:3px solid var(--brand-teal);
  box-shadow:0 2px 10px rgba(16,34,42,0.10);
  font-size:13.5px;line-height:1.5;color:var(--text);
}
/* Three kinds, and which one is used is the server's decision rather than the
   browser's: success, a refusal the researcher can act on, and a fault in the
   platform. Contrast computed rather than judged: 14.04:1, 15.71:1 and 9.69:1,
   all past AAA for body text. */
.panelmessage-good{
  background:#C8E6C9;color:#111111;border-color:#7CB57F;border-left-color:#2E7D32;
}
.panelmessage-warn{
  background:#FFE9A8;color:#111111;border-color:#D9B860;border-left-color:#B7791F;
}
.panelmessage-bad{
  background:#8A1017;color:#FFFFFF;font-weight:600;
  border-color:#6B0C12;border-left-color:#FFFFFF;
}
/* A reference is a thing to copy, so it is set in the mono face wherever it
   appears in one of these. */
.panelmessage code{font-family:var(--mono);font-size:12.5px;}
@media (max-width:640px){
  .panelmessage{left:16px;right:16px;transform:none;max-width:none;}
}

/* ---- Live feeds and dashboards -------------------------------------------
   Appended. No rule above this line is edited: the dashboard is a new app and
   the brief is that nothing demonstrated may change. */

/* The dashboard takes the whole viewport rather than the reading measure the
   rest of the platform is set to. It is built to be projected, and a map and
   five supplier panels inside a centred column is a screen nobody at the back
   can read.

   Reached with `:has()` rather than by editing base.html, because nothing
   outside the dashboard may change and the shell is shared with every other
   screen. A browser without `:has()` renders the dashboard exactly as every
   other screen renders, centred and boxed, which is a smaller screen rather
   than a broken one. */
body:has(.app-fullbleed) .stage{max-width:none;margin:0;padding:0;}
body:has(.app-fullbleed) footer{display:none;}
.app-fullbleed{
  border:0;border-radius:0;box-shadow:none;
  /* Fixed to the viewport rather than merely at least as tall as it. The
     dashboard's own panels scroll inside themselves; the page does not, because
     a screen built for a projector that has to be scrolled is a screen the back
     of the room cannot read. */
  height:100vh;max-height:100vh;overflow:hidden;
  display:flex;flex-direction:column;
  /* A short ease in, rather than the page appearing at once. The shell's own
     entrance animation only runs at sign in; this one runs whenever the
     dashboard is opened, which is the moment it is put on a projector. */
  animation:dashin .22s cubic-bezier(.33,.68,.28,1) both;
}
.app-fullbleed.leaving{animation:dashout .16s ease-in both;}
@keyframes dashin{from{opacity:0;transform:translateY(6px);}to{opacity:1;transform:none;}}
@keyframes dashout{from{opacity:1;}to{opacity:.4;}}
@media (prefers-reduced-motion: reduce){
  .app-fullbleed,.app-fullbleed.leaving{animation:none;}
}
.app-fullbleed .body{flex:1;min-height:0;overflow:hidden;}
.app-fullbleed .rail{overflow-y:auto;}

/* The dashboard's own layout.

   A grid rather than a stack, because the brief is that on a large display the
   counters, the map, the suppliers, the two charts and the dataset panel are
   visible together without scrolling. Rows that size to their content, and one
   row that takes what is left and gives it to the map.

   `min-height:0` on the grid children is what lets that last row actually
   shrink: a grid item defaults to its content's minimum, so without it the map
   pushes the page taller instead of the panel scrolling inside itself. */
/* Rows that size to their content, and the content area scrolls if it must.
   
   It was a `1fr` row with the whole thing clipped, which worked until the
   panels were given minimum heights: on a 14 inch laptop the map's minimum was
   taller than the row it was in, so it spilled over the regional table and drew
   on top of it. A minimum that a layout can overrule is not a minimum.
   
   So the minimums win and this scrolls instead. The topbar, the perimeter
   banner and the rail stay put either way, because they are outside this box: a
   dashboard whose header scrolls away has stopped being one, and that was the
   thing worth protecting rather than the absence of a scrollbar. */
.app-wide .main.main-wide{
  max-width:none;padding:10px 20px 8px;
  display:grid;grid-template-rows:auto auto auto auto auto;
  gap:8px;min-height:0;overflow-y:auto;
}
.app-wide .main.main-wide > *{min-width:0;}
.fsynthline{
  margin:0;font-size:12.5px;line-height:1.45;color:var(--muted);
  background:#FFF6E0;border-left:3px solid #E0B94A;border-radius:0 6px 6px 0;
  padding:7px 12px;
}
.fsynthline strong{color:var(--text);}

.fhead{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;margin:0;}
.flive{display:inline-flex;align-items:center;gap:7px;font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:var(--brand-teal-lift);font-weight:600;}
.flive-idle{color:var(--muted);}
.flive-behind{color:var(--control-ink);}
/* How current the research copy is. Plain text while it is, and a notice in
   the chart-note amber when it is not, because a copy that stopped is a thing
   to read before any figure under it. */
.ffresh{margin:0 0 8px;font-size:12.5px;color:var(--muted);}
.fstale{margin:0 0 10px;font-size:13px;line-height:1.45;color:var(--control-ink);
  background:var(--amber-wash,#fbf3dd);border:1px solid var(--amber-line,#ecdca6);
  border-radius:7px;padding:8px 12px;}
.fdot{width:9px;height:9px;border-radius:50%;background:currentColor;}
.flive:not(.flive-idle) .fdot{animation:fpulse 2s ease-in-out infinite;}
@keyframes fpulse{0%,100%{opacity:1;}50%{opacity:.35;}}
@media (prefers-reduced-motion: reduce){.flive .fdot{animation:none;}}
.fsynth{display:inline-block;font-size:12px;letter-spacing:.08em;text-transform:uppercase;
        background:#FFE9A8;color:#111111;border-radius:4px;padding:2px 7px;font-weight:700;}
.fsynthnote{margin:10px 0 18px;}
.fscope{margin:0 0 12px;}

.fcounters{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:0;}
.fcounter{background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:10px 14px;}
.fcounter p{margin:0 0 2px;font-size:12px;letter-spacing:.09em;text-transform:uppercase;color:var(--label);}
.fcounter .v{display:block;font-size:clamp(26px,2.2vw,40px);line-height:1.05;font-weight:700;color:var(--text);}
.fcounter .u{font-size:12px;color:var(--muted);}
.fasat{margin:0;font-size:12px;}
.fallowance{margin:0;font-size:12px;}

/* Everything that moves, as its own grid so the row it sits in can shrink. */
/* The query bar, the counters, the as-at line, the panels, then the regional
   table. Five children, five rows.
   
   It had four rows and `min-height:0`, which is what let the table paint
   outside the panel that holds it. `min-height:0` tells a grid item it may
   shrink below its own content, and this box is inside a grid whose height is
   the viewport, so it did: the container came out 523px tall while its rows
   summed to 1124, and everything past the fold drew over what followed. The
   fifth row was missing on top of that, so the table had no row of its own.
   
   Measured before the fix, at 1512: 13 of 20 table rows had bounds outside the
   panel's. After: none. */
#feedlive{display:grid;grid-template-rows:auto auto auto auto auto;gap:8px;}
/* The regional table sits below the three panels, never over them.
   
   At 1512 the table drew on top of the map, the suppliers and the chart. The
   cause was the panels being given minimum heights inside a grid row that was
   shorter than they were, so they spilled out of their row into the next one.
   Grid does not clip an overflowing item, it lets it draw over what follows.
   
   `align-items:start` and a row that sizes to its tallest child is the fix:
   the panel row is as tall as the panels need, and the table starts after it.
   At 1920 the layout is unchanged, which is the requirement. */
/* The panel row has a floor and a ceiling, and each panel scrolls inside it.
   
   Not tidiness: a control that made the row shorter made the whole page
   shorter, and a page shorter than the current scroll position is clamped by
   the browser. Restoring a scroll offset cannot beat that, because there is
   nowhere to restore it to. Measured, before this: changing the window moved
   the reader 65px and picking a supplier moved them 115px, with nothing in the
   handler touching the scroll.
   
   So the height stops changing. Same reasoning as pinning the pages of the
   reader's history: remove the height change and the clamp goes with it
   (constraint 22). */
/* The three panel row.
   
   **One height for the row, and every panel in it clips its own content.**
   
   This row has now produced the same fault three times, each time in a
   different mechanism and each time looking like a new bug: a grid with four
   rows for five children, a flex item shrunk below its content by
   `min-height:0`, and a panel given `overflow-y:visible` so the map would not
   scroll. Every one of them is the same shape underneath, which is a container
   whose height is fixed while its content is taller and which does not clip.
   The content then draws over whatever is below it, and because two panels are
   both painted the rows and tiles read through each other.
   
   So the invariant is stated here rather than restored again: the row has one
   height, and each of the three panels is exactly that height and scrolls what
   does not fit. A panel cannot spill because there is nowhere for the overflow
   to go. That is asserted at four widths in the tests rather than left to be
   noticed (constraint 22).
   
   The height is a viewport measure rather than a fixed one, so the row is
   proportionate on a laptop and on a 24 inch display without a breakpoint
   choosing between them. */
.fgrid{--fgrid-row:clamp(520px,58vh,660px);align-items:stretch;min-height:430px;}
.fcol{align-self:stretch;min-height:0;}
.fmap,.fcol-suppliers,.fcol-charts{
  height:var(--fgrid-row);max-height:var(--fgrid-row);overflow-y:auto;min-height:0;
}
/* The right column holds two panels and they split the row between them, so
   the three columns read as three columns rather than as three panels of
   different lengths. Each scrolls its own content. */
.fcol-charts{display:flex;flex-direction:column;gap:10px;}
.fcol-charts > .fpanel{flex:1 1 0;min-height:0;overflow-y:auto;}

/* Two columns by default, three once there is room for one.
   
   On a 24 inch display the map was tall and half empty while the side column
   scrolled, which is the width being wasted and the height being fought over at
   the same time. Splitting the suppliers from the charts at 1600px uses the
   width the screen actually has and takes the pressure off the height, so
   everything is visible together rather than one panel scrolling inside
   itself. */
.fgrid{
  display:grid;grid-template-columns:minmax(0,1.9fr) minmax(300px,1fr);
  gap:12px;align-items:stretch;
}
@media (min-width: 1400px){
  .fgrid{grid-template-columns:minmax(0,1.5fr) minmax(260px,.85fr) minmax(260px,.95fr);}
}
/* Two columns, with the suppliers above the charts on the right and the map
   spanning both rows. Placed explicitly rather than left to auto flow, which
   wrapped the charts underneath the map and left the right column half empty. */
@media (min-width: 1181px) and (max-width: 1399px){
  .fgrid{grid-template-rows:auto minmax(0,1fr);}
  .fcol-map{grid-column:1;grid-row:1 / span 2;}
  .fcol-suppliers{grid-column:2;grid-row:1;}
  .fcol-charts{grid-column:2;grid-row:2;}
}
.fcol{min-width:0;min-height:0;display:flex;flex-direction:column;gap:10px;}
/* A suppliers panel is as tall as its contents, never as tall as the space it
   was given. The charts column is the other way round, and says so above: its
   two panels share the row rather than taking their own heights.
   
   `.fcol` sets `min-height:0`, which lets a flex item shrink below its own
   content. The suppliers panel was 520px tall holding 586px of list, and
   because it does not clip, the overflow spilled into the scroller around it.
   So the scroll range came from a squashed child rather than from the list,
   and the scroller had no relationship to what was in it. Measured: box 520,
   content 586.
   
   `flex:0 0 auto` makes the panel take its natural height, so the scroller's
   scroll height is the content's height and scrolling stops at the last
   supplier. */
.fcol-suppliers > .fpanel{flex:0 0 auto;}
/* And a wheel that reaches the end of one of these stays there rather than
   carrying on into the page behind it, which is what makes a short scroll feel
   like it never arrives anywhere. */
.fmap,.fcol-suppliers,.fcol-charts,.ftablewrap{overscroll-behavior-y:contain;}
.fcol-suppliers,.fcol-charts{position:relative;}
.fpanel{
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;
  padding:11px 14px;margin:0;
}
.ffreeze{margin:0;}

.fmap{
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;
  padding:12px 14px;flex:1;position:relative;
}
.fmap-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:8px;}
/* Events by region, the graphic view.
   
   Each nation is its own bordered container, so the nations read as separate
   blocks rather than one continuous grid. The containers are equal width cells
   of one grid and the regions inside are a second grid of fixed height cells,
   so a nation with five regions and one with two are the same width and line
   up on the same rows. */
/* One height per row, so the containers line up across the grid.
   
   `align-items:start` let each container shrink to its own contents, so a
   nation with five regions stood taller than its neighbours and nothing lined
   up. Stretching them makes every container in a row the height of the tallest
   in that row, which is what "consistent sizing" has to mean when nations hold
   different numbers of regions. */
.fmap-nations{
  display:grid;grid-template-columns:repeat(auto-fill,minmax(268px,1fr));
  gap:12px;align-items:stretch;
}
.fmap-nation{
  min-width:0;border:1px solid var(--hairline);border-radius:9px;
  padding:10px 11px 11px;background:var(--surface);
}
.fmap-nation-name{margin:0 0 8px;font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:var(--label);}
.fmap-regions{
  display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));gap:6px;
}
/* One height for every cell whatever state it is in, so a withheld region does
   not make its row a different size from the counts beside it. */
.fmap-cell{
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  gap:2px;min-height:58px;padding:6px 4px;border-radius:6px;
  border:1px solid var(--hairline);background:var(--teal-wash);text-align:center;
}
/* Both drawn in the same near black rather than the count in the text colour
   and the label in the muted one.

   The hierarchy is size and weight, not colour, because colour is the budget
   that is already spent here: the label sat in --muted, which is 1.7:1 against
   the darker end of the tile range and unreadable. A ratio measured across the
   whole fill range is asserted in the tests rather than judged by eye. */
.fmap-count{font-size:19px;font-weight:700;color:#111111;line-height:1.05;}
.fmap-label{font-size:12px;font-weight:400;color:#111111;letter-spacing:.04em;}
/* Genuinely no reports. A real figure, so it is drawn as one: plain ground and
   a lighter number, never a gap and never the withheld treatment. */
.fmap-cell-zero{background:var(--surface-2);}
/* Darker than --muted, which is 4.1:1 on this ground. The zero is the signal
   that separates "reported nothing" from "not shown", so it is held to 7:1
   like body text rather than to the 3:1 large bold text could get away with. */
.fmap-cell-zero .fmap-count{color:#455860;font-weight:600;}
/* Withheld. The house treatment, the same dashed control-coloured chip the
   cohort table and every chart already use for a withheld cell, so a reader
   who has seen one anywhere else recognises this one. No number in it. */
.fmap-cell-withheld{
  background:var(--control-wash);border-style:dashed;border-color:var(--control);
}
.fmap-cell-withheld .withheld{
  /* The shared chip's ink is --control, which is 3.38:1 on this wash and fails
     (ISSUES.md BIO-51). Darkened for this use rather than left to inherit a
     ratio that does not pass. Measured 6.94:1. */
  font-size:12px;letter-spacing:.1em;padding:1px 6px;border:0;background:none;
  color:#6B4C11;
}
.fmap-cell-withheld .fmap-label{color:#5F450D;}
.fmap-empty,.fmap-withheld{margin:10px 0 0;}

/* The map component. One implementation on two surfaces.
   
   Every colour is a custom property with the light chrome as its default. The
   dark surface redefines the same six and nothing else, which is the whole of
   the theming: no second set of rules, and nothing that can be changed on one
   surface and forgotten on the other. */
.geomap{
  /* The research panel is one of three in a row with a shared height, so the
     map has to leave room for the breadcrumb above it and the withheld note
     below. At 560 the panel overflowed by 62px and the legend was squeezed to
     175px, which wrapped its prose into a ribbon three words wide. */
  --gm-max-height:380px;
  --gm-ink:var(--brand-teal);
  --gm-hover:var(--brand-teal);
  --gm-context:#9DB2BC;
  --gm-context-fill:rgba(255,255,255,.001);
  --gm-edge:#FFFFFF;
  /* Every coastline and land border, one colour on this surface. */
  --gm-line:#8FA3AD;
  /* An area that reported nothing, and one whose count is not shown. Neither
     is invisible and neither is greyed out of the design: they are two facts,
     drawn as two things, in the same palette as everything else here. */
  --gm-control-bg:rgba(255,255,255,.92);
  --gm-control-ink:var(--text);
  --gm-control-line:var(--hairline);
  --gm-zero:#C3D0D7;
  --gm-withheld:#AD8628;
  --gm-withheld-ground:#FAF3E4;
  --gm-base-opacity:.85;
  --gm-base-filter:none;
  position:relative;
}
.geomap-dark{
  /* The operating picture gives the map a panel of its own, so it fills it
     edge to edge rather than sitting in the middle of it. Capping the width at
     what the tallest allowed box would be left 395px of empty panel either
     side of an 801px map in a 1196px column. The frame is fitted to whatever
     shape the panel is, so filling the width costs no letterboxing. */
  --gm-max-height:560px;
  --gm-ink:var(--op-accent);
  --gm-hover:var(--op-accent);
  --gm-context:#48626C;
  --gm-context-fill:rgba(11,20,24,.001);
  --gm-edge:#0B1418;
  /* Every coastline and land border, one colour on this surface. */
  --gm-line:#6A8791;
  --gm-control-bg:rgba(17,30,36,.92);
  --gm-control-ink:var(--op-text);
  --gm-control-line:var(--op-line);
  --gm-zero:#33454C;
  --gm-withheld:#D2A64A;
  --gm-withheld-ground:#3A3020;
  /* The relief, on a dark panel.
     
     Inverting it and then dropping it to 0.4 opacity took it to nothing: the
     map read as flat shapes on flat dark and the terrain the reference gets its
     credibility from was there in the markup and invisible on the screen.
     Darkened and cooled instead of inverted, and left at full opacity so it is
     actually seen. One image still, two surfaces. */
  --gm-base-opacity:1;
  /* Inverted, then lifted rather than dimmed. Inverting the light source image
     and multiplying brightness by 0.42 put the whole relief between 0 and 0.16
     luminance, which is black on a panel that is already nearly black: the
     terrain was in the markup and absent from the screen. Land now sits around
     0.12 to 0.35 and the sea below the panel, so the shapes still read as the
     brightest thing on it. */
  /* As an SVG filter in the map's own defs (_geomap.html), the same chain:
     WebKit ignores CSS filter functions on SVG content. */
  --gm-base-filter:url(#gm-base-dark);
  /* Night operations rather than a pale terrain map.
     
     The reference uses satellite tiles, which are ruled out: every tile request
     tells somebody else's server which area is being looked at. What is left is
     to darken the relief until it reads as ground at night and put real vector
     detail on top of it, which is what the layers below are. Brightness came
     down from 0.95 to 0.72 and contrast up, so the relief is present as texture
     and the towns, roads and markers are the bright things on it. */

  /* The bundled detail. Every one of these is drawn under the shapes and the
     markers, so nothing crosses a cluster. */
  --gm-urban:#2E4756;
  --gm-water:#1D4A5E;
  --gm-rail:#4A5A63;
  --gm-road:#5A4B3A;
  --gm-motorway:#8A6C42;
  --gm-label:#C6D6DE;
  --gm-label-ink:#0B1418;
}
/* Panning. The plot scrolls, so a pointer drag and a trackpad both move the
   map, and the scrollbars say there is more to see. */
/* The map fills its panel and the frame moves inside it. It used to be a
   drawing wider and taller than the panel inside a scrolling box, so it opened
   showing about a quarter of itself. */
/* The dark surface's map takes the whole panel. The research view's shares a
   column with a legend, so it keeps the projection's proportions and is
   centred in what is left. */
.geomap-dark .geomap-plot{
  width:100%;max-width:none;aspect-ratio:auto;
  /* Tall enough that the frame crops rather than throws away half of Europe.
     A shallower panel means a harder crop, and at 2.05 to 1 the frame kept only
     fourteen degrees of latitude and Ukraine fell out of the bottom of it. */
  /* Where there is no band (the stacked layout below 1180 wide), a height of
     its own. With a band, the plot takes whatever height the band leaves it
     (the band rules below), and the map fits its frame to that. */
  height:clamp(340px, calc(var(--op-band, 760px) - 82px), 700px);
}
.geomap-plot{
  position:relative;overflow:hidden;cursor:grab;touch-action:none;
  /* A definite height, and the projection's own proportions.
     
     `height:100%` resolved against a parent with no height of its own, so the
     panel grew to the whole drawing and ran off the screen with only Norway in
     view. Given a height but the column's full width it was a 2.5:1 strip,
     which the projection cannot fill: the window is 1.43:1, so a third of the
     panel was empty either side whatever frame was chosen.
     
     So the box takes the projection's shape and is centred in whatever column
     it is given. The map fills it, and the panel is around the map rather than
     the map being a band across the panel. */
  /* One rule for two very different columns.
     
     The operating picture gives the map about 1200px and the research view
     about 600, and a fixed height with a free width letterboxed the narrow one
     exactly as a fixed width letterboxed the wide one. Capping the width at
     what the tallest allowed box would be lets the aspect hold in both: the
     wide column stops at 801 by 560, the narrow one takes 603 by 421, and
     neither has empty bands down its sides. */
  --gm-max-height:560px;
  aspect-ratio:1000/699;
  width:min(100%, calc(var(--gm-max-height) * 1000 / 699));
  height:auto;margin-inline:auto;
}
@media (max-width:900px){
  /* Too narrow to hold the shape. Width first, and let the height follow. */
  .geomap-plot{width:100%;}
}
.geomap-dragging{cursor:grabbing;}
/* Zoom, top left, over the map, on both surfaces. */
.geomap-zoom{
  position:absolute;top:10px;left:10px;z-index:3;
  display:flex;flex-direction:column;gap:4px;
}
/* The layers cog shares the zoom buttons' rule rather than copying it, so the
   two corners read as a pair and cannot drift apart. */
.geomap-zoom button,.geomap-layers-toggle{
  width:40px;height:40px;display:flex;align-items:center;justify-content:center;
  font-size:19px;line-height:1;cursor:pointer;
  background:var(--gm-control-bg);color:var(--gm-control-ink);
  border:1px solid var(--gm-control-line);border-radius:7px;
  font-family:inherit;
}
.geomap-zoom button:last-child{font-size:13px;}
.geomap-zoom button:hover,.geomap-layers-toggle:hover,
.geomap-layers-toggle[aria-expanded="true"]{border-color:var(--gm-hover);color:var(--gm-hover);}
.geomap-zoom button:focus-visible,
.geomap-layers-toggle:focus-visible{outline:2px solid var(--gm-hover);outline-offset:2px;}
/* Map layers, top right, over the map. The column runs the plot's height and
   lets presses through, so only the cog and the open panel take them; the
   panel is positioned inside it and scrolls within the plot, so opening it at
   the smallest band changes nothing about the map, the band or the cards. */
.geomap-layers{
  position:absolute;top:10px;right:10px;bottom:10px;z-index:4;
  width:40px;pointer-events:none;
}
.geomap-layers > *{pointer-events:auto;}
.geomap-layers-panel{
  position:absolute;top:46px;right:0;width:224px;max-height:calc(100% - 46px);
  overflow:auto;box-sizing:border-box;padding:8px 10px 6px;
  background:var(--gm-control-bg);color:var(--gm-control-ink);
  border:1px solid var(--gm-control-line);border-radius:8px;
  box-shadow:0 10px 26px rgba(0,0,0,.34);
}
.geomap-layers-panel[hidden]{display:none;}
/* Placed against the window by static/js/map-layers.js when it opens, so it
   can be taller than the map. Where even the window is too short to hold every
   row, the foot of it says so until the reader has scrolled to the end. */
.geomap-layers-panel.has-more:not(.at-end)::after{
  content:"More below";position:sticky;bottom:-6px;display:block;
  margin:2px -10px -6px;padding:12px 10px 5px;text-align:center;
  font-size:10px;font-weight:600;letter-spacing:.12em;text-transform:uppercase;
  background:linear-gradient(rgba(0,0,0,0),var(--gm-control-bg) 55%);
}
.geomap-layers-head{
  margin:0 0 4px;font-size:12px;font-weight:600;letter-spacing:.12em;
  text-transform:uppercase;opacity:.72;
}
.gmlayer{display:flex;align-items:center;gap:8px;padding:3px 0;font-size:12px;cursor:pointer;}
.gmlayer input{margin:0;flex:none;}
.gmlayer-swatch{flex:none;width:18px;height:18px;display:inline-flex;}
.gmlayer-swatch svg{width:18px;height:18px;overflow:visible;}
.gmlayer-glyph{
  font-size:12px;font-weight:600;text-anchor:middle;fill:var(--gm-label);
  paint-order:stroke fill;stroke:var(--gm-label-ink);stroke-width:2.4;stroke-linejoin:round;
}
.geomap-plot.geomap-dragging{cursor:grabbing;}
.geomap-svg{display:block;width:100%;height:100%;}
.geomap-base{opacity:var(--gm-base-opacity);filter:var(--gm-base-filter);}
/* A country with no feed. A fill a pointer can find and nothing else: no
   shading, no link and no stroke; its outline is the boundary layer's. It takes
   a pointer so hovering names it, which is the only way the legend's "a bare
   outline has no feed here" is any use to a reader who cannot tell which
   country they are looking at. `fill` is set rather than left transparent so
   the whole shape is hoverable and not just its edge. */
.geomap-context{
  fill:var(--gm-context-fill);stroke:none;
}
.geomap-context.fhovered{fill:var(--gm-hover);fill-opacity:.14;}
/* Fills carry no stroke, on either surface, in any state. Every line is drawn
   once, by the boundary layer, from the same arcs the fills are made of; a
   stroke on a fill is a second copy of a border its neighbour also draws, which
   is the doubling this replaced. Hovering lightens a fill rather than
   outlining it, for the same reason. */
.geomap-shape path,.geomap-zero path,.geomap-withheld path{stroke:none;}
.geomap-shape path.fhovered{filter:brightness(1.3);}
.geomap-pick{cursor:pointer;}
/* The boundary layer. One colour and one weight for every land border and
   every coastline, round at every join and end so an arc meets the next
   without a notch, and one pixel at every zoom. The region lines are the
   compass cuts inside a nation, drawn in the panel's own colour so they read
   as a parting in the shading rather than as a border. */
.gm-lines{pointer-events:none;}
.gm-line{
  fill:none;stroke-linejoin:round;stroke-linecap:round;
  vector-effect:non-scaling-stroke;shape-rendering:geometricPrecision;
}
.gm-line-coast,.gm-line-border{stroke:var(--gm-line);stroke-width:1;}
.gm-line-region{stroke:var(--gm-edge);stroke-width:1;}
.geomap-empty{font-size:12px;color:var(--muted);margin:10px 0 0;}
.geomap-dark .geomap-empty{color:var(--op-muted);}

@media (max-width:640px){
  .fmap-nations{grid-template-columns:1fr;}
  .fmap-regions{grid-template-columns:repeat(auto-fill,minmax(72px,1fr));}
}

.fsuppliers{list-style:none;margin:0;padding:0;}
.fsupplier{padding:6px 0;border-bottom:1px solid var(--hairline-soft);}
.fsupplier:last-child{border-bottom:0;}
.fstate{font-size:12px;letter-spacing:.06em;text-transform:uppercase;color:var(--brand-teal-lift);font-weight:600;}
.fsupplier-off .fstate{color:var(--muted);}
.fsupplier-quiet .fstate{color:#6C5300;}
/* A rate far above the rest of the feed. Measured against the panel in the
   tests like every other state colour. It reads as elevated without reading as
   an alarm, because what it describes is how much data is arriving. */
.fsupplier-high .fstate{color:#7F4400;}
/* The synthetic marker, small enough to sit inside a panel heading and dark
   enough to survive a screenshot. It is not decoration: a panel that can be
   cropped out of the page has to carry the sentence with it. */
.finvented{
  display:inline-block;margin-left:6px;padding:1px 6px;border-radius:3px;
  background:#F3E7C8;color:#604400;font-size:12px;font-weight:700;
  letter-spacing:.08em;text-transform:uppercase;vertical-align:middle;
}

.fbars{display:flex;align-items:flex-end;gap:3px;height:74px;}
.fbar{flex:1;min-height:2px;background:var(--brand-teal);border-radius:2px 2px 0 0;opacity:.85;}
.fbands{list-style:none;margin:0;padding:0;}
.fbands li{margin-bottom:7px;}
.fband{height:7px;background:var(--hairline-soft);border-radius:4px;overflow:hidden;}
.fband span{display:block;height:100%;background:var(--brand-teal);}

.fqueries{margin:0;}
.fquerybar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;}
.fquerylist{display:flex;flex-wrap:wrap;gap:7px;align-items:center;}
.fpresets{display:flex;flex-wrap:wrap;gap:7px;}
.fpresets form{display:inline;}
.fq-add{cursor:pointer;font-family:inherit;border-style:dashed;}
.fq-add:hover{border-color:var(--brand-teal);border-style:solid;}
.fscope{font-size:12px;color:var(--muted);}
.fq-wrap{display:inline-flex;align-items:center;}
.fq{display:inline-block;padding:5px 11px;border-radius:999px;border:1px solid var(--hairline);
    font-size:13px;text-decoration:none;color:var(--text);background:var(--surface);}
.fq-on{border-color:var(--brand-teal);box-shadow:inset 0 0 0 1px var(--brand-teal);font-weight:600;}
/* The query palette. Fixed, and chosen to stay apart from each other on a
   projector: a researcher typing a hex value could pick one that vanishes on
   the screen this is built for. Text stays var(--text) on a light wash rather
   than being drawn in the colour, so contrast does not depend on the choice. */
.fq-teal{background:#D7ECEA;}
.fq-amber{background:#FFE9A8;}
.fq-violet{background:#E4DCF4;}
.fq-rose{background:#F7DCE2;}
.fq-slate{background:#DEE4EA;}
.fq-moss{background:#DFEBD5;}
.fq-drop{display:inline;}
.fq-x{background:none;border:0;cursor:pointer;color:var(--muted);font-size:16px;line-height:1;padding:0 4px;}
.fq-x:hover{color:var(--text);}
.fqadd{margin-top:12px;}
.fqadd > summary{cursor:pointer;font-size:12.5px;color:var(--brand-teal-lift);}
/* The Add a query row.
   
   Five controls on one baseline. They were aligned on flex-end, which lines up
   the bottom edge of whatever each column happens to contain: the value column
   carries a hint paragraph under its control and the others do not, so its
   control sat a line higher than the rest. Aligning the tops of equal height
   rows and letting the hint hang below fixes it at the cause rather than by
   nudging one column. */
.fqform{display:flex;flex-wrap:wrap;gap:12px;align-items:flex-start;margin-top:12px;}
.fqform .field{margin:0;display:flex;flex-direction:column;min-width:0;}
.fqform .field > label{
  display:block;margin-bottom:5px;line-height:1.2;min-height:15px;
}
/* One height for every control in the row, so the five line up whatever kind
   of input each one is. */
.fqform .sel,.fqform .input{height:38px;box-sizing:border-box;}
.fqform select[multiple].sel{height:auto;min-height:38px;}
.fqvalues{position:relative;}
/* The hint hangs below the row rather than growing the column, which is what
   pushed the value control out of line with the other four. */
.fqform .fqhint{
  position:absolute;top:100%;left:0;margin:4px 0 0;font-size:13px;
  white-space:nowrap;
}
/* The button sits on the controls' baseline, not on the labels'. */
.fqform > .btn{margin-top:20px;height:38px;}
@media (max-width:760px){
  .fqform{flex-direction:column;align-items:stretch;}
  .fqform .field{width:100%;}
  .fqform .fqhint{position:static;white-space:normal;}
  .fqform > .btn{margin-top:4px;width:100%;}
}

/* The Add catalogue dialogue. */
.addcat-panel{padding-top:4px;}
.catlive,.catidle{display:inline-flex;align-items:center;gap:6px;font-size:12px;letter-spacing:.07em;
         text-transform:uppercase;color:var(--brand-teal-lift);font-weight:700;white-space:nowrap;}
.catidle{color:var(--text);}
/* The Nightjar TCCC Intake Feed's records menu on its card (6 November 2026). */
.feedcog > summary.feedcog-btn{padding:6px 8px;}
.feedcog > summary.feedcog-btn::after{content:none;}
.feedcog-menu{left:auto;right:0;width:300px;}
.feedcog-state{margin:4px 6px 8px;font-weight:600;color:var(--paper);}
.feedcog-hint{margin:0 6px 6px;}
.feedconfirm > summary{list-style:none;cursor:pointer;}
.feedconfirm > summary::-webkit-details-marker{display:none;}
.feedconfirm-form{margin:8px 6px 4px;display:flex;flex-direction:column;gap:8px;}
.feedconfirm-form p{margin:0;font-size:13px;}
.opplay-form{display:inline-flex;margin:0;}
/* Only a feed with records arriving pulses (BIO-147); idle is a still dot. */
.catlive .fdot{width:8px;height:8px;animation:fpulse 2s ease-in-out infinite;}
.catidle .fdot{width:8px;height:8px;opacity:.7;}
@media (prefers-reduced-motion: reduce){.catlive .fdot{animation:none;}}

/* A 14 inch laptop is the case that must still work: 1512 wide, and after the
   browser chrome about 860 of usable height. Everything is reachable, with the
   map and the right column scrolling inside themselves where they have to.
   Tighter than the 24 inch case on purpose: the alternative is a page that
   scrolls as a whole, and a dashboard whose header scrolls away is a dashboard
   that has stopped being one. */
/* At 1920 the map is the thing worth looking at, so it gets height. The other
   two panels in the row keep their own ceiling and simply have room to spare. */
/* The map's frame, sized from the row it sits in rather than from a number.
   
   The map view has to fit inside the panel without the panel scrolling, and
   the panel is now one row tall whatever the width, so the frame is the row
   less the breadcrumb, the heading and the note beneath it. Written as one
   subtraction, so changing the row height moves the map with it. */
.geomap-light{--gm-max-height:calc(var(--fgrid-row,520px) - 190px);}

@media (max-width: 1599px){
  .fcounter .v{font-size:clamp(24px,1.9vw,32px);}
  .fcounter{padding:8px 12px;}
  /* 236 rather than 190. The nations are bordered containers now with a grid
     of region cells inside, and at 190 a container was too narrow to hold two
     cells side by side, so a five region nation drew a column of five. */
  .fmap-nations{grid-template-columns:repeat(auto-fill,minmax(236px,1fr));gap:10px;}
  .fbars{height:62px;}
  .fsynthline{font-size:12px;padding:6px 11px;}
}
/* Below this the two columns stack and the page scrolls, which is the right
   trade at that width. */
@media (max-width: 1180px){
  .fgrid{min-height:0;}
  /* Stacked, so each panel takes its natural height and nothing is
     constrained. There is no row to share and nothing to clip against. */
  .fmap,.fcol-suppliers,.fcol-charts{
    height:auto;max-height:none;overflow:visible;
  }
  .fcol-charts > .fpanel{flex:0 0 auto;overflow-y:visible;}
  .app-fullbleed{height:auto;max-height:none;overflow:visible;}
  .app-fullbleed .body{overflow:visible;}
  .app-wide .main.main-wide{overflow:visible;grid-template-rows:none;}
  .fgrid{grid-template-columns:minmax(0,1fr);}
  .fcounters{grid-template-columns:repeat(2,minmax(0,1fr));}
}
@media (max-width: 640px){
  .fcounters{grid-template-columns:minmax(0,1fr);}
  .fmap-nations{grid-template-columns:minmax(0,1fr);}
  .fqform{flex-direction:column;align-items:stretch;}
  .fquerybar{align-items:flex-start;flex-direction:column;gap:8px;}
}
/* The Add catalogue modal is wider than the run modal: it carries a column
   table and two panels of prose, and the run modal's measure would wrap the
   header table into something unreadable. */
.modal-wide{max-width:820px;width:calc(100vw - 48px);max-height:86vh;overflow-y:auto;}
/* A dialogue whose head stays put and whose body scrolls. The whole thing used
   to scroll as one, which carried Close off the top of a long tab. */
.modal-split{display:flex;flex-direction:column;overflow:hidden;padding:0;}
.modal-split .modal-head{
  flex:none;padding:20px 22px 14px;border-bottom:1px solid var(--hairline);
  background:var(--surface);
}
.modal-split .modal-body{
  flex:1 1 auto;min-height:0;overflow-y:auto;overscroll-behavior-y:contain;
  padding:18px 22px 22px;
}
.cardlive{margin-top:10px;}
.ffoot{display:flex;gap:18px;align-items:flex-start;}
.ffoot .hint{margin:0;font-size:13px;line-height:1.5;}
.ffoot .hint:first-child{flex:2;}
.ffoot .hint:last-child{flex:1;}
.fbuild{display:inline-block;margin-left:8px;padding:1px 7px;border-radius:999px;
        background:var(--teal-wash);color:var(--brand-teal-lift);font-weight:600;}
@media (max-width: 1180px){ .ffoot{flex-direction:column;gap:8px;} }

/* ---- The significance card runs its prose the full width of the card ------

   WHERE THE CONSTRAINT CAME FROM. There is no single global prose measure. It
   is a repeated idiom, `max-width:36em`, written into nine separate rules, five
   of which belong to this card:

     .sigcard-lede       the introduction
     .sigcard-sentence   the finding
     .sigcard-caveat-text  "What this does not mean", at 34em
     .sigcard-refused    the refusal wording
     .sigcard-note       the three paragraphs under the menus

   The other four are `.askmeasure`, `.cardolder`, `.askblocked` and the
   ambiguity legend, which belong to the AI panel and the catalogue card. Those
   are left exactly as they are, and so is `.lede` at 70ch and `.caption span`
   at 62ch.

   `.sigcard-caveat-text` also had a container query giving it two columns once
   the card passed 880px, which is what split "What this does not mean" into the
   two side by side blocks. That is undone here too, so it is one block.

   THE SCOPE OF THIS OVERRIDE is `.sigcard`, the card element itself. That
   matters for one case: the print sheet renders `.sigcard-sentence` on its own,
   outside any `.sigcard`, inside a `.printsheet` capped at 820px. Scoping to
   the ancestor leaves the printed sentence at its measure, where a full 820px
   line would be about a hundred characters and worse on paper.

   WHY THE MEASURE WAS THERE. A long line is harder to read, and 36em is about
   the right measure for a paragraph somebody reads start to finish. The finding
   is not that: it is one sentence somebody reads once, for an answer, and
   breaking it across five short lines to protect a reading measure made the
   card twice as tall as the answer needed. Nick's decision, recorded here so
   the next person knows this card is deliberately different rather than
   overlooked. */
.sigcard .sigcard-lede,
.sigcard .sigcard-sentence,
.sigcard .sigcard-refused,
.sigcard .sigcard-note,
.sigcard .sigcard-caveat-text,
.sigcard .askmeasure{
  max-width:none;
}
.sigcard .sigcard-caveat-text{
  columns:auto;
  column-gap:normal;
}
@container (min-width:880px){
  .sigcard .sigcard-caveat-text{columns:auto;}
}

/* ---- Dashboard, second round: minimums, axes, table, map -----------------*/

/* Minimum heights.
   
   On a 14 inch laptop the panels compressed until the suppliers showed two of
   five and the chart was a strip. These are floors rather than fixed heights:
   the panels still grow on a larger display, which is what fills the white
   space that used to sit below them.
   
   The numbers are what five rows and a readable chart actually measure, taken
   from the rendered panels rather than guessed. */
/* Measured from the rendered panels rather than guessed: a supplier row is 54px
   once its figures fit on one line, a nation block of region tiles is 149px, and
   the chart needs 96 for its bars plus both axes and the sentence above them. */
.fcol-suppliers .fpanel{min-height:318px;}   /* five supplier rows and a heading */
.fmap{min-height:330px;}                     /* five region tiles at least */
.fchart{min-height:186px;}                   /* bars tall enough to compare, plus both axes */
.ftablepanel{min-height:150px;overflow:hidden;}

/* A panel that scrolls says so, rather than leaving a researcher to guess that
   there is more below the fold. A fading edge at the bottom, and only while
   there is something under it: `scroll-timeline` is not needed for that because
   the mask sits on the scroll container and disappears when it is scrolled to
   the end. */
.fcol-suppliers,.fcol-charts,.fmap,.ftablewrap{scrollbar-width:thin;}

/* The "more below" indicator is gone from both surfaces.
   
   It was removed from the research view for overlapping content, and from the
   operating picture because a white fade on a dark panel reads as a fault and
   it sat over the last row of the casualty feed. A panel that scrolls says so
   with a scrollbar, and every panel clips at its own edge, which is the part
   that mattered. */

/* The over time chart, with both axes. */
.fchart-say{margin:0 0 8px;font-size:13px;}
.fplot{display:grid;grid-template-columns:auto minmax(0,1fr);gap:0 8px;}
.fyaxis{
  display:flex;flex-direction:column;justify-content:space-between;
  font-size:12px;color:var(--muted);text-align:right;height:96px;
  border-right:1px solid var(--hairline-soft);padding-right:6px;
}
.fplot-area{min-width:0;}
.fbars{display:flex;align-items:flex-end;gap:3px;height:96px;
       border-bottom:1px solid var(--hairline);}
.fbar-slot{flex:1;height:100%;display:flex;align-items:flex-end;min-width:0;}
.fbar{width:100%;min-height:2px;background:var(--brand-teal);border-radius:2px 2px 0 0;opacity:.85;}
.fxaxis{display:flex;gap:3px;margin-top:4px;}
.fxtick{flex:1;min-width:0;font-size:12px;color:var(--muted);text-align:center;
        white-space:nowrap;overflow:visible;}
.fyname{margin:4px 0 0;font-size:12px;letter-spacing:.06em;text-transform:uppercase;
        color:var(--muted);}

/* Regional activity. */
/* A fixed height, not just a ceiling. Fewer rows made the table shorter, which
   made the page shorter, which clamped the reader's scroll position: choosing a
   window moved them 47px and choosing a supplier 29px. A table that is always
   the same height cannot do that. */
/* Fixed height, and the rows are clipped by it.
   
   `overflow-y:auto` clips vertically but leaves the horizontal axis visible, so
   a sticky header and a wide row could still paint outside the rounded corner
   of the panel. `overflow:hidden auto` clips both, and the radius on the
   wrapper is what actually rounds the clip: a radius on the panel alone does
   not clip a scrolling child. */
.ftablewrap{
  height:190px;overflow:hidden auto;margin-top:8px;position:relative;
  border-radius:8px;
}
/* Twice the height on a laptop, so five rows are readable before scrolling.
   1920 and mobile are unchanged. */
@media (min-width: 1181px) and (max-width: 1599px){
  .ftablewrap{height:380px;}
  .ftablepanel{min-height:300px;}
}
.ftable{width:100%;border-collapse:collapse;font-size:12.5px;}
.ftable th{
  position:sticky;top:0;background:var(--surface);text-align:left;
  font-family:var(--label);text-transform:uppercase;letter-spacing:.06em;
  font-size:12px;color:var(--label);font-weight:600;
  padding:4px 8px 5px;border-bottom:1px solid var(--hairline);
}
.ftable td{padding:4px 8px;border-bottom:1px solid var(--hairline-soft);color:var(--text);}
.ftable tr:last-child td{border-bottom:0;}
.ftable .num{text-align:right;font-family:var(--mono);}
/* A row that moved at the last refresh, marked quietly.
   
   A left edge that fades, not a flash and not a colour that pulls the eye to a
   particular region the instant it moves. It marks the whole refresh, not an
   arrival: several records inside one bucket produce one mark. */
.ftable-moved td:first-child{box-shadow:inset 3px 0 0 var(--brand-teal);}
.fmovedsay{margin:6px 0 0;font-size:12px;}
/* Halved, so it reads as quick rather than as a state the row is in. The delay
   is set per row by the shim, spread across about a second, so the table looks
   alive rather than updating in one block. */
@media (prefers-reduced-motion: no-preference){
  .ftable-moved td{animation:fmoved 3s ease-out both;}
}
@keyframes fmoved{from{background:var(--teal-wash);}to{background:transparent;}}

/* The Graphic and Map control. A segmented pair, obviously a choice. */
.fseg{display:inline-flex;border:1px solid var(--hairline);border-radius:999px;
      overflow:hidden;background:var(--surface-2);}
.fseg-opt{
  padding:4px 14px;font-size:12px;font-weight:600;text-decoration:none;
  color:var(--muted);letter-spacing:.02em;
}
.fseg-opt + .fseg-opt{border-left:1px solid var(--hairline);}
.fseg-opt:hover{color:var(--text);}
.fseg-opt.on{background:var(--brand-teal);color:#FFFFFF;}
.fmap-note{margin:0 0 8px;font-size:12px;}

/* The geographic view. */
/* The legend column is given a width rather than left to size itself. `auto`
   takes max-content, and the legend carries two explanatory sentences whose
   max-content width is 566px, so the map got 137 of a 746px panel. */
/* The legend column. It was a fixed 168px, which is a thin strip on a 24 inch
   display and wrapped its prose into a column two or three words wide. It now
   takes a share of the room and stops growing once the text is comfortable. */
.fgeo{
  display:grid;grid-template-columns:minmax(0,1fr) clamp(200px,26%,300px);
  gap:16px;align-items:start;
}
.fgeo-plot{min-width:0;width:100%;}
.fgeo-crumb{margin:0 0 6px;font-size:12px;color:var(--muted);}
.fgeo-crumb strong{color:var(--text);}
.fgeo-crumb a{color:var(--brand-teal-lift);}
/* Each map eases in, so moving between the world and a nation reads as a
   change of view rather than a jump. It is an animation on arrival rather than
   a transition between two states, because the two states are two renders from
   the server and there is nothing to tween between. */
.fgeomap{width:100%;height:auto;min-height:230px;max-height:400px;display:block;
         animation:fgeoin .22s cubic-bezier(.33,.68,.28,1) both;}
@keyframes fgeoin{from{opacity:0;transform:scale(.985);}to{opacity:1;transform:none;}}
.fgeo-shape path{stroke:var(--surface);stroke-width:1.2;vector-effect:non-scaling-stroke;}
.fgeo-pick{cursor:pointer;}
.fgeo-pick:hover path,.fgeo-pick:focus path{stroke:var(--brand-teal);stroke-width:2;}
.fgeo-legend{min-width:0;}
.flegend{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:2px;}
.flegend li{display:flex;align-items:center;gap:7px;}
.flegend-swatch{width:26px;height:13px;border-radius:3px;border:1px solid var(--hairline);}
.flegend-text{font-size:13px;color:var(--text);}
@media (prefers-reduced-motion: reduce){
  .fgeomap{animation:none;}
  .ftable-moved td{animation:none;}
}
@media (max-width: 1180px){
  .fgeo{grid-template-columns:minmax(0,1fr);}
  .fgeo-legend{display:flex;gap:14px;align-items:flex-start;}
  .flegend{flex-direction:row;}
}
.fsupplier-figs{
  margin:2px 0 0;display:flex;flex-wrap:wrap;gap:2px 10px;
  font-size:12px;color:var(--muted);line-height:1.4;
}
.fsupplier-figs strong{color:var(--text);font-weight:600;}
/* The hover box. Immediate, clear of the mark, and never over it. */
.ftip{
  position:fixed;z-index:60;max-width:280px;pointer-events:none;
  background:#12333A;color:#FFFFFF;font-size:12px;line-height:1.45;
  padding:7px 10px;border-radius:7px;box-shadow:0 6px 20px rgba(16,34,42,.22);
}
/* The map key's box, which opens under the key and never over the map
   (tooltip.js `placeBelow`). Wider, so the long ones wrap into a block, with
   an arrow up at the row it explains. */
.ftip.ftip-below{max-width:320px;}
.ftip.ftip-below::before{
  content:"";position:absolute;top:-6px;left:var(--ftip-arrow,14px);margin-left:-6px;
  border:6px solid transparent;border-top:0;border-bottom-color:#12333A;
}
/* The mark being read. Subtle: enough to say which one, not enough to redraw
   the chart. */
.fbar.fhovered{opacity:1;filter:brightness(.86);}
/* The region cells are HTML now rather than SVG rects, so the mark is a
   border rather than a stroke. Same restraint: enough to say which one. */
.fmap-cell.fhovered{border-color:var(--brand-teal);box-shadow:inset 0 0 0 1px var(--brand-teal);}
/* One hover weight for the whole map, at country level and region level
   alike, halved from the two it was. `vector-effect` keeps it one pixel
   whatever the zoom transform is doing, which is what "the same weight" has to
   mean on a map that scales. */
.fgeo-shape.fhovered path,[data-tip].fhovered > path{
  stroke:var(--gm-hover,var(--brand-teal));stroke-width:1;
  vector-effect:non-scaling-stroke;
}
.fbands li.fhovered .fband span{filter:brightness(.86);}
.buildhead{justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:8px;}
.dsswitch{display:flex;align-items:center;gap:8px;flex:none;}
.dsswitch .sel{max-width:260px;}
.catdefault-on{font-size:12px;letter-spacing:.07em;text-transform:uppercase;
               color:var(--brand-teal-lift);background:var(--teal-wash);
               border-radius:999px;padding:3px 10px;font-weight:700;}

/* The catalogue card's heading row.
   
   The text takes the space that is left and wraps inside itself; the badges
   keep their own width and stay on the title line. `min-width:0` on the text is
   what lets it shrink: without it a flex item is at least its content's minimum
   width, which for a long summary is the whole card, and the badges wrapped
   below and went left.
   
   Three badges fit beside the title at every desktop width because the group
   does not wrap internally. Below 720 the whole group drops under the title,
   which is where it belongs on a phone rather than squeezed alongside. */
.cardhead{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;}
.cardhead-text{flex:1 1 auto;min-width:0;}
.cardbadges{
  display:flex;align-items:center;gap:10px;flex:0 0 auto;flex-wrap:nowrap;
  margin-top:2px;
}
.cardbadges form{display:flex;}
@media (max-width: 720px){
  .cardhead{flex-direction:column;gap:10px;}
  .cardbadges{flex-wrap:wrap;}
}

/* ---- The operational picture --------------------------------------------
   
   A different surface with a different purpose, and its own palette. Scoped to
   `.opview` so nothing here reaches the research screens: those keep the light
   theme, the perimeter banner and every control they have.
   
   **Contrast is measured, not judged.** Every ink below was composited against
   all three surfaces and the worst pair is 7.09:1, which is AAA for body text.
   A test recomputes it from this file, so changing a colour means re-measuring
   rather than eyeballing. The screen is built to be read across a room. */
.opview{
  --op-bg:#0B1418;
  --op-panel:#111E24;
  --op-row:#16262E;
  --op-line:#22383F;
  --op-text:#E6EEF2;
  --op-muted:#9FB3BD;
  --placeholder:var(--op-muted);
  /* No severity reported, which is a different thing from a severity and is not
     a point on the scale.
     Its own token rather than the muted ink it used to borrow. #9FB3BD sits at
     0.433 relative luminance and critical at 0.429, so an unknown cluster and a
     critical one were 1.01:1 apart: the same grey to anybody reading the map in
     greyscale, and the same grey to a red deficiency. That is two different
     things looking identical on the screen a commander reads first.
     This is 1.81:1 against critical and no closer than that to any other band,
     and it still carries the chip's ink at 4.61:1. The ramp is otherwise
     untouched. `tests_triage_bands` recomputes both figures from this file, so
     changing a token here means re-measuring rather than eyeballing. */
  --op-unknown:#6E838C;
  --op-accent:#67DCD3;
  --op-critical:#FF8F8F;
  --op-severe:#FFB86B;
  --op-moderate:#FFE066;
  --op-minor:#7FEFC8;
  --op-expectant:#000000;
  --op-text-on-expectant:#E6EDF0;
  /* Triage, NATO AMedP-1.10, as Chris confirmed on 4 November 2026: T1
     Immediate red, T2 Urgent yellow, T3 Minimal green, T4 Expectant black
     with a thin white border so it shows on the dark view. The fills are the
     ATAK plugin's (docs/design/operational-view/atak/atak-triage-chips.png)
     and every chip, bar, trend line and map cluster on the view is drawn in
     them. Fills are never adjusted; only a label may change, dark or white.
     Every label meets 4.5:1 on its fill and all but T1's dark label meet
     7.0 (4.97:1, `tests_triage_chips.ChipContrast`). */
  --op-t1:#E53935;
  --op-t2:#F1C40F;
  --op-t3:#27AE60;
  --op-t4:#000000;
  --op-t4-border:#FFFFFF;
  --op-t4-ink:#FFFFFF;
  --op-chip-label:#000000;
  --op-sos:#FF8585;
  --op-ok:#22D3EE;
  --op-t-none:#9DB0B8;
  /* A mix chip's count, in a circle of its fill mixed toward white
     (triagechip.COLOURS `circle` and `circle_ink`, held equal by
     tests_nato_triage.TheColours). */
  --op-t1-in:#F5B4B2;
  --op-t1-in-ink:#4A0607;
  --op-t2-in:#FAEBAD;
  --op-t2-in-ink:#3A2C00;
  --op-t3-in:#B1E2C6;
  --op-t3-in-ink:#06210F;
  --op-t4-in:#5F5F5F;
  --op-t4-in-ink:#FFFFFF;
  --op-t-none-in:#D3DBDF;
  --op-t-none-in-ink:#1A2427;
  --op-good:#7FEFC8;
  --op-bad:#FF9E9E;
  /* Dark ink on a light chip, as the silent chip carries it. */
  --op-chip-ink:#0B1418;
  /* The readings' icons, in the Biostream ATAK plugin's colours. Graphics, not text, so
     the 3:1 non-text floor applies; each clears 5.5:1 on the panel. */
  --op-hr:#FF5A4E;
  --op-spo2:#4DA3FF;
  --op-rr:#A58BFF;
  --op-battery:#D0D5D8;
  /* The plugin's alert orange, 8.33:1 on the panel. The brief's starting
     point, #F57C00, is 6.29:1 and fails the floor for the count beside it. */
  --op-alert:#FF9D42;
  background:var(--op-bg);color:var(--op-text);
  min-height:100vh;display:flex;flex-direction:column;
}
body:has(.opview) .stage{max-width:none;margin:0;padding:0;}
body:has(.opview) footer{display:none;}
body:has(.opview){background:#0B1418;}

/* Five pixels above and below rather than ten: at 1512 by 860 the header,
   the tabs, the banner and the headline cards took 291 pixels before any
   data. The title over its subtitle is the tallest thing here and sets the
   height; side by side they do not fit at 1512 and the bar wraps. */
.opbar{
  display:flex;align-items:center;gap:20px;flex-wrap:wrap;
  padding:5px 18px;background:#0E1A20;border-bottom:1px solid var(--op-line);
}
/* The wordmark, a link home. The white logo in the line the word "Biostream"
   stood in (15px at the body's 1.62, 24.3px), drawn at the height the research
   header draws the same logo (`.wordmark`, 15.4px), so the block and the bar
   keep their height. Padding with a matching negative margin gives the hover
   room without moving anything. */
.opident{
  display:flex;flex-direction:column;gap:1px;
  color:inherit;text-decoration:none;
  padding:2px 6px;margin:-2px -6px;border-radius:7px;
  transition:background-color .15s ease-out;
}
.opident-mark{display:flex;align-items:center;height:calc(15px * 1.62);}
.opident-mark img{display:block;height:15.4px;width:auto;}
.opident-line{font-size:12px;letter-spacing:.16em;text-transform:uppercase;color:var(--op-muted);}
/* The same hover as the view switch beside it: the accent, faintly, behind. */
a.opident:hover{background:color-mix(in srgb,var(--op-accent) 14%,transparent);}
a.opident:hover .opident-line{color:var(--op-text);}
a.opident:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}

/* The fade between the Operational View and the home page, 450ms, opacity
   only, easing out (static/js/page-fade.js). Every page opts in to the
   browser's cross-document transition, and only when motion is allowed; the
   script skips it for every navigation a marked link did not start. The root
   cross-fade is opacity alone, old into new, so a dark to light change does not
   pass through white or black. */
@media (prefers-reduced-motion: no-preference){
  @view-transition{navigation:auto;}
}
::view-transition-group(root),
::view-transition-old(root),
::view-transition-new(root){animation-duration:450ms;animation-timing-function:ease-out;}
/* Where the browser has no such transition, the outgoing page fades its own
   opacity over the ground of the page it is going to. */
html.tre-leaving-light{background:var(--base);}
html.tre-leaving-dark{background:#0B1418;}
html.tre-leaving body{opacity:0;transition:opacity 450ms ease-out;}
@media (prefers-reduced-motion: reduce){
  ::view-transition-group(*),::view-transition-old(*),::view-transition-new(*){animation:none !important;}
  html.tre-leaving body{opacity:1;transition:none;}
}
.optitle{flex:1;min-width:0;text-align:center;}
/* Stated, not inherited. It was taking the light chrome's ink from a global
   heading rule and rendering at 1.08:1 against this bar, which is the title of
   the screen being invisible on it. */
.optitle h1{
  margin:0;font-size:19px;font-weight:600;letter-spacing:.01em;
  color:var(--op-text);
}
.optitle p{margin:2px 0 0;font-size:12px;letter-spacing:.16em;text-transform:uppercase;color:var(--op-muted);}
.oplive{display:inline-flex;align-items:center;gap:7px;font-size:12px;
        letter-spacing:.12em;text-transform:uppercase;color:var(--op-good);font-weight:700;}
.oplive .fdot{width:8px;height:8px;border-radius:50%;background:currentColor;}
@media (prefers-reduced-motion: no-preference){
  .oplive[data-state="live"] .fdot{animation:fpulse 2s ease-in-out infinite;}
}
/* The badge's other states. Only live pulses, and each of the rest has its own
   colour and its own words, so a screen that is not updating cannot pass for
   one that is. The words carry the time the figures were last current. */
.oplive[data-state="slowed"]{color:var(--op-severe);}
.oplive[data-state="paused"],.oplive[data-state="stopped"]{color:var(--op-muted);}
.oplive[data-state="refused"],.oplive[data-state="error"]{color:var(--op-critical);}
.oplive[data-oplive-badge]{cursor:help;white-space:nowrap;}
.opclock{font-family:var(--mono);font-size:15px;letter-spacing:.02em;}
.opclock span{display:block;font-size:12px;color:var(--op-muted);letter-spacing:.06em;}
.opwho{display:flex;flex-direction:column;text-align:right;font-size:12.5px;}
.opwho span{font-size:12px;color:var(--op-muted);}

.optabs{display:flex;gap:2px;padding:0 12px;background:#0E1A20;
        border-bottom:1px solid var(--op-line);overflow-x:auto;}
.optab{
  padding:6px 15px;font-size:12.5px;font-weight:600;color:var(--op-muted);
  border-bottom:2px solid transparent;white-space:nowrap;text-decoration:none;
}
.optab.on{color:var(--op-accent);border-bottom-color:var(--op-accent);}
/* Visibly not available, and it is not a link: there is no route behind it, so
   there is nothing to reach by typing a URL either. */
.optab[aria-disabled="true"]{opacity:.42;cursor:not-allowed;}

.opnote{
  margin:0;padding:7px 18px;background:#2A2410;border-bottom:1px solid var(--op-line);
  font-size:12px;color:var(--op-moderate);
}
.opnote strong{color:var(--op-moderate);}

.opcounters{display:grid;gap:10px;padding:6px 16px 0;
            grid-template-columns:repeat(auto-fit,minmax(190px,1fr));}
.opcounter{background:var(--op-panel);border:1px solid var(--op-line);
           border-radius:9px;padding:5px 14px;
           display:flex;align-items:center;gap:var(--op-icon-gap);min-width:0;}
/* The icon beside each headline figure, centred on the label and figure as a
   block. One box for all six, one stroke, one colour: the muted ink the card
   labels use, and T1 Immediate's red for the one filled glyph. The box
   is a variable so the smaller screen can shrink the icon, never the figure. */
.opcounters{--op-icon:40px;--op-icon-gap:12px;}
.opcounter-body{min-width:0;}
.opicon{flex:none;width:var(--op-icon);height:var(--op-icon);
        fill:none;stroke:var(--op-muted);stroke-width:1.6;
        stroke-linecap:round;stroke-linejoin:round;}
.opicon-alert{fill:var(--op-t1);stroke:none;}
/* The smaller screen: 1512 wide gives each card 208 pixels inside its padding,
   and "Evacuations in progress" needs 162 of them on one line. A 40 pixel icon
   and its gap leave 156, so the label broke; 32 and 10 leave 166. The icon
   gives way, never the figure (measured in DASHBOARD.md). */
@media (max-width:1600px){.opcounters{--op-icon:32px;--op-icon-gap:10px;}}
.opcounter p{margin:0 0 3px;font-size:12px;letter-spacing:.1em;text-transform:uppercase;color:var(--op-muted);}
.opcounter .v,.opsince-headline .v{font-size:clamp(22px,2vw,32px);font-weight:700;line-height:1.05;}
/* A figure is one line: "2 h 55 min" broke into three at 1440 (5 November 2026). */
.opcounter .v{white-space:nowrap;}
.opcounter .u{font-size:12px;color:var(--op-muted);}
.opdelta{font-size:12px;font-weight:700;margin-left:8px;}
.opdelta-up{color:var(--op-bad);}
.opdelta-down{color:var(--op-good);}
.opdelta-flat{color:var(--op-muted);}

/* The rail is 420 wide, 160 more than it was, taken from the map and not from
   the lists on the right, which are already tight for the feed's table. The
   width is what lets the nation pills go two to a row. */
.opgrid{display:grid;gap:12px;padding:4px 16px 16px;
        grid-template-columns:420px minmax(0,1fr) clamp(380px,24vw,470px);align-items:start;}
/* The right hand column fills the row and no more: the feed and the timeline
   share its height, each scrolling inside itself, so neither runs below the
   fold on a laptop. The rail does the same and scrolls rather than clipping. */
.opview .opgrid:not(.opgrid-tab) > .opcol:last-child{
  display:flex;flex-direction:column;gap:12px;height:var(--op-band,auto);
}
.opview .opgrid:not(.opgrid-tab) > .opcol:last-child > .oppanel{
  flex:1 1 0;min-height:0;margin:0;display:flex;flex-direction:column;
}
.opview .opgrid:not(.opgrid-tab) > .opcol:last-child .opscroll{
  max-height:none;flex:1 1 auto;min-height:0;
}
.opview .opgrid:not(.opgrid-tab) > .oprail > .oppanel{
  height:var(--op-band,auto);overflow:auto;margin:0;
}
.oppanel{background:var(--op-panel);border:1px solid var(--op-line);
         border-radius:9px;padding:11px 13px;margin-bottom:12px;}
.oppanel h2{margin:0 0 8px;font-size:12px;letter-spacing:.12em;
            text-transform:uppercase;color:var(--op-muted);font-weight:700;}
.opchips{display:flex;flex-wrap:wrap;gap:6px;}
.opchip{
  display:inline-flex;align-items:center;gap:6px;padding:4px 9px;border-radius:999px;
  border:1px solid var(--op-line);background:var(--op-row);color:var(--op-text);
  font-size:12px;text-decoration:none;
}
.opchip.on{border-color:var(--op-accent);color:var(--op-accent);font-weight:600;}
/* The Nation heading, with the one control that puts both filters back to
   All beside it, offered only when either is set. */
.opfilterhead{display:flex;align-items:baseline;justify-content:space-between;gap:8px;}
.opclear{font-size:12px;color:var(--op-accent);text-decoration:none;
         border:1px solid var(--op-line);border-radius:999px;padding:2px 9px;}
.opclear:hover{border-color:var(--op-accent);}
/* A combination with no reporting in the window, said in words where a panel
   would otherwise draw an empty chart or a nought. */
.opempty{margin:0;padding:10px 0;font-size:12px;color:var(--op-muted);}
.opcounter .v.opnone{font-size:15px;font-weight:600;color:var(--op-muted);}
/* A card's figure, or the one muted line it says in place of one, sits in a
   row of one fixed height and never wraps, so a card is the same height
   whichever it holds and nothing below it moves (6 November 2026,
   TheDockedBox on GitHub: the docked box came back 12 px lower once a card
   had switched). The muted lines are worded to fit at 1280 wide. */
.opcounter div:has(> .v){height:calc(clamp(22px,2vw,32px) * 1.05);display:flex;align-items:flex-end;gap:8px;
  min-width:0;white-space:nowrap;}
.opcounter .v.opnone{display:block;min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;line-height:1.2;}
/* With no unit beside it, the muted line keeps its own width and the label
   beside it wraps, as a label already does on a narrow card. */
.opcounter div:has(> .v.opnone){flex:0 0 auto;}
/* A panel that takes the territory filter only, saying so under its title. */
.opexempt{margin:-4px 0 8px;font-size:12px;line-height:1.35;color:var(--op-muted);}
/* A filter that does not apply on this section: still a control, because it
   carries to the others, but drawn as not doing anything here. */
.opinert{opacity:.45;}
.opfilternote{margin:2px 0 6px;}
/* A casualty row that opens its record: the whole row is the target. */
.oprow-link{cursor:pointer;}
.oprow-link:hover td{background:var(--op-row);}
/* Keyboard focus: dotted and in the text colour, so it cannot be taken for
   the open record's solid green border below. */
.oprow-link:focus-within{outline:2px dotted var(--op-text);outline-offset:-4px;}
.oprowlink{color:inherit;text-decoration:none;}
.oprowlink:hover,.oprowlink:focus-visible{text-decoration:underline;}
/* Where each value on an opened record came from, drawn quietly: a rule to
   the left of the value, read by the key at the top of the record. From the
   device is a solid rule; from the record platform a dotted one; not
   recorded has none, and its words already say so. */
.opsrc-key{display:flex;flex-wrap:wrap;gap:4px 14px;margin:0 0 10px;font-size:13px;color:var(--op-muted);}
.opsrc{padding-left:7px;border-left:2px solid transparent;}
.opsrc-dd{padding-left:7px;border-left:2px solid transparent;}
.opsrc-device{border-left-color:var(--op-accent);}
.opsrc-platform{border-left:2px dotted var(--op-muted);}
.opsrc-card{border-left:2px dashed var(--op-accent);}
.opsrc-none{border-left-color:transparent;}
.opsrc-key .opsrc-none{font-style:italic;}
.opdetail-views{display:flex;flex-wrap:wrap;gap:4px 14px;margin:-2px 0 10px;font-size:12px;}
.opdetail-view{color:var(--op-muted);text-decoration:none;padding-bottom:2px;border-bottom:2px solid transparent;}
.opdetail-view:hover,.opdetail-view:focus-visible{color:var(--op-text);}
.opdetail-view.on{color:var(--op-text);border-bottom-color:var(--op-accent);}
.opdetail-back{margin:4px 0 8px;font-size:12px;}
.opdetail-back a,.opdetail-list a,.opdetail-facts dd a{color:var(--op-text);}
.opdetail-list{margin:0 0 8px;padding-left:16px;font-size:12px;}
.opwidened{display:flex;flex-wrap:wrap;gap:4px 10px;margin:6px 0 0;padding:6px 10px;
  border:1px solid var(--op-line);border-radius:4px;font-size:12px;color:var(--op-text);}
/* The selection in words in the map header. */
.opselection{font-size:12px;font-weight:600;color:var(--op-text);}
.opflag{font-size:13px;line-height:1;}
/* Round, because a flag in a list is an identifier rather than a flag: the
   circle keeps every one the same shape whatever its proportions, so a row of
   them reads as a column of marks. Served from this repository. */
.opflagimg{
  width:16px;height:16px;border-radius:50%;object-fit:cover;flex:none;
  box-shadow:0 0 0 1px rgba(255,255,255,.14);
}
.opcell-nat .opflagimg{width:14px;height:14px;vertical-align:-3px;}
.opcell-nat{text-align:center;}
/* The two letter code beside each flag, as the rail's chips carry it, so the
   Nation and Nationality columns side by side can be read without the flags. */
.opnat-code{margin-left:4px;font-size:12px;font-weight:600;letter-spacing:.03em;color:var(--op-text);}
/* Casualty nationality on the Evacuation table: up to three flags side by
   side, then how many more (`_evac_nat_cell.html`). */
.opcell-nat .opflagimg + .opflagimg{margin-left:3px;}
.opnat-more{margin-left:4px;font-size:12px;font-weight:600;color:var(--op-muted);}
.opwindows{display:flex;gap:4px;}
.opwindow{flex:1;text-align:center;padding:5px 0;border-radius:6px;font-size:12px;
          border:1px solid var(--op-line);background:var(--op-row);color:var(--op-muted);
          text-decoration:none;}
.opwindow.on{background:var(--op-accent);border-color:var(--op-accent);color:#08171A;font-weight:700;}

.optable{width:100%;border-collapse:collapse;font-size:12px;}
.optable th{
  position:sticky;top:0;background:var(--op-panel);text-align:left;
  font-size:12px;letter-spacing:.1em;text-transform:uppercase;color:var(--op-muted);
  padding:5px 7px;border-bottom:1px solid var(--op-line);font-weight:700;
}
/* The feed's own ink, stated rather than inherited.
   
   Location, injury, severity and nation were arriving at 1.74:1 against the
   panel, from the light chrome's muted colour. This is the most operationally
   interesting table on the screen and it was the least readable thing on it.
   Measured after: 7.0:1 for the supporting columns and 14:1 for the place,
   which is the one a reader scans for. */
.optable td{
  padding:5px 6px;border-bottom:1px solid var(--op-line);color:var(--op-muted);
}
.optable td.opcell-key{color:var(--op-text);font-weight:500;}
/* Every column visible. The table was 367px in a 352px panel, so the evacuation
   status was clipped at the edge. */
.optable{table-layout:fixed;}
/* Column widths, so nothing is clipped at the panel edge and the two columns a
   reader scans get the room. */
/* Widths set from the values, measured at 1512 where the column is 380px:
   "12:19" in tabular figures, a "MODERATE" chip, a flag, and the evacuation
   stage in its short form ("En route" rather than "MEDEVAC en route", the
   whole label in its hover box). The place takes what is left. Every one of
   these was clipping: the time read "12..", the severity "MODERA". */
/* Since 11 September: Nation and Nationality, flag and code each, third and
   fourth, and the place fifth. */
.optable th:nth-child(1),.optable td:nth-child(1){width:46px;}
.optable th:nth-child(2),.optable td:nth-child(2){width:74px;}
.optable th:nth-child(3),.optable td:nth-child(3){width:42px;text-align:center;}
.optable th:nth-child(4),.optable td:nth-child(4){width:42px;text-align:center;}
.optable th:nth-child(6),.optable td:nth-child(6){width:56px;}
.optable th:nth-child(7),.optable td:nth-child(7){width:66px;}
.optable th,.optable td{padding-left:4px;padding-right:4px;}
/* The severity chip in the narrow feed, measured: "MODERATE" at 10px with
   0.6px tracking and 7px padding needed 93px in a 74px column. Slightly
   tighter here, and the whole word still. */
.opgrid:not(.opgrid-tab) .optable .opsev{font-size:12px;letter-spacing:.3px;padding:1px 5px;}
.optable th,.optable td{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
/* The live feed's Location and Casualty nationality (4 November 2026): wide
   enough for a flag and its code, and the headings wrap onto two lines
   rather than being cut to "NATI...". Triage gives up the width: its chip
   is a T code now, not a word, so the place keeps the room it had. */
.optable-feed th:nth-child(2),.optable-feed td:nth-child(2){width:50px;}
.optable-feed th:nth-child(3),.optable-feed td:nth-child(3){width:56px;}
.optable-feed th:nth-child(4),.optable-feed td:nth-child(4){width:70px;}
.optable-feed th.opcell-nat{white-space:normal;overflow:visible;text-overflow:clip;line-height:1.15;
  vertical-align:bottom;letter-spacing:.02em;}
/* Narrower than 420 pixels, as the feed's panel is at 1440 wide (302
   measured), seven fixed columns added to more than the panel and the place,
   the column a reader scans for, was squeezed to nothing. There, Injury and
   Evac status step aside: both were cut to a few letters, and both are on
   the casualty's record a click away. */
.oppanel[data-fast-part="feed"] .opscroll{container-type:inline-size;}
@container (max-width:419px){
  .optable-feed th:nth-child(6),.optable-feed td:nth-child(6),
  .optable-feed th:nth-child(7),.optable-feed td:nth-child(7){display:none;}
}
.optable tr:last-child td{border-bottom:0;}
/* Positioned so it is the containing block of what is absolutely placed inside
   it. Without that, the screen reader labels in a wide table (position
   absolute, `opvisually-hidden`) were placed against an ancestor outside the
   scroll box, escaped its clipping, and stretched a 320 wide phone's page to
   1195 (ISSUES.md BIO-84). */
.opscroll{position:relative;max-height:290px;overflow:hidden auto;border-radius:7px;}
/* The synthetic marker on this surface. Every panel showing nation data carries
   one, because a screenshot cropped to a single panel is how a figure travels
   and it must not travel without the sentence that the records are invented
   (constraint 24). Measured against the panel like every other ink here. */
.opinvented,.oprange{
  display:inline-block;margin-left:6px;padding:1px 5px;border-radius:3px;
  font-size:12px;font-weight:700;
  letter-spacing:.08em;text-transform:uppercase;vertical-align:middle;
}
.opinvented{background:#3A2E18;color:#F0D089;}
/* The window a card is showing, on the three cards that carried the marker
   above until 10 September. The same pill to the pixel, sharing the rule, in
   the neutral colours of the panel furniture (the chips and tags): the row
   ground and the muted ink, 7.15:1. Their hairline is drawn inside rather
   than as a border, so the box is exactly the marker's size. */
.oprange{background:var(--op-row);color:var(--op-muted);box-shadow:inset 0 0 0 1px var(--op-line);}
/* On Total casualties the pill has its own line under the title, at every
   width, so the card reads the same on both screens. Beside the title it
   needed 207 of the 208 pixels a card has at 1512 and wrapped there anyway.
   A flex row so the pill sits at its own height with no text strut around
   it, and no indent, because nothing is beside it. */
.opcounter-range{display:flex;margin:0 0 4px;}
.opcounter-range .oprange{margin-left:0;}
.opsev{
  display:inline-block;padding:1px 7px;border-radius:4px;font-size:12px;
  font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:#08171A;
}
/* The triage bands, everywhere a casualty is coloured by its category:
   the triage bars, the mix chips, the nations' bars and the evacuation
   panel. The same fills and labels as the T chips (`.optchip-*`). */
.opsev-T1{background:var(--op-t1);color:var(--op-chip-label);}
.opsev-T2{background:var(--op-t2);color:var(--op-chip-label);}
.opsev-T3{background:var(--op-t3);color:var(--op-chip-label);}
.opsev-T4{background:var(--op-t4);color:var(--op-t4-ink);box-shadow:inset 0 0 0 1px var(--op-t4-border);}
.opsev-none{background:var(--op-t-none);color:var(--op-chip-label);}
/* Not categorised, after T4 on the triage bars: muted, because it is the
   absence of a category rather than one. */
.opbar-muted > span:first-child,.opbar-muted > b{color:var(--op-muted);font-weight:500;}
/* The triage chip and its SOS label, one size in every table
   (feeds/_triage_chip.html, apps/feeds/triagechip.py). The label is turned on
   its side to read bottom to top, left of the chip with a small gap, and as
   tall as the chip because the cell stretches both. */
.optriage-cell{display:inline-flex;align-items:stretch;gap:3px;vertical-align:middle;}
/* One part, the code only, at a mix chip's font and height (5 November
   2026), so a casualty's chip and a movement's mix match: 3px, the 19px of
   the count's circle, 3px. */
.optchip{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:32px;height:25px;padding:0 7px;border-radius:5px;font-family:var(--mono);font-size:13px;font-weight:600;line-height:1;color:var(--op-chip-label);}
.optchip-T1{background:var(--op-t1);}
.optchip-T2{background:var(--op-t2);}
.optchip-T3{background:var(--op-t3);}
/* T4's 1px border stands in for a pixel of padding, so it is the same size
   as the other chips and stays visible on the dark panel. */
.optchip-T4{background:var(--op-t4);color:var(--op-t4-ink);box-shadow:inset 0 0 0 1px var(--op-t4-border);}
.optchip-none{background:var(--op-t-none);}
.opsos{display:inline-flex;align-items:center;justify-content:center;writing-mode:vertical-rl;transform:rotate(180deg);background:var(--op-sos);color:var(--op-chip-label);font-size:12px;font-weight:800;line-height:1;padding:0 1px;border-radius:2px;letter-spacing:.03em;}
/* Whether reports are arriving from the field, on the live feed's heading.

   Right of the heading so it costs no vertical space on a dense screen, and at
   the panel furniture's weight rather than the heading's, because it is a note
   and not a title.

   Nothing here reddens and nothing here moves. Silence is not an error: a
   rehearsal with nobody posting for twenty minutes is normal, and a screen that
   reddened at it would be teaching the reader to ignore it. The only state with
   an accent is the one where reports are arriving; the two quiet states take
   the muted ink the rest of the furniture uses. The dot is filled in the first
   and a hollow ring in the others, so the state survives any colour vision
   deficiency and a greyscale print. */
.opfield{
  float:right;display:inline-flex;align-items:center;gap:5px;
  font-size:12px;font-weight:600;letter-spacing:.04em;text-transform:uppercase;
  color:var(--op-muted);
}
.opfield-dot{
  width:7px;height:7px;border-radius:50%;flex:0 0 auto;
  box-shadow:inset 0 0 0 1.5px currentColor;
}
.opfield-receiving{color:var(--op-accent);}
.opfield-receiving .opfield-dot{background:currentColor;}
/* The device's confidence in the reading it sits beside, 0 to 1.

   **The bar carries it by length and not by colour.** It is the same muted ink
   as the label and only its width changes, so it reads on a greyscale print
   and with any colour vision deficiency, and the number beside it is real text
   in both cases.

   **There is no threshold here, deliberately.** Anything applied to the
   reading itself, fading it or marking it, becomes noticeable at some value,
   and that point is a clinical threshold whether or not anybody wrote it down.
   A bar has no such point. If a threshold is ever wanted it belongs to the
   clinical owner and not to this file.

   Nought is an empty bar with the number 0.00 beside it, which is a
   measurement. A confidence nobody sent says so in words instead, because the
   two are different facts and the panel keeps them apart the way it keeps
   Not recorded apart from a zero. */
.opconf{
  display:inline-flex;align-items:center;gap:5px;margin-left:9px;
  font-size:12px;letter-spacing:.04em;color:var(--op-muted);vertical-align:1px;
}
.opconf-n{font-variant-numeric:tabular-nums;}
.opconf-bar{
  display:inline-block;width:30px;height:5px;border-radius:3px;overflow:hidden;
  box-shadow:inset 0 0 0 1px var(--op-muted);
}
.opconf-bar span{display:block;height:100%;background:var(--op-muted);}
.opconf-none{font-style:italic;}
/* Where the screen is looking, on the map's own head.

   A trail rather than a Back button alone: it says where you ARE as well as
   where you have been, and on a command screen that is the question that must
   never be in doubt. The last step is plain text, because it is here and there
   is nowhere for it to go; Back sits beside it because it is what people reach
   for and the trail's own last step offers no way up.

   Every step is a real button, so the whole thing is reachable from the
   keyboard. Focus used to be a double click and nothing else, which is
   undiscoverable, and on a trackpad or a touch screen barely a gesture. */
.gmtrail{
  display:flex;flex-wrap:wrap;align-items:center;gap:5px;margin:3px 0 0;
  font-size:12px;letter-spacing:.04em;
}
.gmtrail-step{
  background:none;border:0;padding:0;margin:0;cursor:pointer;font:inherit;
  color:var(--op-accent);text-decoration:underline;text-underline-offset:2px;
}
.gmtrail-step:hover{color:var(--op-text);}
.gmtrail-step:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.gmtrail-sep{color:var(--op-muted);}
.gmtrail-here{color:var(--op-text);font-weight:600;}
/* Back, beside the trail and not on the map's own overlay. It carried
   `geomap-return` and inherited its absolute position, which put it in the
   page header while the trail sat on the map: one glance could not tell you
   both where you are and how to leave. Its own rules now, so there is no
   cascade to lose. */
.gmtrail-back{
  margin-left:8px;height:22px;padding:0 10px;border:1px solid var(--op-accent);
  border-radius:999px;background:var(--op-panel);color:var(--op-accent);
  font:inherit;font-size:12px;font-weight:600;cursor:pointer;
}
.gmtrail-back:hover{background:var(--op-row);}
.gmtrail-back:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.gmtrail-unplaced{margin:2px 0 0;font-size:12px;color:var(--op-muted);}
.gmtrail-unplacedlink{
  background:none;border:0;padding:0;margin:0;cursor:pointer;font:inherit;
  color:var(--op-muted);text-decoration:underline;text-underline-offset:2px;
}
.gmtrail-unplacedlink:hover{color:var(--op-text);}
/* The unplaced, under a panel whose figures deliberately exclude them. A note
   and not a row: a distribution's rows are one dimension and must add up to
   its own total, and "not placed" is a different dimension. */
.opunplaced{margin:4px 0 0;font-size:12px;color:var(--op-muted);}
.opstatus-awaiting{color:var(--op-severe);}
.opstatus-en_route,.opstatus-in_transit{color:var(--op-accent);}
.opstatus-evacuated{color:var(--op-good);}
/* A row that has just arrived. Brief, and on a surface with no interval to
   protect: there is nothing to difference here that the reader is not entitled
   to see. */
@media (prefers-reduced-motion: no-preference){
  .oprow-new td{animation:opnew 2.4s ease-out both;}
}
@keyframes opnew{from{background:#1D3A3F;}to{background:transparent;}}

.optimeline{list-style:none;margin:0;padding:0;}
.optimeline li{display:flex;gap:9px;align-items:flex-start;padding:5px 0;
               border-bottom:1px solid var(--op-line);font-size:12px;}
.optimeline li:last-child{border-bottom:0;}
.optime{font-family:var(--mono);color:var(--op-muted);flex:none;}
.opkind{
  flex:none;padding:1px 7px;border-radius:4px;font-size:12px;font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;color:#08171A;
}
.opkind-strike,.opkind-mass_casualty{background:var(--op-critical);}
.opkind-medevac_launch,.opkind-medevac_complete{background:var(--op-accent);}
.opkind-hospital_alert{background:var(--op-severe);}
.opkind-front_line{background:#B2A6F0;}
.opkind-line_update{background:var(--op-muted);}

.opbottom{display:grid;gap:12px;padding:0 16px 16px;
          grid-template-columns:repeat(auto-fit,minmax(280px,1fr));}
.opbars{display:flex;flex-direction:column;gap:7px;}
.opbar-row{display:grid;grid-template-columns:64px 1fr 44px 38px;gap:8px;align-items:center;font-size:12px;}
/* Both are spans, so both have to be told to be boxes. `.opbar-fill` was left
   inline, which ignores width and height entirely: every bar on the triage and
   facility panels was 0 by 0, so the numbers were there and nothing was drawn
   beside them. */
.opbar-track{display:block;height:12px;background:var(--op-row);border-radius:3px;overflow:hidden;}
.opbar-fill{display:block;height:100%;border-radius:3px;min-width:2px;}
/* The occupancy bands, named by operational.FACILITY_BANDS. The colour is here
   rather than in the template so the band a bar draws and the band the Medical
   facilities tab counts are one decision. */
.opbar-fill.opbar-at-capacity,.opbar-fill.opbar-pressure{background:var(--op-critical);}
.opbar-fill.opbar-busy{background:var(--op-severe);}
.opbar-fill.opbar-normal{background:var(--op-accent);}
/* The ring takes the room it is given rather than a fixed 132px, which left it
   small in the corner of its card with the legend floating beside it.

   It wraps, so on a narrow card the legend goes under the ring instead of the
   two fighting over a width that will not hold both. */
.opdonut{display:flex;gap:16px;align-items:center;flex-wrap:wrap;}
.opdonut-ring{
  /* Never wider than the card and never wider than it is useful. `min()`
     rather than a `max-width`, so the cap holds even where a flex line has
     told the element how wide it is. */
  flex:0 1 auto;width:min(100%,210px);min-width:0;height:auto;aspect-ratio:1;
}
/* No font size here on purpose.
   
   The centre label's size depends on how many characters the total has, which
   a stylesheet cannot know, and these two rules used to state one anyway: 19
   and 8 user units in a 42 unit box, which is a numeral almost half the height
   of the whole drawing. It overflowed the hole at every value and was simply
   less obvious while the ring was pinned at 132px. The size is computed in
   `operational.donut_label` and written inline on the element. */
.opdonut-total{font-weight:700;fill:var(--op-text);text-anchor:middle;}
.opdonut-cap{fill:var(--op-muted);text-anchor:middle;letter-spacing:.12em;
             text-transform:uppercase;}
.oplegend{list-style:none;margin:0;padding:0;font-size:13px;flex:1;min-width:130px;}
.oplegend li{display:flex;align-items:center;gap:7px;padding:2px 0;}
.oplegend i{width:10px;height:10px;border-radius:2px;flex:none;}
.oplegend b{margin-left:auto;font-variant-numeric:tabular-nums;}
/* The trend chart: legend on top, a y axis from zero beside a plot that takes
   every pixel left, and the x axis under the plot. The drawing is stretched to
   the plot (preserveAspectRatio none) with strokes that do not scale, and the
   markers sit over it as HTML so they stay round. On its own, in the analytics
   tab, the plot is given a height; in the bottom row the card gives it one. */
.optrendbox{display:flex;flex-direction:column;flex:1 1 auto;min-height:0;}
.optrend-legend{display:flex;flex-wrap:wrap;gap:3px 12px;list-style:none;margin:0 0 6px;
                padding:0;font-size:13px;color:var(--op-text);}
.optrend-legend li{display:flex;align-items:center;gap:6px;}
.optrend-legend i{width:8px;height:8px;border-radius:50%;flex:none;}
/* T4's black key and markers carry the chip's white edge, as its line runs
   over a white one (`_picture_trend.html`), or they vanish on the panel. */
.optrend-key-T4,.optrend-dot-T4{box-shadow:0 0 0 1px var(--op-t4-border);}
.optrend-body{display:grid;grid-template-columns:auto minmax(0,1fr);
              grid-template-rows:minmax(0,1fr) auto;column-gap:6px;
              flex:1 1 auto;min-height:150px;}
.optrend-yaxis{position:relative;grid-row:1;grid-column:1;font-size:12px;
               color:var(--op-muted);font-variant-numeric:tabular-nums;}
.optrend-yaxis span{position:absolute;right:0;transform:translateY(50%);white-space:nowrap;}
.optrend-yaxis .optrend-ysizer{position:static;display:block;visibility:hidden;height:0;transform:none;}
.optrend-plot{position:relative;grid-row:1;grid-column:2;min-height:0;}
.optrend{position:absolute;inset:0;width:100%;height:100%;display:block;overflow:visible;}
/* Faint, well behind the lines. */
.optrend-grid{stroke:var(--op-line);stroke-width:1;vector-effect:non-scaling-stroke;opacity:.6;}
.optrend-dots{position:absolute;inset:0;pointer-events:none;}
.optrend-dot{position:absolute;width:5px;height:5px;margin:-2.5px 0 0 -2.5px;border-radius:50%;}
.optrend-body .optrend-axis{grid-row:2;grid-column:2;}
/* Axis labels placed under their own bucket. The first sits flush left and the
   last flush right, so neither hangs off the panel. */
.optrend-axis{position:relative;height:13px;margin-top:3px;font-size:12px;color:var(--op-muted);}
.optrend-axis span{position:absolute;top:0;transform:translateX(-50%);white-space:nowrap;}
.optrend-axis span:first-child{transform:none;}
.optrend-axis span:last-child:not(:first-child){transform:translateX(-100%);}
/* Invisible hover bands, one per bucket. A 1.8px line is not a pointer target,
   so the band is the whole height of the chart and the reader points at a
   moment rather than at a stroke. */
.optrend-hit{fill:transparent;}
.optrend-hit.fhovered{fill:rgba(255,255,255,.05);}
.opfac{font-size:12px;margin-bottom:9px;}
.opfac-name{display:flex;justify-content:space-between;gap:8px;margin-bottom:3px;}

/* --- the four cards under the map ------------------------------------------
   The content fills the card. The cards share their height with the map row
   above, and the band's handle moves the line between them
   (static/js/picture-band.js sets --op-bottom). Every load and every section
   switch starts the cards at their minimum and gives the rest to the map row
   (BIO-85): `--op-bottom-min`, the least height at which every card is whole
   on a typical window, measured in a browser at 1181 to 1920 wide. The
   script never raises it (4 November 2026): where a card's contents need
   more, its list scrolls inside the card. Below
   1180 the cards stack and every row has that same minimum, so a chart that
   fills its card has a height to fill; without JavaScript the rows are the
   minimum too. */
.opbottom{--op-bottom-min:200px;grid-auto-rows:var(--op-bottom, var(--op-bottom-min));}
.opbottom > .oppanel{display:flex;flex-direction:column;min-height:0;margin:0;}
.opbottom > .oppanel{container-type:size;}
.opbottom .optrend-body{min-height:0;}
/* The lists inside the cards scroll rather than push the card taller, so the
   cards open at their minimum whatever the data (picture-band.js). */
.opbottom .optriage,.opbottom .opfacs,.opbottom .opdonut .oplegend{overflow-y:auto;}
.opcardhead{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:0 0 8px;}
.opcardhead h2{margin:0;}
/* The page's range, in the place and the look of the reference's dropdown,
   and plainly not one: no chevron, no pointer, nothing to focus. */
.oprangebox{font-size:12px;color:var(--op-text);background:var(--op-row);
            border:1px solid var(--op-line);border-radius:6px;padding:3px 10px;
            white-space:nowrap;cursor:default;user-select:none;}
/* Triage: bars about three times the weight they were, spread down the card. */
.opbottom .optriage{flex:1 1 auto;min-height:0;justify-content:space-between;gap:6px;}
.opbottom .optriage .opbar-row{flex:1 1 0;min-height:0;}
/* The triage rows name their category in full, "T4 Expectant" and "Not
   categorised" the longest, on one line: 64 pixels clipped them (4 November
   2026). The same width on every row, so the bars still start together. */
.optriage .opbar-row{grid-template-columns:104px 1fr 44px 38px;}
.optriage .opbar-row > span:first-child{white-space:nowrap;}
.opbottom .optriage .opbar-track{height:min(62%,40px);min-height:12px;}
/* Facility status: the same rows, spread down the card. */
.opfacs{display:flex;flex-direction:column;justify-content:space-between;flex:1 1 auto;min-height:0;}
.opfacs .opfac{margin-bottom:0;}
/* Injury pattern: the ring beside its legend, taking the card's height, and
   never so much width that the legend, whose text does not change size, has
   less than its 130 pixels. At 1512 it used to wrap, legend under ring, which
   is what made that row 411 tall. */
.opbottom .opdonut{flex:1 1 auto;min-height:0;flex-wrap:nowrap;}
.opbottom .opdonut-ring{width:min(calc(100% - 146px), calc(100cqh - 25px));}
/* As a card shortens, its contents close up rather than clip. Measured on the
   card's own inside height, because the reader sets it with the band's
   handle; each figure below is that inside height, which is the card less 24.
   Each step is the least that keeps everything whole, and the text never gets
   smaller than the trend legend's 10 pixels. At the default at 1512 (cards
   323) only the first applies. */
@container (max-height:300px){
  .opfacs .opfac-name{margin-bottom:2px;}
  .opfacs .opbar-track{height:9px;}
}
@container (max-height:240px){
  .opfacs .opfac-name{margin-bottom:1px;}
  .opfacs .opbar-track{height:6px;}
  .opbottom .opdonut .oplegend li{padding:0;}
}
@container (max-height:190px){
  .opfacs .opfac{line-height:1.2;}
  .optrend-legend{font-size:13px;margin-bottom:3px;gap:2px 9px;}
  /* Every other label on the y axis, keeping nought and the top, so the
     labels do not crowd a short plot. The gridlines all stay. */
  .optrend-yaxis span:nth-child(2n+3):not(:last-child){visibility:hidden;}
}
/* Anything a filter note pushes past the card scrolls inside it. */
.opfacs{overflow:auto;}

/* --- the map row, one band ------------------------------------------------
   One height, `--op-band`, set by static/js/picture-band.js from what is on
   the screen and dragged by the reader. The rail, the map and the two lists
   take it together, so the three columns start and end on the same two lines,
   and each scrolls inside itself so none of them can grow the band. The grid's
   bottom padding is the handle, so nothing below moves. Below 1180 the row
   stacks and there is no band. */
.opbandhandle{display:none;}
@media (min-width:1181px){
  .opview .opgrid:not(.opgrid-tab){padding-bottom:0;}
  .opview .oppanel-map{height:var(--op-band,auto);display:flex;flex-direction:column;}
  .opview .oppanel-map > .opmap{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;}
  .opview .oppanel-map .geomap{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;}
  .opview .oppanel-map .geomap-dark .geomap-plot{height:auto;max-height:none;flex:1 1 0;min-height:0;}
  .opbandhandle{
    display:block;position:relative;height:16px;margin:0 16px;
    cursor:row-resize;touch-action:none;outline:none;
  }
  /* A line along the edge and a grip in the middle, faint until the pointer
     or the keyboard is on it. */
  .opbandhandle::before{content:"";position:absolute;left:0;right:0;top:7px;height:2px;
                        border-radius:2px;background:transparent;}
  .opbandhandle::after{content:"";position:absolute;left:50%;top:5px;width:48px;height:6px;
                       margin-left:-24px;border-radius:3px;background:var(--op-line);}
  .opbandhandle:hover::before,.opbandhandle:focus-visible::before,
  .opband-dragging .opbandhandle::before{background:var(--op-accent);}
  .opbandhandle:hover::after,.opbandhandle:focus-visible::after,
  .opband-dragging .opbandhandle::after{background:var(--op-accent);}
  .opbandhandle:focus-visible{box-shadow:inset 0 0 0 2px var(--op-accent);border-radius:4px;}
  .opband-dragging,.opband-dragging *{cursor:row-resize !important;user-select:none;}
}

/* Nation and Nationality, two to a row in equal columns, with All alone at the
   top of each list at a column's width. The rail's width is what makes room.
   A name that did not fit would be cut at the pill's edge rather than wrapped
   or shrunk; at 420 none needs to be (measured in DASHBOARD.md). */
.opview:not(.oprail-shut) .oprail .opchips{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;
}
.opview:not(.oprail-shut) .oprail .opchips > .opchip:first-child{
  grid-column:1 / -1;width:calc(50% - 3px);
}
.opview:not(.oprail-shut) .oprail .opchip{min-width:0;white-space:nowrap;overflow:hidden;}
/* At narrow widths the name gives way, with an ellipsis, and the flag and the
   two letter code always show: the code is the identifier, the name is help. */
.opview:not(.oprail-shut) .oprail .opchip > .opflagimg,
.opview:not(.oprail-shut) .oprail .opchip > .opflag{flex:none;}
.opview:not(.oprail-shut) .oprail .opchip > span:not(.opflag){min-width:0;overflow:hidden;text-overflow:ellipsis;}

/* --- the operating picture's map layers ---------------------------------
   
   Record level, and only on this surface. The research view's map is the same
   component with no layers passed to it, so none of the rules below have
   anything to match there.
   
   Every colour is measured against the darkened relief rather than judged, and
   the measurements are in DASHBOARD.md. */

/* The bundled Natural Earth detail. Filled in by the script as the reader
   zooms, one band at a time, fetched from this platform. */
.gm-urban path{fill:var(--gm-urban);fill-opacity:.5;stroke:none;}
.gm-lakes path{fill:var(--gm-water);fill-opacity:.75;stroke:none;}
.gm-rivers path{fill:none;stroke:var(--gm-water);stroke-width:.9;stroke-opacity:.85;}
.gm-rail path{fill:none;stroke:var(--gm-rail);stroke-width:.5;stroke-opacity:.75;
              stroke-dasharray:2.4 1.6;}
.gm-roads path{fill:none;stroke:var(--gm-road);stroke-width:.55;stroke-opacity:.7;}
.gm-motorways path{fill:none;stroke:var(--gm-motorway);stroke-width:.9;stroke-opacity:.85;}

/* Names. Sized in projection units so they scale with the map, and given a
   dark halo rather than a box, because a box over a town is a box over the
   thing being named. */
.gm-placenames text,.gm-countrynames text{
  fill:var(--gm-label);text-anchor:middle;pointer-events:none;
  paint-order:stroke fill;stroke:var(--gm-label-ink);stroke-width:2.4;
  stroke-linejoin:round;font-weight:600;
}
/* Relative to the group, whose size the script sets against the frame. A
   number here would be a number in the drawing's units, which is a name that
   doubles in size every time somebody zooms in. */
/* Relative to the group, whose size the script sets to 11 screen pixels in
   the map's own units. The proportions give 10.5px country names, 11px towns,
   11.5px busier places and 12px capitals, and 12px is the most any name on the
   map may be. A number in px here would be a number in map units, which is a
   name that doubles every time somebody zooms in. */
.gm-countrynames text{
  font-size:.9545em;letter-spacing:.16em;text-transform:uppercase;fill-opacity:.62;
  stroke-width:.5em;
}
.gm-placenames text{font-size:1em;stroke-width:.4em;}
.gm-placenames text[data-weight="1"]{font-size:1.0909em;fill:#EAF3F7;}
.gm-placenames text[data-weight="2"]{font-size:1.0455em;}

/* Where reporting is concentrated. A soft edge, because a hard one reads as a
   line somebody drew on the ground, and this is not that. */
.gm-areas circle{
  fill:var(--op-severe);fill-opacity:.10;stroke:var(--op-severe);
  stroke-opacity:.30;stroke-width:.8;stroke-dasharray:5 4;
}
/* ARRIVALS, AS A PULSE. A ring expanding from the place's own circle and
   fading, so somebody watching sees where things are developing without
   reading the feed.

   THE COLOUR IS THE TRIAGE BAND OF WHAT ARRIVED, taken from the same
   `--op-*` tokens and the same `gm-sev-*` classes the cluster markers and the
   triage bars use. Red was asked for and refused: red is T1 on this map, and
   a red ring for a minor casualty would tell a commander something false in
   the half second before they read the count. A burst shows its worst.

   NO FILL. The ring is a stroke only, so it never tints what is under it and
   never reads as a shape on the ground. `gm-sev-*` sets a fill, so it is
   turned off here rather than a second set of colour rules being written. */
.gm-pulses{pointer-events:none;}
.gm-pulse{
  fill:none;stroke:currentColor;vector-effect:non-scaling-stroke;
  transform-box:fill-box;transform-origin:center;
  animation:gmpulse 2.4s cubic-bezier(.16,.7,.3,1) forwards;
}
.gm-pulse-T1{color:var(--op-t1);}
.gm-pulse-T2{color:var(--op-t2);}
.gm-pulse-T3{color:var(--op-t3);}
/* A black ring on a dark map is no ring: T4 pulses in its white edge. */
.gm-pulse-T4{color:var(--op-t4-border);}
.gm-pulse-none{color:var(--op-t-none);}
/* One ring per place per eight second refresh, running for 2.4 seconds: 0.125
   pulses a second at the very most, against a photosensitivity limit of three.
   Slow on purpose, so several areas pulsing together read as a picture rather
   than as an alarm. */
@keyframes gmpulse{
  from{transform:scale(.25);}
  to{transform:scale(1);opacity:0;}
}
/* A REGION ARRIVAL washes the region's own shape rather than expanding a ring
   from a point, because a posted report names a region and carries no place.
   A stroke and a very light fill, so the shape brightens and fades without
   ever reading as a new boundary. */
/* FILL ONLY, NEVER A STROKE. A stroked region reads as a line somebody drew
   on the ground, which is the thing this map refuses everywhere else
   (`tests_boundaries`), and a wash that outlined a region for two seconds
   would be making that claim for two seconds. The region lights up instead. */
.gm-wash{
  fill:currentColor;fill-opacity:.30;stroke:none;
  animation:gmwash 2.4s cubic-bezier(.16,.7,.3,1) forwards;
}
/* NO `from`. An animated property takes the keyframes' value over the
   element's own, so a `from{opacity:1}` here threw away the strength the
   script had just set and every wave washed at the same weight however many
   had arrived. With only a `to`, the animation starts from what is on the
   element, which is where the count is carried. */
@keyframes gmwash{
  to{opacity:0;}
}

/* REDUCED MOTION: nothing moves. The arrival is a state on the place's own
   circle, which the next refresh clears, rather than a ring going anywhere.
   Motion was never the only signal: the counts, the live feed and the
   timeline all change as they did before. */
@media (prefers-reduced-motion: reduce){
  .gm-pulse,.gm-wash{display:none;animation:none;}
}
.gm-areas circle.gm-arrived{
  fill-opacity:.20;stroke-opacity:.75;stroke-width:1.6;stroke-dasharray:none;
}
/* The still state for a region, for reduced motion. A fill again, for the
   reason the wash above is a fill. */
.geomap-shape.gm-arrived path{fill-opacity:.42;}

.gmkey .gm-areakey,.gmlayer-swatch .gm-areakey{
  fill:var(--op-severe);fill-opacity:.14;stroke:var(--op-severe);
  stroke-opacity:.5;stroke-width:1.4;stroke-dasharray:3 2.4;
}

/* Population centres: a small light dot with a dark ring, the same in the
   layers panel as on the map, sized in screen pixels by the script like the
   facility markers. Gridlines: hairlines that stay a hairline at any zoom. */
.gm-town{fill:var(--gm-label);fill-opacity:.9;stroke:var(--gm-label-ink);stroke-width:1.2;}
.gm-towns g{pointer-events:auto;}
.gm-grid line,.gm-grid path{
  fill:none;stroke:var(--gm-label);stroke-opacity:.22;stroke-width:1;
  vector-effect:non-scaling-stroke;pointer-events:none;
}

/* Movements. Dashed and animated so they read as movement rather than as
   boundaries, and the animation stops for anybody who has asked it to. */
.gm-route{
  stroke-width:1;stroke-opacity:.55;stroke-dasharray:6 5;fill:none;
  stroke-linecap:round;
}
.gm-route-en_route{stroke:var(--op-accent);}
.gm-route-in_transit{stroke:var(--op-moderate);}
.gm-routes line:hover{stroke-opacity:1;stroke-width:1.8;}
.gm-asset{stroke:var(--gm-edge);stroke-width:.6;}
.gm-asset-en_route{fill:var(--op-accent);}
.gm-asset-in_transit{fill:var(--op-moderate);}
@media (prefers-reduced-motion: no-preference){
  .gm-routes line{animation:gmflow 1.6s linear infinite;}
}
@keyframes gmflow{to{stroke-dashoffset:-11;}}

/* Facilities. A square with a cross in it, so it is told apart from a cluster
   by shape and not only by colour. */
.gm-facility{stroke:var(--gm-edge);stroke-width:1;}
.gm-facility-at-capacity,.gm-facility-pressure{fill:var(--op-critical);}
.gm-facility-busy{fill:var(--op-severe);}
.gm-facility-normal{fill:var(--op-accent);}
.gm-cross{fill:var(--gm-edge);}
.gm-facilities g{cursor:pointer;}

/* Incident clusters. The halo is what makes a marker readable over relief and
   over another marker; the disc carries the count. */
.gm-halo{fill-opacity:.16;stroke:none;}
.gm-cluster{fill-opacity:.85;stroke:var(--gm-edge);stroke-width:1;}
.gm-sev-T1{fill:var(--op-t1);stroke-opacity:.9;}
.gm-sev-T2{fill:var(--op-t2);}
.gm-sev-T3{fill:var(--op-t3);}
.gm-sev-none{fill:var(--op-t-none);}
/* Expectant on the map, which is the one that needs care.

   Black is the treatment a T4 tag has, and on the dark theme `--gm-edge` is
   #0B1418: a black disc drawn the ordinary way has a near black rim and near
   black digits on it and disappears into the ground. Measured rather than
   assumed, the fill is 1.11:1 against that ground, so the fill cannot be the
   thing that makes this readable.

   So the rim is. It is the T4 chip's own white border, which reads against
   black on both themes and against both map grounds, and it is heavier than
   every other marker's, so the difference is a shape as well as a colour and
   survives any colour vision deficiency. The halo is pale rather than a tint
   of the fill: a black halo at 16 per cent is nothing at all, and a pale one
   puts the disc in a surround instead of a hole. The band is on the wrapping
   group because the count is a sibling of the circles and a class on a circle
   cannot reach it. */
.gm-sev-T4{fill:var(--op-t4);}
.gm-band-T4 .gm-cluster{stroke:var(--op-t4-border);stroke-width:1.6;
  stroke-opacity:1;fill-opacity:1;}
.gm-band-T4 .gm-halo{fill:var(--op-t4-border);fill-opacity:.22;}
.gm-band-T4 .gm-count{fill:var(--op-t4-ink);}
.gm-count{
  fill:var(--gm-edge);font-size:7px;font-weight:700;text-anchor:middle;
  pointer-events:none;
}
.gm-incidents g{cursor:pointer;}
.gm-incidents g:hover .gm-cluster,.gm-facilities g:hover .gm-facility{
  stroke:var(--op-text);stroke-width:1.6;
}

/* The key, as a strip under the map. It sat over the map bottom right and
   that corner held the three busiest clusters on the screen. */
.gmkey{
  margin-top:6px;background:var(--gm-control-bg);border:1px solid var(--gm-control-line);
  border-radius:7px;color:var(--op-text);font-size:12px;line-height:1.3;
  display:flex;align-items:stretch;
}
.gmkey summary{
  cursor:pointer;list-style:none;padding:6px 10px;font-size:12px;
  letter-spacing:.12em;text-transform:uppercase;color:var(--op-muted);
  font-weight:700;display:flex;align-items:center;gap:8px;flex:none;
}
.gmkey summary::-webkit-details-marker{display:none;}
.gmkey-mark{
  width:0;height:0;border-top:4px solid transparent;border-bottom:4px solid transparent;
  border-left:5px solid currentColor;transition:transform .12s ease;
}
.gmkey[open] .gmkey-mark{transform:rotate(180deg);}
.gmkey summary:hover{color:var(--op-accent);}
.gmkey-body{
  display:flex;flex-wrap:wrap;align-items:center;gap:4px 16px;padding:5px 10px;
  border-left:1px solid var(--gm-control-line);
}
/* Each row is a button to press and hold (static/js/map-solo.js), reset so it
   reads as the label it was. The padding is taken back by the margin, so the
   strip is laid out exactly as before. No long press menu or text selection
   on a touch screen, and a finger that moves still scrolls the page. */
.gmkey-row{display:inline-flex;align-items:center;gap:6px;cursor:help;
  font:inherit;color:inherit;background:none;border:0;border-radius:5px;
  padding:2px 5px;margin:-2px -5px;text-align:left;
  touch-action:manipulation;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;}
.gmkey-row:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
/* The row being held. A ring as well as a fill, so colour is not the only
   thing that says which one. */
.gmkey-row.gmkey-held{background:var(--op-panel);color:var(--op-text);box-shadow:inset 0 0 0 1.5px var(--op-accent);}
.gmkey-swatch{flex:none;width:15px;height:15px;}
.gmkey-swatch svg{width:15px;height:15px;overflow:visible;}
.gmkey-scale{display:flex;gap:1.5px;align-items:center;}
.gmkey-scale i{width:2.5px;height:10px;background:var(--gm-ink);border-radius:1px;}
.gmkey-scale i[data-band="1"]{opacity:.25;}
.gmkey-scale i[data-band="2"]{opacity:.4;}
.gmkey-scale i[data-band="3"]{opacity:.58;}
.gmkey-scale i[data-band="4"]{opacity:.78;}
.gmkey-scale i[data-band="5"]{opacity:1;}
.gmkey-note{color:var(--op-muted);margin-left:auto;}

/* The map's panel, with less of it between the map and the edge. The header
   is one line and the padding is enough that the panel's own rounded corner
   never cuts into the plot. */
.oppanel-map{padding:7px 8px 7px;}
.opmap-head{
  display:flex;justify-content:space-between;align-items:baseline;gap:10px;
  margin-bottom:5px;
}
.opmap-head h2{margin:0;}
.opmap-head span{font-size:12px;color:var(--op-muted);}

/* Lines that stay lines. Drawn in the map's units, a motorway was 0.9 units
   wide, which is 2px at the world view and 25px at the closest: zooming in
   thickened every road into a band. `non-scaling-stroke` holds a stroke at its
   screen width whatever the zoom, so the widths below are pixels. */
.geomap-dark [data-geomap-detail] path,
.gm-routes line,.gm-areas circle{vector-effect:non-scaling-stroke;}
.gm-rivers path{stroke-width:1.1;}
.gm-rail path{stroke-width:.9;stroke-dasharray:4 3;}
.gm-roads path{stroke-width:.8;}
.gm-motorways path{stroke-width:1.4;}
.gm-routes .gm-route{stroke-width:1.5;stroke-dasharray:7 5;}
.gm-areas circle{stroke-width:1;stroke-dasharray:6 4;}

/* The count on a cluster is sized by the script, in the marker's own pixel
   space, and hidden when it would not fit inside its disc. */
.gm-incidents .gm-count{
  fill:var(--gm-edge);font-weight:700;text-anchor:middle;pointer-events:none;
}
/* A count too big for its disc, drawn beside it, with a dark halo so it
   reads over relief and roads. */
.gm-incidents .gm-count-out{
  text-anchor:start;fill:var(--op-text);paint-order:stroke fill;
  stroke:var(--gm-edge);stroke-width:3px;stroke-linejoin:round;
}
/* The region shading fades as the reader zooms in; the script sets how much.
   Only on this surface: the research view never sets the property, so its
   shading is drawn exactly as before. */
/* Region shading. The script sets --gm-shade from the zoom (1 far out, a
   quarter close in); the counted regions are drawn at half of that on top, in
   every state. One multiplier on the whole shape, so hovered and not, selected
   and not, keep exactly the ratio they had and only the whole gets lighter. */
.geomap-dark{--gm-shade-base:.5;}
.geomap-dark [data-geomap-shapes] > .geomap-shape{opacity:var(--gm-shade,1);}
.geomap-dark [data-geomap-shapes] > [data-band]{
  opacity:calc(var(--gm-shade,1) * var(--gm-shade-base));
}
/* The close zoom relief: shaded hills only, mid grey where the ground is flat
   or wet, so an overlay blend changes nothing but the slopes. */
.geomap-dark .geomap-relief{
  mix-blend-mode:overlay;opacity:0;pointer-events:none;transition:opacity .25s ease;
}
.gm-merged .gm-cluster{stroke-dasharray:3 2;}
.gm-merged{cursor:zoom-in;}

/* --- the sections beside the operating picture --------------------------
   
   One visual language, not five. Every rule below reuses the surface's own
   properties (`--op-panel`, `--op-line`, `--op-text`, `--op-muted`, the
   severity colours) rather than introducing a palette, so a change to the
   picture's theme moves the sections with it. Where a section needed a shape
   the picture did not have, the shape is new and the colours are not. */

/* The tab, when it is a real link. Same chip as the disabled one, so the two
   sit on one line without the built ones jumping. */
a.optab{text-decoration:none;}
a.optab:hover{background:var(--op-row);color:var(--op-text);}
.optab.opbusy{opacity:.6;}
/* While a section is being fetched. Deliberately slight: a reader pressing a
   column heading should see that something is happening without the table
   flashing. */
#optab.opbusy{opacity:.72;transition:opacity .12s ease;}

.opgrid-tab{grid-template-columns:260px minmax(0,1fr);}
/* Reports and Admin, where no carried filter applies (BIO-146): one column. */
.opview .opgrid.opgrid-norail,.opview.oprail-shut .opgrid.opgrid-norail,.opgrid.opgrid-norail{grid-template-columns:minmax(0,1fr);}
.opnorail{margin:0 0 12px;}

/* The filter bar. */
.opfilters{padding:8px 16px 0;}
.opfilterbar{
  display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end;
  background:var(--op-panel);border:1px solid var(--op-line);
  border-radius:9px;padding:11px 13px;
}
.opfield{display:flex;flex-direction:column;gap:4px;font-size:12px;min-width:150px;}
.opfield > span{
  font-size:12px;letter-spacing:.1em;text-transform:uppercase;
  color:var(--op-muted);font-weight:700;
}
.opfield-wide{flex:1 1 200px;}
/* More filters (BIO-105): a button in the bar whose panel floats over the
   list, so opening it moves nothing below. */
.opmore{position:relative;align-self:flex-end;}
.opmore > summary{list-style:none;}
.opmore > summary::-webkit-details-marker{display:none;}
.opmore-body{
  position:absolute;left:0;top:calc(100% + 6px);z-index:30;display:flex;flex-wrap:wrap;gap:10px;
  background:var(--op-panel);border:1px solid var(--op-line);border-radius:9px;padding:11px 13px;
  box-shadow:0 10px 24px rgba(0,0,0,.35);width:max-content;max-width:min(560px,80vw);
}
.opfield select,.opfield input{
  background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);
  border-radius:6px;padding:6px 8px;font:inherit;font-size:12px;width:100%;
}
.opfield select:focus,.opfield input:focus{
  outline:2px solid var(--op-accent);outline-offset:1px;
}
.opbtn{
  background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);
  border-radius:6px;padding:7px 14px;font:inherit;font-size:12px;font-weight:600;
  cursor:pointer;text-decoration:none;display:inline-block;
}
.opbtn:hover{border-color:var(--op-accent);color:var(--op-accent);}
/* The refresh control: Refresh, the same button as Apply with an icon, then
   how long ago the screen was brought up to date (feeds/_refresh_control.html),
   in the menu row after the "?" since BIO-84.
   The status is body text; failed is the alert colour; New reports is a pill
   in it. Each measured against the panel in tests_live_refresh. */
.oprefresh{display:inline-flex;align-items:center;gap:10px;white-space:nowrap;}
.oprefresh-btn{display:inline-flex;align-items:center;gap:6px;}
/* In the menu row it reads as a menu item (1 October): no border in any
   state, nothing behind it at rest, and the accent on hover as before. The
   border's pixel goes into the padding, so the button keeps its size. Focus
   keeps the browser's own ring, as the section tabs beside it do. */
.optabs .oprefresh-btn,.optabs .oprefresh-btn:hover,.optabs .oprefresh-btn:focus,
.optabs .oprefresh-btn:active{border:0;background:transparent;}
.optabs .oprefresh-btn{padding:8px 15px;}
.optabs .oprefresh-btn:hover{color:var(--op-accent);}
.oprefresh-status{font-size:12px;color:var(--op-text);font-variant-numeric:tabular-nums;}
.oprefresh-status[data-state="failed"]{color:var(--op-alert);font-weight:600;}
.oprefresh-new{font-size:12px;font-weight:700;color:#08171A;background:var(--op-alert);border-radius:4px;padding:2px 7px;}
.opbtn-quiet{font-weight:500;}
.opbtn-off{opacity:.45;cursor:default;}
.opbtn-off:hover{border-color:var(--op-line);color:var(--op-text);}

/* What is currently applied, and how to take it off. */
.opapplied{display:flex;flex-wrap:wrap;gap:7px;align-items:center;padding:9px 2px 0;}
.opapplied-say{font-size:13px;color:var(--op-muted);}
.optag{
  display:inline-flex;align-items:center;gap:6px;font-size:12px;
  background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);
  border-radius:999px;padding:3px 10px;text-decoration:none;
}
.optag:hover{border-color:var(--op-accent);color:var(--op-accent);}
.optag b{font-weight:700;}
.optag-clear{color:var(--op-muted);}
.opdropped{
  margin:8px 2px 0;font-size:12px;color:var(--op-severe);
}

/* The table and its record panel, side by side. */
.opsplit{display:grid;gap:12px;padding:12px 16px 16px;grid-template-columns:minmax(0,1fr);}
/* The record list is the work on this section, so it takes the height the
   panels on the operating picture take rather than the 290px a panel sharing a
   column with three others gets. A viewport measure, like the picture's own row,
   so it is proportionate on a laptop and on a wall display without choosing
   between them. */
.opcasualties .opscroll{max-height:none;height:clamp(320px,calc(100vh - 430px),820px);overflow:auto;}
/* The count floats right of the heading and drops below it when the panel is
   narrow. Contained here, or the scrolling table beside it shrinks to fit
   round the float (123px at 375px wide). */
.opcasualties > h2{display:flow-root;}
.opsplit-open{grid-template-columns:minmax(0,1fr) 10px min(var(--oprecord-w,340px),60vw,calc(100% - 378px));column-gap:4px;}
.opcasualties{margin-bottom:0;}
.oppanel h2 .opcount{
  float:right;font-size:12px;letter-spacing:.06em;text-transform:none;
  color:var(--op-muted);font-weight:500;
}
/* The record list is a table in a whole column rather than in a 380px panel,
   so it undoes the picture's column widths rather than inheriting them.
   
   Those widths exist because the live feed sits in a narrow panel beside the
   map and every column had to be told what to give up. Inherited here they
   truncated the time to "16..", the severity to "CRITICA" and the status to
   "MEDEVA...", in a table with four hundred spare pixels beside it. */
.optable-wide{table-layout:auto;font-size:12px;}
.optable-wide th:nth-child(n),.optable-wide td:nth-child(n){width:auto;}
.optable-wide th,.optable-wide td{
  white-space:nowrap;overflow:visible;text-overflow:clip;padding:6px 10px;
}
.optable-wide td.opcell-key{white-space:normal;}
/* With a record open beside the list at 1512 the list is 31px wider than its
   panel once Nation and Nationality are both there, and the panel clips it. The
   stage and the facility, the two longest phrases, wrap there instead. */
.opsplit-open .optable-wide td.opcell-yield{white-space:normal;}
.optable-wide th:nth-child(3),.optable-wide td:nth-child(3){
  width:44px;text-align:center;
}
.opsortable a{
  color:inherit;text-decoration:none;display:inline-flex;align-items:center;gap:4px;
}
.opsortable a:hover{color:var(--op-accent);}
.opsorted{color:var(--op-text);}
.opsortmark{font-size:8px;}
.opcell-time{font-variant-numeric:tabular-nums;}
.opcell-open{text-align:right;}
.opopenlink{color:var(--op-accent);text-decoration:none;font-weight:600;}
.opopenlink:hover{text-decoration:underline;}
.oprow.opopen{background:var(--op-row);}
/* The open record's row, marked two ways so neither depends on the other: a
   2px border in the Open link's green, and an arrowhead after the link that
   is a shape before it is a colour. The border is drawn as inset shadows on
   the cells, which take no space, and the arrow's slot is reserved on every
   row, so opening or closing a record moves nothing. */
.oprow.opopen td{box-shadow:inset 0 2px 0 var(--op-accent),inset 0 -2px 0 var(--op-accent);}
.oprow.opopen td:first-child{box-shadow:inset 2px 0 0 var(--op-accent),inset 0 2px 0 var(--op-accent),inset 0 -2px 0 var(--op-accent);}
.oprow.opopen td:last-child{box-shadow:inset -2px 0 0 var(--op-accent),inset 0 2px 0 var(--op-accent),inset 0 -2px 0 var(--op-accent);}
.opcell-open::after{
  content:"";display:inline-block;width:0;height:0;margin-left:7px;vertical-align:-1px;
  border-top:6px solid transparent;border-bottom:6px solid transparent;
  border-left:8px solid transparent;
}
.oprow.opopen .opcell-open::after{border-left-color:var(--op-accent);}
.opempty{padding:18px 0;text-align:center;color:var(--op-muted);}
.opnone{color:var(--op-muted);font-style:italic;}
.oppager{display:flex;gap:10px;align-items:center;justify-content:flex-end;padding-top:10px;}
.oppager-say{font-size:13px;color:var(--op-muted);}

/* One casualty, in full. */
.opdetail{margin-bottom:0;align-self:start;}
.opdetail h2{display:flex;justify-content:space-between;align-items:center;gap:8px;}
.opclose{
  display:inline-flex;align-items:center;gap:5px;color:var(--op-muted);
  text-decoration:none;font-size:12px;letter-spacing:.06em;
}
.opclose:hover{color:var(--op-accent);}
.opdetail-head{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin-bottom:10px;}
.opdetail-nat{display:inline-flex;align-items:center;gap:6px;font-size:12px;}
.opdetail-nat .opnat-code{margin-left:0;}
.opdetail-natlabel{
  font-size:12px;letter-spacing:.1em;text-transform:uppercase;font-weight:700;
  color:var(--op-muted);
}
.opdetail-head3{
  margin:14px 0 6px;font-size:12px;letter-spacing:.12em;text-transform:uppercase;
  color:var(--op-muted);font-weight:700;
  border-top:1px solid var(--op-line);padding-top:10px;
}
.opdetail-facts{
  display:grid;grid-template-columns:auto 1fr;gap:4px 12px;margin:0;font-size:12px;
}
.opdetail-facts dt{color:var(--op-muted);}
.opdetail-facts dd{margin:0;color:var(--op-text);overflow-wrap:anywhere;}
/* A posted report's card: one label width for every section, so the values
   line up down the card rather than moving with each section's longest label. */
.opdetail-facts[data-section]{grid-template-columns:11em minmax(0,1fr);}
.opdetail-blank{
  margin:14px 0 0;padding-top:10px;border-top:1px solid var(--op-line);
  font-size:12px;color:var(--op-muted);
}

/* The summary row on a section, which is the picture's counter row in a
   narrower column rather than a second kind of card. */
.opcounters-tab{padding:8px 0 0;grid-template-columns:repeat(4,minmax(0,1fr));}

.optable-facilities td.opnum,.optable-facilities th:nth-child(n+4){
  text-align:right;font-variant-numeric:tabular-nums;
}
.optable-facilities th:nth-child(n+4) a{justify-content:flex-end;}
.opsub{color:var(--op-muted);font-size:12px;margin-left:4px;}
.opcell-bar{min-width:150px;}
.opcell-bar .opbar-track{width:100%;margin-bottom:3px;}
.opcell-bar b{font-size:12px;color:var(--op-text);}
/* One definition of pressure, drawn the same way the picture draws it. */
.opfac-at-capacity{background:var(--op-critical);}
.opfac-pressure{background:var(--op-critical);}
.opfac-busy{background:var(--op-severe);}
.opfac-normal{background:var(--op-accent);}
.opstate{
  display:inline-block;padding:2px 8px;border-radius:999px;font-size:12px;
  font-weight:700;color:#0B1418;
}
.opstate-at-capacity{background:var(--op-critical);}
.opstate-pressure{background:var(--op-critical);}
.opstate-busy{background:var(--op-severe);}
.opstate-normal{background:var(--op-accent);}
.optag-on{border-color:var(--op-accent);color:var(--op-accent);font-weight:600;}

.optable-evac td.opnum,.optable-evac th.opnum{
  text-align:right;font-variant-numeric:tabular-nums;
}
/* Every cell on one text line: the patient count, the chips, the stage, the
   time and View read across with First reported. */
.optable-evac td{vertical-align:baseline;}
.optable-evac td.opcell-mix{display:table-cell;}
/* One line, never stacked (5 November 2026): in the table a row is one line
   whatever its mix, the chips 4px apart rather than the mock's 6 so four fit
   the column; in the evacuation panel's narrower header the chips may wrap,
   onto two lines at most, since five chips take two. */
.opmixes{display:inline-flex;gap:4px;flex-wrap:nowrap;vertical-align:baseline;}
.opevac-sec h4 .opmixes{flex-wrap:wrap;max-height:56px;overflow:hidden;}
.opnone-dash{color:var(--op-muted);}
.opcell-mix{display:flex;gap:4px;flex-wrap:nowrap;}
/* The mix, as one chip per triage category present, T1 to T4 then Not
   categorised, in two parts (the approved mock, 5 November 2026): the code on
   the category's fill, then the count in a circle of that fill mixed toward
   white, so "T1 1" can no longer read as "T11". The `opsev-*` band gives the
   fill and the code's ink: dark on red, yellow and green, white on T4's black
   with its white border. */
.opmix{
  display:inline-flex;align-items:center;gap:6px;padding:3px 3px 3px 7px;
  border-radius:5px;font-family:var(--mono);font-size:13px;font-weight:600;line-height:1;
  white-space:nowrap;font-variant-numeric:tabular-nums;
}
.opmix-n{
  display:inline-grid;place-items:center;box-sizing:border-box;min-width:19px;height:19px;
  padding:0 5px;border-radius:999px;font-size:12px;font-variant-numeric:tabular-nums;
}
.opmix.opsev-T1 .opmix-n{background:var(--op-t1-in);color:var(--op-t1-in-ink);}
.opmix.opsev-T2 .opmix-n{background:var(--op-t2-in);color:var(--op-t2-in-ink);}
.opmix.opsev-T3 .opmix-n{background:var(--op-t3-in);color:var(--op-t3-in-ink);}
.opmix.opsev-T4 .opmix-n{background:var(--op-t4-in);color:var(--op-t4-in-ink);}
.opmix.opsev-none .opmix-n{background:var(--op-t-none-in);color:var(--op-t-none-in-ink);}

.optable-admin td.opnum,.optable-admin th{white-space:nowrap;}
.optable-admin td.opcell-key{display:table-cell;}
.optable-admin td.opcell-key img{vertical-align:-2px;margin-right:5px;}
.oprow-warn td{background:rgba(240,85,90,.08);}
.opadmin-rule{margin:0 0 10px;font-size:12px;color:var(--op-muted);line-height:1.5;}
.opadmin-absent{margin:0;padding-left:18px;font-size:12px;color:var(--op-muted);line-height:1.55;}
.opadmin-absent li{margin-bottom:7px;}
.opadmin-absent b{color:var(--op-text);}
.opscroll-short{max-height:250px;}
/* A table that may be wider than a phone scrolls sideways inside its panel,
   and positioned so its screen reader labels stay inside it too. */
.opwide{position:relative;overflow-x:auto;}
.oppanel h2 .opopenlink{float:right;font-size:12px;text-transform:none;letter-spacing:0;}

/* The summary charts. Two to a row on a wide screen, one on a narrow one, and
   every one of them is the picture's own panel with a chart in it. */
.opanalytics{
  display:grid;gap:12px;padding:12px 16px 16px;
  grid-template-columns:repeat(auto-fit,minmax(min(430px,100%),1fr));
  /* Tiles (BIO-107): a standard tile is one cell, a large one two by two,
     and the rest flow into the cells beside it. Row flow, not dense: dense
     packing back filled a gap with the add chart tile, which then sat above
     charts added before it, and it is always the last tile. */
  list-style:none;margin:0;grid-auto-rows:minmax(320px,auto);grid-auto-flow:row;
  container-type:inline-size;
}
.opanalytics .oppanel{margin-bottom:0;}
/* A large tile spans two columns only where there are two: one column wide,
   it stays one cell rather than pushing the page sideways. */
@container (min-width:872px){.optile-large{grid-column:span 2;grid-row:span 2;}}
.opnote-inline{margin:8px 0 0;border-radius:9px;}
.opnationbar{
  display:grid;grid-template-columns:58px minmax(0,1fr) 54px;gap:9px;
  align-items:center;font-size:12px;
}
.opnationbar-on .opnationbar-name{color:var(--op-accent);font-weight:700;}
.opnationbar-name{
  display:inline-flex;align-items:center;gap:5px;color:var(--op-text);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.opnationbar-wide{grid-column:1;}
.opnationbar b{text-align:right;font-variant-numeric:tabular-nums;}
/* A track holding several fills side by side rather than one. */
.opnationbar .opbar-track{display:flex;}
.opnationbar .opbar-fill{border-radius:0;}
.opnationbar .opbar-fill:first-child{border-radius:3px 0 0 3px;}
.opnationbar .opbar-fill:last-child{border-radius:0 3px 3px 0;}
.oplegend-row{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:10px;}
.oplegend-row li{padding:0;}
/* The distribution. Columns, because the shape is the point. */
.opspread{display:flex;align-items:flex-end;gap:4px;height:130px;}
.opspread-col{
  flex:1;display:flex;flex-direction:column;justify-content:flex-end;
  align-items:center;height:100%;gap:3px;
}
.opspread-bar{
  display:block;width:100%;background:var(--op-accent);border-radius:3px 3px 0 0;
  min-height:2px;
}
.opspread-col.fhovered .opspread-bar{background:var(--op-moderate);}
.opspread-tick{font-size:12px;color:var(--op-muted);}

.opvisually-hidden{
  position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;
  clip:rect(0 0 0 0);white-space:nowrap;border:0;
}

/* Below the rail's own breakpoint the record stacks under the list, and the
   handle goes: there is no width to share. Moved from 1400px on 29 September
   2026, so a 1400px screen keeps the record beside the list. */
@media (max-width:1180px){
  .opsplit-open{grid-template-columns:minmax(0,1fr);}
  .opsplit-handle{display:none;}
}

/* A map layer that has been switched off.
   
   The class is on the view, which is outside the fragment the picture replaces
   every eight seconds, so unticking a box survives a refresh. It used to be the
   `checked` attribute the template writes plus a `hidden` flag on each drawn
   layer, both inside that fragment, so the box ticked itself again on the next
   refresh. There is nothing to restore now because nothing is thrown away. */
.opview.oplayer-off-incidents [data-oplayer-target="incidents"],
.opview.oplayer-off-facilities [data-oplayer-target="facilities"],
.opview.oplayer-off-routes [data-oplayer-target="routes"],
.opview.oplayer-off-assets [data-oplayer-target="assets"],
.opview.oplayer-off-areas [data-oplayer-target="areas"],
.opview.oplayer-off-labels [data-oplayer-target="labels"],
.opview.oplayer-off-towns [data-oplayer-target="towns"],
.opview.oplayer-off-grid [data-oplayer-target="grid"],
.opview.oplayer-off-air [data-oplayer-target="air"],
.opview.oplayer-off-focus [data-oplayer-target="focus"],
.opview.oplayer-off-borders [data-oplayer-target="borders"],
.opview.oplayer-off-detail [data-geomap-detail]{display:none;}
/* Our country borders off: the region shading goes with the lines, and the
   regions stay where a press finds them. The base map is untouched. */
.opview.oplayer-off-borders [data-geomap-shapes] .geomap-shape path{fill-opacity:0 !important;stroke-opacity:0 !important;}

/* Pressing and holding a key row shows only that kind of item
   (static/js/map-solo.js). Everything else a key row names, and the arrival
   rings and the focused area, fade to a tenth and take no pointer; the base
   map, the lines and the names stay as the cog has them, so the items keep
   their context.

   One rule per kind, naming everything but that kind, so the held kind's own
   opacity is never set and never has to be put back: the shading draws its
   counted regions at half the zoom's shade, and a rule restoring "full" would
   have drawn them twice as dark while held. Only inside the map's drawing, so
   the same symbols in the key and the layers list are never faded.

   The held kind shows even where the cog has it off, for the length of the
   hold only: these classes are the hold's and are removed on release, and the
   cog's classes are never touched. Later than the rule that hides a layer and
   more specific than it, so it wins on both counts. */
.opview.opsolo-clusters [data-geomap-shapes] :is(.geomap-shape,.gm-facilities,.gm-routes,.gm-assets,.gm-air,.gm-areas,.gm-pulses,.gm-asked),
.opview.opsolo-shading [data-geomap-shapes] :is(.gm-incidents,.gm-facilities,.gm-routes,.gm-assets,.gm-air,.gm-areas,.gm-pulses,.gm-asked),
.opview.opsolo-facilities [data-geomap-shapes] :is(.gm-incidents,.geomap-shape,.gm-routes,.gm-assets,.gm-air,.gm-areas,.gm-pulses,.gm-asked),
.opview.opsolo-air [data-geomap-shapes] :is(.gm-incidents,.geomap-shape,.gm-facilities,.gm-routes,.gm-assets,.gm-areas,.gm-pulses,.gm-asked),
.opview.opsolo-evacuations [data-geomap-shapes] :is(.gm-incidents,.geomap-shape,.gm-facilities,.gm-air,.gm-areas,.gm-pulses,.gm-asked),
.opview.opsolo-areas [data-geomap-shapes] :is(.gm-incidents,.geomap-shape,.gm-facilities,.gm-routes,.gm-assets,.gm-air,.gm-pulses,.gm-asked){opacity:.1;pointer-events:none;transition:opacity .12s ease;}
.opview.opsolo-clusters.oplayer-off-incidents [data-geomap-shapes] .gm-incidents,
.opview.opsolo-shading.oplayer-off-incidents [data-geomap-shapes] .geomap-shape,
.opview.opsolo-facilities.oplayer-off-facilities [data-geomap-shapes] .gm-facilities,
.opview.opsolo-air.oplayer-off-air [data-geomap-shapes] .gm-air,
.opview.opsolo-evacuations.oplayer-off-routes [data-geomap-shapes] .gm-routes,
.opview.opsolo-evacuations.oplayer-off-assets [data-geomap-shapes] .gm-assets,
.opview.opsolo-areas.oplayer-off-areas [data-geomap-shapes] .gm-areas{display:inline;}
@media (prefers-reduced-motion:reduce){
  .opview.opsolo [data-geomap-shapes] :is(.gm-incidents,.geomap-shape,.gm-facilities,.gm-routes,.gm-assets,.gm-air,.gm-areas,.gm-pulses,.gm-asked){transition:none;}
}
/* What the hold is showing, over the top of the map between the zoom buttons
   and the cog. Solid, so its contrast does not depend on the map under it.
   Empty, and drawn as nothing, while nothing is held; never display:none, so
   the live region stays in place for a screen reader. */
.gmsolo-say{
  position:absolute;top:10px;left:50%;transform:translateX(-50%);z-index:3;
  margin:0;max-width:calc(100% - 140px);pointer-events:none;
  background:var(--op-panel);color:var(--op-text);border:1px solid var(--op-accent);
  border-radius:7px;padding:5px 10px;font-size:13px;line-height:1.35;text-align:center;
}
.gmsolo-say:empty{padding:0;border:0;}

/* Air assets. One symbol for each kind, defined once in the map's own defs
   and drawn with `use` both on the map and in the layers panel, so the two are
   the same drawing. Light at base, the accent while flying, with a dark edge
   so a symbol reads over the relief and the shading alike. */
.gm-air use{
  color:var(--gm-label);stroke:var(--gm-label-ink);stroke-width:1.1px;
  paint-order:stroke fill;stroke-linejoin:round;
}
.gm-air-outbound use,.gm-air-inbound use{color:var(--op-accent);}
.gm-air g[data-tip]{cursor:help;}

/* The rail collapses to a narrow strip so the content can take the width.
   
   The class sits on the document element rather than on anything inside the
   page, so the state is applied by a script in the head before the first paint.
   Put on a wrapper inside <body> it would have to be applied after the rail had
   already been laid out, and the rail would flash open on every navigation.
   
   The width transitions. The rail's own contents are switched rather than
   faded, because a label crossfading to a letter reads as a glitch. */
.body{transition:grid-template-columns .18s ease;}
.railtoggle{
  display:flex;align-items:center;gap:8px;width:100%;background:none;border:0;
  color:var(--muted);font-size:12px;letter-spacing:.1em;text-transform:uppercase;
  padding:2px 18px 12px;cursor:pointer;font-family:var(--label);
}
.railtoggle:hover{color:var(--text);}
.railtoggle:focus-visible{outline:2px solid var(--brand-teal);outline-offset:-2px;}
/* A chevron, pointing the way the click goes. */
.railtoggle-arrow{
  width:7px;height:7px;flex:none;border-left:1.5px solid currentColor;
  border-bottom:1.5px solid currentColor;transform:rotate(45deg);
  transition:transform .18s ease;
}
.app-railshut .railtoggle-arrow{transform:rotate(-135deg);}
.app-railshut .body{grid-template-columns:44px 1fr;}
.app-railshut .rail-h,.app-railshut .scope,.app-railshut .previewnote,
.app-railshut .rail-version,.app-railshut .railtoggle-word{display:none;}
.app-railshut .rail hr{margin:8px 10px;}
.app-railshut .railtoggle{justify-content:center;padding:2px 0 12px;}
/* The letter stands in for the label. Every item stays present and clickable:
   a menu that empties when it is collapsed is a menu somebody has to remember
   the shape of. The title carries the full label for a pointer, and the link
   text is still read in full by a screen reader because it is the font size
   that is zero rather than the text that is gone. */
.app-railshut .rail a{padding:10px 0;text-align:center;font-size:0;}
.app-railshut .rail a::first-letter{font-size:14px;}
@media (prefers-reduced-motion: reduce){
  .body,.railtoggle-arrow{transition:none;}
}
/* Below 1040 the rail is already a band above the content rather than a left
   column, so there is no width to reclaim and nothing to collapse. The rule
   that lays it out that way is at line 569; this follows it rather than
   choosing a number of its own. */
@media (max-width:1040px){
  .railtoggle{display:none;}
  .app-railshut .body{grid-template-columns:1fr;}
  .app-railshut .rail-h,.app-railshut .scope,.app-railshut .previewnote,
  .app-railshut .rail-version{display:revert;}
  .app-railshut .rail a{padding:10px 18px;text-align:left;font-size:14px;}
}

/* The rail collapse control. The class lives on .opview, which is outside the
   fragment that refreshes, so the collapsed state survives a refresh without
   anything having to restore it. Collapsed narrows the rail rather than
   removing it: every control stays reachable, with its label carried by the
   tip instead of the text. */
.oprailtoggle{
  margin-left:auto;align-self:center;display:inline-flex;align-items:center;gap:7px;
  background:transparent;border:1px solid var(--op-line);border-radius:6px;
  color:var(--op-muted);font:inherit;font-size:12px;padding:4px 10px;cursor:pointer;
}
.oprailtoggle:hover{color:var(--op-text);border-color:var(--op-accent);}

/* The question mark right of Admin. Filled in the accent, bold, round, and the
   height of the tab labels' line with their own vertical padding, centred on
   them. A clear ring on keyboard focus, and on keyboard focus only: after a
   mouse click on the dialog it opens, focus comes back with
   `data-quiet-focus` (picture-since.js) and no ring.
   The margin is the ring's reach, its offset and width, on the three sides
   it does not already have room: the button is the last thing in the tab
   strip, which scrolls sideways and so clips what is drawn outside it, and
   the ring was cut off on the right and read as an off centre circle through
   the button (27 October 2026). */
.ophelp{
  align-self:center;flex:none;width:26px;height:26px;margin:4px 4px 4px 8px;padding:0;
  border:0;border-radius:50%;background:var(--op-accent);color:#08171A;
  font:inherit;font-size:15px;font-weight:800;line-height:26px;text-align:center;cursor:pointer;
}
.ophelp:hover{filter:brightness(1.1);}
.ophelp:focus-visible{outline:2px solid var(--op-text);outline-offset:2px;}
.ophelp[data-quiet-focus]{outline:none;}

/* The "since your last visit" dialog. It never grows past the window: the
   header with its close button and the footer with its labelling stay put and
   the middle scrolls. No padding on the dialog itself, so a click that lands
   on it and not on its contents is a click on the backdrop. */
.opsince{
  padding:0;border:1px solid var(--op-line);border-radius:12px;
  background:var(--op-panel);color:var(--op-text);
  width:min(560px, calc(100vw - 32px));max-height:calc(100vh - 48px);overflow:hidden;
}
.opsince::backdrop{background:rgba(4,10,12,.62);}
.opsince-box{display:flex;flex-direction:column;max-height:calc(100vh - 48px);}
.opsince-head{display:flex;align-items:center;justify-content:space-between;gap:12px;
              padding:14px 18px 12px;border-bottom:1px solid var(--op-line);flex:none;}
.opsince-head h2{margin:0;font-size:12px;letter-spacing:.12em;text-transform:uppercase;
                 color:var(--op-muted);font-weight:700;}
.opsince-close{display:inline-flex;align-items:center;gap:6px;background:var(--op-row);
               border:1px solid var(--op-line);border-radius:6px;color:var(--op-text);
               font:inherit;font-size:12px;padding:4px 10px;cursor:pointer;}
.opsince-close:hover{border-color:var(--op-accent);}
.opsince-close:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opsince-body{flex:1 1 auto;min-height:0;overflow:auto;padding:14px 18px;}
.opsince-lede{margin:0;font-size:13px;line-height:1.5;}
.opsince-block{margin:0 0 16px;}
.opsince-block:last-child{margin-bottom:0;}
.opsince-block h3{margin:0 0 8px;font-size:12px;letter-spacing:.12em;text-transform:uppercase;
                  color:var(--op-muted);font-weight:700;}
.opsince-headline p{margin:4px 0 0;font-size:12px;color:var(--op-muted);}
.opsince-list{list-style:none;margin:0;padding:0;}
.opsince-list li{display:flex;align-items:center;justify-content:space-between;gap:10px;
                 padding:4px 0;font-size:12.5px;border-bottom:1px solid var(--op-line);}
.opsince-list li:last-child{border-bottom:0;}
.opsince-list b{font-variant-numeric:tabular-nums;}
.opsince-rest,.opsince-change{margin:6px 0 0;font-size:12px;color:var(--op-muted);line-height:1.45;}
.opsince-change{color:var(--op-text);margin:0;}
.opsince-foot{flex:none;padding:10px 18px 14px;border-top:1px solid var(--op-line);}
.opsince-quiet{display:flex;align-items:center;gap:8px;font-size:12px;color:var(--op-text);}
.opsince-note{margin:8px 0 0;font-size:12px;color:var(--op-muted);line-height:1.45;}
.oprailicon{width:11px;height:11px;border:1.5px solid currentColor;border-radius:2px;
            border-left-width:4px;}
.opview.oprail-shut .oprailicon{border-left-width:1.5px;border-right-width:4px;}

.opview.oprail-shut .opgrid{grid-template-columns:58px minmax(0,1fr) 380px;}
.opview.oprail-shut .oprail .oppanel{padding:10px 6px;}
.opview.oprail-shut .oprail h2{display:none;}
.opview.oprail-shut .oprail .opchips{gap:5px;}
.opview.oprail-shut .oprail .opchip{
  justify-content:center;padding:4px 0;width:100%;gap:0;
}
.opview.oprail-shut .oprail .opchip > span:not(.opflag){display:none;}
.opview.oprail-shut .oprail .opflag{font-size:12px;}
.opview.oprail-shut .oprail .opwindows{flex-direction:column;}
/* Hide panel hides the notes on what a filter does here too, from the eye and
   from a screen reader alike, off the one class the panel itself reads, so
   the two cannot disagree and the choice is remembered with the panel's. */
.opview.oprail-shut .oprail .opfilternote{display:none;}

@media (max-width: 1500px){
  .opgrid{grid-template-columns:230px minmax(0,1fr) 330px;}
  .opview.oprail-shut .opgrid{grid-template-columns:58px minmax(0,1fr) 330px;}
  /* The sections have two columns, the rail and themselves. Without these
     the rule above, coming later, outranked `.opgrid-tab` and every section
     from 1181 to 1500 wide had an empty 330px third column (found 4 November
     2026, making the evacuation panel designs). */
  .opgrid.opgrid-tab{grid-template-columns:230px minmax(0,1fr);}
  .opview.oprail-shut .opgrid.opgrid-tab{grid-template-columns:58px minmax(0,1fr);}
}
@media (max-width: 1180px){
  .opgrid,.opview.oprail-shut .opgrid{grid-template-columns:minmax(0,1fr);}
  /* As strong as the sections' two columns above 1180, so one column here
     too (the two column rule of 2026.1.18.41 outranked this one). */
  .opgrid.opgrid-tab,.opview.oprail-shut .opgrid.opgrid-tab{grid-template-columns:minmax(0,1fr);}
  /* One column, so there is no width to reclaim and nothing to collapse. */
  .oprailtoggle{display:none;}
  .opview.oprail-shut .oprail h2,
  .opview.oprail-shut .oprail .opchip > span:not(.opflag){display:revert;}
  .opview.oprail-shut .oprail .opchip{width:auto;padding:4px 9px;gap:6px;}
  .opview.oprail-shut .oprail .opwindows{flex-direction:row;}
  .opview.oprail-shut .oprail .opfilternote{display:revert;}
  .opbottom{grid-template-columns:repeat(auto-fit,minmax(260px,1fr));}
}

/* The Add a catalogue dialogue.
   
   Every control in it is a drawing of a control. They are filled in and styled
   normally rather than disabled, because a row of greyed out inputs reads as a
   screen that is broken rather than one that is not connected yet, and the
   notice at the top is the thing that has to be believed. What makes them inert
   is structural: there is no form element in the dialogue at all, so nothing
   can submit even with the script gone, the buttons are type="button", and
   every group carries a Mockup chip. Pressing one says so.
   
   The text inputs are `readonly` rather than `disabled`: readonly keeps normal
   ink and stays focusable and selectable, so a reader can copy the endpoint,
   and it cannot be typed into or submitted. */
.addcat-tabs{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:0 0 18px;}
.addcat-tab{
  display:flex;align-items:center;justify-content:center;gap:8px;
  padding:11px 14px;border:1px solid var(--hairline);border-radius:9px;
  background:var(--surface-2);color:var(--muted);text-decoration:none;
  font-family:var(--label);letter-spacing:.12em;text-transform:uppercase;
  font-size:12px;font-weight:600;
}
.addcat-tab:hover{color:var(--text);border-color:var(--brand-teal);}
.addcat-tab.on{
  background:var(--teal-wash);border-color:var(--brand-teal);
  color:var(--brand-teal-lift);box-shadow:inset 0 0 0 1px var(--brand-teal);
}
.addcat-tab:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}

/* The sixty columns, in their own scroller, so the sequence is checkable
   without the dialogue running past the bottom of the screen. */
.addcat-columns{max-height:260px;overflow:hidden auto;overscroll-behavior-y:contain;}
.addcat-columns table{width:100%;}
.addcat-columns thead th{position:sticky;top:0;background:var(--surface);z-index:1;}
.addcat-pos{font-family:var(--mono);color:var(--muted);width:70px;}
.addcat-columns:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}

.addcat-controls{
  margin-top:22px;padding:16px;border:1px solid var(--hairline);
  border-radius:10px;background:var(--surface-2);
}
.addcat-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px;}
.addcat-field{display:flex;flex-direction:column;min-width:0;}
.addcat-field > label{
  font-size:12px;letter-spacing:.06em;text-transform:uppercase;
  color:var(--muted);margin-bottom:5px;font-family:var(--label);
}
.addcat-field .input,.addcat-field .sel{height:38px;box-sizing:border-box;width:100%;}
.addcat-mono{font-family:var(--mono);font-size:12px;}
.addcat-file{display:flex;gap:8px;align-items:center;min-width:0;}
/* Not a button. It looks like the control a real file input would carry, and it
   is a span so there is nothing to press and nothing to fail. */
.addcat-fake{flex:none;pointer-events:none;opacity:.75;}
.addcat-file .input{flex:1;min-width:0;}
.addcat-suffix{display:flex;align-items:center;gap:8px;}
.addcat-suffix span{font-size:12px;color:var(--muted);white-space:nowrap;}
.addcat-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px;}
/* A value the platform shows rather than asks for. Greyed, so it reads as an
   example of what would be issued rather than as something to fill in, and
   still selectable so it can be copied. */
.addcat-shown{color:var(--muted);background:var(--surface-2);}

/* The nation picker. */
.addcat-picker{position:relative;}
.addcat-hidden-label{
  position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);
  white-space:nowrap;
}
.addcat-picker > .input{width:100%;height:38px;box-sizing:border-box;}
.addcat-options{
  list-style:none;margin:4px 0 0;padding:4px;position:absolute;z-index:5;
  left:0;right:0;background:var(--surface);border:1px solid var(--hairline);
  border-radius:9px;box-shadow:0 12px 28px rgba(16,34,42,.14);
  max-height:220px;overflow:auto;
}
.addcat-options[hidden]{display:none;}
.addcat-option{
  display:block;width:100%;text-align:left;padding:7px 9px;border:0;
  border-radius:6px;background:none;cursor:pointer;font:inherit;font-size:13px;
  color:var(--text);
}
.addcat-option b{font-family:var(--mono);color:var(--muted);margin-right:7px;}
.addcat-option:hover,.addcat-option:focus-visible{background:var(--teal-wash);}
.addcat-check{
  display:flex;align-items:center;gap:8px;margin:10px 0 0;font-size:12.5px;
  color:var(--text);cursor:pointer;
}
.addcat-chosen{
  list-style:none;margin:10px 0 0;padding:0;display:flex;flex-wrap:wrap;gap:6px;
}
.addcat-chip{
  display:inline-flex;align-items:center;gap:7px;padding:3px 4px 3px 9px;
  border:1px solid var(--hairline);border-radius:999px;background:var(--surface);
  font-size:12px;
}
.addcat-chip b{font-family:var(--mono);color:var(--muted);margin-right:3px;}
.addcat-chip-x{
  width:19px;height:19px;border:0;border-radius:50%;background:var(--surface-2);
  color:var(--muted);cursor:pointer;font-size:13px;line-height:1;
  display:flex;align-items:center;justify-content:center;font-family:inherit;
}
.addcat-chip-x:hover{background:var(--control-wash);color:#604400;}
.addcat-chip-x:focus-visible{outline:2px solid var(--brand-teal);outline-offset:1px;}
.addcat-empty{margin:10px 0 0;}
.addcat-empty[hidden]{display:none;}
.addcat-said{
  margin:16px 0 0;padding:10px 13px;border-radius:9px;
  border:1px solid var(--control);background:var(--control-wash);
  color:#4A3600;font-size:12.5px;line-height:1.5;
}
.addcat-said[hidden]{display:none;}
@media (max-width:620px){
  .addcat-tabs{grid-template-columns:1fr;}
  .addcat-actions .btn{width:100%;}
}

/* --- the Ai panel on the Operational View --------------------------------
   The button sits beside the view switch at the switch's own height, 29px,
   so the two share one line. Its
   corners are an app icon's rather than the switch's: the switch is already a
   full pill, so nothing can be rounder than it, and the brief's reference for
   the letterform was an icon. The panel is fixed over the right hand column,
   under the bar, and never over the map it moves; where it sits was measured
   at 1920 and at 1512 by 860 (DASHBOARD.md). */
.opask-toggle{
  height:29px;min-width:38px;padding:0 10px;box-sizing:border-box;flex:none;
  border:0;border-radius:9px;background:var(--op-accent);color:#08171A;
  font:inherit;font-size:14px;font-weight:700;letter-spacing:.01em;line-height:1;
  display:inline-flex;align-items:center;justify-content:center;cursor:pointer;
}
.opask-toggle:hover{filter:brightness(1.08);}
.opask-toggle:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opask-toggle[aria-expanded="true"]{box-shadow:0 0 0 2px var(--op-bg),0 0 0 4px var(--op-accent);}
.opask-toggle.is-busy{animation:opask-breathe 1.2s ease-in-out infinite;}
/* While an answer card is open (BIO-180) it brings the card forward rather
   than opening the panel (2 November), so it looks as it always does. Back
   from a closed card, it pulses once. */
.opask-toggle.is-back{animation:opask-return .7s ease-out 1;}
@keyframes opask-return{
  0%{box-shadow:0 0 0 0 color-mix(in srgb, var(--op-accent) 70%, transparent);}
  100%{box-shadow:0 0 0 12px color-mix(in srgb, var(--op-accent) 0%, transparent);}
}
/* The assistant's status as a dot on the Ai button (static/js/assistant-ping.js):
   ready, waking, offline. Colour and a pulse while waking, and the button's
   own label says the rest to a screen reader through its tip. */
.opask-toggle{position:relative;}
.opask-toggle[data-assistant-status]::after{
  content:"";position:absolute;top:-3px;right:-3px;width:9px;height:9px;border-radius:50%;
  box-shadow:0 0 0 2px var(--op-bg);
}
.opask-toggle[data-assistant-status="ready"]::after{background:#3FB950;}
.opask-toggle[data-assistant-status="waking"]::after{background:#D29922;animation:opask-breathe 1.2s ease-in-out infinite;}
.opask-toggle[data-assistant-status="offline"]::after{background:#8B949E;}
.opask{
  position:fixed;right:16px;top:70px;z-index:60;
  width:360px;max-width:calc(100vw - 32px);max-height:calc(100vh - 86px);overflow:auto;
  box-sizing:border-box;padding:14px 16px 16px;
  background:var(--op-panel);color:var(--op-text);
  border:1px solid var(--op-line);border-radius:10px;
  box-shadow:0 18px 40px rgba(0,0,0,.45);
  display:flex;flex-direction:column;gap:10px;
}
.opask[hidden]{display:none;}
.opask-head{display:flex;align-items:center;justify-content:space-between;gap:10px;}
.opask-head h2{margin:0;font-size:14px;font-weight:600;letter-spacing:.02em;color:var(--op-text);}
.opask-close{border:0;background:transparent;color:var(--op-muted);font-size:20px;line-height:1;
  padding:2px 6px;border-radius:6px;cursor:pointer;}
.opask-close:hover{color:var(--op-text);background:var(--op-row);}
.opask-close:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opask-status{margin:0;font-size:12px;font-weight:600;color:var(--op-muted);}
/* Offline: Ask and the listed questions are disabled, and look it, which the
   busy state's softer disabled look did not say. */
.opask[data-offline] .opask-go:disabled,
.opask[data-offline] .opask-example:disabled{opacity:.4;cursor:not-allowed;filter:saturate(.4);}
/* A list with nothing in it yet is hidden, whatever display its block takes. */
.opask-examples[hidden]{display:none;}
/* An assistant answer on the map (static/js/picture-ask.js): what it names is
   picked out and everything else is dimmed, until Clear. */
.gm-answering [data-shape]:not(.gm-hit),
.gm-answering [data-gm-places]:not(.gm-hit),
.gm-answering [data-facility]:not(.gm-hit){opacity:.22;transition:opacity .2s;}
.gm-answering .gm-hit path,.gm-answering .gm-hit .gm-cluster,.gm-answering .gm-hit rect{stroke:var(--op-accent);stroke-width:2.5px;}
/* The answer over the left of the map (static/js/picture-ask.js). */
/* The card's border, and the badge on its corner, are the header Ai button's
   colour, var(--op-accent), so the card reads as the button's answer (BIO-174).
   The card does not scroll; its body does, so the badge can sit half outside. */
.opanswer{position:fixed;z-index:55;width:300px;max-width:calc(100vw - 48px);overflow:visible;box-sizing:border-box;
  padding:0;background:var(--op-panel);color:var(--op-text);border:1.5px solid var(--op-line);
  border-radius:10px;box-shadow:0 8px 24px rgba(0,0,0,.35);display:flex;flex-direction:column;
  transition:opacity .2s ease, transform .2s ease, border-color .3s ease;transform-origin:0 0;}
.opanswer[hidden]{display:none;}
.opanswer.is-opening{opacity:0;transform:scale(.96);}
.opanswer-body{display:flex;flex-direction:column;gap:8px;padding:14px 14px 12px;overflow:auto;max-height:inherit;
  box-sizing:border-box;min-height:0;}
.opanswer-content{display:flex;flex-direction:column;gap:8px;transition:opacity .2s ease;}
.opanswer-content.is-arriving{opacity:0;}
/* Three tabs on the card's top border, each centred on the line, one height,
   one radius, one size of text (the tab aware brief's follow up): the Ai tab
   on the left corner, New question beside it, thumbs and close on the right
   corner. Filled with the card's own colour so the border does not show
   through them, and edged in the Ai colour, lightly, so they read as part of
   the card; New question's edge is the full colour. */
.opanswer-tab{position:absolute;top:0;z-index:2;height:24px;box-sizing:border-box;border-radius:8px;
  font-size:12px;line-height:1;display:inline-flex;align-items:center;margin:0;
  background:var(--op-panel);border:1px solid color-mix(in srgb, var(--op-accent) 45%, transparent);}
.opanswer-badge{left:0;transform:translate(-50%,-50%);min-width:32px;padding:0 8px;justify-content:center;
  background:var(--op-accent);color:#08171A;font-weight:700;letter-spacing:.01em;font-family:inherit;
  box-shadow:0 0 0 2px var(--op-bg);cursor:grab;touch-action:none;}
.opanswer-badge:focus-visible{outline:2px solid var(--op-text);outline-offset:2px;}
.opanswer-tab.opanswer-newq{left:22px;transform:translateY(-50%);padding:0 9px;border-color:var(--op-accent);}
.opanswer-acts{right:0;transform:translate(50%,-50%);gap:4px;padding:0 4px;}
.opanswer-acts .opanswer-thumbs{display:inline-flex;}
.opanswer-acts .aifeedback{position:static;display:inline-flex;flex-wrap:nowrap;gap:4px;max-width:none;}
.opanswer-acts .aifeedback-btn{width:20px;height:20px;border-radius:5px;}
.opanswer-acts .aifeedback-btn svg{width:12px;height:12px;}
/* The card's button style comes after and would make the tab see through. */
.opanswer .opanswer-tab.opanswer-newq{background:var(--op-panel);font-size:12px;border-radius:8px;height:24px;}
/* The reasons, inside the card in its own colours. */
.opanswer-body .aifeedback-why{width:auto;margin:0;background:var(--op-row);color:var(--op-text);border-color:var(--op-line);}
.opanswer-body .aifeedback-why legend,.opanswer-body .aifeedback-why label{color:var(--op-text);}
.opanswer-body .aifeedback-why textarea{background:var(--op-bg);color:var(--op-text);border:1px solid var(--op-line);}
.opanswer-body .aifeedback-why .aifeedback-note{color:var(--op-muted);}
.opanswer-body .aifeedback-why .btn{color:var(--op-text);border-color:var(--op-line);background:transparent;}
/* New question and Dock side by side on the top border (the dock brief,
   2 November), one group so Dock follows New question whatever its width.
   Dock shows one icon: into the corner while free, out of it while docked. */
.opanswer-tabgroup{position:absolute;top:0;left:22px;z-index:2;transform:translateY(-50%);display:flex;gap:6px;align-items:center;}
.opanswer-tabgroup > .opanswer-tab,.opanswer-tabgroup > .opanswer-tab.opanswer-newq{position:static;left:auto;transform:none;}
.opanswer .opanswer-tab.opanswer-dock{gap:5px;padding:0 9px 0 6px;color:var(--op-text);font-family:inherit;font-size:12px;
  cursor:pointer;white-space:nowrap;}
.opanswer .opanswer-tab.opanswer-dock:hover,.opanswer .opanswer-tab.opanswer-dock:focus-visible{color:var(--op-accent);border-color:var(--op-accent);}
.opanswer-dock:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opanswer-dock svg{flex:none;display:block;}
.opanswer-dock .opanswer-dock-out,.opanswer-dock.is-docked .opanswer-dock-in{display:none;}
.opanswer-dock.is-docked .opanswer-dock-out{display:block;}
/* Free, it is resized from its bottom right corner, and once sized its body
   takes the height and scrolls. Docked, it does not move, and the open
   section keeps a margin as wide as it, so it covers none of the section. */
.opanswer.is-sized .opanswer-body{flex:1 1 auto;max-height:none;}
.opanswer-resize{position:absolute;right:3px;bottom:3px;width:14px;height:14px;cursor:nwse-resize;touch-action:none;
  border-right:2px solid var(--op-muted);border-bottom:2px solid var(--op-muted);border-bottom-right-radius:3px;}
.opanswer.is-docked .opanswer-resize{display:none;}
.opanswer.is-docked .opanswer-badge,.opanswer.is-docked .opanswer-body > .opanswer-question{cursor:default;}
body.opai-docked #optab{margin-right:var(--opdock-room,0px);}
/* Moved by its header: the Ai tab and the question line. */
.opanswer .opanswer-body > .opanswer-question{cursor:grab;user-select:none;}
.opanswer.is-dragging{box-shadow:0 18px 40px rgba(0,0,0,.5);transition:none;}
.opanswer.is-dragging,.opanswer.is-dragging .opanswer-badge,.opanswer.is-dragging .opanswer-question{cursor:grabbing;}
.opanswer.is-returning{transition:left .28s ease, top .28s ease, opacity .2s ease, border-color .3s ease;}
@media (prefers-reduced-motion: reduce){.opanswer.is-returning{transition:none;}}
.opanswer-travel{position:fixed;left:0;top:0;z-index:70;transform-origin:50% 50%;}
.opanswer-close{width:20px;height:20px;padding:0;display:inline-flex;align-items:center;justify-content:center;
  border:0;border-radius:5px;background:transparent;color:var(--op-muted);font-size:16px;line-height:1;cursor:pointer;}
.opanswer-close:hover{color:var(--op-text);background:var(--op-row);}
.opanswer-close:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opanswer .opanswer-body{padding-top:18px;}
/* Loading: the border pulses gently, and grey lines stand where the answer
   will be. No words: the question above them says what is coming. */
.opanswer.is-loading.ai-focus{animation:opanswer-pulse 1.2s ease-in-out infinite;}
@keyframes opanswer-pulse{
  0%,100%{box-shadow:0 0 0 0 color-mix(in srgb, var(--op-accent) 0%, transparent),0 8px 24px rgba(0,0,0,.35);}
  50%{box-shadow:0 0 0 5px color-mix(in srgb, var(--op-accent) 45%, transparent),0 8px 24px rgba(0,0,0,.35);}
}
/* The Ai button pressed with a card open (2 November): the page dims behind
   the card, which comes to the front with its green border (.ai-focus) and
   pulses once. The veil is the card's sibling and sits behind it, so it
   never covers the card. */
.opveil{position:fixed;inset:0;z-index:64;background:rgba(3,8,10,.62);}
.opveil[hidden]{display:none;}
.opanswer.is-summoned{z-index:65;}
.opanswer.is-pulsing{animation:opanswer-summon .9s ease-out 1;}
@keyframes opanswer-summon{
  0%{box-shadow:0 0 0 0 color-mix(in srgb, var(--op-accent) 70%, transparent),0 8px 24px rgba(0,0,0,.35);}
  100%{box-shadow:0 0 0 16px color-mix(in srgb, var(--op-accent) 0%, transparent),0 8px 24px rgba(0,0,0,.35);}
}
.opanswer-skeleton{display:flex;flex-direction:column;gap:9px;padding:2px 0 4px;transition:opacity .2s ease;}
.opanswer-skeleton.is-leaving{opacity:0;position:absolute;visibility:hidden;}
.opanswer-skeleton i{display:block;height:11px;border-radius:4px;
  background:linear-gradient(90deg, var(--op-row) 0%, color-mix(in srgb, var(--op-row) 55%, var(--op-text) 12%) 50%, var(--op-row) 100%);
  background-size:300% 100%;animation:opanswer-shimmer 1.6s linear infinite;}
.opanswer-skeleton i:nth-child(1){width:94%;}
.opanswer-skeleton i:nth-child(2){width:82%;}
.opanswer-skeleton i:nth-child(3){width:58%;}
.opanswer-skeleton i.is-figure{height:28px;width:100%;margin-top:4px;}
@keyframes opanswer-shimmer{from{background-position:100% 0;}to{background-position:-200% 0;}}
@media (prefers-reduced-motion: reduce){
  .opanswer{transition:opacity .2s ease;}
  .opanswer.is-opening{transform:none;}
  .opanswer.is-loading.ai-focus,.opanswer-skeleton i,.opask-toggle.is-back{animation:none;}
  .opanswer.is-pulsing{animation:none;}
}
.opanswer-question{margin:0;font-size:12px;color:var(--op-muted);}
.opanswer-text{margin:0;font-size:14px;line-height:1.4;}
.opanswer-period{margin:0;font-size:12px;color:var(--op-muted);}
.opanswer .opask-figures{margin:0;}
.opanswer-actions{display:flex;gap:8px;flex-wrap:wrap;}
.opanswer-btn{font:inherit;font-size:13px;padding:4px 12px;border-radius:6px;cursor:pointer;text-decoration:none;
  border:1px solid var(--op-line, rgba(255,255,255,.25));background:transparent;color:var(--op-text);}
.opanswer-btn:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opreport-answer{display:flex;flex-direction:column;gap:8px;}
/* Focus mode (static/js/picture-ask.js): an answer that names areas or
   facilities hides the map's other dots, routes and aircraft, and its own
   numbered marks stand in for them. "Show everything" takes it back out. */
.gm-focus [data-oplayer-target="incidents"],
.gm-focus [data-oplayer-target="routes"],
.gm-focus [data-oplayer-target="air"],
.gm-focus [data-oplayer-target="assets"],
.gm-focus [data-oplayer-target="areas"],
.gm-focus [data-oplayer-target="facilities"]{display:none;}
.gm-focus-nation_focus [data-shape]:not(.gm-in-scope){opacity:0;}
.gm-answer-layer{pointer-events:none;}
.gm-answer-mark circle{fill:var(--op-accent);fill-opacity:.85;stroke:var(--op-bg);stroke-width:.4;}
/* A place by relation's regions, drawn by the answer layer (the tab aware brief). */
.gm-answer-area{fill:var(--op-accent);fill-opacity:.18;stroke:var(--op-accent);stroke-opacity:.7;stroke-width:.6;vector-effect:non-scaling-stroke;pointer-events:none;}
.gm-answer-mark text{fill:#08171A;font-weight:700;text-anchor:middle;font-family:inherit;}
.gm-answer-mark .gm-answer-scale circle:not(.gm-answer-num){stroke-width:1.5;}
.gm-answer-mark.gm-answer-at-capacity circle,.gm-answer-mark.gm-answer-pressure circle{fill:var(--op-t1);}
.gm-answer-mark.gm-answer-busy circle{fill:var(--op-t2);}
.gm-answer-mark.gm-answer-normal circle{fill:var(--op-t3);}
.gm-answer-mark text.gm-answer-note{fill:var(--op-text);paint-order:stroke;stroke:var(--op-bg);stroke-width:.3;}
.gm-answer-plus{fill:var(--op-text);font-weight:700;text-anchor:middle;paint-order:stroke;stroke:var(--op-bg);stroke-width:.3;}
.gm-rise path{fill:var(--op-t1);fill-opacity:calc(var(--gm-rise, .5) * .8);}
.opanswer-chart .opchart{margin:0;}
.opanswer-more{margin:0;font-size:13px;}
.opanswer-more a{color:var(--op-accent);font-weight:600;}
.opanswer-more a:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.gm-answer-mark.is-selected circle{stroke:var(--op-text);stroke-width:1.2;fill-opacity:1;}
/* The results tray (static/js/picture-tray.js): a ranked answer's full list
   takes the bottom band, and the four graphs move into a narrow strip on the
   right that scrolls, each at the height it has in the band, so all four are
   still in reach. Closing it puts them back. */
/* Open, the band is at least tall enough for eight rows of the list, taken
   from the map row by picture-band.js, which reads this floor. */
.opbottom.optray-open{grid-template-columns:minmax(520px,2fr) minmax(0,3fr);--op-bottom-min:364px;}
.optray{display:flex;flex-direction:column;min-height:0;margin:0;}
.optray:focus{outline:none;}
.optray .opcardhead{display:flex;align-items:center;gap:12px;}
.optray-close{margin-left:auto;width:28px;height:28px;border-radius:6px;border:1px solid var(--op-line);
  background:transparent;color:var(--op-text);font-size:18px;line-height:1;cursor:pointer;}
.optray-close:focus-visible,.optray-sort:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.optray-scroll{overflow:auto;min-height:0;flex:1;}
.optray-table{width:100%;border-collapse:collapse;font-size:14px;}
.optray-table th{position:sticky;top:0;background:var(--op-panel);text-align:left;font-weight:600;color:var(--op-muted);
  font-size:12px;letter-spacing:.06em;text-transform:uppercase;padding:6px 10px;border-bottom:1px solid var(--op-line);}
.optray-table td{padding:3px 10px;border-bottom:1px solid var(--op-line);color:var(--op-text);}
.optray-table tbody tr{cursor:pointer;}
.optray-table tbody tr:hover td{background:var(--op-row);}
.optray-table tbody tr:focus{outline:none;}
.optray-table tbody tr:focus-visible td{box-shadow:inset 0 0 0 1px var(--op-accent);}
.optray-table tr.is-selected td{background:var(--op-row);}
.optray-table tr.is-selected td:first-child{box-shadow:inset 3px 0 0 var(--op-accent);}
.optray-rank{width:56px;font-variant-numeric:tabular-nums;color:var(--op-muted);}
.optray-table .optray-num{text-align:right;font-variant-numeric:tabular-nums;}
.optray-sort{font:inherit;color:var(--op-accent);background:none;border:0;padding:0;cursor:pointer;
  text-transform:inherit;letter-spacing:inherit;}
.optray-up{color:var(--op-bad);}
.optray-down{color:var(--op-good);}
/* The four graphs, as compact cards at the band's full height, side by side
   where the width allows (four at 2560) and scrolling where it does not, so
   none is squashed to fit. */
.optray-strip{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));
  grid-auto-rows:var(--op-bottom, var(--op-bottom-min));gap:12px;overflow-y:auto;min-height:0;}
.optray-strip > .oppanel{height:100%;display:flex;flex-direction:column;
  min-height:0;margin:0;container-type:size;box-sizing:border-box;}
.optray-strip > .oppanel.optray-related{box-shadow:0 0 0 2px var(--op-accent);}
.optray-matched{outline:2px solid var(--op-accent);outline-offset:2px;border-radius:4px;}
/* Six labels across the card's narrow chart ran together at 300px: each is held to its own sixth, at the 12px floor (BIO-126), and a long one ends in an ellipsis. */
.opanswer-chart .opchart-x span{font-size:12px;max-width:16%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.opask-period{margin:0;font-size:12px;color:var(--op-muted);}
.opask-form{margin:0;}
.opask-label{display:block;margin:0 0 5px;font-size:12px;letter-spacing:.14em;
  text-transform:uppercase;color:var(--op-muted);}
.opask-row{display:flex;gap:8px;align-items:flex-start;}
/* The box grows with the question to four lines, then scrolls (BIO-179);
   the clear and microphone buttons sit inside it on the right. */
.opask-box{position:relative;flex:1;min-width:0;}
.opask-input{display:block;width:100%;min-height:32px;box-sizing:border-box;padding:7px 58px 7px 10px;
  border:1px solid var(--op-line);border-radius:7px;background:var(--op-bg);color:var(--op-text);
  font:inherit;font-size:13px;line-height:18px;resize:none;overflow-y:hidden;}
.opask-input:focus{outline:none;border-color:var(--op-accent);}
.opask-tools{position:absolute;top:4px;right:4px;display:flex;gap:2px;}
.opask-tool{width:24px;height:24px;padding:0;border:0;border-radius:5px;background:transparent;
  color:var(--op-muted);cursor:pointer;display:inline-flex;align-items:center;justify-content:center;
  font:inherit;font-size:16px;line-height:1;}
.opask-tool[hidden]{display:none;}
.opask-tool:hover{color:var(--op-text);background:var(--op-line);}
.opask-tool:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
/* A microphone drawn by a mask in the text colour, so the page holds no
   chart-like svg of its own (tests_opreportview reads svg as a chart). */
.opask-mic-icon{width:14px;height:14px;background:currentColor;
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.4' stroke-linecap='round'%3E%3Crect x='5.5' y='1.5' width='5' height='8.5' rx='2.5'/%3E%3Cpath d='M3 7.5a5 5 0 0 0 10 0M8 12.5v2.5'/%3E%3C/svg%3E") center/contain no-repeat;
  mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.4' stroke-linecap='round'%3E%3Crect x='5.5' y='1.5' width='5' height='8.5' rx='2.5'/%3E%3Cpath d='M3 7.5a5 5 0 0 0 10 0M8 12.5v2.5'/%3E%3C/svg%3E") center/contain no-repeat;}
/* Recording: the icon itself in the T1 red, a fill rather than a text
   colour, and pulsing. */
.opask-mic[aria-pressed="true"] .opask-mic-icon{background:var(--op-t1);
  animation:opask-pulse 1.2s ease-in-out infinite;}
@keyframes opask-pulse{50%{opacity:.35;}}
.opask-heard{margin:6px 0 0;font-size:12px;color:var(--op-muted);}
.opask-go{height:32px;padding:0 14px;border:0;border-radius:7px;background:var(--op-accent);
  color:#08171A;font:inherit;font-size:13px;font-weight:700;cursor:pointer;
  display:inline-flex;align-items:center;gap:7px;}
.opask-go:disabled{cursor:progress;opacity:.85;}
.opask-go:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opask-go.is-busy::before{content:"";width:11px;height:11px;border-radius:50%;box-sizing:border-box;
  border:2px solid currentColor;border-right-color:transparent;animation:opask-spin .8s linear infinite;}
.opask-examples,.opask-offer{display:flex;flex-direction:column;gap:6px;}
.opask-example{text-align:left;padding:7px 10px;border:1px solid var(--op-line);border-radius:7px;
  background:var(--op-row);color:var(--op-text);font:inherit;font-size:12.5px;line-height:1.35;cursor:pointer;}
.opask-example:hover{border-color:var(--op-accent);}
.opask-example:disabled{opacity:.6;cursor:progress;}
.opask-example:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opask-note{margin:2px 0 0;font-size:12px;color:var(--op-muted);}
.opask-answer{border-top:1px solid var(--op-line);padding-top:10px;}
.opask-answer:empty{display:none;}
.opask-reply{display:flex;flex-direction:column;gap:8px;}
.opask-asked{margin:0;font-size:12px;color:var(--op-muted);overflow-wrap:anywhere;}
.opask-asked-label{font-size:12px;letter-spacing:.14em;text-transform:uppercase;margin-right:6px;}
.opask-sentence{margin:0;font-size:13.5px;line-height:1.5;color:var(--op-text);}
.opask-figures{margin:0;display:grid;gap:0;font-size:12px;}
.opask-figure{display:flex;justify-content:space-between;gap:12px;padding:4px 0;
  border-bottom:1px solid var(--op-line);}
.opask-figure dt{color:var(--op-muted);}
.opask-figure dd{margin:0;font-variant-numeric:tabular-nums;font-weight:600;text-align:right;}
.opask-mapnote{margin:0;font-size:12px;color:var(--op-muted);}
/* The catching up screen (feeds/picture_catching_up.html): the picture's own
   ground, and one plain statement of what is happening. The picture's colour
   tokens live on .opview, which this page does not have, so each colour carries
   its value as a fallback. */
body:has(.opcatchup){background:#0B1418;}
body:has(.opcatchup) .stage{max-width:none;margin:0;padding:0;}
body:has(.opcatchup) footer{display:none;}
.opcatchup{
  min-height:100vh;box-sizing:border-box;padding:24px;
  display:flex;align-items:center;justify-content:center;
}
.opcatchup-box{max-width:460px;display:flex;flex-direction:column;align-items:flex-start;gap:10px;}
.opcatchup h1{margin:0;font-size:18px;font-weight:600;color:var(--op-text,#E6EEF2);}
.opcatchup p{margin:0;font-size:13px;line-height:1.5;color:var(--op-text,#E6EEF2);}
.opcatchup .opcatchup-note{font-size:12px;color:var(--op-muted,#9FB3BD);}
.opcatchup a{color:var(--op-accent,#67DCD3);}
.opcatchup-spin{
  width:18px;height:18px;border-radius:50%;box-sizing:border-box;
  border:2px solid var(--op-line,#22383F);border-top-color:var(--op-accent,#67DCD3);
  animation:btnspin .9s linear infinite;
}
@media (prefers-reduced-motion: reduce){.opcatchup-spin{animation:none;}}
/* A long list of figures, two to a row, so what comes after it stays in view. */
.opask-figures-two{grid-template-columns:1fr 1fr;column-gap:16px;}
/* What the picture cannot answer, set apart from what it counted. */
.opask-limits{
  margin:0;padding:2px 0 2px 10px;border-left:2px solid var(--op-line);
  font-size:12.5px;line-height:1.5;color:var(--op-text);
}
.opask-handoff{display:flex;flex-direction:column;align-items:flex-start;gap:8px;}
/* The panel's own control shape, outlined rather than filled so it does not
   read as the Ask button. */
.opask-tre{
  height:30px;padding:0 12px;border:1px solid var(--op-accent);border-radius:7px;
  background:transparent;color:var(--op-accent);font:inherit;font-size:12.5px;
  font-weight:600;cursor:pointer;
}
.opask-tre:hover{background:color-mix(in srgb,var(--op-accent) 14%,transparent);}
.opask-tre:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opask-tre:disabled{cursor:progress;opacity:.85;}
.opask-pathway{
  width:100%;box-sizing:border-box;padding:10px 12px;
  border:1px solid var(--op-line);border-radius:8px;background:var(--op-row);
}
.opask-pathway[hidden]{display:none;}
.opask-pathway .opask-label{margin-bottom:8px;}
.opask-steps{
  margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:6px;
  font-size:12.5px;line-height:1.45;color:var(--op-text);
}
/* The answer's regions on the map: an outline in the accent that stays the
   same width however far in the map is, over a faint fill, and never in the
   way of a pointer. */
/* The focused area's outline. It was the assistant's alone; it is the
   focus's now, whichever way in set it, and it comes from the server so a
   refresh keeps it. */
/* The focused area NEVER TAKES A POINTER. With pointer events it swallowed
   the hover and the click of every marker, label and facility icon beneath it,
   so the tooltips stopped and the markers stopped opening. Stated on the group
   so it holds whatever the paint order later becomes. */
.gm-asked{pointer-events:none;}
.gm-asked path{fill:var(--op-accent);fill-opacity:.10;stroke:var(--op-accent);stroke-width:1.6;
  vector-effect:non-scaling-stroke;pointer-events:none;}
.geomap-return{position:absolute;left:50%;top:10px;transform:translateX(-50%);z-index:5;
  height:28px;padding:0 12px;border:1px solid var(--op-accent);border-radius:999px;
  background:var(--op-panel);color:var(--op-accent);font:inherit;font-size:12px;font-weight:600;cursor:pointer;}
.geomap-return[hidden]{display:none;}
.geomap-return:hover{background:var(--op-row);}
.geomap-return:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
@keyframes opask-spin{to{transform:rotate(360deg);}}
@keyframes opask-breathe{50%{filter:brightness(1.25);}}
@media (prefers-reduced-motion: reduce){
  .opask-go.is-busy::before,.opask-toggle.is-busy,.opask-mic[aria-pressed="true"] .opask-mic-icon{animation:none;}
}

/* ---- Readings on the Casualties list -------------------------------------
   The ALERTS bar, the four reading columns, the history dialog and its chart,
   and the record panel's drag handle. Colours are the tokens above, and the
   triage chips are the rows' own `opsev` classes, so a T code looks the same
   everywhere on the screen. */
.opalerts{display:flex;gap:10px;align-items:stretch;flex-wrap:wrap;margin:0 0 12px;}
.optri-bar{flex:1 1 auto;display:flex;align-items:center;gap:12px;flex-wrap:wrap;background:var(--op-panel);border:1px solid var(--op-line);border-top:3px solid var(--op-alert);border-radius:6px;padding:8px 14px;}
.optri-bar-count{color:var(--op-alert);font-size:18px;font-weight:600;font-variant-numeric:tabular-nums;}
.optri-bar-word{font-family:var(--label);letter-spacing:.06em;font-size:18px;font-weight:600;color:var(--op-text);}
.optri-chips{display:flex;gap:6px;margin-left:auto;flex-wrap:wrap;}
.opwear-tri{width:20px;height:18px;flex:0 0 auto;vertical-align:-3px;}
.opwear-tri path{fill:none;stroke:var(--op-alert);stroke-width:2;stroke-linejoin:round;}
.opwear-tri .opwear-tri-mark{fill:var(--op-alert);stroke:none;}
/* A chip: the label in the rows' own triage colour, the count beneath it. */
/* The categories in ALERTS are two part mix chips (`.opmix`, 5 November
   2026); Silent is a count of devices, not a category, and keeps its label
   over its count. */
.optri{display:inline-flex;align-items:center;}
.optri-silent{align-self:center;display:inline-grid;grid-template-rows:auto auto;min-width:40px;text-align:center;border:1px solid var(--op-line);border-radius:4px;overflow:hidden;font-variant-numeric:tabular-nums;}
.optri-silent .optri-label{display:block;margin:0;padding:1px 6px;font-size:12px;font-weight:700;background:var(--op-muted);color:var(--op-chip-ink);}
.optri-silent .optri-count{padding:2px 6px;font-size:16px;font-weight:600;color:var(--op-text);background:var(--op-row);}
/* The four readings: the value, then its icon at the height of the text. */
.opcell-read{white-space:nowrap;}
.opread{display:inline-flex;align-items:center;gap:5px;font-weight:600;font-variant-numeric:tabular-nums;color:var(--op-text);white-space:nowrap;text-decoration:none;}
.opread svg{width:1em;height:1em;flex:0 0 auto;}
.opread-hr svg{color:var(--op-hr);}
.opread-spo2 svg{color:var(--op-spo2);}
.opread-rr svg{color:var(--op-rr);}
.opread-battery svg{color:var(--op-battery);}
.opread-btn{cursor:pointer;border-bottom:1px dotted var(--op-muted);}
.opread-btn:hover .opread-value,.opread-btn:focus-visible .opread-value{color:var(--op-accent);}
.opread:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;border-radius:2px;}
.opread-low .opread-value{color:var(--op-severe);}
.opread-sim .opread-value{color:var(--op-muted);font-weight:400;}
.opread-simtag{margin-left:4px;font-size:12px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;color:var(--op-muted);border:1px solid var(--op-line);border-radius:3px;padding:0 3px;}
.opread-notsent{color:var(--op-muted);font-size:12px;}
.opcell-sev{white-space:nowrap;}
.opsilentmark{margin-left:6px;padding:1px 4px;font-size:12px;font-weight:600;color:var(--op-chip-ink);background:var(--op-muted);border-radius:3px;vertical-align:middle;}
/* Time and severity stay in view while the wide table scrolls sideways
   inside its own area. */
.opcasualties .optable th:nth-child(1),.opcasualties .optable td:nth-child(1){position:sticky;left:0;z-index:1;width:52px;min-width:52px;background:var(--op-panel);}
.opcasualties .optable th:nth-child(2),.opcasualties .optable td:nth-child(2){position:sticky;left:52px;z-index:1;background:var(--op-panel);}
/* The header sticks to the top and the two pinned columns to the left, so they
   meet. The header goes over the rows scrolling up under it, and the two
   pinned header cells over everything, so the headings scrolling sideways go
   under them. With both at 1 the rows came later in the page and painted over
   the header: scrolled down, Time and Severity were covered (browser
   walkthrough, walk 6, 29 September). */
.opcasualties .optable thead th{z-index:2;}
/* At the 12px floor (BIO-126) the headers, kept to one line, set the
   columns wider than the panel and pushed Open out of sight. They wrap
   instead, so the cells decide the widths as they did. */
.opcasualties .optable thead th{white-space:normal;overflow:visible;text-overflow:clip;vertical-align:bottom;}
.opcasualties .optable thead th:nth-child(-n+2){z-index:3;}
.opcasualties .oprow.opopen td:nth-child(-n+2),.opcasualties .oprow-link:hover td:nth-child(-n+2){background:var(--op-row);}
/* The history dialog: the page dims behind it at about sixty percent. */
.opdialog{width:min(640px,calc(100vw - 32px));max-height:calc(100vh - 48px);overflow:auto;padding:18px 20px 16px;border:1px solid var(--op-line);border-radius:10px;background:var(--op-panel);color:var(--op-text);}
.opdialog::backdrop{background:rgba(0,0,0,.6);}
.opdialog-x{position:absolute;top:10px;right:12px;width:30px;height:30px;border:1px solid var(--op-line);border-radius:50%;background:var(--op-row);color:var(--op-text);font-size:18px;line-height:1;cursor:pointer;}
.opdialog-x:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opreadings-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding-right:36px;}
.opreadings-title{margin:0;font-size:18px;font-weight:600;color:var(--op-text);}
.opreadings-device{color:var(--op-muted);font-size:12px;}
.opreadings-tabs{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0 6px;}
.opreadings-tab{padding:3px 10px;border:1px solid var(--op-line);border-radius:999px;color:var(--op-text);font-size:12px;text-decoration:none;background:var(--op-row);}
.opreadings-tab.on{border-color:var(--op-accent);color:var(--op-accent);font-weight:600;}
.opreadings-latest{margin:8px 0 4px;}
.opreadings-value{font-size:26px;font-weight:600;font-variant-numeric:tabular-nums;}
.opreadings-spans{display:flex;gap:6px;flex-wrap:wrap;margin:8px 0;}
.opreadings-count{margin:4px 0 8px;font-size:12px;}
.opreadings-one{margin:14px 0;}
/* The view's own heading ink: the page's heading rule is the research theme's
   dark ink, which vanished on this panel. */
.opreadings-one .opdetail-h{margin:0 0 6px;font-size:12px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--op-text);}
.opreadings-one .opdetail-h .opnone{margin-left:6px;font-weight:400;letter-spacing:0;text-transform:none;font-style:normal;}
.opreadings-table td,.opreadings-table th{font-size:12px;}
.opchart{display:block;width:100%;height:auto;margin:6px 0;}
.opchart-grid{stroke:var(--op-line);stroke-width:1;}
.opchart-tick{fill:var(--op-muted);font-size:12px;}
.opchart-line{fill:none;stroke:currentColor;stroke-width:2;stroke-linejoin:round;}
.opchart-band{fill:currentColor;opacity:.15;}
.opchart-dot{fill:currentColor;}
.opchart-hr{color:var(--op-hr);}
.opchart-spo2{color:var(--op-spo2);}
.opchart-rr{color:var(--op-rr);}
.opchart-battery{color:var(--op-battery);}
/* The record panel's width: its saved value, never above sixty percent of the
   window, with a handle between the list and the record. */
/* Two caps, because one was not enough: 60 percent of the window alone left a
   1400px screen's list 50px wide beside the rail. The record also leaves the
   list at least 360px, measured against this grid, never the window. */
.opsplit-handle{position:relative;cursor:col-resize;border-radius:4px;touch-action:none;}
.opsplit-handle::before{content:"";position:absolute;top:0;bottom:0;left:4px;width:2px;background:var(--op-line);border-radius:1px;}
.opsplit-handle:hover::before,.opsplit-handle.dragging::before{background:var(--op-accent);}
.opsplit-handle:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
/* The same orange triangle on the map, on a place holding somebody in need. */
.gm-need path{fill:var(--op-alert);stroke:var(--op-bg);stroke-width:1.5;}

/* --- The Operational View on a tablet and a phone (ISSUES.md BIO-84) -------
   Measured at 1600, 1400, 1024, 768, 390 and 320 wide: the page itself never
   scrolls sideways. What is wider than the screen scrolls inside its own box:
   the section tabs in their strip, the tables in theirs, a dialog inside
   itself. Below 600 every control is at least 44 pixels tall to touch. */

/* The menu row: the tabs and the "?" in a strip that scrolls inside itself,
   then the refresh control, 24 pixels after the "?" while there is room and
   pinned at the right end when there is not, because the strip gives way and
   the control does not. Then the rail toggle, at the far right. */
.optabs{overflow:visible;align-items:center;gap:0;}
.optabs-strip{display:flex;gap:2px;align-items:center;flex:0 1 auto;min-width:0;
              overflow-x:auto;scrollbar-width:thin;}
.optabs > .oprefresh{flex:none;margin-left:24px;margin-right:12px;}
.optabs > .oprailtoggle{margin-left:auto;}

/* The refresh control's short form, used below 768: the icon, and "0 s".
   The words go out of sight and stay in the accessibility tree, so a screen
   reader still hears "Refresh now" and "Updated 0 s ago". */
.oprefresh-short{display:none;}
@media (max-width:767px){
  .oprefresh-btn-text,
  .oprefresh-full{position:absolute;width:1px;height:1px;margin:-1px;padding:0;
                  overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;}
  .oprefresh-short{display:inline;}
  .optabs > .oprefresh{margin-left:12px;gap:6px;}
  .optabs .oprefresh-btn{padding:8px 11px;}
}

/* The filter rail at 1180 and below, where it stops being a column and
   becomes a band above the panels: a panel the Filters button opens. Only when the
   page's script is running (`op-js`, set by it): without JavaScript there is
   no button to press, so the rail stays shown, stacked above the panels, and
   every filter stays reachable. */
@media (max-width:1180px){
  .oprailtoggle{display:inline-flex;}
  .opview.op-js:not(.oprail-open) .oprail{display:none;}
  .opview .opgrid:not(.opgrid-tab) > .opcol{height:auto;}
  .oppanel-map{min-height:min(70vh,520px);}
  .oppanel-map .opmap{min-height:min(70vh,520px);}
  /* The live feed scrolls sideways inside its panel, with the time and the
     triage chip pinned, as the Casualty Records table already does. */
  .opscroll{overflow:auto;}
  .opgrid:not(.opgrid-tab) .optable{min-width:640px;}
  .opgrid:not(.opgrid-tab) .optable th:nth-child(1),
  .opgrid:not(.opgrid-tab) .optable td:nth-child(1){position:sticky;left:0;z-index:1;width:52px;min-width:52px;background:var(--op-panel);}
  .opgrid:not(.opgrid-tab) .optable th:nth-child(2),
  .opgrid:not(.opgrid-tab) .optable td:nth-child(2){position:sticky;left:52px;z-index:1;background:var(--op-panel);}
  /* With no band the right hand column has no height to share, and its two
     panels, which share it at flex 1 1 0, closed to their headings (BIO-85).
     Each takes its own height here, its rows scrolling inside at the height
     the lists have everywhere else. */
  .opview .opgrid:not(.opgrid-tab) > .opcol:last-child > .oppanel{flex:none;}
  .opview .opgrid:not(.opgrid-tab) > .opcol:last-child .opscroll{flex:none;max-height:290px;}
  .gmkey{flex-wrap:wrap;}
  .gmkey-body{overflow-x:auto;}
  .opfilterbar{flex-wrap:wrap;}
}

/* Two columns of headline cards on a tablet, 1024 wide included. */
@media (max-width:1024px){
  .opcounters{grid-template-columns:repeat(2,minmax(0,1fr));}
}

/* A phone. One column of cards, the header's furniture allowed to wrap, and
   every control at least 44 pixels to touch. */
@media (max-width:599px){
  /* The title takes a line of its own and wraps, rather than squeezing to
     a sliver beside the logo and pushing the header past the screen. */
  .optitle{flex-basis:100%;order:3;}
  .opcounters{grid-template-columns:minmax(0,1fr);}
  .opbar{gap:8px 12px;padding:5px 12px;}
  .optab{min-height:44px;display:inline-flex;align-items:center;}
  .ophelp{width:44px;height:44px;line-height:44px;}
  .oprefresh-btn,.oprailtoggle,.opbtn{min-height:44px;}
  .opwindow{min-height:44px;display:inline-flex;align-items:center;justify-content:center;}
  /* The nation chips stay 29 pixel pills (BIO-64) and are 45 to touch: an
     invisible area 8 pixels above and below each, measured from the outside
     of the border (so 9 from the padding box it is placed against), and 16
     between rows, so two chips' areas meet and never overlap. The name's ellipsis is on its
     own span, so the chip no longer needs to clip. */
  .opview:not(.oprail-shut) .oprail .opchips{row-gap:16px;}
  .opview:not(.oprail-shut) .oprail .opchip{position:relative;overflow:visible;}
  .opview:not(.oprail-shut) .oprail .opchip::before{content:"";position:absolute;left:-1px;right:-1px;top:-9px;bottom:-9px;}
  .opgrid{padding:4px 10px 12px;}
  .opcounters{padding:6px 10px 0;}
}

/* Dialogs fit the screen and scroll inside themselves, with the close button
   kept in reach at the top while the rest scrolls. */
.opdialog{max-height:calc(100dvh - 24px);}
.opdialog-x{position:sticky;top:0;z-index:2;}
@media (max-width:599px){
  .opdialog{width:calc(100vw - 16px);padding:12px;}
  .opdialog-x{min-width:44px;min-height:44px;}
}

/* --- The research environment at full width (ISSUES.md BIO-87) -------------
   Every page with the research shell, the menu beside the content, uses the
   whole window instead of a centred 1360 box, from a laptop to a 4K screen.
   Pages without the shell (signing in, a code, an invitation) keep their
   centred card. What gains from the width is anything laid out in a grid,
   which gains columns rather than growing, and tables and charts. Running
   text does not: a paragraph keeps a readable measure however wide the
   window, because a line of 300 characters is not read, it is skimmed. */
body:has(.app .body) .stage{max-width:none;margin:0;
  padding:clamp(14px,1.4vw,30px) clamp(16px,2vw,40px) 0;}
body:has(.app .body) footer,
body:has(.app .body) .staticmark{max-width:none;
  padding-left:clamp(16px,2vw,40px);padding-right:clamp(16px,2vw,40px);}
.main{padding-left:clamp(20px,2vw,40px);padding-right:clamp(20px,2vw,40px);}
/* The measure. Paragraphs, list items and the boxed notes stop at about 80
   characters; a table, a chart, a grid or a form is not text and takes the
   width it is given. The narrower measures already set (`36em`, `70ch`) are
   more specific and still win. */
.main p,.main li,.main .note{max-width:80ch;}
.main table p,.main table li{max-width:none;}
/* Chart cards in as many columns as fit, each at least 460 wide, so a 4K
   screen shows more charts rather than bigger ones. The results table, wide or
   open, still takes the whole row. */
.charts{grid-template-columns:repeat(auto-fill,minmax(min(100%,460px),1fr));}
/* The catalogue's three or four figures: the grid keeps a sensible width
   rather than stretching four numbers across a 4K screen. */
.grid3,.grid4{max-width:1240px;}

/* --- The analysis page as tabs (ISSUES.md BIO-87, design Option B) ---------
   A header that is the same on every tab, a sticky tab bar, and four panels.
   New text here is in --text, --paper or --brand-teal-lift, every one above
   7:1 on white; --muted is not used for anything new, as it is under it. */
.analysis{display:flex;flex-direction:column;gap:0;}
/* Three rows since BIO-118: the title and the actions, the facts strip, then
   the conditions with your tags at the top right. 16px between the rows and
   24px before the tabs. One control height for row one and one for row three,
   set here because the stylesheet has no shared one. */
.ahead{--ahead-ctl:36px;--ahead-chip:28px;display:flex;flex-direction:column;gap:16px;padding-bottom:24px;}
.ahead-top{display:flex;align-items:flex-start;gap:12px 16px;}
.ahead-back{display:inline-flex;align-items:center;justify-content:center;width:var(--ahead-ctl);height:var(--ahead-ctl);
  border-radius:8px;color:var(--paper);text-decoration:none;font-size:18px;flex:none;}
.ahead-back:hover{background:var(--surface-3);}
.ahead-name{flex:1 1 0;min-width:0;position:relative;}
.ahead-name h3{font-size:20px;margin:0;line-height:1.35;padding-top:3px;min-width:0;overflow-wrap:anywhere;}
.mono{font-family:var(--mono);}
.analysistitle-row{display:flex;align-items:flex-start;gap:8px;min-width:0;}
.ahead .analysistitle .renameopen{width:var(--ahead-ctl);height:var(--ahead-ctl);padding:0;flex:none;
  display:inline-flex;align-items:center;justify-content:center;}
.ahead .analysistitle .renameopen[hidden]{display:none;}
.ahead-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;flex:none;justify-content:flex-end;}
.ahead-actions .btn{height:var(--ahead-ctl);display:inline-flex;align-items:center;padding:0 14px;white-space:nowrap;}

/* The facts strip: four equal cells divided by thin rules, two by two on a
   narrower screen and stacked on a phone. */
.afacts{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));margin:0;
  border:1px solid var(--hairline);border-radius:10px;background:var(--surface-2);}
.afact{min-width:0;padding:12px 16px;border-left:1px solid var(--hairline);display:flex;flex-direction:column;gap:6px;}
.afact:first-child{border-left:0;}
.afact-label{font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12px;font-weight:600;
  color:var(--text);line-height:1.2;}
.afact-value{margin:0;display:flex;flex-direction:column;align-items:flex-start;gap:4px;min-width:0;
  font-size:14px;line-height:1.4;color:var(--paper);overflow-wrap:anywhere;}
.afact-value a{color:var(--brand-teal-lift);font-weight:600;}
.afact-sub{font-family:var(--mono);font-size:12.5px;color:var(--text);}
.afact-line{display:flex;flex-wrap:wrap;align-items:baseline;gap:2px 8px;}
.afact-n{font-family:var(--mono);font-size:16px;font-weight:700;color:var(--paper);font-variant-numeric:tabular-nums;}
.afact-of{color:var(--text);}
.afact .sharebar{align-self:stretch;margin:4px 0 0;}

/* Row three: the conditions wrap on the left, and the tags and What can leave
   hold the top right however many conditions there are. */
.ahead-row3{display:flex;align-items:flex-start;justify-content:space-between;gap:10px 24px;}
.ahead-conds{display:flex;align-items:flex-start;gap:6px 8px;flex:1 1 auto;min-width:min(240px,30%);}
.ahead-side{display:flex;align-items:flex-start;justify-content:flex-end;gap:6px 10px;flex:0 1 auto;}
.ahead-side > .afact-label,.ahead-side > .helptip{flex:none;}
.ahead-side .helptip > summary{line-height:1.2;}
/* The tags flow from their label, and + Add tag stays beside the last line
   of them rather than taking a line of its own. */
.ahead-side .tagbar{flex:0 1 auto;min-width:0;flex-wrap:nowrap;align-items:flex-end;}
.ahead-side .tagpills{min-width:0;}
.ahead-side .tagpills:empty{display:none;}
.ahead-row3 .afact-label{margin-right:4px;line-height:var(--ahead-chip);white-space:nowrap;}
.ahead-row3 .cchip,.ahead-row3 .tagpill{min-height:var(--ahead-chip);box-sizing:border-box;padding-top:0;padding-bottom:0;}
.ahead-row3 .helptip > summary{min-height:var(--ahead-chip);}
.ahead-row3 .tagbar{gap:6px;}
.btngroup{display:inline-flex;}
.btngroup .btn{border-radius:0;margin-left:-1px;}
.btngroup .btn:first-child{border-radius:8px 0 0 8px;margin-left:0;}
.btngroup .btn:last-child{border-radius:0 8px 8px 0;}
/* Request release greyed when the form cannot be prepared: the state is in
   the ground and the border, never in faint text, which would read as broken
   and fall under the contrast floor. */
.ahead-release[aria-disabled="true"]{background:var(--surface-3);border:1px dashed var(--hairline);
  color:var(--text);cursor:not-allowed;}
.ahead-release[aria-disabled="true"]:hover{background:var(--surface-3);border-color:var(--hairline);}
.ahead-message{margin:0;}
.ahead-chips{display:flex;flex-wrap:wrap;gap:6px;list-style:none;margin:0;padding:0;flex:1 1 0;min-width:0;}
.cchip{display:inline-flex;align-items:center;min-height:28px;padding:2px 10px;border-radius:14px;
  background:var(--teal-wash);color:var(--paper);font-size:13px;max-width:none;}
.ahead .drillpath{margin:0;}
/* The rename form opens over the page with the script, so the chips and the
   tabs under the title never move; without it, it is part of the page. */
.js .ahead .renameform{position:absolute;left:0;top:calc(100% + 6px);z-index:40;width:min(560px,90vw);
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:12px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);}

/* The tab bar. Sticky, so the tab just pressed stays where it was. */
.atabs{position:sticky;top:0;z-index:30;background:var(--surface);
  border-bottom:1px solid var(--hairline);margin:0 0 16px;}
.atabs-list{display:flex;gap:20px;overflow-x:auto;}
.atab{display:inline-flex;align-items:center;gap:4px;min-height:44px;padding:0 4px;
  font-size:14px;font-weight:500;color:var(--text);text-decoration:none;
  border-bottom:2px solid transparent;white-space:nowrap;}
.atab:hover{color:var(--paper);}
.atab.on{color:var(--paper);border-bottom-color:var(--brand-teal);}
.atab:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:-2px;}
.atab-n{font-weight:400;}
.apanel[hidden]{display:none;}

/* Help: a small link that opens over the page. A details element, so it opens
   and closes with JavaScript off too, and positioned, so it never pushes the
   page down. The wording inside is the page's own, unchanged. */
.helptip{position:relative;display:inline-block;}
.helptip > summary{list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:5px;
  font-size:12.5px;font-weight:600;color:var(--brand-teal-lift);white-space:nowrap;}
.helptip > summary::-webkit-details-marker{display:none;}
.helptip > summary::before{content:"i";display:inline-flex;align-items:center;justify-content:center;
  width:15px;height:15px;border:1.5px solid currentColor;border-radius:50%;font-size:10px;
  font-style:italic;font-family:Georgia,serif;}
.helptip-body{position:absolute;left:0;top:calc(100% + 6px);z-index:45;width:min(460px,86vw);
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:12px 14px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);color:var(--text);font-weight:400;white-space:normal;}
.helptip-end .helptip-body{left:auto;right:0;}
.helptip-body p{margin:0 0 8px;max-width:none;font-size:13px;line-height:1.6;color:var(--text);}
.helptip-body p:last-child{margin-bottom:0;}
/* About these numbers is a help popover now (BIO-87); its body keeps the
   popover's place rather than the old inline one. */
.about-toggle .about-body{position:absolute;}

.atoolbar{display:flex;align-items:center;gap:10px;margin:0 0 12px;}
.atoolbar-gap{flex:1;}
.atoolbar form{margin:0;}
.anote{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px 10px;}

/* A card's other actions, in one menu, the same on the table and every chart. */
.cardmore{position:relative;}
.cardmore > summary{list-style:none;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;
  width:32px;height:32px;border:1px solid var(--hairline);border-radius:8px;background:var(--surface);
  color:var(--paper);font-size:16px;line-height:1;}
.cardmore > summary::-webkit-details-marker{display:none;}
.cardmore[open] > summary{border-color:var(--brand-teal);}
.cardmore-menu{position:absolute;right:0;top:calc(100% + 6px);z-index:35;width:260px;
  background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:8px;
  box-shadow:0 18px 40px rgba(16,34,42,.18);display:flex;flex-direction:column;gap:4px;}
.cardmore-menu form{margin:0;display:block;}
.cardmore-menu .hint{margin:0 4px 4px;font-size:13px;color:var(--text);}
.cardmore-item,.cardmore-menu .chart-remove{display:block;width:100%;height:auto;text-align:left;
  border:0;border-radius:7px;background:none;padding:7px 9px;font:inherit;font-size:13px;
  color:var(--paper);text-decoration:none;cursor:pointer;}
.cardmore-menu .chart-remove{color:var(--blocked-ink);}
.cardmore-item:hover,.cardmore-menu .chart-remove:hover{background:var(--surface-3);}
.cardmore-menu .chart-remove[disabled]{color:var(--text);background:none;cursor:not-allowed;}
/* The title in the card header, between the label and the controls. */
.chart-head .chart-title{flex:1;min-width:0;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.chart-head .chart-k{flex:none;}
/* The removal question opens over the top of its card rather than pushing
   the card, and every card after it, down. */
.chartcard > .chart-confirm{position:absolute;left:12px;right:12px;top:56px;z-index:30;
  box-shadow:0 18px 40px rgba(16,34,42,.18);}
.chartcard > .chart-error:not([hidden]){position:absolute;left:12px;right:12px;bottom:10px;z-index:30;
  margin:0;background:var(--blocked-wash);border:1px solid var(--blocked);border-radius:8px;padding:8px 10px;}

/* Statistics: the two cards side by side where they fit. */
/* One card a row until each has room for its controls on one line, which
   the regression card's four menus and button need (BIO-127): side by side
   only on the widest screens. */
.astats{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,900px),1fr));gap:16px;align-items:start;}
.astats .regcard{margin-top:0;}
.astats .sigcard-head{display:flex;align-items:flex-start;gap:10px;}
.astats .sigcard-head > div:first-child{flex:1;}

/* Release: the two steps, and the rules and requests beside them. */
.arelease{display:grid;grid-template-columns:minmax(0,1fr) minmax(280px,400px);gap:16px;align-items:start;}
.arelease-main,.arelease-side{display:flex;flex-direction:column;gap:16px;min-width:0;}
.arelease-form{display:flex;flex-direction:column;gap:16px;align-items:flex-start;}
.arelease-form .astep{width:100%;}
.astep-head{display:flex;align-items:baseline;gap:10px;margin-bottom:10px;}
.astep-head h4{flex:1;margin:0;font-size:15px;}
.astep-head .eyebrow{margin:0;}
/* The release request as a panel under the header (BIO-159). */
.releasepanel{margin:0 0 16px;display:flex;flex-direction:column;gap:14px;}
.releasepanel[hidden]{display:none;}
.releasepanel-head{display:flex;align-items:center;gap:12px;flex-wrap:wrap;}
.releasepanel-head h3{flex:1;margin:0;font-size:18px;}
.releasepanel-head h3:focus{outline:2px solid var(--brand-teal);outline-offset:3px;}
.releasepanel-problems p,.releasepanel-problems ul{margin:0 0 6px;}
.releasepanel-problems ul{padding-left:20px;}
.releasepanel .astep{border:0;margin:0;padding:0;min-width:0;}
.releasepanel legend.astep-head{padding:0;font-size:15px;font-weight:600;}
.releasepanel .astep-head label{font-size:15px;font-weight:600;}
.releaserules{margin:0 0 8px;padding-left:18px;font-size:13px;line-height:1.55;}
.openreqs{margin:0 0 8px;padding-left:18px;font-size:13.5px;line-height:1.55;}
.ruletiles{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:8px;}
.ruletile{border:1px solid var(--hairline-soft);border-radius:8px;padding:9px 11px;font-size:13px;
  line-height:1.45;color:var(--paper);max-width:none;}

/* History: the record, and where it came from beside it. */
.ahistory{display:grid;grid-template-columns:minmax(0,1fr) minmax(260px,360px);gap:16px;align-items:start;}
.ahistory-side{display:flex;flex-direction:column;gap:16px;}
.ahistory .history{margin-top:0;border-top:0;padding-top:16px;}

@media (width <= 1040px){
  .arelease,.ahistory{grid-template-columns:1fr;}
}
/* Below 1100px the actions take their own line under the title, the strip
   goes two by two, and the tags follow the conditions. */
@media (width < 1100px){
  .ahead-top{flex-wrap:wrap;}
  .ahead-actions{flex-basis:100%;justify-content:flex-start;padding-left:calc(var(--ahead-ctl) + 16px);}
  .afacts{grid-template-columns:repeat(2,minmax(0,1fr));}
  .afact:nth-child(3){border-left:0;}
  .afact:nth-child(n+3){border-top:1px solid var(--hairline);}
  .ahead-row3{flex-wrap:wrap;}
  .ahead-conds{min-width:0;}
  .ahead-side{justify-content:flex-start;flex-basis:100%;}
}
@media (width < 700px){
  .ahead-actions{padding-left:0;}
  .afacts{grid-template-columns:minmax(0,1fr);}
  .afact{border-left:0;}
  .afact + .afact{border-top:1px solid var(--hairline);}
  /* The labels above their chips, so a condition has the full width. One
     longer than a phone is wide wraps inside its chip rather than being cut. */
  .ahead-conds,.ahead-side{flex-direction:column;align-items:flex-start;}
  .ahead-row3 .afact-label{line-height:1.2;}
}
@media (width <= 620px){
  .btngroup{flex-wrap:wrap;}
  .btngroup .btn{border-radius:8px;margin:0;}
  .atabs-list{gap:12px;}
}
/* The analysis page's tab bar sticks to the window, and a sticky element
   inside a box with overflow hidden sticks to that box instead, which never
   scrolls. Clip does the same clipping of the rounded corners without making
   the box a scroller (BIO-87). */
.app:has(.analysis){overflow:clip;}
/* Every panel at least a screen tall when the tabs switch in place, so a
   short tab can still be scrolled to put its bar at the top: without it the
   browser clamps the scroll and the bar, and the tab just pressed, jump down. */
.atabs-live .apanel{min-height:calc(100vh - 64px);}
/* On a narrow screen the card's help link and Collapse go under its title
   rather than squeezing it to a word a line. */
.astats .sigcard-head{flex-wrap:wrap;}
.astats .sigcard-head > div:first-child{flex:1 1 240px;}
/* On a phone the signed in email gives way, so Sign out is not cut off at the
   right of the top bar. It was, on every research page, before BIO-87. */
@media (width <= 620px){
  .whoemail{max-width:130px;}
  .who{flex-wrap:wrap;justify-content:flex-end;row-gap:6px;min-width:0;}
}

/* The safe defaults tick box above a catalogue's restrictions (BIO-88). */
.restrictions-source{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin:0 0 12px;
  padding:10px 12px;border:1px solid var(--hairline);border-radius:8px;background:var(--surface-2);}
.restrictions-source .hint{flex-basis:100%;color:var(--text);}
.source-tick{display:inline-flex;align-items:center;gap:8px;color:var(--paper);}
/* A group's rule on a catalogue (BIO-89). */
.override-form{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px 12px;}
.override-form .field{margin:0;}
/* The People list's bulk actions (BIO-89). */
.bulkbar{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px 12px;padding:12px;
  border:1px solid var(--hairline);border-radius:10px;background:var(--surface-2);}
.bulkbar .field{margin:0;}
.bulkbar-gap{flex:1;}
.effective-rules{margin:10px 0 0;}
.effective-rules > summary{cursor:pointer;font-weight:600;color:var(--brand-teal-lift);}

/* The public reachability page (BIO-92). Its own narrow column, since it has
   no menu and no frame. The two rules at the end are the Styles check itself:
   without this stylesheet the page shows "Not loaded" and hides "Loaded",
   and with it the other way round. */
body.reach{background:var(--base);color:var(--text);margin:0;}
.reach-main{max-width:760px;margin:0 auto;padding:40px 16px 56px;}
.reach-title{font-size:26px;font-weight:600;margin:6px 0 12px;color:var(--paper);}
.reach-sub{font-size:16px;font-weight:600;margin:28px 0 8px;color:var(--paper);}
.reach-table{margin-top:18px;}
.reach-table th:last-child,.reach-table td:last-child{text-align:left;}
.reach-facts{display:grid;grid-template-columns:minmax(0,max-content) minmax(0,1fr);gap:6px 18px;margin:0 0 10px;}
.reach-facts dt{color:var(--text);}
.reach-facts dd{margin:0;font-family:var(--mono);overflow-wrap:anywhere;}
@media (max-width:520px){.reach-facts{grid-template-columns:minmax(0,1fr);gap:2px;}.reach-facts dd{margin-bottom:8px;}}
.reach-yes,.reach-yes[hidden]{display:inline;}
.reach-no{display:none;}

/* The line on the research map itself when its catalogue's controls are
   switched off by the owner (BIO-94), and the By area card on a result. The
   line takes the control colour, as the perimeter and every suppression note
   do, on its own wash with the ink for text, which is above the 7.0 floor. */
.fmap-off{margin:8px 0 10px;padding:8px 12px;border-left:3px solid var(--control);
  background:var(--control-wash);color:var(--paper);font-size:13px;}
.byarea{margin-top:16px;}
.byarea td.n,.byarea th.n{text-align:right;font-family:var(--mono);}

/* The catalogue page (BIO-96). 16px between the section boxes, so none sits
   against the next. */
.catalogue-owner > section.card + section.card{margin-top:16px;}
/* The Restrictions head: the tick box and Reset all on one line. */
.restrictions-head{display:flex;flex-wrap:wrap;align-items:center;gap:8px 16px;}
.restrictions-head .restrictions-source{margin:0;}
.restrictions-says{margin:6px 0 12px;color:var(--text);}
/* One compact row a rule: name, control, default, range and an info link. */
.restrictions-table td{vertical-align:middle;padding-top:7px;padding-bottom:7px;}
.rform{display:flex;flex-wrap:wrap;align-items:center;gap:6px 8px;margin:0;position:relative;}
.rform .input{max-width:96px;}
.rform .rform-wide{max-width:200px;}
/* A refusal, beside its field as a bubble laid over the page rather than a
   line in the row, so showing it moves nothing (BIO-96). */
.rform-error{position:absolute;left:0;top:calc(100% + 4px);z-index:20;width:max-content;
  max-width:min(340px,70vw);padding:7px 10px;border-radius:7px;background:var(--blocked-wash);
  border:1px solid var(--blocked);color:var(--paper);font-size:12.5px;font-weight:600;
  box-shadow:0 4px 14px rgba(16,34,42,.14);}
.rform-error:empty{display:none;}
.rform.is-saving .input{opacity:.7;}
/* Save buttons are for scripts off; with them on each value saves itself. */
.js-autosave .rsave{display:none;}
/* The info link: a small round mark that opens the one line explanation as a
   popover, so opening it moves no row. */
.rinfo-cell{width:34px;text-align:right;}
.rinfo{position:relative;display:inline-block;}
.rinfo summary{list-style:none;cursor:pointer;width:22px;height:22px;border-radius:50%;
  border:1px solid var(--hairline);display:inline-flex;align-items:center;justify-content:center;
  font-size:12px;font-weight:600;color:var(--brand-teal-lift);background:var(--surface);}
.rinfo summary::-webkit-details-marker{display:none;}
.rinfo summary:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}
.rinfo p{position:absolute;right:0;top:28px;z-index:30;width:min(320px,70vw);margin:0;
  padding:10px 12px;background:var(--surface);border:1px solid var(--hairline);border-radius:8px;
  box-shadow:0 6px 20px rgba(16,34,42,.14);font-size:13px;color:var(--text);text-align:left;}
/* The status line's dismiss button. */
.panelmessage{display:flex;align-items:flex-start;gap:12px;}
.panelmessage[hidden]{display:none;}
.panelmessage-close{background:none;border:0;color:inherit;font-size:18px;line-height:1;
  padding:0 2px;cursor:pointer;}
.panelmessage-close:focus-visible{outline:2px solid currentColor;outline-offset:2px;}
.rdialog-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;}
.rdialog-head h3{flex:1;}

/* The audit trail as a timeline with icons (BIO-97). The line and the times
   are the trail's own; each entry's dot becomes a circle on the line with the
   icon of its kind, in the trail's colours: the analysis gold, the sign in
   green, a refusal red, the rest the teal ink. Tighter than before. */
.thread .ev{padding-bottom:14px;min-height:30px;}
.thread .ev::before{display:none;}
.evdot{position:absolute;left:-25px;top:-2px;width:22px;height:22px;border-radius:50%;
  display:inline-flex;align-items:center;justify-content:center;
  background:var(--surface);border:1.5px solid var(--hairline);color:var(--brand-teal-lift);}
.evdot svg{width:13px;height:13px;}
.evdot-run{border-color:var(--control);color:#684B10;background:var(--control-wash);}
.evdot-ai{border-color:var(--brand-teal);color:var(--brand-teal-lift);background:var(--teal-wash);}
.evdot-signin{border-color:var(--cleared);color:#1E563D;background:var(--cleared-wash);}
.ev.red .evdot{border-color:var(--blocked);color:#84301F;background:var(--blocked-wash);}
.ev h4{line-height:1.35;}
.ev p{color:var(--text);}
.evai{display:grid;grid-template-columns:max-content minmax(0,1fr);gap:2px 12px;margin:4px 0 0;font-size:13px;}
.evai dt{color:var(--text);font-weight:600;}
.evai dd{margin:0;color:var(--paper);overflow-wrap:anywhere;}
.evai .evq{font-style:italic;}
.evchanges{margin:4px 0 0;font-size:13px;}
.evchanges summary{cursor:pointer;color:var(--brand-teal-lift);font-weight:600;}
.evchanges ul{margin:4px 0 0;padding-left:18px;color:var(--paper);}
.filterbar .chip[aria-current="true"]{outline:none;}
@media (max-width:620px){
  .evdot{position:static;margin:0 8px 0 0;vertical-align:middle;width:20px;height:20px;}
  .ev .evdot + h4{display:inline;}
  .evai{grid-template-columns:minmax(0,1fr);}
}
/* The times and the who line, at the 7.0 floor: the text ink, 9.8:1 on the
   page, where the dim grey they had was under it. */
.thread .ev .t,.thread .ev .who2{color:var(--text);}

/* The catalogue's cards in a grid (BIO-98). Columns at least 860px, so the
   three figure boxes stay in a row; each card at most 1150px, so on one
   column it does not run the width of a wide screen. Measured: one card at
   1440 (1109) and 1920 (capped at 1150), two from about 2500 (1051 at 2500,
   1081 at 2560) and three at 3840 (1140). Tops lined up; never wider than
   the page, so nothing scrolls sideways. */
.catgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,860px),1fr));
  gap:22px;align-items:start;}
.catcard{max-width:1150px;min-width:0;}

/* Tags (BIO-99): a person's own pills, the shape of the Default and Ready
   badges, in each colour's tint with its ink, which is 9.3 to 11.3 to 1 and
   computed in tests_tags. The name is always written: never colour alone. */
.cardbadges{flex-wrap:nowrap;justify-content:flex-end;}
@media (max-width:720px){.cardbadges{flex-wrap:wrap;justify-content:flex-start;}}
/* One height on one line (BIO-147): tags, + Add tag, Default or Make
   default, Live and No restrictions are each 28px and centred on one axis,
   so no badge sits higher or lower than the one beside it. */
.cardbadges .tagbar,.cardbadges .tagpills{flex-wrap:nowrap;}
.cardbadges .tagpills .tagpill,.cardbadges .tagpill-add,.cardbadges .catdefault-on,.cardbadges > form > .btn,
.cardbadges .catlive,.cardbadges .catidle,.cardbadges .state{
  height:28px;min-height:28px;box-sizing:border-box;padding-top:0;padding-bottom:0;
  display:inline-flex;align-items:center;line-height:1;white-space:nowrap;margin:0;}
.cardbadges > form > .btn{padding-left:12px;padding-right:12px;font-size:13px;}
.cardbadges .catlive,.cardbadges .catidle{padding:0 10px;border-radius:999px;border:1px solid var(--hairline);}
@media (max-width:720px){.cardbadges .tagbar,.cardbadges .tagpills{flex-wrap:wrap;}}
.tagbar{display:flex;align-items:center;gap:6px;flex-wrap:wrap;position:relative;}
.tagpills{display:flex;flex-wrap:wrap;gap:6px;margin:0;padding:0;list-style:none;}
.tagpill{display:inline-flex;align-items:center;gap:6px;border-radius:999px;padding:3px 10px;
  font-size:12px;font-weight:600;line-height:1.4;text-decoration:none;border:1px solid transparent;
  background:var(--surface-3);color:var(--paper);white-space:nowrap;}
a.tagpill:hover{text-decoration:underline;}
.tagpill:focus-visible,.tagpick-option:focus-visible,.tagdrop-pick:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}
.tagdot{width:8px;height:8px;border-radius:50%;flex:none;background:currentColor;}
.tagpill-add{color:var(--text);background:var(--surface);border-color:var(--hairline);border-style:dashed;
  cursor:pointer;list-style:none;}
.tagpill-add::-webkit-details-marker{display:none;}
/* The Operational View's reports list (BIO-179): tags in their own column,
   small chips, and Add tag as the page's own small dark button, the one
   Injuries near a place is, rather than a white pill. */
.oplist-tags{min-width:120px;}
.oplist-tags .tagbar{display:flex;flex-wrap:wrap;align-items:center;gap:4px;}
.oplist-tags .tagpills{display:contents;}
.oplist-tags .tagpills li{display:inline-flex;}
.oplist-tags .tagpill{padding:1px 8px;font-size:12px;}
.oplist-tags .tagpill-add{background:var(--op-row);border:1px solid var(--op-line);border-style:solid;
  color:var(--op-text);border-radius:6px;padding:3px 9px;font-size:12px;font-weight:600;line-height:1.4;}
.oplist-tags .tagpill-add:hover{border-color:var(--op-accent);color:var(--op-accent);}
.tagpick,.tagdrop{position:relative;}
.tagpick > summary,.tagdrop > summary{list-style:none;}
.tagpick > summary::-webkit-details-marker,.tagdrop > summary::-webkit-details-marker{display:none;}
.tagpick-panel,.tagdrop-panel{position:absolute;right:0;top:calc(100% + 6px);z-index:35;
  width:min(300px,85vw);padding:10px;background:var(--surface);border:1px solid var(--hairline);
  border-radius:10px;box-shadow:0 10px 28px rgba(16,34,42,.16);}
.tagdrop-panel{width:min(360px,90vw);}
/* On a phone a tag panel is a sheet at the foot of the window (BIO-150).
   Hung from its button it opened off the left edge whenever the button sat
   at the left, as Tags does at 390; fixed to the window it cannot. */
@media (max-width:720px){
  .tagpick-panel,.tagdrop-panel{position:fixed;left:16px;right:16px;top:auto;bottom:16px;width:auto;
    max-height:70vh;overflow-y:auto;}
}
/* Wider than a phone, Tags on Operational View Reports sits at the left of
   its row, so its panel hangs from the button's left edge. Hung from the
   right it opened 247px off the left of the window (28 October 2026). */
@media (min-width:721px){
  .opreports .tagdrop-panel{right:auto;left:0;}
}
.tagpick-search{width:100%;margin-bottom:8px;}
.tagpick-list,.tagdrop-list{list-style:none;margin:0;padding:0;max-height:260px;overflow-y:auto;}
.tagpick-row{margin:0;}
.tagpick-option,.tagdrop-pick{display:flex;align-items:center;gap:8px;width:100%;padding:6px 8px;border:0;
  background:none;border-radius:6px;color:var(--paper);font:inherit;font-size:13.5px;text-align:left;
  cursor:pointer;text-decoration:none;}
.tagpick-option:hover,.tagdrop-pick:hover{background:var(--surface-3);}
.tagpick-name{flex:1;min-width:0;overflow-wrap:anywhere;}
.tagpick-tick{width:14px;color:var(--brand-teal-lift);font-weight:700;}
.tagdrop-count{font-family:var(--mono);font-size:12px;color:var(--text);}
.tagpick-create{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px;padding-top:8px;border-top:1px solid var(--hairline-soft);}
.tagpick-create .input{flex:1 1 120px;min-width:0;}
.tagpick-create[hidden]{display:none;}
.tagdrop-row{display:flex;flex-wrap:wrap;align-items:center;}
.tagdrop-row .tagdrop-pick{flex:1;}
.tagedit > summary{font-size:12px;color:var(--brand-teal-lift);cursor:pointer;padding:4px 6px;}
.tagedit[open]{flex-basis:100%;padding:6px 8px 8px;}
.tagedit-row{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin:4px 0;}
.tagedit-row .input{flex:1 1 120px;min-width:0;}
/* In the Tags panel and the Your tags table an input sits beside a small
   button, so it is the small button's height, and the button stays on its
   line (BIO-150): stretched, the buttons were 39 and 41px in one panel, and
   in the table each wrapped under its input. */
.tagdrop-panel .tagedit-row .input,[data-tag-table] .tagedit-row .input{
  height:30px;box-sizing:border-box;padding:4px 8px;font-size:13px;}
/* `.rowtable form` is inline-block and outranks `.tagedit-row`, so the flex
   row is said again here, where it is more specific. */
[data-tag-table] .tagedit-row{display:flex;flex-wrap:nowrap;}
/* Making a tag on Your tags: name, colour and Create tag on one line at one
   height. A select draws 2px taller than an input, so the height is said. */
.tagnew{flex-wrap:nowrap;}
.tagnew .input,.tagnew .btn{height:40px;box-sizing:border-box;}
.tagnew .input{padding-top:0;padding-bottom:0;}
.tagnew .btn{display:inline-flex;align-items:center;flex:none;padding-top:0;padding-bottom:0;}
.tagedit-confirm{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-top:6px;font-size:13px;color:var(--paper);}
.tagedit-confirm[hidden]{display:none;}
.tagdrop-manage{display:block;margin-top:8px;font-size:12.5px;}
.tagfilter{display:flex;align-items:center;gap:8px;flex-wrap:wrap;}
.tagfilter-clear{font-size:12.5px;}
.cattools{gap:10px;align-items:center;flex-wrap:wrap;justify-content:flex-end;}
.tagshowing{margin:-4px 0 14px;color:var(--text);}
.tag-red.tagpill{background:#FBE3E0;color:#5C1A12;border-color:#FBE3E0;}
.tag-red .tagdot,.tagdot.tag-red,.tag-red.tagpill .tagdot{background:#C62828;}
.tag-orange.tagpill{background:#FDEBD8;color:#5A2E07;border-color:#FDEBD8;}
.tag-orange .tagdot,.tagdot.tag-orange,.tag-orange.tagpill .tagdot{background:#D86F00;}
.tag-yellow.tagpill{background:#FBF3C9;color:#463900;border-color:#FBF3C9;}
.tag-yellow .tagdot,.tagdot.tag-yellow,.tag-yellow.tagpill .tagdot{background:#B89400;}
.tag-green.tagpill{background:#DFF1E3;color:#14452A;border-color:#DFF1E3;}
.tag-green .tagdot,.tagdot.tag-green,.tag-green.tagpill .tagdot{background:#2E7D32;}
.tag-blue.tagpill{background:#DDEBFA;color:#123A63;border-color:#DDEBFA;}
.tag-blue .tagdot,.tagdot.tag-blue,.tag-blue.tagpill .tagdot{background:#1E66C4;}
.tag-purple.tagpill{background:#ECE3F7;color:#3A1F5C;border-color:#ECE3F7;}
.tag-purple .tagdot,.tagdot.tag-purple,.tag-purple.tagpill .tagdot{background:#7B3FC4;}
.tag-grey.tagpill{background:#E9EEF0;color:#263238;border-color:#E9EEF0;}
.tag-grey .tagdot,.tagdot.tag-grey,.tag-grey.tagpill .tagdot{background:#6B7C85;}
/* A row the search has hidden stays hidden: the row's own display would
   otherwise beat the hidden attribute, leaving it on screen and focusable. */
.tagdrop-row[hidden],.tagpick-list > li[hidden]{display:none;}

/* ---------- the builder's grid (BIO-104, which tidied BIO-102) ----------
   One grid. The wrappers between it and the builder's parts (the left
   column, the form, the manual panel) take no box of their own, so the
   header, the tabs, the conditions box, the run button and the live result
   are each a cell of it, and the saved datasets beside them line up with
   those cells rather than with a column of their own. One gap, 24px, between
   every pair of boxes, across and down; the tabs sit on their box.
   Stacked below 1400px: header, tabs, conditions, run, live result, saved. */
.buildgrid{display:grid;grid-template-columns:minmax(0,1fr);}
.buildgrid-split{
  --build-gap:24px;
  grid-template-areas:"head" "pre" "tabs" "box" "run" "result" "saved";
  row-gap:0;column-gap:var(--build-gap);
}
.buildgrid-split .buildmain,
.buildgrid-split #cohortform,
.buildgrid-split #manualpanel:not([hidden]){display:contents;}
.buildheader{grid-area:head;min-width:0;}
.buildpre{grid-area:pre;min-width:0;}
.buildgrid-split #cohortform > .qtabs{grid-area:tabs;min-width:0;}
.buildgrid-split #cohortform > .qcard,
.buildgrid-split #manualpanel > .qcard{grid-area:box;min-width:0;margin-bottom:0;}
.buildrun{grid-area:run;min-width:0;margin-top:var(--build-gap);}
.buildgrid-split .buildresult{grid-area:result;min-width:0;margin-top:var(--build-gap);}
.buildgrid-split .buildsaved{grid-area:saved;min-width:0;margin-top:var(--build-gap);}
/* Stacked, the latest five; the rest are a link away under See all. */
.buildgrid-split .savedlist li:nth-child(n+6){display:none;}
@media (min-width:1400px){
  .buildgrid-split{
    grid-template-columns:minmax(0,2fr) minmax(380px,1fr);
    grid-template-areas:"head ." "pre ." "tabs saved" "box saved" "run saved" "result saved";
  }
  /* The saved column takes the rows of the tabs, the box, the run button
     and the live result, and passes them to its heading and its card, so
     the heading sits on the tabs' line and the card runs from the top of
     the conditions box to the foot of the live result whichever tab is
     open. The card adds no height of its own (contain:size): the builder
     sets the height and the list scrolls inside it. */
  .buildgrid-split .buildsaved{margin-top:0;display:grid;grid-template-rows:subgrid;}
  .buildgrid-split .buildsaved-head{grid-row:1;align-self:center;margin-bottom:0;}
  .buildgrid-split .buildsaved-card{grid-row:2 / 5;contain:size;display:flex;flex-direction:column;min-height:0;}
  /* The card scrolls as one, so Your saved queries and the organisation's
     list below it are both reachable (BIO-154). */
  .buildgrid-split .buildsaved-card{overflow-y:auto;}
  .buildgrid-split .buildsaved-card .savedlist{flex:none;}
  .buildgrid-split .savedlist li:nth-child(n+6){display:grid;}
}
.buildsaved-card{background:var(--surface);border:1px solid var(--hairline);border-radius:10px;overflow:hidden;}
.buildsaved-card > .hint{padding:12px 14px;}
/* The live result lays its count and its breakdown side by side once the
   card itself is wide enough, measured on the card rather than the window. */
.buildresult{container-type:inline-size;}
.buildresult-parts{display:grid;grid-template-columns:minmax(0,1fr);column-gap:var(--build-gap,24px);}
@container (min-width:600px){
  .buildresult-parts{grid-template-columns:minmax(0,1fr) minmax(0,1.35fr);}
  .buildresult-breakdown > .breakdownpick:first-child{margin-top:0;}
}

.buildresult{background:var(--surface);border:1px solid var(--hairline);border-radius:10px;padding:18px 20px 16px;}
/* While a new count is on its way the old one stays where it is, quieter,
   so nothing below it moves. */
.buildresult[aria-busy="true"]{opacity:.62;}
.bigcount{display:flex;align-items:baseline;gap:12px;min-height:56px;}
.bigcount-n{font-family:var(--mono);font-size:44px;line-height:56px;font-weight:500;color:var(--paper);letter-spacing:-.02em;font-variant-numeric:tabular-nums;}
.bigcount-say{font-family:var(--label);text-transform:uppercase;letter-spacing:.16em;font-size:13px;color:var(--text);}
.bigcount-of{margin:0 0 8px;}
.sharebar{height:10px;border-radius:5px;background:var(--surface-3);border:1px solid var(--hairline);overflow:hidden;margin:0 0 14px;}
.sharebar-fill{display:block;height:100%;background:var(--brand-teal);}
.condchips{list-style:none;margin:0 0 10px;padding:0;display:flex;flex-wrap:wrap;gap:6px;}
.condchip{font-size:13px;line-height:1.4;padding:3px 10px;border-radius:999px;background:var(--teal-wash);color:var(--paper);border:1px solid var(--hairline);}
.condchips-none{margin:0 0 10px;}
.resultcaption[hidden]{display:none;}
.breakdownpick{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:14px 0 8px;}
.breakdownpick label{font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12px;color:var(--text);}
.js-build .breakdownpick [data-breakdown-apply]{display:none;}
.buildresult .tablecard{margin-bottom:10px;}
.buildresult-source{margin:10px 0 0;}

.buildsaved-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;margin-bottom:8px;}
.savedlist{list-style:none;margin:0;padding:0;}
.savedlist li{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:4px 14px;align-items:baseline;padding:9px 14px;border-top:1px solid var(--hairline-soft);}
.savedlist li:first-child{border-top:none;}
.savedlist-name{overflow-wrap:anywhere;color:var(--paper);}
.savedlist-n{font-variant-numeric:tabular-nums;white-space:nowrap;}
.savedlist-when{grid-column:1 / 3;}
.savedlist li a{grid-column:3;grid-row:1 / 3;align-self:center;}

/* An analysis's title with its tags beside it (BIO-103). They wrap under it
   when the title is long or the column narrow. */
.ahead-titlerow{display:flex;flex-wrap:wrap;align-items:center;gap:6px 16px;}
.ahead-titlerow .analysistitle{min-width:0;}

/* ---------- the Operational View's chart library (BIO-106) ----------
   Shared by report sections and Analytics tiles. Drawn on the server; the
   plot fills its card, and every count and label is text on the panel's
   own inks (--op-text and --op-muted), which meet the floor on --op-panel. */
.opchart{margin:0;display:flex;flex-direction:column;gap:8px;min-width:0;min-height:0;height:100%;color:var(--op-text);}
.opchart-head{display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:6px 12px;}
.opchart-title{margin:0;font-size:13px;font-weight:700;letter-spacing:.02em;color:var(--op-text);}
.opchart-legend{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:4px 10px;}
.opchart-key{background:none;border:0;padding:0;color:var(--op-text);font:inherit;font-size:13px;display:inline-flex;align-items:center;gap:5px;cursor:pointer;}
.opchart-key i{width:10px;height:10px;border-radius:2px;display:inline-block;}
.opchart-key i.opchart-key-t4{border:1px solid var(--op-t4-border);}
.opchart-key[aria-pressed="false"]{text-decoration:line-through;color:var(--op-muted);}
.opchart-key:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opchart-frame{position:relative;flex:1 1 auto;min-height:120px;display:grid;grid-template-columns:auto minmax(0,1fr);grid-template-rows:minmax(0,1fr) 10px auto;column-gap:6px;}
.opchart-y{grid-row:1;grid-column:1;position:relative;font-size:12px;color:var(--op-muted);min-width:22px;}
.opchart-y span{position:absolute;right:0;transform:translateY(50%);font-variant-numeric:tabular-nums;}
.opchart-plot{grid-row:1;grid-column:2;position:relative;min-height:0;}
.opchart-svg{position:absolute;inset:0;width:100%;height:100%;overflow:visible;}
.opchart-grid{stroke:var(--op-line);stroke-width:1;vector-effect:non-scaling-stroke;}
.opchart-mark[data-hidden]{display:none;}
.opchart-hit{fill:transparent;}
.opchart-svg a:focus-visible rect,.opchart-svg a:focus-visible path{stroke:var(--op-accent);stroke-width:2;vector-effect:non-scaling-stroke;}
.opchart-flags{position:absolute;inset:auto 0 -2px 0;height:0;}
.opchart-flag{position:absolute;bottom:0;width:8px;height:8px;margin-left:-4px;transform:rotate(45deg);background:var(--op-alert);border:1px solid var(--op-bg);}
.opchart-flag-strike{background:var(--op-bad);}
.opchart-flag-medevac_launch{background:var(--op-ok);}
.opchart-periods{grid-row:2;grid-column:2;display:flex;}
.opchart-periods a{display:block;height:100%;border-right:1px solid var(--op-bg);background:var(--op-row);}
.opchart-periods a:hover,.opchart-periods a:focus-visible{background:var(--op-accent);outline:none;}
.opchart-x{grid-row:3;grid-column:2;position:relative;height:16px;font-size:12px;color:var(--op-muted);}
.opchart-x span{position:absolute;transform:translateX(-50%);white-space:nowrap;font-variant-numeric:tabular-nums;}
.opchart-brush{position:absolute;top:0;bottom:0;background:rgba(103,220,211,.18);border:1px solid var(--op-accent);pointer-events:none;}
.opchart-rows{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:4px;overflow:auto;min-height:0;}
.opchart-row{display:grid;grid-template-columns:minmax(80px,34%) minmax(0,1fr) auto;align-items:center;gap:8px;color:var(--op-text);text-decoration:none;font-size:12px;padding:3px 4px;border-radius:5px;}
.opchart-row:hover,.opchart-row:focus-visible{background:var(--op-row);outline:none;}
.opchart-row b{font-variant-numeric:tabular-nums;font-weight:600;}
.opchart-row-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.opchart-track{display:block;height:10px;border-radius:5px;background:var(--op-row);overflow:hidden;}
.opchart-fill{display:block;height:100%;background:var(--op-accent);}
.opchart-fill-beds{background:var(--op-muted);}
.opchart-boxtrack{position:relative;display:block;height:14px;}
.opchart-whisker{position:absolute;top:6px;height:2px;background:var(--op-muted);}
.opchart-box{position:absolute;top:1px;height:12px;background:rgba(103,220,211,.35);border:1px solid var(--op-accent);border-radius:2px;}
.opchart-median{position:absolute;top:0;height:14px;width:2px;margin-left:-1px;background:var(--op-text);}
.opchart-xrow{position:relative;height:14px;margin-left:calc(34% + 8px);margin-right:40px;font-size:12px;color:var(--op-muted);}
.opchart-xrow span{position:absolute;transform:translateX(-50%);}
.opchart-facilities .opchart-row{grid-template-columns:minmax(80px,30%) minmax(60px,1fr) auto minmax(70px,22%);}
.opchart-spark{width:100%;height:26px;}
.opchart-beds{display:flex;flex-direction:column;gap:2px;font-size:12px;color:var(--op-muted);}
.opchart-map{flex:1 1 auto;min-height:120px;position:relative;}
.opchart-mapsvg{position:absolute;inset:0;width:100%;height:100%;}
.opchart-region{fill:var(--op-row);stroke:var(--op-line);stroke-width:1;vector-effect:non-scaling-stroke;}
.opchart-level-1.opchart-region{fill:rgba(255,157,66,.25);}
.opchart-level-2.opchart-region{fill:rgba(255,157,66,.42);}
.opchart-level-3.opchart-region{fill:rgba(255,157,66,.6);}
.opchart-level-4.opchart-region{fill:rgba(255,157,66,.78);}
.opchart-level-5.opchart-region{fill:rgba(255,157,66,.95);}
.opchart-play{display:flex;align-items:center;gap:8px;font-size:12px;}
.opchart-play[hidden]{display:none;}
.opchart-scrub{flex:1 1 auto;}
.opchart-scrub input{width:100%;accent-color:var(--op-accent);}
.opchart-tablewrap{overflow:auto;min-height:0;}
.opchart-matrix{border-collapse:separate;border-spacing:3px;font-size:12px;width:100%;}
.opchart-matrix th{font-weight:600;text-align:left;color:var(--op-muted);font-size:12px;}
.opchart-matrix th a{color:var(--op-text);text-decoration:none;display:inline-flex;align-items:center;gap:5px;}
.opchart-matrix th a i{width:9px;height:9px;border-radius:2px;display:inline-block;}
.opchart-cell a{display:block;text-align:center;padding:4px 2px;border-radius:4px;color:var(--op-text);text-decoration:none;font-variant-numeric:tabular-nums;background:var(--op-row);}
.opchart-cell.opchart-level-1 a{background:#1E3A40;}
.opchart-cell.opchart-level-2 a{background:#245058;}
.opchart-cell.opchart-level-3 a{background:#2A6670;}
.opchart-cell.opchart-level-4 a{background:#2F7C87;}
.opchart-cell.opchart-level-5 a{background:#33919E;color:#FFFFFF;}
.opchart-cell a:focus-visible,.opchart-matrix th a:focus-visible{outline:2px solid var(--op-accent);}
.opchart-cell-total{text-align:right;font-variant-numeric:tabular-nums;color:var(--op-muted);}
.opchart-strip{display:grid;grid-template-columns:minmax(70px,24%) minmax(0,1fr);align-items:center;gap:8px;font-size:12px;}
.opchart-strip-name small{display:block;color:var(--op-muted);font-size:12px;}
.opchart-striptrack{position:relative;height:18px;border-radius:4px;background:var(--op-row);}
.opchart-band{position:absolute;top:0;bottom:0;background:rgba(127,239,200,.12);}
.opchart-line{position:absolute;top:0;bottom:0;width:1px;background:var(--op-muted);}
.opchart-sos{position:absolute;top:3px;width:4px;height:12px;margin-left:-2px;background:var(--op-sos);border-radius:1px;}
.opchart-sos-cleared{background:var(--op-good);}
.opchart-dot{position:absolute;top:5px;width:8px;height:8px;margin-left:-4px;border-radius:50%;background:var(--op-good);}
.opchart-dot-out{background:var(--op-alert);box-shadow:0 0 0 2px var(--op-bg);}
.opchart-dot:focus-visible,.opchart-sos:focus-visible,.opchart-flag:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opchart-summary{margin:0;font-size:12px;color:var(--op-muted);}
.opchart-about{font-size:12px;color:var(--op-muted);}
.opchart-about summary{cursor:pointer;color:var(--op-text);}
.opchart-about p{margin:4px 0 0;}
.opchart-empty{margin:0;font-size:12px;color:var(--op-muted);}

/* ---------- Analytics tiles and the add chart dialog (BIO-107) ---------- */
.optile{position:relative;display:flex;flex-direction:column;min-width:0;}
.optile-body{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;}
.optile-body > h2,.optile-body .opchart-head{padding-right:64px;}
.optile-bar{position:absolute;top:8px;right:8px;display:flex;gap:4px;z-index:3;}
.optile-handle,.optile-menu > summary{
  background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;
  width:28px;height:24px;display:inline-flex;align-items:center;justify-content:center;font-size:12px;cursor:pointer;
  list-style:none;padding:0;
}
.optile-handle{cursor:grab;letter-spacing:-2px;}
.optile-menu > summary::-webkit-details-marker{display:none;}
.optile-handle:focus-visible,.optile-menu > summary:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.optile-menu{position:relative;}
.optile-menu-body{
  position:absolute;right:0;top:calc(100% + 4px);min-width:200px;display:flex;flex-direction:column;
  background:var(--op-panel);border:1px solid var(--op-line);border-radius:8px;padding:4px;box-shadow:0 10px 24px rgba(0,0,0,.35);
}
.optile-menu-body form{margin:0;}
.optile-menu-item{
  display:block;width:100%;text-align:left;background:none;border:0;color:var(--op-text);
  font:inherit;font-size:12.5px;padding:7px 10px;border-radius:5px;text-decoration:none;cursor:pointer;
}
.optile-menu-item:hover,.optile-menu-item:focus-visible{background:var(--op-row);outline:none;}
.optile-dragging{opacity:.5;}
.optile-add{border:2px dashed var(--op-line);border-radius:9px;background:transparent;}
.optile-addlink{
  flex:1 1 auto;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;
  color:var(--op-muted);text-decoration:none;font-size:13px;border-radius:7px;
}
.optile-addlink:hover,.optile-addlink:focus-visible{color:var(--op-text);background:rgba(103,220,211,.06);outline:none;}
.optile-plus{font-size:40px;line-height:1;font-weight:300;}
.optile-addlink small{font-size:12px;}
.opanalytics-cross,.opanalytics-undo{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:10px 16px 0;font-size:12.5px;}
.opanalytics-undo[hidden]{display:none;}
.opanalytics-default{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px;margin:0 16px 16px;font-size:12px;}
.opmuted{color:var(--op-muted);}
.opcrosschip{background:var(--op-row);border:1px solid var(--op-line);border-radius:999px;padding:2px 9px;}
/* The platform's own table heads are light; inside a chart they are the
   view's, or the mechanism names read pale on white (measured, BIO-107). */
.opchart-matrix th,.opchart-matrix td{background:transparent;border-bottom:0;padding:2px;text-transform:none;letter-spacing:0;}
.opchart-matrix thead th{color:var(--op-muted);font-family:inherit;font-size:12px;text-align:center;}
.opchart-matrix tbody th{font-family:inherit;font-size:12px;}
.opchartdialog{color:var(--op-text);}
.opchartdialog-inline{margin:12px 16px 0;background:var(--op-panel);border:1px solid var(--op-line);border-radius:9px;padding:14px 16px;}
.opchartdialog-modal{
  width:min(1640px,96vw);max-height:94vh;overflow:auto;background:var(--op-panel);color:var(--op-text);
  border:1px solid var(--op-line);border-radius:12px;padding:16px 18px;
}
.opchartdialog-modal::backdrop{background:rgba(0,0,0,.55);}
.opchartdialog-head{display:flex;justify-content:space-between;align-items:center;gap:12px;}
.opchartdialog-head h2{margin:0;font-size:16px;color:var(--op-text);}
/* Fields beside the preview where both fit at the preview's real size; where
   they do not, the preview goes beneath, still at its size up to the width. */
.opchartdialog-grid{display:flex;flex-wrap:wrap;gap:18px;align-items:flex-start;}
.opchartdialog-grid > .opchartdialog-fields{flex:1 1 360px;}
.opchartdialog-grid > .opchartdialog-preview{flex:0 0 auto;}
.opchartdialog-fields{display:flex;flex-direction:column;gap:12px;min-width:0;}
.opchartdialog fieldset{border:1px solid var(--op-line);border-radius:8px;padding:8px 10px;margin:0;display:flex;flex-direction:column;gap:6px;}
.opchartdialog legend{font-size:13px;letter-spacing:.1em;text-transform:uppercase;color:var(--op-muted);font-weight:700;padding:0 4px;}
.opchartpick{display:grid;grid-template-columns:auto 44px minmax(0,1fr);align-items:center;gap:8px;font-size:12.5px;cursor:pointer;padding:3px;border-radius:6px;}
.opchartpick:hover{background:var(--op-row);}
.opchartpick small{display:block;color:var(--op-muted);}
.opchartthumb{width:44px;height:26px;fill:var(--op-accent);stroke:var(--op-accent);stroke-width:1.5;}
.opchartdialog-soon-title{margin:6px 0 0;font-size:12px;color:var(--op-muted);text-transform:uppercase;letter-spacing:.08em;}
.opchartdialog-soon{margin:0;padding-left:16px;font-size:12px;color:var(--op-muted);}
.opchartdialog-soon b{color:var(--op-text);font-weight:600;}
.opradio{font-size:12.5px;display:flex;align-items:center;gap:6px;}
.opchartdialog-own{display:flex;flex-direction:column;gap:10px;}
.opchartdialog-own .optime-window{max-width:220px;}
.opchartdialog-own.opchartdialog-off{opacity:.45;}
.opchartdialog-own select[multiple]{min-height:62px;}
.opchartdialog-query{width:100%;}
.opchartdialog-sub{margin:4px 0;font-size:12px;color:var(--op-muted);}
.opchartdialog-qrow{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr) minmax(0,1.4fr);gap:6px;margin-bottom:4px;}
.opchartdialog-qrow select,.opchartdialog-qrow input{width:100%;background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;padding:5px 7px;font:inherit;font-size:12px;}
/* The preview is the tile at its size on the page (BIO-111): one grid cell,
   measured by opanalytics.js into --op-tile-w and --op-tile-h, or two by two. */
.opchartdialog-preview{position:sticky;top:0;width:var(--op-tile-w,460px);max-width:100%;}
.opchartdialog-preview:has(.optile-large){width:calc(var(--op-tile-w,460px) * 2 + 12px);}
.optile-preview{height:var(--op-tile-h,320px);}
.opchartdialog-preview .optile-large{height:calc(var(--op-tile-h,320px) * 2 + 12px);}
.opchartdialog-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:12px;}
.opbtn-primary{background:var(--op-accent);color:var(--op-bg);border-color:var(--op-accent);}
.opbtn-primary:hover{color:var(--op-bg);}
.opbtn[disabled]{opacity:.5;cursor:not-allowed;}

/* ---------- Reports (BIO-108) ---------- */
.opreports{padding:12px 16px 16px;display:flex;flex-direction:column;gap:12px;color:var(--op-text);}
.opreports-head{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:12px;}
.opreports-head > div:first-child{flex:1 1 360px;}
.opreports-new{margin-left:auto;display:flex;flex-wrap:wrap;gap:8px;}
.opreports-title{margin:0;font-size:18px;color:var(--op-text);}
.opreports-find{display:flex;flex-direction:column;gap:10px;}
/* Cards at least 340px wide and never more than four to a row. */
.opreportgrid{list-style:none;margin:0;padding:0;display:grid;gap:12px;
  grid-template-columns:repeat(auto-fill,minmax(min(100%,max(340px,calc((100% - 36px) / 4))),1fr));}
.opreportcard{background:var(--op-panel);border:1px solid var(--op-line);border-radius:9px;padding:12px 14px;display:flex;flex-direction:column;gap:8px;min-width:0;}
.opreportcard-top{display:flex;justify-content:space-between;align-items:baseline;gap:8px;}
.opreportcard h3{margin:0;font-size:14px;}
.opreportcard h3 a{color:var(--op-text);text-decoration:none;}
.opreportcard h3 a:hover,.opreportcard h3 a:focus-visible{text-decoration:underline;}
.opreportcard-purpose,.opreportcard-meta{margin:0;font-size:12px;}
.opreportchips{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:4px;}
.opreportchips li{font-size:12px;background:var(--op-row);border:1px solid var(--op-line);border-radius:999px;padding:1px 8px;}
.opreportcard-figure{display:grid;grid-template-columns:auto auto minmax(0,1fr);align-items:baseline;gap:6px;}
.opreportcard-figure b{font-size:24px;font-variant-numeric:tabular-nums;}
.opreportcard-figure span{font-size:12px;color:var(--op-muted);}
.opreportcard-spark{width:100%;height:30px;}
.opreportcard-actions{display:flex;flex-wrap:wrap;gap:6px;align-items:center;}
.opreportcard-actions form{margin:0;}
.opbtn-danger{border-color:var(--op-bad);color:var(--op-bad);}
.opbadge{font-size:12px;font-weight:700;letter-spacing:.1em;border-radius:4px;padding:2px 6px;display:inline-flex;align-items:center;gap:5px;}
.opbadge-live{background:rgba(127,239,200,.14);color:var(--op-good);border:1px solid var(--op-good);}
.opbadge-snapshot{background:var(--op-row);color:var(--op-text);border:1px solid var(--op-line);}
.opbadge-window{font-size:12px;color:var(--op-muted);margin-left:6px;}
.opbadge-dot{width:7px;height:7px;border-radius:50%;background:var(--op-good);animation:opbadge-pulse 1.6s ease-in-out infinite;}
@keyframes opbadge-pulse{0%,100%{opacity:1;}50%{opacity:.25;}}
@media (prefers-reduced-motion:reduce){.opbadge-dot{animation:none;}}
.opreport-meta{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin-top:6px;font-size:12px;}
.opreport-share{display:flex;flex-wrap:wrap;align-items:flex-end;gap:8px;}
.opreport-toanalytics{display:flex;gap:6px;align-items:center;}
.opreport-toanalytics select{background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;padding:5px 7px;font:inherit;font-size:12px;}
.opreport-sections{display:grid;gap:12px;grid-template-columns:repeat(auto-fill,minmax(min(430px,100%),1fr));grid-auto-rows:auto;}
.opreport-section:not(.opreport-headline){min-height:300px;}
.opreport-headline{grid-column:1 / -1;}
.opreport-section{margin:0;display:flex;flex-direction:column;min-width:0;}
.opreport-section > div{flex:1 1 auto;display:flex;flex-direction:column;min-height:0;}
.opreport-wide{grid-column:1 / -1;}
/* The headline is one slim row of tiles (BIO-111), never a tall panel. */
.opheadline,.opreport-section > .opheadline{display:flex;flex-direction:row;flex-wrap:wrap;gap:8px;flex:0 0 auto;}
.opheadline div{display:flex;flex-direction:column;flex:1 1 110px;background:var(--op-row);border:1px solid var(--op-line);border-radius:7px;padding:6px 10px;}
.opheadline b{font-size:20px;line-height:1.2;font-variant-numeric:tabular-nums;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;}
.opheadline span{font-size:12px;color:var(--op-muted);}
.opreporttable{width:100%;border-collapse:collapse;font-size:12px;}
.opreporttable th,.opreporttable td{background:transparent;color:var(--op-text);text-transform:none;letter-spacing:0;font-family:inherit;
  font-size:12px;padding:5px 6px;border-bottom:1px solid var(--op-line);text-align:left;}
.opreporttable th{color:var(--op-muted);font-weight:600;}
.opreporttable a{color:var(--op-accent);}
.opreport-builder{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:18px;align-items:start;}
@media (max-width:1100px){.opreport-builder{grid-template-columns:minmax(0,1fr);}}
.opreport-span{display:flex;flex-wrap:wrap;gap:8px;}
.opreport-preview{position:sticky;top:0;}
.opreport-preview-title{margin:0 0 6px;font-size:12px;letter-spacing:.1em;text-transform:uppercase;color:var(--op-muted);}
.opreport-sections-preview{grid-template-columns:minmax(0,1fr);}
.opreport-sections-preview .opreport-section:not(.opreport-headline){min-height:280px;}
.opreport-back,.opempty a,.opreports-find .opmuted a{color:var(--op-accent);}
/* The shared Tags control, drawn on the view's own colours here: its light
   theme ghost button read pale on the dark panel (measured, BIO-108). */
.opreports .tagdrop > summary{background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);}

/* ---------- Shared controls (BIO-111) ----------
   The filter picker, the condition rows, the back control, the summary
   sentence and the save bar, used by the report builder, the Analytics
   dialog, an open report and the list (feeds/controls/). Every control in a
   row is one height, --op-control-h. A display rule beats the hidden
   attribute, so inside these it is restated. */
.opview{--op-control-h:32px;}
:where(.opwhich,.opconds,.optime,.oppicker,.opreport-preview,.opsavebar,.opreportview,.opreportlist,.opchartdialog) [hidden]{display:none !important;}
.opback{align-self:flex-start;display:inline-flex;align-items:center;gap:6px;color:var(--op-accent);text-decoration:none;font-size:13px;font-weight:600;border-radius:4px;}
.opback:visited{color:var(--op-accent);}
.opback:hover{text-decoration:underline;text-underline-offset:3px;}
.opback:focus-visible{outline:2px solid var(--op-accent);outline-offset:3px;}
.opsummary{margin:0 0 10px;font-size:13.5px;line-height:1.45;color:var(--op-text);max-width:80ch;}
.oplinkbutton{background:none;border:0;padding:0;font:inherit;font-size:12px;color:var(--op-accent);cursor:pointer;}
.oplinkbutton:hover{text-decoration:underline;text-underline-offset:3px;}
.oplinkbutton:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;border-radius:3px;}
.opbuilder-column{display:flex;flex-direction:column;min-width:0;}
.opbuilder-fields{display:flex;flex-direction:column;gap:12px;}
.opbuilder-fields fieldset{border:1px solid var(--op-line);border-radius:8px;padding:8px 10px 10px;margin:0;display:flex;flex-direction:column;gap:8px;min-width:0;}
.opbuilder-fields legend,.opchartdialog .opwhich legend,.opchartdialog .opconds legend{font-size:13px;letter-spacing:.1em;text-transform:uppercase;color:var(--op-muted);font-weight:700;padding:0 4px;}
.opbuilder-row,.optime-modes,.optime-boxes,.opbuilder-sections{display:flex;flex-wrap:wrap;gap:8px 14px;}
.opbuilder-row .opfield{flex:1 1 220px;}
.optime-boxes .opfield{flex:0 1 220px;}
.opbuilder-column .opfield select:not([multiple]),.opbuilder-column .opfield input,.opconds select,.opconds .input,
.oppicker-button,.opsavebar .opbtn,.opchartdialog .opfield select:not([multiple]),.opchartdialog .opfield input{
  box-sizing:border-box;height:var(--op-control-h);
}
.opsavebar .opbtn{display:inline-flex;align-items:center;}
/* The save bar stays at the foot of the builder column while it scrolls. */
.opsavebar{position:sticky;bottom:0;z-index:20;display:flex;align-items:center;gap:8px;margin-top:12px;padding:10px 0;
  background:var(--op-bg);border-top:1px solid var(--op-line);}
.opsavebar-gap{flex:1 1 auto;}
.opreport-preview-head{display:flex;justify-content:space-between;align-items:baseline;}
.opupdating{font-size:12px;}

/* Which casualties: an even, filling grid of pickers. Four to a row, six in
   a wide column, one on a phone; the last row's pickers widen to fill it, so
   no row is ragged. */
.opwhich{container-type:inline-size;}
.opwhich-head{display:flex;justify-content:space-between;align-items:baseline;gap:10px;font-size:12px;}
.oppickers{display:flex;flex-wrap:wrap;gap:8px;}
.oppickers > *{flex:1 1 calc((100% - 24px) / 4);min-width:0;}
@container (min-width:1000px){.oppickers > *{flex-basis:calc((100% - 40px) / 6);}}
@container (max-width:560px){.oppickers > *{flex-basis:calc((100% - 8px) / 2);}}
@container (max-width:340px){.oppickers > *{flex-basis:100%;}}
.oppicker{position:relative;display:flex;flex-direction:column;gap:4px;min-width:0;}
.oppicker-name{font-size:12px;letter-spacing:.1em;text-transform:uppercase;color:var(--op-muted);font-weight:700;}
.oppicker-native{background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;padding:4px;font:inherit;font-size:12px;width:100%;}
.oppicker-native[multiple]{min-height:150px;}
.oppicker-plain{display:flex;gap:6px;}
.opbtn-small{padding:3px 8px;font-size:12px;}
.oppicker-hidden{display:none !important;}
.oppicker-button{display:flex;align-items:center;justify-content:space-between;gap:6px;width:100%;
  background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;padding:0 9px;
  font:inherit;font-size:12px;cursor:pointer;text-align:left;}
.oppicker-button:hover{border-color:var(--op-accent);}
.oppicker-button:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.oppicker-button[aria-expanded="true"]{border-color:var(--op-accent);}
.oppicker-summary{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0;}
.oppicker-chevron{color:var(--op-muted);font-size:12px;}
.oppicker-panel{position:absolute;top:100%;left:0;z-index:40;margin-top:4px;min-width:100%;width:max-content;max-width:min(340px,86vw);
  background:var(--op-panel);border:1px solid var(--op-line);border-radius:8px;padding:8px;box-shadow:0 10px 24px rgba(0,0,0,.4);
  display:flex;flex-direction:column;gap:6px;}
.oppicker-panel:focus{outline:none;}
.oppicker-search{box-sizing:border-box;height:var(--op-control-h);background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;padding:0 8px;font:inherit;font-size:12px;}
.oppicker-search:focus{outline:2px solid var(--op-accent);outline-offset:1px;}
.oppicker-links{display:flex;gap:12px;}
.oppicker-list{list-style:none;margin:0;padding:0;max-height:280px;overflow:auto;}
.oppicker-list [role=option]{display:flex;align-items:center;gap:8px;padding:5px 6px;border-radius:5px;font-size:12.5px;cursor:pointer;color:var(--op-text);}
.oppicker-list [role=option]:hover,.oppicker-list [role=option]:focus{background:var(--op-row);outline:none;}
.oppicker-list [role=option]:focus-visible{outline:2px solid var(--op-accent);outline-offset:-2px;}
.oppicker-tick{flex:0 0 14px;height:14px;border:1px solid var(--op-muted);border-radius:3px;}
[aria-selected="true"] > .oppicker-tick{background:var(--op-accent);border-color:var(--op-accent);
  box-shadow:inset 0 0 0 2px var(--op-panel);}
.oppicker-dot{flex:0 0 9px;height:9px;border-radius:50%;border:1px solid var(--op-line);}
.oppicker-label{flex:1 1 auto;}
.oppicker-count{color:var(--op-muted);font-variant-numeric:tabular-nums;font-size:12px;}

/* Condition rows: field, condition, value, then + and x. "and" sits on its
   own line between rows. */
.opconds-rows{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px;}
.opcond{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr) minmax(0,1.5fr) auto;gap:6px;align-items:start;}
.opcond[data-beyond-plain]{display:none;}
.opcond-and{grid-column:1 / -1;font-size:12px;color:var(--op-muted);letter-spacing:.08em;text-transform:uppercase;}
.opcond-cell{display:flex;flex-wrap:wrap;align-items:center;gap:6px;min-width:0;}
.opcond-cell > label{flex:1 1 auto;min-width:0;}
.opconds select,.opconds .input{width:100%;background:var(--op-row);border:1px solid var(--op-line);color:var(--op-text);border-radius:6px;padding:0 7px;font:inherit;font-size:12px;}
.opconds select:focus,.opconds .input:focus{outline:2px solid var(--op-accent);outline-offset:1px;}
.opcond-value .input{flex:1 1 80px;min-width:0;}
.opcond-value .oppicker{flex:1 1 100%;}
.opcond-between{font-size:12px;color:var(--op-muted);}
.opcond-note{flex:1 1 100%;font-size:12px;color:var(--op-muted);}
.opcond-tools{display:flex;gap:4px;}
.opcond-add,.opcond-remove{box-sizing:border-box;width:var(--op-control-h);height:var(--op-control-h);background:var(--op-row);border:1px solid var(--op-line);
  color:var(--op-text);border-radius:6px;font:inherit;font-size:16px;line-height:1;cursor:pointer;}
.opcond-add:hover,.opcond-remove:hover{border-color:var(--op-accent);color:var(--op-accent);}
.opcond-add:focus-visible,.opcond-remove:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opcond-error{grid-column:1 / -1;margin:0;font-size:12px;color:var(--op-bad);}
@media (max-width:640px){.opcond{grid-template-columns:minmax(0,1fr) auto;}.opcond-cell{grid-column:1;}}
.opchartpicks{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:2px 8px;}
.opchartdialog-size{flex:0 0 auto;}
.opchartdialog-more{border:1px solid var(--op-line);border-radius:8px;padding:8px 10px;}
.opchartdialog-more > summary{cursor:pointer;font-size:12px;font-weight:600;color:var(--op-text);}
.opchartdialog-more > summary:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opchartdialog-more-body{display:flex;flex-direction:column;gap:8px;margin-top:8px;}
.opchartdialog .opsavebar{background:var(--op-panel);}
.opreport-leftout{margin:0 0 8px;font-size:12px;}
/* In the modal the bar sits on the dialog's own bottom edge, over its
   padding, so nothing scrolls past beneath it. */
.opchartdialog-modal .opsavebar{bottom:-16px;margin-bottom:-16px;padding-bottom:16px;}

/* ---------- An open report and the list (BIO-111) ---------- */
/* One header row: the name, its badge and window, when it was updated; on
   the right Edit, Add to Analytics and More. */
.opreporthead{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:10px 16px;}
.opreporthead-title{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px 10px;min-width:0;}
.opreporthead-when{font-size:12px;font-variant-numeric:tabular-nums;}
.opreporthead-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px;}
.opreporthead-actions .opbtn,.opreporthead-actions select{box-sizing:border-box;height:var(--op-control-h);display:inline-flex;align-items:center;}
.opreport-purpose{margin:-4px 0 0;}
.opmoremenu{position:relative;}
.opmoremenu > summary{list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:4px;}
.opmoremenu > summary::-webkit-details-marker{display:none;}
.opmoremenu > summary:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opmoremenu-body{position:absolute;right:0;top:calc(100% + 4px);z-index:40;min-width:180px;display:flex;flex-direction:column;
  background:var(--op-panel);border:1px solid var(--op-line);border-radius:8px;padding:4px;box-shadow:0 10px 24px rgba(0,0,0,.4);}
.opmoremenu-body form{margin:0;}
.opmoremenu-body a,.opmoremenu-body button{display:block;width:100%;text-align:left;background:none;border:0;border-radius:5px;
  padding:7px 10px;font:inherit;font-size:12.5px;color:var(--op-text);text-decoration:none;cursor:pointer;}
.opmoremenu-body a:hover,.opmoremenu-body button:hover,.opmoremenu-body a:focus-visible,.opmoremenu-body button:focus-visible{background:var(--op-row);outline:none;}
.opmoremenu-body .opmoremenu-danger{color:var(--op-bad);}
.opsharedialog{background:var(--op-panel);color:var(--op-text);border:1px solid var(--op-line);border-radius:10px;padding:16px 18px;width:min(420px,92vw);}
.opsharedialog::backdrop{background:rgba(0,0,0,.55);}
.opsharedialog h3{margin:0 0 10px;font-size:15px;color:var(--op-text);}
.opsharedialog .opreport-share{flex-direction:column;align-items:stretch;}
.opsavebar-inline{display:flex;justify-content:flex-end;gap:8px;margin-top:12px;}
/* Without scripts Share is the same form on the page, under the header. */
.opsharedialog:not([open]){display:none;}
.opsharedialog[open]:not(:modal){position:static;margin:0;}
.opfilterspanel{border:1px solid var(--op-line);border-radius:8px;padding:6px 10px;background:var(--op-panel);}
.opfilterspanel > summary{cursor:pointer;font-size:12.5px;font-weight:600;color:var(--op-text);}
.opfilterspanel > summary:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;border-radius:3px;}
.opfilterspanel-list{margin:8px 0 2px;display:grid;gap:6px;}
.opfilterspanel-list > div{display:grid;grid-template-columns:minmax(120px,max-content) minmax(0,1fr);gap:10px;font-size:12.5px;}
.opfilterspanel-list dt{color:var(--op-muted);}
.opfilterspanel-list dd{margin:0;}
.opfilterspanel-list .oppicker-dot{display:inline-block;width:9px;height:9px;margin-right:4px;vertical-align:baseline;}
.opreport-empty{background:var(--op-panel);border:1px solid var(--op-line);border-radius:9px;padding:12px 14px;font-size:13px;}
.opreport-empty p{margin:0;}
.opreport-empty p + p{margin-top:8px;}
.opreport-widen{display:flex;flex-wrap:wrap;align-items:center;gap:8px;}
.opreport-section.opreport-collapsed{min-height:0;}
.opreport-emptyline{margin:0;font-size:12.5px;}
/* The open report's sections fill each row: the last in a row widens to the
   edge rather than leaving a gap, and a wide section takes a row of its own. */
.opreportview .opreport-sections{display:flex;flex-wrap:wrap;gap:12px;}
.opreportview .opreport-section{flex:1 1 430px;min-width:0;}
.opreportview .opreport-wide,.opreportview .opreport-headline{flex-basis:100%;}
/* A figure that changed in place is lit briefly; not under reduced motion. */
@keyframes opchanged{from{background:color-mix(in srgb,var(--op-accent) 30%,transparent);}to{background:transparent;}}
.opchanged{animation:opchanged 1.6s ease-out;border-radius:3px;}
@media (prefers-reduced-motion:reduce){.opchanged{animation:none;}}

/* The list as a table. */
.oplist-wrap{overflow-x:auto;container-type:inline-size;}
/* Where the table is narrow, the sentence is a line under the name rather
   than a column squeezed to a word; with room it has its own column. */
.oplist .oplist-name .oplist-sentence-under{display:none;margin-top:3px;font-weight:400;font-size:12px;color:var(--op-text);}
@container (max-width:1000px){
  .oplist .oplist-summary{display:none;}
  .oplist .oplist-name .oplist-sentence-under{display:block;}
  .oplist .oplist-name{max-width:0;min-width:170px;}
}
.oplist{width:100%;border-collapse:collapse;font-size:12.5px;}
.oplist th,.oplist td{background:transparent;color:var(--op-text);text-transform:none;letter-spacing:0;font-family:inherit;
  font-size:12.5px;padding:8px 6px;border-bottom:1px solid var(--op-line);text-align:left;vertical-align:middle;}
.oplist thead th{color:var(--op-muted);font-weight:600;font-size:12px;white-space:normal;min-width:40px;}
.oplist thead .oplist-num{text-align:right;white-space:normal;font-family:inherit;}
.oplist thead a{color:var(--op-muted);text-decoration:none;}
.oplist thead a:hover,.oplist thead a:focus-visible{color:var(--op-accent);text-decoration:underline;}
.oplist thead [aria-sort] a{color:var(--op-text);}
.oplist-row{cursor:pointer;}
.oplist-row:hover > *{background:var(--op-row);}
.oplist .oplist-name{min-width:130px;width:auto;}
.oplist-name a{color:var(--op-text);font-weight:600;text-decoration:none;}
.oplist-name a:hover,.oplist-name a:focus-visible{text-decoration:underline;color:var(--op-accent);}
.oplist-name > .opmuted{display:block;font-weight:400;font-size:12px;margin-top:2px;}
.oplist-type{min-width:96px;}
.oplist-type .opbadge-window{display:block;margin:3px 0 0;white-space:normal;}
/* The sentence takes what width is left and is cut to one line there; every
   other column is as narrow as what it holds. */
.oplist td,.oplist th{width:1%;}
.oplist .oplist-summary{width:auto;max-width:0;min-width:100px;}
.oplist-sentence{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.oplist-sentence:hover,.oplist-sentence:focus{white-space:normal;outline:none;}
.oplist-sentence:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.oplist .oplist-num{text-align:right;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-variant-numeric:tabular-nums;white-space:nowrap;}
.oplist-spark svg{display:block;width:64px;height:24px;}
.oplist-when{white-space:nowrap;font-variant-numeric:tabular-nums;font-size:12px;}
.oplist-when .oplist-counted{display:block;font-size:12px;}
.oplist-by{display:block;font-size:12px;}
.oplist-menu .opbtn{padding:4px 9px;}
.oplist-pages{display:flex;align-items:center;gap:10px;margin-top:10px;}
/* On a phone each row is a card. */
@media (max-width:640px){
  .oplist thead{display:none;}
  .oplist,.oplist tbody,.oplist tr,.oplist th,.oplist td{display:block;width:auto;}
  .oplist-row{border:1px solid var(--op-line);border-radius:9px;margin-bottom:10px;padding:6px 4px;background:var(--op-panel);}
  .oplist th,.oplist td{border-bottom:0;padding:4px 10px;}
  .oplist .oplist-num{display:inline-block;text-align:left;}
  .oplist .oplist-num::before{content:attr(data-label) " ";color:var(--op-muted);font-family:inherit;}
  .oplist-summary{max-width:none;}
  .oplist-sentence{white-space:normal;}
}
/* Under an Analytics tile's title, what it shows (BIO-111). */
.opchart-subtitle{margin:2px 0 0;display:flex;align-items:center;gap:5px;font-size:13px;color:var(--op-muted);min-width:0;}
.opchart-subtitle span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.opchart-filtericon{flex:0 0 12px;width:12px;height:12px;color:var(--op-accent);}
.opanalytics-sentence{margin:10px 0 0;}
/* A link inside a note is the note's own colour, underlined: the accent
   on the note's ground read as a blur (measured, BIO-111). */
.opnote .opnote-link{color:var(--op-moderate);text-decoration:underline;text-underline-offset:3px;font-weight:600;}
.opnote .opnote-link:focus-visible{outline:2px solid var(--op-moderate);outline-offset:2px;}

/* ---------- Injuries near a place (BIO-110) ---------- */
.opnearset{display:flex;flex-direction:column;gap:10px;}
.opnearset-centre{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.2fr);gap:12px;align-items:start;}
@media (max-width:900px){.opnearset-centre{grid-template-columns:minmax(0,1fr);}}
.opnearset-fields{display:flex;flex-direction:column;gap:8px;min-width:0;}
.opnearset-hint{margin:0;font-size:13px;}
.opnearset-ring{flex:1 1 70px;min-width:70px;}
.opnearpick{width:100%;height:auto;aspect-ratio:3 / 2;background:var(--op-row);border:1px solid var(--op-line);border-radius:8px;cursor:crosshair;}
.opnearpick-ground{fill:transparent;}
.opnearpick-town{fill:var(--op-muted);opacity:.6;}
.opnearmap-lines{stroke:var(--op-muted);opacity:.7;}
.opnearmap{display:block;width:100%;height:auto;max-height:520px;background:var(--op-row);border-radius:7px;}
.opnearmap-ring{stroke:var(--op-accent);}
.opnearmap a:hover .opnearmap-ring,.opnearmap a:focus .opnearmap-ring{stroke:var(--op-text);}
.opnearmap a:focus-visible{outline:none;}
.opnearmap a:focus-visible .opnearmap-ring{stroke:var(--op-text);stroke-dasharray:4 2;}
.opnearmap-on{stroke:var(--op-text);}
.opnearmap-label{fill:var(--op-text);paint-order:stroke;stroke:var(--op-bg);}
.opnearmap-pin{fill:var(--op-moderate);stroke:var(--op-bg);}
.opnearmap-pinlabel{fill:var(--op-text);font-weight:700;paint-order:stroke;stroke:var(--op-bg);}
.opneartable .opnum{text-align:right;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-variant-numeric:tabular-nums;white-space:nowrap;}
.opneartable thead .opnum{font-family:inherit;}
.opneartable tbody th a{color:var(--op-accent);}
.opneartable .opnear-on > *{background:var(--op-row);}
.opneartable tfoot th,.opneartable tfoot td{border-top:1px solid var(--op-line);}
.opneartable .opnear-unplaced th,.opneartable .opnear-unplaced td{color:var(--op-muted);}
.opnear-placing{display:block;font-size:12px;font-weight:400;}
.opnear-key{display:inline-block;width:9px;height:9px;border-radius:2px;margin-right:5px;vertical-align:baseline;}
.opnear-ringnote,.opnear-units,.opnear-outside{margin:4px 0;font-size:12px;}
.opnear-ringnote a,.opnear-units a{color:var(--op-accent);}
.opnearhead span{display:block;}

/* Admin's two panels side by side (the Casualties split has a handle
   between its columns, and Admin has none). */
.opsplit.opsplit-admin{display:grid;grid-template-columns:minmax(0,1fr) minmax(300px,340px);column-gap:12px;align-items:start;}
/* With the bar (BIO-146): this person's share for the first panel, This feed
   never under 300px, the bar between them. */
.opsplit.opsplit-admin.has-handle{grid-template-columns:minmax(300px,calc(var(--admin-split,.55) * (100% - 34px))) 10px minmax(300px,1fr);}
/* The bars in the Operational View's own colours: a line until hovered,
   focused or dragged, then the accent. */
.adminhandle{align-self:stretch;cursor:col-resize;border-radius:4px;touch-action:none;min-height:60px;
  background:linear-gradient(var(--op-line),var(--op-line)) center/2px 100% no-repeat;}
.adminhandle:hover,.adminhandle.dragging,.adminhandle:focus-visible{background:var(--op-accent);outline:none;}
.suphandle{height:10px;margin:2px 0 0;cursor:row-resize;border-radius:4px;touch-action:none;
  background:linear-gradient(var(--op-line),var(--op-line)) center/100% 2px no-repeat;}
.suphandle:hover,.suphandle.dragging,.suphandle:focus-visible{background:var(--op-accent);outline:none;}
@media (max-width:1180px){.opsplit.opsplit-admin,.opsplit.opsplit-admin.has-handle{grid-template-columns:minmax(0,1fr);}
  .adminhandle{display:none;}}
/* Supplier states: the words carry the meaning, the colour repeats it. */
.supstate{display:inline-block;font-size:12.5px;font-weight:600;border-radius:999px;padding:1px 8px;border:1px solid;white-space:nowrap;}
.supstate-delivering{color:var(--cleared-ink);background:var(--cleared-wash);border-color:var(--cleared);}
.supstate-quiet{color:var(--control-ink);background:var(--control-wash);border-color:var(--control);}
.supstate-off{color:var(--blocked-ink);background:var(--blocked-wash);border-color:var(--blocked);}
/* As specific as `.optable td:nth-child(n)`, which centres two columns, so
   the numbers are right aligned under their headings and the time is left. */
.supplytable td.opnum,.supplytable th.opnum{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap;}
.supplytable td:nth-child(3),.supplytable th:nth-child(3){text-align:left;}
.supplytable th.opnum .thsort{justify-content:flex-end;width:100%;}
.thsort{display:inline-flex;align-items:center;gap:4px;background:none;border:0;padding:0;font:inherit;color:inherit;
  cursor:pointer;text-align:inherit;}
.thsort::after{content:"\2195";font-size:10px;opacity:.6;}
th[aria-sort="ascending"] .thsort::after{content:"\2191";opacity:1;}
th[aria-sort="descending"] .thsort::after{content:"\2193";opacity:1;}
.thsort:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}
.suptotal th,.suptotal td{font-weight:600;border-top:1px solid var(--op-line);color:var(--op-text);}
.opwhy{margin:4px 0 0;}
.opwhy > summary{cursor:pointer;font-size:13px;color:var(--op-text);text-decoration:underline;text-underline-offset:2px;width:max-content;}
.opwhy > summary:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
/* A button in an empty state keeps its own colours: the empty state's link
   colour is the accent, which drew the primary button as a blank block of
   accent (seen 6 October). */
.opempty a.opbtn{color:var(--op-text);}
.opempty a.opbtn-primary,.opempty a.opbtn-primary:hover,.opempty a.opbtn-primary:focus-visible{color:var(--op-bg);}
.opempty a.opbtn:not(.opbtn-primary):hover{color:var(--op-accent);}

/* The message under the code editor, one style on every path (BIO-113). */
.codemessage{margin-top:12px;padding:10px 12px;border-radius:8px;border:1px solid var(--hairline);font-size:13px;}
.codemessage p{margin:0;}
.codemessage p + p{margin-top:6px;}
.codemessage-refused{border-color:var(--blocked);}
.codemessage-found{font-family:var(--mono);font-size:12px;padding:1px 4px;border-radius:4px;background:var(--hairline);}
.codemessage-summary{margin:6px 0 0;padding-left:18px;}
.codewaiting{margin:0 0 10px;}
.codewhat{margin:0 0 10px;font-size:13px;}
.codewhat > summary{cursor:pointer;font-weight:600;}
.codewhat-list{margin:6px 0;padding-left:18px;}
.codewhat-list code{font-family:var(--mono);font-size:12px;}
[data-build-result][data-stale="true"]{opacity:.55;}
.buildstale{font-size:12px;margin:0 0 6px;}

/* The regression card's Table / Chart switch. */
.regswitch{display:inline-flex;border:1px solid var(--hairline);border-radius:8px;overflow:hidden;margin:4px 0 10px;}
.regswitch-opt{padding:5px 14px;font-size:13px;color:var(--paper);text-decoration:none;background:var(--surface);}
.regswitch-opt + .regswitch-opt{border-left:1px solid var(--hairline);}
.regswitch-opt.on{background:var(--teal-wash);font-weight:600;}
.regswitch-opt:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:-2px;}

/* Every feature at once (BIO-122), and the invitation's starting features. */
.feature-bulk{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 8px;}
.invite-feature-rows{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:6px 18px;}
.invite-feature-row{display:flex;align-items:center;justify-content:space-between;gap:10px;}
.invite-feature-row label{font-size:13px;color:var(--paper);}

/* No restrictions (BIO-123): a badge on a catalogue's card, in the house
   error colours, and the three choices on its Restrictions. */
.state.norestrict{border:1px solid var(--blocked);border-radius:6px;padding:4px 10px;background:var(--blocked-wash);}
.restrictions-choice fieldset{border:0;margin:0 0 8px;padding:0;display:flex;flex-direction:column;gap:6px;}
.restrictions-choice .choice{display:flex;gap:8px;align-items:center;font-size:14px;color:var(--paper);}
.restrictions-choice .choice.is-off{color:var(--text);}

/* The invitation form in two columns (BIO-124): label and help at 280px,
   the field beside it, the whole capped; on a phone, labels above. */
/* The whole width of the page (BIO-133), in two columns from about 1200
   wide: the people, where they land and what they see on the left; the
   group, the code, the features and Send on the right, starting level with
   Email addresses. One column below, in the same order. */
.iform-card{max-width:none;}
.iform-cols{display:grid;grid-template-columns:minmax(0,1fr);gap:0 40px;}
.icol{display:flex;flex-direction:column;min-width:0;}
@media (min-width:1200px){
  .iform-cols{grid-template-columns:minmax(0,1fr) minmax(0,1fr);}
  .iform-cols .irow{grid-template-columns:170px minmax(0,1fr);}
}
/* The card's header line, and the card folded to it. */
.invcard-head{display:flex;flex-wrap:wrap;align-items:center;gap:6px 14px;}
.invcard-head h4{margin:0;}
.invcard-sum{margin:0;font-size:13px;color:var(--text);flex:1 1 auto;}
.invcard-toggle{margin-left:auto;}
.invcard-body[hidden]{display:none;}
.sentlist{margin:0;padding-left:18px;font-size:13px;color:var(--text);}
/* The address chips (BIO-133). Each says what it is in words as well as
   colour: not valid, already has an account, already invited, outside. */
.addrfield .addrbox{min-height:44px;resize:vertical;}
.chipbox{display:flex;flex-wrap:wrap;gap:6px;align-items:center;max-width:520px;min-height:42px;padding:5px 8px;
  border:1px solid var(--hairline);border-radius:8px;background:var(--surface);}
.chipbox:focus-within{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}
.chiplist{display:contents;list-style:none;margin:0;padding:0;}
.chipinput{flex:1 1 160px;min-width:120px;border:0;outline:0;font:inherit;font-size:14px;color:var(--paper);
  background:transparent;padding:4px 2px;}
.addrchip{display:inline-flex;align-items:center;flex-wrap:wrap;gap:4px 6px;border:1px solid var(--hairline);
  border-radius:999px;padding:2px 4px 2px 10px;background:var(--surface-2);font-size:13px;color:var(--paper);}
.addrchip-edit{background:none;border:0;padding:0;font:inherit;color:inherit;cursor:text;font-family:var(--mono);
  font-size:12.5px;}
.addrchip-why{font-size:12px;font-weight:600;}
.addrchip-who{font-size:12px;color:var(--brand-teal-lift);}
.addrchip-x{background:none;border:0;width:24px;height:24px;border-radius:50%;font-size:16px;line-height:1;
  color:var(--text);cursor:pointer;}
.addrchip-x:hover{background:var(--surface-3);color:var(--paper);}
.addrchip.is-invalid,.addrchip.is-refused{border-color:var(--blocked);background:var(--blocked-wash);color:var(--blocked-ink);}
.addrchip.is-account,.addrchip.is-invited,.addrchip.is-duplicate{border-color:var(--control);background:var(--control-wash);
  color:var(--control-ink);}
.addrchip.is-outside{border-color:var(--brand-teal-lift);background:var(--teal-wash);color:var(--brand-teal-lift);}
.addr-note:empty{display:none;}
/* Catalogues past five (BIO-133): a box five rows tall, the tools on one
   line, and the count beside them. */
.catpick-wrap.is-many .catpick{max-height:168px;overflow-y:auto;border:1px solid var(--hairline);border-radius:8px;
  padding:8px 10px;background:var(--surface);max-width:520px;}
.catpick-wrap.is-many .catpick-search{width:140px;max-width:220px;flex:1 1 140px;padding:6px 10px;}
.catpick-count{font-size:13px;color:var(--text);}
.catpick-tools [hidden]{display:none;}
.iform{display:flex;flex-direction:column;}
.irow{display:grid;grid-template-columns:280px minmax(0,1fr);gap:6px 24px;padding:14px 0;
  border-top:1px solid var(--hairline-soft);align-items:start;}
.irow[hidden]{display:none;}
.irow-end{border-top:none;padding-bottom:0;}
.ilabel label,.ilabel .ilabel-text{font-weight:600;font-size:14px;color:var(--paper);}
.ihelp{margin:4px 0 0;font-size:13px;line-height:1.5;color:var(--text);}
.ifield{display:flex;flex-direction:column;gap:8px;min-width:0;}
.ifield .input,.ifield .sel{max-width:520px;}
.ichoice{display:flex;align-items:center;gap:8px;font-size:14px;color:var(--paper);}
.iperiod{flex-direction:row;flex-wrap:wrap;align-items:center;gap:8px 12px;}
.iperiod .input{max-width:200px;}
/* Catalogues on the invitation (BIO-130): a tick and its name per line,
   the ticks siblings so two ticked can be told from one, and the table of
   periods shown only then, each row only for a catalogue ticked (the rows'
   own rules are written beside the table, one per catalogue). */
.catpick-tools{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin:0 0 8px;}
.catpick-search{max-width:260px;}
.catpick{display:grid;grid-template-columns:auto minmax(0,1fr);gap:6px 10px;align-items:center;
  max-height:320px;overflow:auto;padding:2px;}
.catpick-name{font-size:14px;color:var(--paper);}
.catpick [hidden]{display:none;}
.catperiods{display:none;margin-top:4px;}
.iform:has(.catpick > input:checked ~ input:checked) .catperiods{display:block;}
.catperiod-row{display:none;}
.catperiod-table .input{max-width:170px;}
.resendform{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:0 0 6px;}
.resendform .sel{width:auto;}
.confirm-cats{margin:0 0 4px;padding-left:18px;}
.ilabel-sub{font-size:12.5px;color:var(--text);}
.irow-end .btn{align-self:flex-start;}
.invite-features .invite-feature-rows{grid-template-columns:repeat(auto-fill,minmax(250px,1fr));}
.invite-features .invite-feature-row label{flex:1 1 auto;min-width:0;}
.invite-features .invite-feature-row .sel{flex:0 0 116px;width:116px;}
.iform-more{margin-top:14px;}
.iform-more summary{cursor:pointer;font-weight:600;color:var(--brand-teal-lift);}
@media (width < 700px){
  .irow{grid-template-columns:minmax(0,1fr);}
}

/* The statistics menus' lines (BIO-125): how many fit, and why the rest do
   not, in the page's text colour, which clears the 7.0 floor. */
.regline{margin:4px 0 0;font-size:13px;line-height:1.45;color:var(--text);}
.regwhy{margin:4px 0 0;font-size:13px;color:var(--text);}
.regwhy summary{cursor:pointer;color:var(--brand-teal-lift);font-weight:600;}
.regwhy ul{margin:6px 0 0;padding-left:18px;}

/* Linear regression chart (BIO-129). Drawn in SVG from coordinates the server
   works out, so it shows with scripts off. The points and the band are
   graphics, told apart by the legend's words as well as their colour; the
   words on the chart are the text tokens. */
.linplot{margin:6px 0 0;}
.linplot svg{display:block;width:100%;height:auto;max-height:420px;}
.lin-grid{stroke:var(--hairline-soft);stroke-width:1;}
.lin-axis{stroke:var(--hairline);stroke-width:1;}
.lin-band{fill:var(--brand-teal);fill-opacity:.14;stroke:none;}
.lin-line{stroke:var(--brand-teal);stroke-width:2.5;stroke-linecap:round;}
.lin-dot{fill-opacity:.62;stroke:var(--surface);stroke-width:.6;}
.lr-c0{fill:var(--brand-teal);background:var(--brand-teal);}
.lr-c1{fill:#C7A15A;background:#C7A15A;}
.lr-c2{fill:#9A6DB0;background:#9A6DB0;}
.lr-c3{fill:#5B7C99;background:#5B7C99;}
.lr-c4{fill:#3E8A8E;background:#3E8A8E;}
.lr-c5{fill:#843321;background:#843321;}
.linchart-words{margin:4px 0 6px;font-size:15px;font-weight:600;color:var(--paper);}
.linchart-assumes{margin:4px 0 0;}
.lin-legend{display:flex;flex-wrap:wrap;gap:6px 14px;align-items:center;margin:8px 0 0;font-size:13px;color:var(--text);}
.lin-legend-cap{font-weight:600;}
.lin-key{display:inline-flex;align-items:center;gap:6px;}
.lin-swatch{display:inline-block;width:10px;height:10px;border-radius:50%;}
.lin-note{margin:8px 0 0;font-size:13px;color:var(--text);}
.lintable{margin:12px 0 0;min-width:0;}
.lintable caption{text-align:left;caption-side:top;margin:0 0 4px;}

/* Regression estimates chart (BIO-116). A forest plot in plain HTML: positions
   along the axis come from apps/screens/forest.py as percentages, so the
   page draws it with no script and no library. Every colour pair here is at
   7.0 or more against the card's surface: the ink for marks and labels, the
   body text for figures and ticks, the teal for the no difference line, and
   the control wash under the stale mark (tests_regression_chart). */
.regchart{margin-top:6px;}
.regchart-mark{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;background:var(--control-wash);
  color:var(--paper);border-radius:8px;padding:8px 12px;margin:0 0 10px;font-size:13px;}
.regchart-mark-text{margin:0;flex:1 1 16rem;}
.regfit-form{margin:0;}
.regchart-sentence{margin:0 0 6px;font-size:15px;line-height:1.45;}
.regchart-head{display:flex;flex-wrap:wrap;gap:2px 0;margin:0 0 10px;font-size:12.5px;color:var(--text);}
.regchart-head span:not(:last-child)::after{content:"\00b7";margin:0 8px;color:var(--text);}
.regchart-hidden{margin:8px 0 0;}
/* The chart's settings are the controls grid (BIO-127). */
.regchart-editor .ctlwrap{flex:1 1 100%;min-width:0;}
.regchart-applyhint{margin:6px 0 0;font-size:13px;color:var(--text);}
.regchart-table{margin:10px 0 0;}
.regchart-table > summary{cursor:pointer;font-size:13px;color:var(--brand-teal-lift);font-weight:600;}

.forest{margin:0;}
.forest-row{display:grid;grid-template-columns:minmax(6.5rem,9rem) minmax(8rem,1fr) auto;
  column-gap:14px;align-items:center;min-height:26px;}
.forest-body .forest-row{border-radius:4px;}
.forest-body .forest-row[tabindex]:hover,
.forest-body .forest-row[tabindex]:focus-visible{background:var(--teal-wash);}
.forest-body .forest-row[tabindex]:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:1px;}
.forest-label{color:var(--paper);font-size:13px;line-height:1.3;padding:3px 0;overflow-wrap:anywhere;}
.forest-heading{font-family:var(--label);font-size:12px;letter-spacing:.08em;text-transform:uppercase;
  font-weight:600;padding-top:8px;}
.forest-reftag{font-style:normal;color:var(--text);font-size:12px;}
.forest-plot{position:relative;align-self:stretch;min-height:26px;}
.forest-null{position:absolute;top:0;bottom:0;width:0;border-left:1.5px dashed var(--brand-teal-lift);}
.forest-ci{position:absolute;top:50%;height:0;border-top:2px solid var(--paper);}
.forest-ci::before,.forest-ci::after{content:"";position:absolute;top:-6px;height:10px;border-left:2px solid var(--paper);}
.forest-ci::before{left:-1px;}
.forest-ci::after{right:-1px;}
.forest-ci.clip-low::before,.forest-ci.clip-high::after{display:none;}
.forest-arrow{position:absolute;top:50%;transform:translate(-50%,-50%);color:var(--paper);font-size:12px;line-height:1;}
.forest-arrow.is-low{transform:translate(0,-50%);}
.forest-arrow.is-high{transform:translate(-100%,-50%);}
.forest-dot{position:absolute;top:50%;width:11px;height:11px;border-radius:50%;transform:translate(-50%,-50%);
  border:2px solid var(--paper);background:var(--surface);box-sizing:border-box;}
.forest-dot.is-filled{background:var(--paper);}
.forest-dot.is-ref{border-radius:1px;transform:translate(-50%,-50%) rotate(45deg);width:10px;height:10px;}
.forest-dot.is-clipped{box-shadow:0 0 0 2px var(--surface),0 0 0 3px var(--paper);}
.forest-dot.is-key{position:relative;display:inline-block;top:auto;transform:none;vertical-align:-1px;margin-right:4px;}
.forest-dot.is-ref.is-key{transform:rotate(45deg);}
.forest-figs{display:grid;grid-template-columns:10ch 14ch 7ch;column-gap:10px;text-align:right;
  font-family:var(--mono);font-size:12px;color:var(--text);font-variant-numeric:tabular-nums;}
.forest-colhead .forest-figs{font-family:var(--label);font-size:12px;letter-spacing:.04em;text-transform:uppercase;white-space:nowrap;}
.forest-refnote{grid-column:1 / span 3;text-align:right;font-family:var(--ui);font-style:italic;}
.forest-ticks{min-height:22px;border-top:1px solid var(--paper);}
.forest-tick{position:absolute;top:4px;transform:translateX(-50%);font-family:var(--mono);font-size:12px;color:var(--text);
  white-space:nowrap;}
.forest-tick::before{content:"";position:absolute;left:50%;top:-4px;height:4px;border-left:1px solid var(--paper);}
.forest-tick.is-first{transform:none;}
.forest-tick.is-first::before{left:0;}
.forest-tick.is-last{transform:translateX(-100%);}
.forest-tick.is-last::before{left:auto;right:0;}
.forest-direction{display:flex;justify-content:space-between;font-size:12px;color:var(--text);min-height:20px;align-items:center;}
.forest-axistitle{margin:4px 0 0;font-size:12.5px;color:var(--paper);text-align:center;}
.forest-key{display:flex;flex-wrap:wrap;gap:6px 18px;margin:10px 0 0;font-size:13px;color:var(--text);}
.forest-keyitem{white-space:nowrap;}
.regchart .sigcard-caveat-text{column-count:auto;max-width:80ch;}

/* The expanded view: larger type and the full figures column, records too. */
.regchart.is-detail .forest-row{grid-template-columns:minmax(9rem,14rem) minmax(12rem,1fr) auto;min-height:32px;}
.regchart.is-detail .forest-label{font-size:15px;}
.regchart.is-detail .forest-figs{grid-template-columns:10ch 16ch 8ch 8ch;font-size:13.5px;}
.regchart.is-detail .forest-refnote{grid-column:1 / span 3;}
.regchart.is-detail .forest-dot{width:13px;height:13px;}
.regchart.is-detail .forest-tick{font-size:13px;}

/* A narrow card: the figures move under the plot rather than squeezing it. */
@container (max-width: 34rem){
  .forest-row{grid-template-columns:minmax(5.5rem,7.5rem) minmax(7rem,1fr);}
  .forest-figs{grid-column:2;justify-self:end;}
}
.regchart:not(.is-detail){container-type:inline-size;}
/* A model chart is an ordinary tile (BIO-129): Expand opens it large in the
   shared dialog, and a narrow tile moves the figures under the plot. */
.regchart-model{margin:8px 0 0;}
.regchart-model > summary{cursor:pointer;font-size:13px;font-weight:600;color:var(--brand-teal-lift);margin-bottom:8px;}
/* End of the regression estimates chart (BIO-116): its colour test reads
   from the chart's opening comment to this one, and no further. */

/* Invitations at other domains (BIO-117). The outside mark and the confirm
   page's facts: ink on the control wash and on the surface, both above 7.0. */
.rt-flag{display:inline-block;margin-top:2px;padding:1px 6px;border-radius:4px;font-size:12px;
  color:var(--paper);background:var(--control-wash);}
.invite-facts{display:grid;grid-template-columns:max-content 1fr;gap:6px 16px;margin:0;}
.invite-facts div{display:contents;}
.invite-facts dt{color:var(--text);font-size:13px;}
.invite-facts dd{margin:0;color:var(--paper);font-size:14px;overflow-wrap:anywhere;}
.invite-warn{color:var(--paper);}
.orgform{margin:10px 0 0;display:flex;flex-wrap:wrap;gap:8px 12px;align-items:flex-end;}
.orgform .field{flex:1 1 18rem;margin:0;}
.orgform fieldset{border:0;padding:0;}
/* Admin, Organisations (BIO-136): a new organisation and each one's details,
   folded, with the same marker as the other folded panels. */
.orgnew > summary,.orgedit > summary{list-style:none;cursor:pointer;display:flex;flex-wrap:wrap;align-items:baseline;
  gap:4px 10px;color:var(--paper);font-size:14px;}
.orgnew > summary::-webkit-details-marker,.orgedit > summary::-webkit-details-marker{display:none;}
.orgnew > summary::after,.orgedit > summary::after{content:"\25be";font-size:10px;color:var(--text);}
.orgnew[open] > summary::after,.orgedit[open] > summary::after{content:"\25b4";}
.orgedit{margin:8px 0 4px;}
.orgedit > summary{font-size:13px;color:var(--text);text-decoration:underline;text-underline-offset:2px;}
.orgdetails .field textarea{min-height:2.6em;resize:vertical;}
.orgstatus{margin-left:6px;}
/* Admin, Organisations (BIO-144). One field block everywhere on the page:
   label, input, then help and error under it. The grid aligns to the start,
   so labels share a line and inputs start on one line however long a help
   line is; every input is one height and Notes starts on its neighbours'
   line. One column below 700px, two to 1600px, four above. */
.ofields{display:grid;grid-template-columns:minmax(0,1fr);gap:16px 18px;align-items:start;margin:0;}
@media (min-width:700px){.ofields{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media (min-width:1600px){.ofields{grid-template-columns:repeat(4,minmax(0,1fr));}}
.ofields-after{margin-top:16px;}
.ofield{display:flex;flex-direction:column;min-width:0;margin:0;}
@media (min-width:700px){.ofield-wide{grid-column:span 2;}}
.ofield-label{display:block;font-family:var(--label);text-transform:uppercase;letter-spacing:.14em;font-size:12px;
  color:var(--muted);margin:0 0 6px;font-weight:600;line-height:1.4;white-space:nowrap;overflow:hidden;
  text-overflow:ellipsis;}
.ofield .input{height:42px;width:100%;}
.ofield textarea.input{height:auto;min-height:42px;line-height:1.5;resize:vertical;}
.ofield .ofield-notes{min-height:84px;}
.ofield .chipbox{max-width:none;min-height:42px;width:100%;}
.ofield-help{margin:6px 0 0;font-size:13px;line-height:1.45;color:var(--text);}
.ofield-error{margin:6px 0 0;font-size:13px;line-height:1.45;color:var(--blocked-ink);font-weight:600;}
.ofield.has-error .input,.ofield.has-error .chipbox{border-color:var(--blocked);}
.ofield.is-saving .input,.ofield.is-saving .chipbox{border-color:var(--brand-teal-lift);}
.ofield-code{font-family:var(--mono);text-transform:uppercase;letter-spacing:.06em;}
.ofield .input[readonly],.ofield .input:disabled{background:var(--surface-2);color:var(--text);}
.orgcode{color:var(--paper);border-color:var(--hairline);font-size:12px;white-space:nowrap;}
.org-js [data-noscript-only]{display:none;}
.orgactions{display:flex;flex-wrap:wrap;gap:10px;justify-content:flex-end;align-items:center;margin-top:16px;}
.orgactions-note{margin:8px 0 0;text-align:right;}
@media (max-width:699px){
  .orgactions{flex-direction:column-reverse;align-items:stretch;}
  .orgactions .btn{width:100%;text-align:center;}
  .orgactions-note{text-align:left;}
}
.orglede{margin-bottom:8px;}
.orgfold{margin:0 0 16px;}
.orgfold > summary{cursor:pointer;font-size:14px;color:var(--paper);text-decoration:underline;
  text-underline-offset:2px;width:max-content;}
.orgfold-body{margin-top:8px;max-width:72ch;}
.orgtoolbar{display:flex;flex-wrap:wrap;gap:12px 14px;align-items:flex-end;margin:0 0 16px;}
.orgtool-search{flex:2 1 260px;}
.orgtool-status,.orgtool-tests{flex:1 1 150px;}
.orgtool-go,.orgtool-new{display:flex;align-items:flex-end;flex:0 0 auto;}
.orgtool-go[hidden]{display:none;}
.orgtool-go .btn,.orgtool-new .btn{height:42px;display:inline-flex;align-items:center;white-space:nowrap;}
.orgtool-count{margin:0;flex:0 0 auto;line-height:42px;font-size:14px;color:var(--text);white-space:nowrap;}
.orgtool-new{margin-left:auto;}
@media (max-width:699px){
  .orgtoolbar{flex-direction:column;align-items:stretch;}
  .orgtool-search,.orgtool-status,.orgtool-tests{flex:0 0 auto;}
  .orgtool-count{line-height:1.4;}
  .orgtool-new{margin-left:0;}
  .orgtool-new .btn{width:100%;justify-content:center;}
}
.orgcard2{margin:0 0 16px;padding:16px 18px;}
.orgcard2.is-operator{border-left:3px solid var(--brand-teal);}
.orgcreate{margin:0 0 16px;padding:16px 18px;border-left:3px solid var(--brand-teal-lift);}
.orgcreate-h{margin:0 0 14px;}
.orghead{display:flex;flex-wrap:wrap;align-items:center;gap:6px 14px;}
.orghead-main{display:flex;flex-wrap:wrap;align-items:center;gap:6px 10px;min-width:0;flex:1 1 320px;}
.orghead-name{margin:0;font-size:17px;}
.orghead-counts{margin:0;font-size:13px;color:var(--text);flex:0 1 auto;}
.orghead-fold{margin:0;}
.orgstate{font-size:12px;font-weight:600;border-radius:999px;padding:2px 9px;border:1px solid;}
.orgstate.is-active{color:var(--cleared-ink);background:var(--cleared-wash);border-color:var(--cleared);}
.orgstate.is-paused{color:var(--control-ink);background:var(--control-wash);border-color:var(--control);}
.orgbody{margin-top:14px;padding-top:14px;border-top:1px solid var(--hairline-soft);}
.orgmsg{margin:0 0 12px;}
.orgmade{margin:12px 0 0;}
.orgsections{display:grid;grid-template-columns:minmax(0,1fr);gap:18px;margin-top:20px;}
@media (min-width:1600px){.orgsections{grid-template-columns:minmax(0,3fr) minmax(0,2fr);}}
.orgsection-head{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px;margin:0 0 8px;}
.orgsection-head h5{margin:0;font-size:14px;}
.orgpop{position:relative;}
.orgpop > summary{list-style:none;cursor:pointer;}
.orgpop > summary::-webkit-details-marker{display:none;}
.orgpop-body{margin-top:8px;padding:12px 14px;border:1px solid var(--hairline);border-radius:8px;
  background:var(--surface);min-width:min(420px,80vw);}
.orgadd[open]{flex-basis:100%;}
.orgadd .orgpop-body .ofield{margin-bottom:12px;}
.orgrow-tools{white-space:nowrap;text-align:right;vertical-align:top;}
.orgrow-tools .orgpop-right{position:absolute;right:0;z-index:5;text-align:left;white-space:normal;}
.iconbtn{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border:1px solid
  var(--hairline);border-radius:8px;background:var(--surface);color:var(--paper);cursor:pointer;font-size:15px;
  line-height:1;vertical-align:middle;}
.iconbtn:hover{background:var(--surface-3);}
.iconbtn:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}
.orgrowset{display:flex;flex-wrap:wrap;gap:6px;align-items:center;}
.orgrowset .input{height:36px;width:auto;min-width:0;flex:1 1 140px;padding:6px 10px;}
.orgtable td{vertical-align:top;}
.orgpeople2{list-style:none;margin:0;padding:0;}
.orgpeople2 li{display:flex;flex-wrap:wrap;justify-content:space-between;gap:2px 12px;padding:6px 0;
  border-bottom:1px solid var(--hairline-soft);font-size:14px;}
.orgpeople2-who{color:var(--paper);min-width:0;overflow-wrap:anywhere;}
.orgmore > summary{cursor:pointer;font-size:13px;color:var(--paper);text-decoration:underline;
  text-underline-offset:2px;width:max-content;margin-top:6px;}
.orgstart{margin:0 0 16px;padding:12px 14px;border:1px solid var(--hairline);border-radius:8px;background:var(--surface-2);}
.orgstart-steps{margin:0;padding-left:20px;display:grid;gap:8px;}
.orgstart-steps li{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:6px 12px;}
/* A step is a row with its button at the right edge, not a line of prose, so
   the reading width (`.main li`, 80ch) does not apply; and a button that wraps
   under its words on a phone keeps to the right edge too (BIO-149). */
.main .orgstart-steps li{max-width:none;}
.orgstart-steps li > .btn{margin-left:auto;}
.orgremove{margin-top:16px;}
.orgempty{margin:0 0 16px;}
.testbadge{display:inline-block;font-size:12px;font-weight:600;color:var(--control-ink);background:var(--control-wash);
  border:1px solid var(--control);border-radius:6px;padding:0 6px;margin-left:4px;vertical-align:middle;}
/* Tables become stacked rows on a phone, each value under its column's name. */
@media (max-width:699px){
  .orgtable table,.orgtable tbody,.orgtable tr,.orgtable td{display:block;width:100%;}
  .orgtable thead{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);}
  .orgtable tr{padding:8px 0;border-bottom:1px solid var(--hairline-soft);}
  .orgtable td{padding:4px 0;border:0;text-align:left;}
  .orgtable td::before{content:attr(data-label);display:block;font-family:var(--label);text-transform:uppercase;
    letter-spacing:.14em;font-size:12px;font-weight:600;color:var(--muted);margin-bottom:2px;}
  .orgrow-tools .orgpop-right{position:static;}
}

/* One organisation (BIO-137): its breadcrumb, the in-page links, the
   overview's facts and the people table's catalogue lines. */
.orgcrumb{font-size:13px;color:var(--text);margin:0 0 6px;}
.orgcrumb a,.orgtabs a,.orgcard h4 a,.orgcard .hint a{color:var(--paper);text-decoration:underline;text-underline-offset:2px;}
.orgtabs{display:flex;flex-wrap:wrap;gap:6px 18px;margin:4px 0 14px;font-size:14px;}
.orgfacts{display:grid;grid-template-columns:max-content minmax(0,1fr);gap:6px 16px;margin:0;font-size:14px;}
.orgfacts div{display:contents;}
.orgfacts dt{color:var(--text);}
.orgfacts dd{margin:0;color:var(--paper);overflow-wrap:anywhere;}
.orgfilter .field{flex:1 1 12rem;}
.orgpeople td{vertical-align:top;}
.orgpeople .orgcat{white-space:normal;margin:0 0 4px;}
.orgpeople .orgcat.is-own{font-weight:600;}
@media (max-width:640px){.orgfacts{grid-template-columns:1fr;}.orgfacts dd{margin-bottom:6px;}}
/* Our organisation's tabs (BIO-139): People, Groups and Features, each its
   own page. The current one is underlined and bold, and says so to a screen
   reader with aria-current. */
.ourtabs{display:flex;flex-wrap:wrap;gap:4px 22px;margin:2px 0 14px;border-bottom:1px solid var(--hairline);}
.ourtabs a{color:var(--text);text-decoration:none;padding:6px 0;font-size:14px;border-bottom:3px solid transparent;
  margin-bottom:-1px;}
.ourtabs a:hover{color:var(--paper);}
.ourtabs a[aria-current="page"]{color:var(--paper);font-weight:600;border-bottom-color:var(--brand-teal-lift);}
.ourtabs a:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}

/* Delete on a saved query's row (BIO-154): a quiet link, to its confirmation. */
.runitem-delete{display:inline-block;margin-top:6px;font-size:12.5px;color:var(--blocked-ink);}
/* Organisation's queries, under Your saved queries in the same card (BIO-154). */
.buildorg{border-top:1px solid var(--hairline);padding:12px 0 4px;}
.buildorg-title{margin:0 14px 8px;}
.buildorg .buildorg-dataset{grid-column:1 / 3;}
.buildorg{flex:none;}
@media (max-width:600px){
  /* On a phone the link goes under the words rather than beside them. */
  .buildorg .savedlist li{grid-template-columns:minmax(0,1fr);}
  .buildorg .savedlist li a,.buildorg .buildorg-dataset,.buildorg .savedlist-when{grid-column:1;grid-row:auto;}
}

/* The AI board (apps/feeds/templates/feeds/_tab_ai.html, BIO-174): a person's
   kept answers as cards, four across at 2560, pinned first and then by day,
   and one opened in a drawer on the right. */
.opai{gap:6px;}
.opai-topbar{align-items:flex-end;}
.opai-title{margin:0 12px 6px 0;flex:none;}
.opai-section{display:flex;flex-direction:column;gap:8px;}
.opai-day{margin:14px 0 2px;font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:var(--op-muted);font-weight:600;}
.opai-board{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;}
@media (max-width: 1800px){.opai-board{grid-template-columns:repeat(3,minmax(0,1fr));}}
@media (max-width: 1300px){.opai-board{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media (max-width: 760px){.opai-board{grid-template-columns:minmax(0,1fr);}}
.opai-card{position:relative;display:flex;flex-direction:column;border:1px solid var(--op-line);border-radius:10px;
  background:var(--op-panel);color:var(--op-text);overflow:hidden;min-width:0;
  transition:transform .15s ease, box-shadow .15s ease, border-color .15s ease;}
.opai-card:hover,.opai-card:focus-within{transform:translateY(-2px);box-shadow:0 8px 20px rgba(0,0,0,.35);border-color:var(--op-accent);}
.opai-card.is-grabbed{box-shadow:0 0 0 2px var(--op-accent),0 10px 24px rgba(0,0,0,.4);opacity:.92;}
.opai-card-open{position:absolute;inset:0;z-index:1;border-radius:10px;}
.opai-card-open:focus-visible{outline:2px solid var(--op-accent);outline-offset:-2px;}
.opai-card-open[aria-current]{box-shadow:inset 0 0 0 2px var(--op-accent);}
.opai-thumb{height:170px;background:var(--op-bg);border-bottom:1px solid var(--op-line);overflow:hidden;}
.opai-card-words{display:flex;flex-direction:column;gap:6px;padding:10px 12px 12px;}
.opai-q{margin:0;font-weight:600;font-size:14px;line-height:1.35;overflow-wrap:anywhere;padding-right:4px;}
.opai-meta{margin:0;display:flex;flex-wrap:wrap;gap:10px;font-size:13px;color:var(--op-muted);font-variant-numeric:tabular-nums;}
.opai-type{color:var(--op-accent);}
.opai-card-tools{position:absolute;top:8px;right:8px;z-index:2;display:flex;gap:4px;}
.opai-tool{width:28px;height:28px;padding:0;border-radius:7px;border:1px solid var(--op-line);
  background:color-mix(in srgb, var(--op-panel) 88%, transparent);color:var(--op-muted);font-size:17px;line-height:1;
  display:inline-flex;align-items:center;justify-content:center;cursor:pointer;}
.opai-tool svg{width:14px;height:14px;fill:currentColor;}
.opai-tool:hover{color:var(--op-text);border-color:var(--op-accent);}
.opai-tool:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opai-tool[aria-pressed="true"]{color:var(--op-accent);border-color:var(--op-accent);}
.opai-grip{cursor:grab;}
.opai-card.is-removed{justify-content:center;border-style:dashed;}
.opai-removed{display:flex;align-items:center;justify-content:center;gap:10px;padding:14px 12px;font-size:14px;color:var(--op-muted);}
.opai-undo{font:inherit;font-weight:600;color:var(--op-accent);background:none;border:0;padding:0;cursor:pointer;}
.opai-undo:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opai-defs{position:absolute;width:0;height:0;overflow:hidden;}
/* An answer's picture: its map frame, shaded and picked out regions, and its
   numbered marks, from the run as kept. */
.opai-map{display:block;width:100%;height:100%;}
.opai-map-context{fill:color-mix(in srgb, var(--op-panel) 70%, var(--op-bg));stroke:var(--op-line);stroke-width:.4;}
.opai-map-nations{fill:color-mix(in srgb, var(--op-row) 80%, var(--op-bg));stroke:var(--op-muted);stroke-width:.5;stroke-opacity:.6;}
.opai-map-shaded{fill:var(--op-t1);fill-opacity:calc(var(--shade, .5) * .8);}
.opai-map-picked{fill:color-mix(in srgb, var(--op-accent) 18%, transparent);stroke:var(--op-accent);}
.opai-map-mark circle{fill:var(--op-accent);fill-opacity:.9;stroke:var(--op-bg);stroke-width:.4;}
.opai-map-mark text{fill:#08171A;font-weight:700;text-anchor:middle;font-family:inherit;}
.opai-chart{width:166%;transform:scale(.6);transform-origin:0 0;padding:10px 14px;box-sizing:border-box;pointer-events:none;}
.opai-chart .opchart{margin:0;}
.opai-figure{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:0 14px;text-align:center;}
.opai-figure b{font-size:40px;font-variant-numeric:tabular-nums;color:var(--op-text);}
.opai-figure span{font-size:13px;color:var(--op-muted);}
.opai-figure-sorry b{color:var(--op-muted);}
.opai-pages{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px;}
.opai-pages a{padding:4px 10px;border-radius:6px;border:1px solid var(--op-line);color:var(--op-text);text-decoration:none;
  font-variant-numeric:tabular-nums;}
.opai-pages a.is-current{background:var(--op-accent);color:var(--op-bg);border-color:var(--op-accent);}
/* The drawer: about 45% of the width, on the right, over the board. */
.opai-drawer{position:fixed;top:0;right:0;bottom:0;z-index:58;width:45vw;min-width:min(560px,100vw);max-width:100vw;
  box-sizing:border-box;display:flex;flex-direction:column;background:var(--op-panel);color:var(--op-text);
  border-left:1.5px solid var(--op-accent);box-shadow:-12px 0 32px rgba(0,0,0,.4);}
.opai-drawer-head{display:flex;align-items:flex-start;gap:12px;padding:18px 20px 4px;}
.opai-drawer-head h2{flex:1;margin:0;}
.opai-drawer-head h2:focus{outline:none;}
.opai-drawer-close{width:32px;height:32px;border-radius:7px;display:inline-flex;align-items:center;justify-content:center;
  color:var(--op-muted);text-decoration:none;font-size:22px;border:1px solid var(--op-line);}
.opai-drawer-close:hover{color:var(--op-text);border-color:var(--op-accent);}
.opai-drawer-close:focus-visible{outline:2px solid var(--op-accent);outline-offset:1px;}
.opai-frozen{margin:0;padding:0 20px 10px;font-size:13px;color:var(--op-muted);}
.opai-drawer-body{flex:1;min-height:0;overflow:auto;padding:4px 20px 24px;display:flex;flex-direction:column;gap:14px;}
.opai-drawer-map{height:min(42vh,520px);border:1px solid var(--op-line);border-radius:8px;overflow:hidden;background:var(--op-bg);flex:none;}
.opai-drawer-chart{max-width:640px;}
.opai-drawer .optray-table th[scope="row"]{text-align:left;font-weight:400;color:var(--op-text);text-transform:none;
  letter-spacing:0;font-size:14px;position:static;background:none;padding:4px 10px;}
.opai-listed{max-height:420px;flex:none;}
.opai-settings code{font-size:12px;}
.opai-drawer-actions{gap:10px;}
.opai-drawer-actions form{margin:0;}
.opai-suggest{margin:0;padding-left:18px;color:var(--op-muted);}
.opai-timeline ol{list-style:none;margin:6px 0 0;padding:0;display:flex;flex-direction:column;gap:4px;}
.opai-timeline li{display:flex;gap:12px;align-items:baseline;padding-left:12px;border-left:2px solid var(--op-line);font-size:14px;}
.opai-timeline li.is-current{border-left-color:var(--op-accent);}
.opai-timeline a{color:var(--op-text);font-variant-numeric:tabular-nums;}
.opai-timeline span{color:var(--op-muted);font-size:13px;}
@media (prefers-reduced-motion: reduce){.opai-card{transition:none;}.opai-card:hover,.opai-card:focus-within{transform:none;}}

/* Follow ups (BIO-175): the question a follow up builds on, in the panel; what
   it changed and the two periods side by side, in the card; a thread on the AI
   board, one card that opens to its follow ups. */
.opask-thread{display:flex;align-items:center;gap:8px;margin:0 0 8px;padding:6px 8px;border:1px solid var(--op-line);
  border-radius:7px;background:var(--op-row);}
.opask-thread[hidden]{display:none;}
.opask-thread-q{flex:1;min-width:0;margin:0;font-size:12px;color:var(--op-muted);overflow-wrap:anywhere;}
.opask-thread-q span{color:var(--op-text);}
.opanswer.is-wide{width:400px;}
.opanswer-changed{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:2px;font-size:13px;}
.opanswer-changed b{font-weight:600;color:var(--op-muted);margin-right:4px;}
.opanswer-was{margin-left:6px;color:var(--op-muted);font-size:12px;}
/* BIO-180: what the answer used, what it kept from before with Remove, and
   Show all on a count of nothing. */
.opanswer-used{border-top:1px solid var(--op-line);padding-top:6px;}
.opanswer-kept{margin:0;font-size:13px;display:flex;flex-wrap:wrap;align-items:center;gap:6px;}
.opanswer-kept .opanswer-btn{font-size:12px;padding:2px 8px;}
.opanswer-widen{align-self:flex-start;}
/* New question is a tab on the border now, `.opanswer-tab` above. */
/* The card's own way to ask (BIO-180): the switch, the box, the limit. */
.opanswer-ask{border-top:1px solid var(--op-line);padding:10px 14px 12px;display:flex;flex-direction:column;gap:6px;
  flex:none;}
.opanswer-ask[hidden],.opanswer-ask-open[hidden],.opanswer-full[hidden],.opanswer-limit[hidden]{display:none;}
.opanswer-ask-open{display:flex;flex-direction:column;gap:5px;}
.opanswer-mode{display:inline-flex;align-self:flex-start;border:1px solid var(--op-line);border-radius:7px;overflow:hidden;}
.opanswer-mode button{font:inherit;font-size:12px;padding:3px 10px;border:0;background:transparent;color:var(--op-muted);
  cursor:pointer;}
.opanswer-mode button[aria-checked="true"]{background:var(--op-row);color:var(--op-text);font-weight:600;}
.opanswer-mode button:disabled{cursor:not-allowed;opacity:.5;}
.opanswer-mode button:focus-visible{outline:2px solid var(--op-accent);outline-offset:-2px;}
.opanswer-limit{margin:0;font-size:12px;color:var(--op-muted);}
.opanswer-full p{margin:0 0 6px;font-size:13px;}
/* Did you mean (BIO-180): centred over the dimmed screen. */
.opclarify{width:min(460px, calc(100vw - 32px));box-sizing:border-box;padding:18px 20px;
  background:var(--op-panel);color:var(--op-text);border:1.5px solid var(--op-line);border-radius:12px;
  box-shadow:0 24px 60px rgba(0,0,0,.55);transition:border-color .3s ease;}
.opclarify[open]{display:flex;flex-direction:column;gap:10px;}
.opclarify::backdrop{background:rgba(4,10,12,.62);}
.opclarify-said{margin:0;font-size:15px;line-height:1.4;}
.opclarify-options{display:flex;flex-direction:column;gap:6px;}
.opclarify-more{min-height:52px;padding:7px 10px;}
.opclarify-actions{display:flex;gap:8px;}
.opask{transition:border-color .3s ease, opacity .3s ease;}
.opask.is-leaving{opacity:0;}
.opanswer.is-closing{opacity:0;}
/* The one place to look (BIO-180): the green border, in the Ai button's
   colour, on exactly one of the assistant's surfaces at a time. Set only by
   setAiFocus in static/js/picture-ask.js; no surface draws it any other way. */
.ai-focus{border-color:var(--op-accent);}
.opanswer-compare{width:100%;border-collapse:collapse;font-size:13px;font-variant-numeric:tabular-nums;}
.opanswer-compare th,.opanswer-compare td{padding:3px 4px;border-bottom:1px solid var(--op-line);text-align:left;font-weight:400;
  font-family:inherit;font-size:13px;text-transform:none;letter-spacing:normal;color:var(--op-text);background:none;}
.opanswer-compare thead th{font-size:12px;color:var(--op-muted);font-weight:600;border-bottom-width:1px;}
.opanswer-compare .opanswer-num{text-align:right;}
.opchart-pair{display:flex;gap:12px;margin:2px 0 0;font-size:12px;color:var(--op-muted);}
.opchart-pair-now::before,.opchart-pair-then::before{content:"";display:inline-block;width:14px;height:0;margin-right:5px;
  vertical-align:middle;border-top:2px solid var(--op-accent);}
.opchart-pair-then::before{border-top:2px dashed var(--op-muted);}
.opai-thread{position:relative;z-index:2;display:flex;flex-direction:column;gap:6px;padding:0 12px 12px;}
.opai-thread-toggle{align-self:flex-start;font:inherit;font-size:13px;color:var(--op-accent);background:none;border:0;
  padding:0;cursor:pointer;}
.opai-thread-toggle:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opai-thread ol{list-style:none;margin:0;padding:0 0 0 10px;border-left:2px solid var(--op-line);display:flex;
  flex-direction:column;gap:4px;}
.opai-thread ol[hidden]{display:none;}
.opai-thread a{color:var(--op-text);font-size:13px;text-decoration:none;}
.opai-thread a:hover,.opai-thread a:focus-visible{text-decoration:underline;}
.opai-thread time{color:var(--op-muted);font-size:12px;margin-right:6px;font-variant-numeric:tabular-nums;}

/* Admin, Assistant tests (BIO-181): read only results of the assistant's
   question bank. */
.asktests h4{margin:24px 0 8px;font-size:14px;color:var(--text);}
.asktests-tiles{display:flex;flex-wrap:wrap;gap:12px;margin:12px 0;}
.asktests-tile{display:flex;flex-direction:column;gap:4px;min-width:240px;padding:12px 16px;border:1px solid var(--hairline);
  border-radius:8px;background:var(--surface);}
.asktests-tile b{font-size:28px;color:var(--text);}
.asktests-tile span{font-size:13px;color:var(--text);}
.asktests-muted{color:var(--muted);}
.asktests-chart{margin:0;max-width:720px;}
.asktests-chart svg{width:100%;height:auto;display:block;}
.asktests-grid{stroke:var(--hairline);stroke-width:1;}
.asktests-axis{fill:var(--muted);font-size:12px;}
.asktests-line{fill:none;stroke-width:2;}
.asktests-line-model{stroke:var(--brand-teal);}
.asktests-line-browser{stroke:var(--control);}
.asktests-chart figcaption{font-size:13px;color:var(--muted);display:flex;align-items:center;gap:6px;}
.asktests-key{display:inline-block;width:14px;height:3px;}
.asktests-key-model{background:var(--brand-teal);}
.asktests-key-browser{background:var(--control);margin-left:10px;}
.asktests-status{font-size:12px;font-weight:600;padding:2px 8px;border-radius:999px;background:var(--hairline-soft);color:var(--text);}
.asktests-pass{background:var(--cleared-wash);color:var(--cleared-ink);}
.asktests-fail{background:var(--blocked-wash);color:var(--blocked-ink);}
.asktests-flaky{background:var(--control-wash);color:var(--control-ink);}
.asktests-why{font-size:12px;color:var(--text);max-width:420px;}
.asktests-shot{width:160px;height:auto;border:1px solid var(--hairline);border-radius:4px;}

/* Query datasets, the AI tab answering (BIO-182). The steps as they happen,
   the field check, the answer and the build offer. The green border is on the
   one place to look, set by static/js/query-ai.js, as on the Operational View. */
:root{--ai-accent:var(--brand-teal);}
.aiwork{display:flex;flex-direction:column;gap:12px;margin:14px 0 0;padding:14px 16px;border:1px solid var(--hairline);
  border-radius:6px;background:var(--surface);transition:border-color .3s ease, box-shadow .3s ease;}
/* The green border is the answer card's, always and only (the Query AI tab,
   23 October): every answer, field choice and no field card carries
   ai-focus from the server. Nothing in the asking area does. */
.qai .aiwork.ai-focus{border-color:var(--ai-accent);box-shadow:0 0 0 1px var(--ai-accent);}
.aisteps{display:flex;flex-wrap:wrap;gap:6px 18px;margin:0;padding:0;list-style:none;font-size:13px;color:var(--muted);}
.aistep{display:flex;align-items:center;gap:6px;}
.aistep-mark{width:10px;height:10px;border-radius:50%;border:1.5px solid var(--hairline);flex:none;}
.aistep.is-done{color:var(--text);}
.aistep.is-done .aistep-mark{background:var(--ai-accent);border-color:var(--ai-accent);}
.aistep.is-active{color:var(--paper);font-weight:600;}
.aistep.is-active .aistep-mark{border-color:var(--ai-accent);animation:aistep-pulse 1s ease-in-out infinite;}
.aistep-note{color:var(--muted);font-weight:400;font-variant-numeric:tabular-nums;}
@keyframes aistep-pulse{50%{background:var(--teal-wash);}}
@media (prefers-reduced-motion: reduce){.aistep.is-active .aistep-mark{animation:none;background:var(--teal-wash);}}
.aicheck{display:flex;flex-direction:column;gap:6px;margin:0;}
.aicheck-row{display:grid;grid-template-columns:132px 1fr;gap:2px 10px;font-size:13px;}
.aicheck-tag{grid-row:span 2;align-self:start;padding:1px 8px;border-radius:999px;font-size:12px;font-weight:600;text-align:center;}
.aicheck-matched .aicheck-tag{background:var(--teal-wash);color:var(--brand-teal-lift);}
.aicheck-partial .aicheck-tag{background:var(--control-wash);color:var(--control-ink);}
.aicheck-missing .aicheck-tag{background:var(--blocked-wash);color:var(--blocked-ink);}
/* The model read the question otherwise than the rules, which stand (BIO-182). */
.aicheck-disagreed .aicheck-tag{background:var(--surface-3);color:var(--text);border:1px dashed var(--hairline);}
.aicheck-phrase{color:var(--paper);font-weight:600;}
.aicheck-says{grid-column:2;color:var(--text);}
.aianswer{display:flex;flex-direction:column;gap:8px;}
.aianswer-line{margin:0;font-size:15px;line-height:1.45;color:var(--paper);}
.aianswer-note{margin:0;font-size:13px;color:var(--text);}
.aianswer-meta{margin:0;font-size:12px;color:var(--muted);}
.aibars{display:flex;flex-direction:column;gap:4px;max-width:520px;}
.aibar{display:grid;grid-template-columns:150px 1fr;gap:10px;align-items:center;font-size:13px;}
.aibar-label{color:var(--text);overflow-wrap:anywhere;}
/* The band holding the mean or the median of a summary drawn as its histogram (#164). */
.aibar-mark{display:inline-block;margin-left:4px;font-size:12px;line-height:1.4;padding:0 5px;border-radius:3px;border:1px solid var(--brand-teal);color:var(--paper);}
.aibar-track{display:flex;align-items:center;gap:6px;min-width:0;}
.aibar-scale{flex:1;min-width:0;}
.aibar-fill{display:block;height:12px;width:var(--share);min-width:2px;background:var(--brand-teal);border-radius:2px;}
/* The count and its share on one line beside the bar, however long the bar. */
.aibar-value{flex:none;white-space:nowrap;font-variant-numeric:tabular-nums;color:var(--paper);}
.aibar-withheld,.aiwithheld{font-size:12px;color:var(--control-ink);background:var(--control-wash);padding:0 6px;border-radius:3px;}
.aitable-wrap{overflow-x:auto;}
.aitable{border-collapse:collapse;font-size:13px;font-variant-numeric:tabular-nums;}
.aitable th,.aitable td{padding:4px 10px;border-bottom:1px solid var(--hairline-soft);text-align:right;}
.aitable th[scope=row],.aitable thead th:first-child{text-align:left;}
.aitable thead th{font-weight:600;color:var(--muted);}
.aifigures{display:flex;flex-wrap:wrap;gap:6px 20px;margin:0;font-size:13px;}
.aifigures dt{color:var(--muted);}
.aifigures dd{margin:0;color:var(--paper);font-weight:600;font-variant-numeric:tabular-nums;}
.aioffers{display:flex;flex-wrap:wrap;gap:6px;margin:0;}
.aibuild{display:flex;flex-direction:column;gap:8px;padding:12px 0 0;border-top:1px solid var(--hairline-soft);}
.aibuild-ask{margin:0;font-weight:600;color:var(--paper);}
.aibuild .btn{align-self:flex-start;}
.aibuild .chips{display:flex;flex-wrap:wrap;gap:6px;margin:0;padding:0;}
.aicheck,.aioffers{padding:0;list-style:none;}
.aioffers li{margin:0;}
/* One card, ask, answer, build (23 October). The first sentence leads with
   its figure, large; one small chart; how it was read; then the actions. */
.aihead{font-size:16px;}
.aihead-n{display:inline-block;margin-right:6px;font-family:var(--label);font-size:34px;font-weight:600;line-height:1;
  color:var(--paper);font-variant-numeric:tabular-nums;vertical-align:-3px;}
.aicheck-held .aicheck-tag{background:var(--blocked-wash);color:var(--blocked-ink);}
.airead{margin:0;font-size:13px;color:var(--text);}
.airead .asklink{margin-left:4px;}
.aiactions{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px 18px;padding:12px 0 0;
  border-top:1px solid var(--hairline-soft);}
.aiactions .aibuild{padding:0;border-top:0;}
/* Stacked bars: a sequential teal ramp, so an ordered field such as severity
   reads from light to dark. Colour is not the only key: each segment names
   itself in its title, and the table below holds every figure. */
.aic-0{background:#A9CFD1;}.aic-1{background:#6FA9AD;}.aic-2{background:#2F8187;}
.aic-3{background:#16686D;}.aic-4{background:#0D464A;}.aic-5{background:#072A2D;}
.aistack{display:flex;flex-direction:column;gap:5px;max-width:560px;}
.aistack-legend{display:flex;flex-wrap:wrap;gap:4px 14px;margin:0 0 4px;padding:0;font-size:12px;color:var(--text);}
.aistack-legend li{display:flex;align-items:center;gap:5px;}
.aistack-key{width:10px;height:10px;border-radius:2px;}
.aistack-row{display:grid;grid-template-columns:110px 1fr auto;gap:10px;align-items:center;font-size:13px;}
.aistack-label{color:var(--text);font-variant-numeric:tabular-nums;}
.aistack-track{display:flex;height:14px;min-width:0;}
.aistack-seg{display:block;height:100%;min-width:1px;}
.aistack-seg + .aistack-seg{box-shadow:inset 1px 0 0 var(--surface);}
.aistack-withheld{font-size:12px;color:var(--control-ink);}
.aitable-more summary{cursor:pointer;font-size:13px;color:var(--brand-teal-lift);}
.aitable-more[open] summary{margin-bottom:6px;}
.ailine{margin:0;max-width:600px;}
.ailine svg{display:block;width:100%;height:auto;overflow:visible;}
.ailine-axis{stroke:var(--hairline);stroke-width:1;}
.ailine-path{fill:none;stroke:var(--brand-teal);stroke-width:2;stroke-linejoin:round;stroke-linecap:round;}
.ailine-dot{fill:var(--brand-teal);}
.ailine-tick{fill:var(--muted);font-size:12px;font-family:var(--ui);}
.airange{display:flex;flex-direction:column;gap:6px;max-width:620px;}
.airange-row{display:grid;grid-template-columns:110px minmax(120px,1fr) auto;gap:10px;align-items:center;font-size:13px;}
.airange-label{color:var(--text);}
.airange-track{position:relative;height:14px;border-bottom:1px solid var(--hairline-soft);}
.airange-span{position:absolute;top:4px;height:6px;min-width:2px;background:var(--teal-wash);border:1px solid var(--brand-teal);
  border-radius:3px;}
.airange-mid{position:absolute;top:0;width:2px;height:14px;margin-left:-1px;background:var(--paper);}
.airange-says{color:var(--text);font-variant-numeric:tabular-nums;white-space:nowrap;}
/* Under the card: the last questions, then the examples. */
.askunder{margin-top:14px;}
/* What the question asks, and how it resolved (26 October): one line at the
   top of every card, the status as a small label in front of it. */
.aiasks{margin:0;font-size:13px;color:var(--text);display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 8px;}
.aistatus{display:inline-block;padding:1px 8px;border-radius:999px;font-size:12px;font-weight:600;}
.aistatus-answered{background:var(--teal-wash);color:var(--brand-teal-lift);}
.aistatus-partial{background:var(--control-wash);color:var(--control-ink);}
.aistatus-not_in_dataset,.aistatus-not_queryable,.aistatus-cannot_infer{background:var(--surface-3);color:var(--paper);}
/* Limits of this answer and related studies (26 October): two short lists
   under the answer, before the actions. */
.aisection{display:flex;flex-direction:column;gap:4px;}
.aisection-h{margin:0;}
.ailimits,.aistudies{display:flex;flex-direction:column;gap:3px;margin:0;padding-left:18px;font-size:13px;color:var(--text);
  list-style:disc;}
.ainearest,.aimissing{display:flex;flex-direction:column;gap:4px;margin:0;padding:0;font-size:13px;color:var(--text);}
.askhistory{margin:0 0 12px;}
.askhistory .plain{margin:0;padding-left:18px;font-size:13px;}
.askhistory a{color:var(--paper);text-decoration:underline;text-underline-offset:2px;}
/* Which field (the host's /plan): a button per candidate, its label and a
   one line reason, then None of these with room to say what was meant. */
.aichoose{display:flex;flex-direction:column;gap:8px;margin-top:4px;}
.aichoose-list{display:flex;flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;}
.aichoose .aichoose-pick{display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;gap:2px;text-align:left;white-space:normal;height:auto;padding:6px 10px;}
.aichoose-label{font-weight:600;}
.aichoose-reason{font-size:12px;color:var(--muted);}
.aichoose-none{display:flex;flex-wrap:wrap;align-items:center;gap:6px;}
.aichoose-none .input{flex:1 1 220px;min-width:0;}
.aichoose-why{flex-basis:100%;font-size:12px;color:var(--muted);}
.asktests-tabs{display:flex;gap:4px;margin:0 0 12px;border-bottom:1px solid var(--hairline);}
.asktests-tabs a{padding:6px 12px;color:var(--text);text-decoration:none;border-bottom:2px solid transparent;}
.asktests-tabs a.is-current{color:var(--paper);font-weight:600;border-bottom-color:var(--brand-teal);}
/* The Questions tab (BIO-183): its filters, its third line and its send bar. */
.asktests-filters{display:flex;flex-wrap:wrap;align-items:flex-end;gap:8px 12px;margin:0 0 16px;}
.asktests-filters label{display:flex;flex-direction:column;gap:2px;font-size:12px;color:var(--muted);}
.asktests-filters label.asktests-check{flex-direction:row;align-items:center;gap:6px;color:var(--text);}
.asktests-line-third{stroke:var(--muted);stroke-dasharray:4 3;}
.asktests-key-third{background:var(--muted);margin-left:10px;}
.asktests-dot-down{fill:var(--brand-teal);}
.asktests-dot-bad{fill:var(--control);}
.asktests-dot-unanswered{fill:var(--muted);}
.asktests-bankbar{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin:16px 0 8px;font-size:13px;}
.asktests-questions td{vertical-align:top;}
.asktests-questions + .pager,.main.asktests .pager{display:flex;gap:12px;align-items:center;margin:12px 0;font-size:13px;}

/* Thumbs up or down on an assistant's answer (BIO-183): top right, out of the
   way, muted until hovered or focused; a thumbs down opens its reasons below. */
.aiwork{position:relative;}
.aifeedback{position:absolute;top:10px;right:12px;z-index:3;display:flex;flex-wrap:wrap;justify-content:flex-end;gap:2px;
  max-width:320px;opacity:.5;transition:opacity .2s ease;}
.opai-drawer .aifeedback{position:static;align-self:flex-end;margin:0 0 4px;}
.aifeedback:hover,.aifeedback:focus-within,.aifeedback[data-feedback-state="down"],
.aifeedback[data-feedback-state="up"]{opacity:1;}
.aifeedback-btn{display:inline-flex;align-items:center;justify-content:center;width:26px;height:26px;padding:0;border:1px solid transparent;
  border-radius:4px;background:transparent;color:var(--muted);cursor:pointer;}
.aifeedback-btn svg{width:14px;height:14px;}
.aifeedback-btn:hover{border-color:var(--hairline);color:var(--paper);}
.aifeedback-btn:focus-visible{outline:2px solid var(--brand-teal);outline-offset:1px;}
.aifeedback-btn[aria-pressed="true"]{color:var(--brand-teal-lift);border-color:var(--brand-teal);background:var(--teal-wash);}
.opanswer .aifeedback-btn{color:var(--op-muted,#9FB3BD);}
.opanswer .aifeedback-btn[aria-pressed="true"]{color:var(--op-accent,#67DCD3);background:transparent;}
.aifeedback-why{flex-basis:100%;display:flex;flex-direction:column;gap:6px;margin-top:4px;padding:10px;width:300px;box-sizing:border-box;
  border:1px solid var(--hairline);border-radius:6px;background:var(--surface);color:var(--text);font-size:12px;text-align:left;}
.aifeedback-why[hidden]{display:none;}
.aifeedback-reasons{display:flex;flex-wrap:wrap;gap:4px 10px;margin:0;padding:0;border:0;}
.aifeedback-reasons legend{padding:0;margin:0 0 4px;font-weight:600;color:var(--paper);}
.aifeedback-comment{display:flex;flex-direction:column;gap:2px;}
.aifeedback-comment textarea{font:inherit;padding:4px 6px;border:1px solid var(--hairline);border-radius:4px;resize:vertical;}
.aifeedback-note{color:var(--muted);}
.aifeedback-why .btn{align-self:flex-start;}
/* In the Query datasets work area the thumbs sit in its flow, top right, so
   an open thumbs down pushes the answer down rather than covering it. */
.aiwork > .aifeedback{position:static;order:-1;align-self:flex-end;margin:-6px -4px -30px 0;}
.aiwork > .aifeedback[data-feedback-state="down"]{margin-bottom:4px;}
.aiwork .aisteps{padding-right:64px;}
.aiwork > .aifeedback .aifeedback-why{width:min(100%, 460px);}
.aiwork > .aifeedback[data-feedback-state="down"]{align-self:stretch;max-width:none;}
.aiwork > .aifeedback[data-feedback-state="down"] .aifeedback-why{width:100%;}

/* The assistant's answer on a tab (the tab aware brief): a summary panel
   above the list, numbered round badges on the rows it picks out, the rest
   dimmed but visible. The badge is the map's answer mark, so 1 on a row is 1
   on the map and in the card. */
.optabanswer{display:flex;flex-direction:column;gap:8px;margin-bottom:12px;border:1px solid var(--op-line, rgba(255,255,255,.12));}
.optabanswer.ai-focus{border-color:var(--op-accent);box-shadow:0 0 0 1px var(--op-accent);}
.optabanswer-head{display:flex;align-items:center;justify-content:space-between;gap:12px;}
.optabanswer-head h2{margin:0;font-size:14px;}
.optabanswer-summary{margin:0;font-size:15px;color:var(--op-text,#E6EEF2);}
.optabanswer-how{margin:0;font-size:13px;color:var(--op-muted,#9FB3BD);}
.optabanswer-bars{display:flex;flex-direction:column;gap:6px;margin:0;padding:0;}
.optabanswer-bars li{display:grid;grid-template-columns:28px minmax(120px,240px) 1fr auto;align-items:center;gap:8px;font-size:13px;color:var(--op-text,#E6EEF2);}
.optabanswer-bar-mark,.opmark{display:inline-flex;align-items:center;justify-content:center;min-width:24px;height:24px;padding:0 6px;border-radius:999px;background:var(--op-accent,#67DCD3);color:var(--op-bg);font-weight:700;font-size:13px;font-variant-numeric:tabular-nums;}
.optabanswer-bar-track{height:10px;border-radius:5px;background:rgba(255,255,255,.08);overflow:hidden;}
.optabanswer-bar{display:block;height:100%;background:var(--op-accent,#67DCD3);}
.optabanswer-bar-value{font-variant-numeric:tabular-nums;font-weight:600;}
.opmark-at-capacity,.opmark-pressure{background:var(--op-critical);}
.opmark-busy{background:var(--op-severe);}
.opmark-normal{background:var(--op-t3);}
/* One point on the map in detail (the tab aware brief, phase 5): over the
   right hand column, where the Ai panel opens, so it never covers the map
   the point is on. The green border is the one place to look. */
.oppoint-host{position:fixed;top:132px;right:16px;z-index:60;width:min(380px,calc(100vw - 32px));max-height:calc(100vh - 148px);overflow:auto;border-radius:10px;box-shadow:0 12px 32px rgba(0,0,0,.45);}
.oppoint-host[hidden]{display:none;}
.oppoint{background:var(--op-panel,#0F1E24);color:var(--op-text,#E6EEF2);border:2px solid var(--op-line,#23383F);border-radius:10px;padding:14px 16px;display:flex;flex-direction:column;gap:10px;font-size:13px;}
.oppoint.ai-focus{border-color:var(--op-accent,#67DCD3);}
.oppoint:focus{outline:none;}
.oppoint:focus-visible{box-shadow:0 0 0 2px var(--op-accent,#67DCD3);}
.oppoint-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;}
.oppoint-head h2{margin:0;font-size:17px;color:var(--op-text,#E6EEF2);text-wrap:balance;}
.oppoint-kind{margin:0 0 2px;font-size:12px;letter-spacing:.06em;text-transform:uppercase;color:var(--op-muted,#9FB3BD);}
.oppoint-at-capacity .oppoint-status,.oppoint-pressure .oppoint-status{color:var(--op-critical);}
.oppoint-busy .oppoint-status{color:var(--op-severe);}
.oppoint-sub{margin:2px 0 0;color:var(--op-muted,#9FB3BD);}
.oppoint-close{background:none;border:0;color:var(--op-text,#E6EEF2);font-size:22px;line-height:1;cursor:pointer;padding:2px 6px;border-radius:6px;}
.oppoint-close:hover,.oppoint-close:focus-visible{background:rgba(255,255,255,.08);outline:2px solid var(--op-accent,#67DCD3);}
.oppoint-figures{display:grid;grid-template-columns:1fr 1fr;gap:8px 14px;margin:0;}
.oppoint-figures div{display:flex;flex-direction:column;gap:1px;}
.oppoint-figures dt{font-size:12px;color:var(--op-muted,#9FB3BD);}
.oppoint-figures dd{margin:0;font-size:15px;font-weight:600;font-variant-numeric:tabular-nums;}
.oppoint h3{margin:4px 0 0;font-weight:600;font-size:12px;letter-spacing:.04em;text-transform:uppercase;color:var(--op-muted,#9FB3BD);}
.oppoint-list,.oppoint-events{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:4px;}
.oppoint-list li{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:8px;}
.oppoint-list li > span:only-of-type{grid-column:1 / 3;}
.oppoint-list b{font-variant-numeric:tabular-nums;}
.oppoint-more{color:var(--op-muted,#9FB3BD);}
.oppoint-events time{color:var(--op-muted,#9FB3BD);font-variant-numeric:tabular-nums;}
.oppoint-trend{margin:0;display:flex;flex-direction:column;gap:4px;}
.oppoint-trend figcaption{font-size:12px;color:var(--op-muted,#9FB3BD);}
.oppoint-bars{display:flex;align-items:flex-end;gap:3px;height:44px;border-bottom:1px solid var(--op-line,#23383F);}
.oppoint-bars span{flex:1;height:max(2px,var(--h));background:var(--op-accent,#67DCD3);border-radius:2px 2px 0 0;opacity:.85;}
.oppoint-note,.oppoint-foot,.oppoint-loading{margin:0;color:var(--op-muted,#9FB3BD);font-size:12px;}
.oppoint-loading{padding:14px 16px;background:var(--op-panel,#0F1E24);border:2px solid var(--op-accent,#67DCD3);border-radius:10px;}
[data-point-kind][tabindex]:focus-visible{outline:2px solid var(--op-accent,#67DCD3);}
/* A ranked answer in the card (the tab aware brief, phase 4): the same badge
   as the map's and the row's, then the name, then the value, paged by four. */
.opask-ranked{display:flex;flex-direction:column;gap:8px;margin:0 0 10px;}
.opask-ranked:focus-visible{outline:2px solid var(--op-accent,#67DCD3);outline-offset:2px;}
.opask-ranked ol{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px;}
.opask-ranked li{display:grid;grid-template-columns:28px 1fr auto;align-items:center;gap:8px;font-size:13px;color:var(--op-text,#E6EEF2);}
.opask-ranked-name{overflow-wrap:anywhere;}
.opask-ranked-value{font-variant-numeric:tabular-nums;font-weight:600;text-align:right;}
.opask-ranked [data-opanswer-page]{align-self:flex-start;}
/* A facility on the map: its number and its percentage side by side in one
   pill, coloured by how full it is with the same colours as the badges. */
.gm-answer-mark .gm-answer-pill{fill:var(--op-accent);stroke:var(--op-bg);stroke-width:1.5;}
.gm-answer-mark .gm-answer-num{fill:var(--op-bg);fill-opacity:.35;}
.gm-answer-mark.gm-answer-at-capacity .gm-answer-pill,.gm-answer-mark.gm-answer-pressure .gm-answer-pill{fill:var(--op-critical);}
.gm-answer-mark.gm-answer-busy .gm-answer-pill{fill:var(--op-severe);}
.gm-answer-mark.gm-answer-normal .gm-answer-pill{fill:var(--op-t3);}
.gm-answer-mark .gm-answer-pill ~ text.gm-answer-note{fill:#08171A;stroke:none;font-weight:700;text-anchor:start;}
.gm-answer-mark.is-selected .gm-answer-pill{stroke:var(--op-text);stroke-width:1.2;}
.oprow.ophl{background:rgba(103,220,211,.10);box-shadow:inset 3px 0 0 var(--op-accent,#67DCD3);}
.oprow.opdim{opacity:.45;}
.oprow.opdim:hover,.oprow.opdim:focus-within{opacity:.85;}
.opair{display:inline-block;margin-left:4px;padding:0 5px;border-radius:3px;font-size:12px;background:rgba(255,255,255,.1);color:var(--op-text,#E6EEF2);}
@media (prefers-reduced-motion:no-preference){.oprow.opdim{transition:opacity .15s ease;}}

/* EVACUATION MOVEMENTS (the evacuation brief, 3 November 2026). View on each
   row and the patient count are links drawn like the stage chips' text:
   accent, no border at rest, the accent border on hover and on keyboard
   focus, and never smaller than 44px to press. */
.opcell-act{width:1%;white-space:nowrap;}
.opview-btn{
  position:relative;display:inline-block;padding:0 8px;border:0;border-radius:4px;
  background:transparent;color:var(--op-accent);font-size:inherit;line-height:inherit;
  font-weight:600;text-decoration:none;
}
/* The hit area, 32px tall, drawn outside the box so the row does not grow. */
.opview-btn::before{content:"";position:absolute;left:0;right:0;top:50%;height:32px;transform:translateY(-50%);}
.opview-btn:hover,.opview-btn:focus-visible{background:var(--op-accent);color:#08171A;}
.opview-btn:focus{outline:none;}
.opview-btn:focus-visible{outline:2px solid var(--op-text);outline-offset:2px;}

/* The movement on the map: what it is, and what cannot be drawn, in words. */
.gm-movement-say{
  position:absolute;left:12px;bottom:12px;z-index:3;max-width:min(440px,70%);
  margin:0;padding:8px 12px;border:1px solid var(--op-accent);border-radius:8px;
  background:var(--op-bg);color:var(--op-text);font-size:12px;line-height:1.45;
  pointer-events:none;
}
.gm-movement-say p{margin:0;}
.gm-movement-say p + p{margin-top:3px;color:var(--op-muted);}
.gm-movement-line{stroke:var(--op-accent);stroke-width:2;stroke-dasharray:6 4;
                  vector-effect:non-scaling-stroke;fill:none;}
/* The assistant's marks centre a number in the disc; a movement's mark
   carries its words beside the disc instead. */
.gm-movement .gm-answer-mark text.gm-answer-note{text-anchor:start;font-weight:600;}
.opview-num{font-variant-numeric:tabular-nums;}
.opmovement{margin-bottom:6px;}

/* Back to Evacuation, full width under the tabs, 44px tall, and one link
   from end to end (the polish brief, 3 November 2026): the arrow, the words
   and the movement all go back. The same gap above as below it. */
.opevacback{display:block;margin:var(--opevacback-gap,8px) 16px;}
.opevacback-link{
  display:flex;align-items:center;gap:14px;min-height:44px;box-sizing:border-box;padding:0 16px;
  border-radius:8px;background:var(--op-row);box-shadow:inset 0 0 0 1px var(--op-line);
  color:var(--op-text);text-decoration:none;cursor:pointer;
}
.opevacback-link,.opevacback-link:hover,.opevacback-link *{text-decoration:none;}
.opevacback-link:hover,.opevacback-link:focus-visible{background:color-mix(in srgb,var(--op-row),#fff 7%);}
.opevacback-link:hover .opevacback-arrow,.opevacback-link:hover .opevacback-label,
.opevacback-link:focus-visible .opevacback-arrow,.opevacback-link:focus-visible .opevacback-label{color:var(--op-accent);}
.opevacback-link:focus{outline:none;}
.opevacback-link:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opevacback-label{font-size:13px;font-weight:600;}
.opevacback-arrow{font-size:16px;line-height:1;}
.opevacback-name{color:var(--op-muted);font-size:12px;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

/* The row just viewed, picked out for a moment on the way back. */
@keyframes opseen{from{background:color-mix(in srgb,var(--op-accent) 28%,transparent);}to{background:transparent;}}
.optable-evac tr.is-seen > td{animation:opseen 2.2s ease-out;}
@media (prefers-reduced-motion: reduce){
  .optable-evac tr.is-seen > td{animation:none;background:color-mix(in srgb,var(--op-accent) 18%,transparent);}
}

/* MEDEVAC 9-LINE REQUESTS on the Evacuation tab (3 November 2026). */
.opreq-tag{display:inline-block;padding:1px 6px;border:1px solid var(--op-accent);border-radius:4px;
  color:var(--op-accent);font-size:12px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;}
.opreq-mgrs-cell{font-variant-numeric:tabular-nums;white-space:nowrap;}
/* A MEDEVAC request's pickup on the map, in line 6's colour. */
.gm-movement .gm-sec-good circle{fill:var(--op-good);}
.gm-movement .gm-sec-warn circle{fill:var(--op-severe);}
.gm-movement .gm-sec-bad circle{fill:var(--op-critical);}
.gm-movement .gm-movement-pickup circle{stroke:var(--op-text);stroke-width:1.5;}
/* A request's casualties, as a ring round the pickup they share a spot with. */
.gm-movement .gm-answer-mark circle.gm-movement-ring{fill:none;stroke:var(--op-accent);stroke-width:2.5;}
/* Inside the text line, so a request's row is the height of any other: the
   tag's border is drawn inside it and the chips take the line's own height. */
.opreq-tag{padding:0 6px;border:0;box-shadow:inset 0 0 0 1px var(--op-accent);line-height:inherit;vertical-align:baseline;}
.opview-btn{z-index:1;}
/* What follows the strip brings a top offset of its own, 6px on the map and
   4px on Casualties, so the strip's own gap below takes it off: 8px seen
   above and below on both. */
.opevacback:has(+ #oplive){margin-bottom:2px;}
.opevacback:has(+ .opgrid){margin-bottom:4px;}

/* The layers panel's foot: Reset to defaults, and what a change did. */
.gmlayer-foot{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:8px;padding-top:8px;
  border-top:1px solid var(--op-line);}
.gmlayer-reset{padding:4px 10px;border:1px solid var(--op-line);border-radius:6px;background:transparent;
  color:var(--op-text);font:inherit;font-size:12px;cursor:pointer;}
.gmlayer-reset:hover,.gmlayer-reset:focus-visible{border-color:var(--op-accent);color:var(--op-accent);}
.gmlayer-said{color:var(--op-good);font-size:12px;min-height:1em;}

/* EVACUATION FOCUS (the polish brief, 3 November 2026): the map opened from a
   movement's View shows that movement and what places it. Every other
   incident, route, movement marker, aircraft and reporting area is hidden;
   facilities and place names are dimmed rather than removed, so the reader
   keeps their bearings, its own origin and destination excepted. A display
   rule and nothing else: the person's saved layers are not touched, and
   Show everything (`show=all`) lifts it. */
.gm-evac-focus :is(.gm-incidents,.gm-assets,.gm-air,.gm-areas,.gm-pulses){display:none !important;}
.gm-evac-focus .gm-routes > a:not(.gm-movement-keep){display:none;}
.gm-evac-focus .gm-facilities > a:not(.gm-movement-keep),
.gm-evac-focus .gm-feedplaces text:not(.gm-movement-keep),
.gm-evac-focus .gm-countrynames,
.gm-evac-focus [data-geomap-detail]{opacity:.3;}
.gm-movement-say .gm-movement-all{pointer-events:auto;margin-left:6px;color:var(--op-accent);font-weight:600;
  text-decoration:none;border-radius:4px;padding:0 4px;}
.gm-movement-say .gm-movement-all:hover,.gm-movement-say .gm-movement-all:focus-visible{background:var(--op-accent);color:#08171A;}
.gm-movement-say{pointer-events:none;}
/* The two swatches in the layers list, drawn like their layers but with
   classes of their own, so nothing counting the map's outline or lines finds
   the list instead. */
.gm-askedkey path{fill:var(--op-accent);fill-opacity:.10;stroke:var(--op-accent);stroke-width:1.6;}
.gm-lineskey path{fill:none;stroke:var(--gm-line);stroke-width:1.4;}

/* THE EVACUATION TABLE'S ORDER (4 November 2026): every heading a link that
   sorts on the server. The arrow keeps its width when it moves, so a heading
   does not shift as the order changes; the line beside the count names the
   default and links back to it. */
.optable-evac .opsortable a{border-radius:4px;}
.optable-evac .opsortable a:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.optable-evac .opsortmark{display:inline-block;min-width:8px;}
.optable-evac th.opnum.opsortable a{flex-direction:row;}
/* Both are right floats, so the gap goes on this one's right: on the left
   they read "first7 movements". */
.opsortsay{margin-right:14px;}
.opsortsay a{color:var(--op-accent);text-decoration:none;}
.opsortsay a:hover,.opsortsay a:focus-visible{text-decoration:underline;}

/* THE EVACUATION DETAIL PANEL (4 November 2026, the signed off design in
   docs/design/operational-view/evac-request-panel/). One row of the table
   open beside it, taking the right half of the table's area; the table keeps
   its own scroll, and its secondary columns step aside while the panel is
   open. Below 900px the panel takes the width and the table steps aside. */
.opsplit.opevac-split{grid-template-columns:minmax(0,1fr) minmax(0,1fr);column-gap:12px;align-items:start;}
.optable-evac.opevac-narrow .opevac-sec,.optable-evac.opevac-narrow td.opcell-mix.opevac-sec,
.optable-evac.opevac-narrow td.opcell-nat{display:none;}
.optable-evac.opevac-narrow td{white-space:normal;}
.optable-evac.opevac-narrow td.opcell-time,.optable-evac.opevac-narrow td.opnum{white-space:nowrap;}
/* The arrow, in View's style: accent text, inverted on hover and keyboard
   focus, a 32px hit area that does not grow the row. It turns to point back
   at the table on the open row. */
.opevac-go{position:relative;display:inline-flex;align-items:center;justify-content:center;width:24px;height:18px;
  border-radius:4px;color:var(--op-accent);text-decoration:none;vertical-align:baseline;z-index:1;}
.opevac-go::before{content:"";position:absolute;inset:-7px -4px;}
.opevac-go:hover,.opevac-go:focus-visible{background:var(--op-accent);color:#08171A;}
.opevac-go:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opevac-chev{display:inline-block;width:7px;height:7px;border-right:2px solid currentColor;border-top:2px solid currentColor;
  transform:rotate(45deg);margin-left:-3px;transition:transform .3s ease;}
.opevac-chev-left,.opevac-open .opevac-go .opevac-chev{transform:rotate(-135deg);margin-left:3px;}
.optable-evac tr.oprow{cursor:pointer;}
.optable-evac tr.opevac-open{background:color-mix(in srgb,var(--op-accent) 14%,transparent);}
.optable-evac tr.opevac-open > td:first-child,.optable-evac tr.opevac-new > td:first-child{box-shadow:inset 3px 0 0 var(--op-accent);}
.opevac-newtag{display:inline-block;margin-right:6px;padding:0 5px;border-radius:3px;background:var(--op-accent);color:#08171A;
  font-size:12px;font-weight:700;letter-spacing:.06em;line-height:16px;animation:opevac-pulse 1.6s ease-in-out 3;}
.opevac-newtag.is-still{animation:none;}
@keyframes opevac-pulse{50%{opacity:.4}}
.opevac-filled > td{animation:opevac-fill 2.4s ease-out 1;}
@keyframes opevac-fill{from{background:color-mix(in srgb,var(--op-accent) 26%,transparent)}}

.opevac-panel{position:sticky;top:8px;display:flex;flex-direction:column;min-width:0;
  max-height:max(360px,calc(100vh - 120px));background:var(--op-panel);border:1px solid var(--op-line);border-radius:8px;overflow:hidden;}
.opevac-panel.is-opening{animation:opevac-in .3s ease-out;}
.opevac-panel.is-stepping .opevac-body{animation:opevac-step .3s ease-out;}
@keyframes opevac-in{from{opacity:0;transform:translateX(24px)}}
@keyframes opevac-step{from{opacity:0;transform:translateX(12px)}}
.opevac-pin{flex:none;border-bottom:1px solid var(--op-line);background:var(--op-panel);}
.opevac-head{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 16px;padding:14px 18px 10px;}
.opevac-pills{display:flex;flex-wrap:wrap;gap:8px;align-items:center;font-size:12px;}
.opevac-pill{padding:1px 8px;border-radius:4px;border:1px solid var(--op-line);color:var(--op-muted);font-size:12px;
  font-weight:600;letter-spacing:.08em;text-transform:uppercase;}
.opevac-pill-new{background:var(--op-accent);border-color:var(--op-accent);color:#08171A;}
.opevac-pill-medevac{border-color:var(--op-accent);color:var(--op-accent);}
.opevac-pill-casevac{border-color:var(--op-severe);color:var(--op-severe);}
.opevac-title{grid-column:1 / -1;margin:6px 0 2px;font-size:22px;font-weight:600;color:var(--op-text);letter-spacing:.01em;}
.opevac-sub{grid-column:1 / -1;display:flex;flex-wrap:wrap;gap:4px 14px;margin:0;color:var(--op-muted);font-size:12.5px;}
.opevac-panel code{font-size:12px;color:var(--op-text);}
.opevac-nav{display:flex;align-items:center;gap:6px;}
.opevac-navbtn{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:4px;
  border:1px solid var(--op-line);color:var(--op-text);text-decoration:none;font-size:18px;}
.opevac-navbtn:hover,.opevac-navbtn:focus-visible{border-color:var(--op-accent);color:var(--op-accent);}
.opevac-navbtn:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opevac-of{min-width:56px;text-align:center;color:var(--op-muted);font-size:12.5px;font-variant-numeric:tabular-nums;}
.opevac-actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:0 18px 12px;}
.opevac-btn{display:inline-flex;align-items:center;height:30px;padding:0 12px;border-radius:4px;border:1px solid var(--op-accent);
  color:var(--op-accent);text-decoration:none;font-weight:600;font-size:13px;}
.opevac-btn:hover,.opevac-btn:focus-visible{background:var(--op-accent);color:#08171A;}
.opevac-btn:focus-visible{outline:2px solid var(--op-accent);outline-offset:2px;}
.opevac-btn-off,.opevac-btn-off:hover{border-color:var(--op-line);background:none;color:var(--op-muted);cursor:not-allowed;}
.opevac-why{color:var(--op-muted);font-size:12.5px;}
.opevac-body.opscroll{max-height:none;flex:1 1 auto;min-height:0;overflow:auto;border-radius:0;
  padding:14px 18px 22px;display:grid;gap:12px;align-content:start;}
.opevac-check{margin:0;padding:10px 12px;border-radius:6px;font-size:13px;line-height:1.45;color:var(--op-text);}
.opevac-check ul{margin:6px 0 0;padding-left:18px;}
.opevac-check-ok{border:1px solid color-mix(in srgb,var(--op-good) 45%,transparent);background:color-mix(in srgb,var(--op-good) 10%,transparent);}
.opevac-check-differ{border:1px solid color-mix(in srgb,var(--op-alert) 55%,transparent);background:color-mix(in srgb,var(--op-alert) 12%,transparent);}
.opevac-check-wait{border:1px dashed var(--op-line);color:var(--op-muted);}
.opevac-check-wait b{color:var(--op-text);}
.opevac-added{margin:0;padding:6px 10px;border-radius:4px;background:color-mix(in srgb,var(--op-accent) 16%,transparent);
  color:var(--op-text);font-size:12.5px;font-weight:600;}
.opevac-pair{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;}
.opevac-pair:empty{display:none;}
.opevac-sec{min-width:0;padding:12px 14px;border:1px solid var(--op-line);border-radius:6px;background:var(--op-row);}
.opevac-sec h4{display:flex;flex-wrap:wrap;align-items:baseline;gap:8px;margin:0 0 8px;font-size:12px;font-weight:700;
  letter-spacing:.12em;text-transform:uppercase;color:var(--op-muted);}
.opevac-sec h4 span{font-weight:500;letter-spacing:.04em;text-transform:none;font-size:12px;}
.opevac-sec h4 .opmixes{margin-left:auto;}
.opevac-big{margin:0;font-size:20px;font-weight:600;letter-spacing:.03em;color:var(--op-text);font-variant-numeric:tabular-nums;}
.opevac-note{margin:2px 0 0;color:var(--op-muted);font-size:12px;}
.opevac-plain{margin:0;color:var(--op-text);}
.opevac-dl{display:grid;grid-template-columns:auto 1fr;gap:4px 14px;margin:8px 0 0;font-size:13px;}
.opevac-dl dt{color:var(--op-muted);}
.opevac-dl dd{margin:0;min-width:0;overflow-wrap:anywhere;color:var(--op-text);}
.opevac-restricted{color:var(--op-muted);font-style:italic;}
.opevac-line1{display:grid;grid-template-columns:minmax(0,1fr) 240px;gap:14px;align-items:start;}
.opevac-map{display:block;width:240px;height:150px;border-radius:5px;background:var(--op-bg);border:1px solid var(--op-line);}
.opevac-map-context{fill:color-mix(in srgb,var(--op-line) 35%,var(--op-bg));stroke:color-mix(in srgb,var(--op-muted) 40%,transparent);stroke-width:.08;}
.opevac-map-land{fill:color-mix(in srgb,var(--op-line) 60%,var(--op-bg));}
.opevac-map-line{fill:none;stroke:var(--op-line);}
.opevac-map-ring{fill:none;stroke:var(--op-critical);stroke-dasharray:.6 .4;opacity:.8;}
.opevac-map-pin{stroke:var(--op-bg);stroke-width:.25;}
.opevac-tone-good{fill:var(--op-good);}.opevac-tone-warn{fill:var(--op-alert);}.opevac-tone-bad{fill:var(--op-bad);}.opevac-tone-plain{fill:var(--op-text);}
.opevac-prec{display:flex;gap:8px;flex-wrap:wrap;}
.opevac-precblock{flex:1;min-width:90px;padding:6px 10px;border-radius:5px;color:var(--op-chip-ink);}
.opevac-precblock b{display:block;font-size:22px;line-height:1.1;}
.opevac-precblock small{font-size:12px;font-weight:600;}
.opevac-zero{border:1px dashed var(--op-line);color:var(--op-muted);}
.opevac-tags{display:flex;flex-wrap:wrap;gap:6px;}
.opevac-tag{padding:2px 8px;border-radius:4px;border:1px solid color-mix(in srgb,var(--op-accent) 60%,transparent);
  background:color-mix(in srgb,var(--op-accent) 10%,transparent);color:var(--op-text);font-size:12.5px;}
.opevac-security{border-left-width:4px;}
.opevac-edge-good{border-left-color:var(--op-good);}.opevac-edge-warn{border-left-color:var(--op-alert);}.opevac-edge-bad{border-left-color:var(--op-bad);}
.opevac-secrow{display:flex;gap:12px;align-items:center;}
.opevac-secbadge{display:inline-grid;place-items:center;width:34px;height:34px;border-radius:6px;font-weight:700;font-size:18px;color:var(--op-chip-ink);}
.opevac-badge-good{background:var(--op-good);}.opevac-badge-warn{background:var(--op-alert);}.opevac-badge-bad{background:var(--op-bad);}
.opevac-zmist{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:8px;}
.opevac-zcard{padding:8px 10px;border:1px solid var(--op-line);border-radius:5px;background:var(--op-bg);}
.opevac-ztitle{display:flex;justify-content:space-between;margin:0;color:var(--op-text);}
.opevac-zcard .opevac-dl dt{color:var(--op-accent);font-weight:700;}
.opevac-cas{width:100%;border-collapse:collapse;font-size:13px;}
.opevac-cas th{position:static;background:none;text-align:left;color:var(--op-muted);font-weight:600;font-size:12px;
  letter-spacing:.08em;text-transform:uppercase;padding:4px 6px;border-bottom:1px solid var(--op-line);}
.opevac-cas td{padding:5px 6px;border-bottom:1px solid var(--op-line);color:var(--op-text);}
.opevac-hist{margin:0;padding:0;list-style:none;display:grid;gap:6px;font-size:13px;}
.opevac-hist li{display:grid;grid-template-columns:auto 1fr;gap:12px;color:var(--op-text);}
.opevac-hist code{color:var(--op-muted);}
@media (max-width:900px){
  .opsplit.opevac-split{grid-template-columns:minmax(0,1fr);}
  .opevac-split > .opcasualties{display:none;}
  .opevac-line1{grid-template-columns:minmax(0,1fr);}
}
@media (prefers-reduced-motion:reduce){
  .opevac-newtag,.opevac-panel.is-opening,.opevac-panel.is-stepping .opevac-body,.opevac-filled > td{animation:none;}
  .opevac-chev{transition:none;}
}

/* ---------- the site-wide AI panel (9 November 2026) ----------
   After the Nightjar prototype's AI panel, in today's tokens. Docked: fixed on
   the right, 480 px, and the page makes room for it (body.aidock), so it never
   covers what you are reading. Full screen: the whole window, the chat history
   on the left and the conversation centred on the right. Below 900 px there is
   no room beside a page, so docked opens over it. */
/* The AI button, as the design's "Nightjar AI" button (9 November 2026), in
   the platform's light mode. Its own tokens, so nothing here is an inline
   colour; the star and edge are the design's #28596A, darker than the
   platform's --brand-teal (#16686D), on purpose.
   Night values, for later only (not built): fill #0F2433; edge gradient
   #2B6B7A, then #6FA3B0 at 55%, then #7E9CC4; halo #2B6B7A at 25% over
   #06121C; star #6FA3B0; label #BAC7D2. */
:root{--ai-fill:#FFFFFF;--ai-teal:#28596A;--ai-edge:#2D72D2;--ai-halo:#E1E8EA;--ai-star:#28596A;
  --ai-label:#0D1B26;--ai-star-hover:var(--brand-teal-lift);--ai-label-hover:#06121C;}
.aibtn{display:inline-flex;align-items:center;gap:8px;height:48px;padding:0 18px 0 14px;border-radius:6px;
  border:1.5px solid transparent;
  background:linear-gradient(var(--ai-fill),var(--ai-fill)) padding-box,
             linear-gradient(135deg,var(--ai-teal),var(--ai-teal) 55%,var(--ai-edge)) border-box;
  box-shadow:0 0 0 3px var(--ai-halo);color:var(--ai-label);font:700 15px/1 var(--ui);cursor:pointer;
  transition:color .16s,box-shadow .16s;}
.aibtn-star{flex:none;width:18px;height:18px;color:var(--ai-star);transition:color .16s;}
.aibtn:hover{color:var(--ai-label-hover);}
.aibtn:hover .aibtn-star{color:var(--ai-star-hover);}
/* Outside the 3px halo, so the ring is never lost in it. */
.aibtn:focus-visible{outline:2px solid var(--ai-teal);outline-offset:5px;}
/* Open: the same look, pressed. No green edge: that is the Operational View's. */
.aibtn[aria-expanded="true"]{box-shadow:0 0 0 3px var(--ai-halo),inset 0 1px 3px rgba(13,27,38,.18);}

.aipanel{position:fixed;top:0;right:0;bottom:0;z-index:70;width:480px;max-width:100%;display:flex;
  background:var(--surface);border-left:1px solid var(--hairline);box-shadow:-14px 0 36px rgba(16,34,42,.10);
  font-family:var(--ui);color:var(--text);}
.aipanel[hidden]{display:none;}
@media (min-width:900px){
  body.aidock{padding-right:480px;}
  body.aidock .stage{max-width:1360px;}
}
body.aifull{overflow:hidden;}
.aipanel.full{left:0;width:auto;border-left:0;box-shadow:none;}
.aicol{display:none;}
.aipanel.full .aicol{display:flex;flex-direction:column;gap:10px;flex:none;width:290px;padding:16px 14px;
  background:var(--surface-2);border-right:1px solid var(--hairline);overflow-y:auto;}
.aicol-new{text-align:center;}
.aicol-search{height:36px;padding:0 10px;border:1px solid var(--hairline);border-radius:8px;background:var(--surface);
  font:14px var(--ui);color:var(--text);}
.aicol-search:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:1px;}
.aicol-list{display:flex;flex-direction:column;gap:2px;}
.aicol-group{margin:12px 4px 4px;font:600 12px/1 var(--label);letter-spacing:.12em;text-transform:uppercase;color:var(--muted);}
.aicol-row{display:flex;align-items:center;gap:4px;border-radius:7px;}
.aicol-row.is-current{background:var(--teal-wash);}
.aicol-open{flex:1;min-width:0;text-align:left;padding:8px 8px;border:0;background:none;border-radius:7px;cursor:pointer;
  font:14px/1.3 var(--ui);color:var(--text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.aicol-open:hover{background:var(--surface-3);}
.aicol-del{flex:none;width:28px;height:28px;border:0;background:none;border-radius:6px;color:var(--muted);cursor:pointer;}
.aicol-del:hover{background:var(--blocked-wash);color:var(--blocked-ink);}
.aicol-open:focus-visible,.aicol-del:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:-2px;}
.aicol-empty{margin:8px 4px;font-size:13px;color:var(--muted);}

.aimain{flex:1;min-width:0;display:flex;flex-direction:column;}
.aihead{flex:none;display:flex;align-items:center;gap:8px;height:58px;padding:0 10px 0 16px;border-bottom:1px solid var(--hairline);}
.aihead-mark,.aimsg-mark{flex:none;display:inline-grid;place-items:center;width:28px;height:28px;border-radius:50%;
  background:var(--teal-wash);color:var(--brand-teal-lift);font:700 11px/1 var(--ui);letter-spacing:.04em;}
.aihead-title{margin:0;font-size:16px;font-weight:600;color:var(--paper);}
/* The name over its status, as Sophia's panels put them (issue #171), so  */
/* "Ready" is never cut off beside New chat in the docked width.          */
.aihead-name{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center;line-height:1.2;}
.aihead-mark .aistar,.aimsg-mark .aistar{display:block;}
.aihead-status{min-width:0;font-size:12px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.aihead-status[data-state="waking"]{color:var(--control-ink);}
.aihead-btn{padding:6px 12px;font-size:13px;}
.aihead-icon{display:inline-grid;place-items:center;width:34px;height:34px;border:1px solid transparent;border-radius:8px;
  background:none;color:var(--text);cursor:pointer;}
.aihead-icon:hover{background:var(--surface-3);border-color:var(--hairline);}
.aihead-btn:focus-visible,.aihead-icon:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:1px;}
.aiic-collapse,.aipanel.full .aiic-expand{display:none;}
.aipanel.full .aiic-collapse{display:inline;}

.aibody{flex:1;overflow-y:auto;padding:20px 18px;display:flex;flex-direction:column;gap:16px;}
.aipanel.full .aibody,.aipanel.full .aifoot{padding-left:max(20px,calc((100% - 860px) / 2));padding-right:max(20px,calc((100% - 860px) / 2));}
.aiintro p{margin:0 0 8px;font-size:14px;line-height:1.5;}
.aichat-log{display:flex;flex-direction:column;gap:16px;}
.aimsg{font-size:14px;line-height:1.5;}
.aimsg p{margin:0 0 8px;}
.aimsg p:last-child{margin-bottom:0;}
.aimsg-me{align-self:flex-end;max-width:85%;padding:10px 14px;border-radius:10px;background:var(--surface-3);color:var(--paper);}
.aimsg-ai{display:flex;gap:10px;align-items:flex-start;}
.aimsg-body{flex:1;min-width:0;}
.aimsg-meta,.aimsg-src{font-size:13px;color:var(--muted);}
.aimsg-src strong{color:var(--paper);}
.aiguide p{margin:0 0 8px;}
.aiguide-list{margin:0 0 8px;padding-left:18px;list-style:disc;}
.aiwhich{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px;}
.aiwhich .btn{padding:8px 14px;font-size:13px;}
.aichipref{display:inline-flex;align-items:center;height:26px;padding:0 10px;border:1px solid var(--hairline);border-radius:6px;
  background:var(--surface-2);font-size:12px;font-weight:600;color:var(--paper);}
.aimsg-chips{margin-bottom:6px;}
.aisteplist{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px;font-size:13px;color:var(--muted);}
.aisteplist li{display:flex;align-items:center;gap:8px;}
.aisteplist li::before{content:"";flex:none;width:9px;height:9px;border-radius:50%;border:1.5px solid var(--hairline);}
.aisteplist li.is-active{color:var(--paper);font-weight:600;}
.aisteplist li.is-active::before{border-color:var(--brand-teal);border-top-color:transparent;animation:aispin .8s linear infinite;}
.aisteplist li.is-done::before{background:var(--brand-teal);border-color:var(--brand-teal);}
@keyframes aispin{to{transform:rotate(360deg);}}
@media (prefers-reduced-motion:reduce){.aisteplist li.is-active::before{animation:none;}}
.aifail{padding:10px 12px;border:1px solid var(--blocked);border-radius:8px;background:var(--blocked-wash);color:var(--blocked-ink);}
.aifail .btn{margin-top:8px;padding:7px 14px;font-size:13px;}
/* The AI tab's answer, drawn here: its own controls belong to that tab, and the
   green focus border stays on the Operational View. */
.aipanel .aiactions,.aipanel .aisteps,.aipanel [data-ai-change]{display:none;}
.aipanel .aiwork{margin-top:4px;padding:12px 14px;}
.aipanel .ai-focus{border-color:var(--hairline);}

.aifoot{flex:none;padding:10px 16px 14px;display:flex;flex-direction:column;gap:6px;border-top:1px solid var(--hairline-soft);}
.aicompose{display:flex;flex-direction:column;gap:8px;margin:0;padding:10px;border:1px solid var(--hairline);border-radius:10px;background:var(--surface);}
.aicompose:focus-within{border-color:var(--brand-teal);box-shadow:0 0 0 2px rgba(22,104,109,.16);}
.aiscope{display:flex;flex-wrap:wrap;gap:8px;align-items:center;}
.aichip{display:inline-flex;align-items:center;gap:4px;height:30px;padding:0 4px 0 10px;border:1px solid var(--hairline);
  border-radius:6px;background:var(--surface-2);font-size:13px;font-weight:600;color:var(--paper);}
.aichip[hidden]{display:none;}
.aichip button{display:inline-grid;place-items:center;width:22px;height:22px;border:0;border-radius:5px;background:none;color:var(--muted);cursor:pointer;}
.aichip button:hover{background:var(--surface-3);color:var(--paper);}
.aiadd-wrap{position:relative;}
.aiadd{height:30px;padding:0 10px;border:1px dashed var(--hairline);border-radius:6px;background:none;cursor:pointer;
  font:600 13px var(--ui);color:var(--brand-teal-lift);}
.aiadd:hover{background:var(--teal-wash);}
.aiadd-menu{position:absolute;left:0;bottom:36px;z-index:2;min-width:260px;max-height:260px;overflow-y:auto;padding:6px;
  background:var(--surface);border:1px solid var(--hairline);border-radius:8px;box-shadow:0 12px 28px rgba(16,34,42,.14);}
.aiadd-menu[hidden]{display:none;}
.aiadd-menu button{display:block;width:100%;text-align:left;padding:8px 10px;border:0;border-radius:6px;background:none;
  font:14px var(--ui);color:var(--text);cursor:pointer;}
.aiadd-menu button:hover,.aiadd-menu button:focus-visible{background:var(--teal-wash);outline:none;}
.aiadd-menu p{margin:6px 8px;font-size:13px;color:var(--muted);}
.aiaskrow{display:flex;align-items:flex-end;gap:10px;}
.aiinput{flex:1;min-height:44px;max-height:160px;resize:none;border:0;outline:0;background:transparent;color:var(--paper);font:14px/1.45 var(--ui);padding:4px;}
.aiinput::placeholder{color:var(--placeholder);}
.aiaskrow .btn{padding:9px 18px;}
.aiaskrow .btn:disabled{opacity:.55;cursor:default;}
.aichip button:focus-visible,.aiadd:focus-visible,.aiaskrow .btn:focus-visible,.aiwhich .btn:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:2px;}
.aihint{margin:0;font-size:12px;color:var(--muted);}

/* ---------- the Nightjar shell (9 November 2026) ----------
   The research and administration pages in the Nightjar look: full width, the
   design's background, white components, its colours and faces. Scoped to
   body.research, which base.html sets and the Operational View and the
   geographical dashboard turn off, so neither changes. Muted text is the
   design's secondary #3A4B59 rather than its #5A6B79, which is under the 7:1
   every text colour here is held to (BIO-126); the warning, danger and
   success inks stay the platform's for the same reason; and teal text is
   --brand-teal-lift, since --brand-teal is a fill and never text. */
body.research{
  --brand-teal:#28596A;--brand-teal-lift:#214957;--teal-wash:#E5EBED;
  --primary-press:#1A3B46;--control-border-hover:#5A6B79;--focus-ink:#0D1B26;--row-picked:#EEF2F3;
  --warn-wash:#FFF4D6;--warn-edge:#8A5A00;--ok-wash:#E5F2E7;--ok-edge:#2E6B3A;--err-wash:#FDECEA;--err-edge:#B42318;
  --paper:#0D1B26;--text:#0D1B26;--muted:#3A4B59;--dim:#3A4B59;--placeholder:#3A4B59;
  --surface:#FFFFFF;--surface-2:#F4F7F9;--surface-3:#EEF2F5;--hairline:#DCE3E9;--hairline-soft:#E6ECF0;
  --control-border:#8494A1;
  /* The design's own panel treatment, read from its light palette on 16
     November 2026 (--panel and --shadow in Main.dc.html's logic class).
     Added with the code workspace (issue #32), which is the first screen
     here to use them; the shell had taken the design's colours, faces and
     background and not these. */
  --panel-shadow:0 12px 32px rgba(13,27,38,0.14);
  --panel-fill:linear-gradient(160deg,rgba(255,255,255,0.96) 0%,rgba(255,255,255,0.84) 60%);
  --ui:"IBM Plex Sans","Inter",system-ui,-apple-system,sans-serif;
  --mono:"IBM Plex Mono","JetBrains Mono",ui-monospace,monospace;
  --display:"Pathway Gothic One","IBM Plex Sans",sans-serif;
  --page-bg:
    radial-gradient(1400px 700px at 92% -10%,rgba(40,89,106,.12),transparent 62%),
    radial-gradient(1200px 800px at -10% 20%,rgba(45,114,210,.10),transparent 60%),
    linear-gradient(180deg,#E1E9EF 0%,#ECF1F4 45%,#EEF2F5 100%);
  background:var(--page-bg);
  background-attachment:fixed;min-height:100vh;color:var(--text);font-family:var(--ui);
}
body.research{margin:0;}
/* Her sizes (#115): fixed at what her file draws at 1440 (Nick, 18 November
   2026), her numbers times 0.75, with no page zoom: a zoom moved every
   script that places something by pixels and the code editors' gutters.
   Text is never under 12 px. */
body.research .stage,body.research:has(.app .body) .stage,body.research.aidock .stage{max-width:none;margin:0;padding:0;}
/* The frame (Nick, 9 November 2026): the header full width along the top, the
   menu under it on the left and the content filling the rest. The content
   scrolls and the header and the menu stay put: pinned (sticky) on the page's
   own scroll rather than a scroller of their own, so the window still scrolls,
   which every link, Back and the walks rely on. Each carries the page's own
   fixed background, so nothing shows through it. Nothing between them and the
   window's edges. */
body.research .app{border:0;border-radius:0;box-shadow:none;background:transparent;margin:0;
  min-height:100vh;display:grid;grid-template-rows:54px auto;overflow:visible;}

/* The header: hamburger, wordmark, then the name and the AI button. */
body.research .topbar{display:flex;align-items:center;gap:9px;height:54px;min-height:0;padding:0 18px;
  border:0;border-bottom:1px solid var(--hairline);flex-wrap:nowrap;box-sizing:border-box;
  position:sticky;top:0;z-index:60;background:var(--page-bg);background-attachment:fixed;}
body.research .hamb{flex:none;display:inline-grid;place-items:center;width:44px;height:44px;margin-left:-10px;border:0;
  border-radius:6px;background:transparent;color:var(--paper);padding:0;cursor:pointer;}
body.research .hamb:hover{background:var(--surface-2);}
body.research .hamb svg{width:22px;height:22px;}
body.research .hamb .railtoggle-arrow{display:none;}
body.research .wordmark{display:inline-flex;align-items:baseline;gap:10px;width:auto;height:auto;background:none;
  font-size:inherit;text-indent:0;overflow:visible;text-decoration:none;color:var(--paper);white-space:nowrap;}
body.research .wm-name{font-family:var(--display);font-size:21px;line-height:21px;letter-spacing:1.68px;text-transform:uppercase;}
body.research .wm-product{font-family:var(--display);font-size:14px;line-height:13.5px;letter-spacing:1.08px;text-transform:uppercase;
  color:var(--brand-teal-lift);}
body.research .env{display:none;}
body.research .who{margin-left:auto;display:flex;align-items:center;gap:12px;}
body.research .whomenu{position:relative;}
body.research .whobtn{list-style:none;display:grid;grid-template-columns:auto auto;grid-template-rows:auto auto;
  column-gap:7.5px;align-items:center;padding:4.5px 7.5px;border-radius:4.5px;cursor:pointer;background:transparent;border:0;}
body.research .whobtn::-webkit-details-marker{display:none;}
body.research .whobtn:hover{background:var(--surface-2);}
body.research .whoinitials{display:none;}
body.research .whoname{grid-column:1;font-weight:700;font-size:12px;color:var(--paper);line-height:1.2;
  max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
body.research .whorole{grid-column:1;font-size:12px;color:var(--muted);line-height:1.3;}
body.research .whochev{grid-column:2;grid-row:1 / span 2;color:var(--muted);}
body.research .whomenu[open] .whochev{transform:rotate(180deg);}
body.research .whopanel{position:absolute;right:0;top:calc(100% + 6px);z-index:80;min-width:195px;padding:10.5px;
  background:#FFFFFF;border:1px solid var(--hairline);border-radius:6px;box-shadow:0 10.5px 25.5px rgba(13,27,38,.14);
  display:flex;flex-direction:column;gap:7.5px;}
body.research .whopanel p{margin:0;}
body.research .whopanel .whoemail{max-width:none;font-size:12px;color:var(--muted);}
body.research .whopanel form{display:block;}
body.research .whopanel .signout{width:100%;text-align:left;padding:6px 7.5px;border:1px solid var(--hairline);border-radius:4.5px;
  background:var(--surface-2);color:var(--paper);font-weight:600;}
body.research .whopanel .signout:hover{background:var(--teal-wash);}
body.research .whobtn:focus-visible,body.research .hamb:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}

/* The menu (#115, Nick's brief of 18 November 2026, from Sophia's
   Main.dc.html at 1440): about 230 px open, items 36 px high with a 6 px
   corner, the current item filled teal with white text and icon, the others
   ink on no fill with a light hover. Her icons: 20 px, a 2 px stroke.
   Settings at the foot, plain unless a Settings page is open. The hamburger
   collapses it to her 57 px rail of icons, each with its label as a tip, and
   the choice is kept per browser (`shell-controls.js`). At 1024 px and below
   the menu is the rail; the hamburger opens the full menu over the page.

   The header is 54 px and a menu item 36 px, both measured from her file.
   Her menu is 186 px at 1440 because her three labels are short; ours is
   wider by Nick's brief, so a longer Settings label still fits. */
body.research .body{display:grid;grid-template-columns:186px minmax(0,1fr);min-height:0;transition:none;}
/* Pinned (#115, Nick's review): fixed to the screen below the 54 px header,
   the full height that is left, so nothing on the page (a strip, a long page,
   scrolling) can push Settings, at its foot, out of sight. The grid keeps
   the menu's column, and the page sits in the second. */
body.research .rail{border-right:1px solid var(--hairline);padding:12px 9px 12px 12px;
  overflow-y:auto;box-sizing:border-box;position:fixed;top:54px;left:0;bottom:0;width:186px;z-index:50;
  display:flex;flex-direction:column;background:var(--page-bg);background-attachment:fixed;}
body.research .body > .main{grid-column:2;}
html.app-railshut body.research .rail{width:57px;}
body.research .rail-items{display:flex;flex-direction:column;gap:2px;flex:1;min-height:0;position:static;}
body.research .rail-h{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);margin:0;padding:0;}
body.research .rail hr{border:0;border-top:1px solid var(--hairline);margin:8px 0;}
body.research .rail a{display:flex;align-items:center;gap:10.5px;height:36px;padding:0 10.5px;border-left:0;border-radius:4.5px;
  color:var(--paper);font-weight:700;font-size:12px;text-decoration:none;box-sizing:border-box;white-space:nowrap;}
body.research .rail a:hover{background:rgba(255,255,255,0.95);color:var(--paper);}
body.research .rail a.on,body.research .rail a.on:hover{background:var(--brand-teal);color:#FFFFFF;}
/* Settings open, as hers: the soft teal wash and the ink, not the fill. */
body.research .rail a.rail-settings.on,body.research .rail a.rail-settings.on:hover{background:var(--teal-wash);color:var(--paper);}
body.research .rail a:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research .rail-ic{flex:none;width:20px;height:20px;}
body.research .rail-foot{margin-top:auto;padding-top:8px;}
body.research .rail-version{display:none;}
body.research .railscrim{display:none;}
html.app-railshut body.research .body{grid-template-columns:57px minmax(0,1fr);}
html.app-railshut body.research .rail{padding:12px 9px 12px 12px;}
html.app-railshut body.research .rail-label{display:none;}
html.app-railshut body.research .rail a{justify-content:center;padding:0;}
html.app-railshut body.research .previewnote{display:none;}
/* The rail's tips: the label beside the icon, on hover or keyboard focus.
   Their own attribute, `data-rail-tip`, not `data-tip`, so the page's hover
   box (tooltip.js) cannot draw one above the first item, over the header
   and the wordmark (#154). Shown only where the label is hidden. */
body.research .rail a{position:relative;}
body.research .rail a[data-rail-tip]::after{content:attr(data-rail-tip);position:absolute;left:calc(100% + 10px);top:50%;transform:translateY(-50%);
  padding:6px 10px;border-radius:6px;background:var(--paper);color:#FFFFFF;font:600 13px/1.2 var(--ui);white-space:nowrap;
  box-shadow:var(--panel-shadow);pointer-events:none;opacity:0;visibility:hidden;z-index:95;}
html.app-railshut body.research .rail a[data-rail-tip]:hover::after,
html.app-railshut body.research .rail a[data-rail-tip]:focus-visible::after{opacity:1;visibility:visible;}
html.app-railshut body.research .rail{overflow:visible;}

/* The content: the only thing that scrolls. */
body.research .main{min-width:0;padding:18px 24px 30px 24px;box-sizing:border-box;}
@media (min-width:900px){
  body.research.aidock{padding-right:0;}
  body.research.aidock .main{padding-right:381px;}
}

/* 1024 px and below (#115): the menu is her 57 px rail of icons beside the
   page, whatever was stored, and the hamburger opens the full menu over the
   page, with a scrim behind it. Never stored: a menu left open would cover
   the next page. */
@media (max-width:1024px){
  body.research .body,html.app-railshut body.research .body{grid-template-columns:57px minmax(0,1fr);}
  body.research .rail{overflow:visible;padding:12px 9px 12px 12px;width:57px;}
  body.research .rail-label,body.research .previewnote{display:none;}
  body.research .rail a{justify-content:center;padding:0;}
  body.research .rail a[data-rail-tip]:hover::after,body.research .rail a[data-rail-tip]:focus-visible::after{opacity:1;visibility:visible;}
  html.app-draweropen body.research .rail{position:fixed;top:0;left:0;bottom:0;height:100vh;height:100dvh;z-index:90;width:186px;max-width:85vw;
    padding:12px 9px 12px 12px;background:#F4F7F9;box-shadow:10.5px 0 27px rgba(13,27,38,.18);overflow-y:auto;}
  html.app-draweropen body.research .rail-label{display:inline;}
  html.app-draweropen body.research .previewnote{display:block;}
  html.app-draweropen body.research .rail a{justify-content:flex-start;padding:0 14px;}
  html.app-draweropen body.research .rail a[data-rail-tip]::after{display:none;}
  html.app-draweropen body.research .railscrim{display:block;position:fixed;inset:0;z-index:89;background:rgba(13,27,38,.45);}
  body.research .main{padding:18px 24px 30px;}
}
/* A phone (below 600 px): no rail beside the page, which would take a sixth of
   the width; the hamburger opens the full menu over the page, as above. */
@media (max-width:599px){
  body.research .body,html.app-railshut body.research .body{grid-template-columns:minmax(0,1fr);}
  body.research .body > .main{grid-column:1;}
  body.research .rail{position:fixed;top:0;left:0;bottom:0;height:100vh;height:100dvh;z-index:90;width:186px;max-width:85vw;
    transform:translateX(-100%);visibility:hidden;transition:transform .2s ease,visibility 0s linear .2s;}
  html.app-draweropen body.research .rail{transform:none;visibility:visible;transition:transform .2s ease;}
}
@media (max-width:599px) and (prefers-reduced-motion:reduce){
  body.research .rail,html.app-draweropen body.research .rail{transition:none;}
}
@media (max-width:599px){
  body.research .topbar{padding:0 16px;gap:10px;}
  body.research .main{padding:20px 16px 32px;}
  body.research .whobtn{grid-template-columns:auto;padding:3px;border-radius:50%;}
  body.research .whoname,body.research .whorole,body.research .whochev{display:none;}
  body.research .whoinitials{display:grid;place-items:center;width:30px;height:30px;border-radius:50%;
    background:var(--brand-teal);color:#FFFFFF;font:700 12px/1 var(--ui);}
  body.research .who{gap:7.5px;}
  body.research .aibtn{padding:0 12px;}
}

/* The content on white components. */
body.research .card,body.research .catcard{background:#FFFFFF;border:1px solid var(--hairline);border-radius:8px;}
body.research .btn{background:var(--brand-teal);border-color:var(--brand-teal);border-radius:4.5px;}
body.research .btn:hover{background:var(--brand-teal-lift);border-color:var(--brand-teal-lift);}
body.research .btn.ghost{background:#FFFFFF;color:var(--paper);border-color:var(--control-border);}
body.research .btn.ghost:hover{background:var(--surface-2);border-color:var(--paper);}
body.research a{color:var(--brand-teal-lift);}
body.research a.btn{color:#FFFFFF;}
body.research a.btn.ghost{color:var(--paper);}
body.research .rail a,body.research .rail a.on{color:inherit;}
body.research .rail a{color:var(--paper);}
body.research .rail a.on{color:#FFFFFF;}
body.research .rail a.rail-settings.on{color:var(--paper);}
body.research table{background:#FFFFFF;}
body.research :focus-visible{outline-color:var(--brand-teal);}

/* Settings: its screens as tabs, the version at the foot. */
body.research .settingstabs{margin:0 0 16.5px;}
/* Her Settings has no visible heading: the tab bar is the top of the page,
   and the word is kept for a screen reader. */
body.research .settingstabs-h{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);margin:0;}
/* Her joined tab bar (#115): a 4 px well on the chip ground, 6 px tabs at
   16/600 in the secondary ink, the current one filled teal, a 1 px line
   between two tabs neither of which is current. One row, never wrapped: a
   row too long for the page scrolls sideways inside its own well (Nick's
   review), so the page itself never scrolls sideways. */
body.research .settingstabs-row,body.research .qtabs,body.research .ourtabs,body.research .asktests-tabs{
  display:flex;flex-wrap:nowrap;gap:3px;padding:3px;margin:0 0 12px;box-sizing:border-box;width:max-content;max-width:100%;
  overflow-x:auto;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch;background:rgba(255,255,255,0.72);border:1px solid var(--hairline);border-radius:6px;z-index:auto;
  scrollbar-width:thin;}
body.research .settingstab,body.research .qtab,body.research .ourtabs a,body.research .asktests-tabs a{
  position:relative;flex:none;display:flex;align-items:center;justify-content:center;height:39px;padding:0 12px;box-sizing:border-box;
  border:0;border-radius:4.5px;background:transparent;color:var(--muted);font:600 12px/1 var(--ui);letter-spacing:0;
  text-transform:none;text-decoration:none;white-space:nowrap;}
body.research .settingstab:hover,body.research .qtab:hover,body.research .ourtabs a:hover,body.research .asktests-tabs a:hover{
  background:rgba(255,255,255,0.95);color:var(--paper);}
body.research .settingstab.on,body.research .qtab.on,body.research .ourtabs a[aria-current="page"],body.research .asktests-tabs a.is-current{
  background:var(--brand-teal);color:#FFFFFF;border:0;}
body.research .settingstab:focus-visible,body.research .qtab:focus-visible,body.research .ourtabs a:focus-visible,
body.research .asktests-tabs a:focus-visible{outline:2px solid var(--focus-ink);outline-offset:-2px;}
body.research .settingstab + .settingstab:not(.on)::before,body.research .qtab + .qtab:not(.on)::before,
body.research .ourtabs a + a:not([aria-current="page"])::before,body.research .asktests-tabs a + a:not(.is-current)::before{
  content:"";position:absolute;left:-3px;top:9px;bottom:9px;width:1px;background:var(--control-border);}
body.research .settingstab.on + .settingstab::before,body.research .qtab.on + .qtab::before,
body.research .ourtabs a[aria-current="page"] + a::before,body.research .asktests-tabs a.is-current + a::before{display:none;}
body.research .main:has(> .settingstabs){display:flex;flex-direction:column;}
body.research .settingsfoot{order:99;margin:32px 0 0;font-family:var(--mono);font-size:12px;color:var(--muted);}


/* ---------- the Nightjar components (9 November 2026, phase 1b) ----------
   Every control on the research and administration pages as the design draws
   it, through the tokens above. Text colours are held to the platform's 7:1
   (BIO-126), so teal text is --brand-teal-lift (#214957, the design's hover
   teal), a danger button's text is --blocked-ink with the design's #B42318
   edge, and placeholders are --muted; every fill, edge and wash is the
   design's own value. */
body.research .btn,body.research button.btn,body.research input.btn{display:inline-flex;align-items:center;justify-content:center;
  gap:6px;min-height:33px;padding:0 13.5px;border:0;border-radius:4.5px;background:var(--brand-teal);color:#FFFFFF;
  font:700 12px/1 var(--ui);text-decoration:none;cursor:pointer;box-sizing:border-box;}
body.research .btn:hover{background:var(--brand-teal-lift);}
body.research .btn:active{background:var(--primary-press);}
body.research .btn:disabled,body.research .btn[aria-disabled="true"]{background:var(--brand-teal);opacity:.4;cursor:not-allowed;}
body.research .btn.ghost{background:#FFFFFF;color:var(--paper);border:1px solid var(--control-border);font-weight:600;}
body.research .btn.ghost:hover{background:var(--surface-2);border-color:var(--control-border-hover);}
body.research .btn.ghost:active{background:var(--surface-3);}
body.research .btn.small{min-height:30px;padding:0 12px;font-size:13px;}
body.research .btn.danger{background:#FFFFFF;color:var(--blocked-ink);border:1px solid var(--err-edge);font-weight:600;}
body.research .btn.danger:hover{background:var(--err-wash);}
body.research .btn:focus-visible,body.research button:focus-visible,body.research a:focus-visible,
body.research summary:focus-visible,body.research .aiadd:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research .asklink,body.research .linkbtn,body.research .tagadd,body.research .every-rule{color:var(--brand-teal-lift);}

/* Panels, tiles and dividers. */
/* Her panel: the white to near white fill, a 1 px edge, 8 px corners and no
   shadow (her --panel; #115). */
body.research .card,body.research .catcard,body.research .tablecard,body.research .panel,body.research .table-wrap{
  background:var(--panel-fill);border:1px solid var(--hairline);border-radius:8px;box-shadow:none;}
body.research .statcard{background:#FFFFFF;border:1px solid var(--hairline);border-radius:8px;}
body.research hr{border:0;border-top:1px solid var(--hairline);}

/* Notes and banners: warning, success, error. */
body.research .note{background:var(--warn-wash);border-left:3px solid var(--warn-edge);border-radius:0 8px 8px 0;}
body.research .note.ok{background:var(--ok-wash);border-left-color:var(--ok-edge);}
body.research .errors{background:var(--err-wash);border:1px solid var(--err-edge);border-left-width:3px;border-radius:0 8px 8px 0;}

/* Forms. */
body.research .input,body.research .ta,body.research .sel,body.research input[type="text"],body.research input[type="email"],
body.research input[type="password"],body.research input[type="search"],body.research input[type="date"],
body.research input[type="number"],body.research select,body.research textarea:not(#querytext){
  background:#FFFFFF;border:1px solid var(--control-border);border-radius:4.5px;color:var(--paper);font:12px var(--ui);
  min-height:33px;padding:0 9px;box-sizing:border-box;}
body.research textarea:not(#querytext),body.research .ta:not(#querytext){min-height:66px;padding:7.5px 9px;}
body.research select,body.research .sel{-webkit-appearance:none;appearance:none;padding-right:27px;
  background:#FFFFFF url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%233A4B59' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right 10.5px center;}
body.research textarea.codeblock{font-family:var(--mono);}
body.research input::placeholder,body.research textarea::placeholder{color:var(--muted);font-style:normal;}
body.research .input:focus-visible,body.research .ta:focus-visible,body.research .sel:focus-visible,body.research input:focus-visible,
body.research select:focus-visible,body.research textarea:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research input[aria-invalid="true"],body.research .field.has-error .input{border-color:var(--err-edge);}
body.research input[type="checkbox"],body.research input[type="radio"]{accent-color:var(--brand-teal);width:15px;height:15px;}
body.research .field label,body.research label.field-label{color:var(--paper);font-weight:600;}
body.research .hint{color:var(--muted);}

/* Tables. */
body.research th{background:var(--surface-2);color:var(--muted);font-weight:700;border-bottom:1px solid var(--hairline);}
body.research td{background:#FFFFFF;border-bottom:1px solid var(--hairline);}
body.research tbody tr:hover td{background:var(--surface-2);}
body.research tr.selected td,body.research tr[aria-selected="true"] td{background:var(--row-picked);}
body.research td a{color:var(--brand-teal-lift);text-decoration:none;}
body.research td a:hover{text-decoration:underline;}

/* Tabs as the design's segmented control: Query datasets and others. */
body.research .tabs,body.research .tabbar{display:inline-flex;flex-wrap:wrap;gap:4px;padding:4px;background:#FFFFFF;
  border:1px solid var(--hairline);border-radius:8px;}
body.research .tab{padding:9px 16px;border-radius:6px;font-weight:600;color:var(--paper);text-decoration:none;border:0;background:transparent;}
body.research .tab:hover{background:var(--surface-2);}
body.research .tab.on,body.research .tab[aria-selected="true"]{background:var(--brand-teal);color:#FFFFFF;}

/* The other tab rows (the query modes, Our organisation's three screens, the
   assistant tests' two) are drawn as her joined tab bar with Settings', above. */
/* Chips and badges keep their shapes; their fills and edges from the set. */
body.research .pill,body.research .tagpill{border-color:var(--hairline);}

/* ---------- the catalogue and a catalogue's page (9 November 2026) ----------
   After the Nightjar design's catalogue screens, measured at 1440 px: its
   sizes, spacing, edges and washes, with its 11 px labels at the platform's
   12 px floor. Text is held to 7:1 (BIO-126), so the
   design's #5A6B79 grey is --muted, its teal and green chip text are
   --brand-teal-lift and --cleared-ink, and danger text is --blocked-ink. */
body.research .pagehead{display:flex;align-items:center;gap:12px;min-height:48px;margin:0 0 20px;flex-wrap:wrap;}
body.research .pagehead .grow,body.research .grow{flex:1;min-width:0;}
body.research .pagehead .eyebrow{margin:0 0 2px;font:700 12px/16px var(--ui);letter-spacing:.66px;text-transform:uppercase;color:var(--muted);}
body.research .pagehead h1{margin:0;font:700 22px/1.45 var(--ui);color:var(--paper);}
/* A page's title under its eyebrow, on every page that has one: her 22/700
   page heading (#115). */
body.research .main .eyebrow + h1,body.research .main .eyebrow + h2,body.research .main .eyebrow + h3{
  margin-top:0;font-size:22px;font-weight:700;line-height:1.45;color:var(--paper);}
body.research .catpage-ver{font:500 16px/20px var(--mono);letter-spacing:-.16px;color:var(--muted);}
body.research .pagehead .btn{min-height:30px;font-size:12px;}
body.research .btn.back{gap:4.5px;padding:0 12px;}
body.research .catstack{display:flex;flex-direction:column;gap:16px;}
body.research .cattags{display:flex;flex-wrap:wrap;align-items:center;gap:8px;min-height:32px;}
body.research .cattags-h{font-weight:700;font-size:14px;color:var(--muted);}
body.research .cattags .tagpill{display:inline-flex;align-items:center;height:24px;padding:0 10px;border-radius:12px;border:1px solid transparent;
  background:#FFFFFF;border-color:var(--hairline);color:var(--brand-teal-lift);font:700 12px/1 var(--ui);text-decoration:none;}
body.research .cattags .tagpill:hover{border-color:var(--brand-teal-lift);}
body.research .cattags .tagpill.on{background:var(--brand-teal);color:#FFFFFF;}
body.research .catcount{margin:0;font:700 16px/21px var(--ui);color:var(--paper);}
body.research .catwhy{margin:2px 0 0;font-size:14px;line-height:20px;color:var(--muted);max-width:none;}
body.research .msg{display:flex;gap:12px;align-items:flex-start;padding:14px 16px;border-radius:8px;border:1px solid var(--hairline);
  background:var(--surface-2);color:var(--paper);font-size:14px;}
body.research .msg p{margin:0;max-width:none;}
body.research .msg b{font-weight:700;}
body.research .msg-ok{background:var(--ok-wash);border-color:transparent;}
body.research .catempty{padding:28px;text-align:center;}
body.research .dscard .controls-off{position:relative;z-index:2;margin:0;font-size:12px;line-height:17px;}
body.research .catempty p{margin:0 auto;color:var(--muted);}

/* The cards. The whole card links to the catalogue's page; the menu sits
   above that link, so it stays clickable. */
body.research .dsgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:16px;}
body.research .dscard{position:relative;display:flex;flex-direction:column;gap:12px;padding:16px 18px;border:1px solid var(--hairline);
  border-radius:8px;background:#FFFFFF;color:var(--paper);min-width:0;transition:border-color .12s ease;}
body.research .dscard:hover{border-color:var(--control-border);}
body.research .dstop{display:flex;align-items:center;gap:8px;flex-wrap:wrap;position:relative;z-index:3;min-height:32px;}
body.research .dslink{display:flex;flex-direction:column;gap:2px;color:var(--paper);text-decoration:none;min-width:0;}
body.research .dslink::after{content:"";position:absolute;inset:0;border-radius:8px;z-index:1;}
body.research .dslink:focus-visible{outline:none;}
body.research .dslink:focus-visible::after{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research .dsname{font:700 14px/20px var(--ui);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
body.research .dsver{font:500 13.5px/20px var(--mono);letter-spacing:-.135px;color:var(--muted);}
body.research .dsowner{font-size:12px;line-height:17px;color:var(--muted);}
body.research .dsfoot{display:flex;align-items:flex-end;gap:12px;}
body.research .dsbig{display:flex;flex-direction:column;}
body.research .dsbig b{font:500 26px/38px var(--mono);letter-spacing:-.52px;color:var(--paper);}
body.research .dsbig span{font-size:12px;line-height:16px;color:var(--muted);}
body.research .dsside{display:flex;flex-direction:column;align-items:flex-end;gap:2px;}
body.research .dsside span{font-size:12px;line-height:16px;color:var(--muted);}
body.research .dsside b{font:600 12px/17px var(--ui);color:var(--muted);white-space:nowrap;}

/* Status chips, one family. */
body.research .st{height:24px;display:inline-flex;align-items:center;gap:6px;padding:0 9px;border-radius:4px;font:700 12px/1 var(--ui);
  white-space:nowrap;box-sizing:border-box;}
body.research .st-ok{background:var(--ok-wash);color:var(--cleared-ink);}
body.research .st-accent{background:var(--teal-wash);color:var(--brand-teal-lift);}
body.research .st-neutral{background:#FFFFFF;color:var(--muted);border:1px solid var(--hairline);}
body.research .st-warn{background:var(--control-wash);color:var(--control-ink);}
body.research .st-bad{background:var(--blocked-wash);color:var(--blocked-ink);}
body.research .st .stdot{width:7px;height:7px;border-radius:50%;background:currentColor;flex:none;opacity:.7;}
body.research .st .stdot.live{opacity:1;animation:fpulse 2s ease-in-out infinite;}
@media (prefers-reduced-motion:reduce){body.research .st .stdot.live{animation:none;}}

/* The menu: a native details element, its panel floating at the right. */
body.research .catmenu{position:relative;}
body.research .catmenu > summary{list-style:none;}
body.research .catmenu > summary::-webkit-details-marker{display:none;}
body.research .catmenu > summary::after{content:none;}
body.research .btn.iconbtn{display:inline-grid;place-items:center;width:32px;min-height:32px;height:32px;padding:0;border-color:transparent;background:transparent;}
body.research .btn.iconbtn:hover{background:var(--surface-2);}
body.research .catpagehead .btn.iconbtn{width:40px;height:40px;min-height:40px;border-color:var(--control-border);background:#FFFFFF;}
body.research .catmenu .menu{position:absolute;right:0;top:calc(100% + 6px);z-index:45;width:290px;padding:8px;background:#FFFFFF;
  border:1px solid var(--hairline);border-radius:8px;box-shadow:0 14px 34px rgba(13,27,38,.14);box-sizing:border-box;}
body.research .menu-item{width:100%;min-height:44px;display:flex;align-items:center;gap:10px;padding:6px 10px;border:0;border-radius:4px;
  background:transparent;color:var(--paper);text-align:left;font:600 14px/1.3 var(--ui);text-decoration:none;cursor:pointer;box-sizing:border-box;}
body.research .menu-item:hover{background:var(--surface-2);}
body.research .menu-item.danger{color:var(--blocked-ink);}
body.research .menu-hint{display:block;font-weight:500;font-size:12px;line-height:17px;color:var(--muted);}
body.research .menu-sep{height:1px;margin:6px 4px;background:var(--hairline);}
body.research .menu-state{margin:0;padding:6px 10px 2px;font-size:13px;color:var(--muted);}

/* The Clear dialog, the design's: head, body, foot, a filled red Clear. */
body.research .catdialog{width:560px;max-width:calc(100% - 32px);padding:0;border:1px solid var(--hairline);border-radius:8px;
  background:#FFFFFF;color:var(--paper);box-shadow:0 24px 60px rgba(13,27,38,.24);}
body.research .catdialog::backdrop{background:rgba(13,27,38,.45);}
body.research .catdialog-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 18px;border-bottom:1px solid var(--hairline);}
body.research .catdialog-head h2{margin:0;font:700 16px/21px var(--ui);}
body.research .catdialog-body{padding:16px 18px;}
body.research .catdialog-body p{margin:0;max-width:none;}
body.research .catdialog-foot{display:flex;justify-content:flex-end;gap:8px;padding:12px 18px 16px;}
body.research .btn.dangerfill{background:var(--err-edge);color:#FFFFFF;border:0;}
body.research .btn.dangerfill:hover{background:var(--blocked-ink);}

/* A catalogue's page: its figures in one row of tiles, then the tabs. */
body.research .kvgrid{display:grid;grid-template-columns:repeat(var(--tiles,4),minmax(0,1fr));border:1px solid var(--hairline);
  border-radius:8px;overflow:hidden;background:#FFFFFF;}
body.research .kvgrid > div{padding:12px 16px;border-left:1px solid var(--hairline);min-width:0;}
body.research .kvgrid > div:first-child{border-left:0;}
body.research .kvgrid .k{display:block;font:700 12px/16px var(--ui);color:var(--muted);}
body.research .kvgrid .v{font:400 13.5px/20px var(--mono);letter-spacing:-.135px;color:var(--paper);}
body.research .kvgrid .hint{font-size:12px;line-height:17px;color:var(--muted);}
body.research .ptabs{display:flex;gap:4px;border-bottom:1px solid var(--hairline);overflow-x:auto;}
body.research .ptab{height:44px;display:inline-flex;align-items:center;padding:0 14px;border-bottom:3px solid transparent;color:var(--muted);
  font:700 14px/1 var(--ui);white-space:nowrap;text-decoration:none;box-sizing:border-box;}
body.research .ptab:hover{color:var(--paper);}
body.research .ptab[aria-current="page"]{color:var(--paper);border-bottom-color:var(--brand-teal);}
body.research .panel{background:#FFFFFF;border:1px solid var(--hairline);border-radius:8px;}
body.research dl.kv{display:grid;grid-template-columns:200px minmax(0,1fr);margin:0;}
body.research dl.kv dt,body.research dl.kv dd{margin:0;padding:12px 18px;border-top:1px solid var(--hairline);font-size:14px;line-height:20px;}
body.research dl.kv dt{font-weight:700;color:var(--muted);}
body.research dl.kv > :nth-child(1),body.research dl.kv > :nth-child(2){border-top:0;}
body.research .catversions{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:4px;}
body.research .cattable{overflow:auto;}
body.research .cattable table{width:100%;border-collapse:collapse;}
body.research .cattable th{padding:8px 14px;text-align:left;font:700 12px/16px var(--ui);letter-spacing:.66px;text-transform:uppercase;}
body.research .cattable td{padding:8px 14px;font-size:14px;vertical-align:top;}
body.research .cattable .st{margin-right:6px;}
body.research .catrestrictions{padding:16px 18px;display:flex;flex-direction:column;gap:10px;}
body.research .catrestrictions-line{margin:0;max-width:none;}
/* Kept to their own sizes under the components pass (9 November 2026): the
   code editor, whose line numbers count from its own padding and font
   (BIO-115), and the results table's controls, all one height (BIO-148). */
body.research .rtable-tools select,body.research .rtable-tools input[type=search],body.research .rtable-tools .btn,
body.research .rtable-controls select,body.research .rtable-controls .btn{min-height:27px;height:27px;box-sizing:border-box;}
/* Pinned below the pinned header (9 November 2026), so nothing slides under it. */
body.research .atabs{top:54px;}
@media (max-width:1180px){
  body.research .kvgrid{grid-template-columns:repeat(3,minmax(0,1fr));}
  body.research .kvgrid > div:nth-child(3n+1){border-left:0;}
  body.research .kvgrid > div:nth-child(n+4){border-top:1px solid var(--hairline);}
}
@media (max-width:700px){
  body.research .kvgrid{grid-template-columns:minmax(0,1fr);}
  body.research .kvgrid > div{border-left:0;border-top:1px solid var(--hairline);}
  body.research .kvgrid > div:first-child{border-top:0;}
  body.research dl.kv{grid-template-columns:minmax(0,1fr);}
  body.research dl.kv dd{border-top:0;padding-top:0;}
}

/* The compact tag controls keep their 30 px (BIO-150) under the components
   pass, whose inputs are 44 px and small buttons 36 px everywhere else: in
   the Tags panel, its Edit and Delete question, and the Your tags table. */
body.research .tagdrop-panel .tagedit-row .input,body.research [data-tag-table] .tagedit-row .input{
  min-height:30px;height:30px;padding:4px 8px;font-size:13px;}
body.research .tagdrop-panel .btn.small,body.research [data-tag-table] .btn.small{min-height:30px;height:30px;padding:0 10px;font-size:13px;}
body.research .tagnew .input,body.research .tagnew .btn{min-height:30px;height:30px;}

/* ---------- Results (9 November 2026) ----------
   After the Nightjar design's Results screen, measured at 1440 px: the
   filters in one panel on one row, the Tags row, the analyses as a table in
   one panel. Inputs and the Filter button keep the components pass's 44 px;
   the table's heading labels its 12 px floor. */
body.research .pagehead-line{margin:6px 0 0;font-size:14px;line-height:20px;color:var(--muted);max-width:none;}
body.research .resfilter{padding:16px 18px;}
body.research .resfilter-row{display:grid;grid-template-columns:2fr 1fr 1fr 1.4fr auto;gap:16px;align-items:end;margin:0;}
body.research .resfilter-row .field{display:flex;flex-direction:column;gap:6px;min-width:0;margin:0;}
body.research .resfilter-row .field label{font:700 14px/20px var(--ui);color:var(--paper);text-transform:none;letter-spacing:0;}
body.research .resfilter-row .input{width:100%;}
body.research .resfilter-go{display:flex;gap:8px;}
body.research .restable{min-width:0;max-width:100%;}
/* A wide table scrolls in its panel, never the page (a flex item grows to its content). */
body.research .catstack > *{min-width:0;}
body.research .restbl{width:100%;border-collapse:separate;border-spacing:0;}
body.research .restbl th{height:40px;padding:0 14px;background:var(--surface-2);border-bottom:1px solid var(--hairline);text-align:left;
  font:700 12px/16px var(--ui);letter-spacing:.66px;text-transform:uppercase;color:var(--muted);white-space:nowrap;}
body.research .restbl th:first-child{border-top-left-radius:8px;}
body.research .restbl th:last-child{border-top-right-radius:8px;}
body.research .restbl td{height:56px;padding:8px 14px;border-top:1px solid var(--hairline);border-bottom:0;vertical-align:middle;
  background:transparent;font-size:14px;color:var(--paper);}
body.research .restbl tbody tr:first-child td{border-top:0;}
body.research .restbl tbody tr:hover td{background:var(--surface-2);}
body.research .restbl .num{text-align:right;font-variant-numeric:tabular-nums;}
body.research .restbl .mono{font:400 13.5px/20px var(--mono);letter-spacing:-.135px;}
body.research .reslink{font-weight:700;color:var(--paper);text-decoration:none;}
body.research .reslink:hover{color:var(--brand-teal-lift);text-decoration:underline;}
body.research .ressub{font-size:13px;line-height:19px;color:var(--muted);}
body.research .resrun{white-space:nowrap;}
body.research .restags .tagbar{display:flex;flex-wrap:nowrap;align-items:center;gap:6px;margin:0;}
body.research .restbl td:nth-child(1){min-width:220px;}
body.research .restbl td:nth-child(2){min-width:170px;}
body.research .restags .tagpills{display:contents;}
body.research .resact{white-space:nowrap;text-align:right;}
body.research .resact .btn.small{min-height:24px;height:24px;padding:0 9px;font-size:12px;}
body.research .resact .btn + .btn{margin-left:4.5px;}
body.research .btn.small.resdelete{background:transparent;border-color:transparent;color:var(--paper);font-weight:600;}
body.research .btn.small.resdelete:hover{background:var(--surface-2);}
body.research .resempty{padding:28px 18px;text-align:center;}
body.research .resempty p{margin:0 auto 8px;max-width:none;}
body.research .resempty p:last-child{margin-bottom:0;}
body.research .panel-head{min-height:56px;display:flex;align-items:center;gap:10px;padding:0 12px 0 18px;border-bottom:1px solid var(--hairline);}
body.research .panel-head h2{margin:0;flex:1;font:700 16px/21px var(--ui);color:var(--paper);}
body.research .reslapsed-item{display:flex;flex-direction:column;gap:4px;padding:16px 18px;border-top:1px solid var(--hairline);}
body.research .reslapsed-item:first-of-type{border-top:0;}
body.research .reslapsed-item .hint{margin:4px 0 0;}
@media (max-width:1180px){
  /* As the design: the table scrolls in its panel, the first column staying
     put. The panel is the positioning context, so nothing inside it widens
     the page; an open + Add tag scrolls with the table here. */
  body.research .restable{overflow-x:auto;position:relative;}
  body.research .restbl th:first-child,body.research .restbl td:first-child{position:sticky;left:0;z-index:2;background:#FFFFFF;}
  body.research .restbl th:first-child{z-index:3;background:var(--surface-2);}
}
@media (max-width:1023px){
  body.research .resfilter-row{grid-template-columns:2fr 1fr 1fr;}
}
@media (max-width:599px){
  body.research .resfilter-row{grid-template-columns:minmax(0,1fr);}
}

/* A table too wide for a phone scrolls in its own box (Your tags). */
body.research .tablescroll{overflow-x:auto;position:relative;max-width:100%;}

/* ---------- Refresh's loading overlay on the Nightjar feed (9 November 2026) ----------
   Since 10 November a light veil, black at 40% with a 3px blur, so the
   Operational View stays in sight behind it; fading in over 0.3s and out
   over 0.4s. The wordmark, the count, its stage and Cancel sit on a dark
   panel of their own, because the view behind a 40% veil has light parts
   (the map's land, a bar) and the text is held to 7:1 whatever is behind
   it: on the panel (#050C0F at 90%) white is 17.4, the teal 10.0, the
   timeout's red 8.8, the muted grey 7.8. */
.dmload{position:fixed;inset:0;z-index:10000;display:grid;place-items:center;padding:24px;
  background:rgba(0,0,0,.40);-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px);
  opacity:0;transition:opacity .4s ease;font-family:"IBM Plex Sans",system-ui,sans-serif;color:#FFFFFF;}
.dmload.on{opacity:1;transition:opacity .3s ease;}
.dmload[hidden]{display:none;}
.dmload-card{display:grid;justify-items:center;gap:14px;text-align:center;padding:28px 36px;border-radius:12px;
  background:rgba(5,12,15,.90);border:1px solid rgba(255,255,255,.08);box-shadow:0 18px 48px rgba(0,0,0,.45);}
.dmload-word{font-weight:600;font-size:20px;letter-spacing:.28em;color:#FFFFFF;}
.dmload-word em{font-style:normal;margin-left:8px;font-weight:500;font-size:13px;letter-spacing:.2em;color:#6FD6C4;}
.dmload-track{width:min(260px,70vw);height:4px;border-radius:4px;background:rgba(255,255,255,.08);overflow:hidden;}
.dmload-fill{height:100%;width:0;border-radius:4px;background:linear-gradient(90deg,#2B6B7A,#6FD6C4);}
.dmload-title{margin:0;font-size:16px;font-weight:600;color:#FFFFFF;}
.dmload-stopped .dmload-title{color:#F4A3A4;}
.dmload-count{font-family:"IBM Plex Mono",ui-monospace,monospace;font-size:28px;font-weight:600;letter-spacing:-.02em;color:#FFFFFF;}
.dmload-count small{font-size:13px;font-weight:500;letter-spacing:0;color:#9FB1B6;}
.dmload-stage{font-family:"IBM Plex Mono",ui-monospace,monospace;font-size:13px;color:#9FB1B6;}
.dmload-cancel{font:600 14px/1 "IBM Plex Sans",system-ui,sans-serif;color:#FFFFFF;background:transparent;
  border:1px solid rgba(255,255,255,.15);border-radius:6px;padding:10px 16px;min-height:40px;cursor:pointer;}
.dmload-cancel:hover{border-color:rgba(255,255,255,.4);}
.dmload-cancel:focus-visible{outline:2px solid #6FD6C4;outline-offset:3px;}
@media (prefers-reduced-motion:reduce){
  .dmload,.dmload.on,.dmload-fill{transition:none;}
}

/* ---------- Analysis cards: controls behind a settings button (9 November 2026) ----------
   Option 1 of the card controls mock: the card shows its description and its
   chart or table; the sliders button opens its choices in a popover under the
   head, 250 px, labelled 30 px controls, applied as they change. Without
   scripts the popover is drawn in place, with Apply, as the controls were. */
body.research .chartcard{position:relative;}
body.research .chart-iconbtn{width:30px;height:30px;min-height:30px;display:inline-grid;place-items:center;padding:0;
  border:1px solid var(--hairline);border-radius:6px;background:#FFFFFF;color:var(--muted);cursor:pointer;text-decoration:none;
  box-sizing:border-box;font-size:0;}
body.research .chart-iconbtn:hover{background:var(--surface-2);color:var(--paper);}
body.research .chart-iconbtn:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research .chart-iconbtn[aria-expanded="true"]{background:var(--surface-2);border-color:var(--control-border);color:var(--paper);}
body.research .chart-settings{display:none;}
.js body.research .chart-settings{display:inline-grid;}
body.research .chart-actions{display:flex;align-items:center;gap:6px;}
body.research .chartpop .chart-editor{display:flex;flex-direction:column;align-items:stretch;gap:10px;margin:0;padding:0;
  background:transparent;border:0;}
body.research .chartpop-field{display:grid;gap:4px;margin:0;}
body.research .chartpop-label{font:700 12px/16px var(--ui);color:var(--muted);}
body.research .chartpop .sel,body.research .chartpop select,body.research .chartpop input[type=search]{min-height:30px;height:30px;
  padding:0 19.5px 0 7.5px;font-size:12px;width:100%;background-position:right 7px center;}
body.research .chartpop input[type=search]{padding:0 7.5px;}
.js body.research .chartpop .chart-formsel{display:block;}
body.research .chartpop .chart-fixed{font-size:13px;color:var(--paper);}
body.research .chartpop-note{margin:0;font-size:12px;line-height:17px;color:var(--muted);}
/* The chart first, then fields, then Show as (BIO-193): the line under Chart
   saying what the chosen analysis shows, and, while a Chart changed in the
   popover still needs a field, the card's drawing hidden behind one line. */
body.research .chartpop-hint{margin:-6px 0 0;font-size:12px;line-height:17px;color:var(--muted);}
body.research .chartpop-slots{display:flex;flex-direction:column;gap:10px;}
body.research .chartpop-slots:empty,body.research .chartpop-slots:not(:has(*)){display:none;}
.chart-choose{margin:4px 0 8px;border:1px dashed var(--hairline);border-radius:8px;padding:16px;
  font-size:13.5px;color:var(--paper);}
.chart-choose[hidden]{display:none;}
.chartcard.is-choosing > :not(.chart-head):not(.chartpop):not(.chart-choose):not(.chart-confirm):not(template){display:none;}
.chartcard.is-choosing .chart-title{visibility:hidden;}
/* Add a chart in the Chart menu's groups. A type this version cannot draw
   is disabled with its reason, in the page's text colour on a tint, so it
   keeps the 7.0 floor (BIO-126): set apart by italic, not by fading. */
.chartadd-h{margin:8px 0 2px;padding:0 9px;font:700 12px/16px var(--ui);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
.chartadd-menu .formopt:disabled{cursor:not-allowed;font-style:italic;background:#F3F6F7;color:var(--text);}
.chartadd-menu .formopt:disabled .formopt-what{color:var(--text);}
body.research .chartpop .btn{min-height:30px;height:30px;font-size:13px;padding:0 12px;}
/* With scripts: a popover under the card's head, shown when its button opens it. */
.js body.research .chartpop{position:absolute;right:12px;top:52px;z-index:40;width:250px;max-width:calc(100% - 24px);
  padding:12px;display:none;flex-direction:column;gap:10px;background:#FFFFFF;border:1px solid var(--hairline);border-radius:8px;
  box-shadow:0 12px 32px rgba(13,27,38,.14);box-sizing:border-box;margin:0;
  overflow:auto;overscroll-behavior:contain;}
.js body.research .chartpop.open{display:flex;}
/* Capped by chart-settings.js at 70% of the window and its edge (BIO-194):
   the Chart menu stays at the top while the rest scrolls under it. */
.js body.research .chartpop .chart-editor > .chartpop-field:first-of-type{position:sticky;top:-12px;z-index:1;
  margin-top:-12px;padding-top:12px;background:#FFFFFF;}
.js body.research .chartpop .chart-editor > *{flex:none;}
/* The table's: its chips, the two layout buttons, Shares, Filter rows and Sort by, stacked. */
.js body.research .rtable-pop{width:280px;}
.js body.research .rtable-pop .rtable-tools,.js body.research .rtable-pop .rtable-fields{display:flex;flex-direction:column;align-items:stretch;gap:8px;}
.js body.research .rtable-pop .rtable-inline label{display:grid;gap:4px;font:700 12px/16px var(--ui);color:var(--muted);}
.js body.research .rtable-pop .rtable-inline{display:grid;gap:6px;}
.js body.research .rtable-pop .rtable-add label{display:grid;gap:4px;font:700 12px/16px var(--ui);color:var(--muted);}
.js body.research .rtable-pop .rtable-now,.js body.research .rtable-pop .rtable-cap{font-size:12px;}
/* Expanded into its dialog, the table keeps its controls in place above it. */
.js body.research .rtable-dialog .rtable-pop{position:static;display:flex;width:auto;box-shadow:none;}
.js body.research .chart-apply,.js body.research [data-rtable-apply]{display:none;}
.js body.research .rtable-pop .rtable-fields{flex-direction:row;flex-wrap:wrap;align-items:center;}
/* Table settings in groups (9 November 2026, option A of the cross tabulation
   mock): Layout, Shares and Rows, each under a small uppercase heading and
   divided by a thin line, 290 px, on every table card. */
.js body.research .chartpop-table,.js body.research .rtable-pop{width:290px;}
body.research .chartpop-grp{display:grid;gap:6px;margin:0;}
body.research .chartpop-h{margin:0;font:700 12px/16px var(--ui);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
body.research .chartpop-sep{height:1px;background:var(--hairline);margin:0;}
body.research .chartpop-two{display:flex;flex-wrap:wrap;gap:6px;}
body.research .chartpop-two > form{margin:0;}
body.research .chartpop-two.rtable-inline{display:grid;grid-template-columns:1fr 1fr;}
/* The two layout buttons side by side, in equal halves. At 290px neither
   label fits on one line in half the width, so each wraps to two, at 12px on
   13px lines, which keeps both at the 30px of every control beside them.
   min-height rather than height, so a longer field name grows the button
   instead of spilling out of it. */
body.research .chartpop-pair{display:grid;grid-template-columns:1fr 1fr;gap:6px;}
body.research .chartpop-pair > form{display:grid;margin:0;}
body.research .chartpop .chartpop-pair .btn{width:100%;height:auto;min-height:30px;padding:1px 6px;
  font-size:12px;line-height:10px;white-space:normal;text-align:center;}
.js body.research .chartpop [data-rtable-tools]{display:flex;flex-direction:column;align-items:stretch;gap:10px;margin:0;}
.js body.research .chartpop .rtable-inline{display:grid;gap:6px;margin:0;}
/* The chart's own lists as wide as the table's under them. */
body.research .chartpop .chart-editor .sel{max-width:none;}

/* ---------- sign in and account (10 November 2026) ----------
   Every sign in, code, reset, invitation, access ended and error page, as
   section A of the Nightjar prototype draws them: the research background,
   no header or menu, the wordmark centred over one white card, and the
   version under it. Scoped to body.auth, which only those pages set beside
   body.research, so their tokens are the shell's and nothing signed in
   changes. */
body.auth .auth-wrap{min-height:100vh;display:flex;flex-direction:column;align-items:center;gap:24px;
  padding:56px 24px 96px;box-sizing:border-box;}
body.auth .auth-brand{display:flex;flex-direction:column;align-items:center;gap:6px;text-align:center;}
body.auth .auth-mark{font-family:var(--display);font-size:34px;line-height:1;letter-spacing:.06em;text-transform:uppercase;
  color:var(--paper);font-weight:400;margin:0;}
body.auth .auth-tag{font-size:15px;line-height:20px;color:var(--muted);}
body.auth .auth-card{width:460px;max-width:100%;box-sizing:border-box;padding:32px;background:#FFFFFF;
  border:1px solid var(--hairline);border-radius:10px;box-shadow:0 1px 2px rgba(13,27,38,.05),0 8px 24px rgba(13,27,38,.06);
  display:flex;flex-direction:column;gap:16px;color:var(--paper);}
body.auth .auth-card.wide{width:520px;}
body.auth .auth-card.err{width:640px;}
body.auth .auth-version{margin:-8px 0 0;font-size:12px;line-height:16px;color:var(--muted);text-align:center;}
body.auth .auth-step{display:inline-flex;align-items:center;gap:10px;align-self:flex-start;height:30px;padding:0 12px 0 4px;
  border-radius:15px;background:#FFFFFF;border:1px solid var(--hairline);font:700 13px/1 var(--ui);color:var(--muted);box-sizing:border-box;}
body.auth .auth-step span{width:22px;height:22px;border-radius:50%;display:grid;place-items:center;background:var(--brand-teal);
  color:#FFFFFF;font-size:12px;}
body.auth .auth-head{display:flex;flex-direction:column;gap:8px;}
body.auth .auth-card h1{margin:0;font:700 24px/1.25 var(--ui);color:var(--paper);letter-spacing:0;text-wrap:balance;}
body.auth .auth-card h2{margin:0;font:700 17px/1.3 var(--ui);color:var(--paper);letter-spacing:0;}
body.auth .auth-lede{margin:0;font-size:15px;line-height:1.55;color:var(--muted);max-width:none;}
body.auth .auth-lede b{color:var(--paper);font-weight:700;}
body.auth .auth-card p{margin:0;}
body.auth .auth-card form{margin:0;display:flex;flex-direction:column;gap:16px;}
body.auth .auth-card fieldset{border:0;padding:0;margin:0;min-width:0;display:flex;flex-direction:column;gap:16px;}
body.auth .field{margin:0;display:flex;flex-direction:column;gap:6px;min-width:0;}
body.auth .field label{font:700 15px/1.3 var(--ui);text-transform:none;letter-spacing:0;color:var(--paper);margin:0;}
body.auth .field .input,body.auth .field input{width:100%;height:44px;min-height:44px;font-size:15px;}
body.auth .auth-card .btn{width:100%;height:44px;min-height:44px;}
body.auth .auth-card .btn.is-submitting[disabled]{opacity:1;}
body.auth .auth-card .btn-spinner{margin-right:0;}
body.auth .auth-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap;}
body.auth .auth-row .btn{width:auto;flex:1 1 auto;}
body.auth .auth-text{appearance:none;-webkit-appearance:none;background:none;border:0;padding:0;margin:0;align-self:flex-start;
  font:600 15px/1.4 var(--ui);color:var(--brand-teal-lift);text-decoration:underline;text-underline-offset:3px;cursor:pointer;}
body.auth .auth-text:hover{color:var(--paper);}
body.auth .auth-text:disabled{color:var(--muted);text-decoration:none;cursor:not-allowed;}
body.auth .auth-text.quiet{font-weight:600;}
body.auth .auth-hint{font-size:13px;line-height:1.5;color:var(--muted);}
body.auth .auth-card .msg{font-size:14px;line-height:1.5;}
body.auth .auth-card .msg ul{margin:0;padding-left:18px;}
/* The message kinds and their icons, read by the account pages, update
   password included (in the shell); no other page draws them. */
body.research .msg-info{background:var(--surface-2);}
body.research .msg-warn{background:var(--warn-wash);border-color:transparent;}
body.research .msg-err{background:var(--err-wash);border-color:transparent;}
body.research .msg .ic{flex:none;width:20px;height:20px;margin-top:0;fill:none;stroke:currentColor;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round;color:var(--brand-teal-lift);}
body.research .msg-ok .ic{color:var(--cleared-ink);}
body.research .msg-warn .ic{color:var(--control-ink);}
body.research .msg-err .ic{color:var(--blocked-ink);}
body.research .msg-err p,body.research .msg-err li{color:var(--paper);}
body.research .msg ul{margin:0;padding-left:18px;}
body.auth .auth-panel{padding:16px 18px;border:1px solid var(--hairline);border-radius:8px;background:var(--surface-2);
  display:flex;flex-direction:column;gap:12px;}
body.auth .auth-panel form{gap:12px;}
body.auth .auth-panel .btn{width:auto;align-self:flex-start;background:#FFFFFF;color:var(--paper);border:1px solid var(--control-border);font-weight:600;}
body.auth .auth-panel .btn:hover{background:var(--surface-2);border-color:var(--control-border-hover);}
body.auth .auth-chip{display:inline-flex;align-items:center;gap:6px;align-self:flex-start;height:24px;padding:0 9px;border-radius:4px;
  font:700 12px/1 var(--ui);white-space:nowrap;}
body.auth .auth-chip .ic{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;}
body.auth .auth-chip.ok{background:var(--ok-wash);color:var(--cleared-ink);}
body.auth .auth-chip.danger{background:var(--err-wash);color:var(--blocked-ink);}
body.auth .auth-chip.warn{background:var(--warn-wash);color:var(--control-ink);}
body.auth .auth-chip.neutral{background:var(--surface-2);color:var(--muted);border:1px solid var(--hairline);}
body.auth .auth-section{display:flex;flex-direction:column;gap:8px;padding:16px 18px;border:1px solid var(--hairline);border-radius:8px;}
body.auth .auth-section ul{margin:0;padding-left:18px;color:var(--muted);font-size:15px;line-height:1.55;}
body.auth .auth-eyebrow{font:700 12px/16px var(--ui);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
body.auth .auth-card a:not(.btn){color:var(--brand-teal-lift);}
body.auth .auth-card a.btn{text-decoration:none;}
body.auth .auth-card .auth-row .btn.ghost{background:transparent;border-color:transparent;color:var(--brand-teal-lift);}
body.auth .auth-card .auth-row .btn.ghost:hover{background:var(--surface-2);}

/* The six digit code: six boxes in one row filling the card, built by
   code-boxes.js from the one input the form posts, which stays and is what
   is sent. Without scripts that input is shown as it is. */
body.auth .codebox-group{display:grid;grid-template-columns:repeat(6,1fr);gap:10px;margin:0;}
body.auth input.codebox{width:100%;min-width:0;height:56px;min-height:56px;padding:0;box-sizing:border-box;border:1px solid var(--control-border);
  border-radius:8px;background:#FFFFFF;color:var(--paper);text-align:center;font:600 24px/1 var(--mono);caret-color:var(--brand-teal);}
body.auth input.codebox.filled{border-color:var(--paper);}
body.auth input.codebox:focus,body.auth input.codebox:focus-visible{outline:none;border:2px solid var(--brand-teal);
  box-shadow:0 0 0 3px rgba(40,89,106,.25);}
body.auth .codebox-group.has-error input.codebox{border-color:var(--err-edge);}
body.auth .codebox-group.has-error input.codebox:focus{border:2px solid var(--err-edge);box-shadow:0 0 0 3px rgba(180,35,24,.2);}
body.auth input.codebox:disabled{background:var(--surface-2);border-color:var(--hairline);cursor:not-allowed;}
body.auth input.codeinput{height:56px;min-height:56px;font:600 24px/1 var(--mono);letter-spacing:.3em;text-align:center;border-radius:8px;
  border:1px solid var(--control-border);}
body.auth input.codeinput[aria-invalid="true"]{border-color:var(--err-edge);}

/* The card fades and lifts away as a code is accepted, as it did. */
body.auth .auth-wrap.leaving{animation:appleave .5s ease both;pointer-events:none;}
@media (prefers-reduced-motion:reduce){body.auth .auth-wrap.leaving{animation:none;}}

/* The error pages, in the same frame. */
body.auth .auth-card.err .auth-head .auth-lede{font-size:16px;}
body.auth .auth-card.err > .btn{width:auto;align-self:flex-start;}
body.auth .auth-section .auth-lede{font-size:15px;}

@media (max-width:600px){
  body.auth .auth-wrap{padding:32px 16px 64px;gap:20px;}
  body.auth .auth-card{padding:24px;}
  body.auth .auth-mark{font-size:30px;}
}
@media (max-width:400px){
  body.auth .codebox-group{gap:8px;}
  body.auth input.codebox{height:48px;min-height:48px;font-size:22px;}
}

/* Refresh on the Nightjar feed while it holds its records (10 November
   2026): the icon turns once, half a second, as the view is fetched again. */
@keyframes oprefresh-turn{to{transform:rotate(360deg);}}
.oprefresh-btn.is-spinning svg{animation:oprefresh-turn .5s ease-in-out;}
@media (prefers-reduced-motion:reduce){.oprefresh-btn.is-spinning svg{animation:none;}}

/* The No restrictions chip's tooltip on a catalogue's card and page (10
   November 2026): the design's tooltip, a white panel under the chip, kept
   inside the window by chip-tip.js. The chip takes focus, with a ring.
   Since 12 November 2026 the same chip, with a warning sign before its
   label, stands in for the note on every page that draws from such a
   catalogue (_controls_off.html), beside the dataset's name, sometimes
   inside an eyebrow or a facts cell, so it sets its own case, spacing and
   box rather than taking theirs. Not held under body.research: the
   geographical dashboard draws its own shell without that class. */
.st.norestrict[data-tip-chip]{display:inline-flex;align-items:center;gap:6px;height:24px;padding:0 9px;border-radius:4px;
  box-sizing:border-box;font:700 12px/1 var(--ui);letter-spacing:normal;text-transform:none;white-space:nowrap;
  vertical-align:middle;background:var(--blocked-wash);color:var(--blocked-ink);cursor:help;}
.st.norestrict[data-tip-chip]:focus-visible{outline:2px solid var(--focus-ink,var(--paper));outline-offset:2px;}
.norestrict-warn{gap:5px;padding-left:7px;}
.norestrict-sign{display:block;flex:none;}
.eyebrow .norestrict-warn,.pagehead-line .norestrict-warn{margin-left:10px;}
.cw-pickers .norestrict-warn{align-self:flex-end;margin-bottom:10px;}
.ntip{display:none;position:fixed;z-index:80;max-width:320px;box-sizing:border-box;padding:10px 12px;
  background:#FFFFFF;border:1px solid var(--hairline);border-radius:8px;box-shadow:0 12px 32px rgba(13,27,38,.14);
  font:400 13px/1.5 var(--ui);letter-spacing:normal;text-transform:none;color:var(--paper);text-align:left;
  white-space:normal;}
.ntip.open{display:block;}
.ntip strong{font-weight:700;}

/* The code workspace (Tier 2, constraint 16). The house tokens throughout;
   the editor itself is themed to match in static/js/code-workspace.js. */
.cw-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;flex-wrap:wrap;}
.cw-pickers{display:flex;align-items:flex-end;gap:12px;flex-wrap:wrap;}
.cw-pick{display:flex;flex-direction:column;gap:4px;font-family:var(--label);text-transform:uppercase;
  letter-spacing:.1em;font-size:12px;color:var(--muted);}
.cw-langs{display:inline-flex;border:1px solid var(--hairline);border-radius:8px;overflow:hidden;background:var(--surface);}
.cw-lang{font:inherit;font-size:13px;padding:7px 14px;border:0;background:transparent;color:var(--text);cursor:pointer;}
.cw-lang.is-on{background:var(--brand-teal);color:#fff;}
.cw-lang:focus-visible{outline:2px solid var(--brand-teal-lift);outline-offset:-2px;}
.cw-lede{max-width:70ch;}
.cw-grid{display:grid;grid-template-columns:260px minmax(0,1fr);gap:16px;align-items:start;margin-top:12px;}
@media (max-width:900px){.cw-grid{grid-template-columns:1fr;}}
.cw-tree{padding:14px;}
.cw-tree-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px;}
.cw-tree-head h4{margin:0;}
.cw-small{height:30px;padding:0 11px;font-size:13px;}
.cw-list{list-style:none;margin:0;padding:0;}
.cw-list .cw-list{padding-left:14px;border-left:1px solid var(--hairline-soft);margin-left:6px;}
.cw-row{display:flex;align-items:center;gap:6px;min-height:30px;}
.cw-folder-name,.cw-script-name{font:inherit;font-size:13px;background:none;border:0;padding:3px 4px;color:var(--paper);
  cursor:pointer;text-align:left;border-radius:4px;overflow-wrap:anywhere;}
.cw-folder-name{font-weight:600;}
.cw-folder-name.is-on{background:var(--teal-wash);}
.cw-script.is-on > .cw-row .cw-script-name{background:var(--teal-wash);}
.cw-folder-name:hover,.cw-script-name:hover{text-decoration:underline;}
.cw-mini{font:inherit;font-size:12px;background:none;border:0;color:var(--brand-teal-lift);cursor:pointer;padding:2px 3px;
  margin-left:auto;}
.cw-mini + .cw-mini{margin-left:0;}
.cw-tag{font-family:var(--mono);font-size:12px;color:var(--muted);border:1px solid var(--hairline);border-radius:4px;padding:0 4px;}
.cw-tree-hint{margin:10px 0 0;}
.cw-bar{display:flex;align-items:center;gap:8px;margin-bottom:8px;flex-wrap:wrap;}
.cw-name{font-weight:600;color:var(--paper);}
.cw-bar-gap{flex:1;}
.cw-editor{height:340px;border:1px solid var(--hairline);border-radius:8px;overflow:hidden;background:var(--surface);}
.cw-win.is-editor .cw-editor{border:0;border-radius:0;}
.cw-win.is-full .cw-editor{height:auto;}
.cw-test{margin-top:10px;}
.cw-fallback{width:100%;height:340px;font-family:var(--mono);font-size:13px;border:1px solid var(--hairline);
  border-radius:8px;padding:10px;}
.cw-fields{margin:8px 0 0;}
.cw-run{margin-top:14px;}
.cw-run-head{display:flex;align-items:center;gap:10px;}
.cw-run-head h4{margin:0;}
.cw-elapsed{margin-left:auto;font-family:var(--mono);font-size:13px;color:var(--muted);}
.cw-stages{list-style:none;margin:12px 0;padding:0;display:grid;gap:6px;}
.cw-stages li{display:flex;align-items:center;gap:10px;color:var(--muted);font-size:14px;}
.cw-dot{width:12px;height:12px;border-radius:50%;border:2px solid var(--hairline);flex:none;}
.cw-stages li[data-state="active"]{color:var(--paper);font-weight:600;}
.cw-stages li[data-state="active"] .cw-dot{border-color:var(--brand-teal);border-right-color:transparent;
  animation:cw-spin .8s linear infinite;}
.cw-stages li[data-state="done"] .cw-dot{background:var(--cleared);border-color:var(--cleared);}
.cw-stages li[data-state="stopped"] .cw-dot{background:var(--blocked);border-color:var(--blocked);}
@keyframes cw-spin{to{transform:rotate(360deg);}}
@media (prefers-reduced-motion:reduce){.cw-stages li[data-state="active"] .cw-dot{animation:none;background:var(--teal-wash);}}
/* The run's verdict, as a card rather than a badge (issue #32).

   Sophia's refusal card is the shape: a sign, the verdict in one short line,
   and under it a plain sentence saying what actually happened ("Blocked:
   record-level output" / "The query returned individual records"). A badge
   alone left the reader to work the second line out, which is the error
   constraint 24 names. The three cards are the gate's own outcomes
   (`CodeRun.Outcome`): passed, withheld and blocked, so nothing here invents
   a state the model cannot produce.

   The colour is the last thing that carries the meaning, never the first:
   the word is in the title, the sign has its own shape per outcome, and the
   tint only agrees with them. */
.cw-verdict{display:flex;align-items:flex-start;gap:12px;margin:0 0 12px;padding:13px 15px;
  border:1px solid var(--hairline);border-left-width:3px;border-radius:8px;background:var(--surface);
  box-shadow:var(--panel-shadow);}
.cw-verdict-sign{flex:none;width:20px;height:20px;margin-top:1px;}
.cw-verdict-body{min-width:0;}
.cw-verdict-title{margin:0;font-size:14px;font-weight:600;color:var(--paper);}
.cw-verdict-said{margin:2px 0 0;font-size:14px;color:var(--muted);}
.cw-verdict.is-passed{border-left-color:var(--cleared);}
.cw-verdict.is-passed .cw-verdict-sign{color:var(--cleared-ink);}
.cw-verdict.is-withheld{border-left-color:var(--control);}
.cw-verdict.is-withheld .cw-verdict-sign{color:var(--control-ink);}
.cw-verdict.is-blocked{border-left-color:var(--blocked);}
.cw-verdict.is-blocked .cw-verdict-sign{color:var(--blocked-ink);}

/* The status bar under the editor: what it is pointed at, and what a count
   is held to. It states and never decides, so nothing in it is a control. */
.cw-status{display:flex;align-items:center;gap:18px;flex-wrap:wrap;margin-top:8px;padding:7px 12px;
  border:1px solid var(--hairline);border-radius:6px;background:var(--surface-2);font-size:13px;}
.cw-status-bit{display:inline-flex;align-items:baseline;gap:6px;min-width:0;}
.cw-status-key{font-family:var(--label);text-transform:uppercase;letter-spacing:.1em;font-size:12px;color:var(--muted);}
.cw-status-val{color:var(--paper);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:28ch;}
.cw-status-gap{flex:1;}
.cw-status-chip{border:1px solid var(--hairline);border-radius:999px;padding:2px 10px;color:var(--muted);
  background:var(--surface);white-space:nowrap;}
.cw-reasons{margin:0 0 10px;padding-left:18px;color:var(--paper);}
.cw-reasons li{margin-bottom:4px;}
.cw-fix{color:var(--muted);}
.cw-warning{font-size:13px;color:var(--control-ink);background:var(--control-wash);border-radius:6px;padding:6px 10px;}
.cw-out{margin-top:14px;}
.cw-out-title{margin:0 0 8px;font-size:14px;color:var(--paper);}
.cw-table-wrap{overflow-x:auto;}
.cw-table{border-collapse:collapse;font-size:13px;min-width:260px;}
.cw-table th,.cw-table td{border-bottom:1px solid var(--hairline-soft);padding:6px 10px;text-align:left;}
.cw-table th{font-family:var(--label);text-transform:uppercase;letter-spacing:.08em;font-size:12px;color:var(--muted);}
.cw-table td.num{text-align:right;font-family:var(--mono);font-variant-numeric:tabular-nums;}
/* Save to Results, and a saved result's own page. */
.cw-keep{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:6px 0 4px;}
.cw-keep-said{font-size:14px;color:var(--paper);}
.cw-saved .cw-out{max-width:760px;}
.cw-saved-code{margin-top:22px;}
.cw-saved-code summary{cursor:pointer;font-size:14px;color:var(--paper);}
.cw-saved-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px;}
.cw-results{margin-top:18px;}
.cw-results-title{font-size:16px;margin:0 0 4px;}
.cw-results-table{width:100%;}
.cw-release{margin-top:22px;max-width:760px;}
.cw-log{font-family:var(--mono);font-size:12.5px;background:var(--surface-2);border:1px solid var(--hairline);
  border-radius:6px;padding:8px 10px;white-space:pre-wrap;}

/* Narrower than 1024: the scripts panel goes above the editor rather than
   beside it, because two columns in that width leave the editor too narrow
   to read a line of code in. The panel keeps its own height and scrolls, so
   a long tree does not push the editor off the screen.

   The status bar is left to wrap on its own. An earlier version of this
   block gave the spacer `flex-basis:100%` to put the chip on its own line,
   which measured 84px tall at 1024 for three rows when everything in it fits
   on one: the four parts come to 586px of the 686 available. Measured in
   Chromium at 1024 wide on 16 November 2026. */
@media (max-width:1024px){
  .cw-grid{grid-template-columns:minmax(0,1fr);}
  .cw-tree{max-height:260px;overflow-y:auto;}
  .cw-status{gap:8px 14px;}
  .cw-status-val{max-width:22ch;}
}

/* ---------- the shared field picker (ISSUES.md BIO-194) ----------
   Every research field list (static/js/field-picker.js): a button where the
   native control was, opening a list fixed beside it with a search, the
   fields under their group headings, Selected and Apply for several. The
   list is at most 70% of the window and never past its edges, with its own
   scroll that does not pass a wheel on to the page. Rows are 40px, label
   left and tick right, in the Nightjar Evidence tokens; text keeps the 7:1
   floor (BIO-126), so a field that cannot be chosen is set apart by italic
   and a tint, not by fading. */
.fpick-native{display:none !important;}
.fpick-button{display:block;width:100%;text-align:left;cursor:pointer;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.fpick-button .fpick-value{pointer-events:none;}
.fpick-button[aria-expanded="true"]{border-color:var(--brand-teal);box-shadow:inset 0 0 0 1px var(--brand-teal);}
.fpick-button[aria-invalid="true"]{border-color:var(--err-edge);}
.fpick-button:disabled{background-color:var(--surface-3);color:var(--muted);cursor:not-allowed;}
.ctlgrid > .field > .fpick-button{grid-row:var(--rc);}
.ctlgrid .fpick-button{appearance:none;-webkit-appearance:none;padding-right:34px;}
.fpick-panel{position:fixed;z-index:70;display:flex;flex-direction:column;box-sizing:border-box;margin:0;
  background:#FFFFFF;border:1px solid var(--hairline);border-radius:8px;box-shadow:0 12px 32px rgba(13,27,38,.14);
  overflow:hidden;font:14px/1.35 var(--ui);color:var(--paper);text-align:left;text-transform:none;letter-spacing:0;}
.fpick-panel[hidden]{display:none;}
.fpick-head{flex:none;display:flex;align-items:center;gap:6px;padding:10px 8px 10px 12px;border-bottom:1px solid var(--hairline);background:#FFFFFF;}
.fpick-panel .fpick-x{flex:none;display:inline-grid;place-items:center;width:32px;height:32px;min-height:0;padding:0;border:0;border-radius:6px;
  background:transparent;color:var(--paper);font:400 18px/1 var(--ui);cursor:pointer;}
.fpick-panel .fpick-x:hover{background:var(--surface-2);}
body.research .fpick-panel input.fpick-search[type="search"]{display:block;flex:1 1 auto;width:auto;min-width:0;min-height:36px;height:36px;margin:0;padding:0 10px;font-size:14px;}
.fpick-panel .fpick-morechips{min-height:28px;padding:2px 6px;border:0;background:none;font:600 13px/18px var(--ui);
  color:var(--brand-teal-lift);text-decoration:underline;cursor:pointer;}
.fpick-body{flex:1 1 auto;min-height:0;overflow:auto;overscroll-behavior:contain;padding:4px 0 8px;}
.fpick-sel{padding:8px 12px 10px;border-bottom:1px solid var(--hairline-soft);}
.fpick-selhead{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:0 0 6px;
  font:700 12px/16px var(--ui);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
.fpick-panel .fpick-clear{min-height:0;padding:2px 4px;border:0;background:none;font:600 13px/18px var(--ui);letter-spacing:0;
  text-transform:none;color:var(--brand-teal-lift);text-decoration:underline;cursor:pointer;}
.fpick-panel .fpick-clear:disabled{color:var(--muted);text-decoration:none;cursor:default;}
.fpick-chips{display:flex;flex-wrap:wrap;gap:6px;}
.fpick-panel .fpick-chip{display:inline-flex;align-items:center;gap:6px;min-height:28px;padding:2px 8px;border:1px solid var(--hairline);
  border-radius:7px;background:var(--surface-2);font:13px/18px var(--ui);color:var(--paper);cursor:pointer;}
.fpick-panel .fpick-chip:hover{border-color:var(--control-border);}
.fpick-chipx{font-size:15px;line-height:1;color:var(--paper);}
.fpick-none{margin:0;font-size:13px;color:var(--muted);}
.fpick-group[hidden],.fpick-rows[hidden],.fpick-row[hidden],.fpick-empty[hidden],.fpick-code[hidden],.fpick-why[hidden]{display:none;}
.fpick-panel .fpick-gh{display:flex;align-items:center;gap:8px;width:100%;min-height:34px;margin:0;padding:0 12px;border:0;border-radius:0;
  background:#FFFFFF;font:700 12px/16px var(--ui);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);text-align:left;cursor:pointer;}
.fpick-panel .fpick-gh:hover{background:var(--surface-2);}
.fpick-gh::before{content:"";flex:none;width:7px;height:7px;margin:0 2px 2px 1px;border-right:2px solid var(--muted);border-bottom:2px solid var(--muted);
  transform:rotate(45deg);}
.fpick-gh[aria-expanded="false"]::before{transform:rotate(-45deg);margin:0 3px 0 0;}
.fpick-gname{flex:1 1 auto;}
.fpick-gn{font-weight:600;letter-spacing:0;}
.fpick-rows{display:grid;grid-template-columns:minmax(0,1fr);}
.fpick-panel.is-wide .fpick-rows{grid-template-columns:repeat(2,minmax(0,1fr));column-gap:4px;padding:0 4px;}
.fpick-row{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:40px;padding:4px 12px;box-sizing:border-box;
  cursor:pointer;font-size:14px;line-height:18px;color:var(--paper);outline:none;border-radius:6px;}
.fpick-row:hover{background:var(--surface-2);}
.fpick-row:focus,.fpick-row:focus-visible{box-shadow:inset 0 0 0 2px var(--focus-ink);}
.fpick-row[aria-selected="true"]{background:var(--row-picked);font-weight:600;}
.fpick-row[aria-disabled="true"]{cursor:not-allowed;font-style:italic;color:var(--text);background:#F3F6F7;}
.fpick-text{display:grid;min-width:0;}
.fpick-label{overflow-wrap:anywhere;}
.fpick-code{font:12px/16px var(--mono);color:var(--muted);font-style:normal;font-weight:400;overflow-wrap:anywhere;}
.fpick-why{font-size:12px;line-height:16px;color:var(--text);font-weight:400;}
.fpick-row mark{background:var(--warn-wash);color:inherit;font-weight:700;text-decoration:underline;text-underline-offset:2px;padding:0;}
.fpick-tick{flex:none;width:18px;height:18px;box-sizing:border-box;border:1.5px solid var(--control-border);border-radius:4px;background:#FFFFFF;}
.fpick-single .fpick-tick{border-radius:50%;}
.fpick-row[aria-selected="true"] .fpick-tick{border-color:var(--brand-teal);background:var(--brand-teal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='10' viewBox='0 0 12 10'%3E%3Cpath d='M1 5l3.5 3.5L11 1.5' fill='none' stroke='%23FFFFFF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center;}
.fpick-row[aria-disabled="true"] .fpick-tick{border-style:dashed;background:transparent;}
.fpick-panel .fpick-more{display:block;width:calc(100% - 24px);min-height:36px;margin:6px 12px 0;padding:0;border:0;background:none;
  font:600 13px/18px var(--ui);color:var(--brand-teal-lift);text-decoration:underline;text-align:left;cursor:pointer;}
.fpick-empty{margin:12px;font-size:14px;color:var(--paper);}
.fpick-foot{flex:none;display:flex;align-items:center;gap:10px;padding:8px 12px;border-top:1px solid var(--hairline);background:#FFFFFF;}
.fpick-status{flex:1 1 auto;min-width:0;margin:0;font-size:12px;line-height:16px;color:var(--muted);}
.fpick-actions{flex:none;display:flex;justify-content:flex-end;gap:8px;}
body.research .fpick-panel .btn{min-height:30px;height:30px;padding:0 12px;font-size:13px;}

/* ---------- a project's sessions (#35) ----------
   Sophia's notebook launcher: a card for each tool, its Start below, and when
   one is live the bar in its place, a green dot for running, with Stop and
   Open. Two tools side by side where there is room, one above the other on a
   narrow screen. */
.sess .sess-offers{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,340px),1fr));gap:16px;margin:4px 0 8px;}
.sess-tool{display:flex;flex-direction:column;gap:14px;}
.sess-tool-head h4{margin:0 0 4px;}
.sess-tool-head .hint{margin:0;}
.sess-start{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px;}
.sess-start .hint{flex-basis:100%;margin:0;}
.sess-size{display:flex;flex-direction:column;gap:6px;min-width:0;flex:1 1 200px;}
.sess-size span{font-size:12px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
.sess-bar{display:flex;flex-wrap:wrap;align-items:center;gap:10px 12px;padding:12px 14px;border:1px solid var(--hairline);
  border-radius:8px;background:var(--surface-3);}
.sess-bar.is-running{background:var(--cleared-wash);}
.sess-dot{width:10px;height:10px;border-radius:50%;background:var(--control);flex:none;}
.sess-bar.is-running .sess-dot{background:var(--cleared);}
.sess-status{flex:1 1 220px;display:flex;flex-direction:column;gap:2px;min-width:0;font-size:14px;}
.sess-left{font-size:13px;color:var(--dim);font-variant-numeric:tabular-nums;}
.sess-inline{display:inline;margin:0;}
.sess-limits{margin:4px 0 20px;}
.sess-books,.sess-recent{margin-top:16px;}
.sess-books h4,.sess-recent h4{margin:0 0 8px;}
.sess-books .sess-sub{margin:24px 0 8px;}
.sess-table{overflow-x:auto;}
.sess-table table{width:100%;}
.sess-act{text-align:right;white-space:nowrap;}
.sess-files{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px;}
.sess-files li{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;max-width:none;}
/* At a phone's width the notebook keeps its name, its versions and Open, and
   drops Last saved, rather than scrolling Open out of sight in its table. */
@media (max-width:600px){.sess-books th:nth-child(3),.sess-books td:nth-child(3){display:none;}
  .sess-act{white-space:normal;}.sess-act .btn{white-space:normal;text-align:center;}}

/* ---------------------------------------------------------------------------
   The project screens (#24), to Sophia's Nightjar design.

   Her Dashboard is a two column grid of project cards over a count row; her
   project page is a four step bar over the step's own panels. The measurements
   are hers, read from her prototype at 1440: a 36 px control, a 6 px corner on
   a control and 8 px on a panel, 15/700 for a heading inside a card, 13 px for
   the line under it.

   Nothing here decides anything. Every dataset on these screens came from
   `service.reachable`, which is the access chain, and the server refuses a
   version it did not give (constraint 5).
--------------------------------------------------------------------------- */
.msg-bad{background:var(--bad-wash,#FBEAEA);border-color:transparent;}

/* The Dashboard (#115), her values from Main.dc.html: a 22/700 greeting, her
   joined tab bar (a 4 px well on the chip ground, 6 px tabs, 16/600, the
   current one filled teal), New project on the right, a full width search
   and the cards, auto-fill at a 520 px minimum, so four sit across a wide
   screen and fewer as it narrows. */
.dash{display:flex;flex-direction:column;gap:15px;}
/* Her header band: sticky under the header, lighter, from the top of the
   content to under the tab bar, full width of the content column. */
.dashhead{position:sticky;top:54px;z-index:8;margin:-18px -24px 0;padding:13.5px 24px 10.5px;display:flex;flex-direction:column;gap:10.5px;
  background:rgba(234,239,243,0.9);-webkit-backdrop-filter:blur(10.5px);backdrop-filter:blur(10.5px);}
.dashhi{margin:0;font-size:16px;font-weight:700;line-height:1.45;min-height:36px;display:flex;align-items:center;}
.dashbar{display:flex;align-items:center;gap:12px;height:49.5px;}
.dashnew{flex:none;white-space:nowrap;}
.dashbar .grow{flex:1;}
.dashnew svg{flex:none;}
/* Her secondary button (ghost): 44 px, the chip ground, a control edge. */
body.research .btn.njghost{min-height:33px;height:33px;padding:0 12px;background:rgba(255,255,255,0.72);border:1px solid var(--control-border);
  color:var(--paper);font-size:12px;font-weight:600;white-space:nowrap;}
body.research .btn.njghost:hover{background:rgba(255,255,255,0.95);}
.dashstop{margin:0;flex:none;}

/* Her joined tab bar, shared: Dashboard, Settings and any page with tabs. */
.jtabs{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);gap:3px;padding:3px;box-sizing:border-box;
  border-radius:6px;background:rgba(255,255,255,0.72);border:1px solid var(--hairline);max-width:100%;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:thin;}
.dashtabs{flex:0 1 auto;min-width:0;grid-auto-columns:142.5px;}
.jtab{position:relative;display:flex;align-items:center;justify-content:center;height:42px;padding:0 7.5px;
  border-radius:4.5px;font-size:12px;font-weight:600;color:var(--muted);text-decoration:none;white-space:nowrap;min-width:0;}
body.research a.jtab{color:var(--muted);}
.jtab:hover{background:rgba(255,255,255,0.95);}
body.research a.jtab.on,.jtab.on{background:var(--brand-teal);color:#FFFFFF;}
/* Her divider: a 1 px line between two tabs neither of which is current. */
.jtab + .jtab:not(.on)::before{content:"";position:absolute;left:-3px;top:9px;bottom:9px;width:1px;background:var(--control-border);}
.jtab.on + .jtab::before{display:none;}
.jtab:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}

.dashsearch{position:relative;display:flex;align-items:center;margin:0;}
.dashsearch svg{position:absolute;left:10.5px;color:var(--muted);pointer-events:none;}
body.research .dashsearch input[type="search"]{width:100%;height:36px;padding:0 9px 0 31.5px;background:#FFFFFF;}
.dashnone{margin:0;padding:27px;text-align:center;border-style:dashed;border-color:var(--control-border);color:var(--muted);}

.pjgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(345px,100%),1fr));gap:12px;align-items:start;}
.pjcard{display:flex;flex-direction:column;gap:12px;padding:13.5px 15px;text-decoration:none;color:inherit;min-width:0;}
body.research a.pjcard{color:var(--text);}
.pjcard:hover{border-color:var(--control-border);}
.pjcard.is-current{border-color:var(--brand-teal);}
.pjcard.is-closed{opacity:.72;}
.pjcard-top{display:flex;align-items:flex-start;gap:9px;width:100%;}
.pjcard-titles{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px;}
.pjcard-name{font-size:13px;font-weight:700;line-height:1.3;overflow-wrap:anywhere;}
.pjcard-by{font-size:12px;color:var(--muted);}
.pjfaces{flex:none;display:flex;align-items:center;}
.pjface{width:24px;height:24px;box-sizing:border-box;border-radius:50%;border:2px solid #FFFFFF;display:flex;align-items:center;
  justify-content:center;background:var(--teal-wash);color:var(--brand-teal-lift);font-size:12px;font-weight:700;}
.pjface + .pjface{margin-left:-6px;}
.pjmore{margin-left:4.5px;font-size:12px;color:var(--muted);}
.pjcard-sets{display:flex;align-items:center;flex-wrap:wrap;gap:4.5px;width:100%;}

/* The four segments on a card: where the project has got to, as a shape
   rather than a number, her 6 px bars with the label under each. */
.pjbar{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:3px;margin:0;padding:0;list-style:none;width:100%;}
.pjbar li{min-width:0;display:flex;flex-direction:column;gap:4.5px;}
.pjbar li::before{content:"";display:block;height:4.5px;border-radius:3px;background:var(--surface-3);}
.pjbar li.is-on::before,.pjbar li.is-done::before{background:var(--brand-teal);}
.pjbar li span{display:block;font-size:12px;font-weight:500;color:var(--muted);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.pjbar li.is-on span{color:var(--paper);font-weight:700;}

.pjchip{display:inline-flex;align-items:center;gap:4.5px;height:19.5px;padding:0 7.5px;box-sizing:border-box;
  border:1px solid var(--hairline);border-radius:3px;background:rgba(255,255,255,0.72);font-size:12px;font-weight:600;
  color:var(--muted);max-width:195px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.pjchip .dbic{flex:none;color:var(--muted);}
.pjchip.is-none{font-style:italic;font-weight:500;}
.pjstate{margin-left:auto;display:inline-flex;align-items:center;height:19.5px;padding:0 7.5px;box-sizing:border-box;border-radius:3px;
  background:var(--surface-2);font-size:12px;font-weight:700;color:var(--text);white-space:nowrap;}
.pjstate.is-current{background:var(--teal-wash);color:var(--brand-teal-lift);}
.pjstate.is-closed{background:var(--surface-3);color:var(--muted);}

/* Her Datasets tiles: 300 px minimum. */
.dsgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(225px,100%),1fr));gap:12px;}
.dstile{display:flex;flex-direction:column;gap:2px;padding:12px 13.5px;min-width:0;}
.dstile-name{font-size:12px;font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.dstile-name .mono{font-weight:500;color:var(--muted);}
.dstile-big{margin-top:7.5px;font-size:20px;font-weight:500;letter-spacing:-0.02em;}
.dstile-sub{font-size:12px;color:var(--muted);}
.dashtable{overflow-x:auto;}
.dashtable td.mono{white-space:nowrap;}

.pjempty{padding:16.5px 18px;max-width:480px;}
.pjempty h2{margin:0 0 6px;font-size:13px;}
.pjleave{display:flex;align-items:center;gap:9px;flex-wrap:wrap;margin:0;}
.pjleave .hint{margin:0;}

/* A project's own page (#115), her values: the back button (44 px, chip
   ground, chevron), the name at 22/700 and the meta line at 14 px, then her
   stepper panel, 66 px high, a 32 px ring per step joined by 2 px lines, the
   step's actions on the right. */
.pjtop{display:flex;align-items:center;gap:9px;min-height:36px;margin:0;}
/* Her band on a project page too: the back button, the name and the stepper
   on the lighter sticky ground, as on the Dashboard. */
.pjband{position:sticky;top:54px;z-index:8;margin:-18px -24px 15px;padding:13.5px 24px 10.5px;display:flex;flex-direction:column;gap:10.5px;
  background:rgba(234,239,243,0.9);-webkit-backdrop-filter:blur(10.5px);backdrop-filter:blur(10.5px);}
.pjband .pjstep{margin:0;}
body.research .pjback{flex:none;min-height:33px;height:33px;gap:6px;padding:0 12px 0 7.5px;background:rgba(255,255,255,0.72);font-size:12px;font-weight:600;}
.pjtitle{flex:1;min-width:0;display:flex;flex-direction:column;line-height:1.25;margin-left:4.5px;}
.pjtitle h1{margin:0;font-size:16px;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.pjsub{display:flex;align-items:center;gap:4.5px;flex-wrap:wrap;margin:0;font-size:12px;color:var(--muted);}

.pjstep{display:flex;align-items:center;gap:18px;min-height:49.5px;padding:0 9px 0 13.5px;margin:0 0 15px;box-sizing:border-box;}
.pjstep-list{flex:1;min-width:0;display:flex;align-items:center;margin:0;padding:0;list-style:none;}
.pjstep-list > li{display:flex;align-items:center;flex:1;min-width:0;}
.pjstep-list > li:last-child{flex:none;}
.pjstep-list > li:not(:last-child)::after{content:"";flex:1;min-width:9px;height:2px;margin:0 7.5px;border-radius:1px;background:var(--control-border);}
.pjstep-list > li.is-done:not(:last-child)::after{background:var(--brand-teal);}
.pjstep-box{flex:none;display:flex;align-items:center;gap:7.5px;height:36px;padding:0 9px 0 3px;box-sizing:border-box;
  border:0;border-radius:4.5px;background:transparent;font:700 12px/1 var(--ui);color:var(--muted);text-decoration:none;white-space:nowrap;}
body.research a.pjstep-box{color:var(--muted);}
a.pjstep-box:hover{background:rgba(255,255,255,0.95);}
.pjstep-list > li.is-on > .pjstep-box{color:var(--paper);}
.pjstep-list > li.is-off > .pjstep-box{color:var(--muted);opacity:.7;}
.pjstep-t{min-width:0;overflow:hidden;text-overflow:ellipsis;}
.pjstep-n{flex:none;display:flex;align-items:center;justify-content:center;width:24px;height:24px;box-sizing:border-box;border-radius:50%;
  border:1.5px solid var(--control-border);background:rgba(255,255,255,0.72);color:var(--muted);font-size:12px;}
.pjstep-n .mono{font-size:12px;font-weight:600;}
.pjstep-list > li.is-on .pjstep-n{background:var(--brand-teal);border-color:var(--brand-teal);color:#FFFFFF;}
.pjstep-list > li.is-done .pjstep-n{background:var(--teal-wash);border-color:var(--brand-teal);color:var(--brand-teal-lift);}
.pjstep-act{flex:none;display:flex;align-items:center;gap:6px;}
.pjstep-note{margin:-9px 0 12px;}

/* Her fields: small uppercase labels, two columns, the purpose across both. */
.pjform{padding:15px;margin:0;}
.pjfields{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:15px;}
.pjfield{display:flex;flex-direction:column;gap:4.5px;min-width:0;}
.pjfield-wide{grid-column:1 / -1;}
.pjlabel,body.research .pjfield label.pjlabel{font-size:12px;font-weight:700;letter-spacing:0.06em;text-transform:uppercase;color:var(--muted);}
.pjfields .ihelp{max-width:none;margin:0;font-size:12px;color:var(--muted);}
.pjfields .input,.pjfields .ta{width:100%;}
.pjdate-fixed{display:block;line-height:33px;font-size:12px;text-align:left;}

.pjsec{margin:15px 0 0;padding:0;overflow:visible;}
.pjsec-head{display:flex;align-items:center;gap:7.5px;height:42px;padding:0 9px 0 13.5px;border-bottom:1px solid var(--hairline);}
.pjsec-head h2{flex:1;margin:0;font-size:13px;font-weight:700;}
.pjsec > .hint,.pjsec-note{max-width:none;margin:0;padding:10.5px 13.5px;}
.pjsec-note{border-top:1px solid var(--hairline);font-size:12px;}
.pjlist{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;}
body.research .pjitem{max-width:none;display:flex;align-items:center;gap:9px;min-height:48px;padding:6px 9px 6px 13.5px;box-sizing:border-box;border-top:1px solid var(--hairline);}
.pjitem:first-child{border-top:0;}
.pjitem > .dbic{flex:none;width:15px;height:15px;color:var(--muted);}
.pjitem form{margin:0;}
/* Her remove control: a 40 px square with a cross, named for a screen reader. */
body.research .pjx{width:30px;height:30px;min-height:30px;padding:0;display:flex;align-items:center;justify-content:center;
  border:1.5px solid var(--control-border);border-radius:3px;background:transparent;color:var(--paper);cursor:pointer;}
body.research .pjx:hover{background:rgba(255,255,255,0.95);}
.pjitem-main{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1 1 auto;}
.pjitem-name{font-size:12px;font-weight:700;overflow-wrap:anywhere;}
.pjitem-name .mono{font-weight:500;color:var(--muted);}
.pjitem-sub{font-size:12px;}
.pjitem-sub.hint{margin:0;}
.pjadd{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin:0;padding:10.5px 13.5px 13.5px;border-top:1px solid var(--hairline);}
.pjadd .sel{width:auto;min-width:0;max-width:none;flex:1 1 165px;}
.pjdates{flex-direction:row;align-items:flex-end;gap:9px;flex-wrap:wrap;}
.pjdates .input{width:auto;min-width:0;flex:0 1 135px;}
.pjdates .ilabel-sub{font-size:12px;color:var(--muted);}

/* Her grid is two columns at 1440 and one below about 1100, where two cards
   stop holding a dataset chip without cutting it. The stepper stays four
   across, because four short words fit at 1024 and a wrapped stepper reads as
   two groups of steps rather than one. */
/* Narrower, the stepper keeps four rings in one row and drops the labels of
   the steps not open, which the ring's number still names; the fields go to
   one column. */
@media (max-width:900px){
  .pjstep{gap:9px;}
  .pjstep-list > li:not(.is-on) .pjstep-t{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);}
  .pjstep-box{padding:0 4.5px 0 3px;}
}
@media (max-width:720px){
  .pjfields{grid-template-columns:minmax(0,1fr);}
  .dashbar{flex-wrap:wrap;}
  .dashtabs{flex:1 1 100%;}
}
.pjdate-fixed{display:flex;flex-direction:column;gap:3px;padding:0 0 7px;}
.pjdate-fixed strong{font-size:12px;}

/* The project's working steps (#25): Sophia's list on the left and the step's
   own panel on the right, and her Release step's two columns. One column
   below 1100, where the list and the panel stop holding a dataset name side
   by side. */
.pjwork{display:grid;grid-template-columns:240px minmax(0,1fr);gap:12px;align-items:start;}
.pjside,.pjmain{padding:0;margin:0;overflow:hidden;}
.pjside .pjsec-head h2,.pjmain .pjsec-head h2{flex:1;margin:0;font-size:13px;font-weight:700;}
.pjmain > p,.pjmain > .hint,.pjside > p,.pjside > .hint,.pjempty-step > p{max-width:none;margin:0;padding:10.5px 13.5px;}
.pjmain > p + p,.pjempty-step > p + p{padding-top:0;}
.pjmain > .pjsec-note{border-top:1px solid var(--hairline);padding-top:10.5px;}
.pjmain > :not(.pjsec-head):not(p):not(.hint){margin:10.5px 13.5px;}
.pjactions{display:flex;align-items:center;gap:7.5px;flex-wrap:wrap;margin:0;padding:0 13.5px 13.5px;}
.pjsec-head .pjstate{margin-left:0;}
.pjmain > .pjactions,.pjempty-step > .pjactions{padding:3px 13.5px 13.5px;}
.pjmain > .note{margin:0 13.5px 13.5px;padding:9px 10.5px;}
.pjsec-head h2 .mono{font-weight:500;color:var(--muted);}
.pjrel{display:flex;flex-direction:column;gap:12px;}
.pjrel > .pjsec,.pjempty-step{margin-top:0;}
.pjrel-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,240px);gap:15px;margin:0;padding:0 13.5px 13.5px;
  align-items:start;}
.pjrel-h{margin:0 0 6px;font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.06em;
  color:var(--muted);}
/* Her status list: a dot per step, joined, filled once the step has happened.
   Four steps and not her five, because there is no reviewer (constraint 14). */
.pjtime{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:0;}
.pjtime li{position:relative;padding:0 0 12px 16.5px;font-size:12px;color:var(--muted);}
.pjtime li:last-child{padding-bottom:0;}
.pjtime li::before{content:"";position:absolute;left:0;top:3px;width:7.5px;height:7.5px;border-radius:50%;
  border:2px solid var(--control-border);background:#FFFFFF;box-sizing:border-box;}
.pjtime li::after{content:"";position:absolute;left:3px;top:12px;bottom:0;width:2px;background:var(--hairline);}
.pjtime li:last-child::after{display:none;}
.pjtime li.is-done{color:var(--paper);font-weight:600;}
.pjtime li.is-done::before{border-color:var(--brand-teal);background:var(--brand-teal);}
@media (max-width:1100px){
  .pjwork{grid-template-columns:minmax(0,1fr);}
  .pjrel-grid{grid-template-columns:minmax(0,1fr);}
}
/* A step is a box, not a sentence with a link in it. */
a.pjstep-box,body.research a.pjstep-box{text-decoration:none;color:var(--paper);}
a.pjstep-box:hover{background:var(--surface-2);border-color:var(--control-border);}
a.pjstep-box:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
/* ---------------------------------------------------------------------------
   The administration tables (#26): one named container, applied to all of
   them.

   The pattern was already here and already right. Seven of the tables sat in
   `<div style="overflow-x:auto">`, written out inline each time, and ten did
   not: the two on a catalogue's restrictions, the members table on a group,
   an organisation's card and its page, two of a person's five and one of
   Invitations' four. A table in the container cannot widen the page; a table
   outside it can.

   None of them does today, because `.rowtable` is `width:100%` and wraps to
   whatever it is given. Measured across 15 administration pages at 620, 768,
   900, 1024, 1280 and 1440 in both engines, with 7 catalogues, 7 groups, 19
   agreements, 12 people and a 118 character catalogue name: nothing ran off
   the right. So this closes a latent inconsistency rather than a live defect,
   and the walk's overflow check is what would catch it if the wrapping ever
   stopped saving us.

   No sticky first column. These tables wrap rather than scroll, so a sticky
   column would be a control that never fires (constraint 21). It belongs with
   whatever first makes one of them genuinely scroll.
--------------------------------------------------------------------------- */
.rowtable-wrap{overflow-x:auto;max-width:100%;}

.rowtable td.rt-prose,.rowtable th.rt-prose{text-align:left;padding-right:0;}
.rowtable td.rt-prose{line-height:1.5;}
.rowtable td.rt-num,.rowtable th.rt-num{text-align:right;white-space:nowrap;padding-right:28px;}
.rowtable td:last-child.rt-num,.rowtable th:last-child.rt-num{padding-right:0;}
/* A Settings row entry that is not a setting: Catalogue, Audit trail,
   Instructions for use and Contact us sit under Settings once the menu is the
   Dashboard and one Settings link, so this row is the only place they can be
   clicked (17 November 2026). Drawn quieter, so the settings proper read
   first, and still a link. */
.settingstab.settingstab-other{color:var(--muted);}
body.research .settingstab.settingstab-other.on{color:#FFFFFF;}

/* ---------- Messages (#112), Sophia's Main.dc.html ----------
   Her values as she draws them at 1440 (her numbers times 0.75):
   a 420 px list beside the thread, her 44 px All / Unread / Alerts bar, 84 px
   rows with a 3 px bar on the open one, her pills, a 560 px thread with its
   head, its messages in 8 px boxes and the reply foot. At 768 px and below
   the list sits above the thread. */
.msgs{display:grid;grid-template-columns:315px minmax(0,1fr);gap:12px;align-items:start;}
.msgs-side{display:flex;flex-direction:column;gap:9px;min-width:0;}
.msgtabs{grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-flow:row;}
.msgtabs .jtab{height:33px;font-size:12px;}
.msglist{overflow:hidden;padding:0;}
.msglist ul{list-style:none;margin:0;padding:0;}
.msglist li{max-width:none;margin:0;}
.msglist li + li{border-top:1px solid var(--hairline);}
.msgrow{position:relative;display:flex;flex-direction:column;justify-content:center;gap:3px;min-height:63px;padding:7.5px 12px 7.5px 13.5px;
  box-sizing:border-box;color:var(--text);text-decoration:none;}
body.research a.msgrow{color:var(--text);}
.msgrow:hover{background:rgba(255,255,255,0.95);}
.msgrow.is-on{background:var(--surface-2);}
.msgrow.is-on::before{content:"";position:absolute;left:0;top:0;bottom:0;width:3px;background:var(--brand-teal);}
.msgrow-top{display:flex;align-items:center;gap:6px;width:100%;}
.msgpill{flex:none;height:18px;display:inline-flex;align-items:center;gap:4.5px;padding:0 7px;box-sizing:border-box;border-radius:3px;
  font-size:12px;font-weight:700;white-space:nowrap;background:var(--teal-wash);color:var(--brand-teal-lift);}
.msgpill.is-alert{background:var(--warn-wash);color:#604400;}
.msgrow-title{flex:1;min-width:0;font-size:12px;font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.msgrow-title.is-unread{font-weight:700;}
.msgdot{flex:none;width:6px;height:6px;border-radius:50%;background:var(--brand-teal);}
.msgrow-last{font-size:12px;color:var(--muted);width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.msgrow-who{font-size:12px;color:var(--muted);}
.msgnone{max-width:none;margin:0;padding:21px;text-align:center;color:var(--muted);}

.msgthread{display:flex;flex-direction:column;min-height:420px;padding:0;overflow:hidden;}
.msgthread-head{display:flex;align-items:center;gap:9px;padding:10.5px 10.5px 10.5px 15px;border-bottom:1px solid var(--hairline);}
.msgthread-titles{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px;}
.msgthread-top{display:flex;align-items:center;gap:6px;min-width:0;}
.msgthread-title{font-size:13px;font-weight:700;overflow-wrap:anywhere;}
.msgthread-ctx{font-size:12px;color:var(--muted);}
body.research .btn.msgopen{min-height:30px;height:30px;}
.msgthread-body{flex:1;padding:15px;display:flex;flex-direction:column;gap:10.5px;}
.msgitem{display:flex;flex-direction:column;gap:3px;max-width:80%;}
.msgitem-who{font-size:12px;color:var(--muted);}
.msgitem-text{padding:9px 10.5px;border-radius:6px;background:var(--surface-2);line-height:1.5;overflow-wrap:anywhere;}
.msgitem-text.is-alert{background:var(--warn-wash);}
.msgitem-text.is-mine{background:var(--teal-wash);}
.msgreply{display:flex;flex-direction:column;gap:6px;padding:10.5px 13.5px 13.5px;border-top:1px solid var(--hairline);margin:0;}
.msgreply-row{display:flex;gap:6px;}
body.research .msgreply input[type="text"]{flex:1;height:33px;min-width:0;}
@media (max-width:768px){
  .msgs{grid-template-columns:minmax(0,1fr);}
}

/* Her unread count on Messages in the menu, and its place on the rail. */
body.research .rail-count{margin-left:auto;min-width:19.5px;height:16.5px;padding:0 5px;box-sizing:border-box;border-radius:8px;display:inline-flex;
  align-items:center;justify-content:center;background:var(--teal-wash);color:var(--brand-teal-lift);font-weight:500;font-size:12px;}
body.research .rail a.on .rail-count{background:rgba(255,255,255,0.18);color:#FFFFFF;}
html.app-railshut body.research .rail-count{position:absolute;top:3px;right:2px;min-width:15px;height:13.5px;padding:0 4px;font-size:12px;}
@media (max-width:1024px){
  body.research .rail-count{position:absolute;top:3px;right:2px;min-width:15px;height:13.5px;padding:0 4px;font-size:12px;}
  html.app-draweropen body.research .rail-count{position:static;min-width:19.5px;height:16.5px;padding:0 5px;font-size:12px;}
}

/* ---------- Her component styles, measured (#115, sophia-match) ----------
   Read from her Main.dc.html in a browser on 18 November 2026, component by
   component (`docs/design/sophia-match/styles.md`), and kept here as tokens
   and one rule per component, so every page takes them from one place.
   Two departures, both recorded there: muted text stays at 7:1 (BIO-126)
   and no text goes under 12 px. */
body.research{
  --nj-chip:rgba(255,255,255,0.72);      /* her --chip: control grounds, secondary buttons, pills */
  --nj-chip-hover:rgba(255,255,255,0.95);/* her --chip-hover */
  --nj-float:rgba(255,255,255,0.96);     /* her --float: the AI panel */
  --nj-shadow:0 9px 24px rgba(13,27,38,0.14); /* her --shadow */
  --nj-row-picked:#EEF2F3;               /* her open row */
  --nj-avatar:#D3E4E8;--nj-avatar-ink:#1E3F4A; /* her avatar */
  line-height:1.45;                      /* her body: 15 px on 21.75 */
  --label:"IBM Plex Sans","Inter",system-ui,sans-serif; /* her small labels are Plex, not a condensed face */
}
/* Her small uppercase label: 12/700, 0.06em, the secondary ink. */
body.research .eyebrow,body.research .rail-h,body.research .pagehead .eyebrow{font-family:var(--ui);font-size:12px;font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
body.research .rail-count[hidden]{display:none;}
body.research h1,body.research h2,body.research h3,body.research h4{letter-spacing:normal;}

/* Controls: her chip ground on every field; the Dashboard's search keeps
   her white surface. */
body.research .input,body.research .ta,body.research .sel,body.research input[type="text"],body.research input[type="email"],
body.research input[type="password"],body.research input[type="date"],body.research input[type="number"],
body.research select,body.research textarea:not(#querytext){background-color:var(--nj-chip);line-height:1.45;}
body.research .dashsearch input[type="search"]{background:#FFFFFF;}

/* Buttons: one primary, one secondary, one ghost link, each hers. */
body.research .btn,body.research .jtab,body.research .settingstab,body.research .pjstep-box{line-height:normal;}
body.research .btn.ghost,body.research .btn.njghost,body.research .pjback{background:var(--nj-chip);}
body.research .btn.ghost:hover,body.research .btn.njghost:hover,body.research .pjback:hover{background:var(--nj-chip-hover);}
body.research .btn.ghost:not(.pjback),body.research .btn.njghost{padding:0 12px;}
body.research .njlink{display:inline-flex;align-items:center;gap:4.5px;height:27px;padding:0 7.5px;border:0;border-radius:3px;background:transparent;
  color:var(--brand-teal-lift);font:700 12px/1 var(--ui);white-space:nowrap;cursor:pointer;text-decoration:none;}
body.research .njlink:hover{background:var(--nj-chip-hover);}
body.research .njlink svg{flex:none;}

/* Her pill, wherever a row or a header carries one. */
body.research .njpill,body.research .pjitem .pjstate,body.research .pjstep-act .pjstate{height:18px;display:inline-flex;align-items:center;gap:4.5px;
  padding:0 7px;border-radius:3px;font-size:12px;font-weight:700;white-space:nowrap;background:var(--nj-chip);color:var(--muted);margin-left:0;}

body.research .pjface{background:var(--nj-avatar);color:var(--brand-teal-lift);}
body.research .msgrow.is-on{background:var(--nj-row-picked);}

/* Her tables: the head in small uppercase on the sunk ground, rows 56 px
   with a line between them and no ground of their own. */
/* Lists of things (the panels' tables), not the result tables, whose own
   density is how they are read. */
body.research :is(.table-wrap,.tablescroll,.dashtable,.sess-table) th{height:33px;padding:0 10.5px;font:700 12px/1.45 var(--ui);letter-spacing:.06em;
  text-transform:uppercase;color:var(--muted);background:var(--surface-2);border-bottom:1px solid var(--hairline);white-space:nowrap;}
body.research :is(.table-wrap,.tablescroll,.dashtable,.sess-table) td{height:42px;padding:0 10.5px;font-size:12px;background:transparent;border-bottom:0;
  border-top:1px solid var(--hairline);}
body.research :is(.table-wrap,.tablescroll,.dashtable,.sess-table) tbody tr:first-child td{border-top:0;}

/* Her empty state. */
body.research .card.dashnone,body.research .dashnone{border:1px dashed var(--control-border);color:var(--muted);background:var(--panel-fill);}

/* Her Settings bar: the content's width up to 1100 px, the tabs sharing it. */
body.research .settingstabs-row{width:100%;max-width:825px;}
body.research .settingstab{flex:1 0 auto;padding:0 7.5px;}

/* Her AI panel: a floating card 24 px in from the right and the bottom. */
body.research .aipanel:not(.full){top:54px;right:18px;bottom:18px;width:345px;border:1px solid var(--hairline);border-radius:6px;
  box-shadow:var(--nj-shadow);background:var(--nj-float);overflow:hidden;}
/* Full screen keeps her card's top, under the header, so Full screen and
   Exit full screen stay where they were pressed (the scroll sweep, #136). */
body.research .aipanel.full{top:54px;border-top:1px solid var(--hairline);}
@media (max-width:599px){
  body.research .aipanel:not(.full){top:0;right:0;bottom:0;width:100%;border-radius:0;}
  body.research .aipanel.full{top:0;border-top:0;}
}

/* Her card header action (#115): Add dataset and Add person as her ghost
   links at the right of the header, each opening our picker under it as her
   floating panel. A details element: no script, and Escape-free closing by
   the same link. */
body.research .pjsec{position:relative;}
.njpick{position:static;}
.njpick > summary{list-style:none;}
.njpick > summary::-webkit-details-marker{display:none;}
body.research .njpick-panel{position:absolute;top:42px;right:9px;z-index:20;width:min(345px,calc(100% - 18px));margin:0;padding:9px;
  display:flex;gap:6px;align-items:center;border:1px solid var(--hairline);border-radius:6px;background:var(--nj-float);box-shadow:var(--nj-shadow);}
body.research .njpick-panel .sel{flex:1 1 auto;min-width:0;}
/* Her release status on the stepper, and her Next with its chevron. */
.njstatus{display:inline-flex;align-items:center;height:18px;padding:0 7px;font-size:12px;font-weight:700;color:var(--paper);white-space:nowrap;}
body.research .btn.njnext svg{flex:none;}

body.research .njlink:disabled{opacity:.45;cursor:not-allowed;background:transparent;}

/* The researcher view's one line (#115, Nick): small grey text under the
   Viewing as switch, inside the name menu, and nowhere else. */
body.research .whopanel .roleview-note{margin:0;padding:0 7.5px 6px;font-size:12px;line-height:1.35;color:var(--muted);max-width:none;}

/* Her Release step (#115): each request's line, then two cards side by side. */
.pjrelone{display:flex;flex-direction:column;gap:9px;}
.pjrelone-head{display:flex;align-items:center;gap:7.5px;flex-wrap:wrap;}
.pjrelone-head h2{margin:0;font-size:13px;font-weight:700;}
.pjrelone-head h2 .mono{font-weight:500;color:var(--muted);}
.pjrelone-head .hint{margin:0;font-size:12px;}
.pjrelone .pjrel-grid{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;padding:0;}
.pjrelone .pjrel-grid > .card{margin:0;}
.pjsec-h{flex:1;margin:0;font-size:13px;font-weight:700;}
.pjrelone .pjtime{padding:12px 13.5px;}
body.research .njpill-state.is-ok{background:var(--ok-wash);color:#1e563d;}
body.research .njpill-state.is-held{background:var(--warn-wash);color:#604400;}
@media (max-width:900px){ .pjrelone .pjrel-grid{grid-template-columns:minmax(0,1fr);} }

/* ---------- The name menu, in her "View as" chip and menu (#115) ----------
   Measured from Main.dc.html (closed, hovered, open, focused). Its content is
   ours and unchanged (organisation tag, address, Viewing as, Sign out); only
   its look is hers. Closed: her chip ground, 6 px corners, 48 px like the AI
   button, the role in small grey above the name in bold, the chevron at the
   right. Her chip computes with no border and no shadow. Open: her brighter
   ground. Keyboard focus: her 2 px ink ring, 2 px out. */
body.research .whobtn{display:grid;grid-template-columns:auto auto;grid-template-rows:auto auto;align-items:center;column-gap:9px;row-gap:0;
  height:36px;padding:0 9px 0 12px;box-sizing:border-box;border:0;border-radius:4.5px;background:var(--nj-chip);box-shadow:none;}
body.research .whobtn:hover,body.research .whomenu[open] .whobtn{background:var(--nj-chip-hover);}
body.research .whobtn:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research .whorole{grid-column:1;grid-row:1;font-size:12px;line-height:1.15;color:var(--muted);}
body.research .whoname{grid-column:1;grid-row:2;font-size:12px;font-weight:700;line-height:1.15;color:var(--paper);}
body.research .whochev{grid-column:2;grid-row:1 / span 2;width:13.5px;height:13.5px;color:var(--paper);}
body.research .who{align-items:center;}

/* The menu: her white card under the button, right-aligned, never past the
   right edge. */
body.research .whopanel{top:calc(100% + 6px);right:0;left:auto;width:240px;max-width:calc(100vw - 24px);min-width:0;
  padding:6px;gap:0;box-sizing:border-box;border:1px solid var(--hairline);border-radius:6px;background:var(--nj-float);box-shadow:var(--nj-shadow);}
/* Her section label, for the organisation tag. */
body.research .whopanel .whoorg{padding:6px 9px 4.5px;}
body.research .whopanel .whoorg .pill{all:unset;font:700 12px/1.45 var(--ui);letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
/* Her rows: 52 px, 6/10 padding, 4 px corners, a hover, and the open one filled. */
body.research .whopanel .whoemail,body.research .whopanel .roleview,body.research .whopanel form:last-child{margin:0;}
body.research .whopanel .whoemail{display:flex;align-items:center;min-height:33px;padding:4.5px 7.5px;font-size:12px;color:var(--paper);overflow-wrap:anywhere;}
body.research .whopanel .roleswitch,body.research .whopanel .signout,body.research .whopanel .whorow{display:flex;align-items:center;gap:7.5px;width:100%;min-height:39px;padding:4.5px 7.5px;
  box-sizing:border-box;border:0;border-radius:3px;background:transparent;color:var(--paper);font:700 12px/1.2 var(--ui);text-align:left;cursor:pointer;}
body.research .whopanel .roleswitch:hover,body.research .whopanel .signout:hover,body.research .whopanel .whorow:hover{background:var(--nj-chip-hover);}
body.research .whopanel .roleswitch.as-researcher{background:var(--teal-wash);}
body.research .whopanel .roleswitch:focus-visible,body.research .whopanel .signout:focus-visible,body.research .whopanel .whorow:focus-visible{outline:2px solid var(--focus-ink);outline-offset:-2px;}
body.research .whopanel .roleswitch-label{opacity:1;font-weight:500;font-size:12px;color:var(--muted);}
body.research .whopanel .roleswitch-mode{font-weight:700;}
/* Her switch: a 50 by 30 track, a 24 px white knob with its shadow. */
body.research .whopanel .roleswitch-track{width:37.5px;height:22.5px;border-radius:11px;background:var(--control-border);margin-left:auto;order:3;}
body.research .whopanel .roleswitch-knob{top:3px;left:3px;width:18px;height:18px;box-shadow:0 1px 3px rgba(0,0,0,0.3);}
body.research .whopanel .roleswitch.as-admin .roleswitch-track{background:var(--brand-teal);}
body.research .whopanel .roleswitch.as-admin .roleswitch-knob{transform:translateX(15px);}

/* 768 px and below: the button shrinks to her chip with the initials; the
   menu still opens under it and fits. */
@media (max-width:768px){
  body.research .whobtn{grid-template-columns:auto auto;padding:0 7.5px;}
  body.research .whoname,body.research .whorole{display:none;}
  body.research .whoinitials{display:grid;place-items:center;width:24px;height:24px;border-radius:50%;background:var(--nj-avatar);
    color:var(--brand-teal-lift);font:700 12px/1 var(--ui);grid-column:1;grid-row:1 / span 2;}
}

/* Her dataset card (#115), as she draws it at 1440: her numbers times 0.75,
   text never under 12 px. The grid fills the row by width. */
body.research .dsgrid.njdsgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(225px,100%),1fr));gap:12px;}
body.research a.njds{display:flex;flex-direction:column;gap:9px;padding:12px 13.5px;min-width:0;box-sizing:border-box;border:1px solid var(--hairline);
  border-radius:6px;background:var(--panel-fill);color:var(--text);text-decoration:none;}
body.research a.njds:hover{border-color:var(--control-border);}
.njds-top{display:flex;align-items:center;gap:6px;width:100%;}
.njds-type,.njds-access{height:18px;display:inline-flex;align-items:center;gap:4.5px;padding:0 6.75px;box-sizing:border-box;border-radius:3px;
  font-size:12px;font-weight:700;white-space:nowrap;}
.njds-type{background:var(--nj-chip);color:var(--paper);}
.njds-type.is-live{background:var(--ok-wash);color:#1e563d;}
.njds-dot{width:5px;height:5px;border-radius:50%;background:currentColor;flex:none;}
.njds-type.is-arriving .njds-dot{animation:njpulse 2s ease-in-out infinite;}
@keyframes njpulse{0%,100%{opacity:1}50%{opacity:.35}}
@media (prefers-reduced-motion:reduce){ .njds-type.is-arriving .njds-dot{animation:none;} }
.njds-access{background:var(--teal-wash);color:var(--brand-teal-lift);}
.njds-names{display:flex;flex-direction:column;gap:1.5px;min-width:0;width:100%;}
.njds-name{font-size:12px;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.njds-ver{font-weight:500;color:var(--muted);}
.njds-owner{font-size:12px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.njds-foot{display:flex;align-items:flex-end;gap:9px;width:100%;}
.njds-figure{display:flex;flex-direction:column;}
.njds-big{font-size:19.5px;font-weight:500;letter-spacing:-0.02em;color:var(--text);line-height:1.2;}
.njds-sub{font-size:12px;color:var(--muted);}
.njds-side{display:flex;flex-direction:column;align-items:flex-end;gap:1.5px;}
.njds-sidel{font-size:12px;color:var(--muted);}
.njds-sidev{font-size:12px;font-weight:600;color:var(--muted);white-space:nowrap;}

body.research .whopanel a.whorow{text-decoration:none;color:var(--paper);}

/* The languages a code tool runs (#115), in her pill: R, not run yet, quieter. */
.njlangs{display:flex;flex-wrap:wrap;gap:4.5px;margin:6px 0 0;padding:0;list-style:none;}
.njlangs li{max-width:none;margin:0;}
body.research .njpill.is-off{background:transparent;border:1px dashed var(--hairline);color:var(--muted);font-weight:500;}

/* ---------- her Cohorts step: Query datasets inside a project (#136) ----------
   Three columns from 1200px, her 1440 sizes: the saved queries (240), the
   field list (195) and the builder with its live result. The builder's own
   cells keep their areas; the two lists span every row, and the last row
   takes what is left so a long list never opens gaps in the builder.
   Below 1200px it is the builder as everywhere else, and the field list,
   which only adds a way in, is not drawn: Add condition does what it does. */
.buildfields{display:none;}
/* The list scrolls inside itself, so it is the containing block of what it
   holds: its "add a condition" labels for screen readers are absolutely
   placed, and without this they escaped the scroller and stretched the page
   by the whole list's length, far past the last content (#136). */
.buildfields{position:relative;}
@media (min-width:1200px){
  .buildgrid-split.buildgrid-project{
    grid-template-columns:240px 195px minmax(0,1fr);
    grid-template-areas:"saved fields head" "saved fields pre" "saved fields tabs" "saved fields box" "saved fields run" "saved fields result";
    grid-template-rows:auto auto auto auto auto 1fr;
    column-gap:12px;
  }
  .buildgrid-project .buildfields{display:block;grid-area:fields;align-self:start;max-height:calc(100vh - 200px);overflow-y:auto;overscroll-behavior:contain;padding:0;border-radius:6px;background:var(--surface);}
  .buildgrid-project .buildresult{align-self:start;}
  .buildgrid-project .buildsaved{grid-area:saved;align-self:start;margin-top:0;display:block;
    background:var(--surface);border:1px solid var(--hairline);border-radius:6px;overflow:hidden;}
  .buildgrid-project .buildsaved-head{min-height:42px;margin:0;padding:4.5px 9px 4.5px 13.5px;align-items:center;border-bottom:1px solid var(--hairline);gap:6px;}
  .buildgrid-project .buildsaved-head .eyebrow{flex:1;font-family:inherit;font-size:13px;font-weight:700;letter-spacing:0;text-transform:none;color:var(--paper);}
  .buildgrid-project .buildsaved-card{grid-row:auto;contain:none;overflow:visible;border:0;border-radius:0;display:block;}
  .buildgrid-project .savedlist li,.buildgrid-project .savedlist li:nth-child(n+6){display:grid;}
  .buildgrid-project .savedlist li{grid-template-columns:minmax(0,1fr) auto;gap:2px 9px;padding:7.5px 12px 7.5px 13.5px;}
  .buildgrid-project .savedlist-name{font-size:12px;font-weight:700;}
  .buildgrid-project .savedlist-n,.buildgrid-project .savedlist-when{grid-column:1;font-size:12px;color:var(--muted);}
  .buildgrid-project .savedlist li a{grid-column:2;grid-row:1 / 4;font-size:12px;}
  .buildgrid-project .buildorg-title{margin:0 13.5px 6px;}
  .buildgrid-project .buildsaved-foot{margin:0;padding:6px 13.5px 9px;border-top:1px solid var(--hairline-soft);}
  .buildgrid-project .buildorg > .hint{padding:0 13.5px 9px;}
  .buildgrid-project .buildhead h3{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;}
}
.buildfields-search{position:sticky;top:0;z-index:1;padding:9px;background:var(--surface);}
.buildfields-search .input{height:33px;padding:0 9px;font-size:12px;border-radius:4.5px;background:var(--nj-chip);}
.buildfields-group{border-top:1px solid var(--hairline);}
.buildfields-group[hidden],.buildfields-group li[hidden]{display:none;}
.buildfields-head{margin:0;padding:7.5px 10.5px 3px;font-family:var(--label);font-size:12px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
.buildfields ul{margin:0;padding:0 4.5px 6px;list-style:none;}
.buildfields li{max-width:none;margin:0;}
.buildfields-add{display:flex;align-items:center;justify-content:space-between;gap:6px;width:100%;min-height:27px;padding:4.5px 6px;line-height:1.25;border:0;border-radius:3px;background:transparent;color:var(--paper);font:inherit;font-size:12px;text-align:left;cursor:pointer;}
.buildfields-add:hover:not(:disabled){background:var(--nj-row-picked);}
.buildfields-add:focus-visible{outline:2px solid var(--brand-teal);outline-offset:-2px;}
.buildfields-add svg{flex:none;color:var(--muted);}
.buildfields-add:disabled{color:var(--muted);cursor:not-allowed;}

/* ---------- her Analyses step and New analysis (#136) ----------
   Her list (255 at 1440) beside the open analysis. The open analysis is
   Results' own detail, unchanged inside its column. Stacked below 1200px,
   the list above. */
.pjanwork{display:grid;grid-template-columns:minmax(0,1fr);gap:12px;align-items:start;}
@media (min-width:1200px){.pjanwork{grid-template-columns:255px minmax(0,1fr);}}
.pjanopen{min-width:0;}
.pjanlist .pjsec-head{gap:6px;}
.pjanrows{margin:0;padding:0;list-style:none;}
.pjanrows li{max-width:none;margin:0;border-top:1px solid var(--hairline);}
.pjanrows li:first-child{border-top:0;}
.pjanrow{display:flex;flex-direction:column;gap:2px;padding:7.5px 12px 7.5px 13.5px;color:var(--text);text-decoration:none;border-left:2px solid transparent;}
.pjanrow:hover{background:var(--nj-chip-hover);}
.pjanrow.is-on{background:var(--nj-row-picked);border-left-color:var(--brand-teal);}
.pjanrow:focus-visible{outline:2px solid var(--brand-teal);outline-offset:-2px;}
.pjanrow-top{display:flex;align-items:flex-start;gap:6px;}
.pjanrow-name{flex:1;min-width:0;font-size:12px;font-weight:700;color:var(--paper);overflow-wrap:anywhere;}
.pjanrow-sub,.pjanrow-ref{font-size:12px;color:var(--muted);}
.pjstate.is-ok{background:var(--ok-wash);color:var(--cleared-ink);}
.pjnew-head{display:flex;flex-direction:column;gap:2px;margin:0 0 12px;}
.pjnew-head h2{margin:0;font-size:14.25px;font-weight:700;}
.pjnew-sub{font-size:12px;color:var(--muted);}
.pjcohort{display:flex;align-items:center;gap:10.5px;margin:0 0 12px;padding:9px 9px 9px 13.5px;border-radius:6px;background:var(--surface);}
.pjcohort-ic{flex:none;display:grid;place-items:center;width:30px;height:30px;border-radius:4.5px;background:var(--nj-chip);border:1px solid var(--hairline);color:var(--muted);}
.pjcohort-main{flex:1;min-width:0;}
.pjcohort-line{margin:0;max-width:none;font-size:12px;display:flex;flex-wrap:wrap;align-items:baseline;gap:6px;}
.pjcohort-conds{display:flex;flex-wrap:wrap;gap:4.5px;margin:4.5px 0 0;padding:0;list-style:none;}
.pjcohort-conds li{max-width:none;margin:0;padding:1.5px 6px;border:1px solid var(--hairline);border-radius:3px;font-size:12px;background:var(--nj-chip);}
body.research .qtabs.pjways{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));width:100%;margin:0 0 12px;}
body.research .pjways .qtab{text-align:center;justify-content:center;}
.pjway{margin:0;}
.pjway-body{padding:10.5px 13.5px 13.5px;display:flex;flex-direction:column;gap:10.5px;}
.pjway-pick{display:flex;flex-direction:column;gap:4.5px;margin:0;}
.pjway-pick .sel{max-width:none;}
.pjway-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;}
.pjway-foot .hint{margin:0;}

/* The project band and the Dashboard band bleed to the edges of .main, so
   their negative margins follow its padding: 20px 16px on a phone. */
@media (max-width:599px){
  body.research .pjband,body.research .dashhead{margin-top:-20px;margin-left:-16px;margin-right:-16px;padding-left:16px;padding-right:16px;}
}
/* Withheld in her label face keeps her label tracking: Plex at the old
   condensed face's .14em ran past a chart's value column at 390px. */
body.research .withheld{letter-spacing:.06em;}

/* ---------- her Analyses screen: header, switch, Method (#136) ---------- */
.pjnew-head{flex-direction:row;align-items:flex-start;justify-content:space-between;gap:12px;}
.pjnew-title{display:flex;flex-direction:column;gap:2px;min-width:0;}
.pjnew-title h2{margin:0;font-size:14.25px;font-weight:700;}
.njswitch{flex:none;display:grid;grid-template-columns:1fr 1fr;width:225px;padding:3px;box-sizing:border-box;
  border:1px solid var(--hairline);border-radius:6px;background:var(--nj-chip);}
.njswitch-opt{display:grid;place-items:center;height:33px;border-radius:4.5px;font-size:12px;font-weight:600;color:var(--text);text-decoration:none;}
.njswitch-opt:hover{background:var(--nj-chip-hover);}
.njswitch-opt.on{background:var(--brand-teal);color:#fff;}
.njswitch-opt.is-off{color:var(--muted);cursor:not-allowed;}
.njswitch-opt:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}
.pjcohort-meta{font-size:12px;color:var(--muted);}
.pjcohort-pick{display:inline-flex;align-items:center;gap:6px;margin:0;}
.pjcohort-pick .sel{width:auto;max-width:340px;height:30px;}
.njchips{display:flex;flex-wrap:wrap;gap:6px;margin:0;padding:0;list-style:none;}
.njchips li{max-width:none;margin:0;}
.njchip{display:inline-flex;align-items:center;height:30px;padding:0 10.5px;border:1px solid var(--hairline);border-radius:4.5px;
  background:var(--surface);font-size:12px;font-weight:600;color:var(--text);text-decoration:none;}
.njchip:hover{background:var(--nj-chip-hover);}
.njchip.on{background:var(--nj-row-picked);border-color:var(--brand-teal);color:var(--brand-teal-lift);}
.njchip.is-off{color:var(--muted);border-style:dashed;}
.njrun{display:inline-flex;align-items:center;gap:6px;}
.pjcode-head{gap:9px;flex-wrap:wrap;height:auto;min-height:42px;}
.njlangtabs{flex:1;display:flex;align-items:center;gap:3px;min-width:0;flex-wrap:wrap;}
.njlangtab{display:inline-flex;align-items:center;height:27px;padding:0 9px;border-radius:4.5px;font-size:12px;font-weight:600;color:var(--text);text-decoration:none;}
.njlangtab:hover{background:var(--nj-chip-hover);}
.njlangtab.on{background:var(--nj-row-picked);}
.njlangtab.is-off{color:var(--muted);font-weight:500;}
.pjcode-versions{font-size:12px;color:var(--muted);}
.njcode{margin:0;padding:12px 13.5px;max-height:420px;overflow:auto;font-family:var(--mono);font-size:12px;line-height:1.6;
  color:var(--paper);background:var(--surface);white-space:pre;}
.njcode:focus-visible{outline:2px solid var(--brand-teal);outline-offset:-2px;}
.pjnotebooks .sess-offers{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:9px;}
.pjnotebooks .sess-tool{margin:0;}
.pjchat{justify-content:flex-end;}

.pjchat-ask{display:flex;gap:9px;margin:0;}
.pjchat-ask .input{flex:1;min-width:0;height:33px;}
body.research .ahead .ahead-actions{flex-wrap:wrap;}
.ahead > .pjcohort{margin:12px 0;}
.ahead > .ahead-actions{display:flex;justify-content:flex-end;gap:6px;margin:0 0 12px;}
.ahead-name .pjnew-sub{display:block;}
@media (max-width:720px){.pjnew-head{flex-direction:column;}.njswitch{width:100%;}}
/* A draft on the Dashboard (#136): her Draft, quieter than Closed. */
.pjstate.is-draft{background:var(--nj-chip);border:1px dashed var(--hairline);color:var(--muted);}

/* The session bar as hers (#136): a dot that pulses while it starts, her
   green bar once it runs, her error with the reason when it did not start. */
@keyframes sesspulse{0%,100%{opacity:1;}50%{opacity:.35;}}
.sess-bar:not(.is-running) .sess-dot{background:var(--brand-teal);animation:sesspulse 1.2s ease-in-out infinite;}
@media (prefers-reduced-motion:reduce){.sess-bar:not(.is-running) .sess-dot{animation:none;}}
.sess-error{margin:0 0 9px;padding:9px 12px;border-left:3px solid var(--err-edge);border-radius:4.5px;background:var(--err-wash);font-size:12px;color:var(--text);}
.sess-error strong{color:var(--text);}

/* Her chat in the Plain language tab (#136): the question in her bubble on
   the right, the answer below it in plain text, the ask box at the bottom. */
.pjchat{gap:0;}
.pjchat-log{display:flex;flex-direction:column;gap:12px;margin:0 0 12px;padding:0;list-style:none;}
.pjchat-log:empty{display:none;}
.pjturn{max-width:none;margin:0;}
.pjturn-me{display:flex;justify-content:flex-end;}
.pjbubble{margin:0;max-width:75%;padding:9px 12px;border-radius:6px;background:var(--nj-row-picked);font-size:12px;color:var(--paper);overflow-wrap:anywhere;}
.pjanswer{display:flex;flex-direction:column;gap:6px;font-size:12px;}
.pjanswer > p{margin:0;max-width:65ch;}
.pjanswer-note{color:var(--muted);}
.pjanswer-meta{color:var(--muted);font-size:12px;}
.pjanswer-act{display:flex;flex-wrap:wrap;gap:6px;}
.pjanswer-act form{margin:0;}
.pjchat-ask{display:flex;gap:9px;margin:0;padding-top:12px;border-top:1px solid var(--hairline);}
.pjchat-log:empty + .pjchat-ask{border-top:0;padding-top:0;}

/* Her stepper on every project step (#136): the four steps compact on the
   left, a flexible gap, then her right-hand group in a box of one width on
   every step, so the steps sit in the same place whichever step is open:
   the status or count, the main action, a thin divider, her two icons. */
@media (min-width:1200px){
  .pjstep-list{flex:0 1 980px;}
  .pjstep-act{flex:0 0 440px;margin-left:auto;justify-content:flex-end;}
}
.pjstep-main{display:flex;align-items:center;justify-content:flex-end;gap:6px;min-width:0;}
.pjstep-div{flex:none;width:1px;height:30px;margin:0 6px;background:var(--hairline);}
.njicon{flex:none;display:inline-grid;place-items:center;width:33px;height:33px;padding:0;border:1px solid var(--hairline);
  border-radius:4.5px;background:var(--nj-chip);color:var(--paper);cursor:pointer;font:inherit;font-size:16px;line-height:1;}
.njicon:hover{background:var(--nj-chip-hover);}
.njicon:focus-visible{outline:2px solid var(--brand-teal);outline-offset:2px;}

/* Her slide-out panel: over the page from the right, nothing under it moves. */
.njpanel{position:fixed;top:54px;right:0;bottom:0;z-index:85;width:345px;max-width:92vw;box-sizing:border-box;
  display:flex;flex-direction:column;background:var(--surface);border-left:1px solid var(--hairline);
  box-shadow:-10.5px 0 27px rgba(13,27,38,.12);transform:translateX(100%);transition:transform .2s ease;}
.njpanel.is-open{transform:none;}
.njpanel[hidden]{display:none;}
@media (prefers-reduced-motion:reduce){.njpanel{transition:none;}}
.njpanel-head{flex:none;display:flex;align-items:center;justify-content:space-between;height:42px;padding:0 9px 0 13.5px;border-bottom:1px solid var(--hairline);}
.njpanel-head h2{margin:0;font-size:13px;font-weight:700;}
.njpanel-content{flex:1;overflow-y:auto;overscroll-behavior:contain;}
.njpanel-content > .hint{padding:12px 13.5px;margin:0;}
.njpanel-body{padding:6px 0 12px;}
.njpanel-h{margin:9px 13.5px 3px;font-family:var(--label);font-size:12px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);}
.njpanel-body > .hint{margin:0 13.5px 6px;}
.njfiles,.njacts{margin:0;padding:0;list-style:none;}
.njfiles li{display:flex;gap:9px;align-items:flex-start;max-width:none;margin:0;padding:6px 13.5px;}
.njfile-ic{flex:none;color:var(--muted);padding-top:2px;}
.njfile-main{display:flex;flex-direction:column;gap:1px;min-width:0;}
.njfile-name{font-size:12px;color:var(--paper);overflow-wrap:anywhere;}
.njfile-sub{font-size:12px;color:var(--muted);}
.njacts li{display:flex;flex-direction:column;gap:2px;max-width:none;margin:0;padding:9px 13.5px;border-top:1px solid var(--hairline-soft);}
.njacts li:first-child{border-top:0;}
.njact-when{font-size:12px;color:var(--muted);}
.njact-what{font-size:12px;font-weight:700;color:var(--paper);}
.njact-sub{font-size:12px;color:var(--muted);}
.njact-flag{align-self:flex-start;margin-top:3px;padding:1.5px 6px;border-radius:3px;background:var(--err-wash);color:var(--text);border-left:3px solid var(--err-edge);font-size:12px;font-weight:600;}
@media (min-width:600px) and (max-width:1199px){
  .pjstep-list{flex:1 1 auto;}
  .pjstep-act{flex:0 0 380px;margin-left:auto;justify-content:flex-end;}
}

/* Her Release step (#136): Outputs and Justification on the left, the newest
   request's checks and status on the right. */
.pjrelwork{display:grid;grid-template-columns:minmax(0,1fr);gap:12px;align-items:start;}
@media (min-width:1024px){.pjrelwork{grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);}}
.pjrelform,.pjrelside{display:flex;flex-direction:column;gap:12px;min-width:0;margin:0;}
.pjrelform .pjsec,.pjrelside .pjsec{margin:0;}
.pjouts{margin:0;padding:0;list-style:none;}
.pjouts li{max-width:none;margin:0;border-top:1px solid var(--hairline-soft);}
.pjouts li:first-child{border-top:0;}
.pjout{display:flex;align-items:flex-start;gap:10.5px;padding:9px 13.5px;cursor:pointer;}
.pjout input{flex:none;width:16px;height:16px;margin:2px 0 0;accent-color:var(--brand-teal);}
.pjout-main{display:flex;flex-direction:column;gap:2px;min-width:0;}
.pjout-name{font-size:12px;font-weight:700;color:var(--paper);}
.pjout-sub{font-size:12px;color:var(--muted);}
.pjrel-why{padding:10.5px 13.5px 13.5px;display:flex;flex-direction:column;gap:4.5px;}
.pjrel-why .ta{max-width:none;}
.pjtime-when{display:block;font-size:12px;color:var(--muted);}
.pjrelform .sess-error p{margin:0;}

/* Her snackbar (#179), from Main.dc.html's toast: centred 32px above the
   bottom of the screen, a hairline, her radius and panel shadow, bold
   words and a dismiss. An error, so a red edge on its left. Fixed, so it
   moves nothing under it. */
.snack{position:fixed;left:50%;bottom:32px;transform:translateX(-50%);z-index:90;display:flex;align-items:center;gap:12px;
  box-sizing:border-box;width:max-content;max-width:min(640px,calc(100vw - 32px));padding:10px 10px 10px 18px;
  border:1px solid var(--hairline);border-left:4px solid var(--err-edge);border-radius:8px;background:var(--surface);
  box-shadow:var(--panel-shadow);color:var(--text);font-family:var(--ui);font-size:14px;line-height:1.45;font-weight:600;}
.snack[hidden]{display:none;}
.snack-text{margin:0;}
.snack-x{flex:none;width:36px;height:36px;display:flex;align-items:center;justify-content:center;border:0;border-radius:4px;
  background:transparent;color:var(--muted);cursor:pointer;}
.snack-x:hover{background:var(--surface-2);}
.snack-x:focus-visible{outline:2px solid var(--focus-ink);outline-offset:2px;}
body.research textarea[aria-invalid="true"]{border-color:var(--err-edge);}
