/* JavaScript to follow cursor */ document.addEventListener('mousemove', function(e) { var spotlight = document.querySelector('.spotlight'); spotlight.style.left = e.pageX + 'px'; spotlight.style.top = e.pageY + 'px'; }); /* Fallback for no-JS users */ body.no-js .spotlight { display: none; }