Replaces hover-to-play with viewport-visibility autoplay for a more
Instagram-like browsing experience. Videos auto-play when their card
enters the viewport (25% threshold) and pause+reset when scrolled off.
- New videoAutoplayObserver in logic_virtual.js with threshold: 0.25
- Each rendered video is registered with the observer
- Pool/removal flow unobserves and pauses the video to prevent leaks
- createCard() in logic_ui.js drops the hover-play listeners; keeps
click-to-fullscreen and loadedmetadata aspect ratio handlers
- Observer also lazy-loads src on first intersection as a safety net
Uses native IntersectionObserver so it respects zoom, pan, and any
viewport transform automatically — no manual bounds math needed.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>