:root {
  --bg: #f7f9fc;
  --panel: #ffffff;
  --surface: #f3f6fb;
  --line: #d7e2f0;
  --line-strong: #c0d0e6;
  --ink: #0f172a;
  --text: #0f172a;
  --muted: #64748b;
  --accent: #0052ff;
  --accent-secondary: #4d7cff;
  --accent-strong: #0046dd;
  --accent-soft: rgba(0, 82, 255, 0.08);
  --accent-softer: rgba(77, 124, 255, 0.08);
  --success: #0f8a62;
  --warn: #c47519;
  --danger: #d14b3d;
  --shadow: 0 16px 36px rgba(15, 23, 42, 0.055);
  --shadow-soft: 0 8px 22px rgba(15, 23, 42, 0.045);
  --shadow-accent: 0 10px 26px rgba(0, 82, 255, 0.15);
  --radius-card: 22px;
  --radius-soft: 16px;
  --radius-pill: 999px;
  --font-body: "Inter", "SF Pro Text", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-display: "Iowan Old Style", "Palatino Linotype", "Source Serif 4", "Noto Serif SC", Georgia, serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", "SF Mono", ui-monospace, monospace;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(0, 82, 255, 0.07), transparent 28%),
    radial-gradient(circle at top right, rgba(77, 124, 255, 0.07), transparent 26%),
    linear-gradient(180deg, #fbfcfe 0%, var(--bg) 100%);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--accent);
  text-decoration: none;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  color: var(--ink);
  letter-spacing: -0.03em;
  font-weight: 700;
}

.shell {
  width: min(1180px, calc(100vw - 72px));
  margin: 0 auto;
  padding: 22px 0 32px;
}

.detail-shell {
  width: min(1120px, calc(100vw - 72px));
}

.system-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 34px;
  margin-bottom: 14px;
}

.system-topbar-actions {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
}

.page-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
  margin-bottom: 18px;
}

.page-header-right {
  display: grid;
  justify-items: end;
  gap: 10px;
  margin-left: auto;
}

.page-customers .page-header,
.page-tasks .page-header {
  align-items: center;
  margin-bottom: 16px;
}

.page-header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.page-header > .badge-group {
  grid-column: 2;
  justify-self: end;
}

.user-account-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 28px;
  max-width: 520px;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid rgba(215, 226, 240, 0.82);
  background: rgba(255, 255, 255, 0.68);
  color: color-mix(in srgb, var(--muted) 86%, var(--ink));
  font-size: 12px;
  line-height: 1;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.user-account-name {
  min-width: 0;
  max-width: 156px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 800;
  color: color-mix(in srgb, var(--ink) 72%, var(--muted));
}

.user-account-logout {
  min-height: 20px;
  padding: 0 0 0 8px;
  border: 0;
  border-left: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 0;
  background: transparent;
  color: color-mix(in srgb, var(--muted) 88%, var(--accent));
  box-shadow: none;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
}

.user-account-manage {
  --user-account-link-color: color-mix(in srgb, var(--muted) 88%, var(--accent));
  min-height: 20px;
  padding: 0 0 0 8px;
  border-left: 1px solid rgba(148, 163, 184, 0.28);
  color: var(--user-account-link-color);
  font-size: 12px;
  font-weight: 800;
  line-height: 20px;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.16s ease;
}

.user-account-work-stats {
  --user-account-link-color: color-mix(in srgb, var(--muted) 88%, var(--accent));
  min-height: 20px;
  padding: 0 0 0 8px;
  border-left: 1px solid rgba(148, 163, 184, 0.28);
  color: var(--user-account-link-color);
  font-size: 12px;
  font-weight: 800;
  line-height: 20px;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.16s ease;
}

.user-account-maintenance {
  --user-account-link-color: color-mix(in srgb, var(--muted) 88%, var(--accent));
  min-height: 20px;
  padding: 0 0 0 8px;
  border-left: 1px solid rgba(148, 163, 184, 0.28);
  color: var(--user-account-link-color);
  font-size: 12px;
  font-weight: 800;
  line-height: 20px;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.16s ease;
}

.user-account-help {
  --user-account-link-color: var(--ink);
  min-height: 20px;
  padding: 0 0 0 8px;
  border-left: 1px solid rgba(148, 163, 184, 0.28);
  color: var(--user-account-link-color);
  font-size: 12px;
  font-weight: 800;
  line-height: 20px;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.16s ease;
}

.user-account-manage:link,
.user-account-manage:visited,
.user-account-manage:active,
.user-account-work-stats:link,
.user-account-work-stats:visited,
.user-account-work-stats:active,
.user-account-maintenance:link,
.user-account-maintenance:visited,
.user-account-maintenance:active,
.user-account-help:link,
.user-account-help:visited,
.user-account-help:active {
  color: var(--user-account-link-color);
  text-decoration: none;
}

.user-account-manage:hover,
.user-account-work-stats:hover,
.user-account-maintenance:hover,
.user-account-help:hover,
.user-account-manage:focus-visible,
.user-account-work-stats:focus-visible,
.user-account-maintenance:focus-visible,
.user-account-help:focus-visible {
  color: var(--accent-strong);
  text-decoration: none;
  outline: none;
}

.user-account-logout:hover {
  color: var(--accent-strong);
  background: transparent;
  box-shadow: none;
}

.page-login {
  min-height: 100vh;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  align-items: center;
  justify-items: center;
}

.login-shell {
  width: min(520px, calc(100vw - 32px));
  padding: 28px 0;
}

.app-version-footer {
  width: min(1180px, calc(100vw - 72px));
  margin: 0 auto 22px;
  padding: 4px 0 8px;
  color: color-mix(in srgb, var(--muted) 74%, #ffffff);
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}

.page-login .app-version-footer {
  width: min(520px, calc(100vw - 32px));
  margin-bottom: 18px;
}

.login-card {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(215, 226, 240, 0.94);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
  padding: 26px;
}

.login-brand {
  margin-bottom: 16px;
}

.login-brand h1 {
  margin: 0;
  font-size: clamp(36px, 4.5vw, 46px);
  line-height: 1;
}

.login-form {
  grid-template-columns: 1fr;
}

.login-actions {
  justify-content: space-between;
}

.login-helper {
  margin-top: 18px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
}

.detail-page-header {
  display: block;
}

.detail-header-stack {
  display: grid;
  gap: 12px;
}

.detail-system-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 34px;
}

.detail-header-main {
  padding: 20px 22px;
  border-radius: var(--radius-card);
  border: 1px solid rgba(215, 226, 240, 0.92);
  background:
    radial-gradient(circle at top right, rgba(77, 124, 255, 0.08), transparent 34%),
    linear-gradient(140deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 255, 0.95));
  box-shadow: var(--shadow);
}

.detail-header-actions {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
}

.detail-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, auto);
  gap: 18px;
  align-items: end;
}

.detail-title-row h1 {
  min-width: 0;
  word-break: break-word;
}

.detail-header-meta {
  display: grid;
  gap: 4px;
  min-width: 180px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(0, 82, 255, 0.12);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

.detail-header-meta-label {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-family: var(--font-mono);
}

.detail-header-meta strong {
  color: var(--accent-strong);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.15;
}

.back-link-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  min-height: 40px;
  padding: 8px 13px;
  border-radius: 14px;
  border: 1px solid rgba(0, 82, 255, 0.12);
  background: rgba(255, 255, 255, 0.9);
  color: var(--accent-strong);
  font-size: 14px;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, border-color 180ms ease;
}

.back-link-button:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.98);
  border-color: rgba(0, 82, 255, 0.22);
  box-shadow: var(--shadow-accent);
}

.page-header h1 {
  margin: 0;
  font-size: clamp(34px, 3.7vw, 48px);
  line-height: 0.98;
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-family: var(--font-mono);
}

.subtle {
  color: var(--muted);
}

.badge-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(0, 82, 255, 0.12);
  background: linear-gradient(180deg, rgba(0, 82, 255, 0.08), rgba(255, 255, 255, 0.92));
  color: var(--accent-strong);
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.badge.muted {
  background: rgba(255, 255, 255, 0.84);
  border-color: rgba(192, 208, 230, 0.8);
  color: var(--muted);
}

.panel {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(215, 226, 240, 0.9);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
  padding: 16px 16px 18px;
  position: relative;
  overflow: hidden;
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.96), rgba(77, 124, 255, 0.16), rgba(255, 255, 255, 0.96));
  pointer-events: none;
}

.panel h2 {
  margin: 0 0 12px;
  font-size: 20px;
}

.panel + .panel {
  margin-top: 16px;
}

.detail-grid > .panel + .panel,
.detail-hero-grid > .panel + .panel {
  margin-top: 0;
}

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

.trend-panel-header {
  align-items: flex-start;
}

.trend-subtitle {
  margin: 4px 0 0;
}

.trend-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.trend-tabs {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border-radius: var(--radius-pill);
  background: rgba(0, 82, 255, 0.06);
  border: 1px solid rgba(0, 82, 255, 0.12);
}

.trend-tab {
  background: transparent;
  color: var(--muted);
  border-radius: var(--radius-pill);
  padding: 8px 14px;
  font-weight: 700;
}

.trend-tab.active {
  background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
  color: #fff;
  box-shadow: var(--shadow-accent);
}

.trend-judgement {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.86);
  padding: 14px 16px;
  margin-bottom: 14px;
}

.trend-judgement.neutral {
  background: rgba(255, 255, 255, 0.78);
}

.trend-judgement.warn {
  background: rgba(196, 117, 25, 0.08);
  border-color: rgba(196, 117, 25, 0.2);
}

.trend-judgement.good {
  background: rgba(15, 138, 98, 0.08);
  border-color: rgba(15, 138, 98, 0.18);
}

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

.trend-judgement-label {
  font-size: 18px;
  font-weight: 700;
}

