/* VESSIGO v8.91 — Supplier Catalog responsive modal
   Keep the entire dialog inside the viewport. Only product results scroll vertically. */
#v889CatalogDialog{
  width:min(1100px,calc(100vw - 32px)) !important;
  max-width:calc(100vw - 32px) !important;
  max-height:calc(100vh - 32px) !important;
  margin:auto !important;
  padding:0 !important;
  overflow:hidden !important;
  box-sizing:border-box !important;
}
#v889CatalogDialog > div{
  width:100% !important;
  max-width:none !important;
  height:min(760px,calc(100vh - 32px)) !important;
  max-height:calc(100vh - 32px) !important;
  padding:24px 28px !important;
  box-sizing:border-box !important;
  display:flex !important;
  flex-direction:column !important;
  overflow:hidden !important;
}
#v889CatalogDialog .section-head{flex:0 0 auto}
#v889CatalogDialog .form-grid{
  flex:0 0 auto;
  grid-template-columns:minmax(0,1fr) minmax(0,1fr) !important;
  gap:12px !important;
}
#v889CatalogDialog label{min-width:0}
#v889CatalogDialog input{width:100%;max-width:100%;box-sizing:border-box}
#v889Results{
  flex:1 1 auto !important;
  min-height:0 !important;
  max-height:none !important;
  overflow-y:auto !important;
  overflow-x:hidden !important;
  scrollbar-gutter:stable;
}
#v889Results .inventory-row{
  display:grid !important;
  grid-template-columns:minmax(0,1fr) auto !important;
  gap:14px !important;
  align-items:center !important;
}
#v889Results .inventory-main{min-width:0;overflow-wrap:anywhere}
#v889Results .inventory-actions{white-space:normal}
#v889Results .inventory-actions button{max-width:160px;white-space:normal}

@media (max-width:720px){
 #v889CatalogDialog{width:calc(100vw - 16px)!important;max-width:calc(100vw - 16px)!important;max-height:calc(100vh - 16px)!important}
 #v889CatalogDialog > div{height:calc(100vh - 16px)!important;max-height:calc(100vh - 16px)!important;padding:18px!important}
 #v889CatalogDialog .form-grid{grid-template-columns:1fr!important}
 #v889Results .inventory-row{grid-template-columns:1fr!important}
 #v889Results .inventory-actions button{width:100%;max-width:none}
}
