.cash-close-form { max-width: 420px; margin: 16px auto; padding: 16px; }
.cash-close-form label { display: block; margin: 12px 0 4px; font-weight: 600; }
.cash-close-form input[type="number"], .cash-close-form textarea {
  width: 100%; padding: 10px; font-size: 18px; border: 1px solid #ccc; border-radius: 6px;
}
.cash-close-form .float-locked { background: #f0f0f0; color: #666; }
.cash-close-form button.submit {
  width: 100%; padding: 14px; margin-top: 16px; font-size: 18px; font-weight: 700;
  background: #2563eb; color: white; border: 0; border-radius: 6px;
}
/* ok-message rendered as direct child of `container` (replaces form on
   submit success and approved state). Do NOT prefix with .cash-close-form. */
.ok-message { padding: 16px; background: #dcfce7; color: #166534; border-radius: 6px; }
.cash-close-form .disputed-card {
  padding: 12px; background: #fef2f2; color: #991b1b; border-radius: 6px; margin-bottom: 12px;
}

/* ----- Verify queue (consumed by verify.js) ----- */
/* Scope header: finance只核对现金, 总账走Square KPI. UI affordance to
   prevent finance from looking for accounting/总账 data on this surface. */
.finance-scope-header {
  padding: 12px 0 14px; border-bottom: 1px solid #e5e7eb; margin-bottom: 4px;
}
.finance-scope-title {
  font-size: 18px; font-weight: 700; margin: 0 0 4px 0;
  color: var(--color-text, #111827);
}
.finance-scope-hint {
  font-size: 12px; color: var(--color-text-muted, #6b7280);
}
.finance-toolbar { display: flex; gap: 8px; padding: 12px 0; }
.finance-toolbar button {
  padding: 8px 16px; font-size: 14px; cursor: pointer;
  background: #f3f4f6; color: #111827; border: 1px solid #d1d5db; border-radius: 6px;
}
.finance-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.finance-table th, .finance-table td {
  padding: 8px 10px; border-bottom: 1px solid #e5e7eb; text-align: left;
}
.finance-table th { background: #f9fafb; font-weight: 600; }
.finance-table td.num { text-align: right; font-variant-numeric: tabular-nums; }
.finance-table button.approve {
  margin-right: 4px; padding: 4px 10px; background: #16a34a; color: white;
  border: 0; border-radius: 4px; cursor: pointer;
}
.finance-table button.dispute {
  padding: 4px 10px; background: #dc2626; color: white;
  border: 0; border-radius: 4px; cursor: pointer;
}
/* Variance severity (mirrors domain classifySeverity 100/500/3000 thresholds). */
.sev-matched { color: #166534; }     /* green:  |variance| ≤ 100 */
.sev-low     { color: #ca8a04; }     /* amber:  ≤ 500 */
.sev-medium  { color: #ea580c; }     /* orange: ≤ 3000 */
.sev-high    { color: #dc2626; font-weight: 700; }  /* red: > 3000 */
/* gold_cash_close_v emits MATCHED/MINOR/MAJOR/EXTREME — class form mirrors raw label. */
.sev-minor   { color: #ca8a04; }
.sev-major   { color: #ea580c; }
.sev-extreme { color: #dc2626; font-weight: 700; }

/* ----- Cart-Day card (Schedule day-detail anchor, consumed by card.js) ----- */
.cc-day-panel {
  margin-top: 16px; padding: 14px; border: 1px solid var(--color-border, #e5e7eb);
  border-radius: 8px; background: var(--color-card, #fff);
}
.cc-day-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.cc-day-title  { font-weight: 600; font-size: 14px; color: var(--color-text, #111827); }
.cc-day-badge  { font-size: 11px; padding: 3px 8px; border-radius: 999px; font-weight: 600; }
.cc-badge-empty    { background: #f3f4f6; color: #6b7280; }
.cc-badge-pending  { background: #fef3c7; color: #92400e; }
.cc-badge-approved { background: #dcfce7; color: #166534; }
.cc-badge-disputed { background: #fee2e2; color: #991b1b; }
.cc-day-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
  padding: 8px 0; border-bottom: 1px solid var(--color-border-light, #f1f5f9);
}
.cc-day-grid .cc-k { font-size: 11px; color: var(--color-text-muted, #6b7280); margin-bottom: 2px; }
.cc-day-grid .cc-v { font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cc-day-meta { padding: 8px 0; font-size: 12px; color: var(--color-text-secondary, #4b5563); line-height: 1.6; }
.cc-day-meta .cc-dispute { color: #991b1b; margin-top: 4px; }
.cc-day-actions { display: flex; gap: 8px; margin-top: 8px; }
.cc-btn { flex: 1; padding: 8px 12px; font-size: 13px; font-weight: 600; border: 0; border-radius: 6px; cursor: pointer; }
.cc-btn-approve { background: #16a34a; color: white; }
.cc-btn-dispute { background: #dc2626; color: white; }
.cc-btn-submit  { background: #2563eb; color: white; }
.cc-day-hint    { font-size: 12px; color: var(--color-text-muted, #6b7280); }
/* POS variance line (reference, not approval gate). Severity color uses .sev-* classes. */
.cc-day-variance {
  margin-top: 8px; padding: 6px 10px; font-size: 12px; font-variant-numeric: tabular-nums;
  background: #f9fafb; border-radius: 6px;
}

/* ----- Workflow stepper (SoD chain visualization) ----- */
.cc-stepper {
  list-style: none; padding: 12px 0; margin: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
  border-bottom: 1px solid var(--color-border-light, #f1f5f9);
}
.cc-step { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cc-step-marker { display: flex; align-items: center; gap: 0; }
.cc-step-dot {
  width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0;
  border: 2px solid #d1d5db; background: #fff; box-sizing: border-box;
}
.cc-step-dot.cc-step-done   { background: #16a34a; border-color: #16a34a; }
.cc-step-dot.cc-step-active { background: #fbbf24; border-color: #f59e0b;
  box-shadow: 0 0 0 4px rgba(251, 191, 36, 0.2); }
.cc-step-dot.cc-step-reject { background: #dc2626; border-color: #dc2626; }
.cc-step-dot.cc-step-wait   { background: #fff; border-color: #d1d5db; }
.cc-step-line {
  flex: 1; height: 2px; margin: 0 4px; min-width: 12px;
}
.cc-step-line.cc-step-line-active { background: #16a34a; }
.cc-step-line.cc-step-line-wait   { background: #e5e7eb; }
.cc-step-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cc-step-label {
  font-size: 11px; font-weight: 600; color: var(--color-text-secondary, #4b5563);
  text-transform: none;
}
.cc-step-who {
  display: flex; align-items: center; gap: 6px; font-size: 12px;
  color: var(--color-text, #111827); overflow: hidden;
}
.cc-step-who span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-step-who.cc-step-pending { color: var(--color-text-muted, #9ca3af); font-style: italic; }
.cc-step-when {
  font-size: 10px; color: var(--color-text-muted, #6b7280);
  font-variant-numeric: tabular-nums;
}
.cc-dispute {
  margin-top: 8px; padding: 8px 10px; background: #fef2f2; color: #991b1b;
  border-radius: 6px; font-size: 12px;
}

/* ----- Overview pending-close summary card (read-only) ----- */
.cc-overview-card {
  margin: 12px 0; padding: 14px; border: 1px solid var(--color-border, #e5e7eb);
  border-radius: 8px; background: var(--color-card, #fff);
}
.cc-overview-header {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px;
}
.cc-overview-title { font-weight: 600; font-size: 14px; }
.cc-overview-count {
  background: #fef3c7; color: #92400e; font-size: 11px; font-weight: 600;
  padding: 3px 8px; border-radius: 999px;
}
.cc-overview-row {
  display: flex; align-items: center; gap: 10px; padding: 8px 0;
  border-top: 1px solid var(--color-border-light, #f1f5f9); cursor: pointer;
}
.cc-overview-row:first-of-type { border-top: 0; }
.cc-overview-row:hover { background: #fafafa; }
.cc-overview-date { font-size: 13px; font-weight: 600; min-width: 80px; }
.cc-overview-meta {
  flex: 1; display: flex; align-items: center; gap: 6px; font-size: 12px;
  color: var(--color-text-secondary, #4b5563); overflow: hidden;
}
.cc-overview-arrow {
  color: var(--color-text-muted, #9ca3af); font-size: 14px;
}
.cc-overview-empty {
  font-size: 12px; color: var(--color-text-muted, #6b7280); text-align: center; padding: 8px 0;
}

/* ----- Weekly pill status dot (Overview 本周出车) ----- */
.cc-pill-badge {
  position: absolute; top: 6px; right: 6px;
  width: 7px; height: 7px; border-radius: 50%;
  box-shadow: 0 0 0 2px var(--color-card, #fff);
  pointer-events: none;
}
.cc-pill-badge.cc-pill-pending  { background: #f59e0b; }
.cc-pill-badge.cc-pill-approved { background: #16a34a; }
.cc-pill-badge.cc-pill-disputed { background: #dc2626; }

/* ----- Today KPI hero cash-close badge ----- */
.cc-today-badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 600; padding: 4px 10px; border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.cc-today-badge.cc-today-approved { background: #dcfce7; color: #166534; }
.cc-today-badge.cc-today-pending  { background: #fef3c7; color: #92400e; }
.cc-today-badge.cc-today-disputed { background: #fee2e2; color: #991b1b; }

/* ----- Calendar cell status badge (Schedule month grid) ----- */
.cc-cell-badge {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  margin-left: 4px; vertical-align: middle;
}
.cc-cell-badge.cc-cell-pending  { background: #f59e0b; }
.cc-cell-badge.cc-cell-approved { background: #16a34a; }
.cc-cell-badge.cc-cell-disputed { background: #dc2626; }