.trend-judgement-tone {
  color: var(--muted);
  font-size: 13px;
}

.trend-judgement-summary {
  margin: 0;
  line-height: 1.6;
}

.trend-chart-card {
  border-radius: var(--radius-soft);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(215, 226, 240, 0.86);
  padding: 14px 14px 10px;
  margin-bottom: 14px;
}

.trend-chart-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.trend-chart-wrap {
  position: relative;
  min-height: 320px;
}

.trend-chart {
  width: 100%;
  height: 320px;
  display: block;
}

.trend-chart-empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.trend-grid-row line {
  stroke: rgba(148, 163, 184, 0.22);
  stroke-dasharray: 4 6;
}

.trend-grid-row text,
.trend-axis-label {
  fill: var(--muted);
  font-size: 12px;
}

.trend-axis {
  stroke: rgba(148, 163, 184, 0.36);
  stroke-width: 1;
}

.trend-area {
  fill: rgba(0, 82, 255, 0.08);
}

.trend-line {
  fill: none;
  stroke: var(--accent);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.trend-point {
  fill: var(--accent);
  stroke: white;
  stroke-width: 2;
}

.trend-point.zero {
  fill: #f0a23d;
}

.filter-panel {
  margin-bottom: 14px;
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.filter-actions,
.form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}

label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

input,
select,
textarea,
button {
  font: inherit;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(192, 208, 230, 0.92);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  padding: 9px 12px;
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(0, 82, 255, 0.38);
  box-shadow:
    0 0 0 4px rgba(0, 82, 255, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
  background: rgba(255, 255, 255, 0.99);
}

button {
  border: 0;
  min-height: 40px;
  border-radius: 14px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 700;
  transition: transform 180ms ease, opacity 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
}

button:hover {
  transform: translateY(-1px);
}

button.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
  color: white;
  box-shadow: var(--shadow-accent);
}

button.primary:hover {
  box-shadow: 0 14px 32px rgba(0, 82, 255, 0.2);
}

button.secondary {
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  border: 1px solid rgba(192, 208, 230, 0.94);
  box-shadow: var(--shadow-soft);
}

button.secondary:hover {
  border-color: rgba(0, 82, 255, 0.18);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 920px;
}

thead th {
  background: rgba(245, 248, 255, 0.86);
}

th,
td {
  padding: 13px 12px;
  border-bottom: 1px solid rgba(215, 226, 240, 0.82);
  text-align: left;
  font-size: 14px;
  vertical-align: middle;
}

th {
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.02em;
}

.table-sort-button {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 5px;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  text-align: left;
  cursor: pointer;
}

.table-sort-button:hover {
  transform: none;
  color: var(--accent-strong);
}

.table-sort-button .sort-indicator {
  color: rgba(100, 116, 139, 0.5);
  font-size: 11px;
  line-height: 1;
  transition: color 160ms ease;
}

.table-sort-button.active {
  color: var(--accent-strong);
}

.table-sort-button.active .sort-indicator {
  color: var(--accent-strong);
}

.page-customers .table-panel table,
.page-tasks .table-panel table {
  table-layout: fixed;
}

.page-customers .table-panel table {
  min-width: 1040px;
}

.page-tasks .table-panel table {
  min-width: 1080px;
}

.page-customers .table-panel th,
.page-customers .table-panel td,
.page-tasks .table-panel th,
.page-tasks .table-panel td {
  text-align: center;
}

.page-customers .table-panel th,
.page-customers .table-panel td,
.page-tasks .table-panel th,
.page-tasks .table-panel td,
.page-customers .table-sort-button,
.page-tasks .table-sort-button {
  white-space: nowrap;
}

.page-customers .table-panel th:first-child,
.page-customers .table-panel td:first-child,
.page-tasks .table-panel th:first-child,
.page-tasks .table-panel td:first-child {
  text-align: left;
}

.page-customers .table-panel .numeric,
.page-tasks .table-panel .numeric {
  text-align: center;
}

.page-customers .table-sort-button,
.page-tasks .table-sort-button {
  justify-content: center;
}

.page-customers .table-panel th:nth-child(1),
.page-customers .table-panel td:nth-child(1) {
  width: 176px;
}

.page-customers .table-panel th:nth-child(2),
.page-customers .table-panel td:nth-child(2) {
  width: 96px;
}

.page-customers .table-panel th:nth-child(3),
.page-customers .table-panel td:nth-child(3) {
  width: 122px;
}

.page-customers .table-panel th:nth-child(4),
.page-customers .table-panel td:nth-child(4) {
  width: 68px;
}

.page-customers .table-panel th:nth-child(5),
.page-customers .table-panel td:nth-child(5) {
  width: 92px;
}

.page-customers .table-panel th:nth-child(6),
.page-customers .table-panel td:nth-child(6) {
  width: 105px;
}

.page-customers .table-panel th:nth-child(7),
.page-customers .table-panel td:nth-child(7) {
  width: 116px;
}

.page-customers .table-panel th:nth-child(8),
.page-customers .table-panel td:nth-child(8) {
  width: 110px;
}

.page-customers .table-panel th:nth-child(9),
.page-customers .table-panel td:nth-child(9) {
  width: 78px;
}

.page-customers .table-panel th:nth-child(10),
.page-customers .table-panel td:nth-child(10) {
  width: 77px;
}

.page-tasks .table-panel th:nth-child(1),
.page-tasks .table-panel td:nth-child(1) {
  width: 260px;
}

.page-tasks .table-panel th:nth-child(2),
.page-tasks .table-panel td:nth-child(2),
.page-tasks .table-panel th:nth-child(3),
.page-tasks .table-panel td:nth-child(3),
.page-tasks .table-panel th:nth-child(4),
.page-tasks .table-panel td:nth-child(4) {
  width: 150px;
}

.page-tasks .table-panel th:nth-child(5),
.page-tasks .table-panel td:nth-child(5) {
  width: 110px;
}

.page-tasks .table-panel th:nth-child(6),
.page-tasks .table-panel td:nth-child(6) {
  width: 120px;
}

.page-tasks .table-panel th:nth-child(7),
.page-tasks .table-panel td:nth-child(7) {
  width: 140px;
}

tbody tr:hover {
  background: rgba(0, 82, 255, 0.04);
}

tbody tr.focus-row {
  animation: row-focus-pulse 2.4s ease;
}

tbody tr.focus-row td {
  background: rgba(0, 82, 255, 0.08);
}

.numeric {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.numeric-strong {
  color: var(--accent-strong);
  font-weight: 700;
}

.empty {
  text-align: center;
  color: var(--muted);
}

.pagination {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}

.pagination-page-size {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  margin: 0 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.pagination-page-size select {
  width: 94px;
  min-height: 40px;
  padding: 8px 12px;
  border-radius: 14px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}

.detail-hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 18px;
  margin-bottom: 18px;
  align-items: stretch;
}

.detail-action-grid {
  align-items: stretch;
}

.detail-action-grid-single {
  grid-template-columns: 1fr;
}

.detail-log-grid {
  align-items: start;
}

.detail-hero-grid > .panel,
.detail-action-grid > .panel {
  height: 100%;
}

.detail-log-grid {
  grid-template-columns: 1fr;
}

.kv-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
  margin: 0;
}

.kv-grid dt {
  color: var(--muted);
  font-size: 13px;
}

.kv-grid dd {
  margin: 0;
  font-size: 15px;
}

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

.identity-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 14px;
}

.identity-panel-head h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.15;
}

.identity-panel-head-simple {
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(215, 226, 240, 0.8);
  margin-bottom: 18px;
}

.identity-status-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: var(--radius-pill);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid rgba(215, 226, 240, 0.82);
  background: rgba(255, 255, 255, 0.88);
  color: var(--muted);
}

.status-pill.good {
  background: rgba(47, 125, 83, 0.12);
  color: var(--success);
  border-color: rgba(47, 125, 83, 0.2);
}

.status-pill.warn {
  background: rgba(196, 117, 25, 0.12);
  color: var(--warn);
  border-color: rgba(196, 117, 25, 0.18);
}

.status-pill.accent {
  background: rgba(0, 82, 255, 0.1);
  color: var(--accent-strong);
  border-color: rgba(0, 82, 255, 0.18);
}

.status-pill.neutral {
  background: rgba(77, 124, 255, 0.12);
  color: #2f63df;
  border-color: rgba(77, 124, 255, 0.18);
}

.status-pill.muted {
  background: rgba(255, 255, 255, 0.82);
  color: var(--muted);
}

.core-contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.core-info-card {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.86);
  padding: 13px 14px;
  min-height: 86px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: var(--shadow-soft);
}

.core-info-card.wide {
  grid-column: 1 / -1;
  min-height: auto;
}

.core-info-label {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.core-info-value {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
  word-break: break-word;
}

.core-info-value.emphasis {
  color: var(--accent-strong);
}

.detail-group-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.detail-group-grid-tight {
  margin-top: 4px;
  grid-template-columns: 1fr;
  gap: 16px;
}

.info-group {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.82);
  padding: 13px 14px;
  box-shadow: var(--shadow-soft);
}

.info-group h3 {
  margin: 0 0 10px;
  font-size: 15px;
  color: var(--ink);
}

.compact-kv {
  display: grid;
  gap: 10px 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
}

.compact-kv-item {
  min-width: 0;
}

.compact-kv dt {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 4px;
}

.compact-kv dd {
  margin: 0;
  line-height: 1.5;
  word-break: break-word;
}

.compact-kv dd.value-strong {
  font-weight: 700;
  color: var(--accent-strong);
}

.identity-detail-group {
  padding: 15px 16px;
  background: rgba(255, 255, 255, 0.82);
}

.identity-detail-group h3 {
  margin-bottom: 12px;
}

.identity-contact-group {
  margin-bottom: 16px;
}

.identity-contact-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin-bottom: 14px;
}

.identity-contact-head h3 {
  margin-bottom: 4px;
}

