/* Zovy Batalha Naval — mar no visual "figurinha" do Zovy. A base (botões, cartões, sala de espera, modal, avisos) é a mesma dos outros
   jogos ao vivo (copiada do Truco); o que é só da Batalha Naval (mar, navios, tiros) vem depois. Celular em pé, deitado e computador. */
:root { --ink: #1E1338; --violet: #7C4DFF; --lime: #C6F432; --pink: #FF4FA3; --cyan: #2EE6FF; --gold: #FFB800; --orange: #FF8A3D; --red: #FF3B5C; --soft: #cdbfff;
  --paper: #FFFBF0; --line: #BFD7FF; --margin: #FF8DA8;
  --disp: "Bricolage Grotesque", "Figtree", system-ui, sans-serif; --ui: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif; --hand: "Patrick Hand", "Comic Sans MS", cursive; }
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--ink); }
body { font: 600 16px/1.35 var(--ui); color: #fff; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
button { font: inherit; color: inherit; cursor: pointer; }
input { font: inherit; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
#app { position: fixed; inset: 0; overflow: hidden;
  background: radial-gradient(circle at 88% 0, rgb(46 230 255 / .18), transparent 42%), radial-gradient(circle at 0 100%, rgb(124 77 255 / .32), transparent 48%), linear-gradient(170deg, #12408a 0%, #0B1E4A 55%, #08122f 100%); }
#app::before { content: ""; position: absolute; inset: 0; opacity: .4; pointer-events: none; background: radial-gradient(rgb(255 255 255 / .2) 1.3px, transparent 1.5px) 0 0 / 22px 22px; }
.screen { position: absolute; inset: 0; display: none; flex-direction: column; padding: max(10px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(10px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left)); }
.screen.on { display: flex; animation: screenIn .32s cubic-bezier(.2, .9, .3, 1.2); }
@keyframes screenIn { from { opacity: 0; transform: translateY(14px) scale(.985); } }

/* letras flutuando no fundo */
.bg-suits { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.bg-suits span { position: absolute; bottom: -80px; font: 800 var(--s, 48px)/1 var(--disp); color: rgb(255 255 255 / .07); animation: floatUp var(--d, 18s) linear infinite; animation-delay: var(--w, 0s); }
@keyframes floatUp { to { transform: translateY(-120vh) rotate(var(--r, 40deg)); } }

/* ---------- botões e peças básicas ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 16px; color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 18px; box-shadow: 0 5px 0 var(--ink); font: 800 16px/1.1 var(--ui); transition: transform .12s, box-shadow .12s, filter .12s; }
.btn:hover { filter: brightness(1.05); }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.btn:focus-visible, .icon-btn:focus-visible, .mini-btn:focus-visible, .stop-btn:focus-visible, .chip:focus-visible, .vote-btn:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; }
.btn.lime { background: var(--lime); } .btn.pink { background: var(--pink); color: #fff; } .btn.violet { background: var(--violet); color: #fff; }
.btn.small { padding: 8px 12px; font-size: 14px; border-radius: 14px; box-shadow: 0 4px 0 var(--ink); }
.btn:disabled { opacity: .45; pointer-events: none; }
.btn.big { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 12px; align-items: center; text-align: left; padding: 12px 16px; }
.btn.big .ico { grid-row: 1 / 3; display: grid; place-items: center; width: 44px; height: 44px; background: rgb(255 255 255 / .6); border: 3px solid var(--ink); border-radius: 50%; font-size: 18px; }
.btn.big .t { font: 800 21px/1.1 var(--disp); }
.btn.big small { font: 700 13px/1.2 var(--ui); opacity: .8; }
.icon-btn { display: grid; place-items: center; width: 42px; height: 42px; flex: none; color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 14px; box-shadow: 0 4px 0 var(--ink); font: 800 18px/1 var(--ui); }
.icon-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ink); }
.mini-btn { padding: 4px 10px; color: var(--ink); background: #fff; border: 2px solid var(--ink); border-radius: 99px; font: 800 12px/1.3 var(--ui); }
.mini-btn[aria-pressed="true"] { background: var(--pink); color: #fff; }
.card { background: #fff; color: var(--ink); border: 3px solid var(--ink); border-radius: 22px; box-shadow: 0 6px 0 var(--ink); padding: 14px; }
.card h2, .card h3 { margin: 0; font: 800 20px/1.1 var(--disp); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.card-head small { color: #6b5f8f; font-size: 12px; }
.pill { display: inline-block; padding: 2px 10px; color: var(--ink); background: var(--lime); border: 2px solid var(--ink); border-radius: 99px; font: 800 12px/1.4 var(--ui); white-space: nowrap; vertical-align: middle; }
.pill.violet { background: var(--violet); color: #fff; } .pill.pink { background: var(--pink); color: #fff; } .pill.gold { background: var(--gold); }
input[type=text], input:not([type]) { width: 100%; min-width: 0; padding: 11px 14px; color: var(--ink); background: #F4F0FF; border: 3px solid var(--ink); border-radius: 14px; font: 700 16px/1.2 var(--ui); outline: none; }
input:focus { background: #fff; box-shadow: 0 0 0 3px var(--cyan); }
.dots { display: inline-flex; gap: 4px; vertical-align: middle; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: dot 1s infinite; } .dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }
@keyframes dot { 50% { transform: translateY(-5px); opacity: .5; } }
.wait { padding: 12px; text-align: center; color: #e6dcff; font-weight: 700; }

/* ---------- menu ---------- */
.top { display: flex; align-items: center; gap: 10px; flex: none; position: relative; z-index: 1; }
.logo { height: 32px; width: auto; }
.chip-orig { padding: 3px 12px; color: var(--ink); background: var(--lime); border: 2px solid var(--ink); border-radius: 99px; box-shadow: 0 3px 0 var(--ink); font: 800 12px/1.3 var(--ui); letter-spacing: .1em; }
.top .icon-btn { margin-left: auto; }
#menu { overflow-y: auto; }
.menu-body { position: relative; flex: 1; display: grid; grid-template-columns: minmax(0, 1fr); align-content: center; gap: 14px; width: 100%; max-width: 980px; margin: 0 auto; padding: 10px 0; }
.hero { text-align: center; }
.hero-sign { display: inline-flex; align-items: flex-end; gap: clamp(4px, 1.2vw, 10px); }
.hero-sign span, .hero-sign b { display: grid; place-items: center; width: clamp(54px, 15vw, 96px); height: clamp(62px, 17vw, 110px); color: var(--ink); background: var(--lime); border: 4px solid var(--ink); border-radius: 18px; box-shadow: 0 7px 0 var(--ink); font: 800 clamp(40px, 11vw, 74px)/1 var(--disp);
  animation: signIn .7s cubic-bezier(.2, 1.6, .4, 1) backwards, wobble 4s ease-in-out infinite; }
.hero-sign span:nth-child(1) { --rot: -6deg; background: var(--lime); animation-delay: 0s, .2s; }
.hero-sign span:nth-child(2) { --rot: 4deg; background: var(--cyan); animation-delay: .08s, .6s; }
.hero-sign span:nth-child(3) { --rot: -3deg; background: var(--gold); animation-delay: .16s, 1s; }
.hero-sign span:nth-child(4) { --rot: 6deg; background: #fff; animation-delay: .24s, 1.4s; }
.hero-sign b { --rot: -8deg; width: auto; padding: 0 10px; background: var(--red); color: #fff; animation-delay: .4s, 1.8s; }
@keyframes signIn { from { opacity: 0; transform: translateY(-60px) rotate(30deg) scale(.4); } }
@keyframes wobble { 0%, 100% { transform: rotate(var(--rot)); } 50% { transform: rotate(calc(var(--rot) * -1)) translateY(-4px); } }
.tag { max-width: 520px; margin: 16px auto 0; color: #e6dcff; font-size: clamp(15px, 3.8vw, 18px); }
.tag b { color: var(--lime); }
.me-card { display: flex; align-items: center; gap: 14px; }
.av-big { position: relative; flex: none; width: 76px; height: 76px; padding: 0; background: #F4F0FF; border: 3px solid var(--ink); border-radius: 50%; box-shadow: 0 4px 0 var(--ink); }
.av-big img { width: 100%; height: 100%; border-radius: 50%; }
.av-big .dice { position: absolute; right: -6px; bottom: -4px; display: grid; place-items: center; width: 30px; height: 30px; color: var(--ink); background: var(--gold); border: 2px solid var(--ink); border-radius: 50%; font-size: 16px; }
.av-big:active { transform: rotate(-12deg) scale(.95); }
.av-big.roll img { animation: roll .45s; } @keyframes roll { 40% { transform: scale(.6) rotate(-40deg); } }
.av-big[disabled] .dice { display: none; }
.me-fields { flex: 1; min-width: 0; display: grid; gap: 4px; }
.me-fields label, .join label { font: 800 13px/1 var(--ui); color: #6b5f8f; letter-spacing: .04em; text-transform: uppercase; }
.me-fields small { color: #6b5f8f; font-size: 12px; }
.me-fields .lvl { display: flex; align-items: center; gap: 8px; }
.menu-actions { display: grid; gap: 12px; }
.join-row { display: flex; gap: 8px; margin-top: 6px; }
#inpCode { text-transform: uppercase; letter-spacing: .35em; font: 800 22px/1 var(--disp); text-align: center; }
.menu-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.menu-row .btn { padding: 9px 6px; }
@media (min-width: 860px) {
  .menu-body { grid-template-columns: 1.1fr 1fr; align-items: center; column-gap: 34px; }
  .hero { grid-row: 1 / 3; }
}

/* ---------- barra de cima ---------- */
.bar { display: flex; align-items: center; gap: 10px; flex: none; margin-bottom: 10px; }
.bar-title { flex: 1; min-width: 0; display: grid; }
.bar-title small { color: var(--soft); font: 800 11px/1 var(--ui); letter-spacing: .12em; }
.bar-title b { font: 800 20px/1.1 var(--disp); }

/* ---------- sala de espera ---------- */
#lobby { overflow-y: auto; }
.lobby-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; width: 100%; max-width: 1100px; margin: 0 auto; }
.lobby-grid .col { display: grid; gap: 14px; align-content: start; min-width: 0; }
@media (min-width: 860px) { .lobby-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); } }
.code-card { text-align: center; background: var(--violet); color: #fff; }
.code-head { display: flex; align-items: center; justify-content: space-between; }
.code-head small { font: 800 12px/1 var(--ui); letter-spacing: .12em; opacity: .85; }
.code-tiles { display: flex; justify-content: center; gap: 10px; margin: 12px 0 14px; }
.code-tiles span { display: grid; place-items: center; width: clamp(54px, 16vw, 74px); height: clamp(62px, 18vw, 84px); color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 16px; box-shadow: 0 6px 0 var(--ink); font: 800 clamp(36px, 10vw, 52px)/1 var(--disp); animation: tileIn .5s cubic-bezier(.2, 1.6, .4, 1) backwards; }
.code-tiles span:nth-child(2) { animation-delay: .07s; } .code-tiles span:nth-child(3) { animation-delay: .14s; } .code-tiles span:nth-child(4) { animation-delay: .21s; }
@keyframes tileIn { from { transform: scale(.2) rotate(-30deg); opacity: 0; } }
.code-tiles.hide span { color: transparent; text-shadow: 0 0 14px rgb(30 19 56 / .7); }
.code-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.invite { margin: 10px 0 0; font-size: 13px; opacity: .85; word-break: break-all; }
.invite.hide { filter: blur(6px); user-select: none; }
.players { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.players li { position: relative; display: grid; justify-items: center; gap: 4px; padding: 10px 6px 8px; background: #F4F0FF; border: 2px solid var(--ink); border-radius: 16px; text-align: center; animation: pop .4s cubic-bezier(.2, 1.6, .4, 1); }
.players li.off { opacity: .45; }
.players li.me { background: #F2FCCF; }
.players img { width: 54px; height: 54px; background: #fff; border: 2px solid var(--ink); border-radius: 50%; }
.players b { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.players .crown { position: absolute; top: -14px; left: 50%; transform: translateX(-50%) rotate(-8deg); }
.players .kick { position: absolute; top: 4px; right: 4px; display: grid; place-items: center; width: 24px; height: 24px; padding: 0; color: var(--ink); background: #fff; border: 2px solid var(--ink); border-radius: 50%; font-size: 12px; }
.players .kick:hover { color: #fff; background: var(--red); }
.players .tagme { font-size: 11px; color: #6b5f8f; }
@keyframes pop { from { transform: scale(.5); opacity: 0; } }
.settings { display: grid; gap: 12px; }
.set-block { display: grid; gap: 6px; min-width: 0; }
.set-block > small { color: #6b5f8f; font: 800 12px/1 var(--ui); letter-spacing: .08em; }
.set-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; align-items: end; }
.packs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.packs button { display: grid; justify-items: center; gap: 2px; padding: 8px 4px; color: var(--ink); background: #F4F0FF; border: 2px solid var(--ink); border-radius: 14px; font: 800 12px/1.1 var(--ui); }
.packs .pk-ic { display: grid; place-items: center; width: 30px; height: 30px; color: var(--ink); background: #fff; border: 2px solid var(--ink); border-radius: 10px; font-size: 17px; }
.packs button.on .pk-ic { background: var(--lime); }
.packs button.on { background: var(--gold); box-shadow: 0 3px 0 var(--ink); transform: translateY(-2px); }
.cats { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; color: #6b5f8f; background: #fff; border: 2px dashed #b9add9; border-radius: 99px; font: 700 14px/1.2 var(--ui); }
.chip.on { color: var(--ink); background: var(--lime); border: 2px solid var(--ink); }
.chip.custom.on { background: var(--cyan); }
.chip .x { font-size: 12px; opacity: .7; }
.cat-add { display: flex; gap: 6px; margin-top: 4px; }
.cat-add input { padding: 8px 12px; }
.seg { display: flex; padding: 3px; background: #F4F0FF; border: 2px solid var(--ink); border-radius: 14px; }
.seg button { flex: 1; padding: 7px 4px; color: var(--ink); background: none; border: 0; border-radius: 10px; font: 800 14px/1 var(--ui); }
.seg button.on { background: var(--violet); color: #fff; }
.switch { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: center; cursor: pointer; }
.switch input { position: absolute; opacity: 0; }
.switch span { grid-row: 1 / 3; position: relative; width: 50px; height: 28px; background: #d9d1f2; border: 2px solid var(--ink); border-radius: 99px; transition: background .2s; }
.switch span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; background: #fff; border: 2px solid var(--ink); border-radius: 50%; transition: transform .2s; }
.switch input:checked + span { background: var(--pink); } .switch input:checked + span::after { transform: translateX(22px); }
.switch input:focus-visible + span { outline: 3px solid var(--cyan); outline-offset: 2px; }
.switch b { font-size: 14px; } .switch small { color: #6b5f8f; font-size: 12px; }
.rules-view { display: grid; gap: 8px; }
.rules-view .cats .chip { pointer-events: none; }
.rv-row { display: flex; flex-wrap: wrap; gap: 6px; }
.start { width: 100%; }
.start .ico { animation: pulse 1.2s infinite; } @keyframes pulse { 50% { transform: scale(1.12); } }
/* ---------- final ---------- */
#final { overflow-y: auto; }
.final-wrap { width: 100%; max-width: 980px; margin: 0 auto; display: grid; gap: 14px; }
.final-title { margin: 6px 0 0; text-align: center; font: 800 clamp(32px, 8vw, 48px)/1 var(--disp); text-shadow: 0 4px 0 rgb(0 0 0 / .3); }
.podium { display: flex; align-items: flex-end; justify-content: center; gap: clamp(8px, 2vw, 18px); min-height: 260px; padding-top: 10px; }
.pod { display: grid; justify-items: center; gap: 6px; width: clamp(96px, 26vw, 170px); }
.pod img { width: clamp(64px, 16vw, 96px); height: clamp(64px, 16vw, 96px); background: #fff; border: 3px solid var(--ink); border-radius: 50%; box-shadow: 0 5px 0 var(--ink); animation: popUp .6s cubic-bezier(.2, 1.6, .4, 1) backwards; }
.pod b { max-width: 100%; overflow: hidden; font: 800 16px/1.1 var(--ui); text-overflow: ellipsis; white-space: nowrap; }
.pod .step { display: grid; place-items: start center; width: 100%; padding-top: 10px; color: var(--ink); border: 3px solid var(--ink); border-bottom: 0; border-radius: 16px 16px 0 0; font: 800 34px/1 var(--disp); transform-origin: bottom; animation: rise .8s cubic-bezier(.2, 1.2, .4, 1) backwards; }
.pod .step small { display: block; font: 800 14px/1.4 var(--ui); }
.pod.p1 .step { height: 150px; background: var(--gold); animation-delay: .9s; } .pod.p1 img { animation-delay: 1.5s; width: clamp(76px, 19vw, 116px); height: clamp(76px, 19vw, 116px); }
.pod.p2 .step { height: 110px; background: #e3e8f5; animation-delay: .5s; } .pod.p2 img { animation-delay: 1.1s; }
.pod.p3 .step { height: 80px; background: #f3c49b; animation-delay: .1s; } .pod.p3 img { animation-delay: .7s; }
.pod.p1 .crown { animation: popUp .6s 1.8s cubic-bezier(.2, 1.6, .4, 1) backwards, wobble 3s 2.4s infinite; --rot: -6deg; }
@keyframes rise { from { transform: scaleY(0); } }
@keyframes popUp { from { transform: translateY(40px) scale(.3); opacity: 0; } }
.final-cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
@media (min-width: 760px) { .final-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.final-cols h3 { margin-bottom: 10px; }
.flist { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.flist li { display: grid; grid-template-columns: 30px 34px minmax(0, 1fr) auto; align-items: center; gap: 8px; padding: 6px 10px; background: #F4F0FF; border: 2px solid var(--ink); border-radius: 14px; font-weight: 800; }
.flist li.me { background: #F2FCCF; }
.flist img { width: 34px; height: 34px; background: #fff; border: 2px solid var(--ink); border-radius: 50%; }
.flist span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reward { display: grid; gap: 8px; min-height: 40px; }
.reward .xp-big { font: 800 40px/1 var(--disp); color: var(--violet); } .reward .xp-big small { font-size: 18px; }
.reward p { margin: 0; } .reward .soft { color: #6b5f8f; } .reward .gold { color: #b47a00; font-weight: 800; }
.reward .row-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.btn-mini { display: inline-block; padding: 6px 12px; color: var(--ink); background: var(--lime); border: 2px solid var(--ink); border-radius: 99px; font: 800 13px/1.2 var(--ui); text-decoration: none; }
.btn-mini.ghost { background: #fff; }
.final-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

/* ---------- efeitos ---------- */
.fx { position: absolute; inset: 0; z-index: 50; overflow: hidden; pointer-events: none; }
.float { position: absolute; bottom: 70px; display: grid; justify-items: center; animation: floatR 2.6s ease-out forwards; }
.float .fr { display: block; width: 58px; height: 58px; filter: drop-shadow(0 4px 0 rgb(0 0 0 / .3)); }
.float img { width: 26px; height: 26px; margin-top: -6px; background: #fff; border: 2px solid var(--ink); border-radius: 50%; }
@keyframes floatR { 0% { transform: translateY(20px) scale(.3); opacity: 0; } 12% { transform: translateY(0) scale(1.15); opacity: 1; } 100% { transform: translate(var(--dx, 0), -60vh) scale(.9); opacity: 0; } }
.confetti { position: absolute; inset: 0; z-index: 55; width: 100%; height: 100%; pointer-events: none; }
.toasts { position: absolute; top: max(10px, env(safe-area-inset-top)); left: 50%; z-index: 85; display: grid; gap: 6px; width: min(92vw, 420px); transform: translateX(-50%); pointer-events: none; }
.toast { display: flex; align-items: center; gap: 8px; padding: 9px 14px; color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 16px; box-shadow: 0 5px 0 var(--ink); font-weight: 800; animation: toastIn .35s cubic-bezier(.2, 1.6, .4, 1); }
.toast img { width: 26px; height: 26px; border: 2px solid var(--ink); border-radius: 50%; }
.toast .t-ic { display: grid; place-items: center; flex: none; width: 28px; height: 28px; color: var(--ink); background: var(--lime); border: 2px solid var(--ink); border-radius: 50%; }
.toast.ic-alert .t-ic, .toast.ic-lock .t-ic, .toast.ic-exit .t-ic { color: #fff; background: var(--red); }
.toast.ic-crown .t-ic, .toast.ic-party .t-ic { background: var(--gold); }
.toast.out { opacity: 0; transform: translateY(-10px); transition: .3s; }
@keyframes toastIn { from { transform: translateY(-20px) scale(.9); opacity: 0; } }
.modal { position: absolute; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; background: rgb(30 19 56 / .75); backdrop-filter: blur(3px); }
.modal-card { position: relative; width: min(100%, 520px); max-height: 88vh; overflow-y: auto; padding: 20px; color: var(--ink); background: #fff; border: 3px solid var(--ink); border-radius: 24px; box-shadow: 0 8px 0 var(--ink); animation: pop .35s cubic-bezier(.2, 1.6, .4, 1); }
.modal-x { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; box-shadow: 0 3px 0 var(--ink); }
.modal-card h2 { margin: 0 40px 12px 0; font: 800 26px/1.1 var(--disp); }
.modal-card ol { padding-left: 20px; } .modal-card li { margin-bottom: 8px; }
.qr { display: grid; place-items: center; padding: 14px; background: #fff; border: 3px solid var(--ink); border-radius: 18px; }
.qr svg { width: min(70vw, 280px); height: auto; }
.top-list { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.top-list li { display: flex; align-items: center; gap: 8px; color: var(--ink); padding: 6px 10px; background: #F4F0FF; border: 2px solid var(--ink); border-radius: 14px; font-weight: 800; }
.top-list img { width: 30px; height: 30px; background: #fff; border: 2px solid var(--ink); border-radius: 50%; }
.top-list b { margin-left: auto; }
.boot { position: absolute; inset: 0; z-index: 90; display: grid; place-content: center; justify-items: center; gap: 10px; background: var(--ink); color: var(--soft); font-weight: 700; transition: opacity .3s; }
.boot.gone { opacity: 0; pointer-events: none; }
.boot .err { max-width: 420px; padding: 0 16px; text-align: center; color: #fff; }

/* ---------- ícones SVG (v1.76) ---------- */
.icon-btn .zi { width: 22px; height: 22px; }
.btn .zi { width: 1.1em; height: 1.1em; }
.btn.big .ico .zi { width: 20px; height: 20px; }
.mini-btn { display: inline-flex; align-items: center; gap: 5px; }
.modal-card h2 .zi, .final-title .zi { color: var(--gold); }
.final-title .zi { width: .9em; height: .9em; vertical-align: -.08em; }
.reward p .zi { width: 18px; height: 18px; vertical-align: -.25em; }
.boot .err .zi { color: var(--red); }
.pill .zi, .seg .zi { width: 14px; height: 14px; vertical-align: -.18em; }

/* =====================================================================
   Só da Batalha Naval
   ===================================================================== */
:root { --sea1: #1f8fe0; --sea2: #1263b8; --sea3: #0b3f86; --grid: rgb(255 255 255 / .16); --navy: #0B1E4A;
  --bs: min(92vw, 52vh, 560px); --ms: min(44vw, 27vh); }
.btn.cyan { background: var(--cyan); }
.sea-bg { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.sea-bg i { position: absolute; left: -10%; right: -10%; height: 120px; bottom: var(--b, -40px); opacity: .5;
  background: radial-gradient(60px 26px at 30px 30px, rgb(46 230 255 / .18) 50%, transparent 52%) 0 0 / 120px 60px repeat-x; animation: wave 9s linear infinite; }
.sea-bg i:nth-child(2) { --b: 20px; opacity: .35; animation-duration: 13s; animation-direction: reverse; }
.sea-bg i:nth-child(3) { --b: 80px; opacity: .2; animation-duration: 17s; }
@keyframes wave { to { transform: translateX(120px); } }

/* ---------- menu ---------- */
.hero-sea { position: relative; height: clamp(130px, 30vw, 210px); width: min(100%, 440px); margin: 0 auto; }
.hero-sea svg.hs-ship { position: absolute; left: 50%; bottom: 26%; width: 78%; transform: translateX(-50%); filter: drop-shadow(0 6px 0 rgb(0 0 0 / .25)); animation: bob 3.2s ease-in-out infinite; }
.hero-sea .hs-water { position: absolute; left: 0; right: 0; bottom: 0; height: 40%; border: 4px solid var(--ink); border-radius: 26px; background: linear-gradient(var(--sea1), var(--sea2)); box-shadow: 0 7px 0 var(--ink); overflow: hidden; }
.hero-sea .hs-water::before { content: ""; position: absolute; inset: -4px -40px auto; height: 18px; background: radial-gradient(14px 10px at 14px 0, #fff 50%, transparent 52%) 0 0 / 28px 14px repeat-x; opacity: .85; animation: wave 3s linear infinite; }
.hero-sea svg.hs-ship { bottom: 22%; }
.hero-sea .hs-front { position: absolute; left: 4px; right: 4px; bottom: 26%; height: 16%; pointer-events: none;
  background: radial-gradient(18px 12px at 18px 100%, var(--sea1) 60%, transparent 63%) 0 100% / 36px 100% repeat-x; animation: waveBg 1.6s linear infinite; }
@keyframes waveBg { to { background-position: 36px 100%; } }
.hero-sea .hs-boom { position: absolute; width: 18%; aspect-ratio: 1; animation: heroBoom 3.2s infinite; }
.hero-sea .hs-boom.b2 { animation-delay: 1.6s; }
@keyframes heroBoom { 0%, 55% { transform: scale(0); opacity: 0; } 62% { transform: scale(1.15); opacity: 1; } 85% { transform: scale(1); opacity: 1; } 100% { transform: scale(.4); opacity: 0; } }
@keyframes bob { 0%, 100% { transform: translateX(-50%) translateY(0) rotate(-1.5deg); } 50% { transform: translateX(-50%) translateY(-6px) rotate(1.5deg); } }
.hero-title { display: grid; justify-items: center; margin: 4px 0 0; line-height: 1; }
.hero-title span { display: inline-block; padding: 2px 16px 4px; color: var(--ink); background: var(--cyan); border: 4px solid var(--ink); border-radius: 16px; box-shadow: 0 6px 0 var(--ink); font: 800 clamp(26px, 7vw, 44px)/1 var(--disp); transform: rotate(-3deg); }
.hero-title b { display: inline-block; margin-top: -4px; padding: 2px 22px 8px; color: #fff; background: var(--pink); border: 4px solid var(--ink); border-radius: 20px; box-shadow: 0 8px 0 var(--ink);
  font: 800 clamp(52px, 15vw, 92px)/1 var(--disp); letter-spacing: -.02em; --rot: 2deg; transform: rotate(2deg); animation: stampIn .6s .3s cubic-bezier(.2, 1.8, .4, 1) backwards, wobble 4s 1.2s ease-in-out infinite; }
@keyframes stampIn { from { transform: scale(2.4) rotate(12deg); opacity: 0; } }
@keyframes wobble { 0%, 100% { transform: rotate(var(--rot)); } 50% { transform: rotate(calc(var(--rot) * -1)) translateY(-4px); } }

/* ---------- sala de espera ---------- */
.duel { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 10px; }
.duel .vs { font: 800 26px/1 var(--disp); color: var(--pink); }
.duel .slot { display: grid; justify-items: center; gap: 4px; padding: 12px 6px; background: #EAF6FF; border: 3px solid var(--ink); border-radius: 18px; text-align: center; min-width: 0; }
.duel .slot img { width: 64px; height: 64px; background: #fff; border: 3px solid var(--ink); border-radius: 50%; }
.duel .slot b { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.duel .slot small { color: #50608f; font-size: 12px; }
.duel .slot.empty { background: rgb(255 255 255 / .7); border-style: dashed; color: #50608f; }
.duel .slot.empty .q { display: grid; place-items: center; width: 64px; height: 64px; border: 3px dashed var(--ink); border-radius: 50%; font: 800 30px/1 var(--disp); animation: pulse 1.4s infinite; }
.duel .slot.me { box-shadow: 0 0 0 3px var(--violet); }
.modes { display: grid; gap: 6px; }
.modes button { display: grid; grid-template-columns: 38px minmax(0, 1fr); align-items: center; gap: 2px 10px; padding: 8px 10px; color: var(--ink); background: #F4F0FF; border: 2px solid var(--ink); border-radius: 14px; text-align: left; font: 800 15px/1.1 var(--ui); }
.modes button .mi { grid-row: 1 / 3; display: grid; place-items: center; width: 38px; height: 38px; background: #fff; border: 2px solid var(--ink); border-radius: 12px; }
.modes button small { color: #50608f; font: 700 12px/1.2 var(--ui); }
.modes button.on { background: var(--lime); box-shadow: 0 3px 0 var(--ink); transform: translateY(-2px); }
.watchers { margin-top: 10px; color: #50608f; font: 700 13px/1.3 var(--ui); }
.watchers:empty { display: none; }
.setup { display: grid; gap: 14px; }
.setup .btn.big { width: 100%; }
.bots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.bots button { display: grid; justify-items: center; gap: 3px; padding: 8px 4px; color: var(--ink); background: #F4F0FF; border: 2px solid var(--ink); border-radius: 14px; font: 800 13px/1.1 var(--ui); }
.bots button img { width: 44px; height: 44px; background: #fff; border: 2px solid var(--ink); border-radius: 50%; }
.bots button small { color: #50608f; font: 700 11px/1.15 var(--ui); }
.bots button .stars { color: var(--gold); letter-spacing: 1px; font-size: 12px; -webkit-text-stroke: .6px var(--ink); }
.bots button.on { background: var(--gold); box-shadow: 0 3px 0 var(--ink); transform: translateY(-2px); }

/* ---------- o mar (tabuleiro) ---------- */
.board { --sz: var(--bs); position: relative; width: var(--sz); padding: calc(var(--sz) * .055) 0 0 calc(var(--sz) * .055); user-select: none; -webkit-user-select: none; transition: width .35s cubic-bezier(.2, .9, .3, 1); }
.board.small { --sz: var(--ms); }
.board .lab { position: absolute; display: grid; place-items: center; color: #bfe6ff; font: 800 calc(var(--sz) * .028)/1 var(--ui); pointer-events: none; }
.board .sea { position: relative; aspect-ratio: 1; border: 3px solid var(--ink); border-radius: calc(var(--sz) * .03); box-shadow: 0 5px 0 var(--ink); overflow: hidden;
  background: radial-gradient(circle at 30% 20%, rgb(255 255 255 / .18), transparent 40%), linear-gradient(160deg, var(--sea1), var(--sea2) 55%, var(--sea3)); }
.board .sea::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .3;
  background: radial-gradient(10px 4px at 50% 50%, rgb(255 255 255 / .35) 40%, transparent 45%) 0 0 / 20% 20%; animation: shimmer 6s linear infinite; }
@keyframes shimmer { to { background-position: 20% 10%; } }
.cells { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(10, 1fr); grid-template-rows: repeat(10, 1fr); }
.cell { position: relative; display: block; padding: 0; margin: 0; background: none; border: 0; border-right: 1px solid var(--grid); border-bottom: 1px solid var(--grid); cursor: default; }
.cell:nth-child(10n) { border-right: 0; } .cell:nth-child(n + 91) { border-bottom: 0; }
.ships, .marks, .fxl { position: absolute; inset: 0; pointer-events: none; }
.ship { position: absolute; display: block; padding: 0; transition: left .12s, top .12s; }
.ship svg { display: block; width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 2px 0 rgb(0 0 0 / .35)); }
.ship.sunk svg { filter: grayscale(.85) brightness(.55) drop-shadow(0 2px 0 rgb(0 0 0 / .35)); }
.ship.sunk { animation: sinkIn .9s cubic-bezier(.2, .9, .3, 1); }
@keyframes sinkIn { 0% { transform: scale(1.2); opacity: 0; } 40% { opacity: 1; transform: scale(1); } 60% { transform: rotate(-3deg); } 100% { transform: rotate(0); } }
.mk { position: absolute; display: block; width: 10%; height: 10%; }
.mk svg { width: 100%; height: 100%; display: block; overflow: visible; }
.mk.miss svg { animation: popIn .35s cubic-bezier(.2, 1.6, .4, 1); }
.mk.hit svg { animation: popIn .35s cubic-bezier(.2, 1.6, .4, 1), flicker 1.1s infinite alternate .35s; transform-origin: 50% 80%; }
.mk.sunkc::before { content: ""; position: absolute; inset: 0; background: rgb(11 30 74 / .45); }
.mk.free::before { content: ""; position: absolute; inset: 38%; border-radius: 50%; background: rgb(198 244 50 / .7); }
.mk.son { display: grid; place-items: center; border: 2px dashed var(--lime); border-radius: 18%; background: rgb(198 244 50 / .12); width: 30%; height: 30%; color: #fff; font: 800 calc(var(--sz) * .05)/1 var(--disp); text-shadow: 0 2px 0 var(--ink); animation: popIn .4s; }
@keyframes popIn { from { transform: scale(.2); opacity: 0; } }
@keyframes flicker { to { transform: scale(1.08) rotate(3deg); } }
/* mirar */
.board.armed .cell:not(.done) { cursor: crosshair; }
@media (hover: hover) { .board.armed .cell:not(.done):hover { background: rgb(198 244 50 / .25); box-shadow: inset 0 0 0 2px var(--lime); } }
.cell.pre { background: rgb(198 244 50 / .28); box-shadow: inset 0 0 0 2px var(--lime); }
.cell.aim::after { content: ""; position: absolute; inset: 8%; border: 3px solid var(--lime); border-radius: 50%; box-shadow: 0 0 0 2px var(--ink), inset 0 0 0 2px var(--ink); animation: aim 1s infinite; }
.cell.aim::before { content: ""; position: absolute; left: 50%; top: 12%; bottom: 12%; width: 2px; margin-left: -1px; background: var(--lime); box-shadow: 0 0 0 1px var(--ink); }
@keyframes aim { 50% { transform: scale(.82); } }
.cell.target { background: rgb(255 79 163 / .35); }
.cell.target::after { content: ""; position: absolute; inset: 18%; border: 3px solid var(--pink); border-radius: 50%; box-shadow: 0 0 0 2px var(--ink); animation: aim .9s infinite; }
/* radar quando é a vez de alguém */
.board.scan .sea::after { content: ""; position: absolute; inset: -40%; pointer-events: none; background: conic-gradient(from 0deg, rgb(198 244 50 / .28), transparent 18%, transparent); animation: radar 2.6s linear infinite; }
@keyframes radar { to { transform: rotate(360deg); } }
.board.shake { animation: shake .42s; }
@keyframes shake { 20% { transform: translate(-4px, 2px); } 40% { transform: translate(4px, -2px); } 60% { transform: translate(-3px, -1px); } 80% { transform: translate(2px, 1px); } }
/* efeitos do tiro */
.missile { position: absolute; width: 10%; height: 10%; display: grid; place-items: center; z-index: 3; animation: fall .42s cubic-bezier(.5, 0, 1, .7) forwards; }
.missile svg { width: 70%; height: 140%; filter: drop-shadow(0 3px 0 rgb(0 0 0 / .3)); }
@keyframes fall { from { transform: translateY(-260%) scale(1.8); opacity: 0; } 20% { opacity: 1; } to { transform: translateY(0) scale(.6); } }
.boom, .splash { position: absolute; width: 10%; height: 10%; z-index: 4; }
.boom::before, .boom::after { content: ""; position: absolute; inset: -60%; border-radius: 50%; background: radial-gradient(circle, #fff 0 18%, var(--gold) 30%, var(--orange) 48%, var(--red) 62%, transparent 66%); animation: boom .6s ease-out forwards; }
.boom::after { inset: -110%; background: none; border: 4px solid var(--gold); animation: ring .6s ease-out forwards; }
.boom.big::before { inset: -140%; }
@keyframes boom { from { transform: scale(.1); opacity: 1; } 60% { opacity: 1; } to { transform: scale(1); opacity: 0; } }
@keyframes ring { from { transform: scale(.2); opacity: 1; } to { transform: scale(1.2); opacity: 0; } }
.splash::before, .splash::after { content: ""; position: absolute; inset: -30%; border: 3px solid #fff; border-radius: 50%; animation: ring .7s ease-out forwards; }
.splash::after { animation-delay: .15s; inset: -70%; border-width: 2px; }
.splash i { position: absolute; left: 50%; top: 50%; width: 18%; height: 18%; border-radius: 50%; background: #dff6ff; animation: drop .6s ease-out forwards; }
@keyframes drop { from { transform: translate(-50%, -50%); opacity: 1; } to { transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))); opacity: 0; } }
.sonar-wave { position: absolute; width: 30%; height: 30%; z-index: 4; border-radius: 50%; border: 3px solid var(--lime); animation: ring 1.1s ease-out 2 forwards; }

/* ---------- posicionar ---------- */
#monta { overflow-y: auto; }
.monta-grid { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; align-content: start; gap: 14px; width: 100%; max-width: 1060px; margin: 0 auto; }
#monta .board { --sz: min(92vw, 56vh, 540px); }
.monta-side { display: grid; gap: 10px; width: min(100%, 520px); }
.m-help { margin: 0; color: #cfe8ff; font-size: 14px; text-align: center; }
.m-help b { color: var(--lime); }
.dock { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 12px; min-height: 52px; padding: 8px; background: rgb(255 255 255 / .1); border: 3px dashed rgb(255 255 255 / .35); border-radius: 18px; }
.dock:empty::before { content: "Todos os navios estão no mar!"; color: var(--lime); font-weight: 800; }
.dock .dk { --u: clamp(22px, 6.4vw, 34px); position: relative; height: var(--u); width: calc(var(--u) * var(--n)); padding: 0; background: none; border: 0; touch-action: none; cursor: grab; }
.dock .dk svg { width: 100%; height: 100%; display: block; overflow: visible; filter: drop-shadow(0 3px 0 rgb(0 0 0 / .35)); }
.dock .dk.sel { outline: 3px solid var(--lime); outline-offset: 4px; border-radius: 10px; }
.dock .dk small { position: absolute; left: 0; right: 0; top: 100%; margin-top: 2px; color: #cfe8ff; font: 700 10px/1 var(--ui); white-space: nowrap; }
#placeBoard .ship { pointer-events: auto; touch-action: none; cursor: grab; }
#placeBoard .ship.sel svg { filter: drop-shadow(0 0 0 var(--lime)) drop-shadow(0 0 4px var(--lime)) drop-shadow(0 2px 0 rgb(0 0 0 / .35)); }
#placeBoard .ship.lift { opacity: .3; }
#placeBoard .ship.no { animation: no .35s; }
@keyframes no { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.ghost { position: absolute; pointer-events: none; z-index: 2; border-radius: 8%; }
.ghost.ok { background: rgb(198 244 50 / .45); box-shadow: inset 0 0 0 3px var(--lime); }
.ghost.bad { background: rgb(255 59 92 / .45); box-shadow: inset 0 0 0 3px var(--red); }
.m-tools { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.m-timer { display: grid; place-items: center; min-width: 52px; height: 42px; padding: 0 10px; color: var(--ink); background: var(--gold); border: 3px solid var(--ink); border-radius: 14px; font: 800 18px/1 var(--disp); }
.m-timer.low { background: var(--red); color: #fff; animation: pulse .6s infinite; }
@media (min-width: 900px) {
  .monta-grid { grid-template-columns: auto minmax(300px, 400px); align-items: center; align-content: center; column-gap: 30px; }
  #monta .board { --sz: min(64vh, 560px); }
}

/* ---------- batalha ---------- */
#batalha { padding-bottom: max(6px, env(safe-area-inset-bottom)); }
.hud { flex: none; width: 100%; max-width: 1180px; margin-left: auto; margin-right: auto; display: grid; grid-template-columns: auto minmax(0, 1fr) auto minmax(0, 1fr) auto; align-items: center; gap: 8px; margin-bottom: 6px; position: relative; z-index: 2; }
.side { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 4px 10px 4px 4px; background: #fff; color: var(--ink); border: 3px solid var(--ink); border-radius: 99px; box-shadow: 0 4px 0 var(--ink); transition: transform .25s, background .25s; }
.side.them { flex-direction: row-reverse; padding: 4px 4px 4px 10px; text-align: right; }
.side img { flex: none; width: 36px; height: 36px; background: #EAF6FF; border: 2px solid var(--ink); border-radius: 50%; }
.side .who { min-width: 0; display: grid; }
.side .who b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.side .who small { color: #50608f; font: 700 11px/1.2 var(--ui); }
.side.on { background: var(--lime); transform: translateY(-2px); }
.side.off img { opacity: .4; }
.turn { display: grid; justify-items: center; min-width: 108px; padding: 5px 12px; color: var(--ink); background: var(--gold); border: 3px solid var(--ink); border-radius: 16px; box-shadow: 0 4px 0 var(--ink); text-align: center; font: 800 15px/1.05 var(--disp); }
.turn small { font: 700 11px/1.2 var(--ui); }
.turn.mine { background: var(--lime); animation: pulse 1.2s infinite; }
.turn.theirs { background: #fff; }
.turn .bar { display: block; width: 100%; height: 5px; margin-top: 3px; background: rgb(30 19 56 / .15); border-radius: 9px; overflow: hidden; }
.turn .bar i { display: block; height: 100%; width: var(--p, 100%); background: var(--ink); border-radius: 9px; }
.arena { flex: 1; min-height: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; justify-content: safe center; gap: 8px; }
.zone { display: grid; justify-items: center; gap: 4px; min-width: 0; }
.zone-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; padding-left: calc(var(--sz, var(--bs)) * .055); color: #cfe8ff; font: 800 12px/1 var(--ui); letter-spacing: .1em; }
.zone.enemy .zone-head { --sz: var(--bs); } .zone.mine .zone-head { --sz: var(--ms); }
.fleet-left { display: flex; gap: 3px; }
.fleet-left i { display: block; height: 8px; width: calc(var(--n) * 7px); background: var(--lime); border: 2px solid var(--ink); border-radius: 6px; }
.fleet-left i.down { background: var(--red); opacity: .55; }
.tools { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; min-height: 44px; }
.tools:empty { display: none; }
.btn.power em { display: grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; font-style: normal; color: #fff; background: var(--violet); border-radius: 99px; font-size: 12px; }
.btn.power.on { background: var(--lime); box-shadow: 0 0 0 3px var(--ink), 0 4px 0 var(--ink); }
.btn.power:disabled { opacity: .35; }
.btn.fire { display: grid; padding: 6px 22px; color: #fff; background: var(--red); font: 800 22px/1 var(--disp); }
.btn.fire small { font: 700 11px/1.2 var(--ui); opacity: .9; }
.btn.fire.go { animation: pulse .9s infinite; }
.zone.mine { position: relative; }
.talk { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.talk button { padding: 4px; width: 38px; height: 38px; background: #fff; border: 2px solid var(--ink); border-radius: 12px; box-shadow: 0 3px 0 var(--ink); }
.talk button svg { width: 100%; height: 100%; }
.react-fly { position: absolute; z-index: 6; width: 56px; height: 56px; pointer-events: none; animation: reactFly 1.8s ease-out forwards; }
.react-fly svg { width: 100%; height: 100%; }
@keyframes reactFly { 0% { transform: translateY(20px) scale(.3); opacity: 0; } 15% { transform: translateY(0) scale(1.2); opacity: 1; } 100% { transform: translateY(-120px) scale(.9); opacity: 0; } }
.banner { position: absolute; left: 50%; top: 50%; z-index: 30; display: grid; justify-items: center; padding: 12px 26px; color: var(--ink); background: #fff; border: 4px solid var(--ink); border-radius: 22px; box-shadow: 0 8px 0 var(--ink); text-align: center; transform: translate(-50%, -50%); pointer-events: none; animation: bannerIn .5s cubic-bezier(.2, 1.6, .4, 1); }
.banner b { font: 800 clamp(30px, 8vw, 50px)/1 var(--disp); }
.banner small { font: 700 14px/1.3 var(--ui); color: #50608f; }
.banner.mine { background: var(--lime); } .banner.theirs { background: var(--cyan); } .banner.sunk { background: var(--gold); } .banner.lost { background: var(--pink); color: #fff; } .banner.lost small { color: #fff; }
.banner.out { animation: bannerOut .3s forwards; }
@keyframes bannerIn { from { transform: translate(-50%, -50%) scale(.3) rotate(-8deg); opacity: 0; } }
@keyframes bannerOut { to { transform: translate(-50%, -50%) scale(.8); opacity: 0; } }
.shout { position: absolute; inset: 0; z-index: 40; display: grid; place-items: center; pointer-events: none; }
.shout span { font: 800 clamp(48px, 15vw, 120px)/1 var(--disp); color: var(--gold); -webkit-text-stroke: 4px var(--ink); paint-order: stroke fill; text-shadow: 0 8px 0 var(--ink); animation: shout 1.2s forwards; }
.shout span.red { color: var(--red); } .shout span.lime { color: var(--lime); } .shout span.white { color: #fff; }
@keyframes shout { 0% { transform: scale(2.6) rotate(-10deg); opacity: 0; } 18% { transform: scale(1) rotate(-4deg); opacity: 1; } 75% { transform: scale(1.05) rotate(-4deg); opacity: 1; } 100% { transform: scale(.9) rotate(-4deg); opacity: 0; } }
.flash { position: absolute; inset: 0; z-index: 35; pointer-events: none; background: radial-gradient(circle, rgb(255 184 0 / .5), rgb(255 59 92 / .25) 50%, transparent 70%); animation: flash .5s forwards; }
@keyframes flash { from { opacity: 1; } to { opacity: 0; } }

/* computador */
@media (min-width: 900px) {
  :root { --bs: min(66vh, 600px, 52vw); --ms: min(44vh, 400px, 32vw); }
  .arena { flex-direction: row; align-items: center; gap: clamp(20px, 4vw, 60px); }
  .side img { width: 44px; height: 44px; } .side .who b { font-size: 16px; }
  .turn { min-width: 160px; font-size: 18px; }
}
/* celular em pé: quando é a vez do outro, o seu mar cresce */
@media (max-width: 899px) and (min-height: 521px) {
  .arena.theirs { --bs: min(64vw, 36vh); --ms: min(80vw, 44vh); }
  .arena.theirs .zone.mine { order: -1; }
  .hud { grid-template-columns: auto minmax(0, 1fr) auto auto; grid-template-areas: "q me them s" "t t t t"; }
  .hud #btnQuit { grid-area: q; } .hud .me { grid-area: me; } .hud .them { grid-area: them; } .hud #btnSound4 { grid-area: s; } .hud .turn { grid-area: t; justify-self: center; }
  .side .who small { display: none; }
  .side img { width: 30px; height: 30px; }
}
/* telas baixas (celular deitado) */
@media (max-height: 520px) {
  :root { --bs: calc(100vh - 118px); --ms: calc((100vh - 118px) * .7); }
  .arena { flex-direction: row; align-items: flex-start; gap: 14px; }
  .hud { margin-bottom: 2px; } .hud .icon-btn { width: 36px; height: 36px; }
  .side { padding: 2px 8px 2px 2px; } .side img { width: 28px; height: 28px; } .side .who small { display: none; }
  .turn { padding: 3px 10px; font-size: 13px; }
  .zone.enemy { grid-template-columns: auto auto; align-items: center; column-gap: 10px; }
  .zone.enemy .zone-head { grid-column: 1 / 3; }
  .tools { flex-direction: column; flex-wrap: nowrap; }
  .menu-body { grid-template-columns: 1fr 1fr; align-items: center; column-gap: 16px; padding: 2px 0; }
  .hero { grid-row: 1 / 4; } .hero-sea { height: 110px; } .hero-title b { font-size: 46px; } .hero-title span { font-size: 22px; } .tag { margin-top: 8px; font-size: 14px; }
  .me-card { padding: 8px 12px; } .av-big { width: 54px; height: 54px; } .me-fields small { display: none; }
  .btn.big { padding: 6px 12px; } .btn.big .ico { width: 32px; height: 32px; } .btn.big .t { font-size: 17px; } .btn.big small { font-size: 11px; }
  .join.card { padding: 8px 12px; } .menu-actions { gap: 6px; }
  .monta-grid { grid-template-columns: auto minmax(0, 1fr); align-items: start; column-gap: 16px; }
  #monta .board { --sz: calc(100vh - 80px); }
  #monta .bar { margin-bottom: 4px; }
  .monta-side { gap: 6px; } .dock { min-height: 40px; padding: 6px; } .dock .dk { --u: 22px; }
  .m-help { font-size: 12px; }
}

/* ---------- fim ---------- */
.final-head { display: grid; justify-items: center; gap: 6px; text-align: center; padding-top: 6px; }
.final-head .big { font: 800 clamp(38px, 10vw, 66px)/1 var(--disp); text-shadow: 0 5px 0 rgb(0 0 0 / .3); }
.final-head .big.win { color: var(--lime); } .final-head .big.lose { color: #ffd0e6; }
.final-head .cup { width: clamp(84px, 20vw, 130px); color: var(--gold); filter: drop-shadow(0 6px 0 rgb(0 0 0 / .3)); animation: popUp .7s .2s cubic-bezier(.2, 1.6, .4, 1) backwards; }
.final-head .cup svg { width: 100%; height: auto; }
.final-head .cup.sunk { width: clamp(150px, 34vw, 230px); filter: grayscale(.8) brightness(.7) drop-shadow(0 6px 0 rgb(0 0 0 / .3)); transform: rotate(-14deg); animation: sinkHead 1.2s .2s cubic-bezier(.2, .9, .3, 1) backwards; }
@keyframes sinkHead { from { transform: translateY(-40px) rotate(0); opacity: 0; } }
.final-head .vsrow { display: flex; align-items: center; gap: 10px; }
.final-head .vsrow img { width: 48px; height: 48px; background: #fff; border: 3px solid var(--ink); border-radius: 50%; }
.final-head .vsrow img.lost { filter: grayscale(1); opacity: .6; }
.final-head .note { max-width: 520px; padding: 8px 14px; color: var(--ink); background: var(--gold); border: 3px solid var(--ink); border-radius: 14px; font-weight: 800; }
.final-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.final-stats div { display: grid; justify-items: center; padding: 8px 4px; background: #EAF6FF; border: 2px solid var(--ink); border-radius: 14px; text-align: center; }
.final-stats b { font: 800 26px/1 var(--disp); }
.final-stats small { color: #50608f; font: 700 11px/1.2 var(--ui); }
.reveal { display: grid; justify-items: center; gap: 6px; margin-top: 12px; }
.reveal small { color: #50608f; font-weight: 700; }
.reveal .board { --sz: min(70vw, 260px); }
.reveal .lab { color: #50608f; }
.daily-grid { font: 800 15px/1.4 var(--ui); letter-spacing: 2px; }
