class CustomHeader extends HTMLElement {
connectedCallback() {
this.attachShadow({ mode: 'open' });
this.shadowRoot.innerHTML = `
`;
// Mobile menu toggle
const menuButton = this.shadowRoot.getElementById('menuButton');
const navLinks = this.shadowRoot.getElementById('navLinks');
menuButton.addEventListener('click', () => {
navLinks.classList.toggle('active');
});
}
}
customElements.define('custom-header', CustomHeader);