:root { --fundo: #070b10; --cartao: #121a23; --texto: #e8eef5; --fraco: #8a99a8; --cor: #3fd9a8; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--fundo); color: var(--texto); font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-tap-highlight-color: transparent; overflow: hidden; user-select: none; -webkit-user-select: none; touch-action: none; }
button { font: inherit; color: inherit; border: 0; cursor: pointer; }
.oculto { display: none !important; }

#entrada { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 16px; text-align: center; gap: 10px; touch-action: auto; }
#entrada h1 { margin: 0; font-size: 28px; }
#entrada p { color: #c9d3de; margin: 4px 0 10px; max-width: 360px; line-height: 1.45; }
#cod { font-size: 48px; font-weight: 900; letter-spacing: 14px; text-align: center; width: 260px; padding: 12px; border-radius: 16px;
  border: 2px solid #23313f; background: var(--cartao); color: var(--cor); }
#cod:focus { outline: none; border-color: var(--cor); }
#entrar { background: var(--cor); color: #04110c; font-weight: 800; font-size: 20px; padding: 14px 40px; border-radius: 14px; margin-top: 8px; }
.erro { color: #ff7a8a !important; min-height: 22px; }
.link { color: var(--fraco); margin-top: 18px; }

#pad { height: 100%; display: flex; flex-direction: column; padding: env(safe-area-inset-top) 12px env(safe-area-inset-bottom); }
header { display: flex; align-items: center; gap: 10px; padding: 10px 2px; }
.bola { width: 14px; height: 14px; border-radius: 50%; background: #ff5d73; flex: none; box-shadow: 0 0 10px currentColor; }
.bola.on { background: var(--cor); }
.info { flex: 1; min-width: 0; }
.info b { display: block; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.info small { color: var(--fraco); font-size: 13px; }
.mini { background: var(--cartao); border-radius: 12px; padding: 10px 12px; font-size: 15px; font-weight: 700; }
.corpo { flex: 1; display: flex; align-items: center; justify-content: space-around; gap: 16px; padding: 8px 0; }
.cruz { display: grid; grid-template: repeat(3, var(--t)) / repeat(3, var(--t)); --t: min(26vw, 22vh, 120px); }
.d { background: var(--cartao); font-size: calc(var(--t) * 0.36); color: #c9d3de; transition: background .05s, transform .05s; }
.d.up { grid-area: 1 / 2; border-radius: 18px 18px 6px 6px; }
.d.left { grid-area: 2 / 1; border-radius: 18px 6px 6px 18px; }
.centro { grid-area: 2 / 2; background: var(--cartao); }
.d.right { grid-area: 2 / 3; border-radius: 6px 18px 18px 6px; }
.d.down { grid-area: 3 / 2; border-radius: 6px 6px 18px 18px; }
.acoes { position: relative; width: calc(var(--b) * 2.1); height: calc(var(--b) * 2.1); --b: min(30vw, 26vh, 130px); }
.acoes button { position: absolute; width: var(--b); height: var(--b); border-radius: 50%; font-weight: 900; transition: transform .05s, filter .05s; }
.a { right: 0; top: 0; background: var(--cor); color: #04110c; font-size: calc(var(--b) * 0.3); box-shadow: 0 6px 0 rgba(0,0,0,.35); }
.b { left: 0; bottom: 0; background: #2a3542; font-size: calc(var(--b) * 0.3); box-shadow: 0 6px 0 rgba(0,0,0,.35); }
.premido { transform: scale(0.93); filter: brightness(1.25); }
.d.premido { background: #23404a; color: #fff; }
.dica { text-align: center; color: var(--fraco); font-size: 14px; margin: 4px 0 10px; min-height: 18px; }

@media (orientation: portrait) {
  .corpo { flex-direction: column; justify-content: center; gap: 3vh; }
  .cruz { --t: min(27vw, 15vh, 120px); }
  .acoes { --b: min(30vw, 17vh, 130px); }
}

/* celular antigo sem min() (Chrome < 79): tamanhos fixos para a cruz e os botões não sumirem */
@supports not (width: min(1px, 2px)) {
  .cruz { --t: 96px; } .acoes { --b: 104px; }
}

/* 19/11/2026: dica sempre visível (no iPhone ela ficava abaixo da tela) e cartão do jogador no topo */
#pad { overflow: hidden; }
.corpo { min-height: 0; }
.dica { flex: none; background: var(--cartao); border-radius: 12px; padding: 8px 10px; color: #c9d3de; margin: 4px 0 6px; }
.dica:empty { display: none; }
header { border-bottom: 2px solid var(--cor); margin-bottom: 4px; }
