/* Базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Кнопки */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2980b9 0%, #2573a7 100%);
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.3);
}

.btn-secondary {
    background: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background: #7f8c8d;
    box-shadow: 0 5px 15px rgba(149, 165, 166, 0.3);
}

.btn-success {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, #27ae60 0%, #219653 100%);
    box-shadow: 0 5px 20px rgba(46, 204, 113, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #c0392b 0%, #a93226 100%);
    box-shadow: 0 5px 20px rgba(231, 76, 60, 0.3);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 14px;
}

.btn-large {
    padding: 16px 32px;
    font-size: 18px;
}

/* Карточки */
.card {
    background: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    border: 1px solid #eaeaea;
}

.card h2 {
    color: #2c3e50;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.5rem;
}

/* Формы */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #2c3e50;
    font-weight: 600;
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e6ed;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
    background: #f8fafc;
}

.form-control:focus {
    border-color: #3498db;
    outline: none;
    background: white;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-control:disabled {
    background: #f5f5f5;
    cursor: not-allowed;
    opacity: 0.7;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237f8c8d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 40px;
}

/* Уведомления */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-left: 4px solid transparent;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border-left-color: #28a745;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border-left-color: #dc3545;
}

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border-left-color: #ffc107;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
    border-left-color: #17a2b8;
}

/* Таблицы */
.table-container {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-bottom: 30px;
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
}

thead {
    background: #f8f9fa;
}

th {
    padding: 16px 20px;
    text-align: left;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #eaeaea;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

td {
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
    color: #555;
}

tbody tr:hover {
    background: #f8f9fa;
}

tbody tr:last-child td {
    border-bottom: none;
}

/* Пагинация */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 30px;
}

.page-item {
    list-style: none;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 2px solid #e0e6ed;
    border-radius: 8px;
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
}

.page-link:hover {
    background: #f8f9fa;
    border-color: #3498db;
}

.page-link.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.page-link.disabled {
    color: #bdc3c7;
    cursor: not-allowed;
    pointer-events: none;
}

/* Загрузка */
.loading {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Утилиты */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mt-5 { margin-top: 2.5rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-5 { margin-bottom: 2.5rem; }

/* Адаптивность */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .card {
        padding: 20px;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 15px;
    }
    
    .btn-large {
        padding: 14px 28px;
        font-size: 16px;
    }
    
    th, td {
        padding: 12px 15px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }
    
    .card {
        padding: 15px;
    }
    
    .btn {
        padding: 8px 16px;
        font-size: 14px;
    }
    
    th, td {
        padding: 10px 12px;
        font-size: 0.85rem;
    }
}

/* Уведомления */
.alert-message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    background: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 10px;
    transform: translateX(120%);
    transition: transform 0.3s ease;
    max-width: 400px;
}

.alert-message.show {
    transform: translateX(0);
}

.alert-success {
    border-left: 4px solid #27ae60;
    color: #155724;
    background-color: #d4edda !important;
}

.alert-error {
    border-left: 4px solid #e74c3c;
    color: #721c24;
    background-color: #f8d7da !important;
}

.alert-warning {
    border-left: 4px solid #f39c12;
    color: #856404;
    background-color: #fff3cd !important;
}

.alert-info {
    border-left: 4px solid #3498db;
    color: #0c5460;
    background-color: #d1ecf1 !important;
}

/* Скрытые элементы */
.hidden {
    display: none !important;
}

/* Отключенные элементы */
.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}
/* Улучшенные стили для вопросов */
.question-item {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    border: 2px solid #e0e0e0;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
}

.question-item:hover {
    border-color: #3498db;
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.1);
    transform: translateY(-2px);
}

.maturity-question {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    border: 2px solid #e0e0e0;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
}

.maturity-question:hover {
    border-color: #2ecc71;
    box-shadow: 0 5px 20px rgba(46, 204, 113, 0.1);
    transform: translateY(-2px);
}

/* Номера вопросов */
.question-number {
    position: absolute;
    top: -12px;
    left: 20px;
    background: #3498db;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
    box-shadow: 0 3px 8px rgba(52, 152, 219, 0.3);
}

.maturity-question .question-number {
    background: #2ecc71;
    box-shadow: 0 3px 8px rgba(46, 204, 113, 0.3);
}

.question-text {
    font-size: 1.1rem;
    color: #2c3e50;
    margin-bottom: 25px;
    line-height: 1.5;
    font-weight: 600;
    padding-top: 5px;
    padding-left: 40px;
    position: relative;
}

/* Подсветка выбранного варианта */
.option-label input:checked + .option-text {
    color: #2c3e50;
    font-weight: 600;
}

.option-label input:checked {
    accent-color: #3498db;
}

