// Main application controller class App { constructor() { this.currentSection = 'overview'; this.init(); } init() { this.setupNavigation(); this.updateSliderValues(); } setupNavigation() { const navLinks = document.querySelectorAll('.nav-link'); navLinks.forEach(link => { link.addEventListener('click', (e) => { e.preventDefault(); const section = link.dataset.section; this.navigateTo(section); }); }); } navigateTo(section) { // Update nav links document.querySelectorAll('.nav-link').forEach(link => { link.classList.remove('active'); if (link.dataset.section === section) { link.classList.add('active'); } }); // Update sections document.querySelectorAll('.section').forEach(sec => { sec.classList.remove('active'); }); document.getElementById(section).classList.add('active'); this.currentSection = section; } updateSliderValues() { const quantumInfluence = document.getElementById('quantum-influence'); const entanglementDepth = document.getElementById('entanglement-depth'); if (quantumInfluence) { quantumInfluence.addEventListener('input', (e) => { document.getElementById('quantum-influence-val').textContent = e.target.value; }); } if (entanglementDepth) { entanglementDepth.addEventListener('input', (e) => { document.getElementById('entanglement-val').textContent = e.target.value; }); } } } // Initialize app const app = new App();