/* Namok Poster — the whole look, in one file. White wall, near-black type in Pretendard, posters
   hung as prints (no boxes, no borders, a shallow paper shadow), one accent for "this one now":
   the current step, the chosen chip, a sentence just copied. Words: src/data/copy.mjs. */

:root {
  --bg: #fff; --ink: #151515; --ink-2: #3b3b3b; --muted: #6b6b6b;
  --line: rgb(21 21 21 / .12); --line-2: rgb(21 21 21 / .26); --wash: #f4f3f0;
  --accent: #d4401f; --accent-ink: #fff;
  --font: "Pretendard", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --nav: 64px; --gut: clamp(20px, 5.5vw, 80px); --max: 1280px; --gap: clamp(32px, 5vw, 72px);
  --ease: cubic-bezier(.2, .7, .2, 1);      /* things that answer a press or arrive */
  --ease-io: cubic-bezier(.45, 0, .25, 1);  /* things that travel across the screen */
  --paper: 0 1px 2px rgb(0 0 0 / .08), 0 12px 28px -16px rgb(0 0 0 / .25);
  --paper-up: 0 2px 4px rgb(0 0 0 / .08), 0 24px 44px -20px rgb(0 0 0 / .34);
}

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; word-break: keep-all; overflow-wrap: break-word; scroll-padding-top: var(--nav); }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.7 var(--font); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
h1, h2, h3 { font-weight: 600; letter-spacing: -0.03em; line-height: 1.22; }
h2 { font-size: clamp(24px, 2.2vw + 15px, 44px); }
h3 { font-size: clamp(20px, 1vw + 15px, 26px); letter-spacing: -0.02em; }
/* a unit of sense in a heading stays on one line: a line breaks between units, never inside one */
.u { display: inline-block; }
img, video { max-width: 100%; }
a { color: inherit; }
code { font-family: var(--mono); font-size: .92em; }
button, select { font: inherit; color: inherit; }
a, button, summary, select { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; scroll-margin-top: 96px; }
/* a section that only receives focus after an in-page link (it is not a control) keeps its place and shows no ring */
[tabindex="-1"]:focus { outline: none; scroll-margin-top: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.wrap { width: min(100% - 2 * var(--gut), var(--max)); margin-inline: auto; }
.lead { font-size: clamp(17px, .4vw + 15.5px, 20px); line-height: 1.65; color: var(--ink-2); max-width: 34em; }
/* a paragraph does not leave one word alone on its last line (where the browser can) */
p, dd, li { text-wrap: pretty; }
.small { font-size: 14px; line-height: 1.6; }
.muted { color: var(--muted); }
.nobr { white-space: nowrap; }
.i { display: block; width: 16px; height: 16px; flex: none; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ------------------------------------------------------------------ controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border: 1px solid var(--ink); border-radius: 10px;
  background: var(--ink); color: #fff; font: 600 16px/1 var(--font); text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform 120ms var(--ease), background-color 160ms var(--ease), border-color 160ms var(--ease), color 160ms var(--ease); }
.btn:hover { background: #000; }
.btn:active { transform: scale(.97); }
.btn--line { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn--line:hover { background: transparent; border-color: var(--ink); }
.btn--sm { min-height: 40px; padding: 0 16px; font-size: 15px; }
.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--ink); cursor: pointer;
  transition: transform 120ms var(--ease), border-color 160ms var(--ease), background-color 160ms var(--ease); }
.icon-btn:hover { border-color: var(--line-2); }
.icon-btn:active { transform: scale(.94); }
.textbtn { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px 0 8px; border: 0; border-radius: 8px; background: none; color: var(--ink-2); font: 500 14px/1 var(--font); cursor: pointer;
  transition: background-color 160ms var(--ease), color 160ms var(--ease), transform 120ms var(--ease); }
.textbtn:hover { background: var(--wash); color: var(--ink); }
.textbtn:active { transform: scale(.97); }
.link { font-weight: 500; text-decoration: underline; text-decoration-color: var(--line-2); text-decoration-thickness: 1px; text-underline-offset: 5px; transition: text-decoration-color 160ms var(--ease); }
.link:hover { text-decoration-color: currentColor; }
.link--back::before { content: "\2190\00a0"; }
@media (pointer: coarse) { .icon-btn, .copy--icon { width: 44px; height: 44px; } .textbtn, .copy { min-height: 44px; } }

/* a sentence to say, with its copy button; in lists the button is its icon alone */
.say { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 2px 8px; padding: 6px 6px 6px 16px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--bg); }
.say__text { flex: 1 1 12em; min-width: min-content; padding: 6px 0; font-size: 15.5px; line-height: 1.55; color: var(--ink); overflow-wrap: break-word; text-wrap: pretty; }
.say--code .say__text { min-width: 0; font-size: 13px; line-height: 1.65; }
.say__url { display: inline-block; max-width: 100%; vertical-align: top; }
.copy { flex: none; display: none; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 0 12px; border: 0; border-radius: 8px; background: none; color: var(--ink-2); font: 500 14px/1 var(--font); cursor: pointer;
  transition: background-color 160ms var(--ease), color 160ms var(--ease), transform 120ms var(--ease); }
.has-js .copy { display: inline-flex; }
.copy:hover { background: var(--wash); color: var(--ink); }
.copy:active { transform: scale(.95); }
.copy--icon { width: 40px; padding: 0; }
.copy__icon { position: relative; width: 16px; height: 16px; flex: none; }
.copy__icon .i { position: absolute; inset: 0; transition: opacity 140ms var(--ease), transform 200ms var(--ease); }
.copy__icon .i--check { opacity: 0; transform: scale(.6); }
.copy__label { display: inline-grid; justify-items: start; }
.copy__label > span { grid-area: 1 / 1; transition: opacity 140ms var(--ease); }
.copy__label > span + span { opacity: 0; visibility: hidden; }
.copy.is-copied { color: var(--accent); }
.copy.is-copied .i--copy { opacity: 0; transform: scale(.6); }
.copy.is-copied .i--check { opacity: 1; transform: none; }
.copy.is-copied .copy__label > span:first-child { opacity: 0; visibility: hidden; }
.copy.is-copied .copy__label > span + span { opacity: 1; visibility: visible; }

/* the two- or three-way switch: plain words on a hairline, and a rule in the accent colour that
   travels to the chosen one */
.seg { position: relative; display: inline-flex; gap: 4px; box-shadow: inset 0 -1px 0 var(--line); isolation: isolate; }
.seg__btn { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border: 0; border-radius: 4px 4px 0 0; background: none; color: var(--muted); font: 500 14.5px/1 var(--font); white-space: nowrap; cursor: pointer;
  transition: color 160ms var(--ease), transform 120ms var(--ease); }
.seg__btn:hover, .seg__btn[aria-checked="true"] { color: var(--ink); }
.seg__btn:active { transform: scale(.97); }
.seg__n { font-size: 12px; font-variant-numeric: tabular-nums; }
.slide-ind { position: absolute; z-index: 0; left: 0; top: 0; opacity: 0; pointer-events: none; box-shadow: inset 0 -2px 0 var(--accent); transform-origin: 0 0; transition: opacity 160ms var(--ease); }
.seg:not(.has-ind) .seg__btn[aria-checked="true"] { box-shadow: inset 0 -2px 0 var(--accent); }
@media (pointer: coarse) { .seg__btn, .chip { height: 44px; } }

/* ------------------------------------------------------------------ nav */
.nav { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); view-transition-name: nav; }
.nav__bar { position: relative; display: flex; align-items: center; gap: 8px; height: var(--nav); }
.skip { position: absolute; left: 0; top: 12px; z-index: 2; padding: 10px 14px; border-radius: 8px; background: var(--ink); color: #fff; font-size: 14px; text-decoration: none; transform: translateY(-200%); }
.skip:not(:focus-visible) { opacity: 0; pointer-events: none; }
.skip:focus-visible { transform: none; }
.nav__logo { margin-right: 20px; font-size: 19px; font-weight: 600; letter-spacing: -0.03em; text-decoration: none; white-space: nowrap; }
.nav__links { display: flex; gap: 2px; margin-right: auto; }
.nav__link { display: inline-flex; align-items: center; min-height: 40px; padding: 0 12px; border-radius: 8px; color: var(--ink-2); font-size: 15px; font-weight: 500; text-decoration: none; transition: color 160ms var(--ease), background-color 160ms var(--ease); }
.nav__link:hover { color: var(--ink); background: var(--wash); }
.nav__link[aria-current="page"] { color: var(--ink); }
.nav__link[aria-current="page"] span { box-shadow: 0 2px 0 var(--ink); padding-bottom: 4px; }
.nav__spy { position: absolute; left: 0; bottom: -1px; height: 2px; width: 0; background: var(--ink); opacity: 0; pointer-events: none; transform-origin: 0 0; transition: opacity 160ms var(--ease); }
.nav__toggle { display: none; }
.nav__toggle .i-x, .nav.is-open .nav__toggle .i-bars { display: none; }
.nav.is-open .nav__toggle .i-x { display: block; }
@media (max-width: 899px) {
  .nav__logo { margin-right: auto; }
  .nav__toggle { display: inline-grid; }
  .nav__spy { display: none; }
  .nav__links { position: absolute; left: calc(-1 * var(--gut)); right: calc(-1 * var(--gut)); top: 100%; margin: 0; flex-direction: column; gap: 0; padding: 8px var(--gut) 20px; background: var(--bg); border-bottom: 1px solid var(--line);
    visibility: hidden; opacity: 0; transform: translateY(-8px); transition: opacity 180ms var(--ease), transform 220ms var(--ease), visibility 0s linear 220ms; }
  .nav.is-open .nav__links { visibility: visible; opacity: 1; transform: none; transition: opacity 180ms var(--ease), transform 220ms var(--ease), visibility 0s; }
  .nav__link { min-height: 52px; padding: 0; border-radius: 0; font-size: 18px; border-bottom: 1px solid var(--line); }
  .nav__link:hover { background: none; }
}
@media (max-width: 359px) { .nav__logo { font-size: 17px; } .nav__cta { padding: 0 12px; } }

/* ------------------------------------------------------------------ a poster: a print on the wall */
.poster { display: block; color: inherit; text-decoration: none; }
.poster__pic { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 2px; background: var(--wash); box-shadow: var(--paper); overflow: clip; transition: transform 240ms var(--ease), box-shadow 240ms var(--ease); }
.poster--a3 .poster__pic { aspect-ratio: 1000 / 1414; }
.poster__img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
/* a poster that holds both shapes shows the one its page is set to (data-shape on an ancestor) */
[data-shape="a3"] .poster--both .poster__pic { aspect-ratio: 1000 / 1414; }
[data-shape="wide"] .poster--both .poster__pic { aspect-ratio: 16 / 9; }
[data-shape="a3"] .poster--both .poster__img--wide, [data-shape="wide"] .poster--both .poster__img--a3 { display: none; }
.poster__cap { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; margin-top: 12px; font-size: 14px; line-height: 1.5; font-weight: 500; text-wrap: balance; }
.poster__tag { font-weight: 600; color: var(--muted); }
.poster__sub { flex-basis: 100%; font-size: 13px; font-weight: 400; color: var(--muted); }
.poster__name { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; transition: text-decoration-color 160ms var(--ease); }
a.poster:hover .poster__name { text-decoration-color: var(--line-2); }
@media (hover: hover) and (pointer: fine) { a.poster:hover .poster__pic { transform: translateY(-3px); box-shadow: var(--paper-up); } }
a.poster:active .poster__pic { transform: scale(.985); transition-duration: 120ms; }
a.poster.is-loading .poster__pic { transform: scale(.985); }

/* three drafts: side by side; on a phone, and in the hero, the first large and the other two beside it */
.trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 32px); align-items: start; }
.trio--lead { grid-template-columns: minmax(0, 2.18fr) minmax(0, 1fr); gap: 16px 20px; }
.trio--lead > :first-child { grid-row: 1 / span 2; }
@media (max-width: 639px) {
  .trio { grid-template-columns: minmax(0, 2.24fr) minmax(0, 1fr); gap: 12px; }
  .trio > :first-child { grid-row: 1 / span 2; }
  .trio .poster__cap { margin-top: 6px; font-size: 13px; }
  .trio > :not(:first-child) .poster__cap { display: block; font-size: 12px; line-height: 1.45; }
  .trio > :not(:first-child) .poster__tag { margin-right: 5px; }
  [data-shape="wide"] .trio:not(.trio--lead) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  [data-shape="wide"] .trio:not(.trio--lead) > :first-child { grid-column: 1 / -1; grid-row: auto; }
}

