/* Исправления контрастности и выравнивания */

/* Spinner для загрузки */
.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e0e0e0;
    border-top-color: #1e3a8a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #666;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #999;
    text-align: center;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.error-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #dc2626;
    text-align: center;
}

.error-state i {
    font-size: 48px;
    margin-bottom: 16px;
}

/* Улучшенная контрастность */
.profile-card {
    /* Убираем форсирование синего фона для всех карточек профиля */
    /* background: #1e3a8a !important; */
    /* color: #fff !important; */
}

/* Убираем глобальное переопределение цвета текста */
/* .profile-card * {
    color: white !important;
} */

.profile-card .profile-role {
    opacity: 0.9;
}

/* Исправление белого на белом */
.page-container {
    background: transparent !important;
}

.user-dashboard .profile-card {
    /* Убираем синий градиент */
    /* background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%) !important; */
}

.user-dashboard .profile-stats {
    background: rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(10px);
}

.user-dashboard .stat-value {
    /* Убираем форсирование белого цвета для значений статистики */
    /* color: white !important; */
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
    font-weight: 600;
}

.user-dashboard .stat-label {
    color: rgba(255, 255, 255, 0.9) !important;
    font-size: 0.875rem;
}

/* Исправление белого текста на белом фоне */
.info-list,
.settings-list,
.faq-list {
    background: #f8f9fa !important;
}

.info-item,
.setting-item,
.faq-item {
    background: #ffffff !important;
    color: #111827 !important;
}

.info-label,
.setting-label {
    color: #666 !important;
}

.info-value {
    color: #333 !important;
    font-weight: 600;
}

/* Контрастность для форм */
.form-control {
    background: white !important;
    color: #333 !important;
    border: 2px solid #e0e0e0 !important;
}

.form-control:focus {
    border-color: #1e3a8a !important;
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1) !important;
}

.form-control::placeholder {
    color: #999 !important;
}

/* Контрастность для модалок */
.modal-header {
    background: #f8f9fa !important;
    border-bottom: 1px solid #e0e0e0 !important;
}

.modal-header h2 {
    color: #1e3a8a !important;
}

/* Исправление выравнивания страниц */
.page-container {
    padding: 16px;
    padding-bottom: 32px;
    max-width: 100%;
    box-sizing: border-box;
}

.page-header {
    margin-bottom: 20px;
    padding: 0 4px;
}

/* Симметричные карточки */
.task-card,
.stat-card,
.info-item,
.setting-item,
.faq-item,
.ticket-item {
    margin-bottom: 12px;
    border-radius: 12px;
    overflow: hidden;
}

/* Центрирование контента */
.user-dashboard,
.profile-page .profile-content,
.support-page .support-content {
    max-width: 600px;
    margin: 0 auto;
    width: 100%;
}

/* Исправление быстрых действий */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin: 20px 0;
}

.action-card {
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
}

.action-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.action-card i {
    font-size: 32px;
    color: #1e3a8a;
}

.action-card span {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

/* Контрастность статистики */
.stats-grid .stat-card {
    background: white !important;
    color: #333 !important;
}

.stats-grid .stat-value {
    color: #1e3a8a !important;
    font-weight: 700;
}

.stats-grid .stat-label {
    color: #666 !important;
}

/* Исправление табов */
.tabs {
    position: sticky;
    top: 0;
    background: white;
    z-index: 10;
    padding: 0 16px;
    margin: 0 -16px 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* Правильное отображение статусов */
.task-status,
.ticket-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

/* Фикс для длинного текста в info-value */
.info-value {
    word-wrap: break-word;
    word-break: break-word;
    max-width: 100%;
}

/* Фикс для модальных окон */
.modal {
    z-index: 2000 !important;
}

.modal-content {
    background: white !important;
    color: #333 !important;
}

/* Убираем белое на белом в карточках */
.task-card {
    background: white !important;
    border: 1px solid #e0e0e0 !important;
    cursor: pointer;
}

/* Исправление спиннера */
.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e0e0e0;
    border-top-color: #1e3a8a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Исправление кнопок в задачах */
.error-state button,
.empty-state button {
    margin-top: 12px;
}

.stat-card {
    background: #f8f9fa !important;
    border: 1px solid #e5e7eb !important;
}

.action-card {
    background: white !important;
    border: 1px solid #e0e0e0 !important;
}

/* Улучшенная навигация */
.bottom-nav {
    background: white !important;
    border-top: 1px solid #e0e0e0 !important;
    z-index: 1000 !important;
}

.nav-item {
    background: transparent !important;
    color: #666 !important;
    position: relative !important;
    z-index: 1001 !important;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.nav-item:active {
    opacity: 0.7;
}

.nav-item.active {
    color: #1e3a8a !important;
}

.nav-item.active i {
    color: #1e3a8a !important;
}

/* Убираем синий квадрат у активной иконки */
.nav-item i {
    background: transparent !important;
    padding: 0 !important;
    border-radius: 0 !important;
}

/* Исправление отступов */
.profile-stats {
    padding: 16px 0;
    margin: 0;
}

/* Выравнивание панелей */
.page-container {
    padding: 16px;
    max-width: 100%;
    background: #f5f5f5 !important;
}

.profile-card,
.action-cards,
.tasks-section,
.stat-card,
.task-card {
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
    background: white !important;
    color: #111827 !important;
}

/* Профиль - синий градиент */
.user-dashboard .profile-card {
    /* Убираем синий градиент для dashboard */
    /* background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%) !important; */
    /* color: white !important; */
}

.profile-stats-grid {
    margin-bottom: 20px;
}

.profile-info-section,
.profile-settings-section {
    margin-bottom: 24px;
}

.profile-info-section h3,
.profile-settings-section h3,
.faq-section h3,
.support-form-section h3,
.tickets-history-section h3 {
    margin-bottom: 16px;
    font-size: 20px;
    color: #1e3a8a;
}

/* Улучшение форм */
.support-form {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
}

/* Правильное выравнивание заголовков */
h1, h2, h3, h4 {
    margin: 0;
    padding: 0;
    line-height: 1.4;
}

/* Исправление кнопок */
.btn {
    width: 100%;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: #1e3a8a;
    color: white;
}

.btn-primary:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.3);
}

/* Исправление FAQ */
.faq-item {
    background: white;
    margin-bottom: 8px;
}

.faq-question {
    background: white;
    color: #333;
}

.faq-answer {
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}
