.ui-datepicker {
    z-index: 2000 !important;
}

@media (max-width: 767.98px) {
    .table-responsive:has(tbody[data-accounting-line-grid]) {
        overflow: visible;
    }

    table:has(> tbody[data-accounting-line-grid]),
    table:has(> tbody[data-accounting-line-grid]) > tbody,
    table:has(> tbody[data-accounting-line-grid]) > tbody > tr,
    table:has(> tbody[data-accounting-line-grid]) > tbody > tr > td {
        display: block;
        width: 100% !important;
        min-width: 0 !important;
    }

    table:has(> tbody[data-accounting-line-grid]) > thead {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    table:has(> tbody[data-accounting-line-grid]) > tbody > tr {
        margin-bottom: 1rem;
        padding: .75rem;
        border: 1px solid var(--bs-border-color);
        border-radius: .5rem;
        background: var(--bs-body-bg);
    }

    table:has(> tbody[data-accounting-line-grid]) > tbody > tr > td {
        display: grid;
        grid-template-columns: minmax(6.5rem, 34%) minmax(0, 1fr);
        gap: .35rem .75rem;
        align-items: center;
        padding: .4rem 0;
        border: 0;
        text-align: left !important;
    }

    table:has(> tbody[data-accounting-line-grid]) > tbody > tr > td::before {
        content: attr(data-label);
        color: var(--bs-secondary-color);
        font-size: .75rem;
        font-weight: 600;
        line-height: 1.2;
    }

    table:has(> tbody[data-accounting-line-grid]) > tbody > tr > td > * {
        min-width: 0;
        max-width: 100%;
    }

    table:has(> tbody[data-accounting-line-grid]) .form-control,
    table:has(> tbody[data-accounting-line-grid]) .form-select {
        width: 100%;
        min-width: 0;
    }
}

/* Accounting date controls use the company date format with one consistent calendar. */
.accounting-app .accounting-date-input {
    position: relative;
    width: 100%;
}

.accounting-app .accounting-date-input > .form-control {
    padding-right: 2.75rem;
    background-color: #fff;
}

.accounting-app .accounting-date-input-button {
    position: absolute;
    top: 50%;
    right: .45rem;
    display: inline-flex;
    width: 2rem;
    height: 2rem;
    padding: 0;
    align-items: center;
    justify-content: center;
    color: #69707a;
    background: transparent;
    border: 0;
    border-radius: .4rem;
    transform: translateY(-50%);
    transition: color .15s ease, background-color .15s ease;
}

.accounting-app .accounting-date-input-button:hover,
.accounting-app .accounting-date-input-button:focus-visible {
    color: var(--bs-primary, #0061f2);
    background: #eef4ff;
    outline: 0;
}

.accounting-app .accounting-date-input:has(.form-control:disabled) .accounting-date-input-button,
.accounting-app .accounting-date-input:has(.form-control[readonly]) .accounting-date-input-button {
    pointer-events: none;
    opacity: .45;
}

.accounting-app .ui-datepicker {
    width: 21.5rem;
    max-width: calc(100vw - 1rem);
    box-sizing: border-box;
    padding: .9rem;
    color: #363d47;
    font-family: inherit;
    font-size: .875rem;
    background: #fff;
    border: 1px solid #d9e0e7;
    border-radius: .75rem;
    box-shadow: 0 .75rem 2rem rgb(33 40 50 / 18%);
    z-index: 10050 !important;
}

.accounting-app .ui-datepicker .ui-datepicker-header {
    padding: 0 2.45rem .8rem;
    background: transparent;
    border: 0;
}

.accounting-app .ui-datepicker .ui-datepicker-title {
    display: grid;
    grid-template-columns: minmax(5.5rem, 1fr) 7.5rem;
    gap: .5rem;
    margin: 0;
    line-height: normal;
}

.accounting-app .ui-datepicker .ui-datepicker-title select {
    width: 100%;
    min-width: 0;
    height: 2.25rem;
    margin: 0;
    padding: .35rem .5rem;
    color: #363d47;
    font: inherit;
    font-weight: 600;
    background-color: #fff;
    border: 1px solid #d9e0e7;
    border-radius: .45rem;
    text-overflow: clip;
    cursor: pointer;
}

.accounting-app .ui-datepicker .ui-datepicker-title select:focus-visible {
    border-color: var(--bs-primary, #0061f2);
    box-shadow: 0 0 0 .2rem rgb(0 97 242 / 16%);
    outline: 0;
}

.accounting-app .ui-datepicker .ui-datepicker-title select.ui-datepicker-year {
    min-width: 7.5rem;
}

.accounting-app .ui-datepicker .ui-datepicker-prev,
.accounting-app .ui-datepicker .ui-datepicker-next {
    top: 0;
    display: flex;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    color: #69707a;
    background: #f2f6fc;
    border: 0;
    border-radius: .45rem;
    cursor: pointer;
}

.accounting-app .ui-datepicker .ui-datepicker-prev {
    left: 0;
}

.accounting-app .ui-datepicker .ui-datepicker-next {
    right: 0;
}

.accounting-app .ui-datepicker .ui-datepicker-prev:hover,
.accounting-app .ui-datepicker .ui-datepicker-next:hover {
    top: 0;
    color: var(--bs-primary, #0061f2);
    background: #e7efff;
}

.accounting-app .ui-datepicker .ui-datepicker-prev:hover {
    left: 0;
}

.accounting-app .ui-datepicker .ui-datepicker-next:hover {
    right: 0;
}

.accounting-app .ui-datepicker .ui-datepicker-prev::before,
.accounting-app .ui-datepicker .ui-datepicker-next::before {
    font-family: inherit;
    font-size: 1.15rem;
    font-weight: 700;
}

.accounting-app .ui-datepicker .ui-datepicker-prev::before {
    content: "\2039";
}

.accounting-app .ui-datepicker .ui-datepicker-next::before {
    content: "\203a";
}

.accounting-app .ui-datepicker .ui-datepicker-prev span,
.accounting-app .ui-datepicker .ui-datepicker-next span {
    display: none;
}

.accounting-app .ui-datepicker table {
    margin: 0;
    font-size: inherit;
}

.accounting-app .ui-datepicker th {
    padding: .4rem .15rem .55rem;
    color: #69707a;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
}

.accounting-app .ui-datepicker td {
    padding: .12rem;
}

.accounting-app .ui-datepicker td span,
.accounting-app .ui-datepicker td a {
    display: flex;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    align-items: center;
    justify-content: center;
    color: #363d47;
    background: transparent;
    border: 1px solid transparent;
    border-radius: .45rem;
    text-align: center;
}

.accounting-app .ui-datepicker .ui-datepicker-calendar td a.ui-state-default {
    color: #363d47 !important;
    text-decoration: none;
}

.accounting-app .ui-datepicker td a:hover {
    color: var(--bs-primary, #0061f2);
    background: #eef4ff;
    border-color: #dce8ff;
}

.accounting-app .ui-datepicker .ui-datepicker-calendar .ui-datepicker-today a.ui-state-default {
    color: var(--bs-primary, #0061f2) !important;
    background: #fff;
    border-color: var(--bs-primary, #0061f2);
    font-weight: 700;
}

.accounting-app .ui-datepicker .ui-datepicker-calendar .ui-datepicker-current-day a.ui-state-default,
.accounting-app .ui-datepicker .ui-datepicker-calendar .ui-datepicker-current-day a.ui-state-default:hover {
    color: #fff !important;
    background: var(--bs-primary, #0061f2);
    border-color: var(--bs-primary, #0061f2);
    font-weight: 700;
}

.accounting-app .ui-datepicker .ui-datepicker-other-month {
    opacity: .38;
}

.accounting-app .ui-datepicker .ui-datepicker-buttonpane {
    display: flex;
    margin: .75rem 0 0;
    padding: .75rem 0 0;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid #e9ecef;
}

.accounting-app .ui-datepicker .ui-datepicker-buttonpane button {
    float: none;
    margin: 0;
    padding: .4rem .75rem;
    color: #363d47;
    font: inherit;
    font-weight: 600;
    background: #fff;
    border: 1px solid #d9e0e7;
    border-radius: .45rem;
    opacity: 1;
}

.accounting-app .ui-datepicker .ui-datepicker-buttonpane button:hover {
    color: var(--bs-primary, #0061f2);
    background: #eef4ff;
    border-color: #c8d9fa;
}

@media (max-width: 420px) {
    .accounting-app .ui-datepicker {
        width: calc(100vw - 1rem);
        padding: .75rem;
    }

    .accounting-app .ui-datepicker .ui-datepicker-header {
        padding-right: 2.35rem;
        padding-left: 2.35rem;
    }

    .accounting-app .ui-datepicker .ui-datepicker-title {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: .35rem;
    }

    .accounting-app .ui-datepicker .ui-datepicker-title select.ui-datepicker-year {
        min-width: 0;
    }

    .accounting-app .ui-datepicker td span,
    .accounting-app .ui-datepicker td a {
        width: 100%;
    }
}

﻿/*:root {
    --primary-color: #0061f2;
    --primary-card-color: #339ab7;
    --secondary-card-color: #337ab7;
    --tertiary-card-color: #00b1cb;
    --mainImagePrimary: #0061f2;
    --mainImageSecondary: #6900c7cc;
    --primary-MainImage: linear-gradient(135deg, var(--mainImagePrimary) 0%, var(--mainImageSecondary)) !important;
    --dashboard-admin-image: url("https://source.unsplash.com/1600x900/?abstract,blue");
    --dashboard-supplier-image: url("https://source.unsplash.com/1600x900/?abstract,blue");
    --primary-text-color: #363d47;
    --secondary-text-color: #69707A;
    --tertiary-text-color: #a7aeb8;
    --alternative-text-color: #ffffff;
    --primary-panel-color: #ffffff;
    --seconday-panel-color: #2128320d;
    --primary-shadow-color: rgb(33 40 50 / 15%);
    --primary-background-color: #f2f6fc;
    --notification-color: #e81500;
    --notification-success-color: green;
    --notification-danger-color: blue;
    --login-page-panel-color: white;
    --login-background-image: url("https://source.unsplash.com/1600x900/?abstract,blue");
}
*/
html {
  font-size: 14px;
}


.dx-datagrid-content .dx-datagrid-table .dx-row > td, .dx-datagrid-content .dx-datagrid-table .dx-row > tr > td {
    vertical-align: middle !important;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}
.custom-file-upload {
    border: 1px solid #ccc;
    display: inline-block;
    padding: 6px 12px;
    cursor: pointer;
    background-color: #f8f9fa;
    border-radius: 4px;
}
.profile-initials-toggle,
.profile-initials-toggle:hover,
.profile-initials-toggle:focus,
.profile-initials-toggle:active {
    background: transparent !important;
    box-shadow: none !important;
}
.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}


#autocomplete {
    width: 300px;
    padding: 7px;
} 

.ui-widget-content {
    text-align: left;
    z-index:9999 !important;
}

.autocomplete-suggestions {
    text-align: left;
    border: 1px solid #999;
    border-bottom-left-radius: 3px;
    border-bottom-right-radius: 3px;
    background: #FFF;
    overflow: auto;
}

.autocomplete-suggestion {
    padding: 5px 5px;
    white-space: nowrap;
    overflow: hidden;
    cursor: pointer;
}

.autocomplete-selected {
    background: #F0F0F0;
}

.autocomplete-suggestions strong {
    font-weight: normal;
    color: #3399FF;
}

.autocomplete-group {
    padding: 2px 5px;
}

    .autocomplete-group strong {
        display: block;
        border-bottom: 1px solid #000;
    }

.ui-autocomplete .highlight {
    color: blue;
}


/* Custom tooltip offset */
.custom-tooltip-offset .tooltiptreeview {
    top: calc(100% + 10px) !important; /* Adjust the offset as needed */
}

.tree {
    position: relative;
    background: white;
    margin-top: 20px;
    padding: 30px;
    font-weight: 400;
    color: #212529;
}

    .tree span {
        font-size: 13px;
        font-style: italic;
        letter-spacing: .4px;
        color: #a8a8a8;
    }

    .tree .fa-folder-open, .tree .fa-folder {
        color: #007bff;
    }

    .tree .fa-html5 {
        color: #f21f10;
    }

    .tree ul {
        padding-left: 5px;
        list-style: none;
    }

    .tree li {
        position: relative;
        padding-top: 5px;
        padding-bottom: 5px;
        padding-left: 15px;
        -webkit-box-sizing: border-box;
        -moz-box-sizing: border-box;
        box-sizing: border-box;
    }

    .tree &:before {
        position: absolute;
        top: 15px;
        left: 0;
        width: 10px;
        height: 1px;
        margin: auto;
        content: '';
        background-color: #666;
    }

    .tree &:after {
        position: absolute;
        top: 0;
        bottom: 0;
        left: 0;
        width: 1px;
        height: 100%;
        content: '';
        background-color: #666;
    }

    .tree &:last-child:after {
        height: 15px;
    }



    .tree a, .tree .contextMenu {
        cursor: pointer;
    }

    .tree &:hover {
        text-decoration: none;
    }

    .tree .context-menu {
        display: none;
        position: absolute;
        z-index: 1000;
    }

    .tree .contextMenu {
        font-size: 1rem;
    }

    .tree .context-menu .dropdown-menu {
        display: block;
        position: static;
        float: none;
    }

    /* Adjust tooltip positioning within the tree view */
    .tree .tooltip {
        /* Add custom positioning styles here */
        /* For example: */
        left: 50%;
        transform: translateX(-50%);
    }

.dx-datagrid-rowsview .dx-data-row:hover {
    cursor: pointer !important;
}

#sidebarToggleArrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: calc((0.875rem * 1) + (0.875rem * 2) + (2px)) !important;
    height: calc((0.875rem * 1) + (0.875rem * 2) + (2px)) !important;
    padding: 0;
    margin: 1.5rem auto 0;
    background-color: var(--seconday-panel-color);
    border: 1px solid #ccc;
    border-radius: 50%;
    color: var(--primary-text-color);
    font-size: 1rem;
    cursor: pointer;
}

.dx-icon-folder:before,
.dx-icon-activefolder:before {
    content: none !important;
}

/* 2) Inject your SVG as a background */
.dx-icon-folder,
.dx-icon-activefolder {
    /* make sure it still sizes like an icon */
    display: inline-block !important;
    width: 1.125rem; /* tweak to taste */
    height: 1.125rem; /* tweak to taste */
    background: url('/img/thumbnails/mini-folder-icon.svg') center center no-repeat !important;
    background-size: contain !important;
    font-size: 0 !important; /* hide any leftover text */
}

.dx-filemanager-dirs-tree
.dx-treeview-node
.dx-treeview-toggle-item-visibility,
.dx-filemanager-dirs-tree
.dx-treeview-node
.dx-treeview-expander-icon-stub {
    display: inline-block !important;
    width: 18px !important;
    min-width: 18px !important;
    text-overflow: ellipsis;
}

.dx-filemanager-dirs-tree .dx-treeview-item-content {
    display: flex !important;
    align-items: center !important;
    text-overflow: ellipsis;
    flex: 1 1 auto !important;
    min-width: 0 !important;
}

/* let the text grow and ellipsize */
.dx-filemanager-dirs-tree .dx-filemanager-dirs-tree-item-text {
    flex: 1 1 auto !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* push the overflow “⋮” button to the far right */
.dx-filemanager-dirs-tree .dx-filemanager-file-actions-button {
    flex: 0 0 auto !important;
    margin-left: auto !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 4px !important;
}

.dx-filemanager-dirs-tree .dx-treeview-item-content .dx-filemanager-dirs-tree-item-text {
    display: inline-block !important;
    max-width: 100% !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    vertical-align: middle !important;
}

.dx-datagrid-headers .dx-datagrid-table .dx-row > td {
    font-weight: 700;
}
.dx-datagrid-content .dx-datagrid-table.dx-datagrid-table-fixed { 
    color: black !important;
}
.dx-datagrid-borders > .dx-datagrid-pager {
    margin-top: -1px; 
}

.dx-widget {
    font-size: 12px !important;
    font-family: var(--bs-body-font-family) !important;
}

.dx-icon.dx-icon-edit::before,
.dx-icon.dx-icon-trash::before,
.dx-icon.dx-icon-check::before,
.dx-icon.dx-icon-close::before,
.dx-icon.dx-icon-save::before,
.dx-icon.dx-icon-undo::before,
.dx-icon.dx-icon-refresh::before,
.dx-icon.dx-icon-add::before,
.dx-icon.dx-icon-plus::before,
.dx-icon.dx-icon-comment::before,
.dx-icon.dx-icon-file::before,
.dx-icon.dx-icon-download::before,
.dx-icon.dx-icon-upload::before,
.dx-icon.dx-icon-lock::before,
.dx-icon.dx-icon-unlock::before,
.dx-icon.dx-icon-event::before,
.dx-icon.dx-icon-overflow::before,
.dx-icon.dx-icon-filter::before,
.dx-icon.dx-icon-box::before,
.dx-icon.dx-icon-revert::before,
.dx-icon.dx-icon-exportxlsx::before,
.dx-icon.dx-icon-pdffile::before,
.dx-icon.dx-icon-import::before,
.dx-icon.dx-icon-copy::before,
.dx-icon.dx-icon-clear::before,
.dx-icon.dx-icon-warning::before,
.dx-icon.dx-icon-info::before,
.dx-icon.dx-icon-search::before {
    font-family: "Font Awesome 6 Free", "Font Awesome 5 Free", FontAwesome !important;
    font-style: normal !important;
    font-variant: normal !important;
    font-weight: 900 !important;
    text-rendering: auto !important;
}

.dx-icon.dx-icon-edit::before { content: "\f044" !important; }
.dx-icon.dx-icon-trash::before { content: "\f1f8" !important; }
.dx-icon.dx-icon-check::before { content: "\f00c" !important; }
.dx-icon.dx-icon-close::before,
.dx-icon.dx-icon-clear::before { content: "\f00d" !important; }
.dx-icon.dx-icon-save::before { content: "\f0c7" !important; }
.dx-icon.dx-icon-undo::before,
.dx-icon.dx-icon-revert::before { content: "\f0e2" !important; }
.dx-icon.dx-icon-refresh::before { content: "\f021" !important; }
.dx-icon.dx-icon-add::before,
.dx-icon.dx-icon-plus::before { content: "\2b" !important; }
.dx-icon.dx-icon-comment::before { content: "\f075" !important; }
.dx-icon.dx-icon-file::before { content: "\f15b" !important; }
.dx-icon.dx-icon-download::before { content: "\f019" !important; }
.dx-icon.dx-icon-upload::before { content: "\f093" !important; }
.dx-icon.dx-icon-lock::before { content: "\f023" !important; }
.dx-icon.dx-icon-unlock::before { content: "\f09c" !important; }
.dx-icon.dx-icon-event::before { content: "\f073" !important; }
.dx-icon.dx-icon-overflow::before { content: "\f142" !important; }
.dx-icon.dx-icon-filter::before { content: "\f0b0" !important; }
.dx-icon.dx-icon-box::before { content: "\f187" !important; }
.dx-icon.dx-icon-exportxlsx::before { content: "\f1c3" !important; }
.dx-icon.dx-icon-pdffile::before { content: "\f1c1" !important; }
.dx-icon.dx-icon-import::before { content: "\f56f" !important; }
.dx-icon.dx-icon-copy::before { content: "\f0c5" !important; }
.dx-icon.dx-icon-warning::before { content: "\f071" !important; }
.dx-icon.dx-icon-info::before { content: "\f129" !important; }
.dx-icon.dx-icon-search::before { content: "\f002" !important; }

.dx-datagrid-table .dx-row > td[role="columnheader"],
.dx-datagrid-table .dx-row > td[role="gridcell"] {
    padding: 5px 5px !important; 
}
.quotation-grid-wrap-cell {
    white-space: normal !important;
    vertical-align: top !important;
}
.quotation-grid-wrap-text {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    line-height: 1.3;
}
.dx-texteditor-input {
    padding: 5px !important;
    min-height: 30px !important;
}
.dx-button .dx-button-content {
    padding-block: 5px !important;
}
.dx-datagrid-group-panel {
    font-size: 12px !important;
}
.dx-datagrid-group-panel .dx-group-panel-item {
    padding: 5px !important;
}


.btn-transparent-dark svg,
.sidenav-light,
.dropdown-user-details-name,
.breadcrumb-item,
.page-header.page-header-light .page-header-title,
.dx-datagrid-content .dx-datagrid-table.dx-datagrid-table-fixed,
.dx-datagrid-rowsview .dx-row.dx-group-row:not(.dx-row-focused),
.dx-texteditor-input,
.dx-button-mode-outlined,
.dx-button-mode-contained,
.dx-button-mode-contained .dx-icon,
.dx-dropdowneditor-icon,
.dx-datagrid-group-opened,
.dx-menu-item,
.dx-widget,
h5,
form-group,
.dx-button-text,
.dx-datagrid-nodata,
.dx-button-mode-outlined .dx-icon,
.form-control:focus,
h4,
.topnav.navbar-light .navbar-brand {
    color: var(--primary-text-color) !important;
}

/* Keep the company name beside the menu toggle at every breakpoint instead
   of reserving a fixed desktop brand column. */
.topnav .navbar-brand {
    flex: 0 1 auto;
    width: auto;
    min-width: 0;
    max-width: min(18rem, 40vw);
    margin: 0;
    padding-right: .5rem !important;
    padding-left: .5rem !important;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 991.98px) {
    .topnav {
        justify-content: flex-start !important;
        padding-right: .5rem;
    }

    .topnav #sidebarToggle {
        order: 0 !important;
        flex: 0 0 auto;
        margin-right: .25rem !important;
        margin-left: .5rem !important;
    }

    .topnav .navbar-brand {
        order: 0;
        max-width: min(15rem, calc(100vw - 9rem));
    }

    .topnav .navbar-nav {
        margin-left: auto !important;
    }
}

.dx-toolbar .dx-button-text {
    color: var(--primary-text-color);
}

.dx-filemanager .dx-toolbar .dx-button-text {
    color: black !important;
}

.modal {
    --bs-modal-color: var(--primary-text-color);
}

.dropdown-notifications-header {
    color: var(--alternative-text-color);
    background-color: var(--primary-color) !important;
    border: 1px solid var(--primary-color) !important;
}

.btn:focus {
    box-shadow: unset !important;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--primary-color) !important;
    border: 1px solid var(--primary-color) !important;
}

.dropdown-item-icon svg,
.page-header-icon svg,
.sidenav-light .sidenav-menu .sidenav-menu-heading,
.sidenav-light .sidenav-menu .nav-link .nav-link-icon,
.sidenav-light .sidenav-menu .nav-link,
.sidenav-light .sidenav-footer .sidenav-footer-subtitle,
.btn-transparent-dark,
.text-dark,
.dx-placeholder,
.dx-searchbox .dx-icon-search::before,
.dx-datagrid .dx-header-filter::before,
.dx-datagrid-group-panel .dx-sort,
.dx-datagrid-group-panel .dx-group-panel-item,
.footer-admin.footer-light,
.dx-field-item-label-text,
.dropdown-user-details-email,
.recent-activity {
    color: var(--secondary-text-color) !important;
}
.page-header.page-header-dark .page-header-subtitle {
    color: rgb(255 255 255);
}
/* Shared tenant page header (_PageHeader.cshtml): one line of supporting text. */
.page-header.page-header-compact .page-header-content .page-header-subtitle {
    font-size: .85rem;
    margin-top: .2rem;
    max-width: 60rem;
}
.dx-filemanager-file-actions-button .dx-button .dx-icon,
.dx-menu-item-text {
    color: #000 !important;
}

.sidenav-light .sidenav-menu .nav-link.active,
.sidenav-light .sidenav-menu .nav-link.active .nav-link-icon,
.card:not([class*=bg-]) .card-header,
a,
.text-primary,
.nav-link,
.dx-checkbox-checked .dx-checkbox-icon,
.activity {
    color: var(--primary-color) !important;
}

.bg-gradient-primary-to-secondary {
    background-image: var(--primary-MainImage) !important;
    height: 100%;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.card {
    --bs-card-bg: var(--primary-panel-color) !important;
    box-shadow: 0 0 0.5rem var(--primary-shadow-color) !important;
}

.card1{
    background-color: var(--primary-card-color)
}
.card2 {
    background-color: var(--secondary-card-color)
}
.card3 {
    background-color: var(--tertiary-card-color)
}

.timeline-item-marker-text {
    color: var(--tertiary-text-color) !important;
}

.page-header-title,
.feather-activity svg,
.text-white,
.dropdown-notifications-header,
.text-white-75 {
    color: var(--alternative-text-color) !important;
}

#layoutAuthentication .btn-primary {
    color: #fff !important;
}

svg.feather.feather-activity {
    color: var(--alternative-text-color) !important;
}

/* The rule above paints every "activity" icon in the light text colour; in the user menu
   (Activity log) that made the icon white on white. It takes the colour of the menu's
   other icons (.dropdown-item-icon svg). */
.dropdown-menu .dropdown-item-icon svg.feather.feather-activity {
    color: var(--secondary-text-color) !important;
}

.bg-white,
.dx-datagrid > .dx-datagrid-headers,
.dx-button-mode-contained,
.dx-datagrid > .dx-datagrid-rowsview,
.modal-content,
.sidenav-light {
    --bs-bg-opacity: 1;
    background-color: var(--primary-panel-color) !important;
}

.card-header {
    --bs-card-bg: var(--primary-panel-color) !important;
    --bs-card-cap-bg: var(--seconday-panel-color) !important;
}

.sidenav-light .sidenav-footer,
.form-control[readonly],
.dx-datagrid-rowsview .dx-row.dx-group-row:not(.dx-row-focused) {
    background-color: var(--seconday-panel-color) !important;
}

.bg-light {
    background-color: var(--seconday-panel-color) !important;
    color: var(--primary-text-color);
}

input {
    background-color: var(--primary-panel-color) !important;
    border: 1px solid var(--seconday-panel-color) !important;
}

.btn-light {
    background-color: var(--seconday-panel-color) !important;
    border: 1px solid var(--seconday-panel-color) !important;
    color: var(--primary-color) !important;
}

.dx-datagrid .dx-row-alt > td, .dx-datagrid .dx-row-alt > tr > td {
    background-color: var(--seconday-panel-color) !important;
}

.dx-button-mode-contained,
dx-texteditor-input,
.dx-texteditor.dx-editor-outlined,
.dx-datagrid-table {
    background-color: var(--primary-panel-color);
}

.shadow-right,
.shadow {
    box-shadow: 0 0.15rem 1rem var(--primary-shadow-color) !important;
}

.dropdown-menu,
.dx-master-detail-cell,
body {
    background-color: var(--primary-background-color) !important;
}


.notification-bell {
    color: var(--alternative-text-color) !important;
    background-color: var(--notification-color) !important;
}



* {
    --scrollbar-color-thumb: var(--primary-color);
    --scrollbar-color-track: var(--primary-panel-color);
    --scrollbar-width: thin;
    --scrollbar-width-legacy: 10px;
}

/* Modern browsers */
@supports (scrollbar-width: auto) {
    * {
        scrollbar-color: var(--scrollbar-color-thumb) var(--scrollbar-color-track);
        scrollbar-width: var(--scrollbar-width);
    }
}

/* WebKit-based browsers (Chrome, Edge, Safari, etc.) */
@supports selector(::-webkit-scrollbar) {
    *::-webkit-scrollbar-thumb {
        background: var(--scrollbar-color-thumb);
    }

    *::-webkit-scrollbar-track {
        background: var(--scrollbar-color-track);
    }

    *::-webkit-scrollbar {
        max-width: var(--scrollbar-width-legacy);
        max-height: var(--scrollbar-width-legacy);
    }
}

.bg-info {
    background-color: var(--primary-color) !important;
    color: var(--primary-text-color) !important; 
}

.bg-danger,
.bg-warning {
    background-color: var(--notification-danger-color) !important;
    color: var(--primary-text-color) !important;
}

.bg-success {
    background-color: var(--notification-success-color) !important;
    color: var(--primary-text-color) !important;
}

.form-control {
    background-color: var(--seconday-panel-color);
    color: var(--primary-text-color);
}

.dx-button-mode-contained.dx-button-default {
    background-color: var(--primary-color);
    border-color: #ddd;
}

.table {
    --bs-table-color: var(--primary-text-color);
}

.btn-secondary {
    --bs-btn-color: var(--alternative-text-color);
    --bs-btn-bg: var(--secondary-card-color);
    --bs-btn-border-color: var(--secondary-card-color);
    --bs-btn-hover-color: var(--alternative-text-color);
    --bs-btn-hover-bg: var(--secondary-card-color);
    --bs-btn-hover-border-color: var(--secondary-card-color);
    --bs-btn-focus-shadow-rgb: 128, 38, 207;
    --bs-btn-active-color: var(--alternative-text-color);
    --bs-btn-active-bg: var(--secondary-card-color);
    --bs-btn-active-border-color: var(--secondary-card-color);
    --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
    --bs-btn-disabled-color: var(--alternative-text-color);
    --bs-btn-disabled-bg: var(--secondary-card-color);
    --bs-btn-disabled-border-color: var(--secondary-card-color);
    color: var(--alternative-text-color) !important;
}

.btn-primary {
    --bs-btn-color: var(--alternative-text-color);
    --bs-btn-bg: var(--primary-color);
    --bs-btn-border-color: var(--primary-color);
    --bs-btn-hover-color: var(--alternative-text-color);
    --bs-btn-hover-bg: var(--primary-color);
    --bs-btn-hover-border-color: var(--primary-color);
    --bs-btn-focus-shadow-rgb: 38, 121, 244;
    --bs-btn-active-color: var(--alternative-text-color);
    --bs-btn-active-bg: var(--primary-color);
    --bs-btn-active-border-color: var(--primary-color);
    --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
    --bs-btn-disabled-color: var(--alternative-text-color);
    --bs-btn-disabled-bg: var(--primary-color);
    --bs-btn-disabled-border-color: #0061f2;
    background-color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

/* Disabled buttons must be visibly inert, not just non-clickable. */
.btn:disabled,
.btn.disabled,
fieldset:disabled .btn {
    opacity: .45;
    filter: saturate(.55);
}

/* Adaptive grid expander: chevron on the left that rotates when the row's
   collapsed-columns detail is open (replaces DevExtreme's "..." glyph). */
.dx-datagrid .dx-datagrid-adaptive-more::before {
    font-family: 'Font Awesome 6 Pro';
    font-weight: 900;
    content: '\f105';
    font-size: .9rem;
    color: var(--primary-color);
    display: inline-block;
    transition: transform .15s ease-in-out;
}

.dx-datagrid tr:has(+ tr.dx-adaptive-detail-row) .dx-datagrid-adaptive-more::before {
    transform: rotate(90deg);
}


.btn-sm {
    border: 1px solid var(--primary-text-color) !important;
    color: var(--primary-text-color) !important;
    background-color: transparent !important;
}

#layoutAuthentication .card {
    background-color: var(--login-page-panel-color);
}

.logInForm {
    background-color: var(--login-page-panel-color) !important;
}

    .logInForm .btn-secondary {
        color: #fff !important;
    }

    .form-group {
        color: var(--primary-text-color) !important;
    }

/* The Build Sync logo (the shared _BuildSyncLogo partial) on the account pages:
   register, verification, one-time PIN and password reset. Same look as the sign-in page. */
.account-logo,
.account-logo:hover,
.account-logo:focus {
    color: var(--primary-text-color, #101b3b);
    font-size: 2rem;
    text-decoration: none;
}

    .account-logo .bsl {
        align-items: center;
        display: inline-flex;
        gap: 10px;
        line-height: 1;
    }

    .account-logo .bsl-mark {
        flex: none;
        height: 1.55em;
        width: auto;
    }

    .account-logo .bsl-word {
        font-family: "Montserrat", "Segoe UI", system-ui, sans-serif;
        font-weight: 700;
        letter-spacing: -.02em;
    }

.form-control:focus {
    background-color: var(--primary-background-color) !important;
    border: 1px solid var(--primary-text-color) !important;
    box-shadow: 0 0 0 0 white !important;
}

.dropdown-item:active {
    background-color: var(--bs-dropdown-link-hover-bg) !important;
    color: var(--primary-color) !important;
}

.dropdown-user .dropdown-item-icon:active,
.dropdown-user .dropdown-item:active {
    color: var(--primary-color) !important;
}

.dropdown-menu .dropdown-item.active .dropdown-item-icon, .dropdown-menu .dropdown-item:active .dropdown-item-icon {
    color: var(--primary-color) !important;
}

.bg-select {
    background-color: #27a8f7 !important;
    color: var(--primary-text-color) !important;
}

/* Only CHECKED boxes take the primary colour - an unconditional override made checked and
   unchecked toggles indistinguishable across the whole app. */
input[type=checkbox] {
    border-radius: .25em;
}

input[type=checkbox]:checked {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

/* A checked radio button shows its dot: the panel colour of text inputs must not
   paint over it. */
input[type=radio]:checked {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.cat-chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    font-size: 12px;
    font-weight: 600;
    color: #374151;
    max-width: 240px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.dx-datagrid-header-panel .dx-toolbar-after {
    margin-left: auto !important;
    justify-content: flex-end !important;
    column-gap: 10px;
    row-gap: 14px;
}

.dx-datagrid-header-panel .dx-toolbar-items-container {
    justify-content: flex-end !important;
    row-gap: 5px;
}

/* collapsed sidebar */
.nav-fixed #layoutSidenav #layoutSidenav_nav {
    width: 3.5rem;
    transition: width 0.25s ease;
    overflow: hidden;
    box-shadow: 0 0.15rem 1rem var(--primary-shadow-color) !important;
}

    .nav-fixed #layoutSidenav #layoutSidenav_nav:hover {
        width: 15rem;
    }

.nav-fixed #layoutSidenav #layoutSidenav_content {
    padding-left: 3.5rem;
    top: 3.625rem;
    transition: padding-left 0.25s ease;
}

/* optional if you want content to move on hover */
.nav-fixed #layoutSidenav:has(#layoutSidenav_nav:hover) #layoutSidenav_content {
    padding-left: 15rem;
}

/* same alignment for all links */
#layoutSidenav_nav .nav-link {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-height: 48px;
    padding: 0.75rem 0 !important;
    gap: 0 !important;
}

/* keep icon perfectly centered */
#layoutSidenav_nav .nav-link-icon {
    width: 100%;
    min-width: 100%;
    margin: 0 !important;
    padding: 0 !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* hide everything except icon when collapsed */
#layoutSidenav_nav:not(:hover) .nav-link > *:not(.nav-link-icon) {
    display: none !important;
}

/* also hide raw text nodes by shrinking font */
#layoutSidenav_nav:not(:hover) .nav-link {
    font-size: 0 !important;
}

/* restore normal layout on hover */
#layoutSidenav_nav:hover .nav-link {
    justify-content: flex-start;
    gap: 0.75rem !important;
    padding: 0.75rem 1rem !important;
    font-size: inherit !important;
}

#layoutSidenav_nav:hover .nav-link-icon {
    width: 1rem;
    min-width: 1rem;
    justify-content: center;
}

