/* Quiz do Retiro Vem e Veja: papel kraft, fita adesiva, bússola e trilha pontilhada.
   Fontes (SIL OFL): Bebas Neue (títulos), Caveat (manuscrito) e DM Sans (texto). */
@font-face { font-family: 'Display'; src: url('/fonts/display.woff2') format('woff2'); font-display: swap; }
@font-face { font-family: 'Hand'; src: url('/fonts/hand.woff2') format('woff2'); font-display: swap; }
@font-face { font-family: 'Body'; src: url('/fonts/body.woff2') format('woff2'); font-weight: 400 800; font-display: swap; }

/* Tema claro: kraft. O tema escuro (principal) fica no fim do arquivo. */
:root {
  --bg: #e6d1ab;
  --bg-2: #dcc398;
  --card: #f6ecd9;
  --surface: #fbf4e6;
  --field: #fffaf0;
  --ink: #2a2016;
  --muted: #6b5640;
  --line: #d3bb93;
  --borda: #8a6a44;
  --peach: #F2B27A;
  --peach-forte: #e8914f;
  --peach-ink: #9a4f1c;
  --kraft: #cfa46c;
  --creme: #f4ebda;
  --marrom: #2a2016;
  --on-peach: #2a1d0f;
  --sombra-btn: #7a5530;
  --ok: #2f7d43;
  --ok-soft: #dcecd2;
  --ok-ink: #24622f;
  --bad: #b8432c;
  --bad-soft: #f6d8cc;
  --bad-ink: #93311d;
  --warn-soft: #f7e2c0;
  --warn-ink: #6b4415;
  --toast-bg: #2a2016;
  --toast-ink: #f4ebda;
  --contagem-bg: #2a2016;
  --contagem-ink: #f4ebda;
  --contagem-forte: #F2B27A;
  --mapa: #8a6a44;
  --grao-op: .16;
  --sombra-card: 0 2px 0 rgba(90, 60, 30, .18), 0 10px 24px rgba(90, 60, 30, .14);
  --fx-sombra: #f6ecd9;
  --radius: 6px;
  color-scheme: light dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: 'Body', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: var(--ink);
  background-color: var(--bg);
  background-image: radial-gradient(ellipse at 50% 18%, var(--bg-2), transparent 62%), linear-gradient(110deg, var(--bg), var(--bg-2));
  background-attachment: fixed;
  min-height: 100vh;
  -webkit-tap-highlight-color: transparent;
  padding-top: calc(var(--faixa-h) + 14px + env(safe-area-inset-top));
}
/* granulado de papel por cima de tudo (não pega toque) */
body::after {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 90; opacity: var(--grao-op); mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .25 0 0 0 0 .18 0 0 0 0 .1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23g)'/%3E%3C/svg%3E");
}
.fundo-mapa { position: fixed; right: -120px; bottom: -90px; width: 520px; height: 520px; pointer-events: none; z-index: 0; opacity: .22; transform: rotate(-12deg); }
.fundo-mapa path { fill: none; stroke: var(--mapa); stroke-width: 1.4; }
.fundo-mapa .trilha { stroke-width: 3; stroke-dasharray: 2 10; stroke-linecap: round; opacity: .9; }

