:root {
    --primary-color: #4361ee;
    --secondary-color: #3f37c9;
    --success-color: #4cc9f0;
    --info-color: #4895ef;
    --warning-color: #f72585;
    --danger-color: #e63946;
    --light-bg: #f8f9fa;
    --dark-text: #2b2d42;
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    --hover-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

body {
    background-color: #f0f2f5;
    font-family: 'Poppins', sans-serif;
    color: var(--dark-text);
}

/* Navbar */
.navbar-brand {
    font-weight: 700;
    letter-spacing: 0.5px;
}

.nav-link {
    font-weight: 500;
    transition: all 0.3s;
}

.nav-link:hover {
    transform: translateY(-2px);
    color: #fff !important;
}

/* Cards */
.card {
    border: none;
    border-radius: 15px;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    background: #fff;
    margin-bottom: 1.5rem;
}

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

.card-header {
    background-color: #fff;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    font-weight: 600;
    padding: 1.25rem;
    border-radius: 15px 15px 0 0 !important;
}

/* Dashboard Stats Cards */
.stats-card {
    color: white;
    overflow: hidden;
    position: relative;
}

.stats-card .card-body {
    padding: 1.5rem;
    z-index: 2;
    position: relative;
}

.stats-card h5 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0;
}

.stats-card .card-title-text {
    font-size: 0.9rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stats-card .icon-bg {
    position: absolute;
    right: -10px;
    bottom: -10px;
    font-size: 5rem;
    opacity: 0.2;
    transform: rotate(-15deg);
    transition: all 0.3s;
}

.stats-card:hover .icon-bg {
    transform: rotate(0deg) scale(1.1);
}

/* Tables */
.table-responsive {
    border-radius: 15px;
    overflow: hidden;
}

.table thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #e9ecef;
    color: #6c757d;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    padding: 1rem;
}

.table tbody td {
    padding: 1rem;
    vertical-align: middle;
}

/* Buttons */
.btn {
    border-radius: 50px;
    padding: 0.5rem 1.5rem;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    transition: all 0.3s;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 97, 238, 0.4);
}

/* Utilities */
.bg-primary-light { background-color: rgba(67, 97, 238, 0.1); }
.bg-secondary-light { background-color: rgba(108, 117, 125, 0.1); }
.bg-success-light { background-color: rgba(25, 135, 84, 0.1); }
.bg-info-light { background-color: rgba(13, 202, 240, 0.1); }
.bg-warning-light { background-color: rgba(255, 193, 7, 0.1); }
.bg-danger-light { background-color: rgba(220, 53, 69, 0.1); }

.text-muted-small {
    font-size: 0.8rem;
    color: #adb5bd;
}

@media print {
    .no-print {
        display: none !important;
    }
}

/* Mobile Responsive Adjustments */
@media (max-width: 768px) {
    .card-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 1rem;
    }
    
    .card-header form {
        width: 100%;
        flex-wrap: wrap;
        gap: 0.5rem;
        background: transparent !important;
        padding: 0 !important;
    }
    
    .card-header form .input-group {
        width: 100%;
        margin-right: 0 !important;
        margin-bottom: 0.5rem;
    }
    
    .card-header form .btn {
        width: 100%;
    }
    
    .stats-card h5 {
        font-size: 1.5rem;
    }
    
    .border-start {
        border-left: none !important;
        border-top: 1px solid #e9ecef;
        padding-top: 1.5rem;
        margin-top: 1.5rem;
    }
    
    /* Optimize table for mobile */
    .table-responsive .table {
        min-width: 600px; /* Force scroll */
    }
    
    /* Adjust quick actions grid */
    .row.g-4 > .col-md-3 {
        width: 50%; /* 2 items per row on mobile instead of 1 */
    }
}

@media (max-width: 576px) {
    .row.g-4 > .col-md-3 {
        width: 100%; /* 1 item per row on very small screens */
    }
    
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .card-body {
        padding: 1rem;
    }
}

/* Gradients - Force override */
.bg-gradient-primary { background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important; }
.bg-gradient-blue { background: linear-gradient(45deg, #4361ee, #4895ef) !important; }
.bg-gradient-green { background: linear-gradient(45deg, #10b981, #34d399) !important; }
.bg-gradient-orange { background: linear-gradient(45deg, #f59e0b, #fbbf24) !important; }
.bg-gradient-red { background: linear-gradient(45deg, #ef4444, #f87171) !important; }

.bg-gradient-secondary { background: linear-gradient(45deg, #6c757d, #adb5bd) !important; }
.bg-gradient-success { background: linear-gradient(45deg, #198754, #20c997) !important; }
.bg-gradient-info { background: linear-gradient(45deg, #0dcaf0, #3dd5f3) !important; }
.bg-gradient-warning { background: linear-gradient(45deg, #ffc107, #ffca2c) !important; }
.bg-gradient-danger { background: linear-gradient(45deg, #dc3545, #ff6b6b) !important; }
.bg-gradient-dark { background: linear-gradient(45deg, #212529, #343a40) !important; }
