:root {
    color-scheme: light;
    --bg: #eef4f7;
    --panel: #ffffff;
    --line: #c8d7e6;
    --text: #111827;
    --muted: #526173;
    --primary: #de7a36;
    --primary-dark: #b86528;
    --secondary: #102224;
    --secondary-soft: #e8f3f4;
    --success: #1d7c57;
    --warning: #b24a1b;
}

.users-dashboard-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
    padding: 12px 14px;
}

.users-dashboard-head h1,
.users-dashboard-head p {
    margin: 0;
}

.users-dashboard-head h1 {
    font-size: 22px;
    line-height: 1.1;
}

.users-dashboard-head p {
    color: var(--muted);
    font-size: 12px;
}

.users-dashboard-kpis {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 8px;
}

.users-dashboard-kpis article {
    display: grid;
    gap: 3px;
    min-height: 68px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.users-dashboard-kpis span,
.users-dashboard-kpis small {
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
}

.users-dashboard-kpis strong {
    color: var(--text);
    font-size: 24px;
    line-height: 1;
}

.users-dashboard-panel {
    margin-bottom: 8px;
    padding: 12px;
}

.users-grid-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    align-items: stretch;
}

.users-grid-columns .users-dashboard-panel {
    display: flex;
    flex-direction: column;
    min-height: 450px;
    margin-bottom: 0;
}

.users-grid-columns .users-primary-panel,
.users-grid-columns .users-pdv-panel {
    height: 500px;
    min-height: 500px;
    max-height: 500px;
    overflow: hidden;
}

.users-grid-columns .users-primary-panel {
    order: 1;
}

.users-grid-columns .users-pdv-panel {
    order: 2;
}

.users-grid-columns .users-grid-wrap {
    flex: 1;
    min-height: 0;
}

.users-grid-columns .users-action-bar {
    margin-top: 8px;
}

.users-grid-columns .contador-access-panel {
    order: 3;
    grid-column: 1 / -1;
    min-height: 0;
}

.contador-access-empty {
    padding: 14px;
    border: 1px dashed var(--line);
    border-radius: 8px;
    background: #f8fbfd;
    color: var(--muted);
    font-size: 12px;
}

.contador-access-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 8px;
}

.contador-access-card {
    display: grid;
    gap: 8px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.contador-access-card-head,
.contador-access-meta,
.contador-access-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.contador-access-card-head {
    justify-content: space-between;
}

.contador-access-card-head div {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.contador-access-card-head strong,
.contador-access-card-head span,
.contador-access-note,
.contador-access-response {
    overflow-wrap: anywhere;
}

.contador-access-card-head span,
.contador-access-meta,
.contador-access-note,
.contador-access-response {
    color: var(--muted);
    font-size: 12px;
}

.contador-access-meta {
    flex-wrap: wrap;
}

.contador-access-note,
.contador-access-response {
    margin: 0;
    padding: 8px;
    border-radius: 7px;
    background: #f8fbfd;
}

.contador-access-actions {
    flex-wrap: wrap;
}

.contador-access-actions form,
.contador-access-deny-form {
    display: flex;
    align-items: center;
    gap: 6px;
}

.contador-access-deny-form {
    flex: 1 1 320px;
}

.contador-access-deny-form input[type="text"] {
    flex: 1;
    min-width: 180px;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 6px 8px;
    font: inherit;
}

.users-page .users-dashboard-panel-head {
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 7px;
}

.users-page .users-dashboard-panel-head > div {
    min-width: 0;
}

.users-page .users-dashboard-panel .panel-head h2 {
    margin: 0 0 3px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
}

.users-dashboard-filter {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) 110px 72px auto;
    gap: 6px;
    align-items: center;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 6px;
    border: 1px solid #d5e5ef;
    border-radius: 8px;
    background: #f8fbfd;
}

.users-dashboard-filter input,
.users-dashboard-filter select,
.users-inline-form select {
    width: 100%;
    min-width: 0;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    color: var(--text);
    padding: 6px 8px;
    font: inherit;
}

.users-dashboard-filter label {
    min-width: 0;
    font-size: 10px;
}

.users-dashboard-filter .button {
    min-width: 0;
    max-width: 100%;
    white-space: nowrap;
}

.users-grid-wrap {
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.users-grid {
    width: 100%;
    min-width: 940px;
    border-collapse: collapse;
    font-size: 12px;
}

.users-grid-compact {
    min-width: 0;
    table-layout: fixed;
}

.users-grid.users-grid-compact th,
.users-grid.users-grid-compact td {
    height: 24px;
    padding: 3px 6px;
    font-size: 11px;
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.users-grid-compact th:nth-child(1),
.users-grid-compact td:nth-child(1) {
    width: 34%;
}

.users-grid-compact th:nth-child(2),
.users-grid-compact td:nth-child(2) {
    width: 22%;
}

.users-grid-compact th:nth-child(3),
.users-grid-compact td:nth-child(3) {
    width: 32%;
}

.users-grid-compact th:nth-child(4),
.users-grid-compact td:nth-child(4) {
    width: 12%;
}

.users-pdv-grid th:nth-child(1),
.users-pdv-grid td:nth-child(1) {
    width: 52px;
}

.users-pdv-grid th:nth-child(2),
.users-pdv-grid td:nth-child(2) {
    width: 22%;
}

.users-pdv-grid th:nth-child(3),
.users-pdv-grid td:nth-child(3) {
    width: 68px;
}

.users-pdv-grid th:nth-child(4),
.users-pdv-grid td:nth-child(4) {
    width: 98px;
}

.users-pdv-grid th:nth-child(5),
.users-pdv-grid td:nth-child(5) {
    width: auto;
}

.users-pdv-grid th:nth-child(6),
.users-pdv-grid td:nth-child(6) {
    width: 58px;
}

.users-pdv-grid th,
.users-pdv-grid td {
    padding: 4px 6px;
    font-size: 11px;
    line-height: 1.15;
}

.users-pdv-grid strong {
    display: inline;
    font-size: inherit;
    font-weight: 400;
    line-height: inherit;
}

.users-pdv-grid .status-badge {
    min-height: 18px;
    padding: 1px 6px;
    font-size: 10px;
    line-height: 1.2;
}

.users-grid th,
.users-grid td {
    padding: 7px 8px;
    border-bottom: 1px solid #e2edf5;
    text-align: left;
    vertical-align: middle;
}

.users-grid th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f4f8fb;
    color: var(--muted);
    font-size: 10px;
    font-weight: 400;
    text-transform: none;
}

.users-grid td strong {
    font-weight: 400;
}

.users-grid tbody tr:hover {
    background: #eef7f8;
}

.users-grid tbody tr[data-user-row],
.users-grid tbody tr[data-pdv-operator-row],
.users-grid tbody tr[data-contador-legacy-row] {
    cursor: pointer;
}

.users-grid tbody tr[data-user-row]:focus,
.users-grid tbody tr[data-pdv-operator-row]:focus,
.users-grid tbody tr[data-contador-legacy-row]:focus {
    outline: 2px solid rgba(18, 172, 160, 0.35);
    outline-offset: -2px;
}

.contador-legacy-grid-wrap {
    max-height: 300px;
    overflow: auto;
}

.contador-legacy-grid {
    min-width: 980px;
}

.contador-legacy-action-bar {
    align-items: center;
    flex-wrap: wrap;
}

.users-grid tbody tr.is-selected {
    background: #dff5f2;
    box-shadow: inset 3px 0 0 var(--primary);
}

.users-grid tbody tr.is-selected:hover {
    background: #d4f0ec;
}

.users-grid tbody tr.is-current:not(.is-selected) {
    box-shadow: inset 3px 0 0 #86a7b7;
}

.users-pdv-filter {
    grid-template-columns: minmax(160px, 1fr) 110px 74px 68px;
    margin-bottom: 8px;
}

.users-page .button {
    font-family: Tahoma, Arial, sans-serif;
    font-weight: 400;
}

.users-remove-access-dialog {
    width: min(620px, calc(100vw - 28px));
}

.users-remove-access-explanation {
    display: grid;
    gap: 8px;
    margin-bottom: 14px;
    padding: 12px;
    border: 1px solid #e6c6ad;
    border-radius: 8px;
    background: #fff8f1;
    color: var(--text);
    font-size: 12px;
    line-height: 1.4;
}

.users-remove-access-explanation p {
    margin: 0;
}

.pdv-permissions-panel {
    max-width: 1180px;
}

.pdv-permissions-grid-wrap.products-grid-wrap {
    min-height: 160px;
    height: min(360px, calc(100vh - 260px));
    max-height: none;
}

.products-grid.pdv-permission-grid {
    min-width: 760px;
}

.products-grid col.pdv-permission-col-name {
    width: 34%;
}

.products-grid col.pdv-permission-col-description {
    width: 38%;
}

.products-grid col.pdv-permission-col-order,
.products-grid col.pdv-permission-col-status,
.products-grid col.pdv-permission-col-operators {
    width: 9.33%;
}

.pdv-permission-grid tbody tr[data-pdv-permission-row] {
    cursor: pointer;
}

.pdv-permission-grid .status-badge {
    min-height: 18px;
    padding: 1px 6px;
    font-size: 10px;
}

.pdv-permission-dialog {
    width: min(760px, calc(100vw - 28px));
}

.users-grid strong,
.users-grid small {
    display: block;
}

.users-grid small {
    margin-top: 2px;
    color: var(--muted);
    font-size: 10px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    margin: 1px 2px 1px 0;
    padding: 3px 8px;
    border-radius: 999px;
    background: #edf2f7;
    color: #354152;
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.status-badge.success {
    background: #ddf7ef;
    color: #116448;
}

.status-badge.secondary {
    background: #e8f3f4;
    color: #24525a;
}

.status-badge.warning {
    background: #fff1e8;
    color: #9b4a16;
}

.status-badge.muted {
    background: #f1f5f9;
    color: #64748b;
}

.users-inline-form {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    align-items: center;
}

.users-inline-form .inline-check {
    min-height: 28px;
    padding: 4px 7px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    font-size: 10px;
}

.users-action-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
    padding: 8px;
    border: 1px solid var(--primary);
    border-radius: 8px;
    background: #f8fbfd;
}

.users-action-bar form {
    display: contents;
}

.users-selection-note {
    margin-left: auto;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.button.is-disabled,
.users-action-bar button:disabled,
.product-action-bar button:disabled,
.purchase-xml-cost-form button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    pointer-events: none;
}

.users-access-dialog {
    width: min(620px, calc(100vw - 28px));
}

.users-create-dialog,
.users-profile-dialog {
    width: min(760px, calc(100vw - 28px));
}

.pdv-access-dialog {
    width: min(760px, calc(100vw - 28px));
}

.pdv-access-form {
    display: grid;
    gap: 10px;
}

.pdv-access-dual-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.pdv-access-list-panel {
    min-width: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fbfd;
    overflow: hidden;
}

.pdv-access-list-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-bottom: 1px solid var(--line);
    background: #eef4f8;
    color: var(--text);
}

.pdv-access-list-head span {
    min-width: 24px;
    text-align: center;
    color: var(--muted);
    font-weight: 700;
}

.pdv-access-list-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    min-width: 0;
}

.pdv-copy-access-dialog {
    width: min(620px, calc(100vw - 28px));
}

.inline-note.warning {
    color: var(--warning);
    font-weight: 700;
}

.pdv-access-list {
    display: grid;
    gap: 0;
    align-content: start;
    min-height: 270px;
    max-height: 340px;
    overflow: auto;
    padding: 4px 6px;
    background: #fff;
}

.pdv-access-list.is-drop-target {
    outline: 2px solid rgba(18, 164, 153, 0.22);
    outline-offset: -3px;
    background: #f3fffd;
}

.pdv-access-item {
    display: grid;
    gap: 2px;
    width: 100%;
    min-height: 38px;
    padding: 6px 7px;
    border: 0;
    border-bottom: 1px solid #dbe9ef;
    border-radius: 0;
    background: transparent;
    color: var(--text);
    text-align: left;
    cursor: grab;
    overflow: hidden;
}

.pdv-access-item:hover,
.pdv-access-item:focus {
    border-bottom-color: #9fd4cf;
    background: #f0fbfa;
    outline: none;
}

.pdv-access-item.is-dragging {
    opacity: 0.55;
}

[data-pdv-access-list="granted"] .pdv-access-item {
    border-bottom-color: #b9e5df;
    background: #f2fcfa;
}

.pdv-access-name {
    display: block;
    color: #087f73;
    font-size: 12px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-access-description {
    display: block;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 760px) {
    .pdv-access-dual-list {
        grid-template-columns: 1fr;
    }
}

.users-pdv-permissions-dialog {
    width: min(1040px, calc(100vw - 28px));
}

.users-pdv-permissions-body {
    display: grid;
    gap: 8px;
    height: auto;
    max-height: calc(100vh - 42px);
    grid-template-rows: auto minmax(0, 1fr);
}

.users-pdv-permissions-body iframe {
    width: 100%;
    height: min(500px, calc(100vh - 150px));
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.embedded-body {
    margin: 0;
    background: var(--bg);
}

.embedded-main {
    padding: 0;
}

.embedded-main .pdv-permissions-panel {
    max-width: none;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.embedded-main .pdv-permissions-panel > .panel-head {
    display: none;
}

.embedded-main .pdv-permissions-grid-wrap.products-grid-wrap {
    border-radius: 0;
}

.embedded-main .product-action-bar {
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 0;
}

@media (max-width: 900px) {
    .users-dashboard-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .users-grid-columns {
        grid-template-columns: 1fr;
    }

    .users-grid-columns .users-dashboard-panel {
        min-height: auto;
    }

    .users-grid-columns .users-primary-panel,
    .users-grid-columns .users-pdv-panel {
        height: auto;
        min-height: 420px;
        max-height: none;
        overflow: visible;
    }

    .users-dashboard-panel-head,
    .users-dashboard-filter {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .users-selection-note {
        width: 100%;
        margin-left: 0;
    }

    .company-store-form {
        grid-template-columns: 1fr;
    }

    .company-stores-selection-note {
        width: 100%;
        margin-left: 0;
    }
}

.operational-dashboard-hero {
    align-items: flex-end;
    gap: 14px;
}

.dashboard-overview-compact {
    display: grid;
    gap: 0;
    margin-bottom: 8px;
    padding: 8px 10px;
    position: sticky;
    top: 8px;
    z-index: 30;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 8px 22px rgba(15, 43, 48, 0.12);
    backdrop-filter: blur(8px);
}

.dashboard-sticky-filter-placeholder {
    display: none;
    margin-bottom: 8px;
}

.dashboard-overview-compact.is-dashboard-filter-fixed {
    position: fixed;
    top: 8px;
    z-index: 130;
    box-sizing: border-box;
    margin-bottom: 0;
}

.dashboard-overview-head {
    display: grid;
    grid-template-columns: auto minmax(620px, 1fr);
    gap: 12px;
    align-items: end;
    justify-content: start;
}

.dashboard-overview-title {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 5px 8px;
    min-width: 0;
}

.dashboard-overview-title strong {
    color: var(--text);
    font-size: 16px;
    line-height: 1;
}

.dashboard-overview-title small {
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
}

.operational-dashboard-filter {
    display: grid;
    grid-template-columns: minmax(150px, 1.1fr) repeat(2, minmax(130px, 0.9fr)) auto auto;
    gap: 8px;
    align-items: end;
    width: min(820px, 100%);
}

.operational-dashboard-filter label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
}

.operational-dashboard-filter select,
.operational-dashboard-filter input {
    min-height: 36px;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 8px 10px;
    font: inherit;
}

.dashboard-overview-compact .operational-dashboard-filter {
    width: 100%;
    max-width: 1220px;
    grid-template-columns: minmax(220px, 360px) minmax(150px, 230px) repeat(2, minmax(130px, 190px)) auto auto;
    gap: 6px;
}

.dashboard-overview-compact .operational-dashboard-filter:not(:has(.dashboard-company-scope)) {
    grid-template-columns: minmax(180px, 280px) repeat(2, minmax(150px, 240px)) auto auto;
}

.dashboard-overview-compact .operational-dashboard-filter label {
    gap: 3px;
    font-size: 9px;
}

.dashboard-overview-compact .operational-dashboard-filter select,
.dashboard-overview-compact .operational-dashboard-filter input {
    min-height: 32px;
    padding: 6px 8px;
    border-radius: 7px;
    font-size: 11px;
}

.dashboard-overview-compact .operational-dashboard-filter .button {
    min-height: 32px;
    padding: 7px 12px;
    border-radius: 8px;
    font-size: 12px;
}

.dashboard-kpi-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}

.dashboard-kpi {
    display: grid;
    gap: 4px;
    min-height: 92px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(16, 34, 36, 0.05);
}

.dashboard-kpi span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.dashboard-kpi strong {
    align-self: end;
    color: var(--text);
    font-size: 20px;
    line-height: 1.1;
}

.dashboard-kpi small {
    color: var(--muted);
    font-size: 10px;
    line-height: 1.25;
}

.dashboard-kpi-grid-compact {
    gap: 6px;
    margin-bottom: 0;
}

.dashboard-kpi-mini {
    min-height: 58px;
    gap: 2px;
    padding: 8px 9px;
    box-shadow: none;
}

.dashboard-kpi-mini span {
    font-size: 10px;
}

.dashboard-kpi-mini strong {
    align-self: unset;
    font-size: 16px;
    line-height: 1.05;
}

.dashboard-kpi-mini small {
    font-size: 9px;
    line-height: 1.15;
}

.dashboard-chart-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.dashboard-chart {
    min-height: 216px;
    min-width: 0;
}

/* Cards e graficos do dashboard operacional. */
.dashboard-chart-grid > .panel, .dashboard-ranking-list-panel { min-width: 0; border: 1px solid #e6e7eb; border-radius: 16px; background: #fafafb; box-shadow: none; }
.dashboard-chart-grid .panel-head, .dashboard-ranking-list-panel .panel-head { gap: 8px; margin-bottom: 12px; }
.dashboard-chart-grid .panel-head h2, .dashboard-ranking-list-panel .panel-head h2 { margin: 0; color: #252831; font-size: 18px; font-weight: 500; letter-spacing: -.02em; }
.dashboard-chart-grid .panel-head p, .dashboard-ranking-list-panel .panel-head p { color: var(--muted); font-size: 12px; }
.dashboard-sales-dre-grid, .dashboard-commercial-grid { gap: 12px; }
.dashboard-chart-grid .dashboard-sales-dre-grid { align-items: start; }
.dashboard-chart-grid .dashboard-chart-slice { min-width: 0; padding: 14px; border: 1px solid #e6e7eb; border-radius: 14px; background: #fff; }
.dashboard-chart-grid .dashboard-chart-slice h3 { color: #252831; font-size: 16px; font-weight: 500; }
.dashboard-dre-compact { gap: 10px; }
.dashboard-dre-result { padding: 14px; border: 1px solid #e6e7eb; border-radius: 14px; background: #fff; }
.dashboard-dre-result.positive { border-left: 4px solid #b91524; background: #fff; }
.dashboard-dre-result.negative { border-left: 4px solid #c42f2f; background: #fff; }
.dashboard-dre-result strong { font-size: clamp(24px, 3vw, 32px); font-weight: 400; letter-spacing: -.03em; }
.dashboard-dre-result.positive strong, .dashboard-dre-line strong.positive, .dashboard-dre-chips .positive strong, .dashboard-dre-return-strip strong { color: #252831; }
.dashboard-dre-return-strip { grid-template-columns: repeat(auto-fit, minmax(min(100%, 135px), 1fr)); gap: 8px; }
.dashboard-dre-return-strip span, .dashboard-dre-chips span { padding: 10px; border-color: #e6e7eb; border-radius: 12px; font-size: 11px; font-weight: 400; }
.dashboard-dre-return-strip strong, .dashboard-dre-chips strong { overflow: visible; font-size: 13px; text-overflow: clip; white-space: normal; overflow-wrap: anywhere; }
.dashboard-dre-track { background: #f0f0f2; }
.dashboard-dre-fill.positive { background: #b91524; }
.dashboard-dre-chips { gap: 8px; }
.dashboard-chart-summary-list, .dashboard-payment-method-list { display: grid; gap: 0; margin-top: 12px; }
.dashboard-chart-summary-list > div, .dashboard-payment-method-list > div { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; min-width: 0; padding: 7px 0; border-top: 1px solid #ececef; font-size: 12px; }
.dashboard-chart-summary-list span, .dashboard-payment-method-list span { min-width: 0; flex: 1; overflow-wrap: anywhere; }
.dashboard-chart-summary-list strong, .dashboard-payment-method-list strong { flex: 0 0 auto; color: #252831; font-weight: 500; }
.dashboard-chart-summary-list i { display: inline-block; min-width: 20px; color: #b91524; font-style: normal; }
.dashboard-payment-method-list i { width: 8px; height: 8px; flex: 0 0 8px; align-self: center; border-radius: 50%; }
.dashboard-payment-total { display: grid; gap: 3px; padding: 10px 0; }
.dashboard-payment-total span { color: var(--muted); font-size: 11px; }
.dashboard-payment-total strong { color: #252831; font-size: 24px; font-weight: 400; letter-spacing: -.02em; }
.dashboard-chart-grid .dashboard-products-chart .dashboard-chart-canvas-wrap { height: 280px; }
.dashboard-ranking-table-wrap { border-color: #e6e7eb; border-radius: 12px; background: #fff; }
.dashboard-ranking-table th { background: #f7f7f8; }
.dashboard-ranking-table th, .dashboard-ranking-table td { border-bottom-color: #ececef; }
@media (max-width: 620px) {
    .dashboard-chart-grid .dashboard-chart-slice { padding: 12px; }
    .dashboard-dre-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-chart-summary-list > div, .dashboard-payment-method-list > div { flex-wrap: wrap; }
    .dashboard-chart-summary-list strong, .dashboard-payment-method-list strong { margin-left: auto; }
    .dashboard-ranking-table-wrap-large { max-height: none; overflow: visible; border: 0; background: transparent; }
    .dashboard-ranking-table, .dashboard-ranking-table tbody, .dashboard-ranking-table tr, .dashboard-ranking-table td { display: block; width: 100%; box-sizing: border-box; }
    .dashboard-ranking-table thead { display: none; }
    .dashboard-ranking-table tbody { display: grid; gap: 9px; }
    .dashboard-ranking-table tr { padding: 10px 12px; border: 1px solid #e6e7eb; border-radius: 12px; background: #fff; }
    .dashboard-ranking-table td { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 5px 0; border: 0; text-align: right; white-space: normal !important; overflow-wrap: anywhere; }
    .dashboard-ranking-table td + td { border-top: 1px solid #f0f0f2; }
    .dashboard-ranking-table td::before { content: attr(data-label); flex: 0 0 auto; color: var(--muted); font-size: 11px; text-align: left; }
    .dashboard-ranking-table td[data-label="Produto"] { display: grid; gap: 3px; text-align: left; }
    .dashboard-ranking-table td[data-label="Produto"]::before { display: block; }
}
/* Visual do dashboard operacional alinhado aos cards dos PDVs. */
.dashboard-pdv-terminals {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
    gap: 12px;
    min-width: 0;
}

.dashboard-pdv-overview {
    margin-bottom: 16px;
    padding: 16px;
    border: 1px solid #e6e7eb;
    border-radius: 16px;
    background: #fff;
}

.dashboard-pdv-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.dashboard-pdv-hero > div:first-child { min-width: 0; }
.dashboard-pdv-hero span,
.dashboard-pdv-hero small { display: block; color: var(--muted); font-size: 12px; }
.dashboard-pdv-hero strong { display: block; margin: 4px 0; font-size: clamp(25px, 4vw, 36px); font-weight: 400; letter-spacing: -1px; overflow-wrap: anywhere; }
.dashboard-pdv-donut { width: 76px; height: 76px; flex: 0 0 76px; border-radius: 50%; position: relative; }
.dashboard-pdv-donut::after { content: ''; position: absolute; inset: 12px; background: #fff; border-radius: 50%; }
.dashboard-pdv-donut-small { width: 46px; height: 46px; flex-basis: 46px; }
.dashboard-pdv-donut-small::after { inset: 8px; }
.dashboard-pdv-payment-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 15px; }
.dashboard-pdv-payment-legend > div { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; }
.dashboard-pdv-payment-legend i { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; }
.dashboard-pdv-payment-legend span { color: var(--muted); }
.dashboard-pdv-payment-legend strong { font-weight: 600; }
.dashboard-pdv-section-title { margin: 15px 0 8px; font-size: 16px; font-weight: 500; }
.dashboard-pdv-operator-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 10px; }
.dashboard-pdv-summary-card { min-width: 0; padding: 12px; border: 1px solid #e6e7eb; border-radius: 14px; background: #fff; }
.dashboard-pdv-summary-head,
.dashboard-pdv-summary-method { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.dashboard-pdv-summary-head span { min-width: 0; font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.dashboard-pdv-summary-head strong { flex: 0 0 auto; color: #b91524; font-size: 17px; }
.dashboard-pdv-summary-head { align-items: center; }
.dashboard-pdv-summary-total { display: block; margin: 5px 0 2px; color: #b91524; font-size: 19px; font-weight: 500; }
.dashboard-pdv-summary-card > small { color: var(--muted); font-size: 11px; }
.dashboard-pdv-summary-method { margin-top: 7px; font-size: 12px; }
.dashboard-pdv-summary-method span { min-width: 0; color: var(--muted); overflow-wrap: anywhere; }
.dashboard-pdv-summary-method strong { flex: 0 0 auto; font-weight: 500; }

.dashboard-pdv-terminal {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}

.dashboard-pdv-terminal-head,
.dashboard-pdv-operator-head,
.dashboard-pdv-method-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    min-width: 0;
}

.dashboard-pdv-terminal-head {
    padding: 12px;
    border-bottom: 1px solid var(--line);
    background: #f7f7f8;
}

.dashboard-pdv-terminal-head > div,
.dashboard-pdv-operator-head > div {
    min-width: 0;
}

.dashboard-pdv-terminal-head small,
.dashboard-pdv-operator-head span,
.dashboard-pdv-terminal-total span,
.dashboard-pdv-operator-total span {
    display: block;
    color: var(--muted);
    font-size: 11px;
}

.dashboard-pdv-terminal-head h3 {
    margin: 3px 0 0;
    font-size: 18px;
    overflow-wrap: anywhere;
}

.dashboard-pdv-terminal-total,
.dashboard-pdv-operator-total {
    flex: 0 0 auto;
    text-align: right;
}

.dashboard-pdv-terminal-total strong {
    display: block;
    color: #b91524;
    font-size: 20px;
    white-space: nowrap;
}

.dashboard-pdv-terminal-total span,
.dashboard-pdv-operator-total span { max-width: 230px; line-height: 1.3; white-space: normal; }

.dashboard-pdv-operators {
    display: grid;
    gap: 8px;
    padding: 9px;
}

.dashboard-pdv-operator {
    min-width: 0;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
}

.dashboard-pdv-operator-head {
    margin-bottom: 9px;
    align-items: center;
}

.dashboard-pdv-operator-identity { flex: 1 1 auto; min-width: 0; }

.dashboard-pdv-operator-head strong {
    display: block;
    margin-top: 2px;
    font-size: 14px;
    overflow-wrap: anywhere;
}

.dashboard-pdv-operator-total strong {
    color: #b91524;
    font-size: 15px;
    white-space: nowrap;
}

.dashboard-pdv-method + .dashboard-pdv-method {
    margin-top: 7px;
}

.dashboard-pdv-method-head {
    align-items: baseline;
    font-size: 12px;
}

.dashboard-pdv-method-head span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.dashboard-pdv-method-head strong {
    flex: 0 0 auto;
    color: #b91524;
}

.dashboard-pdv-track {
    height: 5px;
    margin-top: 4px;
    overflow: hidden;
    border-radius: 999px;
    background: #e8f1f7;
}

.dashboard-pdv-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #3478b8;
}

.dashboard-pdv-note {
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 11px;
}

@media (max-width: 480px) {
    .dashboard-pdv-overview { padding: 12px; }
    .dashboard-pdv-payment-legend { display: grid; grid-template-columns: minmax(0, 1fr); }
    .dashboard-pdv-payment-legend > div { min-width: 0; }
    .dashboard-pdv-payment-legend > div span { min-width: 0; flex: 1; overflow-wrap: anywhere; }
    .dashboard-pdv-summary-head { flex-wrap: wrap; }
    .dashboard-pdv-summary-head strong { width: 100%; }
    .dashboard-pdv-terminals {
        grid-template-columns: minmax(0, 1fr);
    }

    .dashboard-pdv-terminal-head,
    .dashboard-pdv-operator-head {
        flex-wrap: wrap;
    }

    .dashboard-pdv-terminal-total,
    .dashboard-pdv-operator-total {
        width: 100%;
        text-align: left;
    }
}

.dashboard-chart-wide {
    grid-column: 1 / -1;
}

.dashboard-chart-canvas-wrap {
    position: relative;
    width: 100%;
    height: 196px;
}

.dashboard-chart-canvas-wrap canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.dashboard-chart-large {
    height: 238px;
}

.dashboard-chart-donut {
    height: 210px;
}

.dashboard-sales-dre-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(320px, 0.9fr);
    gap: 8px;
    align-items: stretch;
}

.dashboard-commercial-grid {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(260px, 1fr) minmax(240px, 0.9fr);
    gap: 8px;
}

.dashboard-chart-slice {
    min-width: 0;
}

.dashboard-chart-slice h3 {
    margin: 0 0 8px;
    color: var(--text);
    font-size: 15px;
}

.dashboard-dre-compact {
    display: grid;
    gap: 7px;
    min-height: 196px;
}

.dashboard-dre-result {
    display: grid;
    gap: 2px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-left-width: 4px;
    border-radius: 8px;
    background: #f8fbfd;
}

.dashboard-dre-result.positive {
    border-left-color: #3478b8;
    background: #f4f9fd;
}

.dashboard-dre-result.negative {
    border-left-color: #ef4444;
    background: #fff5f5;
}

.dashboard-dre-result span,
.dashboard-dre-line span {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
}

.dashboard-dre-result strong {
    font-size: 19px;
    line-height: 1.05;
}

.dashboard-dre-result.positive strong,
.dashboard-dre-line strong.positive,
.dashboard-dre-chips .positive strong {
    color: #1d5f99;
}

.dashboard-dre-result.negative strong,
.dashboard-dre-line strong.negative,
.dashboard-dre-chips .negative strong {
    color: #c42f2f;
}

.dashboard-dre-result small {
    color: var(--muted);
    font-size: 10px;
}

.dashboard-dre-return-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
    gap: 5px;
}

.dashboard-dre-return-strip span {
    display: grid;
    gap: 2px;
    min-width: 0;
    padding: 6px 7px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--muted);
    font-size: 9px;
    font-weight: 800;
}

.dashboard-dre-return-strip strong {
    overflow: hidden;
    color: #1d5f99;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-dre-return-strip .negative strong {
    color: #c42f2f;
}

.dashboard-dre-note {
    margin: 0;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.35;
}

.dashboard-dre-lines {
    display: grid;
    gap: 5px;
}

.dashboard-dre-line {
    display: grid;
    gap: 3px;
}

.dashboard-dre-line > div {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.dashboard-dre-line strong {
    font-size: 11px;
    white-space: nowrap;
}

.dashboard-dre-track {
    display: block;
    height: 6px;
    overflow: hidden;
    border-radius: 999px;
    background: #e8f1f7;
}

.dashboard-dre-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
}

.dashboard-dre-fill.positive {
    background: #3478b8;
}

.dashboard-dre-fill.negative {
    background: #ef4444;
}

.dashboard-dre-chips {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
}

.dashboard-dre-chips span {
    display: grid;
    gap: 2px;
    min-width: 0;
    padding: 6px 7px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--muted);
    font-size: 9px;
    font-weight: 800;
}

.dashboard-dre-chips strong {
    overflow: hidden;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-ranking-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: end;
    justify-content: flex-end;
}

.dashboard-ranking-filter label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
}

.dashboard-ranking-filter select {
    min-height: 34px;
    min-width: 112px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 7px 10px;
    font: inherit;
}

.dashboard-ranking-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.9fr);
    gap: 8px;
    align-items: stretch;
}

.dashboard-ranking-table-wrap {
    max-height: 196px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.dashboard-ranking-list-panel {
    margin-top: 12px;
}

.dashboard-ranking-table-wrap-large {
    max-height: min(640px, 62vh);
}

.dashboard-ranking-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.dashboard-ranking-table th,
.dashboard-ranking-table td {
    padding: 6px 7px;
    border-bottom: 1px solid #e2edf5;
    text-align: left;
    vertical-align: top;
}

.dashboard-ranking-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f4f8fb;
    color: var(--muted);
    font-size: 10px;
    text-transform: uppercase;
}

.dashboard-ranking-table th[data-dashboard-ranking-sort] {
    cursor: pointer;
    user-select: none;
}

.dashboard-ranking-table th[data-dashboard-ranking-sort]::after {
    color: #8391a3;
    content: " \2195";
    font-size: 0.8em;
}

.dashboard-ranking-table th[data-dashboard-ranking-sort][aria-sort="ascending"]::after {
    content: " \2191";
}

.dashboard-ranking-table th[data-dashboard-ranking-sort][aria-sort="descending"]::after {
    content: " \2193";
}

.dashboard-ranking-table td:nth-child(1),
.dashboard-ranking-table td:nth-child(3),
.dashboard-ranking-table td:nth-child(4),
.dashboard-ranking-table td:nth-child(5) {
    white-space: nowrap;
}

.dashboard-ranking-table strong,
.dashboard-ranking-table span {
    display: block;
}

.dashboard-ranking-table span {
    margin-top: 2px;
    color: var(--muted);
    font-size: 10px;
}
/* Consolida o visual dos indicadores depois das regras antigas do dashboard. */
.dashboard-chart-grid .dashboard-dre-compact { gap: 10px; }
.dashboard-chart-grid .dashboard-dre-result { padding: 14px; border: 1px solid #e6e7eb; border-radius: 14px; background: #fff; }
.dashboard-chart-grid .dashboard-dre-result.positive { border-left: 4px solid #16806a; background: #fff; }
.dashboard-chart-grid .dashboard-dre-result.negative { border-left: 4px solid #c42f2f; background: #fff; }
.dashboard-chart-grid .dashboard-dre-result.neutral { border-left: 4px solid #89939e; background: #fff; }
.dashboard-chart-grid .dashboard-dre-result strong { font-size: clamp(24px, 3vw, 32px); font-weight: 400; letter-spacing: -.03em; }
.dashboard-chart-grid .dashboard-dre-result.positive strong,
.dashboard-chart-grid .dashboard-dre-line strong.positive,
.dashboard-chart-grid .dashboard-dre-chips .positive strong,
.dashboard-chart-grid .dashboard-dre-return-strip .positive strong { color: #116e5d; }
.dashboard-chart-grid .dashboard-dre-result.neutral strong,
.dashboard-chart-grid .dashboard-dre-line strong.neutral,
.dashboard-chart-grid .dashboard-dre-chips .neutral strong { color: #596675; }
.dashboard-chart-grid .dashboard-dre-chips .warning strong { color: #9a6200; }
.dashboard-chart-grid .dashboard-dre-return-strip .negative strong { color: #c42f2f; }
.dashboard-chart-grid .dashboard-dre-return-strip { grid-template-columns: repeat(auto-fit, minmax(min(100%, 135px), 1fr)); gap: 8px; }
.dashboard-chart-grid .dashboard-dre-return-strip span,
.dashboard-chart-grid .dashboard-dre-chips span { padding: 10px; border-color: #e6e7eb; border-radius: 12px; font-size: 11px; font-weight: 400; }
.dashboard-chart-grid .dashboard-dre-return-strip strong,
.dashboard-chart-grid .dashboard-dre-chips strong { overflow: visible; font-size: 13px; text-overflow: clip; white-space: normal; overflow-wrap: anywhere; }
.dashboard-chart-grid .dashboard-dre-track { background: #f0f0f2; }
.dashboard-chart-grid .dashboard-dre-fill.positive { background: #16806a; }
.dashboard-chart-grid .dashboard-dre-fill.negative { background: #dc3545; }
.dashboard-chart-grid .dashboard-dre-chips { gap: 8px; }
.dashboard-ranking-list-panel .dashboard-ranking-table-wrap { border-color: #e6e7eb; border-radius: 12px; background: #fff; }
.dashboard-ranking-list-panel .dashboard-ranking-table th { background: #f7f7f8; }
.dashboard-ranking-list-panel .dashboard-ranking-table th,
.dashboard-ranking-list-panel .dashboard-ranking-table td { border-bottom-color: #ececef; }
@media (max-width: 620px) {
    .dashboard-chart-grid .dashboard-dre-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-ranking-list-panel .dashboard-ranking-table-wrap-large { max-height: none; overflow: visible; border: 0; background: transparent; }
    .dashboard-ranking-list-panel .dashboard-ranking-table,
    .dashboard-ranking-list-panel .dashboard-ranking-table tbody,
    .dashboard-ranking-list-panel .dashboard-ranking-table tr,
    .dashboard-ranking-list-panel .dashboard-ranking-table td { display: block; width: 100%; box-sizing: border-box; }
    .dashboard-ranking-list-panel .dashboard-ranking-table thead { display: none; }
    .dashboard-ranking-list-panel .dashboard-ranking-table tbody { display: grid; gap: 9px; }
    .dashboard-ranking-list-panel .dashboard-ranking-table tr { padding: 10px 12px; border: 1px solid #e6e7eb; border-radius: 12px; background: #fff; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 5px 0; border: 0; text-align: right; white-space: normal !important; overflow-wrap: anywhere; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td + td { border-top: 1px solid #f0f0f2; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td::before { content: attr(data-label); flex: 0 0 auto; color: var(--muted); font-size: 11px; text-align: left; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td[data-label="Produto"] { display: grid; gap: 3px; text-align: left; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td[data-label="Produto"]::before { display: block; }
    /* Ranking compacto: uma linha por produto, inclusive no celular. */
    .dashboard-ranking-list-panel .dashboard-ranking-table-wrap-large { overflow: hidden; border: 1px solid #e6e7eb; background: #fff; }
    .dashboard-ranking-list-panel .dashboard-ranking-table { display: table; width: 100%; table-layout: fixed; font-size: 10px; }
    .dashboard-ranking-list-panel .dashboard-ranking-table thead { display: table-header-group; }
    .dashboard-ranking-list-panel .dashboard-ranking-table tbody { display: table-row-group; }
    .dashboard-ranking-list-panel .dashboard-ranking-table tr { display: table-row; width: auto; padding: 0; border: 0; border-radius: 0; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th,
    .dashboard-ranking-list-panel .dashboard-ranking-table td { display: table-cell; width: auto; min-width: 0; padding: 7px 3px; border: 0; border-bottom: 1px solid #ececef; text-align: right; white-space: nowrap !important; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th::after { display: none; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th:nth-child(1),
    .dashboard-ranking-list-panel .dashboard-ranking-table td:nth-child(1) { width: 7%; text-align: center; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th:nth-child(2),
    .dashboard-ranking-list-panel .dashboard-ranking-table td:nth-child(2) { width: 43%; text-align: left; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th:nth-child(3),
    .dashboard-ranking-list-panel .dashboard-ranking-table td:nth-child(3) { width: 10%; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th:nth-child(4),
    .dashboard-ranking-list-panel .dashboard-ranking-table td:nth-child(4) { width: 20%; }
    .dashboard-ranking-list-panel .dashboard-ranking-table th:nth-child(5),
    .dashboard-ranking-list-panel .dashboard-ranking-table td:nth-child(5) { width: 20%; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td::before { display: none; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td[data-label="Produto"] { display: table-cell; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td[data-label="Produto"] strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .dashboard-ranking-list-panel .dashboard-ranking-table td[data-label="Produto"] span { display: none; }
}

.dashboard-bars {
    display: grid;
    gap: 8px;
}

.dashboard-column-chart {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    min-height: 300px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 26px 8px 8px;
    border: 1px solid #d6e5ee;
    border-radius: 8px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(238, 246, 248, 0.72)),
        repeating-linear-gradient(0deg, transparent, transparent 53px, rgba(34, 100, 117, 0.08) 54px);
    perspective: 900px;
}

.dashboard-column-chart-compact {
    min-height: 240px;
}

.dashboard-column {
    position: relative;
    display: grid;
    grid-template-rows: 22px minmax(0, 1fr) 16px 12px;
    justify-items: center;
    flex: 0 0 44px;
    height: 250px;
    min-width: 44px;
    color: var(--text);
}

.dashboard-column-chart-compact .dashboard-column {
    flex-basis: 52px;
    height: 190px;
    min-width: 52px;
}

.dashboard-column-value {
    align-self: end;
    min-height: 16px;
    color: #254149;
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
}

.dashboard-column-bar {
    position: relative;
    align-self: end;
    width: 28px;
    height: var(--height);
    min-height: 3px;
    border-radius: 5px 5px 2px 2px;
    background: linear-gradient(180deg, #19c3ba 0%, #0a8f8a 100%);
    box-shadow: 0 10px 16px rgba(13, 174, 163, 0.22);
    transform: skewY(-4deg);
    transform-origin: bottom center;
}

.dashboard-column-bar::before {
    content: "";
    position: absolute;
    left: 5px;
    right: -6px;
    top: -7px;
    height: 8px;
    border-radius: 5px 5px 2px 2px;
    background: #55d5cf;
    transform: skewX(-46deg);
}

.dashboard-column-bar::after {
    content: "";
    position: absolute;
    top: -3px;
    right: -8px;
    width: 8px;
    height: calc(100% + 3px);
    border-radius: 0 5px 2px 0;
    background: #087673;
    transform: skewY(-42deg);
    transform-origin: left top;
}

.dashboard-column-bar.teal {
    background: linear-gradient(180deg, #20c8be 0%, #0b817e 100%);
}

.dashboard-column-label,
.dashboard-column-count {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.dashboard-column-count {
    color: #6b7788;
    font-size: 9px;
    font-weight: 700;
}

.dashboard-bar-row {
    display: grid;
    grid-template-columns: minmax(68px, 110px) minmax(120px, 1fr) minmax(94px, auto) minmax(76px, auto);
    gap: 8px;
    align-items: center;
    min-height: 28px;
}

.dashboard-bar-row.compact {
    grid-template-columns: minmax(88px, 140px) minmax(120px, 1fr) minmax(94px, auto) minmax(68px, auto);
}

.dashboard-bar-label {
    min-width: 0;
    overflow: hidden;
    color: var(--text);
    font-size: 11px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-bar-track {
    display: block;
    width: 100%;
    height: 12px;
    overflow: hidden;
    border: 1px solid #cfe0ea;
    border-radius: 999px;
    background: #eef6f8;
}

.dashboard-bar-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #0daea3;
}

.dashboard-bar-fill.teal,
.dashboard-bar-fill.positive {
    background: #0daea3;
}

.dashboard-bar-fill.orange,
.dashboard-bar-fill.warning {
    background: var(--primary);
}

.dashboard-bar-fill.blue,
.dashboard-bar-fill.info {
    background: #3478b8;
}

.dashboard-bar-fill.expense {
    background: #6b7280;
}

.dashboard-bar-row strong {
    justify-self: end;
    color: var(--text);
    font-size: 11px;
    white-space: nowrap;
}

.dashboard-bar-row em {
    justify-self: end;
    color: var(--muted);
    font-size: 10px;
    font-style: normal;
    white-space: nowrap;
}

.dashboard-empty {
    margin: 0;
    padding: 16px;
    border: 1px dashed var(--line);
    border-radius: 8px;
    background: #f7fbfc;
    color: var(--muted);
    font-weight: 700;
}

.dre-bars .dashboard-bar-track {
    height: 14px;
}

@media (max-width: 1180px) {
    .dashboard-kpi-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .dashboard-overview-head {
        grid-template-columns: 1fr;
    }

    .operational-dashboard-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-overview-compact .operational-dashboard-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .operational-dashboard-hero {
        align-items: stretch;
    }

    .operational-dashboard-filter,
    .dashboard-kpi-grid,
    .dashboard-chart-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-overview-compact .operational-dashboard-filter,
    .dashboard-overview-compact .operational-dashboard-filter:not(:has(.dashboard-company-scope)),
    .dashboard-kpi-grid-compact {
        grid-template-columns: minmax(0, 1fr);
    }

    .dashboard-overview-compact,
    .dashboard-overview-head,
    .operational-dashboard-filter,
    .operational-dashboard-filter > *,
    .operational-dashboard-filter label {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .dashboard-overview-compact.is-dashboard-filter-fixed {
        position: static;
        width: 100% !important;
    }

    .operational-dashboard-filter select,
    .operational-dashboard-filter input,
    .operational-dashboard-filter .button {
        display: block;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .operational-dashboard-filter input[type="date"] {
        inline-size: 100%;
        min-inline-size: 0;
    }

    .dashboard-ranking-list-panel .panel-head {
        align-items: stretch;
        flex-direction: column;
    }

    .dashboard-ranking-filter,
    .dashboard-ranking-filter label,
    .dashboard-ranking-filter select {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .dashboard-sales-dre-grid,
    .dashboard-commercial-grid,
    .dashboard-ranking-layout {
        grid-template-columns: 1fr;
    }

    .dashboard-bar-row,
    .dashboard-bar-row.compact {
        grid-template-columns: minmax(72px, 0.8fr) minmax(90px, 1fr);
    }

    .dashboard-bar-row strong,
    .dashboard-bar-row em {
        justify-self: start;
    }

    .dashboard-column-chart {
        min-height: 240px;
    }

    .dashboard-column {
        flex-basis: 40px;
        height: 190px;
        min-width: 40px;
    }

}

.pdv-suggestion-body {
    min-height: 100vh;
    margin: 0;
    background: #2f343b;
}

.pdv-suggestion-shell {
    width: min(1160px, calc(100vw - 28px));
    margin: 18px auto;
}

.pdv-suggestion-modal {
    max-height: calc(100vh - 36px);
    overflow: auto;
    padding: 18px;
    border: 1px solid #d8c6ad;
    border-radius: 18px;
    background: #fffaf3;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

.pdv-suggestion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.pdv-suggestion-header span {
    color: #d9202f;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pdv-suggestion-header h1 {
    margin: 2px 0;
    color: #101b2f;
}

.pdv-suggestion-header p {
    margin: 0;
    color: #4f5561;
}

.pdv-suggestion-modal .hero {
    display: none;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Tahoma, Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    font-size: 13px;
    line-height: 1.35;
}

a {
    color: inherit;
    text-decoration: none;
}

.wrap {
    width: min(1180px, calc(100% - 28px));
    margin: 0 auto;
}

.site-body {
    background: #ffffff;
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
    font-size: 13px;
    line-height: 1.42;
}

.site-body .wrap {
    width: min(1220px, calc(100% - 56px));
}

.site-body .site-main {
    padding-top: 34px;
}

.app-body {
    background: #eef4f7;
}

.site-body .site-main {
    background: #ffffff;
}

.site-main {
    padding-top: 28px;
}

.gestor-shell {
    display: grid;
    grid-template-columns: 214px minmax(0, 1fr);
    min-height: 100vh;
    padding-top: 0;
}

.gestor-mobile-bar {
    display: none;
}

.gestor-mobile-menu-button {
    display: inline-grid;
    grid-template-columns: 18px auto;
    align-items: center;
    gap: 8px;
    min-height: 32px;
    padding: 5px 10px;
    border: 1px solid #c7dde8;
    border-radius: 8px;
    background: #eef8fb;
    color: #102224;
    font: inherit;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}

.gestor-mobile-menu-button span {
    grid-column: 1;
    display: block;
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: currentColor;
}

.gestor-mobile-menu-button strong {
    grid-column: 2;
    grid-row: 1 / 4;
}

.gestor-mobile-title {
    min-width: 0;
    overflow: hidden;
    color: #102224;
    font-size: 13px;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.gestor-mobile-backdrop {
    display: none;
}

.app-body.sidebar-collapsed .gestor-shell {
    grid-template-columns: 0 minmax(0, 1fr);
}

.gestor-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px 8px;
    background: #f8fbff;
    border-right: 1px solid #d8e4ee;
    font-family: "Segoe UI", Arial, sans-serif;
}

.nfse-modal-frame-body {
    min-height: 100vh;
    background: #f8fbff;
}

.nfse-modal-frame-main {
    padding: 0;
}

.nfse-modal-frame-main .panel {
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.app-body.sidebar-collapsed .gestor-sidebar {
    overflow: hidden;
    width: 0;
    padding: 0;
    border-right: 0;
}

.gestor-brand-card {
    width: 100%;
    max-width: 100%;
    min-height: 88px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px;
    border-radius: 8px;
    background: #ffffff;
    border: 1px solid #d8e4ee;
}

.gestor-brand-card img {
    width: min(70px, calc(50% - 3px));
    height: 76px;
    object-fit: contain;
}

.gestor-brand > img {
    width: 118px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.gestor-brand {
    display: grid;
    gap: 0;
    padding: 2px 2px 8px;
    color: #102224;
    text-decoration: none;
    width: 100%;
}

.gestor-brand span {
    color: #526173;
    font-size: 11px;
    font-weight: 600;
}

.gestor-nav {
    display: grid;
    gap: 3px;
}

.gestor-nav-label {
    margin-top: 5px;
    margin-bottom: 1px;
    color: #4b8f89;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.gestor-nav a {
    display: flex;
    align-items: center;
    min-height: 27px;
    padding: 4px 9px;
    border: 1px solid #d8e4ee;
    border-radius: 8px;
    background: #ffffff;
    color: #102224;
    text-decoration: none;
    font-weight: 600;
    font-size: 12px;
}

.gestor-nav a:hover,
.gestor-nav a.active {
    border-color: #de7a36;
    background: #fff3ea;
    color: #102224;
}

.gestor-sidebar-footer {
    display: grid;
    gap: 5px;
    margin-top: auto;
}

.full-button {
    width: 100%;
}

.gestor-main {
    min-width: 0;
    padding: 16px 18px 52px;
    background: #eef4f7;
}

.gestor-footer {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 214px;
    z-index: 18;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 30px;
    padding: 4px 18px 8px;
    background: transparent;
    color: #7a8795;
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    pointer-events: none;
}

.app-body.sidebar-collapsed .gestor-footer {
    left: 0;
}

.gestor-footer-inner {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    max-width: 100%;
    margin-left: auto;
    padding: 4px 10px;
    border: 1px solid #d8e4ee;
    border-radius: 8px;
    background: rgba(248, 251, 255, 0.92);
    box-shadow: 0 2px 10px rgba(16, 34, 36, 0.04);
    pointer-events: auto;
}

.gestor-footer-inner > span {
    display: inline-flex;
    align-items: center;
    min-height: 16px;
    padding: 0 10px;
    border-left: 1px solid #d8e4ee;
    white-space: nowrap;
}

.gestor-footer-inner > span:first-of-type {
    border-left: 0;
}

.gestor-footer-brand {
    color: #7c8794;
}

.gestor-footer-whatsapp {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
    margin: -2px 6px -2px 0;
    border: 1px solid #bfe8ce;
    border-radius: 50%;
    background: #fff;
    text-decoration: none;
    box-shadow: 0 1px 4px rgba(37, 211, 102, 0.24);
    overflow: hidden;
}

.gestor-footer-whatsapp img {
    display: block;
    width: 19px;
    height: 19px;
    object-fit: contain;
}

.gestor-footer-whatsapp:hover,
.gestor-footer-whatsapp:focus {
    border-color: #25d366;
    background: #f3fff7;
    outline: 2px solid rgba(37, 211, 102, 0.22);
    outline-offset: 2px;
}

.gestor-footer-address {
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gestor-topbar {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fbff;
}

.gestor-topbar-compact {
    min-height: 34px;
}

.gestor-topbar-brand {
    flex: 0 0 auto;
}

.gestor-topbar strong,
.gestor-topbar span,
.gestor-user strong,
.gestor-user span {
    display: block;
}

.gestor-topbar span {
    color: var(--muted);
}

.gestor-user {
    text-align: right;
}

.gestor-topbar-line {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    flex-wrap: wrap;
    color: var(--muted);
    font-size: 11px;
}

.gestor-topbar-line-full {
    width: 100%;
}

.gestor-topbar-title {
    display: inline-flex !important;
    margin-right: 0;
    color: var(--text) !important;
    font-size: 12px;
    white-space: nowrap;
}

.gestor-topbar-title .gestor-topbar-system-label {
    display: inline-flex;
    align-items: center;
    margin-left: 6px;
    padding-left: 6px;
    border-left: 1px solid #b8cbd6;
    color: #3d6275;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.gestor-topbar .fiscal-environment-badge {
    display: inline-flex;
    align-items: center;
    margin-right: auto;
    padding: 3px 8px;
    border: 1px solid #c8dce8;
    border-radius: 999px;
    color: #36536a;
    background: #edf6fa;
    font-size: 10px;
    line-height: 1.2;
    white-space: nowrap;
}

.gestor-topbar .fiscal-environment-badge.homologation {
    border-color: #efb376;
    color: #9a4508;
    background: #fff2e4;
}

.gestor-topbar .fiscal-environment-badge.production {
    border-color: #93d1aa;
    color: #176b38;
    background: #eaf8ef;
}

.gestor-topbar .fiscal-environment-badge.mixed {
    border-color: #b9aedf;
    color: #51408d;
    background: #f2effc;
}

.gestor-topbar-line strong {
    display: inline;
    color: #254149;
}

.gestor-content {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0 0 42px;
}

.nfe-return-manual-issue {
    display: flex;
    align-items: end;
    gap: 8px;
    flex-wrap: wrap;
    margin: 0 0 8px;
    padding: 7px 9px;
    border: 1px solid #e5b382;
    border-radius: 7px;
    background: #fff7ee;
}

.nfe-return-manual-issue-title {
    align-self: center;
    color: #8a3f08;
    font-weight: 700;
}

.nfe-return-manual-issue label {
    min-width: 110px;
    margin: 0;
}

.nfe-return-manual-issue input,
.nfe-return-manual-issue select {
    min-width: 110px;
}

.nfe-return-manual-issue-warning {
    align-self: center;
    color: #8a3f08;
    font-size: 11px;
}

.topbar {
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 120;
    backdrop-filter: none;
    overflow: visible;
}

.topbar-inner,
.panel-head,
.actions,
.hero {
    display: flex;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
}

.topbar-inner {
    min-height: 76px;
}

.menu-toggle {
    display: inline-flex;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--secondary);
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-direction: column;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(31, 36, 48, 0.08);
}

.menu-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: currentColor;
    transition: transform .18s ease, opacity .18s ease;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.brand-logo {
    width: 132px;
    height: auto;
    flex: 0 0 auto;
}

.brand-copy {
    display: grid;
    gap: 2px;
    line-height: 1.05;
}

.brand-copy strong {
    font-size: 16px;
}

.brand-copy small {
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.menu {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(420px, calc(100vw - 24px));
    max-width: 100vw;
    padding: 86px 14px 20px;
    background: rgba(255, 255, 255, 0.98);
    border-left: 1px solid var(--line);
    box-shadow: -18px 0 36px rgba(31, 36, 48, 0.12);
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    flex-wrap: nowrap;
    transform: translateX(100%);
    opacity: 0;
    pointer-events: none;
    transition: transform .2s ease, opacity .2s ease;
    z-index: 125;
}

@media (max-width: 640px) {
    .menu {
        width: min(320px, calc(100vw - 18px));
        padding: 78px 10px 18px;
    }
}

.menu a {
    padding: 11px 12px;
    border: 1px solid var(--line);
    background: #fffdfb;
    border-radius: 10px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
    white-space: normal;
    word-break: break-word;
    min-width: 0;
}

.menu a:hover {
    background: var(--secondary-soft);
    color: var(--text);
}

.menu-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    border: 0;
    padding: 0;
    margin: 0;
    background: rgba(31, 36, 48, 0.28);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
    z-index: 124;
}

body.menu-open {
    overflow: hidden;
}

body.menu-open .menu {
    transform: translateX(0);
    opacity: 1;
    pointer-events: auto;
}

body.menu-open .menu-backdrop {
    opacity: 1;
    pointer-events: auto;
}

body.menu-open .menu-toggle span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

body.menu-open .menu-toggle span:nth-child(2) {
    opacity: 0;
}

body.menu-open .menu-toggle span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

main {
    padding: 0 0 42px;
}

.hero,
.panel,
.stats article {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.05);
}

.pdv-body {
    background: #e7e0d7;
    min-height: 100vh;
    overflow: auto;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    padding: 16px 16px 16px 0;
}

.pdv-frame {
    --pdv-base-width: 1024;
    --pdv-base-height: 768;
    --pdv-scale: min(
        calc((100vw - 16px) / (var(--pdv-base-width) * 1px)),
        calc((100vh - 32px) / (var(--pdv-base-height) * 1px)),
        1
    );
    width: calc(var(--pdv-base-width) * 1px * var(--pdv-scale));
    height: calc(var(--pdv-base-height) * 1px * var(--pdv-scale));
    position: relative;
    flex: 0 0 auto;
}

.pdv-shell {
    width: 1024px;
    min-height: 768px;
    padding: 6px 12px 12px;
    display: grid;
    gap: 0;
    transform: scale(var(--pdv-scale));
    transform-origin: top left;
    position: absolute;
    top: 0;
    left: 0;
}

.pdv-session-strip {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    flex-wrap: nowrap;
    min-height: 14px;
    padding: 0 2px;
    color: var(--muted);
    font-size: 10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdv-session-strip strong {
    color: var(--text);
}

.pdv-session-retroactive-alert {
    border: 1px solid #dc2626;
    border-radius: 999px;
    padding: 1px 6px;
    background: #fef2f2;
    color: #b91c1c;
    font-weight: 700;
}

.pdv-qz-status {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 2px 8px;
    background: rgba(255, 255, 255, 0.72);
    color: inherit;
    font: inherit;
    cursor: pointer;
}

.pdv-qz-status-active {
    border-color: rgba(17, 135, 74, 0.28);
    background: rgba(17, 135, 74, 0.1);
    color: #11874a;
}

.pdv-qz-status-inactive {
    border-color: rgba(216, 35, 42, 0.28);
    background: rgba(216, 35, 42, 0.08);
    color: #b4232a;
}

.pdv-flash-actions {
    margin-top: 10px;
}

.pdv-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 12px 28px rgba(31, 36, 48, 0.08);
}

.pdv-topbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pdv-topbar-brand img {
    width: 110px;
    height: auto;
}

.pdv-topbar-brand strong {
    display: block;
    font-size: 18px;
    line-height: 1.1;
}

.pdv-topbar-brand span {
    color: var(--muted);
    font-size: 11px;
}

.pdv-topbar-status {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.pdv-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: #fff7ef;
    border: 1px solid var(--line);
    font-weight: 700;
    color: var(--muted);
    font-size: 12px;
}

.pdv-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 14px;
    min-height: 0;
    align-items: start;
}

.pdv-layout-single {
    grid-template-columns: 1fr;
}

.pdv-main,
.pdv-sidebar {
    min-height: 0;
}

.pdv-panel {
    background: rgba(255, 255, 255, 0.97);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 8px 14px 14px;
    box-shadow: 0 12px 28px rgba(31, 36, 48, 0.06);
}

.pdv-sale-stage {
    height: 100%;
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto auto auto;
    gap: 6px;
}

.pdv-stage-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.pdv-stage-head-brand {
    padding-bottom: 0;
    align-items: flex-start;
}

.pdv-stage-brand-block {
    display: grid;
    min-width: 0;
    flex: 1 1 auto;
}

.pdv-stage-brand {
    display: flex;
    align-items: center;
    gap: 9px;
}

.pdv-stage-brand img {
    width: 64px;
    height: auto;
}

.pdv-stage-brand strong {
    display: block;
    font-size: 20px;
    line-height: 1.05;
}

.pdv-stage-brand span {
    font-size: 12px;
}

.pdv-sale-context {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 3px;
    font-size: 11px;
    color: #594f44;
}

.pdv-sale-context > span {
    max-width: 260px;
    padding: 3px 7px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff8f1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-sale-context strong {
    display: inline;
    font-size: inherit;
    color: #2f2b27;
}

.pdv-stage-head h1,
.pdv-panel h2 {
    margin: 0;
}

.pdv-stage-actions,
.pdv-function-grid {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pdv-stage-actions .button,
.pdv-stage-actions a.button {
    font-size: 12px;
    padding: 7px 10px;
    white-space: nowrap;
}

.pdv-entry-grid {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(260px, 1.6fr) 96px 96px 118px;
    gap: 10px;
    align-items: end;
}

.pdv-entry-grid > label:nth-child(1) {
    grid-column: 1;
}

.pdv-entry-grid > label:nth-child(2) {
    grid-column: 2;
}

.pdv-entry-grid > label:nth-child(3) {
    grid-column: 3;
}

.pdv-entry-grid > label:nth-child(4) {
    grid-column: 4;
}

.pdv-entry-grid label {
    display: grid;
    gap: 6px;
    position: relative;
}

.pdv-help-field {
    position: relative;
}

.pdv-inline-search-button {
    position: absolute;
    top: -8px;
    right: 28px;
    min-height: 22px;
    padding: 2px 8px;
    font-size: 11px;
    line-height: 1.1;
    z-index: 2;
}

.pdv-help-trigger {
    position: absolute;
    top: -1px;
    right: 0;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: #fff8f1;
    color: var(--secondary);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    padding: 0;
}

.pdv-help-bubble {
    position: absolute;
    top: 22px;
    right: 0;
    z-index: 3;
    width: 240px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: #fff8f1;
    color: var(--text);
    font-size: 11px;
    line-height: 1.3;
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.12);
}

[data-pdv-quantity-field][hidden] {
    display: none !important;
}

.inline-help-field {
    position: relative;
}

.inline-help-trigger {
    position: absolute;
    top: -1px;
    right: 0;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: #fff8f1;
    color: var(--secondary);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    padding: 0;
}

.inline-help-bubble {
    position: absolute;
    top: 22px;
    right: 0;
    z-index: 3;
    width: 260px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: #fff8f1;
    color: var(--text);
    font-size: 11px;
    line-height: 1.3;
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.12);
}

.pdv-entry-grid > button {
    grid-column: 5;
    align-self: end;
    min-height: 36px;
    padding-block: 7px;
    white-space: nowrap;
}

.pdv-grid-wrap {
    min-height: 0;
    height: 330px;
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fffdfa;
}

.pdv-quick-shortcuts {
    display: flex;
    align-items: center;
    gap: 3px;
    flex-wrap: nowrap;
    min-height: 28px;
    margin: -2px 0 -4px;
    overflow: visible;
}

.pdv-quick-shortcuts .button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 28px;
    padding: 5px 6px;
    font-size: 10px;
    white-space: nowrap;
}

.pdv-payment-shortcut-button img {
    width: 14px;
    height: 14px;
    object-fit: contain;
    flex: 0 0 auto;
}

.pdv-payment-shortcut-button:disabled,
.pdv-payment-shortcut-button.is-disabled-by-config {
    cursor: not-allowed;
    opacity: 0.45;
    filter: grayscale(0.2);
}

.pdv-payment-shortcut-button:disabled img,
.pdv-payment-shortcut-button.is-disabled-by-config img {
    opacity: 0.65;
}

.pdv-grid {
    margin: 0;
    width: 100%;
    table-layout: fixed;
}

.pdv-grid th,
.pdv-grid td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdv-grid th:nth-child(1),
.pdv-grid td:nth-child(1) {
    width: 54px;
}

.pdv-grid th:nth-child(2),
.pdv-grid td:nth-child(2) {
    width: 170px;
}

.pdv-grid th:nth-child(3),
.pdv-grid td:nth-child(3) {
    width: auto;
}

.pdv-grid th:nth-child(4),
.pdv-grid td:nth-child(4) {
    width: 70px;
}

.pdv-grid th:nth-child(5),
.pdv-grid td:nth-child(5) {
    width: 80px;
}

.pdv-grid th:nth-child(6),
.pdv-grid td:nth-child(6),
.pdv-grid th:nth-child(7),
.pdv-grid td:nth-child(7) {
    width: 110px;
}

.pdv-grid-row {
    cursor: pointer;
    transition: background-color .15s ease;
}

.pdv-grid-row td {
    font-size: 15px;
    font-weight: 700;
    position: relative;
}

.pdv-grid-row:hover {
    background: #f8f1e8;
}

.pdv-grid-row.is-selected {
    background: #dbe8fb;
}

.pdv-grid-row.is-removed {
    background: #f4efe8 !important;
}

.pdv-grid-row.is-removed td {
    color: #8f8478;
    opacity: 0.68;
}

.pdv-grid-row.is-removed td::after {
    content: '';
    position: absolute;
    left: 4px;
    right: 4px;
    top: 50%;
    border-top: 2px solid #de7a36;
    transform: rotate(-1deg);
}

.pdv-grid-empty td {
    white-space: normal;
    color: var(--muted);
}

.pdv-last-item-card {
    margin-top: 0;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff8f1;
    display: grid;
    gap: 4px;
    text-align: right;
}

.pdv-last-item-card.is-sale-closed {
    background: #eef8ef;
    border-color: #b7d6bb;
}

.pdv-last-item-label {
    color: #3a342d;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.pdv-last-item-description {
    font-size: 28px;
    line-height: 1.05;
    font-weight: 800;
    color: #2f2b27;
}

.pdv-last-item-formula {
    font-size: 24px;
    font-weight: 800;
    color: #2f2b27;
}

.pdv-last-item-meta {
    display: flex;
    justify-content: flex-end;
    gap: 10px 18px;
    flex-wrap: wrap;
    color: #314034;
    font-size: 14px;
    font-weight: 700;
}

.pdv-last-item-hint {
    color: #4c5d4f;
    font-size: 12px;
    font-weight: 700;
}

.settings-pdv-scale-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.9fr);
    gap: 16px;
    align-items: start;
}

.settings-pdv-scale-config {
    display: grid;
    gap: 10px;
}

.settings-pdv-scale-inline-card {
    margin-top: 2px;
    padding: 10px;
    background: #fff7ee;
}

.settings-pdv-scale-fields {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.settings-pdv-scale-fields label {
    display: grid;
    align-content: start;
}

.settings-pdv-scale-fields label > span {
    display: flex;
    align-items: flex-start;
    min-height: 2.4em;
}

.pdv-scale-example-card {
    min-width: 0;
}

.pdv-scale-example {
    display: grid;
    gap: 8px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff8f1;
}

.pdv-scale-example.is-disabled {
    opacity: 0.58;
}

.pdv-scale-example-barcode {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 72px;
}

.pdv-scale-example-barcode img {
    display: block;
    width: min(100%, 320px);
    height: auto;
    object-fit: contain;
}

.pdv-scale-example-code {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
    font-size: 15px;
    font-weight: 700;
}

.pdv-scale-example-code span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 68px;
    padding: 6px 8px;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: #fff;
}

.pdv-scale-example-prefix {
    min-width: 30px !important;
}

.pdv-scale-example-product {
    color: var(--warning);
}

.pdv-scale-example-value {
    color: #0d6b9f;
}

.pdv-scale-example-legend {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 11px;
}

.pdv-totals {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.pdv-totals article,
.pdv-sidebar-kpis div {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff8f1;
    padding: 12px;
    display: grid;
    gap: 4px;
}

.pdv-totals span,
.pdv-sidebar-kpis span,
.pdv-summary-list span {
    color: var(--muted);
    font-size: 12px;
}

.pdv-totals strong,
.pdv-sidebar-kpis strong,
.pdv-summary-list strong {
    font-size: 24px;
    line-height: 1.1;
}

.pdv-total-discount-note {
    color: #047857;
    font-size: 11px;
    font-weight: 700;
}

.pdv-total-discount-note[hidden] {
    display: none;
}

.pdv-sidebar {
    display: grid;
    gap: 14px;
}

.pdv-sidebar-kpis,
.pdv-summary-list {
    display: grid;
    gap: 10px;
}

.pdv-summary-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.pdv-summary-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px dashed var(--line);
    padding-bottom: 8px;
}

.pdv-summary-list li:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.pdv-login-dialog {
    border: 0;
    padding: 0;
    background: transparent;
    width: min(560px, calc(100vw - 24px));
    max-width: 100vw;
}

.pdv-login-dialog::backdrop {
    background: rgba(31, 36, 48, 0.48);
}

.pdv-login-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 18px;
    display: grid;
    gap: 16px;
    box-shadow: 0 20px 44px rgba(31, 36, 48, 0.18);
}

.pdv-login-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.pdv-login-head h2 {
    margin: 0 0 4px;
}

.pdv-login-head p,
.pdv-company-picker p {
    margin: 0;
    color: var(--muted);
}

.pdv-login-form {
    display: grid;
    gap: 12px;
}

.pdv-login-footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 242px;
    gap: 12px;
    align-items: end;
}

.pdv-login-primary-actions {
    display: grid;
    gap: 8px;
    align-content: end;
}

.pdv-login-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pdv-login-message {
    padding: 8px 10px;
    border: 1px solid #cfe0ea;
    border-radius: 8px;
    background: #f4fafb;
    color: #263b4b;
    font-size: 12px;
    line-height: 1.35;
}

.pdv-login-message-danger {
    border-color: #f4b5a6;
    background: #fff1ef;
    color: #9b2c12;
}

.pdv-login-message-success {
    border-color: #b9dec9;
    background: #effcf3;
    color: #17633a;
}

.pdv-login-recovery-link {
    width: fit-content;
    border: 0;
    padding: 0;
    background: transparent;
    color: #665b50;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.pdv-login-recovery-link:hover {
    color: var(--accent);
    text-decoration: underline;
}

.pdv-login-signup-callout {
    width: 100%;
    display: grid;
    gap: 5px;
    padding: 8px 10px;
    border: 1px solid #e6d7c5;
    border-radius: 8px;
    background: #fffaf4;
}

.pdv-login-signup-callout strong {
    color: #1f2937;
    font-size: 12px;
    line-height: 1.15;
}

.pdv-login-signup-callout span {
    color: #665b50;
    font-size: 11px;
    line-height: 1.2;
}

.pdv-login-signup-callout div {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pdv-company-picker ul {
    margin: 12px 0;
    padding-left: 18px;
}

.pdv-company-picker-list {
    display: grid;
    gap: 10px;
    margin-top: 12px;
}

.pdv-company-picker-list form {
    margin: 0;
}

.pdv-company-picker-button {
    width: 100%;
    justify-content: space-between;
    text-align: left;
    min-height: 46px;
}

.pdv-company-picker-button strong,
.pdv-company-picker-button span {
    display: block;
}

.pdv-company-picker-button span {
    color: var(--muted);
    font-size: 12px;
}

.pdv-alert-dialog {
    border: 0;
    padding: 0;
    background: transparent;
    width: min(520px, calc(100vw - 24px));
    max-width: 100vw;
}

.pdv-alert-dialog::backdrop {
    background: rgba(31, 36, 48, 0.56);
}

.pdv-alert-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 20px;
    display: grid;
    gap: 16px;
    box-shadow: 0 20px 44px rgba(31, 36, 48, 0.2);
}

.pdv-alert-card-danger {
    background: #fff5f5;
    border-color: #dc2626;
}

.pdv-password-reset-card {
    width: min(520px, calc(100vw - 24px));
}

.pdv-inline-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
}

.pdv-inline-field .button {
    min-width: 48px;
    white-space: nowrap;
}

.pdv-customer-form-dialog {
    width: min(860px, calc(100vw - 28px));
}

.pdv-customer-form-dialog .pdv-alert-card {
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.pdv-document-choice-card {
    max-width: 520px;
}

.pdv-close-contrast-dialog {
    width: min(1060px, calc(100vw - 24px));
}

.pdv-close-contrast-card {
    gap: 14px;
}

.pdv-close-contrast-content {
    display: grid;
    gap: 12px;
}

.pdv-close-contrast-meta,
.pdv-close-contrast-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(128px, 1fr));
    gap: 6px;
}

.pdv-close-contrast-meta {
    font-size: 12px;
    color: #3f3a34;
}

.pdv-cash-movement-meta {
    grid-template-columns: repeat(5, max-content);
    gap: 4px 12px;
    align-items: start;
    font-size: 11px;
}

.pdv-cash-movement-meta span {
    white-space: nowrap;
}

.pdv-close-contrast-cards article {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 7px 9px;
    background: #fbf8f2;
    display: grid;
    gap: 1px;
    min-height: 0;
}

.pdv-close-contrast-cards span,
.pdv-close-contrast-cards small {
    color: #64584d;
    font-size: 10.5px;
    line-height: 1.15;
}

.pdv-close-contrast-cards strong {
    color: #111827;
    font-size: 17px;
    line-height: 1.1;
}

.pdv-close-contrast-cards article.is-expected {
    border-color: #b8c7d9;
    background: #f3f7fb;
}

.pdv-close-contrast-cards article.is-declared {
    border-color: #d7c5a6;
    background: #fffaf0;
}

.pdv-close-contrast-cards article.is-surplus {
    border-color: #9bc7a6;
    background: #eef9f1;
}

.pdv-close-contrast-cards article.is-surplus strong,
.pdv-close-contrast-cards article.is-balanced strong {
    color: #157347;
}

.pdv-close-contrast-cards article.is-shortage {
    border-color: #e2aaa5;
    background: #fff1f0;
}

.pdv-close-contrast-cards article.is-shortage strong {
    color: #b42318;
}

.pdv-close-contrast-cards article.is-balanced {
    border-color: #9bc7a6;
    background: #eef9f1;
}

.pdv-close-contrast-table {
    margin: 0;
    font-size: 11px;
}

.pdv-close-contrast-table th,
.pdv-close-contrast-table td {
    padding: 5px 6px;
    white-space: nowrap;
}

.pdv-close-contrast-table th:not(:first-child),
.pdv-close-contrast-table td:not(:first-child) {
    text-align: right;
}

.pdv-close-contrast-difference.is-negative {
    color: #b42318;
    font-weight: 800;
}

.pdv-close-contrast-difference.is-positive {
    color: #157347;
    font-weight: 800;
}

.pdv-pix-dialog {
    width: min(460px, calc(100vw - 24px));
}

.pdv-pix-card {
    text-align: center;
}

.pdv-pix-amount {
    font-size: 30px;
    font-weight: 900;
    color: #111827;
}

.pdv-pix-qr-box {
    width: 240px;
    min-height: 240px;
    margin: 0 auto;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    display: grid;
    place-items: center;
    padding: 10px;
}

.pdv-pix-qr-box img {
    display: block;
    width: 220px;
    max-width: 100%;
    height: auto;
}

.pdv-pix-status {
    font-weight: 800;
    color: #1f3556;
}

.pdv-document-choice-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 4px 0;
}

.pdv-document-choice-button {
    min-height: 72px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 16px;
}

.pdv-document-choice-button strong {
    font-size: 22px;
    color: #1f2937;
}

.pdv-alert-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.pdv-alert-head h2 {
    margin: 0;
}

.pdv-alert-message {
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
}

.pdv-alert-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.pdv-price-dialog-grid {
    display: grid;
    gap: 12px;
}

.pdv-price-dialog-grid label {
    display: grid;
    gap: 6px;
}

.pdv-customer-form-grid {
    display: grid;
    grid-template-columns: 1.65fr 0.9fr 0.9fr 0.75fr;
    gap: 10px;
    align-items: end;
}

.pdv-customer-form-grid label {
    display: grid;
    gap: 5px;
    min-width: 0;
    white-space: nowrap;
}

.pdv-customer-form-grid input,
.pdv-customer-form-grid select {
    width: 100%;
    min-width: 0;
}

.pdv-customer-form-grid label:nth-child(2),
.pdv-customer-form-grid label:nth-child(8) {
    grid-column: span 2;
}

.pdv-customer-form-grid label:nth-child(4) {
    grid-column: span 1;
}

.pdv-customer-form-checkbox {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px !important;
    min-height: 48px;
    padding: 0 8px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fbf8f2;
    white-space: normal !important;
}

.pdv-customer-form-checkbox input {
    width: auto;
    min-width: auto;
}

@media (max-width: 820px) {
    .pdv-customer-form-grid {
        grid-template-columns: 1fr;
    }

    .pdv-customer-form-grid label:first-child,
    .pdv-customer-form-grid label:nth-child(8) {
        grid-column: auto;
    }
}

.pdv-adjustments-inline-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: end;
}

.pdv-product-dialog {
    border: 0;
    padding: 0;
    background: transparent;
    width: min(1180px, calc(100vw - 28px));
    max-width: 100vw;
}

.pdv-product-dialog::backdrop {
    background: rgba(31, 36, 48, 0.56);
}

.pdv-product-dialog-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 18px;
    display: grid;
    gap: 14px;
    box-shadow: 0 20px 44px rgba(31, 36, 48, 0.2);
    max-height: calc(100vh - 28px);
    overflow: hidden;
}

.pdv-payment-dialog-card {
    width: min(620px, 92vw);
    max-height: calc(100vh - 28px);
    overflow: hidden;
    padding: 14px;
}

.pdv-product-search-field {
    display: grid;
    gap: 6px;
}

.pdv-product-grid-wrap {
    border: 1px solid var(--line);
    border-radius: 12px;
    overflow: auto;
    background: #fffdfa;
    height: 330px;
    min-height: 330px;
    max-height: 330px;
}

.pdv-product-grid {
    margin: 0;
    width: 100%;
    table-layout: auto;
}

.pdv-product-grid th,
.pdv-product-grid td {
    white-space: nowrap;
    padding-top: 0.24rem;
    padding-bottom: 0.24rem;
    line-height: 1.12;
}

.pdv-product-grid tbody tr {
    cursor: pointer;
}

.pdv-product-grid tbody tr.is-selected {
    background: #dbe8fb;
}

.pdv-product-grid-empty td {
    color: var(--muted);
}

.pdv-store-stock-card {
    width: min(760px, calc(100vw - 28px));
}

.pdv-store-stock-grid-wrap {
    height: 260px;
    min-height: 260px;
    max-height: 260px;
}

.pdv-store-stock-grid th:nth-child(2),
.pdv-store-stock-grid td:nth-child(2),
.pdv-store-stock-grid th:nth-child(3),
.pdv-store-stock-grid td:nth-child(3),
.pdv-store-stock-grid th:nth-child(4),
.pdv-store-stock-grid td:nth-child(4) {
    text-align: right;
}

.pdv-store-stock-grid .is-current-store td {
    background: #f2fbf7;
    font-weight: 800;
}

.pdv-store-current-tag,
.pdv-store-price-compare {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 18px;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 900;
    white-space: nowrap;
}

.pdv-store-current-tag {
    margin-left: 6px;
    border: 1px solid #b9dec9;
    color: #17633a;
    background: #effcf3;
}

.pdv-store-price-compare.is-higher {
    border: 1px solid #f1c98e;
    color: #8a4c12;
    background: #fff8eb;
}

.pdv-store-price-compare.is-lower {
    border: 1px solid #f4b5a6;
    color: #9b2c12;
    background: #fff1ef;
}

.pdv-store-price-compare.is-equal {
    border: 1px solid #cfe0ea;
    color: #34495a;
    background: #f4fafb;
}

.pdv-cash-movements-grid {
    font-size: 0.75rem;
}

.pdv-cash-movements-grid th,
.pdv-cash-movements-grid td {
    padding: 0.12rem 0.24rem;
    line-height: 1;
}

.pdv-cash-movements-grid .button.small {
    min-height: 22px;
    padding: 3px 7px;
    font-size: 10px;
}

.pdv-cash-movement-withdrawal td:nth-child(2),
.pdv-cash-movement-withdrawal td:nth-child(4) {
    color: #b91c1c;
    font-weight: 800;
}

.pdv-cash-movement-supply td:nth-child(2),
.pdv-cash-movement-supply td:nth-child(4) {
    color: #1d4ed8;
    font-weight: 800;
}

.pdv-session-sales-card {
    width: min(1120px, 96vw);
}

.pdv-trade-return-card {
    box-sizing: border-box;
    width: 100%;
    height: min(700px, calc(100vh - 28px));
    overflow: hidden;
    gap: 6px;
    padding: 10px 12px;
    grid-template-rows: auto auto auto 1fr auto auto;
}

.pdv-trade-return-dialog {
    width: min(1000px, calc(100vw - 56px));
}

.pdv-receivables-dialog {
    width: min(1040px, calc(100vw - 44px));
}

.pdv-trade-returns-toolbar {
    grid-template-columns: minmax(320px, 1fr) 170px auto;
}

.pdv-trade-returns-grid-wrap {
    height: 360px;
    min-height: 360px;
    max-height: 360px;
}

.pdv-trade-returns-grid {
    table-layout: fixed;
    font-size: 0.68rem;
    min-width: 1040px;
}

.pdv-trade-returns-grid th,
.pdv-trade-returns-grid td {
    padding: 0.16rem 0.22rem;
    line-height: 1.05;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdv-trade-returns-grid th:nth-child(1),
.pdv-trade-returns-grid td:nth-child(1) {
    width: 118px;
}

.pdv-trade-returns-grid th:nth-child(2),
.pdv-trade-returns-grid td:nth-child(2),
.pdv-trade-returns-grid th:nth-child(3),
.pdv-trade-returns-grid td:nth-child(3) {
    width: 72px;
}

.pdv-trade-returns-grid th:nth-child(4),
.pdv-trade-returns-grid td:nth-child(4) {
    width: 210px;
}

.pdv-trade-returns-grid th:nth-child(5),
.pdv-trade-returns-grid td:nth-child(5) {
    width: 86px;
}

.pdv-trade-returns-grid th:nth-child(6),
.pdv-trade-returns-grid td:nth-child(6) {
    width: 280px;
}

.pdv-trade-returns-grid th:nth-child(7),
.pdv-trade-returns-grid td:nth-child(7) {
    width: 82px;
    text-align: right;
}

.pdv-trade-returns-grid th:nth-child(8),
.pdv-trade-returns-grid td:nth-child(8) {
    width: 86px;
}

.pdv-document-view-dialog {
    width: min(980px, calc(100vw - 42px));
}

.pdv-document-view-card {
    height: min(720px, calc(100vh - 34px));
    padding: 12px;
    gap: 10px;
    grid-template-rows: auto 1fr auto;
}

.pdv-document-view-frame-wrap {
    min-height: 0;
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    background: #eef4f7;
}

.pdv-document-view-frame-wrap iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #fff;
}

.pdv-receivables-card {
    width: min(1040px, 94vw);
    max-height: calc(100vh - 56px);
    gap: 10px;
    padding: 14px;
    overflow: hidden;
}

.pdv-position-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.pdv-position-grid section {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 10px;
    background: #fffaf4;
}

.pdv-position-grid h3 {
    margin: 0 0 8px;
    font-size: 14px;
}

.pdv-functions-quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-bottom: 0.9rem;
}

.pdv-session-sales-toolbar {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(150px, 190px) auto;
    gap: 0.9rem;
    align-items: end;
}

.pdv-product-search-field-compact {
    min-width: 0;
}

.pdv-session-sales-summary {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    flex-wrap: wrap;
    color: #3a342d;
    font-weight: 700;
}

.pdv-trade-return-filters {
    display: grid;
    grid-template-columns: minmax(170px, 1fr) 104px 104px 82px 82px minmax(130px, 0.8fr) minmax(98px, 0.65fr) 64px;
    gap: 0.38rem;
    align-items: end;
    min-width: 0;
}

.pdv-trade-return-filters label {
    gap: 0.18rem;
    font-size: 0.78rem;
}

.pdv-trade-return-filters input {
    min-height: 32px;
    padding: 0.3rem 0.36rem;
    font-size: 0.76rem;
    min-width: 0;
}

.pdv-trade-return-filters input[type="date"] {
    min-width: 0;
    padding-inline: 0.28rem;
    font-weight: 400;
    letter-spacing: 0;
}

.pdv-trade-return-sales-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    font-size: 0.82rem;
}

.pdv-trade-return-sales-wrap {
    height: 145px;
    min-height: 145px;
    max-height: 145px;
}

.pdv-trade-return-sales-grid {
    font-size: 0.72rem;
    table-layout: fixed;
    width: 100%;
}

.pdv-trade-return-sales-grid th:nth-child(1),
.pdv-trade-return-sales-grid td:nth-child(1) {
    width: 76px;
}

.pdv-trade-return-sales-grid th:nth-child(2),
.pdv-trade-return-sales-grid td:nth-child(2) {
    width: 116px;
}

.pdv-trade-return-sales-grid th:nth-child(3),
.pdv-trade-return-sales-grid td:nth-child(3) {
    width: auto;
}

.pdv-trade-return-sales-grid th:nth-child(4),
.pdv-trade-return-sales-grid td:nth-child(4) {
    width: 180px;
}

.pdv-trade-return-sales-grid th:nth-child(5),
.pdv-trade-return-sales-grid td:nth-child(5),
.pdv-trade-return-sales-grid th:nth-child(6),
.pdv-trade-return-sales-grid td:nth-child(6) {
    width: 56px;
    text-align: center;
}

.pdv-trade-return-sales-grid th:nth-child(7),
.pdv-trade-return-sales-grid td:nth-child(7) {
    width: 82px;
    text-align: right;
}

.pdv-trade-return-sales-grid th,
.pdv-trade-return-sales-grid td {
    padding: 0.16rem 0.22rem;
    line-height: 1.05;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdv-trade-return-sales-grid tr.is-disabled {
    color: #8c8175;
}

.pdv-trade-return-sales-grid tbody tr.is-return-active {
    background: #ffe1e1;
    color: #7f1018;
    font-weight: 800;
}

.pdv-trade-return-sales-grid tbody tr.is-return-active td {
    border-top: 1px solid #e1252d;
    border-bottom: 1px solid #e1252d;
}

.pdv-session-sales-grid-wrap {
    height: 380px;
    min-height: 380px;
    max-height: 380px;
}

.pdv-receivables-grid-wrap {
    height: 315px;
    min-height: 315px;
    max-height: 315px;
    overflow: auto;
}

.pdv-receivables-grid-wrap .pdv-session-sales-grid {
    min-width: 1060px;
    font-size: 0.7rem;
}

.pdv-receivables-grid-wrap .pdv-session-sales-grid th,
.pdv-receivables-grid-wrap .pdv-session-sales-grid td {
    padding: 0.18rem 0.22rem;
    line-height: 1.05;
}

.pdv-customer-purchased-items-card {
    width: min(1120px, 96vw);
}

.pdv-customer-purchased-items-grid-wrap {
    height: 380px;
    min-height: 380px;
    max-height: 380px;
    overflow: auto;
}

.pdv-customer-purchased-items-grid {
    min-width: 960px;
    font-size: 0.68rem;
}

.pdv-customer-purchased-items-grid th,
.pdv-customer-purchased-items-grid td {
    padding: 0.12rem 0.16rem;
    line-height: 1;
}

.pdv-customer-purchased-items-grid th:nth-child(4),
.pdv-customer-purchased-items-grid td:nth-child(4) {
    min-width: 230px;
}

.pdv-customer-purchased-items-grid tr.pdv-purchased-sale-break td {
    border-top: 3px solid #d6c2ac;
}

.pdv-functions-sales-grid-wrap {
    height: 315px;
    min-height: 315px;
    max-height: 315px;
    overflow-y: auto;
    overflow-x: hidden;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid {
    width: 100%;
    min-width: 980px;
    table-layout: auto;
    font-size: 0.76rem;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th,
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td {
    padding: 0.24rem 0.3rem;
    line-height: 1.12;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th:nth-child(1),
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td:nth-child(1) {
    width: 72px;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th:nth-child(2),
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td:nth-child(2) {
    width: 108px;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th:nth-child(5),
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td:nth-child(5) {
    width: 150px;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th:nth-child(6),
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td:nth-child(6) {
    width: 58px;
    text-align: center;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th:nth-child(7),
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td:nth-child(7) {
    width: 90px;
    text-align: right;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid th:nth-child(8),
.pdv-functions-sales-grid-wrap .pdv-session-sales-grid td:nth-child(8) {
    width: 180px;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid tbody tr.is-cancelled-sale {
    position: relative;
    color: #606873;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid tbody tr.is-cancelled-sale::after {
    content: "";
    position: absolute;
    left: 0.25rem;
    right: 0.25rem;
    top: 50%;
    height: 1px;
    background: #d63b3b;
    pointer-events: none;
}

.pdv-functions-sales-grid-wrap .pdv-session-sales-grid tbody tr.is-cancelled-sale td {
    color: #606873;
    font-weight: 600;
}

.pdv-pre-sales-grid {
    font-size: 0.78rem;
}

.pdv-pre-sales-notice {
    margin: -0.3rem 0 0.5rem;
    padding: 0.45rem 0.65rem;
    border: 1px solid #f1c79b;
    border-radius: 8px;
    background: #fff7ef;
    color: #8a4b17;
    font-size: 0.78rem;
    font-weight: 700;
}

.pdv-pre-sales-grid th:nth-child(1),
.pdv-pre-sales-grid td:nth-child(1) {
    width: 74px;
}

.pdv-pre-sales-grid th:nth-child(2),
.pdv-pre-sales-grid td:nth-child(2) {
    width: 118px;
}

.pdv-pre-sales-grid th:nth-child(6),
.pdv-pre-sales-grid td:nth-child(6) {
    width: 52px;
    text-align: center;
}

.pdv-pre-sales-grid th:nth-child(7),
.pdv-pre-sales-grid td:nth-child(7) {
    width: 82px;
    text-align: right;
}

.pdv-pre-sales-grid th:nth-child(8),
.pdv-pre-sales-grid td:nth-child(8) {
    width: 142px;
}

.pdv-receivables-empty td {
    height: 230px;
    text-align: center;
}

.pdv-receivables-customer-card {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    margin: 0.2rem 0;
    padding: 0.55rem 0.75rem;
    border: 1px solid #ead9c7;
    border-radius: 10px;
    background: #fffaf4;
    color: #332b23;
    font-size: 0.88rem;
}

.pdv-receivables-customer-card strong {
    color: #1f3556;
}

.pdv-receivables-selection {
    border: 1px dashed #d9c7b5;
    border-radius: 10px;
    padding: 0.45rem 0.65rem;
    color: #4f4236;
    background: #fffaf5;
    font-size: 0.82rem;
    font-weight: 700;
}

.pdv-receivable-receipts-box {
    margin-top: 0.75rem;
    padding: 0.75rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fffaf4;
}

.pdv-receivable-receipts-box h3 {
    margin: 0 0 0.5rem;
    font-size: 0.9rem;
    color: #1f3556;
}

.pdv-receivable-receipts-list {
    display: grid;
    gap: 0.35rem;
    max-height: 150px;
    overflow: auto;
}

.pdv-receivable-receipt-row {
    display: grid;
    grid-template-columns: minmax(150px, 1.3fr) minmax(110px, 1fr) 90px minmax(90px, 0.8fr) auto;
    gap: 0.5rem;
    align-items: center;
    padding: 0.45rem 0.55rem;
    border: 1px solid #ead9c7;
    border-radius: 10px;
    background: #fff;
    font-size: 0.82rem;
}

.pdv-receivable-receipt-row span {
    min-width: 0;
}

.pdv-receivable-receipt-row small {
    display: block;
    color: #8b7562;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
}

.pdv-receipt-status-reversed {
    color: #a33a2b;
    text-decoration: line-through;
}

.pdv-receivable-receive-card {
    max-width: 560px;
}

.pdv-receivable-selected {
    display: grid;
    gap: 0.25rem;
    margin-bottom: 0.9rem;
    padding: 0.75rem 0.9rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fbf8f2;
}

.pdv-receivable-selected strong {
    color: #1f3556;
}

.pdv-receivable-selected span {
    color: #5e5448;
    font-size: 0.88rem;
}

.pdv-receivable-selected .pdv-receivable-totalizer {
    margin-top: 0.35rem;
    padding-top: 0.45rem;
    border-top: 1px solid var(--line);
    color: #1f3556;
    font-weight: 800;
}

.pdv-text-wrap {
    white-space: normal;
    word-break: break-word;
}

.pdv-session-sales-grid th,
.pdv-session-sales-grid td {
    white-space: nowrap;
    padding-top: 0.24rem;
    padding-bottom: 0.24rem;
    line-height: 1.12;
}

.pdv-session-sales-grid tbody tr {
    cursor: pointer;
}

.pdv-session-sales-grid tbody tr.is-selected {
    background: #dbe8fb;
}

.pdv-session-sales-detail {
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fbf8f2;
    padding: 0.65rem 0.75rem;
    display: grid;
    gap: 0.5rem;
}

.pdv-trade-return-card .pdv-session-sales-detail {
    min-height: 235px;
    max-height: 235px;
    overflow: auto;
}

.pdv-session-sales-detail-head,
.pdv-session-sales-detail-meta {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.pdv-session-sales-detail-head strong,
.pdv-session-sales-detail-meta strong {
    color: #1f3556;
}

.pdv-session-sales-detail-head > div,
.pdv-session-sales-detail-meta span {
    display: grid;
    gap: 0.12rem;
}

.pdv-trade-return-detail-head {
    align-items: center;
    display: grid;
    grid-template-columns: 1fr minmax(190px, 1.4fr) 0.75fr 0.78fr;
    min-width: 0;
}

.pdv-trade-return-detail-head > div {
    min-width: 0;
}

.pdv-trade-return-detail-head > div:last-child {
    text-align: right;
}

.pdv-trade-return-items-wrap {
    height: 176px;
    min-height: 176px;
    max-height: 176px;
    overflow: auto;
    border-top: 1px solid var(--line);
}

.pdv-session-sales-detail-sections {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.9fr);
    gap: 1rem;
}

.pdv-session-sales-detail-sections section {
    display: grid;
    gap: 0.6rem;
}

.pdv-session-sales-detail-sections h3 {
    margin: 0;
    font-size: 0.98rem;
    color: #3a342d;
}

.pdv-session-sales-mini-grid {
    margin: 0;
}

.pdv-session-sales-mini-grid th,
.pdv-session-sales-mini-grid td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0.18rem 0.24rem;
    line-height: 1.05;
}

.pdv-trade-return-items-grid {
    font-size: 0.7rem;
    table-layout: fixed;
    width: 100%;
}

.pdv-trade-return-items-grid th,
.pdv-trade-return-items-grid td {
    padding: 0.07rem 0.16rem;
    line-height: 1;
}

.pdv-trade-return-items-grid th:nth-child(1),
.pdv-trade-return-items-grid td:nth-child(1) {
    width: 9%;
}

.pdv-trade-return-items-grid th:nth-child(2),
.pdv-trade-return-items-grid td:nth-child(2) {
    width: 29%;
}

.pdv-trade-return-items-grid th:nth-child(3),
.pdv-trade-return-items-grid td:nth-child(3),
.pdv-trade-return-items-grid th:nth-child(4),
.pdv-trade-return-items-grid td:nth-child(4),
.pdv-trade-return-items-grid th:nth-child(5),
.pdv-trade-return-items-grid td:nth-child(5) {
    width: 10%;
}

.pdv-trade-return-items-grid th:nth-child(6),
.pdv-trade-return-items-grid td:nth-child(6) {
    width: 12%;
}

.pdv-trade-return-items-grid th:nth-child(7),
.pdv-trade-return-items-grid td:nth-child(7) {
    width: 20%;
}

.pdv-trade-return-items-grid input {
    min-height: 24px;
    padding: 0.14rem 0.3rem;
    font-size: 0.72rem;
}

.pdv-trade-return-card label textarea {
    min-height: 50px;
}

.pdv-trade-return-card .pdv-alert-actions {
    margin-top: 0;
    flex-wrap: nowrap;
    overflow: hidden;
}

.pdv-trade-return-card .pdv-alert-actions .button {
    white-space: nowrap;
    padding-inline: 0.75rem;
}

.pdv-session-sales-payments-grid {
    table-layout: fixed;
    width: 100%;
}

.pdv-session-sales-payments-grid th:nth-child(1),
.pdv-session-sales-payments-grid td:nth-child(1) {
    width: 28%;
}

.pdv-session-sales-payments-grid th:nth-child(2),
.pdv-session-sales-payments-grid td:nth-child(2) {
    overflow-wrap: anywhere;
    text-overflow: clip;
    white-space: normal;
    width: 52%;
}

.pdv-session-sales-payments-grid th:nth-child(3),
.pdv-session-sales-payments-grid td:nth-child(3) {
    text-align: right;
    width: 20%;
}

.pdv-session-sale-detail-card {
    width: min(980px, 94vw);
}

.pdv-dav-layout-card {
    max-width: 28rem;
}

.pdv-dav-layout-options {
    display: grid;
    gap: 0.75rem;
    margin-top: 1rem;
}

.pdv-dav-layout-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff9f2;
    font-weight: 700;
    color: #1f3556;
    cursor: pointer;
}

.pdv-dav-layout-option input {
    margin: 0;
}

.pdv-payment-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0.65rem;
    margin-bottom: 0.55rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff9f2;
}

.pdv-payment-summary strong {
    font-size: 1.12rem;
    color: #1d3557;
}

.pdv-payment-summary-strong {
    align-items: stretch;
    gap: 0.5rem;
}

.pdv-payment-summary-strong > div {
    display: grid;
    gap: 0.35rem;
}

.pdv-payment-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.8rem;
    margin-bottom: 0.55rem;
    padding: 0.45rem 0.6rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fffdf9;
    color: #3a342d;
    font-size: 0.8rem;
}

.pdv-payment-meta span {
    white-space: nowrap;
}

.pdv-payment-balance {
    margin-left: auto;
    padding: 0.4rem 0.6rem;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #d9cbbd;
    min-width: 140px;
    text-align: right;
}

.pdv-payment-balance span {
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #54483d;
}

.pdv-payment-balance strong {
    font-size: 1.28rem;
    line-height: 1;
    color: #c16b00;
}

.pdv-payment-balance.is-change strong {
    color: #1f6f43;
}

.pdv-payment-methods {
    display: grid;
    gap: 0.38rem;
}

.pdv-payment-layout {
    display: grid;
    grid-template-columns: minmax(190px, 0.82fr) minmax(0, 1fr);
    gap: 0.55rem;
    align-items: start;
}

.pdv-payment-methods-wrap,
.pdv-payment-entries-wrap {
    display: grid;
    gap: 0.38rem;
    min-width: 0;
    min-height: 0;
}

.pdv-payment-methods-title {
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #5b5148;
}

.pdv-payment-method-button {
    display: grid;
    grid-template-columns: 28px 1fr;
    align-items: center;
    gap: 0.45rem;
    width: 100%;
    min-height: 38px;
    padding: 0.36rem 0.5rem;
    border: 1px solid #d5c7ba;
    border-radius: 9px;
    background: #fffdfa;
    color: #1d3557;
    text-align: left;
    font-size: 0.86rem;
    font-weight: 800;
}

.pdv-payment-method-button:hover:not(:disabled),
.pdv-payment-method-button.is-selected:not(:disabled) {
    border-color: #1f6fd1;
    background: #0d73d614;
    outline: 0;
}

.pdv-payment-method-button:focus-visible {
    outline: 2px solid #1f6fd1;
    outline-offset: 1px;
}

.pdv-payment-method-button:disabled {
    opacity: 0.45;
}

.pdv-payment-method-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 23px;
    height: 23px;
    border-radius: 7px;
    background: #1d3557;
    color: #fff;
    font-size: 0.78rem;
}

.pdv-payment-method-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-payment-rows {
    display: grid;
    gap: 0.38rem;
    min-height: 132px;
    max-height: 190px;
    padding-right: 0.15rem;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.pdv-payment-empty {
    padding: 0.55rem 0.65rem;
    border: 1px dashed #d7c7b8;
    border-radius: 12px;
    background: #fffdfa;
}

.pdv-payment-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 0.55rem;
    align-items: center;
    padding: 0.7rem 0.8rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fffdfa;
}

.pdv-payment-stack-card {
    display: grid;
    gap: 0;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fffdfa;
    overflow: hidden;
}

.pdv-payment-stack-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 0.38rem;
    align-items: center;
    padding: 0.45rem 0.55rem;
    border-bottom: 1px solid #eee1d4;
}

.pdv-payment-stack-line:last-child {
    border-bottom: 0;
}

.pdv-payment-stack-main {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
}

.pdv-payment-stack-main strong {
    font-size: 0.82rem;
    color: #1f3556;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-payment-stack-main span {
    color: #6f6358;
    font-size: 0.72rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-payment-row-main {
    display: grid;
    gap: 0.18rem;
    min-width: 0;
}

.pdv-payment-row-main strong {
    font-size: 0.95rem;
    color: #1f3556;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-payment-row-main span {
    color: #6f6358;
    font-size: 0.82rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-payment-row-amount {
    font-size: 0.9rem;
    color: #1f3556;
    white-space: nowrap;
}

.pdv-payment-actions {
    justify-content: space-between;
}

.pdv-receipt {
    max-width: 880px;
    margin: 32px auto;
}

.pdv-receipt-frame-wrap {
    height: min(68vh, 720px);
    min-height: 420px;
    margin-top: 14px;
    border: 1px solid #d7dde8;
    background: #f8fafc;
}

.pdv-receipt-frame-wrap iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

@media print {
    .pdv-receipt .button {
        display: none !important;
    }

    .no-print {
        display: none !important;
    }

    .promotion-print-line {
        grid-template-columns: 1fr 140px 110px;
    }
}

@media (max-width: 960px) {
    .pdv-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1360px) {
    .pdv-layout {
        grid-template-columns: 1fr;
    }

    .pdv-sidebar {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        align-items: start;
    }
}

@media (max-width: 720px) {
    .pdv-body {
        display: block;
        min-height: 100svh;
        padding: 0;
        overflow-x: hidden;
    }

    .pdv-frame {
        --pdv-scale: 1;
        width: 100%;
        height: auto;
        min-height: 100svh;
        position: static;
    }

    .pdv-shell {
        width: 100%;
        min-height: 100svh;
        position: static;
        transform: none;
        transform-origin: top left;
        padding: 8px;
    }

    .pdv-session-strip {
        flex-wrap: wrap;
        gap: 4px 10px;
        white-space: normal;
        overflow: visible;
    }

    .pdv-topbar,
    .pdv-stage-head,
    .pdv-topbar-status {
        align-items: flex-start;
        flex-direction: column;
    }

    .pdv-entry-grid {
        grid-template-columns: 1fr;
    }

    .pdv-entry-grid > label:nth-child(1),
    .pdv-entry-grid > label:nth-child(2),
    .pdv-entry-grid > label:nth-child(3),
    .pdv-entry-grid > label:nth-child(4),
    .pdv-entry-grid > button {
        grid-column: auto;
    }

    .pdv-stage-brand {
        gap: 8px;
    }

    .pdv-stage-brand img {
        width: 56px;
    }

    .pdv-stage-brand strong {
        font-size: 18px;
    }

    .pdv-stage-actions {
        width: 100%;
    }

    .pdv-stage-actions .button,
    .pdv-stage-actions a.button {
        flex: 1 1 calc(50% - 8px);
        min-width: 0;
        text-align: center;
    }

    .pdv-grid-wrap {
        overflow-x: auto;
    }

    .pdv-grid {
        min-width: 720px;
    }

    .pdv-sidebar {
        grid-template-columns: 1fr;
    }

    .pdv-totals {
        grid-template-columns: 1fr;
    }

    .pdv-alert-head,
    .pdv-alert-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .pdv-adjustments-inline-grid {
        grid-template-columns: 1fr;
    }

    .pdv-payment-summary-strong {
        flex-direction: column;
    }

    .pdv-payment-layout {
        grid-template-columns: 1fr;
    }

    .pdv-payment-balance {
        margin-left: 0;
        text-align: left;
        min-width: 0;
    }

    .pdv-payment-row {
        grid-template-columns: 1fr;
    }

    .pdv-payment-stack-line {
        grid-template-columns: 1fr;
    }

    .pdv-payment-dialog-card {
        width: min(94vw, 560px);
        max-height: calc(100vh - 24px);
        overflow: auto;
    }

    .pdv-product-dialog,
    .pdv-alert-dialog,
    .pdv-login-dialog,
    .pdv-company-dialog {
        width: calc(100vw - 12px);
        max-width: calc(100vw - 12px);
    }

    .pdv-product-dialog-card,
    .pdv-alert-card,
    .pdv-login-card,
    .pdv-company-card {
        max-height: calc(100svh - 12px);
        overflow: auto;
        border-radius: 10px;
        padding: 12px;
    }

    .pdv-product-grid-wrap,
    .sales-lookup-grid-wrap {
        height: 240px;
        min-height: 240px;
        max-height: 240px;
    }

    .pdv-login-signup-callout {
        width: 100%;
    }

    .pdv-login-footer {
        grid-template-columns: 1fr;
    }

    .pdv-session-sales-toolbar,
    .pdv-session-sales-detail-sections {
        grid-template-columns: 1fr;
    }

    .pdv-session-sales-summary,
    .pdv-session-sales-detail-head,
    .pdv-session-sales-detail-meta {
        justify-content: flex-start;
    }
}

/* Ajuste final da modal de venda: participante compacto com acoes ao lado do nome. */
.sales-create-panel-modal .sales-participant-field {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.sales-create-panel-modal .sales-participant-head {
    display: flex;
    min-height: 24px;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.sales-create-panel-modal .sales-participant-caption {
    flex: 0 0 auto;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.1;
}

.sales-create-panel-modal .sales-top-participant-actions {
    display: flex;
    flex: 1 1 auto;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
    width: auto;
    padding-top: 0;
    margin-left: 0;
}

.sales-create-panel-modal .sales-top-participant-actions .button {
    flex: 0 0 auto;
    min-height: 24px;
    padding: 4px 8px;
    font-size: 0.68rem;
    font-weight: 400;
    line-height: 1.1;
}

.hero {
    padding: 18px 20px;
    margin-bottom: 14px;
}

.hero-compact {
    align-items: flex-start;
}

.hero-copy {
    display: grid;
    gap: 6px;
    max-width: 720px;
}

.hero h1 {
    margin: 0;
    font-size: 20px;
}

.hero p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.eyebrow {
    color: var(--primary);
    text-transform: uppercase;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
}

.panel {
    padding: 14px 16px;
    margin-bottom: 12px;
}

.panel.narrow {
    max-width: 760px;
}

.panel-head {
    margin-bottom: 12px;
    align-items: flex-start;
}

.panel-head h1,
.panel-head h2,
.panel h2 {
    margin: 0 0 4px;
    font-size: 17px;
}

.panel-head p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.stats article {
    padding: 10px 12px;
    display: grid;
    gap: 4px;
}

.stats strong {
    font-size: 18px;
}

.stats span {
    color: var(--muted);
    font-size: 12px;
}

.module-choice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 14px;
}

.module-choice-card {
    display: grid;
    gap: 10px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fffdfb;
    color: var(--text);
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.05);
}

.module-choice-card:hover {
    border-color: #d59b6b;
    background: #fff7f0;
}

.module-choice-card-disabled,
.module-choice-card-disabled:hover {
    background: #f7f2eb;
    border-color: #e4d8ca;
    cursor: not-allowed;
}

.module-choice-card-disabled strong,
.module-choice-card-disabled span {
    color: #8d7f71;
}

.module-choice-card strong {
    font-size: 20px;
    line-height: 1.2;
}

.module-choice-card span {
    color: var(--muted);
}

.module-choice-card > span:not(.module-choice-action) {
    font-size: 11px;
    line-height: 1.25;
}

.state-tax-rate-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 12px;
}

.state-tax-rate-card {
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.7);
    display: grid;
    gap: 8px;
}

.state-tax-rate-card strong {
    font-size: 12px;
}

.state-tax-rate-card label {
    display: grid;
    gap: 4px;
    font-size: 12px;
}

.module-choice-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    width: fit-content;
    padding: 0 16px;
    border-radius: 8px;
    background: var(--primary);
    color: #fff !important;
    font-size: 13px;
    font-weight: 700;
}

.module-choice-action-disabled {
    background: #d9cec2;
    color: #66584a !important;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 8px;
    background: var(--primary);
    color: #fff;
    padding: 8px 12px;
    min-height: 34px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}

.button:hover {
    background: var(--primary-dark);
}

.button.secondary {
    background: var(--secondary);
}

.button.secondary:hover {
    background: #161b22;
}

.button.tertiary {
    background: var(--secondary-soft);
    color: var(--text);
    border: 1px solid var(--line);
}

.button.tertiary:hover {
    background: #e9e1d7;
}

.mdfe-panel .button.mdfe-event-ready {
    border-color: #8ac79f;
    background: #eaf8ef;
    color: #17633a;
    box-shadow: inset 3px 0 0 #1f8f56;
}

.mdfe-panel .button.mdfe-event-ready:hover:not(:disabled) {
    background: #dff3e8;
}

.mdfe-panel .button:disabled,
.mdfe-modal-backdrop .button:disabled {
    cursor: not-allowed;
    opacity: 0.48;
}

.button.small {
    padding: 6px 8px;
    min-height: 28px;
    font-size: 11px;
}

.button.danger {
    background: #b91c1c;
    border-color: #991b1b;
    color: #fff;
}

.pdv-cash-position-alert {
    border-color: #dc2626 !important;
    background: #fef2f2 !important;
    color: #991b1b;
}

.pdv-cash-position-alert strong {
    color: #b91c1c;
}

.pdv-grid-row.has-promotion {
    background: #f0fdf4;
}

.promotion-search-tag {
    color: #047857;
    font-size: 10px;
    font-weight: 700;
}

.pdv-grid-row [data-pdv-row-total] small {
    color: #de7a36;
    font-size: 10px;
    font-weight: 800;
}

.pdv-grid-row [data-pdv-row-total] {
    line-height: 1.15;
    overflow: visible;
    text-overflow: clip;
}

.pdv-grid-row [data-pdv-row-total] small {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.promotion-print-line {
    align-items: center;
    border-bottom: 1px solid var(--line);
    display: grid;
    gap: 8px;
    grid-template-columns: 1fr 160px 120px;
    padding: 8px 0;
}

.suggestions-layout,
.suggestion-detail-layout {
    display: grid;
    gap: 14px;
}

.suggestions-layout {
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
    align-items: start;
}

.suggestion-detail-layout {
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 380px);
    align-items: start;
    margin-bottom: 12px;
}

.suggestion-form,
.suggestion-facts,
.suggestion-participants {
    display: grid;
    gap: 12px;
}

.suggestion-filter-grid {
    margin-bottom: 14px;
}

.suggestion-card-grid {
    display: grid;
    gap: 12px;
}

.suggestion-card {
    display: grid;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 14px;
    background: linear-gradient(180deg, #fffefd 0%, #fff7f5 100%);
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.04);
}

.suggestion-card h3 {
    margin: 0;
    font-size: 18px;
}

.suggestion-card p,
.suggestion-richtext,
.suggestion-event-body {
    margin: 0;
    color: var(--muted);
    line-height: 1.55;
}

.suggestion-card-top,
.suggestion-card-meta,
.suggestion-event-head,
.suggestion-event-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    justify-content: space-between;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    border: 1px solid transparent;
}

.status-pill-default {
    background: #fff0ef;
    color: #a12a31;
    border-color: #f4c9cc;
}

.status-pill-warning {
    background: #fff6e7;
    color: #a36b16;
    border-color: #f0d59e;
}

.status-pill-secondary {
    background: #f1ece5;
    color: #57493d;
    border-color: #e0d3c7;
}

.status-pill-success {
    background: #e8f6ee;
    color: #1f724f;
    border-color: #b9dec9;
}

.status-pill-muted {
    background: #ececec;
    color: #676767;
    border-color: #d5d5d5;
}

.suggestion-sidebar {
    display: grid;
    gap: 12px;
}

.suggestion-facts div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 8px;
}

.suggestion-facts div:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.suggestion-facts strong {
    font-size: 12px;
    text-transform: uppercase;
    color: var(--muted);
    letter-spacing: .04em;
}

.suggestion-participants ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
}

.suggestion-participants li {
    display: grid;
    gap: 2px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fffdfb;
}

.suggestion-attachment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.suggestion-attachment-card {
    display: grid;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    background: #fffdfb;
}

.suggestion-attachment-card img {
    width: 100%;
    height: 170px;
    object-fit: cover;
    display: block;
}

.suggestion-attachment-card span {
    padding: 0 10px 10px;
    font-size: 12px;
    font-weight: 700;
}

.suggestion-timeline {
    display: grid;
    gap: 12px;
}

.suggestion-event {
    display: grid;
    gap: 8px;
    border-left: 4px solid var(--primary);
    border-radius: 8px;
    padding: 12px 14px;
    background: #fffdfb;
    border-top: 1px solid var(--line);
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.suggestion-event-internal {
    border-left-color: var(--secondary);
    background: #f8f5f0;
}

@media (max-width: 980px) {
    .suggestions-layout,
    .suggestion-detail-layout {
        grid-template-columns: 1fr;
    }
}

.access-dialog {
    width: min(920px, calc(100vw - 28px));
    border: 0;
    border-radius: 8px;
    padding: 0;
    background: transparent;
}

.access-dialog::backdrop {
    background: rgba(31, 36, 48, 0.48);
}

.access-dialog-body {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
}

.tax-profile-dialog {
    width: min(900px, calc(100vw - 28px));
}

.tax-profile-dialog-body {
    display: grid;
    gap: 8px;
    max-height: calc(100vh - 42px);
    overflow: auto;
    padding: 12px 14px;
}

.tax-profile-dialog .panel-head {
    align-items: start;
    gap: 8px;
    margin-bottom: 0;
}

.tax-profile-dialog .panel-head h2 {
    font-size: 18px;
    line-height: 1.15;
}

.tax-profile-dialog .panel-head p {
    font-size: 12px;
    line-height: 1.25;
    margin-top: 2px;
}

.company-switch-dialog {
    width: min(980px, calc(100vw - 28px));
}

.company-select-panel {
    max-width: 980px;
    margin-inline: auto;
}

.company-switch-body {
    gap: 8px;
}

.company-switch-form {
    display: grid;
    gap: 8px;
}

.company-switch-list {
    display: grid;
    gap: 0;
    max-height: min(520px, calc(100vh - 190px));
    overflow: auto;
    padding: 0 4px 0 0;
    border: 0;
    background: transparent;
}

.company-switch-option {
    display: grid;
    grid-template-columns: 210px 150px minmax(360px, 1fr);
    gap: 8px;
    align-items: center;
    min-height: 26px;
    padding: 2px 8px;
    border: 0;
    border-radius: 0;
    background: #f8fbfd;
    color: var(--text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.company-switch-option + .company-switch-option {
    border-top: 1px solid #edf4f8;
}

.company-switch-option.is-main {
    background: #ecfbf8;
    box-shadow: inset 4px 0 0 #12aca0;
}

.company-switch-option.is-branch {
    background: #f8fbfd;
}

.company-switch-option:hover,
.company-switch-option:focus {
    background: #f1fbfa;
    outline: 2px solid rgba(18, 172, 160, 0.18);
    outline-offset: -2px;
}

.company-switch-option.is-selected {
    background: #d5f4ef;
    box-shadow:
        inset 4px 0 0 var(--primary),
        0 0 0 2px rgba(18, 172, 160, 0.35);
}

.company-switch-cell {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 11px;
    line-height: 1.15;
}

.company-switch-document {
    color: #2e4058;
}

.company-switch-name {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #0b2239;
    font-weight: 800;
}

.company-switch-role {
    flex: 0 0 auto;
    padding: 1px 5px;
    border-radius: 999px;
    background: #dff8f4;
    color: #087d75;
    font-size: 9px;
    font-style: normal;
    font-weight: 900;
    text-transform: uppercase;
}

.company-switch-role.branch {
    background: #eef4f7;
    color: #526173;
}

.company-switch-alias {
    color: #153e75;
    font-weight: 700;
}

.company-switch-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.fiscal-company-selector {
    display: flex;
    align-items: end;
    gap: 8px;
    min-width: min(100%, 420px);
}

.fiscal-company-selector label {
    display: grid;
    gap: 4px;
    flex: 1 1 auto;
    min-width: 0;
    color: #43556d;
    font-size: 12px;
}

.fiscal-company-selector select {
    width: 100%;
    min-width: 280px;
    max-width: 560px;
}

.hero-copy .fiscal-company-selector {
    margin-top: 10px;
}

@media (max-width: 760px) {
    .fiscal-company-selector {
        align-items: stretch;
        flex-direction: column;
        width: 100%;
    }

    .fiscal-company-selector select {
        min-width: 0;
        max-width: none;
    }
}

.company-role-badge {
    display: inline-flex;
    align-items: center;
    min-height: 18px;
    margin-left: 6px;
    padding: 2px 8px;
    border-radius: 999px;
    font-style: normal;
    font-size: 10px;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
    vertical-align: middle;
}

.company-role-badge.main {
    border: 1px solid #93c5fd;
    background: #dbeafe;
    color: #1d4ed8;
}

.company-role-badge.branch {
    border: 1px solid #86efac;
    background: #dcfce7;
    color: #15803d;
}

.products-stock-history-dialog {
    width: min(1180px, calc(100vw - 28px));
}

.products-stock-history-body {
    height: min(680px, calc(100vh - 44px));
    padding: 10px;
    overflow: hidden;
    grid-template-rows: auto minmax(0, 1fr);
    align-content: stretch;
}

.products-stock-history-content {
    width: 100%;
    min-height: 0;
    flex: 1;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    display: block;
}

.products-stock-history-content .purchase-xml-summary-panel,
.products-stock-history-content .product-stock-history-panel {
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.error-dialog.products-stock-pdf-dialog {
    width: min(1180px, calc(100vw - 28px));
    max-width: none;
}

.error-dialog-body.products-stock-pdf-body {
    display: flex;
    flex-direction: column;
    height: min(860px, calc(100vh - 34px));
    padding: 12px;
}

.error-dialog-body.products-stock-pdf-body iframe {
    width: 100%;
    min-height: 0;
    flex: 1;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

@media (max-width: 720px) {
    .company-switch-option {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
        gap: 2px;
        height: auto;
        min-height: 64px;
        padding: 6px 10px;
    }

    .company-switch-cell {
        white-space: normal;
        overflow: visible;
        line-height: 1.25;
        overflow-wrap: anywhere;
    }

    .company-switch-name {
        display: block;
    }
}

.access-dialog-form {
    display: grid;
    gap: 12px;
}

.purchase-conference-dialog {
    width: min(760px, calc(100vw - 28px));
}

.purchase-conference-form {
    padding: 14px 16px;
}

.purchase-conference-form .panel-head {
    align-items: start;
    margin-bottom: 2px;
}

.purchase-conference-form .panel-head h2 {
    font-size: 16px;
}

.purchase-conference-form .panel-head p {
    font-size: 11px;
}

.purchase-conference-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px 10px;
}

.purchase-conference-grid label {
    gap: 4px;
    font-size: 11px;
    line-height: 1.15;
}

.purchase-conference-grid input,
.purchase-conference-grid select,
.purchase-conference-grid textarea {
    min-height: 32px;
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 800;
}

.purchase-field-label {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 26px;
    gap: 5px;
    align-items: center;
}

.purchase-field-help-wrap {
    position: relative;
    display: inline-grid;
    place-items: center;
}

.purchase-field-help {
    display: inline-grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border: 1px solid #d9a06f;
    border-radius: 999px;
    background: #fff8ef;
    color: #9b4d17;
    cursor: help;
    font-size: 12px;
    font-weight: 900;
    padding: 0;
}

.purchase-field-help-bubble {
    position: absolute;
    top: 28px;
    right: 0;
    z-index: 8;
    width: min(300px, 74vw);
    padding: 8px 10px;
    border: 1px solid #d9a06f;
    border-radius: 8px;
    background: #fff8ef;
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.16);
    color: #1f3b57;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.35;
}

.purchase-conference-grid .full {
    grid-column: 1 / -1;
}

.purchase-conference-grid input[readonly] {
    border-color: transparent;
    background: #f6f8fa;
    box-shadow: none;
    color: #26384d;
}

.purchase-conference-grid input:not([readonly]):not(:disabled),
.purchase-conference-grid select:not(:disabled),
.purchase-conference-grid textarea:not(:disabled) {
    border-color: #d9a06f;
    background: #fffdfa;
    box-shadow: inset 3px 0 0 rgba(224, 122, 52, 0.75);
}

.purchase-conference-grid textarea:disabled {
    border-color: transparent;
    background: #f6f8fa;
    box-shadow: none;
}

.purchase-conference-grid input.is-negative-margin {
    border-color: #d94f4f;
    color: #8f1d1d;
    box-shadow: inset 3px 0 0 rgba(217, 79, 79, 0.85);
}

.purchase-conference-grid small {
    color: #8f1d1d;
    font-size: 10px;
    font-weight: 800;
}

.access-dialog-list {
    max-height: 420px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fffdfa;
}

.access-company-option {
    display: grid;
    grid-template-columns: 20px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border-bottom: 1px solid var(--line);
    cursor: pointer;
}

.access-company-option:last-child {
    border-bottom: 0;
}

.access-company-option:hover {
    background: #fff7f0;
}

.access-company-option[hidden] {
    display: none !important;
}

.access-company-main,
.access-company-meta {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.access-company-main strong,
.access-company-meta {
    font-size: 13px;
}

.access-company-main small,
.access-company-meta small {
    color: var(--muted);
    font-size: 11px;
}

.flash,
.notice {
    padding: 12px 14px;
    border-radius: 8px;
    margin-bottom: 12px;
    border: 1px solid transparent;
}

.flash-success,
.notice.success {
    background: #e6f6ee;
    border-color: #c9ebda;
    color: var(--success);
}

.flash-error,
.flash-warning,
.notice.warning {
    background: #fff0ea;
    border-color: #f3d6c8;
    color: var(--warning);
}

.system-messages {
    position: fixed;
    inset: auto 18px 18px auto;
    width: min(430px, calc(100vw - 28px));
    max-height: min(72vh, 640px);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    overflow-y: auto;
    border: 0;
    background: transparent;
    color: inherit;
    pointer-events: none;
    z-index: 2147483647;
}

.system-messages[hidden] {
    display: none;
}

.system-messages:popover-open {
    display: flex;
    flex-direction: column;
    gap: 9px;
    height: max-content;
}

.system-message {
    --system-message-color: #2563eb;
    display: grid;
    flex: 0 0 auto;
    grid-template-columns: 5px minmax(0, 1fr) 30px;
    min-height: 74px;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, .16);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 16px 38px rgba(15, 23, 42, .28);
    color: #1f2937;
    pointer-events: auto;
    animation: system-message-enter .2s ease-out both;
}

.system-message.is-leaving {
    animation: system-message-leave .18s ease-in both;
}

.system-message-error { --system-message-color: #c62828; }
.system-message-warning { --system-message-color: #b45309; }
.system-message-success { --system-message-color: #0f766e; }
.system-message-info { --system-message-color: #2563eb; }

.system-message-accent {
    background: var(--system-message-color);
}

.system-message-content {
    min-width: 0;
    padding: 11px 9px 11px 12px;
}

.system-message-title {
    display: block;
    margin-bottom: 3px;
    color: var(--system-message-color);
    font: 400 13px/1.25 Tahoma, Arial, sans-serif;
}

.system-message-text {
    overflow-wrap: anywhere;
    white-space: pre-wrap;
    font: 400 12px/1.4 Tahoma, Arial, sans-serif;
}

.system-message-close {
    align-self: start;
    width: 28px;
    height: 28px;
    margin: 5px 5px 0 0;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    font: 400 22px/1 Tahoma, Arial, sans-serif;
}

.system-message-close:hover,
.system-message-close:focus-visible {
    background: #f1f5f9;
    color: #0f172a;
    outline: 2px solid rgba(37, 99, 235, .2);
}

.system-message-details {
    margin-top: 7px;
    font: 400 11px/1.35 Tahoma, Arial, sans-serif;
}

.system-message-details summary {
    width: max-content;
    color: var(--system-message-color);
    cursor: pointer;
}

.system-message-details pre {
    max-height: 180px;
    margin: 6px 0 0;
    padding: 7px;
    overflow: auto;
    border-radius: 6px;
    background: #f8fafc;
    color: #334155;
    white-space: pre-wrap;
    font: 400 10px/1.35 Consolas, monospace;
}

@keyframes system-message-enter {
    from { opacity: 0; transform: translate3d(22px, 0, 0); }
    to { opacity: 1; transform: translate3d(0, 0, 0); }
}

@keyframes system-message-leave {
    from { opacity: 1; transform: translate3d(0, 0, 0); }
    to { opacity: 0; transform: translate3d(22px, 0, 0); }
}

@media (max-width: 640px) {
    .system-messages {
        inset: auto 8px 8px 8px;
        width: auto;
        max-height: 56vh;
    }
}

.notice {
    background: #fff7f1;
    border-color: #f1dfd2;
    color: #8f5d35;
}

.session-bar,
.auth-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.session-bar {
    background: #fffdfa;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px 14px;
    color: var(--muted);
    font-size: 12px;
}

.session-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 8px;
    background: #edf8ef;
    color: #2d6b39;
    font-weight: 700;
}

.session-badge.warning {
    background: #fff0ea;
    color: #b84202;
}

.session-badge.authorized {
    background: #e8f2ff;
    color: #175aa6;
}

.session-badge.invalidated {
    background: #f2e9ff;
    color: #6b2aa6;
}

.session-badge.danger {
    background: #fff3ef;
    color: #a62b16;
}

.mdfe-panel,
.mdfe-documents-panel {
    margin-top: 14px;
}

.mdfe-head {
    display: grid;
    grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.6fr);
    gap: 10px;
    align-items: center;
}

.mdfe-panel .button,
.mdfe-modal-backdrop .button,
.mdfe-filter label,
.mdfe-filter input,
.mdfe-filter select,
.mdfe-filter-actions,
.mdfe-system-search-filter label,
.mdfe-system-search-filter input,
.mdfe-system-search-filter .button,
.mdfe-picker-filter label,
.mdfe-picker-filter input,
.mdfe-picker-filter .button {
    font-weight: 400;
}

.mdfe-transit-inline {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    min-width: 0;
    flex-wrap: nowrap;
    font-size: 12px;
    font-weight: 400;
}

.mdfe-transit-stat {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 1 150px;
    min-width: 130px;
    max-width: 210px;
    min-height: 28px;
    padding: 4px 10px;
    border: 1px solid #e2a08f;
    border-radius: 6px;
    background: #fff6f3;
    color: #842f1f;
    font-weight: 400;
    white-space: nowrap;
    box-shadow: inset 3px 0 0 #d45a3d;
}

.mdfe-transit-inline .button {
    border-color: #e2a08f;
    background: #fff6f3;
    color: #842f1f;
}

.mdfe-transit-modal-card {
    width: min(980px, calc(100vw - 44px));
    max-height: calc(100vh - 68px);
    overflow: hidden;
}

.products-grid-wrap.mdfe-transit-grid-wrap {
    height: min(360px, calc(100vh - 230px));
    min-height: 180px;
    overflow-x: hidden;
}

.products-grid.mdfe-transit-grid {
    min-width: 100%;
    width: 100%;
    table-layout: fixed;
}

.products-grid.mdfe-transit-grid th,
.products-grid.mdfe-transit-grid td {
    height: 24px;
    padding: 3px 6px;
    white-space: normal;
}

.products-grid.mdfe-transit-grid th:nth-child(1) {
    width: 10%;
}

.products-grid.mdfe-transit-grid th:nth-child(2) {
    width: 22%;
}

.products-grid.mdfe-transit-grid th:nth-child(3) {
    width: 14%;
}

.products-grid.mdfe-transit-grid th:nth-child(4) {
    width: 27%;
}

.products-grid.mdfe-transit-grid th:nth-child(5) {
    width: 10%;
}

.products-grid.mdfe-transit-grid th:nth-child(6) {
    width: 17%;
}

.mdfe-filter {
    display: grid;
    grid-template-columns: minmax(110px, 132px) minmax(110px, 132px) minmax(120px, 150px) minmax(135px, 1fr) minmax(130px, 0.9fr) minmax(180px, 1.3fr) minmax(76px, auto);
    gap: 6px;
    align-items: end;
}

.mdfe-filter label {
    min-width: 0;
}

.mdfe-filter input,
.mdfe-filter select {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.mdfe-filter-search input {
    min-width: 0;
}

.mdfe-filter-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: flex-end;
    min-width: 0;
}

.mdfe-filter-actions .button {
    min-width: 76px;
}

.mdfe-grid-wrap {
    height: clamp(220px, calc(100vh - 390px), 380px);
    min-height: 220px;
}

.mdfe-grid {
    min-width: 1420px;
}

.mdfe-grid tbody tr.is-selected {
    background: #dff5f2;
    box-shadow: inset 3px 0 0 var(--primary);
}

.mdfe-grid tbody tr.is-selected:hover {
    background: #d4f0ec;
}

.mdfe-grid tbody tr {
    cursor: pointer;
}

.mdfe-status-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.mdfe-status-tooltip .tooltiptext {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    z-index: 25;
    left: 0;
    top: calc(100% + 6px);
    width: min(420px, 70vw);
    padding: 8px 10px;
    border: 1px solid #e8c8b8;
    border-radius: 6px;
    background: #fff7f2;
    color: #7a341b;
    box-shadow: 0 8px 22px rgba(60, 80, 100, 0.16);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.35;
    white-space: normal;
    pointer-events: none;
}

.mdfe-status-tooltip:hover .tooltiptext,
.mdfe-status-tooltip:focus .tooltiptext {
    visibility: visible;
    opacity: 1;
}

.mdfe-bottom-bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 6px;
}

.mdfe-bottom-bar form {
    margin: 0;
}

.mdfe-selection-state {
    color: var(--muted);
    font-size: 12px;
    font-weight: 400;
}

.mdfe-col-created {
    width: 6.5%;
}

.mdfe-col-status {
    width: 5.5%;
}

.mdfe-col-open {
    width: 5.5%;
}

.mdfe-col-route {
    width: 11%;
}

.mdfe-col-vehicle {
    width: 5.5%;
}

.mdfe-col-driver {
    width: 8.5%;
}

.mdfe-col-docs {
    width: 3%;
}

.mdfe-col-total {
    width: 6%;
}

.mdfe-col-env {
    width: 4.5%;
}

.mdfe-col-authorized {
    width: 7%;
}

.mdfe-col-number {
    width: 4.5%;
}

.mdfe-col-protocol {
    width: 7%;
}

.mdfe-col-key {
    width: 25%;
}

.mdfe-open-cell {
    color: #7a341b;
    white-space: nowrap;
}

.mdfe-key-cell {
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: 10.5px;
    white-space: nowrap;
    word-break: normal;
}

.mdfe-form {
    display: grid;
    gap: 0;
}

.mdfe-form-grid {
    display: grid;
    grid-template-columns: 1fr 0.65fr 1.25fr 0.55fr;
    gap: 6px;
}

.mdfe-form-grid label,
.mdfe-doc-entry label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.mdfe-form-grid input,
.mdfe-form-grid select,
.mdfe-form-grid textarea,
.mdfe-doc-entry input {
    width: 100%;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 6px 8px;
    font: inherit;
}

.mdfe-form-grid .wide,
.mdfe-doc-entry .wide {
    grid-column: span 2;
}

.mdfe-form-grid .span-2 {
    grid-column: span 2;
}

.mdfe-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}

.mdfe-summary span {
    display: grid;
    gap: 2px;
    min-height: 42px;
    padding: 7px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f7fafc;
    font-size: 12px;
}

.mdfe-summary strong {
    color: var(--muted);
    font-size: 10px;
    text-transform: uppercase;
}

.mdfe-documents-wrap {
    height: 250px;
    min-height: 220px;
}

.products-grid.mdfe-documents-grid,
.products-grid.mdfe-create-docs-grid {
    min-width: 100%;
    width: 100%;
    table-layout: fixed;
}

.mdfe-status-actions {
    margin-top: 10px;
}

.mdfe-status-actions form,
.mdfe-documents-grid form,
.mdfe-modal-actions form {
    margin: 0;
}

.mdfe-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(16, 31, 45, 0.38);
}

.mdfe-modal-backdrop[hidden] {
    display: none;
}

.mdfe-modal-card {
    position: relative;
    width: min(1240px, calc(100vw - 36px));
    max-height: calc(100vh - 40px);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-confirm-card {
    width: min(440px, calc(100vw - 36px));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-confirm-card .mdfe-modal-actions {
    justify-content: flex-end;
}

.mdfe-wait-card {
    width: min(460px, calc(100vw - 36px));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-wait-body {
    display: grid;
    gap: 10px;
    padding: 12px 14px 14px;
}

.mdfe-wait-body p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 400;
}

.mdfe-wait-bar {
    position: relative;
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #e7eff5;
}

.mdfe-wait-bar span {
    position: absolute;
    inset: 0 auto 0 0;
    width: 42%;
    border-radius: inherit;
    background: linear-gradient(90deg, #de7a36, #f5b678);
    animation: mdfe-wait-slide 1.05s ease-in-out infinite;
}

@keyframes mdfe-wait-slide {
    0% {
        transform: translateX(-110%);
    }

    100% {
        transform: translateX(245%);
    }
}

.mdfe-damdfe-card {
    width: min(1080px, calc(100vw - 36px));
    height: min(84vh, 760px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-damdfe-card iframe {
    width: 100%;
    height: 100%;
    border: 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: #fff;
}

.mdfe-email-card {
    width: min(560px, calc(100vw - 36px));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-email-card form,
.mdfe-email-body {
    display: grid;
}

.mdfe-email-body {
    gap: 10px;
    padding: 12px 14px;
}

.mdfe-email-body label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.mdfe-email-body input {
    width: 100%;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 6px 8px;
    font: inherit;
}

.mdfe-email-facts {
    display: grid;
    grid-template-columns: minmax(120px, 0.45fr) minmax(0, 1fr);
    gap: 6px;
}

.mdfe-email-facts span {
    display: grid;
    gap: 2px;
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid #d8e7f1;
    border-radius: 6px;
    background: #f8fbfd;
    color: var(--text);
    font-size: 11px;
    word-break: break-all;
}

.mdfe-email-facts strong {
    color: var(--muted);
    font-size: 10px;
    text-transform: uppercase;
}

.mdfe-events-card {
    width: min(900px, calc(100vw - 44px));
    max-height: calc(100vh - 80px);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.products-grid-wrap.mdfe-events-grid-wrap {
    height: min(330px, calc(100vh - 230px));
    min-height: 180px;
    overflow-x: hidden;
}

.products-grid.mdfe-events-grid {
    min-width: 100%;
    width: 100%;
    table-layout: fixed;
}

.products-grid.mdfe-events-grid th,
.products-grid.mdfe-events-grid td {
    height: 24px;
    padding: 3px 6px;
    white-space: normal;
}

.mdfe-event-form-card {
    width: min(620px, calc(100vw - 44px));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-event-form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 8px;
    padding: 12px 14px;
}

.mdfe-event-form-grid.single {
    grid-template-columns: 1fr;
}

.mdfe-event-form-grid label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 400;
}

.mdfe-event-form-grid input,
.mdfe-event-form-grid select,
.mdfe-event-form-grid textarea {
    width: 100%;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 6px 8px;
    font: inherit;
    font-weight: 400;
}

.mdfe-event-driver-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
}

.mdfe-event-driver-line .button {
    min-height: 32px;
}

.mdfe-event-driver-search-card {
    width: min(720px, calc(100vw - 44px));
    max-height: calc(100vh - 120px);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-event-driver-search-card .mdfe-picker-filter {
    padding: 10px 14px;
}

.products-grid-wrap.mdfe-event-driver-picker-wrap {
    height: 178px;
    min-height: 150px;
    max-height: 178px;
    margin: 0 14px 0;
    overflow-x: hidden;
}

.mdfe-modal-card .modal-head,
.mdfe-modal-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--line);
}

.mdfe-register-modal-card .modal-head {
    padding: 10px 12px 6px;
}

.mdfe-register-modal-card .modal-head h2 {
    font-size: 18px;
}

.mdfe-register-modal-card .modal-head p {
    margin-top: 2px;
    font-size: 12px;
}

.mdfe-modal-card .modal-head h2 {
    margin: 0;
    font-size: 18px;
}

.mdfe-modal-card .modal-head p {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.mdfe-modal-card .modal-head .mdfe-create-title-line {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-width: 0;
    text-align: center;
}

.mdfe-modal-card .modal-head .mdfe-create-title-line p {
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mdfe-modal-body {
    display: grid;
    grid-template-columns: minmax(500px, 0.9fr) minmax(520px, 1.1fr);
    gap: 10px;
    max-height: calc(100vh - 150px);
    overflow: auto;
    padding: 10px 12px;
}

.mdfe-form-side {
    border-right: 1px solid #e2edf5;
    padding-right: 10px;
}

.mdfe-modal-docs {
    display: grid;
    gap: 10px;
    align-content: start;
}

.mdfe-grid-action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.mdfe-doc-entry {
    display: grid;
    grid-template-columns: minmax(220px, 1.4fr) 128px 95px minmax(110px, 0.75fr) minmax(110px, 0.75fr);
    gap: 6px;
    align-items: end;
}

.mdfe-create-base-grid {
    grid-template-columns: minmax(140px, 1fr) minmax(160px, 1.1fr);
    margin-bottom: 8px;
}

.mdfe-choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 8px;
}

.mdfe-choice-box,
.mdfe-route-box {
    display: grid;
    gap: 5px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fbfd;
    padding: 6px 8px;
}

.mdfe-choice-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-width: 0;
}

.mdfe-choice-box strong,
.mdfe-route-box strong,
.mdfe-section-head strong {
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
}

.mdfe-choice-box span,
.mdfe-section-head span,
.mdfe-route-preview {
    color: var(--muted);
    font-size: 11px;
    font-weight: 400;
    line-height: 1.2;
}

.mdfe-choice-box .button {
    min-height: 26px;
    padding: 5px 8px;
    font-size: 11px;
    font-weight: 400;
    white-space: nowrap;
}

.mdfe-edit-box-grid {
    display: grid;
    grid-template-columns: 1fr 74px;
    gap: 6px;
}

.mdfe-edit-box-grid label {
    display: grid;
    gap: 3px;
    min-width: 0;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.mdfe-edit-box-grid input,
.mdfe-edit-box-grid select {
    width: 100%;
    min-width: 0;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 6px 8px;
    font: inherit;
}

.mdfe-edit-box-grid .wide {
    grid-column: 1 / -1;
}

.mdfe-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.mdfe-section-head > div {
    display: grid;
    gap: 2px;
}

.mdfe-route-columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
}

.mdfe-route-columns > div {
    display: grid;
    gap: 4px;
}

.mdfe-route-percurso {
    display: grid;
    gap: 4px;
}

.mdfe-percurso-picker {
    display: grid;
    grid-template-columns: 64px 82px 82px;
    gap: 5px;
    align-items: center;
}

.mdfe-percurso-picker select {
    min-height: 28px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff;
    padding: 4px 6px;
    font: inherit;
    font-size: 12px;
}

.mdfe-percurso-picker .button {
    min-height: 28px;
    padding: 5px 8px;
    font-size: 12px;
    font-weight: 400;
}

.mdfe-route-list {
    height: 128px;
    min-height: 112px;
    max-height: 128px;
    overflow: auto;
    border: 1px solid #d8e7f1;
    border-radius: 6px;
    background: #fff;
    padding: 0;
}

.mdfe-route-head,
.mdfe-route-item {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    align-items: start;
}

.mdfe-route-head {
    position: sticky;
    top: 0;
    z-index: 1;
    min-height: 22px;
    padding: 4px 6px;
    border-bottom: 1px solid #d8e7f1;
    background: #eef5fa;
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.mdfe-route-empty {
    min-height: 25px;
    padding: 5px 8px;
    color: var(--muted);
    font-size: 12px;
}

.mdfe-route-item {
    min-height: 23px;
    padding: 3px 6px;
    border-bottom: 1px solid #edf3f7;
    cursor: grab;
}

.mdfe-route-item:last-child {
    border-bottom: 0;
}

.mdfe-route-item:hover {
    background: #f4f9fc;
}

.mdfe-route-item.is-selected {
    background: #d8edf8;
    box-shadow: inset 4px 0 0 #1f7aa8;
}

.mdfe-route-item.is-dragging {
    opacity: 0.55;
}

.mdfe-route-item.is-drop-target {
    outline: 1px dashed #1f7aa8;
    outline-offset: -3px;
}

.mdfe-route-grip {
    width: 14px;
    height: 18px;
    margin-top: 1px;
    background-image: radial-gradient(circle, #7893a5 1.2px, transparent 1.3px);
    background-position: 0 0;
    background-size: 5px 5px;
    opacity: 0.8;
}

.mdfe-route-city {
    display: block;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.2;
    overflow: visible;
    text-overflow: clip;
    white-space: normal;
    word-break: break-word;
}

.mdfe-route-city small {
    display: inline;
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
}

.mdfe-route-docs {
    display: grid;
    gap: 1px;
    padding: 2px 8px 4px 32px;
    border-bottom: 1px solid #edf3f7;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.2;
}

.mdfe-route-percurso-list {
    min-height: 0;
    max-height: 58px;
    overflow: auto;
    border: 1px solid #d8e7f1;
    border-radius: 6px;
    background: #fff;
}

.mdfe-route-preview {
    min-height: 28px;
    border: 1px solid #d8e7f1;
    border-radius: 6px;
    background: #fff;
    padding: 6px 8px;
    font-weight: 400;
    line-height: 1.25;
    white-space: normal;
    word-break: break-word;
}

.mdfe-create-actions {
    display: grid;
    grid-template-columns: 118px minmax(0, 520px) max-content;
    align-items: center;
}

.mdfe-route-preview-bar {
    width: 100%;
    max-height: 44px;
    overflow: auto;
    background: #f8fbfd;
}

.mdfe-create-actions .actions {
    justify-content: flex-end;
}

.mdfe-create-error-modal {
    position: fixed;
    inset: auto;
    top: 50%;
    left: 50%;
    right: auto;
    bottom: auto;
    z-index: 130;
    width: min(560px, calc(100vw - 40px));
    height: auto;
    min-height: 0;
    max-height: calc(100vh - 80px);
    transform: translate(-50%, -50%);
    grid-template-rows: auto auto auto;
    align-content: start;
    gap: 8px;
    overflow: visible;
}

.mdfe-create-error-body {
    display: grid;
    gap: 8px;
}

.mdfe-create-error-modal .modal-head,
.mdfe-create-error-modal .mdfe-modal-actions {
    padding: 8px 10px;
}

.mdfe-create-error-modal .mdfe-modal-actions {
    min-height: 0;
    border-top: 1px solid var(--line);
}

.mdfe-error-key {
    display: grid;
    gap: 4px;
    padding: 8px;
    border: 1px solid #f1dfd2;
    border-radius: 6px;
    background: #fff7f1;
}

.mdfe-error-key code {
    white-space: normal;
    word-break: break-all;
}

.mdfe-notes-grid {
    grid-template-columns: 1fr;
    margin-top: 8px;
}

.mdfe-doc-entry button {
    min-height: 32px;
}

.mdfe-create-docs-wrap {
    height: 330px;
    min-height: 260px;
}

.products-grid.mdfe-create-docs-grid th,
.products-grid.mdfe-create-docs-grid td,
.products-grid.mdfe-documents-grid th,
.products-grid.mdfe-documents-grid td {
    height: auto;
    min-height: 24px;
    white-space: normal;
    line-height: 1.25;
    vertical-align: top;
}

.products-grid.mdfe-create-docs-grid td:nth-child(2),
.products-grid.mdfe-documents-grid td:nth-child(2) {
    word-break: break-all;
}

.products-grid.mdfe-create-docs-grid td:nth-child(3),
.products-grid.mdfe-create-docs-grid td:nth-child(4),
.products-grid.mdfe-documents-grid td:nth-child(3),
.products-grid.mdfe-documents-grid td:nth-child(4) {
    word-break: break-word;
}

.mdfe-doc-col-model {
    width: 7%;
}

.mdfe-doc-col-key {
    width: 31%;
}

.mdfe-doc-col-issuer {
    width: 20%;
}

.mdfe-doc-col-recipient {
    width: 22%;
}

.mdfe-doc-col-value {
    width: 10%;
}

.mdfe-doc-col-weight {
    width: 10%;
}

.mdfe-grid-input {
    width: 100%;
    min-width: 0;
    height: 24px;
    border: 1px solid #bdd4e5;
    border-radius: 4px;
    background: #fff;
    padding: 2px 5px;
    font: inherit;
}

.mdfe-doc-weight-input {
    text-align: right;
}

.products-grid-wrap.mdfe-create-docs-wrap,
.products-grid-wrap.mdfe-documents-wrap {
    overflow-x: hidden;
}

.mdfe-create-docs-grid tr.is-selected td,
.mdfe-documents-grid tr.is-selected td,
.mdfe-system-docs-grid tr.is-selected td,
.mdfe-picker-grid tr.is-selected td {
    background: #d8edf8;
    box-shadow: inset 4px 0 0 #1f7aa8;
}

.mdfe-create-docs-grid tbody tr,
.mdfe-documents-grid tbody tr,
.mdfe-system-docs-grid tbody tr,
.mdfe-picker-grid tbody tr {
    cursor: pointer;
}

.products-grid.mdfe-create-docs-grid tr.is-selected td,
.products-grid.mdfe-documents-grid tr.is-selected td {
    box-shadow: none;
}

.products-grid.mdfe-create-docs-grid tr.is-selected td:first-child,
.products-grid.mdfe-documents-grid tr.is-selected td:first-child {
    box-shadow: inset 4px 0 0 #1f7aa8;
}

.mdfe-system-docs {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px;
    background: #f8fbfd;
}

.mdfe-system-docs summary {
    cursor: pointer;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.products-grid-wrap.mdfe-system-docs-wrap {
    height: 280px;
    min-height: 280px;
    max-height: 280px;
    margin-top: 0;
    overflow-x: hidden;
}

.products-grid.mdfe-system-docs-grid {
    min-width: 100%;
    width: 100%;
    table-layout: fixed;
}

.products-grid.mdfe-system-docs-grid th,
.products-grid.mdfe-system-docs-grid td {
    height: auto;
    min-height: 23px;
    padding: 2px 5px;
    white-space: normal;
    line-height: 1.25;
    vertical-align: top;
}

.products-grid.mdfe-system-docs-grid td:nth-child(2) {
    word-break: break-all;
}

.products-grid.mdfe-system-docs-grid td:nth-child(3) {
    word-break: break-word;
}

.mdfe-system-col-doc {
    width: 14%;
}

.mdfe-system-col-key {
    width: 32%;
}

.mdfe-system-col-recipient {
    width: 42%;
}

.mdfe-system-col-value {
    width: 12%;
}

.mdfe-system-search-call {
    display: flex;
    justify-content: flex-end;
}

.mdfe-search-modal {
    position: absolute;
    inset: 52px 16px 68px 16px;
    z-index: 2;
    display: grid;
    grid-template-rows: auto auto 1fr;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 16px 42px rgba(20, 40, 56, 0.20);
    padding: 10px;
}

.mdfe-note-modal {
    inset: 42px 18px auto 18px;
    grid-template-rows: auto auto auto;
    align-content: start;
    min-height: 0;
}

.mdfe-note-modal.has-system-search {
    inset: 52px 16px 68px 16px;
    grid-template-rows: auto auto auto 1fr;
}

.mdfe-note-entry {
    grid-template-columns: minmax(260px, 1.35fr) 112px minmax(150px, 0.9fr) minmax(150px, 0.9fr) 118px;
}

.mdfe-note-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.mdfe-system-search-panel {
    inset: 46px 10px auto 10px;
    height: min(462px, calc(100vh - 118px));
    max-height: calc(100vh - 118px);
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    gap: 8px;
    overflow: hidden;
    z-index: 3;
}

.mdfe-system-search-panel .mdfe-modal-actions {
    position: relative;
    z-index: 2;
    min-height: 42px;
    padding: 8px 0 0;
    background: #fff;
}

.mdfe-search-modal[hidden] {
    display: none;
}

.mdfe-search-modal.mdfe-create-error-modal {
    position: fixed;
    inset: auto;
    top: 50%;
    left: 50%;
    right: auto;
    bottom: auto;
    z-index: 130;
    width: min(520px, calc(100vw - 40px));
    height: auto;
    min-height: 0;
    max-height: calc(100vh - 80px);
    transform: translate(-50%, -50%);
    grid-template-rows: auto auto auto;
    align-content: start;
    gap: 8px;
    overflow: visible;
}

.mdfe-search-modal.mdfe-xml-error-modal {
    width: min(440px, calc(100vw - 40px));
}

.mdfe-system-search-filter {
    display: grid;
    grid-template-columns: 126px 126px minmax(180px, 1fr) minmax(170px, 0.9fr) auto;
    gap: 6px;
    align-items: end;
    padding: 0;
    border: 0;
    background: transparent;
}

.mdfe-system-search-filter label {
    display: grid;
    gap: 2px;
    min-width: 0;
    color: var(--muted);
    font-size: 11px;
    font-weight: 400;
}

.mdfe-system-search-filter input {
    width: 100%;
    min-width: 0;
    min-height: 30px;
    box-sizing: border-box;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 5px 7px;
    font: inherit;
}

.mdfe-system-search-filter .button {
    min-height: 30px;
}

.mdfe-picker-modal {
    inset: 54px auto auto 50%;
    width: min(720px, calc(100% - 44px));
    max-height: min(430px, calc(100vh - 160px));
    transform: translateX(-50%);
    grid-template-rows: auto auto 1fr auto;
    overflow: hidden;
}

.mdfe-picker-filter {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) auto;
    gap: 6px;
    align-items: end;
    padding: 0;
    border: 0;
    background: transparent;
}

.products-grid-wrap.mdfe-picker-wrap {
    height: 136px;
    min-height: 120px;
    max-height: 136px;
    overflow-x: hidden;
}

.products-grid.mdfe-picker-grid {
    min-width: 100%;
    width: 100%;
    table-layout: fixed;
}

.products-grid.mdfe-picker-grid th,
.products-grid.mdfe-picker-grid td {
    height: 23px;
    padding: 2px 5px;
}

.products-grid.mdfe-picker-grid tr.is-selected td {
    background: #d8edf8;
    box-shadow: none;
}

.products-grid.mdfe-picker-grid tr.is-selected td:first-child {
    box-shadow: inset 4px 0 0 #1f7aa8;
}

.mdfe-vehicle-picker-grid .mdfe-picker-col-plate {
    width: 18%;
}

.mdfe-vehicle-picker-grid .mdfe-picker-col-uf {
    width: 8%;
}

.mdfe-vehicle-picker-grid .mdfe-picker-col-rntrc {
    width: 18%;
}

.mdfe-vehicle-picker-grid .mdfe-picker-col-model {
    width: 56%;
}

.mdfe-driver-picker-grid .mdfe-picker-col-name {
    width: 42%;
}

.mdfe-driver-picker-grid .mdfe-picker-col-cpf {
    width: 18%;
}

.mdfe-driver-picker-grid .mdfe-picker-col-rntrc {
    width: 15%;
}

.mdfe-driver-picker-grid .mdfe-picker-col-cnh {
    width: 25%;
}

.mdfe-register-modal-card {
    width: min(760px, calc(100vw - 36px));
    max-height: calc(100vh - 36px);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-register-body {
    display: grid;
    grid-template-columns: minmax(520px, 1fr) minmax(280px, 360px);
    gap: 12px;
    padding: 8px 12px;
}

.mdfe-register-body.single {
    grid-template-columns: 1fr;
}

.products-grid-wrap.mdfe-register-grid-wrap {
    height: 132px;
    min-height: 118px;
    overflow-x: hidden;
}

.products-grid-wrap.mdfe-drivers-grid-wrap,
.products-grid-wrap.mdfe-vehicles-grid-wrap {
    height: 132px;
    min-height: 118px;
    max-height: 132px;
}

.products-grid.mdfe-register-grid {
    min-width: 100%;
    width: 100%;
    table-layout: fixed;
}

.products-grid.mdfe-register-grid th,
.products-grid.mdfe-register-grid td {
    height: 22px;
    padding: 2px 5px;
}

.mdfe-driver-col-name {
    width: 33%;
}

.mdfe-driver-col-cpf {
    width: 14%;
}

.mdfe-driver-col-rntrc {
    width: 11%;
}

.mdfe-driver-col-cnh {
    width: 16%;
}

.mdfe-driver-col-phone {
    width: 16%;
}

.mdfe-driver-col-status {
    width: 10%;
}

.mdfe-vehicle-col-plate {
    width: 12%;
}

.mdfe-vehicle-col-state {
    width: 6%;
}

.mdfe-vehicle-col-rntrc {
    width: 12%;
}

.mdfe-vehicle-col-model {
    width: 36%;
}

.mdfe-vehicle-col-type {
    width: 19%;
}

.mdfe-vehicle-col-status {
    width: 15%;
}

.mdfe-register-grid tr.is-selected td {
    background: #d8edf8;
    box-shadow: inset 4px 0 0 #1f7aa8;
}

.mdfe-register-grid tbody tr {
    cursor: pointer;
}

.mdfe-register-form {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    align-content: start;
}

.mdfe-register-form label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.mdfe-register-form input,
.mdfe-register-form select {
    width: 100%;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 6px 8px;
    font: inherit;
}

.mdfe-small-form-card {
    width: min(620px, calc(100vw - 36px));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 46px rgba(20, 40, 56, 0.22);
}

.mdfe-small-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 12px 14px;
}

.mdfe-small-form-grid .wide {
    grid-column: span 2;
}

.button.disabled {
    pointer-events: none;
    opacity: 0.48;
}

.mdfe-modal-actions {
    border-top: 1px solid var(--line);
    border-bottom: 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

@media (max-width: 1280px) {
    .mdfe-head {
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
    }

    .mdfe-head h2 {
        margin-bottom: 2px;
    }

    .mdfe-head p {
        margin-bottom: 0;
    }

    .mdfe-transit-inline {
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 6px;
    }

    .mdfe-transit-stat {
        flex: 1 1 150px;
        min-width: 136px;
        max-width: none;
    }

    .mdfe-transit-inline .button {
        flex: 0 1 128px;
        min-height: 28px;
        white-space: normal;
    }

    .mdfe-filter {
        grid-template-columns: repeat(4, minmax(120px, 1fr));
    }

    .mdfe-filter label:nth-of-type(5) {
        grid-column: 1 / 2;
    }

    .mdfe-filter-search {
        grid-column: 2 / 4;
    }

    .mdfe-filter-actions {
        grid-column: 4 / 5;
        justify-content: flex-end;
    }

    .products-grid-wrap.mdfe-grid-wrap {
        height: clamp(90px, calc(100vh - 520px), 220px);
        min-height: 90px;
    }
}

@media (max-width: 980px) {
    .mdfe-modal-card {
        max-height: calc(100svh - 18px);
    }

    .mdfe-form {
        max-height: calc(100svh - 18px);
        grid-template-rows: auto minmax(0, 1fr) auto;
    }

    .mdfe-filter,
    .mdfe-form-grid,
    .mdfe-summary,
    .mdfe-modal-body,
    .mdfe-doc-entry,
    .mdfe-choice-grid,
    .mdfe-route-columns,
    .mdfe-note-entry,
    .mdfe-register-body,
    .mdfe-small-form-grid,
    .mdfe-system-search-filter,
    .mdfe-picker-filter,
    .mdfe-event-form-grid {
        grid-template-columns: 1fr;
    }

    .mdfe-filter-search,
    .mdfe-filter-actions {
        grid-column: auto;
    }

    .mdfe-filter-actions {
        justify-content: stretch;
    }

    .mdfe-filter-actions .button {
        flex: 1 1 120px;
    }

    .mdfe-modal-body {
        max-height: none;
        min-height: 0;
    }

    .mdfe-create-docs-wrap {
        height: auto;
        min-height: 0;
        max-height: 170px;
        overflow: auto;
        overflow-x: auto !important;
    }

    .products-grid.mdfe-create-docs-grid {
        min-width: 760px;
        width: 760px;
        table-layout: fixed;
    }

    .mdfe-create-docs-grid .mdfe-doc-col-model {
        width: 70px;
    }

    .mdfe-create-docs-grid .mdfe-doc-col-key {
        width: 230px;
    }

    .mdfe-create-docs-grid .mdfe-doc-col-issuer,
    .mdfe-create-docs-grid .mdfe-doc-col-recipient {
        width: 145px;
    }

    .mdfe-create-docs-grid .mdfe-doc-col-value {
        width: 90px;
    }

    .mdfe-create-docs-grid .mdfe-doc-col-weight {
        width: 110px;
    }

    .products-grid.mdfe-create-docs-grid th,
    .products-grid.mdfe-create-docs-grid td {
        white-space: normal;
        word-break: normal;
    }

    .products-grid.mdfe-create-docs-grid td:nth-child(2) {
        word-break: break-all;
    }

    .mdfe-doc-weight-input {
        min-width: 92px;
        height: 32px;
        font-size: 13px;
    }

    .mdfe-note-modal,
    .mdfe-note-modal.has-system-search {
        inset: 34px 8px 64px 8px;
        grid-template-rows: auto auto auto minmax(0, 1fr);
        overflow: auto;
    }

    .mdfe-system-search-panel {
        inset: 48px 8px 8px 8px;
        height: auto;
        max-height: none;
        grid-template-rows: auto auto minmax(0, 1fr) auto;
        overflow: hidden;
    }

    .products-grid-wrap.mdfe-system-docs-wrap {
        height: auto;
        min-height: 86px;
        max-height: 128px;
        overflow: auto;
    }

    .products-grid.mdfe-system-docs-grid {
        min-width: 420px;
    }

    .mdfe-system-search-panel .mdfe-modal-actions {
        align-items: stretch;
        gap: 6px;
        min-height: 0;
    }

    .mdfe-bottom-bar,
    .mdfe-head,
    .mdfe-modal-card .modal-head,
    .mdfe-modal-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .mdfe-head {
        grid-template-columns: 1fr;
    }

    .mdfe-transit-inline {
        flex-wrap: wrap;
        justify-content: flex-start;
    }

    .mdfe-form-grid .wide,
    .mdfe-doc-entry .wide,
    .mdfe-small-form-grid .wide {
        grid-column: auto;
    }

    .mdfe-picker-modal {
        inset: 58px 14px 76px 14px;
        width: auto;
        max-width: none;
        max-height: none;
        transform: none;
    }

    .mdfe-picker-modal .modal-head {
        align-items: center;
        flex-direction: row;
    }

    .mdfe-picker-modal .modal-head .button {
        flex: 0 0 auto;
    }

    .products-grid-wrap.mdfe-picker-wrap {
        height: min(180px, calc(100vh - 330px));
        min-height: 132px;
        max-height: 180px;
        overflow-x: auto;
    }

    .products-grid.mdfe-picker-grid {
        min-width: 420px;
    }
}

.auth-links {
    margin-top: 10px;
}

.auth-register-callout {
    margin-top: 14px;
    display: grid;
    gap: 12px;
    padding: 14px;
    border: 1px solid #f1dfd2;
    border-radius: 8px;
    background: #fff7f1;
}

.auth-register-copy {
    display: grid;
    gap: 4px;
}

.auth-register-copy strong {
    font-size: 15px;
}

.auth-register-copy span {
    color: var(--muted);
    font-size: 12px;
}

.auth-register-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.auth-panel {
    max-width: 520px;
}

.auth-showcase {
    display: grid;
    grid-template-columns: minmax(300px, 420px) minmax(0, 1fr);
    gap: 18px;
    align-items: stretch;
}

.auth-panel-compact {
    max-width: none;
    margin: 0;
    padding: 22px 18px;
    align-self: start;
}

.auth-panel-head {
    display: grid;
    gap: 6px;
    margin-bottom: 16px;
}

.auth-panel-head h1,
.auth-marketing h2 {
    margin: 0;
}

.auth-panel-head p,
.auth-marketing p,
.media-card-copy span {
    margin: 0;
    color: var(--muted);
}

.auth-marketing {
    min-height: 100%;
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 16px;
    background: #f8fbff;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 18px;
}

.auth-marketing-2g {
    align-items: stretch;
    background: #f8fbff;
}

.auth-marketing-copy {
    display: grid;
    align-content: start;
    gap: 12px;
}

.auth-marketing-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.auth-marketing-list {
    margin: 0;
    padding-left: 18px;
    display: grid;
    gap: 6px;
    font-size: 12px;
}

.auth-marketing-media {
    display: grid;
    gap: 12px;
}

.platform-preview,
.landing-preview {
    display: grid;
    gap: 14px;
    align-content: start;
    padding: 16px;
    border: 1px solid #c8d7e6;
    border-radius: 8px;
    background: #ffffff;
}

.platform-preview-head,
.landing-preview-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.platform-preview-head img {
    width: 148px;
    max-width: 45%;
    height: auto;
}

.platform-preview-head span,
.landing-preview-bar span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.platform-preview-grid,
.landing-preview-metrics,
.landing-feature-grid {
    display: grid;
    gap: 10px;
}

.platform-preview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.platform-preview-grid article,
.landing-preview-metrics article,
.landing-feature-grid article,
.landing-preview-table span {
    display: grid;
    gap: 4px;
    padding: 12px;
    border: 1px solid #d7e3ee;
    border-radius: 8px;
    background: #f8fbff;
}

.platform-preview-grid span,
.landing-preview-metrics span,
.landing-feature-grid span {
    color: var(--muted);
    font-size: 12px;
}

.landing-hero,
.landing-split {
    display: grid;
    grid-template-columns: minmax(260px, 0.72fr) minmax(420px, 1.28fr);
    gap: 22px;
    align-items: stretch;
    margin-bottom: 26px;
    padding: 28px 32px;
    border: 0;
    border-radius: 14px;
    box-shadow: none;
}

.landing-hero {
    background: #e8f5f2;
}

.landing-split-text-right {
    grid-template-columns: minmax(420px, 1.28fr) minmax(260px, 0.72fr);
}

.landing-split-text-right > :first-child {
    order: 2;
}

.landing-split-text-right > :last-child {
    order: 1;
}

.landing-hero-copy {
    display: grid;
    gap: 10px;
    align-content: center;
    max-width: 780px;
    min-width: 0;
    padding: 0;
    border-radius: 0;
    background: transparent;
}

.landing-contact-strip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    max-width: 100%;
    padding: 6px 10px 6px 7px;
    border: 1px solid #bfe8ce;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.84);
    color: #14202d;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(37, 211, 102, 0.12);
}

.landing-contact-strip img {
    display: block;
    width: 23px;
    height: 23px;
    object-fit: contain;
}

.landing-contact-strip:hover,
.landing-contact-strip:focus {
    border-color: #25d366;
    background: #f3fff7;
    color: #14202d;
    outline: 2px solid rgba(37, 211, 102, 0.2);
    outline-offset: 2px;
}

.landing-brand-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #233941;
    font-size: 13px;
    font-weight: 700;
}

.landing-logo {
    width: 28px;
    height: auto;
}

.landing-hero h1 {
    max-width: 680px;
    margin: 0;
    color: #16252d;
    font-size: 22px;
    font-weight: 650;
    line-height: 1.16;
}

.landing-hero p {
    max-width: 700px;
    margin: 0;
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.48;
}

.landing-login-form {
    display: grid;
    gap: 8px;
    max-width: 360px;
}

.landing-login-form label {
    display: grid;
    gap: 4px;
    color: #3c4d55;
    font-size: 11px;
    font-weight: 700;
}

.landing-login-form input {
    min-height: 34px;
    border: 1px solid rgba(18, 172, 160, 0.22);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.86);
    color: var(--text);
    padding: 7px 10px;
    font: inherit;
    font-size: 12px;
}

.landing-login-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding-top: 2px;
}

.landing-login-actions > a:not(.button) {
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.landing-login-note {
    display: grid;
    gap: 2px;
    color: var(--muted);
    font-size: 11.5px;
}

.landing-login-note strong {
    color: #16252d;
}

.landing-hero-visual,
.landing-pdv-visual {
    display: grid;
    align-content: stretch;
    min-width: 0;
    padding: 0;
    border-radius: 0;
    background: transparent;
}

.landing-hero .landing-shot-frame,
.landing-pdv-showcase .landing-shot-frame {
    background: transparent;
}

.landing-hero .landing-shot-frame img,
.landing-pdv-showcase .landing-shot-frame img {
    background: transparent;
}

.landing-shot-frame {
    position: relative;
    min-height: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 8px;
    background: #e6f0f2;
}

.landing-shot-frame img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    background: #f7fbfc;
}

.landing-shot-frame.is-missing .landing-media-placeholder {
    display: grid;
}

.landing-pdv-showcase {
    grid-template-columns: minmax(420px, 1.2fr) minmax(260px, 0.8fr);
    gap: 24px;
    align-items: center;
    background: #fff5eb;
}

.landing-pdv-copy {
    display: grid;
    gap: 12px;
    min-width: 0;
}

.landing-pdv-copy h2 {
    margin: 0;
    color: #16252d;
    font-size: 20px;
    font-weight: 650;
    line-height: 1.18;
}

.landing-pdv-copy p {
    margin: 0;
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.55;
}

.landing-pdv-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 4px;
}

.landing-pdv-button {
    background: #102224;
    border-color: #102224;
    color: #ffffff;
    box-shadow: 0 10px 22px rgba(16, 34, 36, 0.14);
}

.landing-pdv-button:hover {
    background: #18373a;
    border-color: #18373a;
}

.landing-preview-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.landing-preview-table {
    display: grid;
    gap: 8px;
}

.landing-section {
    scroll-margin-top: 18px;
}

.landing-feature-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.site-body .landing-feature-grid {
    gap: 18px;
}

.site-body .landing-feature-grid article {
    gap: 10px;
    padding: 20px;
    border: 1px solid rgba(18, 172, 160, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.76);
    box-shadow: 0 12px 26px rgba(16, 34, 36, 0.045), 0 0 0 1px rgba(255, 255, 255, 0.36) inset;
}

.site-body .landing-feature-grid article:nth-child(3n + 2) {
    border-color: rgba(222, 122, 54, 0.16);
    box-shadow: 0 12px 26px rgba(222, 122, 54, 0.055), 0 0 0 1px rgba(255, 255, 255, 0.36) inset;
}

.site-body .landing-feature-grid article:nth-child(3n) {
    border-color: rgba(37, 99, 235, 0.12);
    box-shadow: 0 12px 26px rgba(37, 99, 235, 0.04), 0 0 0 1px rgba(255, 255, 255, 0.36) inset;
}

.landing-hero-seo {
    position: relative;
    overflow: hidden;
}

.landing-hero-seo::before {
    content: none;
}

.landing-hero-seo > * {
    position: relative;
}

.landing-trust-list,
.landing-keyword-cloud,
.landing-segment-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.landing-trust-list span,
.landing-keyword-cloud span,
.landing-segment-grid span {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 5px 10px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    color: #28424b;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0;
}

.site-body .eyebrow {
    letter-spacing: 0.06em;
    font-weight: 700;
}

.site-body .panel-head h1,
.site-body .panel-head h2,
.site-body .landing-feature-grid strong,
.site-body .landing-proof-grid strong,
.site-body .landing-flow-grid strong,
.site-body .landing-faq-grid strong,
.site-body .landing-media-card figcaption strong {
    color: #16252d;
    font-weight: 700;
    letter-spacing: 0;
}

.site-body .button {
    font-weight: 700;
    letter-spacing: 0;
}

.site-body .landing-hero .actions {
    align-items: center;
    gap: 10px;
}

.site-body .landing-section {
    margin-bottom: 28px;
    padding: 30px 34px;
    border: 0;
    border-radius: 14px;
    box-shadow: none;
}

.site-body .landing-section .panel-head {
    margin-bottom: 22px;
}

.site-body .landing-section .panel-head h2 {
    font-size: 20px;
    line-height: 1.18;
    font-weight: 650;
}

.site-body .landing-section .panel-head p {
    max-width: 900px;
    font-size: 13.5px;
    line-height: 1.55;
}

.site-body #prints {
    background: #ffffff;
}

.site-body #por-que-2g {
    background: #eaf6f0;
}

.site-body #solucoes {
    background: #fff4e9;
}

.site-body #recursos {
    background: #f2f8ff;
}

.site-body #fluxos {
    background: #eef7f5;
}

.site-body #segmentos {
    background: #fff8ed;
}

.site-body #duvidas {
    background: #f5f4ff;
}

.site-body #credibilidade {
    background: #eef8ef;
}

.site-body #planos {
    background: #e6f3f2;
}

.landing-human-copy .panel-head p {
    max-width: 1040px;
}

.landing-human-copy .panel-head p + p {
    margin-top: 8px;
}

.landing-proof-grid,
.landing-flow-grid,
.landing-faq-grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.landing-proof-grid article,
.landing-flow-grid article,
.landing-faq-grid article {
    display: grid;
    gap: 10px;
    align-content: start;
    padding: 20px;
    border: 1px solid rgba(18, 172, 160, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 12px 26px rgba(16, 34, 36, 0.045), 0 0 0 1px rgba(255, 255, 255, 0.32) inset;
}

.landing-proof-grid article:nth-child(2n),
.landing-flow-grid article:nth-child(2n),
.landing-faq-grid article:nth-child(2n) {
    border-color: rgba(222, 122, 54, 0.16);
    box-shadow: 0 12px 26px rgba(222, 122, 54, 0.055), 0 0 0 1px rgba(255, 255, 255, 0.32) inset;
}

.landing-proof-grid p,
.landing-flow-grid span,
.landing-faq-grid span {
    margin: 0;
    color: var(--muted);
    font-size: 12.5px;
    line-height: 1.45;
}

.landing-seo-band .panel-head p,
.landing-cta-section .panel-head p {
    max-width: 980px;
}

.landing-cta-section {
    border-color: #c9e2de;
    background: #fbfffe;
}

.landing-media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.landing-media-card {
    display: grid;
    gap: 14px;
    margin: 0;
    padding: 14px;
    border: 1px solid rgba(18, 172, 160, 0.14);
    border-radius: 12px;
    background: #f4fafb;
    box-shadow: 0 12px 26px rgba(16, 34, 36, 0.05), 0 0 0 1px rgba(255, 255, 255, 0.42) inset;
}

.landing-media-card:nth-child(2n) {
    border-color: rgba(222, 122, 54, 0.16);
    box-shadow: 0 12px 26px rgba(222, 122, 54, 0.055), 0 0 0 1px rgba(255, 255, 255, 0.42) inset;
}

.landing-media-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 0;
    border-radius: 10px;
    background: #e6f0f2;
}

.landing-media-frame img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    background: #f7fbfc;
}

.landing-media-placeholder {
    position: absolute;
    inset: 0;
    display: none;
    place-content: center;
    gap: 6px;
    padding: 16px;
    text-align: center;
    color: #54666e;
}

.landing-media-card.is-missing .landing-media-placeholder {
    display: grid;
}

.landing-media-placeholder strong {
    color: #203841;
    font-size: 13px;
}

.landing-media-placeholder span {
    font-size: 12px;
    font-weight: 700;
}

.landing-media-card figcaption {
    display: grid;
    gap: 4px;
}

.landing-media-card figcaption span {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.4;
}

.media-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.media-card {
    display: grid;
    background: #fff;
    border: 1px solid #eadfd4;
    border-radius: 8px;
    overflow: hidden;
}

.media-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.media-card-main img {
    height: 260px;
}

.media-card-copy {
    display: grid;
    gap: 4px;
    padding: 12px;
    font-size: 12px;
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    align-items: end;
    margin-bottom: 12px;
}

.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 8px;
    background: #fff1e8;
    color: #92430f;
    padding: 7px 10px;
    font-size: 11px;
    font-weight: 700;
}

.badge.secondary {
    background: #f1ece5;
    color: #645749;
}

.checkbox-field {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 400;
}

.checkbox-field input {
    width: auto;
}

.inline-actions {
    display: flex;
    align-items: end;
}

.company-help-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.company-contact-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    padding: 14px;
    margin-bottom: 14px;
    background: #fff7f1;
    border: 1px solid #f1dfd2;
    border-radius: 8px;
}

.company-contact-box p {
    margin: 4px 0 0;
    color: var(--muted);
}

.company-contact-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.settings-shortcuts {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 2px;
}

.settings-launcher-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 12px;
}

.settings-launcher-card {
    border: 1px solid #e6d7c5;
    border-radius: 12px;
    background: #fffdfa;
    padding: 14px;
    display: grid;
    gap: 6px;
    text-align: left;
    cursor: pointer;
    color: inherit;
    text-decoration: none;
}

.settings-launcher-card strong {
    font-size: 15px;
    line-height: 1.2;
}

.settings-launcher-card span {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.35;
}

.settings-card {
    display: grid;
    gap: 12px;
}

.settings-card-head {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 12px;
}

.settings-card-head p,
.settings-subcard-head p {
    margin: 4px 0 0;
    color: var(--muted);
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    align-items: start;
}

.settings-grid .full {
    grid-column: 1 / -1;
}

.settings-grid-compact {
    grid-template-columns: repeat(4, minmax(160px, 1fr));
    gap: 10px 12px;
}

.settings-subcard {
    border: 1px solid #e6d7c5;
    border-radius: 12px;
    background: #fffdfa;
    padding: 12px;
    display: grid;
    gap: 10px;
}

.settings-subcard-head {
    display: grid;
    gap: 2px;
}

.settings-subcard-head-compact {
    margin-top: 14px;
}

.company-margin-analysis-panel {
    margin-top: 10px;
}

.company-margin-analysis-note,
.company-credit-limit-note {
    border: 1px solid #cfdfe9;
    border-radius: 6px;
    background: #f7fbfd;
    color: #455a6f;
    font-size: 11px;
    line-height: 1.45;
    padding: 8px 10px;
}

.company-credit-limit-note {
    margin-top: 10px;
}

.settings-check-row {
    align-items: center;
    display: flex;
    flex-direction: row;
    gap: 8px;
    min-height: 38px;
}

.settings-check-row input {
    width: auto;
}

.company-fiscal-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.company-fiscal-toolbar .button.is-active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.company-fiscal-panel[hidden] {
    display: none !important;
}

.company-fiscal-grid {
    grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.settings-modal-card {
    display: none;
}

.settings-modal-card[hidden] {
    display: none !important;
}

.settings-modal-card.is-open {
    display: grid;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: min(1100px, calc(100vw - 28px));
    max-height: calc(100vh - 32px);
    overflow: auto;
    padding: 16px;
    z-index: 1200;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.18);
}

#company-fiscal,
#company-fiscal * {
    font-weight: 400 !important;
}

#company-fiscal.settings-modal-card.is-open {
    gap: 8px;
    padding: 10px;
}

#company-fiscal .settings-card-head {
    gap: 8px;
    align-items: center;
}

#company-fiscal .settings-card-head h2,
#company-fiscal .settings-subcard-head h3 {
    margin: 0;
    font-size: 17px;
    line-height: 1.15;
}

#company-fiscal .settings-card-head p,
#company-fiscal .settings-subcard-head p {
    margin-top: 2px;
    font-size: 11px;
    line-height: 1.25;
}

#company-fiscal .company-fiscal-toolbar {
    gap: 5px;
}

#company-fiscal .company-fiscal-toolbar .button,
#company-fiscal .settings-card-head .button {
    min-height: 28px;
    padding: 5px 10px;
    font-size: 11px;
}

#company-fiscal .settings-subcard {
    gap: 7px;
    padding: 8px 10px;
    border-radius: 8px;
}

#company-fiscal .company-fiscal-panel {
    gap: 8px;
}

#company-fiscal .company-fiscal-grid {
    grid-template-columns: repeat(4, minmax(125px, 1fr));
    gap: 6px 8px;
}

#company-fiscal label {
    display: grid;
    gap: 3px;
    font-size: 11px;
    line-height: 1.2;
}

#company-fiscal input,
#company-fiscal select,
#company-fiscal textarea {
    min-height: 30px;
    padding: 6px 9px;
    font-size: 12px;
}

#company-fiscal .company-receivable-settings-card,
#company-fiscal .company-margin-analysis-panel {
    margin-top: 4px;
}

#company-fiscal .company-receivable-settings-card {
    border-color: #cfdfe9;
    background: #f9fcfe;
}

#company-fiscal .company-credit-limit-note,
#company-fiscal .company-margin-analysis-note {
    margin-top: 2px;
    padding: 6px 8px;
    font-size: 10.5px;
    line-height: 1.35;
}

.settings-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(31, 36, 48, 0.48);
    z-index: 1190;
}

.settings-modal-backdrop[hidden] {
    display: none !important;
}

.settings-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 4px;
}

.company-document-onboarding {
    gap: 12px;
}

.company-document-onboarding-actions {
    gap: 10px;
    flex-wrap: wrap;
}

.company-document-lookup-result[hidden],
.company-document-access-form[hidden] {
    display: none !important;
}

[data-tax-field][hidden] {
    display: none !important;
}

.company-cert-actions {
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.module-settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 14px;
}

.tax-profile-layout {
    display: grid;
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
    gap: 18px;
}

.tax-profile-list {
    display: grid;
    gap: 12px;
    align-content: start;
    max-height: 720px;
    overflow: auto;
    padding-right: 4px;
}

.tax-profile-card {
    border: 1px solid #e6d7c5;
    border-radius: 14px;
    background: #fffdfa;
    padding: 14px;
    display: grid;
    gap: 10px;
}

.tax-profile-card.is-active {
    border-color: #de7a36;
    box-shadow: 0 0 0 1px rgba(222, 122, 54, 0.12);
}

.tax-profile-card-head {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 10px;
}

.tax-profile-status {
    border-radius: 999px;
    background: #efe5d9;
    color: #6a5848;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    white-space: nowrap;
}

.tax-profile-status.is-active {
    background: #e2f3e7;
    color: #25613b;
}

.tax-profile-meta,
.tax-profile-flags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tax-profile-meta span,
.tax-profile-flags span {
    font-size: 12px;
    line-height: 1.3;
    border-radius: 10px;
    background: #f7efe7;
    color: #6a5848;
    padding: 5px 8px;
}

.tax-profile-form-box {
    min-width: 0;
}

.tax-profile-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.toggle-field {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
}

.toggle-field input {
    width: 18px;
    height: 18px;
    margin: 0;
}

@media (max-width: 980px) {
    .tax-profile-layout {
        grid-template-columns: 1fr;
    }

    .tax-profile-list {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

.module-setting-option {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding: 16px 16px 14px;
    border: 1px solid #ead8ca;
    border-radius: 12px;
    background: linear-gradient(180deg, #fffefd 0%, #fff8f3 100%);
    box-shadow: 0 10px 24px rgba(31, 36, 48, 0.04);
    cursor: pointer;
    transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease, background .16s ease;
}

.module-setting-option:hover {
    border-color: #d9a57b;
    background: linear-gradient(180deg, #fffdfb 0%, #fff2e8 100%);
    transform: translateY(-1px);
}

.module-setting-option:has(input:checked) {
    border-color: rgba(216, 35, 42, 0.35);
    background: linear-gradient(180deg, #fff9fa 0%, #fff1f2 100%);
    box-shadow: 0 0 0 1px rgba(216, 35, 42, 0.08), 0 12px 26px rgba(216, 35, 42, 0.08);
}

.module-setting-option input[type="checkbox"] {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    accent-color: var(--primary);
}

.module-setting-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.module-setting-eyebrow {
    color: var(--primary);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.module-setting-check {
    display: grid;
    justify-items: center;
    gap: 6px;
    min-width: 52px;
}

.module-setting-check small {
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.module-setting-option strong {
    font-size: 16px;
    line-height: 1.2;
}

.module-setting-copy > small:last-child {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.35;
}

.stock-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding: 3px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    border: 1px solid transparent;
}

.stock-badge-ok {
    background: #edf8ef;
    border-color: #c9ebda;
    color: #1d7c57;
}

.stock-badge-low {
    background: #fff6e7;
    border-color: #f0d59e;
    color: #a36b16;
}

.stock-badge-error {
    background: #fff0ef;
    border-color: #f4c9cc;
    color: #a12a31;
}

.stock-badge-zero,
.stock-badge-inactive {
    background: #f1ece5;
    border-color: #e0d3c7;
    color: #645749;
}

.product-summary-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
    gap: 12px;
    align-items: start;
    margin-bottom: 12px;
}

.product-summary-card {
    display: grid;
    gap: 8px;
}

.product-summary-card h3,
.product-stock-layout h3 {
    margin: 0;
    font-size: 15px;
}

.product-meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
}

.product-meta-grid .detail-meta-card strong {
    font-size: 12px;
}

.products-dashboard-panel {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 196px);
    margin-bottom: 0;
    padding: 10px;
}

.products-toolbar {
    display: grid;
    grid-template-columns: repeat(16, minmax(52px, 1fr));
    gap: 6px;
    align-items: end;
    margin-bottom: 8px;
    padding: 6px;
    border: 1px solid #d5e5ef;
    border-radius: 8px;
    background: #f8fbfd;
}

.products-toolbar-search {
    grid-column: span 3;
}

.products-toolbar-code {
    grid-column: span 2;
}

.products-toolbar-group {
    grid-column: span 3;
}

.products-toolbar-ncm,
.products-toolbar-ncm-status,
.products-toolbar-tax {
    grid-column: span 2;
}

.products-toolbar-tiny,
.products-toolbar-limit {
    grid-column: span 1;
}

.products-toolbar-store {
    grid-column: span 6;
}

.products-toolbar label {
    display: grid;
    min-width: 0;
    gap: 2px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.products-toolbar input,
.products-toolbar select {
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    color: var(--text);
    padding: 5px 7px;
    font: inherit;
    font-size: 12px;
}

.products-toolbar .button {
    min-height: 34px;
    justify-content: center;
}

.products-filter-submit {
    grid-column: span 1;
    background: #e07a32;
    border-color: #e07a32;
    color: #fff;
    font-weight: 800;
}

.products-filter-submit:hover,
.products-filter-submit:focus-visible {
    background: #c95f18;
    border-color: #c95f18;
    color: #fff;
}

.products-filter-submit:focus-visible {
    outline: 2px solid rgba(224, 122, 50, 0.35);
    outline-offset: 2px;
}

.products-filter-clear {
    grid-column: span 1;
    background: #f2f8fb;
    border-color: #cfe0ea;
    color: #526779;
}

.products-grid-wrap {
    flex: none;
    min-height: 300px;
    height: clamp(300px, calc(100vh - 370px), 540px);
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.products-grid {
    width: 100%;
    min-width: 1400px;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 11.5px;
}

.products-grid th,
.products-grid td {
    height: 26px;
    padding: 3px 5px;
    border-bottom: 1px solid #e2edf5;
    text-align: left;
    vertical-align: middle;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.products-grid th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f4f8fb;
    color: var(--muted);
    font-size: 10.5px;
    text-transform: uppercase;
}

.products-grid td.credit-limit-label {
    width: 110px;
    min-width: 110px;
    max-width: 110px;
    font-weight: 600;
    white-space: nowrap;
}

.products-main-grid th[data-products-sort-key] {
    cursor: pointer;
    user-select: none;
}

.products-main-grid th[data-products-sort-key]:focus {
    outline: 2px solid #f97316;
    outline-offset: -2px;
}

.products-main-grid th[data-products-sort-key]::after {
    content: "";
    display: inline-block;
    min-width: 10px;
    margin-left: 3px;
    color: #d86f2b;
    font-size: 9px;
}

.products-main-grid th[data-products-sort-key].is-sorted-asc::after {
    content: "^";
}

.products-main-grid th[data-products-sort-key].is-sorted-desc::after {
    content: "v";
}

.products-grid col.products-col-group {
    width: 8%;
}

.products-grid col.products-col-sku {
    width: 5%;
}

.products-grid col.products-col-barcode {
    width: 9%;
}

.products-grid col.products-col-photo {
    width: 32px;
}

.products-grid col.products-col-name {
    width: 20%;
}

.products-grid col.products-col-unit {
    width: 3%;
}

.products-grid col.products-col-ncm {
    width: 6%;
}

.products-grid col.products-col-tax {
    width: 8%;
}

.products-grid col.products-col-supplier {
    width: 8%;
}

.products-grid col.products-col-cost,
.products-grid col.products-col-price {
    width: 6%;
}

.products-grid col.products-col-margin {
    width: 5%;
}

.products-grid col.products-col-days-without-sale {
    width: 4%;
}

.products-grid col.products-col-promotion {
    width: 5%;
}

.products-grid col.products-col-stock {
    width: 4.5%;
}

.products-grid col.products-col-stock-fiscal,
.products-grid col.products-col-stock-third-party {
    width: 4.5%;
}

.products-photo-cell {
    text-align: center;
}

.products-photo-indicator {
    position: relative;
    display: inline-flex;
    width: 18px;
    height: 18px;
    padding: 0;
    align-items: center;
    justify-content: center;
    border: 1px solid #b8c9c0;
    border-radius: 4px;
    background: #eef7f3;
    color: #1e6b52;
    font-family: Tahoma, Arial, sans-serif;
    line-height: 1;
    cursor: default;
}

.products-photo-indicator::before {
    content: "";
    width: 11px;
    height: 8px;
    border: 1px solid currentColor;
    border-radius: 2px;
    background: #ffffff;
}

.products-photo-indicator::after {
    content: "";
    position: absolute;
    top: 5px;
    right: 5px;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: currentColor;
}

.products-photo-preview-popover {
    position: fixed;
    z-index: 9999;
    width: 220px;
    height: 220px;
    padding: 8px;
    border: 1px solid #b8c9c0;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 14px 30px rgba(18, 36, 28, 0.18);
}

.products-photo-preview-popover img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.products-tax-linked-grid-wrap {
    min-height: 260px;
    height: clamp(260px, calc(100vh - 360px), 430px);
}

.products-grid.products-tax-linked-grid {
    min-width: 0;
    table-layout: fixed;
}

.products-grid.products-tax-linked-grid col.products-tax-linked-col-code {
    width: 74px;
}

.products-grid.products-tax-linked-grid col.products-tax-linked-col-barcode {
    width: 126px;
}

.products-grid.products-tax-linked-grid col.products-tax-linked-col-name {
    width: auto;
}

.products-grid.products-tax-linked-grid col.products-tax-linked-col-unit {
    width: 44px;
}

.products-grid.products-tax-linked-grid col.products-tax-linked-col-money {
    width: 78px;
}

.products-grid.products-tax-linked-grid th,
.products-grid.products-tax-linked-grid td {
    height: auto;
    min-height: 24px;
    line-height: 1.2;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
}

.products-grid.products-tax-linked-grid td:nth-child(1),
.products-grid.products-tax-linked-grid td:nth-child(4),
.products-grid.products-tax-linked-grid td:nth-child(5),
.products-grid.products-tax-linked-grid td:nth-child(6) {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.products-grid.products-tax-linked-grid td:nth-child(2),
.products-grid.products-tax-linked-grid td:nth-child(3) {
    overflow-wrap: anywhere;
}

.products-grid.products-tax-linked-grid td:nth-child(5),
.products-grid.products-tax-linked-grid td:nth-child(6) {
    text-align: right;
}

.products-tax-linked-name span {
    display: block;
}

.products-grid.product-stock-history-grid {
    min-width: 100%;
    table-layout: fixed;
}

.purchase-xml-entry-overlay.product-stock-overlay {
    align-items: flex-start;
    padding-top: 12px;
}

.purchase-xml-entry-modal.product-stock-modal {
    align-self: flex-start;
    width: min(1120px, calc(100vw - 40px));
    max-height: min(520px, calc(100vh - 40px));
    height: auto;
    min-height: 0;
    padding: 8px;
}

.purchase-xml-entry-modal.product-stock-modal .purchase-xml-header-panel {
    margin-bottom: 6px;
}

.product-stock-history-panel {
    min-height: 0;
    padding: 10px;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.products-stock-history-dialog,
.products-stock-history-dialog * {
    font-family: Tahoma, Arial, sans-serif;
    font-weight: normal !important;
}

.products-stock-history-dialog .panel-head h2 {
    font-size: 16px;
    line-height: 1.2;
}

.products-stock-history-dialog .panel-head p,
.products-stock-history-dialog label,
.products-stock-history-dialog input,
.products-stock-history-dialog select,
.products-stock-history-dialog button,
.products-stock-history-dialog .button,
.products-stock-history-dialog th,
.products-stock-history-dialog td {
    font-size: 11px;
}

.product-stock-history-panel .panel-head {
    margin-bottom: 8px;
}

.product-stock-history-panel .panel-head h2 {
    margin-bottom: 2px;
}

.product-stock-filter {
    display: flex;
    align-items: end;
    flex-wrap: nowrap;
    gap: 6px;
    margin: 0 0 6px;
}

.product-stock-filter label {
    display: grid;
    gap: 2px;
    min-width: 150px;
}

.product-stock-filter .product-stock-filter-date {
    flex: 0 0 165px;
    min-width: 0;
}

.product-stock-filter .product-stock-filter-type {
    flex: 0 0 165px;
    min-width: 0;
}

.product-stock-filter .product-stock-filter-company {
    flex: 1 1 auto;
    min-width: 220px;
}

.product-stock-filter input,
.product-stock-filter select {
    width: 100%;
}

.product-stock-filter input {
    min-height: 30px;
}

.product-stock-history-wrap {
    min-height: 0;
    height: auto;
    flex: 1 1 auto;
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.product-stock-history-wrap .product-stock-history-grid {
    width: 100%;
    min-width: 1680px;
}

.products-grid tbody tr.product-stock-fiscal-opening-row {
    background: #fff8e6;
    color: #7a4a10;
}

.products-grid tbody tr.product-stock-fiscal-opening-row:hover {
    background: #fff1cc;
}

.product-stock-action-bar {
    margin-top: 8px;
    flex: 0 0 auto;
}

@media (max-width: 900px) {
    .product-stock-filter {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .product-stock-filter .product-stock-filter-company {
        grid-column: 1 / -1;
        min-width: 0;
    }
}

.product-stock-history-grid col.product-stock-history-col-date {
    width: 13%;
}

.product-stock-history-grid col.product-stock-history-col-type {
    width: 8%;
}

.product-stock-history-grid col.product-stock-history-col-qty,
.product-stock-history-grid col.product-stock-history-col-balance {
    width: 9%;
}

.product-stock-history-grid col.product-stock-history-col-reference {
    width: 13%;
}

.product-stock-history-grid col.product-stock-history-col-notes {
    width: 24%;
}

.product-stock-history-grid col.product-stock-history-col-supplier,
.product-stock-history-grid col.product-stock-history-col-company {
    width: 18%;
}

.product-stock-history-grid th,
.product-stock-history-grid td {
    padding: 4px 6px;
    font-size: 11px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.products-price-cell {
    white-space: nowrap;
}

.products-price-cell[data-products-inline-price-cell] {
    cursor: text;
}

.products-inline-price-input {
    width: 100%;
    min-width: 72px;
    height: 24px;
    padding: 2px 6px;
    border: 1px solid #e07a32;
    border-radius: 4px;
    background: #fffaf4;
    color: #18242d;
    font: 400 11px Tahoma, sans-serif;
    text-align: right;
    outline: none;
    box-shadow: 0 0 0 2px rgba(224, 122, 50, 0.14);
}

.products-inline-price-input:focus {
    border-color: #c85f16;
    box-shadow: 0 0 0 2px rgba(224, 122, 50, 0.24);
}

.products-grid tbody tr.has-bulk-price-change td {
    background: #fff8e8;
}

.products-grid tbody tr.has-bulk-price-change td:first-child {
    box-shadow: inset 3px 0 0 #e07a32;
}

.products-bulk-price-actions {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-left: auto;
}

.products-bulk-price-actions[hidden] {
    display: none;
}

.products-bulk-price-actions .button {
    font-family: Tahoma, sans-serif;
    font-weight: 400;
}

.products-bulk-price-actions .product-selection-note {
    min-width: 130px;
    color: #8a4819;
}

.products-price-arrow {
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: 4px;
    flex: 0 0 auto;
    vertical-align: middle;
}

.products-price-arrow.is-up {
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-bottom: 8px solid #cf3f35;
}

.products-price-arrow.is-down {
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 8px solid #1f9d67;
}

.products-margin-risk-dot {
    display: inline-block;
    width: 9px;
    height: 9px;
    margin-left: 4px;
    padding: 0;
    border: 1px solid rgba(20, 32, 45, 0.18);
    border-radius: 999px;
    vertical-align: middle;
    cursor: pointer;
}

.products-margin-risk-dot.is-safe {
    background: #19a463;
}

.products-margin-risk-dot.is-warning {
    background: #f0b429;
}

.products-margin-risk-dot.is-danger {
    background: #d9343a;
}

.products-margin-risk-popover {
    position: fixed;
    z-index: 300;
    width: min(330px, calc(100vw - 24px));
    max-height: min(420px, calc(100vh - 24px));
    overflow: auto;
    padding: 10px 12px;
    border: 1px solid #cfdfe9;
    border-radius: 6px;
    background: #fff;
    color: var(--text);
    box-shadow: 0 18px 48px rgba(18, 33, 48, 0.2);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.45;
    white-space: pre-line;
}

.products-grid col.customers-col-name {
    width: 18%;
}

.products-grid col.customers-col-fantasy {
    width: 11%;
}

.products-grid col.customers-col-document {
    width: 10%;
}

.products-grid col.customers-col-type {
    width: 8%;
}

.products-grid col.customers-col-ie {
    width: 8%;
}

.products-grid col.customers-col-company {
    width: 14%;
}

.products-grid col.customers-col-city {
    width: 10%;
}

.products-grid col.customers-col-email {
    width: 14%;
}

.products-grid col.customers-col-status {
    width: 7%;
}

.customers-grid tbody tr.is-inactive td {
    background: #fff1e8;
    color: #7b3e16;
}

.customers-grid tbody tr.is-inactive.is-selected td {
    background: #ffe1cf;
}

.products-grid tbody tr[data-product-row],
.products-grid tbody tr[data-customer-row],
.products-grid tbody tr[data-service-row] {
    cursor: pointer;
}

.products-grid tbody tr:hover {
    background: #eef7f8;
}

.products-grid tbody tr:focus {
    outline: 2px solid rgba(18, 172, 160, 0.35);
    outline-offset: -2px;
}

.products-grid tbody tr.is-selected {
    background: #dff5f2;
    box-shadow: inset 3px 0 0 var(--primary);
}

.products-grid tbody tr.is-selected:hover {
    background: #d4f0ec;
}

.products-grid tbody tr.is-marked {
    background: #fff4d4;
    box-shadow: inset 3px 0 0 #e07a32;
}

.products-grid tbody tr.is-selected.is-marked {
    background: #e7f3de;
}

.products-grid tbody tr.is-inactive {
    background: #f3f5f7;
    color: #78848d;
}

.products-grid tbody tr.is-inactive:hover {
    background: #edf1f4;
}

@media (max-width: 1024px) {
    .products-toolbar {
        grid-template-columns: repeat(6, minmax(72px, 1fr));
        gap: 5px;
    }

    .products-toolbar-search,
    .products-toolbar-code,
    .products-toolbar-group,
    .products-toolbar-store {
        grid-column: span 3;
    }

    .products-filter-submit,
    .products-filter-clear {
        grid-column: span 2;
    }

    .products-toolbar label {
        font-size: 9.5px;
    }

    .products-toolbar input,
    .products-toolbar select,
    .products-toolbar .button {
        min-height: 28px;
        font-size: 11px;
    }

    .products-main-grid {
        min-width: 860px;
    }

    .products-main-grid col.products-col-ncm,
    .products-main-grid col.products-col-tax,
    .products-main-grid col.products-col-supplier,
    .products-main-grid th:nth-child(15),
    .products-main-grid td:nth-child(15),
    .products-main-grid th:nth-child(16),
    .products-main-grid td:nth-child(16),
    .products-main-grid th:nth-child(17),
    .products-main-grid td:nth-child(17) {
        display: none;
        visibility: collapse;
    }

    .products-main-grid col.products-col-name {
        width: 30%;
    }

    .products-main-grid col.products-col-group {
        width: 9%;
    }

    .products-main-grid col.products-col-barcode {
        width: 13%;
    }
}

@media (max-width: 640px) {
    .products-toolbar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-width: 100%;
        overflow: hidden;
    }

    .products-toolbar-search,
    .products-toolbar-code,
    .products-toolbar-group,
    .products-toolbar-ncm,
    .products-toolbar-ncm-status,
    .products-toolbar-tax,
    .products-toolbar-store {
        grid-column: 1 / -1;
    }

    .products-toolbar-tiny,
    .products-toolbar-limit,
    .products-filter-submit,
    .products-filter-clear {
        grid-column: span 1;
    }

    .products-toolbar input,
    .products-toolbar select,
    .products-toolbar .button {
        width: 100%;
        min-width: 0;
    }

    .products-grid-wrap {
        max-width: 100%;
        overflow: auto;
    }

    .products-main-grid {
        min-width: 1120px;
        table-layout: fixed;
    }

    .products-main-grid col.products-col-name {
        width: min(360px, calc(100vw - 142px));
    }

    .products-main-grid col.products-col-price {
        width: 86px;
    }

    .products-main-grid th,
    .products-main-grid td {
        padding: 5px 6px;
        white-space: nowrap;
    }

    .products-main-grid th:nth-child(8),
    .products-main-grid td:nth-child(8) {
        position: sticky;
        right: 0;
        z-index: 3;
        background: #fffefa;
        box-shadow: -2px 0 0 #d8e4ee;
    }

    .products-main-grid td:nth-child(8) {
        font-size: 10px;
    }

    .products-main-grid thead th:nth-child(8) {
        z-index: 4;
    }

    .products-main-grid tbody tr:hover td:nth-child(8) {
        background: #eef7f8;
    }

    .products-main-grid tbody tr.is-selected td:nth-child(8) {
        background: #dff5f2;
    }

    .product-action-bar {
        max-width: 100%;
        overflow: hidden;
    }

    .product-action-bar .button {
        flex: 1 1 108px;
        min-width: 0;
    }
}

.products-grid td.is-negative {
    color: #b42318;
    font-weight: 800;
}

.products-grid small {
    margin-top: 2px;
    color: var(--muted);
    font-size: 10px;
}

.pdvoff-devices-panel,
.pdvoff-devices-panel label,
.pdvoff-devices-panel input,
.pdvoff-devices-panel select,
.pdvoff-devices-panel button,
.pdvoff-devices-panel .button,
.pdvoff-devices-panel th,
.pdvoff-devices-panel td,
.pdvoff-devices-panel legend {
    font-weight: 400;
}

.pdvoff-devices-grid-wrap {
    height: clamp(300px, calc(100vh - 310px), 620px);
}

.pdvoff-devices-filter {
    display: flex;
    align-items: end;
    gap: 8px;
    margin: 8px 0;
}

.pdvoff-devices-filter label {
    width: 180px;
}

.pdvoff-devices-filter .pdvoff-devices-company-filter {
    width: min(360px, 40vw);
}

.products-grid.pdvoff-devices-grid {
    min-width: 1280px;
    font-size: 11px;
}

.pdvoff-devices-grid th,
.pdvoff-devices-grid td {
    height: 23px;
    padding: 2px 4px;
}

.pdvoff-sort-button {
    display: inline-flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: inherit;
    text-align: left;
    cursor: pointer;
}

.pdvoff-sort-button:hover,
.pdvoff-sort-button:focus-visible,
.pdvoff-sort-button.is-active {
    color: #c85c12;
    outline: none;
}

.pdvoff-devices-grid tbody tr.is-pending-activation td {
    background: #fff4de;
    border-bottom-color: #f2c36e;
}

.pdvoff-devices-grid tbody tr.is-pending-activation td:first-child {
    box-shadow: inset 4px 0 0 #e77817;
}

.pdvoff-approval-required {
    border: 1px solid #db6b0b;
    background: #fff0d4;
    color: #92400e;
}

.pdvoff-devices-grid .pdvoff-col-alias {
    width: 9%;
}

.pdvoff-devices-grid .pdvoff-col-company {
    width: 14%;
}

.pdvoff-devices-grid .pdvoff-col-device {
    width: 11%;
}

.pdvoff-devices-grid .pdvoff-col-type {
    width: 8%;
}

.pdvoff-devices-grid .pdvoff-col-activation {
    width: 8%;
}

.pdvoff-devices-grid .pdvoff-col-version {
    width: 6%;
}

.pdvoff-devices-grid .pdvoff-col-signal,
.pdvoff-devices-grid .pdvoff-col-online {
    width: 8%;
}

.pdvoff-devices-grid .pdvoff-col-nfce {
    width: 9%;
}

.pdvoff-devices-grid .pdvoff-col-sync {
    width: 11%;
}

.pdvoff-devices-grid .pdvoff-col-events {
    width: 8%;
}

.pdvoff-cell-note {
    display: block;
    color: var(--muted);
    font-size: 10.5px;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdvoff-activation-code {
    color: #0f172a;
    font-weight: 400;
    letter-spacing: 0;
}

.pdvoff-duplicate-note {
    display: inline-block;
    margin-top: 2px;
    padding: 1px 5px;
    border: 1px solid #f3b36d;
    border-radius: 4px;
    background: #fff3e5;
    color: #9a4f06;
    font-size: 10px;
    line-height: 1.2;
}

.pdvoff-devices-grid tbody tr {
    cursor: pointer;
}

.pdvoff-devices-grid tbody tr:focus td,
.pdvoff-devices-grid tbody tr.is-selected td {
    background: #e8f3ff;
    outline: none;
}

.pdvoff-devices-grid tbody tr.is-selected td:first-child {
    box-shadow: inset 3px 0 0 #2563eb;
}

.pdvoff-modal-holder {
    width: 0;
    max-width: 0;
    padding: 0 !important;
    border: 0 !important;
    overflow: visible !important;
}

.pdvoff-action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 36px;
    padding: 6px 0 0;
}

.pdvoff-action-status {
    color: var(--muted);
    font-size: 11.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdvoff-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1190;
    background: rgba(31, 36, 48, 0.45);
}

.pdvoff-modal-backdrop[hidden],
.pdvoff-modal[hidden] {
    display: none !important;
}

.pdvoff-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: grid;
    place-items: center;
    padding: 14px;
    white-space: normal;
    text-overflow: clip;
}

.pdvoff-modal-card {
    width: min(980px, calc(100vw - 28px));
    max-height: calc(100vh - 28px);
    display: grid;
    grid-template-rows: auto 1fr auto;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
    overflow: hidden;
    font-size: 11.5px;
    white-space: normal;
}

.pdvoff-modal-head,
.pdvoff-modal-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 10px;
    background: #f4f8fb;
    border-bottom: 1px solid var(--line);
}

.pdvoff-modal-actions {
    justify-content: flex-end;
    border-top: 1px solid var(--line);
    border-bottom: 0;
}

.pdvoff-modal-head h2 {
    margin: 0;
    font-size: 15px;
    font-weight: 400;
}

.pdvoff-modal-head p {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 11px;
}

.pdvoff-modal-body {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 8px;
    overflow: auto;
}

.pdvoff-modal-body fieldset {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px 7px;
    margin: 0;
    padding: 7px;
    border: 1px solid #d8e4ec;
    border-radius: 6px;
}

.pdvoff-modal-body legend {
    padding: 0 4px;
    color: var(--muted);
    font-size: 10.5px;
}

.pdvoff-modal-body label {
    display: grid;
    gap: 2px;
    min-width: 0;
    color: #334155;
    font-size: 10.5px;
}

.pdvoff-modal-body input,
.pdvoff-modal-body select {
    width: 100%;
    height: 25px;
    min-width: 0;
    padding: 2px 5px;
    border: 1px solid #cbd9e3;
    border-radius: 4px;
    font: 400 11.5px Tahoma, Arial, sans-serif;
}

.pdvoff-modal-body input[readonly] {
    background: #f4f8fb;
    color: #64748b;
}

.pdvoff-modal-body .pdvoff-activation-code-input {
    color: #0f172a;
    font-weight: 400;
    text-align: center;
}

.pdvoff-modal-body .pdvoff-check-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pdvoff-check {
    display: flex !important;
    grid-template-columns: none !important;
    align-items: center;
    gap: 5px;
    min-height: 24px;
}

.pdvoff-check input {
    width: 14px;
    height: 14px;
}

@media (max-width: 900px) {
    .pdvoff-modal-body {
        grid-template-columns: 1fr;
    }

    .pdvoff-modal-body fieldset {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.product-kit-badge {
    display: inline-block;
    margin-left: 5px;
    padding: 1px 4px;
    border: 1px solid #b7d6cc;
    border-radius: 5px;
    background: #e9f7f1;
    color: #176b4d;
    font-size: 9px;
    font-weight: 800;
}

.product-action-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
    padding: 8px;
    border: 1px solid var(--primary);
    border-radius: 8px;
    background: #f8fbfd;
}

.product-action-bar form {
    display: contents;
}

.product-action-bar .button {
    min-height: 30px;
    padding: 6px 10px;
    font-size: 12px;
    line-height: 1.1;
}

.sellers-page {
    min-height: calc(100vh - 168px);
}

.sellers-page .products-toolbar {
    grid-template-columns: repeat(8, minmax(90px, 1fr));
}

.sellers-page .products-toolbar label,
.sellers-page .products-toolbar input,
.sellers-page .products-toolbar select,
.sellers-page .products-toolbar .button,
.sellers-page .product-action-bar .button {
    font-weight: 400;
}

.sellers-toolbar .products-toolbar-search {
    grid-column: span 3;
}

.sellers-grid-wrap {
    height: clamp(340px, calc(100vh - 300px), 610px);
}

.sellers-grid {
    min-width: 980px;
}

.sellers-grid col.sellers-col-code {
    width: 9%;
}

.sellers-grid col.sellers-col-name {
    width: 30%;
}

.sellers-grid col.sellers-col-cpf {
    width: 14%;
}

.sellers-grid col.sellers-col-contact {
    width: 27%;
}

.sellers-grid col.sellers-col-status {
    width: 9%;
}

.sellers-grid col.sellers-col-movement {
    width: 11%;
}

.sellers-grid tr.is-selected td {
    background: #dff3ef;
}

.sellers-grid tr.is-inactive {
    color: #7d8b96;
}

.sellers-dialog .tax-profile-dialog-body {
    max-width: 900px;
}

.sellers-form-grid {
    grid-template-columns: 92px minmax(260px, 1fr) 170px 150px 210px 170px 130px;
}

.nfse-dashboard-panel {
    min-height: calc(100vh - 178px);
}

.nfse-dashboard-panel .filter-grid {
    margin-bottom: 8px;
}

.nfse-filter-grid {
    grid-template-columns: minmax(170px, 1.25fr) minmax(110px, .75fr) minmax(170px, 1.15fr) minmax(120px, .75fr) minmax(120px, .75fr) 96px;
    gap: 7px;
}

.nfse-filter-actions {
    align-self: end;
}

.nfse-filter-actions .button {
    width: 100%;
    min-height: 34px;
    justify-content: center;
}

.nfse-grid-wrap {
    min-height: 270px;
    height: clamp(300px, calc(100vh - 430px), 520px);
    margin-top: 4px;
}

.nfse-grid {
    width: 100%;
    min-width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    font-size: 10.5px;
}

.nfse-grid th,
.nfse-grid td {
    height: 25px;
    padding: 3px 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nfse-grid thead th {
    position: sticky;
    top: 0;
    z-index: 2;
}

.nfse-grid col.grid-col-date {
    width: 14%;
}

.nfse-grid col.grid-col-number {
    width: 8%;
}

.nfse-grid col.grid-col-emitter {
    width: 13%;
}

.nfse-grid col.grid-col-customer {
    width: 28%;
}

.nfse-grid col.grid-col-service {
    width: 18%;
}

.nfse-grid col.grid-col-status {
    width: 9%;
}

.nfse-grid col.grid-col-value {
    width: 10%;
}

.nfse-dashboard-panel .vfp-grid .invoice-row {
    cursor: pointer;
}

.nfse-dashboard-panel .vfp-grid .invoice-row.is-selected,
.nfse-dashboard-panel .vfp-grid .invoice-row.is-selected:hover,
.nfse-dashboard-panel .vfp-grid .invoice-row.is-selected:focus {
    background: #c6f0ea;
    box-shadow: inset 4px 0 0 var(--primary);
}

.nfse-dashboard-panel .vfp-grid .invoice-row.is-selected > td {
    background: #c6f0ea;
    border-top: 1px solid #77cfc4;
    border-bottom: 1px solid #77cfc4;
    color: #062f34;
    font-weight: 700;
}

.nfse-dashboard-panel .vfp-grid .invoice-row.is-selected > td:first-child {
    border-left: 4px solid var(--primary);
}

.nfse-action-bar {
    min-height: 48px;
    align-content: flex-start;
}

.nfse-frame-dialog {
    width: min(1180px, calc(100vw - 48px));
    max-width: 1180px;
    border: 0;
    padding: 0;
    background: transparent;
}

.nfse-frame-dialog::backdrop {
    background: rgba(8, 22, 30, .42);
}

.nfse-frame-dialog-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #f8fbfd;
    box-shadow: 0 18px 45px rgba(15, 39, 55, .24);
}

.nfse-frame-content {
    width: 100%;
    height: min(74vh, 720px);
    overflow: auto;
    border: 1px solid #cfe0ea;
    border-radius: 8px;
    background: #fff;
}

.nfse-frame-content .panel {
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

@media (max-width: 1100px) {
    .nfse-filter-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .nfse-grid {
        min-width: 900px;
    }
}

@media (max-width: 720px) {
    .nfse-filter-grid {
        grid-template-columns: 1fr;
    }

    .nfse-frame-dialog {
        width: calc(100vw - 18px);
    }

    .nfse-frame-content {
        height: 78vh;
    }
}

.product-selection-note {
    margin-left: auto;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.services-dashboard-panel {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 170px);
}

.services-grid-wrap {
    height: clamp(280px, calc(100vh - 300px), 560px);
}

.services-grid {
    min-width: 980px;
}

.services-grid col.services-col-name {
    width: 26%;
}

.services-grid col.services-col-company {
    width: 25%;
}

.services-grid col.services-col-national,
.services-grid col.services-col-municipal {
    width: 15%;
}

.services-grid col.services-col-rate,
.services-grid col.services-col-value {
    width: 9.5%;
}

.products-tax-dialog {
    width: min(1180px, calc(100vw - 32px));
}

.products-tax-dialog-body {
    max-height: calc(100vh - 44px);
    overflow: hidden;
}

.products-kit-dialog {
    width: min(1120px, calc(100vw - 32px));
}

.products-kit-form {
    max-height: calc(100vh - 44px);
    overflow: hidden;
}

.products-kit-head {
    margin-bottom: 6px;
}

.products-kit-layout {
    display: block;
    min-height: 0;
}

.products-kit-main {
    min-height: 0;
}

.products-kit-options,
.products-kit-entry,
.products-kit-picker-bar {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 6px;
}

.products-kit-entry {
    grid-template-columns: 120px 104px minmax(190px, 1fr) 96px 120px 106px;
    align-items: end;
}

.products-kit-entry-description {
    min-width: 0;
}

.products-kit-summary {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 6px;
}

.products-kit-summary span {
    min-width: 0;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f8fbfd;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.products-kit-summary strong {
    display: block;
    margin-top: 2px;
    color: var(--text);
    font-size: 12px;
}

.products-kit-picker-bar {
    grid-template-columns: minmax(0, 1fr) 120px;
}

.products-kit-search-dialog {
    width: min(980px, calc(100vw - 32px));
}

.products-kit-search-body {
    max-height: calc(100vh - 44px);
    overflow: hidden;
}

.products-kit-picker-wrap {
    height: min(390px, calc(100vh - 250px));
    min-height: 240px;
}

.products-kit-picker-grid {
    min-width: 760px;
}

.products-kit-components-wrap {
    height: min(330px, calc(100vh - 390px));
    min-height: 210px;
}

.products-kit-components-grid {
    min-width: 760px;
}

.products-kit-components-grid td,
.products-kit-components-grid th {
    padding-top: 4px;
    padding-bottom: 4px;
}

.products-kit-qty {
    width: 86px;
    min-height: 26px;
    padding: 3px 5px;
}

.products-product-form .is-invalid {
    border-color: #e46f2f;
    box-shadow: 0 0 0 2px rgba(228, 111, 47, 0.16);
}

.products-tax-head {
    margin-bottom: 0;
}

.products-tax-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f8fbfd;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.products-tax-grid-wrap {
    min-height: 300px;
    height: min(480px, calc(100vh - 260px));
}

.products-tax-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
    min-height: 300px;
}

.products-tax-pane {
    min-width: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
}

.products-tax-pane-title {
    color: #334155;
    font-size: 11px;
    font-weight: 700;
    margin: 0 0 5px;
    text-transform: uppercase;
}

.products-tax-grid {
    min-width: 930px;
}

.products-tax-grid-compact {
    min-width: 0;
}

.products-tax-grid-compact th,
.products-tax-grid-compact td {
    font-size: 11px;
    padding: 4px 6px;
}

.products-tax-grid-compact td,
.products-tax-grid-compact td strong {
    font-weight: 400;
}

.products-tax-grid col.products-tax-col-name {
    width: 26%;
}

.products-tax-grid col.products-tax-col-icms,
.products-tax-grid col.products-tax-col-cfop,
.products-tax-grid col.products-tax-col-piscofins,
.products-tax-grid col.products-tax-col-rates {
    width: 16%;
}

.products-tax-grid col.products-tax-col-status {
    width: 10%;
}

.products-tax-grid tbody tr[data-products-tax-row] {
    cursor: pointer;
}

.products-tax-grid td small {
    display: block;
    color: var(--muted);
    font-size: 9.5px;
    font-weight: 400;
}

.products-tax-action-bar {
    margin-top: 0;
}

.products-tax-pane-action-bar {
    border-color: transparent;
    border-radius: 0;
    margin-top: 8px;
    padding: 8px 0 0;
}

.products-tax-pane-action-bar .button {
    font-weight: 400;
}

.products-change-tax-dialog,
.products-change-ncm-dialog {
    width: min(760px, calc(100vw - 28px));
}

.products-change-tax-form,
.products-change-ncm-form {
    display: grid;
    gap: 10px;
    padding: 14px;
}

.products-change-tax-inline,
.products-change-ncm-inline {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 8px;
}

.products-change-tax-inline label,
.products-change-ncm-inline label {
    display: grid;
    gap: 3px;
    font-size: 11px;
    font-weight: 800;
}

.products-change-tax-inline select,
.products-change-ncm-inline input {
    min-height: 32px;
}

.products-change-tax-inline small,
.products-change-ncm-inline small {
    color: var(--muted);
    font-size: 10px;
}

.products-change-ncm-warning {
    margin: 0;
    color: #9a4d10;
    font-size: 11px;
    line-height: 1.35;
}

.products-batches-dialog {
    width: min(980px, calc(100vw - 28px));
}

.products-batches-body {
    max-height: calc(100vh - 44px);
    overflow: hidden;
}

.products-batches-grid-wrap {
    height: min(390px, calc(100vh - 250px));
    min-height: 220px;
    overflow-x: hidden;
}

.products-grid.products-batches-grid {
    min-width: 0;
}

.products-batches-grid th,
.products-batches-grid td {
    padding: 3px 5px;
}

.products-batches-grid col.products-batch-col-id {
    width: 8%;
}

.products-batches-grid col.products-batch-col-target {
    width: 30%;
}

.products-batches-grid col.products-batch-col-count {
    width: 9%;
}

.products-batches-grid col.products-batch-col-user {
    width: 23%;
}

.products-batches-grid col.products-batch-col-date {
    width: 18%;
}

.products-batches-grid col.products-batch-col-status {
    width: 12%;
}

.products-batches-grid small {
    display: inline;
    margin-left: 4px;
}

.products-undo-confirm-dialog {
    width: min(520px, calc(100vw - 28px));
}

.products-undo-confirm-body {
    display: grid;
    gap: 10px;
    padding: 14px;
}

.products-undo-warning {
    padding: 10px 12px;
    border: 1px solid #efb17a;
    border-radius: 8px;
    background: #fff4e8;
    color: #8d420c;
    font-size: 12px;
    line-height: 1.35;
}

.products-undo-check {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 10px;
    border: 1px solid #d6e3ec;
    border-radius: 8px;
    background: #f7fbfd;
    color: var(--text);
    font-size: 12px;
    font-weight: 700;
}

.products-undo-check input {
    width: auto;
    margin-top: 2px;
}

.products-price-history-modal {
    align-self: flex-start;
    width: min(1220px, calc(100vw - 40px));
    max-height: min(540px, calc(100vh - 32px));
    height: auto;
    min-height: 0;
    padding: 8px;
}

.products-price-history-overlay {
    align-items: flex-start;
    padding-top: 12px;
}

.products-price-history-modal .purchase-xml-header-panel {
    margin-bottom: 6px;
}

.products-price-history-panel {
    min-height: 0;
}

.products-price-history-panel .panel-head {
    margin-bottom: 8px;
}

.products-price-history-grid-wrap {
    min-height: 148px;
    height: min(236px, calc(100vh - 278px));
    overflow-x: hidden;
}

.products-grid.products-price-history-grid {
    min-width: 0;
    font-size: 10px;
}

.products-price-history-grid th,
.products-price-history-grid td {
    padding: 3px 4px;
    height: 24px;
}

.products-price-history-grid col.products-price-history-col-date {
    width: 10%;
}

.products-price-history-grid col.products-price-history-col-type {
    width: 9%;
}

.products-price-history-grid col.products-price-history-col-money {
    width: 8%;
}

.products-price-history-grid col.products-price-history-col-move {
    width: 7%;
}

.products-price-history-grid col.products-price-history-col-reference {
    width: 17%;
}

.products-price-history-grid col.products-price-history-col-origin {
    width: 14%;
}

.products-price-history-grid col.products-price-history-col-user {
    width: 12%;
}

.products-price-history-grid col.products-price-history-col-status {
    width: 15%;
}

.products-price-history-status {
    height: auto;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    line-height: 1.25;
}

.products-price-history-status small {
    display: block;
    margin-top: 1px;
}

.products-stock-documents-dialog {
    width: min(1240px, calc(100vw - 32px));
}

.products-price-matrix-dialog {
    width: min(1320px, calc(100vw - 24px));
    max-width: 98vw;
}

.products-price-matrix-body {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 85vh;
    padding: 8px;
    overflow: hidden;
}

.products-price-matrix-head {
    align-items: start;
    flex: 0 0 auto;
    padding-bottom: 2px;
}

.products-price-matrix-head h2 {
    font-size: 18px;
}

.products-price-matrix-head p {
    margin: 1px 0 0;
    max-width: min(980px, 76vw);
    overflow: hidden;
    color: #526779;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.products-price-matrix-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    flex: 1 1 auto;
    min-height: 260px;
    max-height: calc(85vh - 112px);
    overflow: hidden;
    border: 1px solid #cfdfe9;
    border-radius: 6px;
    background: #fff;
}

.products-price-matrix-fixed {
    display: grid;
    grid-template-columns: 0.65fr 2.3fr repeat(5, minmax(92px, 1fr));
    align-content: start;
    gap: 2px;
    padding: 5px;
    border-bottom: 1px solid #d7e5ee;
    background: #f7fafc;
}

.products-price-summary-item {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    padding: 4px;
    border-bottom: 1px solid #e4edf3;
}

.products-price-summary-item.is-wide {
    min-width: 0;
}

.products-price-summary-item span,
.products-price-cell span,
.products-price-margin-cell span {
    color: #526779;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.products-price-summary-item strong {
    min-width: 0;
    overflow: hidden;
    color: var(--text);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.products-price-matrix-stores {
    display: block;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding: 0;
    background: #fff;
}

.products-price-grid {
    width: auto;
    min-width: 1280px;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
}

.products-price-grid th,
.products-price-grid td {
    height: 27px;
    padding: 3px 4px;
    border-right: 1px solid #e4edf3;
    border-bottom: 1px solid #e4edf3;
    overflow: hidden;
    color: var(--text);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.products-price-grid th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #eef5fa;
    color: #16324b;
    font-weight: 700;
    text-align: left;
    text-transform: uppercase;
}

.products-price-grid tr.is-main-store td {
    background: #f7fbff;
}

.products-price-grid tr.is-changed td {
    background: #fff8ed;
}

.products-price-grid tr.is-selected td {
    background: #eaf4ff;
}

.products-price-grid tr.is-selected.is-changed td {
    background: #fff2dc;
}

.products-price-store-code {
    width: 30px;
    text-align: center;
}

.products-price-store-nick {
    width: 112px;
    font-weight: 700;
}

.products-price-store-name {
    width: 150px;
}

.products-price-store-type {
    width: 52px;
    text-align: center;
    font-weight: 700;
}

.products-price-grid tr.is-main-store .products-price-store-type {
    background: #dceeff;
    color: #125c9c;
}

.products-price-grid tr:not(.is-main-store) .products-price-store-type {
    background: #e5f8ee;
    color: #08703d;
}

.products-price-money-cell {
    width: 88px;
    text-align: right;
}

.products-price-money-cell input {
    width: 78px;
    height: 22px;
    padding: 2px 5px;
    border: 1px solid #cfdfe9;
    border-radius: 4px;
    background: #fff;
    font-size: 11px;
    font-weight: 700;
    text-align: right;
}

.products-price-money-cell input.is-changed {
    border-color: #e3a15f;
    background: #fff8ed;
}

.products-price-number-cell {
    width: 82px;
    text-align: right;
}

.products-price-number-cell input {
    width: 72px;
    height: 22px;
    padding: 2px 4px;
    border: 1px solid #cfdfe9;
    border-radius: 4px;
    background: #fff;
    font: 400 11px Tahoma, sans-serif;
    text-align: right;
}

.products-price-number-cell input.is-changed {
    border-color: #e3a15f;
    background: #fff8ed;
}

.product-stock-limits-stores-button {
    grid-column: span 2;
    align-self: end;
    width: 100%;
    min-width: 0;
    min-height: 26px;
    padding: 3px 7px;
    white-space: nowrap;
    font-family: Tahoma, sans-serif;
    font-weight: 400;
}

[data-products-price-matrix-replicate-all] {
    font-family: Tahoma, sans-serif;
    font-weight: 400;
}

.products-price-margin-cell {
    width: 68px;
    text-align: right;
}

.products-price-markup-cell {
    width: 68px;
    text-align: right;
}

.products-price-margin-cell strong {
    color: #16324b;
    font-size: 10px;
}

.products-price-markup-cell input {
    width: 62px;
    height: 22px;
    padding: 2px 5px;
    border: 1px solid #cfdfe9;
    border-radius: 4px;
    background: #fff;
    color: #16324b;
    font-size: 10px;
    text-align: right;
}

.products-price-markup-cell input:focus {
    border-color: #e97a2c;
    outline: 1px solid #e97a2c;
}

.products-price-markup-cell input.is-invalid {
    border-color: #b42318;
    background: #fff0ee;
}

.products-price-margin-cell .is-negative,
.products-price-markup-cell .is-negative,
.products-price-summary-item .is-negative {
    color: #b42318;
}

.products-price-matrix-actions {
    position: sticky;
    bottom: 0;
    flex: 0 0 auto;
    justify-content: flex-end;
    gap: 6px;
    margin-top: 0;
    padding-top: 6px;
    border-top: 1px solid #d7e5ee;
    background: #fff;
}

.products-price-matrix-actions .button {
    min-height: 30px;
    padding: 6px 9px;
    font-size: 11px;
}

@media (max-width: 760px) {
    .dashboard-overview-compact {
        position: static;
        box-shadow: none;
        backdrop-filter: none;
    }

    .products-price-matrix-fixed {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.stock-document-view-dialog {
    width: min(1180px, calc(100vw - 32px));
}

.products-stock-documents-body {
    max-height: calc(100vh - 44px);
    overflow: hidden;
}

.stock-document-view-body {
    display: grid;
    gap: 8px;
    overflow: auto;
}

.stock-document-view-body > .panel {
    margin: 0;
    box-shadow: none;
}

.stock-document-view-body .stock-documents-list-wrap {
    min-height: 180px;
    height: min(360px, calc(100vh - 310px));
}

.stock-document-view-panel {
    padding: 6px 10px;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.stock-document-view-head {
    margin-bottom: 5px;
}

.stock-document-view-route {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: flex-start;
    gap: 4px 20px;
    flex: 1 1 auto;
    min-width: 0;
    margin-left: auto;
    text-align: right;
}

.stock-document-view-party {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 3px 10px;
    min-width: 0;
}

.stock-document-view-party span {
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
    min-width: 0;
}

.stock-document-view-party em {
    color: #31526f;
    font-size: 10px;
    font-style: normal;
    font-weight: 800;
    text-transform: uppercase;
}

.stock-document-view-party em::after {
    content: ':';
}

.stock-document-view-party strong {
    min-width: 0;
    overflow: hidden;
    color: var(--text);
    font-size: 11px;
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.stock-document-view-head h2 {
    margin-bottom: 2px;
    font-size: 14px;
    line-height: 1.12;
}

.stock-document-view-head p {
    margin: 0;
    font-size: 10px;
    line-height: 1.2;
}

.stock-document-view-panel h1,
.stock-document-view-panel h2,
.stock-document-view-panel .panel-head h1,
.stock-document-view-panel .panel-head h2,
.stock-document-view-body > .panel h1,
.stock-document-view-body > .panel h2 {
    font-size: 14px;
    line-height: 1.12;
}

.stock-document-view-body > .panel .panel-head {
    margin-bottom: 5px;
}

.stock-document-view-body > .panel .panel-head p {
    display: none;
}

.stock-document-detail-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 3px 14px;
    align-items: center;
}

.stock-document-detail-item {
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
    min-width: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
}

.stock-document-detail-title {
    flex-basis: 100%;
}

.stock-document-detail-item em,
.stock-document-detail-item strong,
.stock-document-detail-item small {
    display: inline;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.stock-document-detail-item em {
    color: #31526f;
    font-size: 10px;
    font-style: normal;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

.stock-document-detail-item em::after {
    content: ':';
}

.stock-document-detail-item strong {
    color: var(--text);
    font-size: 11px;
    font-weight: 500;
}

.stock-document-detail-item small {
    color: #38536a;
    font-size: 9px;
    font-weight: 400;
    white-space: normal;
}

.stock-document-detail-item small::before {
    content: ' - ';
}

.stock-document-view-actions {
    margin-top: 0;
    border-color: var(--line);
}

.stock-document-view-status {
    margin-right: auto;
}

.stock-document-nfe-dialog .error-dialog-body {
    width: min(720px, calc(100vw - 48px));
    gap: 8px;
    padding: 12px;
}

.stock-document-nfe-dialog .stock-documents-list-wrap {
    height: auto;
    min-height: 0;
    max-height: min(260px, 46vh);
    overflow: auto;
}

.stock-document-nfe-dialog .panel-head {
    margin-bottom: 0;
}

.stock-document-nfe-dialog .panel-head h2 {
    font-size: 18px;
    line-height: 1.15;
}

.stock-document-nfe-dialog .error-dialog-message {
    padding: 8px 10px;
    font-size: 12px;
    line-height: 1.25;
}

.stock-document-nfe-grid-wrap {
    min-height: 0;
    overflow-x: hidden;
}

.stock-document-nfe-status-panel .panel-head p {
    max-width: 780px;
}

.stock-document-nfe-status-panel {
    padding-top: 7px;
    padding-bottom: 7px;
}

.stock-document-nfe-status-panel .stock-document-view-head h2 {
    font-size: 13px;
}

.stock-document-nfe-key strong {
    font-size: 9px;
    word-break: break-all;
}

.stock-document-nfe-rejected {
    border-color: #f3b3b3;
    background: #fff1f1;
    color: #8a1f1f;
}

.stock-document-nfe-rejection {
    display: grid;
    gap: 2px;
    margin-top: 6px;
    padding: 6px 8px;
    border: 1px solid #f3b3b3;
    border-radius: 5px;
    background: #fff7f7;
    color: #7f1d1d;
    font-size: 10px;
    line-height: 1.25;
}

.stock-document-nfe-rejection strong {
    text-transform: uppercase;
    font-size: 10px;
}

.stock-document-danfe-dialog {
    width: min(1220px, calc(100vw - 16px));
    max-width: none;
}

.stock-document-danfe-dialog .error-dialog-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    height: min(760px, calc(100vh - 48px));
    padding: 10px;
}

.stock-document-danfe-dialog iframe {
    width: 100%;
    min-height: 0;
    flex: 1 1 auto;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
}

.stock-document-nfe-grid {
    table-layout: fixed;
    min-width: 0;
    width: 100%;
}

.stock-document-nfe-grid col.stock-document-nfe-col-product {
    width: auto;
}

.stock-document-nfe-grid col.stock-document-nfe-col-qty {
    width: 46px;
}

.stock-document-nfe-grid col.stock-document-nfe-col-cost {
    width: 82px;
}

.stock-document-nfe-grid col.stock-document-nfe-col-price {
    width: 92px;
}

.stock-document-nfe-grid col.stock-document-nfe-col-total {
    width: 82px;
}

.stock-document-nfe-grid th,
.stock-document-nfe-grid td {
    box-sizing: border-box;
    padding: 2px 4px;
    height: 25px;
    font-size: 10px;
    line-height: 1.1;
}

.stock-document-nfe-grid td:nth-child(n + 2),
.stock-document-nfe-grid th:nth-child(n + 2) {
    text-align: right;
}

.stock-document-nfe-grid td:first-child strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 10px;
    font-weight: 600;
    line-height: 1.1;
}

.stock-document-nfe-grid td:first-child small {
    font-size: 8px;
    font-weight: 400;
    line-height: 1.05;
}

@media (max-width: 900px) {
    .stock-document-view-head {
        align-items: flex-start;
    }

    .stock-document-view-route,
    .stock-document-view-party {
        justify-content: flex-start;
        width: 100%;
        margin-left: 0;
        text-align: left;
    }

    .stock-document-detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .stock-document-detail-title {
        grid-column: 1 / -1;
    }
}

.stock-document-nfe-dialog input[data-stock-document-nfe-price] {
    width: 74px;
    max-width: 100%;
    min-height: 24px;
    padding: 2px 4px;
    border-radius: 5px;
    font-size: 10px;
    text-align: right;
}

.stock-document-nfe-dialog input[data-stock-document-nfe-price].is-invalid {
    border-color: #dc2626;
    background: #fff1f1;
    color: #991b1b;
}

.products-stock-documents-filter {
    margin-bottom: 0;
}

.products-stock-documents-grid-wrap {
    min-height: 320px;
    height: min(520px, calc(100vh - 300px));
}

.products-stock-documents-grid {
    min-width: 1040px;
}

.products-stock-documents-grid col.products-stock-doc-col-id {
    width: 4.5%;
}

.products-stock-documents-grid col.products-stock-doc-col-type {
    width: 11%;
}

.products-stock-documents-grid col.products-stock-doc-col-number {
    width: 7%;
}

.products-stock-documents-grid col.products-stock-doc-col-company {
    width: 13%;
}

.products-stock-documents-grid col.products-stock-doc-col-store {
    width: 15%;
}

.products-stock-documents-grid col.products-stock-doc-col-supplier {
    width: 20%;
}

.products-stock-documents-grid col.products-stock-doc-col-items,
.products-stock-documents-grid col.products-stock-doc-col-status,
.products-stock-documents-grid col.products-stock-doc-col-date {
    width: 10%;
}

.products-stock-documents-grid tbody tr[data-products-stock-document-row] {
    cursor: pointer;
}

.products-stock-documents-grid tbody tr[data-stock-document-status="draft"],
.products-stock-documents-grid tbody tr[data-stock-document-status="draft"]:hover,
.products-stock-documents-grid tbody tr[data-stock-document-status="draft"]:focus,
.products-stock-documents-grid tbody tr[data-stock-document-status="draft"].is-selected {
    background: #ffd6d6 !important;
    box-shadow: inset 5px 0 #b71c1c !important;
}

.products-stock-documents-grid tbody tr[data-stock-document-status="draft"] td {
    border-top-color: #e58b8b !important;
    border-bottom-color: #e58b8b !important;
}

.products-labels-dialog {
    width: min(1080px, calc(100vw - 40px));
}

.products-labels-dialog .products-labels-body {
    max-height: calc(100vh - 52px);
    overflow-y: auto;
}

.products-label-model-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    align-items: center;
    margin-bottom: 8px;
    color: #425466;
    font-size: 10.5px;
    line-height: 1.2;
}

.products-label-section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin: 8px 0 4px;
}

.products-label-section-title {
    margin: 0 0 4px;
    font-size: 14px;
    line-height: 1.1;
}

.products-label-section-head .products-label-section-title {
    margin: 0;
}

.products-label-section-head .small-button {
    min-height: 26px;
    padding: 4px 9px;
    font-size: 10px;
}

.products-label-queue-grid-wrap {
    min-height: 0;
    height: 118px;
    max-height: 118px;
}

.products-label-xml-grid-wrap {
    min-height: 0;
    height: 112px;
    max-height: 112px;
}

.products-label-queue-grid {
    min-width: 820px;
}

.products-labels-dialog .products-stock-documents-grid {
    min-width: 760px;
}

.products-labels-dialog .products-stock-documents-grid th,
.products-labels-dialog .products-stock-documents-grid td {
    padding: 3px 5px;
    font-size: 9.5px;
    line-height: 1.08;
}

.products-labels-dialog .products-stock-documents-grid td small {
    display: block;
    margin-top: 0;
    font-size: 8px;
    line-height: 1;
}

.products-stock-documents-grid th,
.products-stock-documents-grid td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.products-stock-documents-grid small {
    display: block;
    color: var(--muted);
    font-size: 9.5px;
    font-weight: 700;
}

.products-purchase-xml-grid {
    min-width: 1120px;
    table-layout: fixed;
    font-family: "Arial Narrow", "Roboto Condensed", Tahoma, sans-serif;
    font-size: 11.5px;
    letter-spacing: -0.2px;
}

.products-purchase-xml-grid th,
.products-purchase-xml-grid td {
    padding: 4px 5px;
    line-height: 1.08;
    font-size: 11.5px;
}

.products-purchase-xml-grid col.products-purchase-xml-col-number {
    width: 7%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-supplier {
    width: 22%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-store {
    width: 17%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-issue,
.products-purchase-xml-grid col.products-purchase-xml-col-entry {
    width: 8.5%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-operator {
    width: 13%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-total {
    width: 10%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-items {
    width: 5%;
}

.products-purchase-xml-grid col.products-purchase-xml-col-status {
    width: 9%;
}

.products-purchase-xml-grid td:nth-child(7) {
    text-align: left;
}

.products-purchase-xml-grid td strong {
    letter-spacing: -0.25px;
}

.products-purchase-xml-grid td small {
    font-size: 9px;
}

.products-purchase-xml-dfe-grid {
    min-width: 1040px;
    table-layout: fixed;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-select {
    width: 3%;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-issue {
    width: 11%;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-number {
    width: 10%;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-supplier {
    width: 30%;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-document {
    width: 16%;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-total,
.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-xml {
    width: 9%;
}

.products-purchase-xml-dfe-grid col.products-purchase-xml-dfe-col-entry {
    width: 12%;
}

.products-purchase-xml-dfe-grid th,
.products-purchase-xml-dfe-grid td {
    padding-right: 5px;
    padding-left: 5px;
}

.products-stock-documents-action-bar {
    margin-top: 0;
}

.product-action-bar .products-stock-zero-button {
    border-color: #f3c290;
    background: #fff7ed;
    color: #8a3a0b;
}

.product-action-bar .products-stock-zero-button:hover {
    border-color: #e57a31;
    background: #ffedd5;
}

.products-stock-zero-dialog {
    width: min(760px, calc(100vw - 32px));
}

.products-product-dialog {
    width: min(1180px, calc(100vw - 32px));
}

.products-product-form {
    max-height: calc(100vh - 24px);
    overflow: auto;
    padding: 9px 10px;
    font-family: Tahoma, Arial, sans-serif;
}

.products-product-form > .panel-head {
    margin-bottom: 1px;
}

.products-product-form > .panel-head h2 {
    margin: 0;
    font-size: 18px;
}

.products-product-form > .panel-head p {
    margin: 1px 0 0;
    font-size: 10px;
}

.products-ncm-hint {
    position: fixed;
    z-index: 10020;
    top: 112px;
    right: 28px;
    width: min(430px, calc(100vw - 32px));
    max-height: min(42vh, 320px);
    overflow: auto;
    box-sizing: border-box;
    padding: 28px 12px 11px;
    border: 1px solid #8fbdd5;
    border-radius: 9px;
    background: #f5fbff;
    color: #17384d;
    box-shadow: 0 10px 28px rgba(16, 45, 65, .24);
    font: normal 12px/1.45 Tahoma, Arial, sans-serif;
    cursor: grab;
    user-select: text;
    touch-action: none;
}
.products-ncm-hint::before {
    content: 'NCM oficial  ·  arraste para mover';
    position: absolute;
    inset: 0 0 auto;
    padding: 6px 10px;
    border-bottom: 1px solid #bad6e5;
    border-radius: 8px 8px 0 0;
    background: #dff1fa;
    color: #315c75;
    font: normal 10px Tahoma, Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: .02em;
}
.products-ncm-hint.is-dragging { cursor: grabbing; box-shadow: 0 14px 34px rgba(16,45,65,.32); }
.products-ncm-hint[data-status="invalid"],
.products-ncm-hint[data-status="expired"],
.products-ncm-hint[data-status="replaced"] { border-color:#df9a9a; background:#fff5f5; color:#8d2020; }

.products-product-form-alert {
    margin-top: 8px;
    padding: 8px 10px;
    border: 1px solid #fecaca;
    border-radius: 7px;
    background: #fff1f0;
    color: #a71922;
    font-size: 12px;
    font-weight: 800;
}

.products-product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px 10px;
    margin-top: 8px;
}

.products-product-form .products-product-grid {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 4px;
}

.products-product-form .product-form-section {
    display: grid;
    grid-template-columns: repeat(16, minmax(0, 1fr));
    grid-auto-flow: row dense;
    gap: 3px 6px;
    min-width: 0;
}

.products-product-form .product-form-section > h3 {
    grid-column: 1 / -1;
    margin: 0 0 1px;
    color: #38566b;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
}

.products-product-form .product-form-tax-section,
.products-product-form .product-form-price-section {
    padding: 5px 6px;
    border: 1px solid #d7e5ee;
    border-radius: 6px;
    background: #f8fbfd;
}

.products-product-form .product-form-section > label {
    grid-column: span 4;
    min-width: 0;
}

.products-product-form .product-form-description-section > .full {
    grid-column: 1 / -1;
    width: 100%;
}

.products-product-form .product-form-description-section > .full > input {
    width: 100%;
}

.products-product-form .product-form-section > .product-field-tiny { grid-column: span 2; }
.products-product-form .product-form-section > .product-field-small { grid-column: span 3; }
.products-product-form .product-form-section > .product-field-medium { grid-column: span 4; }
.products-product-form .product-form-section > .product-field-wide,
.products-product-form .product-form-section > .product-field-code { grid-column: span 4; }

.products-product-grid .full {
    grid-column: 1 / -1;
}

.products-product-grid label {
    display: grid;
    gap: 3px;
    color: var(--text);
    font-size: 11px;
    font-weight: 400;
}

.products-product-grid label.is-required {
    font-weight: 700;
}

.products-product-grid input,
.products-product-grid select,
.products-product-grid textarea {
    min-height: 30px;
    border: 1px solid #d6bda9;
    border-radius: 7px;
    background: #fffefc;
    color: var(--text);
    padding: 5px 7px;
    font: inherit;
    font-size: 12px;
}

.products-product-grid textarea {
    min-height: 56px;
    resize: vertical;
}

.products-product-grid .product-sku-row {
    grid-template-columns: minmax(0, 1fr) auto;
}

.products-product-grid .product-sku-row .button {
    min-height: 30px;
    padding: 5px 8px;
}

.product-benefit-code-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
}

.product-benefit-code-row .button {
    min-height: 30px;
    padding: 5px 8px;
}

.products-product-form .products-product-grid label { gap: 1px; }
.products-product-form .products-product-grid input,
.products-product-form .products-product-grid select,
.products-product-form .products-product-grid textarea {
    box-sizing: border-box;
    height: 26px;
    min-height: 26px;
    padding: 3px 6px;
}
.products-product-form .products-product-grid textarea {
    height: 58px;
    min-height: 58px;
}
.products-product-form .products-product-grid .product-sku-row .button,
.products-product-form .product-benefit-code-row .button {
    min-height: 26px;
    padding: 3px 7px;
}

@media (max-width: 900px) {
    .products-product-form .product-form-section {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .products-product-form .product-form-section > label,
    .products-product-form .product-form-section > .product-field-tiny,
    .products-product-form .product-form-section > .product-field-small,
    .products-product-form .product-form-section > .product-field-medium,
    .products-product-form .product-form-section > .product-field-wide,
    .products-product-form .product-form-section > .product-field-code {
        grid-column: span 1;
    }

    .products-product-form .product-form-section > .full {
        grid-column: 1 / -1;
    }
}

@media (max-width: 620px) {
    .products-product-form .product-form-section {
        grid-template-columns: minmax(0, 1fr);
    }
}

.product-benefit-profile-alert {
    color: #a15c00;
    font-size: 10px;
    line-height: 1.35;
}

.products-benefit-search-body {
    width: min(760px, calc(100vw - 32px));
    max-height: calc(100vh - 32px);
}

.products-benefit-search-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: end;
}

.products-benefit-experimental-notice {
    margin-bottom: 2px;
    padding: 7px 9px;
    border: 1px solid #e8c98d;
    border-radius: 8px;
    background: #fff8e8;
    color: #6f4d12;
    font-size: 12px;
    line-height: 1.4;
}

.products-benefit-experimental-notice strong {
    margin-right: 4px;
}

.products-benefit-search-row label {
    display: grid;
    gap: 4px;
    font-size: 11px;
}

.products-benefit-search-row input {
    min-height: 34px;
}

.products-benefit-search-grid {
    min-height: 76px;
    max-height: 180px;
    margin-top: 2px;
    overflow: auto;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.products-benefit-search-grid table {
    width: 100%;
    border-collapse: collapse;
}

.products-benefit-search-grid th,
.products-benefit-search-grid td {
    padding: 7px 8px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    font-size: 11px;
}

.products-benefit-search-grid th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f7f1eb;
    font-weight: 400;
}

.products-benefit-search-grid tbody tr:not(.empty) {
    cursor: pointer;
}

.products-benefit-search-grid tbody tr:hover td,
.products-benefit-search-grid tbody tr.is-selected td {
    background: #fff1e8;
}

.products-benefit-search-grid .empty {
    padding: 32px 8px;
    text-align: center;
    color: var(--muted);
}

.products-benefit-rule-detail {
    margin-top: 2px;
    padding: 9px 10px;
    border: 1px solid #dbe3ec;
    border-radius: 10px;
    background: #f8fafc;
    color: #334155;
}

.products-benefit-rule-detail p,
.products-benefit-rule-detail ul {
    margin: 6px 0;
    font-size: 12px;
}

.products-benefit-rule-detail ul {
    padding-left: 22px;
}

.products-benefit-rule-option {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    margin-top: 8px;
    justify-content: flex-start;
}

.products-benefit-rule-option input[type="radio"] {
    width: auto;
    min-width: 14px;
    margin: 2px 0 0;
    flex: 0 0 auto;
}

.products-benefit-rule-option span,
.products-benefit-rule-option small {
    display: block;
}

.products-benefit-rule-option small {
    margin-top: 2px;
    color: #64748b;
}

.products-product-grid .product-special-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px 10px;
}

.products-comanda-sector-body {
    box-sizing: border-box;
    width: min(920px, calc(100vw - 56px));
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.products-comanda-sector-top,
.products-comanda-sector-new,
.products-comanda-sector-products,
.products-comanda-sector-edit,
.products-comanda-sector-actions {
    display: flex;
    align-items: end;
    gap: 8px;
    flex-wrap: wrap;
}

.products-comanda-sector-top {
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.products-comanda-sector-new,
.products-comanda-sector-products {
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface-muted);
    margin-bottom: 10px;
}

.products-comanda-sector-new label,
.products-comanda-sector-products label,
.products-comanda-sector-top label {
    min-width: 240px;
    margin: 0;
}

.products-comanda-sector-grid {
    display: grid;
    gap: 8px;
    margin-bottom: 10px;
}

.products-comanda-sector-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.products-comanda-sector-edit {
    align-items: center;
}

.products-comanda-sector-edit input {
    min-width: min(320px, 100%);
}

.products-product-grid .is-required > input,
.products-product-grid .is-required > select,
.products-product-grid .is-required > textarea {
    border-color: #e07a32;
}

.products-nutrition-dialog {
    width: min(1080px, calc(100vw - 32px));
    max-width: calc(100vw - 32px);
    overflow-x: hidden;
}

.products-nutrition-dialog .products-nutrition-body {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    overflow-x: hidden;
}

.products-nutrition-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr);
    gap: 10px;
    min-height: 0;
    min-width: 0;
    max-width: 100%;
}

.products-nutrition-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(100px, 1fr));
    align-content: start;
    gap: 4px 6px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 2px;
}

.products-nutrition-grid label {
    display: grid;
    gap: 2px;
    min-width: 0;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 9px;
    font-weight: 400;
    color: var(--text);
}

.products-nutrition-grid label.is-required {
    font-weight: 700;
}

.products-nutrition-grid input,
.products-nutrition-grid select,
.products-nutrition-grid textarea {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    min-height: 25px;
    border: 1px solid #d6bda9;
    border-radius: 7px;
    background: #fffefc;
    color: var(--text);
    padding: 2px 5px;
    font: inherit;
    font-size: 10px;
    font-weight: 400;
}

.products-nutrition-grid .full {
    grid-column: 1 / -1;
}

.products-nutrition-check {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
}

.products-nutrition-check input {
    min-height: 0;
    width: 16px;
    height: 16px;
    padding: 0;
}

.products-nutrition-manual {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    gap: 6px;
    min-width: 0;
}

.products-nutrition-manual label {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 3px;
    min-width: 0;
    font: 400 10px Tahoma, Arial, sans-serif;
    color: var(--text);
}

.products-nutrition-manual textarea,
.products-nutrition-manual input {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    border: 1px solid #d6bda9;
    border-radius: 7px;
    background: #fffefc;
    color: var(--text);
    padding: 6px 7px;
    font-family: "Courier New", Consolas, monospace;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.3;
    font-variant-ligatures: none;
    tab-size: 4;
}

.products-nutrition-manual textarea {
    min-height: 100%;
    resize: none;
    overflow: auto;
    white-space: pre;
}

.products-nutrition-manual input {
    min-height: 27px;
    font-size: 10px;
}

@media (max-width: 820px) {
    .products-nutrition-layout {
        grid-template-columns: 1fr;
    }

    .products-nutrition-manual textarea {
        min-height: 190px;
    }
}

.products-promotion-dialog {
    width: min(760px, calc(100vw - 32px));
}

.products-promotion-form {
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.products-promotion-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px 10px;
    margin-top: 8px;
}

.products-promotion-grid .full {
    grid-column: 1 / -1;
}

.products-promotion-grid label {
    display: grid;
    gap: 3px;
    color: var(--text);
    font-size: 11px;
    font-weight: 800;
}

.products-promotion-grid input,
.products-promotion-grid select {
    min-height: 30px;
    border: 1px solid #d6bda9;
    border-radius: 7px;
    background: #fffefc;
    color: var(--text);
    padding: 5px 7px;
    font: inherit;
    font-size: 12px;
}

.products-promotion-conflict-list {
    display: grid;
    gap: 6px;
    margin-top: 8px;
    max-height: 260px;
    overflow: auto;
}

.products-promotion-conflict-item {
    display: grid;
    gap: 2px;
    padding: 8px 10px;
    border: 1px solid #f0b6a0;
    border-radius: 7px;
    background: #fff4ee;
    font-size: 12px;
}

.products-promotion-conflict-item span {
    color: #7a3a22;
    font-size: 11px;
}

.purchase-xml-entry-overlay {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: stretch;
    justify-content: center;
    padding: 10px;
    background: rgba(31, 36, 48, 0.42);
}

.purchase-xml-entry-modal {
    width: min(1360px, calc(100vw - 20px));
    max-height: calc(100vh - 20px);
    overflow: auto;
    border: 1px solid #c7d9e7;
    border-radius: 8px;
    background: #f7fbfd;
    box-shadow: 0 18px 52px rgba(31, 36, 48, 0.32);
    padding: 8px;
}

.purchase-xml-entry-modal > .panel {
    margin-bottom: 8px;
}

.purchase-xml-entry-modal > .panel:last-child {
    margin-bottom: 0;
}

.purchase-xml-top-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(380px, 0.95fr);
    gap: 8px;
    align-items: start;
    margin-bottom: 8px;
}

.purchase-xml-top-grid-single {
    grid-template-columns: minmax(0, 1fr);
}

.purchase-xml-top-grid > .panel {
    margin-bottom: 0;
    padding: 10px;
}

.purchase-xml-summary-panel .panel-head,
.purchase-xml-cost-panel .panel-head {
    gap: 8px;
    margin-bottom: 6px;
}

.purchase-xml-summary-panel h1,
.purchase-xml-cost-panel h2 {
    margin: 0;
    font-size: 16px;
    line-height: 1.15;
}

.purchase-xml-summary-panel .eyebrow {
    margin-bottom: 2px;
}

.purchase-xml-summary-panel .panel-head p,
.purchase-xml-cost-panel .panel-head p {
    margin: 3px 0 0;
    font-size: 11px;
    line-height: 1.25;
}

.purchase-xml-header-panel {
    padding: 6px 10px;
}

.purchase-xml-facts {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px 14px;
}

.purchase-xml-note-strip {
    margin: 0;
    padding: 0;
    border: 0;
}

.purchase-xml-fact {
    display: inline-flex;
    align-items: baseline;
    gap: 5px;
    min-height: 20px;
    white-space: nowrap;
}

.purchase-xml-note-title {
    flex: 1 1 360px;
    min-width: 280px;
}

.purchase-xml-note-title strong {
    font-size: 14px;
}

.purchase-xml-note-title small {
    overflow: hidden;
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.purchase-xml-cost-inline {
    display: inline-flex;
    align-items: center;
    flex: 1 1 420px;
    flex-wrap: wrap;
    gap: 5px;
    min-width: 280px;
}

.purchase-xml-cost-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 26px;
    padding: 3px 4px 3px 8px;
    border: 1px solid #ead8c4;
    border-radius: 6px;
    background: #fff9f2;
    color: #213951;
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
}

.purchase-xml-cost-chip small {
    color: var(--muted);
    font-size: 9px;
    font-weight: 800;
}

.purchase-xml-cost-chip .button.small {
    min-height: 22px;
    padding: 3px 6px;
    border-radius: 5px;
    font-size: 9px;
    font-weight: 600;
}

.purchase-xml-fact em {
    color: var(--muted);
    font-size: 9px;
    font-style: normal;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.purchase-xml-fact strong {
    color: var(--text);
    font-size: 12px;
    font-weight: 800;
}

.purchase-xml-cost-form {
    display: grid;
    grid-template-columns: minmax(140px, 1fr) 100px minmax(150px, 1fr) 110px;
    gap: 6px;
    align-items: end;
}

.purchase-xml-cost-panel {
    display: grid;
    grid-template-columns: minmax(180px, 280px) minmax(0, 1fr);
    gap: 10px;
    align-items: end;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--line);
}

.purchase-xml-cost-title {
    display: grid;
    gap: 2px;
}

.purchase-xml-cost-title strong {
    font-size: 13px;
    line-height: 1.15;
}

.purchase-xml-cost-title span {
    color: var(--muted);
    font-size: 10px;
    line-height: 1.25;
}

.purchase-xml-cost-form label {
    gap: 4px;
    font-size: 11px;
}

.purchase-xml-cost-form input,
.purchase-xml-cost-form select {
    min-height: 32px;
    padding: 6px 8px;
}

.purchase-xml-cost-form .button {
    min-height: 32px;
    padding-block: 6px;
}

.purchase-xml-items-panel {
    min-height: auto;
}

.purchase-xml-grid-filter {
    display: grid;
    grid-template-columns: auto minmax(180px, 300px) auto;
    gap: 6px;
    align-items: center;
    margin-left: auto;
}

.purchase-xml-grid-tabs {
    display: flex;
    gap: 4px;
}

.purchase-xml-grid-tabs .button.is-active {
    background: #e07a34;
    border-color: #d96f2c;
    color: #fff;
}

.purchase-xml-grid-filter input {
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    color: var(--text);
    padding: 5px 8px;
    font: inherit;
    font-size: 11px;
    font-weight: 700;
}

.purchase-xml-grid-filter span {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.purchase-xml-checked-badge {
    display: inline-block;
    margin-top: 2px;
    padding: 2px 6px;
    border-radius: 999px;
    background: #dff5f2;
    color: #11645e;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.purchase-xml-price-badge {
    display: inline-block;
    margin-top: 2px;
    padding: 2px 6px;
    border-radius: 999px;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.purchase-xml-price-badge.is-pending,
.purchase-xml-price-pending {
    color: #9b4d17;
}

.purchase-xml-price-badge.is-pending {
    background: #fff1dc;
}

.purchase-xml-price-badge.is-released {
    background: #dff5f2;
    color: #11645e;
}

.purchase-xml-price-muted {
    color: var(--muted);
}

.purchase-xml-tax-suggestion {
    color: #9b4d17;
    font-size: 10px;
    font-weight: 800;
}

.purchase-xml-price-release-form {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
    margin-right: auto;
}

.purchase-xml-price-release-form select {
    min-height: 28px;
    max-width: 128px;
    padding: 5px 7px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff;
    font-size: 10px;
    font-weight: 700;
}

.purchase-xml-price-report-dialog {
    width: min(980px, calc(100vw - 40px));
}

.purchase-xml-price-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.purchase-xml-price-summary span {
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
    min-height: 24px;
    padding: 3px 8px;
    border: 1px solid #d8e7f0;
    border-radius: 999px;
    background: #f7fbfd;
    color: #1f3b57;
    font-size: 10px;
    font-weight: 800;
}

.purchase-xml-price-tabs {
    margin-top: 8px;
}

.purchase-xml-price-report-wrap {
    max-height: min(48vh, 420px);
    margin-top: 8px;
}

.purchase-xml-price-report-grid {
    min-width: 760px;
    font-size: 11px;
}

.purchase-xml-price-report-grid th,
.purchase-xml-price-report-grid td {
    padding: 5px 7px;
}

.purchase-xml-price-report-grid .is-positive {
    color: #11645e;
    font-weight: 900;
}

.purchase-xml-price-report-grid .is-negative {
    color: #9b1c1c;
    font-weight: 900;
}

.purchase-xml-financial-dialog {
    width: min(940px, calc(100vw - 32px));
}

.purchase-xml-financial-summary {
    display: grid;
    grid-template-columns: minmax(220px, 1.4fr) repeat(3, minmax(110px, 0.7fr));
    gap: 6px;
    margin-bottom: 8px;
}

.purchase-xml-financial-summary span {
    display: grid;
    gap: 2px;
    min-height: 46px;
    padding: 7px 9px;
    border: 1px solid #d8e7f0;
    border-radius: 7px;
    background: #f7fbfd;
}

.purchase-xml-financial-summary em {
    color: var(--muted);
    font-size: 9px;
    font-style: normal;
    font-weight: 900;
    text-transform: uppercase;
}

.purchase-xml-financial-summary strong {
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.purchase-xml-financial-wrap {
    max-height: min(46vh, 390px);
}

.purchase-xml-financial-grid {
    min-width: 760px;
    table-layout: fixed;
}

.purchase-xml-financial-grid th,
.purchase-xml-financial-grid td {
    padding: 6px 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.purchase-xml-financial-grid th:nth-child(1),
.purchase-xml-financial-grid td:nth-child(1) {
    width: 90px;
}

.purchase-xml-financial-grid th:nth-child(2),
.purchase-xml-financial-grid td:nth-child(2) {
    width: 105px;
}

.purchase-xml-financial-grid th:nth-child(5),
.purchase-xml-financial-grid td:nth-child(5) {
    width: 110px;
    text-align: right;
}

.purchase-xml-lots-wrap {
    height: auto;
    max-height: 300px;
    min-height: 0;
}

.purchase-xml-lots-grid {
    min-width: 980px;
}

.purchase-xml-lots-grid tbody tr {
    cursor: pointer;
}

.purchase-xml-lots-grid th,
.purchase-xml-lots-grid td {
    padding: 6px 8px;
}

.purchase-xml-lots-grid th:nth-child(1),
.purchase-xml-lots-grid td:nth-child(1) {
    width: 17%;
}

.purchase-xml-lots-grid th:nth-child(2),
.purchase-xml-lots-grid td:nth-child(2) {
    width: 28%;
}

.purchase-xml-lots-grid th:nth-child(3),
.purchase-xml-lots-grid td:nth-child(3) {
    width: 17%;
}

.purchase-xml-lots-grid th:nth-child(4),
.purchase-xml-lots-grid td:nth-child(4),
.purchase-xml-lots-grid th:nth-child(5),
.purchase-xml-lots-grid td:nth-child(5),
.purchase-xml-lots-grid th:nth-child(6),
.purchase-xml-lots-grid td:nth-child(6) {
    width: 12%;
}

.purchase-xml-lot-actions select,
.purchase-xml-lot-workbar select {
    min-height: 28px;
    max-width: 128px;
    padding: 5px 7px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff;
    font-size: 10px;
    font-weight: 700;
}

.purchase-xml-lot-actions .button,
.purchase-xml-lot-workbar .button {
    min-height: 28px;
    padding: 5px 9px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.purchase-xml-price-lot-modal {
    width: min(1400px, calc(100vw - 34px));
}

.purchase-xml-lot-head {
    gap: 10px;
}

.purchase-xml-lot-filter {
    margin-left: auto;
    grid-template-columns: auto minmax(190px, 320px) auto;
}

.purchase-xml-price-lot-wrap {
    height: min(58vh, 640px);
    min-height: 320px;
}

.purchase-xml-price-lot-grid {
    min-width: 980px;
}

.purchase-xml-price-lot-grid th,
.purchase-xml-price-lot-grid td {
    padding: 6px 8px;
}

.purchase-xml-price-lot-grid .is-positive {
    color: #11645e;
    font-weight: 900;
}

.purchase-xml-price-lot-grid .is-negative {
    color: #9b1c1c;
    font-weight: 900;
}

.purchase-xml-label-cell input {
    width: 76px;
    min-height: 28px;
    padding: 5px 7px;
    border: 1px solid var(--line);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 800;
}

.purchase-xml-lot-workbar {
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.purchase-xml-recent-wrap {
    height: auto;
    max-height: 360px;
    min-height: 0;
}

.purchase-xml-recent-grid {
    min-width: 980px;
}

.purchase-xml-recent-grid tbody tr {
    cursor: pointer;
}

.purchase-xml-recent-grid th,
.purchase-xml-recent-grid td {
    padding: 6px 8px;
}

.purchase-xml-recent-grid th:nth-child(1),
.purchase-xml-recent-grid td:nth-child(1) {
    width: 18%;
}

.purchase-xml-recent-grid th:nth-child(2),
.purchase-xml-recent-grid td:nth-child(2) {
    width: 26%;
}

.purchase-xml-recent-grid th:nth-child(3),
.purchase-xml-recent-grid td:nth-child(3) {
    width: 16%;
}

.purchase-xml-recent-grid th:nth-child(4),
.purchase-xml-recent-grid td:nth-child(4),
.purchase-xml-recent-grid th:nth-child(5),
.purchase-xml-recent-grid td:nth-child(5),
.purchase-xml-recent-grid th:nth-child(6),
.purchase-xml-recent-grid td:nth-child(6),
.purchase-xml-recent-grid th:nth-child(7),
.purchase-xml-recent-grid td:nth-child(7) {
    width: 10%;
}

.purchase-xml-recent-grid td,
.purchase-xml-recent-grid small {
    overflow-wrap: anywhere;
}

.purchase-xml-items-wrap {
    flex: 0 0 auto;
    height: min(56vh, 620px);
    min-height: 320px;
}

.purchase-xml-items-grid {
    min-width: 1040px;
    font-size: 11px;
}

.purchase-xml-items-grid th,
.purchase-xml-items-grid td {
    padding: 4px 5px;
}

.purchase-xml-items-grid th {
    font-size: 9px;
}

.purchase-xml-items-grid strong {
    font-size: 11px;
    line-height: 1.18;
}

.purchase-xml-items-grid small {
    font-size: 9px;
    line-height: 1.22;
}

.purchase-xml-items-grid td .purchase-xml-supplier-code,
.purchase-xml-items-grid td .purchase-xml-source-data {
    display: block;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
}

.purchase-xml-items-grid .purchase-xml-internal-data {
    display: block;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    color: #42566c;
}

.purchase-xml-items-grid th:nth-child(1),
.purchase-xml-items-grid td:nth-child(1) {
    width: 30%;
}

.purchase-xml-items-grid th:nth-child(2),
.purchase-xml-items-grid td:nth-child(2) {
    width: 20%;
}

.purchase-xml-items-grid th:nth-child(3),
.purchase-xml-items-grid td:nth-child(3) {
    width: 9%;
}

.purchase-xml-items-grid th:nth-child(4),
.purchase-xml-items-grid td:nth-child(4) {
    width: 16%;
}

.purchase-xml-items-grid th:nth-child(5),
.purchase-xml-items-grid td:nth-child(5) {
    width: 7%;
}

.purchase-xml-items-grid th:nth-child(6),
.purchase-xml-items-grid td:nth-child(6) {
    width: 7%;
}

.purchase-xml-items-grid th:nth-child(7),
.purchase-xml-items-grid td:nth-child(7) {
    width: 11%;
}

.purchase-xml-entry-modal .product-action-bar {
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.purchase-xml-workbar {
    display: grid;
    gap: 6px;
    align-items: stretch;
}

.purchase-xml-workbar .button {
    min-height: 28px;
    padding: 5px 9px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.purchase-xml-workbar .button.small {
    min-height: 26px;
    padding: 4px 7px;
    font-size: 10px;
}

.purchase-xml-action-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.purchase-xml-note-action-row {
    justify-content: flex-end;
    padding-top: 6px;
    border-top: 1px solid #d8e7f0;
}

.purchase-xml-workbar-filter {
    margin-left: auto;
    grid-template-columns: auto minmax(180px, 280px) auto;
}

.purchase-xml-workbar-cost {
    display: grid !important;
    grid-template-columns: auto minmax(170px, 260px) 76px minmax(100px, 130px) auto;
    align-items: center;
    gap: 5px;
    margin-right: auto;
}

.purchase-xml-workbar-cost strong {
    color: #1f3b57;
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.purchase-xml-workbar-cost input,
.purchase-xml-workbar-cost select {
    min-height: 28px;
    padding: 5px 8px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff;
    font-size: 11px;
    font-weight: 700;
}

.purchase-xml-product-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px 10px;
}

.purchase-xml-product-grid .full {
    grid-column: 1 / -1;
}

.purchase-xml-product-grid .half {
    grid-column: span 2;
}

.purchase-xml-product-grid label {
    gap: 3px;
    color: #1f3b57;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.15;
}

.purchase-xml-product-grid input,
.purchase-xml-product-grid select,
.purchase-xml-product-grid textarea {
    min-height: 30px;
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
}

.purchase-xml-product-grid label.is-required {
    color: #8f1d1d;
}

.purchase-xml-product-grid label.is-required > input,
.purchase-xml-product-grid label.is-required > select,
.purchase-xml-product-grid label.is-required > textarea {
    border-color: #d94f4f;
    box-shadow: inset 3px 0 0 rgba(217, 79, 79, 0.85);
}

.purchase-xml-product-grid textarea {
    min-height: 56px;
}

.purchase-xml-product-grid .product-sku-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 5px;
}

.purchase-xml-product-grid .product-sku-row .button {
    min-height: 30px;
    padding: 5px 8px;
    font-size: 11px;
}

.purchase-associate-search-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 8.5rem;
    gap: 0.5rem;
}

.purchase-associate-results-wrap {
    max-height: 14rem;
    min-height: 8rem;
    overflow: auto;
}

.purchase-associate-results-grid {
    min-width: 760px;
}

.purchase-associate-results-grid .purchase-associate-col-code { width: 75px; }
.purchase-associate-results-grid .purchase-associate-col-barcode { width: 130px; }
.purchase-associate-results-grid .purchase-associate-col-unit { width: 48px; }
.purchase-associate-results-grid .purchase-associate-col-price { width: 88px; }
.purchase-associate-results-grid .purchase-associate-col-stock { width: 72px; }

.purchase-associate-results-grid td,
.purchase-associate-results-grid th {
    padding: 0.35rem 0.45rem;
    white-space: nowrap;
}

.purchase-associate-results-grid td:nth-child(3) {
    white-space: normal;
}

.purchase-associate-error {
    color: #b42318;
    font-weight: 700;
}

.purchase-xml-product-dialog {
    width: min(1240px, calc(100vw - 28px));
}

.purchase-xml-product-dialog .tax-profile-dialog-body {
    gap: 10px;
    max-height: calc(100vh - 40px);
}

@media (max-width: 1180px) {
    .purchase-xml-top-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .purchase-xml-cost-panel {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 980px) {
    .purchase-xml-product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .purchase-xml-product-grid .half {
        grid-column: span 1;
    }
}

@media (max-width: 760px) {
    .purchase-xml-grid-filter {
        grid-template-columns: minmax(0, 1fr) auto;
        width: 100%;
        margin-left: 0;
    }

    .purchase-xml-grid-tabs {
        grid-column: 1 / -1;
    }

    .purchase-xml-grid-filter span {
        grid-column: auto;
    }

    .purchase-xml-cost-form {
        grid-template-columns: minmax(0, 1fr);
    }

    .purchase-xml-fact {
        min-width: calc(50% - 10px);
    }

    .purchase-xml-product-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .purchase-xml-product-grid .half {
        grid-column: 1 / -1;
    }
}

.company-stores-panel {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 188px);
    margin-bottom: 0;
    padding: 12px;
}

.company-stores-head {
    margin-bottom: 8px;
}

.company-stores-grid-wrap {
    flex: 1;
    min-height: 520px;
    height: calc(100vh - 284px);
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.company-stores-grid {
    width: 100%;
    min-width: 1120px;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 12px;
}

.company-stores-grid th,
.company-stores-grid td {
    padding: 2px 5px;
    border-bottom: 1px solid #e2edf5;
    text-align: left;
    vertical-align: middle;
    line-height: 1.08;
}

.company-stores-grid td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.company-stores-grid th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f4f8fb;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.1;
    text-transform: uppercase;
}

.company-stores-grid th:nth-child(1),
.company-stores-grid td:nth-child(1) {
    width: 6%;
}

.company-stores-grid th:nth-child(2),
.company-stores-grid td:nth-child(2) {
    width: 33%;
}

.company-stores-grid th:nth-child(3),
.company-stores-grid td:nth-child(3) {
    width: 14%;
}

.company-stores-grid th:nth-child(4),
.company-stores-grid td:nth-child(4) {
    width: 8%;
}

.company-stores-grid th:nth-child(5),
.company-stores-grid td:nth-child(5) {
    width: 12%;
}

.company-stores-grid th:nth-child(6),
.company-stores-grid td:nth-child(6) {
    width: 11%;
}

.company-stores-grid th:nth-child(7),
.company-stores-grid td:nth-child(7) {
    width: 10%;
}

.company-stores-grid th:nth-child(8),
.company-stores-grid td:nth-child(8) {
    width: 6%;
}

.company-stores-grid tbody tr[data-company-store-row] {
    cursor: pointer;
}

.company-stores-grid tbody tr:hover {
    background: #eef7f8;
}

.company-stores-grid tbody tr:focus {
    outline: 2px solid rgba(18, 172, 160, 0.35);
    outline-offset: -2px;
}

.company-stores-grid tbody tr.is-selected {
    background: #dff5f2;
    box-shadow: inset 3px 0 0 var(--primary);
}

.company-store-kind {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    padding: 1px 5px;
    border-radius: 999px;
    font-size: 10px;
    line-height: 1.05;
}

.company-stores-grid .status-badge {
    min-height: 16px;
    margin: 0;
    padding: 1px 6px;
    line-height: 1.05;
    font-size: 10px;
}

.company-store-kind.is-main {
    background: #dce8fb;
    color: #123b69;
    font-weight: 700;
}

.company-store-kind.is-branch {
    background: #dff6e7;
    color: #2d7a4c;
    font-weight: 500;
}

.company-stores-action-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
    padding: 8px;
    border: 1px solid var(--primary);
    border-radius: 8px;
    background: #f8fbfd;
}

.company-stores-action-bar form {
    display: contents;
}

.company-stores-action-bar button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.company-stores-selection-note {
    margin-left: auto;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.company-branch-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: end;
    margin: 10px 0;
}

.company-branch-search label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.company-branch-candidate-list {
    display: grid;
    gap: 6px;
    max-height: 340px;
    overflow: auto;
    border: 1px solid #c8dae8;
    border-radius: 8px;
    padding: 8px;
    background: #fff;
}

.company-branch-candidate {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 8px;
    align-items: center;
    padding: 8px;
    border: 1px solid #d7e5ef;
    border-radius: 7px;
    cursor: pointer;
}

.company-branch-candidate:hover {
    background: #eef7f8;
}

.company-branch-candidate:has(input:checked) {
    border-color: var(--primary);
    background: #dff5f2;
}

.company-branch-candidate span,
.company-branch-candidate strong,
.company-branch-candidate small {
    display: block;
    min-width: 0;
}

.company-branch-candidate small {
    color: var(--muted);
    font-size: 10px;
    margin-top: 2px;
}

.company-store-dialog {
    width: min(920px, calc(100vw - 28px));
}

.company-store-alias-dialog {
    width: min(420px, calc(100vw - 28px));
}

.company-store-alias-form {
    grid-template-columns: 1fr;
}

.company-store-form {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.company-store-form .full {
    grid-column: 1 / -1;
}

.accounts-receivable-grid-wrap {
    height: min(500px, 55vh);
    max-width: 100%;
    min-height: 360px;
    max-height: 55vh;
    overflow: auto;
}

.accounts-receivable-grid {
    min-width: 1330px;
    table-layout: fixed;
}

.accounts-receivable-grid .receivable-col-date {
    width: 83px;
}

.accounts-receivable-grid .receivable-col-customer {
    width: 180px;
}

.accounts-receivable-grid .receivable-col-history {
    width: 180px;
}

.accounts-receivable-grid .receivable-col-store {
    width: 110px;
}

.accounts-receivable-grid .receivable-col-sale {
    width: 62px;
}

.accounts-receivable-grid .receivable-col-installment {
    width: 38px;
}

.accounts-receivable-grid .receivable-col-money {
    width: 70px;
}

.accounts-receivable-grid .receivable-col-method {
    width: 86px;
}

.accounts-receivable-grid .receivable-col-delay {
    width: 50px;
}

.accounts-receivable-grid .receivable-col-status {
    width: 78px;
}

.accounts-receivable-grid .receivable-col-bank {
    width: 360px;
}

.accounts-receivable-bank-badge {
    cursor: default;
    white-space: nowrap;
}

.accounts-receivable-boleto-popover {
    position: fixed;
    z-index: 10000;
    width: min(460px, calc(100vw - 24px));
    padding: 10px;
    border: 1px solid #b8cee2;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 12px 28px rgba(22, 42, 64, 0.22);
    color: #0f2238;
    font-size: 12px;
}

.accounts-receivable-boleto-popover strong {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
}

.accounts-receivable-boleto-popover dl {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 4px 8px;
    margin: 0;
}

.accounts-receivable-boleto-popover dt {
    font-weight: 700;
}

.accounts-receivable-boleto-popover dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.accounts-receivable-boleto-popover .button {
    margin-top: 8px;
}

.accounts-receivable-santander-result {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #d7e3ee;
}

.accounts-receivable-santander-result dl {
    display: grid;
    grid-template-columns: 104px minmax(0, 1fr);
    gap: 5px 8px;
    margin: 0 0 8px;
}

.accounts-receivable-santander-result dt {
    font-weight: 700;
}

.accounts-receivable-santander-result dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.accounts-receivable-empty td {
    height: 220px;
    text-align: center;
    color: #7a6a5a;
}

.accounts-receivable-panel {
    display: grid;
    gap: 8px;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
}

.accounts-receivable-head-total {
    align-self: end;
    border: 1px solid #cfe2ef;
    border-radius: 8px;
    display: grid;
    gap: 2px;
    min-width: 130px;
    max-width: 190px;
    padding: 8px 10px;
    text-align: right;
}

.accounts-receivable-head-total span,
.accounts-receivable-summary span {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.accounts-receivable-head-total strong {
    font-size: 18px;
}

.accounts-receivable-summary {
    display: grid;
    gap: 7px;
    grid-template-columns: repeat(auto-fit, minmax(138px, 1fr));
    min-width: 0;
}

.accounts-receivable-summary > div {
    background: #fffefa;
    border: 1px solid #cfe2ef;
    border-radius: 8px;
    display: grid;
    gap: 2px;
    min-width: 0;
    padding: 7px 9px;
}

.accounts-receivable-summary strong {
    font-size: 13px;
}

.accounts-receivable-filter-card {
    padding: 8px;
    max-width: 100%;
    overflow: visible;
}

.accounts-receivable-filters {
    align-items: end;
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    max-width: 100%;
    overflow: visible;
}

.accounts-receivable-filters label {
    display: grid;
    flex: 1 1 118px;
    gap: 3px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    min-width: 0;
}

.accounts-receivable-filters input,
.accounts-receivable-filters select {
    min-height: 30px;
    min-width: 0;
    padding: 6px 8px;
    width: 100%;
}

.accounts-receivable-customer-filter {
    flex: 2 1 310px !important;
}

.accounts-receivable-company-filter {
    flex: 2.4 1 430px !important;
}

.accounts-receivable-customer-lookup {
    display: grid;
    gap: 5px;
    grid-template-columns: minmax(220px, 1fr) auto;
    min-width: 0;
}

.accounts-receivable-customer-lookup .button {
    min-height: 30px;
    padding: 6px 9px;
}

.accounts-receivable-filter-submit {
    background: #e6792e;
    flex: 0 1 96px;
    min-height: 32px;
    min-width: 0;
}

.accounts-receivable-filter-clear {
    color: #5d6a74;
    flex: 0 1 88px;
    min-height: 32px;
    min-width: 0;
}

.accounts-receivable-card {
    display: grid;
    gap: 8px;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
    padding: 8px;
}

.accounts-receivable-grid th,
.accounts-receivable-grid td {
    overflow: hidden;
    padding: 4px 6px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.accounts-receivable-grid td,
.accounts-receivable-grid td strong {
    font-weight: 600;
}

.accounts-receivable-grid tbody td {
    height: 27px;
    line-height: 1.15;
}

.accounts-receivable-grid small {
    color: #476174;
    font-size: 10px;
}

.accounts-receivable-sort-button {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    width: 100%;
    min-height: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: inherit;
    text-align: left;
    cursor: pointer;
}

.accounts-receivable-sort-button::after {
    content: "↕";
    color: #9b8977;
    font-size: 9px;
    opacity: 0.55;
}

.accounts-receivable-sort-button[data-direction="asc"]::after {
    content: "▲";
    color: #c25e1c;
    opacity: 1;
}

.accounts-receivable-sort-button[data-direction="desc"]::after {
    content: "▼";
    color: #c25e1c;
    opacity: 1;
}

.accounts-receivable-grid tbody tr[data-receivable-row] {
    cursor: pointer;
}

.accounts-receivable-grid tbody tr[data-receivable-row]:hover {
    background: #eef7f8;
}

.accounts-receivable-grid tbody tr[data-receivable-row]:focus {
    outline: 2px solid rgba(18, 172, 160, 0.35);
    outline-offset: -2px;
}

.accounts-receivable-grid.vfp-grid tbody tr.is-selected {
    background: #c8f0ec;
    box-shadow: inset 4px 0 0 var(--primary);
}

.accounts-receivable-grid.vfp-grid tbody tr.is-selected:hover {
    background: #bce9e4;
}

.accounts-receivable-grid.vfp-grid tbody tr.is-marked {
    background: #ffd9a8;
    box-shadow: inset 4px 0 0 #e6792e;
}

.accounts-receivable-grid.vfp-grid tbody tr.is-selected.is-marked {
    background: #ffc983;
    box-shadow: inset 4px 0 0 #c75f1f;
}

.accounts-receivable-actions {
    align-items: center;
    border: 1px solid #e6792e;
    border-radius: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    max-width: 100%;
    overflow: hidden;
    padding: 7px;
}

.accounts-receivable-actions .button {
    flex: 0 1 auto;
    min-height: 30px;
    min-width: 0;
    padding: 6px 10px;
    white-space: normal;
}

.accounts-receivable-selection {
    flex: 1 1 180px;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 1220px) {
    .accounts-receivable-customer-filter {
        flex-basis: 300px !important;
    }
}

@media (max-width: 860px) {
    .accounts-receivable-panel {
        min-width: 0;
    }

    .accounts-receivable-panel .compact-panel-head {
        grid-template-columns: minmax(0, 1fr);
    }

    .accounts-receivable-head-total {
        min-width: 0;
        text-align: left;
    }

    .accounts-receivable-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .accounts-receivable-customer-lookup {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .accounts-receivable-grid-wrap {
        max-width: 100%;
        overflow: auto;
    }

    .accounts-receivable-grid {
        min-width: 1040px;
    }

    .accounts-receivable-actions {
        flex-wrap: wrap;
        max-width: 100%;
        overflow: hidden;
    }

    .accounts-receivable-actions .button {
        flex: 1 1 110px;
        min-width: 0;
    }
}

.accounts-receivable-message-dialog {
    width: min(460px, calc(100vw - 28px));
}

.accounts-receivable-message-body {
    display: grid;
    gap: 12px;
}

.accounts-receivable-message-body .accounts-receivable-actions {
    justify-content: flex-end;
}

.accounts-receivable-sale-pdf-dialog {
    width: min(1120px, calc(100vw - 28px));
}

.sales-receipt-pdf-dialog {
    width: min(1120px, calc(100vw - 28px));
}

.retaguarda-paid-link-dialog {
    width: min(720px, calc(100vw - 28px));
}

.retaguarda-paid-link-body {
    display: grid;
    gap: 12px;
}

.retaguarda-paid-link-grid {
    display: grid;
    gap: 8px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.retaguarda-paid-link-grid div {
    border: 1px solid var(--line);
    border-radius: 7px;
    display: grid;
    gap: 3px;
    padding: 8px 10px;
}

.retaguarda-paid-link-grid span {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.retaguarda-paid-link-grid strong {
    color: var(--ink);
    font-size: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.retaguarda-paid-link-message {
    background: #fff7ef;
    border: 1px solid #efb684;
    border-left: 4px solid #df7936;
    border-radius: 8px;
    color: #7a3608;
    font-size: 12px;
    padding: 10px 12px;
}

.retaguarda-paid-link-message[data-tone="success"] {
    background: #e9f8ef;
    border-color: #b8e5c8;
    border-left-color: #2ba360;
    color: #086332;
}

.retaguarda-paid-link-message[data-tone="error"] {
    background: #fff1f1;
    border-color: #f3b6b6;
    border-left-color: #d53a3a;
    color: #8a1f1f;
}

.retaguarda-paid-link-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

@media (max-width: 760px) {
    .retaguarda-paid-link-grid {
        grid-template-columns: 1fr;
    }
}

.accounts-receivable-sale-pdf-body {
    display: grid;
    gap: 10px;
    height: min(820px, calc(100vh - 42px));
    grid-template-rows: auto minmax(0, 1fr);
}

.sales-receipt-pdf-body {
    display: grid;
    gap: 10px;
    height: min(820px, calc(100vh - 42px));
    grid-template-rows: auto minmax(0, 1fr);
}

.accounts-receivable-sale-pdf-body iframe {
    width: 100%;
    height: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.sales-receipt-pdf-body iframe {
    width: 100%;
    height: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.is-kit-price-locked {
    background: #eef8fb !important;
    color: #435466;
    cursor: not-allowed;
}

.accounts-receivable-selection {
    margin-left: auto;
    text-align: right;
}

.accounts-receivable-dialog-body,
.accounts-receivable-link-dialog-body {
    width: min(900px, calc(100vw - 36px));
}

[data-receivable-customer-dialog] {
    width: min(1080px, calc(100vw - 28px));
    max-width: calc(100vw - 28px);
}

.accounts-receivable-list-dialog-body {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.accounts-receivable-receive-form {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.accounts-receivable-link-dialog-body {
    display: grid;
    gap: 10px;
}

.accounts-receivable-link-dialog-body textarea {
    min-height: 120px;
    resize: vertical;
}

.accounts-receivable-customer-search-line {
    align-items: end;
    display: grid;
    gap: 8px;
    grid-template-columns: minmax(320px, 1fr) minmax(180px, 220px) 120px;
}

.customers-toolbar {
    grid-template-columns: minmax(360px, 1fr) minmax(150px, 190px) minmax(130px, 160px) auto auto;
}

.customers-toolbar > label:first-of-type,
.customers-toolbar > label:first-of-type input {
    min-width: 0;
    width: 100%;
}

.accounts-receivable-customer-search-line label {
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.accounts-receivable-customer-grid th,
.accounts-receivable-customer-grid td {
    padding: 6px 8px;
}

.accounts-receivable-customer-grid {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}

.accounts-receivable-customer-grid col.receivable-customer-col-name {
    width: 31%;
}

.accounts-receivable-customer-grid col.receivable-customer-col-document {
    width: 20%;
}

.accounts-receivable-customer-grid col.receivable-customer-col-type {
    width: 13%;
}

.accounts-receivable-customer-grid col.receivable-customer-col-city {
    width: 20%;
}

.accounts-receivable-customer-grid col.receivable-customer-col-contact {
    width: 16%;
}

.suggestion-notification-dialog {
    width: min(520px, calc(100vw - 28px));
    max-height: calc(100vh - 36px);
    padding: 0;
    border: 1px solid #c8dce8;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 18px 44px rgba(20, 39, 57, 0.28);
    color: var(--text);
}

.suggestion-notification-dialog::backdrop {
    background: rgba(24, 39, 53, 0.46);
}

.suggestion-notification-body {
    display: grid;
    gap: 0;
    max-height: calc(100vh - 38px);
    overflow: hidden;
}

.suggestion-notification-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border-bottom: 1px solid #d8e5ed;
    background: #f6fafc;
}

.suggestion-notification-head > div {
    display: grid;
    gap: 1px;
}

.suggestion-notification-head span {
    color: var(--muted);
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
}

.suggestion-notification-head strong {
    font-size: 14px;
}

.suggestion-notification-list {
    display: grid;
    gap: 7px;
    max-height: min(540px, calc(100vh - 96px));
    padding: 8px;
    overflow-y: auto;
}

.suggestion-notification-item {
    display: grid;
    gap: 6px;
    padding: 9px;
    border: 1px solid #d8e5ed;
    border-left: 3px solid #e6792e;
    border-radius: 8px;
    background: #fff;
}

.suggestion-notification-title {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.suggestion-notification-title strong {
    min-width: 0;
    overflow: hidden;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.suggestion-notification-title span {
    flex: 0 0 auto;
    padding: 3px 6px;
    border-radius: 999px;
    background: #e6f6ef;
    color: #08785f;
    font-size: 9px;
    font-weight: 800;
}

.suggestion-notification-item p {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: #40576a;
    font-size: 11px;
    line-height: 1.35;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.suggestion-notification-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 3px 10px;
    color: var(--muted);
    font-size: 9.5px;
}

.suggestion-notification-actions {
    display: flex;
    justify-content: flex-end;
    gap: 6px;
}

.suggestion-notification-actions .button,
.suggestion-notification-head .button {
    min-height: 28px;
    padding: 5px 8px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 10px;
    font-weight: 400;
}

.accounts-receivable-customer-grid tbody tr[data-receivable-customer-row] {
    cursor: pointer;
}

.accounts-receivable-customer-grid tbody tr[data-receivable-customer-row]:hover {
    background: #eef7f8;
}

.accounts-receivable-customer-grid tbody tr[data-receivable-customer-row]:focus {
    outline: 2px solid rgba(18, 172, 160, 0.35);
    outline-offset: -2px;
}

.accounts-receivable-customer-grid tbody tr.is-selected,
.accounts-receivable-customer-grid tbody tr.is-selected:hover {
    background: #dff5f2;
    box-shadow: inset 3px 0 0 var(--primary);
}

.accounts-receivable-mini-grid-wrap {
    height: min(360px, 50vh);
    min-height: 260px;
    max-width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

@media (max-width: 640px) {
    .customers-toolbar {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .customers-toolbar > label:first-of-type {
        grid-column: 1 / -1;
    }

    .accounts-receivable-list-dialog-body {
        width: min(420px, calc(100vw - 24px));
        max-height: calc(100svh - 24px);
        overflow: auto;
    }

    .accounts-receivable-list-dialog-body .panel-head {
        grid-template-columns: minmax(0, 1fr);
        gap: 8px;
    }

    .accounts-receivable-list-dialog-body .panel-head .button {
        width: min(120px, 100%);
    }

    .accounts-receivable-customer-search-line {
        grid-template-columns: minmax(0, 1fr);
    }

    .accounts-receivable-customer-search-line input,
    .accounts-receivable-customer-search-line select,
    .accounts-receivable-customer-search-line .button {
        width: 100%;
        min-width: 0;
    }

    .accounts-receivable-mini-grid-wrap {
        max-width: 100%;
        min-height: 220px;
        height: min(300px, 42svh);
        overflow: auto;
    }

    .accounts-receivable-customer-grid {
        min-width: 100%;
        table-layout: fixed;
    }

    .accounts-receivable-customer-grid th,
    .accounts-receivable-customer-grid td {
        white-space: nowrap;
    }

    .accounts-receivable-list-dialog-body .accounts-receivable-actions {
        align-items: stretch;
    }

    .accounts-receivable-list-dialog-body .accounts-receivable-selection {
        flex-basis: 100%;
        margin-left: 0;
        text-align: left;
        white-space: normal;
    }
}

.manual-receivable-dialog-body {
    gap: 12px;
}

.manual-receivable-form {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.manual-receivable-generate {
    align-self: end;
}

.manual-receivable-total {
    padding: 8px 10px;
    border: 1px dashed #dbc8b6;
    border-radius: 8px;
    background: #fffaf3;
    color: #1f3556;
    font-weight: 800;
}

.manual-receivable-installments-wrap {
    max-height: 260px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.manual-receivable-installments {
    min-width: 860px;
}

.manual-receivable-installments input {
    min-height: 28px;
    padding: 5px 7px;
    font-size: 11px;
}

.promotions-standard-panel {
    display: grid;
    gap: 8px;
}

.promotions-standard-panel .panel-head {
    margin-bottom: 0;
}

.promotions-filter-bar {
    align-items: end;
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 170px 130px 110px;
    gap: 7px;
}

.promotions-filter-bar-embedded {
    grid-template-columns: minmax(260px, 420px) minmax(160px, 1fr);
}

.promotion-filter-note {
    align-self: end;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
    padding: 8px 0;
}

.promotions-filter-bar label {
    display: grid;
    gap: 3px;
    color: var(--muted);
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
}

.promotions-filter-bar input,
.promotions-filter-bar select {
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fffefc;
    padding: 5px 7px;
    color: var(--text);
    font-size: 12px;
}

.promotions-manager-wrap {
    height: 430px;
    max-height: 430px;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.promotions-booklets-grid {
    min-width: 0;
    table-layout: fixed;
    width: 100%;
}

.promotions-booklets-grid .promotion-col-id {
    width: 7%;
}

.promotions-booklets-grid .promotion-col-name {
    width: 27%;
}

.promotions-booklets-grid .promotion-col-store {
    width: 17%;
}

.promotions-booklets-grid .promotion-col-validity {
    width: 18%;
}

.promotions-booklets-grid .promotion-col-status {
    width: 12%;
}

.promotions-booklets-grid .promotion-col-products {
    width: 8%;
}

.promotions-booklets-grid .promotion-col-created {
    width: 11%;
}

.promotions-booklets-grid th,
.promotions-booklets-grid td {
    padding: 5px 7px;
    font-size: 11px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.promotions-booklets-grid tbody tr {
    cursor: pointer;
}

.promotions-booklets-grid tbody tr.is-selected,
.promotions-booklets-grid tbody tr.is-selected:hover {
    background: #d8f1ee;
    box-shadow: inset 3px 0 0 var(--accent);
}

.promotions-action-bar {
    align-items: center;
    gap: 6px;
}

.promotion-entry-dialog {
    width: min(1220px, calc(100vw - 40px));
}

.products-promotions-dialog .products-stock-documents-body {
    width: min(1280px, calc(100vw - 40px));
}

.promotion-entry-form {
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.promotion-entry-fields {
    display: grid;
    grid-template-columns: minmax(220px, 1.2fr) minmax(150px, 0.8fr) 116px 116px minmax(170px, 0.9fr) 86px 126px;
    gap: 7px;
}

.promotion-search-line {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) 120px 120px auto;
    gap: 7px;
    align-items: end;
    margin-top: 8px;
}

.promotion-entry-fields label,
.promotion-search-line label,
.products-promotion-grid label {
    display: grid;
    gap: 3px;
    color: var(--text);
    font-size: 10.5px;
    font-weight: 800;
}

.promotion-entry-fields input,
.promotion-entry-fields select,
.promotion-search-line input {
    width: 100%;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fffefc;
    padding: 5px 7px;
    color: var(--text);
    font-size: 12px;
}

.promotion-builder {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
    gap: 10px;
    margin-top: 10px;
}

.promotion-builder-compact .settings-subcard {
    padding: 10px;
}

.promotion-builder-compact .settings-subcard-head {
    margin-bottom: 7px;
}

.promotion-products-card,
.promotion-selected-card {
    min-width: 0;
}

.promotion-selected-summary {
    min-height: 24px;
    color: var(--muted);
    font-size: 11px;
}

.promotion-product-results-wrap,
.promotion-selected-wrap {
    height: 300px;
    max-height: 300px;
    margin-top: 8px;
}

.promotion-product-results-grid {
    min-width: 720px;
}

.promotion-product-results-grid th,
.promotion-product-results-grid td,
.promotion-selected-wrap table th,
.promotion-selected-wrap table td {
    padding: 4px 6px;
    font-size: 11px;
}

[data-promotion-product-row] {
    cursor: pointer;
}

[data-promotion-product-row].is-focused {
    outline: 2px solid #b91c1c;
    outline-offset: -2px;
}

[data-promotion-product-row].is-selected {
    background: #eaf7ee;
}

[data-promotion-product-row][data-locked="1"] {
    color: #9a6a4f;
    background: #fff4ec;
    cursor: not-allowed;
}

[data-promotion-selected-row] {
    cursor: pointer;
}

[data-promotion-selected-row].is-selected,
[data-promotion-selected-row].is-selected:hover {
    background: #d8f1ee;
}

.warning-box {
    border: 1px solid #f4c7b8;
    border-radius: 8px;
    background: #fff4ee;
    color: #9a3412;
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 700;
}

.status-pill.status-active {
    background: #dff8ed;
    border-color: #a9ebd0;
    color: #047857;
}

.status-pill.status-ended {
    background: #eef4f8;
    border-color: #d6e2ea;
    color: #536273;
}

.status-pill.status-scheduled {
    background: #eef7ff;
    border-color: #bfdbfe;
    color: #1d4ed8;
}

.status-pill.status-expired {
    background: #fff7ed;
    border-color: #fed7aa;
    color: #c2410c;
}

.status-pill.status-cancelled {
    background: #fff4ee;
    border-color: #f4c7b8;
    color: #9a3412;
}

@media (max-width: 1180px) {
    .promotions-filter-bar,
    .promotion-entry-fields,
    .promotion-search-line,
    .promotion-builder {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .promotions-filter-bar,
    .promotion-entry-fields,
    .promotion-search-line,
    .promotion-builder {
        grid-template-columns: 1fr;
    }
}

.fuel-rates-toolbar {
    justify-content: space-between;
    align-items: end;
    gap: 12px;
}

.fuel-rates-search {
    display: grid;
    gap: 4px;
    min-width: min(420px, 100%);
}

.fuel-rates-search span {
    font-size: 11px;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.fuel-rates-grid tbody tr[hidden] {
    display: none;
}

.fuel-rates-grid tbody tr.is-selected,
.fuel-rates-grid tbody tr.is-selected:hover {
    background: #d9e8fb;
}

.fuel-rates-grid {
    table-layout: fixed;
    min-width: 100%;
}

.fuel-rates-grid th:nth-child(1),
.fuel-rates-grid td:nth-child(1) {
    width: 110px;
}

.fuel-rates-grid th:nth-child(2),
.fuel-rates-grid td:nth-child(2) {
    width: 320px;
}

.fuel-rates-grid th:nth-child(3),
.fuel-rates-grid td:nth-child(3),
.fuel-rates-grid th:nth-child(4),
.fuel-rates-grid td:nth-child(4),
.fuel-rates-grid th:nth-child(5),
.fuel-rates-grid td:nth-child(5) {
    width: 130px;
}

.fuel-rates-grid th:nth-child(6),
.fuel-rates-grid td:nth-child(6),
.fuel-rates-grid th:nth-child(7),
.fuel-rates-grid td:nth-child(7),
.fuel-rates-grid th:nth-child(8),
.fuel-rates-grid td:nth-child(8) {
    width: 90px;
}

.fuel-rates-actions {
    justify-content: flex-start;
    margin-top: 8px;
}

.fuel-rates-summary {
    margin-top: 10px;
}

.fuel-rate-form {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
}

.product-stock-layout {
    display: grid;
    grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
    gap: 12px;
}

.product-movement-form {
    display: grid;
    gap: 12px;
}

.product-stock-head {
    display: grid;
    gap: 6px;
}

.product-stock-head p {
    margin: 0;
    color: var(--muted);
}

.product-form-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    font-family: Tahoma, Arial, sans-serif;
}

.product-form-grid label {
    font-weight: 400;
}

.product-form-grid label.is-required {
    font-weight: 700;
}

.product-form-grid .product-form-wide {
    grid-column: span 2;
}

.product-form-grid .product-form-full {
    grid-column: 1 / -1;
}

.product-form-grid input,
.product-form-grid select {
    min-height: 40px;
}

.product-sku-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
}

.product-special-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

.tax-profile-form-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px 10px;
}

.tax-profile-dialog .notice {
    padding: 8px 10px;
    min-height: auto;
    font-size: 12px;
    line-height: 1.25;
}

.tax-profile-dialog .notice strong {
    font-weight: 500;
}

.tax-profile-form-grid label {
    gap: 3px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.15;
}

.tax-profile-form-grid small {
    font-size: 10px;
    line-height: 1.15;
    font-weight: 400;
}

.tax-profile-form-grid input,
.tax-profile-form-grid select,
.tax-profile-form-grid textarea {
    min-height: 31px;
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 400;
}

.tax-profile-form-grid textarea {
    min-height: 58px;
}

.tax-profile-form-grid .button {
    min-height: 31px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 500;
}

.tax-profile-form-grid label:has(select[name="tax_reform_ibs_cbs_class_trib"]),
.tax-profile-form-grid label:has(select[name="tax_reform_is_class_trib"]) {
    grid-column: span 2;
}

.tax-profile-form-grid label:has(input[name="tax_profile_name"]) {
    order: 10;
}

.tax-profile-form-grid label:has(input[readonly]) {
    order: 11;
}

.tax-profile-form-grid label:has(select[name="tax_profile_icms_code"]) {
    order: 12;
}

.tax-profile-form-grid [data-tax-field="icms-rate"] {
    order: 13;
}

.tax-profile-form-grid [data-tax-field="icms-base-reduction-rate"] {
    order: 14;
}

.tax-profile-form-grid [data-tax-field="icms-st-rate"] {
    order: 15;
}

.tax-profile-form-grid [data-tax-field="fcp-rate"] {
    order: 16;
}

.tax-profile-form-grid [data-tax-field="fcp-st-rate"] {
    order: 17;
}

.tax-profile-form-grid label:has(input[name="tax_profile_pis_rate"]) {
    order: 18;
}

.tax-profile-form-grid label:has(input[name="tax_profile_cofins_rate"]) {
    order: 19;
}

.tax-profile-form-grid label:has(input[name="tax_profile_ipi_rate"]) {
    order: 20;
}

.tax-profile-form-grid [data-tax-field="has-icms-st"],
.tax-profile-form-grid [data-tax-field="allows-credit"],
.tax-profile-form-grid [data-tax-field="requires-benefit"] {
    order: 21;
}

.tax-profile-form-grid label:has(select[name="tax_profile_pis_cst"]) {
    order: 30;
}

.tax-profile-form-grid label:has(select[name="tax_profile_cofins_cst"]) {
    order: 31;
}

.tax-profile-form-grid label:has(select[name="tax_profile_ipi_cst"]) {
    order: 32;
}

.tax-profile-form-grid label:has(select[name="tax_profile_cfop_consumer_final"]) {
    order: 40;
}

.tax-profile-form-grid label:has(select[name="tax_profile_cfop_inside_state"]) {
    order: 41;
}

.tax-profile-form-grid label:has(select[name="tax_profile_cfop_outside_state"]) {
    order: 42;
}

.tax-profile-form-grid label:has(select[name="tax_profile_transfer_icms_code"]) {
    order: 50;
}

.tax-profile-form-grid label:has(select[name="tax_profile_transfer_cfop_inside_state"]) {
    order: 51;
}

.tax-profile-form-grid label:has(select[name="tax_profile_transfer_cfop_outside_state"]) {
    order: 52;
}

.tax-profile-form-grid .notice {
    order: 0;
}

.tax-profile-form-grid label.full,
.tax-profile-form-grid [data-tax-field="monophase-guidance"] {
    order: 90;
}

.tax-profile-form-grid .inline-actions {
    order: 100;
}

.tax-profile-form-grid .checkbox-field {
    align-self: end;
    min-height: 31px;
    display: flex;
    gap: 7px;
    align-items: center;
}

.tax-profile-form-grid .is-tax-field-disabled {
    color: #789;
    opacity: 0.72;
}

.tax-profile-form-grid .is-tax-field-disabled input,
.tax-profile-form-grid .is-tax-field-disabled select,
.tax-profile-form-grid .is-tax-field-disabled textarea {
    background: #eef5f8;
    color: #6f7f8d;
    cursor: not-allowed;
}

@media (min-width: 861px) {
    .tax-profile-dialog {
        width: min(1120px, calc(100vw - 28px));
    }

    .tax-profile-dialog .tax-profile-form-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.tax-profile-form-grid .inline-actions,
.tax-profile-form-grid .notice,
.tax-profile-form-grid label.full {
    grid-column: 1 / -1;
}

.tax-profile-form-grid .inline-actions {
    justify-content: flex-start;
    gap: 8px;
    padding-top: 4px;
}

.fiscal-rules-panel {
    display: grid;
    gap: 10px;
}

.fiscal-rules-contract-note {
    padding: 8px 10px;
    min-height: auto;
    font-size: 12px;
    line-height: 1.3;
}

.fiscal-rules-grid-wrap {
    max-height: 62vh;
    overflow: auto;
}

.fiscal-rules-grid th,
.fiscal-rules-grid td {
    vertical-align: top;
    line-height: 1.25;
}

.fiscal-rules-grid td {
    white-space: normal;
}

.fiscal-rules-grid strong {
    display: block;
    font-weight: 600;
}

.fiscal-rules-grid small {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.25;
}

.fiscal-rules-grid code {
    display: inline-block;
    max-width: 360px;
    padding: 2px 5px;
    border-radius: 5px;
    background: #eef5f8;
    color: #18364f;
    font-family: Consolas, "Courier New", monospace;
    font-size: 11px;
    white-space: normal;
}

.certificate-required-panel {
    display: grid;
    gap: 14px;
}

.certificate-required-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
    gap: 14px;
    padding: 16px;
    border: 1px solid #f0ddd1;
    border-radius: 12px;
    background: linear-gradient(135deg, #fffdfb 0%, #fff4ee 100%);
}

.certificate-required-copy,
.certificate-required-notes {
    display: grid;
    gap: 6px;
}

.certificate-required-copy strong {
    font-size: 18px;
}

.certificate-required-copy span,
.certificate-required-notes small {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}

.certificate-required-actions {
    gap: 10px;
    flex-wrap: wrap;
}

.pending-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 12px;
    padding: 10px 12px;
    border: 1px solid #efb9b9;
    border-radius: 8px;
    background: #fdeeee;
    color: #8a1f1f;
}

.pending-banner-copy {
    display: grid;
    gap: 4px;
}

.pending-banner-copy strong {
    color: #6e1515;
    font-size: 12px;
}

.pending-banner-copy span {
    font-size: 11px;
    line-height: 1.35;
}

.certificate-password-box {
    display: grid;
    gap: 6px;
    min-width: 280px;
}

.certificate-password-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.certificate-password-row input {
    flex: 1 1 auto;
}

.certificate-expiry-modal[hidden] {
    display: none !important;
}

.certificate-expiry-modal {
    position: fixed;
    inset: 0;
    z-index: 1400;
    display: grid;
    place-items: center;
    padding: 16px;
}

.certificate-expiry-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.48);
}

.certificate-expiry-card {
    position: relative;
    width: min(560px, calc(100vw - 32px));
    max-height: calc(100vh - 32px);
    display: grid;
    grid-template-rows: auto 1fr auto;
    overflow: hidden;
    background: #fff;
    border: 1px solid #fed7aa;
    border-radius: 8px;
    box-shadow: 0 22px 48px rgba(15, 23, 42, 0.24);
}

.certificate-expiry-head,
.certificate-expiry-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    background: #fff7ed;
    border-bottom: 1px solid #fed7aa;
}

.certificate-expiry-head h2 {
    margin: 2px 0 0;
    font-size: 18px;
    font-weight: 400;
    color: #111827;
}

.certificate-expiry-body {
    display: grid;
    gap: 10px;
    padding: 14px;
    overflow: auto;
    font-size: 13px;
    line-height: 1.45;
    color: #334155;
}

.certificate-expiry-alert {
    margin: 0;
    padding: 10px 12px;
    border: 1px solid #fdba74;
    border-radius: 6px;
    background: #fff7ed;
    color: #9a3412;
}

.certificate-expiry-alert strong {
    color: #c2410c;
}

.certificate-expiry-body dl {
    display: grid;
    gap: 6px;
    margin: 0;
    padding: 0;
}

.certificate-expiry-body dl div {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 8px;
    align-items: baseline;
}

.certificate-expiry-body dt {
    color: #64748b;
    font-size: 11px;
    text-transform: uppercase;
}

.certificate-expiry-body dd {
    margin: 0;
    color: #0f172a;
    font-weight: 400;
}

.certificate-expiry-actions {
    justify-content: flex-end;
    border-top: 1px solid #fed7aa;
    border-bottom: 0;
}

.ncm-alert-trigger {
    min-height: 24px;
    padding: 3px 9px;
    border: 1px solid #f59e0b;
    border-radius: 6px;
    background: #fffbeb;
    color: #92400e;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 11px;
    font-weight: 400;
    cursor: pointer;
}

.ncm-alert-trigger:hover {
    background: #fef3c7;
}

.ncm-alert-modal[hidden] {
    display: none !important;
}

.ncm-alert-modal {
    position: fixed;
    inset: 0;
    z-index: 1500;
    display: grid;
    place-items: center;
    padding: 24px;
}

.ncm-alert-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(69, 10, 10, 0.72);
}

.ncm-alert-card {
    position: relative;
    width: min(1120px, calc(100vw - 48px));
    height: min(760px, calc(100vh - 48px));
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    overflow: hidden;
    background: #fff;
    border: 2px solid #ef4444;
    border-radius: 8px;
    box-shadow: 0 30px 70px rgba(69, 10, 10, 0.38);
}

.ncm-alert-head,
.ncm-alert-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 18px;
    background: #991b1b;
    border-bottom: 1px solid #b91c1c;
    color: #fff;
}

.ncm-alert-head h2 {
    margin: 2px 0 0;
    font-size: 22px;
    font-weight: 400;
    color: #fff;
}

.ncm-alert-head .eyebrow {
    color: #fee2e2;
}

.ncm-alert-head .button {
    border-color: rgba(255, 255, 255, 0.55);
    background: #fff;
    color: #991b1b;
}

.ncm-alert-summary {
    margin: 0;
    padding: 14px 18px;
    border-bottom: 1px solid #fecaca;
    background: #fee2e2;
    color: #7f1d1d;
    font-size: 15px;
    line-height: 1.35;
}

.ncm-alert-body {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.8fr);
    gap: 12px;
    padding: 14px;
    overflow: auto;
    background: #fff7f7;
}

.ncm-alert-list,
.ncm-alert-notes {
    display: grid;
    align-content: start;
    gap: 8px;
    min-width: 0;
}

.ncm-alert-item {
    display: grid;
    gap: 4px;
    padding: 11px 12px;
    border: 1px solid #fecaca;
    border-left: 5px solid #dc2626;
    border-radius: 7px;
    background: #fff;
}

.ncm-alert-item-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.ncm-alert-item-head strong {
    color: #111827;
    font-size: 14px;
}

.ncm-alert-status {
    flex: 0 0 auto;
    padding: 3px 8px;
    border-radius: 999px;
    background: #fee2e2;
    color: #991b1b;
    font-size: 10px;
}

.ncm-alert-description {
    margin: 0;
    color: #334155;
    font-size: 12px;
}

.ncm-alert-item small {
    color: #64748b;
    font-size: 11px;
}

.ncm-alert-products {
    display: grid;
    gap: 2px;
    margin: 2px 0;
    padding-left: 18px;
    color: #1f2937;
    font-size: 11px;
}

.ncm-alert-products li {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ncm-alert-link {
    justify-self: start;
    padding: 0;
    border: 0;
    background: transparent;
    color: #b91c1c;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 11px;
    font-weight: 400;
    text-decoration: none;
    cursor: pointer;
}

.ncm-alert-link:hover {
    text-decoration: underline;
}

.ncm-alert-notes h3 {
    margin: 0;
    color: #7f1d1d;
    font-size: 15px;
    font-weight: 400;
}

.ncm-alert-note {
    display: grid;
    gap: 3px;
    padding: 8px 9px;
    border: 1px solid #fecaca;
    border-radius: 7px;
    background: #fff7f7;
    color: #7f1d1d;
    font-size: 11px;
}

.ncm-alert-note strong {
    color: #991b1b;
}

.ncm-alert-empty {
    margin: 0;
    color: #64748b;
    font-size: 12px;
}

.ncm-alert-actions {
    justify-content: flex-end;
    border-top: 1px solid #fecaca;
    border-bottom: 0;
    background: #fff5f5;
}

.ncm-alert-actions .button.primary {
    border-color: #dc2626;
    background: #dc2626;
    color: #fff;
}

.ncm-adjust-card[hidden] { display: none !important; }
.ncm-adjust-card { position: absolute; z-index: 2; width: min(980px, calc(100vw - 72px)); height: min(680px, calc(100vh - 72px)); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; overflow: hidden; border: 2px solid #b91c1c; border-radius: 8px; background: #fff; box-shadow: 0 28px 65px rgba(69, 10, 10, 0.45); }
.ncm-adjust-head, .ncm-adjust-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; background: #991b1b; color: #fff; }
.ncm-adjust-head h2 { margin: 2px 0 0; color: #fff; font-size: 20px; font-weight: 400; }
.ncm-adjust-head .eyebrow { color: #fee2e2; }
.ncm-adjust-head .button { border-color: #fff; background: #fff; color: #991b1b; }
.ncm-adjust-content { display: grid; grid-template-rows: auto auto auto auto minmax(150px, 1fr) auto; gap: 9px; padding: 12px 14px; overflow: hidden; }
.ncm-adjust-current { margin: 0; color: #7f1d1d; font-size: 13px; }
.ncm-adjust-search label { display: block; margin-bottom: 4px; color: #334155; font-size: 11px; }
.ncm-adjust-search > div { display: flex; gap: 7px; }
.ncm-adjust-search input { flex: 1; min-width: 0; height: 34px; padding: 5px 8px; border: 1px solid #cbd5e1; border-radius: 5px; font: 12px Tahoma, Arial, sans-serif; }
.ncm-adjust-search small { display: block; margin-top: 4px; color: #475569; }
.ncm-adjust-results { max-height: 150px; overflow: auto; border: 1px solid #cbd5e1; border-radius: 5px; background: #fff; }
.ncm-adjust-result { display: block; width: 100%; padding: 7px 9px; border: 0; border-bottom: 1px solid #e2e8f0; background: #fff; color: #0f172a; font: 11px Tahoma, Arial, sans-serif; font-weight: 400; text-align: left; cursor: pointer; }
.ncm-adjust-result:hover { background: #eff6ff; }
.ncm-adjust-grid-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ncm-adjust-grid-head strong { color: #334155; font-size: 12px; font-weight: 400; }
.ncm-adjust-grid-head > div { display: flex; gap: 5px; }
.ncm-adjust-grid { min-height: 0; overflow: auto; border: 1px solid #cbd5e1; border-radius: 5px; }
.ncm-adjust-table { width: 100%; border-collapse: collapse; font-size: 11px; }
.ncm-adjust-table th { position: sticky; top: 0; z-index: 1; padding: 6px 7px; background: #e2e8f0; color: #334155; font-weight: 400; text-align: left; }
.ncm-adjust-table td { padding: 5px 7px; border-top: 1px solid #e2e8f0; color: #1f2937; }
.ncm-adjust-table tr.selected td { background: #fee2e2; }
.ncm-adjust-table th:first-child, .ncm-adjust-table td:first-child { width: 52px; text-align: center; }
.ncm-adjust-message { min-height: 16px; margin: 0; color: #b91c1c; font-size: 11px; }
.ncm-adjust-message.success { color: #166534; }
.ncm-adjust-actions { justify-content: flex-end; border-top: 1px solid #fecaca; background: #fff5f5; }
.ncm-adjust-actions .button.primary { border-color: #dc2626; background: #dc2626; color: #fff; }
.ncm-adjust-busy[hidden] { display: none !important; }
.ncm-adjust-busy { position: absolute; inset: 0; z-index: 4; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 20px; background: rgba(255, 255, 255, 0.88); color: #7f1d1d; font-size: 13px; text-align: center; }
.ncm-adjust-busy strong { font-weight: 400; }
.ncm-adjust-spinner { width: 34px; height: 34px; border: 4px solid #fecaca; border-top-color: #b91c1c; border-radius: 50%; animation: ncm-adjust-spin 0.75s linear infinite; }
@keyframes ncm-adjust-spin { to { transform: rotate(360deg); } }

@media (max-width: 760px) {
    .ncm-alert-modal {
        padding: 12px;
    }

    .ncm-alert-card {
        width: calc(100vw - 24px);
        height: calc(100vh - 24px);
    }

    .ncm-alert-body {
        grid-template-columns: 1fr;
    }
    .ncm-adjust-card { width: calc(100vw - 36px); height: calc(100vh - 36px); }
    .ncm-adjust-grid-head { align-items: flex-start; flex-direction: column; }
}

.row-actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}

.detail-meta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.detail-meta-card,
.detail-field-card {
    display: grid;
    gap: 3px;
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fffdfa;
}

.detail-meta-card span,
.detail-field-card span {
    color: var(--muted);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.detail-meta-card strong,
.detail-field-card strong {
    font-size: 13px;
    line-height: 1.25;
    font-weight: 500;
    word-break: break-word;
}

.detail-tabbar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.detail-tablink {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    appearance: none;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff7f1;
    font-size: 12px;
    font-weight: 600;
    color: #8f5d35;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.detail-tablink:hover,
.detail-tablink.is-active {
    background: #fbeadb;
}

.detail-tablink.is-active {
    border-color: #d59b6b;
    color: #7a3e14;
}

.detail-tab-panel-hidden {
    display: none;
}

.detail-group + .detail-group {
    margin-top: 16px;
}

.detail-group h3 {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 600;
}

.detail-fields-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 8px;
}

.detail-table-wrap {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.dfe-grid-wrap {
    max-height: 68vh;
    overflow: auto;
    border: 1px solid #d7c7b6;
    border-radius: 8px;
    background: #fffdfa;
}

.dfe-grid-table {
    min-width: 1320px;
}

.detail-item-row {
    cursor: pointer;
}

.detail-item-row:hover {
    background: #eef5ff !important;
}

.detail-item-row td:first-child {
    position: relative;
    padding-left: 22px;
}

.detail-item-row td:first-child::before {
    content: '+';
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 13px;
    font-weight: 700;
    color: #7a3e14;
}

.detail-item-row.is-open td:first-child::before {
    content: '-';
}

.detail-item-row.is-open td {
    border-bottom-color: #d59b6b;
    background: #fffaf4 !important;
}

.detail-item-subrow td {
    background: #fffdf8;
    padding: 7px;
    border-top: 0;
    border-bottom: 2px solid #d59b6b;
    box-shadow: inset 3px 0 0 #e8b182;
}

.detail-item-subpanel {
    display: grid;
    gap: 8px;
}

.detail-item-subsection h4 {
    margin: 0 0 6px;
    font-size: 12px;
    font-weight: 600;
}

.invoice-subrow td {
    padding-top: 0;
}

.invoice-subrow-error td {
    background: #fff1f1;
    border-top: 0;
    border-bottom: 1px solid #d98d8d;
}

.invoice-error-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    color: #7f1d1d;
    font-size: 10px;
    line-height: 1.3;
    padding: 4px 2px 6px;
}

.invoice-error-inline strong {
    text-transform: uppercase;
}

.invoice-error-inline form {
    margin: 0;
}

.compact-grid {
    width: 100%;
    table-layout: fixed;
}

.compact-grid th,
.compact-grid td {
    padding: 5px 7px;
    font-size: 11px;
}

.compact-grid tbody td {
    font-weight: 400;
}

.compact-grid .row-actions {
    gap: 4px;
}

.grid-nowrap {
    white-space: nowrap;
}

.grid-ellipsis {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.grid-col-date {
    width: 98px;
}

.grid-col-number {
    width: 51px;
}

.grid-col-emitter {
    width: 90px;
}

.grid-col-customer {
    width: 236px;
}

.grid-col-service {
    width: 119px;
}

.grid-col-status {
    width: 61px;
}

.grid-col-value {
    width: 64px;
}

.grid-col-actions {
    width: 249px;
}

.compact-grid .button.small,
.compact-grid .button {
    min-height: 24px;
    padding: 4px 7px;
    font-size: 10px;
}

.financial-panel {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.financial-filter-card,
.financial-card {
    padding: 0.55rem 0.65rem;
}

.financial-filters,
.financial-form-grid,
.financial-report-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(110px, 1fr));
    gap: 0.35rem 0.45rem;
    align-items: end;
}

.financial-filters {
    grid-template-columns:
        minmax(190px, 1.25fr)
        minmax(180px, 1.15fr)
        minmax(120px, 0.75fr)
        minmax(120px, 0.75fr)
        minmax(130px, 0.8fr)
        minmax(130px, 0.8fr);
}

.financial-filter-account,
.financial-filter-store,
.financial-filter-chart,
.financial-filter-source,
.financial-filter-search {
    min-width: 0;
}

.financial-filter-chart,
.financial-filter-source,
.financial-filter-search {
    grid-column: span 2;
}

.financial-filters > .button,
.financial-filters > a.button {
    min-width: 0;
}

.financial-filters label,
.financial-form-grid label,
.financial-report-grid label {
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
    margin: 0;
    font-size: 0.72rem;
    color: var(--muted);
}

.financial-filters input,
.financial-filters select,
.financial-form-grid input,
.financial-form-grid select,
.financial-report-grid input,
.financial-report-grid select {
    min-height: 1.85rem;
    padding-block: 4px;
}

.financial-form-grid .full {
    grid-column: 1 / -1;
}

.financial-report-grid {
    margin-bottom: 0.6rem;
}

.financial-report-grid label[hidden] {
    display: none;
}

.financial-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}

.financial-section-head h2 {
    margin: 0;
    font-size: 1rem;
}

.financial-section-head span {
    color: var(--muted);
    font-size: 0.8rem;
}

.financial-grid-wrap {
    max-height: 300px;
    overflow: auto;
}

.financial-movements-wrap {
    max-height: 320px;
}

.financial-chart-wrap {
    max-height: 360px;
}

.financial-chart-filters {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 150px 150px auto;
    align-items: end;
    gap: 6px;
    margin-bottom: 6px;
}

.financial-chart-filters label {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.financial-chart-filters input,
.financial-chart-filters select {
    width: 100%;
}

@media (max-width: 760px) {
    .financial-chart-filters {
        grid-template-columns: 1fr;
    }
}

.financial-payables-wrap {
    max-height: min(54vh, 590px);
}

.financial-small-wrap {
    max-height: 240px;
}

.financial-grid th,
.financial-grid td {
    white-space: nowrap;
}

.financial-grid td:nth-child(3),
.financial-grid td:nth-child(4) {
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.financial-grid tr.is-selected > td {
    background: rgba(18, 172, 160, 0.14);
}

.financial-grid tr.is-marked > td {
    background: #d8f1ee;
}

.financial-grid tr.is-selected.is-marked > td {
    background: #bfe7e2;
}

.financial-movements-grid {
    min-width: 1320px;
    table-layout: fixed;
}

.financial-movements-grid th,
.financial-movements-grid td {
    padding: 5px 7px;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

.financial-movements-grid tbody tr {
    cursor: pointer;
}

.financial-movements-grid tbody tr.is-cancelled td {
    color: #7d8792;
    text-decoration: line-through;
}

.financial-mov-col-date {
    width: 116px;
}

.financial-mov-col-company {
    width: 150px;
}

.financial-mov-col-account {
    width: 128px;
}

.financial-mov-col-type,
.financial-mov-col-status {
    width: 92px;
}

.financial-mov-col-history {
    width: 285px;
}

.financial-mov-col-chart {
    width: 190px;
}

.financial-mov-col-money {
    width: 92px;
}

.financial-mov-col-source {
    width: 112px;
}

.financial-payables-grid {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}

.financial-payables-grid th,
.financial-payables-grid td {
    padding: 5px 5px;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

.financial-pay-col-date {
    width: 72px;
}

.financial-pay-col-check {
    width: 36px;
}

.financial-pay-col-person {
    width: 185px;
}

.financial-pay-col-store {
    width: 110px;
}

.financial-pay-col-history {
    width: 200px;
}

.financial-pay-col-chart {
    width: 140px;
}

.financial-pay-col-account {
    width: 100px;
}

.financial-pay-col-money {
    width: 88px;
}

.financial-pay-col-status {
    width: 80px;
}

.financial-cell-stack {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 1px;
}

.financial-cell-stack strong,
.financial-cell-stack small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.financial-cell-stack strong {
    color: var(--text);
    font-size: 11px;
    line-height: 1.2;
}

.financial-cell-stack small {
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
    line-height: 1.1;
}

.financial-date-cell {
    font-weight: 800;
}

.financial-money-cell {
    text-align: right;
    font-variant-numeric: tabular-nums;
    font-weight: 800;
}

.financial-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 66px;
    min-height: 20px;
    padding: 2px 7px;
    border: 1px solid #cfdae3;
    border-radius: 999px;
    background: #f4f8fb;
    color: #34495a;
    font-size: 10px;
    font-weight: 900;
}

.financial-status-pill.is-open,
.financial-status-pill.is-scheduled {
    border-color: #c8d7e6;
    background: #eef6fb;
    color: #24445e;
}

.financial-status-pill.is-partially_paid {
    border-color: #f1c98e;
    background: #fff7e8;
    color: #8a4c12;
}

.financial-status-pill.is-paid {
    border-color: #b8dfd1;
    background: #e6f8f1;
    color: #146846;
}

.financial-status-pill.is-posted {
    border-color: #b8dfd1;
    background: #e6f8f1;
    color: #146846;
}

.financial-status-pill.is-pending {
    border-color: #f1c98e;
    background: #fff7e8;
    color: #8a4c12;
}

.financial-status-pill.is-cancelled,
.financial-status-pill.is-reversed {
    border-color: #e6b8b8;
    background: #fff0f0;
    color: #8f1d1d;
}

.financial-chart-row > td:first-child {
    box-shadow: inset 4px 0 0 #9aa8b4;
}

.financial-chart-row.is-revenue > td:first-child {
    box-shadow: inset 4px 0 0 #168a5a;
}

.financial-chart-row.is-expense > td:first-child {
    box-shadow: inset 4px 0 0 #d46c2f;
}

.financial-chart-level-1 > td {
    background: #edf3f6;
    font-weight: 800;
}

.financial-chart-level-2 > td {
    background: #f7fbfb;
    font-weight: 700;
}

.financial-chart-level-3 > td {
    background: #fff;
}

.financial-tree-toggle {
    width: 22px;
    min-width: 22px;
    height: 22px;
    margin-right: 5px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #f3f8fa;
    color: #233645;
    font-size: 14px;
    font-weight: 900;
    line-height: 1;
    cursor: pointer;
}

.financial-grid tr.is-selected > td {
    background: rgba(18, 172, 160, 0.14);
}

.financial-action-bar {
    margin-top: 0.55rem;
    flex-wrap: wrap;
}

.financial-dialog {
    width: min(760px, calc(100vw - 1.5rem));
    box-sizing: border-box;
    max-height: calc(100vh - 2rem);
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
    padding: 0.85rem;
    box-shadow: 0 18px 55px rgba(31, 36, 48, 0.26);
}

.financial-wide-dialog {
    width: min(980px, calc(100vw - 1.5rem));
}

.financial-report-view-dialog {
    width: min(1120px, calc(100vw - 1.5rem));
}

.financial-report-frame-wrap {
    height: min(76vh, 820px);
    min-height: 520px;
    border: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.financial-report-frame-wrap iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    background: #fff;
}

.financial-list-dialog {
    width: min(1080px, calc(100vw - 1.5rem));
}

.financial-payables-dialog {
    width: min(1460px, calc(100vw - 1.5rem));
    overflow-x: hidden;
}

.financial-reports-actions {
    margin-top: 0;
}

.financial-dialog-filters {
    grid-template-columns: 1fr 130px 130px minmax(170px, 1.2fr) auto auto;
    margin-bottom: 0.6rem;
}

.financial-payables-dialog .financial-dialog-filters {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    align-items: end;
    gap: 7px;
}

.financial-payable-filter-status,
.financial-payable-filter-store {
    grid-column: span 2;
}

.financial-payable-supplier-filter {
    grid-column: span 5;
}

.financial-payable-filter-date-type {
    grid-column: span 3;
}

.financial-payable-filter-date-from,
.financial-payable-filter-date-to,
.financial-payable-filter-amount-from,
.financial-payable-filter-amount-to,
.financial-payable-filter-search {
    grid-column: span 2;
}

.financial-payable-filter-submit,
.financial-payable-filter-clear {
    grid-column: span 1;
    width: 100%;
}

.financial-payable-supplier-filter span {
    display: grid;
    grid-template-columns: minmax(150px, 1fr) auto auto;
    gap: 5px;
}

.financial-payable-totals {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 7px;
    margin: 0.55rem 0;
}

.financial-movement-totals {
    display: grid;
    grid-template-columns: repeat(5, minmax(145px, 1fr));
    gap: 7px;
    margin: 0.45rem 0 0.55rem;
}

.financial-payable-totals span {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 6px 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f7fafb;
}

.financial-movement-totals span {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2px;
    padding: 6px 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f7fafb;
}

.financial-payable-totals small {
    color: var(--muted);
}

.financial-movement-totals small,
.financial-movement-totals em {
    color: var(--muted);
    font-style: normal;
}

.financial-movement-totals strong {
    font-size: 0.95rem;
}

.financial-payables-grid [data-payable-sort] {
    cursor: pointer;
    user-select: none;
}

.financial-payables-grid [data-payable-sort]::after {
    content: " ↕";
    color: var(--muted);
}

.financial-payables-grid [data-payable-sort].is-sort-asc::after {
    content: " ↑";
}

.financial-payables-grid [data-payable-sort].is-sort-desc::after {
    content: " ↓";
}

.financial-check-cell::before {
    content: "";
    display: block;
    width: 13px;
    height: 13px;
    margin: auto;
    border: 1px solid #76919c;
    border-radius: 3px;
    background: #fff;
}

.financial-payables-grid tr.is-marked .financial-check-cell::before {
    content: "✓";
    color: #fff;
    border-color: #148f85;
    background: #148f85;
    font-size: 10px;
    line-height: 12px;
    text-align: center;
}

.financial-dialog form,
.financial-dialog > div:not(.panel-head) {
    margin: 0;
}

.financial-dialog .panel-head {
    margin-bottom: 0.7rem;
}

.financial-dialog-actions {
    margin-top: 0.7rem;
}

.financial-pay-dialog {
    width: min(1120px, calc(100vw - 1.5rem));
}

.financial-movement-dialog {
    width: min(1120px, calc(100vw - 1.5rem));
}

.financial-movement-form-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    align-items: start;
    gap: 8px 10px;
    padding: 10px;
    border: 1px solid #d8e7f0;
    border-radius: 8px;
    background: #f8fbfd;
}

.financial-movement-form-grid .financial-movement-type {
    grid-column: 1 / span 2;
    grid-row: 1;
}

.financial-movement-form-grid .financial-movement-store {
    grid-column: 3 / span 3;
    grid-row: 1;
}

.financial-movement-form-grid .financial-movement-account {
    grid-column: 6 / span 4;
    grid-row: 1;
}

.financial-movement-form-grid .financial-movement-plan {
    grid-column: 1 / span 6;
    grid-row: 2;
}

.financial-movement-form-grid .financial-movement-date {
    grid-column: 10 / span 3;
    grid-row: 1;
}

.financial-movement-form-grid .financial-movement-competence {
    grid-column: 7 / span 2;
    grid-row: 2;
}

.financial-movement-form-grid .financial-movement-document {
    grid-column: 9 / span 2;
    grid-row: 2;
}

.financial-movement-form-grid .financial-movement-amount {
    grid-column: 11 / span 2;
    grid-row: 2;
}

.financial-movement-form-grid .financial-participant-field,
.financial-movement-form-grid .full {
    grid-column: 1 / -1;
}

.financial-movement-form-grid label {
    min-width: 0;
}

.financial-movement-form-grid input,
.financial-movement-form-grid select,
.financial-movement-form-grid .financial-combo-field > span {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.financial-movement-form-grid .financial-account-field small {
    display: block;
    min-height: 0;
    max-height: 2.5em;
    margin-top: 2px;
    overflow: hidden;
    line-height: 1.25;
}

.financial-movement-form-grid .financial-participant-field,
.financial-movement-form-grid > label.full {
    padding-top: 2px;
}

.financial-reconcile-grid {
    grid-template-columns: 130px 150px minmax(180px, 1fr);
}

.financial-pay-dialog .financial-form-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.financial-pay-dialog .financial-pay-account,
.financial-pay-dialog .financial-pay-chart {
    grid-column: span 2;
}

.financial-pay-dialog .financial-pay-money,
.financial-pay-dialog .financial-pay-date,
.financial-pay-dialog .financial-pay-total {
    grid-column: span 1;
}

.financial-payable-form-grid {
    grid-template-columns: repeat(8, minmax(90px, 1fr));
}

.financial-payable-form-grid .financial-payable-store-field,
.financial-payable-form-grid .financial-payable-plan-field {
    grid-column: 1 / -1;
}

.financial-payable-form-grid .financial-payable-account-field,
.financial-payable-form-grid .financial-payable-document-field,
.financial-payable-form-grid .financial-payable-amount-field {
    grid-column: span 2;
}

.financial-payable-form-grid .financial-payable-description-field {
    grid-column: span 4;
}

.financial-payable-form-grid .financial-payable-date-field {
    grid-column: span 2;
}

.financial-payable-form-grid .financial-payable-plan-field > span {
    grid-template-columns: minmax(260px, 1fr) auto;
}

.financial-payable-form-grid .financial-payable-plan-field select,
.financial-payable-form-grid .financial-payable-plan-field datalist {
    display: none;
}

.financial-pay-dialog select,
.financial-pay-dialog input {
    min-width: 0;
}

.financial-account-field small {
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1.25;
    min-height: 1.8rem;
    max-height: 2.7rem;
    overflow: hidden;
}

.financial-combo-field > span {
    display: grid;
    grid-template-columns: minmax(150px, 0.9fr) minmax(180px, 1.1fr) auto;
    gap: 0.4rem;
}

.financial-combo-field,
.financial-combo-field > span > * {
    min-width: 0;
}

.financial-chart-picker-grid tbody tr:not([hidden]) {
    cursor: pointer;
}

.financial-chart-picker-grid th,
.financial-chart-picker-grid td {
    overflow: hidden;
    text-overflow: ellipsis;
}

.financial-participant-field > span,
.financial-participant-search {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 0.4rem;
    align-items: center;
}

.financial-participant-search {
    grid-template-columns: 1fr auto;
    margin-bottom: 0.55rem;
}

.financial-participant-results-wrap {
    max-height: 320px;
}

.financial-selected-summary {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--secondary-soft);
    padding: 0.5rem 0.65rem;
    margin-bottom: 0.65rem;
    font-size: 0.88rem;
}

.financial-delete-reason {
    display: grid;
    gap: 0.25rem;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 700;
}

.financial-move-confirm {
    flex-direction: row !important;
    align-items: center;
    color: #9a3412 !important;
}

.financial-move-confirm input {
    width: auto;
    min-height: 0;
}

.financial-log-grid {
    min-width: 680px;
    table-layout: fixed;
}

.financial-log-grid th:nth-child(1),
.financial-log-grid td:nth-child(1) {
    width: 135px;
}

.financial-log-grid th:nth-child(2),
.financial-log-grid td:nth-child(2) {
    width: 105px;
}

.financial-log-grid th:nth-child(3),
.financial-log-grid td:nth-child(3) {
    width: 170px;
}

.financial-pay-total {
    align-self: end;
    min-height: 2rem;
    padding: 0.45rem 0.65rem;
    border: 1px solid #d8e7f0;
    border-radius: 7px;
    background: #f7fbfd;
    color: var(--text);
    font-size: 0.82rem;
    font-weight: 900;
}

.financial-empty-state {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.financial-empty-state span,
.financial-empty-row td {
    color: var(--muted);
}

@media (max-width: 980px) {
    .financial-filters,
    .financial-dialog-filters,
    .financial-form-grid,
    .financial-report-grid {
        grid-template-columns: repeat(2, minmax(120px, 1fr));
    }

    .financial-pay-dialog .financial-form-grid {
        grid-template-columns: repeat(2, minmax(120px, 1fr));
    }

    .financial-payables-dialog .financial-dialog-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .financial-payables-dialog .financial-dialog-filters > * {
        grid-column: span 1;
    }

    .financial-payables-dialog .financial-payable-supplier-filter,
    .financial-payables-dialog .financial-payable-filter-search {
        grid-column: 1 / -1;
    }

    .financial-payable-totals,
    .financial-movement-totals {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .financial-movement-form-grid .financial-movement-plan,
    .financial-movement-form-grid .financial-movement-type,
    .financial-movement-form-grid .financial-movement-store,
    .financial-movement-form-grid .financial-account-field,
    .financial-movement-form-grid .financial-movement-date,
    .financial-movement-form-grid .financial-movement-competence,
    .financial-movement-form-grid .financial-movement-document,
    .financial-movement-form-grid .financial-movement-amount {
        grid-column: span 2;
        grid-row: auto;
    }

    .financial-reconcile-grid {
        grid-template-columns: repeat(2, minmax(120px, 1fr));
    }

    .financial-pay-dialog .financial-pay-account,
    .financial-pay-dialog .financial-pay-chart,
    .financial-pay-dialog .financial-pay-total {
        grid-column: 1 / -1;
    }
}

@media (max-width: 640px) {
    .financial-filters,
    .financial-dialog-filters,
    .financial-form-grid,
    .financial-report-grid,
    .financial-combo-field > span,
    .financial-participant-field > span,
    .financial-participant-search {
        grid-template-columns: 1fr;
    }

    .financial-card {
        padding: 0.55rem;
    }

    .financial-pay-dialog .financial-form-grid {
        grid-template-columns: 1fr;
    }

    .financial-payables-dialog .financial-dialog-filters,
    .financial-payable-totals,
    .financial-movement-totals,
    .financial-payable-supplier-filter span {
        grid-template-columns: 1fr;
    }

    .financial-payables-dialog .financial-dialog-filters > * {
        grid-column: 1;
    }

    .financial-movement-form-grid .financial-movement-plan,
    .financial-movement-form-grid .financial-movement-type,
    .financial-movement-form-grid .financial-movement-store,
    .financial-movement-form-grid .financial-account-field,
    .financial-movement-form-grid .financial-movement-date,
    .financial-movement-form-grid .financial-movement-competence,
    .financial-movement-form-grid .financial-movement-document,
    .financial-movement-form-grid .financial-movement-amount {
        grid-column: span 1;
        grid-row: auto;
    }

    .financial-reconcile-grid {
        grid-template-columns: 1fr;
    }

    .financial-grid-wrap {
        max-height: 270px;
    }
}

.cash-management-hero {
    padding: 10px 12px;
    margin-bottom: 8px;
}

.cash-management-panel {
    padding: 10px 12px;
    margin-bottom: 8px;
}

.cash-management-panel .panel-head {
    margin-bottom: 7px;
}

.cash-management-panel .panel-head h2 {
    font-size: 16px;
}

.cash-management-panel .panel-head p {
    font-size: 11px;
}

.cash-management-stats {
    grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
    gap: 8px;
    margin-bottom: 0;
}

.cash-management-stats article {
    padding: 7px 9px;
    box-shadow: none;
}

.cash-management-stats strong {
    font-size: 15px;
}

.cash-management-stats span {
    font-size: 10px;
}

.cash-grid-wrap {
    min-height: 0;
    height: 180px;
    max-height: 260px;
    background: #fff;
}

.cash-grid-wrap-presales {
    height: 190px;
    max-height: 190px;
}

.cash-grid-wrap-active {
    height: 170px;
    max-height: 170px;
}

.cash-grid-wrap-closures {
    height: 190px;
    max-height: 190px;
}

.cash-grid-wrap-backoffice {
    height: 150px;
    max-height: 150px;
}

.cash-backoffice-table {
    min-width: 1160px;
}

.cash-management-table td strong {
    font-size: 11px;
}

.cash-management-table td small {
    color: var(--muted);
    font-size: 9px;
}

.cash-management-table {
    table-layout: fixed;
    min-width: 980px;
}

.cash-management-table th {
    white-space: nowrap;
}

.cash-management-table th,
.cash-management-table td {
    padding: 3px 6px;
    font-size: 10px;
}

.cash-management-table.vfp-grid thead th {
    background: #eef4f8;
    color: #34465f;
    border-color: #d5e3ee;
}

.cash-management-table.vfp-grid tbody tr:nth-child(even) {
    background: #f8fbfd;
}

.cash-management-table.vfp-grid tbody tr.is-selected,
.cash-management-table.vfp-grid tbody tr.is-selected:hover {
    background: #dff4f1;
    box-shadow: inset 3px 0 0 #22a89a;
}

.cash-management-table td {
    vertical-align: middle;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cash-management-table .cash-primary {
    display: inline-block;
    max-width: 100%;
    line-height: 1.2;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cash-management-table .cash-secondary {
    display: inline-block;
    margin-top: 2px;
    line-height: 1.2;
    color: var(--muted);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cash-management-table .cash-col-box {
    width: 120px;
}

.cash-management-table .cash-col-box .cash-primary {
    font-family: Consolas, "Courier New", monospace;
    font-weight: 700;
}

.cash-management-table .cash-col-operator {
    width: 150px;
}

.cash-management-table .cash-col-operator .cash-primary {
    font-weight: 500;
}

.cash-management-table .cash-col-date {
    width: 108px;
}

.cash-management-table .cash-col-count {
    width: 78px;
}

.cash-management-table .cash-col-money {
    width: 102px;
    white-space: nowrap;
}

.cash-management-table .cash-col-draft {
    width: 118px;
}

.cash-management-table .cash-actions-cell {
    width: 150px;
    white-space: nowrap;
}

.cash-grid-actions {
    align-items: center;
    border: 1px solid #e6792e;
    border-radius: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
    padding: 7px;
}

.cash-grid-actions .button {
    min-height: 28px;
    padding: 5px 10px;
}

.cash-grid-selection {
    margin-left: auto;
    text-align: right;
}

.cash-management-close-dialog {
    width: min(720px, calc(100vw - 28px));
}

.cash-session-preview-dialog {
    width: min(1120px, calc(100vw - 28px));
}

.cash-management-close-body {
    display: grid;
    gap: 12px;
}

.cash-session-preview-body {
    display: grid;
    gap: 10px;
    height: min(820px, calc(100vh - 42px));
    grid-template-rows: auto minmax(0, 1fr);
}

.cash-session-preview-body iframe {
    width: 100%;
    height: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.cash-management-close-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.cash-management-close-grid .span-2 {
    grid-column: span 2;
}

.cash-accounting-edit-status {
    margin-top: 10px;
    padding: 9px 11px;
    border: 1px solid #b8d5c0;
    border-radius: 7px;
    background: #f1faf3;
    color: #245c32;
    font-size: 12px;
}

.cash-accounting-audit-history {
    display: grid;
    gap: 4px;
    max-height: 112px;
    margin-top: 8px;
    padding: 8px 10px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fafafa;
    font-size: 11px;
}

.cash-accounting-audit-history span {
    display: block;
}

.cash-pre-sales-table th:nth-child(1),
.cash-pre-sales-table td:nth-child(1) {
    width: 78px;
}

.cash-pre-sales-table th:nth-child(2),
.cash-pre-sales-table td:nth-child(2) {
    width: 102px;
}

.cash-pre-sales-table th:nth-child(3),
.cash-pre-sales-table td:nth-child(3),
.cash-pre-sales-table th:nth-child(4),
.cash-pre-sales-table td:nth-child(4) {
    width: 155px;
}

.cash-pre-sales-table th:nth-child(5),
.cash-pre-sales-table td:nth-child(5),
.cash-pre-sales-table th:nth-child(8),
.cash-pre-sales-table td:nth-child(8) {
    width: 112px;
}

.cash-pre-sales-table th:nth-child(6),
.cash-pre-sales-table td:nth-child(6) {
    width: 52px;
}

.cash-pre-sales-table th:nth-child(7),
.cash-pre-sales-table td:nth-child(7) {
    width: 92px;
}

.cash-pre-sales-table th:nth-child(9),
.cash-pre-sales-table td:nth-child(9) {
    width: 94px;
}

.cash-management-table .stock-badge {
    white-space: normal;
    text-align: center;
}

.cash-draft-table {
    table-layout: auto;
}

.cash-draft-table th:nth-child(1),
.cash-draft-table td:nth-child(1) {
    width: 130px;
}

.cash-draft-table th:nth-child(3),
.cash-draft-table td:nth-child(3),
.cash-draft-table th:nth-child(4),
.cash-draft-table td:nth-child(4),
.cash-draft-table th:nth-child(5),
.cash-draft-table td:nth-child(5),
.cash-draft-table th:nth-child(6),
.cash-draft-table td:nth-child(6) {
    white-space: nowrap;
}

.cash-draft-table tr.cash-draft-removed {
    background: #f4efe8;
}

.cash-draft-table tr.cash-draft-removed td {
    position: relative;
    color: #8f8478;
    opacity: 0.72;
}

.cash-draft-table tr.cash-draft-removed td::after {
    content: '';
    position: absolute;
    left: 4px;
    right: 4px;
    top: 50%;
    border-top: 2px solid #de7a36;
    transform: rotate(-1deg);
}

.cash-draft-removed-note {
    color: #a12a31;
    font-weight: 700;
}

.cash-draft-open {
    margin-top: 6px;
}

.cash-draft-dialog {
    width: min(920px, calc(100vw - 28px));
}

.cash-draft-dialog-body {
    display: grid;
    gap: 14px;
    max-height: calc(100vh - 40px);
    overflow: auto;
}

.cash-closing-filter {
    display: grid;
    grid-template-columns: 170px 170px minmax(220px, 300px) auto;
    align-items: end;
    justify-content: start;
    margin-bottom: 8px;
    gap: 8px;
}

.cash-closing-terminal-filter {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.cash-closing-filter label {
    display: grid;
    gap: 4px;
    font-weight: 700;
    min-width: 0;
}

.cash-closing-filter input,
.cash-closing-filter select {
    width: 100%;
}

.cash-grid-sort {
    appearance: none;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: normal;
    cursor: pointer;
    text-transform: inherit;
}

.cash-grid-sort span {
    color: #718096;
    font-size: 9px;
}

.cash-grid-sort.is-active span {
    color: #e6782f;
}

.cash-closing-filter .button {
    min-width: 74px;
    align-self: end;
}

.cash-closures-table tbody tr[data-cash-closing-row] {
    cursor: pointer;
}

.cash-closures-table tbody tr[data-cash-closing-row].is-marked > td {
    background: #d8f1ee;
}

.cash-closures-table tbody tr[data-cash-closing-row].is-selected.is-marked > td {
    background: #bfe7e2;
}

.cash-backoffice-table tbody tr[data-cash-backoffice-row] {
    cursor: pointer;
}

.cash-closures-table tbody tr[data-cash-closing-row]:hover,
.cash-backoffice-table tbody tr[data-cash-backoffice-row]:hover {
    background: #fff4ec;
}

.cash-closing-dialog-card {
    max-height: calc(100vh - 42px);
    overflow: auto;
}

.cash-closing-inline-form {
    display: grid;
    gap: 8px;
    padding-top: 10px;
    border-top: 2px solid #d8e4e9;
}

.cash-closing-inline-form[hidden] {
    display: none;
}

.cash-closing-inline-head h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 400;
}

.cash-closing-inline-head p {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 11px;
}

.cash-closing-inline-form .cash-management-close-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px 12px;
}

.cash-closing-inline-form .cash-management-close-grid label {
    gap: 3px;
    font-size: 12px;
    font-weight: 400;
}

.cash-closing-inline-form .cash-management-close-grid input {
    min-height: 32px;
    padding: 5px 9px;
    font-size: 13px;
    font-weight: 400;
}

.cash-closing-inline-form .cash-management-close-grid .span-3 {
    grid-column: 1 / -1;
}

.cash-closing-inline-form .cash-closing-note-field input {
    min-height: 30px;
}

.cash-closing-inline-form .cash-accounting-audit-history {
    height: 82px;
    max-height: 82px;
    overflow-y: auto;
}

.pdv-close-contrast-cards article.is-result {
    border-width: 2px;
}

.pdv-close-contrast-cards article.is-result strong {
    font-size: 19px;
}

.pdv-close-contrast-table tfoot th {
    border-top: 2px solid #91adb9;
    background: #eef5f7;
    color: #132d3a;
    font-weight: 700;
    text-align: right;
}

.pdv-close-contrast-table tfoot th:first-child {
    text-align: left;
}

.pdv-close-contrast-table .cash-composition-view {
    min-height: 25px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 400;
}

.cash-composition-dialog {
    width: min(1440px, calc(100vw - 18px));
}

.cash-composition-dialog-body {
    display: grid;
    gap: 8px;
    max-height: calc(100vh - 42px);
    overflow: hidden;
}

.cash-composition-dialog-body .panel-head h2 {
    margin-bottom: 2px;
}

.cash-composition-dialog-body .panel-head p {
    margin: 0;
    font-size: 11px;
}

.cash-composition-table-wrap {
    max-height: min(560px, calc(100vh - 145px));
    overflow: auto;
    border: 1px solid #d8e4e9;
    border-radius: 8px;
}

.cash-composition-layout {
    display: grid;
    grid-template-columns: minmax(660px, 720px) minmax(0, 1fr);
    gap: 7px;
    min-height: 0;
}

.cash-composition-table {
    min-width: 650px;
    margin: 0;
    font-size: 11px;
    line-height: 1.15;
}

.cash-composition-table th,
.cash-composition-table td {
    padding: 3px 5px;
    white-space: nowrap;
}

.cash-composition-table th:nth-child(1),
.cash-composition-table td:nth-child(1) {
    width: 58px;
}

.cash-composition-table th:nth-child(2),
.cash-composition-table td:nth-child(2) {
    width: 68px;
}

.cash-composition-table th:nth-child(3),
.cash-composition-table td:nth-child(3) {
    width: 42px;
}

.cash-composition-table th:nth-child(4),
.cash-composition-table td:nth-child(4) {
    width: 54px;
}

.cash-composition-table .cash-col-money {
    width: 68px;
}

.cash-composition-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #eef5f7;
}

.cash-composition-table tfoot th {
    position: sticky;
    bottom: 0;
    z-index: 2;
    border-top: 2px solid #91adb9;
    background: #e3f0f3;
}

.cash-composition-table tbody tr {
    cursor: pointer;
}

.cash-composition-table tbody tr.is-selected > td {
    background: #ccebe6;
    color: #102f38;
}

.cash-composition-table tbody tr:focus {
    outline: 2px solid #e8752e;
    outline-offset: -2px;
}

.cash-composition-receipt {
    height: min(560px, calc(100vh - 145px));
    min-width: 0;
    overflow: auto;
    border: 1px solid #d8e4e9;
    border-radius: 8px;
    background: #edf2f4;
}

.cash-composition-receipt .pdv-sale-receipt-paper {
    width: min(100%, 560px);
    min-height: 100%;
    --pdv-receipt-font-size: 14.3px;
}

@media (max-width: 1080px) {
    .cash-composition-layout {
        grid-template-columns: 1fr;
    }

.cash-composition-receipt {
        height: 440px;
    }
}

@media (max-width: 760px) {
    .cash-closing-inline-form .cash-management-close-grid {
        grid-template-columns: 1fr;
    }

    .cash-closing-inline-form .cash-management-close-grid .span-3 {
        grid-column: auto;
    }
}

.cash-movements-dialog {
    width: min(1240px, calc(100vw - 24px));
}

.cash-movements-dialog-body {
    display: grid;
    gap: 8px;
    max-height: calc(100vh - 36px);
    overflow: hidden;
}

.cash-movements-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
}

.cash-movements-summary article,
.cash-movements-side article {
    border: 1px solid #d6e2ec;
    border-radius: 6px;
    background: #f8fbfd;
    padding: 6px 8px;
}

.cash-movements-summary span,
.cash-movements-side span,
.cash-movements-side small {
    display: block;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.2;
}

.cash-movements-summary strong,
.cash-movements-side strong {
    display: block;
    color: var(--text);
    font-size: 14px;
    line-height: 1.25;
    margin-top: 2px;
}

.cash-movements-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 310px;
    gap: 8px;
    min-height: 0;
}

.cash-movements-grid-wrap {
    height: min(460px, calc(100vh - 290px));
    min-height: 260px;
    background: #fff;
}

.cash-movements-table {
    table-layout: fixed;
    min-width: 980px;
}

.cash-movements-table th,
.cash-movements-table td {
    padding: 3px 6px;
    font-size: 10px;
    white-space: nowrap;
}

.cash-movements-table th {
    cursor: pointer;
    user-select: none;
}

.cash-movements-table td {
    overflow: hidden;
    text-overflow: ellipsis;
}

.cash-movements-table.vfp-grid tbody tr,
.cash-movements-table.vfp-grid tbody tr:nth-child(even) {
    background: #fff;
}

.cash-movements-table th:nth-child(1),
.cash-movements-table td:nth-child(1) {
    width: 48px;
    text-align: center;
}

.cash-movements-table th:nth-child(2),
.cash-movements-table td:nth-child(2) {
    width: 122px;
}

.cash-movements-table th:nth-child(3),
.cash-movements-table td:nth-child(3),
.cash-movements-table th:nth-child(4),
.cash-movements-table td:nth-child(4),
.cash-movements-table th:nth-child(7),
.cash-movements-table td:nth-child(7),
.cash-movements-table th:nth-child(8),
.cash-movements-table td:nth-child(8) {
    width: 92px;
}

.cash-movements-table th:nth-child(5),
.cash-movements-table td:nth-child(5) {
    width: 180px;
}

.cash-movements-table th:nth-child(6),
.cash-movements-table td:nth-child(6) {
    width: 270px;
}

.cash-movements-table tbody tr.is-marked,
.cash-movements-table tbody tr.is-marked:hover {
    box-shadow: inset 3px 0 0 #22a89a;
}

.cash-movements-table tbody tr.is-marked > td {
    background: #d8f1ee;
    font-weight: 700;
}

.cash-movements-table tbody tr.is-active,
.cash-movements-table tbody tr.is-active:hover {
    box-shadow: inset 4px 0 0 #d86716;
    font-weight: 700;
}

.cash-movements-table tbody tr.is-active > td {
    background: #ffd89c;
    font-weight: 700;
}

.cash-movements-table tbody tr.is-active.is-marked,
.cash-movements-table tbody tr.is-active.is-marked:hover {
    box-shadow: inset 4px 0 0 #0f766e;
    font-weight: 700;
}

.cash-movements-table tbody tr.is-active.is-marked > td {
    background: #ffc56f;
    font-weight: 700;
}

.cash-movements-table .cash-movement-group-row td {
    background: #eef4f8;
    border-top: 1px solid #b8cad8;
    border-bottom: 1px solid #b8cad8;
    color: #24384f;
    font-size: 11px;
    font-weight: 700;
    padding: 5px 7px;
}

.cash-movements-table .cash-movement-group-row span {
    color: var(--muted);
    font-size: 10px;
    font-weight: 400;
    margin-left: 8px;
}

.cash-movements-table .cash-movement-empty-row td {
    background: #fff;
    color: var(--muted);
    font-style: italic;
    padding: 6px 7px;
}

.cash-movement-check {
    color: #0f766e;
    font-weight: 700;
}

.cash-movements-side {
    display: grid;
    gap: 8px;
    align-content: start;
    max-height: min(460px, calc(100vh - 290px));
    overflow: auto;
    min-width: 0;
}

.cash-movements-side section {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.cash-movements-side h3 {
    margin: 0;
    font-size: 12px;
}

.cash-movements-side div {
    display: grid;
    gap: 5px;
}

.cash-movements-filter-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}

.cash-movements-filter-actions .button {
    min-height: 24px;
    padding: 3px 6px;
}

.cash-movements-filter-option {
    align-items: center;
    border: 1px solid #d6e2ec;
    border-radius: 6px;
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 6px;
    min-height: 25px;
    padding: 4px 6px;
    min-width: 0;
}

.cash-movements-filter-option input {
    height: 13px;
    margin: 0;
    width: 13px !important;
}

.cash-movements-filter-option span {
    color: var(--text);
    display: block;
    font-size: 10px;
    line-height: 1.2;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cash-movements-filter-option strong {
    display: block;
    font-size: 10px;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cash-movements-filter-option small {
    color: var(--muted);
    display: block;
    font-size: 9px;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 760px) {
    .cash-closing-filter {
        grid-template-columns: 1fr;
    }

    .cash-closing-filter .button {
        width: 100%;
    }

    .cash-management-close-grid {
        grid-template-columns: 1fr;
    }

    .cash-management-close-grid .span-2 {
        grid-column: auto;
    }

    .cash-grid-selection {
        width: 100%;
        margin-left: 0;
        text-align: left;
    }

    .cash-movements-dialog-body {
        overflow: auto;
    }

    .cash-movements-summary,
    .cash-movements-layout {
        grid-template-columns: 1fr;
    }

    .cash-movements-grid-wrap,
    .cash-movements-side {
        max-height: none;
    }
}

.compact-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
}

.dfe-grid-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    justify-content: flex-start;
}

[data-dfe-countdown] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    white-space: normal;
}

.dfe-filter-grid {
    grid-template-columns: repeat(16, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 8px;
}

.dfe-side-panels {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(420px, 1.7fr);
    gap: 12px;
}

.dfe-import-grid {
    grid-template-columns: minmax(220px, 1.6fr) minmax(180px, 1fr) 160px;
    gap: 8px;
    align-items: end;
    margin-bottom: 0;
}

.dfe-key-grid {
    grid-template-columns: minmax(380px, 1fr) 170px;
    gap: 8px;
    align-items: end;
    margin-bottom: 0;
}

.dfe-key-grid .full {
    grid-column: span 1;
}

.dfe-import-grid .full:first-child {
    grid-column: span 1;
}

.dfe-import-grid .full[data-dfe-import-status],
.dfe-import-grid [data-dfe-import-status] {
    grid-column: span 1;
    margin-bottom: 0;
}

.dfe-filter-grid .dfe-filter-value,
.dfe-filter-grid .dfe-filter-date,
.dfe-filter-grid .dfe-filter-number,
.dfe-filter-grid .dfe-filter-key {
    min-width: 0;
}

.dfe-filter-grid .dfe-filter-status,
.dfe-filter-grid .dfe-filter-show {
    min-width: 0;
}

.dfe-filter-grid .dfe-filter-submit {
    width: 100%;
}

@media (min-width: 861px) {
    .dfe-filter-grid .dfe-filter-issuer {
        grid-column: 1 / span 6;
    }

    .dfe-filter-grid .dfe-filter-number {
        grid-column: 7 / span 3;
    }

    .dfe-filter-grid .dfe-filter-key {
        grid-column: 10 / span 7;
    }

    .dfe-filter-grid .dfe-filter-date:nth-of-type(4) { grid-column: 1 / span 2; }
    .dfe-filter-grid .dfe-filter-date:nth-of-type(5) { grid-column: 3 / span 2; }
    .dfe-filter-grid .dfe-filter-value:nth-of-type(6) { grid-column: 5 / span 2; }
    .dfe-filter-grid .dfe-filter-value:nth-of-type(7) { grid-column: 7 / span 2; }
    .dfe-filter-grid .dfe-filter-manifestation { grid-column: 9 / span 2; }
    .dfe-filter-grid .dfe-filter-xml-status { grid-column: 11 / span 2; }
    .dfe-filter-grid .dfe-filter-show { grid-column: 13 / span 2; }
    .dfe-filter-grid .dfe-filter-submit { grid-column: 15 / span 2; align-self: end; min-width: 90px; }
}

.vfp-grid tbody tr {
    cursor: pointer;
}

.vfp-grid tbody tr:hover,
.vfp-grid tbody tr:focus {
    outline: none;
    background: #d9e8fb;
}

.vfp-grid {
    border: 1px solid #d7c7b6;
    background: #fffdfa;
}

.vfp-grid thead th {
    background: #eee3d7;
    color: #5b4d40;
    border-bottom: 1px solid #d2c0ae;
}

.vfp-grid tbody td {
    border-bottom: 1px solid #d8c6b5;
    border-right: 1px solid #efe3d8;
}

.vfp-grid tbody td:last-child,
.vfp-grid thead th:last-child {
    border-right: 0;
}

.vfp-grid tbody tr:nth-child(even) {
    background: #fbf6f0;
}

.vfp-grid tbody tr + tr td {
    border-top: 1px solid #ccb9a7;
}

.panel-head h3 {
    margin: 0 0 2px;
    font-size: 15px;
}

.panel-head h3 + p {
    margin: 0;
    font-size: 11px;
}

.documents-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    flex-wrap: wrap;
}

.vfp-grid tbody tr.invoice-row.status-issued,
table tbody tr.invoice-row.status-issued {
    background: #edf8ef;
}

.vfp-grid tbody tr.invoice-row.status-cancelled,
table tbody tr.invoice-row.status-cancelled {
    background: #fdeeee;
}

.vfp-grid tbody tr.invoice-row.status-queued,
table tbody tr.invoice-row.status-queued,
.vfp-grid tbody tr.invoice-row.status-draft,
table tbody tr.invoice-row.status-draft {
    background: #fff8dc;
}

.vfp-grid tbody tr.invoice-row.status-error,
table tbody tr.invoice-row.status-error {
    background: #ffdede;
}

.vfp-grid tbody tr.invoice-row.status-error td,
table tbody tr.invoice-row.status-error td {
    border-top-color: #d98d8d;
    border-bottom-color: #d98d8d;
}

.vfp-grid tbody tr.invoice-row:hover,
.vfp-grid tbody tr.invoice-row:focus,
table tbody tr.invoice-row:hover,
table tbody tr.invoice-row:focus {
    background: #d9e8fb;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.form-grid .full {
    grid-column: 1 / -1;
}

label {
    display: grid;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
}

.field-hint {
    color: var(--muted);
    font-size: 11px;
    font-weight: 400;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid #d8cabb;
    border-radius: 8px;
    padding: 8px 10px;
    font: inherit;
    background: #fff;
}

input:focus,
select:focus,
textarea:focus {
    outline: 2px solid rgba(217, 79, 4, 0.15);
    border-color: #df8a56;
}

.customer-entry-overlay {
    align-items: flex-start;
    padding: 8px;
}

.customer-entry-modal {
    width: min(960px, calc(100vw - 16px));
    max-height: calc(100vh - 16px);
    padding: 8px;
}

.customer-form-panel {
    margin-bottom: 0;
}

.customer-form-panel-modal {
    padding: 10px 12px;
}

.customer-form-head {
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.customer-form-head h1 {
    font-size: 20px;
    line-height: 1.15;
    font-weight: 600;
}

.customer-form-head p {
    margin-top: 2px;
    color: var(--muted);
    font-size: 12px;
}

.customer-form-head .button,
.customer-form-actions .button {
    font-weight: 400;
}

.customer-form-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px 10px;
}

.customer-form-grid label {
    gap: 4px;
    min-width: 0;
    font-weight: 400;
}

.customer-form-grid input,
.customer-form-grid select {
    min-height: 32px;
    border-radius: 7px;
    padding: 6px 8px;
}

.customer-form-wide {
    grid-column: span 2;
}

.customer-form-full {
    grid-column: 1 / -1;
}

.customer-checkbox-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px 10px;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px 10px;
    background: #fffdfa;
}

.customer-checkbox {
    display: flex;
    grid-template-columns: none;
    align-items: center;
    gap: 7px;
    min-height: 22px;
    font-weight: 400;
}

.customer-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.customer-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 2px;
}

.customer-addresses-panel {
    margin-top: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px;
    background: #fffdfa;
}

.customer-addresses-head {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
}

.customer-addresses-head h2,
.customer-address-dialog-head h2 {
    margin: 0;
    font-size: 15px;
    line-height: 1.2;
    font-weight: 600;
}

.customer-addresses-head p,
.customer-address-dialog-head p,
.customer-addresses-warning {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 11px;
}

.customer-addresses-warning {
    border: 1px solid #f3c796;
    border-radius: 7px;
    padding: 6px 8px;
    background: #fff7ed;
    color: #9a4b12;
}

.customer-addresses-grid-wrap {
    max-height: 150px;
    min-height: 92px;
}

.customer-addresses-grid th,
.customer-addresses-grid td {
    white-space: nowrap;
}

.customer-addresses-grid td:nth-child(3),
.customer-addresses-grid td:nth-child(7) {
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.customer-addresses-actions {
    margin-top: 6px;
}

.customer-addresses-actions form {
    display: inline-flex;
    margin: 0;
}

.customer-address-dialog {
    width: min(820px, calc(100vw - 24px));
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0;
    background: #fff;
    color: var(--text);
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.24);
}

.customer-address-dialog::backdrop {
    background: rgba(15, 23, 42, 0.48);
}

.customer-address-form {
    padding: 10px;
}

.customer-address-dialog-head,
.customer-address-dialog-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 8px;
    margin-bottom: 8px;
}

.customer-address-dialog-actions {
    justify-content: flex-end;
    border-top: 1px solid var(--line);
    border-bottom: 0;
    padding-top: 8px;
    padding-bottom: 0;
    margin-top: 8px;
    margin-bottom: 0;
}

.customer-address-form-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px 10px;
}

.customer-address-form-grid label {
    gap: 4px;
    min-width: 0;
    font-weight: 400;
}

.customer-address-form-grid input,
.customer-address-form-grid select {
    min-height: 32px;
    border-radius: 7px;
    padding: 6px 8px;
}

.customer-address-wide {
    grid-column: span 2;
}

.customer-address-default-check {
    align-self: end;
    min-height: 32px;
}

@media (max-width: 760px) {
    .customer-entry-overlay {
        padding: 6px;
    }

    .customer-entry-modal {
        width: calc(100vw - 12px);
        max-height: calc(100vh - 12px);
    }

    .customer-form-grid {
        grid-template-columns: 1fr;
    }

    .customer-form-wide,
    .customer-form-full {
        grid-column: 1 / -1;
    }

    .customer-checkbox-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .customer-address-form-grid {
        grid-template-columns: 1fr;
    }

    .customer-address-wide {
        grid-column: 1 / -1;
    }

    .customer-address-dialog-head,
    .customer-address-dialog-actions,
    .customer-addresses-actions {
        align-items: stretch;
        flex-wrap: wrap;
    }
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

th,
td {
    text-align: left;
    padding: 7px 8px;
    border-bottom: 1px solid #f0e6dc;
    vertical-align: top;
}

th {
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.error-dialog {
    width: min(720px, calc(100% - 24px));
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 0;
}

.error-dialog::backdrop {
    background: rgba(25, 20, 15, 0.5);
}

.error-dialog-body {
    padding: 18px;
}

.sales-presential-dialog {
    width: min(540px, calc(100% - 24px));
}

.sales-presential-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 12px;
}

.sales-presential-actions .button {
    min-width: 130px;
}

.error-dialog-message {
    margin: 0;
    white-space: pre-wrap;
    background: #fffdfa;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 14px;
    font: inherit;
}

.processing-dialog .error-dialog-message {
    font-weight: 700;
    color: #1f2430;
}

.processing-progress {
    margin-top: 12px;
    height: 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fffdfa;
    overflow: hidden;
}

.processing-progress-bar {
    width: 35%;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #d94f04 0%, #f08b4a 100%);
    animation: processing-progress-slide 1.2s ease-in-out infinite;
}

.processing-timer {
    margin-top: 10px;
    font-size: 12px;
    font-weight: 700;
    color: #8f5d35;
}

.processing-stage {
    margin-top: 10px;
    font-size: 12px;
    font-weight: 700;
    color: #b15317;
}

@keyframes processing-progress-slide {
    0% {
        transform: translateX(-110%);
    }
    100% {
        transform: translateX(310%);
    }
}

.whatsapp-float {
    position: fixed;
    right: 18px;
    bottom: 18px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #25d366;
    color: #fff;
    border-radius: 999px;
    padding: 8px 13px 8px 9px;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 12px 24px rgba(37, 211, 102, 0.28);
    z-index: 20;
    text-decoration: none;
}

.whatsapp-float img {
    display: block;
    width: 26px;
    height: 26px;
    object-fit: contain;
}

.whatsapp-float:hover,
.whatsapp-float:focus {
    background: #1fb85b;
    color: #fff;
    outline: 2px solid rgba(37, 211, 102, 0.28);
    outline-offset: 2px;
}

.site-footer {
    padding: 18px 0 26px;
}

.site-footer-inner {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    color: var(--muted);
    font-size: 12px;
}

.site-footer-inner a {
    color: var(--secondary);
}

.sales-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.sales-entry-modal,
.sales-create-panel-modal {
    overflow-x: hidden;
}

.sales-entry-overlay {
    align-items: flex-start;
    padding: 4px 8px;
}

.sales-entry-modal {
    width: min(1360px, calc(100vw - 16px));
    max-height: calc(100vh - 8px);
    height: auto;
    align-self: flex-start;
    padding: 6px;
}

.sales-create-panel-modal {
    padding: 8px 10px;
}

.sales-create-panel-modal .panel-head {
    margin-bottom: 4px;
}

.sales-create-panel-modal .panel-head h1 {
    font-size: 16px;
    line-height: 1.15;
    font-weight: 600;
}

.sales-create-panel-modal label,
.sales-create-panel-modal th,
.sales-create-panel-modal td,
.sales-create-panel-modal strong,
.sales-create-panel-modal .button,
.sales-create-panel-modal .sales-summary-card span,
.sales-create-panel-modal .sales-payment-summary-block span,
.sales-create-panel-modal .sales-payment-summary-inline strong,
.sales-create-panel-modal .sales-payment-summary-inline span {
    font-weight: 400;
}

.sales-create-panel-modal .sales-form-grid,
.sales-create-panel-modal .sales-items-panel,
.sales-create-panel-modal .sales-item-entry-grid,
.sales-create-panel-modal .sales-totals-strip,
.sales-create-panel-modal .sales-payments-panel {
    min-width: 0;
}

.sales-top-inline {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    column-gap: 16px;
}

.sales-top-main {
    grid-template-columns: 190px 190px minmax(360px, 1fr) 130px 130px;
    align-items: end;
    gap: 6px 12px;
}

.sales-top-main-remittance {
    grid-template-columns: 190px 190px 220px 130px 130px;
}

.sales-top-main label,
.sales-top-main input,
.sales-top-main select {
    min-width: 0;
    box-sizing: border-box;
}

.sales-top-main .sales-participant-field {
    grid-column: 3 / -1;
}

.sales-top-main-remittance .sales-participant-field {
    grid-column: 1 / -1;
}

.sales-operation-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 28px;
    padding: 5px 8px;
    border: 1px solid #cfe0ea;
    border-radius: 7px;
    background: #f7fbfd;
    color: #203042;
    line-height: 1.2;
}

.sales-operation-indicator span {
    padding: 2px 8px;
    border-radius: 999px;
    background: #e6f4fb;
    color: #0b4f6c;
}

.sales-operation-indicator.is-remittance span {
    background: #fff3dd;
    color: #8a4b00;
}

.sales-operation-indicator small,
.sales-payment-fiscal-note {
    color: #52677a;
}

.sales-payment-fiscal-note {
    margin-right: auto;
}

.sales-operation-purpose-field {
    width: 220px;
    max-width: 220px;
}

.sales-complex-panel {
    grid-template-columns: minmax(320px, 1fr) minmax(220px, 0.7fr);
    align-items: end;
    padding: 8px 10px;
    border: 1px solid #dbc8b6;
    border-radius: 8px;
    background: #fff8f1;
}

.sales-complex-note {
    min-height: 38px;
    padding: 7px 9px;
    border: 1px solid #efc59f;
    border-radius: 7px;
    background: #fff3e8;
    color: #31445c;
    line-height: 1.2;
}

.sales-complex-panel[hidden],
.sales-item-entry-grid [data-sale-complex-item-field][hidden] {
    display: none !important;
}

.sales-complex-note strong {
    display: block;
    font-size: 12px;
}

.sales-complex-note span {
    display: block;
    font-size: 11px;
}

.sales-top-customer {
    min-width: 0;
}

.sales-top-customer input {
    font-size: 0.88rem;
    font-weight: 400;
}

.sales-participant-field {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.sales-participant-field[hidden] {
    display: none !important;
}

.sales-participant-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 24px;
}

.sales-participant-caption {
    flex: 0 0 auto;
    color: var(--text);
    font-size: 12px;
    line-height: 1.1;
    font-weight: 400;
}

.sales-top-participant-actions {
    display: flex;
    gap: 4px;
    align-items: center;
    justify-content: flex-end;
    align-self: center;
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
    margin-left: 0;
    padding-top: 0;
}

.sales-top-participant-actions .button {
    flex: 0 0 auto;
    min-width: 0;
    min-height: 24px;
    padding: 4px 6px;
    line-height: 1.1;
    font-size: 0.68rem;
    text-align: center;
    white-space: nowrap;
}

.sales-top-carrier {
    display: grid;
    grid-template-columns: minmax(420px, 1fr) minmax(220px, 0.55fr);
    gap: 6px 12px;
    padding: 8px 10px;
    border: 1px solid #dbc8b6;
    border-radius: 8px;
    background: #fdf4ea;
    align-items: end;
}

.sales-top-carrier-search {
    min-width: 0;
}

.sales-top-carrier-actions {
    justify-content: flex-start;
}

.sales-transport-details {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) minmax(130px, 0.42fr) minmax(100px, 0.32fr) minmax(70px, 0.22fr);
    gap: 6px 12px;
    padding: 8px 10px;
    border: 1px solid #dbc8b6;
    border-radius: 8px;
    background: #fffaf4;
    align-items: end;
}

.sales-items-panel {
    display: grid;
    gap: 4px;
    padding: 8px 10px;
    border: 1px solid #dbc8b6;
    border-radius: 10px;
    background: #fdf7f0;
}

.sales-item-entry-grid {
    display: grid;
    grid-template-columns: minmax(150px, 0.86fr) minmax(280px, 2fr) minmax(70px, 0.38fr) minmax(86px, 0.52fr) minmax(86px, 0.52fr) minmax(92px, 0.48fr) minmax(120px, 0.72fr);
    gap: 6px;
    align-items: end;
    padding: 7px 8px;
    border: 1px solid #d8c4b1;
    border-radius: 8px;
    background: #fcf1e6;
}

.sales-item-entry-grid.is-complex {
    grid-template-columns: minmax(118px, 0.9fr) minmax(170px, 1.35fr) 58px 72px 68px 74px 82px 84px 82px 90px 74px 82px;
    gap: 5px;
}

.sales-item-entry-grid.is-complex label,
.sales-item-entry-grid.is-complex .sales-lookup-field label {
    min-width: 0;
}

.sales-item-entry-grid.is-complex input,
.sales-item-entry-grid.is-complex select {
    min-width: 0;
    padding-left: 5px;
    padding-right: 5px;
    font-size: 11px;
}

.sales-item-entry-grid.is-complex .sales-item-entry-description {
    min-width: 0;
}

.sales-item-entry-grid.is-complex .sales-item-entry-total-box {
    min-width: 0;
    padding-left: 6px;
    padding-right: 6px;
}

.sales-item-entry-grid.is-complex .sales-item-entry-actions .button {
    min-width: 0;
    padding-left: 7px;
    padding-right: 7px;
}

.sales-item-entry-grid label {
    gap: 4px;
    font-size: 11px;
}

.sales-item-entry-code {
    grid-column: span 1;
}

.sales-lookup-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
    align-items: end;
}

.sales-lookup-field label {
    min-width: 0;
}

.sales-lookup-field .button {
    min-height: 30px;
    padding: 5px 8px;
    white-space: nowrap;
}

.sales-item-entry-description {
    grid-column: span 1;
}

.sales-item-entry-total-box {
    display: grid;
    gap: 2px;
    align-self: stretch;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    min-width: 108px;
}

.sales-item-entry-total-box span {
    font-size: 11px;
    font-weight: 700;
    color: var(--muted);
}

.sales-item-entry-total-box strong {
    font-size: 13px;
    line-height: 1;
    color: var(--accent);
}

.sales-item-entry-actions {
    display: grid;
    gap: 3px;
    align-self: stretch;
}

.sales-items-grid-wrap {
    overflow: auto;
    max-width: 100%;
    max-height: 320px;
    padding: 2px;
    border: 1px solid #dccabc;
    border-radius: 8px;
    background: #fffdfb;
}

.sales-products-grid-wrap {
    height: 138px;
    max-height: 138px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
}

.sales-payments-panel {
    padding: 8px 10px 7px;
}

.sales-payments-panel .sales-items-grid-wrap {
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
}

.sales-items-grid {
    min-width: 870px;
}

.sales-items-grid th:nth-child(1),
.sales-items-grid td:nth-child(1) {
    width: 150px;
}

.sales-items-grid th:nth-child(2),
.sales-items-grid td:nth-child(2) {
    width: 310px;
}

.sales-items-grid th:nth-child(3),
.sales-items-grid td:nth-child(3) {
    width: 86px;
}

.sales-items-grid th:nth-child(4),
.sales-items-grid td:nth-child(4),
.sales-items-grid th:nth-child(5),
.sales-items-grid td:nth-child(5),
.sales-items-grid th:nth-child(6),
.sales-items-grid td:nth-child(6),
.sales-items-grid th:nth-child(7),
.sales-items-grid td:nth-child(7),
.sales-items-grid th:nth-child(8),
.sales-items-grid td:nth-child(8) {
    width: 92px;
}

.sales-items-grid th:nth-child(4),
.sales-items-grid td:nth-child(4) {
    width: 52px;
}

.sales-items-grid th:nth-child(5),
.sales-items-grid td:nth-child(5) {
    width: 70px;
}

.sales-grid-fiscal-cell {
    max-width: 86px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sales-payments-grid {
    min-width: 860px;
}

.sales-payments-grid th:nth-child(1),
.sales-payments-grid td:nth-child(1) {
    width: 190px;
}

.sales-payments-grid th:nth-child(2),
.sales-payments-grid td:nth-child(2) {
    width: 120px;
}

.sales-payments-grid th:nth-child(3),
.sales-payments-grid td:nth-child(3) {
    width: 100px;
}

.sales-payments-grid th:nth-child(4),
.sales-payments-grid td:nth-child(4) {
    width: 240px;
}

.sales-payments-grid th:nth-child(5),
.sales-payments-grid td:nth-child(5) {
    width: 160px;
}

.sales-payments-grid th:nth-child(6),
.sales-payments-grid td:nth-child(6) {
    width: 92px;
}

.sales-items-grid input,
.sales-items-grid select,
.sales-payments-grid input,
.sales-payments-grid select {
    min-height: 30px;
}

.sales-payment-details-box {
    display: grid;
    gap: 4px;
}

.sales-payment-details-box small {
    color: var(--muted);
    font-size: 11px;
}

.sales-payment-parcels-cell {
    display: grid;
    gap: 4px;
    align-content: start;
}

.sales-payment-installments-summary {
    color: var(--muted);
    font-size: 10px;
    line-height: 1.25;
}

.sales-payment-installments {
    display: grid;
    gap: 8px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fffdfa;
}

.sales-payment-installments-controls {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    align-items: end;
}

.sales-payment-installments-grid {
    display: grid;
    gap: 8px;
}

.sales-payment-installment-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.sales-volumes-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.sales-totals-strip {
    display: grid;
    grid-template-columns: minmax(118px, 0.72fr) minmax(98px, 0.54fr) minmax(118px, 0.64fr) minmax(118px, 0.64fr) minmax(112px, 0.58fr) minmax(112px, 0.58fr) minmax(126px, 0.62fr) minmax(128px, 0.64fr);
    gap: 5px;
    align-items: end;
    margin-top: 0;
}

.sales-totals-strip label {
    gap: 3px;
    font-size: 10px;
}

.sales-summary-card {
    display: grid;
    gap: 1px;
    padding: 5px 7px;
    border: 1px solid #d9c5b3;
    border-radius: 8px;
    background: #fdf0e5;
    min-height: 38px;
}

.sales-summary-card span {
    font-size: 9px;
    font-weight: 700;
    color: var(--muted);
}

.sales-summary-card strong {
    font-size: 12px;
    color: var(--accent);
}

.sales-summary-card-slim {
    background: #fffaf4;
}

.sales-summary-card-primary {
    background: #fde7d8;
    border-color: #e6bfa5;
}

.sales-disabled-field {
    opacity: 0.65;
}

.sales-disabled-field input:disabled,
.sales-disabled-field select:disabled,
.sales-disabled-field textarea:disabled {
    background: #f4efe8;
    color: #7a6e62;
    cursor: not-allowed;
}

.sales-volumes-toggle {
    margin-top: 0;
    max-width: none;
}

.sales-bottom-info {
    display: block;
    padding: 10px 12px;
    border: 1px solid #dccabc;
    border-radius: 8px;
    background: #fcf3ea;
}

.sales-notes-inline-action {
    display: grid;
    grid-template-columns: auto minmax(78px, 1fr);
    gap: 2px 5px;
    align-self: end;
    align-items: end;
}

.sales-notes-inline-action span {
    grid-column: 1 / -1;
    font-size: 10px;
    font-weight: 700;
    color: var(--muted);
}

.sales-notes-inline-action small {
    grid-column: 1 / -1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.sales-notes-box {
    display: block;
}

.sales-notes-box textarea {
    min-height: 108px;
}

.sales-installments-dialog {
    width: min(760px, calc(100vw - 32px));
}

.sales-lookup-dialog {
    width: min(1040px, calc(100vw - 28px));
}

.sales-lookup-dialog-card {
    max-height: calc(100vh - 32px);
    overflow: hidden;
    grid-template-rows: auto auto minmax(180px, 1fr) auto;
}

.sales-lookup-grid-wrap {
    height: 330px;
    min-height: 330px;
    max-height: 330px;
}

.sales-lookup-grid th,
.sales-lookup-grid td {
    padding-top: 5px;
    padding-bottom: 5px;
    line-height: 1.1;
}

.sales-lookup-grid tbody tr {
    cursor: pointer;
}

@media (max-width: 720px) {
    .sales-lookup-grid-wrap {
        height: 240px;
        min-height: 240px;
        max-height: 240px;
    }
}

.sales-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff7f1;
}

.sales-summary-row strong {
    font-size: 15px;
}

.sales-summary-row span {
    font-size: 18px;
    font-weight: 700;
    color: var(--accent);
}

.sales-change-row {
    margin-top: -4px;
}

.sales-hidden-items {
    display: none;
}

.sales-grid-actions {
    justify-content: flex-start;
    gap: 5px;
    flex-wrap: nowrap;
    align-items: center;
    margin-top: 0;
    margin-bottom: -1px;
}

.sales-payments-head {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.sales-payments-head > strong {
    margin-right: 4px;
}

.sales-payment-summary-inline {
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
}

.sales-payment-summary-inline span,
.sales-payment-summary-inline strong {
    font-size: 13px;
}

.sales-payment-actions {
    justify-content: flex-end;
}

.sales-items-panel .panel-head .button {
    flex-shrink: 0;
}

.sales-form-grid > .inline-actions.full {
    gap: 12px;
    margin-top: 4px;
}

.sales-inline-summary {
    display: inline-grid;
    gap: 1px;
    padding: 4px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fffaf4;
    margin-right: 2px;
}

.sales-inline-summary span {
    font-size: 8px;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .04em;
}

.sales-inline-summary strong {
    font-size: 11px;
    color: var(--accent);
}

.sales-payment-summary-row .sales-summary-row-values {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    width: 100%;
}

.sales-payment-summary-block {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 2px 0;
}

.sales-payment-summary-block span {
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
}

.sales-payment-summary-block strong {
    font-size: 15px;
    color: var(--accent);
}

.sales-payment-summary-block.is-missing strong {
    color: #9b5b14;
}

.disabled-link {
    opacity: 0.45;
    pointer-events: none;
    cursor: not-allowed;
    filter: grayscale(0.2);
}

.sales-items-grid tbody tr.is-selected {
    background: #d9e8fb !important;
}

.sales-items-grid tbody tr[draggable="true"] {
    cursor: grab;
}

.sales-items-grid tbody tr.is-dragging {
    opacity: 0.55;
}

.sales-items-grid tbody tr.is-drag-over {
    outline: 2px solid #e6772e;
    outline-offset: -2px;
}

.sales-items-grid tbody td {
    font-size: 12px;
    color: #2f2922;
    font-weight: 600;
}

.sales-create-panel-modal .sales-items-grid tbody td,
.sales-create-panel-modal .sales-inline-summary span,
.sales-create-panel-modal .sales-payment-summary-block span {
    font-weight: 400;
}

.sales-items-grid tbody td:nth-child(1),
.sales-items-grid tbody td:nth-child(3),
.sales-items-grid tbody td:nth-child(4),
.sales-items-grid tbody td:nth-child(5),
.sales-items-grid tbody td:nth-child(6),
.sales-items-grid tbody td:nth-child(7),
.sales-items-grid tbody td:nth-child(8) {
    white-space: nowrap;
}

.sales-list-row-closed {
    background: #eef8f1;
}

.sales-list-row-closed td {
    border-top-color: #cfe3d4;
    border-bottom-color: #cfe3d4;
}

.sales-list-row-closed:hover,
.sales-list-row-closed:focus {
    background: #d9e8fb !important;
}

.sales-list-hint {
    color: #2c6c49;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.sales-list-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}

.sales-col-user {
    width: 112px;
}

.sales-col-date {
    width: 106px;
}

.sales-col-pdv-doc {
    width: 72px;
}

.sales-col-participant {
    width: 222px;
    min-width: 222px;
}

.sales-col-document {
    width: 158px;
}

.sales-col-items {
    width: 44px;
}

.sales-col-total {
    width: 74px;
}

.sales-col-fiscal {
    width: 176px;
}

.sales-col-status {
    width: 86px;
}

.sales-list-grid-wrap th,
.sales-list-grid-wrap td {
    padding: 4px 7px;
    font-size: 11px;
    font-weight: 400;
    line-height: 1.15;
    vertical-align: middle;
}

.sales-list-grid-wrap th {
    font-size: 10px;
    font-weight: 700;
}

.sales-cell-user,
.sales-cell-date,
.sales-cell-pdv-doc,
.sales-cell-participant,
.sales-cell-document,
.sales-cell-fiscal,
.sales-cell-status {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.sales-cell-pdv-doc small {
    display: block;
    overflow: hidden;
    margin-top: 1px;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.05;
    text-overflow: ellipsis;
}

.sales-date-inline,
.sales-participant-name {
    font: inherit;
    white-space: nowrap;
}

.sales-cell-inline {
    display: inline;
    white-space: nowrap;
}

.sales-cell-inline-meta {
    font-size: 10px;
    line-height: 1;
    color: var(--muted);
    white-space: nowrap;
}

.sales-cell-helper {
    display: block;
    margin-top: 2px;
    font-size: 10px;
    line-height: 1.15;
    color: var(--muted);
}

.sales-cell-no-wrap {
    white-space: nowrap;
}

.sales-list-grid-wrap {
    min-height: 220px;
    height: min(360px, calc(100vh - 410px));
    overflow: auto;
}

.sales-list-grid-wrap .vfp-grid {
    table-layout: fixed;
    min-width: 100%;
}

.management-grid-wrap-visits {
    max-height: 420px;
    overflow: auto;
}

.sales-list-hint-inline {
    display: inline;
    margin: 0;
}

.sales-list-row {
    cursor: pointer;
}

.sales-list-row-no-movements td:first-child {
    box-shadow: inset 4px 0 0 #df7a28;
}

.sales-list-row-no-movements:not(.is-selected) {
    background: #fff5e8;
}

.sales-no-movements-badge {
    display: block;
    width: max-content;
    max-width: 100%;
    margin-top: 2px;
    padding: 1px 5px;
    overflow: hidden;
    border: 1px solid #d96b19;
    border-radius: 999px;
    background: #fff0df;
    color: #98440d;
    font-size: 8px;
    font-weight: 700;
    line-height: 1.15;
    text-overflow: ellipsis;
}

.sales-list-row.is-selected,
.sales-list-row.is-selected:hover,
.sales-list-row.is-selected:focus {
    background: #d9e8fb !important;
}

.sales-grid-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 10px;
    flex-wrap: wrap;
}

.sales-grid-toolbar-status {
    font-size: 12px;
    color: var(--muted);
    font-weight: 700;
}

.sales-grid-toolbar-status-wrap {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.sales-grid-toolbar-meta {
    font-size: 10px;
    color: var(--muted);
    line-height: 1.15;
}

.sales-grid-toolbar-actions {
    display: flex;
    gap: 10px 18px;
    flex-wrap: wrap;
    align-items: flex-start;
}

.sales-grid-toolbar-group {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}

.sales-grid-toolbar-group-commercial [data-sales-edit] {
    order: 10;
}

.sales-grid-toolbar-group-commercial [data-sales-reopen-form] {
    order: 11;
}

.sales-grid-toolbar-group-commercial [data-sales-delete-form] {
    order: 12;
}

.sales-grid-toolbar-group-commercial [data-sales-clone-form] {
    order: 13;
}

.sales-grid-toolbar-group-commercial [data-sales-convert-quote-form] {
    order: 14;
}

.sales-grid-toolbar-group-commercial [data-sales-payment-link] {
    order: 15;
}

.sales-grid-toolbar-group-fiscal [data-sales-assign-form] {
    order: 20;
}

.sales-grid-toolbar-group-fiscal [data-sales-issue-form="55"] {
    order: 21;
}

.sales-grid-toolbar-group-fiscal [data-sales-issue-form="65"] {
    order: 22;
}

.sales-grid-toolbar-group-fiscal [data-sales-cancel-form] {
    order: 23;
}

.sales-grid-toolbar-group-fiscal [data-sales-view-xml] {
    order: 24;
}

.sales-grid-toolbar-group-fiscal [data-sales-danfe] {
    order: 25;
}

.sales-grid-toolbar-group-fiscal [data-sales-email-trigger] {
    order: 26;
}

.sales-grid-toolbar-group-fiscal [data-sales-receipt] {
    order: 27;
}

.sales-grid-toolbar-group-fiscal [data-sales-email-receipt-trigger] {
    order: 28;
}

.sales-grid-toolbar-actions form {
    margin: 0;
    display: inline-flex;
}

.sales-grid-toolbar-actions button:disabled,
.sales-grid-toolbar-actions .button[aria-disabled="true"],
.sales-grid-toolbar-actions .disabled-link {
    opacity: 0.48;
    cursor: not-allowed;
    filter: grayscale(0.25);
}

.sales-grid-filters {
    display: grid;
    grid-template-columns: 132px 132px minmax(280px, 1fr) minmax(150px, 0.7fr) minmax(176px, 0.8fr) minmax(230px, 0.9fr);
    gap: 8px 12px;
    margin-bottom: 12px;
    align-items: end;
}

.sales-grid-filters label {
    display: grid;
    gap: 3px;
    font-size: 10.5px;
    font-weight: 800;
    color: var(--muted);
    text-transform: uppercase;
}

.sales-grid-filters input,
.sales-grid-filters select {
    width: 100%;
    min-height: 30px;
    font-size: 12px;
}

.sales-grid-filter-actions {
    display: flex;
    grid-column: 1 / -1;
    gap: 6px;
    align-items: end;
    justify-content: flex-start;
    white-space: nowrap;
}

.sales-grid-filter-actions .button {
    min-height: 30px;
    padding: 6px 9px;
}

@media (max-width: 1320px) {
    .sales-grid-filters {
        grid-template-columns: 132px 132px minmax(300px, 1fr) minmax(150px, 0.75fr);
    }

    .sales-grid-filters label:nth-of-type(5),
    .sales-grid-filters label:nth-of-type(6) {
        grid-column: span 2;
    }
}

@media (max-width: 980px) {
    .sales-grid-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sales-grid-filters label:nth-of-type(3),
    .sales-grid-filter-actions {
        grid-column: 1 / -1;
    }

    .sales-grid-filters label:nth-of-type(5),
    .sales-grid-filters label:nth-of-type(6) {
        grid-column: span 1;
    }
}

.sales-duplicate-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    margin-bottom: 12px;
    border: 1px solid #f1c6b7;
    border-radius: 8px;
    background: #fff0ea;
    flex-wrap: wrap;
}

.sales-duplicate-panel strong {
    display: block;
    margin-bottom: 2px;
    color: #9a3b1f;
}

.sales-duplicate-panel span {
    color: #8c3c21;
    font-size: 12px;
}

.sales-list-feedback-row td {
    padding: 0;
    border-top: 0;
    border-bottom: 1px solid #d8c6b5;
    background: #fffaf6;
}

.sales-list-feedback {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    padding: 8px 12px;
    font-size: 12px;
    line-height: 1.4;
}

.sales-list-feedback strong {
    color: #9a3b1f;
    white-space: nowrap;
}

.sales-list-feedback-error {
    background: #fff0ea;
    border-top: 1px solid #f1c6b7;
}

.sales-list-feedback-error span {
    color: #8c3c21;
}

.sales-list-feedback small {
    color: #9b6542;
    font-weight: 700;
    white-space: nowrap;
}

.sales-list-issue-form {
    margin: 0;
}

@media (max-width: 1280px) {
    .sales-item-entry-grid {
        grid-template-columns: minmax(130px, 0.95fr) minmax(220px, 1.8fr) repeat(3, minmax(72px, 0.5fr)) minmax(98px, 0.6fr);
    }

    .sales-item-entry-actions {
        grid-column: 1 / -1;
        grid-template-columns: minmax(150px, 220px) minmax(0, 1fr);
        align-items: center;
    }

    .sales-item-entry-actions .button {
        min-width: 0;
        padding: 8px 10px;
    }

    .sales-totals-strip {
        grid-template-columns: repeat(4, minmax(118px, 1fr));
    }
}

@media (max-width: 1180px) {
    .sales-entry-modal {
        padding: 6px;
    }

    .sales-top-inline,
    .sales-top-main {
        gap: 8px;
    }

    .sales-top-main {
        grid-template-columns: minmax(150px, 0.8fr) minmax(150px, 0.8fr) minmax(260px, 1.5fr) minmax(112px, 0.55fr) minmax(112px, 0.55fr);
    }

    .sales-top-main-remittance {
        grid-template-columns: minmax(150px, 0.75fr) minmax(150px, 0.75fr) minmax(170px, 0.85fr) minmax(112px, 0.55fr) minmax(112px, 0.55fr);
    }

    .sales-top-participant-actions {
        width: auto;
        padding-top: 0;
    }

    .sales-top-participant-actions .button {
        padding: 4px 6px;
        font-size: 0.62rem;
    }

    .sales-payments-grid {
        min-width: 760px;
    }
}

@media (max-width: 1040px) {
    .sales-top-main,
    .sales-top-main-remittance {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
    }

    .sales-top-main .sales-participant-field,
    .sales-top-main-remittance .sales-participant-field {
        grid-column: 1 / -1;
    }

    .sales-item-entry-grid {
        grid-template-columns: minmax(150px, 1fr) minmax(250px, 1.7fr) repeat(3, minmax(74px, 0.52fr)) minmax(100px, 0.65fr);
    }

    .sales-item-entry-actions {
        grid-column: 1 / -1;
        grid-template-columns: minmax(150px, 220px) minmax(0, 1fr);
        align-items: center;
    }

    .sales-items-grid {
        min-width: 760px;
    }
}

@media (max-width: 860px) {
    .gestor-shell {
        grid-template-columns: 1fr;
        padding-top: 46px;
    }

    .app-body.sidebar-collapsed .gestor-shell {
        grid-template-columns: 1fr;
    }

    .gestor-mobile-bar {
        position: fixed;
        top: 0;
        right: 0;
        left: 0;
        z-index: 70;
        display: flex;
        align-items: center;
        justify-content: space-between;
        min-height: 46px;
        padding: 6px 10px;
        border-bottom: 1px solid #d8e4ee;
        background: #f8fbff;
        box-shadow: 0 4px 14px rgba(16, 34, 36, 0.08);
    }

    .gestor-mobile-menu-button {
        display: inline-grid;
        grid-template-columns: 18px auto;
        align-items: center;
        gap: 8px;
        min-height: 32px;
        padding: 5px 10px;
        border: 1px solid #c7dde8;
        border-radius: 8px;
        background: #eef8fb;
        color: #102224;
        font: inherit;
        font-size: 12px;
        font-weight: 800;
    }

    .gestor-mobile-menu-button span {
        grid-column: 1;
        display: block;
        width: 18px;
        height: 2px;
        border-radius: 999px;
        background: currentColor;
    }

    .gestor-mobile-menu-button strong {
        grid-column: 2;
        grid-row: 1 / 4;
    }

    .gestor-mobile-title {
        min-width: 0;
        overflow: hidden;
        color: #102224;
        font-size: 13px;
        font-weight: 800;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .gestor-mobile-backdrop {
        position: fixed;
        inset: 0;
        z-index: 68;
        background: rgba(15, 24, 32, 0.46);
    }

    .app-body.gestor-mobile-menu-open {
        overflow: hidden;
    }

    .app-body.gestor-mobile-menu-open .gestor-mobile-backdrop {
        display: block;
    }

    .gestor-sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        z-index: 72;
        width: min(316px, calc(100vw - 34px));
        height: 100svh;
        max-height: none;
        transform: translateX(calc(-100% - 12px));
        transition: transform 0.18s ease;
        box-shadow: 10px 0 24px rgba(16, 34, 36, 0.18);
    }

    .app-body.gestor-mobile-menu-open .gestor-sidebar {
        transform: translateX(0);
    }

    .app-body.sidebar-collapsed .gestor-sidebar {
        align-items: stretch;
        padding: 10px 8px;
    }

    .app-body.sidebar-collapsed .gestor-brand {
        display: grid;
    }

    .app-body.sidebar-collapsed .gestor-nav,
    .app-body.sidebar-collapsed .gestor-sidebar-footer {
        display: grid;
    }

    .app-body.sidebar-collapsed .gestor-sidebar-toggle {
        width: auto;
        min-height: 28px;
        padding: 5px 8px;
        writing-mode: horizontal-tb;
    }

    .gestor-footer {
        display: none;
    }

    .app-body.sidebar-collapsed .gestor-footer {
        left: 0;
    }

    .gestor-footer-inner {
        flex-wrap: wrap;
        gap: 2px 8px;
        padding: 4px 8px;
    }

    .gestor-footer-inner span {
        min-height: 16px;
        padding: 0 6px;
        border-left: 0;
    }

    .gestor-footer-address {
        max-width: 100%;
    }

    .gestor-nav {
        grid-template-columns: 1fr;
    }

    .gestor-nav-label {
        grid-column: 1 / -1;
    }

    .gestor-main {
        padding: 10px 8px 20px;
    }

    .gestor-topbar {
        display: none;
    }

    .gestor-user {
        text-align: left;
    }

    .landing-hero,
    .landing-split,
    .landing-pdv-showcase,
    .landing-preview-metrics {
        grid-template-columns: 1fr;
    }

    .landing-split-text-right > :first-child,
    .landing-split-text-right > :last-child {
        order: initial;
    }

    .landing-hero,
    .landing-pdv-showcase,
    .site-body .landing-section {
        padding: 22px;
    }

    .landing-shot-frame {
        width: 100%;
        min-height: 0;
    }

    .landing-hero h1 {
        font-size: 23px;
    }

    .hero,
    .panel-head {
        flex-direction: column;
        align-items: stretch;
    }

    .form-grid,
    .filter-grid {
        grid-template-columns: 1fr;
    }

    .batch-actions-groups,
    .dfe-filter-grid,
    .dfe-side-panels,
    .dfe-import-grid,
    .dfe-key-grid {
        grid-template-columns: 1fr;
    }

    .auth-showcase,
    .auth-marketing,
    .platform-preview-grid,
    .media-card-grid,
    .company-help-grid,
    .certificate-required-hero {
        grid-template-columns: 1fr;
    }

    .auth-panel-compact,
    .auth-marketing {
        padding: 16px;
    }

    .product-summary-grid,
    .product-stock-layout,
    .product-form-grid,
    .sales-form-grid,
    .tax-profile-form-grid {
        grid-template-columns: 1fr;
    }

    .product-form-grid .product-form-wide,
    .product-form-grid .product-form-full {
        grid-column: span 1;
    }

    .product-sku-row {
        grid-template-columns: 1fr;
    }

    .product-special-grid {
        grid-template-columns: 1fr;
    }

    .sales-summary-row {
        flex-direction: column;
        align-items: stretch;
    }

    .sales-item-entry-grid {
        grid-template-columns: 1fr;
    }

    .sales-item-entry-code,
    .sales-item-entry-description {
        grid-column: span 1;
    }

    .sales-lookup-field {
        grid-template-columns: 1fr;
    }

    .sales-top-inline,
    .sales-top-main,
    .sales-top-carrier,
    .sales-transport-details,
    .sales-totals-strip,
    .sales-bottom-info,
    .sales-payment-installments-controls,
    .sales-payment-installment-row {
        grid-template-columns: 1fr;
    }

    .settings-grid,
    .settings-grid-compact,
    .company-fiscal-grid {
        grid-template-columns: 1fr;
    }

    .settings-pdv-scale-layout {
        grid-template-columns: 1fr;
    }

    .settings-launcher-grid {
        grid-template-columns: 1fr;
    }

    .settings-modal-card.is-open {
        width: calc(100vw - 18px);
        max-height: calc(100vh - 18px);
        padding: 12px;
    }

    .settings-modal-actions {
        flex-direction: column-reverse;
    }

    .sales-volumes-grid {
        grid-template-columns: 1fr;
    }

    .company-contact-box {
        flex-direction: column;
        align-items: stretch;
    }

    .pending-banner {
        flex-direction: column;
        align-items: stretch;
    }

    .compact-actions {
        width: 100%;
        justify-content: stretch;
    }

    .compact-actions > * {
        width: 100%;
    }

    [data-dfe-countdown] {
        min-width: 0;
    }

    .dfe-grid-actions {
        gap: 6px;
        align-items: stretch;
    }

    .dfe-grid-actions .button {
        flex: 1 1 140px;
        justify-content: center;
    }

    .vfp-grid {
        display: block;
        width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        white-space: nowrap;
    }

    .vfp-grid thead,
    .vfp-grid tbody,
    .vfp-grid tr {
        white-space: nowrap;
    }

    .sales-items-grid {
        min-width: 720px;
    }

    .sales-grid-filters {
        grid-template-columns: 1fr;
    }

    .sales-grid-filter-actions {
        justify-content: flex-start;
    }

    .sales-payments-grid {
        min-width: 640px;
    }

    .compact-grid th,
    .compact-grid td {
        padding: 4px 6px;
        font-size: 10px;
    }

    .compact-grid .row-actions {
        flex-wrap: nowrap;
    }

    .fuel-rates-toolbar {
        align-items: stretch;
    }

    .fuel-rates-search {
        min-width: 0;
        width: 100%;
    }

    .compact-grid .button.small,
    .compact-grid .button {
        min-height: 22px;
        padding: 3px 6px;
        font-size: 9px;
    }

    .invoice-error-inline {
        min-width: max-content;
    }

    .media-card img,
    .media-card-main img {
        height: 200px;
    }
}

.stock-document-form {
    display: grid;
    gap: 8px;
}

.stock-document-entry-dialog {
    width: min(1260px, calc(100vw - 32px));
}

.stock-document-entry-panel {
    margin: 0;
    border: 0;
    box-shadow: none;
}

.stock-document-entry-dialog::backdrop,
.stock-zero-dialog::backdrop,
.products-stock-documents-dialog::backdrop,
.products-tax-dialog::backdrop {
    background: rgba(14, 29, 43, 0.42);
}

.stock-documents-filter-bar {
    display: grid;
    grid-template-columns: minmax(210px, 1.35fr) repeat(5, minmax(110px, .7fr)) minmax(230px, 1.2fr) auto;
    gap: 7px;
    align-items: end;
    margin-bottom: 8px;
}

.stock-documents-filter-bar label,
.stock-zero-grid label {
    display: grid;
    gap: 3px;
    min-width: 0;
    color: var(--text);
    font-size: 10.5px;
    font-weight: 800;
}

.stock-documents-filter-bar input,
.stock-documents-filter-bar select,
.stock-zero-grid input,
.stock-zero-grid select {
    width: 100%;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fffefc;
    padding: 5px 7px;
    color: var(--text);
    font: inherit;
    font-size: 12px;
}

.stock-zero-dialog {
    width: min(760px, calc(100vw - 32px));
}

.stock-zero-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 10px;
}

.stock-zero-grid .full {
    grid-column: 1 / -1;
}

.stock-document-form-grid {
    display: grid;
    grid-template-columns: 150px minmax(170px, 1fr) 190px 190px 190px 190px;
    gap: 7px;
    align-items: end;
}

.stock-document-form-grid label,
.stock-document-fast-row label {
    display: grid;
    gap: 3px;
    min-width: 0;
    color: var(--text);
    font-size: 10.5px;
    font-weight: 800;
}

.stock-document-form-grid .wide,
.stock-document-fast-row .wide {
    grid-column: span 2;
}

.stock-supplier-picker {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
}

.stock-supplier-picker input[readonly] {
    background: #f6f9fb;
    cursor: pointer;
}

.stock-supplier-picker .button {
    min-height: 30px;
    padding: 5px 10px;
    font-size: 12px;
    white-space: nowrap;
}

.stock-document-form-grid input,
.stock-document-form-grid select,
.stock-document-fast-row input,
.stock-document-fast-row select {
    width: 100%;
    min-width: 0;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fffefc;
    padding: 5px 7px;
    color: var(--text);
    font: inherit;
    font-size: 12px;
}

.stock-document-fast-row {
    display: grid;
    grid-template-columns: minmax(150px, 220px) auto minmax(220px, 1fr) 86px 112px 96px 112px auto auto minmax(90px, auto);
    gap: 7px;
    align-items: end;
}

.stock-document-fast-row[data-stock-current-type="manual_entry"] .stock-import-trigger,
.stock-document-fast-row[data-stock-current-type="manual_entry"] [data-stock-import-status],
.stock-document-fast-row.is-manual-entry .stock-import-trigger,
.stock-document-fast-row.is-manual-entry [data-stock-import-status] {
    display: none !important;
}

.stock-document-fast-row[data-stock-current-type="manual_entry"],
.stock-document-fast-row.is-manual-entry {
    grid-template-columns: minmax(150px, 220px) auto minmax(220px, 1fr) 86px 112px 96px 112px auto;
}

.stock-manual-detail-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(130px, 1fr));
    gap: 7px;
    margin-top: 7px;
}

.stock-manual-detail-row label {
    display: grid;
    gap: 3px;
    min-width: 0;
    font-size: 10.5px;
    font-weight: 800;
}

.stock-manual-detail-row input {
    width: 100%;
    min-width: 0;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fffefc;
    padding: 5px 7px;
    color: var(--text);
    font: inherit;
    font-size: 12px;
}

.stock-manual-detail-row input[readonly] { background: #f6f9fb; }

@media (max-width: 900px) {
    .stock-manual-detail-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.stock-document-fast-row .stock-product-description-field input {
    background: #f6f9fb;
}

.stock-document-fast-row input[readonly] {
    background: #f6f9fb;
}

.stock-document-fast-row small {
    color: var(--muted);
    font-size: 9.5px;
    font-weight: 700;
    line-height: 1.1;
}

.stock-supplier-search-dialog .pdv-product-dialog-card {
    width: min(920px, calc(100vw - 40px));
}

.stock-supplier-search-grid-wrap {
    max-height: 360px;
}

.stock-supplier-search-grid th:nth-child(1),
.stock-supplier-search-grid td:nth-child(1) {
    width: 34%;
}

.stock-supplier-search-grid th:nth-child(2),
.stock-supplier-search-grid td:nth-child(2),
.stock-supplier-search-grid th:nth-child(3),
.stock-supplier-search-grid td:nth-child(3),
.stock-supplier-search-grid th:nth-child(4),
.stock-supplier-search-grid td:nth-child(4) {
    width: 16%;
}

.stock-import-trigger {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #eef8fb;
    cursor: pointer;
    white-space: nowrap;
}

.stock-import-trigger input {
    display: none;
}

.stock-document-import-status {
    color: var(--muted);
    font-size: 10.5px;
    font-weight: 800;
}

.stock-product-results {
    display: grid;
    max-height: 170px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.stock-supplier-results {
    grid-column: 1 / -1;
    display: grid;
    max-height: 150px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.stock-supplier-results[hidden] {
    display: none;
}

.stock-product-result {
    display: grid;
    gap: 2px;
    padding: 6px 8px;
    border: 0;
    border-bottom: 1px solid #e2edf5;
    background: transparent;
    text-align: left;
    cursor: pointer;
}

.stock-product-result:hover,
.stock-product-result:focus-visible {
    background: #eef7f8;
    outline: 0;
}

.stock-product-result strong {
    color: var(--text);
    font-size: 12px;
}

.stock-product-result span {
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
}

.stock-document-items-wrap {
    min-height: 220px;
    height: min(330px, calc(100vh - 430px));
    scroll-behavior: smooth;
}

.stock-document-items-grid {
    min-width: 1040px;
}

.stock-document-items-grid col.stock-doc-col-product {
    width: 27%;
}

.stock-document-items-grid col.stock-doc-col-code {
    width: 11%;
}

.stock-document-items-grid col.stock-doc-col-origin,
.stock-document-items-grid col.stock-doc-col-destination {
    width: 10%;
}

.stock-document-items-grid col.stock-doc-col-quantity,
.stock-document-items-grid col.stock-doc-col-cost,
.stock-document-items-grid col.stock-doc-col-price,
.stock-document-items-grid col.stock-doc-col-margin {
    width: 10%;
}

.stock-document-items-grid tbody tr[data-stock-item-row] {
    cursor: pointer;
}

.stock-document-items-grid tbody tr[data-stock-item-row].is-selected td {
    background: #dff5f2;
    box-shadow: inset 3px 0 0 var(--primary);
}

.stock-document-action-bar {
    margin-top: 0;
    padding: 7px;
}

.stock-draft-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f7fbfd;
    color: var(--text);
    font-size: 12px;
}

.stock-draft-strip span {
    color: var(--muted);
    font-size: 11px;
}

.stock-document-mode-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.stock-document-mode-bar span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}

.stock-document-transfer-warning {
    margin-top: 6px;
    padding: 7px 9px;
    border: 1px solid #fecaca;
    border-radius: 7px;
    background: #fff1f0;
    color: #a71922;
    font-size: 11px;
    font-weight: 700;
}

.stock-document-action-bar input {
    min-height: 30px;
    min-width: 240px;
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 5px 7px;
    font: inherit;
    font-size: 12px;
}

.stock-documents-list-wrap {
    min-height: 320px;
    height: min(460px, calc(100vh - 330px));
    max-height: none;
    overflow: auto;
}

.stock-documents-management-actions {
    margin-top: 0;
}

.stock-document-toolbar-form {
    display: contents;
}

.stock-documents-list-grid {
    min-width: 1040px;
}

.stock-documents-list-grid tbody tr[data-stock-document-row] {
    cursor: pointer;
}

.stock-documents-list-grid tbody tr.stock-document-status-draft,
.stock-documents-list-grid tbody tr.stock-document-status-draft:hover,
.stock-documents-list-grid tbody tr.stock-document-status-draft:focus,
.stock-documents-list-grid tbody tr.stock-document-status-draft.is-selected {
    background: #ffe3e3;
    box-shadow: inset 4px 0 #c62828;
}

.stock-documents-list-grid tbody tr.stock-document-status-draft td {
    border-top-color: #efaaaa;
    border-bottom-color: #efaaaa;
}

.stock-documents-list-grid tbody tr[data-stock-document-status="draft"],
.stock-documents-list-grid tbody tr[data-stock-document-status="draft"]:hover,
.stock-documents-list-grid tbody tr[data-stock-document-status="draft"]:focus,
.stock-documents-list-grid tbody tr[data-stock-document-status="draft"].is-selected {
    background: #ffd6d6 !important;
    box-shadow: inset 5px 0 #b71c1c !important;
}

.stock-documents-list-grid tbody tr[data-stock-document-status="draft"] td {
    border-top-color: #e58b8b !important;
    border-bottom-color: #e58b8b !important;
}

.stock-doc-list-col-id {
    width: 4.5%;
}

.stock-doc-list-col-type {
    width: 11%;
}

.stock-doc-list-col-number {
    width: 7%;
}

.stock-doc-list-col-company {
    width: 13%;
}

.stock-doc-list-col-store {
    width: 15%;
}

.stock-doc-list-col-supplier {
    width: 20%;
}

.stock-doc-list-col-items,
.stock-doc-list-col-status,
.stock-doc-list-col-date {
    width: 10%;
}

.stock-documents-list-grid th,
.stock-documents-list-grid td,
.stock-document-show-grid th,
.stock-document-show-grid td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stock-documents-list-grid small,
.stock-document-show-grid small,
.stock-document-items-grid small {
    display: block;
    color: var(--muted);
    font-size: 9.5px;
    font-weight: 700;
}

.stock-document-topline {
    padding-bottom: 3px;
    border-bottom: 1px solid var(--line);
}

.stock-document-print-actions form {
    display: contents;
}

@media print {
    header,
    nav,
    .sidebar,
    .stock-document-print-actions,
    .compact-actions {
        display: none !important;
    }

    body {
        background: #fff !important;
    }

    .panel {
        box-shadow: none !important;
        border-color: #ccc !important;
    }
}

@media (max-width: 1180px) {
    .stock-document-form-grid,
    .stock-document-fast-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .stock-document-form-grid .wide,
    .stock-document-fast-row .wide {
        grid-column: 1 / -1;
    }
}

.accounting-dashboard-panel .products-actions form {
    display: contents;
}

.accounting-dashboard-panel {
    min-height: 0;
    margin-bottom: 10px;
    padding: 10px 12px;
}

.accounting-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 14px;
}

.accounting-summary-grid article {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    padding: 12px;
}

.accounting-summary-grid strong {
    display: block;
    color: var(--ink);
    font-size: 1.35rem;
}

.accounting-summary-grid span {
    display: block;
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.3;
}

.accounting-events-grid-wrap {
    min-height: 0;
    height: auto;
    max-height: 360px;
}

.accounting-events-grid,
.accounting-numbering-grid {
    min-width: 1120px;
}

.accounting-events-grid {
    min-width: 0;
    table-layout: fixed;
}

.accounting-events-grid th:nth-child(1),
.accounting-events-grid td:nth-child(1) {
    width: 122px;
}

.accounting-events-grid th:nth-child(2),
.accounting-events-grid td:nth-child(2) {
    width: 78px;
}

.accounting-events-grid th:nth-child(3),
.accounting-events-grid td:nth-child(3) {
    width: 96px;
}

.accounting-events-grid th:nth-child(4),
.accounting-events-grid td:nth-child(4) {
    width: 118px;
}

.accounting-events-grid th:nth-child(5),
.accounting-events-grid td:nth-child(5) {
    width: 230px;
}

.accounting-events-grid th:nth-child(6),
.accounting-events-grid td:nth-child(6) {
    width: 88px;
}

.accounting-events-grid th:nth-child(7),
.accounting-events-grid td:nth-child(7) {
    width: 88px;
}

.accounting-events-grid th:nth-child(8),
.accounting-events-grid td:nth-child(8) {
    width: auto;
}

.accounting-events-grid td:nth-child(8) {
    white-space: normal;
    line-height: 1.25;
    overflow: visible;
    text-overflow: clip;
}

.accounting-numbering-grid-wrap {
    min-height: 0;
    height: auto;
    max-height: 190px;
}

.accounting-reservations-grid-wrap {
    min-height: 0;
    height: auto;
    max-height: 260px;
}

.accounting-numbering-panel .settings-card-head {
    margin-bottom: 8px;
}

.accounting-numbering-panel .settings-card-head p {
    margin-bottom: 0;
}

.accounting-reservation-summary {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 12px;
}

.accounting-reservation-summary span {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fbfd;
    padding: 7px 9px;
}

.accounting-reservations-grid {
    min-width: 0;
    table-layout: fixed;
}

.accounting-reservations-grid th:nth-child(1),
.accounting-reservations-grid td:nth-child(1) {
    width: 118px;
}

.accounting-reservations-grid th:nth-child(2),
.accounting-reservations-grid td:nth-child(2) {
    width: 64px;
}

.accounting-reservations-grid th:nth-child(3),
.accounting-reservations-grid td:nth-child(3) {
    width: 80px;
}

.accounting-reservations-grid th:nth-child(4),
.accounting-reservations-grid td:nth-child(4) {
    width: 130px;
}

.accounting-reservations-grid th:nth-child(5),
.accounting-reservations-grid td:nth-child(5) {
    width: 70px;
}

.accounting-reservations-grid th:nth-child(6),
.accounting-reservations-grid td:nth-child(6) {
    width: 150px;
}

.accounting-reservations-grid th:nth-child(7),
.accounting-reservations-grid td:nth-child(7) {
    width: 92px;
}

.accounting-reservations-grid th:nth-child(8),
.accounting-reservations-grid td:nth-child(8) {
    width: 230px;
}

[data-accounting-selectable-row] {
    cursor: pointer;
}

.accounting-reservation-rejected td {
    background: #fff1f1;
    color: #7f1d1d;
}

.accounting-rejection-action {
    font-weight: 800;
}

.accounting-provider-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.accounting-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.accounting-provider-grid .accounting-form-actions {
    grid-column: 1 / -1;
}

.accounting-filter-bar {
    display: grid;
    grid-template-columns: minmax(130px, 1fr) minmax(160px, 1.15fr) minmax(80px, .55fr) minmax(110px, .7fr) minmax(110px, .7fr) auto;
    gap: 10px;
    align-items: end;
    margin-bottom: 12px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fbfd;
}

.accounting-filter-bar label {
    display: grid;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--muted);
}

.accounting-filter-actions {
    display: flex;
    gap: 8px;
}

.accounting-break-form {
    display: grid;
    grid-template-columns: auto minmax(90px, .8fr) minmax(70px, .5fr) minmax(100px, .7fr) minmax(100px, .7fr) minmax(210px, 1.3fr) minmax(160px, 1fr) auto;
    gap: 8px;
    align-items: end;
    margin-top: 10px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fbfd;
}

.accounting-break-form strong {
    align-self: center;
    white-space: nowrap;
}

.accounting-break-form label {
    display: grid;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--muted);
}

.accounting-events-wrap {
    max-height: 520px;
}

.accounting-progress {
    border: 1px solid #f07c2f;
    border-radius: 6px;
    margin-top: 10px;
    padding: 10px 12px;
    background: #fff8f3;
}

.accounting-progress-head {
    align-items: center;
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.accounting-progress-track {
    background: #f2d8c8;
    border-radius: 999px;
    height: 8px;
    overflow: hidden;
}

.accounting-progress-track span {
    background: #df762f;
    display: block;
    height: 100%;
    transition: width 160ms ease;
    width: 0;
}

.accounting-progress p {
    margin: 8px 0 0;
}

.accounting-row-processing td {
    background: #fff4df !important;
    box-shadow: inset 0 1px 0 #f0a85a, inset 0 -1px 0 #f0a85a;
}

.accounting-access-key {
    max-width: 210px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 1180px) {
    .accounting-summary-grid,
    .accounting-provider-grid,
    .accounting-filter-bar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .accounting-filter-actions,
    .accounting-provider-grid .accounting-form-actions {
        grid-column: 1 / -1;
    }

    .accounting-break-form {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .accounting-break-form strong {
        grid-column: 1 / -1;
    }
}
.nfe-return-panel {
    max-width: 1640px;
    margin: 0 auto 12px;
}

.nfe-return-import {
    grid-template-columns: minmax(260px, 1fr) auto;
    align-items: end;
}

.nfe-return-filter {
    grid-template-columns: 180px minmax(300px, 1fr) auto auto;
    align-items: end;
    margin-bottom: 8px;
}

.nfe-return-inline-action {
    margin: 0;
    display: contents;
}

.nfe-return-grid-wrap {
    height: 360px;
}

.nfe-return-grid td,
.nfe-return-grid th,
.nfe-return-items-grid td,
.nfe-return-items-grid th {
    white-space: nowrap;
}

.nfe-return-grid th:nth-child(1),
.nfe-return-grid td:nth-child(1) {
    width: 110px;
}

.nfe-return-grid th:nth-child(2),
.nfe-return-grid td:nth-child(2) {
    width: 260px;
}

.nfe-return-grid th:nth-child(3),
.nfe-return-grid td:nth-child(3) {
    width: 112px;
}

.nfe-return-grid th:nth-child(4),
.nfe-return-grid td:nth-child(4) {
    width: 330px;
}

.nfe-return-grid th:nth-child(5),
.nfe-return-grid td:nth-child(5) {
    width: 140px;
}

.nfe-return-grid th:nth-child(6),
.nfe-return-grid td:nth-child(6) {
    width: 160px;
}

.nfe-return-grid th:nth-child(7),
.nfe-return-grid td:nth-child(7) {
    width: 52px;
    text-align: center;
}

.nfe-return-grid th:nth-child(8),
.nfe-return-grid td:nth-child(8) {
    width: 82px;
}

.nfe-return-grid th:nth-child(9),
.nfe-return-grid td:nth-child(9) {
    width: 86px;
}

.nfe-return-issued-key {
    display: block;
    max-width: 44ch;
    overflow: visible;
    font-size: 10px;
    line-height: 1.12;
}

.nfe-return-grid tr,
.nfe-return-items-grid tr {
    cursor: pointer;
}

.nfe-return-grid.vfp-grid tbody tr:nth-child(even),
.nfe-return-items-grid.vfp-grid tbody tr:nth-child(even) {
    background: #fffdfa;
}

.nfe-return-grid.vfp-grid tbody tr:hover,
.nfe-return-grid.vfp-grid tbody tr:focus,
.nfe-return-items-grid.vfp-grid tbody tr:hover,
.nfe-return-items-grid.vfp-grid tbody tr:focus {
    background: #eef7f8;
}

.nfe-return-grid.vfp-grid tbody tr.is-selected,
.nfe-return-grid.vfp-grid tbody tr.is-selected:hover,
.nfe-return-grid.vfp-grid tbody tr.is-selected:focus,
.nfe-return-items-grid.vfp-grid tbody tr.is-selected,
.nfe-return-items-grid.vfp-grid tbody tr.is-selected:hover,
.nfe-return-items-grid.vfp-grid tbody tr.is-selected:focus {
    background: #dff5f2 !important;
    box-shadow: inset 4px 0 0 var(--primary);
}

.nfe-return-grid.vfp-grid tbody tr.is-selected td,
.nfe-return-items-grid.vfp-grid tbody tr.is-selected td {
    color: #061b24;
}

.nfe-return-modal {
    width: min(94vw, 1180px);
    max-height: 92vh;
    height: auto;
    min-height: 0;
    overflow: auto;
}

.nfe-return-overlay {
    align-items: flex-start;
}

.nfe-return-title-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 34px;
    margin-bottom: 6px;
    padding: 5px 8px;
    border: 1px solid #c7d9e7;
    border-radius: 7px;
    background: #eef7fb;
    color: #0f2533;
}

.nfe-return-title-main {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 7px;
    min-width: 0;
}

.nfe-return-title-main strong {
    font-size: 13px;
    line-height: 1.15;
    white-space: nowrap;
}

.nfe-return-title-main span {
    min-width: 0;
    overflow: hidden;
    color: var(--muted);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nfe-return-title-side {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 11px;
    white-space: nowrap;
}

.nfe-return-title-side span {
    color: var(--muted);
}

.nfe-return-title-side strong {
    color: #0f2533;
    font-size: 11px;
    font-weight: 600;
}

.nfe-return-title-side .button {
    min-height: 26px;
    padding: 4px 9px;
}

.nfe-return-summary {
    margin-bottom: 4px;
    padding: 4px 8px;
}

.nfe-return-summary .purchase-xml-fact em,
.nfe-return-summary .purchase-xml-fact strong,
.nfe-return-summary .purchase-xml-fact small {
    font-weight: 400;
}

.nfe-return-summary .purchase-xml-facts {
    gap: 2px 12px;
}

.nfe-return-summary .purchase-xml-fact {
    min-height: 16px;
}

.nfe-return-summary .purchase-xml-fact em {
    font-size: 8px;
}

.nfe-return-summary .purchase-xml-fact strong {
    font-size: 11px;
}

.nfe-return-summary .purchase-xml-note-title strong {
    font-size: 12px;
}

.nfe-return-summary .purchase-xml-note-title small {
    font-size: 9px;
}

.nfe-return-note {
    margin-top: 4px;
    color: #8a3b04;
    background: #fff6ed;
    border: 1px solid #f0c8a8;
    border-radius: 6px;
    padding: 5px 8px;
    font-size: 11px;
    line-height: 1.2;
}

.nfe-return-note-error {
    color: #9b2c12;
    background: #fff3ef;
    border-color: #f4b5a6;
}

.nfe-return-totals-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 1px 14px;
    margin-top: 3px;
}

.nfe-return-totals-strip span {
    display: inline-flex;
    gap: 4px;
    align-items: baseline;
    padding: 0;
    border: 0;
    background: transparent;
}

.nfe-return-totals-strip em {
    color: var(--muted);
    font-size: 8px;
    font-style: normal;
    font-weight: 400;
    text-transform: uppercase;
}

.nfe-return-totals-strip strong {
    font-size: 11px;
    font-weight: 400;
}

.nfe-return-issued-info-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 14px;
    margin-top: 4px;
    padding: 5px 8px;
    border: 1px solid #b9e3d8;
    border-radius: 6px;
    background: #eefbf7;
    color: #0f3b34;
}

.nfe-return-issued-info-strip span {
    display: inline-flex;
    gap: 4px;
    align-items: baseline;
    min-width: 0;
}

.nfe-return-issued-info-strip em {
    color: #46655f;
    font-size: 8px;
    font-style: normal;
    font-weight: 400;
    text-transform: uppercase;
}

.nfe-return-issued-info-strip strong {
    font-size: 11px;
    font-weight: 500;
}

.nfe-return-issued-info-key {
    flex: 1 1 390px;
}

.nfe-return-issued-info-key strong {
    word-break: break-all;
}

.nfe-return-modal label,
.nfe-return-modal input,
.nfe-return-modal select,
.nfe-return-modal textarea {
    font-weight: 400;
}

.nfe-return-email-field {
    min-width: 260px;
    max-width: 340px;
}

.nfe-return-email-field input {
    min-width: 260px;
}

.nfe-return-items-form.is-issued input:disabled,
.nfe-return-items-form.is-issued select:disabled,
.nfe-return-items-form.is-issued textarea:disabled,
.nfe-return-items-form.is-readonly input:disabled,
.nfe-return-items-form.is-readonly select:disabled,
.nfe-return-items-form.is-readonly textarea:disabled {
    color: #334155;
    opacity: 1;
    background: #f7fafc;
}

.nfe-return-create-modal,
.nfe-return-delete-modal,
.nfe-return-email-modal,
.nfe-return-document-modal,
.nfe-return-issued-success-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(31, 42, 54, 0.48);
}

.nfe-return-create-modal[hidden],
.nfe-return-delete-modal[hidden],
.nfe-return-email-modal[hidden],
.nfe-return-document-modal[hidden],
.nfe-return-issued-success-modal[hidden] {
    display: none;
}

.nfe-return-create-box,
.nfe-return-delete-box,
.nfe-return-email-box,
.nfe-return-issued-success-box {
    width: min(420px, calc(100vw - 36px));
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.22);
}

.nfe-return-document-box {
    width: min(1040px, calc(100vw - 36px));
    height: min(82vh, 760px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.22);
}

.nfe-return-document-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.nfe-return-document-head h2 {
    margin: 0;
    font-size: 18px;
}

.nfe-return-document-box iframe {
    width: 100%;
    height: 100%;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
}

.nfe-return-create-box {
    width: min(520px, calc(100vw - 36px));
}

.nfe-return-create-box h2,
.nfe-return-create-box p,
.nfe-return-delete-box h2,
.nfe-return-delete-box p,
.nfe-return-email-box h2,
.nfe-return-issued-success-box h2,
.nfe-return-issued-success-box p {
    margin: 0;
}

.nfe-return-xml-create-form,
.nfe-return-email-box form {
    display: grid;
    gap: 12px;
}

.nfe-return-create-actions,
.nfe-return-delete-actions,
.nfe-return-email-actions,
.nfe-return-issued-success-actions {
    justify-content: flex-end;
}

.nfe-return-panel-head {
    align-items: center;
    min-height: 0;
    margin-bottom: 3px;
    padding: 0;
}

.nfe-return-panel-head h2 {
    margin: 0;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.15;
}

.nfe-return-items-form.products-dashboard-panel {
    min-height: 0;
    gap: 5px;
    margin-top: 4px;
    padding: 7px 9px;
}

.nfe-return-items-wrap {
    height: 150px;
}

.nfe-return-items-grid th,
.nfe-return-items-grid td {
    padding: 3px 6px;
    font-size: 11px;
    line-height: 1.08;
}

.nfe-return-product-cell {
    max-width: 620px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap !important;
}

.nfe-return-items-grid th:nth-child(1),
.nfe-return-items-grid td:nth-child(1) {
    width: 74px;
}

.nfe-return-items-grid th:nth-child(2),
.nfe-return-items-grid td:nth-child(2) {
    width: 108px;
}

.nfe-return-items-grid th:nth-child(4),
.nfe-return-items-grid td:nth-child(4) {
    width: 110px;
}

.nfe-return-items-grid th:nth-child(5),
.nfe-return-items-grid td:nth-child(5),
.nfe-return-items-grid th:nth-child(6),
.nfe-return-items-grid td:nth-child(6),
.nfe-return-items-grid th:nth-child(7),
.nfe-return-items-grid td:nth-child(7) {
    width: 106px;
}

.nfe-return-use-toggle {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0;
    white-space: nowrap;
}

.nfe-return-items-grid .session-badge {
    padding: 2px 8px;
    font-size: 10px;
    line-height: 1;
}

.nfe-return-items-grid tr.is-reference-only td {
    color: #536471;
}

.nfe-return-items-grid tr.is-reference-only.is-selected td {
    color: #061b24;
}

.nfe-return-items-grid tr.is-reference-only .nfe-return-product-cell,
.nfe-return-items-grid tr.is-reference-only td:nth-child(5),
.nfe-return-items-grid tr.is-reference-only td:nth-child(6),
.nfe-return-items-grid tr.is-reference-only td:nth-child(7) {
    opacity: 0.72;
}

.nfe-return-items-form.hide-reference-items .nfe-return-items-grid tr.is-reference-only {
    display: none;
}

.nfe-return-warning-cell {
    margin-bottom: 5px;
    white-space: normal !important;
    color: #9a3412;
    background: #fff6ed;
    border: 1px solid #f0c8a8;
    border-radius: 6px;
    padding: 5px 8px;
    font-size: 11px;
    line-height: 1.2;
}

.nfe-return-small-input,
.nfe-return-money-input,
.nfe-return-code-input {
    min-width: 72px;
    width: 86px;
}

.nfe-return-code-input {
    width: 58px;
}

.nfe-return-tax-editors {
    margin-top: 3px;
}

.nfe-return-tax-editor {
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    padding: 7px 9px;
}

.nfe-return-editor-title {
    display: flex;
    gap: 8px;
    align-items: baseline;
    margin-bottom: 4px;
    color: #334155;
    font-size: 12px;
}

.nfe-return-editor-title span {
    color: var(--muted);
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nfe-return-tax-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 8px;
}

.nfe-return-tax-tabs button {
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #eef8fc;
    color: #082c33;
    cursor: pointer;
    font-weight: 700;
    height: 30px;
    padding: 0 11px;
}

.nfe-return-tax-tabs button.is-active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.nfe-return-tax-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 7px 8px;
}

.nfe-return-tax-grid:not(.is-active) {
    display: none;
}

.nfe-return-tax-grid label {
    min-width: 0;
}

.nfe-return-tax-grid .nfe-return-field-wide {
    grid-column: span 2;
}

.nfe-return-tax-grid-principal {
    grid-template-columns: minmax(290px, 1.45fr) repeat(5, minmax(130px, 1fr));
}

.nfe-return-tax-grid-icms {
    grid-template-columns: minmax(170px, 0.8fr) minmax(260px, 1.25fr) repeat(3, minmax(150px, 1fr));
}

.nfe-return-total-grid {
    grid-template-columns: repeat(5, minmax(130px, 1fr));
}

.nfe-return-tax-grid input,
.nfe-return-tax-grid select {
    width: 100%;
    min-width: 0;
    height: 34px;
    min-height: 34px;
    line-height: 1.28;
    padding-top: 5px;
    padding-bottom: 5px;
}

@media (max-width: 1180px) {
    .nfe-return-tax-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .nfe-return-tax-grid-principal,
    .nfe-return-tax-grid-icms,
    .nfe-return-total-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .nfe-return-totals-strip {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .nfe-return-import,
    .nfe-return-filter {
        grid-template-columns: 1fr;
    }

    .nfe-return-tax-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .nfe-return-tax-grid-principal,
    .nfe-return-tax-grid-icms,
    .nfe-return-total-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .nfe-return-totals-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.nfe-management-panel,
.nfe-events-panel {
    min-height: 0;
}

.nfe-management-head,
.nfe-events-head {
    margin-bottom: 7px;
}

.nfe-management-head {
    align-items: flex-start;
    gap: 12px;
}

.nfe-management-problem-alert {
    margin-left: auto;
    width: min(790px, 48vw);
    min-height: 44px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 2px;
    padding: 7px 10px;
    border: 2px solid #e11d48;
    border-radius: 4px;
    background: #fff1f2;
    color: #991b1b;
    font-weight: 700;
    font-size: 12px;
    text-align: left;
    box-sizing: border-box;
}

.nfe-management-problem-alert span,
.nfe-management-problem-alert strong {
    display: block;
    line-height: 1.15;
}

.nfe-management-problem-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 5px;
}

.nfe-management-problem-actions .button.small {
    min-height: 24px;
    padding: 4px 9px;
    border-color: #e11d48;
    background: #fff;
    color: #991b1b;
    font-size: 11px;
}

.nfe-management-problem-actions .button.small:hover {
    background: #ffe4e6;
}

.nfe-management-head h2,
.nfe-events-head h2 {
    margin: 0;
}

.nfe-management-head p,
.nfe-events-head p {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.nfe-management-filter {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 6px 5px;
    align-items: end;
    max-width: 100%;
}

.nfe-management-filter label {
    min-width: 0;
}

.nfe-management-filter input,
.nfe-management-filter select {
    width: 100%;
    min-width: 0;
}

.nfe-management-filter-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    align-items: center;
    justify-content: flex-start;
    grid-column: span 2;
    min-width: 0;
}

.nfe-management-filter-actions .button {
    min-width: 0;
    padding-left: 10px;
    padding-right: 10px;
    white-space: nowrap;
}

.nfe-numbering-grid-wrap {
    height: 112px;
    margin-top: 8px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.products-grid.nfe-numbering-grid {
    min-width: 920px;
}

.nfe-numbering-grid th,
.nfe-numbering-grid td {
    height: 24px;
    padding: 3px 6px;
    font-size: 10.5px;
}

.nfe-management-grid-wrap {
    height: min(510px, calc(100vh - 390px));
    min-height: 310px;
    margin-top: 8px;
}

.products-grid.nfe-management-grid {
    min-width: 1160px;
}

.nfe-management-grid th,
.nfe-management-grid td,
.nfe-events-grid th,
.nfe-events-grid td {
    height: 25px;
    padding: 3px 6px;
    font-size: 10.5px;
    line-height: 1.12;
}

.nfe-management-grid col.nfe-col-created,
.nfe-management-grid col.nfe-col-issued,
.nfe-management-grid col.nfe-col-authorized {
    width: 82px;
}

.nfe-management-grid col.nfe-col-model {
    width: 44px;
}

.nfe-management-grid col.nfe-col-number {
    width: 58px;
}

.nfe-management-grid col.nfe-col-type {
    width: 116px;
}

.nfe-management-grid col.nfe-col-party {
    width: 158px;
}

.nfe-management-grid col.nfe-col-key {
    width: 205px;
}

.nfe-management-grid col.nfe-col-protocol {
    width: 86px;
}

.nfe-management-grid col.nfe-col-events {
    width: 52px;
}

.nfe-management-grid col.nfe-col-items {
    width: 42px;
}

.nfe-management-grid col.nfe-col-value {
    width: 76px;
}

.nfe-management-grid col.nfe-col-status {
    width: 98px;
}

.nfe-management-grid tbody tr,
.nfe-events-grid tbody tr {
    cursor: pointer;
}

.nfe-management-grid.vfp-grid tbody tr:nth-child(even),
.nfe-events-grid.vfp-grid tbody tr:nth-child(even),
.nfe-management-grid tbody tr:nth-child(even),
.nfe-events-grid tbody tr:nth-child(even) {
    background: #fffdfa;
}

.nfe-management-grid tbody tr:hover,
.nfe-management-grid tbody tr:focus,
.nfe-events-grid tbody tr:hover,
.nfe-events-grid tbody tr:focus {
    background: #eef7f8;
}

.nfe-management-grid tbody tr.nfe-row-open {
    background: #fff8db;
}

.nfe-management-grid tbody tr.nfe-row-open:nth-child(even) {
    background: #fff5c9;
}

.nfe-management-grid tbody tr.nfe-row-error {
    background: #fff0ec;
}

.nfe-management-grid tbody tr.nfe-row-error:nth-child(even) {
    background: #ffe7e1;
}

.nfe-management-grid tbody tr.nfe-management-error-row,
.nfe-management-grid tbody tr.nfe-management-error-row:nth-child(even),
.nfe-management-grid tbody tr.nfe-management-error-row:hover,
.nfe-management-grid tbody tr.nfe-management-error-row:focus {
    background: #fff7f4;
    cursor: default;
}

.nfe-management-grid tbody tr.nfe-management-error-row td {
    color: #7f1d1d;
    font-size: 10px;
    line-height: 1.25;
}

.nfe-management-grid tbody tr.nfe-management-error-row strong {
    margin-right: 6px;
    color: #9f321f;
}

.nfe-management-grid tbody tr.is-selected,
.nfe-management-grid tbody tr.is-selected:hover,
.nfe-management-grid tbody tr.is-selected:focus,
.nfe-events-grid tbody tr.is-selected,
.nfe-events-grid tbody tr.is-selected:hover,
.nfe-events-grid tbody tr.is-selected:focus {
    background: #c8f3ec !important;
    box-shadow: inset 4px 0 0 var(--primary), inset 0 0 0 1px #62cfc2;
}

.nfe-management-grid tbody tr.is-selected > td,
.nfe-events-grid tbody tr.is-selected > td {
    background: #c8f3ec !important;
}

.nfe-management-grid small,
.nfe-events-grid small {
    display: block;
    margin-top: 1px;
    color: var(--muted);
    font-size: 9.5px;
    line-height: 1.1;
}

.nfe-event-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 18px;
    border: 1px solid #b9e3d8;
    border-radius: 999px;
    background: #e8fbf7;
    color: #006b5f;
    font-size: 10px;
    font-weight: 700;
}

.nfe-management-error-detail {
    margin-top: 6px;
    padding: 7px 10px;
    border: 1px solid #efb4a6;
    border-radius: 7px;
    background: #fff3ef;
    color: #9b2c12;
    font-size: 11.5px;
    line-height: 1.25;
}

.nfe-management-actions {
    gap: 6px;
}

.nfe-management-actions .button,
.nfe-events-actions .button {
    min-height: 29px;
    padding: 5px 9px;
}

.nfe-management-modal {
    position: fixed;
    inset: 0;
    z-index: 110;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(31, 42, 54, 0.48);
}

.nfe-management-modal[hidden] {
    display: none;
}

.nfe-management-document-box,
.nfe-management-small-box {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.22);
}

.nfe-management-document-box {
    width: min(1100px, calc(100vw - 36px));
    height: min(84vh, 760px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 10px;
    padding: 14px;
}

.nfe-management-small-box {
    width: min(520px, calc(100vw - 36px));
    display: grid;
    gap: 12px;
    padding: 16px;
}

.nfe-management-cce-box {
    width: min(720px, calc(100vw - 36px));
}

.nfe-management-small-box h2,
.nfe-management-small-box p {
    margin: 0;
}

.nfe-management-small-box form {
    display: grid;
    gap: 12px;
}

.nfe-management-small-box textarea {
    width: 100%;
    resize: vertical;
}

.nfe-management-modal-head,
.nfe-management-modal-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.nfe-management-modal-head h2 {
    margin: 0;
    font-size: 17px;
}

.nfe-management-document-box iframe {
    width: 100%;
    height: 100%;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
}

.nfe-management-events-modal .nfe-management-document-box {
    width: min(1440px, calc(100vw - 36px));
    height: calc(100vh - 36px);
    max-height: 940px;
    grid-template-rows: auto minmax(0, 1fr);
}

.nfe-management-events-modal .nfe-management-document-box iframe {
    height: 100%;
    min-height: 0;
}

.nfe-management-embed-body {
    margin: 0;
    padding: 8px;
    background: #edf5f9;
}

.nfe-events-grid-wrap {
    height: auto;
    min-height: 0;
    max-height: min(210px, calc(100vh - 220px));
    margin-top: 6px;
}

.products-grid.nfe-events-grid {
    min-width: 980px;
}

.nfe-events-grid col.nfe-event-col-date {
    width: 126px;
}

.nfe-events-grid col.nfe-event-col-type {
    width: 90px;
}

.nfe-events-grid col.nfe-event-col-seq {
    width: 56px;
}

.nfe-events-grid col.nfe-event-col-protocol {
    width: 170px;
}

.nfe-events-grid col.nfe-event-col-status {
    width: 120px;
}

.nfe-events-grid col.nfe-event-col-text {
    width: auto;
}

@media (max-width: 1350px) {
    .nfe-management-filter {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .nfe-management-filter-search {
        grid-column: span 3;
    }

    .nfe-management-filter-actions {
        grid-column: span 3;
    }
}

@media (max-width: 900px) {
    .nfe-management-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .nfe-management-filter-search,
    .nfe-management-filter-actions {
        grid-column: span 2;
    }
}
/* Ajuste visual: filtros e botoes sem negrito nas telas operacionais principais. */
.products-dashboard-panel button,
.products-dashboard-panel .button,
.products-stock-documents-dialog button,
.products-stock-documents-dialog .button,
.products-stock-zero-dialog button,
.products-stock-zero-dialog .button,
.products-purchase-xml-dialog button,
.products-purchase-xml-dialog .button,
.products-labels-dialog button,
.products-labels-dialog .button,
.products-promotions-dialog button,
.products-promotions-dialog .button,
.product-stock-modal button,
.product-stock-modal .button,
.stock-document-entry-dialog button,
.stock-document-entry-dialog .button,
.stock-document-view-dialog button,
.stock-document-view-dialog .button,
.stock-documents-panel button,
.stock-documents-panel .button,
.purchase-conference-dialog button,
.purchase-conference-dialog .button,
.accounts-receivable-panel button,
.accounts-receivable-panel .button,
.accounts-receivable-dialog-body button,
.accounts-receivable-dialog-body .button,
.accounts-receivable-link-dialog-body button,
.accounts-receivable-link-dialog-body .button,
.accounts-receivable-list-dialog-body button,
.accounts-receivable-list-dialog-body .button,
.accounts-receivable-message-body button,
.accounts-receivable-message-body .button,
.manual-receivable-dialog-body button,
.manual-receivable-dialog-body .button,
.financial-panel button,
.financial-panel .button,
.financial-dialog button,
.financial-dialog .button,
.financial-list-dialog button,
.financial-list-dialog .button,
.financial-report-view-dialog button,
.financial-report-view-dialog .button,
.nfe-management-panel button,
.nfe-management-panel .button,
.nfe-management-modal button,
.nfe-management-modal .button,
.nfe-return-panel button,
.nfe-return-panel .button,
.nfe-return-modal button,
.nfe-return-modal .button,
.nfe-return-create-box button,
.nfe-return-create-box .button,
.nfe-return-delete-box button,
.nfe-return-delete-box .button,
.nfe-return-email-box button,
.nfe-return-email-box .button,
.nfe-return-tax-tabs button,
.nfse-dashboard-panel button,
.nfse-dashboard-panel .button,
.nfse-frame-dialog-body button,
.nfse-frame-dialog-body .button {
    font-weight: 400 !important;
}

.products-toolbar label,
.products-toolbar input,
.products-toolbar select,
.products-stock-documents-filter label,
.products-stock-documents-filter input,
.products-stock-documents-filter select,
.stock-documents-filter-bar label,
.stock-documents-filter-bar input,
.stock-documents-filter-bar select,
.stock-document-form label,
.stock-document-form input,
.stock-document-form select,
.stock-document-form textarea,
.product-stock-modal label,
.product-stock-modal input,
.product-stock-modal select,
.accounts-receivable-filters label,
.accounts-receivable-filters input,
.accounts-receivable-filters select,
.accounts-receivable-customer-search-line label,
.accounts-receivable-customer-search-line input,
.accounts-receivable-customer-search-line select,
.manual-receivable-form label,
.manual-receivable-form input,
.manual-receivable-form select,
.manual-receivable-form textarea,
.financial-filters label,
.financial-filters input,
.financial-filters select,
.financial-form-grid label,
.financial-form-grid input,
.financial-form-grid select,
.financial-form-grid textarea,
.financial-report-grid label,
.financial-report-grid input,
.financial-report-grid select,
.financial-dialog-filters label,
.financial-dialog-filters input,
.financial-dialog-filters select,
.nfe-management-filter label,
.nfe-management-filter input,
.nfe-management-filter select,
.nfe-return-filter label,
.nfe-return-filter input,
.nfe-return-filter select,
.nfe-return-import label,
.nfe-return-import input,
.nfe-return-import select,
.nfe-return-modal label,
.nfe-return-modal input,
.nfe-return-modal select,
.nfe-return-modal textarea,
.nfse-filter-grid label,
.nfse-filter-grid input,
.nfse-filter-grid select {
    font-weight: 400 !important;
}

.product-form-grid label,
.product-form-grid input,
.product-form-grid select,
.product-form-grid textarea,
.products-product-grid label,
.products-product-grid input,
.products-product-grid select,
.products-product-grid textarea {
    font-weight: 400 !important;
}

.product-form-grid label.is-required,
.products-product-grid label.is-required {
    font-weight: 700 !important;
}

.relatorios-shell {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: calc(100vh - 94px);
}

.relatorios-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.relatorios-topline h1 {
    margin: 0;
    font-size: 1.25rem;
    letter-spacing: 0;
}

.relatorios-topline span {
    color: #5f7280;
    font-size: .86rem;
}

.relatorios-limit-warning {
    display: block;
    margin-top: 2px;
    color: #9a5a12;
    font-size: .76rem;
    font-style: normal;
}

.relatorios-filter {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(128px, 100%), 1fr));
    gap: 6px;
    align-items: end;
    padding: 8px;
    border: 1px solid #d8e6eb;
    background: #f8fbfc;
    border-radius: 6px;
}

.relatorios-filter label {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    max-width: 100%;
    font-size: .72rem;
    font-weight: 400;
    color: #415764;
}

.relatorios-filter select,
.relatorios-filter input {
    width: 100%;
    min-width: 0;
    min-height: 30px;
    padding: 5px 7px;
    border: 1px solid #c8d9df;
    border-radius: 5px;
    background: #fff;
    color: #172b36;
    font: inherit;
    font-size: .78rem;
    font-weight: 400;
}

.relatorios-filter-receivables {
    grid-template-columns: repeat(auto-fit, minmax(min(128px, 100%), 1fr));
}

.relatorios-filter-actions {
    display: flex;
    align-items: end;
    min-width: 0;
    max-width: 100%;
}

.relatorios-filter .button,
.relatorios-bottom-bar .button {
    font-weight: 400;
}

.relatorios-workarea {
    display: grid;
    grid-template-columns: 214px minmax(0, 1fr);
    gap: 8px;
    min-height: 0;
    flex: 1;
}

.relatorios-list {
    overflow: auto;
    max-height: calc(100vh - 235px);
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
    padding: 6px;
}

.relatorios-list span {
    display: block;
    margin: 7px 4px 3px;
    color: #6f7f89;
    font-size: .68rem;
    text-transform: uppercase;
}

.relatorios-list a {
    display: block;
    padding: 5px 6px;
    border-radius: 4px;
    color: #213640;
    text-decoration: none;
    font-size: .78rem;
}

.relatorios-list a:hover,
.relatorios-list a.is-active {
    background: #e9f6f7;
    color: #116a73;
}

.relatorios-list .relatorios-list-disabled {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin: 0;
    padding: 5px 6px;
    border-radius: 4px;
    color: #8898a3;
    font-size: .78rem;
    text-transform: none;
    cursor: not-allowed;
}

.relatorios-list .relatorios-list-disabled small {
    color: #9aa8b1;
    font-size: .66rem;
    text-transform: uppercase;
}

.relatorios-loading {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 30px;
    padding: 6px 8px;
    border: 1px solid #cfe0e6;
    border-radius: 6px;
    background: #fff;
    color: #3a5260;
    font-size: .78rem;
}

.relatorios-loading[hidden] {
    display: none;
}

.relatorios-loading div {
    position: relative;
    flex: 1;
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #e4eef2;
}

.relatorios-loading i {
    position: absolute;
    inset: 0 auto 0 0;
    width: 34%;
    border-radius: inherit;
    background: #247f8f;
    animation: relatorios-loading-bar 1.05s ease-in-out infinite;
}

@keyframes relatorios-loading-bar {
    0% { transform: translateX(-105%); }
    100% { transform: translateX(305%); }
}

.relatorios-result {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.relatorios-kpis {
    display: grid;
    grid-template-columns: repeat(5, minmax(118px, 1fr));
    gap: 6px;
}

.relatorios-kpis div {
    min-height: 54px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
    padding: 7px;
}

.relatorios-kpis span {
    display: block;
    color: #60717c;
    font-size: .72rem;
}

.relatorios-kpis strong {
    display: block;
    margin-top: 4px;
    font-size: .98rem;
    color: #172b36;
}

.relatorios-chart-grid,
.relatorios-chart-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
}

.relatorios-chart-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.relatorios-chart-grid > div,
.relatorios-chart-strip > div {
    height: 168px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
    padding: 6px;
}

.relatorios-grid-wrap {
    min-height: 220px;
    max-height: 360px;
    overflow: auto;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
}

.relatorios-grid {
    width: 100%;
    border-collapse: collapse;
    font-size: .76rem;
}

.relatorios-grid th,
.relatorios-grid td {
    padding: 5px 7px;
    border-bottom: 1px solid #edf3f5;
    white-space: nowrap;
}

.relatorios-grid th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #eef7f8;
    color: #354d5a;
    text-align: left;
    font-weight: 500;
}

.relatorios-grid td.num,
.relatorios-grid th.num {
    text-align: right;
}

.relatorios-grid tbody tr:hover {
    background: #f7fbfc;
}

.relatorios-total-row td {
    position: sticky;
    bottom: 0;
    background: #f0f7f8;
    font-weight: 500;
}

.relatorios-empty,
.relatorios-empty-cell {
    padding: 12px;
    color: #61737f;
    text-align: center;
}

.relatorios-manual-result {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    min-height: 190px;
    padding: 18px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
    color: #243a45;
}

.relatorios-manual-result strong {
    font-size: 1rem;
}

.relatorios-manual-result span {
    color: #5b6f7a;
    font-size: .82rem;
}

.relatorios-manual-result div {
    display: flex;
    gap: 8px;
    margin-top: 4px;
}

.relatorios-pdf-pane {
    min-height: 390px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    overflow: hidden;
    background: #eef3f5;
}

.relatorios-pdf-pane iframe {
    display: block;
    width: 100%;
    height: 390px;
    border: 0;
    background: #fff;
}

.relatorios-result.is-pdf-only .relatorios-pdf-pane {
    min-height: calc(100vh - 248px);
}

.relatorios-result.is-pdf-only .relatorios-pdf-pane iframe {
    height: calc(100vh - 248px);
    min-height: 560px;
}

.relatorios-bottom-bar {
    position: sticky;
    bottom: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 7px 8px;
    border: 1px solid #cfe0e6;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 -4px 14px rgba(19, 43, 54, .06);
}

.relatorios-bottom-bar span {
    color: #516671;
    font-size: .78rem;
}

.relatorios-bottom-bar div {
    display: flex;
    gap: 6px;
}

.simples-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow: hidden;
}

.simples-head {
    align-items: flex-end;
    gap: 12px;
}

.simples-cnpj-form {
    display: flex;
    align-items: flex-end;
    gap: 6px;
}

.simples-cnpj-form label {
    display: flex;
    flex-direction: column;
    gap: 3px;
    color: #516671;
    font-size: .76rem;
}

.simples-cnpj-form input {
    width: 150px;
    height: 31px;
}

.simples-empty {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 16px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
}

.simples-panel .settings-card-head p {
    margin: 2px 0 0;
}

.simples-empty span {
    color: #5c707a;
    font-size: .82rem;
}

.simples-status-strip,
.simples-reference-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.simples-status-strip span,
.simples-reference-list span {
    padding: 5px 7px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
    color: #354d5a;
    font-size: .78rem;
}

.simples-status-strip b,
.simples-reference-list b {
    font-weight: 400;
}

.simples-kpis {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
}

.simples-kpi,
.simples-info-box {
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    background: #fff;
}

.simples-kpi span,
.simples-info-box span {
    display: block;
    margin-bottom: 4px;
    color: #61737f;
    font-size: .74rem;
}

.simples-card-value,
.simples-kpi strong,
.simples-info-box strong {
    display: block;
    overflow: hidden;
    color: #14313d;
    font-size: .78rem;
    font-weight: 400;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.simples-detail-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
}

.simples-detail-grid-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.simples-main-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
    align-items: start;
}

.simples-data-pane,
.simples-pdf-column {
    min-width: 0;
}

.simples-data-pane {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.simples-workarea {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
    align-items: start;
}

.simples-section-title,
.simples-doc-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin: 0 0 5px;
}

.simples-section-title span {
    color: #61737f;
    font-size: .76rem;
}

.simples-grid-wrap {
    max-height: 178px;
    min-height: 112px;
    margin-bottom: 8px;
    overflow-x: hidden;
    overflow-y: auto;
}

.simples-grid-wrap-tight {
    min-height: 108px;
    max-height: 176px;
}

.simples-revenue-grid-wrap {
    max-height: 210px;
}

.simples-grid .num {
    text-align: right;
}

.simples-declarations-grid {
    table-layout: fixed;
    width: 100%;
    min-width: 0;
}

.simples-declarations-grid th,
.simples-declarations-grid td {
    overflow: hidden;
    padding: 4px 4px;
    font-size: .66rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.simples-declarations-grid th:nth-child(1),
.simples-declarations-grid td:nth-child(1) {
    width: 13%;
}

.simples-declarations-grid th:nth-child(2),
.simples-declarations-grid td:nth-child(2) {
    width: 22%;
}

.simples-declarations-grid th:nth-child(3),
.simples-declarations-grid td:nth-child(3) {
    width: 22%;
}

.simples-declarations-grid th:nth-child(4),
.simples-declarations-grid td:nth-child(4),
.simples-declarations-grid th:nth-child(5),
.simples-declarations-grid td:nth-child(5) {
    width: 14%;
}

.simples-declarations-grid th:nth-child(6),
.simples-declarations-grid td:nth-child(6) {
    width: 15%;
}

.simples-revenue-grid {
    table-layout: fixed;
    width: 100%;
    min-width: 0;
}

.simples-revenue-grid th,
.simples-revenue-grid td {
    overflow: hidden;
    padding: 4px 6px;
    font-size: .68rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.simples-revenue-grid th:nth-child(1),
.simples-revenue-grid td:nth-child(1) {
    width: 26%;
}

.simples-revenue-grid th:nth-child(2),
.simples-revenue-grid td:nth-child(2) {
    width: 42%;
}

.simples-revenue-grid th:nth-child(3),
.simples-revenue-grid td:nth-child(3) {
    width: 32%;
}

.simples-pdf-pane {
    min-height: calc(100vh - 250px);
    border: 1px solid #d8e6eb;
    border-radius: 6px;
    overflow: hidden;
    background: #eef3f5;
}

.simples-pdf-pane iframe {
    display: block;
    width: 100%;
    height: calc(100vh - 250px);
    min-height: 520px;
    border: 0;
    background: #fff;
}

.simples-pdf-pane > span {
    display: block;
    padding: 14px;
    color: #61737f;
    font-size: .82rem;
}

@media (max-width: 1180px) {
    .relatorios-filter {
        grid-template-columns: repeat(4, minmax(120px, 1fr));
    }

    .relatorios-workarea {
        grid-template-columns: 1fr;
    }

    .relatorios-list {
        max-height: 132px;
    }

    .relatorios-kpis,
    .relatorios-chart-grid,
    .relatorios-chart-strip,
    .simples-kpis,
    .simples-detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .simples-detail-grid-compact {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .simples-workarea {
        grid-template-columns: 1fr;
    }

    .simples-main-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .relatorios-filter,
    .relatorios-kpis,
    .relatorios-chart-grid,
    .relatorios-chart-strip,
    .simples-kpis,
    .simples-detail-grid {
        grid-template-columns: 1fr;
    }

    .relatorios-bottom-bar {
        align-items: stretch;
        flex-direction: column;
    }

    .relatorios-bottom-bar div {
        flex-wrap: wrap;
    }

    .simples-head,
    .simples-cnpj-form,
    .simples-doc-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .simples-cnpj-form input {
        width: 100%;
    }

    .simples-workarea {
        grid-template-columns: minmax(0, 1fr);
    }

    .simples-main-split {
        grid-template-columns: minmax(0, 1fr);
    }

    .simples-pdf-pane,
    .simples-pdf-pane iframe {
        min-height: 360px;
        height: 360px;
    }
}

/* Normalizacao visual final da modal de venda interna: sem negritos pesados. */
.sales-entry-modal .sales-create-panel-modal,
.sales-entry-modal .sales-create-panel-modal label,
.sales-entry-modal .sales-create-panel-modal span,
.sales-entry-modal .sales-create-panel-modal small,
.sales-entry-modal .sales-create-panel-modal strong,
.sales-entry-modal .sales-create-panel-modal th,
.sales-entry-modal .sales-create-panel-modal td,
.sales-entry-modal .sales-create-panel-modal input,
.sales-entry-modal .sales-create-panel-modal select,
.sales-entry-modal .sales-create-panel-modal textarea,
.sales-entry-modal .sales-create-panel-modal button,
.sales-entry-modal .sales-create-panel-modal .button,
.sales-entry-modal .sales-create-panel-modal .sales-summary-card span,
.sales-entry-modal .sales-create-panel-modal .sales-summary-card strong,
.sales-entry-modal .sales-create-panel-modal .sales-item-entry-total-box span,
.sales-entry-modal .sales-create-panel-modal .sales-item-entry-total-box strong,
.sales-entry-modal .sales-create-panel-modal .sales-payments-head > strong,
.sales-entry-modal .sales-create-panel-modal .sales-payment-summary-inline span,
.sales-entry-modal .sales-create-panel-modal .sales-payment-summary-inline strong,
.sales-entry-modal .sales-create-panel-modal .sales-items-grid tbody td,
.sales-entry-modal .sales-create-panel-modal .sales-inline-summary span,
.sales-entry-modal .sales-create-panel-modal .sales-inline-summary strong {
    font-weight: 400 !important;
}

.sales-entry-modal .sales-create-panel-modal .panel-head h1 {
    font-weight: 500 !important;
}

/* Venda interna: normalizacao ampla para pegar modal e tela direta. */
.sales-create-panel,
.sales-create-panel *,
.sales-create-panel label,
.sales-create-panel span,
.sales-create-panel small,
.sales-create-panel strong,
.sales-create-panel b,
.sales-create-panel th,
.sales-create-panel td,
.sales-create-panel input,
.sales-create-panel select,
.sales-create-panel textarea,
.sales-create-panel button,
.sales-create-panel .button,
.sales-create-panel .panel-head h1,
.sales-create-panel .panel-head h2,
.sales-create-panel .sales-payments-head > strong,
.sales-create-panel .sales-summary-card span,
.sales-create-panel .sales-summary-card strong,
.sales-create-panel .sales-items-grid tbody td,
.sales-create-panel .sales-payment-summary-inline span,
.sales-create-panel .sales-payment-summary-inline strong {
    font-weight: 400 !important;
}
.pdv-delivery-card {
    width: min(1180px, calc(100vw - 28px));
    max-height: calc(100vh - 28px);
    overflow: auto;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-card [hidden],
.pdv-delivery-editor-card [hidden] {
    display: none !important;
}

.pdv-delivery-editor-card {
    width: min(1180px, calc(100vw - 42px));
    max-height: calc(100vh - 42px);
    overflow: auto;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-editor-card h2,
.pdv-delivery-editor-card strong,
.pdv-delivery-editor-card .button {
    font-weight: normal;
}

.pdv-delivery-card h2,
.pdv-delivery-card strong,
.pdv-delivery-card .button {
    font-weight: normal;
}

.pdv-delivery-card .pdv-alert-head {
    margin-bottom: 6px;
}

.pdv-delivery-card .pdv-alert-head h2 {
    font-size: 18px;
    line-height: 1.15;
}

.pdv-delivery-card .pdv-alert-message {
    font-size: 12px;
    margin: 2px 0 0;
}

.pdv-delivery-board {
    display: grid;
    gap: 7px;
}

.pdv-delivery-filterbar {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 150px auto;
    gap: 6px;
    align-items: end;
}

.pdv-delivery-filterbar label,
.pdv-delivery-status-actions label {
    display: grid;
    gap: 3px;
    font-size: 12px;
}

.pdv-delivery-filterbar input,
.pdv-delivery-filterbar select,
.pdv-delivery-status-actions select {
    min-height: 28px;
    padding: 4px 6px;
    border: 1px solid #b8c1d1;
    border-radius: 3px;
    font-size: 12px;
}

.pdv-delivery-orders-wrap {
    height: 360px;
    overflow: auto;
}

.pdv-delivery-orders-grid th,
.pdv-delivery-orders-grid td,
.pdv-delivery-search-grid th,
.pdv-delivery-search-grid td {
    padding: 4px 6px;
    font-size: 12px;
    font-weight: normal;
}

.pdv-delivery-orders-grid tr.selected td {
    background: #dcecff;
}

.pdv-delivery-board-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.pdv-delivery-message {
    margin: 0 0 8px;
    padding: 7px 10px;
    border: 1px solid #b7d7b9;
    background: #eef8ef;
    color: #22522a;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-layout {
    display: grid;
    grid-template-columns: minmax(620px, 1.45fr) minmax(330px, 0.75fr);
    gap: 8px;
    min-height: 430px;
}

.pdv-delivery-block {
    border: 1px solid var(--border-color, #d7dde8);
    background: #fff;
    padding: 8px;
    min-width: 0;
}

.pdv-delivery-block label,
.pdv-delivery-customer-card label,
.pdv-delivery-address-card label {
    display: grid;
    gap: 3px;
    margin: 0 0 6px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
    color: #293241;
}

.pdv-delivery-block input,
.pdv-delivery-block select,
.pdv-delivery-block textarea,
.pdv-delivery-customer-card input,
.pdv-delivery-address-card input,
.pdv-delivery-address-card select {
    min-height: 30px;
    padding: 4px 6px;
    border: 1px solid #b8c1d1;
    border-radius: 3px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-lookup-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px;
    align-items: end;
}

.pdv-delivery-block-head,
.pdv-delivery-item-entry,
.pdv-delivery-two-cols,
.pdv-delivery-actions {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px;
    align-items: end;
}

.pdv-delivery-item-entry {
    grid-template-columns: minmax(180px, 1fr) auto 74px auto;
}

.pdv-delivery-product-readonly {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 120px;
    gap: 6px;
    align-items: end;
}

.pdv-delivery-two-cols {
    grid-template-columns: 1fr 1fr;
    align-items: start;
}

.pdv-delivery-results,
.pdv-delivery-addresses,
.pdv-delivery-history,
.pdv-delivery-quick-notes {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 4px 0 6px;
}

.pdv-delivery-selected {
    min-height: 30px;
    padding: 6px 8px;
    border: 1px solid #d7dde8;
    background: #f7f9fc;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-items-grid {
    width: 100%;
}

.pdv-delivery-items-wrap {
    height: 230px;
    overflow: auto;
    border: 1px solid #d7dde8;
}

.pdv-delivery-items-grid th,
.pdv-delivery-items-grid td {
    padding: 4px 6px;
    font-size: 12px;
}

.pdv-delivery-items-grid tr.selected td,
.pdv-delivery-product-modal-grid tr.selected td {
    background: #dcecff;
}

.pdv-delivery-item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    justify-content: flex-start;
}

.pdv-delivery-company-info {
    padding: 6px 8px;
    border: 1px solid #d7dde8;
    background: #f7f9fc;
    color: #1f2937;
    font-size: 12px;
}

.pdv-delivery-product-search-card {
    width: min(780px, calc(100vw - 42px));
    max-height: calc(100vh - 42px);
    overflow: hidden;
}

.pdv-delivery-product-modal-wrap {
    height: 360px;
    overflow: auto;
}

.pdv-delivery-total-box {
    display: grid;
    gap: 5px;
    margin: 8px 0;
    padding: 8px;
    border: 1px solid #d7dde8;
    background: #f7f9fc;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-total-box span {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.pdv-delivery-total-box span:last-child {
    font-size: 14px;
}

.pdv-delivery-status-actions {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px;
    align-items: end;
    margin: 6px 0;
}

.pdv-delivery-section-button,
.pdv-delivery-section-title {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    margin: 0 0 6px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.pdv-delivery-no-change {
    grid-template-columns: auto 1fr !important;
    align-items: center;
}

.pdv-delivery-kanban {
    display: grid;
    grid-template-columns: repeat(6, minmax(120px, 1fr));
    gap: 6px;
    margin-top: 8px;
    max-height: 150px;
    overflow: auto;
}

.pdv-delivery-kanban-col {
    min-width: 120px;
    border: 1px solid #d7dde8;
    background: #f7f9fc;
    padding: 5px;
}

.pdv-delivery-kanban-col > strong {
    display: block;
    margin-bottom: 4px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 11px;
    font-weight: normal;
}

.pdv-delivery-order-card {
    display: grid;
    width: 100%;
    gap: 2px;
    margin-bottom: 4px;
    padding: 5px;
    border: 1px solid #c8d0de;
    background: #fff;
    color: #202735;
    text-align: left;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 11px;
    cursor: pointer;
}

.pdv-delivery-order-card strong {
    font-weight: normal;
}

.delivery-workspace {
    display: grid;
    gap: 6px;
}

.delivery-settings-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    align-items: center;
}

.delivery-settings-pane {
    display: grid;
    gap: 5px;
}

.delivery-settings-pane[hidden] {
    display: none !important;
}

.delivery-settings-grid-wrap {
    min-height: 220px;
    height: min(360px, calc(100vh - 260px));
    border: 1px solid #d7dde8;
    overflow: auto;
}

.delivery-settings-grid {
    min-width: 760px;
}

.delivery-settings-grid th,
.delivery-settings-grid td {
    padding: 3px 5px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 10.5px;
    font-weight: normal;
    line-height: 1.08;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.delivery-settings-grid tbody tr[data-delivery-row] {
    cursor: pointer;
}

.delivery-settings-grid tbody tr.is-selected td {
    background: #dcecff;
}

.delivery-settings-actions {
    margin-top: 0;
}

.delivery-settings-split {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 6px;
}

.delivery-settings-split .delivery-settings-grid-wrap {
    height: min(300px, calc(100vh - 300px));
    min-height: 200px;
}

.delivery-settings-dialog .pdv-alert-card,
.delivery-product-dialog .pdv-product-dialog-card {
    width: min(760px, calc(100vw - 42px));
    max-height: calc(100vh - 42px);
    overflow: auto;
    font-family: Tahoma, Arial, sans-serif;
}

.delivery-settings-form {
    gap: 10px;
}

.delivery-settings-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(160px, 1fr));
    gap: 7px;
}

.delivery-settings-form label,
.delivery-settings-product-lookup label {
    display: grid;
    gap: 3px;
    margin: 0;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.delivery-settings-form input,
.delivery-settings-form select,
.delivery-settings-product-lookup input {
    min-height: 30px;
    padding: 5px 7px;
    border: 1px solid #b8c1d1;
    border-radius: 3px;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 12px;
}

.delivery-settings-product-lookup {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) auto;
    gap: 6px;
    align-items: end;
}

.delivery-product-search-wrap {
    height: 180px;
    min-height: 180px;
}

.delivery-print-ticket {
    max-width: 420px;
    margin: 0 auto;
    padding: 16px;
    border: 1px solid #111;
    font-family: Tahoma, Arial, sans-serif;
    color: #111;
}

.delivery-print-ticket h2 {
    text-align: center;
    margin: 0 0 10px;
}

.delivery-print-item {
    display: grid;
    gap: 3px;
    margin: 8px 0;
}

@media (max-width: 980px) {
    .pdv-delivery-layout,
    .delivery-settings-split,
    .delivery-settings-form-grid {
        grid-template-columns: 1fr;
    }

    .pdv-delivery-kanban {
        grid-template-columns: repeat(3, minmax(120px, 1fr));
    }

    .delivery-settings-grid-wrap {
        height: 300px;
    }
}

@media print {
    body:has(.delivery-print-page) header,
    body:has(.delivery-print-page) .app-sidebar,
    body:has(.delivery-print-page) .panel-head .actions {
        display: none !important;
    }
}

.public-login-page {
    min-height: calc(100vh - 40px);
    display: grid;
    align-content: start;
    gap: 22px;
    padding: 26px;
    background: linear-gradient(135deg, #eef8f8 0%, #f7fbfc 48%, #eff7f8 100%);
}

.public-login-topbar,
.public-login-hero,
.public-help-link,
.public-downloads-section {
    width: min(1040px, 100%);
    margin: 0 auto;
}

.public-login-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 0 2px;
}

.public-login-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #162333;
    font-family: Tahoma, Arial, sans-serif;
}

.public-login-brand img {
    width: auto;
    max-width: 150px;
    height: 42px;
    object-fit: contain;
    display: block;
}

.public-login-brand .public-login-sennda-icon {
    width: 34px;
    height: 34px;
    object-fit: contain;
}

.public-login-brand strong {
    font-size: 15px;
    font-weight: normal;
}

.public-brand-separator {
    width: 1px;
    height: 28px;
    background: #bed1dc;
}

.public-login-contacts {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 7px;
}

.public-contact-pill {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 10px;
    border: 1px solid #b8d7d0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.82);
    color: #16445a;
    font-size: 12px;
    text-decoration: none;
    white-space: nowrap;
}

.public-contact-whatsapp {
    color: #0d7a4d;
}

.public-contact-pill img {
    width: 16px;
    height: 16px;
    object-fit: contain;
}

.public-login-hero {
    min-height: 0;
    display: grid;
    align-content: center;
}

.public-login-grid {
    display: grid;
    grid-template-columns: minmax(320px, 390px);
    justify-content: center;
}

.public-login-copy {
    display: grid;
    gap: 12px;
}

.public-login-copy h1 {
    max-width: 420px;
    margin: 0;
    color: #162333;
    font-family: "Segoe UI", "Trebuchet MS", Tahoma, Arial, sans-serif;
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 700;
    line-height: 1.06;
    letter-spacing: 0;
}

.public-login-copy p {
    max-width: 440px;
    margin: 0;
    color: #536173;
    font-size: 17px;
    line-height: 1.45;
}

.public-login-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.public-login-highlights span {
    padding: 7px 10px;
    border: 1px solid #c7dbe4;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.82);
    color: #21475c;
    font-size: 12px;
}

.public-login-card {
    display: grid;
    gap: 13px;
    padding: 22px;
    border: 1px solid #c3d6df;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 48px rgba(22, 35, 51, 0.15);
}

.public-login-card-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 12px;
}

.public-login-card-title {
    display: grid;
    gap: 4px;
}

.public-login-card-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.public-login-card-head strong {
    color: #162333;
    font-size: 24px;
}

.public-login-card-head span,
.public-login-card label,
.public-login-links a {
    color: #536173;
    font-size: 12px;
}

.public-login-card label {
    display: grid;
    gap: 6px;
    margin: 0;
}

.public-login-card input {
    min-height: 41px;
    padding: 9px 11px;
    border: 1px solid #b7cbd7;
    border-radius: 6px;
    background: #fbfdfe;
    color: #102737;
    font-size: 14px;
}

.public-login-submit {
    width: 100%;
    min-height: 42px;
}

.public-login-links {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.public-help-panel {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border: 1px solid #c3d6df;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 12px 32px rgba(22, 35, 51, 0.08);
}

.public-help-icon {
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #e9f6f5;
    color: #078b82;
}

.public-help-icon svg,
.public-help-button svg {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.public-help-copy {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.public-help-copy strong {
    color: #162333;
    font-size: 20px;
    line-height: 1.2;
}

.public-help-copy small {
    color: #536173;
    font-size: 13px;
    line-height: 1.45;
}

.public-help-button {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 8px;
    background: #d91f31;
    color: #fff;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 15px;
    font-weight: normal;
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(217, 31, 49, 0.22);
}

.public-help-button:hover {
    background: #b91626;
}

.public-help-button svg {
    width: 22px;
    height: 22px;
}

.public-downloads-section {
    display: grid;
    gap: 14px;
    padding: 20px;
    border: 1px solid #c3d6df;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.92);
}

.public-help-link {
    display: block;
    text-align: right;
    color: #536173;
    font: normal 11px Tahoma, Arial, sans-serif;
    text-decoration: underline;
}

.public-downloads-head {
    display: grid;
    gap: 4px;
}

.public-downloads-head h2 {
    margin: 0;
    color: #162333;
    font-size: 27px;
}

.public-downloads-head p {
    margin: 0;
    color: #687586;
    font-size: 14px;
}

.public-downloads-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(260px, 1fr));
    gap: 12px;
}

.public-download-row {
    min-height: 86px;
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border: 1px solid #b7e2ce;
    border-radius: 8px;
    background: #f2fbf6;
    color: #162333;
    text-decoration: none;
}

.public-download-row:hover {
    border-color: #24a86e;
    box-shadow: 0 10px 28px rgba(15, 111, 105, 0.12);
}

.public-download-row.is-unavailable {
    border-color: #ead0c8;
    background: #fbf4f2;
    opacity: 0.8;
}

.public-download-icon {
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d4e7dc;
    border-radius: 8px;
    background: #ffffff;
    color: #0d8d5b;
}

.public-download-icon svg {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.public-download-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.public-download-copy strong {
    color: #162333;
    font-size: 16px;
}

.public-download-copy small,
.public-download-action small {
    color: #687586;
    font-size: 12px;
}

.public-download-action {
    display: grid;
    justify-items: end;
    gap: 4px;
    white-space: nowrap;
}

.public-download-action b {
    color: #0d8d5b;
    font-size: 13px;
}

@media (max-width: 900px) {
    .public-login-page {
        padding: 16px;
    }

    .public-login-topbar,
    .public-login-grid {
        grid-template-columns: 1fr;
    }

    .public-login-topbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .public-login-hero {
        min-height: auto;
    }

    .public-help-panel {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .public-downloads-list,
    .public-download-row {
        grid-template-columns: 1fr;
    }

    .public-download-action {
        justify-items: start;
    }
}
.pdv-management-dialog {
    width: min(1460px, calc(100vw - 1.5rem));
    max-height: calc(100vh - 1.5rem);
    padding: 0;
    overflow: hidden;
}

.pdv-management-page {
    width: 100%;
    min-width: 0;
    margin: 0;
    box-sizing: border-box;
}

.pdv-management-page .pdv-management-body {
    height: auto;
    min-height: 0;
}

.pdv-management-page .pdv-management-grid-wrap {
    height: clamp(340px, calc(100vh - 340px), 580px);
    min-height: 0;
    flex: none;
}

.pdv-management-body {
    display: flex;
    height: min(900px, calc(100vh - 2rem));
    min-height: 620px;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    box-sizing: border-box;
}

.pdv-management-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pdv-management-tabs .button,
.pdv-management-filters,
.pdv-management-filters label,
.pdv-management-filters input,
.pdv-management-filters select,
.pdv-management-filters .button {
    font-weight: 400;
}

.pdv-management-filters {
    display: grid;
    grid-template-columns: repeat(16, minmax(0, 1fr));
    gap: 7px;
    align-items: end;
}

.pdv-management-date {
    grid-column: span 2;
}

.pdv-management-pdv-filter {
    grid-column: span 5;
}

.pdv-management-status-filter {
    grid-column: span 2;
}

.pdv-management-company-filter {
    grid-column: span 5;
}

.pdv-management-search {
    grid-column: span 4;
}

.pdv-management-operator-filter {
    grid-column: span 3;
}

.pdv-management-check {
    grid-column: span 2;
}

.pdv-management-sale-status {
    grid-column: 1 / span 2;
}

.pdv-management-filters > .button {
    grid-column: span 1;
    min-width: 0;
    padding-inline: 8px;
}

.pdv-management-filters label {
    min-width: 0;
}

.pdv-management-filters [hidden] {
    display: none !important;
}

.pdv-management-filters input,
.pdv-management-filters select {
    width: 100%;
    min-width: 0;
}

.pdv-management-check {
    display: flex !important;
    min-height: 34px;
    flex-direction: row !important;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

.pdv-management-check input {
    width: auto;
}

.pdv-sale-receipt-kit-composition {
    display: grid;
    gap: 1px;
    margin: -2px 0 4px 10px;
    padding-left: 6px;
    border-left: 2px solid #b9c6ca;
    font-family: "Arial Narrow", "Roboto Condensed", Tahoma, sans-serif;
    font-size: .72em;
    line-height: 1.05;
}

.pdv-sale-receipt-kit-composition strong {
    font-weight: 400;
    text-transform: uppercase;
}

.pdv-management-summary {
    padding: 5px 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f7fafb;
    color: var(--muted);
    font-size: 0.78rem;
}

.pdv-management-grid-wrap {
    min-height: 0;
    flex: 1;
    overflow: auto;
}

.pdv-management-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    min-height: 0;
}

.pdv-management-workspace.has-sale-receipt {
    grid-template-columns: minmax(600px, 1.55fr) minmax(360px, .9fr);
}

.pdv-management-workspace:not(.has-sale-receipt) .pdv-sale-receipt {
    display: none;
}

.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid {
    min-width: 0;
}

.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th,
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid td {
    padding-right: 5px;
    padding-left: 5px;
}

.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(1) { width: 132px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(2) { width: 58px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(3) { width: 116px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(4) { width: 92px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(5) { width: 118px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(6) { width: auto; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(7) { width: 48px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(8) { width: 92px; }
.pdv-management-workspace.has-sale-receipt.is-sales .pdv-management-grid th:nth-child(9) { width: 82px; }

.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(1) { width: 126px; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(2) { width: 78px; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(3) { width: 82px; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(4) { width: 92px; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(5) { width: 116px; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(6) { width: auto; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(7) { width: 48px; }
.pdv-management-workspace.is-pre_sales .pdv-management-grid th:nth-child(8) { width: 92px; }

.pdv-management-workspace.has-sale-receipt:not(.is-sales) .pdv-management-grid {
    min-width: 0;
}

.pdv-management-workspace.is-movements .pdv-management-grid th:nth-child(1) { width: 125px; }
.pdv-management-workspace.is-movements .pdv-management-grid th:nth-child(2) { width: 90px; }
.pdv-management-workspace.is-movements .pdv-management-grid th:nth-child(3) { width: 92px; }
.pdv-management-workspace.is-movements .pdv-management-grid th:nth-child(4) { width: 125px; }
.pdv-management-workspace.is-movements .pdv-management-grid th:nth-child(5) { width: auto; }
.pdv-management-workspace.is-movements .pdv-management-grid th:nth-child(6) { width: 96px; }

.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(1) { width: 116px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(2) { width: 78px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(3) { width: 72px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(4) { width: 108px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(5) { width: auto; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(6) { width: 48px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(7) { width: 90px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(8) { width: 86px; }
.pdv-management-workspace.is-removed_items .pdv-management-grid th:nth-child(9) { width: 105px; }

.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(1) { width: 120px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(2) { width: 76px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(3) { width: 135px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(4) { width: auto; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(5) { width: 105px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(6) { width: 105px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(7) { width: 76px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(8) { width: 82px; }
.pdv-management-workspace.is-audits .pdv-management-grid th:nth-child(9) { width: 112px; }

.pdv-management-workspace.is-movements .pdv-management-grid th,
.pdv-management-workspace.is-movements .pdv-management-grid td,
.pdv-management-workspace.is-removed_items .pdv-management-grid th,
.pdv-management-workspace.is-removed_items .pdv-management-grid td,
.pdv-management-workspace.is-audits .pdv-management-grid th,
.pdv-management-workspace.is-audits .pdv-management-grid td {
    padding-right: 5px;
    padding-left: 5px;
}

.pdv-sale-receipt {
    height: clamp(340px, calc(100vh - 340px), 580px);
    min-width: 0;
    overflow: auto;
    padding: 4px 8px 10px;
    border: 1px solid #b8afa2;
    border-radius: 8px;
    background: #d6d0c7;
    box-sizing: border-box;
    scrollbar-gutter: stable;
}

.pdv-sale-receipt-zoom {
    position: sticky;
    z-index: 2;
    top: 0;
    display: flex;
    justify-content: flex-end;
    gap: 3px;
    margin: -4px -4px 4px;
    padding: 4px;
    background: rgba(214, 208, 199, .96);
}

.pdv-sale-receipt-zoom .button {
    min-width: 30px;
    min-height: 26px;
    padding: 3px 7px;
}

.pdv-sale-receipt-paper {
    position: relative;
    width: min(100%, 420px);
    min-height: calc(100% - 7px);
    margin: 0 auto;
    padding: 14px 15px 20px;
    color: #24211d;
    background: #fffefa;
    box-shadow: 0 4px 12px rgba(48, 39, 28, .18);
    font-family: "Courier New", monospace;
    font-size: var(--pdv-receipt-font-size, 11px);
    line-height: 1.15;
    box-sizing: border-box;
}

.pdv-sale-receipt-paper::after {
    position: absolute;
    right: 0;
    bottom: -7px;
    left: 0;
    height: 8px;
    background: linear-gradient(135deg, #fffefa 5px, transparent 0) 0 0/10px 10px repeat-x;
    content: "";
}

.pdv-sale-receipt-paper header {
    display: grid;
    gap: 2px;
    padding-bottom: 6px;
    border-bottom: 1px dashed #777;
    text-align: center;
}

.pdv-sale-receipt-customer,
.pdv-sale-receipt-fiscal,
.pdv-sale-receipt-paper section,
.pdv-sale-receipt-totals,
.pdv-sale-receipt-payments,
.pdv-sale-receipt-notes {
    padding: 5px 0;
    border-bottom: 1px dashed #888;
}

.pdv-sale-receipt-customer,
.pdv-sale-receipt-fiscal,
.pdv-sale-receipt-notes {
    display: grid;
    gap: 2px;
}

.pdv-sale-receipt-fiscal span {
    overflow-wrap: anywhere;
    letter-spacing: .03em;
}

.pdv-sale-receipt-fiscal .pdv-sale-receipt-access-key {
    overflow: hidden;
    font-size: .78em;
    letter-spacing: -.045em;
    white-space: nowrap;
}

.pdv-sale-receipt-item {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 1px 7px;
    padding: 2px 0;
}

.pdv-sale-receipt-item span { grid-column: 1 / -1; }
.pdv-sale-receipt-item.is-removed { color: #a33b2f; }

.pdv-sale-receipt-item-benefit {
    display: grid;
    gap: 1px;
    margin: -1px 0 3px 8px;
    padding-left: 5px;
    color: #266540;
    border-left: 2px solid #62a57b;
    font-family: "Arial Narrow", "Roboto Condensed", Tahoma, sans-serif;
    font-size: .72em;
    font-stretch: condensed;
    line-height: 1.05;
    letter-spacing: -.035em;
}

.pdv-sale-receipt-removed-audit {
    display: grid;
    gap: 1px;
    margin: 1px 0 3px;
    padding: 3px 5px;
    color: #8b3128;
    border-left: 3px solid #c75545;
    background: #fff1ee;
    font-size: .78em;
    line-height: 1.05;
    letter-spacing: -.025em;
}

.pdv-sale-receipt-totals > div,
.pdv-sale-receipt-payments > div,
.pdv-sale-receipt-operation > div {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 1px 0;
}

.pdv-sale-receipt-operation {
    display: grid;
    gap: 5px;
    padding: 7px 0;
    border-bottom: 1px dashed #888;
}

.pdv-sale-receipt-operation > div {
    align-items: baseline;
}

.pdv-sale-receipt-operation .is-operation-total {
    margin-top: 4px;
    padding-top: 5px;
    border-top: 1px solid #444;
    font-size: 1.15em;
}

.pdv-sale-receipt-totals .is-total {
    margin-top: 3px;
    padding-top: 4px;
    border-top: 1px solid #444;
    font-size: 16px;
}

.pdv-sale-receipt-paper footer { padding-top: 7px; text-align: center; font-weight: 700; }
.pdv-sale-receipt-empty { display: grid; place-content: center; gap: 8px; min-height: 180px; text-align: center; color: #68625b; }

.pdv-management-danfe-dialog { width: min(1180px, 96vw); height: min(900px, 94vh); }
.pdv-management-danfe-dialog .access-dialog-body {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
}
.pdv-management-danfe-dialog iframe {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    flex: 1 1 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.pdv-management-grid {
    width: 100%;
    min-width: 1050px;
    table-layout: fixed;
}

.pdv-management-grid th,
.pdv-management-grid td {
    padding: 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pdv-management-grid tbody tr {
    cursor: pointer;
}

.pdv-management-grid tbody tr.is-selected td {
    background: #d8f1ee;
}

.pdv-management-actions {
    margin-top: 0;
}

.pdv-management-actions .button {
    font-weight: 400;
}

.pdv-management-detail-dialog {
    width: min(900px, calc(100vw - 1.5rem));
}

.pdv-management-detail-body {
    max-height: calc(100vh - 3rem);
    overflow: auto;
}

.pdv-management-detail-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
}

.pdv-management-detail-grid span {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 2px;
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f7fafb;
}

.pdv-management-detail-grid small {
    color: var(--muted);
}

.pdv-management-detail-grid strong {
    overflow-wrap: anywhere;
}

@media (max-width: 1100px) {
    .pdv-management-workspace.has-sale-receipt {
        grid-template-columns: minmax(0, 1fr);
    }

    .pdv-sale-receipt {
        display: none;
    }

    .pdv-management-filters {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .pdv-management-pdv-filter,
    .pdv-management-search,
    .pdv-management-operator-filter {
        grid-column: span 2;
    }

    .pdv-management-date,
    .pdv-management-status-filter,
    .pdv-management-check {
        grid-column: span 1;
    }
}

@media (max-width: 700px) {
    .pdv-management-filters,
    .pdv-management-detail-grid {
        grid-template-columns: 1fr;
    }

    .pdv-management-pdv-filter,
    .pdv-management-search,
    .pdv-management-operator-filter {
        grid-column: span 1;
    }
}
.users-pdv-grid th[data-pdv-operator-sort] {
    cursor: pointer;
    user-select: none;
}

.users-pdv-grid th[data-pdv-operator-sort]::after {
    content: " ↕";
    color: #708090;
    font-weight: normal;
}

.users-pdv-grid th[data-pdv-operator-sort][data-sort-direction="asc"]::after {
    content: " ↑";
}

.users-pdv-grid th[data-pdv-operator-sort][data-sort-direction="desc"]::after {
    content: " ↓";
}
.users-admin-grid th[data-user-sort] {
    cursor: pointer;
    user-select: none;
}

.users-admin-grid th[data-user-sort]::after {
    content: " \2195";
    color: #708090;
    font-weight: 400;
}

.users-admin-grid th[data-user-sort][data-sort-direction="asc"]::after {
    content: " \2191";
}

.users-admin-grid th[data-user-sort][data-sort-direction="desc"]::after {
    content: " \2193";
}

.accounts-receivable-details-dialog {
    width: min(1080px, calc(100vw - 28px));
}

.accounts-receivable-details-body {
    max-height: calc(100vh - 34px);
    overflow: hidden;
}

.accounts-receivable-details-loading {
    padding: 28px;
    border: 1px dashed var(--line);
    border-radius: 8px;
    color: var(--muted);
    text-align: center;
}

.accounts-receivable-details-content {
    min-height: 0;
    max-height: calc(100vh - 116px);
    overflow: auto;
    padding-right: 4px;
}

.accounts-receivable-sale-dialog {
    width: min(1180px, calc(100vw - 32px));
    max-width: 1180px;
}

.accounts-receivable-sale-body {
    width: 100%;
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.accounts-receivable-sale-content {
    display: grid;
    gap: 12px;
}

.receivable-sale-summary,
.receivable-sale-meta {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 8px;
}

.receivable-sale-summary > div,
.receivable-sale-meta > div,
.receivable-sale-payments > div {
    display: grid;
    gap: 3px;
    padding: 9px 10px;
    border: 1px solid var(--line, #d5e2e8);
    border-radius: 8px;
    background: var(--panel-soft, #f6fafb);
}

.receivable-sale-summary span,
.receivable-sale-meta span,
.receivable-sale-meta small {
    color: var(--muted, #526579);
    font-size: 12px;
}

.receivable-sale-section {
    display: grid;
    gap: 8px;
    padding: 11px;
    border: 1px solid var(--line, #d5e2e8);
    border-radius: 10px;
}

.receivable-sale-section h3 {
    margin: 0;
    font-size: 15px;
}

.receivable-sale-meta {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.receivable-sale-grid {
    max-height: 245px;
    overflow: auto;
    border: 1px solid var(--line, #d5e2e8);
    border-radius: 8px;
}

.receivable-sale-grid .products-grid {
    min-width: 880px;
}

.receivable-sale-totals,
.receivable-sale-payments {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.receivable-sale-totals span {
    display: flex;
    gap: 8px;
    padding: 6px 9px;
    border-radius: 7px;
    background: var(--panel-soft, #f6fafb);
}

.receivable-sale-totals .is-total {
    color: var(--accent-strong, #a54813);
    border: 1px solid var(--accent, #e5782f);
}

.receivable-sale-payments > div {
    min-width: 190px;
}

@media (max-width: 800px) {
    .receivable-sale-summary,
    .receivable-sale-meta {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.accounts-receivable-details-section {
    margin-top: 10px;
    padding: 10px;
    border: 1px solid #d7e5ee;
    border-radius: 8px;
    background: #fff;
}

.accounts-receivable-details-section:first-child {
    margin-top: 0;
}

.accounts-receivable-details-section h3 {
    margin: 0 0 8px;
    font-size: 14px;
}

.accounts-receivable-details-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
}

.accounts-receivable-detail-field {
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid #deebf2;
    border-radius: 7px;
    background: #f8fbfd;
}

.accounts-receivable-detail-field.is-wide {
    grid-column: span 2;
}

.accounts-receivable-detail-field span,
.accounts-receivable-detail-field strong {
    display: block;
    overflow-wrap: anywhere;
}

.accounts-receivable-detail-field span {
    margin-bottom: 2px;
    color: var(--muted);
    font-size: 10px;
    text-transform: uppercase;
}

.accounts-receivable-detail-field strong {
    font-size: 12px;
}

.accounts-receivable-receipts-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
}

.accounts-receivable-receipt-card {
    padding: 8px;
    border: 1px solid #d7e5ee;
    border-radius: 7px;
    background: #f8fbfd;
}

.accounts-receivable-receipt-card > div {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    padding-bottom: 5px;
    border-bottom: 1px solid #deebf2;
}

.accounts-receivable-receipt-card > div span {
    color: var(--muted);
    font-size: 11px;
}

.accounts-receivable-receipt-card dl {
    display: grid;
    grid-template-columns: 132px minmax(0, 1fr);
    gap: 3px 8px;
    margin: 7px 0 0;
}

.accounts-receivable-receipt-card dt {
    color: var(--muted);
}

.accounts-receivable-receipt-card dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.accounts-receivable-audit-list {
    display: grid;
    gap: 0;
}

.accounts-receivable-audit-event {
    display: grid;
    grid-template-columns: 14px minmax(0, 1fr);
    gap: 8px;
    padding: 7px 0;
    border-bottom: 1px solid #e5eef3;
}

.accounts-receivable-audit-event:last-child {
    border-bottom: 0;
}

.accounts-receivable-audit-marker {
    width: 9px;
    height: 9px;
    margin-top: 4px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 0 1px #c9dce7;
}

.accounts-receivable-audit-event header {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.accounts-receivable-audit-event time,
.accounts-receivable-audit-event p span {
    color: var(--muted);
}

.accounts-receivable-audit-event p {
    margin: 3px 0 0;
}

.accounts-receivable-audit-event ul {
    margin: 4px 0 0;
    padding-left: 18px;
    color: #34495e;
}

.accounts-receivable-details-empty {
    margin: 0;
    padding: 10px;
    color: var(--muted);
    text-align: center;
}

@media (max-width: 820px) {
    .accounts-receivable-details-grid,
    .accounts-receivable-receipts-list {
        grid-template-columns: 1fr;
    }

    .accounts-receivable-detail-field.is-wide {
        grid-column: auto;
    }

    .accounts-receivable-receipt-card > div,
    .accounts-receivable-audit-event header {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }
}
.customer-credit-limit-dialog {
    width: min(980px, calc(100vw - 28px));
}

.customer-credit-limit-body {
    max-height: calc(100vh - 34px);
    overflow-x: hidden;
    overflow-y: auto;
}

.customer-credit-limit-summary-wrap,
.customer-credit-limit-titles-wrap {
    width: 100%;
    overflow-x: hidden;
}

.customer-credit-limit-summary-wrap {
    height: auto;
    min-height: 0;
    max-height: none;
}

.customer-credit-limit-summary {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}

.customer-credit-limit-summary td:first-child {
    width: 150px;
}

.customer-credit-limit-open-section {
    display: grid;
    min-height: 0;
    margin-top: 9px;
}

.customer-credit-limit-open-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 5px;
}

.customer-credit-limit-open-head h3 {
    margin: 0;
    font-size: 14px;
}

.customer-credit-limit-open-head span {
    color: var(--muted);
    font-size: 11px;
}

.customer-credit-limit-titles-wrap {
    max-height: 270px;
    overflow-y: auto;
    border: 1px solid var(--line);
    border-radius: 7px;
}

.customer-credit-limit-titles-grid {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
    font-size: 11px;
}

.customer-credit-limit-titles-grid th,
.customer-credit-limit-titles-grid td {
    padding: 5px 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.customer-credit-limit-titles-grid th:nth-child(1),
.customer-credit-limit-titles-grid td:nth-child(1),
.customer-credit-limit-titles-grid th:nth-child(2),
.customer-credit-limit-titles-grid td:nth-child(2) {
    width: 84px;
}

.customer-credit-limit-titles-grid th:nth-child(3),
.customer-credit-limit-titles-grid td:nth-child(3) {
    width: 102px;
}

.customer-credit-limit-titles-grid th:nth-child(4),
.customer-credit-limit-titles-grid td:nth-child(4) {
    width: auto;
}

.customer-credit-limit-titles-grid th:nth-child(5),
.customer-credit-limit-titles-grid td:nth-child(5) {
    width: 55px;
}

.customer-credit-limit-titles-grid th:nth-child(6),
.customer-credit-limit-titles-grid td:nth-child(6),
.customer-credit-limit-titles-grid th:nth-child(7),
.customer-credit-limit-titles-grid td:nth-child(7),
.customer-credit-limit-titles-grid th:nth-child(8),
.customer-credit-limit-titles-grid td:nth-child(8) {
    width: 82px;
}

.customer-credit-limit-titles-grid th:nth-child(9),
.customer-credit-limit-titles-grid td:nth-child(9) {
    width: 68px;
}

.customer-credit-limit-titles-grid td small {
    display: block;
    overflow: hidden;
    color: var(--muted);
    font-size: 9px;
    text-overflow: ellipsis;
}

.customer-credit-limit-titles-grid td.is-overdue {
    color: #b42318;
}

.customer-credit-title-sort {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.customer-credit-title-sort::after {
    color: #7a8b96;
    content: "↕";
    font-size: 9px;
}

.customer-credit-title-sort[data-direction="asc"]::after {
    content: "↑";
}

.customer-credit-title-sort[data-direction="desc"]::after {
    content: "↓";
}

.customer-grid-sort {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.customer-grid-sort::after {
    color: #7a8b96;
    content: "↕";
    font-size: 9px;
}

.customer-grid-sort[data-direction="asc"]::after {
    content: "↑";
}

.customer-grid-sort[data-direction="desc"]::after {
    content: "↓";
}

@media (max-width: 760px) {
    .customer-credit-limit-dialog {
        width: calc(100vw - 16px);
    }

    .customer-credit-limit-summary td:first-child {
        width: 118px;
    }

    .customer-credit-limit-titles-grid th:nth-child(2),
    .customer-credit-limit-titles-grid td:nth-child(2),
    .customer-credit-limit-titles-grid th:nth-child(6),
    .customer-credit-limit-titles-grid td:nth-child(6),
    .customer-credit-limit-titles-grid th:nth-child(7),
    .customer-credit-limit-titles-grid td:nth-child(7) {
        display: none;
    }
}
.fiscal-audit-page { min-height: calc(100vh - 130px); }
.fiscal-audit-summary { display:grid; grid-template-columns:repeat(5,minmax(130px,1fr)); gap:8px; margin:10px 0; }
.fiscal-audit-summary > * { border:1px solid #c7dceb; border-radius:8px; background:#f6fbfe; padding:9px 12px; text-align:left; font:normal 12px Tahoma,sans-serif; color:#40546a; }
.fiscal-audit-summary button { cursor:pointer; }
.fiscal-audit-summary span { display:block; }
.fiscal-audit-summary strong { display:block; color:#102d41; font-size:19px; margin-top:3px; }
.fiscal-audit-tabs { display:flex; flex-wrap:wrap; gap:7px; margin-bottom:8px; }
.fiscal-audit-filters { display:grid; grid-template-columns:minmax(300px,1fr) auto auto; gap:8px; align-items:end; margin-bottom:8px; }
.fiscal-audit-filters label,.fiscal-action-dialog label { display:grid; gap:4px; font:normal 11px Tahoma,sans-serif; }
.fiscal-audit-filters input,.fiscal-audit-filters select,.fiscal-action-dialog input,.fiscal-action-dialog select { min-height:34px; }
.fiscal-audit-grid-wrap { height:clamp(260px,46vh,460px); min-height:260px; overflow:auto; border:1px solid #c7dceb; border-radius:8px; }
.fiscal-audit-grid { table-layout:fixed; min-width:760px; }
.fiscal-audit-grid th:nth-child(1){width:11%}.fiscal-audit-grid th:nth-child(2){width:41%}.fiscal-audit-grid th:nth-child(3){width:9%}.fiscal-audit-grid th:nth-child(4){width:8%}.fiscal-audit-grid th:nth-child(5){width:9%}.fiscal-audit-grid th:nth-child(6){width:12%}.fiscal-audit-grid th:nth-child(7){width:10%}
.fiscal-audit-grid td { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.fiscal-audit-grid td:nth-child(2) { white-space:normal; line-height:1.3; }
.fiscal-audit-page th[data-sort-type] { cursor:pointer; user-select:none; }
.fiscal-audit-page th[data-sort-type]::after { content:' ↕'; color:#6d8294; font-size:10px; }
.fiscal-audit-page th[data-sort-direction="asc"]::after { content:' ↑'; color:#163e59; }
.fiscal-audit-page th[data-sort-direction="desc"]::after { content:' ↓'; color:#163e59; }
.fiscal-audit-page th[data-sort-type]:focus-visible { outline:2px solid #e77b2f; outline-offset:-2px; }
.fiscal-purchase-dialog { width:min(1820px,99vw); }
.fiscal-purchase-dialog .dialog-content { width:100%; }
.fiscal-purchase-summary { margin:0 0 7px; padding:7px 9px; border:1px solid #c7dceb; border-radius:7px; background:#f4f9fc; font:normal 11px Tahoma,sans-serif; color:#40546a; }
.fiscal-purchase-product { margin:0 0 8px; padding:10px; border:1px solid #bdd6e6; border-radius:7px; background:#fbfdfe; font:normal 12px Tahoma,sans-serif; line-height:1.3; }
.fiscal-purchase-product-title { display:flex; align-items:baseline; flex-wrap:wrap; gap:8px 14px; margin-bottom:8px; }
.fiscal-purchase-product-title strong { font-size:16px; }
.fiscal-purchase-product-title span { font-size:11px; color:#40546a; }
.fiscal-purchase-product dl { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:7px 10px; margin:0; }
.fiscal-purchase-product dl div { min-width:0; padding:6px 8px; border-radius:5px; background:#edf5f9; }
.fiscal-purchase-product dt { color:#60758a; text-transform:uppercase; font-size:10px; line-height:1.1; }
.fiscal-purchase-product dd { margin:3px 0 0; overflow:hidden; text-overflow:ellipsis; white-space:normal; }
.fiscal-purchase-grid-wrap { height:clamp(250px,48vh,500px); overflow:auto; border:1px solid #c7dceb; border-radius:7px; }
.fiscal-purchase-grid-wrap table { width:100%; min-width:0; table-layout:fixed; font-family:Tahoma,sans-serif; font-size:11px; letter-spacing:0; line-height:1.25; }
.fiscal-purchase-grid-wrap td { padding:6px 7px; white-space:normal; overflow-wrap:anywhere; vertical-align:top; }
.fiscal-purchase-grid-wrap td:nth-child(1){width:9%}.fiscal-purchase-grid-wrap td:nth-child(2){width:9%}.fiscal-purchase-grid-wrap td:nth-child(3){width:18%}.fiscal-purchase-grid-wrap td:nth-child(4){width:26%}.fiscal-purchase-grid-wrap td:nth-child(5){width:15%}.fiscal-purchase-grid-wrap td:nth-child(6){width:23%}
.fiscal-purchase-grid-wrap td { overflow:hidden; }
.fiscal-purchase-grid-wrap .fiscal-cell-label { display:block; margin-bottom:3px; color:#526b80; font-size:9px; line-height:1; text-transform:uppercase; }
.fiscal-purchase-grid-wrap .fiscal-cell-detail { display:block; margin-top:3px; color:#4c6072; font-size:9.5px; line-height:1.2; }
.fiscal-purchase-record-main td { background:#fff; border-top:2px solid #91b8cc; font-weight:normal; }
.fiscal-purchase-record-tax td { background:#f2f8fb; border-bottom:2px solid #91b8cc; }
@media(max-width:900px){.fiscal-purchase-product dl{grid-template-columns:1fr 1fr}}
.fiscal-audit-grid tr[data-group-code],.fiscal-products-grid-wrap tr[data-product-id] { cursor:pointer; }
.fiscal-audit-grid tr.is-selected { background:#d8f3f0; box-shadow:inset 3px 0 #e77b2f; }
.fiscal-products-dialog { width:min(1280px,98vw); }
.fiscal-products-dialog .dialog-content,.fiscal-history-dialog .dialog-content { display:flex; flex-direction:column; max-height:88vh; }
.fiscal-products-dialog [data-products-subtitle] { max-width:980px; margin:4px 0 0; white-space:normal; line-height:1.35; color:#40546a; }
.fiscal-products-header-actions { display:flex; align-items:end; gap:8px; }
.fiscal-products-header-actions label { display:grid; gap:3px; min-width:180px; font:normal 11px Tahoma,sans-serif; }
.fiscal-products-header-actions select { min-height:32px; }
.fiscal-ncm-hierarchy { display:grid; grid-template-columns:repeat(auto-fit,minmax(210px,1fr)); gap:7px; margin:0 0 8px; }
.fiscal-ncm-hierarchy > div { min-width:0; padding:7px 9px; border:1px solid #c7dceb; border-radius:7px; background:#f6fbfe; }
.fiscal-ncm-hierarchy span { display:block; color:#667b8d; font:normal 10px Tahoma,sans-serif; text-transform:uppercase; }
.fiscal-ncm-hierarchy strong { display:block; margin:2px 0; color:#163e59; font:normal 12px Tahoma,sans-serif; }
.fiscal-ncm-hierarchy p { margin:0; color:#243746; font:normal 11px/1.3 Tahoma,sans-serif; white-space:normal; }
.fiscal-products-grid-wrap { height:58vh; overflow:auto; border:1px solid #c7dceb; }
.fiscal-products-grid-wrap table { width:100%; min-width:0; table-layout:fixed; font-family:Tahoma,sans-serif; font-size:10.5px; letter-spacing:0; line-height:1.18; }
.fiscal-products-grid-wrap th,.fiscal-products-grid-wrap td { padding:5px 5px; }
.fiscal-products-grid-wrap th:nth-child(1){width:34px}.fiscal-products-grid-wrap th:nth-child(2){width:56px}.fiscal-products-grid-wrap th:nth-child(3){width:105px}.fiscal-products-grid-wrap th:nth-child(4){width:205px}.fiscal-products-grid-wrap th:nth-child(5){width:108px}.fiscal-products-grid-wrap th:nth-child(6){width:108px}.fiscal-products-grid-wrap th:nth-child(7){width:70px}.fiscal-products-grid-wrap th:nth-child(8){width:78px}.fiscal-products-grid-wrap th:nth-child(9){width:128px}.fiscal-products-grid-wrap th:nth-child(10){width:112px}.fiscal-products-grid-wrap th:nth-child(11){width:88px}.fiscal-products-grid-wrap th:nth-child(12){width:54px}
.fiscal-products-grid-wrap td { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.fiscal-products-grid-wrap tr.is-marked { background:#d8f3f0; }
.fiscal-products-dialog .action-bar { gap:5px; flex-wrap:wrap; }
.fiscal-products-dialog .action-bar .button { padding:7px 9px; font-size:11px; }
.fiscal-action-dialog { width:min(520px,94vw); }
.fiscal-action-dialog [data-action-fields] { padding:12px 0; }
.fiscal-modal-feedback { margin:8px 0; padding:9px; border:1px solid #9ed2b5; background:#edf9f2; border-radius:6px; color:#17663b; }
.fiscal-modal-feedback.error { border-color:#e0a0a0; background:#fff1f1; color:#9b2525; }
.fiscal-history-dialog { width:min(1100px,96vw); }
.fiscal-history-grid-wrap { height:58vh; overflow:auto; border:1px solid #c7dceb; }
@media (max-width:800px) {
  .fiscal-audit-summary { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .fiscal-audit-filters { grid-template-columns:1fr 1fr; }
  .fiscal-audit-grid-wrap { height:clamp(240px,42vh,360px); min-height:240px; }
}
.products-branch-price-prompt-dialog {
    width: min(430px, calc(100vw - 24px));
}

.products-branch-price-prompt-body {
    min-width: 0;
    gap: 12px;
}

.products-branch-price-prompt-actions {
    justify-content: flex-end;
}
.cloud-load-panel { width: min(1100px, calc(100% - 24px)); margin: 18px auto; overflow: hidden; }
.cloud-load-summary { display: flex; flex-wrap: wrap; gap: 8px 18px; width: fit-content; max-width: 100%; margin: 10px 0; padding: 7px 10px; border: 1px solid #c8d8e5; border-radius: 7px; background: #f7fbfe; }
.cloud-load-summary span { color: #52657a; font-size: 11px; white-space: nowrap; }
.cloud-load-summary strong { margin-left: 4px; color: #17283a; font-size: 12px; }
.cloud-load-actions { margin-top: 14px; }
.cloud-load-progress { margin: 18px 0; padding: 14px; border: 1px solid #c8d8e5; border-radius: 8px; background: #f7fbfe; }
.cloud-load-progress-track { height: 18px; overflow: hidden; border-radius: 9px; background: #dfe9f0; }
.cloud-load-progress-track span { display: block; width: 0; height: 100%; background: #159447; transition: width .2s ease; }
.cloud-load-progress strong { display: block; margin-top: 7px; }
.cloud-load-progress p { margin: 3px 0 0; }
.cloud-load-invoices { margin-top: 14px; padding-top: 12px; border-top: 1px solid #c8d8e5; }
.cloud-load-invoice-filters { display: flex; align-items: flex-end; gap: 8px; margin: 8px 0; }
.cloud-load-invoice-filters label { display: grid; gap: 3px; font-size: 12px; }
.cloud-load-invoice-filters input { min-width: 145px; }
.cloud-load-invoice-grid-wrap { height: 230px; overflow: auto; }
.cloud-load-invoice-grid { width: 100%; min-width: 0; table-layout: fixed; }
.cloud-load-invoice-grid th:first-child, .cloud-load-invoice-grid td:first-child { width: 34px; text-align: center; }
.cloud-load-invoice-grid th:nth-child(2) { width: 145px; }
.cloud-load-invoice-grid th:nth-child(3), .cloud-load-invoice-grid th:nth-child(4) { width: 80px; }
.cloud-load-invoice-grid th:nth-child(6) { width: 90px; }
.cloud-load-invoice-grid th:nth-child(7) { width: 110px; }
.cloud-load-invoice-grid td { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cloud-load-invoice-grid tbody tr[data-cloud-load-invoice-row] { cursor: pointer; }
.cloud-load-invoice-grid tbody tr[data-cloud-load-invoice-row].is-selected { background: #d9efff; box-shadow: inset 3px 0 #ef7b2d; }
.cloud-load-invoice-selected { display: block; margin: 7px 0 0; }
.cloud-load-changed-date { display: flex; align-items: center; gap: 6px; font-size: 12px; }
.cloud-load-changed-date input { width: 145px; }
.cloud-load-products-dialog { width: min(980px, calc(100vw - 24px)); }
.cloud-load-products-dialog .access-dialog-body { width: 100%; max-width: none; }
.cloud-load-products-search { display: flex; align-items: flex-end; gap: 8px; margin: 8px 0; }
.cloud-load-products-search label { display: grid; flex: 1; gap: 3px; font-size: 12px; }
.cloud-load-products-grid-wrap { height: min(430px, 55vh); overflow: auto; }
.cloud-load-products-grid { width: 100%; min-width: 0; table-layout: fixed; }
.cloud-load-products-grid th:first-child, .cloud-load-products-grid td:first-child { width: 38px; text-align: center; }
.cloud-load-products-grid th:nth-child(2) { width: 100px; }
.cloud-load-products-grid th:nth-child(3) { width: 170px; }
.cloud-load-products-grid th:nth-child(5) { width: 110px; text-align: right; }
.cloud-load-products-grid td:nth-child(5) { text-align: right; }
.cloud-load-products-grid td { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cloud-load-products-grid tbody tr[data-cloud-load-product-row] { cursor: pointer; }
.cloud-load-products-grid tbody tr[data-cloud-load-product-row].is-selected { background: #d9efff; box-shadow: inset 3px 0 #ef7b2d; }
@media (max-width: 720px) { .cloud-load-summary { grid-template-columns: 1fr; } }
.stock-price-report-dialog {
    width: min(1380px, 96vw);
    height: min(900px, 94vh);
    padding: 0;
}

.stock-price-report-panel {
    height: 100%;
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr);
    gap: 8px;
    padding: 12px;
}

.stock-price-report-toolbar {
    display: flex;
    align-items: end;
    gap: 8px;
    flex-wrap: wrap;
}

.stock-price-report-toolbar label {
    display: grid;
    gap: 3px;
    min-width: 240px;
}

.stock-price-report-toolbar .product-selection-note {
    margin-left: auto;
}

.stock-price-report-frame {
    width: 100%;
    height: 100%;
    min-height: 420px;
    border: 1px solid #c7d8e2;
    border-radius: 8px;
    background: #fff;
}

@media (max-width: 760px) {
    .stock-price-report-dialog {
        width: 98vw;
        height: 96vh;
    }

    .stock-price-report-toolbar .product-selection-note {
        width: 100%;
        margin-left: 0;
    }
}
.error-dialog.sales-return-dialog {
    width: min(960px, calc(100vw - 16px));
    max-width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
    overflow: hidden;
}
.sales-return-dialog-body {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    max-height: calc(100vh - 18px);
    padding: 12px;
    display: grid;
    grid-template-rows: auto auto auto minmax(120px, 1fr) auto auto;
    gap: 7px;
    overflow: hidden;
}
.sales-return-dialog-body .panel-head { margin: 0; min-width: 0; }
.sales-return-dialog-body .panel-head h2,
.sales-return-dialog-body .panel-head p { margin: 0; }
.sales-return-dialog-body .error-dialog-message { min-width: 0; padding: 9px 11px; overflow-wrap: anywhere; }
.sales-return-participant-grid { display: grid; grid-template-columns: minmax(180px, .7fr) minmax(240px, 1.3fr); gap: 8px; min-width: 0; }
.sales-return-participant-grid label,
.sales-return-dialog-body > label { min-width: 0; margin: 0; }
.sales-return-participant-grid input,
.sales-return-dialog-body textarea { box-sizing: border-box; width: 100%; min-width: 0; }
.sales-return-items-wrap { width: 100%; height: auto; min-height: 120px; max-height: none; overflow-x: hidden; overflow-y: auto; }
.sales-return-items-wrap table { width: 100%; min-width: 0; table-layout: fixed; }
.sales-return-items-wrap th:nth-child(1) { width: 15%; }
.sales-return-items-wrap th:nth-child(2) { width: 31%; }
.sales-return-items-wrap th:nth-child(3) { width: 12%; }
.sales-return-items-wrap th:nth-child(4) { width: 14%; }
.sales-return-items-wrap th:nth-child(5) { width: 28%; }
.sales-return-items-wrap th,
.sales-return-items-wrap td { overflow: hidden; overflow-wrap: anywhere; text-overflow: ellipsis; }
.sales-return-items-wrap input,
.sales-return-items-wrap select { box-sizing: border-box; width: 100%; min-width: 0; padding: 5px 6px; }
.sales-return-dialog-body .form-actions { margin: 0; padding-top: 2px; flex-wrap: wrap; }
@media (max-width: 620px) {
    .sales-return-participant-grid { grid-template-columns: 1fr 1.35fr; }
    .sales-return-items-wrap th:nth-child(1),
    .sales-return-items-wrap td:nth-child(1) { display: none; }
    .sales-return-items-wrap th:nth-child(2) { width: 38%; }
    .sales-return-items-wrap th:nth-child(3) { width: 14%; }
    .sales-return-items-wrap th:nth-child(4) { width: 17%; }
    .sales-return-items-wrap th:nth-child(5) { width: 31%; }
}
.inventory-approval-dialog{width:min(1320px,96vw)}.inventory-native-preview{width:min(1240px,96vw)}.expiration-edit-dialog{width:min(560px,94vw)}.inventory-approval-dialog .inline-form{display:inline-block;margin-left:4px}
.inventory-expiration-toolbar {
    display: grid;
    grid-template-columns: minmax(180px, 1.35fr) 120px 140px 140px minmax(230px, 1.5fr) auto auto;
    gap: 8px;
    align-items: end;
    margin-bottom: 10px;
}
.inventory-expiration-toolbar label { margin: 0; }
.inventory-expiration-toolbar input,
.inventory-expiration-toolbar select { width: 100%; }
.inventory-expiration-search { min-width: 0; }
.expiration-product-search-dialog .access-dialog-body { width: min(760px, 92vw); }
.expiration-product-search-dialog .products-grid-wrap { height: min(390px, 52vh); margin-top: 8px; overflow-x: hidden; }
.expiration-product-search-bar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.expiration-product-search-bar input { width: 100%; min-width: 0; }
.expiration-product-results-grid { width: 100%; table-layout: fixed; }
.expiration-product-results-grid th,
.expiration-product-results-grid td { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.expiration-product-results-grid .expiration-col-sku { width: 15%; }
.expiration-product-results-grid .expiration-col-barcode { width: 24%; }
.expiration-product-results-grid .expiration-col-description { width: 53%; }
.expiration-product-results-grid .expiration-col-unit { width: 8%; }
.expiration-product-search-dialog tbody tr { cursor: pointer; }
.expiration-product-search-dialog tbody tr:focus,
.expiration-product-search-dialog tbody tr:hover { background: #fff1e7; outline: none; }
@media (max-width: 1050px) {
    .inventory-expiration-toolbar { grid-template-columns: repeat(3, minmax(130px, 1fr)); }
    .inventory-expiration-search { grid-column: span 2; }
}

/* Controle fiscal de creditos de ICMS: consulta compacta, sem hierarquia tipografica pesada. */
.icms-credit-page { padding: 12px; font-family: Tahoma, Arial, sans-serif; font-size: 12px; }
.icms-credit-page, .icms-credit-page * { font-weight: normal; }
.icms-credit-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.icms-credit-header h1 { margin: 0; font-size: 16px; line-height: 1.2; font-weight: normal; }
.icms-credit-header p { margin: 2px 0 0; font-size: 11px; color: #52647a; }
.icms-credit-filters { display: grid; grid-template-columns: 120px 120px minmax(210px, 1fr) minmax(150px, 1fr) minmax(170px, 1fr) auto auto; gap: 7px; align-items: end; margin-bottom: 7px; }
.icms-credit-filters label { display: grid; gap: 3px; font-size: 11px; min-width: 0; }
.icms-credit-filters select { width: 100%; min-width: 0; }
.icms-credit-filters input, .icms-credit-filters select, .icms-credit-filters .button { min-height: 32px; font: normal 12px Tahoma, Arial, sans-serif; }
.icms-credit-summary { display: flex; gap: 18px; padding: 6px 8px; border: 1px solid #c9dbea; background: #f4f9fc; color: #334a60; }
.icms-credit-grid-wrap { height: calc(100vh - 285px); min-height: 310px; overflow: auto; border: 1px solid #c9dbea; border-top: 0; }
.icms-credit-grid { min-width: 1770px; font-size: 11px; }
.icms-credit-grid th, .icms-credit-grid td { padding: 5px 6px; white-space: nowrap; font-weight: normal; }
.icms-credit-grid td:nth-child(4), .icms-credit-grid td:nth-child(7) { max-width: 245px; overflow: hidden; text-overflow: ellipsis; }
.icms-credit-grid tbody tr { cursor: pointer; }
.icms-credit-grid tbody tr.is-selected { background: #d8f2ef; outline: 1px solid #36aaa2; outline-offset: -1px; }
.icms-credit-grid .number { text-align: right; font-variant-numeric: tabular-nums; }
.icms-credit-footer { min-height: 38px; font-size: 11px; }
.icms-credit-footer span:last-child { margin-left: auto; color: #5b6b7b; }
.icms-usage-dialog { width: min(1050px, calc(100vw - 36px)); }
.icms-usage-dialog .dialog-content { font: normal 11px Tahoma, Arial, sans-serif; }
.icms-usage-dialog h2 { font-size: 15px; font-weight: normal; }
.icms-usage-dialog p, .icms-usage-dialog th, .icms-usage-dialog td, .icms-usage-dialog button { font-weight: normal; }
.icms-usage-grid-wrap { height: min(430px, 55vh); overflow: auto; border: 1px solid #c9dbea; }
@media (max-width: 980px) {
    .icms-credit-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .icms-credit-grid-wrap { height: calc(100vh - 350px); }
}
.sales-fiscal-only-menu {
    position: relative;
}

.sales-fiscal-only-menu > summary {
    list-style: none;
    cursor: pointer;
}

.sales-fiscal-only-menu > summary::-webkit-details-marker {
    display: none;
}

.sales-fiscal-only-menu-options {
    position: absolute;
    z-index: 30;
    bottom: calc(100% + 6px);
    left: 0;
    display: flex;
    gap: 5px;
    padding: 7px;
    border: 1px solid #bed5df;
    border-radius: 7px;
    background: #fff;
    box-shadow: 0 8px 20px rgb(16 38 51 / 18%);
    white-space: nowrap;
}
.company-store-api-actions {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 4px;
    border: 1px solid var(--line, #d5e2e8);
    border-radius: 8px;
    background: var(--panel-soft, #f6fafb);
}
.nfe-return-transport-overlay{position:fixed;inset:0;z-index:10080;display:grid;place-items:center;padding:18px;background:rgba(15,31,38,.58);backdrop-filter:blur(2px)}
.nfe-return-transport-overlay[hidden]{display:none}
.nfe-return-transport-dialog{width:min(720px,calc(100vw - 24px));max-height:calc(100vh - 24px);overflow:auto;padding:11px;border:1px solid #c9dce4;border-radius:13px;background:#fff;box-shadow:0 24px 70px rgba(7,28,36,.32);font:normal 11px Tahoma,Arial,sans-serif}
.nfe-return-transport-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.nfe-return-transport-head>div{display:grid;gap:2px}.nfe-return-transport-head strong{font-size:17px;color:#183d48}.nfe-return-transport-head small{color:#667d86}
.nfe-return-transport-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}.nfe-return-transport-grid-three{grid-template-columns:2fr 1fr 2fr}.nfe-return-volume-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.nfe-return-transport-grid label{display:grid;gap:2px;color:#4d6670}.nfe-return-transport-grid input,.nfe-return-transport-grid select,.nfe-return-transport-grid textarea{min-height:28px;padding:4px 7px;font:normal 11px Tahoma,Arial,sans-serif}.nfe-return-transport-grid textarea{min-height:58px;resize:vertical}.nfe-return-transport-wide{grid-column:1/-1}.nfe-return-transport-section{padding:7px;border:1px solid #d8e5e9;border-radius:8px;background:#f9fbfc}.nfe-return-transport-section>strong{display:block;margin-bottom:5px;color:#234955}.nfe-return-transport-section.is-disabled{opacity:.48}
@media(max-width:700px){.nfe-return-transport-grid,.nfe-return-transport-grid-three,.nfe-return-volume-grid{grid-template-columns:1fr}}
.planning-page{display:grid;gap:12px}.planning-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:4px 2px}.planning-head h1{margin:2px 0 3px;font-size:26px;color:#173b46}.planning-head p,.planning-chart p,.planning-table p{margin:0;color:#71838b}.planning-eyebrow{font-size:10px;letter-spacing:.16em;color:#e2762d}.planning-filter{display:flex;gap:9px;align-items:end;flex-wrap:wrap;padding:12px}.planning-filter>label{display:grid;gap:4px;font-size:11px;color:#536b75}.planning-filter select,.planning-filter input{min-height:35px}.planning-filter details{width:100%;border-top:1px solid #dce8eb;padding-top:8px}.planning-filter summary{cursor:pointer;color:#0a766a}.planning-assumptions{display:grid;grid-template-columns:repeat(5,minmax(120px,1fr));gap:8px;margin-top:9px}.planning-assumptions label{display:grid;gap:4px;font-size:10px;color:#59717b}.planning-kpis{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.planning-kpis article,.planning-health article{background:#fff;border:1px solid #d8e6ea;border-radius:12px;padding:14px;box-shadow:0 5px 18px rgba(18,61,72,.05)}.planning-kpis span,.planning-health span{display:block;color:#647b85;font-size:11px}.planning-kpis strong,.planning-health strong{display:block;font-size:21px;margin:7px 0 4px}.planning-kpis small,.planning-health small{color:#82949b}.planning-kpis .teal{color:#078875}.planning-kpis .blue{color:#397fc2}.planning-kpis .orange{color:#dc712d}.planning-kpis .violet{color:#7157a5}.planning-health{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.planning-health strong{font-size:17px;color:#183d48}.planning-chart-grid{display:grid;grid-template-columns:2fr 1fr;gap:10px}.planning-chart{height:330px;padding:15px}.planning-chart>div{height:42px}.planning-chart h2,.planning-reading h2,.planning-table h2{margin:0 0 3px;font-size:16px}.planning-chart canvas{width:100%!important;height:255px!important}.planning-reading{padding:15px}.planning-reading ul{list-style:none;padding:0;margin:12px 0}.planning-reading li{display:flex;justify-content:space-between;gap:8px;padding:9px 0;border-bottom:1px solid #e5edef}.planning-warning{background:#fff4e8;border-left:3px solid #e77b31;padding:10px;color:#72513b;font-size:11px}.planning-table{padding:15px}.planning-table .table-scroll{max-height:330px;overflow:auto;margin-top:10px}.planning-table table{width:100%;border-collapse:collapse}.planning-table th{position:sticky;top:0;background:#edf5f6;color:#526b75}.planning-table th,.planning-table td{padding:9px;text-align:right;border-bottom:1px solid #e2eaed;white-space:nowrap}.planning-table th:first-child,.planning-table td:first-child{text-align:left}.planning-table .positive{color:#087c69;font-weight:bold}.planning-table .negative{color:#c64d3f;font-weight:bold}@media(max-width:980px){.planning-kpis,.planning-health{grid-template-columns:repeat(2,1fr)}.planning-assumptions{grid-template-columns:repeat(2,1fr)}.planning-chart-grid{grid-template-columns:1fr}}@media(max-width:560px){.planning-head{align-items:flex-start;flex-direction:column}.planning-kpis,.planning-health{grid-template-columns:1fr}.planning-assumptions{grid-template-columns:1fr}.planning-chart{height:300px}.planning-chart canvas{height:225px!important}}
.planning-loading-overlay{position:fixed;inset:0;z-index:10050;display:grid;place-items:center;background:rgba(12,35,42,.6);backdrop-filter:blur(3px)}.planning-loading-overlay[hidden]{display:none}.planning-loading-card{display:grid;justify-items:center;gap:10px;width:min(410px,calc(100vw - 32px));padding:26px;border:1px solid #d9e8eb;border-radius:16px;background:#fff;box-shadow:0 24px 70px rgba(8,30,36,.32);text-align:center}.planning-loading-card strong{font-size:18px;color:#173b46}.planning-loading-card small{max-width:340px;color:#6b7f87;line-height:1.45}.planning-loading-spinner{width:44px;height:44px;border:4px solid #dceceb;border-top-color:#e47b32;border-radius:50%;animation:planning-loading-spin .75s linear infinite}@keyframes planning-loading-spin{to{transform:rotate(360deg)}}
.planning-kpis{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}
.planning-kpis,.planning-health{gap:7px}.planning-kpis article,.planning-health article{padding:9px 12px;border-radius:9px;box-shadow:0 2px 8px rgba(18,61,72,.04)}.planning-kpis strong{font-size:18px;margin:3px 0 2px}.planning-health strong{font-size:15px;margin:3px 0 2px}.planning-kpis small,.planning-health small{font-size:10px}.planning-filter{padding:8px 12px}.planning-head h1{font-size:23px}
.planning-quality{display:flex;align-items:center;gap:12px;padding:9px 12px;border:1px solid #f0c996;border-left:4px solid #e67e31;border-radius:8px;background:#fff8ed;color:#6d5138;font-size:11px}.planning-quality strong{white-space:nowrap;color:#b65d20}.planning-table .table-scroll{overflow:auto}.planning-table table{min-width:1580px}.planning-unavailable{height:230px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;gap:8px;color:#667e89;background:#f6f9fa;border:1px dashed #b9cbd1;border-radius:10px;padding:20px}.planning-unavailable strong{color:#173d48;font-size:18px}.planning-unavailable span{max-width:470px}
.gestor-customer-center-card,.gestor-brand-compact{position:relative;margin:8px 7px 10px;padding:9px 25px 9px 8px;min-height:52px;border:1px solid #ead0d1;border-radius:10px;background:#fff;display:flex;align-items:center;gap:7px;text-decoration:none;color:#34383b;box-shadow:0 3px 10px rgba(61,25,28,.06);overflow:hidden}
.gestor-customer-center-card:hover{border-color:#d71920;background:#fff8f8;transform:translateY(-1px)}
.gestor-customer-center-icon{width:25px;height:25px;display:grid;place-items:center;flex:0 0 25px}.gestor-customer-center-icon img{display:block;width:25px;height:25px;object-fit:contain}
.gestor-customer-center-copy{display:block;min-width:0}.gestor-customer-center-card strong,.gestor-brand-compact strong{display:block;white-space:nowrap;font:normal 10px Tahoma,sans-serif;color:#282b2e}.gestor-customer-center-card small,.gestor-brand-compact small{display:block;margin-top:3px;color:#777;font:9px Tahoma,sans-serif}.gestor-customer-center-status[hidden]{display:none!important}.gestor-customer-center-status{position:absolute;right:6px;top:7px;min-width:18px;height:18px;border-radius:20px;background:#f2ecec;color:#6c6060;padding:3px 5px;text-align:center;font:9px Tahoma,sans-serif}.gestor-customer-center-status.attention{background:#ffdede;color:#bd1c25}.gestor-customer-center-status.clear{background:#e9eeee;color:#60706f}
.gestor-customer-center-card strong{white-space:normal;line-height:1.08;padding-right:2px}
.products-export-options {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 12px 0;
}
.products-export-option {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 5px 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid #d7e3e8;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
}
.products-export-option > span { font-weight: 600; }
.products-export-option > input { grid-column: 2; grid-row: 1 / span 2; }
.products-export-option > small { color: #586b75; font-weight: normal; line-height: 1.35; }
@media (max-width: 720px) {
    .products-export-options { grid-template-columns: 1fr; }
}
.dfe-event-dialog {
    width: min(980px, calc(100vw - 32px));
    max-height: calc(100vh - 32px);
    padding: 0;
    border: 0;
    border-radius: 18px;
    color: #173044;
    background: #fffdfa;
    box-shadow: 0 24px 70px rgba(13, 36, 48, .32);
}

.dfe-event-dialog::backdrop {
    background: rgba(14, 30, 38, .62);
    backdrop-filter: blur(2px);
}

.dfe-event-dialog-body {
    padding: 22px;
    overflow: auto;
    max-height: calc(100vh - 32px);
}

.dfe-event-dialog-head {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
    padding-bottom: 14px;
    border-bottom: 1px solid #dbe7eb;
}

.dfe-event-dialog-head h2,
.dfe-event-dialog-head p {
    margin: 2px 0 0;
}

.dfe-event-loading {
    margin-top: 16px;
    padding: 22px;
    border-radius: 12px;
    background: #eef6f8;
    color: #315264;
    text-align: center;
}

.dfe-event-summary,
.dfe-event-parties,
.dfe-event-detail-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.dfe-event-summary,
.dfe-event-parties {
    margin-top: 14px;
    padding: 14px;
    border: 1px solid #d8e5e9;
    border-radius: 13px;
    background: #f8fbfc;
}

.dfe-event-parties {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.dfe-event-field {
    min-width: 0;
}

.dfe-event-field.wide {
    grid-column: 1 / -1;
}

.dfe-event-field span {
    display: block;
    margin-bottom: 3px;
    color: #67808d;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.dfe-event-field strong {
    display: block;
    overflow-wrap: anywhere;
    font-size: 13px;
    font-weight: 600;
}

.dfe-event-timeline-wrap {
    margin-top: 18px;
}

.dfe-event-timeline-wrap h3 {
    margin: 0 0 10px;
}

.dfe-event-timeline {
    display: grid;
    gap: 10px;
}

.dfe-event-timeline-item {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 10px;
}

.dfe-event-marker {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #0b8d75;
    color: #fff;
    font-weight: 700;
}

.dfe-event-timeline-item.cancelled .dfe-event-marker {
    background: #c74343;
}

.dfe-event-timeline-body {
    padding: 13px;
    border: 1px solid #d8e5e9;
    border-radius: 12px;
    background: #fff;
}

.dfe-event-timeline-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 11px;
}

.dfe-event-timeline-head time {
    color: #617984;
    white-space: nowrap;
    font-size: 12px;
}

.dfe-event-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.dfe-event-explanation {
    margin: 0 0 10px;
    color: #334f5e;
    line-height: 1.45;
}

.dfe-event-friendly-status {
    display: inline-flex;
    width: fit-content;
    margin-bottom: 9px;
    padding: 5px 9px;
    border-radius: 999px;
    background: #e5f6f1;
    color: #087660;
    font-size: 12px;
}

.dfe-event-friendly-status.cancelled {
    background: #fdeaea;
    color: #a52f2f;
}

.dfe-event-technical {
    border-top: 1px solid #e5edef;
    padding-top: 9px;
}

.dfe-event-technical summary {
    width: fit-content;
    color: #526d79;
    cursor: pointer;
    font-size: 12px;
}

.dfe-event-technical[open] summary {
    margin-bottom: 10px;
}

.dfe-event-technical .compact-actions {
    margin-top: 10px;
}

@media (max-width: 720px) {
    .dfe-event-dialog {
        width: calc(100vw - 16px);
    }

    .dfe-event-summary,
    .dfe-event-parties,
    .dfe-event-detail-grid {
        grid-template-columns: 1fr;
    }

    .dfe-event-timeline-head {
        display: grid;
    }
}

/* O widget externo conserva o texto para acessibilidade, mas exibe apenas o icone. */
body > button.elo2g-btn {
    width: 48px;
    height: 48px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
}

body > button.elo2g-btn > span:not(.elo2g-btn-ico):not(.elo2g-btn-count) {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

body > button.elo2g-btn > .elo2g-btn-count {
    position: absolute;
    top: -4px;
    right: -4px;
}

@media (max-width: 640px) {
    [data-products-stock-documents-dialog] {
        position: fixed;
        inset: 8px;
        width: calc(100vw - 16px);
        max-width: none;
        height: calc(100dvh - 16px);
        max-height: none;
        margin: 0;
        overflow: hidden;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-body {
        display: block;
        min-width: 0;
        height: 100%;
        max-height: none;
        padding: 10px 10px max(16px, env(safe-area-inset-bottom));
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-body > * + * {
        margin-top: 8px;
    }

    [data-products-stock-documents-dialog] .products-tax-head,
    [data-products-stock-documents-dialog] .products-tax-head > div,
    [data-products-stock-documents-dialog] .products-stock-documents-filter,
    [data-products-stock-documents-dialog] .products-stock-documents-grid-wrap {
        min-width: 0;
        max-width: 100%;
    }

    [data-products-stock-documents-dialog] .products-tax-head p {
        white-space: normal;
        overflow-wrap: anywhere;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-filter > label,
    [data-products-stock-documents-dialog] .products-stock-documents-filter > button {
        min-width: 0;
    }

    [data-products-stock-documents-dialog] .stock-documents-filter-supplier {
        grid-column: 1 / -1;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-grid-wrap {
        height: min(24dvh, 200px);
        min-height: 110px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-grid {
        width: 100%;
        min-width: 0;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-grid colgroup {
        display: none;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-grid th:nth-child(n+3):nth-child(-n+8),
    [data-products-stock-documents-dialog] .products-stock-documents-grid td:nth-child(n+3):nth-child(-n+8) {
        display: none;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-grid th,
    [data-products-stock-documents-dialog] .products-stock-documents-grid td {
        padding: 5px 4px;
        overflow: hidden;
        font-size: 10px;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    [data-products-stock-documents-dialog] .products-stock-documents-grid th:nth-child(1),
    [data-products-stock-documents-dialog] .products-stock-documents-grid td:nth-child(1) { width: 12%; }
    [data-products-stock-documents-dialog] .products-stock-documents-grid th:nth-child(2),
    [data-products-stock-documents-dialog] .products-stock-documents-grid td:nth-child(2) { width: 32%; }
    [data-products-stock-documents-dialog] .products-stock-documents-grid th:nth-child(9),
    [data-products-stock-documents-dialog] .products-stock-documents-grid td:nth-child(9) { width: 24%; }
    [data-products-stock-documents-dialog] .products-stock-documents-grid th:nth-child(10),
    [data-products-stock-documents-dialog] .products-stock-documents-grid td:nth-child(10) { width: 32%; }

    [data-products-stock-documents-dialog] .products-stock-documents-action-bar {
        max-height: none;
        overflow: visible;
    }

    [data-stock-entry-dialog] {
        position: fixed;
        inset: 8px;
        width: calc(100vw - 16px);
        max-width: none;
        height: calc(100dvh - 16px);
        max-height: none;
        margin: 0;
        overflow: hidden;
        background: #fff;
    }

    [data-stock-entry-dialog] .stock-document-entry-panel {
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        height: 100%;
        margin: 0;
        padding: 10px 10px max(16px, env(safe-area-inset-bottom));
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    [data-stock-entry-dialog] .stock-document-entry-panel .panel-head,
    [data-stock-entry-dialog] .stock-document-form,
    [data-stock-entry-dialog] .stock-document-form-grid,
    [data-stock-entry-dialog] .stock-document-fast-row,
    [data-stock-entry-dialog] .stock-document-items-wrap {
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        max-width: 100%;
    }

    [data-stock-entry-dialog] .stock-document-form-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    [data-stock-entry-dialog] .stock-document-form-grid .wide {
        grid-column: 1 / -1;
    }

    [data-stock-entry-dialog] .stock-document-form-grid .checkbox-field {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    [data-stock-entry-dialog] .stock-document-form-grid input[type="checkbox"] {
        width: auto;
        min-width: 18px;
    }

    [data-stock-entry-dialog] .stock-document-fast-row,
    [data-stock-entry-dialog] .stock-document-fast-row.is-manual-entry,
    [data-stock-entry-dialog] .stock-document-fast-row[data-stock-current-type="manual_entry"] {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    [data-stock-entry-dialog] .stock-product-code-field,
    [data-stock-entry-dialog] .stock-product-description-field,
    [data-stock-entry-dialog] [data-stock-search-product],
    [data-stock-entry-dialog] [data-stock-add-product] {
        grid-column: 1 / -1;
    }

    [data-stock-entry-dialog] .stock-document-items-wrap {
        height: 170px;
        min-height: 120px;
        overflow-x: auto;
    }
}

/* Atalhos de periodo do dashboard: datas somente na janela personalizada. */
.dashboard-overview-compact .dashboard-overview-head { grid-template-columns: auto minmax(0, 1fr); align-items: center; }
.dashboard-overview-compact .operational-dashboard-filter,
.dashboard-overview-compact .operational-dashboard-filter:not(:has(.dashboard-company-scope)) { display: flex; flex-wrap: wrap; align-items: end; justify-content: flex-end; gap: 6px; width: 100%; }
.dashboard-overview-compact .dashboard-company-scope { flex: 0 1 280px; min-width: 180px; }
.dashboard-period-actions { display: flex; flex-wrap: wrap; gap: 4px; }
.dashboard-period-button { min-height: 32px; padding: 6px 10px; border: 1px solid #d6e2e8; border-radius: 8px; background: #f4f8fa; color: #314653; font: normal 12px Tahoma, sans-serif; cursor: pointer; }
.dashboard-period-button:hover { background: #e8f3f5; }
.dashboard-period-button.is-active { border-color: #13806b; background: #13806b; color: #fff; }
.dashboard-period-button:focus-visible { outline: 2px solid #0a6e98; outline-offset: 2px; }
.dashboard-date-dialog { width: min(440px, calc(100vw - 32px)); max-width: none; padding: 18px; border: 1px solid #d6e2e8; border-radius: 14px; box-shadow: 0 16px 48px #18333c40; color: var(--text); }
.dashboard-date-dialog::backdrop { background: #172b36a6; }
.dashboard-date-dialog h3 { margin: 0 0 14px; font-size: 17px; }
.dashboard-date-dialog-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.dashboard-date-dialog-fields label { display: grid; gap: 5px; }
.dashboard-date-dialog-fields input { width: 100%; box-sizing: border-box; }
.dashboard-date-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
@media (max-width: 820px) {
    .dashboard-overview-compact .dashboard-overview-head { grid-template-columns: minmax(0, 1fr); }
    .dashboard-overview-compact .operational-dashboard-filter,
    .dashboard-overview-compact .operational-dashboard-filter:not(:has(.dashboard-company-scope)) { justify-content: flex-start; }
    .dashboard-overview-compact .dashboard-company-scope { flex: 1 1 100%; }
    .dashboard-period-actions { width: 100%; }
    .dashboard-period-button { flex: 1 1 auto; }
}

/* Resumo fiscal compacto e responsivo. */
.dashboard-fiscal-layout { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; }
.dashboard-fiscal-summary { display: grid; gap: 10px; min-width: 0; }
.dashboard-fiscal-total { display: grid; gap: 3px; padding: 14px; border: 1px solid #dce9e5; border-left: 4px solid #16806a; border-radius: 12px; background: #f7fbf9; }
.dashboard-fiscal-total span, .dashboard-fiscal-models span { color: #526173; font-size: 11px; }
.dashboard-fiscal-total strong { color: #116e5d; font-size: clamp(20px, 3vw, 29px); font-weight: 600; }
.dashboard-fiscal-total small, .dashboard-fiscal-models small { color: #526173; font-size: 11px; }
.dashboard-fiscal-models { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.dashboard-fiscal-models > div { display: grid; gap: 4px; min-width: 0; padding: 11px; border: 1px solid #e6e7eb; border-radius: 12px; background: #fff; }
.dashboard-fiscal-models strong { color: #252831; font-size: 15px; overflow-wrap: anywhere; }
.dashboard-fiscal-chart { display: grid; justify-items: center; gap: 10px; min-width: 120px; }
.dashboard-fiscal-donut { width: 110px; height: 110px; border-radius: 50%; mask: radial-gradient(farthest-side, transparent 58%, #000 60%); }
.dashboard-fiscal-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; font-size: 11px; }
.dashboard-fiscal-legend span { display: inline-flex; align-items: center; gap: 4px; }
.dashboard-fiscal-legend i { width: 9px; height: 9px; border-radius: 50%; }
.dashboard-fiscal-legend i.nfce { background: #16806a; }
.dashboard-fiscal-legend i.nfe { background: #3e7481; }
.dashboard-fiscal-series { display: grid; gap: 8px; margin-top: 16px; }
.dashboard-fiscal-series h3 { margin: 0; font-size: 14px; }
.dashboard-fiscal-series-row { display: grid; grid-template-columns: 70px minmax(0, 1fr) 100px 75px; gap: 8px; align-items: center; font-size: 11px; }
.dashboard-fiscal-series-row strong, .dashboard-fiscal-series-row small { text-align: right; white-space: nowrap; }
.dashboard-fiscal-series-row strong { color: #252831; }
.dashboard-fiscal-series-row small { color: #526173; }
.dashboard-fiscal-series-bar { height: 8px; overflow: hidden; border-radius: 999px; background: #edf2f2; }
.dashboard-fiscal-series-bar i { display: block; height: 100%; border-radius: inherit; background: #16806a; }
.dashboard-fiscal-note { margin: 12px 0 0; color: #526173; font-size: 10px; line-height: 1.4; }
.dashboard-fiscal-tabs { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 10px; margin-bottom: 10px; scrollbar-width: thin; }
.dashboard-fiscal-tab { flex: 0 0 auto; max-width: min(240px, 70vw); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; border: 1px solid #cbdde0; border-radius: 999px; background: #f5faf9; color: #355463; padding: 7px 12px; font: normal 12px Tahoma, sans-serif; cursor: pointer; }
.dashboard-fiscal-tab.is-active { background: #16806a; border-color: #16806a; color: #fff; }
.dashboard-fiscal-tab:focus-visible { outline: 2px solid #ea873a; outline-offset: 2px; }
.dashboard-fiscal-card [data-dashboard-fiscal-panel][hidden] { display: none; }
.dashboard-filter-loading[hidden] { display: none; }
.dashboard-filter-loading { position: fixed; inset: 0; z-index: 9999; display: grid; place-items: center; padding: 20px; background: rgba(19, 34, 43, .48); }
.dashboard-filter-loading-box { display: grid; gap: 10px; width: min(400px, 100%); padding: 22px; border-radius: 14px; background: #fff; box-shadow: 0 12px 42px rgba(0, 0, 0, .2); color: #24404b; }
.dashboard-filter-loading-box strong { font-size: 17px; }
.dashboard-filter-loading-box span { font-size: 12px; }
.dashboard-filter-loading-bar { height: 8px; overflow: hidden; border-radius: 999px; background: #dcebe7; }
.dashboard-filter-loading-bar i { display: block; width: 35%; height: 100%; border-radius: inherit; background: #16806a; animation: dashboard-filter-progress 1.2s ease-in-out infinite alternate; }
@keyframes dashboard-filter-progress { from { transform: translateX(0); } to { transform: translateX(185%); } }
@media (max-width: 620px) {
    .dashboard-fiscal-layout { grid-template-columns: minmax(0, 1fr); }
    .dashboard-fiscal-chart { grid-row: 1; grid-template-columns: auto 1fr; justify-items: start; min-width: 0; }
    .dashboard-fiscal-donut { width: 58px; height: 58px; }
    .dashboard-fiscal-legend { justify-content: start; }
    .dashboard-fiscal-series-row { grid-template-columns: 58px minmax(0, 1fr) 86px; gap: 5px; }
    .dashboard-fiscal-series-row small { display: none; }
}

/* Seletor de empresas: busca e grade responsiva, 09/11/2026. */
.company-switch-toolbar{display:grid;grid-template-columns:minmax(0,1fr) 165px auto;gap:10px;align-items:end}
.company-switch-toolbar label{display:flex;flex-direction:column;gap:5px;min-width:0;font-size:12px;color:#43556c}
.company-switch-toolbar input,.company-switch-toolbar select{box-sizing:border-box;width:100%;min-width:0;height:36px;margin:0;padding:6px 9px;font:400 14px Tahoma,Arial,sans-serif}
.company-switch-toolbar button,.company-switch-actions button{font:400 13px Tahoma,Arial,sans-serif;min-height:36px}
.company-switch-summary{font-size:12px;color:#56677a;min-height:18px}
.company-switch-list{display:block;height:min(460px,48vh);max-height:none;min-height:110px;padding:0;border:1px solid #d5e0e8;border-radius:6px;background:#fff;overflow:auto;overscroll-behavior:contain}
.company-switch-option{display:grid;grid-template-columns:minmax(100px,0.7fr) 155px minmax(0,1.8fr);width:100%;min-width:0;min-height:40px;padding:8px 10px;gap:10px;font:400 13px Tahoma,Arial,sans-serif}
.company-switch-option[hidden],.company-switch-empty[hidden]{display:none!important}
.company-switch-cell{font-size:12px;line-height:1.35;font-weight:400}
.company-switch-name{font-weight:400;white-space:normal;overflow-wrap:anywhere;display:block}
.company-switch-role{display:inline-block;margin-right:5px;font-weight:400}
.company-switch-option:focus-visible{outline:2px solid #157a73;outline-offset:-2px}
.company-switch-empty{margin:0;padding:12px;background:#f5f8fb;border-radius:5px;font-size:13px}
.company-switch-dialog{max-height:calc(100dvh - 24px);padding:16px;box-sizing:border-box}
.company-switch-body{min-width:0;max-height:none;overflow:visible;padding:0}
.company-switch-actions{padding-top:5px;flex-wrap:wrap}
@media(max-width:600px){
 .company-switch-dialog{width:calc(100vw - 16px);max-width:none;max-height:calc(100dvh - 16px);padding:12px}
 .company-select-panel{padding:12px;min-width:0}
 .company-switch-toolbar{grid-template-columns:minmax(0,1fr) auto;gap:8px}
 .company-switch-search{grid-column:1/-1}
 .company-switch-toolbar input,.company-switch-toolbar select{font-size:16px;height:40px}
 .company-switch-toolbar button{min-height:40px}
 .company-switch-option{display:grid;grid-template-columns:minmax(0,1fr) auto;min-height:66px;gap:3px 8px;align-items:start}
 .company-switch-name{grid-column:1/-1;grid-row:1;font-size:13px}
 .company-switch-document{font-size:11px;white-space:nowrap}
 .company-switch-alias{font-size:11px;overflow-wrap:anywhere}
 .company-switch-list{height:clamp(110px,42dvh,420px)}
 .company-switch-actions button{flex:1;min-height:40px}
}
.company-switch-dialog{background:#fff;border:1px solid #d5e0e8}.company-switch-body{border:0;border-radius:0}
/* Consulta opcional de última venda no Controle de Estoque. */
.products-main-grid [hidden]{display:none!important}
.products-main-grid col[hidden]{display:none!important;visibility:collapse}
.products-main-grid.has-last-sale{min-width:1500px}
.products-main-grid col.products-col-last-sale{width:145px}
.products-main-grid .products-last-sale-cell{white-space:nowrap}
.products-toolbar .products-filter-last-sale{grid-column:span 3;min-width:0;white-space:normal}
@media(max-width:720px){.products-toolbar .products-filter-last-sale{grid-column:1/-1}}


/* Auditoria e vendas: filtros responsivos, 11/11/2026. */
@media (min-width: 701px) and (max-width: 1100px) {
    .pdv-management-filters > .pdv-management-company-filter {
        grid-column: span 2;
    }
}
@media (max-width: 700px) {
    .pdv-management-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }
    .pdv-management-filters > label,
    .pdv-management-filters > .button {
        grid-column: auto / span 1;
        min-width: 0;
        max-width: 100%;
    }
    .pdv-management-filters > .pdv-management-date,
    .pdv-management-filters > .pdv-management-pdv-filter,
    .pdv-management-filters > .pdv-management-company-filter,
    .pdv-management-filters > .pdv-management-search,
    .pdv-management-filters > .pdv-management-operator-filter {
        grid-column: 1 / -1;
    }
    .pdv-management-filters input,
    .pdv-management-filters select {
        box-sizing: border-box;
        max-width: 100%;
        min-height: 42px;
        font-size: 16px;
    }
    .pdv-management-filters input[type="date"] {
        display: block;
        min-inline-size: 0;
        -webkit-appearance: none;
        appearance: none;
    }
    .pdv-management-filters > .button {
        width: 100%;
        min-height: 42px;
        font-family: Tahoma, sans-serif;
        font-weight: 400;
        white-space: nowrap;
    }
}
