/* ============================================================
   MERIDIANO — Inteligência de Gestão para Incorporadoras
   Paleta Midnight Executive · Playfair Display + Inter
   ============================================================ */

:root {
  --navy: #1E2761;
  --ink: #10142E;
  --ice: #CADCFC;
  --ice-2: #8FAEE0;
  --graphite: #2B2D42;
  --gold: #C9A24B;
  --gold-soft: #E3C88A;
  --bg-light: #F4F6FB;
  --white: #FFFFFF;
  --text: #2B2D42;
  --text-soft: #5A5F7A;
  --radius: 14px;
  --shadow: 0 10px 40px rgba(16, 20, 46, 0.10);
  --shadow-strong: 0 18px 60px rgba(16, 20, 46, 0.22);
  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', 'Segoe UI', Arial, sans-serif;
  --maxw: 1180px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg-light);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--navy); text-decoration: none; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- Tipografia ---------- */
h1, h2, h3 { font-family: var(--font-serif); color: var(--ink); line-height: 1.2; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 600; }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.5rem); font-weight: 600; }
h3 { font-size: 1.25rem; font-weight: 600; }

.kicker {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
}

.section { padding: 96px 0; }
.section-head { max-width: 780px; margin-bottom: 56px; }
.section-head p { color: var(--text-soft); margin-top: 16px; font-size: 1.1rem; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* Seções escuras */
.dark { background: linear-gradient(160deg, var(--navy) 0%, var(--ink) 70%); color: var(--ice); }
.dark h1, .dark h2, .dark h3 { color: var(--white); }
.dark p, .dark li { color: var(--ice); }
.dark .section-head p { color: var(--ice-2); }

/* ---------- Botões ---------- */
.btn {
  display: inline-block;
  padding: 15px 32px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.02em;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
  cursor: pointer;
  border: none;
  font-family: var(--font-sans);
}
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: var(--ink); box-shadow: 0 6px 22px rgba(201, 162, 75, .35); }
.btn-gold:hover { background: var(--gold-soft); }
.btn-outline { background: transparent; color: var(--ice); border: 1.5px solid var(--ice-2); }
.btn-outline:hover { border-color: var(--ice); background: rgba(202, 220, 252, .08); }
.btn-navy { background: var(--navy); color: var(--white); }
.btn-navy:hover { background: var(--ink); }

/* ---------- Header ---------- */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(16, 20, 46, .92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(143, 174, 224, .18);
  transition: background .25s ease;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.header .logo img { height: 40px; width: auto; }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a { color: var(--ice); font-size: .92rem; font-weight: 500; transition: color .18s; white-space: nowrap; }
.nav a:hover { color: var(--gold-soft); }
.nav .btn { padding: 10px 22px; font-size: .9rem; }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; }
.nav-toggle span { display: block; width: 26px; height: 2px; background: var(--ice); margin: 6px 0; transition: .25s; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 190px 0 130px;
  overflow: hidden;
  background: radial-gradient(ellipse at 25% 15%, var(--navy) 0%, var(--ink) 65%);
}
.hero-mesh { position: absolute; inset: 0; opacity: .5; pointer-events: none; }
.hero-content { position: relative; max-width: 760px; }
.hero h1 { color: var(--white); margin-bottom: 24px; }
.hero h1 .gold { color: var(--gold); }
.hero .sub { font-size: 1.25rem; color: var(--ice); max-width: 620px; margin-bottom: 40px; }
.hero-ctas { display: flex; gap: 18px; flex-wrap: wrap; }
.hero-note { margin-top: 28px; font-size: .9rem; color: var(--ice-2); }

/* ---------- Grid de cards ---------- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 28px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(30, 39, 97, .06);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-strong); }
.card .icon { width: 46px; height: 46px; margin-bottom: 18px; }
.card h3 { margin-bottom: 10px; }
.card p { color: var(--text-soft); font-size: .97rem; }

.dark .card { background: rgba(244, 246, 251, .05); border: 1px solid rgba(143, 174, 224, .2); box-shadow: none; }
.dark .card h3 { color: var(--white); }
.dark .card p { color: var(--ice-2); }

/* ---------- Estatísticas ---------- */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.stat { text-align: center; padding: 40px 24px; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); }
.stat .num { font-family: var(--font-serif); font-size: 3rem; font-weight: 700; color: var(--navy); }
.stat .num span { color: var(--gold); }
.stat .label { color: var(--text-soft); font-size: .95rem; margin-top: 8px; }
.stats-footnote { margin-top: 20px; font-size: .82rem; color: var(--text-soft); text-align: center; }

