/* ==========================================================================
   Associação de Pais do Picoto — folha de estilos principal
   Paleta derivada do logótipo (6 mãos pintadas). Contraste verificado.
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  /* cores do logótipo */
  --rose: #e8365d;
  --orange: #f28c12;
  --yellow: #f0b400;
  --magenta: #cf34bd;
  --blue: #2e45e8;
  --green: #1fae46;

  /*_usage das cores de acento_ */
  --rose-soft: #fdeaef;
  --orange-soft: #fef1e0;
  --yellow-soft: #fff8e0;
  --magenta-soft: #fbe8f8;
  --blue-soft: #eaedfd;
  --green-soft: #e6f7ec;

  /* neutros */
  --ink: #191c3b;
  --ink-2: #4b5270;
  --ink-3: #79809b;
  --paper: #ffffff;
  --cream: #fffaf6;
  --mist: #f5f7fd;
  --line: #e7e9f3;

  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 28px;
  --radius-xl: 40px;

  --shadow-xs: 0 1px 2px rgba(25, 28, 59, .06);
  --shadow-sm: 0 2px 6px rgba(25, 28, 59, .05), 0 8px 20px rgba(25, 28, 59, .05);
  --shadow: 0 12px 34px rgba(25, 28, 59, .09);
  --shadow-lg: 0 28px 70px rgba(25, 28, 59, .14);

  --maxw: 1240px;
  --gutter: 20px;

  --font-head: "Fredoka", "Trebuchet MS", system-ui, sans-serif;
  --font-body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;

  --ease: cubic-bezier(.22, .8, .3, 1);
}

/* ---------- 2. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  /* hidden é o fallback para o Safari 15; clip (suportado desde o Safari 16)
     evita a barra horizontal do menu lateral fora do ecrã sem criar um bloco
     contentor que partiria o position:sticky do cabeçalho */
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--paper);
  overflow-x: hidden;
  overflow-x: clip;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 .5em;
  font-weight: 600;
  letter-spacing: -.01em;
}

h1 { font-size: clamp(2.4rem, 5.6vw, 4rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

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

button, input, select, textarea { font: inherit; color: inherit; }

::selection { background: var(--yellow); color: var(--ink); }

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- 3. Utilitários ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding: clamp(56px, 8vw, 100px) 0; }
.section--tint { background: var(--mist); }
.section--cream { background: var(--cream); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 26px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--rose), var(--orange), var(--yellow));
}

.section-head {
  max-width: 680px;
  margin-bottom: clamp(32px, 4vw, 56px);
}
.section-head--center { margin-inline: auto; text-align: center; }
.section-head p { font-size: 1.08rem; color: var(--ink-2); }

