/* ==========================================================================
   LAYOUT.CSS — Container, grelha, ritmo de secções, eyebrow, títulos
   Carregar depois de base.css.
   ========================================================================== */

/* ---- Container --------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: var(--container-narrow); }

/* ---- Secções ----------------------------------------------------------- */
.section { padding-block: var(--section-y); }
.section--tight { padding-block: calc(var(--section-y) * 0.62); }
.section--surface { background: var(--surface-2); }

/* Secção escura (navy) */
.section--dark {
  background: linear-gradient(180deg, var(--navy-800), var(--navy-900));
  color: rgba(255, 255, 255, 0.78);
}
.section--dark h2,
.section--dark h3 { color: #fff; }

/* ---- Eyebrow (rótulo de secção) --------------------------------------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--brand-600);
}
.eyebrow::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--brand-500);
  box-shadow: 0 0 0 4px var(--brand-100);
}
.section--dark .eyebrow { color: var(--brand-200); }
.section--dark .eyebrow::before { background: var(--brand-300); box-shadow: 0 0 0 4px rgba(151,175,195,0.18); }

/* ---- Títulos-declaração (palavras destacadas vs. atenuadas) ----------- */
.statement {
  color: var(--head-muted);
  font-weight: 800;
  letter-spacing: var(--tracking-tight);
  line-height: 1.08;
}
.statement .hl { color: var(--head-strong); }
.statement .hl-accent { color: var(--brand-500); }
.section--dark .statement { color: rgba(255,255,255,0.42); }
.section--dark .statement .hl { color: #fff; }
.section--dark .statement .hl-accent { color: var(--brand-200); }

/* ---- Cabeçalho de secção (centrado) ----------------------------------- */
.section-head {
  max-width: 52rem;
  margin-inline: auto;
  text-align: center;
  margin-bottom: var(--space-2xl);
}
.section-head .eyebrow { margin-bottom: var(--space-md); }
.section-head h2 { margin-top: var(--space-xs); }
.section-lead {
  margin-top: var(--space-md);
  font-size: var(--step-1);
  line-height: var(--leading-snug);
  color: var(--ink-500);
}
.section--dark .section-lead { color: rgba(255,255,255,0.66); }

/* ---- Cabeçalho dividido (título à esquerda + apoio à direita) --------- */
.split-head {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: end;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}
.split-head .eyebrow { margin-bottom: var(--space-md); }
.split-head__aside {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  padding-bottom: 0.4rem;
}
.split-head__aside p { color: var(--ink-500); font-size: var(--step-0); }
.section--dark .split-head__aside p { color: rgba(255,255,255,0.66); }
@media (max-width: 820px) {
  .split-head { grid-template-columns: 1fr; align-items: start; gap: var(--space-lg); }
}

/* ---- Grelhas ----------------------------------------------------------- */
.grid { display: grid; gap: var(--space-lg); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-auto { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }

@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ---- Utilitários ------------------------------------------------------- */
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.text-center { text-align: center; }
.no-wrap { white-space: nowrap; }
.stack > * + * { margin-top: var(--space-md); }
.stack-lg > * + * { margin-top: var(--space-lg); }
.flow-cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  align-items: center;
}
