/* ============================================================
   Components — header, footer, botões, cards, callouts, hero
   ============================================================ */

/* ---- Textura granulada (spec: texturas & fundos) ---- */
.hero::before,
.section--dark::before,
.cta-band::before,
.footer::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, .16) 1px, transparent 1px);
  background-size: 4px 4px; opacity: .55;
}
.section--dark > .container { position: relative; z-index: 1; }

/* ---- Breadcrumbs (spec: navegação) ---- */
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; font-size: 14px; font-weight: 500; margin-bottom: 1.25rem; }
.crumbs a { color: var(--green-600); transition: color var(--t-fast); }
.crumbs a:hover { color: var(--green-hover); text-decoration: underline; text-underline-offset: 3px; }
.crumbs span[aria-current] { color: var(--text-soft); }
.crumbs li { display: inline-flex; align-items: center; gap: .5rem; }
.crumbs li::after { content: "›"; color: var(--cinza-400); }
.crumbs li:last-child::after { content: none; }
/* sobre hero escuro */
.hero .crumbs a { color: var(--mint); }
.hero .crumbs a:hover { color: #fff; }
.hero .crumbs span[aria-current] { color: var(--on-dark-muted); }
.hero .crumbs li::after { color: rgba(255, 255, 255, .4); }

/* ---- Reading progress bar ---- */
.progress {
  position: fixed; inset: 0 0 auto 0;
  height: 4px; z-index: var(--z-progress);
  background: transparent; pointer-events: none;
}
.progress__bar {
  height: 100%; width: 0%;
  background: var(--grad-green);
  transform-origin: left;
}

/* ---- Header ---- */
.header {
  position: fixed; inset: 0 0 auto 0;
  height: var(--header-h);
  z-index: var(--z-header);
  display: flex; align-items: center;
  transition: background var(--t-med), box-shadow var(--t-med), height var(--t-med);
}
.header__inner {
  width: min(100% - 2.5rem, 1320px);
  margin-inline: auto;
  display: flex; align-items: center; justify-content: flex-start;
  gap: 1.5rem;
}
.header__actions { margin-left: auto; }
.header__home {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: var(--r-sm);
  color: currentColor; flex-shrink: 0;
  transition: background var(--t-fast), color var(--t-fast);
}
.header__home .icon { width: 24px; height: 24px; color: currentColor; }
.header__home:hover { color: var(--green-600); background: rgba(64, 165, 90, .1); }
.header--on-dark:not(.is-scrolled) .header__home:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.header.is-scrolled .header__home { color: var(--text-muted); }
.header.is-scrolled {
  background: rgba(255, 255, 255, .85);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  box-shadow: var(--sh-sm);
  height: 64px;
}
/* dark hero -> header transparent with light text until scrolled */
.header__logo img { height: 30px; width: auto; }
.header--on-dark:not(.is-scrolled) { color: #fff; }
.header--on-dark:not(.is-scrolled) .header__logo img { filter: brightness(0) invert(1); }

.nav { display: flex; align-items: center; gap: .3rem; }
.nav__link {
  position: relative;
  padding: .55rem .8rem;
  font-size: .92rem; font-weight: 500;
  color: inherit; border-radius: var(--r-sm);
  transition: color var(--t-fast), background var(--t-fast);
}
.header.is-scrolled .nav__link { color: var(--text-muted); }
.nav__link::after {
  content: ""; position: absolute; left: .8rem; right: .8rem; bottom: .35rem;
  height: 2px; background: var(--green-vivid);
  transform: scaleX(0); transform-origin: left;
  transition: transform var(--t-med) var(--ease);
}
.nav__link:hover { color: var(--green-vivid); }
.nav__link:hover::after,
.nav__link[aria-current="page"]::after { transform: scaleX(1); }
.nav__link[aria-current="page"] { color: var(--green-vivid); font-weight: 700; }

.header__actions { display: flex; align-items: center; gap: .75rem; }

/* ---- Buttons ---- */
.btn {
  --btn-bg: var(--green-vivid);
  --btn-fg: #fff;
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .85rem 1.5rem;
  background: var(--btn-bg); color: var(--btn-fg);
  font-weight: 600; font-size: .95rem;
  border-radius: var(--r-sm);
  line-height: 1; min-height: 44px;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-med), background var(--t-fast);
  will-change: transform;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--sh-green); }
