:root {
  --gold: #ffd23f;
  --xp: #5ee6ff;
  --red: #ff4d4d;
  --ink: #0d1420;
  --panel: rgba(10, 16, 28, 0.72);
  --font-display: 'Lilita One', 'Arial Black', system-ui, sans-serif;
  --font-ui: 'Nunito', system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; overflow: hidden; background: #87c3ff; }
body { font-family: var(--font-ui); color: #fff; user-select: none; -webkit-user-select: none; }
canvas#game { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
.hidden { display: none !important; }

.outline { text-shadow: 0 2px 0 #000, 0 0 6px rgba(0, 0, 0, .6); }

/* ---------- topo ---------- */
#top { position: fixed; top: 10px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none; }
#topbar { display: flex; align-items: center; gap: 4px; font-family: var(--font-display); font-size: 22px; }
#topbar span { background: var(--panel); padding: 4px 14px; border-radius: 6px; text-shadow: 0 2px 0 #000; }
#timer { min-width: 92px; text-align: center; font-size: 26px; }
#money { color: var(--gold); }
#streak { color: #ffb347; }

#xprow { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 900; text-shadow: 0 1px 0 #000; }
#xpbar { position: relative; width: 220px; height: 12px; background: rgba(0, 0, 0, .55); border-radius: 6px; overflow: hidden; border: 1px solid rgba(255,255,255,.25); }
#xpfill { height: 100%; width: 0; background: linear-gradient(90deg, #2bb8ff, var(--xp)); transition: width .4s; }
#xptext { position: absolute; inset: 0; text-align: center; font-size: 10px; line-height: 11px; }

#avatars { display: flex; gap: 6px; margin-top: 12px; }
.av { position: relative; width: 46px; height: 46px; border-radius: 6px; border: 2px solid rgba(255,255,255,.85); display: grid; place-items: center; font-family: var(--font-display); font-size: 22px; text-shadow: 0 2px 0 rgba(0,0,0,.6); box-shadow: 0 2px 6px rgba(0,0,0,.4); }
.av.dead { filter: grayscale(1) brightness(.5); }
.av.me { border-color: var(--gold); }
.av .nm { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); font-family: var(--font-ui); font-size: 9px; font-weight: 900; white-space: nowrap; max-width: 48px; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 0 #000; }
.av .k { position: absolute; bottom: -4px; right: -4px; background: #111; border: 1px solid #fff; border-radius: 4px; font-family: var(--font-ui); font-size: 10px; font-weight: 900; padding: 0 3px; }

/* ---------- killfeed geral ---------- */
#feed { position: fixed; top: 12px; right: 14px; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; pointer-events: none; }
.feed-item { background: var(--panel); padding: 4px 10px; border-radius: 4px; font-size: 13px; font-weight: 900; animation: fadein .2s; }
.feed-item.mine { border: 1px solid var(--gold); }
.feed-item .hs { color: var(--gold); margin: 0 4px; }
.feed-item.info { opacity: .75; font-weight: 700; font-size: 12px; }

/* ---------- centro ---------- */
#crosshair { position: fixed; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px 0 0 -3px; background: #fff; border-radius: 50%; box-shadow: 0 0 0 1.5px rgba(0,0,0,.7); pointer-events: none; }
#hitmarker { position: fixed; left: 50%; top: 50%; width: 28px; height: 28px; margin: -14px 0 0 -14px; opacity: 0; pointer-events: none; }
#hitmarker::before, #hitmarker::after { content: ''; position: absolute; left: 50%; top: 0; width: 3px; height: 100%; margin-left: -1.5px; background: #fff; box-shadow: 0 0 2px #000; }
#hitmarker::before { transform: rotate(45deg); }
#hitmarker::after { transform: rotate(-45deg); }
#hitmarker.head::before, #hitmarker.head::after { background: var(--red); }
#hitmarker.show { animation: hit .35s ease-out; }

#popup { position: fixed; left: 50%; top: 26%; transform: translateX(-50%); text-align: center; pointer-events: none; font-family: var(--font-display); }
#popup .line { font-size: 22px; letter-spacing: 1px; text-shadow: 0 2px 0 #000, 0 0 8px rgba(0,0,0,.6); animation: pop .35s ease-out; }
#popup .line.big { font-size: 30px; }
#popup .money { color: var(--gold); }
#popup .xp { color: var(--xp); }
#popup .lvl { color: #9dff6a; font-size: 26px; }
#popup.fade { transition: opacity .5s; opacity: 0; }

#mykills { position: fixed; left: 50%; top: 72%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 2px; pointer-events: none; }
#mykills div { font-family: var(--font-display); color: var(--gold); font-size: 18px; text-shadow: 0 2px 0 #000; animation: fadein .2s; }

/* ---------- cantos ---------- */
#bottom-left { position: fixed; left: 18px; bottom: 18px; display: flex; align-items: center; gap: 10px; }
#hpbar { width: 200px; height: 16px; background: rgba(0,0,0,.6); border: 2px solid rgba(255,255,255,.8); border-radius: 4px; overflow: hidden; }
#hpfill { width: 100%; height: 100%; background: linear-gradient(90deg, #3ee86a, #b6ff5c); transition: width .15s; }
#hpfill.low { background: linear-gradient(90deg, #ff3d3d, #ff8a3d); }
#hptext { font-family: var(--font-display); font-size: 24px; text-shadow: 0 2px 0 #000; }
#shield { font-size: 11px; font-weight: 900; background: #2b8cff; padding: 2px 6px; border-radius: 4px; }

#bottom-right { position: fixed; right: 18px; bottom: 18px; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
#bolt { width: 120px; height: 6px; background: rgba(0,0,0,.5); border-radius: 3px; overflow: hidden; }
#boltfill { height: 100%; width: 100%; background: #fff; }
/* ping: canto superior esquerdo (no celular fica ao lado do botão do placar) */
#ping { position: fixed; top: 12px; left: calc(14px + env(safe-area-inset-left)); padding: 3px 8px; border-radius: 6px; background: rgba(0,0,0,.45);
  font: 900 12px var(--font-ui); color: #9dff6a; text-shadow: 0 1px 0 #000; pointer-events: none; }
#ping.mid { color: var(--gold); }
#ping.bad { color: var(--red); }
body.touch #ping { left: calc(66px + env(safe-area-inset-left)); top: 20px; }

/* ---------- efeitos ---------- */
#damage { position: fixed; inset: 0; pointer-events: none; opacity: 0; background: radial-gradient(ellipse at center, transparent 45%, rgba(255, 0, 0, .55) 100%); transition: opacity .5s; }

#scope { position: fixed; inset: 0; pointer-events: none;
  background: radial-gradient(circle at center, transparent 0, transparent 41vmin, rgba(0,0,0,.92) 41.4vmin, #000 60vmin); }
#scope::before { content: ''; position: absolute; left: 50%; top: 50%; width: 82.8vmin; height: 82.8vmin; transform: translate(-50%, -50%); border-radius: 50%; box-shadow: inset 0 0 6vmin rgba(0,0,0,.65); }
#scope .h, #scope .v { position: absolute; background: rgba(0,0,0,.85); }
#scope .h { left: calc(50% - 41vmin); width: 82vmin; top: 50%; height: 1px; }
#scope .v { top: calc(50% - 41vmin); height: 82vmin; left: 50%; width: 1px; }

/* ---------- overlays ---------- */
#death { position: fixed; left: 50%; top: 40%; transform: translate(-50%, -50%); text-align: center; pointer-events: none; }
#death .title { font-family: var(--font-display); font-size: 48px; color: var(--red); text-shadow: 0 3px 0 #000; }
#death-by { font-size: 18px; font-weight: 900; text-shadow: 0 2px 0 #000; }
#death-timer { margin-top: 6px; font-size: 14px; font-weight: 700; opacity: .85; text-shadow: 0 1px 0 #000; }

#scoreboard, #matchend { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); min-width: min(560px, 92vw); background: rgba(8, 12, 22, .9); border: 2px solid rgba(255,255,255,.15); border-radius: 10px; padding: 18px 22px; }
#scoreboard h2, #matchend .title { font-family: var(--font-display); font-size: 28px; text-align: center; margin-bottom: 10px; letter-spacing: 1px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 11px; opacity: .6; padding: 4px 6px; text-transform: uppercase; }
td { padding: 6px; border-top: 1px solid rgba(255,255,255,.08); font-weight: 700; }
tr.me td { color: var(--gold); }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: middle; }
#winner { text-align: center; font-size: 18px; font-weight: 900; color: var(--gold); margin-bottom: 10px; }
#next-match { text-align: center; margin-top: 12px; font-size: 13px; opacity: .8; }

/* ---------- menu ---------- */
#menu { position: fixed; inset: 0; display: flex; flex-direction: column; overflow-y: auto; touch-action: pan-y; background: linear-gradient(180deg, rgba(20, 60, 120, .55), rgba(5, 10, 25, .85)); padding: 16px; }
#menu .card { margin: auto; flex: none; width: min(420px, 100%); text-align: center; background: rgba(8, 12, 22, .82); border: 2px solid rgba(255,255,255,.12); border-radius: 14px; padding: 28px 24px 22px; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
#menu h1 { font-family: var(--font-display); font-size: 64px; letter-spacing: 3px; color: var(--gold); text-shadow: 0 4px 0 #a35b00, 0 8px 24px rgba(0,0,0,.6); line-height: 1; }
#menu .tag { margin: 8px 0 20px; opacity: .8; font-weight: 700; }
#nick { width: 100%; padding: 12px 14px; font: 900 18px var(--font-ui); border-radius: 8px; border: 2px solid rgba(255,255,255,.2); background: rgba(255,255,255,.08); color: #fff; outline: none; text-align: center; }
#nick:focus { border-color: var(--gold); }
#play { width: 100%; margin-top: 10px; padding: 12px; font: 26px var(--font-display); letter-spacing: 2px; border: 0; border-radius: 8px; background: var(--gold); color: #3a2100; cursor: pointer; box-shadow: 0 4px 0 #b37b00; }
#play:active { transform: translateY(2px); box-shadow: 0 2px 0 #b37b00; }
#play:disabled { opacity: .6; cursor: wait; }
#menu-error { min-height: 20px; margin-top: 8px; color: var(--red); font-weight: 900; font-size: 14px; }
.controls { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; margin-top: 10px; font-size: 12px; opacity: .75; text-align: left; }
.controls b { color: var(--gold); }

#paused { position: fixed; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.45); font-family: var(--font-display); font-size: 28px; cursor: pointer; }

@keyframes pop { 0% { transform: scale(1.6); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes fadein { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@keyframes hit { 0% { opacity: 1; transform: scale(1.3); } 100% { opacity: 0; transform: scale(1); } }

@media (max-width: 700px) {
  #topbar { font-size: 16px; } #timer { font-size: 18px; min-width: 70px; }
  .av { width: 34px; height: 34px; font-size: 16px; }
  #xpbar { width: 140px; }
  #hpbar { width: 120px; }
}

/* =========================================================
   CELULAR / TOQUE
   ========================================================= */
html, body { touch-action: none; overscroll-behavior: none; -webkit-tap-highlight-color: transparent; }
#menu, #menu * { touch-action: manipulation; }

.touch-only { display: none !important; }
body.touch .touch-only { display: grid !important; }
body.touch .desktop-only { display: none !important; }

#touch { position: fixed; inset: 0; z-index: 5; }
#joy-zone { position: absolute; left: 0; top: 30%; width: 45%; bottom: 0; }
#look-zone { position: absolute; right: 0; top: 0; width: 55%; height: 100%; }

#joy-base { position: absolute; width: 120px; height: 120px; margin: -60px 0 0 -60px; border-radius: 50%;
  background: rgba(255,255,255,.12); border: 2px solid rgba(255,255,255,.35); pointer-events: none; }
#joy-knob { position: absolute; left: 50%; top: 50%; width: 54px; height: 54px; border-radius: 50%;
  background: rgba(255,255,255,.55); box-shadow: 0 2px 8px rgba(0,0,0,.4); transform: translate(-50%, -50%); }

#touch button { position: absolute; border: 2px solid rgba(255,255,255,.55); border-radius: 50%;
  background: rgba(10,16,28,.45); color: #fff; font: 26px var(--font-display); display: grid; place-items: center;
  padding: 0; touch-action: none; user-select: none; -webkit-user-select: none; }
#touch button.down, #touch button:active { background: rgba(255,255,255,.3); }

#btn-fire { right: calc(26px + env(safe-area-inset-right)); bottom: 34px; width: 92px; height: 92px; font-size: 34px;
  background: conic-gradient(rgba(255,210,63,.75) var(--p, 360deg), rgba(10,16,28,.45) 0) !important; }
#btn-fire span { width: 76px; height: 76px; border-radius: 50%; background: rgba(10,16,28,.7); display: grid; place-items: center; }
#btn-fire.ready { border-color: var(--gold); }
#btn-fire.down span { background: rgba(255,210,63,.45); }

#btn-scope { right: calc(132px + env(safe-area-inset-right)); bottom: 70px; width: 64px; height: 64px; font-size: 30px; }
#btn-scope.active { background: rgba(255,210,63,.65) !important; border-color: var(--gold); color: #3a2100; }
#btn-jump { right: calc(60px + env(safe-area-inset-right)); bottom: 144px; width: 58px; height: 58px; }
#btn-board { left: calc(14px + env(safe-area-inset-left)); top: 12px; width: 44px; height: 44px; font-size: 20px; border-radius: 10px !important; }

/* HUD reposicionado para não ficar embaixo dos dedos */
body.touch #bottom-left { top: 64px; bottom: auto; left: calc(14px + env(safe-area-inset-left)); }
body.touch #hpbar { width: 120px; height: 12px; }
body.touch #hptext { font-size: 18px; }
body.touch #bottom-right { bottom: auto; top: 50%; right: auto; left: 50%; transform: translate(-50%, 28px); align-items: center; }
body.touch #bolt { width: 60px; height: 4px; }
body.touch #feed { right: calc(14px + env(safe-area-inset-right)); }
body.touch #scoreboard, body.touch #matchend { z-index: 6; max-height: 90vh; overflow: auto; }

/* Celular deitado: tela baixa, HUD compacto */
@media (max-height: 500px) {
  #top { top: 4px; gap: 3px; }
  #topbar { font-size: 15px; }
  #topbar span { padding: 2px 9px; }
  #timer { font-size: 18px; min-width: 64px; }
  #xprow { font-size: 10px; }
  #xpbar { width: 130px; height: 9px; }
  #xptext { font-size: 8px; line-height: 8px; }
  #avatars { margin-top: 10px; gap: 4px; }
  .av { width: 30px; height: 30px; font-size: 15px; border-width: 1.5px; }
  .av .nm { display: none; }
  .feed-item { font-size: 11px; padding: 2px 7px; }
  #popup { top: 22%; }
  #popup .line { font-size: 16px; } #popup .line.big { font-size: 21px; }
  #death .title { font-size: 34px; }
  #menu .card { padding: 14px 18px; }
  #menu h1 { font-size: 40px; }
  #menu .tag { margin: 4px 0 10px; font-size: 13px; }
  #nick { padding: 8px; font-size: 16px; }
  #play { padding: 8px; font-size: 22px; }
  .controls { font-size: 11px; gap: 3px 10px; }
  table { font-size: 12px; } td { padding: 3px 6px; }
}

/* Pede para girar quando o celular está em pé */
#rotate { display: none; }
@media (orientation: portrait) {
  body.touch #rotate { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; text-align: center;
    background: #0d1420; font: 24px/1.5 var(--font-display); color: var(--gold); padding: 24px; }
}

/* =========================================================
   MODO TREINO / BOTS
   ========================================================= */
#mode { font-size: 13px !important; color: #9dff6a; align-self: center; }
#train { margin-top: 14px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.12); }
.train-title { font: 16px var(--font-display); letter-spacing: 1px; color: #9dff6a; margin-bottom: 8px; }
.seg { display: flex; gap: 4px; margin-bottom: 6px; }
.seg button { flex: 1; padding: 7px 4px; border-radius: 6px; border: 2px solid rgba(255,255,255,.15); background: rgba(255,255,255,.06);
  color: #fff; font: 900 13px var(--font-ui); cursor: pointer; }
.seg button.on { border-color: #9dff6a; background: rgba(157,255,106,.18); }
#play-bots { width: 100%; margin-top: 4px; padding: 10px; font: 22px var(--font-display); letter-spacing: 2px; border: 0; border-radius: 8px;
  background: #6fd94a; color: #0f2a05; cursor: pointer; box-shadow: 0 4px 0 #3f8f25; }
#play-bots:active { transform: translateY(2px); box-shadow: 0 2px 0 #3f8f25; }
#play-bots:disabled { opacity: .6; cursor: wait; }
.train-note { margin-top: 6px; font-size: 11px; opacity: .6; }

.bot-tag { display: inline-block; margin-left: 6px; padding: 0 4px; border-radius: 3px; background: rgba(255,255,255,.18); font-size: 9px; font-weight: 900; vertical-align: middle; }
.av .bt { position: absolute; bottom: -4px; left: -4px; background: #333; border: 1px solid #fff; border-radius: 4px; font: 900 8px var(--font-ui); padding: 0 2px; }

.pause-card { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.leave-btn { padding: 8px 18px; border-radius: 8px; border: 2px solid rgba(255,255,255,.35); background: rgba(255,77,77,.25); color: #fff;
  font: 900 14px var(--font-ui); cursor: pointer; }
.leave-btn:hover { background: rgba(255,77,77,.45); }
.touch-leave { display: none; margin: 12px auto 0; }
body.touch .touch-leave { display: block; }

@media (max-height: 500px) {
  #train { margin-top: 8px; padding-top: 8px; }
  .train-title { font-size: 13px; margin-bottom: 4px; }
  .seg button { padding: 4px; font-size: 11px; }
  #play-bots { padding: 6px; font-size: 18px; }
  .train-note { display: none; }
  #menu .card { max-height: 100%; overflow-y: auto; }
}


/* =========================================================
   PWA
   ========================================================= */
.pwa-row { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.pwa-row button { margin-top: 6px; padding: 8px 14px; border-radius: 8px; border: 2px solid rgba(255,255,255,.25);
  background: rgba(94,230,255,.15); color: #fff; font: 900 13px var(--font-ui); cursor: pointer; }
#update-btn { background: rgba(255,210,63,.2); border-color: var(--gold); }
#ios-hint, #offline-note { margin-top: 8px; font-size: 12px; opacity: .85; }
#ios-hint b { color: var(--gold); }
#offline-note { color: #ffb347; font-weight: 900; }

/* =========================================================
   MAPAS
   ========================================================= */
#mapsel button { font-size: 12px; padding: 7px 2px; }
#map-banner { position: fixed; left: 50%; top: 38%; transform: translate(-50%, -50%); pointer-events: none; opacity: 0;
  font: 42px var(--font-display); letter-spacing: 4px; color: #fff; text-shadow: 0 3px 0 #000, 0 0 18px rgba(0,0,0,.6); white-space: nowrap; }
#map-banner.show { animation: mapbanner 2.6s ease-out forwards; }
@keyframes mapbanner { 0% { opacity: 0; transform: translate(-50%, -50%) scale(1.3); } 12% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 75% { opacity: 1; } 100% { opacity: 0; } }
@media (max-height: 500px) { #map-banner { font-size: 26px; } #mapsel button { font-size: 10px; padding: 4px 1px; } }

/* =========================================================
   CONTA / LOGIN
   ========================================================= */
#auth { margin-top: 6px; }
#auth-status { min-height: 16px; font-size: 12px; font-weight: 700; opacity: .9; }
#auth-status b { color: var(--gold); }
.auth-err { color: var(--red); font-weight: 900; }
#password { width: 100%; margin-top: 6px; padding: 10px 14px; font: 900 16px var(--font-ui); border-radius: 8px;
  border: 2px solid rgba(255,255,255,.2); background: rgba(255,255,255,.08); color: #fff; outline: none; text-align: center; }
#password:focus { border-color: var(--gold); }
#nick:disabled { opacity: .75; }
.auth-actions { display: flex; gap: 6px; justify-content: center; margin-top: 6px; }
.auth-actions button { padding: 6px 14px; border-radius: 6px; border: 2px solid rgba(255,255,255,.25); background: rgba(255,255,255,.08);
  color: #fff; font: 900 12px var(--font-ui); cursor: pointer; }
#btn-login { background: rgba(255,210,63,.25); border-color: var(--gold); }
@media (max-height: 500px) { #password { padding: 6px; font-size: 14px; } #auth-status { font-size: 10px; } }

/* =========================================================
   LOJA
   ========================================================= */
#shop-btn { width: 100%; margin-top: 10px; padding: 9px; font: 18px var(--font-display); letter-spacing: 1px; border-radius: 8px;
  border: 2px solid rgba(255,210,63,.6); background: rgba(255,210,63,.12); color: var(--gold); cursor: pointer; }
#shop-btn:hover { background: rgba(255,210,63,.22); }

#shop { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 12px; background: rgba(3, 6, 14, .82); }
.shop-panel { width: min(1000px, 100%); max-height: 100%; overflow: auto; background: linear-gradient(180deg, #121a2b, #0b1120);
  border: 2px solid rgba(255,255,255,.1); border-radius: 14px; padding: 16px 18px; box-shadow: 0 24px 70px rgba(0,0,0,.6); }
.shop-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.shop-title { font: 30px var(--font-display); color: var(--gold); letter-spacing: 2px; }
#shop-wallet { flex: 1; display: flex; gap: 10px; align-items: center; }
.w-money { font: 22px var(--font-display); color: var(--gold); background: rgba(255,210,63,.1); padding: 2px 12px; border-radius: 6px; }
.w-level { font-weight: 900; color: #9dff6a; }
.w-guest { font-weight: 700; opacity: .8; }
#shop-close { width: 38px; height: 38px; border-radius: 8px; border: 2px solid rgba(255,255,255,.2); background: rgba(255,255,255,.06);
  color: #fff; font-size: 18px; cursor: pointer; }
.shop-body { display: grid; grid-template-columns: 1.25fr 1fr; gap: 16px; }
.shop-detail { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
#shop-canvas { width: 100%; height: 210px; border-radius: 10px; background: radial-gradient(ellipse at center, #22304d 0%, #0d1424 75%); }
.shop-namerow { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
#shop-name { font: 28px var(--font-display); letter-spacing: 1px; }
#shop-rarity { font-weight: 900; font-size: 13px; text-transform: uppercase; }
#shop-desc { font-size: 14px; opacity: .85; }
#shop-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; }
.stat span { display: block; font-size: 11px; font-weight: 900; opacity: .75; margin-bottom: 2px; }
.stat .bar { position: relative; height: 8px; border-radius: 4px; background: rgba(255,255,255,.1); overflow: visible; }
.stat .fill { height: 100%; border-radius: 4px; background: #8ea3c2; transition: width .3s; }
.stat.up .fill { background: #6fd94a; }
.stat.down .fill { background: #ff6b6b; }
.stat .mark { position: absolute; top: -3px; width: 2px; height: 14px; background: #fff; opacity: .8; transform: translateX(-1px); }
#shop-action { margin-top: 4px; padding: 12px; border: 0; border-radius: 8px; font: 20px var(--font-display); letter-spacing: 1px; cursor: pointer;
  background: var(--gold); color: #3a2100; box-shadow: 0 4px 0 #b37b00; }
#shop-action.k-owned { background: #4fa3ff; color: #04203f; box-shadow: 0 4px 0 #2a6bb3; }
#shop-action:disabled { cursor: default; background: rgba(255,255,255,.1); color: rgba(255,255,255,.75); box-shadow: none; }
#shop-action.k-equipped:disabled { background: rgba(111,217,74,.2); color: #9dff6a; }
#shop-msg { min-height: 18px; font-weight: 900; font-size: 13px; }
#shop-list { display: flex; flex-direction: column; gap: 6px; max-height: 470px; overflow-y: auto; padding-right: 2px; }
.shop-card { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; text-align: left; cursor: pointer;
  border: 2px solid rgba(255,255,255,.08); background: rgba(255,255,255,.04); color: #fff; font-family: var(--font-ui); }
.shop-card:hover { background: rgba(255,255,255,.08); }
.shop-card.sel { border-color: var(--gold); background: rgba(255,210,63,.08); }
.shop-card .sw { width: 42px; height: 42px; flex: none; border-radius: 8px; border: 2px solid rgba(255,255,255,.25); }
.shop-card .info { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.shop-card .info b { font-size: 15px; }
.shop-card .info i { font-style: normal; font-size: 11px; font-weight: 900; text-transform: uppercase; }
.shop-card .tag { font-weight: 900; font-size: 13px; color: var(--gold); white-space: nowrap; }
.shop-card.k-equipped .tag { color: #9dff6a; }
.shop-card.k-owned .tag { color: #4fa3ff; }
.shop-card.k-locked { opacity: .65; }
.shop-card.k-locked .tag, .shop-card.k-poor .tag { color: rgba(255,255,255,.6); }
.shop-note { margin-top: 12px; font-size: 11px; opacity: .55; text-align: center; }

/* pagamento no fim da partida */
#payout { margin-top: 12px; padding: 10px 12px; border-radius: 8px; background: rgba(255,210,63,.07); border: 1px solid rgba(255,210,63,.3); }
.pay-title { font: 16px var(--font-display); color: var(--gold); letter-spacing: 1px; margin-bottom: 4px; }
.pay-line, .pay-total { display: flex; justify-content: space-between; font-size: 13px; padding: 2px 0; }
.pay-line b { color: #9dff6a; }
.pay-line.neg b { color: #ff9f43; }
.pay-total { border-top: 1px solid rgba(255,255,255,.15); margin-top: 4px; padding-top: 5px; font-size: 16px; font-weight: 900; }
.pay-total b { color: var(--gold); }
.pay-wallet { margin-top: 4px; font-size: 12px; opacity: .8; }
.pay-empty { font-size: 13px; opacity: .8; }

@media (max-width: 760px), (max-height: 500px) {
  .shop-body { grid-template-columns: 1fr 1fr; gap: 10px; }
  #shop-canvas { height: 84px; }
  #shop-name { font-size: 20px; }
  #shop-desc { display: none; }
  #shop-stats { grid-template-columns: 1fr 1fr; gap: 2px 8px; }
  .stat span { font-size: 9px; margin-bottom: 0; }
  .stat .bar { height: 5px; }
  #shop-action { padding: 7px; font-size: 15px; }
  #shop-list { max-height: 260px; }
  .shop-card { padding: 4px 8px; gap: 6px; }
  .shop-card .sw { width: 28px; height: 28px; }
  .shop-card .info b { font-size: 12px; }
  .shop-panel { padding: 10px 12px; }
  .shop-title { font-size: 20px; }
  .shop-note { display: none; }
  #matchend { max-height: 96vh; overflow-y: auto; }
  #payout { padding: 6px 8px; margin-top: 6px; }
  .pay-line { font-size: 11px; padding: 0; }
}
@media (max-width: 520px) { .shop-body { grid-template-columns: 1fr; } }

/* a loja precisa rolar com o dedo (o jogo bloqueia gestos no resto da tela) */
#shop, #shop * { touch-action: pan-y; }
@media (max-height: 500px) {
  .shop-head { margin-bottom: 6px; }
  .shop-detail { gap: 4px; }
  #shop-list { max-height: calc(100vh - 90px); }
}

/* Skyper Supremo: cartão com borda arco-íris animada */
.shop-card.supreme { position: relative; border: 2px solid transparent;
  background: linear-gradient(#141b2c, #141b2c) padding-box,
              linear-gradient(90deg, #ff004c, #ffb300, #39ff88, #00e5ff, #b26bff, #ff004c) border-box;
  background-size: 100% 100%, 300% 100%; animation: supreme-border 3s linear infinite; }
.shop-card.supreme.sel { box-shadow: 0 0 18px rgba(255, 79, 216, .55); }
.shop-card.supreme .info b { background: linear-gradient(90deg, #ffd700, #ff4fd8, #00e5ff, #ffd700); background-size: 300% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: supreme-text 3s linear infinite; }
.shop-card.supreme .info i { color: #ff4fd8 !important; }
@keyframes supreme-border { from { background-position: 0 0, 0 0; } to { background-position: 0 0, 300% 0; } }
@keyframes supreme-text { from { background-position: 0 0; } to { background-position: 300% 0; } }

/* aviso para todos */
#announce { position: fixed; left: 50%; top: 21%; transform: translateX(-50%); max-width: min(720px, 92vw); padding: 10px 20px; border-radius: 10px;
  background: rgba(255, 79, 216, .2); border: 2px solid rgba(255, 79, 216, .8); font: 22px var(--font-display); text-align: center;
  text-shadow: 0 2px 0 #000; pointer-events: none; opacity: 0; }
#announce.show { animation: announce 6s ease-out forwards; }
@keyframes announce { 0% { opacity: 0; transform: translate(-50%, -12px); } 8% { opacity: 1; transform: translate(-50%, 0); } 85% { opacity: 1; } 100% { opacity: 0; } }
@media (max-height: 500px) { #announce { font-size: 15px; padding: 6px 12px; } }

/* conta: trocar nick / senha */
#acct-edit { margin-top: 8px; padding: 10px; border-radius: 8px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.12);
  display: flex; flex-direction: column; gap: 6px; }
#acct-title { font-weight: 900; font-size: 13px; color: var(--gold); }
#acct-edit input { width: 100%; padding: 9px 12px; font: 900 15px var(--font-ui); border-radius: 8px; border: 2px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.08); color: #fff; outline: none; text-align: center; }
#acct-edit input:focus { border-color: var(--gold); }
#acct-save { background: rgba(255,210,63,.25) !important; border-color: var(--gold) !important; }
#acct-msg { min-height: 16px; font-size: 12px; font-weight: 900; }
#acct-msg.err { color: var(--red); } #acct-msg.ok { color: #9dff6a; }

/* ---------- ícones próprios (pixel art SVG, herdam a cor do texto) ---------- */
.ic { width: 1em; height: 1em; display: inline-block; vertical-align: -0.14em; fill: currentColor; flex: none; }
.ic { margin-right: .35em; }
#touch .ic, #mapsel .ic, #shop-close .ic, .controls b .ic, .ic.big, .feed-item .hs .ic, #streak .ic { margin-right: 0; }
.ic.fire { color: #ff8a2a; filter: drop-shadow(0 0 3px rgba(255,120,30,.6)); }
.ic.gold { color: var(--gold); }
.ic.red { color: #ff5a5a; }
.ic.ok { color: #6be06b; }
.ic.big { width: 64px; height: 64px; margin-bottom: 8px; color: var(--gold); }
#streak { display: inline-flex; align-items: center; gap: 4px; }
.feed-item .hs { display: inline-flex; gap: 3px; vertical-align: -0.14em; }
.feed-item .hs .ic { width: 1.45em; height: 1.45em; }
.feed-item .hs .ic:not(.gold):not(.red) { color: #e8eef7; }
#btn-fire .ic { width: 38px; height: 38px; }
#btn-scope .ic { width: 30px; height: 30px; }
#btn-jump .ic { width: 26px; height: 26px; }
#btn-board .ic { width: 20px; height: 20px; }
#mapsel .ic { width: 18px; height: 18px; vertical-align: -4px; }
#shop-close .ic { width: 16px; height: 16px; vertical-align: -2px; }
.controls b .ic { width: 14px; height: 14px; vertical-align: -2px; }

/* ---------- patentes ---------- */
.rank-ic { display: inline-block; flex: none; filter: drop-shadow(0 1px 1px rgba(0,0,0,.5)); }
.rank-ic.hud { width: 22px; height: 22px; vertical-align: middle; }
.rank-ic.row { width: 18px; height: 18px; vertical-align: -4px; margin-right: 5px; }
.rank-ic.tiny { width: 15px; height: 15px; vertical-align: -3px; }
.rank-ic.rcard { width: 58px; height: 58px; }
.rank-ic.list { width: 46px; height: 46px; }
.rank-ic.promo { width: 120px; height: 120px; filter: drop-shadow(0 6px 18px rgba(0,0,0,.6)) drop-shadow(0 0 22px rgba(255,210,63,.45)); }
#lvl-now { display: inline-flex; align-items: center; gap: 5px; }
#lvl-now .rk-name { color: var(--gold); }
#lvl-now .rk-lvl { opacity: .8; }

.menu-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.menu-btns #shop-btn { margin-top: 0; }
#ranks-btn { padding: 9px; font: 18px var(--font-display); letter-spacing: 1px; border-radius: 8px; color: #cfe3ff;
  background: rgba(79,163,255,.12); border: 2px solid rgba(79,163,255,.55); cursor: pointer; }
#ranks-btn:hover { background: rgba(79,163,255,.22); }

#rank-card { display: flex; align-items: center; gap: 12px; margin-top: 10px; padding: 10px 12px; text-align: left;
  background: linear-gradient(90deg, rgba(255,210,63,.10), rgba(255,255,255,.03)); border: 1px solid rgba(255,210,63,.25); border-radius: 10px; }
#rank-card.hidden { display: none; }
.rc-info { flex: 1; min-width: 0; }
.rc-name { font: 20px var(--font-display); color: var(--gold); letter-spacing: .5px; line-height: 1.1; }
.rc-lvl { font-size: 12px; opacity: .75; margin: 2px 0 6px; }
.rc-bar { height: 7px; border-radius: 4px; background: rgba(255,255,255,.1); overflow: hidden; }
.rc-bar div { height: 100%; background: linear-gradient(90deg, #ffb347, #ffd23f); border-radius: 4px; }
.rc-next { font-size: 11px; margin-top: 5px; opacity: .85; }
.rc-next span { color: #9dff6a; }
.rc-next.top { color: var(--gold); }

#ranks { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 12px; background: rgba(3, 6, 14, .82); }
#ranks.hidden { display: none; }
.ranks-panel { width: min(760px, 100%); max-height: 100%; overflow: auto; background: linear-gradient(180deg, #121a2b, #0b1120);
  border: 1px solid rgba(255,255,255,.1); border-radius: 14px; padding: 16px 18px; box-shadow: 0 24px 70px rgba(0,0,0,.6); touch-action: pan-y; }
.ranks-panel .shop-head { justify-content: space-between; }
#ranks-close { width: 38px; height: 38px; border-radius: 8px; border: 2px solid rgba(255,255,255,.2); background: rgba(255,255,255,.06); color: #fff; cursor: pointer; }
#ranks-close .ic { width: 16px; height: 16px; margin: 0; vertical-align: -2px; }
#ranks-sub { font-size: 13px; opacity: .75; margin-bottom: 12px; }
#ranks-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.rk-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.07); }
.rk-item .rk-txt { flex: 1; display: flex; flex-direction: column; }
.rk-item b { font-size: 14px; }
.rk-item span { font-size: 11px; opacity: .7; }
.rk-item.cur { border-color: var(--gold); background: rgba(255,210,63,.1); }
.rk-item.lock { opacity: .5; }
.rk-item.lock .rank-ic { filter: grayscale(.7) brightness(.8); }
.rk-item .ic.ok { color: #6be06b; margin: 0; }
.rk-you { font: normal 11px var(--font-display); color: #3a2100; background: var(--gold); padding: 2px 6px; border-radius: 4px; letter-spacing: .5px; }

#promo { position: fixed; left: 50%; top: 12%; transform: translateX(-50%); z-index: 6; text-align: center; pointer-events: none; opacity: 0; }
#promo.show { animation: promo 4.2s ease-out forwards; }
#promo .pr-title { font: 34px var(--font-display); color: var(--gold); letter-spacing: 2px; text-shadow: 0 3px 0 #a35b00, 0 0 18px rgba(0,0,0,.6); margin-top: 6px; }
#promo .pr-name { font: 22px var(--font-display); color: #fff; text-shadow: 0 2px 0 #000; }
#promo .pr-money { font: 22px var(--font-display); color: #9dff6a; text-shadow: 0 2px 0 #000; margin-top: 2px; }
@keyframes promo {
  0% { opacity: 0; transform: translateX(-50%) scale(.4); }
  8% { opacity: 1; transform: translateX(-50%) scale(1.12); }
  14% { transform: translateX(-50%) scale(1); }
  85% { opacity: 1; transform: translateX(-50%) scale(1); }
  100% { opacity: 0; transform: translateX(-50%) scale(.95); }
}
@media (max-height: 500px) {
  .rank-ic.promo { width: 72px; height: 72px; }
  #promo .pr-title { font-size: 24px; } #promo .pr-name, #promo .pr-money { font-size: 16px; }
  #lvl-now .rk-name { display: none; }
  .rank-ic.hud { width: 18px; height: 18px; }
  .rank-ic.rcard { width: 44px; height: 44px; }
  .rc-name { font-size: 16px; }
}

/* ---------- Telas de entrada: login/criar conta e escolha do nick ---------- */
.overlay { position: fixed; inset: 0; z-index: 30; display: flex; flex-direction: column; overflow-y: auto; touch-action: pan-y; padding: 16px;
  background: linear-gradient(180deg, rgba(20, 60, 120, .55), rgba(5, 10, 25, .9)); }
.overlay, .overlay * { touch-action: manipulation; }
.overlay .card { margin: auto; flex: none; width: min(380px, 100%); text-align: center; background: rgba(8, 12, 22, .88); border: 2px solid rgba(255,255,255,.12);
  border-radius: 14px; padding: 28px 24px 22px; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.overlay h1 { font-family: var(--font-display); font-size: 56px; letter-spacing: 3px; color: var(--gold); text-shadow: 0 4px 0 #a35b00, 0 8px 24px rgba(0,0,0,.6); line-height: 1; }
.overlay .tag { margin: 8px 0 16px; opacity: .85; font-weight: 700; }
.overlay form { display: flex; flex-direction: column; gap: 8px; }
.overlay input { width: 100%; padding: 12px 14px; font: 900 17px var(--font-ui); border-radius: 8px; border: 2px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.08); color: #fff; outline: none; text-align: center; }
.overlay input:focus { border-color: var(--gold); }
.tabs { display: flex; gap: 6px; margin-bottom: 12px; }
.tabs button { flex: 1; padding: 9px; border-radius: 8px; border: 2px solid rgba(255,255,255,.2); background: rgba(255,255,255,.06); color: #fff; font: 900 14px var(--font-ui); cursor: pointer; }
.tabs button.on { background: rgba(255,210,63,.25); border-color: var(--gold); color: var(--gold); }
.big-btn { margin-top: 4px; padding: 12px; font: 24px var(--font-display); letter-spacing: 2px; border: 0; border-radius: 8px; background: var(--gold); color: #3a2100; cursor: pointer; box-shadow: 0 4px 0 #b37b00; }
.big-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #b37b00; }
.big-btn:disabled { opacity: .6; cursor: wait; }
.form-error { min-height: 20px; margin-top: 8px; color: var(--red); font-weight: 900; font-size: 14px; }
.gate-note { margin-top: 6px; font-size: 12px; opacity: .65; }
.link-btn { margin-top: 10px; background: none; border: 0; color: #fff; opacity: .7; text-decoration: underline; font: 700 13px var(--font-ui); cursor: pointer; }
#nick[readonly] { cursor: default; opacity: .9; }
@media (max-height: 500px) { .overlay h1 { font-size: 36px; } .overlay .tag { margin: 4px 0 8px; font-size: 13px; } .overlay input { padding: 8px; font-size: 15px; } .overlay .card { padding: 14px 18px; } }

/* ---------- Lobby em telas separadas ---------- */
#menu section.hidden { display: none; }
.menu-btns.three { grid-template-columns: repeat(3, 1fr); }
.train-open { width: 100%; margin-top: 10px; padding: 10px; font: 20px var(--font-display); letter-spacing: 1px; border-radius: 8px; color: #b9ff9c;
  background: rgba(157,255,106,.14); border: 2px solid rgba(157,255,106,.55); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; }
.train-open:hover { background: rgba(157,255,106,.24); }
.account-open { padding: 9px; font: 18px var(--font-display); letter-spacing: 1px; border-radius: 8px; color: #fff; background: rgba(255,255,255,.08);
  border: 2px solid rgba(255,255,255,.3); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; }
.account-open:hover { background: rgba(255,255,255,.16); }
.back-btn { display: block; margin: 0 0 10px; padding: 6px 12px; border-radius: 6px; border: 2px solid rgba(255,255,255,.25); background: rgba(255,255,255,.08);
  color: #fff; font: 900 13px var(--font-ui); cursor: pointer; }
.view-title { font: 20px var(--font-display); letter-spacing: 1px; color: var(--gold); margin-bottom: 8px; }
#menu .link-btn { display: block; margin: 12px auto 0; }
#menu [data-view=train] #train { margin-top: 0; padding-top: 0; border-top: 0; }
#menu [data-view=controls] .controls { margin-top: 4px; font-size: 14px; opacity: .9; }
/* celular na horizontal (tela baixa): início em duas colunas, sem rolagem */
@media (max-height: 500px) {
  #menu .tag { display: none; }
  #menu .card { width: min(640px, 100%); }
  #menu h1 { margin-bottom: 8px; }
  #menu [data-view=home] { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: start; }
  #menu [data-view=home] #rank-card { margin-top: 8px; }
  #menu [data-view=home] .home-actions > :first-child { margin-top: 0; }
  #menu [data-view=train], #menu [data-view=account], #menu [data-view=controls] { max-width: 420px; margin: 0 auto; }
  .menu-btns.three { gap: 6px; }
  .train-open { padding: 6px; font-size: 16px; margin-top: 6px; }
  .account-open, #ranks-btn, #shop-btn { padding: 6px; font-size: 15px; }
  .back-btn { margin-bottom: 6px; }
  #menu .link-btn { margin-top: 6px; }
}

/* ---------- Loja: notas da arma (tiros para matar, especialidade, efeitos) ---------- */
.stat-note { font-size: 12px; font-weight: 700; opacity: .9; margin-top: 4px; text-align: left; }
.stat-note b { color: var(--gold); }
.stat-note.fx { color: #cfe3ff; }

/* ---------- Trocar de arma ao morrer ---------- */
#death-pick { margin: 14px auto 0; max-width: min(92vw, 640px); pointer-events: auto; }
#death-pick.hidden { display: none; }
.pick-title { font-size: 13px; font-weight: 900; text-shadow: 0 1px 0 #000; margin-bottom: 8px; }
.pick-keys { color: var(--gold); }
#pick-list { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; max-height: 36vh; overflow-y: auto; }
#pick-list button { position: relative; min-width: 104px; padding: 7px 10px 7px 12px; text-align: left; color: #fff; background: rgba(8, 12, 22, .78);
  border: 2px solid rgba(255,255,255,.2); border-radius: 8px; cursor: pointer; font: 900 13px var(--font-ui); pointer-events: auto; }
#pick-list button::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 4px; border-radius: 2px; background: var(--rc, #b8c0cc); }
#pick-list button small { display: block; font-weight: 700; font-size: 11px; opacity: .75; }
#pick-list button.sel { border-color: var(--gold); background: rgba(255, 210, 63, .2); }
#pick-list button.cur::after { content: "em campo"; position: absolute; right: 7px; bottom: 5px; font-size: 9px; font-weight: 900; opacity: .75; color: var(--gold); }
#pick-list button { padding-bottom: 9px; }
@media (max-height: 500px) { #death-pick { margin-top: 6px; } #pick-list { max-height: 30vh; } #pick-list button { min-width: 88px; padding: 4px 8px 4px 10px; font-size: 12px; } }

/* ---------- Ferramentas de admin: bolinha flutuante e painel ---------- */
#cheat-bubble { position: fixed; z-index: 40; width: 52px; height: 52px; border-radius: 50%; border: 3px solid rgba(255,255,255,.85); cursor: grab; touch-action: none;
  background: radial-gradient(circle at 30% 28%, #7a8bff, #3b2bd1 70%); color: #fff; font-size: 22px; display: grid; place-items: center;
  box-shadow: 0 6px 18px rgba(0,0,0,.5), 0 0 0 0 rgba(122,139,255,.6); opacity: .85; }
#cheat-bubble:active { cursor: grabbing; }
#cheat-bubble.active { background: radial-gradient(circle at 30% 28%, #ffe27a, #ff8a1f 70%); animation: cheatpulse 2s infinite; opacity: 1; }
#cheat-bubble[data-count]::after { content: attr(data-count); position: absolute; right: -4px; top: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px;
  background: #ff3d3d; color: #fff; font: 900 12px var(--font-ui); display: grid; place-items: center; }
#cheat-bubble:not([data-count])::after { display: none; }
@keyframes cheatpulse { 0% { box-shadow: 0 6px 18px rgba(0,0,0,.5), 0 0 0 0 rgba(255,170,60,.7); } 70% { box-shadow: 0 6px 18px rgba(0,0,0,.5), 0 0 0 14px rgba(255,170,60,0); } 100% { box-shadow: 0 6px 18px rgba(0,0,0,.5), 0 0 0 0 rgba(255,170,60,0); } }
#cheat-panel { position: fixed; z-index: 41; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(340px, 92vw); max-height: 88vh; overflow-y: auto; padding: 12px;
  border-radius: 14px; background: rgba(8, 12, 22, .94); border: 2px solid rgba(122,139,255,.55); box-shadow: 0 20px 60px rgba(0,0,0,.6); color: #fff; }
#cheat-panel.hidden { display: none; }
.cheat-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 8px; font-size: 18px; }
.cheat-head b { font-family: var(--font-display); letter-spacing: 1px; color: var(--gold); }
.cheat-head span { font-size: 11px; opacity: .65; font-weight: 700; }
#cheat-list { display: flex; flex-direction: column; gap: 6px; }
.cheat-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; text-align: left; color: #fff; cursor: pointer;
  background: rgba(255,255,255,.06); border: 2px solid rgba(255,255,255,.14); border-radius: 10px; font-family: var(--font-ui); }
.cheat-row .cheat-sw { flex: none; width: 38px; height: 22px; border-radius: 11px; background: rgba(255,255,255,.2); position: relative; transition: background .15s; }
.cheat-row .cheat-sw::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .15s; }
.cheat-row.on { border-color: #ffb84a; background: rgba(255,184,74,.14); }
.cheat-row.on .cheat-sw { background: #ffb84a; }
.cheat-row.on .cheat-sw::after { transform: translateX(16px); }
.cheat-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cheat-txt b { font-size: 14px; font-weight: 900; }
.cheat-txt small { font-size: 11px; opacity: .7; font-weight: 700; }
.cheat-row kbd { font: 900 11px var(--font-ui); padding: 2px 6px; border-radius: 5px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); }
.cheat-note { margin: 8px 0 0; font-size: 11px; opacity: .6; text-align: center; }
@media (max-height: 500px) { #cheat-panel { padding: 8px; } .cheat-row { padding: 5px 8px; } .cheat-txt small { display: none; } }
