document.addEventListener('touchstart', function (event) {
    if (event.touches.length > 1) {
        event.preventDefault();
    }
}, { passive: false });

let lastTouchTime = 0;
document.addEventListener('touchstart', function (event) {
    const now = Date.now();
    if (now - lastTouchTime < 300) {
        event.preventDefault();
    }
    lastTouchTime = now;
}, { passive: false });

document.addEventListener('gesturestart', function (event) {
    event.preventDefault();
});