/* ---------- Pilares (Encontra/Vigia/Recomenda) ---------- */
.pillar { text-align: center; }
.pillar .num { font-family: var(--font-serif); font-size: 1rem; color: var(--gold); letter-spacing: .2em; margin-bottom: 10px; }

/* ---------- Malha radial (domínios) ---------- */
.mesh-wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.mesh-svg { width: 100%; height: auto; }
.mesh-svg .node { cursor: pointer; transition: opacity .2s; }
.mesh-svg .node:hover circle.halo { opacity: 1; }
.mesh-info { background: rgba(244, 246, 251, .05); border: 1px solid rgba(143, 174, 224, .25); border-radius: var(--radius); padding: 32px; min-height: 180px; }
.mesh-info h3 { color: var(--gold-soft); margin-bottom: 10px; }
.mesh-info p { color: var(--ice); }

/* ---------- Pipeline de dados ---------- */
.pipeline { display: grid; grid-template-columns: repeat(7, 1fr); gap: 0; margin: 48px 0 16px; position: relative; }
.pipe-step { position: relative; text-align: center; padding: 0 8px; }
.pipe-step .dot {
  width: 54px; height: 54px; margin: 0 auto 14px;
  border-radius: 50%;
  background: rgba(202, 220, 252, .07);
  border: 1.5px solid var(--ice-2);
  display: flex; align-items: center; justify-content: center;
}
.pipe-step .dot svg { width: 26px; height: 26px; }
.pipe-step::after {
  content: ""; position: absolute; top: 27px; left: calc(50% + 30px); right: calc(-50% + 30px);
  height: 1.5px; background: linear-gradient(90deg, var(--ice-2), rgba(143,174,224,.25));
}
.pipe-step:last-child::after { display: none; }
.pipe-step h4 { color: var(--white); font-size: .92rem; font-family: var(--font-sans); font-weight: 600; margin-bottom: 4px; }
.pipe-step p { font-size: .8rem; color: var(--ice-2); line-height: 1.45; }

.tech-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 36px; }
.badge {
  font-size: .8rem; font-weight: 600; letter-spacing: .04em;
  color: var(--ice); border: 1px solid rgba(143, 174, 224, .4);
  border-radius: 100px; padding: 7px 16px;
}
.badge.gold { color: var(--gold-soft); border-color: rgba(201, 162, 75, .5); }

/* ---------- Regra de Ouro / FCA ---------- */
.golden-rule { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 40px; }
.gr-col { border-radius: var(--radius); padding: 36px 32px; }
.gr-col.rule { background: var(--white); box-shadow: var(--shadow); border-top: 4px solid var(--navy); }
.gr-col.agent { background: var(--ink); border-top: 4px solid var(--gold); }
.gr-col.agent h3, .gr-col.agent p, .gr-col.agent li { color: var(--ice); }
.gr-col h3 { margin-bottom: 14px; }
.gr-col ul { list-style: none; margin-top: 14px; }
.gr-col li { padding-left: 26px; position: relative; margin-bottom: 10px; font-size: .95rem; color: var(--text-soft); }
.gr-col li::before { content: "—"; position: absolute; left: 0; color: var(--gold); font-weight: 700; }

