/* workspace.css — the instructional workspace: a conversation / sequence rail (left) + drop-in panes
   (right) for the course outline / objectives / scratch pad / exercise, with a VISIBLE inferred-intent
   label. Fully-implicit intent (heuristic stub now; Syndex cognition wired post-handoff, §4). The
   exercise pane renders the PUBLIC half only — the SEALED rubric never reaches this surface. */

#view-workspace { overflow: hidden; }
.ws { flex: 1; min-height: 0; display: flex; }

/* === Left: conversation + sequence rail === */
.ws-rail { width: 380px; flex-shrink: 0; border-right: 1px solid var(--border); background: var(--deep); display: flex; flex-direction: column; min-height: 0; }
.ws-rail-head { padding: 14px 16px; border-bottom: 1px solid var(--border); }
.ws-back { font-size: 12px; color: var(--text-muted); text-decoration: none; }
.ws-back:hover { color: var(--cyan); }
.ws-course { font-family: 'Outfit', sans-serif; font-size: 15px; color: var(--text); margin-top: 6px; line-height: 1.3; }

/* the visible inferred-intent label */
.ws-intent { display: flex; align-items: center; gap: 8px; margin-top: 12px; }
.ws-intent-label { font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--text-dim); }
.ws-intent-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 600; letter-spacing: .4px; padding: 3px 10px; border-radius: 999px; border: 1px solid; transition: all .25s; cursor: help; }
.ws-intent-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.intent-tutor { color: var(--cyan); border-color: rgba(0,200,255,.3); background: rgba(0,200,255,.08); }
.intent-exercise { color: var(--violet); border-color: rgba(120,80,255,.3); background: rgba(120,80,255,.1); }
.intent-placement { color: var(--warning); border-color: rgba(255,170,48,.3); background: rgba(255,170,48,.1); }
.intent-coach { color: var(--mint); border-color: rgba(0,255,180,.3); background: rgba(0,255,180,.08); }

.ws-msgs { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 14px; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.06) transparent; }
.ws-msgs::-webkit-scrollbar { width: 5px; }
.ws-msgs::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.06); border-radius: 3px; }
.ws-msg { font-size: 13px; line-height: 1.55; }
.ws-msg .who { font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--text-dim); margin-bottom: 4px; display: flex; align-items: center; gap: 6px; }
.ws-msg .bubble { padding: 10px 12px; border-radius: 10px; color: var(--text); }
.ws-msg.user .bubble { background: var(--bg-user); border: 1px solid rgba(0,200,255,.12); }
.ws-msg.assistant .bubble { background: var(--bg-assistant); border: 1px solid var(--border); }
.ws-msg .mode-tag { font-size: 8.5px; letter-spacing: .5px; text-transform: uppercase; padding: 1px 6px; border-radius: 4px; border: 1px solid currentColor; }

.ws-input { border-top: 1px solid var(--border); padding: 12px; display: flex; gap: 8px; }
.ws-input textarea { flex: 1; resize: none; min-height: 42px; max-height: 120px; background: var(--void); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; color: var(--text); font-family: 'Inter', sans-serif; font-size: 13px; outline: none; }
.ws-input textarea:focus { border-color: var(--border-focus); }

/* === Right: drop-in panes (work objects) === */
.ws-stage { flex: 1; min-width: 0; display: flex; flex-direction: column; background: var(--void); }
.ws-tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); padding: 0 12px; background: var(--deep); flex-wrap: wrap; }
.ws-tab { font-family: 'Inter', sans-serif; font-size: 12px; color: var(--text-muted); padding: 11px 14px; border: none; border-bottom: 2px solid transparent; cursor: pointer; background: none; transition: all .18s; }
.ws-tab:hover { color: var(--text); }
.ws-tab.active { color: var(--cyan); border-bottom-color: var(--cyan); }
.ws-tab.flagged::after { content: '•'; color: var(--violet); margin-left: 6px; }

.ws-pane { flex: 1; overflow-y: auto; padding: 22px 26px; display: none; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.06) transparent; }
.ws-pane.active { display: block; }
.pane-h { font-family: 'Outfit', sans-serif; font-size: 17px; color: var(--text); margin-bottom: 4px; }
.pane-sub { font-size: 12px; color: var(--text-muted); margin-bottom: 16px; }

