-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
1315 lines (1210 loc) · 78.5 KB
/
index.html
File metadata and controls
1315 lines (1210 loc) · 78.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="google-site-verification" content="oPRKrn_Mq5mw_lrzN8LYYtcmC7FEpbD8a7Xjrv6k_FM" />
<title>Velox — Professional PageSpeed & Performance Analyzer</title>
<!-- SEO Meta Tags -->
<meta name="description" content="Velox is a professional-grade web performance analyzer. Audit your website with Google PageSpeed Insights API, track Core Web Vitals, and optimize your site for speed with waterfall charts and diagnostics.">
<meta name="keywords" content="PageSpeed, Web Performance, Core Web Vitals, Website Audit, Velox Analyzer, Speed Optimization, Lighthouse Report, GTmetrix Alternative, PageSpeed Insights API">
<meta name="author" content="Velox Team">
<meta name="theme-color" content="#09090b">
<link rel="canonical" href="https://velox-analyzer.vercel.app/">
<!-- Open Graph / Facebook -->
<meta property="og:type" content="website">
<meta property="og:url" content="https://velox-analyzer.vercel.app/">
<meta property="og:site_name" content="Velox Analyzer">
<meta property="og:locale" content="en_US">
<meta property="og:title" content="Velox — Professional PageSpeed & Performance Analyzer">
<meta property="og:description" content="Audit your website speed and performance in seconds with Velox. Powered by Google PageSpeed Insights.">
<meta property="og:image" content="https://velox-analyzer.vercel.app/og-image.png">
<meta property="og:image:width" content="1200">
<meta property="og:image:height" content="630">
<!-- Twitter -->
<meta property="twitter:card" content="summary_large_image">
<meta property="twitter:url" content="https://velox-analyzer.vercel.app/">
<meta property="twitter:title" content="Velox — Professional PageSpeed & Performance Analyzer">
<meta property="twitter:description" content="Audit your website speed and performance in seconds with Velox. Powered by Google PageSpeed Insights.">
<meta property="twitter:image" content="https://velox-analyzer.vercel.app/og-image.png">
<link rel="icon" type="image/png" href="favicon.png">
<!-- Structured Data -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "WebApplication",
"name": "Velox Analyzer",
"url": "https://velox-analyzer.vercel.app/",
"description": "Professional web performance analyzer powered by Google PageSpeed Insights. Track Core Web Vitals, analyze waterfall charts, and optimize site speed.",
"applicationCategory": "DeveloperApplication",
"genre": "Web Performance Tool",
"browserRequirements": "requires HTML5 support",
"softwareVersion": "1.2.0",
"operatingSystem": "All",
"author": {
"@type": "Organization",
"name": "Velox"
},
"offers": {
"@type": "Offer",
"price": "0",
"priceCurrency": "USD"
}
}
</script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@300;400;500&display=swap" rel="stylesheet">
<style>
*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
:root{
--bg:#09090b;--s1:#111113;--s2:#18181b;--s3:#27272a;--s4:#3f3f46;
--bd:rgba(255,255,255,0.06);--bd2:rgba(255,255,255,0.1);--bd3:rgba(255,255,255,0.18);
--t1:#fafafa;--t2:#a1a1aa;--t3:#71717a;--t4:#3f3f46;
--acc:#99f6e4;--acc2:#6366f1;--acc3:#f59e0b;
--good:#22c55e;--warn:#f59e0b;--bad:#ef4444;--info:#3b82f6;
--r:6px;--rl:10px;--rxl:14px;
--fh:'Inter',sans-serif;--fm:'JetBrains Mono',monospace;
}
html{scroll-behavior:smooth}
body{background:var(--bg);color:var(--t1);font-family:var(--fh);min-height:100vh;overflow-x:hidden;-webkit-font-smoothing:antialiased;font-size:14px;line-height:1.5}
button,input,select{font-family:var(--fh)}
::-webkit-scrollbar{width:4px;height:4px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:var(--s4);border-radius:2px}
/* ── PAGES ── */
.page{display:none}.page.active{display:block}
/* ── NAV ── */
nav{position:sticky;top:0;z-index:600;height:52px;display:flex;align-items:center;justify-content:space-between;padding:0 28px;border-bottom:1px solid var(--bd);background:rgba(9,9,11,.94);backdrop-filter:blur(20px)}
.logo{display:flex;align-items:center;gap:8px;cursor:pointer;user-select:none}
.lm{width:26px;height:26px;background:var(--acc);border-radius:6px;display:flex;align-items:center;justify-content:center;flex-shrink:0}
.lm svg{width:12px;height:12px}
.lt{font-size:1rem;font-weight:700;letter-spacing:-.5px}
.nav-c{display:flex;gap:1px}
.na{font-size:.8rem;color:var(--t2);padding:5px 11px;border-radius:5px;cursor:pointer;border:none;background:transparent;transition:color .15s,background .15s}
.na:hover{color:var(--t1);background:rgba(255,255,255,.05)}
.nav-r{display:flex;gap:8px;align-items:center}
.nb{background:var(--t1);color:#09090b;font-size:.79rem;font-weight:600;padding:6px 16px;border-radius:5px;border:none;cursor:pointer;transition:background .15s}
.nb:hover{background:#e4e4e7}
/* ── HOME HERO ── */
.hero{position:relative;padding:72px 28px 60px;overflow:hidden}
.hgrid{position:absolute;inset:0;background-image:linear-gradient(rgba(255,255,255,.022) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.022) 1px,transparent 1px);background-size:36px 36px;mask-image:radial-gradient(ellipse 75% 55% at 50% 0,black,transparent);pointer-events:none}
.hglow{position:absolute;top:-80px;left:50%;transform:translateX(-50%);width:700px;height:380px;background:radial-gradient(ellipse at center,rgba(153,246,228,.07) 0%,transparent 65%);pointer-events:none}
.hero-in{max-width:1080px;margin:0 auto;position:relative}
.htag{display:inline-flex;align-items:center;gap:6px;background:var(--s2);border:1px solid var(--bd2);border-radius:20px;padding:3px 12px 3px 8px;font-size:.69rem;font-family:var(--fm);color:var(--t2);margin-bottom:26px}
.ld{width:5px;height:5px;border-radius:50%;background:var(--good);animation:ld 2s ease infinite}
@keyframes ld{0%,100%{opacity:1}50%{opacity:.2}}
h1.hero-h{font-size:clamp(2.4rem,5vw,4.4rem);font-weight:700;line-height:1.05;letter-spacing:-2px;margin-bottom:18px}
h1.hero-h em{font-style:normal;color:var(--acc);font-weight:300}
.hsub{font-size:.95rem;color:var(--t2);font-weight:300;max-width:480px;line-height:1.75;margin-bottom:40px}
/* ── INPUT ── */
.iw{max-width:700px}
.ibox{display:flex;align-items:center;background:var(--s1);border:1px solid var(--bd2);border-radius:11px;padding:4px 4px 4px 16px;gap:8px;transition:border-color .2s,box-shadow .2s}
.ibox:focus-within{border-color:rgba(153,246,228,.45);box-shadow:0 0 0 3px rgba(153,246,228,.07)}
.ii{color:var(--t3);flex-shrink:0}
#urlInput{flex:1;background:transparent;border:none;outline:none;color:var(--t1);font-size:.93rem;min-width:0}
#urlInput::placeholder{color:var(--t3)}
.sg{display:flex;background:var(--s2);border-radius:6px;padding:3px;gap:2px;flex-shrink:0}
.sb{font-size:.72rem;font-weight:500;padding:5px 11px;border-radius:4px;border:none;cursor:pointer;background:transparent;color:var(--t3);transition:all .15s}
.sb.on{background:var(--s3);color:var(--t1)}
.rbtn{background:var(--acc);color:#09090b;font-weight:700;font-size:.82rem;padding:10px 20px;border-radius:8px;border:none;cursor:pointer;display:flex;align-items:center;gap:6px;transition:all .15s;flex-shrink:0;white-space:nowrap}
.rbtn:hover{background:#6ee7d4}
.rbtn:active{transform:scale(.97)}
.imeta{font-size:.7rem;color:var(--t3);font-family:var(--fm);margin-top:9px;display:flex;align-items:center;gap:10px}
.md{width:2px;height:2px;background:var(--t4);border-radius:50%}
/* ── TRUST ── */
.trust{display:grid;grid-template-columns:repeat(4,1fr);border-top:1px solid var(--bd);background:var(--s1)}
.ti{padding:20px 24px;border-right:1px solid var(--bd)}
.ti:last-child{border-right:none}
.tn{font-size:1.8rem;font-weight:700;letter-spacing:-1px;margin-bottom:3px}
.tl{font-size:.75rem;color:var(--t3);font-weight:300}
/* ── OVERLAY ── */
#ov{display:none;position:fixed;inset:0;z-index:900;background:rgba(9,9,11,.97);backdrop-filter:blur(12px);align-items:center;justify-content:center}
#ov.on{display:flex}
.ov-w{width:540px;max-width:90vw}
.ov-url{font-family:var(--fm);font-size:.73rem;color:var(--t3);margin-bottom:22px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ov-h{font-size:1.7rem;font-weight:700;letter-spacing:-1px;margin-bottom:6px}
.ov-s{font-size:.82rem;color:var(--t3);margin-bottom:36px;font-weight:300}
.ov-track{height:2px;background:var(--s3);border-radius:1px;overflow:hidden;margin-bottom:28px}
.ov-fill{height:100%;background:var(--acc);border-radius:1px;width:0%;transition:width .6s ease}
.ov-steps{display:flex;flex-direction:column;gap:0}
.ovs{display:flex;align-items:center;gap:12px;padding:10px 0;border-bottom:1px solid var(--bd);opacity:.25;transition:opacity .3s}
.ovs:last-child{border-bottom:none}
.ovs.on{opacity:1}
.ovs.done{opacity:.55}
.ovs-ic{width:28px;height:28px;border-radius:7px;background:var(--s2);border:1px solid var(--bd);display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:all .3s}
.ovs.on .ovs-ic{background:rgba(153,246,228,.1);border-color:rgba(153,246,228,.3)}
.ovs.done .ovs-ic{background:rgba(34,197,94,.1);border-color:rgba(34,197,94,.25)}
.ovs-n{font-size:.82rem;font-weight:500}
.ovs-d{font-size:.7rem;color:var(--t3);margin-top:1px}
.ovs-p{font-family:var(--fm);font-size:.69rem;color:var(--t3);margin-left:auto;flex-shrink:0}
.ovs.on .ovs-p{color:var(--acc)}
@keyframes spin{to{transform:rotate(360deg)}}
.spin{animation:spin .8s linear infinite}
/* ── ERROR ── */
.errw{max-width:520px;margin:52px auto;padding:0 28px;text-align:center}
.errw h3{font-size:.95rem;font-weight:600;color:var(--bad);margin-bottom:8px}
.errw p{font-size:.81rem;color:var(--t3);line-height:1.65}
.errw button{margin-top:18px;background:var(--s2);border:1px solid var(--bd2);color:var(--t1);padding:8px 18px;border-radius:var(--r);cursor:pointer;font-size:.8rem;transition:background .15s}
.errw button:hover{background:var(--s3)}
/* ── RESULTS WRAPPER ── */
.res-wrap{max-width:1080px;margin:0 auto;padding:32px 28px 80px}
/* ── REPORT HEADER ── */
.rpt-hd{display:grid;grid-template-columns:160px 1fr;gap:18px;margin-bottom:28px;align-items:start}
.grade-card{background:var(--s1);border:1px solid var(--bd);border-radius:var(--rxl);padding:24px 18px;display:flex;flex-direction:column;align-items:center;gap:10px;text-align:center;position:sticky;top:68px}
.g-ring{position:relative;width:108px;height:108px}
.g-ring svg{width:108px;height:108px;transform:rotate(-90deg)}
.gbg{fill:none;stroke:var(--s3);stroke-width:7}
.gv{fill:none;stroke-width:7;stroke-linecap:round;stroke-dasharray:289.03;stroke-dashoffset:289.03;transition:stroke-dashoffset 1s ease,stroke .4s}
.gnum{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;line-height:1}
.gnum span{font-size:2.3rem;font-weight:700;font-family:var(--fm);letter-spacing:-1px}
.gnum small{font-size:.58rem;color:var(--t3);margin-top:3px;letter-spacing:.06em;text-transform:uppercase}
.gletter{font-size:1.8rem;font-weight:700;font-family:var(--fm)}
.gurl{font-family:var(--fm);font-size:.62rem;color:var(--t3);word-break:break-all;line-height:1.5;padding:0 4px}
.gstrat{font-family:var(--fm);font-size:.6rem;color:var(--t4)}
/* ── SCORE BADGES ── */
.score-badges{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:12px}
.sc-badge{background:var(--s1);border:1px solid var(--bd);border-radius:var(--rl);padding:14px 16px}
.sc-lbl{font-size:.66rem;color:var(--t3);font-family:var(--fm);letter-spacing:.07em;text-transform:uppercase;margin-bottom:7px}
.sc-val{font-size:1.75rem;font-weight:700;font-family:var(--fm);letter-spacing:-1px;line-height:1;margin-bottom:8px}
.sc-bar{height:3px;background:var(--s3);border-radius:2px;overflow:hidden}
.sc-fill{height:100%;border-radius:2px;transition:width 1s ease}
/* ── VITALS GRID ── */
.vgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.vit{background:var(--s1);border:1px solid var(--bd);border-radius:var(--rl);padding:14px 16px;position:relative;overflow:hidden;transition:border-color .2s,transform .15s;cursor:default}
.vit:hover{border-color:var(--bd2);transform:translateY(-1px)}
.vit::before{content:'';position:absolute;top:0;left:0;right:0;height:2px}
.vit.good::before{background:var(--good)}.vit.avg::before{background:var(--warn)}.vit.bad::before{background:var(--bad)}
.vk{font-family:var(--fm);font-size:.63rem;color:var(--t3);text-transform:uppercase;letter-spacing:.08em;margin-bottom:9px;display:flex;align-items:center;justify-content:space-between}
.vb{font-size:.61rem;padding:2px 6px;border-radius:8px;font-weight:600}
.vit.good .vb{background:rgba(34,197,94,.12);color:var(--good)}
.vit.avg .vb{background:rgba(245,158,11,.12);color:var(--warn)}
.vit.bad .vb{background:rgba(239,68,68,.12);color:var(--bad)}
.vval{font-size:1.8rem;font-weight:700;font-family:var(--fm);letter-spacing:-1px;line-height:1}
.vunit{font-size:.82rem;color:var(--t3);margin-left:1px;font-weight:300}
.vname{font-size:.72rem;color:var(--t2);margin-top:4px}
.vdv{font-size:.67rem;color:var(--t3);margin-top:1px}
/* ── TABS ── */
.tab-bar{display:flex;border-bottom:1px solid var(--bd);overflow-x:auto;background:var(--s1);border-radius:var(--rxl) var(--rxl) 0 0;margin-bottom:0;padding:0 4px}
.tb{font-size:.78rem;font-weight:500;padding:10px 16px;border:none;background:transparent;color:var(--t3);cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-1px;white-space:nowrap;transition:color .15s,border-color .15s}
.tb.on{color:var(--t1);border-bottom-color:var(--acc)}
.tp{display:none}.tp.on{display:block}
.tab-wrap{background:var(--s1);border:1px solid var(--bd);border-radius:var(--rxl);overflow:hidden}
/* ── SUMMARY TAB ── */
.sum-grid{display:grid;grid-template-columns:1fr 1fr;gap:0;border-bottom:1px solid var(--bd)}
.sum-block{padding:20px 22px;border-right:1px solid var(--bd)}
.sum-block:last-child,.sum-block:nth-child(2){border-right:none}
.sum-block:nth-child(3),.sum-block:nth-child(4){border-top:1px solid var(--bd)}
.sb-label{font-size:.67rem;color:var(--t3);font-family:var(--fm);letter-spacing:.07em;text-transform:uppercase;margin-bottom:14px}
/* SPEED VIZ */
.speed-viz{position:relative;height:56px;background:var(--s2);border-radius:var(--r);overflow:hidden;margin:0 22px 20px}
.sv-track{position:absolute;top:50%;left:0;right:0;height:1px;background:var(--s4);transform:translateY(-50%)}
.sv-marker{position:absolute;top:0;bottom:0;width:2px;border-radius:1px}
.sv-marker-label{position:absolute;top:4px;font-size:.58rem;font-family:var(--fm);white-space:nowrap;transform:translateX(-50%)}
.sv-milestone{position:absolute;bottom:4px;font-size:.58rem;font-family:var(--fm);color:var(--t3);transform:translateX(-50%)}
.sv-dot{position:absolute;width:8px;height:8px;border-radius:50%;top:50%;transform:translate(-50%,-50%);border:2px solid var(--bg)}
/* TOP ISSUES */
.issue-row{display:flex;align-items:flex-start;gap:10px;padding:11px 0;border-bottom:1px solid var(--bd)}
.issue-row:last-child{border-bottom:none}
.issue-dot{width:6px;height:6px;border-radius:50%;flex-shrink:0;margin-top:4px}
.issue-t{font-size:.8rem;font-weight:500;margin-bottom:2px}
.issue-d{font-size:.72rem;color:var(--t3);line-height:1.5}
/* PAGE DETAILS */
.pd-row{display:flex;align-items:center;gap:10px;padding:9px 0;border-bottom:1px solid var(--bd)}
.pd-row:last-child{border-bottom:none}
.pd-color{width:10px;height:10px;border-radius:2px;flex-shrink:0}
.pd-name{flex:1;font-size:.8rem;color:var(--t2)}
.pd-size{font-family:var(--fm);font-size:.75rem;color:var(--t1)}
.pd-pct{font-family:var(--fm);font-size:.7rem;color:var(--t3);width:36px;text-align:right}
.pd-bar-w{width:80px;height:4px;background:var(--s3);border-radius:2px;overflow:hidden}
.pd-bar{height:100%;border-radius:2px}
/* ── PERFORMANCE TAB ── */
.perf-metrics{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;padding:18px}
.pm-card{background:var(--s2);border-radius:var(--rl);padding:14px 16px}
.pm-lbl{font-size:.66rem;color:var(--t3);font-family:var(--fm);letter-spacing:.06em;text-transform:uppercase;margin-bottom:6px}
.pm-val{font-size:1.4rem;font-weight:600;font-family:var(--fm);letter-spacing:-.5px}
.pm-info{font-size:.7rem;color:var(--t3);margin-top:3px}
.metric-bar-wrap{height:3px;background:var(--s3);border-radius:2px;margin-top:8px;overflow:hidden}
.metric-bar{height:100%;border-radius:2px;transition:width 1s ease}
/* ── STRUCTURE TAB ── */
.str-row{display:flex;align-items:flex-start;gap:12px;padding:13px 18px;border-bottom:1px solid var(--bd);transition:background .15s;cursor:default}
.str-row:last-child{border-bottom:none}
.str-row:hover{background:rgba(255,255,255,.012)}
.str-ic{width:16px;height:16px;flex-shrink:0;margin-top:1px}
.str-body{flex:1;min-width:0}
.str-t{font-size:.81rem;font-weight:500;margin-bottom:2px}
.str-d{font-size:.72rem;color:var(--t3);line-height:1.5}
.str-imp{font-family:var(--fm);font-size:.68rem;padding:2px 7px;border-radius:4px;font-weight:500;white-space:nowrap;flex-shrink:0}
.str-imp.hi{background:rgba(239,68,68,.1);color:#f87171}
.str-imp.md{background:rgba(245,158,11,.1);color:#fbbf24}
.str-imp.lo{background:rgba(34,197,94,.1);color:#4ade80}
.str-imp.pass{background:rgba(34,197,94,.08);color:var(--good)}
/* ── CRUX TAB ── */
.crux-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;padding:18px}
.crux-card{background:var(--s2);border-radius:var(--rl);padding:16px 18px}
.crux-label{font-size:.66rem;color:var(--t3);font-family:var(--fm);letter-spacing:.07em;text-transform:uppercase;margin-bottom:10px}
.crux-val{font-size:1.6rem;font-weight:700;font-family:var(--fm);letter-spacing:-.5px;margin-bottom:6px}
.crux-desc{font-size:.7rem;color:var(--t3);margin-bottom:10px;line-height:1.5}
.crux-dist{display:flex;height:6px;border-radius:3px;overflow:hidden;gap:2px}
.crux-seg{height:100%;border-radius:3px;transition:width .8s ease}
.crux-legend{display:flex;gap:12px;margin-top:7px}
.crux-leg{display:flex;align-items:center;gap:4px;font-size:.66rem;color:var(--t3)}
.crux-leg-dot{width:7px;height:7px;border-radius:50%}
.crux-no{padding:36px 18px;text-align:center;color:var(--t3);font-size:.82rem;grid-column:1/-1}
.crux-pass-badge{display:inline-flex;align-items:center;gap:5px;font-size:.72rem;padding:4px 10px;border-radius:20px;font-weight:500;margin-top:8px}
.crux-pass-badge.pass{background:rgba(34,197,94,.12);color:var(--good)}
.crux-pass-badge.fail{background:rgba(239,68,68,.12);color:var(--bad)}
.crux-pass-badge.avg{background:rgba(245,158,11,.12);color:var(--warn)}
/* ── WATERFALL TAB ── */
.wf-hdr{display:grid;grid-template-columns:2.5fr 70px 80px 1fr;gap:0;padding:8px 16px;font-family:var(--fm);font-size:.64rem;color:var(--t3);text-transform:uppercase;letter-spacing:.07em;background:var(--s2);border-bottom:1px solid var(--bd)}
.wf-row{display:grid;grid-template-columns:2.5fr 70px 80px 1fr;align-items:center;padding:8px 16px;border-bottom:1px solid var(--bd);font-size:.76rem;transition:background .15s;cursor:default}
.wf-row:last-child{border-bottom:none}
.wf-row:hover{background:rgba(255,255,255,.012)}
.wf-name{display:flex;align-items:center;gap:7px;overflow:hidden}
.wf-typedot{width:7px;height:7px;border-radius:2px;flex-shrink:0}
.wf-url{font-family:var(--fm);font-size:.72rem;color:var(--t2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.wf-n{font-family:var(--fm);font-size:.73rem;color:var(--t1)}
.wf-bw{height:12px;background:var(--s3);border-radius:2px;overflow:hidden;position:relative}
.wf-b{position:absolute;top:0;bottom:0;border-radius:2px;opacity:.85}
/* ── RESOURCES TAB ── */
.rtbl{width:100%;border-collapse:collapse}
.rtbl th{text-align:left;font-family:var(--fm);font-size:.64rem;color:var(--t3);letter-spacing:.07em;text-transform:uppercase;padding:8px 14px;border-bottom:1px solid var(--bd);font-weight:400}
.rtbl td{padding:9px 14px;border-bottom:1px solid var(--bd);font-size:.78rem;vertical-align:middle}
.rtbl tr:last-child td{border-bottom:none}
.rtbl tr:hover td{background:rgba(255,255,255,.012)}
.rtype{display:inline-block;font-size:.61rem;padding:2px 6px;border-radius:3px;font-weight:600;text-transform:uppercase;letter-spacing:.04em;font-family:var(--fm)}
.rtype.script{background:rgba(245,158,11,.12);color:#fbbf24}
.rtype.stylesheet{background:rgba(99,102,241,.12);color:#818cf8}
.rtype.image{background:rgba(34,197,94,.12);color:#4ade80}
.rtype.document{background:rgba(153,246,228,.1);color:var(--acc)}
.rtype.font{background:rgba(244,114,182,.12);color:#f472b6}
.rtype.fetch,.rtype.xhr{background:rgba(59,130,246,.1);color:#60a5fa}
.rtype.other{background:rgba(113,113,122,.1);color:#888}
.rb-w{height:4px;background:var(--s3);border-radius:2px;min-width:70px}
.rb{height:100%;border-radius:2px;background:var(--info)}
/* ── HISTORY TAB ── */
.hist-empty{padding:48px 28px;text-align:center;color:var(--t3);font-size:.82rem}
.hist-row{display:grid;grid-template-columns:1fr 80px 80px 80px 100px;align-items:center;padding:12px 18px;border-bottom:1px solid var(--bd);transition:background .15s;cursor:default}
.hist-row:last-child{border-bottom:none}
.hist-row:hover{background:rgba(255,255,255,.012)}
.hist-hdr{font-family:var(--fm);font-size:.63rem;color:var(--t3);text-transform:uppercase;letter-spacing:.07em;background:var(--s2)}
.hist-url{font-family:var(--fm);font-size:.73rem;color:var(--t2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hist-date{font-family:var(--fm);font-size:.7rem;color:var(--t3)}
.grade-pill{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;border-radius:6px;font-weight:700;font-size:.85rem;font-family:var(--fm)}
.grade-A{background:rgba(34,197,94,.15);color:var(--good)}
.grade-B{background:rgba(153,246,228,.1);color:var(--acc)}
.grade-C{background:rgba(245,158,11,.12);color:var(--warn)}
.grade-D,.grade-E,.grade-F{background:rgba(239,68,68,.12);color:var(--bad)}
.hist-clear{margin:12px 18px;font-size:.74rem;color:var(--t3);cursor:pointer;text-decoration:underline;text-underline-offset:2px;background:none;border:none;transition:color .15s}
.hist-clear:hover{color:var(--bad)}
/* ── INNER PAGES ── */
.ip{max-width:820px;margin:0 auto;padding:48px 28px 80px}
.ip-lbl{font-size:.67rem;color:var(--t3);font-family:var(--fm);letter-spacing:.1em;text-transform:uppercase;margin-bottom:10px}
.ip-title{font-size:clamp(1.8rem,3.5vw,2.8rem);font-weight:700;letter-spacing:-1.5px;line-height:1.05;margin-bottom:12px}
.ip-sub{font-size:.92rem;color:var(--t2);font-weight:300;line-height:1.72;max-width:540px;margin-bottom:36px;padding-bottom:28px;border-bottom:1px solid var(--bd)}
.ip-body h2{font-size:1.3rem;font-weight:700;letter-spacing:-.5px;margin:32px 0 10px}
.ip-body h3{font-size:.9rem;font-weight:600;margin:20px 0 7px}
.ip-body p{font-size:.84rem;color:var(--t2);line-height:1.8;margin-bottom:12px;font-weight:300}
.ip-body ul,.ip-body ol{padding-left:18px;margin-bottom:12px}
.ip-body li{font-size:.83rem;color:var(--t2);line-height:1.75;font-weight:300;margin-bottom:3px}
.ip-body code{font-family:var(--fm);font-size:.77rem;background:var(--s2);border:1px solid var(--bd);padding:1px 6px;border-radius:3px;color:var(--acc)}
.ip-body pre{background:var(--s1);border:1px solid var(--bd);border-radius:var(--rl);padding:18px 20px;overflow-x:auto;margin:14px 0 18px}
.ip-body pre code{background:transparent;border:none;padding:0;color:var(--t1);font-size:.78rem;line-height:1.7}
.note-box{background:rgba(153,246,228,.04);border:1px solid rgba(153,246,228,.15);border-radius:var(--rl);padding:12px 16px;margin:14px 0}
.note-box p{margin:0;color:var(--t1)}
.warn-box{background:rgba(245,158,11,.04);border:1px solid rgba(245,158,11,.2);border-radius:var(--rl);padding:12px 16px;margin:14px 0}
.warn-box p{margin:0}
.ip-divider{height:1px;background:var(--bd);margin:28px 0}
.ip-body table{width:100%;border-collapse:collapse;margin:12px 0 18px;font-size:.8rem}
.ip-body table th{text-align:left;font-family:var(--fm);font-size:.63rem;color:var(--t3);letter-spacing:.07em;text-transform:uppercase;padding:7px 12px;border-bottom:1px solid var(--bd);font-weight:400}
.ip-body table td{padding:9px 12px;border-bottom:1px solid var(--bd);color:var(--t2);font-weight:300}
.ip-body table tr:last-child td{border-bottom:none}
/* STATUS */
.st-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;margin:18px 0}
.st-item{background:var(--s1);border:1px solid var(--bd);border-radius:var(--rl);padding:14px 16px;display:flex;align-items:center;gap:10px}
.st-dot{width:9px;height:9px;border-radius:50%;flex-shrink:0}
.st-dot.op{background:var(--good);box-shadow:0 0 7px rgba(34,197,94,.5)}
.st-n{font-size:.82rem;font-weight:500}
.st-d{font-size:.7rem;color:var(--t3);margin-top:1px}
.ub-wrap{display:flex;gap:2px;margin:12px 0 5px}
.ub{flex:1;height:24px;border-radius:2px}
/* FEATURES SECTION */
.feat-sec{background:var(--s1);border-top:1px solid var(--bd);padding:64px 28px}
.feat-in{max-width:1080px;margin:0 auto}
.feat-hd{display:flex;align-items:flex-end;justify-content:space-between;margin-bottom:36px;flex-wrap:wrap;gap:14px}
.feat-hd h2{font-size:clamp(1.6rem,2.8vw,2.3rem);font-weight:700;letter-spacing:-1px}
.feat-hd p{font-size:.8rem;color:var(--t3);max-width:280px;line-height:1.7;font-weight:300;text-align:right}
.fgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:1px;border:1px solid var(--bd);border-radius:var(--rxl);overflow:hidden;background:var(--bd)}
.fc{background:var(--s1);padding:24px;transition:background .2s}
.fc:hover{background:var(--s2)}
.fcn{font-family:var(--fm);font-size:.62rem;color:var(--t4);letter-spacing:.1em;margin-bottom:16px}
.fci{width:32px;height:32px;border-radius:7px;border:1px solid var(--bd2);display:flex;align-items:center;justify-content:center;margin-bottom:13px}
.fc h3{font-size:.9rem;font-weight:600;letter-spacing:-.2px;margin-bottom:6px}
.fc p{font-size:.78rem;color:var(--t3);line-height:1.68;font-weight:300}
/* FOOTER */
footer{border-top:1px solid var(--bd);padding:24px 28px;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px;background:var(--s1)}
.fbrand{font-size:.82rem;font-weight:700;display:flex;align-items:center;gap:7px}
.flinks{display:flex;flex-wrap:wrap}
.fl{font-size:.75rem;color:var(--t3);padding:3px 11px;cursor:pointer;border:none;background:transparent;transition:color .15s;border-right:1px solid var(--bd)}
.fl:last-child{border-right:none}
.fl:hover{color:var(--t1)}
.fcopy{font-size:.7rem;color:var(--t4)}
/* ADS */
.ad-side{position:fixed;right:18px;top:80px;z-index:500;width:160px;height:600px;background:var(--s1);border:1px solid var(--bd);border-radius:var(--r);display:none;overflow:hidden}
@media(min-width:1480px){.ad-side{display:block}}
/* ANIM */
@keyframes fu{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
.fu{animation:fu .38s ease both}
.d1{animation-delay:.04s}.d2{animation-delay:.08s}.d3{animation-delay:.12s}.d4{animation-delay:.16s}.d5{animation-delay:.2s}
/* RESPONSIVE */
@media(max-width:800px){
nav,footer,.hero,.feat-sec{padding-left:16px;padding-right:16px}
.res-wrap,.ip{padding-left:16px;padding-right:16px}
.rpt-hd,.trust,.fgrid{grid-template-columns:1fr}
.vgrid,.score-badges,.crux-grid,.perf-metrics,.sum-grid,.st-grid{grid-template-columns:1fr}
.nav-c{display:none}
.ti{border-right:none;border-bottom:1px solid var(--bd)}
.wf-hdr,.wf-row{grid-template-columns:2fr 60px 1fr}
.hist-row,.hist-hdr{grid-template-columns:1fr 60px 60px}
.hero{padding-top:48px;padding-bottom:40px}
h1.hero-h{font-size:2.4rem;letter-spacing:-1px}
.ibox{flex-direction:column;padding:12px;gap:12px;align-items:stretch}
#urlInput{padding:8px 0}
.sg{width:100%;justify-content:center}
.rbtn{width:100%;justify-content:center}
.feat-hd{text-align:center;justify-content:center}
.feat-hd p{text-align:center;max-width:100%}
}
</style>
</head>
<body>
<!-- NAV -->
<nav>
<div class="logo" onclick="goHome()" role="button" aria-label="Velox Home">
<div class="lm" aria-hidden="true"><svg viewBox="0 0 12 12" fill="none"><polygon points="6,0 12,6 6,12 0,6" fill="#09090b"/></svg></div>
<span class="lt">Velox</span>
</div>
<div class="nav-c">
<button class="na" onclick="showPage('docs')">Docs</button>
<button class="na" onclick="showPage('api')">API</button>
<button class="na" onclick="showPage('status')">Status</button>
</div>
<div class="nav-r">
<button class="nb" onclick="goHome()">Analyze a site →</button>
</div>
</nav>
<!-- ════════════════ HOME ════════════════ -->
<div class="page active" id="pg-home">
<div class="hero">
<div class="hgrid"></div>
<div class="hglow"></div>
<div class="hero-in">
<div class="htag"><span class="ld"></span>Real Lighthouse · Google PageSpeed Insights · No signup</div>
<h1 class="hero-h">Is your website<br><em>fast enough?</em></h1>
<p class="hsub">Enter any URL and get a full GTmetrix-style report — Core Web Vitals, waterfall, CrUX field data, opportunities, diagnostics, and history. Free forever.</p>
<div class="iw">
<div class="ibox">
<svg class="ii" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="12" r="10"/><path d="M2 12h20M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z"/></svg>
<input id="urlInput" type="text" placeholder="https://yourwebsite.com" autocomplete="off" spellcheck="false"/>
<div class="sg">
<button class="sb on" id="sMob" onclick="setSt('mobile')">Mobile</button>
<button class="sb" id="sDsk" onclick="setSt('desktop')">Desktop</button>
</div>
<button class="rbtn" onclick="runAudit()" aria-label="Run Performance Audit">
<svg width="11" height="11" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><polygon points="5 3 19 12 5 21 5 3"/></svg>
Analyze
</button>
</div>
<div class="imeta">
<span>Enter ↵ to run</span><span class="md"></span>
<span>Free forever</span><span class="md"></span>
<span>No account needed</span><span class="md"></span>
<span>Powered by Google PSI</span>
</div>
</div>
</div>
</div>
<div class="trust">
<div class="ti"><div class="tn">7 tabs</div><div class="tl">Summary · Performance · Structure · CrUX · Waterfall · Resources · History</div></div>
<div class="ti"><div class="tn">17+</div><div class="tl">Performance metrics tracked</div></div>
<div class="ti"><div class="tn">CrUX</div><div class="tl">Real user field data from Chrome</div></div>
<div class="ti"><div class="tn">Free</div><div class="tl">No account, no limits</div></div>
</div>
<!-- ERROR -->
<div id="errBox" style="display:none" class="errw">
<h3>Audit failed</h3>
<p id="errMsg"></p>
<button onclick="goHome()">← Try another URL</button>
</div>
<!-- RESULTS -->
<div id="resBox" style="display:none">
<div class="res-wrap">
<!-- HEADER: grade ring + score badges + vitals -->
<div class="rpt-hd fu d1">
<div class="grade-card">
<div class="g-ring">
<svg viewBox="0 0 108 108"><circle class="gbg" cx="54" cy="54" r="46"/><circle class="gv" id="garc" cx="54" cy="54" r="46"/></svg>
<div class="gnum"><span id="gnum">—</span><small>Grade</small></div>
</div>
<div class="gletter" id="gletter">—</div>
<div class="gurl" id="gurl">—</div>
<div class="gstrat" id="gstrat">—</div>
</div>
<div>
<div class="score-badges fu d2">
<div class="sc-badge">
<div class="sc-lbl">Performance Score</div>
<div class="sc-val" id="perfScoreVal">—</div>
<div class="sc-bar"><div class="sc-fill" id="perfScoreBar"></div></div>
</div>
<div class="sc-badge">
<div class="sc-lbl">Structure Score</div>
<div class="sc-val" id="structScoreVal">—</div>
<div class="sc-bar"><div class="sc-fill" id="structScoreBar"></div></div>
</div>
</div>
<div class="vgrid fu d3" id="vgrid"></div>
</div>
</div>
<!-- MAIN TABS -->
<div class="fu d4">
<div class="tab-wrap">
<div class="tab-bar">
<button class="tb on" onclick="swTab('sum')">Summary</button>
<button class="tb" onclick="swTab('perf')">Performance</button>
<button class="tb" onclick="swTab('str')">Structure</button>
<button class="tb" onclick="swTab('crux')">CrUX</button>
<button class="tb" onclick="swTab('wfall')">Waterfall</button>
<button class="tb" onclick="swTab('res')">Resources</button>
<button class="tb" onclick="swTab('hist')">History</button>
</div>
<!-- SUMMARY -->
<div class="tp on" id="tp-sum">
<div style="padding:14px 22px 0;font-size:.72rem;color:var(--t3);font-family:var(--fm);text-transform:uppercase;letter-spacing:.07em">Speed Visualization</div>
<div class="speed-viz" id="speedViz"></div>
<div class="sum-grid">
<div class="sum-block">
<div class="sb-label">Top Issues</div>
<div id="topIssues"></div>
</div>
<div class="sum-block">
<div class="sb-label">Page Details</div>
<div id="pageDetails"></div>
</div>
</div>
<div style="padding:18px 22px;border-top:1px solid var(--bd)">
<div class="sb-label" style="margin-bottom:12px">Request Summary</div>
<div id="reqSummary" style="display:grid;grid-template-columns:repeat(4,1fr);gap:10px"></div>
</div>
</div>
<!-- PERFORMANCE -->
<div class="tp" id="tp-perf">
<div class="perf-metrics" id="perfMetrics"></div>
</div>
<!-- STRUCTURE -->
<div class="tp" id="tp-str">
<div id="strList"></div>
</div>
<!-- CRUX -->
<div class="tp" id="tp-crux">
<div class="crux-grid" id="cruxGrid"></div>
</div>
<!-- WATERFALL -->
<div class="tp" id="tp-wfall">
<div class="wf-hdr"><span>Resource</span><span>Size</span><span>Time</span><span>Timeline</span></div>
<div id="wfRows"></div>
</div>
<!-- RESOURCES -->
<div class="tp" id="tp-res">
<table class="rtbl">
<thead><tr><th>URL</th><th>Type</th><th style="text-align:right">Transfer</th><th style="min-width:80px">Share</th></tr></thead>
<tbody id="resTbody"></tbody>
</table>
</div>
<!-- HISTORY -->
<div class="tp" id="tp-hist">
<div class="hist-hdr hist-row"><span>URL</span><span>Score</span><span>Grade</span><span>LCP</span><span>Date</span></div>
<div id="histRows"></div>
<div style="padding:10px 18px;border-top:1px solid var(--bd)">
<button class="hist-clear" onclick="clearHistory()">Clear history</button>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- FEATURES (hidden after first audit) -->
<div id="featSec" class="feat-sec">
<div class="feat-in">
<div class="feat-hd">
<h2>Full GTmetrix feature<br>parity — for free.</h2>
<p>7 report tabs, 17+ metrics, CrUX field data, waterfall, structure audits. No paywall, ever.</p>
</div>
<div class="fgrid">
<div class="fc"><div class="fcn">01</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><path d="M13 2L3 14h9l-1 8 10-12h-9l1-8z"/></svg></div><h3>Performance Score</h3><p>Lighthouse-powered 0–100 score with A–F letter grade. Weighted across 6 Core Web Vitals metrics.</p></div>
<div class="fc"><div class="fcn">02</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><circle cx="12" cy="12" r="10"/><path d="M12 2a10 10 0 0 1 0 20"/><path d="M2 12h20"/></svg></div><h3>CrUX Real User Data</h3><p>Field data from real Chrome users visiting your site — LCP, CLS, FCP, INP distribution with pass/fail status.</p></div>
<div class="fc"><div class="fcn">03</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M9 21V9"/></svg></div><h3>Waterfall Chart</h3><p>Every request in chronological order with type-colored bars, timing, and transfer size.</p></div>
<div class="fc"><div class="fcn">04</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><path d="M9 11l3 3 8-8"/><path d="M20 12v6a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h9"/></svg></div><h3>Structure Audits</h3><p>Prioritized punch list of structural issues — caching, images, render-blocking, DOM size, and more.</p></div>
<div class="fc"><div class="fcn">05</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><polyline points="22 12 18 12 15 21 9 3 6 12 2 12"/></svg></div><h3>Speed Visualization</h3><p>Timeline ruler showing when FCP, LCP, TTI, and Fully Loaded fire during the page load sequence.</p></div>
<div class="fc"><div class="fcn">06</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><path d="M3 3v18h18"/><path d="m7 16 4-4 4 4 4-4"/></svg></div><h3>History & Trends</h3><p>Every audit saved locally. Track performance over time, see grade changes, and spot regressions.</p></div>
<div class="fc"><div class="fcn">07</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><rect x="5" y="2" width="14" height="20" rx="2"/><path d="M12 18h.01"/></svg></div><h3>Mobile + Desktop</h3><p>Throttled Moto G4 mobile or fast desktop. Different scores, different bottlenecks.</p></div>
<div class="fc"><div class="fcn">08</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><circle cx="12" cy="12" r="10"/><path d="M12 8v4l3 3"/></svg></div><h3>17+ Metrics</h3><p>TTFB, FCP, LCP, SI, TBT, TTI, CLS, Fully Loaded Time, page size, request count, and more.</p></div>
<div class="fc"><div class="fcn">09</div><div class="fci"><svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="1.5"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/><polyline points="14 2 14 8 20 8"/></svg></div><h3>Page Details</h3><p>Breakdown of total page weight by resource type — HTML, CSS, JS, images, fonts — with percentage bars.</p></div>
</div>
</div>
</div>
</div><!-- /home -->
<!-- ════════════ PROCESSING OVERLAY ════════════ -->
<div id="ov">
<div class="ov-w">
<div class="ov-url" id="ovUrl">—</div>
<div class="ov-h">Analyzing performance</div>
<div class="ov-s" id="ovSub">Connecting to Google PageSpeed Insights…</div>
<div class="ov-track"><div class="ov-fill" id="ovFill"></div></div>
<div class="ov-steps" id="ovSteps"></div>
</div>
</div>
<!-- ════════════ DOCS ════════════ -->
<div class="page" id="pg-docs">
<div class="ip">
<div class="ip-lbl">Documentation</div>
<div class="ip-title">How Velox works</div>
<div class="ip-sub">Understand every tab, metric, and score in your performance report — and how to act on them.</div>
<div class="ip-body">
<h2>Overview</h2>
<p>Velox uses the <strong>Google PageSpeed Insights API v5</strong>, which runs Google Lighthouse in a controlled datacenter environment. Results are lab data — consistent and reproducible, but not identical to real user experience. The CrUX tab shows real user data separately.</p>
<div class="note-box"><p>💡 Run tests 2–3 times and average the scores. Server load and CDN caching state can cause variance of ±5–10 points between runs.</p></div>
<h2>The 7 Report Tabs</h2>
<h3>Summary</h3>
<p>High-level overview: speed visualization timeline, top issues ranked by impact, page size breakdown by resource type, and request count summary. Start here to get oriented.</p>
<h3>Performance</h3>
<p>All 17+ performance metrics in full detail — from TTFB to Fully Loaded Time, with thresholds and bar charts. This is your stopwatch.</p>
<h3>Structure</h3>
<p>Prioritized audit list of structural issues — the "instruction manual" for improving performance. Each audit shows impact (High/Medium/Low/Pass) and a description of what to fix.</p>
<h3>CrUX</h3>
<p>Chrome User Experience Report data — anonymized measurements from real Chrome users visiting your site. Shows distribution of Good / Needs Improvement / Poor for LCP, CLS, FCP, and INP. Only available for URLs with enough traffic in Google's dataset.</p>
<h3>Waterfall</h3>
<p>Every network request in chronological order with type-colored bars. Bar position = when the request started. Bar width = how long it took. Use this to spot render-blocking resources, slow third parties, and sequential request chains.</p>
<h3>Resources</h3>
<p>All network requests grouped with transfer size, resource type, and proportional size bars. Identify which resources contribute most to page weight.</p>
<h3>History</h3>
<p>Every audit you run is saved in your browser (localStorage). Track performance over time, see when grades change, and spot regressions after deploys.</p>
<div class="ip-divider"></div>
<h2>Scoring</h2>
<h3>Performance Score (0–100)</h3>
<p>Weighted aggregate of 6 Lighthouse metrics:</p>
<ul>
<li><strong>Total Blocking Time</strong> — 30%</li>
<li><strong>Largest Contentful Paint</strong> — 25%</li>
<li><strong>Cumulative Layout Shift</strong> — 15%</li>
<li><strong>First Contentful Paint</strong> — 10%</li>
<li><strong>Speed Index</strong> — 10%</li>
<li><strong>Time to Interactive</strong> — 10%</li>
</ul>
<h3>Structure Score (0–100)</h3>
<p>Average of all structural audit scores. Measures how well the page is built, independent of network conditions. Improving structure generally improves performance too.</p>
<h3>GTmetrix Grade (A–F)</h3>
<p>A = 90–100, B = 75–89, C = 60–74, D = 45–59, E = 30–44, F = 0–29.</p>
<div class="ip-divider"></div>
<h2>Core Web Vitals thresholds</h2>
<table>
<thead><tr><th>Metric</th><th>Good</th><th>Needs Improvement</th><th>Poor</th></tr></thead>
<tbody>
<tr><td>LCP</td><td style="color:var(--good)">≤ 2.5s</td><td style="color:var(--warn)">2.5–4s</td><td style="color:var(--bad)">> 4s</td></tr>
<tr><td>CLS</td><td style="color:var(--good)">≤ 0.1</td><td style="color:var(--warn)">0.1–0.25</td><td style="color:var(--bad)">> 0.25</td></tr>
<tr><td>FCP</td><td style="color:var(--good)">≤ 1.8s</td><td style="color:var(--warn)">1.8–3s</td><td style="color:var(--bad)">> 3s</td></tr>
<tr><td>TBT</td><td style="color:var(--good)">≤ 200ms</td><td style="color:var(--warn)">200–600ms</td><td style="color:var(--bad)">> 600ms</td></tr>
<tr><td>TTI</td><td style="color:var(--good)">≤ 3.8s</td><td style="color:var(--warn)">3.8–7.3s</td><td style="color:var(--bad)">> 7.3s</td></tr>
<tr><td>SI</td><td style="color:var(--good)">≤ 3.4s</td><td style="color:var(--warn)">3.4–5.8s</td><td style="color:var(--bad)">> 5.8s</td></tr>
</tbody>
</table>
<div class="ip-divider"></div>
<h2>Mobile vs Desktop</h2>
<p><strong>Mobile:</strong> Simulates a Moto G4 with 4x CPU throttling and Slow 4G network (150ms RTT, 1.6 Mbps down). Scores will be significantly lower than desktop. This is what most of your real users experience.</p>
<p><strong>Desktop:</strong> No CPU throttling, fast cable connection. Use to diagnose JS execution and rendering issues without network noise.</p>
</div>
</div>
</div>
<!-- ════════════ API ════════════ -->
<div class="page" id="pg-api">
<div class="ip">
<div class="ip-lbl">API Reference</div>
<div class="ip-title">Integrate into<br>your pipeline</div>
<div class="ip-sub">Velox is built on Google PageSpeed Insights API v5. Call it directly from CI/CD, scripts, or your own apps.</div>
<div class="ip-body">
<h2>Endpoint</h2>
<pre><code>GET https://www.googleapis.com/pagespeedonline/v5/runPagespeed</code></pre>
<h2>Parameters</h2>
<table>
<thead><tr><th>Parameter</th><th>Required</th><th>Values</th></tr></thead>
<tbody>
<tr><td><code>url</code></td><td style="color:var(--bad)">Yes</td><td style="color:var(--t2);font-size:.78rem">Full URL including https://</td></tr>
<tr><td><code>strategy</code></td><td style="color:var(--t3)">No</td><td style="color:var(--t2);font-size:.78rem"><code>mobile</code> (default) · <code>desktop</code></td></tr>
<tr><td><code>category</code></td><td style="color:var(--t3)">No</td><td style="color:var(--t2);font-size:.78rem"><code>performance</code> · <code>accessibility</code> · <code>seo</code> · <code>best-practices</code></td></tr>
<tr><td><code>key</code></td><td style="color:var(--t3)">Recommended</td><td style="color:var(--t2);font-size:.78rem">Your Google API key</td></tr>
</tbody>
</table>
<h2>JavaScript example</h2>
<pre><code>const url = 'https://example.com';
const key = 'YOUR_API_KEY';
const strategy = 'mobile'; // or 'desktop'
const res = await fetch(
`https://www.googleapis.com/pagespeedonline/v5/runPagespeed` +
`?url=${encodeURIComponent(url)}&strategy=${strategy}` +
`&category=performance&key=${key}`
);
const data = await res.json();
const lhr = data.lighthouseResult;
const score = Math.round(lhr.categories.performance.score * 100);
const lcp = lhr.audits['largest-contentful-paint'].numericValue;
const cls = lhr.audits['cumulative-layout-shift'].numericValue;
const tbt = lhr.audits['total-blocking-time'].numericValue;
console.log(`Score: ${score}/100`);
console.log(`LCP: ${(lcp/1000).toFixed(2)}s`);
console.log(`CLS: ${cls.toFixed(3)}`);
console.log(`TBT: ${Math.round(tbt)}ms`);</code></pre>
<h2>CI/CD — fail build on regression</h2>
<pre><code>#!/bin/bash
# velox-check.sh — add to your GitHub Actions or deploy hook
SCORE=$(curl -s \
"https://www.googleapis.com/pagespeedonline/v5/runPagespeed\
?url=https://yoursite.com&strategy=mobile\
&category=performance&key=$PSI_KEY" \
| python3 -c "
import sys, json
d = json.load(sys.stdin)
print(int(d['lighthouseResult']['categories']['performance']['score']*100))
")
echo "Performance score: $SCORE"
[ "$SCORE" -lt 75 ] && echo "❌ Score below 75. Blocking." && exit 1
echo "✅ Score OK."</code></pre>
<h2>Getting a free API key</h2>
<ol>
<li>Visit <strong>console.cloud.google.com</strong> and create a project</li>
<li>Enable the <strong>PageSpeed Insights API</strong></li>
<li>Credentials → Create Credentials → <strong>API Key</strong></li>
<li>Restrict the key to PageSpeed Insights API for security</li>
</ol>
<div class="note-box"><p>💡 Free tier: <strong>25,000 requests/day</strong> on your own quota. No billing needed at that limit.</p></div>
<div class="warn-box"><p>⚠️ Never commit API keys to public repos. Use environment variables in CI/CD.</p></div>
</div>
</div>
</div>
<!-- ════════════ PRIVACY ════════════ -->
<div class="page" id="pg-privacy">
<div class="ip">
<div class="ip-lbl">Legal</div>
<div class="ip-title">Privacy Policy</div>
<div class="ip-sub">Last updated May 2025. We collect as little as possible.</div>
<div class="ip-body">
<h2>What we collect</h2>
<p>Velox does not create accounts, store passwords, or track individuals. The only data involved:</p>
<ul>
<li><strong>The URL you enter</strong> — sent to Google's PageSpeed Insights API. We do not log or store it server-side.</li>
<li><strong>Your audit history</strong> — stored entirely in your own browser's <code>localStorage</code>. Never sent to any server. You can clear it anytime.</li>
<li><strong>Browser telemetry</strong> — IP address and user-agent sent by your browser to our CDN. Not linked to any identity, not retained beyond 24 hours.</li>
</ul>
<h2>Google PageSpeed Insights</h2>
<p>Audit requests are processed by Google. <a href="https://policies.google.com/privacy" style="color:var(--acc);text-decoration:underline" target="_blank">Google's Privacy Policy</a> applies to those requests. We receive the API response in your browser only — it's never forwarded to our servers.</p>
<h2>Cookies</h2>
<p>No tracking cookies. No advertising cookies. No analytics. The only browser storage is <code>localStorage</code> for your audit history — client-side only, never transmitted.</p>
<h2>Third parties</h2>
<p>Google Fonts (<code>fonts.googleapis.com</code>) for typography. No ad networks, no tracking pixels, no social widgets.</p>
<h2>Contact</h2>
<p>Questions: <code>privacy@velox.dev</code></p>
</div>
</div>
</div>
<!-- ════════════ TERMS ════════════ -->
<div class="page" id="pg-terms">
<div class="ip">
<div class="ip-lbl">Legal</div>
<div class="ip-title">Terms of Service</div>
<div class="ip-sub">Last updated May 2025. By using Velox you agree to these terms.</div>
<div class="ip-body">
<h2>1. Service</h2>
<p>Velox is a free web performance analysis tool. It sends URLs you provide to Google's PageSpeed Insights API and presents results. Provided "as is" with no warranty of uptime or accuracy.</p>
<h2>2. Acceptable use</h2>
<p>You may analyze URLs you own or have permission to test. You may not use Velox to:</p>
<ul>
<li>Perform denial-of-service attacks or load test servers</li>
<li>Scan for security vulnerabilities</li>
<li>Automate bulk requests that violate Google's API Terms of Service</li>
<li>Resell or mirror output without attribution</li>
</ul>
<h2>3. API keys</h2>
<p>If you supply a Google API key, you are responsible for its security and any usage costs beyond Google's free tier.</p>
<h2>4. Limitation of liability</h2>
<p>Velox is not liable for decisions made based on its reports. Scores are lab-based and may differ from real user experience. Always validate with real user monitoring before major infrastructure decisions.</p>
<h2>5. Changes</h2>
<p>We may update these terms. Continued use constitutes acceptance. Contact: <code>legal@velox.dev</code></p>
</div>
</div>
</div>
<!-- ════════════ STATUS ════════════ -->
<div class="page" id="pg-status">
<div class="ip">
<div class="ip-lbl">System Status</div>
<div class="ip-title">All systems operational</div>
<div class="ip-sub">Current status of Velox and the Google PageSpeed Insights API.</div>
<div class="ip-body">
<div class="st-grid">
<div class="st-item"><div class="st-dot op"></div><div><div class="st-n">Velox App</div><div class="st-d">Operational</div></div></div>
<div class="st-item"><div class="st-dot op"></div><div><div class="st-n">PageSpeed Insights API</div><div class="st-d">Operational</div></div></div>
<div class="st-item"><div class="st-dot op"></div><div><div class="st-n">Google Fonts CDN</div><div class="st-d">Operational</div></div></div>
<div class="st-item"><div class="st-dot op"></div><div><div class="st-n">CrUX Dataset</div><div class="st-d">Operational</div></div></div>
</div>
<h2>Uptime — last 30 days</h2>
<div class="ub-wrap" id="ubWrap"></div>
<div style="display:flex;justify-content:space-between;font-size:.68rem;color:var(--t4);font-family:var(--fm)"><span>30 days ago</span><span>Today</span></div>
<h2>Known limitations</h2>
<ul>
<li>The <strong>keyless API endpoint</strong> shares quota globally — use your own key to avoid quota errors.</li>
<li>Sites behind Cloudflare Bot Fight Mode, login walls, or private networks cannot be audited.</li>
<li>Very large SPAs may time out on Lighthouse. Try auditing a specific deep-link page.</li>
<li>CrUX data is only available for URLs with sufficient Chrome traffic in Google's dataset.</li>
<li>Video playback of page load requires a server-side browser runner — not available in this client-only tool.</li>
</ul>
<h2>Incidents</h2>
<p style="color:var(--good)">✓ No incidents in the last 30 days.</p>
</div>
</div>
</div>
<!-- ════════════ FOOTER ════════════ -->
<footer>
<div class="fbrand">
<div class="lm" style="width:22px;height:22px;border-radius:5px"><svg width="10" height="10" viewBox="0 0 12 12" fill="none"><polygon points="6,0 12,6 6,12 0,6" fill="#09090b"/></svg></div>
Velox
</div>
<div class="flinks">
<a href="https://yukistackai.vercel.app/" target="_blank" class="fl">Company</a>
<a href="https://github.com/YukiStackAI" target="_blank" class="fl">GitHub</a>
<a href="https://www.linkedin.com/company/yuki-stack-ai/" target="_blank" class="fl">LinkedIn</a>
<button class="fl" onclick="showPage('privacy')">Privacy</button>
<button class="fl" onclick="showPage('terms')">Terms</button>
</div>
<div class="fcopy">© 2026 Yuki Stack AI · Powered by Google PSI</div>
</footer>
<div class="ad-side">
<!-- 160x600 Banner Ad -->
<script>
atOptions = {
'key' : 'e359c7504c30cdd5e96f3bad34a1771f',
'format' : 'iframe',
'height' : 600,
'width' : 160,
'params' : {}
};
</script>
<script src="https://intermediatenormalconfederate.com/e359c7504c30cdd5e96f3bad34a1771f/invoke.js"></script>
</div>
<script>
'use strict';
const API_KEY = 'AIzaSyBVPlDNSYswYW7RuWpqWgdywEVnRsBCSao';
const CIRC = 2 * Math.PI * 46;
let strategy = 'mobile';
/* ── ROUTING ── */
function showPage(id) {
document.querySelectorAll('.page').forEach(p => p.classList.remove('active'));
document.getElementById('pg-' + id).classList.add('active');
window.scrollTo(0,0);
}
function goHome() {
showPage('home');
setTimeout(() => document.getElementById('urlInput').focus(), 80);
}
/* ── STRATEGY ── */
function setSt(s) {
strategy = s;
document.getElementById('sMob').classList.toggle('on', s==='mobile');
document.getElementById('sDsk').classList.toggle('on', s==='desktop');
}
document.getElementById('urlInput').addEventListener('keydown', e => { if(e.key==='Enter') runAudit(); });
/* ── TABS ── */
function swTab(id) {
const ids = ['sum','perf','str','crux','wfall','res','hist'];
document.querySelectorAll('.tb').forEach((b,i) => b.classList.toggle('on', ids[i]===id));
document.querySelectorAll('.tp').forEach(p => p.classList.remove('on'));
document.getElementById('tp-'+id).classList.add('on');
if(id==='hist') renderHistory();
}
/* ── OVERLAY ── */
const OV_STEPS = [
{n:'Resolving URL', d:'Validating and normalizing the address', p:'5%'},
{n:'Connecting to Google', d:'Opening connection to PageSpeed Insights API', p:'14%'},
{n:'Running Lighthouse', d:'Simulating page load in a Google datacenter', p:'32%'},
{n:'Measuring Core Web Vitals', d:'LCP, CLS, FCP, TBT, TTI, Speed Index', p:'52%'},
{n:'Fetching CrUX data', d:'Loading real user field data from Chrome UX Report', p:'65%'},
{n:'Auditing structure', d:'Scanning opportunities, diagnostics, resource map', p:'80%'},
{n:'Compiling report', d:'Building your 7-tab performance dashboard', p:'95%'},
];
let ovTs=[], ovInt=null;
function showOverlay(url) {
document.getElementById('ovUrl').textContent = url.replace(/^https?:\/\//,'');
document.getElementById('ovFill').style.width = '0%';
document.getElementById('ovSub').textContent = 'Connecting to Google PageSpeed Insights…';
const el = document.getElementById('ovSteps');
el.innerHTML = OV_STEPS.map((s,i) => `
<div class="ovs" id="ovs${i}">
<div class="ovs-ic" id="ovsi${i}">${sico('idle')}</div>
<div><div class="ovs-n">${s.n}</div><div class="ovs-d">${s.d}</div></div>
<div class="ovs-p">${s.p}</div>
</div>`).join('');
document.getElementById('ov').classList.add('on');
OV_STEPS.forEach((s,i) => {
ovTs.push(setTimeout(()=>{
if(i>0) markDone(i-1);
markActive(i);
document.getElementById('ovFill').style.width = s.p;
document.getElementById('ovSub').textContent = s.d;
}, i*1100));
});
}
function hideOverlay(ok) {
ovTs.forEach(clearTimeout); ovTs=[];
if(ok){ document.getElementById('ovFill').style.width='100%'; OV_STEPS.forEach((_,i)=>markDone(i)); document.getElementById('ovSub').textContent='Done ✓'; }
setTimeout(()=>document.getElementById('ov').classList.remove('on'), 500);
}
function markActive(i){ const e=document.getElementById('ovs'+i); if(!e)return; e.classList.add('on'); document.getElementById('ovsi'+i).innerHTML=sico('spin'); }
function markDone(i){ const e=document.getElementById('ovs'+i); if(!e)return; e.classList.remove('on'); e.classList.add('done'); document.getElementById('ovsi'+i).innerHTML=sico('done'); }
function sico(t){
if(t==='done') return `<svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="var(--good)" stroke-width="2.5"><path d="m9 12 2 2 4-4"/><circle cx="12" cy="12" r="10"/></svg>`;
if(t==='spin') return `<svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="var(--acc)" stroke-width="2" class="spin"><path d="M12 2v4M12 18v4M4.93 4.93l2.83 2.83M16.24 16.24l2.83 2.83M2 12h4M18 12h4M4.93 19.07l2.83-2.83M16.24 7.76l2.83-2.83"/></svg>`;
return `<svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="var(--t4)" stroke-width="1.5"><circle cx="12" cy="12" r="10"/></svg>`;
}
/* ── HELPERS ── */
function nu(r){ r=r.trim(); if(!r)return null; if(!/^https?:\/\//i.test(r))r='https://'+r; try{return new URL(r).href;}catch{return null;} }
function sc(s){ return s>=90?'var(--good)':s>=50?'var(--warn)':'var(--bad)'; }
function gl(s){ return s>=90?'A':s>=75?'B':s>=60?'C':s>=45?'D':s>=30?'E':'F'; }
function fb(b){ if(!b||b===0)return'—'; if(b<1024)return b+' B'; if(b<1048576)return(b/1024).toFixed(1)+' KB'; return(b/1048576).toFixed(2)+' MB'; }
function ft(ms){ if(ms<1000)return Math.round(ms)+'ms'; return(ms/1000).toFixed(2)+'s'; }
function mdstrip(s){ return (s||'').replace(/\[([^\]]+)\]\([^)]+\)/g,'$1').replace(/`([^`]+)`/g,'$1').replace(/\*\*([^*]+)\*\*/g,'$1').slice(0,160); }
/* ── AUDIT ── */
async function runAudit() {
const url = nu(document.getElementById('urlInput').value);
if(!url){ alert('Enter a valid URL.'); return; }
document.getElementById('urlInput').value = url;
document.getElementById('resBox').style.display = 'none';
document.getElementById('errBox').style.display = 'none';
document.getElementById('featSec').style.display = '';
showPage('home');
showOverlay(url);
const apiUrl = `https://www.googleapis.com/pagespeedonline/v5/runPagespeed?key=${API_KEY}&url=${encodeURIComponent(url)}&strategy=${strategy}&category=performance`;
try {
const res = await fetch(apiUrl);
if(!res.ok){ const e=await res.json().catch(()=>{}); throw new Error((e?.error?.message)||'HTTP '+res.status); }
const data = await res.json();
hideOverlay(true);
setTimeout(()=>{ render(data,url); }, 650);
} catch(e) {
hideOverlay(false);
document.getElementById('errBox').style.display='block';
document.getElementById('errMsg').textContent=`Could not audit ${url}. ${e.message}. The site may block crawlers, or try again shortly.`;
}
}
/* ── RENDER ── */
function render(data, url) {
const au = data.lighthouseResult.audits;
const lhr = data.lighthouseResult;
const perf = Math.round((lhr.categories.performance.score||0)*100);
const lhv = lhr.lighthouseVersion||'';
// Grade ring
const col = sc(perf), grade = gl(perf);
const arc = document.getElementById('garc');
setTimeout(()=>{ arc.style.strokeDashoffset=CIRC-(perf/100)*CIRC; arc.style.stroke=col; },120);
document.getElementById('gnum').textContent=perf; document.getElementById('gnum').style.color=col;
document.getElementById('gletter').textContent='Grade '+grade; document.getElementById('gletter').style.color=col;
document.getElementById('gurl').textContent=url.replace(/^https?:\/\//,'').replace(/\/$/,'');
document.getElementById('gstrat').textContent=strategy.toUpperCase()+' · LH '+lhv;