:root {
  --bg: #F1F5F9;
  --panel: #ffffff;
  --line: #E8EDF2;
  --text: #1F2937;
  --muted: #64748B;
  --accent: #1F7A6B;
  --accent-soft: #E6F4F1;
  --ok: #14614F;
  --warn: #B26A00;
  --shadow: 0 10px 28px rgba(15, 42, 46, 0.08);
  --side: #12232B;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top, rgba(201, 220, 233, 0.5), transparent 28%),
    var(--bg);
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
}

[hidden] {
  display: none !important;
}

.login-panel {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(238, 242, 246, 0.95);
}

.login-card,
.panel,
.page-head,
.side-card,
.stat-card,
.detail-item,
.list-card,
.timeline-body {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.login-card {
  width: min(420px, 100%);
  padding: 28px;
}

.portal-card {
  width: min(560px, 100%);
}

.portal-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0 16px;
}

.portal-option {
  display: grid;
  place-items: center;
  min-height: 64px;
  text-align: center;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f7fafc;
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease, transform .15s ease;
}

.portal-option:hover {
  border-color: #7aa7d9;
  background: #eef5fc;
  transform: translateY(-1px);
}

.portal-option.is-current {
  border-color: #3b82c4;
  background: #e8f2fb;
}

.portal-option strong {
  font-size: 16px;
  color: #1f2d3d;
}

.portal-option span {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.4;
}

.portal-switch-btn {
  width: 100%;
  margin-top: 12px;
}

@media (max-width: 560px) {
  .portal-options {
    grid-template-columns: 1fr;
  }
}

.brand-block h1,
.page-head h2,
.section-head h3 {
  margin: 0;
}

.brand-block p,
.eyebrow,
.meta,
.list-desc,
.side-card span,
.side-card small {
  color: var(--muted);
}

.brand-block p {
  margin: 8px 0 0;
}

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

.sidebar {
  padding: 20px;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, #f7fafc 0%, #f3f7fb 100%);
}

.side-card {
  margin-top: 14px;
  padding: 14px;
}

.side-card span,
.side-card small {
  display: block;
}

.side-card strong {
  display: block;
  margin-top: 6px;
}

.nav-menu {
  margin-top: 16px;
  display: grid;
  gap: 14px;
  padding: 0 12px;
}

.nav-group {
  display: grid;
  gap: 6px;
}

.nav-group-title {
  padding: 0 6px;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: #8a97a3;
  text-transform: none;
}

.nav-link,
.btn,
.action-btn {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--text);
  cursor: pointer;
  font: inherit;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.nav-link {
  padding: 10px 12px;
  text-align: left;
}

.nav-link.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px rgba(46, 103, 134, 0.1);
}

.content {
  padding: 22px;
  display: grid;
  gap: 18px;
  align-content: start;
  align-items: start;
}

.page-head,
.panel {
  padding: 16px 18px;
}

.page-head {
  display: block;
  width: 100%;
  height: auto;
  align-self: start;
}

.page-head-row,
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 42px;
}

.page-head-copy,
.section-head > div:first-child {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  min-width: 0;
}

.page-head h2,
.section-head h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.25;
}

.workspace-crumb,
.section-head .eyebrow {
  margin: 0;
  font-size: 12px;
  line-height: 1.2;
}

.section-head > .toolbar,
.section-head > .toolbar.compact {
  flex: 0 0 auto;
  align-items: center;
  margin-left: auto;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.toolbar.compact {
  align-items: stretch;
  flex: 1 1 320px;
  min-width: 0;
  justify-content: flex-end;
}

.btn,
.action-btn {
  min-height: 42px;
  padding: 0 14px;
}

.btn.primary,
.action-btn {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 8px 18px rgba(46, 103, 134, 0.16);
}

.secondary-btn {
  background: #f4f8fb;
  color: var(--text);
}

.wide-btn {
  width: 100%;
}

.logout-btn {
  width: auto;
  min-width: 112px;
  max-width: 132px;
  margin: 16px auto 0;
  padding-left: 18px;
  padding-right: 18px;
  display: block;
}

.input,
textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--text);
  font: inherit;
}

.input + .input,
.input + textarea,
textarea + .button-row,
.form-grid + textarea {
  margin-top: 12px;
}

.search-input {
  width: 320px;
}

.slim-select {
  width: 180px;
}

.message {
  min-height: 42px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  display: inline-flex;
  align-items: center;
}

.message.ok {
  color: var(--ok);
}

.message.warn {
  color: var(--warn);
}

.message.action-msg {
  display: block;
  width: 100%;
  margin: 0 0 12px;
  box-sizing: border-box;
}

.selected-card,
.table tr.selected {
  outline: 2px solid rgba(31, 122, 107, 0.45);
  background: #F2FAF8;
}

.list-card {
  cursor: pointer;
}

.list-card[data-disabled="1"] {
  cursor: not-allowed;
  opacity: 0.72;
}

.section-panel {
  display: grid;
  gap: 18px;
  width: 100%;
  align-content: start;
  align-items: stretch;
  align-self: start;
}

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

.stat-card {
  padding: 16px 18px;
}

.stat-card.emphasis {
  border-color: var(--accent);
  background: linear-gradient(145deg, #f8fbfe, #eef5fa);
}

.stat-card span {
  display: block;
  font-size: 12px;
  color: var(--muted);
}

.stat-card strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

.split-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 18px;
  align-items: start;
}

.list-top,
.timeline-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.section-head {
  flex-wrap: wrap;
}

.section-head > div:first-child {
  flex: 0 0 auto;
}

.section-head h3 {
  white-space: nowrap;
  word-break: keep-all;
  line-break: strict;
}

.compact-head {
  margin-top: 18px;
}

.detail-grid,
.list,
.timeline,
.button-row,
.slim-list {
  display: grid;
  gap: 12px;
}

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

.detail-section-title {
  grid-column: 1 / -1;
  margin: 4px 0 0;
  padding: 10px 16px 2px;
  font-size: 13px;
  font-weight: 700;
  color: #1f5f56;
  letter-spacing: 0.02em;
}

.detail-section-title:first-child {
  margin-top: 0;
  padding-top: 4px;
}

.detail-item {
  padding: 16px;
}

.detail-item span {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--muted);
}

.detail-item strong {
  line-height: 1.6;
  white-space: pre-wrap;
}

.detail-item--duration {
  background: #f3faf7;
  border: 1px solid #d5ebe3;
  border-radius: 12px;
}

.detail-item--duration strong {
  color: #0f6b5c;
  font-size: 16px;
  font-weight: 700;
}

.list-card {
  padding: 16px 18px;
}

.warn-card {
  border-color: #e6c9bb;
}

.table-wrap {
  overflow: auto;
}

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

.table th,
.table td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.table th {
  font-size: 13px;
  color: var(--muted);
  background: #f7fafc;
}

.table tr {
  cursor: pointer;
}

.table tr.media-order-head td {
  background: #eef6f3;
  font-weight: 600;
  border-top: 1px solid var(--line);
}

.table tr:hover {
  background: #f8fbfd;
}

.row-action-cell {
  width: 96px;
}

.row-action-btn {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--accent);
  border-radius: 10px;
  background: #eef5fa;
  color: var(--accent);
  cursor: pointer;
  font: inherit;
  white-space: nowrap;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #f7fafc;
  font-size: 12px;
}