/* outline pane reuses .section-block / .module-row from schoolhouse.css */
.ws-outline .module-row.here { border-color: rgba(0,200,255,.4); background: rgba(0,200,255,.05); }

/* objectives */
.obj-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.obj-item { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--text); padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; line-height: 1.5; }
.obj-item .obj-icon { color: var(--violet); flex-shrink: 0; }

/* scratch */
.scratch { width: 100%; min-height: 320px; background: var(--deep); border: 1px solid var(--border); border-radius: 10px; padding: 14px; color: var(--text); font-family: 'Inter', sans-serif; font-size: 13px; line-height: 1.6; resize: vertical; outline: none; }
.scratch:focus { border-color: var(--border-focus); }
.scratch-note { font-size: 11px; color: var(--text-dim); margin-top: 8px; }

/* exercise (PUBLIC half only) */
.ex-card { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.ex-head { background: rgba(120,80,255,.06); border-bottom: 1px solid var(--border); padding: 12px 16px; display: flex; align-items: center; gap: 10px; }
.ex-badge { font-size: 9px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--violet); border: 1px solid rgba(120,80,255,.3); border-radius: 4px; padding: 2px 7px; }
.ex-title { font-size: 14px; color: var(--text); }
.ex-body { padding: 16px; }
.ex-section { margin-bottom: 14px; }
.ex-label { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; color: var(--text-dim); margin-bottom: 5px; }
.ex-text { font-size: 13px; color: var(--text); line-height: 1.6; }
.ex-attempt { width: 100%; min-height: 90px; background: var(--void); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; color: var(--text); font-family: 'Inter', sans-serif; font-size: 13px; resize: vertical; outline: none; }
.ex-attempt:focus { border-color: var(--border-focus); }
.ex-foot { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.ex-verdict { margin-top: 14px; padding: 12px 14px; border-radius: 10px; font-size: 13px; line-height: 1.55; }
.ex-verdict.indeterminate { background: rgba(255,170,48,.06); border: 1px solid rgba(255,170,48,.2); color: var(--text); }
.ex-verdict.pass { background: rgba(0,255,180,.06); border: 1px solid rgba(0,255,180,.22); color: var(--text); }
.ex-verdict.fail { background: rgba(255,68,102,.05); border: 1px solid rgba(255,68,102,.2); color: var(--text); }
.ex-verdict.pending { background: var(--bg-assistant); border: 1px solid var(--border); color: var(--text-muted); }
.exv-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.ex-verdict.pass .exv-head strong { color: var(--mint); }
.ex-verdict.fail .exv-head strong { color: var(--error); }
.ex-verdict.indeterminate .exv-head strong { color: var(--warning); }
.exv-conf { font-size: 11px; color: var(--text-dim); }
.exv-crits { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 5px; }
.exv-crit { display: flex; align-items: baseline; gap: 8px; font-size: 12.5px; }
.exv-mark { width: 13px; flex: none; }
.exv-crit.met .exv-mark { color: var(--mint); }
.exv-crit.missed .exv-mark { color: var(--error); }
.exv-key { color: var(--text); font-weight: 500; }
.exv-cnote { color: var(--text-dim); }
.exv-coach { margin-top: 10px; color: var(--text-muted); font-style: italic; }
.exv-note { margin-top: 8px; font-size: 11.5px; color: var(--text-dim); }
.ex-seal { font-size: 11px; color: var(--text-dim); margin-top: 14px; display: flex; align-items: center; gap: 6px; padding: 8px 10px; border: 1px dashed var(--border); border-radius: 8px; }

@media (max-width: 900px) {
  .ws { flex-direction: column; }
  .ws-rail { width: 100%; height: 46%; border-right: none; border-bottom: 1px solid var(--border); }
}

/* === Instructor answer formatting (Phase 2: live Training House cognition over /api/chat/stream) === */
.ws-cursor { display: inline-block; width: 7px; height: 13px; background: var(--cyan); opacity: .7; animation: ws-blink 1s steps(2) infinite; vertical-align: text-bottom; }
@keyframes ws-blink { 0%, 50% { opacity: .7; } 50.01%, 100% { opacity: 0; } }
.ws-err { color: #ff8da3; }
.ws-note { margin-top: 6px; font-size: 11px; color: var(--warning); border-top: 1px solid rgba(255, 170, 48, .2); padding-top: 5px; }
.ws-msg.assistant .bubble p { margin: 0 0 8px; }
.ws-msg.assistant .bubble p:last-child { margin-bottom: 0; }
.ws-msg.assistant .bubble strong { color: #eef2f8; font-weight: 600; }
.ws-md-h { font-family: 'Outfit', sans-serif; font-weight: 600; font-size: 13px; color: #cfe3ff; margin: 11px 0 4px; }
.ws-md-h:first-child { margin-top: 0; }
.ws-md-list { margin: 4px 0 8px; padding-left: 18px; }
.ws-md-list li { margin: 2px 0; }
.ws-ic { font-family: 'JetBrains Mono', monospace; font-size: 12px; background: rgba(255, 255, 255, .06); padding: 1px 5px; border-radius: 4px; }
.ws-code { background: var(--void); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; overflow-x: auto; font-family: 'JetBrains Mono', monospace; font-size: 12px; margin: 8px 0; }
/* display:block + overflow-x:auto + word-sized cells keep a wide table in-bounds (Surety dock lesson). */
.ws-table { width: 100%; max-width: 100%; display: block; overflow-x: auto; border-collapse: collapse; margin: 8px 0; font-size: 12px; }
.ws-table th, .ws-table td { text-align: left; padding: 4px 8px; border-bottom: 1px solid var(--border); vertical-align: top; word-break: normal; overflow-wrap: normal; }
.ws-table th { color: var(--text-muted); font-weight: 600; font-size: 10.5px; text-transform: uppercase; letter-spacing: .04em; }
.ws-cites { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 5px; align-items: center; }
.ws-cites-label { font-size: 9px; letter-spacing: .5px; text-transform: uppercase; color: var(--text-dim); margin-right: 2px; }
.ws-cite { font-size: 10px; color: var(--mint); background: rgba(0, 255, 180, .06); border: 1px solid rgba(0, 255, 180, .2); border-radius: 4px; padding: 1px 6px; }

/* Mode-change divider — labeled marker in the inferred mode's colour (the .intent-* class on the
   element supplies the colour; we strip its bg/border so only the colour carries through). */
.ws-mode-divider { display: flex; align-items: center; gap: 8px; margin: 6px 2px; background: none; border: none; }
.ws-mode-divider .ws-mode-divider-line { flex: 1; height: 1px; background: currentColor; opacity: .22; }
.ws-mode-divider .ws-mode-divider-label { font-size: 9px; font-weight: 600; letter-spacing: .8px; text-transform: uppercase; }

/* Session-history spine (Workspace v2 seed) — the course as a reviewable session: the learner's own
   recorded course_session events, in order. */
.ws-hist { margin-top: 4px; }
.ws-hist-empty { font-size: 12.5px; color: var(--text-muted); line-height: 1.55; padding: 14px 12px; border: 1px dashed var(--border); border-radius: 8px; }
.ws-hist-list { list-style: none; margin: 0; padding: 0 0 0 4px; }
.ws-hev { display: flex; gap: 11px; padding: 0 0 14px 0; position: relative; }
.ws-hev::before { content: ''; position: absolute; left: 8px; top: 18px; bottom: -4px; width: 1px; background: var(--border); }
.ws-hev:last-child::before { display: none; }
.ws-hev-mark { flex: none; width: 17px; height: 17px; line-height: 17px; text-align: center; font-size: 10px; border-radius: 50%; background: var(--void); border: 1px solid var(--border); z-index: 1; }
.ws-hev-verdict .ws-hev-mark { color: var(--cyan); border-color: rgba(0,200,255,.35); }
.ws-hev-review .ws-hev-mark { color: var(--mint); border-color: rgba(0,255,180,.3); }
.ws-hev-body { flex: 1; min-width: 0; }
.ws-hev-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.ws-hev-title { font-size: 13px; color: var(--text); font-weight: 500; }
.ws-hev-ts { font-size: 10.5px; color: var(--text-dim); flex: none; }
.ws-hev-sum { font-size: 12px; color: var(--text-muted); line-height: 1.5; margin-top: 2px; }
.ws-hev-ref { font-size: 11px; color: var(--text-dim); margin-top: 2px; }

/* ============================================================================
   Workspace v2 — chat-central layout: session-history spine (left) · chat
   (center) · drop-in work panes (right). Lent from the Claude desktop UX.
   ============================================================================ */
.ws-v2 { gap: 0; }

/* LEFT — session-history spine (the navigator: course as a reviewable session) */
.ws-spine { width: 252px; flex: none; border-right: 1px solid var(--border); background: var(--deep); display: flex; flex-direction: column; min-height: 0; transition: width .2s; }
.ws-spine.collapsed { width: 56px; }
.ws-spine-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 13px 12px 4px; }
.ws-spine-title { font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--text-dim); padding: 2px 14px 8px; }
.ws-spine.collapsed .ws-spine-title, .ws-spine.collapsed .ws-back { display: none; }
.ws-spine-body { flex: 1; overflow-y: auto; padding: 4px 8px 16px; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.06) transparent; }
.ws-sp-loading, .ws-sp-empty { font-size: 11.5px; color: var(--text-muted); padding: 8px 10px; line-height: 1.5; }
.ws-spine.collapsed .ws-sp-empty, .ws-spine.collapsed .ws-sp-loading { display: none; }
.ws-sp-list { list-style: none; margin: 0; padding: 0; }
.ws-sp { display: flex; gap: 9px; padding: 7px 8px; border-radius: 8px; cursor: pointer; position: relative; transition: background .15s; outline: none; }
.ws-sp:hover { background: rgba(255,255,255,0.03); }
.ws-sp:focus-visible { box-shadow: 0 0 0 1px var(--border-focus) inset; }
.ws-sp.sel { background: rgba(0,200,255,0.07); }
.ws-sp::before { content: ''; position: absolute; left: 17px; top: 26px; bottom: -7px; width: 1px; background: var(--border); }
.ws-sp:last-child::before { display: none; }
.ws-sp-mark { flex: none; width: 19px; height: 19px; line-height: 19px; text-align: center; font-size: 10px; border-radius: 50%; background: var(--void); border: 1px solid var(--border); z-index: 1; }
.ws-sp-verdict .ws-sp-mark { color: var(--cyan); border-color: rgba(0,200,255,.35); }
.ws-sp-review .ws-sp-mark { color: var(--mint); border-color: rgba(0,255,180,.3); }
.ws-sp-body { flex: 1; min-width: 0; }
.ws-sp-title { font-size: 12.5px; color: var(--text); line-height: 1.35; }
.ws-sp-sum { font-size: 11px; color: var(--text-muted); line-height: 1.4; margin-top: 2px; }
.ws-sp-ts { font-size: 10px; color: var(--text-dim); margin-top: 3px; }
.ws-spine.collapsed .ws-sp-body { display: none; }
.ws-spine.collapsed .ws-sp { justify-content: center; padding: 7px 0; }
.ws-spine.collapsed .ws-sp::before { left: 50%; }

/* CENTER — chat front-and-center */
.ws-chat { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 0; }
.ws-chat-head { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--border); background: var(--deep); }
.ws-chat-head .ws-course { margin: 0; flex: 1; }
.ws-chat-head .ws-intent { margin: 0; }

