/* ==========================================================================
   KEYFRAMES
   ========================================================================== */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes pulse {
  0%   { transform: scale(0.9); opacity: 0.9; }
  70%  { transform: scale(1.6); opacity: 0; }
  100% { transform: scale(1.6); opacity: 0; }
}

@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@keyframes spin-slow {
  to { transform: rotate(360deg); }
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(-1.5deg); }
  50%      { transform: translateY(-8px) rotate(-1deg); }
}

@keyframes draw-line {
  from { stroke-dashoffset: 600; }
  to   { stroke-dashoffset: 0; }
}

@keyframes blink {
  0%, 60%, 100% { opacity: 1; }
  30%           { opacity: 0.25; }
}

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

@keyframes count-bar {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

/* ==========================================================================
   SCROLL-IN REVEALS
   ========================================================================== */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 700ms var(--ease-standard),
              transform 700ms var(--ease-standard);
  transition-delay: var(--reveal-delay, 0ms);
}

[data-reveal].is-in {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   PRODUCT MOCK MOTION (Lottie-like)
   ========================================================================== */
.product-frame {
  animation: float 6s var(--ease-standard) infinite;
}

.product-chart svg .chart-line {
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  animation: draw-line 2.4s var(--ease-standard) 0.3s forwards;
}

.product-chart svg .chart-point {
  opacity: 0;
  animation: fade-in 400ms var(--ease-standard) forwards;
}

.product-chart svg .chart-point.cp-1 { animation-delay: 0.8s; }
.product-chart svg .chart-point.cp-2 { animation-delay: 1.2s; }
.product-chart svg .chart-point.cp-3 { animation-delay: 1.6s; }
.product-chart svg .chart-point.cp-4 { animation-delay: 2.0s; }
.product-chart svg .chart-point.cp-5 { animation-delay: 2.4s; }

.product-chart svg .chart-area {
  opacity: 0;
  animation: fade-in 800ms var(--ease-standard) 1.2s forwards;
}

.product-pill {
  position: relative;
  overflow: hidden;
}

.product-pill::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.7) 50%, transparent 70%);
  animation: shimmer 2.6s var(--ease-standard) infinite;
}

.product-stat .delta { animation: blink 2s var(--ease-standard) infinite; }

/* Bar chart bars: paint then fill */
.bar-fill {
  transform: scaleX(0);
  animation: count-bar 1.4s var(--ease-spring) 0.4s forwards;
}

/* Hero chips wiggle */
.hero-chip { animation: float 5s var(--ease-standard) infinite; }
.hero-chip--bot { animation-delay: -2.5s; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}
