/* ── LLM response blocks & lightweight code highlighting ─────────── */

.llm-block {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  overflow: hidden;
}
.llm-block:last-child { margin-bottom: 0; }

.llm-block__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.6rem;
  background: var(--bg-hl);
  border-bottom: 1px solid var(--border);
}
.llm-block__specifier {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--violet);
}
.llm-block__token {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}
.llm-block pre { margin: 0; border: none; border-radius: 0; }
.llm-block__headline {
  min-width: 0;
  overflow: hidden;
  font-size: 0.78rem;
  color: var(--text-muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.llm-block__copy {
  margin-left: auto;
  padding: 0.1rem 0.5rem;
  font-size: 0.75rem;
}
/* Drag the corner to read a long validation error or answer in full. */
.llm-block .llm-block__resizable {
  max-height: 18rem;
  overflow: auto;
  resize: vertical;
}
.llm-block__answer { margin: 0; }

/* Syntax tokens — set by code-highlight.js. Colours degrade gracefully
   to the default text colour when the script has not run. */
.tok-key { color: var(--violet); }
.tok-str { color: #6a9955; }
.tok-num { color: #b5842a; }
.tok-bool { color: #c586c0; }
.tok-null { color: #c586c0; }
.tok-comment { color: var(--text-faint); font-style: italic; }

html.dark .tok-str { color: #9ccc7c; }
html.dark .tok-num { color: #d8a657; }