.identity-contact-head .subtle {
  margin: 0;
}

.contact-module-edit-button {
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.contact-inline-list {
  display: grid;
  gap: 12px;
}

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

.contact-summary-card {
  min-width: 0;
  display: grid;
  gap: 7px;
  padding: 13px 14px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 17px;
  background:
    radial-gradient(circle at top right, rgba(0, 82, 255, 0.05), transparent 32%),
    rgba(255, 255, 255, 0.82);
}

.contact-summary-card.wide {
  grid-column: 1 / -1;
}

.contact-summary-label {
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.contact-summary-value {
  min-height: 24px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.45;
  word-break: break-word;
}

.contact-summary-value.empty {
  color: color-mix(in srgb, var(--muted) 70%, transparent);
  font-weight: 700;
}

.contact-editor-form {
  display: grid;
  gap: 14px;
}

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

.contact-editor-field {
  display: grid;
  gap: 7px;
  min-width: 0;
  margin: 0;
}

.contact-editor-field.wide {
  grid-column: 1 / -1;
}

.contact-editor-field > span {
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
}

.contact-editor-field small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
}

.contact-editor-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding-top: 2px;
}

.contact-editor-actions button {
  min-width: 86px;
}

.contact-inline-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  padding: 9px 0;
  border-bottom: 1px dashed rgba(215, 226, 240, 0.92);
}

.contact-inline-row:last-child {
  border-bottom: none;
  padding-bottom: 2px;
}

.contact-inline-row.wide {
  align-items: flex-start;
}

.contact-inline-row-main {
  min-width: 0;
  display: grid;
  gap: 4px;
  flex: 1;
}

.contact-inline-row-label {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.contact-inline-row-value {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  word-break: break-word;
}

.contact-inline-row-value.empty {
  color: var(--muted);
}

.contact-inline-edit-button {
  min-width: 68px;
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 12px;
  font-size: 13px;
  flex-shrink: 0;
}

.contact-inline-row-editing {
  align-items: flex-start;
  padding: 12px 0;
}

.contact-inline-row-editor {
  display: grid;
  gap: 8px;
}

.contact-inline-editor-control {
  min-height: 44px;
  width: min(420px, 100%);
}

.contact-inline-editor-textarea {
  min-height: 96px;
  resize: vertical;
}

.contact-inline-editor-hint {
  margin: -2px 0 0;
}

.contact-inline-editor-status {
  min-height: 18px;
  font-size: 12px;
  line-height: 1.45;
}

.contact-inline-action-button {
  align-self: center;
}

.contact-inline-row-editing .contact-inline-action-button {
  min-width: 88px;
  min-height: 40px;
  padding: 8px 14px;
}

.contact-inline-row.wide .contact-inline-action-button,
.contact-inline-row-editing.wide .contact-inline-action-button {
  align-self: flex-start;
  margin-top: 18px;
}

.identity-compact-kv {
  gap: 14px 18px;
  align-content: start;
}

.identity-compact-kv .compact-kv-item {
  padding: 8px 0 10px;
  border-bottom: 1px dashed rgba(215, 226, 240, 0.92);
}

.identity-compact-kv dt {
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.identity-compact-kv dd {
  font-size: 15px;
  line-height: 1.65;
}

.identity-compact-kv dd.value-strong {
  font-size: 16px;
}

.analysis-subtitle {
  margin: 6px 0 0;
}

.analysis-status-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.analysis-status-item {
  min-width: 0;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.74);
  padding: 12px 13px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.04);
}

.analysis-status-item span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
}

.analysis-status-item strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.25;
}

.analysis-status-item.good {
  border-color: rgba(47, 125, 83, 0.2);
  background: rgba(47, 125, 83, 0.08);
}

.analysis-status-item.warn {
  border-color: rgba(196, 117, 25, 0.2);
  background: rgba(196, 117, 25, 0.08);
}

.analysis-status-item.accent,
.analysis-status-item.neutral {
  border-color: rgba(0, 82, 255, 0.16);
  background: rgba(0, 82, 255, 0.06);
}

.analysis-status-item.muted {
  background: rgba(248, 251, 255, 0.72);
}

.analysis-summary-card,
.analysis-detail-card {
  border-radius: 20px;
  border: 1px solid rgba(215, 226, 240, 0.9);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.045);
}

.analysis-summary-card {
  padding: 16px;
  margin-bottom: 12px;
}

.analysis-section-title {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.analysis-summary-main {
  margin: 0;
  color: var(--ink);
  font-size: 19px;
  font-weight: 900;
  line-height: 1.45;
}

.analysis-summary-sub {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.analysis-detail-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.analysis-detail-card {
  padding: 16px;
}

.analysis-compact-kv {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px 18px;
}

.analysis-card-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.analysis-spotlight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.analysis-spotlight-card {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.82);
  background: rgba(255, 255, 255, 0.84);
  padding: 13px 14px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  box-shadow: var(--shadow-soft);
}

.analysis-spotlight-card.wide {
  grid-column: 1 / -1;
}

.analysis-spotlight-card.warn {
  background: rgba(196, 117, 25, 0.08);
  border-color: rgba(196, 117, 25, 0.18);
}

.analysis-spotlight-card.good {
  background: rgba(47, 125, 83, 0.1);
  border-color: rgba(47, 125, 83, 0.18);
}

.analysis-spotlight-card.accent {
  background: rgba(0, 82, 255, 0.08);
  border-color: rgba(0, 82, 255, 0.16);
}

.analysis-spotlight-card.neutral {
  background: rgba(77, 124, 255, 0.07);
  border-color: rgba(77, 124, 255, 0.14);
}

.analysis-spotlight-card.muted {
  background: rgba(255, 255, 255, 0.78);
}

.analysis-spotlight-label {
  font-size: 12px;
  color: var(--muted);
}

.analysis-spotlight-value {
  font-size: 18px;
  line-height: 1.25;
}

.analysis-spotlight-value.numeric-value {
  font-variant-numeric: tabular-nums;
}

.analysis-spotlight-hint {
  margin: 0;
  line-height: 1.5;
  color: var(--muted);
  font-size: 13px;
}

.analysis-emphasis-card {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.9);
  background: linear-gradient(180deg, rgba(0, 82, 255, 0.08), rgba(255, 255, 255, 0.88));
  padding: 16px;
  margin-bottom: 14px;
}

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

.analysis-emphasis-title {
  font-size: 14px;
  color: var(--accent-strong);
  font-weight: 700;
}

.analysis-emphasis-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.86);
  color: var(--muted);
}

.analysis-emphasis-badge.warn {
  background: rgba(196, 117, 25, 0.14);
  color: var(--warn);
}

.analysis-emphasis-badge.good {
  background: rgba(15, 138, 98, 0.14);
  color: var(--success);
}

.analysis-emphasis-badge.neutral {
  background: rgba(77, 124, 255, 0.12);
  color: #2f63df;
}

.analysis-emphasis-main {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.5;
}

.analysis-emphasis-subtle {
  margin: 0;
  line-height: 1.6;
  color: var(--muted);
}

.form-panel-note {
  margin: 0 0 14px;
  line-height: 1.6;
}

.form-status.error {
  color: #b23a2c;
}

.form-status.success {
  color: #08745f;
  font-weight: 700;
}

.inline-form-hint {
  margin: -2px 0 0;
  line-height: 1.6;
  padding: 0 2px;
}

button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}

@keyframes row-focus-pulse {
  0% {
    box-shadow: inset 0 0 0 0 rgba(0, 82, 255, 0.18);
  }
  35% {
    box-shadow: inset 0 0 0 999px rgba(0, 82, 255, 0.09);
  }
  100% {
    box-shadow: inset 0 0 0 0 rgba(0, 82, 255, 0);
  }
}

.wide {
  grid-column: 1 / -1;
}

.risk-pill {
  display: inline-flex;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(196, 117, 25, 0.12);
  color: var(--warn);
}

.ok-pill {
  display: inline-flex;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(47, 125, 83, 0.14);
  color: var(--success);
}

.info-pill {
  display: inline-flex;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(77, 124, 255, 0.12);
  color: #2f63df;
}

.followup-cell {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  min-width: 124px;
}

.followup-cell .risk-pill,
.followup-cell .info-pill,
.followup-cell .ok-pill {
  min-height: 34px;
  padding: 0 12px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.note-trigger,
.note-popover-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.94);
  color: var(--accent-strong);
  border: 1px solid rgba(0, 82, 255, 0.14);
  min-height: 34px;
  padding: 0 12px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  box-shadow: var(--shadow-soft);
}

.note-trigger:hover,
.note-popover-close:hover {
  border-color: rgba(0, 82, 255, 0.22);
  background: rgba(247, 250, 255, 0.98);
}

.note-popover {
  position: absolute;
  z-index: 40;
  width: min(360px, calc(100vw - 40px));
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.94);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 26px 52px rgba(15, 23, 42, 0.14);
  padding: 14px;
}

.note-popover.hidden {
  display: none;
}

.note-popover-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.note-popover-body {
  display: grid;
  gap: 10px;
}

.note-item {
  border-radius: 16px;
  padding: 10px 12px;
  background: rgba(247, 250, 255, 0.88);
  border: 1px solid rgba(215, 226, 240, 0.86);
}

.note-item-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 6px;
}

.note-item-progress {
  font-weight: 700;
  margin-bottom: 6px;
}

.note-item-remark {
  line-height: 1.5;
  color: var(--ink);
}