.badge.info {
  color: var(--accent);
}

.badge.ok {
  color: var(--ok);
}

.badge.warn {
  color: var(--warn);
}

/* 调度重点状态：待审核 / 待派单 / 异常待核验 */
.badge.priority-review {
  color: #9f1239;
  background: #fff1f2;
  border-color: #fecdd3;
  font-weight: 700;
}

.badge.priority-dispatch {
  color: #92400e;
  background: #fff7ed;
  border-color: #fdba74;
  font-weight: 700;
}

.badge.priority-exception {
  color: #7f1d1d;
  background: #fef2f2;
  border-color: #f87171;
  font-weight: 700;
}

.status-cell {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.timeline-item {
  display: flex;
  gap: 10px;
}

.timeline-dot {
  width: 10px;
  height: 10px;
  margin-top: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.timeline-body {
  flex: 1;
  padding: 12px 14px;
}

.timeline-text {
  margin-top: 8px;
  line-height: 1.6;
}

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

.nav-link:hover,
.btn:hover,
.action-btn:hover {
  transform: translateY(-1px);
}

.divider {
  height: 1px;
  margin: 8px 0 2px;
  background: var(--line);
}

.empty,
.empty-cell {
  color: var(--muted);
  text-align: center;
  padding: 14px 12px;
}

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

.manual-groups {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.manual-group {
  padding: 16px 16px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fafb;
}

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

.manual-group h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  font-weight: 600;
}

.manual-group h4::before {
  content: "";
  width: 3px;
  height: 14px;
  border-radius: 99px;
  background: #1f7a6b;
}

.manual-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 14px 12px;
}

.manual-form .field {
  display: grid;
  gap: 6px;
  flex: 0 0 auto;
  width: 168px;
  min-width: 0;
}

.manual-form .w-age { width: 96px; }
.manual-form .w-gender { width: 112px; }
.manual-form .w-fee { width: 140px; }
.manual-form .w-name { width: 168px; }
.manual-form .w-phone { width: 196px; }
.manual-form .w-code { width: 188px; }
.manual-form .w-time { width: 220px; }
.manual-form .w-id { width: 220px; }
.manual-form .w-service { width: 240px; }
.manual-form .w-care { width: 280px; }
.manual-form .w-full { width: 100%; }

.manual-group:not(.manual-group-wide) .manual-form .field {
  flex: 1 1 140px;
  width: auto;
  min-width: 140px;
  max-width: 220px;
}

.manual-form .field > span {
  color: var(--muted);
  font-size: 13px;
}

.manual-group .skill-check-grid {
  background: #fff;
}

.manual-remark {
  margin-top: 14px;
}

.manual-submit {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}

.manual-submit .action-btn {
  width: auto;
  min-width: 220px;
  padding-left: 28px;
  padding-right: 28px;
}

.inline-form {
  display: grid;
  grid-template-columns: repeat(5, minmax(130px, 1fr));
  gap: 12px;
  margin: 0 0 20px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fafc;
}

.inline-form .input {
  min-width: 0;
}

.inline-form .btn {
  min-height: 44px;
}

.inline-form select[multiple] {
  min-height: 88px;
}

.report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.report-grid--visual {
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, .9fr);
}

.chart-panel {
  display: grid;
  gap: 14px;
  min-height: 320px;
  background:
    linear-gradient(180deg, #fbfcfd 0%, #f4f8f7 100%);
  border: 1px solid rgba(31, 122, 107, 0.08);
}

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

.chart-panel__head h4 {
  margin: 2px 0 0;
}

.chart-meta {
  font-size: 12px;
  color: var(--muted);
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
}

.trend-chart,
.donut-chart {
  min-height: 240px;
}

.report-section-head {
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 22px;
}

.report-section-head > .report-toolbar.toolbar.compact {
  flex: 0 1 auto;
  align-items: center;
  justify-content: flex-end;
  margin-left: auto;
  gap: 10px;
}

.report-quick-range {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
}

.report-range-chip {
  min-height: 32px;
  padding: 0 12px;
}

.report-range-chip.is-on {
  background: #1f7a6b;
  border-color: #1f7a6b;
  color: #fff;
}

#reportSummary {
  margin-top: 4px;
}

.date-range-picker {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.date-range-picker__label {
  color: #5b7280;
  font-size: 13px;
  white-space: nowrap;
}

.date-range-picker__trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: auto;
  min-width: 0;
  max-width: 100%;
  min-height: 36px;
  padding: 0 10px 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #17323f;
  font: inherit;
  cursor: pointer;
}

.date-range-picker__trigger:hover {
  border-color: #1f8a70;
}

.date-range-picker__text {
  flex: 0 1 auto;
  text-align: left;
  white-space: nowrap;
}

.date-range-picker__text.is-placeholder {
  color: #94a3b8;
}

.date-range-picker__icon {
  flex: 0 0 auto;
  color: #94a3b8;
  font-size: 12px;
  line-height: 1;
}

.date-range-picker__panel {
  position: absolute;
  top: calc(100% + 8px);
  left: auto;
  right: 0;
  z-index: 40;
  box-sizing: border-box;
  width: 328px;
  padding: 14px 16px 16px;
  border: 1px solid #d7e3ea;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 16px 40px rgba(20, 40, 55, 0.16);
}

.date-range-picker__hint {
  margin-bottom: 12px;
  color: #5b7280;
  font-size: 13px;
  line-height: 1.4;
}

.date-range-picker__calendars {
  display: block;
  width: 100%;
}

.date-range-cal {
  width: 100%;
}

.date-range-cal__head {
  display: grid;
  grid-template-columns: 32px 32px 1fr 32px 32px;
  gap: 4px;
  align-items: center;
  margin-bottom: 10px;
}

.date-range-cal__title {
  text-align: center;
  font-weight: 700;
  color: #17323f;
  font-size: 15px;
}

.date-range-cal__nav {
  width: 32px;
  height: 32px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: #5b7280;
  cursor: pointer;
}

.date-range-cal__nav:hover {
  background: #f3f7f6;
  color: #1f8a70;
}

.date-range-cal__week,
.date-range-cal__days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  column-gap: 4px;
  row-gap: 8px;
  width: 100%;
}

.date-range-cal__week span {
  text-align: center;
  color: #94a3b8;
  font-size: 12px;
  padding: 4px 0 2px;
}

.date-range-day {
  width: 100%;
  height: 38px;
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #17323f;
  font: inherit;
  font-size: 14px;
  line-height: 38px;
  cursor: pointer;
}

.date-range-day:hover:not(:disabled) {
  background: rgba(31, 138, 112, 0.12);
  color: #1f8a70;
}

.date-range-day.is-empty {
  cursor: default;
  visibility: hidden;
}

.date-range-day.is-today {
  box-shadow: inset 0 0 0 1px #1f8a70;
}

.date-range-day.is-in-range {
  background: rgba(31, 138, 112, 0.12);
  border-radius: 0;
}

.date-range-day.is-start,
.date-range-day.is-end {
  background: #1f8a70;
  color: #fff;
  border-radius: 8px;
}

