-Tag) ================================================== */ (function() { function initKontextSection() { var section = document.getElementById('kontext'); if (!section) return; var sources = section.querySelectorAll('.kontext-source-tile'); var hubRing = document.getElementById('kontext-hub-ring'); var results = section.querySelectorAll('.kontext-result-tile'); var io = new IntersectionObserver(function(entries) { entries.forEach(function(entry) { if (!entry.isIntersecting) return; // Quellen animieren sources.forEach(function(tile, i) { setTimeout(function() { tile.classList.add('active'); }, i * 150); }); // Hub pulsieren setTimeout(function() { if (hubRing) hubRing.classList.add('pulsing'); }, sources.length * 150 + 100); // Ergebnisse einblenden results.forEach(function(tile) { var delay = parseInt(tile.dataset.delay || '0', 10); setTimeout(function() { tile.classList.add('visible'); }, sources.length * 150 + 200 + delay); }); io.unobserve(entry.target); }); }, { threshold: 0.25 }); io.observe(section); } if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', initKontextSection); } else { initKontextSection(); } })();