.customer-page-hidden,.list-page-hidden {display:none!important}
.customer-fixed-pagination {display:flex;justify-content:space-between;align-items:center;gap:8px;flex-wrap:wrap;padding:7px 0 0;color:#6b7c8c;font-size:12px;min-height:30px;min-width:0}
.customer-fixed-pagination .list-pagination-controls,
.customer-fixed-pagination .list-page-size,
.customer-fixed-pagination .list-page-turns,
.customer-fixed-pagination .list-page-jump {display:flex;align-items:center;gap:6px;flex-wrap:nowrap;width:auto;margin:0;font-size:12px;line-height:1.4}
.customer-fixed-pagination .list-pagination-controls {flex-wrap:wrap;justify-content:flex-end;gap:8px 12px;max-width:100%}
.customer-fixed-pagination .list-page-size select {width:100px;min-height:30px;margin:0;padding:4px 6px;font-size:12px;box-sizing:border-box}
.customer-fixed-pagination .list-page-jump input {width:58px;min-height:30px;margin:0;padding:4px 6px;font-size:12px;box-sizing:border-box}
.customer-fixed-pagination :is(button,select,input) {border:1px solid #d9e3ed;border-radius:6px;background:#fff;color:#486b91}
.customer-fixed-pagination button {width:auto;min-height:30px;margin:0;padding:4px 7px;font-size:12px;white-space:nowrap;line-height:20px}
.customer-fixed-pagination button:disabled,.customer-fixed-pagination input:disabled {color:#a1afbd;cursor:default}
.customer-fixed-pagination [data-page-current] {white-space:nowrap}
.customer-fixed-pagination .list-page-jump[hidden] {display:none}
.list-page-scroll[data-page-size-mode="fixed"] {height:var(--list-page-height);max-height:var(--list-page-height);overflow-y:auto;overscroll-behavior:contain;min-height:0!important;scrollbar-gutter:stable}
.list-page-scroll[data-page-size-mode="fixed"] thead th {position:sticky;top:0;z-index:1;background:#f7f9fc}
.customer-fixed-list [data-fixed-row-menu] {position:fixed!important;z-index:1100;width:230px;max-height:200px;overflow:auto;background:#fff;border:1px solid #d9e3ed;padding:8px;box-shadow:0 6px 24px #20364f33}
@media(max-width:768px){
  .customer-fixed-pagination {align-items:flex-start}
  .customer-fixed-pagination .list-pagination-controls {justify-content:flex-start;gap:8px}
}
@media(min-width:769px){
  body.pc-ui-preview .customer-fixed-list {padding:10px 16px;min-width:0}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table {max-height:none;height:auto;overflow-y:visible;box-sizing:border-box;margin-bottom:0}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table[data-page-size-mode="fixed"] {height:var(--list-page-height);max-height:var(--list-page-height);overflow-y:auto;overscroll-behavior:contain}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table>table {margin:0;width:100%;min-width:0;box-sizing:border-box}
  body.pc-ui-preview .customer-fixed-list .project-contract-board-table {width:100%;min-width:0}
  body.pc-ui-preview .customer-fixed-list .project-contract-period-cell span {white-space:normal;overflow-wrap:anywhere}
  body.pc-ui-preview .customer-fixed-list .customer-page-hidden {display:none!important}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table > table > :is(thead,tbody) > tr > :is(th,td) {padding:4px 8px;line-height:1.3}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table > table > tbody > tr[data-row-id] > td {padding:4px 8px;line-height:1.3}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table .cell-sub {margin-top:2px;line-height:1.3}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table :is(.cell-main,.cell-sub,td>strong):not(.client-compact-activity,.project-contract-narrow-meta,.quote-row-compact-meta) {display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table :is(button,summary) {min-height:26px;margin-top:0;margin-bottom:0;padding:3px 6px;font-size:12px;line-height:18px}
  body.pc-ui-preview #clientViewHost .client-list-view .client-row-actions {gap:3px}
  body.pc-ui-preview #clientViewHost .client-list-view .client-row-actions > button,
  body.pc-ui-preview #clientViewHost .client-list-view .client-row-more > summary {min-height:26px;padding:3px 6px}
  body.pc-ui-preview .customer-fixed-pagination {display:flex;justify-content:space-between;align-items:center;gap:8px;padding:7px 0 0;color:#6b7c8c;font-size:12px;min-height:30px}
  body.pc-ui-preview .customer-fixed-pagination>div {display:flex;align-items:center;gap:8px}
  body.pc-ui-preview .customer-fixed-pagination button {width:auto;min-height:30px;margin:0;padding:5px 10px;border:1px solid #d9e3ed;background:#fff;color:#486b91;font-size:12px}
  body.pc-ui-preview .customer-fixed-pagination button:disabled {color:#a1afbd;cursor:default}
  body.pc-ui-preview .customer-fixed-list .section-head {margin-bottom:8px;padding-bottom:8px}
  body.pc-ui-preview .customer-fixed-list .toolbar-strip {margin-bottom:8px;gap:6px}
  body.pc-ui-preview .customer-fixed-list .client-page-head {margin-bottom:8px;padding-bottom:8px}
  body.pc-ui-preview .customer-fixed-list .client-list-controls>.cards {margin-bottom:8px}
  body.pc-ui-preview .customer-fixed-list .client-list-controls>.cards .stat {padding:5px 8px;min-height:32px}
  body.pc-ui-preview .customer-fixed-list .client-filter-grid {padding:8px;gap:6px;margin-bottom:6px}
  body.pc-ui-preview .customer-fixed-list .client-filter-field {gap:3px}
  body.pc-ui-preview .customer-fixed-list .client-filter-field>span {position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
  body.pc-ui-preview .customer-fixed-list .client-filter-field> :is(input,select),
  body.pc-ui-preview .customer-fixed-list .client-filter-actions>button {min-height:32px;padding:5px 8px}
  body.pc-ui-preview .customer-fixed-list .client-filter-summary {margin-bottom:6px}
  body.pc-ui-preview .customer-fixed-list .quote-row-actions-a {gap:3px}
  body.pc-ui-preview .customer-fixed-list .quote-row-more-a {width:auto;flex-basis:auto}
  body.pc-ui-preview .customer-fixed-list .quote-list-table > tbody > tr[data-row-id] .quote-row-actions-a {gap:2px}
  body.pc-ui-preview .customer-fixed-list .quote-list-table > tbody > tr[data-row-id] .quote-row-more-a {flex:0 0 auto;width:auto;margin:0}
  body.pc-ui-preview .customer-fixed-list .quote-list-table > tbody > tr[data-row-id] .quote-row-actions-a :is(button.tiny,summary) {padding:3px 4px}
  body.pc-ui-preview .customer-fixed-list .quote-status-control select {min-height:26px;padding:3px 6px}
  body.pc-ui-preview .customer-fixed-list .quote-list-table .cell-sub {line-height:1.25;margin-top:1px}
  body.pc-ui-preview .quote-list-panel.customer-fixed-list>.section-head {margin:0 0 6px;padding:0 0 6px;min-height:30px}
  body.pc-ui-preview .quote-list-panel.customer-fixed-list .quote-search-toolbar {margin-top:0;padding:6px}
  body.pc-ui-preview .quote-list-panel.customer-fixed-list .quote-settings-panel {margin-top:6px;padding-top:4px}
  body.pc-ui-preview .quote-page-head-panel:has(+.customer-fixed-list) .quote-page-subtitle {display:none}
  body.pc-ui-preview .customer-fixed-list .project-contract-result-line {display:none}
  body.pc-ui-preview .customer-fixed-list [data-fixed-row-menu] {position:fixed!important;z-index:1100;width:230px;max-height:200px;overflow:auto;background:#fff;border:1px solid #d9e3ed;padding:8px;box-shadow:0 6px 24px #20364f33}
  body.pc-ui-preview .customer-fixed-list .customer-fixed-table td:has(details[open]) {position:relative!important;z-index:1200!important}
  body.pc-ui-preview .customer-fixed-list .client-row-more[open] {grid-column:auto!important}
  .customer-list-history-dialog {width:min(900px,90vw);max-height:80vh;overflow:auto;border:1px solid #d9e3ed;border-radius:8px;padding:16px;color:#243b53}
  .customer-list-history-dialog::backdrop {background:#152a4659}
  .customer-list-history-dialog>header {display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}
  .customer-list-history-dialog>header>button {width:auto;margin:0;padding:5px 12px}
}

@media screen {
body.mobile-ui-active .cw-backup-modal .cw-backup-list.list-page-scroll[data-page-size-mode="fixed"] {overflow-y:auto;max-height:var(--list-page-height);}
body.mobile-ui-active .cw-backup-modal .customer-fixed-pagination {position:relative;z-index:2;flex-shrink:0;background:#fff;}
body.mobile-ui-active .customer-fixed-pagination :is(button,.list-page-size>span) {white-space:nowrap;flex-shrink:0;}
body.mobile-ui-active .customer-fixed-pagination .list-pagination-controls {flex-wrap:wrap;}
}

/* Paging wrappers belong only to the three mobile hub lists. */
@media screen and (max-width:1024px){
 body.mobile-ui-active .hub-paged-list>.hub-list-scroll{min-width:0;}
 body.mobile-ui-active .hub-paged-list>.hub-list-scroll[data-page-size-mode="fixed"]{overscroll-behavior:contain;}
 body.mobile-ui-active .hub-paged-list .hub-pagination{min-width:0;margin:0;padding:6px 0 0;}
 body.mobile-ui-active .hub-paged-list .hub-pagination .list-pagination-controls{width:100%;justify-content:space-between;gap:6px;}
 body.mobile-ui-active .hub-paged-list .hub-pagination .list-page-size select{width:84px;max-width:100%;}
 body.mobile-ui-active .hub-paged-list .hub-summary-actions{display:flex;align-items:center;gap:10px;flex:none;}
 body.mobile-ui-active .hub-paged-list .hub-summary-actions>button{width:auto;min-height:32px;margin:0;padding:4px 0;border:0;background:none;}
 body.mobile-ui-active .hub-paged-list .mobile-workspace-list{margin-bottom:0;}
 body.mobile-ui-active .hub-paged-list .hub-pagination .list-page-turns{max-width:100%;}
}

@media (max-width: 1024px) {
  body.mobile-ui-active .extra-record-page-wrap { min-width: 0; }
  body.mobile-ui-active .extra-record-pagination { margin: 8px 0; min-width: 0; font-size: 13px; }
  body.mobile-ui-active .extra-record-pagination .list-pagination-controls { width: 100%; justify-content: space-between; gap: 6px; }
  body.mobile-ui-active .extra-record-pagination select { width: 84px; min-width: 0; }
  body.mobile-ui-active .extra-record-page-wrap table { font-size: 13px; }
  body.mobile-ui-active #purchaseDetailDialog .extra-record-page-wrap .purchase-detail-table td { font-size: 13px; }
  body.mobile-ui-active .extra-record-items > .mw-entry,
  body.mobile-ui-active .extra-record-items > .mw-review-arrival { font-size: 13px; }
  body.mobile-ui-active .mw-phone-menu .extra-record-items { display: grid; gap: 8px; }
  body.mobile-ui-active .mw-phone-menu .extra-record-items > button { width: 100%; margin: 0; text-align: left; font-size: 13px; }
}

/* A mobile page contains complete records; only an explicitly larger page may scroll inside. */
@media screen {
 body.mobile-ui-active .list-page-scroll[data-page-size-mode="auto"] { height:auto;min-height:0;max-height:none;overflow-y:visible;scrollbar-gutter:auto; }
 body.mobile-ui-active .list-page-scroll[data-page-size-mode="fixed"] { height:auto;min-height:0;max-height:var(--list-page-height);overflow-y:auto;scrollbar-gutter:auto; }
}
