:root {
      --bg: #f6f8fb;
      --surface: #ffffff;
      --surface-soft: #eef3f7;
      --ink: #17202a;
      --muted: #667384;
      --line: #dbe3ea;
      --blue: #2367d1;
      --green: #16895f;
      --weijia-green: #67ad03;
      --amber: #b87512;
      --red: #c7473d;
      --shadow: 0 8px 22px rgba(28, 45, 64, .05);
      --radius: 6px;
    }

    * { box-sizing: border-box; }

    body {
      margin: 0;
      min-height: 100vh;
      font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
      color: var(--ink);
      background: var(--bg);
      overflow-x: hidden;
    }

    button, input, select { font: inherit; }

    [hidden] { display: none !important; }

    .shell {
      display: grid;
      grid-template-columns: 220px minmax(0, 1fr);
      min-height: 100vh;
    }

    .sidebar {
      background: #fff;
      border-right: 1px solid var(--line);
      padding: 16px 12px;
      display: flex;
      flex-direction: column;
      gap: 16px;
    }

    .brand {
      display: flex;
      align-items: center;
      gap: 12px;
      min-height: 48px;
    }

    .mark {
      width: 38px;
      height: 38px;
      border-radius: 8px;
      display: grid;
      place-items: center;
      background: var(--ink);
      color: #fff;
      font-weight: 700;
      letter-spacing: 0;
    }

    .brand strong {
      display: block;
      font-size: 16px;
      line-height: 1.3;
    }

    .brand span {
      display: block;
      color: var(--muted);
      font-size: 12px;
      margin-top: 2px;
    }

    .nav {
      display: flex;
      flex-direction: column;
      gap: 6px;
    }

    .nav button {
      border: 0;
      background: transparent;
      color: #394656;
      display: flex;
      align-items: center;
      justify-content: space-between;
      width: 100%;
      min-height: 34px;
      border-radius: 4px;
      padding: 0 12px;
      cursor: pointer;
      text-align: left;
    }

    .nav button.active {
      background: #eef7e7;
      color: #3d7605;
      font-weight: 700;
    }

    .nav small {
      color: var(--muted);
      font-size: 11px;
    }

    .sidebar-foot {
      margin-top: auto;
      padding: 14px;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: var(--surface);
    }

    .sidebar-foot b {
      display: block;
      font-size: 13px;
      margin-bottom: 6px;
    }

    .sidebar-foot span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.7;
    }

    main {
      min-width: 0;
      display: flex;
      flex-direction: column;
    }

    .topbar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      flex-wrap: wrap;
      padding: 10px 18px 0;
      background: #fff;
      border-bottom: 1px solid var(--line);
      position: sticky;
      top: 0;
      z-index: 5;
    }

    .scope {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 0;
      min-height: 36px;
      flex: 0 0 auto;
    }

    .scope h1 {
      margin: 0;
      font-size: 18px;
      line-height: 1.25;
      white-space: nowrap;
    }

    .scope select {
      border: 1px solid var(--line);
      background: var(--surface);
      border-radius: 4px;
      height: 32px;
      padding: 0 32px 0 12px;
      color: #2d3a49;
    }

    .workbench-tabs {
      display: flex;
      align-items: center;
      gap: 2px;
      min-width: 0;
      order: 3;
      flex: 0 0 100%;
      justify-content: flex-start;
      overflow-x: auto;
      border-top: 1px solid #edf2f6;
    }

    .workbench-tabs button {
      border: 0;
      background: transparent;
      color: #3e4a59;
      min-height: 42px;
      padding: 0 14px;
      cursor: pointer;
      white-space: nowrap;
      border-bottom: 3px solid transparent;
    }

    .workbench-tabs button.active {
      color: #3d7605;
      border-bottom-color: var(--weijia-green);
      font-weight: 700;
    }

    .actions {
      display: flex;
      align-items: center;
      gap: 10px;
      flex-wrap: wrap;
      margin-left: auto;
    }

    .btn {
      border: 1px solid var(--line);
      background: var(--surface);
      color: #243142;
      border-radius: 4px;
      min-height: 32px;
      padding: 0 12px;
      cursor: pointer;
    }

    .btn.primary {
      border-color: #4f9505;
      background: #5aa10a;
      color: #fff;
      font-weight: 700;
    }

    .login-bar {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .login-bar input {
      width: 188px;
      height: 32px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
      padding: 0 10px;
      color: var(--ink);
    }

    .login-bar input[type="password"] {
      width: 128px;
    }

    .status-pill {
      min-height: 28px;
      display: inline-flex;
      align-items: center;
      border-radius: 999px;
      padding: 0 10px;
      background: #e8f0fb;
      color: #174f9d;
      font-size: 12px;
      white-space: nowrap;
    }

    .status-pill.warn {
      background: #fff3dc;
      color: #8b5708;
    }

    .status-pill.error {
      background: #fdecea;
      color: #9b3128;
    }

    .content {
      padding: 16px 18px 28px;
      display: grid;
      gap: 14px;
    }

    .summary {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 10px;
    }

    .metric {
      background: var(--surface);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      padding: 12px 14px;
      box-shadow: var(--shadow);
      min-height: 76px;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
    }

    .metric span {
      color: var(--muted);
      font-size: 13px;
    }

    .metric strong {
      font-size: 22px;
      line-height: 1;
      letter-spacing: 0;
    }

    .metric em {
      font-style: normal;
      color: var(--green);
      font-size: 12px;
    }

    .workspace,
    .workbench-grid {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 320px;
      gap: 14px;
      align-items: start;
    }

    .main-stack,
    .context-rail {
      display: grid;
      gap: 14px;
      align-items: start;
    }

    .panel {
      background: var(--surface);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
      overflow: hidden;
    }

    .panel-head {
      min-height: 46px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      padding: 0 14px;
      border-bottom: 1px solid var(--line);
    }

    .panel-head h2 {
      margin: 0;
      font-size: 16px;
      line-height: 1.35;
    }

    .segmented {
      display: flex;
      gap: 4px;
      background: var(--surface-soft);
      border-radius: 8px;
      padding: 4px;
    }

    .segmented button {
      border: 0;
      background: transparent;
      border-radius: 7px;
      min-height: 28px;
      padding: 0 10px;
      color: #526171;
      cursor: pointer;
    }

    .segmented button.active {
      background: var(--surface);
      color: var(--blue);
      font-weight: 700;
      box-shadow: 0 1px 4px rgba(26, 45, 67, .08);
    }

    .task-list { display: grid; }

    .task {
      display: grid;
      grid-template-columns: 96px minmax(0, 1fr) 132px;
      gap: 14px;
      align-items: center;
      padding: 12px 14px;
      border-bottom: 1px solid var(--line);
    }

    .task:last-child { border-bottom: 0; }

    .tag {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 26px;
      border-radius: 999px;
      padding: 0 9px;
      font-size: 12px;
      font-weight: 700;
      white-space: nowrap;
      background: #e8f0fb;
      color: #174f9d;
    }

    .tag.green { background: #e6f5ef; color: #106b4c; }
    .tag.amber { background: #fff3dc; color: #8b5708; }
    .tag.red { background: #fdecea; color: #9b3128; }
    .tag.muted { background: #eef3f7; color: #536273; }

    .task b {
      display: block;
      font-size: 14px;
      line-height: 1.35;
      margin-bottom: 5px;
    }

    .task span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .pending-task-queue {
      gap: 10px;
      margin-top: 12px;
    }

    .pending-task {
      border: 1px solid var(--line);
      border-radius: 8px;
      background: var(--surface);
    }

    .processed-task-history {
      margin-top: 14px;
      border-top: 1px solid var(--line);
    }

    .report-chart-dashboard {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      gap: 12px;
      margin-top: 14px;
      min-width: 0;
      max-width: 100%;
      width: 100%;
      box-sizing: border-box;
    }

    .report-chart-card {
      border: 1px solid var(--line);
      border-radius: 8px;
      background: var(--surface);
      padding: 14px;
      min-width: 0;
      max-width: 100%;
      box-sizing: border-box;
    }

    .report-chart-head {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 10px;
      margin-bottom: 12px;
    }

    .report-chart-head b { display: block; font-size: 14px; }
    .report-chart-head span { color: var(--muted); font-size: 12px; }
    .report-chart-value { font-size: 20px; font-weight: 800; color: var(--green); white-space: nowrap; }

    .report-bar-chart {
      display: grid;
      gap: 8px;
    }

    .report-bar-row {
      display: grid;
      grid-template-columns: 72px minmax(0, 1fr) 38px;
      gap: 8px;
      align-items: center;
      font-size: 12px;
      color: var(--muted);
    }

    .report-bar-track {
      height: 8px;
      border-radius: 999px;
      background: var(--surface-soft);
      overflow: hidden;
    }

    .report-bar-fill {
      height: 100%;
      border-radius: inherit;
      background: linear-gradient(90deg, #16a34a, #22c55e);
    }

    .report-donut-chart {
      display: grid;
      grid-template-columns: 92px minmax(0, 1fr);
      gap: 14px;
      align-items: center;
    }

    .report-donut-ring {
      width: 78px;
      height: 78px;
      border-radius: 50%;
      background: conic-gradient(#16a34a 0 52%, #2563eb 52% 80%, #f59e0b 80% 100%);
      position: relative;
    }

    .report-donut-ring::after {
      content: "";
      position: absolute;
      inset: 18px;
      border-radius: 50%;
      background: var(--surface);
    }

    .report-legend {
      display: grid;
      gap: 6px;
      font-size: 12px;
      color: var(--muted);
    }

    .report-pipeline-chart {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 8px;
    }

    .report-pipeline-step {
      min-height: 64px;
      min-width: 0;
      border: 1px solid var(--line);
      border-radius: 8px;
      padding: 10px;
      background: var(--surface-soft);
    }

    .report-pipeline-step b { display: block; font-size: 13px; }
    .report-pipeline-step span { color: var(--muted); font-size: 12px; }

    .task .btn { width: 100%; }

    .candidate-workflow-chain-panel {
      display: grid;
      gap: 8px;
      margin-top: 8px;
      padding: 10px;
      border: 1px solid var(--line);
      border-radius: 8px;
      background: #f8fbfd;
    }

    .candidate-workflow-chain-head {
      display: flex;
      justify-content: space-between;
      gap: 10px;
      align-items: flex-start;
    }

    .candidate-workflow-chain-head b {
      margin: 0;
      font-size: 13px;
    }

    .candidate-workflow-chain-head span {
      text-align: right;
      max-width: 52%;
    }

    .candidate-workflow-steps {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 6px;
    }

    .candidate-workflow-step {
      min-height: 26px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      border: 1px solid #d8e1ea;
      border-radius: 6px;
      padding: 0 7px;
      background: #fff;
      color: #526171;
      font-size: 12px;
      white-space: normal;
      text-align: center;
    }

    .candidate-workflow-step.active {
      border-color: #2d6cdf;
      background: #e8f0fb;
      color: #174f9d;
      font-weight: 700;
    }

    .flow {
      padding: 12px;
      display: grid;
      gap: 8px;
    }

    .folder-panel {
      display: grid;
      gap: 14px;
      min-width: 0;
    }

    .folder-intro {
      padding: 12px;
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 14px;
      align-items: center;
      border-bottom: 1px solid var(--line);
    }

    .folder-intro b {
      display: block;
      font-size: 14px;
      margin-bottom: 5px;
    }

    .folder-intro span {
      display: block;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .folder-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(168px, 1fr));
      gap: 8px;
      padding: 12px;
    }

    .folder-card {
      min-height: 96px;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: #fbfcfd;
      padding: 11px;
      display: grid;
      gap: 7px;
      align-content: start;
      text-align: left;
      cursor: pointer;
    }

    .folder-card b {
      display: block;
      font-size: 14px;
      line-height: 1.35;
    }

    .folder-card span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.55;
    }

    .workflow-candidate-assembly .folder-intro {
      align-items: start;
    }

    .assembly-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
      padding: 12px;
    }

    .assembly-form {
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: #fbfcfd;
      display: grid;
      gap: 12px;
      padding: 12px;
      min-width: 0;
    }

    .assembly-form-head {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 96px;
      gap: 10px;
      align-items: start;
    }

    .assembly-form-head b,
    .assembly-section > b {
      display: block;
      font-size: 14px;
      line-height: 1.35;
      margin-bottom: 5px;
    }

    .assembly-form-head span,
    .assembly-section small {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    .assembly-section {
      display: grid;
      gap: 7px;
      min-width: 0;
    }

    .assembly-details {
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
      padding: 8px;
      min-width: 0;
    }

    .assembly-details summary {
      cursor: pointer;
      color: #2f3d4e;
      font-size: 13px;
      font-weight: 700;
      line-height: 1.45;
    }

    .assembly-details[open] {
      display: grid;
      gap: 10px;
    }

    .field-chip-list,
    .pipeline-list,
    .plugin-safety-list {
      display: grid;
      gap: 6px;
    }

    .field-chip,
    .pipeline-step,
    .plugin-safety {
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
      padding: 8px;
      display: grid;
      gap: 3px;
      min-width: 0;
    }

    .field-chip strong,
    .pipeline-step strong,
    .plugin-safety strong {
      font-size: 12px;
      line-height: 1.35;
    }

    .flow-row {
      display: grid;
      grid-template-columns: 112px minmax(0, 1fr) 74px;
      gap: 10px;
      align-items: center;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      padding: 10px;
      background: #fbfcfd;
    }

    .flow-row strong { font-size: 14px; }

    .flow-row p {
      margin: 0;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .flow-row button {
      min-height: 32px;
      border-radius: 8px;
      border: 1px solid var(--line);
      background: var(--surface);
      cursor: pointer;
      color: #263445;
    }

    .wide {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
      gap: 18px;
    }

    .quick-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 8px;
      padding: 12px;
    }

    .quick {
      min-height: 70px;
      border-radius: var(--radius);
      border: 1px solid var(--line);
      background: #fbfcfd;
      padding: 10px;
      text-align: left;
      cursor: pointer;
    }

    .quick b {
      display: block;
      font-size: 14px;
      margin-bottom: 7px;
    }

    .quick span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    .risk-list {
      display: grid;
      gap: 8px;
      padding: 12px;
    }

    .risk {
      display: grid;
      grid-template-columns: 62px minmax(0, 1fr);
      gap: 10px;
      align-items: start;
      padding-bottom: 10px;
      border-bottom: 1px solid var(--line);
    }

    .risk:last-child {
      border-bottom: 0;
      padding-bottom: 0;
    }

    .risk b { font-size: 13px; }

    .risk p {
      margin: 0;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .workflow-records {
      display: grid;
      grid-template-columns: 1fr;
      gap: 12px;
      padding: 12px;
    }

    .workflow-record-section {
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
      overflow: hidden;
    }

    .workflow-record-section[hidden] {
      display: none;
    }

    .workflow-record-section-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      min-height: 42px;
      padding: 0 12px;
      border-bottom: 1px solid var(--line);
      background: #fbfcfd;
    }

    .workflow-record-section-head h3 {
      margin: 0;
      font-size: 14px;
    }

    .weijia-record-table {
      display: grid;
      width: 100%;
      font-size: 13px;
    }

    .weijia-record-head,
    .weijia-record-row {
      display: grid;
      grid-template-columns: minmax(120px, 1.1fr) minmax(110px, .9fr) minmax(120px, 1fr) minmax(82px, .7fr) 98px;
      align-items: center;
      gap: 10px;
      min-height: 40px;
      padding: 0 12px;
      border-bottom: 1px solid var(--line);
    }

    .weijia-record-head {
      min-height: 36px;
      color: var(--muted);
      background: #f7f9fb;
      font-size: 12px;
    }

    .weijia-record-row:last-child {
      border-bottom: 0;
    }

    .weijia-record-row b {
      font-size: 13px;
      line-height: 1.35;
    }

    .weijia-record-row span {
      color: var(--muted);
      line-height: 1.5;
    }

    .weijia-record-row.empty {
      grid-template-columns: 1fr;
      min-height: 48px;
      color: var(--muted);
    }

    .weijia-record-row .btn {
      min-height: 30px;
      padding: 0 10px;
    }

    .relation-links {
      display: grid;
      gap: 10px;
    }

    .relation-link {
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fbfcfd;
      padding: 12px;
      display: grid;
      grid-template-columns: minmax(0, 1fr) 96px;
      gap: 10px;
      align-items: center;
    }

    .relation-link b {
      display: block;
      font-size: 13px;
      margin-bottom: 4px;
    }

    .relation-link span {
      display: block;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    .drawer {
      position: fixed;
      inset: 0;
      background: rgba(12, 21, 32, .28);
      display: none;
      justify-content: flex-end;
      z-index: 20;
    }

    .drawer.open { display: flex; }

    .drawer-panel {
      width: min(540px, 100%);
      height: 100%;
      background: var(--surface);
      box-shadow: -22px 0 60px rgba(14, 28, 43, .16);
      padding: 24px;
      overflow: auto;
    }

    .drawer-panel.sales-detail-drawer-panel {
      width: min(1080px, calc(100% - 64px));
    }

    .drawer-panel.sales-form-drawer-panel {
      width: min(960px, calc(100% - 64px));
      background: #eef3f8;
      padding: 18px 24px;
    }

    .drawer-panel.workflow-form-drawer-panel {
      width: min(900px, calc(100% - 64px));
      background: #eef3f8;
      padding: 18px 24px;
    }

    .drawer-panel header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 12px;
      margin-bottom: 20px;
    }

    .drawer-panel h3 {
      margin: 0;
      font-size: 20px;
    }

    .form {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      gap: 14px;
    }

    #drawerBody > [data-drawer] {
      min-width: 0;
      max-width: 100%;
    }

    [data-hq-config-mode-banner],
    [data-store-config-edit-form] {
      display: none;
    }

    body[data-hq-config-mode="true"] [data-hq-config-mode-banner] {
      display: grid;
    }

    body[data-hq-config-mode="true"] [data-store-config-edit-form] {
      display: inline-flex;
    }

    .hq-config-mode-banner {
      margin: 12px 18px 0;
      border: 1px solid #b9d7c9;
      border-radius: 8px;
      padding: 10px 12px;
      background: #f1fbf6;
      color: #123728;
      gap: 4px;
    }

    .hq-config-mode-banner strong {
      font-size: 13px;
    }

    .hq-config-mode-banner span {
      color: #456052;
      font-size: 12px;
      line-height: 1.45;
    }

    .store-config-edit-btn {
      align-items: center;
      justify-content: center;
      min-height: 32px;
      border: 1px solid #b9d7c9;
      border-radius: 6px;
      padding: 0 10px;
      background: #f1fbf6;
      color: #0f7a4d;
      font-size: 12px;
      font-weight: 800;
      cursor: pointer;
    }

    .workflow-record-section-head .store-config-edit-btn,
    .sales-title-toolbar .store-config-edit-btn {
      margin-left: auto;
    }

    .drawer-panel.store-config-editor-drawer-panel {
      width: min(1240px, calc(100% - 48px));
      background: #f5f7fa;
      padding: 0;
    }

    .drawer-panel.store-config-editor-drawer-panel.store-config-editor-fullscreen {
      position: fixed;
      inset: 0;
      width: 100vw;
      max-width: none;
      height: 100vh;
      margin: 0;
      border: 0;
      border-radius: 0;
      transform: none;
      background: #f5f7fa;
      box-shadow: none;
      z-index: 60;
    }

    .store-config-editor-fullscreen > header {
      display: none !important;
    }

    body.store-form-builder-open {
      overflow: hidden;
      max-width: 100vw;
    }

    body.store-form-builder-open #drawerBody {
      height: 100vh;
      min-height: 0;
      overflow: hidden;
      padding: 0;
    }

    .store-config-editor-shell {
      display: grid;
      grid-template-rows: auto minmax(0, 1fr);
      width: 100%;
      max-width: 100vw;
      min-width: 0;
      height: 100vh;
      min-height: 0;
      overflow: hidden;
      background: #f5f7fa;
    }

    .weijia-config-editor-topbar {
      position: relative;
      z-index: 2;
      min-height: 64px;
      display: grid;
      grid-template-columns: minmax(240px, 320px) minmax(460px, 1fr) auto auto auto;
      align-items: center;
      gap: 12px;
      padding: 8px 16px;
      border-bottom: 1px solid #dfe6ee;
      background: #fff;
    }

    .weijia-config-editor-title {
      display: grid;
      gap: 2px;
      min-width: 0;
    }

    .weijia-config-editor-title input {
      width: min(320px, 100%);
      min-height: 30px;
      border: 1px solid transparent;
      border-radius: 4px;
      background: transparent;
      font-size: 16px;
      font-weight: 800;
      line-height: 1.3;
      color: #17202a;
      padding: 3px 6px;
    }

    .weijia-config-editor-title input:hover,
    .weijia-config-editor-title input:focus {
      border-color: #b8c8d8;
      background: #fff;
      outline: 0;
    }

    .weijia-config-editor-title span,
    .store-config-editor-note {
      color: #536171;
      font-size: 12px;
      line-height: 1.5;
    }

    .store-config-editor-tabs {
      display: inline-flex;
      align-items: center;
      justify-self: center;
      gap: 0;
      min-width: 0;
      align-self: stretch;
      background: transparent;
    }

    .store-config-editor-tabs button {
      min-height: 48px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 7px;
      border: 0;
      border-bottom: 2px solid transparent;
      padding: 0 24px;
      background: #fff;
      color: #6c7786;
      cursor: pointer;
      font-weight: 700;
      white-space: nowrap;
    }

    .store-config-editor-tabs [data-weijia-editor-step-number] {
      width: 18px;
      height: 18px;
      display: inline-grid;
      place-items: center;
      border: 1px solid #cbd5df;
      border-radius: 2px;
      color: #7b8795;
      font-size: 11px;
      line-height: 1;
    }

    .store-config-editor-tabs button.is-active {
      border-bottom-color: #67ad03;
      background: #fff;
      color: #3d7605;
    }

    .store-config-editor-tabs button.is-active [data-weijia-editor-step-number] {
      border-color: #67ad03;
      background: #67ad03;
      color: #fff;
    }

    .weijia-config-editor-save {
      min-height: 36px;
      border: 1px solid #e49313;
      border-radius: 4px;
      padding: 0 14px;
      background: #f3a12a;
      color: #fff;
      font-weight: 800;
      cursor: pointer;
    }

    .store-config-editor-panel {
      display: none;
      min-height: 0;
      min-width: 0;
    }

    .store-config-editor-panel.is-active {
      display: block;
      height: 100%;
      min-height: 0;
      overflow: hidden;
    }

    .store-config-editor-panel[data-store-config-editor-panel="settings"].is-active {
      overflow-x: hidden;
      overflow-y: auto;
      overscroll-behavior: contain;
      scrollbar-gutter: stable;
    }

    .weijia-form-design-layout {
      display: grid;
      grid-template-columns: 220px minmax(420px, 1fr) 292px;
      gap: 12px;
      height: 100%;
      min-height: 0;
      padding: 12px;
    }

    .weijia-component-palette,
    .weijia-form-canvas,
    .weijia-property-panel,
    .weijia-editor-menu,
    .weijia-editor-content {
      border: 1px solid #dfe6ee;
      border-radius: 6px;
      background: #fff;
      min-width: 0;
      min-height: 0;
    }

    .weijia-component-palette {
      overflow-y: auto;
      padding: 10px;
      display: grid;
      align-content: start;
      gap: 12px;
    }

    .weijia-component-group {
      display: grid;
      gap: 8px;
    }

    .weijia-component-group b,
    .weijia-form-canvas-head b,
    .weijia-property-panel b,
    .weijia-editor-content b,
    .weijia-rule-card b {
      display: block;
      color: #17202a;
      font-size: 13px;
      line-height: 1.45;
    }

    .weijia-component-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 6px;
    }

    .weijia-component-chip {
      min-height: 32px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #f8fafc;
      color: #344256;
      font-size: 12px;
      white-space: nowrap;
      cursor: grab;
    }

    .weijia-component-chip:active { cursor: grabbing; }

    .weijia-field-restore {
      min-height: 32px;
      border: 1px dashed #9db0c3;
      border-radius: 4px;
      background: #fff;
      color: #536171;
      font-weight: 800;
    }

    .weijia-form-canvas {
      overflow-y: auto;
      padding: 14px;
      display: grid;
      gap: 10px;
      align-content: start;
    }

    .weijia-form-canvas-head {
      display: grid;
      gap: 4px;
      padding-bottom: 10px;
      border-bottom: 1px solid #edf2f6;
    }

    .weijia-form-title-field {
      min-height: 54px;
      display: grid;
      place-items: center;
      border: 1px dashed #7aa4c7;
      border-radius: 4px;
      background: #f8fbfe;
      padding: 9px 48px;
      position: relative;
    }

    .weijia-form-title-field button {
      min-width: min(280px, 70%);
      min-height: 28px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      border-radius: 3px;
      border: 0;
      background: var(--form-title-background, #4f92d5);
      color: var(--form-title-color, #fff);
      font-size: var(--form-title-font-size, 13px);
      font-weight: 800;
      padding: 0 18px;
      cursor: pointer;
    }

    .weijia-form-title-field.is-selected {
      border-color: #5aa10a;
      box-shadow: 0 0 0 2px rgba(90, 161, 10, .12);
      background: #fbfff8;
    }

    .weijia-form-field-grid {
      display: grid;
      grid-template-columns: repeat(12, minmax(0, 1fr));
      grid-auto-rows: max-content;
      gap: 8px;
      min-height: 160px;
      align-content: start;
    }

    .weijia-form-field-grid.is-drop-target {
      outline: 2px dashed #5aa10a;
      outline-offset: 4px;
      background: #fbfff8;
    }

    .weijia-field-card {
      min-height: 104px;
      height: max-content;
      align-self: start;
      grid-column: span 6;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #fff;
      padding: 12px;
      position: relative;
      display: grid;
      gap: 8px;
      align-content: start;
      cursor: pointer;
    }

    .weijia-field-card.is-dragging { opacity: .45; }
    .weijia-field-card.is-drop-before { box-shadow: inset 0 3px 0 #5aa10a; }

    .weijia-field-card.is-detail-drop-target {
      border-color: #5aa10a;
      box-shadow: 0 0 0 3px rgba(90, 161, 10, .16);
      background: #fbfff8;
    }

    .weijia-detail-drop-hint {
      display: block;
      min-height: 0;
      max-height: 0;
      overflow: hidden;
      border: 0 dashed #8dbb5b;
      color: #4e7f16;
      font-size: 12px;
      font-weight: 700;
      line-height: 28px;
      text-align: center;
      opacity: 0;
      transition: max-height .15s ease, opacity .15s ease, border-width .15s ease;
    }

    .weijia-field-card.is-detail-drop-target .weijia-detail-drop-hint {
      max-height: 30px;
      border-width: 1px;
      opacity: 1;
    }

    .weijia-field-card-main {
      width: 100%;
      min-height: 24px;
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      align-items: start;
      gap: 10px;
      border: 0;
      padding: 0;
      background: transparent;
      text-align: left;
      cursor: pointer;
    }

    .weijia-field-card-main .weijia-field-kind {
      color: #8a96a3;
      font-size: 11px;
      white-space: nowrap;
    }

    .weijia-field-card-actions {
      position: absolute;
      top: 6px;
      right: 6px;
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 4px;
      min-height: 32px;
      padding: 0;
      opacity: 0;
      pointer-events: none;
      transform: translateY(-3px);
      transition: opacity .15s ease, transform .15s ease;
    }

    .weijia-field-card:hover .weijia-field-card-actions,
    .weijia-field-card:focus-within .weijia-field-card-actions,
    .weijia-field-card.is-selected .weijia-field-card-actions {
      opacity: 1;
      pointer-events: auto;
      transform: translateY(0);
    }

    .weijia-field-card-actions button {
      min-width: 32px;
      min-height: 32px;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      cursor: pointer;
    }

    .weijia-field-card-actions button:disabled {
      cursor: not-allowed;
      opacity: .42;
    }

    .weijia-field-card.is-selected {
      border-color: #5aa10a;
      box-shadow: 0 0 0 2px rgba(90, 161, 10, .12);
      background: #fbfff8;
    }

    .weijia-field-card.is-selected .weijia-field-card-main {
      padding-right: 142px;
    }

    .weijia-field-preview {
      min-width: 0;
      pointer-events: none;
    }

    .weijia-field-preview[data-form-builder-detail-drop-zone] {
      pointer-events: auto;
    }

    .weijia-field-preview[data-form-builder-detail-drop-zone] > * {
      pointer-events: none;
    }

    .weijia-preview-input,
    .weijia-preview-textarea,
    .weijia-preview-select {
      width: 100%;
      min-height: 34px;
      border: 1px solid #d9e1e8;
      border-radius: 3px;
      background: #fff;
      color: #596777;
      padding: 6px 10px;
      opacity: 1;
    }

    .weijia-preview-textarea {
      min-height: 60px;
      resize: none;
    }

    .weijia-preview-input:disabled,
    .weijia-preview-textarea:disabled,
    .weijia-preview-select:disabled {
      color: #596777;
      -webkit-text-fill-color: #596777;
      background: #fff;
      opacity: 1;
    }

    .weijia-preview-input.is-readonly {
      background: #f6f8fa;
    }

    .weijia-preview-options {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 8px 18px;
      min-height: 34px;
      color: #445264;
      font-size: 12px;
    }

    .weijia-preview-options label {
      display: inline-flex;
      align-items: center;
      gap: 5px;
    }

    .weijia-preview-options input {
      margin: 0;
    }

    .weijia-preview-upload {
      min-height: 62px;
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      border: 1px dashed #b8c5d1;
      border-radius: 3px;
      background: #fbfcfd;
      color: #718093;
      font-size: 12px;
    }

    .weijia-preview-upload-icon {
      width: 24px;
      height: 24px;
      display: inline-grid;
      place-items: center;
      border: 1px solid #b8c5d1;
      border-radius: 50%;
      color: #5f7184;
      font-size: 16px;
    }

    .weijia-preview-detail {
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      align-items: center;
      gap: 12px;
      min-height: 58px;
      border: 1px solid #d9e1e8;
      border-radius: 3px;
      background: #fbfcfd;
      padding: 10px 12px;
    }

    .weijia-preview-detail div {
      display: grid;
      gap: 3px;
    }

    .weijia-preview-detail button {
      min-height: 30px;
      border: 1px solid #cfd9e2;
      border-radius: 3px;
      background: #fff;
      color: #506174;
    }

    .weijia-preview-system {
      min-height: 34px;
      display: flex;
      align-items: center;
      border: 1px dashed #c8d2dc;
      border-radius: 3px;
      background: #f6f8fa;
      color: #778493;
      font-size: 12px;
      padding: 6px 10px;
    }

    .weijia-field-card[data-field-width="整行"] {
      grid-column: 1 / -1;
    }
    .weijia-field-card[data-field-width="1/4"] { grid-column: span 3; }
    .weijia-field-card[data-field-width="1/3"] { grid-column: span 4; }
    .weijia-field-card[data-field-width="1/2"] { grid-column: span 6; }
    .weijia-field-card[data-field-width="2/3"] { grid-column: span 8; }
    .weijia-field-card[data-field-width="3/4"] { grid-column: span 9; }

    .weijia-field-card strong {
      font-size: 13px;
      line-height: 1.35;
      color: #17202a;
    }

    .weijia-field-card span,
    .weijia-property-row span,
    .weijia-editor-content span,
    .weijia-rule-card span {
      color: #536171;
      font-size: 12px;
      line-height: 1.5;
    }

    .weijia-required-mark {
      color: #c7473d;
      font-weight: 900;
    }

    .weijia-property-panel {
      overflow-y: auto;
      padding: 0;
    }

    .weijia-property-tabs {
      display: flex;
      border-bottom: 1px solid #dfe6ee;
    }

    .weijia-property-tabs button {
      flex: 1;
      min-height: 40px;
      border: 0;
      background: #fff;
      color: #344256;
      cursor: pointer;
      font-weight: 700;
    }

    .weijia-property-tabs button.is-active {
      color: #3d7605;
      background: #f3f9ee;
    }

    .weijia-property-body {
      display: grid;
      gap: 12px;
      padding: 14px;
    }

    .weijia-property-row {
      display: grid;
      gap: 6px;
      min-width: 0;
    }

    .weijia-property-row input,
    .weijia-property-row textarea,
    .weijia-property-row select {
      width: 100%;
      min-height: 34px;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      padding: 7px 9px;
      color: #17202a;
      background: #fff;
    }

    .weijia-property-row textarea {
      min-height: 72px;
      resize: vertical;
    }

    .weijia-color-property {
      display: grid;
      grid-template-columns: 44px minmax(0, 1fr);
      align-items: center;
      gap: 8px;
    }

    .weijia-color-property input[type="color"] {
      width: 44px;
      min-width: 44px;
      min-height: 36px;
      padding: 3px;
      cursor: pointer;
    }

    .weijia-color-property span {
      min-height: 36px;
      display: inline-flex;
      align-items: center;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #f8fafc;
      padding: 0 9px;
      font-variant-numeric: tabular-nums;
    }

    .weijia-option-editor {
      display: grid;
      gap: 7px;
    }

    .weijia-option-row {
      display: grid;
      grid-template-columns: 22px minmax(0, 1fr) repeat(3, 32px);
      gap: 4px;
      align-items: center;
    }

    .weijia-option-row[data-colorful="true"] {
      grid-template-columns: 22px 36px minmax(0, 1fr) repeat(3, 32px);
    }

    .weijia-option-row input {
      min-width: 0;
    }

    .weijia-option-row .weijia-option-default {
      width: 18px;
      height: 18px;
      margin: 0;
      justify-self: center;
      accent-color: #67ad03;
    }

    .weijia-option-row .weijia-option-color {
      width: 36px;
      min-width: 36px;
      min-height: 34px;
      padding: 3px;
      cursor: pointer;
    }

    .workflow-color-multi {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      position: relative;
      min-width: 0;
    }

    .workflow-color-option {
      min-height: 36px;
      --workflow-option-color: #1285EE;
      display: inline-flex;
      align-items: center;
      gap: 7px;
      border: 1px solid color-mix(in srgb, var(--workflow-option-color) 55%, #dfe6ee);
      border-radius: 4px;
      padding: 6px 10px;
      background: color-mix(in srgb, var(--workflow-option-color) 8%, #fff);
      color: #243244;
      cursor: pointer;
      user-select: none;
    }

    .workflow-color-option input {
      width: 16px;
      height: 16px;
      margin: 0;
      accent-color: var(--workflow-option-color);
    }

    .workflow-color-option:has(input:checked) {
      border-color: var(--workflow-option-color);
      background: color-mix(in srgb, var(--workflow-option-color) 16%, #fff);
      color: #17202a;
      font-weight: 700;
    }

    .workflow-color-source {
      position: absolute;
      width: 1px;
      height: 1px;
      opacity: 0;
      pointer-events: none;
      overflow: hidden;
    }

    .weijia-option-row button,
    .weijia-option-add {
      min-width: 32px;
      min-height: 32px;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      cursor: pointer;
    }

    .weijia-option-row button:disabled,
    .weijia-option-add:disabled {
      cursor: not-allowed;
      opacity: .42;
    }

	    .weijia-option-add {
	      width: 100%;
	      color: #3d7605;
	      font-weight: 800;
	    }

    .weijia-detail-child-editor {
      display: grid;
      gap: 10px;
      padding: 12px 0;
      border-top: 1px solid #e5e9f0;
      border-bottom: 1px solid #e5e9f0;
    }

    .weijia-detail-child-head,
    .weijia-detail-child-row,
    .weijia-detail-child-actions {
      display: flex;
      align-items: center;
    }

    .weijia-detail-child-head {
      justify-content: space-between;
    }

    .weijia-detail-child-head span,
    .weijia-detail-child-empty {
      color: #7b8494;
      font-size: 12px;
    }

    .weijia-detail-child-rows {
      display: grid;
      gap: 8px;
    }

    .weijia-detail-child-row {
      flex-wrap: wrap;
      gap: 7px;
      padding: 9px;
      border: 1px solid #dbe2ec;
      background: #f8fafc;
    }

    .weijia-detail-child-row > input,
    .weijia-detail-child-row > select {
      min-width: 0;
      height: 34px;
      border: 1px solid #cfd8e6;
      background: #fff;
    }

    .weijia-detail-child-row > input { flex: 1 1 120px; }
    .weijia-detail-child-row > select { flex: 0 1 112px; }

    .weijia-detail-child-row > label {
      display: inline-flex;
      align-items: center;
      gap: 4px;
      min-height: 32px;
      white-space: nowrap;
      font-size: 12px;
    }

    .weijia-detail-child-actions {
      gap: 4px;
      margin-left: auto;
    }

    .weijia-detail-child-actions button,
    .weijia-detail-child-add {
      min-width: 32px;
      min-height: 32px;
      border: 1px solid #cfd8e6;
      background: #fff;
      color: #344054;
    }

    .weijia-detail-child-add {
      width: 100%;
      color: #3b7c0f;
      font-weight: 700;
    }

	    .weijia-relation-panel {
	      display: grid;
	      gap: 12px;
	      padding-top: 12px;
	      border-top: 1px solid #dfe6ee;
	    }

	    .weijia-relation-lock-note,
	    .weijia-relation-catalog-note {
	      border: 1px solid #d7e2cd;
	      border-radius: 4px;
	      background: #f3f9ee;
	      color: #41601e;
	      padding: 8px 10px;
	      font-size: 12px;
	      line-height: 1.5;
	    }

	    .weijia-relation-list {
	      display: grid;
	      gap: 7px;
	    }

	    .weijia-relation-condition-row,
	    .weijia-relation-mapping-row {
	      display: grid;
	      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 32px;
	      gap: 5px;
	      align-items: center;
	      padding: 7px;
	      border: 1px solid #dfe6ee;
	      border-radius: 4px;
	      background: #f8fafc;
	    }

	    .weijia-relation-mapping-row {
	      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 32px;
	    }

	    .weijia-relation-condition-row input,
	    .weijia-relation-condition-row select,
	    .weijia-relation-mapping-row input,
	    .weijia-relation-mapping-row select {
	      width: 100%;
	      min-width: 0;
	      min-height: 34px;
	      border: 1px solid #dfe6ee;
	      border-radius: 4px;
	      background: #fff;
	      color: #17202a;
	      padding: 6px 7px;
	    }

	    .weijia-relation-condition-row [data-weijia-editor-relation-condition-value] {
	      grid-column: 2 / -1;
	    }

	    .weijia-relation-display-fields {
	      display: grid;
	      gap: 6px;
	      max-height: 176px;
	      overflow: auto;
	      padding: 7px;
	      border: 1px solid #dfe6ee;
	      border-radius: 4px;
	      background: #f8fafc;
	    }

	    .weijia-relation-display-fields label {
	      display: flex;
	      align-items: center;
	      gap: 7px;
	      min-height: 28px;
	      color: #344256;
	      font-size: 12px;
	    }

	    .weijia-relation-display-fields input {
	      width: 16px;
	      height: 16px;
	      margin: 0;
	      accent-color: #67ad03;
	    }

	    .weijia-relation-property-error {
	      color: #b42318;
	      font-size: 12px;
	      line-height: 1.45;
	    }

	    .weijia-relation-condition-row .weijia-relation-property-error,
	    .weijia-relation-mapping-row .weijia-relation-property-error {
	      grid-column: 1 / -1;
	    }

	    .weijia-relation-row-remove,
	    .weijia-relation-row-add {
	      min-width: 32px;
	      min-height: 32px;
	      border: 1px solid #dfe6ee;
	      border-radius: 4px;
	      background: #fff;
	      color: #344256;
	      cursor: pointer;
	      touch-action: manipulation;
	    }

	    .weijia-relation-row-add {
	      width: 100%;
	      color: #3d7605;
	      font-weight: 800;
	    }

	    .weijia-relation-panel :disabled {
	      cursor: not-allowed;
	      opacity: .58;
	    }

      .weijia-relation-correspondence-summary-content {
        display: grid;
        gap: 8px;
      }

      .weijia-relation-correspondence-summary-content > span {
        color: #667384;
        font-size: 12px;
        line-height: 1.5;
      }

      .weijia-relation-correspondence-summary-content > button {
        min-height: 40px;
        border: 1px solid #d7e2cd;
        border-radius: 4px;
        background: #f3f9ee;
        color: #3d7605;
        font-weight: 800;
        cursor: pointer;
        touch-action: manipulation;
      }

      .weijia-relation-correspondence-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1200;
        display: grid;
        place-items: center;
        padding: 16px;
        background: rgba(0, 0, 0, .45);
      }

      .weijia-relation-correspondence-dialog {
        width: min(700px, calc(100vw - 32px));
        max-height: calc(100dvh - 32px);
        display: grid;
        grid-template-rows: auto auto minmax(0, 1fr) auto;
        overflow: hidden;
        border: 0;
        border-radius: 4px;
        background: #fff;
        box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
      }

      .weijia-relation-correspondence-dialog:focus {
        outline: 0;
      }

      .weijia-relation-correspondence-header {
        position: relative;
        min-height: 57px;
        padding: 16px 56px 16px 24px;
        border-bottom: 0;
      }

      .weijia-relation-correspondence-header b {
        display: block;
        margin: 0;
        color: rgba(0, 0, 0, .85);
        font-size: 16px;
        font-weight: 600;
        line-height: 24px;
      }

      .weijia-relation-correspondence-header button {
        position: absolute;
        top: 0;
        right: 0;
        width: 56px;
        height: 56px;
        border: 0;
        background: transparent;
        color: rgba(0, 0, 0, .45);
        font-size: 20px;
        cursor: pointer;
        touch-action: manipulation;
      }

      .weijia-relation-correspondence-hint {
        padding: 10px 24px;
        background: #f5f9ff;
        color: #1890ff;
        font-size: 14px;
        line-height: 21px;
      }

      .weijia-relation-correspondence-body {
        min-height: 0;
        overflow: auto;
        padding: 24px 24px 24px;
      }

      .weijia-relation-correspondence-rows {
        min-height: 0;
        max-height: min(420px, calc(100dvh - 231px));
        overflow: auto;
      }

      .weijia-relation-correspondence-row {
        display: grid;
        grid-template-columns: 260px 70px 260px 42px;
        min-height: 50px;
        align-items: center;
        padding: 9px 10px;
        margin-bottom: 10px;
        border-radius: 4px;
        background: #f9f9f9;
      }

      .weijia-relation-correspondence-row select {
        width: 100%;
        min-width: 0;
        height: 32px;
        border: 1px solid #d9d9d9;
        border-radius: 4px;
        background: #fff;
        color: rgba(0, 0, 0, .65);
        padding: 4px 11px;
        font-size: 14px;
        line-height: 22px;
      }

      .weijia-relation-correspondence-connector {
        width: 70px;
        color: rgba(0, 0, 0, .65);
        font-size: 14px;
        line-height: 21px;
        text-align: center;
      }

      .weijia-relation-correspondence-remove {
        justify-self: end;
        width: 32px;
        height: 32px;
        border: 0;
        background: transparent;
        color: #b7b8b9;
        font-size: 20px;
        line-height: 1;
        cursor: pointer;
        touch-action: manipulation;
      }

      .weijia-relation-correspondence-remove span {
        display: grid;
        place-items: center;
        width: 14px;
        height: 14px;
        margin: auto;
        border: 1px solid currentColor;
        border-radius: 50%;
        font-size: 12px;
        line-height: 1;
      }

      .weijia-relation-correspondence-empty,
      .weijia-relation-correspondence-error {
        border: 1px solid #d9d9d9;
        border-radius: 4px;
        padding: 12px;
        color: rgba(0, 0, 0, .45);
        font-size: 14px;
        line-height: 1.5;
        text-align: center;
      }

      .weijia-relation-correspondence-row .weijia-editor-error {
        grid-column: 1 / -1;
        margin: 6px 0 0;
      }

      .weijia-relation-correspondence-row .weijia-relation-property-error {
        grid-column: 1 / -1;
        margin: 6px 0 0;
      }

      .weijia-relation-correspondence-error {
        margin: 0 0 10px;
        border-color: #efb7b1;
        background: #fff3f2;
        color: #a33229;
        text-align: left;
      }

      .weijia-relation-correspondence-add {
        width: 100%;
        height: 32px;
        border: 1px dashed #d9d9d9;
        border-radius: 4px;
        background: #fff;
        color: rgba(0, 0, 0, .65);
        font-size: 14px;
        cursor: pointer;
        touch-action: manipulation;
      }

      .weijia-relation-correspondence-actions {
        display: flex;
        justify-content: flex-end;
        gap: 8px;
        min-height: 53px;
        padding: 10px 16px;
        border-top: 1px solid #f0f0f0;
        background: #fff;
      }

      .weijia-relation-correspondence-actions button {
        min-width: 64px;
        height: 32px;
        border: 1px solid #d9d9d9;
        border-radius: 4px;
        background: #fff;
        color: rgba(0, 0, 0, .65);
        font-size: 14px;
        cursor: pointer;
        touch-action: manipulation;
      }

      .weijia-relation-correspondence-actions [data-weijia-relation-correspondence-confirm] {
        border-color: #ff9900;
        background: #ff9900;
        color: #fff;
      }

      .weijia-relation-filter-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1200;
        display: grid;
        place-items: center;
        padding: 16px;
        background: rgba(0, 0, 0, .45);
      }

      .weijia-relation-filter-dialog {
        width: min(860px, calc(100vw - 32px));
        max-height: calc(100dvh - 32px);
        display: grid;
        grid-template-rows: auto auto minmax(0, 1fr) auto;
        overflow: hidden;
        border-radius: 4px;
        background: #fff;
        box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
      }

      .weijia-relation-filter-header,
      .weijia-relation-filter-actions {
        display: flex;
        align-items: center;
        justify-content: space-between;
        min-height: 56px;
        padding: 10px 18px;
      }

      .weijia-relation-filter-header button,
      .weijia-relation-filter-actions button,
      .weijia-relation-filter-add-actions button {
        min-height: 32px;
        border: 1px solid #d9d9d9;
        border-radius: 4px;
        background: #fff;
        color: #344256;
        cursor: pointer;
      }

      .weijia-relation-filter-hint {
        padding: 10px 18px;
        background: #f5f9ff;
        color: #2367d1;
        font-size: 13px;
      }

      .weijia-relation-filter-body {
        min-height: 0;
        overflow: auto;
        padding: 18px;
      }

      .weijia-relation-filter-rows {
        display: grid;
        gap: 10px;
      }

      .weijia-relation-filter-row {
        display: grid;
        grid-template-columns: 52px minmax(140px, 1fr) minmax(130px, 1fr) 110px minmax(150px, 1.2fr) 36px;
        gap: 8px;
        align-items: center;
        padding: 10px;
        border: 1px solid #e5e8eb;
        border-radius: 4px;
        background: #f8fafc;
      }

      .weijia-relation-filter-row select,
      .weijia-relation-filter-row input {
        width: 100%;
        min-width: 0;
        min-height: 34px;
        border: 1px solid #d9d9d9;
        border-radius: 4px;
        background: #fff;
        padding: 5px 8px;
      }

      .weijia-relation-filter-first {
        color: #536171;
        font-size: 13px;
        text-align: center;
      }

      .weijia-relation-filter-add-actions,
      .weijia-relation-filter-actions {
        display: flex;
        justify-content: flex-end;
        gap: 8px;
      }

      .weijia-relation-filter-add-actions {
        margin-top: 12px;
      }

      .weijia-relation-filter-add-actions button {
        padding: 0 14px;
        color: #3d7605;
        font-weight: 800;
      }

      .weijia-relation-filter-actions {
        border-top: 1px solid #f0f0f0;
      }

      .weijia-relation-filter-actions [data-weijia-relation-filter-confirm] {
        border-color: #67ad03;
        background: #67ad03;
        color: #fff;
      }

      .weijia-form-title-property-preview {
        min-height: 48px;
        display: grid;
        place-items: center;
        border: 1px dashed #b8c8d8;
        border-radius: 4px;
        background: #f8fafc;
      }

	    .weijia-checkbox-row {
      display: flex;
      align-items: center;
      gap: 8px;
      min-height: 28px;
      color: #344256;
      font-size: 13px;
    }

    .weijia-width-options {
      display: grid;
      grid-template-columns: repeat(6, minmax(0, 1fr));
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      overflow: hidden;
    }

    .weijia-width-options span {
      min-height: 32px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      border-right: 1px solid #dfe6ee;
      background: #fff;
      color: #344256;
    }

    .weijia-width-options button {
      min-width: 0;
      min-height: 36px;
      border: 0;
      border-right: 1px solid #dfe6ee;
      border-radius: 0;
      background: #fff;
      color: #344256;
      cursor: pointer;
      padding: 0 4px;
    }

    .weijia-width-options button:last-child { border-right: 0; }
    .weijia-width-options button.is-active {
      background: #eef7e7;
      color: #3d7605;
      font-weight: 800;
    }

    .weijia-field-error {
      border: 1px solid #efb7b1;
      border-radius: 4px;
      background: #fff3f2;
      color: #a33229;
      padding: 8px 10px;
      font-size: 12px;
      line-height: 1.5;
    }

    .weijia-config-editor-exit {
      min-width: 36px;
      min-height: 36px;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      cursor: pointer;
      font-weight: 800;
    }

    @media (max-width: 980px) {
      .weijia-config-editor-topbar {
        grid-template-columns: minmax(0, 1fr) auto auto;
      }
      .store-config-editor-tabs {
        grid-column: 1 / -1;
        grid-row: 2;
        overflow-x: auto;
      }
      .weijia-form-design-layout {
        height: 100%;
        grid-template-columns: 180px minmax(360px, 1fr) 260px;
        overflow-x: auto;
      }
    }

    @media (max-width: 820px) {
      .weijia-config-editor-topbar {
        grid-template-columns: minmax(0, 1fr) auto auto;
        gap: 8px;
        padding: 8px 10px;
      }
      .weijia-config-editor-title {
        grid-column: 1;
        grid-row: 1;
      }
      .weijia-config-editor-save {
        grid-column: 2;
        grid-row: 1;
        white-space: nowrap;
      }
      .weijia-config-editor-exit {
        grid-column: 3;
        grid-row: 1;
      }
      .store-config-editor-tabs {
        grid-column: 1 / -1;
        grid-row: 2;
        max-width: 100%;
        overflow-x: auto;
      }
      .weijia-config-editor-topbar [data-store-form-config-effective-status] {
        grid-column: 1 / -1;
        grid-row: 3;
        max-width: 100%;
        white-space: normal;
      }
      .weijia-form-design-layout {
        grid-template-columns: minmax(0, 1fr);
        align-content: start;
        height: 100%;
        overflow-x: hidden;
        overflow-y: auto;
        padding: 8px;
      }
      .weijia-component-palette,
      .weijia-form-canvas,
      .weijia-property-panel {
        overflow: visible;
      }
      .weijia-form-field-grid {
        min-width: 0;
      }
    }

    .weijia-width-options span:last-child {
      border-right: 0;
    }

    .weijia-width-options span.is-active {
      background: #eef7e7;
      color: #3d7605;
      font-weight: 800;
    }

    .weijia-publish-layout,
    .weijia-settings-layout {
      display: grid;
      grid-template-columns: 220px minmax(0, 1fr);
      gap: 12px;
      min-height: 0;
      padding: 12px;
    }

	    .weijia-release-shell {
	      position: relative;
	      display: grid;
	      grid-template-rows: 54px minmax(0, 1fr);
	      height: 100%;
	      min-height: 0;
	      overflow: hidden;
	      background: #fff;
	    }

	    .weijia-release-toolbar {
	      min-height: 54px;
	      display: flex;
	      align-items: center;
	      justify-content: space-between;
	      gap: 12px;
	      padding: 8px 20px;
	      border-bottom: 1px solid #e5e9ee;
	      background: #fff;
	    }

	    .weijia-release-toolbar > div:first-child,
	    .weijia-release-actions {
	      display: flex;
	      align-items: center;
	      gap: 10px;
	      flex-wrap: wrap;
	    }

	    .weijia-release-toolbar span,
	    .weijia-release-loading,
	    .weijia-workflow-sidebar span,
	    .weijia-workflow-property > span {
	      color: #667384;
	      font-size: 12px;
	      line-height: 1.5;
	    }

	    .weijia-release-toolbar span.error { color: #b42318; }

	    .weijia-release-shell .weijia-publish-layout {
	      width: min(1160px, calc(100% - 32px));
	      margin: 16px auto 0;
	      grid-template-columns: 190px minmax(0, 1fr);
	      gap: 0;
	      height: 100%;
	      overflow: hidden;
	      padding: 0;
	      border: 1px solid #dfe6ee;
	      background: #fff;
	    }

	    .weijia-permission-head,
	    .weijia-release-version {
	      display: flex;
	      align-items: center;
	      justify-content: space-between;
	      gap: 10px;
	    }

	    .weijia-permission-head span,
	    .weijia-release-version span {
	      color: #667384;
	      font-size: 12px;
	    }

	    .weijia-permission-role-grid,
	    .weijia-permission-action-grid {
	      display: grid;
	      grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
	      gap: 8px;
	    }

	    .weijia-permission-role-grid label,
	    .weijia-permission-action-grid label,
	    .weijia-field-permission-table label {
	      min-height: 32px;
	      display: flex;
	      align-items: center;
	      gap: 7px;
	      color: #354253;
	      font-size: 13px;
	    }

	    .weijia-field-permission-matrix summary {
	      min-height: 32px;
	      display: flex;
	      align-items: center;
	      cursor: pointer;
	      color: #3d7605;
	      font-weight: 700;
	    }

	    .weijia-field-permission-table {
	      display: grid;
	      max-height: 280px;
	      overflow-y: auto;
	      border: 1px solid #dfe6ee;
	    }

	    .weijia-field-permission-table > div {
	      display: grid;
	      grid-template-columns: minmax(140px, 1fr) 72px 72px;
	      gap: 8px;
	      align-items: center;
	      min-height: 38px;
	      padding: 3px 10px;
	      border-bottom: 1px solid #edf1f5;
	    }

	    .weijia-release-field {
	      display: grid;
	      gap: 6px;
	      color: #354253;
	      font-size: 13px;
	      font-weight: 700;
	    }

	    .weijia-release-field input,
	    .weijia-release-field select {
	      width: 100%;
	      min-height: 36px;
	      border: 1px solid #cfd9e4;
	      border-radius: 4px;
	      background: #fff;
	      padding: 0 10px;
	      color: #17202a;
	    }

	    .weijia-release-version {
	      min-height: 48px;
	      padding-top: 8px;
	      border-top: 1px solid #edf1f5;
	    }

	    .weijia-release-version > div {
	      min-width: 0;
	      display: grid;
	      gap: 3px;
	    }

	    .weijia-workflow-layout {
	      display: grid;
	      grid-template-rows: 50px minmax(0, 1fr);
	      height: 100%;
	      min-height: 0;
	      overflow: hidden;
	      background: #fff;
	    }

	    .weijia-workflow-toolbar {
	      display: flex;
	      align-items: center;
	      justify-content: space-between;
	      gap: 12px;
	      padding: 7px 16px;
	      border-bottom: 1px solid #e5e9ee;
	      background: #fff;
	    }

	    .weijia-workflow-toolbar > div {
	      display: flex;
	      align-items: center;
	      gap: 8px;
	    }

	    .weijia-workflow-toolbar .btn,
	    .weijia-workflow-toolbar select {
	      min-height: 34px;
	    }

	    .weijia-workflow-body {
	      display: grid;
	      grid-template-columns: minmax(0, 1fr) 310px;
	      min-height: 0;
	      overflow: hidden;
	    }

	    .weijia-workflow-canvas {
	      position: relative;
	      min-width: 0;
	      min-height: 0;
	      overflow: auto;
	      background: #fff;
	    }

	    .weijia-workflow-canvas-stage {
	      width: max(100%, 660px);
	      min-height: 100%;
	      display: flex;
	      flex-direction: column;
	      align-items: center;
	      padding: 72px 40px 120px;
	      transform-origin: top center;
	    }

	    .weijia-workflow-version-summary {
	      color: #6c7786;
	      font-size: 12px;
	      white-space: nowrap;
	    }

	    .weijia-workflow-node {
	      position: relative;
	      width: 188px;
	      min-height: 44px;
	      display: grid;
	      grid-template-columns: minmax(0, 1fr) auto;
	      align-items: center;
	      border: 1px solid #9ec5d7;
	      border-radius: 3px;
	      background: #fff;
	      box-shadow: 0 1px 2px rgba(21, 45, 68, .06);
	    }

	    .weijia-workflow-node[data-node-type="start"] { background: #edf9fd; border-color: #76bfd8; }
	    .weijia-workflow-node[data-node-type="end"] { background: #fff7f4; border-color: #e0a58f; }
	    .weijia-workflow-node.is-active { border-color: #67ad03; box-shadow: 0 0 0 2px rgba(103, 173, 3, .14); }

	    .weijia-workflow-node-main {
	      min-width: 0;
	      min-height: 42px;
	      display: flex;
	      align-items: center;
	      gap: 8px;
	      border: 0;
	      background: transparent;
	      padding: 0 10px;
	      text-align: left;
	      cursor: pointer;
	    }

	    .weijia-workflow-node-main > span {
	      width: 18px;
	      height: 18px;
	      display: grid;
	      place-items: center;
	      border-radius: 50%;
	      background: #d9f0f7;
	      color: #277c9c;
	      font-size: 10px;
	      font-weight: 800;
	      flex: 0 0 auto;
	    }

	    .weijia-workflow-node-main div { min-width: 0; display: grid; gap: 1px; }
	    .weijia-workflow-node-main b,
	    .weijia-workflow-node-main small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
	    .weijia-workflow-node-main b { font-size: 13px; }
	    .weijia-workflow-node-main small { color: #7b8794; font-size: 10px; }

	    .weijia-workflow-node-actions {
	      display: none;
	      position: absolute;
	      left: calc(100% + 8px);
	      top: 4px;
	      gap: 4px;
	      z-index: 2;
	    }

	    .weijia-workflow-node.is-active .weijia-workflow-node-actions { display: flex; }
	    .weijia-workflow-node-actions button {
	      width: 30px;
	      min-width: 30px;
	      height: 30px;
	      border: 1px solid #d8e2ec;
	      border-radius: 3px;
	      background: #fff;
	      cursor: pointer;
	    }

	    .weijia-workflow-connector {
	      position: relative;
	      width: 1px;
	      height: 70px;
	      background: #8fb56b;
	    }

	    .weijia-workflow-connector::after {
	      content: '';
	      position: absolute;
	      left: -3px;
	      bottom: -1px;
	      border-left: 4px solid transparent;
	      border-right: 4px solid transparent;
	      border-top: 6px solid #8fb56b;
	    }

	    .weijia-workflow-inline-add {
	      position: absolute;
	      left: 50%;
	      top: 50%;
	      width: 24px;
	      height: 24px;
	      display: grid;
	      place-items: center;
	      transform: translate(-50%, -50%);
	      border: 1px solid #a9bdcf;
	      border-radius: 50%;
	      background: #fff;
	      color: #4d6a82;
	      cursor: pointer;
	      opacity: 0;
	    }

	    .weijia-workflow-connector:hover .weijia-workflow-inline-add,
	    .weijia-workflow-inline-add:focus { opacity: 1; }

	    .weijia-workflow-property {
	      min-width: 0;
	      min-height: 0;
	      display: grid;
	      grid-template-rows: 44px minmax(0, 1fr);
	      border-left: 1px solid #e2e7ec;
	      background: #fff;
	      overflow: hidden;
	    }

	    .weijia-workflow-property-tabs {
	      display: grid;
	      grid-template-columns: 1fr 1fr;
	      border-bottom: 1px solid #e5e9ee;
	    }

	    .weijia-workflow-property-tabs button {
	      border: 0;
	      border-bottom: 2px solid transparent;
	      background: #fff;
	      color: #667384;
	      cursor: pointer;
	      font-weight: 700;
	    }

	    .weijia-workflow-property-tabs button.is-active {
	      border-bottom-color: #67ad03;
	      color: #3d7605;
	    }

	    .weijia-workflow-property-content {
	      min-height: 0;
	      display: grid;
	      align-content: start;
	      gap: 14px;
	      padding: 16px;
	      overflow-y: auto;
	    }

	    .weijia-permission-drawer-backdrop {
	      position: fixed;
	      inset: 64px 0 0;
	      z-index: 75;
	      background: rgba(22, 31, 40, .46);
	    }

	    .weijia-permission-drawer {
	      position: fixed;
	      top: 64px;
	      right: 0;
	      bottom: 0;
	      z-index: 76;
	      width: min(760px, 72vw);
	      display: grid;
	      grid-template-rows: 56px minmax(0, 1fr) 58px;
	      background: #fff;
	      box-shadow: -12px 0 30px rgba(21, 36, 51, .15);
	    }

	    .weijia-permission-drawer[hidden],
	    .weijia-permission-drawer-backdrop[hidden] { display: none; }

	    .weijia-permission-drawer-head,
	    .weijia-permission-drawer-foot {
	      display: flex;
	      align-items: center;
	      justify-content: space-between;
	      gap: 12px;
	      padding: 0 20px;
	      border-bottom: 1px solid #e5e9ee;
	    }

	    .weijia-permission-drawer-foot {
	      justify-content: flex-end;
	      border-top: 1px solid #e5e9ee;
	      border-bottom: 0;
	    }

	    .weijia-permission-drawer-head button {
	      width: 36px;
	      height: 36px;
	      border: 0;
	      background: transparent;
	      font-size: 22px;
	      cursor: pointer;
	    }

	    .weijia-permission-drawer-body {
	      min-height: 0;
	      display: grid;
	      align-content: start;
	      gap: 20px;
	      padding: 18px 20px 28px;
	      overflow-y: auto;
	    }

	    .weijia-permission-drawer-section {
	      display: grid;
	      gap: 10px;
	      padding-bottom: 18px;
	      border-bottom: 1px solid #edf1f5;
	    }

	    .weijia-publish-permission-section {
	      display: grid;
	      gap: 12px;
	    }

	    .weijia-publish-permission-actions {
	      display: grid;
	      grid-template-columns: minmax(220px, 1fr) 130px 160px;
	      gap: 10px;
	    }

	    .weijia-publish-permission-actions button {
	      min-height: 46px;
	      border: 1px dashed #c9d3dc;
	      background: #fff;
	      color: #4c5b6b;
	      cursor: pointer;
	    }

	    .weijia-permission-group-row {
	      display: grid;
	      grid-template-columns: minmax(0, 1fr) auto;
	      gap: 12px;
	      align-items: center;
	      min-height: 72px;
	      padding: 12px 14px;
	      border: 1px solid #dfe6ee;
	      background: #fff;
	    }

	    .weijia-permission-group-row > div:first-child { display: grid; gap: 6px; }
	    .weijia-permission-group-row span { color: #667384; font-size: 12px; }
	    .weijia-permission-group-row-actions { display: flex; gap: 12px; }
	    .weijia-permission-group-row-actions button {
	      min-height: 32px;
	      border: 0;
	      background: transparent;
	      color: #277cb8;
	      cursor: pointer;
	    }

    @media (max-width: 600px) {
      .weijia-publish-layout,
      .weijia-settings-layout {
        grid-template-columns: minmax(0, 1fr);
        overflow-y: auto;
        padding: 8px;
      }
      .weijia-editor-menu {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }
      .weijia-editor-menu button {
        min-width: 0;
        text-align: center;
        overflow-wrap: anywhere;
      }
      .weijia-editor-content {
        overflow: visible;
        padding: 12px;
      }
	      .weijia-release-shell { overflow-y: auto; }
	      .weijia-release-toolbar { align-items: flex-start; flex-direction: column; }
	      .weijia-release-shell .weijia-publish-layout { height: auto; overflow: visible; }
	      .weijia-workflow-layout {
	        height: auto;
	        overflow-y: auto;
	      }
	      .weijia-workflow-body { grid-template-columns: minmax(0, 1fr); }
	      .weijia-workflow-canvas,
	      .weijia-workflow-property { overflow: visible; }
	      .weijia-workflow-property { border-top: 1px solid #e2e7ec; border-left: 0; }
	      .weijia-permission-drawer { top: 0; width: 100vw; }
	      .weijia-permission-drawer-backdrop { inset: 0; }
	      .weijia-field-permission-table > div { grid-template-columns: minmax(110px, 1fr) 64px 64px; }
    }

    .weijia-editor-menu {
      padding: 8px;
      display: grid;
      align-content: start;
      gap: 4px;
    }

    .weijia-editor-menu button {
      min-height: 42px;
      border: 0;
      border-radius: 4px;
      background: #fff;
      color: #354253;
      text-align: left;
      padding: 0 12px;
      cursor: pointer;
    }

    .weijia-editor-menu button.is-active {
      background: #eef7e7;
      color: #3d7605;
      font-weight: 800;
    }

    .weijia-editor-content {
      padding: 16px;
      overflow-y: auto;
      display: grid;
      gap: 12px;
      align-content: start;
    }

    .weijia-publish-group,
    .weijia-rule-card,
    .weijia-smart-rule-editor {
      border: 1px solid #dfe6ee;
      border-radius: 6px;
      background: #fff;
      padding: 12px;
      display: grid;
      gap: 10px;
    }

    .weijia-rule-card {
      grid-template-columns: 38px minmax(0, 1fr) auto;
      align-items: start;
    }

    .weijia-rule-order {
      width: 28px;
      height: 28px;
      border-radius: 50%;
      display: grid;
      place-items: center;
      background: #eef7e7;
      color: #3d7605;
      font-weight: 900;
      font-size: 13px;
    }

    .weijia-rule-actions {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .weijia-rule-actions button,
    .weijia-rule-editor-actions button {
      min-height: 32px;
      border: 1px solid #dfe6ee;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      padding: 0 10px;
      cursor: pointer;
    }

    .weijia-rule-actions .danger {
      color: #c7473d;
    }

    .weijia-rule-editor-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .weijia-rule-editor-row {
      border: 1px solid #edf2f6;
      border-radius: 4px;
      background: #f8fafc;
      padding: 10px;
      display: grid;
      gap: 4px;
      min-width: 0;
    }

    .weijia-rule-editor-row.is-wide {
      grid-column: 1 / -1;
    }

    .weijia-rule-editor-actions {
      display: flex;
      justify-content: flex-end;
      gap: 8px;
    }

    .weijia-rule-editor-actions .primary {
      border-color: #4f9505;
      background: #5aa10a;
      color: #fff;
      font-weight: 800;
    }

    .weijia-smart-rule-editor.is-hidden {
      display: none;
    }

    .weijia-smart-business-head,
    .weijia-smart-rule-editor-head,
    .weijia-rule-section-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
    }

    .weijia-smart-business-head h4 {
      margin: 0;
      font-size: 16px;
    }

    .weijia-smart-business-head button,
    .weijia-smart-rule-editor-head button,
    .weijia-rule-add {
      min-height: 36px;
      border: 1px solid #d9e3ec;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      padding: 0 12px;
      cursor: pointer;
    }

    .weijia-smart-business-notice {
      border: 1px solid #dbe8cc;
      border-radius: 4px;
      background: #f5faef;
      color: #4b672e;
      padding: 10px 12px;
      font-size: 12px;
      line-height: 1.6;
    }

    .weijia-smart-rule-editor {
      padding: 0;
      overflow: hidden;
    }

    .weijia-smart-rule-editor-head {
      min-height: 54px;
      padding: 0 14px;
      border-bottom: 1px solid #dfe6ee;
      background: #f8fafc;
    }

    .weijia-smart-rule-editor-head > div {
      display: grid;
      gap: 3px;
    }

    .weijia-smart-rule-editor-head span,
    .weijia-rule-section-head span {
      color: #738195;
      font-size: 12px;
    }

    .weijia-smart-rule-editor-head button {
      width: 36px;
      padding: 0;
      font-size: 20px;
    }

    .weijia-smart-business-error {
      margin: 12px 14px 0;
      border-left: 3px solid #d43f32;
      background: #fff2f0;
      color: #aa2f25;
      padding: 9px 10px;
      font-size: 13px;
    }

    .weijia-rule-editor-grid {
      padding: 14px;
    }

    .weijia-rule-field,
    .weijia-rule-section,
    .weijia-rule-block {
      min-width: 0;
    }

    .weijia-rule-field {
      display: grid;
      gap: 6px;
      color: #314054;
      font-size: 13px;
      font-weight: 700;
    }

    .weijia-rule-field input,
    .weijia-rule-field select,
    .weijia-rule-section-head select,
    .weijia-smart-condition-row input,
    .weijia-smart-condition-row select,
    .weijia-smart-mapping-row input,
    .weijia-smart-mapping-row select {
      width: 100%;
      min-width: 0;
      min-height: 36px;
      border: 1px solid #d7e0e9;
      border-radius: 4px;
      background: #fff;
      color: #263548;
      padding: 0 10px;
    }

    .weijia-rule-field input[aria-invalid="true"],
    .weijia-rule-field select[aria-invalid="true"],
    .weijia-smart-condition-row [aria-invalid="true"],
    .weijia-smart-mapping-row [aria-invalid="true"] {
      border-color: #d43f32;
      box-shadow: 0 0 0 2px rgba(212, 63, 50, .12);
    }

    .weijia-rule-section,
    .weijia-rule-block {
      grid-column: 1 / -1;
      display: grid;
      gap: 9px;
      border: 1px solid #e2e8ef;
      border-radius: 4px;
      background: #fbfcfd;
      padding: 11px;
    }

    .weijia-rule-block > .weijia-rule-section {
      border: 0;
      padding: 0;
      background: transparent;
    }

    .weijia-rule-section-head select {
      width: auto;
      min-width: 180px;
      flex: 0 0 auto;
    }

    .weijia-smart-condition-row,
    .weijia-smart-mapping-row {
      display: grid;
      grid-template-columns: minmax(120px, 1.2fr) minmax(106px, .75fr) minmax(128px, .9fr) minmax(150px, 1.35fr) 36px;
      gap: 8px;
      align-items: center;
      margin-top: 8px;
      min-width: 0;
    }

    .weijia-smart-condition-row button,
    .weijia-smart-mapping-row button {
      width: 36px;
      min-height: 36px;
      border: 1px solid #efd3d0;
      border-radius: 4px;
      background: #fff;
      color: #b93429;
      cursor: pointer;
    }

    .weijia-rule-add {
      width: 100%;
      border-style: dashed;
      color: #4a820c;
      font-weight: 700;
    }

    .weijia-rule-editor-actions {
      padding: 12px 14px;
      border-top: 1px solid #dfe6ee;
      background: #f8fafc;
    }

    @media (max-width: 1120px) {
      .weijia-rule-card {
        grid-template-columns: 38px minmax(0, 1fr);
      }

      .weijia-rule-card .weijia-rule-actions {
        grid-column: 2;
      }

      .weijia-smart-condition-row,
      .weijia-smart-mapping-row {
        grid-template-columns: minmax(120px, 1fr) minmax(106px, .8fr) minmax(128px, 1fr) 36px;
      }

      .weijia-smart-condition-row > :nth-child(4),
      .weijia-smart-mapping-row > :nth-child(4) {
        grid-column: 1 / 4;
      }

      .weijia-smart-condition-row > button,
      .weijia-smart-mapping-row > button {
        grid-column: 4;
        grid-row: 1;
      }
    }

    @media (max-width: 760px) {
      .weijia-rule-editor-grid {
        grid-template-columns: minmax(0, 1fr);
      }

      .weijia-smart-business-head,
      .weijia-rule-section-head {
        align-items: stretch;
        flex-direction: column;
      }

      .weijia-rule-section-head select {
        width: 100%;
      }

      .weijia-smart-condition-row,
      .weijia-smart-mapping-row {
        grid-template-columns: minmax(0, 1fr) 36px;
      }

      .weijia-smart-condition-row > :not(button),
      .weijia-smart-mapping-row > :not(button) {
        grid-column: 1;
      }

      .weijia-smart-condition-row > button,
      .weijia-smart-mapping-row > button {
        grid-column: 2;
        grid-row: 1;
      }
    }

    .smart-business-drawer-shell {
      position: fixed;
      inset: 0;
      z-index: 80;
      background: rgba(21, 31, 43, .42);
    }

    .smart-business-drawer-shell.is-hidden {
      display: none;
    }

    .smart-business-drawer {
      position: fixed;
      top: 0;
      right: 0;
      width: min(820px, 72vw);
      height: 100dvh;
      z-index: 81;
      display: grid;
      grid-template-rows: auto minmax(0, 1fr) auto;
      background: #fff;
      border-left: 1px solid #dfe5eb;
      box-shadow: -12px 0 32px rgba(20, 33, 48, .18);
      overflow: hidden;
    }

    .smart-business-drawer-head {
      min-height: 74px;
      padding: 14px 20px;
      border-bottom: 1px solid #e2e7ec;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      background: #fff;
    }

    .smart-business-drawer-head > div {
      min-width: 0;
      display: grid;
      gap: 3px;
    }

    .smart-business-drawer-head b {
      font-size: 18px;
    }

    .smart-business-drawer-head span {
      color: #718094;
      font-size: 13px;
    }

    .smart-business-drawer-close {
      width: 42px;
      min-width: 42px;
      min-height: 42px;
      border: 1px solid #d9e2eb;
      border-radius: 4px;
      background: #fff;
      color: #263548;
      font-size: 22px;
      cursor: pointer;
    }

    .smart-business-drawer-body {
      min-height: 0;
      overflow-y: auto;
      overscroll-behavior: contain;
      padding: 18px 20px 24px;
      display: grid;
      gap: 16px;
      align-content: start;
      background: #fff;
    }

    .smart-business-drawer-footer {
      position: sticky;
      bottom: 0;
      min-height: 68px;
      padding: 12px 20px;
      border-top: 1px solid #dfe5eb;
      background: #f7f9fb;
      display: flex;
      justify-content: flex-end;
      align-items: center;
      gap: 10px;
    }

    .smart-business-drawer-footer button {
      min-height: 42px;
      border: 1px solid #d6e0e9;
      border-radius: 4px;
      background: #fff;
      color: #314054;
      padding: 0 18px;
      cursor: pointer;
    }

    .smart-business-drawer-footer .primary {
      border-color: #e56516;
      background: #ed6a18;
      color: #fff;
      font-weight: 800;
    }

    .smart-business-drawer-footer .test-command {
      margin-right: auto;
      border-color: #8fc1d5;
      color: #17627e;
      background: #f2fbfe;
    }

    .smart-business-formula-control {
      min-width: 0;
    }

    .smart-business-formula-open {
      width: 100%;
      min-height: 38px;
      border: 1px solid #d6e0e9;
      border-radius: 4px;
      background: #fff;
      color: #2d3b4d;
      padding: 8px 10px;
      text-align: left;
      cursor: pointer;
      overflow: hidden;
    }

    .smart-business-formula-open span {
      display: block;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .smart-business-formula-open.is-empty span {
      color: #8a96a6;
    }

    .smart-business-formula-shell {
      position: fixed;
      inset: 0;
      z-index: 92;
      display: grid;
      place-items: center;
      padding: 24px;
      background: rgba(20, 30, 42, .48);
    }

    .smart-business-formula-dialog {
      width: min(1920px, calc(100vw - 32px));
      height: min(1120px, calc(100dvh - 32px));
      min-height: 520px;
      display: grid;
      grid-template-rows: auto minmax(0, 1fr) auto;
      overflow: hidden;
      border: 1px solid #d9e2eb;
      border-radius: 6px;
      background: #fff;
      box-shadow: 0 24px 70px rgba(15, 27, 41, .28);
    }

    .smart-business-formula-head {
      min-height: 74px;
      padding: 14px 20px;
      border-bottom: 1px solid #dfe6ed;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
    }

    .smart-business-formula-head > div {
      display: grid;
      gap: 4px;
    }

    .smart-business-formula-head b {
      font-size: 18px;
    }

    .smart-business-formula-head span,
    .smart-business-formula-help,
    .smart-business-formula-empty {
      color: #718094;
      font-size: 12px;
      line-height: 1.6;
    }

    .smart-business-formula-close {
      width: 40px;
      min-width: 40px;
      min-height: 40px;
      border: 1px solid #d7e0e9;
      border-radius: 4px;
      background: #fff;
      color: #2c394a;
      font-size: 20px;
      cursor: pointer;
    }

    .smart-business-formula-body {
      min-height: 0;
      display: grid;
      grid-template-columns: 230px minmax(260px, .9fr) minmax(360px, 1.2fr);
      overflow: hidden;
    }

    .smart-business-formula-pane {
      min-width: 0;
      min-height: 0;
      padding: 14px;
      border-right: 1px solid #e0e7ee;
      display: grid;
      grid-template-rows: auto auto minmax(0, 1fr);
      gap: 10px;
      overflow: hidden;
    }

    .smart-business-formula-pane:last-child {
      border-right: 0;
      grid-template-rows: auto minmax(160px, 1fr) auto auto;
    }

    .smart-business-formula-pane > b {
      font-size: 14px;
    }

    .smart-business-formula-pane input[type="search"] {
      width: 100%;
      min-height: 36px;
      border: 1px solid #d7e1ea;
      border-radius: 4px;
      padding: 0 10px;
      background: #fff;
    }

    .smart-business-formula-list {
      min-height: 0;
      overflow-y: auto;
      overscroll-behavior: contain;
      display: grid;
      align-content: start;
      gap: 10px;
      padding-right: 3px;
    }

    .smart-business-formula-group {
      display: grid;
      gap: 6px;
    }

    .smart-business-formula-group > b {
      color: #536176;
      font-size: 12px;
    }

    .smart-business-formula-token-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 6px;
    }

    .smart-business-formula-token {
      min-width: 0;
      min-height: 34px;
      border: 1px solid #d9e2ea;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      padding: 5px 8px;
      text-align: left;
      cursor: pointer;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .smart-business-formula-token[data-origin="source"] {
      border-left: 3px solid #3f8ed8;
    }

    .smart-business-formula-token[data-origin="target"] {
      border-left: 3px solid #7bad16;
    }

    .smart-business-formula-token[disabled] {
      color: #9aa5b2;
      background: #f5f7f9;
      cursor: not-allowed;
    }

    .smart-business-formula-editor {
      width: 100%;
      min-height: 180px;
      overflow-y: auto;
      border: 1px solid #cfdbe5;
      border-radius: 4px;
      padding: 12px;
      background: #fbfcfd;
      color: #1f2c3c;
      font: 14px/1.7 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
      white-space: pre-wrap;
      overflow-wrap: anywhere;
      cursor: text;
      outline: none;
    }

    .smart-business-formula-editor:focus {
      border-color: #4b91d8;
      box-shadow: 0 0 0 2px rgba(75, 145, 216, .14);
    }

    .smart-business-formula-editor:empty::before {
      content: attr(data-placeholder);
      color: #9aa6b4;
      pointer-events: none;
    }

    .smart-business-formula-field-chip {
      display: inline-flex;
      align-items: center;
      max-width: 100%;
      min-height: 24px;
      margin: 1px 2px;
      border: 1px solid #9fc5f1;
      border-radius: 3px;
      background: #e8f3ff;
      color: #1768b2;
      padding: 0 7px;
      font: 13px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
      white-space: nowrap;
      vertical-align: baseline;
      user-select: none;
    }

    .smart-business-formula-field-chip[data-scope="target"] {
      border-color: #8ebced;
      background: #dfefff;
      color: #115b9d;
    }

    .smart-business-formula-warning {
      border: 1px solid #e3d5aa;
      border-radius: 4px;
      background: #fff9e8;
      color: #765915;
      padding: 8px 10px;
      font-size: 12px;
      line-height: 1.55;
    }

    .smart-business-formula-validation {
      min-height: 20px;
      color: #c6362b;
      font-size: 12px;
    }

    .smart-business-formula-validation.is-valid {
      color: #3f7e0d;
    }

    .smart-business-formula-footer {
      min-height: 66px;
      padding: 12px 20px;
      border-top: 1px solid #dfe6ed;
      background: #f7f9fb;
      display: flex;
      justify-content: flex-end;
      align-items: center;
      gap: 10px;
    }

    .smart-business-formula-footer button {
      min-height: 40px;
      border: 1px solid #d6e0e9;
      border-radius: 4px;
      background: #fff;
      color: #314054;
      padding: 0 18px;
      cursor: pointer;
    }

    .smart-business-formula-footer .primary {
      border-color: #4f9505;
      background: #5aa10a;
      color: #fff;
      font-weight: 700;
    }

    .smart-business-command-bar {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .smart-business-command-bar button {
      min-height: 36px;
      border: 1px solid #d8e1e9;
      border-radius: 4px;
      background: #fff;
      color: #314054;
      padding: 0 12px;
      cursor: pointer;
    }

    .smart-business-command-bar .primary {
      border-color: #e56516;
      background: #ed6a18;
      color: #fff;
      font-weight: 800;
    }

    .smart-business-command-bar .danger {
      color: #b93429;
    }

    .smart-business-choice-group {
      display: grid;
      gap: 9px;
    }

    .smart-business-choice-group > b,
    .smart-business-section-title > b {
      font-size: 14px;
    }

    .smart-business-choice-grid {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 8px;
    }

    .smart-business-choice-card {
      min-height: 72px;
      border: 1px solid #dce4eb;
      border-radius: 4px;
      background: #fff;
      color: #344256;
      padding: 10px 12px;
      text-align: left;
      display: grid;
      gap: 4px;
      align-content: center;
      cursor: pointer;
    }

    .smart-business-choice-card span {
      color: #738195;
      font-size: 12px;
      line-height: 1.45;
    }

    .smart-business-choice-card.is-selected {
      border-color: #38a8c4;
      background: #ecf9fc;
      color: #12617a;
      box-shadow: inset 0 0 0 1px #38a8c4;
    }

    .smart-business-rule-drawer .weijia-rule-editor-grid {
      padding: 0;
      grid-template-columns: minmax(0, 1fr);
      gap: 16px;
    }

    .smart-business-rule-drawer .weijia-rule-section,
    .smart-business-rule-drawer .weijia-rule-block {
      background: #fff;
      border-color: #dfe5eb;
      padding: 14px;
    }

    .smart-business-row-error {
      grid-column: 1 / -1;
      color: #c6362b;
      font-size: 12px;
      line-height: 1.5;
      min-height: 18px;
    }

    .smart-business-row-error:empty {
      display: none;
    }

    .smart-business-log-filters {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .smart-business-log-filters label {
      display: grid;
      gap: 5px;
      color: #4c5b6d;
      font-size: 12px;
    }

    .smart-business-log-filters input,
    .smart-business-log-filters select {
      width: 100%;
      min-height: 38px;
      border: 1px solid #d8e1e9;
      border-radius: 4px;
      padding: 0 10px;
      background: #fff;
    }

    .smart-business-execution-list {
      display: grid;
      border: 1px solid #dfe5eb;
      border-radius: 4px;
      overflow: hidden;
    }

    .smart-business-execution-row {
      border: 0;
      border-bottom: 1px solid #e7ebef;
      background: #fff;
      color: #2b394a;
      min-height: 62px;
      padding: 10px 12px;
      text-align: left;
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 6px 12px;
      cursor: pointer;
    }

    .smart-business-execution-row:last-child {
      border-bottom: 0;
    }

    .smart-business-execution-row span {
      color: #748196;
      font-size: 12px;
    }

    .smart-business-execution-detail {
      border: 1px solid #dfe5eb;
      border-radius: 4px;
      background: #f8fafc;
      padding: 14px;
      display: grid;
      gap: 10px;
    }

    .smart-business-execution-detail pre {
      margin: 0;
      max-height: 280px;
      overflow: auto;
      white-space: pre-wrap;
      word-break: break-word;
      font-size: 12px;
    }

    @media (max-width: 760px) {
      .smart-business-drawer {
        width: 100vw;
      }

      .smart-business-choice-grid,
      .smart-business-log-filters {
        grid-template-columns: minmax(0, 1fr);
      }

      .smart-business-drawer-body {
        padding: 14px;
      }

      .smart-business-drawer-footer {
        padding: 10px 14px;
        flex-wrap: wrap;
      }

      .smart-business-formula-shell {
        padding: 0;
      }

      .smart-business-formula-dialog {
        width: 100vw;
        height: 100dvh;
        min-height: 0;
        border-radius: 0;
      }

      .smart-business-formula-body {
        grid-template-columns: minmax(0, 1fr);
        overflow-y: auto;
      }

      .smart-business-formula-pane {
        min-height: 260px;
        border-right: 0;
        border-bottom: 1px solid #e0e7ee;
      }
    }

    .store-config-editor-actions {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
    }

    .workflow-form-delivery-shell {
      display: grid;
      gap: 12px;
    }

    .workflow-form-delivery-head,
    .workflow-form-delivery-section {
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fff;
      padding: 14px;
    }

    .workflow-form-delivery-head {
      display: flex;
      justify-content: space-between;
      gap: 12px;
      align-items: flex-start;
    }

    .workflow-form-delivery-head p {
      margin: 4px 0 0;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .workflow-form-delivery-section h4 {
      margin: 0 0 12px;
      font-size: 14px;
    }

    .field {
      display: grid;
      gap: 7px;
    }

    .field label {
      font-size: 13px;
      color: #334155;
      font-weight: 700;
    }

    .field.required label::before {
      content: "";
      display: inline-block;
      width: 6px;
      height: 6px;
      margin-right: 6px;
      border-radius: 999px;
      background: #e53935;
      vertical-align: middle;
      transform: translateY(-1px);
    }

    .condition-help {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    .field input,
    .field textarea,
    .field select {
      width: 100%;
      border: 1px solid var(--line);
      border-radius: 8px;
      background: #fbfcfd;
      min-height: 40px;
      padding: 9px 11px;
      color: var(--ink);
    }

    .field textarea {
      min-height: 116px;
      resize: vertical;
      line-height: 1.6;
    }

    .field.workflow-field-invalid label {
      color: #b42318;
    }

    .field.workflow-field-invalid input,
    .field.workflow-field-invalid textarea,
    .field.workflow-field-invalid select {
      border-color: #d92d20;
      box-shadow: 0 0 0 1px rgba(217, 45, 32, 0.18);
      background: #fff8f7;
    }

    .workflow-field-error {
      display: block;
      margin-top: 2px;
      color: #b42318;
      font-size: 12px;
      line-height: 1.45;
      font-weight: 600;
    }

    .form-actions {
      display: flex;
      justify-content: flex-end;
      gap: 10px;
      padding-top: 10px;
    }

    .micro-reference {
      padding: 12px;
      display: grid;
      gap: 8px;
    }

    .reference-row {
      border: 1px solid var(--line);
      border-radius: 4px;
      padding: 10px;
      background: #fbfcfd;
      display: grid;
      gap: 5px;
    }

    .reference-row b {
      font-size: 13px;
    }

    .reference-row span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    body.is-dashboard,
    body.is-app-page {
      background: #f4f6f8;
      overflow: hidden;
    }

    body.is-dashboard .shell {
      grid-template-columns: minmax(0, 1fr);
    }

    body.is-dashboard .tree {
      display: none;
    }

    body.is-app-page .shell {
      grid-template-columns: 256px minmax(0, 1fr);
    }

    body.is-app-page .tree {
      display: grid;
    }

    body.is-dashboard .content {
      padding: 18px;
    }

    body[data-store-portal-ui-redesign] {
      background: #f4f6f9;
    }

    body[data-store-portal-ui-redesign].is-app-page .shell {
      grid-template-columns: 228px minmax(0, 1fr);
      background: #f4f6f9;
    }

    body[data-store-portal-ui-redesign] .topbar {
      min-height: 52px;
      background: #fff;
      color: #1a2332;
      border-bottom: 1px solid #e2e8ef;
      box-shadow: 0 1px 4px rgba(20, 40, 70, .04);
    }

    body[data-store-portal-ui-redesign] .brand,
    body[data-store-portal-ui-redesign] .top-actions,
    body[data-store-portal-ui-redesign] .top-store-field {
      color: #1a2332;
    }

    body[data-store-portal-ui-redesign] .brand span,
    body[data-store-portal-ui-redesign] .top-actions {
      color: #6b7a8d;
    }

    body[data-store-portal-ui-redesign] .brand-mark {
      background: #52a800;
      border-radius: 8px;
    }

    body[data-store-portal-ui-redesign] .product-tabs button {
      color: #3d4e60;
      min-height: 52px;
    }

    body[data-store-portal-ui-redesign] .product-tabs button.active {
      color: #3d8000;
      background: #f0f8e6;
    }

    body[data-store-portal-ui-redesign] .top-store-field select {
      color: #1a2332;
      background: #fff;
      border-color: #dbe3ea;
    }

    body[data-store-portal-ui-redesign] .top-login-status {
      background: #fff4e0;
      color: #8b5708;
      border-color: #f0d8aa;
    }

    body[data-store-portal-ui-redesign].is-app-page .tree {
      background: #1c2a3a;
      border-right: 0;
      color: #fff;
    }

    body[data-store-portal-ui-redesign] .module-tree-panel {
      background: transparent;
      grid-template-rows: auto auto 1fr;
    }

    body[data-store-portal-ui-redesign] .store-redesign-side-head {
      min-height: auto;
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 10px;
      align-items: start;
      padding: 16px 14px 12px;
      border-bottom: 1px solid rgba(255, 255, 255, .08);
    }

    .store-redesign-store {
      display: grid;
      gap: 2px;
      min-width: 0;
    }

    .store-redesign-store span,
    .store-redesign-store small,
    .store-redesign-user-card small {
      color: rgba(255, 255, 255, .48);
      font-size: 11px;
      line-height: 1.45;
    }

    .store-redesign-store strong,
    .store-redesign-user-card strong {
      color: #fff;
      font-size: 14px;
      line-height: 1.35;
    }

    .store-redesign-back {
      min-height: 30px;
      border-color: rgba(255, 255, 255, .14);
      background: rgba(255, 255, 255, .06);
      color: rgba(255, 255, 255, .82);
    }

    .store-redesign-user-card {
      display: flex;
      align-items: center;
      gap: 10px;
      margin: 10px 12px 6px;
      padding: 10px;
      border: 1px solid rgba(255, 255, 255, .08);
      border-radius: 6px;
      background: rgba(255, 255, 255, .06);
    }

    .store-redesign-user-avatar {
      width: 32px;
      height: 32px;
      border-radius: 50%;
      display: grid;
      place-items: center;
      background: #52a800;
      color: #fff;
      font-size: 13px;
      font-weight: 800;
      flex: 0 0 auto;
    }

    body[data-store-portal-ui-redesign] .app-list {
      padding: 10px 12px 14px;
    }

    body[data-store-portal-ui-redesign] .app-group-title {
      color: rgba(255, 255, 255, .38);
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: .06em;
    }

    body[data-store-portal-ui-redesign] .app-item {
      min-height: 36px;
      color: rgba(255, 255, 255, .68);
      border-radius: 5px;
      padding: 0 12px;
    }

    body[data-store-portal-ui-redesign] .app-item:hover {
      background: rgba(255, 255, 255, .07);
      color: rgba(255, 255, 255, .9);
    }

    body[data-store-portal-ui-redesign] .app-item.active {
      background: rgba(82, 168, 0, .18);
      color: #8fd940;
    }

    body[data-store-portal-ui-redesign] .content-head,
    body[data-store-portal-ui-redesign] .app-content-head,
    body[data-store-portal-ui-redesign] .data-panel,
    body[data-store-portal-ui-redesign] .sales-title-toolbar,
    body[data-store-portal-ui-redesign] .sales-order-toolbar {
      background: #fff;
      border-color: #e2e8ef;
    }

    body[data-phase-one-real-store] [data-low-code-admin-menu="batchOperation"],
    body[data-phase-one-real-store] [data-sales-toolbar-popover="batchOperation"],
    body[data-phase-one-real-store] [data-low-code-admin-action="batchOperation"],
    body[data-phase-one-real-store] [data-module-switch-key="reportingReadonly"] {
      display: none !important;
    }

    .store-workflow-kpi-grid {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 12px;
      margin: 14px 0 0;
    }

    .store-workflow-kpi-grid article {
      min-height: 88px;
      border: 1px solid #e2e8ef;
      border-radius: 8px;
      background: #fff;
      padding: 12px 14px;
      display: grid;
      gap: 4px;
      align-content: center;
      box-shadow: 0 1px 4px rgba(20, 40, 70, .06);
    }

    .store-workflow-kpi-grid span,
    .store-workflow-kpi-grid small {
      color: #6b7a8d;
      font-size: 12px;
      line-height: 1.35;
    }

    .store-workflow-kpi-grid strong {
      color: #1a2332;
      font-size: 22px;
      line-height: 1.1;
    }

    .store-workflow-status-legend {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin: 10px 0 14px;
    }

    .store-workflow-status-legend span {
      min-height: 24px;
      display: inline-flex;
      align-items: center;
      border-radius: 999px;
      padding: 0 9px;
      font-size: 12px;
      font-weight: 700;
    }

    .store-workflow-status-legend [data-status-tone="new"] {
      background: #eef4ff;
      color: #2060c8;
    }

    .store-workflow-status-legend [data-status-tone="reception"] {
      background: #fff4e0;
      color: #b86a00;
    }

    .store-workflow-status-legend [data-status-tone="construction"] {
      background: #f3eeff;
      color: #6b3fa0;
    }

    .store-workflow-status-legend [data-status-tone="payment"] {
      background: #fff0f0;
      color: #c03838;
    }

    .store-workflow-status-legend [data-status-tone="closed"] {
      background: #f0f8e6;
      color: #3d8000;
    }

    .topbar {
      min-height: 48px;
      background: #263342;
      color: #eef3f7;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 20px;
      padding: 0 18px 0 14px;
      border-bottom: 0;
      position: static;
      z-index: 5;
    }

    .brand {
      min-width: 198px;
      min-height: 48px;
      color: #eef3f7;
    }

    .brand-mark {
      width: 30px;
      height: 30px;
      border-radius: 5px;
      display: grid;
      place-items: center;
      background: #182330;
      color: #fff;
      font-weight: 700;
      font-size: 13px;
    }

    .brand span {
      color: #aebbc8;
    }

    .product-tabs {
      display: flex;
      align-items: center;
      gap: 2px;
      min-width: 0;
      flex: 1;
      overflow-x: auto;
    }

    .product-tabs button {
      min-height: 48px;
      border: 0;
      border-bottom: 3px solid transparent;
      background: transparent;
      color: #dce6ef;
      padding: 0 14px;
      white-space: nowrap;
      cursor: pointer;
    }

    .product-tabs button.active {
      color: #fff;
      border-bottom-color: var(--weijia-green);
      background: rgba(255, 255, 255, .06);
      font-weight: 700;
    }

    .top-actions {
      display: flex;
      align-items: center;
      gap: 10px;
      color: #dce6ef;
      font-size: 12px;
      white-space: nowrap;
    }

    .top-store-field {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      color: #dce6ef;
    }

    .top-store-field select {
      min-height: 28px;
      border: 1px solid rgba(255, 255, 255, .28);
      border-radius: 4px;
      background: rgba(255, 255, 255, .08);
      color: #fff;
      padding: 0 8px;
    }

    .top-store-field option {
      color: #213244;
      background: #fff;
    }

    .top-login-status {
      background: rgba(255, 255, 255, .12);
      color: #fff;
      border: 1px solid rgba(255, 255, 255, .2);
    }

    .shell {
      height: calc(100vh - 48px);
      min-height: 0;
      display: grid;
      grid-template-columns: minmax(0, 1fr);
    }

    .tree {
      background: #f7f9fb;
      border-right: 1px solid var(--line);
      display: none;
      grid-template-rows: auto auto 1fr;
      min-width: 0;
      min-height: 0;
      overflow: hidden;
    }

    .tree-head {
      padding: 15px 14px 12px;
      border-bottom: 1px solid var(--line);
      background: #fff;
    }

    .tree-title {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      margin-bottom: 10px;
    }

    .tree-title h1 {
      margin: 0;
      font-size: 16px;
      line-height: 1.25;
    }

    .tree-filter {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      padding: 10px;
      gap: 4px;
      border-bottom: 1px solid var(--line);
      background: #fff;
    }

    .tree-filter button,
    .app-item {
      border: 0;
      border-radius: 4px;
      background: transparent;
      color: #3d4b5b;
      min-height: 30px;
      text-align: left;
      padding: 0 10px;
      cursor: pointer;
    }

    .tree-filter button.active,
    .app-item.active {
      background: #eef7e7;
      color: #3d7605;
      font-weight: 700;
    }

    .module-tree-panels,
    .module-tree-panel.active {
      display: grid;
      min-height: 0;
    }

    .module-tree-panel {
      display: none;
      grid-template-rows: auto auto 1fr;
      background: #fff;
      min-height: 0;
    }

    .app-side-head {
      min-height: 48px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      padding: 0 12px;
      border-bottom: 1px solid var(--line);
    }

    .app-side-actions {
      display: grid;
      gap: 8px;
      padding: 12px;
      border-bottom: 1px solid var(--line);
    }

    .app-action-row {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 8px;
    }

    .inline-search,
    .search {
      width: 100%;
      height: 32px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
      color: #2e3b48;
      padding: 0 10px;
      font-size: 13px;
    }

    .app-list {
      display: grid;
      align-content: start;
      gap: 4px;
      padding: 12px;
      overflow: auto;
    }

    .app-group-title {
      color: var(--muted);
      font-size: 12px;
      font-weight: 700;
      padding: 10px 10px 4px;
    }

    .content {
      min-width: 0;
      min-height: 0;
      padding: 0;
      display: block;
      overflow: auto;
    }

    .content-head {
      min-height: 64px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      padding: 0 18px;
      border-bottom: 1px solid var(--line);
      background: #fff;
    }

    .title-stack {
      display: grid;
      gap: 3px;
    }

    .crumb {
      margin: 0;
      color: var(--muted);
      font-size: 12px;
    }

    .content-head h2 {
      margin: 0;
      font-size: 18px;
      line-height: 1.25;
    }

    .head-tools {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
      justify-content: flex-end;
    }

    .store-workflow-head-tools {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
      justify-content: flex-end;
    }

    .store-workflow-runtime-status {
      min-height: 28px;
      display: inline-flex;
      align-items: center;
      border: 1px solid #c5e89a;
      border-radius: 999px;
      background: #f0f8e6;
      color: #3d8000;
      padding: 0 10px;
      font-size: 12px;
      font-weight: 700;
      white-space: nowrap;
    }

    .page {
      display: grid;
      gap: 14px;
      padding: 18px;
    }

    .page[hidden] {
      display: none !important;
    }

    .page.active {
      display: grid;
    }

    .panel-body {
      padding: 14px;
    }

    @font-face {
      font-family: "Material Symbols Rounded";
      font-style: normal;
      font-weight: 100 700;
      src: url("./assets/material-symbols-rounded.woff2") format("woff2");
      font-display: block;
    }

    .material-symbols-rounded {
      font-family: "Material Symbols Rounded";
      font-weight: normal;
      font-style: normal;
      font-size: 24px;
      line-height: 1;
      letter-spacing: normal;
      text-transform: none;
      display: inline-block;
      white-space: nowrap;
      word-wrap: normal;
      direction: ltr;
      font-feature-settings: "liga";
      -webkit-font-feature-settings: "liga";
      -webkit-font-smoothing: antialiased;
    }

    .home-module-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 14px;
    }

    .module-tile {
      min-height: 156px;
      border: 1px solid var(--line);
      border-radius: 6px;
      background: #fff;
      box-shadow: var(--shadow);
      padding: 18px;
      display: grid;
      align-content: center;
      justify-items: center;
      gap: 12px;
      color: #263445;
      cursor: pointer;
    }

    .module-icon {
      width: 42px;
      height: 42px;
      border-radius: 8px;
      display: grid;
      place-items: center;
      background: #eef7e7;
      color: #4f9505;
      font-size: 18px;
      font-weight: 700;
    }

    .module-tile strong {
      font-size: 16px;
      line-height: 1.35;
      text-align: center;
    }

    body.is-dashboard {
      --home-bg: #090a0d;
      --home-card: #15171c;
      --home-card-2: #1b1d22;
      --home-line: rgba(255, 255, 255, .09);
      --home-muted: #a6a9b2;
      --home-accent: #e8f719;
      background: var(--home-bg);
      color: #f7f7f5;
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .topbar,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .content {
      background: var(--home-bg);
      color: #f7f7f5;
      border-color: var(--home-line);
    }

    body.is-dashboard .topbar-title,
    body.is-dashboard .topbar-meta,
    body.is-dashboard .topbar-date {
      color: #f7f7f5;
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .icon-btn {
      border-color: var(--home-line);
      background: rgba(255,255,255,.08);
      color: #f7f7f5;
      border-radius: 12px;
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .icon-btn:hover {
      background: rgba(255,255,255,.14);
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .icon-btn.active {
      border-color: var(--home-accent);
      background: var(--home-accent);
      color: #111318;
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .topbar-meta {
      min-height: 32px;
      border: 1px solid var(--home-line);
      border-radius: 12px;
      background: rgba(255,255,255,.08);
      color: #f7f7f5;
      padding: 0 11px;
      cursor: pointer;
    }

    body.is-dashboard [data-page="dashboard"] {
      max-width: 1500px;
      margin: 0 auto;
      padding: 18px 0 32px;
    }

    .home-dashboard-shell {
      display: grid;
      gap: 22px;
    }

    .home-dashboard-intro {
      display: flex;
      align-items: end;
      justify-content: space-between;
      gap: 24px;
      padding: 4px 2px 0;
    }

    .home-dashboard-intro h1 {
      margin: 0;
      font-size: clamp(30px, 3vw, 46px);
      line-height: 1.05;
      letter-spacing: -.04em;
    }

    .home-dashboard-intro h1 span { color: var(--home-accent); }
    .home-dashboard-intro p { margin: 10px 0 0; color: var(--home-muted); font-size: 14px; }
    .home-dashboard-eyebrow { color: var(--home-muted); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }

    .home-module-grid.home-module-bento {
      grid-template-columns: repeat(5, minmax(0, 1fr));
      grid-auto-rows: minmax(144px, auto);
      gap: 14px;
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .module-tile {
      min-height: 0;
      border: 1px solid var(--home-line);
      border-radius: 24px;
      background: linear-gradient(145deg, rgba(255,255,255,.075), rgba(255,255,255,.025));
      box-shadow: 0 18px 50px rgba(0, 0, 0, .22);
      padding: 20px;
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      justify-content: space-between;
      gap: 18px;
      color: #f7f7f5;
      text-align: left;
      overflow: hidden;
      position: relative;
      opacity: 0;
      transform: translateY(14px);
      animation: home-card-enter .52s cubic-bezier(.2,.75,.25,1) forwards;
      animation-delay: calc(var(--home-card-index, 0) * 55ms);
      transition: transform .24s ease, border-color .24s ease, background .24s ease;
    }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .module-tile:hover {
      transform: translateY(-4px);
      border-color: rgba(232,247,25,.38);
      background: linear-gradient(145deg, rgba(255,255,255,.1), rgba(255,255,255,.035));
    }

    body.is-dashboard .module-tile:focus-visible,
    .home-todo-row:focus-visible,
    .home-dashboard-retry:focus-visible { outline: 2px solid var(--home-accent); outline-offset: 3px; }

    body.is-dashboard .module-icon {
      width: 48px;
      height: 48px;
      border-radius: 16px;
      background: rgba(255,255,255,.08);
      color: #f7f7f5;
      font-size: 25px;
      transition: transform .24s ease, color .24s ease;
    }

    body.is-dashboard .module-tile:hover .module-icon { transform: rotate(-6deg) scale(1.06); color: var(--home-accent); }
    body.is-dashboard .module-tile strong { color: #f7f7f5; font-size: 17px; text-align: left; }
    .home-module-copy { display: grid; gap: 5px; }
    .home-module-copy small { color: var(--home-muted); font-size: 12px; line-height: 1.45; }
    .home-module-arrow { position: absolute; right: 18px; top: 18px; color: #737780; font-size: 20px; }

    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .home-module-primary {
      grid-column: span 2;
      grid-row: span 2;
      padding: 28px;
      background:
        radial-gradient(circle at 78% 18%, rgba(232,247,25,.18), transparent 28%),
        linear-gradient(145deg, #22252a, #121418);
    }

    .home-module-primary .module-icon {
      width: 62px !important;
      height: 62px !important;
      border-radius: 20px !important;
      background: var(--home-accent) !important;
      color: #111318 !important;
      animation: home-accent-breathe 3.2s ease-in-out infinite;
    }

    .home-module-primary strong { font-size: clamp(25px, 2.2vw, 36px) !important; letter-spacing: -.03em; }
    .home-module-primary .home-module-copy small { max-width: 320px; font-size: 14px; }

    .home-dashboard-summary {
      display: grid;
      grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr);
      gap: 14px;
    }

    .home-summary-card {
      min-width: 0;
      border: 1px solid var(--home-line);
      border-radius: 24px;
      background: var(--home-card);
      padding: 22px;
      box-shadow: 0 18px 50px rgba(0,0,0,.18);
    }

    .home-summary-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
    .home-summary-head h2 { margin: 0; color: #f7f7f5; font-size: 19px; }
    .home-summary-head span { color: var(--home-muted); font-size: 12px; }
    .home-todo-list { display: grid; gap: 8px; }
    .home-todo-row {
      width: 100%; min-height: 54px; border: 1px solid transparent; border-radius: 15px;
      background: rgba(255,255,255,.045); color: #f7f7f5; padding: 0 14px;
      display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 12px;
      text-align: left; cursor: pointer; transition: background .2s ease, border-color .2s ease, transform .2s ease;
    }
    .home-todo-row:hover { background: rgba(255,255,255,.075); border-color: rgba(232,247,25,.22); transform: translateX(3px); }
    .home-todo-row .material-symbols-rounded { color: var(--home-accent); font-size: 20px; }
    .home-todo-count { min-width: 30px; height: 30px; padding: 0 9px; border-radius: 999px; display: grid; place-items: center; background: var(--home-accent); color: #111318; font-weight: 800; }
    .home-todo-chevron { color: #777b84 !important; }
    .home-metric-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
    .home-metric { min-height: 112px; border-radius: 17px; background: var(--home-card-2); padding: 16px; display: grid; align-content: space-between; gap: 14px; }
    .home-metric .material-symbols-rounded { color: var(--home-muted); font-size: 21px; }
    .home-metric-label { color: var(--home-muted); font-size: 12px; }
    .home-metric-value { color: #f7f7f5; font-size: 30px; font-weight: 800; line-height: 1; }
    .home-dashboard-error { display: none; color: #ffd2d2; font-size: 13px; align-items: center; gap: 10px; }
    [data-home-dashboard-summary][data-state="error"] .home-dashboard-error { display: flex; }
    .home-dashboard-retry { border: 1px solid rgba(255,255,255,.16); border-radius: 999px; background: transparent; color: #fff; padding: 6px 12px; cursor: pointer; }

    @keyframes home-card-enter { to { opacity: 1; transform: translateY(0); } }
    @keyframes home-accent-breathe { 0%, 100% { box-shadow: 0 0 0 0 rgba(232,247,25,.12); } 50% { box-shadow: 0 0 0 10px rgba(232,247,25,0); } }

    @media (max-width: 1100px) {
      .home-module-grid.home-module-bento { grid-auto-rows: minmax(132px, auto); }
      body.is-dashboard .module-tile { padding: 16px; border-radius: 20px; }
      .home-module-copy small { display: none; }
    }

    @media (max-width: 820px) {
      .home-module-grid.home-module-bento { grid-template-columns: repeat(2, minmax(0,1fr)); }
      body.is-dashboard .home-module-primary { grid-column: span 2; grid-row: span 1; min-height: 220px; }
      .home-dashboard-summary { grid-template-columns: 1fr; }
    }

    @media (prefers-reduced-motion: reduce) {
      body.is-dashboard .module-tile,
      .home-module-primary .module-icon { animation: none; opacity: 1; transform: none; transition: none; }
    }

    .app-workspace {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      min-height: calc(100vh - 148px);
      background: #fff;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
      overflow: hidden;
    }

    .app-sidebar {
      border-right: 1px solid var(--line);
      background: #fbfcfd;
      min-width: 0;
      display: grid;
      grid-template-rows: auto auto 1fr;
    }

    .app-content {
      min-width: 0;
      display: grid;
      align-content: start;
      gap: 14px;
      padding: 14px;
      background: #fff;
    }

	    .app-content-head {
	      min-height: 50px;
	      display: flex;
	      align-items: center;
	      justify-content: space-between;
      gap: 14px;
	      padding-bottom: 12px;
	      border-bottom: 1px solid var(--line);
	    }

	    .app-content-actions {
	      display: flex;
	      align-items: center;
	      gap: 8px;
	      flex-wrap: wrap;
	      justify-content: flex-end;
	    }

    .settings-account {
      display: grid;
      gap: 12px;
      padding: 16px;
      border-bottom: 1px solid var(--line);
      background: #fbfcfd;
    }

    .settings-account.requires-login {
      border: 1px solid #f5b84b;
      box-shadow: 0 0 0 3px rgba(245, 184, 75, 0.18);
      background: #fffaf0;
    }

    .settings-account b {
      display: block;
      font-size: 14px;
      margin-bottom: 4px;
    }

    .settings-account span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .settings-account .login-bar {
      padding: 0;
      border: 0;
    }

    .settings-account .login-bar input {
      width: 220px;
    }

    .settings-workbench {
      display: grid;
      grid-template-columns: minmax(180px, 220px) minmax(0, 1fr);
      gap: 14px;
      align-items: start;
      margin-top: 14px;
    }

    .settings-nav-list,
    .settings-section-stack,
    .settings-side-summary {
      display: grid;
      gap: 10px;
      min-width: 0;
    }

    .settings-nav-list {
      position: sticky;
      top: 12px;
      padding: 10px;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: #fff;
    }

    .settings-nav-list button {
      min-height: 44px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      width: 100%;
      padding: 10px 12px;
      border: 1px solid transparent;
      border-radius: 8px;
      background: transparent;
      color: var(--text);
      font: inherit;
      text-align: left;
      cursor: pointer;
    }

    .settings-nav-list button.is-active,
    .settings-nav-list button:hover {
      border-color: #dce7f1;
      background: #f6f9fc;
    }

    .settings-section-card {
      display: grid;
      gap: 12px;
      padding: 14px;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: #fff;
    }

    .settings-section-card header {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      gap: 12px;
      flex-wrap: wrap;
    }

    .settings-section-card h3,
    .settings-section-card p {
      margin: 0;
    }

    .settings-section-card p {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .settings-metric-grid,
    .settings-title-field-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 8px;
    }

    .settings-metric,
    .settings-title-field {
      min-height: 44px;
      display: flex;
      align-items: center;
      gap: 8px;
      padding: 10px;
      border: 1px solid #e4edf5;
      border-radius: 8px;
      background: #fbfcfd;
    }

    .settings-metric {
      display: grid;
      gap: 2px;
    }

    .settings-metric b,
    .settings-title-field span {
      font-size: 13px;
      color: var(--text);
    }

    .settings-title-preview {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      min-height: 44px;
      padding: 10px 12px;
      border: 1px solid #d8e8f5;
      border-radius: 8px;
      background: #f5f9fd;
      overflow: hidden;
    }

    .settings-title-preview output {
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      color: var(--text);
      font-weight: 700;
    }

    .settings-config-actions {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .settings-builder-panel {
      display: grid;
      gap: 12px;
      margin-top: 14px;
      padding: 16px;
      border: 1px solid var(--line);
      background: #fbfcfd;
    }

    .settings-builder-panel b {
      display: block;
      font-size: 14px;
      margin-bottom: 4px;
    }

    .settings-builder-panel span {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .settings-builder-panel .app-side-actions {
      padding: 0;
      border: 0;
      background: transparent;
    }

    .settings-config-registry {
      display: grid;
      gap: 8px;
      padding: 12px;
      border: 1px dashed #c9d8e5;
      border-radius: var(--radius);
      background: #fff;
    }

    .settings-config-registry header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      flex-wrap: wrap;
    }

    .settings-config-row {
      display: grid;
      grid-template-columns: minmax(120px, 180px) minmax(0, 1fr);
      gap: 10px;
      padding-top: 8px;
      border-top: 1px solid #edf2f6;
    }

    .settings-config-row b {
      margin: 0;
    }

    .settings-config-note {
      margin: 0;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.6;
    }

    .settings-config-list {
      display: grid;
      gap: 6px;
      margin: 0;
      padding: 0;
      list-style: none;
    }

    .settings-config-list li {
      display: grid;
      grid-template-columns: 36px minmax(110px, 180px) minmax(0, 1fr);
      align-items: center;
      gap: 10px;
      padding: 8px 0;
      border-top: 1px solid #edf2f6;
    }

    .settings-config-list .order {
      display: inline-grid;
      width: 24px;
      height: 24px;
      place-items: center;
      border: 1px solid var(--line);
      border-radius: 50%;
      color: var(--muted);
      font-size: 12px;
    }

    [data-settings-desktop-message] {
      margin: 14px 0 0;
      padding: 14px;
      border: 1px solid #f0c36d;
      border-radius: var(--radius);
      background: #fff8e8;
      color: #704b00;
    }

    [data-settings-root][data-settings-desktop-only="blocked"] [data-settings-workbench] {
      display: none;
    }

    @media (max-width: 1100px) {
      .settings-workbench {
        grid-template-columns: 1fr;
      }

      .settings-nav-list {
        position: static;
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }
    }

    @media (max-width: 720px) {
      .settings-metric-grid,
      .settings-title-field-grid,
      .settings-nav-list {
        grid-template-columns: 1fr;
      }
    }

    .store-field {
      display: flex;
      align-items: center;
      gap: 8px;
      color: #445266;
      font-size: 13px;
    }

    .store-field select {
      height: 32px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
      padding: 0 10px;
    }

    .data-panel {
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: #fff;
      overflow: hidden;
    }

    .data-toolbar {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
      padding: 12px;
      border-bottom: 1px solid var(--line);
      background: #fbfcfd;
    }

    .sales-title-actions,
    .sales-title-toolbar,
    .sales-order-toolbar {
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .sales-title-toolbar {
      justify-content: space-between;
      padding: 10px 12px;
      border-bottom: 1px solid var(--line);
      background: #fff;
    }

    .sales-title-main {
      display: inline-flex;
      align-items: center;
      gap: 14px;
      min-width: 0;
    }

    .sales-title-main h3 {
      margin: 0;
      color: rgba(0, 0, 0, .85);
      font-size: 18px;
      font-weight: 600;
    }

    .sales-title-actions {
      justify-content: flex-end;
    }

	    .sales-order-toolbar {
	      position: relative;
	      justify-content: space-between;
	      padding: 10px 14px;
	      border-bottom: 1px solid var(--line);
	      background: #fff;
	      min-height: 58px;
	    }

	    .sales-order-primary-toolbar {
	      display: flex;
	      align-items: center;
	      gap: 8px;
	      flex-wrap: wrap;
	    }

	    .sales-order-toolbar .btn {
	      height: 32px;
	      min-height: 32px;
	      border-radius: 4px;
	      padding: 0 14px;
	      background: #fff;
	      border-color: #d9e1ea;
	      color: #223247;
	      box-shadow: 0 1px 0 rgba(16, 35, 56, .02);
	    }

	    .sales-order-toolbar .btn:hover:not(:disabled) {
	      border-color: #8fc46b;
	      color: #2f7100;
	    }

	    .sales-order-toolbar .btn.primary {
	      border-color: #4f9505;
	      background: #52a000;
	      color: #fff;
	      box-shadow: 0 1px 0 rgba(42, 86, 0, .12);
	    }

	    .sales-order-toolbar .btn:disabled {
	      opacity: 1;
	      cursor: not-allowed;
	    }

	    .sales-order-toolbar .inline-search {
	      width: 264px;
	      height: 32px;
	      border-color: #d9e1ea;
	      border-radius: 4px;
	      background: #fff;
	      font-size: 13px;
	    }

    .toolbar-more {
      position: relative;
    }

    .toolbar-more summary {
      list-style: none;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 34px;
      height: 32px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fff;
      color: #2f3c4a;
      cursor: pointer;
      font-size: 20px;
      line-height: 1;
      user-select: none;
    }

    .toolbar-more summary::-webkit-details-marker {
      display: none;
    }

	    .toolbar-more[open] summary {
	      border-color: #8fc46b;
	      box-shadow: 0 0 0 2px rgba(82, 153, 28, .12);
	    }

	    .toolbar-more:not([open]) .toolbar-more-menu {
	      display: none;
	    }

	    .toolbar-more-menu {
	      position: absolute;
	      z-index: 20;
      right: 0;
      top: calc(100% + 6px);
      display: grid;
      grid-template-columns: repeat(2, minmax(92px, 1fr));
      gap: 6px;
      width: 220px;
      padding: 8px;
      border: 1px solid var(--line);
      border-radius: 6px;
      background: #fff;
      box-shadow: 0 12px 30px rgba(18, 32, 48, .14);
    }

    .toolbar-more-menu .btn {
      justify-content: flex-start;
      background: #fff;
    }

	    .toolbar-admin-menu-contract {
	      display: inline-flex;
	      align-items: center;
	      gap: 0;
	      align-content: center;
	      position: static;
	    }

	    .toolbar-admin-menu-contract .btn {
	      width: auto;
	    }

	    .toolbar-admin-subactions {
	      display: none;
	      padding: 0 4px;
	      color: var(--muted);
	      font-size: 11px;
	      line-height: 1.35;
	    }

    .filter-hint {
      flex: 1 1 100%;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

			    .sales-order-filter-panel,
	    .sales-toolbar-popover,
	    .sales-order-column-popover,
	    .sales-display-field-popover {
	      flex: 1 1 100%;
	      display: grid;
	      gap: 8px;
      padding: 10px;
      border: 1px solid #cfdbe6;
      border-radius: 4px;
      background: #fff;
      color: #34495f;
      font-size: 12px;
    }

    .sales-order-filter-panel {
      position: absolute;
      right: 12px;
      top: calc(100% + 6px);
      z-index: 12;
      width: min(560px, calc(100vw - 24px));
      padding: 0;
      gap: 0;
      overflow: visible;
      border-color: #e4e8ee;
      border-radius: 6px;
      box-shadow: 0 16px 34px rgba(20, 35, 52, .18);
    }

	    .sales-toolbar-popover {
	      position: absolute;
	      right: 12px;
      top: calc(100% + 6px);
      z-index: 13;
      width: 520px;
	      box-shadow: 0 12px 28px rgba(20, 35, 52, .14);
	    }

    .sales-order-column-popover {
      position: fixed;
      z-index: 40;
      width: min(360px, calc(100vw - 32px));
      max-height: min(420px, calc(100vh - 48px));
      overflow: auto;
      box-shadow: 0 18px 42px rgba(20, 35, 52, .20);
    }

	    .sales-display-field-popover {
	      position: absolute;
	      left: 0;
	      top: calc(100% + 10px);
	      z-index: 15;
	      width: 340px;
	      max-height: 468px;
	      padding: 0;
	      gap: 0;
	      overflow: hidden;
	      border-color: #e5e9ef;
	      border-radius: 6px;
	      box-shadow: 0 16px 36px rgba(18, 32, 48, .16);
	    }

	    .sales-display-field-popover::before {
	      content: "";
	      position: absolute;
	      left: 28px;
	      top: -8px;
	      width: 16px;
	      height: 16px;
	      transform: rotate(45deg);
	      background: #fff;
	      border-left: 1px solid #e5e9ef;
	      border-top: 1px solid #e5e9ef;
	    }

	    .sales-order-filter-panel.is-collapsed,
	    .sales-toolbar-popover.is-collapsed,
	    .sales-order-column-popover.is-collapsed,
	    .sales-display-field-popover.is-collapsed {
	      display: none;
	    }

    .sales-toolbar-popover.is-collapsed {
      display: none;
    }

    .sales-toolbar-popover-head,
    .sales-toolbar-popover-actions,
    .sales-order-column-popover-row {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .sales-toolbar-popover input[type="search"],
    .sales-order-column-popover input,
    .sales-display-field-search-row input {
      min-height: 32px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fff;
      color: #213244;
      padding: 0 10px;
    }

    .sales-order-filter-builder {
      display: grid;
      gap: 10px;
      padding: 12px;
      background: #fff;
    }

    .sales-order-filter-header {
      display: flex;
      align-items: center;
      gap: 10px;
      color: #4f5762;
      font-size: 12px;
      line-height: 1.3;
    }

    .sales-order-filter-logic {
      min-height: 28px;
      border: 0;
      background: transparent;
      color: #1688f5;
      font: inherit;
      cursor: pointer;
    }

    .sales-order-filter-add {
      justify-self: start;
      border: 0;
      background: transparent;
      color: #1688f5;
      font-size: 12px;
      line-height: 1.4;
      cursor: pointer;
    }

    .sales-order-filter-conditions {
      display: grid;
      gap: 8px;
    }

    .sales-order-filter-condition {
      display: grid;
      grid-template-columns: 150px 120px minmax(210px, 1fr) 24px;
      align-items: center;
      gap: 6px;
    }

    .sales-order-filter-label {
      color: #50565d;
      font-size: 12px;
      line-height: 1.4;
    }

    .sales-order-filter-field,
    .sales-order-filter-control,
    .sales-order-filter-value select,
    .sales-order-filter-value input,
    .sales-order-filter-date-range {
      min-height: 28px;
      border: 1px solid #d5d7db;
      border-radius: 4px;
      background: #fff;
      color: #555f69;
      font-size: 12px;
      padding: 0 8px;
    }

    .sales-order-filter-field,
    .sales-order-filter-value select,
    .sales-order-filter-value input {
      width: 100%;
    }

    .sales-order-filter-value input::placeholder,
    .sales-order-filter-date-range input::placeholder {
      color: #b3b7be;
    }

    .sales-order-filter-date-range {
      position: relative;
      display: grid;
      grid-template-columns: 1fr auto 1fr;
      align-items: center;
      gap: 4px;
      color: #a9aeb6;
    }

    .sales-order-filter-date-range input {
      min-width: 0;
      min-height: 26px;
      border: 0;
      background: transparent;
      color: #555f69;
      font-size: 12px;
      text-align: center;
      outline: 0;
    }

    .sales-order-filter-calendar {
      position: absolute;
      right: 0;
      top: calc(100% + 6px);
      z-index: 20;
      display: grid;
      width: min(302px, calc(100vw - 24px));
      border: 1px solid #dce3ea;
      border-radius: 6px;
      background: #fff;
      color: #596676;
      font-size: 12px;
      box-shadow: 0 12px 28px rgba(20, 35, 52, .16);
    }

    .sales-order-filter-calendar[hidden] {
      display: none;
    }

    .sales-order-filter-calendar-hint {
      min-height: 38px;
      display: grid;
      place-items: center;
      color: #7a8795;
    }

    .sales-order-filter-calendar-quick {
      display: flex;
      flex-wrap: wrap;
      gap: 4px;
      padding: 7px;
      border-top: 1px solid #e9edf2;
    }

    .sales-order-filter-calendar-quick button {
      min-height: 24px;
      border: 1px solid #dce3ea;
      border-radius: 4px;
      background: #f8fafc;
      color: #446078;
      padding: 0 7px;
      font-size: 11px;
      cursor: pointer;
    }

    .sales-order-filter-delete {
      min-height: 28px;
      border: 0;
      background: transparent;
      color: #9ca3ad;
      font-size: 18px;
      line-height: 1;
      cursor: pointer;
    }

    .sales-order-filter-footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 10px 12px;
      border-top: 1px solid #e9edf2;
      background: #fff;
    }

    .sales-order-filter-save-common {
      border: 0;
      background: transparent;
      color: #1688f5;
      font-size: 12px;
      cursor: pointer;
    }

    @media (max-width: 620px) {
      .sales-order-filter-panel {
        position: fixed;
        left: 12px;
        right: 12px;
        top: 72px;
        width: auto;
        max-width: none;
        max-height: calc(100vh - 96px);
        overflow-y: auto;
      }

      .sales-order-filter-condition {
        grid-template-columns: 1fr;
      }

      .sales-order-filter-delete {
        justify-self: end;
      }

      .sales-order-filter-calendar {
        right: auto;
        left: 0;
        width: min(302px, calc(100vw - 48px));
        max-width: calc(100vw - 24px);
      }
    }

    .sales-toolbar-popover-head {
      justify-content: space-between;
    }

	    .sales-toolbar-popover-actions {
	      justify-content: flex-end;
	      padding-top: 4px;
	      border-top: 1px solid #eef2f6;
	    }

	    .sales-display-field-search-row {
	      display: flex;
	      align-items: center;
	      gap: 8px;
	      padding: 12px 18px;
	      border-bottom: 1px solid #eef2f6;
	      color: #98a4b3;
	    }

	    .sales-display-field-search-row input {
	      flex: 1;
	      min-height: 34px;
	      border: 0;
	      padding: 0;
	      font-size: 16px;
	      color: #263445;
	      box-shadow: none;
	    }

	    .sales-display-field-search-row input::placeholder {
	      color: #aeb6c1;
	    }

	    .sales-display-field-list,
	    .sales-display-list {
	      display: grid;
	      gap: 0;
	      max-height: 338px;
	      overflow: auto;
	      padding: 0;
	      scrollbar-color: #c1c7d0 transparent;
	    }

	    .sales-display-field-list label,
	    .sales-display-list label,
	    .sales-display-select-all {
	      min-height: 42px;
	      display: flex;
	      align-items: center;
	      justify-content: flex-start;
	      gap: 10px;
	      padding: 0 18px;
	      border: 0;
	      border-radius: 0;
	      background: #fff;
	      color: #545b65;
	      font-size: 16px;
	      line-height: 1.35;
	      cursor: pointer;
	    }

	    .sales-display-field-list label > span,
	    .sales-display-list label > span {
	      min-width: 0;
	      overflow: hidden;
	      text-overflow: ellipsis;
	      white-space: nowrap;
	      line-height: 1.35;
	    }

	    .sales-display-field-list input[type="checkbox"],
	    .sales-display-list input[type="checkbox"],
	    .sales-display-select-all input[type="checkbox"] {
	      flex: 0 0 auto;
	      width: 18px;
	      height: 18px;
	      margin: 0;
	      accent-color: #2688ef;
	    }

	    .sales-display-field-list label:has(input:not(:checked)),
	    .sales-display-list label:has(input:not(:checked)),
	    .sales-display-select-all:has(input:not(:checked)) {
	      color: #8a94a3;
	      background: #fff;
	      text-decoration: none;
	    }

	    .sales-display-field-list label.is-filter-hidden,
	    .sales-display-list label.is-filter-hidden {
	      display: none;
	    }

	    .sales-display-field-actions {
	      display: flex;
	      justify-content: flex-end;
	      gap: 10px;
	      padding: 12px 18px;
	      border-top: 1px solid #eef2f6;
	      background: #fff;
	    }

	    .sales-display-field-actions .btn {
	      min-width: 76px;
	      min-height: 34px;
	      font-size: 15px;
	    }

	    .sales-display-field-actions .btn.primary {
	      background: #ff9900;
	      border-color: #ff9900;
	    }

    .batch-action-list {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 8px;
    }

    .popover-muted,
    .sales-order-filter-active-list {
      margin: 0;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    .sales-order-filter-active-list {
      padding-top: 4px;
      border-top: 1px solid #eef2f6;
    }

    .filter-chip {
      display: inline-flex;
      align-items: center;
      max-width: 100%;
      margin: 2px 6px 2px 0;
      padding: 2px 8px;
      border-radius: 4px;
      background: #eef7e8;
      color: #2f7100;
      white-space: nowrap;
    }

    .sales-order-column-menu-list {
      display: flex;
      gap: 6px;
      flex-wrap: wrap;
      max-height: 112px;
      overflow: auto;
    }

    .sales-order-column-menu-list label {
      display: inline-flex;
      align-items: center;
      gap: 4px;
      min-height: 28px;
      border: 1px solid var(--line);
      border-radius: 4px;
      padding: 0 8px;
      background: #fbfcfd;
      white-space: nowrap;
    }

    .sr-only {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      white-space: nowrap;
      border: 0;
    }

    .linked-sales-summary {
      display: grid;
      gap: 6px;
      grid-column: 1 / -1;
      padding: 10px;
      border: 1px solid #cfe3f5;
      border-radius: 4px;
      background: #f6fbff;
      color: #34495f;
      font-size: 13px;
      line-height: 1.55;
    }

    .linked-sales-summary b {
      color: #203247;
    }

    .sales-order-review-strip {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 8px;
      padding: 10px;
      border: 1px solid #d8e3ec;
      border-radius: 4px;
      background: #fff;
      color: #34495f;
      font-size: 12px;
      line-height: 1.45;
    }

    .sales-review-item {
      display: grid;
      gap: 3px;
      min-width: 0;
    }

    .sales-review-item b {
      color: #203247;
      font-size: 13px;
    }

    .sales-review-item span {
      color: var(--muted);
    }

    .weijia-table-scroll {
      width: 100%;
      overflow-x: auto;
      border-top: 1px solid var(--line);
      min-height: 360px;
      background: #fff;
    }

	    .weijia-record-table.sales-order-weijia-table {
	      display: table;
	      border-collapse: collapse;
	      min-width: 100%;
	      width: max-content;
	      table-layout: auto;
	      font-size: 13px;
	    }

	    .sales-order-weijia-table th,
	    .sales-order-weijia-table td {
	      height: 34px;
	      border-right: 1px solid #e8e8e8;
	      border-bottom: 1px solid #e8e8e8;
	      padding: 6px 14px;
	      text-align: left;
	      overflow: hidden;
	      text-overflow: ellipsis;
	      white-space: nowrap;
	      vertical-align: middle;
    }

	    .sales-order-weijia-table th {
	      position: sticky;
	      top: 0;
	      z-index: 1;
	      color: rgba(0, 0, 0, .85);
	      background: #f8fafc;
	      font-weight: 700;
	      user-select: none;
	    }

	    .sales-order-column-head {
	      display: flex;
	      align-items: center;
	      gap: 6px;
	      min-width: 0;
	      max-width: 100%;
	      width: 100%;
	    }

	    .sales-order-column-head span {
	      min-width: 0;
	      overflow: hidden;
      text-overflow: ellipsis;
    }

    .sales-column-menu-button {
      width: 18px;
      height: 18px;
      border: 0;
      border-radius: 4px;
      background: transparent;
      color: #6b7a8c;
      cursor: pointer;
      line-height: 1;
    }

	    .sales-column-menu-button:hover {
	      background: #eaf1f8;
	      color: #213244;
	    }

	    .sales-column-resize-handle {
	      position: absolute;
	      top: 0;
	      right: -3px;
	      z-index: 4;
	      width: 7px;
	      height: 100%;
	      cursor: col-resize;
	      touch-action: none;
	    }

	    .sales-column-resize-handle::after {
	      content: "";
	      position: absolute;
	      top: 8px;
	      bottom: 8px;
	      left: 3px;
	      width: 1px;
	      background: transparent;
	    }

	    .sales-column-resize-handle:hover::after,
	    .sales-column-resize-handle.is-resizing::after {
	      background: #52a000;
	    }

	    .sales-order-weijia-table.is-resizing {
	      user-select: none;
	      cursor: col-resize;
	    }

    .sales-order-summary-row td {
      background: #fbfcfd;
      color: #526171;
      font-weight: 700;
    }

    .sales-order-pagination {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: flex-end;
      gap: 8px;
      padding: 10px 0 0;
      color: #526171;
      font-size: 12px;
    }

    .sales-order-pagination button,
    .sales-order-pagination select,
    .sales-order-pagination input {
      min-height: 28px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fff;
      color: #213244;
    }

    .sales-order-pagination button {
      min-width: 28px;
      padding: 0 8px;
    }

    [data-list-toolbar-page-items] {
      display: inline-flex;
      align-items: center;
      gap: 6px;
    }

    .sales-order-pagination button.active {
      border-color: var(--green);
      color: var(--green);
      font-weight: 700;
    }

    .sales-order-pagination input {
      width: 48px;
      padding: 0 8px;
    }

    .sales-order-weijia-table th:first-child,
    .sales-order-weijia-table td:first-child {
      min-width: 48px;
      width: 48px;
      text-align: center;
      position: sticky;
      left: 0;
      z-index: 2;
      background: #fff;
    }

    .sales-order-weijia-table th:first-child {
      background: #f7f9fb;
      z-index: 3;
    }

    .sales-order-weijia-table :is(th, td):nth-child(2) { min-width: 176px; }
    .sales-order-weijia-table :is(th, td):nth-child(n+3) { min-width: 148px; }

    .sales-order-weijia-table tbody tr {
      cursor: pointer;
    }

	    .sales-order-weijia-table tbody tr:hover td {
	      background: #f8fbff;
	    }

    .weijia-record-table[data-workflow-list-table] {
      display: table;
      border-collapse: collapse;
      border-spacing: 0;
      min-width: 100%;
      width: max-content;
      table-layout: auto;
      font-size: 13px;
    }

    .weijia-record-table[data-workflow-list-table] col {
      min-width: 148px;
    }

    .weijia-record-table[data-workflow-list-table] thead {
      display: table-header-group;
    }

    .weijia-record-table[data-workflow-list-table] tbody {
      display: table-row-group;
    }

    .weijia-record-table[data-workflow-list-table] thead tr,
    .weijia-record-table[data-workflow-list-table] tbody tr {
      display: table-row;
    }

    .weijia-record-table[data-workflow-list-table] th,
    .weijia-record-table[data-workflow-list-table] td {
      display: table-cell;
      min-width: 148px;
      height: 38px;
      padding: 8px 12px;
      border-right: 1px solid #e8e8e8;
      border-bottom: 1px solid #e8e8e8;
      background: #fff;
      text-align: left;
      vertical-align: middle;
      white-space: nowrap;
    }

    .weijia-record-table[data-workflow-list-table] th {
      position: sticky;
      top: 0;
      z-index: 1;
      color: rgba(0, 0, 0, .85);
      background: #f8fafc;
      font-weight: 700;
      user-select: none;
    }

    .weijia-record-table[data-workflow-list-table] :is(th, td):first-child {
      min-width: 176px;
    }

    .weijia-record-table[data-workflow-list-table] tbody tr:hover td {
      background: #f8fbff;
    }

    tr[data-record-row-actionable="true"] {
      cursor: pointer;
    }

    tr[data-record-row-actionable="true"]:focus-visible {
      outline: 2px solid #2d6cdf;
      outline-offset: -2px;
    }

	    .table-link {
	      border: 0;
	      padding: 0;
      background: transparent;
      color: var(--blue);
      font-weight: 700;
      cursor: pointer;
      text-align: left;
    }

    .workflow-row-status {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 6px;
      margin-top: 6px;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.4;
    }

    .workflow-row-status .tag {
      min-height: 22px;
      padding: 0 7px;
      font-size: 11px;
    }

    .sales-order-empty-cell {
      color: var(--muted);
      text-align: left !important;
      position: static !important;
      background: #fff !important;
    }

    .workflow-record-empty-card {
      display: grid;
      gap: 6px;
      justify-items: start;
      padding: 10px 4px;
      line-height: 1.6;
    }

    .workflow-record-empty-card b {
      color: var(--text);
      font-size: 14px;
    }

    .workflow-record-empty-card span {
      color: var(--muted);
      font-size: 12px;
    }

    .sales-detail-actions,
    .sales-detail-tabs {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .sales-detail-summary {
      display: grid;
      grid-template-columns: repeat(5, minmax(120px, 1fr));
      gap: 8px;
      padding: 10px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #f7faf4;
    }

    .sales-detail-summary span {
      display: grid;
      gap: 2px;
      min-width: 0;
      color: var(--muted);
      font-size: 12px;
    }

    .sales-detail-summary b {
      overflow: hidden;
      color: #1f2d3d;
      font-size: 13px;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .sales-detail-shell {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 150px;
      gap: 14px;
      align-items: start;
    }

    .sales-detail-main,
    .sales-detail-side,
    .form-section {
      display: grid;
      gap: 10px;
      min-width: 0;
    }

    .sales-detail-side {
      border-left: 1px solid var(--line);
      padding-left: 12px;
    }

    .sales-detail-tabs {
      display: grid;
    }

    .sales-detail-tabs button {
      justify-content: flex-start;
      text-align: left;
    }

    .form-section {
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fbfcfd;
      padding: 12px;
    }

    .form-section h4 {
      margin: 0;
      font-size: 14px;
      line-height: 1.4;
    }

    .sales-form-caption {
      margin-top: 8px;
      color: var(--muted);
      font-size: 13px;
      line-height: 1.5;
    }

    .sales-order-form-canvas,
    .sales-order-item-canvas {
      background: #fff;
      border: 1px solid var(--line);
      border-radius: 0;
      padding: 18px 20px;
    }

    .sales-order-form-canvas {
      background: #fff;
      border-radius: 0;
    }

    .sales-order-form-canvas .sales-form-caption {
      margin: 0 0 14px;
      padding: 8px 12px;
      background: #4c89c8;
      color: #fff;
      text-align: center;
      font-size: 15px;
      font-weight: 700;
      line-height: 1.45;
    }

    .sales-order-form-canvas .sales-field-grid {
      grid-template-columns: minmax(0, 1fr);
      gap: 12px;
    }

    .sales-order-form-canvas .sales-field-grid > .sales-order-item-canvas {
      grid-column: 1 / -1;
      padding: 12px 0 0;
      border: 0;
      border-top: 1px solid var(--line);
    }

    .sales-order-form-canvas .sales-field-grid > .sales-project-detail-frame {
      margin-top: 4px;
      padding: 14px;
      border: 1px solid var(--line);
      background: #fbfdff;
    }

    .sales-project-detail-frame h4 {
      padding-bottom: 10px;
      border-bottom: 1px solid var(--line);
    }

    .sales-order-item-canvas .sales-item-grid {
      grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .sales-project-catalog-search {
      position: relative;
      grid-column: 1 / -1;
    }

    .sales-project-catalog-results {
      max-height: 260px;
      margin-top: 6px;
      overflow-y: auto;
      border: 1px solid var(--line);
      background: #fff;
      box-shadow: 0 8px 20px rgba(20, 44, 68, .12);
    }

    .sales-project-catalog-option {
      display: grid;
      width: 100%;
      min-height: 48px;
      padding: 8px 12px;
      border: 0;
      border-bottom: 1px solid var(--line);
      background: #fff;
      color: var(--text);
      text-align: left;
      cursor: pointer;
    }

    .sales-project-catalog-option:last-child {
      border-bottom: 0;
    }

    .sales-project-catalog-option:hover,
    .sales-project-catalog-option:focus-visible {
      background: #eef6fc;
      outline: 2px solid #4c89c8;
      outline-offset: -2px;
    }

    .sales-project-catalog-option span,
    .sales-project-catalog-empty {
      color: var(--muted);
      font-size: 12px;
    }

    .sales-project-catalog-empty {
      display: block;
      padding: 12px;
    }

    .weijia-full-row {
      grid-column: 1 / -1;
    }

    .weijia-status-select-source {
      position: absolute;
      width: 1px;
      height: 1px;
      margin: -1px;
      padding: 0;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      border: 0;
    }

    .weijia-status-chip-row {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      min-height: 34px;
      padding: 8px 10px;
      border: 1px solid #d8e3ec;
      background: #f7fafc;
    }

    .weijia-status-chip {
      display: inline-flex;
      align-items: center;
      min-height: 24px;
      padding: 2px 10px;
      border: 1px solid #c8d6e4;
      border-radius: 3px;
      background: #fff;
      color: #44566c;
      font-size: 12px;
      line-height: 1.4;
    }

    .weijia-status-chip.is-current {
      border-color: #4b91d8;
      background: #e8f3ff;
      color: #1f5f9f;
      font-weight: 700;
    }

    .form-section-note {
      color: var(--muted);
      font-size: 12px;
      line-height: 1.55;
      margin: -2px 0 4px;
    }

    .sales-field-grid {
      display: grid;
      grid-template-columns: repeat(12, minmax(0, 1fr));
      gap: 10px;
    }

    .sales-item-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .sales-field-grid > .field { grid-column: span 6; }
    .sales-field-grid > .field[data-field-width="1/4"] { grid-column: span 3; }
    .sales-field-grid > .field[data-field-width="1/3"] { grid-column: span 4; }
    .sales-field-grid > .field[data-field-width="1/2"] { grid-column: span 6; }
    .sales-field-grid > .field[data-field-width="2/3"] { grid-column: span 8; }
    .sales-field-grid > .field[data-field-width="3/4"] { grid-column: span 9; }
    .sales-field-grid > .field[data-field-width="整行"],
    .sales-field-grid > .form-section,
    .sales-field-grid > .sales-order-item-canvas { grid-column: 1 / -1; }

    [data-workflow-record-detail-drawer] .workflow-detail-table-field {
      grid-column: 1 / -1;
      min-width: 0;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-table-field .table-wrap {
      width: 100%;
      overflow-x: auto;
      border: 1px solid var(--line);
      border-radius: 6px;
      background: #fff;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-table-field table {
      width: max-content;
      min-width: 100%;
      border-collapse: collapse;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-table-field th,
    [data-workflow-record-detail-drawer] .workflow-detail-table-field td {
      min-width: 108px;
      padding: 9px 10px;
      border: 1px solid var(--line);
      text-align: left;
      white-space: nowrap;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-table-field th {
      background: #f5f8fa;
      color: #526171;
      font-weight: 700;
    }

    [data-workflow-record-detail-drawer] [data-workflow-record-oss-attachments] {
      grid-column: 1 / -1;
      min-width: 0;
    }

    [data-workflow-record-detail-drawer] .dynamic-attachment-list {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
      gap: 10px;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-thumbnail {
      display: block;
      width: 96px;
      margin: 0;
      padding: 0;
      border: 0;
      border-radius: 4px;
      background: transparent;
      cursor: pointer;
      overflow: hidden;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-thumbnail img {
      width: 96px;
      height: 72px;
      object-fit: cover;
      grid-row: 1 / span 2;
      border-radius: 4px;
      background: #eef3f7;
    }

    [data-workflow-record-detail-drawer] .workflow-detail-thumbnail figcaption {
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      color: var(--muted);
      font-size: 12px;
    }

    .workflow-attachment-preview {
      position: fixed;
      inset: 0;
      z-index: 2000;
      display: grid;
      place-items: center;
      padding: 64px 24px 24px;
      background: rgba(8, 15, 26, 0.88);
      cursor: zoom-out;
    }

    .workflow-attachment-preview img {
      display: block;
      max-width: min(1120px, 94vw);
      max-height: calc(100vh - 96px);
      object-fit: contain;
      border-radius: 8px;
      box-shadow: 0 18px 56px rgba(0, 0, 0, 0.45);
      cursor: default;
    }

    .workflow-attachment-preview-close {
      position: absolute;
      top: 18px;
      right: 22px;
      width: 40px;
      height: 40px;
      border: 1px solid rgba(255, 255, 255, 0.48);
      border-radius: 999px;
      background: rgba(17, 24, 39, 0.76);
      color: #fff;
      font-size: 28px;
      line-height: 1;
      cursor: pointer;
    }

    .sales-detail-relation-list {
      display: grid;
      gap: 10px;
    }

    .sales-detail-relation-card {
      display: grid;
      gap: 10px;
      border: 1px solid #d8e3ec;
      border-radius: 4px;
      background: #fff;
      padding: 10px;
    }

    .sales-detail-relation-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      color: #1f2d3d;
      font-size: 13px;
      line-height: 1.4;
    }

    .sales-detail-relation-head span {
      color: var(--muted);
      font-size: 12px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .sales-detail-relation-card .folder-card {
      min-height: auto;
      padding: 8px 10px;
      background: #fbfcfd;
    }

    .system-managed-field input,
    .system-managed-field select {
      background: #f4f7fa;
      color: #6b7685;
    }

    .sales-line-table-scroll {
      overflow-x: auto;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fff;
    }

    .sales-project-line-table {
      width: 100%;
      min-width: 1320px;
      border-collapse: collapse;
      font-size: 12px;
    }

    .sales-project-line-table th,
    .sales-project-line-table td {
      border-bottom: 1px solid var(--line);
      padding: 8px;
      text-align: left;
      white-space: nowrap;
      vertical-align: middle;
    }

    .sales-project-line-table th {
      background: #f5f8fb;
      color: #334155;
      font-weight: 700;
    }

    .sales-line-row-actions {
      display: inline-flex;
      gap: 6px;
      align-items: center;
    }

    .sales-line-editor-title {
      margin: 12px 0 8px;
      color: #25364a;
      font-size: 13px;
      font-weight: 700;
    }

    @media (max-width: 1100px) {
      .shell { grid-template-columns: 1fr; }
      .sidebar {
        position: static;
        border-right: 0;
        border-bottom: 1px solid var(--line);
        padding: 14px;
      }
      .nav {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
      }
      .sidebar-foot { display: none; }
      .workspace, .wide, .workbench-grid { grid-template-columns: 1fr; }
      .workbench-tabs { justify-content: flex-start; }
    }

    @media (max-width: 760px) {
      .weijia-relation-filter-backdrop {
        padding: 0;
        place-items: stretch;
      }
      .weijia-relation-filter-dialog {
        width: 100%;
        min-height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
      }
      .weijia-relation-filter-row {
        grid-template-columns: 64px minmax(0, 1fr) 36px;
      }
      .weijia-relation-filter-row > select:not([data-weijia-relation-filter-conjunction]),
      .weijia-relation-filter-row > input {
        grid-column: 2;
      }
      .weijia-relation-filter-row [data-weijia-relation-filter-remove] {
        grid-column: 3;
        grid-row: 1 / span 4;
      }
      .weijia-relation-correspondence-backdrop {
        padding: 0;
        place-items: stretch;
      }
      .weijia-relation-correspondence-dialog {
        width: 100%;
        max-height: 100dvh;
        min-height: 100dvh;
        border: 0;
        border-radius: 0;
      }
      .weijia-relation-correspondence-header,
      .weijia-relation-correspondence-actions {
        padding-left: 14px;
        padding-right: 14px;
      }
      .weijia-relation-correspondence-hint {
        padding-left: 14px;
        padding-right: 14px;
      }
      .weijia-relation-correspondence-body {
        padding: 14px;
      }
      .weijia-relation-correspondence-rows {
        max-height: none;
      }
      .weijia-relation-correspondence-row {
        grid-template-columns: minmax(0, 1fr) 32px;
        gap: 8px 10px;
        padding: 10px;
      }
      .weijia-relation-correspondence-row select {
        grid-column: 1;
      }
      .weijia-relation-correspondence-connector {
        grid-column: 1;
        width: auto;
        text-align: left;
      }
      .weijia-relation-correspondence-remove {
        grid-column: 2;
        grid-row: 1 / span 3;
        align-self: center;
      }
      .topbar {
        height: auto;
        align-items: stretch;
        flex-direction: column;
        padding: 14px;
        max-width: 100%;
        overflow: hidden;
      }
      .topbar > * {
        min-width: 0;
        max-width: 100%;
      }
      .scope {
        justify-content: space-between;
        width: 100%;
      }
      .scope h1 { font-size: 18px; }
      .scope select { min-width: 0; }
      .actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        width: 100%;
        min-width: 0;
        margin-left: 0;
      }
      .workbench-tabs {
        order: 3;
        grid-column: 1 / -1;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
        max-width: 100%;
        min-width: 0;
        overflow-x: visible;
      }
      .workbench-tabs button {
        min-height: 38px;
        padding: 0 10px;
        white-space: normal;
        overflow-wrap: anywhere;
      }
      .product-tabs {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        width: 100%;
        max-width: 100%;
        min-width: 0;
        overflow-x: visible;
      }
      .product-tabs button {
        min-height: 38px;
        padding: 0 8px;
        white-space: normal;
        overflow-wrap: anywhere;
      }
      .top-actions {
        justify-content: flex-start;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        white-space: normal;
        overflow-wrap: anywhere;
      }
      .login-bar {
        grid-column: 1 / -1;
        border-right: 0;
        padding-right: 0;
        display: grid;
        grid-template-columns: 1fr 1fr;
        min-width: 0;
      }
      .login-bar input,
      .login-bar input[type="password"] { width: 100%; }
      .status-pill {
        grid-column: 1 / -1;
        justify-content: center;
        max-width: 100%;
        min-width: 0;
        white-space: normal;
        overflow-wrap: anywhere;
        text-align: center;
        padding-top: 5px;
        padding-bottom: 5px;
      }
      .content { padding: 14px; }
      .summary { grid-template-columns: 1fr 1fr; }
      .task {
        grid-template-columns: 1fr;
        gap: 8px;
      }
      .workflow-records { grid-template-columns: 1fr; }
      .workflow-record-section {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
      }
      .workflow-record-section .weijia-record-table {
        min-width: 760px;
      }
      .weijia-record-head { display: none; }
      .weijia-record-row {
        grid-template-columns: 1fr;
        align-items: start;
        gap: 4px;
        padding-top: 10px;
        padding-bottom: 10px;
      }
      .relation-link { grid-template-columns: 1fr; }
      .sales-detail-shell,
      .sales-field-grid,
      .sales-item-grid,
      .sales-detail-summary,
      .sales-order-review-strip {
        grid-template-columns: 1fr;
      }
      .sales-field-grid > .field,
      .sales-field-grid > .field[data-field-width] { grid-column: 1 / -1; }
      .sales-detail-side {
        border-left: 0;
        border-top: 1px solid var(--line);
        padding-left: 0;
        padding-top: 12px;
      }
      .quick-grid { grid-template-columns: 1fr; }
      .folder-intro { grid-template-columns: 1fr; }
      .folder-grid { grid-template-columns: 1fr; }
      .assembly-grid { grid-template-columns: 1fr; }
      .assembly-form-head { grid-template-columns: 1fr; }
      .nav { grid-template-columns: 1fr 1fr; }
      .home-module-grid { grid-template-columns: 1fr; }
      .app-workspace { grid-template-columns: 1fr; }
      .app-sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
      .drawer-panel.workflow-form-drawer-panel {
        width: 100%;
        padding: 16px;
      }
    }

    /* Store desktop runtime compatibility: source prototype/store-portal/ui-desktop.html */
    :root {
          /* ── 背景层次 ── */
          --bg:        #f0f2f5;
          --surface:   #ffffff;
          --surface-2: #f8f9fb;
          --surface-3: #f0f2f5;

          /* ── 侧边栏（深海军蓝） ── */
          --nav-bg:    #1a2840;
          --nav-bg2:   #213251;
          --nav-text:  rgba(255,255,255,.55);
          --nav-hover: rgba(255,255,255,.08);
          --nav-active-bg: rgba(255,255,255,.10);
          --nav-active-text: #ffffff;
          --nav-accent: #4ade98;   /* 亮绿，作为 active 左边条 */

          /* ── 主色：森林绿 ── */
          --green:     #16a34a;
          --green-h:   #15803d;
          --green-bg:  #f0fdf4;
          --green-line:#bbf7d0;
          --green-text:#166534;

          /* ── 状态色 ── */
          --blue:      #2563eb;
          --blue-bg:   #eff6ff;
          --blue-line: #bfdbfe;
          --amber:     #d97706;
          --amber-bg:  #fffbeb;
          --amber-line:#fde68a;
          --red:       #dc2626;
          --red-bg:    #fef2f2;
          --red-line:  #fecaca;
          --purple:    #7c3aed;
          --purple-bg: #f5f3ff;
          --purple-line:#ddd6fe;

          /* ── 文字 ── */
          --ink:       #111827;
          --ink-2:     #374151;
          --ink-3:     #6b7280;
          --ink-4:     #9ca3af;

          /* ── 线条与阴影 ── */
          --line:      #e5e7eb;
          --line-2:    #f3f4f6;
          --shadow-sm: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
          --shadow:    0 4px 12px rgba(0,0,0,.06), 0 2px 4px rgba(0,0,0,.04);

          --radius:    8px;
          --radius-sm: 5px;
          --sidebar-w: 224px;
        }

        *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
        body {
          font-family: -apple-system, BlinkMacSystemFont, "PingFang SC",
                       "Helvetica Neue", "Microsoft YaHei", sans-serif;
          background: var(--bg);
          color: var(--ink);
          font-size: 14px;
          line-height: 1.5;
          -webkit-font-smoothing: antialiased;
        }
        button, input, select, textarea { font: inherit; }
        [hidden] { display: none !important; }

        /* ─────────────── SHELL ─────────────── */
        .app {
          display: grid;
          grid-template-columns: var(--sidebar-w) 1fr;
          grid-template-rows: 100vh;
          min-height: 100vh;
        }

        /* ─────────────── SIDEBAR ─────────────── */
        .sidebar {
          background: var(--nav-bg);
          display: flex; flex-direction: column;
          position: sticky; top: 0; height: 100vh;
          overflow-y: auto;
        }

        .sb-brand {
          padding: 20px 18px 16px;
          display: flex; align-items: center; gap: 11px;
          border-bottom: 1px solid rgba(255,255,255,.06);
        }
        .sb-logo {
          width: 36px; height: 36px; border-radius: 9px;
          background: linear-gradient(135deg, #16a34a, #15803d);
          display: grid; place-items: center;
          font-size: 15px; font-weight: 900; color: #fff;
          flex-shrink: 0;
        }
        .sb-brand-name  { font-size: 15px; font-weight: 700; color: #fff; }
        .sb-brand-sub   { font-size: 11px; color: var(--nav-text); margin-top: 1px; }

        .sb-store {
          margin: 12px 12px 4px;
          padding: 10px 12px;
          background: var(--nav-bg2);
          border-radius: var(--radius-sm);
        }
        .sb-store-label { font-size: 10px; color: rgba(255,255,255,.3);
                          text-transform: uppercase; letter-spacing: .06em; }
        .sb-store-name  { font-size: 13.5px; font-weight: 700; color: #fff; margin-top: 2px; }

        .sb-section { padding: 12px 12px 4px; }
        .sb-section-title {
          font-size: 10px; font-weight: 700; color: rgba(255,255,255,.3);
          text-transform: uppercase; letter-spacing: .06em;
          padding: 0 6px; margin-bottom: 3px;
        }
        .sb-item {
          display: flex; align-items: center; gap: 9px;
          width: 100%; padding: 8px 10px;
          border: none; background: transparent;
          border-radius: var(--radius-sm);
          color: var(--nav-text); font-size: 13.5px; font-weight: 500;
          cursor: pointer; text-align: left;
          position: relative;
          transition: background .12s, color .12s;
        }
        .sb-item:hover { background: var(--nav-hover); color: rgba(255,255,255,.85); }
        .sb-item.active {
          background: var(--nav-active-bg);
          color: var(--nav-active-text); font-weight: 600;
        }
        .sb-item.active::before {
          content: '';
          position: absolute; left: 0; top: 6px; bottom: 6px;
          width: 3px; border-radius: 2px;
          background: var(--nav-accent);
        }
        .sb-icon { width: 16px; height: 16px; flex-shrink: 0; opacity: .7; }
        .sb-item.active .sb-icon { opacity: 1; }
        .sb-badge {
          margin-left: auto;
          background: rgba(255,255,255,.12);
          color: rgba(255,255,255,.7);
          font-size: 10px; font-weight: 700;
          padding: 1px 7px; border-radius: 20px;
        }
        .sb-item.active .sb-badge {
          background: rgba(74,222,152,.18);
          color: var(--nav-accent);
        }
        .sb-divider { height: 1px; background: rgba(255,255,255,.06); margin: 6px 14px; }

        .sb-foot {
          margin-top: auto;
          padding: 14px 16px;
          border-top: 1px solid rgba(255,255,255,.06);
          display: flex; align-items: center; gap: 10px;
        }
        .sb-avatar {
          width: 32px; height: 32px; border-radius: 50%;
          background: linear-gradient(135deg,#16a34a,#15803d);
          display: grid; place-items: center;
          font-size: 12px; font-weight: 800; color: #fff; flex-shrink: 0;
        }
        .sb-user-name  { font-size: 13px; font-weight: 600; color: #fff; }
        .sb-user-role  { font-size: 11px; color: var(--nav-text); }

        /* ─────────────── MAIN ─────────────── */
        .main { display: flex; flex-direction: column; min-width: 0; overflow-y: auto; }

        .topbar {
          background: var(--surface);
          border-bottom: 1px solid var(--line);
          height: 52px;
          padding: 0 24px;
          display: flex; align-items: center; gap: 16px;
          position: sticky; top: 0; z-index: 10;
          flex-shrink: 0;
        }
        .topbar-title { font-size: 17px; font-weight: 800; color: var(--ink); }
        .topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
        .topbar-date { font-size: 12px; color: var(--ink-3); }

        .icon-btn {
          width: 32px; height: 32px; border-radius: var(--radius-sm);
          border: 1px solid var(--line); background: var(--surface);
          display: grid; place-items: center; cursor: pointer; color: var(--ink-3);
        }
        .icon-btn:hover { background: var(--surface-2); }

        .content { flex: 1; padding: 22px 24px 40px; }

        /* ─────────────── PAGE HEAD ─────────────── */
        .page-head {
          display: flex; align-items: flex-start;
          justify-content: space-between; gap: 16px;
          margin-bottom: 18px;
        }
        .page-head h1 { font-size: 22px; font-weight: 800; }
        .page-head p  { font-size: 13px; color: var(--ink-3); margin-top: 3px; }

        /* ─────────────── BTN ─────────────── */
        .btn {
          display: inline-flex; align-items: center; gap: 6px;
          padding: 0 16px; height: 36px; border-radius: var(--radius-sm);
          font-size: 13.5px; font-weight: 600; cursor: pointer;
          border: 1px solid transparent;
          transition: all .12s;
        }
        .btn-primary  { background: var(--green);  color: #fff; border-color: var(--green-h); }
        .btn-primary:hover  { background: var(--green-h); }
        .btn-ghost    { background: var(--surface); color: var(--ink-2); border-color: var(--line); }
        .btn-ghost:hover    { background: var(--surface-2); }
        .btn-sm { height: 30px; padding: 0 12px; font-size: 12.5px; }

        /* ─────────────── STATS ─────────────── */
        .stats-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; margin-bottom: 20px; }
        .stat-card {
          background: var(--surface);
          border: 1px solid var(--line);
          border-radius: var(--radius);
          padding: 16px 18px;
          box-shadow: var(--shadow-sm);
        }
        .stat-label { font-size: 12px; color: var(--ink-3); }
        .stat-value { font-size: 28px; font-weight: 900; line-height: 1.1; margin-top: 4px; }
        .stat-sub   { font-size: 11px; color: var(--ink-3); margin-top: 4px; }
        .stat-up    { color: var(--green); font-weight: 600; }
        .stat-card.accent-green .stat-value { color: var(--green); }
        .stat-card.accent-amber .stat-value { color: var(--amber); }
        .stat-card.accent-blue  .stat-value { color: var(--blue);  }

        /* ─────────────── FILTER ─────────────── */
        .filter-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
        .search-box { position: relative; }
        .search-box svg { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--ink-4); }
        .search-input {
          width: 240px; height: 34px; padding: 0 10px 0 32px;
          border: 1px solid var(--line); border-radius: var(--radius-sm);
          background: var(--surface); font-size: 13px; color: var(--ink);
        }
        .search-input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(22,163,74,.1); }
        .filter-chip {
          height: 34px; padding: 0 14px;
          border: 1px solid var(--line); border-radius: 20px;
          background: var(--surface); font-size: 13px; color: var(--ink-3); cursor: pointer;
        }
        .filter-chip.on { background: var(--green-bg); border-color: var(--green-line); color: var(--green-text); font-weight: 600; }
        .filter-select {
          height: 34px; padding: 0 10px; border: 1px solid var(--line);
          border-radius: var(--radius-sm); background: var(--surface);
          font-size: 13px; color: var(--ink-2); cursor: pointer;
        }
        .ml-auto { margin-left: auto; }

        /* ─────────────── TABLE ─────────────── */
        .table-card {
          background: var(--surface); border: 1px solid var(--line);
          border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden;
        }
        .table-card-head {
          padding: 11px 16px; background: var(--surface-2);
          border-bottom: 1px solid var(--line);
          display: flex; align-items: center; gap: 10px;
        }
        .table-card-head strong { font-size: 13px; color: var(--ink-2); }
        .table-card-count {
          font-size: 11px; color: var(--ink-3);
          background: var(--line-2); padding: 2px 8px; border-radius: 20px;
        }
        .data-table { width: 100%; border-collapse: collapse; }
        .data-table th {
          padding: 9px 14px; text-align: left;
          font-size: 11px; font-weight: 700; color: var(--ink-3);
          text-transform: uppercase; letter-spacing: .04em;
          border-bottom: 1px solid var(--line);
          background: var(--surface-2); white-space: nowrap;
        }
        .data-table td {
          padding: 11px 14px; border-bottom: 1px solid var(--line-2);
          font-size: 13.5px; vertical-align: middle;
        }
        .data-table tr:last-child td { border-bottom: none; }
        .data-table tbody tr:hover { background: #fafcff; cursor: pointer; }

        .cell-id { font-family: ui-monospace, monospace; font-size: 12px; color: var(--blue); font-weight: 600; }
        .cell-name strong { display: block; font-size: 14px; }
        .cell-name span   { font-size: 12px; color: var(--ink-3); }
        .cell-amount { font-size: 15px; font-weight: 800; }
        .cell-date { font-size: 12px; color: var(--ink-3); }

        /* ── Flow progress inline ── */
        .flow-inline {
          display: flex; align-items: center; gap: 0; min-width: 140px;
        }
        .fi-step {
          display: flex; flex-direction: column; align-items: center; gap: 2px; flex: 1;
        }
        .fi-dot {
          width: 18px; height: 18px; border-radius: 50%;
          font-size: 9px; font-weight: 700;
          display: grid; place-items: center;
          border: 1.5px solid var(--line);
          background: var(--surface-3); color: var(--ink-4);
        }
        .fi-dot.done   { background: var(--green-bg); border-color: var(--green-line); color: var(--green-text); }
        .fi-dot.active { background: #fffbeb; border-color: var(--amber-line); color: var(--amber); }
        .fi-label { font-size: 9px; color: var(--ink-4); white-space: nowrap; }
        .fi-label.done   { color: var(--green-text); }
        .fi-label.active { color: var(--amber); font-weight: 600; }
        .fi-line { flex: 1; height: 1.5px; background: var(--line); margin-bottom: 12px; }
        .fi-line.done { background: var(--green-line); }

        /* ── Status badge ── */
        .badge {
          display: inline-flex; align-items: center; gap: 5px;
          padding: 3px 9px; border-radius: 20px;
          font-size: 11.5px; font-weight: 600; white-space: nowrap;
        }
        .badge::before { content: ''; width: 5px; height: 5px; border-radius: 50%; }
        .badge-new  { background: var(--blue-bg);   color: var(--blue);   }
        .badge-new::before   { background: var(--blue); }
        .badge-recv { background: var(--amber-bg);  color: var(--amber);  }
        .badge-recv::before  { background: var(--amber); }
        .badge-work { background: var(--purple-bg); color: var(--purple); }
        .badge-work::before  { background: var(--purple); }
        .badge-pay  { background: var(--green-bg);  color: var(--green-text);  }
        .badge-pay::before   { background: var(--green); }
        .badge-debt { background: #fdecea; color: #9b3128; }
        .badge-debt::before  { background: #d9473f; }
        .badge-done { background: var(--surface-3); color: var(--ink-3); }
        .badge-done::before  { background: var(--ink-4); }
        .badge-cancelled { background: var(--surface-3); color: var(--ink-4); }
        .badge-cancelled::before { background: var(--ink-4); }

        /* ── Row actions ── */
        .row-actions { display: flex; gap: 6px; }

        /* ─────────────── PAGINATION ─────────────── */
        .pagination {
          padding: 11px 16px; border-top: 1px solid var(--line-2);
          display: flex; align-items: center; justify-content: space-between;
          font-size: 12px; color: var(--ink-3);
        }
        .pg-btns { display: flex; gap: 4px; }
        .pg-btn {
          width: 28px; height: 28px; border-radius: var(--radius-sm);
          border: 1px solid var(--line); background: var(--surface);
          font-size: 12px; color: var(--ink-3); cursor: pointer; display: grid; place-items: center;
        }
        .pg-btn.on { background: var(--green); border-color: var(--green-h); color: #fff; font-weight: 700; }

        /* ─────────────── DRAWER ─────────────── */
        .drawer-mask {
          position: fixed; inset: 0; background: rgba(0,0,0,.35);
          z-index: 40; opacity: 0; pointer-events: none; transition: opacity .2s;
        }
        .drawer-mask.open { opacity: 1; pointer-events: auto; }
        .drawer {
          position: fixed; top: 0; right: 0; bottom: 0;
          width: 520px; max-width: 95vw;
          background: var(--surface);
          box-shadow: -6px 0 32px rgba(0,0,0,.10);
          z-index: 41;
          transform: translateX(100%);
          transition: transform .22s cubic-bezier(.22,.61,.36,1);
          display: flex; flex-direction: column;
        }
        .drawer.open { transform: translateX(0); }
        .drawer-head {
          padding: 18px 22px;
          border-bottom: 1px solid var(--line);
          display: flex; align-items: flex-start; gap: 14px;
        }
        .drawer-title { font-size: 18px; font-weight: 800; }
        .drawer-sub   { font-size: 12px; color: var(--ink-3); margin-top: 3px; }
        .drawer-close {
          margin-left: auto; width: 32px; height: 32px;
          border: 1px solid var(--line); border-radius: var(--radius-sm);
          background: var(--surface); cursor: pointer;
          display: grid; place-items: center; font-size: 18px; color: var(--ink-3);
        }
        .drawer-close:hover { background: var(--surface-2); }
        .drawer-body { flex: 1; overflow-y: auto; padding: 20px 22px; }
        .drawer-foot {
          padding: 14px 22px; border-top: 1px solid var(--line);
          display: flex; gap: 10px; justify-content: flex-end;
        }

        /* ─────────────── FORM ─────────────── */
        .form-sec       { margin-bottom: 22px; }
        .form-sec-title {
          font-size: 11px; font-weight: 700; color: var(--ink-3);
          text-transform: uppercase; letter-spacing: .05em;
          padding-bottom: 8px; border-bottom: 1px solid var(--line-2);
          margin-bottom: 12px;
        }
        .form-grid     { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
        .form-grid.c1  { grid-template-columns: 1fr; }
        .form-field    { display: flex; flex-direction: column; gap: 5px; }
        .form-label    { font-size: 12px; font-weight: 600; color: var(--ink-2); }
        .form-label .req { color: var(--red); margin-left: 2px; }
        .form-input, .form-select {
          height: 37px; padding: 0 11px;
          border: 1px solid var(--line); border-radius: var(--radius-sm);
          background: var(--surface); color: var(--ink); font-size: 14px;
        }
        .form-input:focus, .form-select:focus {
          outline: none; border-color: var(--green);
          box-shadow: 0 0 0 3px rgba(22,163,74,.1);
        }
        .form-hint { font-size: 11px; color: var(--ink-4); }
        .form-readonly { background: var(--surface-2); color: var(--ink-3); }

        /* ─────────────── DETAIL KV ─────────────── */
        .kv-block { background: var(--surface-2); border-radius: var(--radius-sm); overflow: hidden; margin-bottom: 16px; }
        .kv-row { display: flex; padding: 10px 14px; border-bottom: 1px solid var(--line-2); }
        .kv-row:last-child { border-bottom: none; }
        .kv-key { width: 88px; flex-shrink: 0; color: var(--ink-3); font-size: 13px; }
        .kv-val { flex: 1; color: var(--ink); font-size: 13px; font-weight: 500; }

        /* ─────────────── LINKED ORDERS ─────────────── */
        .linked-block { border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
        .linked-row { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--line-2); }
        .linked-row:last-child { border-bottom: none; }
        .linked-type { font-size: 11px; color: var(--ink-3); width: 56px; }
        .linked-id   { font-size: 12px; font-family: monospace; color: var(--blue); }
        .linked-info { flex: 1; font-size: 13px; color: var(--ink-3); }

        @media (max-width: 900px) {
          .app { grid-template-columns: 1fr; }
          .sidebar { display: none; }
          .stats-row { grid-template-columns: 1fr 1fr; }
        }


    :root {
      --card: var(--surface);
      --r2: var(--radius);
    }
    .drawer-panel.sales-detail-drawer-panel { max-width: 960px; }
    .drawer-panel.sales-form-drawer-panel { max-width: 960px; }
    .drawer-panel.workflow-form-drawer-panel { max-width: 900px; }
    .sales-order-form-canvas {
      background: var(--card);
      border-radius: var(--r2);
      border: 1px solid var(--line);
      color: var(--ink);
      padding: 14px;
    }
    .sales-order-form-canvas .sales-field-grid {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      gap: 12px;
    }

    .runtime-hidden { display: none !important; }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] {
      background: var(--bg);
      color: var(--ink);
      overflow-x: hidden;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .app {
      display: grid;
      grid-template-columns: var(--sidebar-w) 1fr;
      grid-template-rows: minmax(100vh, auto);
      min-height: 100vh;
      background: var(--bg);
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .app {
      grid-template-columns: 1fr;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"].is-dashboard .sidebar {
      display: none;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .main {
      display: flex;
      flex-direction: column;
      min-width: 0;
      overflow-y: auto;
      max-height: 100vh;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .content {
      flex: 1;
      width: 100%;
      margin: 0;
      padding: 22px 24px 40px;
      display: block;
      min-width: 0;
      background: var(--bg);
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .page,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .page-content,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .app-workspace,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .app-content {
      background: transparent;
      min-width: 0;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .content-head {
      display: none;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .module-tree-panels,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .module-tree-panel {
      display: flex;
      flex-direction: column;
      min-height: 100%;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .sb-store-row {
      display: grid;
      gap: 6px;
      margin-top: 8px;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .store-select-inline {
      width: 100%;
      min-height: 32px;
      border: 1px solid rgba(255,255,255,.12);
      border-radius: var(--radius-sm);
      background: rgba(0,0,0,.12);
      color: #fff;
      padding: 0 9px;
      font-size: 12px;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .top-login-status {
      min-height: 24px;
      align-items: center;
      justify-content: center;
      border: 1px solid rgba(74,222,152,.24);
      background: rgba(74,222,152,.12);
      color: var(--nav-accent);
      width: max-content;
      max-width: 100%;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .topbar-meta {
      display: flex;
      align-items: center;
      gap: 8px;
      color: var(--ink-3);
      font-size: 12px;
      white-space: nowrap;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .desktop-workflow-shell {
      display: grid;
      gap: 14px;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .table-scroll {
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .data-table {
      min-width: 980px;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .workflow-record-section {
      margin-top: 14px;
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
      background: var(--surface);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: var(--shadow-sm);
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .workflow-record-section .weijia-record-table {
      min-width: 980px;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .data-panel,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .panel,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .folder-panel,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .module-tile,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .settings-card {
      background: var(--surface);
      border-color: var(--line);
      border-radius: var(--radius);
      color: var(--ink);
      box-shadow: var(--shadow-sm);
    }
    .btn,
    .sb-item,
    .icon-btn,
    .filter-chip,
    .pg-btn,
    .drawer-close {
      min-height: 32px;
      min-width: 32px;
      touch-action: manipulation;
    }
    .sales-column-menu-button,
    .sales-order-pagination button,
    .table-link {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 32px;
      min-width: 32px;
      touch-action: manipulation;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer {
      position: fixed;
      inset: 0;
      width: auto;
      max-width: none;
      background: rgba(0,0,0,.35);
      z-index: 40;
      opacity: 0;
      pointer-events: none;
      transform: none;
      transition: opacity .2s;
      display: block;
      backdrop-filter: none;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer.open {
      opacity: 1;
      pointer-events: auto;
      transform: none;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel {
      position: fixed;
      top: 0;
      right: 0;
      bottom: 0;
      width: 520px;
      max-width: 95vw;
      margin: 0;
      background: var(--surface);
      color: var(--ink);
      box-shadow: -6px 0 32px rgba(0,0,0,.10);
      border: 0;
      border-left: 1px solid var(--line);
      border-radius: 0;
      transform: translateX(100%);
      transition: transform .22s cubic-bezier(.22,.61,.36,1);
      display: flex;
      flex-direction: column;
      overflow: hidden;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer.open .drawer-panel {
      transform: translateX(0) !important;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel.sales-detail-drawer-panel,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel.sales-form-drawer-panel,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel.workflow-form-drawer-panel,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel.store-config-editor-drawer-panel {
      width: min(960px, 95vw);
      max-width: 95vw;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel.store-config-editor-drawer-panel.store-config-editor-fullscreen {
      inset: 0;
      width: 100vw;
      max-width: none;
      height: 100vh;
      transform: none !important;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer[data-store-config-editor-drawer="true"] {
      position: fixed;
      inset: 0;
      width: 100vw;
      max-width: 100vw;
      height: 100vh;
      overflow: hidden;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer[data-store-config-editor-drawer="true"] .drawer-panel.store-config-editor-fullscreen {
      position: fixed;
      top: 0;
      right: 0;
      bottom: 0;
      left: 0;
      width: 100%;
      max-width: 100vw;
      height: 100%;
      max-height: 100vh;
      margin: 0;
      transform: none !important;
      overflow: hidden;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer[data-store-config-editor-drawer="true"] #drawerBody {
      width: 100%;
      height: 100%;
      min-height: 0;
      padding: 0 !important;
      margin: 0;
      overflow: hidden;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-handle {
      display: none;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel header,
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-head {
      padding: 18px 22px;
      border-bottom: 1px solid var(--line);
      display: flex;
      align-items: center;
      gap: 14px;
      flex: 0 0 auto;
      margin-bottom: 0;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel header h3 {
      margin: 0;
      font-size: 18px;
      font-weight: 800;
      color: var(--ink);
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel header .drawer-close {
      margin-left: auto;
      width: 36px;
      height: 36px;
      min-width: 36px;
      min-height: 36px;
      padding: 0;
      border: 1px solid var(--line);
      border-radius: var(--radius-sm);
      background: var(--surface);
      color: var(--ink-3);
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 22px;
      line-height: 1;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] #drawerBody {
      flex: 1;
      min-height: 0;
      overflow-y: auto;
      padding: 20px 22px;
      -webkit-overflow-scrolling: touch;
    }
    body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-body {
      flex: 1;
      min-height: 0;
      overflow-y: auto;
      padding: 20px 22px;
      -webkit-overflow-scrolling: touch;
    }

    @media (max-width: 900px) {
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .app { grid-template-columns: 1fr; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .sidebar { display: none; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .content { padding: 16px 12px 28px; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .stats-row { grid-template-columns: 1fr 1fr; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .filter-bar { max-width: 100%; overflow-x: auto; flex-wrap: nowrap; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .status-pill { max-width: 100%; min-width: 0; white-space: normal; overflow-wrap: anywhere; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .weijia-record-row { grid-template-columns: 1fr; align-items: start; gap: 4px; }
      body[data-store-portal-ui-redesign="desktop-v1-20260705"] .drawer-panel.workflow-form-drawer-panel { width: 100%; max-width: 100%; }
    }

    .project-brand-toolbar {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 8px;
      padding: 14px 16px;
      border-bottom: 1px solid var(--line);
      background: var(--surface);
    }

    .project-brand-toolbar .inline-search {
      width: min(360px, 100%);
      min-width: 220px;
    }

    .project-brand-status {
      min-height: 32px;
      display: flex;
      align-items: center;
      color: var(--muted);
      font-size: 13px;
      margin-left: auto;
    }

    .project-brand-status.error { color: var(--red); }

    .project-brand-table {
      display: table;
      width: 100%;
      min-width: 980px;
      border-collapse: collapse;
      table-layout: auto;
    }

    .project-brand-table thead { display: table-header-group; }
    .project-brand-table tbody { display: table-row-group; }
    .project-brand-table tr { display: table-row; }

    .project-brand-table td,
    .project-brand-table th {
      display: table-cell;
      min-height: 44px;
      padding: 11px 14px;
      border-bottom: 1px solid var(--line);
      text-align: left;
      vertical-align: middle;
      white-space: nowrap;
    }

    .project-brand-table th {
      color: #4b5969;
      background: #f7f9fb;
      font-size: 12px;
      font-weight: 700;
    }

    .project-brand-table tbody tr:hover { background: #fafcf8; }

    [data-warehouse-form-view="projectBrandMaterials"] .table-wrap {
      width: 100%;
      overflow-x: auto;
      border-top: 1px solid var(--line);
    }

    .project-brand-table .material-name-cell {
      white-space: normal;
      min-width: 180px;
    }

    .project-brand-dialog {
      width: min(720px, calc(100vw - 32px));
      max-height: min(760px, calc(100vh - 32px));
      margin: auto;
      padding: 0;
      border: 1px solid var(--line);
      border-radius: 6px;
      box-shadow: 0 18px 48px rgba(21, 33, 48, .18);
      overflow: hidden;
    }

    .project-brand-dialog.wide {
      display: block;
      width: min(1120px, calc(100vw - 32px));
    }

    .project-brand-dialog::backdrop { background: rgba(16, 24, 40, .42); }

    .project-brand-dialog-head,
    .project-brand-dialog-foot {
      min-height: 56px;
      padding: 10px 16px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      border-bottom: 1px solid var(--line);
      background: var(--surface);
    }

    .project-brand-dialog-foot {
      justify-content: flex-end;
      border-top: 1px solid var(--line);
      border-bottom: 0;
    }

    .project-brand-dialog-body {
      max-height: calc(100vh - 180px);
      overflow: auto;
      padding: 16px;
    }

    .project-brand-form-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 14px;
    }

    .project-brand-field {
      display: grid;
      gap: 6px;
      min-width: 0;
      color: #394656;
      font-size: 13px;
    }

    .project-brand-field.full { grid-column: 1 / -1; }

    .project-brand-field :is(input, select) {
      width: 100%;
      min-height: 40px;
      border: 1px solid var(--line);
      border-radius: 4px;
      padding: 7px 10px;
      background: #fff;
    }

    .project-brand-candidates {
      display: grid;
      gap: 8px;
      margin-top: 14px;
    }

    .project-brand-candidate {
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 8px;
      align-items: center;
      padding: 10px 12px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #f8fafc;
    }

    .project-brand-candidate small {
      display: block;
      margin-top: 4px;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.5;
    }

    @media (max-width: 680px) {
      .project-brand-form-grid { grid-template-columns: 1fr; }
      .project-brand-field.full { grid-column: auto; }
      .project-brand-status { width: 100%; margin-left: 0; }
      .project-brand-dialog :is(button, input, select) { min-height: 44px; }
    }
    .dynamic-form-wizard {
      width: min(440px, calc(100vw - 32px));
      border: 1px solid #d8dde6;
      border-radius: 8px;
      padding: 0;
      color: #1f2937;
      background: #fff;
      box-shadow: 0 18px 48px rgb(15 23 42 / 22%);
    }

    .dynamic-form-wizard::backdrop {
      background: rgb(15 23 42 / 42%);
    }

    .dynamic-form-wizard form {
      display: grid;
      gap: 16px;
      padding: 20px;
    }

    .dynamic-form-wizard header,
    .dynamic-form-wizard footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
    }

    .dynamic-form-wizard h3,
    .dynamic-form-wizard p {
      margin: 0;
    }

    .dynamic-form-wizard label,
    .dynamic-form-wizard fieldset {
      display: grid;
      gap: 8px;
    }

    .dynamic-form-wizard fieldset label {
      display: inline-flex;
      align-items: center;
    }

    .dynamic-form-wizard input[type="text"],
    .dynamic-form-wizard select {
      min-height: 40px;
      width: 100%;
    }
    .sidebar [hidden] { display: none !important; }

    [data-hr-sidebar-nav] {
      display: none;
    }

    body [data-module="hr"] {
      display: none !important;
    }

    body[data-active-module="hr"] .app {
      grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
    }

    body[data-active-module="hr"] .sidebar {
      display: block;
    }

    body[data-active-module="hr"] [data-module="workflow"] {
      display: none !important;
    }

    body[data-active-module="hr"] [data-module="hr"] {
      display: flex !important;
    }

    body[data-active-module="hr"] [data-hr-sidebar-nav] {
      display: block;
    }

    body[data-active-module="hr"] [data-page="hr"] {
      width: 100%;
      min-width: 0;
    }

    .hr-workbench {
      width: 100%;
      min-width: 0;
      display: grid;
      gap: 14px;
    }

    .hr-workbench__header {
      margin: 0;
    }

    .hr-workbench__header h1 {
      margin: 0 0 4px;
      letter-spacing: 0;
    }

    .hr-workbench button,
    .hr-workbench select {
      min-height: 34px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: #fff;
      color: var(--ink);
      padding: 0 12px;
      cursor: pointer;
    }

    .hr-workbench__nav {
      display: none;
      gap: 4px;
      padding: 12px;
      border: 1px solid var(--line);
      border-radius: 4px;
      background: var(--surface);
    }

    .hr-workbench__nav button[aria-current="page"] {
      border-color: var(--weijia-green);
      color: #356500;
      background: #eef7e7;
    }

    .hr-workbench__content {
      padding: 18px;
      overflow-x: auto;
    }

    .hr-workbench__panel {
      min-width: 0;
      overflow: hidden;
    }

    .hr-workbench__content h2 {
      margin: 0 0 14px;
      font-size: 17px;
      letter-spacing: 0;
    }

    .hr-workbench__content table {
      width: 100%;
      border-collapse: collapse;
      min-width: 680px;
    }

    .hr-workbench__content th,
    .hr-workbench__content td {
      padding: 10px 12px;
      border-bottom: 1px solid var(--line);
      text-align: left;
      white-space: nowrap;
    }

    .hr-workbench [data-position-form] {
      display: grid;
      gap: 14px;
      max-width: 680px;
      margin-top: 18px;
      padding-top: 18px;
      border-top: 1px solid var(--line);
    }

    .hr-workbench [data-position-form] fieldset {
      border: 1px solid var(--line);
      border-radius: 4px;
      padding: 12px;
    }

    .hr-workbench [data-position-form] fieldset label {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      margin: 6px 16px 6px 0;
    }

    @media (max-width: 900px) {
      body[data-active-module="hr"] .app {
        grid-template-columns: minmax(0, 1fr);
      }

      body[data-active-module="hr"] .sidebar {
        display: none;
      }

      .hr-workbench__header {
        align-items: flex-start;
      }

      .hr-workbench__nav {
        display: flex;
        overflow-x: auto;
        flex-wrap: nowrap;
      }

      .hr-workbench__nav button {
        white-space: nowrap;
      }
    }
    :root {
      --login-bg: #090a0d;
      --login-card: #15171c;
      --login-ink: #f7f7f5;
      --login-accent: #e8f719;
      --login-muted: #a6a9b2;
    }

    .store-login-shell {
      width: min(100%, 1180px);
      min-height: min(680px, calc(100vh - 48px));
      display: grid;
      grid-template-columns: minmax(0, 1.08fr) minmax(380px, .92fr);
      overflow: hidden;
      border: 1px solid rgba(255, 255, 255, .09);
      border-radius: 26px;
      background: var(--login-bg);
      box-shadow: 0 28px 80px rgba(0, 0, 0, .28);
    }

    .store-login-brand-panel {
      position: relative;
      overflow: hidden;
      padding: 52px;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      color: var(--login-ink);
      background:
        radial-gradient(circle at 75% 25%, rgba(232, 247, 25, .17), transparent 28%),
        linear-gradient(145deg, #22252a, #121418);
    }

    .store-login-brand-panel::after {
      content: "";
      position: absolute;
      right: -110px;
      bottom: -130px;
      width: 360px;
      height: 360px;
      border: 1px solid rgba(232, 247, 25, .13);
      border-radius: 50%;
      box-shadow: 0 0 0 54px rgba(255, 255, 255, .025), 0 0 0 108px rgba(255, 255, 255, .015);
    }

    .store-login-brand,
    .store-login-hero,
    .store-login-foot { position: relative; z-index: 1; }
    .store-login-brand { display: flex; align-items: center; gap: 14px; }
    .store-login-mark {
      width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center;
      background: var(--login-accent); color: #111318; font-size: 21px; font-weight: 900;
      box-shadow: 0 0 0 10px rgba(232, 247, 25, .07);
    }
    .store-login-brand strong { display: block; font-size: 18px; }
    .store-login-brand small { color: var(--login-muted); font-size: 12px; }
    .store-login-eyebrow { color: var(--login-accent); font-size: 12px; letter-spacing: .16em; text-transform: uppercase; }
    .store-login-hero h1 { margin: 14px 0 15px; max-width: 520px; font-size: clamp(38px, 4.5vw, 64px); line-height: 1.03; letter-spacing: -.045em; }
    .store-login-hero h1 span { color: var(--login-accent); }
    .store-login-hero p { max-width: 430px; margin: 0; color: var(--login-muted); font-size: 15px; line-height: 1.8; }
    .store-login-foot { color: #747780; font-size: 11px; letter-spacing: .09em; }

    .store-login-form-panel { padding: 54px; display: flex; align-items: center; background: var(--login-ink); color: #111318; }
    .store-login-form-wrap { width: 100%; max-width: 410px; margin: auto; }
    .store-login-form-wrap h2 { margin: 0; font-size: 30px; letter-spacing: -.03em; }
    .store-login-form-wrap > p { margin: 8px 0 32px; color: #6f737a; font-size: 14px; }
    .store-login-form { display: grid; gap: 8px; }
    .store-login-form label { margin-top: 9px; color: #363a40; font-size: 12px; font-weight: 750; }
    .store-login-form input {
      width: 100%; height: 50px; border: 1px solid #d9dce0; border-radius: 13px;
      padding: 0 15px; background: #fff; color: #111318; outline: none;
    }
    .store-login-form input:focus { border-color: #a6ae13; box-shadow: 0 0 0 3px rgba(232, 247, 25, .35); }
    .store-login-form #loginButton {
      width: 100%; height: 50px; margin-top: 16px; border: 0; border-radius: 13px;
      background: #111318; color: var(--login-ink); font-weight: 800; cursor: pointer;
    }
    .store-login-form #loginButton:not(:disabled):hover { color: var(--login-accent); }
    .store-login-form #loginButton:disabled { cursor: wait; opacity: .58; }
    .store-login-feedback { min-height: 20px; margin: 12px 0 0; color: #6f737a; font-size: 12px; }
    .store-login-feedback.error { color: #b42318; }
    .store-login-admin-note { margin-top: 18px; padding: 14px 15px; border-radius: 13px; background: #eceee8; color: #60645f; font-size: 12px; line-height: 1.65; }
    .store-login-admin-note strong { color: #111318; }
    .store-login-guards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 26px; }
    .store-login-guards div { border-top: 1px solid #dddeda; padding-top: 10px; color: #8b8e8a; font-size: 10px; }
    .store-login-guards b { display: block; margin-bottom: 3px; color: #40433f; font-size: 11px; }

    @media (max-width: 820px) {
      .store-login-shell { grid-template-columns: 1fr; min-height: auto; border-radius: 20px; }
      .store-login-brand-panel { min-height: 270px; padding: 32px; }
      .store-login-hero h1 { font-size: 38px; }
      .store-login-foot { display: none; }
      .store-login-form-panel { padding: 34px; }
    }

    body[data-auth-shell-state="initializing"] .sidebar,
    body[data-auth-shell-state="locked"] .sidebar,
    body[data-auth-shell-state="initializing"] .topbar,
    body[data-auth-shell-state="locked"] .topbar,
    body[data-auth-shell-state="initializing"] .hq-config-mode-banner,
    body[data-auth-shell-state="locked"] .hq-config-mode-banner,
    body[data-auth-shell-state="initializing"] .content-head,
    body[data-auth-shell-state="locked"] .content-head,
    body[data-auth-shell-state="initializing"] [data-folder-panel]:not([data-folder-panel="account"]),
    body[data-auth-shell-state="locked"] [data-folder-panel]:not([data-folder-panel="account"]) {
      display: none !important;
    }

    body[data-auth-shell-state="initializing"] .app,
    body[data-auth-shell-state="locked"] .app {
      grid-template-columns: minmax(0, 1fr);
      min-height: 100vh;
      background: var(--login-bg);
    }

    body[data-auth-shell-state="initializing"] .main,
    body[data-auth-shell-state="locked"] .main,
    body[data-auth-shell-state="initializing"] .content,
    body[data-auth-shell-state="locked"] .content {
      min-height: 100vh;
    }

    body[data-auth-shell-state="initializing"] .content,
    body[data-auth-shell-state="locked"] .content {
      display: grid;
      place-items: center;
      padding: 24px;
    }

    body[data-auth-shell-state="initializing"] [data-folder-panel="account"],
    body[data-auth-shell-state="locked"] [data-folder-panel="account"] {
      display: block !important;
      width: min(100%, 1180px);
    }

    body[data-auth-shell-state="initializing"] [data-folder-panel="account"] .store-field,
    body[data-auth-shell-state="locked"] [data-folder-panel="account"] .store-field,
    body[data-auth-shell-state="initializing"] [data-folder-panel="account"] [data-login-required-hint][hidden],
    body[data-auth-shell-state="locked"] [data-folder-panel="account"] [data-login-required-hint][hidden] {
      display: none !important;
    }

    body[data-auth-shell-state="initializing"] [data-folder-panel="account"] .settings-account,
    body[data-auth-shell-state="locked"] [data-folder-panel="account"] .settings-account {
      padding: 28px;
    }

    body[data-auth-shell-state="initializing"] [data-folder-panel="account"] .login-bar,
    body[data-auth-shell-state="locked"] [data-folder-panel="account"] .login-bar {
      margin-top: 18px;
    }


/* Initialization is a loading state, not a failed or missing login. */
.portal-page-loading { display: none; }
body[data-auth-shell-state="initializing"] .app { display: none !important; }
body[data-auth-shell-state="initializing"] .portal-page-loading {
  display: grid;
  place-items: center;
  position: fixed;
  inset: 0;
  min-height: 100vh;
  background: #f5f6f8;
  color: #616773;
  font: 14px/1.5 system-ui, sans-serif;
}

/* Store permission editor shares the HR workbench layout. */
.hr-workbench [data-hr-view="rolesPermissions"] > section {
  margin-top: 24px;
  max-width: 980px;
}
.hr-workbench [data-hr-view="rolesPermissions"] h3 { margin: 0 0 12px; }
.hr-workbench [data-permission-role-form],
.hr-workbench [data-permission-employee-form] { margin-top: 16px; }
.hr-workbench [data-permission-role-form] h4,
.hr-workbench [data-permission-employee-form] h4 { margin: 0 0 8px; }
.hr-workbench [data-permission-role-form] > fieldset,
.hr-workbench [data-permission-employee-form] > fieldset {
  border: 1px solid #e3e7ed;
  border-radius: 8px;
  padding: 16px;
  min-width: 0;
}
.hr-workbench [data-hr-view="rolesPermissions"] details {
  border-bottom: 1px solid #e3e7ed;
  padding: 10px 0;
}
.hr-workbench [data-hr-view="rolesPermissions"] summary { cursor: pointer; font-weight: 600; }
.hr-workbench [data-hr-view="rolesPermissions"] input[name="permissionReason"] {
  padding: 8px 10px;
  border: 1px solid #d9dfe8;
  border-radius: 6px;
  width: min(360px, 100%);
  box-sizing: border-box;
}
.hr-workbench [data-permission-role-save],
.hr-workbench [data-permission-employee-save] { margin: 10px 0 0 10px; }
.hr-workbench [data-permission-saved] { color: #28703e; }
.hr-workbench [data-permission-form-error] { color: #a62b2b; }

/* Permission matrix: compact, reviewable, and usable without opening a drawer. */
.permission-page-head,
.permission-section-head,
.permission-employee-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}
.permission-page-head p,
.permission-section-head p,
.permission-employee-summary p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.permission-tabs { display: flex; gap: 26px; border-bottom: 1px solid var(--line); margin: 10px 0 18px; }
.permission-tabs button { border: 0; border-radius: 0; background: transparent; padding: 8px 4px 10px; color: #586779; font-weight: 700; }
.permission-tabs button.is-active { color: var(--weijia-green); border-bottom: 3px solid var(--weijia-green); }
.permission-role-pills { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.permission-role-pill { min-width: 76px; border-radius: 9px !important; background: #f7f9fb !important; }
.permission-role-pill.is-active { color: #fff !important; background: var(--weijia-green) !important; border-color: var(--weijia-green) !important; font-weight: 700; }
.permission-role-panel,
.permission-employee-panel { width: 100%; max-width: none !important; }
.hr-workbench__panel:has([data-hr-view="rolesPermissions"]) { max-width: 1440px; }
.hr-workbench [data-permission-role-form],
.hr-workbench [data-permission-employee-form] { width: 100%; max-width: none; }
.permission-form-title { display: flex; align-items: center; gap: 12px; }
.permission-form-title h4 { margin: 0; font-size: 16px; }
.permission-disabled-note,
.permission-lock-note { color: #9b5d12; font-size: 12px; }
.permission-matrix { width: 100% !important; min-width: 760px !important; table-layout: fixed; border: 1px solid #e2e8ef; border-radius: 10px; overflow: hidden; }
.permission-matrix th,
.permission-matrix td { text-align: center !important; padding: 8px 6px !important; border: 1px solid #e7ecf1 !important; white-space: normal !important; }
.permission-matrix thead th { background: #f7f9fb; font-size: 12px; color: #4d5b6b; }
.permission-matrix tbody th { text-align: left !important; font-weight: 700; background: #fbfcfd; }
.permission-matrix th:first-child { width: 19%; }
.permission-matrix th:last-child { width: 19%; }
.permission-unavailable { color: #b7c0ca; font-size: 17px; }
.permission-risk { display: block; color: #b45d2c; font-size: 10px; font-weight: 500; }
.permission-control { min-height: 32px; display: inline-flex; align-items: center; justify-content: center; gap: 4px; position: relative; }
.permission-control > input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--weijia-green); cursor: pointer; }
.permission-control > select[hidden] { display: none !important; }
.permission-override-dot { color: #e68a25; font-size: 10px; line-height: 1; }
.permission-reset { min-height: 22px !important; padding: 0 4px !important; border: 0 !important; background: transparent !important; color: #19855a !important; font-size: 11px; }
.permission-fields { text-align: left; border: 0 !important; padding: 0 !important; }
.permission-fields summary { color: #16865a; font-size: 12px; }
.permission-field-list { display: grid; gap: 4px; padding: 6px 0; }
.permission-field-list > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; color: #526171; }
.permission-field-list .permission-control { flex: 0 0 auto; }
.permission-field-modes { display: inline-flex; align-items: center; gap: 8px; }
.permission-field-mode { display: inline-flex; align-items: center; gap: 3px; }
.permission-field-mode small { color: #84909c; font-size: 10px; }
.permission-field-unavailable { color: #a97836; font-size: 11px; white-space: nowrap; }
.permission-field-reset { min-height: 22px !important; padding: 0 4px !important; border: 0 !important; background: transparent !important; color: #19855a !important; font-size: 11px; }
.permission-template-panel { margin-top: 18px; padding: 14px 16px; border: 1px solid #e2e8ef; border-radius: 10px; background: #fff; }
.permission-template-head-actions,
.permission-template-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.permission-template-list { display: grid; gap: 8px; list-style: none; margin: 12px 0 0; padding: 0; }
.permission-template-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 10px; border: 1px solid #edf0f3; border-radius: 8px; }
.permission-template-row > div:first-child { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.permission-template-status,
.permission-template-assigned { color: #718092; font-size: 12px; }
.permission-template-assigned { color: #19855a; }
.permission-template-preview { display: grid; gap: 8px; margin-top: 12px; padding: 10px; border-radius: 8px; background: #f7f9fb; color: #536273; font-size: 12px; }
.permission-preview-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.permission-preview-columns > div { display: grid; gap: 4px; padding: 8px; border: 1px solid #e2e8ef; border-radius: 6px; background: #fff; }
.permission-preview-columns small { color: #718092; }
.permission-template-editor { flex: 1 0 100%; min-width: 0; margin-top: 10px; padding-top: 8px; border-top: 1px solid #edf0f3; }
.permission-template-editor > summary { color: #16865a; font-size: 12px; }
.permission-template-form { display: grid; gap: 7px; margin-top: 10px; padding: 9px; border: 1px solid #edf0f3; border-radius: 7px; }
.permission-template-form h5 { margin: 0; color: #31465b; font-size: 12px; }
.permission-template-actions-grid { display: grid; gap: 6px; }
.permission-template-action { display: grid; grid-template-columns: 110px 90px minmax(0, 1fr); align-items: center; gap: 8px; font-size: 12px; }
.permission-template-action > label { display: flex; align-items: center; gap: 5px; }
.permission-template-custom-scope { display: inline-flex; gap: 5px; min-width: 0; }
.permission-template-custom-scope[hidden] { display: none; }
.permission-template-custom-scope select,
.permission-template-custom-scope input,
.permission-template-action > select,
.permission-template-field select { min-height: 26px; padding: 3px 6px; font-size: 12px; }
.permission-template-custom-scope input { min-width: 80px; flex: 1; }
.permission-template-fields { display: grid; gap: 5px; padding-top: 5px; border-top: 1px dashed #e6ebef; }
.permission-template-field { display: flex; justify-content: space-between; gap: 8px; align-items: center; color: #526171; font-size: 12px; }
.permission-template-editor > button { margin-top: 9px; color: #fff; background: var(--weijia-green); border-color: var(--weijia-green); }
.permission-preview-grants,
.permission-preview-sources,
.permission-preview-changes { display: grid; gap: 4px; margin: 0; padding-left: 18px; }
.permission-preview-grants li { display: grid; gap: 2px; }
.permission-preview-grants small,
.permission-preview-sources li,
.permission-preview-changes li { color: #718092; }
.permission-ai { margin-top: 14px; border: 1px solid #e2e8ef !important; border-radius: 9px; padding: 10px 12px !important; }
.permission-ai summary { display: flex; justify-content: space-between; color: #23364d; }
.permission-ai summary span { color: #788696; font-size: 12px; font-weight: 400; }
.permission-ai ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; list-style: none; padding: 10px 0 0; margin: 0; }
.permission-ai li { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid #edf0f3; padding-top: 7px; }
.permission-ai-label { color: #526171; font-size: 13px; }
.permission-muted,
.permission-empty { color: #83909d; font-size: 13px; }
.permission-resolution { margin-top: 16px; border: 1px solid #e2e8ef !important; border-radius: 9px; padding: 10px 12px !important; }
.permission-resolution ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px 18px; list-style: none; padding: 10px 0 0; margin: 0; }
.permission-resolution li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; align-items: center; font-size: 12px; }
.permission-resolution li small { color: #7c8996; }
.permission-source--employeeDeny { color: #b13e39; }
.permission-source--employeeAllow { color: #16865a; }
.permission-source--publishedSeed { color: #657587; }
.permission-save-row { display: flex; justify-content: flex-end; align-items: center; gap: 16px; margin-top: 12px; color: #6b7785; font-size: 12px; }
.permission-save-row output { color: #6f7c8b; }
.permission-save-row + p { margin: 8px 0 0; }
.hr-workbench [data-permission-role-save],
.hr-workbench [data-permission-employee-save] { display: block; margin: 12px 0 0 auto; border-color: var(--weijia-green); background: var(--weijia-green); color: #fff; font-weight: 700; }
.hr-workbench [data-permission-confirm-dialog] { width: min(480px, calc(100vw - 32px)); border: 0; border-radius: 12px; padding: 20px; box-shadow: 0 18px 60px rgba(19, 38, 59, .25); }
.hr-workbench [data-permission-confirm-dialog]::backdrop { background: rgba(18, 32, 47, .38); }
.hr-workbench [data-permission-confirm-dialog] h3 { margin: 0 0 12px; }
.hr-workbench [data-permission-confirm-dialog] ul { padding-left: 20px; max-height: 220px; overflow: auto; }
.hr-workbench [data-permission-confirm-dialog] label { display: grid; gap: 6px; margin: 14px 0; }
.hr-workbench [data-permission-confirm-dialog] input[name="permissionReason"] { width: 100%; box-sizing: border-box; }
.hr-workbench [data-permission-confirm-dialog] [data-permission-confirm-cancel] { margin-right: 8px; }
.hr-workbench [data-permission-confirm-dialog] [data-permission-delete-warning] { color: #ae4d2d; font-size: 13px; }

@media (max-width: 760px) {
  .permission-page-head,
  .permission-section-head,
  .permission-employee-summary { display: grid; }
  .permission-ai ul,
  .permission-resolution ul,
  .permission-preview-columns { grid-template-columns: 1fr; }
  .permission-template-row { align-items: flex-start; flex-direction: column; }
  .permission-template-action { grid-template-columns: 1fr; }
  .permission-template-custom-scope { flex-wrap: wrap; }
  .permission-save-row { justify-content: flex-start; }
}
