/* ==========================================================================
   RELATÓRIO GERENCIAL — NORDESTE SERVIÇOS · VALE SOSSEGO · SETEMBRO/2026
   Folha de estilo única do projeto.

   Sumário
     1. Variáveis de tema           12. Painel 01 — Capa
     2. Base / reset                13. Painéis escuros
     3. Cabeçalho                   14. Texto narrativo
     4. Barra de ferramentas        15. Galeria de fotos / DDS
     5. Menu lateral                16. Matriz de riscos
     6. Estrutura dos painéis       17. Rodapé e auxiliares
     7. Grades de layout            18. Responsivo
     8. KPIs e semáforo             19. Acessibilidade
     9. Destaques                   20. Impressão / PDF
    10. Gráficos                    21. Modo apresentação
    11. Tabelas e notas             22. Janela de detalhamento
                                    23. Menu fluido e transições
                                    24. Tela de senha

   A ordem dos blocos importa (regras posteriores sobrescrevem anteriores).
   ========================================================================== */
/* ========================================================================
   1. VARIÁVEIS DE TEMA (cores, sombra e altura do cabeçalho)
   Altere aqui as cores da marca; todo o restante do CSS usa estas variáveis.
   --header-height é atualizado via JS (navegacao.js) conforme a altura real do topo.
   ======================================================================== */
:root {
  --ink: #1f2b33;
  --brown: #98511f;
  --brown2: #6b371e;
  --gold: #ffca05;
  --orange: #f39a18;
  --cream: #f6f4ef;
  --card: #fff;
  --line: #e5ddd2;
  --green: #13885f;
  --red: #c8443b;
  --amber: #d89b00;
  --muted: #6c6762;
  --good-bg: #eaf4ed;
  --warn-bg: #fff7dd;
  --bad-bg: #fcedeb;
  --shadow: 0 5px 20px #6035130b;
  --header-height: 108px;
}

/* ========================================================================
   2. BASE / RESET
   Box-sizing, fonte padrão, botões, links e foco acessível.
   ======================================================================== */
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font:
    16px/1.5 "Segoe UI",
    Calibri,
    Arial,
    sans-serif;
}
button,
a,
summary {
  -webkit-tap-highlight-color: transparent;
}
button {
  font: inherit;
  cursor: pointer;
}
button:disabled {
  cursor: default;
  opacity: 0.4;
}
a {
  color: var(--brown);
}
:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}

/* ========================================================================
   3. CABEÇALHO (topbar)
   Link "pular para o conteúdo", logo, título do contrato e ciclo.
   ======================================================================== */
.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 100;
  background: #fff;
  padding: 10px;
}
.skip-link:focus {
  top: 10px;
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 26px;
  background: #fff;
  padding: 8px 28px;
  min-height: 108px;
  border-bottom: 5px solid var(--gold);
  box-shadow: 0 3px 15px #3f2a1d12;
}
.topbar:after {
  content: "";
  height: 5px;
  width: 29%;
  background: var(--brown);
  position: absolute;
  right: 0;
  bottom: -5px;
}
.brand {
  width: 310px;
  height: auto;
  flex-shrink: 0;
  display: block;
}
.brand-title {
  flex: 1;
}
.brand-title b {
  font-size: 22px;
  display: block;
}
.brand-title span {
  font-size: 13px;
  color: var(--brown);
}
.cycle {
  text-align: right;
  font-size: 13px;
  color: var(--muted);
}
.cycle strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
}

/* ========================================================================
   4. BARRA DE FERRAMENTAS (toolbar)
   Botões Visão completa / Modo apresentação, paginador e Imprimir.
   ======================================================================== */
.toolbar {
  position: sticky;
  top: var(--header-height);
  z-index: 35;
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 11px 28px;
  background: #fffdfa;
  border-bottom: 1px solid var(--line);
}
.toolbar button {
  border: 1px solid #ddcdbc;
  border-radius: 7px;
  padding: 7px 12px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
}
.toolbar .active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--ink);
}
.toolbar .spacer {
  flex: 1;
}
.progress-label {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}
.pager {
  display: flex;
  gap: 8px;
  align-items: center;
}
.pager[hidden] {
  display: none;
}

/* ========================================================================
   5. MENU LATERAL (sidebar)
   Lista dos 15 painéis; o item ativo recebe aria-current="page".
   ======================================================================== */