.option-label:has(input:checked) {
    border-color: #3498db;
    background: #e3f2fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.maturity-question .option-label:has(input:checked) {
    border-color: #2ecc71;
    background: #e8f6f3;
    box-shadow: 0 0 0 3px rgba(46, 204, 113, 0.1);
}

/* Улучшенные варианты ответов */
.option-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    background: white;
    min-height: 90px;
    justify-content: center;
}

.option-label:hover {
    border-color: #3498db;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.15);
}

.option-label input {
    margin-bottom: 12px;
    transform: scale(1.3);
    cursor: pointer;
}

.option-text {
    font-size: 0.95rem;
    color: #555;
    font-weight: 500;
    line-height: 1.4;
}

/* Уровни зрелости */
.maturity-level {
    margin-bottom: 15px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    border: 2px solid #e0e0e0;
}

.maturity-level-header {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.maturity-level-description {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
}

/* Новые стили для стажа */
.experience-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.experience-input-full {
    display: flex;
    align-items: center;
    gap: 15px;
}

.experience-input-full label {
    white-space: nowrap;
    font-weight: 600;
    color: #2c3e50;
}

.experience-example {
    font-size: 0.85rem;
    color: #7f8c8d;
    font-style: italic;
    margin-top: 5px;
    padding-left: 10px;
    border-left: 3px solid #3498db;
}

/* Секции */
.section-group {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4fd 100%);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    border: 2px solid #d6e4ff;
}

