/* Home page sections below the hero. Tokens: tokens.css; grammar: home.css. */

/* ───────── 1. Builder window ───────── */
.bw { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; border-radius: 16px; background: var(--panel); box-shadow: 0 0 0 1px var(--line-2), var(--shadow-float); overflow: clip; }
.bw-bar { display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; min-height: 56px; padding: 0 12px 0 20px; border-bottom: 1px solid var(--line); }
.bw-form { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; white-space: nowrap; }
.bw-form .icon, .bw-tabs .icon { width: 16px; height: 16px; color: var(--muted); }
.bw-live { display: inline-flex; align-items: center; gap: 8px; min-height: 24px; padding: 0 10px 0 8px; border-radius: 99px; background: var(--panel-2); font: 500 .8125rem/1 var(--font-mono); white-space: nowrap; }
.bw-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.bw-saved { overflow: hidden; color: var(--text-2); font-size: .875rem; white-space: nowrap; text-overflow: ellipsis; }
.bw-saved[data-state='done'] { color: var(--text); }
.bw-tabs { display: flex; gap: 4px; align-self: stretch; margin-inline-end: 16px; color: var(--text-2); font-size: .875rem; font-weight: 500; }
.bw-tabs span { display: inline-flex; align-items: center; gap: 8px; padding: 0 12px; }
.bw-tabs .is-on { color: var(--text); box-shadow: inset 0 -2px 0 var(--text); }
.bw-tabs .is-on .icon { color: var(--text); }
.bw-pub { min-width: 148px; }
.bw-pub:disabled { opacity: 1 !important; --btn-bg: var(--panel-2) !important; --btn-fg: var(--muted) !important; }
.bw-pub[data-busy] { cursor: progress; }

.bw-body { display: grid; grid-template-columns: 232px minmax(0, 1fr) 356px; min-height: 420px; }
.bw-outline { display: grid; align-content: start; gap: 4px; padding: 16px 12px; border-inline-end: 1px solid var(--line); }
.bw-list { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.bw-list button, .bw-end, .bw-add summary { display: grid; grid-template-columns: 16px minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; min-height: 40px; padding: 0 10px; border: 0; border-radius: 8px; background: none; color: var(--text-2); font: 400 .875rem/1.2 var(--font-sans); text-align: start; cursor: pointer; transition: background-color 140ms var(--ease), color 140ms var(--ease); }
.bw-list .icon, .bw-end .icon, .bw-add .icon { width: 16px; height: 16px; color: var(--muted); }
.bw-list span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bw-list b { color: var(--muted); font: 500 .75rem/1 var(--font-mono); }
.bw-list [aria-current] { background: var(--panel-2); color: var(--text); }
.bw-add { position: relative; }
.bw-add summary { list-style: none; color: var(--text); font-weight: 500; }
.bw-add summary::-webkit-details-marker { display: none; }
.bw-pop { position: absolute; z-index: 3; left: 0; top: calc(100% + 4px); display: grid; gap: 2px; width: 208px; padding: 6px; border-radius: 12px; background: var(--panel-2); box-shadow: 0 0 0 1px var(--line-2), var(--shadow-float); }
.bw-pop button { display: grid; grid-template-columns: 16px 1fr; align-items: center; gap: 12px; min-height: 40px; padding: 0 10px; border: 0; border-radius: 8px; background: none; color: var(--text); font: 400 .875rem/1 var(--font-sans); text-align: start; cursor: pointer; }
.bw-sub { margin: 16px 0 0; padding: 0 10px; color: var(--muted); font-size: .8125rem; }
.bw-end { cursor: default; }

.bw-canvas { position: relative; min-height: 0; overflow: clip; background: var(--bg-2); }
.bw-canvas::after { content: ''; position: absolute; inset: auto 0 0; height: 48px; background: linear-gradient(transparent, var(--bg-2)); pointer-events: none; }
.bw-cards { position: absolute; inset: 0 0 auto; display: grid; gap: 12px; width: min(100% - 48px, 560px); margin: 24px auto; transition: translate 320ms var(--ease); }
.bw-card { display: grid; gap: 12px; padding: 14px 16px 12px; border-radius: 12px; background: var(--panel); box-shadow: 0 0 0 1px var(--line); cursor: pointer; transition: box-shadow 160ms var(--ease); }
.bw-card.is-on { box-shadow: 0 0 0 2px var(--text); cursor: default; }
.bw-card-top { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: .8125rem; }
.bw-type { display: inline-flex; align-items: center; gap: 8px; min-height: 28px; padding: 0 10px; border-radius: 8px; background: var(--panel-2); color: var(--text-2); }
.bw-type .icon { width: 14px; height: 14px; }
.bw-qn { font-family: var(--font-mono); } .bw-qn b { font-weight: 500; }
.bw-in { display: block; field-sizing: content; width: 100%; min-height: 32px; padding: 0 0 4px; resize: none; overflow: hidden; border: 0; border-bottom: 1px solid transparent; border-radius: 0; background: none; color: var(--text); font: 500 1.125rem/1.35 var(--font-sans); letter-spacing: -.01em; transition: border-color 140ms var(--ease); }
body.site .bw-in:focus { outline: 0; border-color: var(--accent); }
.bw-req { display: inline-flex; align-items: center; justify-self: end; gap: 10px; min-height: 32px; color: var(--text-2); font-size: .875rem; cursor: pointer; }
.bw-req input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.bw-req span { width: 36px; height: 20px; padding: 2px; border-radius: 99px; background: var(--line-2); transition: background-color 160ms var(--ease); }
.bw-req span::before { content: ''; display: block; width: 16px; height: 16px; border-radius: 50%; background: var(--panel); transition: translate 180ms var(--ease); }
.bw-req input:checked + span { background: var(--text); }
.bw-req input:checked + span::before { translate: 16px 0; }
.bw-req input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* controls drawn in the cards and the phone */
.ct { display: flex; gap: 8px; color: var(--muted); font-size: .875rem; }
.ct-stars .icon { width: 24px; height: 24px; stroke-width: 1.5; }
.ct-opts { flex-direction: column; } .ct-opts span { display: flex; align-items: center; gap: 10px; min-height: 36px; padding: 0 12px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--text-2); }
.ct-opts i { flex: none; width: 14px; height: 14px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--muted); }
.ct-field { align-items: center; min-height: 36px; padding: 0 12px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--line-2); } .ct-field .icon { width: 14px; height: 14px; }
.ct-area { min-height: 56px; align-items: start; padding-top: 10px; }
.ct-pair span, .ct-scale span { display: grid; place-items: center; min-width: 40px; min-height: 36px; padding: 0 12px; border-radius: 8px; box-shadow: inset 0 0 0 1px var(--line-2); color: var(--text-2); }
.ct-scale span { flex: 1; padding: 0; min-width: 0; }

