/* 灵壳 agent cloud module — session list, Codex / Claude Code terminal, explorer.
   Generated from the 灵枢 console stylesheet by tools/build_web_css.py. Theme: override these variables. */
:root {
  --ink-0: #0a0b0e; --ink-1: #0f1116; --ink-2: #14171f; --paper: #ece9e1; --paper-soft: #c7c4bb; --muted: #8b8e96; --faint: #5d616b;
  --accent: #6fe3c4; --matrix: #3dff9a; --accent-dim: rgba(111,227,196,.08); --accent-line: rgba(111,227,196,.32);
  --warn: #e0a83e; --bad: #e06c5b; --hairline: rgba(236,233,225,.08); --hairline-strong: rgba(236,233,225,.16);
  --font-body: -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", "SF Mono", Consolas, monospace;
}
.agentlink-pane { display: flex; flex-direction: column; min-height: 0; background: var(--ink-1); color: var(--paper); font-family: var(--font-body); }
.agentlink-pane .btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--hairline-strong); color: var(--paper); background: transparent;
  border-radius: 999px; padding: 4px 11px; font: 12.5px var(--font-body); cursor: pointer; }
.agentlink-pane .btn:hover { border-color: var(--accent-line); color: var(--accent); }
.agentlink-pane input { width: 100%; background: var(--ink-1); border: 1px solid var(--hairline-strong); color: var(--paper); border-radius: 8px; outline: none; }