.lead { font-size: 1.12rem; color: var(--ink-2); }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- 4. Botões ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 999px;
  border: 2px solid transparent;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: .97rem;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), background .22s var(--ease), color .22s var(--ease);
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background: var(--ink);
  color: #fff;
  box-shadow: 0 10px 24px rgba(25, 28, 59, .22);
}
.btn--primary:hover { background: #262a52; box-shadow: 0 14px 30px rgba(25, 28, 59, .28); }

.btn--sun {
  background: linear-gradient(120deg, var(--orange), var(--yellow));
  color: #3a2a00;
  box-shadow: 0 10px 26px rgba(242, 140, 18, .35);
}
.btn--sun:hover { box-shadow: 0 14px 32px rgba(242, 140, 18, .45); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn--ghost:hover { border-color: var(--ink); background: #fff; }

.btn--light {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 8px 22px rgba(0, 0, 0, .14);
}

.btn--sm { padding: 10px 18px; font-size: .88rem; }
.btn--block { width: 100%; }

/* ---------- 5. Cabeçalho ---------- */
.topbar {
  background: var(--ink);
  color: #cfd3e8;
  font-size: .84rem;
}
.topbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 42px;
  flex-wrap: wrap;
}
.topbar a { color: #fff; font-weight: 700; }
.topbar__links { display: flex; gap: 22px; align-items: center; }
.topbar__links a:hover { color: var(--yellow); }

.header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.header.is-stuck {
  border-bottom-color: var(--line);
  box-shadow: 0 6px 24px rgba(25, 28, 59, .06);
}
.header .container {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 78px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}
.brand:hover { text-decoration: none; }
.brand__logo {
  width: 46px;
  height: 46px;
  object-fit: contain;
  flex-shrink: 0;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--ink);
}
.brand__sub { font-size: .74rem; color: var(--ink-3); font-weight: 700; letter-spacing: .02em; }

.nav { margin-left: auto; }
.nav__mobile-only { display: none; }
.nav__list {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__list a {
  display: block;
  padding: 9px 11px;
  border-radius: 999px;
  color: var(--ink-2);
  font-weight: 700;
  font-size: .92rem;
  white-space: nowrap;
}
.nav__list a:hover {
  text-decoration: none;
  background: var(--mist);
  color: var(--ink);
}
.header__actions { display: flex; align-items: center; gap: 10px; }

.nav-toggle {
  display: none;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  padding: 0;
  place-items: center;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  position: relative;
  transition: background .2s var(--ease);
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .25s var(--ease);
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- 6. Hero ---------- */
.hero {
  position: relative;
  padding: clamp(48px, 7vw, 92px) 0 clamp(56px, 8vw, 110px);
  overflow: hidden;
  background:
    radial-gradient(900px 520px at 88% -8%, rgba(240, 180, 0, .18), transparent 60%),
    radial-gradient(760px 480px at 6% 8%, rgba(232, 54, 93, .13), transparent 62%),
    radial-gradient(700px 500px at 55% 108%, rgba(46, 69, 232, .10), transparent 60%),
    linear-gradient(180deg, #fffdfb, #fff7f0);
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero__title { margin-bottom: .35em; }
.hero__title .accent {
  position: relative;
  background: linear-gradient(90deg, var(--rose), var(--orange), var(--yellow));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero__text { font-size: 1.12rem; max-width: 34em; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }

.hero__badges {
  display: flex;
  gap: 26px;
  margin-top: 40px;
  padding-top: 28px;
  border-top: 1px solid rgba(25, 28, 59, .1);
  flex-wrap: wrap;
}
.hero__badge strong {
  display: block;
  font-family: var(--font-head);
  font-size: 1.7rem;
  color: var(--ink);
  line-height: 1.1;
}
.hero__badge span { font-size: .86rem; color: var(--ink-3); font-weight: 700; }

/* cartão do logótipo */
.hero__art { position: relative; display: grid; place-items: center; }
.hero__card-wrap { position: relative; width: fit-content; }
.logo-card {
  position: relative;
  background: #fff;
  border-radius: var(--radius-xl);
  padding: clamp(26px, 4vw, 44px);
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(25, 28, 59, .06);
  transform: rotate(-2deg);
  max-width: 420px;
}
.logo-card img { width: 100%; height: auto; }
.logo-card__ribbon {
  position: absolute;
  bottom: -18px;
  left: 50%;
  transform: translateX(-50%) rotate(2deg);
  background: var(--ink);
  color: #fff;
  font-family: var(--font-head);
  font-size: .95rem;
  padding: 10px 22px;
  border-radius: 999px;
  box-shadow: var(--shadow);
  white-space: nowrap;
}

.floating-chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 9px;
  background: #fff;
  border-radius: 999px;
  padding: 10px 18px 10px 12px;
  box-shadow: var(--shadow);
  font-size: .84rem;
  font-weight: 800;
  color: var(--ink);
  z-index: 3;
}
.floating-chip i {
  width: 26px; height: 26px;
  border-radius: 50%;
  display: grid; place-items: center;
  color: #fff;
  font-style: normal;
  font-size: .78rem;
}
.floating-chip--1 { top: 4%; right: -7%; }
.floating-chip--1 i { background: var(--rose); }
.floating-chip--2 { bottom: 14%; left: -9%; }
.floating-chip--2 i { background: var(--green); }

.hero__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(48px);
  opacity: .38;
  z-index: 1;
}
.hero__blob--a { width: 260px; height: 260px; background: var(--yellow); top: -60px; right: 8%; }
.hero__blob--b { width: 220px; height: 220px; background: var(--magenta); bottom: -70px; left: 2%; }

/* mãos decorativas */
.decor-hand--a { width: 190px; right: 2%; top: 26%; transform: rotate(18deg); color: var(--magenta); }
.decor-hand--b { width: 150px; left: -40px; bottom: 8%; transform: rotate(-24deg); color: var(--blue); }

/* utilitários que substituem estilos inline (permite CSP estrito) */
.painel-topo { background: #fff; }
.app-hidden { display: none; }
.secao-sem-topo { padding-top: 0; }
.acoes-a-direita { margin-left: auto; }
.linha-opcao { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.opcao-label { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 600; color: var(--ink-2); }
.caixa-verificacao { width: 18px; height: 18px; accent-color: var(--blue); }
.link-escuro { font-size: .88rem; font-weight: 800; }
.nota-fundo { margin-top: 22px; font-size: .9rem; color: var(--ink-3); }
.sprite-oculto { position: absolute; }
.marca-bloco { margin-bottom: 22px; }
.entrada-suave { color: var(--ink-3); font-weight: 700; margin-bottom: 22px; }
.ligacao-forte { font-weight: 800; }
.rodape-desc { max-width: 34ch; }

/* Atrasos da animação de entrada — em classes, não em style inline,
   para que a CSP possa ser estrita (sem 'unsafe-inline'). */
.reveal-d1 { transition-delay: 60ms; }
.reveal-d2 { transition-delay: 120ms; }
.reveal-d3 { transition-delay: 180ms; }
.reveal-d4 { transition-delay: 240ms; }
.reveal-d5 { transition-delay: 300ms; }
.reveal-d6 { transition-delay: 360ms; }

/* Corpo sem scroll (gaveta de menu aberta) */
.sem-scroll { overflow: hidden; }

/* Mensagem de erro do formulário */
.form__ok--erro { background: var(--rose-soft); color: #96213b; }

/* Visibilidade do painel de famílias */
.app-visivel { display: block; }

.decor-hand {
  position: absolute;
  opacity: .09;
  color: var(--ink);
  pointer-events: none;
  z-index: 1;
}

/* ---------- 7. Faixa de estatísticas ---------- */
.stats {
  background: var(--ink);
  color: #fff;
  padding: clamp(34px, 4vw, 54px) 0;
  position: relative;
  overflow: hidden;
}
.stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  position: relative;
  z-index: 2;
}
.stat__value {
  font-family: var(--font-head);
  font-size: clamp(2rem, 4vw, 2.9rem);
  line-height: 1;
  background: linear-gradient(120deg, var(--yellow), var(--orange), var(--rose));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat__label { color: #c8cde4; font-size: .92rem; font-weight: 700; margin-top: 6px; }
.stat { position: relative; padding-left: 18px; }
.stat::before {
  content: "";
  position: absolute;
  left: 0; top: 6px; bottom: 6px;
  width: 4px;
  border-radius: 2px;
  background: var(--rose);
}
.stat:nth-child(2)::before { background: var(--orange); }
.stat:nth-child(3)::before { background: var(--yellow); }
.stat:nth-child(4)::before { background: var(--green); }

/* ---------- 8. Cartões ---------- */
.grid {
  display: grid;
  gap: 24px;
}
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 30px 28px;
  box-shadow: var(--shadow-xs);
  transition: transform .28s var(--ease), box-shadow .28s var(--ease), border-color .28s var(--ease);
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
  border-color: transparent;
}
.card h3 { margin-bottom: .35em; }
.card p:last-child { margin-bottom: 0; }

.card__icon {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  margin-bottom: 20px;
  color: #fff;
}
.card__icon svg { width: 28px; height: 28px; }

.card__icon--rose { background: linear-gradient(135deg, var(--rose), #f4607f); }
.card__icon--orange { background: linear-gradient(135deg, var(--orange), #f7b040); }
.card__icon--yellow { background: linear-gradient(135deg, var(--yellow), #ffd23f); color: #4a3700; }
.card__icon--magenta { background: linear-gradient(135deg, var(--magenta), #e26fd6); }
.card__icon--blue { background: linear-gradient(135deg, var(--blue), #6478f0); }
.card__icon--green { background: linear-gradient(135deg, var(--green), #52cf6d); }

/* ---------- 9. Sobre + valores ---------- */
.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.about__list {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 12px;
}
.about__list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-weight: 600;
  color: var(--ink);
}
.about__list svg { width: 22px; height: 22px; flex-shrink: 0; color: var(--green); margin-top: 3px; }

.quote-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 34px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
  position: relative;
}
.quote-card::before {
  content: "\201C";
  position: absolute;
  top: -6px; left: 22px;
  font-family: var(--font-head);
  font-size: 6rem;
  color: var(--yellow);
  opacity: .35;
  line-height: 1;
}
.quote-card p { position: relative; font-size: 1.06rem; color: var(--ink); }
.quote-card footer { margin-top: 18px; font-weight: 800; color: var(--ink); }
.quote-card footer span { display: block; font-weight: 600; color: var(--ink-3); font-size: .9rem; }

/* ---------- 10. Passos ---------- */
.steps { counter-reset: step; }
.step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 34px 30px;
  box-shadow: var(--shadow-xs);
}
.step__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--yellow), #ffd23f);
  color: #4a3700;
  font-family: var(--font-head);
  font-size: 1.4rem;
  font-weight: 600;
  line-height: 1;
  margin-bottom: 16px;
}
.step h3 { font-size: 1.3rem; }
.step p { margin-bottom: 0; color: var(--ink-2); }

/* ---------- 11. Agenda ---------- */
.events { display: grid; gap: 18px; }
.event {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 26px;
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 22px 28px;
  box-shadow: var(--shadow-xs);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.event:hover { transform: translateX(4px); box-shadow: var(--shadow); }
.event__date {
  text-align: center;
  background: var(--mist);
  border-radius: var(--radius);
  padding: 12px 6px;
  border-top: 4px solid var(--blue);
}
.event__date--rose { border-top-color: var(--rose); background: var(--rose-soft); }
.event__date--orange { border-top-color: var(--orange); background: var(--orange-soft); }
.event__date--green { border-top-color: var(--green); background: var(--green-soft); }
.event__date--yellow { border-top-color: var(--yellow); background: var(--yellow-soft); }
.event__date--magenta { border-top-color: var(--magenta); background: var(--magenta-soft); }
.event__month {
  display: block;
  font-size: .72rem;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.event__day {
  display: block;
  font-family: var(--font-head);
  font-size: 1.9rem;
  line-height: 1.1;
  color: var(--ink);
}
.event__body h3 { margin-bottom: .25em; font-size: 1.2rem; }
.event__body p { margin: 0 0 6px; color: var(--ink-2); font-size: .96rem; }
.event__meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: .85rem;
  font-weight: 700;
  color: var(--ink-3);
}
.event__meta span { display: inline-flex; align-items: center; gap: 6px; }
.event__meta svg { width: 15px; height: 15px; }
.tag {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: .74rem;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
  background: var(--blue-soft);
  color: var(--blue);
  white-space: nowrap;
}
.tag--rose { background: var(--rose-soft); color: var(--rose); }
.tag--orange { background: var(--orange-soft); color: #a75a00; }
.tag--yellow { background: var(--yellow-soft); color: #8a6400; }
.tag--magenta { background: var(--magenta-soft); color: #8d227c; }
.tag--blue { background: var(--blue-soft); color: var(--blue); }
.tag--green { background: var(--green-soft); color: #14612b; }

/* ---------- 12. Equipa ---------- */
.team { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.member {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-xs);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.member:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.member__avatar {
  width: 58px; height: 58px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-head);
  font-size: 1.25rem;
  color: #fff;
  flex-shrink: 0;
}
.member__avatar--rose { background: linear-gradient(135deg, var(--rose), #f4607f); }
.member__avatar--orange { background: linear-gradient(135deg, var(--orange), #f7b040); }
.member__avatar--yellow { background: linear-gradient(135deg, var(--yellow), #ffd23f); color: #4a3700; }
.member__avatar--magenta { background: linear-gradient(135deg, var(--magenta), #e26fd6); }
.member__avatar--blue { background: linear-gradient(135deg, var(--blue), #6478f0); }
.member__avatar--green { background: linear-gradient(135deg, var(--green), #52cf6d); }
.member__name { font-family: var(--font-head); font-weight: 600; color: var(--ink); font-size: 1.05rem; }
.member__role { font-size: .86rem; color: var(--ink-3); font-weight: 700; }

/* ---------- 13. CTA final ---------- */
.cta-band {
  background: var(--ink);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: clamp(38px, 5vw, 66px);
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.cta-band h2 { color: #fff; }
.cta-band p { color: #c8cde4; max-width: 56ch; margin-inline: auto; }
.cta-band .btn { margin-top: 12px; }
.cta-band::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto;
  height: 340px;
  background: radial-gradient(closest-side, rgba(240, 180, 0, .22), transparent);
}
.cta-band__inner { position: relative; z-index: 2; }

/* ---------- 14. Contactos ---------- */
.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(32px, 5vw, 60px);
}
.contact-list { display: grid; gap: 16px; margin-top: 24px; }
.contact-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
}
.contact-item svg { width: 22px; height: 22px; color: var(--blue); flex-shrink: 0; margin-top: 2px; }
.contact-item strong { display: block; color: var(--ink); font-family: var(--font-head); font-weight: 600; }
.contact-item span { font-size: .95rem; }

.social { display: flex; gap: 10px; margin-top: 22px; }
.social a {
  width: 44px; height: 44px;
  border-radius: 14px;
  background: var(--mist);
  display: grid; place-items: center;
  color: var(--ink);
  transition: background .2s var(--ease), color .2s var(--ease), transform .2s var(--ease);
}
.social a:hover { background: var(--ink); color: #fff; transform: translateY(-3px); text-decoration: none; }
.social svg { width: 20px; height: 20px; }

.form {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3vw, 34px);
  box-shadow: var(--shadow);
}
.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: .84rem;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 6px;
}
.field input, .field textarea, .field select {
  width: 100%;
  padding: 13px 15px;
  border: 2px solid var(--line);
  border-radius: 14px;
  background: #fff;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(46, 69, 232, .12);
}
.field textarea { min-height: 120px; resize: vertical; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.form__ok {
  display: none;
  align-items: center;
  gap: 10px;
  background: var(--green-soft);
  color: #14612b;
  border-radius: 14px;
  padding: 14px 18px;
  font-weight: 700;
  margin-top: 14px;
}
.form__ok.is-visible { display: flex; }

/* ---------- 15. Rodapé ---------- */
.footer {
  background: var(--ink);
  color: #a9afc9;
  padding: clamp(44px, 6vw, 72px) 0 28px;
  margin-top: 0;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.footer h4 {
  color: #fff;
  font-size: .84rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.footer a { color: #a9afc9; }
.footer a:hover { color: #fff; }
.footer__logo { width: 74px; margin-bottom: 16px; background: #fff; border-radius: 16px; padding: 8px; }
.footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 22px;
  font-size: .85rem;
}

/* ---------- 16. Página de login / área de famílias ---------- */
.auth {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.auth__aside {
  background:
    radial-gradient(600px 400px at 20% 15%, rgba(240, 180, 0, .3), transparent 60%),
    radial-gradient(500px 400px at 80% 85%, rgba(232, 54, 93, .3), transparent 60%),
    var(--ink);
  color: #fff;
  padding: clamp(36px, 5vw, 70px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.auth__aside h2 { color: #fff; }
.auth__aside p { color: #c8cde4; max-width: 40ch; }
.auth__logo { width: 96px; background: #fff; border-radius: 22px; padding: 12px; margin-bottom: 26px; }
.auth__list { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 12px; }
.auth__list li { display: flex; gap: 10px; align-items: center; font-weight: 600; }
.auth__list svg { width: 20px; height: 20px; color: var(--yellow); flex-shrink: 0; }

.auth__main {
  display: grid;
  place-items: center;
  padding: clamp(32px, 5vw, 60px) var(--gutter);
  background: var(--cream);
}
.auth__card {
  width: 100%;
  max-width: 430px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(26px, 4vw, 38px);
  box-shadow: var(--shadow);
}
.auth__card h1 { font-size: 1.75rem; margin-bottom: .3em; }
.auth__hint {
  background: var(--blue-soft);
  color: #1c2a8f;
  border-radius: 14px;
  padding: 12px 16px;
  font-size: .88rem;
  margin: 18px 0 0;
}
.auth__hint code { font-weight: 800; }
.auth__error {
  display: none;
  background: var(--rose-soft);
  color: #96213b;
  border-radius: 14px;
  padding: 12px 16px;
  font-size: .9rem;
  font-weight: 700;
  margin-bottom: 16px;
}
.auth__error.is-visible { display: block; }

/* painel */
.panel { display: none; padding: clamp(32px, 5vw, 64px) 0 80px; background: var(--mist); }
.panel.is-visible { display: block; }
.panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 34px;
}
.panel__hello { font-family: var(--font-head); font-size: 1.9rem; color: var(--ink); margin: 0; }
.panel__hello span { color: var(--ink-3); font-size: 1rem; font-family: var(--font-body); font-weight: 700; }
.panel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.panel-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-xs);
}
.panel-card--wide { grid-column: 1 / -1; }
.panel-card h3 {
  font-size: 1.05rem;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 9px;
}
.panel-card h3 svg { width: 18px; height: 18px; color: var(--blue); }

.avisos { display: grid; gap: 14px; }
.aviso { border-left: 4px solid var(--yellow); padding-left: 14px; }
.aviso__title { font-family: var(--font-head); color: var(--ink); font-weight: 600; }
.aviso__date { font-size: .8rem; color: var(--ink-3); font-weight: 700; }
.aviso p { font-size: .93rem; margin: 4px 0 0; }

.doc-list { display: grid; gap: 8px; }
.doc {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--mist);
  transition: background .2s var(--ease);
}
.doc:hover { background: var(--blue-soft); }
.doc__icon {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--rose);
  color: #fff;
  display: grid; place-items: center;
  font-size: .62rem;
  font-weight: 900;
  flex-shrink: 0;
}
.doc__name { font-weight: 700; color: var(--ink); font-size: .95rem; }
.doc__meta { font-size: .8rem; color: var(--ink-3); font-weight: 700; }
.doc__dl { margin-left: auto; color: var(--ink-3); }
.doc__dl svg { width: 18px; height: 18px; }

.kv { display: grid; gap: 12px; }
.kv__row { display: flex; justify-content: space-between; gap: 16px; font-size: .95rem; }
.kv__row dt { color: var(--ink-3); font-weight: 700; }
.kv__row dd { margin: 0; color: var(--ink); font-weight: 700; text-align: right; }
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--green-soft);
  color: #14612b;
  font-size: .8rem;
  font-weight: 900;
}
.badge--warn { background: var(--orange-soft); color: #8a4b00; }

.chip-list { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  background: var(--magenta-soft);
  color: #8d227c;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: .87rem;
  font-weight: 700;
}

/* ---------- 17. Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }

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

/* ---------- 18. Responsivo ---------- */
/* O cabeçalho completo (marca + 6 links + 2 botões) precisa de ~1160px.
   Abaixo disso o menu passa a gaveta lateral com o botão de hamburger. */
@media (max-width: 1240px) {
  /* o backdrop-filter cria um bloco contentor que parte o position:fixed do menu */
  .header {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(255, 255, 255, .96);
  }
  .header__actions { margin-left: auto; }
  .nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    height: 100vh;
    height: 100dvh;
    width: min(340px, 86vw);
    background: #fff;
    box-shadow: var(--shadow-lg);
    padding: 96px 26px 30px;
    transform: translateX(100%);
    transition: transform .32s var(--ease);
    z-index: 70;
    overflow-y: auto;
  }
  .nav.is-open { transform: none; }
  .nav__list { flex-direction: column; align-items: stretch; gap: 4px; }
  .nav__list a {
    padding: 14px 16px;
    font-size: 1.02rem;
    border-radius: 14px;
    white-space: normal;
  }
  .nav__mobile-only { display: block; }
  .nav-toggle { display: grid; margin-left: auto; z-index: 80; position: relative; }
  .nav-scrim {
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    background: rgba(25, 28, 59, .45);
    opacity: 0; visibility: hidden;
    transition: opacity .3s var(--ease), visibility .3s;
    z-index: 65;
  }
  .nav-scrim.is-open { opacity: 1; visibility: visible; }
}

@media (max-width: 1024px) {
  .hero__grid { grid-template-columns: 1fr; text-align: center; }
  .hero__text { margin-inline: auto; }
  .hero__actions { justify-content: center; }
  .hero__badges { justify-content: center; }
  .hero__art { order: -1; margin-bottom: 34px; }
  .logo-card { transform: none; max-width: 340px; }
  .floating-chip--1 { right: -2%; }
  .floating-chip--2 { left: -3%; }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .grid--3, .team { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .auth { grid-template-columns: 1fr; }
  .auth__aside { display: none; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .topbar { font-size: .78rem; }
  .topbar .container > span { display: none; }
  .topbar .container { justify-content: flex-end; min-height: 38px; }
  .topbar__links { gap: 16px; width: 100%; justify-content: space-between; }
  .decor-hand { display: none; }
  .header .container { gap: 12px; }
  .header__actions .btn--ghost { display: none; }
  .brand__name { font-size: .95rem; }
  .header__actions .btn--primary { display: none; }
  .stats__grid { grid-template-columns: repeat(2, 1fr); gap: 26px 18px; }
  .grid--2, .grid--3, .grid--4, .team,
  .about__grid, .contact__grid, .panel-grid { grid-template-columns: 1fr; }
  .event { grid-template-columns: 72px 1fr; gap: 18px; padding: 18px; }
  .event__date { grid-row: span 2; }
  .event .tag { grid-column: 2; justify-self: start; }
  .field-row { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; gap: 28px; }
  .footer__bottom { flex-direction: column; }
  .cta-band { border-radius: var(--radius-lg); }
}

/* ---------- 19. Impressão ---------- */
@media print {
  .header, .topbar, .footer, .hero__art, .nav, .cta-band { display: none !important; }
  body { font-size: 12pt; }
  .card, .event { box-shadow: none; border-color: #ccc; }
}