.section-group h3 {
    color: #2c3e50;
    padding-bottom: 15px;
    border-bottom: 3px solid #3498db;
    margin-bottom: 25px;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.category-header {
    background: linear-gradient(135deg, #e8f6f3 0%, #d1f2eb 100%);
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 25px;
    border: 2px solid #a3e4d7;
}

.category-header h4 {
    color: #2c3e50;
    margin: 0;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Подсказки при наведении */
.question-item[data-tooltip]::after,
.maturity-question[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 10px 15px;
    border-radius: 6px;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 100;
}

.question-item[data-tooltip]:hover::after,
.maturity-question[data-tooltip]:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-5px);
}

/* Прогресс в реальном времени */
.progress-indicator {
    position: fixed;
    top: 10px;
    right: 20px;
    background: white;
    padding: 10px 15px;
    border-radius: 20px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
    z-index: 1000;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 2px solid #3498db;
}

.progress-indicator i {
    color: #3498db;
}
/* Стили для валидации стажа */
input:invalid {
    border-color: #e74c3c !important;
    background: #fff5f5;
}

input:valid:not(:placeholder-shown) {
    border-color: #2ecc71 !important;
    background: #f8fff8;
}

.experience-hint {
    font-size: 0.85rem;
    color: #27ae60;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Сообщение об ошибке */
.error-message {
    color: #e74c3c;
    font-size: 0.85rem;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
}
.error-message {
    color: #e74c3c;
    font-size: 0.85rem;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
}

input:invalid {
    border-color: #e74c3c !important;
    background: #fff5f5;
}

input:valid:not(:placeholder-shown) {
    border-color: #2ecc71 !important;
    background: #f8fff8;
}

.chart-container {
  min-height: 300px;
  height: 300px;
  overflow: auto;
}

.stat-card {
  min-height: 120px;
}

.dashboard-section {
  background: white;
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}


.chart-container {
  min-height: 300px;
  background: #f8f9fa;
  border-radius: 8px;
  padding: 20px;
  margin-top: 10px;
}

.dashboard-section {
  background: white;
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  border: 1px solid #eaeaea;
}

.dashboard-section h3 {
  margin-top: 0;
  margin-bottom: 15px;
  color: #2c3e50;
  font-size: 1.2rem;
  font-weight: 600;
}
  
        .dashboard-container {
            max-width: 1400px;
            margin: 0 auto;
            padding: 20px;
            background: #f5f7fa;
            min-height: 100vh;
        }
        
        .admin-header {
            background: linear-gradient(135deg, var(--dark-color), #34495e);
            border-radius: 15px;
            padding: 25px 30px;
            margin-bottom: 30px;
            color: white;
            display: flex;
            justify-content: space-between;
            align-items: center;
            box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        }
        
        .admin-header h1 {
            margin: 0;
            font-size: 2rem;
            font-weight: 700;
            display: flex;
            align-items: center;
            gap: 15px;
        }
        
        .admin-header h1 i {
            color: var(--secondary-color);
            font-size: 2.2rem;
        }
        
        .admin-header p {
            margin: 10px 0 0 0;
            opacity: 0.9;
            font-size: 1rem;
        }
        
        .user-info {
            display: flex;
            align-items: center;
            gap: 20px;
            background: rgba(255,255,255,0.1);
            padding: 15px 20px;
            border-radius: 10px;
            backdrop-filter: blur(10px);
        }
        
        .user-info strong {
            font-size: 1.1rem;
            display: block;
        }
        
        .user-info div div {
            font-size: 0.9rem;
            opacity: 0.8;
        }
        
        .btn-back {
            background: rgba(255,255,255,0.2);
            color: white;
            padding: 10px 20px;
            border-radius: 8px;
            text-decoration: none;
            display: flex;
            align-items: center;
            gap: 8px;
            transition: all 0.3s;
            border: 1px solid rgba(255,255,255,0.3);
        }
        
        .btn-back:hover {
            background: rgba(255,255,255,0.3);
            transform: translateY(-2px);
        }
        
        .admin-nav {
            background: white;
            border-radius: 12px;
            padding: 0;
            margin-bottom: 30px;
            box-shadow: 0 5px 20px rgba(0,0,0,0.05);
            display: flex;
            overflow: hidden;
            border: 1px solid var(--border-color);
        }
        
        .admin-nav a {
            flex: 1;
            padding: 18px 20px;
            text-align: center;
            text-decoration: none;
            color: var(--dark-color);
            font-weight: 500;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            transition: all 0.3s;
            border-bottom: 3px solid transparent;
        }
        
        .admin-nav a:hover {
            background: #f8f9fa;
            color: var(--primary-color);
        }
        
        .admin-nav a.active {
            background: #f8f9fa;
            color: var(--primary-color);
            border-bottom-color: var(--primary-color);
        }
        
        .admin-nav a i {
            font-size: 1.1rem;
        }
        
        .filters-container {
            background: white;
            border-radius: 15px;
            padding: 30px;
            margin-bottom: 30px;
            box-shadow: 0 5px 20px rgba(0,0,0,0.05);
            border: 1px solid var(--border-color);
        }
        
        .filters-container h3 {
            margin-top: 0;
            margin-bottom: 25px;
            color: var(--dark-color);
            font-size: 1.3rem;
            display: flex;
            align-items: center;
            gap: 10px;
        }
        
        .filters-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 25px;
            margin-bottom: 25px;
        }
        
        .filter-group {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }
        
        .filter-group label {
            font-weight: 600;
            color: var(--dark-color);
            font-size: 0.95rem;
            display: flex;
            align-items: center;
            gap: 8px;
        }
        
        .form-control {
            padding: 12px 15px;
            border: 2px solid var(--border-color);
            border-radius: 8px;
            font-size: 0.95rem;
            transition: all 0.3s;
            background: white;
        }
        
        .form-control:focus {
            outline: none;
            border-color: var(--primary-color);
            box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
        }
        
        .date-range {
            display: flex;
            gap: 10px;
            align-items: center;
        }
        
        .date-range input {
            flex: 1;
        }
        
        .filter-actions {
            display: flex;
            gap: 15px;
            margin-top: 15px;
        }
        
        .btn {
            padding: 12px 25px;
            border: none;
            border-radius: 8px;
            font-size: 0.95rem;
            font-weight: 600;
            cursor: pointer;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            transition: all 0.3s;
            text-decoration: none;
        }
        
        .btn-primary {
            background: var(--primary-color);
            color: white;
        }
        
        .btn-primary:hover {
            background: #2980b9;
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
        }
        
        .btn-secondary {
            background: var(--light-color);
            color: var(--dark-color);
        }
        
        .btn-secondary:hover {
            background: #d5dbdb;
            transform: translateY(-2px);
        }
        
        .stats-overview {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
            gap: 25px;
            margin-bottom: 30px;
        }
        
        .stat-card-large {
            background: white;
            border-radius: 15px;
            padding: 30px;
            text-align: center;
            box-shadow: 0 5px 20px rgba(0,0,0,0.05);
            transition: all 0.3s;
            border: 1px solid var(--border-color);
            position: relative;
            overflow: hidden;
        }
        
        .stat-card-large::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            height: 5px;
            background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
        }
        
        .stat-card-large:hover {
            transform: translateY(-5px);
            box-shadow: 0 15px 30px rgba(0,0,0,0.1);
        }
        
        .stat-card-large .value {
            font-size: 3.5rem;
            font-weight: 800;
            color: var(--dark-color);
            margin: 15px 0;
            line-height: 1;
        }
        
        .stat-card-large .label {
            color: var(--gray-color);
            font-size: 1rem;
            font-weight: 600;
            margin-bottom: 10px;
        }
        
        .stat-card-large .subtext {
            color: var(--gray-color);
            font-size: 0.9rem;
            margin-top: 10px;
        }
        
        .category-breakdown {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
            gap: 20px;
            margin-bottom: 40px;
        }
        
        .category-item {
            background: white;
            padding: 25px 20px;
            border-radius: 12px;
            text-align: center;
            border: 1px solid var(--border-color);
            box-shadow: 0 5px 15px rgba(0,0,0,0.05);
            transition: all 0.3s;
        }
        
        .category-item:hover {
            transform: translateY(-3px);
            box-shadow: 0 10px 25px rgba(0,0,0,0.08);
        }
        
        .category-value {
            font-size: 2.2rem;
            font-weight: 800;
            color: var(--dark-color);
            margin: 10px 0;
            line-height: 1;
        }
        
        .category-label {
            color: var(--gray-color);
            font-size: 0.95rem;
            font-weight: 600;
            margin-bottom: 5px;
        }
        
        .category-percent {
            color: var(--primary-color);
            font-size: 1.1rem;
            font-weight: 700;
        }
        
        .charts-container {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(550px, 1fr));
            gap: 30px;
        }
        
        .chart-card {
            background: white;
            border-radius: 15px;
            padding: 30px;
            box-shadow: 0 5px 20px rgba(0,0,0,0.05);
            border: 1px solid var(--border-color);
            display: flex;
            flex-direction: column;
            height: 450px;
        }
        
        .chart-card h3 {
            margin: 0 0 20px 0;
            color: var(--dark-color);
            font-size: 1.3rem;
            display: flex;
            align-items: center;
            gap: 12px;
        }
        
        .chart-card h3 i {
            color: var(--primary-color);
            font-size: 1.2rem;
        }
        
        .chart-container {
            flex: 1;
            background: #f8f9fa;
            border-radius: 10px;
            padding: 20px;
            border: 1px solid var(--border-color);
            overflow: auto;
            min-height: 350px;
            display: flex;
            flex-direction: column;
        }
        
        /* Стили для таблиц в графиках */
        .chart-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 0.9rem;
            flex: 1;
        }
        
        .chart-table thead {
            background: var(--light-color);
            position: sticky;
            top: 0;
            z-index: 10;
        }
        
        .chart-table th {
            padding: 15px 12px;
            text-align: left;
            color: var(--dark-color);
            font-weight: 600;
            border-bottom: 2px solid var(--border-color);
            white-space: nowrap;
        }
        
        .chart-table td {
            padding: 14px 12px;
            border-bottom: 1px solid var(--border-color);
            vertical-align: middle;
        }
        
        .chart-table tbody tr:hover {
            background: rgba(52, 152, 219, 0.05);
        }
        
        /* Стили для прогресс-баров */
        .progress-container {
            background: var(--light-color);
            height: 24px;
            border-radius: 12px;
            overflow: hidden;
            width: 100%;
        }
        
        .progress-bar {
            height: 100%;
            background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
            border-radius: 12px;
            transition: width 0.5s ease;
            min-width: 20px;
        }
        
        /* Стили для графика временной шкалы */
        .timeline-graph {
            display: flex;
            align-items: flex-end;
            gap: 15px;
            height: 250px;
            padding: 20px 0;
            position: relative;
            flex: 1;
        }
        
        .timeline-bar {
            flex: 1;
            display: flex;
            flex-direction: column;
            align-items: center;
            height: 100%;
            min-width: 60px;
        }
        
        .timeline-column {
            width: 70%;
            background: linear-gradient(to top, var(--primary-color), var(--secondary-color));
            border-radius: 6px 6px 0 0;
            position: relative;
            transition: height 0.5s ease;
        }
        
        .timeline-value {
            position: absolute;
            top: -30px;
            left: 50%;
            transform: translateX(-50%);
            background: var(--dark-color);
            color: white;
            padding: 4px 8px;
            border-radius: 4px;
            font-size: 0.85rem;
            font-weight: 600;
            white-space: nowrap;
        }
        
        .timeline-date {
            margin-top: 10px;
            font-size: 0.8rem;
            color: var(--gray-color);
            text-align: center;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            max-width: 100%;
            padding: 0 5px;
        }
        
        @media (max-width: 1200px) {
            .charts-container {
                grid-template-columns: 1fr;
            }
            
            .chart-card {
                height: 400px;
            }
        }
        
        @media (max-width: 768px) {
            .admin-header {
                flex-direction: column;
                gap: 20px;
                text-align: center;
            }
            
            .user-info {
                width: 100%;
                justify-content: center;
            }
            
            .admin-nav {
                flex-wrap: wrap;
            }
            
            .admin-nav a {
                flex: 1 0 calc(50% - 2px);
                padding: 15px;
                font-size: 0.9rem;
            }
            
            .filters-grid {
                grid-template-columns: 1fr;
            }
            
            .stats-overview {
                grid-template-columns: 1fr;
            }
            
            .category-breakdown {
                grid-template-columns: repeat(3, 1fr);
            }
            
            .charts-container {
                grid-template-columns: 1fr;
            }
            
            .chart-card {
                height: 400px;
                padding: 20px;
            }
            
            .chart-container {
                padding: 15px;
            }
            
            .timeline-graph {
                gap: 10px;
                height: 200px;
            }
            
            .timeline-bar {
                min-width: 50px;
            }
        }
        
        @media (max-width: 576px) {
            .dashboard-container {
                padding: 15px;
            }
            
            .admin-nav a {
                flex: 1 0 100%;
            }
            
            .category-breakdown {
                grid-template-columns: 1fr;
                gap: 15px;
            }
            
            .chart-card {
                height: 350px;
            }
            
            .filter-actions {
                flex-direction: column;
            }
            
            .btn {
                width: 100%;
            }
        }
        /* Адаптивные стили для таблиц в графиках */
            .chart-container {
            overflow-x: hidden !important; /* Запрещаем горизонтальную прокрутку */
            overflow-y: auto;
            }

            .chart-table {
            min-width: auto !important; /* Убираем минимальную ширину */
            width: 100% !important;
            table-layout: fixed !important; /* Фиксируем ширину колонок */
            }

            /* Стили для мобильных устройств */
            @media (max-width: 768px) {
            .charts-container {
                grid-template-columns: 1fr !important;
            }
            
            .chart-card {
                height: auto !important;
                min-height: 400px !important;
            }
            
            .chart-container {
                min-height: 300px !important;
                height: 300px !important;
            }
            
            /* Адаптивные таблицы */
            .chart-table {
                font-size: 0.85rem !important;
            }
            
            .chart-table th,
            .chart-table td {
                padding: 8px 6px !important;
            }
            
            /* Уменьшаем график временной шкалы на мобильных */
            .timeline-graph {
                height: 200px !important;
            }
            
            .timeline-date {
                font-size: 0.75rem !important;
            }
            }

            /* Еще более компактно на маленьких экранах */
            @media (max-width: 480px) {
            .chart-card {
                padding: 15px !important;
            }
            
            .chart-container {
                padding: 10px !important;
            }
            
            .chart-table {
                font-size: 0.8rem !important;
            }
            
            .timeline-bar {
                min-width: 40px !important;
            }
            }

            /* Улучшенная вертикальная прокрутка */
            .chart-container::-webkit-scrollbar {
            width: 6px;
            }

            .chart-container::-webkit-scrollbar-track {
            background: #f1f1f1;
            border-radius: 3px;
            }

            .chart-container::-webkit-scrollbar-thumb {
            background: #c1c1c1;
            border-radius: 3px;
            }

            .chart-container::-webkit-scrollbar-thumb:hover {
            background: #a8a8a8;
            }
            /* Улучшенные стили для графиков */
