/* ==========================================================================
   pages.css (v2): the older content pages' body markup, set in the night world.

   legacy.php runs each live page with its whole stylesheet stack removed and
   night.css, shell.css and this sheet added, so every class the page bodies use
   is defined here from nothing. Hex literals stay in night.css; this sheet only
   reads tokens. Every rule is class-scoped: the tools, forms and the cable test
   load a second sheet of their own after this one.

   The page scripts fold sections on a phone at (max-width: 59.999rem); every
   phone/desktop split here uses the same line so a closed fold always has its
   summary to reopen it.
   ========================================================================== */

:root {
  /* The pages' own colour names that night.css does not carry. */
  --c-red: var(--zone-urgent);
  --c-accent: var(--wake);
  --hair-soft: var(--hair);
  --nav-height: var(--bar-height);
}

/* --------------------------------------------------------------------------
   The measure and the rhythm
   -------------------------------------------------------------------------- */
main .container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter) max(24px, env(safe-area-inset-right, 0px));
}
@media (max-width: 34rem) {
  main .container { padding-inline: var(--gutter) max(16px, env(safe-area-inset-right, 0px)); }
}
/* A container inside a container: the guide's tool strip and every legal
   section sit inside an outer one that already carries the gutter. */
main .container .container { max-width: none; padding-inline: 0; }

main .section { padding-block: var(--space-section); }
main .section + .section { padding-top: var(--space-section); }
main .band { background: var(--ink-800); border-block: 1px solid var(--hair); }
main .band + .band { border-top: 0; }
main .section > .container > :is(h2, .lede) { max-width: var(--measure); }
main .section > .container > .lede { margin-top: 1rem; }
main .section > .container > :is(.prose, .rows, .shots, .photos, .grid-uneven, .callout, .bom, .spec, .facts, .faq, .table-wrap, .cluster, .tool-grid, .m-fold, .fold, .narrative-body) { margin-top: clamp(1.75rem, 3vw, 2.5rem); }
main .section > .container > .prose + .prose { margin-top: 1.25rem; }
main .section > .container > h3 { margin-top: clamp(2rem, 3.5vw, 3rem); margin-bottom: 1rem; }
main .section > .container > h3 + .rows { margin-top: 0; }
main .section > .container > .callout + .callout { margin-top: 1rem; }

main .narrative > * { max-width: var(--measure); }
main .narrative > p { margin-top: 1.1em; color: var(--mute); }
main .narrative > p:first-of-type { margin-top: clamp(1.5rem, 3vw, 2rem); }
main .narrative > .cluster, main .narrative > .callout { margin-top: 1.75rem; }

/* Eyebrows: the heading carries its own weight. The hero's eyebrow holds the
   firmware stamp, so it keeps the stamp and drops its words. */
main .eyebrow, main .tool-eyebrow, main .eyebrow-index, main .tool-strip-label, main .list-label { display: none; }
main .hero-copy > .eyebrow { display: block; font-size: 0; line-height: 0; color: transparent; }
main .hero-copy > .eyebrow > .stamp { font-size: 0.6875rem; line-height: 1.3; }
main .hero-copy > .eyebrow > .stamp[data-fw-version] { color: var(--lum); border: 1px solid var(--lum-soft); background: rgba(0, 229, 255, 0.05); }

/* The breadcrumb: a quiet line above the page's opening. */
main .crumbs { padding-top: 1.25rem; font-size: var(--size-xs); color: var(--quiet); }
main .crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 0.6rem; margin: 0; padding: 0; list-style: none; }
main .crumbs li { display: inline-flex; align-items: center; gap: 0.6rem; }
main .crumbs li + li::before { content: ""; width: 0.9rem; height: 1px; background: var(--hair-strong); }
main .crumbs a { display: inline-flex; align-items: center; min-height: 2.75rem; color: var(--mute); text-decoration: none; }
main .crumbs a:hover { color: var(--lum); }
main .crumbs [aria-current="page"] { color: var(--quiet); }

/* --------------------------------------------------------------------------
   The hero: the page's opening. One column of copy; a photograph beside it
   from 60rem when the page has one.
   -------------------------------------------------------------------------- */
