@font-face { font-family: "GT Pressura"; src: url("fonts/gt-pressura.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Die Grotesk A"; src: url("fonts/die-grotesk-a.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Die Grotesk A"; src: url("fonts/die-grotesk-a-italic.woff2") format("woff2"); font-style: italic; font-display: swap; }
@font-face { font-family: "GT Pressura Mono"; src: url("fonts/gt-pressura-mono.woff2") format("woff2"); font-display: swap; }

/*
  One grid: 24 columns wide with 24px gutters and margins, as the Figma frame
  (2047:6019) draws it, from 1280px. Below that the gutter and margin stay
  16px: 12 columns on a tablet, 8 on a phone, and 24 on the narrow desktop,
  where the side panel is too tight for four plates. Text
  starts on a column line, except in the list, where each column hangs its
  rule on the line and sets its text one cell (12px) in. The list is 12
  columns: number 1–2, persona 3–6, gifts 7–9, enough 10–12.
  The panel is the other 12, in quarters: 1, 4, 7, 10.
  Vertical space follows size. Each block names the size of its largest type
  (--size), and its spaces are built from it, on the 8px step:
    tight  size ÷ 8, at least 8    a thing and its own label, value, or key
    near   16 + size ÷ 4           a heading and what it introduces
    apart  near × 2                the next group
    band   apart × 2 at display    the next section
  So a thing always sits closer to what it belongs to than to anything else,
  and the bigger the type, the more room around it. At reading size the three
  are 8, 16, and 32 (--inset, --stack, --group). Reading text is a 20px line.
  Pairs hang from the same top. Orange marks where you are.
*/

:root {
  --bg: var(--role-surface-dark-page);
  --fg: var(--role-text-on-dark-primary);
  --fg2: var(--role-text-on-dark-secondary);
  --fg3: var(--role-text-on-dark-tertiary);
  --hair: var(--role-border-on-dark-default);
  --rule: var(--fg);
  --on-fg: var(--bg);
  --accent: var(--role-accent-primary);
  --plate: var(--role-surface-light-sunken);
  --well: var(--role-surface-dark-sunken);
  --mar: var(--spacing-4);
  --gut: var(--spacing-4);
  --cols: 8;
  --inset: var(--spacing-2);
  --stack: var(--spacing-4);
  --group: var(--spacing-8);
  --pad: var(--inset);
  --leading: var(--spacing-5);
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --label: var(--font-size-11);
  --read: var(--font-size-13);
  --figure: var(--font-size-32);
  --figure-lead: calc(var(--figure) + var(--spacing-1));
  --display: clamp(40px, 10.4vw, 112px);
  --band: calc(round(calc(var(--spacing-4) + var(--display) / 4), var(--spacing-2)) * 4);
  --size: var(--read);
  color-scheme: dark;
  background: var(--bg);
}

.hero { --size: var(--display); }
.facts, .pn { --size: var(--figure); }
:root, .hero, .facts, .pn {
  --tight: max(var(--spacing-2), round(calc(var(--size) / 8), var(--spacing-2)));
  --near: round(calc(var(--spacing-4) + var(--size) / 4), var(--spacing-2));
  --apart: calc(var(--near) * 2);
}

/* Paper uses on-light text roles so secondary copy and chart marks clear WCAG. */
html[data-theme="paper"] {
  color-scheme: light;
  --bg: var(--tone-neutral-100);
  --fg: var(--tone-neutral-10);
  --fg2: var(--role-text-on-light-secondary);
  --fg3: var(--tone-neutral-50);
  --hair: var(--role-border-on-light-default);
  --on-fg: var(--tone-neutral-95);
  --well: var(--role-surface-light-sunken);
}

html.theme-switching,
html.theme-switching *,
html.theme-switching *::before,
html.theme-switching *::after {
  transition: none !important;
}

@media (min-width: 600px) { :root { --cols: 12; --display: clamp(48px, 7.4vw, 112px); } }
@media (max-width: 959px) { :root { --mar: var(--spacing-4); --gut: var(--spacing-4); } }
@media (min-width: 960px) { :root { --cols: 24; --display: clamp(64px, 6.8vw, 120px); } }
@media (min-width: 1280px) { :root { --mar: var(--spacing-6); --gut: var(--spacing-6); } }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
html { -webkit-tap-highlight-color: transparent; }
body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: var(--read);
  line-height: var(--leading);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, p, ol, ul, dl, dd, blockquote, figure { margin: 0; padding: 0; }
ol, ul { list-style: none; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; background: none; border: 0; padding: 0; margin: 0; border-radius: 0; }
button { cursor: pointer; text-align: inherit; }
button, a, [role="button"] {
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
}
button:active, a:active, [role="button"]:active { opacity: 0.72; }
img { display: block; }
::selection { background: color-mix(in srgb, var(--fg) 16%, transparent); color: var(--fg); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }
[tabindex="-1"]:focus-visible { outline: none; }
.boot { grid-column: 1 / -1; padding: var(--band) var(--mar); }

.grid {
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  column-gap: var(--gut);
  padding-inline: var(--mar);
}
.dim { color: var(--fg2); }
.strong { color: var(--fg); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: var(--mar); top: -40px; z-index: 60; background: var(--fg); color: var(--bg); padding: var(--spacing-1) var(--spacing-2); }
.skip:focus { top: var(--spacing-2); }
.noscript { padding: var(--spacing-10) var(--mar); }
.nm { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arr { margin-left: 0.25em; }

.credit, .sheet-bar, .pl-note {
  font-family: var(--font-mono);
  font-size: var(--label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: var(--leading);
}

/* Caps hang from the same edge. The reel keeps its own em boxes. */

h1, h2, h3, .hero-k, .hero-dek, .pn-one > p, .lg-k, .facts dt, .gv-price, blockquote, .fs-k > *, .fs-col > p, .keys, .cl-axis, .cap, .fail {
  text-box-trim: trim-both;
  text-box-edge: cap alphabetic;
}
.fig, .fig * { text-box-trim: none; }
blockquote { hanging-punctuation: first; }

/* The frame */

.top { padding-top: max(var(--stack), env(safe-area-inset-top)); align-items: start; }
.top > * { grid-row: 1; }
.t-a { grid-column: 1 / 5; }
.t-b { grid-column: 5 / 9; display: flex; flex-direction: column; align-items: flex-start; }
.t-b a[aria-current],
.t-b a[aria-current]:hover,
.t-b a[aria-current]:focus-visible { color: var(--accent); }
.t-c, .t-d { display: none; }

/* The mode. Filled is light, stroked is dark. */
.t-mode { grid-column: -2 / -1; justify-self: end; position: relative; z-index: 1; padding: var(--spacing-2) var(--spacing-3); margin: calc(var(--spacing-2) * -1) calc(var(--spacing-3) * -1); line-height: var(--leading); }
.t-mode::before { content: ""; display: inline-block; box-sizing: border-box; width: 1cap; height: 1cap; border: 1px solid currentColor; }
html[data-theme="paper"] .t-mode::before { background: currentColor; }
@media (min-width: 600px) {
  .t-a { grid-column: 1 / 4; }
  .t-b { grid-column: 4 / 7; }
  .t-c { display: block; grid-column: 7 / 10; }
  .t-d { display: block; grid-column: 10 / 13; }
}
@media (min-width: 960px) {
  .t-a { grid-column: 1 / 7; }
  .t-b { grid-column: 7 / 13; }
  .t-c { grid-column: 13 / 19; }
  .t-d { grid-column: 19 / 25; }
}

.foot {
  margin-top: var(--band);
  padding-top: var(--inset);
  padding-bottom: var(--band);
  row-gap: var(--group);
  color: var(--fg2);
  position: relative;
  align-items: start;
}
.foot::before { content: ""; position: absolute; top: 0; left: calc(var(--mar) - var(--gut) / 2); right: calc(var(--mar) - var(--gut) / 2); height: 1px; background: var(--hair); }
.foot a { color: var(--fg); display: block; width: fit-content; }
.f-a { grid-column: 1 / 5; color: var(--fg); }
.f-b { grid-column: 5 / 9; }
.f-c { grid-column: 1 / 5; }
.f-d { grid-column: 5 / 9; }
@media (min-width: 600px) {
  .f-a { grid-column: 1 / 4; }
  .f-b { grid-column: 4 / 7; }
  .f-c { grid-column: 7 / 10; }
  .f-d { grid-column: 10 / 13; }
}
@media (min-width: 960px) {
  .f-a { grid-column: 1 / 7; }
  .f-b { grid-column: 7 / 13; }
  .f-c { grid-column: 13 / 19; }
  .f-d { grid-column: 19 / 25; }
}

/* The hero */

.hero { padding-top: var(--band); row-gap: 0; align-items: start; }
.hero-h {
  grid-column: 1 / -1;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--display);
  line-height: 0.92;
  letter-spacing: var(--letter-spacing-minus-3);
  text-wrap: balance;
  margin-bottom: var(--near);
}
.hero-k { grid-column: 1 / -1; margin-bottom: var(--spacing-6); color: var(--fg2); }
.hero-dek { grid-column: 1 / -1; max-width: 36ch; font-size: var(--font-size-14); line-height: var(--line-height-ratio-140); margin-bottom: var(--apart); }
.facts { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; row-gap: var(--apart); }
.facts > div { grid-column: span 4; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: var(--tight); padding-top: var(--tight); border-top: 1px solid var(--rule); }
.facts dt { color: var(--fg2); text-wrap: balance; }
.facts dd { margin-top: -0.22em; font-family: var(--font-display); font-size: var(--figure); line-height: 1; letter-spacing: -0.02em; }
@media (min-width: 600px) {
  .hero-k, .hero-h { grid-column: 1 / 12; }
  .hero-dek { grid-column: 7 / 13; }
  .facts > div { grid-column: span 4; }
}
/* As the frame (2047:16378) draws it: 144px above the headline's cap, and
   144px under its baseline before the 96px that leads the figures. */
@media (min-width: 960px) {
  .hero { padding-top: calc(var(--spacing-12) * 3); }
  .hero-h { grid-column: 1 / 19; grid-row: 1; margin-bottom: calc(var(--spacing-12) * 3 + var(--spacing-24)); }
  .hero-dek { grid-column: 19 / 25; grid-row: 1; align-self: start; max-width: none; }
  .facts { grid-row: 2; }
  .facts > div { grid-column: span 4; }
  /* Method hero matches the index corner deck but has no figure row. */
  .hero:not(:has(.facts)) .hero-h { margin-bottom: var(--near); }
  .hero:not(:has(.facts)) .hero-dek { margin-bottom: calc(var(--spacing-12) * 3); }
}

/* The reel. Each digit rolls once, on the first visit. */

.fig { display: inline-flex; align-items: flex-start; height: 1em; white-space: nowrap; line-height: 1; font-variant-numeric: tabular-nums lining-nums; }
.slot { height: 1em; line-height: 1; }
.reel { display: block; overflow: hidden; }
.strip { display: flex; flex-direction: column; transform: translate3d(0, calc(var(--n, 0) * -1em), 0); }
.strip > span, .slot .glyph { display: block; height: 1em; line-height: 1; }
.facts.is-rolling .strip { transition: transform 620ms cubic-bezier(0.16, 1, 0.3, 1); transition-delay: calc(var(--col, 0) * 40ms + var(--i, 0) * 26ms); }

/* The index, to the Figma frame. Type is 14px on a 1.4 line, which Figma
   trims to the caps, so every space counts from a cap top or a baseline:
   text sits a cell (12px) past the 1px rule on its column line and 12px
   from the rules above and below it, so a row is 35px with its rule. A
   group's name is 48px below what comes before and 12px above its rows, and
   the header's caps are two 96px section pads below the figures. --trim is
   what a 1.4 line keeps above the caps, with Figma's whole-pixel cap. */

.ix, .fs {
  --cell: var(--spacing-2);
  --lh: calc(var(--font-size-14) * var(--line-height-ratio-140));
  --trim: calc((var(--lh) - round(down, 1cap, 1px)) / 2);
  --cell-y: calc(var(--spacing-3) - var(--trim));
  align-items: start;
}
.ix { margin-top: var(--band); }
@media (min-width: 600px) { .ix, .fs { --cell: var(--spacing-3); } }
@media (min-width: 960px) { .ix { margin-top: calc(var(--spacing-24) * 2 - var(--spacing-3)); } }
.ix-list { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-content: start; font-size: var(--font-size-14); line-height: var(--lh); }
.ix-top, .ix-body, .grp, .p, .p-in { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; }
.ix-top { position: sticky; top: 0; z-index: 3; background: var(--bg); padding-top: max(var(--cell-y), env(safe-area-inset-top)); }
.ix-top::before { content: ""; position: absolute; inset: 0 calc(var(--gut) / -2); background: var(--bg); z-index: -1; }

.row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: subgrid;
  position: relative;
  width: 100%;
  font-variant-numeric: tabular-nums;
}
.row::before {
  content: "";
  position: absolute;
  inset: 0;
  border-left: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  pointer-events: none;
}
.row > * { position: relative; min-width: 0; padding: var(--cell-y) 0 calc(var(--cell-y) + 1px) calc(var(--cell) + 1px); }
.row > :not(.c-no)::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 1px;
  background: var(--rule);
}
.row .nm { overflow: visible; white-space: normal; }

.c-no { grid-column: 1 / 3; white-space: nowrap; }
.c-name { grid-column: 3 / 7; display: flex; align-items: flex-start; min-width: 0; }
.c-gifts { display: none; }
.c-usd { grid-column: 7 / 9; display: flex; justify-content: space-between; align-items: flex-start; gap: var(--spacing-2); white-space: nowrap; }
@media (min-width: 600px) {
  .c-gifts { grid-column: 7 / 10; display: block; }
  .c-usd { grid-column: 10 / 13; }
}

.ix-head > * { padding-top: 0; white-space: normal; }
.ix-head::before, .ix-head > :not(.c-no)::before { top: var(--trim); }
.ix-head button { text-align: left; }
.ix-head i { font-style: normal; }

.grp-head { margin-top: calc(var(--spacing-12) - var(--trim)); font-size: inherit; font-weight: 400; color: var(--fg); }
.grp-head::before { border-left: 0; }
.grp-head > * { padding-top: 0; padding-left: var(--cell); }
.grp-head > *::before { display: none; }
.grp-head .c-name { grid-column: 1 / -1; display: block; }
.grp-head .dim { margin-left: var(--spacing-2); }
.grp-head .c-gifts { color: var(--fg2); }
@media (min-width: 600px) { .grp-head .c-name { grid-column: 1 / 7; } }
.grp { scroll-margin-top: var(--spacing-12); }
.p { scroll-margin-top: calc(var(--cell-y) * 2 + var(--lh)); }

.p-row { cursor: pointer; text-align: left; }
.p-row .nm, .g-row .nm, .g-about .c-name { text-decoration-line: underline; text-decoration-color: transparent; text-underline-offset: 0.18em; text-decoration-thickness: 1px; transition: text-decoration-color 120ms var(--ease); }
.g-row.is-hot .nm { text-decoration-color: currentColor; }
.p.is-shown > .p-row .c-no { color: var(--accent); }
html[data-theme="paper"] .p.is-shown:not(.is-open) > .p-row .c-no { color: var(--fg); }
.p.is-open > .p-row { background: var(--fg); color: var(--on-fg); }
.p.is-open > .p-row > * { padding-top: calc(var(--cell-y) + 1px); }
.p.is-open > .p-row .c-no { color: inherit; }
.sign { display: grid; flex: none; }
.sign::before, .sign::after { grid-area: 1 / 1; }
.sign::before { content: "+"; }
.sign::after { content: "-"; visibility: hidden; }
.c-usd .sign::before { position: relative; top: 1px; }
.p.is-open .sign::before { visibility: hidden; }
.p.is-open .sign::after { visibility: visible; }
.n-ph { font-family: var(--font-mono); font-size: var(--label); line-height: 1; margin-left: var(--spacing-2); color: var(--fg2); }
@media (min-width: 600px) { .n-ph { display: none; } }

/* A persona opens onto its gifts, on a sunken fill. The rows grow from zero
   height and clip above and below only. */

.p-gifts { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; grid-template-rows: 0fr; transition: grid-template-rows 320ms var(--ease); }
.p.is-open > .p-gifts { grid-template-rows: 1fr; }
.p.is-snap > .p-gifts { transition: none; }
.p-in { min-height: 0; clip-path: inset(0 calc(var(--gut) * -1)); align-content: start; visibility: hidden; transition: visibility 0s linear 320ms; }
.p.is-open .p-in { visibility: visible; transition-delay: 0s; }
.p.is-snap .p-in { transition: none; }
.p-in > .row { background: var(--well); }
.g-row { color: var(--fg); }
.g-row.is-shown .c-no, .g-row.is-pinned .c-no { color: var(--accent); }
.g-row.is-pinned .nm { text-decoration-color: currentColor; }
.g-one .c-name { grid-column: 3 / -1; display: block; max-width: 56ch; }
.g-about { cursor: pointer; text-align: left; }
.g-about .c-name { grid-column: 3 / 7; color: var(--fg); }
@media (min-width: 600px) { .g-about .c-name { grid-column: 3 / 10; } }
@media (min-width: 960px) { .g-one, .g-about { display: none; } }

.ix-body { padding-bottom: var(--group); }

/* The panel. One place on the right that shows whatever is in hand. */

.panel { display: none; }
/* As the frame (2049:16467) draws it: 14px on 1.4, every line cap-trimmed,
   48px between blocks, 24px between rows, 12px from a rule to the cap. */
.pn {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / -1;
  align-content: start;
  align-items: start;
  padding-bottom: var(--band);
  font-size: var(--font-size-14);
  line-height: var(--lh);
}
.pn > * { grid-column: 1 / -1; }
.pn > * + * { margin-top: var(--spacing-12); }
.sheet-bar { display: none; }

@media (min-width: 960px) {
  .ix-list { grid-column: 1 / 13; grid-row: 1; }
  .panel {
    grid-column: 13 / 25;
    grid-row: 1;
    display: grid;
    grid-template-columns: subgrid;
    position: sticky;
    top: 0;
    height: 100vh;
    height: 100dvh;
    overflow-x: clip;
    overflow-y: auto;
    /* The panel scrolls first. Past either end, the same wheel moves the page. */
    overscroll-behavior: auto;
    scrollbar-width: none;
  }
  .panel::-webkit-scrollbar { display: none; }
}

.pn-up { text-transform: inherit; letter-spacing: inherit; color: var(--fg); }

.gv-name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--figure);
  line-height: var(--figure-lead);
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.pn-head { display: grid; grid-template-columns: subgrid; row-gap: var(--spacing-6); align-items: start; }
.pn-title {
  grid-column: 1 / -1;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--figure);
  line-height: 1;
  letter-spacing: -0.03em;
  overflow-wrap: normal;
}
.pn-one { grid-column: 1 / -1; text-wrap: pretty; }
.pn-one > p + p { margin-top: calc(var(--lh) * 2 - 1cap); }
@media (min-width: 600px) {
  .pn-title { grid-column: 1 / 9; }
  .pn-one { grid-column: 9 / 13; }
}
@media (min-width: 960px) {
  .pn-title { font-size: var(--font-size-64); }
}
@media (min-width: 960px) and (max-width: 1279px) {
  .pn-title, .pn-one { grid-column: 1 / -1; }
}
.pn-more { margin-top: var(--apart); }

