/* =========================================================
   THEME TOKENS & ROOT VARIABLES
   ========================================================= */
:root {
    /* Bootstrap core theme vars */
    --bs-primary: #c8681f;
    --bs-primary-rgb: 200, 104, 31;

    --bs-secondary: #5f5a53;
    --bs-secondary-rgb: 95, 90, 83;

    --bs-body-bg: #f6f2eb;
    --bs-body-color: #22211f;

    --bs-link-color: #a95517;
    --bs-link-hover-color: #793b0e;

    /* Brand vars */
    --brand-navy: #202326;
    --brand-navy-soft: #e7e0d6;
    --brand-navy-light: #d8d0c4;
    --brand-accent: #c8681f;

    --card-border-light: #d8d0c4;
    --theme-primary-hover: #a65317;
    --theme-secondary-hover: #48443f;

    /* Theme tokens – default = light mode */
    color-scheme: light;
    --theme-bg: #f6f2eb;
    --theme-surface: #fffdf8;
    --theme-text: #22211f;
    --theme-muted: #6f6a62;

    --theme-card-header-bg: #fffdf9;
    --theme-card-header-bg2: var(--brand-navy-soft);

    --theme-border: #d8d0c4;
    --theme-navbar-bg: var(--brand-navy);
    --theme-subtle: #eee7dd;
    --theme-row-alt: #f7f2ea;
    --theme-row-hover: #eee5d8;
    --theme-table-head-bg: #ece4d8;
    --theme-table-head-text: #2d2924;
    --theme-table-border: #d8d0c4;
}

/* Dark Mode overrides */
:root.dark-mode {
    color-scheme: dark;

    --bs-primary: #d98b3a;
    --bs-primary-rgb: 217, 139, 58;
    --bs-secondary: #a9a39a;
    --bs-secondary-rgb: 169, 163, 154;
    --bs-body-bg: #171717;
    --bs-body-color: #eee9df;
    --bs-link-color: #e0a15e;
    --bs-link-hover-color: #f0bc7d;

    --brand-navy: #121212;
    --brand-navy-soft: #242424;
    --brand-navy-light: #3b3935;
    --brand-accent: #d98b3a;
    --theme-primary-hover: #be7128;
    --theme-secondary-hover: #8e877e;

    --theme-bg: #171717;
    --theme-surface: #222120;
    --theme-text: #eee9df;
    --theme-muted: #aca59c;

    --theme-card-header-bg: #222120;
    --theme-card-header-bg2: #2b2926;

    --theme-border: #3b3935;
    --theme-navbar-bg: #111111;
    --theme-subtle: #2a2927;
    --theme-row-alt: #262522;
    --theme-row-hover: #312e2a;
    --theme-table-head-bg: #302e2b;
    --theme-table-head-text: #f4efe7;
    --theme-table-border: #45413a;
}

/* =========================================================
   BASE LAYOUT
   ========================================================= */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: var(--theme-bg);
    color: var(--theme-text);
}

main {
    flex: 1 0 auto;
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

/* Keep dashboard area tall so cards can stretch */
#dashboard-content {
    min-height: calc(100vh - 80px);
}

/* Global link styles */
a { color: var(--bs-link-color); }
a:hover {
    color: var(--bs-link-hover-color);
    text-decoration: underline;
}

/* Smaller text utility for dense content */
.text-xs { font-size: 0.8rem; }

/* Muted text */
.text-muted,
small,
.form-text {
    color: var(--theme-muted) !important;
}

/* =========================================================
   NAVBAR
   ========================================================= */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1040;
    background: var(--theme-navbar-bg) !important;
    border-bottom: 1px solid rgba(0,0,0,0.22);
}

.navbar .navbar-brand,
.navbar .nav-link,
.navbar .navbar-text {
    color: #ffffff !important;
}

.navbar .navbar-brand {
    margin-right: 0;
    padding-top: 0;
    padding-bottom: 0;
}

.navbar .nav-link.active {
    color: var(--brand-accent) !important;
    font-weight: 600;
}

.navbar .nav-link:hover,
.navbar .nav-link:focus {
    color: #ffd6a3 !important;
}

.navbar .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.4) !important;
}

.navbar .navbar-toggler-icon { filter: invert(1); }

/* =========================================================
   MOBILE SEARCH PANEL (lightweight, no modal)
   ========================================================= */