/* ------------------------------------------------------------------ hero */
.hero { padding: clamp(36px, 5vw, 72px) 0 clamp(64px, 8vw, 112px); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.hero h1 { font-size: clamp(27px, 4.3vw, 62px); line-height: 1.18; letter-spacing: -0.04em; }
.hero h1 .u { display: block; white-space: nowrap; }
.hero .lead { margin-top: clamp(20px, 2vw, 28px); max-width: 29em; }
.hero .actions { margin-top: clamp(24px, 2.6vw, 36px); }
.bubble { width: fit-content; max-width: min(100%, 30em); margin: 0 0 12px auto; padding: 12px 18px 14px; border-radius: 18px 18px 4px 18px; background: var(--ink); color: #fff; font-size: 15.5px; line-height: 1.55; }
.bubble__label { display: block; margin-bottom: 2px; font-size: 12.5px; font-weight: 500; color: rgb(255 255 255 / .68); }
.hero__reply { margin-bottom: 14px; font-size: 13px; font-weight: 500; color: var(--muted); }
@media (max-width: 1023px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: 44px; }
  .hero h1 { font-size: clamp(27px, 8.2vw, 56px); }
}

/* ------------------------------------------------------------------ sections */
.sec { padding: clamp(72px, 9vw, 136px) 0; }
.sec__head { display: grid; gap: 14px; margin-bottom: clamp(32px, 4vw, 56px); }
.sec__head--row { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px 32px; }
.sec__head--row > div:not(.seg) { display: grid; gap: 14px; }
.sub { margin: clamp(64px, 8vw, 112px) 0 0; }

/* ------------------------------------------------------------------ the guide: every step open, its film beside it */
.guide { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap); align-items: start; margin-top: clamp(32px, 4vw, 56px); }
.guide > .steps { grid-column: 1; grid-row: 1; }
.guide__media { grid-column: 2; grid-row: 1; position: sticky; top: calc(var(--nav) + 24px); }
.guide--flip > .steps { grid-column: 2; }
.guide--flip > .guide__media { grid-column: 1; }
.guide__frame { position: relative; aspect-ratio: 4 / 3; border-radius: 14px; background: #f3f1ec; overflow: clip; }
.guide__still, .guide__video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.guide__still { opacity: 0; transition: opacity 220ms var(--ease); }
.guide__still.is-on { opacity: 1; }
/* the film takes the still's place at once when it starts; only a jump to another chapter dips to that chapter's still */
.guide__video { opacity: 0; }
.guide.is-live .guide__video { opacity: 1; }
.guide.is-ready .guide__video { transition: opacity 200ms var(--ease); }
.guide.is-seeking .guide__video { opacity: 0; }
.guide__ctl { display: flex; justify-content: flex-end; margin-top: 6px; }
.textbtn .i-play { display: none; }
.textbtn[aria-pressed="true"] .i-play { display: block; }
.textbtn[aria-pressed="true"] .i-pause { display: none; }
.guide__help { display: grid; gap: 8px; margin-top: 12px; padding-top: 16px; border-top: 1px solid var(--line); }
.steps { position: relative; list-style: none; margin: 0; padding: 0; }
.step { position: relative; padding: 26px 0 28px 44px; border-top: 1px solid var(--line); }
.step:first-child { padding-top: 0; border-top: 0; }
.step__head { display: block; width: 100%; padding: 0; border: 0; background: none; color: var(--ink); font: 600 19px/1.45 var(--font); letter-spacing: -0.02em; text-align: left; cursor: pointer; }
.step__num { position: absolute; left: 0; display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--line-2); border-radius: 50%; color: var(--muted); font-size: 13px; font-weight: 600; letter-spacing: 0;
  transition: background-color 200ms var(--ease), border-color 200ms var(--ease), color 200ms var(--ease), transform 120ms var(--ease); }
