/* ==========================================================================
   GovernoCerto — base.css
   Tokens da identidade, reset, tipografia e utilitários de layout.
   ========================================================================== */

:root {
  /* Paleta oficial */
  --navy: #0B2F6B;          /* Azul Governo — confiança */
  --navy-800: #082552;
  --navy-900: #061B3F;
  --navy-950: #04122C;
  --blue: #2E7BFF;          /* Azul Tecnologia — ações, links, dados */
  --blue-ink: #1C5FD6;      /* variação para texto sobre fundo claro (AA) */
  --blue-soft: #DCE8FF;
  --gold: #D4A017;          /* Dourado Gestão — destaque, selos, números */
  --gold-300: #E9C45C;
  --gold-deep: #7F5F00;     /* dourado para números grandes sobre bege */
  --gold-soft: #F6E7B8;
  --green: #0F9D76;         /* Verde Território — progresso, mapa, sucesso */
  --green-ink: #0A7A5B;
  --green-soft: #D5F0E6;
  --beige: #F6F3EB;         /* Bege Neutro — fundos editoriais */
  --beige-200: #EEE9DC;
  --beige-300: #E2DAC6;
  --paper: #FCFBF7;
  --ink: #1F2937;           /* Grafite — texto */
  --ink-2: #4A5463;
  --ink-3: #5B6370;
  --danger: #C2410C;
  --white: #fff;

  --line: rgba(11, 47, 107, .12);
  --line-strong: rgba(11, 47, 107, .2);
  --line-dark: rgba(255, 255, 255, .12);
  --line-dark-strong: rgba(255, 255, 255, .22);

  /* Tipografia */
  --f-display: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;
  --f-text: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;

  --fs-display: clamp(2.45rem, 1.2rem + 5.2vw, 5.4rem);
  --fs-h2: clamp(2rem, 1.25rem + 3vw, 3.6rem);
  --fs-h3: clamp(1.35rem, 1.1rem + 1vw, 1.85rem);
  --fs-lead: clamp(1.06rem, 1rem + .35vw, 1.3rem);

  /* Forma */
  --r-xs: 8px;
  --r-sm: 12px;
  --r: 16px;
  --r-lg: 24px;
  --r-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(6, 27, 63, .06), 0 2px 8px rgba(6, 27, 63, .05);
  --shadow: 0 2px 6px rgba(6, 27, 63, .06), 0 14px 34px -10px rgba(6, 27, 63, .18);
  --shadow-lg: 0 4px 12px rgba(6, 27, 63, .08), 0 40px 80px -24px rgba(6, 27, 63, .38);

  --container: 1240px;
  --gutter: clamp(20px, 4vw, 44px);
  --section-y: clamp(80px, 6vw + 40px, 150px);
  --header-h: 76px;

  --ease: cubic-bezier(.22, .61, .36, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: var(--f-text);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--beige);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
a { color: inherit; text-decoration: none; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; font-family: var(--f-display); font-weight: 800; line-height: 1.06; letter-spacing: -.025em; color: inherit; }
table { border-collapse: collapse; }
[hidden] { display: none !important; }
::selection { background: var(--gold); color: var(--navy-950); }

:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
.on-dark :focus-visible, .section--dark :focus-visible, .section--deep :focus-visible { outline-color: var(--gold-300); }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--gold); color: var(--navy-950); font-weight: 700;
  padding: 12px 18px; border-radius: var(--r-sm); transition: top .2s;
}
.skip-link:focus { top: 12px; }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Tipografia ---------- */
.display { font-size: var(--fs-display); line-height: .98; letter-spacing: -.035em; font-weight: 800; }
.h2 { font-size: var(--fs-h2); line-height: 1.02; letter-spacing: -.032em; }
.h3 { font-size: var(--fs-h3); line-height: 1.12; letter-spacing: -.02em; font-weight: 750; }
.h4 { font-size: 1.12rem; line-height: 1.25; letter-spacing: -.01em; font-weight: 750; }
.lead { font-size: var(--fs-lead); line-height: 1.55; color: var(--ink-2); max-width: 38em; }
.muted { color: var(--ink-2); }
.small { font-size: .875rem; }

/* Palavra em destaque: itálico dourado */
.accent { font-style: italic; color: var(--gold); font-weight: 800; padding-right: .04em; }
.on-light .accent, .section--light .accent { color: var(--gold-deep); }

/* Rótulo editorial em caixa-alta */
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--f-text); font-size: .75rem; font-weight: 650;
  text-transform: uppercase; letter-spacing: .2em; line-height: 1.4;
  color: var(--navy);
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; opacity: .55; flex: none; }
.eyebrow b { color: var(--gold-deep); font-weight: 750; }
.section--dark .eyebrow, .section--deep .eyebrow, .on-dark .eyebrow { color: rgba(255, 255, 255, .82); }
.section--dark .eyebrow b, .section--deep .eyebrow b, .on-dark .eyebrow b { color: var(--gold); }
.eyebrow--plain::before { display: none; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(880px + var(--gutter) * 2); }

.grid-12 { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.2vw, 32px); row-gap: 32px; }
.grid-12 > * { grid-column: 1 / -1; }

.section { position: relative; padding-block: var(--section-y); }
.section--light { background: var(--beige); color: var(--ink); }
.section--paper { background: var(--paper); color: var(--ink); }
.section--dark { background: var(--navy-900); color: #fff; }
.section--deep { background: var(--navy-950); color: #fff; }
.section--dark .lead, .section--deep .lead { color: rgba(255, 255, 255, .74); }
.section--dark .muted, .section--deep .muted { color: rgba(255, 255, 255, .66); }

.hairline { height: 1px; background: var(--line); border: 0; margin: 0; }
.section--dark .hairline, .section--deep .hairline { background: var(--line-dark); }

.stack > * + * { margin-top: var(--stack, 1.25rem); }

/* ---------- Revelação ao rolar (só oculta quando o JS está ativo) ---------- */
.js [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  transition: opacity .9s var(--ease-out), transform 1s var(--ease-out);
  transition-delay: var(--d, 0s);
}
.js [data-reveal="left"] { transform: translate3d(-36px, 0, 0); }
.js [data-reveal="right"] { transform: translate3d(36px, 0, 0); }
.js [data-reveal="zoom"] { transform: scale(.94); }
.js [data-reveal="fade"] { transform: none; }
.js [data-reveal].is-in { opacity: 1; transform: none; }
@media (max-width: 1023.98px) {
  .js [data-reveal="left"]:not(.is-in), .js [data-reveal="right"]:not(.is-in) { transform: translate3d(0, 28px, 0); }
}
main { overflow-x: clip; }

@media (min-width: 1600px) { :root { --container: 1320px; } }
