body {
    min-height: 100vh;
    background: #f5f7fa;
    color: #1f2937;
}

.login-card {
    width: min(100%, 28rem);
}

.app-topbar {
    --topbar-border: #e5e7eb;
    --topbar-muted: #6b7280;
    --topbar-blue: #2563eb;
    --topbar-blue-soft: #eff6ff;
    --topbar-hover: #f3f6fb;
    --topbar-shadow: 0 .625rem 1.875rem rgba(15, 23, 42, .08);
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--topbar-border);
    box-shadow: 0 .25rem 1.5rem rgba(15, 23, 42, .04);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.app-brand {
    min-width: 0;
    color: #111827;
    line-height: 1.1;
}

.app-brand:hover,
.app-brand:focus-visible {
    color: #0f172a;
}

.app-brand-name {
    display: block;
    font-size: 1.05rem;
    font-weight: 750;
    letter-spacing: -.02em;
}

.app-brand-company {
    display: block;
    max-width: 13rem;
    margin-top: .1rem;
    color: var(--topbar-muted);
    font-size: .76rem;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-topbar .navbar-toggler {
    border-color: var(--topbar-border);
    border-radius: .75rem;
    box-shadow: none;
}

.app-topbar .navbar-toggler:focus-visible {
    box-shadow: 0 0 0 .2rem rgba(37, 99, 235, .18);
}

.app-nav {
    align-items: center;
}

.app-topbar .app-nav-trigger {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    min-height: 2.35rem;
    padding: .45rem .75rem;
    border-radius: 999px;
    color: #374151;
    font-size: .92rem;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
}

.app-topbar .app-nav-trigger:hover,
.app-topbar .app-nav-trigger:focus {
    color: #111827;
    background: var(--topbar-hover);
}

.app-topbar .app-nav-trigger.active,
.app-topbar .app-nav-trigger.show {
    color: #1d4ed8;
    background: var(--topbar-blue-soft);
}

.app-topbar .app-nav-trigger:focus {
    box-shadow: none;
}

.app-topbar .app-nav-trigger:focus-visible,
.topbar-pill:focus-visible,
.topbar-account-button:focus-visible {
    box-shadow: 0 0 0 .2rem rgba(37, 99, 235, .18);
    outline: 0;
}

.app-topbar .dropdown-menu {
    border: 1px solid rgba(226, 232, 240, .95);
    border-radius: .9rem;
    box-shadow: var(--topbar-shadow);
}

.app-nav-menu {
    min-width: 14rem;
    padding: .45rem;
}

.app-nav-menu .dropdown-item,
.topbar-user-menu .dropdown-item {
    border-radius: .65rem;
    padding: .55rem .75rem;
    color: #374151;
    font-size: .92rem;
}

.app-nav-menu .dropdown-item:hover,
.app-nav-menu .dropdown-item:focus,
.topbar-user-menu .dropdown-item:hover,
.topbar-user-menu .dropdown-item:focus {
    color: #111827;
    background: var(--topbar-hover);
}

.app-nav-menu .dropdown-item.active,
.app-nav-menu .dropdown-item:active {
    color: #1d4ed8;
    background: var(--topbar-blue-soft);
}

.topbar-account {
    min-width: 0;
}

.topbar-pill,
.topbar-account-button {
    min-height: 2.35rem;
    border: 1px solid var(--topbar-border);
    border-radius: 999px;
    background: #fff;
    color: #374151;
    box-shadow: 0 .25rem .75rem rgba(15, 23, 42, .04);
}

.topbar-pill {
    padding: .42rem .72rem;
    font-size: .86rem;
    font-weight: 700;
    letter-spacing: .01em;
}

.topbar-pill:hover,
.topbar-pill:focus,
.topbar-account-button:hover,
.topbar-account-button:focus {
    border-color: #bfdbfe;
    color: #1d4ed8;
    background: #f8fbff;
}

.topbar-pill:focus,
.topbar-account-button:focus {
    box-shadow: 0 .25rem .75rem rgba(15, 23, 42, .04);
}

.topbar-preferences {
    width: min(18rem, calc(100vw - 2rem));
}

.topbar-preferences .form-label {
    color: #4b5563;
    font-weight: 650;
}

.topbar-preferences .topbar-select {
    min-width: 100%;
    color: #111827;
    background-color: #fff;
    border-color: #d1d5db;
    border-radius: .7rem;
}

.topbar-account-button {
    display: inline-flex;
    max-width: 20rem;
    align-items: center;
    padding: .38rem .65rem .38rem .85rem;
}

.topbar-account-name {
    display: inline-block;
    max-width: 10rem;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
    white-space: nowrap;
}

.topbar-role-badge {
    color: #1d4ed8;
    background: #dbeafe;
    border: 1px solid #bfdbfe;
    font-size: .68rem;
    font-weight: 700;
}

.topbar-user-menu {
    min-width: 15rem;
    padding: .45rem;
}

.topbar-user-menu form {
    margin: 0;
}

.dt-buttons .buttons-colvis,
div.dt-container .dt-buttons .btn.buttons-colvis {
    border-color: #d1d5db;
    border-radius: .65rem;
    background: #fff;
    color: #374151;
    font-size: .86rem;
    font-weight: 650;
    box-shadow: 0 .125rem .5rem rgba(15, 23, 42, .04);
}

.dt-buttons .buttons-colvis:hover,
div.dt-container .dt-buttons .btn.buttons-colvis:hover {
    border-color: #bfdbfe;
    background: #f8fbff;
    color: #1d4ed8;
}

.dt-buttons .buttons-colvis:focus,
div.dt-container .dt-buttons .btn.buttons-colvis:focus {
    box-shadow: none;
}

.dt-buttons .buttons-colvis:focus-visible,
div.dt-container .dt-buttons .btn.buttons-colvis:focus-visible {
    box-shadow: 0 0 0 .2rem rgba(37, 99, 235, .18);
}

.receiving-table-wrapper {
    overflow-x: auto;
}

.modal-xxl {
    width: min(96vw, 1500px);
    max-width: calc(100vw - 1.5rem);
}

.modal-dialog-scrollable {
    max-height: calc(100vh - var(--bs-modal-margin) * 2);
}

.modal-dialog-scrollable .modal-content {
    max-height: inherit;
}

.modal-dialog-scrollable .modal-content > form {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-height: inherit;
    min-height: 0;
    overflow: hidden;
}

.modal-dialog-scrollable .modal-content > form > .modal-header,
.modal-dialog-scrollable .modal-content > form > .modal-footer {
    flex: 0 0 auto;
}

.modal-dialog-scrollable .modal-content > form > .modal-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.app-modal-scrollable .modal-body {
    overscroll-behavior: contain;
}

.receiving-table {
    min-width: 1180px;
}

.supplier-priority-cell {
    width: 8rem;
}

.mapping-column-letter-cell {
    min-width: 10rem;
}

.mapping-source-header-cell {
    min-width: 16rem;
}

.receiving-table th {
    vertical-align: middle;
    white-space: normal;
}

.receiving-th-label {
    display: inline-block;
    min-width: max-content;
    color: #374151;
    font-size: .76rem;
    font-weight: 700;
    line-height: 1.08;
}

.receiving-product-col,
.receiving-product-cell {
    min-width: 14rem;
    max-width: 18rem;
    white-space: normal;
}

.receiving-supplier-col,
.receiving-supplier-cell {
    min-width: 8.5rem;
    white-space: normal;
}

.receiving-number-col,
.receiving-price-col,
.receiving-input-col,
.receiving-condition-col,
.receiving-status-col,
.receiving-date-col {
    width: 6.5rem;
}

.receiving-table td:nth-child(3),
.receiving-table td:nth-child(5),
.receiving-table td:nth-child(6),
.receiving-table td:nth-child(8) {
    text-align: right;
    white-space: nowrap;
}

.receiving-condition-select-col,
.receiving-condition-select-cell {
    min-width: 10.5rem;
}

.receiving-note-col,
.receiving-note-cell {
    min-width: 12rem;
}

.receiving-action-col,
.receiving-action-cell {
    min-width: 7rem;
    white-space: nowrap;
}

.receiving-quantity-input,
.receiving-price-input {
    min-width: 6.75rem;
}

.receiving-condition-select {
    min-width: 10.5rem;
}

.receiving-note-input {
    min-width: 12rem;
}

.receiving-status-cell .badge {
    white-space: nowrap;
}

.import-preview-table th,
.import-preview-table td {
    min-width: 8rem;
    max-width: 24rem;
    white-space: normal;
    overflow-wrap: anywhere;
}

.import-preview-table th:first-child,
.import-preview-table td:first-child {
    min-width: 6rem;
    position: sticky;
    left: 0;
    z-index: 1;
    background: inherit;
}

.product-pool-filters .form-label {
    font-size: .82rem;
    font-weight: 600;
    color: #495057;
}

#product-pool-table th,
#product-pool-table td {
    white-space: nowrap;
}

