:root {
  --bg: #F5F4EE; --surface: #FFFFFF; --bubble: #EAE7DE; --border: #DEDBD1;
  --text: #1F1E1D; --muted: #73726C; --accent: #D97757; --code: #F0EEE6;
  /* Web fonts with full Vietnamese support: the Mac fallback (Iowan Old Style) mis-stacks Vietnamese diacritics. */
  --serif: "Source Serif 4", "Noto Serif", Georgia, serif;
  --sans: "Be Vietnam Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #262624; --surface: #30302E; --bubble: #3A3A37; --border: #45443F; --text: #EDECE7; --muted: #A6A49C; --code: #1F1F1D; }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font: 16px/1.5 var(--sans); }
button, select, textarea { font: inherit; color: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); } .small { font-size: 13px; } .serif { font-family: var(--serif); }
.error { color: #d33; min-height: 1em; }
.login { min-height: 100%; height: 100%; overflow-y: auto; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 24px; text-align: center; }
.login > :first-child { margin-top: auto; } .login > :last-child { margin-bottom: auto; }
.login h1 { font: 600 44px var(--serif); margin: 0; }
.spark { color: var(--accent); font-size: 56px; line-height: 1; }
.primary { background: var(--accent); color: #fff; border: 0; border-radius: 14px; padding: 14px 28px; font-weight: 600; cursor: pointer; margin-top: 24px; }
.link { background: none; border: 0; color: var(--accent); cursor: pointer; padding: 0; }
.icon { background: none; border: 1px solid var(--border); border-radius: 999px; min-width: 34px; height: 34px; cursor: pointer;
        display: inline-flex; align-items: center; justify-content: center; color: var(--muted); padding: 0 8px; }
.icon.on { background: var(--accent); color: #fff; border-color: var(--accent); }
select { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 4px 8px; }

.app { display: flex; height: 100%; }
.sidebar { width: 290px; flex-shrink: 0; border-right: 1px solid var(--border); display: flex; flex-direction: column; background: var(--bg); }
.side-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 14px 8px; }
.brand { font: 600 20px var(--serif); } .brand::first-letter { color: var(--accent); }
.side-list { flex: 1; overflow-y: auto; padding: 4px 8px; }
.side-section { font-size: 12px; color: var(--muted); margin: 14px 8px 4px; text-transform: uppercase; letter-spacing: .04em; }
.item { display: flex; gap: 8px; align-items: flex-start; padding: 8px 10px; border-radius: 10px; cursor: pointer; }
.item:hover { background: var(--bubble); } .item.active { background: var(--bubble); }
.item .t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item .sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item .ico { color: var(--muted); font-size: 13px; padding-top: 2px; }
.item .body { min-width: 0; flex: 1; }
.activity { font-size: 12px; color: var(--accent); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.activity::before { content: "◌ "; display: inline-block; animation: spin 1.2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.side-foot { padding: 10px 14px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 8px; }

.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.top { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); }
.title { flex: 1; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-actions { display: flex; gap: 8px; align-items: center; }
.messages { flex: 1; overflow-y: auto; padding: 20px max(16px, calc((100% - 760px) / 2)); }
.greet { text-align: center; margin-top: 18vh; } .greet .spark { font-size: 40px; } .greet h2 { font: 400 28px var(--serif); }
.msg { margin: 18px 0; }
.msg.user { display: flex; flex-direction: column; align-items: flex-end; }
.msg.user .bubble { background: var(--bubble); border-radius: 20px; padding: 10px 14px; max-width: 85%; white-space: pre-wrap; word-wrap: break-word; }
.msg.assistant .md { font-family: var(--serif); font-size: 17px; line-height: 1.6; word-wrap: break-word; }
.md p { margin: .4em 0; } .md pre { position: relative; background: var(--code); border: 1px solid var(--border); border-radius: 10px; padding: 12px; overflow-x: auto; font: 14px/1.45 var(--mono); cursor: pointer; }
.md pre::after { content: "Chép"; position: absolute; top: 6px; right: 10px; font: 11px var(--sans); color: var(--muted); }
.md pre.copied::after { content: "Đã chép ✓"; color: var(--accent); }
.md code { font-family: var(--mono); font-size: .9em; background: var(--code); padding: 1px 4px; border-radius: 4px; }
.md pre code { background: none; padding: 0; }
.tool { font: 12px var(--mono); color: var(--muted); margin: 2px 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.actions { display: flex; gap: 14px; margin-top: 6px; color: var(--muted); font-size: 14px; }
.actions button { background: none; border: 0; color: inherit; cursor: pointer; padding: 0; }
.actions .on { color: var(--accent); }
.actions .cost { font-size: 12px; font-variant-numeric: tabular-nums; align-self: center; }
.imgs { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; margin-bottom: 6px; }
.imgs img { max-width: 200px; max-height: 200px; border-radius: 12px; border: 1px solid var(--border); }
.chip { font-size: 11px; color: var(--muted); margin-top: 4px; display: flex; gap: 8px; align-items: center; }
.chip button { background: none; border: 0; color: var(--muted); cursor: pointer; }
.thinking { color: var(--accent); font-size: 22px; animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.note { font-size: 13px; color: var(--muted); background: var(--bubble); border-radius: 12px; padding: 10px 12px; }

.composer { margin: 8px max(12px, calc((100% - 784px) / 2)) 14px; background: var(--surface); border: 1px solid var(--border);
            border-radius: 24px; padding: 10px 14px; box-shadow: 0 2px 10px rgba(0,0,0,.05); }
.composer textarea { width: 100%; border: 0; outline: 0; resize: none; background: transparent; max-height: 220px; padding: 4px 0; }
.composer-row { display: flex; align-items: center; gap: 8px; }
.grow { flex: 1; }
.send { background: var(--accent); color: #fff; border: 0; width: 34px; height: 34px; border-radius: 999px; font-weight: 700; cursor: pointer; }
.send:disabled { opacity: .35; cursor: default; }
.thumbs { display: flex; gap: 8px; } .thumbs:empty { display: none; }
.thumbs div { position: relative; } .thumbs img { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; }
.thumbs button { position: absolute; top: -6px; right: -6px; border: 0; border-radius: 999px; background: #000a; color: #fff; width: 20px; height: 20px; cursor: pointer; font-size: 11px; }

.menu-btn { display: none; }
.app.collapsed .sidebar { display: none; }
.app.collapsed .menu-btn { display: inline-flex; }
@media (max-width: 760px) {
  .menu-btn { display: inline-flex; }
  .only-desktop { display: none; }
  .app.collapsed .sidebar { display: flex; }
  .sidebar { position: fixed; inset: 0 auto 0 0; z-index: 10; width: 86%; transform: translateX(-100%); transition: transform .2s; box-shadow: 0 0 30px #0003; }
  .sidebar.open { transform: none; }
  .msg.assistant .md { font-size: 16px; }
}

.side-btn { margin: 4px 14px 2px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; text-align: left; cursor: pointer; color: var(--text); }
.side-btn:hover { border-color: var(--accent); }
.slash { max-height: 220px; overflow-y: auto; border-bottom: 1px solid var(--border); margin-bottom: 6px; }
.slash div { font: 14px var(--mono); padding: 6px 4px; cursor: pointer; display: flex; justify-content: space-between; }
.slash div:hover, .slash div.sel { background: var(--bubble); border-radius: 6px; }
.files { display: flex; gap: 6px; flex-wrap: wrap; } .files:empty { display: none; }
.files span { font-size: 12px; background: var(--bubble); border-radius: 999px; padding: 3px 10px; display: inline-flex; gap: 6px; align-items: center; }
.files button { background: none; border: 0; cursor: pointer; color: var(--muted); padding: 0; }
.sheet { border: 1px solid var(--border); border-radius: 16px; background: var(--surface); color: var(--text); padding: 18px 20px; width: min(460px, 92vw); max-height: 80vh; }
.sheet.wide { width: min(760px, 94vw); }
.sheet::backdrop { background: #0006; }
.sheet h3 { margin: 0 0 12px; font: 600 18px var(--serif); }
.pick-machine { font-size: 12px; color: var(--muted); margin: 12px 0 6px; text-transform: uppercase; }
.pick-dir { display: inline-block; margin: 0 6px 6px 0; background: var(--bubble); border: 0; border-radius: 999px; padding: 6px 12px; cursor: pointer; color: var(--text); }
.run { border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; }
.run .cmd { font: 600 14px var(--mono); margin-bottom: 6px; }

.agent-img { display: block; max-width: min(360px, 100%); max-height: 360px; border-radius: 12px; border: 1px solid var(--border); margin: 6px 0; cursor: zoom-in; background: var(--bubble); min-height: 60px; }

.artifact { border: 1px solid var(--border, #ddd); border-radius: 14px; overflow: hidden; margin: 8px 0; max-width: 720px; }
.artifact iframe { width: 100%; height: 420px; border: 0; display: block; background: #fff; resize: vertical; }
.artifact-bar { display: flex; justify-content: space-between; padding: 6px 12px; font-size: 13px; opacity: .8; }

.term { background: #1c1c1e; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; margin: 6px 0; overflow: hidden; cursor: pointer; max-width: 760px; }
.term-bar { display: flex; gap: 6px; align-items: center; padding: 7px 10px; background: rgba(255,255,255,.06); }
.term-bar i { width: 10px; height: 10px; border-radius: 50%; background: #ff5f57; } .term-bar i:nth-child(2) { background: #febc2e; } .term-bar i:nth-child(3) { background: #28c840; }
.term-bar span { margin-left: auto; font: 11px ui-monospace, Menlo, monospace; color: rgba(255,255,255,.4); }
.term-body { padding: 10px 12px; display: flex; flex-direction: column; gap: 5px; }
.term-row { font: 12.5px/1.45 ui-monospace, Menlo, monospace; color: #e0e0e0; white-space: pre-wrap; word-break: break-all;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.term.open .term-row { -webkit-line-clamp: unset; display: block; }
.term-row .p { color: #5ad974; } .term-row .t { color: #73bfff; }

.term .cursor { width: 7px; height: 14px; background: #5ad974; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.term.running .term-bar span::before { content: "◌ "; display: inline-block; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

details.tools { margin: 6px 0; } details.tools > summary { cursor: pointer; color: var(--muted, #8a8478); font-size: 14px; list-style: none; }
details.tools > summary::after { content: " ›"; display: inline-block; transition: transform .2s; } details.tools[open] > summary::after { transform: rotate(90deg); }
details.tools > summary::-webkit-details-marker { display: none; } details.tools .term { margin-top: 8px; }
.thinking { display: flex; gap: 8px; align-items: center; color: #d97757; padding: 4px 0; }
.thinking .star { font-weight: 700; font-size: 17px; display: inline-block; animation: spinstar 2.4s steps(8) infinite; }
@keyframes spinstar { to { transform: rotate(360deg); } }

.icon.accent { color: var(--accent); border-color: var(--accent); }
.side-section.ask { color: var(--accent); }
.item .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-top: 7px; flex-shrink: 0; }
.suggest { margin: 10px 0 18px; display: flex; flex-direction: column; gap: 8px; }
.suggest .label { font-size: 12px; color: var(--muted); }
.suggest button { text-align: left; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 9px 14px;
  cursor: pointer; color: var(--text); display: flex; justify-content: space-between; gap: 10px; }
.suggest button:hover { border-color: var(--accent); }
.suggest button::after { content: "↑"; color: var(--accent); font-weight: 700; }
.card { background: var(--bubble); border-radius: 14px; padding: 10px 12px; margin: 10px 0; font-size: 14px; }
.card .head { font-size: 12px; color: var(--muted); font-weight: 600; margin-bottom: 6px; display: flex; justify-content: space-between; }
.card .row { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; cursor: pointer; }
.card .row:hover .t { color: var(--accent); }
.card .state { font-size: 12px; color: var(--muted); } .card .state.on { color: var(--accent); }
.btw-q { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; margin: 6px 0 4px 18%; }
.btw-q .bubble { background: var(--bubble); border-radius: 16px; padding: 7px 12px; font-size: 14px; }
.btw-q .tag { color: var(--accent); background: color-mix(in srgb, var(--accent) 15%, transparent); font-size: 11px; font-weight: 700;
  border-radius: 999px; padding: 1px 7px; margin-right: 7px; }
.btw-q .acts { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.btw-q .acts .icon { min-width: 24px; height: 24px; border: 0; }
.btw-a { margin: 0 18% 10px 0; padding: 8px 12px; border-left: 3px solid color-mix(in srgb, var(--accent) 60%, transparent);
  background: var(--surface); border-radius: 4px 14px 14px 4px; font-size: 14px; }
.btw-a > :first-child { margin-top: 0; } .btw-a > :last-child { margin-bottom: 0; }
.pick-env { display: block; width: 100%; text-align: left; margin: 0 0 6px; background: var(--bubble); border: 0; border-radius: 12px; padding: 8px 12px; cursor: pointer; color: var(--text); }
.pick-env small { display: block; color: var(--muted); }

.side-links { display: flex; gap: 4px; margin: 6px 14px 0; flex-wrap: wrap; }
.side-link { background: none; border: 1px solid var(--border); border-radius: 999px; padding: 4px 10px; font-size: 13px; cursor: pointer; color: var(--text); }
.side-link:hover, .side-link.active { border-color: var(--accent); color: var(--accent); }
.lib-search { width: 100%; padding: 9px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--text); font: inherit; margin-bottom: 12px; }
.lib-item { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 10px 14px; margin-bottom: 8px; cursor: pointer; }
.lib-item:hover { border-color: var(--accent); }
.lib-item .t { font-weight: 600; } .lib-item .sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.lib-item .desc { font-size: 14px; color: var(--muted); margin-top: 4px; }
.lib-back { margin-bottom: 10px; }
.tag { display: inline-block; font-size: 11px; border-radius: 999px; padding: 1px 8px; margin: 2px 4px 0 0; background: var(--bubble); color: var(--muted); }
.tag.ok { color: #2e8b57; } .tag.warn { color: var(--accent); }
.file-row { font: 13px var(--mono); padding: 3px 0; display: flex; justify-content: space-between; gap: 10px; }
.file-row .blocked { color: var(--accent); font-family: var(--sans); font-size: 12px; }
.artifact.big iframe { height: 70vh; }

.side-search { margin: 8px 14px 0; padding: 7px 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--text); font: inherit; font-size: 14px; }
.side-section.toggle { cursor: pointer; user-select: none; }
.side-section.toggle::before { content: "▸ "; } .side-section.toggle.open::before { content: "▾ "; }
.findbar { display: flex; gap: 8px; align-items: center; padding: 8px 16px; border-bottom: 1px solid var(--border); background: var(--bg); }
.findbar input { flex: 1; padding: 6px 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--text); font: inherit; }
mark.hit { background: #f6d58a; color: inherit; border-radius: 3px; } mark.hit.cur { background: var(--accent); color: #fff; }

.ic { display: block; flex-shrink: 0; }
.ibtn { background: none; border: 0; color: var(--muted); cursor: pointer; padding: 3px; border-radius: 6px; display: inline-flex; align-items: center; }
.ibtn:hover { color: var(--text); background: var(--bubble); }
.ibtn.on, .ibtn.done { color: var(--accent); }
.actions { gap: 4px; align-items: center; }
.side-btn { display: flex; align-items: center; gap: 8px; }
.item .ico { padding-top: 3px; }
.chip { gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.chip .link { font-size: 11px; color: var(--accent); }
.chip .live::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-right: 5px; animation: pulse 1s ease-in-out infinite; }
.send { display: inline-flex; align-items: center; justify-content: center; }
.thumbs .ibtn { position: absolute; top: -6px; right: -6px; background: #000a; color: #fff; border-radius: 999px; padding: 2px; }
.files .ibtn { padding: 0; }
.pick-other { display: flex; gap: 8px; align-items: center; margin: 2px 0 8px; flex-wrap: wrap; }
.pick-other select { max-width: 100%; }
.pick-other input { flex: 1; min-width: 180px; padding: 6px 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--text); font: 14px var(--mono); }
.item { position: relative; }
.item .row-pin { visibility: hidden; margin-top: 1px; }
.item:hover .row-pin, .item .row-pin.on { visibility: visible; }
.item .row-pin.on svg { fill: currentColor; fill-opacity: .18; }
#pin.on { background: none; color: var(--accent); border-color: var(--accent); }
.ibtn.on svg { fill: currentColor; fill-opacity: .18; }
@media (hover: none) { .item .row-pin { visibility: visible; opacity: .45; } .item .row-pin.on { opacity: 1; } }
.ctx { position: fixed; z-index: 50; min-width: 180px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.18); padding: 4px; display: flex; flex-direction: column; }
.ctx button { text-align: left; background: none; border: 0; padding: 7px 10px; border-radius: 6px; cursor: pointer; color: var(--text); font-size: 14px; }
.ctx button:hover { background: var(--bubble); }
.title-wrap { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.status { display: flex; gap: 10px; align-items: center; font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; }
.status:empty { display: none; }
.status .dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; margin: 0; }
.status .dot.on { background: #34c759; } .status .dot.off { background: var(--muted); }
.status b.ok { color: #2e9e57; } .status b.mid { color: #d98a1c; } .status b.low { color: #d33; }

/* Secrets */
.secret-head { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; margin-bottom: 12px; }
.secret-head p { margin: 0; max-width: 560px; }
.secret-row { display: flex; gap: 6px; align-items: flex-start; }
.secret-row .tag { margin-right: 6px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.grow { flex: 1; min-width: 0; }
.secret-form { display: grid; gap: 10px; }
.secret-form label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.secret-form input { padding: 9px 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg, var(--surface)); color: var(--text); font: inherit; }
.secret-form .row { display: flex; justify-content: flex-end; gap: 10px; }
.secret-form .error:empty { display: none; }
.secret-card { display: flex; align-items: center; gap: 12px; max-width: 360px; padding: 12px 14px; margin: 8px 0; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.secret-card .secret-ic { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--border); }
.secret-card .t { font-weight: 600; } .secret-card .sub { font-size: 12px; color: var(--muted); }
.primary.small { padding: 6px 14px; font-size: 14px; }
.secret-head .primary, .secret-form .primary, .secret-card .primary { margin-top: 0; padding: 8px 18px; border-radius: 12px; }
.devices { cursor: default; } .devices:hover { border-color: var(--border); }
.dev-row { display: flex; align-items: center; gap: 10px; padding: 4px 0; }
.dev-row.pending { color: var(--accent); }
.devices .sub { font-size: 12px; color: var(--muted); margin-top: 6px; }
.item .row-stop { color: var(--muted); margin-top: 1px; }
.item .row-stop:hover { color: #e5484d; }

/* ---- Vibecoding (cử chỉ + giọng nói) ---- */
.composer { position: relative; }
#vibe-btn svg { display: block; margin: auto; }
.vibe-menu { position: absolute; bottom: 52px; left: 12px; z-index: 20; min-width: 270px; padding: 6px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,.18); display: flex; flex-direction: column; }
.vibe-menu hr { border: 0; border-top: 1px solid var(--border); margin: 4px 6px; width: auto; }
.vibe-item { display: flex; align-items: center; gap: 8px; text-align: left; background: none; border: 0; padding: 8px 10px; border-radius: 9px;
  cursor: pointer; color: var(--text); text-decoration: none; font-size: 14px; }
.vibe-item:hover { background: var(--bubble); }
.vibe-item .tick { width: 14px; color: var(--accent); font-weight: 700; }
.vibe-bar { border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent); border-radius: 16px; padding: 8px; margin-bottom: 8px; }
.vibe-row { display: flex; align-items: center; gap: 10px; }
.vibe-lead { width: 46px; height: 46px; border-radius: 50%; flex: none; display: grid; place-items: center; overflow: hidden;
  background: var(--bubble); color: var(--muted); border: 2px solid transparent; }
.vibe-lead video { display: none; width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.vibe-bar.gestures .vibe-lead { width: 64px; height: 48px; border-radius: 10px; border-color: var(--border); }
.vibe-bar.gestures .vibe-lead video { display: block; }
.vibe-bar.gestures .vibe-wave { display: none; }
.vibe-bar.gestures .vibe-lead.seen { border-color: #34c759; }
.vibe-lead.live { background: var(--accent); color: #fff; }
.vibe-lead.live .vibe-wave svg { animation: vibe-pulse 1s ease-in-out infinite; }
@keyframes vibe-pulse { 50% { opacity: .45; } }
.vibe-status { flex: 1; min-width: 0; }
.vibe-main { font-size: 14px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.vibe-main.live { color: var(--accent); }
.vibe-sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vibe-mic { flex: none; }
.vibe-pending { display: flex; align-items: center; gap: 10px; padding: 8px 10px; margin-bottom: 8px; border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 13%, transparent); }
.vibe-pending > div { flex: 1; }
.vibe-ring { width: 20px; height: 20px; border-radius: 50%; flex: none;
  background: conic-gradient(var(--accent) var(--p, 100%), transparent 0); animation: vibe-count 1.6s linear forwards; }
@property --p { syntax: "<percentage>"; inherits: false; initial-value: 100%; }
@keyframes vibe-count { to { --p: 0%; } }
.vibe-head { font-size: 12px; color: var(--muted); padding: 6px 10px 2px; text-transform: uppercase; letter-spacing: .05em; }
#compact-now { padding: 0 10px; font-size: 13px; }
.suggest button .num { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-right: 10px; border-radius: 6px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 700; }

/* CLO 2 pairing */
.pair-steps { text-align: left; max-width: 460px; margin: 4px auto 10px; line-height: 1.6; padding-left: 20px; }
.pair-guide { text-align: left; max-width: 480px; margin: 10px auto; }
.pair-guide > p { margin: 10px 0 2px; }
.pair-cmd { display: block; user-select: all; padding: 8px 10px; border-radius: 8px; background: rgba(127,127,127,.12); font-size: 12.5px; overflow-x: auto; white-space: nowrap; }
.pair-row { display: flex; gap: 8px; max-width: 420px; margin: 10px auto; width: 100%; }
.pair-row input { flex: 1; font: 13px ui-monospace, monospace; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); color: var(--text); }
.pair-check { display: flex; flex-direction: column; align-items: center; gap: 4px; margin: 10px auto; }
.pair-check b { font: 700 36px ui-monospace, monospace; letter-spacing: 8px; }
.offline-bar { background: #c0392b; color: #fff; font-size: 13px; padding: 7px 14px; text-align: center; }