/* Plates. Cutouts sit on a light plate, because multiply needs a light field. */

.pl { position: relative; display: block; overflow: hidden; aspect-ratio: 1; background: var(--plate); border-radius: var(--radius-xs); }
.pl img { position: absolute; inset: 0; margin: auto; width: 76%; height: 76%; object-fit: contain; mix-blend-mode: multiply; }
.pl.is-object img { mix-blend-mode: normal; }
.pl.is-photo img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: normal; }
.pl.is-none { display: flex; align-items: flex-end; padding: var(--inset); background: repeating-linear-gradient(135deg, transparent 0 8px, color-mix(in oklab, var(--fg) 7%, transparent) 8px 9px), color-mix(in oklab, var(--fg) 4%, var(--bg)); }
.pl-note { color: var(--fg2); }

.pn-plates { display: grid; grid-template-columns: subgrid; row-gap: var(--spacing-6); }
.pn-cell { grid-column: span 4; display: flex; flex-direction: column; align-items: stretch; gap: var(--spacing-2_5); text-align: left; min-width: 0; }
.pn-cell .pl img { transition: transform 140ms var(--ease); }
.pn-cap { display: flex; flex-direction: column; gap: var(--spacing-2_5); min-width: 0; }
.pn-cap > * { text-box-trim: trim-both; text-box-edge: cap alphabetic; }
.pn-cap .nm { white-space: normal; overflow: visible; overflow-wrap: anywhere; }