.date-range-day.is-start.is-in-range,
.date-range-day.is-start:not(.is-end) {
  border-radius: 8px 0 0 8px;
}

.date-range-day.is-end:not(.is-start) {
  border-radius: 0 8px 8px 0;
}

.date-range-picker__foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e8eef2;
}

.date-range-picker__foot .btn {
  min-width: 72px;
  min-height: 34px;
  padding: 0 14px;
}

.chart-hit {
  fill: transparent;
  stroke: none;
  cursor: pointer;
}

.donut-segment,
.donut-legend-item {
  cursor: pointer;
}

.chart-hover-tip {
  position: fixed;
  z-index: 9999;
  max-width: 280px;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(23, 50, 63, 0.94);
  color: #fff;
  font-size: 12px;
  line-height: 1.5;
  pointer-events: none;
  box-shadow: 0 8px 20px rgba(15, 35, 45, 0.22);
  white-space: pre-wrap;
}

.trend-svg,
.donut-svg {
  width: 100%;
  height: auto;
  display: block;
}

.chart-grid-line {
  stroke: rgba(31, 53, 71, 0.08);
  stroke-width: 1;
}

.chart-axis-label {
  fill: #7a8794;
  font-size: 11px;
}

.trend-area {
  fill: url(#trendAreaFill);
}

.trend-line {
  fill: none;
  stroke: #1f8a70;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart-point circle {
  fill: #fff;
  stroke: #1f8a70;
  stroke-width: 2.5;
}

.donut-layout {
  display: grid;
  grid-template-columns: minmax(180px, 220px) minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.donut-visual {
  display: grid;
  place-items: center;
}

.donut-track {
  fill: none;
  stroke: #e6eef1;
}

.donut-segment {
  fill: none;
  stroke-linecap: butt;
  transition: stroke-width .2s ease;
}

.donut-segment:hover {
  stroke-width: 32;
}

.donut-center-value {
  fill: #17323f;
  font-size: 28px;
  font-weight: 700;
}

.donut-center-label {
  fill: #7a8794;
  font-size: 12px;
}

.donut-legend {
  display: grid;
  gap: 10px;
}

.donut-legend-item {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.donut-swatch {
  width: 12px;
  height: 12px;
  margin-top: 4px;
  border-radius: 4px;
}

.donut-legend-copy {
  display: grid;
  gap: 2px;
}

.donut-legend-copy strong {
  font-size: 13px;
  color: var(--text);
}

.donut-legend-copy span {
  font-size: 12px;
  color: var(--muted);
}

.report-stat-card strong {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.report-stat-card small {
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}

.panel.inset {
  padding: 18px;
  background: #f8fafc;
  box-shadow: none;
}

.panel.inset h4 {
  margin: 0 0 12px;
}

.report-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

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

@media (max-width: 980px) {
  .report-grid--visual {
    grid-template-columns: 1fr;
  }

  .donut-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1200px) {
  .stat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .split-grid,
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 720px) {
  .content {
    padding: 14px;
  }

  .page-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .stat-grid,
  .detail-grid,
  .form-grid,
  .inline-form,
  .report-grid,
  .button-row {
    grid-template-columns: 1fr;
  }

  .manual-groups,
  .manual-group-wide {
    grid-column: auto;
    grid-template-columns: 1fr;
  }

  .manual-form .field,
  .manual-group:not(.manual-group-wide) .manual-form .field {
    flex: 1 1 100%;
    width: 100%;
    min-width: 0;
    max-width: none;
  }

  .search-input,
  .slim-select {
    width: 100%;
  }
}

/* Match the approved prototype: dark navigation, quiet workspace, compact ERP controls. */
:root {
  --bg: #eef2f6;
  --panel: #ffffff;
  --line: #e5e9ef;
  --text: #1f2937;
  --muted: #64748b;
  --accent: #1f7a6b;
  --accent-soft: #e6f4f1;
  --ok: #14614f;
  --warn: #b26a00;
  --shadow: 0 6px 18px rgba(15, 42, 46, 0.06);
}

body {
  background: #eef2f6;
  font-size: 14px;
}

.login-card,
.panel,
.page-head,
.side-card,
.stat-card,
.detail-item,
.list-card,
.timeline-body {
  border-radius: 10px;
  box-shadow: var(--shadow);
}

.sidebar {
  background: #12232b;
  border-right: 0;
  color: #94a3b8;
}

.sidebar .brand-block h1,
.sidebar .brand-block p,
.sidebar .side-card strong {
  color: #fff;
}

.sidebar .side-card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.nav-menu {
  gap: 6px;
}

.nav-link {
  border: 0;
  border-left: 3px solid transparent;
  border-radius: 0 6px 6px 0;
  background: transparent;
  color: #a8b8bd;
}

.nav-primary.is-current-group {
  color: #edf7f4;
  border-left-color: rgba(31, 122, 107, 0.7);
  background: rgba(31, 122, 107, 0.16);
}

.nav-child.active,
.nav-leaf.active {
  border-color: #1f7a6b;
  background: #1f7a6b;
  color: #fff;
  box-shadow: none;
}

.nav-leaf {
  font-weight: 600;
}

.content {
  padding: 18px;
  gap: 14px;
  align-content: start;
  align-items: start;
}

.page-head,
.panel {
  padding: 16px 18px;
}

.stat-grid {
  gap: 10px;
}

.stat-card {
  border-top: 3px solid #1f7a6b;
  border-radius: 10px;
}

.stat-card.emphasis {
  background: #f5fbf9;
  border-color: #1f7a6b;
}

.btn,
.action-btn,
.row-action-btn {
  border-radius: 6px;
}

.btn {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--text);
}

.btn.primary,
.action-btn {
  background: #1f7a6b;
  border-color: #1f7a6b;
  color: #fff;
}

.action-btn.secondary-btn,
.btn.secondary-btn,
.secondary-btn {
  background: #f4f8fb !important;
  border-color: #d7e3ea !important;
  color: #1f2937 !important;
  box-shadow: none !important;
}

.action-btn.danger-btn,
.row-action-btn.danger,
.danger-btn {
  background: #fff5f3 !important;
  border-color: #e8b4a8 !important;
  color: #b42318 !important;
  box-shadow: none !important;
}

.row-action-btn {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #cfe3dd;
  border-radius: 6px;
  background: #f3faf7;
  color: #14614f;
  cursor: pointer;
  font: inherit;
  white-space: nowrap;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 220px;
}

/* 服务人员表：长字段截断 + 横向滚动，避免把短列挤成竖排一字一行 */
.worker-table-wrap {
  overflow-x: auto;
  overflow-y: visible;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.worker-table {
  min-width: 1280px;
  table-layout: fixed;
}

.worker-table th,
.worker-table td {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}

.worker-table th:nth-child(1),
.worker-table td:nth-child(1) { width: 128px; }
.worker-table th:nth-child(2),
.worker-table td:nth-child(2) { width: 72px; }
.worker-table th:nth-child(3),
.worker-table td:nth-child(3) { width: 118px; }
.worker-table th:nth-child(4),
.worker-table td:nth-child(4) { width: 72px; }
.worker-table th:nth-child(5),
.worker-table td:nth-child(5) { width: 88px; }
.worker-table th:nth-child(6),
.worker-table td:nth-child(6) {
  width: 220px;
  white-space: normal;
}
.worker-table th:nth-child(7),
.worker-table td:nth-child(7) { width: 72px; }
.worker-table th:nth-child(8),
.worker-table td:nth-child(8) { width: 88px; }
.worker-table th:nth-child(9),
.worker-table td:nth-child(9) {
  width: 200px;
  white-space: normal;
}
.worker-table th:nth-child(10),
.worker-table td:nth-child(10) { width: 110px; }
.worker-table th:nth-child(11),
.worker-table td:nth-child(11) {
  width: 240px;
  white-space: normal;
  overflow: visible;
}

.worker-table .cell-clamp {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
  white-space: normal;
  word-break: break-word;
  line-height: 1.45;
  max-height: 2.9em;
}

.worker-table .row-actions {
  min-width: 0;
  max-width: 230px;
}

.row-action-cell {
  width: auto;
  min-width: 88px;
}

.check-line {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 8px 0;
  color: var(--muted);
}

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

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

#reportSummary.compact-stat-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.section-head--sub {
  margin-top: 18px;
}

.create-form,
.form-grid.create-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

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

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

.complaint-handle-block {
  display: grid;
  gap: 12px;
  padding: 12px;
  margin: 0 -4px;
  border-radius: 12px;
  border: 1px solid transparent;
  transition: border-color .15s ease, background .15s ease;
}

.complaint-handle-block.is-active {
  border-color: rgba(15, 118, 110, 0.28);
  background: rgba(15, 118, 110, 0.04);
}

/* 投诉保存条：贴在表单底部，避免滚出视野后找不到按钮 */
.complaint-action-bar {
  display: grid;
  gap: 5px;
  position: sticky;
  bottom: 0;
  z-index: 3;
  margin-top: 5px;
  padding: 10px 0 2px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), #fff 28%);
}

.complaint-action-bar__hint {
  font-size: 12px;
  line-height: 1.4;
  color: var(--muted);
}

.complaint-action-bar .action-btn {
  width: 100%;
}

.action-btn:disabled,
.action-btn[disabled] {
  opacity: 0.72;
  cursor: default;
  transform: none !important;
  box-shadow: none !important;
}

.complaint-form {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.complaint-form .field-hint {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
}

.complaint-refund-field {
  display: grid;
  gap: 8px;
}

.complaint-refund-cap {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(15, 107, 92, 0.22);
  background: #eef8f5;
  color: #0f6b5c;
  font-size: 13px;
  line-height: 1.5;
}

.complaint-refund-cap strong {
  font-size: 16px;
  font-weight: 700;
}

.complaint-refund-amount-label {
  display: grid;
  gap: 6px;
}

.date-segments {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  padding-right: 42px;
}

.date-segments__year {
  width: 5.2em;
  flex: 0 0 auto;
  text-align: center;
}

.date-segments__month,
.date-segments__day {
  width: 3.2em;
  flex: 0 0 auto;
  text-align: center;
}

.date-segments__sep {
  color: var(--muted);
  font-weight: 600;
  user-select: none;
}

.date-segments__btn {
  position: absolute;
  top: 50%;
  right: 4px;
  width: 34px;
  height: 34px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 8px;
  background: #f3f6f8 center / 16px 16px no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7c93' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cpath d='M16 2v4M8 2v4M3 10h18'/%3E%3C/svg%3E");
  cursor: pointer;
}

.date-segments__btn:hover {
  background-color: #e8eef2;
}

.date-segments__picker {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
  border: 0;
  padding: 0;
  margin: 0;
}

.field-span-2 {
  grid-column: span 2;
}

.field-span-3 {
  grid-column: span 3;
}

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

.skill-check-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f8fafb;
  min-height: 48px;
}

.skill-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  user-select: none;
  font-size: 13px;
  color: var(--text, #1f2933);
  transition: border-color .15s ease, background .15s ease, color .15s ease;
}

.skill-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.skill-check.is-on {
  border-color: #1f8a70;
  background: #e8f7f2;
  color: #0f5c4a;
  font-weight: 600;
}

.skill-empty {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.form-actions {
  display: flex;
  align-items: end;
}

.form-actions--row {
  gap: 8px;
}

.audit-guide {
  margin: 0 0 8px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #f3f8f6;
  border: 1px solid rgba(31, 122, 107, 0.16);
  color: #3d5560;
  line-height: 1.55;
}

.audit-summary {
  margin: 4px 0 12px;
}

.audit-table-wrap {
  margin-top: 4px;
  max-height: min(58vh, 640px);
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.audit-table {
  min-width: 1080px;
}

.audit-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  box-shadow: 0 1px 0 var(--line);
}

.audit-table th,
.audit-table td {
  padding: 10px 12px;
  font-size: 13px;
  vertical-align: middle;
}

.audit-table .audit-col-time {
  width: 118px;
  white-space: nowrap;
}

.audit-table .audit-col-cat {
  width: 96px;
  white-space: nowrap;
}

.audit-table .audit-col-action {
  min-width: 160px;
}

.audit-table .audit-col-target {
  width: 120px;
  white-space: nowrap;
}

.audit-table .audit-col-order {
  width: 140px;
  white-space: nowrap;
}

.audit-table .audit-col-operator {
  width: 168px;
  white-space: normal;
}

.audit-table .audit-col-detail {
  min-width: 240px;
  max-width: 420px;
  color: #445463;
  white-space: normal;
  line-height: 1.45;
}

.audit-table .audit-col-ops {
  width: 96px;
  white-space: nowrap;
}

.audit-time {
  display: grid;
  gap: 2px;
  line-height: 1.25;
}

.audit-time-date {
  color: var(--text);
  font-weight: 600;
}

.audit-time-clock {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
}

.audit-action-cell {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 8px;
}

.audit-action-cell strong {
  font-size: 13px;
  font-weight: 650;
  color: var(--text);
}

.audit-operator {
  display: grid;
  gap: 2px;
  line-height: 1.3;
}

.audit-operator-mobile {
  color: #14614f;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.audit-row--sensitive {
  background: #fffaf5;
}

.audit-row--sensitive:hover {
  background: #fff3e8;
}

.audit-feed {
  display: none;
}

.workspace-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 0;
  border: 1px solid rgba(31, 122, 107, 0.18);
  background:
    linear-gradient(135deg, rgba(230, 244, 241, 0.95), rgba(255, 255, 255, 0.98)),
    #fff;
}

.workspace-banner-main {
  flex: 1;
  min-width: 0;
}

.workspace-banner-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 12px;
  margin: 4px 0 6px;
}

.order-no-lock {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  cursor: default;
}

.workspace-banner-main h3 {
  margin: 0;
  font-size: 22px;
  line-height: 1.3;
}

.workspace-banner-title-row .badge {
  flex-shrink: 0;
  align-self: center;
}

.workspace-banner-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.resource-lock-bar {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 8px;
  max-width: 100%;
  margin-top: 10px;
  padding: 8px 0 0;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
}

.resource-lock-bar .lock-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #94a3b8;
}

