/* ============================================================
   ENTRE RIOS – style.css
   Design System: Organic Editorial (terra + trigo + verde)
   Mobile-First · CSS Grid · Flexbox · Alto Contraste
   ============================================================ */

/* ============================================================
   1. DESIGN TOKENS – :root (mude aqui para alterar todo o site)
   ============================================================ */
:root {
  /* --- Paleta principal --- */
  --color-earth:      #3d2b1f;  /* marrom terra escuro (textos) */
  --color-wheat:      #c8973a;  /* dourado trigo (accent primário) */
  --color-wheat-lt:   #f0d48a;  /* dourado claro */
  --color-green:      #3a5c3e;  /* verde floresta (accent secundário) */
  --color-green-lt:   #6b9c6f;  /* verde médio */
  --color-cream:      #faf5ea;  /* fundo principal */
  --color-paper:      #f2ead6;  /* fundo seções alternadas */
  --color-bark:       #7a5c44;  /* marrom médio */
  --color-fog:        #e8dfc8;  /* bordas suaves */

  /* --- Tipografia --- */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Source Serif 4', Georgia, serif;
  --fs-base:  1rem;       /* 16px – mude aqui para alterar escala base */
  --fs-sm:    0.875rem;
  --fs-lg:    1.125rem;
  --fs-xl:    1.375rem;
  --fs-2xl:   1.75rem;
  --fs-3xl:   2.375rem;
  --fs-4xl:   3.25rem;
  --fs-hero:  clamp(2.5rem, 6vw, 5rem);
  --lh-tight: 1.2;
  --lh-body:  1.7;

  /* --- Espaçamentos --- */
  --space-xs:  0.25rem;
  --space-sm:  0.5rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2.5rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;

  /* --- Arredondamentos --- */
  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  16px;
  --radius-xl:  24px;
  --radius-full: 9999px;

  /* --- Sombras --- */
  --shadow-sm:  0 1px 3px rgba(61,43,31,.10);
  --shadow-md:  0 4px 16px rgba(61,43,31,.12);
  --shadow-lg:  0 12px 40px rgba(61,43,31,.15);

  /* --- Transições --- */
  --ease-out: cubic-bezier(.16,1,.3,1);
  --dur-fast: 150ms;
  --dur-med:  300ms;
  --dur-slow: 600ms;

  /* --- Navbar --- */
  --navbar-h:  70px;
  --navbar-bg: rgba(250,245,234,.92);
}

/* ============================================================
   2. RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: var(--fs-base);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  color: var(--color-earth);
  background-color: var(--color-cream);
  min-height: 100dvh;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--dur-fast) ease;
}

ul, ol { list-style: none; }

button { cursor: pointer; font-family: inherit; border: none; background: none; }

/* Foco visível – acessibilidade */
:focus-visible {
  outline: 3px solid var(--color-wheat);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ============================================================
   3. ALTO CONTRASTE
   ============================================================ */
body.high-contrast {
  --color-earth:    #000000;
  --color-wheat:    #ffcc00;
  --color-wheat-lt: #ffee66;
  --color-green:    #00aa44;
  --color-cream:    #ffffff;
  --color-paper:    #f0f0f0;
  --color-bark:     #333333;
  --color-fog:      #aaaaaa;
  --navbar-bg:      rgba(255,255,255,.98);
}

body.high-contrast .hero__overlay,
body.high-contrast .page-hero::after {
  background: rgba(0,0,0,.75) !important;
}

body.high-contrast .btn-primary { background: #000; color: #ffcc00; border-color: #000; }
body.high-contrast .btn-secondary { border-color: #000; color: #000; }

/* ============================================================
   4. BARRA DE ACESSIBILIDADE
   ============================================================ */
.a11y-bar {
  position: fixed;
  top: 0; right: 0;
  z-index: 9999;
  display: flex;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  background: var(--color-earth);
  border-bottom-left-radius: var(--radius-md);
}

.a11y-btn {
  background: transparent;
  color: var(--color-wheat-lt);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  transition: background var(--dur-fast);
  letter-spacing: .03em;
}

.a11y-btn:hover, .a11y-btn:focus-visible {
  background: rgba(255,255,255,.15);
}

/* ============================================================
   5. NAVBAR – Sticky, responsiva, centralizada
   ============================================================ */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--navbar-h);
  background: var(--navbar-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-fog);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--dur-med) ease;
}