/* RIGHT — drop-in work panes */
.ws-panes { width: 444px; flex: none; border-left: 1px solid var(--border); background: var(--void); display: flex; flex-direction: column; min-height: 0; }
.ws-panes.hidden { display: none; }

/* shared icon button (spine collapse · panes toggle) */
.ws-icon-btn { background: none; border: 1px solid var(--border); color: var(--text-muted); border-radius: 7px; width: 27px; height: 27px; flex: none; cursor: pointer; font-size: 13px; line-height: 1; transition: all .15s; }
.ws-icon-btn:hover { color: var(--text); border-color: var(--border-focus); }
.ws-panes-btn { margin-left: auto; }

/* ---- Workspace v2 hone: free-floating panes + pane menu + spine hover/jump ---- */
.ws-v2 { position: relative; }   /* anchor the floating panes overlay */

/* pane menu (⊞ in the chat header) */
.ws-pane-menu-wrap { position: relative; margin-left: auto; }
.ws-pane-menu { position: absolute; top: 34px; right: 0; min-width: 168px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.45); padding: 6px; z-index: 40; display: none; }
.ws-pane-menu.open { display: block; }
.ws-pane-menu-h { font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--text-dim); padding: 5px 9px 6px; }
.ws-pane-menu-item { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: none; border: none; color: var(--text-muted); font-family: 'Inter', sans-serif; font-size: 13px; padding: 8px 9px; border-radius: 7px; cursor: pointer; }
.ws-pane-menu-item:hover { background: rgba(255,255,255,0.04); color: var(--text); }
.ws-pmi-check { width: 13px; font-size: 11px; color: var(--cyan); opacity: 0; }
.ws-pane-menu-item.on { color: var(--text); }
.ws-pane-menu-item.on .ws-pmi-check { opacity: 1; }

