:root{--day-module-accent:#b32143;--day-module-soft:#fff0f4;--day-red:var(--day-module-accent);--module-red:var(--day-module-accent);--module-red-soft:var(--day-module-soft)}
#appSection.day-connected-shell .erp-header{grid-template-columns:40px auto minmax(0,1fr) auto;column-gap:12px;padding-inline:16px}
#appSection.day-connected-shell .header-brand{gap:12px;min-width:0}
#appSection.day-connected-shell .header-logo{flex:0 0 42px;box-shadow:none}
#appSection.day-connected-shell .header-actions{gap:8px}
#appSection.day-connected-shell .erp-body{background:var(--day-module-accent)}
#appSection.day-connected-shell .erp-workspace{position:relative;z-index:0;background:#f7fafc;border-start-start-radius:0;isolation:isolate}
#appSection.day-connected-shell .erp-workspace:before{content:"";position:fixed;top:68px;bottom:0;left:0;right:220px;z-index:-1;background:#f7fafc;pointer-events:none}
#appSection.day-connected-shell.sidebar-collapsed .erp-workspace:before{right:0}
#appSection.day-connected-shell .module-sidebar-item,#appSection.day-connected-shell .module-sidebar-module,#appSection.day-connected-shell .sidebar-item{border-radius:8px}
.primary-action{background:var(--day-module-accent);border-color:var(--day-module-accent);box-shadow:none}
.primary-action:hover{background:var(--day-module-accent);border-color:var(--day-module-accent);filter:brightness(.92)}
.day-select{display:inline-grid;grid-template-columns:minmax(0,1fr);width:100%;min-width:0;max-width:100%}
.day-select[hidden]{display:none!important}
.day-select>.day-select-button{width:100%;min-width:0;max-width:100%;height:40px;min-height:40px;box-sizing:border-box;padding:0 10px;gap:8px;border-radius:6px;white-space:nowrap;background:#fff;color:var(--module-text);font-size:14px;font-weight:400}
.day-select-value{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:start}
.day-select>.day-select-button:after{flex:0 0 8px}
.day-select-menu>button{width:100%;height:auto;min-height:36px;white-space:normal;overflow-wrap:anywhere;font-size:14px;font-weight:400;color:var(--module-text)}
.day-select-menu>button:hover,.day-select-menu>button:focus-visible{background:var(--day-module-soft);color:var(--day-module-accent)}
.day-select-menu>button[aria-selected=true]{background:var(--day-module-accent);color:#fff}
@media(max-width:430px){#appSection.day-connected-shell .header-brand>div{display:none}}
@media(max-width:900px){#appSection.day-connected-shell .erp-workspace:before{right:0}}
@media(max-width:760px){#appSection.day-connected-shell .erp-header{grid-template-columns:40px minmax(0,1fr) auto;column-gap:10px;padding-inline:12px}#appSection.day-connected-shell .header-profile-trigger{display:none!important}#appSection.day-connected-shell .header-brand{gap:10px}.wf-assignee-row>.day-select{grid-column:1 / 2}}
#appSection.day-connected-shell .erp-header{background:#f8f8fa;color:#262b36;border:0;border-top:3px solid var(--day-module-accent);box-shadow:none}
#appSection.day-connected-shell .erp-sidebar{background:#f8f8fa;color:#262b36;border:0;border-inline-end:1px solid #cdd2dc;box-shadow:none;margin:0;border-radius:0}
#appSection.day-connected-shell .header-brand small,#appSection.day-connected-shell .header-center small{color:#59616f;opacity:1}
#appSection.day-connected-shell .header-center{background:transparent;border:0;color:#262b36}
#appSection.day-connected-shell .erp-header button{color:#414958;background:transparent;border-color:transparent}
#appSection.day-connected-shell .erp-header button:hover{background:#e9ecf2}
#appSection.day-connected-shell .erp-header button:focus-visible{outline:2px solid var(--day-module-accent);outline-offset:3px}
#appSection.day-connected-shell .erp-header .header-user-avatar{background:rgba(255,255,255,.18);color:#fff}
.day-module-mark{display:grid;place-items:center;flex:0 0 32px;width:32px;height:32px;border-radius:6px;background:rgba(255,255,255,.15)}
.day-module-mark svg{width:22px;height:22px}
#appSection.day-connected-shell .sidebar-top-label,#appSection.day-connected-shell .sidebar-version{color:#59616f;opacity:1}
#appSection.day-connected-shell .sidebar-item,#appSection.day-connected-shell .module-sidebar-module,#appSection.day-connected-shell .module-sidebar-item{color:#3f4653;border-color:transparent}
#appSection.day-connected-shell .sidebar-item:hover,#appSection.day-connected-shell .module-sidebar-module:hover,#appSection.day-connected-shell .module-sidebar-item:hover,#appSection.day-connected-shell .sidebar-item:focus-visible,#appSection.day-connected-shell .module-sidebar-module:focus-visible,#appSection.day-connected-shell .module-sidebar-item:focus-visible{background:var(--day-module-soft)!important;color:var(--day-module-accent)}
#appSection.day-connected-shell .sidebar-item.active,#appSection.day-connected-shell .module-sidebar-module.active,#appSection.day-connected-shell .module-sidebar-item.active{background:#fff!important;color:var(--day-module-accent);box-shadow:none}
#appSection.day-connected-shell .erp-sidebar button:focus-visible{outline:2px solid var(--day-module-accent);outline-offset:2px}
#appSection.day-connected-shell .erp-sidebar button:hover .sidebar-icon,#appSection.day-connected-shell .erp-sidebar button:focus-visible .sidebar-icon{color:inherit}
.erp-workspace .catalog-table th{text-align:center!important}
.erp-workspace .catalog-table td{text-align:center!important}
.erp-workspace .catalog-table td.table-description{text-align:right!important}
.inventory-unit-section{margin-top:16px;border-top:1px solid var(--module-line);padding-top:12px}
.inventory-unit-section>header{display:flex;align-items:center;justify-content:flex-start;gap:12px}
.inventory-unit-section h3{font-size:14px;margin:0}
.inventory-unit-row{display:grid;grid-template-columns:minmax(100px,1fr) minmax(100px,1fr) auto auto 36px;gap:8px;align-items:end;padding-block:8px}
.inventory-unit-row>label{min-width:0}
.inventory-unit-row>button{height:36px;width:36px;border:1px solid var(--module-line);border-radius:6px;background:#fff;color:#b32143}
.inventory-unit-row>button svg{width:18px;height:18px}
@media(max-width:760px){.inventory-unit-row{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.inventory-unit-row>button{grid-column:2;justify-self:end}}
.project-column-summary{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 8px;margin:6px 0;background:var(--day-module-soft);border-radius:6px;min-height:40px}
.project-column-summary .column-add-task{margin:0;flex:0 0 32px;width:32px;min-width:32px;height:32px;padding:0}
#appSection.day-connected-shell .sidebar-icon,#appSection.day-connected-shell .module-sidebar-module-icon{background:rgba(255,255,255,.13);color:inherit}
#appSection.day-connected-shell .sidebar-item.active .sidebar-icon,#appSection.day-connected-shell .module-sidebar-module.active .module-sidebar-module-icon{background:var(--day-module-soft);color:var(--day-module-accent)}
#appSection.day-connected-shell .module-menu-chevron{color:inherit}
#appSection.day-connected-shell .module-sidebar-module b{color:inherit}
#appSection.day-connected-shell .module-focus-nav{padding-top:4px}
.module-page .module-head{border-top-color:var(--day-module-accent)}
.module-detail-grid>div{display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:4px 12px;text-align:start}
.module-detail-grid>div>span{flex:0 0 auto}
.module-detail-grid>div>b{margin:0;min-width:0;text-align:start}
.module-detail-grid>div>b[dir=ltr]{text-align:right;unicode-bidi:isolate}
.day-action-panel{position:fixed!important;inset:auto!important;left:50%!important;top:50%!important;transform:translate(-50%,-50%)!important;margin:0!important;width:min(760px,calc(100vw - 32px))!important;max-width:calc(100vw - 32px)!important;height:auto!important;max-height:calc(100dvh - 40px)!important;border-radius:12px!important;overflow:auto;overscroll-behavior:contain;border:1px solid var(--module-line);box-shadow:0 0 0 100vmax rgba(20,30,40,.28),0 16px 48px rgba(20,30,40,.18)!important;z-index:100}
dialog.day-action-panel{box-shadow:0 16px 48px rgba(20,30,40,.18)!important}
dialog.day-action-panel::backdrop,.day-centered-dialog::backdrop{background:rgba(20,30,40,.28)}
.hr-modal-host .day-action-panel,.workflow-modal-backdrop .day-action-panel,.mail-dialog-backdrop .day-action-panel{box-shadow:0 16px 48px rgba(20,30,40,.18)!important}
.day-panel-expand,.day-record-expand{display:none!important}
.day-centered-dialog[open]{display:block;position:fixed;inset:0;margin:auto;padding:0;width:min(760px,calc(100vw - 32px));max-height:calc(100dvh - 40px);height:fit-content;overflow:auto;background:#fff;border:1px solid var(--module-line);border-radius:12px;box-shadow:0 16px 48px #20283830;font:inherit;color:var(--module-text)}
.day-centered-dialog>.hr-leave-workflow-dialog{width:100%;max-width:100%;max-height:none;box-sizing:border-box;box-shadow:none;border:0}
.day-action-panel>header,.day-action-panel>form>header{display:flex;align-items:center;gap:8px;background:var(--day-module-soft);color:var(--module-text);border-bottom:2px solid var(--day-module-accent)}
.day-action-panel header>:first-child:not(button){flex:1;min-width:0}
.day-action-panel header h3{color:var(--module-text)}
.day-action-panel header h2{color:var(--module-text);font-size:var(--day-section-size)}
.day-action-panel header p{color:var(--module-muted)}
.day-panel-expand{width:34px;height:34px;min-width:34px;flex:0 0 34px;border:1px solid var(--module-line-strong);border-radius:6px;background:#fff;color:var(--day-module-accent);padding:6px;cursor:pointer}
.day-panel-expand svg{display:block;width:20px;height:20px}
.day-panel-expand:focus-visible{outline:2px solid var(--day-module-accent);outline-offset:2px}
.day-action-panel:not(.hr-contract-form)>header,.day-action-panel>form>header{position:sticky;top:0;z-index:5;padding:12px}
.day-action-panel .hr-contract-title-icon{background:var(--day-module-accent);color:#fff}
.day-action-panel .hr-editor-close{background:#fff;color:var(--day-module-accent);border-color:var(--module-line-strong)}

@media(max-width:760px){.day-action-panel{width:calc(100vw - 24px)!important;max-width:calc(100vw - 24px)!important;max-height:calc(100dvh - 24px)!important}.day-panel-expand{display:none}.day-module-mark{display:none}.module-detail-grid{grid-template-columns:minmax(0,1fr)}}
@supports(backdrop-filter:blur(10px)){#appSection.day-connected-shell :is(.erp-header,.erp-sidebar){background:rgba(248,248,250,.96);backdrop-filter:blur(10px)}}

/* Transient dialogs are centered and sized for their task. Retained records remain in the workspace. */
.wf-note-dialog.day-action-panel{width:min(560px,calc(100vw - 32px))!important;}
.wf-note-dialog>form{display:grid;gap:0;margin:0;min-width:0;}
.wf-note-dialog>form>textarea{display:block;width:calc(100% - 32px);margin:16px;min-height:100px;box-sizing:border-box;}
.wf-note-dialog>form>footer{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px;padding:12px 16px;border-top:1px solid var(--module-line);}
.module-editor-wide.day-action-panel{width:min(1120px,calc(100vw - 32px))!important;}

.day-input-dialog{width:min(560px,calc(100vw - 32px));box-sizing:border-box;}
.day-input-dialog label{display:grid;gap:8px;font-size:14px;font-weight:600;}
.day-input-dialog textarea{width:100%;min-height:100px;box-sizing:border-box;font:inherit;color:var(--module-text);padding:10px;border:1px solid var(--module-line-strong);border-radius:6px;}
dialog.notification-sound-backdrop[open]{display:block;position:fixed;inset:0;margin:auto;padding:0;width:min(560px,calc(100vw - 24px));height:fit-content;max-height:calc(100dvh - 32px);overflow:auto;background:#fff;border:1px solid var(--module-line);border-radius:12px;box-shadow:0 16px 48px #20283830;font:inherit;backdrop-filter:none;}
dialog.notification-sound-backdrop::backdrop{background:rgba(20,30,40,.28)}
dialog.notification-sound-backdrop>.notification-sound-dialog{width:100%;max-width:100%;max-height:none;border:0;box-shadow:none;box-sizing:border-box;}

/* Portalled transient editors inherit the same fields as workspace forms. */
.day-action-panel :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),textarea,select),.day-centered-dialog :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),textarea,select){font-family:var(--module-font,Vazir),Tahoma,Arial,sans-serif;color:var(--module-text);border:1px solid var(--module-line-strong);border-radius:6px;box-sizing:border-box;max-width:100%;}
.day-action-panel textarea,.day-centered-dialog textarea{padding:10px;resize:vertical;}
.day-action-panel :is(input,textarea,select):focus-visible,.day-centered-dialog :is(input,textarea,select):focus-visible,.day-input-dialog textarea:focus-visible{outline:2px solid var(--day-module-accent);outline-offset:2px;}
.day-action-panel header :is(h2,h3),.day-centered-dialog header :is(h2,h3){margin:0;line-height:1.6;}
.day-action-panel header p,.day-centered-dialog header p{margin:4px 0 0;line-height:1.6;}