/* headings/footer hidden in collapsed mode */
#layoutSidenav_nav:not(:hover) .sidenav-menu-heading,
#layoutSidenav_nav:not(:hover) .sidenav-footer,
#layoutSidenav_nav:not(:hover) .sidenav-collapse-arrow,
#layoutSidenav_nav:not(:hover) #sidebarToggleArrow {
    display: none !important;
}

/* hide submenus while collapsed */
#layoutSidenav_nav:not(:hover) .collapse {
    display: none !important;
}
#layoutSidenav_nav:not(:hover) .sidenav-menu {
    padding-top: 2.25rem;
}


/* Mobile: always show full menu */
@media (max-width: 991.98px) {

    /* 15rem, matching the theme's margin-left: -15rem below 992px (14.5rem put every page
       8px to the left). */
    .nav-fixed #layoutSidenav #layoutSidenav_content {
        padding-left: 15rem;
        top: 3.625rem;
        transition: padding-left 0.25s ease;
    }
    .nav-fixed #layoutSidenav #layoutSidenav_nav {
        width: 15rem !important;
        overflow: visible !important;
    }

    #layoutSidenav_nav .nav-link {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        gap: 0.75rem !important;
        padding: 0.75rem 1rem !important;
        font-size: inherit !important;
    }

    #layoutSidenav_nav .nav-link-icon {
        width: 1rem !important;
        min-width: 1rem !important;
        margin: 0 !important;
        padding: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    #layoutSidenav_nav .nav-link > *:not(.nav-link-icon) {
        display: inline-flex !important;
    }

    #layoutSidenav_nav .sidenav-menu-heading,
    #layoutSidenav_nav .sidenav-footer,
    #layoutSidenav_nav .sidenav-collapse-arrow,
    #layoutSidenav_nav #sidebarToggleArrow {
        display: block !important;
    }

    #layoutSidenav_nav .collapse.show {
        display: block !important;
    }

    #layoutSidenav_nav .sidenav-menu {
        padding-top: 0 !important;
    }

    /* ignore collapsed desktop state on mobile */
    body:not(.sidenav-toggled) #layoutSidenav #layoutSidenav_nav,
    body.sidenav-toggled #layoutSidenav #layoutSidenav_nav {
        width: 15rem !important;
    }

    body:not(.sidenav-toggled) #layoutSidenav_nav .nav-link,
    body.sidenav-toggled #layoutSidenav_nav .nav-link {
        font-size: inherit !important;
    }

    body:not(.sidenav-toggled) #layoutSidenav_nav .nav-link > *:not(.nav-link-icon),
    body.sidenav-toggled #layoutSidenav_nav .nav-link > *:not(.nav-link-icon) {
        display: inline-flex !important;
    }
}

