*{box-sizing:border-box}body{margin:0;background:#f4f5f7;color:#243142;font:14px/1.5 Arial,sans-serif}button,input,select{font:inherit}button{cursor:pointer;border:0;border-radius:7px;padding:11px 17px;background:#be392f;color:white}button:hover{filter:brightness(.93)}input,select{padding:11px 13px;border:1px solid #dbe0e5;border-radius:7px;background:white;color:#243142}input:focus,button:focus-visible,select:focus{outline:2px solid #bf4237;outline-offset:2px}aside{position:fixed;inset:0 auto 0 0;width:238px;background:#172732;color:#e5edf0;padding:32px 22px}.brand{font-size:23px;font-weight:800;letter-spacing:-1px;color:#ed6557}.brand span{display:block;color:#a7b8c2;font-size:12px;letter-spacing:2px;font-weight:400}.workspace{font-size:10px;letter-spacing:1.6px;color:#8b9ea9;margin-top:55px}.nav{padding:14px 10px;border-radius:7px;margin-top:12px}.active{background:#2b3d48}.tenant{margin-top:28px;padding:12px;border-left:2px solid #e36a59}.tenant small{display:block;color:#a6b8c2;font-size:11px}.muted{opacity:.55;border-color:#627782}.aside-bottom{position:absolute;bottom:25px;font-size:11px;color:#afbec7}.dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:#6dbea6;margin-right:6px}.ghost{background:transparent;color:inherit;border:1px solid #d1d8df}.aside-bottom button{margin-top:15px;border-color:#465963}main{margin-left:238px;padding:40px;max-width:1800px}header{display:flex;justify-content:space-between;align-items:center}h1{font-size:31px;letter-spacing:-1px;margin:8px 0}header p{margin:0;color:#6d7885}.eyebrow{font-size:10px;letter-spacing:1.7px;color:#83909b}.badge{background:#fff0dd;color:#966321;border:1px solid #efd9b8;padding:6px 12px;border-radius:20px;font-size:12px}.notice{margin:28px 0 24px;padding:13px 17px;border:1px solid #e8d9c2;background:#fffcf5;color:#806545;border-radius:7px;font-size:12px}.stats{display:grid;grid-template-columns:1fr 1fr 1.6fr;gap:18px;margin-bottom:25px}.stats>div{padding:20px 23px;background:white;border:1px solid #e2e5e9;border-radius:9px}.stats small{display:block;color:#77828e}.stats strong{font-size:30px;display:block;margin-top:7px;font-weight:500}.stats .date{font-size:19px;margin-top:15px}.panel{border:1px solid #e2e5e9;border-radius:10px;background:white;overflow:hidden}.toolbar{padding:20px;display:flex;gap:12px;align-items:center}.toolbar input{width:360px;max-width:60%}.toolbar>span{margin-left:auto;color:#7b8792;font-size:12px}.table-wrap{overflow:auto}table{border-collapse:collapse;width:100%;font-size:12px}th{text-align:left;background:#fafbfc;color:#78828c;font-weight:500;padding:13px 18px;border-block:1px solid #edf0f2}td{padding:16px 18px;border-bottom:1px solid #edf0f2}td small{display:block;color:#88939c;font-size:11px;margin-top:4px}.num{text-align:right;white-space:nowrap}.status{padding:4px 8px;background:#eef3f6;border-radius:4px;white-space:nowrap}.new{color:#ae722a}.view{background:#f7edeb;color:#a73e35;padding:7px 11px;font-size:11px;white-space:nowrap}.table-note{padding:0 20px;color:#8a949d;font-size:11px}.login{display:grid;place-items:center;min-height:100vh;background:#172732}.login-card{padding:40px;width:440px;max-width:90vw;background:white;border-radius:14px}.login-card h1{font-size:25px;margin-top:35px}.login-card p{color:#7c8791}.login-card input{display:block;width:100%;margin:8px 0 20px}.login-card button{width:100%}dialog{padding:0;border:0;border-radius:10px;width:1000px;max-width:96vw;max-height:96vh;background:#e5e9ed}dialog::backdrop{background:#142332b8}.dialog-bar{position:sticky;top:0;display:flex;align-items:center;gap:15px;background:white;padding:14px 22px;z-index:2}.dialog-bar>div{margin-right:auto}.dialog-bar small{display:block;color:#81909c;font-size:11px}#warnings{margin:16px 25px;background:#fff5dc;border:1px solid #ebd5a5;padding:8px 15px;color:#80643a;font-size:12px}#warnings p{margin:4px 0}.paper{width:210mm;min-height:297mm;background:white;margin:20px auto;color:#111;padding:16mm 15mm 0;font:10pt Arial,sans-serif;position:relative}.invoice-top{display:flex;justify-content:space-between}.invoice-top h2{color:#273e50;font-size:26pt;margin:0}.invoice-top h2 span{color:#c54135}.invoice-top p{font-size:8pt}.draft{color:#b34437;letter-spacing:2px}.address{margin:16mm 0 14mm;min-height:27mm}.invoice-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:8mm}.invoice-heading h2{font-size:18pt}.invoice-heading>div{font-size:9pt}.items{font-size:9pt}.items th,.items td{padding:3mm 2mm}.items th{background:#f3f3f3;color:#333}.items small{display:block}.totals{margin:5mm 0 0 auto;width:85mm}.totals>div{display:flex;justify-content:space-between;padding:1.3mm 0}.grand{border-block:1px solid #222;margin-top:2mm;font-size:12pt}.disclaimer{font-size:8pt;color:#777;margin:10mm 0 6mm}.qr-part{margin-left:-15mm;width:210mm;height:105mm;border-top:1px dashed #777;display:grid;grid-template-columns:62mm 148mm;background:white;break-inside:avoid}.qr-part h3{margin:0 0 5mm;font-size:11pt}.receipt{padding:5mm;border-right:1px dashed #888;font-size:8pt;position:relative}.qr-part b{display:block;font-size:8pt;margin-top:3mm}.qr-part div>div{line-height:1.25}.receipt h3{font-size:11pt}.receipt>div{font-size:8pt}.payment{padding:5mm}.payment h3 span{float:right;font-size:8pt;font-weight:400;color:#a44}.payment-grid{display:grid;grid-template-columns:51mm 1fr;gap:5mm}.qr{width:46mm;height:46mm;position:relative;margin:0 0 5mm}.qr svg{width:100%;height:100%}.cross{position:absolute;inset:50% auto auto 50%;transform:translate(-50%,-50%);width:7mm;height:7mm;border:.5mm solid white;color:white;background:black;text-align:center;line-height:6mm;font-size:21pt}.qr.missing{border:1px solid #bbb;display:grid;place-content:center;text-align:center;color:#a33;font-size:10pt}.amount{display:grid;grid-template-columns:18mm 1fr;gap:1mm;font-size:10pt;margin-top:4mm}.amount b{margin:0;font-size:8pt}.payment-details{font-size:9pt}.payment-details b:first-child,.receipt>b:first-of-type{margin-top:0}.accept{position:absolute;bottom:5mm;right:5mm;font-size:6pt!important}@media(max-width:1000px){aside{width:190px;padding:25px 14px}main{margin-left:190px;padding:25px}.stats{gap:10px}.stats>div{padding:15px}.toolbar{flex-wrap:wrap}.paper{transform-origin:top left}#invoice{overflow:auto}}@media(max-width:700px){aside{position:relative;width:100%;padding:15px}.workspace,.nav,.tenant,.aside-bottom{display:none}main{margin:0;padding:18px}h1{font-size:25px}.stats{grid-template-columns:1fr 1fr}.stats>div:last-child{grid-column:1/-1}.toolbar input{width:100%;max-width:100%}.dialog-bar{padding:10px;gap:7px}.dialog-bar button{padding:8px;font-size:11px}}@page{size:A4;margin:0}@media print{body{background:white}body>aside,body>main,.dialog-bar,#warnings{display:none!important}dialog{display:block!important;position:absolute;inset:0;margin:0;padding:0;border:0;width:210mm;max-width:none;height:auto;max-height:none;overflow:visible;background:white}dialog::backdrop{display:none}#invoice{overflow:visible}.paper{margin:0;box-shadow:none}.qr-part{margin-top:6mm}.paper{print-color-adjust:exact;-webkit-print-color-adjust:exact}}

.cross::before,.cross::after{content:"";position:absolute;display:block;background:white;left:50%;top:50%;transform:translate(-50%,-50%)}.cross::before{width:4mm;height:1.2mm}.cross::after{width:1.2mm;height:4mm}

.packing-slip{padding-bottom:15mm}.packing-slip .invoice-heading{margin-top:12mm}.shipping-address{margin:8mm 0 12mm;min-height:35mm}.shipping-address h3{font-size:9pt;color:#666;margin:0 0 3mm}.packing-items td{padding:5mm 2mm}.packing-items th:last-child{width:22mm}.packing-items th:nth-last-child(2){width:25mm}.write-line{display:block;border-bottom:1px solid #888;width:17mm;height:6mm}.check-box{display:block;width:5mm;height:5mm;border:1px solid #333}.packing-summary{margin-top:5mm;text-align:right;font-size:10pt}.packing-notes{margin-top:12mm}.packing-notes>div{height:9mm;border-bottom:1px solid #bbb}.packing-signatures{display:flex;justify-content:space-between;gap:5mm;margin-top:15mm;font-size:9pt}.address-warning{color:#a33;font-weight:bold}.packing-items tr{break-inside:avoid}.packing-items thead{display:table-header-group}@media print{.packing-signatures,.packing-notes{break-inside:avoid}}

.order-title{display:flex;align-items:center;gap:3mm;white-space:nowrap}.order-barcode{height:18mm;width:auto;flex-shrink:0;display:block;shape-rendering:crispEdges}.invoice-heading{gap:5mm;flex-wrap:wrap}.invoice-heading>div{margin-left:auto}button:disabled{opacity:.45;cursor:not-allowed}@media print{.order-title,.order-barcode{break-inside:avoid}}

/* Compact internal packing slip: reserve page height for readable item rows. */
.packing-slip{padding:8mm 10mm;font-size:11pt;line-height:1.2}
.packing-slip .invoice-top{align-items:center;margin:0}
.packing-slip .invoice-top h2{font-size:14pt}
.packing-slip .invoice-top p{display:none}
.packing-slip .draft{font-size:10pt}
.packing-slip .invoice-heading{margin:2mm 0 2mm;gap:1mm;align-items:center}
.packing-slip .invoice-heading h2{font-size:18pt;margin:0}
.packing-slip .invoice-heading>div{font-size:9pt;white-space:nowrap}
.packing-slip .shipping-address{margin:0 0 4mm;padding:2mm 0;min-height:0;border-block:1px solid #aaa;font-size:10pt;line-height:1.25}
.packing-slip .shipping-address h3{display:inline;font-size:10pt;margin:0 2mm 0 0;color:#111}
.packing-slip .shipping-address h3::after{content:':'}
.packing-slip .address-warning{margin:1mm 0}
.packing-slip .packing-items{font-size:12pt;line-height:1.18;table-layout:fixed}
.packing-slip .packing-items th{font-size:9pt;font-weight:bold;padding:1.8mm 1.2mm}
.packing-slip .packing-items td{padding:2mm 1.2mm;vertical-align:middle;color:#111;overflow-wrap:anywhere}
.packing-slip .packing-items th:first-child{width:33mm}
.packing-slip .packing-items th:nth-child(3){width:13mm}
.packing-slip .packing-items th:nth-last-child(2){width:23mm}
.packing-slip .packing-items th:last-child{width:18mm}
.packing-slip .packing-items .num{font-size:15pt}
.packing-slip .packing-model{font-size:12pt}
.packing-slip .write-line{height:5mm}
.packing-slip .packing-summary{margin:2mm 0;font-size:10pt}
.packing-slip .packing-notes{margin-top:3mm;font-size:9pt}
.packing-slip .packing-notes>div{height:6mm}
.packing-slip .packing-signatures{margin-top:4mm;font-size:9pt}
.packing-slip .disclaimer{margin:3mm 0 0;font-size:7pt}

.shop-logo{display:block;width:70mm;height:auto;max-width:100%;object-fit:contain}.packing-slip .shop-logo{width:48mm;height:auto}

.header-actions{display:flex;gap:12px;align-items:center}.batch-controls{display:flex;align-items:center;gap:20px;padding:20px;margin-bottom:15px}.batch-controls>div{margin-right:auto}.batch-controls small{display:block;color:#798692;margin-top:3px}.batch-controls label{font-size:12px;color:#6c7883}.batch-controls input{display:block;width:100px;margin-top:4px}.lot-history{margin-top:25px;padding:20px}.lot-history h2{font-size:18px;margin:0}.lot-history>p{font-size:12px;color:#788590}.lot-row{display:flex;align-items:center;gap:15px;padding:14px 0;border-top:1px solid #eee}.lot-row>div{margin-right:auto}.lot-row small{display:block;color:#798692;font-size:11px}.lot-row b{font-family:monospace}.empty-lots{color:#798692}.lot-ident{font:8pt Arial,sans-serif;color:#333;border-bottom:1px solid #bbb;margin:0 0 3mm;padding-bottom:1mm}.dialog-bar{flex-wrap:wrap}#refresh-status{font-size:12px;color:#597269}@media(max-width:800px){.header-actions,.batch-controls,.lot-row{flex-wrap:wrap}.batch-controls>div{flex-basis:100%}}@media print{.paper+.paper{break-before:page;page-break-before:always}.lot-ident{color:black}}

/* Content height in print: a forced A4 minimum can overflow onto an empty page. */
@media print{
 .paper,.packing-slip{min-height:0;height:auto;margin:0;break-after:auto;page-break-after:auto}
 .paper+.paper{break-before:page;page-break-before:always}
 dialog{top:0;bottom:auto;min-height:0;max-height:none;overflow:visible}
}

/* Keep ordinary invoices and the full-size Swiss payment part on one A4 sheet. */
.invoice-sheet{padding-top:8mm;font-size:9.5pt;line-height:1.2}
.invoice-sheet .invoice-top{align-items:flex-start}
.invoice-sheet .shop-logo{width:65mm}
.invoice-sheet .invoice-top p{font-size:8pt;margin:2mm 0 0}
.invoice-sheet .address{margin:6mm 0 4mm;min-height:0;line-height:1.2}
.invoice-sheet .invoice-heading{margin:3mm 0 4mm;gap:3mm}
.invoice-sheet .invoice-heading h2{font-size:17pt;margin:0}
.invoice-sheet .items{font-size:9pt;line-height:1.15}
.invoice-sheet .items th,.invoice-sheet .items td{padding:1.5mm 1.5mm}
.invoice-sheet .items td small{margin:0 0 .5mm;font-size:8pt}
.invoice-sheet .items tr{break-inside:avoid}
.invoice-sheet .items thead{display:table-header-group}
.invoice-sheet .totals{margin-top:3mm;break-inside:avoid}
.invoice-sheet .totals>div{padding:.8mm 0}
.invoice-sheet .grand{margin-top:1mm;font-size:11pt}
.invoice-sheet .disclaimer{margin:4mm 0 3mm;font-size:7pt}
.invoice-sheet .qr-part{margin-top:3mm;line-height:1.25}

/* Anchor payment part low on A4 while retaining a 12 mm bottom reserve. */
.invoice-sheet{display:flex;flex-direction:column;min-height:285mm;padding-bottom:0}
.invoice-sheet>.qr-part{margin-top:auto;flex-shrink:0;break-inside:avoid;page-break-inside:avoid}
.invoice-sheet>.invoice-top,.invoice-sheet>.address,.invoice-sheet>.invoice-heading,.invoice-sheet>.items,.invoice-sheet>.totals,.invoice-sheet>.disclaimer{flex-shrink:0}
@media print{.invoice-sheet{min-height:285mm;height:auto;padding-bottom:0}.invoice-sheet>.qr-part{margin-top:auto}}

/* Address positions taken from the customer's original VB invoice (117475). */
.invoice-sheet{padding:0 25mm 0 26mm;font-size:10pt;line-height:1.2;min-height:285mm}
.invoice-letterhead{position:relative;width:210mm;margin-left:-26mm;height:96mm;flex-shrink:0}
.invoice-letterhead .sender-address{position:absolute;left:26mm;top:10mm;font-size:10pt;line-height:4.2mm}
.invoice-letterhead .shop-logo{position:absolute;left:63mm;top:17mm;width:119mm;height:auto}
.invoice-letterhead h1{position:absolute;left:25.3mm;right:25mm;top:36.3mm;margin:0;padding-top:3mm;border-top:1mm solid #111;font-size:20pt;line-height:1.1;letter-spacing:0}
.invoice-delivery,.invoice-billing{position:absolute;top:50.8mm;font-size:10pt;line-height:4.2mm;overflow-wrap:anywhere}
.invoice-delivery{left:26mm;width:85mm}
.invoice-billing{left:127.6mm;width:57.4mm}
.invoice-delivery>b,.invoice-billing>b{display:block;font-size:10pt;line-height:4.2mm;margin-bottom:7.4mm}
.invoice-metadata{border-block:.2mm solid #111;display:flex;justify-content:space-between;gap:2mm;min-height:16mm;margin:0 0 4mm;padding:2mm 0;font-size:10pt;flex-shrink:0;break-inside:avoid}
.invoice-metadata .order-title{font-size:10pt;margin:0;gap:2mm;font-weight:400;height:7mm}
.invoice-metadata .order-barcode{height:12mm;align-self:center}
.invoice-metadata>div:last-child{font-size:9pt;padding-top:1mm;white-space:nowrap}
.invoice-sheet .invoice-items{table-layout:fixed;font-size:10pt;line-height:1.15}
.invoice-items .qty-col{width:10mm}.invoice-items .model-col{width:23mm}.invoice-items .price-col{width:17mm}
.invoice-sheet .invoice-items td,.invoice-sheet .invoice-items th{padding:1.4mm .8mm;vertical-align:top;color:#111;background:white;overflow-wrap:anywhere}
.invoice-sheet .invoice-items th{font-weight:bold;font-size:10pt}
.invoice-sheet .invoice-items .num{overflow-wrap:normal}
.invoice-sheet .totals{width:75mm;margin-top:3mm;font-size:10pt}
.invoice-sheet .invoice-closing{margin:4mm 0 0;font-size:10pt;flex-shrink:0;break-inside:avoid}
.invoice-closing p{margin:0 0 1mm}
.invoice-sheet .disclaimer{margin:2mm 0 3mm;font-size:7pt}
.invoice-sheet>.qr-part{margin-left:-26mm;width:210mm;min-height:105mm;margin-top:auto}
@media print{.invoice-sheet{padding:0 25mm 0 26mm;min-height:285mm}.invoice-letterhead{height:96mm}}

.invoice-contact{margin-top:4mm;font-size:10pt;line-height:4.2mm;overflow-wrap:anywhere}.invoice-sheet .invoice-items{font-size:9pt}.invoice-sheet .invoice-items td{padding:1mm .8mm}.invoice-metadata>div:last-child{line-height:4.5mm}

.invoice-sheet .totals>div{padding:.5mm 0}.invoice-sheet .invoice-closing{margin-top:3mm;font-size:9.5pt}.invoice-sheet .disclaimer{margin:1mm 0 2mm}.invoice-payment-page{padding-top:8mm}.payment-page-caption{font-size:10pt;padding-top:2mm;flex-shrink:0}@media print{.invoice-payment-page{padding-top:8mm}}

.invoice-footer{margin-top:auto;border-block:.2mm solid #111;padding:2mm 0;font:7.3pt/1.4 Arial,sans-serif;flex-shrink:0;break-inside:avoid;page-break-inside:avoid}.invoice-footer>div+div{margin-top:1mm}@media print{.invoice-footer{color:#111}}

/* Invoice footer: 20 mm reserve to the A4 bottom edge, independent of payment pages. */
.invoice-sheet:not(.invoice-payment-page){min-height:277mm}
@media print{.invoice-sheet:not(.invoice-payment-page){min-height:277mm}}

.tenant-choice{display:block;text-align:left;width:100%;color:inherit;background:transparent;border-radius:0;border-left:2px solid #627782}.tenant-choice[aria-pressed="true"]{border-left-color:#e36a59;background:#2b3d48}.tenant-choice:hover{background:#2b3d48}@media(max-width:700px){.tenant-choice{display:inline-block;width:auto;margin:12px 6px 0 0;padding:8px 12px}.tenant-choice small{display:none}}

/* Shop identity stays visible throughout the working area. */
@media screen{body[data-shop="tintenmax"]{background:#fce5ed}}
.tenant-choice{position:relative;margin-top:16px;padding:16px 12px;border:1px solid #526571;border-left:4px solid #627782;border-radius:9px;transition:background .15s,color .15s}
.tenant-choice b{display:block;font-size:15px;line-height:1.4;padding-right:40px}
.tenant-choice small{margin-top:5px;font-size:11px}
.tenant-choice[aria-pressed="true"]{background:#e6f1f8;border-color:#9cc2d9;border-left-color:#65b5e5;color:#182f40;box-shadow:0 0 0 2px #ffffff16}
.tenant-choice[aria-pressed="true"] small{color:#425e70}
.tenant-choice[aria-pressed="true"]::after{content:'AKTIV';position:absolute;right:9px;top:18px;padding:2px 5px;border-radius:4px;font-size:8px;font-weight:700;letter-spacing:.4px;background:#235e80;color:white}
body[data-shop="tintenmax"] .tenant-choice[data-tenant="tintenmax"][aria-pressed="true"]{background:#ffd4e4;border-color:#ed8eb0;border-left-color:#db4a83;color:#592238}
body[data-shop="tintenmax"] .tenant-choice[data-tenant="tintenmax"][aria-pressed="true"] small{color:#7d3f58}
body[data-shop="tintenmax"] .tenant-choice[aria-pressed="true"]::after{background:#a92d60}
body[data-shop="tintenmax"] #shop-heading{color:#a43160;font-weight:bold}
@media(max-width:700px){.tenant-choice{width:calc(50% - 10px);vertical-align:top;margin-top:12px}.tenant-choice b{font-size:13px}.tenant-choice[aria-pressed="true"]::after{top:16px}.tenant-choice small{display:block}}
