
    document.addEventListener("DOMContentLoaded", function () {
        var currentUrl = window.location.pathname.split('/').pop(); 

        var links = document.querySelectorAll(".menu a");

        links.forEach(function (link) {
            if (link.getAttribute("href") === currentUrl) {
                link.classList.add("active");
            }
        });
    });

