/* ==========================================================================
   GAO Contábeis — identidade visual conforme o Manual de Identidade Visual
   Cores principais: #005151 · #51284F · #89764B  |  Tipografia: Montserrat
   ========================================================================== */
:root {
  /* Principais */
  --teal: #005151;
  --teal-dark: #003b3b;
  --plum: #51284F;
  --gold: #89764B;
  --gold-light: #b3a27a;
  --ink: #231F20;

  /* Secundárias */
  --gray-11: #53565A;
  --gray-6: #A7A8A9;
  --gray-1: #D9D9D6;
  --warm-11: #6E6259;
  --warm-6: #A59C94;
  --warm-1: #D7D2CB;

  /* Complementares (uso pontual) */
  --paper: #F4F2EF;
  --white: #FFFFFF;
  --red: #92611F;    /* tom terroso da paleta complementar para alertas */
  --amber: #EA8C3F;

  --radius: 4px;
  --radius-lg: 10px;
  --shadow: 0 20px 50px -24px rgba(0, 59, 59, .35);
  --font: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  --track: .22em;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-weight: 400;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
[hidden] { display: none !important; }

.container { width: min(1120px, 100% - 32px); margin-inline: auto; }
.container--narrow { width: min(860px, 100% - 32px); }

/* ---------- Tipografia ---------- */
.eyebrow {
  margin: 0 0 14px;
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow--light { color: var(--gold-light); }
.section__title {
  margin: 0 0 16px;
  font-size: clamp(1.7rem, 3.4vw, 2.5rem);
  font-weight: 300;
  line-height: 1.2;
  color: var(--teal);
  text-wrap: balance;
}
.section__title--light { color: var(--white); }
.section__lead { margin: 0; color: var(--gray-11); max-width: 60ch; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 28px;
  font: 600 .78rem/1 var(--font);
  letter-spacing: .16em; text-transform: uppercase; text-decoration: none;
  border: 1px solid transparent; border-radius: var(--radius);
  cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.btn:active { transform: translateY(1px); }
.btn:focus-visible, .choice input:focus-visible + span, .consent input:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.btn--sm { min-height: 40px; padding: 0 18px; font-size: .7rem; }
.btn--primary { background: var(--teal); color: var(--white); }
.btn--primary:hover { background: var(--teal-dark); }
.btn--gold { background: var(--gold); color: var(--white); }
.btn--gold:hover { background: #75653f; }
.btn--ghost { border-color: rgba(255,255,255,.5); color: var(--white); background: transparent; }
.btn--ghost:hover { background: rgba(255,255,255,.1); border-color: var(--white); }
.btn--outline { border-color: var(--gray-6); color: var(--gray-11); background: transparent; }
.btn--outline:hover { border-color: var(--teal); color: var(--teal); }
.link-btn { background: none; border: 0; padding: 8px; font: 500 .85rem var(--font); color: var(--teal); text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }

/* ---------- Topo ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(0, 81, 81, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.topbar__inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 16px; }
.topbar__logo img { width: 140px; height: auto; }
.topbar__nav { display: flex; align-items: center; gap: 28px; }
.topbar__nav a:not(.btn) {
  color: rgba(255,255,255,.8); text-decoration: none;
  font-size: .72rem; font-weight: 500; letter-spacing: var(--track); text-transform: uppercase;
}
.topbar__nav a:not(.btn):hover { color: var(--white); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(120% 90% at 85% 10%, #0a6464 0%, var(--teal) 45%, var(--teal-dark) 100%);
  color: var(--white);
  padding: clamp(72px, 12vw, 140px) 0 clamp(64px, 9vw, 110px);
}
.hero__monogram {
  position: absolute; right: -6%; bottom: -12%;
  width: min(760px, 90vw); aspect-ratio: 255 / 60;
  background: url("assets/logo-gao-branco.svg") no-repeat center / contain;
  opacity: .05; pointer-events: none;
}
.hero__photo {
  position: absolute; inset: 0 0 0 auto; width: 48%;
  background: url("assets/capa.jpg") no-repeat center 30% / cover;
}
/* funde a foto no verde da marca */
.hero__photo::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, var(--teal) 0%, rgba(0,81,81,.55) 22%, rgba(0,81,81,0) 55%),
    linear-gradient(0deg, rgba(0,59,59,.55) 0%, rgba(0,59,59,0) 35%);
}
.hero__inner { position: relative; max-width: min(620px, 50%); margin-left: max(16px, calc((100% - 1120px) / 2)); }
.hero__title {
  margin: 0 0 22px;
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 300; line-height: 1.15; text-wrap: balance;
}
.hero__title strong { font-weight: 600; color: var(--gold-light); }
.hero__lead { margin: 0 0 36px; font-size: clamp(1rem, 1.6vw, 1.12rem); font-weight: 300; color: rgba(255,255,255,.85); max-width: 58ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__facts {
  display: flex; flex-wrap: wrap; gap: 14px 40px;
  margin: 56px 0 0; padding: 28px 0 0; list-style: none;
  border-top: 1px solid rgba(255,255,255,.15);
  font-size: .85rem; color: rgba(255,255,255,.85);
}
.hero__facts span { display: block; font-size: .68rem; letter-spacing: var(--track); color: var(--gold-light); margin-bottom: 4px; }

/* ---------- Seções ---------- */
.section { padding: clamp(64px, 10vw, 110px) 0; }
.section__head { text-align: center; margin-bottom: 44px; }
.section__head .section__lead { margin-inline: auto; }
.section__head--left { text-align: left; }
.section__head--left .section__lead { margin-inline: 0; }

/* ---------- Formulário ---------- */
.card { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.form-card { padding: clamp(24px, 5vw, 48px); position: relative; overflow: hidden; }
.progress { position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--gray-1); }
.progress__bar { height: 100%; width: 25%; background: linear-gradient(90deg, var(--teal), var(--gold)); transition: width .4s ease; }

.steps { display: flex; gap: 8px; margin: 0 0 36px; padding: 0; list-style: none; counter-reset: s; }
.steps li {
  flex: 1; display: flex; align-items: center; gap: 10px;
  font-size: .72rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--gray-6);
}
.steps li span {
  flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
  border: 1px solid var(--gray-1); font-size: .75rem; letter-spacing: 0;
}
.steps li.is-active { color: var(--teal); }
.steps li.is-active span { background: var(--teal); border-color: var(--teal); color: var(--white); }
.steps li.is-done { color: var(--gold); }
.steps li.is-done span { border-color: var(--gold); color: var(--gold); }

.step__title { margin: 0 0 24px; font-size: 1.35rem; font-weight: 400; color: var(--teal); }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 20px; }
.field { grid-column: 1 / -1; margin: 0; padding: 0; border: 0; min-width: 0; }
.field--half { grid-column: span 1; }
.field__label { display: block; margin-bottom: 8px; padding: 0; font-size: .86rem; font-weight: 500; color: var(--ink); }
.field__hint { margin: -4px 0 10px; font-size: .8rem; color: var(--gray-11); }
.field input[type="text"], .field input[type="email"], .field input[type="tel"], .field select {
  width: 100%; min-height: 50px; padding: 0 14px;
  font: 400 1rem var(--font); color: var(--ink);
  background: var(--paper); border: 1px solid var(--warm-1); border-radius: var(--radius);
  transition: border-color .2s, background .2s; appearance: none;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23005151' stroke-width='1.6' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--teal); background: var(--white); box-shadow: 0 0 0 3px rgba(0,81,81,.12); }
.field__error { margin: 6px 0 0; min-height: 0; font-size: .78rem; color: var(--plum); font-weight: 500; }
.field__error:empty { display: none; }
.is-invalid input[type="text"], .is-invalid input[type="email"], .is-invalid input[type="tel"], .is-invalid select { border-color: var(--plum); }
.is-invalid .choice span { border-color: rgba(81,40,79,.45); }

.choices { display: flex; flex-wrap: wrap; gap: 10px; }
.choices--grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice span {
  display: flex; align-items: center; gap: 10px; height: 100%;
  min-height: 48px; padding: 10px 16px;
  font-size: .9rem; line-height: 1.35;
  background: var(--paper); border: 1px solid var(--warm-1); border-radius: var(--radius);
  transition: border-color .15s, background .15s, color .15s;
}
.choice span::before {
  content: ""; flex: none; width: 16px; height: 16px;
  border: 1.5px solid var(--gray-6); border-radius: 50%; background: var(--white);
  transition: border-color .15s, box-shadow .15s;
}
.choice input[type="checkbox"] + span::before { border-radius: 3px; }
.choice:hover span { border-color: var(--teal); }
.choice input:checked + span { background: rgba(0,81,81,.07); border-color: var(--teal); color: var(--teal); font-weight: 500; }
.choice input:checked + span::before { border-color: var(--teal); box-shadow: inset 0 0 0 4px var(--white); background: var(--teal); }
.choice input[type="checkbox"]:checked + span::before {
  box-shadow: none;
  background: var(--teal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='8'%3E%3Cpath d='M1 4l3 3 5-6' stroke='white' stroke-width='1.8' fill='none'/%3E%3C/svg%3E") no-repeat center;
}

.choices--scale { display: grid; grid-template-columns: repeat(5, 1fr); }
.choices--scale .choice span { justify-content: center; font-weight: 600; }
.choices--scale .choice span::before { display: none; }
.scale-legend { display: flex; justify-content: space-between; margin-top: 6px; font-size: .74rem; color: var(--gray-6); }

.consent { display: flex; gap: 12px; align-items: flex-start; font-size: .84rem; color: var(--gray-11); cursor: pointer; }
.consent input { flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--teal); }

.form-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 36px; padding-top: 28px; border-top: 1px solid var(--gray-1); }

/* ---------- Relatório ---------- */
.report { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: clamp(24px, 5vw, 52px); }
.report__header { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-bottom: 24px; border-bottom: 1px solid var(--gray-1); }
.report__logo { width: 150px; height: auto; }
.report__meta { text-align: right; font-size: .82rem; color: var(--gray-11); }
.report__meta p { margin: 0; }
.report__meta .eyebrow { margin-bottom: 4px; }

.report__hero { display: grid; grid-template-columns: 1fr auto; gap: 32px; align-items: center; padding: 36px 0; }
.report__title { margin: 0 0 14px; font-size: clamp(1.4rem, 3vw, 1.9rem); font-weight: 300; line-height: 1.25; color: var(--teal); }
.report__title strong { font-weight: 600; }
.report__level { margin: 0 0 8px; font-size: .78rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--gray-11); }
.report__hero p:last-child { margin: 0; color: var(--gray-11); }

