SG
SteadyGlade Studio

Your Cart

Checkout

Thank you for your interest in the Masterclass. We’ll guide you through secure payment on the next step in a real environment. For now, this demo confirms your intent.

Read FAQ
`; const footerHTML = ` `; document.getElementById('site-header').innerHTML = headerHTML; document.getElementById('site-footer').innerHTML = footerHTML; initAllListeners(); } function initAllListeners() { // Theme const themeBtn = document.querySelector('[data-action="toggle-theme"]'); if (themeBtn) { themeBtn.addEventListener('click', () => { const isDark = document.documentElement.classList.toggle('dark'); localStorage.setItem('sg_theme', isDark ? 'dark' : 'light'); }); } // Mobile Menu const menuBtn = document.querySelector('[data-action="open-menu"]'); const mobileMenu = document.querySelector('[data-mobile-menu]'); if (menuBtn && mobileMenu) { menuBtn.addEventListener('click', () => { mobileMenu.classList.toggle('hidden'); }); } // Auth Modal const authBtn = document.querySelector('[data-action="open-auth"]'); const authModal = document.querySelector('dialog[data-auth-modal]') || createAuthModal(); if (authBtn && authModal) { authBtn.addEventListener('click', () => authModal.showModal()); } // Cookie banner initCookieBanner(); } function createAuthModal() { const dialog = document.createElement('dialog'); dialog.setAttribute('data-auth-modal', ''); dialog.className = 'rounded-2xl p-0 w-full max-w-lg backdrop:bg-black/50 backdrop:backdrop-blur-sm'; dialog.innerHTML = `
`; document.body.appendChild(dialog); // Tab logic const tabs = dialog.querySelectorAll('[data-auth-tab]'); const panels = dialog.querySelectorAll('[data-auth-panel]'); tabs.forEach(tab => { tab.addEventListener('click', () => { const target = tab.getAttribute('data-auth-tab'); tabs.forEach(t => t.classList.toggle('border-b-2', t === tab)); tabs.forEach(t => t.classList.toggle('border-orange-600', t === tab)); panels.forEach(p => p.classList.toggle('hidden', p.getAttribute('data-auth-panel') !== target)); }); }); dialog.querySelectorAll('[data-action="close-auth"]').forEach(b => b.addEventListener('click', () => dialog.close())); return dialog; } function initCookieBanner() { const banner = document.querySelector('[data-cookie-banner]'); if (!banner) return; if (!localStorage.getItem('sg-cookie-consent')) { banner.classList.remove('hidden'); } const accept = banner.querySelector('[data-action="accept-cookies"]'); const closeBtn = banner.querySelector('[data-action="close-cookies"]'); if (accept) accept.addEventListener('click', () => { localStorage.setItem('sg-cookie-consent', 'accepted'); banner.classList.add('hidden'); }); if (closeBtn) closeBtn.addEventListener('click', () => { localStorage.setItem('<|eos|>