@tenonai/yew 1.4.0 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/CHANGELOG.md +48 -5
  2. package/README.md +31 -13
  3. package/THIRD-PARTY-NOTICES.md +6 -1
  4. package/dist/cli/app.js +22 -12
  5. package/dist/cli/export.js +5 -5
  6. package/dist/cli/mcp.js +7 -7
  7. package/dist/cli/remote.js +6 -6
  8. package/dist/cli/run.js +3 -3
  9. package/dist/cli/schedule.js +3 -3
  10. package/dist/cli/send.js +4 -4
  11. package/dist/cli/serve.js +88 -14
  12. package/dist/cli/service.js +13 -13
  13. package/dist/server/agent/prompt.js +3 -2
  14. package/dist/server/agent/runner.js +41 -1
  15. package/dist/server/data-usage.js +1 -1
  16. package/dist/server/db/database.js +1 -1
  17. package/dist/server/export.js +2 -2
  18. package/dist/server/folder-picker.js +1 -1
  19. package/dist/server/http/api.js +17 -1
  20. package/dist/server/http/app.js +13 -5
  21. package/dist/server/http/data.js +1 -1
  22. package/dist/server/http/mcp.js +2 -2
  23. package/dist/server/http/problem.js +1 -1
  24. package/dist/server/http/security.js +5 -5
  25. package/dist/server/mail/envelope.js +11 -6
  26. package/dist/server/mail/post.js +2 -2
  27. package/dist/server/mcp-builtin.js +15 -2
  28. package/dist/server/mcp-config.js +4 -4
  29. package/dist/server/mcp-oauth.js +6 -6
  30. package/dist/server/mcp.js +70 -8
  31. package/dist/server/permissions/engine.js +23 -5
  32. package/dist/server/sandbox.js +447 -0
  33. package/dist/server/settings.js +34 -1
  34. package/dist/server/store.js +2 -2
  35. package/dist/server/tools/jobs.js +3 -2
  36. package/dist/server/tools/mail.js +11 -1
  37. package/dist/server/tools/process.js +63 -12
  38. package/dist/server/tools/search.js +5 -2
  39. package/dist/server/tools/shell.js +70 -17
  40. package/dist/shared/policy.js +20 -20
  41. package/dist/shared/version.js +8 -0
  42. package/dist/sim/client.d.ts +17 -0
  43. package/dist/sim/client.js +41 -0
  44. package/dist/sim/index.d.ts +7 -0
  45. package/dist/sim/index.js +6 -0
  46. package/dist/sim/types.d.ts +161 -0
  47. package/dist/sim/types.js +5 -0
  48. package/dist/sim/world.d.ts +6 -0
  49. package/dist/sim/world.js +359 -0
  50. package/package.json +17 -3
  51. package/web/dist/THIRD-PARTY-NOTICES.txt +1 -1
  52. package/web/dist/assets/index-BQdFuM-f.css +1 -0
  53. package/web/dist/assets/index-Dh9QdEsc.js +70 -0
  54. package/web/dist/icons/apple-touch-icon.png +0 -0
  55. package/web/dist/index.html +3 -3
  56. package/web/dist/mascot/alarm.webp +0 -0
  57. package/web/dist/mascot/books.webp +0 -0
  58. package/web/dist/mascot/bow.webp +0 -0
  59. package/web/dist/mascot/branch.webp +0 -0
  60. package/web/dist/mascot/clipboard.webp +0 -0
  61. package/web/dist/mascot/dozing.webp +0 -0
  62. package/web/dist/mascot/fired-up.webp +0 -0
  63. package/web/dist/mascot/giftbox.webp +0 -0
  64. package/web/dist/mascot/halt.webp +0 -0
  65. package/web/dist/mascot/jump.webp +0 -0
  66. package/web/dist/mascot/letter-run.webp +0 -0
  67. package/web/dist/mascot/magnifier.webp +0 -0
  68. package/web/dist/mascot/mini.webp +0 -0
  69. package/web/dist/mascot/nap.webp +0 -0
  70. package/web/dist/mascot/on-duty.webp +0 -0
  71. package/web/dist/mascot/pajamas.webp +0 -0
  72. package/web/dist/mascot/paper-plane.webp +0 -0
  73. package/web/dist/mascot/peek.webp +0 -0
  74. package/web/dist/mascot/permission.webp +0 -0
  75. package/web/dist/mascot/phone.webp +0 -0
  76. package/web/dist/mascot/pointing.webp +0 -0
  77. package/web/dist/mascot/portrait.webp +0 -0
  78. package/web/dist/mascot/pout.webp +0 -0
  79. package/web/dist/mascot/proud.webp +0 -0
  80. package/web/dist/mascot/reading.webp +0 -0
  81. package/web/dist/mascot/stamp.webp +0 -0
  82. package/web/dist/mascot/stretch.webp +0 -0
  83. package/web/dist/mascot/surprised.webp +0 -0
  84. package/web/dist/mascot/tea.webp +0 -0
  85. package/web/dist/mascot/teary.webp +0 -0
  86. package/web/dist/mascot/typing.webp +0 -0
  87. package/dist/server/from-jig.js +0 -98
  88. package/web/dist/assets/index-B9oWPSod.css +0 -1
  89. package/web/dist/assets/index-C5qBMzFX.js +0 -68