.navbar.scrolled { box-shadow: var(--shadow-md); }

.navbar__inner {
  max-width: 1200px;
  margin: 0 auto;
  height: 100%;
  padding: 0 var(--space-lg);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-xl);
}

/* Logo */
.navbar__logo {
  grid-column: 1;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
  flex-shrink: 0;
}

.logo-mark {
  font-size: 1.6rem;
  color: var(--color-wheat);
  line-height: 1;
}

.logo-text {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 700;
  color: var(--color-earth);
  letter-spacing: -.02em;
}

/* Nav links (desktop) */
.navbar__nav {
  grid-column: 2;
  display: flex;
  justify-content: center;
}

.nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.nav__link {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--color-bark);
  padding: var(--space-xs) 0;
  position: relative;
  transition: color var(--dur-fast) ease;
}

/* Underline animado no hover */
.nav__link::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 2px;
  background: var(--color-wheat);
  border-radius: var(--radius-full);
  transition: width var(--dur-med) var(--ease-out);
}

.nav__link:hover { color: var(--color-earth); }
.nav__link:hover::after { width: 100%; }

/* Link ativo */
.nav__link.active {
  color: var(--color-wheat);
}
.nav__link.active::after { width: 100%; }

/* Hamburger (mobile) */
.navbar__toggle {
  grid-column: 3;
  justify-self: end;
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-sm);
  border-radius: var(--radius-sm);
  transition: background var(--dur-fast);
}

.navbar__toggle:hover { background: var(--color-fog); }

.burger-line {
  display: block;
  width: 22px; height: 2px;
  background: var(--color-earth);
  border-radius: var(--radius-full);
  transition: transform var(--dur-med) var(--ease-out), opacity var(--dur-fast);
}

/* Animação hamburger → X */
.navbar__toggle[aria-expanded="true"] .burger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.navbar__toggle[aria-expanded="true"] .burger-line:nth-child(2) {
  opacity: 0;
}
.navbar__toggle[aria-expanded="true"] .burger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ============================================================
   6. LAYOUT UTILITIES
   ============================================================ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.container--narrow {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.section-pad { padding: var(--space-3xl) 0; }

/* Grid de 2 colunas (mude grid-template-columns aqui) */
.grid-2col {
  display: grid;
  grid-template-columns: 1fr;  /* mobile: 1 col */
  gap: var(--space-2xl);
  align-items: center;
}

/* Cards grid (mude grid-template-columns aqui) */
.cards-grid {
  display: grid;
  grid-template-columns: 1fr;  /* mobile: 1 col */
  gap: var(--space-lg);
}

/* ============================================================
   7. TIPOGRAFIA
   ============================================================ */
.section-tag {
  display: inline-block;
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--color-wheat);
  margin-bottom: var(--space-sm);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: var(--lh-tight);
  color: var(--color-earth);
  margin-bottom: var(--space-lg);
}

.section-title--center { text-align: center; }

.section-title em {
  font-style: italic;
  color: var(--color-wheat);
}

/* ============================================================
   8. BUTTONS
   ============================================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--color-wheat);
  color: var(--color-earth);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: var(--space-md) var(--space-xl);
  border-radius: var(--radius-full);
  border: 2px solid var(--color-wheat);
  transition: background var(--dur-med), color var(--dur-med), transform var(--dur-fast);
  box-shadow: 0 4px 14px rgba(200,151,58,.35);
}

.btn-primary:hover, .btn-primary:focus-visible {
  background: var(--color-earth);
  color: var(--color-wheat-lt);
  transform: translateY(-2px);
}

.btn-primary--light {
  background: var(--color-cream);
  color: var(--color-earth);
  border-color: var(--color-cream);
  box-shadow: none;
}

.btn-primary--light:hover {
  background: var(--color-wheat);
  border-color: var(--color-wheat);
  color: var(--color-earth);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: transparent;
  color: var(--color-earth);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .04em;
  padding: var(--space-sm) 0;
  border-bottom: 2px solid var(--color-wheat);
  transition: color var(--dur-fast), border-color var(--dur-fast);
}

.btn-secondary:hover { color: var(--color-wheat); }

/* ============================================================
   9. HERO – Página inicial
   ============================================================ */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  overflow: hidden;
  padding: var(--space-3xl) var(--space-lg);
  padding-top: calc(var(--navbar-h) + var(--space-3xl));
}

