/* assets/styles/suppliers.css */

/* ============================================
   MODERN SUPPLIERS MANAGEMENT STYLES
   Reusable across all procurement pages
   ============================================ */

/* Custom Properties */
:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --success-gradient: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%);
    --danger-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --warning-gradient: linear-gradient(135deg, #ffe259 0%, #ffa751 100%);
    --info-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --card-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    --hover-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    --border-radius-card: 20px;
    --border-radius-table: 16px;
    --transition-default: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Modern Card Design */
.modern-card {
    background: white;
    border-radius: var(--border-radius-card);
    box-shadow: var(--card-shadow);
    overflow: hidden;
    transition: var(--transition-default);
    border: none;
}

.modern-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--hover-shadow);
}

.modern-card-header {
    background: var(--primary-gradient);
    padding: 1.5rem 2rem;
    border: none;
}

.modern-card-header h4 {
    color: white;
    margin: 0;
    font-weight: 600;
    font-size: 1.5rem;
}

.modern-card-header p {
    color: rgba(255, 255, 255, 0.9);
    margin: 0.5rem 0 0 0;
}

/* Modern Stats Cards */
.stat-card {
    background: white;
    border-radius: 16px;
    padding: 1.5rem;
    transition: var(--transition-default);
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: #2c3e50;
}

.stat-label {
    color: #7f8c8d;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Modern Table Design */
.modern-table-container {
    background: white;
    border-radius: var(--border-radius-table);
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

.modern-table {
    margin-bottom: 0;
    width: 100%;
}

.modern-table thead {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.modern-table thead th {
    padding: 1rem 1.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
}

.modern-table tbody tr {
    transition: var(--transition-default);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.modern-table tbody tr:hover {
    background: #f8f9fa;
    transform: scale(1.01);
}

.modern-table tbody td {
    padding: 1rem 1.5rem;
    vertical-align: middle;
    color: #2c3e50;
}

/* Modern Badges */
.badge-modern {
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-weight: 500;
    font-size: 0.75rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.badge-success-modern {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    color: white;
}

.badge-warning-modern {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: white;
}

/* Modern Buttons */
.btn-modern {
    padding: 0.5rem 1rem;
    border-radius: 10px;
    font-weight: 500;
    transition: var(--transition-default);
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-modern-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-modern-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
    color: white;
}

.btn-modern-success {
    background: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%);
    color: #2c3e50;
}

.btn-modern-warning {
    background: linear-gradient(135deg, #ffe259 0%, #ffa751 100%);
    color: #2c3e50;
}

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

.btn-icon {
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-default);
}

.btn-icon:hover {
    transform: scale(1.1);
}

/* Action Group */
.action-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.action-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
    border-radius: 8px;
    transition: var(--transition-default);
}

/* Supplier Avatar */
.supplier-avatar {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1rem;
}

/* Search & Filter Bar */
.search-filter-bar {
    background: white;
    border-radius: 16px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--card-shadow);
}

.search-input {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 0.75rem 1rem;
    transition: var(--transition-default);
}

.search-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Pagination Modern */
.pagination-modern {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 2rem;
}

.pagination-modern .page-item .page-link {
    border-radius: 10px;
    padding: 0.5rem 1rem;
    color: #667eea;
    border: 1px solid #dee2e6;
    transition: var(--transition-default);
}

.pagination-modern .page-item.active .page-link {
    background: var(--primary-gradient);
    border-color: #667eea;
    color: white;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state-icon {
    font-size: 4rem;
    color: #dee2e6;
    margin-bottom: 1rem;
}

/* Loading Skeleton */
.skeleton-loader {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .modern-table thead th,
    .modern-table tbody td {
        padding: 0.75rem 1rem;
    }
    
    .action-group {
        flex-direction: column;
    }
    
    .stat-card {
        margin-bottom: 1rem;
    }
}

/* Tooltip Custom */
.tooltip-modern {
    position: relative;
    display: inline-block;
}

.tooltip-modern .tooltip-text {
    visibility: hidden;
    background: #2c3e50;
    color: white;
    text-align: center;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    font-size: 0.75rem;
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip-modern:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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