main .hero { padding-block: clamp(1.5rem, 3vw, 2.5rem) clamp(3rem, 6vw, 5rem); }
main .hero .container { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); align-items: center; }
main .hero-copy { min-width: 0; max-width: 60ch; }
main .hero-copy > .eyebrow { margin-bottom: 0.75rem; }
main .hero-copy > .log-date { margin-bottom: 1.25rem; font: 400 var(--size-xs) / 1.4 var(--font-mono); letter-spacing: 0.04em; color: var(--quiet); }
main .hero-copy > .log-date b { font-weight: 400; color: var(--quiet); }
main .hero-copy > h1 { margin-bottom: 1.25rem; }
main .hero-copy > .lede { margin-bottom: 1.75rem; }
main .hero-copy > .cluster { margin-bottom: 1.75rem; }
main .hero-copy > .cluster:last-child { margin-bottom: 0; }
/* The trademark line is a sentence, not a stamp. */
main .hero-copy > p.stamp { display: block; margin-top: 1.75rem; padding: 0; border: 0; background: none; box-shadow: none; white-space: normal; text-transform: none; letter-spacing: 0; font: 400 var(--size-xs) / 1.6 var(--font-body); color: var(--quiet); max-width: 60ch; }
main .hero-solo .hero-copy { max-width: var(--measure); }

main .hero-media { position: relative; min-width: 0; margin: 0; padding: 0; border-radius: var(--radius-card); overflow: hidden; border: 1px solid var(--hair); background: var(--ink-800); }
main .hero-media img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
main .hero-media.uncropped img { aspect-ratio: auto; object-fit: contain; }
main .hero-media picture { display: block; }
main .sk-etch, main .sk-cable, main .sk-feet { display: none; }
@media (max-width: 59.999rem) {
  main .hero-media { max-width: min(100%, 34rem); }
}
@media (min-width: 60rem) {
  main .hero .container.bleed-right { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(2rem, 5vw, 5rem); }
  main .hero-copy { max-width: none; }
}

/* --------------------------------------------------------------------------
   Keys and clusters. night.css maps .btn to the key; a cluster lights one.
   -------------------------------------------------------------------------- */
main .cluster { gap: 0.75rem; }
main .cluster .btn, main .tool-actions .btn { white-space: normal; text-align: center; }
main .section > .container > .cluster + .prose { margin-top: 1.75rem; }

/* --------------------------------------------------------------------------
   Facts: a ruled strip, the values in mono.
   -------------------------------------------------------------------------- */
