/* ConciliaSUS · site institucional
   Sem estilos inline: a política de segurança (CSP) do site bloqueia style="". */

@font-face {
  font-family: "ConciliaSUS Sans";
  src: url("/assets/fonts/conciliasus-sans-400-800.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #0C326F;
  --navy-2: #0A2858;
  --blue: #1351B4;
  --text-blue: #0A6FA8;
  --sky: #23A6E6;
  --sky-light: #5FC4F5;
  --papaya: #FF8000;
  --papaya-text: #A04E00;
  --ink: #1B2430;
  --muted: #4B5563;
  --line: #E2E6EC;
  --bg: #FFFFFF;
  --bg-alt: #F4F6F9;
  --warn-bg: #FFF5C2;
  --warn-ink: #5C4400;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(12, 50, 111, .06), 0 8px 24px rgba(12, 50, 111, .08);
  --container: 1180px;
  --gutter: 20px;
  --header-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "ConciliaSUS Sans", "Segoe UI", Roboto, Arial, sans-serif;
  font-size-adjust: from-font;
  font-size: 1.0625rem;
  line-height: 1.6;
  /* Raleway usa algarismos antigos por padrão; números alinhados ficam mais legíveis. */
  font-variant-numeric: lining-nums;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3 {
  color: var(--navy);
  line-height: 1.15;
  margin: 0 0 .5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.2rem, 1.3rem + 3.6vw, 3.6rem); font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: clamp(1.75rem, 1.3rem + 1.6vw, 2.5rem); font-weight: 800; letter-spacing: -.015em; }
h3 { font-size: 1.15rem; font-weight: 700; }
p { margin: 0 0 1em; text-wrap: pretty; }

a { color: var(--blue); text-underline-offset: .18em; }
a:hover { color: var(--navy); }

:focus-visible {
  outline: 3px solid var(--papaya);
  outline-offset: 3px;
  border-radius: 4px;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.narrow { max-width: 820px; }

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  background: var(--navy);
  color: #fff;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-weight: 700;
}
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 999px;
  border: 2px solid transparent;
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .15s, color .15s, border-color .15s;
}
.btn-lg { min-height: 52px; padding: 0 28px; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--blue); color: #fff; }
.btn-secondary { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-secondary:hover { background: var(--navy); color: #fff; }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy);
  cursor: pointer;
}
.icon-btn:hover { background: var(--bg-alt); }

/* ---------- Cabeçalho ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(1.4) blur(8px);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: var(--header-h);
}
.brand { flex: none; }
.brand img { width: 178px; }

.main-nav { margin-left: auto; }
.main-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: block;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-weight: 600;
  font-size: .98rem;
  text-decoration: none;
}
.main-nav a:hover { background: var(--bg-alt); color: var(--navy); }

.menu-btn { display: none; margin-left: auto; }

@media (max-width: 980px) {
  .main-nav, .header-cta { display: none; }
  .menu-btn { display: inline-flex; }
  .brand img { width: 150px; }
}

/* ---------- Menu lateral (navigation drawer) ---------- */
.Drawer {
  --drawer-width: min(20em, 82dvw);
  --drawer-backdrop: 0;
  width: auto;
  height: auto;
  padding: 0;
  margin: 0;
  inset: 0;
  background: transparent;
  border: 0;
  overflow: visible;
}
.Drawer::backdrop {
  background: #06142B;
  opacity: calc(var(--drawer-backdrop) * .55);
}
.Drawer-scroller {
  position: relative;
  display: grid;
  grid-template-columns: var(--drawer-width) 100%;
  height: 100%;
  overflow-x: scroll;
  overscroll-behavior: none;
  scrollbar-width: none;
  scroll-snap-type: x mandatory;
}
.Drawer-scroller::-webkit-scrollbar { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .Drawer-scroller { scroll-behavior: smooth; }
}
.Drawer-scroller::after {
  content: "";
  scroll-snap-align: end;
  scroll-initial-target: nearest;
}
.Drawer-sheet {
  display: grid;
  grid-template-rows: auto 1fr;
  align-content: start;
  height: 100svh;
  background: #fff;
  color: var(--ink);
  overflow-y: auto;
  scroll-snap-align: start;
  scrollbar-width: none;
  box-shadow: 8px 0 32px rgba(6, 20, 43, .25);
}
.Drawer-sheet:focus { outline: none; }
.Drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 16px 20px;
  border-bottom: 1px solid var(--line);
}
.Drawer-head img { width: 150px; }
.Drawer-links { list-style: none; margin: 0; padding: 12px; display: grid; gap: 2px; align-content: start; }
.Drawer-links a:not(.btn) {
  display: block;
  padding: 12px;
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}
.Drawer-links a:not(.btn):hover { background: var(--bg-alt); color: var(--navy); }
.Drawer-links li:last-child { margin-top: 12px; }

