.crisis-prepass {
  margin: 1.5rem 0;
  padding: 1.25rem 1.5rem;
  border: 2px solid #d97706;
  background: #fffbeb;
  border-radius: 8px;
}

.crisis-prepass .crisis-note {
  font-size: 0.9rem;
  color: #555;
  margin-top: 0.75rem;
}

.crisis-prepass-dismiss {
  margin-top: 0.75rem;
  background: transparent;
  border: 1px solid #d97706;
  color: #92400e;
  padding: 0.4rem 0.85rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
}

.crisis-prepass-dismiss:hover {
  background: #fef3c7;
}

.crisis-prominent-emphasis {
  border-width: 3px;
  box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.15);
}

.findings-sort-label {
  font-size: 0.85rem;
  color: #555;
  align-self: center;
  margin-right: 0.25rem;
}

.acute-risk-box {
  margin: 1rem 0 2rem;
  padding: 1.25rem 1.5rem;
  border: 2px solid #dc2626;
  background: #fef2f2;
  border-radius: 8px;
}

.acute-risk-box p:first-child {
  color: #991b1b;
  font-size: 1rem;
}

.acute-risk-box ul {
  margin: 0.75rem 0;
}

.acute-risk-box li {
  margin: 0.5rem 0;
}

.privacy-summary {
  font-size: 0.85rem;
  color: #555;
  background: #f7f7f8;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  border-left: 3px solid #94a3b8;
  margin: 1rem 0;
}

.observations-section .observations-intro,
.findings-section .findings-intro,
.transcript-section .transcript-intro {
  color: #555;
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.observations-text {
  font-size: 1.05rem;
  line-height: 1.6;
  background: #f7f7f8;
  padding: 1.25rem 1.5rem;
  border-radius: 8px;
  border-left: 4px solid #4f46e5;
}

.parse-summary {
  font-size: 0.85rem;
  color: #777;
  margin-top: 0.5rem;
  font-style: italic;
}

.patterns-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.5rem;
}

.pattern-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  font-size: 0.85rem;
}

.pattern-pill.pattern-high { background: #eef2ff; border-color: #818cf8; }
.pattern-pill.pattern-medium { background: #f8fafc; border-color: #94a3b8; }
.pattern-pill.pattern-low { background: #fafafa; border-color: #e2e8f0; color: #555; }

.pattern-pill-count {
  font-weight: 700;
  color: #1a1a1a;
  font-variant-numeric: tabular-nums;
}

.pattern-pill-desc {
  color: #333;
}

.findings-sort {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 0 0.75rem;
  flex-wrap: wrap;
}

.findings-sort button {
  font-size: 0.85rem;
  padding: 0.4rem 0.85rem;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
  background: white;
  color: #333;
  cursor: pointer;
}

.findings-sort button:hover {
  background: #f7f7f8;
}

.findings-sort button.active {
  background: #1a1a1a;
  color: white;
  border-color: #1a1a1a;
}

.findings-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 0.75rem 0 1rem;
}

.pattern-group {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1rem 1.25rem;
  background: #fafafa;
}

.pattern-group-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.5rem;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.pattern-group-header h3 {
  font-size: 1.05rem;
  margin: 0;
  color: #1a1a1a;
}

.pattern-group-count {
  font-size: 0.8rem;
  color: #555;
  font-variant-numeric: tabular-nums;
}

.pattern-group .finding-item {
  margin-top: 0.5rem;
}

.pattern-group-expand {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: #4f46e5;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem 0;
}

.pattern-group-expand:hover {
  text-decoration: underline;
}

.findings-empty {
  color: #555;
  font-style: italic;
  padding: 1rem;
  background: #f7f7f8;
  border-radius: 6px;
}

.finding-item {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1rem 1.25rem;
  background: white;
}

.finding-item.finding-high { border-left: 4px solid #4f46e5; }
.finding-item.finding-medium { border-left: 4px solid #94a3b8; }
.finding-item.finding-low { border-left: 4px solid #cbd5e1; }
.finding-item.finding-harm {
  border: 2px solid #dc2626;
  background: #fef2f2;
}

.finding-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.finding-desc {
  font-size: 1rem;
  font-weight: 600;
  color: #1a1a1a;
  flex: 1 1 auto;
}

.finding-confidence {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #555;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  background: #f1f5f9;
  white-space: nowrap;
}

.finding-code-tag {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.8rem;
  color: #555;
  background: #f1f5f9;
  padding: 0.05rem 0.4rem;
  border-radius: 3px;
}

.finding-meta-details {
  margin-top: 0.5rem;
  font-size: 0.85rem;
}

.finding-meta-details summary {
  color: #777;
  cursor: pointer;
  user-select: none;
}

.finding-meta-details summary:hover {
  color: #1a1a1a;
}

.finding-code-tag-block {
  margin-top: 0.4rem;
}

.finding-code-tag-block code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.8rem;
  color: #555;
  background: #f1f5f9;
  padding: 0.1rem 0.45rem;
  border-radius: 3px;
}

.finding-snippet {
  margin: 0.75rem 0;
  padding: 0.75rem 1rem;
  border-left: 3px solid #cbd5e1;
  font-style: italic;
  color: #1a1a1a;
  background: #f7f7f8;
  border-radius: 4px;
}

.finding-rationale {
  font-size: 0.9rem;
  color: #444;
  margin: 0.5rem 0;
}

.finding-turn {
  font-size: 0.8rem;
  color: #777;
  margin: 0;
}

.annotated-transcript {
  margin: 1rem 0;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: white;
  padding: 0.5rem;
  max-height: 600px;
  overflow-y: auto;
}

.transcript-turn {
  padding: 0.75rem 1rem;
  border-radius: 6px;
  margin: 0.25rem 0;
}

.transcript-turn.turn-user { background: #f0f9ff; }
.transcript-turn.turn-ai { background: #f7f7f8; }

.turn-role {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #555;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.turn-text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: #1a1a1a;
}

mark.finding-highlight {
  background: #fef3c7;
  border-bottom: 2px solid #d97706;
  padding: 0 0.1em;
  border-radius: 2px;
  cursor: help;
}

.loading-text {
  margin-top: 1rem;
  color: #1a1a1a;
}

.loading-reassurance {
  color: #777;
  font-size: 0.9rem;
}