.chart-container {
  min-height: 300px;
  background: #f8f9fa;
  border-radius: 8px;
  padding: 15px;
  border: 1px solid #eaeaea;
  overflow: hidden; /* Убираем все прокрутки */
  display: flex;
  flex-direction: column;
}

/* Адаптивные таблицы для графиков */
.chart-container table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed; /* Фиксированная ширина колонок */
}

.chart-container td {
  padding: 10px 8px;
  vertical-align: middle;
}

/* Прогресс-бары */
.chart-container .progress-bar {
  height: 12px;
  border-radius: 6px;
  transition: width 0.3s ease;
}

/* График временной шкалы */
.timeline-graph {
  height: 250px;
  display: flex;
  align-items: flex-end;
  padding: 10px 0;
}

.timeline-column {
  width: 70%;
  margin: 0 auto;
  border-radius: 4px 4px 0 0;
  transition: height 0.3s ease;
}

.timeline-date {
  margin-top: 10px;
  padding-top: 5px;
  font-size: 0.8rem;
  color: #7f8c8d;
  text-align: center;
  border-top: 1px solid #eaeaea;
  width: 100%;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
  .chart-card {
    height: 380px !important;
    padding: 20px !important;
  }
  
  .chart-container {
    padding: 10px !important;
    min-height: 250px !important;
  }
  
  /* Уменьшаем шрифты для таблиц */
  .chart-container table {
    font-size: 0.8rem !important;
  }
  
  .chart-container td {
    padding: 8px 4px !important;
  }
  
  /* Уменьшаем график временной шкалы */
  .timeline-graph {
    height: 200px !important;
  }
  
  .timeline-date {
    font-size: 0.7rem !important;
  }
}