/* Fundo com gradiente evocando campos ao entardecer */
.hero__bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(160deg,
      #2e1f0e 0%,
      #4a3520 25%,
      #6b4c2a 45%,
      #8a6835 60%,
      #3a5c3e 100%
    );
  z-index: 0;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(61,43,31,.7) 0%, rgba(61,43,31,.1) 100%);
  z-index: 1;
}

/* Textura de grão */
.hero__grain {
  position: absolute;
  inset: 0;
  z-index: 2;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: .45;
  pointer-events: none;
}

/* Partículas de trigo */
.hero__particles { position: absolute; inset: 0; z-index: 2; pointer-events: none; }

.wheat-particle {
  position: absolute;
  font-size: 1.2rem;
  opacity: 0;
  animation: floatUp var(--dur, 8s) var(--delay, 0s) infinite ease-in-out;
}

@keyframes floatUp {
  0%   { transform: translateY(0) rotate(0deg); opacity: 0; }
  10%  { opacity: .4; }
  90%  { opacity: .15; }
  100% { transform: translateY(-120vh) rotate(360deg); opacity: 0; }
}

.hero__content {
  position: relative;
  z-index: 3;
  max-width: 680px;
}

.hero__eyebrow {
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--color-wheat-lt);
  margin-bottom: var(--space-md);
  opacity: .85;
}

.hero__title {
  font-family: var(--font-display);
  font-size: var(--fs-hero);
  font-weight: 700;
  line-height: 1.05;
  color: #fff;
  margin-bottom: var(--space-lg);
}

.hero__title em {
  font-style: italic;
  color: var(--color-wheat-lt);
}

.hero__title--sm { font-size: clamp(2rem, 5vw, 3.5rem); }

.hero__subtitle {
  font-size: var(--fs-lg);
  color: rgba(255,255,255,.82);
  max-width: 560px;
  margin-bottom: var(--space-xl);
  line-height: var(--lh-body);
}

/* Hint de scroll */
.hero__scroll-hint {
  position: absolute;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  color: rgba(255,255,255,.5);
}

.scroll-line {
  display: block;
  width: 1px; height: 50px;
  background: linear-gradient(to bottom, transparent, rgba(255,255,255,.5));
  animation: scrollPulse 2s ease-in-out infinite;
}

.scroll-text {
  font-size: .7rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}

@keyframes scrollPulse {
  0%, 100% { opacity: .3; transform: scaleY(1); }
  50%       { opacity: 1;  transform: scaleY(1.1); }
}

/* ============================================================
   10. PAGE HERO (páginas internas)
   ============================================================ */
.page-hero {
  position: relative;
  min-height: 50vh;
  display: flex;
  align-items: flex-end;
  padding: var(--space-3xl) var(--space-lg) var(--space-2xl);
  padding-top: calc(var(--navbar-h) + var(--space-3xl));
  overflow: hidden;
}

.page-hero--historia {
  background:
    linear-gradient(160deg, #1a0f08 0%, #4a3520 50%, #3a5c3e 100%);
}

.page-hero--autor {
  background:
    linear-gradient(160deg, #0e1a12 0%, #3a5c3e 50%, #c8973a 100%);
}

.page-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.35);
  z-index: 1;
}

.page-hero__content {
  position: relative;
  z-index: 2;
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
  width: 100%;
}

/* ============================================================
   11. STATS BAND
   ============================================================ */
.stats-band {
  background: var(--color-earth);
  padding: var(--space-xl) 0;
}

.stats-grid {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* mobile: 2 col */
  gap: var(--space-lg);
}

.stat-item {
  text-align: center;
  padding: var(--space-md);
}

.stat-number {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  color: var(--color-wheat);
  line-height: 1;
  display: block;
}