main .facts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--hair); }
main .facts > li { display: grid; gap: 0.2rem; margin: 0; padding: 0.85rem 1rem 0.85rem 0; border-bottom: 1px solid var(--hair); }
main .fact-value { font: 500 var(--size-lg) / 1.2 var(--font-mono); font-variant-numeric: tabular-nums; color: var(--text); white-space: nowrap; }
main .fact-label { font: 400 var(--size-xs) / 1.5 var(--font-body); letter-spacing: 0.04em; text-transform: uppercase; color: var(--quiet); }
@media (min-width: 40rem) { main .facts { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 60rem) and (max-width: 78rem) { main .hero .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* --------------------------------------------------------------------------
   Rows: the step rows, the number lit the way .steps does on the home page.
   -------------------------------------------------------------------------- */
main .rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--hair); }
main .row {
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr);
  grid-template-areas: "num head" "num body" "num media";
  column-gap: 1.25rem;
  row-gap: 0.4rem;
  padding-block: 1.75rem;
  border-bottom: 1px solid var(--hair);
  align-content: start;
}
main .row:not(:has(> .row-num)) { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "body" "media"; }
main .row-num { grid-area: num; margin: 0; font: 200 2.4rem / 1 var(--font-display); color: var(--lum); text-shadow: var(--lum-text-shadow); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
main .row-head { grid-area: head; margin: 0; }
main h4.row-head { font: 500 var(--size-lg) / 1.3 var(--font-display); letter-spacing: -0.01em; }
main .row-head a { color: inherit; }
main .row-body { grid-area: body; margin: 0; max-width: 62ch; color: var(--mute); }
main .row-body + .row-body { margin-top: 0.5rem; }
main .row-body p + p, main .row-body ul { margin-top: 0.75em; }
main .row-media { grid-area: media; margin: 0.75rem 0 0; max-width: 22rem; }
main .row:has(> .guide-time):not(:has(> .row-num)) { grid-template-areas: "time" "head" "body" "media"; }
main .row > .guide-time { grid-area: time; }
@media (min-width: 60rem) {
  main .row.has-media { grid-template-columns: 4rem minmax(0, 1fr) minmax(14rem, 20rem); grid-template-areas: "num head media" "num body media"; column-gap: 2rem; align-items: start; }
  main .row.has-media .row-media { margin: 0; }
}
@media (max-width: 34rem) {
  main .row { grid-template-columns: 2.6rem minmax(0, 1fr); column-gap: 0.9rem; padding-block: 1.4rem; }
  main .row-num { font-size: 1.7rem; }
}

/* Release notes: the version is the numeral, so it is mono, not display. */
main .rows-releases > .row { grid-template-columns: minmax(6rem, 9rem) minmax(0, 1fr); grid-template-areas: "num head" "num body"; row-gap: 0.75rem; }
main .rows-releases > .row > .row-num { align-self: start; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; font: 500 1.05rem / 1.3 var(--font-mono); letter-spacing: 0; text-shadow: none; color: var(--lum); }
main .rows-releases .row-head { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; align-items: baseline; font: 500 var(--size-base) / 1.3 var(--font-mono); letter-spacing: 0; color: var(--text); }
main .rel-stage { font-family: var(--font-body); color: var(--quiet); font-size: var(--size-sm); }
main .stamp-fw { color: var(--ink-900); background: var(--lum); box-shadow: 0 0 16px -2px var(--lum-soft); }
main .rows-releases .row-body { max-width: 70ch; overflow-wrap: anywhere; }
main .rel-head { margin: 1.25rem 0 0.4rem; font-weight: 600; color: var(--text); }
main .rel-head:first-child { margin-top: 0; }
main .rel-list { margin: 0; padding-left: 1.2rem; }
main .rel-list li + li { margin-top: 0.4rem; }
main .rows-releases .row-body > p:not(.rel-head) { margin-top: 0.75rem; }
@media (max-width: 59.999rem) {
  main .rows-releases > .row { grid-template-columns: minmax(0, 1fr); grid-template-areas: "num" "head" "body"; row-gap: 0.35rem; }
  main .rows-releases > .row > .m-fold { grid-area: 1 / 1 / -1 / -1; border: 0; margin-block: -0.5rem; }
  main .rows-releases .m-fold > summary { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0.25rem 1rem; padding-block: 0.75rem; }
  main .rows-releases .m-fold > summary > .row-num { grid-area: 1 / 1; }
  main .rows-releases .m-fold > summary > .row-head { grid-area: 2 / 1; font-size: var(--size-sm); }
  main .rows-releases .m-fold > summary::after { content: ""; grid-area: 1 / 2 / span 2 / 2; align-self: center; flex: none; width: 0.6rem; height: 0.6rem; border-right: 1px solid var(--lum); border-bottom: 1px solid var(--lum); transform: rotate(45deg); transition: transform var(--dur) var(--ease); }
  main .rows-releases .m-fold[open] > summary::after { transform: rotate(225deg); }
  main .rows-releases .m-fold > .row-body { padding: 0.25rem 0 1rem; }
}

/* --------------------------------------------------------------------------
   Device captures and photographs. A capture sits in a thin dark bezel with
   its own light (.screen-glass); it is never scaled past what 320x240 needs. A
   photograph keeps its own proportions, always.
   -------------------------------------------------------------------------- */
main .screenshot { position: relative; margin: 0; padding: 0; background: none; border: 0; }
main .screenshot img { width: 100%; aspect-ratio: 4 / 3; image-rendering: auto; border-radius: 10px; padding: 6px; background: var(--ink-800); border: 1px solid var(--hair-strong); box-shadow: 0 24px 50px -30px rgba(0, 0, 0, 0.9), 0 0 50px -14px var(--lum-faint); }
main .screenshot > a { display: block; }
main .screenshot figcaption { margin-top: 0.75rem; font-size: var(--size-xs); line-height: 1.5; color: var(--quiet); }
main .screenshot figcaption .stamp { margin-right: 0.4em; vertical-align: 0.1em; font-size: var(--size-xs); color: var(--mute); border: 1px solid var(--hair-strong); }
main .screenshot[role="button"], main .photo[role="button"] { cursor: zoom-in; }
main .screenshot[role="button"]:focus-visible, main .photo[role="button"]:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: var(--radius-card); }