.fca { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; gap: 18px; align-items: stretch; margin-top: 48px; }
.fca-card { background: var(--white); border-radius: var(--radius); padding: 34px 28px; box-shadow: var(--shadow); text-align: center; border-top: 4px solid var(--ice-2); }
.fca-card.fato { border-top-color: var(--navy); }
.fca-card.causa { border-top-color: var(--gold); }
.fca-card.acao { border-top-color: #2E7D5B; }
.fca-card .letter { font-family: var(--font-serif); font-size: 2.6rem; font-weight: 700; color: var(--navy); }
.fca-card.causa .letter { color: var(--gold); }
.fca-card.acao .letter { color: #2E7D5B; }
.fca-card h3 { margin: 6px 0 10px; }
.fca-card p { font-size: .93rem; color: var(--text-soft); }
.fca-card .tag { display: inline-block; margin-top: 16px; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 6px 14px; border-radius: 100px; background: var(--bg-light); color: var(--navy); }
.fca-arrow { display: flex; align-items: center; color: var(--ice-2); font-size: 1.6rem; }

/* ---------- Casos de uso (fala do gestor de IA) ---------- */
.quote-card { background: var(--white); border-radius: var(--radius); padding: 30px 28px; box-shadow: var(--shadow); border-left: 4px solid var(--gold); }
.quote-card .who { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.quote-card .who .avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--navy); display: flex; align-items: center; justify-content: center; }
.quote-card .who .avatar svg { width: 20px; height: 20px; }
.quote-card .who strong { font-size: .9rem; color: var(--navy); }
.quote-card blockquote { font-size: .97rem; color: var(--graphite); font-style: italic; }

/* ---------- Fases / metodologia ---------- */
.phases { counter-reset: phase; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.phase { background: var(--white); border-radius: var(--radius); padding: 30px 26px; box-shadow: var(--shadow); position: relative; }
.phase::before {
  counter-increment: phase; content: counter(phase, decimal-leading-zero);
  font-family: var(--font-serif); font-size: 2.2rem; font-weight: 700; color: var(--ice-2);
  display: block; margin-bottom: 10px;
}
.phase h3 { font-size: 1.08rem; margin-bottom: 8px; }
.phase p { font-size: .92rem; color: var(--text-soft); }

/* ---------- Formulário ---------- */
.form-wrap { max-width: 680px; margin: 0 auto; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-strong); padding: 48px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: .88rem; font-weight: 600; color: var(--graphite); }
.field input, .field select, .field textarea {
  padding: 13px 15px; border: 1.5px solid #D6DAEB; border-radius: 8px;
  font-family: var(--font-sans); font-size: 1rem; color: var(--graphite);
  background: var(--bg-light); transition: border-color .18s;
  width: 100%; min-width: 0; max-width: 100%;
}
.form-grid > * { min-width: 0; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--navy); }
.field .error-msg { display: none; font-size: .8rem; color: #B4413C; }
.field.invalid input, .field.invalid select { border-color: #B4413C; }
.field.invalid .error-msg { display: block; }
.form-status { margin-top: 18px; font-size: .95rem; display: none; }
.form-status.ok { display: block; color: #2E7D5B; }
.form-status.err { display: block; color: #B4413C; }
.form-consent { grid-column: 1 / -1; display: flex; gap: 10px; align-items: flex-start; font-size: .84rem; color: var(--text-soft); }
.form-consent input { margin-top: 4px; }

/* ---------- Rodapé ---------- */
.footer { background: var(--ink); color: var(--ice-2); padding: 64px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer .logo img { height: 44px; margin-bottom: 18px; }
.footer h4 { color: var(--white); font-size: .95rem; margin-bottom: 14px; font-family: var(--font-sans); }
.footer a { color: var(--ice-2); font-size: .9rem; display: block; margin-bottom: 8px; }
.footer a:hover { color: var(--gold-soft); }
.footer-bottom { border-top: 1px solid rgba(143, 174, 224, .18); padding-top: 24px; font-size: .8rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* ---------- Cookie banner (LGPD) ---------- */
.cookie-banner {
  position: fixed; bottom: 20px; left: 20px; right: 20px; z-index: 200;
  max-width: 560px; margin: 0 auto;
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-strong);
  padding: 24px; display: none; gap: 16px; align-items: center; flex-wrap: wrap;
}
.cookie-banner.show { display: flex; }
.cookie-banner p { font-size: .85rem; color: var(--text-soft); flex: 1 1 300px; }
.cookie-banner .btn { padding: 10px 20px; font-size: .85rem; }

/* ---------- Página interna ---------- */
.page-hero { padding: 160px 0 80px; }
.page-hero p { max-width: 700px; font-size: 1.15rem; }
.prose { max-width: 820px; }
.prose h2 { margin: 48px 0 16px; }
.prose h3 { margin: 32px 0 12px; }
.prose p, .prose li { color: var(--text-soft); margin-bottom: 14px; }
.prose ul { padding-left: 22px; }

/* ---------- Responsivo ---------- */
@media (max-width: 980px) {
  .grid-3, .stats, .phases { grid-template-columns: 1fr 1fr; }
  .mesh-wrap { grid-template-columns: 1fr; }
  .pipeline { grid-template-columns: repeat(4, 1fr); row-gap: 36px; }
  .pipe-step:nth-child(4)::after { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .fca { grid-template-columns: 1fr; }
  .fca-arrow { justify-content: center; transform: rotate(90deg); }
}
@media (max-width: 1140px) {
  /* backdrop-filter no header faria dele o bloco de contenção do menu fixed,
     colapsando o painel — desligado aqui para o menu ocupar a tela toda */
  .header { backdrop-filter: none; background: rgba(16, 20, 46, .97); }
  .nav { position: fixed; top: 72px; right: 0; height: calc(100vh - 72px); width: 78%; max-width: 340px;
    background: var(--ink); flex-direction: column; align-items: flex-start; padding: 36px 28px;
    gap: 22px; transform: translateX(105%); visibility: hidden; overflow-y: auto;
    box-shadow: -16px 0 48px rgba(0, 0, 0, .4);
    transition: transform .28s ease, visibility 0s linear .28s; }
  .nav.open { transform: translateX(0); visibility: visible; transition: transform .28s ease, visibility 0s; }
  .nav-toggle { display: block; }
}
@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .hero { padding: 140px 0 90px; }
  .grid-2, .grid-3, .stats, .phases, .golden-rule, .form-grid, .pipeline { grid-template-columns: 1fr; }
  .pipe-step::after { display: none; }
  .form-wrap { padding: 32px 22px; }
}

/* ---------- Banner do diagnóstico na home ---------- */
.diag-banner {
  margin-top: 48px;
  background: linear-gradient(135deg, var(--navy) 0%, var(--ink) 80%);
  border-radius: var(--radius);
  box-shadow: var(--shadow-strong);
  padding: 44px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 36px;
}
.diag-banner h3 { color: var(--white); font-size: 1.5rem; margin: 4px 0 10px; }
.diag-banner p { color: var(--ice-2); font-size: .95rem; max-width: 640px; }
.diag-banner .btn { flex-shrink: 0; }
@media (max-width: 860px) {
  .diag-banner { flex-direction: column; align-items: flex-start; padding: 32px 26px; }
}

/* ---------- Diagnóstico de maturidade (quiz) ---------- */
.method-box {
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  border-left: 4px solid var(--gold); padding: 32px 30px; margin: 40px 0;
}
.method-box h3 { margin-bottom: 12px; }
.method-box p { color: var(--text-soft); font-size: .95rem; margin-bottom: 10px; }
.method-box ul { list-style: none; margin: 14px 0; }
.method-box li { padding-left: 26px; position: relative; margin-bottom: 8px; font-size: .93rem; color: var(--text-soft); }
.method-box li::before { content: "—"; position: absolute; left: 0; color: var(--gold); font-weight: 700; }

.quiz-shell { max-width: 760px; margin: 0 auto; }
.quiz-progress { height: 6px; background: #E2E7F5; border-radius: 100px; margin-bottom: 12px; overflow: hidden; }
.quiz-progress .bar { height: 100%; width: 0; background: linear-gradient(90deg, var(--navy), var(--gold)); border-radius: 100px; transition: width .3s ease; }
.quiz-meta { display: flex; justify-content: space-between; font-size: .82rem; color: var(--text-soft); margin-bottom: 28px; }
.quiz-dim { color: var(--gold); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

.quiz-card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 42px 38px; }
.quiz-card h3 { font-size: 1.35rem; margin-bottom: 26px; }
.quiz-option {
  display: block; width: 100%; text-align: left; margin-bottom: 12px; padding: 16px 18px;
  border: 1.5px solid #D6DAEB; border-radius: 10px; background: var(--bg-light);
  font-family: var(--font-sans); font-size: .95rem; color: var(--graphite);
  cursor: pointer; transition: border-color .15s, background .15s, transform .15s;
}
.quiz-option:hover { border-color: var(--navy); background: #EDF1FA; transform: translateX(4px); }
.quiz-option.selected { border-color: var(--gold); background: #FBF6EA; }
.quiz-back { margin-top: 18px; background: none; border: none; color: var(--text-soft); font-size: .88rem; cursor: pointer; font-family: var(--font-sans); }
.quiz-back:hover { color: var(--navy); text-decoration: underline; }

.result-level { text-align: center; margin-bottom: 40px; }
.result-level .badge-level {
  display: inline-block; font-family: var(--font-serif); font-size: 2rem; font-weight: 700;
  color: var(--navy); border: 2px solid var(--gold); border-radius: 100px; padding: 12px 44px;
}
.result-level .score-line { margin-top: 14px; color: var(--text-soft); font-size: .95rem; }
.result-radar { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; margin: 40px 0; }
.result-radar svg { width: 100%; height: auto; }
.dim-list { list-style: none; }
.dim-list li { display: flex; justify-content: space-between; gap: 14px; padding: 10px 0; border-bottom: 1px solid #E2E7F5; font-size: .93rem; }
.dim-list .dim-score { font-weight: 700; color: var(--navy); white-space: nowrap; }
.dim-list .weak .dim-score { color: #B4413C; }
.dim-list .strong .dim-score { color: #2E7D5B; }

@media (max-width: 720px) {
  .quiz-card { padding: 28px 20px; }
  .result-radar { grid-template-columns: 1fr; }
}

/* Acessibilidade: foco visível */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid var(--gold); outline-offset: 2px;
}

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