/* Inter — loaded from cdn.jsdelivr.net (Fontsource), which the CSP
   already whitelists. The family is named "Inter Variable", so a broken
   locally-installed "Inter" can never be matched by mistake. */
:root,
[data-bs-theme="light"] {
    --bs-body-bg: #FAF9F5;
    --bs-body-font-family: "Inter Variable", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

body {
    font-family: var(--bs-body-font-family);
    font-style: normal;
    background-color: #FAF9F5;
}

/* The ivory (#FAF9F5) is the PAGE background only. Surfaces sitting on
   top of it stay pure white for contrast — in Bootstrap 5.3 these all
   inherit --bs-body-bg unless overridden here. */
.table {
    --bs-table-bg: #ffffff;
}

.card {
    --bs-card-bg: #ffffff;
}

.modal {
    --bs-modal-bg: #ffffff;
}

.dropdown-menu {
    --bs-dropdown-bg: #ffffff;
}

.list-group {
    --bs-list-group-bg: #ffffff;
}

.accordion {
    --bs-accordion-bg: #ffffff;
}

.pagination {
    --bs-pagination-bg: #ffffff;
}

.form-control,
.form-select {
    background-color: #ffffff;
}

#sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    flex-shrink: 0;
    min-width: 260px;
    z-index: 100;
    background-color: #ffffff;
}

#sidebar .nav-link {
    color: #495057;
    border-radius: 0.375rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
}

#sidebar .nav-link:hover {
    color: #000;
    background-color: rgba(0, 0, 0, 0.05);
}

#sidebar .nav-link.active {
    color: #0d6efd;
    background-color: rgba(13, 110, 253, 0.1);
    font-weight: 500;
}

/* Prevent main content from pushing sidebar off-screen */
main.flex-grow-1 {
    min-width: 0;
    overflow-x: hidden;
}

.table-truncate {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.toast-container .toast {
    min-width: 300px;
}

tr.htmx-swapping {
    opacity: 0;
    transition: opacity 0.3s ease-out;
}

.progress {
    border-radius: 0.5rem;
}