main .photo { margin: 0; }
main .photo img { width: 100%; height: auto; border-radius: var(--radius-card); border: 1px solid var(--hair); background: var(--ink-800); }
main .photo figcaption { margin-top: 0.75rem; font-size: var(--size-xs); line-height: 1.5; color: var(--quiet); }
main .photo figcaption .stamp { margin-right: 0.4em; vertical-align: 0.1em; font-size: var(--size-xs); color: var(--mute); border: 1px solid var(--hair-strong); }
main .photos { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 20rem)); justify-content: start; align-items: start; }

/* A strip of captures: capped columns on a wide screen, a swiping rail on a phone. */
main .shots { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 20rem)); justify-content: start; align-items: start; }
main .shots-swipe { display: none; }
@media (max-width: 39.999rem) {
  main .shots { grid-auto-flow: column; grid-auto-columns: 13rem; grid-template-columns: none; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 0.75rem; scrollbar-width: none; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); }
  main .shots::-webkit-scrollbar { display: none; }
  main .shots > * { scroll-snap-align: start; }
  main .shots-swipe { display: block; margin-top: 0.5rem; text-align: right; font-size: var(--size-xs); color: var(--quiet); }
}

/* The gallery's uneven grid: twelve columns, each figure its span. */
main .grid-uneven { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(1.25rem, 2.5vw, 2rem); align-items: start; }
main .grid-uneven > figure { width: 100%; margin: 0; }
main .span-4 { grid-column: span 4; } main .span-5 { grid-column: span 5; } main .span-6 { grid-column: span 6; }
main .span-7 { grid-column: span 7; } main .span-8 { grid-column: span 8; }
main .grid-uneven .screenshot img { max-width: 34rem; }
@media (max-width: 59.999rem) {
  main .grid-uneven > * { grid-column: span 6; }
}
@media (max-width: 34rem) {
  main .grid-uneven > * { grid-column: 1 / -1; }
  main .grid-uneven .screenshot img { max-width: none; }
}

/* The lightbox the captures open. It carries .screenshot; the figure's frame
   must not reach the dialog or whatever it shows. */
main #shot-dialog, #shot-dialog { padding: 0; border: 1px solid var(--hair-strong); border-radius: var(--radius-card); background: var(--ink-800); color: var(--text); max-width: min(96vw, 1100px); margin: auto; }
#shot-dialog::backdrop { background: rgba(3, 6, 11, 0.86); backdrop-filter: blur(6px); }
#shot-dialog img { aspect-ratio: auto; image-rendering: auto; object-fit: contain; max-height: 82vh; width: auto; max-width: 100%; margin: 0 auto; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: none; }
#shot-dialog figcaption { padding: 0.9rem 3.5rem 1rem 1.25rem; margin: 0; color: var(--mute); font-size: var(--size-sm); }
#shot-dialog figcaption:empty { display: none; }
#shot-dialog:focus, #shot-dialog:focus-visible { outline: none; box-shadow: none; }
.shot-close { position: absolute; top: 0.5rem; right: 0.5rem; z-index: 1; width: 2.75rem; height: 2.75rem; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--hair-strong); border-radius: 50%; background: var(--ink-700); color: var(--text); cursor: pointer; }
.shot-close:hover { color: var(--lum); border-color: var(--lum); }
.to-top { display: none; }

/* A range mark: a small square of the tier's colour ahead of the tier's name.
   The gallery carries the same rule inline; the tokens here are what give it
   its colours. Zone colours stay on readings. */
main .rng::before { content: ""; display: inline-block; width: 0.55em; height: 0.55em; margin-right: 0.45em; vertical-align: 0.04em; border-radius: 2px; background: var(--rng, currentColor); }
main .rng-in { --rng: var(--zone-ok); }
main .rng-high { --rng: var(--zone-high); }
main .rng-low { --rng: var(--zone-urgent); }
main .stamp-purple { color: var(--c-purple); }

/* --------------------------------------------------------------------------
   Callouts: night.css draws the pane; the legal pages add the prose class.
   -------------------------------------------------------------------------- */
main .callout.prose { max-width: var(--measure); }
main .callout p { color: var(--mute); }
main .callout p + p { margin-top: 0.8em; }
main .callout .callout-title { font-size: var(--size-base); }
main .callout.callout-safety.callout-danger { border-color: rgba(239, 68, 68, 0.45); }
main .callout.callout-safety.callout-danger .callout-title { color: var(--zone-urgent-text); }
main .callout a { color: var(--text); }
main .section-safety { padding-top: 0; }