#product-pool-table td:nth-child(3),
#product-pool-table td:nth-child(9) {
    min-width: 16rem;
    white-space: normal;
}

.product-actions-column,
#product-pool-table td:last-child .btn-group {
    white-space: nowrap;
}

.product-detail-grid > div > .fw-semibold {
    min-height: 1.5rem;
}

.product-details-column {
    width: 2.75rem;
}

.product-offer-toggle {
    width: 2rem;
    height: 2rem;
    line-height: 1;
}

.product-offer-details {
    background: #f8f9fa;
}

.product-offer-details table {
    min-width: 64rem;
}

.product-offer-recommended {
    color: #b77900;
}

.smart-combobox {
    position: relative;
}

.smart-combobox-input {
    padding-right: 2.25rem;
    background-image:
        linear-gradient(45deg, transparent 50%, #6b7280 50%),
        linear-gradient(135deg, #6b7280 50%, transparent 50%);
    background-position:
        calc(100% - 1rem) 50%,
        calc(100% - .72rem) 50%;
    background-repeat: no-repeat;
    background-size: .34rem .34rem, .34rem .34rem;
}

.smart-combobox.is-open .smart-combobox-input {
    border-color: #86b7fe;
    box-shadow: 0 0 0 .25rem rgba(13, 110, 253, .25);
}

.smart-combobox-menu {
    position: absolute;
    top: calc(100% + .25rem);
    right: 0;
    left: 0;
    z-index: 1055;
    display: none;
    max-height: 260px;
    padding: .35rem;
    overflow-y: auto;
    background: #fff;
    border: 1px solid #d7dee8;
    border-radius: .75rem;
    box-shadow: 0 .85rem 1.75rem rgba(15, 23, 42, .14);
}

.smart-combobox.is-open .smart-combobox-menu {
    display: block;
}

.smart-combobox-option {
    display: block;
    width: 100%;
    padding: .48rem .65rem;
    color: #1f2937;
    font-size: .92rem;
    line-height: 1.25;
    text-align: left;
    white-space: normal;
    overflow-wrap: anywhere;
    background: transparent;
    border: 0;
    border-radius: .55rem;
}

.smart-combobox-option:hover,
.smart-combobox-option:focus,
.smart-combobox-option.is-active {
    color: #1d4ed8;
    background: #eff6ff;
    outline: 0;
}

.smart-combobox-new-option {
    color: #047857;
    font-weight: 650;
}

.smart-combobox-empty {
    padding: .6rem .65rem;
    color: #6b7280;
    font-size: .9rem;
}

.unmatched-search-panel .form-label {
    font-size: .82rem;
    font-weight: 600;
    color: #495057;
}

#unmatched-table th,
#unmatched-table td {
    white-space: nowrap;
}

#unmatched-table td:nth-child(2) {
    min-width: 18rem;
    max-width: 30rem;
    white-space: normal;
}