.stat-label {
  font-size: var(--fs-sm);
  color: rgba(255,255,255,.65);
  letter-spacing: .06em;
  margin-top: var(--space-xs);
  display: block;
}

/* ============================================================
   12. ABOUT / 2-COL SECTION
   ============================================================ */
.about {
  background: var(--color-cream);
}

.about__text p {
  color: var(--color-bark);
  margin-bottom: var(--space-md);
  font-size: var(--fs-lg);
}

.about__visual { width: 100%; }

.about__img-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3;
}

/* Placeholder de imagem (substitua por <img> com src real) */
.img-placeholder {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 5rem;
}

.img-placeholder--golden {
  background: linear-gradient(135deg, #c8973a 0%, #8a6835 50%, #4a3520 100%);
}
.img-placeholder--earth {
  background: linear-gradient(135deg, #4a3520 0%, #7a5c44 60%, #c8973a 100%);
}
.img-placeholder--forest {
  background: linear-gradient(135deg, #3a5c3e 0%, #6b9c6f 60%, #c8973a 100%);
}

.about__caption {
  font-size: var(--fs-sm);
  color: var(--color-bark);
  text-align: center;
  margin-top: var(--space-sm);
  font-style: italic;
  opacity: .75;
}

/* ============================================================
   13. TABS (desktop) / ACORDEÃO (mobile)
   ============================================================ */
.pillars { background: var(--color-paper); }

/* Tab buttons */
#tab-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}

.tab-btn {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--color-bark);
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-full);
  border: 2px solid var(--color-fog);
  background: transparent;
  transition: all var(--dur-med) ease;
}

.tab-btn:hover {
  border-color: var(--color-wheat);
  color: var(--color-earth);
}

.tab-btn.active, .tab-btn[aria-selected="true"] {
  background: var(--color-wheat);
  border-color: var(--color-wheat);
  color: var(--color-earth);
}

/* Painéis das abas */
.tabs__panels { position: relative; }

.tab-panel {
  display: none;
  animation: fadeSlideIn var(--dur-med) var(--ease-out);
}

.tab-panel.active { display: grid; }

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Conteúdo do painel */
.tab-panel__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  align-items: center;
  padding: var(--space-xl);
  background: var(--color-cream);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.tab-panel__icon {
  font-size: 3.5rem;
  text-align: center;
}

.tab-panel__title {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  font-weight: 700;
  color: var(--color-earth);
  margin-bottom: var(--space-sm);
}

.tab-panel__text {
  color: var(--color-bark);
  font-size: var(--fs-lg);
  line-height: var(--lh-body);
}

/* ============================================================
   14. CARROSSEL
   ============================================================ */
.gallery { background: var(--color-earth); }
.gallery .section-tag { color: var(--color-wheat-lt); }
.gallery .section-title { color: #fff; }

.carousel { position: relative; overflow: hidden; }

.carousel__track {
  display: flex;
  transition: transform var(--dur-slow) var(--ease-out);
  will-change: transform;
}

.carousel__slide {
  flex: 0 0 100%;
  padding: 0 var(--space-sm);
}

.carousel__img-wrap {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/9;
}

.carousel__img-placeholder {
  width: 100%; height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
}

.carousel__caption {
  padding: var(--space-md) var(--space-sm) 0;
  color: rgba(255,255,255,.7);
  font-size: var(--fs-sm);
  text-align: center;
  font-style: italic;
}

.carousel__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.carousel__btn {
  width: 44px; height: 44px;
  border-radius: var(--radius-full);
  border: 2px solid rgba(255,255,255,.3);
  color: #fff;
  font-size: var(--fs-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--dur-fast);
  background: rgba(255,255,255,.08);
}

.carousel__btn:hover, .carousel__btn:focus-visible {
  background: var(--color-wheat);
  border-color: var(--color-wheat);
  color: var(--color-earth);
}

.carousel__dots { display: flex; gap: var(--space-sm); }

.carousel__dot {
  width: 8px; height: 8px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,.3);
  border: none;
  transition: all var(--dur-med);
  cursor: pointer;
}

.carousel__dot.active {
  background: var(--color-wheat);
  width: 24px;
}

/* ============================================================
   15. CARDS DE SUSTENTABILIDADE
   ============================================================ */
.sustentabilidade { background: var(--color-cream); }

.card {
  background: var(--color-paper);
  border: 1px solid var(--color-fog);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transition: transform var(--dur-med) var(--ease-out), box-shadow var(--dur-med);
  role: listitem;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card__icon {
  font-size: 2.5rem;
  line-height: 1;
  margin-bottom: var(--space-sm);
}

.card__title {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 700;
  color: var(--color-earth);
}

.card__text {
  font-size: var(--fs-base);
  color: var(--color-bark);
  line-height: var(--lh-body);
  flex: 1;
}

.card__tag {
  display: inline-block;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--color-green);
  background: rgba(58,92,62,.1);
  padding: 2px 10px;
  border-radius: var(--radius-full);
  align-self: flex-start;
}

/* ============================================================
   16. CTA BAND
   ============================================================ */
.cta-band {
  background: var(--color-green);
  padding: var(--space-2xl) 0;
}

.cta-band__inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  align-items: flex-start;
}

