/* Waiting screen of the multi-step agent (ADR-T036), chosen 2026-11-23: bản 2 folded. The status line (bản A,
   progress-sheet.css) is the button that opens the list of lookups; the same list opens from the line above an answer. */

/* Step icons: running = a turning ring; done = tick; going deeper = bulb on yellow; nothing found = grey count. */
.ag-ic { display: grid; place-items: center; flex: none; width: 18px; height: 18px; border-radius: 50%; }
.ag-ic .ic { width: 11px; height: 11px; }
.ag-ic.is-ok { background: var(--primary-soft); color: var(--tdtu-blue-800); }
.ag-ic.is-up { background: var(--v-yellow); color: var(--tdtu-blue-800); box-shadow: inset 0 0 0 1.5px var(--v-ink); }
.ag-ic.is-run { box-sizing: border-box; border: 2px solid var(--tdtu-blue-200); border-top-color: var(--v-ink); animation: ag-turn .8s linear infinite; }
@keyframes ag-turn { to { transform: rotate(360deg); } }

.ag2 { margin: 0; padding: 0; list-style: none; }
.ag-it { display: grid; grid-template-columns: 18px minmax(0, 1fr); align-items: start; gap: 9px; font-size: 13.5px; line-height: 20px; color: var(--text); }
.ag-it + .ag-it { margin-top: 6px; }
.ag-it .ag-ic { margin-top: 1px; }
.ag-it.is-run .ag-l { color: var(--v-ink); font-weight: 700; }
.ag-it.is-up .ag-l { color: var(--tdtu-blue-800); font-weight: 700; }
.ag-l { min-width: 0; overflow-wrap: anywhere; }
.ag-lt { margin-right: 8px; }
.ag-n { display: inline-flex; align-items: center; gap: 3px; height: 20px; padding: 0 8px; border-radius: 999px; background: var(--primary-soft); color: var(--tdtu-blue-800); font-size: 12px; font-weight: 500; line-height: 1; white-space: nowrap; vertical-align: 1px; font-variant-numeric: tabular-nums; }
.ag-n b { font-weight: 800; }
.ag-n.is-none { background: var(--gray-100); color: var(--gray-700); }
.ag-car { width: 13px; height: 13px; transition: transform var(--duration-fast); }
[aria-expanded="true"] > .ag-car { transform: rotate(90deg); }

/* The status line opens the list: same look as bản A, a chevron at its end, light yellow on hover. */
.ag-head { width: fit-content; max-width: 100%; margin: -3px -8px; padding: 3px 8px; border-radius: var(--radius-sm); text-align: left; cursor: pointer; }
.ag-head:hover { background: var(--v-cream); }
.ag-head .ag-car { flex: none; color: var(--gray-600); }

/* The lookups: running ring or tick, the result count, the documents read under each. */
.ag2 { margin-top: 10px; padding: 10px 12px 10px 10px; border: 1.5px solid var(--tdtu-blue-200); border-radius: var(--radius-md); background: var(--paper); }
.ag2 .ag-it { position: relative; }
.ag2 .ag-it + .ag-it { margin-top: 10px; }
.ag2 .ag-it:not(:last-child)::before { content: ''; position: absolute; left: 8px; top: 22px; bottom: -10px; width: 2px; background: var(--tdtu-blue-100); }
.ag-found { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 3px; }
.ag-found span { display: inline-flex; align-items: center; gap: 4px; color: var(--gray-700); font-size: 12.5px; line-height: 18px; }
.ag-found .ic { width: 12px; height: 12px; color: var(--tdtu-blue-800); }
/* ── Every answer: one line with what the agent did, opened on demand ── */
.ag-sum { margin: 0 0 10px; }
.ag-sum-btn { min-height: 26px; }
.ag-sum-btn .pg-text { font-size: 14px; }
.ag-done { width: 20px; height: 20px; margin: 0 3px; }
.ag-done .ic { width: 12px; height: 12px; }
.ag-sum .ag2 { margin-top: 8px; }

@media (prefers-reduced-motion: reduce) { .ag-ic.is-run { animation: none; border-color: var(--v-ink); } }