/* Ledgers: a rule, then the label on three columns, the matter on six, and
   an aside on the last three. Paragraphs sit one blank line apart. */

.lg { display: grid; grid-template-columns: subgrid; row-gap: var(--spacing-3); align-items: start; padding-top: var(--spacing-3); border-top: 1px solid var(--rule); }
.lg-k { grid-column: 1 / -1; }
.lg-v { grid-column: 1 / -1; min-width: 0; text-wrap: pretty; }
.lg-a { grid-column: 1 / -1; color: var(--fg2); font-variant-numeric: tabular-nums; }
.lg-a, .lg-v > * { text-box-trim: trim-both; text-box-edge: cap alphabetic; }
.lg-v > * + * { margin-top: calc(var(--lh) * 2 - 1cap); }
@media (min-width: 600px) {
  .lg { row-gap: 0; }
  .lg-k { grid-column: 1 / 4; }
  .lg-v { grid-column: 4 / 10; }
  .lg-a { grid-column: 10 / 13; text-align: right; }
  /* A line of counts has no aside, so it runs to the edge and breaks evenly. */
  .lg.is-run .lg-v { grid-column: 4 / -1; text-wrap: balance; }
}
.lg-v a { color: var(--fg2); text-decoration: underline; text-decoration-thickness: from-font; text-underline-position: from-font; }
/* A button is an inline-block, and its baseline is the last line, so a wrapped
   name sits one line high and crosses the rule. This is a link, and it flows
   as text with the label. */
