collabmd 0.1.31 → 0.1.32

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 (93) hide show
  1. package/dist/client/assets/{drawio-editor-B4sHHwWJ.js → drawio-editor-Br4qyh3r.js} +1 -1
  2. package/dist/client/assets/drawioEditor-ClmnTx5J.js +2 -0
  3. package/dist/client/assets/{editor-session-BKHEYkbY.js → editor-session-Cf-iV5-3.js} +2 -2
  4. package/dist/client/assets/embedded-editor-base-CgEkjNYn.css +1 -0
  5. package/dist/client/assets/{excalidraw-editor-CHbeNZu6.js → excalidraw-editor-CXAxVhlw.js} +2 -2
  6. package/dist/client/assets/{excalidrawEditor-BhaTX2Ko.js → excalidrawEditor-DoH_kMdu.js} +2 -2
  7. package/dist/client/assets/exportDocument-9wTrBZNS.css +1 -0
  8. package/dist/client/assets/{index-kPgEYvEX.js → index-C8QZYHvV.js} +2 -2
  9. package/dist/client/assets/index-CxSbUTs2.css +1 -0
  10. package/dist/client/assets/inter-cyrillic-ext-wght-normal-BOeWTOD4.woff2 +0 -0
  11. package/dist/client/assets/inter-cyrillic-wght-normal-DqGufNeO.woff2 +0 -0
  12. package/dist/client/assets/inter-greek-ext-wght-normal-DlzME5K_.woff2 +0 -0
  13. package/dist/client/assets/inter-greek-wght-normal-CkhJZR-_.woff2 +0 -0
  14. package/dist/client/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2 +0 -0
  15. package/dist/client/assets/inter-latin-wght-normal-Dx4kXJAl.woff2 +0 -0
  16. package/dist/client/assets/inter-vietnamese-wght-normal-CBcvBZtf.woff2 +0 -0
  17. package/dist/client/assets/jetbrains-mono-cyrillic-400-normal-BEIGL1Tu.woff2 +0 -0
  18. package/dist/client/assets/jetbrains-mono-cyrillic-400-normal-ugxPyKxw.woff +0 -0
  19. package/dist/client/assets/jetbrains-mono-greek-400-normal-B9oWc5Lo.woff +0 -0
  20. package/dist/client/assets/jetbrains-mono-greek-400-normal-C190GLew.woff2 +0 -0
  21. package/dist/client/assets/jetbrains-mono-latin-400-normal-6-qcROiO.woff +0 -0
  22. package/dist/client/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
  23. package/dist/client/assets/jetbrains-mono-latin-ext-400-normal-Bc8Ftmh3.woff2 +0 -0
  24. package/dist/client/assets/jetbrains-mono-latin-ext-400-normal-fXTG6kC5.woff +0 -0
  25. package/dist/client/assets/jetbrains-mono-vietnamese-400-normal-CqNFfHCs.woff +0 -0
  26. package/dist/client/assets/main-BjHHMlv0.js +1249 -0
  27. package/dist/client/assets/vault-api-client-Bf9tB_GW.js +1 -0
  28. package/dist/client/assets/vault-api-client-D7Ck0CvR.css +1 -0
  29. package/dist/client/drawio-editor.html +1 -1
  30. package/dist/client/excalidraw-editor.html +1 -1
  31. package/dist/client/export-document.html +2 -2
  32. package/dist/client/index.html +2 -2
  33. package/package.json +4 -1
  34. package/src/client/app/main-entry.js +2 -0
  35. package/src/client/application/app-shell/git-feature.js +28 -36
  36. package/src/client/application/app-shell/presence-feature.js +3 -1
  37. package/src/client/application/diagram-preview-hydrator.js +24 -15
  38. package/src/client/application/mermaid-preview-hydrator.js +121 -4
  39. package/src/client/application/plantuml-preview-hydrator.js +6 -16
  40. package/src/client/application/preview-renderer.js +11 -2
  41. package/src/client/bootstrap/collabmd-app-shell.js +176 -50
  42. package/src/client/domain/excalidraw-document-switch.js +3 -0
  43. package/src/client/excalidraw-editor.js +187 -84
  44. package/src/client/infrastructure/auth-client.js +4 -4
  45. package/src/client/infrastructure/backlinks-api-client.js +18 -0
  46. package/src/client/infrastructure/comment-thread-store.js +4 -0
  47. package/src/client/infrastructure/editor-session.js +2 -0
  48. package/src/client/infrastructure/git-api-client.js +134 -0
  49. package/src/client/infrastructure/plantuml-api-client.js +21 -0
  50. package/src/client/infrastructure/vault-api-client.js +67 -0
  51. package/src/client/presentation/backlinks-panel.js +6 -9
  52. package/src/client/presentation/bases-preview-controller.js +26 -7
  53. package/src/client/presentation/excalidraw-embed-controller.js +251 -15
  54. package/src/client/presentation/excalidraw-embed-reconciler.js +0 -1
  55. package/src/client/presentation/file-action-controller.js +97 -0
  56. package/src/client/presentation/file-explorer-controller.js +2 -0
  57. package/src/client/presentation/file-explorer-view.js +368 -0
  58. package/src/client/presentation/file-history-view-controller.js +41 -40
  59. package/src/client/presentation/git-diff-view-controller.js +70 -53
  60. package/src/client/presentation/git-panel-controller.js +12 -30
  61. package/src/client/styles/export-document.css +45 -2
  62. package/src/client/styles/features/auth-gate.css +13 -24
  63. package/src/client/styles/features/comment-card.css +6 -0
  64. package/src/client/styles/features/comments-drawer.css +38 -18
  65. package/src/client/styles/features/diagram-preview.css +33 -0
  66. package/src/client/styles/features/embedded-preview.css +37 -11
  67. package/src/client/styles/features/preview-markdown.css +103 -28
  68. package/src/client/styles/foundation/themes.css +4 -0
  69. package/src/client/styles/foundation/tokens.css +4 -3
  70. package/src/client/styles/layout/sidebar.css +72 -0
  71. package/src/server/auth/auth-common.js +224 -0
  72. package/src/server/auth/auth-constants.js +30 -0
  73. package/src/server/auth/auth-strategies.js +320 -0
  74. package/src/server/auth/create-auth-service.js +24 -545
  75. package/src/server/domain/bases/base-definition.js +255 -0
  76. package/src/server/domain/bases/base-expression-runtime.js +1159 -0
  77. package/src/server/domain/bases/base-index-snapshot-store.js +418 -0
  78. package/src/server/domain/bases/base-query-results.js +205 -0
  79. package/src/server/domain/bases/base-query-service.js +68 -1965
  80. package/src/server/domain/collaboration/collaboration-room.js +36 -1
  81. package/src/server/domain/collaboration/room-client-state-store.js +1 -0
  82. package/src/server/domain/collaboration/room-persistence-controller.js +1 -1
  83. package/src/server/infrastructure/http/create-vault-api-query-handler.js +109 -1
  84. package/src/server/infrastructure/http/http-response.js +56 -0
  85. package/src/server/infrastructure/persistence/vault-file-store.js +110 -0
  86. package/dist/client/assets/drawioEditor-DGpo2hcx.js +0 -2
  87. package/dist/client/assets/embedded-editor-base-DgmRcsR8.css +0 -1
  88. package/dist/client/assets/exportDocument-DmV7Gngb.css +0 -1
  89. package/dist/client/assets/index-D69HOZHr.css +0 -1
  90. package/dist/client/assets/main-DSxNTtD-.js +0 -1243
  91. package/dist/client/assets/vault-api-client-BzHQseMN.js +0 -1
  92. package/dist/client/assets/vault-api-client-De7kMvrE.css +0 -1
  93. /package/dist/client/assets/{exportDocument-CtZKWE2c.js → exportDocument-Bia2hI25.js} +0 -0
@@ -45,10 +45,39 @@ function closeSlowClient(ws, clientState, { maxBufferedAmountBytes, name }) {
45
45
  return false;
46
46
  }
47
47
 