.btn:not(.btn--ghost):not(.btn--light):hover { background: var(--green-hover); }
.btn:active { transform: translateY(0); }
.btn .icon { width: 1.15em; height: 1.15em; color: currentColor; }
.btn--ghost {
  --btn-bg: transparent; --btn-fg: var(--green-600);
  box-shadow: inset 0 0 0 1.5px currentColor;
}
.btn--ghost:hover { background: var(--green-600); color: #fff; box-shadow: var(--sh-green); }
.btn--light { --btn-bg: #fff; --btn-fg: var(--escuro-700); }
.btn--lg { padding: 1.05rem 2rem; font-size: 1.05rem; }
.btn--on-dark.btn--ghost { --btn-fg: #fff; }
.btn--on-dark.btn--ghost:hover { background: #fff; color: var(--teal-deep); }
.header__cta { padding: .6rem 1.2rem; font-size: .9rem; }

/* mobile menu toggle */
.menu-toggle {
  display: none; width: 44px; height: 44px;
  border-radius: var(--r-sm);
  align-items: center; justify-content: center;
}
.menu-toggle span {
  position: relative; width: 22px; height: 2px;
  background: currentColor; border-radius: 2px;
  transition: background var(--t-fast);
}
.menu-toggle span::before, .menu-toggle span::after {
  content: ""; position: absolute; left: 0; width: 22px; height: 2px;
  background: currentColor; border-radius: 2px;
  transition: transform var(--t-med) var(--ease);
}
.menu-toggle span::before { top: -7px; }
.menu-toggle span::after { top: 7px; }
body.menu-open .menu-toggle span { background: transparent; }
body.menu-open .menu-toggle span::before { transform: translateY(7px) rotate(45deg); }
body.menu-open .menu-toggle span::after { transform: translateY(-7px) rotate(-45deg); }

/* ---- Mobile drawer ---- */
.drawer {
  position: fixed; inset: 0;
  z-index: var(--z-menu);
  background: var(--grad-dark-radial);
  color: #fff;
  display: flex; flex-direction: column;
  justify-content: center;
  padding: var(--sp-6) 2rem;
  clip-path: circle(0% at calc(100% - 44px) 44px);
  transition: clip-path .6s var(--ease);
  visibility: hidden;
}
body.menu-open .drawer { clip-path: circle(150% at calc(100% - 44px) 44px); visibility: visible; }
.drawer__list { display: flex; flex-direction: column; gap: .25rem; }
.drawer__link {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 7vw, 2.4rem); font-weight: 700;
  padding: .35rem 0; display: flex; align-items: baseline; gap: 1rem;
  color: #fff; opacity: .92;
}
.drawer__link span { font-size: .8rem; color: var(--mint); font-family: var(--font-sans); }
.drawer__link:hover { color: var(--mint); }
.drawer__cta { margin-top: var(--sp-5); }

/* ---- Hero ---- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding-top: var(--header-h);
  background: var(--grad-dark-radial);
  color: var(--on-dark);
  overflow: hidden;
}
.hero__bg {
  position: absolute; inset: 0; z-index: 0;
  opacity: .5; mix-blend-mode: screen;
}
.hero__pattern {
  position: absolute; inset: -10% -10% auto auto; width: 60%; height: 120%;
  background: url("../img/brand/chevron-pattern.svg") repeat;
  opacity: .06; z-index: 0;
}
.hero__glow {
  position: absolute; border-radius: 50%; filter: blur(80px); z-index: 0;
}
.hero__glow--1 { width: 480px; height: 480px; background: rgba(97,183,100,.4); top: -120px; right: -80px; }
.hero__glow--2 { width: 420px; height: 420px; background: rgba(106,63,181,.35); bottom: -140px; left: -100px; }
.hero__inner { position: relative; z-index: 2; }
.hero__content { max-width: 880px; }
.hero h1 { color: #fff; margin-block: 1rem 1.25rem; }
.hero .lead { max-width: 640px; color: var(--on-dark-muted); }
.hero .eyebrow { color: var(--mint); }
.hero .script { color: var(--green-400); }
.hero strong { color: #fff; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: var(--sp-5); }

/* home hero: split (texto + imagem placeholder) */
.hero--home { min-height: 100svh; }
.hero__inner--split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero__logo { height: 38px; width: auto; filter: brightness(0) invert(1); margin-bottom: 1.6rem; }
.hero__media { position: relative; }
.hero__placeholder {
  aspect-ratio: 4 / 3; border-radius: var(--r-lg);
  border: 1.5px dashed rgba(255, 255, 255, .28);
  background: rgba(255, 255, 255, .05);
  display: grid; place-content: center; justify-items: center; gap: .6rem;
  color: var(--on-dark-muted); text-align: center;
}
.hero__placeholder .icon { width: 44px; height: 44px; color: var(--mint); }
.hero__placeholder span { font-size: .9rem; letter-spacing: .02em; }
@media (max-width: 880px) {
  .hero__inner--split { grid-template-columns: 1fr; }
  .hero__media { max-width: 440px; }
}

.scroll-cue {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%);
  z-index: 3; display: flex; flex-direction: column; align-items: center; gap: .5rem;
  font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--on-dark-muted);
}
.scroll-cue__line { width: 1px; height: 46px; background: linear-gradient(var(--mint), transparent); position: relative; overflow: hidden; }
.scroll-cue__line::after { content: ""; position: absolute; inset: 0; background: var(--mint); animation: cue 1.8s var(--ease) infinite; }
@keyframes cue { 0% { transform: translateY(-100%); } 60%,100% { transform: translateY(100%); } }

/* ---- Module hero variant ---- */
.hero--module { min-height: 72svh; }
.hero--module .hero__content { max-width: 760px; }
.hero__icon {
  width: 72px; height: 72px; border-radius: var(--r-md);
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.16);
  display: grid; place-items: center; margin-bottom: 1.4rem;
}
.hero__icon .icon { width: 40px; height: 40px; color: var(--mint); }
.hero__num {
  position: absolute; right: clamp(1rem, 5vw, 5rem); top: 50%; transform: translateY(-50%);
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(8rem, 22vw, 20rem); line-height: 1;
  color: rgba(255,255,255,.05); z-index: 1; pointer-events: none; user-select: none;
}

