/* ==========================================================================
   ANIMAÇÃO SLIDE-UP & FADE (ESMAECER) — NORTE CORPORATE
   Padrão idêntico ao ajustado na plataforma Norte Invest (fadeUpPublic).
   Suave, contínuo, coerente e com esmaecimento (fade) elegante.
   ========================================================================== */

/* 1. Animação Global Padrão (Fade-In + Slide-Up Suave) */
@keyframes fadeUpPublic {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 2. Animação Estrutural Leve (Fade / Esmaecer Puro) para Header e Footer */
@keyframes structuralFade {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

/* Header e Footer esmaecem suavemente no carregamento */
header.bg-nav,
footer {
  opacity: 0;
  animation: structuralFade 0.45s ease-out forwards;
}

/* 3. Aplicação do Slide-Up com Fade nos blocos filhos diretos do conteúdo principal */
.th-main > * {
  opacity: 0;
  animation: fadeUpPublic 0.65s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Exceção: O vídeo hero da Home esmaece suavemente no lugar (sem solavanco vertical) */
#hero,
.hero-fullwidth {
  animation: structuralFade 0.6s ease-out forwards !important;
  transform: none !important;
}

/* Exceções: Modais e Drawer Mobile nunca sofrem animação de bloco */
.nc-modal-overlay,
.nc-modal-wrapper,
.gm-menu-overlay,
.gm-menu-list-wrapper {
  animation: none !important;
  opacity: 1 !important;
  transform: none !important;
}

/* Exceções: Separadores horizontais e quebras de linha mantêm altura e opacidade */
.th-main > hr,
.th-main > div:empty {
  opacity: 1 !important;
  animation: none !important;
  transform: none !important;
}

/* Stagger (Efeito cascata suave) para os blocos da página */
.th-main > *:nth-child(1) { animation-delay: 50ms; }
.th-main > *:nth-child(2) { animation-delay: 140ms; }
.th-main > *:nth-child(3) { animation-delay: 230ms; }
.th-main > *:nth-child(4) { animation-delay: 320ms; }
.th-main > *:nth-child(5) { animation-delay: 410ms; }
.th-main > *:nth-child(6) { animation-delay: 500ms; }
.th-main > *:nth-child(7) { animation-delay: 590ms; }
.th-main > *:nth-child(n+8) { animation-delay: 680ms; }

/* 4. Cascata interna suave para cards da Equipe e botões de Soluções */
.perfil {
  opacity: 0;
  animation: fadeUpPublic 0.65s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.perfil:nth-child(1) { animation-delay: 150ms; }
.perfil:nth-child(2) { animation-delay: 230ms; }
.perfil:nth-child(3) { animation-delay: 310ms; }
.perfil:nth-child(4) { animation-delay: 390ms; }
.perfil:nth-child(5) { animation-delay: 470ms; }
.perfil:nth-child(6) { animation-delay: 550ms; }
.perfil:nth-child(7) { animation-delay: 630ms; }

.button-elements {
  opacity: 0;
  animation: fadeUpPublic 0.65s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.button-elements:nth-child(1) { animation-delay: 200ms; }
.button-elements:nth-child(2) { animation-delay: 280ms; }

/* 5. Garantia para os efeitos de hover :hover { transform: scale() } */
.scale:hover {
  transform: scale(0.98) !important;
}
.shrink:hover {
  transform: scale(0.95) !important;
}
.btn-historico-modal:hover {
  transform: translateY(-2px) !important;
}

/* 6. Preferência por movimento reduzido */
@media (prefers-reduced-motion: reduce) {
  .th-main > *,
  header.bg-nav,
  footer,
  .perfil,
  .button-elements {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}