.unmatched-actions-column {
    min-width: 22rem;
}

.unmatched-actions .btn {
    white-space: nowrap;
}

.source-rows-table-wrapper {
    overflow-x: auto;
}

.source-rows-table {
    table-layout: fixed;
}

.unmatched-source-table {
    min-width: 64rem;
}

.unmatched-source-table.source-table-with-file {
    min-width: 76rem;
}

#unmatched-product-results {
    max-height: 24rem;
    overflow-y: auto;
}

.conflict-search-panel .form-label {
    font-size: .82rem;
    font-weight: 600;
    color: #495057;
}

#conflict-table th,
#conflict-table td {
    white-space: nowrap;
}

#conflict-table td:nth-child(3) {
    min-width: 18rem;
    max-width: 30rem;
    white-space: normal;
}

.conflict-actions-column {
    min-width: 14rem;
}

.conflict-options-table,
.conflict-source-table {
    min-width: 72rem;
}

.conflict-source-table {
    min-width: 58rem;
}

.conflict-source-table th:nth-child(1),
.conflict-source-table th:nth-child(3),
.conflict-source-table th:nth-child(7),
.conflict-source-table th:nth-child(8) {
    width: 6.5rem;
}

.conflict-source-table th:nth-child(2) {
    width: 13rem;
}

.conflict-source-table th:nth-child(5),
.conflict-source-table th:nth-child(6) {
    width: 10rem;
}

.conflict-source-table th:nth-child(4) {
    width: 8rem;
}

.unmatched-source-table .source-col-batch,
.unmatched-source-table .source-col-price,
.unmatched-source-table .source-col-stock {
    width: 5.75rem;
}

.unmatched-source-table .source-col-row {
    width: 5.25rem;
}