@@ -0,0 +1,359 @@
1
+ /**
2
+ * Loads an evaluation's world into a fresh data folder before `yew serve` starts (docs/sim.md,
3
+ * section 2): teams, workspaces, sessions with the conversation they already had, letters, decision
4
+ * cards with the person's decisions, and scheduled tasks. Only the controller of an evaluation calls
5
+ * it, in a step of its own; no session has a tool or a route that reaches it, since it writes
6
+ * decisions as the person's.
7
+ */
8
+ import { mkdirSync, writeFileSync } from "node:fs";
9
+ import { join } from "node:path";
10
+ import { openDatabase } from "../server/db/database.js";
11
+ import { EventBus } from "../server/events.js";
12
+ import { newId } from "../server/ids.js";
13
+ import { decisionRef, letterRef, letterText } from "../server/mail/envelope.js";
14
+ import { MailStore } from "../server/mail/store.js";
15
+ import { dbPath, ensureDir } from "../server/paths.js";
16
+ import { ScheduleBook } from "../server/schedules.js";
17
+ import { Store } from "../server/store.js";
18
+ export const WORLD_FORMAT = "yew-sim-world/1";
19
+ /** The setting that keeps the world's start, for the clock when YEW_SIM_DATE is not set. */
20
+ export const SIM_SETTING = "sim";
21
+ const ZERO_USAGE = {
22
+ input: 0,
23
+ output: 0,
24
+ cacheRead: 0,
25
+ cacheWrite: 0,
26
+ totalTokens: 0,
27
+ cost: { input: 0, output: 0, cacheRead: 0, cacheWrite: 0, total: 0 },
28
+ };
29
+ function time(value, fallback, what) {
30
+ if (value === undefined)
31
+ return fallback;
32
+ const at = Date.parse(value);
33
+ if (Number.isNaN(at))
34
+ throw new Error(`${what}: "${value}" is not an ISO 8601 time.`);
35
+ return at;
36
+ }
37
+ /** Writes the world into `options.home` and returns the ids it got (docs/sim.md, section 1). */
38
+ export function loadWorld(world, options) {
39
+ if (world.format !== "yew-sim-world/1") {
40
+ throw new Error(`The world's format is "${world.format}"; this Yew Harness reads ${WORLD_FORMAT}.`);
41
+ }
42
+ const start = time(world.date, Number.NaN, "date");
43
+ if (Number.isNaN(start))
44
+ throw new Error("The world needs a date.");
45
+ const home = ensureDir(options.home);
46
+ // The global instruction file: the skill under test, or an empty one, so that nothing of the
47
+ // computer's own (~/.claude/CLAUDE.md) is read in its place.
48
+ writeFileSync(join(home, "AGENTS.md"), options.skill ?? "");
49
+ const db = openDatabase(dbPath(home));
50
+ try {
51
+ const store = new Store(db, new EventBus());
52
+ const mail = new MailStore(store);
53
+ const run = (sql, ...params) => db.prepare(sql).run(...params);
54
+ for (const provider of options.providers ?? [])
55
+ store.saveCustomProvider(provider);
56
+ store.setSetting(SIM_SETTING, { date: world.date });
57
+ if (world.settings?.language)
58
+ store.setSetting("language", world.settings.language);
59
+ if (world.settings?.defaultModel)
60
+ store.setSetting("defaultModel", world.settings.defaultModel);
61
+ const teams = new Map();
62
+ for (const team of world.teams ?? [])
63
+ teams.set(team.name, store.createGroup(team.name).id);
64
+ const workspaces = new Map();
65
+ store.setSetting("workspaces", (world.workspaces ?? []).map((workspace) => {
66
+ workspaces.set(workspace.name, workspace.path);
67
+ return { id: newId(), name: workspace.name, path: workspace.path };
68
+ }));
69
+ const sessions = new Map();
70
+ const sessionId = (name, what) => {
71
+ const id = sessions.get(name);
72
+ if (!id)
73
+ throw new Error(`${what}: there is no session named "${name}".`);
74
+ return id;
75
+ };
76
+ for (const session of world.sessions) {
77
+ if (sessions.has(session.name))
78
+ throw new Error(`Two sessions are named "${session.name}".`);
79
+ sessions.set(session.name, addSession(store, session, workspaces, teams, options, start));
80
+ }
81
+ for (const session of world.sessions) {
82
+ if (!session.openedBy)
83
+ continue;
84
+ const parent = sessionId(session.openedBy, `session "${session.name}".openedBy`);
85
+ run("UPDATE sessions SET parent_id = ? WHERE id = ?", parent, sessionId(session.name, "sessions"));
86
+ }
87
+ if (world.settings?.mainSession) {
88
+ store.setSetting("mainSessionId", sessionId(world.settings.mainSession, "settings.mainSession"));
89
+ }
90
+ // What goes into each transcript besides its own items: delivered letters and decisions.
91
+ const placed = new Map();
92
+ let order = 0;
93
+ const place = (session, item) => {
94
+ const list = placed.get(session) ?? [];
95
+ list.push({ ...item, order: order++ });
96
+ placed.set(session, list);
97
+ };
98
+ const letters = new Map();
99
+ const byKey = new Map();
100
+ for (const [index, item] of (world.letters ?? []).entries()) {
101
+ const letter = addLetter(mail, item, index, byKey, sessionId);
102
+ const at = time(item.at, start, `letter ${item.key ?? index + 1}.at`);
103
+ const delivered = item.status === "delivered" || item.status === "done";
104
+ run("UPDATE letters SET created_at = ?, updated_at = ?, delivered_at = ? WHERE id = ?", at, at, delivered ? at : null, letter.id);
105
+ if (item.key)
106
+ byKey.set(item.key, letter);
107
+ letters.set(letter.id, letter);
108
+ if (delivered) {
109
+ place(letter.toSession, {
110
+ at,
111
+ body: () => {
112
+ const decision = letter.decision
113
+ ? decisionRef(mail.cardByNumber(letter.decision))
114
+ : null;
115
+ return {
116
+ role: "user",
117
+ message: { role: "user", content: letterText(letter, decision), timestamp: at },
118
+ letter: letterRef(letter, decision),
119
+ };
120
+ },
121
+ });
122
+ }
123
+ }
124
+ const cards = {};
125
+ for (const item of [...(world.cards ?? [])].sort((a, b) => a.number - b.number)) {
126
+ const card = addCard(mail, item, sessionId, run, start);
127
+ cards[String(item.number)] = card.id;
128
+ for (const name of item.deliveredTo ?? []) {
129
+ const to = sessionId(name, `card #${item.number}.deliveredTo`);
130
+ const letter = decisionLetter(mail, card, to);
131
+ const at = card.decidedAt ?? card.updatedAt;
132
+ run("UPDATE letters SET created_at = ?, updated_at = ?, delivered_at = ? WHERE id = ?", at, at, at, letter.id);
133
+ place(to, {
134
+ at,
135
+ body: () => ({
136
+ role: "user",
137
+ message: {
138
+ role: "user",
139
+ content: letterText(letter, decisionRef(card)),
140
+ timestamp: at,
141
+ },
142
+ letter: letterRef(letter, decisionRef(card)),
143
+ }),
144
+ });
145
+ }
146
+ }
147
+ for (const session of world.sessions) {
148
+ const id = sessionId(session.name, "sessions");
149
+ let last = start;
150
+ for (const item of session.transcript ?? []) {
151
+ last = time(item.at, last, `transcript of "${session.name}"`);
152
+ const at = last;
153
+ place(id, { at, body: (nextSeq) => entryBody(item, at, nextSeq) });
154
+ }
155
+ }
156
+ for (const [id, items] of placed) {
157
+ items.sort((a, b) => a.at - b.at || a.order - b.order);
158
+ for (const item of items) {
159
+ // The entry gets the next sequence number; a compaction keeps what comes after it.
160
+ const seq = db.prepare("SELECT message_seq AS n FROM sessions WHERE id = ?").get(id);
161
+ const entry = store.appendEntry(id, item.body(seq.n + 2));
162
+ run("UPDATE messages SET created_at = ? WHERE id = ?", item.at, entry.id);
163
+ }
164
+ }
165
+ const book = new ScheduleBook(store);
166
+ for (const schedule of world.schedules ?? []) {
167
+ book.create({
168
+ name: schedule.name,
169
+ cron: schedule.cron,
170
+ session: sessionId(schedule.session, `schedule "${schedule.name}"`),
171
+ message: schedule.message,
172
+ enabled: schedule.enabled ?? true,
173
+ ...(schedule.permissionMode ? { permissionMode: schedule.permissionMode } : {}),
174
+ ...(schedule.catchUp !== undefined ? { catchUp: schedule.catchUp } : {}),
175
+ }, start);
176
+ }
177
+ // The state each session is left in, last, so that loading the transcripts does not change it.
178
+ for (const session of world.sessions) {
179
+ const id = sessionId(session.name, "sessions");
180
+ if (session.status?.state === "error") {
181
+ store.setStatus(id, "error", session.status.error);
182
+ const since = time(session.status.since, start, `session "${session.name}".status.since`);
183
+ run("UPDATE sessions SET updated_at = ?, last_activity_at = ? WHERE id = ?", since, since, id);
184
+ }
185
+ else if (session.status?.state === "archived") {
186
+ store.updateSession(id, { archived: true });
187
+ run("UPDATE sessions SET archived_at = ? WHERE id = ?", start, id);
188
+ }
189
+ }
190
+ return {
191
+ sessions: Object.fromEntries(sessions),
192
+ letters: Object.fromEntries([...byKey].map(([key, letter]) => [key, letter.id])),
193
+ cards,
194
+ };
195
+ }
196
+ finally {
197
+ db.close();
198
+ }
199
+ }
200
+ function addSession(store, session, workspaces, teams, options, start) {
201
+ const model = session.model === "under-test" ? options.underTest : session.model;
202
+ if (!model) {
203
+ throw new Error(`Session "${session.name}" is the one under test; give its model in options.underTest.`);
204
+ }
205
+ const cwd = session.workspace ? workspaces.get(session.workspace) : null;
206
+ if (session.workspace && !cwd) {
207
+ throw new Error(`Session "${session.name}": there is no workspace named "${session.workspace}".`);
208
+ }
209
+ if (cwd)
210
+ mkdirSync(cwd, { recursive: true });
211
+ const groupId = session.team ? teams.get(session.team) : null;
212
+ if (session.team && !groupId) {
213
+ throw new Error(`Session "${session.name}": there is no team named "${session.team}".`);
214
+ }
215
+ const created = store.createSession({
216
+ name: session.name,
217
+ kind: session.kind,
218
+ groupId: groupId ?? null,
219
+ responsibility: session.role ?? "",
220
+ cwd: cwd ?? null,
221
+ provider: model.provider,
222
+ model: model.model,
223
+ ...(model.thinking ? { thinking: model.thinking } : {}),
224
+ options: {
225
+ ...(session.permissionMode ? { permissionMode: session.permissionMode } : {}),
226
+ ...(session.receive ? { receive: session.receive } : {}),
227
+ ...(session.canOrganize ? { canOrganize: true } : {}),
228
+ ...(session.canPostCards ? { canPostCards: true } : {}),
229
+ },
230
+ });
231
+ store.db
232
+ .prepare("UPDATE sessions SET created_at = ?, updated_at = ?, last_activity_at = ? WHERE id = ?")
233
+ .run(start, start, start, created.id);
234
+ return created.id;
235
+ }
236
+ function addLetter(mail, item, index, byKey, sessionId) {
237
+ const what = `letter ${item.key ?? index + 1}`;
238
+ const from = item.from === "@person"
239
+ ? { fromKind: "person", fromSession: null, fromName: "the person" }
240
+ : item.from === "@cli"
241
+ ? { fromKind: "cli", fromSession: null, fromName: "yew send" }
242
+ : {
243
+ fromKind: "session",
244
+ fromSession: sessionId(item.from, what),
245
+ fromName: item.from,
246
+ };
247
+ const replyTo = item.replyTo ? byKey.get(item.replyTo) : null;
248
+ if (item.replyTo && !replyTo) {
249
+ throw new Error(`${what}: replies to "${item.replyTo}", which comes later or has no such key.`);
250
+ }
251
+ return mail.addLetter({
252
+ ...from,
253
+ toSession: sessionId(item.to, what),
254
+ kind: item.kind,
255
+ summary: item.summary,
256
+ body: item.body ?? "",
257
+ status: item.status,
258
+ ...(replyTo ? { threadId: replyTo.threadId, replyTo: replyTo.id } : {}),
259
+ ...(item.decision !== undefined ? { decision: item.decision } : {}),
260
+ });
261
+ }
262
+ function addCard(mail, item, sessionId, run, start) {
263
+ const what = `card #${item.number}`;
264
+ const options = item.options ?? [];
265
+ const index = (label, field) => {
266
+ if (label === undefined || label === null)
267
+ return null;
268
+ const found = options.findIndex((option) => option.label === label);
269
+ if (found < 0)
270
+ throw new Error(`${what}.${field}: no option is labelled "${label}".`);
271
+ return found;
272
+ };
273
+ const card = mail.addCard(item.by ? sessionId(item.by, what) : null, item.requestedBy ? sessionId(item.requestedBy, what) : null, {
274
+ title: item.title,
275
+ context: item.context ?? "",
276
+ options,
277
+ recommended: index(item.recommended, "recommended"),
278
+ deadline: item.deadline ?? null,
279
+ sessions: (item.sessions ?? []).map((name) => sessionId(name, `${what}.sessions`)),
280
+ undoable: item.undoable ?? false,
281
+ reversible: item.reversible ?? "",
282
+ after: item.after ?? "",
283
+ });
284
+ if (item.status === "decided")
285
+ mail.decideCard(card.id, index(item.choice, "choice"), item.note ?? null);
286
+ else if (item.status === "withdrawn")
287
+ mail.withdrawCard(card.id, item.withdrawnReason ?? "");
288
+ const created = time(item.createdAt, start, `${what}.createdAt`);
289
+ const decided = item.status === "decided" ? time(item.decidedAt, created, `${what}.decidedAt`) : null;
290
+ run("UPDATE cards SET number = ?, created_at = ?, updated_at = ?, decided_at = ? WHERE id = ?", item.number, created, decided ?? created, decided, card.id);
291
+ return mail.getCard(card.id);
292
+ }
293
+ /** The letter Yew sends a session with the person's decision, as when the person decides (post.ts). */
294
+ function decisionLetter(mail, card, to) {
295
+ const chosen = card.choice === null ? null : (card.options[card.choice]?.label ?? null);
296
+ return mail.addLetter({
297
+ fromKind: "person",
298
+ fromSession: null,
299
+ fromName: "the person",
300
+ toSession: to,
301
+ kind: "decision",
302
+ summary: `#${card.number} ${card.title}`,
303
+ body: [
304
+ `The person decided #${card.number}: ${card.title}`,
305
+ chosen ? `Chosen: ${chosen}` : "No option chosen; see the note.",
306
+ card.note ? `Note: ${card.note}` : null,
307
+ ]
308
+ .filter(Boolean)
309
+ .join("\n"),
310
+ status: "delivered",
311
+ decision: card.number,
312
+ });
313
+ }
314
+ function entryBody(item, timestamp, nextSeq) {
315
+ switch (item.role) {
316
+ case "user":
317
+ return { role: "user", message: { role: "user", content: item.text, timestamp } };
318
+ case "assistant":
319
+ return {
320
+ role: "assistant",
321
+ message: {
322
+ role: "assistant",
323
+ content: [
324
+ ...(item.text ? [{ type: "text", text: item.text }] : []),
325
+ ...(item.calls ?? []).map((call) => ({
326
+ type: "toolCall",
327
+ id: call.id,
328
+ name: call.tool,
329
+ arguments: call.args,
330
+ })),
331
+ ],
332
+ api: "sim",
333
+ provider: "sim",
334
+ model: "world",
335
+ usage: ZERO_USAGE,
336
+ stopReason: item.calls?.length ? "toolUse" : "stop",
337
+ timestamp,
338
+ },
339
+ };
340
+ case "toolResult":
341
+ return {
342
+ role: "toolResult",
343
+ message: {
344
+ role: "toolResult",
345
+ toolCallId: item.callId,
346
+ toolName: item.tool,
347
+ content: [{ type: "text", text: item.text }],
348
+ isError: item.isError ?? false,
349
+ timestamp,
350
+ },
351
+ };
352
+ case "compaction":
353
+ // Everything before it is summarized: the model sees the summary, then what follows.
354
+ return {
355
+ role: "compaction",
356
+ compaction: { summary: item.summary, firstKeptSeq: nextSeq, tokensBefore: 0, timestamp },
357
+ };
358
+ }
359
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tenonai/yew",
3
- "version": "1.4.0",
3
+ "version": "1.6.0",
4
4
  "description": "An AI-native multi-agent workbench",
5
5
  "keywords": [
6
6
  "agent",
@@ -26,6 +26,13 @@
26
26
  "bin": {
27
27
  "yew": "bin/yew.js"
28
28
  },
29
+ "exports": {
30
+ "./sim": {
31
+ "types": "./dist/sim/index.d.ts",
32
+ "default": "./dist/sim/index.js"
33
+ },
34
+ "./package.json": "./package.json"
35
+ },
29
36
  "files": [
30
37
  "bin",
31
38
  "dist",
@@ -44,8 +51,9 @@
44
51
  "build:web": "vite build --config web/vite.config.ts",
45
52
  "watch:web": "vite build --config web/vite.config.ts --watch",
46
53
  "relay:publish": "bash deploy/relay/publish.sh",
47
- "build": "tsc -p tsconfig.build.json && npm run build:web && node scripts/notices.mjs",
48
- "prepack": "npm run build"
54
+ "build": "node -e \"require('node:fs').rmSync('dist', { recursive: true, force: true })\" && tsc -p tsconfig.build.json && npm run build:web && node scripts/notices.mjs && tsc -p tsconfig.sim.json && node scripts/sim-types.mjs",
55
+ "prepack": "npm run build",
56
+ "audit:gate": "node scripts/audit-gate.mjs"
49
57
  },
50
58
  "devDependencies": {
51
59
  "@biomejs/biome": "2.6.6",
@@ -64,6 +72,7 @@
64
72
  "vite": "8.3.6"
65
73
  },
66
74
  "dependencies": {
75
+ "@anthropic-ai/sandbox-runtime": "0.0.83",
67
76
  "@earendil-works/pi-ai": "1.5.0",
68
77
  "@hono/node-server": "2.1.6",
69
78
  "@napi-rs/keyring": "2.1.2",
@@ -72,5 +81,10 @@
72
81
  "htmlparser2": "12.0.0",
73
82
  "uqr": "0.1.3",
74
83
  "ws": "8.22.0"
84
+ },
85
+ "overrides": {
86
+ "@anthropic-ai/sandbox-runtime": {
87
+ "zod": "4.6.6"
88
+ }
75
89
  }
76
90
  }
@@ -1,4 +1,4 @@
1
- Yew's web interface is built from these packages. Each stays under its own license.
1
+ Yew Harness's web interface is built from these packages. Each stays under its own license.
2
2
 
3
3
  ========================================================================
4
4
  @ungap/structured-clone 1.4.0 (ISC)
@@ -0,0 +1 @@
1
+ :root,:root[data-theme=light]{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light;--bg:#fff;--bg-side:#f9f9f9;--surface:#fff;--surface-2:#f3f3f3;--surface-3:#e8e8e8;--hover:#efefef;--selected:#e6e6e6;--divider:#ececec;--border:#e3e3e3;--control:#dcdcdc;--control-strong:#b5b5b5;--text:#0d0d0d;--text-2:#5d5d5d;--text-3:#666;--primary:#e6e6e6;--primary-hover:#dadada;--on-primary:#0d0d0d;--accent:#0d0d0d;--on-accent:#fff;--accent-soft:#e6e6e6;--danger:#c0262d;--warning:#9f4e08;--review:#6b38cf;--success:#23803a;--user-bubble:#f1f1f1;--code-bg:#f6f6f6;--diff-add:#e3f5e8;--diff-del:#fde8e8;--shadow:0 10px 30px #0000001a, 0 1px 4px #0000000f;--lift:0 2px 10px #0000000d;--backdrop:#00000052;--scroll-thumb:#00000030;--mark-ink:#1f3a2e;--switch-on:#2f7d4f;--watermark:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 -840 2091 1000%27%3E%3Cpath fill=%27%231f3a2e%27 fill-opacity=%270.04%27 d=%27M769 -750Q784 -750 784 -735V-705Q784 -690 769 -690Q736 -690 704.5 -667Q673 -644 644 -594L490 -333Q485 -326 485 -314V-155Q485 -115 499.5 -87.5Q514 -60 552 -60H559Q574 -60 574 -45V-15Q574 0 559 0H251Q236 0 236 -15V-45Q236 -60 251 -60H257Q295 -60 310 -87.5Q325 -115 325 -155V-309Q325 -318 319 -327L139 -594Q105 -644 81 -667Q57 -690 25 -690Q10 -690 10 -705V-735Q10 -750 25 -750H372Q387 -750 387 -735V-705Q387 -690 372 -690Q345 -690 323.5 -679.5Q302 -669 302 -643Q302 -622 319 -594L436 -407L544 -594Q566 -634 566 -657Q566 -690 520 -690Q505 -690 505 -705V-735Q505 -750 520 -750ZM829 -179Q846 -137 883.5 -104Q921 -71 979 -71Q1011 -71 1046 -89Q1081 -107 1107 -145Q1110 -150 1115 -150Q1120 -150 1125.5 -147Q1131 -144 1155 -130Q1159 -127 1159 -122Q1159 -115 1153 -105Q1125 -53 1077 -20Q1029 13 952 13Q869 13 809 -24Q749 -61 716.5 -122Q684 -183 684 -255Q684 -324 704.5 -373.5Q725 -423 759 -453.5Q793 -484 835.5 -498.5Q878 -513 922 -513Q972 -513 1010 -493.5Q1048 -474 1074.5 -444Q1101 -414 1114.5 -380.5Q1128 -347 1128 -318Q1128 -310 1119 -306ZM978 -322Q978 -370 955 -401Q932 -432 897 -432Q856 -432 832 -399.5Q808 -367 808 -318Q808 -303 809.5 -281Q811 -259 817 -241ZM2070 -500Q2085 -500 2085 -485V-455Q2085 -440 2070 -440H2055Q2039 -440 2026.5 -428Q2014 -416 1997 -378L1838 -11Q1834 0 1823 0H1766Q1755 0 1750 -11L1618 -317L1486 -11Q1482 0 1470 0H1414Q1403 0 1398 -11L1240 -377Q1224 -415 1213 -427.5Q1202 -440 1182 -440H1180Q1165 -440 1165 -455V-485Q1165 -500 1180 -500H1411Q1426 -500 1426 -485V-455Q1426 -440 1411 -440H1409Q1390 -440 1382.5 -432.5Q1375 -425 1375 -411Q1375 -398 1381.5 -381Q1388 -364 1396 -345L1476 -158L1562 -371Q1575 -401 1575 -419Q1575 -440 1554 -440H1532Q1519 -440 1519 -455V-485Q1519 -500 1533 -500H1773Q1788 -500 1788 -485V-455Q1788 -440 1773 -440H1761Q1742 -440 1734.5 -432.5Q1727 -425 1727 -411Q1727 -398 1733 -381Q1739 -364 1747 -345L1828 -158L1914 -371Q1927 -401 1927 -419Q1927 -440 1906 -440H1886Q1871 -440 1871 -455V-485Q1871 -500 1886 -500Z%27/%3E%3C/svg%3E")}:root[data-theme=dark]{--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark;--bg:#181818;--bg-side:#1f1f1f;--surface:#242424;--surface-2:#2a2a2a;--surface-3:#343434;--hover:#2a2a2a;--selected:#303030;--divider:#262626;--border:#323232;--control:#363636;--control-strong:#5c5c5c;--text:#ececec;--text-2:#b4b4b4;--text-3:#9b9b9b;--primary:#383838;--primary-hover:#444;--on-primary:#f2f2f2;--accent:#ececec;--on-accent:#121212;--accent-soft:#3a3a3a;--danger:#ff8a85;--warning:#f1ac5b;--review:#c3a3ff;--success:#7fd08d;--user-bubble:#2a2a2a;--code-bg:#1f1f1f;--diff-add:#1a3323;--diff-del:#3d1f22;--shadow:0 10px 30px #00000080, 0 1px 4px #0006;--lift:0 2px 10px #00000040;--backdrop:#0009;--scroll-thumb:#ffffff2e;--mark-ink:#e3e8e4;--switch-on:#3f9c66;--watermark:url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 -840 2091 1000%27%3E%3Cpath fill=%27%23e3e8e4%27 fill-opacity=%270.04%27 d=%27M769 -750Q784 -750 784 -735V-705Q784 -690 769 -690Q736 -690 704.5 -667Q673 -644 644 -594L490 -333Q485 -326 485 -314V-155Q485 -115 499.5 -87.5Q514 -60 552 -60H559Q574 -60 574 -45V-15Q574 0 559 0H251Q236 0 236 -15V-45Q236 -60 251 -60H257Q295 -60 310 -87.5Q325 -115 325 -155V-309Q325 -318 319 -327L139 -594Q105 -644 81 -667Q57 -690 25 -690Q10 -690 10 -705V-735Q10 -750 25 -750H372Q387 -750 387 -735V-705Q387 -690 372 -690Q345 -690 323.5 -679.5Q302 -669 302 -643Q302 -622 319 -594L436 -407L544 -594Q566 -634 566 -657Q566 -690 520 -690Q505 -690 505 -705V-735Q505 -750 520 -750ZM829 -179Q846 -137 883.5 -104Q921 -71 979 -71Q1011 -71 1046 -89Q1081 -107 1107 -145Q1110 -150 1115 -150Q1120 -150 1125.5 -147Q1131 -144 1155 -130Q1159 -127 1159 -122Q1159 -115 1153 -105Q1125 -53 1077 -20Q1029 13 952 13Q869 13 809 -24Q749 -61 716.5 -122Q684 -183 684 -255Q684 -324 704.5 -373.5Q725 -423 759 -453.5Q793 -484 835.5 -498.5Q878 -513 922 -513Q972 -513 1010 -493.5Q1048 -474 1074.5 -444Q1101 -414 1114.5 -380.5Q1128 -347 1128 -318Q1128 -310 1119 -306ZM978 -322Q978 -370 955 -401Q932 -432 897 -432Q856 -432 832 -399.5Q808 -367 808 -318Q808 -303 809.5 -281Q811 -259 817 -241ZM2070 -500Q2085 -500 2085 -485V-455Q2085 -440 2070 -440H2055Q2039 -440 2026.5 -428Q2014 -416 1997 -378L1838 -11Q1834 0 1823 0H1766Q1755 0 1750 -11L1618 -317L1486 -11Q1482 0 1470 0H1414Q1403 0 1398 -11L1240 -377Q1224 -415 1213 -427.5Q1202 -440 1182 -440H1180Q1165 -440 1165 -455V-485Q1165 -500 1180 -500H1411Q1426 -500 1426 -485V-455Q1426 -440 1411 -440H1409Q1390 -440 1382.5 -432.5Q1375 -425 1375 -411Q1375 -398 1381.5 -381Q1388 -364 1396 -345L1476 -158L1562 -371Q1575 -401 1575 -419Q1575 -440 1554 -440H1532Q1519 -440 1519 -455V-485Q1519 -500 1533 -500H1773Q1788 -500 1788 -485V-455Q1788 -440 1773 -440H1761Q1742 -440 1734.5 -432.5Q1727 -425 1727 -411Q1727 -398 1733 -381Q1739 -364 1747 -345L1828 -158L1914 -371Q1927 -401 1927 -419Q1927 -440 1906 -440H1886Q1871 -440 1871 -455V-485Q1871 -500 1886 -500Z%27/%3E%3C/svg%3E")}:root{--font:-apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;--mono:ui-monospace, "SF Mono", Menlo, Consolas, monospace;--fs-s:12px;--fs-m:14px;--fs-l:16px;--fs-xl:22px;--radius-s:8px;--radius:10px;--radius-l:16px;--cap:clamp(160px, 40dvh, 360px);--cap-tall:clamp(240px, 60dvh, 600px);--dialog-s-w:440px;--dialog-s-h:320px;--dialog-m-w:640px;--dialog-m-h:620px;--dialog-l-w:860px;--dialog-l-h:680px;font-family:var(--font);font-size:var(--fs-m);color:var(--text);background:var(--bg);line-height:1.55}*{box-sizing:border-box}body{background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;margin:0}h1,h2,h3{color:var(--text);margin:0;line-height:1.3}button,input,textarea{font:inherit;color:inherit}a{color:var(--text);text-underline-offset:2px;text-decoration:underline}:focus-visible{outline:2px solid var(--accent);outline-offset:2px}@media (prefers-reduced-motion:reduce){*,:before,:after{transition:none!important;animation:none!important}}*{scrollbar-width:thin;scrollbar-color:transparent transparent}:hover{scrollbar-color:var(--scroll-thumb) transparent}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-track{background:0 0}::-webkit-scrollbar-thumb{background:0 0;border-radius:4px}:hover::-webkit-scrollbar-thumb{background:var(--scroll-thumb)}.visually-hidden{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}.hint{color:var(--text-2);font-size:var(--fs-s)}.lockup{align-items:center;gap:7px;display:inline-flex}.lockup-mark{flex:none;width:22px;height:22px}.mark-leaf{fill:var(--mark-ink)}.wordmark{width:calc(var(--word-h,22px) * 2.091);height:var(--word-h,22px);fill:var(--mark-ink);overflow:visible}.product-name{--word-h:22px;align-items:baseline;gap:calc(var(--word-h) * .25);display:inline-flex}.product-harness{color:var(--mark-ink);font-size:calc(var(--word-h) * .64);letter-spacing:.01em;white-space:nowrap;transform:translateY(calc(var(--word-h) * -.16));font-weight:600;line-height:1}.mascot{pointer-events:none;-webkit-user-select:none;user-select:none;-webkit-user-drag:none;flex:none;display:block}.home-mascot,.page-mascot{margin:0 auto}.about-mascot{margin-bottom:6px}.page-mascot{margin-bottom:12px}.empty-state{justify-items:center;gap:4px;display:grid}@media (prefers-reduced-motion:no-preference){.home-mascot{animation:4.5s ease-in-out infinite mascot-float}}@keyframes mascot-float{50%{transform:translateY(-4px)}}.companion{align-items:flex-end;gap:4px;margin-bottom:4px;padding:0 2px;display:flex}@media (prefers-reduced-motion:no-preference){.companion-mascot{animation:.36s cubic-bezier(.34,1.56,.64,1) companion-in,4.5s ease-in-out .36s infinite mascot-float}}@keyframes companion-in{0%{opacity:0;transform:translateY(6px)scale(.92)}}.companion-bubble{border:1px solid var(--border);border-radius:var(--radius);background:var(--surface);min-width:0;box-shadow:var(--lift);color:var(--text);font:inherit;font-size:var(--fs-s);text-align:left;overflow-wrap:anywhere;text-wrap:pretty;flex:auto;margin:0 0 30px;padding:7px 10px;line-height:1.45;position:relative}.companion-bubble:before{content:"";border-bottom:1px solid var(--border);border-left:1px solid var(--border);background:inherit;width:8px;height:8px;position:absolute;bottom:12px;left:-5px;transform:rotate(45deg)}.companion-go{cursor:pointer}@media (hover:hover){.companion-go:hover{background:var(--hover)}}@media (height<=620px){.companion{display:none}}.opening{z-index:100;background:var(--bg);place-content:center;justify-items:center;gap:24px;padding:16px;animation:.2s ease-out opening-fade;display:grid;position:fixed;inset:0}.opening-leaving{opacity:0;transition:opacity .26s}.opening-stage{align-items:center;gap:14px;display:flex}.opening-mark{flex:none;overflow:visible}.opening-ring{fill:none;stroke:var(--control);stroke-width:.6px;stroke-dasharray:1;stroke-dashoffset:1px;animation:.7s ease-out forwards opening-draw}.opening-leaf{fill:var(--mark-ink);fill-opacity:0;stroke:var(--mark-ink);stroke-width:1.2px;stroke-dasharray:1;stroke-dashoffset:1px;animation:.5s ease-out .1s forwards opening-draw,.3s ease-out .45s forwards opening-fill}.opening-berry{transform-box:fill-box;transform-origin:50%;animation:.4s cubic-bezier(.34,1.56,.64,1) .3s forwards opening-pop;transform:scale(0)}.opening-seed{opacity:0;animation:.2s ease-out .6s forwards opening-show}.opening-word{--word-h:52px;opacity:0;animation:.4s ease-out .45s forwards opening-settle;transform:translate(-8px)}.opening-mascot{opacity:0;margin-left:4px;animation:.45s cubic-bezier(.34,1.56,.64,1) .6s forwards opening-settle;transform:translateY(10px)scale(.9)}@media (width<=560px){.opening-stage{flex-wrap:wrap;justify-content:center}.opening-word{--word-h:40px}}.opening-steps{min-width:240px;color:var(--text-3);font-size:var(--fs-s);gap:4px;margin:0;padding:0;list-style:none;display:grid}.opening-step{opacity:.6;gap:8px;transition:opacity .2s;display:flex}.opening-step.done{color:var(--text-2);opacity:1}.opening-tick{text-align:center;width:1em}.opening-skip{color:var(--text-3);font-size:var(--fs-s)}.opening-enter{color:var(--text-2);font-weight:600}@keyframes opening-draw{to{stroke-dashoffset:0}}@keyframes opening-fill{to{fill-opacity:1}}@keyframes opening-pop{to{transform:scale(1)}}@keyframes opening-fade{0%{opacity:0}}@keyframes opening-show{to{opacity:1}}@keyframes opening-settle{to{opacity:1;transform:none}}.btn{border-radius:var(--radius-s);min-height:32px;color:var(--text);font-size:var(--fs-m);cursor:pointer;white-space:nowrap;appearance:none;background:0 0;border:1px solid #0000;justify-content:center;align-items:center;gap:6px;padding:0 12px;display:inline-flex}a.btn{text-decoration:none}.btn:disabled{opacity:.45;cursor:not-allowed}.btn svg{flex:none;width:16px;height:16px}.btn-primary{background:var(--primary);border-color:var(--primary);color:var(--on-primary);font-weight:600}.btn-danger{color:var(--danger)}.btn-ghost{background:0 0;border-color:#0000}.btn-icon{border-radius:var(--radius-s);width:32px;color:var(--text-2);padding:0}.btn[aria-busy=true]{cursor:progress}.btn[aria-busy=true]:before{content:"";border:2px solid;border-right-color:#0000;border-radius:50%;width:12px;height:12px;animation:.8s linear infinite spin}@media (hover:hover){.btn:not(:disabled):hover{background:var(--hover);color:var(--text)}.btn-primary:not(:disabled):hover{background:var(--primary-hover);border-color:var(--primary-hover);color:var(--on-primary)}}@keyframes spin{to{transform:rotate(360deg)}}.input,.textarea{border:1px solid var(--control);border-radius:var(--radius);background:var(--surface);width:100%;min-height:36px;font-size:var(--fs-m);appearance:none;padding:7px 12px}.input::placeholder,.textarea::placeholder{color:var(--text-3)}.input:focus-visible,.textarea:focus-visible{border-color:var(--control-strong);outline:none}.textarea{resize:none;field-sizing:content;min-height:64px;line-height:1.55}.textarea-large{min-height:96px}.field-row{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;display:grid}.input[aria-invalid=true],.textarea[aria-invalid=true]{border-color:var(--danger)}.secret-input{-webkit-text-security:disc}.field{gap:6px;display:grid}.field-label{align-items:center;gap:2px;font-weight:600;display:inline-flex}.field-head{justify-content:space-between;align-items:center;gap:8px;display:flex}.folder-box{border:1px dashed var(--control-strong);border-radius:var(--radius);min-height:52px;color:var(--text-3);align-items:center;gap:10px;padding:0 14px;display:flex}.folder-box:focus-within{border-style:solid}.folder-box input{min-width:0;color:var(--text);background:0 0;border:none;outline:none;flex:1}.folder-box input::placeholder{color:var(--text-3)}.field-error{color:var(--danger);font-size:var(--fs-s)}.switch{cursor:pointer;text-align:left;background:0 0;border:none;align-items:center;gap:10px;padding:4px 0;font-weight:600;display:inline-flex}.switch-track{border:1px solid var(--control);background:var(--surface-3);border-radius:10px;flex:none;width:36px;height:20px;transition:background .15s;position:relative}.switch-thumb{background:var(--text-2);border-radius:50%;width:14px;height:14px;transition:transform .15s;position:absolute;top:2px;left:2px}.switch[aria-checked=true] .switch-track{background:var(--switch-on);border-color:var(--switch-on)}.switch[aria-checked=true] .switch-thumb{background:var(--on-accent);transform:translate(16px)}.select-trigger{border-radius:var(--radius);border-color:var(--control);justify-content:space-between;width:100%;min-width:0;min-height:36px;padding:0 12px}.select-trigger span{text-overflow:ellipsis;overflow:hidden}.select-trigger:after{content:"";border-bottom:1.5px solid;border-right:1.5px solid;flex:none;width:6px;height:6px;transform:rotate(45deg)translateY(-2px)}.listbox,.menu{border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);color:var(--text);box-shadow:var(--shadow);min-width:180px;margin:0;padding:5px;position:fixed}.listbox{overscroll-behavior:contain;max-height:min(360px,60dvh);overflow-y:auto}.listbox [role=option],.menu [role^=menuitem]{border-radius:var(--radius-s);cursor:pointer;text-align:left;width:100%;min-height:32px;font-size:var(--fs-m);background:0 0;border:none;align-items:center;gap:8px;margin:2px 0;padding:4px 10px;display:flex}.listbox [role=option][aria-selected=true]{font-weight:600}.listbox [role=option][aria-selected=true]:after{content:"✓";margin-left:auto}.listbox [role=option].active,.menu [role^=menuitem]:focus-visible{background:var(--hover);outline:none}.listbox .option-text{flex-direction:column;gap:1px;padding:3px 0;display:flex}.listbox .option-hint{font-size:var(--fs-s);color:var(--text-3);font-weight:400}.listbox .group-label{font-size:var(--fs-s);color:var(--text-3);padding:6px 10px 2px}.menu-danger{color:var(--danger)}.menu-label{flex:1;min-width:0}.menu-check{color:var(--text-2)}.menu-detail{text-overflow:ellipsis;white-space:nowrap;max-width:8em;color:var(--text-3);font-size:var(--fs-s);flex:none;overflow:hidden}.menu-heading{font-size:var(--fs-s);color:var(--text-3);padding:6px 10px 2px}.menu-separator{background:var(--border);border:none;height:1px;margin:5px 6px}.menu .menu-parent[aria-expanded=true]{background:var(--hover)}.menu .menu-arrow{color:var(--text-3);flex:none;margin-left:auto}@media (hover:hover){.listbox [role=option]:hover,.menu [role^=menuitem]:hover{background:var(--hover)}}.info-button{width:24px;height:24px;color:var(--text-3);cursor:pointer;border-radius:var(--radius-s);background:0 0;border:none;place-items:center;padding:0;display:inline-grid}.info-button svg{width:15px;height:15px}.info-button[aria-expanded=true]{color:var(--text)}@media (hover:hover){.info-button:hover{color:var(--text)}}.toggletip{border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);width:260px;max-width:calc(100vw - 32px);color:var(--text);box-shadow:var(--shadow);font-weight:400;font-size:var(--fs-s);margin:0;padding:12px 14px;line-height:1.6;position:fixed}.dialog{border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);color:var(--text);box-shadow:var(--shadow);max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);padding:0;overflow:hidden}.dialog::backdrop{background:var(--backdrop)}.dialog-s{width:var(--dialog-s-w);height:min(var(--dialog-s-h), calc(100dvh - 32px))}.dialog-m{width:var(--dialog-m-w);height:min(var(--dialog-m-h), calc(100dvh - 32px))}.dialog-l{width:var(--dialog-l-w);height:min(var(--dialog-l-h), calc(100dvh - 32px))}.dialog-frame{grid-template-rows:auto 1fr auto;height:100%;display:grid}.dialog-header{justify-content:space-between;align-items:center;gap:12px;padding:14px 16px 10px 22px;display:flex}.dialog-header h2{font-size:var(--fs-l);font-weight:600}.dialog-body{overscroll-behavior:contain;align-content:start;gap:16px;padding:8px 22px 18px;display:grid;overflow-y:auto}.dialog-body>p{margin:0}.dialog-footer{border-top:1px solid var(--divider);justify-content:flex-end;align-items:center;gap:8px;padding:12px 22px 16px;display:flex}.unsaved{margin-right:auto}.settings-window{width:var(--dialog-l-w);height:min(var(--dialog-l-h), calc(100dvh - 32px))}.settings-frame{grid-template-columns:208px minmax(0,1fr);height:100%;display:grid}.settings-nav{border-right:1px solid var(--divider);background:var(--bg-side);flex-direction:column;gap:2px;min-height:0;padding:14px 10px 12px;display:flex;overflow-y:auto}.settings-nav-head{justify-content:space-between;align-items:center;gap:8px;min-height:36px;padding:0 6px 8px 10px;display:flex}.settings-nav-head h2{font-size:var(--fs-l);font-weight:600}.settings-nav-list{gap:2px;margin:0;padding:0;list-style:none;display:grid}.settings-nav-item{border-radius:var(--radius);width:100%;min-height:36px;color:var(--text);font:inherit;text-align:left;cursor:pointer;background:0 0;border:none;align-items:center;gap:10px;padding:0 10px;text-decoration:none;display:flex}.settings-nav-item svg{width:16px;height:16px;color:var(--text-2);flex:none}.settings-nav-item[aria-current=true]{background:var(--selected);font-weight:600}@media (hover:hover){.settings-nav-item:not([aria-current=true]):hover{background:var(--hover)}}.settings-feedback{margin-top:auto}.settings-pane{flex-direction:column;min-width:0;min-height:0;display:flex}.settings-back{align-self:flex-start;margin:12px 0 0 14px}.dialog-panel{flex-direction:column;flex:1;min-height:0;display:flex}.panel-body{flex:1;min-height:0}@media (width<=760px){.settings-window{width:calc(100vw - 32px);height:calc(100dvh - 32px)}.settings-frame{grid-template-columns:minmax(0,1fr)}.settings-nav{background:0 0;border-right:none}}body.scroll-locked{overflow:hidden}.app{grid-template-columns:260px minmax(0,1fr);height:100dvh;display:grid;position:relative;overflow:hidden}.app.app-collapsed{grid-template-columns:56px minmax(0,1fr)}.yew-backdrop{object-fit:contain;object-position:right bottom;pointer-events:none;-webkit-user-select:none;user-select:none;-webkit-user-drag:none;grid-area:1/2;max-width:calc(50vw - 534px);height:calc(100% - 72px);display:none;position:absolute;bottom:0;right:16px}.app-collapsed .yew-backdrop{max-width:calc(50vw - 432px)}:root[data-theme=dark] .yew-backdrop{opacity:.86}@media (width>=1468px){.app.with-yew:not(.app-collapsed) .yew-backdrop{display:block}.app.with-yew:not(.app-collapsed) .main:not(.center-main){background-image:none}.app.with-yew:not(.app-collapsed) .home-mascot{display:none}}@media (width>=1264px){.app.with-yew.app-collapsed .yew-backdrop{display:block}.app.with-yew.app-collapsed .main:not(.center-main){background-image:none}.app.with-yew.app-collapsed .home-mascot{display:none}}.rail{background:var(--bg-side);min-height:0;box-shadow:inset -1px 0 0 var(--divider);flex-direction:column;align-items:center;gap:2px;padding:12px 0 14px;display:flex}.rail-brand{border-radius:var(--radius-s);width:40px;height:40px;color:var(--text);cursor:pointer;background:0 0;border:none;place-items:center;margin-bottom:8px;display:grid}.rail-mark{display:grid}.rail-open{color:var(--text-2);display:none}.rail-brand:hover .rail-mark,.rail-brand:focus-visible .rail-mark{display:none}.rail-brand:hover .rail-open,.rail-brand:focus-visible .rail-open{display:grid}@media (hover:hover){.rail-brand:hover{background:var(--hover)}}.rail .btn-icon{width:40px;min-height:40px}.rail .btn-icon[aria-current=page]{background:var(--selected);color:var(--text)}.rail-spacer{flex:1}.drawer-backdrop{z-index:15;background:var(--backdrop);position:fixed;inset:0}.center-page{text-align:center;place-items:center;height:100dvh;padding:16px;display:grid}.center-page>div{justify-items:center;gap:12px;max-width:440px;display:grid}.center-page h1{font-size:var(--fs-xl)}.banner{background:var(--surface-2);color:var(--text-2);font-size:var(--fs-s);text-align:center;padding:8px 16px}.sidebar{background:var(--bg-side);border-right:1px solid var(--divider);grid-template-rows:auto auto minmax(0,1fr) auto;grid-template-columns:minmax(0,1fr);min-height:0;display:grid}.sidebar-top{justify-content:space-between;align-items:center;min-height:60px;padding:16px 12px 12px 17px;display:flex}.sidebar-nav{grid-template-columns:minmax(0,1fr);gap:6px;padding:4px 10px 16px;display:grid}.nav-row{border-radius:var(--radius);width:100%;min-height:36px;color:var(--text);text-align:left;cursor:pointer;background:0 0;border:none;align-items:center;gap:10px;padding:0 10px;display:flex}.nav-row svg{width:16px;height:16px;color:var(--text-2);flex:none}.nav-row[aria-current=page]{background:var(--selected);font-weight:600}@media (hover:hover){.nav-row:not([aria-current=page]):hover{background:var(--hover)}}.sidebar-search,.search-field{position:relative}.search-field svg{width:15px;height:15px;color:var(--text-3);pointer-events:none;position:absolute;top:50%;left:11px;transform:translateY(-50%)}.search-field .input{background:var(--hover);border-color:#0000;min-height:36px;padding-left:34px}.search-field .input:focus-visible{border-color:var(--control);background:var(--bg)}.sidebar-list{overscroll-behavior:contain;padding:0 10px 10px;overflow-y:auto}.empty-box{border:1px dashed var(--control-strong);border-radius:var(--radius);color:var(--text-3);font-size:var(--fs-s);margin:2px 0 6px;padding:10px 12px}.lockup-button{border-radius:var(--radius-s);color:inherit;font:inherit;cursor:pointer;background:0 0;border:none;margin:-4px -6px;padding:4px 6px}.sidebar-bottom{padding:8px 10px 14px}.group-heading{min-height:30px;font-size:var(--fs-s);color:var(--text-3);justify-content:space-between;align-items:center;margin-top:14px;padding:0 2px 0 10px;font-weight:600;display:flex}.group-heading .btn-icon{width:28px;min-height:28px}.heading-text{text-overflow:ellipsis;white-space:nowrap;flex:auto;min-width:0;overflow:hidden}.heading-filter{color:var(--text-2)}.archived-toggle{font-size:var(--fs-s);color:var(--text-2);margin:10px 0 0}.session-item{position:relative}.session-row{border-radius:var(--radius);text-align:left;cursor:pointer;width:100%;min-height:36px;color:var(--text);background:0 0;border:none;grid-template-columns:16px minmax(0,1fr) auto auto;align-items:center;gap:8px;margin:2px 0;padding:0 10px;display:grid}.session-row:is([aria-current=true],[aria-pressed=true]){background:var(--selected);font-weight:600}@media (hover:hover){.session-row:not([aria-current=true],[aria-pressed=true]):hover{background:var(--hover)}}.session-icon{width:16px;height:16px;color:var(--text-3);display:inline-grid;position:relative}.session-icon svg{width:16px;height:16px}.pin-icon{width:12px;height:12px;color:var(--text-3)}.session-row-editing{cursor:default;background:var(--selected);grid-template-columns:16px minmax(0,1fr)}.row-input{border:1px solid var(--control-strong);background:var(--surface);min-width:0;height:26px;color:var(--text);font:inherit;border-radius:6px;outline:none;padding:0 6px}.row-error{grid-column:1/-1;padding:0 0 6px 24px}.session-name{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.session-time{font-size:var(--fs-s);color:var(--text-3);white-space:nowrap;font-weight:400}.session-row-menu{position:absolute;top:50%;right:4px;transform:translateY(-50%)}.session-row-menu .btn-icon{width:28px;min-height:28px}@media (hover:hover){.session-item:not(:hover,:focus-within) .session-row-menu,.group-heading:not(:hover,:focus-within) .btn-icon:not(.heading-add){opacity:0}.session-item:is(:hover,:focus-within) :is(.session-time,.badge,.row-dot,.unread-count){visibility:hidden}}@media (hover:none){.session-row{padding-right:38px}.session-row .session-time{display:none}}.badge{background:var(--surface-3);min-width:18px;height:18px;color:var(--text);font-size:var(--fs-s);border-radius:5px;place-items:center;padding:0 5px;font-weight:600;line-height:1;display:inline-grid}.dot{border-radius:50%;width:8px;height:8px}.dot-working{background:var(--accent);animation:1.4s ease-in-out infinite pulse}.dot-waiting{background:var(--warning)}.dot-error{background:var(--danger)}.dot-needs_review{background:var(--review)}.dot-idle{background:0 0}.unread-count{min-width:18px;color:var(--text-2);font-size:var(--fs-s);font-variant-numeric:tabular-nums;text-align:center;font-weight:600}.row-dot{width:6px;height:6px;margin:0 5px}@keyframes pulse{50%{opacity:.35}}.search-results{z-index:5;overscroll-behavior:contain;border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);max-height:60dvh;box-shadow:var(--shadow);padding:5px;position:absolute;top:40px;left:0;right:0;overflow-y:auto}.search-hit{border-radius:var(--radius-s);text-align:left;cursor:pointer;background:0 0;border:none;width:100%;margin:2px 0;padding:6px 8px;display:block}.search-hit-row{align-items:center;gap:8px;display:flex}.search-hit-row svg{color:var(--text-3);flex:none}.search-hit-row .hint{text-overflow:ellipsis;white-space:nowrap;margin-left:auto;overflow:hidden}.search-hit mark{background:var(--accent-soft);color:inherit;font-weight:600}@media (hover:hover){.search-hit:hover{background:var(--hover)}}.main{background:var(--bg);grid-template-rows:auto minmax(0,1fr) auto;grid-template-columns:minmax(0,1fr);min-width:0;min-height:0;display:grid;overflow-y:auto}.main:not(.center-main){background-image:var(--watermark);background-position:right 4% bottom 26%;background-repeat:no-repeat;background-size:min(44%,560px)}.main-home{grid-template-rows:minmax(0,1fr);position:relative}.home-menu{position:absolute;top:10px;left:8px}.home{place-self:center;gap:16px;width:min(760px,100%);padding:32px 20px 14dvh;display:grid}.home-intro{text-align:center;justify-items:center;gap:14px;display:grid}.home h1{font-size:var(--fs-xl);font-weight:600}.suggestions{flex-wrap:wrap;justify-content:center;gap:8px;display:flex}.suggestion{color:var(--text-2);background:0 0}.suggestion svg{color:var(--text-3)}.suggestion[aria-pressed=true]{background:var(--selected);border-color:var(--control);color:var(--text);font-weight:600}.home-more{color:var(--text-2);font-size:var(--fs-s);justify-self:center}.session-header{align-items:center;gap:8px;min-height:52px;padding:8px 12px 8px 20px;display:flex}.session-title{flex:auto;align-items:baseline;gap:10px;min-width:0;display:flex}.session-title h1{min-width:0;font-size:var(--fs-m);text-overflow:ellipsis;white-space:nowrap;flex:0 auto;font-weight:600;overflow:hidden}.session-meta{min-width:0;color:var(--text-3);font-size:var(--fs-s);text-overflow:ellipsis;white-space:nowrap;flex:0 auto;overflow:hidden}.session-aside{flex:0 100 auto;justify-content:flex-end;align-items:center;gap:8px;min-width:0;display:flex}.model-picker{flex-wrap:wrap;gap:6px;display:flex}.model-picker .select-trigger{width:auto;max-width:220px}.model-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;display:grid}.model-grid .field-label{color:var(--text-2);font-weight:400;font-size:var(--fs-s)}.session-body{grid-template-columns:minmax(0,1fr);min-height:160px;display:grid;position:relative}.transcript{overscroll-behavior:contain;padding:8px 20px 24px;position:relative;overflow-y:auto}.transcript-inner{grid-template-columns:minmax(0,1fr);gap:14px;max-width:760px;margin:0 auto;display:grid}.new-messages{border-color:var(--divider);background:var(--surface);box-shadow:var(--shadow);margin:0 auto;position:sticky;bottom:8px}.msg-user{border-radius:var(--radius-l);background:var(--user-bubble);white-space:pre-wrap;overflow-wrap:anywhere;justify-self:end;max-width:80%;padding:9px 14px}.msg-assistant{grid-template-columns:minmax(0,1fr);gap:6px;min-width:0;display:grid}.message-mine{justify-items:end;gap:2px;display:grid}.message-actions{opacity:0;align-items:center;gap:2px;min-height:28px;transition:opacity .12s;display:flex}.message-actions time{margin-right:4px;font-size:12px}.message-mine:hover .message-actions,.msg-assistant:hover .message-actions,.message-actions:focus-within{opacity:1}@media (hover:none){.message-actions{opacity:1}}.step-group{grid-template-columns:minmax(0,1fr);gap:2px;display:grid}.step-list{border-left:2px solid var(--divider);grid-template-columns:minmax(0,1fr);gap:2px;margin:2px 0 4px 5px;padding-left:14px;display:grid}.msg-tool+.msg-tool{margin-top:-10px}.markdown{overflow-wrap:anywhere;line-height:1.65}.markdown>:first-child{margin-top:0}.markdown>:last-child{margin-bottom:0}.markdown h1,.markdown h2,.markdown h3{font-size:var(--fs-l);margin:18px 0 8px}.markdown pre,.code{border-radius:var(--radius);background:var(--code-bg);font-family:var(--mono);font-size:var(--fs-s);margin:0;padding:10px 12px;line-height:1.55;overflow-x:auto}.markdown code{font-family:var(--mono);font-size:var(--fs-s)}.markdown :not(pre)>code{background:var(--code-bg);border-radius:5px;padding:1px 5px}.markdown table{border-collapse:collapse;display:block;overflow-x:auto}.markdown th,.markdown td{border:1px solid var(--divider);padding:4px 8px}.activity>summary{border-radius:var(--radius-s);width:fit-content;max-width:100%;min-height:28px;color:var(--text-2);cursor:pointer;align-items:center;gap:6px;padding:2px 6px 2px 0;list-style:none;display:flex}.activity>summary::-webkit-details-marker{display:none}.activity-verb{flex:none;font-weight:600}.activity-count{flex:0 auto;min-width:0}.chevron{width:12px;height:12px;color:var(--text-3);flex:none;transition:transform .15s}.activity[open]>summary .chevron{transform:rotate(90deg)}@media (hover:hover){.activity>summary:hover{color:var(--text)}}.tool-summary{min-width:0;color:var(--text-3);font-family:var(--mono);font-size:var(--fs-s);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.tool-stat{font-family:var(--mono);font-size:var(--fs-s);flex:none}.stat-add{color:var(--success)}.stat-del{color:var(--danger)}.tool-state{font-size:var(--fs-s);flex:none}.tool-state-error,.tool-state-denied{color:var(--danger)}.tool-state-waiting{color:var(--warning)}.tool-state-needs_review{color:var(--review)}.shimmer{background:linear-gradient(90deg, var(--text-3) 25%, var(--text) 50%, var(--text-3) 75%) 0 0 / 200% 100%;color:#0000;-webkit-background-clip:text;background-clip:text;animation:1.8s linear infinite shimmer}@keyframes shimmer{to{background-position:-200% 0}}.tool-detail{border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);grid-template-columns:minmax(0,1fr);gap:8px;margin:4px 0 6px;padding:10px 12px 12px;display:grid}.tool-detail h2{font-size:var(--fs-s);color:var(--text-3);margin-top:2px;font-weight:600}.thinking-body{border-left:2px solid var(--divider);color:var(--text-2);font-size:var(--fs-s);white-space:pre-wrap;overflow-wrap:anywhere;margin:4px 0 4px 5px;padding-left:12px}.note-body{margin:4px 0}.output{max-height:var(--cap);overscroll-behavior:contain;white-space:pre-wrap;overflow:auto}.diff{border-radius:var(--radius);background:var(--code-bg);font-family:var(--mono);font-size:var(--fs-s);overscroll-behavior:contain;max-height:420px;margin:0;padding:6px 0;overflow:auto}.diff div{white-space:pre;padding:0 12px}.diff .add{background:var(--diff-add)}.diff .del{background:var(--diff-del)}.diff .hunk{color:var(--text-3)}.card{border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);min-width:0}.request-card{border-color:var(--border);grid-template-columns:minmax(0,1fr);gap:12px;padding:14px 16px 16px;display:grid}.request-card,.decision-card{container-type:inline-size}.card-head{color:var(--text-2);font-size:var(--fs-s);grid-template-columns:auto minmax(0,1fr) auto;align-items:start;gap:6px 8px;line-height:18px;display:grid}.card-head>svg{color:var(--text-3);margin-top:1px}.card-head-parts{flex-wrap:wrap;min-width:0;display:flex}.card-head-parts>span:not(:last-child):after{content:"·";color:var(--text-3);margin:0 6px}.card-head-tags{flex-wrap:wrap;justify-content:flex-end;gap:6px;display:flex}@container (width<=480px){.card-head-tags{grid-area:2/2;justify-content:flex-start}}.request-title{font-size:var(--fs-m);overflow-wrap:anywhere;margin:0;font-weight:600}.request-question{white-space:pre-wrap}.request-description{overscroll-behavior:contain;max-height:7.5em;color:var(--text-2);white-space:pre-wrap;overflow-wrap:anywhere;margin-top:-6px;overflow-y:auto}.request-list{gap:4px;margin:0;padding-left:18px;display:grid}.request-card .diff{max-height:260px}.request-code{white-space:pre-wrap;overflow-wrap:anywhere;max-height:180px;overflow:auto}.question-option{border-color:var(--control)}.request-always{text-overflow:ellipsis;max-width:320px;overflow:hidden}.request-actions{flex-wrap:wrap;align-items:center;gap:8px;display:flex}.notice{color:var(--text-3);font-size:var(--fs-s);text-align:center;justify-self:center;max-width:90%;margin:0}.notice-error{color:var(--danger)}.composer{background:var(--bg);padding:0 20px 18px}.composer-inner{gap:8px;width:100%;max-width:760px;margin:0 auto;display:grid}.composer-box{border:1px solid var(--control);border-radius:var(--radius-l);background:var(--surface);box-shadow:var(--lift);gap:4px;padding:10px 10px 8px;display:grid}.composer-box:focus-within{border-color:var(--control-strong)}.composer-box textarea{resize:none;field-sizing:content;background:0 0;border:none;outline:none;width:100%;min-height:48px;max-height:40dvh;padding:4px 8px;line-height:1.55;overflow-y:auto}.composer-box textarea::placeholder{color:var(--text-3)}.composer-bar{align-items:flex-end;gap:4px;min-width:0;display:flex}.composer-chips{flex-wrap:wrap;flex:1;align-items:center;min-width:0;display:flex}.composer-chips .model-picker{display:contents}.composer-bar .select-trigger{border-radius:var(--radius-s);width:auto;max-width:200px;min-height:32px;color:var(--text-2);background:0 0;border-color:#0000;gap:6px;padding:0 10px}:root{--cell:32px}.composer-actions{flex:none;align-items:center;gap:2px;display:flex}.composer-actions>.btn,.context-pie{width:var(--cell);height:var(--cell);min-height:var(--cell)}.context-pie{color:var(--text-2);flex:none;place-items:center;display:inline-grid}.context-pie-high{color:var(--warning)}.send-button{border-radius:var(--radius-s);width:34px;height:34px;min-height:34px;color:var(--text);background:0 0;border:none;flex:none;padding:0}.send-button:disabled{color:var(--text-3);opacity:1;background:0 0}.send-button[aria-busy=true]{color:var(--text)}.send-button[aria-busy=true] svg{display:none}@media (hover:hover){.send-button:not(:disabled):hover{background:var(--hover);color:var(--text)}}.queued{gap:6px;display:grid}.queued-item{border:1px dashed var(--control);border-radius:var(--radius-l);color:var(--text-2);white-space:pre-wrap;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:6px;padding:6px 8px 6px 14px;display:grid}.error-box{border:1px solid var(--danger);border-radius:var(--radius);color:var(--text);gap:6px;padding:10px 12px;display:grid}.error-id{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.error-code{font-family:var(--mono);font-size:var(--fs-s)}.settings-section{gap:20px;display:grid}.settings-section>h2{font-size:var(--fs-l);font-weight:600}.provider-group>h3{font-size:var(--fs-s);color:var(--text-3);margin:8px 0 4px;font-weight:600}.provider-row{border-bottom:1px solid var(--border);grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:8px;padding:10px 0;display:grid}.provider-key{gap:6px;margin-top:8px;display:grid}.provider-detail p{overflow-wrap:anywhere;margin:4px 0 0}.provider-failed{color:var(--danger)}.setting-group{gap:8px;display:grid}.setting-group-title{font-size:var(--fs-s);color:var(--text-2);align-items:center;gap:2px;margin:0;font-weight:600;display:inline-flex}.setting-box{border:1px solid var(--border);border-radius:var(--radius-l);display:grid;overflow:hidden}.setting-row{justify-content:space-between;align-items:center;gap:16px;min-height:56px;padding:10px 14px;display:flex}.setting-row+.setting-row{border-top:1px solid var(--border)}.setting-text{gap:2px;min-width:0;display:grid}.setting-label{align-items:center;gap:2px;font-weight:500;display:inline-flex}.setting-control{flex:none;align-items:center;gap:8px;display:flex}.setting-control .select-trigger{width:9em}.input-number{text-align:right;font-variant-numeric:tabular-nums;width:7em}@media (width<=480px){.setting-row:not(:has(.switch)){flex-direction:column;align-items:stretch;gap:8px}.setting-control .select-trigger,.input-number{width:100%}}.rules-empty{color:var(--text-3);margin:0;padding:14px 16px}.allowed-row{border-top:1px solid var(--border);align-items:center;gap:8px;min-height:44px;padding:6px 8px 6px 14px;display:flex}.allowed-row:first-child{border-top:none}.allowed-text{min-width:0;font-family:var(--mono);font-size:var(--fs-s);overflow-wrap:anywhere;flex:auto}.about{gap:24px}.about-head{gap:8px;display:grid}.about-version{color:var(--text-3);font-size:var(--fs-s);margin:0}.about-text{gap:12px;display:grid}.about-text p{margin:0;line-height:1.75}.about-list{border:1px solid var(--border);border-radius:var(--radius-l);display:grid;overflow:hidden}.about-row{border:none;border-top:1px solid var(--border);width:100%;min-height:48px;color:var(--text);font-size:var(--fs-m);text-align:left;background:0 0;justify-content:space-between;align-items:center;gap:12px;padding:0 16px;display:flex}.about-row:first-child{border-top:none}button.about-row{cursor:pointer}@media (hover:hover){button.about-row:hover{background:var(--hover)}}.about-label{color:var(--text-2)}.publisher-mark{color:var(--text);align-items:center;gap:5.4px;font-size:13.5px;font-weight:600;display:inline-flex}.publisher-mark img{flex:none}.todo-card{z-index:5;border:1px solid var(--divider);border-radius:var(--radius-l);background:var(--surface);width:max-content;min-width:min(220px,100% - 32px);max-width:min(360px,100% - 32px);box-shadow:var(--shadow);font-size:var(--fs-s);position:absolute;top:8px;right:16px}.todo-toggle{border-radius:inherit;width:100%;min-height:32px;color:var(--text-2);font:inherit;cursor:pointer;background:0 0;border:none;align-items:center;gap:6px;padding:4px 10px;display:flex}.todo-card .todo-toggle>svg{flex:none}.todo-count{font-variant-numeric:tabular-nums;flex:none;font-weight:600}.todo-current{text-overflow:ellipsis;white-space:nowrap;min-width:0;max-width:220px;color:var(--text);overflow:hidden}.todo-card .todo-toggle svg.chevron{margin-left:auto;transform:rotate(90deg)}.todo-card.open .todo-toggle svg.chevron{transform:rotate(-90deg)}@media (hover:hover){.todo-toggle:hover{color:var(--text)}}.todo-card ol{contain:inline-size;overscroll-behavior:contain;gap:8px;max-height:min(50dvh,420px);margin:0;padding:2px 12px 12px;list-style:none;display:grid;overflow-y:auto}.todo-card ol[hidden]{display:none}.todo-card li{overflow-wrap:anywhere;grid-template-columns:14px minmax(0,1fr);gap:8px;display:grid}.todo-card .todo-list svg{color:var(--text-3);margin-top:2px}.todo-done{color:var(--text-3);text-decoration:line-through}.todo-in_progress{font-weight:600}.todo-card .todo-in_progress>svg{color:var(--text)}.transcript,.dialog-body,.sidebar-list,.dialog-body{--fade-bg:var(--surface)}.sidebar-list{--fade-bg:var(--bg-side)}@media (width<=760px){.app{grid-template-columns:minmax(0,1fr)}.sidebar{display:none}.app.sidebar-open .sidebar{z-index:20;width:min(300px,85vw);box-shadow:var(--shadow);display:grid;position:fixed;inset:0 auto 0 0}.todo-current{display:none}.model-grid{grid-template-columns:1fr 1fr}.field-row{grid-template-columns:minmax(0,1fr)}.session-header{padding-left:8px}.transcript{padding:8px 14px 20px}.composer{padding:0 10px 10px}.composer-bar .select-trigger{max-width:120px}}@media (width>=761px){.only-narrow{display:none}}.session-header .btn-icon svg,.sidebar-bottom .btn svg{width:16px;height:16px}.menu [role^=menuitem] svg{width:16px;height:16px;color:var(--text-2);flex:none}.nav-label{flex:none}.nav-detail{text-overflow:ellipsis;white-space:nowrap;min-width:0;color:var(--text-3);font-size:var(--fs-s);flex:0 auto;overflow:hidden}.nav-row .badge{margin-left:auto}.rail .rail-center{position:relative}.rail-badge{background:var(--surface-3);min-width:15px;height:15px;color:var(--text);text-align:center;border-radius:4px;padding:0 3px;font-size:10px;font-weight:600;line-height:15px;position:absolute;top:2px;right:2px}.session-item[data-child=true]{margin-left:calc(var(--depth,1) * 14px)}.tag{border:1px solid var(--control);height:18px;color:var(--text-2);font-size:var(--fs-s);white-space:nowrap;border-radius:5px;flex:none;align-items:center;padding:0 6px;font-weight:500;line-height:1;display:inline-flex}.tag-danger{color:var(--danger);border-color:currentColor}.tag-deadline{max-width:14em;color:var(--warning);text-overflow:ellipsis;line-height:16px;display:inline-block;overflow:hidden}.link-button{color:inherit;font:inherit;text-decoration:underline;-webkit-text-decoration-color:var(--control-strong);text-decoration-color:var(--control-strong);text-underline-offset:2px;cursor:pointer;background:0 0;border:none;padding:0}.link-button:hover{text-decoration-color:currentColor}.session-parent{color:var(--text-3);font-size:var(--fs-s);flex:none}.center-main{grid-template-rows:auto minmax(0,1fr)}.center-body{overscroll-behavior:contain;padding:8px 20px 32px;overflow-y:auto}.center-inner,.center-panel{grid-template-columns:minmax(0,1fr);align-content:start;gap:18px;display:grid}.center-inner{max-width:760px;margin:0 auto}.panel-tabs{gap:4px;display:flex}.panel-tab{border-radius:var(--radius);min-height:32px;color:var(--text-2);font:inherit;cursor:pointer;background:0 0;border:none;align-items:center;gap:6px;padding:0 12px;display:inline-flex}.panel-tab[aria-selected=true]{background:var(--selected);color:var(--text);font-weight:600}@media (hover:hover){.panel-tab[aria-selected=false]:hover{background:var(--hover)}}.center-section{grid-template-columns:minmax(0,1fr);gap:10px;display:grid}.center-section h2{color:var(--text-3);font-size:var(--fs-s);font-weight:600}.decision-card{border-color:var(--border);grid-template-columns:minmax(0,1fr);gap:10px;padding:14px 16px 16px;display:grid}.decision-card h3{font-size:var(--fs-m);font-weight:600}.decision-context{max-height:240px;color:var(--text-2);overflow-y:auto}.decision-options{border:none;gap:6px;min-width:0;margin:0;padding:0;display:grid}.decision-option{border:1px solid var(--control);border-radius:var(--radius);cursor:pointer;align-items:flex-start;gap:10px;padding:9px 12px;display:flex}.decision-option[data-checked=true]{border-color:var(--accent);background:var(--surface-2)}.decision-option:has(input:focus-visible){outline:2px solid var(--accent);outline-offset:2px}.decision-radio{border:1.5px solid var(--control-strong);border-radius:50%;flex:none;width:14px;height:14px;margin-top:3px}.decision-option[data-checked=true] .decision-radio{border-color:var(--accent);background:var(--accent);box-shadow:inset 0 0 0 2.5px var(--surface-2)}.decision-check{border:1.5px solid var(--control-strong);border-radius:3px;flex:none;width:14px;height:14px;margin-top:3px}.decision-option[data-checked=true] .decision-check{border-color:var(--accent);background:var(--accent);box-shadow:inset 0 0 0 2.5px var(--surface-2)}.question-block{border:none;grid-template-columns:minmax(0,1fr);gap:6px;min-width:0;margin:0;padding:0;display:grid}.question-block .request-title{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.question-block .request-title .hint{font-weight:400}.question-other{cursor:text}.question-other>label{cursor:pointer;display:flex}.question-other-input{min-width:0;min-height:20px;color:inherit;font:inherit;resize:none;field-sizing:content;background:0 0;border:none;flex:1;padding:0}.question-other-input:focus-visible{outline:none}.question-other:focus-within{border-color:var(--control-strong)}.decision-option-text{gap:2px;min-width:0;display:grid}.decision-option-label{flex-wrap:wrap;align-items:center;gap:6px;font-weight:500;display:flex}.letter-card{border:1px solid var(--border);border-radius:var(--radius-l);background:var(--surface);grid-template-columns:minmax(0,1fr);gap:6px;padding:10px 14px 12px;display:grid}.letter-head{color:var(--text-2);font-size:var(--fs-s);flex-wrap:wrap;align-items:center;gap:8px;display:flex}.letter-card .letter-head svg{color:var(--text-3);flex:none}.letter-summary{overflow-wrap:anywhere;margin:0;font-weight:500}.letter-body,.letter-note{color:var(--text-2);overflow-wrap:anywhere;white-space:pre-wrap;margin:0}.letter-body .markdown{white-space:normal}.letter-list{margin:0;padding:0;list-style:none;display:grid}.letter-row{border-bottom:1px solid var(--divider);grid-template-columns:minmax(0,1fr);gap:4px;padding:12px 0;display:grid}.letter-row-head{font-size:var(--fs-s);color:var(--text-2);flex-wrap:wrap;align-items:center;gap:6px 8px;display:flex}.letter-route{color:var(--text);font-weight:500}.letter-lines,.decision-lines{gap:4px 8px}.letter-lines{grid-template-columns:fit-content(16em) max-content minmax(0,1fr) max-content max-content}.decision-lines{grid-template-columns:max-content minmax(0,1fr) fit-content(12em) max-content max-content}.record-options{gap:2px;margin:0;padding:0;list-style:none;display:grid}.record-options li{align-items:baseline;gap:6px;display:flex}.record-options li[data-chosen=true]{color:var(--text);font-weight:500}.record-check{flex:none;width:1em}.letter-item{grid-column:1/-1;grid-template-columns:subgrid;border-radius:var(--radius);display:grid}.letter-item[data-open=true]{background:var(--surface)}.letter-line{grid-column:1/-1;grid-template-columns:subgrid;border-radius:var(--radius);width:100%;min-height:36px;color:var(--text-2);font:inherit;text-align:left;cursor:pointer;background:0 0;border:0;align-items:center;padding:6px 10px;display:grid}.letter-line>.tag{text-overflow:ellipsis;white-space:nowrap;justify-self:start;max-width:100%;overflow:hidden}.letter-line-route{text-overflow:ellipsis;white-space:nowrap;color:var(--text);overflow:hidden}.letter-line-summary{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.letter-line-meta{font-size:var(--fs-s);white-space:nowrap;justify-self:end;align-items:center;gap:8px;display:flex}.letter-line[aria-expanded=true]{color:var(--text)}.letter-item[data-open=true] .letter-line-summary{visibility:hidden}.letter-item>.letter-line[aria-expanded=true]>.chevron{transform:rotate(90deg)}@media (hover:hover){.letter-item[data-open=false]>.letter-line:hover{background:var(--hover);color:var(--text)}}.letter-panel{grid-column:1/-1;grid-template-columns:minmax(0,1fr);gap:10px;padding:2px 14px 12px;display:grid}.letter-content{color:var(--text-2);overflow-wrap:anywhere;grid-template-columns:minmax(0,1fr);gap:6px;display:grid}.letter-panel p{margin:0}@media (width<=640px){.letter-lines,.decision-lines,.letter-item{grid-template-columns:minmax(0,1fr)}.letter-line{grid-template-columns:minmax(0,1fr) auto auto auto;grid-template-areas:"route tag meta chevron""summary summary summary summary";gap:2px 8px}.letter-line-route{grid-area:route}.letter-line>.tag{grid-area:tag}.letter-line-meta{grid-area:meta}.letter-line>.chevron{grid-area:chevron}.letter-line-summary{grid-area:summary}}.letter-status{color:var(--text-3)}.letter-status-held{color:var(--warning)}.letter-status-refused,.letter-status-dropped{color:var(--danger)}.field-heading{font-size:var(--fs-m);margin-top:6px;font-weight:600}.letter-card p,.decision-card p{margin:0}.thinking-body,.msg-user,.letter-body,.letter-content,.note-summary,.markdown pre{max-height:var(--cap);overscroll-behavior:contain;overflow-y:auto}.step-list{max-height:var(--cap-tall);overscroll-behavior:contain;overflow-y:auto}[data-more=true]{-webkit-mask-image:linear-gradient(#000 calc(100% - 32px),#0000);mask-image:linear-gradient(#000 calc(100% - 32px),#0000)}.session-item[data-drop=true]>.session-row{background:var(--selected);box-shadow:inset 0 0 0 1px var(--control-strong)}.relay-url{font-family:var(--mono);font-size:var(--fs-s);color:var(--text-2);overflow-wrap:anywhere}.setting-empty{padding:10px 14px}.pairing{text-align:center;justify-items:center;gap:10px;margin-top:16px;display:grid}.pairing-qr{border-radius:var(--radius-l);background:#fff;width:220px;height:220px;padding:12px}.dialog-tabs{padding:0 22px 8px}.mono-input{font-family:var(--mono);font-size:var(--fs-s)}.mcp-server+.mcp-server{border-top:1px solid var(--border)}.mcp-row,.mcp-row .setting-control{flex-wrap:wrap}.mcp-code{font-family:var(--mono);font-size:var(--fs-s);overflow-wrap:anywhere}.mcp-detail{gap:10px;padding:0 14px 12px;display:grid}.mcp-line{font-size:var(--fs-s);grid-template-columns:7em minmax(0,1fr);align-items:baseline;gap:8px;display:grid}.mcp-line>span:first-child{color:var(--text-2)}.mcp-values{gap:6px;display:grid}.mcp-value{flex-wrap:wrap;align-items:center;gap:8px;display:flex}.mcp-value .input{flex:12em;width:auto}.mcp-tools{flex-wrap:wrap;gap:4px 14px;margin:0;padding:0;list-style:none;display:flex}.skill+.skill{border-top:1px solid var(--border)}.skill-row{flex-wrap:wrap}.skill-row .setting-text{flex:14em}.skill-row .setting-control{margin-left:auto}.skill-name{overflow-wrap:anywhere;gap:8px}.skill-mark{border:1px solid var(--control-strong);border-radius:var(--radius-s);color:var(--warning);font-size:var(--fs-s);flex:none;padding:0 6px;font-weight:400}.skill-description{text-align:left;cursor:pointer;text-overflow:ellipsis;white-space:nowrap;background:0 0;border:0;min-width:0;padding:0;font-family:inherit;display:block;overflow:hidden}.skill-description.open{white-space:normal;overflow-wrap:anywhere}.skill>.error-box{margin:0 14px 12px}.data-row{flex-wrap:wrap}.data-row .setting-text{flex:16em}.data-row .setting-control{margin-left:auto}@media (width<=480px){.data-row .setting-text{flex:none}.data-row .setting-control{margin-left:0}}.data-path{font-family:var(--mono);overflow-wrap:anywhere;-webkit-user-select:all;user-select:all}.data-usage{justify-content:stretch;align-items:start;gap:12px;padding-block:14px;display:grid}.data-line{justify-content:space-between;align-items:baseline;gap:16px;display:flex}.data-total{font-weight:500}.data-size{font-variant-numeric:tabular-nums;flex:none}.data-part .data-size{color:var(--text-2)}.data-parts{gap:10px;margin:0;padding:0;list-style:none;display:grid}.data-part{gap:5px;display:grid}.data-bar{background:var(--hover);border-radius:2px;height:4px;overflow:hidden}.data-bar>span{background:var(--text-2);border-radius:2px;height:100%;display:block}.data-typed{gap:6px}.data-result{overflow-wrap:anywhere}.setting-box>.error-box{margin:0 14px 12px}.pairs{justify-items:start;gap:8px;display:grid}.pair-row{grid-template-columns:minmax(0,2fr) minmax(0,3fr) auto;gap:8px;width:100%;display:grid}@media (width<=480px){.mcp-line{grid-template-columns:minmax(0,1fr);gap:2px}}.schedule-list{gap:10px;margin:0;padding:0;list-style:none;display:grid}.schedule-card{grid-template-columns:minmax(0,1fr);gap:6px;padding:14px 16px;display:grid}.schedule-card p{margin:0}.schedule-head{justify-content:space-between;align-items:center;gap:12px;display:flex}.schedule-head h3{overflow-wrap:anywhere;min-width:0;font-size:var(--fs-m);font-weight:600}.schedule-line{color:var(--text-2);font-size:var(--fs-s);flex-wrap:wrap;gap:4px 12px;display:flex}.schedule-cron{font-family:var(--mono)}.schedule-message{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.schedule-actions{flex-wrap:wrap;gap:6px;margin-top:4px;display:flex}.artifacts{gap:16px;display:grid}.artifact-list{gap:2px;margin:0;padding:0;list-style:none;display:grid}.artifact-row,.artifact-chip{border-radius:var(--radius-s);width:100%;min-height:44px;color:var(--text);font:inherit;text-align:left;cursor:pointer;background:0 0;border:1px solid #0000;gap:2px;padding:8px 12px;display:grid}.artifact-row:hover,.artifact-chip:hover{background:var(--hover)}.artifact-row[aria-current=true]{background:var(--selected)}.artifact-chip{border-color:var(--border);background:var(--surface);width:auto;max-width:100%;margin:4px 0}.artifact-name{text-overflow:ellipsis;white-space:nowrap;font-weight:600;overflow:hidden}.artifact-meta{color:var(--text-2);font-size:var(--fs-s)}.artifact-viewer{border:1px solid var(--border);border-radius:var(--radius-m,10px);background:var(--surface);gap:12px;min-width:0;padding:16px;display:grid}.artifact-head{flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px 16px;display:flex}.artifact-title{gap:2px;min-width:0;display:grid}.artifact-title h2{overflow-wrap:anywhere;font-size:var(--fs-l,1.125rem);margin:0}.artifact-actions{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.artifact-actions a.btn{border-color:var(--control);text-decoration:none}.artifact-frame{border:1px solid var(--border);border-radius:var(--radius-s);background:#fff;width:100%;height:min(70vh,720px)}.artifact-text{overflow-wrap:anywhere;min-width:0}.artifact-json{border-radius:var(--radius-s);background:var(--surface-2);max-height:70vh;font-family:var(--mono);font-size:var(--fs-s);white-space:pre-wrap;overflow-wrap:anywhere;margin:0;padding:12px;overflow:auto}.chart{gap:8px;margin:0;display:grid}.chart figcaption{font-weight:600}.chart-svg{width:100%;height:auto}.chart-grid{stroke:var(--divider);stroke-width:1px}.chart-tick{fill:var(--text-2);font-size:11px}.chart-bar{fill:var(--text)}.chart-line{fill:none;stroke:var(--text);stroke-width:2px;stroke-linejoin:round}.chart-legend{color:var(--text-2);font-size:var(--fs-s);flex-wrap:wrap;gap:4px 16px;margin:0;padding:0;list-style:none;display:flex}.chart-legend li{align-items:center;gap:6px;display:inline-flex}.chart-swatch{background:var(--text);border-radius:2px;width:12px;height:12px}.chart-table summary{color:var(--text-2);font-size:var(--fs-s);cursor:pointer}.chart-table table{border-collapse:collapse;font-size:var(--fs-s);font-variant-numeric:tabular-nums;margin-top:8px}.chart-table th,.chart-table td{border-bottom:1px solid var(--divider);text-align:right;padding:4px 10px}.chart-table tbody th{text-align:left;font-weight:400}.usage-today{gap:6px;display:grid}.usage-today p{margin:0}.usage-figure{flex-wrap:wrap;align-items:baseline;gap:4px 10px;display:flex}.usage-figure strong{font-size:var(--fs-xl);font-variant-numeric:tabular-nums;font-weight:600}.usage-meter{background:var(--selected);border-radius:2px;height:4px;overflow:hidden}.usage-meter span{background:var(--text);border-radius:2px;height:100%;display:block}.usage-section{grid-template-columns:minmax(0,1fr);gap:8px;display:grid}.usage-section>p{margin:0}.usage-chart{min-width:0;position:relative}.usage-svg{pointer-events:none;display:block;position:absolute;inset:0}.usage-hits{display:flex;position:absolute}.usage-hit{cursor:pointer;background:0 0;border:none;border-radius:3px;flex:1 1 0;min-width:0;padding:0}.usage-hit:focus-visible{outline-offset:0}@media (hover:hover){.usage-hit:hover{background:var(--hover)}}.usage-bar{fill:var(--text);opacity:.35}.usage-bar-on{fill:var(--text);opacity:1}.usage-base{stroke:var(--control-strong);stroke-width:1px}.usage-limit{stroke:var(--text-2);stroke-width:1px;stroke-dasharray:4 3}.usage-day{font-size:var(--fs-m);margin:0;font-weight:600}.usage-note{font-weight:400}.usage-table-wrap{overflow-x:auto}.usage-table{border-collapse:collapse;width:100%;font-size:var(--fs-s);font-variant-numeric:tabular-nums}.usage-table tr th,.usage-table tr td{border-bottom:1px solid var(--divider);text-align:right;white-space:nowrap;padding:7px 0 7px 14px}.usage-table tr th:first-child{text-align:left;white-space:normal;overflow-wrap:anywhere;padding-left:0}.usage-name{text-align:left}.usage-table thead th{color:var(--text-2);font-weight:400}.usage-table tbody th{min-width:120px;font-weight:400}.usage-table tfoot th,.usage-table tfoot td{border-bottom:none;font-weight:600}.usage-limit-label{paint-order:stroke;stroke:var(--bg);stroke-width:4px;stroke-linejoin:round}.map-page{grid-template-columns:minmax(0,1fr);align-content:start;gap:12px;display:grid}.map-caption{gap:6px;max-width:760px;display:grid}.map-caption p{margin:0}.map-legend{flex-wrap:wrap;gap:4px 14px;margin:0;padding:0;list-style:none;display:flex}.map-legend li{align-items:center;display:inline-flex}.map-legend .row-dot{margin-left:0}.map-scroll{overscroll-behavior:contain;border:1px solid var(--border);border-radius:var(--radius);max-height:max(240px,100dvh - 230px);overflow:auto}.map-canvas{position:relative}.map-lines{pointer-events:none;display:block;position:absolute;inset:0}.map-opened{fill:none;stroke:var(--control-strong);stroke-width:1.5px}.map-flow{fill:none;stroke:var(--text-2);stroke-width:1px}.map-arrow{fill:var(--text-2)}.map-flow-count{fill:var(--text);paint-order:stroke;stroke:var(--bg);stroke-width:4px;stroke-linejoin:round;font-weight:600}.map-faded{opacity:.12}.map-head{color:var(--text-2);font-size:var(--fs-s);text-overflow:ellipsis;white-space:nowrap;line-height:20px;position:absolute;overflow:hidden}.map-node{border:1px solid var(--control);border-radius:var(--radius);background:var(--surface);color:var(--text);text-align:left;cursor:pointer;grid-template-columns:16px minmax(0,1fr) auto;align-items:center;gap:8px;padding:0 10px;display:grid;position:absolute}.map-node[data-main]{border-color:var(--control-strong);font-weight:600}.map-node .row-dot{margin:0 2px}.map-node-name{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}@media (hover:hover){.map-node:hover{background:var(--hover)}}.map-outline{max-width:760px}.map-outline summary{width:max-content;color:var(--text-2);font-size:var(--fs-s);cursor:pointer}.map-outline h2{font-size:var(--fs-m);margin:12px 0 4px;font-weight:600}.map-list{margin:0;padding-left:18px}.map-list li{margin:2px 0}.map-list .link-button{text-align:left}.session-title-stack{flex-direction:column;align-items:flex-start;gap:0}.session-title-stack h1{max-width:100%}.progress-line{max-width:100%;color:var(--text-2);font-size:var(--fs-s);font-variant-numeric:tabular-nums;align-items:center;gap:8px;line-height:16px;display:flex}.progress-text{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}.progress-line .row-dot{flex:none;margin:0 -1px 0 1px}.progress-time{color:var(--text-3);flex:none}.preset-steps{gap:6px;margin:0;padding-left:20px;display:grid}.preset-redirect{overflow-wrap:anywhere;margin-top:4px;display:block}