.resource-lock-bar .lock-status-text {
  min-width: 0;
}

.resource-lock-bar.is-mine {
  color: #1f5c52;
}

.resource-lock-bar.is-mine .lock-status-dot {
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(31, 122, 107, 0.16);
}

.resource-lock-bar.is-occupied {
  color: #8a5a12;
}

.resource-lock-bar.is-occupied .lock-status-dot {
  background: var(--warn);
  box-shadow: 0 0 0 3px rgba(178, 106, 0, 0.14);
}

.resource-lock-bar .lock-actions {
  display: inline-flex;
  gap: 5px;
  margin-left: 4px;
  padding-left: 8px;
  border-left: 1px solid var(--line);
}

.resource-lock-bar .lock-action-btn {
  appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: 13px;
  line-height: 1.4;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.resource-lock-bar .lock-action-btn:hover {
  color: #166557;
}

.resource-lock-bar .lock-action-btn.is-warn {
  color: var(--warn);
}

.resource-lock-bar .lock-action-btn.is-warn:hover {
  color: #935600;
}

.btn.secondary-btn {
  background: #eef3f6;
  color: #385063;
  border: 1px solid #d7e1e8;
}

.modal-mask {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(18, 35, 43, 0.42);
  box-sizing: border-box;
}

.modal-mask[hidden] {
  display: none !important;
}

.modal-card {
  width: min(720px, 100%);
  max-height: min(82vh, 860px);
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(15, 42, 46, 0.18);
  box-sizing: border-box;
}

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

.modal-head h3 {
  margin: 4px 0 0;
}

.modal-list {
  overflow: auto;
  display: grid;
  gap: 10px;
  min-height: 180px;
  max-height: 48vh;
  padding: 4px 6px 4px 2px;
  box-sizing: border-box;
}

.modal-list-item {
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #f8fafb;
  cursor: pointer;
  box-sizing: border-box;
}

.modal-list-item.selected-card {
  outline: none;
  border-color: #1f7a6b;
  box-shadow: inset 0 0 0 1px rgba(31, 122, 107, 0.35);
  background: #f2faf8;
}

.modal-list-item:hover {
  background: #f2faf7;
}

.modal-list-item.selected-card:hover {
  background: #eef8f5;
}

.modal-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.modal-foot-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-left: auto;
}

