/* ERP paper contract: ISO A4, paper margins are applied exactly once. */
@page{size:A4 portrait!important;margin:10mm!important}
@page portrait-page{size:A4 portrait!important;margin:10mm!important}
@page landscape-page{size:A4 landscape!important;margin:10mm!important}
@page slip-sheet{size:A4 portrait!important;margin:0!important}
@media screen{
  body.a4-document .a4-page:not(.two-up-page){box-sizing:border-box;width:210mm;max-width:none;min-height:297mm;height:auto;padding:10mm;margin:16px auto}
  body.a4-document .a4-page.landscape{width:297mm;min-height:210mm}
  body.a4-document{overflow-x:auto}
}
@media print{
  html,body{margin:0!important;padding:0!important;background:#fff!important;min-width:0!important;height:auto!important;overflow:visible!important}
  .topbar,.global-nav,.workspace-tabs,.mobile-nav,.build-tag,.print-toolbar,.infographic-print-toolbar,.cd-actionbar,.ledger5-actionbar{display:none!important}
  main.shell{width:100%!important;max-width:none!important;min-width:0!important;margin:0!important;padding:0!important;overflow:visible!important}
  body.a4-document .a4-page:not(.two-up-page){page:portrait-page;box-sizing:border-box;width:190mm!important;max-width:190mm!important;min-height:0!important;height:auto!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;overflow:visible!important;display:block!important;break-after:page}
  body.a4-document .a4-page.landscape{page:landscape-page;width:277mm!important;max-width:277mm!important}
  body.a4-document .a4-page:last-of-type{break-after:auto;page-break-after:auto}
  body.a4-document .two-up-page{page:slip-sheet;width:210mm!important;height:297mm!important;min-height:297mm!important;max-width:none!important;margin:0!important;box-sizing:border-box}
  body.a4-document .a4-page table{max-width:100%;min-width:0;overflow-wrap:anywhere}
  body.a4-document thead{display:table-header-group}
  body.a4-document tfoot{display:table-row-group}
  body.a4-document tr{break-inside:avoid}
  body.a4-document .a4-page:before{display:none!important}
  body.a4-document .cf-empty{display:none!important}
  body.a4-document .stationery-brand{margin-bottom:5mm}
  body.a4-document .cf-title{margin-bottom:5mm}
  body.a4-document .stationery-meta{gap:6mm;margin-bottom:5mm}
  body.a4-document .cf-table th,body.a4-document .cf-table td{padding:2mm 1.5mm}
  body.a4-document .stationery-summary{margin:5mm 0 5mm auto}
  body.a4-document .stationery-footer{margin-top:5mm;padding:3mm 0;border-bottom-width:3mm}
  .ledger5-table-wrap,.cd-table-wrap{height:auto!important;max-height:none!important;min-height:0!important;overflow:visible!important}
  #item-ledger,#company-ledger{page:landscape-page}
  .ledger5-table{width:100%!important;min-width:0!important;font-size:8pt;table-layout:auto}
}
