:root {
    --primary-color: #0d6efd;
    --primary-hover: #0b5ed7;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f5f5;
    color: #333;
}

a {
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    text-decoration: none;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.alert {
    border-radius: 0.25rem;
}

/* Sidebar styles */
.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 48px 0 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, 0.1);
    background-color: #fff;
}

.sidebar-sticky {
    position: relative;
    top: 0;
    height: calc(100vh - 48px);
    padding-top: 0.5rem;
    overflow-x: hidden;
    overflow-y: auto;
}

.sidebar .nav-link {
    font-weight: 500;
    color: #333;
    padding: 0.75rem 1rem;
    border-left: 3px solid transparent;
}

.sidebar .nav-link:hover {
    color: var(--primary-color);
    background-color: rgba(13, 110, 253, 0.1);
}

.sidebar .nav-link.active {
    color: var(--primary-color);
    background-color: rgba(13, 110, 253, 0.1);
    border-left: 3px solid var(--primary-color);
}

.sidebar .nav-link i {
    margin-right: 4px;
    color: var(--secondary-color);
}

.sidebar .nav-link.active i {
    color: var(--primary-color);
}

/* Table styles */
.table th {
    background-color: var(--primary-color);
    color: white;
}

.table-hover tbody tr:hover {
    background-color: rgba(13, 110, 253, 0.05);
}

img {
    max-width: 100%;
    height: auto;
}

@media (max-width: 991.98px) {
    .container,
    .container-fluid {
        padding-left: 12px;
        padding-right: 12px;
    }

    .table {
        font-size: 0.92rem;
    }

    .btn-group {
        flex-wrap: wrap;
        gap: 0.35rem;
    }

    .btn-group .btn {
        border-radius: 0.375rem !important;
    }
}

@media (max-width: 767.98px) {
    .card-body {
        padding: 1rem;
    }

    .table-responsive {
        border: 0;
    }

    .table th,
    .table td {
        white-space: normal;
        vertical-align: middle;
    }

    .d-grid .btn,
    .btn {
        min-height: 42px;
    }

    .display-4 {
        font-size: 1.8rem;
    }

    h1, .h1 {
        font-size: 1.5rem;
    }

    h2, .h2 {
        font-size: 1.3rem;
    }

    h3, .h3 {
        font-size: 1.15rem;
    }

    .row {
        --bs-gutter-x: 0.9rem;
    }

    .sticky-top {
        position: static !important;
        top: auto !important;
    }

    .input-group {
        flex-wrap: nowrap;
    }

    .alert {
        font-size: 0.93rem;
    }
}