.permission-denied-page {
    min-height: calc(100vh - 7.5rem);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 2rem;
    padding-bottom: 2rem;
}

.permission-denied-shell {
    width: min(100%, 760px);
    position: relative;
}

.permission-denied-shell::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(39, 168, 247, 0.22), rgba(18, 32, 59, 0.06), rgba(40, 167, 69, 0.18));
}

.permission-denied-panel {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: #fff;
    box-shadow: 0 1rem 2.5rem rgba(15, 23, 42, 0.12);
    padding: clamp(1.5rem, 4vw, 3rem);
}

.permission-denied-status {
    position: absolute;
    right: clamp(1rem, 4vw, 2.5rem);
    top: clamp(0.75rem, 3vw, 1.5rem);
    font-size: clamp(3rem, 12vw, 7rem);
    font-weight: 700;
    line-height: 1;
    color: rgba(15, 23, 42, 0.05);
    pointer-events: none;
}

.permission-denied-icon {
    width: 4rem;
    height: 4rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #eef7ff;
    color: var(--primary-color);
    font-size: 1.75rem;
    margin-bottom: 1.25rem;
}

.permission-denied-kicker {
    margin: 0 0 0.5rem;
    color: var(--primary-color);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.permission-denied-panel h1 {
    max-width: 620px;
    margin: 0;
    color: #111827;
    font-size: clamp(2rem, 5vw, 3.25rem);
    font-weight: 700;
    line-height: 1.08;
}

.permission-denied-copy {
    max-width: 610px;
    margin: 1rem 0 0;
    color: #4b5563;
    font-size: 1rem;
    line-height: 1.7;
}

.permission-denied-request {
    display: grid;
    gap: 0.4rem;
    max-width: 100%;
    margin-top: 1.25rem;
    padding: 0.875rem 1rem;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
}

.permission-denied-request span {
    color: #6b7280;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.permission-denied-request code {
    display: block;
    max-width: 100%;
    overflow-wrap: anywhere;
    color: #111827;
    font-size: 0.875rem;
}

.permission-denied-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

@media (max-width: 575.98px) {
    .permission-denied-actions .btn {
        width: 100%;
    }
}

.accounting-desktop-chrome {
    --accounting-dashboard-border-color: var(--seconday-panel-color, rgba(167, 174, 184, .45));
    border: 1px solid var(--accounting-dashboard-border-color);
    background: var(--primary-background-color, #f3f4f6);
}

.accounting-icon-bar {
    display: flex;
    align-items: center;
    gap: .65rem;
    min-height: 4.65rem;
    padding: .45rem .75rem;
    background: var(--primary-panel-color, #ffffff);
    overflow-x: auto;
}

.accounting-pinned-sections {
    display: flex;
    align-items: stretch;
    gap: .35rem;
    min-height: 3.45rem;
}

.accounting-pinned-section {
    position: relative;
    width: 6.6rem;
    min-height: 3.45rem;
    padding: .35rem .45rem;
    color: var(--primary-text-color);
    border: 1px solid transparent;
    background: transparent;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .2rem;
    text-align: center;
    text-decoration: none;
    font-size: .75rem;
    line-height: 1.1;
    cursor: grab;
    user-select: none;
    touch-action: pan-x;
}

.accounting-pinned-section:hover,
.accounting-pinned-section:focus {
    color: var(--primary-text-color);
    background: var(--seconday-panel-color, #f8fafc);
    border-color: var(--seconday-panel-color, #cbd5e1);
    text-decoration: none;
}

.accounting-pinned-section:active {
    cursor: grabbing;
}

.accounting-pinned-section.is-dragging {
    opacity: .45;
    background: var(--seconday-panel-color, #eef4ff);
    border-color: var(--primary-color, #8fb3e8);
}

.accounting-pinned-sections.is-reordering .accounting-pinned-section:not(.is-dragging) {
    transition: transform .12s ease, border-color .12s ease, background-color .12s ease;
}

.accounting-pinned-sections.is-editing .accounting-pinned-section,
.accounting-pinned-section.is-editing {
    background: var(--seconday-panel-color, #f8fafc);
    border-color: var(--seconday-panel-color, #cbd5e1);
}

.accounting-pinned-section i {
    color: var(--primary-color);
    font-size: 1.15rem;
}

.accounting-pinned-unpin {
    position: absolute;
    top: .18rem;
    right: .18rem;
    width: 1.25rem;
    height: 1.25rem;
    border: 1px solid var(--notification-color, #f0b4b4);
    border-radius: 50%;
    background: var(--primary-panel-color, #ffffff);
    color: var(--notification-color, #b42318);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transform: scale(.82);
    transition: opacity .12s ease, transform .12s ease;
    z-index: 2;
}

.accounting-pinned-unpin:hover,
.accounting-pinned-unpin:focus {
    background: var(--seconday-panel-color, #fff5f5);
    border-color: var(--notification-color, #e58b8b);
    color: var(--notification-color, #991b1b);
}

.accounting-pinned-unpin i {
    color: currentColor;
    font-size: .75rem;
}

.accounting-pinned-sections.is-editing .accounting-pinned-unpin,
.accounting-pinned-section.is-editing .accounting-pinned-unpin {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.accounting-page-actions {
    display: flex;
    align-items: stretch;
    gap: .35rem;
    margin-left: auto;
}

.accounting-page-action {
    min-width: 5.25rem;
    min-height: 3.45rem;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .2rem;
    text-align: center;
    font-size: .75rem;
    line-height: 1.1;
    white-space: normal;
}

.accounting-page-action i {
    font-size: 1.05rem;
}

.accounting-page-action.is-pinned {
    color: var(--secondary-card-color, #b7791f);
    border-color: var(--secondary-card-color, #e0bf76);
    background: var(--seconday-panel-color, #fff8e6);
}

.accounting-setup-warning {
    margin-top: .75rem;
}

.accounting-setup-warning-body {
    display: flex;
    align-items: center;
    gap: .85rem;
    padding: .8rem .9rem;
    border: 1px solid var(--secondary-card-color, #e5c469);
    background: var(--primary-panel-color, #fff8e6);
    color: var(--primary-text-color, #3f3421);
}

.accounting-setup-warning-icon {
    width: 2.25rem;
    height: 2.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    color: var(--primary-color, #a36200);
    background: var(--seconday-panel-color, #ffffff);
    border: 1px solid var(--secondary-card-color, #efd486);
}

.accounting-setup-warning-copy {
    min-width: 13rem;
    flex: 1 1 auto;
}

.accounting-setup-warning-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .4rem;
}

.accounting-setup-warning-action {
    white-space: nowrap;
}

.accounting-item-pin,
.accounting-section-pin {
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--seconday-panel-color, #ccd3df);
    background: var(--primary-panel-color, #ffffff);
    color: var(--secondary-text-color, #69707a);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.accounting-workflow-node,
.accounting-rail-list a,
[data-quickaccess-pin="true"] {
    position: relative;
}

.accounting-item-pin {
    position: absolute;
    top: .35rem;
    right: .35rem;
    width: 1.75rem;
    height: 1.75rem;
}

.sidenav-menu-nested .nav-link[data-quickaccess-pin="true"] {
    padding-right: 2.25rem;
}

.sidenav-menu-nested .nav-link .accounting-item-pin {
    top: .45rem;
    right: .45rem;
    width: 1.35rem;
    height: 1.35rem;
    font-size: .7rem;
}

.accounting-item-pin.is-pinned,
.accounting-section-pin.is-pinned {
    color: var(--secondary-card-color, #b7791f);
    border-color: var(--secondary-card-color, #e0bf76);
    background: var(--seconday-panel-color, #fff8e6);
}

.accounting-form-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: .85rem;
}

.accounting-field {
    grid-column: span 4;
    min-width: 0;
}

.accounting-field-sm {
    grid-column: span 3;
}

.accounting-field-lg {
    grid-column: span 6;
}

.accounting-field-full {
    grid-column: 1 / -1;
}

.accounting-field-check {
    display: flex;
    align-items: end;
    min-height: 4.15rem;
}

.accounting-required-label::after {
    content: " *";
    color: var(--notification-color, #b42318);
    font-weight: 700;
}

.accounting-field-note {
    display: block;
    margin-top: .25rem;
    color: var(--secondary-text-color);
    font-size: .78rem;
    line-height: 1.35;
}

.accounting-form-status {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
    padding: .65rem .75rem;
    border: 1px solid var(--bs-border-color);
    background: var(--bs-light);
    font-size: .85rem;
}

.accounting-form-status .badge {
    flex: 0 0 auto;
}

.accounting-inline-guidance {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: .45rem 1rem;
    padding: .55rem .7rem;
    border: 1px solid var(--seconday-panel-color, #cfe2ff);
    border-left: .2rem solid var(--primary-color, #0d6efd);
    border-radius: .3rem;
    color: var(--primary-text-color);
    background: var(--accounting-theme-soft, #f5f9ff);
    font-size: .82rem;
    line-height: 1.35;
}

.accounting-inline-guidance-primary {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: .5rem;
    font-weight: 600;
}

.accounting-inline-guidance-icon {
    display: inline-flex;
    flex: 0 0 1.4rem;
    width: 1.4rem;
    height: 1.4rem;
    align-items: center;
    justify-content: center;
    color: var(--primary-color, #0d6efd);
}

.accounting-inline-guidance-details {
    min-width: 0;
}

.accounting-inline-guidance-details summary {
    color: var(--primary-color, #0d6efd);
    cursor: pointer;
    font-weight: 600;
    text-align: right;
    white-space: nowrap;
}

.accounting-inline-guidance-details[open] {
    grid-column: 1 / -1;
}

.accounting-inline-guidance-detail {
    margin-top: .45rem;
    padding-top: .45rem;
    border-top: 1px solid var(--seconday-panel-color, #cfe2ff);
    color: var(--secondary-text-color);
}

@media (max-width: 767.98px) {
    .accounting-inline-guidance {
        grid-template-columns: 1fr;
    }

    .accounting-inline-guidance-details summary {
        text-align: left;
        white-space: normal;
    }
}

.accounting-capture-table {
    margin-bottom: 0;
    --bs-table-border-color: var(--bs-border-color);
    --bs-table-hover-bg: var(--seconday-panel-color, rgba(224, 229, 236, 0.25));
}

.accounting-capture-table th {
    font-size: .78rem;
    font-weight: 600;
    color: var(--bs-gray-700);
    background: var(--bs-light);
    border-bottom-color: var(--bs-border-color);
    white-space: nowrap;
}

.accounting-capture-table td {
    vertical-align: middle;
}

.accounting-capture-table .form-control,
.accounting-capture-table .form-select {
    min-width: 7rem;
}

.accounting-capture-table .is-invalid {
    border-color: var(--notification-color, #dc3545) !important;
}

/* The capture popups are the style guide's widest (xl, 1140 px): their line grids fit inside it
   at 1440 and scroll sideways inside the popup only on a narrower window. */
.accounting-line-entry-table {
    width: 100%;
    min-width: var(--accounting-line-table-min-width);
    table-layout: fixed;
}

.accounting-po-line-table {
    --accounting-line-table-min-width: 1060px;
}

.accounting-supplier-bill-line-table {
    --accounting-line-table-min-width: 1060px;
}

.accounting-customer-invoice-line-table {
    --accounting-line-table-min-width: 960px;
}

.accounting-line-entry-table .form-control,
.accounting-line-entry-table .form-select {
    width: 100%;
    min-width: 0 !important;
}

.accounting-app .accounting-line-entry-table td:last-child,
.accounting-app .accounting-line-entry-table th:last-child {
    padding-right: .2rem !important;
    padding-left: .2rem !important;
}

.accounting-page-empty-state {
    min-height: 16rem;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.accounting-page-empty-state-icon {
    width: 3rem;
    height: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-card-color);
    background: var(--seconday-panel-color, rgba(51, 122, 183, .08));
    border: 1px solid var(--seconday-panel-color, rgba(51, 122, 183, .16));
    border-radius: .35rem;
}

@media (max-width: 767.98px) {
    .accounting-icon-bar {
        align-items: stretch;
        gap: .35rem;
        min-height: 3.35rem;
        padding: .35rem .45rem;
    }

    .accounting-pinned-sections {
        gap: .25rem;
        min-height: 2.8rem;
    }

    .accounting-pinned-section {
        width: 4.65rem;
        min-height: 2.8rem;
        padding: .3rem .35rem;
        font-size: .68rem;
    }

    .accounting-pinned-section i {
        font-size: 1rem;
    }

    .accounting-page-actions {
        gap: .25rem;
        margin-left: auto;
    }

    .accounting-page-action {
        min-width: 4.35rem;
        min-height: 2.8rem;
        padding: .3rem .35rem;
        font-size: .68rem;
    }

    .accounting-page-action i {
        font-size: .95rem;
    }

    .accounting-setup-warning-body {
        align-items: flex-start;
        flex-direction: column;
    }

    .accounting-setup-warning-actions {
        justify-content: flex-start;
    }

    .accounting-form-grid {
        grid-template-columns: 1fr;
    }

    .accounting-field,
    .accounting-field-sm,
    .accounting-field-lg,
    .accounting-field-full {
        grid-column: 1 / -1;
    }
}

@media (max-width: 575.98px) {
    .accounting-app .accounting-toolbar-container {
        padding-left: .75rem !important;
        padding-right: .75rem !important;
    }

    .accounting-desktop-chrome.mb-4,
    .accounting-app .accounting-desktop-chrome.mb-4 {
        margin-bottom: .75rem !important;
    }

    .accounting-icon-bar,
    .accounting-app .accounting-icon-bar {
        gap: .25rem;
        min-height: 2.85rem;
        padding: .25rem .35rem;
        scrollbar-width: thin;
    }

    .accounting-pinned-sections,
    .accounting-app .accounting-pinned-sections {
        display: none;
        gap: .2rem;
        min-height: 2.35rem;
    }

    .accounting-app .accounting-home-link {
        order: -2;
    }

    .accounting-app .accounting-pin-current-page {
        display: none;
    }

    .accounting-pinned-section,
    .accounting-app .accounting-pinned-section,
    .accounting-page-action,
    .accounting-app .accounting-page-action {
        flex: 0 0 auto;
        width: 2.45rem;
        min-width: 2.45rem;
        min-height: 2.35rem;
        padding: .25rem;
        gap: 0;
    }

    .accounting-pinned-section span:not(.accounting-pinned-unpin),
    .accounting-page-action span {
        display: none;
    }

    .accounting-pinned-section i,
    .accounting-app .accounting-pinned-section i,
    .accounting-page-action i,
    .accounting-app .accounting-page-action i {
        font-size: 1rem;
    }

    .accounting-page-actions,
    .accounting-app .accounting-page-actions {
        gap: .2rem;
        margin-left: auto;
    }

    .accounting-pinned-unpin {
        top: .08rem;
        right: .08rem;
        width: 1rem;
        height: 1rem;
    }

    .accounting-pinned-unpin i {
        font-size: .62rem;
    }
}

body.accounting-app {
    --accounting-theme-border: var(--seconday-panel-color, rgba(167, 174, 184, .45));
    --accounting-theme-panel: var(--primary-panel-color, #ffffff);
    --accounting-theme-page: var(--primary-background-color, #f2f6fc);
    --accounting-theme-soft: var(--seconday-panel-color, rgba(33, 40, 50, .05));
    --accounting-theme-accent: var(--primary-color, #0061f2);
    --accounting-theme-accent-alt: var(--secondary-card-color, #337ab7);
    color: var(--primary-text-color);
}

.accounting-app .text-primary,
.accounting-app .text-primary-soft,
.accounting-app a.text-primary {
    color: var(--accounting-theme-accent) !important;
}

.accounting-app .bg-primary,
.accounting-app .text-bg-primary {
    background-color: var(--accounting-theme-accent) !important;
    color: var(--alternative-text-color) !important;
}

.accounting-app .bg-primary-soft,
.accounting-app .text-bg-primary-soft {
    background-color: var(--accounting-theme-soft) !important;
    color: var(--accounting-theme-accent) !important;
}

.accounting-app .border-primary,
.accounting-app .border-primary-soft {
    border-color: var(--accounting-theme-accent) !important;
}

.accounting-app .btn-outline-primary {
    --bs-btn-color: var(--accounting-theme-accent);
    --bs-btn-border-color: var(--accounting-theme-accent);
    --bs-btn-hover-color: var(--alternative-text-color);
    --bs-btn-hover-bg: var(--accounting-theme-accent);
    --bs-btn-hover-border-color: var(--accounting-theme-accent);
    --bs-btn-active-color: var(--alternative-text-color);
    --bs-btn-active-bg: var(--accounting-theme-accent);
    --bs-btn-active-border-color: var(--accounting-theme-accent);
    color: var(--accounting-theme-accent) !important;
    border-color: var(--accounting-theme-accent) !important;
}

.accounting-app .btn-outline-primary:hover,
.accounting-app .btn-outline-primary:focus,
.accounting-app .btn-outline-primary:active {
    color: var(--alternative-text-color) !important;
    background-color: var(--accounting-theme-accent) !important;
    border-color: var(--accounting-theme-accent) !important;
}

.accounting-app .accounting-action-busy {
    pointer-events: none;
    cursor: wait;
    opacity: .8;
}

.accounting-app .accounting-action-busy .spinner-border {
    vertical-align: -.125em;
}

.accounting-app main > .container-fluid:first-child {
    margin-bottom: 0 !important;
}

.accounting-app .accounting-toolbar-container {
    margin-bottom: 0 !important;
}

.accounting-app .accounting-page-header-main {
    margin-top: 0;
}

.accounting-app .accounting-breadcrumb,
.project-management-app .page-header nav .breadcrumb,
.supplier-workspace-app .page-header nav .breadcrumb {
    align-items: center;
    background: var(--primary-panel-color);
    border: 1px solid var(--seconday-panel-color);
    box-shadow: 0 0.1rem 0.35rem var(--primary-shadow-color);
    gap: .15rem;
}

.accounting-app .accounting-breadcrumb .breadcrumb-item,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item {
    align-items: center;
    display: inline-flex;
    font-size: .84rem;
    min-width: 0;
}

.accounting-app .accounting-breadcrumb .breadcrumb-item a,
.accounting-app .accounting-breadcrumb .breadcrumb-item.active,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item a,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item a,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item.active,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item.active {
    align-items: center;
    display: inline-flex;
    gap: .4rem;
    max-width: 22rem;
    min-width: 0;
}

.accounting-app .accounting-breadcrumb .breadcrumb-item a,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item a,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item a {
    color: var(--primary-color) !important;
    font-weight: 600;
    text-decoration: none;
}

.accounting-app .accounting-breadcrumb .breadcrumb-item a:hover,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item a:hover,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item a:hover {
    text-decoration: underline;
}

.accounting-app .accounting-breadcrumb .breadcrumb-item span,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item span,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.accounting-app .accounting-breadcrumb .breadcrumb-item i,
.project-management-app .page-header nav .breadcrumb .breadcrumb-item i,
.supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item i {
    color: var(--primary-color);
    flex: 0 0 auto;
    font-size: .78rem;
}

.accounting-app .accounting-page-header-main .page-header-title {
    color: var(--primary-text-color) !important;
    font-size: clamp(1rem, 1.25vw, 1.15rem);
    font-weight: 700;
}

.accounting-app .accounting-page-header-main .page-header-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.accounting-app .accounting-page-header-main .page-header-icon i {
    color: var(--primary-color);
    font-size: 1.05rem;
}

.accounting-app .accounting-page-header-main + .container-fluid.px-4.mt-4 {
    margin-top: 0 !important;
}

.accounting-app main > .container-fluid.px-4:not(.accounting-toolbar-container) {
    padding-bottom: 1.5rem;
}

@media (max-width: 575.98px) {
    .accounting-app main > .container-fluid.px-4:not(.accounting-toolbar-container) {
        padding-right: .75rem !important;
        padding-left: .75rem !important;
    }

    .accounting-app .accounting-breadcrumb .breadcrumb-item a,
    .accounting-app .accounting-breadcrumb .breadcrumb-item.active,
    .project-management-app .page-header nav .breadcrumb .breadcrumb-item a,
    .supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item a,
    .project-management-app .page-header nav .breadcrumb .breadcrumb-item.active,
    .supplier-workspace-app .page-header nav .breadcrumb .breadcrumb-item.active {
        max-width: 11rem;
    }
}

.accounting-app .accounting-desktop-chrome {
    border: 0;
    border-radius: .35rem;
    background: var(--primary-panel-color);
    box-shadow: 0 0 0.5rem var(--primary-shadow-color) !important;
    overflow: hidden;
}

.accounting-app .accounting-icon-bar {
    gap: .2rem;
    min-height: 3.65rem;
    padding: .25rem .45rem;
    background: var(--primary-panel-color) !important;
    border-bottom: 1px solid var(--seconday-panel-color);
}

.accounting-app .accounting-pinned-sections {
    gap: .2rem;
    min-height: 3.15rem;
}

.accounting-app .accounting-pinned-section,
.accounting-app .accounting-page-action {
    display: inline-flex;
    flex: 0 0 4.75rem;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 4.75rem;
    min-width: 4.75rem;
    height: 3.15rem;
    min-height: 3.15rem;
    padding: .2rem .3rem;
    gap: .1rem;
    font-size: .7rem;
    line-height: 1.05;
    text-align: center;
    white-space: normal;
}

.accounting-app .accounting-pinned-section > i,
.accounting-app .accounting-page-action > i {
    display: inline-flex;
    width: 1rem;
    height: 1rem;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    line-height: 1;
}

.accounting-app .accounting-pinned-section > span:not(.accounting-pinned-unpin),
.accounting-app .accounting-page-action > span {
    width: 100%;
    line-height: 1.1;
    overflow-wrap: anywhere;
}

.accounting-app .accounting-home-link {
    cursor: pointer;
    touch-action: auto;
}

.accounting-app .accounting-pinned-section,
.accounting-app .accounting-page-action,
.accounting-app .accounting-section-pin,
.accounting-app .accounting-item-pin {
    border-radius: .25rem;
}

.accounting-app .accounting-pinned-section {
    color: var(--primary-text-color);
}

.accounting-app .accounting-pinned-section:hover,
.accounting-app .accounting-pinned-section:focus,
.accounting-app .accounting-pinned-section.is-editing,
.accounting-app .accounting-pinned-sections.is-editing .accounting-pinned-section {
    background: var(--seconday-panel-color);
    border-color: var(--seconday-panel-color);
}

.accounting-app .accounting-page-actions {
    gap: .2rem;
}

/* Keep the compact control height without forcing long primary actions onto
   three lines. Secondary actions retain the narrower shared width. */
@media (min-width: 768px) {
    .accounting-app .accounting-page-action.accounting-page-action-primary {
        flex-basis: 5.75rem;
        width: 5.75rem;
        min-width: 5.75rem;
    }
}

@media (min-width: 576px) and (max-width: 767.98px) {
    .accounting-app .accounting-page-action.accounting-page-action-primary {
        flex-basis: 5.25rem;
        width: 5.25rem;
        min-width: 5.25rem;
    }
}

.accounting-app .accounting-page-action {
    border: 1px solid var(--seconday-panel-color) !important;
    background: var(--seconday-panel-color) !important;
    color: var(--primary-color) !important;
    box-shadow: none !important;
}

.accounting-app .accounting-page-action:hover,
.accounting-app .accounting-page-action:focus {
    border-color: var(--primary-color) !important;
    color: var(--primary-color) !important;
}

.accounting-app .accounting-page-action.btn-outline-primary:hover,
.accounting-app .accounting-page-action.btn-outline-primary:focus,
.accounting-app .accounting-page-action.btn-outline-primary:active {
    background: var(--accounting-theme-soft) !important;
    border-color: var(--accounting-theme-accent) !important;
    color: var(--accounting-theme-accent) !important;
}

.accounting-app .accounting-page-action.btn-outline-primary:hover i,
.accounting-app .accounting-page-action.btn-outline-primary:hover span,
.accounting-app .accounting-page-action.btn-outline-primary:focus i,
.accounting-app .accounting-page-action.btn-outline-primary:focus span,
.accounting-app .accounting-page-action.btn-outline-primary:active i,
.accounting-app .accounting-page-action.btn-outline-primary:active span {
    color: var(--accounting-theme-accent) !important;
}

.accounting-app .accounting-page-action.btn-primary,
.accounting-app .accounting-page-action.accounting-page-action-primary {
    border-color: var(--primary-color) !important;
    background: var(--primary-color) !important;
    color: var(--alternative-text-color) !important;
    box-shadow: 0 .15rem .4rem color-mix(in srgb, var(--primary-color) 28%, transparent) !important;
}

.accounting-app .accounting-page-action.btn-primary i,
.accounting-app .accounting-page-action.btn-primary span,
.accounting-app .accounting-page-action.accounting-page-action-primary i,
.accounting-app .accounting-page-action.accounting-page-action-primary span {
    color: var(--alternative-text-color) !important;
}

.accounting-app .accounting-page-action.accounting-page-action-primary:hover,
.accounting-app .accounting-page-action.accounting-page-action-primary:focus,
.accounting-app .accounting-page-action.accounting-page-action-primary:active {
    border-color: color-mix(in srgb, var(--primary-color) 82%, black) !important;
    background: color-mix(in srgb, var(--primary-color) 88%, black) !important;
    color: var(--alternative-text-color) !important;
}

.accounting-app .accounting-page-action.accounting-page-action-primary:focus-visible {
    box-shadow: 0 0 0 .18rem color-mix(in srgb, var(--primary-color) 30%, transparent) !important;
}

.accounting-app .accounting-page-action.is-pinned,
.accounting-app .accounting-item-pin.is-pinned,
.accounting-app .accounting-section-pin.is-pinned {
    color: var(--accounting-theme-accent-alt) !important;
    border-color: var(--accounting-theme-accent-alt) !important;
    background: var(--accounting-theme-soft) !important;
}

@media (max-width: 767.98px) {
    .accounting-app .accounting-icon-bar {
        gap: .2rem;
        min-height: 3.35rem;
        padding: .2rem .35rem;
    }

    .accounting-app .accounting-pinned-sections {
        gap: .2rem;
        min-height: 2.9rem;
    }

    .accounting-app .accounting-pinned-section,
    .accounting-app .accounting-page-action {
        flex-basis: 4.25rem;
        width: 4.25rem;
        min-width: 4.25rem;
        height: 2.9rem;
        min-height: 2.9rem;
        padding: .15rem .25rem;
        font-size: .65rem;
    }

    .accounting-app .accounting-pinned-section i,
    .accounting-app .accounting-page-action i {
        font-size: 1rem;
    }

    .accounting-app .accounting-page-actions {
        gap: .2rem;
        margin-left: auto;
    }

}

@media (max-width: 575.98px) {
    .accounting-app .accounting-icon-bar {
        gap: .25rem;
        min-height: 2.85rem;
        padding: .25rem .35rem;
        scrollbar-width: thin;
    }

    .accounting-app .accounting-pinned-sections {
        gap: .2rem;
        min-height: 2.35rem;
    }

    .accounting-app .accounting-pinned-section,
    .accounting-app .accounting-page-action {
        display: inline-flex;
        flex: 0 0 auto;
        align-items: center;
        justify-content: center;
        width: 2.45rem;
        min-width: 2.45rem;
        height: 2.35rem;
        min-height: 2.35rem;
        padding: .25rem;
        gap: 0;
    }

    .accounting-app .accounting-pinned-section span:not(.accounting-pinned-unpin),
    .accounting-app .accounting-page-action span {
        display: none;
    }

    .accounting-app .accounting-pinned-section i,
    .accounting-app .accounting-page-action i {
        font-size: 1rem;
    }

    .accounting-app .accounting-page-actions {
        flex: 0 0 auto;
        gap: .2rem;
        margin-left: 0;
        order: -1;
    }
}

.accounting-app .container-fluid.px-4.mt-4 > .border.bg-white.p-3,
.accounting-app .container-fluid.px-4 > .border.bg-white.p-3,
.accounting-app .row .border.bg-white.p-3,
.accounting-app .modal-body .border.p-3 {
    border: 0 !important;
    border-radius: .35rem;
    background: var(--primary-panel-color) !important;
    box-shadow: 0 0 0.5rem var(--primary-shadow-color) !important;
}

.accounting-app .container-fluid.px-4.mt-4 > .border.bg-white.p-3.mb-4,
.accounting-app .container-fluid.px-4 > .border.bg-white.p-3.mb-4 {
    margin-bottom: 1rem !important;
}

.accounting-app .container-fluid.px-4.mt-4 > .border.bg-white.p-3.mb-4 h1,
.accounting-app .container-fluid.px-4 > .border.bg-white.p-3.mb-4 h1 {
    margin-bottom: .15rem !important;
    color: var(--primary-text-color);
    font-size: 1.25rem;
    font-weight: 700;
}

.accounting-app .container-fluid.px-4.mt-4 > .border.bg-white.p-3.mb-4 .text-muted,
.accounting-app .container-fluid.px-4 > .border.bg-white.p-3.mb-4 .text-muted {
    color: var(--secondary-text-color) !important;
}

.accounting-app .container-fluid.px-4:not(.accounting-toolbar-container) > .alert:not(.d-none) {
    padding: .75rem 1rem;
    border-width: 0 0 0 .25rem;
    border-radius: .35rem;
    box-shadow: 0 .1rem .35rem var(--primary-shadow-color);
    font-size: .875rem;
}

.accounting-app .container-fluid.px-4 .border.bg-white.p-3 > h2.h5,
.accounting-app .container-fluid.px-4 .border.bg-white.p-3 > h3.h6 {
    color: var(--primary-text-color);
    font-weight: 700;
}

.accounting-app .row.g-3.mb-3 > [class*="col-"] > .border.bg-white.p-3.h-100:not(a) {
    display: flex;
    min-height: 6rem;
    flex-direction: column;
    justify-content: center;
}

.accounting-app .row.g-3.mb-3 > [class*="col-"] > .border.bg-white.p-3.h-100:not(a) .h4,
.accounting-app .row.g-3.mb-3 > [class*="col-"] > .border.bg-white.p-3.h-100:not(a) .h5,
.accounting-app .row.g-3.mb-3 > [class*="col-"] > .border.bg-white.p-3.h-100:not(a) .fs-4 {
    font-variant-numeric: tabular-nums;
}

.accounting-app a.border.bg-white.p-3.h-100.d-block {
    min-height: 7.25rem;
    border: 1px solid transparent !important;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.accounting-app a.border.bg-white.p-3.h-100.d-block:hover,
.accounting-app a.border.bg-white.p-3.h-100.d-block:focus-visible {
    border-color: var(--accounting-theme-accent) !important;
    box-shadow: 0 .25rem .8rem var(--primary-shadow-color) !important;
    transform: translateY(-1px);
    outline: 0;
}

.accounting-app a.border.bg-white.p-3.h-100.d-block > i {
    font-size: 1.15rem;
}

.accounting-app .form-label,
.accounting-app label {
    color: var(--primary-text-color);
    font-weight: 600;
}

.accounting-app .form-select,
.accounting-app .form-control,
.accounting-app textarea.form-control {
    color: var(--primary-text-color);
    background-color: var(--primary-panel-color) !important;
    border: 1px solid var(--seconday-panel-color) !important;
    border-radius: .25rem;
}

.accounting-app .form-select:focus,
.accounting-app .form-control:focus,
.accounting-app textarea.form-control:focus {
    background-color: var(--primary-background-color) !important;
    border-color: var(--primary-text-color) !important;
    box-shadow: 0 0 0 0 white !important;
}

.accounting-app .form-select.is-invalid,
.accounting-app .form-control.is-invalid,
.accounting-app textarea.form-control.is-invalid {
    border-color: var(--notification-color, #dc3545) !important;
    background-image: none;
}

.accounting-app .accounting-form-status {
    border-color: var(--seconday-panel-color);
    background: var(--primary-panel-color);
    box-shadow: 0 0 0.5rem var(--primary-shadow-color) !important;
}

.accounting-app .form-check-input {
    border-color: var(--seconday-panel-color);
}

.accounting-app .badge.bg-light,
.accounting-app .badge.text-dark {
    background: var(--seconday-panel-color) !important;
    color: var(--primary-text-color) !important;
}

/* Accounting grid filter system
   Give every register the same control rhythm and keep visibility switches
   together so their meaning is easy to scan. */
.accounting-app .accounting-grid-filter-row,
.accounting-app .supplier-centre-panel > .row.g-3.align-items-end {
    --bs-gutter-x: 1rem;
    --bs-gutter-y: .75rem;
}

.accounting-app .accounting-grid-filter-row > [class*="col-"],
.accounting-app .supplier-centre-panel > .row.g-3.align-items-end > [class*="col-"] {
    min-width: 0;
}

.accounting-app .accounting-grid-filter-row .form-label,
.accounting-app .supplier-centre-panel > .row.g-3.align-items-end .form-label {
    margin-bottom: .35rem;
    color: var(--primary-text-color);
    font-size: .82rem;
    font-weight: 600;
}

.accounting-app .accounting-grid-filter-row .form-control,
.accounting-app .accounting-grid-filter-row .form-select,
.accounting-app .supplier-centre-panel > .row.g-3.align-items-end .form-control,
.accounting-app .supplier-centre-panel > .row.g-3.align-items-end .form-select {
    min-height: 2.4rem;
}

.accounting-app .accounting-grid-filter-row .form-control::placeholder {
    color: var(--secondary-text-color);
    opacity: .72;
}

.accounting-app .accounting-grid-filter-toggles {
    display: flex;
    min-height: 2.4rem;
    flex-direction: column;
    justify-content: flex-end;
    gap: .35rem;
}

.accounting-app .accounting-grid-filter-toggle {
    display: flex;
    min-height: 1.35rem;
    align-items: center;
    gap: .55rem;
    margin: 0;
    padding-left: 0;
}

.accounting-app .accounting-grid-filter-toggle .form-check-input {
    flex: 0 0 auto;
    width: 2rem;
    height: 1.05rem;
    margin: 0;
    margin-left: 0;
}

.accounting-app .accounting-grid-filter-toggle .form-check-label {
    color: var(--primary-text-color);
    line-height: 1.2;
}

.accounting-app .accounting-grid-filter-meta {
    display: flex;
    min-height: 2.4rem;
    align-items: center;
    justify-content: flex-end;
    gap: .5rem;
    flex-wrap: wrap;
}

.accounting-app .accounting-grid-filter-meta .btn {
    display: inline-flex;
    min-height: 2.4rem;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.accounting-app .accounting-grid-filter-meta .badge {
    display: inline-flex;
    min-height: 1.75rem;
    align-items: center;
    padding: .35rem .55rem;
    font-weight: 600;
}

.accounting-app .accounting-report-filter-panel {
    overflow: hidden;
    border: 1px solid var(--seconday-panel-color);
    border-radius: .45rem;
    background: var(--primary-panel-color);
    box-shadow: 0 .1rem .45rem var(--primary-shadow-color);
}

.accounting-app .accounting-report-filter-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .8rem 1rem;
    border-bottom: 1px solid var(--seconday-panel-color);
    background: var(--accounting-theme-soft);
}

.accounting-app .accounting-report-filter-heading {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: .75rem;
}

.accounting-app .accounting-report-filter-icon {
    display: inline-flex;
    flex: 0 0 2.15rem;
    width: 2.15rem;
    height: 2.15rem;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--seconday-panel-color);
    border-radius: .4rem;
    color: var(--primary-color);
    background: var(--primary-panel-color);
}

.accounting-app .accounting-report-filter-title {
    margin: 0;
    color: var(--primary-text-color);
    font-size: .95rem;
    font-weight: 700;
    line-height: 1.25;
}

.accounting-app .accounting-report-filter-description {
    margin-top: .12rem;
    color: var(--secondary-text-color);
    font-size: .76rem;
    line-height: 1.35;
}

.accounting-app .accounting-report-filter-status {
    flex: 0 0 auto;
}

.accounting-app .accounting-report-filter-body {
    padding: 1rem;
}

.accounting-app .accounting-report-directory-filters {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: .75rem;
}

.accounting-app .accounting-report-search-wrap {
    flex: 1 1 22rem;
    max-width: 32rem;
}

.accounting-app .accounting-report-search-wrap .form-label {
    margin-bottom: .35rem;
    color: var(--primary-text-color);
    font-size: .82rem;
    font-weight: 600;
}

.accounting-app .accounting-report-search-wrap .input-group-text {
    min-height: 2.4rem;
    color: var(--secondary-text-color);
    background: var(--primary-panel-color);
    border-color: var(--seconday-panel-color);
}

.accounting-app .accounting-report-search {
    min-width: 0;
    min-height: 2.4rem;
}

.accounting-app .accounting-report-favorites-filter {
    min-height: 2.4rem;
    white-space: nowrap;
}

@media (min-width: 1200px) {
    .accounting-app .accounting-bank-filter-row > [class*="accounting-bank-filter-"] {
        width: auto;
        min-width: 0;
        max-width: none;
    }

    .accounting-app .accounting-bank-filter-account,
    .accounting-app .accounting-bank-filter-search {
        flex: 1.2 1 13rem;
    }

    .accounting-app .accounting-bank-filter-date,
    .accounting-app .accounting-bank-filter-status {
        flex: .8 1 9rem;
    }

    .accounting-app .accounting-bank-filter-actions {
        flex: 0 0 auto;
        width: auto;
        margin-left: auto;
        white-space: nowrap;
    }
}

.accounting-app .accounting-line-grid-footer {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: .75rem;
    margin-top: .75rem;
    flex-wrap: wrap;
}

.accounting-app .accounting-line-grid-summary {
    margin-right: auto;
}

.accounting-app .accounting-line-grid-footer [data-accounting-add-line] {
    min-width: 8.5rem;
}

.accounting-app .accounting-import-mode-switch {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .75rem;
    margin-bottom: .75rem;
}

.accounting-app .accounting-import-mode-button {
    display: flex;
    align-items: center;
    gap: .75rem;
    min-width: 0;
    padding: .8rem .9rem;
    border: 1px solid var(--bs-border-color);
    border-radius: .5rem;
    color: var(--primary-text-color);
    background: var(--primary-panel-color);
    text-align: left;
    transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
}

.accounting-app .accounting-import-mode-button:hover {
    border-color: var(--primary-color);
    background: var(--accounting-theme-soft);
}

.accounting-app .accounting-import-mode-button.active {
    border-color: var(--primary-color);
    background: var(--accounting-theme-soft);
    box-shadow: inset 0 0 0 1px var(--primary-color);
}

.accounting-app .accounting-import-mode-icon {
    display: inline-flex;
    flex: 0 0 2.25rem;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    color: var(--primary-color);
    background: var(--primary-panel-color);
}

.accounting-app .accounting-import-mode-title,
.accounting-app .accounting-import-mode-description {
    display: block;
}

.accounting-app .accounting-import-mode-title {
    font-weight: 700;
}

.accounting-app .accounting-import-mode-description {
    margin-top: .1rem;
    color: var(--secondary-text-color);
    font-size: .78rem;
}

.accounting-app .accounting-import-mode-panel {
    min-height: 4rem;
    padding: .9rem;
    border: 1px solid var(--bs-border-color);
    border-radius: .5rem;
    background: var(--bs-light);
}

.accounting-app .accounting-statement-file-picker {
    display: flex;
    align-items: center;
    gap: .9rem;
}

.accounting-app .accounting-statement-file-icon {
    display: inline-flex;
    flex: 0 0 3rem;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: .5rem;
    color: var(--primary-color);
    background: var(--accounting-theme-soft);
    font-size: 1.25rem;
}

.accounting-app .accounting-statement-line-grid {
    max-height: min(44vh, 32rem);
    border-radius: .35rem;
}

.accounting-app .accounting-statement-line-table {
    min-width: 930px;
    table-layout: fixed;
}

.accounting-app .accounting-statement-line-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
}

@media (max-width: 767.98px) {
    .accounting-app .accounting-grid-filter-meta {
        justify-content: flex-start;
    }

    .accounting-app .accounting-report-filter-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .accounting-app .accounting-report-filter-status {
        width: 100%;
    }

    .accounting-app .accounting-report-filter-body {
        padding: .8rem;
    }

    .accounting-app .accounting-report-directory-filters {
        align-items: stretch;
        flex-direction: column;
    }

    .accounting-app .accounting-report-search-wrap {
        flex-basis: auto;
        max-width: none;
        width: 100%;
    }

    .accounting-app .accounting-report-favorites-filter {
        width: 100%;
    }

    .accounting-app .accounting-import-mode-switch {
        grid-template-columns: 1fr;
    }

    .accounting-app .accounting-statement-file-picker {
        align-items: stretch;
        flex-direction: column;
    }

    .accounting-app .accounting-statement-file-picker .btn {
        align-self: stretch !important;
    }
}

/* Accounting modal system
   Keep every capture form on the same visual and responsive rhythm, including
   modals that are assembled dynamically by the quick-create helpers. */
.accounting-app .modal {
    --bs-modal-padding: 1.25rem;
    --bs-modal-header-padding: 1rem 1.25rem;
    --bs-modal-border-radius: .5rem;
    --bs-modal-inner-border-radius: .5rem;
    --accounting-form-gap: 1rem;
    --accounting-control-height: 2.4rem;
    --accounting-control-radius: .3rem;
}

.accounting-app .modal-dialog {
    max-height: calc(100vh - 2rem);
    max-height: calc(100dvh - 2rem);
}

.accounting-app .modal-content {
    max-height: calc(100vh - 2rem);
    max-height: calc(100dvh - 2rem);
    overflow: hidden;
    border: 0;
    border-radius: var(--bs-modal-border-radius);
    box-shadow: 0 .5rem 2rem var(--primary-shadow-color, rgba(15, 23, 42, .22)) !important;
}

.accounting-app .modal-header,
.accounting-app .modal-footer {
    flex: 0 0 auto;
    background: var(--primary-panel-color, #fff);
    border-color: var(--seconday-panel-color, #dfe3e8);
}

.accounting-app .modal-header {
    align-items: flex-start;
    gap: 1rem;
}

.accounting-app .modal-title {
    margin: 0;
    color: var(--primary-text-color, #1f2937) !important;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.4;
}

.accounting-app .modal-header .text-muted {
    margin-top: .15rem;
    color: var(--secondary-text-color, #69707a) !important;
    line-height: 1.4;
}

.accounting-app .modal-header .btn-close {
    flex: 0 0 auto;
    margin: 0 0 0 auto;
    opacity: .65;
}

.accounting-app .modal-header .btn-close:hover,
.accounting-app .modal-header .btn-close:focus {
    opacity: 1;
}

.accounting-app .modal-body {
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    background: var(--primary-background-color, #f7f8fa);
}

.accounting-app .modal-content.accounting-modal-is-loading {
    position: relative;
}

.accounting-app .modal-content.accounting-modal-is-loading > .modal-body,
.accounting-app .modal-content.accounting-modal-is-loading > .modal-footer {
    pointer-events: none;
    user-select: none;
    opacity: .48;
    filter: saturate(.65);
    transition: opacity .12s ease;
}

.accounting-modal-loading-overlay {
    position: absolute;
    z-index: 8;
    top: 50%;
    left: 50%;
    display: flex;
    width: min(28rem, calc(100% - 2rem));
    min-height: 5rem;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.15rem;
    color: var(--primary-text-color, #1f2937);
    background: var(--primary-panel-color, #fff);
    border: 1px solid color-mix(in srgb, var(--primary-color, #0d6efd) 32%, transparent);
    border-radius: .6rem;
    box-shadow: 0 .75rem 2rem rgba(15, 23, 42, .2);
    transform: translate(-50%, -50%);
}

.accounting-modal-loading-spinner {
    flex: 0 0 auto;
    width: 1.65rem;
    height: 1.65rem;
    color: var(--primary-color, #0d6efd);
    border-width: .18rem;
}

.accounting-modal-loading-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: .15rem;
}

.accounting-modal-loading-label {
    font-size: .95rem;
    line-height: 1.35;
}

.accounting-modal-loading-hint {
    color: var(--secondary-text-color, #69707a);
    font-size: .78rem;
    line-height: 1.35;
}

@media (max-width: 575.98px) {
    .accounting-modal-loading-overlay {
        top: 42%;
    }
}

.accounting-app .modal-body > :last-child {
    margin-bottom: 0 !important;
}

.accounting-app .modal-body .row.g-3 {
    --bs-gutter-x: var(--accounting-form-gap);
    --bs-gutter-y: var(--accounting-form-gap);
}

.accounting-app .modal-body .accounting-form-grid {
    gap: var(--accounting-form-gap);
}

.accounting-app .modal-body .row > [class*="col-"],
.accounting-app .modal-body .accounting-field {
    min-width: 0;
}

.accounting-app .modal-body .form-label {
    margin-bottom: .35rem;
    font-size: .82rem;
    font-weight: 600;
    line-height: 1.35;
}

.accounting-app .modal-body .form-control,
.accounting-app .modal-body .form-select,
.accounting-app .modal-body .searchable-select-toggle {
    width: 100%;
    min-height: var(--accounting-control-height);
    padding: .45rem .65rem;
    border-radius: var(--accounting-control-radius);
    font-size: .875rem;
    line-height: 1.35;
}

.accounting-app .modal-body .form-control::placeholder {
    color: var(--secondary-text-color, #69707a);
    opacity: .72;
}

.accounting-app .modal-body .form-control:disabled,
.accounting-app .modal-body .form-select:disabled,
.accounting-app .modal-body .form-control[readonly] {
    color: var(--secondary-text-color, #69707a);
    background-color: var(--seconday-panel-color, #eef1f5) !important;
    cursor: not-allowed;
    opacity: 1;
}

.accounting-app .modal-body input[type="number"].form-control {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.accounting-app .modal-body textarea.form-control,
.accounting-app .modal-body input[type="file"].form-control {
    height: auto;
}

.accounting-app .modal-body textarea.form-control {
    min-height: 4.75rem;
    resize: vertical;
}

.accounting-app .modal-body input[type="file"].form-control {
    padding: .3rem .4rem;
}

.accounting-app .modal-body input[type="file"].form-control::file-selector-button {
    margin: -.3rem .65rem -.3rem -.4rem;
    padding: .45rem .7rem;
}

.accounting-app .modal-body .accounting-date-input,
.accounting-app .modal-body .searchable-select {
    min-height: var(--accounting-control-height);
}

.accounting-app .modal-body .accounting-date-input > .form-control {
    padding-right: 2.75rem;
}

.accounting-app .modal-body .accounting-date-input-button {
    width: 1.85rem;
    height: 1.85rem;
}

.accounting-app .modal-body .input-group > .btn,
.accounting-app .modal-body .input-group > .input-group-text {
    min-height: var(--accounting-control-height);
    padding: .45rem .65rem;
    font-size: .82rem;
}

.accounting-app .modal-body .form-text,
.accounting-app .modal-body .accounting-field-note {
    margin-top: .3rem;
    color: var(--secondary-text-color, #69707a) !important;
    font-size: .75rem;
    line-height: 1.4;
}

.accounting-app .modal-body .form-check {
    display: flex;
    align-items: flex-start;
    gap: .45rem;
    min-height: 1.5rem;
    margin-bottom: 0;
    padding-left: 0;
}

.accounting-app .modal-body .form-check-input {
    flex: 0 0 auto;
    width: 1.05rem;
    height: 1.05rem;
    margin: .12rem 0 0;
}

.accounting-app .modal-body .form-switch .form-check-input {
    width: 2rem;
    margin-left: 0;
}

.accounting-app .modal-body .form-check-label {
    font-size: .84rem;
    font-weight: 500;
    line-height: 1.4;
}

.accounting-app .modal-body .border.p-3 {
    padding: 1rem !important;
    border: 1px solid var(--seconday-panel-color, #dfe3e8) !important;
    border-radius: .4rem;
    background: var(--primary-panel-color, #fff) !important;
    box-shadow: none !important;
}

.accounting-app .modal-body .border.p-3 > h3.h6,
.accounting-app .modal-body .border.p-3 > h4.h6 {
    margin-bottom: .85rem !important;
    color: var(--primary-text-color, #1f2937) !important;
    font-size: .85rem;
    font-weight: 700;
}

.accounting-app .modal-body .table-responsive {
    border: 1px solid var(--seconday-panel-color, #dfe3e8);
    border-radius: .35rem;
    background: var(--primary-panel-color, #fff);
}

.accounting-app .modal-body .table-responsive > .table,
.accounting-app .modal-body .table-responsive > .accounting-capture-table {
    margin-bottom: 0;
    border: 0;
}

.accounting-app .modal-body .invalid-feedback {
    margin-top: .3rem;
    font-size: .75rem;
    line-height: 1.35;
}

.accounting-app .modal-body [data-accounting-validation-summary]:not(.d-none) {
    padding: .7rem .85rem;
    border-width: 0 0 0 .25rem;
    border-radius: .25rem;
    font-size: .8rem;
    line-height: 1.45;
}

.accounting-app .modal-footer {
    gap: .5rem;
    padding: .875rem 1.25rem;
}

.accounting-app .modal-footer > * {
    margin: 0;
}

.accounting-app .modal-footer .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 6.75rem;
    min-height: 2.35rem;
    padding: .45rem .85rem;
    font-size: .82rem;
    font-weight: 600;
    line-height: 1.25;
}

.accounting-app .modal-footer .btn i {
    flex: 0 0 auto;
}

.dmr-accounting-dialog {
    /* Above DevExtreme overlays (dropdown menus start at 1501) so an
       action menu that is still open can never cover the dialog. */
    z-index: 5000;
}

.dmr-accounting-dialog-container {
    width: min(100% - 2rem, 31rem);
}

.dmr-accounting-dialog .modal-content {
    max-height: calc(100dvh - 2rem);
}

.dmr-accounting-dialog .modal-body {
    background: var(--primary-panel-color, #fff);
}

.dmr-accounting-dialog-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: currentColor;
}

.dmr-accounting-dialog-icon i {
    color: #fff;
    font-size: .9rem;
}

.dmr-accounting-dialog-message {
    color: var(--primary-text-color, #1f2937);
    line-height: 1.55;
    white-space: pre-line;
}

.dmr-accounting-dialog-backdrop {
    z-index: 4995;
}

@media (max-width: 575.98px) {
    .accounting-app .modal {
        --bs-modal-margin: .5rem;
        --bs-modal-padding: 1rem;
        --bs-modal-header-padding: .875rem 1rem;
        --accounting-form-gap: .8rem;
    }

    .accounting-app .modal-dialog,
    .accounting-app .modal-content {
        max-height: calc(100vh - 1rem);
        max-height: calc(100dvh - 1rem);
    }

    .accounting-app .modal-footer {
        padding: .75rem 1rem;
    }

    .accounting-app .modal-footer .btn {
        flex: 1 1 calc(50% - .25rem);
        min-width: 0;
    }
}

.accounting-app .accounting-form-grid {
    gap: .75rem;
}

.accounting-app .accounting-capture-table {
    border: 1px solid var(--seconday-panel-color);
    border-collapse: collapse !important;
    font-size: 12px;
    line-height: 1.25;
}

.accounting-app .accounting-capture-table th,
.accounting-app .accounting-capture-table td {
    border: 1px solid var(--seconday-panel-color) !important;
    padding: .35rem .4rem !important;
    color: var(--primary-text-color);
    vertical-align: middle !important;
}

.accounting-app .accounting-capture-table thead th,
.accounting-app .accounting-capture-table tfoot th,
.accounting-app .accounting-capture-table tfoot td {
    background: var(--seconday-panel-color) !important;
    color: var(--primary-text-color) !important;
    font-weight: 700;
}

.accounting-app .accounting-capture-table tbody tr:hover td {
    background: var(--accounting-theme-soft) !important;
}

.accounting-app .accounting-capture-table .form-control,
.accounting-app .accounting-capture-table .form-select {
    min-height: 30px;
    min-width: 7rem;
    padding: .25rem .4rem;
    font-size: 12px;
}

.accounting-app .accounting-capture-table .searchable-select,
.accounting-app .accounting-capture-table .accounting-date-input {
    min-height: 30px;
}

.accounting-app .accounting-capture-table .accounting-date-input-button {
    width: 1.6rem;
    height: 1.6rem;
    right: .25rem;
}

.accounting-app .accounting-capture-table .btn-icon,
.accounting-app .dx-datagrid .btn-icon {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.accounting-app .accounting-grid-host {
    min-width: 0;
    width: 100%;
}

.accounting-app .accounting-grid-host .dx-datagrid {
    background: var(--primary-panel-color);
    border-radius: .35rem;
    overflow: hidden;
}

.accounting-app .accounting-grid-host .dx-datagrid-headers {
    border-bottom: 1px solid var(--seconday-panel-color);
}

.accounting-app .accounting-grid-host .dx-datagrid-header-panel {
    border-bottom: 1px solid var(--seconday-panel-color);
    background: var(--primary-panel-color);
}

.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-toolbar {
    padding: .6rem .65rem;
    background: transparent;
}

.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-toolbar-items-container {
    min-height: 2.4rem;
}

.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-button,
.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-texteditor {
    min-height: 2.4rem;
    border-radius: .25rem;
}

.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-button {
    border-color: var(--seconday-panel-color);
    background: var(--primary-panel-color);
    color: var(--primary-text-color);
}

.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-button:hover,
.accounting-app .accounting-grid-host .dx-datagrid-header-panel .dx-button:focus {
    border-color: var(--accounting-theme-accent);
    color: var(--accounting-theme-accent);
}

.accounting-app .accounting-grid-host .dx-pager {
    display: none !important;
}

.accounting-app .accounting-grid-host .dx-datagrid-headers .dx-row > td {
    background: var(--seconday-panel-color) !important;
    color: var(--primary-text-color) !important;
    font-weight: 700;
}

/* Shared grid sizing keeps the table at the panel width. Truncate content
   inside its assigned column instead of allowing controls or long values to
   expand the table and create a horizontal scrollbar. */
.accounting-app .accounting-grid-host .dx-datagrid-headers .dx-row > td,
.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-row > td {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.accounting-app .accounting-grid-host .accounting-grid-actions-column,
.accounting-app .dx-datagrid-rowsview .dx-row > td:has(.accounting-grid-action-menu) {
    text-align: right !important;
    width: 140px !important;
    min-width: 140px !important;
    max-width: 140px !important;
}

.accounting-app .accounting-grid-action-menu,
.accounting-app .accounting-grid-action-dropdown {
    display: inline-block;
    width: 8rem;
    min-width: 8rem;
    max-width: 8rem;
    margin-left: auto;
}

.accounting-app .accounting-grid-action-menu .dx-button {
    width: 100%;
    min-width: 0;
    max-width: 100%;
}

.accounting-app .accounting-grid-action-menu .dx-button-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Keep adaptive cells in the table's column sequence so header/body colgroups
   remain aligned, but make their raw text dimensionless. DevExtreme's theme
   only hides child elements; plain text nodes otherwise reopen hidden columns. */
.accounting-app .accounting-grid-host .dx-row > .dx-datagrid-hidden-column,
.accounting-app .accounting-grid-host .dx-row > .dx-command-adaptive-hidden {
    display: table-cell !important;
    width: 0 !important;
    min-width: 0 !important;
    max-width: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    overflow: hidden !important;
    color: transparent !important;
    font-size: 0 !important;
    line-height: 0 !important;
    white-space: nowrap !important;
}

.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-row {
    min-height: 40px;
}

.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-row > td {
    border-color: var(--seconday-panel-color) !important;
}

.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-row-alt > td {
    background: color-mix(in srgb, var(--accounting-theme-soft) 55%, var(--primary-panel-color)) !important;
}

.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-row.dx-state-hover > td {
    background: var(--accounting-theme-soft) !important;
}

.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-adaptive-detail-row > td {
    padding: .65rem !important;
    border-top: 0 !important;
    background: color-mix(in srgb, var(--accounting-theme-soft) 42%, var(--primary-panel-color)) !important;
}

.accounting-app .accounting-grid-adaptive-form {
    position: relative;
    padding: .75rem .75rem .1rem;
    border: 1px solid color-mix(in srgb, var(--accounting-theme-accent) 24%, var(--seconday-panel-color));
    border-left: 3px solid var(--accounting-theme-accent);
    border-radius: .35rem;
    background: var(--primary-panel-color);
    box-shadow: 0 .2rem .65rem color-mix(in srgb, var(--primary-shadow-color) 65%, transparent);
}

.accounting-app .accounting-grid-adaptive-form::before {
    display: block;
    margin-bottom: .65rem;
    color: var(--secondary-text-color);
    content: 'Additional details';
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.accounting-app .accounting-grid-adaptive-form .accounting-grid-adaptive-item {
    margin-bottom: .65rem;
    padding: .6rem .7rem;
    border: 1px solid var(--seconday-panel-color);
    border-radius: .3rem;
    background: color-mix(in srgb, var(--primary-panel-color) 92%, var(--accounting-theme-soft));
}

.accounting-app .accounting-grid-adaptive-form .dx-field-item-label {
    display: block;
    width: auto !important;
    margin-bottom: .18rem;
    padding: 0;
}

.accounting-app .accounting-grid-adaptive-form .dx-field-item-label-text {
    color: var(--secondary-text-color) !important;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .025em;
    text-transform: uppercase;
}

.accounting-app .accounting-grid-adaptive-form .dx-field-item-content {
    min-height: 1.25rem;
    color: var(--primary-text-color);
    font-size: .85rem;
    font-weight: 600;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.accounting-app .accounting-grid-adaptive-form .accounting-grid-adaptive-item-numeric .dx-field-item-content {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.accounting-app .accounting-grid-adaptive-form .dx-adaptive-item-text {
    min-height: 0;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    white-space: normal;
}

.accounting-app .accounting-grid-host .dx-command-adaptive {
    text-align: center !important;
}

.accounting-app .accounting-grid-host .dx-command-adaptive .dx-datagrid-adaptive-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    transition: background-color .15s ease-in-out;
}

.accounting-app .accounting-grid-host .dx-datagrid-adaptive-more::before {
    color: var(--accounting-theme-accent);
    content: '\f0fe';
    transform: none;
}

.accounting-app .accounting-grid-host tr:has(+ tr.dx-adaptive-detail-row) .dx-datagrid-adaptive-more::before {
    content: '\f146';
    transform: none;
}

.accounting-app .accounting-grid-host .dx-command-adaptive .dx-datagrid-adaptive-more:hover,
.accounting-app .accounting-grid-host .dx-command-adaptive .dx-datagrid-adaptive-more:focus {
    background: var(--accounting-theme-soft);
}

.accounting-app .accounting-grid-host .dx-datagrid-nodata {
    padding: 2.5rem 1rem;
    color: var(--secondary-text-color);
    font-size: .875rem;
}

.accounting-app .accounting-grid-host .dx-datagrid-focus-overlay {
    border-color: var(--accounting-theme-accent) !important;
}

.accounting-app .accounting-grid-host .dx-datagrid-rowsview .dx-command-expand {
    padding-left: 0;
    text-align: center !important;
}

.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-expand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: .25rem;
    color: var(--secondary-text-color);
    transform: translateY(1px);
    transition: background-color .15s ease-in-out, color .15s ease-in-out;
}

.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-group-closed,
.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-group-opened {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.25rem;
    height: 1.25rem;
    color: inherit;
    font-family: 'Font Awesome 6 Pro';
    font-size: .9rem;
    font-weight: 900;
    line-height: 1;
}

.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-group-closed::before,
.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-group-opened::before {
    position: static;
    display: inline-block;
}

.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-group-closed::before {
    content: '\f13a';
}

.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-group-opened::before {
    content: '\f139';
}

.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-expand:hover,
.accounting-app .accounting-grid-host .dx-command-expand .dx-datagrid-expand:focus {
    color: var(--accounting-theme-accent);
    background: var(--accounting-theme-soft);
}

@media (min-width: 1400px) {
    .accounting-app .accounting-journal-modal-dialog {
        max-width: min(96vw, 1800px);
    }
}

.accounting-app #journalLinesTable select.form-select-sm,
.accounting-app #journalLinesTable input.form-control-sm {
    min-width: 0;
}

.accounting-app #supplierBillRecordLineTable.hide-line-supplier .supplier-bill-line-supplier-col {
    display: none;
}

.accounting-app .accounting-centre-intro {
    border-radius: .65rem;
    box-shadow: 0 .2rem .65rem var(--primary-shadow-color);
}

.accounting-app .accounting-centre-panel {
    min-height: 32rem;
    overflow: hidden;
    border-radius: .65rem;
    box-shadow: 0 .2rem .65rem var(--primary-shadow-color);
}

.accounting-app .accounting-centre-sidebar {
    display: flex;
    flex-direction: column;
}

.accounting-app .accounting-centre-sidebar-controls {
    padding: 1rem;
    border-bottom: 1px solid var(--seconday-panel-color);
}

.accounting-app .accounting-centre-section-title {
    color: var(--primary-text-color);
    font-size: .95rem;
    font-weight: 700;
}

.accounting-app .accounting-centre-count {
    display: inline-flex;
    min-width: 1.75rem;
    height: 1.55rem;
    align-items: center;
    justify-content: center;
    padding: 0 .45rem;
    border-radius: 999px;
    background: var(--accounting-theme-soft);
    color: var(--accounting-theme-accent);
    font-size: .75rem;
    font-weight: 700;
}

.accounting-app .accounting-centre-search {
    position: relative;
}

.accounting-app .accounting-centre-search > i {
    position: absolute;
    z-index: 2;
    top: 50%;
    left: .8rem;
    color: var(--secondary-text-color);
    transform: translateY(-50%);
    pointer-events: none;
}

.accounting-app .accounting-centre-search .form-control {
    padding-left: 2.35rem;
}

.accounting-app .accounting-centre-list {
    max-height: 38rem;
    overflow-y: auto;
}

.accounting-app .accounting-centre-list .list-group-item {
    display: grid;
    grid-template-columns: 2rem minmax(0, 1fr) auto;
    align-items: center;
    gap: .7rem;
    min-height: 4.3rem;
    padding: .7rem .85rem;
    border-right: 0;
    border-left: 0;
    color: var(--primary-text-color);
    text-align: left;
}

.accounting-app .accounting-centre-list .list-group-item:first-child {
    border-top: 0;
}

.accounting-app .accounting-centre-list .list-group-item.active {
    border-color: var(--accounting-theme-accent);
    background: var(--accounting-theme-accent);
    color: #fff;
}

.accounting-app .accounting-centre-list-avatar,
.accounting-app .accounting-centre-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border-radius: .55rem;
    background: var(--accounting-theme-soft);
    color: var(--accounting-theme-accent);
}

.accounting-app .accounting-centre-list-avatar {
    width: 2rem;
    height: 2rem;
    font-size: .82rem;
}

.accounting-app .accounting-centre-list .list-group-item.active .accounting-centre-list-avatar {
    background: rgba(255, 255, 255, .18);
    color: #fff;
}

.accounting-app .accounting-centre-list-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: .15rem;
}

.accounting-app .accounting-centre-list-name,
.accounting-app .accounting-centre-list-meta {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.accounting-app .accounting-centre-list-name {
    font-size: .88rem;
    font-weight: 700;
}

.accounting-app .accounting-centre-list-meta {
    color: var(--secondary-text-color);
    font-size: .74rem;
}

.accounting-app .accounting-centre-list-value {
    align-self: start;
    padding-top: .08rem;
    font-size: .78rem;
    font-weight: 700;
    white-space: nowrap;
}

.accounting-app .accounting-centre-list .list-group-item.active .accounting-centre-list-meta {
    color: rgba(255, 255, 255, .78);
}

.accounting-app .accounting-centre-loading,
.accounting-app .accounting-centre-empty {
    display: flex;
    min-height: 10rem;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: .65rem;
    padding: 1rem;
    color: var(--secondary-text-color);
    font-size: .85rem;
    text-align: center;
}

.accounting-app .accounting-centre-empty > i {
    color: var(--accounting-theme-accent);
    font-size: 1.35rem;
}

.accounting-app .accounting-centre-detail {
    padding: 1rem;
}

.accounting-app .accounting-centre-detail-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1rem;
}

.accounting-app .accounting-centre-identity {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: .8rem;
}

.accounting-app .accounting-centre-identity .min-w-0 {
    min-width: 0;
}

.accounting-app .accounting-centre-avatar {
    width: 2.75rem;
    height: 2.75rem;
    font-size: 1.05rem;
}

.accounting-app .accounting-centre-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(7.5rem, 1fr));
    gap: .55rem;
    min-width: 17rem;
}

.accounting-app .accounting-centre-summary-wide {
    grid-template-columns: repeat(3, minmax(7.5rem, 1fr));
    min-width: 25rem;
}

.accounting-app .accounting-centre-metric {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: .15rem;
    padding: .55rem .7rem;
    border: 1px solid var(--seconday-panel-color);
    border-radius: .5rem;
    background: var(--primary-panel-color);
    text-align: right;
}

.accounting-app .accounting-centre-metric > span {
    color: var(--secondary-text-color);
    font-size: .7rem;
    font-weight: 600;
    white-space: nowrap;
}

.accounting-app .accounting-centre-metric > strong {
    overflow: hidden;
    color: var(--primary-text-color);
    font-size: .9rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.accounting-app .accounting-centre-metric-primary {
    border-color: color-mix(in srgb, var(--accounting-theme-accent) 28%, transparent);
    background: var(--accounting-theme-soft);
}

.accounting-app .accounting-centre-metric-primary > strong {
    color: var(--accounting-theme-accent);
}

.accounting-app .accounting-centre-filter {
    margin-bottom: 1rem;
    padding: .85rem;
    border: 1px solid var(--seconday-panel-color);
    border-radius: .55rem;
    background: color-mix(in srgb, var(--seconday-panel-color) 34%, transparent);
}

.accounting-app .accounting-centre-filter-actions {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: .5rem;
}

.accounting-app .accounting-centre-filter-actions .btn {
    display: inline-flex;
    min-height: 2.4rem;
    align-items: center;
    justify-content: center;
    gap: .4rem;
}

@media (max-width: 1199.98px) {
    .accounting-app .accounting-centre-detail-header {
        flex-direction: column;
    }

    .accounting-app .accounting-centre-summary,
    .accounting-app .accounting-centre-summary-wide {
        width: 100%;
        min-width: 0;
    }
}

@media (max-width: 991.98px) {
    .accounting-app .accounting-centre-panel {
        min-height: 0;
    }

    .accounting-app .accounting-centre-list {
        max-height: 20rem;
    }
}

@media (max-width: 575.98px) {
    .accounting-app .accounting-centre-summary,
    .accounting-app .accounting-centre-summary-wide {
        grid-template-columns: 1fr;
    }

    .accounting-app .accounting-centre-filter-actions {
        justify-content: stretch;
    }

    .accounting-app .accounting-centre-filter-actions .btn {
        flex: 1;
    }
}

.accounting-app .dx-datagrid .dx-dropdownbutton .dx-button {
    min-width: 7rem;
    height: 2rem;
    border-color: var(--seconday-panel-color, #d3d9e4);
    background: var(--primary-panel-color, #ffffff);
    color: var(--primary-text-color);
}

.accounting-app .accounting-grid-action-menu .dx-button,
.accounting-grid-action-menu .dx-button {
    min-width: 8rem;
    height: 2rem;
    border-color: var(--seconday-panel-color, #d3d9e4);
    background: var(--primary-panel-color, #ffffff);
    color: var(--primary-text-color);
}

.accounting-app .dx-datagrid .dx-dropdownbutton .dx-button-content,
.accounting-app .accounting-grid-action-menu .dx-button-content,
.accounting-grid-action-menu .dx-button-content {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .35rem;
    padding: 0 .55rem;
}

.accounting-app .dx-datagrid .dx-dropdownbutton .dx-button-text,
.accounting-app .accounting-grid-action-menu .dx-button-text,
.accounting-grid-action-menu .dx-button-text {
    line-height: 1;
}

@media (max-width: 575.98px) {
    .accounting-app .accounting-grid-host .accounting-grid-actions-column,
    .accounting-app .dx-datagrid-rowsview .dx-row > td:has(.accounting-grid-action-menu) {
        width: 56px !important;
        min-width: 56px !important;
        max-width: 56px !important;
    }

    .accounting-app .accounting-grid-action-menu,
    .accounting-app .accounting-grid-action-dropdown {
        width: 2.5rem;
        min-width: 2.5rem;
        max-width: 2.5rem;
    }

    .accounting-app .accounting-grid-action-menu .dx-button {
        width: 2.5rem !important;
        min-width: 2.5rem !important;
        max-width: 2.5rem !important;
    }

    .accounting-app .accounting-grid-action-menu .dx-button-content {
        gap: 0;
        padding: 0;
    }

    .accounting-app .accounting-grid-action-menu .dx-button-text,
    .accounting-app .accounting-grid-action-menu .dx-icon-spindown {
        display: none;
    }
}

.accounting-grid-action-overlay .dx-popup-content {
    padding: 0;
}

.accounting-grid-action-overlay .dx-list-item {
    border-radius: 0;
}

.accounting-grid-action-overlay .dx-list-item-content {
    padding: 0;
}

.accounting-grid-action-overlay .dx-list-item.dx-state-hover {
    background: var(--seconday-panel-color, #f8fafc);
}

/* A greyed item still shows its reason as a tooltip when pointed at. */
.accounting-grid-action-overlay .dx-list-item.dx-state-disabled {
    opacity: 1;
    pointer-events: auto;
}

.accounting-grid-action-item {
    display: flex;
    align-items: center;
    gap: .55rem;
    min-height: 2rem;
    padding: .45rem .65rem;
    color: var(--primary-text-color);
    white-space: nowrap;
    overflow: hidden;
}

.accounting-grid-action-item-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 1.15rem;
    width: 1.15rem;
    color: var(--secondary-text-color, #69707a);
    font-size: .95rem;
    line-height: 1;
}

.accounting-grid-action-item-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 400;
    line-height: 1.2;
    white-space: nowrap;
}

/* A disabled item: the normal disabled grey (never pale words on blue: dmr-ui.css keeps a
   disabled item's background white when it is focused or tapped), with why under its name. */
.accounting-grid-action-item.is-disabled,
.accounting-grid-action-item.is-disabled .accounting-grid-action-item-icon {
    color: var(--dmr-muted, #a7aeb8);
    cursor: not-allowed;
}

.accounting-grid-action-item.is-disabled {
    align-items: flex-start;
}

.accounting-grid-action-item-label {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.accounting-grid-action-item-reason {
    margin-top: .2rem;
    font-size: .75rem;
    line-height: 1.3;
    color: var(--dmr-text, #69707a);
    white-space: normal;
    overflow-wrap: anywhere;
}

.accounting-app .accounting-page-empty-state {
    min-height: 15rem;
}

.accounting-app .accounting-page-empty-state-icon {
    color: var(--primary-color);
    background: var(--seconday-panel-color);
    border-color: var(--seconday-panel-color);
}

.accounting-app .accounting-report-favorite {
    width: 2rem;
    height: 2rem;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 2;
    cursor: pointer;
    pointer-events: auto;
    border-color: var(--seconday-panel-color, #d3d9e4);
    box-shadow: 0 .1rem .3rem rgba(15, 23, 42, .08);
}

.accounting-app .accounting-report-favorite i {
    margin: 0;
    font-size: .95rem;
    line-height: 1;
    pointer-events: none;
}

.accounting-app .accounting-report-favorite.btn-primary {
    border-color: var(--primary-color);
}
.searchable-select {
    position: relative;
    display: block;
    width: 100%;
}

.searchable-select.searchable-select--auto {
    display: inline-block;
    width: auto;
}

.searchable-select-native {
    opacity: 0 !important;
    pointer-events: none !important;
}

.searchable-select-toggle {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    color: inherit; 
    text-align: left;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
}

.searchable-select-toggle:focus {
    border-color: #86b7fe;
    outline: 0;
    box-shadow: 0 0 0 .2rem rgba(13, 110, 253, .16);
}

.searchable-select-toggle:disabled {
    cursor: not-allowed;
}

.searchable-select.is-loading .searchable-select-toggle:disabled {
    cursor: wait;
    opacity: 1;
}

.searchable-select-value {
    display: flex;
    align-items: center;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
}

.searchable-select-label {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: left;
}

.searchable-select-value.is-placeholder {
    color: var(--secondary-text-color, #69707a);
}

.searchable-select-loading-indicator {
    flex: 0 0 auto;
    width: .9rem;
    height: .9rem;
    margin-right: .55rem;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    opacity: .75;
    animation: searchable-select-spin .7s linear infinite;
}

.searchable-select-loading-message {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes searchable-select-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (prefers-reduced-motion: reduce) {
    .searchable-select-loading-indicator {
        animation-duration: 1.5s;
    }
}

.searchable-select-menu {
    position: fixed;
    z-index: 2055;
    min-width: 10rem;
    padding: .25rem;
    background: #fff;
    border: 1px solid var(--seconday-panel-color, #d3d9e4);
    border-radius: .25rem;
    box-shadow: 0 .25rem .75rem rgba(15, 23, 42, .14);
}

.searchable-select-search {
    height: calc(1.35em + .45rem + 2px);
    margin-bottom: .25rem;
    font-size: 12px;
}

.searchable-select-options {
    overflow-y: auto;
    overscroll-behavior: contain;
}

.searchable-select-option {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 24px;
    padding: 4px 7px;
    overflow: hidden;
    color: var(--primary-text-color, #1f2937);
    font-size: 12px;
    line-height: 1.15;
    text-align: left;
    white-space: nowrap;
    background: transparent;
    border: 0;
    border-radius: .2rem;
}

.searchable-select-option:hover,
.searchable-select-option.is-active {
    background: #f1f5f9;
}

.searchable-select-option.is-selected {
    color: var(--primary-color, #0d6efd);
    background: #e7f1ff;
    font-weight: 500;
}

.searchable-select-option:disabled {
    color: var(--secondary-text-color, #69707a);
    cursor: not-allowed;
    opacity: .6;
}

.searchable-select-group {
    padding: 5px 7px 2px;
    color: var(--secondary-text-color, #69707a);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
}

.searchable-select-parent {
    color: var(--secondary-text-color, #69707a);
}

.searchable-select-badge {
    flex: 0 0 auto;
    display: inline-block;
    margin-left: 6px;
    padding: 1px 7px;
    font-size: 10px;
    font-weight: 600;
    line-height: 1.5;
    vertical-align: baseline;
    border-radius: 999px;
}

.searchable-select-empty {
    padding: 8px 7px;
    color: var(--secondary-text-color, #69707a);
    font-size: 12px;
    text-align: center;
}



/* Application switcher: anchor and button entries share one text colour
   (anchors otherwise pick up link blue while form buttons render dark).
   .active is excluded so the current app keeps its white-on-blue state. */
.application-switcher .dropdown-menu .dropdown-item:not(.active),
.application-switcher .dropdown-menu .dropdown-item:not(.active) i {
    color: var(--primary-text-color, #363d47) !important;
}

.application-switcher .dropdown-menu .dropdown-item:not(.active):hover,
.application-switcher .dropdown-menu .dropdown-item:not(.active):hover i {
    color: var(--primary-color, #0061f2) !important;
}

/* Multi-select field: a dropdown of checkboxes (check-dropdown.js). The button is a
   form-select, so it sits in a form like any other field. */
.dmr-check-dropdown .form-select {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dmr-check-dropdown .dropdown-menu {
    max-height: 300px;
    overflow-y: auto;
}

/* Quote layout editor: the live preview fills its card. */
.quote-layout-preview {
    border: 0;
    min-height: 900px;
    width: 100%;
}

/* Tenant profile: the current logo above its upload field. */
.dmr-logo-preview {
    align-items: center;
    background-color: var(--seconday-panel-color);
    border-radius: .35rem;
    color: var(--secondary-text-color);
    display: flex;
    flex-direction: column;
    gap: .5rem;
    justify-content: center;
    min-height: 10rem;
    padding: 1rem;
}

.dmr-logo-preview img {
    max-height: 8rem;
    max-width: 100%;
    object-fit: contain;
}

/* DevExtreme 25 indents each tree level by 18px plus 4px; the timeline task lists (the
   only tree lists) keep DevExtreme 24's 14px levels, with 4px after the expand arrow, so
   task titles are not cut short. */
.dx-gantt .dx-treelist-rowsview .dx-row > td.dx-treelist-cell-expandable .dx-treelist-empty-space {
    width: 14px;
}

.dx-gantt .dx-treelist-rowsview .dx-row > td.dx-treelist-cell-expandable .dx-treelist-empty-space--last {
    margin: 0;
}

.dx-gantt .dx-treelist-rowsview .dx-row > td.dx-treelist-cell-expandable .dx-treelist-expanded,
.dx-gantt .dx-treelist-rowsview .dx-row > td.dx-treelist-cell-expandable .dx-treelist-collapsed {
    margin-right: 4px;
}

.dx-gantt .dx-treelist-rowsview .dx-row > td.dx-treelist-cell-expandable .dx-treelist-expanded::before,
.dx-gantt .dx-treelist-rowsview .dx-row > td.dx-treelist-cell-expandable .dx-treelist-collapsed::before {
    margin-left: -3px;
}

/* === Polish, October 2026: shared fixes === */

/* A search box keeps its text clear of the magnifier: the compact editor padding above
   (.dx-texteditor-input) also removed the room DevExtreme leaves for the icon. */
.dx-searchbox .dx-texteditor-input {
    padding-left: 34px !important;
}

/* Amounts and dates never wrap in the middle. */
.dmr-nowrap {
    white-space: nowrap;
}

/* Inline validation (window.dmrValidation): the message under its field. */
.dmr-field-error {
    font-size: .8125rem;
    margin-top: .25rem;
}

/* The message is already under the field: DevExtreme's pop-up copy of it would cover the
   next field's label. */
.dmr-has-field-error .dx-invalid-message {
    display: none !important;
}

/* Empty state of a list grid (dmrGridDefaults.emptyState): what the list is, and the next
   step as a button. */
.dmr-grid-is-empty .dx-datagrid-rowsview.dx-empty {
    height: auto;
    min-height: 11.5rem;
}

.dmr-grid-is-empty .dx-datagrid-rowsview .dx-datagrid-nodata {
    max-width: 30rem;
    white-space: normal;
    width: calc(100% - 2rem);
}

.dmr-grid-empty {
    align-items: center;
    display: flex;
    flex-direction: column;
    gap: .35rem;
    text-align: center;
}

.dmr-grid-empty-title {
    color: var(--primary-text-color);
    font-size: 1rem;
    font-weight: 600;
}

.dmr-grid-empty-text {
    color: var(--secondary-text-color);
    font-size: .875rem;
}

.dmr-grid-empty .btn {
    margin-top: .5rem;
}

/* A row's detail (the columns a narrow grid folds away): long values wrap instead of
   running off the card. Amounts and dates (.dmr-nowrap) still keep together. */
.dx-adaptive-detail-row .dx-field-item-content {
    overflow-wrap: anywhere;
    white-space: normal;
}

.dx-adaptive-detail-row .dx-field-item-content.dmr-nowrap {
    white-space: nowrap;
}

/* Phone width: a grid's toolbar wraps onto as many rows as it needs, with the search box
   on a row of its own, instead of running off the left edge of the card. */
@media (max-width: 767.98px) {
    .dx-datagrid-header-panel .dx-toolbar,
    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-items-container {
        height: auto;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-items-container {
        display: flex;
        flex-wrap: wrap;
        gap: .5rem;
        justify-content: flex-start !important;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-before,
    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-center,
    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-after {
        display: flex;
        flex-wrap: wrap;
        float: none;
        gap: .5rem;
        justify-content: flex-start !important;
        margin: 0 !important;
        max-width: 100%;
        padding: 0;
        position: static;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-before:empty,
    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-center:empty,
    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-after:empty {
        display: none;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-after {
        width: 100%;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-item {
        display: block;
        max-width: 100% !important;
        padding: 0 !important;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-item.dx-toolbar-item-invisible {
        display: none;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-item:has(.dx-datagrid-search-panel) {
        flex: 1 1 100%;
        order: 99;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-datagrid-search-panel {
        margin: 0;
        width: 100% !important;
    }

    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-item .dx-selectbox,
    .dx-datagrid-header-panel .dx-toolbar .dx-toolbar-item .dx-dropdownbutton {
        max-width: 100%;
    }

    .dx-datagrid-header-panel {
        padding-bottom: .5rem;
    }
}