.tag { display: inline-block; margin-left: 6px; padding: 4px 10px; border-radius: 99px; font-size: .72rem; letter-spacing: .08em; color: var(--white); }
.tag--great, .tag--good { background: var(--teal); }
.tag--mid { background: var(--gold); }
.tag--low { background: var(--plum); }

.ring { width: 150px; height: 150px; transform: rotate(-90deg); }
.ring text { transform: rotate(90deg); transform-origin: 64px 64px; text-anchor: middle; font-family: var(--font); }
.ring__track { fill: none; stroke: var(--gray-1); stroke-width: 10; }
.ring__value { fill: none; stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 1s ease; }
.ring--great .ring__value, .ring--good .ring__value { stroke: var(--teal); }
.ring--mid .ring__value { stroke: var(--gold); }
.ring--low .ring__value { stroke: var(--plum); }
.ring__num { font-size: 34px; font-weight: 600; fill: var(--ink); }
.ring__den { font-size: 11px; fill: var(--gray-11); letter-spacing: .1em; }

.report__block { padding: 28px 0; border-top: 1px solid var(--gray-1); }
.report__block h3 { margin: 0 0 18px; font-size: .78rem; font-weight: 600; letter-spacing: var(--track); text-transform: uppercase; color: var(--teal); }
.report__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0 36px; }
.report__block--alert h3 { color: var(--plum); }
.report__block--opp h3 { color: var(--gold); }