.menu-button {
  display: none;
}
.sidebar {
  position: fixed;
  top: calc(var(--header-height) + 58px);
  bottom: 0;
  left: 0;
  width: 220px;
  padding: 22px 12px 28px 20px;
  overflow: auto;
  border-right: 1px solid var(--line);
  background: #f3efe7;
  z-index: 30;
}
.sidebar h2 {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--brown2);
  margin: 0 0 14px 12px;
}
.sidebar a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 39px;
  padding: 8px 9px;
  text-decoration: none;
  color: var(--ink);
  border-radius: 7px;
  border-left: 3px solid transparent;
  font-size: 13px;
  line-height: 1.25;
  margin: 3px 0;
}
.sidebar a span {
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.sidebar a:hover {
  background: #fff9df;
}
.sidebar a[aria-current="page"] {
  background: #fff;
  border-left-color: var(--gold);
  font-weight: 750;
  box-shadow: var(--shadow);
}
.sidebar .legend-small {
  font-size: 11px;
  color: var(--muted);
  margin: 22px 12px 0;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

/* ========================================================================
   6. ÁREA PRINCIPAL E ESTRUTURA DOS PAINÉIS
   Cada painel é uma <section class="section"> carregada de pages/*.html.
   ======================================================================== */
main {
  margin-left: 220px;
  padding: 24px 28px 40px;
  max-width: 1760px;
}
.section {
  background: #fffdfa;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 27px;
  margin: 0 0 28px;
  box-shadow: var(--shadow);
  scroll-margin-top: 190px;
}
.section-header {
  margin-bottom: 23px;
  position: relative;
}
.section-number {
  display: block;
  color: var(--brown);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.section h2 {
  font-size: 30px;
  line-height: 1.2;
  margin: 0 0 8px;
  letter-spacing: -0.5px;
}
.section-subtitle {
  color: var(--muted);
  font-size: 15px;
  max-width: 1120px;
  margin: 0;
}
.section h3 {
  font-size: 19px;
  margin: 0 0 14px;
  line-height: 1.3;
}
.print-brand {
  display: none;
}

/* ========================================================================
   7. GRADES DE LAYOUT
   Colunas (cols-2/3/4) e pilhas usadas dentro dos painéis.
   ======================================================================== */
.grid {
  display: grid;
  gap: 16px;
}
.cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.split-wide {
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
}
.stack {
  display: grid;
  gap: 15px;
}

/* ========================================================================
   8. COMPONENTES: KPIs, CAIXAS, CHAVE-VALOR E SEMÁFORO
   Classes .good / .warn / .bad = verde / amarelo / vermelho.
   ======================================================================== */
.kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 13px;
  margin: 18px 0;
}
.kpis.four {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.kpi {
  background: #fff;
  border: 1px solid var(--line);
  border-left: 4px solid #c9c2b8;
  border-radius: 9px;
  padding: 17px 18px;
  min-height: 116px;
}
.kpi.good {
  border-left-color: var(--green);
}
.kpi.warn {
  border-left-color: var(--amber);
}
.kpi.bad {
  border-left-color: var(--red);
}
.kpi .label {
  color: var(--muted);
  font-weight: 650;
  font-size: 13px;
  display: block;
  margin-bottom: 8px;
}
.kpi strong {
  font-size: 33px;
  letter-spacing: -0.9px;
  line-height: 1.15;
  display: block;
  font-variant-numeric: tabular-nums;
}
.kpi.money strong {
  font-size: clamp(18px, 1.45vw, 25px);
  letter-spacing: -0.5px;
  white-space: nowrap;
}
.kpi.wide-number strong {
  font-size: 25px;
}
.kpi small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 9px;
}
.box {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  min-width: 0;
}
.box p {
  margin: 8px 0;
}
.box .small {
  font-size: 13px;
  color: var(--muted);
}
.key-value {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  font-size: 15px;
  align-items: baseline;
}
.key-value .key {
  color: var(--muted);
}
.key-value .value {
  font-weight: 750;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-right: 8px;
  border-radius: 50%;
  background: #aaa;
  flex: none;
}
.good .dot,
.dot.good {
  background: var(--green);
}
.warn .dot,
.dot.warn {
  background: var(--amber);
}
.bad .dot,
.dot.bad {
  background: var(--red);
}
.good-text {
  color: var(--green);
}
.warn-text {
  color: var(--amber);
}
.bad-text {
  color: var(--red);
}
.brown-text {
  color: var(--brown);
}
.number-lg {
  font-size: 43px;
  letter-spacing: -1px;
  font-weight: 750;
  color: var(--orange);
  line-height: 1.2;
}

/* ========================================================================
   9. DESTAQUES (callouts) E LEGENDA DO SEMÁFORO
   ======================================================================== */
.callout {
  padding: 12px 15px;
  border-left: 4px solid var(--amber);
  border-radius: 7px;
  margin: 17px 0;
  background: var(--warn-bg);
  font-size: 14px;
}
.callout.good {
  border-color: var(--green);
  background: var(--good-bg);
}
.callout.bad {
  border-color: var(--red);
  background: var(--bad-bg);
}
.traffic-legend {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 12px;
  margin-top: 17px;
  color: var(--muted);
}
.traffic-legend b {
  font-weight: 650;
}

/* ========================================================================
   10. GRÁFICOS (SVG embutido nos painéis)
   Cartões, eixos, rótulos, legendas e donuts.
   ======================================================================== */
.chart-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 19px;
  min-width: 0;
}
.chart-card h3 {
  font-size: 18px;
  margin-bottom: 9px;
}
.chart-caption {
  font-size: 12px;
  color: var(--muted);
  margin: 10px 0 0;
  line-height: 1.5;
}
.chart-scroll {
  overflow-x: auto;
  padding: 4px 0 8px;
}
.chart-svg {
  display: block;
  width: 100%;
  height: auto;
  min-width: 570px;
  overflow: visible;
}
.chart-svg.donut-svg {
  min-width: 0;
  max-width: 370px;
  margin: auto;
}
.chart-svg .axis {
  fill: #6c6762;
  font-size: 15px;
}
.chart-svg .data-label {
  fill: #1f2b33;
  font-size: 16px;
  font-weight: 700;
}
.chart-svg .gridline {
  stroke: #e5ddd2;
  stroke-width: 1;
}
.chart-svg .value-light {
  fill: #fff;
  font-weight: 700;
  font-size: 18px;
}
.data-mark {
  cursor: default;
  transition: opacity 0.12s;
}
.data-mark:hover,
.data-mark:focus {
  filter: brightness(0.92);
  outline: none;
}
.chart-key {
  display: flex;
  gap: 17px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--muted);
  margin: 8px 0;
}
.chart-key .swatch {
  width: 12px;
  height: 12px;
  display: inline-block;
  margin-right: 6px;
  border-radius: 2px;
  vertical-align: middle;
}
.chart-key .line-swatch {
  width: 19px;
  height: 3px;
  vertical-align: middle;
  display: inline-block;
  margin-right: 6px;
}
.donut-legend {
  list-style: none;
  padding: 0;
  margin: 12px 0;
  display: grid;
  gap: 6px;
}
.donut-legend li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
}
.donut-legend strong {
  font-variant-numeric: tabular-nums;
}

