/* =============================================================================
   Homepage motion, avinashanandsingh.com (26 Nov 2026)
   Inspired by the movement on kali.onerollstudios.com: words that rise into view,
   cards that fan in, a video frame that grows as you scroll. Layout and text are
   untouched; only transform/opacity/clip-path move.

   Nothing here hides content on its own. The hero entrance is plain CSS, started
   by a small inline script under the hero (it adds .m-hero), so it plays from the
   first paint without waiting for any download. Every animation uses fill-mode
   `backwards`: once it ends, the element is exactly its own styles again.
   The scroll entrances further down are motion.js (GSAP).
   ========================================================================== */

/* words cut by the inline script / motion.js: a clipping window with a word inside that slides up */
.m-w { display: inline-block; overflow: hidden; vertical-align: top; padding: .14em .04em .1em; margin: -.14em -.04em -.1em; }
.m-i { display: inline-block; }

@keyframes m-rise { from { transform: translateY(115%) rotate(3deg); } }
@keyframes m-up   { from { opacity: 0; transform: translateY(var(--m-y, 70px)) scale(var(--m-s, .96)); } }
@keyframes m-zoom { from { transform: scale(1.14); } }
@keyframes m-pop  { from { opacity: 0; transform: scale(.6); } }

@media (prefers-reduced-motion: no-preference) {
   .m-hero .mch-video { animation: m-zoom 2.6s cubic-bezier(.22, .61, .36, 1) backwards; }
   .m-hero .mch-tagline .m-i { animation: m-rise 1.3s cubic-bezier(.16, 1, .3, 1) backwards; animation-delay: calc(.15s + var(--i) * .05s); }
   .m-hero .mch-card { animation: m-up 1.5s cubic-bezier(.16, 1, .3, 1) .4s backwards; }
   .m-hero .mch-title .m-i { animation: m-rise 1.25s cubic-bezier(.16, 1, .3, 1) backwards; animation-delay: calc(.1s + var(--i) * .05s); }
   .m-hero .mch-meta > div, .m-hero .mch-countdown { --m-y: 16px; --m-s: 1; animation: m-up .9s cubic-bezier(.16, 1, .3, 1) backwards; }
   .m-hero .mch-meta > div:nth-child(1) { animation-delay: 1s; }
   .m-hero .mch-meta > div:nth-child(2) { animation-delay: 1.08s; }
   .m-hero .mch-countdown { animation-delay: 1.16s; }
   .m-hero .mch-btn { animation: m-pop .9s cubic-bezier(.34, 1.56, .64, 1) 1.05s backwards; }
}
