:root {
  --ink: #0b0e11;
  --ink2: #151b21;
  --panel: rgba(13, 18, 24, 0.86);
  --line: #000;
  --red: #ff3b2f;
  --orange: #ff7a18;
  --yellow: #ffd21f;
  --blue: #2e8bff;
  --cyan: #2ee6d6;
  --green: #4be37a;
  --fg: #fff;
  --dim: #a9b6bf;
  --shadow: 0 6px 0 #000;
  --title: "Bangers", "Impact", system-ui, sans-serif;
  --body: "Rubik", system-ui, -apple-system, sans-serif;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--ink); color: var(--fg); font-family: var(--body); overflow: hidden; }
body { -webkit-user-select: none; user-select: none; overscroll-behavior: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input { font: inherit; -webkit-user-select: text; user-select: text; }
img { -webkit-user-drag: none; user-select: none; }
.hidden { display: none !important; }

#app { position: fixed; inset: 0; overflow: hidden; }

/* ── background ── */
.bg { position: absolute; inset: 0; background: #0d1216 center/cover no-repeat; transition: opacity .6s; }
.bg svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.bg.scene { animation: kenburns 24s ease-in-out infinite alternate; }
@keyframes kenburns { from { transform: scale(1.04); } to { transform: scale(1.14) translate(-1.5%, 1%); } }
.bg-dim { position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 40%, rgba(0,0,0,.05), rgba(0,0,0,.65) 80%); pointer-events: none; transition: background .5s; }
.bg-dim.strong { background: radial-gradient(ellipse at 50% 35%, rgba(5,8,12,.45), rgba(5,8,12,.9) 80%); }
.sparks { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.sparks i { position: absolute; bottom: -10px; width: 4px; height: 4px; border-radius: 50%; background: var(--yellow); box-shadow: 0 0 8px 2px rgba(255,190,40,.8); animation: spark linear infinite; opacity: 0; }
@keyframes spark { 0% { transform: translate(0,0); opacity: 0; } 10% { opacity: 1; } 100% { transform: translate(var(--dx), -105vh); opacity: 0; } }

/* ── top bar & nav ── */
.topbar { position: absolute; top: 0; left: 0; right: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; padding: calc(10px + var(--safe-t)) 14px 8px; pointer-events: none; }
.topbar > * { pointer-events: auto; }
.topbar-logo { position: absolute; left: 50%; transform: translateX(-50%); top: calc(6px + var(--safe-t)); pointer-events: none; }
.topbar-logo img { height: 46px; filter: drop-shadow(0 3px 0 #000); }
.icon-btn { width: 44px; height: 44px; border-radius: 14px; background: var(--panel); border: 3px solid #000; display: grid; place-items: center; box-shadow: 0 4px 0 #000; transition: transform .12s; }
.icon-btn:active { transform: translateY(3px); box-shadow: 0 1px 0 #000; }
.icon-btn svg { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

#btn-sound .snd-off { display: none; }
#btn-sound.muted .snd-on { display: none; }
#btn-sound.muted .snd-off { display: block; }

.nav { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(12px + var(--safe-b)); z-index: 30; display: flex; gap: 6px; padding: 6px; background: var(--panel); border: 3px solid #000; border-radius: 22px; box-shadow: 0 6px 0 #000; backdrop-filter: blur(6px); }
.nav button { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 16px; border-radius: 15px; font: 800 11px/1 var(--body); letter-spacing: .06em; color: var(--dim); transition: background .2s, color .2s, transform .15s; }
.nav button svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.nav button.on { background: var(--yellow); color: #111; }
.nav button:active { transform: scale(.92); }

/* ── screens ── */
.screen { position: absolute; inset: 0; z-index: 10; display: none; align-items: center; justify-content: center; padding: calc(70px + var(--safe-t)) 16px calc(96px + var(--safe-b)); }
.screen.active { display: flex; animation: scrIn .45s cubic-bezier(.2,.9,.3,1.2) both; }
.screen.leaving { display: flex; animation: scrOut .3s ease both; pointer-events: none; }
@keyframes scrIn { from { opacity: 0; transform: scale(1.06); } to { opacity: 1; transform: none; } }
@keyframes scrOut { to { opacity: 0; transform: scale(.94); } }

.title { font: 400 34px/1 var(--title); letter-spacing: .04em; margin: 0 0 14px; text-align: center; color: var(--yellow); text-shadow: 3px 3px 0 #000, -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000; }
.title.big { font-size: 46px; transform: rotate(-2deg); }
.sub { color: var(--dim); text-align: center; margin: 0 0 18px; line-height: 1.45; }
.panel { width: min(440px, 100%); background: var(--panel); border: 4px solid #000; border-radius: 26px; padding: 26px 22px; box-shadow: 0 10px 0 #000, inset 0 0 0 2px rgba(255,255,255,.06); backdrop-filter: blur(8px); }
.panel.wide { width: min(560px, 100%); max-height: 100%; overflow: auto; }
.pop-in { animation: popIn .5s cubic-bezier(.2,1.4,.4,1) both; }
@keyframes popIn { from { transform: scale(.6) rotate(-4deg); opacity: 0; } to { transform: none; opacity: 1; } }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 56px; padding: 0 26px; width: 100%; border-radius: 18px; border: 4px solid #000; font: 400 26px/1 var(--title); letter-spacing: .06em; text-decoration: none; box-shadow: 0 6px 0 #000; transition: transform .12s, box-shadow .12s, filter .2s; position: relative; }
.btn:active { transform: translateY(5px); box-shadow: 0 1px 0 #000; }
.btn:disabled { filter: grayscale(.8) brightness(.7); pointer-events: none; }
.btn-yellow { background: linear-gradient(#ffe45a, #ffb800); color: #1a1100; }
.btn-blue { background: linear-gradient(#5fb0ff, #1d6fe0); color: #fff; text-shadow: 2px 2px 0 #000; }
.btn-ghost { background: rgba(255,255,255,.08); color: #fff; }
.btn-link { margin-top: 14px; color: var(--dim); text-decoration: underline; font-weight: 600; }
.row { display: flex; gap: 12px; margin-top: 18px; }
.error { color: #ff7b72; min-height: 1.2em; font-weight: 600; margin: 6px 0; text-align: center; }
.hint { color: var(--dim); font-size: 13px; margin: 6px 0 0; }

input { width: 100%; height: 56px; padding: 0 18px; border-radius: 16px; border: 3px solid #000; background: #fff; color: #111; font-weight: 600; font-size: 18px; outline: none; box-shadow: inset 0 3px 0 rgba(0,0,0,.15); }
input:focus { border-color: var(--yellow); box-shadow: 0 0 0 4px rgba(255,210,31,.35); }
.field-label { display: block; margin: 18px 0 8px; font: 400 20px var(--title); letter-spacing: .08em; color: var(--yellow); }
.auth-form { display: grid; gap: 14px; }
.auth-sent { text-align: center; }
.auth-sent h3 { font: 400 32px var(--title); letter-spacing: .05em; margin: 4px 0; color: var(--green); }
.auth-sent p { color: var(--dim); line-height: 1.45; }
.mail-ico { font-size: 56px; animation: bob 1.4s ease-in-out infinite; }
.auth-test { margin-top: 14px; padding: 14px; border-radius: 16px; border: 3px dashed rgba(255,255,255,.25); }
.auth-test p { font-size: 14px; margin: 0 0 12px; }
@keyframes bob { 50% { transform: translateY(-8px) rotate(-6deg); } }

/* ── splash ── */
#scr-splash { z-index: 50; background: radial-gradient(circle at 50% 50%, #2a1407 0%, #0b0e11 70%); flex-direction: column; }
.splash-logo { width: min(86vw, 640px); filter: drop-shadow(0 10px 0 #000) drop-shadow(0 0 40px rgba(255,120,20,.45)); animation: logoIn 1.1s cubic-bezier(.2,1.5,.35,1) both; position: relative; z-index: 2; }
.splash-tag { margin-top: 18px; font: 400 clamp(18px, 4vw, 26px) var(--title); letter-spacing: .3em; color: var(--yellow); text-shadow: 2px 2px 0 #000; animation: fadeUp .6s .9s both; }
.splash-burst { position: absolute; width: 160vmax; height: 160vmax; background: repeating-conic-gradient(from 0deg, rgba(255,140,30,.13) 0 8deg, transparent 8deg 20deg); animation: spin 18s linear infinite, fadeIn 1s .3s both; }
@keyframes logoIn { 0% { transform: scale(3.2) rotate(-12deg); opacity: 0; filter: blur(10px); } 55% { transform: scale(.88) rotate(2deg); opacity: 1; filter: blur(0); } 70% { transform: scale(1.08) rotate(-1deg); } 100% { transform: scale(1); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
.flying-logo { position: fixed; z-index: 60; pointer-events: none; transition: all .9s cubic-bezier(.7,0,.2,1); filter: drop-shadow(0 6px 0 #000); }

/* ── home ── */
.home-wrap { display: flex; flex-direction: column; align-items: center; gap: 18px; width: min(460px, 100%); }
.home-logo { width: min(92vw, 620px); filter: drop-shadow(0 8px 0 #000) drop-shadow(0 0 30px rgba(255,120,20,.4)); animation: floaty 4s ease-in-out infinite; }
@keyframes floaty { 50% { transform: translateY(-8px) rotate(-1deg); } }
.btn-play { position: relative; width: min(300px, 80vw); height: 96px; border-radius: 28px; border: 5px solid #000; background: linear-gradient(#ff6a3d, #e21d12); box-shadow: 0 9px 0 #000, 0 0 50px rgba(255,60,30,.55); animation: pulse 1.6s ease-in-out infinite; transition: transform .12s; }
.btn-play span { font: 400 58px/1 var(--title); letter-spacing: .08em; color: #fff; text-shadow: 4px 4px 0 #000; }
.btn-play::after { content: ""; position: absolute; inset: 8px 14px auto; height: 22px; border-radius: 20px; background: rgba(255,255,255,.35); }
.btn-play:active { transform: translateY(7px) scale(.98); box-shadow: 0 2px 0 #000; animation: none; }
@keyframes pulse { 50% { transform: scale(1.05); box-shadow: 0 9px 0 #000, 0 0 80px rgba(255,80,30,.85); } }
.online-pill { display: flex; align-items: center; gap: 8px; padding: 8px 14px; background: var(--panel); border: 3px solid #000; border-radius: 30px; font-weight: 600; font-size: 14px; color: var(--dim); }
.online-pill span { color: #fff; font-weight: 800; }
.online-pill i, .room-online i { width: 10px; height: 10px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .35; } }

.player-card { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 14px; background: var(--panel); border: 3px solid #000; border-radius: 20px; box-shadow: 0 5px 0 #000; animation: fadeUp .5s both; }
.player-card .av { width: 58px; height: 58px; }
.pc-info { flex: 1; min-width: 0; }
.pc-name { font: 800 18px var(--body); display: flex; gap: 8px; align-items: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lvl { display: inline-grid; place-items: center; min-width: 30px; height: 24px; padding: 0 7px; border-radius: 8px; background: var(--yellow); color: #111; font: 900 13px var(--body); border: 2px solid #000; }
.av { border-radius: 16px; border: 3px solid #000; object-fit: cover; background: #222; box-shadow: 0 3px 0 #000; flex: none; }

.xp-bar { position: relative; height: 14px; border-radius: 10px; background: #000; border: 2px solid #000; overflow: hidden; margin-top: 6px; }
.xp-bar.big { height: 26px; border-width: 3px; border-radius: 14px; }
.xp-fill { position: absolute; inset: 0 auto 0 0; width: 0%; background: linear-gradient(90deg, #ffb800, #ffe45a); box-shadow: inset 0 -4px 0 rgba(0,0,0,.2), 0 0 14px rgba(255,210,31,.6); transition: width .9s cubic-bezier(.3,1.3,.5,1); border-radius: 8px; }
.xp-ticks { position: absolute; inset: 0; display: flex; justify-content: space-evenly; pointer-events: none; }
.xp-ticks i { width: 2px; background: rgba(0,0,0,.55); }
.xp-txt { font-size: 12px; color: var(--dim); margin-top: 4px; font-weight: 600; }

/* ── avatars grid ── */
.avatar-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.avatar-grid button { position: relative; aspect-ratio: 1; border-radius: 18px; overflow: hidden; border: 4px solid #000; box-shadow: 0 4px 0 #000; transition: transform .15s; }
.avatar-grid button img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar-grid button:active { transform: scale(.94); }
.avatar-grid button.sel { border-color: var(--yellow); transform: scale(1.06); box-shadow: 0 0 0 4px #000, 0 0 24px rgba(255,210,31,.8); z-index: 1; }
.avatar-grid button.sel::after { content: "✓"; position: absolute; right: 4px; top: 2px; width: 26px; height: 26px; border-radius: 50%; background: var(--yellow); color: #000; font-weight: 900; display: grid; place-items: center; border: 2px solid #000; }

/* ── rooms ── */
.rooms-wrap { width: min(520px, 100%); display: grid; gap: 18px; }
.room-card { position: relative; display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: 26px; border: 4px solid #000; box-shadow: 0 8px 0 #000; text-align: left; overflow: hidden; transition: transform .15s; animation: popIn .5s cubic-bezier(.2,1.4,.4,1) both; }
.room-card:nth-child(3) { animation-delay: .1s; }
.room-card:hover { transform: translateY(-3px) rotate(-.5deg); }
.room-card:active { transform: translateY(6px); box-shadow: 0 2px 0 #000; }
.room-card::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(-45deg, rgba(255,255,255,.06) 0 14px, transparent 14px 28px); }
.room-one { background: linear-gradient(135deg, #ff5a2e, #b3120a); }
.room-bo3 { background: linear-gradient(135deg, #3a8dff, #1a3fb0); }
.room-ico { position: relative; width: 86px; height: 86px; flex: none; display: grid; place-items: center; border-radius: 20px; background: rgba(0,0,0,.3); border: 3px solid #000; }
.room-ico img { width: 120%; transform: rotate(-35deg); filter: drop-shadow(0 3px 0 #000); }
.room-ico.tri img { position: absolute; width: 76%; }
.room-ico.tri img:nth-child(1) { transform: translate(-14px, -12px) rotate(-40deg); }
.room-ico.tri img:nth-child(2) { transform: translate(10px, 0) rotate(-20deg); }
.room-ico.tri img:nth-child(3) { transform: translate(-6px, 16px) rotate(-55deg); }
.room-txt { position: relative; flex: 1; }
.room-name { font: 400 32px/1 var(--title); letter-spacing: .05em; text-shadow: 3px 3px 0 #000; }
.room-desc { font-weight: 600; margin: 6px 0; font-size: 15px; }
.room-stake { font-size: 12px; font-weight: 800; color: rgba(255,255,255,.85); }
.room-stake .up { color: #b6ffcb; } .room-stake .down { color: #ffd0cc; }
.room-online { position: absolute; top: 10px; right: 12px; display: flex; gap: 6px; align-items: center; font-size: 12px; font-weight: 800; background: rgba(0,0,0,.35); padding: 4px 9px; border-radius: 20px; }

/* ── search ── */
.search-wrap { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; width: min(440px, 100%); }
.radar { position: relative; width: 230px; height: 230px; margin-bottom: 16px; }
.radar-ring { position: absolute; inset: 0; border-radius: 50%; border: 3px solid rgba(255,210,31,.55); animation: ring 2.4s ease-out infinite; }
.radar-ring.r2 { animation-delay: .8s; } .radar-ring.r3 { animation-delay: 1.6s; }
@keyframes ring { from { transform: scale(.35); opacity: 1; } to { transform: scale(1.15); opacity: 0; } }
.radar-sweep { position: absolute; inset: 8px; border-radius: 50%; background: conic-gradient(from 0deg, rgba(255,210,31,.45), transparent 25%); animation: spin 1.6s linear infinite; border: 3px solid rgba(0,0,0,.6); }
.radar-me { position: absolute; left: 50%; top: 50%; width: 96px; height: 96px; margin: -48px; border-radius: 50%; border: 4px solid #000; box-shadow: 0 0 0 4px var(--yellow), 0 0 40px rgba(255,210,31,.6); object-fit: cover; }
.radar.found .radar-sweep { animation-duration: .3s; }
.search-mode { font: 900 13px var(--body); letter-spacing: .2em; color: #111; background: var(--yellow); padding: 4px 12px; border-radius: 8px; border: 2px solid #000; }
.search-title { font: 400 30px/1.05 var(--title); letter-spacing: .05em; margin: 0; text-shadow: 3px 3px 0 #000; }
.search-title.found { color: var(--green); animation: slam .4s cubic-bezier(.2,1.6,.4,1) both; }
.dots i { animation: blink 1s infinite; font-style: normal; } .dots i:nth-child(2) { animation-delay: .2s; } .dots i:nth-child(3) { animation-delay: .4s; }
.search-time { font: 800 22px var(--body); color: var(--dim); font-variant-numeric: tabular-nums; }
.search-tip { color: var(--dim); font-size: 14px; min-height: 3em; max-width: 340px; }
#search-cancel { width: auto; min-height: 46px; font-size: 20px; }
@keyframes slam { from { transform: scale(2.2); opacity: 0; } to { transform: none; opacity: 1; } }

/* ── VS ── */
#scr-vs { padding: 0; z-index: 40; }
.vs-side { position: absolute; top: 0; bottom: 0; width: 58%; display: flex; flex-direction: column; justify-content: center; gap: 10px; padding: 0 7%; }
.vs-left { left: 0; background: linear-gradient(135deg, #ff4b23, #8c0d05); clip-path: polygon(0 0, 100% 0, 72% 100%, 0 100%); align-items: flex-start; animation: vsL .55s cubic-bezier(.2,1.2,.3,1) both; }
.vs-right { right: 0; background: linear-gradient(225deg, #3d8dff, #0b2c86); clip-path: polygon(28% 0, 100% 0, 100% 100%, 0 100%); align-items: flex-end; text-align: right; animation: vsR .55s cubic-bezier(.2,1.2,.3,1) both; }
.vs-side::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(-60deg, rgba(255,255,255,.07) 0 10px, transparent 10px 30px); }
.vs-side > * { position: relative; }
.vs-side .av { width: min(34vw, 190px); height: min(34vw, 190px); border-width: 5px; border-radius: 28px; box-shadow: 0 8px 0 #000; }
.vs-name { font: 400 clamp(26px, 6vw, 46px)/1 var(--title); letter-spacing: .04em; text-shadow: 3px 3px 0 #000; word-break: break-all; }
.vs-meta { display: flex; gap: 8px; align-items: center; font-weight: 800; font-size: 15px; }
.vs-right .vs-meta { justify-content: flex-end; }
.flag { font-size: 1.25em; line-height: 1; }
.vs-mark { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font: 400 clamp(90px, 22vw, 180px)/1 var(--title); color: var(--yellow); -webkit-text-stroke: 5px #000; text-shadow: 8px 8px 0 #000; animation: vsMark .5s .45s cubic-bezier(.2,1.8,.4,1) both; z-index: 2; }
.vs-flash { position: absolute; inset: 0; background: #fff; opacity: 0; animation: flash .5s .5s both; pointer-events: none; }
@keyframes vsL { from { transform: translateX(-100%); } }
@keyframes vsR { from { transform: translateX(100%); } }
@keyframes vsMark { from { transform: translate(-50%, -50%) scale(4) rotate(-20deg); opacity: 0; } to { transform: translate(-50%, -50%) scale(1) rotate(-6deg); opacity: 1; } }
@keyframes flash { 0% { opacity: .9; } 100% { opacity: 0; } }

/* ── FIGHT ── */
#scr-fight { padding: calc(8px + var(--safe-t)) 0 calc(12px + var(--safe-b)); flex-direction: column; justify-content: space-between; }
.hud { position: relative; z-index: 3; width: 100%; max-width: 900px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; padding: 0 10px; }
.hud-p { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 6px 8px; background: var(--panel); border: 3px solid #000; border-radius: 16px; box-shadow: 0 4px 0 #000; }
.hud-op { flex-direction: row-reverse; text-align: right; }
.hud-p .av { width: 46px; height: 46px; border-radius: 12px; }
.hud-me .av { border-color: var(--red); } .hud-op .av { border-color: var(--blue); }
.hud-txt { min-width: 0; }
.hud-name { font: 800 14px var(--body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hud-sub { display: flex; gap: 5px; align-items: center; font-size: 12px; font-weight: 700; color: var(--dim); }
.hud-op .hud-sub { justify-content: flex-end; }
.pips { display: flex; gap: 4px; margin-top: 3px; }
.hud-op .pips { justify-content: flex-end; }
.pips i { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #000; background: rgba(255,255,255,.15); transition: background .3s, transform .3s; }
.hud-me .pips i.on { background: var(--red); box-shadow: 0 0 10px var(--red); transform: scale(1.15); }
.hud-op .pips i.on { background: var(--blue); box-shadow: 0 0 10px var(--blue); transform: scale(1.15); }
.hud-score { text-align: center; }
.hud-mode { font: 900 10px var(--body); letter-spacing: .16em; background: var(--yellow); color: #111; padding: 2px 8px; border-radius: 6px; border: 2px solid #000; display: inline-block; }
.score { font: 400 50px/1 var(--title); letter-spacing: .02em; text-shadow: 4px 4px 0 #000; display: flex; gap: 8px; justify-content: center; align-items: center; margin: 2px 0; }
.score em { font-style: normal; color: var(--yellow); font-size: 36px; }
.score span { display: inline-block; min-width: 30px; }
.score span.bump { animation: bump .6s cubic-bezier(.2,1.8,.4,1); color: var(--yellow); }
@keyframes bump { 0% { transform: scale(2.4); } 100% { transform: scale(1); } }
.hud-round { font: 400 18px var(--title); letter-spacing: .1em; color: #fff; text-shadow: 2px 2px 0 #000; }

.stage { position: relative; flex: 1; width: 100%; max-width: 1000px; min-height: 0; }
.arm { position: absolute; top: 50%; width: min(48vw, 460px); transition: transform .18s; will-change: transform; }
.arm img { width: 100%; display: block; filter: drop-shadow(0 8px 0 rgba(0,0,0,.55)); }
.arm-me { left: -4%; transform-origin: 0% 50%; transform: translateY(-50%) rotate(-8deg); }
.arm-op { right: -4%; transform-origin: 100% 50%; transform: translateY(-50%) scaleX(-1) rotate(-8deg); }
.arm-me.shake { animation: shakeMe .6s ease-in-out 3; }
.arm-op.shake { animation: shakeOp .6s ease-in-out 3; }
@keyframes shakeMe { 0%, 100% { transform: translateY(-50%) rotate(-8deg); } 45% { transform: translateY(-78%) rotate(-24deg); } }
@keyframes shakeOp { 0%, 100% { transform: translateY(-50%) scaleX(-1) rotate(-8deg); } 45% { transform: translateY(-78%) scaleX(-1) rotate(-24deg); } }
.arm-me.strike { animation: strikeMe .35s cubic-bezier(.2,1.6,.4,1) forwards; }
.arm-op.strike { animation: strikeOp .35s cubic-bezier(.2,1.6,.4,1) forwards; }
@keyframes strikeMe { 0% { transform: translateY(-50%) translateX(-10%) rotate(-10deg); } 100% { transform: translateY(-50%) translateX(8%) rotate(0deg); } }
@keyframes strikeOp { 0% { transform: translateY(-50%) scaleX(-1) translateX(-10%) rotate(-10deg); } 100% { transform: translateY(-50%) scaleX(-1) translateX(8%) rotate(0deg); } }
.arm-me.knock { animation: knockMe .6s ease-out forwards; }
.arm-op.knock { animation: knockOp .6s ease-out forwards; }
@keyframes knockMe { 0% { transform: translateY(-50%) translateX(8%); } 30% { transform: translateY(-45%) translateX(-12%) rotate(14deg); filter: brightness(2); } 100% { transform: translateY(-40%) translateX(-14%) rotate(18deg); filter: grayscale(.7) brightness(.7); } }
@keyframes knockOp { 0% { transform: translateY(-50%) scaleX(-1) translateX(8%); } 30% { transform: translateY(-45%) scaleX(-1) translateX(-12%) rotate(14deg); filter: brightness(2); } 100% { transform: translateY(-40%) scaleX(-1) translateX(-14%) rotate(18deg); filter: grayscale(.7) brightness(.7); } }
.arm-me.winpose { animation: winMe .8s ease-in-out infinite alternate; transform: translateY(-50%) translateX(8%); }
.arm-op.winpose { animation: winOp .8s ease-in-out infinite alternate; transform: translateY(-50%) scaleX(-1) translateX(8%); }
@keyframes winMe { to { transform: translateY(-56%) translateX(10%) rotate(-4deg); filter: drop-shadow(0 0 16px rgba(255,210,31,.9)); } }
@keyframes winOp { to { transform: translateY(-56%) scaleX(-1) translateX(10%) rotate(-4deg); filter: drop-shadow(0 0 16px rgba(255,210,31,.9)); } }

.impact { position: absolute; left: 50%; top: 50%; width: 260px; height: 260px; margin: -130px; pointer-events: none; opacity: 0; background: radial-gradient(circle, #fff 0 12%, var(--yellow) 13% 30%, var(--orange) 31% 42%, transparent 43%); clip-path: polygon(50% 0, 61% 30%, 95% 15%, 72% 45%, 100% 55%, 68% 64%, 82% 98%, 52% 72%, 26% 100%, 34% 66%, 0 70%, 28% 48%, 6% 20%, 40% 32%); }
.impact.go { animation: impact .45s ease-out; }
@keyframes impact { 0% { opacity: 1; transform: scale(.2) rotate(0); } 60% { opacity: 1; transform: scale(1.15) rotate(12deg); } 100% { opacity: 0; transform: scale(1.4) rotate(18deg); } }
.op-status { position: absolute; right: 14px; top: 8px; padding: 6px 12px; border-radius: 12px; background: var(--panel); border: 3px solid #000; font-weight: 800; font-size: 13px; color: var(--dim); }
.op-status.done { color: var(--green); }
.op-status i { font-style: normal; animation: blink 1s infinite; } .op-status i:nth-child(2) { animation-delay: .2s; } .op-status i:nth-child(3) { animation-delay: .4s; }
.callout { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font: 400 clamp(54px, 13vw, 120px)/1 var(--title); letter-spacing: .03em; color: #fff; -webkit-text-stroke: 3px #000; text-shadow: 6px 6px 0 #000; white-space: nowrap; pointer-events: none; z-index: 4; opacity: 0; }
.callout.show { animation: callout 1s cubic-bezier(.2,1.6,.4,1) forwards; }
.callout.stay { animation: calloutIn .45s cubic-bezier(.2,1.6,.4,1) forwards; }
.callout.win { color: var(--yellow); } .callout.lose { color: #ff6b5e; } .callout.draw { color: #bfe7ff; } .callout.small { font-size: clamp(40px, 9vw, 80px); }
@keyframes callout { 0% { opacity: 0; transform: translate(-50%, -50%) scale(3) rotate(-10deg); } 25% { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(-4deg); } 80% { opacity: 1; transform: translate(-50%, -50%) scale(1.05) rotate(-4deg); } 100% { opacity: 0; transform: translate(-50%, -50%) scale(.9) rotate(-4deg); } }
@keyframes calloutIn { 0% { opacity: 0; transform: translate(-50%, -50%) scale(3) rotate(-10deg); } 100% { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(-4deg); } }

.timer { position: absolute; z-index: 4; left: 50%; top: calc(108px + var(--safe-t)); transform: translateX(-50%); width: 64px; height: 64px; display: grid; place-items: center; }
.timer svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.timer .t-bg { fill: rgba(10,14,18,.9); stroke: #000; stroke-width: 5; }
.timer .t-fg { fill: none; stroke: var(--yellow); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 119.4; stroke-dashoffset: 0; transition: stroke-dashoffset 1s linear, stroke .3s; }
.timer span { position: relative; font: 400 30px var(--title); text-shadow: 2px 2px 0 #000; }
.timer.urgent .t-fg { stroke: var(--red); }
.timer.urgent span { color: #ff6b5e; animation: tick .5s ease-in-out infinite; }
.timer.off { opacity: 0; transform: translateX(-50%) scale(.5); transition: all .3s; }
@keyframes tick { 50% { transform: scale(1.25); } }

.moves { position: relative; z-index: 3; display: flex; gap: 10px; justify-content: center; padding: 0 10px; width: 100%; max-width: 620px; }
.move { flex: 1; min-width: 0; overflow: hidden; max-width: 190px; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 6px 10px; border-radius: 22px; border: 4px solid #000; background: linear-gradient(#2b3946, #18222b); box-shadow: 0 7px 0 #000; transition: transform .14s, box-shadow .14s, background .2s, opacity .3s, filter .3s; }
.move img { width: 92%; height: 58px; object-fit: contain; transform: rotate(-8deg); filter: drop-shadow(0 3px 0 #000); transition: transform .2s; }
.move span { font: 400 22px var(--title); letter-spacing: .07em; text-shadow: 2px 2px 0 #000; }
.move:hover img { transform: rotate(-8deg) scale(1.08); }
.move:active { transform: translateY(6px); box-shadow: 0 1px 0 #000; }
.move.sel { background: linear-gradient(#ffe45a, #ffb800); color: #111; transform: translateY(-6px) scale(1.04); box-shadow: 0 12px 0 #000, 0 0 30px rgba(255,210,31,.7); }
.move.sel span { text-shadow: none; }
.moves.locked .move:not(.sel) { opacity: .4; filter: grayscale(.6); }
.moves.locked { pointer-events: none; }
.moves.hide { opacity: 0; transform: translateY(40px); transition: all .3s; pointer-events: none; }
.moves { transition: opacity .3s, transform .3s; }

.screen-shake { animation: screenShake .4s cubic-bezier(.36,.07,.19,.97); }
@keyframes screenShake { 10%, 90% { transform: translate(-2px, 1px); } 20%, 80% { transform: translate(5px, -3px); } 30%, 50%, 70% { transform: translate(-8px, 4px); } 40%, 60% { transform: translate(8px, -2px); } }

/* ── RESULT ── */
#scr-result { z-index: 35; }
.confetti { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.crack { position: absolute; inset: 0; pointer-events: none; opacity: 0; background:
  linear-gradient(115deg, transparent 49.6%, rgba(255,255,255,.55) 49.8% 50.1%, transparent 50.3%),
  linear-gradient(62deg, transparent 49.7%, rgba(255,255,255,.4) 49.85% 50.05%, transparent 50.2%),
  linear-gradient(170deg, transparent 49.7%, rgba(255,255,255,.35) 49.85% 50.05%, transparent 50.2%); }
.crack.on { animation: crack .5s ease-out forwards; }
@keyframes crack { 0% { opacity: 0; transform: scale(1.2); } 30% { opacity: 1; } 100% { opacity: .75; transform: none; } }
.result-wrap { position: relative; z-index: 2; width: min(460px, 100%); display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; }
.result-title { margin: 0; font: 400 clamp(76px, 20vw, 140px)/.9 var(--title); letter-spacing: .03em; -webkit-text-stroke: 4px #000; text-shadow: 8px 8px 0 #000; animation: resIn .7s cubic-bezier(.2,1.6,.4,1) both; }
.result-title.win { color: var(--yellow); filter: drop-shadow(0 0 30px rgba(255,190,30,.7)); }
.result-title.lose { color: #ff5246; animation: resLose .9s cubic-bezier(.2,1.2,.4,1) both; }
@keyframes resIn { from { transform: scale(4) rotate(-15deg); opacity: 0; } to { transform: rotate(-4deg); opacity: 1; } }
@keyframes resLose { 0% { transform: translateY(-120%) rotate(0); opacity: 0; } 60% { transform: translateY(6%) rotate(5deg); opacity: 1; } 100% { transform: rotate(3deg); } }
.result-score { font: 400 64px/1 var(--title); text-shadow: 4px 4px 0 #000; animation: fadeUp .5s .4s both; }
.result-vs { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 10px; font-weight: 800; color: var(--dim); animation: fadeUp .5s .5s both; }
.result-vs .av { width: 40px; height: 40px; border-radius: 10px; }
.xp-box { width: 100%; padding: 16px; background: var(--panel); border: 4px solid #000; border-radius: 22px; box-shadow: 0 7px 0 #000; animation: fadeUp .5s .6s both; }
.xp-head { display: flex; justify-content: space-between; align-items: center; font: 400 26px var(--title); letter-spacing: .06em; }
.xp-head b { font-weight: 400; } .xp-head b.up { color: var(--green); } .xp-head b.down { color: #ff7b72; } .xp-head b.zero { color: var(--dim); }
.xp-sub { margin-top: 6px; font-weight: 700; color: var(--dim); font-size: 14px; }
.levelup { font: 400 54px/1 var(--title); color: var(--cyan); -webkit-text-stroke: 3px #000; text-shadow: 5px 5px 0 #000, 0 0 40px rgba(46,230,214,.8); animation: lvl 1s cubic-bezier(.2,1.8,.4,1) both, lvlGlow 1.2s 1s ease-in-out infinite alternate; }
@keyframes lvl { from { transform: scale(0) rotate(-30deg); } to { transform: scale(1) rotate(-3deg); } }
@keyframes lvlGlow { to { transform: scale(1.08) rotate(-3deg); } }
.result-btns { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; width: 100%; margin-top: 6px; animation: fadeUp .5s .8s both; }

/* ── ranking & profile ── */
.list-wrap { width: min(560px, 100%); height: 100%; display: flex; flex-direction: column; }
#scr-ranking, #scr-profile { align-items: stretch; }
.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 8px; margin-bottom: 12px; }
.pod { display: flex; flex-direction: column; align-items: center; gap: 6px; animation: popIn .5s cubic-bezier(.2,1.4,.4,1) both; }
.pod .av { width: 64px; height: 64px; }
.pod.p1 .av { width: 82px; height: 82px; border-color: var(--yellow); box-shadow: 0 0 0 3px #000, 0 0 26px rgba(255,210,31,.7); }
.pod-name { font-weight: 800; font-size: 13px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pod-block { width: 100%; border: 3px solid #000; border-radius: 14px 14px 6px 6px; display: grid; place-items: center; font: 400 34px var(--title); text-shadow: 3px 3px 0 #000; box-shadow: 0 5px 0 #000; }
.p1 .pod-block { height: 86px; background: linear-gradient(#ffe45a, #e8a400); }
.p2 .pod-block { height: 64px; background: linear-gradient(#e7eef3, #9aa8b3); }
.p3 .pod-block { height: 50px; background: linear-gradient(#ffb27a, #c0662d); }
.p1 { animation-delay: .1s; } .p3 { animation-delay: .2s; }
.rank-list { list-style: none; margin: 0; padding: 0 2px 8px; overflow-y: auto; flex: 1; min-height: 0; display: grid; gap: 7px; align-content: start; }
.rank-row { display: flex; align-items: center; gap: 10px; padding: 8px 12px; background: var(--panel); border: 3px solid #000; border-radius: 16px; animation: fadeUp .35s both; }
.rank-row.me { background: linear-gradient(90deg, rgba(255,210,31,.35), rgba(13,18,24,.9)); border-color: var(--yellow); }
.rank-n { width: 32px; font: 400 22px var(--title); text-align: center; color: var(--dim); }
.rank-row .av { width: 40px; height: 40px; border-radius: 11px; border-width: 2px; }
.rank-name { flex: 1; min-width: 0; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-xp { font-size: 12px; color: var(--dim); font-weight: 700; }
.rank-me { margin-top: 8px; }
.rank-me .rank-row { box-shadow: 0 5px 0 #000; }

.profile-head { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; margin-bottom: 16px; }
.profile-head .av { width: 120px; height: 120px; border-radius: 30px; border-width: 5px; box-shadow: 0 7px 0 #000, 0 0 0 4px var(--yellow); animation: popIn .5s both; cursor: pointer; }
.pf-name { font: 400 40px/1 var(--title); letter-spacing: .04em; text-shadow: 3px 3px 0 #000; }
.pf-mail { color: var(--dim); font-size: 13px; }
.pf-xp { width: 100%; max-width: 380px; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat { padding: 12px 6px; text-align: center; background: var(--panel); border: 3px solid #000; border-radius: 18px; box-shadow: 0 5px 0 #000; animation: popIn .45s both; }
.stat b { display: block; font: 400 36px/1 var(--title); color: var(--yellow); text-shadow: 2px 2px 0 #000; }
.stat span { font-size: 11px; font-weight: 800; letter-spacing: .08em; color: var(--dim); }
.profile-actions { display: grid; gap: 12px; margin-top: 18px; }

/* ── modal, toast ── */
.modal { position: absolute; inset: 0; z-index: 70; display: grid; place-items: center; padding: 16px; background: rgba(0,0,0,.7); backdrop-filter: blur(4px); }
.toast { position: absolute; left: 50%; bottom: calc(100px + var(--safe-b)); transform: translate(-50%, 30px); z-index: 80; padding: 12px 18px; border-radius: 16px; background: #fff; color: #111; font-weight: 800; border: 3px solid #000; box-shadow: 0 5px 0 #000; opacity: 0; pointer-events: none; transition: all .3s cubic-bezier(.2,1.4,.4,1); max-width: 90vw; text-align: center; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }
.tap-hint { position: absolute; bottom: calc(24px + var(--safe-b)); left: 50%; transform: translateX(-50%); z-index: 55; font-weight: 800; color: var(--dim); animation: blink 1.6s infinite; font-size: 14px; }

/* ── responsive ── */
@media (min-width: 900px) {
  .arm { width: 440px; }
  .move img { height: 78px; }
}
@media (max-height: 700px) {
  .home-logo { width: min(80vw, 440px); }
  .btn-play { height: 80px; } .btn-play span { font-size: 48px; }
  .radar { width: 170px; height: 170px; }
  .score { font-size: 40px; }
  .move img { height: 48px; }
  .timer { top: calc(96px + var(--safe-t)); width: 54px; height: 54px; }
}
@media (max-width: 420px) {
  .hud-p .av { width: 38px; height: 38px; }
  .hud-name { font-size: 12px; }
  .score { font-size: 40px; }
  .room-name { font-size: 26px; }
  .room-ico { width: 70px; height: 70px; }
  .avatar-grid { gap: 8px; }
  .stat b { font-size: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ── forfeit ── */
.btn-forfeit { position: absolute; left: 14px; top: 8px; z-index: 5; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 12px; background: var(--panel); border: 3px solid #000; box-shadow: 0 4px 0 #000; color: #ffb3ad; font: 800 12px var(--body); letter-spacing: .12em; transition: transform .12s, opacity .2s; }
.btn-forfeit svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linejoin: round; }
.btn-forfeit:hover { background: rgba(160,20,10,.7); color: #fff; }
.btn-forfeit:active { transform: scale(.92); }
.btn-forfeit:disabled { opacity: .35; pointer-events: none; }
.btn-red { background: linear-gradient(#ff6a3d, #d81b10); color: #fff; text-shadow: 2px 2px 0 #000; }
.confirm-panel { text-align: center; }
.confirm-ico { font-size: 48px; animation: bob 1.4s ease-in-out infinite; }
.confirm-panel .row .btn { font-size: 22px; padding: 0 12px; }
.forfeit-note { width: 100%; color: #ffb3ad; font-weight: 700; }

/* ── sound settings ── */
.sound-pop { position: absolute; z-index: 45; top: calc(64px + var(--safe-t)); left: 14px; display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: var(--panel); border: 3px solid #000; border-radius: 16px; box-shadow: 0 5px 0 #000; backdrop-filter: blur(6px); animation: popIn .3s cubic-bezier(.2,1.4,.4,1) both; }
.snd-toggle { width: 36px; height: 36px; border-radius: 10px; background: rgba(255,255,255,.08); border: 2px solid #000; font-size: 18px; display: grid; place-items: center; }
.sound-pop input[type=range] { -webkit-appearance: none; appearance: none; width: 170px; height: 12px; padding: 0; border-radius: 8px; border: 2px solid #000; box-shadow: none; background: linear-gradient(90deg, var(--yellow) var(--p, 80%), #000 var(--p, 80%)); cursor: pointer; }
.sound-pop input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 3px solid #000; box-shadow: 0 2px 0 #000; }
.sound-pop input[type=range]::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid #000; }
#snd-val { min-width: 30px; text-align: right; font: 400 20px var(--title); }

/* ── pvp ── */
.search-waiting { margin: 0; font-weight: 800; color: #fff; font-size: 15px; }
.search-more { width: 100%; padding: 14px; background: var(--panel); border: 3px solid #000; border-radius: 18px; box-shadow: 0 5px 0 #000; animation: popIn .4s both; }
.search-more p { margin: 0 0 6px; font-weight: 700; }
.search-more .row { margin-top: 8px; }
.fight-banner { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); z-index: 6; max-width: 92%; padding: 10px 16px; border-radius: 14px; background: rgba(150,20,10,.92); border: 3px solid #000; box-shadow: 0 5px 0 #000; font-weight: 700; font-size: 14px; text-align: center; animation: popIn .35s both; }
.fight-banner.net { background: rgba(20,40,70,.95); bottom: 64px; }

/* ── ranking details ── */
.rank-count { text-align: center; margin: -6px 0 10px; font-weight: 800; color: var(--dim); font-size: 13px; letter-spacing: .06em; }
.rank-name { display: flex; flex-direction: column; }
.rank-wl { font-size: 12px; font-weight: 600; color: var(--dim); }
.rank-wl .w { color: #8ff0b0; font-weight: 800; } .rank-wl .l { color: #ffaaa3; font-weight: 800; }
.pod-wins { font-size: 12px; font-weight: 800; color: #8ff0b0; }

/* ── wallet / stakes ── */
.money-pill { font-weight: 800; font-size: 14px; padding: 5px 12px; border-radius: 10px; background: rgba(75,227,122,.15); border: 2px solid #1d6b3a; color: #b9ffd0; }
.money-pill:empty { display: none; }
.vs-pot { position: absolute; left: 50%; top: calc(50% + clamp(60px, 13vw, 110px)); transform: translateX(-50%); z-index: 3; font: 400 clamp(24px, 5vw, 38px) var(--title); letter-spacing: .06em; color: #111; background: linear-gradient(#ffe45a, #ffb800); border: 4px solid #000; border-radius: 16px; padding: 4px 18px; box-shadow: 0 6px 0 #000; animation: popIn .5s .8s both; white-space: nowrap; }
.vs-pot:empty { display: none; }
.hud-pot { font: 400 15px var(--title); letter-spacing: .08em; color: #b9ffd0; text-shadow: 2px 2px 0 #000; margin-top: 2px; }
.hud-pot:empty { display: none; }
.money-box { width: 100%; padding: 12px 16px; border-radius: 18px; border: 4px solid #000; box-shadow: 0 6px 0 #000; display: flex; justify-content: space-between; align-items: center; font-weight: 800; animation: fadeUp .5s .7s both; }
.money-box.win { background: linear-gradient(135deg, #1f8a4a, #0f5a2e); }
.money-box.lose { background: linear-gradient(135deg, #8a1f1f, #5a0f0f); }
.money-box.neutral { background: var(--panel); }
.money-box b { font: 400 34px/1 var(--title); letter-spacing: .03em; text-shadow: 2px 2px 0 #000; }
.money-box small { display: block; color: rgba(255,255,255,.8); font-weight: 600; font-size: 12px; }
.pc-money { font-weight: 800; color: #b9ffd0; font-size: 13px; margin-top: 3px; }
.wallet-card { padding: 16px; margin-bottom: 14px; background: linear-gradient(135deg, rgba(31,138,74,.85), rgba(10,50,30,.9)); border: 4px solid #000; border-radius: 22px; box-shadow: 0 7px 0 #000; }
.wallet-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 10px; }
.wallet-amt { font: 400 46px/1 var(--title); letter-spacing: .02em; text-shadow: 3px 3px 0 #000; }
.wallet-lbl { font-size: 12px; font-weight: 800; letter-spacing: .12em; color: rgba(255,255,255,.8); }
.wallet-locked { font-size: 13px; font-weight: 700; color: #ffe9a0; }
.wallet-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.wallet-btns .btn { min-height: 48px; font-size: 22px; }
.wallet-hist { list-style: none; margin: 12px 0 0; padding: 0; max-height: 220px; overflow: auto; display: grid; gap: 6px; }
.wallet-hist li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 10px; border-radius: 12px; background: rgba(0,0,0,.35); font-size: 13px; }
.wallet-hist .amt { font-weight: 900; white-space: nowrap; }
.wallet-hist .amt.p { color: #8ff0b0; } .wallet-hist .amt.n { color: #ffaaa3; } .wallet-hist .amt.z { color: var(--dim); }
.wallet-hist small { display: block; color: var(--dim); font-size: 11px; }
.house { margin-top: 10px; padding: 8px 10px; border-radius: 12px; background: rgba(255,210,31,.15); border: 2px dashed rgba(255,210,31,.5); font-size: 13px; font-weight: 700; }
.stake-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stake { position: relative; padding: 14px 6px 10px; border-radius: 18px; border: 4px solid #000; background: linear-gradient(#2b3946, #18222b); box-shadow: 0 5px 0 #000; text-align: center; transition: transform .12s; }
.stake:active { transform: translateY(4px); box-shadow: 0 1px 0 #000; }
.stake b { display: block; font: 400 36px/1 var(--title); color: var(--yellow); text-shadow: 2px 2px 0 #000; }
.stake small { display: block; font-size: 12px; font-weight: 700; color: #b9ffd0; margin-top: 4px; }
.stake i { position: absolute; top: 6px; right: 8px; font-style: normal; font-size: 11px; font-weight: 800; color: var(--dim); }
.stake:disabled { filter: grayscale(1) brightness(.6); }
.stake:disabled small { color: #ffaaa3; }
.demo-badge { text-align: center; font-size: 12px; font-weight: 800; letter-spacing: .06em; color: #ffe9a0; background: rgba(255,210,31,.12); border: 2px dashed rgba(255,210,31,.5); border-radius: 10px; padding: 6px; margin-bottom: 12px; }
.cash-balance { text-align: center; font-weight: 700; color: var(--dim); margin-bottom: 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chips button, .methods button { padding: 8px 14px; border-radius: 12px; border: 3px solid #000; background: rgba(255,255,255,.08); font-weight: 800; }
.chips button.sel, .methods button.sel { background: var(--yellow); color: #111; }
.methods { display: flex; gap: 8px; flex-wrap: wrap; }
.cash-wait { text-align: center; padding: 20px 0 6px; }
.spinner { width: 54px; height: 54px; margin: 0 auto 12px; border-radius: 50%; border: 6px solid rgba(255,255,255,.15); border-top-color: var(--yellow); animation: spin .8s linear infinite; }
.done-ico { font-size: 54px; animation: popIn .4s both; }

/* ── top bar v2 ── */
.topbar-left { display: flex; gap: 8px; }
.player-chip { margin-left: auto; display: flex; align-items: center; gap: 10px; padding: 5px 12px 5px 5px; max-width: 300px; background: linear-gradient(135deg, rgba(20,28,36,.95), rgba(10,14,18,.95)); border: 3px solid #000; border-radius: 18px; box-shadow: 0 4px 0 #000, inset 0 0 0 1px rgba(255,210,31,.25); text-align: left; transition: transform .12s; animation: fadeIn .4s both; }
.player-chip:active { transform: translateY(3px); box-shadow: 0 1px 0 #000; }
.player-chip .av { width: 42px; height: 42px; border-radius: 12px; border-width: 2px; box-shadow: none; }
.chip-txt { min-width: 0; display: grid; gap: 3px; }
.chip-row { display: flex; align-items: center; gap: 6px; }
.chip-name { font: 800 14px var(--body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 110px; }
.chip-row .lvl { height: 20px; min-width: 0; font-size: 11px; padding: 0 6px; border-radius: 6px; }
.mini-xp { position: relative; width: 120px; height: 7px; border-radius: 5px; background: rgba(255,255,255,.12); overflow: hidden; }
.mini-xp i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #ffb800, #ffe45a); border-radius: 5px; }
.chip-money { font: 800 13px var(--body); color: #b9ffd0; white-space: nowrap; }
.chip-login { font: 400 20px var(--title); letter-spacing: .06em; padding: 4px 10px; color: var(--yellow); }
@media (max-width: 560px) {
  .topbar.has-chip .topbar-logo { display: none; }
  .mini-xp { width: 84px; }
  .chip-name { max-width: 80px; }
}

/* ── profile v2 ── */
.screen.scroll { overflow-y: auto; align-items: flex-start; -webkit-overflow-scrolling: touch; }
.pf-wrap { width: min(600px, 100%); margin: 0 auto; padding-bottom: 20px; }
.pf-hero { display: flex; align-items: center; gap: 16px; padding: 16px; background: var(--panel); border: 4px solid #000; border-radius: 24px; box-shadow: 0 7px 0 #000; margin-bottom: 16px; animation: popIn .4s both; }
.pf-hero .av { width: 92px; height: 92px; border-radius: 24px; border-width: 4px; box-shadow: 0 5px 0 #000, 0 0 0 3px var(--yellow); cursor: pointer; }
.pf-hero-txt { flex: 1; min-width: 0; }
.pf-hero .pf-name { font-size: 34px; }
.pf-hero .xp-head { font-size: 18px; margin-top: 6px; }
.pf-hero .money-pill { display: inline-block; margin-top: 8px; }
.tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 6px; background: var(--panel); border: 3px solid #000; border-radius: 18px; box-shadow: 0 5px 0 #000; margin-bottom: 14px; position: sticky; top: 0; z-index: 5; }
.tabs button { padding: 10px 4px; border-radius: 12px; font: 400 18px var(--title); letter-spacing: .06em; color: var(--dim); transition: background .2s, color .2s; }
.tabs button.on { background: var(--yellow); color: #111; }
.tab-panel { display: grid; gap: 12px; animation: fadeUp .3s both; }
.acc { background: var(--panel); border: 3px solid #000; border-radius: 18px; box-shadow: 0 5px 0 #000; overflow: hidden; }
.acc summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; font: 800 16px var(--body); }
.acc summary::-webkit-details-marker { display: none; }
.acc > summary::after { content: "▾"; font-size: 18px; color: var(--yellow); transition: transform .25s; }
.acc[open] > summary::after { transform: rotate(180deg); }
.acc summary em { margin-left: auto; font-style: normal; font-size: 11px; font-weight: 800; color: #ffe9a0; background: rgba(255,210,31,.15); padding: 2px 8px; border-radius: 8px; }
.acc-body { padding: 0 16px 16px; animation: fadeUp .25s both; }
.acc-body .stats { margin: 0; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 14px; }
.kv span { color: var(--dim); font-weight: 700; } .kv b { text-align: right; }
.wallet-card .wallet-btns { display: none; }
#scr-profile .wallet-hist { max-height: none; }
.cash-inline .row { margin-top: 12px; }
#stats-money .stat b { font-size: 24px; line-height: 1.15; white-space: nowrap; }
.cash-inline .field-label { margin-top: 12px; }
.cash-inline .methods { justify-content: center; }
.cash-inline .ci-go { width: 100%; margin-top: 6px; }
.player-chip.login { padding: 6px 12px; }
.pf-hero .xp-bar { margin-top: 4px; }
@media (max-width: 420px) { #stats-money .stat b { font-size: 19px; } }
.screen.scroll.active, .screen.scroll.leaving { display: block; }
.pf-wrap { padding-bottom: 40px !important; }
.topbar.solid { background: linear-gradient(180deg, rgba(8,11,15,.97) 0%, rgba(8,11,15,.9) 75%, rgba(8,11,15,0) 100%); }
.tabs { background: #141b23; }

/* ── language ── */
.lang-btn { width: auto; min-width: 44px; padding: 0 8px; display: flex; gap: 4px; align-items: center; pointer-events: auto; }
.lang-btn span { font-size: 18px; line-height: 1; }
.lang-btn b { font: 400 17px var(--title); letter-spacing: .04em; color: var(--yellow); }
.lang-pop { position: absolute; z-index: 45; top: calc(64px + var(--safe-t)); left: 14px; display: grid; gap: 6px; padding: 10px; width: 200px; background: var(--panel); border: 3px solid #000; border-radius: 16px; box-shadow: 0 5px 0 #000; animation: popIn .25s both; }
.lang-pop button, .lang-grid button { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; border: 3px solid #000; background: rgba(255,255,255,.07); font-weight: 800; text-align: left; transition: transform .12s; }
.lang-pop button.sel, .lang-grid button.sel { background: var(--yellow); color: #111; }
.lang-pop button:active, .lang-grid button:active { transform: translateY(2px); }
.lf { font-size: 20px; line-height: 1; }
.lang-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

/* ── stake tiers ── */
.stake.locked { filter: grayscale(.9) brightness(.55); border-style: dashed; }
.stake.locked small { color: #ffe9a0; }
.stake.nope { animation: nope .4s; }
@keyframes nope { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.tiers { display: grid; gap: 8px; }
.tier { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; background: rgba(0,0,0,.35); border: 2px solid rgba(255,255,255,.08); animation: fadeUp .35s both; }
.tier.ok { border-color: rgba(75,227,122,.55); background: rgba(75,227,122,.1); }
.tier-coin { min-width: 58px; height: 44px; display: grid; place-items: center; border-radius: 12px; font: 400 24px var(--title); color: #111; background: linear-gradient(#ffe45a, #ffb800); border: 3px solid #000; box-shadow: 0 3px 0 #000; }
.tier.lock .tier-coin { background: linear-gradient(#59636c, #343c43); color: #cfd8dc; }
.tier-txt { flex: 1; min-width: 0; display: grid; gap: 3px; }
.tier-txt b { font-size: 14px; } .tier-txt small { font-size: 12px; color: var(--dim); font-weight: 700; }
.tier-bar { height: 6px; border-radius: 4px; background: rgba(255,255,255,.12); overflow: hidden; }
.tier-bar i { display: block; height: 100%; background: linear-gradient(90deg, #ffb800, #ffe45a); }
.tier.ok .tier-bar i { background: linear-gradient(90deg, #26b35a, #4be37a); }
.tier-ico { font-size: 22px; }

/* ── unlock celebration ── */
.unlock { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; background: radial-gradient(circle at 50% 45%, rgba(255,190,0,.35), rgba(0,0,0,.88) 65%); }
.unlock.hidden { display: none; }
.unlock-rays { position: absolute; left: 50%; top: 45%; width: 900px; height: 900px; margin: -450px 0 0 -450px; background: repeating-conic-gradient(rgba(255,214,60,.22) 0 10deg, transparent 10deg 20deg); border-radius: 50%; animation: spin 14s linear infinite; mask: radial-gradient(circle, #000 25%, transparent 65%); -webkit-mask: radial-gradient(circle, #000 25%, transparent 65%); pointer-events: none; }
.unlock-card { position: relative; width: min(420px, 100%); text-align: center; padding: 26px 20px 20px; background: var(--panel); border: 4px solid #000; border-radius: 28px; box-shadow: 0 9px 0 #000, 0 0 0 4px var(--yellow), 0 0 60px rgba(255,200,0,.5); }
.unlock.go .unlock-card { animation: unlockIn .7s cubic-bezier(.2,1.4,.4,1) both; }
@keyframes unlockIn { from { transform: scale(.2) rotate(-12deg); opacity: 0; } to { transform: none; opacity: 1; } }
.unlock-lock { font-size: 56px; line-height: 1; animation: lockPop 1s .3s both; }
@keyframes lockPop { 0% { transform: scale(0) rotate(-40deg); } 50% { transform: scale(1.4) rotate(15deg); } 100% { transform: scale(1) rotate(0); } }
.unlock-title { font: 400 34px/1.05 var(--title); letter-spacing: .04em; color: var(--yellow); text-shadow: 3px 3px 0 #000; margin: 10px 0 14px; }
.unlock-coin { display: inline-grid; place-items: center; min-width: 150px; height: 150px; padding: 0 20px; border-radius: 50%; font: 400 64px var(--title); color: #111; background: radial-gradient(circle at 35% 30%, #fff6b0, #ffd21f 45%, #e09a00); border: 5px solid #000; box-shadow: 0 8px 0 #000, inset 0 -8px 0 rgba(0,0,0,.18); animation: coinIn 1s .45s cubic-bezier(.2,1.5,.4,1) both, coinFloat 2.4s 1.5s ease-in-out infinite; }
@keyframes coinIn { from { transform: scale(0) rotateY(540deg); } to { transform: scale(1) rotateY(0); } }
@keyframes coinFloat { 50% { transform: translateY(-8px) rotate(-4deg); } }
.unlock-sub { margin: 16px 4px 18px; font-weight: 700; color: #e7eef2; line-height: 1.4; }
@media (max-width: 520px) { .topbar-logo { display: none; } .lang-btn b { font-size: 15px; } }
.online-pill em { font-style: normal; }

/* podium level + xp */
.pod-lvl { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 4px; }
.pod-lvl .lvl { height: 20px; font-size: 11px; padding: 0 6px; border-radius: 6px; min-width: 0; }
.pod-xp { font-size: 11px; font-weight: 800; color: var(--dim); }
.pod-bar { width: 70%; max-width: 90px; height: 5px; margin: 4px auto 6px; border-radius: 4px; background: rgba(255,255,255,.12); overflow: hidden; }
.pod-bar i { display: block; height: 100%; background: linear-gradient(90deg, #ffb800, #ffe45a); }

/* tier purchase */
.tier-lock { cursor: pointer; background: none; border: 0; padding: 4px; transition: transform .15s; animation: lockWiggle 2.6s infinite; }
.tier-lock:active { transform: scale(.85); }
@keyframes lockWiggle { 0%, 88%, 100% { transform: rotate(0); } 91% { transform: rotate(-14deg); } 94% { transform: rotate(12deg); } 97% { transform: rotate(-6deg); } }
.tier-buy { justify-self: start; margin-top: 4px; padding: 5px 12px; border-radius: 10px; border: 3px solid #000; background: var(--yellow); color: #111; font: 800 13px var(--body); box-shadow: 0 3px 0 #000; }
.tier-buy:active { transform: translateY(2px); box-shadow: 0 1px 0 #000; }
.tier-wait { font-size: 11px; font-weight: 700; color: var(--dim); margin-top: 2px; }
.tier.paid { border-color: rgba(255,210,31,.6); background: rgba(255,210,31,.08); }
.chip-row { min-width: 0; } .chip-row .lvl { flex-shrink: 0; } .chip-name { min-width: 0; flex: 1 1 auto; } .player-chip { min-width: 0; }

/* ── Deck & Bluff ── */
.hud-deck { display: flex; gap: 4px; margin-top: 3px; }
.hud-op .hud-deck { justify-content: flex-end; }
.hud-deck span { display: inline-flex; align-items: center; gap: 1px; padding: 1px 4px; border-radius: 6px; background: rgba(0,0,0,.4); font-size: 11px; line-height: 1.3; }
.hud-deck b { font-weight: 900; color: var(--yellow); font-size: 11px; }
.hud-deck span.out { opacity: .35; text-decoration: line-through; }
.hud-last { display: flex; gap: 2px; margin-top: 3px; }
.hud-op .hud-last { justify-content: flex-end; }
.hud-last i { width: 17px; height: 17px; display: grid; place-items: center; font-style: normal; font-size: 11px; border-radius: 5px; background: rgba(255,255,255,.1); }
.hud-last i:first-child { background: rgba(255,210,31,.3); box-shadow: 0 0 0 1px var(--yellow); }
.hud-last i.none { opacity: .35; }
.move { position: relative; }
.move .cnt { position: absolute; top: 6px; right: 8px; font: 400 18px var(--title); color: var(--yellow); text-shadow: 2px 2px 0 #000; }
.move.empty { opacity: .3; filter: grayscale(1); }
.move.empty .cnt { color: #ff6b5e; }
.move.nope { animation: nope .4s; }
.moves.announce .move { background: linear-gradient(#2e6fd6, #1c3f86); }
.moves.announce .move.ann { background: linear-gradient(#5fb0ff, #2e6fd6); transform: translateY(-6px); box-shadow: 0 12px 0 #000, 0 0 26px rgba(80,160,255,.8); }
.moves.announce.locked .move:not(.ann) { opacity: .4; }
.timer.ann .t-fg { stroke: #5fb0ff; }
.timer.ann span { color: #9fd0ff; }
.callout.ann { color: #9fd0ff; }
.bub { position: absolute; z-index: 5; padding: 8px 14px; border-radius: 16px; border: 3px solid #000; background: #fff; color: #111; font: 800 15px var(--body); box-shadow: 0 5px 0 #000; white-space: nowrap; animation: annIn .35s cubic-bezier(.2,1.5,.4,1) both; display: flex; align-items: center; gap: 6px; }
.bub.hidden { display: none; }
.ann-ico { font-size: 17px; }
.ann-me { left: 6%; bottom: 14%; }
.ann-op { right: 6%; top: 18%; }
.bub::after { content: ""; position: absolute; width: 14px; height: 14px; background: #fff; border: 3px solid #000; border-top: 0; border-left: 0; transform: rotate(45deg); }
.ann-me::after { left: 22px; bottom: -9px; }
.ann-op::after { right: 22px; top: -9px; transform: rotate(-135deg); }
.bub em { font-style: normal; font: 400 16px var(--title); letter-spacing: .05em; padding: 1px 8px; border-radius: 8px; margin-left: 4px; }
.bub.bluff em { background: var(--red); color: #fff; }
.bub.honest em { background: var(--green); color: #111; }
@keyframes annIn { from { transform: scale(.3); opacity: 0; } to { transform: none; opacity: 1; } }
.ann-hint { position: absolute; z-index: 4; left: 50%; bottom: 4px; transform: translateX(-50%); width: max-content; max-width: 92%; padding: 6px 12px; border-radius: 12px; background: rgba(28,63,134,.92); border: 2px solid #000; font-size: 12px; font-weight: 800; text-align: center; color: #dff0ff; }
.ann-hint.hidden { display: none; }
.rules-line { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin: -4px 0 12px; font-size: 13px; font-weight: 800; color: #e7eef2; text-align: center; }
.rules-btn { padding: 5px 12px; border-radius: 10px; border: 3px solid #000; background: var(--yellow); color: #111; font: 400 16px var(--title); letter-spacing: .05em; box-shadow: 0 3px 0 #000; }
.rules-panel { max-height: 86vh; overflow-y: auto; }
.rules-body { text-align: left; font-size: 14px; line-height: 1.45; margin-bottom: 16px; }
.rules-body p { margin: 0 0 10px; }
@media (max-width: 520px) { .hud-last i { width: 15px; height: 15px; font-size: 10px; } .hud-deck span { font-size: 10px; padding: 1px 3px; } .bub { font-size: 13px; padding: 6px 10px; } }
@media (max-width: 560px) {
  .hud { gap: 4px; padding: 0 6px; }
  .hud-p { gap: 5px; padding: 5px 6px; }
  .hud-p .av { width: 34px; height: 34px; border-radius: 10px; }
  .hud-me .hud-deck { display: none; } /* your own counts are on the move buttons */
  .hud-deck { gap: 2px; }
  .hud-deck span { padding: 0 2px; font-size: 10px; }
  .hud-deck b { font-size: 10px; }
  .op-status { max-width: 34%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; padding: 5px 8px; }
}
.rules-ico { font: 400 26px/1 var(--title); color: var(--yellow); text-shadow: 2px 2px 0 #000; pointer-events: auto; }
@media (max-width: 420px) { .topbar-left { gap: 6px; } .topbar-left .icon-btn { width: 40px; height: 40px; } .lang-btn { width: auto; padding: 0 6px; } .lang-btn b { display: none; } }
.invite-box { border-top: 2px dashed rgba(255,255,255,.12); padding-top: 12px; }
.inv-row { display: flex; gap: 8px; }
.inv-row input { height: 46px; font-size: 15px; }
.inv-row .btn { min-height: 46px; padding: 0 14px; font-size: 18px; width: auto; }
.inv-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; }
.inv-list li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; background: rgba(0,0,0,.35); font-size: 13px; font-weight: 700; }
.inv-list small { display: block; color: var(--dim); font-size: 11px; }
.inv-list button { width: 30px; height: 30px; border-radius: 9px; border: 2px solid #000; background: rgba(255,90,80,.25); color: #ffb3ad; font-weight: 900; }
.arm-op { transform-origin: 50% 50%; } /* mirror in place: with a 100% origin the flipped arm landed off-screen */

/* timer sits right under the HUD (its height varies with deck / last-5 rows) */
.timer { transition: top .2s; }
.stake .stake-fee { display: block; font-style: normal; font-size: 10px; font-weight: 800; color: var(--dim); margin-top: 1px; }
@media (max-width: 700px) { .vs-pot { top: auto; bottom: calc(46px + var(--safe-b)); } }

/* ── money FX ── */
.coin { position: fixed; z-index: 90; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font: 900 16px var(--body); border: 3px solid #000; pointer-events: none; box-shadow: 0 3px 0 #000; }
.coin.win { color: #0b3d1c; background: radial-gradient(circle at 35% 30%, #d6ffe4, #4be37a 55%, #1f9a4b); }
.coin.lose { color: #4a0a06; background: radial-gradient(circle at 35% 30%, #ffd0cc, #ff5a4e 55%, #b3170d); }
.slot { display: inline-flex; align-items: flex-end; line-height: 1; }
.slot-col { display: inline-block; height: 1em; overflow: hidden; vertical-align: bottom; }
.slot-strip { display: flex; flex-direction: column; }
.slot-strip i { display: block; height: 1em; line-height: 1em; font-style: normal; }
.slot.win { color: #6dffa0; text-shadow: 0 0 12px rgba(75,227,122,.85), 2px 2px 0 #000; animation: slotGlow 1.6s ease-out; }
.slot.lose { color: #ff7468; text-shadow: 0 0 12px rgba(255,80,70,.85), 2px 2px 0 #000; animation: slotGlow 1.6s ease-out; }
@keyframes slotGlow { 0% { filter: brightness(1.8); } 100% { filter: none; } }
.res-net.win, .chip-bal.win { color: #6dffa0; } .res-net.lose, .chip-bal.lose { color: #ff7468; }
.elo-box { border-top: 2px dashed rgba(255,255,255,.12); padding-top: 12px; }
.elo-scroll { max-height: 280px; overflow: auto; margin-top: 8px; }
.elo-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.elo-table th { text-align: left; color: var(--dim); font-weight: 800; padding: 6px 4px; position: sticky; top: 0; background: var(--panel); }
.elo-table td { padding: 6px 4px; border-top: 1px solid rgba(255,255,255,.08); font-weight: 700; }
.elo-table td:nth-child(3) { color: var(--yellow); }
/* VS play style */
.vs-style { display: grid; gap: 5px; width: min(38vw, 230px); margin-top: 4px; }
.vs-right .vs-style { justify-items: end; }
.vs-bar { display: flex; width: 100%; height: 8px; border-radius: 5px; overflow: hidden; border: 2px solid #000; background: rgba(0,0,0,.35); }
.vs-bar i { display: block; height: 100%; }
.vs-bar .r { background: #ffb3a0; } .vs-bar .p { background: #fff3b0; } .vs-bar .s { background: #b0e0ff; }
.vs-pcts { display: flex; gap: 8px; font-size: 12px; font-weight: 800; text-shadow: 1px 1px 0 #000; }
.vs-bluff, .vs-new { font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 8px; background: rgba(0,0,0,.35); text-shadow: 1px 1px 0 #000; justify-self: start; }
.vs-right .vs-bluff, .vs-right .vs-new { justify-self: end; }
@media (max-width: 520px) { .vs-pcts { gap: 5px; font-size: 11px; } .vs-bluff, .vs-new { font-size: 11px; } }
.vs-style { gap: 6px; } .vs-pcts { font-size: 13px; } .vs-bluff, .vs-new { font-size: 12.5px; }

/* ── settings · friends · notifications ── */
.tabs { grid-template-columns: repeat(4, 1fr); }
.tabs button { font-size: 16px; }
.set-pop, .drop-pop { position: absolute; z-index: 45; top: calc(64px + var(--safe-t)); left: 14px; width: min(340px, calc(100vw - 28px)); max-height: calc(100% - 90px - var(--safe-t)); overflow-y: auto; padding: 12px; background: rgba(13,18,24,.96); border: 3px solid #000; border-radius: 18px; box-shadow: 0 6px 0 #000; backdrop-filter: blur(8px); animation: popIn .25s cubic-bezier(.2,1.4,.4,1) both; -webkit-overflow-scrolling: touch; }
.set-h, .drop-h { font: 400 18px var(--title); letter-spacing: .08em; color: var(--yellow); margin: 2px 2px 8px; }
.set-snd { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.set-snd input[type=range] { flex: 1; -webkit-appearance: none; appearance: none; height: 12px; padding: 0; border-radius: 8px; border: 2px solid #000; box-shadow: none; background: linear-gradient(90deg, var(--yellow) var(--p, 80%), #000 var(--p, 80%)); cursor: pointer; }
.set-snd input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 3px solid #000; box-shadow: 0 2px 0 #000; }
.set-snd input[type=range]::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid #000; }
.set-langs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 14px; }
.set-langs button { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 12px; border: 3px solid #000; background: rgba(255,255,255,.07); font-weight: 800; font-size: 13px; text-align: left; }
.set-langs button.sel { background: var(--yellow); color: #111; }
.set-rules { width: 100%; padding: 10px; font-size: 20px; margin-bottom: 12px; }
.icon-btn { position: relative; }
.ico-badge { position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--red); border: 2px solid #000; color: #fff; font: 800 11px/16px var(--body); font-style: normal; text-align: center; animation: popIn .3s both; }
#btn-bell.ring svg { animation: bellRing 1.6s ease-in-out infinite; transform-origin: 50% 15%; }
@keyframes bellRing { 0%, 60%, 100% { transform: rotate(0); } 10% { transform: rotate(14deg); } 20% { transform: rotate(-12deg); } 30% { transform: rotate(8deg); } 40% { transform: rotate(-5deg); } }
.fr-q { width: 100%; padding: 10px 12px; margin-bottom: 8px; border-radius: 12px; border: 3px solid #000; background: rgba(255,255,255,.08); color: #fff; font: 700 15px var(--body); }
.fr-q::placeholder { color: var(--dim); }
.fr-sec { display: flex; align-items: center; gap: 6px; margin: 10px 2px 6px; font: 800 12px var(--body); letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }
.fr-row { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 14px; background: rgba(255,255,255,.04); margin-bottom: 6px; animation: fadeUp .25s both; }
.fr-av { position: relative; flex: none; }
.fr-av .av { width: 40px; height: 40px; border-radius: 12px; border-width: 2px; box-shadow: none; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: #5d6a73; border: 2px solid #000; flex: none; }
.dot.on { background: var(--green); box-shadow: 0 0 8px var(--green); }
.fr-av .dot { position: absolute; right: -3px; bottom: -3px; }
.fr-txt { flex: 1; min-width: 0; display: grid; }
.fr-txt b { font-weight: 800; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fr-txt small { font-size: 11px; color: var(--dim); font-weight: 700; }
.fr-act { display: flex; gap: 5px; flex: none; }
.fr-btn { padding: 6px 10px; border-radius: 10px; border: 2px solid #000; background: rgba(255,255,255,.1); color: #fff; font: 800 12px var(--body); box-shadow: 0 2px 0 #000; white-space: nowrap; }
.fr-btn:active { transform: translateY(2px); box-shadow: none; }
.fr-btn.ok { background: var(--green); color: #0b2a14; }
.fr-btn.no { background: rgba(255,59,47,.18); color: #ffb3ad; }
.fr-btn.go { background: var(--yellow); color: #111; }
.fr-btn.dim { opacity: .55; }
.fr-btn.sure { background: var(--red); color: #fff; }
.fr-btn:disabled { opacity: .5; }
.fr-tag { font: 800 11px var(--body); color: #ffe9a0; background: rgba(255,210,31,.15); padding: 4px 8px; border-radius: 8px; }
.fr-empty { margin: 6px 4px 10px; color: var(--dim); font-size: 13px; font-weight: 600; }
.drop-link { width: 100%; margin-top: 6px; padding: 9px; border-radius: 12px; border: 2px dashed rgba(255,255,255,.2); color: var(--yellow); font-weight: 800; font-size: 13px; }
.fr-add { padding: 12px; background: var(--panel); border: 3px solid #000; border-radius: 18px; box-shadow: 0 5px 0 #000; margin-bottom: 12px; }
.fr-add .fr-q { margin-bottom: 4px; }
#pf-friends .fr-row { background: var(--panel); border: 2px solid #000; }
.nt-row { display: flex; gap: 10px; padding: 8px; border-radius: 14px; background: rgba(255,255,255,.04); margin-bottom: 6px; animation: fadeUp .25s both; }
.nt-row.new { background: rgba(255,210,31,.1); box-shadow: inset 3px 0 0 var(--yellow); }
.nt-row .av { width: 38px; height: 38px; border-radius: 11px; border-width: 2px; box-shadow: none; }
.nt-txt { flex: 1; min-width: 0; }
.nt-txt p { margin: 0; font-size: 13px; line-height: 1.35; }
.nt-txt small { color: var(--dim); font-size: 11px; font-weight: 700; }
.nt-st { font-style: normal; font-size: 11px; font-weight: 800; color: var(--dim); background: rgba(255,255,255,.08); padding: 1px 6px; border-radius: 6px; }
.nt-act { display: flex; gap: 6px; margin-top: 6px; }
.ch-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 4px 0 14px; }
.ch-modes button { padding: 10px; border-radius: 14px; border: 3px solid #000; background: rgba(255,255,255,.07); font: 400 20px var(--title); letter-spacing: .05em; color: var(--dim); }
.ch-modes button.sel { background: var(--yellow); color: #111; }
.ch-wait { text-align: center; }
.ch-wait .av { width: 96px; height: 96px; border-radius: 26px; border-width: 4px; margin: 0 auto 10px; animation: pulseAv 1.4s ease-in-out infinite; }
@keyframes pulseAv { 50% { transform: scale(1.06); box-shadow: 0 0 0 6px rgba(255,210,31,.35); } }
.ch-clock { font: 400 46px/1 var(--title); color: var(--yellow); text-shadow: 3px 3px 0 #000; margin: 6px 0 14px; }
.ch-in { position: absolute; z-index: 60; left: 50%; top: calc(70px + var(--safe-t)); transform: translateX(-50%); width: min(420px, calc(100vw - 24px)); display: flex; align-items: center; gap: 10px; padding: 10px; background: linear-gradient(135deg, rgba(40,28,6,.97), rgba(14,18,24,.97)); border: 3px solid #000; border-radius: 18px; box-shadow: 0 6px 0 #000, 0 0 0 2px var(--yellow) inset; animation: dropIn .45s cubic-bezier(.2,1.4,.4,1) both; }
@keyframes dropIn { from { transform: translate(-50%, -40px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
.ch-in .av { width: 46px; height: 46px; border-radius: 13px; border-width: 2px; box-shadow: none; }
.ch-in-txt { flex: 1; min-width: 0; display: grid; gap: 2px; }
.ch-in-txt b { font-size: 14px; font-weight: 800; }
.ch-in-txt small { font-size: 12px; color: #ffe9a0; font-weight: 700; }
.ch-in-bar { height: 5px; border-radius: 4px; background: rgba(255,255,255,.12); overflow: hidden; }
.ch-in-bar i { display: block; height: 100%; background: var(--yellow); transition: width .25s linear; }
.ch-in-act { display: grid; gap: 5px; }
@media (max-width: 420px) { .fr-btn { padding: 5px 8px; font-size: 11px; } .tabs button { font-size: 14px; letter-spacing: .03em; } }
/* bell: strong shake on a new notification, then the soft ring loop while unread */
#btn-bell.shake { animation: bellShake .9s cubic-bezier(.36,.07,.19,.97) both; }
#btn-bell.shake svg { animation: bellSwing .9s ease-in-out both; transform-origin: 50% 12%; }
@keyframes bellShake { 10%, 90% { transform: translateX(-1px) rotate(-3deg); } 20%, 80% { transform: translateX(2px) rotate(4deg); } 30%, 50%, 70% { transform: translateX(-3px) rotate(-6deg) scale(1.08); } 40%, 60% { transform: translateX(3px) rotate(6deg) scale(1.08); } }
@keyframes bellSwing { 0% { transform: rotate(0); } 15% { transform: rotate(28deg); } 30% { transform: rotate(-24deg); } 45% { transform: rotate(18deg); } 60% { transform: rotate(-12deg); } 75% { transform: rotate(6deg); } 100% { transform: rotate(0); } }
#btn-bell.shake::after { content: ""; position: absolute; inset: -4px; border-radius: 18px; border: 3px solid var(--yellow); animation: bellWave .9s ease-out both; pointer-events: none; }
@keyframes bellWave { from { opacity: .9; transform: scale(.9); } to { opacity: 0; transform: scale(1.45); } }
.ico-badge.bump { animation: badgeBump .6s cubic-bezier(.2,1.6,.4,1) both; }
@keyframes badgeBump { 0% { transform: scale(.3); } 60% { transform: scale(1.35); } 100% { transform: scale(1); } }
/* bell icon in yellow */
#btn-bell svg { stroke: var(--yellow); }
/* themed scrollbars (leaderboard, profile, menus, lists) */
@supports (-moz-appearance: none) { * { scrollbar-width: thin; scrollbar-color: var(--yellow) rgba(0,0,0,.35); } }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: rgba(0,0,0,.35); border-radius: 8px; margin: 6px 0; }
::-webkit-scrollbar-thumb { background: linear-gradient(180deg, #ffe45a, #ffb800); border-radius: 8px; border: 2px solid rgba(0,0,0,.6); }
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, #fff07a, #ffc400); }
::-webkit-scrollbar-corner { background: transparent; }
.rank-list { padding-right: 6px; }

/* ── referral ── */
#setup-ref { text-transform: uppercase; }
.ref-check { min-height: 18px; margin: 4px 2px 0; font-size: 13px; font-weight: 800; }
.ref-check.ok { color: var(--green); } .ref-check.bad { color: #ff8a80; }
.aff-pitch { margin: 0 0 12px; font-size: 13px; line-height: 1.45; color: #dfe7ec; }
.aff-pitch b { color: var(--yellow); }
.aff-share { display: grid; gap: 8px; margin-bottom: 14px; }
.aff-code { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; padding: 9px 10px 9px 12px; border-radius: 14px; border: 2px dashed rgba(255,210,31,.45); background: rgba(255,210,31,.06); }
.aff-code small { grid-column: 1; font-size: 11px; font-weight: 800; color: var(--dim); text-transform: uppercase; letter-spacing: .05em; }
.aff-code b { grid-column: 1; font: 400 24px/1.1 var(--title); letter-spacing: .08em; color: var(--yellow); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aff-code.link b { font: 800 13px var(--body); letter-spacing: 0; color: #fff; }
.aff-code.creator { border-color: rgba(46,230,214,.5); background: rgba(46,230,214,.07); } .aff-code.creator b { color: var(--cyan); }
.aff-code .fr-btn { grid-column: 2; grid-row: 1 / span 2; }
.aff-sharebtn { width: 100%; padding: 11px; font-size: 20px; }
.aff-earn { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 6px; }
.aff-earn > div { padding: 10px 6px; border-radius: 14px; background: rgba(255,255,255,.05); border: 2px solid #000; text-align: center; }
.aff-earn small { display: block; font-size: 10px; font-weight: 800; color: var(--dim); text-transform: uppercase; letter-spacing: .04em; }
.aff-earn b { font: 400 22px/1.2 var(--title); letter-spacing: .03em; } .aff-earn b.g { color: var(--green); }
.aff-next { margin: 4px 2px 12px; }
.aff-levels { display: grid; gap: 6px; margin: 8px 0 12px; }
.aff-lv { border-radius: 12px; background: rgba(255,255,255,.05); }
.aff-lv > summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 38px 52px 1fr 18px; grid-template-rows: auto auto; align-items: center; column-gap: 8px; padding: 7px 10px; }
.aff-lv > summary::-webkit-details-marker { display: none; }
.aff-lv > summary::after { content: "▾"; grid-column: 4; grid-row: 1 / span 2; color: var(--yellow); transition: transform .25s; }
.aff-lv[open] > summary::after { transform: rotate(180deg); }
.aff-lv.off > summary::after { content: ""; }
.aff-lv .lv { grid-row: 1 / span 2; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--yellow); color: #111; font: 400 18px var(--title); border: 2px solid #000; }
.aff-lv .pc { grid-row: 1 / span 2; font-weight: 800; color: #ffe9a0; font-size: 13px; }
.aff-lv b { grid-column: 3; font: 400 22px/1 var(--title); }
.aff-lv small { grid-column: 3; font-size: 11px; color: var(--dim); font-weight: 700; }
.aff-lv.off { opacity: .55; } .aff-lv.off .lv { background: #4a555e; color: #ddd; } .aff-lv.off > summary { cursor: default; }
.aff-members { display: grid; gap: 5px; padding: 0 8px 8px; max-height: 260px; overflow-y: auto; }
.aff-m { display: grid; grid-template-columns: 30px 1fr auto auto; align-items: center; gap: 8px; padding: 5px 6px; border-radius: 10px; background: rgba(0,0,0,.25); animation: fadeUp .2s both; }
.aff-m .av { width: 30px; height: 30px; border-radius: 9px; border-width: 2px; box-shadow: none; }
.aff-m span { font-weight: 800; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aff-m small { font-size: 11px; color: var(--dim); font-weight: 700; }
.aff-m em { font-style: normal; font-size: 10px; font-weight: 800; padding: 2px 6px; border-radius: 6px; background: rgba(255,255,255,.08); color: var(--dim); }
.aff-m em.ok { background: rgba(75,227,122,.15); color: var(--green); }
.wd-src { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.wd-src button { padding: 10px 8px; border-radius: 14px; border: 3px solid #000; background: rgba(255,255,255,.06); text-align: center; box-shadow: 0 3px 0 #000; }
.wd-src button small { display: block; font-size: 10.5px; font-weight: 800; color: var(--dim); }
.wd-src button b { font: 400 24px/1.2 var(--title); letter-spacing: .03em; }
.wd-src button.sel { background: rgba(255,210,31,.14); border-color: var(--yellow); }
.wd-src button.sel b { color: var(--yellow); }
.sub-acc { margin-top: 8px; border-radius: 12px; background: rgba(255,255,255,.04); }
.sub-acc summary { cursor: pointer; list-style: none; padding: 10px 12px; font-weight: 800; font-size: 13px; display: flex; justify-content: space-between; }
.sub-acc summary::after { content: "▾"; color: var(--yellow); font-size: 16px; transform: none !important; transition: transform .25s; }
.sub-acc[open] > summary::after { transform: rotate(180deg) !important; }
.sub-acc summary::-webkit-details-marker { display: none; }
.sub-acc .wallet-hist { margin: 0; padding: 0 8px 8px; }
.aff-rules { padding: 0 12px 10px; font-size: 12.5px; line-height: 1.5; color: #dfe7ec; } .aff-rules p { margin: 0 0 6px; }
.aff-admin { border-top: 2px dashed rgba(255,255,255,.12); padding-top: 12px; }
.affa-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin: 10px 0 6px; }
.affa-grid label { display: grid; gap: 3px; font-size: 11px; font-weight: 800; color: var(--dim); }
.affa-grid label:nth-child(n+6) { grid-column: span 5; grid-template-columns: 1fr 90px; align-items: center; }
.affa-grid input { width: 100%; padding: 7px 6px; border-radius: 10px; border: 2px solid #000; background: rgba(255,255,255,.08); color: #fff; font: 800 14px var(--body); text-align: center; }
#affa-total.bad { color: #ff8a80; font-weight: 800; }
.aff-admin .inv-row input { min-width: 0; }

.audit { padding: 10px 12px; border-radius: 12px; font-weight: 800; font-size: 13px; margin-bottom: 8px; }
.audit.ok { background: rgba(75,227,122,.12); color: var(--green); border: 2px solid rgba(75,227,122,.4); }
.audit.bad { background: rgba(255,59,47,.12); color: #ff8a80; border: 2px solid rgba(255,59,47,.4); }
#audit-run { width: 100%; }

/* ── referral explainer video ── */
.aff-video-btn { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px; margin-bottom: 12px; border-radius: 16px; border: 3px solid #000; background: linear-gradient(135deg, #2a1d00, #151b21 60%); box-shadow: 0 5px 0 #000, inset 0 0 0 2px rgba(255,210,31,.35); text-align: left; transition: transform .12s; }
.aff-video-btn:active { transform: translateY(3px); box-shadow: 0 2px 0 #000; }
.aff-video-btn .pl { flex: none; width: 46px; height: 46px; border-radius: 50%; background: var(--yellow); color: #111; display: grid; place-items: center; font-size: 18px; border: 3px solid #000; animation: vdPulse 1.8s ease-in-out infinite; }
.aff-video-btn b { display: block; font: 400 22px/1.05 var(--title); letter-spacing: .05em; color: var(--yellow); }
.aff-video-btn small { color: var(--dim); font-weight: 700; font-size: 12px; }
@keyframes vdPulse { 50% { box-shadow: 0 0 0 8px rgba(255,210,31,.18); } }
.vd-root-ov { position: fixed; inset: 0; z-index: 95; display: grid; place-items: center; padding: max(12px, env(safe-area-inset-top)) max(10px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-left)); background: rgba(0,0,0,.82); backdrop-filter: blur(6px); }
.vd-root-ov.hidden { display: none; }
.vd-frame { position: relative; width: min(430px, 100%); height: min(820px, 100%); display: grid; grid-template-rows: 1fr auto auto; border-radius: 26px; overflow: hidden; border: 4px solid #000; box-shadow: 0 10px 0 #000, 0 0 0 2px rgba(255,210,31,.25) inset; background: radial-gradient(120% 80% at 50% 0%, #2b2108 0%, #12171d 55%, #0a0d11 100%); }
.vd-stage { position: relative; overflow: hidden; cursor: pointer; }
.vd-stage.paused * { animation-play-state: paused !important; }
.vd-scene { position: absolute; inset: 0; display: grid; place-items: center; padding: 22px 18px; overflow-y: auto; animation: vdIn .45s cubic-bezier(.2,1.2,.4,1) both; }
@keyframes vdIn { from { opacity: 0; transform: scale(.94) translateY(10px); } to { opacity: 1; transform: none; } }
.vd-c { width: 100%; display: grid; gap: 14px; justify-items: center; text-align: center; }
.vd-kicker { font: 800 12px var(--body); letter-spacing: .2em; text-transform: uppercase; color: var(--dim); animation: vdUp .5s .5s both; position: relative; }
.vd-big { position: relative; font: 400 clamp(34px, 9vw, 46px)/1 var(--title); letter-spacing: .03em; text-shadow: 3px 3px 0 #000; animation: vdSlam .6s .8s cubic-bezier(.2,1.5,.4,1) both; }
.vd-big b { color: var(--yellow); font-weight: 400; }
.vd-h { font: 400 32px/1.02 var(--title); letter-spacing: .04em; text-shadow: 3px 3px 0 #000; animation: vdSlam .5s .1s cubic-bezier(.2,1.5,.4,1) both; }
.vd-step { width: 44px; height: 44px; border-radius: 50%; background: var(--yellow); color: #111; display: grid; place-items: center; font: 400 26px var(--title); border: 3px solid #000; box-shadow: 0 4px 0 #000; animation: vdPop .4s both; }
.vd-me { position: relative; width: 120px; height: 120px; border-radius: 30px; border: 4px solid #000; box-shadow: 0 6px 0 #000, 0 0 0 4px var(--yellow); object-fit: cover; animation: vdPop .6s .2s cubic-bezier(.2,1.6,.4,1) both; }
.vd-rays { position: absolute; inset: -60%; background: repeating-conic-gradient(from 0deg, rgba(255,210,31,.09) 0 10deg, transparent 10deg 20deg); animation: vdSpin 18s linear infinite; pointer-events: none; }
.vd-intro, .vd-outro { position: relative; }
.vd-note { font-size: 12.5px; color: var(--dim); font-weight: 600; max-width: 32ch; animation: vdUp .5s 1.2s both; }
.vd-c > .vd-note:last-child { animation-delay: 5s; }
.vd-code { position: relative; display: grid; gap: 2px; padding: 10px 26px; border-radius: 16px; border: 3px dashed rgba(255,210,31,.6); background: rgba(255,210,31,.08); animation: vdPop .5s .6s cubic-bezier(.2,1.6,.4,1) both; }
.vd-code small { font-size: 11px; font-weight: 800; color: var(--dim); text-transform: uppercase; letter-spacing: .1em; }
.vd-code b { font: 400 40px/1 var(--title); letter-spacing: .1em; color: var(--yellow); }
.vd-link { font: 800 14px var(--body); color: #fff; padding: 8px 14px; border-radius: 12px; background: rgba(255,255,255,.07); overflow: hidden; white-space: nowrap; max-width: 100%; animation: vdType 1.4s 1.4s steps(18) both; }
@keyframes vdType { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
.vd-fly { display: flex; gap: 10px; }
.vd-fly img { width: 54px; height: 54px; border-radius: 15px; border: 3px solid #000; box-shadow: 0 4px 0 #000; animation: vdJoin .6s calc(3.2s + var(--k) * .35s) cubic-bezier(.2,1.5,.4,1) both; }
@keyframes vdJoin { from { opacity: 0; transform: translateY(40px) scale(.5) rotate(-12deg); } to { opacity: 1; transform: none; } }
.vd-duel { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; width: 100%; }
.vd-f { display: grid; justify-items: center; gap: 4px; animation: vdUp .5s .3s both; }
.vd-f:last-child { animation-delay: .5s; }
.vd-f img { width: 76px; height: 76px; border-radius: 20px; border: 3px solid #000; box-shadow: 0 4px 0 #000; }
.vd-f b { font-size: 14px; }
.vd-f em { font-style: normal; font-size: 10.5px; font-weight: 800; color: #111; background: var(--yellow); padding: 1px 6px; border-radius: 6px; min-height: 16px; }
.vd-f em:empty { background: transparent; }
.vd-bet { font: 400 22px var(--title); letter-spacing: .03em; }
.vd-bet i { font-style: normal; color: var(--cyan); }
.vd-vs { font: 400 40px var(--title); color: var(--yellow); text-shadow: 3px 3px 0 #000; animation: vdSlam .5s .9s cubic-bezier(.2,1.6,.4,1) both; }
.vd-split { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; }
.vd-split > div { border-radius: 16px; padding: 10px; border: 3px solid #000; display: grid; gap: 2px; }
.vd-split small { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.vd-split b { font: 400 34px/1 var(--title); letter-spacing: .04em; }
.vd-split span { font-size: 11.5px; font-weight: 700; }
.vd-pot { background: rgba(255,255,255,.06); animation: vdPop .5s 2.2s cubic-bezier(.2,1.6,.4,1) both; }
.vd-pot span { color: var(--dim); }
.vd-split .vd-fee { background: rgba(46,230,214,.12); border-color: var(--cyan); animation: vdPop .5s 3.6s cubic-bezier(.2,1.6,.4,1) both, vdGlow 1.2s 4.2s ease-in-out 3; }
.vd-fee b, .vd-fee small { color: var(--cyan); }
@keyframes vdGlow { 50% { box-shadow: 0 0 0 6px rgba(46,230,214,.25); } }
.vd-tree { display: grid; gap: 7px; width: 100%; }
.vd-root { display: flex; align-items: center; justify-content: center; gap: 10px; animation: vdPop .4s both; }
.vd-root img { width: 44px; height: 44px; border-radius: 12px; border: 3px solid #000; box-shadow: 0 0 0 3px var(--yellow); }
.vd-root b { font: 400 24px var(--title); letter-spacing: .05em; color: var(--yellow); }
.vd-lv { display: grid; grid-template-columns: 40px 46px 1fr; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 12px; background: rgba(255,255,255,.05); animation: vdLeft .45s var(--d) cubic-bezier(.2,1.3,.4,1) both; }
.vd-lvb { width: 36px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--yellow); color: #111; font: 400 18px var(--title); border: 2px solid #000; }
.vd-pc { font-weight: 800; font-size: 13px; color: #ffe9a0; }
.vd-avs { display: flex; flex-wrap: wrap; gap: 3px; }
.vd-avs img { width: 26px; height: 26px; border-radius: 8px; border: 2px solid #000; animation: vdPop .3s calc(var(--d) + .2s + var(--k) * .04s) both; }
@keyframes vdLeft { from { opacity: 0; transform: translateX(-30px); } to { opacity: 1; transform: none; } }
.vd-calc { display: grid; gap: 6px; width: 100%; }
.vd-cr { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 12px; background: rgba(255,255,255,.05); font-size: 13px; font-weight: 700; color: var(--dim); text-align: left; animation: vdLeft .4s var(--d) both; }
.vd-cr b { font: 400 22px var(--title); color: var(--green); letter-spacing: .03em; }
.vd-total { display: grid; padding: 10px 26px; border-radius: 18px; background: var(--yellow); color: #111; border: 3px solid #000; box-shadow: 0 6px 0 #000; animation: vdSlam .6s var(--d) cubic-bezier(.2,1.6,.4,1) both; }
.vd-total small { font-size: 12px; font-weight: 800; }
.vd-total b { font: 400 48px/1 var(--title); letter-spacing: .04em; }
.vd-scale { display: grid; gap: 12px; width: 100%; }
.vd-scale > div { padding: 14px; border-radius: 18px; background: rgba(255,255,255,.06); border: 3px solid #000; display: grid; animation: vdSlam .55s var(--d) cubic-bezier(.2,1.6,.4,1) both; }
.vd-scale small { font-size: 12px; font-weight: 800; color: var(--dim); text-transform: uppercase; letter-spacing: .08em; }
.vd-scale b { font: 400 50px/1.05 var(--title); letter-spacing: .04em; }
.vd-scale b.g { color: var(--green); }
.vd-rules { display: grid; gap: 9px; width: 100%; }
.vd-rules > div { padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.06); border-left: 5px solid var(--yellow); font-weight: 800; font-size: 15px; text-align: left; animation: vdLeft .45s var(--d) cubic-bezier(.2,1.3,.4,1) both; }
.vd-share { position: relative; z-index: 2; padding: 12px 22px; border-radius: 16px; border: 3px solid #000; background: var(--yellow); color: #111; font: 400 22px var(--title); letter-spacing: .05em; box-shadow: 0 5px 0 #000; animation: vdPop .5s 1.4s cubic-bezier(.2,1.6,.4,1) both, vdPulseB 1.6s 2s ease-in-out infinite; }
@keyframes vdPulseB { 50% { transform: scale(1.06); } }
.vd-cap { min-height: 56px; padding: 8px 16px; font-size: 13.5px; font-weight: 700; text-align: center; color: #eef3f6; background: rgba(0,0,0,.45); display: grid; place-items: center; line-height: 1.35; }
.vd-ctrl { display: flex; align-items: center; gap: 10px; padding: 10px 12px 12px; background: rgba(0,0,0,.55); }
.vd-ctrl button { flex: none; width: 38px; height: 38px; border-radius: 12px; border: 2px solid #000; background: rgba(255,255,255,.1); color: #fff; font-weight: 800; font-size: 14px; }
.vd-prog { flex: 1; height: 8px; border-radius: 5px; background: rgba(255,255,255,.12); overflow: hidden; cursor: pointer; }
.vd-prog i { display: block; height: 100%; width: 0; background: var(--yellow); border-radius: 5px; }
.vd-time { font: 700 12px var(--body); color: var(--dim); font-variant-numeric: tabular-nums; min-width: 72px; text-align: right; }
.vd-replay { position: absolute; left: 50%; top: 16%; transform: translateX(-50%); width: 70px; height: 70px; border-radius: 50%; border: 3px solid #000; background: var(--yellow); color: #111; font-size: 32px; font-weight: 800; box-shadow: 0 5px 0 #000; display: none; z-index: 3; }
.vd-root-ov.ended .vd-replay { display: grid; place-items: center; }
@keyframes vdPop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: none; } }
@keyframes vdSlam { 0% { opacity: 0; transform: scale(1.8); } 70% { opacity: 1; transform: scale(.95); } 100% { transform: none; } }
@keyframes vdUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes vdSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .vd-rays { animation: none; } }
/* video v2: step counter, running gain, the chain */
.vd-frame { grid-template-rows: auto 1fr auto auto; }
.vd-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px 0; position: relative; z-index: 2; }
.vd-steps { font: 800 12px var(--body); color: var(--dim); letter-spacing: .08em; background: rgba(255,255,255,.07); padding: 4px 9px; border-radius: 8px; }
.vd-gain { display: grid; justify-items: end; padding: 5px 12px; border-radius: 12px; background: rgba(75,227,122,.12); border: 2px solid rgba(75,227,122,.5); transition: opacity .3s; }
.vd-gain.off { opacity: 0; }
.vd-gain small { font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--green); }
.vd-gain b { font: 400 26px/1 var(--title); letter-spacing: .04em; color: #fff; font-variant-numeric: tabular-nums; }
.vd-gain.bump { animation: vdGainBump .6s cubic-bezier(.2,1.6,.4,1); }
@keyframes vdGainBump { 0% { transform: scale(1); } 40% { transform: scale(1.25); box-shadow: 0 0 0 8px rgba(75,227,122,.25); } 100% { transform: scale(1); } }
.vd-lvbig { font: 400 46px/1 var(--title); letter-spacing: .05em; color: var(--yellow); text-shadow: 3px 3px 0 #000; animation: vdSlam .5s .05s cubic-bezier(.2,1.5,.4,1) both; }
.vd-sub { font-size: 16px; font-weight: 800; max-width: 30ch; animation: vdUp .4s .35s both; }
.vd-chain { position: relative; display: grid; gap: 8px; width: 100%; }
.vd-chain::before { content: ""; position: absolute; left: 27px; top: 22px; bottom: 22px; border-left: 3px dashed rgba(255,210,31,.35); }
.vd-row { position: relative; display: grid; grid-template-columns: 44px 1fr auto auto; align-items: center; gap: 8px; padding: 6px 8px 6px 6px; border-radius: 14px; background: rgba(255,255,255,.05); text-align: left; animation: vdUp .35s var(--r) both; }
.vd-row img { width: 40px; height: 40px; border-radius: 11px; border: 2px solid #000; position: relative; z-index: 1; }
.vd-row.me { background: rgba(255,210,31,.12); border: 2px solid rgba(255,210,31,.55); }
.vd-row.me img { box-shadow: 0 0 0 3px var(--yellow); }
.vd-row.pl { background: rgba(46,230,214,.1); border: 2px solid rgba(46,230,214,.5); }
.vd-nm { font-weight: 800; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vd-tag { font-size: 10.5px; font-weight: 800; color: var(--dim); background: rgba(255,255,255,.08); padding: 2px 6px; border-radius: 6px; white-space: nowrap; }
.vd-tag.me { background: var(--yellow); color: #111; }
.vd-chip { display: grid; justify-items: end; font: 400 22px/1 var(--title); letter-spacing: .03em; color: var(--green); animation: vdChip .55s var(--d) cubic-bezier(.2,1.6,.4,1) both; min-width: 64px; }
.vd-chip small { font: 800 10px var(--body); color: var(--dim); }
.vd-chip.me { font-size: 28px; color: var(--yellow); text-shadow: 2px 2px 0 #000; }
@keyframes vdChip { 0% { opacity: 0; transform: translateY(26px) scale(.5); } 100% { opacity: 1; transform: none; } }
.vd-coin { display: grid; justify-items: end; font-size: 11px; font-weight: 800; color: var(--cyan); animation: vdPop .5s var(--d) cubic-bezier(.2,1.6,.4,1) both, vdGlow 1s calc(var(--d) + .5s) ease-in-out 2; border-radius: 10px; padding: 2px 4px; grid-column: 3 / span 2; }
.vd-coin b { font: 400 20px/1 var(--title); letter-spacing: .03em; color: #fff; }
.vd-ladder { display: grid; gap: 8px; width: 100%; }
.vd-ladder > div { display: grid; grid-template-columns: 40px 1fr 72px; align-items: center; gap: 8px; animation: vdLeft .45s var(--d) both; }
.vd-ladder i { display: block; height: 18px; width: var(--w); border-radius: 9px; background: linear-gradient(90deg, #ffb800, #ffe45a); border: 2px solid #000; }
.vd-ladder b { font: 400 24px var(--title); color: var(--green); text-align: right; letter-spacing: .03em; }
.vd-cr { grid-template-columns: 40px 1fr auto auto; }
.vd-cr .vd-avs img { width: 18px; height: 18px; border-radius: 5px; border-width: 1.5px; animation: none; }
.vd-x { font-size: 12px; white-space: nowrap; }
.vd-shield { font-size: 56px; animation: vdPop .5s both; }
.vd-feebar { width: 100%; display: grid; gap: 8px; }
.vd-fb { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; border-radius: 12px; background: rgba(255,255,255,.06); font-weight: 800; animation: vdUp .4s .5s both; }
.vd-fb b { font: 400 26px var(--title); color: var(--cyan); }
.vd-fbsplit { display: flex; height: 46px; border-radius: 14px; overflow: hidden; border: 3px solid #000; }
.vd-fbsplit > div { display: grid; place-items: center; background: rgba(46,230,214,.25); font-size: 12px; font-weight: 800; animation: vdGrow .6s var(--d) both; transform-origin: left; }
.vd-fbsplit > div.you { background: var(--yellow); color: #111; }
@keyframes vdGrow { from { transform: scaleX(0); } to { transform: none; } }
.vd-ctrl { gap: 6px; }
.vd-ctrl .vd-voice.off { opacity: .4; text-decoration: line-through; }
@media (max-height: 700px) { .vd-row img { width: 32px; height: 32px; } .vd-row { grid-template-columns: 36px 1fr auto auto; padding: 4px 6px; } .vd-lvbig { font-size: 36px; } .vd-cap { min-height: 44px; font-size: 12.5px; } }

/* ── FREE room (training credits vs AI) ── */
.room-free { background: linear-gradient(135deg, #35c46a, #127a3c); animation-delay: .2s; }
.room-free .room-ico img { transform: rotate(-20deg); }
.room-stake b { color: #fff; }
#scr-result.free .xp-box, #scr-result.free .levelup { display: none !important; }
.money-box.free small { opacity: .85; }
/* operator: AI players */
.bot-admin .chk { display: flex; align-items: center; gap: 8px; font-weight: 700; margin: 6px 0 10px; }
.bot-admin .chk input { width: 20px; height: 20px; accent-color: var(--yellow); }
.bota-grid { grid-template-columns: 1fr 1fr; }
.bot-admin select { height: 46px; flex: 1; min-width: 0; border-radius: 12px; border: 3px solid #000; background: #1b232b; color: #fff; font: 600 14px var(--body); padding: 0 8px; }
.bot-admin .inv-row { margin-top: 8px; }
.bot-admin .inv-row .btn { flex: 1; }
.bot-admin .hint.bad { color: #ffb4ad; }
.bot-admin td.pos { color: var(--green); } .bot-admin td.neg { color: #ff8a80; }

/* ── TUTORIAL (CoachIA) ── */
.tuto { position: fixed; left: 0; right: 0; top: 26%; z-index: 60; display: flex; justify-content: center; padding: 0 12px; pointer-events: none; }
.tuto.top { top: 8%; }
.tuto.bottom { top: auto; bottom: 96px; }
.tuto-card { pointer-events: auto; width: min(460px, 100%); background: rgba(13, 18, 24, .96); border: 4px solid #000; border-radius: 22px; box-shadow: 0 8px 0 #000, 0 0 0 3px var(--yellow) inset; padding: 14px 14px 12px; }
.tuto-head { display: flex; align-items: center; gap: 10px; }
.tuto-head .av { width: 46px; height: 46px; border-radius: 14px; border: 3px solid #000; object-fit: cover; }
.tuto-head b { font: 400 22px/1 var(--title); letter-spacing: .04em; color: var(--yellow); text-shadow: 2px 2px 0 #000; }
.tuto-head small { display: block; font-size: 11px; font-weight: 800; color: var(--dim); letter-spacing: .06em; margin-top: 3px; }
.tuto-head > div { flex: 1; min-width: 0; }
.tuto-x { width: 34px; height: 34px; border-radius: 10px; background: rgba(255,255,255,.08); border: 2px solid #000; font-weight: 900; }
.tuto-txt { margin: 10px 2px 12px; font-size: 16px; line-height: 1.4; font-weight: 600; }
.tuto-extra:empty { display: none; }
.tuto-extra { margin-top: 10px; }
.tuto-extra .vs-style { margin: 0 auto 8px; max-width: 280px; }
.tuto-deck { display: inline-flex; gap: 6px; }
.tuto-deck span { display: inline-flex; align-items: center; gap: 3px; background: rgba(255,255,255,.08); border: 2px solid #000; border-radius: 10px; padding: 3px 8px; font-size: 18px; }
.tuto-deck span b { font-size: 14px; }
.tuto-deck span.out { opacity: .35; text-decoration: line-through; }
.tuto-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; justify-content: center; }
.tuto-arrow { font-size: 18px; color: var(--yellow); }
.tuto-chip { display: inline-flex; flex-direction: column; align-items: center; background: var(--yellow); color: #111; border: 2px solid #000; border-radius: 10px; padding: 4px 9px; font: 400 17px/1.1 var(--title); letter-spacing: .03em; }
.tuto-chip small { font: 800 10px var(--body); }
.tuto-focus { outline: 3px solid var(--yellow) !important; outline-offset: 3px; border-radius: 12px; animation: tutoPulse 1.1s ease-in-out infinite; position: relative; z-index: 2; }
@keyframes tutoPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 210, 31, .7); } 50% { box-shadow: 0 0 0 10px rgba(255, 210, 31, 0); } }
.tuto-box { display: grid; gap: 8px; margin: 6px 0 14px; }
.tuto-chaps { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.tuto-chap { display: flex; align-items: center; gap: 8px; text-align: left; padding: 8px 10px; border-radius: 12px; border: 3px solid #000; background: rgba(255,255,255,.07); font-size: 13px; font-weight: 700; }
.tuto-chap b { flex: none; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 8px; background: var(--yellow); color: #111; font: 400 16px var(--title); }
.tuto-chap:last-child { grid-column: span 2; }
.tuto-av { width: 84px; height: 84px; border-radius: 22px; border: 4px solid #000; display: block; margin: 0 auto 8px; object-fit: cover; }
#tuto-end .btn, #tuto-ask .btn { width: 100%; }
#tuto-end .row { margin-top: 8px; }

.tuto-ptr { position: fixed; z-index: 70; width: 34px; height: 44px; margin-left: -17px; pointer-events: none; filter: drop-shadow(0 3px 0 rgba(0,0,0,.55)); }
.tuto-ptr svg { width: 100%; height: 100%; display: block; }
.tuto-ptr.up { animation: ptrUp .8s ease-in-out infinite; }
.tuto-ptr.down { margin-top: -44px; animation: ptrDown .8s ease-in-out infinite; }
.tuto-ptr.down svg { transform: rotate(180deg); }
@keyframes ptrUp { 0%, 100% { transform: translateY(6px); } 50% { transform: translateY(0); } }
@keyframes ptrDown { 0%, 100% { transform: translateY(-6px); } 50% { transform: translateY(0); } }

/* tutorial: keep the hands readable while the coach points at them */
.moves.locked.tuto-show .move:not(.sel) { opacity: 1; filter: none; }
.move .cnt.tuto-focus { outline: none !important; animation: none; background: rgba(0,0,0,.8); padding: 1px 7px; border-radius: 9px; box-shadow: 0 0 0 2px var(--yellow); transform: scale(1.2); transform-origin: top right; }

/* ── account: responsible gaming · identity · security · data ── */
#pf-rg .field-label, #pf-sec .field-label, #pf-data .field-label { font-size: 17px; margin: 16px 0 6px; }
.rg-row { display: grid; grid-template-columns: 1fr 74px auto 30px; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,.07); }
.rg-row:last-of-type { border-bottom: 0; }
.rg-l b { display: block; font-size: 14px; }
.rg-l small { display: block; color: var(--dim); font-size: 12px; line-height: 1.35; }
.rg-l small i { display: block; color: #ffe9a0; font-style: normal; }
.rg-bar { display: block; height: 5px; margin-top: 5px; border-radius: 3px; background: rgba(255,255,255,.1); overflow: hidden; }
.rg-bar i { display: block; height: 100%; background: var(--yellow); }
.rg-row input { height: 40px; padding: 0 8px; font-size: 15px; border-radius: 11px; text-align: center; min-width: 0; }
.rg-row .btn { min-height: 40px; padding: 0 12px; font-size: 16px; width: auto; }
.rg-off { width: 30px; height: 30px; border-radius: 50%; border: 2px solid #000; background: rgba(255,255,255,.1); color: #ffb4ad; font-weight: 900; }
.rg-durs { justify-content: flex-start; margin: 8px 0 10px; }
.rg-go { width: 100%; }
.rg-excl { margin: 4px 0 8px; padding: 10px 12px; border-radius: 12px; background: rgba(255,90,60,.15); border: 2px solid rgba(255,120,90,.5); color: #ffd0c8; font-weight: 700; font-size: 14px; }
.rg-help { margin-top: 14px; font-size: 12px; }
.hint.bad { color: #ffb4ad; }
#acc-kyc-cur.kyc-ok { background: #2fbf71; color: #04210f; }
#acc-kyc-cur.kyc-pending, #acc-kyc-cur.kyc-started { background: #ffd21f; color: #1a1100; }
#acc-kyc-cur.kyc-retry, #acc-kyc-cur.kyc-rejected { background: #ff6a5a; color: #2a0500; }
#pf-kyc .btn { margin-top: 12px; width: 100%; }
#kyc-sdk { margin-top: 10px; border-radius: 12px; overflow: hidden; }
#kyc-sdk:empty { display: none; }
.sec-mail { display: flex; align-items: center; gap: 10px; justify-content: space-between; }
.sec-mail b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.sec-mail .btn { width: auto; min-height: 38px; padding: 0 12px; font-size: 15px; }
.sec-form { margin-top: 8px; }
.sec-form .inv-row input { min-width: 0; }
#sec-msg .btn { display: inline-flex; width: auto; min-height: 38px; padding: 0 14px; font-size: 15px; margin-top: 6px; }
.sec-list { list-style: none; margin: 0; padding: 0; }
.sec-list li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,.07); }
.sec-list li b { display: block; font-size: 14px; }
.sec-list li small { color: var(--dim); font-size: 12px; }
.sec-list .btn { width: auto; min-height: 36px; padding: 0 12px; font-size: 14px; }
.sec-cur { width: 10px; height: 10px; border-radius: 50%; background: #2fbf71; box-shadow: 0 0 0 3px rgba(47,191,113,.25); }
.sec-all { width: 100%; margin-top: 10px; font-size: 15px; }
#pf-data .btn { width: 100%; margin-top: 10px; text-decoration: none; font-size: 17px; }
#pf-data .inv-row { margin-top: 10px; }
.acc summary em:empty { display: none; }

/* visitors: nothing but the home screen and the sign-in */
body.guest #btn-rules, body.guest #nav, body.guest #btn-friends, body.guest #btn-bell { display: none !important; }
.auth-code-l { margin: 4px 0 -6px; font-size: 17px; }
.auth-form .ref-check { margin: -6px 0 0; min-height: 0; }
.auth-code-h { margin: -8px 0 0; font-size: 12px; }

.opt-chk { display: flex; align-items: flex-start; gap: 10px; margin: 14px 0 4px; font-weight: 700; font-size: 14px; line-height: 1.35; cursor: pointer; text-align: left; }
.opt-chk input { flex: none; width: 22px; height: 22px; margin: 0; accent-color: var(--yellow); box-shadow: none; }
#pf-data .opt-chk { margin: 0 0 12px; }
.set-curs { margin-top: 0; margin-bottom: 4px; }
.set-fx { margin: 0 2px 12px; font-size: 11px; color: var(--dim); }

.opt-chk a { color: var(--yellow); text-decoration: underline; }
.opt-chk.shake { animation: optShake .4s; color: #ffb4ad; }
@keyframes optShake { 0%,100% { transform: none } 25% { transform: translateX(-6px) } 75% { transform: translateX(6px) } }
.auth-captcha { min-height: 65px; display: flex; justify-content: center; }

/* info pages */
.legal-panel { position: relative; width: min(680px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); display: flex; flex-direction: column; }
.legal-x { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border-radius: 50%; border: 3px solid #000; background: rgba(255,255,255,.1); color: #fff; font-weight: 900; }
.legal-frame { flex: 1; min-height: 40vh; overflow-y: auto; margin: 8px 0 6px; padding: 16px 18px; border-radius: 14px; border: 2px solid rgba(255,210,31,.35); background: rgba(0,0,0,.35); box-shadow: inset 0 2px 10px rgba(0,0,0,.4); }
.legal-body { text-align: left; font-size: 14px; line-height: 1.6; color: #dfe6ea; overflow-wrap: anywhere; }
.legal-body p { margin: 0 0 10px; }
.legal-body h3, .legal-body h4, .legal-body h5 { font-family: var(--title); letter-spacing: .05em; color: var(--yellow); margin: 14px 0 6px; font-weight: 400; }
.legal-body h3 { font-size: 22px; } .legal-body h4 { font-size: 18px; } .legal-body h5 { font-size: 16px; }
.legal-body ul { margin: 0 0 10px; padding-left: 20px; }
.legal-body li { margin: 3px 0; }
.legal-body a { color: var(--yellow); }
.legal-empty { color: var(--dim); text-align: center; margin-top: 15vh !important; font-style: italic; }
.legal-upd { color: var(--dim); font-size: 12px; margin: 0 0 10px; min-height: 1em; }
.set-pages button { background: none; border: 0; padding: 1px 0; font-size: 11px; font-weight: 700; color: rgba(255,255,255,.7); text-decoration: underline; text-underline-offset: 2px; text-align: left; }
.set-pages button:hover { color: #fff; }
.set-pages { display: flex; flex-wrap: wrap; gap: 2px 12px; margin: 0 2px 2px; }
.pages-admin select, .pages-admin textarea { width: 100%; border-radius: 12px; border: 3px solid #000; background: #fff; color: #111; font: 600 14px/1.45 var(--body); padding: 10px 12px; margin: 6px 0 8px; }
.pages-admin textarea { resize: vertical; min-height: 220px; font-family: ui-monospace, Menlo, monospace; font-size: 13px; }
.pages-admin .inv-row .btn { flex: 1; }

.set-select { width: 100%; height: 44px; margin: 0 0 14px; padding: 0 40px 0 12px; border-radius: 12px; border: 3px solid #000; background: rgba(255,255,255,.07) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffd21f' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 16px; color: #fff; font: 800 15px var(--body); appearance: none; -webkit-appearance: none; cursor: pointer; }
.set-select option { background: #1a2028; color: #fff; }

/* support tickets */
body.guest .set-contact { display: none !important; }
.set-pages .set-contact { color: var(--yellow); }
.sup-panel { position: relative; width: min(620px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); display: flex; flex-direction: column; text-align: left; }
.sup-panel .title { text-align: center; }
.sup-view { overflow-y: auto; min-height: 0; flex: 1; display: flex; flex-direction: column; }
.sup-view.hidden { display: none; }
.sup-intro { text-align: center; margin-bottom: 10px; }
.sup-newbtn { width: 100%; }
.sup-tlist, .supa-list { list-style: none; margin: 0; padding: 0; }
.sup-tlist li, .supa-list li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; margin-bottom: 6px; border-radius: 12px; background: rgba(255,255,255,.05); cursor: pointer; }
.sup-tlist li.new, .supa-list li.new { background: rgba(255,210,31,.1); box-shadow: inset 3px 0 0 var(--yellow); }
.sup-tlist li small, .supa-list li small, .sup-head small { display: block; color: var(--dim); font-size: 12px; margin-top: 2px; overflow-wrap: anywhere; }
.supa-list li.empty { cursor: default; color: var(--dim); }
.sup-st { flex: none; font-size: 11px; font-weight: 900; padding: 3px 8px; border-radius: 8px; border: 2px solid #000; white-space: nowrap; }
.sup-st-open { background: #ffd21f; color: #1a1100; }
.sup-st-progress { background: #5fb0ff; color: #001a33; }
.sup-st-resolved { background: #2fbf71; color: #04210f; }
.sup-select, .sup-text { width: 100%; border-radius: 12px; border: 3px solid #000; background: #fff; color: #111; font: 600 15px/1.4 var(--body); padding: 10px 12px; }
.sup-select { height: 46px; padding: 0 10px; }
.sup-text { resize: vertical; min-height: 54px; }
.sup-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; padding: 4px 2px 10px; border-bottom: 1px solid rgba(255,255,255,.1); }
.sup-msgs { flex: 1; min-height: 140px; max-height: 46vh; overflow-y: auto; padding: 10px 2px; display: flex; flex-direction: column; gap: 8px; }
.sup-msg { max-width: 86%; padding: 8px 12px; border-radius: 14px; background: rgba(255,255,255,.08); }
.sup-msg.me { align-self: flex-end; background: rgba(255,210,31,.16); border-bottom-right-radius: 4px; }
.sup-msg.adm { align-self: flex-start; background: rgba(95,176,255,.18); border-bottom-left-radius: 4px; }
.sup-msg.av.me { align-self: flex-start; background: rgba(255,255,255,.08); border-radius: 14px; }
.sup-msg.av.adm { align-self: flex-end; }
.sup-msg small { display: block; color: var(--dim); font-size: 11px; margin-bottom: 2px; }
.sup-msg p { margin: 0; font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; }
.sup-reply { display: flex; gap: 8px; align-items: flex-end; margin-top: 6px; }
.sup-reply .btn { width: auto; min-height: 54px; padding: 0 16px; font-size: 18px; }
#sup-tolist { align-self: center; }
.nt-ico { width: 38px; height: 38px; flex: none; display: grid; place-items: center; font-size: 22px; border-radius: 11px; background: rgba(255,255,255,.08); }
.nt-ticket { cursor: pointer; }
.supa-count { font-style: normal; font-size: 13px; color: #1a1100; background: var(--yellow); border-radius: 8px; padding: 1px 8px; vertical-align: middle; }
.supa-count:empty { display: none; }
.supa-filter { justify-content: flex-start; margin-bottom: 8px; }
.tickets-admin .inv-row { margin-top: 8px; }
.tickets-admin .inv-row .btn { flex: 1; }
.tickets-admin .sup-msgs { max-height: 320px; }

.opskey-val { font: 600 12px ui-monospace, Menlo, monospace; word-break: break-all; background: rgba(0,0,0,.4); border: 1px solid rgba(255,255,255,.15); border-radius: 10px; padding: 10px; margin: 8px 0; user-select: all; }
.opskey-box .btn { width: 100%; margin-top: 6px; }

/* operator tools moved to the external console */
#acc-house > .acc-body:not(.opskey-box) { display: none !important; }

/* operator announcement banner (home) */
.announce { display: flex; align-items: flex-start; gap: 10px; max-width: 440px; width: calc(100% - 32px); margin: 0 auto 6px; padding: 10px 12px 10px 14px; border: 3px solid #000; border-radius: 14px; font-weight: 600; font-size: 14px; line-height: 1.35; text-align: left; box-shadow: 0 4px 0 #000; }
.announce.info { background: #e8f1ff; color: #10213f; }
.announce.warn { background: #ffe9b8; color: #3d2800; }
.announce span { flex: 1; white-space: pre-line; }
.announce button { flex: none; border: 0; background: transparent; font-size: 20px; line-height: 1; font-weight: 800; cursor: pointer; color: inherit; padding: 0 2px; }
.announce.hidden { display: none; }

/* geo-blocking: full-screen notice */
.geo-block { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; padding: 24px; background: rgba(8, 10, 16, 0.92); }
.geo-block.hidden { display: none; }
.geo-panel { max-width: 420px; background: var(--panel, #1b1f2a); color: #fff; border: 3px solid #000; border-radius: 18px; padding: 24px 22px; text-align: center; box-shadow: 0 6px 0 #000; }
.geo-panel h2 { margin: 0 0 10px; font-size: 22px; }
.geo-panel p { margin: 0; line-height: 1.45; color: #d6d9e0; }

/* referral network: long lists, removed/sanctioned members, small screens */
.aff-m span { min-width: 0; }
.aff-m.off { opacity: .6; }
.aff-m.off span i { font-style: italic; font-weight: 700; color: var(--dim); }
.aff-m em.st-deleted { background: rgba(255,255,255,.06); color: var(--dim); }
.aff-m em.st-banned { background: rgba(255,59,47,.18); color: #ff6b61; }
.aff-m em.st-suspended { background: rgba(255,170,0,.18); color: #ffb020; }
.aff-more { width: 100%; margin-top: 4px; padding: 8px; font-size: 12px; }
.aff-lv summary b { font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 380px) { .aff-m { grid-template-columns: 26px 1fr auto; } .aff-m small { display: none; } .aff-m .av { width: 26px; height: 26px; } }

/* ───────── grand opening countdown ───────── */
.opening { --c1: #ff6a3d; --c2: #ffd21f; --glow: rgba(255,90,30,.55); position: relative; width: min(440px, 92vw); padding: 18px 16px 16px; border-radius: 24px; border: 4px solid #000; background: radial-gradient(120% 90% at 50% 0%, rgba(255,255,255,.08), rgba(0,0,0,.55) 60%), rgba(10,12,16,.82); box-shadow: 0 8px 0 #000, 0 0 40px var(--glow); text-align: center; overflow: hidden; isolation: isolate; animation: opIn .6s cubic-bezier(.2,1.4,.4,1) both; }
.opening.theme-neon { --c1: #2ef2ff; --c2: #ff3df2; --glow: rgba(60,220,255,.5); }
.opening.theme-gold { --c1: #ffb300; --c2: #fff2a8; --glow: rgba(255,200,40,.55); }
.op-glow { position: absolute; inset: -40%; z-index: -1; background: conic-gradient(from 0deg, transparent, var(--c1), transparent 30%, var(--c2), transparent 60%); opacity: .22; animation: opSpin 9s linear infinite; }
.op-sparks i { position: absolute; bottom: -10px; width: 4px; height: 4px; border-radius: 50%; background: var(--c2); box-shadow: 0 0 8px var(--c1); opacity: 0; animation: opSpark 4s linear infinite; }
.op-sparks i:nth-child(odd) { background: var(--c1); }
.op-sparks i:nth-child(1) { left: 5%; animation-delay: 0.00s; animation-duration: 3.0s; }
.op-sparks i:nth-child(2) { left: 12%; animation-delay: 0.29s; animation-duration: 3.6s; }
.op-sparks i:nth-child(3) { left: 19%; animation-delay: 0.58s; animation-duration: 4.2s; }
.op-sparks i:nth-child(4) { left: 26%; animation-delay: 0.87s; animation-duration: 4.8s; }
.op-sparks i:nth-child(5) { left: 33%; animation-delay: 1.16s; animation-duration: 5.4s; }
.op-sparks i:nth-child(6) { left: 40%; animation-delay: 1.45s; animation-duration: 3.0s; }
.op-sparks i:nth-child(7) { left: 47%; animation-delay: 1.74s; animation-duration: 3.6s; }
.op-sparks i:nth-child(8) { left: 54%; animation-delay: 2.03s; animation-duration: 4.2s; }
.op-sparks i:nth-child(9) { left: 61%; animation-delay: 2.32s; animation-duration: 4.8s; }
.op-sparks i:nth-child(10) { left: 68%; animation-delay: 2.61s; animation-duration: 5.4s; }
.op-sparks i:nth-child(11) { left: 75%; animation-delay: 2.90s; animation-duration: 3.0s; }
.op-sparks i:nth-child(12) { left: 82%; animation-delay: 3.19s; animation-duration: 3.6s; }
.op-sparks i:nth-child(13) { left: 89%; animation-delay: 3.48s; animation-duration: 4.2s; }
.op-sparks i:nth-child(14) { left: 0%; animation-delay: 3.77s; animation-duration: 4.8s; }

.op-kicker { display: inline-block; font: 400 15px var(--title); letter-spacing: .18em; color: #000; background: linear-gradient(90deg, var(--c1), var(--c2)); padding: 3px 12px; border-radius: 999px; border: 2px solid #000; animation: opBlink 2.4s ease-in-out infinite; }
.op-title { margin: 10px 0 8px; font: 400 clamp(26px, 7vw, 38px)/1.05 var(--title); letter-spacing: .04em; color: #fff; text-shadow: 0 3px 0 #000, 0 0 18px var(--glow); }
.op-clock { display: flex; justify-content: center; align-items: flex-start; gap: 4px; margin: 6px 0 4px; }
.op-u { display: flex; flex-direction: column; align-items: center; min-width: 0; flex: 0 1 70px; }
.op-u b { display: block; width: 100%; font: 400 clamp(34px, 11vw, 52px)/1 var(--title); font-variant-numeric: tabular-nums; color: #000; background: linear-gradient(#fff, var(--c2) 55%, var(--c1)); border: 3px solid #000; border-radius: 14px; padding: 6px 0 4px; box-shadow: 0 5px 0 #000, inset 0 -6px 0 rgba(0,0,0,.18); }
.op-u b.tick { animation: opTick .45s cubic-bezier(.2,1.6,.4,1); }
.op-u small { margin-top: 6px; font: 400 12px var(--title); letter-spacing: .14em; color: var(--c2); }
.op-sep { font: 400 34px/1.4 var(--title); color: var(--c2); animation: opBlink 1s steps(2) infinite; }
.op-when { margin-top: 8px; font-weight: 800; font-size: 13px; color: #fff; opacity: .9; text-transform: capitalize; }
.op-msg { margin: 10px auto 0; max-width: 36ch; font-weight: 700; font-size: 14px; line-height: 1.45; color: #fff; opacity: .95; }
.op-cta { margin-top: 14px; width: 100%; }
.opening.shake { animation: opShake .5s; }
.opening.op-done { animation: opBoom 1.2s ease-out forwards; }
body.pre-opening .btn-play { filter: saturate(.55) brightness(.85); animation: none; }
@keyframes opIn { from { transform: scale(.85) translateY(20px); opacity: 0; } }
@keyframes opSpin { to { transform: rotate(1turn); } }
@keyframes opSpark { 0% { transform: translateY(0) scale(1); opacity: 0; } 10% { opacity: 1; } 100% { transform: translateY(-260px) scale(.3); opacity: 0; } }
@keyframes opBlink { 50% { opacity: .55; } }
@keyframes opTick { 0% { transform: translateY(-6px) scale(1.12); filter: brightness(1.4); } 100% { transform: none; } }
@keyframes opShake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }
@keyframes opBoom { 40% { transform: scale(1.08); box-shadow: 0 0 120px var(--c2); } 100% { transform: scale(.2); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .op-glow, .op-sparks i, .op-kicker, .op-sep, .opening { animation: none !important; } }
@media (max-width: 360px) { .op-u b { font-size: 30px; border-radius: 10px; } .op-sep { font-size: 26px; } }
body.pre-opening .home-logo { width: min(68vw, 380px); }
body.pre-opening .home-wrap { gap: 12px; }
@media (max-height: 700px) { body.pre-opening .home-logo { width: min(52vw, 300px); } .op-msg { font-size: 13px; } }
