/* ================================================
   Chii Landing Page — Animations
   ================================================ */

/* ---------- Mascot Float ---------- */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-14px); }
}

.mascot-float {
  animation: float 3.4s ease-in-out infinite;
  will-change: transform;
}

/* ---------- Hero Gradient Orbs ---------- */
@keyframes orb-drift-1 {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.4; }
  33%      { transform: translate(30px, -20px) scale(1.1); opacity: 0.55; }
  66%      { transform: translate(-15px, 15px) scale(0.95); opacity: 0.35; }
}

@keyframes orb-drift-2 {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.3; }
  40%      { transform: translate(-25px, 20px) scale(1.15); opacity: 0.45; }
  70%      { transform: translate(20px, -10px) scale(0.9); opacity: 0.25; }
}

@keyframes orb-drift-3 {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.25; }
  50%      { transform: translate(15px, 25px) scale(1.08); opacity: 0.4; }
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform, opacity;
}

.hero-orb-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(20, 184, 166, 0.25) 0%, transparent 70%);
  top: -120px;
  right: -80px;
  animation: orb-drift-1 12s ease-in-out infinite;
}

.hero-orb-2 {
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, rgba(255, 184, 48, 0.15) 0%, transparent 70%);
  bottom: -60px;
  left: -40px;
  animation: orb-drift-2 15s ease-in-out infinite;
}

.hero-orb-3 {
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(255, 107, 157, 0.12) 0%, transparent 70%);
  top: 40%;
  left: 35%;
  animation: orb-drift-3 18s ease-in-out infinite;
}

/* ---------- CTA Banner Orbs ---------- */
@keyframes cta-orb-1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(20px, -15px) scale(1.1); }
}

@keyframes cta-orb-2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(-20px, 12px) scale(1.15); }
}

.cta-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform;
}

.cta-orb-1 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
  top: -80px;
  right: -60px;
  animation: cta-orb-1 10s ease-in-out infinite;
}

.cta-orb-2 {
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(255, 184, 48, 0.12) 0%, transparent 70%);
  bottom: -40px;
  left: -30px;
  animation: cta-orb-2 13s ease-in-out infinite;
}

/* ---------- Premium Card Glow Pulse ---------- */
@keyframes glow-pulse {
  0%, 100% { box-shadow: var(--card-premium-glow); }
  50%      { box-shadow: 0 0 50px rgba(20, 184, 166, 0.45), 0 0 100px rgba(20, 184, 166, 0.2); }
}

/* ---------- Scroll Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children within a grid */
.features-grid .reveal:nth-child(2) { transition-delay: 0.08s; }
.features-grid .reveal:nth-child(3) { transition-delay: 0.16s; }
.features-grid .reveal:nth-child(4) { transition-delay: 0.24s; }
.features-grid .reveal:nth-child(5) { transition-delay: 0.32s; }
.features-grid .reveal:nth-child(6) { transition-delay: 0.4s; }

.testimonials-grid .reveal:nth-child(2) { transition-delay: 0.1s; }
.testimonials-grid .reveal:nth-child(3) { transition-delay: 0.2s; }

.pricing-grid .reveal:nth-child(2) { transition-delay: 0.12s; }

.stats-grid .reveal:nth-child(1) { transition-delay: 0s; }
.stats-grid .reveal:nth-child(3) { transition-delay: 0.1s; }
.stats-grid .reveal:nth-child(5) { transition-delay: 0.2s; }

/* ---------- FAQ Chevron Rotation ---------- */
.faq-chevron {
  transition: transform 0.3s ease;
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

/* ---------- Gradient Text Shimmer ---------- */
@keyframes gradient-shift {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.text-gradient {
  background: linear-gradient(135deg, #14b8a6, #2dd4bf, #FFB830, #14b8a6);
  background-size: 300% 300%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradient-shift 6s ease infinite;
}

/* ---------- Nav Scroll ---------- */
#navbar {
  transition: background-color 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}

#navbar.scrolled {
  background-color: var(--bg-nav);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
}

/* ---------- Hamburger Animation ---------- */
.mobile-menu-btn.open .hamburger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.mobile-menu-btn.open .hamburger-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.mobile-menu-btn.open .hamburger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Step Connector Pulse ---------- */
@keyframes connector-pulse {
  0%, 100% { opacity: 0.5; }
  50%      { opacity: 1; }
}

.step-connector svg {
  animation: connector-pulse 2s ease-in-out infinite;
}

/* ---------- Reduce 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;
  }
}