/* ========================================================================
   11. TABELAS, FONTES E NOTAS (<details class="notes">)
   ======================================================================== */
.data-details {
  border-top: 1px solid var(--line);
  margin-top: 14px;
  padding-top: 10px;
  font-size: 12px;
}
.data-details summary,
.notes summary {
  cursor: pointer;
  color: var(--brown);
  font-weight: 650;
  padding: 3px 0;
}
.table-scroll {
  overflow: auto;
  max-width: 100%;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 14px;
  line-height: 1.4;
}
th {
  background: var(--brown2);
  color: #fff;
  font-weight: 650;
}
th,
td {
  padding: 11px 12px;
  border: 1px solid #dfd3c3;
  vertical-align: top;
}
tbody tr:nth-child(even) {
  background: #f3efe7;
}
td.num,
th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.data-table {
  font-size: 12px;
  margin: 10px 0;
}
.data-table th,
.data-table td {
  padding: 7px 8px;
}
.source {
  font-size: 11px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  padding-top: 12px;
  margin-top: 21px;
  line-height: 1.6;
}
.notes {
  font-size: 12px;
  margin: 11px 0 0;
}
.notes-content {
  background: #f7f4ee;
  border: 1px solid var(--line);
  border-radius: 6px;
  margin: 9px 0 0;
  padding: 15px;
  line-height: 1.65;
}
.notes-content p {
  white-space: pre-line;
  margin: 0 0 12px;
}
.notes-content p:last-child {
  margin-bottom: 0;
}

/* ========================================================================
   12. PAINEL 01 — CAPA EXECUTIVA
   ======================================================================== */
.cover {
  padding: 0;
  overflow: hidden;
  background: #fff;
}
.cover-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 555px;
}
.cover-copy {
  padding: 38px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}
.cover-copy .eyebrow {
  color: var(--brown);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.5px;
  margin: 0 0 23px;
}
.cover h1 {
  font-size: clamp(37px, 3.6vw, 59px);
  line-height: 1.08;
  letter-spacing: -1.5px;
  margin: 0 0 22px;
  max-width: 550px;
}
.cover-copy .site {
  font-size: 29px;
  color: var(--brown);
  font-weight: 750;
  margin: 0 0 26px;
}
.cover-copy .contract {
  margin: 0 0 26px;
  font-size: 17px;
  line-height: 1.65;
}
.cover-copy .period {
  font-size: 20px;
  font-weight: 750;
  margin-bottom: 2px;
}
.cover-copy .cycle-text {
  font-size: 13px;
  color: var(--muted);
}
.cover-image {
  width: 100%;
  height: 100%;
  min-height: 555px;
  object-fit: cover;
  border-left: 7px solid var(--gold);
}
.cover .source {
  margin: 0;
  padding: 17px 25px;
  background: #fffdfa;
}

/* ========================================================================
   13. PAINÉIS ESCUROS (.dark-section) — usados nos painéis 03 e 15
   ======================================================================== */
.dark-section {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.dark-section .section-number,
.dark-section h3 {
  color: var(--gold);
}
.dark-section .section-subtitle,
.dark-section .source {
  color: #d2ccc3;
}
.dark-section .source {
  border-color: #536069;
}
.dark-section .number-lg {
  color: var(--gold);
  font-size: 62px;
}
.dark-section .box {
  background: #25343d;
  border-color: #526069;
}
.dark-section .box p {
  color: #fff;
}
.dark-section .notes summary {
  color: var(--gold);
}
.dark-section .notes-content {
  background: #25343d;
  border-color: #526069;
  color: #eee;
}
.dark-section .kpi {
  background: #25343d;
  border-color: #526069;
}
.dark-section .kpi strong {
  color: var(--gold);
}
.dark-section .kpi .label,
.dark-section .kpi small {
  color: #ded6cb;
}
.dark-section .callout {
  background: #25343d;
  border-color: var(--gold);
}

/* ========================================================================
   14. TEXTO NARRATIVO
   ======================================================================== */
.narrative h3 {
  font-size: 16px;
  letter-spacing: 0.4px;
  color: var(--brown);
  margin: 0 0 8px;
}
.narrative p {
  margin: 0 0 20px;
}
.dark-section .narrative h3 {
  color: var(--gold);
}

/* ========================================================================
   15. GALERIA DE FOTOS (painel 11) E IMAGENS DE DDS (painel 12)
   ======================================================================== */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 13px;
}
.photo-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  min-width: 0;
}
.photo-card img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  display: block;
}
.photo-copy {
  padding: 16px;
}
.photo-copy h3 {
  color: var(--brown);
  font-size: 16px;
  margin-bottom: 10px;
}
.photo-copy h4 {
  font-size: 16px;
  line-height: 1.4;
  margin: 0 0 16px;
  min-height: 69px;
}
.photo-copy .time {
  font-size: 12px;
  color: var(--muted);
}
.photo-copy .benefit {
  font-size: 13px;
  margin: 10px 0 0;
}
.photo-copy .benefit b {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 5px;
}
.dds-image {
  width: 100%;
  height: 245px;
  object-fit: cover;
  display: block;
  border-radius: 7px;
  margin-bottom: 20px;
}

/* ========================================================================
   16. MATRIZ DE RISCOS (painel 13) E PÍLULAS DE STATUS
   ======================================================================== */