/* Для очень маленьких экранов */
@media (max-width: 480px) {
  .chart-card {
    height: 350px !important;
    padding: 15px !important;
  }
  
  .chart-container {
    padding: 8px !important;
    min-height: 220px !important;
  }
  
  .chart-container table {
    font-size: 0.75rem !important;
  }
  
  .chart-container td {
    padding: 6px 3px !important;
  }
  
  /* Уменьшаем отступы в графиках */
  .timeline-graph {
    height: 180px !important;
    gap: 8px !important;
  }
}

/* Обрезка длинного текста с многоточием */
.chart-container span[title] {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: help;
}

/* Плавная прокрутка при необходимости */
.chart-container > div:first-child {
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
}

/* Стилизация скроллбара */
.chart-container > div:first-child::-webkit-scrollbar {
  width: 4px;
}

.chart-container > div:first-child::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 2px;
}

.chart-container > div:first-child::-webkit-scrollbar-thumb {
  background: #c1c1c1;
  border-radius: 2px;
}

.chart-container > div:first-child::-webkit-scrollbar-thumb:hover {
  background: #a8a8a8;
}

/* Стили для легенды/подписей */
.chart-footer {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid #eaeaea;
  font-size: 0.8rem;
  color: #7f8c8d;
  text-align: center;
}
/* СУПЕР КОМПАКТНЫЕ СТИЛИ ДЛЯ ДАШБОРДА */

