document.addEventListener('DOMContentLoaded', function() { // Initialize animations const animateElements = document.querySelectorAll('.animate-fade-in'); animateElements.forEach((el, index) => { el.style.animationDelay = `${index * 0.1}s`; }); // Smooth scroll for anchor links document.querySelectorAll('a[href^="#"]').forEach(anchor => { anchor.addEventListener('click', function (e) { e.preventDefault(); document.querySelector(this.getAttribute('href')).scrollIntoView({ behavior: 'smooth' }); }); }); // Property card hover effect const propertyCards = document.querySelectorAll('.property-card-hover'); propertyCards.forEach(card => { card.addEventListener('mouseenter', () => { card.classList.add('shadow-xl'); }); card.addEventListener('mouseleave', () => { card.classList.remove('shadow-xl'); }); }); }); // Auth functions function togglePasswordVisibility(inputId) { const input = document.getElementById(inputId); const icon = document.querySelector(`[data-password="${inputId}"]`); if (input.type === 'password') { input.type = 'text'; icon.setAttribute('data-feather', 'eye-off'); } else { input.type = 'password'; icon.setAttribute('data-feather', 'eye'); } feather.replace(); } function handleAuthFormSubmit(type) { // In a real app, this would handle form submission console.log(`${type} form submitted`); document.querySelector('luxe-auth-modal').setAttribute('visible', 'false'); return false; // Prevent actual form submission for demo }