.matrix {
  table-layout: fixed;
  text-align: center;
}
.matrix th,
.matrix td {
  padding: 0;
  height: 64px;
  vertical-align: middle;
  text-align: center;
}
.matrix td {
  font-size: 13px;
  font-weight: 750;
}
.matrix .score-good {
  background: var(--good-bg);
  color: var(--green);
}
.matrix .score-warn {
  background: var(--warn-bg);
  color: var(--amber);
}
.matrix .score-bad {
  background: var(--bad-bg);
  color: var(--red);
}
.matrix .row-heading {
  background: #f3efe7;
  color: var(--ink);
  font-weight: 650;
}
.matrix-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
  margin: 10px 0;
}
.pill {
  display: inline-block;
  border-radius: 20px;
  padding: 4px 10px;
  background: #f3efe7;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}
.risk-score {
  font-weight: 750;
}
.risk-score.bad {
  color: var(--red);
}
.risk-score.warn {
  color: var(--amber);
}

/* ========================================================================
   17. RODAPÉ, MODO APRESENTAÇÃO (base) E ELEMENTOS AUXILIARES
   ======================================================================== */
.report-end {
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  padding: 10px 0 20px;
}
.tooltip {
  display: none;
  position: fixed;
  z-index: 90;
  background: #1f2b33;
  color: white;
  border: 1px solid #ffca0560;
  box-shadow: 0 8px 28px #0003;
  max-width: 360px;
  padding: 12px 15px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-line;
  pointer-events: none;
}
.presentation main {
  max-width: none;
}
.presentation .section {
  display: none;
}
.presentation .section.current {
  display: block;
  margin-bottom: 0;
  min-height: calc(100vh - 240px);
}
.presentation .report-end {
  display: none;
}
.presentation .source {
  margin-top: 18px;
}
.nav-backdrop {
  display: none;
}
.mobile-hint {
  display: none;
}
.noscript {
  padding: 15px;
  background: var(--warn-bg);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

/* ========================================================================
   18. RESPONSIVO
   Telas largas (>=1760px), notebooks (<=1220px), tablets (<=900px) e celulares (<=600px).
   ======================================================================== */
@media (min-width: 1760px) {
  main {
    margin-right: auto;
  }
  .section {
    padding: 34px;
  }
  .brand {
    width: 330px;
  }
}
@media (max-width: 1220px) {
  .cycle {
    display: none;
  }
  .brand {
    width: 270px;
  }
  .sidebar {
    width: 190px;
    padding-left: 12px;
  }
  main {
    margin-left: 190px;
    padding: 20px;
  }
  .section {
    padding: 23px;
  }
  .cols-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .photo-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .split-wide {
    grid-template-columns: 1fr;
  }
  .photo-copy h4 {
    min-height: 48px;
  }
  .kpis {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}
@media (max-width: 900px) {
  .topbar {
    padding: 9px 16px;
    gap: 18px;
    min-height: 94px;
  }
  .brand {
    width: 245px;
  }
  .brand-title b {
    font-size: 18px;
  }
  .brand-title span {
    font-size: 11px;
  }
  .toolbar {
    padding: 9px 16px;
    flex-wrap: wrap;
    gap: 7px;
  }
  .sidebar {
    display: none;
    top: calc(var(--header-height) + 55px);
    width: 270px;
    z-index: 60;
    box-shadow: 12px 0 28px #0002;
  }
  .sidebar.open {
    display: block;
  }
  .nav-backdrop.open {
    display: block;
    position: fixed;
    inset: var(--header-height) 0 0;
    z-index: 50;
    background: #1f2b3340;
  }
  .menu-button {
    display: inline-block;
  }
  main {
    margin-left: 0;
    padding: 18px;
  }
  .section {
    scroll-margin-top: 180px;
  }
  .cover-grid {
    min-height: 480px;
  }
  .cover-copy {
    padding: 29px;
  }
  .cover-image {
    min-height: 480px;
  }
  .cols-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .photo-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 600px) {
  body {
    font-size: 15px;
  }
  .topbar {
    gap: 12px;
    min-height: 90px;
    padding: 8px 12px;
  }
  .brand {
    width: 204px;
  }
  .brand-title b {
    font-size: 14px;
    line-height: 1.3;
  }
  .brand-title span {
    font-size: 10px;
    line-height: 1.3;
    display: block;
    margin-top: 4px;
  }
  .toolbar {
    padding: 9px 12px;
  }
  .toolbar button {
    padding: 7px 9px;
    font-size: 12px;
  }
  .toolbar .progress-label {
    display: none;
  }
  .toolbar .spacer {
    display: none;
  }
  .toolbar .print-button {
    margin-left: auto;
  }
  main {
    padding: 12px;
  }
  .section {
    padding: 19px;
    border-radius: 10px;
    margin-bottom: 20px;
  }
  .section h2 {
    font-size: 25px;
  }
  .section-subtitle {
    font-size: 13px;
  }
  .cols-2,
  .cols-3,
  .split-wide {
    grid-template-columns: 1fr;
  }
  .kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .kpis.four {
    grid-template-columns: 1fr;
  }
  .kpi {
    padding: 14px;
    min-height: 112px;
  }
  .kpi strong {
    font-size: 29px;
  }
  .kpi.wide-number strong {
    font-size: 22px;
  }
  .kpi.money strong {
    font-size: 23px;
  }
  .cover {
    padding: 0;
  }
  .cover-grid {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .cover-copy {
    padding: 29px;
  }
  .cover h1 {
    font-size: 43px;
  }
  .cover-image {
    min-height: 0;
    height: 270px;
    border-left: 0;
    border-top: 6px solid var(--gold);
  }
  .cover-copy .site {
    font-size: 26px;
    margin-bottom: 19px;
  }
  .cover-copy .contract {
    font-size: 15px;
    margin-bottom: 19px;
  }
  .cover-copy .eyebrow {
    margin-bottom: 18px;
  }
  .box,
  .chart-card {
    padding: 16px;
  }
  .photo-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .photo-card img {
    height: 165px;
  }
  .photo-copy {
    padding: 13px;
  }
  .photo-copy h4 {
    font-size: 14px;
    min-height: 66px;
  }
  .photo-copy h3 {
    font-size: 14px;
  }
  .chart-svg {
    min-width: 610px;
  }
  .chart-svg.donut-svg {
    min-width: 0;
  }
  .dark-section .number-lg {
    font-size: 48px;
  }
  .mobile-hint {
    display: block;
    color: var(--muted);
    font-size: 11px;
    margin: 0 0 9px;
  }
  .dds-image {
    height: 210px;
  }
  .matrix th,
  .matrix td {
    height: 51px;
  }
  .matrix td {
    font-size: 11px;
  }
  .traffic-legend {
    gap: 12px;
  }
  .section .data-table {
    min-width: 440px;
  }
  .source {
    font-size: 10px;
  }
  .print-brand {
    display: none;
  }
}

/* ========================================================================
   19. ACESSIBILIDADE — reduz animações quando o usuário pede
   ======================================================================== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .data-mark {
    transition: none;
  }
}

/* ========================================================================
   20. IMPRESSÃO / PDF
   Formato da página e ajustes para o botão "Imprimir / PDF".
   ======================================================================== */
@page {
  size: A3 landscape;
  margin: 12mm;
}
@media print {
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
  html {
    scroll-behavior: auto;
  }
  body {
    background: white;
    font-size: 12px;
  }
  .topbar,
  .toolbar,
  .sidebar,
  .nav-backdrop,
  .tooltip,
  .skip-link,
  .noscript,
  .report-end {
    display: none !important;
  }
  main {
    margin: 0 !important;
    padding: 0 !important;
    max-width: none !important;
  }
  .section,
  .presentation .section {
    display: block !important;
    box-shadow: none;
    margin: 0;
    padding: 18px;
    border: 0;
    border-radius: 0;
    min-height: 0;
    break-before: page;
    page-break-before: always;
    break-inside: avoid;
  }
  .section:first-child {
    break-before: auto;
    page-break-before: auto;
  }
  .section-header {
    padding-right: 220px;
    margin-bottom: 16px;
  }
  .section h2 {
    font-size: 26px;
  }
  .section-subtitle {
    font-size: 12px;
  }
  .print-brand {
    display: block;
    position: absolute;
    right: 0;
    top: 0;
    width: 210px;
    height: auto;
  }
  .cover-grid {
    min-height: 560px;
  }
  .cover-copy {
    padding: 34px;
  }
  .cover-image {
    min-height: 560px;
  }
  .cover {
    border: 1px solid var(--line);
  }
  .kpis {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
  }
  .kpis.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .kpi {
    padding: 13px;
    min-height: 93px;
  }
  .kpi strong {
    font-size: 28px;
  }
  .kpi.money strong {
    font-size: 20px;
  }
  .kpi .label {
    font-size: 12px;
  }
  .kpi small {
    font-size: 10px;
  }
  .cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .split-wide {
    grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  }
  .box,
  .chart-card {
    padding: 14px;
  }
  .chart-svg {
    min-width: 0;
    width: 100%;
    max-height: 310px;
  }
  .chart-card h3 {
    font-size: 16px;
  }
  .chart-scroll {
    overflow: visible;
  }
  .photo-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .photo-card img {
    height: 210px;
  }
  .photo-copy h4 {
    min-height: 60px;
  }
  .photo-copy {
    padding: 12px;
  }
  .photo-copy h3 {
    font-size: 14px;
  }
  .photo-copy h4 {
    font-size: 14px;
  }
  .box p {
    font-size: 13px;
  }
  .data-details,
  .notes,
  .mobile-hint {
    display: none !important;
  }
  .dds-image {
    height: 235px;
  }
  .source {
    font-size: 10px;
    padding-top: 8px;
    margin-top: 16px;
  }
  .callout {
    font-size: 12px;
    margin: 12px 0;
    padding: 9px 12px;
  }
  .dark-section {
    background: var(--ink) !important;
    color: white !important;
  }
  .table-scroll {
    overflow: visible;
  }
  .risk-table {
    font-size: 12px;
  }
  .actions-table {
    font-size: 12px;
  }
  .actions-table th,
  .actions-table td {
    padding: 8px 10px;
  }
  .matrix th,
  .matrix td {
    height: 55px;
  }
  .traffic-legend {
    font-size: 11px;
  }
  .section {
    scroll-margin-top: 0;
  }
}

/* Palco fixo do slide: o painel é medido e escalado para caber sem cortar conteúdo. */
.presentation-message[hidden],
.presentation-help[hidden],

/* ========================================================================
   21. MODO APRESENTAÇÃO (tela cheia, um painel por vez)
   O painel atual é escalado via --slide-scale (calculado em navegacao.js).
   ======================================================================== */
#slide-mode[hidden] {
  display: none !important;
}
.presentation-message {
  position: fixed;
  left: 50%;
  top: 92px;
  transform: translateX(-50%);
  z-index: 80;
  width: min(760px, 90vw);
  padding: 12px 18px;
  border: 1px solid var(--gold);
  border-radius: 8px;
  background: #fff7dd;
  color: var(--ink);
  font-size: 13px;
  box-shadow: 0 8px 24px #0003;
}
.presentation-help {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
@media screen {
  body.presentation {
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    background: #182127;
    font-size: 16px;
  }
  .presentation .topbar {
    position: fixed;
    inset: 0 0 auto;
    min-height: 0;
    height: 74px;
    padding: 8px 24px;
    gap: 24px;
  }
  .presentation .brand {
    width: 245px;
    max-height: 61px;
    object-fit: contain;
  }
  .presentation .brand-title b {
    font-size: 18px;
    line-height: 1.25;
  }
  .presentation .brand-title span {
    font-size: 12px;
  }
  .presentation .cycle {
    display: block;
    font-size: 11px;
  }
  .presentation .cycle strong {
    font-size: 14px;
  }
  .presentation .toolbar {
    position: fixed;
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    height: 62px;
    padding: 10px 24px;
    gap: 12px;
    flex-wrap: nowrap;
    border-top: 1px solid var(--line);
    border-bottom: 0;
    background: #fffdfa;
  }
  .presentation .toolbar button {
    font-size: 13px;
    padding: 8px 13px;
    white-space: nowrap;
  }
  .presentation .toolbar .spacer {
    display: block;
  }
  .presentation .toolbar .print-button,
  .presentation .menu-button,
  .presentation .sidebar,
  .presentation .nav-backdrop,
  .presentation .skip-link,
  .presentation .report-end {
    display: none !important;
  }
  .presentation .pager {
    display: flex;
    gap: 10px;
    align-items: center;
  }
  .presentation .pager .progress-label {
    display: block;
    font-weight: 700;
    color: var(--brown2);
    min-width: 58px;
    text-align: center;
  }
  .presentation #progress-label {
    display: none;
  }
  .presentation main {
    position: fixed;
    inset: 90px 20px 78px;
    max-width: none;
    margin: 0;
    padding: 0;
    min-height: 0;
    overflow: visible;
  }
  .presentation .section {
    display: none;
  }
  .presentation .section.current {
    display: block;
    position: absolute;
    left: 50%;
    top: 50%;
    width: 1440px;
    min-height: 810px;
    max-height: none;
    height: auto;
    padding: 28px 32px;
    margin: 0;
    border-radius: 10px;
    box-shadow: 0 12px 40px #0004;
    transform: translate(-50%, -50%) scale(var(--slide-scale, 1));
    transform-origin: center;
    scroll-margin-top: 0;
  }
  .presentation .section h2 {
    font-size: 30px;
  }
  .presentation .section-subtitle {
    font-size: 15px;
  }
  .presentation .cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .presentation .cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .presentation .cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .presentation .split-wide {
    grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  }
  .presentation .kpis {
    grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
    gap: 13px;
  }
  .presentation .kpis.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .presentation .kpi {
    padding: 17px 18px;
    min-height: 116px;
  }
  .presentation .kpi strong {
    font-size: 33px;
  }
  .presentation .kpi.money strong {
    font-size: 24px;
  }
  .presentation .kpi.wide-number strong {
    font-size: 25px;
  }
  .presentation .chart-svg {
    min-width: 0;
    width: 100%;
    height: auto;
  }
  .presentation .box,
  .presentation .chart-card {
    padding: 19px;
  }
  .presentation .data-details,
  .presentation .notes,
  .presentation .mobile-hint {
    display: none !important;
  }
  .presentation .source {
    font-size: 11px;
    margin-top: 18px;
  }
  .presentation .dark-section .number-lg {
    font-size: 62px;
  }
  .presentation .photo-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 13px;
  }
  .presentation .photo-card img {
    height: 190px;
  }
  .presentation .photo-copy h4 {
    font-size: 16px;
    min-height: 69px;
  }
  .presentation .photo-copy {
    padding: 16px;
  }
  .presentation .dds-image {
    height: 245px;
  }
  .presentation .matrix th,
  .presentation .matrix td {
    height: 64px;
  }
  .presentation .matrix td {
    font-size: 13px;
  }
  .presentation .section.current.cover {
    padding: 0;
  }
  .presentation .cover-grid {
    grid-template-columns: 1fr 1fr;
    min-height: 750px;
  }
  .presentation .cover-copy {
    padding: 46px;
  }
  .presentation .cover h1 {
    font-size: 59px;
  }
  .presentation .cover-image {
    min-height: 750px;
    height: 100%;
    border-left: 7px solid var(--gold);
    border-top: 0;
  }
  .presentation .cover .source {
    margin: 0;
    padding: 17px 25px;
  }
}
@media screen and (max-width: 800px) {
  .presentation .brand-title,
  .presentation .cycle,
  .presentation-help {
    display: none;
  }
  .presentation .toolbar {
    padding: 8px 10px;
    gap: 7px;
  }
  .presentation .toolbar button {
    font-size: 12px;
    padding: 8px 9px;
  }
  .presentation .pager {
    gap: 5px;
  }
  .presentation .pager .progress-label {
    font-size: 11px;
    min-width: 47px;
  }
  .presentation .toolbar .spacer {
    display: none;
  }
  .presentation main {
    inset: 84px 10px 72px;
  }
}

/* As janelas de detalhe ficam fora do palco escalado (position: fixed). */

/* ========================================================================
   22. JANELA DE DETALHAMENTO (abre no clique; "Ampliar" / "×")
   Abre ao CLICAR em qualquer elemento com data-detail.
   Conteúdo vem de data/detalhes.js e é montado por js/detalhes.js.
   ======================================================================== */
.insight-target {
  cursor: pointer; /* indica que a informação é clicável */
}
.kpi.insight-target:hover,
.box.insight-target:hover,
.photo-card.insight-target:hover,
.chart-card.insight-target:hover {
  border-color: #d8b779;
}
.key-value.insight-target:hover {
  background: #fff7dd;
  border-radius: 5px;
}
.detail-backdrop {
  position: fixed;
  inset: 0;
  background: #15202799;
  backdrop-filter: blur(3px);
  z-index: 89;
}
.detail-backdrop[hidden] {
  display: none !important;
}
.tooltip {
  background: #fffdfa;
  color: var(--ink);
  border: 1px solid #cbae83;
  border-top: 5px solid var(--gold);
  border-radius: 10px;
  padding: 0;
  width: min(660px, calc(100vw - 32px));
  max-width: none;
  max-height: var(--detail-max-height, calc(100dvh - 32px));
  box-shadow: 0 12px 42px #1115;
  white-space: normal;
  pointer-events: auto;
  font:
    14px/1.5 "Segoe UI",
    Calibri,
    Arial,
    sans-serif;
  overflow: hidden;
}
.detail-shell {
  display: flex;
  flex-direction: column;
  max-height: var(--detail-max-height, calc(100dvh - 32px));
}
.detail-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 15px;
  border-bottom: 1px solid var(--line);
  background: #f4efe5;
  flex-shrink: 0;
}
.detail-toolbar > span {
  font-size: 10px;
  letter-spacing: 1.3px;
  font-weight: 800;
  color: var(--brown2);
}
.detail-toolbar > div {
  display: flex;
  gap: 6px;
  align-items: center;
}
.detail-toolbar button {
  border: 1px solid #d9c5a5;
  border-radius: 5px;
  background: white;
  padding: 5px 10px;
  font-size: 12px;
  color: var(--brown2);
}
.detail-toolbar button[aria-pressed="true"] {
  background: var(--gold);
  border-color: var(--gold);
}
.detail-toolbar #detail-close {
  font-size: 21px;
  line-height: 1;
  padding: 4px 10px;
  color: var(--ink);
}
.detail-content {
  overflow: auto;
  overscroll-behavior: contain;
  min-height: 0;
  padding: 18px 20px;
  max-height: calc(var(--detail-max-height, 100dvh - 32px) - 104px);
}
.detail-content h2 {
  font-size: 22px;
  line-height: 1.25;
  color: var(--brown2);
  margin: 0 0 13px;
  letter-spacing: -0.3px;
}
.detail-content h3 {
  font-size: 15px;
  margin: 16px 0 8px;
  color: var(--brown2);
}
.detail-lead {
  margin: 0 0 15px;
  font-size: 14px;
  line-height: 1.6;
}
.detail-selection {
  background: #fff7dd;
  border-left: 3px solid var(--gold);
  padding: 9px 12px;
  margin: 0 0 13px;
  font-size: 13px;
}
.detail-selection b {
  display: block;
  color: var(--brown2);
  font-size: 10px;
  letter-spacing: 0.7px;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.detail-selection span {
  white-space: pre-line;
}
.detail-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0 18px;
}
.detail-facts > div {
  padding: 10px 12px;
  background: #f5f0e6;
  border: 1px solid var(--line);
  border-radius: 6px;
  min-width: 0;
}
.detail-facts dt {
  font-size: 11px;
  color: var(--muted);
  margin: 0 0 5px;
}
.detail-facts dd {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  margin: 0;
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}
.detail-table-wrap {
  overflow: auto;
  margin: 15px 0;
}
.detail-table-wrap table {
  font-size: 12px;
  line-height: 1.5;
  width: 100%;
}
.detail-table-wrap caption {
  font-weight: 700;
  text-align: left;
  color: var(--brown2);
  padding: 0 0 8px;
  font-size: 13px;
}
.detail-table-wrap th,
.detail-table-wrap td {
  padding: 7px 9px;
  min-width: 55px;
  overflow-wrap: anywhere;
}
.detail-table-wrap th {
  background: var(--brown2);
  color: #fff;
}
.detail-table-wrap tbody tr:nth-child(even) {
  background: #f4efe5;
}
.detail-rules {
  border-top: 1px solid var(--line);
  margin-top: 15px;
}
.detail-rules ul {
  padding-left: 19px;
  margin: 8px 0;
}
.detail-rules li {
  margin: 7px 0;
  font-size: 13px;
  line-height: 1.6;
}
.detail-related {
  padding: 0 13px 4px;
  background: #f8f4eb;
  border-radius: 7px;
  border: 1px solid var(--line);
  margin: 16px 0;
}
.detail-related p {
  font-size: 13px;
}
.detail-source {
  font-size: 10px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  padding-top: 11px;
  margin: 16px 0 0;
  line-height: 1.5;
}
.detail-hint {
  padding: 9px 15px;
  background: #f4efe5;
  border-top: 1px solid var(--line);
  font-size: 10px;
  color: var(--muted);
  flex-shrink: 0;
}
.tooltip.is-pinned {
  border-color: var(--brown);
}
.tooltip.is-expanded {
  left: 50% !important;
  top: 50% !important;
  transform: translate(-50%, -50%);
  width: min(1000px, calc(100vw - 40px));
  height: calc(100dvh - 48px);
  max-height: calc(100dvh - 48px);
}
.tooltip.is-expanded .detail-shell {
  height: 100%;
  max-height: none;
}
.tooltip.is-expanded .detail-content {
  flex: 1;
  max-height: none;
  padding: 25px 30px;
}
.tooltip.is-expanded .detail-content h2 {
  font-size: 27px;
}
.tooltip.is-expanded .detail-facts {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.tooltip.is-expanded .detail-table-wrap table {
  font-size: 14px;
}
.tooltip.is-expanded .detail-table-wrap th,
.tooltip.is-expanded .detail-table-wrap td {
  padding: 9px 12px;
}
@media (max-width: 600px) {
  .detail-content {
    padding: 15px;
  }
  .detail-content h2 {
    font-size: 20px;
  }
  .detail-toolbar {
    padding: 8px 10px;
    gap: 5px;
  }
  .detail-toolbar button {
    font-size: 11px;
    padding: 5px 8px;
  }
  .detail-facts {
    grid-template-columns: 1fr;
  }
  .tooltip.is-expanded {
    width: calc(100vw - 24px);
    height: calc(100dvh - 24px);
  }
  .tooltip.is-expanded .detail-content {
    padding: 18px;
  }
  .tooltip.is-expanded .detail-facts {
    grid-template-columns: 1fr 1fr;
  }
  .tooltip.is-expanded .detail-content h2 {
    font-size: 22px;
  }
}
@media print {
  .detail-backdrop,
  .tooltip {
    display: none !important;
  }
  .insight-target {
    cursor: auto;
  }
}
.insight-target:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

/* ========================================================================
   23. MENU FLUIDO E TRANSIÇÕES ENTRE PÁGINAS
   Só interação/animação — nenhum conteúdo muda. Desligado para quem
   pede "reduzir movimento" no sistema (fim desta seção).
   ======================================================================== */

/* Transição suave entre páginas do relatório (Chrome/Edge 126+ no site
   publicado). Cabeçalho, barra e menu ficam parados; só o painel troca. */
@view-transition {
  navigation: auto;
}
.topbar {
  view-transition-name: topo;
}
.toolbar {
  view-transition-name: barra;
}
.sidebar {
  view-transition-name: menu;
}
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.22s;
}