/* Общие настройки компактности */
.chart-container {
  min-height: 280px !important;
  padding: 10px !important;
  font-size: 0.8rem !important;
}

.chart-card {
  height: 380px !important;
  padding: 15px !important;
}

/* Убираем лишние отступы */
.chart-container > div {
  margin: 0 !important;
  padding: 0 !important;
}

/* Компактные заголовки */
.chart-card h3 {
  margin-bottom: 12px !important;
  font-size: 1.1rem !important;
}

.chart-card h3 i {
  font-size: 1rem !important;
}

/* Очень компактные элементы списка */
.chart-container .compact-row {
  padding: 4px 0 !important;
  margin: 0 !important;
}

/* Минимальные прогресс-бары */
.chart-container .compact-progress {
  height: 8px !important;
  border-radius: 4px !important;
}

/* Очень маленькие шрифты для мобильных */
@media (max-width: 768px) {
  .chart-card {
    height: 320px !important;
    padding: 12px !important;
    margin-bottom: 15px !important;
  }
  
  .chart-container {
    min-height: 220px !important;
    padding: 8px !important;
    font-size: 0.75rem !important;
  }
  
  .chart-card h3 {
    font-size: 1rem !important;
    margin-bottom: 8px !important;
  }
  
  /* Скрываем некоторые элементы на очень маленьких экранах */
  @media (max-width: 480px) {
    .chart-card {
      height: 280px !important;
      padding: 10px !important;
    }
    
    .chart-container {
      min-height: 180px !important;
      padding: 6px !important;
      font-size: 0.7rem !important;
    }
    
    /* Можно скрыть % на очень маленьких экранах */
    .hide-on-mobile {
      display: none !important;
    }
  }
}

/* Стили для улучшения видимости на темном фоне */
.chart-container {
  background: white !important;
  border: 1px solid #e0e6ed !important;
}

/* Улучшенная обрезка текста */
.ellipsis-text {
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  max-width: 100% !important;
}

/* Минимальная ширина для столбцов */
.min-width-25 {
  min-width: 25px !important;
}

.min-width-30 {
  min-width: 30px !important;
}

/* Тонкие разделители */
.thin-border {
  border-width: 0.5px !important;
}

/* Убираем тени для компактности */
.chart-card,
.chart-container,
.filters-container {
  box-shadow: 0 2px 8px rgba(0,0,0,0.08) !important;
}

/* Компактные заголовки фильтров */
.filters-container h3 {
  margin-bottom: 15px !important;
  font-size: 1.2rem !important;
}

/* Компактные кнопки фильтров */
.filter-actions .btn {
  padding: 10px 15px !important;
  font-size: 0.9rem !important;
}
/* Стили для уведомлений */
.alert-message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    background: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 10px;
    transform: translateX(120%);
    transition: transform 0.3s ease;
    max-width: 400px;
}

.alert-message.show {
    transform: translateX(0);
}

.alert-success {
    border-left: 4px solid #27ae60;
    color: #27ae60;
}

.alert-error {
    border-left: 4px solid #e74c3c;
    color: #e74c3c;
}

.alert-warning {
    border-left: 4px solid #f39c12;
    color: #f39c12;
}

.alert-info {
    border-left: 4px solid #3498db;
    color: #3498db;
}

/* Стили для пагинации */
.pagination {
    display: flex;
    list-style: none;
    gap: 5px;
    padding: 0;
    margin: 0;
}

.page-item .page-link {
    display: block;
    padding: 8px 15px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    color: #3498db;
    text-decoration: none;
    transition: all 0.3s;
}

