/* ===== 项目状态卡：项目页分区 + 首页重点项目卡的健康度/阶段/新鲜度（MTK-007） ===== */
.status-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}
.status-card-warning {
  margin: 0;
  padding: 12px 15px;
  border-radius: 10px;
  border: 1px solid #fde68a;
  background: #fffbeb;
  color: #b45309;
  font-size: 13px;
  font-weight: 550;
  line-height: 1.65;
}
:root[data-theme=dark] .status-card-warning {
  border-color: #78350f;
  background: #451a03;
  color: #fcd34d;
}
.status-card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.health-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid var(--line);
  background: var(--soft);
  color: var(--ink-strong);
  white-space: nowrap;
}
.health-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.health-badge--on_track {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
}
.health-badge--at_risk {
  background: #fffbeb;
  border-color: #fde68a;
  color: #b45309;
}
.health-badge--blocked {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #be123c;
}
.health-badge--paused {
  background: #f5f3ff;
  border-color: #ddd6fe;
  color: #6d28d9;
}
:root[data-theme=dark] .health-badge--on_track {
  background: #064e3b;
  border-color: #065f46;
  color: #34d399;
}
:root[data-theme=dark] .health-badge--at_risk {
  background: #451a03;
  border-color: #78350f;
  color: #fcd34d;
}
:root[data-theme=dark] .health-badge--blocked {
  background: #4c0519;
  border-color: #881337;
  color: #fda4af;
}
:root[data-theme=dark] .health-badge--paused {
  background: #2e1065;
  border-color: #4c1d95;
  color: #c4b5fd;
}
.status-card-phase {
  font-size: 14.5px;
  font-weight: 700;
  line-height: 1.55;
  color: var(--text);
  min-width: 0;
  overflow-wrap: anywhere;
}
.status-card-updated {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.status-card-source {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-link);
}
.status-card-source svg {
  width: 12px;
  height: 12px;
}
.status-card-hint {
  margin: 0;
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
}
.status-card--missing .empty-state,
.status-card--invalid .empty-state {
  margin: 0;
}
.status-card--invalid {
  gap: 8px;
}
.status-card-error-title {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: #be123c;
}
:root[data-theme=dark] .status-card-error-title {
  color: #fda4af;
}
.status-card-errors {
  margin: 0;
  padding: 12px 15px 12px 28px;
  border-radius: 10px;
  border: 1px dashed #fecdd3;
  background: #fff1f2;
  color: #9f1239;
  font-size: 13px;
  line-height: 1.75;
}
:root[data-theme=dark] .status-card-errors {
  border-color: #881337;
  background: #4c0519;
  color: #fda4af;
}
.status-card-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}
.status-card-group-title {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.8px;
  color: var(--muted);
  font-weight: 700;
}
.status-card-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.status-card-item {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--soft);
  min-width: 0;
}
.status-card-item-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.status-card-item-title {
  font-size: 14px;
  font-weight: 650;
  line-height: 1.55;
  color: var(--ink-strong);
  overflow-wrap: anywhere;
}
.status-card-ref {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-link);
  overflow-wrap: anywhere;
}
.status-card-ref svg {
  width: 12px;
  height: 12px;
}
.status-card-state,
.status-card-kind,
.status-card-flag {
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  white-space: nowrap;
}
.status-card-state--developing {
  color: #047857;
  background: #ecfdf5;
  border-color: #a7f3d0;
}
.status-card-state--review {
  color: #1d4ed8;
  background: #eff6ff;
  border-color: #bfdbfe;
}
.status-card-state--waiting_owner {
  color: #b45309;
  background: #fffbeb;
  border-color: #fde68a;
}
.status-card-state--blocked {
  color: #be123c;
  background: #fff1f2;
  border-color: #fecdd3;
}
.status-card-state--verifying {
  color: #6d28d9;
  background: #f5f3ff;
  border-color: #ddd6fe;
}
:root[data-theme=dark] .status-card-state--developing {
  color: #34d399;
  background: #064e3b;
  border-color: #065f46;
}
:root[data-theme=dark] .status-card-state--review {
  color: #93c5fd;
  background: #1e3a8a;
  border-color: #1d4ed8;
}
:root[data-theme=dark] .status-card-state--blocked {
  color: #fda4af;
  background: #4c0519;
  border-color: #881337;
}
.status-card-flag--maybe-done {
  color: #b45309;
  background: #fffbeb;
  border-color: #fde68a;
}
.status-card-flag--unknown {
  color: #b45309;
  background: #fffbeb;
}
:root[data-theme=dark] .status-card-flag--maybe-done {
  color: #fcd34d;
  background: #451a03;
  border-color: #78350f;
}
.status-card-architecture {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.status-card-architecture a {
  color: var(--ink-link);
  font-weight: 600;
}

/* 首页重点项目卡：健康度、phase、新鲜度 */
.project-status-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 2px 0 0;
  min-width: 0;
}
.project-status-line .health-badge {
  flex-shrink: 0;
}
.project-status-phase {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink-strong);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  flex: 1 1 190px;
  min-width: 0;
}
.project-status-freshness {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
.project-status-freshness.is-stale {
  color: #b45309;
  font-weight: 700;
}
:root[data-theme=dark] .project-status-freshness.is-stale {
  color: #fcd34d;
}
.project-status-line--muted,
.project-status-line--warn {
  display: block;
  font-size: 12.5px;
  color: var(--muted);
}
.project-status-line--warn {
  color: #be123c;
  font-weight: 600;
}
:root[data-theme=dark] .project-status-line--warn {
  color: #fda4af;
}
.status-card-summary-note {
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px dashed var(--focus-line);
  background: var(--soft);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