.note-empty-text {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 2px;
  color: color-mix(in srgb, var(--muted) 82%, white);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.log-note-detail {
  max-width: 360px;
  color: var(--ink);
  line-height: 1.55;
}

.log-note-detail summary {
  display: inline;
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
  list-style: none;
}

.log-note-detail summary::-webkit-details-marker {
  display: none;
}

.log-note-detail summary::after {
  content: " 展开";
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
}

.log-note-detail[open] summary::after {
  content: " 收起";
}

.log-note-detail p {
  margin: 8px 0 0;
  padding: 9px 10px;
  border-radius: 12px;
  border: 1px solid rgba(215, 226, 240, 0.9);
  background: rgba(247, 250, 255, 0.82);
  color: var(--ink);
  white-space: pre-wrap;
  word-break: break-word;
}

.followup-current-card {
  border-radius: 12px;
  background: rgba(247, 250, 255, 0.68);
  border: 1px solid rgba(215, 226, 240, 0.72);
  padding: 9px 11px;
}

.followup-workbench-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
  align-items: start;
}

.task-empty-state {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(247, 250, 255, 0.88);
  padding: 14px 16px;
  box-shadow: var(--shadow-soft);
}

.task-empty-state strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
  color: var(--ink);
}

.task-empty-state p {
  margin: 0;
  line-height: 1.55;
}

.followup-form-card {
  padding: 0;
  border-radius: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.detail-contact-log-panel {
  margin-top: -4px;
}

.operation-log-table th:nth-child(1),
.operation-log-table td:nth-child(1),
.operation-log-table th:nth-child(2),
.operation-log-table td:nth-child(2),
.operation-log-table th:nth-child(3),
.operation-log-table td:nth-child(3) {
  white-space: nowrap;
}

.operation-log-table td:last-child {
  color: var(--muted);
  line-height: 1.5;
}

.followup-current-line {
  margin: 0 0 8px;
}

.followup-current-line:last-child {
  margin-bottom: 0;
}

.zero-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(196, 117, 25, 0.12);
  color: var(--warn);
}

.hidden {
  display: none !important;
}

.task-workspace-grid {
  align-items: start;
}

.task-panel-empty {
  padding: 24px 0;
}

.task-panel-body {
  display: grid;
  gap: 16px;
}

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

.task-summary-card {
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.86);
  padding: 12px 14px;
  display: grid;
  gap: 6px;
  box-shadow: var(--shadow-soft);
}

.task-summary-card.wide {
  grid-column: 1 / -1;
}

.task-summary-label {
  font-size: 12px;
  color: var(--muted);
}

.task-summary-value {
  line-height: 1.55;
  font-size: 15px;
  word-break: break-word;
}

.task-link-row {
  display: flex;
  justify-content: flex-start;
}

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

.task-owner-actions {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.task-row-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  width: 112px;
}

.task-row-actions > .secondary-link-button,
.task-row-actions > button.secondary,
.task-row-actions > .table-action-link {
  width: 100%;
  min-width: 112px;
  min-height: 40px;
  padding: 0 14px;
  justify-content: center;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

.page-customers .table-panel tbody td,
.page-tasks .table-panel tbody td {
  padding-top: 18px;
  padding-bottom: 18px;
}

.page-customers .table-panel th,
.page-customers .table-panel td {
  padding-left: 8px;
  padding-right: 8px;
}

.page-customers .table-panel tbody td {
  vertical-align: middle;
}

.page-customers .table-panel tbody td:first-child {
  font-weight: 700;
  color: var(--ink);
}

.page-customers .table-panel tbody td:nth-child(3),
.page-customers .table-panel tbody td:last-child {
  vertical-align: middle;
}

.page-customers .followup-cell {
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.page-customers .followup-cell .risk-pill,
.page-customers .followup-cell .info-pill,
.page-customers .followup-cell .ok-pill,
.page-customers .note-trigger {
  min-width: 92px;
}

.page-customers .note-trigger {
  justify-content: center;
}

.page-customers .table-panel tbody td:last-child {
  width: 77px;
}

.page-customers .table-action-link {
  min-width: 70px;
  padding-left: 10px;
  padding-right: 10px;
}

.customer-name-cell {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.customer-name-text,
.task-name-link {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.customer-name-text {
  display: block;
  color: var(--ink);
  font-weight: 800;
  line-height: 1.35;
}

.customer-name-meta {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.page-tasks .table-panel tbody td {
  vertical-align: middle;
}

.page-tasks .task-name-cell,
.page-tasks .task-type-cell {
  gap: 8px;
}

.page-tasks .task-type-cell {
  justify-items: center;
}

.page-tasks .task-name-link {
  display: block;
  line-height: 1.35;
}

.page-tasks .task-name-meta {
  color: var(--muted);
  line-height: 1.35;
}

.page-tasks .task-row-actions {
  align-items: stretch;
  width: 120px;
  gap: 12px;
  margin-inline: auto;
}

.page-tasks .task-row-actions > .secondary-link-button,
.page-tasks .task-row-actions > button.secondary,
.page-tasks .task-row-actions > .table-action-link {
  min-width: 120px;
}

.home-shell {
  width: min(1160px, calc(100vw - 84px));
  padding-top: 22px;
  padding-bottom: 34px;
}

.home-hero {
  position: relative;
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
  padding: 16px 18px;
  border-radius: var(--radius-card);
  border: 1px solid rgba(215, 226, 240, 0.9);
  background:
    radial-gradient(circle at right top, rgba(77, 124, 255, 0.1), transparent 34%),
    radial-gradient(circle at left bottom, rgba(0, 82, 255, 0.05), transparent 26%),
    linear-gradient(140deg, rgba(255, 255, 255, 0.98), rgba(244, 248, 255, 0.95));
  box-shadow:
    0 18px 42px rgba(15, 23, 42, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
  overflow: hidden;
}

.home-hero::after {
  content: "";
  position: absolute;
  inset: auto 24px 0 auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 82, 255, 0.12), transparent 68%);
  pointer-events: none;
}

.home-hero-topline {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.home-hero-main {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 4px;
  max-width: 520px;
}

.home-hero-utility {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: flex-end;
  margin-left: auto;
}

.home-hero-status-row {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: flex-end;
}

.home-hero-main h1 {
  margin: 0;
  font-size: clamp(32px, 3.4vw, 42px);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.home-hero-subtitle {
  margin: 0;
  color: var(--ink);
  font-size: 16px;
  font-weight: 600;
}

.home-hero-tags {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(148px, 1fr));
  gap: 9px;
}

.home-status-tag {
  min-width: 0;
  display: grid;
  align-content: start;
  min-height: 82px;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 249, 255, 0.92));
  box-shadow: var(--shadow-soft);
}

.home-status-tag span {
  font-size: 11px;
  line-height: 1.25;
  color: var(--muted);
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-status-tag strong {
  font-size: 17px;
  line-height: 1.15;
  color: var(--accent-strong);
}

.home-workbench-grid {
  display: grid;
  grid-template-columns: 1.06fr 0.94fr;
  gap: 12px;
  margin-bottom: 12px;
}

.home-workbench-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-radius: var(--radius-card);
  border: 1px solid rgba(215, 226, 240, 0.92);
  box-shadow:
    0 18px 40px rgba(15, 23, 42, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
  padding: 16px;
}

.home-workbench-card-primary {
  background:
    radial-gradient(circle at top right, rgba(0, 82, 255, 0.1), transparent 30%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(243, 248, 255, 0.95));
  border-color: rgba(77, 124, 255, 0.22);
  box-shadow:
    0 26px 54px rgba(0, 82, 255, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.home-workbench-card-secondary {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 248, 253, 0.95));
}

.home-workbench-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.home-workbench-head h2 {
  margin: 0;
  font-size: 22px;
}

.home-workbench-summary {
  margin: -2px 0 0;
  min-height: 0;
  line-height: 1.45;
  color: var(--muted);
  font-size: 12px;
  max-width: 30ch;
}

.home-workbench-main-metric {
  display: grid;
  gap: 4px;
  min-height: 82px;
  align-content: center;
  padding: 13px 14px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
}

.home-workbench-card-primary .home-workbench-main-metric {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(241, 247, 255, 0.92));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    var(--shadow-soft);
}

.home-workbench-main-metric strong {
  font-size: 38px;
  line-height: 0.95;
  letter-spacing: -0.05em;
  color: var(--accent-strong);
}

.home-workbench-main-metric span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.home-workbench-submetrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.home-workbench-submetrics article,
.task-summary-mini {
  border-radius: 16px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.86);
  min-height: 66px;
  align-content: center;
  padding: 10px 12px;
  display: grid;
  gap: 5px;
  box-shadow: var(--shadow-soft);
}

.home-workbench-submetrics span,
.task-summary-mini span {
  color: var(--muted);
  font-size: 12px;
}

.home-workbench-submetrics strong,
.task-summary-mini strong {
  font-size: 22px;
  line-height: 1;
  color: var(--accent-strong);
}

.home-workbench-feature-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.home-workbench-level-cluster {
  display: grid;
  gap: 8px;
  padding: 10px;
  border-radius: 16px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(247, 250, 255, 0.88);
  box-shadow: var(--shadow-soft);
}

.home-workbench-level-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

.home-workbench-level-head span {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
}

.home-workbench-level-head small {
  color: var(--muted);
  font-size: 11px;
}

.home-workbench-level-chip-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
}

.home-level-chip {
  display: grid;
  gap: 4px;
  min-height: 62px;
  align-content: center;
  padding: 8px 7px;
  border-radius: 14px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(242, 247, 255, 0.88));
  text-align: center;
}

.home-level-chip span {
  font-size: 11px;
  color: var(--muted);
}

.home-level-chip strong {
  font-size: 18px;
  line-height: 1;
  color: var(--accent-strong);
}

.table-hint {
  display: inline-block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.2;
}

.home-workbench-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 176px;
  min-height: 40px;
  width: fit-content;
  margin-top: auto;
  padding: 0 18px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--shadow-accent);
}

.home-workbench-button:hover,
.primary-link-button:hover,
.secondary-link-button:hover,
.table-action-link:hover {
  transform: translateY(-1px);
}

.home-workbench-button:hover,
.primary-link-button:hover {
  box-shadow: 0 18px 42px rgba(0, 82, 255, 0.24);
}