/* ---- Section heading block ---- */
.head { max-width: 760px; margin-bottom: var(--sp-5); }
.head--center { margin-inline: auto; text-align: center; }
.head--center .eyebrow { justify-content: center; }
.head h2 { margin-block: .8rem .9rem; }

/* ---- Cards ---- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: var(--sp-5) var(--sp-4);
  box-shadow: var(--sh-sm);
  transition: transform var(--t-med) var(--ease), box-shadow var(--t-med), border-color var(--t-med);
  height: 100%;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--sh-md); border-color: var(--line-strong); }
.card__icon {
  width: 56px; height: 56px; border-radius: var(--r-md);
  display: grid; place-items: center; margin-bottom: 1.1rem;
  background: var(--grad-mint); color: var(--green-vivid);
}
.card__icon .icon { width: 30px; height: 30px; }
.card h3 { font-size: var(--fs-h4); margin-bottom: .5rem; }
.card p { color: var(--text-muted); font-size: 1rem; }

/* ---- Callouts (asides) ---- */
.callout {
  position: relative;
  display: grid; grid-template-columns: auto 1fr; gap: 1.1rem;
  align-items: start;
  padding: 1.4rem 1.6rem;
  border-radius: var(--r-md);
  background: #fff;
  border: 1px solid var(--line);
  border-left: 4px solid var(--green);
  box-shadow: var(--sh-sm);
  margin-block: var(--sp-4);
}
.callout__emoji { font-size: 1.5rem; line-height: 1.3; }
.callout p { margin: 0; color: var(--text); font-weight: 500; }
.callout--tip { border-left-color: var(--green-vivid); background: linear-gradient(120deg, #f0f9f2, #fff); }
.callout--warn { border-left-color: #e0a93b; background: linear-gradient(120deg, #fdf6e9, #fff); }

/* ---- Pull quote / destaque ---- */
.pullquote {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.5rem, 1rem + 2.5vw, 2.6rem);
  line-height: 1.25; letter-spacing: var(--ls-tight);
  color: var(--teal-deep);
  max-width: 16ch; margin-inline: auto; text-align: center;
  padding-block: var(--sp-2);
}
.pullquote--left { text-align: left; margin-inline: 0; max-width: 24ch; }
.section--dark .pullquote { color: #fff; }

/* ---- Feature list (com ícones) ---- */
.flist { display: grid; gap: .9rem; }
.flist li { display: flex; gap: .85rem; align-items: flex-start; }
.flist .icon { width: 24px; height: 24px; margin-top: .15rem; color: var(--green-vivid); }
.flist b { display: block; }
.flist span { color: var(--text-muted); font-size: .98rem; }
.section--dark .flist span { color: var(--on-dark-muted); }
.section--dark .flist .icon { color: var(--mint); }

/* ---- Split (texto + mídia) ---- */
.split {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem); align-items: center;
}
.split--reverse .split__media { order: -1; }
.split__media img, .split__media video { border-radius: var(--r-lg); box-shadow: var(--sh-lg); width: 100%; }
.split__media { position: relative; }

/* ---- Stat / counter ---- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: var(--sp-4); }
.stat__num {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(2.4rem, 1.6rem + 3vw, 4rem);
  line-height: 1; color: var(--green-vivid); letter-spacing: -.02em;
}
.stat__label { color: var(--text-muted); margin-top: .4rem; font-size: .95rem; }
.section--dark .stat__num { color: var(--mint); }
.section--dark .stat__label { color: var(--on-dark-muted); }

/* ---- Footer ---- */
.footer {
  background: var(--institucional); color: var(--on-dark);
  padding: var(--sp-6) 0 var(--sp-4);
  position: relative; overflow: hidden;
}
/* footer enxuto: logo | links | botão */
.footer__inner--simple { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1.25rem 2rem; }
.footer__logo img { height: 30px; width: auto; filter: brightness(0) invert(1); }
.footer__nav { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; }
.footer__nav a { color: var(--on-dark-muted); font-weight: 500; transition: color var(--t-fast); }
.footer__nav a:hover { color: var(--teal-400); }
.footer__copyright { margin-top: var(--sp-4); padding-top: var(--sp-4); border-top: 1px solid rgba(255, 255, 255, .12); color: var(--on-dark-muted); font-size: 13px; font-family: var(--font-mono); letter-spacing: .02em; }
@media (max-width: 760px) {
  .footer__inner--simple { flex-direction: column; align-items: flex-start; gap: 1.25rem; }
}
.footer__pattern { position: absolute; inset: 0; background: url("../img/brand/chevron-pattern.svg"); opacity: .04; }
.footer__inner { position: relative; z-index: 1; }
.footer__top { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: var(--sp-5); align-items: start; }
.footer__brand img { height: 34px; filter: brightness(0) invert(1); margin-bottom: 1rem; }
.footer__brand p { color: var(--on-dark-muted); max-width: 34ch; }
.footer__col h4 { color: #fff; font-size: 1rem; margin-bottom: 1rem; }
.footer__col li { margin-bottom: .55rem; }
.footer__col a { color: var(--on-dark-muted); transition: color var(--t-fast); }
.footer__col a:hover { color: var(--mint); }
.footer__cta { margin-top: 1.2rem; }
.footer__bottom {
  margin-top: var(--sp-6); padding-top: var(--sp-4);
  border-top: 1px solid rgba(255,255,255,.12);
  display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between;
  color: var(--on-dark-muted); font-size: .85rem;
}

/* ---- Inter-module nav (prev/next) ---- */
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.pager__item {
  display: flex; flex-direction: column; gap: .35rem;
  padding: 1.5rem 1.75rem; border-radius: var(--r-lg);
  background: #fff; border: 1px solid var(--line);
  transition: transform var(--t-med) var(--ease), box-shadow var(--t-med);
}
.pager__item:hover { transform: translateY(-4px); box-shadow: var(--sh-md); }
.pager__item--next { text-align: right; align-items: flex-end; }
.pager__dir { font-family: var(--font-mono); font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--text-soft); }
.pager__title { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; color: var(--escuro-700); }
.pager-section { border-top: 1px solid var(--line); }

/* ---- Page transition curtain ---- */
.curtain {
  position: fixed; inset: 0; z-index: var(--z-curtain);
  background: var(--grad-dark);
  transform: scaleY(0); transform-origin: bottom;
  pointer-events: none;
  display: grid; place-items: center;
}
.curtain.is-active { transform: scaleY(1); }
.curtain img { height: 40px; filter: brightness(0) invert(1); opacity: 0; }

/* ---- Floating CTA (WhatsApp/contato) ---- */
.float-cta {
  position: fixed; right: clamp(16px, 3vw, 28px); bottom: clamp(16px, 3vw, 28px);
  z-index: 40; box-shadow: var(--sh-green);
}