/* --------------------------------------------------------------------------
   The spec list and the parts list: hairline rows.
   -------------------------------------------------------------------------- */
main .spec { margin: 0; border-top: 1px solid var(--hair); }
main .spec > div { display: grid; grid-template-columns: minmax(10rem, 18rem) minmax(0, 1fr); gap: 1.25rem; padding-block: 1.1rem; border-bottom: 1px solid var(--hair); }
main .spec dt { margin: 0; font: 500 var(--size-base) / 1.4 var(--font-body); color: var(--text); }
main .spec dd { margin: 0; max-width: 62ch; color: var(--mute); }
main .spec dd + dd { margin-top: 0.5rem; }
@media (max-width: 40rem) { main .spec > div { grid-template-columns: minmax(0, 1fr); gap: 0.3rem; } }

main .bom { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--hair); }
main .bom > li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); grid-template-areas: "qty item" ". note"; column-gap: 1rem; row-gap: 0.25rem; padding-block: 1rem; margin: 0; border-bottom: 1px solid var(--hair); }
main .bom > li > p { margin: 0; }
main .bom-qty { grid-area: qty; font: 400 var(--size-sm) / 1.6 var(--font-mono); font-variant-numeric: tabular-nums; color: var(--lum); text-shadow: var(--lum-text-shadow); }
main .bom-item { grid-area: item; font-weight: 500; color: var(--text); }
main .bom-note { grid-area: note; font-size: var(--size-sm); color: var(--mute); max-width: 62ch; }
@media (min-width: 48rem) {
  main .bom > li { grid-template-columns: 2.5rem minmax(0, 18rem) minmax(0, 1fr); grid-template-areas: "qty item note"; column-gap: 1.5rem; align-items: baseline; }
}

/* --------------------------------------------------------------------------
   Questions, folds and the phone disclosures.

   night.css sets summary to flex, which would un-hide a <summary hidden>, so
   the hidden summaries are hidden again here. On a phone the page scripts
   close these details, so there the summary is the row that reopens them, and
   the heading it repeats steps aside.
   -------------------------------------------------------------------------- */
main .faq details > p, main .faq details > div { color: var(--mute); max-width: var(--measure); }
main .faq details > :not(summary) + :not(summary) { margin-top: 0.75em; }
main .faq summary { min-height: 3rem; }

main .fold, main .m-fold { border: 0; }
main .fold > :not(summary), main .m-fold > :not(summary) { padding-bottom: 0; }
main .fold > summary[hidden], main .m-fold > summary[hidden] { display: none; }
main .fold > summary::after, main .m-fold > summary::after { content: none; }
main .fold > *:not(summary) + *, main .m-fold > *:not(summary) + * { margin-top: clamp(1.5rem, 3vw, 2.25rem); }
main .fold > .lede + .shots, main .fold > .lede + .prose, main .fold > .lede + ol, main .fold > .lede + ul { margin-top: 1.5rem; }
main .fold > .shots + .shots-swipe { margin-top: 0.5rem; }
main .fold > h3 + *, main .m-fold > h3 + * { margin-top: 0.75rem; }
main .fold > h3, main .m-fold > h3 { margin-top: clamp(2rem, 3.5vw, 3rem); }
main .fold > .lede, main .m-fold > .lede { max-width: var(--measure); }
main .fold > .callout, main .m-fold > .callout { max-width: var(--measure); }
main .fold-less { display: none; }
@media (max-width: 59.999rem) {
  main .fold > summary[hidden], main .m-fold > summary[hidden] {
    display: flex; align-items: center; justify-content: space-between; gap: 1rem;
    min-height: 3rem; padding: 0.75rem 0; margin: 0;
    border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair);
    font: 400 var(--size-lg) / 1.3 var(--font-display); color: var(--text); letter-spacing: -0.01em; text-wrap: balance;
  }
  main .fold > summary[hidden]::after, main .m-fold > summary[hidden]::after { content: ""; flex: none; width: 0.6rem; height: 0.6rem; border-right: 1px solid var(--lum); border-bottom: 1px solid var(--lum); transform: rotate(45deg); transition: transform var(--dur) var(--ease); }
  main .fold[open] > summary[hidden]::after, main .m-fold[open] > summary[hidden]::after { transform: rotate(225deg); }
  main .fold[open] > summary[hidden], main .m-fold[open] > summary[hidden] { margin-bottom: 1.25rem; }
  main .section .container > .m-fold, main .section .container > .fold { margin-top: 1.25rem; }
  /* The fold's summary carries the heading's words, so the heading itself
     steps out of the screen layout (it stays for headings navigation and its
     anchor). The guide's section lede sits inside the fold. */
  main .section h2:has(+ .fold), main .section h2:has(+ details.m-fold) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  main .section h2:has(+ .fold) + .fold, main .section h2:has(+ details.m-fold) + .m-fold { margin-top: 0; }
  main .section h2:has(+ .fold) + .fold > summary[hidden], main .section h2:has(+ details.m-fold) + .m-fold > summary[hidden] { border-top: 0; }
  main .band .m-fold:not([open]) > summary[hidden] { border-bottom: 0; }
  main .fold:not([open]) > .fold-less, main .fold[open] > summary > .fold-more { display: none; }
  main .fold[open] > summary > .fold-less { display: inline; }
  main .fold:not([open]) > summary > .fold-more { display: inline; }
  /* The questions fold on the guide keeps its own summary at the row size. */
  main .faq + .fold > summary[hidden], main .faq .fold > summary[hidden] { font: 500 var(--size-base) / 1.3 var(--font-body); }
}

