/* Nascefil — componentes reutilizáveis: header, footer, cards, WhatsApp flutuante */

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 20px; height: 20px; flex: none; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background-color .3s var(--ease);
}
/* Sem backdrop-filter: o header fica sticky sobre o hero por toda a altura dele
   (0–100svh), que tem WebGL animando sem parar. Recompor um blur a cada frame
   ali é caro (chegou a travar a composição). Fundo sólido resolve sem esse custo. */
.site-header.is-scrolled { border-color: var(--border); background: rgba(246, 244, 238, 0.96); }
.header-inner { display: flex; align-items: center; gap: 20px; min-height: var(--header-h); }
.brand { display: flex; align-items: center; margin-right: auto; }
.brand img { height: 44px; width: auto; }

.site-nav { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 34px); }
.site-nav ul { display: flex; list-style: none; margin: 0; padding: 0; gap: clamp(14px, 1.8vw, 26px); }
.site-nav a { font-size: 0.94rem; font-weight: 600; color: var(--forest); text-decoration: none; }
.site-nav a:hover { color: var(--emerald-dark); }
.nav-cta { white-space: nowrap; }
.header-cta { display: none; }

.menu-toggle {
  display: none; position: relative; width: 44px; height: 44px; margin-inline-start: 6px;
  border: 1px solid var(--border-strong); border-radius: 999px; background: transparent; cursor: pointer;
}
.menu-toggle span { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--forest); border-radius: 2px; transition: transform .25s var(--ease), opacity .25s var(--ease); }
.menu-toggle span:first-child { top: 17px; }
.menu-toggle span:last-child { bottom: 17px; }
.menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 900px) {
  .site-nav {
    position: fixed; inset: var(--header-h) 0 0 0; z-index: 55;
    flex-direction: column; align-items: stretch; justify-content: space-between;
    padding: 28px var(--gutter) 32px; gap: 24px;
    background: var(--ivory);
    transform: translateY(-8px); opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity .25s var(--ease), transform .25s var(--ease), visibility .25s;
  }
  .site-nav.is-open { transform: none; opacity: 1; visibility: visible; pointer-events: auto; }
  .site-nav ul { flex-direction: column; gap: 4px; }
  .site-nav a { display: block; padding: 14px 4px; font-size: 1.15rem; border-bottom: 1px solid var(--border); }
  .site-nav .nav-cta { justify-content: center; }
  .header-cta { display: inline-flex; }
  .menu-toggle { display: block; }
  body.menu-open { overflow: hidden; }
}

/* ---------- botões extra ---------- */
.link-arrow span { display: inline-block; }
.icon-link {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 999px; border: 1px solid var(--border-strong);
  color: var(--forest); flex: none; text-decoration: none;
}
.icon-link:hover { border-color: var(--emerald-dark); color: var(--emerald-dark); }

/* ---------- footer ---------- */
.site-footer { background: var(--forest); color: var(--on-dark); padding-top: clamp(56px, 7vw, 96px); }
.footer-grid { display: grid; grid-template-columns: 1.1fr 2fr; gap: clamp(32px, 5vw, 64px); padding-bottom: 48px; border-bottom: 1px solid rgba(246, 244, 238, 0.14); }
.footer-brand img { height: 56px; width: auto; margin-bottom: 16px; }
.footer-brand p { color: var(--on-dark-muted); max-width: 26ch; }
.footer-ig { display: inline-flex; align-items: center; gap: 8px; color: var(--on-dark); font-weight: 600; text-decoration: none; margin-top: 8px; }
.footer-nav { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.footer-nav h2 { font-family: var(--font-sans); font-size: 0.82rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--sand); margin-bottom: 14px; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-nav a { color: var(--on-dark-muted); text-decoration: none; font-size: 0.94rem; }
.footer-nav a:hover { color: var(--on-dark); }
.footer-bottom { padding-block: 24px 36px; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; color: var(--on-dark-muted); font-size: 0.84rem; }
.footer-bottom a { color: var(--on-dark-muted); }
.footer-bottom a:hover { color: var(--on-dark); }
.footer-links { white-space: nowrap; }
.footer-legal { width: 100%; font-size: 0.78rem; opacity: 0.7; }

@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-nav { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- WhatsApp flutuante ---------- */
.wa-floating {
  position: fixed; right: max(18px, env(safe-area-inset-right)); bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 70; display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 18px; border-radius: 999px; background: var(--emerald-dark); color: var(--white);
  text-decoration: none; font-weight: 700; font-size: 0.92rem; box-shadow: 0 14px 30px -10px rgba(0, 111, 89, 0.55);
  opacity: 0; transform: translateY(14px) scale(0.96); pointer-events: none;
  transition: opacity .3s var(--ease), transform .3s var(--ease);
}
.wa-floating.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.wa-floating:hover { background: var(--emerald-deep); color: var(--white); }
@media (max-width: 560px) { .wa-floating span { display: none; } .wa-floating { padding: 15px; } }

/* ---------- cards genéricos ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(18px, 2.4vw, 28px); }
.card {
  padding: clamp(24px, 2.6vw, 32px); border-radius: var(--radius); background: var(--white);
  border: 1px solid var(--border); box-shadow: var(--shadow-soft); display: flex; flex-direction: column; gap: 10px;
}
.card b { font-size: var(--fs-eyebrow); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--emerald-dark); }
.card h3 { font-size: 1.15rem; }
.card p { color: var(--gray); margin-bottom: 4px; }
.card .link-arrow { margin-top: auto; }

.section-head { max-width: 62ch; margin-bottom: clamp(32px, 4vw, 56px); }
.section-head h2 { margin-top: 6px; }

/* placeholder de mapa */
.map { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border-strong); aspect-ratio: 4 / 3; }
.map iframe { width: 100%; height: 100%; border: 0; }
.map-button {
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; gap: 10px;
  background: rgba(246, 244, 238, 0.08); color: var(--on-dark); border: 0; cursor: pointer; font-weight: 600;
}

@media (max-width: 860px) {
  .cards { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .cards { grid-template-columns: 1fr; }
}