.app {
  position: relative; z-index: 1;
  max-width: 480px;
  margin: 0 auto;
  padding: 14px 16px calc(24px + env(safe-area-inset-bottom));
  min-height: calc(100vh - var(--faixa-h) - 14px - env(safe-area-inset-top));
  display: flex; flex-direction: column;
}
.loading { margin: auto; color: var(--muted); font-weight: 700; }
h1, h2, h3 { margin: 0; line-height: 1.1; font-weight: 400; }
h1, h2 { font-family: 'Display', Impact, sans-serif; letter-spacing: .02em; }
h1 { font-size: 2.4rem; }
h2 { font-size: 1.9rem; }
h3 { font-size: .8rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
p { line-height: 1.5; }
.muted { color: var(--muted); }
.center { text-align: center; }
.mao { font-family: 'Hand', 'Comic Sans MS', cursive; font-size: 1.45rem; line-height: 1.1; color: var(--muted); }

/* ---------- contagem regressiva (centralizada) ---------- */
:root { --faixa-h: 112px; }
.contagem {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  padding: calc(env(safe-area-inset-top) + 6px) max(12px, env(safe-area-inset-right)) 8px max(12px, env(safe-area-inset-left));
  min-height: calc(var(--faixa-h) + env(safe-area-inset-top));
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  text-align: center;
  background: var(--contagem-bg); color: var(--contagem-ink);
  line-height: 1.1;
  box-shadow: 0 2px 0 rgba(0,0,0,.25);
}
.contagem[hidden] { display: none; }
/* borda de baixo pontilhada, como trilha */
.contagem::after { content: ''; position: absolute; left: 0; right: 0; bottom: -7px; height: 3px;
  background: repeating-linear-gradient(90deg, var(--contagem-forte) 0 6px, transparent 6px 14px); opacity: .8; }
.cont-topo { display: flex; align-items: center; justify-content: center; gap: 6px; }
.cont-bussola { flex: none; width: 18px; height: 18px; fill: none; stroke: var(--contagem-forte); stroke-width: 2; }
.cont-bussola path { fill: var(--contagem-forte); stroke: none; transform-origin: 12px 12px; animation: agulha 6s ease-in-out infinite; }
.cont-titulo { font-size: .72rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.cont-blocos { display: flex; align-items: flex-start; justify-content: center; gap: 4px; }
.cont-blocos i { font-style: normal; font-family: 'Display', sans-serif; font-size: 1.7rem; line-height: 1; padding-top: 2px; color: var(--contagem-forte); opacity: .7; }
.cont-bloco { display: flex; flex-direction: column; align-items: center; min-width: 52px; }
.cont-bloco b { font-family: 'Display', sans-serif; font-weight: 400; font-size: 2.1rem; line-height: 1; letter-spacing: .02em;
  font-variant-numeric: tabular-nums; color: var(--contagem-forte); }
.cont-bloco small { font-size: .62rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; opacity: .75; margin-top: 1px; }
.cont-txt { display: none; font-family: 'Display', sans-serif; font-size: 1.8rem; letter-spacing: .03em; color: var(--contagem-forte); }
.contagem[data-fase='durante'] .cont-blocos, .contagem[data-fase='depois'] .cont-blocos,
.contagem[data-fase='durante'] .cont-topo, .contagem[data-fase='depois'] .cont-topo { display: none; }
.contagem[data-fase='durante'] .cont-txt, .contagem[data-fase='depois'] .cont-txt { display: block; }
.cont-data { font-family: 'Hand', cursive; font-size: 1.05rem; line-height: 1; opacity: .9; }
@media (max-width: 340px) { .cont-bloco { min-width: 44px; } .cont-bloco b { font-size: 1.8rem; } }
@media (prefers-reduced-motion: reduce) { .cont-bussola path { animation: none; } }
@keyframes agulha { 0%, 100% { transform: rotate(-14deg); } 50% { transform: rotate(16deg); } }

/* ---------- logo e títulos ---------- */
.logo-wrap { display: flex; justify-content: center; padding: 10px 0 2px; }
.logo-wrap picture { display: flex; justify-content: center; width: 100%; }
.logo { width: 100%; max-width: 310px; height: auto; }
.logo.small { max-width: 190px; }
.titulo-quiz { margin: 4px 0 4px; }
.etiqueta-rasgada {
  display: inline-block; background: var(--peach); color: var(--on-peach);
  font-family: 'Display', Impact, sans-serif; font-size: 1.35rem; letter-spacing: .08em; padding: 6px 20px 3px;
  transform: rotate(-1.5deg);
  clip-path: polygon(1% 12%, 10% 3%, 21% 8%, 38% 0, 62% 7%, 78% 2%, 98% 5%, 100% 86%, 82% 99%, 63% 94%, 45% 100%, 29% 94%, 10% 100%, 0 86%);
}

/* ---------- cartões: papel kraft com fita adesiva ---------- */
.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--borda);
  border-radius: var(--radius);
  padding: 20px 18px;
  margin-top: 18px;
  box-shadow: var(--sombra-card);
}
.card::before {
  content: ''; position: absolute; top: -11px; left: 50%; width: 84px; height: 22px; transform: translateX(-50%) rotate(-3deg);
  background: var(--kraft); opacity: .82;
  clip-path: polygon(3% 0, 97% 6%, 95% 50%, 100% 100%, 2% 94%, 5% 48%);
}
.card:nth-of-type(even)::before { transform: translateX(-50%) rotate(4deg); left: 42%; }

.topbar { display: flex; align-items: center; gap: 10px; }
.topbar img { width: 46px; height: 46px; flex: none; object-fit: contain; }
.topbar .who { flex: 1; min-width: 0; }
.topbar .who b { display: block; font-family: 'Display', Impact, sans-serif; font-weight: 400; font-size: 1.55rem; letter-spacing: .03em; line-height: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .who span { font-size: .85rem; color: var(--muted); }
.icon-btn {
  flex: none; min-width: 48px; height: 44px; padding: 0 12px; border: 1px solid var(--borda); border-radius: var(--radius);
  background: var(--surface); color: var(--ink); font: inherit; font-weight: 800; font-size: .92rem; cursor: pointer;
  box-shadow: 0 3px 0 var(--sombra-btn);
}
.icon-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--sombra-btn); }

.btn {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 54px;
  border: 1px solid transparent; border-radius: var(--radius); padding: 12px 18px;
  font: inherit; font-size: .95rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; cursor: pointer;
  transition: transform .08s, box-shadow .08s;
}
.btn:disabled { opacity: .6; cursor: default; }
.btn-primary, .btn-yellow { background: var(--peach); color: var(--on-peach); border-color: var(--sombra-btn); box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 5px 0 var(--sombra-btn); margin-bottom: 5px; }
.btn-primary:active, .btn-yellow:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--sombra-btn); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px dashed var(--borda); text-transform: none; letter-spacing: .02em; font-size: 1rem; }
.btn-ghost:active { background: var(--surface); }
.btn-small { min-height: 44px; font-size: .9rem; padding: 8px 12px; width: auto; }
.btn-danger { background: var(--bad-soft); color: var(--bad-ink); border-color: var(--bad); text-transform: none; letter-spacing: .02em; }
.stack > * + * { margin-top: 12px; }

/* ---------- formulários ---------- */
.tabs { display: flex; background: var(--bg-2); border-radius: var(--radius); padding: 4px; gap: 4px; border: 1px solid var(--line); }
.tab {
  flex: 1; min-height: 44px; border: 0; border-radius: 4px; background: transparent; color: var(--muted); cursor: pointer;
  font: inherit; font-weight: 800; min-width: 0; padding: 0 4px; font-size: clamp(.82rem, 3.7vw, .98rem); white-space: nowrap;
}
.tab.active { background: var(--peach); color: var(--on-peach); box-shadow: 0 2px 0 var(--sombra-btn); }
label { display: block; font-weight: 800; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 6px; color: var(--muted); }
.field + .field { margin-top: 14px; }
input[type=text], input[type=password] {
  width: 100%; min-height: 52px; padding: 12px 14px; border: 1px solid var(--borda); border-radius: var(--radius);
  background: var(--field); font: inherit; font-size: 1.05rem; color: var(--ink);
}
input:focus { outline: none; border-color: var(--peach-forte); box-shadow: 0 0 0 3px color-mix(in srgb, var(--peach) 45%, transparent); }
.hint { font-size: .82rem; color: var(--muted); margin-top: 4px; }
.error { color: var(--bad); font-weight: 700; min-height: 1.2em; margin: 10px 0 0; font-size: .95rem; }
.divider { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: .85rem; margin: 18px 0 14px; }
.divider::before, .divider::after { content: ''; flex: 1; border-top: 1px dashed var(--line); }
.google-box { display: flex; justify-content: center; min-height: 44px; }
.aviso { background: var(--warn-soft); border: 1px dashed var(--borda); border-radius: var(--radius); padding: 10px 12px; font-size: .88rem; line-height: 1.4; margin-bottom: 14px; color: var(--warn-ink); }
input.invalido { border-color: var(--bad) !important; background: var(--bad-soft); }
input.valido { border-color: var(--ok) !important; }
.hint.hint-erro { color: var(--bad); font-weight: 700; }

