/* SPEC 38 (2026-10-22): context meter + "Thu gọn" in the status line, the compaction divider in a chat.
   Colours come from tokens.css only, so light and dark both work. */

/* ------------------------------------------------------------------ status line under the composer */
@media (min-width: 761px) {   /* app.css hides the status line at ≤760px; keep that */
  .statusline { display: flex; align-items: center; gap: 10px; }
}
.statusline .st-txt { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.statusline .st-txt:empty { display: none; }
.statusline .ctx-meter, .statusline .st-compact { flex: none; }
.ctx-meter { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); white-space: nowrap; }
.ctx-meter.warn { color: var(--honey-ink); font-weight: 600; }
.ctx-bar { display: inline-block; width: 44px; height: 4px; border-radius: 2px; background: var(--sunken); overflow: hidden; }
.ctx-bar b { display: block; height: 100%; border-radius: 2px; background: var(--muted); }
.ctx-meter.warn .ctx-bar b { background: var(--honey); }
.statusline .st-compact { height: 24px; }

/* ------------------------------------------------------------------ "Đã thu gọn ngữ cảnh" in the conversation */
.msg-compact { margin: 18px 0; padding: 10px 14px; border: 1px dashed var(--border-strong); border-radius: var(--r-card);
  background: var(--sunken); font-size: 13px; color: var(--muted); }
.msg-compact .cmp-line { display: flex; gap: 8px; align-items: flex-start; line-height: 1.5; }
.msg-compact .cmp-line svg { flex: none; margin-top: 2px; }
.msg-compact .cmp-sum { margin-top: 6px; }
.msg-compact .cmp-sum > summary { cursor: pointer; color: var(--ink); font-weight: 500; }
.msg-compact .cmp-sum > summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.msg-compact .cmp-sum[open] > summary { margin-bottom: 8px; }
.msg-compact .cmp-note { margin: 0 0 8px; font-style: italic; }
.msg-compact .answer { color: var(--body); font-size: 14px; }