.home-kpi-panel {
  display: grid;
  gap: 14px;
  margin-bottom: 12px;
  padding: 16px;
  border-radius: var(--radius-card);
  background:
    radial-gradient(circle at top right, rgba(77, 124, 255, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(245, 249, 255, 0.95));
}

.home-kpi-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}

.home-kpi-header h2 {
  margin: 0;
}

.home-kpi-header .subtle {
  margin-top: 4px;
  font-size: 11px;
  line-height: 1.35;
  color: color-mix(in srgb, var(--muted) 72%, transparent);
}

.home-kpi-section {
  display: grid;
  gap: 8px;
}

.home-kpi-section + .home-kpi-section {
  padding-top: 2px;
}

.home-kpi-section-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-end;
}

.home-kpi-section-head h3 {
  margin: 0;
  font-size: 16px;
}

.home-kpi-section-head p {
  margin: 0;
  max-width: 500px;
  font-size: 10px;
  line-height: 1.3;
  color: color-mix(in srgb, var(--muted) 68%, transparent);
}

.home-kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 9px;
}

.home-kpi-card {
  display: grid;
  grid-template-rows: 24px minmax(30px, auto) minmax(56px, 1fr);
  gap: 7px;
  min-height: 130px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  box-shadow: var(--shadow-soft);
}

.home-kpi-card-primary {
  background:
    radial-gradient(circle at top right, rgba(0, 82, 255, 0.12), transparent 32%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(239, 246, 255, 0.95));
  border-color: rgba(77, 124, 255, 0.26);
}

.home-kpi-card-baseline {
  background: rgba(255, 255, 255, 0.86);
}

.home-kpi-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  line-height: 1.35;
  display: flex;
  align-items: flex-start;
}

.home-kpi-card-primary .home-kpi-value {
  font-size: 26px;
  line-height: 0.98;
  letter-spacing: -0.05em;
  color: var(--accent-strong);
  align-self: end;
}

.home-kpi-card-baseline .home-kpi-value {
  font-size: 20px;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--accent);
  align-self: end;
}

.home-kpi-compare {
  display: grid;
  gap: 4px;
  padding-top: 10px;
  border-top: 1px dashed rgba(215, 226, 240, 0.9);
  align-content: end;
}

.home-kpi-compare-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.home-kpi-compare-direction {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.home-kpi-compare-delta {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.home-kpi-compare-rate {
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.home-kpi-compare-label {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.35;
}

.home-kpi-compare.up .home-kpi-compare-direction,
.home-kpi-compare.up .home-kpi-compare-delta,
.home-kpi-compare.up .home-kpi-compare-rate {
  color: var(--danger);
}

.home-kpi-compare.up .home-kpi-compare-direction {
  background: rgba(209, 75, 61, 0.12);
}

.home-kpi-compare.down .home-kpi-compare-direction,
.home-kpi-compare.down .home-kpi-compare-delta,
.home-kpi-compare.down .home-kpi-compare-rate {
  color: #0f8a62;
}

.home-kpi-compare.down .home-kpi-compare-direction {
  background: rgba(15, 138, 98, 0.12);
}

.home-kpi-compare.flat .home-kpi-compare-direction,
.home-kpi-compare.flat .home-kpi-compare-delta,
.home-kpi-compare.flat .home-kpi-compare-rate {
  color: #6f7c8d;
}

.home-kpi-compare.flat .home-kpi-compare-direction {
  background: rgba(111, 124, 141, 0.12);
}

.home-kpi-compare.placeholder {
  color: var(--muted);
  border-top-style: solid;
  opacity: 0.55;
}

.home-business-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.home-business-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(215, 226, 240, 0.9);
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(0, 82, 255, 0.07), transparent 28%),
    rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
}

.home-business-card-featured {
  grid-column: 1 / -1;
  padding: 20px;
  background:
    radial-gradient(circle at top right, rgba(0, 82, 255, 0.12), transparent 30%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(243, 247, 255, 0.95));
  border-color: rgba(77, 124, 255, 0.28);
}

.home-business-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.home-business-card-head h3 {
  margin: 0;
  font-size: 18px;
  letter-spacing: -0.03em;
}

.home-business-card-head span {
  font-size: 11px;
  font-weight: 700;
  color: color-mix(in srgb, var(--muted) 78%, transparent);
}

.home-business-card-body {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(260px, 0.88fr);
  gap: 14px;
  align-items: stretch;
}

.home-business-card:not(.home-business-card-featured) .home-business-card-body {
  grid-template-columns: 1fr;
}

.home-business-primary,
.home-business-secondary {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: rgba(255, 255, 255, 0.72);
}

.home-business-primary {
  border-color: rgba(77, 124, 255, 0.22);
  background:
    radial-gradient(circle at top right, rgba(77, 124, 255, 0.1), transparent 32%),
    rgba(255, 255, 255, 0.82);
}

.home-business-primary > span,
.home-business-secondary > span {
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
}

.home-business-primary > strong {
  font-size: clamp(34px, 4.8vw, 54px);
  line-height: 0.94;
  letter-spacing: -0.07em;
  color: var(--accent-strong);
}

.home-business-secondary > strong {
  font-size: clamp(26px, 3vw, 34px);
  line-height: 0.96;
  letter-spacing: -0.06em;
  color: var(--text);
}

.home-business-card:not(.home-business-card-featured) .home-business-primary > strong {
  font-size: clamp(30px, 3.6vw, 42px);
}

.home-business-card:not(.home-business-card-featured) .home-business-secondary > strong {
  font-size: 28px;
}

.home-business-trend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  padding-top: 10px;
  border-top: 1px dashed rgba(215, 226, 240, 0.95);
  color: #6f7c8d;
}

.home-business-trend-label {
  width: 100%;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
}

.home-business-trend strong {
  font-size: 17px;
  line-height: 1;
  letter-spacing: -0.03em;
}

.home-business-trend span:not(.home-business-trend-label) {
  font-size: 12px;
  font-weight: 800;
}