/* --------------------------------------------------------------------------
   Tables that scroll on a phone. night.css frames .table-wrap already.
   -------------------------------------------------------------------------- */
main .table-wrap { background: var(--ink-800); }
main .data-table { min-width: 36rem; }
main .data-table td { color: var(--mute); }
main .data-table td strong { color: var(--text); font-weight: 500; }

/* --------------------------------------------------------------------------
   The tools on the provider pages and the guide: a pane each, and a strip of
   chips. The colour each tool carried is now a single lit dot.
   -------------------------------------------------------------------------- */
main .tool-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
@media (min-width: 48rem) { main .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; } }
main .tool-card { display: grid; gap: 0.75rem; align-content: start; padding: clamp(1.25rem, 2.5vw, 2rem); background: var(--ink-700); border: 1px solid var(--hair); border-radius: var(--radius-card); }
main .tool-head { margin: 0; font-size: var(--size-lg); line-height: 1.3; }
main .tool-body { margin: 0; color: var(--mute); max-width: 48ch; }
main .tool-actions { margin: 0.5rem 0 0; }
/* One lit action in the band: the first card's. */
main .tool-card:not(:first-child) .btn-primary { background: transparent; color: var(--text); border-color: var(--hair-strong); box-shadow: none; }
main .tool-card:not(:first-child) .btn-primary:hover { color: var(--lum); border-color: var(--lum); background: transparent; }
main .tool-rows { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: 0; border-top: 1px solid var(--hair); }
main .tool-row { display: grid; gap: 0.25rem; padding: 1rem 0; border-bottom: 1px solid var(--hair); }
main .tool-row-head { margin: 0; font-size: var(--size-base); font-weight: 500; }
main .tool-row-head a { text-decoration: none; }
main .tool-row-head a:hover { color: var(--lum); }
main .tool-row-body { margin: 0; color: var(--mute); font-size: var(--size-sm); max-width: 60ch; }

main .tool-strip { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.25rem 0 0; padding: 0; }
main .tool-strip li { margin: 0; }
main .tool-strip a { display: inline-flex; align-items: center; gap: 0.6rem; min-height: 2.75rem; padding: 0.5rem 1rem; border: 1px solid var(--hair-strong); border-radius: var(--radius-pill); color: var(--mute); font: 500 var(--size-sm) / 1.2 var(--font-body); text-decoration: none; transition: color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease); }
main .tool-strip a:hover { color: var(--text); border-color: var(--quiet); }
main .tool-mark { width: 0.45rem; height: 0.45rem; border-radius: 50%; background: var(--tool, var(--lum)); box-shadow: 0 0 8px var(--tool, var(--lum)); }
main .tool-strip .tool-green, main [data-tool="viewer"] { --tool: var(--zone-ok); }
main .tool-strip .tool-amber { --tool: var(--zone-high); }
main .tool-strip .tool-purple, main [data-tool="beta"] { --tool: var(--c-purple); }
main .tool-strip .tool-accent, main [data-tool="flash"] { --tool: var(--lum); }
main .tools-section { padding-block: 0; }
main .tools-section .container { padding-inline: 0; }

