/* Design tokens */ :root { --state-pending: #94a3b8; --state-queued: #60a5fa; --state-running: #f59e0b; --state-completed: #34d399; --state-failed: #f87171; --state-timed-out: #c084fc; --state-cancelled: #9ca3af; --state-budget-exceeded: #fb923c; --bg: #0f172a; --surface: #1e293b; --border: #334155; --text: #e2e8f0; --text-muted: #94a3b8; --accent: #38bdf8; } /* Reset */ *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; } body { font-family: system-ui, -apple-system, sans-serif; background: var(--bg); color: var(--text); min-height: 100dvh; } /* Header */ header { background: var(--surface); border-bottom: 1px solid var(--border); padding: 1rem; position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; max-width: 100%; } header h1 { font-size: 1.25rem; font-weight: 700; color: var(--accent); letter-spacing: -0.01em; max-width: 640px; margin: 0 auto 0 0; flex: 1; } /* Tab bar */ .tab-bar { background: var(--surface); border-bottom: 1px solid var(--border); display: flex; gap: 0; padding: 0 1rem; max-width: 100%; } .tab { font-size: 0.88rem; font-weight: 600; padding: 0.65em 1.25em; border: none; border-bottom: 2px solid transparent; background: transparent; color: var(--text-muted); cursor: pointer; transition: color 0.15s, border-color 0.15s; margin-bottom: -1px; } .tab:hover { color: var(--text); } .tab.active { color: var(--accent); border-bottom-color: var(--accent); } /* Main layout */ main { max-width: 640px; margin: 0 auto; padding: 1rem; } /* Panel header */ .panel-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; } .panel-header h2 { font-size: 1rem; font-weight: 700; } /* Task list toolbar */ .task-list-toolbar { display: flex; align-items: center; padding: 0.5rem 0; margin-bottom: 0.75rem; border-bottom: 1px solid var(--border); } /* Task list */ .task-list { display: flex; flex-direction: column; gap: 0.75rem; } #loading { color: var(--text-muted); text-align: center; padding: 2rem 0; font-size: 0.9rem; } /* Task card */ .task-card { background: var(--surface); border: 1px solid var(--border); border-radius: 0.5rem; padding: 0.875rem 1rem; display: flex; flex-direction: column; gap: 0.375rem; } .task-card-header { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; flex-wrap: wrap; } .task-name { font-weight: 600; font-size: 0.95rem; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } /* State badge */ .state-badge { display: inline-block; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.03em; text-transform: uppercase; padding: 0.2em 0.55em; border-radius: 999px; color: #0f172a; white-space: nowrap; flex-shrink: 0; } .state-badge[data-state="PENDING"] { background: var(--state-pending); } .state-badge[data-state="QUEUED"] { background: var(--state-queued); } .state-badge[data-state="RUNNING"] { background: var(--state-running); } .state-badge[data-state="COMPLETED"] { background: var(--state-completed); } .state-badge[data-state="FAILED"] { background: var(--state-failed); } .state-badge[data-state="TIMED_OUT"] { background: var(--state-timed-out); } .state-badge[data-state="CANCELLED"] { background: var(--state-cancelled); } .state-badge[data-state="BUDGET_EXCEEDED"] { background: var(--state-budget-exceeded); } /* Task meta */ .task-meta { font-size: 0.78rem; color: var(--text-muted); display: flex; gap: 0.75rem; flex-wrap: wrap; } .task-description { font-size: 0.82rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } /* Run button */ .task-card-footer { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.25rem; flex-wrap: wrap; } .btn-run { font-size: 0.8rem; font-weight: 600; padding: 0.35em 0.85em; border-radius: 0.375rem; border: none; cursor: pointer; background: var(--accent); color: #0f172a; transition: opacity 0.15s; } .btn-run:disabled { opacity: 0.5; cursor: not-allowed; } .btn-cancel { font-size: 0.8rem; font-weight: 600; padding: 0.35em 0.85em; border-radius: 0.375rem; border: none; cursor: pointer; background: var(--state-failed); color: #fff; transition: opacity 0.15s; } .btn-cancel:disabled { opacity: 0.5; cursor: not-allowed; } .btn-restart { font-size: 0.8rem; font-weight: 600; padding: 0.35em 0.85em; border-radius: 0.375rem; border: none; cursor: pointer; background: var(--text-muted); color: #0f172a; transition: opacity 0.15s; } .btn-restart:disabled { opacity: 0.5; cursor: not-allowed; } .btn-accept { font-size: 0.8rem; font-weight: 600; padding: 0.35em 0.85em; border-radius: 0.375rem; border: none; cursor: pointer; background: var(--state-completed); color: #0f172a; transition: opacity 0.15s; } .btn-accept:disabled { opacity: 0.5; cursor: not-allowed; } .btn-reject { font-size: 0.8rem; font-weight: 600; padding: 0.35em 0.85em; border-radius: 0.375rem; border: none; cursor: pointer; background: var(--text-muted); color: #0f172a; transition: opacity 0.15s; margin-left: 0.375rem; } .btn-reject:disabled { opacity: 0.5; cursor: not-allowed; } .task-error { font-size: 0.78rem; color: var(--state-failed); } .hidden-tasks-info { font-size: 0.78rem; color: var(--text-muted); text-align: center; padding: 0.5rem 0; cursor: pointer; background: transparent; border: none; width: 100%; } .hidden-tasks-info:hover { color: var(--text); } .hidden-tasks-fold { display: flex; flex-direction: column; gap: 0.75rem; opacity: 0.6; margin-top: 0.5rem; } /* Primary button */ .btn-primary { font-size: 0.85rem; font-weight: 600; padding: 0.4em 1em; border-radius: 0.375rem; border: none; cursor: pointer; background: #2563eb; color: #fff; transition: opacity 0.15s; } .btn-primary:disabled { opacity: 0.5; cursor: not-allowed; } /* Secondary button */ .btn-secondary { font-size: 0.85rem; font-weight: 600; padding: 0.4em 1em; border-radius: 0.375rem; border: 1px solid var(--border); background: transparent; color: var(--text-muted); cursor: pointer; transition: background 0.15s, color 0.15s; } .btn-secondary:hover { background: var(--border); color: var(--text); } .btn-secondary:disabled { opacity: 0.5; cursor: not-allowed; } /* Danger button */ .btn-danger { font-size: 0.85rem; font-weight: 600; padding: 0.4em 1em; border-radius: 0.375rem; border: none; cursor: pointer; background: var(--state-failed); color: #0f172a; transition: opacity 0.15s; } .btn-danger:disabled { opacity: 0.5; cursor: not-allowed; } .btn-sm { font-size: 0.78rem; padding: 0.3em 0.75em; } /* Modal dialog */ dialog { background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 8px; padding: 1.5rem; max-width: 480px; width: 100%; } dialog::backdrop { background: rgba(0, 0, 0, 0.6); } dialog h2 { font-size: 1.1rem; font-weight: 700; margin-bottom: 1rem; } /* Form labels and inputs */ dialog label { display: block; font-size: 0.85rem; color: var(--text-muted); margin-bottom: 12px; } dialog label input, dialog label textarea, dialog label select { display: block; width: 100%; margin-top: 4px; background: var(--bg); border: 1px solid var(--border); border-radius: 0.375rem; color: var(--text); padding: 0.4em 0.6em; font-size: 0.9rem; font-family: inherit; } dialog label input:focus, dialog label textarea:focus, dialog label select:focus { outline: 2px solid var(--accent); outline-offset: 1px; } /* Form actions row */ .form-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; } .form-actions button[type="button"] { font-size: 0.85rem; padding: 0.4em 1em; border-radius: 0.375rem; border: 1px solid var(--border); background: transparent; color: var(--text-muted); cursor: pointer; } .form-actions button[type="button"]:hover { background: var(--border); color: var(--text); } /* Inline form error */ .form-error { color: var(--state-failed); font-size: 0.82rem; margin-top: 8px; } /* Template list */ .template-list { display: flex; flex-direction: column; gap: 0.75rem; } /* Template card */ .template-card { background: var(--surface); border: 1px solid var(--border); border-radius: 0.5rem; padding: 0.875rem 1rem; display: flex; flex-direction: column; gap: 0.375rem; } .template-name { font-weight: 600; font-size: 0.95rem; } .template-description { font-size: 0.82rem; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; } .template-tags { display: flex; flex-wrap: wrap; gap: 0.375rem; margin-top: 0.125rem; } .tag-chip { font-size: 0.7rem; font-weight: 600; padding: 0.2em 0.55em; border-radius: 999px; background: var(--border); color: var(--text-muted); } .template-card-footer { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.25rem; } /* ── Side panel ───────────────────────────────────────────────────────────── */ .panel-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.5); z-index: 20; } .task-panel { position: fixed; top: 0; right: 0; width: min(480px, 100vw); height: 100dvh; background: var(--surface); border-left: 1px solid var(--border); z-index: 30; display: flex; flex-direction: column; transform: translateX(100%); transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1); overflow: hidden; } .task-panel.open { transform: translateX(0); } .task-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); flex-shrink: 0; } .task-panel-header h2 { font-size: 1rem; font-weight: 700; margin: 0; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .btn-close-panel { background: transparent; border: none; color: var(--text-muted); cursor: pointer; font-size: 1.3rem; line-height: 1; padding: 0.15em 0.35em; margin-left: 0.5rem; border-radius: 0.25rem; flex-shrink: 0; } .btn-close-panel:hover { color: var(--text); background: var(--border); } .task-panel-content { flex: 1; overflow-y: auto; padding: 1.25rem; } /* Panel sections */ .panel-section { margin-bottom: 1.5rem; } .panel-section:last-child { margin-bottom: 0; } .panel-section-title { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 0.625rem; padding-bottom: 0.375rem; border-bottom: 1px solid var(--border); } .meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem 1rem; } .meta-item { display: flex; flex-direction: column; gap: 0.15rem; } .meta-item.full-width { grid-column: 1 / -1; } .meta-label { font-size: 0.7rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.04em; } .meta-value { font-size: 0.875rem; word-break: break-all; } .meta-value.mono { font-family: monospace; font-size: 0.8rem; } .meta-value.muted { color: var(--text-muted); } .panel-code { background: var(--bg); border: 1px solid var(--border); border-radius: 0.375rem; padding: 0.625rem 0.75rem; font-family: monospace; font-size: 0.8rem; white-space: pre-wrap; word-break: break-word; color: var(--text); max-height: 220px; overflow-y: auto; margin-top: 0.25rem; } .panel-tags { display: flex; flex-wrap: wrap; gap: 0.375rem; margin-top: 0.1rem; } /* Clickable task cards */ .task-card { cursor: pointer; } .task-card:hover { border-color: var(--accent); } /* Panel loading / error */ .panel-loading { color: var(--text-muted); font-size: 0.9rem; padding: 2rem 0; text-align: center; } .panel-fetch-error { color: var(--state-failed); font-size: 0.85rem; padding: 1rem 0; } /* Executions list in panel */ .executions-list { display: flex; flex-direction: column; gap: 0.5rem; } .execution-row { background: var(--bg); border: 1px solid var(--border); border-radius: 0.375rem; padding: 0.625rem 0.75rem; display: flex; align-items: center; gap: 0.5rem 0.75rem; flex-wrap: wrap; } .execution-id { font-family: monospace; font-size: 0.72rem; color: var(--text-muted); flex-shrink: 0; } .execution-times { font-size: 0.75rem; color: var(--text-muted); flex: 1; min-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .execution-cost { font-size: 0.75rem; color: var(--text-muted); white-space: nowrap; } .execution-exit { font-family: monospace; font-size: 0.72rem; color: var(--text-muted); white-space: nowrap; } .btn-view-logs { font-size: 0.72rem; font-weight: 600; padding: 0.2em 0.55em; border-radius: 0.25rem; border: 1px solid var(--border); background: transparent; color: var(--text-muted); cursor: pointer; white-space: nowrap; flex-shrink: 0; } .btn-view-logs:hover { background: var(--border); color: var(--text); } /* Execution logs modal */ .logs-modal-body { display: flex; flex-direction: column; } .logs-modal-body .meta-grid { row-gap: 0.625rem; } /* ── Question banner ───────────────────────────────────────────────────────── */ .question-banner { margin-top: 0.75rem; padding: 0.75rem; background: #1e293b; border: 1px solid #f59e0b; border-radius: 0.5rem; } .question-item { display: flex; flex-direction: column; gap: 0.5rem; } .question-text { font-weight: 600; color: #f59e0b; font-size: 0.9rem; } .question-options { display: flex; flex-wrap: wrap; gap: 0.375rem; } .btn-question-option { padding: 0.375rem 0.75rem; border: 1px solid #475569; border-radius: 0.375rem; background: #334155; color: #e2e8f0; cursor: pointer; font-size: 0.8rem; transition: background 0.15s, border-color 0.15s; } .btn-question-option:hover:not(:disabled) { background: #475569; border-color: #f59e0b; } .btn-question-option:disabled { opacity: 0.5; cursor: not-allowed; } .question-input-row { display: flex; gap: 0.375rem; } .question-input { flex: 1; padding: 0.375rem 0.5rem; border: 1px solid #475569; border-radius: 0.375rem; background: #0f172a; color: #e2e8f0; font-size: 0.8rem; } .question-input:focus { outline: none; border-color: #f59e0b; } .btn-question-send { padding: 0.375rem 0.75rem; border: 1px solid #f59e0b; border-radius: 0.375rem; background: #f59e0b; color: #0f172a; font-weight: 600; cursor: pointer; font-size: 0.8rem; } .btn-question-send:hover:not(:disabled) { background: #fbbf24; } .btn-question-send:disabled { opacity: 0.5; cursor: not-allowed; } .question-error { color: #f87171; font-size: 0.8rem; margin-top: 0.25rem; } /* ── Log Viewer ──────────────────────────────────────────────────────────── */ .log-viewer { width: 100%; padding: 0; } .log-back-btn { font-size: 0.78rem; font-weight: 600; padding: 0.3em 0.75em; border-radius: 0.375rem; border: 1px solid var(--border); background: transparent; color: var(--text-muted); cursor: pointer; transition: background 0.15s, color 0.15s; margin-bottom: 1rem; display: inline-flex; align-items: center; } .log-back-btn:hover { background: var(--border); color: var(--text); } @keyframes pulse-dot { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } } .log-status-indicator { display: flex; align-items: center; gap: 0.4rem; font-size: 0.78rem; color: var(--text-muted); margin-bottom: 0.75rem; } .log-status-indicator::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--state-running); flex-shrink: 0; animation: pulse-dot 1.4s ease-in-out infinite; } .log-output { font-family: monospace; font-size: 0.8rem; overflow-y: auto; max-height: 400px; background: var(--bg); padding: 0.625rem 0.75rem; border-radius: 0.375rem; border: 1px solid var(--border); } .log-line { padding: 2px 0; line-height: 1.5; } .log-text { color: var(--text); } .log-tool-use { background: rgba(56, 189, 248, 0.1); padding: 4px 8px; border-radius: 3px; margin: 2px 0; } .tool-name { color: var(--accent); font-weight: bold; margin-right: 6px; } .log-tool-result { color: var(--text-muted); opacity: 0.6; } .log-cost { color: var(--state-running); font-weight: bold; margin-top: 8px; } /* ── Validate section ────────────────────────────────────────────────────── */ .validate-section { margin-top: 8px; } #validate-result { border-left: 3px solid transparent; padding: 8px 12px; margin-top: 8px; font-size: 0.85rem; } #validate-result[data-clarity="clear"] { border-color: var(--state-completed); } #validate-result[data-clarity="ambiguous"] { border-color: var(--state-running); } #validate-result[data-clarity="unclear"] { border-color: var(--state-failed); } .validate-blocking { color: var(--state-failed); } .validate-minor { color: var(--state-running); } .validate-suggestion { color: #94a3b8; }