ection.getSenders) {
                    peerConnection.getSenders().forEach(sender => {
                        if (sender.track && sender.track.stop) sender.track.stop();
                    });
                }
                console.log('closing');
                peerConnection.close();
            }
            updateButtonState();
            audioLevel = 0;
        }

        startButton.addEventListener('click', (event) => {
            // Skip if clicking the mute toggle
            if (event.ta