/* ==========================================================================
 * THE SECTION NAVIGATION of a listing's and a project's page (owner, 21
 * November 2026: "we need to add a navigation bar to the left of the listing
 * page to see which section we are in ... make it a vertical nav bar", then
 * "add some animations to it, like it should feel like scrolling", and shown
 * six designs, "give all options and should be able to change in nav bar in
 * pages and copy"). The approved preview's stylesheet, reproduced
 * (_reports/artifacts/section-navigation-options-2026-11-21.html): the same
 * six designs, the same widths, the same row on a phone. What differs is only
 * where it hangs - the design is the server's choice, written on the one
 * container as data-sn-design (content/section_nav.py), where the preview's
 * bar set it on the root - and what a real page needs that a preview did not:
 * right to left mirrored, the right-hand column's boxes in the row only where
 * that column is under the reading one, and the markup drawn by the server
 * (macros/sectionnav.html) rather than by the script.
 *
 * Linked only by a page that draws the navigation: with the setting Off the
 * page loads none of this. Every moving part is drawn by transform alone, set
 * by sectionnav.js on an animation frame from the scroll position; colours are
 * the site's tokens and glass is the site's --lg- glass.
 * ======================================================================== */
.snhost { --sn-w: 128px; --sn-gap: 26px; --sn-head: 85px; --sn-row6: 34px; position: relative; }
.snhost[data-sn-design="list"] { --sn-w: 150px; }
.snhost[data-sn-design="chapters"] { --sn-w: 140px; }
.snhost[data-sn-design="dots"] { --sn-w: 112px; }
.snhost[data-sn-design="glass"] { --sn-w: 176px; }
.snhost[data-sn-design="bar"] { --sn-w: 150px; }

/* One container (.snhost) holds the page's own sections, from the breadcrumb
   to the questions; the navigation is sticky inside it. From 1100px it is a
   column at the left: the content's left edge moves right only by what the
   page's own margin cannot give, its right edge stays on the header's. Below
   1100px it is the sticky row under the header. */
.sntrack { position: absolute; inset: 0; z-index: 6; pointer-events: none; display: none; }
.sntrack > .wrap { height: 100%; padding-top: calc(34px * var(--space-sec)); }
.sn { position: sticky; top: calc(var(--sn-head) + 30px); width: var(--sn-w);
  margin-inline-start: calc(-1 * (var(--sn-w) + var(--sn-gap))); pointer-events: auto; font-family: var(--sans); }
@media (min-width: 1100px) {
  .sntrack { display: block; }
  .snrow { display: none; }
  .snhost .wrap { padding-inline-start: max(30px, calc(var(--sn-w) + var(--sn-gap) + 16px - max(0px, (100vw - 1188px) / 2))); }
}

.sn-kick { display: none; margin: 2px 0 12px; font-size: 9.5px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--muted); font-weight: 400; line-height: 1.4; }
.sn-body { position: relative; }
.sn-list { position: relative; list-style: none; margin: 0; padding: 0; }
.sn-link { position: relative; display: block; text-decoration: none; color: var(--muted); font-weight: 400;
  transition: color .25s ease, opacity .25s ease; }
.sn-link:hover { color: var(--gold); }
.sn-link:focus-visible, .snrow-in a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.sn-num, .sn-short { display: none; }
/* a section a link takes the reader to stops just under the header (and the row, below 1100px): what the
   script's glide measures, and where a plain jump lands with scripts off */
