// Bonkers mode functionality function initBonkersMode() { // Check if we're in bonkers mode const currentMode = document.documentElement.getAttribute('data-website-mode'); if (currentMode === 'bonkers') { // Apply bonkers mode immediately document.body.classList.add('bonkers-mode'); // Start the fabulous effects createExtraSparkles(); createSlayEffects(); console.log('๐ŸŒˆโœจ Bonkers mode activated! โœจ๐ŸŒˆ'); } else { // Remove bonkers mode if it was active document.body.classList.remove('bonkers-mode'); } } // Function to create extra sparkles during bonkers mode function createExtraSparkles() { const currentMode = document.documentElement.getAttribute('data-website-mode'); if (currentMode !== 'bonkers') return; const extraEmojis = [ '๐Ÿ’ซ', 'โญ', '๐ŸŽŠ', '๐ŸŽˆ', '๐ŸŽช', '๐ŸŽญ', '๐ŸŽจ', '๐Ÿ‘‘', '๐Ÿ’Ž', '๐Ÿ”ฅ', 'โšก', '๐Ÿ’ƒ', '๐Ÿ•บ', '๐ŸŽต', '๐ŸŽถ', '๐ŸŽค', '๐Ÿ‘', '๐Ÿ’ฆ', '๐Ÿ˜', '๐Ÿ˜ˆ', '๐Ÿ‘…', '๐Ÿ’‹', '๐Ÿฅต', '๐Ÿ˜ณ', '๐Ÿคค', '๐Ÿ˜', '๐Ÿฅด', '๐Ÿคฏ', '๐Ÿ’•', '๐Ÿ’–', '๐Ÿ’—', '๐Ÿ’˜', '๐Ÿ’', '๐Ÿ’ž', '๐Ÿ’Ÿ', '๐Ÿ’Œ', '๐Ÿ’', '๐Ÿ’Ž', '๐Ÿ’', '๐Ÿ’‘', '๐Ÿ’’', '๐Ÿ’“', '๐Ÿ’”', '๐Ÿ’•', '๐ŸŒถ๏ธ', '๐Ÿ†', '๐Ÿฅ’', '๐ŸŒ', '๐ŸŽ', '๐Ÿ“', '๐Ÿ‡', '๐ŸŠ', '๐Ÿ‹', '๐ŸŒ', '๐Ÿ', '๐Ÿฅญ', '๐ŸŽ', '๐Ÿ', '๐Ÿ', '๐Ÿ’ง', '๐Ÿ’ฆ', '๐Ÿ’จ', '๐Ÿ‘€', '๐Ÿ˜‰', '๐Ÿ˜Œ', '๐Ÿ˜', '๐Ÿฅฐ', '๐Ÿ˜˜', '๐Ÿ˜š', '๐Ÿ˜‹', '๐Ÿฅณ', '๐Ÿ˜', '๐Ÿ˜ซ', '๐Ÿ˜ฉ', '๐Ÿฅบ', '๐Ÿ˜ข', '๐Ÿ˜ก', '๐Ÿคฌ', '๐Ÿคฏ', '๐Ÿ˜ณ', '๐Ÿฅต', '๐Ÿฅด', '๐Ÿค’', '๐Ÿ’–', '๐Ÿ’—', '๐Ÿ’™', '๐Ÿ’š', 'โค๏ธ', '๐Ÿงก', '๐Ÿ’›', '๐Ÿ’œ', '๐Ÿ–ค', '๐Ÿ’”', 'โฃ๏ธ', '๐Ÿ’•', '๐Ÿ’ž', '๐Ÿ’“', '๐Ÿ’—', '๐Ÿ’–', '๐Ÿ’˜', '๐Ÿ’', '๐Ÿ’Ÿ', '๐Ÿ’Œ', '๐Ÿ’‹', '๐Ÿ’', '๐Ÿ’Ž', '๐Ÿ’', '๐Ÿ’‘', '๐Ÿ’’', '๐Ÿ’“', '๐Ÿ’”', '๐Ÿ’•', '๐Ÿ’–', '๐Ÿ’—', '๐Ÿ’˜' ]; const sparkle = document.createElement('div'); sparkle.className = 'emoji-footprint'; sparkle.textContent = extraEmojis[Math.floor(Math.random() * extraEmojis.length)]; sparkle.style.left = Math.random() * window.innerWidth + 'px'; sparkle.style.top = Math.random() * window.innerHeight + 'px'; document.body.appendChild(sparkle); setTimeout(() => { if (sparkle.parentNode) { sparkle.remove(); } }, 3000); // Continue creating extra sparkles while in bonkers mode const newMode = document.documentElement.getAttribute('data-website-mode'); if (newMode === 'bonkers') { setTimeout(() => createExtraSparkles(), 150); } } // Function to create slay effects function createSlayEffects() { const currentMode = document.documentElement.getAttribute('data-website-mode'); if (currentMode !== 'bonkers') return; // Create floating "SLAY" text effects const slayWords = [ 'SLAY', 'QUEEN', 'FABULOUS', 'ICONIC', 'LEGENDARY', 'STUNNING', 'GORGEOUS', 'FLAWLESS', 'DAZZLING', 'RADIANT', 'BREATHTAKING', 'EXQUISITE', 'DIVINE' ]; const slayElement = document.createElement('div'); slayElement.className = 'slay-text'; slayElement.textContent = slayWords[Math.floor(Math.random() * slayWords.length)]; slayElement.style.left = Math.random() * window.innerWidth + 'px'; slayElement.style.top = Math.random() * window.innerHeight + 'px'; document.body.appendChild(slayElement); setTimeout(() => { if (slayElement.parentNode) { slayElement.remove(); } }, 3000); // Continue creating slay effects while in bonkers mode const newMode = document.documentElement.getAttribute('data-website-mode'); if (newMode === 'bonkers') { setTimeout(() => createSlayEffects(), 800); } } // Watch for mode changes function watchModeChanges() { // Create a MutationObserver to watch for changes to the data-website-mode attribute const observer = new MutationObserver(function(mutations) { mutations.forEach(function(mutation) { if (mutation.type === 'attributes' && mutation.attributeName === 'data-website-mode') { const newMode = document.documentElement.getAttribute('data-website-mode'); if (newMode === 'bonkers') { document.body.classList.add('bonkers-mode'); // Start the fabulous effects createExtraSparkles(); createSlayEffects(); console.log('๐ŸŒˆโœจ Switched to bonkers mode! โœจ๐ŸŒˆ'); } else { document.body.classList.remove('bonkers-mode'); console.log(`๐Ÿ˜ด Switched to ${newMode} mode`); } } }); }); // Start observing observer.observe(document.documentElement, { attributes: true, attributeFilter: ['data-website-mode'] }); } // Initialize when DOM is loaded document.addEventListener('DOMContentLoaded', function() { initBonkersMode(); watchModeChanges(); }); export { initBonkersMode, watchModeChanges };