/* Стили для панели управления */

/* Статичный пастельный градиент для дашборда */
body {
    background: linear-gradient(135deg, 
        #f8fafc 0%, 
        #f1f5f9 15%, 
        #e2e8f0 30%, 
        #cbd5e1 45%, 
        #94a3b8 60%, 
        #64748b 75%, 
        #475569 90%, 
        #334155 100%);
    background-attachment: fixed;
    background-size: 100% 100%;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

.dashboard-container {
    min-height: 100vh;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* Заголовок панели */
.dashboard-header {
    margin-bottom: 40px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    padding: 25px 30px;
    box-shadow: var(--shadow-light);
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-icon {
    font-size: 2rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.welcome-text {
    color: #1D1D1F;
    font-size: 1rem;
    font-weight: 500;
    margin: 0;
    display: flex;
    align-items: center;
    min-height: 50px;
}

.header-actions {
    display: flex;
    gap: 15px;
}

.logout-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 24px;
    background: linear-gradient(135deg, rgba(255, 59, 48, 0.15) 0%, rgba(255, 95, 87, 0.1) 100%);
    border: 2px solid rgba(255, 59, 48, 0.3);
    border-radius: 16px;
    color: #FF3B30;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(255, 59, 48, 0.1);
}

.logout-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.logout-btn:hover::before {
    left: 100%;
}

.logout-btn:hover {
    background: linear-gradient(135deg, rgba(255, 59, 48, 0.25) 0%, rgba(255, 95, 87, 0.2) 100%);
    border-color: rgba(255, 59, 48, 0.5);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 30px rgba(255, 59, 48, 0.3);
    color: #FF1A0A;
}

.logout-btn:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 0 4px 15px rgba(255, 59, 48, 0.4);
}

.btn-icon {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
    display: inline-block;
}

.logout-btn:hover .btn-icon {
    transform: rotate(90deg) scale(1.1);
}

/* Основной контент */
.dashboard-main {
    max-width: 1200px;
    margin: 0 auto;
}

/* Сетка модулей */
.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.module-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    padding: 25px;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-light);
}

.module-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
}

.module-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
    background: rgba(255, 255, 255, 0.3);
}

.module-icon {
    font-size: 2.5rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    flex-shrink: 0;
}

.module-content {
    flex: 1;
}

.module-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.module-description {
    font-size: 0.9rem;
    color: #1D1D1F;
    line-height: 1.4;
    margin: 0 0 8px 0;
}

.submodules-count {
    margin-top: 8px;
}

.submodules-badge {
    display: inline-block;
    background: rgba(0, 122, 255, 0.1);
    color: var(--primary-color);
    font-size: 0.75rem;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid rgba(0, 122, 255, 0.2);
}

.module-arrow {
    font-size: 1.5rem;
    color: var(--primary-color);
    opacity: 0.7;
    transition: var(--transition);
    flex-shrink: 0;
}

.module-card:hover .module-arrow {
    opacity: 1;
    transform: translateX(5px);
}

/* Секция статистики */
.stats-section {
    margin-top: 40px;
}

.stats-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: var(--shadow-light);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 20px;
    text-align: left;
}

.stat-icon {
    font-size: 2rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Стили для раздела клинических рекомендаций */
.klinerc-section {
    margin-bottom: 40px;
}

.section-header {
    text-align: center;
    margin-bottom: 30px;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: #1D1D1F;
    margin: 0 0 8px 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.section-subtitle {
    font-size: 1.1rem;
    color: #6E6E73;
    margin: 0;
    font-weight: 400;
}

.klinerc-card {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 30px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-light);
    position: relative;
    overflow: hidden;
}

.klinerc-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.4) 50%, 
        transparent 100%);
}

.klinerc-card:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: var(--shadow-medium);
}

.klinerc-icon {
    font-size: 3rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    flex-shrink: 0;
}

.klinerc-content {
    flex: 1;
    min-width: 0;
}

.klinerc-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px 0;
    line-height: 1.3;
}

.klinerc-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0 0 16px 0;
    line-height: 1.5;
}

