/* 谁是人类 · 鹅鸭杀式综艺牌桌。1280×720 舞台，由 app.js 等比缩放到窗口。 */
:root {
  color-scheme: dark;
  --bg: #1A0E1B; --panel: #2A1830; --panel-2: #341D3B; --line: #6A3261; --ink: #120A12;
  --cream: #FFF6E5; --gold: #FAC722; --red: #E72928; --red-dk: #B5121A; --green: #46B87F; --skip: #A9A6F5; --muted: #B9A3B8; --blue: #2E6FD8;
  --font: "Noto Sans CJK SC", "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "WenQuanYi Micro Hei", sans-serif;
  --pop: cubic-bezier(.3, 1.6, .5, 1);
  font-family: var(--font);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; background: #0c070c; color: var(--cream); overflow: hidden; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .45; cursor: not-allowed; }
button:focus-visible, input:focus-visible, label:focus-within, .card[data-vote]:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
[hidden] { display: none !important; }

#app { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.stage { position: relative; flex: none; width: 1280px; height: 720px; overflow: hidden; transform-origin: center center;
  background: radial-gradient(900px 420px at 50% -10%, #3a1d3c 0%, transparent 70%), var(--bg); }
.boot { display: grid; place-items: center; text-align: center; gap: 12px; }
.boot h1 { font-size: 72px; } .boot p { color: var(--muted); }

/* ---------- 角色贴纸 ---------- */
.char, .mini i, .tumble { display: block; background-position: center bottom; background-size: contain; background-repeat: no-repeat; }
.char { position: absolute; width: 170px; height: 168px; pointer-events: none; }

/* ---------- 字体 ---------- */
.slant { font-weight: 800; letter-spacing: .04em; color: var(--cream); transform: rotate(-4deg); display: inline-block;
  -webkit-text-stroke: 6px var(--ink); paint-order: stroke fill; text-shadow: 0 6px 0 var(--ink); }
.tag { font-size: 13px; font-weight: 700; letter-spacing: .08em; color: var(--muted); }

/* ---------- 按钮 ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 58px; padding: 0 30px; border-radius: 99px; border: 4px solid var(--ink);
  font: 700 22px/1 var(--font); letter-spacing: .08em; color: var(--ink); background: var(--gold); box-shadow: 0 6px 0 var(--ink); flex: none; }
.btn:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--ink); }
.btn.ghost { background: var(--panel); color: var(--cream); border-color: var(--line); box-shadow: 0 6px 0 #0a050a; }
.btn.red { background: var(--red); color: var(--cream); }
.btn.sm { height: 50px; padding: 0 20px; font-size: 18px; }
.mic { width: 66px; height: 66px; padding: 0; border-radius: 50%; touch-action: none; }
.mic svg { width: 30px; height: 30px; stroke: var(--ink); fill: none; stroke-width: 2.6; stroke-linecap: round; }
.mic.wait { background: #5a4a5a; filter: saturate(.3); cursor: default; }
.mic.holding { background: var(--red); animation: pulse 1s ease-in-out infinite; }
.copy { height: 34px; padding: 0 14px; border-radius: 99px; border: 2px solid var(--ink); background: var(--cream); color: var(--ink); font: 700 14px var(--font); box-shadow: 0 3px 0 var(--ink); }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 16px; border-radius: 99px; border: 3px solid var(--ink); flex: none;
  font-weight: 700; font-size: 18px; background: var(--panel); color: var(--gold); box-shadow: 0 0 0 2px var(--line), 0 4px 0 var(--ink); font-variant-numeric: tabular-nums; }
.pill small { font-size: 12px; color: var(--muted); }
.pill.live { color: var(--red); font-size: 14px; }
.pill.skip { color: var(--skip); font-size: 15px; gap: 8px; cursor: default; padding: 0 12px 0 16px; }
.pill.skip.open { cursor: pointer; background: var(--skip); color: var(--ink); animation: pulse 1.4s ease-in-out infinite; }
.pill.skip.open:hover { background: #c4c2ff; }
.pill.skip.picked { background: var(--skip); color: var(--ink); }
.pill.skip .votes { position: static; height: auto; gap: 2px; }
.pill.skip .votes:empty { display: none; }
.pill.skip .mini { width: 24px; height: 24px; border-width: 2px; box-shadow: none; }
.pill.skip .skip-n:empty { display: none; }
.pill.skip .skip-n { color: var(--red); }
.pill.skip.picked .skip-n, .pill.skip.open .skip-n { color: var(--ink); }

/* ---------- 开局 ---------- */
.lobby { position: absolute; inset: 0; }
.beams { position: absolute; inset: 0; pointer-events: none; background:
  conic-gradient(from 168deg at 22% -8%, transparent 0 6deg, rgba(250,199,34,.10) 6deg 16deg, transparent 16deg 360deg),
  conic-gradient(from 178deg at 78% -8%, transparent 0 4deg, rgba(231,41,40,.12) 4deg 15deg, transparent 15deg 360deg); }
.floor { position: absolute; left: 0; right: 0; bottom: 0; height: 250px; background: radial-gradient(60% 70% at 50% 100%, #40203F 0, #2A1830 55%, transparent 75%); }
.logo { position: absolute; left: 56px; top: 34px; }
.logo .title { margin-top: 34px; font-size: 112px; line-height: 1.05; -webkit-text-stroke: 10px var(--ink); text-shadow: 8px 10px 0 var(--red), 8px 10px 0 var(--ink); }
.logo .q { color: var(--gold); }
.logo .ep { position: absolute; left: 12px; top: -6px; transform: rotate(-4deg); background: var(--red); color: var(--cream); font-weight: 700; font-size: 18px;
  padding: 4px 14px; border: 3px solid var(--ink); border-radius: 8px; box-shadow: 0 4px 0 var(--ink); }
.logo .sub { margin: 22px 0 0 18px; font-size: 18px; color: var(--muted); letter-spacing: .12em; }
.host-lobby { left: 610px; top: 30px; width: 180px; height: 190px; transform: rotate(-6deg); animation: bob 2.6s ease-in-out infinite; }
.hb { position: absolute; left: 560px; top: 222px; background: #fff; color: var(--ink); border: 3px solid var(--ink); border-radius: 16px; padding: 8px 14px; font-weight: 700; font-size: 17px; box-shadow: 0 4px 0 var(--ink); }
.room { position: absolute; right: 96px; top: 30px; width: 360px; padding: 14px 18px 16px; background: var(--panel); border: 3px solid var(--line); border-radius: 18px; box-shadow: 0 6px 0 #0a050a;
  display: flex; flex-direction: column; gap: 6px; }
.opts { display: flex; gap: 8px; }
.opt { flex: 1; position: relative; }
.opt input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.scenes .opt span { font-size: 13px; letter-spacing: -.02em; white-space: nowrap; }
.opt span { display: grid; place-items: center; height: 38px; border-radius: 12px; border: 2px solid var(--line); background: var(--panel-2); font-weight: 700; font-size: 15px; color: var(--muted); }
.opt input:checked + span { background: var(--gold); color: var(--ink); border-color: var(--ink); box-shadow: 0 3px 0 var(--ink); }
.blurb { min-height: 36px; font-size: 13px; line-height: 1.4; color: var(--muted); }
.alias-row { display: flex; gap: 8px; align-items: center; }
.alias-row input { flex: 1; min-width: 0; height: 40px; padding: 0 12px; border-radius: 12px; border: 2px solid var(--line); background: #140a14; font-weight: 700; font-size: 17px; }
.lineup { position: absolute; left: 40px; right: 96px; bottom: 126px; height: 250px; display: flex; justify-content: space-between; align-items: flex-end; }
.slot { position: relative; width: 150px; display: flex; flex-direction: column; align-items: center; visibility: hidden; }
.slot .char { position: relative; width: 150px; height: 190px; transform-origin: 50% 100%; filter: drop-shadow(0 8px 0 rgba(0,0,0,.35)); }
.slot .nm { margin-top: 8px; padding: 3px 12px; border-radius: 99px; background: var(--panel); border: 2px solid var(--line); font-weight: 700; font-size: 15px; letter-spacing: .04em; }
.slot small { margin-top: 2px; font-size: 12px; color: var(--muted); }
.slot.me .nm { background: var(--gold); color: var(--ink); border-color: var(--ink); }
.slot.me::after { content: "你"; position: absolute; top: -6px; right: 12px; width: 34px; height: 34px; border-radius: 50%; background: var(--red); border: 3px solid var(--ink);
  color: var(--cream); font-weight: 700; display: grid; place-items: center; transform: rotate(10deg); box-shadow: 0 3px 0 var(--ink); }
.slot.in { visibility: visible; }
.slot.in .char { animation: dropIn .55s var(--pop) both, bob 2.6s ease-in-out .6s infinite; }
.rule { position: absolute; left: 40px; bottom: 30px; display: flex; align-items: center; gap: 14px; height: 78px; padding: 0 22px 0 12px; max-width: 760px;
  background: rgba(0,0,0,.4); border: 2px solid var(--line); border-radius: 18px; font-size: 19px; }
.rule .mini { width: 54px; height: 54px; }
.rule b { color: var(--gold); }
.rule small { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.go { position: absolute; right: 96px; bottom: 34px; height: 78px; padding: 0 54px; font-size: 32px; border-width: 5px; box-shadow: 0 8px 0 var(--ink); animation: pulse 1.4s ease-in-out infinite; }
.go::after { content: ""; position: absolute; inset: -10px; border-radius: 99px; border: 4px solid var(--gold); opacity: 0; animation: ring 1.4s ease-out infinite; }

/* ---------- 牌桌顶栏 ---------- */
.topbar { position: absolute; left: 40px; right: 96px; top: 18px; height: 70px; display: flex; align-items: center; gap: 18px; }
.topbar .slant { font-size: 38px; white-space: nowrap; }
.timer { flex: 1; height: 22px; border: 3px solid var(--ink); border-radius: 99px; background: #140a14; overflow: hidden; box-shadow: 0 0 0 2px var(--line); visibility: hidden; }
.timer i { display: block; height: 100%; width: 100%; border-radius: 99px; background: linear-gradient(90deg, #46B87F, #B6D33A 55%, var(--gold)); transform-origin: left; transition: transform .25s linear; }
.timer i.low { background: var(--red); }
.topbar .clock { visibility: hidden; }
.topbar.timed .timer, .topbar.timed .clock { visibility: visible; }
.rail { position: absolute; right: 20px; top: 20px; width: 56px; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.rail .ico { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: var(--panel); border: 2px solid var(--line); }
.rail .ico svg { width: 26px; height: 26px; stroke: var(--cream); fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.rail .ico:hover { background: var(--gold); border-color: var(--ink); } .rail .ico:hover svg { stroke: var(--ink); }
.rail .control { width: 46px; min-height: 38px; padding: 6px 2px; border: 2px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--cream); font: 700 14px var(--font); }
.rail .control:hover { border-color: var(--gold); color: var(--gold); }
.game-menu { width: min(420px, calc(100vw - 48px)); margin: auto; padding: 28px; border: 3px solid var(--line); border-radius: 18px; background: var(--panel); color: var(--cream); }
.game-menu::backdrop { background: rgba(10,5,10,.78); }
body:has(.game-menu[open]) .stage * { animation-play-state: paused !important; }
.game-menu h2 { margin: 0 0 12px; font-size: 28px; }
.game-menu p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.6; }
.menu-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.menu-actions .btn { height: 46px; padding: 0 20px; font-size: 16px; }

/* ---------- 牌墙：3 / 群主 / 2 ---------- */
.wall { position: absolute; left: 40px; right: 96px; top: 104px; display: grid; grid-template-columns: repeat(6, 1fr); grid-template-rows: 154px 112px 154px; gap: 16px; }
.card { position: relative; grid-column: span 2; background: var(--panel); border: 3px solid var(--line); border-radius: 18px;
  transition: transform .25s var(--pop), border-color .2s, box-shadow .2s; }
.card.span-3 { grid-column: span 3; } .card.span-6 { grid-column: span 6; } .card.span-1 { grid-column: span 1; }
.card.host { grid-column: 1 / -1; background: linear-gradient(90deg, #3A1A2E, var(--panel) 40%); }
.card .char { left: -14px; bottom: -6px; transform-origin: 50% 100%; animation: bob 2.6s ease-in-out infinite; filter: drop-shadow(0 6px 0 rgba(0,0,0,.35)); }
.card:nth-child(2) .char { animation-delay: -.7s; } .card:nth-child(3) .char { animation-delay: -1.3s; }
.card:nth-child(5) .char { animation-delay: -.4s; } .card:nth-child(6) .char { animation-delay: -1.9s; }
.card.host .char { width: 130px; height: 132px; left: 20px; bottom: -8px; }
.card .who { position: absolute; left: 150px; top: 12px; right: 14px; display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 17px; letter-spacing: .04em; white-space: nowrap; }
.card .who small { font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--panel-2); color: var(--muted); overflow: hidden; text-overflow: ellipsis; }
.card.you .who small { background: var(--gold); color: var(--ink); }
.card.host .who { left: 170px; }
.card.host .who small { background: var(--gold); color: var(--ink); }
.topic-meta { margin-left: auto; font-size: 13px; color: var(--muted); }
.card .say { position: absolute; left: 150px; right: 16px; top: 42px; font-size: 14px; line-height: 1.5; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card.host .say { left: 170px; top: 40px; font-size: 19px; line-height: 1.4; color: var(--cream); font-weight: 700; -webkit-line-clamp: 2; }
.card.dim .say { opacity: .6; } .card.dim .char { filter: saturate(.55) brightness(.8) drop-shadow(0 6px 0 rgba(0,0,0,.35)); }
.waves { display: none; color: var(--ink); letter-spacing: -.08em; animation: wave 1s ease-out infinite; }

.card.speaking { border: 5px solid var(--gold); transform: scale(1.04); z-index: 3; box-shadow: 0 0 0 4px rgba(250,199,34,.22), 0 0 36px rgba(250,199,34,.55); }
.card.speaking .char { animation: talk .42s ease-in-out infinite; }
.card.thinking .char { animation: bob 1.2s ease-in-out infinite; }
.card.speaking:not(.host) .who { left: 146px; right: auto; top: -17px; gap: 4px; background: var(--gold); color: var(--ink); padding: 2px 12px; border-radius: 99px; border: 3px solid var(--ink); font-size: 15px; z-index: 4; }
.card.speaking:not(.host) .who small { background: transparent; color: var(--ink); padding: 0 2px; }
.card.speaking .waves { display: inline; }
.card.host.speaking .say { color: var(--gold); }

.bubble { position: absolute; left: 142px; right: 12px; top: 26px; bottom: 12px; background: #fff; color: var(--ink); border: 3px solid var(--ink);
  border-radius: 18px; padding: 8px 12px; font-size: 15px; line-height: 1.45; box-shadow: 0 4px 0 var(--ink); overflow: hidden; }
.bubble::before { content: ""; position: absolute; left: -15px; top: 30px; border: 9px solid transparent; border-right: 14px solid var(--ink); }
.bubble::after { content: ""; position: absolute; left: -9px; top: 32px; border: 7px solid transparent; border-right: 11px solid #fff; }
.bubble .text { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.thinking .bubble .text { color: #7a6a7a; font-style: italic; }
.caret { display: inline-block; width: 2px; height: 1em; background: currentColor; vertical-align: -2px; margin-left: 2px; animation: blink .8s steps(1) infinite; }

/* 投票 */
.card[data-vote] { cursor: pointer; }
.card.votable:hover { border-color: var(--gold); transform: translateY(-3px) rotate(-.6deg); }
.card.votable::after { content: "点我投票"; position: absolute; right: 12px; top: 10px; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--red); color: var(--cream); border: 2px solid var(--ink); }
.card.picked { border-color: var(--green); box-shadow: 0 0 0 3px rgba(70,184,127,.35); }
.card.picked::after { content: "✓ 你投了它"; position: absolute; right: 12px; top: 10px; z-index: 4; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--green); color: #fff; border: 2px solid var(--ink); }
.card.speaking.picked::after, .card.speaking.votable::after { top: auto; bottom: -14px; }
.card.target { border-color: var(--red); box-shadow: 0 0 0 3px rgba(231,41,40,.35), 0 0 28px rgba(231,41,40,.45); }
.card:has(.count.on) .bubble { bottom: 56px; right: 66px; }
.votes { z-index: 4; position: absolute; left: 150px; right: 64px; bottom: 10px; height: 40px; display: flex; gap: 6px; align-items: center; pointer-events: none; }
.count { position: absolute; right: 12px; bottom: 10px; min-width: 46px; height: 42px; padding: 0 8px; border-radius: 12px; background: var(--red); border: 3px solid var(--ink);
  color: var(--cream); font: 700 22px/36px var(--font); text-align: center; box-shadow: 0 4px 0 var(--ink); font-variant-numeric: tabular-nums; display: none; }
.count.on { display: block; }
.check { position: absolute; right: -10px; top: -12px; z-index: 5; width: 40px; height: 40px; border-radius: 50%; background: var(--green); border: 3px solid var(--ink); display: grid; place-items: center; box-shadow: 0 3px 0 var(--ink); }
.check svg { width: 22px; height: 22px; stroke: #fff; stroke-width: 4; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.mini { display: inline-block; width: 36px; height: 36px; border-radius: 50%; background: var(--cream); border: 3px solid var(--ink); overflow: hidden; flex: none; box-shadow: 0 3px 0 var(--ink); }
.mini i { width: 100%; height: 100%; background-position: center 20%; background-size: 130%; }
.mini.flying { position: absolute; z-index: 40; width: 38px; height: 38px; pointer-events: none; }

/* ---------- 字幕 / 速填 / 底栏 ---------- */
.subs, .assist { position: absolute; left: 40px; right: 96px; top: 562px; height: 50px; display: flex; align-items: center; gap: 12px; padding: 0 18px;
  background: rgba(0,0,0,.35); border: 2px solid var(--line); border-radius: 14px; font-size: 17px; overflow: hidden; }
.subs .who-line { color: var(--gold); flex: none; }
.subtitle { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.subtitle.medium { font-size: 15px; }
.subtitle.long { font-size: 13px; white-space: normal; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.subtitle.thinking { color: var(--muted); font-style: italic; }
.assist { gap: 8px; }
.chip-btn, .assist .chip { height: 34px; padding: 0 12px; border-radius: 10px; border: 3px solid var(--ink); background: var(--blue); color: #fff; font-size: 14px; font-weight: 700; box-shadow: 0 3px 0 var(--ink); flex: none; }
.assist .chip:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--ink); }
.example { margin-left: auto; font-size: 14px; color: var(--gold); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dock { position: absolute; left: 40px; right: 96px; bottom: 18px; height: 80px; display: flex; align-items: center; gap: 14px; }
.line { flex: 1; display: flex; gap: 10px; min-width: 0; }
.line input { flex: 1; min-width: 0; height: 58px; padding: 0 20px; border-radius: 99px; border: 4px solid var(--ink); background: var(--cream); color: var(--ink); font-size: 18px; font-weight: 700; box-shadow: 0 0 0 2px var(--line); }
.line input::placeholder { color: #9b8a95; font-weight: 400; }
.hint { min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 15px; color: var(--muted); overflow: hidden; }
.hint b { color: var(--cream); font-size: 18px; }
.hint.big b { font-size: 24px; color: var(--gold); }
.dock .hint:only-child, .dock > .hint { flex: 1; }
.dock .line + .hint { flex: 0 1 220px; font-size: 13px; }
.drawer { margin-left: auto; flex: none; display: flex; align-items: center; gap: 8px; height: 48px; padding: 0 18px; border-radius: 14px; align-self: center;
  background: var(--panel); border: 2px solid var(--line); font-size: 15px; color: var(--muted); }
.drawer b { color: var(--cream); }
.log { position: absolute; right: 96px; top: 104px; bottom: 100px; width: 430px; z-index: 30; display: flex; flex-direction: column;
  background: rgba(26,14,27,.97); border: 3px solid var(--line); border-radius: 18px; box-shadow: 0 10px 0 #0a050a; }
.log header { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 2px solid var(--line); font-size: 18px; }
.log ol { list-style: none; overflow-y: auto; padding: 10px 14px; display: flex; flex-direction: column; gap: 10px; }
.log li { display: flex; gap: 10px; align-items: flex-start; }
.log li b { font-size: 14px; color: var(--gold); margin-right: 6px; }
.log li small { font-size: 12px; color: var(--muted); }
.log li p { font-size: 14px; line-height: 1.45; }
.log .empty { color: var(--muted); }

/* ---------- 综艺横幅 ---------- */
.banner { position: absolute; inset: 0; z-index: 50; display: grid; place-items: center; pointer-events: none; }
.banner .strip { position: absolute; left: -10%; right: -10%; top: 50%; height: 230px; margin-top: -115px; transform: rotate(-5deg);
  background: repeating-linear-gradient(-60deg, var(--red) 0 46px, var(--red-dk) 46px 92px); border-top: 10px solid var(--cream); border-bottom: 10px solid var(--cream);
  box-shadow: 0 0 0 6px var(--ink), 0 0 0 9999px rgba(10,4,10,.55); }
.banner .txt { position: relative; font-size: 88px; z-index: 2; }
.banner .face { left: 30px; top: 50%; width: 300px; height: 330px; margin-top: -190px; z-index: 3; }
.banner.run .strip { animation: stripIn 1.35s ease-out both; }
.banner.run .txt { animation: txtIn 1.35s var(--pop) both; }
.banner.run .face { animation: faceIn 1.35s cubic-bezier(.2,.9,.3,1) both; }

/* ---------- 揭晓 ---------- */
.reveal { position: absolute; inset: 0; }
.space { position: absolute; inset: 0; animation: drift 30s linear infinite; background:
  radial-gradient(1.5px 1.5px at 12% 18%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 28% 72%, #fff 50%, transparent 51%),
  radial-gradient(1.5px 1.5px at 44% 34%, #FFE58A 50%, transparent 51%), radial-gradient(2.5px 2.5px at 63% 12%, #fff 50%, transparent 51%),
  radial-gradient(1.5px 1.5px at 76% 58%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 88% 26%, #A9A6F5 50%, transparent 51%),
  radial-gradient(800px 500px at 30% 60%, #2b1440 0, transparent 70%), #0d0716;
  background-size: 420px 300px, 520px 380px, 380px 340px, 600px 420px, 460px 300px, 540px 360px, 100% 100%, 100% 100%; }
.hostzoom { position: absolute; inset: 0; z-index: 45; display: grid; place-items: center; background: rgba(10,4,10,.7); opacity: 0; pointer-events: none; }
.hostzoom .char { position: relative; width: 400px; height: 430px; transform: scale(.3) rotate(-10deg); }
.hostzoom .hb2 { position: absolute; left: 770px; top: 180px; background: #fff; color: var(--ink); border: 4px solid var(--ink); border-radius: 22px; padding: 14px 24px;
  font: 700 40px var(--font); box-shadow: 0 6px 0 var(--ink); transform: rotate(4deg); }
.hostzoom.run { animation: hz 1.1s ease both; } .hostzoom.run .char { animation: hzi 1.1s var(--pop) both; }
.tumble { position: absolute; left: -260px; top: 210px; width: 240px; height: 260px; z-index: 20; opacity: 0; }
.tumble.run { animation: tumble 2.4s cubic-bezier(.25,.6,.75,.4) both; }
.caption { position: absolute; left: 0; right: 0; top: 600px; text-align: center; font-size: 30px; font-weight: 700; letter-spacing: .06em; z-index: 21; }
.caption b { color: var(--gold); }
.caption.top { top: 40px; left: 96px; right: auto; text-align: left; font-size: 22px; }
.flip { position: absolute; left: 96px; top: 96px; width: 340px; height: 430px; perspective: 1200px; z-index: 10; opacity: 0; transform: translateY(40px); }
.flip.show { opacity: 1; transform: none; transition: opacity .3s, transform .4s var(--pop); }
.flip .inner { position: absolute; inset: 0; transform-style: preserve-3d; transition: transform .7s cubic-bezier(.4,1.4,.5,1); }
.flip.flipped .inner { transform: rotateY(180deg); }
.face { position: absolute; inset: 0; border-radius: 24px; border: 5px solid var(--ink); backface-visibility: hidden; box-shadow: 0 10px 0 var(--ink); }
.face.front { background: repeating-linear-gradient(45deg, #3a1d3c 0 18px, #2f1832 18px 36px); display: grid; place-items: center; overflow: hidden; }
.face.front .qq { font-size: 200px; }
.face.back { transform: rotateY(180deg); background: radial-gradient(circle at 50% 40%, #FFF6E5 0, #FFE58A 60%, var(--gold) 100%); }
.face.back .human { position: absolute; left: 0; right: 0; top: 26px; text-align: center; z-index: 2; }
.face.back .human .slant { font-size: 68px; color: var(--red); -webkit-text-stroke: 7px var(--ink); text-shadow: 0 6px 0 var(--ink); }
.face.back .human.ai .slant { color: var(--blue); font-size: 60px; }
.face.back .char { left: 50%; bottom: 16px; width: 260px; height: 250px; transform: translateX(-50%); }
.face.back .nm { position: absolute; left: 0; right: 0; top: -24px; text-align: center; }
.face.back .nm span { display: inline-block; background: var(--ink); color: var(--cream); font-weight: 700; font-size: 18px; padding: 6px 18px; border-radius: 99px; border: 3px solid var(--gold); }
.box { position: absolute; left: 50%; bottom: 30px; width: 180px; height: 120px; margin-left: -90px; z-index: 3;
  background: linear-gradient(#C99A5E, #B07F45); border: 4px solid var(--ink); border-radius: 8px; box-shadow: inset 0 -10px 0 rgba(0,0,0,.12); }
.box::before { content: ""; position: absolute; left: 50%; top: -4px; bottom: -4px; width: 26px; margin-left: -13px; background: #E8D3A8; border-left: 3px solid rgba(0,0,0,.25); border-right: 3px solid rgba(0,0,0,.25); }
.box::after { content: "AI ✓"; position: absolute; right: 10px; top: 12px; font: 700 15px var(--font); color: var(--ink); transform: rotate(-8deg); background: #fff; padding: 0 4px; border: 2px solid var(--ink); }
.box.fall { animation: boxfall .9s cubic-bezier(.5,0,.9,.6) forwards; }
.box.gone { display: none; }
.stamp { position: absolute; left: 120px; top: 470px; z-index: 30; max-width: 360px; padding: 6px 22px; border: 7px solid var(--red); border-radius: 14px; color: var(--red);
  font: 800 38px/1.15 var(--font); letter-spacing: .04em; text-align: center; transform: rotate(-12deg); background: rgba(255,246,229,.92); box-shadow: 0 0 0 3px var(--ink); opacity: 0; }
.stamp small { display: block; font-size: 15px; letter-spacing: .2em; margin-top: -4px; }
.stamp.on { animation: stamp .32s cubic-bezier(.6,0,.9,.4) both; }
.side { position: absolute; left: 540px; right: 96px; top: 84px; display: flex; flex-direction: column; gap: 12px; }
.win, .meter, .ending, .roast, .recap, .meta-line, .side .acts { opacity: 0; }
.on { opacity: 1 !important; }
.win.on { animation: pop .3s var(--pop) both; }
.win .slant { font-size: 52px; color: var(--gold); }
.win.good .slant { color: var(--green); }
.meter { background: rgba(26,14,27,.9); border: 3px solid var(--line); border-radius: 20px; padding: 14px 18px; display: flex; flex-direction: column; gap: 10px; transition: opacity .25s; }
.chipsList { display: flex; flex-wrap: wrap; gap: 8px; min-height: 36px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border-radius: 10px; border: 3px solid var(--ink); background: var(--blue); color: #fff; font-size: 15px; font-weight: 700; box-shadow: 0 3px 0 var(--ink); }
.chip b { font-size: 18px; }
.chip.mul { background: var(--red); }
.chip.plus { background: var(--green); }
.chip small { font-size: 12px; opacity: .85; }
.meter.detail .chip { height: 32px; padding: 0 10px; font-size: 14px; }
.meter.detail .chip b { font-size: 16px; }
.quote { font-size: 16px; line-height: 1.45; color: var(--cream); background: rgba(0,0,0,.3); border-left: 5px solid var(--gold); border-radius: 8px; padding: 8px 12px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.quote small { display: block; font-size: 12px; color: var(--muted); }
.calc { display: flex; align-items: center; gap: 14px; font: 700 24px var(--font); font-variant-numeric: tabular-nums; }
.calc .blk { min-width: 130px; height: 70px; padding: 0 14px; border-radius: 14px; border: 4px solid var(--ink); display: flex; flex-direction: column; align-items: center; justify-content: center; box-shadow: 0 5px 0 var(--ink); }
.calc .blk small { font-size: 12px; opacity: .85; } .calc .blk b { font-size: 36px; line-height: 1; }
.calc .c { background: var(--gold); color: var(--ink); } .calc .m { background: var(--blue); }
.calc .lbl { font-size: 16px; color: var(--muted); }
.ending { display: flex; gap: 10px; align-items: flex-start; transition: opacity .3s; }
.ending p { background: #fff; color: var(--ink); border: 3px solid var(--ink); border-radius: 14px; padding: 6px 12px; font-size: 15px; line-height: 1.45; font-weight: 700; box-shadow: 0 3px 0 var(--ink);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.roast { font-size: 15px; color: var(--muted); transition: opacity .3s; }
.recap { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--muted); transition: opacity .3s; }
.recap .minis { display: flex; gap: 4px; flex: none; } .recap .mini { width: 40px; height: 40px; }
.meta-line { font-size: 12px; color: var(--muted); transition: opacity .3s; }
.side .acts { display: flex; gap: 12px; transition: opacity .3s; }
.side .acts .btn { height: 54px; padding: 0 22px; font-size: 19px; }

/* ---------- 连接中断 ---------- */
.error-screen { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 40px; }
.err-host { position: relative; width: 300px; height: 320px; transform: rotate(-8deg); }
.err-box { display: flex; flex-direction: column; gap: 14px; max-width: 520px; }
.err-box .slant { font-size: 56px; color: var(--red); align-self: flex-start; }
.err-box h1 { font-size: 40px; } .err-box p { color: var(--muted); font-size: 18px; }
.err-box .acts { display: flex; gap: 12px; }

#toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 100; max-width: min(92vw, 560px); padding: 12px 20px; border-radius: 14px;
  background: var(--cream); color: var(--ink); border: 3px solid var(--ink); box-shadow: 0 4px 0 var(--ink); font-weight: 700; }

/* ---------- 动画 ---------- */
.pop { animation: pop .22s var(--pop) both; }
.shake { animation: shake .38s linear; }
@keyframes pop { 0% { transform: scale(0); } 70% { transform: scale(1.3); } 100% { transform: scale(1); } }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-4px) rotate(-1.5deg); } }
@keyframes talk { 0%, 100% { transform: scale(1, 1); } 50% { transform: scale(1.04, .95) translateY(2px); } }
@keyframes wave { 0% { opacity: .2; } 40% { opacity: 1; } 100% { opacity: .2; } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes dropIn { 0% { transform: translateY(-260px) scale(.9, 1.1); opacity: 0; } 60% { transform: translateY(0) scale(1.15, .85); opacity: 1; } 100% { transform: translateY(0) scale(1); } }
@keyframes pulse { 0%, 100% { transform: scale(1) rotate(-2deg); } 50% { transform: scale(1.06) rotate(-2deg); } }
@keyframes ring { 0% { opacity: .8; transform: scale(.95); } 100% { opacity: 0; transform: scale(1.25); } }
@keyframes stripIn { 0% { transform: rotate(-5deg) translateX(-100%); } 16% { transform: rotate(-5deg) translateX(0); } 84% { transform: rotate(-5deg) translateX(0); opacity: 1; } 100% { transform: rotate(-5deg) translateX(0) scaleY(.2); opacity: 0; } }
@keyframes txtIn { 0% { transform: rotate(-4deg) scale(2.4); opacity: 0; } 20% { transform: rotate(-4deg) scale(1); opacity: 1; } 82% { transform: rotate(-4deg) scale(1.04); opacity: 1; } 100% { transform: rotate(-4deg) scale(1.1); opacity: 0; } }
@keyframes faceIn { 0% { transform: translateX(-140%) rotate(-20deg); } 20%, 82% { transform: translateX(0) rotate(-6deg); } 100% { transform: translateX(-140%) rotate(-20deg); } }
@keyframes drift { to { background-position: -420px 0, -520px 0, -380px 0, -600px 0, -460px 0, -540px 0, 0 0, 0 0; } }
@keyframes hz { 0% { opacity: 0; } 12%, 85% { opacity: 1; } 100% { opacity: 0; } }
@keyframes hzi { 0% { transform: scale(.3) rotate(-10deg); } 25%, 85% { transform: scale(1) rotate(-4deg); } 100% { transform: scale(1.6) rotate(0); } }
@keyframes tumble { 0% { opacity: 1; transform: translate(0, 0) rotate(0) scale(1); } 100% { opacity: 1; transform: translate(1600px, -160px) rotate(760deg) scale(.45); } }
@keyframes boxfall { 0% { transform: translate(0, 0) rotate(0); } 20% { transform: translate(-6px, -26px) rotate(-6deg); } 100% { transform: translate(70px, 420px) rotate(38deg); opacity: 0; } }
@keyframes stamp { 0% { opacity: 0; transform: rotate(-12deg) scale(3); } 100% { opacity: 1; transform: rotate(-12deg) scale(1); } }
@keyframes shake { 0%, 100% { transform: translate(0); } 20% { transform: translate(-9px, 5px); } 40% { transform: translate(8px, -6px); } 60% { transform: translate(-6px, -3px); } 80% { transform: translate(5px, 4px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .slot { visibility: visible; }
}

/* 角色贴纸：GET /mixin/assets/*（后端 #29 提供）。 */
.av-claude { background-image: url(/mixin/assets/chars/claude.webp); }
.av-cursor { background-image: url(/mixin/assets/chars/cursor.webp); }
.av-deepseek { background-image: url(/mixin/assets/chars/deepseek.webp); }
.av-gemini { background-image: url(/mixin/assets/chars/gemini.webp); }
.av-gpt { background-image: url(/mixin/assets/chars/gpt.webp); }
.av-host { background-image: url(/mixin/assets/chars/host.webp); }
.av-niu { background-image: url(/mixin/assets/chars/niu.webp); }
.av-niu-free { background-image: url(/mixin/assets/chars/niu_free.webp); }