.snhost :is([id^="sn-"], #pagefaq) { scroll-margin-top: calc(var(--sn-head) + 16px); }
@media (max-width: 1099.98px) { .snhost :is([id^="sn-"], #pagefaq) { scroll-margin-top: calc(var(--sn-head) + 60px); } }
/* a section a keyboard press moved the reading place into (sectionnav.js): a place to read from, not a control */
.snhost [data-sn-focus]:focus { outline: none; }

/* the moving parts; each design shows the ones it uses */
.sn-line, .sn-prog, .sn-mark, .sn-bar, .sn-pill, .sn-ring, .sn-head, .sn-ride { display: none; position: absolute;
  inset-inline-start: 0; top: 0; pointer-events: none; will-change: transform; }
.sn-line { bottom: 0; width: 1px; background: var(--line); }
.sn-prog { width: 1px; height: 100%; background: var(--gold); transform-origin: 0 0; transform: scaleY(0); }

/* 1 - SLIM RAIL: one hairline, a tick for each section, the site's own gold
   diamond gliding down it, the line gold above it */
.snhost[data-sn-design="rail"] :is(.sn-line, .sn-prog, .sn-mark) { display: block; }
.snhost[data-sn-design="rail"] :is(.sn-line, .sn-prog) { inset-inline-start: 5px; }
.snhost[data-sn-design="rail"] .sn-mark { inset-inline-start: 1px; top: -4.5px; width: 9px; height: 9px; background: var(--gold);
  transform: translate3d(0, 0, 0) rotate(45deg); }
.snhost[data-sn-design="rail"] .sn-list { padding-inline-start: 20px; }
.snhost[data-sn-design="rail"] .sn-link { padding: 7px 0; font-size: 12.5px; line-height: 1.35; letter-spacing: .01em; }
.snhost[data-sn-design="rail"] .sn-link::before { content: ""; position: absolute; inset-inline-start: -16px; top: 50%; width: 3px;
  height: 3px; margin-top: -1.5px; border-radius: 50%; background: var(--muted); opacity: .6; }
.snhost[data-sn-design="rail"] .sn-link[aria-current="true"] { color: var(--text); }

/* 2 - QUIET LIST: "On this page", small capitals like the section headings,
   a faint track, a gold bar gliding beside the current entry */
.snhost[data-sn-design="list"] .sn-kick { display: block; }
.snhost[data-sn-design="list"] :is(.sn-line, .sn-prog, .sn-bar) { display: block; }
.snhost[data-sn-design="list"] .sn-line { background: var(--sep); }
.snhost[data-sn-design="list"] .sn-prog { opacity: .55; }
.snhost[data-sn-design="list"] .sn-bar { inset-inline-start: -.5px; width: 2px; height: 1px; background: var(--gold);
  transform-origin: 0 0; transform: scaleY(0); }
.snhost[data-sn-design="list"] .sn-link { padding-block: 8px; padding-inline: 14px 0; font-size: 10px; line-height: 1.5;
  letter-spacing: .15em; text-transform: uppercase; }
.snhost[data-sn-design="list"] .sn-link[aria-current="true"] { color: var(--gold); }

/* 3 - NUMBERED CHAPTERS: 01, 02 ... in Marcellus beside short names; a gold
   line fills down beside the numbers */
.snhost[data-sn-design="chapters"] :is(.sn-line, .sn-prog) { display: block; inset-inline-start: 3px; }
.snhost[data-sn-design="chapters"] .sn-line { background: var(--sep); }
.snhost[data-sn-design="chapters"] .sn-list { padding-inline-start: 16px; }
.snhost[data-sn-design="chapters"] .sn-link { display: flex; align-items: baseline; gap: 10px; padding: 7px 0;
  font-size: 12.5px; line-height: 1.35; }
.snhost[data-sn-design="chapters"] .sn-num { display: block; flex: none; width: 24px; font-family: var(--serif);
  font-size: 16px; line-height: 1; color: var(--muted); opacity: .7; transition: color .25s ease, opacity .25s ease; }
.snhost[data-sn-design="chapters"] .sn-word { display: none; }
.snhost[data-sn-design="chapters"] .sn-short { display: block; }
.snhost[data-sn-design="chapters"] .sn-link[aria-current="true"] { color: var(--text); }
.snhost[data-sn-design="chapters"] .sn-link[aria-current="true"] .sn-num { color: var(--gold); opacity: 1; }

/* 4 - DOTS: a column of small dots, a gold ring gliding over them; only the
   current section's name shows, any other on hover or focus */
.snhost[data-sn-design="dots"] .sn-ring { display: block; inset-inline-start: 0; top: -7px; width: 14px; height: 14px;
  border-radius: 50%; border: 1.5px solid var(--gold); }
.snhost[data-sn-design="dots"] .sn-link { height: 26px; }
.snhost[data-sn-design="dots"] .sn-link::before { content: ""; position: absolute; inset-inline-start: 4px; top: 50%;
  width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: var(--muted); opacity: .55;
  transition: opacity .25s ease; }
.snhost[data-sn-design="dots"] .sn-link[aria-current="true"]::before { background: var(--gold); opacity: 1; }
.snhost[data-sn-design="dots"] .sn-word { display: none; }
.snhost[data-sn-design="dots"] .sn-short { display: block; position: absolute; inset-inline-start: 22px; top: 50%;
  white-space: nowrap; font-size: 11.5px; line-height: 1; letter-spacing: .04em; opacity: 0;
  transform: translate3d(-4px, -50%, 0); transition: opacity .2s ease, transform .2s ease; }
.snhost[data-sn-design="dots"] .sn-link:is(:hover, :focus-visible, [aria-current="true"]) .sn-short { opacity: 1;
  transform: translate3d(0, -50%, 0); }
[dir="rtl"] .snhost[data-sn-design="dots"] .sn-short { transform: translate3d(4px, -50%, 0); }
[dir="rtl"] .snhost[data-sn-design="dots"] .sn-link:is(:hover, :focus-visible, [aria-current="true"]) .sn-short {
  transform: translate3d(0, -50%, 0); }
.snhost[data-sn-design="dots"] .sn-link[aria-current="true"] { color: var(--text); }

/* 5 - GLASS CARD: the site's liquid glass, floating at the left, a gold pill
   sliding behind the current entry */
.snhost[data-sn-design="glass"] .sn { padding: 12px 10px 10px; border-radius: var(--lg-radius);
  border: 1px solid var(--lg-rim); background: var(--lg-sheen), var(--lg-fill); box-shadow: var(--lg-lift-soft);
  -webkit-backdrop-filter: var(--lg-blur);
  backdrop-filter: var(--lg-blur); }
.snhost[data-sn-design="glass"] .sn-kick { display: block; margin: 0 10px 8px; }
.snhost[data-sn-design="glass"] .sn-pill { display: block; inset-inline: 0; height: 32px; border-radius: 999px;
  background: color-mix(in srgb, var(--gold) 20%, transparent);
  border: 1px solid color-mix(in srgb, var(--gold) 55%, transparent); }
.snhost[data-sn-design="glass"] .sn-link { position: relative; z-index: 1; height: 32px; display: flex; align-items: center;
  padding: 0 12px; border-radius: 999px; font-size: 12px; line-height: 1; white-space: nowrap; }
.snhost[data-sn-design="glass"] .sn-link[aria-current="true"] { color: var(--text); }

/* 6 - PROGRESS BAR: a bar with a tick for each section and a gold head; the
   current section's name rides beside the head; hover or focus shows them all.
   The bar runs the list's own height: one 34px row an entry. */
.snhost[data-sn-design="bar"] :is(.sn-line, .sn-prog) { display: block; inset-inline-start: 0; width: 3px;
  border-radius: 2px; }
.snhost[data-sn-design="bar"] .sn-line { background: var(--sep); }
.snhost[data-sn-design="bar"] .sn-head { display: block; inset-inline-start: -3px; top: -4.5px; width: 9px; height: 9px;
  border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px color-mix(in srgb, var(--gold) 22%, transparent); }
.snhost[data-sn-design="bar"] .sn-ride { display: block; inset-inline-start: 16px; top: 0; white-space: nowrap;
  font-size: 12px; line-height: 1; color: var(--text); transform: translate3d(0, -50%, 0); transition: opacity .2s ease; }
.snhost[data-sn-design="bar"] .sn-link { height: var(--sn-row6); padding-inline-start: 16px; font-size: 12px;
  line-height: var(--sn-row6); white-space: nowrap; opacity: 0; }
.snhost[data-sn-design="bar"] .sn-link::before { content: ""; position: absolute; inset-inline-start: 4px; top: 50%;
  width: 5px; height: 1px; background: var(--muted); opacity: .8; }
.snhost[data-sn-design="bar"] .sn-link[aria-current="true"] { color: var(--gold); }
.snhost[data-sn-design="bar"] .sn:is(:hover, :focus-within) .sn-link { opacity: 1; }
.snhost[data-sn-design="bar"] .sn:is(:hover, :focus-within) .sn-ride { opacity: 0; }

/* THE PHONE (below 1100px): one sticky row under the header in the header's
   own glass, for every design; a gold underline glides under the entries and
   the strip slides to keep it in view. The right-hand column's reading boxes
   join the row only where that column falls under the reading column (site.css
   `.dgrid`, 900px and below). A mask reads only the alpha of its gradient. */
.snrow { position: sticky; top: var(--sn-head); z-index: 58;
  background: color-mix(in srgb, var(--nav-bg) 62%, transparent);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 55%, transparent); }
:root[data-skin="dark"] .snrow { background: color-mix(in srgb, var(--nav-bg) 58%, transparent); }
.snrow-in { position: relative; overflow-x: auto; scrollbar-width: none; padding-block: 0; padding-inline: 30px 44px;
  -webkit-mask-image: linear-gradient(90deg, transparent, black 22px, black calc(100% - 44px), transparent);
          mask-image: linear-gradient(90deg, transparent, black 22px, black calc(100% - 44px), transparent); }
[dir="rtl"] .snrow-in {
  -webkit-mask-image: linear-gradient(270deg, transparent, black 22px, black calc(100% - 44px), transparent);
          mask-image: linear-gradient(270deg, transparent, black 22px, black calc(100% - 44px), transparent); }
.snrow-in::-webkit-scrollbar { display: none; }
.snrow-in ol { display: flex; gap: 24px; width: max-content; list-style: none; margin: 0; padding: 0; }
.snrow-in li { flex: none; }
@media (min-width: 901px) { .snrow-in li[data-sn-side] { display: none; } }
.snrow-in a { display: block; padding: 15px 0 13px; font-size: 10.5px; letter-spacing: .15em; text-transform: uppercase;
  color: var(--muted); white-space: nowrap; text-decoration: none; font-weight: 400; line-height: 1.4;
  transition: color .25s ease; }
.snrow-in a[aria-current="true"] { color: var(--gold); }
.snrow-ink { position: absolute; left: 0; bottom: 0; width: 1px; height: 2px; background: var(--gold);
  transform-origin: 0 0; transform: scaleX(0); will-change: transform; pointer-events: none; }

/* reduced motion: the script places every part on the current entry without
   gliding, and nothing fades */
@media (prefers-reduced-motion: reduce) {
  .sn-link, .sn-num, .sn-short, .sn-ride, .snrow-in a,
  .snhost[data-sn-design="dots"] .sn-link::before { transition: none; }
}