/* the phone: the published form, in its own theme */
.bw-side { display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: 16px; min-height: 0; padding: 24px 24px 16px; border-inline-start: 1px solid var(--line); }
.ph { position: relative; justify-self: center; width: 276px; min-height: 340px; border-radius: 36px; background: #2b2b2b; box-shadow: inset 0 0 0 1px #4a4a4a; overflow: clip; }
.ph-in { position: absolute; inset: 6px; border-radius: 30px; background: var(--fw-bg, #fafafa); color: var(--fw-tx, #111); font-family: var(--fw-font); overflow: clip; transition: background-color 240ms var(--ease), color 240ms var(--ease); }
.ph-cover { display: block; width: 100%; height: 84px !important; object-fit: cover; object-position: 76% 47%; }
.ph-t { padding: 16px 16px 0; font: var(--fw-w, 500) 1.25rem/1.15 var(--fw-font); letter-spacing: -.02em; }
.ph-qs { display: grid; gap: 12px; padding: 12px 16px 16px; }
.ph-q { display: grid; gap: 8px; }
.ph-q p { display: grid; grid-template-columns: auto 1fr; gap: 8px; font-size: .875rem; font-weight: 500; line-height: 1.3; }
.ph-q p b { font: 500 .6875rem/1.7 var(--font-mono); opacity: .6; }
.ph-q p i { font-style: normal; color: var(--fw-pr); margin-inline-start: 4px; }
.ph .ct { color: color-mix(in oklab, var(--fw-tx) 62%, var(--fw-bg)); font-size: .8125rem; }
.ph .ct-stars .icon { width: 24px; height: 24px; color: var(--fw-pr); }
.ph .ct-opts span, .ph .ct-field, .ph .ct-pair span, .ph .ct-scale span { border-radius: var(--fw-r); background: var(--fw-sf); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--fw-tx) 22%, var(--fw-sf)); color: color-mix(in oklab, var(--fw-tx) 80%, var(--fw-sf)); min-height: 34px; transition: background-color 240ms var(--ease), border-radius 240ms var(--ease); }
.ph .ct-opts i { box-shadow: inset 0 0 0 1.5px var(--fw-pr); }
.ph .ct-opts { gap: 6px; }
.bw-themes { display: flex; justify-content: center; gap: 4px; }
.bw-themes button { display: grid; justify-items: center; gap: 6px; min-width: 60px; white-space: nowrap; min-height: 52px; padding: 4px 2px; border: 0; border-radius: 10px; background: none; color: var(--text-2); font: 500 .75rem/1.1 var(--font-sans); cursor: pointer; }
.bw-themes i { width: 24px; height: 24px; border-radius: 50%; background: radial-gradient(circle at 50%, var(--b) 0 5px, var(--a) 5.5px); box-shadow: 0 0 0 1px var(--line-2); transition: box-shadow 160ms var(--ease); }
.bw-themes [aria-pressed='true'] { color: var(--text); }
.bw-themes [aria-pressed='true'] i { box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--text); }

