/* Compact register tables; mobile keeps aligned columns with horizontal scrolling. */
@media screen {
 html body .record-register-scroll { width:100%; max-width:100%; min-width:0; overflow:auto; border:1px solid #e4e7ee; border-radius:10px; margin:10px 0; }
 html body .record-register { display:block!important; width:100%!important; min-width:var(--record-min-width,900px)!important; gap:0!important; padding:0!important; }
 html body .record-register > .record-register-head,
 html body .record-register-scroll .record-register > .table-row.record-register-row { display:grid!important; grid-template-columns:var(--record-columns)!important; align-items:center!important; gap:12px!important; padding:10px 12px!important; margin:0!important; min-height:46px!important; width:100%!important; box-sizing:border-box!important; border:0!important; border-bottom:1px solid #e8ebf1!important; border-radius:0!important; box-shadow:none!important; font-size:12px!important; background:#fff!important; }
 html body .record-register > .record-register-head { background:#f4f6f9!important; font-weight:800; color:#465369; position:sticky; top:0; z-index:1; }
 html body .record-register-scroll .record-register > .table-row.record-register-row:nth-child(odd) { background:#fafbfe!important; }
 html body .record-register-scroll .record-register > .table-row.record-register-row:hover { background:#fff0f3!important; }
 html body .record-register-scroll .record-register > .table-row.record-register-row.is-hidden { display:none!important; }
 html body .record-register-scroll .record-register > .table-row.record-register-row > * { min-width:0!important; max-width:100%!important; overflow:hidden!important; text-overflow:ellipsis; white-space:nowrap; grid-column:auto!important; grid-row:auto!important; font-size:12px!important; }
 html body .record-register-scroll .record-register > .table-row.record-register-row > button { width:auto!important; min-height:30px!important; height:30px!important; padding:4px 8px!important; }
 html body #salesPage .sales-ledger { display:table!important; width:100%!important; min-width:1180px!important; table-layout:fixed!important; border-collapse:collapse!important; }
 html body #salesPage .sales-ledger thead { display:table-header-group!important; }
 html body #salesPage .sales-ledger tbody { display:table-row-group!important; }
 html body #salesPage .sales-ledger tr { display:table-row!important; }
 html body #salesPage .sales-ledger th,html body #salesPage .sales-ledger td { display:table-cell!important; padding:10px 12px!important; font-size:12px!important; text-align:start; vertical-align:middle; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
 html body #salesPage .sales-ledger th:nth-child(1) { width:7%; }
 html body #salesPage .sales-ledger th:nth-child(2) { width:37%; }
 html body #salesPage .sales-ledger th:nth-child(3) { width:11%; }
 html body #salesPage .sales-ledger th:nth-child(4) { width:10%; }
 html body #salesPage .sales-ledger th:nth-child(n+5):nth-child(-n+7) { width:8%; }
 html body #salesPage .sales-ledger th:nth-child(8) { width:11%; }
 html body #salesPage .sales-ledger td > strong { display:block; min-width:0; overflow:hidden; text-overflow:ellipsis; }
 html body #salesPage .sales-ledger .sales-document-link { width:auto!important; max-width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; padding:2px!important; }
}

/* Consistent visible row/column boundaries in ERP registers. POS remains unchanged. */
@media screen {
 html body.erp-modern-page .record-register > .record-register-head { background:#465369!important; color:#fff!important; }
 html body.erp-modern-page .record-register > .record-register-head > * { border-inline-end:1px solid #64748b; padding-inline:10px; }
 html body.erp-modern-page .record-register-scroll .record-register > .table-row.record-register-row { gap:0!important; min-height:40px!important; padding:0!important; }
 html body.erp-modern-page .record-register-scroll .record-register > .table-row.record-register-row > * { padding:9px 10px!important; border-inline-end:1px solid #e4e7ee; align-self:stretch; display:flex; align-items:center; }
 html body.erp-modern-page .record-register > .record-register-head { gap:0!important; padding:10px 0!important; }
 html body.erp-modern-page .record-register > .record-register-head > :last-child,
 html body.erp-modern-page .record-register-row > :last-child { border-inline-end:0; }
 html body.erp-modern-page table thead th,html body.erp-modern-page table thead td,
 html body.erp-modern-page table tr:first-child > th { background:#465369!important; color:#fff!important; border:1px solid #64748b!important; }
 html body.erp-modern-page table { border-collapse:collapse; }
 html body.erp-modern-page table tbody td { border:1px solid #e4e7ee!important; }
 html body.erp-modern-page table tbody tr:nth-child(even) { background:#fafbfe; }
 html body.erp-modern-page .record-register-row > [role="cell"] > button { width:auto!important; min-height:30px!important; height:30px!important; padding:4px 8px!important; }
}

@media screen {
 html body.erp-modern-page #purchaseLines.record-register .purchase-item-metric > span { display:none!important; }
 html body.erp-modern-page #purchaseLines.record-register .purchase-item-name { white-space:normal!important; }
 html body.erp-modern-page #purchaseLines.record-register .invoice-line-tax { min-width:0!important; margin:0!important; gap:4px!important; flex-direction:column; align-items:stretch; }
 html body.erp-modern-page #purchaseLines.record-register .invoice-line-tax > span { display:none!important; }
 html body.erp-modern-page #purchaseLines.record-register .purchase-item-actions { display:flex!important; gap:6px!important; }
 html body.erp-modern-page .purchase-form > .record-register-scroll:has(#purchaseLines) { flex:1 1 auto!important; min-height:90px!important; margin:0!important; overflow:auto!important; }
 html body.erp-modern-page #purchaseLines.record-register { min-height:0!important; overflow:visible!important; }
}