/* free-floating slide-in panes (overlay the chat's right side; only the cards capture clicks) */
.ws-floats { position: absolute; top: 0; right: 0; bottom: 0; width: 466px; max-width: 52%; display: flex; flex-direction: column; gap: 12px; padding: 14px; overflow-y: auto; pointer-events: none; z-index: 30; scrollbar-width: thin; }
.ws-floats.empty { display: none; }
.ws-float { pointer-events: auto; background: var(--surface); border: 1px solid var(--border); border-radius: 13px; box-shadow: 0 12px 34px rgba(0,0,0,.5); display: flex; flex-direction: column; max-height: calc(100% - 0px); overflow: hidden; animation: ws-float-in .22s ease; }
@keyframes ws-float-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
.ws-float-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 10px 15px; border-bottom: 1px solid var(--border); background: var(--deep); }
.ws-float-title { font-family: 'Outfit', sans-serif; font-size: 13.5px; color: var(--text); }
.ws-float-close { background: none; border: none; color: var(--text-dim); font-size: 18px; line-height: 1; cursor: pointer; padding: 0 4px; }
.ws-float-close:hover { color: var(--text); }
.ws-float .ws-pane { display: block; flex: 1; overflow-y: auto; padding: 16px 18px; }
.ws-float .pane-h { display: none; } /* the float header already names the pane */

