or('Failed to load analytics data:', error);
                showErrorState();
            }
        }
        
        function populateMetrics() {
            const metricsGrid = document.getElementById('metricsGrid');
            const totalComponents = Object.keys(statsData.downloads_by_component).length;
            const todayDate = new Date().toISOString().split('T')[0];
            const todayDownloads = statsData.downloads_by_date[todayDate] || 0;
            
            const metrics = [
        