.unmatched-source-table .source-col-file {
    width: 12rem;
}

.unmatched-source-table .source-col-product {
    width: 15rem;
}

.unmatched-source-table .source-col-code,
.unmatched-source-table .source-col-ean {
    width: 9rem;
}

.unmatched-source-table .source-col-created {
    width: 8.25rem;
}

.unmatched-source-table .source-col-action {
    width: 7.75rem;
}

.source-file-summary {
    margin-bottom: .75rem;
    padding: .625rem .75rem;
    border: 1px solid #dee2e6;
    border-radius: .65rem;
    background: #f8f9fa;
    font-size: .875rem;
    line-height: 1.25;
}

.source-file-summary-label {
    font-weight: 700;
    color: #495057;
}

.source-file-summary-name {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.source-file-summary-technical {
    display: block;
    margin-top: .2rem;
    color: #6c757d;
    font-size: .78rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.source-file-cell,
.source-wrap-cell {
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.source-file-name {
    display: block;
    line-height: 1.2;
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.source-file-technical {
    display: block;
    margin-top: .2rem;
    color: #6c757d;
    font-size: .75rem;
    line-height: 1.15;
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.source-nowrap-cell {
    white-space: nowrap;
}

.source-created-at-cell {
    min-width: 8.5rem;
    line-height: 1.15;
    white-space: normal;
    font-variant-numeric: tabular-nums;
}

.source-created-date,
.source-created-time {
    display: block;
    white-space: nowrap;
}

.source-created-time {
    margin-top: .1rem;
    color: #6c757d;
    font-size: .82rem;
}

.source-created-raw {
    overflow-wrap: anywhere;
}

.source-action-cell {
    min-width: 8rem;
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
}

.source-raw-details-button {
    white-space: nowrap;
}

.source-raw-details-wrapper {
    max-width: 100%;
    overflow-x: auto;
}

.source-raw-details-row > td {
    background: #f8f9fa;
    padding: .75rem;
}

.source-raw-details-table {
    min-width: 34rem;
}

.source-raw-details-table th:first-child {
    width: 12rem;
    white-space: nowrap;
}

.source-raw-value {
    min-width: 20rem;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

#conflict-product-results {
    max-height: 20rem;
    overflow-y: auto;
}

div.dt-container .dt-layout-row {
    margin: .75rem 0;
    padding-inline: .75rem;
}

@media (max-width: 767.98px) {
    div.dt-container .dt-layout-row {
        gap: .75rem;
    }
}

@media (max-width: 1399.98px) {
    .app-nav {
        align-items: stretch;
        padding-top: .75rem;
    }

    .app-topbar .app-nav-trigger {
        width: 100%;
        justify-content: space-between;
        border-radius: .75rem;
        text-align: left;
    }

    .app-nav-menu {
        width: 100%;
        margin: .25rem 0 .5rem;
        box-shadow: none;
    }

    .topbar-account {
        padding: .9rem 0 .5rem;
        border-top: 1px solid var(--topbar-border);
    }

    .topbar-preference-dropdown,
    .topbar-user-dropdown,
    .topbar-pill,
    .topbar-account-button {
        width: 100%;
    }

    .topbar-account-button {
        justify-content: space-between;
    }

    .topbar-account-name {
        max-width: calc(100vw - 11rem);
    }
}
.product-add-group {
    min-width: 150px;
}

.order-quantity-input {
    min-width: 76px;
    max-width: 96px;
}

#order-items-table th,
#order-items-table td {
    white-space: nowrap;
}

#order-items-table .order-product-name {
    min-width: 18rem;
    max-width: 34rem;
    white-space: normal;
    overflow-wrap: anywhere;
}

.order-details-column {
    width: 2.75rem;
}

.order-item-toggle {
    width: 2rem;
    height: 2rem;
    line-height: 1;
}

.order-item-details {
    min-width: 58rem;
    background: #f8f9fa;
}

.order-item-details .fw-semibold {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.order-summary-cards .fw-semibold {
    overflow-wrap: anywhere;
}

.legacy-review-table {
    min-width: 112rem;
}

.legacy-review-product {
    min-width: 18rem;
    max-width: 34rem;
    white-space: normal;
    overflow-wrap: anywhere;
}

.legacy-review-eans,
.legacy-review-flags {
    min-width: 14rem;
    white-space: normal;
    overflow-wrap: anywhere;
}

.legacy-review-current {
    min-width: 16rem;
    max-width: 30rem;
}

.legacy-review-decision-table {
    min-width: 68rem;
}

.legacy-review-form textarea {
    min-height: 5rem;
}