.page-item .page-link:hover {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.page-item .page-link.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

/* Кнопки */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
    font-size: 0.95rem;
}

.btn-primary {
    background: #3498db;
    color: white;
}

.btn-primary:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(52, 152, 219, 0.3);
}

.btn-secondary {
    background: #95a5a6;
    color: white;
}

.btn-success {
    background: #27ae60;
    color: white;
}

.btn-danger {
    background: #e74c3c;
    color: white;
}

/* Поля ввода */
.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: border 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}
/* Базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background: #f5f7fa;
    color: #333;
    min-height: 100vh;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.admin-header h1 {
    color: #2c3e50;
    font-size: 1.8rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 20px;
}

.admin-nav {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.admin-nav a {
    padding: 12px 25px;
    background: white;
    border-radius: 8px;
    text-decoration: none;
    color: #555;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
    border: 1px solid #eee;
}

.admin-nav a:hover {
    background: #f8f9fa;
    color: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.admin-nav a.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.table-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}
.btn-excel {
  background: #217346;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-excel:hover {
  background: #1a5c38;
}
.btn-excel {
  background: linear-gradient(135deg, #217346 0%, #185a37 100%);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
  font-weight: 600;
  box-shadow: 0 3px 6px rgba(33, 115, 70, 0.2);
}

.btn-excel:hover {
  background: linear-gradient(135deg, #185a37 0%, #13492d 100%);
  transform: translateY(-2px);
  box-shadow: 0 5px 10px rgba(33, 115, 70, 0.3);
}

.btn-excel:active {
  transform: translateY(0);
}
/* Стили для отображения средних оценок */
.scores-container {
  margin-top: 20px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #e9ecef;
}

.score-item {
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.score-label {
  flex: 1;
  font-weight: 500;
  color: #495057;
  font-size: 0.9rem;
}

.score-value {
  width: 60px;
  text-align: right;
  font-weight: bold;
  color: #2c3e50;
}

.score-bar {
  flex: 2;
  height: 8px;
  background: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
}

.score-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #3498db, #2ecc71);
  border-radius: 4px;
  transition: width 0.3s ease;
}
/* Добавьте в файл css/styles.css или в тег style в head */
.progress-indicator {
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, -20px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(231, 76, 60, 0); }
  100% { box-shadow: 0 0 0 0 rgba(231, 76, 60, 0); }
}

.question-item.unanswered, .maturity-question.unanswered {
  animation: pulse 2s infinite;
}
/* Улучшенные фильтры */
.filters-panel {
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
}

.filter-item {
    flex: 1;
    min-width: 180px;
}

.filter-item label {
    display: block;
    margin-bottom: 5px;
    color: #2c3e50;
    font-weight: 500;
    font-size: 0.9rem;
}

.filter-item select,
.filter-item input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: border 0.3s;
}

.filter-item select:focus,
.filter-item input:focus {
    border-color: #3498db;
    outline: none;
}

.filter-buttons {
    display: flex;
    gap: 10px;
    margin-left: auto;
}

/* Статистика фильтров */
.filter-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    font-size: 0.9rem;
}

.stats-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 15px;
}

.stats-value {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2c3e50;
}

.stats-label {
    color: #7f8c8d;
    font-size: 0.85rem;
    margin-top: 5px;
}

/* Пагинация с информацией */
.pagination-with-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding: 15px 0;
    border-top: 1px solid #eee;
}

