xtToCopy)
            .then(() => {
                alert('Link copied to clipboard!');
            })
            .catch(err => {
                console.error('Failed to copy text: ', err);
            });
    });
});
    // Select all save buttons
const saveButtons = document.querySelectorAll('.save-icon');

// Loop through each save button and attach event listener
saveButtons.forEach((saveBtn) => {
    saveBtn.addEventListener('click', () => {
        saveBtn.classList.toggle('active'); // Toggle the a