/*
 * Улучшенные стили для админ-панели BetBalls
 */

/* Основная структура */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    margin: 0;
    padding: 0;
}

/* Боковая панель */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 250px;
    z-index: 100;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

/* Заголовок боковой панели */
.sidebar-header {
    padding: 1.5rem;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 1rem;
}

.sidebar-header .navbar-brand {
    color: white !important;
    text-decoration: none;
    font-size: 1.4rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.sidebar-header .navbar-brand:hover {
    color: #e9ecef !important;
}

/* Навигационные ссылки */
.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.8) !important;
    padding: 0.75rem 1.5rem;
    margin: 0.2rem 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
    display: flex;
    align-items: center;
}

.sidebar .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white !important;
    transform: translateX(5px);
}

.sidebar .nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: white !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.sidebar .nav-link i {
    font-size: 1.1rem;
    margin-right: 0.75rem;
    width: 20px;
}

/* Основной контент */
.main-content {
    margin-left: 250px;
    min-height: 100vh;
    background-color: #f8f9fa;
}

/* Верхняя панель */
.topbar {
    background: white;
    border-bottom: 1px solid #e9ecef;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
    padding: 1rem 1.5rem;
    margin-bottom: 0;
}

.topbar h4 {
    color: #495057;
    font-weight: 600;
    margin: 0;
}

/* Поиск - улучшенный дизайн */
.search-container {
    width: 300px;
}

.search-container .form-control {
    border: 1px solid #dee2e6;
    border-radius: 20px;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.search-container .btn {
    border-radius: 20px;
    border: 1px solid #dee2e6;
}

/* Профиль пользователя */
.user-profile {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-avatar {
    border: 2px solid #dee2e6;
    border-radius: 50%;
    transition: border-color 0.3s ease;
}

.user-avatar:hover {
    border-color: #667eea;
}

/* Карточки */
.card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    margin-bottom: 1.5rem;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
    font-weight: 600;
    color: #495057;
    padding: 1rem 1.25rem;
}

/* Таблицы - единый стиль */
.table {
    margin-bottom: 0;
}

.table thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    padding: 1rem 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.table tbody tr {
    transition: background-color 0.2s ease;
}

.table tbody tr:nth-child(even) {
    background-color: #f8f9fa;
}

.table tbody tr:hover {
    background-color: #e3f2fd;
}

.table tbody td {
    padding: 1rem 0.75rem;
    vertical-align: middle;
    font-size: 0.9rem;
    color: #495057;
}

/* Кнопки */
.btn {
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
}

.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-1px);
}

.btn-outline-primary {
    border-color: #667eea;
    color: #667eea;
}

.btn-outline-primary:hover {
    background-color: #667eea;
    border-color: #667eea;
}

/* Значки статусов */
.badge {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.4rem 0.8rem;
    border-radius: 15px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .topbar {
        flex-direction: column;
        gap: 1rem;
    }
    
    .search-container {
        width: 100%;
    }
}

/* Убираем мигающий курсор и outline при клике на таблицу */
.table, .table td, .table th, .table-responsive {
    outline: none !important;
}

/* Убираем фокус с интерактивных элементов таблицы */
.table:focus, .table td:focus, .table th:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Убираем курсор только с неинтерактивных элементов таблицы */
.table tbody td:not(:has(a, button, input)) {
    caret-color: transparent;
}

/*For users page*/
.cursor-help {
    cursor: help;
}

.font-monospace {
    font-family: 'Courier New', Courier, monospace;
}