.proof-scroll { overflow:auto; border:1px solid #ccd4d8; max-height:70vh; }
.proof-matrix { border-collapse:collapse; table-layout:fixed; width:max-content; min-width:100%; font-size:11px; }
.proof-matrix th,.proof-matrix td { border:1px solid #dfe2e5; padding:5px 3px; width:34px; min-width:34px; text-align:center; vertical-align:middle; overflow-wrap:anywhere; }
.proof-matrix tr>th:first-child { text-align:left; width:235px; min-width:235px; position:sticky; left:0; background:#fff; z-index:1; font-weight:400; }
.proof-matrix thead th { position:sticky; top:0; background:#fff; z-index:2; }
.proof-matrix thead th:first-child { z-index:3; }
.proof-matrix tr:nth-child(even) td { background:#f6f7f8; }
.proof-matrix .weekend { background:#e9e9e9 !important; }
.proof-matrix .proof-group th { font-weight:700; padding:8px; background:#f1f4f6; position:static; }
.proof-legend { font-size:11px; margin:12px 0; }
#proofPrintDialog { width:96vw; max-width:1600px; height:90vh; border:1px solid #c3cdd3; border-radius:4px; overflow:auto; }
#proofPrintDialog::backdrop { background:#0006; }
.proof-print-actions { display:flex; justify-content:flex-end; gap:10px; position:sticky; top:0; background:white; padding:8px; z-index:4; }
#proofPrintContent { padding:16px; color:#111; background:#eef1f2; }
.proof-paper { position:relative; width:190mm; height:277mm; margin:0 auto 20px; background:white; box-shadow:0 1px 5px #0003; }
.proof-paper-body { position:absolute; left:190mm; top:0; width:277mm; height:190mm; padding:4mm; box-sizing:border-box; transform:rotate(90deg); transform-origin:top left; display:flex; flex-direction:column; font-size:10px; }
.proof-paper-body > * { flex-shrink:0; }
.proof-page-footer { margin-top:auto; min-height:100px; padding-top:12px; }
.proof-page-number { margin:12px 0 0; text-align:right; font-size:9px; }
.proof-print-status { margin:0 0 6px; font-size:10px; }
.proof-paper-body .proof-print-header { overflow-wrap:anywhere; }
#proofPrintContent .proof-matrix tr>th:first-child { overflow-wrap:anywhere; }
#proofPrintContent h1 { font-size:20px; margin:0 0 18px; }
#proofPrintContent .proof-matrix { width:100%; min-width:0; font-size:9px; }
#proofPrintContent .proof-matrix th,#proofPrintContent .proof-matrix td { width:auto; min-width:0; position:static; font-size:9px; line-height:1.25; padding:4px 1px; overflow-wrap:normal; }
#proofPrintContent .proof-matrix tr>th:first-child { width:185px; min-width:0; }
.proof-print-header { display:flex; justify-content:space-between; gap:40px; line-height:1.7; margin-bottom:18px; font-size:12px; }
.proof-signatures { display:flex; justify-content:space-between; gap:24px; margin-top:45px; font-size:12px; }
@media print {
  .modal.hidden { display:none !important; }
  body.printing-proof > :not(#proofPrintDialog) { display:none !important; }
  body.printing-proof #proofPrintDialog { display:block !important; position:static; width:auto; height:auto; max-width:none; max-height:none; overflow:visible; margin:0; padding:0; border:0; }
  .proof-print-actions { display:none !important; }
  #proofPrintContent { min-width:0; padding:0; background:white; }
  .proof-paper { width:210mm; height:297mm; margin:0; box-shadow:none; break-after:page; break-inside:avoid; }
  .proof-paper-body { left:200mm; top:10mm; }
  .proof-paper:last-child { break-after:auto; }
  .proof-signatures { break-inside:avoid; }
  body.printing-proof { margin:0; }
  #proofPrintContent { page:proof-sheet; }
  body.printing-kva > :not(#kvaPrintModal) { display:none !important; }
  @page proof-sheet { size:A4 portrait; margin:0; }
}
