aura-ui-library 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/dist/index.js +3706 -0
  2. package/dist/index.mjs +3674 -0
  3. package/package.json +28 -0
package/dist/index.mjs ADDED
@@ -0,0 +1,3674 @@
1
+ // src/components/Button/MagneticButton.jsx
2
+ import React, { useState, useEffect, useRef, useCallback } from "react";
3
+ var injectStyles = () => {
4
+ const id = "mb-global-v2";
5
+ if (document.getElementById(id)) return;
6
+ const s = document.createElement("style");
7
+ s.id = id;
8
+ s.innerHTML = `
9
+ @import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:wght@300;400;500&display=swap');
10
+
11
+ .mb-root *, .mb-root *::before, .mb-root *::after { box-sizing: border-box; margin: 0; padding: 0; }
12
+
13
+ @keyframes mb-reveal { from { opacity:0; transform:translateY(18px) scale(.97); } to { opacity:1; transform:translateY(0) scale(1); } }
14
+ @keyframes mb-shimmer { from { transform:translateX(-120%) skewX(-15deg); } to { transform:translateX(220%) skewX(-15deg); } }
15
+ @keyframes mb-spin { to { transform:rotate(360deg); } }
16
+ @keyframes mb-tick { 0%{stroke-dashoffset:24} 100%{stroke-dashoffset:0} }
17
+ @keyframes mb-burst { 0%{transform:scale(0) translate(-50%,-50%);opacity:1} 100%{transform:scale(2.8) translate(-50%,-50%);opacity:0} }
18
+ @keyframes mb-particle { 0%{opacity:1;transform:translate(0,0) scale(1)} 100%{opacity:0;transform:var(--tx,0) var(--ty,0) scale(0)} }
19
+ @keyframes mb-pulse-ring{ 0%{transform:scale(1);opacity:.6} 100%{transform:scale(1.9);opacity:0} }
20
+ @keyframes mb-float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-6px)} }
21
+ @keyframes mb-error-shake{ 0%,100%{transform:translateX(0)} 20%,60%{transform:translateX(-5px)} 40%,80%{transform:translateX(5px)} }
22
+
23
+ @media (prefers-reduced-motion: reduce) {
24
+ .mb-root, .mb-root * { animation: none !important; transition: none !important; }
25
+ }
26
+ `;
27
+ document.head.appendChild(s);
28
+ };
29
+ var PRESETS = {
30
+ obsidian: {
31
+ bg: "linear-gradient(135deg,#1a1a2e,#16213e)",
32
+ glow: "rgba(99,102,241,.55)",
33
+ border: "rgba(99,102,241,.25)",
34
+ text: "#fff",
35
+ shimmer: "rgba(255,255,255,.12)"
36
+ },
37
+ crimson: {
38
+ bg: "linear-gradient(135deg,#7f0000,#c0392b)",
39
+ glow: "rgba(231,76,60,.6)",
40
+ border: "rgba(231,76,60,.3)",
41
+ text: "#fff",
42
+ shimmer: "rgba(255,255,255,.15)"
43
+ },
44
+ aurora: {
45
+ bg: "linear-gradient(135deg,#0d7377,#14a085)",
46
+ glow: "rgba(20,160,133,.6)",
47
+ border: "rgba(20,160,133,.3)",
48
+ text: "#fff",
49
+ shimmer: "rgba(255,255,255,.15)"
50
+ },
51
+ solar: {
52
+ bg: "linear-gradient(135deg,#e67e22,#f39c12)",
53
+ glow: "rgba(243,156,18,.65)",
54
+ border: "rgba(243,156,18,.3)",
55
+ text: "#1a1a1a",
56
+ shimmer: "rgba(255,255,255,.2)"
57
+ },
58
+ void: {
59
+ bg: "linear-gradient(135deg,#0f0f0f,#1a1a1a)",
60
+ glow: "rgba(255,255,255,.15)",
61
+ border: "rgba(255,255,255,.1)",
62
+ text: "#fff",
63
+ shimmer: "rgba(255,255,255,.07)"
64
+ },
65
+ neon: {
66
+ bg: "transparent",
67
+ glow: "rgba(0,255,170,.5)",
68
+ border: "rgba(0,255,170,.6)",
69
+ text: "#00ffaa",
70
+ shimmer: "rgba(0,255,170,.15)"
71
+ }
72
+ };
73
+ var SIZES = {
74
+ sm: {
75
+ padding: "9px 22px",
76
+ fontSize: "12px",
77
+ gap: 6,
78
+ iconSize: 13,
79
+ loaderSize: 13
80
+ },
81
+ md: {
82
+ padding: "13px 30px",
83
+ fontSize: "14px",
84
+ gap: 8,
85
+ iconSize: 15,
86
+ loaderSize: 15
87
+ },
88
+ lg: {
89
+ padding: "16px 40px",
90
+ fontSize: "16px",
91
+ gap: 10,
92
+ iconSize: 17,
93
+ loaderSize: 17
94
+ },
95
+ xl: {
96
+ padding: "20px 52px",
97
+ fontSize: "18px",
98
+ gap: 12,
99
+ iconSize: 20,
100
+ loaderSize: 20
101
+ }
102
+ };
103
+ var lerp = (a, b, t) => a + (b - a) * t;
104
+ var clamp = (v, mn, mx) => Math.min(Math.max(v, mn), mx);
105
+ var Loader = ({ size = 15, color = "#fff" }) => /* @__PURE__ */ React.createElement(
106
+ "svg",
107
+ {
108
+ width: size,
109
+ height: size,
110
+ viewBox: "0 0 24 24",
111
+ fill: "none",
112
+ style: { animation: "mb-spin .7s linear infinite", flexShrink: 0 }
113
+ },
114
+ /* @__PURE__ */ React.createElement(
115
+ "circle",
116
+ {
117
+ cx: "12",
118
+ cy: "12",
119
+ r: "10",
120
+ stroke: color,
121
+ strokeOpacity: ".25",
122
+ strokeWidth: "3"
123
+ }
124
+ ),
125
+ /* @__PURE__ */ React.createElement(
126
+ "path",
127
+ {
128
+ d: "M12 2a10 10 0 0 1 10 10",
129
+ stroke: color,
130
+ strokeWidth: "3",
131
+ strokeLinecap: "round"
132
+ }
133
+ )
134
+ );
135
+ var TickIcon = ({ size = 15, color = "#fff" }) => /* @__PURE__ */ React.createElement(
136
+ "svg",
137
+ {
138
+ width: size,
139
+ height: size,
140
+ viewBox: "0 0 24 24",
141
+ fill: "none",
142
+ style: { flexShrink: 0 }
143
+ },
144
+ /* @__PURE__ */ React.createElement(
145
+ "polyline",
146
+ {
147
+ points: "20 6 9 17 4 12",
148
+ stroke: color,
149
+ strokeWidth: "2.5",
150
+ strokeLinecap: "round",
151
+ strokeLinejoin: "round",
152
+ strokeDasharray: "24",
153
+ strokeDashoffset: "0",
154
+ style: { animation: "mb-tick .35s ease forwards" }
155
+ }
156
+ )
157
+ );
158
+ var XIcon = ({ size = 15, color = "#fff" }) => /* @__PURE__ */ React.createElement(
159
+ "svg",
160
+ {
161
+ width: size,
162
+ height: size,
163
+ viewBox: "0 0 24 24",
164
+ fill: "none",
165
+ style: { flexShrink: 0 }
166
+ },
167
+ /* @__PURE__ */ React.createElement(
168
+ "line",
169
+ {
170
+ x1: "18",
171
+ y1: "6",
172
+ x2: "6",
173
+ y2: "18",
174
+ stroke: color,
175
+ strokeWidth: "2.5",
176
+ strokeLinecap: "round"
177
+ }
178
+ ),
179
+ /* @__PURE__ */ React.createElement(
180
+ "line",
181
+ {
182
+ x1: "6",
183
+ y1: "6",
184
+ x2: "18",
185
+ y2: "18",
186
+ stroke: color,
187
+ strokeWidth: "2.5",
188
+ strokeLinecap: "round"
189
+ }
190
+ )
191
+ );
192
+ var Particles = ({ active, color }) => {
193
+ if (!active) return null;
194
+ const count = 8;
195
+ return /* @__PURE__ */ React.createElement(React.Fragment, null, Array.from({ length: count }).map((_, i) => {
196
+ const angle = 360 / count * i;
197
+ const dist = 40 + Math.random() * 20;
198
+ const tx = `translateX(${Math.cos(angle * Math.PI / 180) * dist}px)`;
199
+ const ty = `translateY(${Math.sin(angle * Math.PI / 180) * dist}px)`;
200
+ return /* @__PURE__ */ React.createElement(
201
+ "span",
202
+ {
203
+ key: i,
204
+ "aria-hidden": true,
205
+ style: {
206
+ "--tx": tx,
207
+ "--ty": ty,
208
+ position: "absolute",
209
+ left: "50%",
210
+ top: "50%",
211
+ width: 5,
212
+ height: 5,
213
+ borderRadius: "50%",
214
+ background: color,
215
+ pointerEvents: "none",
216
+ zIndex: 20,
217
+ animation: `mb-particle .55s cubic-bezier(.22,1,.36,1) forwards`,
218
+ animationDelay: `${i * 18}ms`
219
+ }
220
+ }
221
+ );
222
+ }));
223
+ };
224
+ var MagneticButton = ({
225
+ label = "Click Me",
226
+ preset = "obsidian",
227
+ size = "md",
228
+ variant = "solid",
229
+ leftIcon,
230
+ rightIcon,
231
+ showArrow = true,
232
+ magnetStrength = 22,
233
+ loading = false,
234
+ success = false,
235
+ error = false,
236
+ disabled = false,
237
+ float = false,
238
+ pulseRing = false,
239
+ borderRadius = "999px",
240
+ onClick,
241
+ className = "",
242
+ style: styleProp = {}
243
+ }) => {
244
+ const btnRef = useRef(null);
245
+ const wrapRef = useRef(null);
246
+ const rafRef = useRef(null);
247
+ const magnetPos = useRef({ x: 0, y: 0 });
248
+ const targetPos = useRef({ x: 0, y: 0 });
249
+ const [hovered, setHovered] = useState(false);
250
+ const [pressed, setPressed] = useState(false);
251
+ const [visible, setVisible] = useState(false);
252
+ const [shimmer, setShimmer] = useState(false);
253
+ const [burst, setBurst] = useState(false);
254
+ const [magXY, setMagXY] = useState({ x: 0, y: 0 });
255
+ const p = PRESETS[preset] ?? PRESETS.obsidian;
256
+ const sz = SIZES[size] ?? SIZES.md;
257
+ const isLocked = disabled || loading;
258
+ useEffect(() => {
259
+ injectStyles();
260
+ const t = setTimeout(() => setVisible(true), 120);
261
+ return () => clearTimeout(t);
262
+ }, []);
263
+ const animateMagnet = useCallback(() => {
264
+ magnetPos.current.x = lerp(magnetPos.current.x, targetPos.current.x, 0.12);
265
+ magnetPos.current.y = lerp(magnetPos.current.y, targetPos.current.y, 0.12);
266
+ setMagXY({ x: magnetPos.current.x, y: magnetPos.current.y });
267
+ rafRef.current = requestAnimationFrame(animateMagnet);
268
+ }, []);
269
+ const handleMouseEnter = useCallback(
270
+ (e) => {
271
+ if (isLocked) return;
272
+ setHovered(true);
273
+ rafRef.current = requestAnimationFrame(animateMagnet);
274
+ setShimmer(false);
275
+ requestAnimationFrame(() => setShimmer(true));
276
+ setTimeout(() => setShimmer(false), 700);
277
+ },
278
+ [isLocked, animateMagnet]
279
+ );
280
+ const handleMouseMove = useCallback(
281
+ (e) => {
282
+ if (isLocked || !btnRef.current) return;
283
+ const r = btnRef.current.getBoundingClientRect();
284
+ const cx = r.left + r.width / 2;
285
+ const cy = r.top + r.height / 2;
286
+ const dx = e.clientX - cx;
287
+ const dy = e.clientY - cy;
288
+ const dist = Math.sqrt(dx * dx + dy * dy);
289
+ const maxDist = Math.max(r.width, r.height);
290
+ const factor = clamp(1 - dist / maxDist, 0, 1);
291
+ targetPos.current = {
292
+ x: dx * factor * (magnetStrength / 20),
293
+ y: dy * factor * (magnetStrength / 20)
294
+ };
295
+ },
296
+ [isLocked, magnetStrength]
297
+ );
298
+ const handleMouseLeave = useCallback(() => {
299
+ setHovered(false);
300
+ setPressed(false);
301
+ targetPos.current = { x: 0, y: 0 };
302
+ const spring = () => {
303
+ magnetPos.current.x = lerp(magnetPos.current.x, 0, 0.18);
304
+ magnetPos.current.y = lerp(magnetPos.current.y, 0, 0.18);
305
+ setMagXY({ ...magnetPos.current });
306
+ if (Math.abs(magnetPos.current.x) > 0.1 || Math.abs(magnetPos.current.y) > 0.1) {
307
+ rafRef.current = requestAnimationFrame(spring);
308
+ } else {
309
+ magnetPos.current = { x: 0, y: 0 };
310
+ setMagXY({ x: 0, y: 0 });
311
+ cancelAnimationFrame(rafRef.current);
312
+ }
313
+ };
314
+ cancelAnimationFrame(rafRef.current);
315
+ rafRef.current = requestAnimationFrame(spring);
316
+ }, []);
317
+ useEffect(() => () => cancelAnimationFrame(rafRef.current), []);
318
+ const handleClick = useCallback(
319
+ (e) => {
320
+ if (isLocked) return;
321
+ setBurst(true);
322
+ setTimeout(() => setBurst(false), 600);
323
+ onClick == null ? void 0 : onClick(e);
324
+ },
325
+ [isLocked, onClick]
326
+ );
327
+ const getBackground = () => {
328
+ if (variant === "ghost") return "transparent";
329
+ if (variant === "outline") return "transparent";
330
+ return p.bg;
331
+ };
332
+ const getBorder = () => {
333
+ if (variant === "ghost") return "1px solid transparent";
334
+ if (variant === "outline")
335
+ return `1.5px solid ${p.border.replace(".3)", ".7)")}`;
336
+ return `1px solid ${p.border}`;
337
+ };
338
+ const errorAnim = error ? "mb-error-shake .4s ease" : "none";
339
+ const floatAnim = float && !hovered && !error ? "mb-float 4s ease-in-out infinite" : "none";
340
+ const wrapperStyle = {
341
+ position: "relative",
342
+ display: "inline-flex",
343
+ alignItems: "center",
344
+ justifyContent: "center",
345
+ opacity: visible ? 1 : 0,
346
+ animation: visible ? `mb-reveal .55s cubic-bezier(.22,1,.36,1) forwards` : "none"
347
+ };
348
+ const buttonStyle = {
349
+ position: "relative",
350
+ display: "inline-flex",
351
+ alignItems: "center",
352
+ justifyContent: "center",
353
+ gap: sz.gap,
354
+ padding: sz.padding,
355
+ fontSize: sz.fontSize,
356
+ fontFamily: "Syne, sans-serif",
357
+ fontWeight: 600,
358
+ letterSpacing: "0.04em",
359
+ color: success ? "#fff" : error ? "#fff" : p.text,
360
+ background: success ? "linear-gradient(135deg,#059669,#10b981)" : error ? "linear-gradient(135deg,#dc2626,#ef4444)" : getBackground(),
361
+ border: getBorder(),
362
+ borderRadius,
363
+ cursor: isLocked ? "not-allowed" : "pointer",
364
+ opacity: disabled ? 0.42 : 1,
365
+ outline: "none",
366
+ overflow: "hidden",
367
+ userSelect: "none",
368
+ WebkitTapHighlightColor: "transparent",
369
+ transform: `
370
+ translate(${magXY.x}px, ${magXY.y}px)
371
+ scale(${pressed ? 0.95 : hovered ? 1.04 : 1})
372
+ translateY(${hovered ? "-2px" : "0px"})
373
+ `,
374
+ transition: "background .35s ease, border-color .35s ease, box-shadow .35s ease, opacity .25s ease",
375
+ boxShadow: hovered && !isLocked ? `0 18px 45px -8px ${p.glow}, 0 0 0 1px ${p.border}` : pressed ? `0 4px 14px -4px ${p.glow}` : `0 6px 22px -6px rgba(0,0,0,.4)`,
376
+ animation: error ? errorAnim : floatAnim,
377
+ ...styleProp
378
+ };
379
+ const shimmerStyle = {
380
+ position: "absolute",
381
+ top: 0,
382
+ left: 0,
383
+ width: "55%",
384
+ height: "100%",
385
+ background: `linear-gradient(105deg, transparent 20%, ${p.shimmer} 50%, transparent 80%)`,
386
+ pointerEvents: "none",
387
+ zIndex: 3,
388
+ animation: shimmer ? "mb-shimmer .6s ease forwards" : "none"
389
+ };
390
+ const glassOverlayStyle = {
391
+ position: "absolute",
392
+ inset: 0,
393
+ background: "linear-gradient(160deg, rgba(255,255,255,.06) 0%, transparent 55%)",
394
+ pointerEvents: "none",
395
+ zIndex: 1,
396
+ borderRadius
397
+ };
398
+ return /* @__PURE__ */ React.createElement("div", { ref: wrapRef, className: `mb-root ${className}`, style: wrapperStyle }, pulseRing && !hovered && !isLocked && /* @__PURE__ */ React.createElement(
399
+ "span",
400
+ {
401
+ "aria-hidden": true,
402
+ style: {
403
+ position: "absolute",
404
+ inset: -6,
405
+ borderRadius,
406
+ border: `1.5px solid ${p.border}`,
407
+ animation: "mb-pulse-ring 2s ease-out infinite",
408
+ pointerEvents: "none"
409
+ }
410
+ }
411
+ ), /* @__PURE__ */ React.createElement(
412
+ "button",
413
+ {
414
+ ref: btnRef,
415
+ style: buttonStyle,
416
+ onMouseEnter: handleMouseEnter,
417
+ onMouseMove: handleMouseMove,
418
+ onMouseLeave: handleMouseLeave,
419
+ onMouseDown: () => !isLocked && setPressed(true),
420
+ onMouseUp: () => setPressed(false),
421
+ onClick: handleClick,
422
+ disabled,
423
+ "aria-busy": loading,
424
+ "aria-label": label
425
+ },
426
+ /* @__PURE__ */ React.createElement("div", { style: glassOverlayStyle }),
427
+ /* @__PURE__ */ React.createElement("div", { style: shimmerStyle }),
428
+ burst && /* @__PURE__ */ React.createElement(
429
+ "span",
430
+ {
431
+ "aria-hidden": true,
432
+ style: {
433
+ position: "absolute",
434
+ left: "50%",
435
+ top: "50%",
436
+ width: "100%",
437
+ height: "100%",
438
+ borderRadius,
439
+ border: `2px solid ${p.border}`,
440
+ pointerEvents: "none",
441
+ zIndex: 15,
442
+ animation: "mb-burst .5s ease-out forwards"
443
+ }
444
+ }
445
+ ),
446
+ /* @__PURE__ */ React.createElement(
447
+ Particles,
448
+ {
449
+ active: burst,
450
+ color: p.text === "#fff" ? "rgba(255,255,255,.7)" : "rgba(0,0,0,.3)"
451
+ }
452
+ ),
453
+ /* @__PURE__ */ React.createElement(
454
+ "span",
455
+ {
456
+ style: {
457
+ position: "relative",
458
+ zIndex: 5,
459
+ display: "inline-flex",
460
+ alignItems: "center",
461
+ gap: sz.gap,
462
+ transition: "transform .3s cubic-bezier(.22,1,.36,1), opacity .25s ease",
463
+ transform: `translateX(${hovered && showArrow && !loading && !success && !error ? "2px" : "0"})`,
464
+ opacity: loading ? 0.2 : 1
465
+ }
466
+ },
467
+ !loading && !success && !error && leftIcon && /* @__PURE__ */ React.createElement(
468
+ "span",
469
+ {
470
+ style: {
471
+ display: "inline-flex",
472
+ alignItems: "center",
473
+ transition: "transform .35s cubic-bezier(.22,1,.36,1)",
474
+ transform: hovered ? "translateX(-2px) scale(1.1)" : "translateX(0) scale(1)"
475
+ }
476
+ },
477
+ leftIcon
478
+ ),
479
+ loading && /* @__PURE__ */ React.createElement(Loader, { size: sz.loaderSize, color: p.text }),
480
+ success && /* @__PURE__ */ React.createElement(TickIcon, { size: sz.iconSize, color: "#fff" }),
481
+ error && /* @__PURE__ */ React.createElement(XIcon, { size: sz.iconSize, color: "#fff" }),
482
+ /* @__PURE__ */ React.createElement("span", { style: { whiteSpace: "nowrap" } }, label),
483
+ !loading && !success && !error && rightIcon && /* @__PURE__ */ React.createElement("span", { style: { display: "inline-flex", alignItems: "center" } }, rightIcon),
484
+ !loading && !success && !error && showArrow && /* @__PURE__ */ React.createElement(
485
+ "span",
486
+ {
487
+ "aria-hidden": true,
488
+ style: {
489
+ display: "inline-flex",
490
+ opacity: hovered ? 1 : 0,
491
+ transform: hovered ? "translateX(0)" : "translateX(-8px)",
492
+ transition: "all .3s cubic-bezier(.22,1,.36,1)",
493
+ fontSize: sz.fontSize
494
+ }
495
+ },
496
+ "\u2192"
497
+ )
498
+ ),
499
+ loading && /* @__PURE__ */ React.createElement(
500
+ "span",
501
+ {
502
+ style: {
503
+ position: "absolute",
504
+ zIndex: 5,
505
+ fontSize: sz.fontSize,
506
+ fontFamily: "Syne, sans-serif",
507
+ fontWeight: 600,
508
+ color: p.text,
509
+ letterSpacing: "0.04em"
510
+ }
511
+ },
512
+ label
513
+ )
514
+ ));
515
+ };
516
+
517
+ // src/components/Navbar/Navbar.jsx
518
+ import React2, {
519
+ useState as useState2,
520
+ useEffect as useEffect2,
521
+ useRef as useRef2,
522
+ useCallback as useCallback2,
523
+ useReducer
524
+ } from "react";
525
+ Copy;
526
+ var KEYFRAMES = `
527
+ @import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&display=swap');
528
+
529
+ @keyframes nb-entrance { from{opacity:0;transform:translateY(-110%)} to{opacity:1;transform:none} }
530
+ @keyframes nb-fade-up { from{opacity:0;transform:translateY(10px) scale(.98)} to{opacity:1;transform:none} }
531
+ @keyframes nb-item-in { from{opacity:0;transform:translateY(8px) scale(.96)} to{opacity:1;transform:none} }
532
+ @keyframes nb-slide-left { from{opacity:0;transform:translateX(-22px)} to{opacity:1;transform:none} }
533
+ @keyframes nb-overlay-in { from{opacity:0;clip-path:inset(0 0 100% 0)} to{opacity:1;clip-path:inset(0%)} }
534
+ @keyframes nb-banner-in { from{opacity:0;transform:translateY(-100%)} to{opacity:1;transform:none} }
535
+ @keyframes nb-badge-pop { 0%{transform:scale(0)} 70%{transform:scale(1.18)} 100%{transform:scale(1)} }
536
+ @keyframes nb-ping { 0%{transform:scale(1);opacity:.7} 100%{transform:scale(2.2);opacity:0} }
537
+ @keyframes nb-glow-pulse { 0%,100%{box-shadow:0 0 8px 0 var(--nb-accent-glow)} 50%{box-shadow:0 0 22px 4px var(--nb-accent-glow)} }
538
+ @keyframes nb-tag-pulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.07)} }
539
+ @keyframes nb-shimmer { 0%{background-position:-600px 0} 100%{background-position:600px 0} }
540
+ @keyframes nb-notif-in { from{opacity:0;transform:translateY(8px)} to{opacity:1;transform:none} }
541
+ @keyframes nb-cmd-in { from{opacity:0;transform:scale(.96) translateY(-10px)} to{opacity:1;transform:none} }
542
+ @keyframes nb-mob-in { from{opacity:0;transform:translateX(100%)} to{opacity:1;transform:none} }
543
+ @keyframes nb-mob-out { from{opacity:1;transform:none} to{opacity:0;transform:translateX(100%)} }
544
+
545
+ @media(prefers-reduced-motion:reduce){
546
+ .nb-root,.nb-root *{ animation:none!important; transition:none!important; }
547
+ }
548
+ `;
549
+ function injectKeyframes() {
550
+ const id = "nb-kf-v4";
551
+ if (document.getElementById(id)) return;
552
+ const s = document.createElement("style");
553
+ s.id = id;
554
+ s.textContent = KEYFRAMES;
555
+ document.head.appendChild(s);
556
+ }
557
+ var DEFAULT_PRODUCTS = [
558
+ {
559
+ id: "analytics",
560
+ icon: "\u25C8",
561
+ label: "Analytics",
562
+ tag: "Core",
563
+ tagColor: "#63D2B1",
564
+ desc: "Real-time dashboards, event tracking, and funnels.",
565
+ href: "#",
566
+ hot: false
567
+ },
568
+ {
569
+ id: "pipeline",
570
+ icon: "\u2B21",
571
+ label: "Pipeline",
572
+ tag: "New",
573
+ tagColor: "#F0A050",
574
+ desc: "Visual data pipeline builder with drag-and-drop nodes.",
575
+ href: "#",
576
+ hot: true
577
+ },
578
+ {
579
+ id: "inference",
580
+ icon: "\u25C9",
581
+ label: "Inference",
582
+ tag: "Beta",
583
+ tagColor: "#A78BFA",
584
+ desc: "Deploy and scale ML models with one-click infra.",
585
+ href: "#",
586
+ hot: false
587
+ },
588
+ {
589
+ id: "streams",
590
+ icon: "\u25A3",
591
+ label: "Streams",
592
+ tag: "Popular",
593
+ tagColor: "#F472B6",
594
+ desc: "High-throughput event streaming at any scale.",
595
+ href: "#",
596
+ hot: false
597
+ }
598
+ ];
599
+ var DEFAULT_LINKS = [
600
+ {
601
+ label: "Solutions",
602
+ href: "#",
603
+ children: [
604
+ { label: "Enterprise", desc: "Scale with SLA guarantees", href: "#" },
605
+ { label: "Startups", desc: "Launch fast, pay as you grow", href: "#" },
606
+ { label: "Education", desc: "Free for academic teams", href: "#" }
607
+ ]
608
+ },
609
+ { label: "Pricing", href: "#" },
610
+ { label: "Docs", href: "#" },
611
+ { label: "Blog", href: "#" }
612
+ ];
613
+ var DEFAULT_NOTIFICATIONS = [
614
+ {
615
+ id: 1,
616
+ type: "update",
617
+ read: false,
618
+ title: "Pipeline v2.4 released",
619
+ time: "2m ago",
620
+ body: "Drag-to-connect nodes, live preview, 3\xD7 faster build."
621
+ },
622
+ {
623
+ id: 2,
624
+ type: "alert",
625
+ read: false,
626
+ title: "Usage at 89% of quota",
627
+ time: "1h ago",
628
+ body: "Consider upgrading before your monthly reset on the 1st."
629
+ },
630
+ {
631
+ id: 3,
632
+ type: "success",
633
+ read: true,
634
+ title: "Deployment successful",
635
+ time: "3h ago",
636
+ body: "prod-api-v3 is live on 12 edge regions with zero errors."
637
+ },
638
+ {
639
+ id: 4,
640
+ type: "mention",
641
+ read: true,
642
+ title: "Jamie mentioned you",
643
+ time: "Yesterday",
644
+ body: `"Let's loop @you in on the inference budget conversation"`
645
+ }
646
+ ];
647
+ var NOTIF_COLOR = {
648
+ update: "#63D2B1",
649
+ alert: "#F0A050",
650
+ success: "#4ADE80",
651
+ mention: "#A78BFA"
652
+ };
653
+ var NOTIF_ICON = { update: "\u2191", alert: "!", success: "\u2713", mention: "@" };
654
+ var useOutsideClick = (ref, fn) => {
655
+ useEffect2(() => {
656
+ const h = (e) => {
657
+ if (ref.current && !ref.current.contains(e.target)) fn();
658
+ };
659
+ document.addEventListener("mousedown", h);
660
+ return () => document.removeEventListener("mousedown", h);
661
+ }, [ref, fn]);
662
+ };
663
+ var useScrollProgress = () => {
664
+ const [pct, setPct] = useState2(0);
665
+ useEffect2(() => {
666
+ const h = () => {
667
+ const el = document.documentElement;
668
+ const total = el.scrollHeight - el.clientHeight;
669
+ setPct(total > 0 ? window.scrollY / total * 100 : 0);
670
+ };
671
+ window.addEventListener("scroll", h, { passive: true });
672
+ return () => window.removeEventListener("scroll", h);
673
+ }, []);
674
+ return pct;
675
+ };
676
+ var useIsMobile = (bp = 768) => {
677
+ const [mob, setMob] = useState2(false);
678
+ useEffect2(() => {
679
+ const mq = window.matchMedia(`(max-width:${bp}px)`);
680
+ const h = (e) => setMob(e.matches);
681
+ setMob(mq.matches);
682
+ mq.addEventListener("change", h);
683
+ return () => mq.removeEventListener("change", h);
684
+ }, [bp]);
685
+ return mob;
686
+ };
687
+ function HamburgerIcon({ open, accent, textColor, skip }) {
688
+ const L = (ex) => ({
689
+ display: "block",
690
+ height: "1.5px",
691
+ background: open ? accent : textColor,
692
+ borderRadius: "2px",
693
+ transformOrigin: "center",
694
+ transition: skip ? "none" : "all .4s cubic-bezier(.34,1.56,.64,1)",
695
+ ...ex
696
+ });
697
+ return /* @__PURE__ */ React2.createElement(
698
+ "div",
699
+ {
700
+ style: {
701
+ width: 22,
702
+ display: "flex",
703
+ flexDirection: "column",
704
+ gap: "5px"
705
+ }
706
+ },
707
+ /* @__PURE__ */ React2.createElement(
708
+ "span",
709
+ {
710
+ style: L({
711
+ width: open ? "22px" : "18px",
712
+ transform: open ? "translateY(6.5px) rotate(45deg)" : "none"
713
+ })
714
+ }
715
+ ),
716
+ /* @__PURE__ */ React2.createElement(
717
+ "span",
718
+ {
719
+ style: L({
720
+ width: "22px",
721
+ opacity: open ? 0 : 1,
722
+ transform: open ? "scaleX(0)" : "none"
723
+ })
724
+ }
725
+ ),
726
+ /* @__PURE__ */ React2.createElement(
727
+ "span",
728
+ {
729
+ style: L({
730
+ width: open ? "22px" : "14px",
731
+ transform: open ? "translateY(-6.5px) rotate(-45deg)" : "none"
732
+ })
733
+ }
734
+ )
735
+ );
736
+ }
737
+ function Tooltip({ label, children }) {
738
+ const [show, setShow] = useState2(false);
739
+ return /* @__PURE__ */ React2.createElement(
740
+ "div",
741
+ {
742
+ style: { position: "relative", display: "inline-flex" },
743
+ onMouseEnter: () => setShow(true),
744
+ onMouseLeave: () => setShow(false)
745
+ },
746
+ children,
747
+ show && /* @__PURE__ */ React2.createElement(
748
+ "span",
749
+ {
750
+ style: {
751
+ position: "absolute",
752
+ bottom: "calc(100% + 7px)",
753
+ left: "50%",
754
+ transform: "translateX(-50%)",
755
+ background: "rgba(30,30,36,.98)",
756
+ border: "0.5px solid rgba(255,255,255,.12)",
757
+ borderRadius: 6,
758
+ padding: "4px 9px",
759
+ fontFamily: "DM Sans",
760
+ fontSize: 11,
761
+ color: "rgba(255,255,255,.7)",
762
+ whiteSpace: "nowrap",
763
+ pointerEvents: "none",
764
+ zIndex: 999,
765
+ animation: "nb-fade-up .15s ease both"
766
+ }
767
+ },
768
+ label
769
+ )
770
+ );
771
+ }
772
+ function AnnouncementBanner({
773
+ message,
774
+ href,
775
+ cta,
776
+ accent,
777
+ onDismiss,
778
+ skip,
779
+ topOffset
780
+ }) {
781
+ const [hov, setHov] = useState2(false);
782
+ return /* @__PURE__ */ React2.createElement(
783
+ "div",
784
+ {
785
+ style: {
786
+ position: "fixed",
787
+ top: topOffset ?? 0,
788
+ left: 0,
789
+ right: 0,
790
+ zIndex: 90,
791
+ background: `linear-gradient(90deg,${accent}22,${accent}14,${accent}22)`,
792
+ borderBottom: `0.5px solid ${accent}30`,
793
+ backdropFilter: "blur(12px)",
794
+ display: "flex",
795
+ alignItems: "center",
796
+ justifyContent: "center",
797
+ gap: 12,
798
+ padding: "9px 48px 9px 20px",
799
+ animation: skip ? "none" : "nb-banner-in .45s cubic-bezier(.16,1,.3,1) both"
800
+ }
801
+ },
802
+ /* @__PURE__ */ React2.createElement(
803
+ "span",
804
+ {
805
+ style: {
806
+ width: 6,
807
+ height: 6,
808
+ borderRadius: "50%",
809
+ background: accent,
810
+ flexShrink: 0,
811
+ animation: "nb-ping 1.6s ease-out infinite",
812
+ opacity: 0.8
813
+ }
814
+ }
815
+ ),
816
+ /* @__PURE__ */ React2.createElement(
817
+ "span",
818
+ {
819
+ style: {
820
+ fontFamily: "DM Sans",
821
+ fontSize: 13,
822
+ color: "rgba(255,255,255,.65)"
823
+ }
824
+ },
825
+ message
826
+ ),
827
+ cta && href && /* @__PURE__ */ React2.createElement(
828
+ "a",
829
+ {
830
+ href,
831
+ style: {
832
+ fontFamily: "Syne",
833
+ fontSize: 12,
834
+ fontWeight: 600,
835
+ letterSpacing: ".04em",
836
+ color: accent,
837
+ textDecoration: "none",
838
+ padding: "3px 10px",
839
+ borderRadius: 5,
840
+ background: hov ? `${accent}22` : `${accent}12`,
841
+ border: `0.5px solid ${accent}40`,
842
+ transition: "background .2s"
843
+ },
844
+ onMouseEnter: () => setHov(true),
845
+ onMouseLeave: () => setHov(false)
846
+ },
847
+ cta,
848
+ " \u2192"
849
+ ),
850
+ /* @__PURE__ */ React2.createElement(
851
+ "button",
852
+ {
853
+ onClick: onDismiss,
854
+ style: {
855
+ position: "absolute",
856
+ right: 16,
857
+ background: "none",
858
+ border: "none",
859
+ color: "rgba(255,255,255,.3)",
860
+ cursor: "pointer",
861
+ fontSize: 13,
862
+ padding: 4,
863
+ lineHeight: 1,
864
+ transition: "color .2s"
865
+ },
866
+ onMouseEnter: (e) => e.currentTarget.style.color = "rgba(255,255,255,.7)",
867
+ onMouseLeave: (e) => e.currentTarget.style.color = "rgba(255,255,255,.3)"
868
+ },
869
+ "\u2715"
870
+ )
871
+ );
872
+ }
873
+ function ProductCard({ p, idx, accent, text, muted, skip, compact, onClick }) {
874
+ const [hov, setHov] = useState2(false);
875
+ const [pr, setPr] = useState2(false);
876
+ return /* @__PURE__ */ React2.createElement(
877
+ "a",
878
+ {
879
+ href: p.href,
880
+ onClick: (e) => {
881
+ e.preventDefault();
882
+ onClick == null ? void 0 : onClick(p);
883
+ },
884
+ onMouseEnter: () => setHov(true),
885
+ onMouseLeave: () => {
886
+ setHov(false);
887
+ setPr(false);
888
+ },
889
+ onMouseDown: () => setPr(true),
890
+ onMouseUp: () => setPr(false),
891
+ style: {
892
+ display: "flex",
893
+ alignItems: "flex-start",
894
+ gap: 12,
895
+ padding: compact ? "10px 12px" : "13px 14px",
896
+ borderRadius: 10,
897
+ textDecoration: "none",
898
+ cursor: "pointer",
899
+ background: hov ? "rgba(255,255,255,.055)" : "transparent",
900
+ border: `0.5px solid ${hov ? "rgba(255,255,255,.1)" : "transparent"}`,
901
+ transform: skip ? "none" : pr ? "scale(.98)" : hov ? "translateX(4px)" : "none",
902
+ transition: skip ? "none" : "all .22s cubic-bezier(.34,1.56,.64,1)",
903
+ animation: skip ? "none" : `nb-fade-up .4s cubic-bezier(.16,1,.3,1) ${idx * 55 + 60}ms both`
904
+ }
905
+ },
906
+ /* @__PURE__ */ React2.createElement(
907
+ "div",
908
+ {
909
+ style: {
910
+ width: 36,
911
+ height: 36,
912
+ borderRadius: 9,
913
+ flexShrink: 0,
914
+ background: `${p.tagColor}18`,
915
+ border: `0.5px solid ${p.tagColor}30`,
916
+ display: "flex",
917
+ alignItems: "center",
918
+ justifyContent: "center",
919
+ fontSize: 16,
920
+ color: p.tagColor,
921
+ position: "relative",
922
+ transform: hov && !skip ? "scale(1.1) rotate(-5deg)" : "none",
923
+ transition: skip ? "none" : "transform .3s cubic-bezier(.34,1.56,.64,1)"
924
+ }
925
+ },
926
+ p.icon,
927
+ p.hot && /* @__PURE__ */ React2.createElement(
928
+ "span",
929
+ {
930
+ style: {
931
+ position: "absolute",
932
+ top: -3,
933
+ right: -3,
934
+ width: 8,
935
+ height: 8,
936
+ borderRadius: "50%",
937
+ background: p.tagColor,
938
+ border: "1.5px solid #0a0a0d"
939
+ }
940
+ }
941
+ )
942
+ ),
943
+ /* @__PURE__ */ React2.createElement("div", { style: { flex: 1, minWidth: 0 } }, /* @__PURE__ */ React2.createElement(
944
+ "div",
945
+ {
946
+ style: {
947
+ display: "flex",
948
+ alignItems: "center",
949
+ gap: 7,
950
+ marginBottom: 3
951
+ }
952
+ },
953
+ /* @__PURE__ */ React2.createElement(
954
+ "span",
955
+ {
956
+ style: {
957
+ fontFamily: "Syne",
958
+ fontSize: 13,
959
+ fontWeight: 600,
960
+ letterSpacing: "-0.01em",
961
+ color: hov ? p.tagColor : text,
962
+ transition: skip ? "none" : "color .2s"
963
+ }
964
+ },
965
+ p.label
966
+ ),
967
+ /* @__PURE__ */ React2.createElement(
968
+ "span",
969
+ {
970
+ style: {
971
+ fontSize: 9,
972
+ fontWeight: 700,
973
+ letterSpacing: ".08em",
974
+ textTransform: "uppercase",
975
+ color: p.tagColor,
976
+ background: `${p.tagColor}18`,
977
+ border: `0.5px solid ${p.tagColor}35`,
978
+ borderRadius: 4,
979
+ padding: "2px 6px",
980
+ animation: skip ? "none" : `nb-tag-pulse 2.5s ease-in-out ${idx * 300 + 800}ms infinite`
981
+ }
982
+ },
983
+ p.tag
984
+ )
985
+ ), !compact && /* @__PURE__ */ React2.createElement(
986
+ "p",
987
+ {
988
+ style: {
989
+ fontFamily: "DM Sans",
990
+ fontSize: 12,
991
+ fontWeight: 300,
992
+ color: muted,
993
+ lineHeight: 1.5,
994
+ margin: 0
995
+ }
996
+ },
997
+ p.desc
998
+ ))
999
+ );
1000
+ }
1001
+ function NotificationPanel({
1002
+ notifications,
1003
+ accent,
1004
+ text,
1005
+ muted,
1006
+ onRead,
1007
+ onClear,
1008
+ skip
1009
+ }) {
1010
+ return /* @__PURE__ */ React2.createElement(
1011
+ "div",
1012
+ {
1013
+ style: {
1014
+ position: "absolute",
1015
+ top: "calc(100% + 12px)",
1016
+ right: 0,
1017
+ width: 340,
1018
+ background: "rgba(8,8,11,.98)",
1019
+ backdropFilter: "blur(24px)",
1020
+ WebkitBackdropFilter: "blur(24px)",
1021
+ border: "0.5px solid rgba(255,255,255,.1)",
1022
+ borderRadius: 14,
1023
+ boxShadow: "0 28px 60px rgba(0,0,0,.6), 0 0 0 .5px rgba(255,255,255,.04)",
1024
+ zIndex: 300,
1025
+ overflow: "hidden",
1026
+ animation: skip ? "none" : "nb-fade-up .28s cubic-bezier(.16,1,.3,1) both"
1027
+ }
1028
+ },
1029
+ /* @__PURE__ */ React2.createElement(
1030
+ "div",
1031
+ {
1032
+ style: {
1033
+ display: "flex",
1034
+ alignItems: "center",
1035
+ justifyContent: "space-between",
1036
+ padding: "14px 16px 10px",
1037
+ borderBottom: "0.5px solid rgba(255,255,255,.06)"
1038
+ }
1039
+ },
1040
+ /* @__PURE__ */ React2.createElement(
1041
+ "span",
1042
+ {
1043
+ style: {
1044
+ fontFamily: "Syne",
1045
+ fontSize: 13,
1046
+ fontWeight: 700,
1047
+ color: text
1048
+ }
1049
+ },
1050
+ "Notifications"
1051
+ ),
1052
+ /* @__PURE__ */ React2.createElement(
1053
+ "button",
1054
+ {
1055
+ onClick: onClear,
1056
+ style: {
1057
+ fontFamily: "DM Sans",
1058
+ fontSize: 11,
1059
+ color: muted,
1060
+ background: "none",
1061
+ border: "none",
1062
+ cursor: "pointer",
1063
+ transition: "color .2s"
1064
+ },
1065
+ onMouseEnter: (e) => e.currentTarget.style.color = accent,
1066
+ onMouseLeave: (e) => e.currentTarget.style.color = muted
1067
+ },
1068
+ "Mark all read"
1069
+ )
1070
+ ),
1071
+ /* @__PURE__ */ React2.createElement("div", { style: { maxHeight: 320, overflowY: "auto" } }, notifications.length === 0 ? /* @__PURE__ */ React2.createElement("div", { style: { padding: "32px 16px", textAlign: "center" } }, /* @__PURE__ */ React2.createElement("div", { style: { fontSize: 28, marginBottom: 8 } }, "\u2713"), /* @__PURE__ */ React2.createElement(
1072
+ "p",
1073
+ {
1074
+ style: {
1075
+ fontFamily: "DM Sans",
1076
+ fontSize: 13,
1077
+ color: muted,
1078
+ margin: 0
1079
+ }
1080
+ },
1081
+ "You're all caught up"
1082
+ )) : notifications.map((n, i) => {
1083
+ const c = NOTIF_COLOR[n.type];
1084
+ return /* @__PURE__ */ React2.createElement(
1085
+ "div",
1086
+ {
1087
+ key: n.id,
1088
+ onClick: () => onRead(n.id),
1089
+ style: {
1090
+ display: "flex",
1091
+ gap: 12,
1092
+ padding: "12px 16px",
1093
+ borderBottom: "0.5px solid rgba(255,255,255,.04)",
1094
+ background: n.read ? "transparent" : "rgba(255,255,255,.025)",
1095
+ cursor: "pointer",
1096
+ transition: "background .2s",
1097
+ animation: skip ? "none" : `nb-notif-in .35s cubic-bezier(.16,1,.3,1) ${i * 50}ms both`
1098
+ },
1099
+ onMouseEnter: (e) => e.currentTarget.style.background = "rgba(255,255,255,.04)",
1100
+ onMouseLeave: (e) => e.currentTarget.style.background = n.read ? "transparent" : "rgba(255,255,255,.025)"
1101
+ },
1102
+ /* @__PURE__ */ React2.createElement(
1103
+ "div",
1104
+ {
1105
+ style: {
1106
+ width: 32,
1107
+ height: 32,
1108
+ borderRadius: "50%",
1109
+ flexShrink: 0,
1110
+ background: `${c}18`,
1111
+ border: `0.5px solid ${c}30`,
1112
+ display: "flex",
1113
+ alignItems: "center",
1114
+ justifyContent: "center",
1115
+ fontSize: 12,
1116
+ fontWeight: 700,
1117
+ color: c
1118
+ }
1119
+ },
1120
+ NOTIF_ICON[n.type]
1121
+ ),
1122
+ /* @__PURE__ */ React2.createElement("div", { style: { flex: 1, minWidth: 0 } }, /* @__PURE__ */ React2.createElement(
1123
+ "div",
1124
+ {
1125
+ style: {
1126
+ display: "flex",
1127
+ justifyContent: "space-between",
1128
+ alignItems: "flex-start",
1129
+ gap: 8
1130
+ }
1131
+ },
1132
+ /* @__PURE__ */ React2.createElement(
1133
+ "span",
1134
+ {
1135
+ style: {
1136
+ fontFamily: "Syne",
1137
+ fontSize: 12,
1138
+ fontWeight: 600,
1139
+ color: n.read ? muted : text,
1140
+ lineHeight: 1.3
1141
+ }
1142
+ },
1143
+ n.title
1144
+ ),
1145
+ /* @__PURE__ */ React2.createElement(
1146
+ "span",
1147
+ {
1148
+ style: {
1149
+ fontFamily: "DM Sans",
1150
+ fontSize: 10,
1151
+ color: "rgba(255,255,255,.25)",
1152
+ flexShrink: 0
1153
+ }
1154
+ },
1155
+ n.time
1156
+ )
1157
+ ), /* @__PURE__ */ React2.createElement(
1158
+ "p",
1159
+ {
1160
+ style: {
1161
+ fontFamily: "DM Sans",
1162
+ fontSize: 11,
1163
+ fontWeight: 300,
1164
+ color: "rgba(255,255,255,.35)",
1165
+ margin: "3px 0 0",
1166
+ lineHeight: 1.4,
1167
+ overflow: "hidden",
1168
+ textOverflow: "ellipsis",
1169
+ whiteSpace: "nowrap"
1170
+ }
1171
+ },
1172
+ n.body
1173
+ )),
1174
+ !n.read && /* @__PURE__ */ React2.createElement(
1175
+ "div",
1176
+ {
1177
+ style: {
1178
+ width: 6,
1179
+ height: 6,
1180
+ borderRadius: "50%",
1181
+ background: accent,
1182
+ flexShrink: 0,
1183
+ marginTop: 4
1184
+ }
1185
+ }
1186
+ )
1187
+ );
1188
+ })),
1189
+ /* @__PURE__ */ React2.createElement(
1190
+ "div",
1191
+ {
1192
+ style: {
1193
+ padding: "10px 16px",
1194
+ borderTop: "0.5px solid rgba(255,255,255,.05)"
1195
+ }
1196
+ },
1197
+ /* @__PURE__ */ React2.createElement(
1198
+ "a",
1199
+ {
1200
+ href: "#",
1201
+ onClick: (e) => e.preventDefault(),
1202
+ style: {
1203
+ fontFamily: "DM Sans",
1204
+ fontSize: 12,
1205
+ color: muted,
1206
+ textDecoration: "none",
1207
+ display: "flex",
1208
+ alignItems: "center",
1209
+ justifyContent: "center",
1210
+ gap: 5,
1211
+ transition: "color .2s"
1212
+ },
1213
+ onMouseEnter: (e) => e.currentTarget.style.color = accent,
1214
+ onMouseLeave: (e) => e.currentTarget.style.color = muted
1215
+ },
1216
+ "View all notifications \u2192"
1217
+ )
1218
+ )
1219
+ );
1220
+ }
1221
+ function UserDropdown({ user, accent, text, muted, skip, onLogout }) {
1222
+ const items = [
1223
+ { icon: "\u2299", label: "Profile", sub: "Edit your info" },
1224
+ { icon: "\u229E", label: "Workspace", sub: "Manage team & billing" },
1225
+ {
1226
+ icon: "\u2328",
1227
+ label: "Keyboard shortcuts",
1228
+ sub: "\u2318K to open command palette"
1229
+ },
1230
+ { icon: "\u25CE", label: "API Keys", sub: "Generate & manage tokens" }
1231
+ ];
1232
+ return /* @__PURE__ */ React2.createElement(
1233
+ "div",
1234
+ {
1235
+ style: {
1236
+ position: "absolute",
1237
+ top: "calc(100% + 12px)",
1238
+ right: 0,
1239
+ width: 260,
1240
+ background: "rgba(8,8,11,.98)",
1241
+ backdropFilter: "blur(24px)",
1242
+ WebkitBackdropFilter: "blur(24px)",
1243
+ border: "0.5px solid rgba(255,255,255,.1)",
1244
+ borderRadius: 14,
1245
+ boxShadow: "0 28px 60px rgba(0,0,0,.6)",
1246
+ zIndex: 300,
1247
+ overflow: "hidden",
1248
+ animation: skip ? "none" : "nb-fade-up .28s cubic-bezier(.16,1,.3,1) both"
1249
+ }
1250
+ },
1251
+ /* @__PURE__ */ React2.createElement(
1252
+ "div",
1253
+ {
1254
+ style: {
1255
+ padding: 16,
1256
+ borderBottom: "0.5px solid rgba(255,255,255,.06)",
1257
+ display: "flex",
1258
+ gap: 12,
1259
+ alignItems: "center"
1260
+ }
1261
+ },
1262
+ /* @__PURE__ */ React2.createElement(
1263
+ "div",
1264
+ {
1265
+ style: {
1266
+ width: 38,
1267
+ height: 38,
1268
+ borderRadius: "50%",
1269
+ background: `linear-gradient(135deg,${accent},${accent}88)`,
1270
+ display: "flex",
1271
+ alignItems: "center",
1272
+ justifyContent: "center",
1273
+ fontFamily: "Syne",
1274
+ fontSize: 15,
1275
+ fontWeight: 700,
1276
+ color: "#000",
1277
+ flexShrink: 0
1278
+ }
1279
+ },
1280
+ user.initials
1281
+ ),
1282
+ /* @__PURE__ */ React2.createElement("div", { style: { minWidth: 0 } }, /* @__PURE__ */ React2.createElement(
1283
+ "p",
1284
+ {
1285
+ style: {
1286
+ fontFamily: "Syne",
1287
+ fontSize: 13,
1288
+ fontWeight: 700,
1289
+ color: text,
1290
+ margin: 0,
1291
+ overflow: "hidden",
1292
+ textOverflow: "ellipsis",
1293
+ whiteSpace: "nowrap"
1294
+ }
1295
+ },
1296
+ user.name
1297
+ ), /* @__PURE__ */ React2.createElement(
1298
+ "p",
1299
+ {
1300
+ style: {
1301
+ fontFamily: "DM Sans",
1302
+ fontSize: 11,
1303
+ color: muted,
1304
+ margin: "2px 0 0",
1305
+ overflow: "hidden",
1306
+ textOverflow: "ellipsis",
1307
+ whiteSpace: "nowrap"
1308
+ }
1309
+ },
1310
+ user.email
1311
+ ))
1312
+ ),
1313
+ /* @__PURE__ */ React2.createElement("div", { style: { padding: 6 } }, items.map((item, i) => /* @__PURE__ */ React2.createElement(
1314
+ "button",
1315
+ {
1316
+ key: item.label,
1317
+ style: {
1318
+ width: "100%",
1319
+ display: "flex",
1320
+ alignItems: "center",
1321
+ gap: 10,
1322
+ padding: "9px 10px",
1323
+ borderRadius: 8,
1324
+ background: "transparent",
1325
+ border: "none",
1326
+ cursor: "pointer",
1327
+ textAlign: "left",
1328
+ transition: "background .18s",
1329
+ animation: skip ? "none" : `nb-item-in .35s cubic-bezier(.16,1,.3,1) ${i * 45}ms both`
1330
+ },
1331
+ onMouseEnter: (e) => e.currentTarget.style.background = "rgba(255,255,255,.05)",
1332
+ onMouseLeave: (e) => e.currentTarget.style.background = "transparent"
1333
+ },
1334
+ /* @__PURE__ */ React2.createElement(
1335
+ "span",
1336
+ {
1337
+ style: {
1338
+ fontSize: 14,
1339
+ color: accent,
1340
+ width: 20,
1341
+ textAlign: "center"
1342
+ }
1343
+ },
1344
+ item.icon
1345
+ ),
1346
+ /* @__PURE__ */ React2.createElement("div", null, /* @__PURE__ */ React2.createElement(
1347
+ "p",
1348
+ {
1349
+ style: {
1350
+ fontFamily: "DM Sans",
1351
+ fontSize: 13,
1352
+ color: text,
1353
+ margin: 0
1354
+ }
1355
+ },
1356
+ item.label
1357
+ ), /* @__PURE__ */ React2.createElement(
1358
+ "p",
1359
+ {
1360
+ style: {
1361
+ fontFamily: "DM Sans",
1362
+ fontSize: 10,
1363
+ color: "rgba(255,255,255,.28)",
1364
+ margin: 0
1365
+ }
1366
+ },
1367
+ item.sub
1368
+ ))
1369
+ ))),
1370
+ /* @__PURE__ */ React2.createElement(
1371
+ "div",
1372
+ {
1373
+ style: { padding: 6, borderTop: "0.5px solid rgba(255,255,255,.06)" }
1374
+ },
1375
+ /* @__PURE__ */ React2.createElement(
1376
+ "button",
1377
+ {
1378
+ onClick: onLogout,
1379
+ style: {
1380
+ width: "100%",
1381
+ padding: "9px 10px",
1382
+ borderRadius: 8,
1383
+ background: "transparent",
1384
+ border: "none",
1385
+ cursor: "pointer",
1386
+ fontFamily: "DM Sans",
1387
+ fontSize: 13,
1388
+ color: "#EF4444",
1389
+ textAlign: "left",
1390
+ transition: "background .18s"
1391
+ },
1392
+ onMouseEnter: (e) => e.currentTarget.style.background = "rgba(239,68,68,.08)",
1393
+ onMouseLeave: (e) => e.currentTarget.style.background = "transparent"
1394
+ },
1395
+ "Sign out"
1396
+ )
1397
+ )
1398
+ );
1399
+ }
1400
+ function CommandPalette({
1401
+ open,
1402
+ onClose,
1403
+ products,
1404
+ links,
1405
+ accent,
1406
+ text,
1407
+ muted,
1408
+ skip
1409
+ }) {
1410
+ const [q, setQ] = useState2("");
1411
+ const [sel, setSel] = useState2(0);
1412
+ const inputRef = useRef2(null);
1413
+ const allItems = [
1414
+ ...products.map((p) => ({
1415
+ type: "product",
1416
+ icon: p.icon,
1417
+ label: p.label,
1418
+ sub: p.desc,
1419
+ color: p.tagColor,
1420
+ href: p.href
1421
+ })),
1422
+ ...links.flatMap((l) => [
1423
+ {
1424
+ type: "page",
1425
+ icon: "\u2197",
1426
+ label: l.label,
1427
+ sub: `Navigate to ${l.label}`,
1428
+ color: accent,
1429
+ href: l.href
1430
+ },
1431
+ ...(l.children || []).map((c) => ({
1432
+ type: "page",
1433
+ icon: "\u21B3",
1434
+ label: `${l.label} / ${c.label}`,
1435
+ sub: c.desc,
1436
+ color: "rgba(255,255,255,.3)",
1437
+ href: c.href
1438
+ }))
1439
+ ]),
1440
+ {
1441
+ type: "action",
1442
+ icon: "\u25D0",
1443
+ label: "Toggle theme",
1444
+ sub: "Switch between light and dark",
1445
+ color: "#A78BFA"
1446
+ },
1447
+ {
1448
+ type: "action",
1449
+ icon: "\u2318",
1450
+ label: "Keyboard shortcuts",
1451
+ sub: "View all shortcuts",
1452
+ color: "#F0A050"
1453
+ },
1454
+ {
1455
+ type: "action",
1456
+ icon: "\u25C8",
1457
+ label: "Open notification panel",
1458
+ sub: "See your latest updates",
1459
+ color: "#63D2B1"
1460
+ }
1461
+ ];
1462
+ const filtered = q.trim() ? allItems.filter(
1463
+ (i) => `${i.label} ${i.sub}`.toLowerCase().includes(q.toLowerCase())
1464
+ ) : allItems;
1465
+ useEffect2(() => {
1466
+ if (open) {
1467
+ setTimeout(() => {
1468
+ var _a;
1469
+ return (_a = inputRef.current) == null ? void 0 : _a.focus();
1470
+ }, 60);
1471
+ setQ("");
1472
+ setSel(0);
1473
+ }
1474
+ }, [open]);
1475
+ useEffect2(() => {
1476
+ const h = (e) => {
1477
+ if (!open) return;
1478
+ if (e.key === "ArrowDown") {
1479
+ e.preventDefault();
1480
+ setSel((s) => Math.min(s + 1, filtered.length - 1));
1481
+ }
1482
+ if (e.key === "ArrowUp") {
1483
+ e.preventDefault();
1484
+ setSel((s) => Math.max(s - 1, 0));
1485
+ }
1486
+ if (e.key === "Enter") {
1487
+ e.preventDefault();
1488
+ onClose();
1489
+ }
1490
+ };
1491
+ window.addEventListener("keydown", h);
1492
+ return () => window.removeEventListener("keydown", h);
1493
+ }, [open, filtered.length, onClose]);
1494
+ if (!open) return null;
1495
+ return /* @__PURE__ */ React2.createElement(
1496
+ "div",
1497
+ {
1498
+ onClick: onClose,
1499
+ style: {
1500
+ position: "fixed",
1501
+ inset: 0,
1502
+ zIndex: 1e3,
1503
+ background: "rgba(0,0,0,.65)",
1504
+ backdropFilter: "blur(6px)",
1505
+ display: "flex",
1506
+ alignItems: "flex-start",
1507
+ justifyContent: "center",
1508
+ paddingTop: "14vh"
1509
+ }
1510
+ },
1511
+ /* @__PURE__ */ React2.createElement(
1512
+ "div",
1513
+ {
1514
+ onClick: (e) => e.stopPropagation(),
1515
+ style: {
1516
+ width: "min(620px, 92vw)",
1517
+ background: "rgba(10,10,13,.98)",
1518
+ border: "0.5px solid rgba(255,255,255,.14)",
1519
+ borderRadius: 16,
1520
+ boxShadow: "0 40px 80px rgba(0,0,0,.7), 0 0 0 .5px rgba(255,255,255,.04)",
1521
+ overflow: "hidden",
1522
+ animation: skip ? "none" : "nb-cmd-in .25s cubic-bezier(.16,1,.3,1) both"
1523
+ }
1524
+ },
1525
+ /* @__PURE__ */ React2.createElement(
1526
+ "div",
1527
+ {
1528
+ style: {
1529
+ display: "flex",
1530
+ alignItems: "center",
1531
+ gap: 12,
1532
+ padding: "14px 18px",
1533
+ borderBottom: "0.5px solid rgba(255,255,255,.07)"
1534
+ }
1535
+ },
1536
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 16, color: muted, flexShrink: 0 } }, "\u2315"),
1537
+ /* @__PURE__ */ React2.createElement(
1538
+ "input",
1539
+ {
1540
+ ref: inputRef,
1541
+ value: q,
1542
+ onChange: (e) => {
1543
+ setQ(e.target.value);
1544
+ setSel(0);
1545
+ },
1546
+ placeholder: "Search commands, pages, products\u2026",
1547
+ style: {
1548
+ flex: 1,
1549
+ background: "none",
1550
+ border: "none",
1551
+ outline: "none",
1552
+ fontFamily: "DM Sans",
1553
+ fontSize: 15,
1554
+ color: text,
1555
+ caretColor: accent
1556
+ }
1557
+ }
1558
+ ),
1559
+ /* @__PURE__ */ React2.createElement(
1560
+ "kbd",
1561
+ {
1562
+ style: {
1563
+ fontFamily: "DM Sans",
1564
+ fontSize: 10,
1565
+ color: "rgba(255,255,255,.25)",
1566
+ background: "rgba(255,255,255,.06)",
1567
+ border: "0.5px solid rgba(255,255,255,.1)",
1568
+ borderRadius: 5,
1569
+ padding: "2px 7px"
1570
+ }
1571
+ },
1572
+ "ESC"
1573
+ )
1574
+ ),
1575
+ /* @__PURE__ */ React2.createElement("div", { style: { maxHeight: 360, overflowY: "auto" } }, filtered.length === 0 ? /* @__PURE__ */ React2.createElement("div", { style: { padding: "28px 18px", textAlign: "center" } }, /* @__PURE__ */ React2.createElement(
1576
+ "p",
1577
+ {
1578
+ style: {
1579
+ fontFamily: "DM Sans",
1580
+ fontSize: 13,
1581
+ color: muted,
1582
+ margin: 0
1583
+ }
1584
+ },
1585
+ 'No results for "',
1586
+ q,
1587
+ '"'
1588
+ )) : /* @__PURE__ */ React2.createElement(React2.Fragment, null, !q && /* @__PURE__ */ React2.createElement(
1589
+ "p",
1590
+ {
1591
+ style: {
1592
+ fontFamily: "Syne",
1593
+ fontSize: 10,
1594
+ fontWeight: 700,
1595
+ letterSpacing: ".09em",
1596
+ textTransform: "uppercase",
1597
+ color: "rgba(255,255,255,.2)",
1598
+ margin: 0,
1599
+ padding: "10px 18px 4px"
1600
+ }
1601
+ },
1602
+ "All commands"
1603
+ ), filtered.map((item, i) => /* @__PURE__ */ React2.createElement(
1604
+ "div",
1605
+ {
1606
+ key: i,
1607
+ onClick: onClose,
1608
+ style: {
1609
+ display: "flex",
1610
+ alignItems: "center",
1611
+ gap: 12,
1612
+ padding: "10px 18px",
1613
+ cursor: "pointer",
1614
+ background: sel === i ? "rgba(255,255,255,.055)" : "transparent",
1615
+ borderLeft: sel === i ? `2px solid ${accent}` : "2px solid transparent",
1616
+ transition: "background .12s"
1617
+ },
1618
+ onMouseEnter: () => setSel(i)
1619
+ },
1620
+ /* @__PURE__ */ React2.createElement(
1621
+ "div",
1622
+ {
1623
+ style: {
1624
+ width: 32,
1625
+ height: 32,
1626
+ borderRadius: 8,
1627
+ flexShrink: 0,
1628
+ background: `${item.color}18`,
1629
+ border: `0.5px solid ${item.color}28`,
1630
+ display: "flex",
1631
+ alignItems: "center",
1632
+ justifyContent: "center",
1633
+ fontSize: 14,
1634
+ color: item.color
1635
+ }
1636
+ },
1637
+ item.icon
1638
+ ),
1639
+ /* @__PURE__ */ React2.createElement("div", { style: { flex: 1, minWidth: 0 } }, /* @__PURE__ */ React2.createElement(
1640
+ "p",
1641
+ {
1642
+ style: {
1643
+ fontFamily: "DM Sans",
1644
+ fontSize: 13,
1645
+ fontWeight: 500,
1646
+ color: text,
1647
+ margin: 0
1648
+ }
1649
+ },
1650
+ item.label
1651
+ ), /* @__PURE__ */ React2.createElement(
1652
+ "p",
1653
+ {
1654
+ style: {
1655
+ fontFamily: "DM Sans",
1656
+ fontSize: 11,
1657
+ color: muted,
1658
+ margin: 0,
1659
+ overflow: "hidden",
1660
+ textOverflow: "ellipsis",
1661
+ whiteSpace: "nowrap"
1662
+ }
1663
+ },
1664
+ item.sub
1665
+ )),
1666
+ /* @__PURE__ */ React2.createElement(
1667
+ "span",
1668
+ {
1669
+ style: {
1670
+ fontFamily: "DM Sans",
1671
+ fontSize: 10,
1672
+ color: "rgba(255,255,255,.2)",
1673
+ flexShrink: 0
1674
+ }
1675
+ },
1676
+ item.type === "product" ? "Product" : item.type === "page" ? "Page" : "Action"
1677
+ )
1678
+ )))),
1679
+ /* @__PURE__ */ React2.createElement(
1680
+ "div",
1681
+ {
1682
+ style: {
1683
+ padding: "9px 18px",
1684
+ borderTop: "0.5px solid rgba(255,255,255,.06)",
1685
+ display: "flex",
1686
+ gap: 14
1687
+ }
1688
+ },
1689
+ [
1690
+ ["\u2191\u2193", "Navigate"],
1691
+ ["\u21B5", "Select"],
1692
+ ["esc", "Close"]
1693
+ ].map(([k, v]) => /* @__PURE__ */ React2.createElement(
1694
+ "span",
1695
+ {
1696
+ key: k,
1697
+ style: {
1698
+ fontFamily: "DM Sans",
1699
+ fontSize: 11,
1700
+ color: "rgba(255,255,255,.25)",
1701
+ display: "flex",
1702
+ alignItems: "center",
1703
+ gap: 5
1704
+ }
1705
+ },
1706
+ /* @__PURE__ */ React2.createElement(
1707
+ "kbd",
1708
+ {
1709
+ style: {
1710
+ background: "rgba(255,255,255,.07)",
1711
+ border: "0.5px solid rgba(255,255,255,.1)",
1712
+ borderRadius: 4,
1713
+ padding: "1px 5px",
1714
+ fontSize: 10
1715
+ }
1716
+ },
1717
+ k
1718
+ ),
1719
+ v
1720
+ ))
1721
+ )
1722
+ )
1723
+ );
1724
+ }
1725
+ function ProductsMegaMenu({
1726
+ products,
1727
+ accent,
1728
+ text,
1729
+ muted,
1730
+ open,
1731
+ skip,
1732
+ onProductClick
1733
+ }) {
1734
+ if (!open) return null;
1735
+ return /* @__PURE__ */ React2.createElement(
1736
+ "div",
1737
+ {
1738
+ style: {
1739
+ position: "absolute",
1740
+ top: "calc(100% + 14px)",
1741
+ left: "50%",
1742
+ transform: "translateX(-50%)",
1743
+ width: 460,
1744
+ background: "rgba(8,8,11,.98)",
1745
+ backdropFilter: "blur(24px)",
1746
+ WebkitBackdropFilter: "blur(24px)",
1747
+ border: "0.5px solid rgba(255,255,255,.1)",
1748
+ borderRadius: 16,
1749
+ padding: 12,
1750
+ zIndex: 200,
1751
+ boxShadow: "0 32px 64px rgba(0,0,0,.55), 0 0 0 .5px rgba(255,255,255,.04)",
1752
+ animation: skip ? "none" : "nb-fade-up .28s cubic-bezier(.16,1,.3,1) both"
1753
+ }
1754
+ },
1755
+ /* @__PURE__ */ React2.createElement(
1756
+ "div",
1757
+ {
1758
+ style: {
1759
+ padding: "7px 14px 10px",
1760
+ borderBottom: "0.5px solid rgba(255,255,255,.06)",
1761
+ marginBottom: 6,
1762
+ display: "flex",
1763
+ justifyContent: "space-between",
1764
+ alignItems: "center"
1765
+ }
1766
+ },
1767
+ /* @__PURE__ */ React2.createElement(
1768
+ "p",
1769
+ {
1770
+ style: {
1771
+ fontFamily: "Syne",
1772
+ fontSize: 10,
1773
+ fontWeight: 700,
1774
+ letterSpacing: ".1em",
1775
+ textTransform: "uppercase",
1776
+ color: accent,
1777
+ margin: 0
1778
+ }
1779
+ },
1780
+ "All Products"
1781
+ ),
1782
+ /* @__PURE__ */ React2.createElement(
1783
+ "span",
1784
+ {
1785
+ style: {
1786
+ fontFamily: "DM Sans",
1787
+ fontSize: 10,
1788
+ color: "rgba(255,255,255,.25)"
1789
+ }
1790
+ },
1791
+ "4 tools"
1792
+ )
1793
+ ),
1794
+ /* @__PURE__ */ React2.createElement("div", { style: { display: "grid", gridTemplateColumns: "1fr 1fr", gap: 3 } }, products.map((p, i) => /* @__PURE__ */ React2.createElement(
1795
+ ProductCard,
1796
+ {
1797
+ key: p.id,
1798
+ p,
1799
+ idx: i,
1800
+ accent,
1801
+ text,
1802
+ muted,
1803
+ skip,
1804
+ onClick: (pr) => {
1805
+ onProductClick == null ? void 0 : onProductClick(pr);
1806
+ }
1807
+ }
1808
+ ))),
1809
+ /* @__PURE__ */ React2.createElement(
1810
+ "div",
1811
+ {
1812
+ style: {
1813
+ margin: "10px 0 4px",
1814
+ padding: "13px 14px",
1815
+ background: `linear-gradient(135deg,${accent}10,transparent)`,
1816
+ border: `0.5px solid ${accent}20`,
1817
+ borderRadius: 10,
1818
+ display: "flex",
1819
+ alignItems: "center",
1820
+ justifyContent: "space-between",
1821
+ cursor: "pointer"
1822
+ },
1823
+ onMouseEnter: (e) => e.currentTarget.style.background = `linear-gradient(135deg,${accent}1a,transparent)`,
1824
+ onMouseLeave: (e) => e.currentTarget.style.background = `linear-gradient(135deg,${accent}10,transparent)`
1825
+ },
1826
+ /* @__PURE__ */ React2.createElement("div", null, /* @__PURE__ */ React2.createElement(
1827
+ "p",
1828
+ {
1829
+ style: {
1830
+ fontFamily: "Syne",
1831
+ fontSize: 12,
1832
+ fontWeight: 600,
1833
+ color: text,
1834
+ margin: "0 0 2px"
1835
+ }
1836
+ },
1837
+ "\u26A1 Pipeline launch event"
1838
+ ), /* @__PURE__ */ React2.createElement(
1839
+ "p",
1840
+ {
1841
+ style: {
1842
+ fontFamily: "DM Sans",
1843
+ fontSize: 11,
1844
+ color: muted,
1845
+ margin: 0
1846
+ }
1847
+ },
1848
+ "Watch the 12-min demo \u2014 live Q&A on Thursday"
1849
+ )),
1850
+ /* @__PURE__ */ React2.createElement("span", { style: { color: accent, fontSize: 16, flexShrink: 0 } }, "\u2192")
1851
+ )
1852
+ );
1853
+ }
1854
+ function SubDropdown({ link, accent, text, muted, open, skip }) {
1855
+ var _a;
1856
+ if (!open || !((_a = link.children) == null ? void 0 : _a.length)) return null;
1857
+ return /* @__PURE__ */ React2.createElement(
1858
+ "div",
1859
+ {
1860
+ style: {
1861
+ position: "absolute",
1862
+ top: "calc(100% + 12px)",
1863
+ left: "50%",
1864
+ transform: "translateX(-50%)",
1865
+ width: 240,
1866
+ background: "rgba(8,8,11,.98)",
1867
+ backdropFilter: "blur(24px)",
1868
+ border: "0.5px solid rgba(255,255,255,.1)",
1869
+ borderRadius: 12,
1870
+ padding: 8,
1871
+ zIndex: 200,
1872
+ boxShadow: "0 24px 50px rgba(0,0,0,.5)",
1873
+ animation: skip ? "none" : "nb-fade-up .25s cubic-bezier(.16,1,.3,1) both"
1874
+ }
1875
+ },
1876
+ link.children.map((child, i) => /* @__PURE__ */ React2.createElement(
1877
+ "a",
1878
+ {
1879
+ key: child.label,
1880
+ href: child.href,
1881
+ onClick: (e) => e.preventDefault(),
1882
+ style: {
1883
+ display: "flex",
1884
+ flexDirection: "column",
1885
+ padding: "9px 12px",
1886
+ borderRadius: 8,
1887
+ textDecoration: "none",
1888
+ cursor: "pointer",
1889
+ transition: "background .18s",
1890
+ animation: skip ? "none" : `nb-item-in .3s cubic-bezier(.16,1,.3,1) ${i * 50}ms both`
1891
+ },
1892
+ onMouseEnter: (e) => e.currentTarget.style.background = "rgba(255,255,255,.05)",
1893
+ onMouseLeave: (e) => e.currentTarget.style.background = "transparent"
1894
+ },
1895
+ /* @__PURE__ */ React2.createElement(
1896
+ "span",
1897
+ {
1898
+ style: {
1899
+ fontFamily: "Syne",
1900
+ fontSize: 13,
1901
+ fontWeight: 600,
1902
+ color: text
1903
+ }
1904
+ },
1905
+ child.label
1906
+ ),
1907
+ child.desc && /* @__PURE__ */ React2.createElement(
1908
+ "span",
1909
+ {
1910
+ style: {
1911
+ fontFamily: "DM Sans",
1912
+ fontSize: 11,
1913
+ color: muted,
1914
+ marginTop: 2
1915
+ }
1916
+ },
1917
+ child.desc
1918
+ )
1919
+ ))
1920
+ );
1921
+ }
1922
+ function MobileDrawer({
1923
+ open,
1924
+ onClose,
1925
+ links,
1926
+ products,
1927
+ ctaLabel,
1928
+ accent,
1929
+ text,
1930
+ muted,
1931
+ skip,
1932
+ onProductClick,
1933
+ onCtaClick
1934
+ }) {
1935
+ useEffect2(() => {
1936
+ document.body.style.overflow = open ? "hidden" : "";
1937
+ return () => {
1938
+ document.body.style.overflow = "";
1939
+ };
1940
+ }, [open]);
1941
+ if (!open) return null;
1942
+ return /* @__PURE__ */ React2.createElement(
1943
+ "div",
1944
+ {
1945
+ style: {
1946
+ position: "fixed",
1947
+ inset: 0,
1948
+ zIndex: 500,
1949
+ background: "rgba(6,6,9,.98)",
1950
+ backdropFilter: "blur(24px)",
1951
+ WebkitBackdropFilter: "blur(24px)",
1952
+ overflowY: "auto",
1953
+ display: "flex",
1954
+ flexDirection: "column",
1955
+ animation: skip ? "none" : "nb-mob-in .35s cubic-bezier(.16,1,.3,1) both"
1956
+ }
1957
+ },
1958
+ /* @__PURE__ */ React2.createElement(
1959
+ "div",
1960
+ {
1961
+ style: {
1962
+ display: "flex",
1963
+ alignItems: "center",
1964
+ justifyContent: "flex-end",
1965
+ padding: "0 20px",
1966
+ height: 62,
1967
+ borderBottom: "0.5px solid rgba(255,255,255,.07)",
1968
+ flexShrink: 0
1969
+ }
1970
+ },
1971
+ /* @__PURE__ */ React2.createElement(
1972
+ "button",
1973
+ {
1974
+ onClick: onClose,
1975
+ style: {
1976
+ display: "flex",
1977
+ alignItems: "center",
1978
+ gap: 7,
1979
+ fontFamily: "DM Sans",
1980
+ fontSize: 13,
1981
+ color: muted,
1982
+ background: "rgba(255,255,255,.05)",
1983
+ border: "0.5px solid rgba(255,255,255,.1)",
1984
+ borderRadius: 8,
1985
+ padding: "8px 14px",
1986
+ cursor: "pointer",
1987
+ transition: "all .2s"
1988
+ },
1989
+ onMouseEnter: (e) => {
1990
+ e.currentTarget.style.color = text;
1991
+ e.currentTarget.style.background = "rgba(255,255,255,.09)";
1992
+ },
1993
+ onMouseLeave: (e) => {
1994
+ e.currentTarget.style.color = muted;
1995
+ e.currentTarget.style.background = "rgba(255,255,255,.05)";
1996
+ }
1997
+ },
1998
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 10 } }, "\u2715"),
1999
+ " Close"
2000
+ )
2001
+ ),
2002
+ /* @__PURE__ */ React2.createElement("div", { style: { flex: 1, padding: "24px 20px 40px" } }, /* @__PURE__ */ React2.createElement(
2003
+ "p",
2004
+ {
2005
+ style: {
2006
+ fontFamily: "Syne",
2007
+ fontSize: 10,
2008
+ fontWeight: 700,
2009
+ letterSpacing: ".1em",
2010
+ textTransform: "uppercase",
2011
+ color: accent,
2012
+ margin: "0 0 12px"
2013
+ }
2014
+ },
2015
+ "Products"
2016
+ ), /* @__PURE__ */ React2.createElement(
2017
+ "div",
2018
+ {
2019
+ style: {
2020
+ display: "flex",
2021
+ flexDirection: "column",
2022
+ gap: 2,
2023
+ marginBottom: 28
2024
+ }
2025
+ },
2026
+ products.map((p, i) => /* @__PURE__ */ React2.createElement(
2027
+ ProductCard,
2028
+ {
2029
+ key: p.id,
2030
+ p,
2031
+ idx: i,
2032
+ accent,
2033
+ text,
2034
+ muted,
2035
+ skip,
2036
+ onClick: (pr) => {
2037
+ onProductClick == null ? void 0 : onProductClick(pr);
2038
+ onClose();
2039
+ }
2040
+ }
2041
+ ))
2042
+ ), /* @__PURE__ */ React2.createElement(
2043
+ "p",
2044
+ {
2045
+ style: {
2046
+ fontFamily: "Syne",
2047
+ fontSize: 10,
2048
+ fontWeight: 700,
2049
+ letterSpacing: ".1em",
2050
+ textTransform: "uppercase",
2051
+ color: muted,
2052
+ margin: "0 0 8px"
2053
+ }
2054
+ },
2055
+ "Navigate"
2056
+ ), links.map((link, i) => /* @__PURE__ */ React2.createElement(
2057
+ "a",
2058
+ {
2059
+ key: link.label,
2060
+ href: link.href,
2061
+ onClick: (e) => {
2062
+ e.preventDefault();
2063
+ onClose();
2064
+ },
2065
+ style: {
2066
+ display: "flex",
2067
+ alignItems: "center",
2068
+ justifyContent: "space-between",
2069
+ fontFamily: "Syne",
2070
+ fontSize: "clamp(22px,5vw,28px)",
2071
+ fontWeight: 700,
2072
+ letterSpacing: "-0.03em",
2073
+ color: text,
2074
+ textDecoration: "none",
2075
+ padding: "10px 0",
2076
+ borderBottom: "0.5px solid rgba(255,255,255,.05)",
2077
+ transition: skip ? "none" : "all .22s cubic-bezier(.34,1.56,.64,1)",
2078
+ animation: skip ? "none" : `nb-slide-left .5s cubic-bezier(.16,1,.3,1) ${0.1 + i * 0.07}s both`
2079
+ },
2080
+ onMouseEnter: (e) => {
2081
+ e.currentTarget.style.color = accent;
2082
+ e.currentTarget.style.paddingLeft = "8px";
2083
+ },
2084
+ onMouseLeave: (e) => {
2085
+ e.currentTarget.style.color = text;
2086
+ e.currentTarget.style.paddingLeft = "0";
2087
+ }
2088
+ },
2089
+ link.label,
2090
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 13, opacity: 0.3 } }, "\u2197")
2091
+ )), /* @__PURE__ */ React2.createElement(
2092
+ "div",
2093
+ {
2094
+ style: {
2095
+ marginTop: 32,
2096
+ background: `linear-gradient(135deg,${accent}14,${accent}07)`,
2097
+ border: `0.5px solid ${accent}2a`,
2098
+ borderRadius: 14,
2099
+ padding: 20
2100
+ }
2101
+ },
2102
+ /* @__PURE__ */ React2.createElement(
2103
+ "p",
2104
+ {
2105
+ style: {
2106
+ fontFamily: "Syne",
2107
+ fontSize: 15,
2108
+ fontWeight: 600,
2109
+ color: text,
2110
+ margin: "0 0 6px"
2111
+ }
2112
+ },
2113
+ "Ready to ship?"
2114
+ ),
2115
+ /* @__PURE__ */ React2.createElement(
2116
+ "p",
2117
+ {
2118
+ style: {
2119
+ fontFamily: "DM Sans",
2120
+ fontSize: 13,
2121
+ color: muted,
2122
+ margin: "0 0 16px"
2123
+ }
2124
+ },
2125
+ "Free forever. No credit card needed."
2126
+ ),
2127
+ /* @__PURE__ */ React2.createElement(
2128
+ "button",
2129
+ {
2130
+ onClick: () => {
2131
+ onCtaClick == null ? void 0 : onCtaClick();
2132
+ onClose();
2133
+ },
2134
+ style: {
2135
+ fontFamily: "Syne",
2136
+ fontSize: 14,
2137
+ fontWeight: 600,
2138
+ letterSpacing: ".04em",
2139
+ color: "#000",
2140
+ background: `linear-gradient(135deg,${accent},${accent}cc)`,
2141
+ border: "none",
2142
+ borderRadius: 10,
2143
+ padding: "12px 20px",
2144
+ cursor: "pointer",
2145
+ width: "100%"
2146
+ }
2147
+ },
2148
+ ctaLabel
2149
+ )
2150
+ ), /* @__PURE__ */ React2.createElement(
2151
+ "div",
2152
+ {
2153
+ style: { display: "flex", gap: 20, marginTop: 24, flexWrap: "wrap" }
2154
+ },
2155
+ ["Twitter", "GitHub", "Discord", "LinkedIn"].map((s) => /* @__PURE__ */ React2.createElement(
2156
+ "a",
2157
+ {
2158
+ key: s,
2159
+ href: "#",
2160
+ style: {
2161
+ fontFamily: "DM Sans",
2162
+ fontSize: 12,
2163
+ color: muted,
2164
+ textDecoration: "none",
2165
+ transition: "color .2s"
2166
+ },
2167
+ onMouseEnter: (e) => e.currentTarget.style.color = accent,
2168
+ onMouseLeave: (e) => e.currentTarget.style.color = muted
2169
+ },
2170
+ s
2171
+ ))
2172
+ ))
2173
+ );
2174
+ }
2175
+ function FullScreenMenu({
2176
+ open,
2177
+ onClose,
2178
+ links,
2179
+ products,
2180
+ ctaLabel,
2181
+ accent,
2182
+ text,
2183
+ muted,
2184
+ skip,
2185
+ activeIdx,
2186
+ onLinkClick,
2187
+ onProductClick,
2188
+ onCtaClick
2189
+ }) {
2190
+ const [search, setSearch] = useState2("");
2191
+ const inputRef = useRef2(null);
2192
+ useEffect2(() => {
2193
+ if (open) setTimeout(() => {
2194
+ var _a;
2195
+ return (_a = inputRef.current) == null ? void 0 : _a.focus();
2196
+ }, 120);
2197
+ }, [open]);
2198
+ if (!open) return null;
2199
+ const sideLinks = [
2200
+ "About",
2201
+ "Careers",
2202
+ "Contact",
2203
+ "Status",
2204
+ "Changelog",
2205
+ "Security"
2206
+ ];
2207
+ return /* @__PURE__ */ React2.createElement(
2208
+ "div",
2209
+ {
2210
+ style: {
2211
+ position: "fixed",
2212
+ inset: 0,
2213
+ zIndex: 500,
2214
+ background: "rgba(4,4,6,.98)",
2215
+ backdropFilter: "blur(28px)",
2216
+ WebkitBackdropFilter: "blur(28px)",
2217
+ display: "flex",
2218
+ flexDirection: "column",
2219
+ animation: skip ? "none" : "nb-overlay-in .42s cubic-bezier(.16,1,.3,1) both"
2220
+ }
2221
+ },
2222
+ /* @__PURE__ */ React2.createElement(
2223
+ "div",
2224
+ {
2225
+ style: {
2226
+ display: "flex",
2227
+ alignItems: "center",
2228
+ justifyContent: "space-between",
2229
+ padding: "0 36px",
2230
+ height: 68,
2231
+ flexShrink: 0,
2232
+ borderBottom: "0.5px solid rgba(255,255,255,.06)"
2233
+ }
2234
+ },
2235
+ /* @__PURE__ */ React2.createElement("div", { style: { display: "flex", alignItems: "center", gap: 9 } }, /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 20, color: accent } }, "\u25C8"), /* @__PURE__ */ React2.createElement(
2236
+ "span",
2237
+ {
2238
+ style: {
2239
+ fontFamily: "Syne",
2240
+ fontSize: 17,
2241
+ fontWeight: 800,
2242
+ letterSpacing: "-0.02em",
2243
+ color: text
2244
+ }
2245
+ },
2246
+ "Axiom"
2247
+ )),
2248
+ /* @__PURE__ */ React2.createElement(
2249
+ "div",
2250
+ {
2251
+ style: {
2252
+ flex: 1,
2253
+ maxWidth: 400,
2254
+ margin: "0 36px",
2255
+ display: "flex",
2256
+ alignItems: "center",
2257
+ gap: 10,
2258
+ background: "rgba(255,255,255,.05)",
2259
+ border: "0.5px solid rgba(255,255,255,.1)",
2260
+ borderRadius: 10,
2261
+ padding: "9px 14px"
2262
+ }
2263
+ },
2264
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 15, color: muted, flexShrink: 0 } }, "\u2315"),
2265
+ /* @__PURE__ */ React2.createElement(
2266
+ "input",
2267
+ {
2268
+ ref: inputRef,
2269
+ value: search,
2270
+ onChange: (e) => setSearch(e.target.value),
2271
+ placeholder: "Search products, docs, guides\u2026",
2272
+ style: {
2273
+ background: "none",
2274
+ border: "none",
2275
+ outline: "none",
2276
+ fontFamily: "DM Sans",
2277
+ fontSize: 14,
2278
+ color: text,
2279
+ flex: 1,
2280
+ caretColor: accent
2281
+ }
2282
+ }
2283
+ ),
2284
+ search ? /* @__PURE__ */ React2.createElement(
2285
+ "button",
2286
+ {
2287
+ onClick: () => setSearch(""),
2288
+ style: {
2289
+ background: "none",
2290
+ border: "none",
2291
+ color: muted,
2292
+ cursor: "pointer",
2293
+ fontSize: 11,
2294
+ padding: 0
2295
+ }
2296
+ },
2297
+ "\u2715"
2298
+ ) : /* @__PURE__ */ React2.createElement(
2299
+ "kbd",
2300
+ {
2301
+ style: {
2302
+ fontFamily: "DM Sans",
2303
+ fontSize: 10,
2304
+ color: "rgba(255,255,255,.2)",
2305
+ background: "rgba(255,255,255,.06)",
2306
+ border: "0.5px solid rgba(255,255,255,.1)",
2307
+ borderRadius: 4,
2308
+ padding: "2px 7px",
2309
+ flexShrink: 0
2310
+ }
2311
+ },
2312
+ "\u2318K"
2313
+ )
2314
+ ),
2315
+ /* @__PURE__ */ React2.createElement(
2316
+ "button",
2317
+ {
2318
+ onClick: onClose,
2319
+ style: {
2320
+ display: "flex",
2321
+ alignItems: "center",
2322
+ gap: 7,
2323
+ fontFamily: "DM Sans",
2324
+ fontSize: 13,
2325
+ color: muted,
2326
+ background: "rgba(255,255,255,.05)",
2327
+ border: "0.5px solid rgba(255,255,255,.1)",
2328
+ borderRadius: 8,
2329
+ padding: "8px 14px",
2330
+ cursor: "pointer",
2331
+ transition: "all .2s"
2332
+ },
2333
+ onMouseEnter: (e) => {
2334
+ e.currentTarget.style.color = text;
2335
+ e.currentTarget.style.background = "rgba(255,255,255,.09)";
2336
+ },
2337
+ onMouseLeave: (e) => {
2338
+ e.currentTarget.style.color = muted;
2339
+ e.currentTarget.style.background = "rgba(255,255,255,.05)";
2340
+ }
2341
+ },
2342
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 10 } }, "\u2715"),
2343
+ " Close"
2344
+ )
2345
+ ),
2346
+ /* @__PURE__ */ React2.createElement("div", { style: { flex: 1, display: "flex", overflow: "hidden" } }, /* @__PURE__ */ React2.createElement(
2347
+ "div",
2348
+ {
2349
+ style: {
2350
+ flex: "0 0 46%",
2351
+ padding: "32px 36px",
2352
+ borderRight: "0.5px solid rgba(255,255,255,.06)",
2353
+ overflowY: "auto"
2354
+ }
2355
+ },
2356
+ /* @__PURE__ */ React2.createElement(
2357
+ "p",
2358
+ {
2359
+ style: {
2360
+ fontFamily: "Syne",
2361
+ fontSize: 10,
2362
+ fontWeight: 700,
2363
+ letterSpacing: ".1em",
2364
+ textTransform: "uppercase",
2365
+ color: accent,
2366
+ margin: "0 0 16px"
2367
+ }
2368
+ },
2369
+ "Products"
2370
+ ),
2371
+ /* @__PURE__ */ React2.createElement(
2372
+ "div",
2373
+ {
2374
+ style: { display: "grid", gridTemplateColumns: "1fr 1fr", gap: 4 }
2375
+ },
2376
+ products.map((p, i) => /* @__PURE__ */ React2.createElement(
2377
+ ProductCard,
2378
+ {
2379
+ key: p.id,
2380
+ p,
2381
+ idx: i,
2382
+ accent,
2383
+ text,
2384
+ muted,
2385
+ skip,
2386
+ onClick: (pr) => {
2387
+ onProductClick == null ? void 0 : onProductClick(pr);
2388
+ onClose();
2389
+ }
2390
+ }
2391
+ ))
2392
+ ),
2393
+ /* @__PURE__ */ React2.createElement(
2394
+ "div",
2395
+ {
2396
+ style: {
2397
+ marginTop: 18,
2398
+ padding: "14px 16px",
2399
+ background: "rgba(255,255,255,.03)",
2400
+ borderRadius: 10,
2401
+ border: "0.5px solid rgba(255,255,255,.07)",
2402
+ display: "flex",
2403
+ alignItems: "center",
2404
+ justifyContent: "space-between",
2405
+ cursor: "pointer"
2406
+ },
2407
+ onMouseEnter: (e) => e.currentTarget.style.background = "rgba(255,255,255,.055)",
2408
+ onMouseLeave: (e) => e.currentTarget.style.background = "rgba(255,255,255,.03)"
2409
+ },
2410
+ /* @__PURE__ */ React2.createElement("div", null, /* @__PURE__ */ React2.createElement(
2411
+ "p",
2412
+ {
2413
+ style: {
2414
+ fontFamily: "Syne",
2415
+ fontSize: 13,
2416
+ fontWeight: 600,
2417
+ color: text,
2418
+ margin: "0 0 2px"
2419
+ }
2420
+ },
2421
+ "Compare plans"
2422
+ ), /* @__PURE__ */ React2.createElement(
2423
+ "p",
2424
+ {
2425
+ style: {
2426
+ fontFamily: "DM Sans",
2427
+ fontSize: 11,
2428
+ color: muted,
2429
+ margin: 0
2430
+ }
2431
+ },
2432
+ "Find the right tier for your team"
2433
+ )),
2434
+ /* @__PURE__ */ React2.createElement("span", { style: { color: accent, fontSize: 18 } }, "\u2192")
2435
+ )
2436
+ ), /* @__PURE__ */ React2.createElement(
2437
+ "div",
2438
+ {
2439
+ style: {
2440
+ flex: 1,
2441
+ padding: "32px 40px",
2442
+ display: "flex",
2443
+ flexDirection: "column",
2444
+ justifyContent: "space-between",
2445
+ borderRight: "0.5px solid rgba(255,255,255,.06)"
2446
+ }
2447
+ },
2448
+ /* @__PURE__ */ React2.createElement("div", null, /* @__PURE__ */ React2.createElement(
2449
+ "p",
2450
+ {
2451
+ style: {
2452
+ fontFamily: "Syne",
2453
+ fontSize: 10,
2454
+ fontWeight: 700,
2455
+ letterSpacing: ".1em",
2456
+ textTransform: "uppercase",
2457
+ color: muted,
2458
+ margin: "0 0 16px"
2459
+ }
2460
+ },
2461
+ "Navigate"
2462
+ ), links.map((link, i) => /* @__PURE__ */ React2.createElement(
2463
+ "a",
2464
+ {
2465
+ key: link.label,
2466
+ href: link.href,
2467
+ onClick: (e) => {
2468
+ e.preventDefault();
2469
+ onLinkClick(link.label, i);
2470
+ onClose();
2471
+ },
2472
+ style: {
2473
+ fontFamily: "Syne",
2474
+ fontSize: "clamp(22px,2.8vw,30px)",
2475
+ fontWeight: 700,
2476
+ letterSpacing: "-0.03em",
2477
+ color: activeIdx === i ? accent : text,
2478
+ textDecoration: "none",
2479
+ padding: "10px 0",
2480
+ borderBottom: "0.5px solid rgba(255,255,255,.05)",
2481
+ display: "flex",
2482
+ alignItems: "center",
2483
+ justifyContent: "space-between",
2484
+ cursor: "pointer",
2485
+ transition: skip ? "none" : "all .22s cubic-bezier(.34,1.56,.64,1)",
2486
+ animation: skip ? "none" : `nb-slide-left .5s cubic-bezier(.16,1,.3,1) ${0.18 + i * 0.07}s both`
2487
+ },
2488
+ onMouseEnter: (e) => {
2489
+ e.currentTarget.style.color = accent;
2490
+ e.currentTarget.style.paddingLeft = "8px";
2491
+ },
2492
+ onMouseLeave: (e) => {
2493
+ e.currentTarget.style.color = activeIdx === i ? accent : text;
2494
+ e.currentTarget.style.paddingLeft = "0";
2495
+ }
2496
+ },
2497
+ link.label,
2498
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 13, opacity: 0.3 } }, "\u2197")
2499
+ ))),
2500
+ /* @__PURE__ */ React2.createElement("div", { style: { display: "flex", gap: 20 } }, ["Twitter", "GitHub", "Discord", "LinkedIn"].map((s) => /* @__PURE__ */ React2.createElement(
2501
+ "a",
2502
+ {
2503
+ key: s,
2504
+ href: "#",
2505
+ style: {
2506
+ fontFamily: "DM Sans",
2507
+ fontSize: 12,
2508
+ color: muted,
2509
+ textDecoration: "none",
2510
+ transition: "color .2s"
2511
+ },
2512
+ onMouseEnter: (e) => e.currentTarget.style.color = accent,
2513
+ onMouseLeave: (e) => e.currentTarget.style.color = muted
2514
+ },
2515
+ s
2516
+ )))
2517
+ ), /* @__PURE__ */ React2.createElement(
2518
+ "div",
2519
+ {
2520
+ style: {
2521
+ flex: "0 0 230px",
2522
+ padding: "32px 28px",
2523
+ display: "flex",
2524
+ flexDirection: "column",
2525
+ justifyContent: "space-between"
2526
+ }
2527
+ },
2528
+ /* @__PURE__ */ React2.createElement("div", null, /* @__PURE__ */ React2.createElement(
2529
+ "p",
2530
+ {
2531
+ style: {
2532
+ fontFamily: "Syne",
2533
+ fontSize: 10,
2534
+ fontWeight: 700,
2535
+ letterSpacing: ".1em",
2536
+ textTransform: "uppercase",
2537
+ color: muted,
2538
+ margin: "0 0 16px"
2539
+ }
2540
+ },
2541
+ "Company"
2542
+ ), sideLinks.map((l, i) => /* @__PURE__ */ React2.createElement(
2543
+ "a",
2544
+ {
2545
+ key: l,
2546
+ href: "#",
2547
+ style: {
2548
+ display: "block",
2549
+ fontFamily: "DM Sans",
2550
+ fontSize: 14,
2551
+ color: muted,
2552
+ textDecoration: "none",
2553
+ padding: "8px 0",
2554
+ borderBottom: "0.5px solid rgba(255,255,255,.04)",
2555
+ transition: "color .2s ease, padding-left .2s cubic-bezier(.34,1.56,.64,1)",
2556
+ animation: skip ? "none" : `nb-item-in .45s cubic-bezier(.16,1,.3,1) ${0.2 + i * 0.06}s both`
2557
+ },
2558
+ onMouseEnter: (e) => {
2559
+ e.currentTarget.style.color = text;
2560
+ e.currentTarget.style.paddingLeft = "6px";
2561
+ },
2562
+ onMouseLeave: (e) => {
2563
+ e.currentTarget.style.color = muted;
2564
+ e.currentTarget.style.paddingLeft = "0";
2565
+ }
2566
+ },
2567
+ l
2568
+ ))),
2569
+ /* @__PURE__ */ React2.createElement("div", null, /* @__PURE__ */ React2.createElement(
2570
+ "div",
2571
+ {
2572
+ style: {
2573
+ background: `linear-gradient(135deg,${accent}14,${accent}07)`,
2574
+ border: `0.5px solid ${accent}2a`,
2575
+ borderRadius: 12,
2576
+ padding: 18,
2577
+ marginBottom: 12
2578
+ }
2579
+ },
2580
+ /* @__PURE__ */ React2.createElement(
2581
+ "p",
2582
+ {
2583
+ style: {
2584
+ fontFamily: "Syne",
2585
+ fontSize: 13,
2586
+ fontWeight: 600,
2587
+ color: text,
2588
+ margin: "0 0 4px"
2589
+ }
2590
+ },
2591
+ "Ready to ship?"
2592
+ ),
2593
+ /* @__PURE__ */ React2.createElement(
2594
+ "p",
2595
+ {
2596
+ style: {
2597
+ fontFamily: "DM Sans",
2598
+ fontSize: 12,
2599
+ color: muted,
2600
+ margin: "0 0 14px"
2601
+ }
2602
+ },
2603
+ "Free forever. No card needed."
2604
+ ),
2605
+ /* @__PURE__ */ React2.createElement(
2606
+ "button",
2607
+ {
2608
+ onClick: () => {
2609
+ onCtaClick == null ? void 0 : onCtaClick();
2610
+ onClose();
2611
+ },
2612
+ style: {
2613
+ fontFamily: "Syne",
2614
+ fontSize: 13,
2615
+ fontWeight: 600,
2616
+ letterSpacing: ".04em",
2617
+ color: "#000",
2618
+ background: `linear-gradient(135deg,${accent},${accent}cc)`,
2619
+ border: "none",
2620
+ borderRadius: 8,
2621
+ padding: "10px 16px",
2622
+ cursor: "pointer",
2623
+ width: "100%",
2624
+ transition: "transform .2s ease"
2625
+ },
2626
+ onMouseEnter: (e) => e.currentTarget.style.transform = "scale(1.02)",
2627
+ onMouseLeave: (e) => e.currentTarget.style.transform = "none"
2628
+ },
2629
+ ctaLabel
2630
+ )
2631
+ ), /* @__PURE__ */ React2.createElement(
2632
+ "p",
2633
+ {
2634
+ style: {
2635
+ fontFamily: "DM Sans",
2636
+ fontSize: 11,
2637
+ color: "rgba(255,255,255,.2)",
2638
+ textAlign: "center",
2639
+ margin: 0
2640
+ }
2641
+ },
2642
+ "Trusted by 10,000+ teams"
2643
+ ))
2644
+ ))
2645
+ );
2646
+ }
2647
+ function Navbar({
2648
+ logo = "Axiom",
2649
+ logoIcon = "\u25C8",
2650
+ products = DEFAULT_PRODUCTS,
2651
+ links = DEFAULT_LINKS,
2652
+ notifications = DEFAULT_NOTIFICATIONS,
2653
+ ctaLabel = "Get started \u2192",
2654
+ badge,
2655
+ user = { name: "Jamie Rivera", email: "jamie@axiom.co", initials: "JR" },
2656
+ showUser = true,
2657
+ showNotifs = true,
2658
+ showSearch = true,
2659
+ showProgress = true,
2660
+ announcement,
2661
+ loading = false,
2662
+ defaultActive = null,
2663
+ disableAnimation = false,
2664
+ mobileBreakpoint = 768,
2665
+ accent = "#63D2B1",
2666
+ text = "#F2F0EB",
2667
+ muted = "#888580",
2668
+ surface = "rgba(8,8,10,.72)",
2669
+ onClick,
2670
+ onHover,
2671
+ onCtaClick,
2672
+ onProductClick,
2673
+ onAnimationEnd,
2674
+ onChange
2675
+ }) {
2676
+ const navRef = useRef2(null);
2677
+ const prodsRef = useRef2(null);
2678
+ const notifRef = useRef2(null);
2679
+ const userRef = useRef2(null);
2680
+ const subRefs = useRef2({});
2681
+ const [scrolled, setScrolled] = useState2(false);
2682
+ const [menuOpen, setMenuOpen] = useState2(false);
2683
+ const [mobOpen, setMobOpen] = useState2(false);
2684
+ const [prodsOpen, setProdsOpen] = useState2(false);
2685
+ const [notifOpen, setNotifOpen] = useState2(false);
2686
+ const [userOpen, setUserOpen] = useState2(false);
2687
+ const [cmdOpen, setCmdOpen] = useState2(false);
2688
+ const [subOpen, setSubOpen] = useState2(null);
2689
+ const [activeIdx, setActiveIdx] = useState2(defaultActive);
2690
+ const [logoHov, setLogoHov] = useState2(false);
2691
+ const [notifs, setNotifs] = useState2(notifications);
2692
+ const [bannerVisible, setBannerVisible] = useState2(!!announcement);
2693
+ const [isLoggedIn, setIsLoggedIn] = useState2(true);
2694
+ const isMobile = useIsMobile(mobileBreakpoint);
2695
+ const scrollPct = useScrollProgress();
2696
+ const unreadCount = notifs.filter((n) => !n.read).length;
2697
+ const reduced = typeof window !== "undefined" && window.matchMedia("(prefers-reduced-motion:reduce)").matches;
2698
+ const skip = disableAnimation || reduced;
2699
+ useEffect2(() => {
2700
+ injectKeyframes();
2701
+ }, []);
2702
+ useEffect2(() => {
2703
+ const h = () => setScrolled(window.scrollY > 24);
2704
+ window.addEventListener("scroll", h, { passive: true });
2705
+ return () => window.removeEventListener("scroll", h);
2706
+ }, []);
2707
+ useEffect2(() => {
2708
+ if (!isMobile) setMobOpen(false);
2709
+ }, [isMobile]);
2710
+ useEffect2(() => {
2711
+ document.body.style.overflow = menuOpen || mobOpen ? "hidden" : "";
2712
+ return () => {
2713
+ document.body.style.overflow = "";
2714
+ };
2715
+ }, [menuOpen, mobOpen]);
2716
+ useEffect2(() => {
2717
+ const h = (e) => {
2718
+ if (e.key === "Escape") {
2719
+ setMenuOpen(false);
2720
+ setMobOpen(false);
2721
+ setProdsOpen(false);
2722
+ setNotifOpen(false);
2723
+ setUserOpen(false);
2724
+ setCmdOpen(false);
2725
+ setSubOpen(null);
2726
+ }
2727
+ if ((e.metaKey || e.ctrlKey) && e.key === "k") {
2728
+ e.preventDefault();
2729
+ setCmdOpen((v) => !v);
2730
+ }
2731
+ };
2732
+ window.addEventListener("keydown", h);
2733
+ return () => window.removeEventListener("keydown", h);
2734
+ }, []);
2735
+ useOutsideClick(prodsRef, () => setProdsOpen(false));
2736
+ useOutsideClick(notifRef, () => setNotifOpen(false));
2737
+ useOutsideClick(userRef, () => setUserOpen(false));
2738
+ const handleLink = useCallback2(
2739
+ (label, idx) => {
2740
+ setActiveIdx(idx);
2741
+ onChange == null ? void 0 : onChange(label);
2742
+ onClick == null ? void 0 : onClick(label);
2743
+ },
2744
+ [onChange, onClick]
2745
+ );
2746
+ const BANNER_H = bannerVisible ? 42 : 0;
2747
+ const NAV_H = scrolled ? 58 : 68;
2748
+ const TOTAL_H = BANNER_H + NAV_H;
2749
+ const navStyle = {
2750
+ position: "fixed",
2751
+ top: BANNER_H,
2752
+ left: 0,
2753
+ right: 0,
2754
+ zIndex: menuOpen || mobOpen ? 600 : 100,
2755
+ display: "flex",
2756
+ alignItems: "center",
2757
+ justifyContent: "space-between",
2758
+ padding: `0 clamp(14px, 3vw, 28px)`,
2759
+ height: NAV_H,
2760
+ background: menuOpen ? "rgba(4,4,6,.98)" : scrolled ? "rgba(8,8,10,.92)" : surface,
2761
+ backdropFilter: menuOpen ? "none" : "blur(20px) saturate(180%)",
2762
+ WebkitBackdropFilter: menuOpen ? "none" : "blur(20px) saturate(180%)",
2763
+ borderBottom: `0.5px solid ${menuOpen ? "rgba(255,255,255,.06)" : scrolled ? "rgba(255,255,255,.1)" : "rgba(255,255,255,.04)"}`,
2764
+ transition: skip ? "none" : "height .35s cubic-bezier(.34,1.56,.64,1), background .35s ease, top .35s ease",
2765
+ animation: skip ? "none" : "nb-entrance .5s cubic-bezier(.16,1,.3,1) both",
2766
+ fontFamily: "Syne, sans-serif",
2767
+ boxSizing: "border-box"
2768
+ };
2769
+ if (loading)
2770
+ return /* @__PURE__ */ React2.createElement("nav", { style: { ...navStyle, animation: "none" } }, [1, 2, 3].map((k) => /* @__PURE__ */ React2.createElement(
2771
+ "div",
2772
+ {
2773
+ key: k,
2774
+ style: { display: "flex", gap: 12, alignItems: "center" }
2775
+ },
2776
+ [26, 68, 56, 48].map((w, i) => /* @__PURE__ */ React2.createElement(
2777
+ "div",
2778
+ {
2779
+ key: i,
2780
+ style: {
2781
+ width: w,
2782
+ height: 13,
2783
+ borderRadius: 5,
2784
+ background: "linear-gradient(90deg,rgba(255,255,255,.04) 0%,rgba(255,255,255,.1) 50%,rgba(255,255,255,.04) 100%)",
2785
+ backgroundSize: "600px 100%",
2786
+ animation: "nb-shimmer 1.5s ease-in-out infinite"
2787
+ }
2788
+ }
2789
+ ))
2790
+ )));
2791
+ return /* @__PURE__ */ React2.createElement(React2.Fragment, null, announcement && bannerVisible && /* @__PURE__ */ React2.createElement(
2792
+ AnnouncementBanner,
2793
+ {
2794
+ ...announcement,
2795
+ accent,
2796
+ skip,
2797
+ onDismiss: () => setBannerVisible(false)
2798
+ }
2799
+ ), showProgress && /* @__PURE__ */ React2.createElement(
2800
+ "div",
2801
+ {
2802
+ style: {
2803
+ position: "fixed",
2804
+ top: BANNER_H + NAV_H - 1,
2805
+ left: 0,
2806
+ right: 0,
2807
+ zIndex: 101,
2808
+ height: 2,
2809
+ background: "rgba(255,255,255,.05)"
2810
+ }
2811
+ },
2812
+ /* @__PURE__ */ React2.createElement(
2813
+ "div",
2814
+ {
2815
+ style: {
2816
+ height: "100%",
2817
+ width: `${scrollPct}%`,
2818
+ background: `linear-gradient(90deg,${accent},${accent}88)`,
2819
+ transition: "width .1s linear",
2820
+ boxShadow: `0 0 8px ${accent}66`
2821
+ }
2822
+ }
2823
+ )
2824
+ ), /* @__PURE__ */ React2.createElement(
2825
+ "nav",
2826
+ {
2827
+ ref: navRef,
2828
+ className: "nb-root",
2829
+ style: navStyle,
2830
+ onAnimationEnd
2831
+ },
2832
+ /* @__PURE__ */ React2.createElement(
2833
+ "a",
2834
+ {
2835
+ href: "#",
2836
+ onClick: (e) => e.preventDefault(),
2837
+ style: {
2838
+ display: "flex",
2839
+ alignItems: "center",
2840
+ gap: 9,
2841
+ textDecoration: "none",
2842
+ cursor: "pointer",
2843
+ flexShrink: 0,
2844
+ transform: logoHov && !skip ? "scale(1.04)" : "none",
2845
+ transition: skip ? "none" : "transform .25s cubic-bezier(.34,1.56,.64,1)",
2846
+ animation: skip ? "none" : "nb-item-in .5s cubic-bezier(.16,1,.3,1) 60ms both"
2847
+ },
2848
+ onMouseEnter: () => {
2849
+ setLogoHov(true);
2850
+ onHover == null ? void 0 : onHover(true);
2851
+ },
2852
+ onMouseLeave: () => {
2853
+ setLogoHov(false);
2854
+ onHover == null ? void 0 : onHover(false);
2855
+ }
2856
+ },
2857
+ /* @__PURE__ */ React2.createElement("span", { style: { fontSize: 20, color: accent } }, logoIcon),
2858
+ /* @__PURE__ */ React2.createElement(
2859
+ "span",
2860
+ {
2861
+ style: {
2862
+ fontFamily: "Syne",
2863
+ fontSize: 17,
2864
+ fontWeight: 800,
2865
+ letterSpacing: "-0.025em",
2866
+ color: text
2867
+ }
2868
+ },
2869
+ logo
2870
+ ),
2871
+ badge && /* @__PURE__ */ React2.createElement(
2872
+ "span",
2873
+ {
2874
+ style: {
2875
+ fontSize: 9,
2876
+ fontWeight: 700,
2877
+ letterSpacing: ".08em",
2878
+ textTransform: "uppercase",
2879
+ color: accent,
2880
+ background: `${accent}1a`,
2881
+ border: `0.5px solid ${accent}44`,
2882
+ borderRadius: 4,
2883
+ padding: "2px 6px"
2884
+ }
2885
+ },
2886
+ badge
2887
+ )
2888
+ ),
2889
+ !isMobile && /* @__PURE__ */ React2.createElement("div", { style: { display: "flex", alignItems: "center", gap: 22 } }, /* @__PURE__ */ React2.createElement("div", { ref: prodsRef, style: { position: "relative" } }, /* @__PURE__ */ React2.createElement(
2890
+ "button",
2891
+ {
2892
+ onClick: () => setProdsOpen((v) => !v),
2893
+ onMouseEnter: () => setProdsOpen(true),
2894
+ style: {
2895
+ background: "none",
2896
+ border: "none",
2897
+ cursor: "pointer",
2898
+ padding: "6px 0",
2899
+ display: "flex",
2900
+ alignItems: "center",
2901
+ gap: 5,
2902
+ fontFamily: "DM Sans",
2903
+ fontSize: 14,
2904
+ color: prodsOpen ? text : muted,
2905
+ transition: skip ? "none" : "color .2s",
2906
+ animation: skip ? "none" : "nb-item-in .5s cubic-bezier(.16,1,.3,1) 160ms both"
2907
+ }
2908
+ },
2909
+ "Products",
2910
+ /* @__PURE__ */ React2.createElement(
2911
+ "span",
2912
+ {
2913
+ style: {
2914
+ fontSize: 8,
2915
+ opacity: 0.6,
2916
+ display: "inline-block",
2917
+ transform: prodsOpen ? "rotate(180deg)" : "none",
2918
+ transition: skip ? "none" : "transform .3s cubic-bezier(.34,1.56,.64,1)"
2919
+ }
2920
+ },
2921
+ "\u25BC"
2922
+ )
2923
+ ), /* @__PURE__ */ React2.createElement(
2924
+ ProductsMegaMenu,
2925
+ {
2926
+ products,
2927
+ open: prodsOpen,
2928
+ skip,
2929
+ accent,
2930
+ text,
2931
+ muted,
2932
+ onProductClick: (p) => {
2933
+ onProductClick == null ? void 0 : onProductClick(p);
2934
+ setProdsOpen(false);
2935
+ }
2936
+ }
2937
+ )), links.map((link, i) => {
2938
+ var _a;
2939
+ if (!subRefs.current[link.label])
2940
+ subRefs.current[link.label] = React2.createRef();
2941
+ const hasSub = ((_a = link.children) == null ? void 0 : _a.length) > 0;
2942
+ return /* @__PURE__ */ React2.createElement(
2943
+ "div",
2944
+ {
2945
+ key: link.label,
2946
+ ref: subRefs.current[link.label],
2947
+ style: { position: "relative" }
2948
+ },
2949
+ /* @__PURE__ */ React2.createElement(
2950
+ "a",
2951
+ {
2952
+ href: link.href,
2953
+ onClick: (e) => {
2954
+ e.preventDefault();
2955
+ handleLink(link.label, i);
2956
+ if (hasSub)
2957
+ setSubOpen(
2958
+ (v) => v === link.label ? null : link.label
2959
+ );
2960
+ },
2961
+ style: {
2962
+ position: "relative",
2963
+ padding: "6px 0",
2964
+ display: "flex",
2965
+ alignItems: "center",
2966
+ gap: 4,
2967
+ textDecoration: "none",
2968
+ fontFamily: "DM Sans",
2969
+ fontSize: 14,
2970
+ fontWeight: activeIdx === i ? "500" : "400",
2971
+ color: activeIdx === i ? accent : muted,
2972
+ cursor: "pointer",
2973
+ transition: skip ? "none" : "color .25s ease",
2974
+ animation: skip ? "none" : `nb-item-in .5s cubic-bezier(.16,1,.3,1) ${240 + 80 * i}ms both`
2975
+ },
2976
+ onMouseEnter: (e) => {
2977
+ e.currentTarget.style.color = text;
2978
+ if (hasSub) setSubOpen(link.label);
2979
+ },
2980
+ onMouseLeave: (e) => {
2981
+ e.currentTarget.style.color = activeIdx === i ? accent : muted;
2982
+ if (hasSub) setSubOpen(null);
2983
+ }
2984
+ },
2985
+ link.label,
2986
+ hasSub && /* @__PURE__ */ React2.createElement(
2987
+ "span",
2988
+ {
2989
+ style: {
2990
+ fontSize: 7,
2991
+ opacity: 0.5,
2992
+ transform: subOpen === link.label ? "rotate(180deg)" : "none",
2993
+ transition: "transform .2s"
2994
+ }
2995
+ },
2996
+ "\u25BC"
2997
+ ),
2998
+ /* @__PURE__ */ React2.createElement(
2999
+ "span",
3000
+ {
3001
+ style: {
3002
+ position: "absolute",
3003
+ bottom: 0,
3004
+ left: 0,
3005
+ width: "100%",
3006
+ height: "1.5px",
3007
+ background: accent,
3008
+ borderRadius: 2,
3009
+ transformOrigin: "left",
3010
+ transform: activeIdx === i ? "scaleX(1)" : "scaleX(0)",
3011
+ transition: skip ? "none" : "transform .3s cubic-bezier(.34,1.56,.64,1)"
3012
+ }
3013
+ }
3014
+ )
3015
+ ),
3016
+ hasSub && /* @__PURE__ */ React2.createElement(
3017
+ "div",
3018
+ {
3019
+ onMouseEnter: () => setSubOpen(link.label),
3020
+ onMouseLeave: () => setSubOpen(null)
3021
+ },
3022
+ /* @__PURE__ */ React2.createElement(
3023
+ SubDropdown,
3024
+ {
3025
+ link,
3026
+ open: subOpen === link.label,
3027
+ skip,
3028
+ accent,
3029
+ text,
3030
+ muted
3031
+ }
3032
+ )
3033
+ )
3034
+ );
3035
+ })),
3036
+ /* @__PURE__ */ React2.createElement(
3037
+ "div",
3038
+ {
3039
+ style: {
3040
+ display: "flex",
3041
+ alignItems: "center",
3042
+ gap: 8,
3043
+ flexShrink: 0
3044
+ }
3045
+ },
3046
+ showSearch && !isMobile && /* @__PURE__ */ React2.createElement(
3047
+ "div",
3048
+ {
3049
+ style: {
3050
+ animation: skip ? "none" : `nb-item-in .5s cubic-bezier(.16,1,.3,1) 460ms both`
3051
+ }
3052
+ },
3053
+ /* @__PURE__ */ React2.createElement(Tooltip, { label: "Search (\u2318K)" }, /* @__PURE__ */ React2.createElement(
3054
+ "button",
3055
+ {
3056
+ onClick: () => setCmdOpen(true),
3057
+ style: {
3058
+ background: "rgba(255,255,255,.05)",
3059
+ border: "0.5px solid rgba(255,255,255,.1)",
3060
+ borderRadius: 8,
3061
+ padding: "7px 10px",
3062
+ cursor: "pointer",
3063
+ color: muted,
3064
+ fontSize: 15,
3065
+ display: "flex",
3066
+ alignItems: "center",
3067
+ transition: "all .2s"
3068
+ },
3069
+ onMouseEnter: (e) => {
3070
+ e.currentTarget.style.background = "rgba(255,255,255,.09)";
3071
+ e.currentTarget.style.color = text;
3072
+ },
3073
+ onMouseLeave: (e) => {
3074
+ e.currentTarget.style.background = "rgba(255,255,255,.05)";
3075
+ e.currentTarget.style.color = muted;
3076
+ }
3077
+ },
3078
+ "\u2315"
3079
+ ))
3080
+ ),
3081
+ showNotifs && /* @__PURE__ */ React2.createElement(
3082
+ "div",
3083
+ {
3084
+ ref: notifRef,
3085
+ style: {
3086
+ position: "relative",
3087
+ animation: skip ? "none" : "nb-item-in .5s cubic-bezier(.16,1,.3,1) 500ms both"
3088
+ }
3089
+ },
3090
+ /* @__PURE__ */ React2.createElement(Tooltip, { label: "Notifications" }, /* @__PURE__ */ React2.createElement(
3091
+ "button",
3092
+ {
3093
+ onClick: () => {
3094
+ setNotifOpen((v) => !v);
3095
+ setUserOpen(false);
3096
+ },
3097
+ style: {
3098
+ position: "relative",
3099
+ background: notifOpen ? "rgba(255,255,255,.09)" : "rgba(255,255,255,.05)",
3100
+ border: `0.5px solid ${notifOpen ? "rgba(255,255,255,.15)" : "rgba(255,255,255,.1)"}`,
3101
+ borderRadius: 8,
3102
+ padding: "7px 10px",
3103
+ cursor: "pointer",
3104
+ color: notifOpen ? text : muted,
3105
+ fontSize: 15,
3106
+ display: "flex",
3107
+ alignItems: "center",
3108
+ transition: "all .2s"
3109
+ },
3110
+ onMouseEnter: (e) => {
3111
+ e.currentTarget.style.background = "rgba(255,255,255,.09)";
3112
+ e.currentTarget.style.color = text;
3113
+ },
3114
+ onMouseLeave: (e) => {
3115
+ if (!notifOpen) {
3116
+ e.currentTarget.style.background = "rgba(255,255,255,.05)";
3117
+ e.currentTarget.style.color = muted;
3118
+ }
3119
+ }
3120
+ },
3121
+ "\u{1F514}",
3122
+ unreadCount > 0 && /* @__PURE__ */ React2.createElement(React2.Fragment, null, /* @__PURE__ */ React2.createElement(
3123
+ "span",
3124
+ {
3125
+ style: {
3126
+ position: "absolute",
3127
+ top: -4,
3128
+ right: -4,
3129
+ width: 16,
3130
+ height: 16,
3131
+ borderRadius: "50%",
3132
+ background: accent,
3133
+ border: "1.5px solid #07070a",
3134
+ display: "flex",
3135
+ alignItems: "center",
3136
+ justifyContent: "center",
3137
+ fontFamily: "Syne",
3138
+ fontSize: 9,
3139
+ fontWeight: 700,
3140
+ color: "#000",
3141
+ animation: skip ? "none" : "nb-badge-pop .4s cubic-bezier(.34,1.56,.64,1) both"
3142
+ }
3143
+ },
3144
+ unreadCount
3145
+ ), /* @__PURE__ */ React2.createElement(
3146
+ "span",
3147
+ {
3148
+ style: {
3149
+ position: "absolute",
3150
+ top: -4,
3151
+ right: -4,
3152
+ width: 16,
3153
+ height: 16,
3154
+ borderRadius: "50%",
3155
+ background: accent,
3156
+ opacity: 0.5,
3157
+ pointerEvents: "none",
3158
+ animation: "nb-ping 1.8s ease-out infinite"
3159
+ }
3160
+ }
3161
+ ))
3162
+ )),
3163
+ notifOpen && /* @__PURE__ */ React2.createElement(
3164
+ NotificationPanel,
3165
+ {
3166
+ notifications: notifs,
3167
+ accent,
3168
+ text,
3169
+ muted,
3170
+ skip,
3171
+ onRead: (id) => setNotifs(
3172
+ (ns) => ns.map((n) => n.id === id ? { ...n, read: true } : n)
3173
+ ),
3174
+ onClear: () => setNotifs((ns) => ns.map((n) => ({ ...n, read: true })))
3175
+ }
3176
+ )
3177
+ ),
3178
+ showUser && /* @__PURE__ */ React2.createElement(
3179
+ "div",
3180
+ {
3181
+ ref: userRef,
3182
+ style: {
3183
+ position: "relative",
3184
+ animation: skip ? "none" : "nb-item-in .5s cubic-bezier(.16,1,.3,1) 540ms both"
3185
+ }
3186
+ },
3187
+ isLoggedIn ? /* @__PURE__ */ React2.createElement(React2.Fragment, null, /* @__PURE__ */ React2.createElement(Tooltip, { label: user.name }, /* @__PURE__ */ React2.createElement(
3188
+ "button",
3189
+ {
3190
+ onClick: () => {
3191
+ setUserOpen((v) => !v);
3192
+ setNotifOpen(false);
3193
+ },
3194
+ style: {
3195
+ width: 34,
3196
+ height: 34,
3197
+ borderRadius: "50%",
3198
+ background: `linear-gradient(135deg,${accent},${accent}88)`,
3199
+ border: `1.5px solid ${userOpen ? accent : "rgba(255,255,255,.1)"}`,
3200
+ cursor: "pointer",
3201
+ display: "flex",
3202
+ alignItems: "center",
3203
+ justifyContent: "center",
3204
+ fontFamily: "Syne",
3205
+ fontSize: 12,
3206
+ fontWeight: 700,
3207
+ color: "#000",
3208
+ transition: "border-color .2s, transform .2s cubic-bezier(.34,1.56,.64,1)",
3209
+ transform: userOpen ? "scale(1.08)" : "scale(1)"
3210
+ },
3211
+ onMouseEnter: (e) => e.currentTarget.style.transform = "scale(1.08)",
3212
+ onMouseLeave: (e) => {
3213
+ if (!userOpen)
3214
+ e.currentTarget.style.transform = "scale(1)";
3215
+ }
3216
+ },
3217
+ user.initials
3218
+ )), userOpen && /* @__PURE__ */ React2.createElement(
3219
+ UserDropdown,
3220
+ {
3221
+ user,
3222
+ accent,
3223
+ text,
3224
+ muted,
3225
+ skip,
3226
+ onLogout: () => {
3227
+ setIsLoggedIn(false);
3228
+ setUserOpen(false);
3229
+ }
3230
+ }
3231
+ )) : /* @__PURE__ */ React2.createElement(
3232
+ "button",
3233
+ {
3234
+ onClick: () => setIsLoggedIn(true),
3235
+ style: {
3236
+ fontFamily: "DM Sans",
3237
+ fontSize: 13,
3238
+ color: muted,
3239
+ background: "rgba(255,255,255,.05)",
3240
+ border: "0.5px solid rgba(255,255,255,.1)",
3241
+ borderRadius: 8,
3242
+ padding: "7px 14px",
3243
+ cursor: "pointer",
3244
+ transition: "all .2s"
3245
+ },
3246
+ onMouseEnter: (e) => {
3247
+ e.currentTarget.style.color = text;
3248
+ e.currentTarget.style.background = "rgba(255,255,255,.09)";
3249
+ },
3250
+ onMouseLeave: (e) => {
3251
+ e.currentTarget.style.color = muted;
3252
+ e.currentTarget.style.background = "rgba(255,255,255,.05)";
3253
+ }
3254
+ },
3255
+ "Sign in"
3256
+ )
3257
+ ),
3258
+ !isMobile && /* @__PURE__ */ React2.createElement(
3259
+ "button",
3260
+ {
3261
+ onClick: onCtaClick,
3262
+ style: {
3263
+ fontFamily: "Syne",
3264
+ fontSize: 13,
3265
+ fontWeight: 600,
3266
+ letterSpacing: ".04em",
3267
+ color: "#000",
3268
+ background: `linear-gradient(135deg,${accent}ee,${accent}bb)`,
3269
+ border: "none",
3270
+ borderRadius: 8,
3271
+ padding: "8px 18px",
3272
+ cursor: "pointer",
3273
+ whiteSpace: "nowrap",
3274
+ transition: skip ? "none" : "all .25s cubic-bezier(.34,1.56,.64,1)",
3275
+ animation: skip ? "none" : `nb-item-in .5s cubic-bezier(.16,1,.3,1) 580ms both, nb-glow-pulse 3s ease-in-out 1.1s infinite`,
3276
+ "--nb-accent-glow": `${accent}55`
3277
+ },
3278
+ onMouseEnter: (e) => {
3279
+ e.currentTarget.style.transform = "translateY(-2px) scale(1.04)";
3280
+ e.currentTarget.style.boxShadow = `0 8px 28px ${accent}42`;
3281
+ },
3282
+ onMouseLeave: (e) => {
3283
+ e.currentTarget.style.transform = "none";
3284
+ e.currentTarget.style.boxShadow = "none";
3285
+ },
3286
+ onMouseDown: (e) => e.currentTarget.style.transform = "scale(.96)",
3287
+ onMouseUp: (e) => e.currentTarget.style.transform = "translateY(-2px) scale(1.04)"
3288
+ },
3289
+ ctaLabel
3290
+ ),
3291
+ /* @__PURE__ */ React2.createElement(
3292
+ "button",
3293
+ {
3294
+ onClick: () => isMobile ? setMobOpen((v) => !v) : setMenuOpen((v) => !v),
3295
+ "aria-label": "Menu",
3296
+ style: {
3297
+ background: menuOpen || mobOpen ? "rgba(255,255,255,.08)" : "rgba(255,255,255,.04)",
3298
+ border: `0.5px solid ${menuOpen || mobOpen ? "rgba(255,255,255,.15)" : "rgba(255,255,255,.08)"}`,
3299
+ borderRadius: 9,
3300
+ padding: "9px 11px",
3301
+ cursor: "pointer",
3302
+ display: "flex",
3303
+ alignItems: "center",
3304
+ justifyContent: "center",
3305
+ transition: skip ? "none" : "all .22s ease",
3306
+ animation: skip ? "none" : "nb-item-in .5s cubic-bezier(.16,1,.3,1) 630ms both"
3307
+ }
3308
+ },
3309
+ /* @__PURE__ */ React2.createElement(
3310
+ HamburgerIcon,
3311
+ {
3312
+ open: isMobile ? mobOpen : menuOpen,
3313
+ accent,
3314
+ textColor: text,
3315
+ skip
3316
+ }
3317
+ )
3318
+ )
3319
+ )
3320
+ ), /* @__PURE__ */ React2.createElement(
3321
+ CommandPalette,
3322
+ {
3323
+ open: cmdOpen,
3324
+ onClose: () => setCmdOpen(false),
3325
+ products,
3326
+ links,
3327
+ accent,
3328
+ text,
3329
+ muted,
3330
+ skip
3331
+ }
3332
+ ), /* @__PURE__ */ React2.createElement(
3333
+ MobileDrawer,
3334
+ {
3335
+ open: mobOpen,
3336
+ onClose: () => setMobOpen(false),
3337
+ links,
3338
+ products,
3339
+ ctaLabel,
3340
+ accent,
3341
+ text,
3342
+ muted,
3343
+ skip,
3344
+ onProductClick,
3345
+ onCtaClick
3346
+ }
3347
+ ), !isMobile && /* @__PURE__ */ React2.createElement(
3348
+ FullScreenMenu,
3349
+ {
3350
+ open: menuOpen,
3351
+ onClose: () => setMenuOpen(false),
3352
+ links,
3353
+ products,
3354
+ ctaLabel,
3355
+ accent,
3356
+ text,
3357
+ muted,
3358
+ skip,
3359
+ activeIdx,
3360
+ onLinkClick: handleLink,
3361
+ onProductClick,
3362
+ onCtaClick
3363
+ }
3364
+ ), /* @__PURE__ */ React2.createElement("div", { style: { height: TOTAL_H } }));
3365
+ }
3366
+
3367
+ // src/components/Spotlight/Spotlight.jsx
3368
+ import React3, { useState as useState3, useRef as useRef3, useEffect as useEffect3, useCallback as useCallback3 } from "react";
3369
+ var THEMES = {
3370
+ indigo: {
3371
+ spotlight: "rgba(99,102,241,0.18)",
3372
+ border: "99,102,241",
3373
+ glow: "#6366f1",
3374
+ bg: "#0a0a12",
3375
+ inner: "rgba(10,10,18,0.96)"
3376
+ },
3377
+ rose: {
3378
+ spotlight: "rgba(244,63,94,0.18)",
3379
+ border: "244,63,94",
3380
+ glow: "#f43f5e",
3381
+ bg: "#12080a",
3382
+ inner: "rgba(18,8,10,0.96)"
3383
+ },
3384
+ emerald: {
3385
+ spotlight: "rgba(16,185,129,0.18)",
3386
+ border: "16,185,129",
3387
+ glow: "#10b981",
3388
+ bg: "#08120f",
3389
+ inner: "rgba(8,18,15,0.96)"
3390
+ },
3391
+ amber: {
3392
+ spotlight: "rgba(245,158,11,0.18)",
3393
+ border: "245,158,11",
3394
+ glow: "#f59e0b",
3395
+ bg: "#120f08",
3396
+ inner: "rgba(18,15,8,0.96)"
3397
+ },
3398
+ sky: {
3399
+ spotlight: "rgba(14,165,233,0.18)",
3400
+ border: "14,165,233",
3401
+ glow: "#0ea5e9",
3402
+ bg: "#080f12",
3403
+ inner: "rgba(8,15,18,0.96)"
3404
+ },
3405
+ aurora: {
3406
+ spotlight: "rgba(168,85,247,0.18)",
3407
+ border: "168,85,247",
3408
+ glow: "#a855f7",
3409
+ bg: "#0e0a12",
3410
+ inner: "rgba(14,10,18,0.96)"
3411
+ }
3412
+ };
3413
+ var clamp2 = (v, mn, mx) => Math.min(Math.max(v, mn), mx);
3414
+ var injectGlobalStyles = () => {
3415
+ const id = "spotlight-card-global";
3416
+ if (document.getElementById(id)) return;
3417
+ const s = document.createElement("style");
3418
+ s.id = id;
3419
+ s.innerHTML = `
3420
+ @import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700&display=swap');
3421
+ .sc-root *, .sc-root *::before, .sc-root *::after { box-sizing: border-box; }
3422
+ @keyframes sc-ripple { 0%{transform:scale(0) translate(-50%,-50%);opacity:.6} 100%{transform:scale(4) translate(-50%,-50%);opacity:0} }
3423
+ @keyframes sc-badge-pulse{ 0%,100%{box-shadow:0 0 0 0 var(--bpulse,rgba(99,102,241,.5))} 50%{box-shadow:0 0 0 5px rgba(0,0,0,0)} }
3424
+ @keyframes sc-float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-7px)} }
3425
+ @keyframes sc-shimmer { 0%{background-position:-200% 0} 100%{background-position:200% 0} }
3426
+ @media(prefers-reduced-motion:reduce){ .sc-root,.sc-root *{ animation:none!important; transition:none!important; } }
3427
+ `;
3428
+ document.head.appendChild(s);
3429
+ };
3430
+ var Badge = ({ label, color = "#6366f1" }) => {
3431
+ const rgb = (() => {
3432
+ const r = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(color);
3433
+ return r ? `${parseInt(r[1], 16)},${parseInt(r[2], 16)},${parseInt(r[3], 16)}` : "99,102,241";
3434
+ })();
3435
+ return /* @__PURE__ */ React3.createElement(
3436
+ "span",
3437
+ {
3438
+ style: {
3439
+ "--bpulse": `rgba(${rgb},.5)`,
3440
+ display: "inline-flex",
3441
+ alignItems: "center",
3442
+ gap: 5,
3443
+ padding: "3px 10px",
3444
+ borderRadius: 999,
3445
+ fontSize: 10,
3446
+ fontWeight: 700,
3447
+ letterSpacing: "0.07em",
3448
+ textTransform: "uppercase",
3449
+ color,
3450
+ background: `rgba(${rgb},.12)`,
3451
+ border: `1px solid rgba(${rgb},.3)`,
3452
+ animation: "sc-badge-pulse 2s infinite",
3453
+ fontFamily: "DM Sans, sans-serif"
3454
+ }
3455
+ },
3456
+ /* @__PURE__ */ React3.createElement(
3457
+ "span",
3458
+ {
3459
+ style: { width: 6, height: 6, borderRadius: "50%", background: color }
3460
+ }
3461
+ ),
3462
+ label
3463
+ );
3464
+ };
3465
+ var SpotlightCard = ({
3466
+ children,
3467
+ theme = "indigo",
3468
+ customTheme = {},
3469
+ tilt = true,
3470
+ tiltStrength = 12,
3471
+ ripple = true,
3472
+ float = false,
3473
+ glass = false,
3474
+ loading = false,
3475
+ disabled = false,
3476
+ badge,
3477
+ badgeColor,
3478
+ borderRadius = "20px",
3479
+ padding = "28px",
3480
+ spotlightSize = "600px",
3481
+ transitionDuration = 0.3,
3482
+ onClick,
3483
+ className = "",
3484
+ style = {}
3485
+ }) => {
3486
+ const ref = useRef3(null);
3487
+ const rippleCount = useRef3(0);
3488
+ const [pos, setPos] = useState3({ x: 0, y: 0 });
3489
+ const [hovered, setHovered] = useState3(false);
3490
+ const [tiltXY, setTiltXY] = useState3({ x: 0, y: 0 });
3491
+ const [ripples, setRipples] = useState3([]);
3492
+ useEffect3(() => {
3493
+ injectGlobalStyles();
3494
+ }, []);
3495
+ const t = { ...THEMES[theme] ?? THEMES.indigo, ...customTheme };
3496
+ const td = `${transitionDuration}s`;
3497
+ const onMove = useCallback3(
3498
+ (e) => {
3499
+ if (disabled || !ref.current) return;
3500
+ const r = ref.current.getBoundingClientRect();
3501
+ const x = e.clientX - r.left, y = e.clientY - r.top;
3502
+ setPos({ x, y });
3503
+ if (tilt) {
3504
+ const cx = r.width / 2, cy = r.height / 2;
3505
+ setTiltXY({
3506
+ x: clamp2((y - cy) / cy * tiltStrength, -tiltStrength, tiltStrength),
3507
+ y: -clamp2(
3508
+ (x - cx) / cx * tiltStrength,
3509
+ -tiltStrength,
3510
+ tiltStrength
3511
+ )
3512
+ });
3513
+ }
3514
+ },
3515
+ [disabled, tilt, tiltStrength]
3516
+ );
3517
+ const onEnter = useCallback3(() => {
3518
+ if (!disabled) setHovered(true);
3519
+ }, [disabled]);
3520
+ const onLeave = useCallback3(() => {
3521
+ setHovered(false);
3522
+ setTiltXY({ x: 0, y: 0 });
3523
+ }, []);
3524
+ const onClickHandler = useCallback3(
3525
+ (e) => {
3526
+ if (disabled) return;
3527
+ onClick == null ? void 0 : onClick(e);
3528
+ if (!ripple || !ref.current) return;
3529
+ const r = ref.current.getBoundingClientRect();
3530
+ const id = ++rippleCount.current;
3531
+ setRipples((prev) => [
3532
+ ...prev,
3533
+ { x: e.clientX - r.left, y: e.clientY - r.top, id }
3534
+ ]);
3535
+ setTimeout(
3536
+ () => setRipples((prev) => prev.filter((rp) => rp.id !== id)),
3537
+ 650
3538
+ );
3539
+ },
3540
+ [disabled, onClick, ripple]
3541
+ );
3542
+ const transform = tilt && hovered ? `perspective(900px) rotateX(${tiltXY.x}deg) rotateY(${tiltXY.y}deg) scale(1.025)` : "perspective(900px) rotateX(0deg) rotateY(0deg) scale(1)";
3543
+ return /* @__PURE__ */ React3.createElement(
3544
+ "div",
3545
+ {
3546
+ ref,
3547
+ className: `sc-root ${className}`,
3548
+ onClick: onClickHandler,
3549
+ onMouseMove: onMove,
3550
+ onMouseEnter: onEnter,
3551
+ onMouseLeave: onLeave,
3552
+ onKeyDown: (e) => e.key === "Enter" && onClickHandler(e),
3553
+ role: onClick ? "button" : void 0,
3554
+ tabIndex: onClick && !disabled ? 0 : void 0,
3555
+ "aria-disabled": disabled,
3556
+ style: {
3557
+ position: "relative",
3558
+ borderRadius,
3559
+ padding: "1.5px",
3560
+ overflow: "hidden",
3561
+ cursor: disabled ? "not-allowed" : onClick ? "pointer" : "default",
3562
+ opacity: disabled ? 0.42 : 1,
3563
+ transition: `transform ${td} cubic-bezier(.22,1,.36,1), box-shadow ${td} ease`,
3564
+ transform,
3565
+ boxShadow: hovered ? `0 22px 60px rgba(${t.border},.22), 0 0 0 1px rgba(${t.border},.22)` : "0 4px 28px rgba(0,0,0,.45)",
3566
+ animation: float ? "sc-float 4s ease-in-out infinite" : "none",
3567
+ background: t.bg,
3568
+ ...style
3569
+ }
3570
+ },
3571
+ /* @__PURE__ */ React3.createElement(
3572
+ "div",
3573
+ {
3574
+ "aria-hidden": true,
3575
+ style: {
3576
+ position: "absolute",
3577
+ inset: 0,
3578
+ zIndex: 0,
3579
+ borderRadius,
3580
+ transition: `opacity ${td} ease`,
3581
+ opacity: hovered ? 1 : 0,
3582
+ background: `radial-gradient(260px circle at ${pos.x}px ${pos.y}px, ${t.glow}, transparent 70%)`
3583
+ }
3584
+ }
3585
+ ),
3586
+ /* @__PURE__ */ React3.createElement(
3587
+ "div",
3588
+ {
3589
+ style: {
3590
+ position: "relative",
3591
+ zIndex: 1,
3592
+ borderRadius: `calc(${borderRadius} - 1.5px)`,
3593
+ padding,
3594
+ height: "100%",
3595
+ color: "#fff",
3596
+ display: "flex",
3597
+ flexDirection: "column",
3598
+ gap: 12,
3599
+ fontFamily: "DM Sans, sans-serif",
3600
+ overflow: "hidden",
3601
+ ...glass ? {
3602
+ backdropFilter: "blur(18px) saturate(1.7)",
3603
+ background: "rgba(255,255,255,0.055)"
3604
+ } : { background: t.inner },
3605
+ ...loading ? {
3606
+ background: "linear-gradient(90deg,rgba(255,255,255,.04) 25%,rgba(255,255,255,.09) 50%,rgba(255,255,255,.04) 75%)",
3607
+ backgroundSize: "200% 100%",
3608
+ animation: "sc-shimmer 1.6s infinite linear",
3609
+ minHeight: 160
3610
+ } : {}
3611
+ }
3612
+ },
3613
+ /* @__PURE__ */ React3.createElement(
3614
+ "div",
3615
+ {
3616
+ "aria-hidden": true,
3617
+ style: {
3618
+ position: "absolute",
3619
+ inset: 0,
3620
+ pointerEvents: "none",
3621
+ zIndex: 2,
3622
+ borderRadius: `calc(${borderRadius} - 1.5px)`,
3623
+ transition: `opacity ${td} ease`,
3624
+ opacity: hovered ? 1 : 0,
3625
+ background: `radial-gradient(${spotlightSize} circle at ${pos.x}px ${pos.y}px, ${t.spotlight}, transparent 40%)`
3626
+ }
3627
+ }
3628
+ ),
3629
+ /* @__PURE__ */ React3.createElement(
3630
+ "div",
3631
+ {
3632
+ "aria-hidden": true,
3633
+ style: {
3634
+ position: "absolute",
3635
+ inset: 0,
3636
+ zIndex: 3,
3637
+ pointerEvents: "none",
3638
+ borderRadius: `calc(${borderRadius} - 1.5px)`,
3639
+ opacity: 0.028,
3640
+ backgroundImage: `url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")`,
3641
+ backgroundSize: "128px 128px"
3642
+ }
3643
+ }
3644
+ ),
3645
+ badge && !loading && /* @__PURE__ */ React3.createElement("div", { style: { position: "absolute", top: 14, right: 14, zIndex: 10 } }, /* @__PURE__ */ React3.createElement(Badge, { label: badge, color: badgeColor ?? t.glow })),
3646
+ !loading && /* @__PURE__ */ React3.createElement("div", { style: { position: "relative", zIndex: 5 } }, children),
3647
+ ripples.map((rp) => /* @__PURE__ */ React3.createElement(
3648
+ "span",
3649
+ {
3650
+ key: rp.id,
3651
+ "aria-hidden": true,
3652
+ style: {
3653
+ position: "absolute",
3654
+ left: rp.x,
3655
+ top: rp.y,
3656
+ width: 40,
3657
+ height: 40,
3658
+ borderRadius: "50%",
3659
+ background: `rgba(${t.border},.38)`,
3660
+ transform: "scale(0) translate(-50%,-50%)",
3661
+ pointerEvents: "none",
3662
+ animation: "sc-ripple 620ms ease-out forwards",
3663
+ zIndex: 10
3664
+ }
3665
+ }
3666
+ ))
3667
+ )
3668
+ );
3669
+ };
3670
+ export {
3671
+ MagneticButton,
3672
+ Navbar,
3673
+ SpotlightCard
3674
+ };