html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: 'Poppins', sans-serif;
}

/* Focus indicators globais para acessibilidade */
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid #60A5FA;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Animacoes de entrada - so para secoes abaixo do hero */
/* Fallback: conteudo visivel por padrao. JS adiciona .js-ready no body pra ativar animacao */
.reveal {
  opacity: 1;
  transform: translateY(0);
}

.js-ready .reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-ready .reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.stagger-1 {
  transition-delay: 0.1s;
}

.stagger-2 {
  transition-delay: 0.2s;
}

.stagger-3 {
  transition-delay: 0.3s;
}

.stagger-4 {
  transition-delay: 0.4s;
}

.stagger-5 {
  transition-delay: 0.5s;
}

.stagger-6 {
  transition-delay: 0.6s;
}

/* Glassmorphism */
.glass {
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Gradient text */
.gradient-text {
  background: linear-gradient(135deg, #60A5FA 0%, #3B82F6 50%, #93C5FD 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Floating sutil */
@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

/* Pulse glow para CTA */
@keyframes pulse-glow {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.4);
  }
  50% {
    box-shadow: 0 0 0 12px rgba(37, 99, 235, 0);
  }
}

.pulse-glow {
  animation: pulse-glow 2.5s ease-in-out infinite;
}

/* Gradient orbs decorativos */
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.12;
  pointer-events: none;
}

/* Logo carousel */
@keyframes scroll-logos {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

.logo-track {
  animation: scroll-logos 25s linear infinite;
}

.logo-track:hover {
  animation-play-state: paused;
}

/* Card hover premium */
.card-premium {
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-premium:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(37, 99, 235, 0.15);
}

/* Timeline connector */
.timeline-line {
  background: linear-gradient(180deg, #2563EB 0%, #3B82F6 100%);
}

/* Navbar scroll */
.nav-scrolled {
  background: rgba(2, 6, 23, 0.92) !important;
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

header#navbar > div {
  align-items: center;
}

header#navbar nav a {
  display: inline-flex;
  align-items: center;
}

@media (min-width: 768px) {
  header#navbar nav {
    flex: 1;
    display: flex;
    align-items: center;
  }

  header#navbar nav .nav-links {
    margin: 0 auto;
  }

  header#navbar nav .cta-link {
    margin-left: 1.5rem;
  }
}

/* Number highlight dourado */
.number-highlight {
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* FAQ */
details summary::-webkit-details-marker {
  display: none;
}

details[open] .faq-arrow {
  transform: rotate(180deg);
}

.faq-arrow {
  transition: transform 0.3s ease;
}

/* Mesh gradient hero */
.mesh-bg {
  background: radial-gradient(ellipse at 20% 50%, rgba(37, 99, 235, 0.15) 0%, transparent 50%),
  radial-gradient(ellipse at 80% 20%, rgba(59, 130, 246, 0.1) 0%, transparent 50%),
  radial-gradient(ellipse at 60% 80%, rgba(26, 59, 143, 0.08) 0%, transparent 50%),
  linear-gradient(180deg, #0B1628 0%, #0F1D32 100%);
}

section.hero-fit {
  min-height: calc(100vh - 108px);
  padding-top: 0;
  padding-bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

section.hero-fit #hero-content {
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}

section.hero-fit .hero-bar {
  margin-top: auto !important;
}

/* Grid pattern decorativo */
.grid-pattern {
  background-image: linear-gradient(rgba(37, 99, 235, 0.06) 1px, transparent 1px),
  linear-gradient(90deg, rgba(37, 99, 235, 0.06) 1px, transparent 1px);
  background-size: 60px 60px;
}

section.relative.mesh-bg {
  box-sizing: border-box;
}

/* Glow line animada */
@keyframes glow-line {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(200%);
  }
}

.glow-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: glow-line 3s ease-in-out infinite;
}

.contact-card {
  padding: 4rem 5rem;
}

