I get that he is putting some scroll position values (via JS) into a CSS Custom property and then using a calc() function to change the animation-delay on a paused keyframe animation. I understand what is happening and I have even used it myself. What I don’t understand is why it works.
Why does changing the animation-delay value effectively play the animation like you are using the scroll position as a “video scrubber”? How does that work? What is in the spec that allows this to happen?