/* ═══════════════════════════════════════════════════════════════
PDI+VC — custom.css   (gerado automaticamente)
═══════════════════════════════════════════════════════════════ */

/* ── Tipografia ─────────────────────────────────────────────── */
body, .quarto-title {
font-family: 'Source Serif 4', Georgia, serif;
}
code, pre, .sourceCode {
font-family: 'JetBrains Mono', monospace;
font-size: 0.75em;      /* tamanho menor para código, para caber melhor no PDF sem quebrar tanto */
}

/* ── Sidebar ─────────────────────────────────────────────────── */
#quarto-sidebar {
background: #2c3e55 !important;
}
#quarto-sidebar .sidebar-title a,
#quarto-sidebar .sidebar-title {
color: #fde8c0 !important;
font-weight: 700;
}
#quarto-sidebar a,
.sidebar-navigation .sidebar-item-text,
.sidebar-navigation a {
color: #c8ddf0 !important;
}
#quarto-sidebar a:hover,
.sidebar-navigation a:hover,
.sidebar-navigation .sidebar-item-text:hover {
color: #ffe0a0 !important;
background: rgba(255,255,255,0.09) !important;
border-radius: 4px;
}
.sidebar-item.sidebar-item-section > .sidebar-item-text {
color: #ffc97a !important;
font-weight: 600;
letter-spacing: 0.04em;
}
.sidebar-item .chapter-number {
color: #90b8d8 !important;
}

/* ── Títulos ─────────────────────────────────────────────────── */
h1, h2, h3 { color: #1a3a5c; }
h1 { border-bottom: 3px solid #f0c060; padding-bottom: 0.3em; }

/* ── Callouts ────────────────────────────────────────────────── */
.callout { border-left-width: 5px; border-radius: 4px; }

/* ── Código-fonte (input) ────────────────────────────────────── */
/* ── Código-fonte (input) e outputs — base compartilhada ─────── */
div.sourceCode,
.cell-output pre,
.cell-output code,
[class^="cell-output"] pre,
[class*=" cell-output"] pre {
  border-radius: 8px !important;
  border: 1px solid transparent !important;   /* sobrescrito abaixo */
  border-left-width: 4px !important;
  box-shadow: none !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 0.75em !important;       /* tamanho menor para código, para caber melhor no PDF sem quebrar tanto */
  line-height: 1.55 !important;
  padding: 0.75em 1em !important;
  white-space: pre-wrap !important;
}

/* ── Código-fonte: azul ──────────────────────────────────────── */
div.sourceCode {
  background: #f0f4ff !important;
  border-color: #c8d4f0 !important;
  border-left-color: #7090d0 !important;
  color: #1a2050 !important;
}
div.sourceCode pre,
div.sourceCode pre code {
  background: #f0f4ff !important;
  color: #1a2050 !important;
  border: none !important;
  box-shadow: none !important;
}

/* ── Output (stdout): mesma estrutura, fundo âmbar ──────────── */
.cell-output pre,
.cell-output code,
[class^="cell-output"] pre,
[class*=" cell-output"] pre {
  background: #fdf6ec !important;
  border-color: #e8d8b8 !important;
  border-left-color: #e8a840 !important;
  color: #2e1e05 !important;
}

/* ── stderr: mesma estrutura, fundo rosado ───────────────────── */
.cell-output-stderr pre,
.cell-output-stderr code {
  background: #fff2f0 !important;
  border-color: #f0c8c0 !important;
  border-left-color: #e06050 !important;
  color: #5a1a10 !important;
}

/* O <code> DENTRO do <pre> (saída de stream: <pre><code>...</code></pre>)
   não pode reganhar caixa/borda/padding próprios — senão vira uma
   "janela dentro da outra". Só o <pre> externo desenha a moldura,
   idêntico ao que já se faz com div.sourceCode acima. */
.cell-output pre code,
[class^="cell-output"] pre code,
[class*=" cell-output"] pre code {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  border-left-width: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
  color: inherit !important;
  font-size: inherit !important;
}

/* ── display_data (imagens, HTML rico): sem caixa própria ─────── */
.cell-output-display {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  margin-top: 0.3em !important;
}
.cell-output-display > pre,
.cell-output-display pre {
  background: #fdf6ec !important;
  border: 1px solid #e8d8b8 !important;
  border-left: 4px solid #e8a840 !important;
  border-radius: 8px !important;
  padding: 0.75em 1em !important;
  color: #2e1e05 !important;
}
.cell-output-display img {
  background: transparent;
  border-radius: 4px;
  display: block;
}

/* ── Tabelas ─────────────────────────────────────────────────── */
table { border-collapse: collapse; width: 100%; }
thead tr { background: #2c4a6a !important; color: #faf0e0 !important; }
tbody tr:nth-child(even) { background: #f5f0e8; }
td, th { padding: 0.5em 0.8em; border: 1px solid #d0c8b8; }

/* ── Capa ────────────────────────────────────────────────────── */
.quarto-cover-image {
border-radius: 8px;
box-shadow: 0 8px 32px rgba(0,0,0,0.28);
max-height: 480px;
object-fit: cover;
}
/* ── Botões de expansão (Sidebar / Índice) ─────────────────── */
.toggle-layout-btn {
  background: transparent;
  border: 1px solid rgba(0, 0, 0, 0.08);
  color: rgba(85, 85, 85, 0.65);
  padding: 3px 7px;
  font-size: 0.7rem;
  font-weight: 300;
  line-height: 1;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  opacity: 0.55;
}
.toggle-layout-btn:hover {
  background: rgba(0, 0, 0, 0.04);
  color: #1a3a5c;
  border-color: rgba(26, 58, 92, 0.4);
  opacity: 1;
}

#toggle-sidebar-btn {
  position: fixed;
  top: 12px;
  left: 15px;
  z-index: 1100;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

#toggle-toc-btn {
  position: fixed;
  top: 12px;
  right: 15px;
  z-index: 1100;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

/* Classes para alternar a largura e esconder elementos */
body.sidebar-hidden #quarto-sidebar {
  display: none !important;
}
body.sidebar-hidden #quarto-document-content,
body.sidebar-hidden .content,
body.sidebar-hidden page-columns {
  grid-column: 1 / -1 !important;
  max-width: 100% !important;
  padding-left: 5mm !important;
}
body.toc-hidden #TOC,
body.toc-hidden #quarto-margin-sidebar {
  display: none !important;
}
