/* ============================================================
   LIMS Workbench — v3 shared component styles
   Extracted from 设计稿/assets/v3.css for cross-role reuse.
   Only generic panel/drawer/table/utility styles, no role-specific.
   ============================================================ */

/* ----- Section title ---------------------------------------- */
.section-title {
  display: flex; align-items: baseline; gap: 10px;
  margin: 20px 0 12px;
}
.section-title h2 {
  font-size: 15px;
  font-weight: 600;
  margin: 0;
  letter-spacing: -0.01em;
}
.section-title .count {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-3);
  background: var(--surface-3);
  padding: 1px 7px;
  border-radius: 4px;
}
.section-title .spacer { flex: 1; }
.section-title .meta { font-size: 12px; color: var(--ink-3); }

/* ----- Panel ------------------------------------------------ */
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.panel-head {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}
.panel-head h3 {
  margin: 0; font-size: 14px; font-weight: 600;
  letter-spacing: -0.005em;
}
.panel-head .count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
  background: var(--surface-3);
  padding: 1px 6px;
  border-radius: 4px;
}
.panel-head .spacer { flex: 1; }
.panel-head .meta { font-size: 11.5px; color: var(--ink-3); }

/* ----- Utility ---------------------------------------------- */
.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; }
.avatar-sm {
  width: 22px; height: 22px; border-radius: 50%;
  background: linear-gradient(135deg, #cbd5e1, #94a3b8);
  color: white; font-size: 10.5px; font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.avatar-md {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white; font-size: 11.5px; font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

/* ----- Score gauge ------------------------------------------ */
.score-gauge {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.score-gauge .score {
  font-family: var(--font-mono);
  font-size: 56px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.04em;
}
.score-gauge .lbl {
  font-size: 11px;
  color: var(--ink-3);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.score-gauge .delta {
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--ink-3);
  margin-top: 2px;
}
.score-gauge .delta.down { color: var(--st-overdue); }
.score-gauge .delta.up   { color: var(--st-ok); }

/* ----- Health bars ------------------------------------------ */
.health-bars { display: flex; flex-direction: column; gap: 10px; }
.health-bar {
  display: grid;
  grid-template-columns: 100px 1fr 60px;
  gap: 12px;
  align-items: center;
  font-size: 12px;
}
.health-bar .label { color: var(--ink-3); }
.health-bar .track {
  height: 8px; background: var(--surface-3); border-radius: 4px; overflow: hidden;
  position: relative;
}
.health-bar .track i { display: block; height: 100%; border-radius: 4px; }
.health-bar .track i.red    { background: var(--st-overdue); }
.health-bar .track i.amber  { background: var(--st-due); }
.health-bar .track i.green  { background: var(--st-ok); }
.health-bar .track i.blue   { background: var(--st-active); }
.health-bar .val {
  text-align: right;
  font-family: var(--font-mono);
  font-weight: 600;
}
.health-bar .val.red   { color: var(--st-overdue); }
.health-bar .val.amber { color: var(--st-due); }
.health-bar .val.green { color: var(--st-ok); }

/* ----- Generic list rows ------------------------------------ */
.row-list {}
.row-item {
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-soft);
  display: grid;
  gap: 12px;
  align-items: center;
  cursor: pointer;
  transition: background .12s;
}
.row-item:hover { background: var(--surface-2); }
.row-item:last-child { border-bottom: 0; }
