:root {
  --primaria: #141414;
  --primaria-2: #c8102e;
  --acento: #f0b323;
  --fundo: #f4f3f1;
  --cartao: #ffffff;
  --texto: #18211c;
  --muted: #6b766f;
  --linha: #e3e8e4;
  --ruim: #d9534f;
  --medio: #e8a33d;
  --bom: #7cb342;
  --otimo: #1e8e3e;
  --campo: #2e7d43;
  --campo-2: #2a7340;
  --sombra: 0 1px 2px rgba(0,0,0,.05), 0 2px 10px rgba(0,0,0,.05);
  --raio: 14px;
  --nav-h: 64px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fundo: #111111; --cartao: #1c1c1c; --texto: #ececec; --muted: #9c9c9c; --linha: #2e2e2e; --primaria-2: #e5484d;
    --primaria: #000000; --campo: #1f5e33; --campo-2: #1c5530; --sombra: none; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --fundo: #111111; --cartao: #1c1c1c; --texto: #ececec; --muted: #9c9c9c; --linha: #2e2e2e; --primaria-2: #e5484d;
  --primaria: #000000; --campo: #1f5e33; --campo-2: #1c5530; --sombra: none; color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; }
body {
  font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--fundo); color: var(--texto);
  padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 12px);
  overscroll-behavior-y: none;
}
a { color: var(--primaria-2); }
h1, h2, h3 { margin: 0; line-height: 1.2; }
h2 { font-size: 17px; }
.ico { width: 22px; height: 22px; flex: none; }
.mini-ico { width: 14px; height: 14px; vertical-align: -2px; }

/* topo */
#topo {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 8px;
  padding: calc(env(safe-area-inset-top) + 8px) 12px 10px;
  background: var(--primaria); color: #fff;
}
#topo h1 { flex: 1; font-size: 18px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topo-btn { color: #fff; background: none; border: 0; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; padding: 0; }
.topo-btn:active { background: rgba(255,255,255,.15); }
.topo-escudo { width: 40px; display: grid; place-items: center; }
.topo-escudo img { height: 38px; width: auto; display: block; }
.boas-vindas .escudo-grande { display: block; height: 120px; width: auto; margin: 2px auto 10px; }

main { max-width: 640px; margin: 0 auto; padding: 12px 16px; }

