/* User Management Page Styles - Dashboard Style */

/* ========== STAT CARDS ========== */
.stat-card {
    transition: transform 0.15s ease-in-out;
}

.stat-card:hover {
    transform: translateY(-0.125rem);
}

/* Dashboard style border colors */
.stat-card.total { border-left: 4px solid var(--bs-primary) !important; }
.stat-card.active { border-left: 4px solid var(--bs-success) !important; }
.stat-card.online { border-left: 4px solid var(--bs-info) !important; }
.stat-card.suspended { border-left: 4px solid var(--bs-danger) !important; }

/* ========== USER STATUS BADGES ========== */
.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
}

.status-active {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-inactive {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.status-suspended {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

/* ========== ROLE BADGES ========== */
.role-badge {
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
}

.role-admin {
    background-color: #e3f2fd;
    color: #1565c0;
}

.role-manager {
    background-color: #f3e5f5;
    color: #7b1fa2;
}

.role-user {
    background-color: #e8f5e8;
    color: #2e7d32;
}

.role-guest {
    background-color: #fff3e0;
    color: #ef6c00;
}

/* ========== ACTION BUTTONS ========== */
.action-btn {
    padding: 0.25rem 0.5rem;
    margin: 0 0.125rem;
    border: none;
    border-radius: 5px;
    font-size: 0.75rem;
    transition: all 0.2s ease;
}

.action-btn:hover {
    transform: translateY(-1px);
}

.btn-view {
    background-color: #17a2b8;
    color: white;
}

.btn-view:hover {
    background-color: #138496;
    color: white;
}

.btn-edit {
    background-color: #ffc107;
    color: #212529;
}

.btn-edit:hover {
    background-color: #e0a800;
    color: #212529;
}

.btn-delete {
    background-color: #dc3545;
    color: white;
}

.btn-delete:hover {
    background-color: #c82333;
    color: white;
}

/* ========== ADD USER BUTTON STYLES ========== */
.btn-primary.btn-lg {
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.15);
    transition: all 0.2s ease;
}

.btn-primary.btn-lg:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(13, 110, 253, 0.25);
}

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

/* Filter section buttons */
.col-md-4 .btn {
    border-radius: 6px;
    font-weight: 500;
}

.col-md-4 .btn:hover {
    transform: translateY(-1px);
}

/* ========== LOADING STATE ========== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    z-index: 9999;
}

/* ========== PAGINATION ========== */
.pagination-info {
    color: #6c757d;
    font-size: 0.9rem;
}

.pagination .page-link {
    color: #667eea;
    border-color: #dee2e6;
    padding: 0.5rem 0.75rem;
}

.pagination .page-link:hover {
    background-color: #e9ecef;
    border-color: #adb5bd;
    color: #495057;
}

.pagination .page-item.active .page-link {
    background-color: #667eea;
    border-color: #667eea;
}

/* ========== SESSIONS INDICATOR ========== */
.sessions-indicator {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
}

.sessions-active {
    background-color: #d4edda;
    color: #155724;
}

.sessions-none {
    background-color: #f8d7da;
    color: #721c24;
}

/* ========== USER AVATAR ========== */
.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--bs-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 500;
    font-size: 0.875rem;
    margin-right: 0.5rem;
}

/* ========== USER DETAILS MODAL ========== */
.user-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #dee2e6;
}

.user-detail-item:last-child {
    border-bottom: none;
}

.user-detail-label {
    font-weight: 500;
    color: #495057;
    min-width: 120px;
}

.user-detail-value {
    color: #212529;
    text-align: right;
}

/* ========== PERMISSION CHIPS ========== */
.permission-chip {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    margin: 0.125rem;
    background-color: #e9ecef;
    color: #495057;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.permission-chip.all {
    background-color: #d4edda;
    color: #155724;
}

/* ========== ANIMATIONS ========== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.3s ease;
}

.table tbody tr {
    animation: fadeInUp 0.3s ease;
}

/* ========== RESPONSIVE DESIGN ========== */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 0.875rem;
    }
    
    .action-btn {
        padding: 0.125rem 0.25rem;
        font-size: 0.65rem;
    }
    
    .pagination-info {
        text-align: center;
        margin-bottom: 1rem;
    }
    
    .user-avatar {
        width: 28px;
        height: 28px;
        font-size: 0.75rem;
    }
}

/* User details modal */
.user-detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #dee2e6;
}

.user-detail-item:last-child {
    border-bottom: none;
}

.user-detail-label {
    font-weight: 500;
    color: #495057;
    min-width: 120px;
}

.user-detail-value {
    color: #212529;
    text-align: right;
}

/* Sessions indicator */
.sessions-indicator {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
}

.sessions-active {
    background-color: #d4edda;
    color: #155724;
}

.sessions-none {
    background-color: #f8d7da;
    color: #721c24;
}

/* Responsive design */
@media (max-width: 768px) {
    .page-header {
        text-align: center;
        padding: 1.5rem;
    }
    
    .filter-section .row > div {
        margin-bottom: 1rem;
    }
    
    .table-container {
        overflow-x: auto;
    }
    
    .table {
        min-width: 800px;
    }
    
    .pagination-info {
        text-align: center;
        margin-bottom: 1rem;
    }
}

/* Animation for table rows */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.table tbody tr {
    animation: fadeInUp 0.3s ease;
}

/* Tooltips */
.tooltip-inner {
    background-color: #343a40;
    color: white;
}

.tooltip .tooltip-arrow::before {
    border-top-color: #343a40;
}

/* User avatar placeholder */
.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--bs-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 500;
    font-size: 0.875rem;
    margin-right: 0.5rem;
}

/* Permission chips */
.permission-chip {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    margin: 0.125rem;
    background-color: #e9ecef;
    color: #495057;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.permission-chip.all {
    background-color: #d4edda;
    color: #155724;
}