.lg-v .lg-link { color: inherit; text-decoration: none; text-box-trim: trim-both; text-box-edge: cap alphabetic; }
blockquote { color: var(--fg); text-wrap: pretty; }
.lg + .lg { margin-top: var(--spacing-6); }

/* The price line: every gift for a persona on one log scale that starts at
   $5. A decade is a quarter of the grid, so each label sits on a column
   line. The line is black from the cheapest gift to the dearest. A gift is a
   12px ring on a stem; one that would sit on its neighbour steps up. */

.pline { --dec: calc((100% + var(--gut)) / 4); }
.pline-plot { position: relative; height: var(--spacing-12); }
.pline-plot::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--hair); }
.pline-in { position: absolute; left: calc(var(--a) * var(--dec)); bottom: 0; width: calc((var(--b) - var(--a)) * var(--dec)); height: 1px; background: var(--fg); }
/* Ring markers only — gift names live in aria-label, not on the chart.
   Hit area is 44px wide; the ring stays 12px at the stem. */
.pline-t { --ink: var(--fg); --hit: 44px; position: absolute; left: clamp(calc(var(--hit) / 2), calc(var(--d) * var(--dec)), calc(100% - var(--hit) / 2)); top: var(--spacing-3); bottom: 0; width: var(--hit); margin-left: calc(var(--hit) / -2); padding: 0; border: 0; background: none; overflow: visible; color: transparent; font-size: 0; line-height: 0; cursor: pointer; }
.pline-t.is-up { top: 0; }
.pline-t::before { content: ""; position: absolute; top: 0; left: 50%; width: var(--spacing-3); height: var(--spacing-3); margin-left: calc(var(--spacing-3) / -2); border-radius: 50%; box-shadow: inset 0 0 0 1px var(--ink); transition: background-color 160ms var(--ease); }
.pline-t::after { content: ""; position: absolute; top: var(--spacing-3); bottom: 0; left: calc(50% - 0.5px); width: 1px; background: var(--fg); }
.pline-t:focus-visible::before { background: var(--ink); }
.pline-t.is-on { --ink: var(--accent); z-index: 1; }
.pline-t.is-on::before { background: var(--ink); }
.pline-axis { position: relative; height: 1cap; margin-top: var(--spacing-4); color: var(--fg); font-variant-numeric: tabular-nums; }
.pline-axis span { position: absolute; top: 0; left: calc(var(--d) * var(--dec)); white-space: nowrap; text-box-trim: trim-both; text-box-edge: cap alphabetic; }

