:root {
  --bg: #0a0a0c;
  --card: #141418;
  --card-2: #1c1c22;
  --line: #26262e;
  --text: #f4f4f6;
  --muted: #8e8e9a;
  --accent: #c8ff3d;
  --on-accent: #0a0a0c;
  --accent-soft: rgba(200, 255, 61, 0.12);
  --purple: #9b7bff;
  --purple-soft: rgba(155, 123, 255, 0.16);
  --danger: #ff6b6b;
  --radius: 20px;
  --display: 'Unbounded', 'Plus Jakarta Sans', system-ui, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
button { font-family: inherit; font-size: inherit; color: inherit; cursor: pointer; }
input { font-family: inherit; font-size: 16px; }
.hidden { display: none !important; }

.app { max-width: 460px; margin: 0 auto; min-height: 100%; display: flex; flex-direction: column; }
.view { flex: 1; padding: 20px 16px 104px; }

/* type */
.logo { font-family: var(--display); font-weight: 800; font-size: 20px; letter-spacing: -0.5px; }
.logo span { color: var(--accent); }
h1 { font-family: var(--display); font-size: 26px; font-weight: 700; margin: 0 0 8px; line-height: 1.15; letter-spacing: -0.8px; }
h2 { font-family: var(--display); font-size: 18px; font-weight: 600; margin: 0 0 6px; letter-spacing: -0.3px; }
.muted { color: var(--muted); font-size: 14px; margin: 0; line-height: 1.5; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 12px; }

/* header */
.top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.pill { display: inline-flex; align-items: center; gap: 5px; background: var(--card-2); border: 1px solid var(--line); padding: 6px 12px; border-radius: 99px; font-size: 14px; font-weight: 700; }
.pill i { color: var(--accent); font-size: 16px; }

/* buttons */
.btn { width: 100%; border: none; background: var(--accent); color: var(--on-accent); padding: 16px; border-radius: 99px; font-weight: 800; font-size: 16px; display: flex; align-items: center; justify-content: center; gap: 8px; transition: transform 0.12s; }
.btn:active { transform: scale(0.97); }
.btn.ghost { background: var(--card-2); color: var(--text); border: 1px solid var(--line); font-weight: 600; }
.link { background: none; border: none; color: var(--muted); font-size: 14px; font-weight: 600; padding: 8px; display: inline-flex; align-items: center; gap: 5px; }

/* onboarding */
.onb { min-height: calc(100vh - 140px); display: flex; flex-direction: column; justify-content: center; gap: 24px; text-align: center; }
.onb .big-ico { font-size: 44px; color: var(--on-accent); background: var(--accent); width: 96px; height: 96px; border-radius: 32px; display: flex; align-items: center; justify-content: center; margin: 0 auto; transform: rotate(-6deg); }
.dots { display: flex; gap: 6px; justify-content: center; }
.dots i { width: 8px; height: 8px; border-radius: 99px; background: var(--line); transition: width 0.2s; }
.dots i.on { background: var(--accent); width: 24px; }
.field { text-align: left; display: flex; flex-direction: column; gap: 8px; }
.field label { font-size: 13px; color: var(--muted); font-weight: 600; }
.field input { padding: 15px 16px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); color: var(--text); outline: none; }
.field input:focus { border-color: var(--accent); }
.field input::placeholder { color: #55555f; }
.choices { display: flex; gap: 8px; }
.choice { flex: 1; padding: 13px 8px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); font-weight: 600; font-size: 14px; }
.choice.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.error { color: var(--danger); font-size: 14px; min-height: 18px; margin: 0; }