/* Botoes flutuantes — responsivo */
@media (max-width: 767px) {
  #floating-btns {
    bottom: 16px !important;
    right: 16px !important;
    gap: 10px !important;
  }

  #btn-top {
    width: 40px !important;
    height: 40px !important;
  }

  #btn-top svg {
    width: 16px !important;
    height: 16px !important;
  }

  #fab-whatsapp {
    width: 48px !important;
    height: 48px !important;
  }

  #fab-whatsapp svg {
    width: 24px !important;
    height: 24px !important;
  }

  .contact-card {
    padding: 3rem 2rem !important;
  }
}

@media (min-width: 768px) and (max-width: 1024px) {
  #floating-btns {
    bottom: 24px !important;
    right: 24px !important;
    gap: 10px !important;
  }

  #btn-top {
    width: 44px !important;
    height: 44px !important;
  }

  #btn-top svg {
    width: 18px !important;
    height: 18px !important;
  }

  #fab-whatsapp {
    width: 52px !important;
    height: 52px !important;
  }

  #fab-whatsapp svg {
    width: 26px !important;
    height: 26px !important;
  }

  .contact-card {
    padding: 3rem 2rem !important;
  }
}

/* Mobile — ajustes aprovados */
@media (max-width: 767px) {
  #hero-content {
    padding-bottom: 10rem !important;
  }

  #main-footer {
    padding-bottom: 2rem !important;
  }

  /* Reduz espaço entre dobras de mesma cor */
  #agitacao, #recursos, #como-funciona, #faq {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }

  /* Rodapé: empilhado e centralizado */
  #main-footer .border-t {
    flex-direction: column !important;
    align-items: center !important;
    text-align: center;
    gap: 0.75rem !important;
  }

  #main-footer .border-t .flex.items-center.gap-6 {
    flex-direction: column !important;
    align-items: center !important;
    gap: 0.5rem !important;
  }
}

/* Menu overlay fullscreen (mobile + tablet) */
#mobile-menu-toggle {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

#mobile-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  background: #020617;
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
  pointer-events: none;
  overflow: hidden;
}

#mobile-menu-toggle:checked ~ #mobile-overlay {
  transform: translateY(0) !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

#mobile-overlay.open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

#mobile-overlay .overlay-cta {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.5rem;
}

#mobile-menu-btn {
  position: relative;
  z-index: 10001;
  display: none !important;
  pointer-events: auto;
  cursor: pointer;
}

@media (max-width: 1024px) {
  #mobile-menu-btn {
    display: block !important;
  }
}

#mobile-overlay .overlay-link {
  display: block;
  padding: 1.25rem 1.5rem;
  font-size: 1.125rem;
  font-weight: 500;
  color: #e2e8f0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  transition: color 0.2s, background 0.2s;
}

#mobile-overlay .overlay-link:hover, #mobile-overlay .overlay-link:active {
  color: #fff;
  background: rgba(255, 255, 255, 0.04);
}

/* Tablet (iPad Air ~820px) — hamburger menu como mobile */
@media (min-width: 768px) and (max-width: 1024px) {
  header#navbar nav[aria-label] {
    display: none !important;
  }

  button#mobile-menu-btn {
    display: block !important;
  }

  section.relative.mesh-bg {
    height: auto !important;
    min-height: auto !important;
  }

  #hero-content {
    padding-top: 4rem !important;
    padding-bottom: 7rem !important;
  }

  #hero-sub {
    margin-bottom: 1.5rem !important;
  }

  #tablet-spacer {
    height: 20px !important;
  }

  #agitacao, #recursos, #como-funciona, #faq {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
  }

  #recursos-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  #recursos-grid > :last-child {
    grid-column: 1 / -1 !important;
    max-width: 50% !important;
    margin: 0 auto !important;
  }

  #main-footer .border-t {
    justify-content: center !important;
    flex-wrap: wrap !important;
  }
}

/* Desktop — reduz espaço entre dobras de mesma cor */
@media (min-width: 1025px) {
  #agitacao, #recursos, #como-funciona, #faq {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal, .js-ready .reveal {
    transition: none;
    opacity: 1;
    transform: none;
  }

  .logo-track {
    animation: none;
  }

  .pulse-glow {
    animation: none;
  }

  .glow-line::after {
    animation: none;
  }

  .card-premium {
    transition: none;
  }

  html {
    scroll-behavior: auto;
  }
}