.prompt-card {
  width: min(440px, 100%);
  position: relative;
  overflow: hidden;
  padding-top: 22px;
}

.app-dialog-card,
.partner-modal-card {
  animation: dialogRise 0.22s ease;
}

@keyframes dialogRise {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.app-dialog-accent {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 4px;
  background: linear-gradient(90deg, #1f7a6b 0%, #3aa38f 55%, #7bc4b4 100%);
}

.prompt-card #appDialogInput,
.app-dialog-field .input {
  margin-top: 0;
}

.app-dialog-field {
  display: grid;
  gap: 8px;
}

.app-dialog-field > span {
  color: var(--muted);
  font-size: 13px;
}

.prompt-message {
  margin: 0;
  color: var(--text);
  font-size: 15px;
  line-height: 1.65;
  white-space: pre-wrap;
}

.prompt-foot {
  justify-content: flex-end;
  margin-top: 4px;
}

.partner-modal-card {
  width: min(460px, 100%);
  position: relative;
  overflow: hidden;
  padding-top: 22px;
}

.partner-modal-user {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #f3faf8;
  border: 1px solid #d7ebe5;
}

.partner-modal-avatar {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #1f7a6b;
  color: #fff;
  font-size: 18px;
  font-weight: 600;
  flex-shrink: 0;
}

.partner-modal-user strong {
  display: block;
  color: var(--text);
  font-size: 16px;
}

.partner-modal-user .meta {
  margin: 4px 0 0;
}

.partner-rate-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

.partner-rate-unit {
  min-width: 42px;
  height: 42px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
}

.partner-rate-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.partner-rate-chip {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  font-size: 13px;
}

.partner-rate-chip:hover {
  border-color: #b7d8d0;
  background: #f5fbf9;
}

.partner-rate-chip.is-active {
  border-color: #1f7a6b;
  background: #e8f5f1;
  color: #14614f;
  font-weight: 600;
}

.account-form-card {
  width: min(520px, 100%);
}

.account-form .field {
  display: grid;
  gap: 6px;
}

.account-form .field > span {
  color: var(--muted);
  font-size: 13px;
}

.account-form .modal-foot {
  margin-top: 8px;
  padding-top: 4px;
}

.worker-form-card {
  width: min(760px, 100%);
  max-height: min(90vh, 920px);
  overflow: auto;
}

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

.worker-form .field {
  display: grid;
  gap: 6px;
}

.worker-form .field > span {
  color: var(--muted);
  font-size: 13px;
}

.worker-form .field-span-all {
  grid-column: 1 / -1;
}

.worker-form .modal-foot {
  margin-top: 12px;
}

@media (max-width: 760px) {
  .worker-form-grid {
    grid-template-columns: 1fr;
  }
}

.secret-card .secret-value-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 4px;
  padding: 14px 16px;
  border-radius: 12px;
  background: #f3f7f5;
  border: 1px solid rgba(31, 122, 107, 0.18);
}

.secret-card code {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #14614f;
  user-select: all;
}

.secret-copy-tip {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--muted);
}

.secret-copy-tip.is-ok {
  color: var(--ok);
}

.secret-copy-tip.is-warn {
  color: var(--warn);
}

@media (max-width: 900px) {
  .workspace-banner {
    flex-direction: column;
    align-items: stretch;
  }

  .workspace-banner-actions {
    justify-content: flex-end;
  }

  .modal-foot {
    flex-direction: column;
    align-items: stretch;
  }

  .modal-foot-actions {
    width: 100%;
  }

  .modal-foot-actions .btn {
    flex: 1;
  }
}

.btnx {
  display: none;
}

.table th {
  background: #f7f9fb;
}

.table tr:hover {
  background: #f5fbf9;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
}

.sidebar .brand-block h1 {
  font-size: 16px;
  padding: 0 14px;
}

.sidebar .brand-block p {
  color: #94a3b8;
  font-size: 12px;
  padding: 0 14px;
}

.sidebar .side-card {
  margin-left: 12px;
  margin-right: 12px;
}

.app-shell {
  grid-template-columns: 220px minmax(0, 1fr);
}

.sidebar {
  padding: 14px 0 20px;
  display: flex;
  flex-direction: column;
}

.nav-menu {
  margin-top: 12px;
  gap: 6px;
  padding: 0 10px;
  flex: 1;
  overflow-y: auto;
  align-content: start;
}

.nav-link {
  padding: 10px 12px;
  white-space: nowrap;
  word-break: keep-all;
  line-break: strict;
  overflow-wrap: normal;
}

.page-head {
  border-radius: 10px;
}

.page-head-row {
  width: 100%;
}

.page-head-copy {
  min-width: 0;
  flex: 1 1 auto;
}

.page-head-refresh,
.section-head > .btn,
.section-head > .btn.primary {
  flex: 0 0 auto;
}

.page-head-refresh-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex: 0 0 auto;
}

.auto-sync-hint {
  color: #6b7f86;
  font-size: 12px;
  line-height: 1.2;
}

.toast-host {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 120;
  display: grid;
  gap: 10px;
  width: min(360px, calc(100vw - 32px));
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 12px 28px rgba(18, 35, 43, 0.14);
  color: var(--text);
  line-height: 1.5;
  animation: toast-in 0.18s ease;
}

