:root{font-family:system-ui,sans-serif;color:#182536;background:#f4f6f8}body{margin:0}header{background:#173b52;color:white;display:flex;gap:1rem;align-items:center;padding:1rem;flex-wrap:wrap}header a{color:white}nav{display:flex;gap:1rem;flex:1}main{max-width:64rem;margin:2rem auto;padding:0 1rem}h1,h2{color:#173b52}.form{display:grid;gap:.8rem;max-width:28rem;margin:1rem 0}label{display:grid;gap:.25rem}input,select,button{font:inherit;padding:.5rem;border:1px solid #a6b2bd;border-radius:.3rem}button{background:#17647b;color:white;cursor:pointer}li{margin:.7rem 0}.message{background:#fff0d8;border-left:4px solid #c87d00;padding:.8rem}a{color:#075a78}

.table-scroll{max-width:100%;max-height:60vh;max-height:min(60vh,32rem);overflow:auto;border:1px solid #c5d0d8;border-radius:.35rem;background:white}
.table-scroll:focus-visible{outline:3px solid #17647b;outline-offset:2px}
.data-table{width:100%;border-collapse:separate;border-spacing:0;text-align:left}
.warehouse-table{min-width:36rem}.location-table-scroll{box-sizing:border-box;width:39rem}.location-table{width:100%;min-width:35rem;table-layout:fixed}
[data-row-navigation] [data-row-url]{cursor:pointer}[data-row-navigation] [data-row-url]:focus-within{background:#f3f8fa}
.table-row-name{background:transparent;border:0;color:inherit;font:inherit;text-align:left;padding:0;cursor:pointer}
.table-row-name:focus-visible{outline:2px solid #17647b;outline-offset:3px}
.location-place{width:22%}.location-position{width:26%}.location-code-column{width:31%}.location-status{width:21%}
.location-table thead th{white-space:nowrap;overflow-wrap:normal}
.data-table th,.data-table td{padding:.7rem .85rem;border-bottom:1px solid #e1e7eb;vertical-align:top;overflow-wrap:anywhere}
.data-table thead th{position:sticky;top:0;z-index:1;background:#e7eff3;color:#173b52;border-bottom:1px solid #b7c8d2}
.data-table tbody th{font-weight:500}.data-table tbody tr:last-child th,.data-table tbody tr:last-child td{border-bottom:0}
.data-table tbody tr:hover{background:#f3f8fa}.location-code{white-space:nowrap;font-variant-numeric:tabular-nums}
.visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.history-table{min-width:38rem}.history-time{white-space:nowrap;font-variant-numeric:tabular-nums}
.item-receipt-history-scroll{width:36rem;max-height:24rem;margin:1rem 0}.item-receipt-history{min-width:23rem}.item-receipt-history thead th{white-space:nowrap;overflow-wrap:normal}
.stock-table-scroll{margin:1rem 0}.stock-table{min-width:48rem}.stock-table td:nth-child(4){white-space:nowrap}
.stock-overview{min-width:56rem}.stock-filters{display:grid;grid-template-columns:minmax(9rem,1fr) minmax(9rem,1fr) minmax(12rem,2fr) 2.6rem;gap:.6rem;align-items:end;margin:1rem 0}.stock-filters input,.stock-filters select{box-sizing:border-box;width:100%;min-width:0;height:2.6rem}
.stock-nowrap,.stock-overview thead th{white-space:nowrap;overflow-wrap:normal}.stock-detail-fields{display:flex;flex-wrap:wrap;gap:.25rem 1.5rem}.stock-detail-fields p{margin:.3rem 0}.stock-detail-fields+p .product-barcode{vertical-align:middle}
.receipt-filters{display:grid;grid-template-columns:minmax(12rem,2fr) minmax(8rem,1fr) minmax(9rem,1fr);gap:.6rem;margin:1rem 0}.receipt-filters input,.receipt-filters select{box-sizing:border-box;width:100%}.receipt-table{min-width:42rem;table-layout:fixed}.receipt-table th:nth-child(1),.receipt-table th:nth-child(2),.receipt-table th:nth-child(3),.receipt-table th:nth-child(5){width:7rem}.receipt-origin{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.receipt-lines{min-width:50rem}.receipt-summary{display:flex;gap:.2rem 1.5rem;flex-wrap:wrap}.receipt-summary p{margin:.35rem 0}textarea{font:inherit;padding:.5rem;border:1px solid #a6b2bd;border-radius:.3rem;resize:vertical}
.receipt-lines{min-width:58rem}.receipt-placements{list-style:none;padding:0;margin:0}.receipt-placements li{margin:0 0 .25rem}.receipt-placements li:last-child{margin-bottom:0}.receipt-placement-note{margin:.4rem 0 .8rem}
.receipt-date-filter{display:grid;gap:.25rem;align-content:start}.receipt-date-input{position:relative;display:flex}.receipt-date-input input[data-receipt-before]{padding-right:2.8rem}.receipt-date-input .receipt-calendar-button{position:absolute;right:.2rem;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:2.2rem;height:2rem;padding:.35rem;border:0;background:transparent;color:#173b52}.receipt-calendar-button svg{width:100%;height:100%}.receipt-date-input input[data-receipt-calendar]{position:absolute;right:0;bottom:0;width:2rem;height:2rem;opacity:0;pointer-events:none}.receipt-date-input input[aria-invalid="true"]{border-color:#b44028}.receipt-date-error{color:#a42d20}
.receipt-picker-dialog{width:min(52rem,calc(100% - 3rem))}.receipt-picker-scroll{margin:.75rem 0;max-height:35vh}.receipt-picker-table{min-width:32rem;table-layout:fixed}.receipt-picker-table th:first-child{width:5.5rem}.receipt-picker-table th:last-child{width:8rem}.receipt-picker-table thead th{white-space:nowrap;overflow-wrap:normal}.receipt-picker-table tbody tr{cursor:pointer}.receipt-picker-table tbody tr[data-selected="true"]{background:#d5eaf1}.receipt-picker-dialog>label input{box-sizing:border-box;width:100%}
.request-picker-filters{display:grid;grid-template-columns:minmax(0,2fr) minmax(9rem,1fr);gap:.65rem}.request-picker-filters input,.request-picker-filters select{box-sizing:border-box;width:100%;min-width:0}.request-picker-note{margin:.5rem 0 0}.request-picker-table th:nth-child(3){width:8rem}.request-picker-table th:last-child{width:6rem}
@media(max-width:420px){.request-picker-filters{grid-template-columns:1fr}}
.receipt-accept-dialog{width:min(42rem,calc(100% - 3rem))}.receipt-location-filters{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:.65rem}.receipt-location-filters input,.receipt-location-filters select{box-sizing:border-box;width:100%;min-width:0}.receipt-location-scroll{max-height:min(24vh,13rem)}.receipt-location-table{min-width:20rem}.receipt-location-table thead th{white-space:nowrap;overflow-wrap:normal}.receipt-location-table tbody tr{cursor:pointer}.receipt-location-table tbody tr[data-selected="true"]{background:#d5eaf1}.receipt-location-selected{margin:0}.receipt-accept-dialog .message{margin:0}
.request-filters{display:grid;grid-template-columns:minmax(0,2fr) minmax(9rem,1fr);gap:.6rem;max-width:42rem;margin:1rem 0}.request-filters input,.request-filters select{box-sizing:border-box;width:100%}.request-table{min-width:48rem}.request-lines{min-width:60rem}
@media(max-width:380px){.receipt-location-filters{grid-template-columns:1fr}}
@media(max-width:600px){.receipt-filters{grid-template-columns:1fr 1fr}.receipt-filters label:first-child{grid-column:1 / -1}}
@media(max-width:700px){.stock-filters{grid-template-columns:minmax(0,1fr) minmax(0,1fr) 2.6rem}.stock-filters label:nth-child(3){grid-column:1 / 3}}
dialog{box-sizing:border-box;width:min(28rem,calc(100% - 3rem));max-height:calc(100vh - 3rem);overflow:auto;padding:1.5rem;border:1px solid #c5d0d8;border-radius:.5rem;box-shadow:0 1rem 3rem #172c3d40;color:inherit}
dialog::backdrop{background:#10253299}dialog h2{margin-top:0}dialog .form{max-width:none;margin-bottom:0}
.history-trigger{margin:1rem 0}.history-dialog{width:min(48rem,calc(100% - 3rem))}.history-dialog .table-scroll{max-height:50vh}.history-actions{margin-top:1rem}
.dialog-actions{display:flex;gap:.75rem;justify-content:flex-end;flex-wrap:wrap}.secondary-button{background:white;color:#173b52}
.warehouse-actions,.location-actions{display:flex;gap:.75rem;align-items:center;flex-wrap:wrap;margin:1rem 0}.warehouse-actions form,.location-actions form{margin:0}
.list-filters{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,1fr);align-items:end;gap:.8rem;max-width:40rem;margin:1rem 0}
.list-filters input,.list-filters select{box-sizing:border-box;width:100%;min-width:0;height:2.6rem}
.scan-actions{display:flex;align-items:center;gap:.75rem;flex-wrap:wrap;margin:0 0 1rem}
.scan-actions [data-scan-filter]:not([hidden]){display:flex;align-items:center;gap:.5rem;flex-wrap:wrap}
.user-table-scroll{margin-top:1rem}.user-table{min-width:40rem}.user-table button{white-space:nowrap}
dialog .account-section{padding-bottom:1rem;margin-bottom:1rem;border-bottom:1px solid #e1e7eb}dialog .account-section p{margin:0}
@font-face{font-family:'Libre Barcode 128';src:url('fonts/LibreBarcode128-Regular.ttf') format('truetype');font-display:block}
.item-table-scroll{width:62rem}
.item-table{min-width:54rem;table-layout:fixed}
.item-code-1c-column{width:5.5rem}.item-part-code-column{width:7rem}.item-barcode-column{width:16rem}
.item-table .item-barcode-cell{white-space:nowrap;overflow-wrap:normal;vertical-align:middle;text-align:center}
.item-barcode-heading{text-align:center}
.barcode-scroll{display:flex;justify-content:safe center;max-width:100%;overflow-x:auto}
.barcode-scroll .product-barcode{flex:none}
.product-barcode{display:inline-block;white-space:nowrap;overflow-wrap:normal;overflow:hidden;height:.6em;font:normal 3.4rem/1 'Libre Barcode 128';letter-spacing:normal;background:#fff;color:#000;padding:0 1.25rem}
.item-barcodes{overflow-x:auto}.item-barcodes li{white-space:nowrap}.item-barcodes .product-barcode{vertical-align:middle}
.item-table .item-code-1c{white-space:nowrap;overflow-wrap:normal}
.warehouse-back{margin:0 0 .5rem}
.warehouse-summary{display:flex;align-items:center;flex-wrap:wrap;gap:.5rem 1.25rem;margin-bottom:1rem}
.warehouse-title h1{margin:0;font-size:1.8rem;line-height:1.2}.warehouse-title p{margin:.2rem 0 0}
.warehouse-summary .warehouse-actions{margin:0;gap:.5rem}.warehouse-summary .history-trigger{margin:0}
.locations-heading{display:flex;align-items:center;gap:.75rem;flex-wrap:wrap;margin:.5rem 0}
.locations-heading h2{margin:0}
.location-toolbar{grid-template-columns:minmax(0,1fr) minmax(7rem,9rem) 2.6rem;gap:.5rem;max-width:39rem;margin:.5rem 0 .8rem}
.item-toolbar{grid-template-columns:minmax(0,1fr) 2.6rem;gap:.5rem;max-width:28rem;margin:1rem 0 .8rem}
.icon-button{display:grid;place-items:center;width:2.6rem;height:2.6rem;padding:.55rem}.icon-button svg{display:block;width:100%;height:100%}
.code-filter:not([hidden]){display:flex;align-items:center;gap:.5rem;flex-wrap:wrap;margin:0 0 .8rem}
@media(max-width:380px){.location-toolbar{grid-template-columns:minmax(0,1fr) minmax(5.5rem,7rem) 2.6rem}}

/* Keep document picker labels and codes readable while allowing horizontal scrolling on narrow screens. */
.reservation-document-picker{min-width:45rem;table-layout:auto}.reservation-document-picker thead th{white-space:nowrap;overflow-wrap:normal}.reservation-document-picker th:nth-child(1){width:4rem}.reservation-document-picker th:nth-child(2){width:4.5rem}.reservation-document-picker th:nth-child(5){width:5rem}.reservation-document-picker th:nth-child(6){width:6.5rem}.reservation-document-picker td:nth-child(2),.reservation-document-picker td:nth-child(5){white-space:nowrap;overflow-wrap:normal}.reservation-document-picker input[inputmode="decimal"]{box-sizing:border-box;width:6.5rem;max-width:100%}

.shipment-lines{min-width:56rem}.shipment-lines thead th,.shipment-lines td:first-child{white-space:nowrap;overflow-wrap:normal}

.main-nav{display:flex;align-items:center;flex-wrap:wrap;gap:.3rem;min-width:0}.main-nav .nav-group{position:relative}.main-nav summary,.main-nav .nav-link{display:block;color:#fff;padding:.5rem .65rem;border-radius:.3rem;cursor:pointer;white-space:nowrap}.main-nav summary{list-style:none}.main-nav summary::-webkit-details-marker{display:none}.main-nav summary::after{content:" ▾"}.main-nav summary:hover,.main-nav .nav-link:hover,.main-nav .nav-group[open]>summary{background:#28546a}.main-nav summary:focus-visible,.main-nav a:focus-visible{outline:2px solid #fff;outline-offset:2px}.main-nav .nav-menu{position:absolute;top:100%;left:0;z-index:20;min-width:12rem;padding:.3rem;background:#173b52;border:1px solid #77909e;border-radius:.35rem;box-shadow:0 .5rem 1.25rem #0004}.main-nav .nav-menu a{display:block;padding:.55rem .7rem;border-radius:.25rem;color:#fff;white-space:nowrap}.main-nav .nav-menu a:hover,.main-nav .nav-menu a:focus-visible{background:#28546a}
@media(max-width:600px){header .main-nav{flex:1 0 100%;order:1}}
.transfer-list{min-width:42rem}.transfer-lines{min-width:90rem}.transfer-lines thead th,.transfer-lines td:not(:nth-child(2)){white-space:nowrap;overflow-wrap:normal}.transfer-actions button{margin:.1rem .15rem}.transfer-picker{min-width:48rem}.transfer-picker thead th{white-space:nowrap;overflow-wrap:normal}.transfer-picker tbody tr{cursor:pointer}.transfer-picker tbody tr[data-selected="true"]{background:#d5eaf1}

.transfer-list-scroll{margin-top:.75rem}

.inventory-location{display:flex;align-items:center;gap:.75rem;flex-wrap:wrap;margin:.6rem 0}.inventory-location-picker{width:min(34rem,calc(100% - 3rem))}.inventory-location-picker>label input{box-sizing:border-box;width:100%}.inventory-location-scroll{margin:.75rem 0;max-height:min(45vh,20rem)}.inventory-location-table{min-width:16rem}.inventory-location-table thead th{white-space:nowrap;overflow-wrap:normal}.inventory-location-table tbody tr[data-inventory-location-choice]{cursor:pointer}.inventory-location-table tbody tr[data-selected="true"]{background:#d5eaf1}

.inventory-location-toolbar{display:flex;gap:.5rem;align-items:end}.inventory-location-toolbar label{flex:1;min-width:0}.inventory-location-toolbar input{box-sizing:border-box;width:100%}.inventory-location-toolbar .icon-button{flex:none}

.location-barcode{max-width:100%;overflow-x:auto}.location-barcode .product-barcode{vertical-align:top}

.inventory-location-summary{display:grid;gap:.25rem}

.inventory-part-row th,.inventory-part-row td{background:#f6f9fa;font-size:.94em}.inventory-recount-moved{margin:.75rem 0}