/* navegação inferior */
#nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 20;
  display: flex; justify-content: space-around;
  height: calc(var(--nav-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: var(--cartao); border-top: 1px solid var(--linha);
}
#nav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: var(--muted); text-decoration: none; font-size: 11px; }
#nav a.ativo { color: var(--primaria-2); font-weight: 600; }
#nav a.ativo .ico { stroke-width: 2.3; }

/* cartões */
.cartao { background: var(--cartao); border-radius: var(--raio); padding: 14px; margin: 0 0 12px; box-shadow: var(--sombra); }
.cartao-cab { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.cartao-cab a { font-size: 13px; text-decoration: none; }
.cartao.lista { padding: 4px 14px; }
.sub { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 16px 2px 6px; font-weight: 600; }
.sub-cab { color: var(--muted); font-size: 13px; margin: 0 0 10px; }
.mini { font-size: 12px; color: var(--muted); }
.dica { font-size: 12.5px; color: var(--muted); margin: 6px 0; }
.centro { text-align: center; }
.vazio { text-align: center; color: var(--muted); padding: 18px 8px; display: grid; gap: 12px; justify-items: center; }
.erro, .msg.erro { color: var(--ruim); }
.obs { background: var(--fundo); border-radius: 10px; padding: 8px 10px; margin: 6px 0; font-size: 14px; white-space: pre-wrap; }
.obs small { color: var(--muted); font-weight: 600; margin-right: 4px; }

/* botões */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 44px; padding: 0 16px; border-radius: 12px; border: 0;
  background: var(--primaria-2); color: #fff; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
}
.btn:active { filter: brightness(.92); }
.btn:disabled { opacity: .55; }
.btn.sec { background: var(--fundo); color: var(--texto); border: 1px solid var(--linha); }
.btn.perigo { background: var(--ruim); }
.btn.link { background: none; color: var(--primaria-2); padding: 0 4px; min-height: 34px; }
.perigo-txt { color: var(--ruim) !important; }
.btn.largo { width: 100%; margin: 4px 0 12px; }
.btn.redondo { width: 46px; height: 46px; padding: 0; border-radius: 50%; flex: none; }
.btn.grande { flex: 1; min-height: 64px; justify-content: flex-start; padding: 0 16px; font-size: 16px; }
.btn.grande span { display: flex; flex-direction: column; text-align: left; line-height: 1.15; }
.btn.grande small { font-weight: 400; opacity: .85; font-size: 12px; }
.btn.grande .ico { width: 28px; height: 28px; }
.mini-btn { min-height: 46px; padding: 0 12px; }
.botoes-ev { display: flex; gap: 10px; margin-bottom: 12px; }

.fab-grupo { position: fixed; right: 16px; bottom: calc(var(--nav-h) + env(safe-area-inset-bottom) + 14px); display: flex; gap: 8px; z-index: 15; }
.fab { display: inline-flex; align-items: center; gap: 6px; height: 50px; padding: 0 18px; border-radius: 25px; border: 0; background: var(--primaria-2); color: #fff; font: inherit; font-weight: 700; box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.fab.sec { background: var(--cartao); color: var(--texto); }

/* segmentado */
.seg { display: flex; background: var(--linha); border-radius: 12px; padding: 3px; margin-bottom: 12px; }
.seg button { flex: 1; border: 0; background: none; padding: 9px 4px; border-radius: 9px; font: inherit; font-weight: 600; color: var(--muted); }
.seg button.on { background: var(--cartao); color: var(--texto); box-shadow: var(--sombra); }
.seg.pequeno button { padding: 7px 4px; }

/* chips */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.chips.rola { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; margin: 0 -16px 8px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; }
.chips.rola::-webkit-scrollbar { display: none; }
.chip { --c: var(--primaria-2); position: relative; display: inline-flex; border: 1.5px solid var(--linha); background: var(--cartao); color: var(--texto); border-radius: 20px; padding: 7px 12px; font: inherit; font-size: 13.5px; white-space: nowrap; cursor: pointer; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip.on, .chip:has(input:checked) { border-color: var(--c); background: color-mix(in srgb, var(--c) 14%, var(--cartao)); color: var(--texto); font-weight: 600; }

/* formulários */
.form { display: grid; gap: 10px; }
.form h2 { margin-bottom: 4px; }
label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); font-weight: 600; }
.rotulo { font-size: 13px; color: var(--muted); font-weight: 600; display: block; margin-bottom: 4px; }
.rotulo small, label small { font-weight: 400; }
input, select, textarea {
  font: inherit; font-size: 16px; color: var(--texto); background: var(--fundo);
  border: 1px solid var(--linha); border-radius: 10px; padding: 10px 12px; width: 100%; min-height: 44px;
}
textarea { resize: vertical; min-height: 0; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--primaria-2); outline-offset: -1px; }
.duas { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--texto); font-size: 14px; flex-wrap: wrap; }
.check input[type=checkbox] { width: 22px; height: 22px; min-height: 0; flex: none; accent-color: var(--primaria-2); }
input.num { width: 70px; text-align: center; padding: 8px; min-height: 36px; }
.faixa { display: block; }
.faixa input { display: block; margin-top: 4px; padding: 0; min-height: 30px; accent-color: var(--primaria-2); background: none; border: 0; }
.faixa b { color: var(--texto); }
.acoes { display: flex; gap: 10px; justify-content: flex-end; margin-top: 4px; }
.acoes .btn:last-child { flex: 1; }
.form .so-jogo, .form .so-treino { display: none; gap: 10px; }
.form[data-tipo=jogo] .so-jogo, .form[data-tipo=treino] .so-treino { display: grid; }
details { border-top: 1px solid var(--linha); padding: 8px 0; }
details summary { font-weight: 700; cursor: pointer; }
details ul { margin: 6px 0 0; padding-left: 18px; font-size: 13.5px; }

