/* 佳锌 ERP · 统一页面头部规范 · V2.7.10
   Headers share one restrained blue-white surface across business, forms and tools.
   Layout/drag/WCO ownership stays with each module; no extra enclosing cards. */
:root{
 --jx-head-bg:linear-gradient(112deg,var(--jx-ui-surface,#fff) 0%,#fafdff 46%,var(--jx-ui-soft,#edf4ff) 100%);
 --jx-head-divider:var(--jx-ui-border,#e2ebf7);
 --jx-head-ease:cubic-bezier(.22,1,.36,1);
}
:is(.ws-header,.ws-modal-header,.ws-form-sheet-header,.ws-floating-header,.ws-tools-panel-head,
    .jx-studio-top,.sheet-top,.topbar,.mg-header,.bp-top){
 background:var(--jx-head-bg);border-bottom-color:var(--jx-head-divider);
}
/* Studio and Excel use exactly the same title-row spacing, icon scale and buttons. */
.jx-print-overlay .jx-studio-top{min-height:74px;padding:12px 22px;gap:18px;}
.jx-print-overlay .jx-studio-brand{gap:15px;}
.jx-print-overlay .jx-brand-mark{height:36px;width:36px;border-radius:10px;box-shadow:none;
 background:var(--jx-ui-soft,#edf4ff);border-color:var(--jx-head-divider);color:var(--jx-ui-accent,#2c6bdd);}
.jx-print-overlay .jx-studio-divider{height:22px;background:var(--jx-head-divider);}
.jx-print-overlay .jx-studio-brand-text{font-size:15px;letter-spacing:.01em;}
.jx-print-overlay .jx-studio-subtitle{font-size:11px;max-width:260px;}
.jx-print-overlay .jx-p-btn{min-height:35px;border-radius:9px;padding:7px 12px;box-shadow:0 1px 1px #15345c08;}
.jx-print-overlay .jx-p-btn.jx-primary{box-shadow:0 2px 6px #174fb019;}
.jx-print-overlay .jx-p-btn.jx-back{padding:8px 11px;color:var(--jx-ui-muted,#657892);}
.jx-print-overlay .jx-top-controls{gap:7px;}
.jx-print-overlay .jx-template-switch{height:35px;border-radius:9px;}
/* Toolbar on resize: never conceal the return or save action. */
@media(max-width:1050px){.jx-print-overlay .jx-studio-top{padding:10px 15px;gap:9px;}}
@media(max-width:480px){.jx-print-overlay .jx-studio-top{padding:9px 10px;}
 .jx-print-overlay .jx-studio-brand{gap:8px;}
 .jx-print-overlay .jx-top-controls{justify-content:flex-start;}}
/* Form editor and all other full-page views preserve their native structure. */
@media(prefers-reduced-motion:reduce){
 :is(.ws-header,.ws-modal-header,.ws-form-sheet-header,.jx-studio-top,.sheet-top,.topbar){transition:none!important;}
}

/* 2.7.11 · Single floating-window title contract. The approved NEW RECORD
   sheet is the reference. Scoped selectors keep editors and tables independent. */
:root{
 --jx-float-title-bg:linear-gradient(125deg,var(--jx-ui-surface,#fff) 0%,#fafdff 45%,var(--jx-ui-soft,#f1f6ff) 100%);
 --jx-float-title-border:var(--jx-ui-border,#e4edf8);
}
.ws-modal-layer.jx-action-modal .ws-modal-header,
.ws-form-overlay.ws-record-edit-overlay .ws-form-sheet-header,
.ws-floating-settings .ws-floating-header,
.hr-modal .hr-modal-head,
.bp-dialog > header.bp-modal-head,
.jx-schema-dialog > .jx-schema-head,
.jx-default-relation-dialog > .jx-default-relation-head{
 background:var(--jx-float-title-bg)!important;
 border-bottom:1px solid var(--jx-float-title-border);
}
.ws-modal-layer.jx-action-modal .ws-modal-header,
.ws-form-overlay.ws-record-edit-overlay .ws-form-sheet-header{
 display:flex;align-items:center;gap:13px;min-height:76px;
 padding:12px 20px;
}
.ws-modal-layer.jx-action-modal #modal-title{
 display:flex;align-items:center;flex:1;min-width:0;margin:0;
 font-size:inherit;line-height:normal;
}
.ws-modal-layer.jx-action-modal .jx-action-title,
.ws-floating-settings .jx-action-title,
.ws-record-edit-overlay .jx-action-title{display:flex;align-items:center;gap:13px;flex:1;min-width:0}
.ws-modal-layer.jx-action-modal .jx-action-icon,
.ws-floating-settings .jx-action-icon,
.ws-record-edit-overlay .jx-action-icon{
 flex:none;display:grid;place-items:center;width:42px;height:42px;
 border-radius:12px;color:var(--jx-ui-accent,#286bce);
 background:var(--jx-ui-soft,#ebf3ff);border:1px solid var(--jx-float-title-border);
}
.ws-modal-layer.jx-action-modal .jx-action-icon svg,
.ws-floating-settings .jx-action-icon svg,
.ws-record-edit-overlay .jx-action-icon svg{width:22px;height:22px;stroke-width:1.8}
.ws-modal-layer.jx-action-modal .jx-action-caption,
.ws-floating-settings .jx-action-caption,
.ws-record-edit-overlay .jx-action-caption{display:grid;gap:5px;min-width:0}
.ws-modal-layer.jx-action-modal .jx-action-caption small,
.ws-floating-settings .jx-action-caption small,
.ws-record-edit-overlay .jx-action-caption small,
.bp-modal-caption small{
 display:block;font-size:10px;font-weight:760;line-height:1.2;
 letter-spacing:1.6px;color:var(--jx-ui-muted,#8294ab);
}
.ws-modal-layer.jx-action-modal .jx-action-caption strong,
.ws-floating-settings .jx-action-caption strong,
.ws-record-edit-overlay .jx-action-caption strong{
 display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
 font-size:17px;line-height:1.3;font-weight:750;color:var(--jx-ui-text,#273b57);
}
.ws-modal-layer.jx-action-modal #modal-close,
.ws-form-overlay .ws-form-icon.jx-svg-close,
.ws-floating-settings .ws-floating-close.jx-svg-close,
.hr-modal-head #hr-modal-close,
.bp-dialog .bp-modal-head #bp-close{
 box-sizing:border-box;position:static;inset:auto;flex:none;
 display:grid;place-items:center;width:36px;height:36px;min-width:36px;
 padding:7px;border:1px solid transparent;border-radius:10px;
 background:transparent;color:var(--jx-ui-muted,#687b96);cursor:pointer;
}
.ws-modal-layer.jx-action-modal #modal-close svg,
.ws-form-overlay .ws-form-icon.jx-svg-close svg,
.ws-floating-settings .ws-floating-close.jx-svg-close svg,
.hr-modal-head #hr-modal-close svg,
.bp-dialog .bp-modal-head #bp-close svg{display:block;width:20px;height:20px;stroke-width:1.9}
.ws-modal-layer.jx-action-modal #modal-close:hover,
.ws-form-overlay .ws-form-icon.jx-svg-close:hover,
.ws-floating-settings .ws-floating-close.jx-svg-close:hover,
.hr-modal-head #hr-modal-close:hover,
.bp-dialog .bp-modal-head #bp-close:hover{
 background:var(--jx-ui-soft,#edf4ff)!important;
 border-color:var(--jx-ui-border,#d7e5f8)!important;
 color:var(--jx-ui-accent,#286bce);
}
.ws-modal-layer.jx-action-modal #modal-close:focus-visible,
.ws-form-overlay .ws-form-icon.jx-svg-close:focus-visible,
.ws-floating-settings .ws-floating-close.jx-svg-close:focus-visible,
.hr-modal-head #hr-modal-close:focus-visible,
.bp-dialog .bp-modal-head #bp-close:focus-visible{
 outline:2px solid var(--jx-ui-accent,#3479d5);outline-offset:2px;
}
.ws-modal-layer .ws-modal-footer[hidden],
.bp-dialog footer[hidden],.bp-dialog footer button[hidden]{display:none!important}
.ws-form-overlay.ws-record-edit-overlay .ws-form-sheet-header{flex:0 0 auto}
.ws-form-overlay.ws-record-edit-overlay .ws-form-sheet-header .jx-action-caption strong{font-size:16px}
.ws-floating-settings .ws-floating-header{min-height:72px;gap:9px;padding:10px 13px}
.ws-floating-settings .ws-floating-header .jx-action-icon{width:37px;height:37px;border-radius:11px}
.ws-floating-settings .ws-floating-header .jx-action-icon svg{width:19px;height:19px}
.ws-floating-settings .ws-floating-header .jx-action-caption strong{font-size:14px}
.ws-floating-settings .ws-floating-header .ws-live-tip{font-size:10px;white-space:nowrap}
.hr-modal .hr-modal-head{min-height:78px;padding:12px 20px!important}
.hr-modal .hr-modal-head-icon{width:42px;height:42px;border-radius:12px;background:var(--jx-ui-soft,#ebf3ff);border-color:var(--jx-float-title-border)}
.hr-modal .hr-modal-heading>span{color:var(--jx-ui-muted,#8294ab)}
.bp-dialog > header.bp-modal-head{
 display:flex;align-items:center;gap:13px;min-height:78px;padding:12px 21px;
}
.bp-dialog .bp-modal-head-icon{display:grid;place-items:center;flex:none;width:42px;height:42px;
 border-radius:12px;background:var(--jx-ui-soft,#ebf3ff);color:var(--jx-ui-accent,#286bce);border:1px solid var(--jx-float-title-border)}
.bp-dialog .bp-modal-head-icon svg{width:22px;height:22px}
.bp-dialog .bp-modal-caption{flex:1;min-width:0;display:grid;gap:5px}
.bp-dialog .bp-modal-head .bp-modal-caption h2{margin:0;font-size:17px;line-height:1.3;font-weight:750;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bp-dialog .bp-modal-head #bp-close{margin-left:auto}
/* Secondary editor dialogs receive the same header surface without inheriting
   parent window dimensions or changing their save/cancel workflow. */
.jx-schema-dialog > .jx-schema-head{min-height:69px}
@media(max-width:560px){
 .ws-modal-layer.jx-action-modal .ws-modal-header,.ws-form-overlay.ws-record-edit-overlay .ws-form-sheet-header,
 .hr-modal .hr-modal-head,.bp-dialog > header.bp-modal-head{gap:10px;min-height:66px;padding:10px 13px!important}
 .ws-modal-layer.jx-action-modal .jx-action-icon,.ws-record-edit-overlay .jx-action-icon,
 .bp-dialog .bp-modal-head-icon,.hr-modal .hr-modal-head-icon{width:36px;height:36px;border-radius:10px}
 .ws-modal-layer.jx-action-modal .jx-action-icon svg,.ws-record-edit-overlay .jx-action-icon svg,
 .bp-dialog .bp-modal-head-icon svg{width:19px;height:19px}
 .ws-modal-layer.jx-action-modal .jx-action-caption strong,.ws-record-edit-overlay .jx-action-caption strong,
 .bp-dialog .bp-modal-head .bp-modal-caption h2{font-size:14px}
 .ws-floating-settings .ws-floating-header .ws-live-tip{display:none}
}
@media(prefers-reduced-motion:reduce){
 .ws-modal-layer.jx-action-modal .ws-modal,.hr-modal,.bp-dialog{animation:none!important;transition:none!important}
}

/* Designer popups use the exact same bilingual title row. */
.jx-schema-head>.jx-designer-float-title,.jx-default-relation-head>.jx-designer-float-title{display:flex;align-items:center;gap:13px;flex:1;min-width:0}
.jx-designer-float-icon{display:grid;place-items:center;flex:none;width:42px;height:42px;background:var(--jx-ui-soft,#edf4ff);border:1px solid var(--jx-float-title-border);border-radius:12px;color:var(--jx-ui-accent,#286bce)}
.jx-designer-float-icon svg{display:block;width:22px;height:22px}
.jx-designer-float-caption{display:grid;min-width:0;gap:5px}
.jx-designer-float-caption small{font-size:10px;font-weight:750;letter-spacing:1.6px;line-height:1.2;color:var(--jx-ui-muted,#8494ac)}
.jx-designer-float-caption strong{font-size:17px;font-weight:750;color:var(--jx-ui-text,#263b56);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.jx-schema-head>.jx-schema-close,.jx-default-relation-head>.jx-schema-close{position:static;flex:none;display:grid;place-items:center;width:36px;height:36px;padding:7px;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--jx-ui-muted,#71829a);cursor:pointer}
.jx-schema-head>.jx-schema-close svg,.jx-default-relation-head>.jx-schema-close svg{display:block;width:20px;height:20px}
.jx-schema-head>.jx-schema-close:hover,.jx-default-relation-head>.jx-schema-close:hover{background:var(--jx-ui-soft,#edf4ff);border-color:var(--jx-ui-border,#d9e7f8)}
.jx-schema-head>.jx-schema-close:focus-visible,.jx-default-relation-head>.jx-schema-close:focus-visible{outline:2px solid var(--jx-ui-accent,#3479d5);outline-offset:2px}
.jx-default-relation-dialog>.jx-default-relation-head{min-height:70px;display:flex;align-items:center;gap:12px;padding:10px 17px}
/* Actual actions remain in footers; a lone read-only close row does not. */
.hr-modal .hr-modal-actions[hidden],.bp-dialog>footer[hidden]{display:none!important}
/* Same inverse exit rhythm as the workbench, including reduced-motion support. */
@keyframes jx-contract-float-in{from{opacity:0;scale:.975;filter:blur(2px)}to{opacity:1;scale:1;filter:blur(0)}}
@keyframes jx-contract-float-out{from{opacity:1;scale:1;filter:blur(0)}to{opacity:0;scale:.985;filter:blur(1px)}}
.hr-modal-overlay:not([hidden]):not(.jx-floating-closing)>.hr-modal,
.bp-overlay:not([hidden]):not(.jx-floating-closing)>.bp-dialog{animation:jx-contract-float-in 220ms cubic-bezier(.22,1,.36,1) both}
.hr-modal-overlay.jx-floating-closing>.hr-modal,
.bp-overlay.jx-floating-closing>.bp-dialog{animation:jx-contract-float-out 145ms ease-in both;pointer-events:none}
@media(max-width:560px){.jx-designer-float-icon{width:36px;height:36px}.jx-designer-float-caption strong{font-size:14px}}
@media(prefers-reduced-motion:reduce){
 .hr-modal-overlay:not([hidden])>.hr-modal,.bp-overlay:not([hidden])>.bp-dialog{animation:none!important}
}
/* Shared alert/confirm/prompt dialogs participate in the same contract.
   Cancel + Confirm remain because they represent genuine alternative decisions. */
.jx-dialog .jx-dialog-header{position:relative;background:var(--jx-float-title-bg);border-bottom:1px solid var(--jx-float-title-border);display:flex;align-items:center;gap:13px;min-height:78px;padding:15px 20px}
.jx-dialog .jx-dialog-icon{flex:none;width:42px;height:42px;border:1px solid var(--jx-float-title-border);border-radius:12px;font-size:inherit}
.jx-dialog .jx-dialog-icon svg{display:block;width:22px;height:22px}
.jx-dialog .jx-dialog-heading{display:grid;gap:5px;flex:1;min-width:0;padding-right:37px}
.jx-dialog .jx-dialog-heading small{font-size:10px;font-weight:750;letter-spacing:1.6px;line-height:1.2;color:var(--jx-ui-muted,#8494ac)}
.jx-dialog .jx-dialog-heading h2{margin:0;font-size:17px;line-height:1.3}
.jx-dialog .jx-dialog-heading p{margin:2px 0 0;font-size:12px;line-height:1.6}
.jx-dialog .jx-dialog-close{position:absolute;top:16px;right:17px;flex:none;display:grid;place-items:center;width:36px;height:36px;margin:0;padding:7px;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--jx-ui-muted,#72829a);cursor:pointer}
.jx-dialog .jx-dialog-close svg{display:block;width:20px;height:20px}
.jx-dialog .jx-dialog-close:hover{background:var(--jx-ui-soft,#edf4ff);border-color:var(--jx-ui-border,#d9e7f8)}
.jx-dialog .jx-dialog-close:focus-visible{outline:2px solid var(--jx-ui-accent,#3479d5);outline-offset:2px}
.jx-dialog-backdrop.is-open.jx-dialog-closing .jx-dialog{animation:jx-contract-float-out 145ms ease-in both!important;pointer-events:none}
@media(max-width:560px){.jx-dialog .jx-dialog-header{min-height:66px;padding:12px 14px}.jx-dialog .jx-dialog-icon{width:36px;height:36px}.jx-dialog .jx-dialog-heading h2{font-size:15px}}
@media(prefers-reduced-motion:reduce){.jx-dialog-backdrop.jx-dialog-closing .jx-dialog{animation:none!important}}

/* Formula editor and nested print-studio confirmations are also floating windows. */
.jx-logic-head{height:auto;min-height:82px;background:var(--jx-float-title-bg);border-bottom:1px solid var(--jx-float-title-border);padding:10px 20px;gap:14px}
.jx-logic-title-block{display:grid;gap:3px;min-width:0;flex:1}
.jx-logic-title-block>.jx-designer-float-title{display:flex;align-items:center;gap:13px;min-width:0}
.jx-logic-title-block>.tiny{padding-left:55px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.jx-logic-close{display:grid;place-items:center;flex:none;width:36px;height:36px;padding:7px;background:transparent;border:1px solid transparent;border-radius:10px;color:var(--jx-ui-muted,#6f829a);cursor:pointer}
.jx-logic-close svg{display:block;width:20px;height:20px}
.jx-logic-close:hover{background:var(--jx-ui-soft,#edf4ff);border-color:var(--jx-ui-border,#dce7f7);color:var(--jx-ui-accent,#286bce)}
.jx-logic-close:focus-visible{outline:2px solid var(--jx-ui-accent,#3479d5);outline-offset:2px}
.jx-ps-modal{padding:0;overflow:hidden}
.jx-ps-modal-head{display:flex;align-items:center;gap:12px;min-height:75px;padding:13px 18px;background:var(--jx-float-title-bg);border-bottom:1px solid var(--jx-float-title-border)}
.jx-ps-modal-mark{display:grid;place-items:center;flex:none;width:42px;height:42px;border-radius:12px;background:var(--jx-ui-soft,#edf4ff);border:1px solid var(--jx-float-title-border);color:var(--jx-ui-accent,#286bce)}
.jx-ps-modal-mark svg{display:block;width:22px;height:22px}
.jx-ps-modal-heading{display:grid;gap:5px;flex:1;min-width:0}
.jx-ps-modal-heading small{font-size:10px;font-weight:760;line-height:1.2;letter-spacing:1.6px;color:var(--jx-ui-muted,#8494ac)}
.jx-ps-modal-heading h3{margin:0;white-space:normal;font-size:17px;line-height:1.3}
.jx-ps-modal-close{display:grid;place-items:center;flex:none;width:36px;height:36px;padding:7px;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--jx-ui-muted,#72829a);cursor:pointer}
.jx-ps-modal-close svg{display:block;width:20px;height:20px}
.jx-ps-modal-close:hover{background:var(--jx-ui-soft,#edf4ff);border-color:var(--jx-ui-border,#d9e7f8)}
.jx-ps-modal-close:focus-visible{outline:2px solid var(--jx-ui-accent,#3479d5);outline-offset:2px}
.jx-ps-modal-content{padding:17px 20px 7px}
.jx-ps-modal-content:empty{display:none}
.jx-ps-modal .jx-ps-modal-content p{margin:0 0 12px}
.jx-ps-modal-actions{padding:12px 20px 18px}
@media(max-width:560px){.jx-logic-head{padding:10px 12px;min-height:72px}.jx-logic-title-block>.tiny{padding-left:0}.jx-ps-modal-head{min-height:66px;padding:10px 14px}.jx-ps-modal-mark{width:36px;height:36px}}

@media(max-width:560px){.jx-dialog .jx-dialog-heading{padding-right:30px}.jx-dialog .jx-dialog-close{top:11px;right:10px}}
