/*
 * quwire.app articles: the "Blueprint" figure system and its editorial parts. Loads after site.css on article pages
 * and on /guides/, uses only site.css's tokens, and never restyles a site class.
 *
 * Figures are line drawings of one fact each, generated in code (make site-figures): 1.5 px objects, 1.25 px planes,
 * 1 px leaders, all non-scaling; ink for objects, slate for the subject, greys for construction. Each SVG figure has
 * a desktop and a phone artboard, so its type stays 11 px or larger. Motion explains a change, then rests on the
 * final state, which is also what Reduce Motion shows.
 */

:root {
  --qf-grid-dot: #dcdcdc;
  --qf-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --qf-full: 1120px;
  --qf-wide: 960px;
}

/* The glyph sprite: in the page, as a <use> needs it in the same document, but takes no room. */
.qf-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* --- reading column */

.qf-lede strong {
  color: var(--ink);
}

.qf .updated {
  margin-top: 18px;
}

.qf-byline {
  color: var(--body);
  font-weight: var(--weight-700);
}

/* --- figures: column 760, wide 960, full 1120, side 280 */

.qf-fig {
  margin: clamp(36px, 5vw, 56px) 0;
}

.qf-fig--wide {
  --qf-w: var(--qf-wide);
}

.qf-fig--full {
  --qf-w: var(--qf-full);
}

/* Wide and full figures break out of the reading column, centred on it, never wider than the window's gutters. */
.qf-fig--wide,
.qf-fig--full {
  width: min(var(--qf-w), 100vw - 2 * var(--gutter));
  margin-inline: calc((100% - min(var(--qf-w), 100vw - 2 * var(--gutter))) / 2);
}

.qf-plate {
  position: relative;
  border-radius: var(--radius-tile);
}

/* A card holds UI; a sheet (with a dot grid) holds data; slate holds Quwire; open holds heroes. */
.qf-plate--card {
  padding: clamp(14px, 3vw, 36px);
  background: var(--white);
  box-shadow: var(--shadow-tile);
}

.qf-plate--sheet {
  padding: clamp(14px, 3vw, 36px);
  background-color: var(--white);
  background-image: radial-gradient(circle, var(--qf-grid-dot) 0.8px, transparent 1.3px);
  background-position: 10px 10px;
  background-size: 20px 20px;
  box-shadow: inset 0 0 0 1px var(--grey-200), var(--shadow-hairline);
}

/* A sheet's phone board keeps its 12.5 px type at 11 px or more down to 370 px; narrower, it takes the plate's full
   width (its own frame keeps the margin), and its small type gains a unit (below). */
@media (max-width: 639px) {
  .qf-plate--sheet {
    padding: 8px;
  }
}

@media (max-width: 369px) {
  .qf-plate--sheet {
    padding-inline: 0;
  }
}

.qf-plate--slate {
  padding: clamp(16px, 3.4vw, 44px);
  background: var(--slate);
  box-shadow: var(--shadow-tile);
}

/* Artboards: the large one by default; the small one where the large one would set its type under 11 px: under
   1100 px for full figures, 880 px for wide ones and 840 px for the rest. */

.qf-art {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  fill: none;
  stroke: var(--body);
  stroke-width: 1.5px;
  stroke-linecap: round;
  stroke-linejoin: round;
  font-family: var(--font);
}

.qf-ab-s {
  display: none;
  max-width: 460px;
  margin-inline: auto;
}

/* The hero's phone board, 340 px wide at most: 660 px tall, so cause and effect share a landscape tablet's screen. */
.qf-fig--full .qf-ab-s {
  max-width: 340px;
}

@media (max-width: 1099px) {
  .qf-fig--full .qf-ab-l {
    display: none;
  }

  .qf-fig--full .qf-ab-s {
    display: block;
  }
}

@media (max-width: 879px) {
  .qf-fig--wide .qf-ab-l {
    display: none;
  }

  .qf-fig--wide .qf-ab-s {
    display: block;
  }
}

@media (max-width: 839px) {
  .qf-ab-l {
    display: none;
  }

  .qf-ab-s {
    display: block;
  }
}

