/* ARENA do Canarinho — estilos (direção de arte, qui 22/10/2026). Complementa o estilo.css: nada global é redefinido;
 * tudo vive sob .arena-telao (projetor 16:9), .arena-aluno (celular, dentro do .palco) ou prefixo .ar-.
 * Estética: programa de auditório à noite — palco índigo, letreiro neon (celeste, rosa, turquesa), placar luminoso
 * em peso 900 ("Placar", já declarada no estilo.css), animações curtas que celebram o ACERTO. Sem dourado, sem feltro
 * verde, sem iconografia vetada pela bíblia (bloco 9): a única luz que pisca é a de quem acertou. A largura das barras vem de classes
 * .p0…p100 (CSP sem style= em linha); a barra de tempo do telão encolhe por animação, duração em .t10…t120.
 * Animações desligadas por prefers-reduced-motion e por html.sem-animacao (ajuste do app). */

/* ═════════ TELÃO (projetor) ═════════ */
.arena-telao {
  position: fixed; inset: 0; z-index: 20; overflow: hidden; display: grid; grid-template-rows: auto auto 1fr;
  gap: 1.6vmin; padding: 2.2vmin 3.2vmin 10vmin; color: var(--texto); font-size: 2.2vmin; line-height: 1.35;
  background:
    radial-gradient(110% 55% at 50% -8%, #3B1E8F 0%, transparent 62%),
    radial-gradient(55% 40% at -5% 35%, rgba(255, 79, 139, .22), transparent 70%),
    radial-gradient(55% 40% at 105% 25%, rgba(31, 214, 193, .18), transparent 70%),
    var(--palco);
}
.arena-telao::before {   /* dois holofotes parados, bem suaves, para dar profundidade de palco */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    conic-gradient(from 205deg at 12% -12%, transparent 0 18deg, rgba(79, 179, 255, .10) 26deg, transparent 36deg),
    conic-gradient(from 125deg at 88% -12%, transparent 0 18deg, rgba(31, 214, 193, .10) 26deg, transparent 36deg);
}
.arena-telao > * { position: relative; }

/* ── cabeça: mascote, marca, código pequeno ── */
.ar-cabeca { display: flex; align-items: center; gap: 2vmin; min-height: 9vmin; }
.arena-telao .ar-mascote { height: 9vmin; width: auto; flex: 0 0 auto; filter: drop-shadow(0 1.2vmin 1.6vmin rgba(0, 0, 0, .5)); animation: ar-flutua 3.2s ease-in-out infinite; }
.ar-marca { display: flex; flex-direction: column; gap: .3vmin; min-width: 0; }
.ar-titulo { font: 900 4vmin/1 var(--placar); letter-spacing: .02em; color: var(--celeste); transform: skew(-8deg); display: inline-block;
  text-shadow: .4vmin .4vmin 0 var(--rosa), 0 0 2.4vmin rgba(79, 179, 255, .55); }
.ar-sub { font-weight: 700; color: var(--suave); font-size: 2vmin; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ar-codigo-mini { margin-left: auto; padding: 1vmin 2vmin; border-radius: 999px; background: rgba(40, 21, 94, .85); border: .2vmin solid var(--linha);
  font-weight: 700; color: var(--suave); font-size: 2vmin; white-space: nowrap; }
.ar-codigo-mini b { font: 900 2.8vmin/1 var(--placar); letter-spacing: .18em; color: var(--texto); margin-left: .4em; }

/* ── fala do mascote: balão branco igual ao do app, em tamanho de projetor ── */
.arena-telao .ar-fala { position: relative; margin: 0 0 0 11vmin; max-width: 70vw; width: fit-content; background: var(--texto); color: #1B0F3B;
  font-weight: 600; font-size: 2.4vmin; padding: 1.4vmin 2.2vmin; border-radius: 2.2vmin; line-height: 1.3; animation: ar-pop .45s cubic-bezier(.2, 1.5, .4, 1); }
.arena-telao .ar-fala::before { content: ""; position: absolute; left: -1.4vmin; top: 2vmin; border: 1.4vmin solid transparent; border-right-color: var(--texto); border-left: 0; }
.arena-telao .ar-fala:empty { display: none; }

/* ── SAGUÃO: código gigante + QR à esquerda, turma entrando à direita, regras embaixo ── */
.ar-saguao { display: grid; grid-template-columns: 1.05fr 1fr; grid-template-rows: 1fr auto; gap: 2.4vmin 3vmin; min-height: 0; }
.ar-entrada { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2vmin; min-height: 0; }
.ar-codigo { display: flex; gap: 1.6vmin; }
.ar-letra { display: grid; place-items: center; width: 13vmin; height: 15vmin; border-radius: 2.2vmin; font: 900 10vmin/1 var(--placar); color: #fff;
  background: linear-gradient(180deg, var(--painel2), var(--painel)); border: .3vmin solid var(--linha); box-shadow: var(--sombra); animation: ar-sobe-leve .5s ease both; }
.ar-letra:nth-child(1) { color: var(--rosa); border-color: var(--rosa); box-shadow: 0 0 2.6vmin rgba(255, 79, 139, .45), var(--sombra); text-shadow: 0 0 1.6vmin rgba(255, 79, 139, .7); animation-delay: 0s; }
.ar-letra:nth-child(2) { color: var(--turquesa); border-color: var(--turquesa); box-shadow: 0 0 2.6vmin rgba(31, 214, 193, .45), var(--sombra); text-shadow: 0 0 1.6vmin rgba(31, 214, 193, .7); animation-delay: .08s; }
.ar-letra:nth-child(3) { color: var(--celeste); border-color: var(--celeste); box-shadow: 0 0 2.6vmin rgba(79, 179, 255, .45), var(--sombra); text-shadow: 0 0 1.6vmin rgba(79, 179, 255, .7); animation-delay: .16s; }
.ar-letra:nth-child(4) { color: var(--violeta); border-color: var(--violeta); box-shadow: 0 0 2.6vmin rgba(139, 108, 255, .5), var(--sombra); text-shadow: 0 0 1.6vmin rgba(139, 108, 255, .8); animation-delay: .24s; }
.ar-qr { background: #fff; padding: 1.4vmin; border-radius: 2vmin; box-shadow: var(--sombra); line-height: 0; }
.ar-qr svg { display: block; width: 24vmin; height: 24vmin; }
.ar-endereco { margin: 0; text-align: center; font-weight: 700; font-size: 2.3vmin; color: var(--suave); max-width: 44vw; }
.ar-turma { display: flex; flex-direction: column; gap: 1.4vmin; min-height: 0; padding: 2vmin; border-radius: var(--raio);
  background: rgba(40, 21, 94, .55); border: .2vmin solid var(--linha); }
.ar-contagem { margin: 0; font: 900 3.2vmin/1.1 var(--placar); color: var(--turquesa); }
.ar-apelidos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-content: flex-start; gap: 1vmin; overflow: hidden; }
.ar-apelido { padding: .9vmin 1.8vmin; border-radius: 999px; background: var(--painel2); border: .2vmin solid var(--linha); font-weight: 700; font-size: 2.2vmin;
  color: var(--texto); overflow-wrap: anywhere; max-width: 100%; }
.ar-apelido.novo { border-color: var(--celeste); box-shadow: 0 0 1.8vmin rgba(79, 179, 255, .6); animation: ar-chega .55s cubic-bezier(.2, 1.5, .4, 1) both, ar-acende 1.8s ease .55s both; }
.ar-regras { grid-column: 1 / -1; margin: 0; padding: 0 0 0 2.4em; columns: 2; column-gap: 4vmin; font-size: 1.9vmin; color: var(--suave); line-height: 1.3; }
.ar-regras li { margin: .35em 0; break-inside: avoid; padding-left: .2em; }
.ar-regras li::marker { color: var(--celeste); font-weight: 900; }

/* ── PERGUNTA e REVELAÇÃO ── */
.ar-pergunta { display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto auto; gap: 1.4vmin; min-height: 0; }
.ar-pergunta:has(.ar-figura img) { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto minmax(0, 1fr) auto auto; }
.ar-pergunta:has(.ar-figura img) .ar-num, .ar-pergunta:has(.ar-figura img) .ar-enunciado, .ar-pergunta:has(.ar-figura img) .ar-respostas,
.ar-pergunta:has(.ar-figura img) .ar-tempo { grid-column: 1 / -1; }
.ar-num { margin: 0; font: 900 2.2vmin/1 var(--placar); letter-spacing: .08em; text-transform: uppercase; color: var(--celeste); }
.ar-enunciado { margin: 0; font-size: 3.2vmin; font-weight: 600; line-height: 1.35; text-wrap: pretty; }
.ar-figura { margin: 0; min-height: 0; display: flex; align-items: center; justify-content: center; }
.ar-figura:empty { display: none; }
.ar-figura img { max-width: 100%; max-height: 100%; height: auto; border-radius: 1.6vmin; background: #fff; display: block; object-fit: contain; }
.ar-alternativas { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 1.4vmin; min-height: 0; align-content: start; }
.ar-pergunta:has(.ar-figura img) .ar-alternativas { grid-template-columns: 1fr; }
.ar-alternativas li { position: relative; display: flex; align-items: center; gap: 1.6vmin; padding: 1.2vmin 1.6vmin 1.2vmin 1.2vmin; min-height: 7vmin;
  border-radius: 2vmin; background: var(--palco2); border: .3vmin solid var(--linha); font-size: 2.5vmin; font-weight: 600; overflow: hidden;
  transition: border-color .25s ease, background .25s ease, opacity .25s ease, transform .25s ease; }
.ar-alternativas li > span { flex: 1; min-width: 0; }
.ar-letra-alt { flex: 0 0 5.4vmin; height: 5.4vmin; display: grid; place-items: center; border-radius: 1.4vmin; font: 900 2.8vmin/1 var(--placar); color: #fff; }
.ar-alternativas li[data-letra="A"] .ar-letra-alt { background: var(--rosa); }
.ar-alternativas li[data-letra="B"] .ar-letra-alt { background: var(--turquesa); color: #06302C; }
.ar-alternativas li[data-letra="C"] .ar-letra-alt { background: var(--celeste); color: #2A1060; }
.ar-alternativas li[data-letra="D"] .ar-letra-alt { background: var(--violeta); }
.ar-alternativas li[data-letra="E"] .ar-letra-alt { background: var(--laranja); color: #3A1400; }
.ar-alternativas li.certa { border-color: var(--certo); background: rgba(43, 227, 154, .18); transform: scale(1.015); animation: ar-brilho-certo 1.1s ease; }
.ar-alternativas li.certa::after { content: "✓"; position: absolute; right: 1.6vmin; top: 50%; transform: translateY(-50%); font: 900 3.4vmin/1 var(--placar); color: var(--certo); text-shadow: 0 0 1.6vmin rgba(43, 227, 154, .8); }
.ar-alternativas li.errada { opacity: .55; }
/* distribuição de respostas (só na revelação): barra fina no rodapé de cada alternativa */
.ar-dist { position: absolute; left: 0; right: 0; bottom: 0; height: .9vmin; background: rgba(255, 255, 255, .08); display: block; }
.ar-dist > i { display: block; height: 100%; width: 0; background: var(--suave); transition: width .8s cubic-bezier(.2, .9, .3, 1); }
.ar-alternativas li.certa .ar-dist > i { background: var(--certo); box-shadow: 0 0 1.2vmin rgba(43, 227, 154, .8); }
.ar-dist::after { content: attr(data-pct) "%"; position: absolute; right: 1.6vmin; bottom: 1.2vmin; font: 900 1.9vmin/1 var(--placar); color: var(--suave); }
.ar-alternativas li.certa .ar-dist::after { display: none; }   /* o ✓ ocupa o canto */
.ar-alternativas li.certa { padding-right: 7vmin; }
/* contagem de quem respondeu */
.ar-respostas { display: flex; align-items: center; gap: 2vmin; font-weight: 700; font-size: 2.2vmin; color: var(--suave); }
.ar-respostas > span { flex: 0 0 auto; }
.ar-barra { flex: 1; height: 1.6vmin; border-radius: 1vmin; background: var(--painel2); overflow: hidden; }
.ar-barra > i { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--celeste), var(--turquesa));
  box-shadow: 0 0 1.4vmin rgba(79, 179, 255, .6); transition: width .5s cubic-bezier(.2, .9, .3, 1); }
/* tempo da questão (só no telão, instrumento do condutor; o aluno nunca vê isto) */
.ar-tempo { height: 1vmin; border-radius: 1vmin; background: var(--painel2); overflow: hidden; }
.ar-tempo:empty { display: none; }
.ar-tempo-barra { display: block; height: 100%; width: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--violeta), var(--rosa));
  transform-origin: left center; animation: ar-encolhe 30s linear forwards; }
.ar-tempo-barra.t10 { animation-duration: 10s; } .ar-tempo-barra.t15 { animation-duration: 15s; } .ar-tempo-barra.t20 { animation-duration: 20s; }
.ar-tempo-barra.t30 { animation-duration: 30s; } .ar-tempo-barra.t45 { animation-duration: 45s; } .ar-tempo-barra.t60 { animation-duration: 60s; }
.ar-tempo-barra.t90 { animation-duration: 90s; } .ar-tempo-barra.t120 { animation-duration: 120s; }
.ar-tempo.t10 .ar-tempo-barra { animation-duration: 10s; } .ar-tempo.t15 .ar-tempo-barra { animation-duration: 15s; } .ar-tempo.t20 .ar-tempo-barra { animation-duration: 20s; }
.ar-tempo.t30 .ar-tempo-barra { animation-duration: 30s; } .ar-tempo.t45 .ar-tempo-barra { animation-duration: 45s; } .ar-tempo.t60 .ar-tempo-barra { animation-duration: 60s; }
.ar-tempo.t90 .ar-tempo-barra { animation-duration: 90s; } .ar-tempo.t120 .ar-tempo-barra { animation-duration: 120s; }
/* larguras em passos de 5 (CSP sem style= em linha); valem para .ar-dist > i, .ar-barra > i e qualquer outra barra .ar- */
.p0 { width: 0% !important; } .p5 { width: 5% !important; } .p10 { width: 10% !important; } .p15 { width: 15% !important; }
.p20 { width: 20% !important; } .p25 { width: 25% !important; } .p30 { width: 30% !important; } .p35 { width: 35% !important; }
.p40 { width: 40% !important; } .p45 { width: 45% !important; } .p50 { width: 50% !important; } .p55 { width: 55% !important; }
.p60 { width: 60% !important; } .p65 { width: 65% !important; } .p70 { width: 70% !important; } .p75 { width: 75% !important; }
.p80 { width: 80% !important; } .p85 { width: 85% !important; } .p90 { width: 90% !important; } .p95 { width: 95% !important; }
.p100 { width: 100% !important; }

/* ── PLACAR: até 10 linhas, letreiro luminoso ── */
.ar-placar-sec { display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 1.2vmin; min-height: 0; }
.ar-h2 { margin: 0; font: 900 4vmin/1 var(--placar); color: var(--celeste); letter-spacing: .02em; text-shadow: 0 0 2.4vmin rgba(79, 179, 255, .5); }
.ar-placar { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-rows: minmax(0, 1fr); gap: .8vmin; min-height: 0; counter-reset: none; }
.ar-placar:has(> :nth-child(6)) { grid-template-columns: 1fr 1fr; grid-auto-flow: row; }   /* 6 a 10 linhas: duas colunas, ainda legíveis */
.ar-linha { display: grid; grid-template-columns: 6vmin 1fr auto auto; align-items: center; gap: 1.6vmin; padding: .8vmin 1.8vmin .8vmin 1vmin; min-height: 5.6vmin;
  border-radius: 1.6vmin; background: rgba(40, 21, 94, .7); border: .25vmin solid var(--linha); font-size: 2.5vmin; font-variant-numeric: tabular-nums;
  transition: background .3s ease, border-color .3s ease, box-shadow .3s ease; }
.ar-pos { display: grid; place-items: center; height: 4.6vmin; border-radius: 1.2vmin; background: var(--violeta); color: #fff; font: 900 2.4vmin/1 var(--placar); }
.ar-placar > :nth-child(1) .ar-pos { background: var(--celeste); color: #2A1060; box-shadow: 0 0 1.6vmin rgba(79, 179, 255, .8); }
.ar-placar > :nth-child(2) .ar-pos { background: var(--turquesa); color: #06302C; }
.ar-placar > :nth-child(3) .ar-pos { background: var(--rosa); }
.ar-placar > :nth-child(1) { border-color: var(--celeste); background: rgba(79, 179, 255, .12); }
.ar-nome { font-weight: 800; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ar-linha .ar-pontos { font: 900 2.8vmin/1 var(--placar); color: var(--celeste); }
.ar-chamas { display: none; font-weight: 800; font-size: 1.9vmin; color: var(--laranja); padding: .4vmin 1.2vmin; border-radius: 999px;
  background: rgba(255, 138, 61, .16); border: .2vmin solid rgba(255, 138, 61, .55); white-space: nowrap; }
.ar-chamas::before { content: "🔥 "; }
.ar-linha.em-chamas .ar-chamas { display: inline-block; }
.ar-linha.em-chamas { border-color: var(--laranja); animation: ar-chamas 1.6s ease-in-out infinite; }
.ar-linha.sobe { animation: ar-sobe .7s cubic-bezier(.2, 1.3, .4, 1) both, ar-acende 1.6s ease .3s both; }
.ar-linha.sobe.em-chamas { animation: ar-sobe .7s cubic-bezier(.2, 1.3, .4, 1) both, ar-chamas 1.6s ease-in-out .7s infinite; }
.ar-linha.sobe .ar-pontos { animation: ar-pop .6s cubic-bezier(.2, 1.6, .4, 1) .2s both; }
.ar-linha.desce { animation: ar-desce .6s ease both; }

/* ── PÓDIO: três degraus que sobem do chão, 2º à esquerda, 1º no meio, 3º à direita ── */
.ar-podio { display: flex; align-items: flex-end; justify-content: center; gap: 2.4vmin; min-height: 0; padding: 0 6vmin; }
.ar-degrau { position: relative; display: flex; flex-direction: column; justify-content: flex-start; align-items: center; gap: .6vmin; width: 26vmin; padding: 2vmin 1.6vmin;
  border-radius: 2.4vmin 2.4vmin 0 0; text-align: center; color: var(--texto); transform-origin: bottom center; animation: ar-degrau .9s cubic-bezier(.2, 1.2, .4, 1) both; }
.ar-degrau::before { position: absolute; top: -5.4vmin; left: 50%; transform: translateX(-50%); display: grid; place-items: center; width: 7vmin; height: 7vmin; border-radius: 50%;
  font: 900 3.6vmin/1 var(--placar); color: #fff; background: var(--violeta); box-shadow: var(--sombra); }
.ar-degrau.p1 { height: 46vh; width: 30vmin; background: linear-gradient(180deg, var(--celeste), #1F7FCC 60%, #175E99); color: #2A1060; animation-delay: .55s;
  box-shadow: 0 0 4vmin rgba(79, 179, 255, .55), var(--sombra); z-index: 1; }
.ar-degrau.p1::before { content: "1"; background: var(--texto); color: #2A1060; animation: ar-pop .6s cubic-bezier(.2, 1.6, .4, 1) 1.2s both; }
.ar-degrau.p2 { height: 34vh; background: linear-gradient(180deg, var(--turquesa), #11A08F 60%, #0B6E62); color: #06302C; animation-delay: .25s; }
.ar-degrau.p2::before { content: "2"; background: var(--turquesa); color: #06302C; }
.ar-degrau.p3 { height: 26vh; background: linear-gradient(180deg, var(--violeta), #6A4DE0 60%, #4A33A6); animation-delay: 0s; }
.ar-degrau.p3::before { content: "3"; }
.ar-degrau .ar-nome { margin-top: 3.2vmin; font: 900 3vmin/1.15 var(--placar); white-space: normal; overflow-wrap: anywhere; max-width: 100%; }
.ar-degrau.p1 .ar-nome { font-size: 3.6vmin; }
.ar-degrau .ar-pontos { font: 900 2.6vmin/1 var(--placar); opacity: .9; }
.ar-degrau .ar-pontos::after { content: " pts"; font-size: .6em; }
.ar-degrau:empty, .ar-degrau:not(:has(.ar-nome)) { visibility: hidden; }   /* arena com menos de três: o degrau vazio some sem quebrar o desenho */
.arena-telao[data-fase="podio"] { background:
    radial-gradient(110% 55% at 50% -8%, #4A2AA8 0%, transparent 62%),
    radial-gradient(55% 40% at -5% 35%, rgba(255, 79, 139, .3), transparent 70%),
    radial-gradient(55% 40% at 105% 25%, rgba(31, 214, 193, .26), transparent 70%),
    var(--palco); }
.arena-telao[data-fase="podio"]::before { animation: ar-holofotes 1.4s ease-in-out 3 alternate; }
.ar-confete { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 60; pointer-events: none; }

/* ── CONTROLES do condutor no rodapé do telão: discretos, somem em tela cheia ── */
.arena-telao .ar-controles { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; flex-wrap: wrap; justify-content: center; gap: 1.2vmin;
  padding: 1.4vmin 2vmin; background: linear-gradient(180deg, rgba(20, 10, 46, 0), rgba(20, 10, 46, .92) 40%); opacity: .55; transition: opacity .25s ease; }
.arena-telao .ar-controles:hover, .arena-telao .ar-controles:focus-within { opacity: 1; }
html:fullscreen .arena-telao .ar-controles, .arena-telao:fullscreen .ar-controles, html.ar-tela-cheia .arena-telao .ar-controles { display: none; }
html:fullscreen .arena-telao, .arena-telao:fullscreen { padding-bottom: 2.2vmin; }

/* ── botão da arena (não reaproveita .btn: telão mede em vmin) ── */
.ar-btn { display: inline-flex; align-items: center; justify-content: center; gap: .6em; min-height: 54px; padding: 12px 20px; border: 2px solid var(--linha); border-radius: 16px;
  background: var(--painel); color: var(--texto); font: 800 1.05rem/1.2 var(--corpo); text-decoration: none; cursor: pointer; transition: transform .12s ease, filter .12s ease, background .15s ease; }
.ar-btn:hover { filter: brightness(1.1); }
.ar-btn:active { transform: translateY(2px) scale(.99); }
.ar-btn.primario { background: var(--celeste); color: #2A1060; border-color: var(--celeste); box-shadow: 0 5px 0 #1F7FCC, var(--sombra); }
.ar-btn.perigo { background: transparent; color: var(--errado); border-color: var(--errado); }
.ar-btn:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; transform: none; filter: none; }
.arena-telao .ar-btn { min-height: 5.2vmin; padding: .8vmin 2vmin; font-size: 2vmin; border-radius: 1.4vmin; }
.arena-telao .ar-btn.primario { box-shadow: 0 .5vmin 0 #1F7FCC, var(--sombra); }

/* ═════════ ALUNO (celular, dentro de main.palco.arena-aluno) ═════════ */
.ar-cartao { background: linear-gradient(180deg, var(--painel2), var(--painel)); border: 1px solid var(--linha); border-radius: 22px; padding: 18px 16px; margin: 0 0 14px; box-shadow: var(--sombra); }
.ar-cartao > :first-child { margin-top: 0; } .ar-cartao > :last-child { margin-bottom: 0; }
.ar-entrar { display: grid; gap: 12px; }
.ar-entrar label { font-weight: 700; color: var(--suave); font-size: .92rem; display: grid; gap: 6px; }
.ar-campo { width: 100%; padding: 14px 16px; border-radius: 16px; border: 2px solid var(--linha); background: var(--palco2); color: var(--texto); font: inherit; font-weight: 700; }
.ar-campo::placeholder { color: var(--apagado); font-weight: 500; }
.ar-campo:focus { border-color: var(--celeste); }
.ar-campo[autocapitalize="characters"], .ar-campo[maxlength="4"] { text-transform: uppercase; letter-spacing: .3em; text-align: center; font: 900 1.6rem/1.2 var(--placar); }
.ar-campo[aria-invalid="true"] { border-color: var(--errado); }
.ar-entrar small, .ar-dica { color: var(--suave); font-size: .85rem; }
.ar-erro { margin: 0; padding: 10px 12px; border-radius: 12px; background: rgba(255, 99, 99, .12); border-left: 4px solid var(--errado); color: var(--texto); font-weight: 600; }
.ar-erro:empty { display: none; }
.ar-espera { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 24px 8px; }
.ar-espera .ar-mascote { width: 140px; height: auto; filter: drop-shadow(0 14px 18px rgba(0, 0, 0, .45)); animation: ar-flutua 3.2s ease-in-out infinite; }
.arena-aluno .ar-fala { position: relative; background: var(--texto); color: #1B0F3B; font-weight: 600; padding: 12px 14px; border-radius: 16px; line-height: 1.35; margin: 0; }
.ar-espera .ar-fala::before { content: ""; position: absolute; left: 50%; top: -9px; transform: translateX(-50%); border: 10px solid transparent; border-bottom-color: var(--texto); border-top: 0; }
.ar-espera > p:not(.ar-fala) { color: var(--suave); margin: 0; }
.ar-progresso { margin: 0 0 10px; font: 900 .95rem/1 var(--placar); color: var(--celeste); letter-spacing: .03em; }
.ar-q .ar-enunciado { font-size: 1.12rem; line-height: 1.5; margin: 6px 0 14px; font-weight: 500; }
.ar-q .ar-figura { margin: 0 0 14px; }
.ar-q .ar-figura img { width: 100%; height: auto; border-radius: 14px; background: #fff; display: block; }
.ar-alts { display: grid; gap: 10px; }
.ar-alt { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 12px; min-height: 58px; background: var(--palco2); color: var(--texto);
  border: 2px solid var(--linha); border-radius: 16px; cursor: pointer; font: inherit; font-weight: 600; transition: transform .12s ease, border-color .15s ease, background .15s ease; }
.ar-alt:hover:not(:disabled) { border-color: var(--suave); }
.ar-alt:not(:has(.ar-letra-alt))::before { content: attr(data-letra); flex: 0 0 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; font: 900 1.1rem/1 var(--placar); color: #fff; background: var(--violeta); }
.ar-alt .ar-letra-alt { flex: 0 0 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; font: 900 1.1rem/1 var(--placar); color: #fff; background: var(--violeta); }
.ar-alt[data-letra="A"]::before, .ar-alt[data-letra="A"] .ar-letra-alt { background: var(--rosa); }
.ar-alt[data-letra="B"]::before, .ar-alt[data-letra="B"] .ar-letra-alt { background: var(--turquesa); color: #06302C; }
.ar-alt[data-letra="C"]::before, .ar-alt[data-letra="C"] .ar-letra-alt { background: var(--celeste); color: #2A1060; }
.ar-alt[data-letra="D"]::before, .ar-alt[data-letra="D"] .ar-letra-alt { background: var(--violeta); }
.ar-alt[data-letra="E"]::before, .ar-alt[data-letra="E"] .ar-letra-alt { background: var(--laranja); color: #3A1400; }
.ar-alt.marcada { border-color: var(--celeste); background: #2E1A6B; transform: scale(1.01); box-shadow: 0 0 14px rgba(79, 179, 255, .5); }
.ar-alt.certa { border-color: var(--certo); background: rgba(43, 227, 154, .16); animation: ar-brilho-certo 1s ease; }
.ar-alt.errada { border-color: var(--errado); background: rgba(255, 99, 99, .14); animation: ar-treme .4s ease; }
.ar-alt:disabled { cursor: default; }
.ar-alt:disabled:not(.marcada):not(.certa):not(.errada) { opacity: .6; }
.ar-feedback { margin: 16px 0 0; padding: 14px 16px; border-radius: 16px; font: 900 1.4rem/1.15 var(--placar); text-align: center; animation: ar-pop .5s cubic-bezier(.2, 1.6, .4, 1); }
.ar-feedback.ok { color: var(--certo); background: rgba(43, 227, 154, .12); border: 2px solid rgba(43, 227, 154, .5); text-shadow: 0 0 16px rgba(43, 227, 154, .6); }
.ar-feedback.nao { color: var(--errado); background: rgba(255, 99, 99, .1); border: 2px solid rgba(255, 99, 99, .45); }
.ar-feedback small { display: block; margin-top: 6px; font: 600 .95rem/1.3 var(--corpo); color: var(--texto); }
.ar-selo-chamas { display: inline-flex; align-items: center; gap: 6px; margin: 12px auto 0; padding: 8px 16px; border-radius: 999px; font-weight: 900; font-size: .95rem;
  color: #3A1400; background: linear-gradient(90deg, var(--laranja), #FFB36B); box-shadow: 0 0 18px rgba(255, 138, 61, .65); animation: ar-pop .5s cubic-bezier(.2, 1.6, .4, 1), ar-chamas 1.6s ease-in-out .5s infinite; }
.ar-selo-chamas::before { content: "🔥"; }
.ar-minha-posicao { margin: 14px 0 0; text-align: center; font: 900 1.6rem/1.15 var(--placar); color: var(--texto); }
.ar-minha-posicao small { display: block; font: 700 .9rem/1.3 var(--corpo); color: var(--suave); margin-top: 4px; }
.ar-minha-posicao b { color: var(--celeste); }
.ar-fim { text-align: center; }
.ar-fim .ar-pontos { display: block; font: 900 4rem/1 var(--placar); color: var(--celeste); margin: 8px 0; text-shadow: 0 0 22px rgba(79, 179, 255, .6); }

/* ═════════ NOVA ARENA e CONDUTOR (celular) ═════════ */
.ar-nova { display: grid; gap: 14px; }
.ar-grupo { margin: 0; padding: 12px 14px 14px; border: 1px solid var(--linha); border-radius: var(--raio); background: var(--painel); display: grid; gap: 8px; min-width: 0; }
.ar-grupo legend { padding: 0 6px; font: 900 1rem/1 var(--placar); color: var(--celeste); letter-spacing: .03em; }
.ar-opcao { display: flex; align-items: flex-start; gap: 12px; padding: 12px; border-radius: 14px; border: 2px solid var(--linha); background: var(--palco2); cursor: pointer; transition: border-color .15s ease, background .15s ease; }
.ar-opcao input { appearance: none; flex: 0 0 22px; width: 22px; height: 22px; margin: 2px 0 0; border-radius: 50%; border: 2px solid var(--suave); background: transparent; display: grid; place-items: center; cursor: pointer; }
.ar-opcao input::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: transparent; transition: background .15s ease; }
.ar-opcao input:checked { border-color: var(--celeste); } .ar-opcao input:checked::after { background: var(--celeste); }
.ar-opcao:has(input:checked) { border-color: var(--celeste); background: #2E1A6B; }
.ar-opcao b { display: block; font-weight: 800; } .ar-opcao small { display: block; color: var(--suave); font-size: .85rem; line-height: 1.3; }
.ar-grupo:has(.ar-n) { gap: 6px; }
.ar-n { width: 100%; margin: 6px 0; accent-color: var(--celeste); cursor: pointer; }
.ar-n-valor { display: block; text-align: center; font: 900 1.6rem/1.1 var(--placar); color: var(--celeste); }
.ar-grupo select, .ar-grupo .ar-campo { width: 100%; }
.ar-grupo select { padding: 12px 14px; border-radius: 14px; border: 2px solid var(--linha); background: var(--palco2); color: var(--texto); font: inherit; font-weight: 700; }
.ar-nova .ar-privacidade, .ar-privacidade { margin: 0; color: var(--suave); font-size: .88rem; line-height: 1.4; padding: 10px 12px; border-radius: 12px; background: rgba(31, 214, 193, .08); border: 1px solid rgba(31, 214, 193, .3); }
.ar-condutor { display: grid; gap: 14px; }
.ar-codigo-grande { font: 900 3.2rem/1 var(--placar); letter-spacing: .22em; text-align: center; color: var(--celeste); background: var(--painel); border: 2px dashed var(--linha);
  border-radius: 18px; padding: 18px 8px 18px 14px; margin: 0; text-shadow: 0 0 18px rgba(79, 179, 255, .55); user-select: all; }
.ar-link { display: grid; gap: 8px; }
.ar-link input { width: 100%; padding: 12px 14px; border-radius: 14px; border: 2px solid var(--linha); background: var(--palco2); color: var(--suave); font: inherit; font-size: .92rem; }
.ar-link small { color: var(--suave); font-size: .85rem; }
.ar-condutor .ar-controles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ar-condutor .ar-controles .ar-btn.primario, .ar-condutor .ar-controles .ar-btn.largo { grid-column: 1 / -1; }
.ar-condutor .ar-contagem { margin: 0; font: 900 1.3rem/1.1 var(--placar); color: var(--turquesa); }
.ar-condutor .ar-respostas { display: flex; align-items: center; gap: 12px; font-weight: 700; color: var(--suave); font-size: .92rem; }
.ar-condutor .ar-barra { flex: 1; height: 10px; border-radius: 6px; background: var(--painel2); overflow: hidden; }
.ar-condutor .ar-barra > i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--celeste), var(--turquesa)); transition: width .5s ease; }
.ar-condutor .ar-placar { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.ar-condutor .ar-linha { display: grid; grid-template-columns: 34px 1fr auto auto; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: var(--painel); border: 1px solid var(--linha); font-size: .95rem; }
.ar-condutor .ar-pos { display: grid; place-items: center; height: 34px; border-radius: 10px; background: var(--violeta); font: 900 1rem/1 var(--placar); }
.ar-condutor .ar-linha .ar-pontos { font: 900 1rem/1 var(--placar); color: var(--celeste); }
.ar-condutor .ar-chamas { display: none; font-size: .8rem; color: var(--laranja); font-weight: 800; }
.ar-condutor .ar-linha.em-chamas .ar-chamas { display: inline; }

/* ═════════ ANIMAÇÕES (todas curtas; celebram o acerto, nada pisca à toa) ═════════ */
@keyframes ar-flutua { 50% { transform: translateY(-.7vmin); } }
@keyframes ar-pop { 0% { transform: scale(.4); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes ar-chega { 0% { transform: scale(.3) translateY(1.5vmin); opacity: 0; } 100% { transform: none; opacity: 1; } }
@keyframes ar-acende { 0% { box-shadow: 0 0 2.4vmin rgba(79, 179, 255, .9); border-color: var(--celeste); } 100% { box-shadow: 0 0 0 rgba(79, 179, 255, 0); border-color: var(--linha); } }
@keyframes ar-sobe-leve { 0% { transform: translateY(2vmin); opacity: 0; } 100% { transform: none; opacity: 1; } }
@keyframes ar-sobe { 0% { transform: translateY(120%); opacity: 0; } 60% { transform: translateY(-6%); } 100% { transform: none; opacity: 1; } }
@keyframes ar-desce { 0% { transform: translateY(-60%); opacity: .4; } 100% { transform: none; opacity: 1; } }
@keyframes ar-chamas { 0%, 100% { box-shadow: 0 0 1.2vmin rgba(255, 138, 61, .45); } 50% { box-shadow: 0 0 2.8vmin rgba(255, 79, 139, .75); } }
@keyframes ar-brilho-certo { 30% { box-shadow: 0 0 0 .5vmin rgba(43, 227, 154, .35), 0 0 3.5vmin rgba(43, 227, 154, .65); } }
@keyframes ar-treme { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
@keyframes ar-encolhe { from { transform: scaleX(1); } to { transform: scaleX(0); } }
@keyframes ar-degrau { 0% { transform: scaleY(0); opacity: 0; } 100% { transform: scaleY(1); opacity: 1; } }
@keyframes ar-holofotes { 0% { opacity: .4; transform: rotate(-4deg); } 100% { opacity: 1; transform: rotate(4deg); } }

/* ═════════ SEM ANIMAÇÃO: preferência do sistema ou ajuste do app (html.sem-animacao) ═════════
 * A barra de tempo do telão deixa de encolher (fica cheia): o número de respostas segue informando o condutor. */
@media (prefers-reduced-motion: reduce) {
  .arena-telao, .arena-telao *, .arena-telao *::before, .arena-telao *::after,
  .arena-aluno, .arena-aluno *, .arena-aluno *::before, .arena-aluno *::after,
  .ar-nova *, .ar-condutor * { animation: none !important; transition: none !important; }
}
html.sem-animacao .arena-telao, html.sem-animacao .arena-telao *, html.sem-animacao .arena-telao *::before, html.sem-animacao .arena-telao *::after,
html.sem-animacao .arena-aluno, html.sem-animacao .arena-aluno *, html.sem-animacao .arena-aluno *::before, html.sem-animacao .arena-aluno *::after,
html.sem-animacao .ar-nova *, html.sem-animacao .ar-condutor * { animation: none !important; transition: none !important; }
html.sem-animacao .ar-confete, .arena-telao .ar-confete.desligado { display: none; }

/* ═════════ TELÃO em tela estreita (ensaio no celular ou janela pequena): uma coluna ═════════ */
@media (max-aspect-ratio: 4/3) {
  .ar-saguao { grid-template-columns: 1fr; grid-template-rows: auto auto auto; }
  .ar-regras { columns: 1; }
  .ar-alternativas, .ar-pergunta:has(.ar-figura img) { grid-template-columns: 1fr; }
  .ar-placar:has(> :nth-child(6)) { grid-template-columns: 1fr; }
  .ar-degrau { width: 22vmin; } .ar-degrau.p1 { width: 26vmin; }
}

/* ── ajuste de engenharia (Opus, 22/10/2026): as regras do placar no CELULAR (aluno e nova arena) vinham com o corpo do
   telão (1,9 vmin ≈ 7 px num celular) — ilegíveis. Aqui elas voltam ao corpo do app, numa coluna. ── */
.arena-aluno .ar-regras, .ar-nova .ar-regras { columns: 1; font-size: 1rem; line-height: 1.45; padding-left: 1.4em; color: var(--texto); }
.arena-aluno .ar-regras li, .ar-nova .ar-regras li { margin: .45em 0; }
