/* ============================================================
   base.css — tokens, reset, tipografia, helpers
   v2: paleta champagne dark, Fraunces + Manrope, grain SVG
   ============================================================ */

:root {
  /* Paleta extraída do protótipo */
  --bg: #0b0a08;
  --bg-2: #11100d;
  --fg: #f3ece0;
  --fg-dim: #b9b0a0;
  --muted: #2a2722;
  --accent: #c9a36b;
  --accent-soft: #d8bb8a;
  --line: rgba(243, 236, 224, 0.12);
  --line-strong: rgba(243, 236, 224, 0.22);

  /* Tipografia */
  --font-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-sans: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body { overflow-x: hidden; }

/* GRAIN / textura sutil em toda a página */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none; z-index: 1;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.06 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  mix-blend-mode: overlay;
  opacity: .6;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; background: none; border: 0; cursor: pointer; color: inherit; }

/* Helpers de tipografia (ecoam o protótipo) */
.serif { font-family: var(--font-serif); font-weight: 300; letter-spacing: -0.02em; }
.serif-it { font-family: var(--font-serif); font-style: italic; font-weight: 300; }
.mono {
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: .22em;
  font-size: 11px;
  font-weight: 500;
}

/* Eyebrow padrão de seções */
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  color: var(--fg-dim);
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  margin-bottom: 24px;
}
.eyebrow::before { content: ""; width: 24px; height: 1px; background: var(--accent); }

/* Títulos */
.section-title {
  font-family: var(--font-serif); font-weight: 300;
  font-size: clamp(36px, 5vw, 68px);
  line-height: 1.02;
  letter-spacing: -.03em;
  margin: 0 0 24px;
  max-width: 900px;
}
.section-title em { font-style: italic; color: var(--accent-soft); }

.section-lead {
  max-width: 600px;
  color: var(--fg-dim);
  font-size: 16px; line-height: 1.6;
  margin-bottom: 60px;
}

/* Container e section */
.container { max-width: 1340px; margin: 0 auto; }
section { position: relative; padding: 140px 36px; z-index: 2; }
@media (max-width: 760px) { section { padding: 90px 20px; } }

/* Reveal utilities (GSAP anima a partir destes) */
.reveal { opacity: 0; transform: translateY(40px); }
.word { display: inline-block; overflow: hidden; vertical-align: bottom; }
.word > span { display: inline-block; transform: translateY(110%); }

/* Skip-link acessibilidade */
.skip-link {
  position: absolute; left: 12px; top: -100px;
  background: var(--accent); color: #1a1610;
  padding: 12px 18px; z-index: 1000;
  border-radius: 999px;
  font-weight: 600; font-size: 13px;
  letter-spacing: .04em;
  transition: top .2s ease;
}
.skip-link:focus { top: 12px; }

/* Foco visível */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* sr-only */
.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;
}

/* Botões base */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 28px; border-radius: 999px;
  font-size: 13px; letter-spacing: .04em;
  cursor: pointer;
  transition: all .4s cubic-bezier(.2,.7,.2,1);
  border: 1px solid transparent;
  font-family: inherit;
  text-decoration: none;
}
.btn-primary { background: var(--accent); color: #1a1610; }
.btn-primary:hover { background: var(--accent-soft); transform: translateY(-2px); color: #1a1610; }
.btn-ghost { border-color: var(--line); color: var(--fg); }
.btn-ghost:hover { border-color: var(--fg); background: rgba(243,236,224,0.04); color: var(--fg); }
.arrow { display: inline-block; transition: transform .4s; }
.btn:hover .arrow { transform: translateX(4px); }

/* Respeitar reduced-motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .word > span { transform: none; }
}
