/* Scoped procurement design. No external fonts, icon service or CSS runtime. */
#sectionProjectflow > :not(#localProcurementWorkspace){display:none!important}
#sectionProjectflow{background:#f7f7ff!important;padding:24px!important}
#localProcurementWorkspace,.pf-dialog{font-family:Inter,"Segoe UI",Arial,sans-serif;color:#172039;font-size:14px;line-height:1.5}
.pf-dialog{margin:auto}
.pf-sidebar-nav{display:block}.pf-sidebar-nav-items{margin:3px 0 8px 28px;padding-left:9px;border-left:1px solid #334155}.pf-sidebar-nav-items button{display:flex;width:100%;align-items:center;justify-content:space-between;gap:8px;border:0;border-radius:8px;background:transparent;color:#94a3b8;padding:6px 8px;text-align:left;font:600 11px/1.25 Inter,"Segoe UI",sans-serif;cursor:pointer}.pf-sidebar-nav-items button:hover{background:#1e293b;color:#fff}.pf-sidebar-nav-items button.is-active{background:#1e293b;color:#fff;box-shadow:inset 2px 0 #60a5fa}.pf-nav-count{min-width:18px;border-radius:999px;background:#334155;color:#cbd5e1;padding:1px 5px;text-align:center;font:700 9px/1.4 ui-monospace,monospace}.pf-nav-live{margin-left:auto;border-radius:5px;background:#155e7555;color:#67e8f9;padding:2px 6px;font:700 9px/1.3 ui-monospace,monospace;white-space:nowrap}
.pf-hero{display:flex;justify-content:space-between;align-items:center;gap:24px;border-radius:16px;background:linear-gradient(110deg,#eeefff,#e4e9ff);padding:28px;margin-bottom:22px}
.pf-eyebrow{font-size:10px;letter-spacing:.14em;font-weight:800;color:#193b9b}
.pf-hero h1{font-size:28px;line-height:1.2;font-weight:750;margin:9px 0;letter-spacing:-.035em}
.pf-hero p,.pf-footnote{color:#647089;font-size:12px;margin:0}
.pf-actions,.pf-row-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.pf-button{border:1px solid #dbe0ed;background:#fff;color:#253552;border-radius:8px;padding:9px 13px;font-size:12px;font-weight:650;cursor:pointer;white-space:nowrap;min-height:38px}
.pf-button:hover{background:#eef2ff;border-color:#bbc8ef}.pf-button:disabled{opacity:.5;cursor:wait}
.pf-primary{background:#123baf;color:#fff;border-color:#123baf;box-shadow:0 2px 3px #14379922}.pf-primary:hover{background:#0a2b87;color:white}
.pf-stages{display:flex;background:white;padding:12px;border:1px solid #eceef8;border-radius:12px;gap:5px;overflow-x:auto;margin-bottom:22px}
.pf-stages button{display:flex;align-items:center;gap:9px;min-width:118px;flex:1;padding:12px 9px;background:transparent;border:0;border-radius:9px;color:#46516b;font-size:11px;text-align:left;cursor:pointer}
.pf-stages button span{display:grid;place-items:center;width:27px;height:27px;flex-shrink:0;background:#edf0fd;border-radius:100%;color:#163895;font-weight:700}
.pf-stages button[aria-current=step]{background:#eef0ff;color:#082b9d;font-weight:750}.pf-stages button[aria-current=step] span{background:#123baf;color:white}
.pf-metrics{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:14px;margin-bottom:24px}
.pf-metrics button{border:1px solid #edf0f8;border-right:5px solid var(--accent);border-radius:12px;background:white;padding:17px;text-align:left;cursor:pointer}
.pf-metrics small{display:block;min-height:28px;font-size:10px;text-transform:uppercase;letter-spacing:.05em;color:#56617a}.pf-metrics strong{display:block;font-size:30px;font-weight:750;font-variant-numeric:tabular-nums}.pf-metrics span{font-size:10px;color:var(--accent)}
.pf-card{background:white;border:1px solid #e8ebf5;border-radius:13px;overflow:hidden}.pf-toolbar{display:flex;align-items:end;gap:12px;flex-wrap:wrap;padding:18px}.pf-toolbar label{font-size:10px;color:#657087;font-weight:700}.pf-search{flex:1;min-width:230px}.pf-toolbar input,.pf-toolbar select{display:block;width:100%;border:1px solid #dce2f0;background:#f8f9ff;border-radius:7px;min-height:40px;padding:9px 11px;margin-top:5px;font-size:12px;color:#293653}
.pf-register-title{display:flex;align-items:center;gap:12px;background:#f1f3ff;padding:14px 20px}.pf-register-title h2{margin:0;font-size:15px;font-weight:700}.pf-register-title span{font-size:11px;color:#53638e;background:#e0e6ff;padding:3px 8px;border-radius:20px}
.pf-table-scroll{overflow:auto}.pf-table{border-collapse:collapse;width:100%;text-align:left;font-size:12px}.pf-table thead{background:#eaedfc}.pf-table th{padding:12px 16px;font-size:9px;text-transform:uppercase;letter-spacing:.07em;color:#56637b;white-space:nowrap}.pf-table td{padding:17px 16px;border-bottom:1px solid #f0f2f8;vertical-align:middle;min-width:100px;max-width:300px;overflow-wrap:anywhere}.pf-table small{display:block;font-size:10px;color:#778197;margin-top:5px}.pf-table tbody tr:hover{background:#fafbff}.pf-table b{font-weight:650}.pf-number{font-variant-numeric:tabular-nums;white-space:nowrap}.pf-link{background:none;border:0;color:#153baf;font-weight:750;cursor:pointer;text-align:left}.pf-status{display:inline-block;background:#fff6e6;color:#905609;padding:4px 9px;border-radius:30px;font-size:10px;white-space:nowrap}.pf-success{background:#e2f7ee;color:#0e7259}.pf-row-actions .pf-button{font-size:10px;padding:5px 8px;min-height:30px}
.pf-pagination{display:flex;align-items:center;justify-content:space-between;padding:14px 20px;font-size:11px;color:#60708a;background:#f8f9ff}.pf-pagination>div{display:flex;align-items:center;gap:15px}.pf-empty{padding:50px 20px;text-align:center;color:#6a748b}.pf-empty strong{display:block;color:#2a3856;font-size:16px}.pf-empty p{margin:10px 0 18px}.pf-footnote{padding:15px 0}.pf-nav-receipts{width:100%;text-align:left;background:none;border:0;padding:7px 12px;color:#becaeb;font-size:11px;cursor:pointer}
.pf-dialog{width:min(1000px,calc(100vw - 36px));max-height:90vh;padding:0;border:1px solid #e0e4f0;border-radius:16px;box-shadow:0 30px 80px #13234c44;background:white}.pf-dialog::backdrop{background:#17213b80;backdrop-filter:blur(3px)}.pf-dialog form>header{display:flex;justify-content:space-between;align-items:center;padding:22px 28px;border-bottom:1px solid #e9edf5;background:#f8f9ff}.pf-dialog h2{font-weight:750;font-size:22px;margin:5px 0}.pf-dialog [data-close]:not(.pf-button){background:none;border:0;font-size:28px;color:#66728b;cursor:pointer}.pf-dialog-body{padding:26px;overflow:auto;max-height:65vh}.pf-dialog form>footer{padding:16px 26px;border-top:1px solid #e5e9f3;display:flex;justify-content:end;gap:9px}.pf-dialog label{display:block;font-size:12px;font-weight:650;color:#44516c;margin:12px 0}.pf-dialog input,.pf-dialog select,.pf-dialog textarea{display:block;width:100%;border:1px solid #ced6e7;border-radius:8px;padding:11px;margin-top:5px;color:#26344e;background:white;font:inherit;box-sizing:border-box}.pf-dialog input[type=number]{min-width:85px;max-width:125px}.pf-form-grid{display:grid;grid-template-columns:1fr 1fr;gap:6px 22px}.pf-error{padding:0 26px;color:#b4233b;font-size:12px}.pf-signature{margin-top:50px!important}.pf-print-surface h1{font-size:26px;font-weight:750;margin-bottom:16px}.pf-print-surface p{margin:12px 0}.pf-print-surface h3{font-weight:700;margin-top:20px}#pf-master-records{white-space:pre-wrap;padding:15px;background:#f5f7ff;margin-top:15px}
#localProcurementWorkspace :focus-visible,.pf-dialog :focus-visible{outline:3px solid #7897ed;outline-offset:2px}
#procurementEntryModal{border-radius:16px!important;border:1px solid #d7dff2!important;background:#fff!important;box-shadow:0 25px 70px #12244b33!important}#procurementEntryModal input,#procurementEntryModal select,#procurementEntryModal textarea{min-height:42px!important;border-radius:8px!important;font-size:12px!important}#procurementEntryModal form>div:first-child{background:#f3f5ff!important}#procurementEntryModal button{min-height:38px}#procurementDetailOverlay>div{border-radius:16px 0 0 16px}
@media(max-width:1050px){.pf-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}.pf-hero{align-items:start}.pf-hero h1{font-size:24px}.pf-table{min-width:760px}}

/* Procurement is a single responsive workspace shared by every workflow stage. */
@media(max-width:767px){
  #sectionProjectflow{padding:10px!important;overflow-x:hidden}
  #localProcurementWorkspace{min-width:0;width:100%;overflow:visible}
  .pf-hero{padding:18px;flex-direction:column;align-items:stretch;gap:14px;border-radius:13px;margin-bottom:14px}
  .pf-hero h1{font-size:24px;margin:6px 0;overflow-wrap:anywhere}
  .pf-hero .pf-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%}
  .pf-hero .pf-button{width:100%;justify-content:center}
  .pf-stages{position:relative;gap:7px;margin:0 -10px 14px;padding:10px;border-left:0;border-right:0;border-radius:0;scroll-snap-type:x proximity;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
  .pf-stages button{flex:0 0 112px;min-width:112px;min-height:58px;padding:9px 8px;scroll-snap-align:start;line-height:1.25}
  .pf-stages button span{width:25px;height:25px}
  .pf-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-bottom:14px}
  .pf-metrics button{min-width:0;padding:12px;border-right-width:4px}
  .pf-metrics small{min-height:25px;font-size:9px}.pf-metrics strong{font-size:25px}
  .pf-metrics button:last-child:nth-child(odd){grid-column:1/-1}
  .pf-card{border-radius:12px;overflow:visible}
  .pf-toolbar{display:grid;grid-template-columns:minmax(0,1fr);align-items:stretch;gap:10px;padding:13px}
  .pf-search{min-width:0}.pf-toolbar label{width:100%}.pf-toolbar input,.pf-toolbar select{min-height:46px;font-size:16px}
  .pf-toolbar>.pf-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;width:100%}
  .pf-toolbar>.pf-actions .pf-button{width:100%;min-width:0;white-space:normal;line-height:1.2}
  .pf-register-title{padding:13px 14px;justify-content:space-between}.pf-register-title h2{font-size:16px}
  #localProcurementWorkspace .pf-card>.pf-table-scroll{overflow:visible}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table{display:block;min-width:0;width:100%;padding:10px;background:#f7f8fd}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table thead{display:none}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table tbody{display:grid;gap:10px}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table tr{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:0;background:#fff;border:1px solid #e3e7f2;border-radius:11px;overflow:hidden;box-shadow:0 2px 8px #24365d0d}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td{display:block;min-width:0;max-width:none;padding:10px 12px;border-bottom:1px solid #edf0f6;overflow-wrap:anywhere}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td::before{display:block;margin-bottom:4px;color:#778197;font:800 8px/1.2 Inter,"Segoe UI",sans-serif;letter-spacing:.08em;text-transform:uppercase}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(1)::before{content:"Reference / Date"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(2)::before{content:"Supplier / Department"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(3)::before{content:"Linked documents"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(4)::before{content:"Items"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(5)::before{content:"Value"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(6)::before{content:"Status"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(7){grid-column:1/-1;border-bottom:0}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(7)::before{content:"Actions"}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td[colspan]{grid-column:1/-1;padding:0;border:0}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td[colspan]::before{display:none}
  .pf-row-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%}.pf-row-actions .pf-button{min-height:40px;width:100%;white-space:normal}
  .pf-pagination{align-items:flex-start;gap:10px;padding:12px 14px}.pf-pagination>div{gap:7px}.pf-pagination .pf-button{min-width:42px}
  .pf-empty{padding:34px 14px}
  .pf-dialog{width:calc(100vw - 12px);max-height:calc(100dvh - 12px);border-radius:13px}
  .pf-dialog form{display:flex;flex-direction:column;max-height:calc(100dvh - 14px)}
  .pf-dialog form>header{position:sticky;top:0;z-index:2;align-items:flex-start;padding:15px 16px}
  .pf-dialog h2{font-size:19px;overflow-wrap:anywhere}.pf-dialog-body{min-height:0;max-height:none;padding:15px;overflow:auto}
  .pf-dialog form>footer{position:sticky;bottom:0;z-index:2;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));padding:11px 14px;background:#fff}
  .pf-dialog form>footer .pf-button{min-height:44px;width:100%;white-space:normal}
  .pf-dialog .pf-error{padding:0 15px}.pf-form-grid{grid-template-columns:minmax(0,1fr);gap:2px}
  .pf-dialog input,.pf-dialog select,.pf-dialog textarea{min-height:46px;font-size:16px}
  .pf-dialog input[type=number]{max-width:none;width:100%}
  .pf-dialog .pf-table-scroll{margin:0 -4px;overflow-x:auto;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
  .pf-dialog .pf-table{min-width:620px}
  .pf-sidebar-nav-items{margin-left:22px;padding-left:6px}.pf-sidebar-nav-items button{min-height:38px;padding:7px;font-size:10px}

  /* The legacy PR/PO/PI entry form becomes a true touch-first card form. */
  #procurementEntryModal{height:calc(100dvh - 12px)!important;max-height:calc(100dvh - 12px)!important;transform:none!important;translate:none!important}
  #procurementEntryModal>div:first-child{position:sticky;top:0;z-index:4;background:#fff;padding:14px!important}
  #procurementEntryModal form{padding:12px!important;padding-bottom:0!important}
  #procurementEntryModal form>section{min-width:0}
  #procurementEntryModal .procurement-item-header{display:none!important}
  #procurementEntryModal[data-entry-type] .procurement-item-grid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;width:auto!important;max-width:100%!important;min-width:0!important;margin:10px;border:1px solid #dce3ee;border-radius:12px;overflow:hidden;background:#fff;box-shadow:0 2px 9px #13234c0d}
  #procurementEntryModal .procurement-item-row>div{display:block!important;min-width:0;padding:9px!important;border-right:0!important;border-bottom:1px solid #edf0f6}
  #procurementEntryModal .procurement-item-row>div::before{display:block;margin-bottom:5px;color:#64748b;font-size:9px;font-weight:800;letter-spacing:.06em;text-transform:uppercase}
  #procurementEntryModal .procurement-item-row>div:first-child{grid-column:1/-1;background:#f3f6fb;color:#334155}
  #procurementEntryModal .procurement-item-row>div:first-child::before{content:"Item";display:inline;margin-right:5px}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="code"])::before{content:"Item code"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="description"])::before{content:"Description"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="currentStock"])::before{content:"Current stock"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="orderedQty"])::before{content:"Ordered quantity"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="receivedQty"])::before{content:"Received quantity"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="material"])::before{content:"Material / category"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="qty"])::before{content:"Requested quantity"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="unit"])::before{content:"Unit"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="remarks"])::before{content:"Remarks"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="poRate"])::before{content:"PO rate"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="unitPrice"])::before{content:"Unit price"}
  #procurementEntryModal .procurement-item-row>div:has([data-procurement-item="total"])::before{content:"Line total"}
  #procurementEntryModal .procurement-item-row>div:last-child{grid-column:1/-1;border-bottom:0}
  #procurementEntryModal .procurement-item-row>div:last-child::before{content:"Remove item"}
  #procurementEntryModal .procurement-item-row input,#procurementEntryModal .procurement-item-row select{width:100%;min-width:0;min-height:44px;font-size:16px!important}
  #procurementEntryModal .procurement-item-row button{width:100%!important;min-height:42px!important}
  #procurementEntryModal form>.sticky{position:sticky!important;bottom:0;z-index:5;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));margin:0 -12px!important;padding:10px 12px!important;box-shadow:0 -5px 16px #13234c12}
  #procurementEntryModal form>.sticky button{width:100%;min-height:44px;padding:9px!important;white-space:normal}
  #procurementEntryModal form>.sticky button:last-child{grid-column:1/-1}
}

@media(max-width:420px){
  .pf-hero{padding:15px}.pf-hero h1{font-size:21px}.pf-hero .pf-actions{grid-template-columns:1fr}
  .pf-metrics{grid-template-columns:1fr}.pf-metrics button:last-child:nth-child(odd){grid-column:auto}.pf-metrics small{min-height:0}
  .pf-toolbar>.pf-actions{grid-template-columns:1fr}.pf-row-actions{grid-template-columns:1fr}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table tr{grid-template-columns:1fr}
  #localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td:nth-child(7),#localProcurementWorkspace .pf-card>.pf-table-scroll>.pf-table td[colspan]{grid-column:auto}
  .pf-pagination{flex-direction:column}.pf-pagination>div{width:100%;justify-content:space-between}
  .pf-dialog form>footer{grid-template-columns:1fr}
  #procurementEntryModal[data-entry-type] .procurement-item-grid{grid-template-columns:1fr!important}
  #procurementEntryModal .procurement-item-row>div:first-child,#procurementEntryModal .procurement-item-row>div:last-child{grid-column:auto}
  #procurementEntryModal form>.sticky{grid-template-columns:1fr}
  #procurementEntryModal form>.sticky button:last-child{grid-column:auto}
}

/* Attachment viewer: protected previews with native mobile fallbacks. */
body.attachment-preview-open{overflow:hidden}
#attachmentPreviewModal{display:flex;flex-direction:column}
#attachmentPreviewModal.hidden{display:none!important}
#attachmentPreviewModal>div:first-child{flex:0 0 auto;gap:12px}
#attachmentPreviewModal>div:first-child>div:last-child{display:flex;align-items:center;justify-content:flex-end;gap:7px;flex-wrap:wrap}
#attachmentPreviewModal>div:last-child{flex:1 1 auto;min-height:0;overflow:auto}
#attachmentPreviewContent{display:flex;min-height:300px;flex-direction:column;align-items:stretch!important;justify-content:flex-start!important;gap:10px;overflow:auto;padding:10px!important}
.attachment-preview-action{display:inline-flex;min-height:38px;align-items:center;justify-content:center;border:1px solid #d7deeb;border-radius:9px;background:#f8fafc;color:#334155;padding:8px 11px;font:750 11px/1.15 Inter,"Segoe UI",sans-serif;text-decoration:none;cursor:pointer;white-space:nowrap}
.attachment-preview-action:hover{border-color:#9aabd0;background:#eef2ff;color:#173a9b}
.attachment-preview-close{display:inline-flex!important;min-width:38px;min-height:38px;align-items:center;justify-content:center}
.attachment-image-preview{display:block;max-width:100%;max-height:68vh;margin:auto;object-fit:contain;border-radius:10px}
.attachment-pdf-preview,.attachment-document-preview{display:block;width:100%;height:64vh;min-height:360px;border:1px solid #dce2ee;border-radius:10px;background:#fff}
.attachment-native-card{display:flex;flex-wrap:wrap;align-items:center;gap:5px 12px;border:1px solid #dbe3f0;border-radius:10px;background:#f7f9fc;padding:11px 12px;color:#44516b}
.attachment-native-title{font-weight:750;color:#26344e}.attachment-native-note{flex:1 1 250px;font-size:11px;color:#69758c}.attachment-native-open{display:inline-flex;min-height:40px;align-items:center;border-radius:8px;background:#123baf;color:#fff;padding:8px 13px;font-weight:750;text-decoration:none;white-space:nowrap}
.attachment-text-preview{min-height:300px;margin:0;overflow:auto;border-radius:9px;background:#111827;color:#e5e7eb;padding:14px;font:12px/1.55 ui-monospace,SFMono-Regular,Consolas,monospace;white-space:pre-wrap;overflow-wrap:anywhere}
.attachment-sheet-scroll{max-height:60vh;overflow:auto;border:1px solid #dce2ee;border-radius:9px;-webkit-overflow-scrolling:touch}.attachment-sheet-preview{border-collapse:collapse;min-width:100%;background:#fff;font-size:11px}.attachment-sheet-preview th,.attachment-sheet-preview td{border:1px solid #e2e7f0;padding:7px 9px;white-space:nowrap}.attachment-sheet-preview th{position:sticky;top:0;background:#eef2ff;color:#263e80;text-align:left}.attachment-preview-limit,.attachment-loading{padding:18px;text-align:center;color:#64748b}
@media(max-width:767px){
  #attachmentPreviewModal{inset:6px!important;width:calc(100vw - 12px)!important;height:calc(100dvh - 12px)!important;max-height:none!important;transform:none!important;translate:none!important;border-radius:13px!important}
  #attachmentPreviewModal>div:first-child{align-items:flex-start!important;padding:11px 12px!important}
  #attachmentPreviewModal>div:first-child>div:first-child{flex:1 1 100%;min-width:0}
  #attachmentPreviewModal>div:first-child>div:last-child{flex:1 1 100%;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));width:100%}
  .attachment-preview-action,.attachment-preview-close{width:100%;min-width:0;min-height:44px;padding:8px 5px;white-space:normal;text-align:center}
  #attachmentPreviewModal>div:last-child{padding:6px!important}
  #attachmentPreviewContent{min-height:0;height:100%;padding:6px!important;border-radius:9px!important}
  .attachment-pdf-preview,.attachment-document-preview{height:calc(100dvh - 230px);min-height:280px}
  .attachment-native-card{position:sticky;bottom:0;z-index:2;align-items:stretch}.attachment-native-open{width:100%;justify-content:center}
  .attachment-image-preview{max-height:calc(100dvh - 190px)}
  .attachment-sheet-scroll{max-height:calc(100dvh - 260px)}
}
@media(max-width:420px){#attachmentPreviewModal>div:first-child>div:last-child{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media print{
  body.attachment-printing>*:not(#attachmentPreviewModal){display:none!important}
  body.attachment-printing #attachmentPreviewModal{position:static!important;display:block!important;width:100%!important;height:auto!important;max-width:none!important;max-height:none!important;border:0!important;box-shadow:none!important;transform:none!important;translate:none!important}
  body.attachment-printing #attachmentPreviewModal>div:first-child,#attachmentPreviewModal .attachment-native-card{display:none!important}
  body.attachment-printing #attachmentPreviewModal>div:last-child,#attachmentPreviewContent{max-height:none!important;height:auto!important;overflow:visible!important;padding:0!important;border:0!important}
}
@media print{body:has(#pf-dialog[open])>*:not(#pf-dialog){display:none!important}#pf-dialog[open]{position:static!important;width:100%!important;max-width:none!important;max-height:none!important;border:0;box-shadow:none;overflow:visible}#pf-dialog form>header,#pf-dialog form>footer,#pf-dialog .pf-error{display:none!important}#pf-dialog .pf-dialog-body{max-height:none;overflow:visible;padding:0}.pf-table{min-width:0!important}.pf-table td,.pf-table th{font-size:10px;padding:8px;min-width:0}.pf-table tr{break-inside:avoid}.pf-table thead{display:table-header-group}.pf-print-surface{color:#000}@page{size:A4;margin:14mm}}
