lock';
            chevron.classList.remove('bi-chevron-right');
            chevron.classList.add('bi-chevron-down');
        } else {
            content.style.display = 'none';
            chevron.classList.remove('bi-chevron-down');
            chevron.classList.add('bi-chevron-right');
        }
    }
    
    function toggleModalTreeDeviceSelection(deviceId) {
        if (!window.selectedDevicesForCase) {
            window.selectedDevicesForCase = [];
        }
        
        const index = window.s