/* A gift */

.gv-plate { position: relative; margin-top: var(--apart); }
.gv-plate .pl { aspect-ratio: 16 / 10; }
.gv-plate .pl.is-cutout img, .gv-plate .pl.is-object img { width: 60%; height: 74%; }
.credit { position: absolute; left: var(--spacing-2); bottom: var(--spacing-2); color: var(--role-text-on-light-secondary); }
.gv-plate .pl.is-photo + .credit { color: var(--fg); mix-blend-mode: difference; }
.gv-head { display: grid; grid-template-columns: subgrid; row-gap: var(--tight); margin-top: var(--near); align-items: start; }
/* On a phone the name takes the whole width and the price sits under it: the
   full product names run past five lines in a column shared with the price. */
.gv-head > * { grid-column: 1 / -1; }
.gv-price { min-width: 0; margin-top: calc(var(--near) - var(--tight)); font-family: var(--font-display); font-size: var(--figure); line-height: var(--figure-lead); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.gv-brand { text-wrap: pretty; }
.gv-giver { margin-top: calc(var(--near) - var(--tight)); max-width: 52ch; text-wrap: pretty; }
.buy {
  display: grid;
  grid-template-columns: subgrid;
  align-items: start;
  margin-top: var(--inset);
  padding-block: var(--pad);
  border-block: 1px solid var(--rule);
  transition: background-color 160ms var(--ease), color 160ms var(--ease);
}
.buy > :first-child { grid-column: 1 / 4; }
.buy > :last-child { grid-column: 4 / -1; text-align: right; color: var(--fg2); }
@media (min-width: 600px) {
  .gv-name, .gv-brand, .gv-giver { grid-column: 1 / 10; }
  .gv-price { grid-column: 10 / 13; margin-top: 0; text-align: right; }
  .gv-brand { grid-row: 2; }
}
/* On the narrowest two-pane width a four-figure price needs a fourth column. */
@media (min-width: 960px) and (max-width: 1279px) {
  .gv-name, .gv-brand { grid-column: 1 / 9; }
  .gv-price { grid-column: 9 / 13; }
}

/* Previous and next, on one ruled row. The words are trimmed to the cap, so
   each button reaches past its box to stay easy to hit. */
.pn-step { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--gut); padding-top: var(--spacing-3); border-top: 1px solid var(--rule); overflow-x: clip; }
.pn-step > * { position: relative; white-space: nowrap; text-box-trim: trim-both; text-box-edge: cap alphabetic; }
.pn-step button::after { content: ""; position: absolute; inset: calc(var(--spacing-4) * -1); }
@media (min-width: 600px) {
  .pn-cell { grid-column: span 3; }
}
/* The side panel is about 450px at 960, so four plates leave a name no room.
   Three across until the 24px gutter returns at 1280. */
