/* ==========================================================================
   base.css — tokens de design, reset, tipografia e componentes globais
   ========================================================================== */

:root {
  /* Paleta: rosa da logo, branco e preto. Os tons rose-2/3 são o rosa
     ligeiramente mais escuro, usados só em bordas e áreas de apoio. */
  --rose: #f8eeef;
  --rose-2: #f0dfe1;
  --rose-3: #e2c9cc;
  --white: #ffffff;
  --black: #000000;
  --ink-2: rgba(0, 0, 0, 0.76);
  --ink-3: rgba(0, 0, 0, 0.58);
  --line-dark: rgba(255, 255, 255, 0.22);
  --whatsapp: #25d366; /* única cor fora da paleta: reconhecimento imediato do WhatsApp */

  /* Tipografia: serifa de alto contraste (mesma família visual da logo) + sans humanista */
  --font-display: "Cormorant Garamond", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: "Figtree", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", sans-serif;

  --header-h: 76px;
  --container: 1180px;
  --gutter: clamp(20px, 4vw, 40px);
  --section-y: clamp(72px, 9vw, 124px);
  --radius-s: 4px;
  --radius-m: 14px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

@media (max-width: 720px) {
  :root { --header-h: 64px; }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding-top: var(--header-h); /* espaço do cabeçalho fixo */
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--black);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
[id] { scroll-margin-top: calc(var(--header-h) + 16px); }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 5.6vw, 4.6rem); }
h2 { font-size: clamp(2.1rem, 4vw, 3.3rem); }
h3 { font-size: clamp(1.45rem, 2.2vw, 1.85rem); line-height: 1.15; }

/* Foco sempre visível para quem navega pelo teclado */
:focus-visible { outline: 3px solid var(--black); outline-offset: 3px; }
.on-dark :focus-visible, .site-footer :focus-visible { outline-color: var(--white); }

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

.skip-link {
  position: fixed; left: 12px; top: -80px; z-index: 300; padding: 10px 18px;
  background: var(--black); color: var(--white); border-radius: 999px; text-decoration: none; font-weight: 600;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- Estrutura ---------- */
/* Largura padrão do conteúdo: no máximo 1180px, sempre com margem nas laterais. */
.container { width: min(var(--container), 100% - 2 * var(--gutter)); margin-inline: auto; }
.section { padding-block: var(--section-y); }
.section--rose { background: var(--rose); }
.section--black { background: var(--black); color: var(--white); }

/* Cabeçalho de seção: título + frase de apoio, com largura limitada para leitura confortável. */
.section-head { max-width: 46rem; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head p { font-size: 1.18rem; color: var(--ink-2); margin: 0; }
.section--black .section-head p { color: rgba(255, 255, 255, 0.78); }

.prose p { white-space: pre-line; max-width: 62ch; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- Botões ---------- */
/* Botão padrão: pílula preta com texto branco. As variações (--ghost, --light, --sm) só mudam cor e tamanho. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 0.85em 1.7em; border: 2px solid var(--black); border-radius: 999px;
  font-weight: 600; font-size: 0.98rem; line-height: 1.2; text-decoration: none; text-align: center;
  background: var(--black); color: var(--white);
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.btn:hover { background: transparent; color: var(--black); }
.btn--ghost { background: transparent; color: var(--black); }
.btn--ghost:hover { background: var(--black); color: var(--white); }
.btn--light { background: var(--white); color: var(--black); border-color: var(--white); }
.btn--light:hover { background: transparent; color: var(--white); }
.btn--sm { padding: 0.6em 1.3em; font-size: 0.92rem; }
.btn svg { width: 1.15em; height: 1.15em; flex: none; }
.on-dark .btn--ghost, .section--black .btn--ghost { color: var(--white); border-color: var(--white); }
.on-dark .btn--ghost:hover, .section--black .btn--ghost:hover { background: var(--white); color: var(--black); }

.link-underline { font-weight: 600; text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 2px; }
.link-underline:hover { text-decoration-thickness: 3px; }

/* Etiqueta pequena (tipo da atividade, unidade, valores). */
.chip {
  display: inline-block; padding: 0.2em 0.85em; border-radius: 999px; font-size: 0.82rem; font-weight: 600;
  line-height: 1.5; background: var(--rose); border: 1px solid var(--rose-3);
}
.section--rose .chip { background: var(--white); }

.icon { width: 1.4em; height: 1.4em; flex: none; }

/* Destaque temporário do item encontrado pela busca ou por âncoras */
.is-target { outline: 3px solid var(--black); outline-offset: 6px; border-radius: var(--radius-s); }

/* Foto ausente: espaço reservado editável depois */
/* Espaço tracejado que aparece no lugar de uma foto que ainda não existe. */
.placeholder {
  display: grid; place-items: center; gap: 8px; align-content: center; text-align: center;
  background: var(--rose); color: var(--ink-3); border: 1.5px dashed var(--rose-3);
  padding: 24px; font-size: 0.95rem;
}
.placeholder svg { width: 44px; height: 44px; margin-inline: auto; opacity: 0.7; }

/* Tela de carregamento (evita "piscar" de conteúdo vazio) */
.loading-note { min-height: 60vh; display: grid; place-items: center; color: var(--ink-3); }

/* Respeita quem desativou animações no sistema: transições ficam praticamente instantâneas. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

.btn:disabled { opacity: 0.55; cursor: not-allowed; }

/* O atributo [hidden] precisa vencer qualquer "display" definido nos componentes */
[hidden] { display: none !important; }