@supports (animation-timeline: scroll()) {
  .Drawer {
    timeline-scope: --drawer-fade;
    animation: fade-drawer-backdrop linear both;
    animation-timeline: --drawer-fade;
  }
  .Drawer-scroller { scroll-timeline: --drawer-fade x; }
  @property --drawer-backdrop {
    syntax: "<number>";
    inherits: true;
    initial-value: 0;
  }
  @keyframes fade-drawer-backdrop {
    0% { --drawer-backdrop: 1; }
    100% { --drawer-backdrop: 0; }
  }
}

/* ---------- Seções ---------- */
.section { padding-block: clamp(56px, 8vw, 104px); }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 760px; margin-bottom: clamp(28px, 4vw, 48px); }
.section-lead { font-size: 1.15rem; color: var(--muted); }

.eyebrow {
  margin: 0 0 12px;
  color: var(--text-blue);
  font-size: .85rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 4px;
  margin-right: 10px;
  vertical-align: middle;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--sky) 50%, var(--papaya) 50%);
}
.eyebrow-light { color: var(--sky-light); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(48px, 7vw, 96px) clamp(56px, 8vw, 104px);
  background:
    radial-gradient(circle at 92% 8%, rgba(35, 166, 230, .12), transparent 38%),
    radial-gradient(circle at 70% 100%, rgba(255, 128, 0, .10), transparent 40%),
    var(--bg);
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.lead { font-size: clamp(1.1rem, 1rem + .4vw, 1.25rem); color: var(--muted); max-width: 40em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.hero-visual { margin: 0; }
.hero-visual figcaption, .funnel-card figcaption {
  margin-top: 12px;
  font-size: .85rem;
  color: var(--muted);
}

.mock {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px;
  display: grid;
  gap: 16px;
}
.mock-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.mock-kicker { font-size: .8rem; font-weight: 700; color: var(--muted); }
.mock-title { font-size: 1.2rem; font-weight: 800; color: var(--navy); }
.pill {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 700;
  white-space: nowrap;
}
.pill-warn { background: var(--warn-bg); color: var(--warn-ink); }

.mock-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.mock-label { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.mock-value { font-weight: 800; font-size: 1.1rem; font-variant-numeric: lining-nums tabular-nums; }
.mock-sub { grid-column: 1 / -1; font-size: .85rem; color: var(--muted); }
.mock-row .bar { grid-column: 1 / -1; }
.tone-a { color: var(--text-blue); }
.tone-b { color: var(--papaya-text); }

.key {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  font-size: .85rem;
  font-weight: 800;
}
.key-a { background: #DDF0FB; color: var(--text-blue); }
.key-b { background: #FFE9D1; color: var(--papaya-text); }
.key-c { background: #ECEFF3; color: var(--muted); }

.mock-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: var(--navy);
  color: #fff;
  font-weight: 700;
}
.mock-total strong { font-size: 1.35rem; font-weight: 800; font-variant-numeric: lining-nums tabular-nums; }

/* Barras (larguras por classe, sem estilo inline) */
.bar { display: block; height: 8px; border-radius: 999px; background: #ECEFF3; overflow: hidden; }
.bar-lg { height: 14px; }
.fill { display: block; height: 100%; border-radius: 999px; }
.fill-a { background: var(--sky); }
.fill-b { background: var(--papaya); }
.fill-navy { background: linear-gradient(90deg, var(--sky) 0 62%, #7FC9EF 62% 70%, var(--papaya) 70% 100%); }
.w-27 { width: 27%; }
.w-52 { width: 52%; }
.w-73 { width: 73%; }
.w-88 { width: 88%; }
.w-96 { width: 96%; }
.w-100 { width: 100%; }

/* ---------- Cartões ---------- */
.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 20px; }
.cards-4 { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.card p { margin: 0; color: var(--muted); }
.card-icon {
  width: 40px;
  height: 40px;
  padding: 8px;
  margin-bottom: 16px;
  border-radius: 10px;
  background: #E7F4FC;
  color: var(--text-blue);
}
.cards li:nth-child(even) .card-icon { background: #FFEEDB; color: var(--papaya-text); }
.roles .card { border-top: 4px solid var(--sky); }
.roles .card:nth-child(even) { border-top-color: var(--papaya); }

/* ---------- Etapas ---------- */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  counter-reset: step;
}
.step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.step p { color: var(--muted); margin: 0; }
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin-bottom: 16px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-weight: 800;
  font-size: 1.1rem;
}
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0 0; padding: 0; }
.chips li {
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  font-size: .8rem;
  font-weight: 700;
  color: var(--navy);
}

/* ---------- Seção escura: o espelho ---------- */
.section-dark {
  background:
    radial-gradient(circle at 0% 0%, rgba(35, 166, 230, .18), transparent 45%),
    radial-gradient(circle at 100% 100%, rgba(255, 128, 0, .14), transparent 45%),
    var(--navy);
  color: #E3EBF7;
}
.section-dark h2, .section-dark h3 { color: #fff; }
.section-dark .section-lead { color: #C7D5EA; }

.equation {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, .8fr);
  align-items: stretch;
  gap: 12px;
}
.eq-block {
  position: relative;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: var(--radius);
  padding: 22px;
}
.eq-block p { color: #C7D5EA; font-size: .98rem; margin: 0 0 .8em; }
.eq-block p:last-child { margin-bottom: 0; }
.eq-key {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  margin-bottom: 12px;
  border-radius: 9px;
  font-weight: 800;
}
.eq-a { border-top: 4px solid var(--sky); }
.eq-a .eq-key { background: var(--sky); color: var(--navy); }
.eq-b { border-top: 4px solid var(--papaya); }
.eq-b .eq-key { background: var(--papaya); color: var(--navy); }
.eq-c .eq-key { background: rgba(255, 255, 255, .85); color: var(--navy); }
.eq-total { background: #fff; border-color: #fff; }
.eq-total h3 { color: var(--navy); }
.eq-total p { color: var(--muted); }
.eq-source { font-weight: 700; color: #fff !important; font-size: .9rem !important; }
.eq-op {
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .25);
  color: #fff;
}
.eq-total { display: flex; flex-direction: column; justify-content: center; }

.callout {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-top: 28px;
  padding: 20px 24px;
  border-radius: var(--radius);
  background: rgba(255, 128, 0, .12);
  border: 1px solid rgba(255, 128, 0, .45);
  color: #fff;
}
.callout svg { flex: none; color: var(--papaya); }
.callout p { margin: 0; font-size: 1.05rem; }

@media (max-width: 1080px) {
  .equation { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .eq-op { display: none; }
}
@media (max-width: 560px) {
  .equation { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Duas colunas ---------- */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.split-top { align-items: start; }
.split-top > div:first-child { position: sticky; top: calc(var(--header-h) + 24px); }
.split > div > p:not(.eyebrow) { color: var(--muted); font-size: 1.08rem; }

.checklist { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 12px; }
.checklist li { position: relative; padding-left: 34px; }
.checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .2em;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #E7F4FC url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230A6FA8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.funnel-card {
  margin: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px;
}
.funnel { display: grid; gap: 16px; }
.funnel-row { display: grid; grid-template-columns: 100px 1fr; align-items: center; gap: 14px; }
.funnel-label { font-weight: 700; color: var(--navy); font-size: .95rem; }
.source-legend { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 22px; font-size: .9rem; font-weight: 600; color: var(--muted); }
.source-legend span { display: inline-flex; align-items: center; gap: 8px; }
.dot { display: inline-block; width: 12px; height: 12px; border-radius: 3px; }
.dot-mac { background: var(--sky); }
.dot-faec { background: #7FC9EF; }
.dot-prop { background: var(--papaya); }

/* ---------- Recursos ---------- */
.features {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
}
.features li {
  padding: 24px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.features h3 { font-size: 1.05rem; }
.features p { margin: 0; color: var(--muted); font-size: .98rem; }

/* ---------- Segurança ---------- */
.sec-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.sec-list li {
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--navy);
  border-radius: var(--radius-sm);
  background: #fff;
}
.sec-list p { margin: 0; color: var(--muted); }

/* ---------- Perguntas ---------- */
.faq { display: grid; gap: 12px; }
.faq details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}
.faq details[open] { border-color: #B9CBE6; box-shadow: var(--shadow); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  min-height: 44px;
  cursor: pointer;
  font-weight: 700;
  color: var(--navy);
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid var(--navy);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230C326F' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.faq details[open] summary::after {
  background: var(--navy) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23FFFFFF' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M6 12h12'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.faq details p { margin: 0; padding: 0 22px 20px; color: var(--muted); }

/* ---------- Acesso ---------- */
.cta-band { background: var(--bg-alt); border-top: 1px solid var(--line); }
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(28px, 4vw, 48px);
  max-width: calc(var(--container) - 2 * var(--gutter));
  box-shadow: var(--shadow);
}
.cta-inner p { color: var(--muted); max-width: 46em; }
.cta-inner .cta-contact { color: var(--ink); margin-bottom: 0; }
.cta-symbol { flex: none; width: 120px; }

/* ---------- Rodapé ---------- */
.site-footer { background: #fff; border-top: 1px solid var(--line); }
.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  padding-block: 44px;
  align-items: start;
}
.footer-brand img { width: 178px; margin-bottom: 12px; }
.footer-brand p { color: var(--muted); font-size: .95rem; margin: 0; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.footer-nav a { color: var(--ink); font-weight: 600; text-decoration: none; display: inline-block; padding: 4px 0; }
.footer-nav a:hover { color: var(--blue); text-decoration: underline; }
.footer-bottom { background: var(--navy); color: #C7D5EA; font-size: .85rem; }
.footer-bottom p { margin: 0; padding-block: 14px; }

/* ---------- Páginas internas ---------- */
.back-link { margin-left: auto; }
.page-hero { padding-block: clamp(40px, 6vw, 72px) 8px; }
.prose { max-width: 760px; }
.prose h2 { font-size: 1.5rem; margin-top: 1.6em; }
.prose p, .prose li { color: var(--ink); }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; }
.updated { color: var(--muted); font-size: .95rem; }

.notfound { text-align: center; padding-block: clamp(64px, 12vw, 140px); }
.notfound img { margin: 0 auto 28px; width: 110px; }
.notfound p { color: var(--muted); }

/* ---------- Responsivo ---------- */
@media (max-width: 900px) {
  .hero-grid, .split { grid-template-columns: minmax(0, 1fr); }
  .split-top > div:first-child { position: static; }
  .hero-visual { max-width: 560px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-nav ul { display: flex; flex-wrap: wrap; gap: 4px 20px; }
}
@media (max-width: 640px) {
  :root { --gutter: 16px; --header-h: 64px; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
  .cta-symbol { width: 80px; order: -1; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1 1 100%; }
}
