/* DID or NEVER — v2 "rings"
   One night-black ground, two poles (ember = did, ice = never), bone for everything human.
   Anton says the verdicts. Instrument Serif says the experiences. */

@font-face { font-family: "Anton"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/fonts/anton-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Anton"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/fonts/anton-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Instrument Serif"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/fonts/is-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Instrument Serif"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/fonts/is-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-weight: 400; font-display: swap;
  src: url(/fonts/isi-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-weight: 400; font-display: swap;
  src: url(/fonts/isi-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --night: #0d0c0b;
  --night-2: #181614;
  --line: #2c2925;
  --bone: #f2ece1;
  --soft: rgba(242, 236, 225, .74);
  --dim: #8d857a;
  --did: #ff5a36;
  --never: #8fb3ff;

  --display: "Anton", "Impact", "Arial Narrow Bold", sans-serif;
  --serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --ui: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  --ease: cubic-bezier(.2, .8, .2, 1);
  --gut: 20px;
  --col: 540px;
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; background: var(--night); }
body {
  color: var(--bone);
  font: 17px/1.45 var(--ui);
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
/* film grain: one tiny inline svg, fixed, never repainted */
body::after {
  content: ""; position: fixed; inset: -50%; pointer-events: none; z-index: 50; opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { cursor: default; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--bone); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }
.nojs { padding: 24px; font: 20px var(--serif); }

#app { min-height: 100svh; }
.screen {
  min-height: 100svh;
  max-width: var(--col); margin: 0 auto;
  padding: calc(env(safe-area-inset-top, 0px) + 10px) var(--gut) calc(env(safe-area-inset-bottom, 0px) + 28px);
  display: flex; flex-direction: column; gap: 22px;
}
.screen.enter { animation: enter .45s var(--ease) both; }
@keyframes enter { from { opacity: 0; transform: translateY(8px); } }
.grow { flex: 1; }
.center { text-align: center; }

/* ---------- type ---------- */
.display { font: 400 clamp(42px, 11.5vw, 68px)/.98 var(--serif); letter-spacing: -.02em; margin: 0; text-wrap: balance; }
.display.sm { font-size: clamp(30px, 8vw, 42px); line-height: 1.04; }
.who {
  font: 400 clamp(68px, 23vw, 156px)/.86 var(--display); text-transform: uppercase; letter-spacing: -.005em;
  margin: 0; overflow-wrap: anywhere;
}
.body { font-size: 17px; color: var(--soft); margin: 0; max-width: 34ch; text-wrap: pretty; }
.body.lead { font: italic 400 26px/1.15 var(--serif); color: var(--bone); max-width: none; }
.label { font: 400 12px/1 var(--display); letter-spacing: .2em; text-transform: uppercase; color: var(--dim); margin: 0 0 12px; }
.meta { font-size: 14px; color: var(--dim); margin: 0; }
.kicker { font: 400 13px/1.3 var(--display); letter-spacing: .16em; text-transform: uppercase; color: var(--did); margin: 0; }

/* ---------- top bar & wordmark ---------- */
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.bar-r { display: flex; align-items: center; gap: 4px; }
.wm { display: inline-flex; align-items: baseline; gap: 5px; text-decoration: none; padding: 8px 0; }
.wm b { font: 400 19px/1 var(--display); letter-spacing: .03em; font-weight: 400; }
.wm .d { color: var(--did); }
.wm .n { color: var(--never); }
.wm i { font: italic 400 18px/1 var(--serif); color: var(--bone); }
.chip {
  font: 400 12px/1 var(--display); letter-spacing: .14em; text-transform: uppercase;
  border: 1px solid var(--line); border-radius: 999px; padding: 0 13px; min-height: 36px;
  display: inline-flex; align-items: center; gap: 7px; color: var(--bone);
}
.chip.quiet { border-color: transparent; color: var(--dim); }
.pip { width: 7px; height: 7px; border-radius: 50%; background: var(--did); box-shadow: 0 0 10px var(--did); }
.count { font: 400 13px/1 var(--display); letter-spacing: .14em; color: var(--dim); padding: 0 6px; font-variant-numeric: tabular-nums; }

/* ---------- buttons ---------- */
.btn {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  width: 100%; min-height: 58px; padding: 14px 20px;
  font: 400 19px/1 var(--display); letter-spacing: .08em; text-transform: uppercase; text-decoration: none;
  color: var(--bone); border: 1px solid rgba(242, 236, 225, .28); border-radius: 999px;
  transition: transform .12s var(--ease), background .2s, border-color .2s, opacity .2s;
}
.btn:hover:not(:disabled) { border-color: var(--bone); }
.btn:active:not(:disabled) { transform: scale(.98); }
.btn:disabled { opacity: .3; }
.btn.hot { background: var(--did); border-color: var(--did); color: var(--night); }
.btn.hot:hover:not(:disabled) { background: #ff6d4d; }
.btn .sub { font: 400 14px/1.2 var(--ui); letter-spacing: 0; text-transform: none; opacity: .78; }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; }
.actions { display: flex; flex-direction: column; gap: 10px; }
.ghostbtn {
  color: var(--dim); font-size: 15px; min-height: 44px; padding: 0 4px;
  display: inline-flex; align-items: center; gap: 4px; transition: color .15s;
}
.ghostbtn:hover:not(:disabled) { color: var(--bone); }
.ghostbtn.danger:hover { color: var(--did); }

/* ---------- tags: the words, as stamps ---------- */
.tag {
  display: inline-block; font: 400 15px/1 var(--display); letter-spacing: .08em; font-weight: 400;
  padding: 4px 7px 3px; border: 1.5px solid currentColor; border-radius: 5px;
}
.tag.did { color: var(--did); }
.tag.never { color: var(--never); }
.tag.big { font-size: 30px; padding: 6px 10px 4px; border-width: 2px; }
.tag.slam { animation: slam .38s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes slam { from { transform: scale(2.2) rotate(-8deg); opacity: 0; } }

/* ---------- the mark ---------- */
.mark { display: block; width: 100%; height: auto; overflow: visible; }
.ring { fill: none; stroke-linecap: round; transition: stroke .5s, opacity .5s; }
.ring.did { stroke: var(--did); }
.ring.never { stroke: var(--never); }
.ring.empty { stroke: var(--line); }
.ring.sealed { stroke: var(--bone); opacity: .22; }
.ring.match { stroke: var(--bone); }
.ring.ghost { stroke: var(--bone); opacity: .3; stroke-dasharray: 2 5 !important; }
.rg { transform-origin: 100px 100px; }
.rg.new .ring { animation: draw .7s var(--ease) both; }
@keyframes draw { from { stroke-dashoffset: var(--len); } }
.mark.draw .rg .ring { animation: draw 1s var(--ease) both; }
.mark.draw .rg:nth-child(1) .ring { animation-delay: .05s } .mark.draw .rg:nth-child(2) .ring { animation-delay: .12s }
.mark.draw .rg:nth-child(3) .ring { animation-delay: .19s } .mark.draw .rg:nth-child(4) .ring { animation-delay: .26s }
.mark.draw .rg:nth-child(5) .ring { animation-delay: .33s } .mark.draw .rg:nth-child(6) .ring { animation-delay: .40s }
.mark.draw .rg:nth-child(7) .ring { animation-delay: .47s } .mark.draw .rg:nth-child(8) .ring { animation-delay: .54s }
.mark.draw .rg:nth-child(9) .ring { animation-delay: .61s } .mark.draw .rg:nth-child(10) .ring { animation-delay: .68s }

/* ================================================================
   PLAY — the experience hangs between two poles
   ================================================================ */
.screen.play {
  height: 100svh; min-height: 0; max-width: none; overflow: hidden; gap: 0;
  padding-left: 0; padding-right: 0;
  --p: 0;
  --up: clamp(0, var(--p), 1);
  --down: clamp(0, calc(var(--p) * -1), 1);
}
.play .bar, .play .kicker, .play .foot { padding: 0 var(--gut); max-width: 1100px; width: 100%; margin: 0 auto; }
.play .kicker { padding-top: 6px; text-align: center; }
.field {
  flex: 1; position: relative; display: grid; grid-template-rows: 1fr auto 1fr;
  touch-action: none; user-select: none; -webkit-user-select: none; min-height: 0;
}
.field::before, .field::after {
  content: ""; position: absolute; left: 0; right: 0; height: 60%; pointer-events: none; transition: opacity .25s;
}
.field::before { top: 0; background: radial-gradient(70% 90% at 50% 0%, rgba(255, 90, 54, .42), transparent 70%); opacity: var(--up); }
.field::after { bottom: 0; background: radial-gradient(70% 90% at 50% 100%, rgba(143, 179, 255, .36), transparent 70%); opacity: var(--down); }
.dragging .field::before, .dragging .field::after { transition: none; }

.bgmark {
  position: absolute; left: 50%; top: 50%; width: min(118vw, 74svh); translate: -50% -50%;
  opacity: .13; pointer-events: none; z-index: 0;
}
.bgmark .ring.empty { stroke: var(--bone); opacity: .18; }

.pole {
  position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  width: 100%; min-height: 0; color: var(--bone); gap: 12px;
}
.pole.did { justify-content: flex-end; padding-bottom: 2svh; }
.pole.never { justify-content: flex-start; padding-top: 2svh; flex-direction: column-reverse; }
.pole .w {
  position: relative; display: block;
  font: 400 clamp(72px, min(30vw, 21svh), 230px)/.8 var(--display); letter-spacing: .01em;
  color: transparent; -webkit-text-stroke: 1.5px rgba(242, 236, 225, .2);
  transition: -webkit-text-stroke-color .2s, transform .25s var(--ease);
}
.pole .w::after {
  content: attr(data-w); position: absolute; inset: 0; -webkit-text-stroke: 0;
  opacity: 0; transition: opacity .2s;
}
.pole.did .w::after { color: var(--did); opacity: var(--up); }
.pole.never .w::after { color: var(--never); opacity: var(--down); }
.pole.did .w { transform: scale(calc(1 + var(--up) * .07)); }
.pole.never .w { transform: scale(calc(1 + var(--down) * .07)); }
.dragging .pole .w, .dragging .pole .w::after { transition: none; }
.pole .s { font: italic 400 19px/1 var(--serif); color: var(--dim); transition: color .2s; }
.pole:hover .w { -webkit-text-stroke-color: rgba(242, 236, 225, .45); }
.pole.did:hover .s { color: var(--did); }
.pole.never:hover .s { color: var(--never); }
.pole:focus-visible { outline: none; }
.pole:focus-visible .w { -webkit-text-stroke-color: var(--bone); }
.pole.hit .w::after { animation: hit .5s var(--ease); }
@keyframes hit { 0% { opacity: 1; } 100% { opacity: 0; } }
.pole.did.hit .w { animation: kick-up .45s var(--ease); }
.pole.never.hit .w { animation: kick-down .45s var(--ease); }
@keyframes kick-up { 40% { transform: translateY(-6px) scale(1.06); } }
@keyframes kick-down { 40% { transform: translateY(6px) scale(1.06); } }

.stage { position: relative; z-index: 2; padding: 0 var(--gut); display: flex; flex-direction: column; align-items: center; pointer-events: none; }
.qwrap { text-align: center; width: 100%; will-change: transform; }
.qwrap.settle { transition: transform .35s cubic-bezier(.3, 1.4, .5, 1); }
.pre { font: 400 13px/1 var(--display); letter-spacing: .22em; text-transform: uppercase; color: var(--dim); margin: 0 0 12px; }
.q {
  font: 400 clamp(32px, min(9vw, 6.6svh), 72px)/1.02 var(--serif); letter-spacing: -.018em; margin: 0 auto; max-width: 13em;
  text-wrap: balance; text-shadow: 0 2px 30px var(--night);
}
.wd { display: inline-block; white-space: pre; }
.qwrap.enter .wd { animation: word .55s var(--ease) both; animation-delay: calc(var(--i) * 32ms); }
.qwrap.back .wd { animation: word-back .45s var(--ease) both; animation-delay: calc(var(--i) * 20ms); }
@keyframes word { from { opacity: 0; transform: translateY(.4em); filter: blur(8px); } }
@keyframes word-back { from { opacity: 0; transform: translateY(-.4em); filter: blur(8px); } }
.qwrap.go-did { animation: go-did .3s cubic-bezier(.5, 0, .9, .5) forwards; }
.qwrap.go-never { animation: go-never .3s cubic-bezier(.5, 0, .9, .5) forwards; }
.qwrap.go-skip { animation: go-skip .24s ease-in forwards; }
@keyframes go-did { to { transform: translateY(-34svh) scale(.6); opacity: 0; filter: blur(6px); } }
@keyframes go-never { to { transform: translateY(34svh) scale(.6); opacity: 0; filter: blur(6px); } }
@keyframes go-skip { to { transform: translateX(-80vw) rotate(-6deg); opacity: 0; } }
.qwrap.nudge { animation: nudge 3.6s 2.4s var(--ease) infinite; }
@keyframes nudge { 0%, 60%, 100% { transform: none; } 15% { transform: translateY(-14px); } 35% { transform: translateY(12px); } }

.intro { margin: 26px 0 0; max-width: 30ch; text-align: center; color: var(--soft); font-size: 15px; display: flex; flex-direction: column; gap: 12px; animation: enter .6s .5s both; }
.intro .keys { display: none; }
@media (hover: hover) and (pointer: fine) { .intro .keys { display: block; } .intro .gesture:not(.keys) { display: none; } }
.intro .gesture { font: 400 11px/1 var(--display); letter-spacing: .22em; text-transform: uppercase; color: var(--dim); }

.foot { display: flex; justify-content: space-between; align-items: center; min-height: 52px; padding-bottom: 4px !important; }

/* ================================================================
   SEAL — your ten are in
   ================================================================ */
.seal-mark, .owner-mark, .guest-mark { width: min(62vw, 280px); margin: 12px auto 0; }
.seal-form { display: flex; flex-direction: column; gap: 14px; margin-top: auto; }
.name-in {
  width: 100%; font: 400 clamp(36px, 10vw, 52px)/1.1 var(--display); text-transform: uppercase; letter-spacing: .01em;
  background: transparent; border: 0; border-bottom: 2px solid var(--line); border-radius: 0; padding: 4px 0 8px;
  outline: none; caret-color: var(--did); transition: border-color .2s;
}
.name-in:focus { border-bottom-color: var(--bone); }
.name-in::placeholder { color: var(--line); }

/* ================================================================
   SEND & OWNER
   ================================================================ */
.send { display: flex; flex-direction: column; gap: 18px; }
.pv { margin: 0; }
.pv-card {
  display: grid; grid-template-columns: 96px 1fr; gap: 0; overflow: hidden;
  background: var(--night-2); border: 1px solid var(--line); border-radius: 12px;
}
.pv-card img { width: 96px; height: 100%; object-fit: cover; object-position: 8% 50%; display: block; background: #000; }
.pv-t { display: flex; flex-direction: column; gap: 3px; padding: 11px 13px; min-width: 0; }
.pv-t b { font: 600 15px/1.25 var(--ui); }
.pv-t span { font-size: 13px; line-height: 1.35; color: var(--soft); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pv-t small { font-size: 12px; color: var(--dim); }
.trust { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--soft); margin: 0; }
.lock { flex: none; width: 12px; height: 10px; margin-top: 6px; border-radius: 2px; background: var(--bone); position: relative; }
.lock::before { content: ""; position: absolute; left: 2px; top: -6px; width: 8px; height: 8px; border: 1.5px solid var(--bone); border-bottom: 0; border-radius: 5px 5px 0 0; box-sizing: border-box; }
.copyfield { width: 100%; font-size: 16px; padding: 12px; background: var(--night-2); border: 1px solid var(--line); border-radius: 10px; }

.owner-head { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.owner-head .owner-mark { margin: 6px 0 4px; width: min(46vw, 200px); }
.live { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--dim); margin: 0; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); flex: none; }
.dot.on { background: var(--did); animation: pulse 1.8s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 90, 54, .55); } 70%, 100% { box-shadow: 0 0 0 10px rgba(255, 90, 54, 0); } }

details { border-top: 1px solid var(--line); }
summary {
  list-style: none; cursor: pointer; min-height: 56px; display: flex; align-items: center; justify-content: space-between;
  font: 400 13px/1 var(--display); letter-spacing: .18em; text-transform: uppercase; color: var(--soft);
}
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font: 400 22px/1 var(--ui); color: var(--dim); transition: transform .2s; }
details[open] summary::after { transform: rotate(45deg); }
details > :not(summary) { padding-bottom: 22px; }
.yours-in { display: grid; gap: 18px; }
.small-mark { width: 140px; }
.replies { display: flex; flex-direction: column; gap: 8px; }
.reply {
  display: flex; align-items: center; gap: 12px; padding: 16px; border-radius: 12px; text-decoration: none;
  background: var(--night-2); border: 1px solid var(--did); font: 400 16px/1.2 var(--display); letter-spacing: .06em; text-transform: uppercase;
}
.foot-actions { display: flex; justify-content: center; margin-top: 8px; }

/* ---------- ranked lists ---------- */
.board ol, .list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.board li, .list li { border-top: 1px solid var(--line); }
.board li:last-child, .list li:last-child { border-bottom: 1px solid var(--line); }
.board li > *, .board li:not(:has(button)), .list a {
  display: grid; grid-template-columns: 28px 1fr auto auto; gap: 12px; align-items: baseline; padding: 14px 0; width: 100%; text-align: left; text-decoration: none;
}
.list a { grid-template-columns: 1fr auto; }
.rk { font: 400 14px/1 var(--display); color: var(--dim); }
.nm { font: 400 24px/1.1 var(--display); text-transform: uppercase; letter-spacing: .01em; overflow-wrap: anywhere; }
.sc { font: 400 24px/1 var(--display); font-variant-numeric: tabular-nums; }
.sc small { font-size: 14px; color: var(--dim); }
.chev { color: var(--dim); }
.board li.me .nm, .board li.me .sc { color: var(--did); }
.rowbtn:hover .chev { color: var(--bone); }

/* ================================================================
   REVEAL — ring by ring
   ================================================================ */
.screen.reveal { gap: 16px; overflow: hidden; height: 100svh; }
.reveal .kicker { text-align: center; color: var(--dim); }
.rv-mark { position: relative; width: min(84vw, 46svh, 400px); margin: 0 auto; }
.rv-tally { position: absolute; inset: 0; display: grid; place-items: center; font: 400 clamp(22px, 6vw, 32px)/1 var(--display); pointer-events: none; }
.rv-tally > * { grid-area: 1 / 1; }
.rv-tally small { font-size: 12px; color: var(--dim); translate: 0 1.4em; }
.rg.guessing .ring { stroke: var(--bone); opacity: .16; }
.rg.focus .ring { opacity: .55; animation: breathe 1s ease-in-out infinite alternate; }
@keyframes breathe { to { opacity: .9; } }
.rg.miss .ring.truth { animation: crack .5s var(--ease); }
@keyframes crack { 20% { stroke-width: 9; } }
.rv-line { display: flex; flex-direction: column; gap: 16px; text-align: center; align-items: center; min-height: 190px; }
.rq { font: 400 clamp(26px, 7vw, 36px)/1.08 var(--serif); margin: 0; max-width: 16em; text-wrap: balance; }
.rv-row { display: flex; gap: 28px; justify-content: center; }
.rv-row > div { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 90px; }
.rv-row small { font: 400 11px/1 var(--display); letter-spacing: .2em; text-transform: uppercase; color: var(--dim); }
.rv-row .tag { font-size: 26px; padding: 6px 10px 4px; border-width: 2px; }
.rv-you .tag { opacity: .6; }
.reveal[data-state="miss"] .rv-them .tag { box-shadow: 0 0 40px -6px currentColor; }
.reveal[data-state="miss"] .rv-mark { animation: shake .35s; }
@keyframes shake { 25% { transform: translateX(5px); } 50% { transform: translateX(-4px); } 75% { transform: translateX(2px); } }
.rv-skip { align-self: center; margin-top: auto; }

/* ================================================================
   RESULT
   ================================================================ */
.result { gap: 34px; }
.hero { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; }
.hero-mark { width: min(80vw, 380px); margin-bottom: 8px; }
.score { margin: 0; display: flex; align-items: baseline; gap: 4px; }
.score b { font: 400 clamp(96px, 30vw, 150px)/.85 var(--display); font-weight: 400; }
.score span { font: 400 32px/1 var(--display); color: var(--dim); }
.verdict { font: italic 400 clamp(30px, 8vw, 42px)/1.05 var(--serif); margin: 6px 0 0; text-wrap: balance; max-width: 14em; }
.legend { font-size: 13px; color: var(--dim); margin: 8px 0 0; max-width: 32ch; }
.legend .k { display: inline-block; vertical-align: middle; width: 16px; height: 4px; border-radius: 2px; background: var(--bone); }
.legend .k.c { background: linear-gradient(90deg, var(--did) 50%, var(--never) 50%); }
.surprise { border-top: 1px solid var(--line); padding-top: 22px; display: flex; flex-direction: column; gap: 14px; }
.sq { font: 400 clamp(28px, 7.4vw, 38px)/1.06 var(--serif); margin: 0; text-wrap: balance; }
.st { display: flex; align-items: center; gap: 14px; margin: 0; }
.st > span:not(.arrow) { display: flex; flex-direction: column; gap: 6px; }
.st small { font: 400 11px/1 var(--display); letter-spacing: .2em; text-transform: uppercase; color: var(--dim); }
.st .arrow { color: var(--dim); font-size: 22px; padding-top: 16px; }
.stat { font-size: 14px; color: var(--dim); margin: 0; }
.lines { list-style: none; margin: 0; padding: 0; }
.ln { display: flex; flex-direction: column; gap: 8px; padding: 14px 0; border-top: 1px solid var(--line); }
.ln:last-child { border-bottom: 1px solid var(--line); }
.lq { font: 400 21px/1.15 var(--serif); }
.lt { display: flex; align-items: center; gap: 8px; }
.lt small { font: 400 10px/1 var(--display); letter-spacing: .18em; text-transform: uppercase; color: var(--dim); }
.lt small:nth-of-type(2) { margin-left: 8px; }
.ln.ok .tag { opacity: .7; }

/* ---------- misc ---------- */
.loading, .locking, .missing { justify-content: center; }
.spinner { width: 36px; height: 36px; margin: 0 auto; border-radius: 50%; border: 1.5px solid var(--line); border-top-color: var(--bone); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.missing .who { color: var(--line); }

.guest .guest-mark { width: min(52vw, 230px); margin: 8px 0 0; }
.guest-mark .rg:nth-child(odd) { animation: turn 60s linear infinite; }
.guest-mark .rg:nth-child(even) { animation: turn 44s linear infinite reverse; }
@keyframes turn { to { transform: rotate(360deg); } }

.toast {
  position: fixed; left: 50%; bottom: calc(env(safe-area-inset-bottom, 0px) + 24px); z-index: 60;
  transform: translate(-50%, 20px); opacity: 0; transition: .25s var(--ease);
  background: var(--bone); color: var(--night); padding: 12px 18px; border-radius: 999px; font-size: 15px;
  pointer-events: none; white-space: nowrap;
}
.toast.show { transform: translate(-50%, 0); opacity: 1; }

/* ---------- larger screens: a poster, not a stretched phone ---------- */
@media (min-width: 760px) {
  :root { --gut: 36px; }
  .screen { padding-top: 22px; }
  .pole .w { -webkit-text-stroke-width: 2px; }
  .bgmark { width: min(78svh, 760px); }
}
@media (max-height: 640px) {
  .pole .w { font-size: clamp(64px, 22vw, 150px); }
  .q { font-size: clamp(28px, 7.4vw, 52px); }
  .intro { margin-top: 14px; }
  .intro > span:first-child { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .qwrap.nudge { animation: none; }
}
