/* Estilo "artigo técnico" do manual do SGAEE — mesma linha visual usada nos
   artigos técnicos de outros projetos (masthead de periódico, article info,
   resumo, sumário, seções numeradas, tabelas, callouts). Página única, sem
   variantes multi-página. */
:root {
  --paper: #fff;
  --canvas: #eef1f3;
  --ink: #202124;
  --muted: #5f6368;
  --line: #cfd5d8;
  --line-dark: #8a9499;
  --journal: #3730a3;
  --journal-dark: #2d2680;
  --link: #4338ca;
  --soft: #eef0fd;
  --warn: #9a6300;
  --warn-bg: #fff8e6;
  --good: #24713a;
  --bad: #a63232;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 78px; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
code, pre { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; }
code { padding: .08em .3em; background: #f0f2f3; font-size: .86em; }

.reading-progress { position: fixed; inset: 0 auto auto 0; z-index: 100; width: 0; height: 3px; background: var(--journal); }

.site-nav { position: sticky; top: 0; z-index: 90; background: rgba(255,255,255,.97); border-bottom: 1px solid var(--line); font-family: var(--sans); }
.nav-inner { display: flex; align-items: center; gap: 24px; max-width: 1180px; min-height: 58px; margin: 0 auto; padding: 0 24px; }
.brand { color: var(--ink); font-weight: 700; white-space: nowrap; font-size: 16px; }
.brand:hover { text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 22px; margin-left: auto; font-size: 13px; }
.nav-links a { color: #40464a; white-space: nowrap; }
.nav-links .app-link { padding: 7px 14px; color: #fff; background: var(--journal); border-radius: 999px; font-weight: 700; }
.nav-links .app-link:hover { background: var(--journal-dark); text-decoration: none; }
.nav-links .repo-link { padding-left: 22px; border-left: 1px solid var(--line); }

.paper { width: min(1120px, calc(100% - 32px)); margin: 26px auto 48px; background: var(--paper); box-shadow: 0 5px 22px rgba(35,45,50,.1); }
.journal-strip { padding: 10px 46px; color: var(--journal-dark); border-bottom: 1px solid var(--line-dark); text-align: center; font: 12px/1.3 var(--sans); }
.journal-masthead { display: grid; grid-template-columns: 130px 1fr 155px; align-items: stretch; margin: 0 46px; border-bottom: 4px solid #111; }
.journal-identity { display: flex; align-items: center; justify-content: center; overflow: hidden; background: #1b2832; }
.journal-identity img { display: block; width: 100%; height: 100%; object-fit: contain; }
.journal-center { padding: 15px 24px; text-align: center; background: #eceeef; }
.journal-center small { display: block; font: 12px/1.2 var(--sans); }
.journal-center strong { display: block; margin: 7px 0; font: 400 28px/1.1 var(--serif); }
.journal-center a { font: 12px/1.2 var(--sans); }
.journal-type { display: grid; place-items: center; padding: 12px; color: var(--journal-dark); background: var(--soft); text-align: center; font: 700 13px/1.35 var(--sans); }

.article-header { padding: 42px 46px 0; }
.article-label { margin-bottom: 12px; color: var(--journal-dark); font: 700 11px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; }
h1 { max-width: 900px; margin: 0 0 12px; font: 400 44px/1.13 var(--serif); }
.subtitle { max-width: 850px; margin: 0 0 18px; color: var(--muted); font: 17px/1.45 var(--serif); }
.authors { margin: 0; font: 18px/1.5 var(--serif); }
.authors sup, .affiliations sup { color: var(--journal); font-family: var(--sans); }
.affiliations { margin: 11px 0 24px; color: #3e4447; font: italic 12px/1.55 var(--serif); }
.article-rule { margin: 0; border: 0; border-top: 1px solid #111; }

.abstract-grid { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 42px; padding: 26px 46px 30px; border-bottom: 1px solid #111; }
.abstract-grid h2 { margin: 0 0 12px; color: #111; font: 700 11px/1.2 var(--sans); letter-spacing: .23em; text-transform: uppercase; }
.article-info { padding-right: 18px; border-right: 1px solid var(--line); }
.article-info dl { margin: 0; font: 12px/1.5 var(--sans); }
.article-info dt { margin-top: 10px; color: var(--muted); font-weight: 700; }
.article-info dd { margin: 2px 0 0; }
.article-info .secondary-heading { margin-top: 22px; }
.keywords { font-size: 12px; color: var(--muted); }
.abstract p { margin: 0 0 10px; text-align: justify; font-size: 15px; line-height: 1.55; }
.disclaimer-inline { margin-top: 16px; padding: 11px 13px; color: #574216; background: var(--warn-bg); border-left: 3px solid #d39725; font: 12px/1.45 var(--sans); }

.article-tools { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; padding: 13px 46px; color: var(--muted); background: #fafbfb; border-bottom: 1px solid var(--line); font: 12px/1.4 var(--sans); }
.article-tools strong { color: var(--ink); width: 100%; }

.download-row { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: center; margin: 16px 0 24px; padding: 15px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-family: var(--sans); }
.download-row strong, .download-row span { display: block; }
.download-row strong { color: var(--journal-dark); font-size: 13px; }
.download-row span { margin-top: 3px; color: var(--muted); font-size: 12px; }
.download-row a { padding: 8px 12px; color: #fff; background: var(--journal); font-size: 12px; font-weight: 700; border-radius: 4px; }
.download-row a:hover { background: var(--journal-dark); text-decoration: none; }

.supplement-body { max-width: 900px; padding: 20px 46px 54px; }
.supplement-body section { scroll-margin-top: 70px; }
.supplement-body h2 { margin: 32px 0 9px; padding-bottom: 5px; border-bottom: 1px solid var(--line); font: 700 22px/1.25 var(--serif); }
.supplement-body h3 { margin: 22px 0 7px; font: 700 16px/1.3 var(--serif); }
.supplement-body p { text-align: justify; }
.supplement-body pre { overflow-x: auto; margin: 12px 0 20px; padding: 14px 16px; color: #f4f7f8; background: #1e272b; font-size: 12px; line-height: 1.55; }
.supplement-body pre code { padding: 0; color: inherit; background: none; }
.supplement-body ul, .supplement-body ol { padding-left: 22px; }
.supplement-body li { margin-bottom: 5px; }

.table-wrap { overflow-x: auto; margin: 16px 0 22px; border-top: 2px solid #343a3d; border-bottom: 1px solid #343a3d; }
table { width: 100%; border-collapse: collapse; font: 12px/1.4 var(--sans); }
th, td { padding: 8px 9px; text-align: left; vertical-align: top; border-bottom: 1px solid #dfe3e5; }
th { color: #303538; background: #f3f5f6; font-weight: 700; }
tr:last-child td { border-bottom: 0; }
.status { display: inline-block; white-space: nowrap; font-weight: 700; }
.status.done { color: var(--good); }
.status.pending { color: var(--warn); }
.status.excluded { color: var(--bad); }

.metrics { display: grid; grid-template-columns: repeat(4, 1fr); margin: 24px 0; border-top: 2px solid var(--journal); border-bottom: 1px solid var(--line-dark); }
.metric { padding: 17px 15px; border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric strong { display: block; color: var(--journal-dark); font: 700 25px/1 var(--sans); }
.metric span { display: block; margin-top: 7px; color: var(--muted); font: 11px/1.35 var(--sans); }

.callout { margin: 15px 0; padding: 12px 14px; font: 13px/1.5 var(--sans); }
.callout.note { background: var(--soft); border-left: 3px solid var(--journal); }
.callout strong { display: block; margin-bottom: 3px; }

.method-step { display: grid; grid-template-columns: 38px 1fr; gap: 12px; margin: 16px 0; }
.method-step .step-no { display: grid; place-items: center; width: 30px; height: 30px; color: #fff; background: var(--journal); border-radius: 50%; font: 700 12px var(--sans); }
.method-step h3 { margin: 2px 0 4px; }
.method-step p { margin: 0; }

.checklist { list-style: none; padding: 0 !important; }
.checklist li { position: relative; padding: 7px 0 7px 28px; border-bottom: 1px solid #edf0f1; }
.checklist li::before { content: "□"; position: absolute; left: 2px; top: 5px; color: var(--journal); font: 19px/1 var(--sans); }

.references { margin-top: 36px; font-size: 12px; line-height: 1.5; }
.article-footer { display: grid; grid-template-columns: 1fr auto; gap: 24px; padding: 22px 46px; color: var(--muted); background: #f5f6f6; border-top: 1px solid var(--line); font: 11px/1.5 var(--sans); }

@media print {
  body { background: #fff; font-size: 11pt; }
  .site-nav, .reading-progress, .article-tools { display: none; }
  .paper { width: 100%; margin: 0; box-shadow: none; }
  .journal-strip { padding-top: 0; }
  a { color: inherit; }
}

@media (max-width: 820px) {
  html { scroll-padding-top: 54px; }
  .nav-inner { min-height: 52px; padding: 0 16px; overflow-x: auto; }
  .nav-links { gap: 16px; }
  .nav-links .repo-link { padding-left: 0; border-left: 0; }
  .paper { width: 100%; margin: 0; box-shadow: none; }
  .journal-strip { padding: 9px 18px; }
  .journal-masthead { grid-template-columns: 92px 1fr; margin: 0 18px; }
  .journal-center { padding: 12px 10px; }
  .journal-center strong { font-size: 22px; }
  .journal-type { display: none; }
  .article-header, .supplement-body { padding-left: 20px; padding-right: 20px; }
  .article-header { padding-top: 28px; }
  h1 { font-size: 29px; }
  .abstract-grid { grid-template-columns: 1fr; gap: 20px; padding: 23px 20px; }
  .article-info { padding: 0 0 18px; border-right: 0; border-bottom: 1px solid var(--line); }
  .article-tools { padding: 11px 20px; overflow-x: auto; white-space: nowrap; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(2) { border-right: 0; }
  .metric:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .article-footer { grid-template-columns: 1fr; padding: 20px; }
  .download-row { grid-template-columns: 1fr; }
  .download-row a { justify-self: start; }
}