/* --------------------------------------------------------------------------
   The closing line of a section, and the page's foot: a pager and "where next".
   -------------------------------------------------------------------------- */
main .section-note { margin-top: 1.75rem; font: 400 var(--size-xs) / 1.6 var(--font-mono); letter-spacing: 0.04em; color: var(--quiet); }
main .page-foot { margin-top: var(--space-section); }
main .page-foot + .section { padding-top: clamp(2.5rem, 5vw, 4rem); }
main .pager { display: grid; gap: 1rem; }
@media (min-width: 40rem) { main .pager { grid-template-columns: 1fr 1fr; } }
main .pager a { display: block; min-height: 3.5rem; padding: 1rem 1.25rem; border: 1px solid var(--hair); border-radius: var(--radius-card); color: var(--text); text-decoration: none; transition: border-color var(--dur-fast) var(--ease); }
main .pager a:hover { border-color: var(--lum); color: var(--text); }
main .pager-next { grid-column: 2; text-align: right; }
main .pager-prev { grid-column: 1; }
@media (max-width: 39.999rem) { main .pager-prev, main .pager-next { grid-column: 1; text-align: left; } }
main .pager-dir { display: block; font-size: var(--size-xs); letter-spacing: 0.04em; text-transform: uppercase; color: var(--quiet); }
main .pager-title { display: block; margin-top: 0.2rem; font-weight: 500; }
main .related { margin-top: 2rem; }
main .related h2 { font: 500 var(--size-xs) / 1.4 var(--font-body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--quiet); }
main .related ul { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.75rem 0 0; padding: 0; list-style: none; }
main .related a { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0.5rem 1rem; font-size: var(--size-sm); color: var(--mute); border: 1px solid var(--hair-strong); border-radius: var(--radius-pill); text-decoration: none; }
main .related a:hover { color: var(--text); border-color: var(--quiet); }

/* --------------------------------------------------------------------------
   The legal pages: a contents list beside the numbered sections.
   -------------------------------------------------------------------------- */
main .legal-body > .section { padding-block: clamp(2.5rem, 5vw, 4rem); }
main .legal-body > .section:first-child { padding-top: 0; }
@media (max-width: 59.999rem) { main .legal-body > .section { padding-block: 1.5rem; } main .legal-body > .section:first-child { padding-top: 0; } }
main .legal-body > .section + .section { border-top: 1px solid var(--hair); }
main .legal-body .prose { max-width: var(--measure); }
main .legal-body .prose p { color: var(--mute); }
main .legal-body .callout.prose p { color: var(--mute); }
main .legal-body .callout.prose p strong { color: var(--text); }
main .legal-toc { margin: 0 0 clamp(2rem, 4vw, 3rem); border: 1px solid var(--hair); border-radius: var(--radius-card); background: var(--ink-700); }
main .legal-toc > summary { padding: 0.9rem 1.25rem; font: 500 var(--size-sm) / 1.3 var(--font-body); color: var(--lum); }
main .legal-toc[open] > summary { border-bottom: 1px solid var(--hair); }
main .legal-toc ol { list-style: none; margin: 0; padding: 0.5rem 0.75rem; }
main .legal-toc li { margin: 0; }
main .legal-toc a { display: flex; gap: 0.75rem; align-items: baseline; min-height: 2.75rem; padding: 0.5rem; color: var(--mute); text-decoration: none; font-size: var(--size-sm); border-radius: var(--radius-sm); }
main .legal-toc a:hover { color: var(--text); background: var(--color-hover-veil); }
main .legal-toc-num { flex: none; font: 400 var(--size-xs) / 1.6 var(--font-mono); color: var(--quiet); }
main .legal-toc > :not(summary) { padding-bottom: 0.25rem; }
@media (min-width: 64rem) {
  main .legal-layout > .container { display: grid; grid-template-columns: minmax(12rem, 16rem) minmax(0, 1fr); column-gap: clamp(2rem, 5vw, 4rem); align-items: start; }
  main .legal-rail { position: sticky; top: calc(var(--bar-height) + 1.5rem); max-height: calc(100vh - var(--bar-height) - 3rem); overflow-y: auto; }
  /* Open for good in this column: there is nothing for it to save here. */
  main .legal-toc { border: 0; border-radius: 0; background: none; margin: 0; }
  main .legal-toc > summary { pointer-events: none; cursor: default; padding: 0 0 0.75rem; font: 500 var(--size-xs) / 1.4 var(--font-body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--quiet); }
  main .legal-toc > summary::after { content: none; }
  main .legal-toc[open] > summary { border-bottom: 0; }
  main .legal-toc::details-content { content-visibility: visible; display: block; block-size: auto; }
  main .legal-toc ol { padding: 0; border-top: 1px solid var(--hair); }
  main .legal-toc li { border-bottom: 1px solid var(--hair); }
  main .legal-toc a { padding: 0.6rem 0.25rem; border-radius: 0; }
  main .legal-toc a:hover { background: none; }
}

