:root {
  --bg: #f4f6f8;
  --ink: #17202a;
  --muted: #5a6573;
  --line: #d7dde6;
  --panel: #ffffff;
  --blue: #1f6feb;
  --blue-soft: #eaf2ff;
  --green: #16815b;
  --green-soft: #e8f7ef;
  --red: #b83d42;
  --red-soft: #fdecee;
  --shadow: 0 1px 2px rgba(21, 32, 43, 0.05);
}

body { 
  margin: 0; 
  background: var(--bg); 
  color: var(--ink); 
  font-family: system-ui, -apple-system, sans-serif; 
}

.shell { 
  width: min(1240px, calc(100% - 32px)); 
  margin: 0 auto; 
  padding: 26px 0 44px; 
}

.masthead { 
  display: flex; 
  justify-content: space-between; 
  align-items: flex-end; 
  padding-bottom: 18px; 
  border-bottom: 1px solid var(--line); 
}

.eyebrow, .label { 
  margin: 0 0 6px; 
  color: var(--muted); 
  font-size: 12px; 
  font-weight: 800; 
  text-transform: uppercase; 
}

h1 { margin: 0; font-size: 32px; }
h2 { margin: 0; font-size: 24px; }
h3 { margin: 0; font-size: 20px; }
h4 { margin: 0 0 8px 0; font-size: 14px; color: var(--muted); text-transform: uppercase; }

.readout { 
  display: flex; 
  justify-content: space-between; 
  padding: 20px 0; 
  border-bottom: 1px solid var(--line); 
}

.disclosure { 
  color: var(--muted); 
  font-size: 13px; 
  max-width: 300px; 
  text-align: right; 
  margin: 0;
}

.system-tabs { 
  display: flex; 
  gap: 8px; 
  margin: 20px 0; 
}

.tab { 
  padding: 8px 16px; 
  border: 1px solid var(--line); 
  border-radius: 8px; 
  background: var(--panel); 
  cursor: pointer; 
  font-size: 14px; 
  font-weight: 600;
}

.tab:hover {
  border-color: #aeb8c7;
}

.tab.active { 
  border-color: var(--blue); 
  background: var(--blue-soft); 
  color: #0f4fa8; 
}

.system-card { 
  background: var(--panel); 
  border: 1px solid var(--line); 
  border-radius: 12px; 
  padding: 20px; 
  margin-bottom: 20px; 
  box-shadow: var(--shadow); 
}

.system-header { 
  display: flex; 
  justify-content: space-between; 
  align-items: center;
  border-bottom: 1px solid var(--line); 
  padding-bottom: 12px; 
  margin-bottom: 16px; 
}

.system-stats {
  font-size: 15px;
}

.pipeline-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); 
  gap: 16px; 
}

.stage { 
  border: 1px solid var(--line); 
  border-radius: 8px; 
  padding: 16px; 
  background: #fafbfc;
}

.status-badge { 
  display: inline-block; 
  padding: 4px 8px; 
  border-radius: 4px; 
  font-size: 12px; 
  font-weight: bold; 
  margin-bottom: 12px; 
}

.status-ready { background: var(--green-soft); color: var(--green); }
.status-not_ready, .status-disconnected { background: var(--red-soft); color: var(--red); }
.status-trained { background: var(--blue-soft); color: var(--blue); }

.criteria-list { 
  list-style: none; 
  padding: 0; 
  margin: 0; 
  font-size: 13px; 
}

.criteria-list li { 
  display: flex; 
  justify-content: space-between; 
  margin-bottom: 6px; 
  border-bottom: 1px dashed var(--line);
  padding-bottom: 4px;
}

.criteria-list li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.pass { color: var(--green); font-weight: bold; }
.fail { color: var(--red); font-weight: bold; }

.genome-preview {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}