/* * ==================== БЛОК СТАТИСТИКИ (STATS SECTION) ==================== */

/* * Секция статистики */
.stats-section {
    padding: clamp(24px, 4vw, 48px) 0;
    background: linear-gradient(180deg, #17141E 0%, #120f18 100%);
    position: relative;
    overflow: hidden;
}

/* * Контейнер сетки статистики */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(clamp(320px, 42vw, 500px), 1fr));
    gap: clamp(20px, 3.5vw, 32px);
    margin: 0 auto;
    max-width: 1100px;
}

/* * Карточка статистики */
.stat-card {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: clamp(20px, 3.5vw, 28px);
    align-items: center;
    
    padding: clamp(22px, 4vw, 32px);
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    border-radius: clamp(14px, 2vw, 18px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    
    position: relative;
    overflow: hidden;
    
    transform: translateY(0);
    transition: all 300ms cubic-bezier(0.2, 0.8, 0.2, 1);
    cursor: default;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

/* * Иконка статистики */
.stat-icon {
    width: clamp(64px, 10vw, 84px);
    height: clamp(64px, 10vw, 84px);
    display: flex;
    align-items: center;
    justify-content: center;
    
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border-radius: clamp(12px, 1.8vw, 16px);
    box-shadow: 0 6px 18px rgba(99, 102, 241, 0.35);
    
    position: relative;
    z-index: 2;
}

.stat-card-channels .stat-icon {
    background: linear-gradient(135deg, #10b981 0%, #34d399 100%);
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.35);
}

.icon-svg {
    width: clamp(34px, 6vw, 44px);
    height: clamp(34px, 6vw, 44px);
    color: #ffffff;
}

/* * Контент статистики */
.stat-content {
    display: flex;
    flex-direction: column;
    gap: clamp(3px, 0.7vw, 6px);
    min-width: 0;
    justify-content: center;
}

/* * Значение статистики (анимированное число) */
.stat-value {
    font-size: clamp(2rem, 5.5vw, 2.75rem);
    font-weight: 700;
    line-height: 1.15;
    color: #ffffff;
    font-family: 'Roboto Mono', monospace;
    letter-spacing: -0.02em;
}

/* * Метка статистики */
.stat-label {
    font-size: clamp(0.85rem, 1.9vw, 1rem);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.88);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.2;
}

/* * Описание статистики */
.stat-description {
    font-size: clamp(0.75rem, 1.5vw, 0.85rem);
    color: rgba(255, 255, 255, 0.58);
    line-height: 1.35;
}

/* * Эффект свечения */
.stat-glow {
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    opacity: 0.3;
    filter: blur(60px);
    pointer-events: none;
    z-index: 0;
    
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    
    transition: opacity 300ms ease;
}

.stat-card:hover .stat-glow {
    opacity: 0.5;
}

.stat-glow-primary {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.stat-glow-accent {
    background: linear-gradient(135deg, #10b981 0%, #34d399 100%);
}

/* * Анимация появления карточек */
.stat-card {
    animation: statCardFadeIn 600ms cubic-bezier(0.34, 1.56, 0.64, 1) backwards;
}

.stat-card:nth-child(1) {
    animation-delay: 100ms;
}

.stat-card:nth-child(2) {
    animation-delay: 200ms;
}

@keyframes statCardFadeIn {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* * ==================== ТЁМНАЯ ТЕМА ==================== */

[data-theme="dark"] .stats-section {
    background: linear-gradient(180deg, #17141E 0%, #0f0d14 50%, #0a080e 100%);
}

[data-theme="dark"] .stat-card {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .stat-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
}

/* * ==================== АДАПТИВНОСТЬ БЕЗ МЕДИА-ЗАПРОСОВ ==================== */

/* * Для очень узких экранов стек компоновка */
@container (max-width: 320px) {
    .stat-card {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .stat-icon {
        margin: 0 auto;
    }
}

/* * Для широких экранов - максимальная ширина контента */
.stats-section .main_container {
    max-width: min(1200px, 95vw);
}

/* * Accessibility: motion preferences */
@media (prefers-reduced-motion: reduce) {
    .stat-card,
    .stat-card:hover,
    .stat-glow {
        animation: none !important;
        transition-duration: 0.01ms !important;
    }
}
