/* Orders workspace — visual contract based on the approved September 2026 reference. */
:root{
  --orders-navy:#122238;
  --orders-navy-2:#172d43;
  --orders-blue:#087cf0;
  --orders-border:#dce4ed;
  --orders-soft:#f5f7fb;
  --orders-text:#17263a;
  --orders-muted:#748296;
}
.app-shell,.modal-layer{font-family:Tahoma,"Segoe UI",Arial,sans-serif!important;letter-spacing:0!important}

/* Application chrome */
.app-shell .sidebar{
  width:158px!important;
  background:linear-gradient(180deg,#14283c 0%,#0f2033 100%)!important;
  border:0!important;
  padding:0 7px 8px!important;
  box-shadow:-2px 0 14px rgba(15,34,53,.08)!important;
}
.app-shell .main-area{margin-right:158px!important;background:#f7f9fc!important;min-width:0!important}
.app-shell .brand{height:42px!important;min-height:42px!important;padding:0 5px!important;border-bottom:1px solid rgba(255,255,255,.08)!important;gap:6px!important}
.app-shell .brand .brand-mark{width:25px!important;height:25px!important;min-width:25px!important;border-radius:6px!important;background:#eef5ff!important;color:#15314b!important;font-size:9px!important}
.app-shell .brand>div:last-child{min-width:0!important}
.app-shell .brand strong{font:700 11px/1.15 Tahoma,"Segoe UI",sans-serif!important;color:#fff!important;direction:ltr!important;white-space:nowrap!important}
.app-shell .brand span{display:none!important}
.app-shell .nav-list{padding:6px 0!important;gap:2px!important;margin-top:0!important;overflow-y:auto!important;scrollbar-width:thin!important}
.app-shell .nav-item{position:relative!important;min-height:35px!important;height:35px!important;padding:0 8px!important;border-radius:5px!important;color:#d9e2eb!important;font-size:10px!important;font-weight:700!important;gap:6px!important}
.app-shell .nav-item .nav-icon{width:17px!important;font-size:14px!important;color:#c5d1de!important}
.app-shell .nav-item:has(+:is(.sales-subnav,.module-subnav))::after{content:"‹"!important;margin-right:auto!important;color:#91a7ba!important;font-size:12px!important;transition:transform .15s ease!important}
.app-shell .nav-item.expanded:has(+:is(.sales-subnav,.module-subnav))::after{transform:rotate(-90deg)!important;color:#fff!important}
.app-shell .nav-item:hover{background:rgba(255,255,255,.07)!important;color:#fff!important}
.app-shell .nav-item.active{background:#0969c5!important;color:#fff!important;box-shadow:0 4px 12px rgba(0,91,183,.23)!important}
.app-shell .nav-item.active .nav-icon{color:#fff!important}
.app-shell :is(.sales-subnav,.module-subnav){margin:0 6px 3px!important;padding:2px 0 2px 8px!important;border-right:1px solid rgba(146,177,204,.18)!important}
.app-shell .nav-list>:is(.sales-subnav,.module-subnav){display:none!important}
.app-shell .nav-list>.nav-item.expanded+:is(.sales-subnav,.module-subnav){display:block!important}
.app-shell :is(.sales-subnav,.module-subnav) .subnav-item{min-height:25px!important;padding:3px 7px!important;border-radius:4px!important;color:#aebdca!important;font-size:8.5px!important}
.app-shell :is(.sales-subnav,.module-subnav) .subnav-item.active{background:rgba(8,124,240,.2)!important;color:#fff!important}
.app-shell .sidebar-footer{min-height:43px!important;padding:5px 3px!important;gap:5px!important;border-top:1px solid rgba(255,255,255,.09)!important;color:#fff!important}
.app-shell .sidebar-footer .avatar{width:25px!important;height:25px!important;min-width:25px!important;font-size:8px!important}.app-shell .sidebar-footer strong{font-size:8px!important}.app-shell .sidebar-footer span{font-size:7px!important}.app-shell .sidebar-footer .icon-button{width:24px!important;height:24px!important;font-size:11px!important}
.app-shell .sidebar-footer span{color:#9fb0c3!important}

.app-shell .topbar{
  position:sticky!important;top:0!important;z-index:50!important;
  height:42px!important;min-height:42px!important;padding:0 11px!important;
  display:grid!important;grid-template-columns:minmax(120px,1fr) minmax(360px,630px) minmax(205px,1fr)!important;
  align-items:center!important;gap:18px!important;background:#fff!important;border-bottom:1px solid #e6ebf1!important;
  box-shadow:0 1px 3px rgba(19,38,58,.035)!important;
}
.app-shell .topbar-context{display:flex!important;align-items:center!important;gap:10px!important;min-width:0!important}
.app-shell .topbar-menu-button{width:27px!important;height:27px!important;border:0!important;background:transparent!important;color:#20334a!important;font-size:16px!important;cursor:pointer!important}
.app-shell .topbar .crumbs{display:none!important}
.app-shell .crumbs strong{color:#3d4c5e!important}
.app-shell .topbar>.global-search{position:relative!important;display:flex!important;align-items:center!important;width:100%!important;height:29px!important;margin:0!important}
.app-shell .topbar>.global-search span{position:absolute!important;right:12px!important;z-index:1!important;color:#657487!important;font-size:18px!important}
.app-shell .topbar>.global-search input{width:100%!important;height:29px!important;padding:0 34px 0 10px!important;border:1px solid #e1e7ee!important;border-radius:5px!important;background:#f8fafc!important;color:#24374d!important;font-size:9px!important;box-shadow:none!important}
.app-shell .top-actions{display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:6px!important;min-width:0!important;direction:ltr!important}
.app-shell .top-actions>.icon-button{width:27px!important;height:27px!important;min-height:27px!important;border:0!important;background:transparent!important;color:#33465d!important;font-size:13px!important}
.app-shell .topbar-user{display:flex!important;align-items:center!important;gap:5px!important;min-width:98px!important;direction:ltr!important;padding-inline-end:6px!important;border-inline-end:1px solid #edf1f5!important}
.app-shell .topbar-user .avatar{width:25px!important;height:25px!important;min-width:25px!important;border-radius:50%!important;background:#e7eef7!important;color:#34465c!important;font-size:8px!important}
.app-shell .topbar-user>div:last-child{display:flex!important;flex-direction:column!important;align-items:flex-start!important;min-width:0!important;direction:rtl!important}
.app-shell .topbar-user strong{font-size:8px!important;color:#1e2e42!important;white-space:nowrap!important}
.app-shell .topbar-user span{font-size:6.5px!important;color:#7b899a!important;white-space:nowrap!important}
.app-shell .top-actions .connection{display:none!important}

/* Orders page */
.app-shell #orders-view{padding:4px 10px 10px!important;color:var(--orders-text)!important}
.app-shell #orders-view .orders-reference-heading{min-height:31px!important;height:31px!important;margin:0!important;padding:0 2px 3px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;gap:10px!important;background:transparent!important;border:0!important}
.app-shell #orders-view .orders-reference-heading h1{margin:0!important;color:var(--orders-text)!important;font-size:17px!important;line-height:1!important;font-weight:800!important}
.app-shell #orders-view .orders-reference-heading p{display:block!important;margin:2px 0 0!important;color:var(--orders-muted)!important;font-size:7px!important}
.app-shell #orders-view .orders-document-navigation{display:flex!important;align-items:center!important;width:100%!important;height:29px!important;min-height:29px!important;margin:0 0 3px!important;padding:2px!important;border:1px solid #e7ecf2!important;border-radius:5px!important;background:#fff!important;box-shadow:none!important;overflow-x:auto!important}
.app-shell #orders-view .orders-document-navigation>button{height:23px!important;min-height:23px!important;min-width:108px!important;padding:0 10px!important;border:0!important;border-radius:4px!important;background:transparent!important;color:#647487!important;font-size:8px!important;font-weight:750!important}
.app-shell #orders-view .orders-document-navigation>button.active{background:#eaf4ff!important;color:#0874df!important;font-weight:850!important;box-shadow:inset 0 -2px #087cf0!important}

.app-shell #orders-view .orders-status-toolbar{min-height:39px!important;height:39px!important;padding:3px 0!important;display:flex!important;align-items:center!important;gap:6px!important;border-top:0!important}
.app-shell #orders-view .orders-status-filter{display:flex!important;align-items:center!important;gap:8px!important;min-width:0!important;overflow-x:auto!important;scrollbar-width:thin!important}
.app-shell #orders-view .orders-status-filter button{flex:0 0 auto!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:5px!important;height:29px!important;min-width:86px!important;padding:0 9px!important;border:1px solid transparent!important;border-radius:5px!important;background:#f1f4f8!important;color:#344457!important;font-size:8px!important;font-weight:700!important;box-shadow:none!important}
.app-shell #orders-view .orders-status-filter button i{width:8px!important;height:8px!important;border-radius:50%!important;background:#7f8b98!important}
.app-shell #orders-view .orders-status-filter button.active{border-color:#77b7f8!important;background:#fff!important;color:#076fd4!important;box-shadow:0 0 0 1px rgba(8,124,240,.07)!important}
.app-shell #orders-view .orders-status-filter button[data-order-status="DRAFT"] i{background:#1686ef!important}
.app-shell #orders-view .orders-status-filter button[data-order-status="CONFIRMED"] i{background:#11ad55!important}
.app-shell #orders-view .orders-status-filter button[data-order-status="IN_CUTTING"] i{background:#f4a317!important}
.app-shell #orders-view .orders-status-filter button[data-order-status="CANCELLED"] i{background:#ee3f4d!important}
.app-shell #orders-view .orders-status-filter button[data-sales-order-screen="completed-orders"] i{background:#11ad55!important}
.app-shell #orders-view .orders-new-document-menu{position:relative!important;flex:0 0 auto!important;margin-inline-start:auto!important;z-index:15!important}
.app-shell #orders-view .orders-new-document-menu>summary{display:flex!important;align-items:center!important;justify-content:center!important;gap:6px!important;width:112px!important;height:31px!important;padding:0 9px!important;border-radius:5px!important;background:var(--orders-blue)!important;color:#fff!important;font-size:8.5px!important;font-weight:800!important;cursor:pointer!important;list-style:none!important;box-shadow:none!important}
.app-shell #orders-view .orders-new-document-menu>summary::-webkit-details-marker{display:none!important}
.app-shell #orders-view .orders-new-document-menu>summary b{margin-inline-start:auto!important;font-size:10px!important}
.app-shell #orders-view .orders-new-document-menu>div{position:absolute!important;top:calc(100% + 6px)!important;left:0!important;width:245px!important;padding:5px!important;border:1px solid #d6e0ea!important;border-radius:8px!important;background:#fff!important;box-shadow:0 14px 34px rgba(19,40,61,.2)!important}
.app-shell #orders-view .orders-new-document-menu>div>button{display:flex!important;align-items:center!important;gap:10px!important;width:100%!important;min-height:48px!important;padding:7px 9px!important;border:0!important;border-radius:6px!important;background:#fff!important;color:#24384e!important;text-align:right!important;cursor:pointer!important}
.app-shell #orders-view .orders-new-document-menu>div>button:hover{background:#eef6ff!important}
.app-shell #orders-view .orders-new-document-menu>div>button>span:first-child{display:grid!important;place-items:center!important;width:30px!important;height:30px!important;border-radius:6px!important;background:#e9f3ff!important;color:#0874df!important;font-size:15px!important}
.app-shell #orders-view .orders-new-document-menu>div>button>span:last-child{display:flex!important;flex-direction:column!important;align-items:flex-start!important;gap:2px!important}
.app-shell #orders-view .orders-new-document-menu strong{font-size:10px!important}.app-shell #orders-view .orders-new-document-menu small{color:#8090a2!important;font-size:8px!important}

.app-shell #orders-view .orders-card{margin:0!important;border:1px solid #e7ecf2!important;border-radius:8px!important;background:#fff!important;box-shadow:0 2px 8px rgba(20,40,60,.035)!important;overflow:hidden!important}
.app-shell #orders-view .orders-card>.card-toolbar{min-height:40px!important;height:40px!important;padding:4px 7px!important;display:flex!important;align-items:center!important;gap:6px!important;background:#fff!important;border-bottom:1px solid #edf1f5!important;overflow:visible!important}
.app-shell #orders-view .orders-register-filter{display:grid!important;grid-template-columns:minmax(230px,2.2fr) minmax(180px,1.25fr) minmax(135px,.8fr) minmax(135px,.8fr) auto auto!important;align-items:end!important;gap:8px!important;width:100%!important;margin:0!important;padding:0!important;background:transparent!important;border:0!important}
.app-shell #orders-view .orders-register-filter label{display:flex!important;flex-direction:row!important;align-items:center!important;gap:6px!important;min-width:0!important;margin:0!important;color:#68778a!important;font-size:9px!important;white-space:nowrap!important}
.app-shell #orders-view .orders-register-filter label>span:not(.smart-select-arrow){flex:0 0 auto!important}
.app-shell #orders-view .orders-register-filter :is(input,select,.smart-select-trigger,.button){height:30px!important;min-height:30px!important;margin:0!important;border:1px solid #e0e6ed!important;border-radius:5px!important;background:#fff!important;font-size:8.5px!important;box-shadow:none!important}
.app-shell #orders-view .orders-register-filter input,.app-shell #orders-view .orders-register-filter select{min-width:0!important;width:100%!important}
.app-shell #orders-view .orders-register-filter .orders-advanced-search{position:relative!important}
.app-shell #orders-view .orders-register-filter .orders-advanced-search>span{position:absolute!important;right:12px!important;z-index:2!important;font-size:16px!important}
.app-shell #orders-view .orders-register-filter .orders-advanced-search input{padding-right:38px!important}
.app-shell #orders-view .orders-register-filter .orders-customer-filter>span{display:none!important}
.app-shell #orders-view .orders-register-filter .orders-more-filters{padding:0 12px!important;color:#46586e!important;background:#f8fafc!important}
.app-shell #orders-view .orders-register-filter .orders-clear-filter{padding:0 10px!important;background:#fff!important;color:#718094!important}
.app-shell #orders-view .orders-result-label{flex:0 0 auto!important;color:#7a8797!important;font-size:9px!important;white-space:nowrap!important}

.app-shell #orders-view .orders-card>.table-wrap{height:calc(100vh - 218px)!important;min-height:420px!important;overflow:auto!important;background:#fff!important}
.app-shell #orders-view .sales-orders-register-table{width:100%!important;min-width:1120px!important;table-layout:fixed!important;border-collapse:separate!important;border-spacing:0!important}
.app-shell #orders-view .sales-orders-register-table col.order-no-col{width:9%!important}
.app-shell #orders-view .sales-orders-register-table col.order-date-col{width:12%!important}
.app-shell #orders-view .sales-orders-register-table col.order-party-col{width:20%!important}
.app-shell #orders-view .sales-orders-register-table col.order-phone-col{width:10%!important}
.app-shell #orders-view .sales-orders-register-table col.order-lines-col{width:6%!important}
.app-shell #orders-view .sales-orders-register-table col.order-total-col{width:10%!important}
.app-shell #orders-view .sales-orders-register-table col.order-status-col{width:9%!important}
.app-shell #orders-view .sales-orders-register-table col.order-creator-col{width:10%!important}
.app-shell #orders-view .sales-orders-register-table col.order-actions-col{width:14%!important}
.app-shell #orders-view .sales-orders-register-table thead{position:sticky!important;top:0!important;z-index:3!important}
.app-shell #orders-view .sales-orders-register-table th{height:35px!important;padding:0 8px!important;border:0!important;border-bottom:1px solid #e4eaf0!important;background:#f6f8fb!important;color:#536276!important;font-size:9px!important;font-weight:800!important;text-align:right!important;white-space:nowrap!important}
.app-shell #orders-view .sales-orders-register-table td{height:36px!important;padding:4px 8px!important;border:0!important;border-bottom:1px solid #edf1f4!important;background:#fff!important;color:#34455a!important;font-size:9px!important;vertical-align:middle!important}
.app-shell #orders-view .sales-orders-register-table :is(th,td):last-child{border-inline-start:0!important}
.app-shell #orders-view .orders-column-filter-row th{height:30px!important;padding:2px 4px!important;background:#f3f6f9!important;border-bottom:1px solid #e0e6ec!important}
.app-shell #orders-view .orders-column-filter-row :is(input,select,button){width:100%!important;height:26px!important;min-height:26px!important;margin:0!important;padding:2px 6px!important;border:1px solid #c8d5e1!important;border-radius:5px!important;background:#fff!important;color:#3f536a!important;font-size:8.5px!important;outline:none!important}
.app-shell #orders-view .orders-column-filter-row :is(input,select):focus{border-color:#3990e4!important;box-shadow:0 0 0 2px rgba(8,124,240,.08)!important}
.app-shell #orders-view .orders-column-filter-row button{color:#a33844!important;cursor:pointer!important}
.app-shell #orders-view .sales-orders-register-table tbody tr:nth-child(even) td{background:#fbfcfe!important}
.app-shell #orders-view .sales-orders-register-table tbody tr:hover td{background:#f3f8fe!important}
.app-shell #orders-view .sales-orders-register-table .order-number{color:#0874df!important;font-weight:800!important;direction:ltr!important}
.app-shell #orders-view .order-parties-cell{gap:1px!important;line-height:1.25!important}
.app-shell #orders-view .order-parties-cell strong{color:#24364a!important;font-size:10.5px!important;font-weight:750!important}
.app-shell #orders-view .order-parties-cell small{color:#8a96a5!important;font-size:8px!important}
.app-shell #orders-view :is(.order-register-date,.order-register-phone,.order-register-lines,.order-register-total,.order-register-creator){color:#4c5e72!important;font-size:10px!important;font-weight:600!important;white-space:nowrap!important}
.app-shell #orders-view .order-register-phone,.app-shell #orders-view .order-register-total{direction:ltr!important;text-align:right!important}
.app-shell #orders-view .status{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:72px!important;height:25px!important;padding:0 9px!important;border:0!important;border-radius:6px!important;font-size:9px!important;font-weight:800!important;white-space:nowrap!important}
.app-shell #orders-view .status.draft{background:#e8f2ff!important;color:#1974d2!important}
.app-shell #orders-view .status.confirmed{background:#e5f8ed!important;color:#189452!important}
.app-shell #orders-view .status.in_cutting{background:#fff2d9!important;color:#d88509!important}
.app-shell #orders-view .status.cancelled{background:#ffe9eb!important;color:#d83544!important}
.app-shell #orders-view .status.pending_approval{background:#f1eaff!important;color:#7b45cb!important}
.app-shell #orders-view .status.approval_rejected{background:#ffe9eb!important;color:#d83544!important}
.app-shell #orders-view .status.completed{background:#e3f8ec!important;color:#168c4d!important}
.app-shell #orders-view .document-action-cell{display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:3px!important;width:auto!important;max-width:100%!important;margin:0!important;overflow-x:auto!important;scrollbar-width:thin!important}
.app-shell #orders-view .document-action-cell>.document-action-cell{display:contents!important}
.app-shell #orders-view .document-action-cell :is(.button,.small-action,.doc-action){flex:0 0 auto!important;height:25px!important;min-height:25px!important;padding:0 7px!important;border-radius:5px!important;font-size:8px!important;line-height:1!important}
.app-shell #orders-view .document-action-cell .details{border-color:#b7d5f3!important;background:#eff7ff!important;color:#0874df!important}
.app-shell #orders-view .order-row-actions{position:relative!important;display:inline-block!important;z-index:2!important}
.app-shell #orders-view .order-row-actions[open]{z-index:20!important}
.app-shell #orders-view .order-row-actions>summary{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;width:74px!important;height:27px!important;border:1px solid #aed0f2!important;border-radius:5px!important;background:#eef7ff!important;color:#0874df!important;font-size:9px!important;font-weight:800!important;cursor:pointer!important;list-style:none!important}
.app-shell #orders-view .order-row-actions>summary::-webkit-details-marker{display:none!important}
.app-shell #orders-view .order-row-actions>.document-action-cell{position:absolute!important;top:calc(100% + 4px)!important;left:0!important;display:flex!important;flex-direction:column!important;align-items:stretch!important;width:178px!important;padding:5px!important;border:1px solid #d4dfe9!important;border-radius:7px!important;background:#fff!important;box-shadow:0 12px 28px rgba(19,40,61,.2)!important;overflow:visible!important}
.app-shell #orders-view .order-row-actions>.document-action-cell :is(.button,.small-action,.doc-action){width:100%!important;height:29px!important;min-height:29px!important;justify-content:flex-start!important;padding:0 8px!important;border:0!important;border-radius:5px!important;background:#fff!important;color:#344a60!important;font-size:8.5px!important;text-align:right!important}
.app-shell #orders-view .order-row-actions>.document-action-cell :is(.button,.small-action,.doc-action):hover{background:#eef6ff!important;color:#0874df!important}
.app-shell #orders-view .unified-filter-pager{min-height:49px!important;padding:7px 12px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;gap:12px!important;border-top:1px solid #e7edf3!important;background:#fff!important;color:#718094!important;font-size:9px!important}
.app-shell #orders-view .unified-filter-pager.hidden{display:none!important}
.app-shell #orders-view .unified-filter-pager>div{display:flex!important;align-items:center!important;gap:5px!important}
.app-shell #orders-view .unified-filter-pager .small-action{height:30px!important;min-height:30px!important;padding:0 10px!important;border:1px solid #dce5ee!important;border-radius:6px!important;background:#fff!important;color:#40536a!important;font-size:9px!important}
.app-shell #orders-view #orders-page-label{display:inline-flex!important;align-items:center!important;height:30px!important;padding:0 10px!important;border-radius:6px!important;background:var(--orders-blue)!important;color:#fff!important;font-weight:800!important}

/* Sales dialogs inherit the same dense, clean visual language without changing their behavior. */
.modal-layer:has(:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal)){
  background:rgba(9,25,42,.58)!important;backdrop-filter:blur(1.5px)!important;
}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-card{
  max-width:min(1180px,calc(100vw - 48px))!important;max-height:calc(100vh - 34px)!important;border:1px solid #dce5ed!important;border-radius:10px!important;background:#fff!important;box-shadow:0 24px 70px rgba(8,25,43,.3)!important;overflow:hidden!important;
}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) .modal-header{
  min-height:52px!important;padding:8px 14px!important;border-bottom:1px solid #e5ebf1!important;background:#fff!important;
}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) .modal-header h2{font-size:16px!important;color:#1e3045!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) .modal-header p{font-size:9px!important;color:#7a899b!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) .modal-body{padding:12px 14px!important;background:#fbfcfe!important;overflow:auto!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) :is(input,select,textarea,.smart-select-trigger){border:1px solid #dbe4ed!important;border-radius:7px!important;background:#fff!important;box-shadow:none!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) :is(input,select,.smart-select-trigger){height:36px!important;min-height:36px!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) table th{height:36px!important;padding:5px 7px!important;background:#f2f6fa!important;color:#4b5e73!important;font-size:9px!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) table td{min-height:36px!important;padding:5px 7px!important;border-color:#e4eaf0!important;font-size:9px!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) .modal-actions{min-height:52px!important;padding:8px 14px!important;border-top:1px solid #e4eaf0!important;background:#fff!important}
.modal-layer :is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal) .modal-actions .button{height:35px!important;min-height:35px!important;padding:0 13px!important;border-radius:7px!important;font-size:10px!important}

@media(max-width:1180px){
  .app-shell .sidebar{width:148px!important}.app-shell .main-area{margin-right:148px!important}
  .app-shell .topbar{grid-template-columns:minmax(160px,.7fr) minmax(300px,1.4fr) minmax(210px,.8fr)!important;gap:10px!important;padding-inline:10px!important}
  .app-shell #orders-view{padding-inline:10px!important}
  .app-shell #orders-view .orders-register-filter{grid-template-columns:minmax(220px,1.8fr) minmax(170px,1.1fr) 135px 135px auto!important}
  .app-shell #orders-view .orders-clear-filter{display:none!important}
}

/* Correct layer-scoped dialog selectors (the dialog id belongs to the overlay). */
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer{
  background:rgba(9,25,42,.58)!important;backdrop-filter:blur(1.5px)!important;
}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer .modal-card{
  max-width:min(1180px,calc(100vw - 48px))!important;max-height:calc(100vh - 34px)!important;border:1px solid #dce5ed!important;border-radius:10px!important;background:#fff!important;box-shadow:0 24px 70px rgba(8,25,43,.3)!important;overflow:auto!important;
}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer .modal-header{
  position:sticky!important;top:0!important;z-index:4!important;min-height:52px!important;padding:8px 14px!important;border-bottom:1px solid #e5ebf1!important;background:#fff!important;
}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer .modal-header h2{font-size:16px!important;color:#1e3045!important}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer .modal-header p{font-size:9px!important;color:#7a899b!important}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer :is(input,select,textarea,.smart-select-trigger){border:1px solid #dbe4ed!important;border-radius:7px!important;background:#fff!important;box-shadow:none!important}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer :is(input,select,.smart-select-trigger){height:36px!important;min-height:36px!important}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer table th{height:36px!important;padding:5px 7px!important;background:#f2f6fa!important;color:#4b5e73!important;font-size:9px!important}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer table td{min-height:36px!important;padding:5px 7px!important;border-color:#e4eaf0!important;font-size:9px!important}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer .modal-actions{
  position:sticky!important;bottom:0!important;z-index:4!important;min-height:52px!important;padding:8px 14px!important;border-top:1px solid #e4eaf0!important;background:#fff!important;
}
:is(#cutting-create-modal,#cutting-preview-modal,#preparation-modal,#delivery-modal,#delivery-detail-modal,#customer-modal,#customer-request-modal,#invoice-modal,#sales-invoice-editor-modal,#new-sales-invoice-modal).modal-layer .modal-actions .button{height:35px!important;min-height:35px!important;padding:0 13px!important;border-radius:7px!important;font-size:10px!important}

/* Final compact orders register contract. */
.app-shell .topbar{display:none!important}
.app-shell #orders-view{padding-top:2px!important}
.app-shell #orders-view .orders-card>.card-toolbar{height:31px!important;min-height:31px!important;margin-top:-1px!important;padding:2px 5px!important}
.app-shell #orders-view .orders-register-filter{grid-template-columns:minmax(230px,2.2fr) minmax(180px,1.25fr) minmax(125px,.75fr) minmax(125px,.75fr) auto auto!important;gap:5px!important;align-items:center!important}
.app-shell #orders-view .orders-register-filter :is(input,select,.smart-select-trigger,.button){height:26px!important;min-height:26px!important}
.app-shell #orders-view .orders-register-filter .orders-more-filters{padding-inline:9px!important}
.app-shell #orders-view .orders-register-filter .orders-clear-filter{padding-inline:8px!important}
.app-shell #orders-view .orders-card>.table-wrap{height:calc(100vh - 145px)!important}