.cta-band__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 700;
  color: #fff;
  line-height: var(--lh-tight);
}

.cta-band__sub {
  color: rgba(255,255,255,.75);
  font-size: var(--fs-lg);
  margin-top: var(--space-sm);
}

/* ============================================================
   17. TIMELINE
   ============================================================ */
.timeline-section { background: var(--color-paper); }

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  padding: var(--space-lg) 0;
}

/* Linha central */
.timeline::before {
  content: '';
  position: absolute;
  left: 18px;
  top: 0; bottom: 0;
  width: 2px;
  background: var(--color-fog);
}

.timeline__item {
  position: relative;
  padding-left: 56px;
  margin-bottom: var(--space-2xl);
  animation: revealIn var(--dur-slow) var(--ease-out) both;
}

/* Ponto na linha */
.timeline__item::before {
  content: '';
  position: absolute;
  left: 10px; top: 6px;
  width: 18px; height: 18px;
  border-radius: var(--radius-full);
  background: var(--color-wheat);
  border: 3px solid var(--color-cream);
  box-shadow: 0 0 0 2px var(--color-wheat);
  z-index: 1;
}

.timeline__year {
  font-family: var(--font-display);
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--color-wheat);
  letter-spacing: .1em;
  margin-bottom: var(--space-xs);
}

.timeline__title {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 700;
  color: var(--color-earth);
  margin-bottom: var(--space-sm);
}

.timeline__text {
  color: var(--color-bark);
  line-height: var(--lh-body);
}

/* ============================================================
   18. ACORDEÃO
   ============================================================ */
.accordion-section { background: var(--color-cream); }

.accordion__item {
  border: 1px solid var(--color-fog);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-sm);
  overflow: hidden;
  transition: box-shadow var(--dur-fast);
}

.accordion__item:hover { box-shadow: var(--shadow-sm); }

.accordion__trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  background: var(--color-paper);
  text-align: left;
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-weight: 600;
  color: var(--color-earth);
  transition: background var(--dur-fast), color var(--dur-fast);
  gap: var(--space-md);
}

.accordion__trigger[aria-expanded="true"] {
  background: var(--color-earth);
  color: var(--color-wheat-lt);
}

.accordion__icon {
  font-size: var(--fs-xl);
  font-weight: 300;
  flex-shrink: 0;
  transition: transform var(--dur-med) var(--ease-out);
  font-style: normal;
}

.accordion__trigger[aria-expanded="true"] .accordion__icon {
  transform: rotate(45deg);
}

.accordion__panel {
  display: none;
  padding: var(--space-lg);
  background: var(--color-cream);
  color: var(--color-bark);
  line-height: var(--lh-body);
  font-size: var(--fs-base);
  border-top: 1px solid var(--color-fog);
  animation: fadeSlideIn var(--dur-med) var(--ease-out);
}

/* ============================================================
   19. FOOTER
   ============================================================ */
.footer {
  background: var(--color-earth);
  padding: var(--space-2xl) 0 var(--space-xl);
}

.footer__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  align-items: start;
}