/* folha inferior */
.folha-fundo { position: fixed; inset: 0; z-index: 50; background: rgba(0,0,0,0); transition: background .2s; display: flex; align-items: flex-end; justify-content: center; }
.folha-fundo.on { background: rgba(0,0,0,.45); }
.folha {
  width: 100%; max-width: 640px; max-height: 92vh; overflow-y: auto;
  background: var(--cartao); border-radius: 18px 18px 0 0; padding: 8px 16px calc(20px + env(safe-area-inset-bottom));
  transform: translateY(100%); transition: transform .22s ease-out;
}
.folha-fundo.on .folha { transform: none; }
.folha-alca { width: 40px; height: 4px; border-radius: 2px; background: var(--linha); margin: 2px auto 12px; }
.folha h2 { margin-bottom: 10px; }
.folha h2 small { color: var(--muted); font-weight: 500; font-size: 14px; }

#toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + 24px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); background: #222; color: #fff; padding: 10px 16px; border-radius: 22px; font-size: 14px; opacity: 0; transition: .2s; z-index: 60; pointer-events: none; }
#toast.on { opacity: 1; transform: translate(-50%, 0); }

/* avatar e linhas */
.avatar { --h: 140; width: 38px; height: 38px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 800; font-size: 14px; color: #fff; background: hsl(var(--h) 45% 42%); }
.avatar.p { width: 32px; height: 32px; font-size: 12.5px; }
.avatar.g { width: 56px; height: 56px; font-size: 20px; }
.linha-j, .jog { display: flex; align-items: center; gap: 10px; padding: 9px 0; color: inherit; text-decoration: none; border: 0; background: none; width: 100%; font: inherit; text-align: left; }
.linha-j + .linha-j, .jog + .jog { border-top: 1px solid var(--linha); }
.linha-nome { flex: 1; min-width: 0; display: flex; flex-direction: column; font-weight: 600; }
.linha-nome small { color: var(--muted); font-weight: 400; font-size: 12.5px; }
.linha-nome i { font-weight: 400; color: var(--muted); }
.jog.inativo { opacity: .55; }
.dir { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.dir small { font-size: 11px; color: var(--muted); }
.tag-l { font-style: normal; background: color-mix(in srgb, var(--ruim) 15%, transparent); color: var(--ruim); padding: 1px 6px; border-radius: 6px; font-size: 11.5px; font-weight: 600; }
.selo { --c: var(--muted); min-width: 40px; padding: 4px 6px; border-radius: 9px; text-align: center; font-weight: 800; font-size: 14px; color: #fff; background: var(--c); }
.mini-barras { display: flex; gap: 3px; margin-top: 5px; }
.mini-barras i { width: 34px; height: 5px; border-radius: 3px; background: linear-gradient(to right, var(--c) calc(var(--v) * 100%), var(--linha) 0); }

/* eventos */
.evento { display: flex; align-items: center; gap: 12px; padding: 10px 0; color: inherit; text-decoration: none; }
.lista .evento + .evento, .cartao .evento + .evento { border-top: 1px solid var(--linha); }
.evento-ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; flex: none; background: color-mix(in srgb, var(--primaria-2) 14%, transparent); color: var(--primaria-2); }
.evento.jogo .evento-ico { background: color-mix(in srgb, var(--acento) 25%, transparent); color: #9a6b00; }
.evento-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.evento-txt small { color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.placar { font-weight: 800; padding: 3px 8px; border-radius: 8px; font-size: 14px; color: #fff; }
.placar.v { background: var(--otimo); } .placar.e { background: var(--medio); } .placar.d { background: var(--ruim); }
.prox { display: flex; align-items: center; gap: 6px; }
.prox + .prox { border-top: 1px solid var(--linha); }
.prox .evento { flex: 1; min-width: 0; }
.quando { font-size: 12px; font-weight: 700; color: var(--primaria-2); white-space: nowrap; }

.atalhos { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
.atalhos button, .atalhos a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px; border-radius: var(--raio); background: var(--cartao); border: 0; color: var(--texto); font: inherit; font-size: 12px; font-weight: 600; text-decoration: none; box-shadow: var(--sombra); }
.atalhos .ico { color: var(--primaria-2); width: 26px; height: 26px; }
.alertas p { display: flex; gap: 8px; align-items: flex-start; margin: 4px 0; font-size: 14px; }
.alertas .ico { color: var(--medio); width: 20px; height: 20px; margin-top: 1px; }
.boas-vindas { background: linear-gradient(135deg, var(--primaria), var(--primaria-2)); color: #fff; }
.boas-vindas a { color: var(--acento); font-weight: 700; }
.boas-vindas ol { padding-left: 20px; }
.boas-vindas .btn { background: #fff; color: var(--primaria); }
.campanha, .numeros, .resumo-esc { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; text-align: center; margin-bottom: 6px; }
.numeros { grid-template-columns: repeat(auto-fit, minmax(54px, 1fr)); background: var(--cartao); border-radius: var(--raio); padding: 12px 6px; box-shadow: var(--sombra); margin-bottom: 12px; }
.resumo-esc { grid-template-columns: repeat(3, 1fr); margin: 10px 0; }
.campanha b, .numeros b, .resumo-esc b { display: block; font-size: 20px; }
.campanha small, .numeros small, .resumo-esc small { color: var(--muted); font-size: 11.5px; }

/* evento: detalhes */
.info-linha { display: flex; gap: 12px; align-items: center; }
.info-linha > .ico { width: 30px; height: 30px; color: var(--primaria-2); }
.info-linha div { display: flex; flex-direction: column; }
.info-linha small { color: var(--muted); }
.plano { border-top: 1px solid var(--linha); margin-top: 10px; padding-top: 6px; font-size: 14px; }
.plano p { margin: 4px 0; }
.presenca { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.pres { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 10px; border: 1px solid var(--linha); background: var(--cartao); color: var(--texto); font: inherit; font-size: 14px; text-align: left; min-height: 46px; }
.pres span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pp { width: 28px; height: 28px; border-radius: 8px; display: inline-grid; place-items: center; font-weight: 800; background: var(--linha); color: var(--muted); flex: none; font-size: 13px; }
.dica .pp { width: 20px; height: 20px; font-size: 11px; }
.pp.P { background: var(--otimo); color: #fff; } .pp.F { background: var(--ruim); color: #fff; } .pp.J { background: var(--medio); color: #fff; }
.placar-ed { display: flex; align-items: center; justify-content: center; gap: 12px; }
.placar-ed div { display: grid; gap: 4px; text-align: center; flex: 1; }
.placar-ed small { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.placar-ed input { font-size: 30px; font-weight: 800; text-align: center; height: 64px; }
.placar-ed > span { font-size: 22px; color: var(--muted); }
.stat-l { display: flex; align-items: center; gap: 8px; padding: 6px 0; }
.stat-l + .stat-l { border-top: 1px solid var(--linha); }
.stepper { display: flex; align-items: center; gap: 2px; }
.stepper .ico, .stepper i.a { width: 16px; height: 16px; color: var(--muted); font-style: normal; font-weight: 800; font-size: 12px; text-align: center; }
.stepper button { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--linha); background: var(--fundo); color: var(--texto); font-size: 18px; line-height: 1; padding: 0; }
.stepper b { min-width: 18px; text-align: center; }

/* avaliação */
.legenda { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 12px; color: var(--muted); margin: 0 0 10px; }
.legenda b { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 5px; color: #fff; font-size: 11px; margin-right: 2px; }
.n1 { --nc: #d9534f; } .n2 { --nc: #ee8a3c; } .n3 { --nc: #c9a227; } .n4 { --nc: #7cb342; } .n5 { --nc: #1e8e3e; }
.legenda b { background: var(--nc); }
.quesito-atual { border-left: 5px solid var(--c); display: flex; flex-direction: column; gap: 2px; }
.quesito-atual b { font-size: 17px; }
.quesito-atual small { color: var(--muted); }
.lista-aval { padding: 4px 12px; }
.aval-l, .aval-q { display: flex; align-items: center; gap: 8px; padding: 8px 0; }
.aval-l + .aval-l, .aval-q + .aval-q { border-top: 1px solid var(--linha); }
.aval-q { flex-wrap: wrap; }
.aval-q .linha-nome { min-width: 150px; }
.notas { display: flex; gap: 4px; flex: none; }
.notas button { width: 36px; height: 40px; border-radius: 9px; border: 1.5px solid var(--linha); background: var(--fundo); color: var(--texto); font: inherit; font-weight: 700; padding: 0; }
.notas button.on { background: var(--nc); border-color: var(--nc); color: #fff; transform: scale(1.06); }
.grupo-aval h3 { color: var(--c); font-size: 15px; margin-bottom: 4px; }
.nav-q { display: flex; gap: 10px; margin: 4px 0 16px; }
.nav-q .btn { flex: 1; }

/* campo */
.campo {
  position: relative; aspect-ratio: 68 / 88; width: 100%; max-width: 460px; margin: 0 auto;
  border-radius: 14px; overflow: hidden;
  background: repeating-linear-gradient(to bottom, var(--campo) 0 10%, var(--campo-2) 10% 20%);
  box-shadow: inset 0 0 0 3px rgba(255,255,255,.55);
}
.campo-linhas i { position: absolute; border: 2px solid rgba(255,255,255,.55); }
.campo-linhas .meio { left: 0; right: 0; top: 50%; border-width: 2px 0 0; }
.campo-linhas .circ { width: 26%; aspect-ratio: 1; left: 37%; top: 50%; transform: translateY(-50%); border-radius: 50%; }
.campo-linhas .area { left: 22%; right: 22%; height: 13%; }
.campo-linhas .a1 { top: -2px; border-top: 0; }
.campo-linhas .a2 { bottom: -2px; border-bottom: 0; }
.slot { position: absolute; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 1px; background: none; border: 0; padding: 0; color: #fff; font: inherit; width: 84px; }
.slot .avatar { width: 42px; height: 42px; border: 2.5px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.35); }
.slot.fixo .avatar { border-color: var(--acento); }
.slot.vago .avatar { background: rgba(0,0,0,.3); border-style: dashed; }
.slot-nome { font-weight: 700; font-size: 12.5px; text-shadow: 0 1px 3px rgba(0,0,0,.7); max-width: 84px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background: rgba(0,0,0,.28); padding: 0 5px; border-radius: 6px; }
.slot-pos { font-size: 10.5px; opacity: .92; text-shadow: 0 1px 2px rgba(0,0,0,.7); }
.acoes-esc { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.acoes-esc .btn { flex: 1; }
.motivos { background: var(--fundo); border-radius: 10px; padding: 8px 12px; margin: 8px 0; font-size: 14px; }
.motivos ul { margin: 4px 0 0; padding-left: 18px; }
.lista-troca .linha-j.atual { background: color-mix(in srgb, var(--primaria-2) 10%, transparent); border-radius: 10px; }

/* perfil */
.perfil-cab { display: flex; align-items: center; gap: 12px; }
.perfil-cab > div:nth-child(2) { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.perfil-cab small { color: var(--muted); }
.nota-g { text-align: center; }
.nota-g b { display: block; font-size: 30px; color: var(--c); line-height: 1; }
.nota-g small { font-size: 11px; color: var(--muted); }
.grupo-perf h2 { color: var(--c); }
.q-l { display: grid; grid-template-columns: minmax(110px, 1.2fr) 2fr 34px 18px; align-items: center; gap: 8px; padding: 4px 0; font-size: 14px; }
.q-l b { text-align: right; }
.q-l small { color: var(--muted); font-size: 11px; }
.barra { height: 8px; border-radius: 4px; background: var(--linha); overflow: hidden; }
.barra i { display: block; height: 100%; border-radius: 4px; }
.grafico { width: 100%; height: auto; }
.g-grade { stroke: var(--linha); stroke-width: 1; }
.g-txt { fill: var(--muted); font-size: 9px; }
.g-linha { fill: none; stroke: var(--primaria-2); stroke-width: 2.2; }
.g-pt { fill: var(--cartao); stroke: var(--primaria-2); stroke-width: 1.6; }
.g-pt.jogo { fill: var(--acento); stroke: #9a6b00; }

/* assistente */
.intro-ia h2 { display: flex; align-items: center; gap: 8px; color: var(--primaria-2); }
.atalhos-ia { display: grid; gap: 8px; }
.atalhos-ia button { text-align: left; padding: 13px 14px; border-radius: 12px; border: 1px solid var(--linha); background: var(--cartao); color: var(--texto); font: inherit; font-weight: 600; }
.atalhos-ia button:active { background: var(--linha); }
#chat { padding-bottom: 80px; }
.msg { border-radius: 14px; padding: 10px 14px; margin: 8px 0; max-width: 100%; overflow-wrap: anywhere; }
.msg.user { background: var(--primaria-2); color: #fff; margin-left: 15%; white-space: pre-wrap; }
.msg.assistant { background: var(--cartao); box-shadow: var(--sombra); }
.msg.assistant h3, .msg.assistant h4, .msg.assistant h5 { margin: 12px 0 4px; font-size: 15.5px; color: var(--primaria-2); }
.msg.assistant p { margin: 6px 0; }
.msg.assistant ul, .msg.assistant ol { margin: 6px 0; padding-left: 20px; }
.msg.assistant li { margin: 3px 0; }
.msg.assistant code { background: var(--fundo); padding: 0 4px; border-radius: 4px; }
.msg.pensando { color: var(--muted); display: flex; gap: 8px; align-items: center; }
.pontos { display: inline-flex; gap: 3px; }
.pontos i { width: 6px; height: 6px; border-radius: 50%; background: var(--primaria-2); animation: pulo 1s infinite; }
.pontos i:nth-child(2) { animation-delay: .15s; } .pontos i:nth-child(3) { animation-delay: .3s; }
@keyframes pulo { 0%, 100% { opacity: .3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-3px); } }
.tabela-rola { overflow-x: auto; margin: 8px 0; }
table { border-collapse: collapse; font-size: 13px; width: 100%; }
th, td { border: 1px solid var(--linha); padding: 5px 7px; text-align: left; vertical-align: top; }
th { background: var(--fundo); }
.chat-entrada {
  position: fixed; left: 0; right: 0; bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); z-index: 16;
  display: flex; gap: 8px; align-items: flex-end; padding: 8px 12px; background: var(--fundo); border-top: 1px solid var(--linha);
  max-width: 640px; margin: 0 auto;
}
.chat-entrada textarea { flex: 1; border-radius: 22px; padding: 11px 16px; max-height: 140px; }
.destaque-inst { border: 2px solid var(--primaria-2); }
.destaque-inst h2 { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }

@media (min-width: 700px) {
  .presenca { grid-template-columns: 1fr 1fr 1fr; }
}
@media (max-width: 360px) {
  .notas button { width: 31px; }
  .atalhos span { font-size: 11px; }
}

/* ---------- v2: scout, gráficos, famílias ---------- */
button.q-l { width: 100%; background: none; border: 0; color: inherit; font: inherit; text-align: left; cursor: pointer; border-radius: 8px; }
button.q-l:active { background: var(--fundo); }
.tend { font-size: 10px; margin-left: 2px; }
.tend.sobe { color: var(--otimo); } .tend.desce { color: var(--ruim); }

.graf { margin: 6px 0 2px; }
.graf svg { width: 100%; height: auto; display: block; }
.graf figcaption { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.legenda-g { display: flex; flex-wrap: wrap; gap: 4px 12px; }
.legenda-g i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }
.g-media { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 4 3; }

.scout-cab { display: flex; align-items: center; gap: 10px; }
.scout-cab .linha-nome { flex: 1; }
.scout-cab .min { display: flex; flex-direction: column; font-size: 12px; color: var(--muted); width: 80px; }
.scout-cab .min input { text-align: center; font-size: 18px; padding: 6px; }
.scout-grade { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 8px; }
.scout-b { position: relative; }
.scout-b .mais { width: 100%; min-height: 84px; border: 1.5px solid var(--linha); background: var(--cartao); color: var(--texto); border-radius: 14px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font: inherit; cursor: pointer; padding: 8px 4px; box-shadow: var(--sombra); }
.scout-b .mais b { font-size: 26px; line-height: 1; color: var(--primaria-2); }
.scout-b.neg .mais b { color: var(--ruim); }
.scout-b .mais span { font-size: 12px; text-align: center; line-height: 1.15; }
.scout-b .mais:active { transform: scale(.96); }
.scout-b.pulso .mais { animation: pulso .35s; }
@keyframes pulso { 50% { border-color: var(--primaria-2); background: color-mix(in srgb, var(--primaria-2) 12%, var(--cartao)); } }
.scout-b .menos { position: absolute; top: 4px; right: 4px; width: 26px; height: 26px; border-radius: 8px; border: 0; background: var(--fundo); color: var(--muted); font-size: 16px; line-height: 1; cursor: pointer; }

.totais { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 6px; text-align: center; margin-bottom: 8px; }
.totais div { background: var(--fundo); border-radius: 10px; padding: 8px 4px; }
.totais b { display: block; font-size: 20px; color: var(--primaria-2); }
.totais .neg b { color: var(--ruim); }
.totais small { font-size: 11px; color: var(--muted); line-height: 1.1; display: block; }

.lista-notas { display: grid; gap: 4px; margin-top: 8px; }
.lista-notas div { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; border-bottom: 1px solid var(--linha); }
.lista-notas b { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; color: #fff; background: var(--nc); }
.q-l b[class^="n"] { color: var(--nc); }

.nota-b { width: 100%; background: none; border: 0; text-align: left; font: inherit; color: inherit; cursor: pointer; padding: 0; }
.fb-l { width: 100%; display: grid; grid-template-columns: auto 1fr; gap: 2px 8px; align-items: center; background: none; border: 0; border-top: 1px solid var(--linha); padding: 8px 0; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.fb-l small { color: var(--muted); }
.fb-txt { grid-column: 1 / -1; font-size: 13.5px; color: var(--muted); }
.tag-fb { font-size: 11px; font-weight: 700; border-radius: 6px; padding: 2px 6px; background: var(--linha); color: var(--muted); }
.tag-fb.publicado { background: color-mix(in srgb, var(--otimo) 18%, transparent); color: var(--otimo); }
.folha textarea#fb-txt { width: 100%; margin: 6px 0 10px; line-height: 1.45; }

.tag-conv { display: inline-block; margin-top: 3px; font-size: 11.5px; font-weight: 700; border-radius: 6px; padding: 2px 7px; background: var(--linha); color: var(--muted); }
.tag-conv.tit { background: color-mix(in srgb, var(--otimo) 18%, transparent); color: var(--otimo); }
.tag-conv.res { background: color-mix(in srgb, var(--medio) 22%, transparent); color: #9a6b00; }
.evento-txt { display: flex; flex-direction: column; }
.placar-g { font-size: 16px; margin: 8px 0 0; }
.recado p { margin: 6px 0; line-height: 1.5; }
a.recado { display: block; color: inherit; text-decoration: none; }

.acesso { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 0; border-top: 1px solid var(--linha); }
.acesso:first-of-type { border-top: 0; }
.acesso .linha-nome { flex: 1 1 180px; }
.acesso .linha-nome i { font-style: normal; color: var(--muted); font-size: 12.5px; }
.acesso-b { display: flex; gap: 6px; }
.acesso-b .btn { min-height: 36px; padding: 0 12px; font-size: 14px; }

.link-ind { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.link-ind > .ico:first-child { width: 30px; height: 30px; color: var(--primaria-2); }
.link-ind span { flex: 1; display: flex; flex-direction: column; }
.link-ind small { color: var(--muted); }
a.cartao.alertas { display: block; color: inherit; text-decoration: none; }
.publica .check { font-weight: 600; }

.entrada { text-align: center; padding: 18px 4px; }
.entrada-escudo { height: 150px; width: auto; margin: 6px auto 8px; display: block; }
.entrada h1 { font-size: 24px; margin: 0 0 4px; }
.entrada p { color: var(--muted); }
.btn.grande-b { width: 100%; min-height: 72px; justify-content: flex-start; text-align: left; margin: 8px 0; padding: 0 16px; font-size: 16px; }
.btn.grande-b .ico { width: 28px; height: 28px; flex: none; }
.btn.grande-b span { display: flex; flex-direction: column; line-height: 1.2; }
.btn.grande-b small { font-weight: 400; opacity: .85; font-size: 12.5px; }
body[data-papel="escolha"] #nav { display: none; }
.check.longo { flex-wrap: nowrap; align-items: flex-start; font-weight: 400; font-size: 13.5px; line-height: 1.4; }
a.nota-g { text-decoration: none; }

/* v2.1: convite pessoal */
[hidden] { display: none !important; }
.entrada .entrada-tec { margin-top: 28px; color: var(--muted); font-size: 14px; }
.codigo-conv { font: 700 26px/1.2 ui-monospace, Menlo, Consolas, monospace; letter-spacing: 3px; text-align: center; margin: 10px 0 14px; color: var(--texto, inherit); }
#familia .btn.largo { margin-top: 10px; }
#aviso-versao { position: fixed; left: 12px; right: 12px; bottom: calc(76px + env(safe-area-inset-bottom)); z-index: 60; border: 0; border-radius: 12px; padding: 14px; background: var(--primaria-2); color: #fff; font: 600 15px/1.3 inherit; box-shadow: 0 6px 20px rgba(0,0,0,.25); }

/* v2.3: lances por voz */
.voz-linha { display: flex; gap: 8px; align-items: stretch; margin: 8px 0; }
.voz-linha textarea { flex: 1; min-width: 0; }
.btn.voz { width: 56px; min-width: 56px; padding: 0; justify-content: center; border-radius: 14px; }
.btn.voz .ico { width: 26px; height: 26px; }
.btn.voz.on { background: var(--primaria-2); animation: ouvindo 1s ease-in-out infinite; }
@keyframes ouvindo { 50% { box-shadow: 0 0 0 8px color-mix(in srgb, var(--primaria-2) 25%, transparent); } }
.lista-lances { margin: 10px 0; display: grid; gap: 6px; }
.lance { display: flex; gap: 8px; align-items: flex-start; padding: 8px 10px; border-radius: 10px; background: var(--fundo); }
.lance b { color: var(--muted); font-size: 13px; min-width: 16px; }
.lance span { flex: 1; font-size: 14px; }
.lance .btn.link { min-height: 24px; font-size: 18px; line-height: 1; }
.rev-l { align-items: flex-start; padding: 6px 0; border-bottom: 1px solid var(--linha); }
.rev-l span { display: block; }
.rev-l small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.rev-l .lance-ref { font-style: italic; }
.rev-l .selo { display: inline-flex; vertical-align: middle; }
.duvidas { margin: 4px 0 4px 18px; padding: 0; color: var(--texto); font-size: 14px; }

/* v2.3.2: atalhos de registro em destaque */
.registrar { display: flex; gap: 10px; margin-bottom: 12px; }
.registrar .btn.grande { min-height: 76px; padding: 0 12px; gap: 10px; }
.registrar .btn.grande .ico { flex: none; }
.btn.grande.largo-g { display: flex; width: 100%; margin-bottom: 12px; border: 2px solid var(--primaria-2); }
.btn.grande.largo-g .ico { color: var(--primaria-2); }
@media (max-width: 360px) { .registrar { flex-direction: column; } }