/* spine: collapsed lines by default; hover reveals the detail (Claude scrubber feel) */
.ws-sp-sum { display: none; }
.ws-sp-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ws-sp:hover .ws-sp-sum, .ws-sp.sel .ws-sp-sum { display: block; }
.ws-sp:hover .ws-sp-title, .ws-sp.sel .ws-sp-title { white-space: normal; }

/* a jumped-to chat message briefly flashes */
.ws-msg-flash .bubble { box-shadow: 0 0 0 2px var(--cyan); transition: box-shadow .3s; }

/* v2 layout fix: reserve a right gutter when panes are open so the chat never bleeds behind the
   floating cards (they keep the floating look; chat content just stops before them). */
.ws-floats { width: 472px; max-width: 46vw; }
.ws-chat { transition: margin-right .2s ease; }
.ws-v2.panes-open .ws-chat { margin-right: 472px; }
.ws-float { max-height: 100%; }
@media (max-width: 1180px) {
    /* tight screens: don't starve the chat — the cards overlay with a shadow instead of reserving */
    .ws-v2.panes-open .ws-chat { margin-right: 0; }
    .ws-floats { box-shadow: -24px 0 48px rgba(0,0,0,.55); }
}

/* ============================================================================
   Workspace v2 — Claude-faithful pass: DOCKED panes (chat squeezes; vertical
   stack per column, new column every 2) + history SPINE as bars→hover-list→jump.
   (Overrides the earlier float-overlay + labeled-rail rules.)
   ============================================================================ */

/* panes: docked, in the flex flow → chat squeezes to make room (no overlay/gutter) */
.ws-v2.panes-open .ws-chat { margin-right: 0; }     /* neutralize the old gutter hack */
.ws-floats { position: static; flex: none; width: auto; max-width: none; display: flex; flex-direction: row; padding: 0; overflow: visible; pointer-events: auto; box-shadow: none; z-index: auto; }
.ws-floats.empty { display: none; }
.ws-dock-col { width: 416px; flex: none; min-width: 0; display: flex; flex-direction: column; border-left: 1px solid var(--border); background: var(--void); }
.ws-dock-pane { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; animation: ws-float-in .2s ease; }
.ws-dock-pane + .ws-dock-pane { border-top: 1px solid var(--border); }
.ws-dock-pane .ws-pane { display: block; flex: 1; overflow-y: auto; padding: 16px 18px; }
.ws-dock-pane .pane-h { display: none; }   /* the dock head already names the pane */

