/* PHONETHIP Report Print Engine V6
   A4 landscape safe-fit printing for the 3 payroll reports.
   Physical page margin: 5 mm on all four sides.
   A separate 5 mm vertical safety inset keeps the header and footer away
   from the top and bottom printable edges without changing the approved
   left/right layout.
   The report is automatically reduced when any element is wider than the
   printable box, so no text or table column can cross the page boundary.
*/

@media screen {
  .report-v5-print-root { display: none !important; }
  .report-v5-measure-root {
    display: block !important;
    position: fixed !important;
    left: -20000px !important;
    top: 0 !important;
    width: 287mm !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
}

@media print {
  @page {
    size: A4 landscape !important;
    margin: 5mm !important;
  }

  html.report-v5-printing,
  html.report-v5-printing body {
    width: 100% !important;
    height: auto !important;
    min-width: 0 !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    background: #fff !important;
  }

  html.report-v5-printing body > *:not(.report-v5-print-root) {
    display: none !important;
  }

  html.report-v5-printing body > .report-v5-print-root {
    display: block !important;
  }

  .report-v5-print-root {
    --report-fit-scale: 1;
    position: static !important;
    display: block !important;
    width: 287mm !important;
    max-width: 287mm !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 auto !important;
    padding: 5mm 0 !important;
    overflow: visible !important;
    background: #fff !important;
    box-sizing: border-box !important;
  }

  .report-v5-print-root .report-v5-scale-box {
    display: block !important;
    width: calc(287mm / var(--report-fit-scale)) !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    zoom: var(--report-fit-scale) !important;
    transform-origin: top left !important;
    box-sizing: border-box !important;
  }

  .report-v5-print-root .doc,
  .report-v5-print-root .adaptive-a4-report,
  .report-v5-print-root .official-ledger-doc,
  .report-v5-print-root .report-v5-document {
    position: static !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
    transform: none !important;
    box-sizing: border-box !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .report-v5-print-root *,
  .report-v5-print-root *::before,
  .report-v5-print-root *::after {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .report-v5-print-root .modal-head,
  .report-v5-print-root .no-print,
  .report-v5-print-root button {
    display: none !important;
  }

  .report-v5-print-root table {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    border-collapse: collapse !important;
    border-spacing: 0 !important;
    table-layout: fixed !important;
    box-sizing: border-box !important;
  }

  .report-v5-print-root col,
  .report-v5-print-root colgroup {
    max-width: 100% !important;
  }

  .report-v5-print-root thead { display: table-header-group !important; }
  .report-v5-print-root tfoot { display: table-footer-group !important; }

  .report-v5-print-root tr {
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .report-v5-print-root th,
  .report-v5-print-root td {
    min-width: 0 !important;
    padding: 0.5mm 0.3mm !important;
    font-size: 5.8pt !important;
    line-height: 1.02 !important;
    white-space: normal !important;
    overflow: hidden !important;
    overflow-wrap: anywhere !important;
    word-break: break-word !important;
    box-sizing: border-box !important;
  }

  .report-v5-print-root td.money,
  .report-v5-print-root td.num,
  .report-v5-print-root .money,
  .report-v5-print-root .num {
    font-size: 5.55pt !important;
    white-space: nowrap !important;
  }

  .report-v5-print-root img,
  .report-v5-print-root svg,
  .report-v5-print-root canvas {
    max-width: 100% !important;
    height: auto !important;
  }

  .report-v5-print-root .adaptive-report-signatures,
  .report-v5-print-root .sign,
  .report-v5-print-root .sign-row,
  .report-v5-print-root [class*="signature"] {
    width: 100% !important;
    margin-top: 4mm !important;
    min-height: 23mm !important;
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .report-v5-print-root .doc-footer {
    position: static !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    width: 100% !important;
    margin: 2mm 0 0 !important;
    padding: 0 !important;
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .report-v5-print-root,
  .report-v5-print-root .report-v5-scale-box,
  .report-v5-print-root .report-v5-document {
    page-break-before: auto !important;
    page-break-after: auto !important;
  }
}