.toast.ok {
  border-color: rgba(20, 97, 79, 0.28);
  background: #f3faf7;
  color: var(--ok);
}

.toast.warn {
  border-color: rgba(178, 106, 0, 0.28);
  background: #fff8ef;
  color: var(--warn);
}

.toast-dot {
  width: 8px;
  height: 8px;
  margin-top: 6px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 auto;
}

.toast-text {
  flex: 1 1 auto;
  min-width: 0;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nav-accordion {
  display: grid;
  gap: 2px;
}

.nav-primary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-weight: 600;
}

.nav-chevron {
  width: 8px;
  height: 8px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  opacity: 0.7;
  transition: transform 0.22s ease;
  flex-shrink: 0;
}

.nav-accordion.is-open .nav-chevron {
  transform: rotate(45deg);
}

.nav-children {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.24s ease;
}

.nav-accordion.is-open .nav-children {
  grid-template-rows: 1fr;
}

.nav-children-inner {
  overflow: hidden;
  display: grid;
  gap: 2px;
  min-height: 0;
  padding: 0 0 0 10px;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.2s ease, transform 0.24s ease;
}

.nav-accordion.is-open .nav-children-inner {
  padding-bottom: 6px;
  opacity: 1;
  transform: translateY(0);
}

.nav-child {
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}

/* 中文短标题：禁止出现「三字+一字」孤行 */
.page-head h2,
.workspace-crumb,
.eyebrow,
.btn,
.action-btn,
.badge,
.dash-attention-pill,
.settle-anchor,
.nav-primary,
.stat-card span,
.dash-kpi span,
.dash-gauge-kicker {
  word-break: keep-all;
  line-break: strict;
  overflow-wrap: normal;
}

.btn,
.action-btn,
.badge,
.dash-attention-pill,
.settle-anchor {
  white-space: nowrap;
}

.section-panel {
  gap: 14px;
  align-content: start;
}

.panel {
  border-radius: 10px;
}

.button-row {
  gap: 8px;
}

.workspace-crumb {
  color: #94a3b8;
}

.content > .page-head h2 {
  color: #0f2a2e;
}

.dash-hero {
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(31, 138, 112, 0.12), transparent 42%),
    linear-gradient(180deg, #fbfcfd 0%, #f3f7f6 100%);
  border: 1px solid rgba(31, 122, 107, 0.1);
}

.dash-hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.dash-hero-copy {
  min-width: 0;
  flex: 1;
}

.dash-hero-copy .meta {
  margin-top: 6px;
}

.dash-attention {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.dash-attention-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #f7fafc;
  font-size: 13px;
}

.dash-attention-pill.warn {
  color: #b42318;
  background: #fff5f3;
  border-color: #e8b4a8;
}

.dash-attention-pill.ok {
  color: #14614f;
  background: #f3faf7;
  border-color: #cfe3dd;
}

.dash-attention-pill.soft {
  color: var(--muted);
}

.dash-load-gauge {
  flex-shrink: 0;
}

.dash-gauge {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  min-width: 280px;
  padding: 8px 20px 8px 8px;
  border: 1px solid rgba(31, 122, 107, 0.14);
  border-radius: 18px;
  background:
    radial-gradient(circle at 18% 50%, rgba(31, 138, 112, 0.08), transparent 55%),
    rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 20px rgba(15, 42, 46, 0.05);
}

.dash-gauge svg {
  width: 112px;
  height: 112px;
  flex-shrink: 0;
}

.dash-gauge-track {
  fill: none;
  stroke: rgba(31, 53, 71, 0.08);
  stroke-width: 11;
}

.dash-gauge-value {
  fill: none;
  stroke: #1f8a70;
  stroke-width: 11;
  stroke-linecap: round;
  transition: stroke-dashoffset .35s ease;
}

.dash-gauge--warm .dash-gauge-value { stroke: #d4a017; }
.dash-gauge--hot .dash-gauge-value { stroke: #c26d5a; }

.dash-gauge-number {
  fill: #0f2a2e;
  font-size: 28px;
  font-weight: 750;
}

.dash-gauge-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.dash-gauge-kicker {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.dash-gauge-copy strong {
  font-size: 22px;
  color: #0f2a2e;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.dash-gauge-copy span {
  font-size: 12px;
  color: var(--muted);
}

.dash-kpis {
  margin-top: 18px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.dash-kpi {
  width: 100%;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
  background: rgba(255, 255, 255, 0.92);
}

.dash-kpi-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.dash-kpi-top span {
  display: block;
  font-size: 12px;
  color: var(--muted);
}

.dash-kpi-top strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
  line-height: 1;
}

.dash-kpi-ring {
  width: 54px;
  height: 54px;
  flex-shrink: 0;
}

.dash-kpi-ring-track,
.dash-kpi-ring-value {
  fill: none;
  stroke-width: 5;
}

.dash-kpi-ring-track {
  stroke: #e6eef1;
}

.dash-kpi-ring-value {
  stroke-linecap: round;
}

.dash-kpi small {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
}

.dash-grid {
  display: grid;
  grid-template-columns: 1.35fr 0.95fr;
  gap: 14px;
  align-items: stretch;
  margin-top: 14px;
}

.dash-mix-panel,
.dash-hint-panel {
  min-height: 320px;
}

.dash-mix-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(200px, 0.8fr);
  gap: 20px;
  align-items: center;
}

.dash-mix-center {
  display: grid;
  gap: 10px;
  justify-items: center;
  align-content: center;
  padding: 8px 4px;
  min-height: 220px;
}

.dash-mix-donut {
  display: grid;
  place-items: center;
  width: 100%;
}

.dash-compact-donut {
  width: min(100%, 200px);
}

.dash-mix-donut-tip {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}

.dash-mix-legend,
.dash-mix-legend-item {
  display: none;
}

.dash-mix-row {
  display: grid;
  grid-template-columns: 10px minmax(68px, 88px) minmax(56px, 1fr) auto auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: left;
}

.dash-mix-row.is-urgent {
  border-color: rgba(194, 109, 90, 0.35);
  background: #fffaf8;
}

.dash-mix-row:hover {
  border-color: #1f7a6b;
}

.dash-mix-name {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text);
  white-space: nowrap;
}

.dash-mix-name em {
  font-style: normal;
  font-size: 10px;
  color: #b42318;
  background: #fff0ed;
  border: 1px solid #e8b4a8;
  border-radius: 999px;
  padding: 0 5px;
  line-height: 16px;
}

.dash-mix-swatch {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
  display: inline-block;
}

.dash-mix-track {
  display: block;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef2;
}

.dash-mix-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
}

.dash-mix-count {
  font-size: 14px;
  min-width: 1.2em;
  text-align: right;
}

.dash-mix-pct {
  font-size: 12px;
  color: var(--muted);
  min-width: 2.4em;
  text-align: right;
}

.dash-mix-center {
  display: grid;
  gap: 12px;
  justify-items: center;
  align-content: start;
  padding: 8px 4px;
}

.dash-mix-donut {
  display: grid;
  justify-items: center;
}

.dash-compact-donut {
  width: min(100%, 168px);
}

.dash-mix-legend {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  width: 100%;
  max-width: 220px;
}