.home-business-trend em {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.home-business-trend.up,
.home-business-trend.up strong,
.home-business-trend.up span:not(.home-business-trend-label) {
  color: var(--danger);
}

.home-business-trend.up em {
  color: var(--danger);
  background: rgba(209, 75, 61, 0.12);
}

.home-business-trend.down,
.home-business-trend.down strong,
.home-business-trend.down span:not(.home-business-trend-label) {
  color: #0f8a62;
}

.home-business-trend.down em {
  color: #0f8a62;
  background: rgba(15, 138, 98, 0.12);
}

.home-business-trend.flat,
.home-business-trend.flat strong,
.home-business-trend.flat span:not(.home-business-trend-label) {
  color: #6f7c8d;
}

.home-business-trend.flat em {
  color: #6f7c8d;
  background: rgba(111, 124, 141, 0.12);
}

.home-business-reference {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding-top: 2px;
}

.home-business-reference span {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(241, 245, 249, 0.74);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.home-business-reference strong {
  color: var(--text);
  font-size: 15px;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.home-note-strip {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: var(--shadow);
  padding: 10px 14px;
}

.home-note-strip p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 12px;
}

.home-upload-panel {
  margin-top: 12px;
  display: grid;
  gap: 12px;
}

.home-upload-header {
  align-items: flex-start;
}

.home-upload-header .subtle {
  max-width: 560px;
}

.home-upload-form {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.home-upload-form label {
  gap: 6px;
}

.home-upload-actions {
  margin-top: 0;
}

.home-upload-result {
  display: grid;
  gap: 12px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(247, 250, 255, 0.84);
  padding: 12px 14px;
}

.home-upload-result-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.home-upload-result-head strong {
  font-size: 16px;
  color: var(--accent-strong);
}

.home-upload-precheck {
  display: grid;
  gap: 12px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.9);
  padding: 14px;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

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

.precheck-head h3 {
  margin: 0;
  color: var(--text);
  font-size: 16px;
  letter-spacing: -0.01em;
}

.precheck-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.precheck-status {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: var(--radius-pill);
  padding: 5px 11px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.precheck-status.success {
  color: #08745f;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.18);
}

.precheck-status.warning {
  color: #ad6500;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.precheck-status.danger {
  color: #b23a2c;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.18);
}

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

.precheck-file-card {
  display: grid;
  gap: 10px;
  min-width: 0;
  border-radius: 16px;
  border: 1px solid rgba(215, 226, 240, 0.82);
  background: rgba(247, 250, 255, 0.72);
  padding: 12px;
}

.precheck-file-card.success {
  border-color: rgba(16, 185, 129, 0.18);
}

.precheck-file-card.failed {
  border-color: rgba(239, 68, 68, 0.18);
}

.precheck-file-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.precheck-file-title strong {
  color: var(--text);
  font-size: 13px;
}

.precheck-file-card dl {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 7px 10px;
  margin: 0;
  font-size: 12px;
}

.precheck-file-card dt {
  color: var(--muted);
  font-weight: 700;
}

.precheck-file-card dd {
  margin: 0;
  color: var(--text);
  word-break: break-word;
}

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

.precheck-meta-grid > div {
  display: grid;
  gap: 5px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(215, 226, 240, 0.74);
  background: rgba(247, 250, 255, 0.64);
}

.precheck-meta-grid span,
.precheck-meta-grid small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.precheck-meta-grid strong {
  color: var(--text);
  font-size: 14px;
}

.precheck-message-list {
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.55;
}

.precheck-message-list strong {
  display: block;
  margin-bottom: 4px;
}

.precheck-message-list ul {
  margin: 0;
  padding-left: 18px;
}

.precheck-message-list.warning {
  color: #85530a;
  border: 1px solid rgba(245, 158, 11, 0.18);
  background: rgba(245, 158, 11, 0.08);
}

.precheck-message-list.error {
  color: #9f2f24;
  border: 1px solid rgba(239, 68, 68, 0.18);
  background: rgba(239, 68, 68, 0.08);
}

.home-upload-table {
  margin-top: -2px;
}

.batch-no-cell {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.batch-no-cell strong {
  color: var(--text);
  font-weight: 700;
}

.batch-current-row td {
  background: rgba(0, 82, 255, 0.035);
}

.batch-current-chip,
.batch-source-label,
.batch-status-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: var(--radius-pill);
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.batch-current-chip {
  color: var(--accent-strong);
  border: 1px solid rgba(0, 82, 255, 0.2);
  background: rgba(0, 82, 255, 0.08);
}

.batch-source-label {
  color: #42526e;
  background: rgba(241, 245, 249, 0.86);
  border: 1px solid rgba(215, 226, 240, 0.82);
}

.batch-status-tag.success {
  color: #08745f;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.18);
}

.batch-status-tag.danger {
  color: #b23a2c;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.18);
}

.batch-status-tag.info {
  color: var(--accent-strong);
  background: rgba(0, 82, 255, 0.08);
  border: 1px solid rgba(0, 82, 255, 0.16);
}

.batch-status-tag.muted {
  color: var(--muted);
  background: rgba(241, 245, 249, 0.82);
  border: 1px solid rgba(215, 226, 240, 0.82);
}

.batch-error-hint {
  max-width: 220px;
  margin-top: 6px;
  color: #b23a2c;
  font-size: 11px;
  line-height: 1.45;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.batch-detail-toggle {
  padding: 7px 11px;
  min-height: 32px;
  font-size: 12px;
}

.batch-detail-row td {
  background: rgba(248, 251, 255, 0.84);
  padding: 0 12px 14px;
}

.batch-detail-panel {
  display: grid;
  gap: 14px;
  margin: 4px 0 0;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.batch-detail-section {
  display: grid;
  gap: 10px;
}

.batch-detail-section h3 {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  letter-spacing: -0.01em;
}

.batch-detail-grid,
.batch-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.batch-detail-kv,
.batch-stat-item {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 10px 11px;
  border-radius: 14px;
  border: 1px solid rgba(215, 226, 240, 0.74);
  background: rgba(247, 250, 255, 0.74);
}

.batch-detail-kv.wide {
  grid-column: 1 / -1;
}

.batch-detail-kv span,
.batch-stat-item span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.batch-detail-kv strong,
.batch-stat-item strong {
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
  word-break: break-word;
}

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

.batch-file-card {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(215, 226, 240, 0.82);
  background: rgba(255, 255, 255, 0.9);
}

.batch-file-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.batch-file-head strong {
  color: var(--text);
  font-size: 13px;
}

.batch-file-card dl {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 7px 10px;
  margin: 0;
  font-size: 12px;
}

.batch-file-card dt {
  color: var(--muted);
  font-weight: 700;
}

.batch-file-card dd {
  margin: 0;
  color: var(--text);
  word-break: break-word;
}

.batch-detail-loading {
  padding: 16px;
  text-align: center;
  color: var(--muted);
  border-radius: 16px;
  background: rgba(247, 250, 255, 0.72);
}

.batch-detail-loading.error {
  color: #b23a2c;
}

.work-stats-range {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: -4px 0 20px;
}

.work-stats-range > div:first-child {
  display: grid;
  gap: 4px;
}

.work-stats-tabs {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.62);
}

.work-stats-tab {
  min-height: 32px;
  padding: 6px 13px;
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: color-mix(in srgb, var(--muted) 78%, var(--ink));
  box-shadow: none;
  font-size: 13px;
  font-weight: 800;
}

.work-stats-tab.active {
  color: var(--accent-strong);
  background: rgba(0, 82, 255, 0.09);
  box-shadow: inset 0 0 0 1px rgba(0, 82, 255, 0.14);
}

.work-stats-section,
.work-stats-grid {
  margin-bottom: 18px;
}

.section-heading.compact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.section-heading.compact h2 {
  margin: 0;
  font-size: 20px;
}

.work-stats-overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.work-stats-grid.two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.work-stats-card {
  display: flex;
  flex-direction: column;
  padding: 20px;
}

.work-stats-grid.two > .work-stats-card {
  min-height: 206px;
}

.work-stat-metric {
  display: grid;
  align-content: space-between;
  gap: 10px;
  min-width: 0;
  min-height: 88px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: rgba(255, 255, 255, 0.76);
}

.work-stat-metric span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

.work-stat-metric strong {
  color: var(--text);
  font-size: 28px;
  line-height: 1;
}

.work-stat-metric small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.work-stat-metric.primary {
  border-color: rgba(0, 82, 255, 0.22);
  background: linear-gradient(180deg, rgba(0, 82, 255, 0.08), rgba(255, 255, 255, 0.92));
}

.work-stat-metric.primary strong {
  color: var(--accent-strong);
}

.work-stat-metric.success strong {
  color: #0f8b6d;
}

.work-stat-metric.warning strong {
  color: #b45309;
}

.work-stats-type-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  flex: 1;
}

.work-stats-type-card {
  display: grid;
  align-content: space-between;
  gap: 14px;
  min-height: 128px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: rgba(248, 251, 255, 0.72);
}

.work-stats-type-title strong {
  color: var(--text);
  font-size: 15px;
}

.work-stats-type-card dl {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.work-stats-type-card dt {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.work-stats-type-card dd {
  margin: 5px 0 0;
  color: var(--text);
  font-size: 22px;
  font-weight: 850;
}

.work-stats-risk-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  flex: 1;
}

.work-stats-risk-grid .work-stat-metric {
  min-height: 128px;
}

.operator-cell {
  display: grid;
  gap: 4px;
}

.operator-cell strong {
  color: var(--text);
}

.operator-cell.compact {
  gap: 2px;
}

.page-work-stats .table-wrap table {
  table-layout: fixed;
}

.page-work-stats .work-stats-operator-table th:not(:first-child),
.page-work-stats .work-stats-operator-table td:not(:first-child) {
  text-align: right;
}

.page-work-stats .table-wrap th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.page-work-stats .table-wrap td {
  padding-top: 14px;
  padding-bottom: 14px;
}

.work-stats-log-card {
  margin-top: 18px;
}

.work-stats-log-table th,
.work-stats-log-table td {
  text-align: left;
  vertical-align: top;
}

.work-stats-log-table th:first-child {
  width: 128px;
}

.work-stats-log-table th:nth-child(2) {
  width: 170px;
}

.work-stats-log-table th:nth-child(3),
.work-stats-log-table th:nth-child(4) {
  width: 120px;
}

.work-stats-log-table th:nth-child(5) {
  width: 180px;
}

.work-stats-action,
.work-stats-task-type {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: rgba(0, 82, 255, 0.07);
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.work-stats-task-type {
  background: rgba(100, 116, 139, 0.09);
  color: color-mix(in srgb, var(--muted) 76%, var(--text));
}

.work-stats-customer-link,
.work-stats-customer-link:link,
.work-stats-customer-link:visited,
.work-stats-customer-link:active {
  color: var(--text);
  font-weight: 750;
  text-decoration: none;
}

.work-stats-customer-link:hover {
  color: var(--accent-strong);
}

.work-stats-note-summary {
  display: -webkit-box;
  max-width: 100%;
  overflow: hidden;
  color: color-mix(in srgb, var(--muted) 72%, var(--text));
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.task-guidance-note {
  margin: -2px 0 18px;
  color: var(--muted);
  line-height: 1.6;
}

.task-action-explainer {
  margin: 10px 0 0;
  line-height: 1.55;
}

.task-filter-grid {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.task-filter-panel {
  padding: 18px 20px;
}

.task-filter-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, 1.45fr) minmax(160px, 0.75fr) minmax(160px, 0.75fr) auto;
  gap: 12px;
  align-items: end;
}

.task-filter-actions {
  margin-top: 0;
  flex-wrap: nowrap;
  align-self: end;
}

.task-filter-actions .subtle:empty {
  display: none;
}

.task-advanced-toggle {
  color: var(--muted);
}

.task-advanced-toggle.active {
  color: var(--accent-strong);
  border-color: rgba(77, 124, 255, 0.34);
  background: rgba(0, 82, 255, 0.06);
}

.task-advanced-filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(170px, 1fr));
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(215, 226, 240, 0.72);
}

.task-advanced-filters.hidden {
  display: none;
}

.task-summary-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.task-summary-filter-card {
  cursor: pointer;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease;
}

.task-summary-filter-card:hover {
  transform: translateY(-1px);
  border-color: rgba(77, 124, 255, 0.32);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.08);
}

.task-summary-filter-card.active {
  border-color: rgba(77, 124, 255, 0.38);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(238, 245, 255, 0.96));
  box-shadow: 0 16px 34px rgba(0, 82, 255, 0.12);
}

.task-summary-filter-card.active span,
.task-summary-filter-card.active strong {
  color: var(--accent-strong);
}

.task-name-cell {
  display: grid;
  gap: 6px;
}

.task-name-link {
  font-weight: 700;
}

.task-type-cell {
  display: grid;
  gap: 6px;
  min-width: 132px;
}

.task-name-meta {
  font-size: 12px;
}

.secondary-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 13px;
  border-radius: 14px;
  border: 1px solid rgba(192, 208, 230, 0.92);
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}

.secondary-link-button:hover {
  border-color: rgba(0, 82, 255, 0.2);
  color: var(--accent-strong);
  background: rgba(247, 250, 255, 0.98);
}

.primary-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 15px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  box-shadow: var(--shadow-accent);
}

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

.import-rule-card,
.import-summary-card {
  border-radius: var(--radius-soft);
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.86);
  padding: 13px 14px;
  display: grid;
  gap: 6px;
  box-shadow: var(--shadow-soft);
}

.import-rule-card strong,
.import-summary-card strong {
  font-size: 16px;
  color: var(--accent-strong);
}

