// Demo Data for Cat Images const catImages = [ { id: 1, url: 'https://static.photos/cats/640x360/10', title: 'Regal Persian', category: 'realistic', likes: 234, author: 'CatLover99' }, { id: 2, url: 'https://static.photos/cats/640x360/11', title: 'Cyber Punk Kitty', category: 'anime', likes: 567, author: 'NeonArtist' }, { id: 3, url: 'https://static.photos/cats/640x360/12', title: 'Abstract Feline', category: 'artistic', likes: 123, author: 'ArtMaster' }, { id: 4, url: 'https://static.photos/cats/640x360/13', title: '3D Render Cat', category: '3d', likes: 890, author: 'RenderPro' }, { id: 5, url: 'https://static.photos/cats/640x360/14', title: 'Vintage Tabby', category: 'vintage', likes: 456, author: 'RetroFan' }, { id: 6, url: 'https://static.photos/cats/640x360/15', title: 'Realistic Maine Coon', category: 'realistic', likes: 678, author: 'NaturePhotog' }, { id: 7, url: 'https://static.photos/cats/640x360/16', title: 'Chibi Cat', category: 'anime', likes: 789, author: 'KawaiiMaker' }, { id: 8, url: 'https://static.photos/cats/640x360/17', title: 'Oil Painting Style', category: 'artistic', likes: 345, author: 'PainterAI' }, ]; // Demo Data for Cat Videos const catVideos = [ { id: 1, thumbnail: 'https://static.photos/cats/640x360/20', title: 'Sleepy Cat Loop', category: 'loop', duration: '0:15', views: '2.3k' }, { id: 2, thumbnail: 'https://static.photos/cats/640x360/21', title: 'Epic Cat Jump', category: 'cinematic', duration: '0:08', views: '5.1k' }, { id: 3, thumbnail: 'https://static.photos/cats/640x360/22', title: 'Cartoon Cat Dance', category: 'animation', duration: '0:12', views: '1.8k' }, { id: 4, thumbnail: 'https://static.photos/cats/640x360/23', title: 'Slow Blink', category: 'slowmo', duration: '0:20', views: '3.4k' }, { id: 5, thumbnail: 'https://static.photos/cats/640x360/24', title: 'Playful Kitten', category: 'cinematic', duration: '0:25', views: '4.2k' }, { id: 6, thumbnail: 'https://static.photos/cats/640x360/25', title: 'Floating Cat', category: 'animation', duration: '0:10', views: '2.9k' }, { id: 7, thumbnail: 'https://static.photos/cats/640x360/26', title: 'Pounce in Slow Mo', category: 'slowmo', duration: '0:30', views: '6.7k' }, { id: 8, thumbnail: 'https://static.photos/cats/640x360/27', title: 'Endless Purring', category: 'loop', duration: '0:08', views: '1.2k' }, ]; // Initialize Sidebar Toggle function toggleSidebar() { const sidebar = document.getElementById('sidebar'); const overlay = document.getElementById('mobile-overlay'); if (sidebar.classList.contains('-translate-x-full')) { sidebar.classList.remove('-translate-x-full'); overlay.classList.remove('hidden'); } else { sidebar.classList.add('-translate-x-full'); overlay.classList.add('hidden'); } } // Render Image Cards function renderImages(filter = 'all') { const grid = document.getElementById('image-grid'); grid.innerHTML = ''; const filtered = filter === 'all' ? catImages : catImages.filter(img => img.category === filter); filtered.forEach(img => { const card = document.createElement('div'); card.className = 'card-hover bg-white rounded-xl overflow-hidden border border-slate-200 group cursor-pointer'; card.innerHTML = `