/* ERPPLUS UI Framework R1
   Shared presentation tokens and approved Gate Entry style for Sales Order / Customer Delivery Schedule.
   No transaction logic is contained in this file. */
:root{
  --erpplus-navy:#073654;
  --erpplus-navy-2:#0b1724;
  --erpplus-accent:#ff9917;
  --erpplus-accent-border:#a85d00;
  --erpplus-line:#9aaab8;
  --erpplus-field:#ffffff;
  --erpplus-readonly:#eef1f4;
  --erpplus-panel:#f4f6f8;
  --erpplus-toolbar-1:#6f7b85;
  --erpplus-toolbar-2:#58636d;
}

/* Common reusable classes for upcoming forms */
.erpplus-form{width:min(1120px,calc(100% - 24px));margin:10px auto 70px;font-family:Arial,sans-serif;color:#000}
.erpplus-header{min-height:44px;display:flex;align-items:center;justify-content:space-between;padding:0 12px;background:var(--erpplus-navy);color:#fff;border-bottom:1px solid #ef3340;font-weight:900;font-size:18px}
.erpplus-context{margin-left:auto;color:#ffd21f;font-size:14px;font-weight:900;white-space:nowrap}
.erpplus-fields{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px 12px;padding:10px 12px 12px;background:var(--erpplus-panel);border:1px solid var(--erpplus-line);border-top:0}
.erpplus-toolbar{display:flex;align-items:center;justify-content:flex-end;gap:6px;min-height:46px;padding:6px 8px;background:linear-gradient(var(--erpplus-toolbar-1),var(--erpplus-toolbar-2));border:1px solid #4a5660;box-shadow:0 2px 4px rgba(0,0,0,.28)}
.erpplus-button{height:34px;min-width:84px;padding:0 10px;background:var(--erpplus-accent);color:#000;border:1px solid var(--erpplus-accent-border);border-radius:0;font:700 13px Arial;cursor:pointer}
.erpplus-detail-title{min-height:37px;display:flex;align-items:center;justify-content:space-between;padding:0 10px;background:var(--erpplus-navy);color:#fff;border-bottom:1px solid #ef3340;font:900 16px Arial}

/* Apply approved layout to the two legacy Phase-1 forms without changing their JS logic. */
body #salesOrder.page,body #customerSchedule.page{width:min(1120px,calc(100% - 24px))!important;max-width:1120px!important;margin:10px auto 70px!important;padding:0!important;background:transparent!important;color:#000!important}
body #salesOrder .so-final-head,body #customerSchedule .cds-final-head{min-height:44px!important;height:auto!important;display:flex!important;align-items:center!important;justify-content:space-between!important;padding:0 12px!important;background:var(--erpplus-navy)!important;color:#fff!important;border:1px solid #00aeff!important;border-bottom:1px solid #ef3340!important;font:900 18px Arial!important}
body #salesOrder .so-final-context,body #customerSchedule .cds-final-context{margin-left:auto!important;color:#ffd21f!important;font-size:14px!important;font-weight:900!important;white-space:nowrap!important}
body #salesOrder .ae50-phase1-header,body #salesOrder .form-grid,body #salesOrder .professional-module-form,body #salesOrder .advanced-challan-form,
body #customerSchedule .ae50-phase1-header,body #customerSchedule .form-grid,body #customerSchedule .professional-module-form,body #customerSchedule .advanced-challan-form{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:8px 12px!important;width:100%!important;margin:0 0 10px!important;padding:10px 12px 12px!important;background:var(--erpplus-panel)!important;border:1px solid #00aeff!important;border-top:0!important;border-radius:0!important;box-sizing:border-box!important}
body #salesOrder .field-wrap,body #customerSchedule .field-wrap{min-width:0!important;display:flex!important;flex-direction:column!important;gap:3px!important}
body #salesOrder .field-wrap label,body #customerSchedule .field-wrap label{color:#000!important;font:800 11px/14px Arial!important;margin:0!important}
body #salesOrder .field-wrap input,body #salesOrder .field-wrap select,body #customerSchedule .field-wrap input,body #customerSchedule .field-wrap select{width:100%!important;height:34px!important;min-height:34px!important;background:#fff!important;color:#000!important;-webkit-text-fill-color:#000!important;border:1px solid #aebdca!important;border-radius:0!important;padding:5px 8px!important;font-size:13px!important;box-sizing:border-box!important;opacity:1!important}
body #salesOrder .field-wrap input[readonly],body #salesOrder .field-wrap input:disabled,body #salesOrder .field-wrap select:disabled,
body #customerSchedule .field-wrap input[readonly],body #customerSchedule .field-wrap input:disabled,body #customerSchedule .field-wrap select:disabled{background:var(--erpplus-readonly)!important;color:#000!important;-webkit-text-fill-color:#000!important;opacity:1!important}

body #salesOrder .clean-action-toolbar,body #salesOrder .ae50-phase1-toolbar,body #salesOrder .ae50-final-toolbar,body #salesOrder .ae50-restored-toolbar,
body #customerSchedule .clean-action-toolbar,body #customerSchedule .ae50-phase1-toolbar,body #customerSchedule .ae50-final-toolbar,body #customerSchedule .ae50-restored-toolbar{display:flex!important;align-items:center!important;justify-content:flex-end!important;width:100%!important;min-height:46px!important;height:46px!important;margin:0 0 10px!important;padding:6px 8px!important;background:linear-gradient(var(--erpplus-toolbar-1),var(--erpplus-toolbar-2))!important;color:#fff!important;border:1px solid #4a5660!important;border-radius:0!important;box-shadow:0 2px 4px rgba(0,0,0,.28)!important;box-sizing:border-box!important;overflow:hidden!important}
body #salesOrder .clean-toolbar-title,body #salesOrder .ae50-final-toolbar-title,body #customerSchedule .clean-toolbar-title,body #customerSchedule .ae50-final-toolbar-title{display:none!important}
body #salesOrder .clean-toolbar-buttons,body #salesOrder .ae50-final-toolbar-buttons,body #customerSchedule .clean-toolbar-buttons,body #customerSchedule .ae50-final-toolbar-buttons{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:6px!important;flex-wrap:nowrap!important;width:auto!important;margin-left:auto!important}
body #salesOrder button[data-act],body #customerSchedule button[data-act]{height:34px!important;min-width:84px!important;padding:0 10px!important;background:var(--erpplus-accent)!important;color:#000!important;border:1px solid var(--erpplus-accent-border)!important;border-radius:0!important;font:700 13px Arial!important;cursor:pointer!important;box-shadow:0 1px 2px rgba(0,0,0,.25)!important}

body #salesOrder .advanced-items-panel,body #salesOrder .ae50-phase1-detail,body #customerSchedule .advanced-items-panel,body #customerSchedule .ae50-phase1-detail{width:100%!important;margin:0 0 10px!important;padding:0 10px 10px!important;background:#fff!important;color:#000!important;border:1px solid #00aeff!important;border-radius:0!important;box-sizing:border-box!important;overflow:hidden!important}
body #salesOrder .panel-title,body #customerSchedule .panel-title{min-height:40px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;margin:0 -10px 8px!important;padding:0 10px!important;background:var(--erpplus-navy)!important;color:#fff!important;border-bottom:1px solid #ef3340!important;font:900 16px Arial!important}
body #salesOrder .so-final-row-actions,body #customerSchedule .cds-row-actions{margin-left:auto!important;display:flex!important;align-items:center!important;gap:6px!important}
body #salesOrder .so-final-row-actions button,body #customerSchedule .cds-row-actions button{height:30px!important;min-width:72px!important;padding:0 9px!important;background:var(--erpplus-accent)!important;color:#000!important;border:1px solid var(--erpplus-accent-border)!important;border-radius:0!important;font:800 12px Arial!important;cursor:pointer!important}
body #salesOrder .so-final-grid-scroll,body #customerSchedule .cds-final-grid-scroll{width:100%!important;max-width:100%!important;overflow-x:auto!important;overflow-y:hidden!important}
body #salesOrder .advanced-items-table,body #customerSchedule .advanced-items-table{width:100%!important;min-width:1050px!important;border-collapse:collapse!important;background:#fff!important}
body #salesOrder .advanced-items-table th,body #customerSchedule .advanced-items-table th{height:34px!important;background:#dce3e9!important;color:#071522!important;border:1px solid #91a1af!important;padding:6px!important;font-size:12px!important;white-space:nowrap!important}
body #salesOrder .advanced-items-table td,body #customerSchedule .advanced-items-table td{height:38px!important;background:#fff!important;color:#000!important;border:1px solid #c0cad3!important;padding:4px!important}
body #salesOrder .advanced-items-table td input,body #salesOrder .advanced-items-table td select,body #customerSchedule .advanced-items-table td input,body #customerSchedule .advanced-items-table td select{height:28px!important;min-height:28px!important;background:#fff!important;color:#000!important;-webkit-text-fill-color:#000!important;border:1px solid #9dacb8!important;padding:3px 5px!important;opacity:1!important}
body #salesOrder .advanced-items-table input[type="checkbox"],body #customerSchedule .advanced-items-table input[type="checkbox"]{width:18px!important;height:18px!important;min-width:18px!important;min-height:18px!important;margin:0 auto!important;padding:0!important;display:block!important;accent-color:#0878d1!important}
body #salesOrder .advanced-items-table th:first-child,body #salesOrder .advanced-items-table td:first-child,body #customerSchedule .advanced-items-table th:first-child,body #customerSchedule .advanced-items-table td:first-child{width:54px!important;min-width:54px!important;max-width:54px!important;text-align:center!important}
@media(max-width:900px){body #salesOrder .ae50-phase1-header,body #salesOrder .form-grid,body #customerSchedule .ae50-phase1-header,body #customerSchedule .form-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}body #salesOrder .clean-action-toolbar,body #customerSchedule .clean-action-toolbar{overflow-x:auto!important}}
\n\n/* ERPPLUS UI Framework R2 - Customer Delivery Schedule final compact standard */\nbody #customerSchedule .cds-toolbar-clean{\n  justify-content:flex-end!important;\n  min-height:44px!important;\n  height:44px!important;\n  padding:5px 8px!important;\n}\nbody #customerSchedule .cds-toolbar-caption-hidden{display:none!important;visibility:hidden!important}\nbody #customerSchedule .cds-toolbar-clean .clean-toolbar-buttons,\nbody #customerSchedule .cds-toolbar-clean .ae50-final-toolbar-buttons{\n  margin-left:auto!important;\n  flex:0 0 auto!important;\n  width:auto!important;\n}\nbody #customerSchedule .cds-final-head{min-height:42px!important;height:42px!important}\nbody #customerSchedule .ae50-phase1-header,\nbody #customerSchedule .form-grid,\nbody #customerSchedule .professional-module-form,\nbody #customerSchedule .advanced-challan-form{\n  gap:7px 12px!important;\n  padding:8px 12px 10px!important;\n  margin-bottom:10px!important;\n}\nbody #customerSchedule .field-wrap input,\nbody #customerSchedule .field-wrap select{height:33px!important;min-height:33px!important}\nbody #customerSchedule .panel-title{min-height:38px!important;height:38px!important;margin-bottom:7px!important}\nbody #customerSchedule .cds-row-actions button{height:30px!important;min-width:86px!important}\nbody #customerSchedule .advanced-items-table th{height:31px!important;padding:5px!important}\nbody #customerSchedule .advanced-items-table td{height:35px!important;padding:3px!important}\nbody #customerSchedule .advanced-items-table td input,\nbody #customerSchedule .advanced-items-table td select{height:27px!important;min-height:27px!important}\nbody #customerSchedule .advanced-items-table input[type=\"checkbox\"]{\n  width:17px!important;height:17px!important;min-width:17px!important;min-height:17px!important\n}\n\n\n/* ERPPLUS Customer Delivery Schedule - final actions-only toolbar */
body #customerSchedule .cds-final-head{min-height:40px!important;height:40px!important}
body #customerSchedule .cds-toolbar-clean{justify-content:flex-end!important}
body #customerSchedule .cds-toolbar-clean .cds-toolbar-caption-hidden{display:none!important;visibility:hidden!important;width:0!important;min-width:0!important;margin:0!important;padding:0!important}
body #customerSchedule .cds-row-actions{gap:6px!important}
body #customerSchedule .cds-row-actions button{width:28px!important;min-width:28px!important;max-width:28px!important;height:28px!important;min-height:28px!important;padding:0!important;font-size:12px!important}