.dash-mix-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.dash-mix-side {
  display: grid;
  min-width: 0;
  align-content: stretch;
}

.dash-side-block {
  height: 100%;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.dash-side-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.dash-side-head strong {
  font-size: 14px;
}

.dash-side-head span {
  font-size: 12px;
  color: var(--muted);
}

.dash-side-list {
  display: grid;
  gap: 8px;
}

.dash-side-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f8fbfa;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: left;
}

.dash-side-item:hover {
  border-color: #1f7a6b;
}

.dash-side-item__main {
  min-width: 0;
  flex: 1;
}

.dash-side-item__title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
}

.dash-side-item__title span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-side-item__title strong {
  margin-left: auto;
}

.dash-side-item__desc {
  margin-top: 4px;
  font-size: 12px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-side-link {
  flex-shrink: 0;
  font-size: 12px;
  color: #1f8a70;
  font-weight: 600;
}

@media (max-width: 1100px) {
  .dash-mix-layout {
    grid-template-columns: minmax(240px, 1fr) minmax(200px, 260px);
  }

  .dash-mix-side {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .dash-mix-layout {
    grid-template-columns: 1fr;
  }

  .dash-mix-bars {
    max-width: none;
  }
}

.dash-queue,
.dash-alerts,
.dash-shortcuts {
  display: grid;
  gap: 10px;
}

.dash-queue-panel > .section-head {
  margin-bottom: 14px;
}

.settle-anchors {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.settle-anchor {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  text-decoration: none;
  font-size: 13px;
}

.settle-anchor:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.settle-block {
  scroll-margin-top: 18px;
}

.settle-export-toolbar .btn.primary {
  min-height: 40px;
  padding: 0 16px;
  font-weight: 600;
}

.settle-export-hint {
  margin: 0 0 12px;
  color: #5a7380;
  font-size: 13px;
  line-height: 1.45;
}

.settle-filter-bar {
  margin: 8px 0 6px;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.settle-status-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.settle-status-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: #445463;
  font: inherit;
  cursor: pointer;
}

.settle-status-tab span {
  color: var(--muted);
  font-size: 12px;
}

.settle-status-tab.is-active {
  border-color: rgba(15, 107, 92, 0.35);
  background: #eef8f5;
  color: #0f6b5c;
  font-weight: 650;
}

.settle-status-tab.is-active span {
  color: #0f6b5c;
}

.settle-list-meta {
  margin: 0 0 8px;
}

/* 结算/提成表：已有分页，不再表内限高套滚动条；宽表仅保留横向滚动 */
.settle-table-wrap {
  max-height: none;
  overflow-x: auto;
  overflow-y: visible;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.settle-table-wrap .table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  box-shadow: 0 1px 0 var(--line);
}

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

.audit-pager {
  flex-wrap: wrap;
}

.audit-pager .slim-select {
  min-width: 118px;
}

.settle-pager-text {
  color: var(--muted);
  font-size: 13px;
}

.dash-queue-item,
.dash-alert,
.dash-shortcut {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  text-align: left;
}

.dash-queue-item.is-urgent {
  border-color: #e8b4a8;
  background: #fffaf8;
}

.dash-queue-main {
  min-width: 0;
  flex: 1;
}

.dash-queue-main strong {
  display: block;
  margin-bottom: 4px;
}

.dash-queue-side {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex: 0 0 auto;
  align-self: center;
}

#complaintDeskList .dash-queue-item {
  align-items: center;
}

#complaintDeskList .dash-queue-side {
  flex-wrap: nowrap;
  white-space: nowrap;
}

.dash-queue-side .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: nowrap;
}

.dash-queue-side .btn {
  flex: 0 0 auto;
  justify-content: center;
}

.dash-shortcut,
.dash-alert {
  width: 100%;
  cursor: pointer;
  font: inherit;
  color: inherit;
}

