/* ==========================================================================
   JetBrains Mono & Custom Palette Theme
   - Font: JetBrains Mono
   - Black / Navy: #0F172A
   - Blue (Primary): #305CDE
   - White: #ffffff (Retained)
   ========================================================================== */

:root,
[data-bs-theme="light"],
[data-bs-theme="dark"] {
    --bs-font-sans-serif: 'JetBrains Mono', monospace !important;
    --bs-font-monospace: 'JetBrains Mono', monospace !important;
    --bs-body-font-family: 'JetBrains Mono', monospace !important;
    font-family: 'JetBrains Mono', monospace !important;

    /* Primary Accent Blue */
    --bs-primary: #305CDE !important;
    --bs-primary-rgb: 48, 92, 222 !important;
    --bs-primary-active: #2448b8 !important;
    --bs-primary-hover: #264bba !important;
    --bs-primary-light: #eff3fe !important;
    --bs-primary-inverse: #ffffff !important;
    --bs-link-color: #305CDE !important;
    --bs-link-hover-color: #2448b8 !important;
    --bs-link-color-rgb: 48, 92, 222 !important;
    --bs-primary-bg-subtle: #eff3fe !important;
    --bs-primary-border-subtle: #b6c7f8 !important;
    --bs-primary-text-emphasis: #1e3a96 !important;

    /* Dark / Navy */
    --bs-dark: #0F172A !important;
    --bs-dark-rgb: 15, 23, 42 !important;
    --bs-heading-color: #0F172A !important;
    --bs-dark-text-emphasis: #0F172A !important;
}

/* Global Font Override */
body,
input,
button,
select,
textarea,
optgroup,
.form-control,
.form-select,
.btn,
.card,
.card-title,
.card-header,
.menu-title,
.menu-link,
.menu-content,
.badge,
.table,
.table th,
.table td,
.breadcrumb,
.breadcrumb-item,
.modal-title,
.modal-content,
.dropdown-menu,
.dropdown-item,
.nav-link,
.tooltip,
.popover,
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'JetBrains Mono', monospace !important;
}

/* Headings and Dark Elements */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
.text-dark {
    color: #0F172A !important;
}

.bg-dark {
    background-color: #0F172A !important;
}

/* Primary Color Overrides */
.text-primary,
a.text-primary {
    color: #305CDE !important;
}

.text-hover-primary:hover,
a.text-hover-primary:hover,
.text-hover-primary:hover .text-dark {
    color: #305CDE !important;
}

.link-primary {
    color: #305CDE !important;
}
.link-primary:hover,
.link-primary:focus {
    color: #2448b8 !important;
}

.bg-primary {
    background-color: #305CDE !important;
}

.bg-light-primary {
    background-color: #eff3fe !important;
}

.border-primary {
    border-color: #305CDE !important;
}

/* Buttons */
.btn-primary {
    color: #ffffff !important;
    border-color: #305CDE !important;
    background-color: #305CDE !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-primary.active,
.show > .btn-primary.dropdown-toggle {
    color: #ffffff !important;
    border-color: #2448b8 !important;
    background-color: #2448b8 !important;
}

.btn-check:checked + .btn.btn-primary,
.btn-check:active + .btn.btn-primary {
    color: #ffffff !important;
    border-color: #2448b8 !important;
    background-color: #2448b8 !important;
}

.btn-light-primary {
    color: #305CDE !important;
    border-color: transparent !important;
    background-color: #eff3fe !important;
}

.btn-light-primary:hover,
.btn-light-primary:focus,
.btn-light-primary:active,
.btn-light-primary.active {
    color: #ffffff !important;
    border-color: #305CDE !important;
    background-color: #305CDE !important;
}

.btn-active-light-primary:hover,
.btn-active-light-primary:active,
.btn-active-light-primary.active {
    color: #305CDE !important;
    background-color: #eff3fe !important;
}

.btn-outline.btn-outline-primary {
    color: #305CDE !important;
    border-color: #305CDE !important;
}

.btn-outline.btn-outline-primary:hover,
.btn-outline.btn-outline-primary:active,
.btn-outline.btn-outline-primary.active {
    color: #ffffff !important;
    background-color: #305CDE !important;
    border-color: #305CDE !important;
}

/* Form Controls & Focus States */
.form-control:focus,
.form-select:focus {
    border-color: #305CDE !important;
    box-shadow: 0 0 0 0.25rem rgba(48, 92, 222, 0.2) !important;
}

.form-check-input:checked {
    background-color: #305CDE !important;
    border-color: #305CDE !important;
}

.form-check-input:focus {
    border-color: #305CDE !important;
    box-shadow: 0 0 0 0.25rem rgba(48, 92, 222, 0.2) !important;
}

/* Badges */
.badge-primary {
    color: #ffffff !important;
    background-color: #305CDE !important;
}

.badge-light-primary {
    color: #305CDE !important;
    background-color: #eff3fe !important;
}

/* Bullets */
.bullet.bg-primary {
    background-color: #305CDE !important;
}

/* Menu & Sidebar Active / Hover States */
.menu-state-primary .menu-item.hover:not(.here) > .menu-link:not(.disabled):not(.active):not(.here) .menu-title,
.menu-state-primary .menu-item:not(.here) > .menu-link:hover:not(.disabled):not(.active):not(.here) .menu-title {
    color: #305CDE !important;
}

.menu-state-primary .menu-item.hover:not(.here) > .menu-link:not(.disabled):not(.active):not(.here) .menu-icon,
.menu-state-primary .menu-item:not(.here) > .menu-link:hover:not(.disabled):not(.active):not(.here) .menu-icon {
    color: #305CDE !important;
}

.menu-state-primary .menu-item .menu-link.active {
    color: #305CDE !important;
    background-color: #eff3fe !important;
}

.menu-state-primary .menu-item .menu-link.active .menu-title {
    color: #305CDE !important;
    font-weight: 600 !important;
}

.menu-state-primary .menu-item .menu-link.active .menu-icon,
.menu-state-primary .menu-item .menu-link.active .menu-icon i {
    color: #305CDE !important;
}

.menu-state-primary .menu-item .menu-link.active .menu-bullet .bullet {
    background-color: #305CDE !important;
}

.menu-item.show > .menu-link > .menu-title,
.menu-item.show > .menu-link > .menu-icon,
.menu-item.show > .menu-link > .menu-icon i {
    color: #305CDE !important;
}

/* Pagination */
.page-item.active .page-link {
    background-color: #305CDE !important;
    border-color: #305CDE !important;
    color: #ffffff !important;
}

.page-link:hover {
    color: #305CDE !important;
}

/* Tabs */
.nav-line-tabs .nav-item .nav-link.active,
.nav-line-tabs .nav-item .nav-link:hover {
    color: #305CDE !important;
    border-bottom-color: #305CDE !important;
}

.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
    background-color: #305CDE !important;
    color: #ffffff !important;
}

/* Progress bar */
.progress-bar.bg-primary {
    background-color: #305CDE !important;
}

/* Scroll top */
#kt_scrolltop {
    background-color: #305CDE !important;
}

#kt_scrolltop:hover {
    background-color: #2448b8 !important;
}

/* Toastr notifications */
.toast-primary,
#toast-container > .toast-info {
    background-color: #305CDE !important;
}