.footer__brand .logo-text { color: var(--color-wheat-lt); }
.footer__brand .logo-mark { color: var(--color-wheat); }

.footer__tagline {
  font-size: var(--fs-sm);
  color: rgba(255,255,255,.5);
  margin-top: var(--space-xs);
}

.footer__nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md) var(--space-lg);
}

.footer__nav a {
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255,255,255,.55);
  transition: color var(--dur-fast);
}

.footer__nav a:hover { color: var(--color-wheat); }

.footer__copy {
  font-size: var(--fs-sm);
  color: rgba(255,255,255,.3);
  letter-spacing: .04em;
}

/* ============================================================
   20. SCROLL REVEAL
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition:
    opacity var(--dur-slow) var(--ease-out),
    transform var(--dur-slow) var(--ease-out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Delay escalonado para filhos */
.reveal > *:nth-child(2) { transition-delay: 80ms; }
.reveal > *:nth-child(3) { transition-delay: 160ms; }
.reveal > *:nth-child(4) { transition-delay: 240ms; }

@keyframes revealIn {
  from { opacity: 0; transform: translateX(-16px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* ============================================================
   21. RESPONSIVE – Tablet (≥ 640px)
   ============================================================ */
@media (min-width: 640px) {

  /* Grid 2 col ativo */
  .grid-2col { grid-template-columns: 1fr 1fr; }

  /* Cards 2 colunas */
  .cards-grid { grid-template-columns: repeat(2, 1fr); }

  /* Stats 4 colunas */
  .stats-grid { grid-template-columns: repeat(4, 1fr); }

  /* CTA band row */
  .cta-band__inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  /* Timeline linha central */
  .timeline::before { left: 50%; transform: translateX(-50%); }

  .timeline__item {
    width: 50%;
    padding-left: 0;
    padding-right: var(--space-2xl);
    text-align: right;
  }

  .timeline__item:nth-child(even) {
    margin-left: 50%;
    padding-right: 0;
    padding-left: var(--space-2xl);
    text-align: left;
  }

  .timeline__item::before {
    left: auto;
    right: -9px;
  }

  .timeline__item:nth-child(even)::before {
    left: -9px;
    right: auto;
  }

  /* Footer grid */
  .footer__inner { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   22. RESPONSIVE – Desktop (≥ 960px)
   ============================================================ */
@media (min-width: 960px) {

  /* Hamburger oculto */
  .navbar__toggle { display: none; }

  /* Nav visível */
  .navbar__nav {
    position: static;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
  }

  .nav__list { flex-direction: row; }

  /* Cards 3 colunas */
  .cards-grid { grid-template-columns: repeat(3, 1fr); }

  /* Tab panel 2 col */
  .tab-panel__inner { grid-template-columns: 1fr 2fr; }

  /* Carousel 3 visible */
  .carousel__slide { flex: 0 0 33.333%; }

  /* Footer 3 col */
  .footer__inner { grid-template-columns: 2fr 1fr 1fr; }
}

/* ============================================================
   23. MOBILE MENU
   ============================================================ */
@media (max-width: 959px) {
  .navbar__inner {
    display: flex;
    justify-content: space-between;
    gap: 0;
  }

  .navbar__toggle {
    display: flex;
    grid-column: unset;
    justify-self: unset;
  }

  .navbar__nav {
    grid-column: unset;
    position: absolute;
    top: var(--navbar-h);
    left: 0; right: 0;
    background: var(--navbar-bg);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--color-fog);
    box-shadow: var(--shadow-md);
    padding: var(--space-lg);
    /* Oculto por padrão */
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    pointer-events: none;
    transition: clip-path var(--dur-med) var(--ease-out);
  }

  .navbar__nav.open {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    pointer-events: all;
  }

  .nav__list {
    flex-direction: column;
    align-items: center;
    gap: var(--space-lg);
  }

  .nav__link { font-size: var(--fs-base); }
}

/* ============================================================
   24. PRINT
   ============================================================ */
@media print {
  .navbar, .a11y-bar, .hero__particles, .hero__scroll-hint { display: none; }
  body { font-size: 12pt; color: #000; background: #fff; }
  a { text-decoration: underline; }
}