.import-rule-card p,
.import-summary-card small {
  margin: 0;
  line-height: 1.45;
  color: var(--muted);
  font-size: 12px;
}

.import-result-grid {
  margin-top: 14px;
}

.import-result-stack {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 14px;
}

.import-failed-group {
  margin-top: 14px;
}

.panel-soft {
  padding-top: 12px;
  padding-bottom: 12px;
}

.quick-filter-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.quick-filter-chip {
  min-height: 36px;
  padding: 7px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(0, 82, 255, 0.14);
  background: rgba(255, 255, 255, 0.88);
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 700;
  box-shadow: none;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
}

.quick-filter-chip:hover {
  transform: translateY(-1px);
  border-color: rgba(0, 82, 255, 0.22);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.quick-filter-chip.active {
  background: rgba(0, 82, 255, 0.09);
  border-color: rgba(0, 82, 255, 0.24);
  box-shadow: none;
}

.table-action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 12px;
  border: 1px solid rgba(192, 208, 230, 0.9);
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: none;
}

.table-action-link:hover {
  border-color: rgba(0, 82, 255, 0.22);
  color: var(--accent-strong);
  background: rgba(243, 248, 255, 0.98);
}

.account-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.account-create-panel {
  margin-bottom: 16px;
}

.account-form-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.account-create-panel .account-form-grid {
  grid-template-columns: minmax(170px, 1fr) minmax(170px, 1fr) minmax(170px, 1fr) auto;
  align-items: end;
}

.account-form-grid .wide {
  grid-column: 1 / -1;
}

.account-create-actions {
  align-self: end;
  margin-top: 0;
  min-height: 42px;
}

.account-create-actions button {
  min-width: 112px;
}

.account-table {
  min-width: 980px;
}

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

.account-table-actions button {
  min-height: 34px;
  padding: 7px 10px;
  border-radius: 12px;
  font-size: 12px;
}

.account-table-actions .danger-lite {
  color: var(--danger);
  border-color: rgba(209, 75, 61, 0.22);
}

button.danger-action {
  background: linear-gradient(135deg, #d14b3d, #e46d5f);
  color: #fff;
  box-shadow: 0 10px 26px rgba(209, 75, 61, 0.15);
}

.account-current-mark {
  display: inline-flex;
  margin-left: 8px;
  padding: 3px 7px;
  border-radius: var(--radius-pill);
  background: rgba(0, 82, 255, 0.08);
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
  vertical-align: middle;
}

.account-log-table {
  min-width: 900px;
}

.account-log-note {
  color: var(--muted);
  max-width: 280px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account-toast {
  position: fixed;
  top: 24px;
  right: 28px;
  z-index: 120;
  max-width: min(360px, calc(100vw - 40px));
  padding: 11px 14px;
  border-radius: 16px;
  border: 1px solid rgba(215, 226, 240, 0.92);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.account-toast.success {
  border-color: rgba(15, 138, 98, 0.2);
  color: var(--success);
}

.account-toast.error {
  border-color: rgba(209, 75, 61, 0.22);
  color: var(--danger);
}

.account-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.22);
  backdrop-filter: blur(10px);
}

.account-modal {
  width: min(460px, 100%);
  border-radius: 24px;
  border: 1px solid rgba(215, 226, 240, 0.96);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.18);
  padding: 18px;
}

.account-modal-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.account-modal-head h2 {
  margin: 0 0 6px;
  font-size: 22px;
}

.account-modal-head p {
  margin: 0;
  line-height: 1.5;
}

.account-modal-close {
  min-height: 32px;
  width: 32px;
  padding: 0;
  border-radius: 50%;
  background: rgba(245, 248, 255, 0.92);
  border: 1px solid rgba(192, 208, 230, 0.8);
  color: var(--muted);
  box-shadow: none;
  font-size: 18px;
  line-height: 1;
}

.account-modal-fields {
  display: grid;
  gap: 12px;
}

.account-modal-summary {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(245, 248, 255, 0.76);
}

.account-modal-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.account-modal-summary strong {
  color: var(--ink);
  font-size: 16px;
}

.account-modal-error {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(209, 75, 61, 0.08);
  color: var(--danger);
  font-size: 13px;
  font-weight: 800;
}

.account-modal-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
}

.maintenance-shell {
  width: min(1320px, calc(100vw - 48px));
}

.maintenance-page-header {
  align-items: start;
}

.maintenance-subtitle {
  margin: 8px 0 0;
  color: color-mix(in srgb, var(--muted) 92%, var(--ink));
  font-size: 15px;
  line-height: 1.7;
}

.maintenance-main {
  display: grid;
  gap: 18px;
}

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

.maintenance-status-card {
  min-height: 118px;
  padding: 22px;
  border: 1px solid rgba(202, 216, 235, 0.78);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-soft);
}

.maintenance-status-card span,
.maintenance-path-grid span {
  display: block;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  font-size: 13px;
  font-weight: 800;
}

.maintenance-status-card strong {
  display: block;
  margin-top: 18px;
  overflow: hidden;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.maintenance-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.maintenance-section-head.compact {
  align-items: center;
}

.maintenance-section-head h2 {
  margin: 0;
  color: var(--ink);
  font-size: 22px;
}

.maintenance-section-head p {
  margin: 8px 0 0;
  color: color-mix(in srgb, var(--muted) 92%, var(--ink));
  font-size: 14px;
  line-height: 1.6;
}

.maintenance-feedback {
  min-height: 24px;
  margin-bottom: 16px;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  font-size: 14px;
  font-weight: 800;
}

.maintenance-feedback[data-tone="success"] {
  color: #0f8f5f;
}

.maintenance-feedback[data-tone="danger"] {
  color: #d14343;
}

.maintenance-path-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.maintenance-path-grid > div {
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(211, 224, 243, 0.72);
  border-radius: 18px;
  background: rgba(248, 251, 255, 0.72);
}

.maintenance-path-grid strong,
.maintenance-file-path {
  display: block;
  margin-top: 8px;
  overflow: hidden;
  color: color-mix(in srgb, var(--ink) 78%, var(--accent));
  font-size: 13px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.maintenance-table-wrap table {
  min-width: 980px;
}

.maintenance-table-wrap th,
.maintenance-table-wrap td {
  vertical-align: top;
}

.maintenance-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
}

.maintenance-status-pill.success {
  background: rgba(15, 143, 95, 0.11);
  color: #0f8f5f;
}

.maintenance-status-pill.danger {
  background: rgba(209, 67, 67, 0.11);
  color: #d14343;
}

.maintenance-status-pill.neutral {
  background: rgba(100, 116, 139, 0.1);
  color: color-mix(in srgb, var(--muted) 86%, var(--ink));
}

.maintenance-error {
  margin-top: 6px;
  color: #d14343;
  font-size: 12px;
  line-height: 1.5;
}

.maintenance-note-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 18px;
}

.maintenance-note-card h2 {
  margin: 0 0 14px;
  color: var(--ink);
  font-size: 20px;
}

.maintenance-note-card ul {
  margin: 0;
  padding-left: 18px;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  line-height: 1.8;
}

.maintenance-note-card p {
  margin: 0;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  line-height: 1.8;
}

.help-shell {
  width: min(1160px, calc(100vw - 72px));
}

.help-page-header {
  align-items: center;
}

.help-page-subtitle {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 15px;
}

.help-layout {
  display: grid;
  grid-template-columns: 238px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.help-nav {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid rgba(215, 226, 240, 0.88);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-soft);
}

.help-nav-item {
  width: 100%;
  min-height: 38px;
  padding: 0 12px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  font-size: 14px;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.help-nav-item:hover {
  background: rgba(0, 82, 255, 0.055);
  color: var(--accent-strong);
}

.help-nav-item.active {
  background: linear-gradient(135deg, rgba(0, 82, 255, 0.12), rgba(77, 124, 255, 0.1));
  color: var(--accent-strong);
  box-shadow: inset 0 0 0 1px rgba(0, 82, 255, 0.16);
}

.help-content {
  min-height: 620px;
  padding: 28px;
}

.help-section {
  display: none;
}

.help-section.active {
  display: block;
}

.help-eyebrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 26px;
  margin-bottom: 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 800;
}

.help-section h2 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 42px);
  line-height: 1.1;
}

.help-section h3 {
  margin: 0 0 12px;
  font-family: var(--font-body);
  font-size: 16px;
  letter-spacing: -0.01em;
}

.help-section p {
  margin: 0 0 16px;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  font-size: 15px;
  line-height: 1.8;
}

.help-list,
.help-steps {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
  padding-left: 22px;
  color: color-mix(in srgb, var(--ink) 84%, var(--muted));
  font-size: 15px;
  line-height: 1.75;
}

.help-card-grid,
.help-two-col {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.help-two-col {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.help-mini-card,
.help-two-col > div {
  padding: 16px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  border-radius: 18px;
  background: rgba(248, 251, 255, 0.76);
}

.help-mini-card strong {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 16px;
}

.help-mini-card span {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.help-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.help-field-grid > div {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border: 1px solid rgba(215, 226, 240, 0.78);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.68);
}

.help-field-grid strong {
  color: var(--accent-strong);
  font-size: 14px;
}

.help-field-grid span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.help-faq-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.help-faq-list details {
  padding: 14px 16px;
  border: 1px solid rgba(215, 226, 240, 0.82);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.76);
}

.help-faq-list summary {
  color: var(--ink);
  font-weight: 900;
  cursor: pointer;
}

.help-faq-list p {
  margin: 10px 0 0;
  font-size: 14px;
}

.subtle.error {
  color: var(--danger);
  font-weight: 700;
}

.subtle.success {
  color: var(--success);
  font-weight: 700;
}

@media (max-width: 960px) {
  .import-template-grid,
  .import-job-summary-grid {
    grid-template-columns: 1fr;
  }
}

.task-action-card {
  border-radius: 0;
  background: transparent;
  border: 0;
  padding: 0;
  box-shadow: none;
}

.task-unified-panel > .panel-header {
  align-items: center;
}

.task-minimal-status {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.task-status-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  border: 1px solid rgba(215, 226, 240, 0.9);
  background: rgba(247, 250, 255, 0.74);
  padding: 4px 9px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.task-status-chip.type {
  border-color: rgba(0, 82, 255, 0.22);
  background: rgba(0, 82, 255, 0.06);
  color: var(--accent-strong);
}

.task-minimal-summary {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
}

.task-minimal-summary strong {
  color: var(--ink);
  font-size: 15px;
}

.task-next-line {
  margin: 0 0 10px;
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 700;
}

.task-action-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 10px;
}

.task-action-head strong {
  font-size: 16px;
}

.task-action-head p {
  margin: 3px 0 0;
  font-size: 12px;
}

.task-primary-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}