.step__head:hover .step__num { border-color: var(--ink); color: var(--ink); }
.step__head:active .step__num { transform: scale(.92); }
.step.is-on .step__num, .step.is-on .step__head:hover .step__num { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.step__body { display: grid; gap: 12px; margin-top: 10px; font-size: 16px; line-height: 1.7; color: var(--ink-2); }
/* the film's place in its chapter, drawn on the rule under the step on show */
.steps__mark { position: absolute; left: 44px; right: 0; top: -1px; height: 2px; pointer-events: none; opacity: 0; transition: opacity 160ms var(--ease); }
.steps__mark.is-on { opacity: 1; }
.steps__mark i { display: block; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; }
.manual > summary { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; color: var(--ink); font-size: 15px; font-weight: 500; cursor: pointer; list-style: none;
  text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 5px; transition: text-decoration-color 160ms var(--ease); }
.manual > summary::-webkit-details-marker { display: none; }
.manual > summary:hover { text-decoration-color: currentColor; }
.manual > summary:active { color: var(--muted); }
.manual > summary .i { width: 12px; height: 12px; transition: transform 240ms var(--ease); }
.manual[open] > summary .i { transform: rotate(180deg); }
.manual__in { display: grid; gap: 8px; padding-top: 6px; }
/* the one height that animates on the page: commands opening under the step they belong to (where the browser can) */
.manual::details-content { block-size: 0; overflow: clip; transition: block-size 240ms var(--ease), content-visibility 240ms allow-discrete; }
.manual[open]::details-content { block-size: auto; }
:root { interpolate-size: allow-keywords; }
/* one column: the film, then the steps, and the sentence for when it goes wrong after the steps
   (it sits under the film on a wide screen; here it would come between the film and step 1) */
@media (max-width: 1023px) {
  .guide, .guide--flip { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .guide__media, .guide--flip > .guide__media { display: contents; }
  .guide__frame { grid-column: 1; grid-row: 1; }
  .guide__ctl { grid-column: 1; grid-row: 2; }
  .guide > .steps, .guide--flip > .steps { grid-column: 1; grid-row: 3; margin-top: 20px; }
  .guide__help { grid-column: 1; grid-row: 4; margin-top: 4px; padding-top: 24px; }
}

/* ------------------------------------------------------------------ examples: what was said, then the drafts */
.run + .run { margin-top: clamp(56px, 7vw, 104px); }
.said { display: grid; gap: 6px; max-width: 46em; margin-bottom: clamp(20px, 2.4vw, 32px); }
.said__label { font-size: 13px; font-weight: 500; color: var(--muted); }
.said__note { margin-left: 8px; color: var(--ink-2); }
.said__text { font-size: clamp(18px, .9vw + 14px, 23px); line-height: 1.55; font-weight: 500; letter-spacing: -0.015em; }
.said__more { color: var(--ink-2); }
.said .say { max-width: 30em; }

/* ------------------------------------------------------------------ follow-ups: the picture, and the sentences that gave it */
.follow { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); grid-template-rows: auto 1fr; grid-template-areas: "stage head" "stage list"; column-gap: var(--gap); align-items: start; }
.follow__head { grid-area: head; display: grid; gap: 14px; margin-bottom: 28px; }
.follow__stage { grid-area: stage; position: relative; height: min(70vh, 600px); }
.follow__shot { position: absolute; inset: 0; display: flex; align-items: flex-start; justify-content: flex-start; opacity: 0; visibility: hidden; transition: opacity 120ms var(--ease), visibility 0s linear 120ms; }
.follow__shot.is-on { opacity: 1; visibility: visible; transition: opacity 200ms var(--ease) 60ms, visibility 0s; }
.follow__shot img { display: block; flex: none; width: auto; height: auto; max-width: 100%; max-height: 100%; border-radius: 2px; box-shadow: var(--paper); }
.asks { grid-area: list; list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.ask { position: relative; display: flex; align-items: center; gap: 4px; border-bottom: 1px solid var(--line); }
.ask::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 2px; background: var(--accent); transform: scaleY(0); transform-origin: 50% 0; transition: transform 200ms var(--ease); }
.ask.is-on::before { transform: scaleY(1); }
.ask__pick { flex: 1 1 auto; min-width: 0; min-height: 56px; padding: 12px 0 12px 18px; border: 0; background: none; color: var(--ink-2); font: 400 16px/1.5 var(--font); text-align: left; cursor: pointer; transition: color 160ms var(--ease); }
.ask__pick:hover, .ask.is-on .ask__pick { color: var(--ink); }
.ask.is-on .ask__pick { font-weight: 500; }
.ask__pick:active { color: var(--muted); }
.ask__pick:focus-visible { outline-offset: -2px; }
html:not(.has-js) .follow__stage { height: auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
html:not(.has-js) .follow__shot { position: static; opacity: 1; visibility: visible; }
@media (max-width: 1023px) {
  .follow { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; grid-template-areas: "head" "stage" "list"; }
  .follow__stage { height: min(56vh, 460px); margin-bottom: 20px; }
  .follow__shot { align-items: center; justify-content: center; }
}
@media (max-width: 599px) {
  .follow__stage { height: min(42vh, 330px); margin-bottom: 16px; }
}

/* ------------------------------------------------------------------ walls of posters */
.families { display: flex; flex-wrap: wrap; gap: 6px 22px; list-style: none; margin: 0 0 clamp(28px, 3vw, 40px); padding: 0; font-size: 15px; }
.families a { color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 5px; transition: color 160ms var(--ease), text-decoration-color 160ms var(--ease); }
.families a:hover { color: var(--ink); text-decoration-color: currentColor; }
.wall { display: grid; gap: clamp(28px, 3vw, 44px) clamp(16px, 2vw, 24px); list-style: none; margin: 0; padding: 0; }
.wall--a3 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.wall--a3:not(.wall--row) > li:nth-child(n + 16) { display: none; }
.wall--wide { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1359px) { .wall--a3:not(.wall--row) { grid-template-columns: repeat(4, minmax(0, 1fr)); } .wall--a3:not(.wall--row) > li:nth-child(n + 16) { display: block; } }
@media (max-width: 1023px) {
  .wall--a3, .wall--a3:not(.wall--row) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .wall--a3:not(.wall--row) > li:nth-child(n + 13), .wall--row > li:nth-child(n + 4) { display: none; }
  .wall--wide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  .wall--a3, .wall--a3:not(.wall--row) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wall--a3:not(.wall--row) > li:nth-child(n + 9) { display: none; }
  .wall--row > li:nth-child(4) { display: block; }
  .wall--row > li:nth-child(n + 5) { display: none; }
}

/* ------------------------------------------------------------------ questions */
.faq { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--gap); align-items: start; }
.faq__head { display: grid; gap: 14px; }
.qa { border-top: 1px solid var(--line); }
.qa__item { display: grid; gap: 8px; padding: 24px 0 26px; border-bottom: 1px solid var(--line); }
.qa dt { font-size: 18px; font-weight: 600; line-height: 1.45; letter-spacing: -0.02em; }
.qa dd { color: var(--ink-2); }
.shapes { container-type: inline-size; display: flex; align-items: flex-end; gap: 12px; margin-top: 18px; padding-bottom: 14px; }
.shapes img { display: block; width: auto; height: min(150px, calc((100cqw - (var(--n, 3) - 1) * 12px) / var(--sum, 3.15))); aspect-ratio: var(--ar); border-radius: 2px; box-shadow: var(--paper); }
@media (max-width: 899px) { .faq { grid-template-columns: minmax(0, 1fr); gap: 32px; } }

/* ------------------------------------------------------------------ the close: posters, then the one thing to do */
.close { padding-bottom: clamp(72px, 9vw, 120px); }
.close .wall { margin-bottom: clamp(56px, 7vw, 96px); }
.close__ask { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 32px var(--gap); align-items: end; }
.close__ask > div:first-child { display: grid; gap: 14px; }
.close__do { display: grid; gap: 16px; justify-items: start; }
.close__do .say { width: 100%; }
@media (max-width: 899px) { .close__ask { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------------------------------------------------ foot */
.foot { padding: 48px 0 40px; border-top: 1px solid var(--line); font-size: 14.5px; line-height: 1.6; color: var(--ink-2); }
.foot__grid { display: grid; grid-template-columns: minmax(0, 5fr) repeat(3, minmax(0, 2fr)); gap: 32px 24px; }
.foot__about { display: grid; gap: 8px; align-content: start; max-width: 24em; }
.foot__name { font-size: 17px; font-weight: 600; letter-spacing: -0.03em; color: var(--ink); }
.foot__title { margin-bottom: 6px; font-size: 13px; font-weight: 500; color: var(--muted); }
.foot__col ul { list-style: none; margin: 0; padding: 0; }
.foot__col a { display: inline-flex; align-items: center; min-height: 32px; text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; transition: text-decoration-color 160ms var(--ease), color 160ms var(--ease); }
.foot__col a:hover { color: var(--ink); text-decoration-color: currentColor; }
.foot__legal { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
@media (max-width: 767px) { .foot__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .foot__about { grid-column: 1 / -1; } }

/* ------------------------------------------------------------------ /styles/: the library */
.lib { padding: clamp(28px, 4.5vw, 64px) 0 96px; }
.lib__head { display: grid; gap: 10px; }
.lib__head h1, .nf h1 { font-size: clamp(30px, 3.2vw + 12px, 56px); letter-spacing: -0.04em; }
.lib__bar { position: sticky; top: var(--nav); z-index: 10; margin-top: clamp(16px, 2.4vw, 28px); background: var(--bg); border-bottom: 1px solid var(--line); view-transition-name: lib-bar; }
html:not(.has-js) .lib__bar { display: none; }
.lib__filters { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding-block: 12px; }
.lib__count { margin-left: auto; font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pick { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.pick__select { height: 42px; padding: 0 36px 0 14px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); font: 500 14px/1 var(--font); appearance: none; cursor: pointer; transition: border-color 160ms var(--ease);
  background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%23151515' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center / 12px; }
.pick__select:hover { border-color: var(--line-2); }
.chips { flex: 1 0 100%; position: relative; display: flex; flex-wrap: wrap; gap: 6px; isolation: isolate; }
.chip { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 6px; flex: none; height: 36px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--ink-2); font: 500 14px/1 var(--font); white-space: nowrap; cursor: pointer;
  transition: color 160ms var(--ease), border-color 160ms var(--ease), transform 120ms var(--ease); }
.chip:not(:disabled):hover { border-color: var(--line-2); color: var(--ink); }
.chip:not(:disabled):active { transform: scale(.97); }
.chip[aria-checked="true"], .chip[aria-checked="true"]:hover { color: var(--accent-ink); border-color: transparent; }
.chips.has-ind .chip[aria-checked="true"] { transition: color 120ms linear 130ms, border-color 120ms linear 130ms, transform 120ms var(--ease); }
.chip:disabled { opacity: .45; cursor: default; }
.chips > .slide-ind { border-radius: 999px; background: var(--accent); box-shadow: none; }
.chips:not(.has-ind) .chip[aria-checked="true"] { background: var(--accent); }
.lib__body { padding-top: clamp(24px, 3vw, 40px); }
.lib__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(28px, 3vw, 44px) clamp(16px, 2vw, 24px); list-style: none; margin: 0; padding: 0; }
.lib[data-shape="a3"] .lib__grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.lib__item { content-visibility: auto; contain-intrinsic-size: auto 240px auto 400px; }
.lib[data-shape="wide"] .lib__item { contain-intrinsic-size: auto 300px auto 220px; }
.lib__item[hidden] { display: none; }
.lib__item.is-target .poster__pic { outline: 2px solid var(--accent); outline-offset: 4px; }
.lib__empty { display: grid; justify-items: start; gap: 16px; padding: 64px 0; }
.lib__empty[hidden] { display: none; }
@media (max-width: 1279px) { .lib[data-shape="a3"] .lib__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } .lib__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1023px) { .lib[data-shape="a3"] .lib__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .lib__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639px) {
  .lib[data-shape="a3"] .lib__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lib__grid { grid-template-columns: minmax(0, 1fr); }
  .lib__bar { position: static; }
  .lib__count { flex: 1 0 100%; margin: 0; order: 9; }
  .pick__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  /* the families in one row that scrolls sideways, so posters reach the first screen */
  .chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-inline: calc(-1 * var(--gut)); padding-inline: var(--gut); scroll-padding-inline: var(--gut); }
  .chips::-webkit-scrollbar { display: none; }
}

/* ------------------------------------------------------------------ one style: the page, and the sheet over the library */
.dtp { padding: clamp(20px, 3.5vw, 44px) 0 96px; }
.dtp__back { margin-bottom: 24px; font-size: 15px; }
.dt { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(36px, 4.5vw, 64px); }
.dt__top { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.dt--both .dt__top { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.dt__side { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(24px, 3vw, 40px); }
.dt__pic { border-radius: 2px; background: var(--wash); box-shadow: var(--paper); overflow: clip; }
.dt__img { display: block; width: 100%; height: auto; transition: opacity 160ms var(--ease); }
.dt__pic--wide .dt__img { aspect-ratio: 16 / 9; }
.dt__pic--a3 .dt__img { aspect-ratio: 1000 / 1414; }
.dt__img.is-swapping { opacity: 0; }
.dt__text { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.dt__label { font-size: 13px; font-weight: 500; line-height: 1.5; letter-spacing: 0; color: var(--muted); }
.dt__name { font-size: clamp(26px, 1.8vw + 16px, 42px); }
.dt__id { margin-left: 4px; font-size: .45em; font-weight: 400; letter-spacing: 0; color: var(--muted); vertical-align: middle; }
.dt__suits { display: grid; gap: 2px; color: var(--ink-2); }
.dt__ask { display: grid; gap: 8px; margin-top: 12px; padding-top: 20px; border-top: 1px solid var(--line); }
.dt__motifs { display: grid; gap: 16px; }
.dt__motifs ul { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: clamp(20px, 2.4vw, 32px) clamp(16px, 2vw, 24px); list-style: none; margin: 0; padding: 0; }
.motif { display: grid; gap: 12px; width: 100%; padding: 0; border: 0; background: none; color: var(--ink-2); text-align: left; cursor: pointer; }
.motif__pic { display: block; aspect-ratio: 16 / 9; border-radius: 2px; background: var(--wash); box-shadow: var(--paper); overflow: clip; outline: 2px solid transparent; outline-offset: 4px; transition: outline-color 160ms var(--ease), transform 200ms var(--ease); }
.motif__pic img { display: block; width: 100%; height: 100%; object-fit: cover; }
.motif:hover .motif__pic { outline-color: var(--line-2); }
.motif:active .motif__pic { transform: scale(.985); }
.motif[aria-pressed="true"] .motif__pic { outline-color: var(--accent); }
.motif__text { display: grid; gap: 2px; font-size: 14px; line-height: 1.55; }
.motif__text b { font-size: 15px; font-weight: 600; color: var(--ink); }
.motif__text code { font-size: 12px; color: var(--muted); }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.pager__link { display: grid; gap: 2px; min-height: 44px; text-decoration: none; font-weight: 500; transition: color 160ms var(--ease); }
.pager__link span:last-child { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; transition: text-decoration-color 160ms var(--ease); }
.pager__link:hover span:last-child { text-decoration-color: currentColor; }
.pager__link:active { color: var(--muted); }
.pager__link--next { text-align: right; }
html:has(.sheet[open]) { overflow: hidden; scrollbar-gutter: stable; }
.sheet { width: min(1160px, calc(100vw - 32px)); max-width: none; max-height: calc(100dvh - 32px); margin: auto; padding: 0; border: 0; border-radius: 16px; background: var(--bg); color: var(--ink); overflow: auto; overscroll-behavior: contain; box-shadow: 0 30px 80px -24px rgb(0 0 0 / .5); }
.sheet::backdrop { background: rgb(20 20 20 / .5); }
/* browsers without view transitions: the sheet rises in and sinks out by itself */
.sheet.is-plain[open] { animation: sheet-in 240ms var(--ease); }
.sheet.is-plain[open]::backdrop { animation: fade-in 200ms var(--ease); }
.sheet.is-plain.is-closing { animation: sheet-out 160ms var(--ease) forwards; }
.sheet.is-plain.is-closing::backdrop { animation: fade-out 160ms var(--ease) forwards; }
@keyframes sheet-in { from { opacity: 0; transform: translateY(12px) scale(.985); } }
@keyframes sheet-out { to { opacity: 0; transform: translateY(8px) scale(.99); } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }
.sheet__bar { position: sticky; top: 0; z-index: 2; display: flex; justify-content: flex-end; padding: 10px 10px 8px; background: var(--bg); }
.sheet__body { padding: 0 clamp(16px, 3vw, 36px) clamp(24px, 3vw, 40px); }
.sheet .pager { display: none; }
.nf { padding: clamp(64px, 10vw, 160px) 0; }
.nf .lead { margin-top: 16px; }
.nf .actions { margin-top: 32px; }
@media (max-width: 767px) {
  .dt--both .dt__top { grid-template-columns: minmax(0, 1fr); }
  .dt--both .dt__pic--a3 { max-width: 420px; }
  .sheet { width: 100vw; height: 100dvh; max-height: 100dvh; border-radius: 0; }
}

/* ------------------------------------------------------------------ view transitions */
@view-transition { navigation: auto; }
::view-transition { pointer-events: none; }
::view-transition-group(*) { animation-duration: 240ms; animation-timing-function: var(--ease-io); }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 180ms; }
::view-transition-old(*):only-child { animation-duration: 140ms; }
/* the bars stay as they are, above whatever moves under them, and live: their own pills travel inside */
::view-transition-group(nav) { z-index: 3; }
::view-transition-group(lib-bar) { z-index: 2; }
[data-shape-switch] { view-transition-name: shape-switch; }
::view-transition-old(nav), ::view-transition-old(lib-bar), ::view-transition-old(shape-switch) { display: none; }
::view-transition-new(nav), ::view-transition-new(lib-bar), ::view-transition-new(shape-switch) { animation: none; }
/* a shape switch changes every picture at once: no card travels, the page just changes */
.no-vt .lib__item, .no-vt .poster__img { view-transition-name: none !important; }
/* the sheet covers the bars: while it opens or closes they belong to the page behind it (dimmed with it) */
.vt-sheet .nav, .vt-sheet .lib__bar { view-transition-name: none; }
/* a card that was not there comes in after the one that was in its place has gone, so the two do not show through each other */
::view-transition-new(*):only-child { animation-duration: 160ms; animation-delay: 80ms; animation-fill-mode: both; }

/* ------------------------------------------------------------------ less motion */
@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
  .btn, .icon-btn, .textbtn, .copy, .copy__icon .i, .copy__label > span, .seg__btn, .chip, .slide-ind, .nav__spy, .nav__links, .poster__pic, .guide__still, .guide__video, .step__num,
  .manual > summary .i, .manual::details-content, .follow__shot, .ask::before, .motif__pic, .dt__img, .steps__mark { transition: none !important; }
  .sheet.is-plain[open], .sheet.is-plain[open]::backdrop, .sheet.is-plain.is-closing, .sheet.is-plain.is-closing::backdrop { animation: none !important; }
  .btn:active, .icon-btn:active, .textbtn:active, .copy:active, .seg__btn:active, .chip:not(:disabled):active, .step__head:active .step__num, .motif:active .motif__pic,
  a.poster:hover .poster__pic, a.poster:active .poster__pic, a.poster.is-loading .poster__pic { transform: none; }
  .copy__icon .i--check, .copy.is-copied .i--copy { transform: none; }
}

/* without JavaScript: a control that would do nothing is not shown */
html:not(.has-js) :is([data-shape-switch], .guide__ctl, .nav__toggle) { display: none; }