.pillars { display: grid; gap: 20px; margin: 0; padding: 0; list-style: none; }
.pillar__head { display: flex; justify-content: space-between; font-size: .92rem; margin-bottom: 8px; }
.pillar__head strong { font-weight: 600; }
.pillar__bar { height: 8px; background: var(--gray-1); border-radius: 99px; overflow: hidden; }
.pillar__fill { display: block; height: 100%; border-radius: inherit; }
.pillar__fill--good { background: var(--teal); }
.pillar__fill--mid { background: var(--gold); }
.pillar__fill--low { background: var(--plum); }
.pillar__tip { margin: 8px 0 0; font-size: .82rem; color: var(--gray-11); }

.bullets { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.bullets li { position: relative; padding-left: 20px; font-size: .9rem; color: var(--gray-11); }
.bullets li::before { content: ""; position: absolute; left: 0; top: .6em; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.report__block--alert .bullets li::before { background: var(--plum); }
.report__block--opp .bullets li::before { background: var(--gold); }

.report__score { text-align: center; }
.report__score-label { margin: 6px 0 0; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gray-11); }
.report__p { margin: 0 0 12px; font-size: .92rem; color: var(--gray-11); }

.compare-wrap { margin-top: 20px; overflow-x: auto; border: 1px solid var(--gray-1); border-radius: var(--radius); }
.compare { width: 100%; border-collapse: collapse; font-size: .84rem; }
.compare th, .compare td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--gray-1); }
.compare tr:last-child th, .compare tr:last-child td { border-bottom: 0; }
.compare thead th { background: var(--teal); color: var(--white); font-size: .7rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.compare tbody th { width: 26%; font-weight: 600; color: var(--teal); background: var(--paper); }
.compare td { color: var(--gray-11); }

.timeline { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.timeline li { padding: 16px; border-top: 3px solid var(--gray-1); background: var(--paper); border-radius: 0 0 var(--radius) var(--radius); }
.timeline strong { display: block; margin-bottom: 6px; color: var(--teal); font-size: 1rem; }
.timeline span { font-size: .8rem; color: var(--gray-11); line-height: 1.5; }
.timeline li.is-now { border-top-color: var(--gold); background: rgba(137,118,75,.1); }
.timeline li.is-now strong::after { content: " · agora"; color: var(--gold); font-size: .7rem; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; }

.profile { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 24px; margin: 0; }
.profile dt { font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gray-6); margin-bottom: 4px; }
.profile dd { margin: 0; font-size: .9rem; }

.report__next { margin-top: 12px; padding: clamp(24px, 4vw, 40px); border-radius: var(--radius-lg); background: var(--teal); color: rgba(255,255,255,.88); }
.report__next h3 { margin: 0 0 12px; font-size: 1.35rem; font-weight: 300; color: var(--white); }
.report__next p { margin: 0; }
.report__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.report__disclaimer { margin: 20px 0 0; font-size: .74rem; color: var(--gray-6); text-align: center; }
.report__restart { text-align: center; margin-top: 8px; }

/* ---------- Serviços ---------- */
.services { background: var(--white); }
.services__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--gray-1); border: 1px solid var(--gray-1); }
.service { background: var(--white); padding: 36px 32px; transition: background .2s; }
.service:hover { background: var(--paper); }
.service__num { display: block; margin-bottom: 26px; font-size: .72rem; font-weight: 500; letter-spacing: var(--track); color: var(--gold); }
.service h3 { margin: 0 0 10px; font-size: 1.12rem; font-weight: 500; color: var(--teal); }
.service p { margin: 0; font-size: .92rem; color: var(--gray-11); }

