/* The API viewer (/api-viewer): one scrolling column of routes, grouped by plugin. */
body.api-viewer { display: block; height: auto; overflow: auto; max-width: 880px; margin: 0 auto; padding: 0 16px 48px; }
.api-head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; gap: 12px; padding: 14px 0 10px; background: var(--bg); }
.api-head h1 { margin: 0; font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.api-head input { max-width: 280px; }
.api-intro { margin: 4px 0 16px; }
.api-intro code { font: 11.5px var(--mono); color: var(--text); }
.api-group h2 { display: flex; align-items: center; gap: 8px; margin: 22px 0 6px; font-size: 11px; font-weight: 500; color: var(--faint); text-transform: uppercase; letter-spacing: .04em; }
.api-group .off { padding: 0 6px; border-radius: 4px; background: var(--active); color: var(--muted); text-transform: none; letter-spacing: 0; }
.api-route { border-radius: var(--radius); }
.api-route.open { background: var(--panel); box-shadow: inset 0 0 0 1px var(--line); }
.api-line { display: flex; align-items: center; gap: 10px; width: 100%; min-width: 0; padding: 6px 8px; border-radius: var(--radius); text-align: left; font-size: 12.5px; }
.api-line:hover { background: var(--hover); }
.method { flex: none; width: 52px; font: 600 10.5px/18px var(--mono); text-align: center; border-radius: 4px; background: var(--active); color: var(--muted); }
.method.get { color: var(--ok); background: #4cb7821f; }
.method.post { color: var(--accent); background: var(--accent-soft); }
.method.put, .method.patch { color: var(--warn); background: #f2c94c1c; }
.method.delete { color: var(--bad); background: #eb57571f; }
.api-try { display: grid; gap: 8px; padding: 4px 8px 12px; }
.api-try textarea { resize: vertical; font-size: 12px; }
.api-try pre { margin: 0; max-height: 60dvh; white-space: pre-wrap; overflow-wrap: anywhere; }
@media (max-width: 560px) {
  .api-head { flex-wrap: wrap; }
  .api-head input { max-width: none; }
}
