
/* v195: (1) hidden report sections stay hidden, (2) phones get 2 KPI cards per row, (3) date pickers keep their calendar button,
   (4) short laptop screens (<=760px tall) scroll instead of cutting the table footer / pagination. */
@media screen and (max-width:1099px){
  html body :is(#dashboardTab,#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab) [style*="display:none"],html body :is(#dashboardTab,#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab) [style*="display: none"],
  html body #erpReportsTab#erpReportsTab [style*="display:none"],html body #erpReportsTab#erpReportsTab [style*="display: none"]{display:none!important;}
  html body #erpReportsTab#erpReportsTab .pk-date-wrap{display:flex!important;align-items:center!important;gap:6px!important;width:100%!important;}
  html body #erpReportsTab#erpReportsTab .pk-date-wrap input[type=text]{flex:1 1 0!important;width:auto!important;min-width:0!important;}
  html body #erpReportsTab#erpReportsTab .pk-date-wrap .pk-date-btn{flex:0 0 auto!important;}
  html body #erpReportsTab#erpReportsTab .erp-header-actions{flex:1 1 auto!important;}
}
@media screen and (max-width:699px){
  html body #erpReportsTab#erpReportsTab .erp-ar-kpis,
  html body :is(#dashboardTab,#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab) :is(.ud-kpis,[class*="-ui-kpis"],.ph-kpis,.mj-kpis){grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important;}
  html body #erpReportsTab#erpReportsTab .erp-header-actions{width:100%!important;}
  html body #erpReportsTab#erpReportsTab .erp-header-actions .btn{flex:1 1 auto!important;}
}
@media screen and (min-width:1100px) and (max-height:760px){
  html body:has(:is(#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab,#backupTab).active) .main-content{overflow-x:hidden!important;overflow-y:auto!important;height:100dvh!important;}
  html body :is(#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab).tab-content.active{height:auto!important;min-height:0!important;max-height:none!important;overflow:visible!important;}
  html body :is(#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab) :is([class*="-ui-panel"],.ph-panel,.mj-section,.mj-report,.erp-ar-report,.erp-ar-panel){height:auto!important;min-height:0!important;max-height:none!important;flex:0 0 auto!important;overflow:visible!important;}
  html body :is(#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab) :is(.table-container,.table-responsive,.table-wrap,.ph-table-wrap,[class*="-ui-table-wrap"]){height:auto!important;max-height:none!important;flex:0 0 auto!important;overflow-x:auto!important;overflow-y:visible!important;}
  html body :is(#partiesTab,#weightMasterTab,#openingStockTab,#challansTab,#danaTab,#molderJobsTab,#dispatchesTab,#billsTab,#paymentsTab,#ledgersTab,#erpReportsTab) :is([class*="-ui-footer"],.erp-ar-table-footer,.vp-pagination,.ph-footer){flex:0 0 auto!important;height:auto!important;min-height:0!important;}
}
