:root { color-scheme: dark; --bg: #212121; --bg-raised: #2f2f2f; --bg-hover: #383838; --border: #3d3d3d; --text: #ececec; --text-dim: #a6a6a6; --text-faint: #7c7c7c; --accent: #10a37f; --accent-dim: #0d8a6c; --danger: #ef4444; --user-bubble: #2f2f2f; --assistant-bubble: #212121; --radius: 12px; font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; } * { box-sizing: border-box; } html, body, #root { height: 100%; margin: 0; } body { background: var(--bg); color: var(--text); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; } button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; } button:disabled { cursor: not-allowed; opacity: 0.5; } input, textarea, select { font: inherit; color: var(--text); background: var(--bg-raised); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; } input:focus, textarea:focus, select:focus { outline: 1px solid var(--accent); } a { color: var(--text-dim); text-decoration: none; } a:hover { color: var(--text); } /* ---------- app shell ---------- */ .app-shell { display: flex; height: 100%; overflow: hidden; } .sidebar { width: 264px; flex-shrink: 0; display: flex; flex-direction: column; background: var(--bg-raised); border-right: 1px solid var(--border); } .sidebar-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; font-weight: 600; } .sidebar-header .brand { display: flex; align-items: center; gap: 8px; } .sidebar-header .brand .logo { width: 24px; height: 24px; border-radius: 6px; background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; } .conn-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; } .conn-dot.open { background: #22c55e; } .conn-dot.connecting { background: #eab308; } .conn-dot.closed { background: var(--danger); } .new-chat-btn { display: block; width: calc(100% - 20px); margin: 0 10px 8px; padding: 8px; border: 1px solid var(--border); border-radius: 10px; text-align: center; color: var(--text); } .new-chat-btn:hover { background: var(--bg-hover); } .sidebar-sessions { flex: 1; overflow-y: auto; padding: 4px 8px 12px; } .session-link { display: block; padding: 8px 10px; border-radius: 8px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .session-link:hover { background: var(--bg-hover); color: var(--text); } .session-link.active { background: var(--bg-hover); color: var(--text); } .sidebar-footer { padding: 10px; border-top: 1px solid var(--border); display: flex; gap: 8px; align-items: center; } .sidebar-footer .spacer { flex: 1; } .icon-btn { padding: 6px; border-radius: 8px; color: var(--text-dim); font-size: 13px; } .icon-btn:hover { background: var(--bg-hover); color: var(--text); } .icon-btn.danger:hover { color: var(--danger); } .main { flex: 1; display: flex; flex-direction: column; min-width: 0; overflow: hidden; } /* ---------- sessions view ---------- */ .page { flex: 1; overflow-y: auto; padding: 24px; max-width: 860px; margin: 0 auto; width: 100%; } .page h1 { font-size: 20px; margin: 0 0 16px; } .page .empty { color: var(--text-faint); padding: 40px 0; text-align: center; } .session-card { display: flex; align-items: center; gap: 12px; padding: 14px; border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 10px; cursor: pointer; background: var(--bg); } .session-card:hover { background: var(--bg-raised); } .session-card .online-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; background: #525252; } .session-card .online-dot.on { background: #22c55e; } .session-card .card-body { flex: 1; min-width: 0; } .session-card .card-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .session-card .card-meta { font-size: 12px; color: var(--text-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; gap: 8px; flex-wrap: wrap; } .badge { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); color: var(--text-dim); flex-shrink: 0; } /* ---------- chat view ---------- */ .chat-layout { flex: 1; display: flex; min-height: 0; } .chat-col { flex: 1; display: flex; flex-direction: column; min-width: 0; } .chat-header { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); background: var(--bg); } .chat-header .title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .chat-header .sub { font-size: 12px; color: var(--text-faint); } .chat-header .spacer, .task-col .spacer { flex: 1; } .chat-scroll { flex: 1; overflow-y: auto; padding: 20px 16px; scroll-behavior: smooth; } .chat-inner { max-width: 760px; margin: 0 auto; } .bubble-row { display: flex; margin-bottom: 14px; } .bubble-row.user { justify-content: flex-end; } .bubble { max-width: 86%; padding: 10px 14px; border-radius: var(--radius); white-space: pre-wrap; word-break: break-word; } .bubble-row.user .bubble { background: var(--user-bubble); } .bubble-row.assistant .bubble { background: transparent; padding: 0; max-width: 100%; } .bubble-row.system .bubble { color: var(--text-faint); font-size: 13px; font-style: italic; } .bubble .tool-card { border: 1px solid var(--border); border-radius: 10px; background: var(--bg-raised); margin: 8px 0; overflow: hidden; } .bubble .tool-card summary { cursor: pointer; padding: 8px 12px; font-size: 13px; color: var(--text-dim); display: flex; align-items: center; gap: 8px; list-style: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .bubble .tool-card summary::-webkit-details-marker { display: none; } .bubble .tool-card .tool-body { border-top: 1px solid var(--border); padding: 10px 12px; font-size: 13px; color: var(--text-dim); white-space: pre-wrap; word-break: break-word; max-height: 300px; overflow-y: auto; } .tool-status-ok { color: var(--accent); } .tool-status-err { color: var(--danger); } details.thinking { margin-bottom: 8px; } details.thinking summary { cursor: pointer; font-size: 12px; color: var(--text-faint); list-style: none; } details.thinking summary::-webkit-details-marker { display: none; } details.thinking summary::before { content: "◆ "; } details.thinking .thinking-body { font-size: 13px; color: var(--text-faint); border-left: 2px solid var(--border); padding-left: 10px; margin-top: 6px; white-space: pre-wrap; max-height: 260px; overflow-y: auto; } .typing { display: inline-flex; gap: 4px; align-items: center; padding: 8px 0; } .typing .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--text-faint); animation: typing-bounce 1.2s infinite; } .typing .dot:nth-child(2) { animation-delay: 0.15s; } .typing .dot:nth-child(3) { animation-delay: 0.3s; } @keyframes typing-bounce { 0%, 60%, 100% { transform: translateY(0); opacity: 0.5; } 30% { transform: translateY(-4px); opacity: 1; } } .composer { border-top: 1px solid var(--border); padding: 12px 16px; background: var(--bg); } .composer-inner { max-width: 760px; margin: 0 auto; display: flex; gap: 8px; align-items: flex-end; } .composer textarea { flex: 1; resize: none; max-height: 200px; min-height: 42px; border-radius: var(--radius); } .composer .send-btn { background: var(--accent); color: #fff; border-radius: 10px; padding: 10px 14px; } .composer .send-btn:hover { background: var(--accent-dim); } .composer .send-btn:disabled { background: var(--bg-hover); color: var(--text-faint); } .composer .abort-btn { border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; color: var(--danger); } /* ---------- task panel ---------- */ .task-col { width: 300px; flex-shrink: 0; border-left: 1px solid var(--border); overflow-y: auto; padding: 14px; background: var(--bg); } .task-col h2 { font-size: 13px; margin: 0 0 8px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.04em; } .task-col .empty { color: var(--text-faint); font-size: 13px; } .task-section { margin-bottom: 18px; } .todo-item { display: flex; gap: 8px; align-items: baseline; font-size: 13px; padding: 3px 0; } .todo-item .todo-icon { flex-shrink: 0; width: 14px; text-align: center; } .todo-item .todo-icon.pending { color: var(--text-faint); } .todo-item .todo-icon.in-progress { color: #eab308; } .todo-item .todo-icon.completed { color: var(--accent); } .todo-item.done .todo-text { text-decoration: line-through; color: var(--text-faint); } .todo-item .todo-text { color: var(--text); } .subagent-item { font-size: 13px; padding: 4px 0; display: flex; gap: 8px; align-items: center; } .subagent-item .spinner { width: 12px; height: 12px; border: 2px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; flex-shrink: 0; } @keyframes spin { to { transform: rotate(360deg); } } .subagent-item .done-icon { color: var(--accent); flex-shrink: 0; } .working-line { font-size: 12px; color: var(--text-faint); padding: 3px 0; display: flex; gap: 6px; align-items: center; } .task-toggle { display: none; } /* ---------- settings gate ---------- */ .gate { height: 100%; display: flex; align-items: center; justify-content: center; padding: 20px; } .gate-card { width: 100%; max-width: 380px; border: 1px solid var(--border); border-radius: 16px; background: var(--bg-raised); padding: 28px; } .gate-card h1 { font-size: 18px; margin: 0 0 4px; display: flex; align-items: center; gap: 8px; } .gate-card .sub { color: var(--text-faint); font-size: 13px; margin-bottom: 20px; } .gate-card label { display: block; font-size: 13px; color: var(--text-dim); margin: 12px 0 4px; } .gate-card input { width: 100%; } .gate-card .gate-error { color: var(--danger); font-size: 13px; margin-top: 12px; min-height: 18px; } .gate-card .gate-submit { width: 100%; margin-top: 20px; padding: 10px; background: var(--accent); color: #fff; border-radius: 10px; } /* ---------- spawn view ---------- */ .spawn-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; background: var(--bg-raised); } .spawn-card h2 { font-size: 15px; margin: 0 0 10px; } .spawn-card input[type="text"], .spawn-card input[type="password"], .spawn-card select { width: 100%; } .spawn-card .row { display: flex; gap: 10px; } .spawn-card .row > * { flex: 1; } .spawn-card .actions { display: flex; gap: 8px; margin-top: 14px; } .btn-primary { background: var(--accent); color: #fff; border-radius: 10px; padding: 8px 16px; } .btn-primary:hover { background: var(--accent-dim); } .btn-primary:disabled { background: var(--bg-hover); color: var(--text-faint); } .btn-secondary { border: 1px solid var(--border); border-radius: 10px; padding: 8px 16px; } .btn-secondary:hover { background: var(--bg-hover); } .error-text { color: var(--danger); font-size: 13px; margin-top: 10px; } .repo-list { max-height: 420px; overflow-y: auto; } .repo-item { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 8px; cursor: pointer; } .repo-item:hover { background: var(--bg-hover); } .repo-item.selected { background: var(--bg-hover); outline: 1px solid var(--accent); } .repo-item .repo-path { font-weight: 600; } .repo-item .repo-meta { font-size: 12px; color: var(--text-faint); } .spawn-job-line { font-size: 13px; color: var(--text-dim); padding: 4px 0; } /* ---------- toasts ---------- */ .toasts { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 100; } .toast { background: var(--bg-raised); border: 1px solid var(--border); color: var(--text); padding: 10px 16px; border-radius: 10px; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4); font-size: 14px; } /* ---------- mobile ≤400px ---------- */ @media (max-width: 860px) { .task-col { display: none; } .task-toggle { display: inline-flex; align-items: center; } .mobile-tasks { border-bottom: 1px solid var(--border); padding: 12px 16px; background: var(--bg-raised); } } @media (max-width: 700px) { .sidebar { position: fixed; inset: 0 auto 0 0; z-index: 50; transform: translateX(-100%); transition: transform 0.2s ease; width: 280px; } .sidebar.open { transform: translateX(0); } .sidebar-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.5); z-index: 40; } .menu-btn { display: inline-flex !important; } .page { padding: 14px; } .chat-scroll { padding: 14px 10px; } .bubble { max-width: 94%; } } @media (max-width: 400px) { body { font-size: 14px; } .sidebar { width: 100%; } .gate-card { padding: 20px; } .session-card { padding: 10px; gap: 8px; } .composer textarea { font-size: 16px; } /* prevent iOS zoom */ .composer .send-btn { padding: 10px 12px; } }