/* --------------------------------------------------------------------------
   The stories and the pullquote.
   -------------------------------------------------------------------------- */
main .story { padding: clamp(1.25rem, 2.5vw, 2rem); background: var(--ink-700); border: 1px solid var(--hair); border-radius: var(--radius-card); }
main .story + .story { margin-top: 1.25rem; }
main .story blockquote, main .pullquote blockquote { margin: 0; }
main .story blockquote p:first-child, main .pullquote blockquote p:first-child { font: 300 clamp(1.25rem, 1rem + 0.8vw, 1.6rem) / 1.35 var(--font-display); color: var(--text); letter-spacing: -0.01em; }
main .story p { color: var(--mute); }
main .story-attrib { margin-top: 1rem; font-size: var(--size-sm); color: var(--quiet); }
main .story-name { color: var(--text); font-weight: 500; }

/* --------------------------------------------------------------------------
   The search dialog every page carries in its body.
   -------------------------------------------------------------------------- */
#search-dialog { width: min(94vw, 40rem); padding: 0; border: 1px solid var(--hair-strong); border-radius: var(--radius-card); background: var(--ink-800); color: var(--text); margin-top: 10vh; }
#search-dialog::backdrop { background: rgba(3, 6, 11, 0.8); backdrop-filter: blur(6px); }
.search-form { display: block; padding: 1rem 1rem 0.75rem; }
.search-results { list-style: none; margin: 0; padding: 0 1rem; max-height: 50vh; overflow-y: auto; }
.search-results:empty { display: none; }
.search-results li { margin: 0; }
.search-results a, .search-results [role="option"] { display: block; padding: 0.6rem 0.75rem; border-radius: var(--radius-sm); color: var(--text); text-decoration: none; }
.search-results [aria-selected="true"], .search-results a:hover { background: var(--color-hover-veil); color: var(--lum); }
.search-hint { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; padding: 0.75rem 1rem 1rem; margin: 0; font-size: var(--size-xs); color: var(--quiet); }
.search-hint kbd { margin-right: 0.2em; }

/* Plain lists in the prose and the folds read in the body colour. */
main .prose ul, main .prose ol, main .fold > :is(ul, ol):not([class]), main .m-fold > :is(ul, ol):not([class]) { color: var(--mute); padding-left: 1.3rem; }
main .fold > :is(ul, ol):not([class]), main .m-fold > :is(ul, ol):not([class]) { max-width: var(--measure); margin: 1rem 0 0; }
main .fold > :is(ul, ol):not([class]) li + li, main .m-fold > :is(ul, ol):not([class]) li + li { margin-top: 0.4em; }
main .prose h2 { margin-top: 2.2em; }
main .prose h3 { margin-top: 1.8em; }
main .prose h3:first-child { margin-top: 0; }
main .prose p { color: var(--mute); }
main .prose strong { color: var(--text); }
main .lede { color: var(--mute); }

/* The "Where next" links in the older footer nav: the kit's target size. */
main .related a, .related a { display: inline-flex; align-items: center; min-height: 2.75rem; }

/* The older pages' opening: the heading first, the version tag and date as a meta line under it. */
main .hero-copy { display: flex; flex-direction: column; }
main .hero-copy > h1 { order: -3; }
main .hero-copy > .eyebrow, main .hero-copy > .log-date { order: -2; }
main .hero-copy > .eyebrow { margin-top: 1rem; }
main .hero-copy > .lede { order: -1; margin-top: 1.25rem; }
