:root {
  --bg: #070a14;
  --panel: #161c2e;
  --panel2: #1f2740;
  --line: #2f3a5c;
  --text: #eef2ff;
  --muted: #8d97b8;
  --accent: #3fb8ff;
  --good: #2ed573;
  --bad: #ff4757;
  --warn: #ffa502;
  --font: "Trebuchet MS", "Segoe UI", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font-family: var(--font); overflow: hidden; }
body { -webkit-tap-highlight-color: transparent; user-select: none; }
input { user-select: text; }
.hidden { display: none !important; }
.muted { color: var(--muted); font-size: 14px; }
button { font-family: inherit; cursor: pointer; }
kbd { background: #2a3352; border: 1px solid #45507a; border-radius: 4px; padding: 1px 5px; font-size: 12px; font-family: monospace; }

/* buttons + inputs */
.btn { background: var(--panel2); color: var(--text); border: 2px solid var(--line); border-radius: 10px; padding: 10px 16px; font-size: 16px; font-weight: bold; transition: transform .08s, background .15s; }
.btn:hover:not(:disabled) { background: #2a3456; }
.btn:active:not(:disabled) { transform: scale(0.97); }
.btn:disabled { opacity: .45; cursor: default; }
.btn.primary { background: linear-gradient(180deg, #3fb8ff, #1c7fd6); border-color: #7fd2ff; }
.btn.danger { background: #5b1f2a; border-color: #a33c4e; }
.btn.warn { background: #5a4313; border-color: #a17b26; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.big { padding: 14px 20px; font-size: 20px; }
.btn.small { padding: 5px 10px; font-size: 13px; border-radius: 8px; }
input { background: #0d1222; color: var(--text); border: 2px solid var(--line); border-radius: 10px; padding: 11px 14px; font-size: 17px; font-family: inherit; outline: none; width: 100%; }
input:focus { border-color: var(--accent); }
.icon-btn { background: rgba(20,26,44,.85); border: 2px solid var(--line); color: #fff; border-radius: 10px; width: 44px; height: 44px; font-size: 20px; position: relative; display: inline-flex; align-items: center; justify-content: center; }
.icon-btn.small { width: 28px; height: 28px; font-size: 13px; }
.icon-btn b { position: absolute; top: -6px; right: -6px; background: var(--bad); border-radius: 10px; font-size: 11px; padding: 1px 6px; }

/* connection */
#conn-status { position: fixed; top: 0; left: 0; right: 0; text-align: center; background: var(--bad); padding: 6px; z-index: 999; font-weight: bold; }

/* ===================== MENU */
.screen { position: fixed; inset: 0; }
#screen-menu { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16px; overflow-y: auto; background: radial-gradient(ellipse at 50% 30%, #18224a 0%, #070a14 70%); }
#screen-menu.hidden { display: none; }
.stars { position: absolute; inset: 0; pointer-events: none; background-image:
  radial-gradient(2px 2px at 20% 30%, #fff 50%, transparent 51%), radial-gradient(1.5px 1.5px at 70% 20%, #fff 50%, transparent 51%),
  radial-gradient(1.5px 1.5px at 40% 80%, #cfe 50%, transparent 51%), radial-gradient(2px 2px at 85% 65%, #fff 50%, transparent 51%),
  radial-gradient(1px 1px at 10% 90%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 55% 45%, #fff 50%, transparent 51%),
  radial-gradient(1.5px 1.5px at 30% 10%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 92% 12%, #fff 50%, transparent 51%);
  animation: drift 60s linear infinite; }
@keyframes drift { from { background-position: 0 0; } to { background-position: -400px 200px; } }
.logo { font-size: clamp(42px, 9vw, 84px); margin: 0; letter-spacing: 4px; text-shadow: 0 4px 0 #0a0f22, 0 0 30px rgba(63,184,255,.5); position: relative; }
.logo span { color: var(--bad); margin-left: 14px; }
.tagline { color: var(--muted); margin: 4px 0 22px; position: relative; }
.menu-card { position: relative; display: flex; gap: 26px; background: rgba(22,28,46,.92); border: 2px solid var(--line); border-radius: 18px; padding: 24px; max-width: 640px; width: 100%; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.menu-left { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.menu-right { flex: 1; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.field-label { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.join-row { display: flex; gap: 8px; }
.join-row input { text-transform: uppercase; letter-spacing: 6px; text-align: center; font-weight: bold; }
#lobby-list { max-height: 200px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; }
.lobby-row { display: grid; grid-template-columns: 1fr auto; text-align: left; background: #0d1222; border: 2px solid var(--line); color: var(--text); border-radius: 10px; padding: 8px 12px; }
.lobby-row span { grid-column: 1; color: var(--muted); font-size: 13px; }
.lobby-row code { grid-row: 1 / span 2; grid-column: 2; align-self: center; font-size: 18px; color: var(--accent); }
@media (max-width: 560px) { .menu-card { flex-direction: column; align-items: stretch; padding: 16px; } #menu-preview { width: 140px; height: 154px; } }

/* ===================== GAME HUD */
#game-canvas { position: absolute; inset: 0; display: block; touch-action: none; }
#hud-top-right { position: absolute; top: 12px; right: 12px; display: flex; gap: 8px; z-index: 20; }
#lobby-hud .lobby-top { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); text-align: center; z-index: 10; }
.code-box { background: rgba(20,26,44,.9); border: 2px solid var(--line); border-radius: 12px; padding: 8px 14px; font-size: 14px; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.code-box b { font-size: 26px; letter-spacing: 5px; color: #fff; }
.lobby-meta { color: var(--muted); font-size: 13px; margin-top: 4px; text-shadow: 0 1px 2px #000; }
.lobby-bottom { position: absolute; left: 12px; bottom: 12px; display: flex; flex-wrap: wrap; gap: 8px; z-index: 10; max-width: calc(100% - 24px); }
.lobby-start { position: absolute; bottom: 80px; left: 50%; transform: translateX(-50%); z-index: 10; text-align: center; }
.lobby-wait { background: rgba(20,26,44,.85); padding: 10px 18px; border-radius: 10px; color: var(--muted); }
#btn-start { box-shadow: 0 0 30px rgba(63,184,255,.5); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 10px rgba(63,184,255,.3); } }

#hud-top-left { position: absolute; top: 12px; left: 12px; z-index: 10; width: min(330px, 46vw); pointer-events: none; }
#progress { position: relative; height: 26px; background: #1d2e1d; border: 3px solid #0b0f0b; border-radius: 4px; overflow: hidden; }
#progress span { position: absolute; inset: 0; display: flex; align-items: center; padding-left: 8px; font-size: 12px; font-weight: bold; z-index: 2; text-shadow: 0 1px 2px #000; }
#progress-fill { height: 100%; width: 0; background: linear-gradient(180deg, #4cd964, #26a03c); transition: width .5s; }
#progress.unknown #progress-fill { width: 0 !important; }
#progress.unknown span::after { content: ' (hidden)'; color: #aaa; }
#role-badge { margin-top: 6px; font-weight: bold; font-size: 15px; text-shadow: 0 1px 3px #000; }
#task-list { margin-top: 6px; background: rgba(15,20,34,.78); border-radius: 8px; padding: 8px 10px; font-size: 14px; line-height: 1.45; }
#task-list:empty { display: none; }
.tl-item.done { color: var(--good); }
.tl-item.partial { color: #ffd32a; }
.tl-imp { color: #ff6b81; margin-bottom: 4px; }
.tl-sab { color: var(--bad); font-weight: bold; animation: blink 1s infinite; }
.tl-warn { color: var(--warn); font-weight: bold; }
.tl-ghost { color: #c7d2fe; font-style: italic; margin-bottom: 4px; }
@keyframes blink { 50% { opacity: .5; } }
#status-line { margin-top: 6px; color: #7bed9f; font-weight: bold; text-shadow: 0 1px 3px #000; }
#vitals-mini { position: absolute; top: 70px; right: 12px; background: rgba(15,20,34,.9); border: 2px solid var(--line); border-radius: 10px; padding: 8px 12px; font-size: 13px; z-index: 10; min-width: 140px; }
.vm { display: flex; align-items: center; gap: 6px; } .vm i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.vm.dead { color: var(--bad); text-decoration: line-through; }

#actions { position: absolute; right: 14px; bottom: 14px; display: grid; grid-template-columns: repeat(3, auto); gap: 10px; z-index: 15; direction: rtl; }
.act { direction: ltr; width: 92px; height: 92px; border-radius: 18px; border: 3px solid #0b0f1c; background: rgba(40,48,76,.92); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; position: relative; font-weight: bold; font-size: 14px; text-transform: uppercase; box-shadow: 0 4px 0 #0b0f1c; transition: transform .06s; }
.act .ico { font-size: 34px; line-height: 1; margin-bottom: 4px; }
.act .cd { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 40px; text-shadow: 0 2px 4px #000; }
.act .cd:empty { display: none; }
.act kbd { position: absolute; top: 4px; right: 4px; font-size: 10px; opacity: .7; }
.act.disabled { opacity: .38; filter: grayscale(.8); }
.act:active:not(.disabled) { transform: translateY(3px); box-shadow: 0 1px 0 #0b0f1c; }
.act.kill:not(.disabled) { background: linear-gradient(180deg, #d63031, #8e1b1b); }
.act.use:not(.disabled) { background: linear-gradient(180deg, #3fb8ff, #1c6fc2); }
#act-report:not(.disabled) { background: linear-gradient(180deg, #ff7f50, #c0392b); }
#act-sabotage { background: linear-gradient(180deg, #8e2b3b, #5b1622); }
@media (max-width: 700px), (max-height: 520px) {
  .act { width: 70px; height: 70px; font-size: 11px; border-radius: 14px; }
  .act .ico { font-size: 24px; }
  .act kbd { display: none; }
  #hud-top-left { font-size: 12px; }
  #task-list { font-size: 12px; }
}

#vent-arrows { position: absolute; inset: 0; pointer-events: none; z-index: 12; }
.vent-arrow { pointer-events: auto; position: absolute; transform: translate(-50%, -50%); background: rgba(255,71,87,.85); border: 3px solid #fff; color: #fff; border-radius: 14px; padding: 6px 10px; display: flex; flex-direction: column; align-items: center; font-weight: bold; }
.vent-arrow span { font-size: 28px; display: inline-block; }
.vent-arrow small { font-size: 11px; white-space: nowrap; }

#joystick { position: absolute; width: 120px; height: 120px; border-radius: 50%; background: rgba(255,255,255,.08); border: 3px solid rgba(255,255,255,.25); z-index: 14; pointer-events: none; }
#joystick-knob { position: absolute; left: 35px; top: 35px; width: 50px; height: 50px; border-radius: 50%; background: rgba(255,255,255,.4); }

/* chat */
#chat-panel { position: absolute; left: 12px; bottom: 74px; width: min(360px, calc(100vw - 24px)); height: min(380px, 50vh); background: rgba(15,20,34,.95); border: 2px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; z-index: 30; }
#chat-panel.ghost-chat { bottom: 12px; border-color: #6c7bbf; }
#chat-panel.ghost-chat .chat-head::after { content: ' (ghosts only)'; color: var(--muted); font-weight: normal; font-size: 12px; }
.chat-head { padding: 8px 12px; font-weight: bold; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; }
.chat-log { flex: 1; overflow-y: auto; padding: 8px; display: flex; flex-direction: column; gap: 6px; user-select: text; }
.chat-msg { display: flex; gap: 8px; align-items: flex-start; background: rgba(255,255,255,.04); border-radius: 10px; padding: 4px 8px; }
.chat-msg.mine { background: rgba(63,184,255,.12); }
.chat-msg.ghost { opacity: .75; font-style: italic; }
.chat-msg.system { color: var(--muted); font-size: 13px; background: none; justify-content: center; font-style: italic; }
.chat-msg canvas { flex-shrink: 0; }
.chat-text { display: flex; flex-direction: column; font-size: 14px; word-break: break-word; min-width: 0; }
.chat-input-row { display: flex; gap: 6px; padding: 8px; border-top: 1px solid var(--line); }
.chat-input-row input { padding: 8px 10px; font-size: 15px; }

/* ===================== TASK PANEL */
#task-panel { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(520px, 96vw); max-height: 94vh; background: #1a2035; border: 4px solid #0b0f1c; border-radius: 16px; z-index: 60; box-shadow: 0 0 0 4000px rgba(0,0,0,.55); overflow: auto; }
.tp-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; background: #10152a; font-weight: bold; font-size: 18px; }
.tp-close { background: var(--bad); border: none; color: #fff; width: 34px; height: 34px; border-radius: 8px; font-size: 18px; }
.tp-body { padding: 16px; display: flex; flex-direction: column; align-items: center; gap: 12px; position: relative; }
.tp-body.tg-done::after { content: '✔ TASK COMPLETE'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,.6); color: var(--good); font-size: 32px; font-weight: bold; }
.tg-canvas { width: 100%; max-width: 460px; height: auto; border-radius: 10px; border: 3px solid #0b0f1c; touch-action: none; }
.tg-msg { color: var(--muted); text-align: center; min-height: 20px; }
.tg-btn { background: linear-gradient(180deg, #3fb8ff, #1c6fc2); color: #fff; border: 3px solid #0b0f1c; border-radius: 12px; padding: 12px 22px; font-size: 18px; font-weight: bold; touch-action: none; }
.tg-btn.held { filter: brightness(1.3); transform: scale(.97); }
.tg-btn:disabled { opacity: .5; }
.tg-progress { width: 100%; }
.tg-progress-label { margin-bottom: 6px; text-align: center; }
.tg-bar { height: 26px; background: #0b0f1c; border-radius: 8px; overflow: hidden; border: 2px solid #2f3a5c; }
.tg-fill { height: 100%; width: 0; background: linear-gradient(90deg, #2ed573, #7bed9f); }
.tg-gauge { width: 90px; height: 220px; border: 4px solid #0b0f1c; border-radius: 12px; background: #0d1222; position: relative; overflow: hidden; }
.tg-gauge-fill { position: absolute; bottom: 0; left: 0; right: 0; height: 0; }
.tg-simon { display: grid; grid-template-columns: repeat(3, 80px); gap: 10px; }
.tg-cell { width: 80px; height: 80px; border-radius: 10px; border: 3px solid #0b0f1c; background: #2a3352; }
.tg-cell.lit { background: #3fb8ff; box-shadow: 0 0 20px #3fb8ff; }
.tg-cell.wrong { background: var(--bad); }
.tg-numbers { display: grid; grid-template-columns: repeat(5, 70px); gap: 10px; }
.tg-num { height: 70px; border-radius: 10px; border: 3px solid #0b0f1c; background: #2a3352; color: #fff; font-size: 28px; font-weight: bold; }
.tg-num.on { background: var(--good); }
@media (max-width: 420px) { .tg-numbers { grid-template-columns: repeat(5, 54px); } .tg-num { height: 54px; } .tg-simon { grid-template-columns: repeat(3, 66px); } .tg-cell { width: 66px; height: 66px; } }
.tg-tubes { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.tg-tube { --tube: #7bed9f; width: 40px; height: 110px; border-radius: 0 0 20px 20px; border: 3px solid #dfe6e9; background: linear-gradient(0deg, var(--tube) 60%, rgba(255,255,255,.1) 60%); }
.tg-tube.bad { --tube: #ff6b81; }
.tg-swatch { width: 60px; height: 30px; border-radius: 6px; border: 3px solid #fff; }
.tg-range { width: 90%; }
.tg-hand { width: 200px; height: 200px; border-radius: 30px; background: radial-gradient(#2f4a7a, #1a2540); border: 4px solid #3fb8ff; color: #fff; font-size: 70px; display: flex; flex-direction: column; align-items: center; justify-content: center; touch-action: none; }
.tg-hand div { font-size: 18px; font-weight: bold; }
.tg-hand.held { background: radial-gradient(#3fb8ff, #1c6fc2); box-shadow: 0 0 40px #3fb8ff; }
.tg-keypad-wrap { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; justify-content: center; }
.tg-note { background: #fff59d; color: #333; padding: 14px; border-radius: 4px; transform: rotate(-4deg); box-shadow: 3px 3px 0 rgba(0,0,0,.4); text-align: center; }
.tg-note b { display: block; font-size: 30px; letter-spacing: 4px; font-family: monospace; }
.tg-keypad { display: grid; grid-template-columns: repeat(3, 62px); gap: 8px; background: #0d1222; padding: 12px; border-radius: 12px; }
.tg-display { grid-column: 1 / span 3; height: 44px; background: #052; color: #7f7; font-family: monospace; font-size: 30px; display: flex; align-items: center; justify-content: center; border-radius: 6px; letter-spacing: 6px; }
.tg-display.ok { background: #2ed573; color: #fff; }
.tg-key { height: 54px; border-radius: 8px; border: 2px solid #45507a; background: #2a3352; color: #fff; font-size: 22px; font-weight: bold; }
.tg-switches { display: flex; gap: 16px; }
.tg-switch { width: 50px; height: 110px; border-radius: 10px; border: 3px solid #0b0f1c; background: linear-gradient(180deg, #444 50%, #e74c3c 50%); position: relative; }
.tg-switch.on { background: linear-gradient(180deg, #2ed573 50%, #444 50%); }

/* ===================== MAP + CONSOLES */
#map-modal, #console-modal { position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 55; display: flex; align-items: center; justify-content: center; padding: 10px; }
.map-box, .console-box { background: #131a2e; border: 3px solid var(--line); border-radius: 16px; max-width: 1100px; width: 100%; max-height: 96vh; display: flex; flex-direction: column; overflow: hidden; }
.map-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; font-weight: bold; font-size: 20px; background: #0d1222; }
.map-content { display: flex; gap: 12px; padding: 12px; overflow: auto; }
#map-canvas { width: 100%; max-width: 860px; height: auto; flex: 1; min-width: 0; border-radius: 10px; }
#map-side { display: flex; flex-direction: column; gap: 8px; width: 200px; }
#map-side:empty { display: none; }
.sab-btn { display: flex; align-items: center; gap: 8px; padding: 12px; background: #5b1622; border: 2px solid #a33c4e; color: #fff; border-radius: 10px; font-weight: bold; text-align: left; }
.sab-btn span { font-size: 22px; }
.sab-btn em { margin-left: auto; font-style: normal; font-size: 12px; color: #ffb8c1; }
.sab-btn:disabled { opacity: .45; }
@media (max-width: 700px) { .map-content { flex-direction: column; } #map-side { width: 100%; flex-direction: row; flex-wrap: wrap; } .sab-btn { flex: 1 1 45%; } }
#console-body { padding: 12px; overflow: auto; }
.cams-canvas { display: block; margin: 0 auto; max-width: 100%; max-height: calc(96vh - 90px); width: auto; height: auto; border-radius: 8px; }
.vitals { display: flex; flex-direction: column; gap: 6px; }
.vital { display: grid; grid-template-columns: 48px 1fr 140px 60px; align-items: center; gap: 10px; background: #0d1222; border-radius: 10px; padding: 4px 10px; }
.vital.dead { background: #2a1015; }
.vital .ekg svg { width: 120px; height: 30px; }
.vital polyline { fill: none; stroke: var(--good); stroke-width: 2.5; }
.vital.dead polyline { stroke: var(--bad); }
.vital b { color: var(--good); } .vital.dead b { color: var(--bad); }

/* ===================== MEETING */
#meeting { position: fixed; inset: 0; z-index: 70; background: rgba(0,0,0,.65); display: flex; align-items: center; justify-content: center; padding: 10px; }
.meet-box { display: flex; gap: 12px; width: 100%; max-width: 1180px; height: min(720px, 96vh); }
.meet-main { flex: 1; background: linear-gradient(180deg, #a9b8d6, #8394bb); border: 5px solid #1b2238; border-radius: 18px; padding: 14px; display: flex; flex-direction: column; color: #111; min-width: 0; }
.meet-header { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.meet-header h2 { margin: 0; font-size: clamp(16px, 2.6vw, 26px); }
#meet-timer { font-weight: bold; background: #1b2238; color: #fff; padding: 6px 12px; border-radius: 8px; }
#meet-grid { flex: 1; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin: 12px 0; overflow-y: auto; align-content: start; }
.mcard { position: relative; display: flex; align-items: center; gap: 10px; background: #e8eefc; border: 3px solid #1b2238; border-radius: 12px; padding: 6px 10px; min-height: 72px; }
.can-vote .mcard:not(.dead) { cursor: pointer; }
.can-vote .mcard:not(.dead):hover { background: #fff; transform: translateY(-1px); }
.mcard.me { border-color: #1c7fd6; }
.mcard.dead { background: #9aa3b8; opacity: .7; }
.mcard.dead::after { content: '✖'; position: absolute; left: 22px; top: 8px; font-size: 48px; color: #c0392b; }
.mcard.ejected { box-shadow: 0 0 0 4px var(--bad); }
.mc-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.mc-info b { font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-tag { font-size: 12px; color: #333; }
.mc-votes, #meet-skipvotes { display: flex; flex-wrap: wrap; gap: 3px; }
.vote-chip { width: 16px; height: 16px; border-radius: 50%; border: 2px solid #111; display: inline-block; animation: pop .3s; }
@keyframes pop { from { transform: scale(0); } }
.mc-voted { position: absolute; top: 6px; right: 8px; background: #2ed573; color: #fff; font-size: 11px; font-weight: bold; border-radius: 6px; padding: 2px 6px; }
.mc-confirm { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); display: flex; gap: 6px; }
.mc-confirm button { width: 40px; height: 40px; border-radius: 50%; border: 3px solid #111; font-size: 18px; color: #fff; }
.mc-confirm .yes { background: #27ae60; } .mc-confirm .no { background: #c0392b; }
.meet-footer { display: flex; align-items: center; gap: 12px; }
.meet-chat { width: 320px; background: rgba(15,20,34,.97); border: 3px solid var(--line); border-radius: 18px; display: flex; flex-direction: column; }
@media (max-width: 800px) {
  .meet-box { flex-direction: column; height: 96vh; }
  .meet-chat { width: 100%; height: 38%; }
  #meet-grid { grid-template-columns: repeat(2, 1fr); }
  .mcard { min-height: 60px; padding: 4px 6px; }
  .mcard canvas { width: 44px; height: 44px; }
}

/* ===================== OVERLAYS */
.overlay { position: fixed; inset: 0; z-index: 80; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 16px; }
.overlay.role { background: radial-gradient(ellipse at center, color-mix(in srgb, var(--glow, #3fb8ff) 35%, #000) 0%, #000 70%); animation: fadein .5s; }
@keyframes fadein { from { opacity: 0; } }
.rr-sub { font-size: 22px; color: #ddd; margin-bottom: 18px; }
.rr-team, .go-winners, .clue-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; align-items: center; }
.rr-member, .go-member { display: flex; flex-direction: column; align-items: center; font-weight: bold; }
.rr-role { font-size: clamp(48px, 10vw, 96px); font-weight: bold; margin-top: 10px; text-shadow: 0 0 30px currentColor; animation: zoom .6s; }
@keyframes zoom { from { transform: scale(2.5); opacity: 0; } }
.rr-desc { font-size: 20px; color: #ccd; max-width: 520px; }
.overlay.kill { background: rgba(80,0,0,.85); animation: fadein .2s; }
.kill-scene { display: flex; align-items: center; gap: 10px; }
.kill-slash { font-size: 90px; animation: zoom .3s; }
.kill-text { font-size: 34px; font-weight: bold; margin-top: 10px; }
.kill-text small { display: block; font-size: 16px; font-weight: normal; color: #fcc; margin-top: 6px; }
.overlay.splash { background: rgba(0,0,0,.75); }
.overlay.splash.report { background: radial-gradient(circle, #6b1b1b 0%, #000 80%); }
.overlay.splash.emergency { background: radial-gradient(circle, #6b5a1b 0%, #000 80%); }
.splash-title { font-size: clamp(34px, 7vw, 72px); font-weight: bold; color: #fff; text-shadow: 0 0 20px var(--bad), 4px 4px 0 #000; animation: shake .4s 3; }
@keyframes shake { 25% { transform: translateX(-8px) rotate(-1deg); } 75% { transform: translateX(8px) rotate(1deg); } }
.splash-row { display: flex; gap: 20px; margin: 20px 0; }
.splash-sub { color: #ddd; font-size: 20px; }
.overlay.eject { background: #000; overflow: hidden; background-image: radial-gradient(2px 2px at 10% 20%, #fff 50%, transparent 51%), radial-gradient(1.5px 1.5px at 60% 70%, #fff 50%, transparent 51%), radial-gradient(1px 1px at 80% 30%, #fff 50%, transparent 51%), radial-gradient(2px 2px at 30% 85%, #fff 50%, transparent 51%); background-size: 300px 300px; animation: stars 3s linear infinite; }
@keyframes stars { to { background-position: -300px 0; } }
.eject-body { position: absolute; top: 30%; left: -200px; animation: float 6.5s linear forwards; }
@keyframes float { to { left: 110%; transform: rotate(720deg); } }
.eject-text { font-size: clamp(22px, 4.5vw, 40px); font-weight: bold; min-height: 50px; z-index: 2; }
.eject-sub { font-size: 20px; color: #bbb; margin-top: 10px; z-index: 2; }
.overlay.gameover { background: radial-gradient(ellipse at center, #1a2a4a 0%, #000 75%); overflow-y: auto; justify-content: flex-start; padding-top: 6vh; }
.overlay.gameover.win { background: radial-gradient(ellipse at center, #10482a 0%, #000 75%); }
.overlay.gameover.lose { background: radial-gradient(ellipse at center, #4a1010 0%, #000 75%); }
.go-title { font-size: clamp(56px, 12vw, 120px); font-weight: bold; letter-spacing: 6px; animation: zoom .6s; }
.win .go-title { color: #3fb8ff; text-shadow: 0 0 30px #3fb8ff; }
.lose .go-title { color: var(--bad); text-shadow: 0 0 30px var(--bad); }
.go-reason { font-size: 20px; margin-bottom: 16px; }
.go-roles { margin-top: 18px; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px 18px; width: min(780px, 100%); text-align: left; }
.go-role i { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 6px; }
.go-foot { margin-top: 18px; color: var(--muted); }

/* ===================== MODALS */
.modal { position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 65; display: flex; align-items: center; justify-content: center; padding: 10px; }
.modal-box { background: var(--panel); border: 2px solid var(--line); border-radius: 16px; padding: 16px; width: min(520px, 100%); max-height: 94vh; overflow-y: auto; }
.modal-box.wide { width: min(860px, 100%); }
.modal-head { display: flex; justify-content: space-between; align-items: center; font-size: 22px; font-weight: bold; margin-bottom: 10px; }
.cz { display: flex; gap: 18px; }
.cz-left { display: flex; flex-direction: column; align-items: center; gap: 10px; width: 220px; }
.cz-right { flex: 1; min-width: 0; }
.cz-tabs { display: flex; gap: 6px; margin-bottom: 10px; flex-wrap: wrap; }
.cz-tab { background: var(--panel2); color: var(--text); border: 2px solid var(--line); border-radius: 8px; padding: 8px 14px; font-weight: bold; }
.cz-tab.active { background: var(--accent); border-color: #7fd2ff; color: #000; }
#cz-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; max-height: 52vh; overflow-y: auto; padding: 4px; }
.cz-item { background: #0d1222; border: 3px solid var(--line); border-radius: 12px; display: flex; flex-direction: column; align-items: center; color: var(--muted); padding: 4px; min-height: 84px; justify-content: center; }
.cz-item small { font-size: 11px; }
.cz-item.selected { border-color: var(--accent); box-shadow: 0 0 12px rgba(63,184,255,.6); color: #fff; }
.cz-item.swatch { min-height: 64px; }
.cz-item.taken { opacity: .25; cursor: not-allowed; }
.cz-item.taken::after { content: '✖'; color: #fff; font-size: 26px; }
@media (max-width: 620px) { .cz { flex-direction: column; align-items: center; } .cz-left { width: 100%; } #cz-preview { width: 150px; height: 164px; } }
#settings-body h3 { margin: 18px 0 8px; color: var(--accent); border-bottom: 1px solid var(--line); padding-bottom: 4px; }
.set-row { display: flex; justify-content: space-between; align-items: center; padding: 5px 0; gap: 10px; }
.stepper { display: flex; align-items: center; gap: 6px; }
.stepper button { width: 32px; height: 32px; border-radius: 8px; border: 2px solid var(--line); background: var(--panel2); color: #fff; font-size: 18px; font-weight: bold; }
.stepper button:disabled { opacity: .3; cursor: default; }
.stepper .val { min-width: 70px; text-align: center; font-weight: bold; }
.role-card { background: #0d1222; border: 2px solid var(--line); border-radius: 12px; padding: 10px; margin-bottom: 8px; }
.role-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.role-head p { width: 100%; margin: 2px 0 6px; color: var(--muted); font-size: 13px; }
.team { font-size: 11px; padding: 2px 6px; border-radius: 6px; } .team.crew { background: #1c4f7a; } .team.impostor { background: #7a1c2c; }
.role-steppers { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.mini label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 2px; }
.mini .stepper .val { min-width: 54px; font-size: 14px; }
.player-row { display: flex; align-items: center; gap: 10px; padding: 6px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.pr-name { flex: 1; font-weight: bold; min-width: 120px; }
.tag { font-size: 11px; padding: 2px 6px; border-radius: 6px; margin-left: 4px; background: #333; font-weight: normal; }
.tag.host { background: #8a6d00; } .tag.admin { background: #1c4f7a; } .tag.you { background: #2d6a3e; }
.pr-actions { display: flex; flex-wrap: wrap; gap: 4px; }
.pr-actions button { background: var(--panel2); color: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 4px 8px; font-size: 12px; }
.pr-actions button.warn { background: #5a4313; } .pr-actions button.danger { background: #5b1f2a; }
#picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.pick-item { background: #0d1222; border: 2px solid var(--line); border-radius: 12px; color: #fff; display: flex; flex-direction: column; align-items: center; padding: 6px; }
.clue-or { font-size: 24px; font-weight: bold; color: var(--muted); }
.help ul { padding-left: 20px; line-height: 1.6; } .help h3 { color: var(--accent); margin-bottom: 4px; }

/* toasts */
#toasts { position: fixed; top: 64px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 6px; align-items: center; pointer-events: none; }
.toast { background: rgba(20,26,44,.95); border: 2px solid var(--line); padding: 8px 16px; border-radius: 10px; font-weight: bold; transition: opacity .4s, transform .4s; text-align: center; max-width: 90vw; }
.toast.good { border-color: var(--good); } .toast.bad { border-color: var(--bad); } .toast.warn { border-color: var(--warn); }
.toast.out { opacity: 0; transform: translateY(-10px); }

/* effects */
body.flash::after { content: ''; position: fixed; inset: 0; background: rgba(255,0,0,.4); z-index: 300; pointer-events: none; }
body.crit #hud-top-left #task-list { border: 2px solid var(--bad); }

/* ===================== COOKIES + SHOP */
.cookie-pill { display: inline-flex; align-items: center; gap: 6px; background: linear-gradient(180deg, #7a4a1e, #5a3412); border: 2px solid #c98b45; color: #ffe2b8; border-radius: 999px; padding: 4px 12px; font-weight: bold; font-size: 15px; white-space: nowrap; }
.cookie-pill b { color: #fff; }
#hud-top-right .cookie-pill { height: 44px; }
.modal-head .cookie-pill { margin-left: auto; margin-right: 10px; font-size: 14px; }
.cz-filters { display: flex; gap: 6px; align-items: center; margin-bottom: 8px; flex-wrap: wrap; }
.cz-filter { background: #0d1222; color: var(--muted); border: 2px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: 13px; font-weight: bold; }
.cz-filter.active { color: #fff; border-color: var(--accent); }
#cz-owned-count { margin-left: auto; }
.cz-item { position: relative; }
.cz-price { font-size: 11px; font-weight: bold; margin-top: 2px; color: #ffcf8a; }
.cz-price.free { color: var(--good); }
.cz-price.owned { color: var(--accent); }
.cz-item.locked canvas { filter: saturate(.55) brightness(.8); }
.cz-item.previewing { border-color: #c98b45; box-shadow: 0 0 12px rgba(201,139,69,.7); }
#cz-buy-box { display: flex; flex-direction: column; align-items: center; gap: 6px; background: #0d1222; border: 2px solid #c98b45; border-radius: 12px; padding: 10px; width: 100%; }
#cz-buy-box .btn.primary { background: linear-gradient(180deg, #e0a35a, #a8661f); border-color: #ffcf8a; }
.cz-earn { text-align: center; font-size: 12px; }
.go-cookies { margin-top: 18px; background: rgba(90,52,18,.85); border: 2px solid #c98b45; border-radius: 16px; padding: 12px 24px; text-align: center; animation: zoom .5s; }
.gc-total { font-size: 40px; font-weight: bold; color: #ffe2b8; }
.gc-parts { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; color: #ffcf8a; font-size: 15px; }
.gc-bal { margin-top: 6px; color: #fff; font-size: 14px; }

/* ===================== ACCOUNTS */
.account-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; background: #0d1222; border: 2px solid var(--line); border-radius: 10px; padding: 6px 6px 6px 12px; flex-wrap: wrap; }
.acct-who small { color: var(--muted); }
.acct-form { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.acct-form .btn { margin-top: 6px; }
#acct-status { min-height: 20px; text-align: center; }
.acct-note { font-size: 12px; margin-top: 12px; }

/* ===================== MYSTERY BOXES */
.cz-tab.box-tab { background: linear-gradient(180deg, #7a3fd1, #4b1f8e); border-color: #b48cff; }
.cz-tab.box-tab.active { background: linear-gradient(180deg, #b48cff, #7a3fd1); color: #fff; }
.cz-item.rarity { border-color: var(--rar); box-shadow: inset 0 0 14px color-mix(in srgb, var(--rar) 35%, transparent); }
.cz-price.rar { color: var(--rar); }
#cz-grid.box-mode { display: block; }
.box-panel { display: flex; flex-direction: column; gap: 10px; }
.box-hero { display: flex; gap: 16px; align-items: center; background: linear-gradient(135deg, #2b1650, #12172b); border: 2px solid #7a3fd1; border-radius: 14px; padding: 14px; }
.box-hero h3 { margin: 0 0 4px; font-size: 22px; }
.box-hero p { margin: 0 0 8px; }
.box-art { font-size: 72px; animation: boxbob 1.6s ease-in-out infinite; filter: drop-shadow(0 0 16px #b48cff); }
@keyframes boxbob { 50% { transform: translateY(-6px) rotate(-4deg); } }
.box-odds { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.box-odds span { border: 2px solid var(--rar); color: var(--rar); border-radius: 999px; padding: 2px 10px; font-size: 13px; font-weight: bold; }
.box-open { background: linear-gradient(180deg, #b48cff, #7a3fd1) !important; border-color: #d9c4ff !important; }
.box-loot-head { font-weight: bold; display: flex; justify-content: space-between; }
.box-loot { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.loot-card { --rar: #3498db; display: flex; flex-direction: column; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--rar) 40%, #0d1222), #0d1222 75%); border: 3px solid var(--rar); border-radius: 12px; padding: 6px 4px; text-align: center; min-height: 110px; }
.loot-card small { font-size: 11px; color: #eef2ff; }
.loot-rar { font-size: 11px; font-weight: bold; color: var(--rar); text-transform: uppercase; letter-spacing: .5px; }
.loot-card.unowned canvas { filter: brightness(.55) saturate(.6); }
#box-overlay { position: fixed; inset: 0; z-index: 150; background: radial-gradient(ellipse at center, rgba(60,25,110,.96), rgba(5,5,15,.98)); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 16px; }
.roll-title { font-size: 26px; font-weight: bold; letter-spacing: 1px; }
.roll-wrap { position: relative; width: min(860px, 100%); height: 150px; overflow: hidden; border: 3px solid #b48cff; border-radius: 14px; background: #0a0d18; cursor: pointer; }
.roll-strip { display: flex; position: absolute; left: 0; top: 10px; will-change: transform; }
.roll-strip .loot-card { width: 124px; height: 128px; margin: 0 4px; flex-shrink: 0; }
.roll-marker { position: absolute; left: 50%; top: 0; bottom: 0; width: 4px; margin-left: -2px; background: #ffd32a; box-shadow: 0 0 14px #ffd32a; }
.roll-marker::before, .roll-marker::after { content: ''; position: absolute; left: -8px; border: 10px solid transparent; }
.roll-marker::before { top: -2px; border-top-color: #ffd32a; }
.roll-marker::after { bottom: -2px; border-bottom-color: #ffd32a; }
.roll-reveal { display: flex; flex-direction: column; align-items: center; gap: 10px; animation: zoom .45s; }
.roll-reveal .loot-card { width: 210px; min-height: 230px; box-shadow: 0 0 50px var(--rar); }
.roll-reveal .loot-card small { font-size: 18px; font-weight: bold; }
.rr-rarity { font-size: 40px; font-weight: bold; color: var(--rar); text-shadow: 0 0 20px var(--rar); text-transform: uppercase; letter-spacing: 3px; }
.rr-note { color: #ddd; }
.rr-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }

/* ===================== HIDE TAB */
.menu-row { display: flex; gap: 8px; }
.menu-row .btn { flex: 1; }
#cloak-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; margin-top: 8px; }
.cloak-item { display: flex; align-items: center; gap: 10px; background: #0d1222; border: 2px solid var(--line); border-radius: 10px; padding: 8px 10px; color: var(--text); text-align: left; }
.cloak-item img, .cloak-off { width: 28px; height: 28px; flex-shrink: 0; font-size: 22px; display: flex; align-items: center; justify-content: center; }
.cloak-item span { display: flex; flex-direction: column; min-width: 0; }
.cloak-item small { color: var(--muted); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cloak-item.selected { border-color: var(--accent); box-shadow: 0 0 10px rgba(63,184,255,.5); }

/* ===================== CHAT (v2) */
#chat-panel { width: min(540px, calc(100vw - 24px)); height: min(440px, 58vh); background: linear-gradient(180deg, rgba(22,28,48,.97), rgba(12,16,30,.97)); border: 2px solid #3a4772; border-radius: 16px; box-shadow: 0 12px 40px rgba(0,0,0,.5); overflow: hidden; }
.chat-head { background: rgba(255,255,255,.04); }
.chat-title { font-size: 15px; letter-spacing: .3px; }
.chat-tools { display: flex; gap: 6px; align-items: center; }
.chip-btn { background: #24304f; border: 1px solid #3a4772; color: #fff; border-radius: 8px; height: 28px; padding: 0 8px; font-size: 14px; }
.chat-wrap.people-open .people-toggle { background: var(--accent); border-color: #7fd2ff; }
.chat-body { flex: 1; display: flex; min-height: 0; }
.chat-log { gap: 2px; padding: 10px; }
.chat-people { display: none; width: 132px; flex-shrink: 0; border-left: 1px solid #2c375a; overflow-y: auto; padding: 6px; background: rgba(0,0,0,.18); }
.chat-wrap.people-open .chat-people { display: flex; flex-direction: column; gap: 4px; }
.people-head { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; padding: 2px 4px 4px; }
.person { display: flex; align-items: center; gap: 6px; background: rgba(255,255,255,.04); border: 1px solid transparent; border-left: 4px solid var(--c); border-radius: 8px; padding: 2px 6px 2px 2px; color: #fff; font-size: 13px; font-weight: bold; text-align: left; cursor: pointer; transition: background .12s, transform .08s; }
.person:hover { background: rgba(255,255,255,.12); border-color: var(--c); transform: translateX(-2px); }
.person span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person.me span::after { content: ' (you)'; color: var(--muted); font-weight: normal; }
.person.dead { opacity: .55; }
.chat-msg { display: flex; gap: 8px; align-items: flex-end; background: none; padding: 0; margin-top: 8px; }
.chat-msg.grouped { margin-top: 2px; }
.chat-avatar { width: 36px; flex-shrink: 0; }
.chat-bubble { background: #222c48; border-radius: 4px 14px 14px 14px; padding: 6px 10px; max-width: calc(100% - 50px); box-shadow: 0 1px 0 rgba(0,0,0,.3); }
.chat-msg.grouped .chat-bubble { border-radius: 14px; }
.chat-msg.mine { flex-direction: row-reverse; }
.chat-msg.mine .chat-bubble { background: linear-gradient(180deg, #2f6fd6, #2558b0); border-radius: 14px 4px 14px 14px; }
.chat-msg.ghost .chat-bubble { background: #3a2f5c; font-style: italic; }
.chat-msg.pinged .chat-bubble { box-shadow: 0 0 0 2px #ffd32a, 0 0 14px rgba(255,211,42,.5); }
.chat-meta { font-size: 12px; margin-bottom: 2px; display: flex; gap: 4px; align-items: baseline; }
.chat-meta time { margin-left: auto; padding-left: 10px; color: rgba(255,255,255,.45); font-size: 11px; }
.chat-text { font-size: 14.5px; line-height: 1.35; word-break: break-word; display: block; }
.mention { color: var(--c); font-weight: bold; background: rgba(255,255,255,.08); border-radius: 5px; padding: 0 3px; }
.mention.me { background: rgba(255,211,42,.25); color: #ffe66d; }
.chat-msg.system { justify-content: center; margin: 8px 0 2px; }
.sys-pill { background: rgba(255,255,255,.07); border-radius: 999px; padding: 3px 12px; font-size: 12px; color: var(--muted); font-style: normal; }
.chat-input-row input { border-radius: 999px; }
.meet-chat { background: linear-gradient(180deg, rgba(22,28,48,.98), rgba(12,16,30,.98)); width: 400px; overflow: hidden; }
@media (max-width: 800px) { .meet-chat { width: 100%; } .chat-people { width: 108px; } }

/* ===================== CASE-STYLE CARDS (v2) */
.loot-card { background: linear-gradient(180deg, #3a4150 0%, #252a35 60%, #1c2029 100%); border: 1px solid #4a5263; border-bottom: 6px solid var(--rar); border-radius: 4px; box-shadow: inset 0 -26px 30px -18px color-mix(in srgb, var(--rar) 70%, transparent); }
.loot-card small { font-size: 11px; color: #e6e9ef; margin-top: 2px; }
.loot-rar { font-size: 10px; letter-spacing: 1px; }
.loot-card.special { background: linear-gradient(160deg, #6b4e12 0%, #b8862b 45%, #f3d37a 55%, #8a6418 100%); border-color: #f3d37a; animation: specialshine 2.5s linear infinite; background-size: 200% 200%; }
.loot-card.special small, .loot-card.special .loot-rar { color: #fff7d6; text-shadow: 0 1px 2px #000; }
@keyframes specialshine { 0% { background-position: 0% 0%; } 100% { background-position: 200% 200%; } }
.special-art { display: flex; align-items: center; justify-content: center; color: #fff4c2; text-shadow: 0 0 12px #f7c948, 0 2px 0 #7a5410; font-weight: bold; }
.special-art.plain { color: #cfd6e4; text-shadow: none; filter: grayscale(.3); }
.box-loot .loot-card.special .special-art::after { content: ''; }
.anim-info { grid-column: 1 / -1; background: #0d1222; border: 2px solid #e4ae39; border-radius: 12px; padding: 10px 12px; font-size: 13px; color: #dfe4f0; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }

#box-overlay { background: radial-gradient(ellipse at 50% 40%, rgba(34,38,50,.97), rgba(8,9,13,.99)); }
.roll-title { font-size: 22px; text-transform: uppercase; letter-spacing: 4px; color: #cfd6e4; }
.roll-wrap { height: 168px; border: 2px solid #454d5e; border-radius: 6px; background: linear-gradient(180deg, #1d2129, #14171d); box-shadow: inset 0 0 40px #000; }
.roll-wrap::before, .roll-wrap::after { content: ''; position: absolute; top: 0; bottom: 0; width: 120px; z-index: 2; pointer-events: none; }
.roll-wrap::before { left: 0; background: linear-gradient(90deg, #0b0d11, transparent); }
.roll-wrap::after { right: 0; background: linear-gradient(-90deg, #0b0d11, transparent); }
.roll-strip { top: 12px; }
.roll-strip .loot-card { width: 128px; height: 140px; margin: 0 2px; }
.roll-marker { z-index: 3; width: 3px; margin-left: -1.5px; background: #f7c948; box-shadow: 0 0 10px #f7c948, 0 0 2px #fff; }
.roll-reveal .loot-card { border-bottom-width: 10px; }
.rr-rarity { letter-spacing: 6px; }

/* ===================== KILL ANIMATIONS */
.killanim-canvas { width: min(760px, 96vw); height: auto; border-radius: 14px; border: 3px solid #000; box-shadow: 0 0 60px rgba(255,0,0,.35); }
.killanim-caption { margin-top: 12px; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 22px; }
.killanim-caption span { color: #f7c948; font-weight: bold; letter-spacing: 2px; text-transform: uppercase; font-size: 14px; }
.killanim-caption small { font-size: 15px; color: #fcc; }
.chat-msg.mine, .chat-msg.ghost, .chat-msg.system { background: none; }

/* ===================== EVENTS */
.event-banner { position: relative; display: flex; align-items: center; gap: 12px; max-width: 640px; width: 100%; margin: -8px 0 16px; padding: 10px 14px; border-radius: 14px; border: 2px solid var(--evc); background: linear-gradient(90deg, color-mix(in srgb, var(--evc) 35%, #12162a), #12162a); box-shadow: 0 0 24px color-mix(in srgb, var(--evc) 40%, transparent); }
.event-banner .eb-icon { font-size: 34px; animation: boxbob 2s ease-in-out infinite; }
.event-banner > span:nth-child(2) { display: flex; flex-direction: column; flex: 1; }
.event-banner small { color: #dfe4f0; }
.ev-halloween { --evc: #ff7b1c; } .ev-christmas { --evc: #2ecc71; } .ev-summer { --evc: #ffbe2e; }
body[data-event="halloween"] #screen-menu { background: radial-gradient(ellipse at 50% 30%, #3a1a4a 0%, #0c0612 70%); }
body[data-event="halloween"] .logo span { color: #ff7b1c; }
body[data-event="christmas"] #screen-menu { background: radial-gradient(ellipse at 50% 30%, #12304a 0%, #050b14 70%); }
body[data-event="christmas"] .logo span { color: #ff4757; text-shadow: 0 4px 0 #0a0f22, 0 0 30px rgba(46,204,113,.6); }
body[data-event="summer"] #screen-menu { background: radial-gradient(ellipse at 50% 30%, #1f6f8b 0%, #0a1d2b 70%); }
body[data-event="summer"] .logo span { color: #ffbe2e; }
.cz-tab.event-tab { background: linear-gradient(180deg, #8a4b14, #5c2f0a); border-color: #ffb36b; }
.cz-tab.event-tab.active { background: linear-gradient(180deg, #ffb36b, #ff7b1c); color: #000; }
.event-head { grid-column: 1 / -1; display: flex; gap: 12px; align-items: center; background: linear-gradient(90deg, color-mix(in srgb, var(--evc, #3a4772) 30%, #0d1222), #0d1222); border: 2px solid var(--evc, #3a4772); border-radius: 12px; padding: 10px 12px; }
.event-head h3 { margin: 0 0 2px; }
.event-head p { margin: 0 0 6px; font-size: 13px; color: #dfe4f0; }
.eh-icon { font-size: 40px; }
.ev-tag { position: absolute; top: 3px; left: 4px; font-size: 14px; }
.box-picker { display: flex; gap: 6px; flex-wrap: wrap; }
.box-pick { display: flex; align-items: center; gap: 6px; background: #0d1222; border: 2px solid #3a4772; color: #fff; border-radius: 10px; padding: 6px 12px; font-weight: bold; }
.box-pick span { font-size: 20px; }
.box-pick.active { border-color: #b48cff; background: #2b1650; }
.box-pick.event.active { border-color: #ffb36b; background: #4a2508; }
.box-hero.ev-halloween { background: linear-gradient(135deg, #4a2508, #12172b); border-color: #ff7b1c; }
.box-hero.ev-christmas { background: linear-gradient(135deg, #0e3d22, #12172b); border-color: #2ecc71; }
.box-hero.ev-summer { background: linear-gradient(135deg, #0e4a5c, #12172b); border-color: #ffbe2e; }
.anim-info p { margin: 0; }