@media (min-width: 960px) and (max-width: 1279px) {
  .pn-cell { grid-column: span 4; }
}

/* On a phone and a tablet the panel is a sheet. */

@media (max-width: 959px) {
  /* Hold the page still so touch scrolling stays in the sheet (iOS). */
  body.sheet {
    overflow: hidden;
    position: fixed;
    width: 100%;
    left: 0;
    right: 0;
  }
  body.sheet .panel {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    z-index: 50;
    width: 100%;
    height: 100%;
    height: 100dvh;
    max-height: 100dvh;
    min-height: 0;
    overflow-x: clip;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
    overscroll-behavior: contain;
    padding: 0 var(--mar) env(safe-area-inset-bottom);
    background: var(--bg);
    animation: sheet-in 280ms var(--ease);
  }
  body.sheet .panel .pn {
    display: grid;
    grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
    column-gap: var(--gut);
    width: 100%;
    flex: none;
  }
  .sheet-bar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: sticky;
    top: 0;
    z-index: 2;
    margin-inline: calc(var(--mar) * -1);
    padding: max(var(--inset), env(safe-area-inset-top)) var(--mar) var(--inset);
    background: var(--bg);
    border-bottom: 1px solid var(--rule);
    color: var(--fg2);
  }
  .sheet-bar > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .sheet-bar [data-close] { color: var(--fg); text-transform: inherit; letter-spacing: inherit; padding: var(--spacing-2); margin: calc(var(--spacing-2) * -1); flex: none; }
  .gv-plate, .pn-head { margin-top: var(--near); }
}
/* The panel's first line shares a cap line with the list's head row. */
@media (min-width: 960px) {
  .pn { padding-top: var(--spacing-3); }
  .pn-head, .gv-plate { margin-top: 0; }
}
@keyframes sheet-in { from { transform: translateY(24px); opacity: 0; } }

/* The method page, in the index's terms: 14px on a 1.4 line, a rule over
   each step, its name on the left half and its three answers on the right,
   as ledger rows. */

