@eeshans/howiprompt 2.1.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.
- package/LICENSE +21 -0
- package/README.md +148 -0
- package/bin/bootstrap-db.mjs +166 -0
- package/bin/cli-helpers.mjs +86 -0
- package/bin/cli.mjs +205 -0
- package/config/ml.json +47 -0
- package/data/claude_code/.gitkeep +3 -0
- package/data/codex/.gitkeep +0 -0
- package/data/reference_clusters.json +314 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.js +194 -0
- package/dist/index.js.map +1 -0
- package/dist/pipeline/backends.d.ts +39 -0
- package/dist/pipeline/backends.js +411 -0
- package/dist/pipeline/backends.js.map +1 -0
- package/dist/pipeline/classifiers.d.ts +17 -0
- package/dist/pipeline/classifiers.js +181 -0
- package/dist/pipeline/classifiers.js.map +1 -0
- package/dist/pipeline/config.d.ts +21 -0
- package/dist/pipeline/config.js +79 -0
- package/dist/pipeline/config.js.map +1 -0
- package/dist/pipeline/db.d.ts +41 -0
- package/dist/pipeline/db.js +130 -0
- package/dist/pipeline/db.js.map +1 -0
- package/dist/pipeline/embeddings.d.ts +15 -0
- package/dist/pipeline/embeddings.js +82 -0
- package/dist/pipeline/embeddings.js.map +1 -0
- package/dist/pipeline/exclusions.d.ts +86 -0
- package/dist/pipeline/exclusions.js +320 -0
- package/dist/pipeline/exclusions.js.map +1 -0
- package/dist/pipeline/metrics.d.ts +12 -0
- package/dist/pipeline/metrics.js +278 -0
- package/dist/pipeline/metrics.js.map +1 -0
- package/dist/pipeline/ml-config.d.ts +23 -0
- package/dist/pipeline/ml-config.js +54 -0
- package/dist/pipeline/ml-config.js.map +1 -0
- package/dist/pipeline/models.d.ts +23 -0
- package/dist/pipeline/models.js +21 -0
- package/dist/pipeline/models.js.map +1 -0
- package/dist/pipeline/nlp.d.ts +20 -0
- package/dist/pipeline/nlp.js +200 -0
- package/dist/pipeline/nlp.js.map +1 -0
- package/dist/pipeline/parsers.d.ts +11 -0
- package/dist/pipeline/parsers.js +492 -0
- package/dist/pipeline/parsers.js.map +1 -0
- package/dist/pipeline/registry.d.ts +21 -0
- package/dist/pipeline/registry.js +45 -0
- package/dist/pipeline/registry.js.map +1 -0
- package/dist/pipeline/style.d.ts +37 -0
- package/dist/pipeline/style.js +204 -0
- package/dist/pipeline/style.js.map +1 -0
- package/dist/pipeline/sync.d.ts +8 -0
- package/dist/pipeline/sync.js +52 -0
- package/dist/pipeline/sync.js.map +1 -0
- package/dist/pipeline/trends.d.ts +8 -0
- package/dist/pipeline/trends.js +226 -0
- package/dist/pipeline/trends.js.map +1 -0
- package/dist/server.d.ts +7 -0
- package/dist/server.js +216 -0
- package/dist/server.js.map +1 -0
- package/frontend/dist/_astro/MethodologyModal.astro_astro_type_script_index_0_lang.jiHwSrn-.js +34 -0
- package/frontend/dist/_astro/index.Ck1ZXjve.css +1 -0
- package/frontend/dist/_astro/index.astro_astro_type_script_index_0_lang.PuBlxVje.js +37 -0
- package/frontend/dist/_astro/index.astro_astro_type_script_index_1_lang.DmQY6kFx.js +1 -0
- package/frontend/dist/_astro/theme.CbYAaQI4.js +1 -0
- package/frontend/dist/_astro/wrapped.CpzRcLjf.css +1 -0
- package/frontend/dist/_astro/wrapped.astro_astro_type_script_index_0_lang.D4GeWu2-.js +11 -0
- package/frontend/dist/_astro/wrapped.astro_astro_type_script_index_1_lang.CPAAJDh5.js +1 -0
- package/frontend/dist/favicon.svg +4 -0
- package/frontend/dist/images/card_architect.png +0 -0
- package/frontend/dist/images/card_commander.png +0 -0
- package/frontend/dist/images/card_delegator.png +0 -0
- package/frontend/dist/images/card_explorer.png +0 -0
- package/frontend/dist/images/card_partner.png +0 -0
- package/frontend/dist/images/char_architect.png +0 -0
- package/frontend/dist/images/char_commander.png +0 -0
- package/frontend/dist/images/char_delegator.png +0 -0
- package/frontend/dist/images/char_explorer.png +0 -0
- package/frontend/dist/images/char_partner.png +0 -0
- package/frontend/dist/index.html +9 -0
- package/frontend/dist/wrapped/index.html +9 -0
- package/package.json +66 -0
package/dist/server.js
ADDED
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
import http from "node:http";
|
|
2
|
+
import fs from "node:fs";
|
|
3
|
+
import path from "node:path";
|
|
4
|
+
import os from "node:os";
|
|
5
|
+
import { execSync } from "node:child_process";
|
|
6
|
+
import { fileURLToPath } from "node:url";
|
|
7
|
+
export async function startServer(opts) {
|
|
8
|
+
// Resolve frontend dist path — try multiple locations
|
|
9
|
+
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
10
|
+
const candidates = [
|
|
11
|
+
path.join(__dirname, "..", "frontend", "dist"), // dev: from dist/server.js
|
|
12
|
+
path.join(__dirname, "..", "..", "frontend", "dist"), // npx: from dist/server.js in package
|
|
13
|
+
];
|
|
14
|
+
let frontendDir = candidates.find((p) => fs.existsSync(p)) ?? candidates[0];
|
|
15
|
+
const metricsPath = path.join(opts.dataDir, "metrics.json");
|
|
16
|
+
let pipelineRunning = false;
|
|
17
|
+
const mimeTypes = {
|
|
18
|
+
".html": "text/html",
|
|
19
|
+
".js": "application/javascript",
|
|
20
|
+
".css": "text/css",
|
|
21
|
+
".json": "application/json",
|
|
22
|
+
".png": "image/png",
|
|
23
|
+
".svg": "image/svg+xml",
|
|
24
|
+
".ico": "image/x-icon",
|
|
25
|
+
};
|
|
26
|
+
const server = http.createServer(async (req, res) => {
|
|
27
|
+
const url = new URL(req.url ?? "/", `http://localhost:${opts.port}`);
|
|
28
|
+
// CORS headers
|
|
29
|
+
res.setHeader("Access-Control-Allow-Origin", "*");
|
|
30
|
+
res.setHeader("Access-Control-Allow-Methods", "GET, POST, PUT, OPTIONS");
|
|
31
|
+
res.setHeader("Access-Control-Allow-Headers", "Content-Type");
|
|
32
|
+
if (req.method === "OPTIONS") {
|
|
33
|
+
res.writeHead(204);
|
|
34
|
+
res.end();
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
// API: health check
|
|
38
|
+
if (url.pathname === "/api/health") {
|
|
39
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
40
|
+
res.end(JSON.stringify({ status: "ok" }));
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
// API: pick directory (native macOS folder picker)
|
|
44
|
+
if (req.method === "GET" && url.pathname === "/api/pick-directory") {
|
|
45
|
+
try {
|
|
46
|
+
const result = execSync(`osascript -e 'tell application "Finder" to activate' -e 'return POSIX path of (choose folder with prompt "Select directory to exclude")'`, { timeout: 60000 }).toString().trim();
|
|
47
|
+
// Remove trailing slash
|
|
48
|
+
const dirPath = result.replace(/\/$/, "");
|
|
49
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
50
|
+
res.end(JSON.stringify({ path: dirPath }));
|
|
51
|
+
}
|
|
52
|
+
catch {
|
|
53
|
+
// User cancelled or osascript failed
|
|
54
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
55
|
+
res.end(JSON.stringify({ path: null }));
|
|
56
|
+
}
|
|
57
|
+
return;
|
|
58
|
+
}
|
|
59
|
+
// API: count messages that would be excluded for a given path
|
|
60
|
+
if (req.method === "POST" && url.pathname === "/api/exclusion-count") {
|
|
61
|
+
let body = "";
|
|
62
|
+
for await (const chunk of req)
|
|
63
|
+
body += chunk;
|
|
64
|
+
const { path: dirPath } = JSON.parse(body);
|
|
65
|
+
// Convert to Claude's directory format: /path/to/project -> -path-to-project
|
|
66
|
+
const claudeDir = dirPath.replace(/\//g, "-");
|
|
67
|
+
const projectsDir = path.join(os.homedir(), ".claude", "projects");
|
|
68
|
+
const targetDir = path.join(projectsDir, claudeDir);
|
|
69
|
+
let messageCount = 0;
|
|
70
|
+
if (fs.existsSync(targetDir)) {
|
|
71
|
+
// Count lines in all JSONL files under this directory
|
|
72
|
+
const countLines = (dir) => {
|
|
73
|
+
let total = 0;
|
|
74
|
+
try {
|
|
75
|
+
for (const entry of fs.readdirSync(dir, { withFileTypes: true })) {
|
|
76
|
+
const full = path.join(dir, entry.name);
|
|
77
|
+
if (entry.isDirectory())
|
|
78
|
+
total += countLines(full);
|
|
79
|
+
else if (entry.name.endsWith(".jsonl")) {
|
|
80
|
+
total += fs.readFileSync(full, "utf-8").split("\n").filter(Boolean).length;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
catch { /* skip */ }
|
|
85
|
+
return total;
|
|
86
|
+
};
|
|
87
|
+
messageCount = Math.round(countLines(targetDir) / 2); // rough human-only count
|
|
88
|
+
}
|
|
89
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
90
|
+
res.end(JSON.stringify({ messageCount, claudeDir }));
|
|
91
|
+
return;
|
|
92
|
+
}
|
|
93
|
+
// API: reset (delete metrics.json + reset setup flag)
|
|
94
|
+
if (req.method === "POST" && url.pathname === "/api/reset") {
|
|
95
|
+
if (fs.existsSync(metricsPath))
|
|
96
|
+
fs.unlinkSync(metricsPath);
|
|
97
|
+
const { saveConfig } = await import("./pipeline/config.js");
|
|
98
|
+
saveConfig(opts.dataDir, { hasCompletedSetup: false });
|
|
99
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
100
|
+
res.end(JSON.stringify({ ok: true }));
|
|
101
|
+
return;
|
|
102
|
+
}
|
|
103
|
+
// API: detect backends
|
|
104
|
+
if (req.method === "GET" && url.pathname === "/api/detect") {
|
|
105
|
+
const { detectAll } = await import("./pipeline/backends.js");
|
|
106
|
+
const backends = detectAll();
|
|
107
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
108
|
+
res.end(JSON.stringify({ backends }));
|
|
109
|
+
return;
|
|
110
|
+
}
|
|
111
|
+
// API: config
|
|
112
|
+
if (url.pathname === "/api/config") {
|
|
113
|
+
if (req.method === "GET") {
|
|
114
|
+
const { loadConfig } = await import("./pipeline/config.js");
|
|
115
|
+
const config = loadConfig(opts.dataDir);
|
|
116
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
117
|
+
res.end(JSON.stringify(config));
|
|
118
|
+
return;
|
|
119
|
+
}
|
|
120
|
+
if (req.method === "PUT") {
|
|
121
|
+
let body = "";
|
|
122
|
+
for await (const chunk of req)
|
|
123
|
+
body += chunk;
|
|
124
|
+
const updates = JSON.parse(body);
|
|
125
|
+
const { saveConfig } = await import("./pipeline/config.js");
|
|
126
|
+
saveConfig(opts.dataDir, updates);
|
|
127
|
+
res.writeHead(200, { "Content-Type": "application/json" });
|
|
128
|
+
res.end(JSON.stringify({ ok: true }));
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
// API: pipeline stream (SSE)
|
|
133
|
+
if (req.method === "GET" && url.pathname === "/api/pipeline/stream") {
|
|
134
|
+
if (pipelineRunning) {
|
|
135
|
+
res.writeHead(409, { "Content-Type": "application/json" });
|
|
136
|
+
res.end(JSON.stringify({ error: "Pipeline already running" }));
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
pipelineRunning = true;
|
|
140
|
+
let clientDisconnected = false;
|
|
141
|
+
req.on("close", () => { clientDisconnected = true; });
|
|
142
|
+
res.writeHead(200, {
|
|
143
|
+
"Content-Type": "text/event-stream",
|
|
144
|
+
"Cache-Control": "no-cache",
|
|
145
|
+
"Connection": "keep-alive",
|
|
146
|
+
});
|
|
147
|
+
function emit(type, data) {
|
|
148
|
+
if (clientDisconnected)
|
|
149
|
+
return;
|
|
150
|
+
res.write(`event: ${type}\ndata: ${JSON.stringify(data)}\n\n`);
|
|
151
|
+
}
|
|
152
|
+
try {
|
|
153
|
+
emit("progress", { stage: "boot", detail: "Preparing analysis session...", progress: 5 });
|
|
154
|
+
const { runPipeline } = await import("./index.js");
|
|
155
|
+
const stats = await runPipeline({
|
|
156
|
+
dbPath: opts.dbPath,
|
|
157
|
+
dataDir: opts.dataDir,
|
|
158
|
+
onProgress: (progress) => {
|
|
159
|
+
emit("progress", progress);
|
|
160
|
+
},
|
|
161
|
+
});
|
|
162
|
+
const metrics = fs.existsSync(metricsPath)
|
|
163
|
+
? JSON.parse(fs.readFileSync(metricsPath, "utf-8"))
|
|
164
|
+
: null;
|
|
165
|
+
emit("complete", { stats, metrics });
|
|
166
|
+
}
|
|
167
|
+
catch (err) {
|
|
168
|
+
emit("pipeline_error", { message: err.message });
|
|
169
|
+
}
|
|
170
|
+
finally {
|
|
171
|
+
pipelineRunning = false;
|
|
172
|
+
res.end();
|
|
173
|
+
}
|
|
174
|
+
return;
|
|
175
|
+
}
|
|
176
|
+
// Serve metrics.json from data dir (no-cache to avoid stale data after reset)
|
|
177
|
+
if (url.pathname === "/metrics.json" || url.pathname === "/wrapped/metrics.json") {
|
|
178
|
+
if (fs.existsSync(metricsPath)) {
|
|
179
|
+
res.writeHead(200, { "Content-Type": "application/json", "Cache-Control": "no-store" });
|
|
180
|
+
res.end(fs.readFileSync(metricsPath));
|
|
181
|
+
}
|
|
182
|
+
else {
|
|
183
|
+
res.writeHead(404);
|
|
184
|
+
res.end("metrics.json not found");
|
|
185
|
+
}
|
|
186
|
+
return;
|
|
187
|
+
}
|
|
188
|
+
// Serve static files from frontend/dist
|
|
189
|
+
let filePath = path.join(frontendDir, url.pathname);
|
|
190
|
+
// Directory → index.html
|
|
191
|
+
if (url.pathname.endsWith("/")) {
|
|
192
|
+
filePath = path.join(filePath, "index.html");
|
|
193
|
+
}
|
|
194
|
+
// No extension → try adding /index.html (for /wrapped → /wrapped/index.html)
|
|
195
|
+
if (!path.extname(filePath)) {
|
|
196
|
+
const indexPath = path.join(filePath, "index.html");
|
|
197
|
+
if (fs.existsSync(indexPath)) {
|
|
198
|
+
filePath = indexPath;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
if (fs.existsSync(filePath) && fs.statSync(filePath).isFile()) {
|
|
202
|
+
const ext = path.extname(filePath);
|
|
203
|
+
const mime = mimeTypes[ext] ?? "application/octet-stream";
|
|
204
|
+
res.writeHead(200, { "Content-Type": mime });
|
|
205
|
+
fs.createReadStream(filePath).pipe(res);
|
|
206
|
+
}
|
|
207
|
+
else {
|
|
208
|
+
res.writeHead(404);
|
|
209
|
+
res.end("Not found");
|
|
210
|
+
}
|
|
211
|
+
});
|
|
212
|
+
return new Promise((resolve) => {
|
|
213
|
+
server.listen(opts.port, "127.0.0.1", () => resolve(server));
|
|
214
|
+
});
|
|
215
|
+
}
|
|
216
|
+
//# sourceMappingURL=server.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"server.js","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAQzC,MAAM,CAAC,KAAK,UAAU,WAAW,CAAC,IAAmB;IACnD,sDAAsD;IACtD,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;IAC/D,MAAM,UAAU,GAAG;QACjB,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,CAAC,EAAI,2BAA2B;QAC7E,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,sCAAsC;KAC7F,CAAC;IACF,IAAI,WAAW,GAAG,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,IAAI,UAAU,CAAC,CAAC,CAAC,CAAC;IAE5E,MAAM,WAAW,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC;IAC5D,IAAI,eAAe,GAAG,KAAK,CAAC;IAE5B,MAAM,SAAS,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GAAG,SAAS,CAAC;YACvB,CAAC;QACH,CAAC;QAED,IAAI,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,IAAI,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC;YAC9D,MAAM,GAAG,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;YACnC,MAAM,IAAI,GAAG,SAAS,CAAC,GAAG,CAAC,IAAI,0BAA0B,CAAC;YAC1D,GAAG,CAAC,SAAS,CAAC,GAAG,EAAE,EAAE,cAAc,EAAE,IAAI,EAAE,CAAC,CAAC;YAC7C,EAAE,CAAC,gBAAgB,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAC1C,CAAC;aAAM,CAAC;YACN,GAAG,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;YACnB,GAAG,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;QACvB,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;QAC7B,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC;IAC/D,CAAC,CAAC,CAAC;AACL,CAAC"}
|
package/frontend/dist/_astro/MethodologyModal.astro_astro_type_script_index_0_lang.jiHwSrn-.js
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
(function(){const c="/images/",v=[{key:"commander",img:c+"char_commander.png",name:"The Commander",badge:"Brief + Directive",trait:"Direct, efficient, decisive",accent:"#41608e",accentDark:"#7da4d4",gradient:"linear-gradient(160deg,#d4dde8,#c2cedd)",gradientDark:"linear-gradient(160deg,#222830,#1a2028)",desc:"You give precise orders in short bursts. No wasted words, no hand-holding — you know exactly what you want and expect the AI to deliver it on the first try.",prompt:"“Patch this regression, keep the API stable, and show me the exact files changed.”",liner:"You prefer decisive progress over collaborative wandering.",axes:{"Detail Level":30,"Communication Style":25}},{key:"partner",img:c+"char_partner.png",name:"The Partner",badge:"Brief + Collaborative",trait:"Conversational, collaborative, adaptive",accent:"#8a5d73",accentDark:"#c48aa8",gradient:"linear-gradient(160deg,#e8d8e0,#ddc8d4)",gradientDark:"linear-gradient(160deg,#2e2428,#261c22)",desc:"You keep it short but keep it human. Quick exchanges, polite nudges, and a conversational flow that treats AI as a co-pilot, not a tool.",prompt:"“Better, but not there yet. Keep the tone, reduce complexity, and give me a second version with a stronger opening.”",liner:"You keep pushing until the output finally clicks.",axes:{"Detail Level":30,"Communication Style":75}},{key:"architect",img:c+"char_architect.png",name:"The Architect",badge:"Detailed + Directive",trait:"Precise, methodical, thorough",accent:"#7b5a42",accentDark:"#c4a07a",gradient:"linear-gradient(160deg,#e8ddd2,#ddd0c2)",gradientDark:"linear-gradient(160deg,#342c24,#2a2218)",desc:"You write specs, not prompts. Every request comes with constraints, file paths, and numbered requirements. You leave nothing to chance.",prompt:"“Use the existing component API. Keep the interaction model unchanged. Add keyboard support, tests, and a migration note.”",liner:"You like the model to be powerful, but not unsupervised.",axes:{"Detail Level":80,"Communication Style":25}},{key:"explorer",img:c+"char_explorer.png",name:"The Explorer",badge:"Detailed + Collaborative",trait:"Curious, analytical, open-minded",accent:"#3f7a6e",accentDark:"#6abfae",gradient:"linear-gradient(160deg,#d4e8e3,#c2ddd6)",gradientDark:"linear-gradient(160deg,#222e2b,#1a2624)",desc:"You bring context and ask questions. Every conversation is an investigation — you explain what you’re thinking, ask for alternatives, and dig into the details together.",prompt:"“Compare these three approaches, surface tradeoffs, and tell me what an experienced engineer would worry about.”",liner:"You use the model as an idea space, not just a task runner.",axes:{"Detail Level":80,"Communication Style":75}}],y=()=>document.documentElement.classList.contains("dark");let l="commander";const m=document.getElementById("methPersonaList"),s=document.getElementById("methPersonaDetail");if(!m||!s)return;function h(){m.innerHTML=v.map(e=>`
|
|
2
|
+
<button class="meth-p-thumb ${e.key===l?"active":""}" data-pkey="${e.key}"
|
|
3
|
+
style="--pa:${y()?e.accentDark:e.accent}">
|
|
4
|
+
<div class="meth-p-thumb-img"><img src="${e.img}" alt="${e.name}"/></div>
|
|
5
|
+
<div class="meth-p-thumb-text">
|
|
6
|
+
<div class="meth-p-thumb-name">${e.name.replace("The ","")}</div>
|
|
7
|
+
<div class="meth-p-thumb-trait">${e.trait}</div>
|
|
8
|
+
</div>
|
|
9
|
+
</button>`).join("")}function g(e,a){const t=v.find(o=>o.key===e);if(!t)return;const n=y()?t.accentDark:t.accent;s.style.setProperty("--pa",n),s.style.setProperty("--pd-gradient",t.gradient),s.style.setProperty("--pd-gradient-dark",t.gradientDark),s.innerHTML=`
|
|
10
|
+
<div class="meth-pd-art">
|
|
11
|
+
<img src="${t.img}" alt="${t.name}" style="opacity:0;transform:scale(.9)"/>
|
|
12
|
+
</div>
|
|
13
|
+
<div class="meth-pd-copy">
|
|
14
|
+
<div class="meth-pd-badge" style="color:${n}">${t.badge}</div>
|
|
15
|
+
<div class="meth-pd-name">${t.name}</div>
|
|
16
|
+
<p class="meth-pd-desc">${t.desc}</p>
|
|
17
|
+
<div class="meth-pd-cards">
|
|
18
|
+
<div class="meth-pd-card">
|
|
19
|
+
<div class="meth-pd-card-label">Signature prompt</div>
|
|
20
|
+
<div class="meth-pd-card-text">${t.prompt}</div>
|
|
21
|
+
</div>
|
|
22
|
+
<div class="meth-pd-card">
|
|
23
|
+
<div class="meth-pd-card-label">In a nutshell</div>
|
|
24
|
+
<div class="meth-pd-card-text">${t.liner}</div>
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
27
|
+
<div class="meth-pd-axes">
|
|
28
|
+
${Object.entries(t.axes).map(([o,u])=>`
|
|
29
|
+
<div class="meth-ax">
|
|
30
|
+
<div class="meth-ax-label"><span>${o}</span><span>${u}</span></div>
|
|
31
|
+
<div class="meth-ax-track"><div class="meth-ax-fill" style="width:0%;background:${n}"></div></div>
|
|
32
|
+
</div>`).join("")}
|
|
33
|
+
</div>
|
|
34
|
+
</div>`,requestAnimationFrame(()=>{const o=s.querySelector(".meth-pd-art img");o&&(o.style.opacity="1",o.style.transform="scale(1)"),s.querySelectorAll(".meth-ax-fill").forEach((u,x)=>{const E=Object.values(t.axes)[x];setTimeout(()=>u.style.width=E+"%",50+x*60)})})}function w(e){l=e,h(),g(e)}m.addEventListener("click",e=>{const a=e.target.closest("[data-pkey]");a&&w(a.dataset.pkey)}),h(),g("commander"),new MutationObserver(()=>{h(),g(l)}).observe(document.documentElement,{attributes:!0,attributeFilter:["class"]});const i=document.getElementById("methScroll");if(!i)return;const b=new IntersectionObserver(e=>{e.forEach(a=>{a.isIntersecting&&a.target.classList.add("vis")})},{threshold:.1,root:i});i.querySelectorAll(".meth-reveal").forEach(e=>b.observe(e));const f=i.querySelectorAll("[data-meth-section]"),p=document.querySelectorAll(".meth-dot"),d=document.getElementById("methProgressFill");i.addEventListener("scroll",()=>{const e=i.scrollHeight-i.clientHeight;d&&(d.style.width=(e>0?i.scrollTop/e*100:0)+"%");let a=0;const t=i.getBoundingClientRect();f.forEach((r,n)=>{r.getBoundingClientRect().top-t.top<t.height*.5&&(a=n)}),p.forEach((r,n)=>r.classList.toggle("active",n===a))}),p.forEach(e=>e.addEventListener("click",()=>{const a=parseInt(e.dataset.methIdx);f[a]?.scrollIntoView({behavior:"smooth"})}));const k=document.getElementById("methodologyModal");k&&new MutationObserver(a=>{for(const t of a)t.target.classList.contains("active")&&(i.scrollTop=0,d&&(d.style.width="0%"),p.forEach((r,n)=>r.classList.toggle("active",n===0)),i.querySelectorAll(".meth-reveal").forEach(r=>r.classList.remove("vis")),setTimeout(()=>{i.querySelectorAll(".meth-reveal").forEach(r=>b.observe(r))},50))}).observe(k,{attributes:!0,attributeFilter:["class"]})})();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
/*! tailwindcss v4.2.2 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-border-style:solid;--tw-font-weight:initial;--tw-tracking:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial}}}@layer theme{:root,:host{--font-sans:"DM Sans", system-ui, -apple-system, sans-serif;--font-serif:"Fraunces", Georgia, serif;--font-mono:"JetBrains Mono", "SF Mono", Menlo, monospace;--spacing:.25rem;--container-md:28rem;--container-lg:32rem;--container-3xl:48rem;--container-4xl:56rem;--text-xs:.75rem;--text-xs--line-height:calc(1 / .75);--text-sm:.875rem;--text-sm--line-height:calc(1.25 / .875);--text-base:1rem;--text-base--line-height: 1.5 ;--text-lg:1.125rem;--text-lg--line-height:calc(1.75 / 1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75 / 1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2 / 1.5);--text-3xl:1.875rem;--text-3xl--line-height: 1.2 ;--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5 / 2.25);--text-5xl:3rem;--text-5xl--line-height:1;--text-6xl:3.75rem;--text-6xl--line-height:1;--text-7xl:4.5rem;--text-7xl--line-height:1;--text-8xl:6rem;--text-8xl--line-height:1;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--tracking-wider:.05em;--tracking-widest:.1em;--radius-sm:.25rem;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--color-bg:var(--bg);--color-text:var(--text);--color-muted:var(--muted);--color-border:var(--border);--grid-template-columns-24:repeat(24, minmax(0, 1fr))}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}*{box-sizing:border-box;margin:0;padding:0}html,body{height:100%}body{font-family:var(--font-sans);background:var(--bg);color:var(--text);-webkit-font-smoothing:antialiased;touch-action:manipulation}}@layer components{@keyframes fadeIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes spin{to{transform:rotate(360deg)}}@keyframes methBob{0%,to{transform:rotate(45deg)translate(0)}50%{transform:rotate(45deg)translate(2px,2px)}}.animate{animation:.4s forwards fadeIn}.delay-1{opacity:0;animation-delay:50ms}.delay-2{opacity:0;animation-delay:.1s}.delay-3{opacity:0;animation-delay:.15s}.delay-4{opacity:0;animation-delay:.2s}.delay-5{opacity:0;animation-delay:.25s}.refreshing .refresh-icon{animation:.8s linear infinite spin}.top-nav{z-index:50;background:var(--bg);position:sticky;top:0}.source-bar{border-bottom:1px solid var(--border);flex-wrap:wrap;flex-shrink:0;align-items:center;gap:6px;padding:8px 24px;display:flex}.source-pill{color:var(--muted);border:1px solid var(--border);cursor:pointer;white-space:nowrap;background:0 0;border-radius:999px;align-items:center;gap:6px;padding:6px 14px;font-family:inherit;font-size:13px;font-weight:500;transition:all .2s;display:inline-flex}.source-pill:hover{border-color:var(--text);color:var(--text)}.source-pill.active{background:var(--text);color:var(--bg);border-color:var(--text);font-weight:600}.source-pill-dot{border-radius:50%;flex-shrink:0;width:8px;height:8px}@media(max-width:640px){.source-bar{gap:4px;padding:6px 12px}.source-pill{padding:5px 10px;font-size:12px}}.card-dock{perspective:1200px}.player-card{transform-style:preserve-3d;will-change:transform;border:1px solid #0000000f;transition:transform .15s ease-out,box-shadow .2s ease-out;box-shadow:0 1px 2px #0000000a,0 4px 12px #0000000f,0 12px 32px #00000014,0 24px 60px #0000000f;container-type:inline-size}.dark .player-card{border-color:#ffffff0f;box-shadow:0 1px 2px #0003,0 4px 12px #0003,0 12px 32px #00000040,0 24px 60px #0003}.persona-name{text-shadow:0 2px 8px #0000004d;font-size:clamp(26px,6cqw,36px)}.donut-ring svg{transform:rotate(-90deg)}.donut-fill{transition:stroke-dashoffset .6s}.stat-block:not(:last-child):after{content:"";background:var(--border);width:1px;height:60%;position:absolute;top:20%;right:0}.trend-dot{transition:r .1s}.trend-tooltip:after{content:"";border:5px solid #0000;border-top-color:var(--text);position:absolute;top:100%;left:50%;transform:translate(-50%)}.heatmap-cell.l1{background:var(--heatmap-color,var(--accent));opacity:.2}.heatmap-cell.l2{background:var(--heatmap-color,var(--accent));opacity:.35}.heatmap-cell.l3{background:var(--heatmap-color,var(--accent));opacity:.55}.heatmap-cell.l4{background:var(--heatmap-color,var(--accent));opacity:.75}.heatmap-cell.l5{background:var(--heatmap-color,var(--accent));opacity:1}.heatmap-tooltip:after{content:"";border:4px solid #0000;border-top-color:var(--text);position:absolute;top:100%;left:50%;transform:translate(-50%)}.meth-modal{box-shadow:0 1px 2px #0000000a,0 8px 24px #0000000f,0 32px 64px #00000014}.dark .meth-modal{box-shadow:0 1px 2px #0003,0 8px 24px #0003,0 32px 64px #00000040}.meth-progress-fill{background:linear-gradient(90deg,var(--accent),var(--accent))}@supports (color:color-mix(in lab,red,red)){.meth-progress-fill{background:linear-gradient(90deg,var(--accent),color-mix(in srgb,var(--accent) 50%,transparent))}}.meth-step-icon{background:linear-gradient(135deg,var(--accent),var(--accent))}@supports (color:color-mix(in lab,red,red)){.meth-step-icon{background:linear-gradient(135deg,var(--accent),color-mix(in srgb,var(--accent) 70%,#a08060))}}.meth-step-icon{box-shadow:0 4px 10px rgba(var(--accent-rgb),.2)}.meth-step:not(:last-child):after{content:"";z-index:2;background:var(--bg);border:1px solid var(--border);border-bottom:none;border-left:none;width:14px;height:14px;position:absolute;top:50%;right:-1px;transform:translate(50%)translateY(-50%)rotate(45deg)}@media(max-width:700px){.meth-step:not(:last-child):after{display:none}}.meth-scroll-arrow{animation:2s ease-in-out infinite methBob}.meth-s1{background:radial-gradient(ellipse 55% 50% at 50% 85%,rgba(var(--accent-rgb),.06),transparent)}.meth-s2{background:radial-gradient(circle at 80% 20%,rgba(var(--accent-rgb),.06),transparent 45%)}.meth-s3{background:radial-gradient(ellipse 60% 50% at 30% 70%,rgba(var(--accent-rgb),.06),transparent)}.dark .meth-s1{background:radial-gradient(ellipse 55% 50% at 50% 85%,rgba(var(--accent-rgb),.1),transparent)}.dark .meth-s2{background:radial-gradient(circle at 80% 20%,rgba(var(--accent-rgb),.1),transparent 45%)}.dark .meth-s3{background:radial-gradient(ellipse 60% 50% at 30% 70%,rgba(var(--accent-rgb),.1),transparent)}.meth-taste-card:before{content:"";background:var(--tc,var(--accent));height:3px;position:absolute;top:0;left:0;right:0}.meth-pd-art:after{content:"";background:radial-gradient(circle at 50% 80%,#0000 40%,#fff3);position:absolute;inset:0}.dark .meth-pd-art:after{background:radial-gradient(circle at 50% 80%,#0000 40%,#00000026)}.meth-p-thumb.active{box-shadow:0 0 0 3px var(--pa),var(--shadow)}@supports (color:color-mix(in lab,red,red)){.meth-p-thumb.active{box-shadow:0 0 0 3px color-mix(in srgb,var(--pa) 10%,transparent),var(--shadow)}}.meth-reveal{opacity:0;transition:opacity .6s cubic-bezier(.16,1,.3,1),transform .6s cubic-bezier(.16,1,.3,1);transform:translateY(20px)}.meth-reveal.vis{opacity:1;transform:translateY(0)}.meth-reveal.d1{transition-delay:80ms}.meth-reveal.d2{transition-delay:.16s}.meth-reveal.d3{transition-delay:.24s}.meth-reveal.d4{transition-delay:.32s}.wizard-stage-fill{background:var(--accent);transition:width .35s}@supports (color:color-mix(in lab,red,red)){.wizard-stage-fill{background:color-mix(in srgb,var(--accent) 18%,transparent)}}.wizard-stage-track.is-active .wizard-stage-fill{background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.wizard-stage-track.is-active .wizard-stage-fill{background:color-mix(in srgb,var(--accent) 28%,transparent)}}.wizard-stage-track.is-done .wizard-stage-fill{background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.wizard-stage-track.is-done .wizard-stage-fill{background:color-mix(in srgb,var(--accent) 40%,transparent)}}.wizard-stage-track.is-error .wizard-stage-fill{background:var(--stat-r)}@supports (color:color-mix(in lab,red,red)){.wizard-stage-track.is-error .wizard-stage-fill{background:color-mix(in srgb,var(--stat-r) 32%,transparent)}}:focus-visible{outline:2px solid var(--accent);outline-offset:2px;border-radius:var(--ui-radius-sm)}@media(prefers-reduced-motion:reduce){*,:before,:after{transition:none!important;animation:none!important}.player-card{transform:none!important}.meth-reveal{opacity:1!important;transform:none!important}}}@layer utilities{.absolute{position:absolute}.relative{position:relative}.static{position:static}.top-1\/2{top:50%}.bottom-12{bottom:calc(var(--spacing) * 12)}.container{width:100%}@media(min-width:40rem){.container{max-width:40rem}}@media(min-width:48rem){.container{max-width:48rem}}@media(min-width:64rem){.container{max-width:64rem}}@media(min-width:80rem){.container{max-width:80rem}}@media(min-width:96rem){.container{max-width:96rem}}.mx-2{margin-inline:calc(var(--spacing) * 2)}.mx-auto{margin-inline:auto}.mt-1{margin-top:calc(var(--spacing) * 1)}.mt-2{margin-top:calc(var(--spacing) * 2)}.mt-3{margin-top:calc(var(--spacing) * 3)}.mt-4{margin-top:calc(var(--spacing) * 4)}.mt-6{margin-top:calc(var(--spacing) * 6)}.mt-16{margin-top:calc(var(--spacing) * 16)}.mb-1{margin-bottom:calc(var(--spacing) * 1)}.mb-2{margin-bottom:calc(var(--spacing) * 2)}.mb-3{margin-bottom:calc(var(--spacing) * 3)}.mb-4{margin-bottom:calc(var(--spacing) * 4)}.mb-6{margin-bottom:calc(var(--spacing) * 6)}.mb-8{margin-bottom:calc(var(--spacing) * 8)}.mb-10{margin-bottom:calc(var(--spacing) * 10)}.mb-12{margin-bottom:calc(var(--spacing) * 12)}.ml-12{margin-left:calc(var(--spacing) * 12)}.block{display:block}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-block{display:inline-block}.aspect-square{aspect-ratio:1}.h-2{height:calc(var(--spacing) * 2)}.h-4{height:calc(var(--spacing) * 4)}.h-5{height:calc(var(--spacing) * 5)}.min-h-screen{min-height:100vh}.w-4{width:calc(var(--spacing) * 4)}.w-5{width:calc(var(--spacing) * 5)}.w-8{width:calc(var(--spacing) * 8)}.w-12{width:calc(var(--spacing) * 12)}.w-full{width:100%}.max-w-3xl{max-width:var(--container-3xl)}.max-w-4xl{max-width:var(--container-4xl)}.max-w-lg{max-width:var(--container-lg)}.max-w-md{max-width:var(--container-md)}.flex-1{flex:1}.shrink-0{flex-shrink:0}.transform{transform:var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,)}.cursor-pointer{cursor:pointer}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-24{grid-template-columns:var(--grid-template-columns-24)}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.gap-2{gap:calc(var(--spacing) * 2)}.gap-3{gap:calc(var(--spacing) * 3)}.gap-4{gap:calc(var(--spacing) * 4)}.gap-\[1px\]{gap:1px}.gap-\[2px\]{gap:2px}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 1) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 1) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-\[2px\]>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(2px * var(--tw-space-y-reverse));margin-block-end:calc(2px * calc(1 - var(--tw-space-y-reverse)))}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.rounded-full{border-radius:3.40282e38px}.rounded-sm{border-radius:var(--radius-sm)}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-border{border-color:var(--color-border)}.bg-bg{background-color:var(--color-bg)}.p-3{padding:calc(var(--spacing) * 3)}.p-4{padding:calc(var(--spacing) * 4)}.p-6{padding:calc(var(--spacing) * 6)}.px-4{padding-inline:calc(var(--spacing) * 4)}.px-6{padding-inline:calc(var(--spacing) * 6)}.py-1\.5{padding-block:calc(var(--spacing) * 1.5)}.py-8{padding-block:calc(var(--spacing) * 8)}.py-20{padding-block:calc(var(--spacing) * 20)}.pt-4{padding-top:calc(var(--spacing) * 4)}.pt-14{padding-top:calc(var(--spacing) * 14)}.pb-4{padding-bottom:calc(var(--spacing) * 4)}.text-center{text-align:center}.font-mono{font-family:var(--font-mono)}.font-sans{font-family:var(--font-sans)}.font-serif{font-family:var(--font-serif)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.text-7xl{font-size:var(--text-7xl);line-height:var(--tw-leading,var(--text-7xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\[10px\]{font-size:10px}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-wider{--tw-tracking:var(--tracking-wider);letter-spacing:var(--tracking-wider)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.text-muted,.text-muted\/40{color:var(--color-muted)}@supports (color:color-mix(in lab,red,red)){.text-muted\/40{color:color-mix(in oklab,var(--color-muted) 40%,transparent)}}.text-muted\/60{color:var(--color-muted)}@supports (color:color-mix(in lab,red,red)){.text-muted\/60{color:color-mix(in oklab,var(--color-muted) 60%,transparent)}}.text-text,.text-text\/80{color:var(--color-text)}@supports (color:color-mix(in lab,red,red)){.text-text\/80{color:color-mix(in oklab,var(--color-text) 80%,transparent)}}.text-text\/90{color:var(--color-text)}@supports (color:color-mix(in lab,red,red)){.text-text\/90{color:color-mix(in oklab,var(--color-text) 90%,transparent)}}.uppercase{text-transform:uppercase}.italic{font-style:italic}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a), 0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.invert{--tw-invert:invert(100%);filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.delay-1{transition-delay:1ms}.delay-2{transition-delay:2ms}.delay-3{transition-delay:3ms}.duration-300{--tw-duration:.3s;transition-duration:.3s}@media(hover:hover){.hover\:text-text:hover{color:var(--color-text)}}@media(min-width:40rem){.sm\:mb-8{margin-bottom:calc(var(--spacing) * 8)}.sm\:flex{display:flex}.sm\:gap-4{gap:calc(var(--spacing) * 4)}.sm\:gap-6{gap:calc(var(--spacing) * 6)}.sm\:gap-\[2px\]{gap:2px}.sm\:p-4{padding:calc(var(--spacing) * 4)}.sm\:p-6{padding:calc(var(--spacing) * 6)}.sm\:px-6{padding-inline:calc(var(--spacing) * 6)}.sm\:py-20{padding-block:calc(var(--spacing) * 20)}.sm\:text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.sm\:text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.sm\:text-5xl{font-size:var(--text-5xl);line-height:var(--tw-leading,var(--text-5xl--line-height))}.sm\:text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.sm\:text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.sm\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.sm\:text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}}@media(min-width:48rem){.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.md\:p-8{padding:calc(var(--spacing) * 8)}.md\:text-5xl{font-size:var(--text-5xl);line-height:var(--tw-leading,var(--text-5xl--line-height))}.md\:text-6xl{font-size:var(--text-6xl);line-height:var(--tw-leading,var(--text-6xl--line-height))}.md\:text-8xl{font-size:var(--text-8xl);line-height:var(--tw-leading,var(--text-8xl--line-height))}}@media(min-width:64rem){.lg\:grid-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}}}:root{--bg:#f5f3f0;--surface:#fff;--surface-raised:#faf8f5;--text:#3c3226;--subtext:#6b5e50;--muted:#8a7d6f;--border:#d9d2c9;--border-light:#ebe5dc;--accent:#5c3d2e;--accent-soft:#ede6de;--accent-rgb:92,61,46;--ui-radius:14px;--ui-radius-sm:8px;--shadow:0 1px 3px #3c32260f, 0 4px 12px #3c32260a;--shadow-hover:0 4px 12px #3c32261a, 0 8px 24px #3c32260f;--stat-b:#1a5bdb;--stat-r:#d20f39}.dark{--bg:#1c1816;--surface:#2a2420;--surface-raised:#332c26;--text:#e0d6cc;--subtext:#b0a596;--muted:#8a7d6f;--border:#3d342c;--border-light:#4a3f35;--accent:#c9a882;--accent-soft:#2e261f;--accent-rgb:201,168,130;--shadow:0 1px 3px #0000004d, 0 4px 12px #0003;--shadow-hover:0 4px 12px #0006, 0 8px 24px #0000004d;--stat-b:#89b4fa;--stat-r:#f38ba8}.header{background:var(--bg);flex-wrap:wrap;flex-shrink:0;justify-content:space-between;align-items:center;gap:12px;padding:12px 24px;display:flex}.header-left{flex-wrap:wrap;align-items:baseline;gap:12px;display:flex}.header h1{letter-spacing:-.02em;font-size:24px;font-weight:700}.header h1 span{color:var(--accent)}.header-subtitle{color:var(--muted);font-size:20px;font-weight:500}.date-range{color:var(--muted);font-size:14px;font-weight:500}.header-right{align-items:center;gap:12px;display:flex}.nav-link,.accent-link{color:var(--text);background:var(--surface);border:1px solid var(--border);cursor:pointer;white-space:nowrap;border-radius:20px;justify-content:center;align-items:center;gap:6px;padding:8px 14px;font-family:inherit;font-size:13px;font-weight:600;text-decoration:none;transition:all .15s;display:inline-flex}.nav-link:hover,.accent-link:hover{border-color:var(--accent);color:var(--accent);background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.nav-link:hover,.accent-link:hover{background:color-mix(in srgb,var(--accent) 10%,var(--surface))}}.create-dropdown{position:relative}.create-btn{color:var(--accent);background:var(--accent-soft);border:1px solid var(--accent);align-items:center;gap:7px;padding:8px 14px;font-size:13px;font-weight:700;display:inline-flex}@supports (color:color-mix(in lab,red,red)){.create-btn{border:1px solid color-mix(in srgb,var(--accent) 35%,var(--border))}}.create-btn{cursor:pointer;white-space:nowrap;border-radius:20px;font-family:inherit;transition:all .15s}.create-btn:hover,.create-dropdown.open .create-btn{border-color:var(--accent);color:var(--accent);background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.create-btn:hover,.create-dropdown.open .create-btn{background:color-mix(in srgb,var(--accent) 18%,var(--surface))}}.create-menu{background:var(--surface);border:1px solid var(--border);border-radius:var(--ui-radius-sm);width:min(560px,100vw - 32px);box-shadow:var(--shadow-hover);z-index:80;padding:12px;position:absolute;top:calc(100% + 10px);right:0}.create-menu[hidden]{display:none}.create-menu-copy{margin-bottom:10px}.create-kicker{letter-spacing:.02em;text-transform:uppercase;color:var(--text);margin:0 0 4px;font-size:12px;font-weight:700}.create-subcopy{color:var(--muted);margin:0;font-size:12px;line-height:1.45}.command-strip{background:linear-gradient(180deg,var(--bg),var(--bg));justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;display:flex}@supports (color:color-mix(in lab,red,red)){.command-strip{background:linear-gradient(180deg,color-mix(in srgb,var(--bg) 74%,transparent),color-mix(in srgb,var(--bg) 92%,transparent))}}.command-strip{border:1px solid var(--border)}@supports (color:color-mix(in lab,red,red)){.command-strip{border:1px solid color-mix(in srgb,var(--border) 92%,transparent)}}.command-strip{border-radius:12px}.command-line-wrap{flex:1;min-width:0}.command-line{color:var(--text);white-space:nowrap;align-items:center;gap:10px;font-family:JetBrains Mono,monospace;font-size:13px;display:flex;overflow:auto}.command-prompt{color:var(--accent);font-weight:700}.command-actions{flex-shrink:0;align-items:center;gap:8px;display:flex}.create-copy-btn,.create-source-link{white-space:nowrap;border-radius:999px;align-items:center;gap:6px;padding:7px 10px;font-family:inherit;font-size:12px;font-weight:600;text-decoration:none;transition:all .15s;display:inline-flex}.create-copy-btn{border:1px solid var(--border);color:var(--text);cursor:pointer;background:0 0}.create-copy-btn:hover,.create-source-link:hover{border-color:var(--accent);color:var(--accent);background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.create-copy-btn:hover,.create-source-link:hover{background:color-mix(in srgb,var(--accent) 10%,transparent)}}.create-copy-btn.is-copied{color:#2f8f5b;background:#2f8f5b1a;border-color:#2f8f5b}.create-source-link{border:1px solid var(--border);color:var(--muted);background:0 0}.theme-btn{border:1px solid var(--border);background:var(--surface);cursor:pointer;width:36px;height:36px;color:var(--muted);border-radius:50%;justify-content:center;align-items:center;transition:all .2s;display:flex}.theme-btn:hover{border-color:var(--accent);color:var(--accent)}@media(max-width:640px){.header{gap:8px;padding:10px 16px}.header-right{gap:8px}.header-right .nav-link{display:none}.create-menu{width:min(420px,100vw - 32px);left:0;right:auto}.command-strip{flex-direction:column;align-items:stretch}.command-actions{flex-wrap:wrap;justify-content:flex-start}}.page-frame{flex-direction:column;height:100dvh;min-height:0;display:flex}@media(max-width:1024px){.page-frame{height:auto;min-height:100dvh}}.dash-panel{flex-direction:column;flex:1;min-height:0;display:flex}.dash-container{flex-direction:column;flex:1;min-height:0;padding:0 24px;display:flex}.main-grid{flex:1;grid-template-columns:2fr 1fr;gap:20px;min-height:0;padding:16px 0;display:grid}@media(max-width:1024px){.main-grid{flex:none;grid-template-columns:1fr}.right-col{order:-1}}.left{flex-direction:column;gap:12px;min-width:0;min-height:0;display:flex}.stat-cards{grid-template-columns:repeat(4,1fr);gap:12px;display:grid}@media(max-width:640px){.stat-cards{grid-template-columns:repeat(2,1fr)}}.stat-card{background:var(--surface);border-radius:var(--ui-radius-sm);box-shadow:var(--shadow);padding:14px 16px}.stat-card-label{text-transform:uppercase;letter-spacing:.04em;color:var(--muted);margin-bottom:4px;font-size:12px;font-weight:600}.stat-card-value{letter-spacing:-.03em;font-family:JetBrains Mono,monospace;font-size:28px;font-weight:700;line-height:1}.stat-card-value.highlight{color:var(--text);font-weight:800}.stat-card-sub{color:var(--muted);margin-top:4px;font-size:13px}.trend-panel{background:var(--surface);border-radius:var(--ui-radius-sm);box-shadow:var(--shadow);flex-direction:column;flex:1;min-width:0;min-height:0;padding:14px 20px 10px;display:flex}.trend-header{flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:10px 16px;min-width:0;margin-bottom:10px;display:flex}.trend-copy{flex-direction:column;flex:1;gap:6px;min-width:0;display:flex}.trend-copy-row{flex-wrap:wrap;align-items:center;gap:8px;min-width:0;display:flex}.trend-title{font-size:16px;font-weight:700}.trend-copy-sep{color:var(--border);font-size:13px;line-height:1}.trend-metric-def{color:var(--muted);min-width:0;font-size:12px;line-height:1.35}.trend-legend{flex-wrap:wrap;align-items:center;gap:10px;min-height:15px;display:flex}.trend-legend-pill{color:var(--muted);white-space:nowrap;align-items:center;gap:5px;font-size:11px;font-weight:500;display:inline-flex}.trend-legend-dot{border-radius:50%;flex-shrink:0;width:8px;height:8px}.metric-tabs{flex-wrap:wrap;align-self:flex-start;gap:4px;min-width:0;display:flex}.metric-tab{border:1px solid var(--border);color:var(--muted);cursor:pointer;white-space:nowrap;background:0 0;border-radius:20px;padding:6px 14px;font-family:inherit;font-size:12px;font-weight:600;transition:all .15s;position:relative}.metric-tab[data-tooltip]:hover:after{content:attr(data-tooltip);background:var(--text);color:var(--bg);white-space:normal;z-index:20;pointer-events:none;border-radius:8px;width:max-content;max-width:220px;padding:6px 12px;font-family:JetBrains Mono,monospace;font-size:11px;font-weight:500;line-height:1.4;position:absolute;top:calc(100% + 8px);left:50%;transform:translate(-50%)}.metric-tab[data-tooltip]:hover:before{content:"";border:5px solid #0000;border-bottom-color:var(--text);z-index:20;pointer-events:none;position:absolute;top:calc(100% + 3px);left:50%;transform:translate(-50%)}.metric-tab.active{background:var(--accent);color:#fff;border-color:var(--accent)}.metric-tab:hover:not(.active){border-color:var(--accent);color:var(--accent)}.trend-current{align-items:baseline;gap:8px;margin-bottom:8px;display:flex}.trend-current-val{letter-spacing:-.03em;color:var(--trend-color,var(--accent));font-family:JetBrains Mono,monospace;font-size:36px;font-weight:800}.trend-current-label{display:none}.trend-chart-wrap{flex:1;min-height:60px;position:relative}.heatmap-panel{background:var(--surface);border-radius:var(--ui-radius-sm);box-shadow:var(--shadow);flex-shrink:0;padding:14px 18px}.heatmap-title{margin-bottom:8px;font-size:14px;font-weight:700}.heatmap{grid-template-columns:32px repeat(24,1fr);gap:1px;font-size:10px;display:grid}.heatmap-label{color:var(--muted);align-items:center;font-size:10px;font-weight:500;display:flex}.heatmap-hour{text-align:center;color:var(--muted);font-size:10px;font-weight:500}.heatmap-cell{background:var(--border);opacity:.3;border-radius:2px;height:18px}.heatmap-cell.l1{background:var(--heatmap-color,var(--accent));opacity:.2}.heatmap-cell.l2{background:var(--heatmap-color,var(--accent));opacity:.35}.heatmap-cell.l3{background:var(--heatmap-color,var(--accent));opacity:.55}.heatmap-cell.l4{background:var(--heatmap-color,var(--accent));opacity:.75}.heatmap-cell.l5{background:var(--heatmap-color,var(--accent));opacity:1}.heatmap-tooltip{background:var(--text);color:var(--bg);pointer-events:none;opacity:0;white-space:nowrap;z-index:10;border-radius:6px;padding:5px 10px;font-family:JetBrains Mono,monospace;font-size:11px;font-weight:600;transition:opacity .1s;position:absolute;top:0;left:0;transform:translate(-50%)}.heatmap-tooltip:after{content:"";border:4px solid #0000;border-top-color:var(--text);position:absolute;top:100%;left:50%;transform:translate(-50%)}.heatmap-panel{position:relative}.heatmap-meta{color:var(--muted);justify-content:space-between;margin-top:6px;font-size:11px;display:flex}.right-col{flex-direction:column;gap:12px;min-width:0;min-height:0;display:flex}.card-dock{perspective:1200px;flex:1;width:100%;min-height:0;display:flex;position:relative}.player-card{background:var(--surface);width:100%;transform-style:preserve-3d;will-change:transform;border:1px solid #0000000f;border-radius:24px;flex-direction:column;height:100%;transition:transform .15s ease-out,box-shadow .2s ease-out;display:flex;overflow:hidden;box-shadow:0 1px 2px #0000000a,0 4px 12px #0000000f,0 12px 32px #00000014,0 24px 60px #0000000f;container-type:inline-size}.dark .player-card{border-color:#ffffff0f;box-shadow:0 1px 2px #0003,0 4px 12px #0003,0 12px 32px #00000040,0 24px 60px #0003}.card-top{aspect-ratio:840/1040;background-position:50%;background-size:cover;border-radius:24px 24px 0 0;padding:0;position:relative;overflow:hidden}.card-top-content{z-index:2;flex-direction:column;gap:8px;width:50%;padding:22px 24px 18px;display:flex;position:absolute;inset:0}.persona-name{color:#fff;letter-spacing:-.04em;text-shadow:0 2px 8px #0000004d;white-space:nowrap;font-size:clamp(22px,5.5cqw,36px);font-weight:800;line-height:.96}.donut-grid{flex-direction:column;gap:10px;margin-top:16px;display:flex}.donut-item{align-items:center;gap:10px;display:flex}.donut-ring{flex-shrink:0;width:44px;height:44px;position:relative}.donut-ring svg{width:100%;height:100%;transform:rotate(-90deg)}.donut-ring .donut-track{fill:none;stroke:#ffffff26;stroke-width:5px}.donut-ring .donut-fill{fill:none;stroke:#ffffffd9;stroke-width:5px;stroke-linecap:round;transition:stroke-dashoffset .6s}.donut-val{color:#fff;justify-content:center;align-items:center;font-family:JetBrains Mono,monospace;font-size:13px;font-weight:800;display:flex;position:absolute;inset:0}.donut-label{color:#ffffffb3;font-size:12px;font-weight:600}.card-body{padding:14px 24px 12px}.persona-desc{color:var(--muted);font-size:14px;line-height:1.58}.persona-desc strong{color:var(--text);font-weight:700}.stat-strip{border-top:1px solid var(--border);grid-template-columns:repeat(2,1fr);display:grid}.stat-block{text-align:center;padding:16px 10px 14px;position:relative}.stat-block:not(:last-child):after{content:"";background:var(--border);width:1px;height:60%;position:absolute;top:20%;right:0}.stat-num{letter-spacing:-.04em;font-family:JetBrains Mono,monospace;font-size:30px;font-weight:800;line-height:1}.stat-block:first-child .stat-num{color:var(--accent)}.stat-block:nth-child(2) .stat-num{color:var(--stat-b)}.stat-block:nth-child(3) .stat-num{color:var(--stat-r)}.stat-label{text-transform:uppercase;letter-spacing:.05em;color:var(--muted);margin-top:5px;font-size:12px;font-weight:700}.stat-minibar{background:var(--border);opacity:.55;border-radius:999px;width:58%;height:3px;margin:8px auto 0;overflow:hidden}.stat-minibar-fill{border-radius:2px;height:100%}.stat-minibar-fill.o{background:var(--accent)}.stat-minibar-fill.b{background:var(--stat-b)}.stat-minibar-fill.r{background:var(--stat-r)}.card-foot{color:var(--muted);border-top:1px solid var(--border);justify-content:space-between;padding:8px 24px;font-family:JetBrains Mono,monospace;font-size:11px;display:flex}.footer{color:var(--muted);border-top:1px solid var(--border);flex-shrink:0;justify-content:space-between;align-items:center;margin-top:16px;padding:12px 24px;font-size:11px;display:flex}.footer-links{gap:16px;display:flex}.footer-links a{color:var(--muted);text-decoration:none;transition:color .15s}.footer-links a:hover{color:var(--text)}.share-toast{background:var(--surface);color:var(--text);border:1px solid var(--border);border-radius:var(--ui-radius-sm);box-shadow:var(--shadow);z-index:50;opacity:0;pointer-events:none;padding:10px 16px;font-size:13px;font-weight:500;transition:opacity .3s,transform .3s;position:fixed;bottom:84px;right:24px;transform:translateY(8px)}.share-toast.show{opacity:1;transform:translateY(0)}.refresh-modal{background:var(--surface);border-radius:var(--ui-radius);width:90%;max-width:480px;box-shadow:var(--shadow-hover);text-align:center;padding:28px 32px}.refresh-modal h3{margin-bottom:16px;font-size:16px;font-weight:700}.refresh-modal .wizard-log{text-align:left;height:180px;margin-bottom:12px}.refresh-modal .wizard-progress{margin-bottom:12px}.refresh-modal-result{color:var(--text);font-size:14px;line-height:1.8}.refresh-modal-result .result-num{color:var(--accent);font-family:JetBrains Mono,monospace;font-weight:700}.refresh-modal-close{background:var(--accent);color:#fff;cursor:pointer;border:none;border-radius:20px;margin-top:16px;padding:8px 24px;font-family:inherit;font-size:13px;font-weight:600;transition:transform .1s}.refresh-modal-close:hover{transform:scale(1.03)}@media(max-width:1024px){.page-frame{overflow-x:hidden}.dash-container,.main-grid,.card-dock{flex:none}.player-card{height:auto}.card-top-content{gap:8px}.trend-panel{flex:none;min-height:280px}.right-col{align-self:center;width:100%;max-width:480px}}@media(max-width:640px){html,body{height:auto;overflow-x:hidden}.header{gap:8px;padding:10px 16px}.header-right{gap:8px}.tab-bar{padding:0 16px}.dash-container{padding:0 12px}.main-grid{gap:12px}.right-col{align-self:stretch;gap:10px;max-width:none}.card-top{aspect-ratio:840/1040}.card-top-content{width:45%;padding:14px 14px 12px}.persona-name{font-size:22px}.donut-ring{width:36px;height:36px}.donut-val{font-size:11px}.donut-label{font-size:10px}.donut-grid,.donut-item{gap:6px}.card-body{padding:10px 16px 8px}.persona-desc{overflow-wrap:break-word;font-size:12px}.stat-num{font-size:22px}.stat-label{font-size:10px}.stat-block{padding:10px 4px}.card-foot{padding:6px 16px;font-size:10px}.stat-cards{gap:8px}.stat-card{padding:10px 12px}.stat-card-value{font-size:20px}.stat-card-label,.stat-card-sub{font-size:11px}.trend-panel{min-height:220px;padding:14px}.trend-header{flex-direction:column;align-items:flex-start;gap:6px}.trend-copy{gap:4px;width:100%}.trend-copy-row{gap:6px}.trend-copy-sep{display:none}.trend-metric-def{font-size:11px}.trend-title{font-size:14px}.metric-tabs{flex-wrap:wrap;gap:3px;width:100%}.metric-tab{border-radius:14px;padding:4px 8px;font-size:10px}.trend-current-val{font-size:24px}.trend-current-label{font-size:12px}.trend-chart-wrap{min-height:80px}.heatmap-panel{padding:10px 14px}.heatmap-title{margin-bottom:4px;font-size:13px}.heatmap{grid-template-columns:14px repeat(24,1fr);gap:1px}.heatmap-hour{visibility:hidden;height:0;font-size:0;line-height:0}.heatmap-label{text-overflow:clip;white-space:nowrap;width:14px;font-size:7px;overflow:hidden}.heatmap-cell{border-radius:1px;height:8px}.heatmap-meta{flex-wrap:wrap;gap:4px;font-size:10px}.footer{text-align:center;flex-direction:column;gap:4px;margin-top:8px;padding:10px 12px;font-size:10px}}@media(prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}.player-card{transform:none!important}}.icon-sm{width:16px;height:16px}.sr-only{clip:rect(0,0,0,0);border:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.wizard-overlay{z-index:200;background:var(--bg);justify-content:center;align-items:center;padding:16px;display:none;position:fixed;inset:0}.wizard-overlay.active{display:flex}.wizard-panel{background:var(--surface);border-radius:var(--ui-radius);width:100%;max-width:520px;box-shadow:var(--shadow-hover);padding:32px}.wizard-title{letter-spacing:-.02em;margin-bottom:4px;font-size:20px;font-weight:700}.wizard-title span{color:var(--accent)}.wizard-steps{gap:6px;margin:20px 0 24px;display:flex}.wizard-step{color:var(--muted);background:var(--bg);border-radius:20px;align-items:center;gap:6px;padding:6px 14px;font-size:12px;font-weight:600;transition:all .2s;display:flex}.wizard-step.active{background:var(--accent);color:#fff}.wizard-step.done{color:var(--accent)}.wizard-step-num{font-weight:700}.wizard-page{display:none}.wizard-page.active{display:block}.wizard-intro{color:var(--subtext);margin-bottom:20px;font-size:14px;line-height:1.5}.wizard-loading{color:var(--muted);text-align:center;padding:24px 0;font-size:13px}.wizard-backends{flex-direction:column;gap:8px;margin-bottom:24px;display:flex}.wizard-backend{border:1px solid var(--border);border-radius:var(--ui-radius-sm);align-items:center;gap:12px;padding:12px 16px;transition:border-color .15s;display:flex}.wizard-backend.detected{border-color:var(--accent)}.wizard-backend-icon{border-radius:50%;flex-shrink:0;width:8px;height:8px}.wizard-backend-icon.available{background:#40a02b}.wizard-backend-icon.coming_soon{background:#df8e1d}.wizard-backend-icon.not_found{background:var(--border)}.wizard-backend-info{flex:1}.wizard-backend-name{font-size:14px;font-weight:600}.wizard-backend-detail{color:var(--muted);margin-top:2px;font-size:12px}.wizard-config{flex-direction:column;gap:8px;margin-bottom:16px;display:flex}.wizard-toggle{border:1px solid var(--border);border-radius:var(--ui-radius-sm);cursor:pointer;align-items:center;gap:12px;padding:10px 16px;font-size:14px;font-weight:500;transition:border-color .15s;display:flex}.wizard-toggle:has(input:checked){border-color:var(--accent)}.wizard-toggle input[type=checkbox]{accent-color:var(--accent);width:16px;height:16px}.wizard-toggle.is-disabled{cursor:not-allowed;opacity:.65}.wizard-exclusions{margin-bottom:16px}.wizard-label{margin-bottom:6px;font-size:13px;font-weight:600;display:block}.wizard-hint{color:var(--muted);margin-top:8px;font-size:11px}.exclusion-chips{flex-direction:column;gap:6px;margin-bottom:8px;display:flex}.exclusion-chip{background:var(--bg);border:1px solid var(--border);border-radius:var(--ui-radius-sm);align-items:center;gap:8px;padding:8px 12px;font-size:12px;display:flex}.exclusion-chip-path{text-overflow:ellipsis;white-space:nowrap;color:var(--text);flex:1;font-family:JetBrains Mono,monospace;overflow:hidden}.exclusion-chip-count{color:var(--muted);white-space:nowrap;font-size:11px}.exclusion-chip-remove{cursor:pointer;color:var(--muted);background:0 0;border:none;padding:2px;font-size:16px;line-height:1;transition:color .15s}.exclusion-chip-remove:hover{color:var(--stat-r)}.exclusion-add-btn{align-items:center;gap:6px;padding:8px 16px;font-size:12px;display:inline-flex}.wizard-nav{justify-content:flex-end;gap:8px;display:flex}.wizard-btn{cursor:pointer;border:none;border-radius:20px;padding:10px 24px;font-family:inherit;font-size:13px;font-weight:600;transition:transform .1s}.wizard-btn:hover{transform:scale(1.03)}.wizard-btn-primary{background:var(--accent);color:#fff}.wizard-btn-ghost{background:var(--bg);color:var(--text);border:1px solid var(--border)}.wizard-log{background:var(--bg);border:1px solid var(--border);border-radius:var(--ui-radius-sm);height:180px;margin-bottom:16px;padding:12px;font-family:JetBrains Mono,monospace;font-size:12px;overflow-y:auto}.wizard-log-entry{color:var(--subtext);padding:2px 0}.wizard-log-entry.done{color:var(--accent);font-weight:600}.wizard-log-entry.error{color:var(--stat-r)}.wizard-progress{background:var(--border);border-radius:2px;height:4px;margin-bottom:12px;overflow:hidden}.wizard-progress-bar{background:var(--accent);width:0;height:100%;transition:width .4s}.wizard-progress-meta{justify-content:space-between;align-items:center;gap:12px;margin-bottom:8px;display:flex}.wizard-progress-label{color:var(--text);font-size:12px;font-weight:600}.wizard-progress-pct{color:var(--accent);font-size:12px;font-weight:700}.wizard-stage-list{flex-direction:column;gap:8px;margin-bottom:12px;display:flex}.wizard-stage-row{grid-template-columns:minmax(0,130px) 1fr 36px;align-items:center;gap:10px;display:grid}.wizard-stage-name{letter-spacing:.02em;color:var(--muted);text-transform:uppercase;font-size:11px;font-weight:700}.wizard-stage-track{border:1px solid var(--border);background:var(--bg);border-radius:999px;height:24px;position:relative;overflow:hidden}.wizard-stage-fill{background:var(--accent);width:0;position:absolute;inset:0 auto 0 0}@supports (color:color-mix(in lab,red,red)){.wizard-stage-fill{background:color-mix(in srgb,var(--accent) 18%,transparent)}}.wizard-stage-fill{transition:width .35s}.wizard-stage-track.is-active .wizard-stage-fill{background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.wizard-stage-track.is-active .wizard-stage-fill{background:color-mix(in srgb,var(--accent) 28%,transparent)}}.wizard-stage-track.is-done .wizard-stage-fill{background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.wizard-stage-track.is-done .wizard-stage-fill{background:color-mix(in srgb,var(--accent) 40%,transparent)}}.wizard-stage-track.is-error .wizard-stage-fill{background:var(--stat-r)}@supports (color:color-mix(in lab,red,red)){.wizard-stage-track.is-error .wizard-stage-fill{background:color-mix(in srgb,var(--stat-r) 32%,transparent)}}.wizard-stage-detail{z-index:1;color:var(--subtext);white-space:nowrap;text-overflow:ellipsis;padding:0 10px;font-size:11px;line-height:24px;display:block;position:relative;overflow:hidden}.wizard-stage-track.is-active .wizard-stage-detail{color:var(--text)}.wizard-stage-value{color:var(--muted);text-align:right;font-size:11px;font-weight:700}@media(max-width:640px){.wizard-panel{padding:24px 20px}.wizard-steps{flex-wrap:wrap}.wizard-stage-row{grid-template-columns:110px 1fr 32px}}.settings-modal{background:var(--surface);border-radius:var(--ui-radius);width:90%;max-width:460px;box-shadow:var(--shadow-hover)}.settings-header{justify-content:space-between;align-items:center;padding:20px 24px 0;display:flex}.settings-header h3{font-size:16px;font-weight:700}.settings-body{padding:16px 24px}.settings-section{margin-bottom:16px}.settings-backend-row{flex-direction:column;gap:4px;display:flex}.settings-backend-title{align-items:center;gap:8px;display:inline-flex}.settings-backend-badge{letter-spacing:.02em;text-transform:uppercase;background:var(--accent);border-radius:999px;justify-content:center;align-items:center;padding:2px 8px;font-size:10px;font-weight:700;display:inline-flex}@supports (color:color-mix(in lab,red,red)){.settings-backend-badge{background:color-mix(in srgb,var(--accent) 16%,transparent)}}.settings-backend-badge{color:var(--accent)}.settings-backend-detail{color:var(--muted);padding:0 4px 2px 16px;font-size:12px}.settings-footer{border-top:1px solid var(--border);flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;margin-top:8px;padding:16px 24px 20px;display:flex}.settings-footer-right{gap:8px;display:flex}@media(max-width:480px){.settings-footer{flex-direction:column-reverse;align-items:stretch}.settings-footer-right{justify-content:stretch}.settings-footer-right .wizard-btn{text-align:center;flex:1}.settings-footer .wizard-btn-danger{text-align:center}}.wizard-btn-danger{color:var(--stat-r);border:1px solid var(--stat-r);background:0 0;padding:8px 16px;font-size:12px}.wizard-btn-danger:hover{background:var(--stat-r);color:#fff}.modal-overlay{z-index:100;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);background:#3c322659;justify-content:center;align-items:center;padding:16px;display:none;position:fixed;inset:0}.dark .modal-overlay{background:#0000008c}.modal-overlay.active{display:flex}.meth-modal{background:var(--bg);border:1px solid var(--border);border-radius:20px;flex-direction:column;width:min(1000px,100%);height:min(720px,100vh - 32px);display:flex;position:relative;overflow:hidden;box-shadow:0 1px 2px #0000000a,0 8px 24px #0000000f,0 32px 64px #00000014}.dark .meth-modal{box-shadow:0 1px 2px #0003,0 8px 24px #0003,0 32px 64px #00000040}.meth-progress{background:var(--border);z-index:20;opacity:.5;height:2px;position:absolute;top:0;left:0;right:0}.meth-progress-fill{background:linear-gradient(90deg,var(--accent),var(--accent));border-radius:0 1px 1px 0;width:0%;height:100%;transition:width .25s}@supports (color:color-mix(in lab,red,red)){.meth-progress-fill{background:linear-gradient(90deg,var(--accent),color-mix(in srgb,var(--accent) 50%,transparent))}}.meth-header{border-bottom:1px solid var(--border);background:var(--bg);z-index:10;flex-shrink:0;justify-content:space-between;align-items:center;padding:14px 22px;display:flex}.meth-header-left{align-items:center;gap:12px;display:flex}.meth-logo{background:var(--accent);width:32px;height:32px;box-shadow:0 2px 6px rgba(var(--accent-rgb),.2);border-radius:8px;justify-content:center;align-items:center;font-size:15px;display:flex}.meth-header-title{letter-spacing:-.02em;color:var(--text);font-family:Fraunces,serif;font-size:16px;font-weight:700}.meth-header-sub{color:var(--muted);margin-top:1px;font-size:11px}.modal-close{border:1px solid var(--border);background:var(--surface);width:32px;height:32px;color:var(--muted);cursor:pointer;border-radius:8px;justify-content:center;align-items:center;font-size:14px;transition:all .15s;display:flex}.modal-close:hover{border-color:var(--accent);color:var(--accent)}.modal-close svg{color:currentColor;width:16px;height:16px}.meth-scroll{scroll-snap-type:y mandatory;scrollbar-width:thin;scrollbar-color:rgba(var(--accent-rgb),.12) transparent;flex:1;height:0;min-height:0;overflow:hidden auto}.meth-scroll::-webkit-scrollbar{width:5px}.meth-scroll::-webkit-scrollbar-track{background:0 0}.meth-scroll::-webkit-scrollbar-thumb{background:rgba(var(--accent-rgb),.12);border-radius:3px}.meth-snap{scroll-snap-align:start;scroll-snap-stop:always;flex-direction:column;flex-shrink:0;height:100%;min-height:100%;display:flex;overflow:hidden}.meth-reveal{opacity:0;transition:opacity .6s cubic-bezier(.16,1,.3,1),transform .6s cubic-bezier(.16,1,.3,1);transform:translateY(20px)}.meth-reveal.vis{opacity:1;transform:translateY(0)}.meth-reveal.d1{transition-delay:80ms}.meth-reveal.d2{transition-delay:.16s}.meth-reveal.d3{transition-delay:.24s}.meth-reveal.d4{transition-delay:.32s}.meth-s1{background:radial-gradient(ellipse 55% 50% at 50% 85%,rgba(var(--accent-rgb),.06),transparent)}.dark .meth-s1{background:radial-gradient(ellipse 55% 50% at 50% 85%,rgba(var(--accent-rgb),.1),transparent)}.meth-s1-inner{flex-direction:column;flex:1;justify-content:center;padding:0 48px;display:flex}@media(max-width:640px){.meth-s1-inner{padding:0 20px}}.meth-hero{text-align:center;padding:40px 0 32px}.meth-hero-kicker{background:var(--accent-soft);text-transform:uppercase;letter-spacing:.12em;color:var(--accent);border-radius:999px;align-items:center;gap:7px;margin-bottom:20px;padding:6px 14px;font-family:JetBrains Mono,monospace;font-size:11px;font-weight:700;display:inline-flex}.meth-hero h1{letter-spacing:-.04em;color:var(--text);max-width:15ch;margin:0 auto;font-family:Fraunces,serif;font-size:clamp(34px,5.5vw,52px);font-weight:800;line-height:1.02}.meth-hero h1 em{color:var(--accent);font-style:italic;font-weight:600}.meth-hero-sub{color:var(--subtext,var(--muted));max-width:46ch;margin-top:16px;margin-left:auto;margin-right:auto;font-size:17px;line-height:1.6}.meth-pipeline-wrap{padding:0 0 28px}.meth-rule{color:var(--accent);align-items:center;gap:12px;margin-bottom:18px;font-family:Fraunces,serif;font-size:14px;font-weight:700;display:flex}.meth-rule:after{content:"";background:var(--border);flex:1;height:1px}.meth-process{grid-template-columns:repeat(4,1fr);gap:2px;display:grid}@media(max-width:700px){.meth-process{grid-template-columns:1fr 1fr}}.meth-step{background:var(--surface);border:1px solid var(--border);padding:22px 20px;transition:all .2s;position:relative}.meth-step:first-child{border-radius:12px 0 0 12px}.meth-step:last-child{border-radius:0 12px 12px 0}@media(max-width:700px){.meth-step:first-child{border-radius:12px 0 0}.meth-step:nth-child(2){border-radius:0 12px 0 0}.meth-step:nth-child(3){border-radius:0 0 0 12px}.meth-step:last-child{border-radius:0 0 12px}}.meth-step:hover{background:var(--accent-soft)}.meth-step-icon{background:linear-gradient(135deg,var(--accent),var(--accent));border-radius:9px;width:38px;height:38px}@supports (color:color-mix(in lab,red,red)){.meth-step-icon{background:linear-gradient(135deg,var(--accent),color-mix(in srgb,var(--accent) 70%,#a08060))}}.meth-step-icon{color:#f0e8de;box-shadow:0 4px 10px rgba(var(--accent-rgb),.2);justify-content:center;align-items:center;margin-bottom:12px;font-size:17px;display:flex}.meth-step h3{color:var(--text);margin-bottom:5px;font-family:Fraunces,serif;font-size:16px;font-weight:700}.meth-step p{color:var(--muted);font-size:13px;line-height:1.55}.meth-step:not(:last-child):after{content:"";z-index:2;background:var(--bg);border:1px solid var(--border);border-bottom:none;border-left:none;width:14px;height:14px;position:absolute;top:50%;right:-1px;transform:translate(50%)translateY(-50%)rotate(45deg)}@media(max-width:700px){.meth-step:not(:last-child):after{display:none}}.meth-scroll-hint{text-align:center;color:var(--muted);letter-spacing:.1em;text-transform:uppercase;flex-direction:column;align-items:center;gap:6px;padding:8px 0 16px;font-family:JetBrains Mono,monospace;font-size:10px;display:flex}.meth-scroll-arrow{border-right:2px solid var(--border);border-bottom:2px solid var(--border);width:14px;height:14px;animation:2s ease-in-out infinite methBob;transform:rotate(45deg)}@keyframes methBob{0%,to{transform:rotate(45deg)translate(0)}50%{transform:rotate(45deg)translate(2px,2px)}}.meth-s2{background:radial-gradient(circle at 80% 20%,rgba(var(--accent-rgb),.06),transparent 45%)}.dark .meth-s2{background:radial-gradient(circle at 80% 20%,rgba(var(--accent-rgb),.1),transparent 45%)}.meth-s2-inner{flex-direction:column;flex:1;justify-content:center;padding:0 48px;display:flex}@media(max-width:640px){.meth-s2-inner{padding:0 20px}}.meth-s2-header{text-align:center;margin-bottom:36px}.meth-s2-header h2{letter-spacing:-.03em;color:var(--text);font-family:Fraunces,serif;font-size:clamp(28px,4vw,40px);font-weight:800;line-height:1.05}.meth-s2-header p{color:var(--subtext,var(--muted));max-width:48ch;margin-top:10px;margin-left:auto;margin-right:auto;font-size:16px;line-height:1.6}.meth-taste-grid{grid-template-columns:repeat(4,1fr);gap:14px;display:grid}@media(max-width:800px){.meth-taste-grid{grid-template-columns:1fr 1fr}}@media(max-width:480px){.meth-taste-grid{grid-template-columns:1fr}}.meth-taste-card{background:var(--surface);border:1px solid var(--border);box-shadow:var(--shadow);border-radius:16px;padding:24px 22px;position:relative;overflow:hidden}.meth-taste-card:before{content:"";background:var(--tc,var(--accent));height:3px;position:absolute;top:0;left:0;right:0}.meth-taste-cat{color:var(--text);margin-bottom:16px;font-family:Fraunces,serif;font-size:17px;font-weight:700}.meth-taste-list{flex-direction:column;display:flex}.meth-taste-item{border-bottom:1px solid var(--border);justify-content:space-between;align-items:baseline;gap:6px;padding:9px 0;font-size:13px;display:flex}.meth-taste-item:last-child{border-bottom:none}.meth-taste-name{color:var(--text);white-space:nowrap;font-weight:600}.meth-taste-note{color:var(--muted);text-align:right;font-size:11px}.meth-s3{background:radial-gradient(ellipse 60% 50% at 30% 70%,rgba(var(--accent-rgb),.06),transparent)}.dark .meth-s3{background:radial-gradient(ellipse 60% 50% at 30% 70%,rgba(var(--accent-rgb),.1),transparent)}.meth-s3-inner{flex-direction:column;flex:1;min-height:0;padding:28px 48px 24px;display:flex}@media(max-width:640px){.meth-s3-inner{padding:24px 20px 20px}}.meth-s3-header{margin-bottom:20px}.meth-s3-header h2{letter-spacing:-.03em;color:var(--text);font-family:Fraunces,serif;font-size:clamp(26px,3.5vw,36px);font-weight:800;line-height:1.05}.meth-s3-header p{color:var(--subtext,var(--muted));margin-top:8px;font-size:15px;line-height:1.55}.meth-persona-layout{flex:1;grid-template-columns:210px 1fr;gap:16px;min-height:0;display:grid}@media(max-width:760px){.meth-persona-layout{grid-template-rows:auto 1fr;grid-template-columns:1fr}}.meth-persona-list{scrollbar-width:thin;scrollbar-color:rgba(var(--accent-rgb),.1) transparent;flex-direction:column;gap:6px;display:flex;overflow-y:auto}@media(max-width:760px){.meth-persona-list{flex-direction:row;gap:8px;padding-bottom:4px;overflow:auto hidden}}.meth-p-thumb{background:var(--surface);cursor:pointer;box-shadow:var(--shadow);border:2px solid #0000;border-radius:13px;flex-shrink:0;align-items:center;gap:12px;padding:11px 14px;transition:all .2s;display:flex}.meth-p-thumb:hover{border-color:var(--border);transform:translateY(-1px)}.meth-p-thumb.active{border-color:var(--pa,var(--accent));background:var(--pa,var(--accent))}@supports (color:color-mix(in lab,red,red)){.meth-p-thumb.active{background:color-mix(in srgb,var(--pa,var(--accent)) 6%,var(--surface))}}.meth-p-thumb.active{box-shadow:0 0 0 3px var(--pa),var(--shadow)}@supports (color:color-mix(in lab,red,red)){.meth-p-thumb.active{box-shadow:0 0 0 3px color-mix(in srgb,var(--pa) 10%,transparent),var(--shadow)}}.meth-p-thumb-img{background:var(--bg);border-radius:10px;flex-shrink:0;justify-content:center;align-items:center;width:44px;height:44px;display:flex;overflow:hidden}.meth-p-thumb-img img{object-fit:contain;filter:drop-shadow(0 2px 4px #0000001a);width:90%;height:90%}.meth-p-thumb-text{min-width:0}.meth-p-thumb-name{color:var(--text);white-space:nowrap;text-overflow:ellipsis;font-family:Fraunces,serif;font-size:14px;font-weight:700;overflow:hidden}.meth-p-thumb-trait{color:var(--muted);-webkit-line-clamp:2;-webkit-box-orient:vertical;font-size:11px;line-height:1.35;display:-webkit-box;overflow:hidden}@media(max-width:760px){.meth-p-thumb{text-align:center;flex-direction:column;gap:6px;min-width:100px;padding:8px 14px}.meth-p-thumb-trait{display:none}}.meth-pd{background:var(--surface);border:1px solid var(--border);min-height:0;box-shadow:var(--shadow);border-radius:18px;grid-template-columns:240px 1fr;display:grid;overflow:hidden}@media(max-width:900px){.meth-pd{grid-template-columns:200px 1fr}}@media(max-width:760px){.meth-pd{grid-template-rows:180px 1fr;grid-template-columns:1fr}}.meth-pd-art{background:var(--pd-gradient,linear-gradient(160deg,#ede6de,#f5f3f0));border-right:1px solid var(--border);justify-content:center;align-items:center;padding:20px;display:flex;position:relative;overflow:hidden}@media(max-width:760px){.meth-pd-art{border-right:none;border-bottom:1px solid var(--border)}}.meth-pd-art:after{content:"";background:radial-gradient(circle at 50% 80%,#0000 40%,#fff3);position:absolute;inset:0}.dark .meth-pd-art{background:var(--pd-gradient-dark,linear-gradient(160deg,#2e2822,#1c1816))}.dark .meth-pd-art:after{background:radial-gradient(circle at 50% 80%,#0000 40%,#00000026)}.meth-pd-art img{object-fit:contain;z-index:1;filter:drop-shadow(0 10px 20px #00000026);width:auto;max-width:90%;height:82%;transition:transform .4s cubic-bezier(.16,1,.3,1),opacity .25s;position:relative}.meth-pd-copy{scrollbar-width:thin;scrollbar-color:rgba(var(--accent-rgb),.1) transparent;flex-direction:column;padding:24px 28px;display:flex;overflow-y:auto}@media(max-width:640px){.meth-pd-copy{padding:18px 20px}}.meth-pd-badge{text-transform:uppercase;letter-spacing:.1em;color:var(--pa,var(--accent));margin-bottom:5px;font-family:JetBrains Mono,monospace;font-size:11px;font-weight:700}.meth-pd-name{letter-spacing:-.04em;color:var(--text);margin-bottom:12px;font-family:Fraunces,serif;font-size:clamp(28px,3.5vw,38px);font-weight:800;line-height:.95}.meth-pd-desc{color:var(--subtext,var(--muted));margin-bottom:18px;font-size:15px;line-height:1.6}.meth-pd-cards{grid-template-columns:1fr 1fr;gap:10px;margin-bottom:16px;display:grid}@media(max-width:500px){.meth-pd-cards{grid-template-columns:1fr}}.meth-pd-card{background:var(--accent-soft);border:1px solid var(--border);border-radius:12px;padding:14px 16px}.meth-pd-card-label{text-transform:uppercase;letter-spacing:.08em;color:var(--muted);margin-bottom:6px;font-family:JetBrains Mono,monospace;font-size:10px;font-weight:700}.meth-pd-card-text{color:var(--text);font-size:13px;line-height:1.55}.meth-pd-axes{grid-template-columns:repeat(2,1fr);gap:14px;display:grid}@media(max-width:600px){.meth-pd-axes{grid-template-columns:1fr}}.meth-ax{flex-direction:column;gap:5px;display:flex}.meth-ax-label{color:var(--text);justify-content:space-between;font-size:11px;font-weight:600;display:flex}.meth-ax-label span:last-child{color:var(--muted);font-family:JetBrains Mono,monospace}.meth-ax-track{background:var(--border);border-radius:3px;height:6px;overflow:hidden}.meth-ax-fill{background:var(--pa,var(--accent));border-radius:3px;height:100%;transition:width .5s cubic-bezier(.16,1,.3,1)}.meth-bottom{border-top:1px solid var(--border);background:var(--bg);flex-wrap:wrap;flex-shrink:0;justify-content:space-between;align-items:center;gap:12px;padding:12px 22px;display:flex}.meth-bottom-note{color:var(--muted);max-width:50ch;font-size:11px;line-height:1.5}.meth-dot-nav{align-items:center;gap:6px;display:flex}.meth-dot{background:var(--border);cursor:pointer;border:none;border-radius:50%;width:8px;height:8px;transition:all .2s}.meth-dot.active{background:var(--accent);box-shadow:0 0 6px rgba(var(--accent-rgb),.25)}.meth-dot:hover{background:var(--accent)}@supports (color:color-mix(in lab,red,red)){.meth-dot:hover{background:color-mix(in srgb,var(--accent) 50%,var(--border))}}@media(prefers-reduced-motion:reduce){.meth-reveal{opacity:1!important;transition:none!important;transform:none!important}.meth-scroll-arrow{animation:none!important}}.card-label{text-transform:uppercase;letter-spacing:.05em;color:var(--muted);margin-bottom:8px;font-size:12px;font-weight:600}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@keyframes spin{to{transform:rotate(360deg)}}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import{i as Se}from"./theme.CbYAaQI4.js";let b={},P="both",R="both",Z=null,re={};const O=document.getElementById("sourceBar"),de="dashboard-source-filter",ee={both:"All",claude_code:"Claude Code",codex:"Codex",copilot_chat:"Copilot Chat",cursor:"Cursor",lmstudio:"LM Studio"},W={claude_code:"#e67e22",codex:"#a855f7",copilot_chat:"#06b6d4",cursor:"#3b82f6",lmstudio:"#22c55e"};function G(e){return ee[e]||e.replace(/_/g," ").replace(/\b\w/g,t=>t.toUpperCase())}function X(e){return Math.round(Number(e)||0).toLocaleString()}function se(e){const t=Number(e)||0;if(t<1e6)return Math.round(t).toLocaleString();if(t<1e9){const o=t/1e6;return(o>=100?Math.round(o):o.toFixed(1).replace(/\.0$/,""))+"M"}const n=t/1e9;return(n>=100?Math.round(n):n.toFixed(1).replace(/\.0$/,""))+"B"}function te(e){const t=Number(e)||0;return`${t%12||12}${t<12?"am":"pm"}`}function xe(e){if(!e||!e.first||!e.last)return"2025";const t=new Date(e.first),n=new Date(e.last),o={month:"short",day:"2-digit",year:"numeric"};return`${t.toLocaleDateString("en-US",o)} – ${n.toLocaleDateString("en-US",o)}`}const ue={"The Architect":"/images/card_architect.png","The Explorer":"/images/card_explorer.png","The Commander":"/images/card_commander.png","The Partner":"/images/card_partner.png"},_e=125.66;function me(e,t,n){const o=document.getElementById(e),s=document.getElementById(t),a=Math.round(n??0);if(o){const c=_e*(1-Math.min(a,100)/100);o.setAttribute("stroke-dashoffset",String(c))}s&&(s.textContent=a)}function Be(e,t,n,o){const s=document.getElementById("cardTop"),a=e.name||"The Explorer";s&&(s.style.backgroundImage=`url('${ue[a]||ue["The Explorer"]}')`);const c=document.getElementById("personaName");c&&(c.textContent=a);const g=document.getElementById("personaDescription");g&&(g.textContent=e.description||"Not enough data."),me("donutDetail","valDetail",e.detail_score),me("donutStyle","valStyle",e.style_score);const l=t?.vibe_coder_index?.avg_score,m=l!=null?100-l:null,d=t?.politeness?.avg_score,i=r=>document.getElementById(r);i("cardVibe")&&(i("cardVibe").textContent=m!=null?Math.round(m):"--"),i("cardPolite")&&(i("cardPolite").textContent=d!=null?Math.round(d):"--"),i("cardVibeBar")&&(i("cardVibeBar").style.width=`${Math.min(m??0,100)}%`),i("cardPoliteBar")&&(i("cardPoliteBar").style.width=`${Math.min(d,100)}%`);const p=i("cardSerial");if(p){const r=String(Math.abs((e.name||"").split("").reduce((v,x)=>(v<<5)-v+x.charCodeAt(0),0))%1e4).padStart(4,"0");p.textContent=`#${r}`}}function Le(e){const t=Array.isArray(e)?e:[],n=document.getElementById("heatmapGrid");if(!n)return;const o=n.closest(".heatmap-panel");o&&o.style.setProperty("--heatmap-color",ne());let s=o?.querySelector(".heatmap-tooltip");!s&&o&&(s=document.createElement("div"),s.className="heatmap-tooltip",o.appendChild(s));const a=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"];n.innerHTML="";const c=document.createElement("div");n.appendChild(c);for(let l=0;l<24;l++){const m=document.createElement("div");m.className="heatmap-hour",m.textContent=l%3===0?String(l):"",n.appendChild(m)}const g=Math.max(1,...t.flat());a.forEach((l,m)=>{const d=document.createElement("div");d.className="heatmap-label",d.textContent=l,n.appendChild(d),(t[m]||[]).forEach((i,p)=>{const r=document.createElement("div");if(r.className="heatmap-cell",i>0){const v=Math.ceil(i/g*5);r.classList.add("l"+Math.min(v,5))}r.setAttribute("aria-label",`${l} ${te(p)}: ${i} prompt${i!==1?"s":""}`),r.dataset.day=l,r.dataset.hour=p,r.dataset.count=i,n.appendChild(r)})}),s&&(n.onmouseover=l=>{const m=l.target.closest(".heatmap-cell");if(!m){s.style.opacity="0";return}const{day:d,hour:i,count:p}=m.dataset;s.textContent=`${d} ${te(i)} — ${p} prompt${p!=="1"?"s":""}`;const r=m.getBoundingClientRect(),v=o.getBoundingClientRect();let x=r.left-v.left+r.width/2;x=Math.max(60,Math.min(x,v.width-60)),s.style.left=x+"px",s.style.top=r.top-v.top-30+"px",s.style.opacity="1"},n.onmouseleave=()=>{s.style.opacity="0"})}let M={},D="vibe";const Ie={vibe:{key:"vibe_coder_index",label:"Vibe Coder Index",suffix:"/100",desc:"How much you vibe-code. Higher = more intent-driven, less spec-heavy.",invert:!0},polite:{key:"politeness",label:"Politeness",suffix:"/100",desc:"How collaborative your tone is. Higher = warmer, more appreciative prompting style."},activity:{key:"_prompts",label:"Activity",suffix:"/wk",desc:"Prompts per week."}};function Me(e,t){return e.map(n=>t==="_prompts"?n.prompts??null:n.nlp&&n.nlp[t]!=null?Math.round(n.nlp[t]):null)}function ne(){const e=W[R];return e||getComputedStyle(document.documentElement).getPropertyValue("--accent").trim()||"#5c3d2e"}function $e(e){return getComputedStyle(document.documentElement).getPropertyValue(e).trim()}let N=null;function fe(e){const t=e?.trends||{},n=t?.weekly_rollups||[];if(n.length<2)return;const o=t?.weekly_by_platform||{},s=Object.keys(o).length>0,a=document.getElementById("trendChart"),c=document.getElementById("trendVal"),g=document.getElementById("trendLabel"),l=document.getElementById("trendMetricDef");if(!a)return;const m=n.map((f,u)=>{const C=new Date(f.week_start||f.date),w=C.toLocaleDateString("en-US",{month:"short",day:"numeric"}),S=u>0?new Date(n[u-1].week_start||n[u-1].date):null;return u===0||!S||S.getFullYear()!==C.getFullYear()?`${w} '${String(C.getFullYear()).slice(-2)}`:w}),d=e.nlp||{},i=n.length>0?Math.round(n.reduce((f,u)=>f+u.prompts,0)/n.length):null,p={vibe:d.vibe_coder_index?.avg_score,polite:d.politeness?.avg_score,activity:i};M={};for(const[f,u]of Object.entries(Ie)){const C=Me(n,u.key),w=u.invert?C.map(E=>E!=null?100-E:null):C;if(w.some(E=>E!=null)){const E=p[f],T={points:w.map(z=>z??0),label:u.label,desc:u.desc,suffix:u.suffix,lifetime:u.invert&&E!=null?100-E:E};if(s){const z=n.map(L=>L.week_start);T.platforms={};for(const[L,B]of Object.entries(o)){const V=new Map(B.map(_=>[_.week_start,_])),q=z.map(_=>{const A=V.get(_);if(!A)return 0;if(u.key==="_prompts")return A.prompts??0;if(A.nlp&&A.nlp[u.key]!=null){const le=Math.round(A.nlp[u.key]);return u.invert?100-le:le}return 0});q.some(_=>_!=null&&_!==0)&&(T.platforms[L]=q)}}M[f]=T}}M[D]||(D=Object.keys(M)[0]||"vibe");function r(f){const u=M[f];if(!u)return{series:[],colors:[]};if(u.platforms&&Object.keys(u.platforms).length>1){const w=[],S=[];for(const[E,T]of Object.entries(u.platforms))w.push({name:ee[E]||E,data:T.map(z=>z??0)}),S.push(W[E]||"#666666");return{series:w,colors:S,showLegend:!0}}else return{series:[{name:u.label,data:u.points}],colors:[ne()],showLegend:!1}}const v=document.documentElement.classList.contains("dark"),x=$e("--muted")||"#888",$=r(D),h=M[D]?.suffix||"",y={chart:{type:"area",height:220,fontFamily:"'DM Sans', system-ui, sans-serif",toolbar:{show:!1},zoom:{enabled:!1},background:"transparent",animations:{enabled:!0,easing:"easeinout",speed:400}},stroke:{curve:"smooth",width:2.5},fill:{type:"gradient",gradient:{shadeIntensity:1,opacityFrom:.35,opacityTo:.02,stops:[0,95]}},colors:$.colors,series:$.series,xaxis:{categories:m,labels:{style:{colors:x,fontSize:"11px"},rotate:0,hideOverlappingLabels:!0},tickAmount:7,axisBorder:{show:!1},axisTicks:{show:!1}},yaxis:{show:!1,min:0},grid:{show:!1,padding:{left:28,right:28,top:-8,bottom:0}},legend:{show:!1},tooltip:{shared:!0,intersect:!1,theme:v?"dark":"light",y:{formatter:f=>f!=null?Math.round(f)+h:"--"},style:{fontSize:"12px",fontFamily:"'JetBrains Mono', monospace"}},dataLabels:{enabled:!1}};N&&(N.destroy(),N=null),N=new ApexCharts(a,y),N.render();function k(f){if(!M[f])return;D=f;const u=M[f],C=u.lifetime!=null?Math.round(u.lifetime):u.points[u.points.length-1];c.textContent=(f==="activity"?se(C):C)+u.suffix,g.textContent="",l&&(l.textContent=u.desc||"");const w=c.closest(".trend-panel");w&&w.style.setProperty("--trend-color",ne()),document.querySelectorAll(".metric-tab").forEach(B=>B.classList.toggle("active",B.dataset.metric===f));const{series:S,colors:E,showLegend:T}=r(f),z=u.suffix||"",L=document.getElementById("trendLegend");if(L)if(L.innerHTML="",T){for(const B of S){const V=Object.entries(ee).find(([,A])=>A===B.name)?.[0],q=V?W[V]:"#666",_=document.createElement("span");_.className="trend-legend-pill",_.innerHTML=`<span class="trend-legend-dot" style="background:${q}"></span>${B.name}`,L.appendChild(_)}L.style.display=""}else L.style.display="none";N.updateOptions({colors:E,tooltip:{y:{formatter:B=>B!=null?Math.round(B)+z:"--"}}},!1,!1),N.updateSeries(S)}document.querySelectorAll(".metric-tab").forEach(f=>{f.addEventListener("click",()=>k(f.dataset.metric))}),k(D)}function Te(){const e=document.getElementById("playerCard"),t=e?.closest(".card-dock");if(!e||!t)return;const n=12;t.addEventListener("mousemove",o=>{const s=t.getBoundingClientRect(),a=(o.clientX-s.left)/s.width,c=(o.clientY-s.top)/s.height;e.style.transform=`rotateY(${(a-.5)*n}deg) rotateX(${(.5-c)*n}deg)`}),t.addEventListener("mouseleave",()=>{e.style.transform=""})}function ge(e){return b[e]||null}function ze(){return Object.keys(b).filter(e=>e==="both"||!!ge(e)).sort((e,t)=>e==="both"?1:t==="both"?-1:G(e).localeCompare(G(t)))}function he(e){const t=ge(e);if(!t)return;R=e,Z=t;const n=t.volume||{},o=t.temporal||{},s=t.conversation_depth||{};t.politeness;const a=t.persona||{},c=h=>document.getElementById(h),g=c("dateRange");g&&(g.textContent=xe(t.date_range));const l=c("promptsValue");l&&(l.textContent=X(n.total_human));const m=c("promptsSubtitle");m&&(m.textContent=`${X(n.avg_words_per_prompt)} words avg`);const d=c("conversationsValue");d&&(d.textContent=X(n.total_conversations));const i=c("conversationsSubtitle");i&&(i.textContent=`${s.avg_turns??0} turns avg`);const p=c("wordsTypedValue");p&&(p.textContent=se(n.total_words_human));const r=c("wordsTypedSubtitle");r&&(r.textContent=`${n.avg_words_per_prompt??0} words avg`);const v=c("nightOwlValue");v&&(v.textContent=`${o.night_owl_pct??0}%`);const x=c("peakHourValue");x&&(x.textContent=te(o.peak_hour));const $=c("peakDayValue");$&&($.textContent=o.peak_day||"N/A"),Be(a,t.nlp||{}),Le(o.heatmap),fe(t)}function ae(){if(!O)return;const e=ze();O.innerHTML="";for(const o of e){const s=document.createElement("button");s.className="source-pill",s.dataset.source=o;const a=W[o];if(a){const g=document.createElement("span");g.className="source-pill-dot",g.style.background=a,s.appendChild(g)}const c=document.createTextNode(G(o));s.appendChild(c),O.appendChild(s)}let t=localStorage.getItem(de)||P;t==="claude"&&e.includes("claude_code")&&(t="claude_code"),(t==="both"||!e.includes(t))&&(t=e.find(o=>o!=="both")||e[0]||"both");function n(o){O.querySelectorAll(".source-pill").forEach(s=>{s.classList.toggle("active",s.dataset.source===o)}),localStorage.setItem(de,o),he(o)}O.addEventListener("click",o=>{const s=o.target.closest(".source-pill");s&&n(s.dataset.source)}),n(t)}let F=null;function Ae(){const e=document.getElementById("methodologyModal");if(e){F=document.activeElement,e.classList.add("active"),document.body.style.overflow="hidden";const t=e.querySelector(".modal-close");t&&t.focus()}}function ce(){const e=document.getElementById("methodologyModal");e&&(e.classList.remove("active"),document.body.style.overflow="",F&&(F.focus(),F=null))}window.openMethodology=Ae;window.closeMethodology=ce;let J=null,U=null,j=null;function oe(){return Array.isArray(H)&&H.length>0?H:Array.isArray(U)&&U.length>0?U:[]}function ye(e){const t=Array.isArray(e)?e:[];return U=t,t.length>0&&(H=t),t}function Ne(e=[],t=[],n=[]){const o=new Map((e||[]).map(c=>[c.id,c])),s=new Set(n),a={};for(const c of t||[]){const g=o.get(c.id);if(!g){s.has(c.id)||(a[c.id]="New");continue}(g.status!==c.status||g.detected!==c.detected)&&(a[c.id]="Updated")}return a}async function be(e={}){const{useCache:t=!0,force:n=!1}=e;if(!n){const o=oe();if(t&&o.length>0)return o;if(j)return j}return j=fetch("/api/detect").then(o=>o.json()).then(o=>ye(o.backends||[])).catch(()=>oe()).finally(()=>{j=null}),j}function pe(e={},t=[],n={}){const{isRefreshing:o=!1,badges:s={}}=n,a=document.getElementById("settingsBackends");if(!a)return;const c=new Map((t||[]).map(l=>[l.id,l])),g=Array.from(new Set([...Object.keys(e.backends||{}),...Array.from(c.keys())]));if(g.length===0){a.innerHTML=`<div class="wizard-loading">${o?"Checking installed backends…":"No backend settings yet."}</div>`;return}a.innerHTML=g.map(l=>{const m=e.backends?.[l]||{enabled:!1},d=c.get(l),i=d?d.supported===!1||d.status==="coming_soon"||d.status==="not_found":!1;let p=o?"Checking installation...":"Saved configuration";d?.status==="available"&&(p="Ready to analyze"),d?.status==="coming_soon"&&(p="Detected, but analysis support is not shipped yet"),d?.status==="not_found"&&(p="Not installed");const r=s[l]?`<span class="settings-backend-badge">${s[l]}</span>`:"";return`<div class="settings-backend-row">
|
|
2
|
+
<label class="wizard-toggle ${i?"is-disabled":""}">
|
|
3
|
+
<input type="checkbox" data-backend="${l}" ${m.enabled!==!1?"checked":""} ${i?"disabled":""}>
|
|
4
|
+
<span class="settings-backend-title">${G(l)}${r}</span>
|
|
5
|
+
</label>
|
|
6
|
+
<div class="settings-backend-detail">${p}</div>
|
|
7
|
+
</div>`}).join("")}async function Pe(){const e=document.getElementById("settingsModal");if(!e)return;J=document.activeElement,e.classList.add("active"),document.body.style.overflow="hidden";const t=await fetch("/api/config").then(s=>s.json()).catch(()=>({})),n=oe();pe(t,n,{isRefreshing:!0});const o=document.getElementById("settingsExclusionSection");if(o&&t.backends?.claude_code){o.style.display="block";const s=t.backends.claude_code.exclusions??[];Ce("settingsExclusionChips",s)}be({force:!0}).then(s=>{if(!document.getElementById("settingsModal")?.classList.contains("active"))return;const c=[...n.map(l=>l.id),...Object.keys(t.backends||{})],g=Ne(n,s,c);pe(t,s,{isRefreshing:!1,badges:g})}).catch(()=>{})}function Y(){const e=document.getElementById("settingsModal");e&&(e.classList.remove("active"),document.body.style.overflow="",J&&(J.focus(),J=null))}async function De(){if(document.querySelectorAll("#settingsBackends input[type=checkbox]:checked").length===0){alert("Please enable at least one backend to analyze.");return}const t={};document.querySelectorAll("#settingsBackends input[type=checkbox]").forEach(n=>{t[n.dataset.backend]={enabled:n.checked,exclusions:[]}}),t.claude_code&&(t.claude_code.exclusions=ke("settingsExclusionChips")),await fetch("/api/config",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({backends:t})}),Y(),je()}window.openSettings=Pe;window.closeSettings=Y;document.getElementById("settingsAddExclusion")?.addEventListener("click",()=>we("settingsExclusionChips"));document.getElementById("settingsSave")?.addEventListener("click",De);document.getElementById("settingsReset")?.addEventListener("click",()=>{document.getElementById("resetConfirmModal")?.classList.add("active")});document.getElementById("resetCancel")?.addEventListener("click",()=>{document.getElementById("resetConfirmModal")?.classList.remove("active")});document.getElementById("resetConfirm")?.addEventListener("click",async()=>{await fetch("/api/reset",{method:"POST"}),window.location.reload()});document.getElementById("settingsModal")?.addEventListener("click",e=>{e.target===e.currentTarget&&Y()});document.getElementById("methodologyModal")?.addEventListener("click",e=>{e.target===e.currentTarget&&ce()});document.addEventListener("keydown",e=>{e.key==="Escape"&&(ce(),Y());const t=document.getElementById("methodologyModal");if(e.key==="Tab"&&t?.classList.contains("active")){const n=t.querySelectorAll('button, [href], [tabindex]:not([tabindex="-1"])');if(n.length===0)return;const o=n[0],s=n[n.length-1];e.shiftKey&&document.activeElement===o?(e.preventDefault(),s.focus()):!e.shiftKey&&document.activeElement===s&&(e.preventDefault(),o.focus())}});function Oe(){(location.protocol==="file:"||location.hostname==="localhost"||location.hostname==="127.0.0.1")&&document.querySelectorAll('a[href="/wrapped"]').forEach(t=>{const n=location.pathname,o=n.substring(0,n.lastIndexOf("/"));t.href=o+"/wrapped/index.html"})}function ve(e){re=e.branding||{};const t=re.github_repo||"https://github.com/eeshansrivastava89/howiprompt",n=document.getElementById("footerGithubLink");n&&(n.href=t)}let K=!1;async function je(){if(K)return;K=!0;const e=document.getElementById("refreshModal"),t=document.getElementById("refreshLog"),n=document.getElementById("refreshProgressBar"),o=document.getElementById("refreshModalResult"),s=document.getElementById("refreshModalClose");e&&(t&&(t.innerHTML='<div class="wizard-log-entry">Starting pipeline...</div>'),n&&(n.style.width="0"),o.style.display="none",s.style.display="none",e.classList.add("active"),document.body.style.overflow="hidden");const a=d=>{o&&(o.innerHTML=d,o.style.display="block",s.style.display="inline-block",s.focus()),K=!1},c=["sync","parse","insert","nlp","embedding","classifiers","metrics"];let g=0,l=!1;const m=new EventSource("/api/pipeline/stream");m.addEventListener("progress",d=>{const i=JSON.parse(d.data);if(t){const r=document.createElement("div");r.className="wizard-log-entry",r.textContent=`${i.stage}: ${i.detail}`,t.appendChild(r),t.scrollTop=t.scrollHeight}const p=c.indexOf(i.stage);p>=0&&p>g&&(g=p),n&&(n.style.width=`${(g+1)/c.length*100}%`)}),m.addEventListener("complete",d=>{l=!0,m.close();const i=JSON.parse(d.data);if(n&&(n.style.width="100%"),t){const v=document.createElement("div");v.className="wizard-log-entry done",v.textContent=`Done! ${i.stats.totalMessages.toLocaleString()} messages analyzed.`,t.appendChild(v),t.scrollTop=t.scrollHeight}i.metrics&&(b=i.metrics.source_views||{both:i.metrics},!b.claude_code&&b.claude&&(b.claude_code=b.claude),b.both=b.both||i.metrics,b[R]||(R="both"),ae(),he(R));const p=[],r=i.stats;r.newMessages>0?p.push(`<span class="result-num">${r.newMessages}</span> new message${r.newMessages===1?"":"s"} synced`):p.push("Already up to date"),p.push(`<span class="result-num">${se(r.totalMessages)}</span> total messages`),r.embedded>0&&p.push(`<span class="result-num">${r.embedded}</span> embeddings computed`),a(p.join("<br>"))}),m.addEventListener("pipeline_error",d=>{l=!0,m.close();const i=JSON.parse(d.data);a(`Refresh failed: ${i.message}`)}),m.onerror=()=>{l||(m.close(),a("Refresh failed — is the server running?"))}}document.getElementById("refreshModalClose")?.addEventListener("click",()=>{const e=document.getElementById("refreshModal");e&&(e.classList.remove("active"),document.body.style.overflow="")});let H=[];const I=[{key:"boot",label:"Prepare"},{key:"sync",label:"Sync Sources"},{key:"parse",label:"Parse Chats"},{key:"insert",label:"Store Messages"},{key:"nlp",label:"Language Scores"},{key:"embedding",label:"Embeddings"},{key:"classifiers",label:"Behavior Scores"},{key:"metrics",label:"Build Dashboard"}],Q=Object.fromEntries(I.map((e,t)=>[e.key,t]));function Re(){const e=document.getElementById("wizardLog"),t=document.getElementById("wizardProgressBar"),n=document.getElementById("wizardProgressLabel"),o=document.getElementById("wizardProgressPct"),s=document.getElementById("wizardStageList"),a=Object.fromEntries(I.map(({key:h},y)=>[h,{key:h,label:I[y].label,detail:"Waiting...",progress:0,status:"pending"}]));let c="boot",g=null,l=!1;function m(){const h=I.reduce((y,{key:k})=>y+(a[k].progress||0),0)/I.length;if(t&&(t.style.width=`${Math.round(h)}%`),n){const y=a[c]||a.boot;n.textContent=y?.detail||"Preparing analysis..."}o&&(o.textContent=`${Math.round(h)}%`),s&&(s.innerHTML=I.map(({key:y,label:k})=>{const f=a[y];return`
|
|
8
|
+
<div class="wizard-stage-row">
|
|
9
|
+
<div class="wizard-stage-name">${k}</div>
|
|
10
|
+
<div class="wizard-stage-track is-${f.status}">
|
|
11
|
+
<div class="wizard-stage-fill" style="width:${f.progress}%"></div>
|
|
12
|
+
<span class="wizard-stage-detail">${f.detail}</span>
|
|
13
|
+
</div>
|
|
14
|
+
<div class="wizard-stage-value">${Math.round(f.progress)}%</div>
|
|
15
|
+
</div>
|
|
16
|
+
`}).join(""))}function d(){g&&(clearInterval(g),g=null)}function i(h){d(),g=window.setInterval(()=>{if(l||c!==h)return;const y=a[h],k=h==="embedding"||h==="classifiers"?95:88;y.progress>=k||(y.progress=Math.min(k,y.progress+(y.progress<30?3:1)),m())},450)}function p(h,y="normal"){if(!e)return;const k=document.createElement("div");k.className=`wizard-log-entry${y==="done"?" done":y==="error"?" error":""}`,k.textContent=h,e.appendChild(k),e.scrollTop=e.scrollHeight}function r(){e&&(e.innerHTML="");for(const{key:h}of I)a[h].detail="Waiting...",a[h].progress=0,a[h].status="pending";c="boot",a.boot.detail="Connecting to local pipeline...",a.boot.progress=5,a.boot.status="active",l=!1,p("Starting pipeline..."),i("boot"),m()}function v(h,y,k){const f=Q[h]!=null?h:"boot",u=Q[f],C=Q[c]??0;if(u>C)for(let S=C;S<u;S++){const E=I[S].key;a[E].status="done",a[E].progress=100}c=f;const w=a[f];w.status="active",w.detail=y,typeof k=="number"&&Number.isFinite(k)?w.progress=Math.max(w.progress,Math.min(100,k)):w.progress=Math.max(w.progress,12),p(`${f}: ${y}`),i(f),m()}function x(h){l=!0,d();for(const{key:y}of I)a[y].status="done",a[y].progress=100,a[y].detail==="Waiting..."&&(a[y].detail="Done");c="metrics",a.metrics.detail="Dashboard ready.",p(`Done! ${Number(h||0).toLocaleString()} messages analyzed.`,"done"),m()}function $(h){l=!0,d();const y=a[c]||a.boot;y.status="error",y.detail=h,p(`Error: ${h}`,"error"),m()}return{begin:r,advance:v,finish:x,fail:$}}async function He(){const e=document.getElementById("setupWizard");if(!e)return!1;let t=!1;try{t=(await fetch("./metrics.json")).ok}catch{}if(t)return fetch("/api/config",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({hasCompletedSetup:!0})}).catch(()=>{}),!1;let n;try{const o=await fetch("/api/config");o.ok&&(n=await o.json())}catch{}return n?.hasCompletedSetup&&t?!1:(e.classList.add("active"),document.body.style.overflow="hidden",await Ve(),!0)}async function Ve(){const e=document.getElementById("wizardBackends");if(e)try{const t=await fetch("/api/detect"),{backends:n}=await t.json();ye(n),e.innerHTML=n.map(o=>{let s="";return o.status==="available"?s="Detected locally":o.status==="coming_soon"?s="Detected (coming soon)":s="Not installed",`
|
|
17
|
+
<div class="wizard-backend ${o.detected?"detected":""}" data-id="${o.id}">
|
|
18
|
+
<div class="wizard-backend-icon ${o.status}"></div>
|
|
19
|
+
<div class="wizard-backend-info">
|
|
20
|
+
<div class="wizard-backend-name">${o.name}</div>
|
|
21
|
+
<div class="wizard-backend-detail">${s}</div>
|
|
22
|
+
</div>
|
|
23
|
+
</div>`}).join("")}catch{e.innerHTML='<div class="wizard-loading">Could not detect backends.</div>'}}async function we(e){const t=document.getElementById(e);if(!t)return;let n;try{n=(await(await fetch("/api/pick-directory")).json()).path}catch{return}if(!n||t.querySelector(`[data-path="${CSS.escape(n)}"]`))return;let o=0;try{o=(await(await fetch("/api/exclusion-count",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:n})})).json()).messageCount||0}catch{}Ee(t,n,o)}function Ee(e,t,n){const o=document.createElement("div");o.className="exclusion-chip",o.dataset.path=t;const s=t.split("/").pop()||t,a=n>0?`${n.toLocaleString()} messages`:"no data found";o.innerHTML=`
|
|
24
|
+
<span class="exclusion-chip-path" title="${t}">${s}</span>
|
|
25
|
+
<span class="exclusion-chip-count">${a}</span>
|
|
26
|
+
<button class="exclusion-chip-remove" type="button" aria-label="Remove">×</button>
|
|
27
|
+
`,o.querySelector(".exclusion-chip-remove").addEventListener("click",()=>o.remove()),e.appendChild(o)}function ke(e){const t=document.getElementById(e);return t?[...t.querySelectorAll(".exclusion-chip")].map(n=>n.dataset.path):[]}async function Ce(e,t){const n=document.getElementById(e);if(n){n.innerHTML="";for(const o of t){let s=0;try{s=(await(await fetch("/api/exclusion-count",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({path:o})})).json()).messageCount||0}catch{}Ee(n,o,s)}}}function qe(){const e=document.getElementById("wizardConfig"),t=document.getElementById("wizardExclusions");if(!e)return;const n=H.filter(o=>o.status==="available"&&o.supported!==!1);fetch("/api/config").then(o=>o.json()).then(o=>{e.innerHTML=n.map(s=>{const a=o.backends?.[s.id],c=a?a.enabled!==!1:!0;return`
|
|
28
|
+
<label class="wizard-toggle">
|
|
29
|
+
<input type="checkbox" data-backend="${s.id}" ${c?"checked":""}>
|
|
30
|
+
${s.name}
|
|
31
|
+
</label>
|
|
32
|
+
`}).join(""),n.some(s=>s.id==="claude_code")&&t?(t.style.display="block",Ce("wizardExclusionChips",o.backends?.claude_code?.exclusions??[])):t&&(t.style.display="none")}).catch(()=>{e.innerHTML=n.map(o=>`
|
|
33
|
+
<label class="wizard-toggle">
|
|
34
|
+
<input type="checkbox" data-backend="${o.id}" checked>
|
|
35
|
+
${o.name}
|
|
36
|
+
</label>
|
|
37
|
+
`).join("")})}async function Fe(){const e={};document.querySelectorAll("#wizardConfig input[type=checkbox]").forEach(t=>{e[t.dataset.backend]={enabled:t.checked,exclusions:[]}}),e.claude_code&&(e.claude_code.exclusions=ke("wizardExclusionChips"));try{await fetch("/api/config",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({backends:e})})}catch{}}function Je(){const e=document.getElementById("wizardDone"),t=Re();let n=!1;t.begin();const o=new EventSource("/api/pipeline/stream");o.addEventListener("progress",s=>{const a=JSON.parse(s.data);t.advance(a.stage,a.detail,a.progress)}),o.addEventListener("complete",s=>{n=!0,o.close();const a=JSON.parse(s.data);t.finish(a.stats.totalMessages),e&&(e.style.display="inline-block"),a.metrics&&(b=a.metrics.source_views||{both:a.metrics},!b.claude_code&&b.claude&&(b.claude_code=b.claude),b.both=b.both||a.metrics,P=a.metrics.default_view||"both",P==="claude"&&b.claude_code&&(P="claude_code"))}),o.addEventListener("pipeline_error",s=>{n=!0,o.close();const a=JSON.parse(s.data);t.fail(a.message),e&&(e.textContent="Continue Anyway",e.style.display="inline-block")}),o.onerror=()=>{n||(o.close(),t.fail("Connection lost — check terminal for details."),e&&(e.textContent="Continue Anyway",e.style.display="inline-block"))}}function ie(e){document.querySelectorAll(".wizard-step").forEach(t=>{const n=Number(t.dataset.step);t.classList.toggle("active",n===e),t.classList.toggle("done",n<e)}),document.querySelectorAll(".wizard-page").forEach(t=>t.classList.remove("active")),document.getElementById(`wizardStep${e}`)?.classList.add("active")}document.getElementById("wizardAddExclusion")?.addEventListener("click",()=>we("wizardExclusionChips"));document.getElementById("wizardNext1")?.addEventListener("click",()=>{qe(),ie(2)});document.getElementById("wizardBack2")?.addEventListener("click",()=>ie(1));document.getElementById("wizardNext2")?.addEventListener("click",async()=>{if(document.querySelectorAll("#wizardConfig input[type=checkbox]:checked").length===0){alert("Please enable at least one backend to analyze.");return}await Fe(),ie(3),Je()});document.getElementById("wizardDone")?.addEventListener("click",async()=>{try{await fetch("/api/config",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({hasCompletedSetup:!0})})}catch{}const e=document.getElementById("setupWizard");e&&(e.classList.remove("active"),document.body.style.overflow=""),ve({}),ae()});async function Ue(){if(Se(),Oe(),Te(),document.getElementById("themeToggle")?.addEventListener("click",()=>{requestAnimationFrame(()=>{Z&&fe(Z)})}),!await He()){be({useCache:!0}).catch(()=>{});try{const t=await fetch("./metrics.json");if(!t.ok)throw new Error(`HTTP ${t.status}`);const n=await t.json();b=n.source_views||{both:n},!b.claude_code&&b.claude&&(b.claude_code=b.claude),b.both=b.both||n,P=n.default_view||"both",P==="claude"&&b.claude_code&&(P="claude_code"),ve(n),ae()}catch(t){console.warn("Could not load metrics.json:",t.message)}}}Ue();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./wrapped.astro_astro_type_script_index_1_lang.CPAAJDh5.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function o(t="hip-theme"){const e=document.documentElement,a=document.getElementById("themeToggle");if(!a)return;const c=localStorage.getItem(t);(c==="dark"||!c&&window.matchMedia("(prefers-color-scheme: dark)").matches)&&e.classList.add("dark"),a.addEventListener("click",()=>{e.classList.toggle("dark"),localStorage.setItem(t,e.classList.contains("dark")?"dark":"light")})}export{o as i};
|