.log('Brightness set successfully:', data);
    })
    .catch(error => {
        console.error('Error setting brightness:', error);
    });
}


    function showRunning(){
        hideAllSections();
        document.getElementById("running").style.display = "block";
    }
    function countProgress(){
        if(time_elapsed >= attack_timeout){
            document.getElementById("errors").innerHTML = "Please reconnect to Nightlight AP";
            document.getElementById("errors").style.display = "block";