/* Printable documents (receipt, voucher, salary slip, report) — same markup on screen and paper */
.doc { background: #fff; color: #111; padding: 22px 26px; font-size: 12.5px; margin: 0 auto; }
.doc.receipt { max-width: 420px; border: 1px solid #d8d2c2; }
.doc.sheet { max-width: 900px; }
.doc-head { text-align: center; border-bottom: 2px solid #eda81c; padding-bottom: 10px; margin-bottom: 10px; }
.doc-head img { width: 46px; height: 46px; }
.doc-head h3 { margin: 4px 0 0; font-size: 17px; color: #8f0c0c; font-weight: 800; }
.doc-head p { margin: 0; font-size: 11.5px; color: #444; }
.doc-title { text-align: center; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; font-size: 12.5px; margin: 8px 0; color: #8f0c0c; }
.doc-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 3px 18px; margin-bottom: 10px; }
.doc table { width: 100%; border-collapse: collapse; margin-bottom: 8px; }
.doc table th { border-bottom: 1.5px solid #8f0c0c; text-align: left; padding: 5px 6px; font-size: 11.5px; color: #8f0c0c; }
.doc table td { padding: 4px 6px; border-bottom: 1px solid #e8e5dc; vertical-align: top; }
.doc table .num { text-align: right; }
.doc table tfoot td { font-weight: 800; border-top: 1.5px solid #8f0c0c; }
.doc-thanks { text-align: center; margin-top: 12px; border-top: 1px dashed #999; padding-top: 8px; font-size: 11.5px; }
.doc-sign { display: flex; justify-content: space-between; gap: 24px; margin-top: 44px; }
.doc-sign div { flex: 1; border-top: 1px solid #555; text-align: center; padding-top: 4px; font-size: 11px; }
.doc-words { font-style: italic; margin: 4px 0; }
.doc-cancel { text-align: center; color: #b3362c; border: 2px solid #b3362c; font-weight: 800; letter-spacing: 3px; margin-bottom: 8px; }

#print-area { display: none; }

@media print {
  @page { margin: 10mm; }
  body, body.erp { background: #fff !important; }
  body > *:not(#print-area) { display: none !important; }
  #print-area { display: block !important; }
  #print-area .doc { box-shadow: none; max-width: 100%; min-width: 0; padding: 0; }
  #print-area .doc.receipt { max-width: 100mm; border: 0; margin: 0 auto; }
  #print-area table { page-break-inside: auto; }
  #print-area tr { page-break-inside: avoid; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