/* ---------- Contato ---------- */
.contact { background: var(--plum); color: var(--white); }
.contact__inner { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.contact__lead { margin: 0 0 28px; color: rgba(255,255,255,.8); }
.contact__list { margin: 0; padding: 0; list-style: none; display: grid; gap: 4px; }
.contact__list li { display: grid; grid-template-columns: 120px 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.15); }
.contact__label { font-size: .7rem; letter-spacing: var(--track); text-transform: uppercase; color: var(--warm-6); padding-top: 3px; }
.contact__list a { text-decoration: none; overflow-wrap: anywhere; }
.contact__list a:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Rodapé ---------- */
.footer { background: var(--paper); padding: 32px 0; border-top: 1px solid var(--warm-1); }
.footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer img { width: 120px; height: auto; }
.footer p { margin: 0; font-size: .78rem; color: var(--gray-11); }

/* ---------- Responsivo ---------- */
@media (max-width: 900px) {
  .hero { padding-top: 0; }
  .hero__photo {
    position: relative; width: auto; height: 360px; margin-bottom: 8px;
    background-image: url("assets/capa-mobile.jpg"); background-position: center 32%;
  }
  .hero__photo::after { background: linear-gradient(0deg, var(--teal) 0%, rgba(0,81,81,.3) 40%, rgba(0,81,81,0) 70%); }
  .hero__inner { max-width: 820px; }
  .services__grid { grid-template-columns: 1fr 1fr; }
  .contact__inner { grid-template-columns: 1fr; }
  .report__cols { grid-template-columns: 1fr; }
  .profile { grid-template-columns: 1fr 1fr; }
  .timeline { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .topbar__nav a:not(.btn) { display: none; }
  .topbar__logo img { width: 116px; }
  .hero__actions .btn { flex: 1 1 100%; }  .hero__facts { gap: 14px 24px; }
  .fields { grid-template-columns: 1fr; }
  .field--half { grid-column: 1 / -1; }
  .steps li { font-size: 0; gap: 0; flex: none; }
  .steps { justify-content: space-between; }
  .steps li.is-active { font-size: .7rem; gap: 8px; flex: 1; }
  .choices--grid { grid-template-columns: 1fr; }
  .choices .choice { flex: 1 1 100%; }
  .form-actions .btn { flex: 1; padding: 0 14px; }
  .services__grid { grid-template-columns: 1fr; }
  .service { padding: 28px 24px; }
  .report__hero { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .report__hero > div { order: 2; }
  .ring { order: 1; }
  .profile { grid-template-columns: 1fr; }
  .timeline { grid-template-columns: 1fr; }
  /* tabela comparativa vira cartões empilhados */
  .compare-wrap { border: 0; overflow: visible; }
  .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: 100%; }
  .compare thead { display: none; }
  .compare tr { margin-bottom: 10px; border: 1px solid var(--gray-1); border-radius: var(--radius); overflow: hidden; }
  .compare tbody th { width: 100%; }
  .compare td { padding: 10px 14px; font-size: .84rem; }
  .compare td::before { content: attr(data-label); display: block; margin-bottom: 2px; font-size: .66rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
  .report__actions .btn { flex: 1 1 100%; }
  .contact__list li { grid-template-columns: 1fr; gap: 4px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* ---------- Impressão / PDF do relatório ---------- */
@media print {
  @page { size: A4; margin: 14mm; }
  body { background: var(--white); }
  .topbar, .hero, .section__head, .services, .contact, .footer, .no-print, .report__restart { display: none !important; }
  .section { padding: 0; }
  .container--narrow { width: 100%; }
  .report { box-shadow: none; padding: 0; }
  .report__next { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .pillar__fill, .tag, .ring__value, .bullets li::before { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .report__block, .report__next { break-inside: avoid; }
  .compare thead th, .compare tbody th, .timeline li { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .compare-wrap { overflow: visible; }
}
