/* Visual inspirado no politicometro.org: fundo cinza-esverdeado, tinta quase preta,
   números grandes em Big Shoulders, botões em pílula e rodapé escuro. */

/* Fontes servidas daqui mesmo (só o conjunto latino), para o site não depender de terceiros.
   Big Shoulders e Public Sans são variáveis: um arquivo cobre todos os pesos. Licença em fontes/LICENCA.md. */
@font-face { font-family: "Public Sans"; font-weight: 100 900; font-display: swap; src: url(fontes/public-sans.woff2) format("woff2"); }
@font-face { font-family: "Big Shoulders"; font-weight: 100 900; font-display: swap; src: url(fontes/big-shoulders.woff2) format("woff2"); }
@font-face { font-family: "Libre Franklin"; font-weight: 800; font-display: swap; src: url(fontes/libre-franklin.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 500; font-display: swap; src: url(fontes/ibm-plex-mono-500.woff2) format("woff2"); }

:root {
  --f-corpo: "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-marca: "Libre Franklin", var(--f-corpo);
  --f-numeros: "Big Shoulders", "Libre Franklin", var(--f-corpo);
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;

  --bg: #f2f4f2;
  --surface: #fff;
  --ink: #14181d;
  --muted: #56606b;
  --line: #d7dde1;
  --accent: #1d5a8a;
  --hi: #d9961a;
  --warn-bg: #fff4da;
  --warn-ink: #6b4a00;
  --sombra: 0 10px 30px #14181d1a;

  --c-licitacao: #b45309;
  --c-contrato: #be123c;
  --c-pessoal: #6d28d9;
  --c-concurso: #0e7490;
  --c-lei: #1d4fb8;
  --c-decreto: #0f766e;
  --c-portaria: #56606b;
  --c-outros: #78716c;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c1015;
    --surface: #141a21;
    --ink: #e7ecf1;
    --muted: #9aa6b3;
    --line: #26303b;
    --accent: #6ea6d8;
    --hi: #f0b13c;
    --warn-bg: #2b2410;
    --warn-ink: #f3d58a;
    --sombra: 0 10px 30px #00000073;
    --c-licitacao: #f59e0b;
    --c-contrato: #fb7185;
    --c-pessoal: #a78bfa;
    --c-concurso: #22d3ee;
    --c-lei: #7aa2f7;
    --c-decreto: #2dd4bf;
    --c-portaria: #9aa6b3;
    --c-outros: #a8a29e;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #0c1015;
  --surface: #141a21;
  --ink: #e7ecf1;
  --muted: #9aa6b3;
  --line: #26303b;
  --accent: #6ea6d8;
  --hi: #f0b13c;
  --warn-bg: #2b2410;
  --warn-ink: #f3d58a;
  --sombra: 0 10px 30px #00000073;
  --c-licitacao: #f59e0b;
  --c-contrato: #fb7185;
  --c-pessoal: #a78bfa;
  --c-concurso: #22d3ee;
  --c-lei: #7aa2f7;
  --c-decreto: #2dd4bf;
  --c-portaria: #9aa6b3;
  --c-outros: #a8a29e;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 110px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.55 var(--f-corpo);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-underline-offset: 2px; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.wrap { max-width: 1120px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sem-barra { scrollbar-width: none; }
.sem-barra::-webkit-scrollbar { display: none; }

/* Botões e campos em pílula */
.botao {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 42px; padding: 0 16px; border: 1.5px solid var(--ink); border-radius: 999px;
  background: none; color: var(--ink); font: 700 14px var(--f-corpo); text-decoration: none; cursor: pointer;
}
.botao:hover { background: var(--ink); color: var(--bg); }
.botao-primario { background: var(--ink); color: var(--bg); }
.link-botao { font: inherit; color: var(--accent); background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; }
.campo {
  width: 100%; min-height: 44px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--ink); font: 600 15px var(--f-corpo);
}
.campo:focus { border-color: var(--ink); outline: none; }

.pular { position: absolute; left: 8px; top: -60px; z-index: 50; background: var(--surface); }
.pular:focus { top: 8px; }

/* Topo fixo */
.topo { position: sticky; top: 0; z-index: 30; background: var(--surface); border-bottom: 1px solid var(--line); }
.topo-linha { display: flex; align-items: center; gap: 16px; min-height: 60px; }
.logo { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); text-decoration: none; flex: none; }
.logo-olho { width: 30px; height: 30px; }
.logo-nome { font: 800 21px/1 var(--f-marca); letter-spacing: -0.02em; }
.logo-em { color: var(--muted); }

