/*
 * Workspace refinement
 *
 * A final, scoped visual layer inspired by Enterprise WeChat's calm desktop
 * workspace: a soft blue-gray navigation rail, a bright document canvas,
 * compact action controls, and readable text hierarchy. It deliberately keeps
 * the ledger's existing information architecture and interactions intact.
 */

:root {
  --wx-nav: #eaf1f8;
  --wx-nav-strong: #e2ebf5;
  --wx-nav-ink: #3d5068;
  --wx-nav-muted: #71859b;
  --wx-active: #d9e7fb;
  --wx-active-ink: #1c65d1;
  --wx-canvas: #f5f7fa;
  --wx-line: #e3e8ee;
  --wx-line-strong: #d3dbe5;
  --wx-ink: #1f2937;
  --wx-muted: #64748b;
  --wx-blue: #2f6de6;
  --wx-blue-soft: #eaf2ff;
}

body {
  color: var(--wx-ink);
  background: var(--wx-canvas);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
}

/* The screenshot's first rail is a navigation surface, not a dark dashboard
   banner. Keep the existing brand and nav structure while lightening it. */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  align-self: flex-start;
  width: 212px;
  flex-basis: 212px;
  padding: 20px 12px 16px;
  color: var(--wx-nav-ink);
  background: var(--wx-nav);
  border-right: 1px solid var(--wx-line);
}
.brand-block { padding: 0 8px; }
.brand-mark { width: 36px; height: 36px; border: 0; border-radius: 8px; background: var(--wx-blue); }
.brand-name { color: #243852; font-size: 12px; letter-spacing: .12em; }
.brand-subtitle { color: var(--wx-nav-muted); font-size: 9px; }
.sidebar-rule { margin: 22px 8px 21px; background: var(--wx-line-strong); }
.nav-label { padding-left: 10px; color: var(--wx-nav-muted); font-size: 11px; letter-spacing: .08em; }
.nav-label-spaced { margin-top: 22px; }
.nav-list { gap: 2px; }
.nav-item {
  min-height: 36px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 7px;
  color: var(--wx-nav-ink);
  font-size: 13px;
  font-weight: 500;
}
.nav-item:hover { color: var(--wx-active-ink); background: rgba(255,255,255,.55); }
.nav-item.active {
  color: var(--wx-active-ink);
  border-color: transparent;
  background: var(--wx-active);
  box-shadow: none;
}
.ui-symbols { position: absolute; width: 0; height: 0; overflow: hidden; }
.nav-icon, .ui-icon { width: 19px; height: 19px; flex: 0 0 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.nav-icon { color: #71849b; }
.nav-item.active .nav-icon { color: var(--wx-active-ink); }
.version-stamp { color: var(--wx-nav-muted); font-size: 10px; }

.main-content { background: var(--wx-canvas); }
.topbar {
  min-height: 60px;
  gap: 16px;
  padding: 10px 32px;
  border-bottom-color: var(--wx-line);
  background: #fff;
}
.topbar-context { min-width: 0; color: #53657b; font-size: 13px; font-weight: 500; }
.topbar-actions { gap: 7px; flex-wrap: wrap; }
.role-hint { color: var(--wx-muted); font-size: 12px; }
.role-switch { border-color: var(--wx-line-strong); background: #f5f7fa; }
.role-option { min-height: 30px; color: var(--wx-muted); font-size: 12px; font-weight: 500; }
.role-option.active { color: var(--wx-active-ink); background: #fff; box-shadow: 0 1px 3px rgba(15,23,42,.08); }
.role-member-select { min-height: 32px; color: var(--wx-ink); font-size: 12px; }

.page {
  max-width: 1480px;
  padding: 28px 32px 48px;
}
.page-heading {
  align-items: center;
  gap: 24px;
  margin-bottom: 21px;
}
.page-heading h1 {
  max-width: 700px;
  margin: 0 0 5px;
  color: #172235;
  font-size: 26px;
  line-height: 1.3;
  letter-spacing: -.025em;
  font-weight: 600;
}
.page-heading p {
  max-width: 760px;
  color: var(--wx-muted);
  font-size: 14px;
  line-height: 1.6;
  font-weight: 400;
}
.heading-meta {
  min-width: 136px;
  padding: 4px 0 4px 14px;
  border-left: 1px solid var(--wx-blue);
  color: var(--wx-muted);
  font-size: 12px;
  line-height: 1.45;
}
.heading-meta strong { color: var(--wx-ink); font-size: 17px; font-weight: 600; letter-spacing: 0; }

.data-status-bar {
  margin: -3px 0 13px;
  padding: 9px 12px;
  border: 1px solid var(--wx-line);
  background: #f0f3f7;
  color: var(--wx-muted);
  border-radius: 5px;
  font-size: 12px;
  line-height: 1.5;
}
.status-pill { color: #52647b !important; background: #e2e9f1; font-size: 11px; font-weight: 500; }

/* WeChat-like segmented date control: one quiet capsule with one selected
   action, instead of four competing button surfaces. */
.day-toolbar {
  min-height: 48px;
  margin-bottom: 14px;
  padding: 5px 8px;
  border: 1px solid var(--wx-line);
  border-radius: 6px;
  background: #fff;
  box-shadow: none;
}
.day-tabs { gap: 2px; }
.day-tabs button {
  min-height: 34px;
  padding: 0 13px;
  border-radius: 5px;
  color: var(--wx-muted);
  font-size: 13px;
  font-weight: 500;
}
.day-tabs button:hover { color: var(--wx-active-ink); background: var(--wx-blue-soft); }
.day-tabs button.active { color: var(--wx-active-ink); background: var(--wx-blue-soft); box-shadow: none; }
.project-filter-group { display: flex; flex-wrap: wrap; gap: 4px; }
.project-filter-button[aria-pressed="true"] { color: var(--wx-active-ink); border-color: #b8cdf0; background: var(--wx-blue-soft); }
.date-control { gap: 8px; }
.date-control label, .scope-note { font-size: 12px; }
.date-control select, .date-control input, .scope-readout { min-height: 32px; font-size: 12px; }

.stat-grid { gap: 0; margin-bottom: 18px; }
.stat-card { min-height: 102px; padding: 16px 17px; border-radius: 0; box-shadow: none; }
.stat-card:first-child { border-radius: 5px 0 0 5px; }
.stat-card:last-child { border-radius: 0 5px 5px 0; }
.stat-card .stat-label { font-size: 13px; font-weight: 500; }
.stat-card .stat-number { margin-top: 8px; font-size: 28px; font-weight: 600; letter-spacing: -.035em; }
.stat-card .stat-note { font-size: 12px; }

.panel {
  border: 1px solid var(--wx-line);
  border-radius: 6px;
  box-shadow: none;
}
.panel-head { padding: 15px 17px; border-bottom-color: var(--wx-line); }
.panel-title { color: var(--wx-ink); font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.panel-subtitle { color: var(--wx-muted); font-size: 13px; font-weight: 400; }
.panel-body { padding: 17px; }
.table-toolbar {
  margin: -17px -17px 14px;
  padding: 11px 17px;
  border-bottom: 1px solid var(--wx-line);
  background: #f8fafc;
}
.table-toolbar .toolbar-left,
.table-toolbar .toolbar-right { align-items: center; }
.search-input {
  padding-left: 32px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='%2371859b' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='m16 16 4.5 4.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 10px 50%;
  background-size: 15px;
}
.search-input:focus { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='15' height='15' viewBox='0 0 24 24' fill='none' stroke='%232f6de6' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='m16 16 4.5 4.5'/%3E%3C/svg%3E"); }

.button {
  min-height: 34px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 500;
  box-shadow: none;
}
.button-primary { background: var(--wx-blue); border-color: var(--wx-blue); }
.button-primary:hover { background: #245dc9; border-color: #245dc9; }
.button-secondary { color: var(--wx-blue); border-color: #c9d8f5; background: var(--wx-blue-soft); }
.button-ghost { color: #405268; border-color: var(--wx-line-strong); background: #fff; }
.button-ghost:hover { color: var(--wx-blue); border-color: #a8c0ed; background: var(--wx-blue-soft); }
.chip { min-height: 23px; border-radius: 4px; font-size: 12px; font-weight: 500; }

.data-table-wrap { border-color: var(--wx-line); border-radius: 5px; }
.data-table th { padding: 10px 12px; color: #61758c; background: #f4f7fa; font-size: 12px; font-weight: 600; }
.data-table td { padding: 12px; color: var(--wx-ink); font-size: 14px; line-height: 1.6; }
.task-id { color: var(--wx-muted); font-size: 11px; font-weight: 400; letter-spacing: .01em; }
.task-name { font-size: 14px; font-weight: 600; line-height: 1.45; }
.task-table { min-width: 1280px; }
.task-table th { white-space: nowrap; }
.task-table td:first-child { min-width: 220px; max-width: 320px; }
.task-table td:nth-child(2) { min-width: 220px; max-width: 320px; }
.task-table td:nth-child(6) { min-width: 180px; }
.task-table td:is(:nth-child(3), :nth-child(4), :nth-child(5), :nth-child(7), :nth-child(8), :nth-child(9)) { white-space: nowrap; }
.task-table .task-name { margin-top: 0; overflow-wrap: normal; }
.task-table .task-id { margin-top: 4px; white-space: nowrap; }
.data-table td small { font-size: 12px; }
.data-table tbody tr:hover { background: #f4f8ff; }

.table-empty { padding: 54px 20px; color: var(--wx-muted); font-size: 14px; }

/* Empty states stay visually centred in their panel at every width. */
.empty-state { min-height: 176px; padding: 25px 20px; }
.empty-state-inner,
.empty-state > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: min(100%, 360px);
  text-align: center;
}
.empty-glyph { width: 42px; height: 42px; margin: 0 0 12px; font-size: 18px; }
.empty-copy { display: contents; }
.empty-state h3 { margin: 0 0 5px; color: var(--wx-ink); font-size: 15px; font-weight: 600; line-height: 1.45; }
.empty-state p { margin: 0; color: var(--wx-muted); font-size: 13px; line-height: 1.6; }
.empty-state.has-action .button { margin-top: 14px; }
.empty-state.compact { min-height: 142px; }

.action-list li { padding: 14px 17px; }
.action-list strong { font-size: 14px; font-weight: 600; }
.action-list small, .action-list .next-step-inline { font-size: 13px; font-weight: 400; }
.process-item strong, .qc-rule strong { font-size: 14px; font-weight: 600; }
.process-item span, .qc-rule-category { font-size: 13px; }

.modal-card { border-radius: 7px; box-shadow: 0 12px 36px rgba(15,23,42,.16); }
.detail-drawer { box-shadow: -10px 0 28px rgba(15,23,42,.12); }

/* Everyday workspace: clear actions, short previews and quiet utility controls. */
.sidebar > * { flex-shrink: 0; }
.sidebar-bottom { padding-top: 24px; }
.topbar-actions { flex-shrink: 0; }
.workspace-tools { position: relative; }
.workspace-tools summary { list-style: none; gap: 10px; cursor: pointer; user-select: none; }
.workspace-tools summary::-webkit-details-marker { display: none; }
.workspace-tools[open] summary { background: var(--wx-blue-soft); border-color: #bfd0ed; color: var(--wx-blue); }
.workspace-tools-menu { position: absolute; right: 0; top: calc(100% + 8px); width: 190px; padding: 6px; border: 1px solid var(--wx-line); border-radius: 8px; background: white; box-shadow: 0 6px 20px rgba(25, 42, 63, .12); z-index: 10; }
.tools-label { display: block; padding: 7px 10px; color: var(--wx-muted); font-size: 12px; }
.workspace-tools-menu button { display: block; width: 100%; padding: 9px 10px; border: 0; border-radius: 4px; color: var(--wx-ink); background: transparent; text-align: left; font-size: 13px; }
.workspace-tools-menu button:hover { background: var(--wx-blue-soft); color: var(--wx-blue); }
.workspace-tools-menu #downloadSchema { display: block; }
.button { white-space: nowrap; }
.button:focus-visible, .nav-item:focus-visible, summary:focus-visible, .project-preview-row:focus-visible { outline: 2px solid var(--wx-blue); outline-offset: 2px; }
.grid-two { align-items: start; }
.stat-card.accent { background: #ecf3ff; border-color: #d7e4f6; }
.stat-card.accent .stat-number { color: #215fc0; }
.stat-card.accent .stat-label, .stat-card.accent .stat-note { color: #50688c; }
.chip { white-space: nowrap; }
.project-preview-list { list-style: none; margin: 0; padding: 0; }
.project-preview-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) 104px; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--wx-line); cursor: pointer; }
.project-preview-identity { align-self: start; padding-top: 2px; }
.project-preview-row:last-child { border-bottom: 0; }
.project-preview-row:hover { background: #f6f9fd; }
.project-preview-mark { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid #d8e4f2; border-radius: 8px; background: #eef4fc; color: #496e9b; font-size: 15px; font-weight: 600; }
.project-preview-avatar { display: grid; place-items: center; width: 40px; height: 40px; overflow: hidden; border: 1px solid #d8e4f2; border-radius: 50%; background: #eef4fc; }
.project-preview-avatar .account-avatar { width: 100%; height: 100%; font-size: 13px; }
.project-preview-avatar .account-avatar-fallback { color: #5f7ea2; font-size: 13px; font-weight: 700; }
.project-preview-copy { min-width: 0; }
.project-preview-copy strong { display: block; color: var(--wx-ink); font-size: 14px; font-weight: 600; line-height: 1.5; }
.project-preview-account { display: grid; min-width: 0; gap: 1px; margin-bottom: 3px; }
.project-preview-account strong { overflow: hidden; color: #415a78; font-size: 12px; font-weight: 600; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.project-preview-account span { overflow: hidden; color: var(--wx-blue); font-size: 11px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.project-preview-account-fallback { display: block; color: var(--wx-muted); font-size: 12px; line-height: 1.6; overflow-wrap: anywhere; }
.project-preview-project { color: var(--wx-ink) !important; text-wrap: balance; overflow-wrap: anywhere; }
.project-preview-copy > span { display: block; color: var(--wx-muted); font-size: 12px; line-height: 1.6; overflow-wrap: anywhere; }
.project-preview-copy small { display: block; margin-top: 5px; color: #607086; font-size: 12px; line-height: 1.6; }
.content-plan-compact { display: flex; flex-wrap: wrap; gap: 5px 12px; margin-top: 8px; color: #71839a; font-size: 11px; line-height: 1.35; }
.content-plan-compact span { white-space: nowrap; }
.project-preview-meta { display: flex; min-width: 0; flex-direction: column; align-items: stretch; justify-content: center; gap: 7px; }
.project-preview-status { display: flex; justify-content: flex-end; }
.project-preview-owner { display: flex; align-items: baseline; justify-content: flex-end; gap: 5px; white-space: nowrap; }
.project-preview-owner span { color: var(--wx-muted); font-size: 11px; }
.project-preview-owner strong { color: var(--wx-ink); font-size: 12px; font-weight: 600; }
.project-content-plan { margin: 18px 0; padding: 14px; border: 1px solid #dbe5f1; border-radius: 8px; background: #f8fbff; }
.project-content-plan-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.project-content-plan-head strong { display: block; margin-top: 3px; color: var(--wx-ink); font-size: 15px; font-weight: 600; }
.content-plan-note { color: var(--wx-muted); font-size: 11px; white-space: nowrap; }
.content-plan-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.content-plan-grid > div { min-width: 0; padding: 9px 8px; border: 1px solid #e2eaf4; border-radius: 6px; background: #fff; }
.content-plan-grid strong, .content-plan-grid span, .content-plan-grid small { display: block; }
.content-plan-grid strong { color: var(--wx-blue); font-size: 18px; line-height: 1.2; }
.content-plan-grid span { margin-top: 3px; color: var(--wx-ink); font-size: 11px; font-weight: 600; }
.content-plan-grid small { margin-top: 4px; color: var(--wx-muted); font-size: 10px; line-height: 1.35; }
.project-progress-compact { display: flex; flex-wrap: wrap; gap: 5px 12px; margin-top: 5px; color: #2f6fed; font-size: 11px; line-height: 1.35; }
.project-progress-compact span { white-space: nowrap; }
.project-actual-progress { margin: 18px 0; padding: 14px; border: 1px solid #dbe5f1; border-radius: 8px; background: #fff; }
.project-actual-progress .actual-progress-grid { margin-bottom: 12px; }
.project-actual-progress .actual-progress-grid > div { background: #f8fbff; }
.project-actual-progress .project-progress-entry { display: grid; grid-template-columns: 1.25fr repeat(4, minmax(64px, .7fr)) auto; align-items: end; gap: 7px; padding-top: 11px; border-top: 1px solid #e6edf5; }
.project-actual-progress .project-progress-entry label { display: grid; gap: 4px; color: var(--wx-muted); font-size: 10px; }
.project-actual-progress .project-progress-entry input { min-width: 0; width: 100%; padding: 7px 8px; border: 1px solid var(--wx-line); border-radius: 5px; color: var(--wx-ink); font: inherit; font-size: 12px; }
.project-actual-progress .project-progress-entry input:focus { outline: none; border-color: var(--wx-blue); box-shadow: 0 0 0 3px rgba(47,111,237,.12); }
.project-actual-progress .project-progress-entry .button { white-space: nowrap; }
.project-progress-page-panel { margin-bottom: 18px; }
.project-progress-page-panel > .panel-head { align-items: center; }
.project-progress-page-panel > .panel-body { padding: 24px; }
.project-progress-identity { display: flex; align-items: center; gap: 13px; min-width: 0; margin-bottom: 16px; }
.project-progress-identity .account-avatar { display: grid; place-items: center; width: 48px; height: 48px; flex: 0 0 48px; overflow: hidden; border-radius: 50%; background: var(--wx-blue-soft); object-fit: cover; }
.project-progress-identity > div { display: grid; min-width: 0; gap: 2px; }
.project-progress-identity strong { overflow: hidden; color: var(--wx-ink); font-size: 17px; font-weight: 600; line-height: 1.5; text-overflow: ellipsis; white-space: nowrap; }
.project-progress-identity span { overflow: hidden; color: var(--wx-muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.project-progress-toolbar { display: grid; grid-template-columns: minmax(0, 360px) 180px; align-items: end; gap: 16px; padding-bottom: 18px; border-bottom: 1px solid var(--wx-line); }
.project-progress-toolbar .field { min-width: 0; gap: 7px; color: var(--wx-muted); font-size: 12px; font-weight: 500; }
.project-progress-toolbar select, .project-progress-toolbar input { min-width: 0; width: 100%; min-height: 40px; padding: 8px 11px; border: 1px solid var(--wx-line-strong); border-radius: 6px; color: var(--wx-ink); background: #fff; font: inherit; font-size: 13px; }
.project-progress-toolbar select:focus-visible, .project-progress-toolbar input:focus-visible,
.project-progress-page-panel .project-progress-entry input:focus-visible { outline: 2px solid var(--wx-blue); outline-offset: 2px; }
.project-progress-workspace { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: start; gap: 32px; margin-top: 20px; }
.project-progress-editor { min-width: 0; padding-top: 2px; }
.project-progress-section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.project-progress-section-head h3 { margin: 0; color: var(--wx-ink); font-size: 15px; font-weight: 600; line-height: 1.5; }
.project-progress-section-head > span { color: var(--wx-muted); font-size: 12px; white-space: nowrap; }
.project-progress-section-head .project-progress-state { padding: 2px 8px; border-radius: 4px; background: #f1f4f8; font-size: 11px; }
.project-progress-state.is-recorded { color: var(--wx-blue); background: var(--wx-blue-soft); }
.project-progress-state.is-dirty { color: #95611c; background: #fff5e5; }
.project-progress-page-panel .project-progress-entry { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 16px; margin-top: 18px; }
.project-progress-page-panel .project-progress-entry label { display: grid; min-width: 0; gap: 8px; color: var(--wx-ink); font-size: 13px; font-weight: 500; }
.project-progress-page-panel .project-progress-entry input { width: 100%; min-width: 0; min-height: 48px; margin: 0; padding: 9px 12px; border: 1px solid var(--wx-line-strong); border-radius: 6px; color: var(--wx-ink); background: #fff; font: inherit; font-size: 22px; font-weight: 500; line-height: 1.4; font-variant-numeric: tabular-nums; }
.project-progress-page-panel .project-progress-entry input:disabled { color: var(--wx-muted); background: #f5f7fa; cursor: not-allowed; }
.project-progress-page-panel .project-progress-entry small { color: var(--wx-muted); font-size: 11px; font-weight: 400; line-height: 1.5; }
.project-progress-post-total { display: flex; align-items: baseline; gap: 9px; margin-top: 16px; color: var(--wx-muted); font-size: 12px; }
.project-progress-post-total output { color: var(--wx-ink); font-size: 19px; font-weight: 600; font-variant-numeric: tabular-nums; }
.project-progress-post-total small { font-size: 11px; }
.project-progress-form-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--wx-line); }
.project-progress-form-footer .project-progress-form-note { flex: 1 1 180px; margin: 0; font-size: 12px; line-height: 1.6; }
.project-progress-form-footer .button { min-height: 40px; padding: 9px 16px; }
.project-progress-monthly { min-width: 0; padding: 20px 22px; border-radius: 8px; background: #f5f8fd; }
.project-progress-month-hint { margin: 5px 0 20px; color: var(--wx-muted); font-size: 11px; }
.project-progress-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; row-gap: 20px; margin: 0; }
.project-progress-metrics > div { min-width: 0; }
.project-progress-metrics dt { margin: 0 0 4px; color: #52657c; font-size: 12px; }
.project-progress-metrics dd { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px; margin: 0; font-variant-numeric: tabular-nums; }
.project-progress-metrics strong { color: var(--wx-blue); font-size: 28px; font-weight: 600; line-height: 1.3; }
.project-progress-metrics dd span { color: var(--wx-muted); font-size: 12px; white-space: nowrap; }
.project-progress-metrics .project-progress-metric-detail { padding-top: 15px; border-top: 1px solid #e0e8f3; }
.project-progress-metric-detail strong { color: #4b607c; font-size: 19px; font-weight: 500; }
.project-progress-month-note { margin: 19px 0 0; color: var(--wx-muted); font-size: 11px; line-height: 1.6; }
.project-progress-link { margin-top: 12px; }
.project-progress-form-note { margin-top: 8px; color: var(--wx-muted); font-size: 11px; }
.project-progress-form-note.is-recorded { color: #2f6fed; }
.empty-glyph { width: 46px; height: 46px; color: #7f96b1; background: #f1f5fa; border: 0; border-radius: 12px; }
.empty-glyph .ui-icon { width: 25px; height: 25px; }
.empty-state-inner { width: min(100%, 420px); }
.empty-state p { text-wrap: pretty; }
.search-input { width: 320px; max-width: 100%; }

/* Project and account ledgers share the approved quality-center hierarchy. */
.workspace-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: -3px 0 14px;
  padding: 11px 14px;
  border: 1px solid var(--wx-line);
  border-radius: 6px;
  background: #f0f3f7;
}
.workspace-summary-context,
.workspace-summary-metrics { display: flex; align-items: center; gap: 10px; }
.workspace-summary-context strong { color: var(--wx-ink); font-size: 15px; font-weight: 600; }
.workspace-summary-context > span:last-child { color: var(--wx-muted); font-size: 12px; }
.workspace-summary-metrics { gap: 0; }
.workspace-summary-metrics > div { min-width: 78px; padding: 0 12px; border-left: 1px solid var(--wx-line-strong); }
.workspace-summary-metrics strong { display: block; color: var(--wx-ink); font-size: 16px; font-weight: 600; line-height: 1.2; }
.workspace-summary-metrics span { display: block; margin-top: 2px; color: var(--wx-muted); font-size: 11px; white-space: nowrap; }
.workspace-panel-count { display: inline-flex; align-items: center; min-height: 24px; padding: 0 8px; border-radius: 4px; color: var(--wx-blue); background: var(--wx-blue-soft); font-size: 11px; font-weight: 500; white-space: nowrap; }
.project-queue-panel .panel-body,
.account-queue-panel .panel-body { padding-top: 17px; }
.project-table td,
.account-table td { vertical-align: top; }
.project-table .task-name,
.account-table .task-name { color: var(--wx-ink); font-size: 14px; font-weight: 600; line-height: 1.45; }
.project-table td small,
.account-table td small { display: block; margin-top: 3px; color: var(--wx-muted); font-size: 12px; line-height: 1.45; }
.project-table .next-step-cell strong { display: block; color: var(--wx-ink); font-size: 13px; font-weight: 500; line-height: 1.45; }
.project-table .next-step-cell small { color: #71849b; }
.account-table .account-link { display: inline-block; margin-top: 2px; color: var(--wx-blue); font-size: 13px; line-height: 1.45; }
.account-table .account-link:hover { text-decoration: underline; }
.account-table td:first-child { min-width: 218px; }
.table-footnote { margin: 13px 0 0; color: var(--wx-muted); font-size: 12px; line-height: 1.6; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

@media (max-width: 1100px) {
  .sidebar { width: 210px; flex-basis: 210px; }
  .topbar, .page { padding-left: 26px; padding-right: 26px; }
  .topbar { min-height: 72px; padding-top: 10px; padding-bottom: 10px; }
  .topbar-context { flex: 1 0 auto; white-space: nowrap; }
  .topbar-actions { justify-content: flex-end; }
  .page-heading h1 { font-size: 26px; }
}

@media (max-width: 900px) {
  .project-progress-workspace { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .project-progress-monthly { padding: 20px 22px; }
}

@media (max-width: 540px) {
  .project-progress-page-panel > .panel-body { padding: 20px 16px; }
  .project-progress-identity { margin-bottom: 22px; }
  .project-progress-identity strong { font-size: 16px; }
  .project-progress-toolbar { grid-template-columns: minmax(0, 1fr); gap: 14px; padding-bottom: 22px; }
  .project-progress-workspace { margin-top: 24px; }
  .project-progress-page-panel .project-progress-entry { gap: 10px; margin-top: 20px; }
  .project-progress-page-panel .project-progress-entry input { min-height: 48px; padding: 8px 10px; font-size: 20px; }
  .project-progress-form-footer { align-items: stretch; gap: 12px; margin-top: 22px; }
  .project-progress-form-footer .project-progress-form-note { flex-basis: 100%; }
  .project-progress-form-footer .button { width: 100%; }
  .project-progress-monthly { padding: 18px; }
}

@media (max-width: 700px) {
  .sidebar { position: static; height: auto; overflow: visible; width: auto; padding: 13px 14px 10px; }
  .brand-block { padding: 0 5px; }
  .nav-list { overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; }
  .nav-list::-webkit-scrollbar { display: none; }
  .nav-item { flex: 0 0 auto; min-width: max-content; white-space: nowrap; }
  .sidebar-bottom { padding-top: 0; }
  .sidebar-bottom .nav-item { min-height: 40px; }
  .nav-icon { display: none; }
  .topbar { padding: 11px 16px; }
  .topbar-context { flex-basis: 100%; overflow: hidden; text-overflow: ellipsis; }
  .topbar-actions { justify-content: flex-start; }
  .page { padding: 23px 16px 48px; }
  .page-heading { margin-bottom: 18px; }
  .page-heading h1 { font-size: 25px; }
  .heading-meta { min-width: 0; margin-top: 12px; padding-left: 11px; }
  .day-toolbar { display: block; padding: 7px; }
  .day-tabs { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  .day-tabs::-webkit-scrollbar { display: none; }
  .day-tabs button { flex: 0 0 auto; white-space: nowrap; }
  .date-control { justify-content: flex-start; margin-top: 8px; flex-wrap: wrap; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat-card:nth-child(2) { border-left: 0; }
  .stat-card:nth-child(3), .stat-card:nth-child(4) { border-top: 0; }
  .stat-card:first-child { border-radius: 5px 0 0 0; }
  .stat-card:nth-child(2) { border-radius: 0 5px 0 0; }
  .stat-card:nth-child(3) { border-radius: 0 0 0 5px; }
  .stat-card:last-child { border-radius: 0 0 5px 0; }
  .table-toolbar { display: block; }
  .project-queue-panel .toolbar-left { flex-wrap: wrap; }
  .table-toolbar { margin: -17px -17px 14px; padding: 10px 12px; }
  .toolbar-right { margin-top: 8px; }
  .search-input { min-width: 0; width: 100%; }
  .data-table-wrap::after { display: block; padding: 8px 12px; color: var(--wx-muted); border-top: 1px solid var(--wx-line); background: #f7f9fb; font-size: 11px; content: "左右滑动查看完整字段"; }
  .workspace-summary { display: block; }
  .workspace-summary-metrics { margin-top: 13px; justify-content: flex-start; overflow-x: auto; }
  .workspace-summary-metrics > div { min-width: 72px; padding-left: 10px; padding-right: 10px; }
}

@media (max-width: 375px) {
  .nav-item { padding-left: 9px; padding-right: 9px; font-size: 12px; }
  .topbar-actions .button { max-width: 100%; }
  .project-preview-row { grid-template-columns: 34px minmax(0, 1fr) 88px; gap: 8px; padding: 14px 12px; }
  .project-preview-mark { width: 30px; height: 30px; }
  .project-preview-avatar { width: 34px; height: 34px; }
  .content-plan-compact { gap: 4px 8px; }
  .project-progress-compact { gap: 4px 8px; }
  .content-plan-grid { grid-template-columns: 1fr 1fr; }
  .project-actual-progress .project-progress-entry { grid-template-columns: 1fr 1fr; }
  .project-actual-progress .project-progress-entry label:first-child { grid-column: 1 / -1; }
  .project-actual-progress .project-progress-entry .button { grid-column: 1 / -1; justify-self: start; }
  .page-heading h1 { font-size: 24px; }
  .stat-card { padding: 14px 12px; }
  .stat-card .stat-number { font-size: 25px; }
}

/* Quality center: treat the page as a review console, not a blank table. */
.quality-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: -3px 0 14px;
  padding: 11px 14px;
  border: 1px solid var(--wx-line);
  border-radius: 6px;
  background: #f0f3f7;
}
.quality-summary-context,
.quality-summary-metrics { display: flex; align-items: center; gap: 10px; }
.quality-summary-context strong { color: var(--wx-ink); font-size: 15px; font-weight: 600; }
.quality-summary-context > span:last-child { color: var(--wx-muted); font-size: 12px; }
.quality-summary-metrics { gap: 0; }
.quality-summary-metrics > div { min-width: 72px; padding: 0 12px; border-left: 1px solid var(--wx-line-strong); }
.quality-summary-metrics strong { display: block; color: var(--wx-ink); font-size: 16px; font-weight: 600; line-height: 1.2; }
.quality-summary-metrics span { display: block; margin-top: 2px; color: var(--wx-muted); font-size: 11px; }
.quality-queue-count,
.quality-panel-count { display: inline-flex; align-items: center; min-height: 24px; padding: 0 8px; border-radius: 4px; color: var(--wx-blue); background: var(--wx-blue-soft); font-size: 11px; font-weight: 500; white-space: nowrap; }
.quality-queue-panel .panel-body { padding-top: 17px; }
.quality-analyze-recent {
  margin-top: 2px;
  padding: 16px 18px 6px;
  border: 1px solid var(--wx-line);
  border-radius: 10px;
  background: #fbfcfe;
}
.quality-analyze-recent > strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--wx-ink);
  font-size: 13px;
  font-weight: 650;
}
.quality-analyze-recent > strong::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--wx-blue);
  box-shadow: 0 0 0 4px var(--wx-blue-soft);
  content: "";
}
.quality-analyze-recent ul {
  gap: 0;
  margin-top: 12px;
  border-top: 1px solid var(--wx-line);
}
.quality-analyze-recent li {
  grid-template-columns: 116px minmax(92px, auto) minmax(0, 1fr);
  min-height: 42px;
  padding: 0 4px;
  border-bottom: 1px solid var(--wx-line);
  transition: background .16s ease;
}
.quality-analyze-recent li:last-child { border-bottom: 0; }
.quality-analyze-recent li:hover { background: #f1f5fb; }
.quality-analyze-recent li > span {
  color: var(--wx-muted);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}
.quality-analyze-recent li > strong {
  display: inline-flex;
  justify-self: start;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  color: #8c5d1b;
  background: #fff3df;
  font-size: 10px;
  font-weight: 650;
  white-space: nowrap;
}
.quality-analyze-recent li > strong.green {
  color: #187357;
  background: #e8f6f1;
}
.quality-analyze-recent li > strong.orange {
  color: #984e27;
  background: #fff0e7;
}
.quality-analyze-recent li > small {
  min-width: 0;
  color: var(--wx-ink);
  font-size: 11px;
  font-weight: 500;
}
.quality-queue-panel { overflow: hidden; }
.quality-queue-panel .panel-head {
  padding-top: 16px;
  padding-bottom: 16px;
  background: linear-gradient(180deg, #fff 0%, #fbfcfe 100%);
}
.quality-queue-panel .panel-body { background: #fbfcfe; }
.quality-queue-panel .table-toolbar {
  margin: -2px 0 14px;
  padding: 10px;
  border: 1px solid var(--wx-line);
  border-radius: 9px;
  background: #fff;
}
.quality-queue-panel .quality-empty {
  min-height: 178px;
  border: 1px dashed var(--wx-line-strong);
  border-radius: 10px;
  background: #fff;
}
.quality-empty { display: flex; min-height: 218px; align-items: center; justify-content: center; gap: 18px; padding: 30px 24px; text-align: left; }
.quality-empty-icon { display: grid; place-items: center; width: 54px; height: 54px; flex: 0 0 54px; border-radius: 14px; color: #6384a9; background: #eef4fb; }
.quality-empty-icon .ui-icon { width: 28px; height: 28px; }
.quality-empty-copy h3 { margin: 0 0 5px; color: var(--wx-ink); font-size: 15px; font-weight: 600; }
.quality-empty-copy p { max-width: 380px; margin: 0; color: var(--wx-muted); font-size: 13px; line-height: 1.6; }
.quality-empty-copy .button { margin-top: 14px; }
.quality-rules-panel .panel-body,
.quality-process-panel .panel-body { padding-top: 10px; }
.quality-rules-panel .qc-rule { padding: 12px 0; }
.quality-rules-panel .qc-rule-category { color: #6d8198; font-size: 11px; }
.quality-rules-panel .qc-rule strong { color: var(--wx-ink); font-size: 13px; font-weight: 500; }
.quality-rules-panel .chip.orange { color: #9a5a18; background: #fff0dc; }
.quality-process-panel .process-item { padding: 13px 0; }
.quality-process-panel .process-no { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px; color: var(--wx-blue); background: var(--wx-blue-soft); font-size: 11px; }
.quality-process-panel .process-item strong { color: var(--wx-ink); font-size: 13px; font-weight: 600; }
.quality-process-panel .process-item span { color: var(--wx-muted); font-size: 12px; line-height: 1.5; }
.quality-process-panel .process-item .chip { align-self: center; }
.quality-table-wrap .quality-table th { background: #f6f8fb; }

/* Ledger-specific text hierarchy: primary identity first, source evidence second. */
.project-table .next-step-cell strong { color: var(--wx-ink); font-size: 14px; font-weight: 600; line-height: 1.5; }
.project-table .next-step-cell small,
.project-table .table-meta { color: var(--wx-muted); font-size: 12px; font-weight: 400; line-height: 1.55; }
.account-table th { white-space: nowrap; }
.account-primary { color: var(--wx-ink); font-size: 14px; font-weight: 600; line-height: 1.45; }
.account-handle { color: var(--wx-blue) !important; font-size: 13px !important; font-weight: 600; line-height: 1.45; }
.account-source { display: block; max-width: 235px; overflow: hidden; color: var(--wx-muted) !important; font-size: 11px !important; font-weight: 400; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.account-project { display: block; color: var(--wx-ink); font-size: 14px; font-weight: 600; line-height: 1.45; }
.account-owner,
.account-hint,
.account-status-note,
.account-verified-source { color: var(--wx-muted) !important; font-size: 12px !important; font-weight: 400; line-height: 1.55; }
.account-hint { color: #71849b !important; }
.account-status-main { min-height: 23px; }
.account-chip-row { display: flex; flex-wrap: wrap; gap: 4px; }
.account-verified-date { display: block; color: var(--wx-ink); font-size: 13px; font-weight: 600; line-height: 1.45; }

/* Account ledger: make each record read like a calm, scannable card while
   keeping the existing table semantics and all account actions unchanged. */
.account-table-wrap {
  padding: 0 10px 8px;
  border: 0;
  background: #f7f9fc;
}
.account-table {
  min-width: 720px;
  border-collapse: separate;
  border-spacing: 0 8px;
  background: transparent;
}
.account-table thead th {
  padding: 8px 13px 6px;
  border-bottom: 0;
  color: #718198;
  background: transparent;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .02em;
}
.account-table thead th:not(:first-child),
.account-table tbody td:not(:first-child) {
  text-align: center;
  vertical-align: middle;
}
.account-table thead th:first-child,
.account-table tbody td:first-child {
  text-align: left;
}
.account-table tbody tr { background: #fff; }
.account-table tbody td {
  padding: 14px 13px;
  border-top: 1px solid #e5eaf1;
  border-bottom: 1px solid #e5eaf1;
  background: #fff;
}
.account-table tbody td:first-child {
  border-left: 1px solid #e5eaf1;
  border-radius: 7px 0 0 7px;
}
.account-table tbody td:last-child {
  border-right: 1px solid #e5eaf1;
  border-radius: 0 7px 7px 0;
}
.account-table tbody tr:hover td { background: #fbfdff; }
.account-identity { display: flex; align-items: center; gap: 11px; min-width: 250px; }
.account-identity-copy { min-width: 0; }
.account-avatar-frame {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  place-items: center;
  overflow: hidden;
  border: 1px solid #dbe4ef;
  border-radius: 50%;
  background: #eef4fb;
  box-shadow: 0 2px 7px rgba(31, 58, 88, .08);
}
.account-avatar { display: block; width: 100%; height: 100%; object-fit: cover; }
.account-avatar-fallback { display: grid; place-items: center; color: #5f7ea2; font-size: 15px; font-weight: 700; }
.account-primary { display: block; }
.account-relation-label { color: var(--wx-muted) !important; }
.account-project-empty { display: block; color: var(--wx-muted); }
.account-table .account-status-main { display: inline-flex; align-items: center; justify-content: center; }
.account-table .account-status-note { max-width: 220px; }
.account-table .account-actions { justify-content: center; }
.account-table .account-actions .button { min-height: 30px; }
.account-table .account-chip-row { min-height: 23px; align-items: center; justify-content: center; }
.account-table .account-verified-date { color: #33445a; }
.account-table .account-verified-source { margin-top: 3px; }
.account-table + * { margin-top: 4px; }
.ledger-empty { display: flex; min-height: 218px; align-items: center; justify-content: center; gap: 18px; padding: 30px 24px; text-align: left; }
.ledger-empty-icon { display: grid; place-items: center; width: 54px; height: 54px; flex: 0 0 54px; border-radius: 14px; color: #6384a9; background: #eef4fb; }
.ledger-empty-icon .ui-icon { width: 28px; height: 28px; }
.ledger-empty-copy h3 { margin: 0 0 5px; color: var(--wx-ink); font-size: 15px; font-weight: 600; }
.ledger-empty-copy p { max-width: 380px; margin: 0; color: var(--wx-muted); font-size: 13px; line-height: 1.6; }
.ledger-next-card { min-height: 148px; padding: 4px 0 2px; }
.ledger-next-kicker { display: block; margin-bottom: 7px; color: var(--wx-blue); font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.ledger-next-card strong { display: block; color: var(--wx-ink); font-size: 16px; font-weight: 600; line-height: 1.45; }
.ledger-next-card p { max-width: 450px; margin: 7px 0 15px; color: var(--wx-muted); font-size: 13px; line-height: 1.6; }
.ledger-support-grid .panel-body { padding-top: 12px; padding-bottom: 16px; }
.ledger-support-grid .process-item { padding: 13px 0; }
.ledger-support-grid .process-item strong { color: var(--wx-ink); font-size: 13px; font-weight: 600; }
.ledger-support-grid .process-item span { color: var(--wx-muted); font-size: 12px; line-height: 1.5; }
.ledger-support-grid .process-item .chip { align-self: center; }

/* Project list keeps the page identity above the work assigned to it. */
.project-table-wrap { border: 0; border-radius: 6px; }
#projectTableRoot .project-table { min-width: 880px; }
.project-table th:nth-child(1), .project-table td:nth-child(1) { width: 36%; }
.project-table th:nth-child(2), .project-table td:nth-child(2) { width: 18%; }
.project-table th:nth-child(3), .project-table td:nth-child(3) { width: 20%; }
.project-table th {
  padding: 12px 16px;
  color: var(--wx-muted);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .01em;
}
.project-table td {
  font-weight: 400;
  padding: 20px 16px;
}
.project-table-identity { display: flex; align-items: flex-start; gap: 12px; }
.project-table-copy { min-width: 0; }
.project-table .task-name {
  color: var(--wx-muted);
  margin-top: 6px;
  font-size: 13px;
  font-weight: 400;
  line-height: 20px;
  letter-spacing: 0;
}
.project-table .project-table-copy .table-meta {
  margin-top: 2px;
  color: var(--wx-muted);
  font-size: 12px;
  line-height: 18px;
  font-variant-numeric: tabular-nums;
}
.project-table .project-source {
  display: block;
  color: var(--wx-ink);
  font-size: 15px;
  font-weight: 600;
  line-height: 22px;
}
.project-table thead th:not(:first-child),
.project-table tbody td:not(:first-child) {
  text-align: center;
  vertical-align: middle;
}
.project-table thead th:first-child,
.project-table tbody td:first-child {
  text-align: left;
  vertical-align: middle;
}
.project-account-preview { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; }
.project-account-avatar { display: inline-grid; width: 36px; height: 36px; flex: 0 0 36px; margin-top: 2px; place-items: center; overflow: hidden; border: 1px solid var(--wx-line); border-radius: 50%; background: #eef4fb; }
.project-account-avatar .account-avatar { width: 100%; height: 100%; }
.project-account-avatar .account-avatar-fallback { display: grid; place-items: center; color: #5f7ea2; font-size: 16px; font-weight: 600; }
.project-account-preview .project-source { margin-top: 0; }
.project-table .project-account-more { margin-top: 0; color: var(--wx-muted); font-size: 12px; }
.project-table .next-step-cell strong {
  display: block;
  color: #253246;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0;
}
.project-table .next-step-cell small {
  display: block;
  margin-top: 3px;
  color: var(--wx-muted);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
}
.project-table td:nth-child(4) > strong {
  color: var(--wx-ink);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}
.project-table td:nth-child(4) > small {
  font-size: 12px;
}
.project-table .project-owner-select {
  min-height: 36px;
  padding: 0 8px;
  border-color: transparent;
  background-color: transparent;
  color: var(--wx-ink);
  font-size: 13px;
  font-weight: 400;
  text-align: center;
}
.project-table .project-owner-select:hover { border-color: var(--wx-line); background-color: #fff; }
.project-table .project-owner-select:focus-visible { border-color: var(--wx-blue); outline: 2px solid var(--wx-blue); outline-offset: 2px; }
.project-table tr:focus-visible { outline: 2px solid var(--wx-blue); outline-offset: -2px; }

.project-table td small { font-weight: 400; }
.project-table td .chip { font-weight: 500; }
.drawer-header > div { min-width: 0; flex: 1; }
.drawer-header .icon-button { flex-shrink: 0; }
.drawer-header h2 { text-wrap: balance; overflow-wrap: anywhere; }

@media (max-width: 700px) {
  .quality-summary { display: block; }
  .quality-summary-metrics { margin-top: 13px; justify-content: flex-start; overflow-x: auto; }
  .quality-summary-metrics > div { min-width: 68px; padding-left: 10px; padding-right: 10px; }
  .quality-analyze-recent { padding-left: 13px; padding-right: 13px; }
  .quality-analyze-recent li { grid-template-columns: 1fr auto; gap: 6px; padding: 8px 4px; }
  .quality-analyze-recent li > small { grid-column: 1 / -1; }
  .quality-empty { min-height: 190px; gap: 13px; padding-left: 15px; padding-right: 15px; }
  .quality-empty-copy p { max-width: 250px; }
  .quality-process-panel .process-item { grid-template-columns: 27px 1fr; }
  .quality-process-panel .process-item .chip { grid-column: 2; justify-self: start; }
  .ledger-empty { min-height: 190px; gap: 13px; padding-left: 15px; padding-right: 15px; }
  .ledger-empty-copy p { max-width: 250px; }
  .ledger-next-card { min-height: 0; }
  .ledger-support-grid .process-item { grid-template-columns: 27px 1fr; }
  .ledger-support-grid .process-item .chip { grid-column: 2; justify-self: start; }
}

/* Final ledger type balance: regular data, selective emphasis. The approved
   account ledger keeps its own hierarchy; all other data tables share this
   calmer baseline. */
body {
  font-weight: 400;
  letter-spacing: 0;
}
.data-table:not(.account-table):not(.project-table) th {
  font-weight: 500;
  letter-spacing: .01em;
}
.data-table:not(.account-table):not(.project-table) td {
  font-weight: 400;
  letter-spacing: 0;
}
.data-table:not(.account-table):not(.project-table) td strong {
  font-weight: 600;
  letter-spacing: 0;
}
.data-table:not(.account-table):not(.project-table) td.muted strong {
  font-weight: 500;
}
.data-table:not(.account-table):not(.project-table) td small {
  font-weight: 400;
  letter-spacing: 0;
}
.data-status-bar strong,
.modal-header h2,
.drawer-header h2,
.drawer-section-title,
.detail-label,
.setting-card strong,
.intake-card strong,
.ledger-chain strong { font-weight: 600; }

/* Member directory: the settings table has a deliberate column rhythm so
   identity, status, workload and actions read as one unit. */
.member-table-wrap { border-radius: 6px; }
.member-table { min-width: 760px; table-layout: fixed; }
.member-table th,
.member-table td { padding: 12px 16px; }
.member-table th { color: var(--wx-muted); font-size: 12px; font-weight: 500; letter-spacing: 0; }
.member-table th:nth-child(1), .member-table td:nth-child(1) { width: 28%; }
.member-table th:nth-child(2), .member-table td:nth-child(2) { width: 14%; text-align: center; }
.member-table th:nth-child(3), .member-table td:nth-child(3) { width: 13%; text-align: center; }
.member-table th:nth-child(4), .member-table td:nth-child(4) { width: 14%; text-align: right; }
.member-table th:nth-child(5), .member-table td:nth-child(5) { width: 14%; text-align: right; }
.member-table th:nth-child(6), .member-table td:nth-child(6) { width: 17%; text-align: right; }
.member-table tbody tr { height: 68px; }
.member-table tbody tr:hover { background: #f7faff; }
.member-person { display: grid; gap: 2px; min-width: 0; }
.member-person strong { overflow: hidden; color: var(--wx-ink); font-size: 14px; font-weight: 600; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; }
.member-person small { display: block; margin-top: 0 !important; line-height: 1.4; }
.member-person .member-id { color: var(--wx-muted); font-size: 12px; font-weight: 400; }
.member-person .member-note { overflow: hidden; color: var(--wx-muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.member-status-cell .chip { min-width: 54px; justify-content: center; font-weight: 500; }
.member-count-cell { white-space: nowrap; }
.member-count { display: inline-flex; align-items: baseline; justify-content: flex-end; gap: 4px; color: var(--wx-ink); font-variant-numeric: tabular-nums; }
.member-count strong { font-size: 14px; font-weight: 600; }
.member-count span { color: var(--wx-muted); font-size: 12px; font-weight: 400; }
.member-actions-cell { white-space: nowrap; }
.member-actions { justify-content: flex-end; gap: 6px; }
.member-actions .button { min-width: 48px; min-height: 32px; padding: 0 10px; border-radius: 5px; font-size: 12px; font-weight: 500; }
.member-edit-button { color: var(--wx-blue); border-color: #c9d8f5; background: #f7faff; }
.member-edit-button:hover { color: #245dc9; border-color: #a8c0ed; background: var(--wx-blue-soft); }
.member-delete-button { color: #68778a; border-color: var(--wx-line); background: #fff; }
.member-delete-button:hover { color: var(--wx-danger, #b94239); border-color: #e6b8b2; background: #fff7f6; }
.project-danger-action { color: #b94239 !important; border-color: #e6b8b2 !important; background: #fff7f6 !important; }
.project-danger-action:hover { color: #9f3129 !important; border-color: #d9948c !important; background: #fff0ee !important; }
.member-table-empty td { padding: 48px 20px; text-align: center; }
.member-table-empty strong,
.member-table-empty span { display: block; }
.member-table-empty strong { color: var(--wx-ink); font-size: 14px; font-weight: 600; }
.member-table-empty span { margin-top: 5px; color: var(--wx-muted); font-size: 13px; }

@media (max-width: 900px) {
  .member-table { min-width: 760px; }
}

/* Logic v19: account relationship and workload controls */
.field-help {
  display: block;
  margin-top: 5px;
  color: var(--wx-muted, #68778a);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.45;
}
.project-account-field { align-self: start; }
.multi-select {
  width: 100%;
  min-height: 96px;
  padding: 7px 9px;
  border: 1px solid var(--wx-line, #d7e0ec);
  border-radius: 6px;
  background: #fff;
  color: var(--wx-ink, #1f2937);
  font: inherit;
  line-height: 1.5;
}
.multi-select:focus {
  outline: none;
  border-color: var(--wx-blue, #2f6fed);
  box-shadow: 0 0 0 3px rgba(47,111,237,.12);
}
.multi-select option { padding: 5px 6px; }
.multi-select option:checked { color: #1f5fd1; background: #eaf1ff linear-gradient(0deg, #eaf1ff, #eaf1ff); }
.multi-select:disabled { color: var(--wx-muted, #68778a); background: #f7f9fc; cursor: not-allowed; }
.workload-cell strong { display: block; color: var(--wx-ink, #1f2937); font-size: 13px; font-weight: 600; line-height: 1.4; }
.workload-cell small { display: block; margin-top: 3px; color: var(--wx-muted, #68778a); font-size: 11px; font-weight: 400; line-height: 1.4; }
.drawer-account-block { display: grid; gap: 8px; }
.drawer-account-select { min-height: 112px; }
.drawer-account-block .button { justify-self: start; margin-top: 2px; }
@media (max-width: 700px) {
  .project-account-select { min-height: 118px; }
  .drawer-account-select { min-height: 128px; }
}

.account-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  width: 100%;
  max-height: 156px;
  overflow: auto;
  padding: 7px;
  border: 1px solid var(--wx-line, #d7e0ec);
  border-radius: 6px;
  background: #fff;
}
.account-picker.is-empty { display: block; background: #f7f9fc; }
.account-picker-empty { display: block; padding: 10px 4px; color: var(--wx-muted, #68778a); font-size: 12px; line-height: 1.45; }
.account-option {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  min-width: 0;
  padding: 7px 8px;
  border: 1px solid transparent;
  border-radius: 5px;
  background: #f8faff;
  cursor: pointer;
}
.account-option:hover { border-color: #c5d7f7; background: #eff5ff; }
.account-option input { flex: 0 0 auto; width: 14px; height: 14px; margin: 2px 0 0; accent-color: var(--wx-blue, #2f6fed); }
.account-option span { display: grid; min-width: 0; gap: 2px; }
.account-option strong { overflow: hidden; color: var(--wx-ink, #1f2937); font-size: 12px; font-weight: 600; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.account-option small { overflow: hidden; color: var(--wx-muted, #68778a); font-size: 11px; font-weight: 400; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.drawer-account-picker { max-height: 196px; grid-template-columns: 1fr; }
@media (max-width: 700px) { .account-picker { grid-template-columns: 1fr; max-height: 190px; } }

/* Keep repeated overview copy compact; form guidance remains visible. */
.page-heading > div > p,
.panel-subtitle,
.overview-status-bar,
.ledger-chain,
.table-footnote,
.toolbar-note,
.workspace-summary-context > span:last-child {
  display: none !important;
}
.page-heading { margin-bottom: 18px; }
.page-heading h1 { margin-bottom: 0; }
.page .panel:has(.ledger-chain),
.page .ledger-support-grid,
.page .quality-process-panel,
.page .panel:has(.intake-row) {
  display: none !important;
}
.page .workspace-summary { margin-bottom: 14px; }
.page .panel-head { min-height: 48px; }
.role-hint { width: 0; overflow: hidden; }
.form-hint { color: var(--wx-muted); line-height: 1.5; }
.form-hint:empty, .modal-note:empty { display: none; }
.form-error { grid-column: 1 / -1; margin: 0; padding: 10px 12px; border: 1px solid #efc5c0; border-radius: 6px; color: #943a34; background: #fff3f1; font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; }

.people-next-grid { grid-template-columns: minmax(0, 1fr); }
.quality-rules-panel { grid-column: 1 / -1; }
.settings-storage-note { margin: 18px 0 0; color: var(--wx-muted); font-size: 12px; line-height: 1.6; }

.account-table .account-status-note { margin:6px auto; white-space:normal; }

#projectForm [hidden] { display: none !important; }
.project-plan-fields { padding: 16px; border: 1px solid #d8e3f5; border-radius: 8px; background: #f8faff; }
.project-plan-targets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
#projectPlanSummary { margin: 12px 0 0; line-height: 1.6; }
.project-optional-fields { border-top: 1px solid #e1e8f2; padding-top: 14px; }
.project-optional-fields summary { cursor: pointer; color: #516580; font-size: 13px; }
.project-optional-fields > .task-form { margin-top: 14px; }
#projectForm .field > .project-field-title { color: inherit; }
.project-field-title b { color: #bc3428; }
@media (max-width: 480px) { .project-plan-targets { grid-template-columns: 1fr; } }

.ledger-pagination { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 2px 0; color: var(--wx-muted); font-size: 12px; }
.ledger-pagination > div { display: flex; align-items: center; gap: 12px; }
.ledger-pagination .button:disabled { opacity: .45; cursor: default; }
#qualityAnalyzeTaskSearch { width: 100%; }
@media (max-width: 560px) { .ledger-pagination { align-items: flex-start; flex-direction: column; } }
