document.addEventListener("DOMContentLoaded",(function(){const e=document.querySelectorAll(".wp-block-nexa-navigation");e&&e.length>0&&e.forEach((e=>{const t=e.querySelector(".nexa-navigation-hamburger"),a=e.querySelector(".nexa-navigation-wrapper"),i=e.querySelector(".nexa-navigation-overlay"),n=e.querySelector(".nexa-navigation-sidebar-close"),c=e.querySelectorAll(".wp-block-nexa-navigation-item.has-submenu");t.addEventListener("click",(()=>{a.classList.toggle("is-active"),i.classList.toggle("is-active")})),n.addEventListener("click",(()=>{a.classList.remove("is-active"),i.classList.remove("is-active")})),i.addEventListener("click",(()=>{a.classList.remove("is-active"),i.classList.remove("is-active")})),c.forEach((e=>{const t=e.querySelector(".submenu-icon"),a=e.querySelector(".nexa-submenu-wrapper");t.addEventListener("click",(()=>{a.classList.toggle("is-active")}))}))}))}));