@layer erpComponents {
  html body.erp-system-ui #orderMessagesBtn { position:relative!important; color:var(--theme-accent-deep,#148fa2)!important; background:var(--theme-accent-soft,#e7f7fa)!important; }
  html body.erp-system-ui #orderMessagesBtn[hidden],html body.erp-system-ui #orderPushSettingsBtn[hidden],html body.erp-system-ui .om-dialog [hidden],html body.erp-system-ui .om-settings [hidden] { display:none!important; }
  html body.erp-system-ui #orderMessagesBtn svg { width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round; }
  html body.erp-system-ui :is([data-om-count],.office-pending-nav-badge,.cf-nav-badge) {background:#f45162;color:white!important;}
  html body.erp-system-ui [data-om-count] { position:absolute;top:-5px;right:-7px;min-width:17px;height:17px;padding:0 4px;border-radius:10px;font:600 10px/17px Arial;text-align:center; }
  html body.erp-system-ui [data-om-count][hidden] {display:none!important;}
  html body.erp-system-ui.erp-beauty-v2.erp-beauty-v3 dialog:is(.om-dialog,.om-settings) { position:fixed!important;inset:0!important;margin:auto!important;box-sizing:border-box!important;width:min(920px,calc(100vw - 32px))!important;min-width:0!important;max-width:920px!important;height:fit-content!important;min-height:0!important;max-height:calc(var(--erp-visible-height,100dvh) - 40px)!important;padding:0!important;border:1px solid var(--ui-border,#dfe6ee)!important;border-radius:var(--ui-dialog-radius,16px)!important;background:var(--ui-surface,#fff)!important;color:var(--ui-text,#263446)!important;box-shadow:var(--ui-dialog-shadow)!important;overflow:hidden!important;zoom:calc(1 / var(--erp-page-zoom,1.05))!important; }
  html body.erp-system-ui.erp-beauty-v2.erp-beauty-v3 dialog.om-settings {width:min(690px,calc(100vw - 32px))!important;max-width:690px!important;}
  html body.erp-system-ui dialog.om-dialog[open],html body.erp-system-ui dialog.om-settings[open] {display:flex!important;flex-direction:column!important;}
  html body.erp-system-ui :is(.om-dialog,.om-settings)>header {display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 22px;border-bottom:1px solid var(--ui-border,#e4eaf1);flex:none;margin:0!important;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) h2 {font-size:18px;line-height:1.5;margin:0;}
  html body.erp-system-ui .om-dialog h2 small {font-size:12px;font-weight:400;color:var(--ui-muted,#8a95a4);margin-left:12px;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) [data-om-close] {width:32px;height:32px;flex:none;padding:0;font-size:22px;background:#f4f7fa;border:0;border-radius:8px;color:#7c8a9b;}
  html body.erp-system-ui .om-toolbar {display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:14px 22px;border-bottom:1px solid var(--ui-border,#e4eaf1);flex:none;}
  html body.erp-system-ui .om-toolbar select {width:160px;}
  html body.erp-system-ui :is(.om-unread-filter,.om-toggle) {display:flex!important;flex-direction:row!important;align-items:center!important;gap:7px!important;font-size:13px!important;white-space:nowrap;margin:0!important;}
  html body.erp-system-ui :is(.om-unread-filter,.om-toggle) input {width:16px!important;height:16px!important;min-height:16px!important;flex:none;accent-color:var(--theme-accent,#20aec2);}
  html body.erp-system-ui .om-list {overflow:auto;min-height:160px;max-height:58dvh;flex:1;overscroll-behavior:contain;}
  html body.erp-system-ui .om-message {display:flex;align-items:flex-start;gap:12px;padding:18px 22px;border-bottom:1px solid #eef1f5;}
  html body.erp-system-ui .om-message.is-unread {background:color-mix(in srgb,var(--theme-accent-soft,#e7f7fa) 45%,#fff);}
  html body.erp-system-ui .om-event-icon {width:28px;height:28px;flex:none;background:var(--theme-accent-soft,#e7f7fa);color:var(--theme-accent-deep,#168c9d);border-radius:8px;display:grid;place-items:center;font-weight:700;}
  html body.erp-system-ui .om-message-copy {flex:1;min-width:0;}
  html body.erp-system-ui .om-message-heading {display:flex;align-items:center;gap:10px;flex-wrap:wrap;}
  html body.erp-system-ui .om-message-heading b {font-size:14px;}
  html body.erp-system-ui .om-message-heading time {margin-left:auto;color:#8a95a4;font-size:11px;}
  html body.erp-system-ui .om-message p {display:flex;gap:10px;flex-wrap:wrap;margin:7px 0 0;font-size:12px;line-height:1.6;}
  html body.erp-system-ui .om-shop {max-width:190px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:#327acf;}
  html body.erp-system-ui .om-posting {font-size:12px;border:0!important;padding:0!important;background:transparent!important;color:#327acf!important;min-height:0!important;}
  html body.erp-system-ui .om-sync {color:#c78c28!important;}
  html body.erp-system-ui .om-sync.is-done {color:#3d9b73!important;}
  html body.erp-system-ui .om-message-actions {display:flex;gap:7px;flex-wrap:wrap;justify-content:flex-end;max-width:170px;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) button {cursor:pointer;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) button:not([data-om-close]):not(.om-posting) {border:1px solid var(--ui-border,#dce5ef);border-radius:7px;background:var(--ui-surface,#fff);color:var(--ui-text,#263446);min-height:32px;padding:6px 11px;font-size:12px;line-height:1.5;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) button.lc-primary {background:var(--theme-accent,#20aec2)!important;border-color:var(--theme-accent,#20aec2)!important;color:#fff!important;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) button:disabled {opacity:.45;cursor:not-allowed;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) :is(select,input[type=url]) {height:36px;width:100%;min-width:0;border:1px solid var(--ui-border,#dce5ef);border-radius:7px;padding:6px 10px;color:var(--ui-text,#263446);background:var(--ui-surface,#fff);font-size:13px;}
  html body.erp-system-ui .om-toolbar select {width:160px;}
  html body.erp-system-ui .om-message-actions button {font-size:12px;padding:5px 8px;}
  html body.erp-system-ui :is(.om-dialog,.om-settings) footer {display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px;padding:14px 22px!important;border-top:1px solid var(--ui-border,#e4eaf1);flex:none;margin:0!important;background:var(--ui-field-surface,#fbfcfe);}
  html body.erp-system-ui .om-dialog footer>span {color:#8a95a4;font-size:12px;}
  html body.erp-system-ui .om-dialog footer>div {display:flex;align-items:center;gap:12px;font-size:12px;}
  html body.erp-system-ui .om-empty {padding:44px 20px;text-align:center;color:#8793a2;font-size:13px;}
  html body.erp-system-ui .om-note {font-size:12px;line-height:1.6;color:#d44c51;margin:0;padding:0 22px;}
  html body.erp-system-ui .om-note:not(:empty) {padding-top:10px;padding-bottom:10px;}
  html body.erp-system-ui .om-settings form {display:flex;flex-direction:column;overflow:hidden;min-height:0;margin:0;}
  html body.erp-system-ui .om-settings-body {overflow:auto;min-height:0;overscroll-behavior:contain;}
  html body.erp-system-ui .om-settings footer {justify-content:flex-end;}
  html body.erp-system-ui .om-setting-grid {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;padding:20px 22px;align-items:end;}
  html body.erp-system-ui .om-setting-grid label {display:flex;flex-direction:column;gap:7px;font-size:13px;min-width:0;margin:0!important;}
  html body.erp-system-ui .om-setting-grid .om-toggle {min-height:36px;white-space:normal;line-height:1.5;}
  html body.erp-system-ui .om-wide {grid-column:1 / -1;}
  html body.erp-system-ui .om-field-help {font-size:11px;line-height:1.6;color:var(--ui-muted,#8a95a4);font-weight:400;}
  html body.erp-system-ui .om-url-row {display:flex;gap:10px;align-items:center;}
  html body.erp-system-ui .om-url-row textarea {flex:1;min-width:0;resize:none!important;font-size:12px;line-height:1.6;padding:9px;border:1px solid var(--ui-border,#dce5ef);border-radius:8px;background:#f7f9fc;word-break:break-all;}
  html body.erp-system-ui .om-connection-status {margin:0 22px 12px;padding:10px 12px;line-height:1.7;font-size:12px;border-radius:8px;color:var(--theme-accent-deep,#168c9d);background:var(--theme-accent-soft,#e7f7fa);}
  html body.erp-system-ui .om-setup-steps {margin:0;padding:0 22px 0 42px;color:#657489;font-size:12px;line-height:1.8;}
  html body.erp-system-ui .om-setup-steps li {margin:7px 0;}
  html body.erp-system-ui .om-help {margin:12px 22px 20px;color:#8a95a4;font-size:12px;line-height:1.8;}
  @media(max-width:700px) {
    html body.erp-system-ui :is(.om-dialog,.om-settings)>header {padding:15px;}
    html body.erp-system-ui .om-dialog h2 small {display:block;margin:3px 0 0;}
    html body.erp-system-ui .om-toolbar {padding:12px 15px;gap:8px;}
    html body.erp-system-ui .om-message {padding:16px 15px;gap:9px;flex-wrap:wrap;}
    html body.erp-system-ui .om-message-copy {flex-basis:calc(100% - 40px);}
    html body.erp-system-ui .om-message-heading time {margin-left:0;width:100%;}
    html body.erp-system-ui .om-message-actions {max-width:none;margin-left:37px;}
    html body.erp-system-ui .om-setting-grid {grid-template-columns:minmax(0,1fr);padding:16px;gap:16px;}
    html body.erp-system-ui :is(.om-dialog,.om-settings) footer {padding:13px 15px;}
  }
  @media(max-width:900px) {
    html body.erp-system-ui.erp-beauty-v2.erp-beauty-v3 dialog:is(.om-dialog,.om-settings) {zoom:1!important;width:calc(100vw - 24px)!important;max-height:calc(var(--erp-visible-height,100dvh) - 24px)!important;}
  }
}
