/* C · 栅格仪表盘. User reference: 布局参考/oa-workbench-layouts.html.
Craft guidance: unslop by Damir Sokolovsky (@heydamir), CC BY 4.0.
Shared shell tokens own the visual system; workspaces retain business semantics. */
:root {
  --glass:rgba(255,255,255,.66);
  --glass2:rgba(255,255,255,.88);
  --stroke:rgba(255,255,255,.94);
  --ink:#1A2340;
  --ink2:#4C5872;
  --ink-2:var(--ink2);
  --muted:#92A0BA;
  --line:rgba(110,130,180,.14);
  --accent:#5C6CF0;
  --accent2:#38BCC9;
  --ok:#1FA481;
  --warn:#C68A2C;
  --bad:#D26262;
  --surface:rgba(255,255,255,.78);
  --canvas:#f2f5fc;
  --blue:#6155de;
  --teal:#149b86;
  --orange:#b87b24;
  --red:#c34654;
  --shadow:0 18px 44px rgba(76,96,152,.12),0 2px 8px rgba(76,96,152,.05);
  --company-accent:var(--accent);
  --company-accent-hover:#5147ca;
  --company-soft:#eeedff;
  --company-sidebar-width:0px;
  --company-drawer-width:280px;
  --company-header-height:96px;
  --glass-surface:var(--glass);
  --glass-border:var(--stroke);
  --glass-shadow:var(--shadow);
  --glass-radius:20px;
  --company-font:"Inter","SF Pro Display","PingFang SC","Microsoft YaHei",sans-serif;
}
.sr-only {
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip-path:inset(50%);
  white-space:nowrap;
  border:0
}
body.factory-shell {
  color:var(--ink);
  font-family:var(--company-font);
  font-variant-numeric:tabular-nums;
  background:linear-gradient(135deg,#EBE7FF 0%,#DFF0FF 33%,#E4F8F0 67%,#FFE9F3 100%);
  background-attachment:scroll;
  min-height:100vh;
  overflow-x:clip;
  isolation:isolate;
  --factory-ink:var(--ink);
  --factory-secondary:var(--muted);
  --factory-line:var(--line);
  --factory-blue:var(--company-accent)
}
body.factory-shell::before {
  content:"";
  position:fixed;
  inset:-12%;
  z-index:-1;
  pointer-events:none;
  filter:blur(46px);
  opacity:.85;
  background:radial-gradient(38% 42% at 14% 16%,rgba(140,138,255,.30),transparent 72%),
             radial-gradient(36% 40% at 84% 18%,rgba(86,196,232,.26),transparent 72%),
             radial-gradient(40% 40% at 74% 84%,rgba(104,222,188,.24),transparent 72%),
             radial-gradient(34% 38% at 20% 84%,rgba(255,168,204,.22),transparent 72%);
}
body.factory-shell .topbar {
  height:64px;
  min-height:64px;
  max-width:none;
  width:calc(100% - 48px);
  margin:16px auto 0;
  padding:0 16px;
  gap:12px;
  top:16px;
  z-index:40;
  border:1px solid var(--glass-border);
  border-radius:20px;
  background:rgba(255,255,255,.67);
  backdrop-filter:blur(22px);
  box-shadow:var(--glass-shadow)
}
body.factory-shell .topbar>.brand {
  display:flex;
  gap:10px;
  min-width:0;
  flex:none;
  white-space:nowrap;
  color:var(--ink);
  font-size:15px
}
body.factory-shell .brand-mark {
  height:36px;
  width:36px;
  border-radius:12px;
  flex:none;
  background:rgba(255,255,255,.92);
  display:grid;
  place-items:center;
  padding:3px
}
body.factory-shell .brand-mark img {
  width:30px;
  height:30px;
  object-fit:contain;
  display:block
}
.brand-copy {
  display:flex;
  flex-direction:column;
  line-height:1.45
}
.brand-copy b {
  font-size:16px;
  font-weight:600
}
.brand-copy small {
  color:var(--muted);
  font-size:13px;
  letter-spacing:0
}
body.factory-shell .env-badge,body.factory-shell .identity-control {
  display:none
}
.company-topnav {
  display:flex;
  align-items:center;
  gap:2px;
  min-width:0;
  margin-left:12px
}
.company-topnav a {
  font-size:14px;
  color:var(--ink-2);
  text-decoration:none;
  white-space:nowrap;
  padding:9px 12px;
  border-radius:24px;
  transition:color .16s,background-color .16s
}
.company-topnav a:hover {
  background:rgba(235,237,249,.76);
  color:var(--ink)
}
.company-topnav a[aria-current=page] {
  background:#2b344b;
  color:#fff
}
body.factory-shell .mobile-menu {
  display:grid;
  flex:none;
  width:30px;
  height:34px;
  border-radius:10px;
  color:#64718f;
  background:rgba(255,255,255,.52)
}
body.factory-shell .top-actions {
  margin-left:auto;
  gap:8px;
  min-width:0;
  flex:none
}
.platform-date {
  font-size:13px;
  color:var(--muted);
  white-space:nowrap
}
body.factory-shell #accountSessionLabel {
  font-size:13px;
  color:var(--ink-2);
  max-width:192px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis
}
body.factory-shell .top-actions .btn {
  height:32px;
  min-height:32px;
  font-size:13px;
  padding:0 12px;
  border-radius:12px
}
.avatar {
  background:#e8e6ff;
  color:#6155de;
  width:32px;
  height:32px;
  flex:none
}
body.factory-shell .main-content,body.factory-shell.oa-active .main-content {
  width:calc(100% - 48px);
  max-width:none;
  min-width:0;
  margin:24px auto 0;
  padding:0 0 40px;
  padding-inline:0!important
}
body.factory-shell .workspace-tabs {
  width:calc(100% - 48px);
  max-width:none;
  height:44px;
  margin:12px auto 0;
  padding:0 12px;
  top:92px;
  z-index:30;
  background:rgba(255,255,255,.45);
  backdrop-filter:blur(20px);
  border:1px solid rgba(255,255,255,.8);
  border-radius:14px
}
body.factory-shell .workspace-tab-item {
  border:0;
  background:transparent;
  border-radius:10px;
  margin:4px 0
}
body.factory-shell .workspace-tab-item.is-active {
  background:var(--company-soft);
  box-shadow:inset 0 0 0 1px #d6d1f5
}
body.factory-shell .workspace-tab-item>a {
  font-size:14px;
  color:var(--ink-2)
}
body.factory-shell .workspace-tab-item.is-active>a {
  color:var(--company-accent)
}
body.factory-shell :is(.workspace-tab-close,.workspace-tab-scroll,.workspace-tab-menu>summary) {
  color:var(--muted)
}
body.factory-shell .sidebar {
  display:flex;
  position:fixed;
  top:12px;
  left:12px;
  bottom:12px;
  width:min(var(--company-drawer-width),calc(100vw - 40px));
  max-width:calc(100vw - 40px);
  padding:20px 14px;
  z-index:75;
  background:rgba(252,253,255,.97);
  backdrop-filter:blur(24px);
  border:1px solid var(--glass-border);
  border-radius:20px;
  color:var(--ink);
  box-shadow:12px 16px 60px rgba(40,48,85,.12);
  transform:translateX(calc(-100% - 24px));
  visibility:hidden;
  pointer-events:none;
  transition:transform .2s ease,visibility .2s
}
body.factory-shell .sidebar.open {
  transform:translateX(0);
  visibility:visible;
  pointer-events:auto
}
.company-drawer-head {
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
  margin:0 8px 20px
}
.company-drawer-head strong {
  font-weight:600;
  font-size:16px
}
.company-drawer-head span {
  display:block;
  font-size:11px;
  color:#929bb0;
  margin-top:4px
}
.company-drawer-head .icon-btn {
  font-size:24px
}
.sidebar-brand {
  display:none!important
}
.company-drawer-backdrop {
  position:fixed;
  inset:0;
  z-index:70;
  background:rgba(45,54,85,.2);
  backdrop-filter:blur(3px);
  cursor:default
}
.company-drawer-backdrop[hidden] {
  display:none
}
body.factory-shell.company-drawer-open {
  overflow:hidden
}
body.factory-shell .sidebar-caption {
  color:#98a1b6;
  font-size:10px;
  font-weight:500;
  margin:12px 10px 8px;
  letter-spacing:.2px
}
body.factory-shell .main-nav {
  flex:1;
  min-height:0;
  overflow:auto;
  gap:2px;
  scrollbar-width:thin;
  scrollbar-color:#d8dcef transparent
}
body.factory-shell .nav-item {
  height:36px;
  min-height:36px;
  padding:0 10px;
  margin:0;
  border-radius:10px;
  gap:10px;
  color:var(--ink-2);
  font-size:14px
}
.nav-item .nav-icon {
  width:18px;
  display:grid;
  place-items:center;
  color:inherit
}
.nav-item .nav-icon svg {
  height:16px;
  width:16px
}
body.factory-shell .nav-item:hover {
  color:var(--company-accent);
  background:#f1f0ff
}
body.factory-shell .nav-item.active {
  background:#ebe9fd;
  color:var(--company-accent);
  font-weight:600
}
body.factory-shell .nav-item em {
  background:#f0f1f8;
  color:var(--muted);
  font-size:12px
}
.factory-nav-tools {
  border-top:1px solid #e6e9f2;
  margin-top:12px;
  padding-top:8px
}
.factory-nav-tools summary,.factory-nav-group {
  font-size:13px;
  color:var(--muted);
  padding:10px;
  cursor:pointer
}
body.factory-shell .scope-box {
  border:1px solid #e2e6f1;
  background:rgba(244,246,253,.8);
  border-radius:12px;
  height:auto;
  min-height:54px;
  padding:10px;
  font-size:12px
}
.scope-box b {
  color:var(--ink-2)
}
.scope-box small,.sidebar-footer {
  color:var(--muted);
  font-size:13px
}
.scope-dot {
  width:6px;
  height:6px;
  background:#7a71e2
}
.company-drawer-account {
  padding:12px 0 0
}
.company-drawer-account>.btn {
  width:100%
}
.sidebar-footer {
  font-size:13px;
  border-top:0;
  padding:12px 8px 0;
  line-height:1.7
}
body.factory-shell .btn,body.factory-shell :is(.fp-primary,.fp-secondary) {
  border-radius:12px;
  min-height:36px;
  font-size:14px;
  font-weight:500;
  box-shadow:none;
  transition:background-color .15s,border-color .15s,color .15s
}
body.factory-shell .btn.primary,body.factory-shell .fp-primary {
  background:var(--company-accent);
  border:1px solid var(--company-accent);
  color:#fff;
  box-shadow:0 5px 12px rgba(96,85,223,.12)
}
body.factory-shell .btn.primary:hover,body.factory-shell .fp-primary:hover {
  background:var(--company-accent-hover);
  border-color:var(--company-accent-hover)
}
body.factory-shell .btn.outline,body.factory-shell .fp-secondary {
  background:rgba(255,255,255,.72);
  border:1px solid #e0e4f0;
  color:var(--ink-2)
}
body.factory-shell .btn.outline:hover,body.factory-shell .fp-secondary:hover {
  background:#fff;
  border-color:#cfcbea;
  color:#6155de
}
body.factory-shell :focus-visible {
  outline:2px solid #8e86e5;
  outline-offset:3px
}
body.factory-shell :is(input,select,textarea) {
  accent-color:var(--company-accent)
}
body.factory-shell :is(input:not([type=checkbox]):not([type=radio]),select,textarea) {
  border-color:#dce2ef;
  color:var(--ink);
  border-radius:9px;
  background-color:rgba(255,255,255,.82);
  max-width:100%;
  min-width:0;
  box-sizing:border-box
}
body.factory-shell :is(input,select,textarea):focus-visible {
  outline-offset:-2px
}
body.factory-shell .page-head {
  gap:20px;
  margin-bottom:20px
}
body.factory-shell .page-head h1 {
  font-size:26px;
  font-weight:600;
  color:var(--ink)
}
body.factory-shell .page-head p {
  color:var(--muted);
  font-size:14px
}
body.factory-shell .workspace-card {
  background:var(--glass-surface);
  border:1px solid var(--glass-border);
  border-radius:var(--glass-radius);
  box-shadow:var(--glass-shadow)
}
body.factory-shell :is(.office-empty,.office-task-panel,.office-scope-recovery,.ons-editor,.ons-empty,.ons-gate,.org-editor) {
  background:var(--glass-surface);
  border:1px solid var(--glass-border);
  border-radius:var(--glass-radius);
  box-shadow:var(--glass-shadow)
}
body.factory-shell :is(.office-tabs,.org-tabs,.oa-tabs) {
  border-color:#e0e5f0
}
body.factory-shell .office-tabs a[aria-current=page] {
  color:var(--company-accent);
  border-color:var(--company-accent)
}
body.factory-shell .office-counts button {
  background:var(--glass-surface);
  border:1px solid var(--glass-border);
  border-radius:18px;
  box-shadow:var(--glass-shadow)
}
body.factory-shell .office-counts b {
  color:var(--ink);
  font-weight:600
}
body.factory-shell .office-counts button.selected {
  border-color:#ada5ee;
  background:#f7f5ff
}
body.factory-shell .org-editor {
  padding:24px;
  border-radius:20px
}
body.factory-shell .org-editor .text-button {
  display:inline-flex;
  vertical-align:bottom;
  align-items:center;
  min-height:36px;
  margin-left:12px;
  color:var(--company-accent-hover)
}
body.factory-shell .org-navigation button[aria-current="page"] {
  background:#ece9fd;
  color:var(--company-accent-hover)
}
body.factory-shell .org-person {
  background:rgba(255,255,255,.58);
  border:1px solid rgba(255,255,255,.9);
  border-radius:16px;
  padding:18px;
  margin-bottom:14px
}
body.factory-shell #platformSessionDialog {
  background:rgba(255,255,255,.97);
  backdrop-filter:blur(24px)
}
body.factory-shell .ons-root {
  color:var(--ink)
}
body.factory-shell .ons-groups>button {
  border-radius:14px;
  background:rgba(255,255,255,.64);
  border-color:var(--glass-border)
}
body.factory-shell .ons-groups>button[aria-current=page] {
  background:#eeecff;
  border-color:#d1cbef
}
body.factory-shell .ons-status {
  color:var(--muted)
}
body.factory-shell #oaWorkspace {
  --oa-ink:var(--ink);
  --oa-secondary:var(--ink-2);
  --oa-muted:var(--muted);
  --oa-line:var(--line);
  --oa-accent:var(--company-accent);
  --oa-canvas:transparent
}
body.factory-shell #engineeringWorkspace {
  --eng-ink:var(--ink);
  --eng-muted:var(--muted);
  --eng-line:var(--line);
  --eng-accent:var(--company-accent)
}
body.factory-shell #organizationWorkspace {
  --org-text:var(--ink);
  --org-secondary:var(--ink-2);
  --org-muted:var(--muted);
  --org-accent:var(--company-accent)
}
body.factory-shell :is(#collaborationPage,.coop-dialog) {
  --coop-ink:var(--ink);
  --coop-secondary:var(--ink-2);
  --coop-muted:var(--muted);
  --coop-line:var(--line);
  --coop-accent:var(--company-accent)
}
body.factory-shell .coop-dialog {
  border:1px solid #eceefa;
  border-radius:20px;
  box-shadow:0 24px 80px rgba(59,67,106,.15)
}
body.factory-shell .coop-dialog[data-kind=login] {
  width:min(440px,calc(100vw - 32px))
}
.company-login-brand {
  display:flex;
  align-items:center;
  gap:14px;
  margin-bottom:20px
}
.company-login-brand img {
  object-fit:contain
}
.company-login-brand b {
  display:block;
  font-size:18px
}
.company-login-brand span {
  display:block;
  font-size:13px;
  color:var(--muted);
  margin-top:4px
}
body.factory-shell.schedule-dense .main-content {
  width:calc(100% - 24px);
  max-width:none;
  margin:8px auto 0;
  padding:0 0 24px
}
body.factory-shell.schedule-dense .topbar {
  width:calc(100% - 24px);
  margin-top:12px;
  top:12px;
  border-radius:16px
}
body.factory-shell.schedule-dense .workspace-tabs {
  width:calc(100% - 24px);
  margin:8px auto 0;
  top:84px;
  border-radius:12px
}
body.factory-shell .production-workspace {
  background:rgba(255,255,255,.92);
  border-color:#e3e6f1;
  border-radius:16px
}
body.factory-shell #schedulePage .production-filters {
  flex-wrap:wrap;
  max-width:100%;
  background:rgba(251,252,255,.94);
  gap:10px
}
body.factory-shell #schedulePage .production-filters .page-actions {
  flex-wrap:wrap;
  min-width:0;
  max-width:100%
}
body.factory-shell :is(.production-table-wrap,.table-wrap,.office-table-scroll) {
  max-width:100%;
  overflow:auto
}
body.factory-shell #schedulePage .production-table th {
  background:#f1f3fa;
  color:var(--ink-2)
}
body.factory-shell #schedulePage .production-table {
  background:rgba(255,255,255,.96)
}
body.factory-shell #scheduleFullscreenButton[aria-pressed=true] {
  background:#ece9ff;
  border-color:#c7c0ef;
  color:var(--company-accent)
}
body.factory-shell .quick-schedule-row.has-work-order-notes>td:first-child {
  background:#f1f6ff;
  box-shadow:inset 3px 0 #9a91e1
}
body.factory-shell .order-note-marker.has-notes {
  background:#f2f0fc;
  border:1px solid #d9d3ee;
  border-radius:5px;
  color:#7565b0;
  padding:2px 6px
}
body.factory-shell.schedule-maximized :is(.topbar,.sidebar,.workspace-tabs) {
  display:none
}
body.factory-shell.schedule-maximized .main-content {
  margin:0;
  width:100%;
  max-width:none;
  min-height:100dvh;
  padding:8px!important
}
body.factory-shell.schedule-maximized #schedulePage>.page-head {
  display:none
}
body.factory-shell.schedule-maximized #schedulePage .production-filters {
  position:sticky;
  top:0;
  z-index:15;
  background:#fff
}
/* Native production keeps its table dimensions and semantic alert colors. */
body.factory-shell .production-daily-root :is(.top,.stat-bar,.sheet,.footnote) {
  background:var(--glass-surface);
  border:1px solid var(--glass-border);
  border-radius:18px;
  box-shadow:var(--glass-shadow)
}
body.factory-shell .production-daily-root .top {
  padding:16px;
  margin-bottom:14px;
  gap:12px
}
body.factory-shell .production-daily-root .top>.title {
  color:var(--ink);
  font-weight:600;
  font-size:23px
}
body.factory-shell .production-daily-root .top button {
  background:var(--company-accent);
  color:#fff;
  border:1px solid var(--company-accent);
  border-radius:10px;
  padding:7px 14px;
  font-size:12px
}
body.factory-shell .production-daily-root .top button.btn-refresh,body.factory-shell .production-daily-root .top .line-picker-toggle {
  background:rgba(255,255,255,.8);
  color:#7b72bd;
  border:1px solid #dfdaf2
}
body.factory-shell .production-daily-root .top a {
  color:var(--company-accent-hover);
  font-size:13px
}
body.factory-shell .production-daily-root .sheet {
  padding:18px;
  margin-bottom:14px
}
body.factory-shell .production-daily-root .sheet-head {
  border-color:#e2dff3
}
body.factory-shell .production-daily-root .mini-btn,body.factory-shell .production-daily-root .quality-trend-heading button {
  border:1px solid #dfdaf2;
  border-radius:10px;
  background:rgba(255,255,255,.76);
  color:#877bc2;
  font-size:12px;
  padding:7px 12px
}
body.factory-shell .production-daily-root .btn-export {
  background:var(--company-accent);
  border-color:var(--company-accent);
  color:#fff
}
body.factory-shell .production-daily-root .chart-panel {
  border-color:#e7e8f3;
  border-radius:14px;
  background:rgba(255,255,255,.8)
}
body.factory-shell .production-daily-root .modal-box {
  border:1px solid #eef0f8;
  border-radius:20px;
  box-shadow:0 24px 80px rgba(55,65,112,.15)
}
body.factory-shell .production-daily-root .stat-bar {
  color:var(--muted)
}
body.factory-shell .production-daily-root .footnote {
  padding:10px 16px;
  color:var(--muted)
}
body.factory-shell #productionDailyWorkspace,.production-daily-root {
  min-width:0;
  max-width:100%
}
.production-daily-root {
  --bg:transparent;
  --card:rgba(255,255,255,.86);
  --primary:var(--company-accent);
  --text:var(--ink)
}
body.factory-shell .ons-runtime {
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin:0 0 20px;
  font-size:13px;
  color:var(--muted)
}
.meeting-notes-page {
  background:var(--canvas)
}
.meeting-notes-page .meeting-brand {
  display:flex;
  align-items:center;
  gap:10px;
  color:var(--ink)
}
.meeting-notes-page .meeting-brand img {
  object-fit:contain
}
.meeting-notes-page .btn.primary {
  background:var(--company-accent)
}
@media(max-width:1380px) {
  body.factory-shell .platform-date {
    display:none
  }
  .company-topnav {
    margin-left:0
  }
  .company-topnav a {
    padding:8px 9px
  }
  body.factory-shell #accountSessionLabel {
    max-width:160px
  }
}
@media(max-width:1180px) {
  .company-topnav a {
    padding:8px 9px;
    font-size:14px
  }
  .brand-copy small {
    display:none
  }
  body.factory-shell #accountSessionLabel,body.factory-shell #userAvatar {
    display:none
  }
  body.factory-shell .top-actions #accountPasswordButton {
    display:none
  }
}
@media(max-width:920px) {
  .company-topnav {
    flex:1;
    justify-content:center
  }
  .company-topnav a:nth-child(n+5) {
    display:none
  }
  .brand-copy b {
    font-size:16px
  }
  body.factory-shell .topbar {
    padding:0 12px;
    gap:10px
  }
}
@media(max-width:700px) {
  .company-topnav {
    display:none
  }
  body.factory-shell .topbar {
    width:calc(100% - 24px);
    margin-top:12px;
    top:12px;
    height:60px;
    min-height:60px;
    border-radius:16px;
    gap:10px
  }
  body.factory-shell .topbar>.brand {
    flex:1;
    min-width:0
  }
  .brand-copy b {
    font-size:16px
  }
  body.factory-shell .brand-mark {
    height:32px;
    width:32px
  }
  body.factory-shell .brand-mark img {
    height:27px;
    width:27px
  }
  body.factory-shell .top-actions {
    gap:6px
  }
  body.factory-shell .top-actions .btn {
    font-size:13px;
    padding:0 10px
  }
  body.factory-shell .workspace-tabs,body.factory-shell.schedule-dense .workspace-tabs {
    width:calc(100% - 24px);
    margin:10px auto 0;
    top:82px;
    padding:0 8px;
    height:40px;
    border-radius:12px
  }
  body.factory-shell .main-content,body.factory-shell.oa-active .main-content {
    width:calc(100% - 24px);
    margin-top:20px;
    padding-bottom:24px
  }
  body.factory-shell .page-head h1 {
    font-size:22px
  }
  body.factory-shell .page-head {
    flex-wrap:wrap;
    gap:12px
  }
  body.factory-shell .btn {
    font-size:14px;
    min-height:36px
  }
  body.factory-shell #schedulePage .production-filters>* {
    max-width:100%;
    min-width:0
  }
  body.factory-shell #schedulePage .production-filters .search-box {
    width:100%
  }
  body.factory-shell #schedulePage .production-filters .page-actions {
    gap:8px
  }
  body.factory-shell .card-head {
    padding:12px 16px;
    height:auto;
    min-height:60px;
    flex-wrap:wrap;
    gap:10px
  }
  .company-login-brand b {
    font-size:16px
  }
}
@media(max-width:380px) {
  body.factory-shell .topbar {
    padding:0 8px;
    gap:8px
  }
  body.factory-shell .topbar>.brand {
    gap:8px
  }
  .brand-copy b {
    font-size:14px
  }
  body.factory-shell .mobile-menu,body.factory-shell .brand-mark {
    width:28px
  }
  body.factory-shell .brand-mark {
    height:28px
  }
  body.factory-shell .brand-mark img {
    width:24px;
    height:24px
  }
}
@media(prefers-reduced-motion:reduce) {
  body.factory-shell *,body.factory-shell *::before,body.factory-shell *::after {
    scroll-behavior:auto!important;
    transition:none!important
  }
}