/* ---------- início ---------- */
.hero { text-align: center; padding: 26px 18px 22px; background: var(--marrom); color: var(--creme); border-color: #000; overflow: hidden; }
.hero::before { display: none; }
.hero h2 { font-size: 2.3rem; color: var(--peach); }
.hero p { margin: 6px 0 16px; color: #e3d3b8; }
.hero-mao { display: block; color: var(--creme); font-size: 1.5rem; transform: rotate(-3deg); margin-bottom: 2px; }
/* fita adesiva em X no canto */
.fita-x { position: absolute; top: -14px; left: -16px; width: 60px; height: 60px; pointer-events: none; }
.fita-x::before, .fita-x::after { content: ''; position: absolute; left: 0; top: 22px; width: 60px; height: 15px; background: var(--kraft); opacity: .85;
  clip-path: polygon(2% 0, 98% 8%, 96% 50%, 100% 100%, 1% 92%, 4% 50%); }
.fita-x::before { transform: rotate(-38deg); }
.fita-x::after { transform: rotate(38deg); }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.stat { background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); padding: 10px 8px; text-align: center; }
.stat b { display: block; font-family: 'Display', Impact, sans-serif; font-weight: 400; font-size: 1.9rem; line-height: 1.05; letter-spacing: .02em; }
.stat span { font-size: .78rem; color: var(--muted); font-weight: 700; }
.stat.ok b { color: var(--ok); }
.stat.bad b { color: var(--bad); }
.stat.combo b { color: var(--peach-ink); }
.stat.tempo b { font-family: 'Body', system-ui, sans-serif; font-weight: 800; font-size: 1.45rem; line-height: 1.3; letter-spacing: 0; }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; }

/* ---------- rodada ---------- */
.quiz-head { display: flex; align-items: center; gap: 10px; }
.quiz-head .count { font-family: 'Display', Impact, sans-serif; font-size: 1.5rem; min-width: 46px; text-align: right; }
.progress { flex: 1; height: 12px; background: var(--surface); border-radius: 99px; overflow: hidden; border: 1px solid var(--borda); }
.progress > div { height: 100%; border-radius: 99px; transition: width .35s ease;
  background: repeating-linear-gradient(90deg, var(--peach) 0 10px, var(--peach-forte) 10px 14px); }
