/* Shared motion pieces used by every design. Content stays visible if JS is off. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
body { margin: 0; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--focus, currentColor); outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Word-by-word reveal: each word slides up out of a mask. */
.w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 .02em .12em; margin: 0 -.02em -.12em; }
.wi { display: inline-block; will-change: transform; }
.js .is-split .wi { transform: translateY(115%); transition: transform 1s cubic-bezier(.16, 1, .3, 1); transition-delay: calc(var(--i) * 40ms + var(--d, 0ms)); }
.js.is-loaded .is-split.is-in .wi { transform: none; }

/* Fade-and-rise for blocks. */
.js [data-reveal] { opacity: 0; transform: translateY(32px); transition: opacity 1s ease, transform 1s cubic-bezier(.16, 1, .3, 1); transition-delay: var(--d, 0ms); }
.js.is-loaded [data-reveal].is-in { opacity: 1; transform: none; }

/* Endless strip of words. */
.marquee { overflow: hidden; white-space: nowrap; }
.marquee__track { display: inline-flex; width: max-content; animation: marquee var(--speed, 38s) linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Live dot. */
.pulse { position: relative; display: inline-block; width: .55em; height: .55em; border-radius: 50%; background: var(--live, #3ee08f); }
.pulse::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: inherit; animation: pulse 2s ease-out infinite; }
@keyframes pulse { to { transform: scale(3); opacity: 0; } }

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