.fs {
  position: relative;
  margin-top: var(--spacing-18);
  padding-top: var(--spacing-3);
  row-gap: 0;
  font-size: var(--font-size-14);
  line-height: var(--lh);
}
.fs::before { content: ""; position: absolute; top: 0; left: var(--mar); right: var(--mar); height: 1px; background: var(--rule); }
.fs-k { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; font-size: inherit; font-weight: 400; }
.fs-k::before { display: none; }
.fs-k > * { padding: 0; }
.fs-k > *::before { display: none; }
.fs-k > .c-no { grid-column: 1 / 2; }
.fs-l { grid-column: 2 / -1; }
.fs-copy { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-content: start; margin-top: var(--spacing-12); }
.fs-h { grid-column: 1 / -1; font-family: var(--font-display); font-weight: 400; font-size: var(--figure); line-height: var(--figure-lead); letter-spacing: var(--letter-spacing-minus-2); text-wrap: balance; }
.fs-f { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-content: start; min-width: 0; margin-top: var(--spacing-12); }
.fs-f > * { grid-column: 1 / -1; min-width: 0; }
.fs-fig { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-content: start; min-width: 0; margin-top: var(--spacing-12); }
.fs-fig > * { grid-column: 1 / -1; min-width: 0; }
@media (min-width: 600px) {
  .fs { margin-top: var(--spacing-24); }
  /* A step has no aside, so its answer runs to the edge at a reading width. */
  .fs-f .lg-v { grid-column: 4 / -1; max-width: 64ch; text-wrap: pretty; }
}
@media (min-width: 960px) {
  .fs { grid-template-rows: auto 1fr; }
  .fs-k { grid-column: 1 / 13; grid-row: 1; }
  .fs-copy { grid-column: 1 / 13; grid-row: 2; }
  .fs-h { grid-column: 1 / 11; }
  /* The answers start on the step's own cap line, under the step's rule. */
  .fs-f { grid-column: 13 / 25; grid-row: 1 / span 2; margin-top: 0; }
  .fs-f > .lg:first-child { padding-top: 0; border-top: 0; }
  .fs.is-cover { grid-template-rows: auto; }
  .fs.is-cover .fs-copy { grid-column: 1 / -1; grid-row: 1; margin-top: 0; }
  .fs.is-cover .fs-h { grid-column: 1 / 13; }
  .fs.is-cover .fs-col { grid-row: 2; }
}

/* Charts. The mark is the same hairline used everywhere else, lit for the
   share that counts. A square stands for one community. */

.key { display: inline-block; flex: none; width: var(--spacing-2); height: var(--spacing-2); }
.k1 { background: var(--fg); }
.k2 { background: var(--fg2); }
.k3 { background: var(--hair); }
.tk { display: flex; justify-content: space-between; align-items: stretch; height: var(--leading); min-width: 0; }
.tk i { width: 1px; flex: none; background: var(--hair); }
.tk i.k1 { background: var(--fg); }
.tk i.k2 { background: var(--fg2); }

.tb { display: grid; grid-template-columns: subgrid; font-variant-numeric: tabular-nums; }
.tb > .row > * { overflow-wrap: break-word; }
.tb-area > .row > * { overflow-wrap: normal; }
.tb-head > * { padding-top: 0; overflow-wrap: normal; hyphens: none; }
.tb-head::before, .tb-head > *::before { top: var(--trim); }
.tb .tb-tk { grid-column: 1 / -1; grid-row: 2; margin-top: var(--spacing-3); margin-bottom: var(--spacing-2); padding-top: 0; }
.tb > .row:has(.tb-tk) > :not(.tb-tk)::before { bottom: calc(var(--cell-y) + 1px); }
.tb .dim { margin-left: var(--spacing-2); }
.tb-area > .row > :nth-child(1) { grid-column: 1 / 6; }
.tb-area > .row > :nth-child(2), .tb-area > .row > :nth-child(3) { display: none; }
.tb-area > .row > :nth-child(4) { grid-column: 6 / 9; }
.tb-src > .row > :nth-child(1) { grid-column: 1 / 3; }
.tb-src > .row > :nth-child(2) { grid-column: 3 / -1; }
.tb-count > .row > :nth-child(1) { grid-column: 1 / 6; }
.tb-count > .row > :nth-child(2) { grid-column: 6 / 9; text-align: right; }
.tb-pick > .row > :nth-child(1) { grid-column: 1 / 5; }
.tb-pick > .row > :nth-child(2) { grid-column: 5 / 7; text-align: right; }
.tb-pick > .row > :nth-child(3) { grid-column: 7 / 9; text-align: right; }
@media (min-width: 600px) {
  .tb-area > .row > :nth-child(1) { grid-column: 1 / 4; }
  .tb-area > .row > :nth-child(2) { display: block; grid-column: 4 / 7; }
  .tb-area > .row > :nth-child(3) { display: block; grid-column: 7 / 10; }
  .tb-area > .row > :nth-child(4) { grid-column: 10 / 13; }
  .tb-src > .row > :nth-child(1) { grid-column: 1 / 4; }
  .tb-src > .row > :nth-child(2) { grid-column: 4 / 13; }
  .tb-count > .row > :nth-child(1) { grid-column: 1 / 9; }
  .tb-count > .row > :nth-child(2) { grid-column: 9 / 13; }
  .tb-pick > .row > :nth-child(1) { grid-column: 1 / 8; }
  .tb-pick > .row > :nth-child(2) { grid-column: 8 / 10; }
  .tb-pick > .row > :nth-child(3) { grid-column: 10 / 13; }
}
/* On the narrow two-pane width the four heads don't fit, so the bar and its
   legend carry "never mentioned" and "called basic", and the mismatch stays. */