.page-info {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.page-info .highlight {
    color: #2c3e50;
    font-weight: 600;
}

/* Быстрые фильтры */
.quick-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.quick-filter-btn {
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: #f8f9fa;
    border-radius: 20px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s;
}

.quick-filter-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.quick-filter-btn.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

/* Сохраненные фильтры */
.saved-filters {
    margin-top: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.saved-filters-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.saved-filters-list {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
/* Улучшение селектора количества записей */
.items-per-page select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.9rem;
    background: white;
    cursor: pointer;
    transition: border 0.3s;
}

.items-per-page select:focus {
    border-color: #3498db;
    outline: none;
}

.items-per-page label {
    font-weight: 500;
    color: #2c3e50;
    font-size: 0.9rem;
}

/* Улучшение пагинации */
.pagination-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.page-info {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-right: 20px;
}
/* Добавьте эти медиа-запросы в конец файла */

/* Для планшетов (768px - 1024px) */
@media (max-width: 1024px) {
    .container {
        padding: 10px;
    }
    
    .question-item,
    .maturity-question {
        padding: 15px;
        margin: 10px 0;
    }
    
    .options-grid {
        grid-template-columns: 1fr !important;
    }
    
    .question-text {
        font-size: 1rem;
    }
    
    .option-label {
        padding: 8px 12px;
        margin: 5px 0;
    }
}

/* Для мобильных устройств (до 768px) */
@media (max-width: 768px) {
    body {
        font-size: 14px;
    }
    
    .container {
        padding: 5px;
        width: 100%;
        max-width: 100%;
    }
    
    /* Заголовки */
    h1 {
        font-size: 1.8rem !important;
        padding: 0 10px;
    }
    
    h2 {
        font-size: 1.5rem !important;
    }
    
    h3 {
        font-size: 1.2rem !important;
    }
    
    /* Вопросы анкеты */
    .question-item,
    .maturity-question {
        padding: 12px;
        margin: 8px 0;
        border-radius: 8px;
    }
    
    .question-number {
        font-size: 1.1rem;
        min-width: 35px;
        height: 35px;
    }
    
    .question-text {
        font-size: 0.95rem;
        line-height: 1.4;
    }
    
    /* Варианты ответов */
    .option-label {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px;
        margin: 4px 0;
    }
    
    .option-text {
        font-size: 0.9rem;
        margin-top: 5px;
    }
    
    /* Радио-кнопки */
    input[type="radio"] {
        width: 20px;
        height: 20px;
        margin-right: 8px;
    }
    
    /* Кнопки */
    .btn {
        padding: 12px 20px;
        font-size: 0.95rem;
        width: 100%;
        margin: 5px 0;
    }
    
    /* Формы */
    .form-group {
        margin-bottom: 15px;
    }
    
    input[type="text"],
    input[type="number"],
    select {
        padding: 12px;
        font-size: 1rem;
    }
    
    /* Прогресс-индикатор */
    .progress-indicator {
        top: 10px;
        left: 10px;
        right: 10px;
        width: auto;
        transform: none;
        padding: 8px 12px;
        font-size: 0.85rem;
    }
    
    /* Хедер анкеты */
    .questionnaire-header {
        padding: 15px;
        flex-direction: column;
        text-align: center;
    }
    
    .header-actions {
        margin-top: 10px;
        flex-direction: column;
        width: 100%;
    }
    
    .header-actions .btn {
        width: 100%;
        margin: 5px 0;
    }
    
    /* Модальные окна */
    .modal-content {
        width: 95%;
        margin: 10% auto;
        padding: 20px;
    }
    
    /* Вкладки (если есть) */
    .tab-buttons {
        flex-direction: column;
    }
    
    .tab-button {
        width: 100%;
        margin: 2px 0;
    }
    
    /* Таблицы */
    .rating-table {
        font-size: 0.85rem;
    }
    
    .rating-table th,
    .rating-table td {
        padding: 8px 5px;
    }
}

/* Для очень маленьких экранов (до 480px) */
@media (max-width: 480px) {
    body {
        font-size: 13px;
    }
    
    .question-text {
        font-size: 0.9rem;
    }
    
    .option-label {
        padding: 8px;
    }
    
    .option-text {
        font-size: 0.85rem;
    }
    
    .question-number {
        min-width: 30px;
        height: 30px;
        font-size: 1rem;
    }
    
    /* Улучшаем отображение уровней зрелости */
    .maturity-level-header {
        font-size: 0.9rem;
    }
    
    .maturity-level-description {
        font-size: 0.85rem;
    }
    
    /* Уменьшаем размер шрифта для меток */
    label {
        font-size: 0.9rem;
    }
    
    /* Адаптация полей формы */
    .form-row {
        flex-direction: column;
    }
    
    .form-group {
        width: 100%;
    }
    
    /* Адаптация радио-групп */
    .radio-group {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .radio-label {
        margin-bottom: 8px;
    }
}

/* Добавьте анимацию для лучшего UX */
@media (hover: none) and (pointer: coarse) {
    /* Для тач-устройств */
    .btn, 
    .option-label,
    .radio-label {
        min-height: 44px; /* Минимальная высота для тач-интерфейса */
    }
    
    input[type="radio"],
    input[type="checkbox"] {
        min-width: 24px;
        min-height: 24px;
    }
    
    /* Увеличиваем область клика */
    .option-label::before {
        content: '';
        position: absolute;
        top: -10px;
        left: -10px;
        right: -10px;
        bottom: -10px;
    }
}

/* Портретная ориентация */
@media (orientation: portrait) {
    .question-item {
        break-inside: avoid;
    }
    
    .section-group {
        page-break-inside: avoid;
    }
}

/* Ландшафтная ориентация */
@media (orientation: landscape) and (max-height: 500px) {
    .progress-indicator {
        position: absolute;
        top: 5px;
    }
    
    .questionnaire-header {
        position: sticky;
        top: 0;
        z-index: 100;
        background: white;
        padding: 10px;
    }
}