.portal-drawer-backdrop{position:fixed!important;left:0!important;right:0!important;bottom:0!important;width:auto!important;background:rgba(23,44,67,.28)!important;opacity:1!important;filter:none!important}
.portal-drawer{display:flex!important;flex-direction:column;box-sizing:border-box;background:#f5f8fa;border:0;border-inline-start:1px solid #dce5eb;box-shadow:-12px 0 40px #172c4326;animation:portal-drawer-enter .22s ease-out;overflow:hidden!important;text-align:start}
.portal-drawer .portal-drawer-bar{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 20px;background:#fff;border-bottom:1px solid #dce5eb;color:#365f64;font:14px/1.8 wyekan,Tahoma,sans-serif;direction:rtl}
.portal-drawer-close{border:1px solid #d7e0e8;background:#f5f8fa;color:#40556c;border-radius:9px;padding:6px 14px;cursor:pointer;font:inherit}
.portal-drawer .portal-drawer-scroll{flex:1 1 0;min-height:0;overflow:auto;overscroll-behavior:contain;padding:20px;scrollbar-width:thin;scrollbar-color:#a8c9c6 #f5f8fa}
.portal-drawer .portal-drawer-content{width:auto!important;min-width:0;border-radius:0!important;box-shadow:none!important;display:flow-root}
.portal-drawer-content>div[id$="Table"]{float:none!important;width:100%}
.portal-drawer-content>div[id$="Table"]>table{width:100%;border-collapse:collapse}
.portal-drawer-content>div[id$="Table"]>table>tbody>tr>td{height:auto!important;border:0!important;padding:0!important;background:transparent!important}
.portal-drawer-content form{box-sizing:border-box;background:#fff;color:#40556c;border:1px solid #dce5eb;border-radius:12px;padding:18px;margin:0;font-family:wyekan,Tahoma,sans-serif}
.portal-drawer-content form>table{width:100%;max-width:100%}
.portal-drawer-content form td{padding:7px 6px!important}
.portal-drawer-content input:not([type="checkbox"]):not([type="radio"]):not([type="button"]):not([type="submit"]):not([type="reset"]):not([type="hidden"]):not([type="image"]),.portal-drawer-content select,.portal-drawer-content textarea{box-sizing:border-box;max-width:100%;min-height:36px;border:1px solid #c9d6e1!important;border-radius:7px;background:#fff;color:#263b53;padding:6px 10px;font-family:wyekan,Tahoma,sans-serif}
.portal-drawer-content select[multiple]{min-height:120px}
.portal-drawer-content input[type="button"],.portal-drawer-content input[type="submit"],.portal-drawer-content input[type="reset"],.portal-drawer-content .ButtonStyle{height:auto;min-height:36px;border:1px solid #146b70;background:#146b70;color:#fff;border-radius:8px;padding:6px 14px;margin:4px;cursor:pointer}
.portal-drawer-content input[type="reset"]{background:#fff;color:#40556c;border-color:#d7e0e8}
.portal-drawer input:focus-visible,.portal-drawer select:focus-visible,.portal-drawer textarea:focus-visible,.portal-drawer button:focus-visible{outline:2px solid #7ac8cc;outline-offset:2px}
@keyframes portal-drawer-enter{from{translate:100% 0}to{translate:0 0}}
@media(prefers-reduced-motion:reduce){.portal-drawer{animation:none}}
@media(max-width:600px){.portal-drawer .portal-drawer-scroll{padding:10px}.portal-drawer-content form{padding:10px}}

@media(max-width:600px){.portal-drawer{--portal-drawer-width:100vw}}

/* Dense operational forms: retain useful legacy dimensions, remove excess spacing. */
.portal-drawer .portal-drawer-bar{padding:7px 12px;gap:8px;flex-wrap:wrap}
.portal-drawer .portal-drawer-scroll{padding:8px}
.portal-drawer-content form{padding:6px;border-radius:8px}
.portal-drawer-content form:empty{padding:0;border:0}
.portal-drawer-content form td{padding:2px 3px!important}
.portal-drawer-content form table{border-spacing:2px}
.portal-drawer-content fieldset{margin:2px!important;padding:3px!important}
.portal-drawer-content legend{font-size:13px;margin-bottom:4px}
.portal-drawer-content input:not([type="checkbox"]):not([type="radio"]):not([type="button"]):not([type="submit"]):not([type="reset"]):not([type="hidden"]):not([type="image"]),.portal-drawer-content select,.portal-drawer-content textarea{min-height:26px;padding:2px 4px;font-size:12px;line-height:1.4}
.portal-drawer-content .portal-docked-action{display:none!important}
.portal-drawer-actions{display:flex;align-items:center;justify-content:flex-end;flex:1;flex-wrap:wrap;gap:6px}
.portal-drawer .portal-action{border:1px solid #146b70;background:#146b70;color:#fff;border-radius:7px;padding:5px 12px;min-height:30px;font:12px/1.5 wyekan,Tahoma,sans-serif;cursor:pointer}
.portal-drawer .portal-action:disabled{opacity:.45;cursor:default}
.portal-drawer.portal-centered-modal{animation:none;border:1px solid #dce5eb;border-radius:14px;box-shadow:0 18px 60px #172c4340}
.portal-centered-modal .portal-drawer-scroll{flex:1 1 auto;padding:12px}
.portal-centered-modal #frm_Message_Popup{padding:12px}
.portal-centered-modal #frm_Message_Popup #Grid{float:none!important;width:100%}
.portal-message-summary{margin:0 0 12px;line-height:1.9;text-align:start}
.portal-scan-bar{display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;flex:0 0 auto;padding:8px 12px;background:#edf7f6;border-bottom:1px solid #cee3e0;direction:rtl;color:#245d62}
.portal-scan-bar label{display:flex;align-items:center;gap:6px;margin:0}
.portal-scan-bar input[type=text]{box-sizing:border-box;width:260px!important;max-width:100%;height:34px;padding:3px 10px;border:1px solid #9fc7c3;border-radius:7px;background:#fff;font:18px wyekan,Tahoma,sans-serif;direction:ltr}
/* The waybill header previously floated date labels away from their controls. */
.portal-drawer #frm_Cons{border:0;padding:0;background:transparent}
.portal-drawer #frm_Cons>div>table{width:100%;border-spacing:2px}
.portal-drawer #frm_Cons td:has(>div>div>#fld_Pickup_Date)>div:not(.cons-schedule){display:flex;align-items:center;gap:5px;float:none!important;white-space:nowrap}
.portal-drawer #frm_Cons td:has(>div>div>#fld_Pickup_Date)>div:not(.cons-schedule)>div{float:none!important;width:auto!important}
.portal-drawer #frm_Cons #fld_Pickup_Date,.portal-drawer #frm_Cons #fld_Sector_Date{width:100px!important}
.portal-drawer #frm_Cons #fld_Hour,.portal-drawer #frm_Cons #fld_Minute,.portal-drawer #frm_MultiStatus #fld_Hour,.portal-drawer #frm_MultiStatus #fld_Minute{width:30px!important;padding:2px!important}
.portal-drawer #frm_Cons #fld_Delivery_Time_Window{width:125px!important}
.portal-drawer #frm_MultiStatus input:not([type=checkbox]):not([type=radio]):not([type=hidden]):not([type=button]),.portal-drawer #frm_MultiStatus select{font-size:14px!important;min-height:28px;height:28px;padding:2px 4px}
.portal-drawer #frm_MultiStatus #fld_Note{height:50px!important}
.portal-drawer #frm_MultiStatus #CNLIST_DATA,.portal-drawer #frm_MultiStatus #CNLIST_SUCCESS,.portal-drawer #frm_MultiStatus #CNLIST_PROBLEM{height:300px!important;font-size:20px!important;line-height:25px!important;border:1px solid #ccd9e1!important;border-radius:6px;overflow:auto!important}
.portal-drawer #frm_MultiStatus div:has(>#CNLIST_DATA),.portal-drawer #frm_MultiStatus div:has(>#CNLIST_SUCCESS),.portal-drawer #frm_MultiStatus div:has(>#CNLIST_PROBLEM){height:auto!important}
.portal-drawer .portal-after-save{width:auto!important;max-width:220px;min-height:30px;padding:3px 8px;border:1px solid #c9d6e1;border-radius:7px;background:white;color:#40556c;font:12px wyekan,Tahoma,sans-serif}

/* Report filters need more breathing room than dense operational forms. */
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData):has(>table){padding:20px;border-radius:12px;line-height:1.8}
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData)>table>tbody>tr>td{padding:0!important}
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData) fieldset{margin:0!important;padding:8px!important;min-width:0}
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData) legend{margin-bottom:16px;padding-inline:4px;line-height:1.8}
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData) fieldset td{padding:8px 10px!important;vertical-align:middle}
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData):has(>table) input:not([type=hidden]):not([type=radio]):not([type=checkbox]):not([type=button]):not([type=submit]):not([type=reset]),
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData):has(>table) select,
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData):has(>table) textarea{min-height:34px;padding:5px 8px}
.portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData) input:is([type=radio],[type=checkbox]){margin:6px 8px;vertical-align:middle}
@media(max-width:600px){
  .portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData):has(>table){padding:12px}
  .portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData) fieldset{padding:4px!important}
  .portal-drawer-content form:is(#frm_Report, #frm_FetchTPGData) fieldset td{padding:7px 6px!important}
}

/* Legacy .PopUPStyle div floats must not arrange a grid's structural sections. */
.portal-drawer-content .flexigrid{float:none!important;min-width:0;max-width:100%;box-sizing:border-box}
.portal-drawer-content .flexigrid>div:is(.mDiv,.tDiv,.hDiv,.bDiv,.sDiv,.pDiv){float:none!important;clear:both;box-sizing:border-box;width:100%}
.portal-drawer-content .flexigrid :is(.hDivBox,.tDiv2,.sDiv2,.pDiv2){float:none!important}
.portal-drawer-content .flexigrid :is(.hDiv,.bDiv) table{border-spacing:0!important;margin:0!important}
.portal-drawer-content .flexigrid .hDiv th,.portal-drawer-content .flexigrid .bDiv td{padding:0!important}
.portal-drawer-content .flexigrid .hDiv th>div,.portal-drawer-content .flexigrid .bDiv td>div{float:none!important;box-sizing:content-box;padding:8px 6px!important;line-height:1.7}

/* The waybill editor contains a 1080px table; never squeeze it into its old 750px launcher width. */
.portal-drawer #frm_Cons>div:has(>table){float:none!important;width:100%;min-width:1080px}
.portal-drawer #frm_Cons>div>table{min-width:1080px}
.portal-drawer:has(#frm_Cons) .portal-drawer-scroll{direction:rtl}


/* Waybill details have their own layout; legacy table widths and floats do not size it. */
.portal-drawer #frm_Cons .cons-header-table,
.portal-drawer #frm_Cons .cons-header-table>tbody{display:block;width:100%;box-sizing:border-box}
.portal-drawer #frm_Cons .cons-header-table>tbody>tr{display:block}
.portal-drawer #frm_Cons .cons-header-table>tbody>tr>td{display:block;width:auto!important;min-width:0;box-sizing:border-box}
.portal-drawer #frm_Cons .cons-header-table>tbody>.cons-header-main{display:flex;flex-direction:column;gap:10px;align-items:stretch}
.portal-drawer #frm_Cons .cons-header-main>td{width:100%!important;text-align:right!important}
.portal-drawer #frm_Cons .cons-header-main>.cons-header-agents{padding:2px 0!important}
.portal-drawer #frm_Cons .cons-header-agents table{width:100%;table-layout:auto}
.portal-drawer #frm_Cons .cons-header-agents td{white-space:normal;vertical-align:middle;padding:2px 4px!important}
.portal-drawer #frm_Cons .cons-header-agents td:nth-child(odd){width:1%;white-space:nowrap}
.portal-drawer #frm_Cons .cons-header-agents td:nth-child(even){width:49%;overflow-wrap:break-word}
.portal-drawer #frm_Cons .cons-header-table div{float:none!important;box-sizing:border-box}
.portal-drawer #frm_Cons .cons-header-table>tbody>.cons-header-bottom{display:flex;flex-direction:column;gap:10px;align-items:stretch}
.portal-drawer #frm_Cons .cons-header-bottom>td{width:100%!important}
.portal-drawer #frm_Cons .cons-header-carriers>div:has(input){display:flex;align-items:center;gap:6px}
.portal-drawer #frm_Cons .cons-header-carriers input{flex:1;min-width:0;width:100%!important}
.portal-drawer #frm_Cons .cons-header-carriers select{flex:0 0 110px;width:110px!important}
.portal-drawer #frm_Cons .cons-header-notes>div{width:100%!important;height:auto!important}
.portal-drawer #frm_Cons .cons-header-notes textarea{display:block;width:100%!important;max-width:100%;min-height:45px;margin-top:6px;resize:vertical}
.portal-drawer #frm_Cons #ConsignmentNo{width:100%!important}

/* Customer contact and pricing sections need more room than the 850px launcher. */
.portal-drawer #frm_Customer{display:flow-root}
.portal-drawer #frm_Customer #CustomerForm{width:100%;min-width:1120px;table-layout:auto}
.portal-drawer #frm_Customer #CustomerForm>tbody>tr>td{padding:4px 8px!important}
.portal-drawer #frm_Customer #CustomerForm>tbody>tr>td:first-child:not([colspan]){width:40%}
.portal-drawer #frm_Customer #CustomerForm>tbody>tr>td:nth-child(2){width:60%}
.portal-drawer #frm_Customer fieldset{min-width:0;height:auto!important}
.portal-drawer:has(#frm_Customer) .portal-drawer-scroll{direction:rtl}

/* Content search and selected contents stack instead of widening the service column. */
.portal-drawer #frm_Cons .cons-content-fields{white-space:normal}
.portal-drawer #frm_Cons .cons-content-fields>#Contain,
.portal-drawer #frm_Cons .cons-content-fields>#fld_Contain{display:block;float:none!important;clear:both;width:190px!important;max-width:100%;margin:0 0 5px}

/* Manifest scan queues stay side by side, independent of legacy popup floats. */
.portal-drawer #frm_MultiStatus>table{min-width:1050px}
.portal-drawer #frm_MultiStatus #CNLIST_CONTENT{display:grid;grid-template-columns:repeat(3,minmax(200px,1fr));gap:10px;min-width:620px;vertical-align:top}
.portal-drawer #frm_MultiStatus #CNLIST_CONTENT>div{float:none!important;width:auto!important;height:auto!important;min-width:0;padding:0!important}
.portal-drawer #frm_MultiStatus #CNLIST_CONTENT>div>div{float:none!important}
.portal-drawer #frm_MultiStatus #CNLIST_CONTENT :is(#CNLIST_DATA,#CNLIST_SUCCESS,#CNLIST_PROBLEM){width:100%!important;margin:4px 0 0!important;box-sizing:border-box}
.portal-drawer:has(#frm_MultiStatus) .portal-drawer-scroll{direction:rtl}