.score-pill { display: inline-block; background: var(--surface); border: 1px dashed var(--borda); border-radius: 99px; padding: 3px 12px; font-weight: 800; font-size: .9rem; }
.question { font-size: 1.28rem; font-weight: 800; line-height: 1.32; margin: 6px 0 0; }
.options { display: grid; gap: 12px; margin-top: 18px; }
.option {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 58px; padding: 10px 14px;
  border: 1px solid var(--borda); border-radius: var(--radius); background: var(--surface); color: var(--ink);
  font: inherit; font-size: 1.04rem; font-weight: 700; text-align: left; cursor: pointer;
  box-shadow: 0 3px 0 var(--sombra-btn); transition: background-color .2s, border-color .2s;
}
.option:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--sombra-btn); }
.option .letter {
  flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: var(--peach); color: var(--on-peach); font-family: 'Display', Impact, sans-serif; font-size: 1.2rem; border: 1px solid var(--sombra-btn);
}
.option.correct { background: var(--ok-soft); border-color: var(--ok); box-shadow: 0 3px 0 var(--ok); }
.option.correct .letter { background: var(--ok); color: #fff; border-color: var(--ok); }
.option.wrong { background: var(--bad-soft); border-color: var(--bad); box-shadow: 0 3px 0 var(--bad); }
.option.wrong .letter { background: var(--bad); color: #fff; border-color: var(--bad); }
.option:disabled { cursor: default; }
.option.dim { opacity: .5; }
.feedback { margin-top: 16px; border-radius: var(--radius); padding: 14px 16px; border: 1px dashed; animation: pop .25s ease; }
.feedback.ok { background: var(--ok-soft); border-color: var(--ok); }
.feedback.bad { background: var(--bad-soft); border-color: var(--bad); }
.feedback b { font-size: 1.12rem; display: block; }
.feedback .ref { display: inline-block; margin-top: 8px; font-weight: 800; background: var(--card); border-radius: 4px; padding: 2px 8px; font-size: .88rem; }
.q-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.nivel { display: inline-block; border-radius: 3px; padding: 3px 10px 2px; font-family: 'Display', Impact, sans-serif; font-size: 1rem; letter-spacing: .08em; transform: rotate(-2deg); }
.nivel-facil { background: var(--ok-soft); color: var(--ok-ink); }
.nivel-media { background: var(--warn-soft); color: var(--warn-ink); }
.nivel-dificil { background: var(--bad-soft); color: var(--bad-ink); }
@keyframes pop { from { transform: scale(.96); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* ---------- resultado: crachá ---------- */
.big-score { font-family: 'Display', Impact, sans-serif; font-size: 4rem; color: var(--peach-ink); line-height: 1; letter-spacing: .02em; }
.medal { font-size: 3rem; line-height: 1; }
.cracha { padding-top: 34px; }
.cracha::before { display: none; }
.ilhos { position: absolute; top: 12px; left: 50%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; background: var(--bg); border: 3px solid var(--kraft); box-shadow: 0 0 0 2px var(--marrom); }
.resultado .mao { font-size: 1.6rem; color: var(--ink); }

/* ---------- ranking ---------- */
.tabs-rank { flex-wrap: wrap; }
.tabs-rank .tab { flex: 1 1 30%; }
.rank-list { list-style: none; padding: 0; margin: 14px 0 0; }
.rank-list li { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px dashed var(--line); }
.rank-list li:last-child { border-bottom: 0; }
.rank-list li.me { background: color-mix(in srgb, var(--peach) 28%, transparent); border-radius: var(--radius); padding-left: 10px; padding-right: 10px; }
.pos { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-family: 'Display', Impact, sans-serif; font-size: 1.25rem; background: var(--surface); border: 1px solid var(--line); }
.pos.p1 { background: #f2c27a; color: #2a1d0f; border-color: #8a5d24; }
.pos.p2 { background: #e3dccf; color: #2a1d0f; border-color: #8c8270; }
.pos.p3 { background: #c98e5b; color: #2a1d0f; border-color: #7a4a22; }
.rank-name { flex: 1; min-width: 0; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-val { font-weight: 800; text-align: right; }
.rank-val .rank-sub { display: block; font-size: .75rem; font-weight: 700; color: var(--muted); text-align: right; }
.my-pos { margin-top: 12px; padding: 12px; background: var(--surface); border: 1px dashed var(--borda); border-radius: var(--radius); font-weight: 700; text-align: center; }

/* ---------- admin ---------- */
.user-row { padding: 14px 0; border-bottom: 1px dashed var(--line); }
.user-row:last-child { border-bottom: 0; }
.user-row .top { display: flex; align-items: center; gap: 12px; }
.user-row .meta { font-size: .85rem; color: var(--muted); margin-top: 2px; }
.user-row .actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.tag { font-size: .72rem; font-weight: 800; background: var(--peach); color: var(--on-peach); border-radius: 3px; padding: 2px 6px; margin-left: 6px; vertical-align: middle; }

.toast {
  position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%) translateY(calc(100% + 40px)); visibility: hidden;
  background: var(--toast-bg); color: var(--toast-ink); padding: 12px 18px; border-radius: var(--radius); font-weight: 700;
  max-width: calc(100% - 32px); z-index: 80; transition: transform .25s ease; box-shadow: 0 8px 30px rgba(0,0,0,.3);
}
.toast.show { transform: translateX(-50%) translateY(0); visibility: visible; }
footer { margin-top: auto; padding-top: 24px; text-align: center; font-size: .72rem; letter-spacing: .08em; color: var(--muted); display: flex; flex-direction: column; gap: 3px; }
footer .rodape-linha { text-wrap: balance; }

/* ---------- modal (instalar) ---------- */
.modal { position: fixed; inset: 0; background: rgba(20, 15, 9, .7); display: flex; align-items: flex-end; justify-content: center; padding: 16px; z-index: 60; }
.modal-card { width: 100%; max-width: 448px; margin: 0 0 env(safe-area-inset-bottom); }
.modal-card ol { margin: 0; padding-left: 22px; line-height: 1.5; }
.modal-card p { margin: 0; }

/* ---------- efeitos da rodada: acerto, erro e combo ---------- */
.option.correct.pop { animation: pop-certo .5s cubic-bezier(.3, 1.6, .5, 1); }
.option.wrong.treme { animation: treme .45s cubic-bezier(.36, .07, .19, .97); }
@keyframes pop-certo { 0% { transform: scale(1); } 35% { transform: scale(1.07); } 60% { transform: scale(.97); } 80% { transform: scale(1.02); } 100% { transform: scale(1); } }
@keyframes treme { 0%,100% { transform: translateX(0); } 15% { transform: translateX(-9px) rotate(-1deg); } 30% { transform: translateX(8px) rotate(1deg); } 45% { transform: translateX(-6px); } 60% { transform: translateX(5px); } 75% { transform: translateX(-3px); } }

.fx-camada { position: fixed; inset: 0; pointer-events: none; z-index: 70; overflow: hidden; }
.fx-pontos { position: absolute; transform: translate(-50%, -50%); font-family: 'Display', Impact, sans-serif; font-size: 1.8rem; letter-spacing: .03em; color: var(--ok);
  text-shadow: 0 2px 0 var(--fx-sombra), 0 0 12px var(--fx-sombra); white-space: nowrap; animation: flutua 1s ease-out forwards; }
@keyframes flutua { 0% { opacity: 0; transform: translate(-50%, -20%) scale(.6); } 20% { opacity: 1; transform: translate(-50%, -70%) scale(1.15); } 100% { opacity: 0; transform: translate(-50%, -260%) scale(1); } }
.fx-faisca { position: absolute; width: 8px; height: 8px; border-radius: 2px; opacity: 0; animation: faisca .75s ease-out forwards; }
.fx-faisca.estrela { width: 10px; height: 10px; clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); border-radius: 0; }
@keyframes faisca { 0% { opacity: 1; transform: translate(0, 0) scale(.4) rotate(0); } 70% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(1) rotate(200deg); } }

.placar { display: flex; align-items: center; gap: 8px; min-width: 0; }
.combo-pill { position: relative; display: inline-flex; align-items: center; border-radius: 99px; padding: 4px 11px; font-weight: 800; font-size: .9rem;
  background: linear-gradient(135deg, #F2B27A, #e07a3c); color: #2a1d0f; border: 1px solid #8a4f22; box-shadow: 0 3px 10px rgba(224,122,60,.35); visibility: hidden; }
.combo-pill.ativo { visibility: visible; }
.combo-pill.quente { background: linear-gradient(135deg, #f0a35a, #c8502a); color: #fff8ec; box-shadow: 0 0 14px rgba(224,122,60,.6); }
.combo-pill.sobe { animation: combo-sobe .55s cubic-bezier(.3, 1.7, .5, 1); }
@keyframes combo-sobe { 0% { transform: scale(1); filter: brightness(1); } 40% { transform: scale(1.35); filter: brightness(1.25) drop-shadow(0 0 8px #F2B27A); } 100% { transform: scale(1); filter: brightness(1); } }
.combo-pill .invisivel { visibility: hidden; }
.combo-pill.quebra { background: transparent; box-shadow: none; border-color: transparent; }
.combo-pill .metade { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; border-radius: 99px;
  background: linear-gradient(135deg, #a8977f, #7a6a55); color: #fff; }
.combo-pill .metade.e { clip-path: polygon(0 0, 55% 0, 45% 30%, 58% 55%, 44% 78%, 52% 100%, 0 100%); }
.combo-pill .metade.d { clip-path: polygon(55% 0, 100% 0, 100% 100%, 52% 100%, 44% 78%, 58% 55%, 45% 30%); }
.combo-pill.quebra .metade.e { animation: racha-e .85s ease-in forwards; }
.combo-pill.quebra .metade.d { animation: racha-d .85s ease-in forwards; }
@keyframes racha-e { 0%,20% { transform: none; opacity: 1; } 30% { transform: translateX(-2px) rotate(-4deg); } 100% { transform: translate(-14px, 46px) rotate(-38deg); opacity: 0; } }
@keyframes racha-d { 0%,20% { transform: none; opacity: 1; } 30% { transform: translateX(2px) rotate(4deg); } 100% { transform: translate(14px, 52px) rotate(42deg); opacity: 0; } }

.combo-banner { position: fixed; left: 50%; top: 20%; z-index: 75; transform: translateX(-50%); pointer-events: none;
  display: flex; align-items: center; gap: 8px; padding: 10px 26px 6px; white-space: nowrap;
  background: var(--peach); color: #2a1d0f; font-family: 'Display', Impact, sans-serif; font-size: 2rem; letter-spacing: .06em;
  clip-path: polygon(1% 12%, 10% 3%, 21% 8%, 38% 0, 62% 7%, 78% 2%, 98% 5%, 100% 86%, 82% 99%, 63% 94%, 45% 100%, 29% 94%, 10% 100%, 0 86%);
  filter: drop-shadow(0 8px 18px rgba(0,0,0,.35));
  animation: banner 1.8s cubic-bezier(.3, 1.4, .5, 1) forwards; }
.combo-banner b { font-weight: 400; }
@keyframes banner { 0% { opacity: 0; transform: translateX(-50%) scale(.4) rotate(-6deg); } 15% { opacity: 1; transform: translateX(-50%) scale(1.1) rotate(1deg); }
  25% { transform: translateX(-50%) scale(1) rotate(-2deg); } 80% { opacity: 1; transform: translateX(-50%) scale(1) rotate(-2deg); } 100% { opacity: 0; transform: translateX(-50%) translateY(-24px) scale(.95); } }

.combo-perdido { margin-top: 4px; font-weight: 800; color: var(--bad-ink); }
.combo-recorde { margin-top: 4px; font-weight: 800; color: var(--peach-ink); }
.som-btn { font-size: 1.1rem; min-width: 44px; padding: 0 8px; }
.res-combo { display: flex; flex-direction: column; align-items: center; gap: 2px; background: var(--surface); border: 1px dashed var(--borda); border-radius: var(--radius); padding: 10px 14px; font-weight: 700; color: var(--muted); font-size: .9rem; }
.res-combo-num { font-family: 'Display', Impact, sans-serif; font-size: 2rem; color: var(--peach-ink); line-height: 1.05; }

/* ---------- confete (pêssego e creme) ---------- */
.confete { position: fixed; inset: 0; pointer-events: none; z-index: 72; overflow: hidden; }
.confete i { position: absolute; top: -20px; width: 9px; height: 13px; border-radius: 1px; animation-name: cai; animation-timing-function: cubic-bezier(.3, .6, .6, 1); animation-fill-mode: both; }
.confete i.fita { width: 5px; height: 20px; }
@keyframes cai { from { transform: translate(0, -20px) rotate(0); opacity: 1; } to { transform: translate(var(--desvio), 105vh) rotate(var(--giro)); opacity: .85; } }

@media (prefers-reduced-motion: reduce) {
  .option.correct.pop, .option.wrong.treme, .combo-pill.sobe, .combo-pill.quebra .metade.e, .combo-pill.quebra .metade.d, .cont-bussola path, .feedback { animation: none !important; }
  .combo-pill.quebra .metade { opacity: .55; }
  .combo-banner { animation: banner-cor 1.8s linear forwards; transform: translateX(-50%) rotate(-2deg); }
  .fx-camada, .confete { display: none; }
  .progress > div { transition: none; }
}
@keyframes banner-cor { 0%, 85% { opacity: 1; } 100% { opacity: 0; } }

/* ---------- tema escuro (o principal do retiro): marrom com granulado ---------- */
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #201a12;
    --bg-2: #2a2016;
    --card: #2b2218;
    --surface: #352a1d;
    --field: #1a150e;
    --ink: #f4ebda;
    --muted: #c1ab8b;
    --line: #4d3d2a;
    --borda: #75593a;
    --peach-ink: #F2B27A;
    --marrom: #15110b;
    --sombra-btn: #6e4d2b;
    --ok: #7fc98f;
    --ok-soft: #22351f;
    --ok-ink: #a6dcae;
    --bad: #e27a62;
    --bad-soft: #3d1f17;
    --bad-ink: #f0a28f;
    --warn-soft: #3a2c1a;
    --warn-ink: #f2cf9c;
    --toast-bg: #eed4aa;
    --toast-ink: #2a1d0f;
    --contagem-bg: #F2B27A;
    --contagem-ink: #2a1d0f;
    --contagem-forte: #2a1d0f;
    --mapa: #d2ae78;
    --grao-op: .09;
    --sombra-card: 0 18px 40px rgba(0,0,0,.35), inset 0 0 50px rgba(0,0,0,.25);
    --fx-sombra: #201a12;
  }
  body { background-image: radial-gradient(ellipse at 52% 22%, #51402540, transparent 60%), linear-gradient(110deg, #241d13, #1a170f); }
  body::after { mix-blend-mode: screen; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .95 0 0 0 0 .85 0 0 0 0 .7 0 0 0 .8 0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23g)'/%3E%3C/svg%3E"); }
  .card { background-image: radial-gradient(ellipse at 0 100%, rgba(190,145,91,.12), transparent 55%); }
  .hero { background: #15110b; border-color: #5e4730; }
  .option.correct .letter, .option.wrong .letter { color: #1a150e; }
  .contagem { box-shadow: 0 2px 0 rgba(0,0,0,.4); }
  .contagem::after { background: repeating-linear-gradient(90deg, #F2B27A 0 6px, transparent 6px 14px); }
}

/* ---------- popup do versículo do tema ---------- */
.modal-versiculo { align-items: center; animation: vers-fundo .25s ease both; }
.modal-versiculo.saindo { animation: vers-fundo .2s ease reverse both; }
.vers-card { position: relative; width: 100%; max-width: 420px; text-align: center; padding: 30px 22px 18px;
  display: flex; flex-direction: column; align-items: center; gap: 8px; animation: vers-entra .35s cubic-bezier(.2,1.3,.4,1) both; }
.modal-versiculo.saindo .vers-card { animation: vers-entra .2s ease reverse both; }
.vers-fita { position: absolute; top: -14px; left: 50%; width: 120px; height: 30px; transform: translateX(-50%) rotate(-3deg);
  background: var(--kraft); opacity: .85; clip-path: polygon(3% 0, 97% 8%, 100% 92%, 0 100%); }
.vers-x { position: absolute; top: 8px; right: 8px; width: 38px; height: 38px; border-radius: 50%; border: 0;
  background: transparent; color: inherit; font-size: 1.1rem; opacity: .7; }
.vers-mao { font-size: 1.35rem; margin-top: 4px; }
.vers-tema { font-family: 'Display', sans-serif; font-weight: 400; font-size: 2.6rem; line-height: 1; letter-spacing: .03em; margin: 0;
  color: var(--peach-ink); }
.vers-texto { margin: 6px 0 0; font-size: 1.08rem; line-height: 1.5; }
.vers-texto p { margin: 0; }
.vers-texto b { color: var(--peach-ink); }
.vers-ref { font-style: normal; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; font-size: .78rem; opacity: .85; }
.vers-convite { margin: 6px 0 8px; font-size: .95rem; line-height: 1.45; opacity: .9; }
.vers-card .btn { width: 100%; }
.vers-fonte { font-size: .66rem; opacity: .55; margin-top: 2px; }
@keyframes vers-fundo { from { opacity: 0; } to { opacity: 1; } }
@keyframes vers-entra { from { opacity: 0; transform: translateY(24px) scale(.94); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .modal-versiculo, .vers-card { animation: none !important; } }

/* ---------- desafio extra: Leia o Evangelho de João (crachá kraft) ---------- */
.desafio { text-align: center; padding: 34px 18px 18px; background-image: repeating-linear-gradient(0deg, transparent 0 27px, color-mix(in srgb, var(--line) 55%, transparent) 27px 28px); }
.desafio::after { content: ''; position: absolute; inset: 7px; border: 1px dashed var(--borda); border-radius: 4px; opacity: .5; pointer-events: none; }
.desafio > :not(.ilhos) { position: relative; }
.desafio-mao { display: block; font-size: 1.4rem; transform: rotate(-2deg); color: var(--peach-ink); }
.desafio-titulo { font-size: 1.85rem; line-height: 1.02; margin: 4px 0 0; text-wrap: balance; }
.desafio-convite { margin: 8px 0 14px; font-size: .95rem; color: var(--muted); text-wrap: pretty; }
.desafio-prog { display: flex; align-items: center; gap: 10px; }
.desafio-trilho { flex: 1; height: 14px; background: var(--surface); border: 1px solid var(--borda); border-radius: 99px; overflow: hidden; }
.desafio-trilho > div { height: 100%; min-width: 0; border-radius: 99px; transition: width .5s ease;
  background: repeating-linear-gradient(90deg, var(--peach) 0 10px, var(--peach-forte) 10px 14px); }
.desafio-num { flex: none; font-family: 'Display', Impact, sans-serif; font-size: 1.6rem; line-height: 1; letter-spacing: .02em; }
.desafio-num small { font-family: 'Body', system-ui, sans-serif; font-size: .72rem; font-weight: 800; color: var(--muted); letter-spacing: .04em; }
.desafio-meta { margin: 8px 0 14px; font-weight: 800; font-size: .92rem; color: var(--peach-ink); }
.desafio-meta.ok { color: var(--ok); }
.desafio .btn-ghost.desafio-lista { margin-top: 8px; min-height: 46px; }
.desafio.completo .desafio-trilho > div { background: var(--ok); }

/* lista de capítulos */
.grade-caps { display: grid; grid-template-columns: repeat(auto-fill, minmax(56px, 1fr)); gap: 8px; }
.cap-btn { position: relative; min-height: 52px; border: 1px solid var(--borda); border-radius: var(--radius); background: var(--surface); color: var(--ink);
  font-family: 'Display', Impact, sans-serif; font-size: 1.45rem; cursor: pointer; box-shadow: 0 3px 0 var(--sombra-btn); }
.cap-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--sombra-btn); }
.cap-btn.comecou { border-color: var(--peach-forte); background: var(--warn-soft); }
.cap-btn.lido { border-color: var(--ok); background: var(--ok-soft); color: var(--ok-ink); box-shadow: 0 3px 0 var(--ok); }
.cap-btn .check { position: absolute; top: 2px; right: 5px; font-family: 'Body', system-ui, sans-serif; font-size: .78rem; font-weight: 800; }
.cap-btn.bloqueado { opacity: .55; border-style: dashed; box-shadow: none; }
.cap-btn.quiz { border-color: var(--peach-forte); background: var(--warn-soft); box-shadow: 0 3px 0 var(--peach-forte); }

/* quiz de cada capítulo */
.desafio-regra { margin: -6px 0 14px; font-size: .86rem; font-weight: 700; color: var(--muted, var(--ink)); opacity: .85; }
.quiz-cap-box { display: grid; gap: 8px; margin-top: 18px; padding: 14px 16px; border: 1px dashed var(--peach-forte); border-radius: var(--radius); background: var(--warn-soft); }
.quiz-cap-box[hidden] { display: none; }
.quiz-cap-box b { font-size: 1.05rem; }
.quiz-cap-box span { font-size: .9rem; }
.quiz-cap-meta { font-size: .85rem; font-weight: 800; opacity: .8; }

/* leitor */
.leitor-topo { position: sticky; top: calc(var(--faixa-h) + env(safe-area-inset-top)); z-index: 5; margin: -14px -16px 0; padding: 10px 16px 0; background: var(--bg); box-shadow: 0 6px 12px -10px rgba(0,0,0,.4); }
.leitor-topo .topbar { gap: 8px; }
.leitor-topo .icon-btn { min-width: 44px; height: 44px; }
.fonte-btn { padding: 0 8px; font-size: .95rem; }
.leitura-status { display: block; font-size: .8rem; color: var(--muted); font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.leitura-status.ok { color: var(--ok); }
.leitura-status.pausa, .leitura-status.aviso-st { color: var(--warn-ink); }
.leitura-barra { height: 4px; margin: 10px -16px 0; background: var(--line); }
.leitura-barra > div { height: 100%; width: 0; background: linear-gradient(90deg, var(--peach), var(--peach-forte)); transition: width .6s ease; }
.leitura-barra.ok > div { background: var(--ok); }
.leitor-card { padding: 22px 20px; }
.cap-cab { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.cap-titulo { font-size: 2rem; }
.trad-sigla { font-size: .75rem; font-weight: 800; letter-spacing: .1em; color: var(--muted); background: var(--surface); border: 1px dashed var(--borda); border-radius: 4px; padding: 3px 8px; }
.texto-biblia { font-family: Georgia, 'Noto Serif', 'Times New Roman', serif; font-size: var(--fonte, 19px); line-height: 1.75; color: var(--ink); overflow-wrap: break-word; }
.texto-biblia p { margin: 0 0 .9em; line-height: inherit; }
.texto-biblia .vn { font-family: 'Body', system-ui, sans-serif; font-size: .6em; font-weight: 800; color: var(--peach-ink); vertical-align: super; line-height: 0; margin-right: .2em; }
.texto-biblia .v-ausente { color: var(--muted); font-style: italic; font-size: .85em; }
.fim-capitulo { text-align: center; color: var(--muted); font-family: 'Hand', cursive; font-size: 1.3rem; padding: 10px 0 2px; }
footer.traducao { display: block; font-size: .74rem; line-height: 1.5; letter-spacing: .01em; text-align: left; }
footer.traducao a { color: inherit; }
.row .btn-ghost { font-size: .95rem; }

/* ranking: selo de quem leu João */
.rank-leitura { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.rank-leitura .rank-name { display: block; }
.rank-leitura-val { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-weight: 800; font-size: .9rem; color: var(--peach-ink); }
.selo-joao { flex: none; font-size: .68rem; font-weight: 800; letter-spacing: .04em; white-space: nowrap; color: var(--ok-ink); background: var(--ok-soft);
  border: 1px solid var(--ok); border-radius: 3px; padding: 2px 6px; transform: rotate(-2deg); }

/* admin: alertas de leitura */
.alertas { margin-top: 8px; border: 1px dashed var(--line); border-radius: var(--radius); padding: 6px 10px; font-size: .88rem; }
.alertas.tem-aberto { border-color: var(--bad); background: var(--bad-soft); }
.alertas summary { cursor: pointer; font-weight: 800; }
.alerta { padding: 8px 0; border-top: 1px dashed var(--line); }
.alerta:first-of-type { border-top: 0; }
.alerta.resolvido { opacity: .6; }
.alerta .btn-small { margin-top: 6px; min-height: 38px; }

/* comemoração ao ler os 21 capítulos */
.modal-joao { align-items: center; z-index: 65; }
.joao-card { width: 100%; max-width: 420px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; animation: vers-entra .35s cubic-bezier(.2,1.3,.4,1) both; }
.joao-card .btn { width: 100%; }
.joao-selo { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; font-size: 2.6rem; font-weight: 800;
  background: var(--peach); color: var(--on-peach); border: 3px dashed var(--sombra-btn); transform: rotate(-6deg); }
.joao-titulo { font-size: 2.4rem; color: var(--peach-ink); }
.joao-num { margin: 0; font-family: 'Display', Impact, sans-serif; font-size: 1.4rem; letter-spacing: .06em; }
.joao-vers { margin: 0; font-family: Georgia, serif; font-style: italic; line-height: 1.5; }
.joao-vers cite { display: block; margin-top: 4px; font-family: 'Body', system-ui, sans-serif; font-style: normal; font-weight: 800; font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .joao-card { animation: none !important; } .desafio-trilho > div, .leitura-barra > div { transition: none; } }

/* ---------- foto de perfil: avatares, pódio e editar perfil ---------- */
.avatar { flex: none; width: 40px; height: 40px; border-radius: 50%; object-fit: cover; display: grid; place-items: center;
  border: 2px solid var(--kraft); background: var(--surface); }
.avatar-ini { background: var(--kraft); color: #2a1d0f; font-family: 'Display', Impact, sans-serif; font-size: 1.2rem; letter-spacing: .04em; line-height: 1; }
.avatar.m1 { border: 3px solid #e2a63b; box-shadow: 0 0 0 2px color-mix(in srgb, #e2a63b 30%, transparent); }
.avatar.m2 { border: 3px solid #b9b3a8; }
.avatar.m3 { border: 3px solid #b8743f; }
.rank-avatar { width: 42px; height: 42px; margin-left: -4px; }
.rank-list li.top3 { gap: 10px; }
.topbar-perfil { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; border-radius: var(--radius); }
.topbar-perfil:focus-visible { outline: 3px solid color-mix(in srgb, var(--peach) 70%, transparent); outline-offset: 3px; }
.topbar .avatar-topo { width: 46px; height: 46px; object-fit: cover; border: 2px solid var(--peach); }

.podio { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 8px; margin: 16px 0 4px; }
.podio-lugar { display: flex; flex-direction: column; align-items: center; text-align: center; min-width: 0; gap: 2px; }
.podio-foto { position: relative; margin-bottom: 4px; }
.podio-avatar { width: 60px; height: 60px; font-size: 1.6rem; }
.podio-lugar.l1 .podio-avatar { width: 76px; height: 76px; font-size: 2rem; }
.podio-medalha { position: absolute; right: -4px; bottom: -4px; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  font-family: 'Display', Impact, sans-serif; font-size: 1rem; color: #2a1d0f; border: 1px solid #8a5d24; }
.podio-medalha.p1 { background: #f2c27a; }
.podio-medalha.p2 { background: #e3dccf; border-color: #8c8270; }
.podio-medalha.p3 { background: #c98e5b; border-color: #7a4a22; }
.podio-nome { max-width: 100%; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podio-val { font-size: .78rem; font-weight: 700; color: var(--muted); white-space: nowrap; }
.podio-degrau { width: 100%; margin-top: 6px; border-radius: 4px 4px 0 0; background: repeating-linear-gradient(135deg, var(--kraft) 0 8px, color-mix(in srgb, var(--kraft) 82%, #000) 8px 16px); opacity: .55; }
.podio-lugar.l1 .podio-degrau { height: 34px; opacity: .8; }
.podio-lugar.l2 .podio-degrau { height: 22px; }
.podio-lugar.l3 .podio-degrau { height: 14px; }

.perfil-card h3 { margin-bottom: 4px; }
.perfil-previa { display: flex; justify-content: center; margin: 14px 0 16px; }
.perfil-avatar { width: 148px; height: 148px; font-size: 3.6rem; border: 4px solid var(--peach); box-shadow: 0 6px 0 var(--sombra-btn); }
.perfil-escolher { display: flex; gap: 10px; }
.perfil-escolher .btn { flex: 1; }
.perfil-acoes { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.perfil-acoes .btn-small { width: 100%; }
.perfil-acoes [hidden] { display: none; }
.perfil-aviso { margin: 14px 0 0; }
.admin-avatar { width: 48px; height: 48px; }
.user-row .user-info { flex: 1; min-width: 0; }
.tag-bloq { background: var(--bad-soft); color: var(--bad-ink); }

/* ---------- quiz justo: cronômetro, anti-cópia e regras ---------- */
.tempo { display: flex; align-items: center; gap: 10px; margin: 10px 0 2px; }
.tempo-trilho { flex: 1; height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; }
.tempo-barra { height: 100%; width: 100%; border-radius: 99px; background: var(--ok); }
.tempo.acabando .tempo-barra { background: var(--bad); }
.tempo-txt { min-width: 3ch; text-align: right; font-weight: 800; font-size: .9rem; font-variant-numeric: tabular-nums; }
.tempo.acabando .tempo-txt { color: var(--bad); }
.sem-copia .question, .sem-copia .option { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.regras-quiz ul { margin: 0; padding-left: 1.1em; display: grid; gap: 8px; }
.regras-quiz li { line-height: 1.4; }
.susp-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.tag-alerta { background: var(--bad-soft); color: var(--bad-ink); }

/* ---------- faixas do ranking ---------- */
.selo-faixa { display: inline-block; font-weight: 800; font-size: .85rem; border-radius: 999px; }
.faixa-card .selo-faixa, .res-faixa .selo-faixa { padding: 4px 12px; background: var(--warn-soft); color: var(--warn-ink); font-size: .95rem; }
.faixa-card .selo-elite, .res-faixa .selo-elite { background: var(--bad-soft); color: var(--bad-ink); }
.faixa-card .selo-subindo, .res-faixa .selo-subindo { background: var(--ok-soft); color: var(--ok-ink); }
.faixa-topo { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.faixa-link { background: none; border: 0; padding: 4px 0; color: var(--peach-ink); font: inherit; font-weight: 800; text-decoration: underline; cursor: pointer; }
.faixa-pos { display: flex; gap: 16px; margin-top: 10px; color: var(--muted); font-weight: 700; flex-wrap: wrap; }
.faixa-pos b { color: var(--ink); font-size: 1.15rem; }
.faixa-linha { margin: 8px 0 0; font-weight: 800; }
.faixa-hoje { margin-top: 10px; font-size: .85rem; color: var(--muted); }
.faixa-hoje-barra { height: 8px; border-radius: 999px; background: var(--line); overflow: hidden; margin-bottom: 4px; }
.faixa-hoje-barra > div { height: 100%; background: var(--ok); border-radius: 999px; }
.res-faixa { display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 700; }
.aviso-limite { margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: var(--warn-soft); color: var(--warn-ink); font-weight: 800; text-align: center; }
.regras-ranking ul { margin: 0; padding-left: 0; list-style: none; display: grid; gap: 10px; }
.regras-ranking li { display: grid; gap: 2px; padding: 10px 12px; border-radius: 12px; background: var(--bg); }
.regras-ranking li span { color: var(--muted); }
