/*
  Método FLORES — base global (reset, tipografia, header/menu, rodapé,
  botões, cards, formulários, alertas, breadcrumbs, foco, animações)
  Requer flores-tokens.css carregado antes deste arquivo.
  Carregar sempre por URL absoluta:
  https://dominesuasfinancaspessoais.com/assets/flores-base.css

  Cada página mantém, no seu próprio <style>, só o que é exclusivo dela
  (seções de venda, ilustrações, etc.) — sem redeclarar cor/fonte/raio.
*/

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-width: 320px;
  color: var(--plum);
  background: var(--paper);
  font-family: var(--font-sub);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
button, input, textarea, select { font: inherit; }
a { color: inherit; }
img, svg { max-width: 100%; }
.hidden { display: none !important; }
body.nav-open-lock { overflow: hidden; }

.container { width: 100%; max-width: var(--container-wide); margin-inline: auto; padding-inline: clamp(20px, 5vw, 64px); }
.narrow { width: 100%; max-width: var(--container-narrow); margin-inline: auto; padding-inline: clamp(20px, 5vw, 64px); }
.container-bio { width: min(var(--container-bio), 100%); margin-inline: auto; padding-inline: clamp(16px, 5vw, 28px); }
.text-intro { max-width: var(--container-text-lg); margin-inline: auto; }
.text-block { max-width: var(--container-text-md); }

.skip-link {
  position: fixed; left: 16px; top: -80px; z-index: 999;
  background: var(--plum); color: var(--cream);
  padding: 12px 18px; border-radius: 8px;
  font: 600 .82rem var(--font-sub);
  transition: top .2s ease;
}
.skip-link:focus { top: 16px; }

/* Tipografia */
h1, h2, h3 { font-family: var(--font-display); line-height: 1.12; margin: 0 0 18px; color: var(--plum); }
h1 { font-size: clamp(2.6rem, 6vw, 5rem); letter-spacing: -.03em; }
h2 { font-size: clamp(2.5rem, 4.2vw, 3.35rem); letter-spacing: -.02em; margin-bottom: var(--content-gap-sm); }
h3 { font-size: 1.4rem; }
p { margin: 0 0 var(--content-gap-sm); line-height: 1.7; }
.eyebrow { display: inline-block; color: var(--rose); font-weight: 700; text-transform: uppercase; letter-spacing: .16em; font-size: .8rem; margin-bottom: 14px; }
.eyebrow.light { color: var(--gold-light); }
.center { text-align: center; }
.section-heading { max-width: var(--container-text-lg); margin: 0 auto var(--content-gap-lg); }
.section-heading h2 { margin-bottom: var(--content-gap-sm); }
.section-heading p { color: var(--muted); font-size: 1.05rem; line-height: 1.75; }

/* Estados de foco — acessibilidade */
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid var(--gold-dark);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Cabeçalho + navegação (desktop e mobile) */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.header-inner { min-height: 80px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 13px; text-decoration: none; flex-shrink: 0; }
.brand-mark { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--cream); color: var(--rose); border: 1px solid rgba(196,115,107,.25); flex-shrink: 0; }
.brand strong { display: block; font-family: var(--font-display); font-size: 1.55rem; line-height: 1; color: var(--plum); }
.brand small { display: block; color: var(--muted); font-size: .68rem; margin-top: 4px; letter-spacing: .01em; }

.site-nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.site-nav > a, .nav-dropdown-toggle {
  display: inline-flex; align-items: center; padding-block: 10px;
  text-decoration: none; font-size: .9rem; font-weight: 600; color: var(--plum);
  background: none; border: 0; cursor: pointer; font-family: var(--font-sub);
  line-height: 1.3;
}
.site-nav > a:hover, .site-nav > a[aria-current="page"], .nav-dropdown-toggle:hover { color: var(--rose-dark); }