/* Itens do menu: hover, clique e item atual com transição */
.sidebar {
  overscroll-behavior: contain; /* rolar o menu não rola a página */
  scrollbar-width: thin;
  scrollbar-color: #d8cbb8 transparent;
}
.sidebar a {
  transition:
    background-color 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.18s ease,
    color 0.18s ease;
}
.sidebar a:hover {
  transform: translateX(3px);
}
.sidebar a:active {
  transform: translateX(3px) scale(0.98);
}
.sidebar a span {
  transition: color 0.18s ease;
}
.sidebar a:hover span,
.sidebar a[aria-current="page"] span {
  color: var(--brown);
}
.sidebar a:focus-visible {
  outline-offset: 1px;
}

/* Painel entra suavemente; ao clicar no menu, o painel atual esmaece de leve */
main > .section {
  animation: painel-entra 0.28s ease-out both;
}
@keyframes painel-entra {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
main {
  transition: opacity 0.15s ease;
}
body.navegando main {
  opacity: 0.55;
}

/* Botões da barra com resposta visual */
.toolbar button,
.toolbar-link {
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    transform 0.1s ease;
}
.toolbar button:not(:disabled):hover {
  border-color: var(--brown);
}
.toolbar button:not(:disabled):active {
  transform: scale(0.97);
}
.toolbar-link {
  border: 1px solid #ddcdbc;
  border-radius: 7px;
  padding: 7px 12px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}
.toolbar-link:hover {
  border-color: var(--brown);
}
.toolbar .logout-button {
  background: transparent;
  color: var(--muted);
}

/* Celular/tablet: o menu desliza da esquerda em vez de aparecer de repente */
@media (max-width: 900px) {
  .sidebar {
    display: block;
    transform: translateX(-102%);
    visibility: hidden;
    transition:
      transform 0.26s cubic-bezier(0.2, 0.8, 0.2, 1),
      visibility 0s linear 0.26s;
  }
  .sidebar.open {
    transform: none;
    visibility: visible;
    transition: transform 0.26s cubic-bezier(0.2, 0.8, 0.2, 1);
  }
  .nav-backdrop {
    display: block;
    position: fixed;
    inset: var(--header-height) 0 0;
    z-index: 50;
    background: #1f2b3340;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
  }
  .nav-backdrop.open {
    opacity: 1;
    pointer-events: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  @view-transition {
    navigation: none;
  }
  .sidebar,
  .sidebar a,
  main,
  main > .section,
  .nav-backdrop {
    transition: none !important;
    animation: none !important;
  }
}
@media print {
  main > .section {
    animation: none;
  }
  .toolbar-link,
  .logout-button {
    display: none;
  }
}

/* ========================================================================
   24. TELA DE SENHA (versão publicada — js/cofre.js)
   ======================================================================== */
body.cofre-bloqueado {
  overflow: hidden;
}
.cofre {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 16px;
  background: var(--cream);
}
.cofre-caixa {
  width: min(400px, 100%);
  background: #fff;
  border-radius: 12px;
  border-top: 5px solid var(--gold);
  box-shadow: 0 12px 40px #60351322;
  padding: 30px 28px 26px;
  animation: painel-entra 0.3s ease-out both;
}
.cofre-logo {
  width: 230px;
  max-width: 100%;
  display: block;
  margin: 0 auto 18px;
}
.cofre-caixa h1 {
  font-size: 21px;
  margin: 0 0 4px;
}
.cofre-caixa p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 14px;
}
.cofre-caixa label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--brown2);
  margin-bottom: 6px;
}
.cofre-campo {
  display: flex;
  gap: 6px;
}
.cofre-campo input {
  flex: 1;
  min-width: 0;
  font: inherit;
  padding: 10px 12px;
  border: 1px solid #ddcdbc;
  border-radius: 8px;
}
.cofre-campo input:focus {
  outline: 3px solid var(--gold);
  outline-offset: 0;
  border-color: var(--gold);
}
.cofre-campo button {
  border: 1px solid #ddcdbc;
  border-radius: 8px;
  background: #fff;
  width: 44px;
}
.cofre-erro {
  color: var(--red) !important;
  font-weight: 650;
  margin: 10px 0 0 !important;
}
#cofre-entrar {
  width: 100%;
  margin-top: 18px;
  padding: 11px;
  border: 0;
  border-radius: 8px;
  background: var(--gold);
  color: var(--ink);
  font-weight: 750;
}
#cofre-entrar:disabled {
  opacity: 0.7;
}
@media print {
  .cofre {
    display: none;
  }
}
