/* Employee workbench: one local layout, preserving account rules and the existing drawer. */
@layer erp-reconstruction {
  @media screen {
    body[data-module=employees] :is(.module-banner,.module-summary,.module-flow-rail,.business-workspace) { display: none !important; }
    #employee-management-panel {
      --employee-line: #d7e1ef;
      --employee-ink: #213047;
      --employee-muted: #53647a;
      min-width: 0 !important;
      color: var(--employee-ink) !important;
      background: #fff !important;
      font: 15px/1.6 "Microsoft YaHei",sans-serif !important;
      font-variant-numeric: tabular-nums;
      border-radius:0!important;box-shadow:none!important;
    }
    #employee-management-panel:not([hidden]) {
      display: flex !important;
      flex-direction: column !important;
      min-height: 0 !important;
      height: auto !important;
      padding: 20px 24px 24px !important;
      overflow-x: hidden !important;
      overflow-y: auto !important;
      scroll-padding-block: 12px !important;
    }
    #employee-management-panel[hidden],
    #employee-management-panel [hidden],
    #employee-management-panel .employee-empty[hidden],
    #employee-management-panel .employee-action-row :is(button,select)[hidden] { display: none !important; }
    #employee-management-panel * { box-sizing: border-box !important; }
    #employee-management-panel .employee-page-heading{display:flex!important;align-items:start;justify-content:space-between;gap:20px;position:static!important;height:auto!important;padding:0!important;margin:0 0 20px;background:none!important}
    #employee-management-panel .employee-page-heading h2{font-size:24px!important;line-height:1.4;margin:0 0 6px}
    #employee-management-panel .employee-page-heading p{font-size:14px!important;color:#53647a;line-height:1.6;margin:0;max-width:75ch}
    #employee-management-panel .employee-page-heading a{display:inline-flex;align-items:center;min-height:44px;white-space:nowrap;color:#245ca7;text-underline-offset:3px}
    #employee-management-panel .employee-settings-navigation{display:flex;flex-wrap:wrap;gap:6px 16px;border-bottom:1px solid #d7e1ef;margin-bottom:20px}
    #employee-management-panel .employee-settings-navigation button{border:0!important;border-radius:0!important;background:none!important;color:#53647a;padding:10px 4px!important}
    #employee-management-panel .employee-settings-navigation [aria-current=page]{border-bottom:2px solid #245ca7!important;color:#245ca7}

    #employee-management-panel .employee-management-workspace {
      display: flex !important;
      flex: 1 1 auto;
      flex-direction: column !important;
      grid-template-rows: none !important;
      gap: 0 !important;
      min-width: 0 !important;
      min-height: 0 !important;
      height: auto !important;
      padding: 0 !important;
      overflow: visible !important;
    }
    #employee-management-panel :is(button,input,select) {
      min-width: 0 !important;
      min-height: 44px !important;
      height: auto !important;
      max-width: 100% !important;
      font: 15px/1.5 "Microsoft YaHei",sans-serif !important;
      border-radius: 6px !important;
    }
    #employee-management-panel button { padding: 8px 12px !important; cursor: pointer; }
    #employee-management-panel button:disabled { cursor: not-allowed; }
    #employee-management-panel :focus-visible { outline: 2px solid #245ca7 !important; outline-offset: 3px !important; }
    #employee-management-panel input { caret-color: #245ca7; }
    #employee-management-panel input::placeholder { color: #586b85; opacity: 1; }
    #employee-management-panel ::selection { color: #173b7a; background: #dceaff; }
    #employee-management-panel input[type=checkbox] { width: 24px !important; height: 24px !important; min-height: 24px !important; accent-color: #245ca7; }
    #employee-management-panel .employee-query-row {
      display: flex !important;
      flex: 0 0 auto;
      flex-wrap: wrap !important;
      align-items: flex-end !important;
      gap: 12px !important;
      height: auto !important;
      min-height: 0 !important;
      margin: 0 !important;
      padding: 0 0 16px !important;
      border: 0 !important;
      border-bottom: 1px solid var(--employee-line) !important;
    }
    #employee-management-panel .employee-query-row > label {
      display: grid !important;
      flex: 0 1 200px !important;
      gap: 6px !important;
      min-width: 0 !important;
      margin: 0 !important;
      color: var(--employee-muted) !important;
      font-size: 14px !important;
      line-height: 1.5 !important;
    }
    #employee-management-panel .employee-query-row > label:first-child { flex: 1 1 360px !important; }
    #employee-management-panel .employee-query-row :is(input,select) { width: 100% !important; min-width: 0 !important; padding: 8px 12px !important; }
    #employee-management-panel #employee-search { flex: 0 0 auto; width: auto !important; min-width: 72px !important; align-self: flex-end !important; }
    #employee-management-panel .employee-action-row {
      display: flex !important;
      flex: 0 0 auto;
      flex-wrap: wrap !important;
      align-items: center !important;
      justify-content: space-between !important;
      gap: 12px !important;
      min-height: 0 !important;
      height: auto !important;
      margin: 0 !important;
      padding: 12px 0 !important;
      border: 0 !important;
    }
    #employee-management-panel .employee-action-row > div { display: flex !important; flex-wrap: wrap !important; align-items: center; gap: 8px !important; min-width: 0; }
    #employee-management-panel .employee-action-row :is(button,select):not([hidden]) { display: inline-flex !important; align-items: center !important; }
    #employee-management-panel #employee-help { align-self: center !important; margin: 0 !important; border: 1px solid #c8d5e6 !important; }
    #employee-management-panel .employee-table-wrap {
      position: relative !important;
      display: block !important;
      flex: 0 0 auto;
      min-width: 0 !important;
      min-height: 0 !important;
      max-height: min(60vh,640px) !important;
      height: auto !important;
      overflow: auto !important;
      border: 1px solid var(--employee-line) !important;
      scrollbar-color: #a4b3c6 #f1f4f8;
      scrollbar-gutter: stable;
    }

    #employee-management-panel .employee-table {
      display: table !important;
      width: 100% !important;
      min-width: 850px !important;
      table-layout: auto !important;
      border-collapse: collapse !important;
      color: var(--employee-ink) !important;
    }
    #employee-management-panel .employee-table thead { display: table-header-group !important; }
    #employee-management-panel .employee-table tbody { display: table-row-group !important; }
    #employee-management-panel .employee-table tr { display: table-row !important; height: auto !important; }
    #employee-management-panel .employee-table :is(th,td) {
      display: table-cell !important;
      height: auto !important;
      padding: 12px 10px !important;
      color: var(--employee-ink) !important;
      font-size: 15px !important;
      line-height: 1.6 !important;
      vertical-align: middle !important;
      border-color: var(--employee-line) !important;
      white-space: nowrap !important;
    }
    #employee-management-panel .employee-table th { background: #edf3fc !important; font-weight: 600 !important; }
    #employee-management-panel .employee-table :is(th,td):first-child{width:48px!important;text-align:center!important}
    #employee-management-panel .employee-table :is(th,td):nth-child(2){min-width:220px!important;white-space:normal!important}
    #employee-management-panel .employee-table td strong{display:block;font-size:15px!important}
    #employee-management-panel .employee-table td small{display:block;font-size:14px!important;line-height:1.6;color:#53647a;margin-top:4px;overflow-wrap:anywhere}
    #employee-management-panel .employee-table .employee-row-actions { white-space: nowrap !important; }
    #employee-management-panel .employee-row-actions button {
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      width: auto !important;
      min-width: 52px !important;
      min-height: 44px !important;
      padding: 8px !important;
      margin: 0 4px 0 0 !important;
      border: 1px solid #c8d5e6 !important;
      color: #245ca7 !important;
      background: #fff !important;
    }
    #employee-management-panel .employee-row-actions button:last-child { margin-right: 0 !important; }
    #employee-management-panel .employee-row-actions button:disabled { color: #697a91 !important; background: #f0f3f7 !important; }
    #employee-management-panel .employee-empty {
      position: relative !important;
      inset: auto !important;
      display: grid !important;
      place-content: center !important;
      justify-items: center !important;
      min-height: 180px !important;
      height: auto !important;
      gap: 8px !important;
      padding: 24px !important;
      border: 0 !important;
      border-radius: 0 !important;
      color: var(--employee-muted) !important;
      background: #fff !important;
      text-align: center !important;
      white-space: normal !important;
    }
    #employee-management-panel .employee-empty strong { color: var(--employee-ink) !important; font-size: 15px !important; }
    #employee-management-panel .employee-empty span { display: grid !important; justify-items: center; gap: 12px; max-width: 100%; color: var(--employee-muted) !important; font-size: 14px !important; line-height: 1.6; overflow-wrap: anywhere; }
    #employee-management-panel .employee-table-wrap:has(> .employee-empty:not([hidden])) > table { display: none !important; }
    #employee-management-panel .employee-license-row {
      display: flex !important;
      flex: 0 0 auto;
      flex-wrap: wrap !important;
      align-items: center !important;
      justify-content: space-between !important;
      gap: 8px 20px !important;
      min-height: 0 !important;
      height: auto !important;
      margin: 0 !important;
      padding: 16px 0 !important;
      border: 0 !important;
      border-bottom: 1px solid var(--employee-line) !important;
      color: var(--employee-muted) !important;
      font-size: 14px !important;
      line-height: 1.6 !important;
      white-space: normal !important;
    }
    #employee-management-panel .employee-license-row span { display: inline !important; min-width: 0; overflow-wrap: anywhere; }
    #employee-management-panel .employee-license-row b { color: var(--employee-ink) !important; font-weight: 600 !important; }
    #employee-management-panel .employee-pagination {
      display: flex !important;
      flex: 0 0 auto;
      flex-wrap: wrap !important;
      align-items: center !important;
      justify-content: flex-end !important;
      gap: 12px !important;
      height: auto !important;
      min-height: 0 !important;
      margin: 0 !important;
      padding: 16px 0 0 !important;
      position: static !important;
      color: var(--employee-muted) !important;
      font-size: 14px !important;
      white-space: normal !important;
    }
    #employee-management-panel .employee-pagination > :is(span,div) { min-width: 0; max-width: 100%; }
    #employee-management-panel .employee-pagination > div { display: flex !important; align-items: center; gap: 8px !important; }
    #employee-management-panel .employee-pagination :is(button,b) { display: inline-grid; place-items: center; min-width: 44px !important; min-height: 44px !important; height: auto !important; font-size: 15px !important; }

    @media (max-width: 767px) {
      #employee-management-panel:not([hidden]) { padding: 16px 12px 24px !important; }
      #employee-management-panel .employee-management-workspace { flex: 0 0 auto; }
      #employee-management-panel .employee-query-row { display: grid !important; grid-template-columns: minmax(0,1fr) 88px !important; gap: 12px !important; }
      #employee-management-panel .employee-query-row > label { width: 100% !important; }
      #employee-management-panel .employee-query-row > label:first-child { grid-column: 1 / -1 !important; }
      #employee-management-panel #employee-search { width: 100% !important; min-width: 0 !important; }
      #employee-management-panel .employee-action-row { align-items: stretch !important; }
      #employee-management-panel .employee-action-row > div { width: 100%; }
      #employee-management-panel .employee-action-row > div > :is(button,select):not([hidden]) { flex: 1 1 140px; justify-content: center; white-space: normal; }
      #employee-management-panel #employee-help { width: 100% !important; justify-content: center; }
      #employee-management-panel .employee-table-wrap { flex: 0 0 auto; min-height: 0 !important; max-height: none !important; overflow: visible !important; border: 0 !important; scrollbar-gutter: auto; }

      #employee-management-panel .employee-table,
      #employee-management-panel .employee-table tbody { display: block !important; width: 100% !important; min-width: 0 !important; border: 0 !important; }
      #employee-management-panel .employee-table thead { display: none !important; }
      #employee-management-panel .employee-table tbody tr { display: grid !important; grid-template-columns: minmax(0,1fr) !important; gap: 0 !important; height: auto !important; margin: 0 !important; padding: 16px 0 !important; border: 0 !important; border-bottom: 1px solid var(--employee-line) !important; border-radius: 0 !important; background: #fff !important; box-shadow: none !important; }
      #employee-management-panel .employee-table tbody td:nth-child(n) { display: grid !important; grid-template-columns: 100px minmax(0,1fr) !important; grid-column: auto !important; grid-row: auto !important; gap: 12px !important; position: static !important; justify-self: stretch !important; width: auto !important; min-width: 0 !important; height: auto !important; padding: 5px 0 !important; border: 0 !important; color: var(--employee-ink) !important; font-weight: 400 !important; text-align: left !important; white-space: normal !important; overflow: visible !important; text-overflow: clip !important; overflow-wrap: anywhere !important; }
      #employee-management-panel .employee-table tbody td::before { color: var(--employee-muted) !important; font-size: 14px !important; margin: 0 !important; }
      #employee-management-panel .employee-table tbody td:first-child{align-items:center;min-height:44px}
      #employee-management-panel .employee-table tbody td:first-child::before{content:"选择"!important}
      #employee-management-panel .employee-table tbody td:nth-child(2){display:block!important;min-width:0!important;padding:8px 0!important}
      #employee-management-panel .employee-table tbody td:nth-child(2)::before{content:none!important}
      #employee-management-panel .employee-table tbody td:nth-child(3)::before{content:"业务角色"!important}
      #employee-management-panel .employee-table tbody td:nth-child(4)::before{content:"账号状态"!important}
      #employee-management-panel .employee-table tbody td:nth-child(5)::before{content:"首次设密"!important}
      #employee-management-panel .employee-table tbody td:nth-child(6)::before{content:"建档日期"!important}
      #employee-management-panel .employee-table tbody td:nth-child(7){display:flex!important;flex-wrap:wrap!important;gap:8px!important;padding-top:12px!important}
      #employee-management-panel .employee-table tbody td:nth-child(7)::before{content:"操作"!important;flex:1 0 100%}
      #employee-management-panel .employee-page-heading{flex-direction:column;gap:8px}
      #employee-management-panel .employee-row-actions button { margin: 0 !important; }
      #employee-management-panel .employee-license-row { flex-direction: column; align-items: flex-start !important; }
      #employee-management-panel .employee-pagination { justify-content: space-between !important; }
      #employee-management-panel #employee-page-summary { flex: 1 1 100%; }
      #employee-management-panel .employee-pagination > div { margin-left: auto; }
    }
  }
}