/* avatars */
.av { width: 48px; height: 48px; border-radius: 50%; overflow: hidden; flex-shrink: 0; display: block; }
.av img { width: 100%; height: 100%; display: block; }
.av.lg { width: 96px; height: 96px; border: 3px solid var(--accent); }
.av.xl { width: 64px; height: 64px; }
.c-coral { background: #ffb4a2; }
.c-teal { background: #8ee6c9; }
.c-blue { background: #9cc8ff; }
.c-amber { background: #ffd88a; }
.c-purple { background: #c9b6ff; }
.c-pink { background: #ffb3d1; }
.c-green { background: #c8f08f; }
.avatar-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.avpick { aspect-ratio: 1; border-radius: 50%; border: 2px solid transparent; padding: 0; overflow: hidden; background: #e4e4ea; transition: transform 0.12s; opacity: 0.85; }
.avpick:nth-child(7n+1) { background: #ffb4a2; } .avpick:nth-child(7n+2) { background: #8ee6c9; } .avpick:nth-child(7n+3) { background: #9cc8ff; } .avpick:nth-child(7n+4) { background: #ffd88a; } .avpick:nth-child(7n+5) { background: #c9b6ff; } .avpick:nth-child(7n+6) { background: #ffb3d1; }
.avpick img { width: 100%; height: 100%; display: block; }
.avpick.on { border: 3px solid var(--accent); background: var(--accent) !important; transform: scale(1.1); opacity: 1; }

/* tags & chips */
.tag-grid, .chips { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { border: 1px solid var(--line); background: var(--card); border-radius: 99px; padding: 9px 13px; font-size: 14px; font-weight: 600; }
.tag.on { border-color: var(--accent); background: var(--accent); color: var(--on-accent); }
.chip { display: inline-block; background: var(--card-2); border: 1px solid var(--line); color: var(--muted); border-radius: 99px; padding: 2px 8px; font-size: 11px; font-weight: 600; }
.chips { justify-content: center; gap: 4px; }

/* poll */
.progress { height: 6px; background: var(--card-2); border-radius: 99px; overflow: hidden; margin: 8px 0 16px; }
.progress div { height: 100%; background: var(--accent); border-radius: 99px; transition: width 0.4s; }
.qcard { background: var(--purple); color: var(--on-accent); border-radius: 28px; padding: 26px 20px 30px; text-align: center; margin-bottom: 16px; animation: pop 0.35s ease; position: relative; }
.qcard.vibe { background: var(--accent); }
.qcard > i { font-size: 36px; display: block; margin-top: 8px; }
.qcard p { margin: 8px 0 0; font-family: var(--display); font-size: 21px; font-weight: 700; line-height: 1.25; letter-spacing: -0.5px; }
.qtype { display: flex; width: fit-content; margin: 0 auto; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; padding: 5px 11px; border-radius: 99px; background: rgba(0, 0, 0, 0.14); }
.qtype i { font-size: 14px; }
.opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.opt { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 10px; display: flex; flex-direction: column; align-items: center; gap: 7px; transition: transform 0.15s, border-color 0.15s, background 0.15s; }
.opt:active { transform: scale(0.95); }
.opt.picked { border-color: var(--accent); background: var(--accent-soft); transform: scale(0.97); }
.oname { font-weight: 700; }
.obio { font-size: 12px; color: var(--muted); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.poll-actions { display: flex; justify-content: center; gap: 16px; margin-top: 10px; }
@keyframes pop { from { transform: scale(0.94) translateY(6px); opacity: 0; } to { transform: none; opacity: 1; } }

/* cards & rows */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.row { display: flex; align-items: center; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 13px 14px; }
.row.new { border-color: var(--accent); }
.row .ico { width: 42px; height: 42px; border-radius: 14px; background: var(--purple-soft); color: var(--purple); display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.row p { margin: 0; }
.grow { flex: 1; min-width: 0; }
.hint-btn { border: 1px solid var(--line); background: var(--card-2); color: var(--text); border-radius: 99px; padding: 7px 11px; font-size: 13px; font-weight: 600; white-space: nowrap; display: inline-flex; gap: 4px; align-items: center; }
.hint-tag { background: var(--accent); color: var(--on-accent); border-radius: 99px; padding: 7px 12px; font-size: 13px; font-weight: 800; white-space: nowrap; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 14px 8px; text-align: center; }
.stat b { display: block; font-family: var(--display); font-size: 22px; }
.stat span { font-size: 12px; color: var(--muted); font-weight: 600; }
.big-emoji { font-size: 34px; color: var(--on-accent); background: var(--accent); width: 72px; height: 72px; border-radius: 24px; display: flex; align-items: center; justify-content: center; margin: 0 auto; }
.share-card { background: var(--purple); color: var(--on-accent); border-radius: 28px; padding: 26px 22px; text-align: center; }
.share-card p { margin: 4px 0; font-weight: 600; }
.share-card .big { font-family: var(--display); font-size: 20px; font-weight: 800; line-height: 1.25; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.two .btn { font-size: 14px; padding: 13px 8px; }

/* people picker */
.person { display: flex; align-items: center; gap: 12px; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; width: 100%; transition: border-color 0.15s; }
.person.on { border-color: var(--accent); background: var(--accent-soft); }
.person .grow { display: flex; flex-direction: column; gap: 4px; }
.person .chips { justify-content: flex-start; }
.person p { margin: 0; }
.pname { font-weight: 700; }
.pbio { font-size: 13px; }
.check { width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--line); display: flex; align-items: center; justify-content: center; color: transparent; flex-shrink: 0; }
.person.on .check { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.new-tag { background: var(--purple-soft); color: var(--purple); font-size: 11px; padding: 2px 8px; border-radius: 99px; font-weight: 700; vertical-align: middle; }
.sticky-cta { position: sticky; bottom: 12px; padding-top: 8px; }
.banner { width: 100%; display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); background: var(--card); border-radius: 16px; padding: 11px 14px; margin-bottom: 10px; font-size: 14px; font-weight: 600; text-align: left; }
.banner > i:first-child { color: var(--accent); font-size: 20px; }
.banner span { flex: 1; }
.banner > i:last-child { color: var(--muted); }

/* tabs */
.tabs { position: fixed; bottom: 12px; left: 50%; transform: translateX(-50%); width: calc(100% - 32px); max-width: 428px; display: flex; background: rgba(28, 28, 34, 0.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid var(--line); border-radius: 99px; padding: 6px; margin-bottom: env(safe-area-inset-bottom); }
.tab { flex: 1; background: none; border: none; display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--muted); padding: 11px 6px; border-radius: 99px; position: relative; transition: background 0.15s, color 0.15s; }
.tab i { font-size: 20px; }
.tab.on { background: var(--accent); color: var(--on-accent); }
.badge { position: absolute; top: 2px; right: 18%; background: var(--purple); color: #fff; font-size: 11px; min-width: 18px; height: 18px; border-radius: 99px; display: flex; align-items: center; justify-content: center; padding: 0 5px; font-weight: 800; }

.toast { position: fixed; top: 16px; left: 50%; transform: translateX(-50%); background: var(--text); color: var(--bg); padding: 12px 18px; border-radius: 99px; font-size: 14px; font-weight: 700; z-index: 10; animation: pop 0.3s; max-width: 90%; text-align: center; }

/* ---------- 4-tab bar: icon only, label on the active tab ---------- */
.tab span { display: none; }
.tab.on span { display: inline; }

/* ---------- poll scope chips ---------- */
.scopes { display: flex; gap: 6px; overflow-x: auto; margin: -4px -16px 14px; padding: 0 16px; scrollbar-width: none; }
.scopes::-webkit-scrollbar { display: none; }
.scope { flex-shrink: 0; border: 1px solid var(--line); background: var(--card); border-radius: 99px; padding: 8px 13px; font-size: 13px; font-weight: 700; display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.scope b { background: var(--purple); color: #fff; border-radius: 99px; padding: 0 6px; font-size: 11px; }
.scope.on { background: var(--text); color: var(--bg); border-color: var(--text); }

/* ---------- feedback card ---------- */
.fb { margin-bottom: 14px; border-color: var(--purple); }
.fb-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.fb-opt { background: var(--card-2); border: 2px solid var(--line); border-radius: 16px; padding: 10px; font-weight: 700; font-size: 14px; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.fb-opt.on { border-color: var(--accent); }
.fb-prev { width: 100%; height: 64px; border-radius: 10px; padding: 8px; display: flex; flex-direction: column; gap: 5px; }
.fb-prev span { height: 18px; border-radius: 6px; }
.fb-prev i { height: 8px; border-radius: 4px; width: 70%; }
.fb-prev.black { background: #0a0a0c; border: 1px solid #333; }
.fb-prev.black span { background: #c8ff3d; } .fb-prev.black i { background: #2a2a32; }
.fb-prev.pink { background: #fff7fa; }
.fb-prev.pink span { background: #d4537e; } .fb-prev.pink i { background: #f1d9e2; }

/* ---------- squads ---------- */
.sq-card { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.sq-card p { margin: 0; }
.sq-ico { width: 46px; height: 46px; border-radius: 15px; background: var(--purple); color: var(--on-accent); display: flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; }
.sq-head { display: flex; align-items: center; gap: 12px; margin: 4px 0 14px; }
.icon-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--card-2); display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.icon-btn.sm { width: 32px; height: 32px; font-size: 16px; border: none; background: transparent; color: var(--muted); }
.seg { display: flex; background: var(--card); border: 1px solid var(--line); border-radius: 99px; padding: 4px; margin-bottom: 14px; }
.segbtn { flex: 1; border: none; background: none; border-radius: 99px; padding: 10px 4px; font-size: 14px; font-weight: 700; color: var(--muted); display: flex; align-items: center; justify-content: center; gap: 5px; }
.segbtn.on { background: var(--accent); color: var(--on-accent); }
.segbtn b { background: var(--purple); color: #fff; border-radius: 99px; padding: 0 6px; font-size: 11px; }
.code-box { font-family: var(--display); font-size: 34px; font-weight: 800; letter-spacing: 6px; text-align: center; background: var(--accent); color: var(--on-accent); border-radius: 18px; padding: 16px; margin-top: 12px; }
.btn.small { width: auto; padding: 10px 16px; font-size: 14px; }
.btn[disabled] { opacity: 0.5; }

/* ---------- tea ---------- */
.prompt-card { background: var(--purple); color: var(--on-accent); border-radius: 24px; padding: 18px; text-align: center; margin-bottom: 12px; }
.prompt-card p { margin: 8px 0 0; font-family: var(--display); font-size: 17px; font-weight: 700; line-height: 1.3; }
.composer { margin-bottom: 14px; display: flex; flex-direction: column; gap: 10px; }
.composer .as { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.composer .as b { color: var(--text); }
.composer textarea { width: 100%; resize: none; background: var(--card-2); border: 1px solid var(--line); color: var(--text); border-radius: 14px; padding: 12px; font: inherit; font-size: 15px; outline: none; }
.composer textarea:focus { border-color: var(--accent); }
.composer-row { display: flex; justify-content: space-between; align-items: center; }
.dav { width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; color: #0a0a0c; flex-shrink: 0; font-family: var(--display); }
.dav.sm { width: 28px; height: 28px; font-size: 10px; }
.post { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.post.is-hidden { border-color: var(--danger); opacity: 0.75; }
.post p { margin: 0; }
.phead { display: flex; align-items: center; gap: 10px; }
.ptext { font-size: 16px; line-height: 1.45; white-space: pre-wrap; word-break: break-word; }
.reacts { display: flex; gap: 6px; flex-wrap: wrap; }
.react { border: 1px solid var(--line); background: var(--card-2); border-radius: 99px; padding: 5px 10px; font-size: 15px; display: inline-flex; align-items: center; gap: 4px; }
.react b { font-size: 12px; }
.react.on { border-color: var(--accent); background: var(--accent-soft); }
.pacts { display: flex; gap: 8px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 10px; }
.pact { border: none; background: none; color: var(--muted); font-size: 13px; font-weight: 700; display: inline-flex; align-items: center; gap: 5px; padding: 4px 6px; }
.pact.accent { color: var(--accent); }
.guess-res { font-size: 13px; font-weight: 700; color: var(--danger); display: inline-flex; align-items: center; gap: 4px; padding: 4px 6px; }
.guess-res.ok { color: var(--accent); }
.replies { display: flex; flex-direction: column; gap: 8px; border-left: 2px solid var(--line); padding-left: 12px; }
.post.reply { background: var(--card-2); padding: 10px 12px; gap: 6px; }
.post.reply .ptext { font-size: 14px; }
.post.reply .react { padding: 3px 8px; font-size: 13px; }
.reply-box { display: flex; gap: 8px; }
.reply-box input { flex: 1; min-width: 0; background: var(--card-2); border: 1px solid var(--line); color: var(--text); border-radius: 99px; padding: 10px 14px; outline: none; }
.reply-box input:focus { border-color: var(--accent); }
.ico.note { background: var(--accent-soft); color: var(--accent); }

/* ---------- bottom sheet ---------- */
.sheet-wrap { position: fixed; inset: 0; z-index: 20; }
.sheet-bg { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.6); animation: fade 0.2s; }
.sheet { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 460px; max-height: 85vh; overflow-y: auto; background: var(--card); border: 1px solid var(--line); border-bottom: none; border-radius: 28px 28px 0 0; padding: 22px 16px calc(22px + env(safe-area-inset-bottom)); animation: up 0.25s ease; }
.guess-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 14px; }
.guess-grid .opt { padding: 12px 6px; font-size: 13px; }
@keyframes up { from { transform: translate(-50%, 40px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
@keyframes fade { from { opacity: 0; } }

/* ================= animations ================= */
#fx-layer { position: fixed; inset: 0; pointer-events: none; z-index: 50; overflow: hidden; }
.fx-spark { position: absolute; display: block; }
.fx-float { position: absolute; font-family: var(--display); font-weight: 800; font-size: 20px; color: var(--accent); text-shadow: 0 2px 12px rgba(200, 255, 61, 0.5); white-space: nowrap; }
.fx-confetti { position: absolute; inset: 0; width: 100%; height: 100%; }
.fx-bump { animation: fxBump 0.4s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes fxBump { 0% { transform: scale(1); } 40% { transform: scale(1.22); } 100% { transform: scale(1); } }

/* poll: question card swipes in, options rise in one by one */
.qcard { animation: swipeIn 0.38s cubic-bezier(.2, .9, .3, 1.1); }
@keyframes swipeIn { from { transform: translateX(60px) rotate(4deg); opacity: 0; } to { transform: none; opacity: 1; } }
.qcard.exit { animation: swipeOut 0.26s ease-in forwards; }
@keyframes swipeOut { to { transform: translateX(-110%) rotate(-8deg); opacity: 0; } }
.opts .opt { animation: rise 0.36s cubic-bezier(.2, .9, .3, 1.2) backwards; }
.opts .opt:nth-child(2) { animation-delay: 0.05s; } .opts .opt:nth-child(3) { animation-delay: 0.1s; } .opts .opt:nth-child(4) { animation-delay: 0.15s; }
@keyframes rise { from { transform: translateY(18px) scale(0.94); opacity: 0; } }
.opts.decided .opt { transition: opacity 0.2s, transform 0.2s, box-shadow 0.2s; }
.opts.decided .opt:not(.picked) { opacity: 0.25; transform: scale(0.94); }
.opts.decided .opt.picked { transform: scale(1.05); box-shadow: 0 0 0 2px var(--accent), 0 0 28px rgba(200, 255, 61, 0.35); background: var(--accent-soft); border-color: var(--accent); }
.opts.exit .opt { animation: fadeDown 0.22s ease-in forwards; }
@keyframes fadeDown { to { transform: translateY(14px); opacity: 0; } }
.progress div { transition: width 0.5s cubic-bezier(.2, .9, .3, 1.2); }

/* round complete celebration */
.fx-celebrate { position: absolute; inset: 0; pointer-events: auto; background: rgba(10, 10, 12, 0.82); display: flex; align-items: center; justify-content: center; animation: fade 0.25s; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.fx-celebrate.out { animation: fadeOut 0.25s forwards; }
@keyframes fadeOut { to { opacity: 0; } }
.fx-cel-card { text-align: center; animation: celPop 0.5s cubic-bezier(.2, 1.4, .4, 1); padding: 20px; }
.fx-cel-card h2 { font-size: 26px; margin: 6px 0; }
@keyframes celPop { from { transform: scale(0.6); opacity: 0; } }
.fx-flame { width: 120px; height: 120px; margin: 0 auto 10px; border-radius: 40px; background: var(--accent); color: var(--on-accent); display: flex; align-items: center; justify-content: center; font-size: 66px; animation: flameGrow 0.9s cubic-bezier(.3, 1.6, .5, 1), flicker 1.4s 0.9s ease-in-out infinite; }
@keyframes flameGrow { 0% { transform: scale(0.3) rotate(-20deg); } 60% { transform: scale(1.15) rotate(6deg); } 100% { transform: scale(1) rotate(0); } }
@keyframes flicker { 0%, 100% { transform: scale(1) rotate(-2deg); } 50% { transform: scale(1.06) rotate(3deg); } }
.fx-streak { font-family: var(--display); font-size: 18px; font-weight: 700; margin: 0; color: var(--accent); }
.fx-streak b { font-size: 34px; }
.fx-bonus { font-weight: 800; margin: 0; color: var(--purple); }

/* scratch card */
.scratch-box { position: relative; height: 120px; border-radius: 20px; overflow: hidden; background: var(--card-2); border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; margin: 14px 0; touch-action: none; user-select: none; }
.scratch-box .secret { text-align: center; }
.scratch-box .secret b { display: block; font-family: var(--display); font-size: 44px; color: var(--accent); line-height: 1; }
.scratch-box .secret span { font-size: 13px; color: var(--muted); font-weight: 600; }
.scratch-box.done .secret b { animation: fxBump 0.5s cubic-bezier(.3, 1.6, .5, 1); }
.fx-scratch { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; touch-action: none; }

/* guess who: drumroll + flip reveal */
.drum { text-align: center; padding: 10px 0 6px; }
.drum .av { margin: 0 auto 12px; animation: drum 0.12s linear infinite; }
.drum p { font-family: var(--display); font-weight: 700; font-size: 18px; margin: 0; }
.drum .dots-anim::after { content: ''; animation: dots 1s steps(4) infinite; }
@keyframes drum { 0%, 100% { transform: translateX(-3px) rotate(-3deg); } 50% { transform: translateX(3px) rotate(3deg); } }
@keyframes dots { 0% { content: ''; } 25% { content: '.'; } 50% { content: '..'; } 75% { content: '...'; } }
.flip { perspective: 800px; margin: 8px 0 4px; }
.flip-inner { border-radius: 24px; padding: 26px 16px; text-align: center; animation: flipIn 0.6s cubic-bezier(.3, 1.3, .5, 1); transform-origin: center; }
.flip-inner.ok { background: var(--accent); color: var(--on-accent); }
.flip-inner.no { background: var(--card-2); border: 1px solid var(--danger); }
.flip-inner i { font-size: 44px; display: block; margin-bottom: 6px; }
.flip-inner.no i { color: var(--danger); }
.flip-inner h2 { margin: 0 0 4px; }
@keyframes flipIn { from { transform: rotateY(90deg) scale(0.9); opacity: 0.4; } }

/* toast slides down, badge bounces, inbox rows slide in */
.toast { animation: toastIn 0.4s cubic-bezier(.2, 1.3, .4, 1); }
@keyframes toastIn { from { transform: translate(-50%, -140%); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
.badge.fx-bump, .tab.fx-bump { animation: badgeBounce 0.6s cubic-bezier(.3, 1.8, .5, 1); }
@keyframes badgeBounce { 0% { transform: scale(1); } 30% { transform: scale(1.5) translateY(-4px); } 60% { transform: scale(0.9); } 100% { transform: scale(1); } }
.stack > .row, .stack > .post, .stack > .sq-card, .stack > .person { animation: rise 0.35s cubic-bezier(.2, .9, .3, 1.1) backwards; }
.stack > :nth-child(2) { animation-delay: 0.04s; } .stack > :nth-child(3) { animation-delay: 0.08s; } .stack > :nth-child(4) { animation-delay: 0.12s; } .stack > :nth-child(5) { animation-delay: 0.16s; } .stack > :nth-child(n+6) { animation-delay: 0.2s; }
.no-anim, .no-anim * { animation: none !important; }

/* onboarding: content glides in, icon floats */
.onb > * { animation: rise 0.45s cubic-bezier(.2, .9, .3, 1.1) backwards; }
.onb > :nth-child(2) { animation-delay: 0.06s; } .onb > :nth-child(3) { animation-delay: 0.12s; } .onb > :nth-child(4) { animation-delay: 0.18s; } .onb > :nth-child(5) { animation-delay: 0.24s; } .onb > :nth-child(6) { animation-delay: 0.3s; }
.onb .big-ico { animation: icoIn 0.6s cubic-bezier(.3, 1.6, .5, 1) backwards 0.06s, float 3s ease-in-out 0.7s infinite; }
@keyframes icoIn { from { transform: scale(0.3) rotate(-30deg); opacity: 0; } to { transform: rotate(-6deg); } }
@keyframes float { 0%, 100% { transform: rotate(-6deg) translateY(0); } 50% { transform: rotate(4deg) translateY(-8px); } }
.big-emoji { animation: icoPop 0.5s cubic-bezier(.3, 1.6, .5, 1) backwards; }
@keyframes icoPop { from { transform: scale(0.4) rotate(-15deg); opacity: 0; } }

/* respect "reduce motion" */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; transition-duration: 0.01ms !important; }
}

/* ---------- sign in, notification banner, iPhone guide ---------- */
.gbtn { display: flex; justify-content: center; min-height: 44px; }
.banner .btn.small { flex-shrink: 0; padding: 8px 14px; font-size: 13px; }
.banner .icon-btn.sm { flex-shrink: 0; }
.steps { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.step { display: flex; align-items: center; gap: 12px; background: var(--card-2); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; font-size: 14px; }
.step > b { width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--on-accent); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-family: var(--display); }
.step i { color: var(--accent); }

/* ---------- sign-in screen ---------- */
.signin { min-height: calc(100vh - 40px); display: flex; flex-direction: column; justify-content: center; gap: 22px; padding-bottom: 20px; }
.si-hero { position: relative; height: 250px; margin: 0 -16px; overflow: hidden; }
.si-glow { position: absolute; left: 50%; top: 50%; width: 260px; height: 260px; transform: translate(-50%, -50%); border-radius: 50%; background: radial-gradient(circle, rgba(200, 255, 61, 0.22), rgba(155, 123, 255, 0.12) 45%, transparent 70%); animation: glowPulse 5s ease-in-out infinite; }
@keyframes glowPulse { 50% { transform: translate(-50%, -50%) scale(1.15); } }
.si-logo { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(-4deg); font-family: var(--display); font-weight: 800; font-size: 30px; letter-spacing: -1px; background: var(--card); border: 1px solid var(--line); padding: 12px 20px; border-radius: 20px; white-space: nowrap; animation: icoIn 0.6s cubic-bezier(.3, 1.6, .5, 1) backwards; }
.si-logo span { color: var(--accent); }
.si-bubble { position: absolute; display: flex; align-items: center; gap: 6px; animation: rise 0.6s cubic-bezier(.2, .9, .3, 1.2) backwards, bob 4s ease-in-out infinite; }
.si-bubble .av { width: 54px; height: 54px; border: 3px solid var(--bg); box-shadow: 0 0 0 1px var(--line); }
.si-tag { background: var(--accent); color: var(--on-accent); font-size: 11px; font-weight: 800; padding: 5px 9px; border-radius: 99px; white-space: nowrap; display: inline-flex; align-items: center; gap: 3px; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4); }
.si-tag i { font-size: 12px; }
.b1 { left: 6%; top: 14px; animation-delay: 0.1s, 0s; }
.b2 { right: 4%; top: 30px; flex-direction: row-reverse; animation-delay: 0.2s, 0.8s; }
.b2 .si-tag { background: var(--purple); }
.b3 { left: 10%; bottom: 22px; animation-delay: 0.3s, 1.6s; }
.b3 .si-tag { background: #ff8fb8; }
.b4 { right: 8%; bottom: 10px; flex-direction: row-reverse; animation-delay: 0.4s, 2.4s; }
.b5 { left: 44%; top: 16px; animation-delay: 0.5s, 1.2s; }
.b5 .av { width: 40px; height: 40px; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.si-copy { text-align: center; }
.si-copy h1 { font-size: 32px; line-height: 1.1; letter-spacing: -1px; margin-bottom: 10px; }
.si-copy h1 span { color: var(--accent); }
.si-card { background: var(--card); border: 1px solid var(--line); border-radius: 28px; padding: 22px 18px 16px; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.gbtn { color-scheme: light; display: flex; justify-content: center; width: 100%; min-height: 44px; }
.gbtn iframe { color-scheme: light; }
.si-trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; font-size: 12px; color: var(--muted); font-weight: 600; }
.si-trust i { color: var(--accent); font-size: 14px; vertical-align: -2px; }
.si-legal { text-align: center; font-size: 11px; color: #5c5c68; margin: 0; line-height: 1.5; }