/* history spine: narrow bars; hover the column → the labeled segment list pops out (absolute, overlays) */
.ws-spine { width: 50px; flex: none; overflow: visible; position: relative; }
.ws-spine-back { display: block; text-align: center; padding: 13px 0 6px; color: var(--text-muted); font-size: 15px; text-decoration: none; }
.ws-spine-back:hover { color: var(--cyan); }
.ws-spine-body { position: relative; overflow: visible; padding: 0; }
.ws-bars { display: flex; flex-direction: column; gap: 8px; align-items: center; padding: 10px 0; }
.ws-bar { width: 16px; height: 3px; border-radius: 2px; background: var(--text-dim); transition: width .18s, background .18s; }
.ws-bar[data-cur] { width: 26px; background: var(--text-muted); }
.ws-bar.sel { width: 30px; background: var(--cyan); }
.ws-spine-pop { position: absolute; left: 10px; top: 6px; width: 312px; max-height: 78vh; overflow-y: auto; background: var(--surface); border: 1px solid var(--border); border-radius: 13px; box-shadow: 0 14px 40px rgba(0,0,0,.55); padding: 8px; display: none; z-index: 60; }
.ws-spine:hover .ws-spine-pop, .ws-spine:focus-within .ws-spine-pop { display: block; }
.ws-pop-h { font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--text-dim); padding: 6px 10px 8px; }
.ws-pop-empty { font-size: 12px; color: var(--text-muted); padding: 4px 10px 8px; line-height: 1.5; }
.ws-pop-row { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: none; border: none; color: var(--text-muted); font-family: 'Inter', sans-serif; font-size: 13px; padding: 8px 10px; border-radius: 8px; cursor: pointer; transition: background .12s; }
.ws-pop-row:hover, .ws-pop-row.sel { background: rgba(0,200,255,.07); color: var(--text); }
.ws-pop-dash { width: 16px; height: 2px; border-radius: 2px; background: var(--text-dim); flex: none; transition: width .15s, background .15s; }
.ws-pop-row:hover .ws-pop-dash, .ws-pop-row.sel .ws-pop-dash { width: 22px; background: var(--cyan); }
.ws-pop-label { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ws-pop-ts { font-size: 10px; color: var(--text-dim); flex: none; }

/* ---- v2 visual cleanup: docked FUNCTION, floating-card FORM (rounded, inset, shadowed); the left
   spine adopts the same language so it matches all the way through. ---- */
.ws-floats { padding: 12px; gap: 12px; }                 /* inset the cards + gap between columns */
.ws-dock-col { border-left: none; gap: 12px; width: 420px; }
.ws-dock-pane { border: 1px solid var(--border); border-radius: 14px; background: var(--surface); box-shadow: 0 10px 30px rgba(0,0,0,.45); overflow: hidden; }
.ws-dock-pane + .ws-dock-pane { border-top: 1px solid var(--border); } /* full border each (gap separates them) */
.ws-dock-pane .ws-float-head { border-radius: 14px 14px 0 0; background: var(--deep); }

/* left spine — same rounded floating-card treatment */
.ws-spine-pop { border-radius: 14px; box-shadow: 0 10px 30px rgba(0,0,0,.45); padding: 9px; }
.ws-pop-row { border-radius: 9px; }
.ws-bar, .ws-pop-dash { border-radius: 3px; }
.ws-bar.sel, .ws-bar[data-cur] { border-radius: 3px; }
/* a soft floating container around the bars so the left edge echoes the card language */
.ws-bars { margin: 8px 7px; padding: 9px 0; border: 1px solid var(--border); border-radius: 13px; background: var(--bg-assistant); gap: 7px; }

/* ---- visual: drop the bubble around the spine bars; round the spine column + chat-head banner ---- */
.ws-bars { margin: 0; padding: 16px 0; border: none; border-radius: 0; background: none; gap: 8px; } /* bare bars, no bubble */
.ws-spine { margin: 12px 0 12px 12px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); } /* rounded left pane */
.ws-chat-head { margin: 12px 12px 0; border: 1px solid var(--border); border-radius: 14px; background: var(--deep); } /* rounded banner above chat */