.dash-shortcut {
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  background:
    linear-gradient(180deg, #fbfcfd, #f5f8f7);
}

.dash-shortcut:hover,
.dash-alert:hover,
.dash-kpi:hover {
  border-color: #1f7a6b;
  box-shadow: 0 8px 18px rgba(15, 42, 46, 0.07);
}

.dash-shortcut strong {
  font-size: 15px;
}

.dash-shortcut span,
.dash-alert .list-desc {
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 1100px) {
  .dash-kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .dash-grid,
  .dash-grid--main,
  .dash-mix-layout {
    grid-template-columns: 1fr;
  }

  .dash-hero-top {
    flex-direction: column;
    align-items: stretch;
  }

  .dash-gauge {
    align-self: flex-start;
  }
}

@media (max-width: 760px) {
  .dash-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dash-queue-item {
    flex-direction: column;
    align-items: stretch;
  }

  .dash-queue-side {
    width: 100%;
    justify-content: center;
  }
}

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

  .field-span-2,
  .field-span-3 {
    grid-column: span 2;
  }

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

@media (max-width: 760px) {
  .create-form,
  .form-grid.create-form {
    grid-template-columns: 1fr;
  }

  .field-span-2,
  .field-span-3 {
    grid-column: span 1;
  }
}

.content-docs {
  display: grid;
  gap: 10px;
}

.content-doc {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfcfd;
  overflow: hidden;
}

.content-doc.is-open {
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(31, 122, 107, 0.18);
}

.content-doc-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.content-doc-toggle:hover {
  background: rgba(31, 122, 107, 0.04);
}

.content-doc-toggle-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.content-doc-toggle-main strong {
  color: var(--text);
  font-size: 15px;
}

.content-doc-toggle-main span {
  color: var(--muted);
  font-size: 12px;
}

.content-doc-arrow {
  flex-shrink: 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  transition: transform 0.18s ease;
}

.content-doc.is-open .content-doc-arrow {
  transform: rotate(90deg);
  color: var(--accent);
}

.content-doc-body {
  display: none;
  padding: 0 16px 16px;
}

.content-doc.is-open .content-doc-body {
  display: grid;
  gap: 10px;
}

.content-doc textarea {
  min-height: 120px;
  resize: vertical;
}

.settings-hub-tip {
  margin: 0 0 14px;
}

.settings-accordion {
  display: grid;
  gap: 10px;
}

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

.settings-item.is-open {
  box-shadow: 0 8px 20px rgba(15, 42, 46, 0.06);
}

.settings-item-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.settings-item-toggle:hover {
  background: rgba(31, 122, 107, 0.04);
}

.settings-item-text {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.settings-item-eyebrow {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.04em;
}

.settings-item-text strong {
  color: var(--text);
  font-size: 16px;
}

.settings-item-desc {
  color: var(--muted);
  font-size: 13px;
}

.settings-item-arrow {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 18px;
  line-height: 1;
  transition: transform 0.18s ease;
}

.settings-item.is-open .settings-item-arrow {
  transform: rotate(90deg);
}

.settings-item-body {
  display: none;
  padding: 0 18px 18px;
  border-top: 1px solid transparent;
}

.settings-item.is-open .settings-item-body {
  display: grid;
  gap: 12px;
  border-top-color: var(--line);
  padding-top: 16px;
}

.settings-item-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.settings-item-actions--split {
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.settings-item-actions--split > strong,
.settings-item-actions--split > .membership-plan-meta {
  flex: 1 1 auto;
  min-width: 0;
  margin-right: 12px;
  line-height: 1.4;
}

.settings-item-actions--split > .btn {
  flex: 0 0 auto;
  white-space: nowrap;
}

.exception-modal-card {
  width: min(720px, 100%);
  max-height: min(86vh, 900px);
}

.exception-modal-card .exception-detail {
  display: grid;
  gap: 18px;
  overflow: auto;
  padding-right: 2px;
  max-height: min(58vh, 560px);
}

.exception-sections {
  display: grid;
  gap: 16px;
}

.exception-note-box {
  padding: 16px 18px;
  border-radius: 12px;
  background: linear-gradient(180deg, #f7fbfa 0%, #f3f6f8 100%);
  border: 1px solid #dce8e4;
}

.exception-note-label {
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--muted);
}

.exception-note-text {
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-word;
}

.exception-note-meta {
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
}

.exception-section {
  display: grid;
  gap: 0;
}

.exception-section-title {
  margin-bottom: 4px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--muted);
}

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

.exception-kv:last-child {
  border-bottom: 0;
}

.exception-kv span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.exception-kv strong {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.55;
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-word;
}

.exception-empty,
.exception-empty-inline,
.exception-pending-tip {
  padding: 14px 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.exception-pending-tip {
  padding: 12px 14px;
  border-radius: 10px;
  background: #fff8ef;
  border: 1px solid #f0dfc4;
  color: #8a5a12;
}

.catalog-toolbar {
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
}

.catalog-toolbar .input,
.catalog-toolbar .input + .input,
.catalog-toolbar .btn {
  margin-top: 0;
  width: auto;
  flex: 0 0 auto;
}

.catalog-toolbar .slim-select {
  min-width: 118px;
  width: auto;
}

.catalog-cover-thumb {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  display: block;
  background: #edf2f4;
}

.cover-upload-row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-top: 8px;
}

.cover-upload-preview {
  width: 112px;
  height: 112px;
  border-radius: 12px;
  object-fit: cover;
  background: #edf2f4;
  border: 1px solid #d7e3e6;
  flex-shrink: 0;
  display: block;
}

.cover-upload-preview-wrap {
  width: 112px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cover-upload-meta {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  color: #5f7378;
}

.cover-upload-actions {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field-hint {
  margin: 0;
  color: #6d828c;
  font-size: 12px;
  line-height: 1.5;
}

.home-banner-editor {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.home-banner-card {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 14px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid #dce7ea;
  background: #f8fbfb;
}

.home-banner-card__preview {
  width: 140px;
  height: 84px;
  border-radius: 10px;
  overflow: hidden;
  background: #e7eef0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.home-banner-card__preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.home-banner-card__fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.home-banner-card__fields .field:nth-child(4),
.home-banner-card__fields .field:nth-child(5) {
  grid-column: 1 / -1;
}

@media (max-width: 900px) {
  .home-banner-card {
    grid-template-columns: 1fr;
  }
}

.home-entry-card__preview {
  width: 84px;
  height: 84px;
}

.home-entry-editor .home-banner-card {
  grid-template-columns: 84px 1fr;
}

.membership-plan-form {
  display: grid;
  gap: 14px;
}

.membership-plan-block {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfcfd;
  padding: 14px 14px 16px;
}

.membership-plan-block__title {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink, #1f2a2e);
}

.membership-plan-grid {
  display: grid;
  gap: 12px;
}

.membership-plan-grid--base {
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 0.8fr));
}

.membership-plan-grid--base .membership-plan-regions {
  grid-column: 1 / -1;
}

.membership-plan-grid--quota {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.membership-plan-grid--notice {
  grid-template-columns: 1fr;
}

.membership-plan-form .field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.membership-plan-form .field > span {
  font-size: 12px;
  color: var(--muted);
}

.membership-plan-actions {
  margin-top: 4px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.membership-plan-meta {
  font-size: 12px;
}

@media (max-width: 1100px) {
  .membership-plan-grid--base {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .membership-plan-grid--base .membership-plan-name,
  .membership-plan-grid--base .membership-plan-regions {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .membership-plan-grid--base,
  .membership-plan-grid--quota {
    grid-template-columns: 1fr;
  }

  .membership-plan-grid--base .membership-plan-name,
  .membership-plan-grid--base .membership-plan-regions {
    grid-column: auto;
  }
}

/* ���ȳ� */
.pool-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 4px 0 16px;
}
.pool-stat {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  width: 100%;
  padding: 16px 18px;
  border-radius: 14px;
  border: 1px solid #d7e6ea;
  background: #fff;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
}
.pool-stat span {
  font-size: 13px;
  color: var(--muted);
}
.pool-stat strong {
  font-size: 28px;
  line-height: 1.1;
  color: #173944;
}
.pool-stat small {
  font-size: 12px;
  color: #7a929c;
}
.pool-stat.is-active {
  border-color: #1f7a6b;
  background: #f3faf8;
  box-shadow: 0 8px 20px rgba(31, 122, 107, 0.08);
}
.pool-stat--plain {
  cursor: default;
  background: #f7fafb;
}
.pool-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}
.pool-tab {
  min-height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid #d7e6ea;
  background: #fff;
  color: #587285;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.pool-tab.is-active {
  background: #1f7a6b;
  border-color: #1f7a6b;
  color: #fff;
}
.pool-action-cell {
  width: auto !important;
  min-width: 220px;
  white-space: nowrap;
  text-align: left;
  vertical-align: middle;
}
.pool-action-cell .row-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 6px 0 0;
  vertical-align: middle;
}
.pool-action-cell .row-action-btn:last-child {
  margin-right: 0;
}
.row-action-btn.secondary {
  background: #f4f8fb;
  border-color: #d7e3ea;
  color: #1f2937;
}
.row-action-btn.ghost {
  background: transparent;
  border-color: #d7e6ea;
  color: #587285;
}
#poolTable td:nth-child(7) {
  white-space: nowrap;
  min-width: 110px;
}
@media (max-width: 900px) {
  .pool-summary {
    grid-template-columns: 1fr;
  }
}

/* 财务结算锁单：独立卡片，避免说明文案与按钮挤在两列 button-row 里被撑高 */
#detailActions:has(.settlement-box) {
  display: block;
  grid-template-columns: none;
}

.settlement-box {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid #d7e3ea;
  background: #f8fbfc;
}

.settlement-box--locked {
  border-color: rgba(212, 136, 48, 0.35);
  background: #fffaf3;
}

.settlement-box--paid {
  border-color: rgba(31, 122, 107, 0.28);
  background: #f4faf8;
}

.settlement-box__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.settlement-box__title {
  font-size: 15px;
  font-weight: 700;
  color: #17333a;
}

.settlement-box__desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  color: #5b7280;
  text-align: left;
}

.settlement-box__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.settlement-box__actions .action-btn {
  width: auto;
  min-width: 108px;
  min-height: 36px;
  padding: 0 14px;
  align-self: start;
}

.settlement-box__actions--extra {
  margin-top: 8px;
}

.settlement-box--locked .settlement-box__actions .action-btn.secondary-btn {
  background: #fff !important;
  border-color: rgba(181, 106, 18, 0.45) !important;
  color: #b56a12 !important;
}
