/* sentier-diagnostics: the style of the diagnostics, inside a host's page or on their own.
   Every rule is scoped to .sentier-diagnostics: nothing here touches the host's :root, body,
   headings or tables outside it, and no font is set (the host's is inherited). Colours and
   sizes are custom properties that take the host's tokens where it sets them (the shared
   tokens of the Sentier sites) and fall back otherwise. Up, down and noise keep colours of
   their own, so that a direction never takes a site's accent. No font, script or image is
   loaded from anywhere else. */
.sentier-diagnostics:not(#sd-none):not(#sd-none) {
  --sd-ink: var(--ink, #1d232a);
  --sd-muted: var(--muted, #5b6672);
  --sd-surface: var(--surface, #ffffff);
  --sd-paper-deep: var(--paper-deep, #f3f5f7);
  --sd-line: var(--line, #d9dee3);
  --sd-line-strong: var(--line-strong, #b6bfc8);
  --sd-accent: var(--index, #1d625e);
  --sd-on-accent: var(--on-index, #ffffff);
  --sd-fail: var(--fail, #a3262a);
  --sd-radius: var(--radius, 6px);
  --sd-gutter: var(--gutter, 16px);
  --sd-t-xs: var(--t-xs, 0.75rem);
  --sd-t-sm: var(--t-sm, 0.875rem);
  --sd-t-md: var(--t-md, 1rem);
  --sd-t-lg: var(--t-lg, 1.2rem);
  --sd-s2: var(--s2, 0.5rem);
  --sd-s3: var(--s3, 0.75rem);
  --sd-s4: var(--s4, 1rem);
  --sd-s5: var(--s5, 1.5rem);
  --sd-s6: var(--s6, 2rem);
  --sd-up: #b07a1b;      /* went up: amber */
  --sd-down: #1d625e;    /* went down: teal; the pair reads for colour-blind readers */
  --sd-noise: #8a939c;
  --sd-drawer: clamp(22rem, 42vw, 52rem);
  /* the ink and the ground together: on a host without the tokens both fall back, so the
     fallback ink is never dark on the host's dark ground */
  color: var(--sd-ink);
  background: var(--sd-surface);
  font-size: var(--sd-t-md);
  line-height: 1.45;
}
/* A dark page: the script marks it so where the host's ink is light, or its ground dark with
   no ink. Every token the host did not set falls back to a dark colour, so that the host's
   light ink is never set on the page's white ground. */
.sentier-diagnostics:not(#sd-none):not(#sd-none)[data-sd-scheme="dark"] {
  --sd-ink: var(--ink, #e6eaee);
  --sd-muted: var(--muted, #9aa5b0);
  --sd-surface: var(--surface, #15191d);
  --sd-paper-deep: var(--paper-deep, #1f252b);
  --sd-line: var(--line, #36404a);
  --sd-line-strong: var(--line-strong, #56616c);
  --sd-accent: var(--index, #739e9b);
  --sd-on-accent: var(--on-index, #15191d);
  --sd-fail: var(--fail, #ff8a8e);
  --sd-up: #d9a441;
  --sd-down: #5fa29d;
  --sd-noise: #77818b;
}

/* a class that sets `display` would otherwise show an element marked hidden */
.sentier-diagnostics:not(#sd-none):not(#sd-none) [hidden] { display: none !important; }

/* What a host sets on elements stops at the page: a site's `button { min-height: 44px;
   text-transform: uppercase }`, `li { list-style: square }` or `li::before { content: "• " }`
   would otherwise reach the headings, chips and lists. Every rule here weighs two ids more
   than its classes (the `:not(#sd-none)` twice, which every element matches), so it beats a
   host's rule for `#main button` or `#page #main li` too; only a host's `!important` wins.
   These resets come first; the page's own classes, which come later and weigh more, set
   what each control looks like. A list item takes its list's markers, and none where the
   list has none. */
.sentier-diagnostics:not(#sd-none):not(#sd-none) button { display: inline-block; width: auto; min-width: 0; min-height: 0; height: auto; margin: 0; border-radius: 0;
  text-transform: none; letter-spacing: normal; text-shadow: none; box-shadow: none; font: inherit; line-height: inherit; color: inherit; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) li { list-style: inherit; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) li::marker { content: normal; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) li::before, .sentier-diagnostics:not(#sd-none):not(#sd-none) li::after { content: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* the head */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-head { margin: 0 0 var(--sd-s4); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-title { margin: 0.2rem 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-lead { margin: 0.3rem 0; max-width: 60rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-lead:empty { display: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-tier { margin: 0.2rem 0; }
/* a local file says so as a quiet part of the line, as a site's own notice would */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-local { font-weight: 700; color: var(--sd-ink); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-local::before { content: "· "; font-weight: 400; color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-quiet { color: var(--sd-muted); font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-note { max-width: 70rem; color: var(--sd-muted); font-size: var(--sd-t-sm); line-height: 1.5; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-error { color: var(--sd-fail); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-plain { list-style: none; padding: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-plain > li { margin: var(--sd-s2) 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-states { display: flex; flex-wrap: wrap; gap: 0.25rem 0.5rem; margin: 0.6rem 0; padding: 0; list-style: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-states > li { padding: 0.15rem 0.5rem; border: 1px solid var(--sd-line); border-radius: var(--sd-radius); background: var(--sd-paper-deep); font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-states > li + li::before { content: "→ "; color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-banner { display: inline-block; margin: var(--sd-s2) 0; padding: 0.3rem 0.6rem; border: 1px solid var(--sd-fail); border-radius: var(--sd-radius); color: var(--sd-fail); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-made-by { margin-top: var(--sd-s6); }

/* the comparison: a row of chips, the whole way first, then each step */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-picker { margin: var(--sd-s3) 0 var(--sd-s2); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-picker-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--sd-s2) var(--sd-s3); margin-bottom: 0.35rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-summary { font-size: var(--sd-t-xs); font-variant-numeric: tabular-nums; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-open { margin-left: auto; }
/* the strip: the whole way, then one cell per step; a bar as high as what moved in it */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-strip { display: flex; align-items: stretch; gap: 0.5rem; min-width: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-whole { flex: none; padding: 0.3rem 0.75rem; border: 1px solid var(--sd-line-strong); border-radius: 999px; background: var(--sd-surface); color: inherit; font: inherit; font-weight: 600; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-whole[aria-pressed="true"] { border-color: var(--sd-accent); background: var(--sd-accent); color: var(--sd-on-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cells { display: flex; align-items: stretch; gap: 2px; flex: 1 1 auto; min-width: 0; height: 2.6rem; overflow-x: auto; scrollbar-width: thin; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dense .sd-cells { gap: 1px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dense .sd-cell { min-width: 2px; border-width: 0; border-radius: 1px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell { position: relative; flex: 1 1 0; min-width: 3px; max-width: 2.6rem; padding: 0; border: 1px solid transparent; border-radius: 3px; background: var(--sd-paper-deep); cursor: pointer; display: flex; flex-direction: column; justify-content: flex-end; align-items: stretch; user-select: none; -webkit-user-select: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell:hover { border-color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell:focus-visible, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-whole:focus-visible { outline: 2px solid var(--sd-accent); outline-offset: 2px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell-bar { display: block; width: 100%; background: var(--sd-muted); opacity: 0.45; border-radius: 2px 2px 0 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell-bar.sd-none { height: 2px !important; opacity: 0.25; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell[aria-pressed="true"] { background: color-mix(in srgb, var(--sd-accent) 16%, var(--sd-surface)); border-color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell[aria-pressed="true"] .sd-cell-bar { background: var(--sd-accent); opacity: 1; }
/* a dense strip leaves a step 2px: a chosen one is filled and underlined, so that a set of
   hundreds of steps still reads as bands along the strip */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dense .sd-cell[aria-pressed="true"] { background: color-mix(in srgb, var(--sd-accent) 45%, var(--sd-surface)); box-shadow: inset 0 -4px 0 var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-numbered .sd-cell-bar { margin-bottom: 1rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell-no { position: absolute; left: 0; right: 0; bottom: 0.1rem; font-size: var(--sd-t-xs); line-height: 1; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums; color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell[aria-pressed="true"] .sd-cell-no { color: inherit; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell.sd-unexplained { border-top: 2px solid var(--sd-fail); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-cell.sd-look::after { content: ""; position: absolute; top: 2px; right: 2px; width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: 0.7; }
/* Give each numbered step a full touch target on narrow screens. */
@media (max-width: 40rem) {
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-strip.sd-numbered { flex-direction: column; }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-numbered .sd-whole { align-self: flex-start; min-height: 44px; }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-numbered .sd-cells {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); grid-auto-rows: 44px;
    height: auto; gap: 4px; overflow: visible;
  }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-numbered .sd-cell { min-width: 44px; max-width: none; }
}
/* the list: find steps, tick any set */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-panel { margin-top: var(--sd-s2); padding: var(--sd-s2) var(--sd-s3); border: 1px solid var(--sd-line); border-radius: var(--sd-radius); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-panel[hidden] { display: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-tools { display: flex; flex-wrap: wrap; align-items: flex-end; gap: var(--sd-s2) var(--sd-s3); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-actions { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-hint { margin: 0.4rem 0; font-size: var(--sd-t-xs); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-list { max-height: 22rem; overflow-y: auto; font-size: var(--sd-t-sm); border-top: 1px solid var(--sd-line); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-group { position: sticky; top: 0; z-index: 1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; padding: 0.35rem 0.25rem; background: var(--sd-paper-deep); border-bottom: 1px solid var(--sd-line); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-run { padding: 0.1rem 0.4rem; border: 1px solid transparent; border-radius: var(--sd-radius); background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-run:hover, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-run[aria-pressed="true"] { border-color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 0.75rem; width: 100%; min-height: 0; margin: 0; padding: 0.25rem 0.4rem; border: 0; border-bottom: 1px solid var(--sd-line); border-left: 3px solid transparent; border-radius: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-row:hover { background: var(--sd-paper-deep); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-row[aria-pressed="true"] { border-left-color: var(--sd-accent); background: color-mix(in srgb, var(--sd-accent) 12%, var(--sd-surface)); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-row:focus-visible, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-run:focus-visible { outline: 2px solid var(--sd-accent); outline-offset: -2px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-name { display: flex; align-items: center; gap: 0.45rem; min-width: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-no { min-width: 2ch; font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-kind { flex: none; font-size: var(--sd-t-xs); color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-flag { font-weight: 800; color: var(--sd-fail); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-moved { font-size: var(--sd-t-xs); font-variant-numeric: tabular-nums; white-space: nowrap; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-marks { font-size: var(--sd-t-xs); min-width: 1ch; }
@media (max-width: 40rem) { .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-row { grid-template-columns: minmax(0, 1fr) auto; } .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-pick-marks { display: none; } }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-chips-label { font-size: var(--sd-t-xs); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--sd-muted); }
/* a step taken into a run only because it lies between two chosen ones: pressed, and hatched */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-switch { display: inline-flex; align-items: center; gap: 0.35rem; font-weight: 600; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-notice { padding: 0.2rem 0.5rem; border-left: 3px solid var(--sd-line-strong); background: var(--sd-surface); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-claims { margin: 0.25rem 0; padding-left: 1.2rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-claims > li + li { margin-top: 0.2rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-quiet-steps { margin: 0.25rem 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-quiet-steps > summary { cursor: pointer; color: var(--sd-muted); font-size: var(--sd-t-sm); padding-left: 1.2rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer tr.sd-in-run > * { background: var(--sd-paper-deep); }

/* the fixes view: chain or fixes, the list of fixes with a box each, the label of a set */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.75rem; margin-bottom: var(--sd-s2); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode[hidden] { display: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode-button { padding: 0.25rem 0.75rem; border: 1px solid var(--sd-line-strong); border-radius: 999px; background: none; color: inherit; font: inherit; font-weight: 600; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode-button[aria-pressed="true"] { border-color: var(--sd-accent); background: var(--sd-accent); color: var(--sd-surface); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode-button:disabled { opacity: 0.5; cursor: default; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode-button:focus-visible { outline: 2px solid var(--sd-accent); outline-offset: 2px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-mode-said { font-size: var(--sd-t-xs); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-row { grid-template-columns: auto minmax(0, 1fr) auto auto; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-row input { margin: 0; accent-color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-row:focus-within { outline: 2px solid var(--sd-accent); outline-offset: -2px; }
@media (max-width: 40rem) { .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-row { grid-template-columns: auto minmax(0, 1fr) auto; } }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-needs { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 18rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-built { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem; margin: 0.25rem 0 0.4rem; font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fix-set[aria-pressed="true"] { border-color: var(--sd-accent); box-shadow: inset 0 0 0 1px var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fixlabel { font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fixlabel-built { border-color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fixlabel-exact { border-color: var(--sd-down); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-fixlabel-estimated { border-color: var(--sd-up); border-style: dashed; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .mark.sd-est { margin-left: 0.2em; font-weight: 700; color: var(--sd-up); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-nosum { font-style: italic; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-part { margin: var(--sd-s3) 0 0; padding-top: var(--sd-s2); border-top: 1px solid var(--sd-line); font-size: var(--sd-t-sm); text-transform: uppercase; letter-spacing: 0.04em; color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer tr.sd-fix-rest > * { font-style: italic; }

/* the line of the chosen step: what it compares, its claim and what the claim found, its rule */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-step { margin: 0 0 var(--sd-s3); padding: var(--sd-s2) var(--sd-s4); border-left: 3px solid var(--sd-accent); border-radius: 0 var(--sd-radius) var(--sd-radius) 0; background: var(--sd-paper-deep); font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-step > p { margin: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-step > p + p { margin-top: 0.25rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-claim-label { display: inline-block; margin-right: 0.5em; padding: 0 0.45em; border-radius: 3px; background: var(--sd-surface); font-size: var(--sd-t-xs); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--sd-muted); }
/* what a claim found: weight, not colour; a verdict is not an approval (ADR 0010) */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-verdicts { font-weight: 700; }

/* an indicator in which the chosen comparison moved nothing: last, and quiet */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid .sd-still { color: var(--sd-muted); opacity: 0.7; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid thead th.sd-still { font-weight: 400; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid-note { margin: 0 0 var(--sd-s2); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-matrix-said { margin: 0; font-size: var(--sd-t-xs); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-matrix-said:empty { display: none; }

/* below the matrix: the rest of the file, each part closed until a reader opens it */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section { margin-top: var(--sd-s4); border-top: 1px solid var(--sd-line); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section:last-of-type { border-bottom: 1px solid var(--sd-line); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section > summary { padding: var(--sd-s2) 0; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section > summary > h3 { display: inline; margin: 0; font-size: var(--sd-t-lg); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section[open] > summary { margin-bottom: var(--sd-s2); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section + .sd-section { margin-top: 0; border-top: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-section + .sd-section > summary { border-top: 1px solid var(--sd-line); }
/* the steps: the label and the claim have room, the numbers stay narrow */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-steps td:nth-child(2) { min-width: 15rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-steps td:nth-child(5) { min-width: 18rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-table td.sd-wide { min-width: 16rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) h4 { margin: var(--sd-s5) 0 var(--sd-s2); }

/* fields, buttons */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-controls { display: flex; flex-wrap: wrap; align-items: flex-end; gap: var(--sd-s2) var(--sd-s4); margin: var(--sd-s3) 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-filters { display: flex; flex: 1 1 auto; flex-wrap: wrap; align-items: flex-end; gap: var(--sd-s2) var(--sd-s3); min-width: 0; }
/* the count and the legend on the right of the filters, as in a dashboard's control row */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-controls > .sd-status { flex: 1 1 100%; gap: 0.15rem var(--sd-s4); flex-direction: row; flex-wrap: wrap; align-items: baseline; justify-content: space-between; text-align: left; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-controls > .sd-status .sd-legend { margin: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-field { display: flex; flex-direction: column; gap: 0.2rem; font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-field > span { font-size: var(--sd-t-xs); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grow { flex: 0 1 20rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-filters select { min-width: 7rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) select, .sentier-diagnostics:not(#sd-none):not(#sd-none) input, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-button {
  min-height: 2.25rem; padding: 0.25rem 0.5rem; border: 1px solid var(--sd-line-strong); border-radius: var(--sd-radius);
  background: var(--sd-surface); color: var(--sd-ink); font: inherit; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) input[type="search"] { width: 100%; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-button { cursor: pointer; font-weight: 700; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-button:hover { border-color: var(--sd-accent); color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) select:focus-visible, .sentier-diagnostics:not(#sd-none):not(#sd-none) input:focus-visible, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-button:focus-visible { outline: 2px solid var(--sd-accent); outline-offset: 1px; }

/* tables: tables at every width, whatever the host does with bare ones */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-wrap { max-width: 100%; overflow-x: auto; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) table { display: table; width: auto; margin: 0; border: 0; border-collapse: collapse; background: none; font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) thead { display: table-header-group; position: static; width: auto; height: auto; overflow: visible; clip-path: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tbody { display: table-row-group; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tr { display: table-row; padding: 0; border: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) th, .sentier-diagnostics:not(#sd-none):not(#sd-none) td { display: table-cell; padding: 0.25rem 0.5rem; border: 0; border-bottom: 1px solid var(--sd-line); border-radius: 0;
  text-align: left; vertical-align: top; letter-spacing: 0; text-transform: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) td + td::before { content: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) th { font-weight: 700; background: var(--sd-paper-deep); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) td.num, .sentier-diagnostics:not(#sd-none):not(#sd-none) th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tr.sd-row { cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tr.sd-row:hover > *, .sentier-diagnostics:not(#sd-none):not(#sd-none) tr.sd-row:focus-visible > * { background: var(--sd-paper-deep); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tr.sd-row:focus { outline: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tr.sd-row:focus-visible > th { box-shadow: inset 3px 0 0 var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .zero { color: var(--sd-muted); }

/* the matrix: its own frame, scrolling both ways; the names stay on the left, the headings on top */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-status { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.2rem var(--sd-s5); font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-count { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid-wrap { position: relative; max-height: max(24rem, calc(100vh - 6rem)); overflow: auto; border: 1px solid var(--sd-line); border-radius: var(--sd-radius); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) table.sd-grid { border-collapse: separate; border-spacing: 0; font-size: var(--sd-t-xs); line-height: 1.35; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid th, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid td { padding: 0.28rem 0.35rem; vertical-align: middle; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid thead th { position: sticky; top: 0; z-index: 2; vertical-align: bottom; border-bottom-color: var(--sd-line-strong); white-space: normal; min-width: 3.4rem; max-width: 6.5rem; overflow-wrap: break-word; hyphens: auto; font-size: 0.75rem; line-height: 1.2; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid thead th.sd-name { left: 0; z-index: 3; min-width: 12rem; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid thead th.sd-name, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid thead th.sd-group { max-width: none; overflow-wrap: normal; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid tbody th { position: sticky; left: 0; z-index: 1; max-width: 18rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background: var(--sd-surface); font-weight: 600; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid tbody th .sd-listed { display: inline-block; width: 0.45rem; height: 0.45rem; margin-right: 0.35rem; border-radius: 50%; background: var(--sd-accent); vertical-align: 0.1em; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid td.sd-group { max-width: 8rem; overflow: hidden; text-overflow: ellipsis; color: var(--sd-muted); white-space: nowrap; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-sort { display: block; width: 100%; padding: 0; border: 0; background: none; color: inherit; font: inherit; font-weight: 700; text-align: right; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-name .sd-sort { text-align: left; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-sort:hover { color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) th[aria-sort] { box-shadow: inset 0 -3px 0 var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) tr[aria-current="true"] > th { box-shadow: inset 4px 0 0 var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-more { position: sticky; left: 0; margin: 0; padding: var(--sd-s3) var(--sd-s4); }

/* a value: colour from its direction only, strength from how far the two lie apart */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .cell { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-up { background: color-mix(in srgb, var(--sd-up) calc(var(--s, 0.5) * 55%), var(--sd-surface)); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-down { background: color-mix(in srgb, var(--sd-down) calc(var(--s, 0.5) * 55%), var(--sd-surface)); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-up.no-ratio, .sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-down.no-ratio { background-image: repeating-linear-gradient(135deg, transparent 0 4px, rgba(127, 127, 127, 0.35) 4px 6px); font-weight: 700; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-noise { color: var(--sd-noise); background-image: repeating-linear-gradient(135deg, transparent 0 5px, rgba(127, 127, 127, 0.18) 5px 7px); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-near { color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-missing { color: var(--sd-fail); font-style: italic; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .tone-none { color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .mark { margin-left: 0.2em; font-size: 0.75em; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .verdict-look { font-weight: 700; }

.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-legend { display: flex; flex-wrap: wrap; gap: 0.2rem 0.9rem; margin: 0.4rem 0; font-size: var(--sd-t-xs); color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-status > * { min-width: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-legend > span { min-width: 0; overflow-wrap: anywhere; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-legend .key { display: inline-block; white-space: nowrap; min-width: 2.6em; margin-right: 0.3em; padding: 0 0.3em; border: 1px solid var(--sd-line); border-radius: 3px; text-align: center; color: var(--sd-ink); }

/* the distributions: one card per indicator, as many in a row as fit, under the matrix */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dists-part { margin: var(--sd-s6) 0 var(--sd-s5); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dists-part > h3 { margin: 0 0 var(--sd-s2); font-size: var(--sd-t-lg); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-controls { margin: var(--sd-s2) 0 0; align-items: center; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-controls .sd-legend { margin: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dists { display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: var(--sd-s3); margin-top: var(--sd-s3); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist { position: relative; display: flex; flex-direction: column; min-width: 0; padding: var(--sd-s3) var(--sd-s4); border: 1px solid var(--sd-line); border-radius: var(--sd-radius); background: var(--sd-surface); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist:hover { border-color: var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist.sd-chosen { border-color: var(--sd-accent); box-shadow: inset 0 3px 0 var(--sd-accent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist.sd-still { opacity: 0.6; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist > h4 { margin: 0 0 var(--sd-s2); min-height: 2.6em; font-size: var(--sd-t-sm); line-height: 1.3; }
/* the title is the button; it covers the card, so that the whole card is the target */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-pick { padding: 0; border: 0; background: none; color: inherit; font: inherit; font-weight: 700; text-align: left; cursor: pointer; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-pick::after { content: ""; position: absolute; inset: 0; border-radius: var(--sd-radius); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-pick:focus-visible { outline: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-pick:focus-visible::after { outline: 2px solid var(--sd-accent); outline-offset: 2px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-top { margin: 0 0 0.15rem; font-size: 0.7rem; line-height: 1.2; color: var(--sd-muted); text-align: right; font-variant-numeric: tabular-nums; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-hist { display: flex; align-items: flex-end; gap: 2px; height: 4.5rem; border-bottom: 1px solid var(--sd-line-strong); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin { flex: 1 1 0; min-width: 0; border-radius: 1px 1px 0 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin.sd-gap { margin-left: 5px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin.down, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin-key.down { background: color-mix(in srgb, var(--sd-down) 70%, var(--sd-surface)); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin.up, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin-key.up { background: color-mix(in srgb, var(--sd-up) 80%, var(--sd-surface)); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin.mid, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin-key.mid { background: color-mix(in srgb, var(--sd-ink) 72%, var(--sd-surface)); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin.aside, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin-key.aside { background: var(--sd-noise); background-image: repeating-linear-gradient(135deg, transparent 0 3px, rgba(255, 255, 255, 0.35) 3px 5px); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-bin-key { display: inline-block; width: 0.8em; height: 0.8em; margin-right: 0.35em; border-radius: 2px; vertical-align: -0.05em; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis { display: flex; gap: 2px; margin-top: 0.2rem; font-size: 0.7rem; line-height: 1.2; color: var(--sd-muted); white-space: nowrap; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis > span { flex: 1 1 0; min-width: 0; overflow: hidden; text-overflow: clip; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis-mid { text-align: center; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis-up { text-align: right; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis-aside + .sd-axis-down, .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis-up + .sd-axis-aside { margin-left: 5px; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-axis-up + .sd-axis-aside { text-align: right; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-meta { margin: var(--sd-s2) 0 0; font-size: var(--sd-t-xs); line-height: 1.45; color: var(--sd-muted); font-variant-numeric: tabular-nums; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-dist-meta strong { color: var(--sd-ink); }

/* who wrote what */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .badge { display: inline-block; margin-right: 0.4em; padding: 0 0.5em; border: 1px solid var(--sd-line); border-radius: 999px; font-size: var(--sd-t-xs); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .badge.model { border-color: var(--sd-down); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .badge.person { border-color: var(--sd-up); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-scope { display: inline-block; margin-right: 0.3em; padding: 0 0.4em; border: 1px solid var(--sd-line-strong); border-radius: 3px; background: var(--sd-paper-deep); font-size: var(--sd-t-xs); font-weight: 700; }

/* the item: a drawer on the right, the whole window on a phone. It is a dialog that opens as
   a popover or a modal dialog, drawn above everything: above a host's sticky header whatever
   its z-index, and against the window even under a host's transformed ancestor (which would
   otherwise hold a fixed element). The rules below set what the browser's own dialog and
   popover styles set, so that it is the same drawer either way, and where neither is known
   and it stays a fixed element, as high as a z-index goes. */
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer { position: fixed; inset: 0 0 0 auto; z-index: 2147483000; display: flex; flex-direction: column; width: var(--sd-drawer); max-width: 100%;
  height: auto; max-height: none; margin: 0; padding: 0; overflow: hidden; color: var(--sd-ink);
  border: 0; border-left: 1px solid var(--sd-line-strong); background: var(--sd-surface); box-shadow: -0.5rem 0 2rem color-mix(in srgb, var(--sd-ink) 16%, transparent); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer:modal::backdrop { background: rgba(0, 0, 0, 0.3); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-head { flex: none; display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: var(--sd-s4); align-items: start;
  padding: var(--sd-s4) var(--sd-s5); border-bottom: 1px solid var(--sd-line); background: var(--sd-paper-deep); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-head > .sd-label { grid-column: 1; margin: 0; font-size: var(--sd-t-xs); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--sd-muted); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-head > h3 { grid-column: 1; margin: 0.2rem 0 0; font-size: var(--sd-t-lg); line-height: 1.3; overflow-wrap: anywhere; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-head > h3:focus { outline: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-head > .sd-button { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-body { flex: 1 1 auto; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: var(--sd-s4) var(--sd-s5) var(--sd-s6); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-body > h4:first-child { margin-top: 0; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-why { padding: 0; list-style: none; }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-why > li { margin: var(--sd-s2) 0; padding: var(--sd-s2) var(--sd-s3); border-left: 3px solid var(--sd-line-strong); border-radius: 0 4px 4px 0; background: var(--sd-paper-deep); font-size: var(--sd-t-sm); }
.sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-why > li.sd-none { border-left-color: var(--sd-line); background: none; color: var(--sd-muted); }

@media (max-width: 47.99rem) {
  .sentier-diagnostics:not(#sd-none):not(#sd-none) { --sd-drawer: 100vw; }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer { border-left: 0; box-shadow: none; }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-head { padding: var(--sd-s3) var(--sd-s4); }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-drawer-body { padding: var(--sd-s3) var(--sd-s4) var(--sd-s6); }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid tbody th { max-width: 11rem; }
  .sentier-diagnostics:not(#sd-none):not(#sd-none) .sd-grid .sd-group { display: none; }
}