.mobile-search-panel {
    position: sticky;
    top: 56px;              /* matches navbar height */
    z-index: 1035;          /* below navbar (1040), above content */
    background-color: var(--theme-navbar-bg);
    border-bottom: 1px solid rgba(0,0,0,0.15);
}

/* Optional: slightly tighter on mobile */
.mobile-search-panel .input-group {
    height: 34px;
}


/* =========================================================
   BUTTONS / BADGES
   ========================================================= */
.btn-primary {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--bs-primary);
    --bs-btn-border-color: var(--bs-primary);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--theme-primary-hover);
    --bs-btn-hover-border-color: var(--theme-primary-hover);
    --bs-btn-focus-shadow-rgb: var(--bs-primary-rgb);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--theme-primary-hover);
    --bs-btn-active-border-color: var(--theme-primary-hover);
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
}
.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--theme-primary-hover) !important;
    border-color: var(--theme-primary-hover) !important;
}

.btn-outline-primary {
    --bs-btn-color: var(--bs-primary);
    --bs-btn-border-color: var(--bs-primary);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--bs-primary);
    --bs-btn-hover-border-color: var(--bs-primary);
    --bs-btn-focus-shadow-rgb: var(--bs-primary-rgb);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--bs-primary);
    --bs-btn-active-border-color: var(--bs-primary);
    --bs-btn-disabled-color: var(--bs-primary);
    --bs-btn-disabled-border-color: var(--bs-primary);
    color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active,
.btn-outline-primary.active,
.show > .btn-outline-primary.dropdown-toggle {
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
    color: #fff !important;
}

.btn-check:checked + .btn-outline-primary,
.btn-check:active + .btn-outline-primary {
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
    color: #fff !important;
}

.btn-link,
.text-primary {
    color: rgba(var(--bs-primary-rgb), var(--bs-text-opacity, 1)) !important;
}

.btn-link:hover,
.btn-link:focus {
    color: var(--bs-link-hover-color) !important;
}

.bg-primary {
    background-color: rgba(var(--bs-primary-rgb), var(--bs-bg-opacity, 1)) !important;
}

.border-primary {
    border-color: rgba(var(--bs-primary-rgb), var(--bs-border-opacity, 1)) !important;
}

.link-primary,
.page-link {
    color: var(--bs-primary) !important;
}

.page-link:hover,
.page-link:focus {
    color: var(--bs-link-hover-color) !important;
}

.active > .page-link,
.page-link.active,
.dropdown-item.active,
.dropdown-item:active,
.nav-pills .nav-link.active,
.list-group-item.active {
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
    color: #fff !important;
}

.form-check-input:checked {
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
}

.form-check-input:focus {
    border-color: rgba(var(--bs-primary-rgb), 0.56) !important;
    box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.16) !important;
}

.btn-secondary {
    background-color: var(--bs-secondary) !important;
    border-color: var(--bs-secondary) !important;
}
.btn-secondary:hover,
.btn-secondary:focus {
    background-color: var(--theme-secondary-hover) !important;
    border-color: var(--theme-secondary-hover) !important;
}

.btn-outline-secondary {
    color: var(--theme-text);
    border-color: var(--theme-border);
}
.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
    background-color: var(--theme-subtle);
    color: var(--theme-text);
}

:root.dark-mode .btn-outline-dark {
    color: var(--theme-text);
    border-color: #57534d;
}

:root.dark-mode .btn-outline-dark:hover,
:root.dark-mode .btn-outline-dark:focus {
    background-color: var(--theme-subtle);
    color: var(--theme-text);
}

.badge.bg-primary { background-color: var(--bs-primary) !important; }
.badge.bg-secondary { background-color: var(--bs-secondary) !important; }

/* =========================================================
   CARDS
   ========================================================= */
.card {
    display: block;
    min-height: 0;
    background-color: var(--theme-surface) !important;
    border-color: var(--theme-border) !important;
    border-radius: 8px;
    box-shadow: 0 10px 24px rgba(28, 31, 27, 0.07);
}

:root.dark-mode .card {
    box-shadow: 0 12px 28px rgba(0,0,0,0.22);
}

.card-body {
    flex: none;
    min-height: 0;
    max-height: none;
    overflow-y: visible;
}

.card-header {
    background: var(--theme-card-header-bg) !important;
    color: var(--theme-text) !important;
    font-weight: 600;
    border-bottom: 1px solid var(--theme-border);
    padding: 0.6rem 1rem;
}

.card-header .small { opacity: 0.9; }