.task-primary-card {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(215, 226, 240, 0.9);
  background: rgba(247, 250, 255, 0.78);
  padding: 5px 10px;
}

.task-primary-card.task-primary-type {
  border-color: rgba(0, 82, 255, 0.24);
  background: rgba(0, 82, 255, 0.06);
}

.task-primary-card.wide {
  flex: 1 1 100%;
  justify-content: flex-start;
  border-radius: 12px;
  background: rgba(248, 251, 255, 0.84);
  padding: 9px 11px;
}

.task-primary-card span {
  font-size: 12px;
  color: var(--muted);
}

.task-primary-card strong {
  font-size: 13px;
  line-height: 1.45;
  color: var(--ink);
  word-break: break-word;
}

.task-primary-card.wide strong {
  font-size: 14px;
}

.task-action-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.task-action-meta:empty {
  display: none;
}

.task-action-meta-secondary {
  margin-bottom: 12px;
}

.task-action-form {
  grid-template-columns: 1fr;
  gap: 7px;
  margin-bottom: 11px;
  padding-bottom: 11px;
  border-bottom: 1px solid rgba(215, 226, 240, 0.72);
}

.task-action-form label {
  gap: 5px;
}

.task-action-form textarea {
  min-height: 38px;
  padding: 9px 12px;
}

.task-action-buttons {
  margin-top: 0;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.task-action-buttons button {
  min-width: 84px;
  min-height: 38px;
  padding: 8px 13px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
}

.task-action-buttons .ghost-button {
  background: transparent;
  box-shadow: none;
}

.task-action-buttons .subtle {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
}

.task-result-panel {
  display: grid;
  gap: 9px;
  padding-top: 1px;
}

.task-result-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.task-result-head strong {
  display: block;
  font-size: 15px;
}

.task-result-head p {
  margin: 3px 0 0;
  font-size: 12px;
}

.task-result-head .subtle:empty {
  display: none;
}

.task-workorder-summary {
  margin-bottom: 4px;
  border-radius: 12px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: rgba(247, 250, 255, 0.78);
  padding: 10px 12px;
}

.task-workorder-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px 10px;
}

.task-workorder-grid article {
  display: grid;
  gap: 2px;
}

.task-workorder-grid span {
  font-size: 11px;
  color: var(--muted);
}

.task-workorder-grid strong {
  font-size: 13px;
  line-height: 1.35;
  color: var(--ink);
}

.task-workorder-form {
  margin-bottom: 8px;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  gap: 6px 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.task-workorder-form .check-field {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 6px 10px;
  border-radius: 12px;
  border: 1px solid rgba(215, 226, 240, 0.86);
  background: rgba(255, 255, 255, 0.88);
  justify-content: flex-start;
  align-self: start;
}

.task-workorder-form .check-field.wide {
  min-height: 38px;
  grid-column: auto;
}

.task-workorder-form .check-field input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  flex: 0 0 auto;
}

.task-workorder-form .check-field span {
  font-size: 11px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.25;
}

.task-workorder-form label.wide:not(.check-field) {
  gap: 4px;
}

.task-workorder-form textarea {
  min-height: 52px;
  padding: 9px 12px;
}

.task-workorder-actions {
  margin-top: 0;
  gap: 6px;
}

.task-workorder-actions .secondary {
  min-width: 148px;
  min-height: 38px;
  padding: 8px 15px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 700;
}

.task-recent-log {
  border-top: 1px solid rgba(215, 226, 240, 0.72);
  padding-top: 10px;
}

.task-recent-log-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 7px;
}

.task-recent-log-head strong {
  font-size: 13px;
}

.task-recent-log-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.task-recent-log-list li {
  display: grid;
  grid-template-columns: minmax(104px, 0.8fr) minmax(56px, 0.4fr) minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}

.task-recent-log-list strong {
  color: var(--ink);
  font-size: 12px;
}

.task-recent-log-list em {
  font-style: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-inline-log {
  margin-top: 12px;
  border-top: 1px dashed rgba(215, 226, 240, 0.92);
  padding-top: 12px;
}

.task-inline-log-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.task-inline-log-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.task-inline-log-item {
  border-radius: 14px;
  border: 1px solid rgba(215, 226, 240, 0.84);
  background: rgba(247, 250, 255, 0.88);
  padding: 8px 10px;
  display: grid;
  gap: 4px;
  box-shadow: var(--shadow-soft);
}

.task-inline-log-item-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
}

.task-inline-log-item-main {
  font-weight: 700;
  line-height: 1.4;
}

.task-inline-log-item-note {
  color: var(--muted);
  line-height: 1.45;
}

.followup-current-head,
.followup-form-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.followup-current-head strong,
.followup-form-head strong {
  display: block;
  font-size: 15px;
}

.followup-current-head .subtle,
.followup-form-head .subtle {
  margin: 4px 0 0;
  max-width: 32ch;
}

.trade-workorder-panel {
  display: grid;
  gap: 10px;
}

@media (max-width: 1280px) {
  .home-upload-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .batch-detail-grid,
  .precheck-file-grid,
  .precheck-meta-grid,
  .batch-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .task-workorder-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .task-primary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .help-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-stats-overview-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .maintenance-status-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 960px) {
  .page-header,
  .panel-header,
  .home-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-header {
    grid-template-columns: 1fr;
  }

  .system-topbar,
  .home-hero-topline {
    align-items: flex-start;
    flex-direction: column;
  }

  .system-topbar-actions,
  .home-hero-utility,
  .home-hero-status-row {
    justify-content: flex-start;
    margin-left: 0;
  }

  .page-header-right,
  .page-header > .badge-group {
    grid-column: auto;
    justify-self: start;
    justify-items: start;
  }

  .detail-system-row {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .detail-header-actions {
    justify-content: flex-start;
  }

  .detail-header-main,
  .detail-hero-grid,
  .detail-grid,
  .detail-group-grid,
  .compact-kv,
  .core-contact-grid,
  .contact-summary-grid,
  .contact-editor-grid,
  .analysis-status-row,
  .analysis-detail-grid,
  .analysis-spotlight-grid,
  .form-grid,
  .kv-grid,
  .followup-workbench-grid,
  .home-workbench-grid,
  .home-workbench-submetrics,
  .home-workbench-feature-grid,
  .home-workbench-level-chip-grid,
  .home-upload-form,
  .home-business-kpi-grid,
  .home-kpi-grid,
  .batch-detail-grid,
  .batch-file-grid,
  .precheck-file-grid,
  .precheck-meta-grid,
  .batch-stat-grid,
  .account-layout,
  .account-form-grid,
  .account-create-panel .account-form-grid,
  .task-filter-toolbar,
  .task-advanced-filters,
  .task-primary-grid,
  .task-summary-strip,
  .task-summary-grid,
  .task-owner-grid,
  .task-workorder-grid,
  .help-layout,
  .help-card-grid,
  .help-two-col,
  .help-field-grid,
  .work-stats-overview-grid,
  .work-stats-grid.two,
  .work-stats-type-grid,
  .work-stats-risk-grid,
  .maintenance-status-grid,
  .maintenance-path-grid,
  .maintenance-note-grid {
    grid-template-columns: 1fr;
  }

  .work-stats-range {
    flex-direction: column;
    align-items: flex-start;
  }

  .work-stats-tabs {
    width: 100%;
    overflow-x: auto;
  }

  .help-nav {
    position: static;
  }

  .help-content {
    min-height: 0;
    padding: 22px 18px;
  }

  .analysis-compact-kv {
    grid-template-columns: 1fr;
  }

  .task-action-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .task-action-buttons button,
  .task-workorder-actions .secondary {
    width: 100%;
  }

  .shell,
  .detail-shell {
    width: min(100vw - 20px, 100%);
  }

  .trend-toolbar,
  .trend-chart-meta,
  .trend-judgement-head,
  .identity-panel-head,
  .analysis-emphasis-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .detail-title-row {
    display: grid;
  }

  .detail-header-meta {
    min-width: 0;
    width: 100%;
  }

  .home-hero-tags {
    justify-content: flex-start;
  }

  .identity-contact-head,
  .contact-inline-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .contact-module-edit-button {
    width: 100%;
  }

  .identity-status-strip {
    justify-content: flex-start;
  }

  .home-kpi-header,
  .home-kpi-section-head {
    align-items: flex-start;
  }

  .home-business-card-body,
  .home-business-reference {
    grid-template-columns: 1fr;
  }

  .home-hero-tags {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .contact-inline-edit-button {
    width: 100%;
  }

  .contact-inline-editor-control {
    width: 100%;
  }

  .home-workbench-level-head,
  .home-kpi-compare-topline {
    flex-direction: column;
    align-items: flex-start;
  }

  .login-shell {
    width: calc(100vw - 24px);
    padding: 20px 0;
  }

  .login-card {
    padding: 22px 18px 18px;
    border-radius: 24px;
  }

  .login-actions {
    flex-direction: column;
    align-items: flex-start;
  }
}
