document.addEventListener('DOMContentLoaded', function () {
    var navItems = document.querySelectorAll('.nav-item');
    navItems.forEach(function (item) {
        item.addEventListener('click', function () {
            navItems.forEach(function (node) {
                node.classList.remove('active');
            });
            item.classList.add('active');
        });
    });

    var buttons = document.querySelectorAll('[type="button"]');
    buttons.forEach(function (button) {
        button.addEventListener('click', function () {
            if (button.dataset.demoBound === '1') {
                return;
            }
            button.dataset.demoBound = '1';
        });
    });
});
