body {
    overflow-x: hidden;
    font-family: 'Nunito', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f8f9fa;
}

/* Sidebar Styling */
#sidebar-wrapper {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1040;
    overflow-y: auto;
    margin-left: -16rem;
    transition: margin .25s ease-out;
    width: 16rem;
    background: linear-gradient(180deg, #0a282b 10%, #224abe 100%);
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    display: flex;
    flex-direction: column;
}

#sidebar-wrapper .sidebar-heading {
    padding: 1.5rem 1.25rem;
    font-size: 1.2rem;
    color: #fff;
    text-align: center;
    background: rgba(0, 0, 0, 0.1);
}

#sidebar-wrapper .list-group {
    width: 16rem;
    padding: 1rem;
}

#sidebar-wrapper .list-group-item {
    background-color: transparent;
    color: rgba(255, 255, 255, 0.8);
    border: none;
    padding: 0.5rem 1rem;
    margin-bottom: 0.1rem;
    border-radius: 0.35rem;
    transition: all 0.2s ease-in-out;
    font-weight: 600;
    font-size: 0.9rem;
}

#sidebar-wrapper .list-group-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    transform: translateX(5px);
}

#sidebar-wrapper .list-group-item.active {
    background-color: #fff;
    color: #4e73df;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#sidebar-wrapper .list-group-item i {
    width: 20px;
    text-align: center;
    margin-right: 0.5rem;
}

.brand-text {
    color: #fff;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 1.1rem !important;
}

/* Content Wrapper */
#page-content-wrapper {
    min-width: 100vw;
}

body.sb-sidenav-toggled #wrapper #sidebar-wrapper {
    margin-left: 0;
}

@media (min-width: 768px) {
    #sidebar-wrapper {
        margin-left: 0;
    }

    #page-content-wrapper {
        min-width: 0;
        width: 100%;
        margin-left: 16rem;
    }

    body.sb-sidenav-toggled #wrapper #sidebar-wrapper {
        margin-left: -16rem;
    }
    
    body.sb-sidenav-toggled #page-content-wrapper {
        margin-left: 0;
    }
}

/* Card Styling Enhancements */
.card {
    border: none;
    border-radius: 0.35rem;
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15) !important;
}

.card-header {
    background-color: #f8f9fc;
    border-bottom: 1px solid #e3e6f0;
    padding: 0.5rem 1rem; /* Reduced padding */
}

.btn-primary {
    background-color: #4e73df;
    border-color: #4e73df;
}

.btn-primary:hover {
    background-color: #2e59d9;
    border-color: #2653d4;
}

.text-primary {
    color: #4e73df !important;
}

    color: #4e73df;
    background-color: #f8f9fa;
    border-left: 4px solid #4e73df;
    font-weight: 600;
}

.list-group-item {
    border: none;
    font-size: 0.95rem;
    color: #5a5c69;
}

.list-group-item:hover {
    color: #4e73df;
    background-color: #f8f9fa;
}

.btn-primary {
    background-color: #4e73df;
    border-color: #4e73df;
}

.btn-primary:hover {
    background-color: #2e59d9;
    border-color: #2653d4;
}

.card {
    border: none;
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
}

.breadcrumb-item {
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 600;
    color: #858796;
}

.breadcrumb-item.active {
    color: #5a5c69;
}

.page-title {
    color: #5a5c69;
    font-weight: 400;
}

.context-title {
    color: #4e73df;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.table th {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #858796;
    font-weight: 700;
}

.table td {
    color: #5a5c69;
    vertical-align: middle;
}

/* Custom Table Styling to match request */
.table thead th {
    background-color: #4f81c9 !important; /* Blue header */
    color: white !important;
}

/* Alert Visibility Improvements */
.alert-success {
    background-color: #d4edda !important;
    border-color: #c3e6cb !important;
    color: #155724 !important;
    font-weight: 600;
}

.alert-danger {
    background-color: #f8d7da !important;
    border-color: #f5c6cb !important;
    color: #721c24 !important;
    font-weight: 600;
}

.alert-info {
    background-color: #d1ecf1 !important;
    border-color: #bee5eb !important;
    color: #0c5460 !important;
    font-weight: 600;
}
    color: #ffffff !important;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    border-bottom: none;
    padding: 6px 8px;
    vertical-align: middle;
}

.table tbody tr:nth-of-type(odd) {
    background-color: #f2f8fd !important; /* Light blue stripe */
}

.table tbody tr:nth-of-type(even) {
    background-color: #ffffff !important;
}

.table tbody tr:hover {
    background-color: #e2e6ea !important;
}

.table td {
    vertical-align: middle;
    font-size: 0.85rem;
    padding: 4px 8px;
    border-color: #e3e6f0;
    color: #5a5c69;
}

.table {
    border: 1px solid #e3e6f0;
    margin-bottom: 0;
}

/* DataTables Pagination Customization */
.page-item.active .page-link {
    background-color: #4f81c9 !important;
    border-color: #4f81c9 !important;
}

.page-link {
    color: #4f81c9 !important;
}

.page-link:focus {
    box-shadow: 0 0 0 0.25rem rgba(79, 129, 201, 0.25);
}

/* DataTables Filter & Length */
.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
    border-color: #4f81c9;
    box-shadow: 0 0 0 0.25rem rgba(79, 129, 201, 0.25);
}

/* Footer Styling */
.app-footer {
    transition: left .25s ease-out;
}

@media (min-width: 768px) {
    .app-footer {
        left: 16rem;
    }
    
    body.sb-sidenav-toggled .app-footer {
        left: 0;
    }
}

/* Dashboard Cards */
.card {
    border-top: 3px solid #4f81c9;
}

.card-header {
    background-color: #fff;
    border-bottom: 1px solid #e3e6f0;
}

.card-header h6 {
    color: #4f81c9 !important;
    font-weight: 700 !important;
}

.text-primary {
    color: #4f81c9 !important; /* Override primary blue to green */
}

.bg-primary {
    background-color: #4f81c9 !important;
}

.btn-primary {
    background-color: #4f81c9 !important;
    border-color: #4f81c9 !important;
}

.btn-primary:hover {
    background-color: #3e6db0 !important;
    border-color: #4cae4c !important;
}

/* Global Header Sizing Override - Minimized */
h1, .h1 { font-size: 1.5rem !important; }
h2, .h2 { font-size: 1.25rem !important; }
h3, .h3 { font-size: 1.1rem !important; }
h4, .h4 { font-size: 1rem !important; }
h5, .h5 { font-size: 0.9rem !important; }
h6, .h6 { font-size: 0.8rem !important; }

.card-title { font-size: 1rem !important; }
.modal-title { font-size: 1.1rem !important; }
