/* ═══════════════════════════════════════════════════════════════
   AstroKamya™ · Mobile & Tablet Premium Animations v1.0
   ─────────────────────────────────────────────────────────────
   Apple/Stripe-level purposeful motion design.
   ONLY active on tablet (≤1024px) and mobile (≤768px).
   DOES NOT touch desktop animations.
   
   GPU-accelerated: only transform + opacity animations.
   Easing: cubic-bezier(0.22, 1, 0.36, 1) — premium feel.
   ═══════════════════════════════════════════════════════════════ */

/* ── Premium easing tokens ── */
:root {
  --ease-premium: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ══════════════════════════════════════════════════════════════
   1. HERO TEXT REVEAL — Focus-driven stagger (mobile/tablet)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {

  /* Line 1: soft fade + upward motion */
  .hh-line-1 {
    opacity: 0;
    transform: translateY(12px);
    filter: blur(2px);
    animation: mobileHeroLine1 0.8s var(--ease-premium) 0.15s forwards;
  }

  /* Line 2: slightly longer delay */
  .hh-line-2 {
    opacity: 0;
    transform: translateY(12px);
    filter: blur(2px);
    animation: mobileHeroLine2 0.8s var(--ease-premium) 0.35s forwards;
  }

  /* Typewriter line: reveal with soft glow */
  .hh-typewriter-line {
    opacity: 0;
    transform: translateY(10px);
    filter: blur(2px);
    animation: mobileHeroLine3 0.9s var(--ease-premium) 0.55s forwards;
  }

  /* Gold accent: subtle glow pulse after reveal */
  .hh-accent.hh-typing {
    animation: hhTypeReveal 1.4s steps(16, end) forwards,
               mobileAccentGlow 3s ease-in-out 2s infinite;
  }

  @keyframes mobileHeroLine1 {
    0%   { opacity: 0; transform: translateY(12px); filter: blur(2px); }
    100% { opacity: 1; transform: translateY(0);    filter: blur(0);   }
  }
  @keyframes mobileHeroLine2 {
    0%   { opacity: 0; transform: translateY(12px); filter: blur(2px); }
    100% { opacity: 1; transform: translateY(0);    filter: blur(0);   }
  }
  @keyframes mobileHeroLine3 {
    0%   { opacity: 0; transform: translateY(10px); filter: blur(2px); }
    100% { opacity: 1; transform: translateY(0);    filter: blur(0);   }
  }

  /* Ultra-soft glow pulse on the gold accent text */
  @keyframes mobileAccentGlow {
    0%, 100% { filter: drop-shadow(0 0 0px transparent); }
    50%      { filter: drop-shadow(0 0 8px rgba(255,184,0,0.15)); }
  }


/* ══════════════════════════════════════════════════════════════
   2. CTA BUTTON — Magnetic feel (mobile/tablet)
   ══════════════════════════════════════════════════════════════ */

  /* Primary CTA entrance */
  .btn-primary-gold,
  .hero-actions .btn-glow,
  .hero-actions .cta-btn {
    transform: scale(0.96);
    opacity: 0;
    animation: mobileCTAEntry 0.7s var(--ease-premium) 0.9s forwards;
  }

  /* Ghost CTA entrance */
  .btn-ghost-hero,
  .hero-actions .btn-outline {
    transform: scale(0.96);
    opacity: 0;
    animation: mobileCTAEntry 0.7s var(--ease-premium) 1.05s forwards;
  }

  @keyframes mobileCTAEntry {
    0%   { opacity: 0; transform: scale(0.96); }
    100% { opacity: 1; transform: scale(1);    }
  }

  /* CTA tap feedback — micro scale-down with spring back */
  .btn-primary-gold:active,
  .btn-glow:active,
  .cta-btn:active {
    transform: scale(0.97) !important;
    transition: transform 0.1s ease !important;
  }

  /* Ultra-subtle glow bloom on CTA entrance */
  .hero-actions .btn-primary-gold,
  .hero-actions .btn-glow {
    box-shadow:
      0 4px 20px rgba(255,184,0,0.2),
      0 8px 40px rgba(255,184,0,0.1);
  }


/* ══════════════════════════════════════════════════════════════
   3. BACKGROUND MOTION — Very subtle premium gradient drift
   ══════════════════════════════════════════════════════════════ */

  /* Extremely slow radial glow movement — barely noticeable */
  #hero::after {
    animation: mobileHeroAmbient 12s ease-in-out infinite alternate;
    will-change: opacity;
  }

  @keyframes mobileHeroAmbient {
    0%   { box-shadow: inset 0 0 180px rgba(10,6,24,0.25); }
    100% { box-shadow: inset 0 0 200px rgba(10,6,24,0.18); }
  }

  /* Mesh orb slow drift on mobile — reduced count & blur */
  .mesh-orb {
    filter: blur(100px);
    animation-duration: 30s !important;
  }


/* ══════════════════════════════════════════════════════════════
   4. CONTENT STAGGER — Scroll-aware section reveals
   ══════════════════════════════════════════════════════════════ */

  /* Override default .r reveal with premium mobile easing */
  .r {
    opacity: 0;
    transform: translateY(20px);
    transition:
      opacity 0.6s var(--ease-premium),
      transform 0.6s var(--ease-premium);
  }
  .r.v {
    opacity: 1;
    transform: translateY(0);
  }

  /* Stagger children within card grids */
  .intent-grid.v .intent-card,
  .feat-bento.v .fb-card,
  .test-grid.v .test-card,
  .price-row.v .pc,
  .faq-grid.v .faq-item {
    opacity: 0;
    transform: translateY(18px);
    animation: mobileCardStagger 0.5s var(--ease-premium) forwards;
  }

  /* Stagger delays for grid children */
  .intent-grid.v .intent-card:nth-child(1),
  .feat-bento.v .fb-card:nth-child(1),
  .test-grid.v .test-card:nth-child(1),
  .price-row.v .pc:nth-child(1),
  .faq-grid.v .faq-item:nth-child(1) { animation-delay: 0ms; }

  .intent-grid.v .intent-card:nth-child(2),
  .feat-bento.v .fb-card:nth-child(2),
  .test-grid.v .test-card:nth-child(2),
  .price-row.v .pc:nth-child(2),
  .faq-grid.v .faq-item:nth-child(2) { animation-delay: 80ms; }

  .intent-grid.v .intent-card:nth-child(3),
  .feat-bento.v .fb-card:nth-child(3),
  .test-grid.v .test-card:nth-child(3),
  .price-row.v .pc:nth-child(3),
  .faq-grid.v .faq-item:nth-child(3) { animation-delay: 160ms; }

  .intent-grid.v .intent-card:nth-child(4),
  .feat-bento.v .fb-card:nth-child(4),
  .test-grid.v .test-card:nth-child(4),
  .price-row.v .pc:nth-child(4),
  .faq-grid.v .faq-item:nth-child(4) { animation-delay: 240ms; }

  @keyframes mobileCardStagger {
    0%   { opacity: 0; transform: translateY(18px); }
    100% { opacity: 1; transform: translateY(0);    }
  }


/* ══════════════════════════════════════════════════════════════
   5. TRUST BADGES / STATS — Micro-delight fade & rise
   ══════════════════════════════════════════════════════════════ */

  .hero-trust {
    opacity: 0;
    transform: translateY(14px);
    animation: mobileTrustReveal 0.7s var(--ease-premium) 1.2s forwards;
  }

  .hero-pill {
    opacity: 0;
    transform: translateY(10px);
    animation: mobileTrustReveal 0.6s var(--ease-premium) 0.05s forwards;
  }

  .hero-personal {
    opacity: 0;
    transform: translateY(10px);
    animation: mobileTrustReveal 0.7s var(--ease-premium) 0.7s forwards;
  }

  @keyframes mobileTrustReveal {
    0%   { opacity: 0; transform: translateY(14px); }
    100% { opacity: 1; transform: translateY(0);    }
  }

  /* Press logos — subtle fade in */
  .press-section {
    opacity: 0;
    animation: mobileSectionFade 0.8s var(--ease-premium) 0.3s forwards;
  }

  @keyframes mobileSectionFade {
    0%   { opacity: 0; }
    100% { opacity: 1; }
  }


/* ══════════════════════════════════════════════════════════════
   6. NAV DRAWER — Smooth slide animation refinement
   ══════════════════════════════════════════════════════════════ */

  .mobile-nav-drawer {
    transition: transform 0.4s var(--ease-premium);
  }

  .mobile-nav-backdrop {
    transition: opacity 0.3s var(--ease-premium);
  }

  /* Drawer links stagger on open */
  .mobile-nav-drawer.open .mobile-nav-link {
    animation: drawerLinkSlide 0.35s var(--ease-premium) backwards;
  }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(1) { animation-delay: 50ms; }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(2) { animation-delay: 90ms; }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(3) { animation-delay: 130ms; }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(4) { animation-delay: 170ms; }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(5) { animation-delay: 210ms; }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(6) { animation-delay: 250ms; }
  .mobile-nav-drawer.open .mobile-nav-link:nth-child(7) { animation-delay: 290ms; }

  @keyframes drawerLinkSlide {
    0%   { opacity: 0; transform: translateX(20px); }
    100% { opacity: 1; transform: translateX(0);    }
  }

  /* CTA button in drawer — delayed entrance */
  .mobile-nav-drawer.open .mobile-nav-cta .btn-glow {
    animation: mobileCTAEntry 0.5s var(--ease-premium) 0.35s backwards;
  }

}


/* ══════════════════════════════════════════════════════════════
   7. REDUCED MOTION — Accessibility respect
   ══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