/* Dropdown "Soluções" — acessível via mouse, foco e teclado */
.nav-item-dropdown { position: relative; }
.nav-dropdown-toggle { gap: 5px; }
.nav-dropdown-toggle .chevron { width: 9px; height: 9px; transition: transform .18s ease; flex-shrink: 0; }
.nav-item-dropdown.is-open .nav-dropdown-toggle .chevron,
.nav-item-dropdown:hover .nav-dropdown-toggle .chevron { transform: rotate(180deg); }
.nav-dropdown-menu {
  position: absolute; top: calc(100% + 6px); left: 50%; transform: translateX(-50%);
  min-width: 248px; margin: 0; padding: 10px; list-style: none;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateX(-50%) translateY(4px);
  transition: opacity .16s ease, transform .16s ease, visibility .16s;
}
.nav-item-dropdown:hover .nav-dropdown-menu,
.nav-item-dropdown.is-open .nav-dropdown-menu {
  opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0);
}
.nav-dropdown-menu a {
  display: block; padding: 11px 14px; border-radius: 10px;
  font-size: .88rem; font-weight: 600; color: var(--plum); text-decoration: none;
}
.nav-dropdown-menu a:hover, .nav-dropdown-menu a:focus-visible { background: var(--cream); color: var(--rose-dark); }

.site-nav a.header-cta {
  text-decoration: none; color: var(--white); background: var(--rose);
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding-inline: 22px; border-radius: var(--radius-pill);
  font-size: .9rem; font-weight: 700; white-space: nowrap;
  box-shadow: 0 8px 20px rgba(196,115,107,.28);
  margin-left: 10px;
}
.site-nav a.header-cta:hover { background: var(--rose-dark); color: var(--white); }

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 10px;
  width: 44px; height: 44px;
  align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}
.nav-toggle svg { width: 20px; height: 20px; }
.nav-close { display: none; }
.nav-scrim { display: none; }

@media (max-width: 960px) {
  .nav-toggle {
    display: inline-flex;
    position: relative;
    z-index: 1002;
    margin-left: auto;
    color: var(--plum);
  }
  .site-nav {
    position: fixed; top: 0; right: 0; bottom: 0; z-index: 1001;
    width: min(86vw, 360px); max-width: 360px;
    background: var(--paper); flex-direction: column; align-items: stretch;
    gap: 2px; padding: 84px 24px 28px; box-shadow: var(--shadow);
    transform: translateX(100%); transition: transform .28s ease;
    overflow-y: auto;
  }
  .site-nav[data-open="true"] { transform: translateX(0); }
  .site-nav > a {
    padding: 15px 4px; min-height: 48px; width: 100%;
    border-bottom: 1px solid var(--line); font-size: 1rem;
  }
  .nav-close {
    position: absolute; top: 22px; right: 24px;
    border: 1px solid var(--line); background: var(--white); border-radius: 10px;
    width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; cursor: pointer;
  }
  .nav-close svg { width: 18px; height: 18px; }
  .nav-scrim {
    display: none; position: fixed; inset: 0; z-index: 1000;
    background: rgba(61,31,46,.32);
  }
  .nav-scrim[data-open="true"] { display: block; }

  .nav-item-dropdown { border-bottom: 1px solid var(--line); }
  .nav-dropdown-toggle {
    width: 100%; justify-content: space-between; padding: 15px 4px; min-height: 48px; font-size: 1rem;
  }
  .nav-dropdown-menu {
    position: static; transform: none; opacity: 1; visibility: visible;
    display: none; min-width: 0; width: 100%; box-shadow: none; border: 0;
    background: var(--cream); border-radius: 12px; margin: 4px 0 10px; padding: 6px;
  }
  .nav-item-dropdown.is-open .nav-dropdown-menu { display: block; }
  .nav-dropdown-menu a { padding: 13px 12px; min-height: 48px; display: flex; align-items: center; }
  .site-nav .header-cta { margin-top: 18px; margin-left: 0; width: 100%; min-height: 50px; }
  .header-cta { padding-inline: 20px; }
}

/* Breadcrumbs */
.breadcrumbs { padding: 14px 0; font-size: .78rem; color: var(--muted); }
.breadcrumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.breadcrumbs a { text-decoration: none; color: var(--muted); }
.breadcrumbs a:hover { color: var(--rose-dark); text-decoration: underline; }
.breadcrumbs li:not(:last-child)::after { content: "/"; margin-left: 6px; color: var(--gold-dark); }
.breadcrumbs [aria-current="page"] { color: var(--plum); font-weight: 600; }

