/* Ecos do Templo (02/12/2026) — todas as regras presas a .jogo-ecos-do-templo */
.jogo-ecos-do-templo {
  --et-noite: #0b0f33; --et-azul: #262c78; --et-ouro: #d8b465;
  position: relative; display: flex; flex-direction: column; width: 100%; overflow: hidden;
  border-radius: 18px; background: var(--et-noite); color: #fff;
  font-family: "Inter", system-ui, sans-serif; box-shadow: 0 12px 34px rgba(23, 26, 44, .22);
  user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent;
}

/* barra */
.jogo-ecos-do-templo .et-barra {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 12px;
  background: linear-gradient(180deg, rgba(38, 44, 120, .95), rgba(18, 24, 74, .95));
  border-bottom: 1px solid rgba(255, 255, 255, .08); position: relative; z-index: 2;
}
.jogo-ecos-do-templo .et-placar { display: flex; gap: 18px; align-items: flex-end; min-width: 0; }
.jogo-ecos-do-templo .et-num { display: flex; flex-direction: column; line-height: 1.05; min-width: 0; }
.jogo-ecos-do-templo .et-num span { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: rgba(255, 255, 255, .62); font-weight: 600; }
.jogo-ecos-do-templo .et-num strong { font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.jogo-ecos-do-templo .et-num-principal strong { font-size: 24px; color: #fff4c2; text-shadow: 0 0 14px rgba(255, 215, 106, .35); }
.jogo-ecos-do-templo .et-batendo strong { color: #ffd76a; }
.jogo-ecos-do-templo .et-acoes { display: flex; gap: 6px; flex-shrink: 0; }
.jogo-ecos-do-templo .et-bt {
  width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .07); color: #fff; font-size: 19px;
  cursor: pointer; transition: background .15s;
}
.jogo-ecos-do-templo .et-bt:hover { background: rgba(255, 255, 255, .14); }
.jogo-ecos-do-templo .et-bt:focus-visible, .jogo-ecos-do-templo .et-botao:focus-visible,
.jogo-ecos-do-templo .et-pedra:focus-visible { outline: 3px solid #ffd76a; outline-offset: 3px; }
.jogo-ecos-do-templo .et-aria { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* palco: céu com faixas de aurora; o tabuleiro no meio */
.jogo-ecos-do-templo .et-palco {
  position: relative; width: 100%; height: clamp(440px, calc(100dvh - 210px), 760px);
  display: flex; align-items: center; justify-content: center; overflow: hidden; container-type: size;
  background: radial-gradient(120% 80% at 50% 0%, #1c2370 0%, #0e1340 55%, #070a24 100%);
}
.jogo-ecos-do-templo .et-ceu { position: absolute; inset: 0; pointer-events: none; }
.jogo-ecos-do-templo .et-ceu::before {
  content: ""; position: absolute; left: -20%; right: -20%; top: -10%; height: 55%;
  background:
    radial-gradient(60% 40% at 30% 60%, rgba(74, 222, 128, .18), transparent 70%),
    radial-gradient(50% 35% at 70% 45%, rgba(167, 139, 250, .2), transparent 70%),
    radial-gradient(40% 30% at 50% 70%, rgba(56, 189, 248, .12), transparent 70%);
  filter: blur(8px); animation: et-aurora 14s ease-in-out infinite alternate;
}
.jogo-ecos-do-templo .et-ceu::after {
  content: ""; position: absolute; inset: 0; opacity: .7;
  background-image:
    radial-gradient(1.2px 1.2px at 12% 18%, #fff, transparent), radial-gradient(1px 1px at 28% 8%, #fff, transparent),
    radial-gradient(1.4px 1.4px at 46% 22%, #ffe9a8, transparent), radial-gradient(1px 1px at 64% 12%, #fff, transparent),
    radial-gradient(1.2px 1.2px at 82% 26%, #fff, transparent), radial-gradient(1px 1px at 90% 6%, #fff, transparent),
    radial-gradient(1px 1px at 8% 44%, #fff, transparent), radial-gradient(1.2px 1.2px at 94% 52%, #ffe9a8, transparent),
    radial-gradient(1px 1px at 18% 80%, #fff, transparent), radial-gradient(1px 1px at 78% 88%, #fff, transparent);
}
@keyframes et-aurora { from { transform: translateX(-4%) skewX(-4deg); } to { transform: translateX(4%) skewX(4deg); } }

/* tabuleiro: as quatro pedras em losango e o altar no centro */
.jogo-ecos-do-templo .et-tabuleiro {
  --lado: min(88cqw, 86cqh, 480px);
  position: relative; z-index: 1; width: var(--lado); height: var(--lado);
  display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(3, 1fr); gap: 4%;
}
.jogo-ecos-do-templo .et-tabuleiro::before {
  content: ""; position: absolute; inset: 9%; border-radius: 50%;
  border: 1px solid rgba(216, 180, 101, .28); box-shadow: 0 0 0 10px rgba(216, 180, 101, .05), inset 0 0 60px rgba(216, 180, 101, .08);
}
.jogo-ecos-do-templo .et-pedra {
  --c1: #fff; --c2: #888; --c3: #333; --luz: rgba(255, 255, 255, .6);
  position: relative; border: 0; padding: 0; cursor: pointer; border-radius: 22%;
  transform: rotate(45deg) scale(.9); touch-action: manipulation;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .5) 0%, rgba(255, 255, 255, 0) 38%),
    linear-gradient(315deg, rgba(0, 0, 0, .35) 0%, rgba(0, 0, 0, 0) 45%),
    radial-gradient(circle at 50% 50%, var(--c2) 0%, var(--c3) 100%);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .18), inset 0 -6px 14px rgba(0, 0, 0, .35), 0 8px 18px rgba(0, 0, 0, .35);
  transition: transform .12s ease-out, box-shadow .12s ease-out;
}
/* véu por cima da pedra: apagada = véu escuro; acesa = véu claro (sem filter, que cortava o brilho em volta) */
.jogo-ecos-do-templo .et-pedra::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: rgba(6, 8, 34, .42); transition: background .12s ease-out;
}
.jogo-ecos-do-templo .et-pedra[data-i="0"], .jogo-ecos-do-templo .et-halo-0 { grid-column: 2; grid-row: 1; }
.jogo-ecos-do-templo .et-pedra[data-i="1"], .jogo-ecos-do-templo .et-halo-1 { grid-column: 3; grid-row: 2; }
.jogo-ecos-do-templo .et-pedra[data-i="2"], .jogo-ecos-do-templo .et-halo-2 { grid-column: 2; grid-row: 3; }
.jogo-ecos-do-templo .et-pedra[data-i="3"], .jogo-ecos-do-templo .et-halo-3 { grid-column: 1; grid-row: 2; }
.jogo-ecos-do-templo .et-pedra { position: relative; z-index: 1; }
.jogo-ecos-do-templo .et-halo {
  align-self: center; justify-self: center; width: 190%; height: 190%; border-radius: 50%; pointer-events: none; z-index: 0;
  background: radial-gradient(circle, var(--luz) 0%, transparent 62%); opacity: 0; transition: opacity .14s ease-out;
}
.jogo-ecos-do-templo .et-halo.et-aceso { opacity: .9; transition-duration: .04s; }
.jogo-ecos-do-templo .et-safira { --c1: #bfdbfe; --c2: #3b82f6; --c3: #1e3a8a; --luz: rgba(96, 165, 250, .85); }
.jogo-ecos-do-templo .et-rubi { --c1: #fecdd3; --c2: #e11d48; --c3: #7f1d1d; --luz: rgba(251, 113, 133, .85); }
.jogo-ecos-do-templo .et-esmeralda { --c1: #bbf7d0; --c2: #10b981; --c3: #064e3b; --luz: rgba(52, 211, 153, .85); }
.jogo-ecos-do-templo .et-topazio { --c1: #fef3c7; --c2: #f59e0b; --c3: #78350f; --luz: rgba(252, 211, 77, .9); }
.jogo-ecos-do-templo .et-brilho {
  position: absolute; inset: 14%; border-radius: 18%; pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, .35), rgba(255, 255, 255, 0) 55%);
  border: 1px solid rgba(255, 255, 255, .22);
}
.jogo-ecos-do-templo .et-forma {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none;
  transform: rotate(-45deg); font-size: calc(var(--lado) * .045); color: rgba(255, 255, 255, .38);
  text-shadow: 0 1px 2px rgba(0, 0, 0, .4);
}
.jogo-ecos-do-templo .et-pedra:hover:not(:disabled)::after { background: rgba(6, 8, 34, .24); }
.jogo-ecos-do-templo .et-pedra:disabled { cursor: default; }
.jogo-ecos-do-templo .et-pedra.et-aceso {
  transform: rotate(45deg) scale(.97);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .55), 0 0 18px 3px var(--luz);
  transition-duration: .04s;
}
.jogo-ecos-do-templo .et-pedra.et-aceso .et-forma { color: rgba(255, 255, 255, .9); }
.jogo-ecos-do-templo .et-pedra.et-errado {
  animation: et-treme .4s ease-in-out;
  box-shadow: inset 0 0 0 3px rgba(255, 80, 80, .8), 0 0 26px 4px rgba(255, 60, 60, .6);
}
.jogo-ecos-do-templo .et-pedra.et-aceso::after { background: radial-gradient(circle at 40% 40%, rgba(255, 255, 255, .45), rgba(255, 255, 255, .12) 70%); transition-duration: .04s; }
.jogo-ecos-do-templo .et-pedra.et-errado::after { background: rgba(40, 10, 10, .62); }
.jogo-ecos-do-templo .et-pedra.et-era { animation: et-pisca .4s ease-in-out 3; box-shadow: 0 0 18px 3px var(--luz); }
.jogo-ecos-do-templo .et-pedra.et-era::after { background: rgba(255, 255, 255, .25); }
@keyframes et-treme { 0%, 100% { transform: rotate(45deg) scale(.9); } 25% { transform: rotate(39deg) scale(.9); } 75% { transform: rotate(51deg) scale(.9); } }
@keyframes et-pisca { 50% { box-shadow: 0 0 0 0 transparent; } }

/* altar no centro */
.jogo-ecos-do-templo .et-altar {
  grid-column: 2; grid-row: 2; align-self: center; justify-self: center; width: 92%; aspect-ratio: 1; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-align: center;
  background: radial-gradient(circle at 50% 35%, #2c3490, #141a55 70%);
  border: 2px solid rgba(216, 180, 101, .55); box-shadow: 0 0 0 5px rgba(216, 180, 101, .1), 0 10px 26px rgba(0, 0, 0, .45), inset 0 2px 0 rgba(255, 255, 255, .1);
  transition: box-shadow .3s, border-color .3s;
}
.jogo-ecos-do-templo .et-altar-num { font-size: calc(var(--lado) * .085); font-weight: 800; line-height: 1; color: #fff4c2; font-variant-numeric: tabular-nums; }
.jogo-ecos-do-templo .et-altar-txt { font-size: max(11px, calc(var(--lado) * .03)); color: rgba(255, 255, 255, .72); letter-spacing: .04em; max-width: 92%; line-height: 1.15; }
.jogo-ecos-do-templo .et-sua-vez .et-altar { border-color: #ffd76a; box-shadow: 0 0 0 6px rgba(255, 215, 106, .18), 0 0 30px rgba(255, 215, 106, .35); }
.jogo-ecos-do-templo .et-sua-vez .et-pedra:not(.et-aceso):not(.et-errado)::after { background: rgba(6, 8, 34, .22); }
.jogo-ecos-do-templo .et-festa .et-pedra { animation: et-festa 1s ease-out; }
.jogo-ecos-do-templo .et-festa .et-altar { box-shadow: 0 0 0 8px rgba(255, 215, 106, .25), 0 0 60px rgba(255, 215, 106, .6); }
@keyframes et-festa { 30% { box-shadow: 0 0 18px 4px var(--luz); } }

/* telas por cima */
.jogo-ecos-do-templo .et-tela {
  position: absolute; inset: 0; z-index: 5; display: flex; align-items: center; justify-content: center; padding: 18px;
  background: radial-gradient(120% 90% at 50% 40%, rgba(11, 15, 51, .55), rgba(11, 15, 51, .88));
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
}
.jogo-ecos-do-templo .et-tela[hidden] { display: none; }
.jogo-ecos-do-templo .et-caixa {
  width: min(380px, 100%); max-height: 100%; overflow-y: auto; display: flex; flex-direction: column; align-items: center; text-align: center;
  gap: 10px; padding: 26px 22px; border-radius: 20px;
  background: linear-gradient(180deg, rgba(58, 66, 166, .42), rgba(20, 26, 80, .8));
  border: 1px solid rgba(255, 255, 255, .16); box-shadow: 0 18px 50px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .12);
  animation: et-surge .28s ease-out;
}
@keyframes et-surge { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.jogo-ecos-do-templo .et-titulo { display: flex; flex-direction: column; line-height: .95; margin-bottom: 4px; }
.jogo-ecos-do-templo .et-titulo-1 {
  font-size: 46px; font-weight: 800; letter-spacing: -.02em;
  background: linear-gradient(90deg, #93c5fd, #ffffff 40%, #fcd34d 70%, #fb7185); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 18px rgba(147, 197, 253, .35));
}
.jogo-ecos-do-templo .et-titulo-2 { font-size: 18px; font-weight: 700; letter-spacing: .32em; text-transform: uppercase; color: var(--et-ouro); margin-top: 6px; }
.jogo-ecos-do-templo .et-ola, .jogo-ecos-do-templo .et-sub { margin: 0; font-size: 15px; color: rgba(255, 255, 255, .82); }
.jogo-ecos-do-templo .et-rec { margin: 2px 0 0; font-size: 14px; color: #ffd76a; font-weight: 600; }
.jogo-ecos-do-templo .et-nota { font-size: 13px; color: rgba(255, 255, 255, .6); margin-top: 4px; }
.jogo-ecos-do-templo .et-como { list-style: none; margin: 4px 0 6px; padding: 0; display: flex; flex-direction: column; gap: 9px; text-align: left; width: 100%; }
.jogo-ecos-do-templo .et-como li { display: flex; gap: 10px; align-items: center; font-size: 15px; color: rgba(255, 255, 255, .9); line-height: 1.3; }
.jogo-ecos-do-templo .et-como i {
  flex-shrink: 0; width: 32px; height: 32px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .09); color: #ffd76a; font-size: 16px;
}
.jogo-ecos-do-templo .et-botao {
  width: 100%; min-height: 48px; border-radius: 14px; font: inherit; font-size: 16px; font-weight: 700; cursor: pointer;
  transition: transform .12s, box-shadow .15s, background .15s;
}
.jogo-ecos-do-templo .et-principal {
  border: 0; color: #2a1e05; background: linear-gradient(180deg, #ffe08a, #d8b465 60%, #b08a3c);
  box-shadow: 0 8px 22px rgba(216, 180, 101, .35), inset 0 1px 0 rgba(255, 255, 255, .6);
}
.jogo-ecos-do-templo .et-principal:hover { transform: translateY(-1px); }
.jogo-ecos-do-templo .et-principal:active { transform: translateY(1px); }
.jogo-ecos-do-templo .et-sec { border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .06); color: #fff; font-weight: 600; font-size: 15px; }
.jogo-ecos-do-templo .et-sec:hover { background: rgba(255, 255, 255, .12); }
.jogo-ecos-do-templo .et-pausa-tit, .jogo-ecos-do-templo .et-fim-tit { font-size: 28px; font-weight: 800; }
.jogo-ecos-do-templo .et-fim-pts { font-size: 50px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; color: #fff4c2; text-shadow: 0 0 24px rgba(255, 215, 106, .45); }
.jogo-ecos-do-templo .et-selo { margin: 0; padding: 4px 14px; border-radius: 999px; font-size: 14px; font-weight: 700; color: #2a1e05; background: linear-gradient(180deg, #ffe08a, #d8b465); }
.jogo-ecos-do-templo .et-msg { margin: 0; min-height: 20px; font-size: 15px; color: rgba(255, 255, 255, .85); }
.jogo-ecos-do-templo .et-novo { color: #ffd76a; font-weight: 700; }
.jogo-ecos-do-templo .et-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; width: 100%; margin: 4px 0 6px; }
.jogo-ecos-do-templo .et-stats div { padding: 9px 6px; border-radius: 12px; background: rgba(255, 255, 255, .07); display: flex; flex-direction: column; gap: 2px; }
.jogo-ecos-do-templo .et-stats span { font-size: 12px; color: rgba(255, 255, 255, .6); text-transform: uppercase; letter-spacing: .05em; }
.jogo-ecos-do-templo .et-stats strong { font-size: 19px; font-weight: 800; }

/* celular */
@media (max-width: 575.98px) {
  .jogo-ecos-do-templo { border-radius: 14px; }
  .jogo-ecos-do-templo .et-palco { height: calc(100dvh - 190px); min-height: 400px; }
  .jogo-ecos-do-templo .et-placar { gap: 12px; }
  .jogo-ecos-do-templo .et-num-principal strong { font-size: 21px; }
  .jogo-ecos-do-templo .et-num strong { font-size: 15px; }
  .jogo-ecos-do-templo .et-bt { width: 42px; height: 42px; }
  .jogo-ecos-do-templo .et-tabuleiro { --lado: min(94cqw, 86cqh); }
}

/* tela cheia do site (jogos.js) */
.jogo-raiz.jogo-ecos-do-templo.is-cheia {
  max-width: none; border-radius: 0; background: var(--et-noite); overflow: hidden;
  padding: env(safe-area-inset-top, 0px) env(safe-area-inset-right, 0px) env(safe-area-inset-bottom, 0px) env(safe-area-inset-left, 0px);
}
.jogo-raiz.jogo-ecos-do-templo.is-cheia .et-palco { flex: 1; height: auto; min-height: 0; }

/* menos movimento */
.jogo-ecos-do-templo.et-calmo .et-ceu::before, .jogo-ecos-do-templo.et-calmo .et-caixa { animation: none; }
.jogo-ecos-do-templo.et-calmo .et-pedra.et-errado, .jogo-ecos-do-templo.et-calmo .et-festa .et-pedra { animation: none; }
@media (prefers-reduced-motion: reduce) {
  .jogo-ecos-do-templo .et-ceu::before, .jogo-ecos-do-templo .et-caixa, .jogo-ecos-do-templo .et-pedra { animation: none !important; }
}