@media (min-width: 960px) and (max-width: 1279px) {
  .tb-area > .row > :nth-child(1) { grid-column: 1 / 9; }
  .tb-area > .row > :nth-child(2),
  .tb-area > .row > :nth-child(3) { display: none; }
  .tb-area > .row > :nth-child(4) { grid-column: 9 / 13; }
}

.keys { display: flex; flex-wrap: wrap; align-items: center; gap: var(--spacing-3) var(--spacing-6); margin-top: var(--spacing-6); color: var(--fg2); }
.keys span { display: inline-flex; align-items: center; gap: var(--spacing-2); }
.keys b { font-weight: 400; color: var(--fg); font-variant-numeric: tabular-nums; }
.cap { margin-top: var(--spacing-6); color: var(--fg2); text-wrap: pretty; max-width: 52ch; }
.say { min-height: calc(var(--lh) * 2); color: var(--fg2); text-wrap: balance; }
.say.is-live { color: var(--fg); }

.cl-plot { position: relative; display: grid; grid-template-columns: repeat(41, minmax(0, 1fr)); column-gap: var(--spacing-1); align-items: end; min-height: 120px; margin-top: var(--spacing-6); border-bottom: 1px solid var(--fg); }
.cl-col { grid-column: var(--c); grid-row: 1; display: flex; flex-direction: column-reverse; gap: var(--spacing-1); padding-bottom: var(--spacing-1); }
.cl-dot { display: block; aspect-ratio: 1; background: var(--fg3); transition: background-color 120ms var(--ease); }
a.cl-dot { cursor: pointer; }
.cl-dot.is-in { background: var(--fg); }
.cl-dot:focus-visible, .cl-dot.is-said { background: var(--accent); outline: 2px solid var(--accent); outline-offset: 2px; }
.cl-line { grid-column: 11; grid-row: 1; align-self: stretch; justify-self: end; margin-right: calc(var(--spacing-1) / -2); width: 1px; background: var(--fg); position: relative; pointer-events: none; }
.cl-line b { position: absolute; top: 0; left: var(--spacing-2); font-weight: 400; line-height: 1.2; white-space: nowrap; }
.cl-axis { display: grid; grid-template-columns: repeat(41, minmax(0, 1fr)); column-gap: var(--spacing-1); margin-top: var(--spacing-3); color: var(--fg2); font-variant-numeric: tabular-nums; }
.cl-axis span { grid-column: var(--c); grid-row: 1; justify-self: center; white-space: nowrap; }
.cl-axis span:first-child { justify-self: start; }
.cl-axis span:last-child { justify-self: end; }
.cr .say { min-height: 0; }
.cr .tk { height: var(--spacing-6); margin-top: var(--spacing-6); }

.call { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; }
.call > div { grid-column: span 4; display: flex; flex-direction: column; align-items: flex-start; gap: var(--tight); padding-top: var(--tight); border-top: 1px solid var(--rule); }
.call b { font-weight: 400; font-family: var(--font-display); font-size: var(--figure); line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.call span { color: var(--fg2); text-wrap: balance; }
@media (min-width: 600px) { .call > div { grid-column: span 6; } }

.fs-col { grid-column: 1 / -1; margin-top: var(--spacing-12); padding-top: var(--spacing-3); border-top: 1px solid var(--rule); text-wrap: pretty; }
.fs-ch { font-size: inherit; font-weight: 400; margin-bottom: var(--spacing-6); }
@media (min-width: 600px) { .fs-col { grid-column: span 6; } }

.fail { grid-column: 1 / -1; padding-block: var(--band); }
.fail button { text-decoration: underline; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }

/* Hover only on fine pointers — touch keeps :focus-visible / .is-said / :active. */
@media (hover: hover) and (pointer: fine) {
  .top a:hover,
  .foot a:hover,
  .ix-head button:hover,
  .pn-up:hover,
  .pn-more a:hover,
  .pn-step button:hover,
  .lg-v .lg-link:hover { text-decoration: underline; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
  .p-row:hover .nm,
  .g-row:hover .nm,
  .g-about:hover .c-name { text-decoration-color: currentColor; }
  .pn-cell:hover .pl img { transform: scale(1.04); }
  .pn-cell:hover .pn-cap .nm { text-decoration: underline; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
  .lg-v a:hover { color: var(--fg); }
  .buy:hover { background: var(--fg); color: var(--bg); }
  .buy:hover > :last-child { color: var(--bg); }
  .pline-t:hover::before { background: var(--ink); }
  .cl-dot:hover { background: var(--accent); }
}

/* Keep opacity/color feedback; drop movement and long motion. */
@media (prefers-reduced-motion: reduce) {
  .pn-cell .pl img,
  .p-gifts,
  .buy,
  .pline-t::before,
  .cl-dot { transition: none !important; }
  body.sheet .panel { animation: none !important; }
  .strip { transition: none !important; }
}