/* Botões */
.button {
  border: 0; display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 24px; border-radius: var(--radius-pill);
  font-weight: 700; text-decoration: none; cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { color: var(--white); background: var(--rose); box-shadow: 0 12px 30px rgba(196,115,107,.25); }
.button-primary:hover { background: var(--rose-dark); }
.button-ghost { color: var(--plum); background: transparent; border: 1px solid var(--line); }
.button-dark { background: var(--plum); color: var(--cream); }
.button-dark:hover { background: #2d1522; }
.button-gold { background: var(--gold); color: var(--plum); text-align: center; }
.button-gold:hover { background: var(--gold-dark); color: var(--white); }
.button-products { background: transparent; color: var(--plum); border: 1px solid rgba(61,31,46,.22); text-align: center; }
.button-products:hover { background: var(--cream); border-color: var(--gold); }
.button[aria-disabled="true"] { opacity: .55; cursor: not-allowed; pointer-events: none; }

/* Grupo de botões (CTAs lado a lado, empilha no mobile) */
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-top: var(--content-gap-md); }

/* Cards */
.card {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--white); box-shadow: var(--shadow-sm);
  padding: 32px;
}
.card:hover { box-shadow: var(--shadow-md); }
@media (max-width: 640px) {
  .card { padding: 24px 22px; }
}

/* Formulários */
.field { display: grid; gap: 8px; font-size: .82rem; font-weight: 700; color: var(--plum); }
.field small { color: var(--muted); font-weight: 500; }
.field input, .field textarea, .text-input {
  width: 100%; min-height: 54px; border: 1px solid var(--line); border-radius: 14px;
  padding: 0 16px; font: inherit; background: var(--white); outline: none;
}
.field input:focus, .field textarea:focus, .text-input:focus {
  border-color: var(--rose); box-shadow: 0 0 0 4px rgba(196,115,107,.12);
}
.consent-row { display: flex; align-items: flex-start; gap: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--cream); font-size: .8rem; line-height: 1.55; cursor: pointer; }
.consent-row input { margin-top: 4px; accent-color: var(--rose); flex: 0 0 auto; }
.consent-row a { color: var(--rose); font-weight: 700; }
.honeypot { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-error { min-height: 22px; color: #9C3C3C; font-size: .8rem; margin: 14px 0 0; }

/* Alertas */
.alert { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: var(--radius-sm); font-size: .85rem; line-height: 1.5; border: 1px solid transparent; }
.alert-info { background: var(--lavender-light); border-color: rgba(155,137,180,.35); color: var(--plum); }
.alert-success { background: var(--sage-light); border-color: rgba(127,168,122,.4); color: #2F4A2C; }
.alert-error { background: rgba(156,60,60,.09); border-color: rgba(156,60,60,.35); color: #7A2E2E; }
.alert-pending { background: var(--gold-light); border-color: rgba(201,169,110,.5); color: #5A430F; }

/* Rodapé */
.site-footer { padding: var(--section-space-md) 0 calc(var(--section-space-md) * .55); background: #2D1722; color: var(--white); }
.footer-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.footer-inner p { color: #C8B8C0; font-size: .875rem; line-height: 1.7; margin: 8px 0; }
.footer-links { display: flex; flex-direction: column; gap: 12px; margin: 0 0 13px; padding: 0; list-style: none; }
.footer-links a { color: #F3D493; text-decoration: none; font: 600 .875rem/1.6 var(--font-sub); }
.footer-links a:hover { color: #FFFDF8; text-decoration: underline; text-underline-offset: 3px; }
.disclaimer { max-width: 520px; }

/* Rodapé — padrão em 3 colunas (footer.php / footer global) */
.site-footer .footer-columns { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 48px; margin-bottom: var(--content-gap-lg); }
.site-footer .footer-columns h4 { font-family: var(--font-sub); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--gold-light); margin: 0 0 18px; }
.footer-blurb { color: rgba(245,240,235,.82); font-size: .95rem; line-height: 1.7; max-width: 320px; }
.footer-notices { border-top: 1px solid rgba(255,255,255,.18); padding-top: var(--content-gap-md); margin-top: var(--content-gap-sm); }
.footer-notices p { color: rgba(245,240,235,.82); font-size: .875rem; line-height: 1.7; margin: 6px 0; }
.footer-notices p a { color: #F3D493; }
.footer-notices p a:hover { color: #FFFDF8; }
@media (max-width: 900px) {
  .site-footer .footer-columns { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 640px) {
  .site-footer .footer-columns { grid-template-columns: 1fr; gap: var(--content-gap-md); }
}

/* Animação discreta de entrada */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .55s ease, transform .55s ease; }
.reveal.visible, .reveal.is-visible { opacity: 1; transform: translateY(0); }

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

@media (max-width: 640px) {
  .site-header { position: static; }
  .header-inner { min-height: 68px; }
  .brand small { display: none; }
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2.1rem; }
  .footer-inner { grid-template-columns: 1fr; }
}