.secoes { display: flex; gap: 2px; overflow-x: auto; flex: 1; padding: 4px; }
.secoes a {
  display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px; border-radius: 999px; flex: none;
  color: var(--muted); font: 600 14px var(--f-corpo); text-decoration: none; white-space: nowrap; transition: color .2s, background .2s;
}
.secoes a:hover { color: var(--ink); }
.secoes a[aria-current="page"] { background: var(--ink); color: var(--bg); }
.secao-icone, .nome-curto { display: none; }

.tema { flex: none; width: 40px; height: 40px; border-radius: 999px; border: 1.5px solid var(--line); background: none; color: var(--ink); cursor: pointer; display: grid; place-items: center; }
.tema:hover { border-color: var(--ink); }
.tema svg { width: 18px; height: 18px; }

.faixa { background: var(--bg); border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.faixa-linha { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; padding-block: 6px; }
.faixa a { color: var(--muted); }

/* Placar */
.placar { padding-block: 40px 8px; display: flex; flex-direction: column; gap: 22px; }
.n { font-family: var(--f-numeros); font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; line-height: .86; }
.placar-total { font-size: clamp(88px, 15vw, 168px); display: block; }
.placar-rotulo { font: 700 clamp(18px, 2.4vw, 24px)/1.3 var(--f-corpo); max-width: 34ch; margin-top: 10px; }
.sub { color: var(--muted); margin: 8px 0 0; font-size: 15px; }
.sub strong { color: var(--ink); }

.areas { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.area {
  width: 100%; height: 100%; display: flex; flex-direction: column; gap: 10px; text-align: left; cursor: pointer;
  padding: 14px 14px 16px; border: 1px solid var(--line); border-top: 4px solid var(--cor); border-radius: 4px 4px 14px 14px;
  background: var(--surface); color: var(--ink); font: inherit; transition: transform .15s, box-shadow .15s;
}
.area:hover { transform: translateY(-2px); box-shadow: var(--sombra); }
.area .n { font-size: 44px; color: var(--cor); }
.area-nome { font: 700 14px/1.3 var(--f-corpo); }
.area-explica { font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.area.valor { cursor: default; border-top-color: var(--ink); }
.area.valor:hover { transform: none; box-shadow: none; }
.area.valor .n { color: var(--ink); font-size: 40px; }

.fonte { color: var(--muted); font-size: 13px; margin: 0; }
.fonte a { color: inherit; }

/* Blocos */
.bloco { padding-top: 56px; }
.eyebrow { margin: 0 0 6px; font: 500 12px var(--f-mono); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.titulo { font: 800 clamp(26px, 3.4vw, 34px)/1.12 var(--f-corpo); letter-spacing: -0.015em; }

.aviso { margin-top: 32px; background: var(--warn-bg); color: var(--warn-ink); border-radius: 16px; padding: 18px 22px; }
.aviso h2 { font-size: 20px; }

.filtros { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.filtros label { flex: 0 1 190px; }
.filtros .busca { flex: 1 1 300px; position: relative; }
.busca svg { position: absolute; left: 16px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.busca .campo { padding-left: 42px; }
select.campo { appearance: none; padding-right: 36px; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: right 18px top 50%, right 13px top 50%; background-size: 5px 5px; background-repeat: no-repeat; }

.categorias { display: flex; gap: 6px; overflow-x: auto; margin: 12px 0 4px; padding-bottom: 2px; }
.chip {
  display: inline-flex; align-items: center; gap: 7px; flex: none; min-height: 40px; padding: 0 14px;
  border: 1.5px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink);
  font: 600 13px var(--f-corpo); cursor: pointer; transition: background .2s, color .2s, border-color .2s;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.ponto { width: 9px; height: 9px; border-radius: 50%; background: var(--cor, var(--muted)); flex: none; }

.contagem { color: var(--muted); font-size: 14px; margin: 10px 0 14px; }
.filtro-data { background: var(--warn-bg); color: var(--warn-ink); border-radius: 999px; padding: 8px 16px; display: inline-block; margin: 8px 0 0; font-size: 14px; }
.filtro-data .link-botao { color: inherit; font-weight: 700; }

/* Cartões de ato */
.lista { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 10px; }
.ato { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px 14px; position: relative; overflow: hidden; }
.ato::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--cor, var(--c-outros)); }
.ato:target { box-shadow: 0 0 0 3px var(--hi); }
.ato .meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; font: 500 12px var(--f-mono); letter-spacing: .03em; color: var(--muted); }
.ato .tipo { display: inline-flex; align-items: center; gap: 7px; color: var(--cor); text-transform: uppercase; letter-spacing: .07em; }
.ato .tipo::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.ato .resumo { margin: 8px 0 4px; font: 600 17px/1.45 var(--f-corpo); }
.curto { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; overflow: hidden; }
.assunto.curto, .curto.duas-linhas { -webkit-line-clamp: 2; line-clamp: 2; }
.ato .resumo.curto { font-size: 15px; line-height: 1.4; }
.na-lista .importa { font-size: 14px; padding: 8px 12px; }
.na-lista .valor .n { font-size: 24px; }
.nota-ia { margin: 6px 0 12px; font-size: 13px; color: var(--muted); }
.selo-ia { display: inline-block; vertical-align: 2px; font: 500 11.5px var(--f-mono); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 1px 8px; }
.ato .importa { margin: 8px 0; padding: 10px 14px; background: var(--bg); border-radius: 12px; font-size: 15px; }
.ato .importa b { font-weight: 700; }
.ato .valor { margin: 8px 0 2px; display: flex; align-items: baseline; gap: 8px; }
.ato .valor .rotulo { font: 500 12px var(--f-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.ato .valor .n { font-size: 30px; line-height: 1; }
.ato .documento { margin: 6px 0 0; font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.ato details { margin-top: 8px; }
.ato summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: 14px; list-style: none; padding: 8px 0; }
.ato summary::-webkit-details-marker { display: none; }
.ato summary::before { content: ""; display: inline-block; width: 6px; height: 6px; margin: 0 9px 2px 1px; border-right: 2px solid; border-bottom: 2px solid; transform: rotate(-45deg); transition: transform .2s; }
.ato details[open] summary::before { transform: rotate(45deg); }
.ato pre { white-space: pre-wrap; overflow-wrap: anywhere; font: 13px/1.6 var(--f-mono); background: var(--bg); padding: 12px 14px; border-radius: 12px; margin: 8px 0 0; }
.ato .acoes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.ato .acoes .botao { min-height: 40px; font-size: 13px; padding: 0 14px; }
.ato .acoes .botao:not(:hover) { border-color: var(--line); }

.mais { display: flex; margin: 20px auto 0; min-width: 200px; }

/* Glossário e passos */
.glossario { margin: 20px 0 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.glossario > div { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; }
.glossario dt { font: 800 16px var(--f-corpo); }
.glossario dd { margin: 6px 0 0; color: var(--muted); font-size: 15px; }
.glossario dd strong { color: var(--ink); }

.passos { list-style: none; counter-reset: passo; margin: 20px 0 0; padding: 0; display: grid; gap: 10px; }
.passos li { counter-increment: passo; position: relative; padding-left: 72px !important; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; }
.passos li::before { content: counter(passo); position: absolute; left: 20px; top: 18px; font: 800 48px/.86 var(--f-numeros); color: var(--hi); }
.dica { margin: 14px 0 0; padding: 12px 16px; border-radius: 12px; background: var(--warn-bg); color: var(--warn-ink); font-size: 15px; }
.dica strong { color: inherit; }

/* Rodapé escuro */
.rodape { background: var(--ink); color: var(--bg); margin-top: 72px; font-size: 14px; }
.rodape a { color: var(--bg); }
.rodape .logo { color: var(--bg); }
.rodape .logo-em { color: inherit; opacity: .6; }
.rodape p { opacity: .88; }
.rodape-grade { display: grid; gap: 28px; grid-template-columns: 1fr; padding-block: 40px 28px; }
.rodape-titulo { font: 700 12px var(--f-corpo); text-transform: uppercase; letter-spacing: .06em; opacity: .6 !important; margin: 0 0 10px; }
.rodape-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rodape-links a { text-decoration: none; opacity: .88; }
.rodape-links a:hover { opacity: 1; text-decoration: underline; }
.rodape-creditos { border-top: 1px solid color-mix(in srgb, var(--bg) 25%, transparent); padding-block: 18px 28px; font-size: 12px; opacity: .6; }

@media (min-width: 720px) {
  .rodape-grade { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.4fr) minmax(0, .7fr) minmax(0, .7fr); }
}

@media (max-width: 720px) {
  /* No celular, o menu vira uma barra fixa no rodapé (ícone + nome curto), ao alcance do polegar, e o topo
     deixa de ser fixo: sobra mais tela para o conteúdo. */
  html { scroll-padding-top: 16px; }
  .topo { position: static; }
  .logo { flex: 1; }
  .secoes {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 2px; overflow: visible;
    padding: 4px max(4px, env(safe-area-inset-right)) max(4px, env(safe-area-inset-bottom)) max(4px, env(safe-area-inset-left));
    background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -4px 16px #14181d14;
  }
  .secoes a { flex-direction: column; justify-content: center; gap: 3px; min-height: 56px; padding: 0 2px; border-radius: 12px; font-size: 11.5px; }
  .secoes a[aria-current="page"] { background: var(--bg); color: var(--ink); font-weight: 800; }
  .secao-icone { display: block; width: 24px; height: 24px; }
  .nome-curto { display: inline; }
  .nome-longo { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .rodape { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .subtitulo { scroll-margin-top: 16px; }
  .faixa a { display: none; }
  .placar { padding-top: 28px; }
  .area .n { font-size: 38px; }
  .areas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filtros .busca { flex-basis: 100%; }
  .ato.na-lista { padding: 12px 14px 12px 16px; }
  .filtros label { flex: 1 1 110px; }
  .filtros .botao { flex: none; }
  /* Só a lupa, para os dois seletores caberem inteiros ao lado. */
  .buscar { width: 44px; padding: 0; }
  .filtros .buscar svg { display: block; }
  select.campo { padding: 0 30px 0 14px; font-size: 14px; background-position: right 16px top 50%, right 11px top 50%; }
  .buscar span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .passos li { padding-left: 54px !important; }
  .passos li::before { left: 16px; font-size: 38px; }
}

/* Câmara */
.subtitulo { font: 800 20px/1.2 var(--f-corpo); margin: 36px 0 0; scroll-margin-top: 120px; }
.numeros { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.numeros li { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: var(--muted); }
.numeros .n { font-size: 44px; color: var(--ink); }

.vereadores { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.vereador {
  width: 100%; height: 100%; display: grid; grid-template-columns: 72px minmax(0, 1fr); align-items: start; gap: 14px; text-align: left; cursor: pointer;
  padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--surface); color: var(--ink); font: inherit;
  transition: border-color .15s, box-shadow .15s;
}
.vereador:hover { border-color: var(--ink); }
.vereador[aria-pressed="true"] { border-color: var(--ink); box-shadow: 0 0 0 2px var(--ink) inset; }
.vereador-texto { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.vereador-foto {
  width: 72px; height: 96px; border-radius: 12px; overflow: hidden; background: var(--bg);
  display: grid; place-items: center; font: 800 32px var(--f-numeros); color: var(--muted);
}
.vereador-foto img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; display: block; }
.vereador-topo { display: flex; flex-wrap: wrap; gap: 6px; }
.partido, .cargo { font: 500 12px var(--f-mono); letter-spacing: .05em; text-transform: uppercase; border-radius: 999px; padding: 2px 8px; }
.partido { border: 1px solid var(--line); color: var(--muted); }
.cargo { background: var(--ink); color: var(--bg); }
.vereador-nome { font: 700 16px/1.3 var(--f-corpo); }
.vereador-dado { font-size: 13.5px; color: var(--muted); }
.vereador-dado b { color: var(--ink); font-weight: 600; }

.votacao .materia { margin-bottom: 2px; }
.votacao .assunto { margin: 4px 0 0; font-size: 15px; }
.votacao .resumo-votacao { margin: 6px 0 0; font-size: 16px; }
.votacao .assunto.ementa { font-size: 13px; color: var(--muted); }
.placar-votacao { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 12px 0 0; }
.resultado { font: 500 12px var(--f-mono); letter-spacing: .06em; text-transform: uppercase; border-radius: 999px; padding: 3px 10px; background: var(--bg); border: 1px solid var(--line); }
.resultado.aprovada { background: color-mix(in srgb, var(--c-decreto) 14%, transparent); border-color: transparent; color: var(--c-decreto); }
.barra { display: flex; gap: 2px; flex: 1 1 160px; max-width: 260px; height: 8px; border-radius: 999px; overflow: hidden; background: var(--line); }
.barra .sim { background: var(--c-decreto); }
.barra .nao { background: var(--c-contrato); }
.barra .abstencao { background: var(--hi); }
.contagem-votos { font-size: 13.5px; color: var(--muted); }
.divergencias { margin: 8px 0 0; font-size: 14px; }
.voto-vereador { margin: 10px 0 0; padding: 8px 12px; border-radius: 10px; background: var(--bg); font-size: 14.5px; border-left: 4px solid var(--muted); }
.voto-vereador.sim { border-left-color: var(--c-decreto); }
.voto-vereador.nao { border-left-color: var(--c-contrato); }
.voto-vereador.abstencao { border-left-color: var(--hi); }
.votos-lista { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 2px 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); font-size: 14px; }
.votos-lista li { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; border-bottom: 1px solid var(--line); }
.votos-lista li span:last-child { color: var(--muted); white-space: nowrap; }
.votos-lista li.sim span:last-child { color: var(--c-decreto); }
.votos-lista li.nao span:last-child { color: var(--c-contrato); font-weight: 600; }
.votos-lista li.abstencao span:last-child { color: var(--hi); font-weight: 600; }
.camara-fonte { margin-top: 16px; }

/* Prefeitura */
.vinculos .explica { font-size: 13px; margin-top: -4px; }
.folha-meses { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 2px; }
.folha-meses li {
  display: grid; grid-template-columns: 76px minmax(0, 1fr) 84px 110px; align-items: center; gap: 12px;
  padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px;
}
.folha-meses .mes { font: 500 12px var(--f-mono); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.folha-meses .trilho { height: 10px; }
.folha-meses .preenche { display: block; height: 100%; background: var(--accent); border-radius: 0 4px 4px 0; }
.folha-meses .total { font-weight: 700; text-align: right; }
.folha-meses .pessoas { color: var(--muted); font-size: 13px; }
.chefias { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.chefia {
  width: 100%; height: 100%; display: flex; flex-direction: column; gap: 4px; text-align: left; cursor: pointer;
  padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink); font: inherit;
  border-left: 4px solid var(--c-pessoal); transition: border-color .15s;
}
.chefia:hover { border-color: var(--ink); border-left-color: var(--c-pessoal); }
/* O cartão inteiro é um link (leva ao cargo na lista abaixo): sem sublinhado, com uma seta para indicar o toque. */
.chefia { position: relative; padding-right: 30px; text-decoration: none; }
.chefia::after { content: "›"; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-size: 22px; line-height: 1; color: var(--muted); }
.chefia-area { font: 500 12px var(--f-mono); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.chefia-nome { font: 700 16px/1.3 var(--f-corpo); }
.chefia-salario { font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.chefia-aviso, .confianca .mudanca { background: var(--warn-bg); color: var(--warn-ink); border-radius: 8px; font-size: 13px; }
.chefia-aviso { padding: 3px 8px; margin-top: 4px; align-self: flex-start; font-weight: 600; }
.confianca .mudanca { margin: 8px 0 0; padding: 8px 12px; font-size: 14px; }
.confianca .pessoa { margin: 0; font-size: 15px; }
.no-diario-link { display: inline-block; padding: 10px 0 2px; font-size: 14px; font-weight: 600; }
.confianca .valor .liquido { font-size: 13.5px; color: var(--muted); }
.no-diario { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 10px; }
.no-diario li { background: var(--bg); border-radius: 12px; padding: 10px 14px; font-size: 14px; }
.no-diario .quando { font: 500 12px var(--f-mono); color: var(--muted); letter-spacing: .03em; }
.no-diario p { margin: 4px 0; overflow-wrap: anywhere; }
.no-diario a { color: var(--accent); font-weight: 600; }
.sairam { margin-top: 14px; }
.sairam > summary, .texto-publicado > summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: 15px; padding: 8px 0; }
.texto-publicado { margin-top: 20px; }
.cargos { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 6px; }
.cargos li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; align-items: baseline;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px;
}
.cargo-nome { font-weight: 600; overflow-wrap: anywhere; }
.cargo-natureza { font: 500 12px var(--f-mono); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.cargo-dados { grid-column: 1 / -1; font-size: 13.5px; color: var(--muted); }
.prefeitura-fonte { margin-top: 16px; }

/* Eleição (TSE) */
.promessas { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 6px; }
.promessas li { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 12px; padding: 10px 14px; }
.promessa-area { font: 500 12px var(--f-mono); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.promessa-titulo { margin: 2px 0 0; font-weight: 600; }
.promessa-objetivo { margin: 4px 0 0; font-size: 14px; color: var(--muted); }
.promessa-objetivo:empty { display: none; }
#plano-fonte { margin-top: 12px; }
.bens-lista { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 2px; font-size: 14px; }
.bens-lista li { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; border-bottom: 1px solid var(--line); }
.bens-lista li span:first-child { overflow-wrap: anywhere; }
.bens-lista li span:last-child { white-space: nowrap; font-weight: 600; }

@media (max-width: 720px) {
  .numeros { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .numeros .n { font-size: 38px; }
  .folha-meses li { grid-template-columns: 60px minmax(0, 1fr) 72px; }
  .folha-meses .pessoas { display: none; }
  /* Quem chefia: uma faixa baixa por diretor, com nome e salário na mesma linha. */
  .chefias { gap: 6px; }
  .chefia { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 0 10px; padding: 8px 30px 8px 12px; }
  .chefia-area { flex-basis: 100%; }
  .chefia-nome { flex: 1; font-size: 15px; }
  .chefia-salario { white-space: nowrap; font-size: 13.5px; }
}

/* ---------- Site gerado no servidor (web/): cores por classe, porque a CSP não deixa usar style="" ---------- */
.cor-licitacao { --cor: var(--c-licitacao); }
.cor-contrato { --cor: var(--c-contrato); }
.cor-pessoal { --cor: var(--c-pessoal); }
.cor-concurso { --cor: var(--c-concurso); }
.cor-lei { --cor: var(--c-lei); }
.cor-decreto { --cor: var(--c-decreto); }
.cor-portaria { --cor: var(--c-portaria); }
.cor-outros { --cor: var(--c-outros); }
.cor-destaque { --cor: var(--accent); }
.ato .resumo a { color: inherit; text-decoration: none; }
.ato .resumo a:hover { text-decoration: underline; }
.texto-ato { white-space: pre-wrap; overflow-wrap: anywhere; font: 13px/1.6 var(--f-mono); background: var(--surface); border: 1px solid var(--line); padding: 14px 16px; border-radius: 12px; margin: 10px 0 0; }
.acoes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.paginacao { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 18px; color: var(--muted); font-size: 14px; }
.filtros .caixa { display: flex; align-items: center; gap: 8px; font-size: 14px; flex: 0 1 auto; }
.filtros .botao { min-height: 44px; }
.buscar svg { display: none; width: 18px; height: 18px; }
.chip { text-decoration: none; color: inherit; }
.area { text-decoration: none; color: inherit; }
.vereador { text-decoration: none; }
.vereador-pagina { cursor: default; margin-top: 12px; }
.vereador-pagina .titulo { margin: 4px 0; }
.votos-vereador small { color: var(--muted); margin-left: 6px; }
.votos-lista li.ausente span:last-child, .votos-lista li.nao-votou span:last-child { color: var(--muted); }
.folha-meses svg.trilho { width: 100%; height: 10px; display: block; }
.folha-meses .preenche { fill: var(--accent); }
.area-plano { margin-top: 10px; }
.area-plano > summary { cursor: pointer; font-weight: 700; padding: 10px 0; }

/* Aviso de consentimento (LGPD): modal sobre o site, que fica escurecido e inerte até a pessoa escolher.
   Aceitar e Recusar com o mesmo peso. */
.consentimento {
  width: min(560px, calc(100% - 32px)); max-height: calc(100dvh - 32px); overflow: auto;
  padding: 0; border: 1.5px solid var(--ink); border-radius: 16px;
  background: var(--surface); color: var(--ink); box-shadow: var(--sombra);
}
.consentimento::backdrop { background: #0c1015b3; backdrop-filter: blur(6px); }
html:has(.consentimento[open]) { overflow: hidden; }
.consentimento-caixa { display: grid; gap: 16px; padding: 24px; }
.consentimento-titulo { margin: 0; font: 800 22px/1.2 var(--f-marca); }
.consentimento p { margin: 0; font-size: 15px; line-height: 1.55; }
.consentimento-acoes { display: flex; gap: 10px; }
.consentimento-acoes .botao { flex: 1; }
.rodape-botao { color: var(--bg); opacity: .88; text-decoration: none; font-size: inherit; }
.rodape-botao:hover { opacity: 1; text-decoration: underline; }