.klinerc-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.klinerc-features .feature-tag {
    padding: 6px 12px;
    background: rgba(0, 122, 255, 0.1);
    color: #007AFF;
    border: 1px solid rgba(0, 122, 255, 0.2);
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.klinerc-arrow {
    font-size: 1.8rem;
    color: #007AFF;
    font-weight: 300;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.klinerc-card:hover .klinerc-arrow {
    transform: translateX(6px);
}

/* Адаптивность */
@media (max-width: 768px) {
    .dashboard-container {
        padding: 15px;
    }
    
    .header-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    .logo-section {
        flex-direction: column;
        gap: 10px;
    }
    
    .modules-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .module-card {
        padding: 20px;
    }
    
    .stats-card {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 20px;
    }
    
    .stat-item {
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .module-card {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .module-arrow {
        transform: rotate(90deg);
    }
    
    .module-card:hover .module-arrow {
        transform: rotate(90deg) translateY(-5px);
    }
}

/* Анимации загрузки */
.module-card {
    animation: slideUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.module-card:nth-child(1) { animation-delay: 0.1s; }
.module-card:nth-child(2) { animation-delay: 0.2s; }
.module-card:nth-child(3) { animation-delay: 0.3s; }
.module-card:nth-child(4) { animation-delay: 0.4s; }
.module-card:nth-child(5) { animation-delay: 0.5s; }

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Эффекты при наведении */
.module-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.module-card:hover::after {
    left: 100%;
}

/* Analysis Card Styles */
.analysis-card {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(37, 99, 235, 0.05));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 2px solid rgba(59, 130, 246, 0.2);
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
    overflow: hidden;
}

.analysis-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.analysis-card:hover {
    transform: translateY(-5px) scale(1.02);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.2);
}

.analysis-card:hover::before {
    left: 100%;
}

.analysis-icon {
    font-size: 3rem;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    flex-shrink: 0;
}

.analysis-content {
    flex: 1;
}

.analysis-title {
    color: #0a2540;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 10px 0;
    line-height: 1.2;
}

.analysis-description {
    color: #6b7280;
    font-size: 1rem;
    margin: 0 0 15px 0;
    line-height: 1.5;
}

.analysis-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.feature-tag {
    background: rgba(59, 130, 246, 0.1);
    color: #1d4ed8;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.analysis-arrow {
    font-size: 1.5rem;
    color: #3b82f6;
    font-weight: bold;
    transition: transform 0.3s ease;
}

.analysis-card:hover .analysis-arrow {
    transform: translateX(5px);
}

/* Responsive Design for Analysis Card */
@media (max-width: 768px) {
    .analysis-card {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
    
    .analysis-icon {
        font-size: 2.5rem;
    }
    
    .analysis-title {
        font-size: 1.3rem;
    }
    
    .analysis-features {
        justify-content: center;
    }
    
    .analysis-arrow {
        display: none;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .klinerc-card {
        padding: 24px;
        gap: 20px;
    }
    
    .klinerc-icon {
        font-size: 2.5rem;
    }
    
    .klinerc-title {
        font-size: 1.3rem;
    }
    
    .klinerc-description {
        font-size: 0.95rem;
    }
    
    .klinerc-features {
        gap: 6px;
    }
    
    .klinerc-features .feature-tag {
        padding: 5px 10px;
        font-size: 0.8rem;
    }
}

/* User Info Styles */
.user-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.welcome-text {
    color: #1D1D1F;
    font-size: 1.1rem;
    font-weight: 500;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.account-icon {
    background: linear-gradient(135deg, #007AFF, #5856D6);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: white;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
    transition: all 0.3s ease;
}

.account-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 122, 255, 0.4);
}

.datetime-info {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 8px 16px;
    color: #1D1D1F;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
    min-width: 200px;
}
/* ===================================================================
   НОВЫЙ КОМПАКТНЫЙ HEADER С ВИДЖЕТАМИ GLASSMORPHISM iOS 26
   ================================================================ */

/* Основной header - прозрачный и компактный */
.dashboard-header-new {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    margin-bottom: 30px;
    background: transparent;
    position: relative;
    z-index: 100;
}

/* Контейнер для виджетов */
.header-widgets {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* Общий стиль для виджетов */
.header-widget {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    
    /* Glassmorphism iOS 26 */
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: default;
}

.header-widget:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.35);
    /* transform: translateY(-2px); */  /* Анимация убрана */
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* Иконка виджета */
/* Круглые иконки в стиле iOS26 */
.widget-icon {
    font-size: 18px;
    line-height: 1;
    
    /* Круглый контейнер */
    width: 36px;
    height: 36px;
    border-radius: 50%; /* Круг */
    
    display: flex;
    align-items: center;
    justify-content: center;
    
    /* Glassmorphism iOS26 */
    background: linear-gradient(135deg,
        rgba(255, 255, 255, 0.4) 0%,
        rgba(255, 255, 255, 0.2) 100%
    );
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    
    /* Тени для глубины */
    box-shadow: 
        0 4px 16px rgba(0, 0, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    
    /* Плавные переходы */
    transition: all 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
}

/* Hover эффект для иконок */
.header-widget:hover .widget-icon {
    background: linear-gradient(135deg,
        rgba(255, 255, 255, 0.5) 0%,
        rgba(255, 255, 255, 0.3) 100%
    );
    box-shadow: 
        0 6px 24px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
    transform: scale(1.05);
}

/* Специфичные цвета для разных иконок */
.welcome-widget .widget-icon {
    /* Синий оттенок для иконки пользователя */
    background: linear-gradient(135deg,
        rgba(0, 122, 255, 0.15) 0%,
        rgba(10, 132, 255, 0.08) 100%
    );
}

.info-widget .widget-icon {
    /* Зеленый оттенок для иконки календаря */
    background: linear-gradient(135deg,
        rgba(52, 199, 89, 0.15) 0%,
        rgba(48, 209, 88, 0.08) 100%
    );
}

.welcome-widget:hover .widget-icon {
    background: linear-gradient(135deg,
        rgba(0, 122, 255, 0.2) 0%,
        rgba(10, 132, 255, 0.12) 100%
    );
}

.info-widget:hover .widget-icon {
    background: linear-gradient(135deg,
        rgba(52, 199, 89, 0.2) 0%,
        rgba(48, 209, 88, 0.12) 100%
    );
}

/* Контент виджета */
.widget-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.widget-label {
    font-size: 11px;
    font-weight: 500;
    color: rgba(29, 29, 31, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.widget-value {
    font-size: 15px;
    font-weight: 600;
    color: rgba(29, 29, 31, 0.95);
    /* text-shadow removed */
}

.widget-version {
    font-size: 10px;
    font-weight: 500;
    color: rgba(29, 29, 31, 0.5);
    margin-top: 2px;
}

/* Виджет приветствия */
.welcome-widget {
    min-width: 220px;
}

/* Виджет информации */
.info-widget {
    min-width: 200px;
}

/* Кнопки действий */
.header-actions-new {
    display: flex;
    gap: 10px;
}

.action-btn-new {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    
    /* Узкий шрифт iOS26 */
    font-size: 15px;
    font-weight: 400; /* Обычный, не жирный */
    letter-spacing: -0.3px; /* Компактнее */
    
    /* Glassmorphism iOS26 */
    background: linear-gradient(135deg,
        rgba(255, 255, 255, 0.25) 0%,
        rgba(255, 255, 255, 0.15) 100%
    );
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 16px;
    
    color: rgba(29, 29, 31, 0.85);
    
    /* Тени для глубины iOS26 */
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    
    cursor: pointer;
    min-height: 44px; /* Одинаковая высота с виджетами */
    
    transition: all 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    
    /* Убираем стандартные стили кнопки */
    border: none;
    outline: none;
    text-decoration: none;
}



.action-btn-new:active {
    transform: scale(0.98);
    background: linear-gradient(135deg,
        rgba(255, 255, 255, 0.2) 0%,
        rgba(255, 255, 255, 0.1) 100%
    );
}

/* Иконка в кнопке */
.action-btn-new .btn-icon {
    font-size: 18px;
    line-height: 1;
    opacity: 0.8;
}

/* Текст в кнопке */
.action-btn-new .btn-text {
    font-weight: 400;
    letter-spacing: -0.3px;
}

/* Кнопка "Выйти" с красным акцентом */
.action-btn-new.logout-btn {
    color: rgba(255, 59, 48, 0.9);
}

.action-btn-new.logout-btn:hover {
    color: rgba(255, 59, 48, 1);
    background: linear-gradient(135deg,
        rgba(255, 59, 48, 0.08) 0%,
        rgba(255, 59, 48, 0.04) 100%
    );
}

/* Кнопка "Назад" */
.action-btn-new.back-btn {
    color: #000000;
}

.action-btn-new.back-btn:hover {
    color: #000000;
    background: linear-gradient(135deg,
        rgba(0, 122, 255, 0.08) 0%,
        rgba(0, 122, 255, 0.04) 100%
    );
}



.action-btn-new:active {
    transform: translateY(0);
    box-shadow: 
        0 4px 16px rgba(255, 59, 48, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.action-btn-new .btn-icon {
    font-size: 18px;
    line-height: 1;
}

.action-btn-new .btn-text {
    font-size: 14px;
}

/* Кнопка "Назад" для других страниц */
.action-btn-new.back-btn {
    background: rgba(0, 122, 255, 0.15);
    border-color: rgba(0, 122, 255, 0.3);
    color: #000000;
    box-shadow: 
        0 8px 32px rgba(0, 122, 255, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.action-btn-new.back-btn:hover {
    background: rgba(0, 122, 255, 0.25);
    border-color: rgba(0, 122, 255, 0.4);
    box-shadow: 
        0 12px 40px rgba(0, 122, 255, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Адаптивность для планшетов */
@media (max-width: 1024px) {
    .dashboard-header-new {
        padding: 12px 0;
        margin-bottom: 25px;
    }
    
    .header-widgets {
        gap: 12px;
    }
    
    .header-widget {
        padding: 10px 15px;
    }
    
        .widget-icon {
        font-size: 16px;
        width: 32px;
        height: 32px;
    }
    
    .welcome-widget {
        min-width: 180px;
    }
    
    .info-widget {
        min-width: 160px;
    }
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .dashboard-header-new {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
        padding: 10px 0;
        margin-bottom: 20px;
    }
    
    .header-widgets {
        flex-direction: row !important;
        gap: 8px !important;
        justify-content: flex-end;
        flex-wrap: nowrap;
    }
    
    .header-widget {
        width: auto !important;
        min-width: unset !important;
        flex: 1;
        padding: 10px 12px !important;
    }
    
    .header-widget .widget-icon {
        font-size: 18px !important;
    }
    
    .header-widget .widget-label {
        font-size: 9px !important;
    }
    
    .header-widget .widget-value {
        font-size: 12px !important;
    }
    
    .header-widget .widget-date {
        font-size: 10px !important;
    }
    
    .header-widget .widget-time {
        font-size: 11px !important;
    }
    
    .header-actions-new {
        width: 100%;
    }
    
    .action-btn-new {
        width: 100%;
        justify-content: center;
    }
}

/* Скрываем старый header если есть новый */
.dashboard-header-new ~ .dashboard-header {
    display: none;
}

/* Обновление для старых элементов, если они используются */
.dashboard-header {
    margin-bottom: 30px;
}

.header-content {
    display: none; /* Скрываем если есть новый header */
}

/* Анимация появления виджетов - ОТКЛЮЧЕНА */
/* @keyframes widgetFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
} */

.header-widget {
    /* animation: widgetFadeIn 0.4s ease-out; */
    opacity: 1;
    transform: translateY(0);
}

.header-widget:nth-child(1) {
    /* animation-delay: 0.1s; */
}

.header-widget:nth-child(2) {
    /* animation-delay: 0.2s; */
}

.action-btn-new {
    /* animation: widgetFadeIn 0.4s ease-out 0.3s both; */
    opacity: 1;
    transform: translateY(0);
}


/* Обновленные стили для виджета даты и времени */
.widget-date {
    font-size: 13px;
    font-weight: 500;
    color: rgba(29, 29, 31, 0.95);
    text-transform: none;
    letter-spacing: normal;
    line-height: 1.4;
}

.widget-time {
    font-size: 14px;
    font-weight: 600;
    color: rgba(29, 29, 31, 0.95);
    text-transform: none;
    letter-spacing: normal;
    line-height: 1.4;
}

/* Убираем uppercase с widget-label */
.widget-label {
    font-size: 11px;
    font-weight: 500;
    color: rgba(29, 29, 31, 0.95);
    text-transform: none;
    letter-spacing: normal;
}

/* Скрываем старую версию если осталась */
.widget-version {
    display: none;
}



/* ============================================================================
   ACCORDION STYLES - Glassmorphism iOS26
   ============================================================================ */

.accordion-section {
    margin-bottom: 16px;
}

.accordion-header {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    padding: 20px 24px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
    position: relative;
    overflow: hidden;
}

.accordion-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.08) 0%,
        rgba(255, 255, 255, 0.02) 100%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.accordion-header:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.accordion-header:hover::before {
    opacity: 1;
}

.accordion-header.active {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 12px 48px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.accordion-header-content {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
}

.accordion-icon {
    font-size: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
}

.accordion-title-group {
    flex: 1;
}

.accordion-title {
    font-size: 20px;
    font-weight: 600;
    color: rgba(29, 29, 31, 0.95);
    margin: 0 0 4px 0;
}

.accordion-subtitle {
    font-size: 14px;
    color: rgba(29, 29, 31, 0.6);
    margin: 0;
}


.accordion-arrow {
    font-size: 20px;
    font-weight: 600;
    color: rgba(29, 29, 31, 0.8);
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    
    /* Glassmorphism iOS26 style */
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: saturate(180%) blur(10px);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.04),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.accordion-arrow:hover {
    background: rgba(255, 255, 255, 0.5);
    border-color: rgba(255, 255, 255, 0.4);
}

.accordion-header.active .accordion-arrow {
    transform: rotate(180deg);
    background: rgba(255, 255, 255, 0.5);
}


.accordion-content {
    /* Hardware acceleration */
    transform: translateZ(0);
    will-change: transform, opacity;
    
    /* Layout optimization */
    contain: layout style paint;
    
    /* Animation properties */
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    padding: 0 24px;
    
    /* Ultra-fast transition with GPU acceleration */
    transition: max-height 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.12s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                padding 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.accordion-content.active {
    max-height: 2000px;
    opacity: 1;
    padding: 20px 24px 24px 24px;
    transform: translateZ(0) scale(1);
}

.accordion-submodules {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.accordion-submodule-card {
    /* Hardware acceleration */
    transform: translateZ(0);
    will-change: transform, box-shadow;
    
    background: rgba(255, 255, 255, 0.6);
    
    /* Reduced blur for performance */
    backdrop-filter: saturate(180%) blur(8px);
    -webkit-backdrop-filter: saturate(180%) blur(8px);
    
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    padding: 16px;
    cursor: pointer;
    
    /* Optimized transition */
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                background 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Фиксированная минимальная высота для одинакового размера */
    min-height: 120px;
    display: flex;
    flex-direction: column;
}

.accordion-submodule-card:hover {
    background: rgba(255, 255, 255, 0.75);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

.accordion-submodule-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    justify-content: space-between;
}

.accordion-submodule-icon {
    font-size: 24px;
}

.accordion-submodule-title {
    font-size: 16px;
    font-weight: 600;
    color: rgba(29, 29, 31, 0.95);
    margin: 0;
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.development-badge {
    display: inline-block;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: white;
    font-size: 10px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
    white-space: nowrap;
    margin-left: 4px;
}

.accordion-submodule-description {
    font-size: 14px;
    color: rgba(29, 29, 31, 0.7);
    margin: 0;
    line-height: 1.4;
    flex: 1;
    display: flex;
    align-items: flex-start;
}


/* ============================================================================
   APPLE-STYLE ANIMATED ICONS
   ============================================================================ */

.top-card-icon-compact {
    font-size: 40px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 16px;
    
    /* Glassmorphism background */
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.3) 0%,
        rgba(255, 255, 255, 0.1) 100%
    );
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    
    transition: all 0.4s cubic-bezier(0.4, 0.0, 0.2, 1);
}

/* Пульсирующий эффект для иконки */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 
            0 8px 32px rgba(0, 0, 0, 0.06),
            inset 0 1px 0 rgba(255, 255, 255, 0.4),
            0 0 0 0 rgba(0, 122, 255, 0);
    }
    50% {
        box-shadow: 
            0 8px 32px rgba(0, 0, 0, 0.06),
            inset 0 1px 0 rgba(255, 255, 255, 0.4),
            0 0 20px 4px rgba(0, 122, 255, 0.15);
    }
}

/* Анимация "дыхания" */
@keyframes breathe {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Анимация вращения */
@keyframes gentle-rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Анимация покачивания */
@keyframes gentle-shake {
    0%, 100% {
        transform: rotate(0deg);
    }
    25% {
        transform: rotate(-5deg);
    }
    75% {
        transform: rotate(5deg);
    }
}

/* Специфичные стили для иконки анализов (📊) */
.analysis-icon {
    animation: breathe 3s ease-in-out infinite;
}

.analysis-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 16px;
    background: linear-gradient(135deg, 
        rgba(0, 122, 255, 0.1) 0%,
        rgba(10, 132, 255, 0.05) 100%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
}

/* Специфичные стили для иконки рекомендаций (📚) */
.recommendations-icon {
    animation: breathe 3.5s ease-in-out infinite;
    animation-delay: 0.5s;
}

.recommendations-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 16px;
    background: linear-gradient(135deg, 
        rgba(255, 59, 48, 0.1) 0%,
        rgba(255, 149, 0, 0.05) 100%
    );
    opacity: 0;
    transition: opacity 0.4s ease;
}

/* Hover эффекты для иконок */
.top-card-compact:hover .top-card-icon-compact {
    transform: translateY(-4px) scale(1.08);
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.4) 0%,
        rgba(255, 255, 255, 0.2) 100%
    );
    box-shadow: 
        0 16px 48px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.5),
        0 0 24px 8px rgba(0, 122, 255, 0.1);
}

.top-card-compact:hover .analysis-icon::before {
    opacity: 1;
    animation: pulse-glow 2s ease-in-out infinite;
}

.top-card-compact:hover .recommendations-icon::before {
    opacity: 1;
    animation: pulse-glow 2s ease-in-out infinite;
}

/* Анимация иконки при hover на карточку */
.top-card-compact:hover .analysis-icon {
    animation: breathe 3s ease-in-out infinite, gentle-shake 0.6s ease-in-out;
}

.top-card-compact:hover .recommendations-icon {
    animation: breathe 3.5s ease-in-out infinite, gentle-shake 0.6s ease-in-out;
    animation-delay: 0s, 0s;
}

/* Добавляем блеск при hover */
/* Shine ::after element removed
.top-card-icon-compact::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.3) 50%,
        transparent 70%
    );
    transform: rotate(45deg);
    opacity: 0;
    transition: opacity 0.4s ease;
}
*/

/* Shine on hover removed
.top-card-compact:hover .top-card-icon-compact::after {
    opacity: 1;
    animation: shine 1.5s ease-in-out;
}
*/

/* Shine animation removed
@keyframes shine {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
    }
}
*/

/* Улучшенные стили для текста иконок */
.top-card-icon-compact {
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
}

.top-card-compact:hover .top-card-icon-compact {
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15));
}

/* Адаптивность */
@media (max-width: 768px) {
    .top-card-icon-compact {
        width: 56px;
        height: 56px;
        font-size: 36px;
    }
}

/* Уменьшаем анимации для пользователей с prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
    .analysis-icon,
    .recommendations-icon {
        animation: none;
    }
    
    .top-card-compact:hover .top-card-icon-compact {
        transform: translateY(-2px) scale(1.02);
    }
    
    
}


/* Compact top section for analysis and recommendations */
.top-section-compact {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.top-card-compact {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.top-card-compact:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

.top-card-header-compact {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 12px;
}

.top-card-icon-compact {
    font-size: 40px;
}

.top-card-title-compact {
    font-size: 20px;
    font-weight: 600;
    color: rgba(29, 29, 31, 0.95);
    margin: 0;
}

.top-card-description-compact {
    font-size: 14px;
    color: rgba(29, 29, 31, 0.7);
    margin: 0 0 12px 0;
    line-height: 1.5;
}

.top-card-features-compact {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.feature-tag-compact {
    background: rgba(0, 122, 255, 0.1);
    color: rgba(0, 122, 255, 1);
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .accordion-header {
        padding: 16px;
    }
    
    .accordion-icon {
        font-size: 28px;
        width: 40px;
        height: 40px;
    }
    
    .accordion-title {
        font-size: 18px;
    }
    
    .accordion-subtitle {
        font-size: 13px;
    }
    
    .accordion-submodules {
        grid-template-columns: 1fr;
    }
    
    .top-section-compact {
        grid-template-columns: 1fr;
    }
}


/* ========================================
   Счетчик модулей в аккордеоне
   ======================================== */

.accordion-module-count {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 16px;
    margin-right: 12px;
    
    /* Glassmorphism iOS26 */
    background: linear-gradient(135deg,
        rgba(0, 122, 255, 0.1) 0%,
        rgba(0, 122, 255, 0.05) 100%
    );
    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    
    border: 1px solid rgba(0, 122, 255, 0.2);
    border-radius: 12px;
    
    box-shadow: 
        0 2px 8px rgba(0, 122, 255, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.accordion-header:hover .accordion-module-count {
    background: linear-gradient(135deg,
        rgba(0, 122, 255, 0.15) 0%,
        rgba(0, 122, 255, 0.08) 100%
    );
    border-color: rgba(0, 122, 255, 0.3);
    box-shadow: 
        0 4px 12px rgba(0, 122, 255, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.module-count-number {
    font-size: 20px;
    font-weight: 600;
    color: rgba(0, 122, 255, 0.95);
    line-height: 1;
    margin-bottom: 2px;
}

.module-count-label {
    font-size: 11px;
    font-weight: 500;
    color: rgba(0, 122, 255, 0.7);
    text-transform: lowercase;
    letter-spacing: 0.3px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .accordion-module-count {
        padding: 6px 12px;
        margin-right: 8px;
    }
    
    .module-count-number {
        font-size: 16px;
    }
    
    .module-count-label {
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .accordion-module-count {
        padding: 4px 10px;
        margin-right: 6px;
        flex-direction: row;
        gap: 4px;
    }
    
    .module-count-number {
        font-size: 14px;
        margin-bottom: 0;
    }
    
    .module-count-label {
        font-size: 9px;
    }
}

/* ========================================
   Performance Optimizations
   ======================================== */

/* Reduce repaints during scroll */
.accordion-section {
    contain: layout style paint;
    transform: translateZ(0);
}

/* Optimize accordion grid performance */
.accordion-submodules {
    contain: layout style;
    transform: translateZ(0);
}

/* Smooth scrolling with hardware acceleration */
.dashboard-container {
    -webkit-overflow-scrolling: touch;
    transform: translateZ(0);
}

/* Disable animations on low-performance devices */
@media (prefers-reduced-motion: reduce) {
    .accordion-content,
    .accordion-header,
    .accordion-submodule-card,
    .accordion-arrow {
        transition: none !important;
        animation: none !important;
    }
}

/* Performance optimization for multiple accordions */
.accordion-content:not(.active) {
    visibility: hidden;
    pointer-events: none;
}

.accordion-content.active {
    visibility: visible;
    pointer-events: auto;
}

.accordion-header {
    /* Hardware acceleration */
    transform: translateZ(0);
    will-change: transform;
    
    /* Faster hover transition */
    transition: transform 0.1s ease-out,
                background 0.1s ease-out,
                box-shadow 0.1s ease-out;
}

.accordion-submodule-card {
    /* Hardware acceleration for cards */
    transform: translateZ(0);
    will-change: transform, box-shadow;
    
    /* Faster hover transition */
    transition: transform 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                background 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Оптимизация для мобильных устройств */
@media (max-width: 768px) {
    .accordion-content {
        transition: max-height 0.12s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    opacity 0.1s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    padding 0.12s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }
}

/* Блок сообщения об ошибках в расчетах - iOS Glassmorphism */
.error-report-section {
    width: 100%;
    max-width: 1200px;
    margin: 40px auto 20px auto;
    padding: 20px 30px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.error-report-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(255, 255, 255, 0.05) 50%, 
        rgba(255, 255, 255, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.error-report-section:hover::before {
    opacity: 1;
}

.error-report-section:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.error-report-text {
    margin: 0;
    font-size: 16px;
    font-weight: 400;
    color: rgba(0, 0, 0, 0.85);
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

.error-report-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.error-report-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

@media (max-width: 768px) {
    .error-report-section {
        margin: 30px auto 15px auto;
        padding: 16px 20px;
    }
    
    .error-report-text {
        font-size: 14px;
    }
}
