/* Motion — reveal + decorative animations. Reduced-motion safe via reset.css. */

[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity var(--t-slow) var(--ease-out),
    transform var(--t-slow) var(--ease-out);
}
[data-reveal][data-revealed="true"] {
  opacity: 1;
  transform: translateY(0);
}

[data-reveal-delay="1"] { transition-delay: 80ms; }
[data-reveal-delay="2"] { transition-delay: 160ms; }
[data-reveal-delay="3"] { transition-delay: 240ms; }
[data-reveal-delay="4"] { transition-delay: 320ms; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}
@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Marquee strip — horizontally scrolling key-phrases band */
.marquee {
  display: flex; overflow: hidden;
  border-block: 1px solid var(--brand-line);
  padding-block: var(--sp-4);
}
.marquee-track {
  display: flex; gap: var(--sp-7);
  white-space: nowrap;
  animation: marquee 44s linear infinite;
}
.marquee-track > * {
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--brand-muted);
  font-weight: 500;
}
.marquee-track > *::after {
  content: '';
  display: inline-block;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--brand-accent);
  margin-left: var(--sp-7);
  vertical-align: middle;
  opacity: 0.6;
}

/* ============================================================
 * Parrot mascot — mild cha-cha shimmy
 * ============================================================
 * Activated when /data/site-config.json#parrotMotion === "dance"
 * (set via data-parrot-motion="dance" on the .parrot-mascot img by inline script).
 * Tempo ~1.6s = soft 1-2-cha-cha-cha groove. Pause on hover so visitors
 * can actually look at the mascot. prefers-reduced-motion always wins.
 */
@keyframes parrot-chacha {
  0%   { transform: rotate(-2.5deg) translateY(0); }
  25%  { transform: rotate( 2.5deg) translateY(-3px); }
  50%  { transform: rotate(-2.5deg) translateY(0); }
  75%  { transform: rotate( 2.5deg) translateY(-3px); }
  100% { transform: rotate(-2.5deg) translateY(0); }
}
.parrot-mascot {
  transform-origin: 50% 90%;  /* pivot at the feet, not the center, so it swings like dancing */
  will-change: transform;
}
.parrot-mascot[data-parrot-motion="dance"] {
  animation: parrot-chacha 1.6s ease-in-out infinite;
}
.hero-art:hover .parrot-mascot[data-parrot-motion="dance"],
.hero-art:focus-within .parrot-mascot[data-parrot-motion="dance"] {
  animation-play-state: paused;
}
@media (prefers-reduced-motion: reduce) {
  .parrot-mascot[data-parrot-motion="dance"] {
    animation: none;
  }
}
