/* Admin Panel Custom Styles */

/* Login Page Styles */
.vh-100 {
    min-height: 100vh;
}

.card {
    border-radius: 15px;
}

.btn-primary {
    background: linear-gradient(45deg, #007bff, #0056b3);
    border: none;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(45deg, #0056b3, #004085);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

/* Dashboard Styles */
.bg-dark {
    background-color: #2c3e50 !important;
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: white !important;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    color: white !important;
}

/* Stats Cards */
.border-left-primary {
    border-left: 0.25rem solid #4e73df !important;
}

.border-left-success {
    border-left: 0.25rem solid #1cc88a !important;
}

.border-left-info {
    border-left: 0.25rem solid #36b9cc !important;
}

.border-left-warning {
    border-left: 0.25rem solid #f6c23e !important;
}

/* Typography */
.text-xs {
    font-size: 0.7rem;
}

.font-weight-bold {
    font-weight: 700 !important;
}

.text-gray-800 {
    color: #5a5c69 !important;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .position-fixed {
        position: relative !important;
        width: 100% !important;
    }
    
    .flex-grow-1 {
        margin-left: 0 !important;
    }
    
    .vh-100 {
        height: auto !important;
        min-height: 100vh;
    }
}

/* Custom Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card {
    animation: fadeIn 0.5s ease-out;
}

/* Form Styles */
.form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.input-group-text {
    background-color: #f8f9fa;
    border-color: #ced4da;
}

/* Button Styles */
.btn {
    border-radius: 8px;
    transition: all 0.3s ease;
}

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

/* Table Styles */
.table th {
    border-top: none;
    font-weight: 600;
    color: #495057;
}

/* Alert Styles */
.alert {
    border-radius: 10px;
    border: none;
}

/* Badge Styles */
.badge {
    font-size: 0.75rem;
    padding: 0.5em 0.75em;
}

/* Shadow Effects */
.shadow {
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15) !important;
}

.shadow-lg {
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175) !important;
}

/* Pagination Styles */
.pagination {
    margin-bottom: 0;
    border-radius: 8px;
    overflow: hidden;
}

.pagination .page-link {
    color: #495057;
    background-color: #fff;
    border: 1px solid #dee2e6;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border-radius: 0;
}

.pagination .page-link:hover {
    color: #007bff;
    background-color: #e9ecef;
    border-color: #dee2e6;
    transform: translateY(-1px);
}

.pagination .page-item.active .page-link {
    color: #fff;
    background-color: #007bff;
    border-color: #007bff;
    box-shadow: 0 2px 4px rgba(0, 123, 255, 0.3);
}

.pagination .page-item.disabled .page-link {
    color: #6c757d;
    background-color: #fff;
    border-color: #dee2e6;
    opacity: 0.6;
}

.pagination .page-item:first-child .page-link {
    border-top-left-radius: 8px;
    border-bottom-left-radius: 8px;
}

.pagination .page-item:last-child .page-link {
    border-top-right-radius: 8px;
    border-bottom-right-radius: 8px;
}

/* Pagination Info Text */
.pagination-info {
    font-size: 0.875rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.pagination-info .fw-semibold {
    color: #495057;
    font-weight: 600;
}

/* Responsive Pagination */
@media (max-width: 576px) {
    .pagination {
        justify-content: center;
    }
    
    .pagination .page-link {
        padding: 0.375rem 0.5rem;
        font-size: 0.8rem;
    }
}

/* Admin page header: compact toolbar */
.admin-page-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.5rem 0 0.75rem;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid #dee2e6;
}

.admin-page-title {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0;
    color: #212529;
}

.admin-page-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.admin-products-filter .input-group {
    max-width: 100%;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06);
    border-radius: 6px;
    overflow: hidden;
}

.admin-products-filter .form-control,
.admin-products-filter .form-select {
    border-radius: 0;
    font-size: 0.875rem;
}

.admin-products-filter .form-control {
    min-width: 180px;
}

.admin-products-filter .btn {
    border-radius: 0;
    padding: 0.35rem 0.6rem;
}

.admin-page-buttons {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
}

/* Tighter card for list pages */
.admin-card .card-header {
    background: #f8f9fa;
    border-bottom: 1px solid #eee;
}

.admin-card .card-body {
    background: #fff;
}

.product-list-card {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.product-list-card:hover {
    border-color: #ced4da;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* Empty state */
.admin-empty-state {
    text-align: center;
    padding: 2.5rem 1.5rem;
    background: linear-gradient(180deg, #f8f9fa 0%, #fff 100%);
    border-radius: 10px;
    border: 1px dashed #dee2e6;
}

.admin-empty-state-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    background: #e9ecef;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    font-size: 1.75rem;
}

.admin-empty-state-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.35rem;
}

.admin-empty-state-text {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 1.25rem;
}

@media (max-width: 768px) {
    .admin-page-header {
        flex-direction: column;
        align-items: stretch;
    }
    .admin-page-actions {
        flex-direction: column;
    }
    .admin-products-filter .input-group {
        flex-wrap: wrap;
    }
    .admin-products-filter .form-control {
        min-width: 100%;
    }
    .admin-products-filter .form-select {
        max-width: 100% !important;
        flex: 1;
        min-width: 0;
    }
}
