/* Páginas de cada jogo (página do jogo e documentos) no mesmo padrão do estúdio:
   sala escura, facho de luz, grão, vidro e as mesmas cores e fontes de css/estudio.css. Sem script. */

:root {
  --fundo: #000;
  --texto: #f5f5f7;
  --secundario: rgba(235, 235, 245, 0.68);
  --terciario: rgba(235, 235, 245, 0.38);
  --icone: #d1d1d6;
  --vidro: rgba(28, 28, 30, 0.66);
  --vidro-claro: rgba(255, 255, 255, 0.06);
  --linha: rgba(255, 255, 255, 0.09);
  --raio: 22px;
  --mola: cubic-bezier(0.2, 0.8, 0.2, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--fundo); }
body {
  margin: 0;
  min-height: 100vh;
  display: flex; flex-direction: column;
  background: var(--fundo);
  color: var(--texto);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--texto); text-underline-offset: 3px; text-decoration-color: rgba(255, 255, 255, 0.35); }
a:hover { text-decoration-color: currentColor; }
a:focus-visible { outline: 2px solid var(--texto); outline-offset: 3px; border-radius: 10px; }
strong { color: var(--texto); font-weight: 600; }

/* ---------- Topo de vidro ---------- */

.topo {
  position: sticky; top: 0; z-index: 30;
  background: rgba(0, 0, 0, 0.62);
  -webkit-backdrop-filter: blur(20px) saturate(1.6);
  backdrop-filter: blur(20px) saturate(1.6);
  border-bottom: 1px solid var(--linha);
}
.topo-in {
  max-width: 1080px; margin: 0 auto;
  padding: 10px max(16px, env(safe-area-inset-right)) 10px max(16px, env(safe-area-inset-left));
  display: grid; grid-template-columns: auto 1fr auto; grid-template-areas: "marca abas idioma";
  align-items: center; gap: 10px 18px;
}
.marca {
  grid-area: marca;
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--texto);
  font-weight: 700; font-size: 15px; letter-spacing: 0.16em; text-transform: uppercase;
}
.marca img { width: 24px; height: auto; opacity: 0.88; }
.marca:hover img { opacity: 1; }
.abas { grid-area: abas; display: flex; justify-content: center; gap: 4px; }
.abas a {
  color: var(--secundario); text-decoration: none; white-space: nowrap;
  padding: 7px 14px; border-radius: 999px; font-size: 14px; font-weight: 500;
  transition: background 0.2s, color 0.2s;
}
.abas a:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.abas a[aria-current="page"] { background: rgba(255, 255, 255, 0.14); color: #fff; }
.idioma {
  grid-area: idioma;
  height: 40px; padding: 0 14px 0 11px;
  display: inline-flex; align-items: center; gap: 7px;
  border-radius: 999px;
  color: var(--icone);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-decoration: none;
  font-size: 13px; font-weight: 600; letter-spacing: 0.06em;
  transition: background 0.25s, color 0.25s;
}
.idioma svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.idioma:hover { background: rgba(255, 255, 255, 0.16); color: #fff; }

/* ---------- Sala do jogo (abertura da página do jogo) ---------- */

main { flex: 1 0 auto; width: 100%; }
.sala {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: min(86vh, 860px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 64px 16px 72px;
}
.sala .luz {
  position: absolute; left: 50%; top: -14vh; z-index: -3;
  width: max(110vh, 90vw); height: 112%;
  transform: translateX(-50%);
  background: url("/img/luz.png") center / 100% 100% no-repeat;
  opacity: 0.9;
  pointer-events: none;
}
.sala .chao {
  position: absolute; left: 50%; bottom: 4%; z-index: -3;
  width: max(90vh, 70vw); height: 34%;
  transform: translateX(-50%);
  background: radial-gradient(50% 50% at 50% 50%, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0) 70%);
  pointer-events: none;
}
.sala .grao {
  position: absolute; inset: 0; z-index: -2;
  background: url("/img/grao.png");
  opacity: 0.035;
  pointer-events: none;
}
.sala .vinheta {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(75% 70% at 50% 45%, rgba(0, 0, 0, 0) 45%, rgba(0, 0, 0, 0.8) 100%);
}
.logo-jogo {
  width: min(640px, 88vw);
  filter: drop-shadow(0 26px 40px rgba(0, 0, 0, 0.75));
  animation: surgir 1.1s var(--mola) both;
}
.sala .selo { margin-top: 26px; animation: surgir 1.1s var(--mola) 0.12s both; }
.sala h1 {
  margin: 18px 0 12px; max-width: 760px;
  font-size: clamp(30px, 4.4vw, 50px); line-height: 1.08; font-weight: 700; letter-spacing: -0.025em;
  animation: surgir 1.1s var(--mola) 0.2s both;
}
.sala p { margin: 0; max-width: 620px; font-size: clamp(16px, 1.5vw, 19px); color: var(--secundario); animation: surgir 1.1s var(--mola) 0.28s both; }
.sala .acoes { justify-content: center; margin-top: 28px; animation: surgir 1.1s var(--mola) 0.36s both; }
@keyframes surgir { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.selo {
  display: inline-block;
  font-size: 12px; font-weight: 600; letter-spacing: 0.02em;
  color: #000; background: var(--texto);
  padding: 4px 12px; border-radius: 999px;
}

/* ---------- Botões ---------- */

.acoes { display: flex; flex-wrap: wrap; gap: 10px; }
.botao {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px; padding: 0 22px;
  border-radius: 999px;
  background: var(--texto); color: #000;
  font-weight: 600; text-decoration: none;
  transition: transform 0.2s var(--mola), background 0.2s;
}
.botao:hover { background: #fff; }
.botao:active { transform: scale(0.97); }
.botao.vidro { background: rgba(255, 255, 255, 0.1); color: var(--texto); border: 1px solid var(--linha); }
.botao.vidro:hover { background: rgba(255, 255, 255, 0.18); }

/* ---------- Painéis de vidro ---------- */

.coluna { width: 100%; max-width: 860px; margin: 0 auto; padding: 8px 16px 56px; }
.doc-coluna { padding-top: 36px; }
.painel {
  position: relative;
  margin: 0 0 22px;
  padding: 30px 30px 28px;
  background: var(--vidro);
  border: 1px solid var(--linha);
  border-radius: var(--raio);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}
.sobretitulo { margin: 0 0 4px; font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--terciario); }
.painel h2 { margin: 0 0 14px; font-size: 28px; line-height: 1.15; font-weight: 700; letter-spacing: -0.02em; }
.painel p { margin: 0 0 12px; color: var(--secundario); }
.capa { width: 100%; border-radius: 16px; border: 1px solid var(--linha); margin: 6px 0 20px; }

.lista { list-style: none; margin: 18px 0 0; padding: 0; border-radius: 14px; overflow: hidden; background: var(--vidro-claro); }
.lista li { border-top: 1px solid var(--linha); margin: 0; }
.lista li:first-child { border-top: 0; }
.lista > li:not(:has(a)) { display: flex; justify-content: space-between; gap: 16px; padding: 13px 16px; }
.lista li > span { color: var(--secundario); }
.lista li > strong { font-weight: 500; text-align: right; }
.lista.links a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 16px; text-decoration: none;
  transition: background 0.2s;
}
.lista.links a::after {
  content: ""; flex: none; width: 8px; height: 8px;
  border-right: 2px solid var(--terciario); border-top: 2px solid var(--terciario);
  transform: rotate(45deg);
}
.lista.links a:hover { background: rgba(255, 255, 255, 0.06); }
.lista.links span { display: flex; flex-direction: column; font-size: 14px; color: var(--secundario); min-width: 0; }
.lista.links strong { font-size: 16px; font-weight: 500; }

/* ---------- Documentos (privacidade, termos, excluir conta) ---------- */

.doc { padding: 36px 40px 40px; }
.doc h1 { margin: 0 0 14px; font-size: clamp(28px, 3.6vw, 38px); line-height: 1.12; font-weight: 700; letter-spacing: -0.025em; }
.doc h2 {
  margin: 36px 0 12px; padding-top: 26px;
  border-top: 1px solid var(--linha);
  font-size: 21px; letter-spacing: -0.01em;
}
.doc h3 { margin: 24px 0 8px; font-size: 17px; font-weight: 600; }
.doc p, .doc li { color: var(--secundario); }
.doc ul, .doc ol { margin: 0 0 14px; padding-left: 1.4em; }
.doc li { margin-bottom: 6px; }
.doc li::marker { color: var(--terciario); }
.meta {
  display: inline-block;
  font-size: 12px !important; font-weight: 600; letter-spacing: 0.02em;
  color: #000 !important; background: var(--texto);
  padding: 4px 12px; border-radius: 999px;
  margin: 0 0 8px !important;
}
.suave { font-size: 14px; color: var(--terciario) !important; }
.aviso {
  margin: 18px 0; padding: 14px 18px;
  border-radius: 14px;
  background: rgba(255, 196, 64, 0.08);
  border: 1px solid rgba(255, 196, 64, 0.28);
  color: rgba(255, 236, 200, 0.86);
}
.aviso strong { color: #ffd479; }

table { width: 100%; border-collapse: separate; border-spacing: 0; margin: 8px 0 20px; font-size: 14.5px; border: 1px solid var(--linha); border-radius: 14px; overflow: hidden; }
th, td { text-align: left; vertical-align: top; padding: 11px 14px; border-top: 1px solid var(--linha); }
td + td, th + th { border-left: 1px solid var(--linha); }
thead th { border-top: 0; background: rgba(255, 255, 255, 0.07); font-weight: 600; color: var(--texto); font-size: 13px; }
td { color: var(--secundario); }
tbody tr:nth-child(even) td { background: rgba(255, 255, 255, 0.025); }

.passos { list-style: none; counter-reset: passo; padding: 0 !important; margin: 0 0 16px; }
.passos li {
  counter-increment: passo;
  position: relative;
  background: var(--vidro-claro);
  border: 1px solid var(--linha);
  border-radius: 14px;
  padding: 14px 16px 14px 60px;
  margin-bottom: 10px;
}
.passos li::before {
  content: counter(passo);
  position: absolute; left: 14px; top: 11px;
  width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--texto); color: #000;
  font-weight: 700; font-size: 14px;
}

/* ---------- 404 ---------- */

.erro { text-align: center; padding-top: 12vh; }
.erro h1 { font-size: clamp(64px, 12vw, 120px); line-height: 1; margin: 0 0 18px; letter-spacing: -0.04em; color: rgba(235, 235, 245, 0.85); }
.erro p { color: var(--secundario); }
.erro .acoes { justify-content: center; margin-top: 26px; }

/* ---------- Rodapé ---------- */

.rodape { border-top: 1px solid var(--linha); margin-top: auto; }
.rodape-in {
  max-width: 1080px; margin: 0 auto;
  padding: 22px 16px max(26px, env(safe-area-inset-bottom));
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px;
  font-size: 13px; color: var(--terciario);
}
.rodape ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.rodape a { color: var(--secundario); text-decoration: none; }
.rodape a:hover { color: #fff; }

/* ---------- Celular ---------- */

@media (max-width: 760px) {
  .topo-in { grid-template-columns: auto 1fr; grid-template-areas: "marca idioma" "abas abas"; padding-top: 8px; padding-bottom: 8px; }
  .idioma { justify-self: end; height: 38px; }
  .abas { justify-content: flex-start; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px; }
  .abas::-webkit-scrollbar { display: none; }
  .abas { gap: 0; }
  .abas a { padding: 6px 10px; font-size: 13px; }
  .sala { min-height: 0; padding: 56px 16px 64px; }
  .painel { padding: 24px 18px 22px; }
  .painel h2 { font-size: 24px; }
  .doc { padding: 26px 18px 28px; }
  .doc-coluna { padding-top: 20px; }
  .coluna { padding-left: 12px; padding-right: 12px; }

  /* Tabelas viram cartões */
  table, thead, tbody, tr, th, td { display: block; width: 100%; }
  table { border: 0; border-radius: 0; overflow: visible; }
  thead { position: absolute; left: -9999px; }
  tr { border: 1px solid var(--linha); border-radius: 14px; margin-bottom: 12px; overflow: hidden; background: var(--vidro-claro); }
  td, tbody tr:nth-child(even) td { border: 0; border-top: 1px solid var(--linha); padding: 9px 14px; background: none; }
  td:first-child { border-top: 0; }
  td + td { border-left: 0; }
  td::before {
    content: attr(data-r);
    display: block;
    font-size: 11px; font-weight: 600;
    color: var(--terciario);
    text-transform: uppercase; letter-spacing: 0.06em;
  }
}

@media (prefers-reduced-motion: reduce) {
  .logo-jogo, .sala .selo, .sala h1, .sala p, .sala .acoes { animation: none; }
}
