:root {
  --ink: #17324d;
  --muted: #5d7184;
  --blue: #1684c7;
  --blue-dark: #0e6395;
  --green: #52b788;
  --pale: #f4f9fc;
  --line: #dbe7ef;
  --white: #ffffff;
  --shadow: 0 18px 45px rgba(21, 61, 91, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #edf8ff 0, #f8fbfd 360px, #f8fbfd 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.68;
}

a { color: var(--blue-dark); }
a:hover { color: var(--blue); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(219, 231, 239, .9);
  background: rgba(255, 255, 255, .94);
  backdrop-filter: blur(14px);
}

.header-inner {
  width: min(1120px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--green));
  box-shadow: 0 8px 20px rgba(22,132,199,.22);
  font-size: 20px;
}

.site-nav { display: flex; flex-wrap: wrap; gap: 8px; }
.site-nav a {
  padding: 8px 11px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}
.site-nav a:hover { background: var(--pale); color: var(--blue-dark); }

.hero {
  width: min(1120px, calc(100% - 32px));
  margin: 54px auto 28px;
  padding: 42px clamp(24px, 5vw, 62px);
  border: 1px solid rgba(255,255,255,.9);
  border-radius: 28px;
  color: #fff;
  background: linear-gradient(130deg, #0c648f, #1684c7 52%, #3aa778);
  box-shadow: var(--shadow);
}
.hero .eyebrow { margin: 0 0 10px; font-size: 14px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; opacity: .9; }
.hero h1 { margin: 0; max-width: 820px; font-size: clamp(32px, 5vw, 56px); line-height: 1.05; letter-spacing: -.035em; }
.hero p { max-width: 760px; margin: 18px 0 0; font-size: clamp(17px, 2vw, 21px); color: rgba(255,255,255,.92); }
.hero-meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.hero-meta span { padding: 7px 12px; border: 1px solid rgba(255,255,255,.32); border-radius: 999px; background: rgba(255,255,255,.12); font-size: 14px; font-weight: 700; }

body > nav#TOC,
body > main,
body > header:not(.site-header),
body > p,
body > h1,
body > h2,
body > h3,
body > ul,
body > ol,
body > table {
  width: min(940px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

nav#TOC {
  margin-top: 26px;
  margin-bottom: 34px;
  padding: 22px 26px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(21,61,91,.06);
}
nav#TOC::before { content: "Navegação dos documentos"; display: block; margin-bottom: 10px; font-size: 18px; font-weight: 850; }
nav#TOC ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
nav#TOC li ul { display: none; }
nav#TOC a { display: block; padding: 8px 12px; border-radius: 10px; background: var(--pale); text-decoration: none; font-size: 14px; font-weight: 750; }

body > h1 {
  margin-top: 58px;
  margin-bottom: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.12;
  letter-spacing: -.025em;
}
body > h2 { margin-top: 34px; margin-bottom: 8px; font-size: 24px; line-height: 1.25; }
body > h3 { margin-top: 26px; margin-bottom: 8px; font-size: 19px; }
body > p, body > ul, body > ol { margin-top: 8px; margin-bottom: 13px; }
body > ul, body > ol { padding-left: 30px; }
body > ul li, body > ol li { margin: 6px 0; }

table {
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  margin-top: 18px;
  margin-bottom: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--white);
  box-shadow: 0 8px 22px rgba(21,61,91,.05);
}
th, td { padding: 13px 15px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th:last-child, td:last-child { border-right: 0; }
tr:last-child td { border-bottom: 0; }
th { color: #fff; background: #205b83; font-size: 14px; }
tbody tr:nth-child(even) { background: #f7fafc; }

.site-footer {
  margin-top: 64px;
  padding: 38px 16px;
  color: #dceaf3;
  background: #102f45;
}
.footer-inner { width: min(940px, 100%); margin: 0 auto; display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; }
.site-footer strong { color: #fff; }
.site-footer a { color: #fff; }
.site-footer p { margin: 6px 0; }
.legal-note { font-size: 14px; opacity: .86; }

@media (max-width: 780px) {
  body { font-size: 16px; }
  .header-inner { min-height: 66px; align-items: flex-start; padding: 12px 0; }
  .site-nav { display: none; }
  .hero { margin-top: 26px; padding: 30px 22px; border-radius: 22px; }
  nav#TOC { padding: 18px; }
  nav#TOC ul { display: grid; grid-template-columns: 1fr; }
  table { display: block; overflow-x: auto; white-space: normal; }
  th, td { min-width: 180px; }
  .footer-inner { grid-template-columns: 1fr; }
}

@media print {
  .site-header, .hero, nav#TOC, .site-footer { position: static; box-shadow: none; }
  body { background: #fff; color: #000; font-size: 11pt; }
  a { color: #000; text-decoration: none; }
  body > h1 { break-before: page; }
}