.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--faint); flex: 0 0 auto; display: inline-block; }
.dot.on { background: var(--accent); }
.dot.busy { background: var(--matrix); animation: pulse 1.2s infinite; }
.dot.bad { background: var(--bad); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(61,255,154,.6); } 70% { box-shadow: 0 0 0 8px rgba(61,255,154,0); } }
.treebox, .sess { display: flex; flex-direction: column; min-height: 0; }
.treebox { flex: 1; }
.ph { display: flex; align-items: center; gap: 8px; padding: 8px 12px 7px 14px; border-bottom: 1px solid var(--hairline); flex: 0 0 auto; }
.ph b, .info h3 { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .14em; color: var(--accent); font-weight: 500; margin: 0; white-space: nowrap; }
.ph .pm { font-family: var(--font-mono); font-size: 11px; color: var(--muted); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ib { background: none; border: 1px solid transparent; color: var(--muted); border-radius: 6px; width: 26px; height: 24px; cursor: pointer; font-size: 14px; line-height: 1; }
.ib:hover { border-color: var(--hairline-strong); color: var(--accent); }
.ib.on { color: var(--accent); }
.tmsg { color: var(--muted); font-size: 12.5px; padding: 10px 14px; line-height: 1.6; }
.tmsg.bad { color: var(--bad); }
.tree { flex: 1; overflow: auto; padding: 4px 0 12px; outline: none; font: 13px/1 "Segoe UI", var(--font-body); }
.explorer .tr { display: flex; align-items: center; gap: 5px; height: 24px; padding-right: 8px; cursor: default; white-space: nowrap; color: #e3e3e3; border: 1px solid transparent; user-select: none; }
.explorer .tr:hover { background: rgba(255,255,255,.055); }
.explorer .tr.sel { background: rgba(111,227,196,.13); border-color: rgba(111,227,196,.32); }
.explorer .tr.hid { opacity: .55; }
.explorer .tw { width: 14px; flex: 0 0 14px; text-align: center; color: #9aa0a8; font-size: 14px; line-height: 1; }
.explorer .fi { width: 16px; height: 16px; flex: 0 0 16px; }
.explorer .tn { overflow: hidden; text-overflow: ellipsis; flex: 1; min-width: 0; }
.explorer .ts { font-size: 11px; color: var(--faint); margin-left: 6px; }
.explorer .root .tn { font-weight: 600; }
.sbar { display: flex; gap: 6px; padding: 8px 12px; flex: 0 0 auto; }
.sbar input { padding: 6px 10px; font-size: 13px; }
.slist { flex: 1; overflow-y: auto; padding: 0 6px 8px; min-height: 0; }
.si { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; padding: 6px 8px; border-radius: 7px; cursor: pointer; border: 1px solid transparent; }
.si:hover { background: var(--ink-2); }
.si.on { background: var(--accent-dim); border-color: var(--accent-line); }
.si .eb { grid-row: span 2; align-self: center; font: 600 10px/1 var(--font-mono); border-radius: 4px; padding: 4px 4px; color: #fff; }
.eb.codex { background: #2b2f3a; border: 1px solid #555c6e; }
.eb.claude { background: #8a3f26; border: 1px solid #d97757; }
.eb.deepseek { background: #2c3f9e; border: 1px solid #4d6bfe; }
.eb.kimi { background: #0d1117; border: 1px solid #3aa0ff; }
.si .st { font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.si .sm { font-family: var(--font-mono); font-size: 10.5px; color: var(--faint); }
.si .busy { color: var(--matrix); font-style: normal; animation: pulse 1.2s infinite; border-radius: 50%; }
.th { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-bottom: 1px solid var(--hairline); flex: 0 0 auto; background: var(--ink-1); }
.th .eng { display: inline-flex; border: 1px solid var(--hairline-strong); border-radius: 7px; overflow: hidden; flex: 0 0 auto; }
.th .eng button { background: none; border: 0; color: var(--muted); padding: 3px 10px; font: 12px var(--font-mono); cursor: pointer; }
.th .eng button.on.codex { background: #262a33; color: #fff; }
.th .eng button.on.claude { background: rgba(217,119,87,.2); color: #f0a184; }
.th .eng button.on.deepseek { background: rgba(77,107,254,.22); color: #9db0ff; }
.th .eng button.on.kimi { background: rgba(58,160,255,.18); color: #8cc8ff; }
.th .eng button:disabled { opacity: .35; cursor: not-allowed; }
.th .tt { flex: 1; min-width: 0; font: 12px var(--font-mono); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tui { flex: 1; overflow-y: auto; padding: 10px 12px 6px; font: 13px/1.55 "Cascadia Mono", "JetBrains Mono", Consolas, "Microsoft YaHei UI", monospace; color: #d4d4d4; outline: none;
  white-space: pre-wrap; word-break: break-word; min-height: 0; }
.tui .tmsg { white-space: normal; font-family: var(--font-body); }
.tui .dim { color: #8a8f98; }
.tui .red { color: #f4776a; }
.tui .green { color: #4eba65; }
.tui .orange { color: #d97757; }
.tui b { color: #fff; font-weight: 700; }
.tui .wb { border: 1px solid #4b505a; border-radius: 6px; padding: 6px 12px; margin: 2px 0 10px; display: block; white-space: pre-wrap; }
.tui .wb.claude { border-color: #d97757; }
.tui .wb.deepseek { border-color: #4d6bfe; }
.tui .wb.kimi { border-color: #3aa0ff; }
.tui .kimi-c { color: #3aa0ff; }
.tui .wb div { white-space: pre-wrap; }
.tui .tip { margin: -2px 0 12px; white-space: normal; }
.tui .ev { margin: 0 0 9px; }
.tui .ev.a, .tui .ev.x, .tui .ev.r, .tui .ev.e { display: grid; grid-template-columns: 1.4em 1fr; }
.tui .ev .b { color: #d4d4d4; }
.tui .ev .b.wd { color: #fff; }
.tui .ev.u.cx { background: #1d2026; margin-left: -12px; margin-right: -12px; padding: 5px 12px; color: #e8e8e8; }
.tui .ev.u.cx .g { color: #9aa0a8; font-weight: 700; }
.tui .ev.u.cc { color: #9aa0a8; }
.tui .ev.u.cc .g { color: #9aa0a8; }
.tui .ev.r i { color: #9aa0a8; }
.tui .think { color: #6f747d; font-size: 12px; margin-top: 2px; max-height: 7.5em; overflow: hidden; }
.tui .cmd { color: #7dd3fc; }
.tui.claude .cmd { color: #e5e5e5; }
.tui .o { color: #b8bcc4; }
.tui .more { cursor: pointer; }
.tui .more:hover { color: var(--accent); }
.tui .md code { color: #7dd3fc; }
.tui.claude .md code { color: #b4a0ff; }
.tui .md .h { color: #fff; }
.tui .md .quote { color: #9aa0a8; border-left: 2px solid #4b505a; padding-left: 8px; }
.tui pre.code { background: #15171c; border: 1px solid #262a32; border-radius: 5px; padding: 6px 10px; margin: 4px 0; overflow-x: auto; white-space: pre; font: inherit; color: #e3e3e3; position: relative; }
.tui pre.code .lang { position: absolute; right: 8px; top: 2px; font-size: 10.5px; color: #6f747d; }
.tui .diff { margin-top: 3px; white-space: pre; overflow-x: auto; font-size: 12px; }
.tui .add { color: #7ee787; background: rgba(46,160,67,.13); }
.tui .del { color: #ffa198; background: rgba(248,81,73,.13); }
.tui .sep { text-align: left; color: #6f747d; margin: 2px 0 12px; }
.tui .s { margin-top: -4px; }
.tui .spin { animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: .25; } }
.tui .pickm, .tui .picks { cursor: pointer; }
.tui .pickm:hover, .tui .picks:hover { color: var(--matrix); text-decoration: underline; }
.cmpwrap { position: relative; flex: 0 0 auto; padding: 4px 10px 6px; font: 13px/1.5 "Cascadia Mono", "JetBrains Mono", Consolas, monospace; }
.cmpwrap .work { padding: 2px 4px 6px; color: #d4d4d4; }
.cmpwrap .work .orange { color: #d97757; }
.cmpwrap .work .dim { color: #8a8f98; }
.cmpwrap .work .red { color: #f4776a; }
.shimmer { background: linear-gradient(90deg, #8a8f98 0%, #ffffff 45%, #8a8f98 60%); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shim 2s linear infinite; }
@keyframes shim { from { background-position: 100% 0; } to { background-position: -100% 0; } }
.cmp { display: flex; align-items: flex-start; gap: 8px; padding: 7px 10px; }
.cmpwrap.codex .cmp, .cmpwrap.deepseek .cmp { background: #1d2026; border-radius: 4px; }
.cmpwrap.claude .cmp, .cmpwrap.kimi .cmp { border: 1px solid #6f747d; border-radius: 8px; }
.cmpwrap.claude .cmp:focus-within, .cmpwrap.kimi .cmp:focus-within { border-color: #9aa0a8; }
.cmp .pr { color: #e8e8e8; font-weight: 700; line-height: 22px; }
.cmp textarea { flex: 1; border: 0; background: transparent; box-shadow: none !important; resize: none; padding: 0; color: #f0f0f0; font: inherit; line-height: 22px; min-height: 22px; max-height: 180px; outline: none; }
.cmp textarea::placeholder { color: #6f747d; }
.cmp .send { background: none; border: 1px solid #4b505a; color: #9aa0a8; border-radius: 6px; width: 30px; height: 24px; cursor: pointer; flex: 0 0 auto; }
.cmp .send:hover { color: var(--matrix); border-color: var(--matrix); }
.cmp .navk { background: none; border: 1px solid #3a3f49; color: #8a8f98; border-radius: 6px; width: 26px; height: 24px; cursor: pointer; flex: 0 0 auto; padding: 0; font: 13px/1 inherit; }
.cmp .navk:hover { color: var(--accent); border-color: var(--accent-line); }
.popup .pt { display: flex; gap: 12px; align-items: baseline; padding: 3px 12px 5px; border-bottom: 1px solid #2a2e36; margin-bottom: 3px; }
.popup .pt .dim { color: #6f747d; font-size: 11.5px; }
.tui .ev.older { text-align: center; margin: 4px 0 10px; }
.dlg .dh .btn { margin-left: 6px; }
.foot { display: flex; gap: 14px; padding: 4px 6px 0; font-size: 11.5px; color: #6f747d; white-space: nowrap; overflow: hidden; }
.foot .r { margin-left: auto; overflow: hidden; text-overflow: ellipsis; }
.foot .red { color: #f4776a; }
.popup { position: absolute; left: 10px; right: 10px; bottom: 100%; background: #121419; border: 1px solid #3a3f49; border-radius: 6px; padding: 4px 0; max-height: 260px; overflow-y: auto; z-index: 5; box-shadow: 0 -10px 30px rgba(0,0,0,.5); }
.popup .pi { display: grid; grid-template-columns: 9.5em 1fr; gap: 10px; padding: 3px 12px; cursor: pointer; }
.popup .pi.on { background: #1f2a33; }
.popup .pi .cmd { color: #7dd3fc; }
.popup .pi .dim { color: #8a8f98; }
.cmpwrap.claude .popup .pi .cmd { color: #b4a0ff; }
.th .wbadge { font: 11px var(--font-mono); padding: 2px 8px; border-radius: 999px; border: 1px solid var(--accent-line); color: var(--accent); white-space: nowrap; }
.th .wbadge.busy { border-color: rgba(61,255,154,.5); color: var(--matrix); }
.th .wbadge.dialog, .th .wbadge.draft { border-color: rgba(224,168,62,.5); color: var(--warn); }
.th #tt-open { white-space: nowrap; }
.modebtn { font: 11px var(--font-mono); padding: 3px 9px; border-radius: 999px; cursor: pointer; white-space: nowrap; background: none; }
.modebtn.headed { border: 1px solid var(--accent-line); color: var(--accent); }
.modebtn.headless { border: 1px solid var(--hairline-strong); color: var(--muted); }
.wtag { font: 10.5px var(--font-mono); color: var(--accent); margin-left: 4px; }
.wtag.busy { color: var(--matrix); }
.wtag.dialog, .wtag.draft { color: var(--warn); }
.si .wx { background: none; border: 0; padding: 0 3px; margin-left: 2px; font: 10.5px var(--font-mono); color: var(--faint); cursor: pointer; border-radius: 3px; }
.si .wx:hover { color: var(--warn); background: rgba(224,168,62,.12); }
.ph .newpair { display: inline-flex; gap: 4px; flex: 0 0 auto; }
.ph .newpair .btn { white-space: nowrap; }
.ph .newpair .codex { border-color: #555c6e; }
.ph .newpair .claude { border-color: rgba(217,119,87,.6); color: #f0a184; }
.ph .newpair .deepseek { border-color: rgba(77,107,254,.6); color: #9db0ff; }
.ph .newpair .kimi { border-color: rgba(58,160,255,.6); color: #8cc8ff; }
.th #tt-close { white-space: nowrap; }
.dlg { border-top: 1px solid rgba(224,168,62,.4); background: rgba(224,168,62,.06); padding: 8px 12px; flex: 0 0 auto; max-height: 45%; overflow: auto; }
.dlg .dh { font-size: 12.5px; color: var(--warn); margin-bottom: 4px; }
.dlg pre { font: 12px/1.45 "Cascadia Mono", Consolas, monospace; color: #d4d4d4; margin: 0 0 6px; white-space: pre-wrap; }
.dlg .dk { display: flex; gap: 6px; flex-wrap: wrap; }