.bw-rail { display: flex; gap: 2px; margin: 0; padding: 0; border-top: 1px solid var(--line); list-style: none; }
.bw-rail li { flex: var(--n, 4) 1 124px; display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 20px; color: var(--text-2); font-size: .875rem; white-space: nowrap; box-shadow: inset -1px 0 0 var(--line); }
.bw-rail li:last-child { box-shadow: none; }
.bw-rail b { font: 500 .8125rem/1 var(--font-mono); }
.bw-rail .is-live { color: var(--text); }
.bw-rail .is-live::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.bw-rail .is-draft { flex: 0 1 172px; color: var(--text); background: repeating-linear-gradient(-45deg, var(--panel-2) 0 6px, transparent 6px 12px); }
@media (hover: hover) and (pointer: fine) {
  .bw-list button:hover, .bw-add summary:hover { background: var(--panel-2); color: var(--text); }
  .bw-pop button:hover { background: var(--panel); }
  .bw-card:not(.is-on):hover { box-shadow: 0 0 0 1px var(--muted); }
  .bw-in:hover { border-color: var(--line-2); }
  .bw-themes button:hover { color: var(--text); }
}
@media (max-width: 1099px) { .bw-tabs { display: none; } .bw-bar { grid-template-columns: auto auto minmax(0, 1fr) auto; } .bw-body { grid-template-columns: 188px minmax(0, 1fr) 308px; } .bw-side { padding: 20px 12px 16px; } .bw-themes { gap: 0; } .bw-themes button { min-width: 56px; } .bw-cards { width: calc(100% - 32px); margin: 16px auto; } }
@media (max-width: 899px) {
  .bw-body { grid-template-columns: minmax(0, 1fr) 308px; }
  .bw-outline { display: none; }
}
@media (max-width: 680px) {
  .bw-bar { grid-template-columns: minmax(0, 1fr) auto; row-gap: 0; padding: 8px 12px; }
  .bw-live { justify-self: end; } .bw-saved { order: 3; } .bw-pub { order: 4; }
  .bw-body { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .bw-canvas { height: 320px; }
  .bw-cards { width: calc(100% - 24px); margin-block: 12px; }
  .bw-side { padding: 24px 12px 16px; border: 0; border-top: 1px solid var(--line); }
  .ph { height: 380px; }
  .bw-themes button { min-width: 0; flex: 1; }
  .bw-rail { flex-wrap: wrap; gap: 0; }
  .bw-rail li { flex: 1 1 50%; padding: 0 12px; }
}

/* ───────── 3. Question types: one ruled board of working controls ───────── */
.qb-count { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; color: var(--text-2); font-size: 1rem; }
.qb-count b { color: var(--text); font: 500 1rem/1 var(--font-mono); }
.qb { position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: minmax(104px, 1fr); grid-auto-flow: dense; gap: 1px; border-radius: 16px; overflow: clip; background: var(--line); box-shadow: 0 0 0 1px var(--line); }
.qb-bar { position: absolute; z-index: 1; inset: 0 0 auto; height: 3px; pointer-events: none; }
.qb-bar i { display: block; height: 100%; background: var(--accent); transform: scaleX(calc(var(--done, 0) / var(--of))); transform-origin: left; transition: transform 320ms var(--ease); }
.qb-c { grid-column: span var(--s); display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 8px; min-width: 0; margin: 0; padding: 14px 16px; border: 0; background: var(--panel); transition: background-color 160ms var(--ease); }
.qb-c > :last-child { align-self: end; }
.qb-l { display: flex; align-items: center; gap: 8px; min-height: 18px; color: var(--text-2); font-size: .8125rem; }
.qb-l .icon { width: 14px; height: 14px; color: var(--muted); }
.qb-l em { padding: 2px 6px; border-radius: 6px; background: var(--panel-2); color: var(--text-2); font: 500 .6875rem/1.2 var(--font-sans); }
.qb-l .qb-ok { margin-inline-start: auto; color: var(--text); opacity: 0; scale: .6; transition: opacity 160ms var(--ease), scale 220ms var(--ease); }
.qb-c.is-done .qb-ok { opacity: 1; scale: 1; }
.qb-c:focus-within { background: color-mix(in oklab, var(--panel) 60%, var(--panel-2)); }
.qb-in { width: 100%; min-width: 0; min-height: 40px; padding: 0; border: 0; border-bottom: 1px solid var(--line-2); border-radius: 0; background: none; color: var(--text); font: 400 1rem/1.3 var(--font-sans); resize: none; transition: border-color 160ms var(--ease); }
textarea.qb-in { padding-top: 4px; }
select.qb-in { cursor: pointer; }
select.qb-in option { background: var(--panel); color: var(--text); }
.qb-in::placeholder { color: var(--muted); opacity: 1; }
.qb-in[type='date']:invalid, .qb-in[type='date'], .qb-in[type='time'] { font-family: var(--font-mono); font-size: .9375rem; }
body.site .qb-in:focus { outline: 0; border-color: var(--accent); }
.qb-opts { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.qb-opts label, .qb-seg label { position: relative; display: inline-flex; align-items: center; gap: 8px; min-height: 32px; cursor: pointer; }
.qb-opts input, .qb-grid input { appearance: none; flex: none; width: 18px; height: 18px; margin: 0; border: 1.5px solid var(--muted); border-radius: 50%; background: none; cursor: pointer; transition: border-color 140ms var(--ease), box-shadow 140ms var(--ease), background-color 140ms var(--ease); }
.qb-opts [type='checkbox'], .qb-grid [type='checkbox'] { border-radius: 5px; }
.qb-opts input:checked, .qb-grid input:checked { border-color: var(--text); background: var(--text); box-shadow: inset 0 0 0 4px var(--panel); }
.qb-seg { display: flex; gap: 4px; }
.qb-seg label { flex: 1 1 0; min-width: 0; }
.qb-seg input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.qb-seg span { flex: 1; display: grid; place-items: center; min-height: 36px; border-radius: 8px; background: var(--panel-2); color: var(--text-2); font: 500 .875rem/1 var(--font-sans); transition: background-color 140ms var(--ease), color 140ms var(--ease), scale 120ms var(--ease); }
.qb-c--scale .qb-seg span, .qb-c--nps .qb-seg span { font-family: var(--font-mono); font-size: .8125rem; }
.qb-seg input:checked + span { background: var(--text); color: var(--bg); }
.qb-seg label:active span { scale: .95; }
.qb-seg input:focus-visible + span, .qb-stars input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.qb-stars { display: flex; }
.qb-stars label { position: relative; flex: 1; display: grid; place-items: center; min-height: 36px; cursor: pointer; }
.qb-stars input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.qb-stars span { width: 24px; height: 24px; font-size: 0; background: color-mix(in oklab, var(--muted) 70%, var(--panel)); clip-path: polygon(50% 4%, 63% 36%, 97% 38%, 71% 60%, 80% 94%, 50% 75%, 20% 94%, 29% 60%, 3% 38%, 37% 36%); transition: background-color 120ms linear, scale 160ms var(--ease); }
.qb-stars label:has(input:checked) span, .qb-stars label:has(~ label input:checked) span { background: var(--text); }
.qb-c--slider { position: relative; }
.qb-range { --knob-ring: var(--panel); align-self: end; }
.qb-out { position: absolute; right: 16px; top: 14px; font: 500 .8125rem/18px var(--font-mono); }
.qb-c--slider .qb-ok { display: none; }
.qb-grid { width: 100%; border-collapse: collapse; color: var(--text-2); font-size: .8125rem; }
.qb-grid th { padding: 0; font-weight: 400; text-align: center; } .qb-grid tbody th { text-align: start; color: var(--text); }
.qb-grid td { padding: 2px 0; text-align: center; } .qb-grid td:first-child, .qb-grid tbody th { width: 38%; }
.qb-grid label { display: inline-grid; place-items: center; min-width: 28px; min-height: 24px; cursor: pointer; }
.qb-file { display: inline-flex; align-items: center; justify-content: center; min-height: 36px; border-radius: 8px; border: 1px dashed var(--muted); color: var(--text-2); font-size: .875rem; cursor: pointer; overflow: hidden; }
.qb-file input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.qb-file span { padding: 0 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qb-file:has(:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.qb-rank { display: flex; gap: 6px; counter-reset: r; }
.qb-rank button { counter-increment: r; flex: 1; display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px; border: 0; border-radius: 8px; background: var(--panel-2); color: var(--text); font: 500 .875rem/1 var(--font-sans); cursor: pointer; }
.qb-rank button::before { content: counter(r); color: var(--muted); font: 500 .75rem/1 var(--font-mono); }
.qb-rank button:active { scale: .97; }
.qb-sign { width: 100%; height: 60px; border-bottom: 1px solid var(--line-2); cursor: crosshair; touch-action: none; }
.qb-two { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; }
@media (hover: hover) and (pointer: fine) {
  .qb-in:hover { border-color: var(--muted); }
  .qb-opts label:hover input, .qb-grid label:hover input { border-color: var(--text); }
  .qb-seg label:hover input:not(:checked) + span { background: var(--line-2); color: var(--text); }
  .qb-stars:hover span { background: var(--text-2); } .qb-stars label:hover ~ label span { background: color-mix(in oklab, var(--muted) 70%, var(--panel)); }
  .qb-stars label:hover span { scale: 1.12; }
  .qb-rank button:hover { background: var(--line-2); }
  .qb-file:hover { color: var(--text); border-color: var(--text); }
}
@media (max-width: 1099px) { .qb { grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: minmax(104px, auto); } .qb-c--short_text, .qb-c--date { --s: 2 !important; } }
@media (max-width: 700px) { .qb { grid-template-columns: repeat(2, minmax(0, 1fr)); } .qb-c { padding: 12px; } .qb-c--date, .qb-c--short_text { --s: 1 !important; } .qb-c--nps .qb-seg { gap: 2px; } }

/* ───────── 4. Logic: the path the answer takes ───────── */
.lg { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px clamp(40px, 5vw, 80px); align-items: start; }
.lg-text { display: grid; gap: 32px; }
.lg-q { display: grid; gap: 8px; min-width: 0; margin: 0; padding: 0; border: 0; }
.lg-q legend { display: flex; gap: 12px; padding: 0 0 16px; font: 500 1.25rem/1.3 var(--font-sans); letter-spacing: -.015em; }
.lg-q legend .tnum, .rm-q legend .tnum, .rm-l .tnum { color: var(--muted); font-size: .8125rem; line-height: 1.9; }
.lg-q label { position: relative; display: grid; cursor: pointer; }
.lg-q input { appearance: none; position: absolute; left: 18px; top: 50%; width: 18px; height: 18px; margin: -9px 0 0; border: 1.5px solid var(--muted); border-radius: 50%; cursor: pointer; transition: border-color 140ms var(--ease), box-shadow 140ms var(--ease); }
.lg-q span:not(.tnum) { display: flex; align-items: center; min-height: 52px; padding: 0 16px 0 50px; border-radius: 12px; background: var(--panel); box-shadow: inset 0 0 0 1px var(--line-2); transition: box-shadow 140ms var(--ease), background-color 140ms var(--ease); }
.lg-q input:checked { z-index: 1; border-color: var(--text); box-shadow: inset 0 0 0 4px var(--panel), inset 0 0 0 9px var(--text); }
.lg-q input:checked + span { box-shadow: inset 0 0 0 2px var(--text); }
.lg-q input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.lg-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; color: var(--text-2); }
.lg-map { position: relative; container-type: inline-size; aspect-ratio: 680 / 620; }
.lg-lines { position: absolute; inset: 0 0 auto; width: 100%; aspect-ratio: 680 / 540; overflow: visible; }
.lg-line { fill: none; stroke: var(--line-2); stroke-width: 2; transition: stroke 200ms linear; }
.lg-dot { fill: var(--accent); offset-rotate: 0deg; offset-distance: 100%; }
.lg-n { position: absolute; left: calc(var(--x) / 680 * 100%); top: calc(var(--y) / 620 * 100%); display: grid; gap: 4px; align-content: center; width: 27%; min-height: calc(84 / 680 * 100cqw); padding: 0 16px; border-radius: 12px; border: 1px dashed var(--line-2); background: var(--bg); color: var(--muted); font-size: clamp(.8125rem, 2.2cqw, .9375rem); font-weight: 500; line-height: 1.25; transition: background-color 240ms var(--ease), color 240ms var(--ease), border-color 240ms var(--ease); }
.lg-n small { font-size: .8125rem; font-weight: 400; }
.lg-n--start, .lg:has([data-lg='0']:checked) .lg-n--0, .lg:has([data-lg='1']:checked) .lg-n--1, .lg:has([data-lg='2']:checked) .lg-n--2 { border: 1px solid var(--sheet); background: var(--sheet); color: var(--sheet-text); }
.lg-n--start small, .lg:has([data-lg='0']:checked) .lg-n--0 small, .lg:has([data-lg='1']:checked) .lg-n--1 small, .lg:has([data-lg='2']:checked) .lg-n--2 small { color: var(--sheet-muted); }
.lg:has([data-lg='0']:checked) .lg-line--0, .lg:has([data-lg='1']:checked) .lg-line--1, .lg:has([data-lg='2']:checked) .lg-line--2 { stroke: var(--accent); }
.lg-rule { position: absolute; left: 0; right: 0; bottom: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; min-height: 64px; padding: 12px 16px; border-radius: 12px; background: var(--panel); color: var(--text-2); font-size: clamp(.8125rem, 2.3cqw, .9375rem); opacity: 0; visibility: hidden; transition: opacity 200ms var(--ease); }
.lg-rule b { color: var(--muted); font: 500 .8125rem/1 var(--font-mono); }
.lg-rule i { font-style: normal; }
.lg-rule em { padding: 6px 10px; border-radius: 8px; background: var(--panel-2); color: var(--text); font-style: normal; font-weight: 500; }
.lg:has([data-lg='0']:checked) .lg-rule--0, .lg:has([data-lg='1']:checked) .lg-rule--1, .lg:has([data-lg='2']:checked) .lg-rule--2 { opacity: 1; visibility: visible; }
@media (hover: hover) and (pointer: fine) { .lg-q label:hover span:not(.tnum) { background: var(--panel-2); } }
@media (max-width: 959px) { .lg { grid-template-columns: minmax(0, 1fr); } .lg-map { width: 100%; max-width: 680px; } }
@media (max-width: 560px) { .lg-map { aspect-ratio: 680 / 820; } .lg-n { padding: 0 8px; border-radius: 8px; font-size: .8125rem; line-height: 1.15; top: calc(var(--y) / 820 * 100%); } .lg-n small { display: none; } .lg-rule { flex-wrap: wrap; } }

/* ───────── 5. Save and resume: the same answers on two screens ───────── */
.rm { position: relative; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0 24px; min-height: 480px; }
.rm-win { grid-column: 3 / -1; grid-row: 1; display: grid; grid-template-rows: auto minmax(0, 1fr); min-height: 0; border-radius: 16px; background: #e9e9e9; box-shadow: 0 0 0 1px var(--line-2); color: #111; overflow: clip; color-scheme: light; }
.rm-chrome { display: flex; gap: 8px; align-items: center; min-height: 44px; padding: 0 20px; background: #dcdcdc; } .rm-chrome span { width: 10px; height: 10px; border-radius: 50%; background: #b6b6b6; }
.rm-page { display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 24px; min-height: 0; padding: 24px 32px 0 25%; }
.rm-hi { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 4px 24px; min-height: 44px; padding: 8px 16px; border-radius: 12px; background: #fff; font-size: .9375rem; } .rm-hi > span:first-child { display: inline-flex; align-items: center; gap: 10px; } .rm-hi .icon { width: 18px; height: 18px; } .rm-hi .tnum { color: #5a5a5a; font-size: .8125rem; }
.rm-sheet { position: relative; padding: 32px clamp(24px, 4vw, 56px) 0; border-radius: 20px 20px 0 0; background: #fff; overflow: clip; }
.rm-h { font: 500 1.75rem/1.15 var(--font-sans); letter-spacing: -.025em; } .rm-sheet .rm-pg { margin-top: 4px; }
.rm-pg { color: #5a5a5a; font-size: .875rem; }
.rm-bar { display: block; height: 3px; background: #e2e2e2; } .rm-bar i { display: block; width: 50%; height: 100%; background: #e2470f; } .rm-sheet .rm-bar { position: absolute; inset: 0 0 auto; }
.rm-q { display: grid; gap: 8px; min-width: 0; margin: 24px 0 0; padding: 0; border: 0; } .rm-q legend, .rm-l { display: flex; gap: 10px; padding: 0 0 8px; font: 500 1.0625rem/1.3 var(--font-sans); }
.rm-q label { position: relative; display: grid; cursor: pointer; } .rm-q label span { display: flex; align-items: center; min-height: 44px; padding: 0 14px 0 44px; border-radius: 10px; box-shadow: inset 0 0 0 1px #c9c9c9; font-size: .9375rem; transition: box-shadow 140ms var(--ease); }
.rm-q input[type='radio'] { appearance: none; position: absolute; left: 15px; top: 50%; width: 16px; height: 16px; margin: -8px 0 0; border: 1.5px solid #7a7a7a; border-radius: 50%; cursor: pointer; transition: box-shadow 140ms var(--ease); }
.rm-q input[type='radio']:checked { border-color: #e2470f; box-shadow: inset 0 0 0 3.5px #fff, inset 0 0 0 8px #e2470f; } .rm-q input[type='radio']:checked + span { box-shadow: inset 0 0 0 2px #111; }
.rm-q input[type='radio']:focus-visible + span { outline: 2px solid #e2470f; outline-offset: 2px; }
.rm-t input { min-height: 44px; padding: 0 14px; border: 0; border-radius: 10px; background: none; box-shadow: inset 0 0 0 1px #c9c9c9; color: #111; font: 400 1rem/1.3 var(--font-sans); } body.site .rm-t input:focus { outline: 0; box-shadow: inset 0 0 0 2px #e2470f; }
.rm-sheet .rm-q legend, .rm-sheet .rm-l { font-size: 1.125rem; }
.rm-sheet fieldset.rm-q { grid-template-columns: repeat(3, minmax(0, 1fr)); } .rm-sheet fieldset.rm-q legend { grid-column: 1 / -1; }
.rm-phone { grid-column: 1 / 5; grid-row: 1; z-index: 1; align-self: end; justify-self: start; width: 100%; max-width: 324px; margin-bottom: -24px; padding: 8px; border-radius: 44px; background: #2b2b2b; box-shadow: inset 0 0 0 1px #4a4a4a, 0 16px 32px -16px rgb(0 0 0 / .28); color-scheme: light; }
.rm-screen { padding: 16px 18px 20px; border-radius: 36px; background: #fafafa; color: #111; }
.rm-top { display: flex; justify-content: space-between; padding: 0 4px 12px; font-size: .8125rem; }
.rm-phone .rm-q { gap: 6px; margin-top: 16px; } .rm-phone .rm-q label span { min-height: 44px; background: #fff; } .rm-phone .rm-t input { background: #fff; width: 100%; min-width: 0; }
.rm-save { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; margin-top: 16px; border-radius: 10px; background: #111; color: #f4f4f4; font-size: .9375rem; font-weight: 500; } .rm-save .icon { width: 16px; height: 16px; }
.rm-page .rm-q .rm-l, .rm-page .rm-q span.tnum, .rm-q span.rm-l, .rm-q legend span { box-shadow: none !important; min-height: 0 !important; padding-inline: 0 !important; }
.rm-l .tnum, .rm-q legend .tnum { color: #6b6b6b; }
@media (hover: hover) and (pointer: fine) { .rm-q label:hover input[type='radio']:not(:checked) + span { box-shadow: inset 0 0 0 1px #7a7a7a; } }
@media (max-width: 959px) { .rm { grid-template-columns: minmax(0, 1fr); gap: 16px; } .rm-phone, .rm-win { grid-column: 1; grid-row: auto; } .rm-phone { max-width: 324px; justify-self: center; margin: 0; } .rm-page { padding: 16px 16px 0; } .rm-sheet { padding-bottom: 32px; } .rm-sheet fieldset.rm-q { grid-template-columns: minmax(0, 1fr); } }

/* ───────── 6. Results: the same chairs, sorted by what people said ───────── */
.rv { display: grid; gap: 24px; justify-items: start; }
.rv-pick.segmented button { gap: 0; } .rv-pick button > span { white-space: pre; }
@media (max-width: 374px) { .rv-pick button > span { display: none; } }
.rv-say { max-width: 60rem; min-height: 2.5em; font: 400 clamp(1.375rem, .9rem + 1.5vw, 2rem)/1.25 var(--font-sans); letter-spacing: -.02em; color: var(--text-2); text-wrap: pretty; } .rv-say b { color: var(--text); font-weight: 500; }
.rv-rows { display: grid; width: 100%; margin: 0; border-top: 1px solid var(--line); }
.rv-rows > div { display: grid; grid-template-columns: 56px minmax(0, 1fr); align-items: center; min-height: 60px; border-bottom: 1px solid var(--line); }
.rv-rows dt { display: inline-flex; align-items: center; gap: 6px; font: 500 1rem/1 var(--font-mono); } .rv-rows dt .icon { width: 14px; height: 14px; fill: var(--muted); stroke-width: 0; }
.rv-rows dd { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0; min-width: 0; } .rv-rows dd b { flex: none; font: 500 1rem/1 var(--font-mono); }
.rv-chairs { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.rv-c { width: 40px; height: 40px; fill: var(--text); stroke: var(--text); stroke-width: 1.4; stroke-linejoin: round; stroke-linecap: round; transition: fill 200ms linear, stroke 200ms linear, opacity 200ms linear; }
.rv-c.is-new { fill: var(--accent); stroke: var(--accent); }
.rv:not([data-v='0']) .rv-c { fill: transparent; stroke: var(--muted); opacity: .55; }
.rv[data-v='1'] .rv-c[data-v='1'], .rv[data-v='2'] .rv-c[data-v='2'], .rv[data-v='3'] .rv-c[data-v='3'] { fill: var(--text); stroke: var(--text); opacity: 1; }
.rv[data-v='3'] .rv-c.is-new { fill: var(--accent); stroke: var(--accent); }
@media (max-width: 700px) { .rv-c { width: 22px; height: 22px; } .rv-chairs { gap: 4px; } .rv-rows > div { grid-template-columns: 44px minmax(0, 1fr); padding-block: 8px; } }

/* ───────── 7. Beside the other tools: our column is the one orange area ───────── */
.vs-date { color: var(--text-2); }
.vs { width: 100%; margin-top: 72px; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.vs th, .vs td { padding: 20px 24px 20px 0; border-top: 1px solid var(--line-2); vertical-align: top; text-align: start; line-height: 1.45; }
.vs tbody th { font-weight: 500; } .vs tbody td:not(.us) { color: var(--text-2); }
.vs thead th, .vs thead td { padding-block: 0 20px; border: 0; font: 500 1.125rem/1.2 var(--font-sans); letter-spacing: -.01em; }
.vs tr > :first-child { width: 17%; } .vs tr > :nth-child(2) { width: 25%; }
.vs tr > .us + td, .vs tr > .us + th { padding-inline-start: 32px; width: 21.5%; }
.vs .us { position: relative; padding-inline: 24px; background: var(--accent); color: var(--accent-ink); border-color: color-mix(in oklab, var(--accent-ink) 24%, var(--accent)); font-weight: 500; }
.vs thead .us::before, .vs tbody tr:last-child .us::after { content: ''; position: absolute; left: 0; right: 0; height: 24px; background: var(--accent); }
.vs thead .us::before { bottom: 100%; border-radius: 16px 16px 0 0; } .vs tbody tr:last-child .us::after { top: 100%; border-radius: 0 0 16px 16px; }
.vs .us .vd { background: var(--accent-ink); color: var(--accent); }
@media (max-width: 959px) {
  .vs { display: block; margin-top: 32px; } .vs thead { display: none; } .vs tbody, .vs tr { display: block; }
  .vs tr + tr { margin-top: 32px; }
  .vs tbody th, .vs tbody td { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px; padding: 14px 0 !important; width: auto !important; }
  .vs tbody th { grid-template-columns: 1fr; border: 0; font-size: 1.25rem; letter-spacing: -.015em; }
  .vs tbody td::before { content: attr(data-l); font-weight: 500; color: var(--text); }
  .vs .us { padding: 14px 16px !important; border: 0; border-radius: 12px; } .vs tbody .us::before { color: var(--accent-ink); } .vs tbody tr:last-child .us::after { display: none; }
  .vs .us + td { border-top: 0; }
}

/* ───────── 9. Questions, all answered ───────── */
.qa { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px 48px; margin-top: 40px; }
.qa article { padding-top: 16px; border-top: 1px solid var(--line-2); }
.qa h3 { font: 500 1.0625rem/1.35 var(--font-sans); letter-spacing: -.01em; text-wrap: balance; }
.qa-a { margin-top: 6px; color: var(--text-2); line-height: 1.45; text-wrap: pretty; } .qa-a a { color: var(--text); text-decoration: underline; text-decoration-color: var(--link-line); text-underline-offset: 3px; } .qa-a strong { font-weight: 500; color: var(--text); }
@media (max-width: 1099px) { .qa { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) { .qa { grid-template-columns: minmax(0, 1fr); gap: 24px; } }

/* ───────── 10. Close: the name, and one chair at the end of it ───────── */
.cl { overflow: clip; }
.cl-word { position: relative; margin-top: clamp(96px, 13vw, 200px); padding-bottom: .12em; font: 500 min(18.2vw, 236px)/.78 var(--font-sans); letter-spacing: -.055em; color: var(--text); white-space: nowrap; }
.cl-word > span { display: block; margin-inline-start: -.04em; }
.cl-word picture { position: absolute; left: 4.02em; bottom: .02em; height: 1.34em; aspect-ratio: 1560 / 1170; pointer-events: none; }
.cl-word img { display: block; width: 100%; height: 100%; max-width: none; }
@media (min-width: 1200px) and (min-height: 780px) { .cl.hm-sec { min-height: 0; padding-bottom: 96px; } }
