/* Mesma sequência de pagamentos na calculadora e no relatório. */
#calculationReceipts .payment-flow {
    max-width: none;
    table-layout: auto;
    margin: 0;
    font-size: 0.8rem;
}
#calculationReceipts caption {
    padding: 14px 16px 8px;
    text-align: left;
    font-weight: 600;
    color: var(--c-text, #243746);
}
#calculationReceipts :is(th, td) { padding: 10px 16px; text-align: right; vertical-align: top; }
#calculationReceipts :is(th, td):first-child,
#calculationReceipts :is(th, td):nth-child(4) { text-align: left; }
#calculationReceipts :is(th, td):nth-child(4) { min-width: 180px; }
.calc-view .calc-data-table.parcels-table > tbody > tr.payment-subrow > td,
.main-table > tbody > .payment-subrow > td {
    padding: 3px 16px 7px;
    background: #f8fafb;
    border-top: 0;
}
.calc-view .calc-data-table.parcels-table > tbody > tr.payment-subrow > td { padding-right: 100px; }
.payment-flow {
    width: 100%;
    max-width: 640px;
    margin-left: auto;
    table-layout: fixed;
    border-collapse: collapse;
    color: #4b5d6b;
    font-size: 0.7rem;
    font-variant-numeric: tabular-nums;
}
.parcels-table .payment-flow th,
.parcels-table .payment-flow td,
.main-table .payment-flow th,
.main-table .payment-flow td {
    height: auto;
    padding: 3px 10px;
    background: transparent;
    border: 0;
    text-align: right;
    font-size: inherit;
    line-height: 1.4;
    white-space: nowrap;
}
.payment-flow th { color: #586b79; font-weight: 500; }
.calc-view .calc-data-table.parcels-table > tbody > tr.payment-subrow .payment-flow :is(th, td) {
    height: auto;
    padding: 3px 10px;
}
.parcels-table .payment-flow :is(th, td):first-child,
.main-table .payment-flow :is(th, td):first-child { text-align: left; padding-left: 0; }
.payment-flow tbody tr + tr { border-top: 1px solid #e8edf0; }
.payment-flow .payment-flow-paid { color: var(--c-danger, #b42318); }
.payment-flow .payment-flow-description {
    display: block;
    white-space: normal;
    overflow-wrap: anywhere;
    font-weight: 400;
}
.main-table > tbody > .payment-subrow > td {
    padding: 2px 4px 5px;
    background: transparent;
}
.main-table .payment-flow {
    max-width: 520px;
    margin-bottom: 0;
    font-size: 6.7pt;
}
.main-table .payment-flow :is(th, td) {
    padding: 2px 6px;
    font-size: inherit;
    line-height: 1.3;
}
.main-table .payment-flow th { font-weight: 400; }
@media (max-width: 640px) {
    .calc-view #parcelListPanel .list-toolbar { flex-wrap: wrap; }
    .calc-view #parcelListPanel .list-toolbar-end { flex-basis: 100%; min-width: 0; }
    .calc-view #parcelListPanel .parcel-entry-actions { flex-wrap: wrap; }
    #calculationReceipts .payment-flow { display: block; min-width: 0; }
    #calculationReceipts caption { display: block; white-space: normal; }
    #calculationReceipts thead { display: none; }
    #calculationReceipts tbody { display: block; }
    #calculationReceipts tr { display: grid; grid-template-columns: 1fr 1fr; height: auto; gap: 6px; padding: 8px 12px; }
    #calculationReceipts td { display: block; min-width: 0; height: auto; padding: 6px 4px; text-align: left; line-height: 1.5; white-space: normal; }
    #calculationReceipts td::before { content: attr(data-label); display: block; font-size: 0.7rem; color: #586b79; }
    #calculationReceipts td:first-child,
    #calculationReceipts td:nth-child(4) { grid-column: 1 / -1; min-width: 0; }
    .calc-view .calc-data-table.parcels-table > tbody > tr.payment-subrow > td,
    .main-table > tbody > .payment-subrow > td { padding: 3px 8px 6px; }
    .parcels-table .payment-flow th,
    .parcels-table .payment-flow td { font-size: 0.64rem; }
    .calc-view .calc-data-table.parcels-table > tbody > tr.payment-subrow .payment-flow :is(th, td) { padding-inline: 3px; }
    .payment-flow th { white-space: normal; }
}
@media print {
    .payment-subrow { break-inside: avoid; }
    .main-table > tbody > tr:has(+ .payment-subrow) { break-after: avoid; }
}
