/* ===================== NAVBAR ===================== */
#main-nav {
  pointer-events: none;
}

#main-nav .navbar-container,
#main-nav .mega-menu {
  pointer-events: auto;
}

/* Transparent state (in hero) */
#main-nav .navbar-container {
  background: transparent;
}

/* Scrolled state: liquid glass */
#main-nav.scrolled .navbar-container {
  background: rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 -1px 0 rgba(255, 255, 255, 0.1);
}

/* Dark text when scrolled on light backgrounds */
#main-nav.scrolled.on-light .nav-link,
#main-nav.scrolled.on-light .nav-btn-signup {
  color: #000;
}

#main-nav.scrolled.on-light .nav-btn-cta {
  color: #000;
  border-color: #000;
}

#main-nav.scrolled.on-light .nav-btn-cta:hover {
  background: #000;
  color: #fff;
}

#main-nav.scrolled.on-light .nav-text-muted {
  color: rgba(0, 0, 0, 0.6);
}

#main-nav.scrolled.on-light .nav-chevron {
  color: rgba(0, 0, 0, 0.4);
}

/* Nav link underline animation */
.nav-link-line {
  height: 1px;
  width: 0;
  background: currentColor;
  transition: width 0.3s ease;
  margin: 0 auto;
}

.nav-link-wrapper:hover .nav-link-line,
.nav-link-wrapper.active .nav-link-line {
  width: 100%;
}

/* Mega menu */
.mega-menu {
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.mega-menu.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  display: block !important;
}

/* Mega menu glass effect */
#main-nav.scrolled .mega-menu.visible {
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
}

/* Logo filter for scrolled state — only darken on glass bg */
#main-nav.scrolled.on-light .nav-logo {
  filter: brightness(0);
}

/* Hero section */
#hero {
  background-color: #292828;
}

.hero-card-main {
  position: relative;
  z-index: 1;
}

.hero-card-dashboard {
  z-index: 2;
}

.hero-card-timeline {
  z-index: 3;
}

@media (max-width: 1024px) {
  .hero-card-dashboard {
    display: none;
  }

  .hero-card-timeline {
    position: relative !important;
    right: auto !important;
    bottom: auto !important;
    width: 100% !important;
    margin-top: 20px;
  }
}

/* ===================== BASE STYLES ===================== */
@font-face {
  font-family: 'Aspekta';
  src: local('Aspekta');
  font-weight: 750;
  font-style: normal;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.font-display {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 800;
}

/* ===================== BENTO GRID PATTERN ===================== */
.bento-grid-pattern {
  position: relative;
}

.bento-grid-pattern::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 27.5px 27.5px;
  border-radius: inherit;
  pointer-events: none;
  z-index: 0;
}

.bento-grid-pattern > * {
  position: relative;
  z-index: 1;
}

/* ===================== CHANNELS GRID ===================== */
.channels-grid-bg {
  background-image:
    linear-gradient(rgba(0,0,0,0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.08) 1px, transparent 1px);
  background-size: 27.5px 27.5px;
}

/* ===================== FAQ ===================== */
.faq-item button:hover .faq-arrow {
  opacity: 0.7;
}

.faq-item.active .faq-arrow {
  transform: rotate(180deg);
}

.faq-content {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-content {
  display: block;
  max-height: 200px;
}

/* ===================== MARQUEE ===================== */
.marquee-track {
  animation: marquee 8s linear infinite;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-33.33%); }
}

/* ===================== LOGO MARQUEE ===================== */
.logo-marquee-track {
  animation: logoMarquee 25s linear infinite;
}

@keyframes logoMarquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ===================== HOW IT WORKS ===================== */
.hiw-item {
  transition: background-color 0.2s ease;
}

.hiw-item:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

.hiw-item.active {
  background-color: rgba(0, 0, 0, 0.05);
}

/* ===================== FEATURE SLIDES ===================== */
.feature-slide {
  position: absolute;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.feature-slide.hidden {
  opacity: 0;
  pointer-events: none;
}

.feature-slide:not(.hidden) {
  opacity: 1;
}

/* ===================== BUTTONS ===================== */
a[href="#cta"],
a[href="#"],
button {
  transition: all 0.2s ease;
}

/* ===================== CTA SECTION ===================== */
#cta {
  position: relative;
}

#cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 30%, black 70%);
  pointer-events: none;
  z-index: 5;
}

#cta .relative.z-10 {
  z-index: 10;
}

/* ===================== SCROLL ANIMATIONS ===================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-on-scroll {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 1024px) {
  #hero h1 {
    font-size: 48px;
  }

  h2 {
    font-size: 48px !important;
  }

  .feature-slide h2 {
    font-size: 36px !important;
  }

  #features-sticky .flex {
    flex-direction: column;
  }

  #features-sticky .w-1\/2 {
    width: 100%;
  }

  section.py-40 {
    padding-top: 80px;
    padding-bottom: 80px;
  }
}

@media (max-width: 768px) {
  #hero h1 {
    font-size: 36px;
  }

  #hero .px-10 {
    padding-left: 20px;
    padding-right: 20px;
  }

  h2 {
    font-size: 36px !important;
  }

  .grid-cols-2,
  .grid-cols-3 {
    grid-template-columns: 1fr !important;
  }

  .flex.items-center.gap-4 {
    flex-direction: column;
  }

  .w-\[560px\] {
    width: 100% !important;
  }

  .flex.gap-5.justify-center {
    flex-direction: column;
    align-items: center;
  }

  footer .flex.items-start.justify-between {
    flex-direction: column;
    gap: 40px;
  }

  footer .flex.gap-5 {
    flex-wrap: wrap;
    gap: 20px;
  }

  #cta h2 {
    font-size: 48px !important;
  }

  #cta .absolute {
    display: none;
  }

  .bg-cream.rounded-2xl.overflow-hidden.flex {
    flex-direction: column;
    height: auto;
  }

  .bg-cream.rounded-2xl .w-\[285px\] {
    width: 100%;
  }
}