.card-footer {
    background-color: transparent;
    border-top: 0;
    padding: 0.5rem 1rem 0.75rem;
}

.dashboard-row { align-items: stretch; }

/* =========================================================
   TABLES
   ========================================================= */
.table-sm th,
.table-sm td {
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

.table td,
.table th {
    font-size: 0.85rem !important;
    padding: 0.2rem 0.3rem !important;
}

.table {
    --bs-table-bg: var(--theme-surface);
    --bs-table-color: var(--theme-text);
    --bs-table-border-color: var(--theme-table-border);
    --bs-table-striped-bg: var(--theme-row-alt);
    --bs-table-striped-color: var(--theme-text);
    --bs-table-hover-bg: var(--theme-row-hover);
    --bs-table-hover-color: var(--theme-text);
    color: var(--theme-text) !important;
    border-color: var(--theme-table-border) !important;
}

.table > :not(caption) > * > * {
    border-color: var(--theme-table-border) !important;
    color: var(--theme-text) !important;
}

.table thead th {
    background: var(--theme-table-head-bg) !important;
    color: var(--theme-table-head-text) !important;
    border-color: var(--theme-table-border) !important;
    box-shadow: inset 0 -1px 0 rgba(0,0,0,0.08);
}

.table-striped > tbody > tr:nth-of-type(odd) > * {
    --bs-table-accent-bg: var(--theme-row-alt) !important;
    background-color: var(--theme-row-alt) !important;
    color: var(--theme-text) !important;
}

.table-striped > tbody > tr:nth-of-type(even) > * {
    --bs-table-accent-bg: var(--theme-surface) !important;
    background-color: var(--theme-surface) !important;
    color: var(--theme-text) !important;
}

.table-hover > tbody > tr:hover > * {
    --bs-table-accent-bg: var(--theme-row-hover) !important;
    background-color: var(--theme-row-hover) !important;
    color: var(--theme-text) !important;
}

.dataTables_wrapper,
.dt-container,
.dataTables_info,
.dt-info,
.dataTables_length,
.dt-length,
.dataTables_filter,
.dt-search {
    color: var(--theme-muted) !important;
}

.dataTables_wrapper .dataTables_filter input,
.dt-container .dt-search input,
.dataTables_wrapper .dataTables_length select,
.dt-container .dt-length select {
    background: var(--theme-surface) !important;
    border-color: var(--theme-border) !important;
    color: var(--theme-text) !important;
}

.dt-button,
button.dt-button,
.dataTables_wrapper .dataTables_paginate .paginate_button,
.dt-container .dt-paging .dt-paging-button {
    border: 1px solid var(--theme-border) !important;
    border-radius: 6px !important;
    background: var(--theme-surface) !important;
    color: var(--theme-text) !important;
    box-shadow: none !important;
}

.dt-button:hover,
button.dt-button:hover,
.dataTables_wrapper .dataTables_paginate .paginate_button:hover,
.dt-container .dt-paging .dt-paging-button:hover {
    background: var(--theme-subtle) !important;
    border-color: rgba(var(--bs-primary-rgb),0.48) !important;
    color: var(--theme-text) !important;
}

/* =========================================================
   FORM ELEMENTS
   ========================================================= */
.form-control,
.form-select,
textarea.form-control {
    border-radius: 8px !important;
    padding: 0.25rem 0.45rem !important;
    border: 1px solid var(--theme-border) !important;
    background-color: var(--theme-surface) !important;
    color: var(--theme-text) !important;
    box-shadow: none;
    transition: all .18s ease;
}

.form-control:hover,
.form-select:hover,
textarea.form-control:hover {
    border-color: rgba(var(--bs-primary-rgb),0.42) !important;
}

.form-control::placeholder,
textarea.form-control::placeholder {
    color: var(--theme-muted) !important;
    opacity: 0.78;
}

.form-control:focus,
.form-select:focus,
textarea.form-control:focus {
    border-color: var(--bs-primary) !important;
    box-shadow: 0 0 0 3px rgba(var(--bs-primary-rgb), 0.16) !important;
}

:root.dark-mode .form-control,
:root.dark-mode .form-select,
:root.dark-mode textarea {
    background-color: var(--theme-surface) !important;
    border-color: var(--theme-border) !important;
    color: var(--theme-text) !important;
}

/* Accent rule before labels */
.form-label {
    position: relative;
    padding-left: 8px;
    font-weight: 500;
}
.form-label::before {
    content: "";
    position: absolute;
    left: 0;
    top: 3px;
    bottom: 3px;
    width: 3px;
    background-color: var(--bs-primary);
    border-radius: 1px;
}

/* =========================================================
   DARK MODE – COMPONENT TEXT FIXES
   ========================================================= */
:root.dark-mode body { color: var(--theme-text) !important; }

:root.dark-mode .card,
:root.dark-mode .card-body,
:root.dark-mode .table,
:root.dark-mode .accordion-button,
:root.dark-mode .modal-content,
:root.dark-mode .modal-header,
:root.dark-mode .modal-body,
:root.dark-mode .modal-footer,
:root.dark-mode .nav-link,
:root.dark-mode .navbar-brand,
:root.dark-mode .navbar-text,
:root.dark-mode label,
:root.dark-mode .form-label,
:root.dark-mode .form-check-label {
    color: var(--theme-text) !important;
}

.accordion-item {
    background-color: var(--theme-surface) !important;
    border-color: var(--theme-border) !important;
}

.accordion-button {
    background-color: var(--theme-surface) !important;
    color: var(--theme-text) !important;
}

.accordion-button:not(.collapsed) {
    background-color: rgba(var(--bs-primary-rgb),0.12) !important;
    color: var(--theme-text) !important;
    box-shadow: inset 0 -1px 0 var(--theme-border);
}

/* =========================================================
   SLIM SIDEBAR (NAMESPACED)
   ========================================================= */
.lumea-side-nav {
    position: fixed;
    top: 48px;
    bottom: 0;
    left: 0;
    width: 64px;
    background: var(--theme-navbar-bg);
    color: #fff;
    overflow-x: hidden;
    overflow-y: auto;
    z-index: 1020;
    transition: width .25s ease, left .25s ease;

    /* allow footer to sit at bottom */
    display: flex;
    flex-direction: column;
}

/* Desktop: expand on hover */
@media (min-width: 992px) {
    .lumea-side-nav:hover { width: 220px; }

    /* Push main content so it doesn't sit under the sidebar */
    body.has-side-nav main.container-fluid { padding-left: 74px; }
}

/* Mobile: off-canvas style */
@media (max-width: 991.98px) {
    .lumea-side-nav {
        top: 48px;
        left: -220px;
        width: 220px;
    }
    .lumea-side-nav.open { left: 0; }
}

.lumea-side-nav-logo {
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    background-color: rgba(0,0,0,0.16);
    padding: 0.75rem 0.9rem 0.6rem;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.lumea-side-nav-logo-img {
    display: block;
    width: 112px;
    max-width: 100%;
    height: auto;
    opacity: 0.88;
}

.lumea-side-nav-menu {
    list-style: none;
    margin: 0;
    padding: 0 0.5rem 1rem;

    /* fill space so footer pins at bottom */
    flex: 1 1 auto;
}

.lumea-side-nav-menu li { margin-bottom: 0.25rem; }

.lumea-side-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.2rem 0.8rem;
    border-radius: 0.55rem;
    color: rgba(255,255,255,0.72);
    font-size: 0.9rem;
    white-space: nowrap;
}

.lumea-side-nav .nav-link .bi {
    font-size: 1.2rem;
    width: 1.5rem;
    text-align: center;
}

.lumea-side-nav .nav-link:hover {
    background-color: rgba(var(--bs-primary-rgb),0.16);
    color: #ffffff;
    text-decoration: none;
}

.lumea-side-nav .nav-link.active {
    background-color: rgba(var(--bs-primary-rgb),0.22);
    color: #ffffff;
    box-shadow: inset 3px 0 0 var(--brand-accent);
}

/* Labels hidden in collapsed desktop state, visible on hover & mobile */
.lumea-side-nav-label {
    opacity: 0;
    max-width: 0;
    overflow: hidden;
    transition: opacity .25s ease, max-width .25s ease;
}
@media (min-width: 992px) {
    .lumea-side-nav:hover .lumea-side-nav-label {
        opacity: 1;
        max-width: 160px;
    }
}
@media (max-width: 991.98px) {
    .lumea-side-nav .lumea-side-nav-label {
        opacity: 1;
        max-width: 160px;
    }
}

/* ---------- SIDE NAV SUBMENUS ---------- */
.lumea-side-nav-menu li.has-submenu { position: relative; }

/* Submenu container: hidden by default */
.lumea-side-nav-submenu {
    list-style: none;
    margin: 0 0 0 2.2rem;
    padding: 0;                    /* important: avoids extra gap under Orders */
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height .2s ease, opacity .2s ease;
}

/* Mobile: submenu opens normally */
@media (max-width: 991.98px) {
    .lumea-side-nav-menu li.has-submenu.submenu-open > .lumea-side-nav-submenu {
        max-height: 500px;
        opacity: 1;
        padding-bottom: 0.35rem;  /* spacing only when visible */
    }
}

/* Desktop: submenu only visible while sidebar is hovered */
@media (min-width: 992px) {
    .lumea-side-nav:hover
    .lumea-side-nav-menu li.has-submenu.submenu-open
    > .lumea-side-nav-submenu {
        max-height: 500px;
        opacity: 1;
        padding-bottom: 0.35rem;  /* spacing only when visible */
    }
}

/* Submenu items */
.nav-link-sub {
    font-size: 0.8rem;
    padding: 0.3rem 0.6rem 0.3rem 2.1rem;
    color: #c9c8c1;
    width: 100%;
    border-radius: 0.55rem;
}
.nav-link-sub:hover {
    background-color: rgba(255,255,255,0.08);
    color: #ffffff;
}

/* Caret icon on parents */
.submenu-caret {
    font-size: 0.7rem;
    transition: transform .2s ease;
}
.lumea-side-nav-menu li.has-submenu.submenu-open .submenu-caret {
    transform: rotate(90deg);
}

/* Sidebar footer */
.lumea-side-nav-footer {
    margin-top: auto;
    padding: 0.5rem;
    border-top: 1px solid rgba(255,255,255,0.08);
}
.lumea-side-nav-action {
    width: 100%;
    cursor: pointer;
    background: transparent;
    border: 0;
    text-align: left;
}

/* =========================================================
   NAVBAR SEARCH BAR
   ========================================================= */
.navbar-search {
    max-width: 380px;
    width: 100%;
}

.navbar-search .input-group {
    max-height: 32px;
    height: 30px;
}

.navbar-search .form-control {
    border-radius: 0 !important;
    background-color: var(--theme-surface) !important;
    border: 1px solid var(--theme-border) !important;
    color: var(--theme-text) !important;
    font-size: 0.85rem;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

/* Leftmost input */
.navbar-search .form-control:first-child {
    border-top-left-radius: 8px !important;
    border-bottom-left-radius: 8px !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

/* Middle input (date) */
.navbar-search .form-control:nth-child(2) {
    border-radius: 0 !important;
}

.navbar-search .btn {
    border-radius: 0;
    font-size: 0.85rem;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

.navbar-search .btn-calendar {
    background-color: var(--bs-secondary);
    border-color: var(--bs-secondary);
    color: #ffffff;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}
.navbar-search .btn-calendar:hover {
    background-color: var(--theme-secondary-hover);
    border-color: var(--theme-secondary-hover);
}

.navbar-search .btn-search {
    background-color: var(--brand-accent);
    border-color: var(--brand-accent);
    color: #ffffff;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}
.navbar-search .btn-search:hover { filter: brightness(0.9); }

/* Dark mode: navbar search readability */
:root.dark-mode .navbar-search .form-control {
    background-color: var(--theme-surface) !important;
    border-color: var(--theme-border) !important;
    color: var(--theme-text) !important;
}
:root.dark-mode .navbar-search .form-control::placeholder {
    color: var(--theme-muted) !important;
    opacity: 1;
}
:root.dark-mode .navbar-search .btn-calendar {
    background-color: var(--bs-secondary);
    border-color: var(--bs-secondary);
}

/* Small screens: hide search */
@media (max-width: 767.98px) {
    .navbar-search { display: none !important; }
}

/* =========================================================
   FOOTER
   ========================================================= */
.lumea-footer {
    background: var(--theme-card-header-bg2);
    color: #514b43;
    border-top: 1px solid #d1c8bb;
    margin-top: auto;
}

:root.dark-mode .lumea-footer {
    background: #1f1e1d;
    color: #d7d0c5;
    border-top-color: #38342f;
}

.footer-logo {
    width: 200px;
    height: 40px;
    background-color: #000;
    background-image: url("https://d2lefosf1l6ns5.cloudfront.net/HidcotAI/img/hidcotAILogoSmall_v3_alt.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 90% auto;
    border-radius: 6px;
}

.footer-text { font-size: 0.8rem; }

.lumea-footer .footer-left,
.lumea-footer .footer-right,
.lumea-footer .text-muted {
    color: #514b43 !important;
}

:root.dark-mode .lumea-footer .footer-left,
:root.dark-mode .lumea-footer .footer-right,
:root.dark-mode .lumea-footer .text-muted {
    color: #d7d0c5 !important;
}

/* Offset to clear slim sidebar */
body.has-side-nav .lumea-footer .container-fluid { padding-left: 74px; }

/* Lumea Logo */
.lumea-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.1rem 0;
    line-height: 1;
    flex-shrink: 0;
}

.lumea-logo::before {
    content: "";
    width: 0.78rem;
    height: 0.78rem;
    background-color: var(--brand-accent);
    border-radius: 1px;
    flex: 0 0 auto;
}

.lumea-logo-img {
    display: block;
    width: 110px;
    max-width: 100%;
    height: auto;
}

@media (max-width: 767.98px) {
    .lumea-logo-img {
        width: 98px;
    }

    .lumea-side-nav-logo-img {
        width: 104px;
    }
}

/* =========================================================
   HOME SCREEN / PREFIRE PANELS
   ========================================================= */
.home-dashboard {
    font-size: 0.92rem;
}

.home-title {
    font-size: 1.35rem;
    font-weight: 700;
}

.home-refresh-form {
    align-self: flex-start;
    background: var(--theme-surface);
    border: 1px solid var(--theme-border);
    border-radius: 8px;
    padding: 0.55rem 0.8rem;
}

.home-dashboard h4.text-primary {
    font-size: 1rem;
    font-weight: 700;
    margin: 0.4rem 0 0.65rem;
}

.home-dashboard .accordion-item {
    background: var(--theme-surface);
    border-color: var(--theme-border);
}

.home-dashboard .accordion-button {
    min-height: 38px;
    height: auto !important;
    background: var(--theme-surface);
    color: var(--theme-text);
    font-size: 0.88rem !important;
    padding: 0.45rem 0.75rem;
}

.home-dashboard .accordion-button:not(.collapsed) {
    color: var(--theme-text);
    background: rgba(var(--bs-primary-rgb), 0.12);
    box-shadow: inset 0 -1px 0 var(--theme-border);
}

.home-dashboard .accordion-button.is-alerting,
.home-dashboard .accordion-button.bg-warning {
    background: #f2b84b !important;
    color: #2d2924 !important;
}

.home-dashboard .accordion-body {
    background: var(--theme-surface);
    color: var(--theme-text);
    padding: 0.8rem;
}

.home-dashboard .table-responsive {
    border-radius: 8px;
}

.home-dashboard .table-bordered > :not(caption) > * {
    border-color: var(--theme-border);
}

.home-dashboard .clickable-row {
    cursor: pointer;
}

.home-dashboard .clickable-row:hover > * {
    filter: brightness(0.98);
}

.home-dashboard .card {
    border-radius: 8px;
    overflow: hidden;
}

.home-dashboard .card-header a {
    text-decoration: none;
}

.home-dashboard .filterBtn {
    border-radius: 8px;
}

.home-dashboard .filterBtn > span.text-white:not(.rounded-circle) {
    color: var(--theme-text) !important;
}

.home-dashboard .overflow-auto {
    scrollbar-width: thin;
}

.bg-custom-red {
    background-color: #bd2f2f !important;
    color: #fff !important;
}

.bg-custom-magenta {
    background-color: #9f3eb2 !important;
    color: #fff !important;
}

.bg-custom-amber {
    background-color: var(--brand-accent) !important;
    color: #fff !important;
}

.bg-custom-green {
    background-color: #2f7d46 !important;
    color: #fff !important;
}

.bg-custom-yellow {
    background-color: #f5d35f !important;
    color: #2d2924 !important;
}

.bg-custom-pending {
    background-color: #4f6770 !important;
    color: #fff !important;
}

.weatherWarningStageOne,
.weatherWarningStageTwo,
.weatherWarningStageThree {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    margin-right: 0.25rem;
    padding: 0.05rem 0.25rem;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.35;
}

.weatherWarningStageOne {
    background: #f5d35f;
    color: #2d2924;
}

.weatherWarningStageTwo {
    background: var(--brand-accent);
    color: #fff;
}

.weatherWarningStageThree {
    background: #bd2f2f;
    color: #fff;
}