/* Lines. */

.qf-art .ln-h { stroke-width: 1.25px; }
.qf-art .w-1 { stroke-width: 1px; }
.qf-art .w-2 { stroke-width: 2px; }
.qf-art .ln-0 { stroke: none; }
.qf-art .ln-ink { stroke: var(--body); }
.qf-art .ln-soft { stroke: var(--grey-300); stroke-width: 1.25px; }
.qf-art .ln-mute { stroke: var(--grey-400); }
.qf-art .ln-acc { stroke: var(--slate); }
.qf-art .ln-paper { stroke: var(--white); }
.qf-art .ln-ghost { stroke: var(--grey-400); stroke-width: 1.25px; stroke-dasharray: 2.5 3; }
.qf-art .ln-dash { stroke-dasharray: 4 4; }
.qf-art .ln-lead,
.qf-art .ln-dim { fill: none; stroke: var(--secondary); stroke-width: 1px; }
.qf-art .ln-ext { stroke: var(--grey-300); stroke-width: 1px; }

/* Sound in transit: dotted, 2.5 px. */
.qf-art .ln-flow {
  stroke: var(--slate);
  stroke-dasharray: 0 10;
  stroke-width: 2.5px;
}

/* Fills. */

.qf-art .f-0 { fill: none; }
.qf-art .f-paper { fill: var(--white); }
.qf-art .f-50 { fill: var(--grey-50); }
.qf-art .f-l { fill: var(--grey-100); }
.qf-art .f-r { fill: var(--grey-200); }
.qf-art .f-acc { fill: var(--slate); }
.qf-art .f-ink { fill: var(--body); }

/* Glyphs (a <use> of a symbol): white bodies that hide what's behind them. Dashed when away, slate when the subject. */

.qf-art use { fill: var(--white); }
.qf-art .u-ghost { fill: rgba(255, 255, 255, 0.8); stroke: var(--grey-400); stroke-width: 1.25px; stroke-dasharray: 2.5 3; }
.qf-art .u-out { stroke: var(--grey-400); }
.qf-art .u-acc { stroke: var(--slate); stroke-width: 1.75px; }

/* Type in figures: labels 15/600, notes 13/400, eyebrows 11/600 tracked, numbers tabular. Never uppercase "macOS". */

.qf-art text {
  fill: var(--body);
  stroke: none;
  font-size: 15px;
  font-weight: var(--weight-700);
  letter-spacing: -0.005em;
}

.qf-art .tx-sub { fill: var(--secondary); font-size: 13px; font-weight: var(--weight-400); letter-spacing: 0; }
.qf-art .tx-cap { fill: var(--secondary); font-size: 11px; font-weight: var(--weight-700); letter-spacing: 0.08em; }
.qf-art .tx-tick { fill: var(--secondary); font-size: 12px; font-weight: var(--weight-400); font-variant-numeric: tabular-nums; }
.qf-art .tx-acc { fill: var(--slate); }
.qf-art .tx-mid { text-anchor: middle; }
.qf-art .tx-end { text-anchor: end; }

/* A desktop board renders at 0.9–1.1 of its size, so its smallest type is set a little larger. */
.qf-ab-l .tx-cap { font-size: 12.5px; }
.qf-ab-l .tx-tick { font-size: 12.5px; }

/* A phone board renders at 0.9–1 of its size on a phone, so its smallest type is 12.5: 11 px or more at 375 px. */
.qf-ab-s text { font-size: 14px; }
.qf-ab-s .tx-sub,
.qf-ab-s .tx-cap,
.qf-ab-s .tx-tick { font-size: 12.5px; }

/* Under 370 px a phone board renders at 0.8–0.92 of its size, so its small type gains a unit: 11 px or more at 320. */
@media (max-width: 369px) {
  .qf-ab-s .tx-sub,
  .qf-ab-s .tx-cap,
  .qf-ab-s .tx-tick { font-size: 13.5px; }
}

/* On slate everything inverts: white lines, slate bodies, white type. */

