     });

      // Update cleanup
      window.addEventListener("beforeunload", () => {
        if (timestampInterval) clearInterval(timestampInterval);
        if (heartbeatInterval) clearInterval(heartbeatInterval);
        if (countdownInterval) clearInterval(countdownInterval);
      });
    </script>
  </body>
</html>