48
+ function isExpectedSocketSendError(error) {
49
+ const code = String(error?.code || '').toUpperCase();
50
+ const message = String(error?.message || '');
51
+
52
+ return code === 'EPIPE'
53
+ || code === 'ECONNRESET'
54
+ || /EPIPE|ECONNRESET|WebSocket is not open|readyState/i.test(message);
55
+ }
56
+
57
+ function cleanupDisconnectedClient(room, ws, clientState) {
58
+ if (clientState?.transportCloseIssued) {
59
+ return false;
60
+ }
61
+
62
+ if (clientState) {
63
+ clientState.transportCloseIssued = true;
64
+ }
65
+
66
+ room?.removeClient?.(ws);
67
+
68
+ try {
69
+ ws.terminate?.();
70
+ } catch {
71
+ // Ignore termination errors while cleaning up disconnected clients.
72
+ }
73
+
74
+ return false;
75
+ }
76
+
48
77
  function sendMessage(ws, payload, { maxBufferedAmountBytes, name }) {
49
78
  const clientState = this?.getClientState?.(ws) ?? null;
50
79
  if (ws.readyState !== ws.OPEN) {
51
- return false;
80
+ return cleanupDisconnectedClient(this, ws, clientState);
52
81
  }
53
82
 
54
83
  const bufferedAmountBeforeSend = ws.bufferedAmount;
@@ -59,6 +88,11 @@ function sendMessage(ws, payload, { maxBufferedAmountBytes, name }) {
59
88
 
60
89
  ws.send(payload, (error) => {
61
90
  if (error) {
91
+ if (isExpectedSocketSendError(error)) {
92
+ cleanupDisconnectedClient(this, ws, clientState);
93
+ return;
94
+ }
95
+
62
96
  console.error(`[room:${name}] Failed to send websocket frame:`, error.message);
63
97
  }
64
98
  });
@@ -343,6 +377,7 @@ export class CollaborationRoom {
343
377
  const existingState = this.getClientState(ws);
344
378
  if (existingState) {
345
379
  existingState.backpressureCloseIssued = false;
380
+ existingState.transportCloseIssued = false;
346
381
  return existingState;
347
382
  }
348
383
 
@@ -2,6 +2,7 @@ function createClientState() {
2
2
  return {
3
3
  backpressureCloseIssued: false,
4
4
  controlledClientIds: new Set(),
5
+ transportCloseIssued: false,
5
6
  };
6
7
  }
7
8
 
@@ -46,10 +46,10 @@ export class RoomPersistenceController {
46
46
  return;
47
47
  }
48
48
 
49
- const generation = ++this.shutdownGeneration;
50
49
  if (this.finalizePromise) {
51
50
  return;
52
51
  }
52
+ const generation = ++this.shutdownGeneration;
53
53
 
54
54
  this.finalizePromise = (async () => {
55
55
  clearTimeout(this.persistTimer);
@@ -1,3 +1,4 @@
1
+ import archiver from 'archiver';
1
2
  import { basename } from 'node:path';
2
3
 
3
4
  import {
@@ -9,7 +10,7 @@ import {
9
10
  isPlantUmlFilePath,
10
11
  } from '../../../domain/file-kind.js';
11
12
  import { parseJsonBody } from './request-body.js';
12
- import { jsonResponse, sendResponse } from './http-response.js';
13
+ import { jsonResponse, sendResponse, sendStreamResponse } from './http-response.js';
13
14
 
14
15
  const SVG_MIME_TYPE = 'image/svg+xml';
15
16
  const SVG_ATTACHMENT_CSP = "default-src 'none'; img-src 'self' data: blob:; style-src 'unsafe-inline'; sandbox";
@@ -43,6 +44,15 @@ function createAttachmentHeaders(attachment) {
43
44
  return headers;
44
45
  }
45
46
 
47
+ function createDownloadHeaders(fileName, contentType) {
48
+ return {
49
+ 'Cache-Control': 'no-store',
50
+ 'Content-Disposition': `attachment; filename="${createSafeAsciiFilename(fileName)}"; filename*=UTF-8''${encodeContentDispositionFilename(fileName)}`,
51
+ 'Content-Type': contentType,
52
+ 'X-Content-Type-Options': 'nosniff',
53
+ };
54
+ }
55
+
46
56
  function selectReadOperation(vaultFileStore, filePath) {
47
57
  if (isExcalidrawFilePath(filePath)) {
48
58
  return vaultFileStore.readExcalidrawFile(filePath);
@@ -67,6 +77,46 @@ function selectReadOperation(vaultFileStore, filePath) {
67
77
  return vaultFileStore.readMarkdownFile(filePath);
68
78
  }
69
79
 
80
+ async function streamDirectoryArchive(req, res, {
81
+ entries = [],
82
+ rootName = 'archive',
83
+ } = {}) {
84
+ const archive = archiver('zip', {
85
+ zlib: {
86
+ level: 6,
87
+ },
88
+ });
89
+
90
+ archive.on('warning', (error) => {
91
+ if (error?.code !== 'ENOENT') {
92
+ archive.emit('error', error);
93
+ }
94
+ });
95
+
96
+ const responsePromise = sendStreamResponse(req, res, {
97
+ headers: createDownloadHeaders(`${rootName}.zip`, 'application/zip'),
98
+ statusCode: 200,
99
+ stream: archive,
100
+ });
101
+
102
+ for (const entry of entries) {
103
+ if (entry.type === 'directory') {
104
+ const directoryName = entry.path
105
+ ? `${rootName}/${entry.path}/`
106
+ : `${rootName}/`;
107
+ archive.append('', { name: directoryName });
108
+ continue;
109
+ }
110
+
111
+ archive.file(entry.absolutePath, {
112
+ name: `${rootName}/${entry.path}`,
113
+ });
114
+ }
115
+
116
+ await archive.finalize();
117
+ await responsePromise;
118
+ }
119
+
70
120
  export function createVaultApiQueryHandler({
71
121
  baseQueryService = null,
72
122
  backlinkIndex,
@@ -166,6 +216,64 @@ export function createVaultApiQueryHandler({
166
216
  return true;
167
217
  }
168
218
 
219
+ if (requestUrl.pathname === '/api/download/file' && req.method === 'GET') {
220
+ const filePath = requestUrl.searchParams.get('path');
221
+ if (!filePath) {
222
+ jsonResponse(req, res, 400, { error: 'Missing path parameter' });
223
+ return true;
224
+ }
225
+
226
+ try {
227
+ const download = await vaultFileStore.readDownloadFile(filePath);
228
+ if (!download) {
229
+ jsonResponse(req, res, 404, { error: 'File not found' });
230
+ return true;
231
+ }
232
+
233
+ sendResponse(req, res, {
234
+ body: download.content,
235
+ headers: createDownloadHeaders(
236
+ basename(String(download.path ?? 'download')),
237
+ download.mimeType || 'application/octet-stream',
238
+ ),
239
+ statusCode: 200,
240
+ });
241
+ } catch (error) {
242
+ console.error('[api] Failed to download file:', error.message);
243
+ jsonResponse(req, res, 500, { error: 'Failed to download file' });
244
+ }
245
+ return true;
246
+ }
247
+
248
+ if (requestUrl.pathname === '/api/download/directory' && req.method === 'GET') {
249
+ const directoryPath = requestUrl.searchParams.get('path');
250
+ if (!directoryPath) {
251
+ jsonResponse(req, res, 400, { error: 'Missing path parameter' });
252
+ return true;
253
+ }
254
+
255
+ try {
256
+ const result = await vaultFileStore.listDirectoryEntriesForDownload(directoryPath);
257
+ if (!result.ok) {
258
+ jsonResponse(req, res, result.error === 'Directory not found' ? 404 : 400, { error: result.error });
259
+ return true;
260
+ }
261
+
262
+ await streamDirectoryArchive(req, res, {
263
+ entries: result.entries,
264
+ rootName: result.rootName || 'archive',
265
+ });
266
+ } catch (error) {
267
+ console.error('[api] Failed to download directory:', error.message);
268
+ if (!res.headersSent) {
269
+ jsonResponse(req, res, 500, { error: 'Failed to download directory' });
270
+ } else {
271
+ res.destroy(error);
272
+ }
273
+ }
274
+ return true;
275
+ }
276
+
169
277
  if (requestUrl.pathname === '/api/attachment' && req.method === 'GET') {
170
278
  const filePath = requestUrl.searchParams.get('path');
171
279
  if (!filePath) {
@@ -179,6 +179,62 @@ export function sendResponse(req, res, {
179
179
  });
180
180
  }
181
181
 
182
+ export function sendStreamResponse(req, res, {
183
+ headers = {},
184
+ statusCode = 200,
185
+ stream,
186
+ } = {}) {
187
+ writeResponseHead(res, statusCode, headers, null);
188
+
189
+ if (!stream) {
190
+ res.end();
191
+ return Promise.resolve();
192
+ }
193
+
194
+ if (req.method === 'HEAD' || statusCode === 204 || statusCode === 304) {
195
+ stream.destroy?.();
196
+ res.end();
197
+ return Promise.resolve();
198
+ }
199
+
200
+ return new Promise((resolve, reject) => {
201
+ let settled = false;
202
+
203
+ const finish = (error = null) => {
204
+ if (settled) {
205
+ return;
206
+ }
207
+
208
+ settled = true;
209
+ res.off('finish', handleFinish);
210
+ res.off('error', handleError);
211
+ res.off('close', handleClose);
212
+ stream.off('error', handleError);
213
+
214
+ if (error) {
215
+ reject(error);
216
+ return;
217
+ }
218
+
219
+ resolve();
220
+ };
221
+
222
+ const handleFinish = () => finish();
223
+ const handleError = (error) => finish(error);
224
+ const handleClose = () => {
225
+ if (!res.writableEnded) {
226
+ finish(new Error('Response stream closed before completion'));
227
+ }
228
+ };
229
+
230
+ res.on('finish', handleFinish);
231
+ res.on('error', handleError);
232
+ res.on('close', handleClose);
233
+ stream.on('error', handleError);
234
+ stream.pipe(res);
235
+ });
236
+ }
237
+
182
238
  export function jsonResponse(req, res, statusCode, data) {
183
239
  const body = JSON.stringify(data);
184
240
  sendResponse(req, res, {
@@ -2,6 +2,7 @@ import { mkdir, readFile, readdir, rename, rm, rmdir, stat, writeFile } from 'fs
2
2
  import { basename, dirname, extname, join, relative, resolve } from 'path';
3
3
 
4
4
  import {
5
+ getVaultFileKind,
5
6
  getVaultTreeNodeType,
6
7
  isImageAttachmentFilePath,
7
8
  isMarkdownFilePath,
@@ -37,6 +38,14 @@ const MIME_TYPE_TO_IMAGE_EXTENSION = Object.freeze({
37
38
  'image/svg+xml': '.svg',
38
39
  'image/webp': '.webp',
39
40
  });
41
+ const TEXT_FILE_MIME_TYPES = Object.freeze({
42
+ base: 'text/yaml; charset=utf-8',
43
+ drawio: 'application/xml; charset=utf-8',
44
+ excalidraw: 'application/json; charset=utf-8',
45
+ markdown: 'text/markdown; charset=utf-8',
46
+ mermaid: 'text/plain; charset=utf-8',
47
+ plantuml: 'text/plain; charset=utf-8',
48
+ });
40
49
  const WORKSPACE_SCAN_CONCURRENCY = 8;
41
50
 
42
51
  function createTransactionalPath(targetPath, label) {
@@ -201,6 +210,15 @@ function createAttachmentMarkdownSnippet({ altText, documentPath, storedPath })
201
210
  return `![${escapeMarkdownText(altText)}](${encodedRelativePath})`;
202
211
  }
203
212
 
213
+ function getDownloadMimeType(filePath) {
214
+ const fileKind = getVaultFileKind(filePath);
215
+ if (fileKind === 'image') {
216
+ return IMAGE_EXTENSION_TO_MIME_TYPE[extname(String(filePath ?? '')).toLowerCase()] || 'application/octet-stream';
217
+ }
218
+
219
+ return TEXT_FILE_MIME_TYPES[fileKind] || 'application/octet-stream';
220
+ }
221
+
204
222
  export class VaultFileStore {
205
223
  constructor({ vaultDir }) {
206
224
  this.vaultDir = resolve(vaultDir);
@@ -463,6 +481,36 @@ export class VaultFileStore {
463
481
  };
464
482
  }
465
483
 
484
+ async readDownloadFile(filePath) {
485
+ const normalizedPath = String(filePath ?? '').replace(/\\/g, '/').trim();
486
+ if (!normalizedPath || !isVaultFilePath(normalizedPath)) {
487
+ return null;
488
+ }
489
+
490
+ if (isImageAttachmentFilePath(normalizedPath)) {
491
+ return this.readImageAttachmentFile(normalizedPath);
492
+ }
493
+
494
+ const absolute = this.resolveContentPath(normalizedPath, { requireVaultFile: false });
495
+ if (!absolute) {
496
+ return null;
497
+ }
498
+
499
+ try {
500
+ return {
501
+ content: await readFile(absolute),
502
+ mimeType: getDownloadMimeType(normalizedPath),
503
+ path: normalizedPath,
504
+ };
505
+ } catch (error) {
506
+ if (error.code === 'ENOENT') {
507
+ return null;
508
+ }
509
+
510
+ throw error;
511
+ }
512
+ }
513
+
466
514
  async persistCollaborationState(filePath, {
467
515
  commentThreads = [],
468
516
  content = '',
@@ -660,6 +708,68 @@ export class VaultFileStore {
660
708
  return sortWorkspacePaths(paths);
661
709
  }
662
710
 
711
+ async listDirectoryEntriesForDownload(dirPath) {
712
+ const normalizedPath = String(dirPath ?? '').replace(/\\/g, '/').trim();
713
+ const { absolute, error } = resolveVaultDirectoryPath(this.vaultDir, normalizedPath);
714
+ if (!absolute) {
715
+ return { ok: false, error };
716
+ }
717
+
718
+ try {
719
+ const info = await stat(absolute);
720
+ if (!info.isDirectory()) {
721
+ return { ok: false, error: 'Directory not found' };
722
+ }
723
+ } catch (statError) {
724
+ if (statError.code === 'ENOENT') {
725
+ return { ok: false, error: 'Directory not found' };
726
+ }
727
+
728
+ throw statError;
729
+ }
730
+
731
+ const entries = [];
732
+ const visitDirectory = async (directoryAbsolutePath, relativeDirectoryPath = '') => {
733
+ const dirEntries = sortDirectoryEntries(await readdir(directoryAbsolutePath, { withFileTypes: true }))
734
+ .filter((entry) => !isIgnoredVaultEntry(entry.name));
735
+
736
+ if (dirEntries.length === 0) {
737
+ entries.push({
738
+ path: relativeDirectoryPath,
739
+ type: 'directory',
740
+ });
741
+ return;
742
+ }
743
+
744
+ for (const entry of dirEntries) {
745
+ const childAbsolutePath = join(directoryAbsolutePath, entry.name);
746
+ const childRelativePath = relativeDirectoryPath
747
+ ? `${relativeDirectoryPath}/${entry.name}`
748
+ : entry.name;
749
+
750
+ if (entry.isDirectory()) {
751
+ await visitDirectory(childAbsolutePath, childRelativePath);
752
+ continue;
753
+ }
754
+
755
+ if (isVaultFilePath(entry.name)) {
756
+ entries.push({
757
+ absolutePath: childAbsolutePath,
758
+ path: childRelativePath,
759
+ type: 'file',
760
+ });
761
+ }
762
+ }
763
+ };
764
+
765
+ await visitDirectory(absolute);
766
+ return {
767
+ entries,
768
+ ok: true,
769
+ rootName: basename(normalizedPath),
770
+ };
771
+ }
772
+
663
773
  async deleteFile(filePath) {
664
774
  const { absolute, error } = resolveVaultFilePath(this.vaultDir, filePath);
665
775
  if (!absolute) {
@@ -1,2 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./drawio-editor-B4sHHwWJ.js","./yjs-provider-reset-guard-CtERLBID.js","./runtime-config-CqhchMC4.js","./vault-api-client-BzHQseMN.js","./vault-api-client-De7kMvrE.css","./drawio-room-DEivFyNV.js","./drawio-editor-UQQ8XHou.css","./embedded-editor-base-DgmRcsR8.css"])))=>i.map(i=>d[i]);
2
- import{t as e}from"./runtime-config-loader-_D2KZKn-.js";import{t}from"./preload-helper-Bo9GmnuQ.js";await e(),await t(()=>import(`./drawio-editor-B4sHHwWJ.js`),__vite__mapDeps([0,1,2,3,4,5,6,7]),import.meta.url);
@@ -1 +0,0 @@
1
- :root{--text-xs:clamp(.75rem, .7rem + .25vw, .875rem);--text-sm:clamp(.875rem, .8rem + .35vw, 1rem);--text-base:clamp(1rem, .9rem + .5vw, 1.125rem);--text-lg:clamp(1.125rem, .95rem + .85vw, 1.5rem);--text-xl:clamp(1.5rem, 1rem + 1.5vw, 2.25rem);--text-2xl:clamp(2rem, 1.2rem + 2.5vw, 3.5rem);--text-label:12px;--text-meta:11px;--text-caption:10px;--text-micro:9px;--text-code-sm:11.5px;--text-ui-sm:13px;--text-ui-md:14px;--text-title-sm:15px;--text-title-md:18px;--font-body:"Inter", system-ui, sans-serif;--font-display:"Geist", "Cal Sans", "Inter", system-ui, sans-serif;--font-mono:"JetBrains Mono", "Fira Code", monospace;--space-1:.25rem;--space-2:.5rem;--space-3:.75rem;--space-4:1rem;--space-5:1.25rem;--space-6:1.5rem;--space-8:2rem;--space-10:2.5rem;--space-12:3rem;--space-16:4rem;--space-20:5rem;--space-24:6rem;--space-32:8rem;--radius-sm:.375rem;--radius-md:.5rem;--radius-lg:.75rem;--radius-xl:1rem;--radius-2xs:2px;--radius-xs:4px;--radius-lg-plus:10px;--radius-xl-plus:18px;--radius-full:9999px;--transition-interactive:.18s cubic-bezier(.16, 1, .3, 1);--content-narrow:640px;--content-default:960px;--content-wide:1200px;--preview-content-width:720px;--panel-comments-width:min(300px, 34vw);--panel-comments-min-width:240px;--panel-outline-width:220px;--toolbar-h:48px;--control-h-xs:28px;--control-h-sm:30px;--control-h-md:36px;--control-h-lg:44px;--control-icon-sm:14px;--control-icon-md:16px;--panel-border-width:1px}:root,[data-theme=light]{--color-bg:#f5f5f7;--color-surface:#fff;--color-surface-2:#fafafe;--color-surface-offset:#eeeef2;--color-surface-offset-2:#e6e6eb;--color-surface-dynamic:#dddde3;--color-surface-raised:#fff;--color-surface-ink:#0f1117;--color-divider:#d1d1d8;--color-border:#c4c4ce;--color-text:#1a1a2e;--color-text-muted:#6b6b80;--color-text-faint:#a0a0b0;--color-text-inverse:#f5f5f7;--color-primary:#4f46e5;--color-primary-hover:#4338ca;--color-primary-active:#3730a3;--color-primary-highlight:#e0e0ff;--color-comment:#4f46e5;--color-comment-soft:#4f46e514;--color-comment-strong:#4f46e524;--color-comment-text:#3730a3;--color-error:#dc2626;--color-error-highlight:#fce8e8;--color-success:#16a34a;--color-success-highlight:#dcfce7;--color-warning:#d97706;--color-warning-highlight:#fef3c7;--diff-add-bg:#16a34a0f;--diff-add-line-bg:#16a34a24;--diff-add-text:#16a34a;--diff-del-bg:#dc26260f;--diff-del-line-bg:#dc262624;--diff-del-text:#dc2626;--diff-hunk-bg:#4f46e514;--diff-hunk-text:#4f46e5;--diff-gutter:#a0a0b0;--surface-fill-subtle:color-mix(in oklab, var(--color-surface) 92%, var(--color-surface-offset) 8%);--surface-fill-strong:color-mix(in oklab, var(--color-surface-offset) 72%, var(--color-surface-offset-2) 28%);--surface-overlay:color-mix(in srgb, var(--color-surface) 84%, var(--color-surface-offset) 16%);--surface-overlay-soft:color-mix(in srgb, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-overlay-strong:color-mix(in srgb, var(--color-surface) 90%, var(--color-surface-offset) 10%);--surface-overlay-raised:color-mix(in oklab, var(--color-surface) 94%, transparent);--surface-overlay-header:color-mix(in srgb, var(--color-surface-offset) 76%, var(--color-bg) 24%);--surface-overlay-offset:color-mix(in oklab, var(--color-surface-offset) 82%, transparent);--surface-scrim:oklch(10% 0 0/.42);--surface-scrim-strong:oklch(8% .01 260/.82);--surface-inverse-glass:oklch(18% .02 260/.68);--surface-inverse-glass-hover:oklch(24% .02 260/.82);--surface-media-canvas:#000;--surface-embed-canvas:#fff;--surface-avatar-muted:#ffffff38;--surface-avatar-label:#0f1117d6;--surface-accent-subtle:color-mix(in oklab, var(--color-primary) 8%, var(--color-surface));--surface-accent-soft:color-mix(in oklab, var(--color-primary) 16%, transparent);--surface-accent-strong:color-mix(in oklab, var(--color-primary) 22%, transparent);--surface-success-soft:color-mix(in oklab, var(--color-success) 14%, transparent);--surface-warning-soft:color-mix(in oklab, var(--color-warning) 14%, transparent);--surface-danger-soft:color-mix(in oklab, var(--color-error) 14%, transparent);--surface-comment-shell:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .035), transparent 120px), color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-shell-header:color-mix(in srgb, var(--color-surface) 97%, var(--color-comment) 3%);--surface-comment-record:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .028), transparent 70%), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-record-hover:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .042), transparent 70%), color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-record-active:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .055), transparent 72%), color-mix(in srgb, var(--color-surface-2) 90%, var(--color-comment) 10%);--surface-comment-subtle:color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-subtle-strong:color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-card:color-mix(in srgb, var(--color-surface) 94%, var(--color-comment) 6%);--surface-comment-elevated:color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-offset:color-mix(in srgb, var(--color-surface-offset) 90%, var(--color-comment) 10%);--surface-comment-offset-soft:color-mix(in srgb, var(--color-surface-offset) 88%, var(--color-comment) 12%);--surface-comment-offset-strong:color-mix(in srgb, var(--color-surface-offset) 84%, var(--color-comment) 16%);--surface-comment-offset-active:color-mix(in srgb, var(--color-surface-offset) 72%, var(--color-comment) 28%);--surface-comment-highlight-hover:color-mix(in srgb, var(--color-comment-soft) 74%, var(--color-comment) 26%);--surface-comment-highlight-active:color-mix(in srgb, var(--color-comment-soft) 62%, var(--color-comment) 38%);--surface-comment-selection:color-mix(in srgb, var(--color-surface) 25%, var(--color-comment) 75%);--surface-comment-preview-fade:linear-gradient(180deg, oklch(0% 0 0/0), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%));--border-comment-soft:color-mix(in srgb, var(--color-divider) 90%, var(--color-comment) 10%);--border-comment-muted:color-mix(in srgb, var(--color-divider) 88%, var(--color-comment) 12%);--border-comment-strong:color-mix(in srgb, var(--color-border) 82%, var(--color-comment) 18%);--border-comment-active:color-mix(in srgb, var(--color-border) 78%, var(--color-comment) 22%);--shadow-comment-outline:0 0 0 1px oklch(from var(--color-comment) l c h / .14);--surface-warning-toast:linear-gradient(135deg, oklab(94.9166% -.0018052 .0644112), oklab(99.8777% .00026585 .000908241) 42%), #fff8e7;--border-warning-toast:oklab(73.4461% .062398 .147608);--text-warning-toast:#422006;--shadow-warning-toast:0 16px 30px #542e0a2e, 0 0 0 1px #f59e0b1f;--border-accent-soft:color-mix(in oklab, var(--color-primary) 22%, transparent);--border-accent-muted:color-mix(in oklab, var(--color-primary) 24%, var(--color-border));--border-accent-strong:color-mix(in oklab, var(--color-primary) 34%, var(--color-border));--border-accent-stronger:color-mix(in oklab, var(--color-primary) 40%, var(--color-border));--shadow-accent-inset:inset 0 0 0 1px color-mix(in oklab, var(--color-primary) 14%, transparent);--shadow-accent-outline:0 0 0 1px color-mix(in oklab, var(--color-primary) 16%, transparent);--shadow-accent-halo:0 0 0 3px oklch(from var(--color-primary) l c h / .16);--shadow-accent-ring:0 0 0 2px var(--color-surface), 0 0 0 4px oklch(from var(--color-primary) l c h / .18);--shadow-accent-ring-strong:0 0 0 2px var(--color-bg), 0 0 0 4px oklch(from var(--color-primary) l c h / .45);--shadow-accent-ring-solid:0 0 0 2px var(--color-primary), 0 0 0 4px oklch(from var(--color-primary) l c h / .2);--shadow-elevated-soft:0 10px 24px color-mix(in oklab, var(--color-surface-ink) 10%, transparent);--shadow-floating-soft:0 14px 34px oklch(0% 0 0/.18);--shadow-floating-hover:0 18px 40px oklch(0% 0 0/.2);--shadow-media-soft:0 16px 40px oklch(0% 0 0/.24);--shadow-media-stage:0 28px 80px oklch(0% 0 0/.28);--shadow-media-modal:0 10px 40px #00000059;--shadow-card-strong:0 20px 56px oklch(0% 0 0/.24);--shadow-sheet-inset:inset 0 1px 0 color-mix(in oklab, var(--color-text) 4%, transparent);--shadow-focus:0 0 0 3px oklch(from var(--color-primary) l c h / .15);--shadow-focus-compact:0 0 0 2px oklch(from var(--color-primary) l c h / .45);--interactive-border:color-mix(in oklab, var(--color-primary) 22%, transparent);--interactive-surface:color-mix(in oklab, var(--color-primary) 14%, transparent);--color-text-on-dark:#fff;--shadow-sm:0 1px 2px oklch(20% .02 260/.06);--shadow-md:0 4px 12px oklch(20% .02 260/.08);--shadow-lg:0 12px 32px oklch(20% .02 260/.12)}[data-theme=dark]{--color-bg:#0f1117;--color-surface:#161822;--color-surface-2:#1c1e2c;--color-surface-offset:#1a1c28;--color-surface-offset-2:#22243a;--color-surface-dynamic:#2a2c3e;--color-surface-raised:#202330;--color-surface-ink:#050608;--color-divider:#2e3044;--color-border:#383a50;--color-text:#e2e2ea;--color-text-muted:#8b8ba0;--color-text-faint:#5a5a70;--color-text-inverse:#0f1117;--color-primary:#818cf8;--color-primary-hover:#6366f1;--color-primary-active:#4f46e5;--color-primary-highlight:#1e1e3a;--color-comment:#818cf8;--color-comment-soft:#818cf81a;--color-comment-strong:#818cf829;--color-comment-text:#c7d2fe;--color-error:#f87171;--color-error-highlight:#2a1a1a;--color-success:#4ade80;--color-success-highlight:#1a2a1a;--color-warning:#fbbf24;--color-warning-highlight:#2a261a;--diff-add-bg:#4ade8014;--diff-add-line-bg:#4ade8026;--diff-add-text:#4ade80;--diff-del-bg:#f8717114;--diff-del-line-bg:#f8717126;--diff-del-text:#f87171;--diff-hunk-bg:#818cf81a;--diff-hunk-text:#818cf8;--diff-gutter:#5a5a70;--surface-fill-subtle:color-mix(in oklab, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-fill-strong:color-mix(in oklab, var(--color-surface-offset) 60%, var(--color-surface-offset-2) 40%);--surface-overlay:color-mix(in srgb, var(--color-surface) 84%, var(--color-surface-offset) 16%);--surface-overlay-soft:color-mix(in srgb, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-overlay-strong:color-mix(in srgb, var(--color-surface) 90%, var(--color-surface-offset) 10%);--surface-overlay-raised:color-mix(in oklab, var(--color-surface) 94%, transparent);--surface-overlay-header:color-mix(in srgb, var(--color-surface-offset) 76%, var(--color-bg) 24%);--surface-overlay-offset:color-mix(in oklab, var(--color-surface-offset) 82%, transparent);--surface-scrim:oklch(10% 0 0/.42);--surface-scrim-strong:oklch(8% .01 260/.82);--surface-inverse-glass:oklch(18% .02 260/.68);--surface-inverse-glass-hover:oklch(24% .02 260/.82);--surface-media-canvas:#000;--surface-embed-canvas:#121212;--surface-avatar-muted:#ffffff38;--surface-avatar-label:#0f1117d6;--surface-accent-subtle:color-mix(in oklab, var(--color-primary) 8%, var(--color-surface));--surface-accent-soft:color-mix(in oklab, var(--color-primary) 16%, transparent);--surface-accent-strong:color-mix(in oklab, var(--color-primary) 22%, transparent);--surface-success-soft:color-mix(in oklab, var(--color-success) 14%, transparent);--surface-warning-soft:color-mix(in oklab, var(--color-warning) 14%, transparent);--surface-danger-soft:color-mix(in oklab, var(--color-error) 14%, transparent);--surface-comment-shell:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .035), transparent 120px), color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-shell-header:color-mix(in srgb, var(--color-surface) 97%, var(--color-comment) 3%);--surface-comment-record:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .028), transparent 70%), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-record-hover:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .042), transparent 70%), color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-record-active:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .055), transparent 72%), color-mix(in srgb, var(--color-surface-2) 90%, var(--color-comment) 10%);--surface-comment-subtle:color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-subtle-strong:color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-card:color-mix(in srgb, var(--color-surface) 94%, var(--color-comment) 6%);--surface-comment-elevated:color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-offset:color-mix(in srgb, var(--color-surface-offset) 90%, var(--color-comment) 10%);--surface-comment-offset-soft:color-mix(in srgb, var(--color-surface-offset) 88%, var(--color-comment) 12%);--surface-comment-offset-strong:color-mix(in srgb, var(--color-surface-offset) 84%, var(--color-comment) 16%);--surface-comment-offset-active:color-mix(in srgb, var(--color-surface-offset) 72%, var(--color-comment) 28%);--surface-comment-highlight-hover:color-mix(in srgb, var(--color-comment-soft) 74%, var(--color-comment) 26%);--surface-comment-highlight-active:color-mix(in srgb, var(--color-comment-soft) 62%, var(--color-comment) 38%);--surface-comment-selection:color-mix(in srgb, var(--color-surface) 25%, var(--color-comment) 75%);--surface-comment-preview-fade:linear-gradient(180deg, oklch(0% 0 0/0), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%));--border-comment-soft:color-mix(in srgb, var(--color-divider) 90%, var(--color-comment) 10%);--border-comment-muted:color-mix(in srgb, var(--color-divider) 88%, var(--color-comment) 12%);--border-comment-strong:color-mix(in srgb, var(--color-border) 82%, var(--color-comment) 18%);--border-comment-active:color-mix(in srgb, var(--color-border) 78%, var(--color-comment) 22%);--shadow-comment-outline:0 0 0 1px oklch(from var(--color-comment) l c h / .14);--surface-warning-toast:linear-gradient(135deg, oklab(76.8591% .0560995 .154808/.32), color-mix(in oklab, var(--color-surface) 86%, #0b1022 14%) 42%), color-mix(in oklab, var(--color-surface) 74%, #1b1320 26%);--border-warning-toast:oklab(79.4887% .0497246 .137216/.88);--text-warning-toast:oklab(99.6952% -.000454402 .00461993);--shadow-warning-toast:0 18px 34px #00000061, 0 0 0 1px oklab(76.8591% .0560995 .154808/.18);--border-accent-soft:color-mix(in oklab, var(--color-primary) 22%, transparent);--border-accent-muted:color-mix(in oklab, var(--color-primary) 24%, var(--color-border));--border-accent-strong:color-mix(in oklab, var(--color-primary) 34%, var(--color-border));--border-accent-stronger:color-mix(in oklab, var(--color-primary) 40%, var(--color-border));--shadow-accent-inset:inset 0 0 0 1px color-mix(in oklab, var(--color-primary) 14%, transparent);--shadow-accent-outline:0 0 0 1px color-mix(in oklab, var(--color-primary) 16%, transparent);--shadow-accent-halo:0 0 0 3px oklch(from var(--color-primary) l c h / .16);--shadow-accent-ring:0 0 0 2px var(--color-surface), 0 0 0 4px oklch(from var(--color-primary) l c h / .18);--shadow-accent-ring-strong:0 0 0 2px var(--color-bg), 0 0 0 4px oklch(from var(--color-primary) l c h / .45);--shadow-accent-ring-solid:0 0 0 2px var(--color-primary), 0 0 0 4px oklch(from var(--color-primary) l c h / .2);--shadow-elevated-soft:0 10px 24px color-mix(in oklab, var(--color-surface-ink) 10%, transparent);--shadow-floating-soft:0 14px 34px oklch(0% 0 0/.18);--shadow-floating-hover:0 18px 40px oklch(0% 0 0/.2);--shadow-media-soft:0 16px 40px oklch(0% 0 0/.24);--shadow-media-stage:0 28px 80px oklch(0% 0 0/.28);--shadow-media-modal:0 16px 48px #0009;--shadow-card-strong:0 20px 56px oklch(0% 0 0/.24);--shadow-sheet-inset:inset 0 1px 0 color-mix(in oklab, var(--color-text) 4%, transparent);--shadow-focus:0 0 0 3px oklch(from var(--color-primary) l c h / .15);--shadow-focus-compact:0 0 0 2px oklch(from var(--color-primary) l c h / .45);--interactive-border:color-mix(in oklab, var(--color-primary) 32%, transparent);--interactive-surface:color-mix(in oklab, var(--color-primary) 18%, transparent);--color-text-on-dark:#fff;--shadow-sm:0 1px 2px oklch(0% 0 0/.25);--shadow-md:0 4px 12px oklch(0% 0 0/.35);--shadow-lg:0 12px 32px oklch(0% 0 0/.5)}@media (prefers-color-scheme:dark){:root:not([data-theme]){--color-bg:#0f1117;--color-surface:#161822;--color-surface-2:#1c1e2c;--color-surface-offset:#1a1c28;--color-surface-offset-2:#22243a;--color-surface-dynamic:#2a2c3e;--color-surface-raised:#202330;--color-surface-ink:#050608;--color-divider:#2e3044;--color-border:#383a50;--color-text:#e2e2ea;--color-text-muted:#8b8ba0;--color-text-faint:#5a5a70;--color-text-inverse:#0f1117;--color-primary:#818cf8;--color-primary-hover:#6366f1;--color-primary-active:#4f46e5;--color-primary-highlight:#1e1e3a;--color-comment:#818cf8;--color-comment-soft:#818cf81a;--color-comment-strong:#818cf829;--color-comment-text:#c7d2fe;--color-error:#f87171;--color-error-highlight:#2a1a1a;--color-success:#4ade80;--color-success-highlight:#1a2a1a;--color-warning:#fbbf24;--color-warning-highlight:#2a261a;--surface-fill-subtle:color-mix(in oklab, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-fill-strong:color-mix(in oklab, var(--color-surface-offset) 60%, var(--color-surface-offset-2) 40%);--surface-overlay:color-mix(in srgb, var(--color-surface) 84%, var(--color-surface-offset) 16%);--surface-overlay-soft:color-mix(in srgb, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-overlay-strong:color-mix(in srgb, var(--color-surface) 90%, var(--color-surface-offset) 10%);--surface-overlay-raised:color-mix(in oklab, var(--color-surface) 94%, transparent);--surface-overlay-header:color-mix(in srgb, var(--color-surface-offset) 76%, var(--color-bg) 24%);--surface-overlay-offset:color-mix(in oklab, var(--color-surface-offset) 82%, transparent);--surface-scrim:oklch(10% 0 0/.42);--surface-scrim-strong:oklch(8% .01 260/.82);--surface-inverse-glass:oklch(18% .02 260/.68);--surface-inverse-glass-hover:oklch(24% .02 260/.82);--surface-media-canvas:#000;--surface-embed-canvas:#121212;--surface-avatar-muted:#ffffff38;--surface-avatar-label:#0f1117d6;--surface-accent-subtle:color-mix(in oklab, var(--color-primary) 8%, var(--color-surface));--surface-accent-soft:color-mix(in oklab, var(--color-primary) 16%, transparent);--surface-accent-strong:color-mix(in oklab, var(--color-primary) 22%, transparent);--surface-success-soft:color-mix(in oklab, var(--color-success) 14%, transparent);--surface-warning-soft:color-mix(in oklab, var(--color-warning) 14%, transparent);--surface-danger-soft:color-mix(in oklab, var(--color-error) 14%, transparent);--surface-comment-shell:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .035), transparent 120px), color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-shell-header:color-mix(in srgb, var(--color-surface) 97%, var(--color-comment) 3%);--surface-comment-record:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .028), transparent 70%), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-record-hover:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .042), transparent 70%), color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-record-active:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .055), transparent 72%), color-mix(in srgb, var(--color-surface-2) 90%, var(--color-comment) 10%);--surface-comment-subtle:color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-subtle-strong:color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-card:color-mix(in srgb, var(--color-surface) 94%, var(--color-comment) 6%);--surface-comment-elevated:color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-offset:color-mix(in srgb, var(--color-surface-offset) 90%, var(--color-comment) 10%);--surface-comment-offset-soft:color-mix(in srgb, var(--color-surface-offset) 88%, var(--color-comment) 12%);--surface-comment-offset-strong:color-mix(in srgb, var(--color-surface-offset) 84%, var(--color-comment) 16%);--surface-comment-offset-active:color-mix(in srgb, var(--color-surface-offset) 72%, var(--color-comment) 28%);--surface-comment-highlight-hover:color-mix(in srgb, var(--color-comment-soft) 74%, var(--color-comment) 26%);--surface-comment-highlight-active:color-mix(in srgb, var(--color-comment-soft) 62%, var(--color-comment) 38%);--surface-comment-selection:color-mix(in srgb, var(--color-surface) 25%, var(--color-comment) 75%);--surface-comment-preview-fade:linear-gradient(180deg, oklch(0% 0 0/0), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%));--border-comment-soft:color-mix(in srgb, var(--color-divider) 90%, var(--color-comment) 10%);--border-comment-muted:color-mix(in srgb, var(--color-divider) 88%, var(--color-comment) 12%);--border-comment-strong:color-mix(in srgb, var(--color-border) 82%, var(--color-comment) 18%);--border-comment-active:color-mix(in srgb, var(--color-border) 78%, var(--color-comment) 22%);--shadow-comment-outline:0 0 0 1px oklch(from var(--color-comment) l c h / .14);--surface-warning-toast:linear-gradient(135deg, oklab(76.8591% .0560995 .154808/.32), color-mix(in oklab, var(--color-surface) 86%, #0b1022 14%) 42%), color-mix(in oklab, var(--color-surface) 74%, #1b1320 26%);--border-warning-toast:oklab(79.4887% .0497246 .137216/.88);--text-warning-toast:oklab(99.6952% -.000454402 .00461993);--shadow-warning-toast:0 18px 34px #00000061, 0 0 0 1px oklab(76.8591% .0560995 .154808/.18);--border-accent-soft:color-mix(in oklab, var(--color-primary) 22%, transparent);--border-accent-muted:color-mix(in oklab, var(--color-primary) 24%, var(--color-border));--border-accent-strong:color-mix(in oklab, var(--color-primary) 34%, var(--color-border));--border-accent-stronger:color-mix(in oklab, var(--color-primary) 40%, var(--color-border));--shadow-accent-inset:inset 0 0 0 1px color-mix(in oklab, var(--color-primary) 14%, transparent);--shadow-accent-outline:0 0 0 1px color-mix(in oklab, var(--color-primary) 16%, transparent);--shadow-accent-halo:0 0 0 3px oklch(from var(--color-primary) l c h / .16);--shadow-accent-ring:0 0 0 2px var(--color-surface), 0 0 0 4px oklch(from var(--color-primary) l c h / .18);--shadow-accent-ring-strong:0 0 0 2px var(--color-bg), 0 0 0 4px oklch(from var(--color-primary) l c h / .45);--shadow-accent-ring-solid:0 0 0 2px var(--color-primary), 0 0 0 4px oklch(from var(--color-primary) l c h / .2);--shadow-elevated-soft:0 10px 24px color-mix(in oklab, var(--color-surface-ink) 10%, transparent);--shadow-floating-soft:0 14px 34px oklch(0% 0 0/.18);--shadow-floating-hover:0 18px 40px oklch(0% 0 0/.2);--shadow-media-soft:0 16px 40px oklch(0% 0 0/.24);--shadow-media-stage:0 28px 80px oklch(0% 0 0/.28);--shadow-media-modal:0 16px 48px #0009;--shadow-card-strong:0 20px 56px oklch(0% 0 0/.24);--shadow-sheet-inset:inset 0 1px 0 color-mix(in oklab, var(--color-text) 4%, transparent);--shadow-focus:0 0 0 3px oklch(from var(--color-primary) l c h / .15);--shadow-focus-compact:0 0 0 2px oklch(from var(--color-primary) l c h / .45);--interactive-border:color-mix(in oklab, var(--color-primary) 32%, transparent);--interactive-surface:color-mix(in oklab, var(--color-primary) 18%, transparent);--color-text-on-dark:#fff;--shadow-sm:0 1px 2px oklch(0% 0 0/.25);--shadow-md:0 4px 12px oklch(0% 0 0/.35);--shadow-lg:0 12px 32px oklch(0% 0 0/.5)}}*,:before,:after{box-sizing:border-box;margin:0;padding:0}html{-webkit-text-size-adjust:none;-moz-text-size-adjust:none;text-size-adjust:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizelegibility;scroll-behavior:smooth;hanging-punctuation:first last;scroll-padding-top:var(--space-16);overscroll-behavior:none;height:100%;overflow:hidden}body{height:100%;min-height:100dvh;line-height:1.6;font-family:var(--font-body,sans-serif);font-size:var(--text-sm);color:var(--color-text);background-color:var(--color-bg);overflow:hidden}img,picture,video,canvas,svg{max-width:100%;height:auto;display:block}ul[role=list],ol[role=list]{list-style:none}input,button,textarea,select{font:inherit;color:inherit}h1,h2,h3,h4,h5,h6{font-family:var(--font-display,inherit);text-wrap:balance;line-height:1.15}p,li,figcaption{text-wrap:pretty;max-width:72ch}::selection{background:oklch(from var(--color-primary) l c h / .25);color:var(--color-text)}:focus-visible{outline:2px solid var(--color-primary);outline-offset:3px;border-radius:var(--radius-sm)}@media (prefers-reduced-motion:reduce){*,:before,:after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important;animation-iteration-count:1!important}}button{cursor:pointer;background:0 0;border:none}table{border-collapse:collapse;width:100%}.sr-only{clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}html,body{width:100%;height:100%;margin:0;overflow:hidden}body[data-surface]{font-family:var(--font-body);font-size:var(--text-ui-sm);color:var(--color-text);background:var(--color-bg)}#root{width:100%;height:100%}
@@ -1 +0,0 @@
1
- :root{--text-xs:clamp(.75rem, .7rem + .25vw, .875rem);--text-sm:clamp(.875rem, .8rem + .35vw, 1rem);--text-base:clamp(1rem, .9rem + .5vw, 1.125rem);--text-lg:clamp(1.125rem, .95rem + .85vw, 1.5rem);--text-xl:clamp(1.5rem, 1rem + 1.5vw, 2.25rem);--text-2xl:clamp(2rem, 1.2rem + 2.5vw, 3.5rem);--text-label:12px;--text-meta:11px;--text-caption:10px;--text-micro:9px;--text-code-sm:11.5px;--text-ui-sm:13px;--text-ui-md:14px;--text-title-sm:15px;--text-title-md:18px;--font-body:"Inter", system-ui, sans-serif;--font-display:"Geist", "Cal Sans", "Inter", system-ui, sans-serif;--font-mono:"JetBrains Mono", "Fira Code", monospace;--space-1:.25rem;--space-2:.5rem;--space-3:.75rem;--space-4:1rem;--space-5:1.25rem;--space-6:1.5rem;--space-8:2rem;--space-10:2.5rem;--space-12:3rem;--space-16:4rem;--space-20:5rem;--space-24:6rem;--space-32:8rem;--radius-sm:.375rem;--radius-md:.5rem;--radius-lg:.75rem;--radius-xl:1rem;--radius-2xs:2px;--radius-xs:4px;--radius-lg-plus:10px;--radius-xl-plus:18px;--radius-full:9999px;--transition-interactive:.18s cubic-bezier(.16, 1, .3, 1);--content-narrow:640px;--content-default:960px;--content-wide:1200px;--preview-content-width:720px;--panel-comments-width:min(300px, 34vw);--panel-comments-min-width:240px;--panel-outline-width:220px;--toolbar-h:48px;--control-h-xs:28px;--control-h-sm:30px;--control-h-md:36px;--control-h-lg:44px;--control-icon-sm:14px;--control-icon-md:16px;--panel-border-width:1px}:root,[data-theme=light]{--color-bg:#f5f5f7;--color-surface:#fff;--color-surface-2:#fafafe;--color-surface-offset:#eeeef2;--color-surface-offset-2:#e6e6eb;--color-surface-dynamic:#dddde3;--color-surface-raised:#fff;--color-surface-ink:#0f1117;--color-divider:#d1d1d8;--color-border:#c4c4ce;--color-text:#1a1a2e;--color-text-muted:#6b6b80;--color-text-faint:#a0a0b0;--color-text-inverse:#f5f5f7;--color-primary:#4f46e5;--color-primary-hover:#4338ca;--color-primary-active:#3730a3;--color-primary-highlight:#e0e0ff;--color-comment:#4f46e5;--color-comment-soft:#4f46e514;--color-comment-strong:#4f46e524;--color-comment-text:#3730a3;--color-error:#dc2626;--color-error-highlight:#fce8e8;--color-success:#16a34a;--color-success-highlight:#dcfce7;--color-warning:#d97706;--color-warning-highlight:#fef3c7;--diff-add-bg:#16a34a0f;--diff-add-line-bg:#16a34a24;--diff-add-text:#16a34a;--diff-del-bg:#dc26260f;--diff-del-line-bg:#dc262624;--diff-del-text:#dc2626;--diff-hunk-bg:#4f46e514;--diff-hunk-text:#4f46e5;--diff-gutter:#a0a0b0;--surface-fill-subtle:color-mix(in oklab, var(--color-surface) 92%, var(--color-surface-offset) 8%);--surface-fill-strong:color-mix(in oklab, var(--color-surface-offset) 72%, var(--color-surface-offset-2) 28%);--surface-overlay:color-mix(in srgb, var(--color-surface) 84%, var(--color-surface-offset) 16%);--surface-overlay-soft:color-mix(in srgb, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-overlay-strong:color-mix(in srgb, var(--color-surface) 90%, var(--color-surface-offset) 10%);--surface-overlay-raised:color-mix(in oklab, var(--color-surface) 94%, transparent);--surface-overlay-header:color-mix(in srgb, var(--color-surface-offset) 76%, var(--color-bg) 24%);--surface-overlay-offset:color-mix(in oklab, var(--color-surface-offset) 82%, transparent);--surface-scrim:oklch(10% 0 0/.42);--surface-scrim-strong:oklch(8% .01 260/.82);--surface-inverse-glass:oklch(18% .02 260/.68);--surface-inverse-glass-hover:oklch(24% .02 260/.82);--surface-media-canvas:#000;--surface-embed-canvas:#fff;--surface-avatar-muted:#ffffff38;--surface-avatar-label:#0f1117d6;--surface-accent-subtle:color-mix(in oklab, var(--color-primary) 8%, var(--color-surface));--surface-accent-soft:color-mix(in oklab, var(--color-primary) 16%, transparent);--surface-accent-strong:color-mix(in oklab, var(--color-primary) 22%, transparent);--surface-success-soft:color-mix(in oklab, var(--color-success) 14%, transparent);--surface-warning-soft:color-mix(in oklab, var(--color-warning) 14%, transparent);--surface-danger-soft:color-mix(in oklab, var(--color-error) 14%, transparent);--surface-comment-shell:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .035), transparent 120px), color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-shell-header:color-mix(in srgb, var(--color-surface) 97%, var(--color-comment) 3%);--surface-comment-record:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .028), transparent 70%), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-record-hover:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .042), transparent 70%), color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-record-active:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .055), transparent 72%), color-mix(in srgb, var(--color-surface-2) 90%, var(--color-comment) 10%);--surface-comment-subtle:color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-subtle-strong:color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-card:color-mix(in srgb, var(--color-surface) 94%, var(--color-comment) 6%);--surface-comment-elevated:color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-offset:color-mix(in srgb, var(--color-surface-offset) 90%, var(--color-comment) 10%);--surface-comment-offset-soft:color-mix(in srgb, var(--color-surface-offset) 88%, var(--color-comment) 12%);--surface-comment-offset-strong:color-mix(in srgb, var(--color-surface-offset) 84%, var(--color-comment) 16%);--surface-comment-offset-active:color-mix(in srgb, var(--color-surface-offset) 72%, var(--color-comment) 28%);--surface-comment-highlight-hover:color-mix(in srgb, var(--color-comment-soft) 74%, var(--color-comment) 26%);--surface-comment-highlight-active:color-mix(in srgb, var(--color-comment-soft) 62%, var(--color-comment) 38%);--surface-comment-selection:color-mix(in srgb, var(--color-surface) 25%, var(--color-comment) 75%);--surface-comment-preview-fade:linear-gradient(180deg, oklch(0% 0 0/0), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%));--border-comment-soft:color-mix(in srgb, var(--color-divider) 90%, var(--color-comment) 10%);--border-comment-muted:color-mix(in srgb, var(--color-divider) 88%, var(--color-comment) 12%);--border-comment-strong:color-mix(in srgb, var(--color-border) 82%, var(--color-comment) 18%);--border-comment-active:color-mix(in srgb, var(--color-border) 78%, var(--color-comment) 22%);--shadow-comment-outline:0 0 0 1px oklch(from var(--color-comment) l c h / .14);--surface-warning-toast:linear-gradient(135deg, oklab(94.9166% -.0018052 .0644112), oklab(99.8777% .00026585 .000908241) 42%), #fff8e7;--border-warning-toast:oklab(73.4461% .062398 .147608);--text-warning-toast:#422006;--shadow-warning-toast:0 16px 30px #542e0a2e, 0 0 0 1px #f59e0b1f;--border-accent-soft:color-mix(in oklab, var(--color-primary) 22%, transparent);--border-accent-muted:color-mix(in oklab, var(--color-primary) 24%, var(--color-border));--border-accent-strong:color-mix(in oklab, var(--color-primary) 34%, var(--color-border));--border-accent-stronger:color-mix(in oklab, var(--color-primary) 40%, var(--color-border));--shadow-accent-inset:inset 0 0 0 1px color-mix(in oklab, var(--color-primary) 14%, transparent);--shadow-accent-outline:0 0 0 1px color-mix(in oklab, var(--color-primary) 16%, transparent);--shadow-accent-halo:0 0 0 3px oklch(from var(--color-primary) l c h / .16);--shadow-accent-ring:0 0 0 2px var(--color-surface), 0 0 0 4px oklch(from var(--color-primary) l c h / .18);--shadow-accent-ring-strong:0 0 0 2px var(--color-bg), 0 0 0 4px oklch(from var(--color-primary) l c h / .45);--shadow-accent-ring-solid:0 0 0 2px var(--color-primary), 0 0 0 4px oklch(from var(--color-primary) l c h / .2);--shadow-elevated-soft:0 10px 24px color-mix(in oklab, var(--color-surface-ink) 10%, transparent);--shadow-floating-soft:0 14px 34px oklch(0% 0 0/.18);--shadow-floating-hover:0 18px 40px oklch(0% 0 0/.2);--shadow-media-soft:0 16px 40px oklch(0% 0 0/.24);--shadow-media-stage:0 28px 80px oklch(0% 0 0/.28);--shadow-media-modal:0 10px 40px #00000059;--shadow-card-strong:0 20px 56px oklch(0% 0 0/.24);--shadow-sheet-inset:inset 0 1px 0 color-mix(in oklab, var(--color-text) 4%, transparent);--shadow-focus:0 0 0 3px oklch(from var(--color-primary) l c h / .15);--shadow-focus-compact:0 0 0 2px oklch(from var(--color-primary) l c h / .45);--interactive-border:color-mix(in oklab, var(--color-primary) 22%, transparent);--interactive-surface:color-mix(in oklab, var(--color-primary) 14%, transparent);--color-text-on-dark:#fff;--shadow-sm:0 1px 2px oklch(20% .02 260/.06);--shadow-md:0 4px 12px oklch(20% .02 260/.08);--shadow-lg:0 12px 32px oklch(20% .02 260/.12)}[data-theme=dark]{--color-bg:#0f1117;--color-surface:#161822;--color-surface-2:#1c1e2c;--color-surface-offset:#1a1c28;--color-surface-offset-2:#22243a;--color-surface-dynamic:#2a2c3e;--color-surface-raised:#202330;--color-surface-ink:#050608;--color-divider:#2e3044;--color-border:#383a50;--color-text:#e2e2ea;--color-text-muted:#8b8ba0;--color-text-faint:#5a5a70;--color-text-inverse:#0f1117;--color-primary:#818cf8;--color-primary-hover:#6366f1;--color-primary-active:#4f46e5;--color-primary-highlight:#1e1e3a;--color-comment:#818cf8;--color-comment-soft:#818cf81a;--color-comment-strong:#818cf829;--color-comment-text:#c7d2fe;--color-error:#f87171;--color-error-highlight:#2a1a1a;--color-success:#4ade80;--color-success-highlight:#1a2a1a;--color-warning:#fbbf24;--color-warning-highlight:#2a261a;--diff-add-bg:#4ade8014;--diff-add-line-bg:#4ade8026;--diff-add-text:#4ade80;--diff-del-bg:#f8717114;--diff-del-line-bg:#f8717126;--diff-del-text:#f87171;--diff-hunk-bg:#818cf81a;--diff-hunk-text:#818cf8;--diff-gutter:#5a5a70;--surface-fill-subtle:color-mix(in oklab, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-fill-strong:color-mix(in oklab, var(--color-surface-offset) 60%, var(--color-surface-offset-2) 40%);--surface-overlay:color-mix(in srgb, var(--color-surface) 84%, var(--color-surface-offset) 16%);--surface-overlay-soft:color-mix(in srgb, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-overlay-strong:color-mix(in srgb, var(--color-surface) 90%, var(--color-surface-offset) 10%);--surface-overlay-raised:color-mix(in oklab, var(--color-surface) 94%, transparent);--surface-overlay-header:color-mix(in srgb, var(--color-surface-offset) 76%, var(--color-bg) 24%);--surface-overlay-offset:color-mix(in oklab, var(--color-surface-offset) 82%, transparent);--surface-scrim:oklch(10% 0 0/.42);--surface-scrim-strong:oklch(8% .01 260/.82);--surface-inverse-glass:oklch(18% .02 260/.68);--surface-inverse-glass-hover:oklch(24% .02 260/.82);--surface-media-canvas:#000;--surface-embed-canvas:#121212;--surface-avatar-muted:#ffffff38;--surface-avatar-label:#0f1117d6;--surface-accent-subtle:color-mix(in oklab, var(--color-primary) 8%, var(--color-surface));--surface-accent-soft:color-mix(in oklab, var(--color-primary) 16%, transparent);--surface-accent-strong:color-mix(in oklab, var(--color-primary) 22%, transparent);--surface-success-soft:color-mix(in oklab, var(--color-success) 14%, transparent);--surface-warning-soft:color-mix(in oklab, var(--color-warning) 14%, transparent);--surface-danger-soft:color-mix(in oklab, var(--color-error) 14%, transparent);--surface-comment-shell:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .035), transparent 120px), color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-shell-header:color-mix(in srgb, var(--color-surface) 97%, var(--color-comment) 3%);--surface-comment-record:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .028), transparent 70%), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-record-hover:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .042), transparent 70%), color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-record-active:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .055), transparent 72%), color-mix(in srgb, var(--color-surface-2) 90%, var(--color-comment) 10%);--surface-comment-subtle:color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-subtle-strong:color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-card:color-mix(in srgb, var(--color-surface) 94%, var(--color-comment) 6%);--surface-comment-elevated:color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-offset:color-mix(in srgb, var(--color-surface-offset) 90%, var(--color-comment) 10%);--surface-comment-offset-soft:color-mix(in srgb, var(--color-surface-offset) 88%, var(--color-comment) 12%);--surface-comment-offset-strong:color-mix(in srgb, var(--color-surface-offset) 84%, var(--color-comment) 16%);--surface-comment-offset-active:color-mix(in srgb, var(--color-surface-offset) 72%, var(--color-comment) 28%);--surface-comment-highlight-hover:color-mix(in srgb, var(--color-comment-soft) 74%, var(--color-comment) 26%);--surface-comment-highlight-active:color-mix(in srgb, var(--color-comment-soft) 62%, var(--color-comment) 38%);--surface-comment-selection:color-mix(in srgb, var(--color-surface) 25%, var(--color-comment) 75%);--surface-comment-preview-fade:linear-gradient(180deg, oklch(0% 0 0/0), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%));--border-comment-soft:color-mix(in srgb, var(--color-divider) 90%, var(--color-comment) 10%);--border-comment-muted:color-mix(in srgb, var(--color-divider) 88%, var(--color-comment) 12%);--border-comment-strong:color-mix(in srgb, var(--color-border) 82%, var(--color-comment) 18%);--border-comment-active:color-mix(in srgb, var(--color-border) 78%, var(--color-comment) 22%);--shadow-comment-outline:0 0 0 1px oklch(from var(--color-comment) l c h / .14);--surface-warning-toast:linear-gradient(135deg, oklab(76.8591% .0560995 .154808/.32), color-mix(in oklab, var(--color-surface) 86%, #0b1022 14%) 42%), color-mix(in oklab, var(--color-surface) 74%, #1b1320 26%);--border-warning-toast:oklab(79.4887% .0497246 .137216/.88);--text-warning-toast:oklab(99.6952% -.000454402 .00461993);--shadow-warning-toast:0 18px 34px #00000061, 0 0 0 1px oklab(76.8591% .0560995 .154808/.18);--border-accent-soft:color-mix(in oklab, var(--color-primary) 22%, transparent);--border-accent-muted:color-mix(in oklab, var(--color-primary) 24%, var(--color-border));--border-accent-strong:color-mix(in oklab, var(--color-primary) 34%, var(--color-border));--border-accent-stronger:color-mix(in oklab, var(--color-primary) 40%, var(--color-border));--shadow-accent-inset:inset 0 0 0 1px color-mix(in oklab, var(--color-primary) 14%, transparent);--shadow-accent-outline:0 0 0 1px color-mix(in oklab, var(--color-primary) 16%, transparent);--shadow-accent-halo:0 0 0 3px oklch(from var(--color-primary) l c h / .16);--shadow-accent-ring:0 0 0 2px var(--color-surface), 0 0 0 4px oklch(from var(--color-primary) l c h / .18);--shadow-accent-ring-strong:0 0 0 2px var(--color-bg), 0 0 0 4px oklch(from var(--color-primary) l c h / .45);--shadow-accent-ring-solid:0 0 0 2px var(--color-primary), 0 0 0 4px oklch(from var(--color-primary) l c h / .2);--shadow-elevated-soft:0 10px 24px color-mix(in oklab, var(--color-surface-ink) 10%, transparent);--shadow-floating-soft:0 14px 34px oklch(0% 0 0/.18);--shadow-floating-hover:0 18px 40px oklch(0% 0 0/.2);--shadow-media-soft:0 16px 40px oklch(0% 0 0/.24);--shadow-media-stage:0 28px 80px oklch(0% 0 0/.28);--shadow-media-modal:0 16px 48px #0009;--shadow-card-strong:0 20px 56px oklch(0% 0 0/.24);--shadow-sheet-inset:inset 0 1px 0 color-mix(in oklab, var(--color-text) 4%, transparent);--shadow-focus:0 0 0 3px oklch(from var(--color-primary) l c h / .15);--shadow-focus-compact:0 0 0 2px oklch(from var(--color-primary) l c h / .45);--interactive-border:color-mix(in oklab, var(--color-primary) 32%, transparent);--interactive-surface:color-mix(in oklab, var(--color-primary) 18%, transparent);--color-text-on-dark:#fff;--shadow-sm:0 1px 2px oklch(0% 0 0/.25);--shadow-md:0 4px 12px oklch(0% 0 0/.35);--shadow-lg:0 12px 32px oklch(0% 0 0/.5)}@media (prefers-color-scheme:dark){:root:not([data-theme]){--color-bg:#0f1117;--color-surface:#161822;--color-surface-2:#1c1e2c;--color-surface-offset:#1a1c28;--color-surface-offset-2:#22243a;--color-surface-dynamic:#2a2c3e;--color-surface-raised:#202330;--color-surface-ink:#050608;--color-divider:#2e3044;--color-border:#383a50;--color-text:#e2e2ea;--color-text-muted:#8b8ba0;--color-text-faint:#5a5a70;--color-text-inverse:#0f1117;--color-primary:#818cf8;--color-primary-hover:#6366f1;--color-primary-active:#4f46e5;--color-primary-highlight:#1e1e3a;--color-comment:#818cf8;--color-comment-soft:#818cf81a;--color-comment-strong:#818cf829;--color-comment-text:#c7d2fe;--color-error:#f87171;--color-error-highlight:#2a1a1a;--color-success:#4ade80;--color-success-highlight:#1a2a1a;--color-warning:#fbbf24;--color-warning-highlight:#2a261a;--surface-fill-subtle:color-mix(in oklab, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-fill-strong:color-mix(in oklab, var(--color-surface-offset) 60%, var(--color-surface-offset-2) 40%);--surface-overlay:color-mix(in srgb, var(--color-surface) 84%, var(--color-surface-offset) 16%);--surface-overlay-soft:color-mix(in srgb, var(--color-surface) 88%, var(--color-surface-offset) 12%);--surface-overlay-strong:color-mix(in srgb, var(--color-surface) 90%, var(--color-surface-offset) 10%);--surface-overlay-raised:color-mix(in oklab, var(--color-surface) 94%, transparent);--surface-overlay-header:color-mix(in srgb, var(--color-surface-offset) 76%, var(--color-bg) 24%);--surface-overlay-offset:color-mix(in oklab, var(--color-surface-offset) 82%, transparent);--surface-scrim:oklch(10% 0 0/.42);--surface-scrim-strong:oklch(8% .01 260/.82);--surface-inverse-glass:oklch(18% .02 260/.68);--surface-inverse-glass-hover:oklch(24% .02 260/.82);--surface-media-canvas:#000;--surface-embed-canvas:#121212;--surface-avatar-muted:#ffffff38;--surface-avatar-label:#0f1117d6;--surface-accent-subtle:color-mix(in oklab, var(--color-primary) 8%, var(--color-surface));--surface-accent-soft:color-mix(in oklab, var(--color-primary) 16%, transparent);--surface-accent-strong:color-mix(in oklab, var(--color-primary) 22%, transparent);--surface-success-soft:color-mix(in oklab, var(--color-success) 14%, transparent);--surface-warning-soft:color-mix(in oklab, var(--color-warning) 14%, transparent);--surface-danger-soft:color-mix(in oklab, var(--color-error) 14%, transparent);--surface-comment-shell:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .035), transparent 120px), color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-shell-header:color-mix(in srgb, var(--color-surface) 97%, var(--color-comment) 3%);--surface-comment-record:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .028), transparent 70%), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-record-hover:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .042), transparent 70%), color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-record-active:linear-gradient(180deg, oklch(from var(--color-comment) l c h / .055), transparent 72%), color-mix(in srgb, var(--color-surface-2) 90%, var(--color-comment) 10%);--surface-comment-subtle:color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%);--surface-comment-subtle-strong:color-mix(in srgb, var(--color-surface-2) 92%, var(--color-comment) 8%);--surface-comment-card:color-mix(in srgb, var(--color-surface) 94%, var(--color-comment) 6%);--surface-comment-elevated:color-mix(in srgb, var(--color-surface) 96%, var(--color-comment) 4%);--surface-comment-offset:color-mix(in srgb, var(--color-surface-offset) 90%, var(--color-comment) 10%);--surface-comment-offset-soft:color-mix(in srgb, var(--color-surface-offset) 88%, var(--color-comment) 12%);--surface-comment-offset-strong:color-mix(in srgb, var(--color-surface-offset) 84%, var(--color-comment) 16%);--surface-comment-offset-active:color-mix(in srgb, var(--color-surface-offset) 72%, var(--color-comment) 28%);--surface-comment-highlight-hover:color-mix(in srgb, var(--color-comment-soft) 74%, var(--color-comment) 26%);--surface-comment-highlight-active:color-mix(in srgb, var(--color-comment-soft) 62%, var(--color-comment) 38%);--surface-comment-selection:color-mix(in srgb, var(--color-surface) 25%, var(--color-comment) 75%);--surface-comment-preview-fade:linear-gradient(180deg, oklch(0% 0 0/0), color-mix(in srgb, var(--color-surface-2) 95%, var(--color-comment) 5%));--border-comment-soft:color-mix(in srgb, var(--color-divider) 90%, var(--color-comment) 10%);--border-comment-muted:color-mix(in srgb, var(--color-divider) 88%, var(--color-comment) 12%);--border-comment-strong:color-mix(in srgb, var(--color-border) 82%, var(--color-comment) 18%);--border-comment-active:color-mix(in srgb, var(--color-border) 78%, var(--color-comment) 22%);--shadow-comment-outline:0 0 0 1px oklch(from var(--color-comment) l c h / .14);--surface-warning-toast:linear-gradient(135deg, oklab(76.8591% .0560995 .154808/.32), color-mix(in oklab, var(--color-surface) 86%, #0b1022 14%) 42%), color-mix(in oklab, var(--color-surface) 74%, #1b1320 26%);--border-warning-toast:oklab(79.4887% .0497246 .137216/.88);--text-warning-toast:oklab(99.6952% -.000454402 .00461993);--shadow-warning-toast:0 18px 34px #00000061, 0 0 0 1px oklab(76.8591% .0560995 .154808/.18);--border-accent-soft:color-mix(in oklab, var(--color-primary) 22%, transparent);--border-accent-muted:color-mix(in oklab, var(--color-primary) 24%, var(--color-border));--border-accent-strong:color-mix(in oklab, var(--color-primary) 34%, var(--color-border));--border-accent-stronger:color-mix(in oklab, var(--color-primary) 40%, var(--color-border));--shadow-accent-inset:inset 0 0 0 1px color-mix(in oklab, var(--color-primary) 14%, transparent);--shadow-accent-outline:0 0 0 1px color-mix(in oklab, var(--color-primary) 16%, transparent);--shadow-accent-halo:0 0 0 3px oklch(from var(--color-primary) l c h / .16);--shadow-accent-ring:0 0 0 2px var(--color-surface), 0 0 0 4px oklch(from var(--color-primary) l c h / .18);--shadow-accent-ring-strong:0 0 0 2px var(--color-bg), 0 0 0 4px oklch(from var(--color-primary) l c h / .45);--shadow-accent-ring-solid:0 0 0 2px var(--color-primary), 0 0 0 4px oklch(from var(--color-primary) l c h / .2);--shadow-elevated-soft:0 10px 24px color-mix(in oklab, var(--color-surface-ink) 10%, transparent);--shadow-floating-soft:0 14px 34px oklch(0% 0 0/.18);--shadow-floating-hover:0 18px 40px oklch(0% 0 0/.2);--shadow-media-soft:0 16px 40px oklch(0% 0 0/.24);--shadow-media-stage:0 28px 80px oklch(0% 0 0/.28);--shadow-media-modal:0 16px 48px #0009;--shadow-card-strong:0 20px 56px oklch(0% 0 0/.24);--shadow-sheet-inset:inset 0 1px 0 color-mix(in oklab, var(--color-text) 4%, transparent);--shadow-focus:0 0 0 3px oklch(from var(--color-primary) l c h / .15);--shadow-focus-compact:0 0 0 2px oklch(from var(--color-primary) l c h / .45);--interactive-border:color-mix(in oklab, var(--color-primary) 32%, transparent);--interactive-surface:color-mix(in oklab, var(--color-primary) 18%, transparent);--color-text-on-dark:#fff;--shadow-sm:0 1px 2px oklch(0% 0 0/.25);--shadow-md:0 4px 12px oklch(0% 0 0/.35);--shadow-lg:0 12px 32px oklch(0% 0 0/.5)}}.preview-content h1{margin:var(--space-8) 0 var(--space-4);padding-bottom:var(--space-2);border-bottom:1px solid var(--color-divider);font-size:var(--text-xl);letter-spacing:-.02em;font-weight:700}.preview-content h1:first-child,.preview-content .frontmatter-block+h1{margin-top:0}.preview-content h2{margin:var(--space-6) 0 var(--space-3);font-size:var(--text-lg);letter-spacing:-.01em;font-weight:600}.preview-content h3{margin:var(--space-5) 0 var(--space-2);font-size:var(--text-base);font-weight:600}.preview-content h4,.preview-content h5,.preview-content h6{margin:var(--space-4) 0 var(--space-2);color:var(--color-text-muted);font-size:var(--text-sm);font-weight:600}.preview-content p{max-width:72ch;margin-bottom:var(--space-4)}.preview-content .frontmatter-block{max-width:72ch;margin:0 0 var(--space-5);padding:var(--space-4);border:1px solid var(--color-border);border-radius:var(--radius-lg);background:color-mix(in oklab, var(--color-surface-offset) 72%, var(--color-surface))}.preview-content .frontmatter-label{color:var(--color-text-muted);font-size:var(--text-ui-sm);letter-spacing:.04em;text-transform:uppercase;font-weight:600}.preview-content .frontmatter-block>.frontmatter-label{margin-bottom:var(--space-3);display:block}.preview-content .frontmatter-header{justify-content:space-between;align-items:center;gap:var(--space-3);margin-bottom:var(--space-3);display:flex}.preview-content .frontmatter-toggle{min-height:30px;padding:0 var(--space-3);border:1px solid var(--color-border);background:var(--color-surface);color:var(--color-text);font:inherit;font-size:var(--text-ui-sm);cursor:pointer;border-radius:999px;flex-shrink:0}.preview-content .frontmatter-toggle:hover{background:var(--color-surface-offset)}.preview-content .frontmatter-toggle:focus-visible{outline:2px solid var(--color-primary);outline-offset:2px}.preview-content .frontmatter-summary{margin-bottom:var(--space-1);color:var(--color-text-muted);font-size:var(--text-ui-sm)}.preview-content .frontmatter-properties{gap:var(--space-3);margin:0;display:grid}.preview-content .frontmatter-property{gap:var(--space-3);grid-template-columns:minmax(0,160px) minmax(0,1fr);align-items:start;display:grid}.preview-content .frontmatter-key{color:var(--color-text-muted);font-size:var(--text-ui-sm);margin:0;font-weight:600}.preview-content .frontmatter-value{min-width:0;margin:0}.preview-content .frontmatter-value-text{color:var(--color-text);overflow-wrap:anywhere;display:inline-block}.preview-content .frontmatter-value-list{gap:var(--space-2);flex-wrap:wrap;display:flex}.preview-content .frontmatter-value-pill{min-height:28px;padding:0 var(--space-3);border:1px solid var(--color-border);background:var(--color-surface);color:var(--color-text);font-size:var(--text-ui-sm);border-radius:999px;align-items:center;display:inline-flex}.preview-content .frontmatter-value-code{border-radius:var(--radius-md);margin:0}.preview-content .frontmatter-value-code code{white-space:pre-wrap;word-break:break-word}.preview-content .frontmatter-empty{color:var(--color-text-muted);font-size:var(--text-ui-sm)}:is(.preview-content p:has(>.excalidraw-embed-placeholder:only-child),.preview-content p:has(>.bases-embed-placeholder:only-child),.preview-content p:has(>.video-embed-placeholder:only-child),.preview-content p:has(>.plantuml-shell:only-child)){max-width:none;margin-bottom:0}.preview-content .bases-shell{width:100%;margin:0 0 var(--space-5);border:1px solid var(--color-border);border-radius:var(--radius-lg);background:color-mix(in oklab, var(--color-surface-offset) 65%, var(--color-surface));overflow:hidden}.preview-content .bases-toolbar{justify-content:space-between;align-items:center;gap:var(--space-3);padding:var(--space-4);border-bottom:1px solid var(--color-divider);flex-wrap:wrap;display:flex}.preview-content .bases-toolbar-main,.preview-content .bases-toolbar-actions,.preview-content .bases-tabs,.preview-content .bases-summaries,.preview-content .bases-value-list{gap:var(--space-2);flex-wrap:wrap;align-items:center;display:flex}.preview-content .bases-view-tab,.preview-content .bases-export-btn,.preview-content .bases-link-button{border:1px solid var(--color-border);background:var(--color-surface);color:var(--color-text);cursor:pointer;font:inherit;border-radius:999px}.preview-content .bases-view-tab,.preview-content .bases-export-btn{min-height:34px;padding:0 var(--space-3)}.preview-content .bases-view-tab.is-active{background:var(--color-primary);border-color:var(--color-primary);color:var(--color-primary-contrast)}.preview-content .bases-search-input{min-width:200px;min-height:34px;padding:0 var(--space-3);border:1px solid var(--color-border);background:var(--color-surface);color:var(--color-text);font:inherit;border-radius:999px}.preview-content .bases-meta,.preview-content .bases-summary-label,.preview-content .bases-card-label{color:var(--color-text-muted);font-size:var(--text-ui-sm)}.preview-content .bases-summaries{padding:var(--space-3) var(--space-4);border-bottom:1px solid var(--color-divider)}.preview-content .bases-summary{align-items:center;gap:var(--space-2);min-height:28px;padding:0 var(--space-3);background:var(--color-surface);border-radius:999px;display:inline-flex}.preview-content .bases-content{padding:var(--space-4)}.preview-content .bases-group+.bases-group{margin-top:var(--space-5)}.preview-content .bases-group-header{justify-content:space-between;align-items:center;gap:var(--space-2);margin-bottom:var(--space-3);flex-wrap:wrap;display:flex}.preview-content .bases-group-header h3{margin:0}.preview-content .bases-table-shell{overflow-x:auto}.preview-content .bases-table{border-collapse:collapse;width:100%}.preview-content .bases-table th,.preview-content .bases-table td{padding:var(--space-2) var(--space-3);border-bottom:1px solid var(--color-divider);text-align:left;vertical-align:top}.preview-content .bases-list,.preview-content .bases-cards{max-width:none;margin:0;padding:0}.preview-content .bases-list{list-style:none}.preview-content .bases-list-item{gap:var(--space-3);padding:var(--space-3) 0;border-bottom:1px solid var(--color-divider);flex-wrap:wrap;display:flex}.preview-content .bases-cards{gap:var(--space-3);grid-template-columns:repeat(auto-fit,minmax(220px,1fr));display:grid}.preview-content .bases-card{border:1px solid var(--color-border);border-radius:var(--radius-lg);background:var(--color-surface);overflow:hidden}.preview-content .bases-card-media{object-fit:cover;background:color-mix(in oklab, var(--color-surface-offset) 50%, var(--color-surface));width:100%;height:140px;display:block}.preview-content .bases-card-media-color{background:var(--bases-card-swatch)}.preview-content .bases-card-body{padding:var(--space-3)}.preview-content .bases-card-field+.bases-card-field{margin-top:var(--space-3)}.preview-content .bases-link-button{color:var(--color-primary);background:0 0;border:0;padding:0}.preview-content .bases-value-pill{min-height:26px;padding:0 var(--space-3);border:1px solid var(--color-border);background:var(--color-surface);font-size:var(--text-ui-sm);border-radius:999px;align-items:center;display:inline-flex}.preview-content .bases-inline-image{border-radius:var(--radius-md);max-width:120px;max-height:80px;display:block}.preview-content .bases-unsupported{padding:var(--space-4);border:1px dashed var(--color-border);border-radius:var(--radius-lg);color:var(--color-text-muted)}.preview-content a{color:var(--color-primary);border-bottom:1px solid oklch(from var(--color-primary) l c h / .3);transition:border-color var(--transition-interactive);text-decoration:none}.preview-content a:hover{border-bottom-color:var(--color-primary)}.preview-content strong{font-weight:600}.preview-content em{font-style:italic}.preview-content del{color:var(--color-text-muted);text-decoration:line-through}.preview-content ul,.preview-content ol{margin-bottom:var(--space-4);padding-left:var(--space-6)}.preview-content li{margin-bottom:var(--space-1)}.preview-content li>ul,.preview-content li>ol{margin-top:var(--space-1);margin-bottom:0}.preview-content .task-list-item{list-style:none;position:relative}.preview-content .task-list-item input[type=checkbox]{top:.3em;left:calc(var(--space-5) * -1);accent-color:var(--color-primary);cursor:pointer;vertical-align:top;margin:0;position:absolute}.preview-content blockquote{margin:var(--space-4) 0;padding:var(--space-3) var(--space-5);border-left:3px solid var(--color-primary);border-radius:0 var(--radius-md) var(--radius-md) 0;background:var(--color-surface);color:var(--color-text-muted)}.preview-content blockquote p:last-child{margin-bottom:0}.preview-content code{border-radius:var(--radius-sm);background:var(--color-surface-offset);color:var(--color-primary);font-family:var(--font-mono);padding:2px 6px;font-size:.875em}.preview-content pre{max-width:100%;margin:var(--space-4) 0;border:1px solid var(--color-border);border-radius:var(--radius-lg);background:var(--color-surface);-webkit-overflow-scrolling:touch;overflow-x:auto}.preview-content pre code{width:fit-content;min-width:100%;padding:var(--space-4);color:var(--color-text);font-size:var(--text-ui-sm);white-space:pre;word-wrap:normal;overflow-wrap:normal;background:0 0;line-height:1.6;display:block}.preview-content .table-wrapper{margin:var(--space-4) 0;border:1px solid var(--color-border);border-radius:var(--radius-md);-webkit-overflow-scrolling:touch;overflow-x:auto}.preview-content table{border-collapse:collapse;white-space:nowrap;width:100%;min-width:100%}.preview-content th,.preview-content td{padding:var(--space-2) var(--space-3);border-bottom:1px solid var(--color-divider);text-align:left;font-size:var(--text-sm)}.preview-content th{background:var(--color-surface-offset);color:var(--color-text-muted);font-size:var(--text-xs);letter-spacing:.03em;text-transform:uppercase;font-weight:600}.preview-content tr:last-child td{border-bottom:none}.preview-content tr:hover td{background:var(--color-surface-offset)}.preview-content hr{height:1px;margin:var(--space-8) 0;background:var(--color-divider);border:none}.preview-content img{max-width:100%;height:auto;margin:var(--space-4) 0;border-radius:var(--radius-md);cursor:zoom-in}@media (width<=768px){.preview-content .frontmatter-header{flex-direction:column;align-items:flex-start}.preview-content .frontmatter-property{gap:var(--space-1);grid-template-columns:1fr}}[data-theme=light] .preview-content pre,[data-theme=light] .preview-content pre code,[data-theme=light] .hljs{background:var(--color-surface)!important}html[data-surface=export-document]{overscroll-behavior:auto;height:auto;min-height:100%;overflow:hidden auto}body[data-surface=export-document]{overscroll-behavior:auto;background:var(--color-bg);height:auto;color:var(--color-text);overflow:hidden auto}.export-page-shell{width:min(960px,100vw - 48px);margin:0 auto;padding:32px 0 72px}.export-page-header{justify-content:space-between;align-items:flex-start;margin-bottom:20px;display:flex}.export-page-header h1{margin-bottom:6px;font-size:28px}.export-page-header p{color:var(--color-text-muted);max-width:none}.export-warnings-panel{border:1px solid var(--border-warning-toast);background:var(--surface-warning-toast);color:var(--text-warning-toast);border-radius:12px;margin-bottom:20px;padding:14px 16px}.export-warnings-panel h2{margin-bottom:6px;font-size:14px}.export-warnings-panel ul{padding-left:20px}.export-content{border:1px solid var(--color-divider);background:var(--color-surface);box-shadow:var(--shadow-card-strong);border-radius:20px;padding:32px 40px}.export-content p,.export-content li,.export-content blockquote{max-width:none}.export-content .task-list-item input[type=checkbox]{cursor:default}.export-content .table-wrapper{overflow:visible}.export-content table{white-space:normal}.export-diagram{justify-content:center;margin:18px 0 22px;display:flex}.export-diagram-surface,.export-diagram-image{border:1px solid var(--color-divider);background:var(--color-surface);border-radius:14px;max-width:100%;margin:0}.export-diagram-surface{display:inline-block;overflow:hidden}.export-diagram-image,.export-diagram-svg{width:auto;max-width:100%;height:auto;display:block}.export-video-poster{margin:18px 0 22px}.export-video-poster-card{border:1px solid var(--color-divider);background:var(--surface-fill-subtle);border-radius:14px;padding:16px 18px;overflow:hidden}.export-video-poster-media{border-bottom:1px solid var(--color-divider);background:var(--color-surface-offset);margin:-16px -18px 14px;position:relative;overflow:hidden}.export-video-poster-image{object-fit:cover;width:100%;height:auto;max-height:360px;display:block}.export-video-play-badge{background:oklch(from var(--color-surface) l c h / .86);min-width:72px;color:var(--color-text);text-align:center;box-shadow:var(--shadow-lg);border-radius:999px;padding:8px 14px;font-size:14px;font-weight:700;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.export-video-poster-copy{flex-direction:column;gap:4px;display:flex}.export-video-poster-meta{color:var(--color-text-muted);margin-top:4px;font-size:13px;display:block}.export-video-link{word-break:break-word;margin-top:8px;display:inline-block}.export-warning{border:1px solid var(--border-warning-toast);background:var(--surface-warning-toast);color:var(--text-warning-toast);border-radius:12px;padding:12px 14px}.drawio-export-iframe{opacity:0;pointer-events:none;border:0;width:0;height:0;position:absolute}@media print{body[data-surface=export-document]{background:var(--color-surface)}.export-page-shell{width:auto;margin:0;padding:0}.export-page-header,.export-warnings-panel{display:none}.export-content{width:auto;box-shadow:none;border:0;border-radius:0;padding:0}.export-content h1,.export-content h2,.export-content h3,.export-content h4,.export-content h5,.export-content h6{break-after:avoid-page;page-break-after:avoid}.export-content h1+*,.export-content h2+*,.export-content h3+*,.export-content h4+*,.export-content h5+*,.export-content h6+*{break-before:avoid-page;page-break-before:avoid}.export-content pre,.export-content blockquote,.export-content table,.export-content figure,.export-content img{break-inside:avoid}.export-content .export-keep-with-next{break-inside:avoid-page;page-break-inside:avoid}.export-content p,.export-content li,.export-content blockquote{orphans:3;widows:3}}