.qf-plate--slate .qf-art { stroke: var(--white); }
.qf-plate--slate .qf-art use { fill: var(--slate); }
.qf-plate--slate .qf-art .ln-soft { stroke: rgba(255, 255, 255, 0.28); }
.qf-plate--slate .qf-art .ln-flow { stroke: var(--white); }

/* --- captions */

.qf-cap {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 14px;
  max-width: 720px;
  margin-top: 16px;
  color: var(--secondary);
  font-size: 14px;
  line-height: 1.5;
  text-wrap: pretty;
}

.qf-cap b {
  color: var(--ink);
  font-weight: var(--weight-700);
}

.qf-cap-num {
  padding-top: 2px;
  color: var(--slate);
  font-size: 11px;
  font-weight: var(--weight-800);
  letter-spacing: 0.08em;
  line-height: 1.6;
  text-transform: uppercase;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* Set as written, never uppercased: a tag names macOS. */
.qf-cap-tag {
  display: inline-block;
  margin-left: 4px;
  padding: 0 9px;
  border: 1px solid var(--grey-300);
  border-radius: 999px;
  color: var(--secondary);
  font-size: 11.5px;
  font-weight: var(--weight-700);
  letter-spacing: 0.01em;
  line-height: 19px;
  white-space: nowrap;
}

/* Shown only while motion is on. */
.qf-motion-only {
  display: none;
}

/* Captions stay in the reading column, even under a figure that breaks out of it. */
.qf-fig--wide .qf-cap,
.qf-fig--full .qf-cap {
  margin-left: calc((100% - min(760px, 100%)) / 2);
}

@media (max-width: 639px) {
  .qf-cap {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* --- side figure: inline; column-wide from 640 px, stops in a row; from 1600 px in the margin, out of the flow */

.qf-fig--side {
  max-width: 340px;
  margin: 28px 0;
}

.qf-fig--side .qf-cap {
  grid-template-columns: minmax(0, 1fr);
  font-size: 13px;
}

@media (min-width: 640px) and (max-width: 1599px) {
  .qf-fig--side {
    max-width: none;
  }

  .qf-fig--side .qf-cap {
    grid-template-columns: auto minmax(0, 1fr);
    font-size: 14px;
  }
}

@media (min-width: 1600px) {
  .qf {
    position: relative;
  }

  .qf-fig--side {
    position: absolute;
    right: calc(var(--gutter) - 320px);
    width: 280px;
    margin-top: 4px;
  }
}

/* --- the settings path, a line of stops */

.qf-path {
  padding: 20px 22px 18px;
}

.qf-path-k {
  color: var(--secondary);
  font-size: 11px;
  font-weight: var(--weight-700);
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}

.doc .qf-path-list {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.doc .qf-path-list li {
  position: relative;
  margin: 0;
  padding: 0 0 18px 28px;
}

.qf-path-list b {
  display: block;
  color: var(--ink);
  font-size: 15px;
  font-weight: var(--weight-700);
  line-height: 1.35;
}

.qf-path-list li > span {
  display: block;
  margin-top: 2px;
  color: var(--secondary);
  font-size: 13px;
  line-height: 1.45;
  text-wrap: pretty;
}

/* A stop: a ring on the line; the last one, the switch, is filled. */
.qf-path-list li::before {
  position: absolute;
  top: 4px;
  left: 0;
  width: 13px;
  height: 13px;
  border: 1.5px solid var(--slate);
  border-radius: 50%;
  background: var(--white);
  content: "";
}

.qf-path-list li:not(:last-child)::after {
  position: absolute;
  top: 19px;
  bottom: 0;
  left: 6px;
  width: 1.5px;
  background: var(--slate);
  content: "";
}

.doc .qf-path-list li:last-child {
  padding-bottom: 0;
}

.qf-path-list li:last-child::before {
  background: var(--slate);
}

/* Column-wide: the stops run left to right, each note under its stop. */
@media (min-width: 640px) and (max-width: 1599px) {
  .doc .qf-path-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
  }

  .doc .qf-path-list li {
    padding: 26px 0 0;
  }

  .qf-path-list li:not(:last-child)::after {
    top: 10px;
    right: -20px;
    left: 17px;
    width: auto;
    height: 1.5px;
  }
}

/* The switch's own row: its name, then the switch at the row's end. */
.qf-path-list li:last-child b {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* A switch drawn in line, set to Off: an outlined pill with its knob at the left. */
.qf-toggle {
  position: relative;
  flex: none;
  display: inline-block;
  width: 30px;
  height: 18px;
  border: 1.5px solid var(--body);
  border-radius: 9px;
}

.qf-toggle::after {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 11px;
  height: 11px;
  border: 1.5px solid var(--body);
  border-radius: 50%;
  content: "";
}

.qf-path-foot {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--divider);
  color: var(--secondary);
  font-size: 13px;
  line-height: 1.45;
}

.qf-path-foot b {
  color: var(--ink);
  font-weight: var(--weight-700);
}

/* --- what you'd expect / what happened: grey and struck, then slate */

.qf-split {
  display: grid;
  margin: clamp(36px, 5vw, 56px) 0;
  overflow: hidden;
  border-radius: var(--radius-tile);
  box-shadow: var(--shadow-tile);
}

@media (min-width: 640px) {
  .qf-split {
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  }
}

.qf-split-a,
.qf-split-b {
  padding: clamp(24px, 4vw, 40px);
}

.qf-split-a {
  background: var(--grey-100);
}

.qf-split-b {
  background: var(--slate);
  color: var(--white);
}

.doc .qf-split p {
  margin: 0;
}

.qf-split-k {
  color: var(--secondary);
  font-size: 11px;
  font-weight: var(--weight-700);
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}

.qf-split-b .qf-split-k {
  color: rgba(255, 255, 255, 0.66);
}

.doc .qf-split .qf-split-q {
  margin-top: 12px;
  font-size: clamp(23px, 2.6vw, 30px);
  font-weight: var(--weight-900);
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-wrap: balance;
}

.qf-split-a .qf-split-q {
  color: var(--secondary);
}

.qf-split-a s {
  text-decoration-color: var(--body);
  text-decoration-thickness: 2px;
}

.doc .qf-split .qf-split-note {
  margin-top: 14px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 15px;
  line-height: 1.5;
}

/* --- pull quote, under a ruler ticked at both ends */

.qf-quote {
  position: relative;
  margin: clamp(44px, 6vw, 72px) 0;
  padding-top: 24px;
  border-top: 1px solid var(--grey-400);
}

.qf-quote::before,
.qf-quote::after {
  position: absolute;
  top: -5px;
  width: 1px;
  height: 9px;
  background: var(--secondary);
  content: "";
}

.qf-quote::before {
  left: 0;
}

.qf-quote::after {
  right: 0;
}

.qf-quote-k {
  color: var(--slate);
  font-size: 11px;
  font-weight: var(--weight-800);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.doc .qf-quote .qf-quote-text {
  max-width: 17em;
  margin: 12px 0 0;
  color: var(--ink);
  font-size: clamp(28px, 3.6vw, 38px);
  font-weight: var(--weight-900);
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-wrap: balance;
}

/* The quieter second line still reads at 6.9:1: grey-400 is for marks only. */
.qf-quote-text span {
  color: var(--secondary);
}

/* --- causes: small cards, each with what we saw */

.doc .qf-causes {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 640px) {
  .doc .qf-causes {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.doc .qf-causes > li {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 20px 22px;
  border-radius: var(--radius-tile);
  background: var(--card-fill);
  box-shadow: var(--inner-highlight), var(--shadow-hairline);
}

.doc .qf-causes h3 {
  font-size: 18px;
}

.doc .qf-causes p {
  margin-top: 6px;
  color: var(--secondary);
  font-size: 15px;
  line-height: 1.5;
}

/* What we saw: a slate chip when tested, an outline when not. */
.doc .qf-causes .qf-seen {
  align-self: flex-start;
  margin-top: auto;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--slate);
  color: var(--white);
  font-size: 11px;
  font-weight: var(--weight-700);
  letter-spacing: 0.06em;
  line-height: 1.5;
  text-transform: uppercase;
}

/* The space above a chip sits on the text, so every chip stays pinned to its card's foot. */
.doc .qf-causes h3 + p {
  margin-bottom: 14px;
}

.doc .qf-causes .qf-seen--none {
  background: none;
  box-shadow: inset 0 0 0 1px var(--grey-400);
  color: var(--secondary);
}

/* --- how we tested, and sources */

.qf-tested {
  margin-top: 56px;
  padding: 24px 26px;
  border-radius: var(--radius-card);
  background: var(--card-fill);
  box-shadow: var(--inner-highlight), var(--shadow-hairline);
}

.doc .qf-tested h2 {
  margin: 0 0 14px;
  font-size: 22px;
}

.qf-tested dl {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2px 20px;
  margin: 0;
}

@media (min-width: 640px) {
  .qf-tested dl {
    grid-template-columns: 112px minmax(0, 1fr);
  }
}

.qf-tested dt {
  padding-top: 10px;
  color: var(--secondary);
  font-size: 11px;
  font-weight: var(--weight-700);
  letter-spacing: 0.08em;
  line-height: 1.9;
  text-transform: uppercase;
}

.qf-tested dd {
  margin: 0;
  padding: 8px 0 10px;
  border-bottom: 1px solid var(--divider);
  font-size: 15px;
  line-height: 1.5;
}

.qf-tested dd:last-of-type {
  border-bottom: 0;
}

@media (max-width: 639px) {
  .qf-tested dd {
    padding-top: 0;
  }
}

.doc .qf-sources {
  margin-top: 4px;
  padding-left: 22px;
  color: var(--secondary);
  font-size: 14px;
  line-height: 1.5;
}

.doc .qf-sources li + li {
  margin-top: 6px;
}

/* --- Quwire's mix card, as the app looks (on the article's slate plate) */

.qf-mix {
  display: grid;
  grid-template-columns: 120px minmax(24px, 1fr) minmax(240px, 300px) 64px minmax(220px, 264px);
  align-items: center;
  color: var(--white);
}

.qf-mix-src {
  display: grid;
  justify-items: center;
  gap: 2px;
  text-align: center;
}

.qf-mix-mac {
  width: 88px;
}

.qf-mix-lbl,
.qf-mix-name,
.qf-tile-txt {
  display: grid;
  line-height: 1.3;
}

.qf-mix-lbl b {
  font-size: 15px;
  font-weight: var(--weight-700);
}

.qf-mix-lbl small {
  color: rgba(255, 255, 255, 0.66);
  font-size: 13px;
}

.qf-mix-link .qf-art {
  width: 100%;
  height: 8px;
}

.qf-mix-link-v,
.qf-mix-branch .qf-mix-link-v {
  display: none;
}

.qf-mix-card {
  padding: 18px 18px 16px;
  border-radius: var(--radius-tile);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-tile);
  color: var(--body);
}

.doc .qf-mix-card p {
  margin: 0;
}

.qf-mix-name b {
  color: var(--ink);
  font-size: 22px;
  font-weight: var(--weight-900);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.qf-mix-name small {
  margin-top: 2px;
  color: var(--secondary);
  font-size: 13px;
}

.qf-mix-master {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--grey-100);
}

/* A note on the plate, hung under the card (which shows only the app's labels) so the card stays centred on
   the dotted lines. */
.qf-mix-mid {
  position: relative;
}

.doc .qf-mix .qf-mix-note {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  line-height: 1.4;
  text-align: center;
}

.qf-ico {
  flex: none;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.qf-mix-master .qf-ico {
  color: var(--slate);
}

/* A volume slider like the app's: a slate fill and a white pill knob. */
.qf-slider {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 4px;
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.1);
}

.qf-slider b,
.qf-slider i {
  position: absolute;
  top: 0;
}

.qf-slider b {
  bottom: 0;
  left: 0;
  border-radius: 2px;
  background: var(--slate);
}

.qf-slider i {
  top: 50%;
  width: 20px;
  height: 14px;
  margin: -7px 0 0 -10px;
  border-radius: 7px;
  background: var(--white);
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.14), 0 1px 3px rgba(0, 0, 0, 0.24);
}

.qf-v40 b { width: 40%; }
.qf-v40 i { left: 40%; }
.qf-v58 b { width: 58%; }
.qf-v58 i { left: 58%; }
.qf-v64 b { width: 64%; }
.qf-v64 i { left: 64%; }
.qf-v72 b { width: 72%; }
.qf-v72 i { left: 72%; }

.qf-pct {
  flex: none;
  min-width: 36px;
  color: var(--ink);
  font-size: 13px;
  font-weight: var(--weight-800);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.qf-mix-branch {
  display: flex;
  align-self: stretch;
}

.qf-mix-branch .qf-mix-fork {
  width: 100%;
  height: 100%;
}

.doc .qf-mix-outs {
  display: grid;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  margin: 0;
  padding: 0;
  list-style: none;
}

.doc .qf-mix-outs > li {
  margin: 0;
  padding: 6px 0;
}

/* An output's tile. Rows share one height, so the fork meets each tile's middle. */
.qf-tile {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px 12px;
  padding: 12px 14px 13px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-tile);
  color: var(--body);
}

.qf-well {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--slate);
  color: var(--white);
}

.qf-tile-txt b {
  color: var(--ink);
  font-size: 15px;
  font-weight: var(--weight-700);
}

.qf-tile-txt small {
  color: var(--secondary);
  font-size: 12.5px;
}

.qf-tile-vol {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  gap: 10px;
}

/* Under 880 px the mix stacks, joined by vertical dotted links. */
@media (max-width: 879px) {
  .qf-mix {
    grid-template-columns: minmax(0, 1fr);
    max-width: 340px;
    margin: 0 auto;
  }

  .qf-mix-link .qf-mix-link-h,
  .qf-mix-branch .qf-mix-fork {
    display: none;
  }

  .qf-mix-link .qf-mix-link-v,
  .qf-mix-branch .qf-mix-link-v {
    display: block;
    width: 8px;
    height: 36px;
    margin: 8px auto;
  }

  .qf-mix-branch {
    display: block;
  }

  .doc .qf-mix-outs {
    grid-template-rows: none;
  }

  .doc .qf-mix-outs > li {
    padding: 5px 0;
  }

  .doc .qf-mix .qf-mix-note {
    position: static;
  }
}

/* --- the closing card: the landing's slate and black circles, only here */

.qf-cta {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.qf-cta::before,
.qf-cta::after {
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.qf-cta::before {
  right: -150px;
  bottom: -250px;
  width: 440px;
  aspect-ratio: 1;
  background: var(--slate);
}

.qf-cta::after {
  right: -64px;
  bottom: -110px;
  width: 210px;
  aspect-ratio: 1;
  background: var(--ink);
}

.qf-cta h2,
.qf-cta .section-lede {
  max-width: 400px;
}

/* Narrow cards: the circles sit under the button's row, clear of the copy. */
@media (max-width: 759px) {
  .qf-cta::before {
    right: -170px;
    bottom: -290px;
    width: 360px;
  }

  .qf-cta::after {
    right: -60px;
    bottom: -120px;
    width: 170px;
  }

  .qf-cta {
    padding-bottom: 120px;
  }
}

/* --- /guides/: one section per topic */

.doc .qf-group-lede {
  max-width: 640px;
  margin-bottom: 20px;
  color: var(--secondary);
}

/* --- motion
   A figure moves only to show a change or time passing, for 25 s at most, then rests on the styles above: its final,
   fully labelled state, which Reduce Motion shows. Hover pauses it. Only opacity, transform and dash offset move. */

@media (prefers-reduced-motion: no-preference) {
  .qf-motion-only {
    display: inline;
  }

  .qf-fig:hover .qf-art,
  .qf-fig:hover .qf-art * {
    animation-play-state: paused;
  }

  @keyframes qf-flow {
    to {
      stroke-dashoffset: -20px;
    }
  }

  /* Sound in transit: about 14 px/s, 18 cycles (25 s). */
  .qf-art .ln-flow {
    animation: qf-flow 1.4s linear 18;
  }

  /* A state swap, for any figure that shows one change. .qf-sa parts show the resting answer, .qf-sb parts the state
     before it. Each 8 s play turns to the earlier state, holds it, turns back and holds the answer for over half the
     play; 3 plays end at rest. .qf-t1 to .qf-t3 stagger the parts (cause, signal, effect) both ways; .qf-lift drops a
     part 14 px as it goes. */
  .qf-sa,
  .qf-sb {
    animation: qf-sa 8s var(--qf-ease) var(--qf-d, 0s) 3;
  }

  .qf-sb { animation-name: qf-sb; }
  .qf-t1 { --qf-d: 0.5s; }
  .qf-t2 { --qf-d: 0.85s; }
  .qf-t3 { --qf-d: 1.2s; }
  .qf-lift { --qf-y: 14px; }

  @keyframes qf-sa {
    0%, 48%, 100% { opacity: 1; transform: none; }
    7%, 41% { opacity: 0; transform: translateY(var(--qf-y, 0)); }
  }

  @keyframes qf-sb {
    0%, 48%, 100% { opacity: 0; }
    7%, 41% { opacity: 1; }
  }

  /* Words that trade places (.qf-seq) turn in sequence: the old fade out in the first half of each turn, the new fade
     in in the second, so two labels never show on top of each other. Shapes keep the cross-fade above. */
  .qf-sa.qf-seq { animation-name: qf-sa-seq; }
  .qf-sb.qf-seq { animation-name: qf-sb-seq; }

  @keyframes qf-sa-seq {
    0%, 48%, 100% { opacity: 1; transform: none; }
    3.5%, 44.5% { opacity: 0; transform: translateY(var(--qf-y, 0)); }
  }

  @keyframes qf-sb-seq {
    0%, 3.5%, 44.5%, 100% { opacity: 0; }
    7%, 41% { opacity: 1; }
  }

  /* A timeline: a white cover lifts off the plot behind a playhead that sweeps it at twice real speed (5 s). The
     cover lifts once; the playhead sweeps 3 times in 9 s plays, so the complete plot holds 42 % of each play, and it
     ends after 24 s. --qf-x is the plot's width on each board. */
  .qf-tl-cover {
    transform-box: fill-box;
    transform-origin: right center;
    animation: qf-tl-cover 5s linear;
  }

  .qf-tl-play {
    animation: qf-tl-play 9s linear 2.65;
  }

  .qf-tl-play--l { --qf-x: 530px; }
  .qf-tl-play--s { --qf-x: 300px; }

  @keyframes qf-tl-cover {
    from { opacity: 1; transform: none; }
    to { opacity: 1; transform: scaleX(0); }
  }

  @keyframes qf-tl-play {
    0% { opacity: 1; transform: none; }
    55.6% { opacity: 1; transform: translateX(var(--qf-x)); }
    58%, 100% { opacity: 0; transform: translateX(var(--qf-x)); }
  }

  /* Where the browser can (Safari 26, Chrome), the reader's scroll drives the timeline's one sweep and the signal
     path's dots instead, so they play as the figure comes into view, never before; hover doesn't stop them. */
  @supports (animation-timeline: view()) {
    .qf-fig {
      view-timeline: --qf-fig block;
    }

    .qf-fig .qf-art .qf-tl-cover,
    .qf-fig .qf-art .qf-tl-play,
    .qf-fig .qf-plate--slate .ln-flow {
      animation-duration: auto;
      animation-iteration-count: 1;
      animation-fill-mode: both;
      animation-play-state: running;
      animation-timeline: --qf-fig;
      animation-range: entry 40% contain 40%;
    }

    .qf-fig .qf-art .qf-tl-play {
      animation-name: qf-tl-head;
    }

    .qf-fig .qf-plate--slate .ln-flow {
      animation-iteration-count: 12;
      animation-range: cover;
    }

    @keyframes qf-tl-head {
      from { opacity: 1; transform: none; }
      94% { opacity: 1; }
      to { opacity: 0; transform: translateX(var(--qf-x)); }
    }
  }
}

/* The resting state, when nothing moves: what Reduce Motion shows, and every figure after its last play. */
.qf-sb,
.qf-tl-cover,
.qf-tl-play {
  opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
  .qf-art,
  .qf-art * {
    animation: none !important;
  }
}
