Repository navigation
Expand file tree
/
Copy pathindex.html
More file actions
832 lines (782 loc) · 46.9 KB
/
Copy pathindex.html
File metadata and controls
832 lines (782 loc) · 46.9 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
<title>Hack The Code</title>
<meta name="description" content="Dragomir Tsanev (hackthecode) — tech enthusiast. In my free time I turn ideas into code. Public projects, live links and source.">
<meta name="theme-color" content="#050506">
<meta property="og:title" content="Hack The Code">
<meta property="og:description" content="Tech enthusiast. In my free time I turn ideas into code. Public projects, live links and source.">
<meta property="og:image" content="https://hackthecode.github.io/assets/og.png">
<meta property="og:image:width" content="1200">
<meta property="og:image:height" content="630">
<meta name="twitter:card" content="summary_large_image">
<meta property="og:url" content="https://hackthecode.github.io/">
<meta property="og:type" content="website">
<link rel="icon" type="image/png" href="assets/favicon.png">
<link rel="apple-touch-icon" href="assets/icon-180.png">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;700&family=Tektur:wght@500;700;900&display=swap">
<style>
/* Layout: a tactical HUD dossier — status bar, subject file (terminal + portrait in a reticle), then target cards. */
:root {
color-scheme: dark;
--void: #050506; /* page ground */
--panel: #0d0a0b; /* card and terminal surfaces */
--line: #33151a; /* resting borders, grid */
--red: #ff1f33; /* the signal colour */
--blood: #9c0f1d; /* deep red for fills and glows */
--bone: #ece5dd; /* text, taken from the skull */
--dim: #94848a; /* secondary text */
--fringe: #2be0da; /* chromatic fringe from the portrait; glitch only */
--display: "Tektur", "Arial Narrow", "Segoe UI", sans-serif;
--mono: "JetBrains Mono", Consolas, "Courier New", monospace;
--cut: 14px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
margin: 0;
background: var(--void);
color: var(--bone);
font: 400 15px/1.6 var(--mono);
min-height: 100vh;
overflow-x: hidden;
}
a { color: inherit; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
::selection { background: var(--red); color: var(--void); }
/* ---------- atmosphere ---------- */
#rain { position: fixed; inset: 0; width: 100%; height: 100%; opacity: .32; z-index: 0; pointer-events: none; }
.fx { position: fixed; inset: 0; pointer-events: none; }
.fx-grid {
z-index: 0;
background:
linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 100% 56px,
linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 56px 100%;
opacity: .28;
mask-image: radial-gradient(ellipse at 50% 20%, #000 0%, transparent 75%);
-webkit-mask-image: radial-gradient(ellipse at 50% 20%, #000 0%, transparent 75%);
}
.fx-scan {
z-index: 5;
background: repeating-linear-gradient(to bottom, transparent 0 2px, rgba(0,0,0,.28) 2px 3px);
mix-blend-mode: multiply;
}
.fx-vig { z-index: 5; background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,.75) 100%); }
.wrap {
position: relative; z-index: 1;
max-width: 1120px; margin: 0 auto;
padding-left: max(16px, env(safe-area-inset-left, 0px));
padding-right: max(16px, env(safe-area-inset-right, 0px));
}
/* ---------- status bar ---------- */
.bar {
position: sticky; top: 0; z-index: 4;
background: rgba(5,5,6,.86);
backdrop-filter: blur(6px);
border-bottom: 1px solid var(--line);
}
.bar .wrap {
display: flex; flex-wrap: wrap; align-items: center; gap: 6px 22px;
padding-block: 10px;
font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--dim);
}
.bar .tag { color: var(--red); font-weight: 700; }
.bar .grow { flex: 1; }
.bar b { color: var(--bone); font-weight: 500; font-variant-numeric: tabular-nums; }
.dot { display: inline-block; width: 7px; height: 7px; background: var(--red); margin-right: 7px; box-shadow: 0 0 8px var(--red); animation: pulse 1.6s steps(2) infinite; }
@keyframes pulse { 50% { opacity: .25; } }
.lang { display: inline-flex; border: 1px solid var(--line); }
.lang button {
font: inherit; letter-spacing: inherit; color: var(--dim);
background: none; border: 0; padding: 3px 9px; cursor: pointer;
}
.lang button[aria-pressed="true"] { background: var(--red); color: var(--void); font-weight: 700; }
/* ---------- hero ---------- */
.hero {
display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr);
gap: 48px; align-items: center;
padding-block: 64px 56px;
}
.eyebrow { font-size: 12px; letter-spacing: .28em; text-transform: uppercase; color: var(--red); margin: 0 0 14px; }
.eyebrow::before { content: "// "; color: var(--dim); }
h1 {
font: 900 clamp(2.9rem, 9.4vw, 6.6rem)/.92 var(--display);
letter-spacing: -.01em; text-transform: uppercase;
margin: 0; text-wrap: balance;
}
h1 em { font-style: normal; color: var(--red); text-shadow: 0 0 28px rgba(255,31,51,.55); }
.glitch { position: relative; display: inline-block; }
.glitch::before, .glitch::after {
content: attr(data-text); position: absolute; inset: 0; pointer-events: none; opacity: 0;
}
.glitch::before { color: var(--red); animation: gl-a 5.2s steps(1) infinite; }
.glitch::after { color: var(--fringe); animation: gl-b 5.2s steps(1) infinite; }
@keyframes gl-a {
0%, 91%, 100% { opacity: 0; }
92% { opacity: .9; transform: translate(-5px, 2px); clip-path: inset(12% 0 58% 0); }
94% { opacity: .9; transform: translate(4px, -1px); clip-path: inset(62% 0 8% 0); }
96% { opacity: .9; transform: translate(-3px, 0); clip-path: inset(36% 0 40% 0); }
98% { opacity: 0; }
}
@keyframes gl-b {
0%, 91%, 100% { opacity: 0; }
92% { opacity: .8; transform: translate(5px, -2px); clip-path: inset(48% 0 22% 0); }
94% { opacity: .8; transform: translate(-4px, 1px); clip-path: inset(6% 0 76% 0); }
96% { opacity: .8; transform: translate(3px, 0); clip-path: inset(70% 0 12% 0); }
98% { opacity: 0; }
}
.lede { max-width: 54ch; margin: 22px 0 0; color: var(--bone); font-size: 16px; }
.lede strong { color: var(--red); font-weight: 700; }
.term {
margin-top: 30px; max-width: 560px;
background: var(--panel); border: 1px solid var(--line);
clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
}
.term-head {
display: flex; justify-content: space-between; gap: 12px;
padding: 7px 14px; border-bottom: 1px solid var(--line);
font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--dim);
}
.term pre {
margin: 0; padding: 14px 16px 18px; min-height: 13.2em;
font: inherit; font-size: 13.5px; line-height: 1.65;
white-space: pre-wrap; overflow-wrap: anywhere; color: var(--bone);
}
.term .p { color: var(--red); }
.term .o { color: var(--dim); }
.term .k { color: var(--red); }
.term a { color: var(--bone); text-decoration-color: var(--red); text-underline-offset: 3px; }
.term a:hover { color: var(--red); }
.term.wide { max-width: 760px; margin-top: 0; }
.caret { display: inline-block; width: .6em; height: 1.05em; background: var(--red); vertical-align: -.18em; animation: pulse 1s steps(2) infinite; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn {
display: inline-flex; align-items: center; gap: 9px;
padding: 11px 18px;
font: 700 13px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; text-decoration: none;
color: var(--bone); background: transparent; border: 1px solid var(--line);
clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 9px, 100% 100%, 9px 100%, 0 calc(100% - 9px));
transition: background .15s, color .15s, border-color .15s;
}
.btn:hover { border-color: var(--red); color: var(--red); }
.btn:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--bone); }
.btn.hot { background: var(--red); border-color: var(--red); color: var(--void); }
.btn.hot:hover { background: var(--bone); border-color: var(--bone); color: var(--void); }
/* portrait in a reticle */
.id { margin: 0; justify-self: center; width: min(100%, 380px); }
.id-frame { position: relative; aspect-ratio: 1; max-width: 100%; }
.id-frame::before, .id-frame::after {
content: ""; position: absolute; inset: -12px; pointer-events: none; z-index: 2;
}
.id-frame::before {
background:
linear-gradient(var(--red), var(--red)) 0 0 / 34px 2px, linear-gradient(var(--red), var(--red)) 0 0 / 2px 34px,
linear-gradient(var(--red), var(--red)) 100% 0 / 34px 2px, linear-gradient(var(--red), var(--red)) 100% 0 / 2px 34px,
linear-gradient(var(--red), var(--red)) 0 100% / 34px 2px, linear-gradient(var(--red), var(--red)) 0 100% / 2px 34px,
linear-gradient(var(--red), var(--red)) 100% 100% / 34px 2px, linear-gradient(var(--red), var(--red)) 100% 100% / 2px 34px;
background-repeat: no-repeat;
filter: drop-shadow(0 0 6px var(--red));
}
.id-frame::after {
inset: 0;
background: linear-gradient(to bottom, transparent, rgba(255,31,51,.28) 50%, transparent) 0 0 / 100% 22% no-repeat;
animation: sweep 4.5s linear infinite;
}
@keyframes sweep { from { background-position: 0 -30%; } to { background-position: 0 130%; } }
.id-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.id-frame .g { opacity: 0; mix-blend-mode: screen; }
.id-frame .g1 { animation: im-a 6.4s steps(1) infinite; }
.id-frame .g2 { animation: im-b 6.4s steps(1) infinite; filter: hue-rotate(160deg); }
.id:hover .g1 { animation-duration: 1.1s; }
.id:hover .g2 { animation-duration: 1.1s; }
@keyframes im-a {
0%, 86%, 100% { opacity: 0; }
87% { opacity: .9; transform: translate(-10px, 0); clip-path: inset(18% 0 66% 0); }
90% { opacity: .9; transform: translate(8px, 0); clip-path: inset(58% 0 28% 0); }
93% { opacity: .9; transform: translate(-6px, 0); clip-path: inset(80% 0 6% 0); }
95% { opacity: 0; }
}
@keyframes im-b {
0%, 86%, 100% { opacity: 0; }
88% { opacity: .7; transform: translate(9px, 0); clip-path: inset(40% 0 44% 0); }
91% { opacity: .7; transform: translate(-7px, 0); clip-path: inset(6% 0 82% 0); }
94% { opacity: 0; }
}
.id figcaption {
display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap;
margin-top: 24px; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--dim);
}
.id figcaption b { color: var(--red); font-weight: 700; }
/* ---------- sections ---------- */
section { padding-block: 34px; }
.sec-head { display: flex; align-items: baseline; gap: 16px; margin-bottom: 26px; }
.sec-head h2 {
font: 700 clamp(1.5rem, 4vw, 2.1rem)/1 var(--display); letter-spacing: .04em; text-transform: uppercase; margin: 0;
}
.sec-head h2::before { content: "▮ "; color: var(--red); }
.sec-head .rule { flex: 1; height: 1px; background: linear-gradient(90deg, var(--red), transparent); min-width: 20px; }
.sec-head .count { font-size: 12px; letter-spacing: .16em; color: var(--dim); text-transform: uppercase; white-space: nowrap; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card {
position: relative; display: flex; padding: 1px; min-width: 0;
background: var(--line);
clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
transition: background .2s, transform .2s;
}
.card:hover, .card:focus-within { background: var(--red); transform: translateY(-3px); }
.card-in {
position: relative; flex: 1; display: flex; flex-direction: column; gap: 14px; min-width: 0;
padding: 20px 20px 22px; background: var(--panel); overflow: hidden;
clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
}
.card-in::after {
content: ""; position: absolute; left: 0; right: 0; top: -40%; height: 40%; pointer-events: none;
background: linear-gradient(to bottom, transparent, rgba(255,31,51,.14));
opacity: 0;
}
.card:hover .card-in::after { opacity: 1; animation: cardscan .9s linear; }
@keyframes cardscan { from { top: -40%; } to { top: 100%; } }
.card-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--dim); }
.live { color: var(--red); font-weight: 700; white-space: nowrap; }
.card h3 { font: 700 1.5rem/1.05 var(--display); letter-spacing: .02em; text-transform: uppercase; margin: 0; overflow-wrap: anywhere; }
.card:hover h3 { color: var(--red); text-shadow: 2px 0 0 rgba(43,224,218,.35); }
.card p { margin: 0; color: var(--dim); font-size: 13.5px; flex: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; }
.chips li { font-size: 11px; letter-spacing: .08em; padding: 2px 8px; border: 1px solid var(--line); color: var(--bone); }
.card .cta { margin-top: 2px; }
.card .btn { padding: 9px 13px; font-size: 12px; }
.arch { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.arch a {
display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px 22px; align-items: baseline;
padding: 14px 6px; border-bottom: 1px solid var(--line); text-decoration: none;
transition: background .15s, padding-left .15s;
}
.arch a:hover { background: rgba(255,31,51,.07); padding-left: 14px; }
.arch .n { font-weight: 700; overflow-wrap: anywhere; min-width: 0; }
.arch a:hover .n { color: var(--red); }
.arch .n small { display: block; font-weight: 400; font-size: 12.5px; color: var(--dim); }
.arch .l, .arch .y { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--dim); font-variant-numeric: tabular-nums; }
footer { margin-top: 30px; border-top: 1px solid var(--line); }
footer .wrap {
display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
padding-block: 22px calc(28px + env(safe-area-inset-bottom, 0px));
font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--dim);
}
footer a { color: var(--bone); text-decoration: none; border-bottom: 1px solid var(--red); }
footer a:hover { color: var(--red); }
@media (max-width: 900px) {
.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.hero { grid-template-columns: minmax(0, 1fr); gap: 44px; padding-block: 40px 36px; }
.id { order: -1; width: min(72%, 300px); }
}
@media (max-width: 600px) {
.grid { grid-template-columns: minmax(0, 1fr); }
.bar .hide-s { display: none; }
.arch a { grid-template-columns: minmax(0, 1fr) auto; }
.arch .y { display: none; }
}
/* ---------- effects switch ---------- */
.fx-btn {
font: inherit; letter-spacing: inherit; text-transform: uppercase; color: var(--dim);
background: none; border: 1px solid var(--line); padding: 3px 9px; cursor: pointer;
}
.fx-btn b { color: var(--red); font-weight: 700; }
.fx-btn[aria-pressed="false"] b { color: var(--dim); }
.fx-btn:hover { border-color: var(--red); }
.fx-off *, .fx-off *::before, .fx-off *::after { animation: none !important; transition: none !important; }
.fx-off #rain, .fx-off .fx-scan { display: none; }
/* ---------- boot screen ---------- */
#boot {
position: fixed; inset: 0; z-index: 50; background: var(--void);
display: grid; place-items: center; cursor: pointer;
padding: 24px max(16px, env(safe-area-inset-right, 0px)) 24px max(16px, env(safe-area-inset-left, 0px));
}
#boot pre { margin: 0; width: min(100%, 460px); font: 500 14px/1.7 var(--mono); color: var(--dim); white-space: pre-wrap; }
#boot pre div:first-child { color: var(--bone); }
#boot .ok { color: var(--red); font-weight: 700; letter-spacing: .2em; text-shadow: 0 0 18px var(--red); }
#boot.out { animation: boot-out .45s steps(6) forwards; pointer-events: none; }
@keyframes boot-out {
0% { opacity: 1; clip-path: inset(0); transform: none; }
30% { clip-path: inset(18% 0 30% 0); transform: translateX(-14px); }
55% { clip-path: inset(52% 0 12% 0); transform: translateX(12px); opacity: .8; }
80% { clip-path: inset(40% 0 44% 0); transform: translateX(-6px); opacity: .5; }
100% { clip-path: inset(50% 0 50% 0); opacity: 0; }
}
/* ---------- social ---------- */
.social { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 22px 0 0; padding: 0; }
.social a {
display: inline-flex; align-items: center; gap: 8px; padding: 5px 10px 5px 5px;
border: 1px solid var(--line); text-decoration: none;
font-size: 12px; letter-spacing: .08em; color: var(--dim);
transition: border-color .15s, color .15s;
}
.social a b { display: inline-grid; place-items: center; min-width: 26px; height: 22px; background: var(--line); color: var(--bone); font-size: 11px; letter-spacing: .04em; }
.social a:hover { border-color: var(--red); color: var(--bone); }
.social a:hover b { background: var(--red); color: var(--void); }
footer .social { margin: 0; }
footer .social a { padding: 0; border: 0; }
footer .social a span { display: none; }
/* ---------- project shots ---------- */
.shot { position: relative; display: block; margin: -20px -20px 2px; aspect-ratio: 16 / 9; overflow: hidden; border-bottom: 1px solid var(--line); background: var(--void); }
.shot img { width: 100%; height: 100%; object-fit: cover; display: block; filter: saturate(.75) contrast(1.05); transition: transform .5s, filter .3s; }
.shot::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(156,15,29,.28), transparent 45%, rgba(5,5,6,.55)); mix-blend-mode: multiply; transition: opacity .3s; }
.card:hover .shot img { transform: scale(1.05); filter: none; }
.card:hover .shot::after { opacity: .35; }
.gh { font-size: 11px; letter-spacing: .1em; color: var(--dim); font-variant-numeric: tabular-nums; }
/* ---------- skills ---------- */
.skills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 40px; }
.skill { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.skill-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.skill-top b { font: 700 1.05rem/1.1 var(--display); letter-spacing: .04em; text-transform: uppercase; }
.skill-top span { font-size: 11px; letter-spacing: .1em; color: var(--dim); text-align: right; }
.meter {
--seg: 10;
height: 14px; position: relative;
background: repeating-linear-gradient(90deg, var(--line) 0 calc(10% - 3px), transparent calc(10% - 3px) 10%);
}
.meter::after {
content: ""; position: absolute; inset: 0;
background: repeating-linear-gradient(90deg, var(--red) 0 calc(10% - 3px), transparent calc(10% - 3px) 10%);
clip-path: inset(0 calc(100% - var(--v) * 10%) 0 0);
filter: drop-shadow(0 0 5px rgba(255,31,51,.6));
}
.meter:not(.on)::after { clip-path: inset(0 100% 0 0); }
.meter.on::after { transition: clip-path 1.1s steps(10); }
.fx-off .meter::after { clip-path: inset(0 calc(100% - var(--v) * 10%) 0 0); }
@media (max-width: 700px) { .skills { grid-template-columns: minmax(0, 1fr); } }
</style>
</head>
<body>
<canvas id="rain" aria-hidden="true"></canvas>
<div class="fx fx-grid" aria-hidden="true"></div>
<header class="bar">
<div class="wrap">
<span class="tag">hackthecode</span>
<span><span class="dot"></span><span data-bg="на линия">online</span></span>
<span class="hide-s" data-bg="България">Bulgaria</span>
<span class="grow"></span>
<span class="hide-s"><span data-bg="София">Sofia</span> <b id="clock">--:--:--</b></span>
<button type="button" class="fx-btn" id="fx-toggle" aria-pressed="true" title="Effects">FX <b>ON</b></button>
<span class="lang" role="group" aria-label="Language">
<button type="button" id="lang-en" aria-pressed="true">EN</button>
<button type="button" id="lang-bg" aria-pressed="false">BG</button>
</span>
</div>
</header>
<main class="wrap">
<div class="hero">
<div>
<p class="eyebrow" data-bg="досие · публичен достъп">dossier · public access</p>
<h1><span class="glitch" data-text="Hack the">Hack the</span><br><em class="glitch" data-text="Code">Code</em></h1>
<p class="lede" data-bg="Технологичен ентусиаст. В свободното си време превръщам идеи в код.">Tech enthusiast. In my free time I turn ideas into code.</p>
<div class="term" aria-label="Terminal">
<div class="term-head"><span>evil@hackthecode:~</span><span>tty1</span></div>
<pre id="term"><span class="p">$</span> whoami
<span class="o">dragomir tsanev // hackthecode // alias: EVIL</span>
<span class="p">$</span> uptime
<span class="o">in computing since the Windows 95 days · base: bulgaria</span>
<span class="p">$</span> ls ./projects
<span class="o">evil-games/ imoti-i-imperii/ pu-foam-app/
evil-watchface/ nixie-watchface/ predator-watchface/
archive/ profile.txt</span>
<span class="p">$</span> <span class="caret"></span></pre>
</div>
<div class="cta">
<a class="btn hot" href="#targets" data-bg="▶ Към проектите">▶ View projects</a>
<a class="btn" href="#profile" data-bg="Кой съм аз">Who I am</a>
<a class="btn" href="https://github.com/hackthecode" target="_blank" rel="noopener">GitHub ↗</a>
</div>
<ul class="social">
<li><a href="https://github.com/hackthecode" target="_blank" rel="noopener" aria-label="GitHub"><b>GH</b><span>GitHub</span></a></li>
<li><a href="https://www.facebook.com/HackTheCode" target="_blank" rel="noopener" aria-label="Facebook"><b>FB</b><span>Facebook</span></a></li>
<li><a href="https://www.instagram.com/evil___society/" target="_blank" rel="noopener" aria-label="Instagram"><b>IG</b><span>Instagram</span></a></li>
<li><a href="https://www.tiktok.com/@hackthecode" target="_blank" rel="noopener" aria-label="TikTok"><b>TT</b><span>TikTok</span></a></li>
<li><a href="https://discord.com/users/139028293985894400" target="_blank" rel="noopener" aria-label="Discord"><b>DC</b><span>Discord</span></a></li>
</ul>
</div>
<figure class="id">
<div class="id-frame">
<img src="assets/evil.webp" width="460" height="460" alt="EVIL — a hooded skull in red, the hackthecode profile logo">
<img class="g g1" src="assets/evil.webp" width="460" height="460" alt="" aria-hidden="true">
<img class="g g2" src="assets/evil.webp" width="460" height="460" alt="" aria-hidden="true">
</div>
<figcaption><span><span data-bg="обект">subject</span>: <b>EVIL</b></span><span><span data-bg="статус">status</span>: <b data-bg="активен">active</b></span></figcaption>
</figure>
</div>
<section id="targets">
<div class="sec-head">
<h2 data-bg="Проекти">Projects</h2><span class="rule"></span>
<span class="count" data-bg="3 на живо · 3 циферблата">3 live · 3 watch faces</span>
</div>
<div class="grid">
<article class="card"><div class="card-in">
<a class="shot" href="https://hackthecode.github.io/evil-games/" tabindex="-1" aria-hidden="true"><img src="assets/shot-evil-games.webp" width="800" height="450" alt="Evil Games home page" loading="lazy"></a>
<div class="card-top"><span class="live"><span class="dot"></span><span data-bg="на живо">live</span></span><span data-bg="игрален портал">game portal</span></div>
<h3>Evil Games</h3>
<p data-bg="Портал с браузър игри: табла, шах, белот, сантасе, блато, не се сърди човече, пасианс и стратегията Evil Empires. Срещу компютъра или онлайн с приятели. На български и английски.">A browser game portal: backgammon, chess, belot, santase, blato, ludo, solitaire and the Evil Empires strategy game. Play the computer or friends online. English and Bulgarian.</p>
<ul class="chips"><li>JavaScript</li><li>PWA</li><li>Supabase</li></ul>
<span class="gh" data-repo="evil-games" hidden></span>
<div class="cta">
<a class="btn hot" href="https://hackthecode.github.io/evil-games/" data-bg="▶ Играй">▶ Play</a>
<a class="btn" href="https://github.com/hackthecode/evil-games" target="_blank" rel="noopener" data-bg="Код ↗">Source ↗</a>
</div>
</div></article>
<article class="card"><div class="card-in">
<a class="shot" href="https://hackthecode.github.io/evil-games/imoti/" tabindex="-1" aria-hidden="true"><img src="assets/shot-imoti.webp" width="800" height="450" alt="Imoti i Imperii board during a game" loading="lazy"></a>
<div class="card-top"><span class="live"><span class="dot"></span><span data-bg="на живо">live</span></span><span data-bg="настолна игра">board game</span></div>
<h3 data-bg="Имоти и Империи">Imoti i Imperii</h3>
<p data-bg="Настолна игра с имоти за 2 до 10 играчи — с ботове или онлайн в стая с код. Целият ход на играта се води от собствен сървър, така че никой не може да мами.">A property board game for 2 to 10 players, with bots or online in a room with a code. Its own server runs every move, so nobody can cheat.</p>
<ul class="chips"><li>Python</li><li>FastAPI</li><li>Socket.IO</li></ul>
<span class="gh" data-repo="evil-games" hidden></span>
<div class="cta">
<a class="btn hot" href="https://hackthecode.github.io/evil-games/imoti/" data-bg="▶ Играй">▶ Play</a>
<a class="btn" href="https://github.com/hackthecode/evil-games/tree/main/server/imoti" target="_blank" rel="noopener" data-bg="Код ↗">Source ↗</a>
</div>
</div></article>
<article class="card"><div class="card-in">
<a class="shot" href="https://hackthecode.github.io/pu-foam-app/" tabindex="-1" aria-hidden="true"><img src="assets/shot-pu-foam.webp" width="800" height="450" alt="PU Foam material calculator" loading="lazy"></a>
<div class="card-top"><span class="live"><span class="dot"></span><span data-bg="на живо">live</span></span><span data-bg="производство">production tool</span></div>
<h3 data-bg="ПУ Пяна">PU Foam</h3>
<p data-bg="Производствен асистент за пенополиуретан (дунапрен): калкулатор за материали и плътност, калибратор обороти ↔ грамове, рецепти с търсачка. Данните идват на живо от Google Sheets и работи и без интернет.">A production assistant for polyurethane foam: material and density calculator, RPM ↔ grams calibrator, searchable recipes. Data syncs live from Google Sheets and it keeps working offline.</p>
<ul class="chips"><li>JavaScript</li><li>PWA</li><li>Google Sheets</li></ul>
<span class="gh" data-repo="pu-foam-app" hidden></span>
<div class="cta">
<a class="btn hot" href="https://hackthecode.github.io/pu-foam-app/" data-bg="▶ Отвори">▶ Open</a>
<a class="btn" href="https://github.com/hackthecode/pu-foam-app" target="_blank" rel="noopener" data-bg="Код ↗">Source ↗</a>
</div>
</div></article>
<article class="card"><div class="card-in">
<a class="shot" href="https://github.com/hackthecode/evil-watchface" tabindex="-1" aria-hidden="true"><img src="assets/anim-evil-watchface.png" width="800" height="450" alt="EVIL watch face: stencil time with heart rate, steps, battery and weather fields" loading="lazy"></a>
<div class="card-top"><span class="live"><span class="dot"></span>APK</span><span data-bg="циферблат">watch face</span></div>
<h3>EVIL</h3>
<p data-bg="Циферблат за Wear OS във военен стил: двуцветен час с шаблонен шрифт, червена секундна стрелка по минутната скала и девет полета с данни на живо — пулс, крачки, изминато разстояние, батерия, известия, температура и дъжд. Само ресурси, без код.">A military-style watch face for Wear OS: two-tone stencil time, a red seconds hand sweeping the minute bezel and nine live data fields — heart rate, steps, distance, battery, notifications, temperature and rain. Resources only, no code.</p>
<ul class="chips"><li>Wear OS</li><li>Watch Face Format</li><li>PowerShell</li></ul>
<span class="gh" data-repo="evil-watchface" hidden></span>
<div class="cta">
<a class="btn hot" href="https://github.com/hackthecode/evil-watchface/releases/latest" target="_blank" rel="noopener" data-bg="▼ Свали APK">▼ Get APK</a>
<a class="btn" href="https://github.com/hackthecode/evil-watchface" target="_blank" rel="noopener" data-bg="Код ↗">Source ↗</a>
</div>
</div></article>
<article class="card"><div class="card-in">
<a class="shot" href="https://github.com/hackthecode/nixie-watchface" tabindex="-1" aria-hidden="true"><img src="assets/anim-nixie-watchface.png" width="800" height="450" alt="Nixie watch face: four glowing nixie tubes showing the time" loading="lazy"></a>
<div class="card-top"><span class="live"><span class="dot"></span>APK</span><span data-bg="циферблат">watch face</span></div>
<h3>Nixie</h3>
<p data-bg="Часовник с газоразрядни лампи за Wear OS: четири лампи тип ИН-14 със светещи цифри, видими неактивни катоди зад тях и неонов индикатор за батерията. Всяко изображение е генерирано с код — без снимки.">A nixie tube clock for Wear OS: four IN-14 style tubes with glowing wire digits, the unlit cathodes visible behind them and a neon battery gauge. Every bitmap is rendered by code — no photos.</p>
<ul class="chips"><li>Wear OS</li><li>Watch Face Format</li><li>C#</li></ul>
<span class="gh" data-repo="nixie-watchface" hidden></span>
<div class="cta">
<a class="btn hot" href="https://github.com/hackthecode/nixie-watchface/releases/latest" target="_blank" rel="noopener" data-bg="▼ Свали APK">▼ Get APK</a>
<a class="btn" href="https://github.com/hackthecode/nixie-watchface" target="_blank" rel="noopener" data-bg="Код ↗">Source ↗</a>
</div>
</div></article>
<article class="card"><div class="card-in">
<a class="shot" href="https://github.com/hackthecode/predator-watchface" tabindex="-1" aria-hidden="true"><img src="assets/anim-predator-watchface.png" width="800" height="450" alt="Predator watch face: red dash-style digits on black" loading="lazy"></a>
<div class="card-top"><span class="live"><span class="dot"></span>APK</span><span data-bg="циферблат">watch face</span></div>
<h3>Predator</h3>
<p data-bg="Китков дисплей на ловец за Wear OS: яркочервени чертички върху чисто черно. Събужда се с извънземни символи, които за две секунди се сглобяват в часа и после пак се разпадат на символи. Батерията е ред от десет чертички.">A hunter's wrist display for Wear OS: bright red dashes on pure black. It wakes showing alien symbols that assemble into the time over two seconds, then fall apart into symbols again. The battery is a row of ten dashes.</p>
<ul class="chips"><li>Wear OS</li><li>Watch Face Format</li><li>C#</li></ul>
<span class="gh" data-repo="predator-watchface" hidden></span>
<div class="cta">
<a class="btn hot" href="https://github.com/hackthecode/predator-watchface/releases/latest" target="_blank" rel="noopener" data-bg="▼ Свали APK">▼ Get APK</a>
<a class="btn" href="https://github.com/hackthecode/predator-watchface" target="_blank" rel="noopener" data-bg="Код ↗">Source ↗</a>
</div>
</div></article>
</div>
</section>
<section id="skills">
<div class="sec-head">
<h2 data-bg="Умения">Skills</h2><span class="rule"></span>
<span class="count" data-bg="самооценка">self-assessed</span>
</div>
<div class="skills">
<div class="skill"><div class="skill-top"><b data-bg="Мрежи">Networks</b><span>routing · switching · services</span></div><div class="meter" style="--v:9" role="img" aria-label="Networks: 9 of 10"></div></div>
<div class="skill"><div class="skill-top"><b data-bg="Системна администрация">System administration</b><span>Windows · Linux · FreeBSD</span></div><div class="meter" style="--v:9" role="img" aria-label="System administration: 9 of 10"></div></div>
<div class="skill"><div class="skill-top"><b data-bg="Linux / BSD">Linux / BSD</b><span>Red Hat · Debian · Arch · FreeBSD</span></div><div class="meter" style="--v:8" role="img" aria-label="Linux / BSD: 8 of 10"></div></div>
<div class="skill"><div class="skill-top"><b data-bg="Програмиране">Programming</b><span>Java · C# · JavaScript · Python · PHP</span></div><div class="meter" style="--v:7" role="img" aria-label="Programming: 7 of 10"></div></div>
</div>
</section>
<section>
<div class="sec-head">
<h2 data-bg="Архив">Archive</h2><span class="rule"></span>
<span class="count" data-bg="учебни записи">training logs</span>
</div>
<ul class="arch" id="archive-list">
<li><a data-repo="Java-Fundamentals-2016" href="https://github.com/hackthecode/Java-Fundamentals-2016" target="_blank" rel="noopener">
<span class="n">Java-Fundamentals-2016<small data-bg="Упражнения от курса Java Fundamentals в СофтУни">Exercises from the SoftUni Java Fundamentals course</small></span>
<span class="l">Java</span><span class="y">2016</span></a></li>
<li><a data-repo="SoftUni_Programming_Basics-11.2015" href="https://github.com/hackthecode/SoftUni_Programming_Basics-11.2015" target="_blank" rel="noopener">
<span class="n">SoftUni_Programming_Basics-11.2015<small data-bg="Домашни от курса Programming Basics в СофтУни">Homework from the SoftUni Programming Basics course</small></span>
<span class="l">C#</span><span class="y">2015</span></a></li>
</ul>
</section>
<section id="profile">
<div class="sec-head">
<h2 data-bg="Профил">Profile</h2><span class="rule"></span>
<span class="count">cat ~/*.txt</span>
</div>
<div class="term wide" aria-label="Profile terminal">
<div class="term-head"><span>evil@hackthecode:~</span><span>tty2</span></div>
<pre id="profile-term"><span class="p">$</span> whoami
<span class="o">Real Name: </span>Dragomir Tsanev
<span class="o">Nick Name: </span>HackTheCode, Evil, Evil9009
<span class="p">$</span> cat ~/profile.txt
Wide range of computing
<span class="k">OS:</span>
<span class="o">- Windows - 95, 98, 2000, ME, XP, Vista, 7, 8, 10, 11
- Linux - Red Hat, Fedora, CentOS, Debian, Ubuntu, Mandriva, Arch Linux, Pop!_OS
- BSD - FreeBSD 6.x through 15.x
- macOS - Mac OS X 10.x through the latest macOS
- Mobile - Android, iOS</span>
<span class="k">Programming and Scripting Languages:</span>
<span class="o">- Java, C#, JavaScript, Python, PHP, bash, SQL, HTML, CSS</span>
<span class="p">$</span> cat ~/work.txt
<span class="o">- TOP-MAN
- GlobalPakBG Ltd.
- Micronet Ltd.
- Gloub Industries Ltd.</span>
<span class="p">$</span> cat ~/interests.txt
<span class="o">- Computer science
- Network technologies
- Electronic engineering
- Open Source</span>
<span class="p">$</span> cat ~/web.txt
<span class="o">- GitHub - </span><a href="https://github.com/hackthecode" target="_blank" rel="noopener">github.com/hackthecode</a>
<span class="o">- Facebook - </span><a href="https://www.facebook.com/HackTheCode" target="_blank" rel="noopener">facebook.com/HackTheCode</a>
<span class="o">- Instagram - </span><a href="https://www.instagram.com/evil___society/" target="_blank" rel="noopener">instagram.com/evil___society</a>
<span class="o">- TikTok - </span><a href="https://www.tiktok.com/@hackthecode" target="_blank" rel="noopener">tiktok.com/@hackthecode</a>
<span class="o">- Discord - </span><a href="https://discord.com/users/139028293985894400" target="_blank" rel="noopener">Evil</a>
<span class="o">- Discord - </span><a href="https://discord.com/channels/139031858754093056" target="_blank" rel="noopener">Evil_Society</a> <span class="o">(server)</span>
<span class="p">$</span> <span class="caret"></span></pre>
</div>
</section>
</main>
<footer>
<div class="wrap">
<span>© 2026 Dragomir Tsanev</span>
<span data-bg="без тракери · без бисквитки">no trackers · no cookies</span>
<ul class="social">
<li><a href="https://github.com/hackthecode" target="_blank" rel="noopener" aria-label="GitHub"><b>GH</b><span>GitHub</span></a></li>
<li><a href="https://www.facebook.com/HackTheCode" target="_blank" rel="noopener" aria-label="Facebook"><b>FB</b><span>Facebook</span></a></li>
<li><a href="https://www.instagram.com/evil___society/" target="_blank" rel="noopener" aria-label="Instagram"><b>IG</b><span>Instagram</span></a></li>
<li><a href="https://www.tiktok.com/@hackthecode" target="_blank" rel="noopener" aria-label="TikTok"><b>TT</b><span>TikTok</span></a></li>
<li><a href="https://discord.com/users/139028293985894400" target="_blank" rel="noopener" aria-label="Discord"><b>DC</b><span>Discord</span></a></li>
</ul>
</div>
</footer>
<div class="fx fx-scan" aria-hidden="true"></div>
<div class="fx fx-vig" aria-hidden="true"></div>
<script>
(() => {
const root = document.documentElement;
const store = {
get(k) { try { return localStorage.getItem(k); } catch (e) { return null; } },
set(k, v) { try { localStorage.setItem(k, v); } catch (e) {} },
};
// ---- effects switch: on for everyone, the button in the bar turns them off ----
const fxBtn = document.getElementById("fx-toggle");
let fx = store.get("htc.fx") !== "off";
const applyFx = () => {
root.classList.toggle("fx-off", !fx);
fxBtn.setAttribute("aria-pressed", String(fx));
fxBtn.querySelector("b").textContent = fx ? "ON" : "OFF";
};
applyFx();
fxBtn.addEventListener("click", () => { fx = !fx; store.set("htc.fx", fx ? "on" : "off"); applyFx(); });
// ---- decode: a heading resolves out of scrambled symbols ----
const NOISE = "01#$%&/<>[]{}=+*!?";
const decode = (el) => {
clearInterval(el._dec);
const target = el.textContent;
if (!fx || !target.trim()) return;
let shown = 0;
el._dec = setInterval(() => {
shown += Math.max(1, target.length / 14);
if (shown >= target.length) { clearInterval(el._dec); el.textContent = target; return; }
let out = target.slice(0, shown | 0);
for (let i = shown | 0; i < target.length; i++) {
out += target[i] === " " ? " " : NOISE[(Math.random() * NOISE.length) | 0];
}
el.textContent = out;
}, 45);
};
// ---- language: English is in the markup, Bulgarian in data-bg ----
const nodes = [...document.querySelectorAll("[data-bg]")];
nodes.forEach((n) => { n.dataset.en = n.innerHTML; });
const setLang = (lang) => {
nodes.forEach((n) => { clearInterval(n._dec); n.innerHTML = lang === "bg" ? n.dataset.bg : n.dataset.en; });
root.lang = lang;
document.getElementById("lang-en").setAttribute("aria-pressed", String(lang === "en"));
document.getElementById("lang-bg").setAttribute("aria-pressed", String(lang === "bg"));
store.set("htc.lang", lang);
};
setLang(store.get("htc.lang") || ((navigator.language || "").toLowerCase().startsWith("bg") ? "bg" : "en"));
document.getElementById("lang-en").addEventListener("click", () => setLang("en"));
document.getElementById("lang-bg").addEventListener("click", () => setLang("bg"));
// ---- Sofia clock ----
const clock = document.getElementById("clock");
const fmt = new Intl.DateTimeFormat("en-GB", { timeZone: "Europe/Sofia", hour: "2-digit", minute: "2-digit", second: "2-digit" });
const tick = () => { clock.textContent = fmt.format(new Date()); };
tick(); setInterval(tick, 1000);
// ---- terminals: retype the session that is already on the page ----
// Commands are typed key by key, their output prints line by line.
const caret = '<span class="caret"></span>';
const retype = (term) => {
const full = term.innerHTML;
const lines = full.replace(caret, "").split("\n");
const strip = (h) => h.replace(/<[^>]+>/g, "");
let li = 0, ci = 0, done = "";
const step = () => {
if (li >= lines.length) { term.innerHTML = full; return; }
const line = lines[li], last = li === lines.length - 1;
if (!line.startsWith('<span class="p">')) {
done += line + "\n"; li++; term.innerHTML = done + caret; setTimeout(step, line ? 70 : 20); return;
}
const text = strip(line).slice(2);
if (ci <= text.length) {
term.innerHTML = done + '<span class="p">$</span> ' + text.slice(0, ci) + caret;
ci++; setTimeout(step, 32 + Math.random() * 46);
} else {
done += line + (last ? "" : "\n"); li++; ci = 0; setTimeout(step, 200);
}
};
term.style.minHeight = term.offsetHeight + "px"; // the page below must not jump while typing
term.innerHTML = '<span class="p">$</span> ' + caret;
setTimeout(step, 450);
};
// ---- things that start when they scroll into view ----
const onSeen = (el, fn, threshold) => {
if (!("IntersectionObserver" in window)) return;
const io = new IntersectionObserver((hits) => {
if (hits.some((h) => h.isIntersecting)) { io.disconnect(); fn(el); }
}, { threshold: threshold || 0.2 });
io.observe(el);
};
const startPage = () => {
document.querySelectorAll("h1 .glitch").forEach(decode);
retype(document.getElementById("term"));
document.querySelectorAll(".sec-head h2").forEach((h2) => onSeen(h2, decode, 0.6));
onSeen(document.getElementById("profile-term"), retype, 0.15);
document.querySelectorAll(".meter").forEach((m) => onSeen(m, (el) => el.classList.add("on"), 0.6));
};
// ---- boot screen: once per visit, any key or click skips it ----
const BOOT = [
"HTC-BIOS v2.6 // hackthecode.github.io",
"",
"CPU ................... OK",
"MEMORY ................ 640K OK",
"NET: uplink ........... ESTABLISHED",
"MOUNT /home/evil ...... OK",
"LOADING dossier ....... OK",
"DECRYPTING projects ... OK",
"",
"ACCESS GRANTED",
];
let booted = false;
try { booted = sessionStorage.getItem("htc.boot") === "1"; } catch (e) {}
if (!fx || booted) {
startPage();
} else {
try { sessionStorage.setItem("htc.boot", "1"); } catch (e) {}
const boot = document.createElement("div");
boot.id = "boot";
boot.setAttribute("aria-hidden", "true");
const pre = document.createElement("pre");
boot.append(pre);
document.body.append(boot);
let i = 0, over = false;
const finish = () => {
if (over) return;
over = true;
clearInterval(timer);
boot.classList.add("out");
setTimeout(() => boot.remove(), 450);
startPage();
};
const timer = setInterval(() => {
if (i >= BOOT.length) { clearInterval(timer); setTimeout(finish, 380); return; }
const row = document.createElement("div");
row.textContent = BOOT[i] || " ";
if (i === BOOT.length - 1) row.className = "ok";
pre.append(row);
i++;
}, 130);
boot.addEventListener("click", finish);
addEventListener("keydown", finish, { once: true });
}
// ---- projects from GitHub: stars and last update on the cards, new public repos into the archive ----
const KNOWN = new Set(["hackthecode.github.io"]);
document.querySelectorAll("[data-repo]").forEach((el) => KNOWN.add(el.dataset.repo));
fetch("https://api.github.com/users/hackthecode/repos?per_page=100&sort=pushed")
.then((r) => (r.ok ? r.json() : Promise.reject(r.status)))
.then((repos) => {
const list = document.getElementById("archive-list");
repos.forEach((repo) => {
const pushed = (repo.pushed_at || "").slice(0, 7);
document.querySelectorAll('.gh[data-repo="' + repo.name + '"]').forEach((el) => {
el.textContent = (repo.stargazers_count ? "★ " + repo.stargazers_count + " · " : "") + "updated " + pushed;
el.hidden = false;
});
if (KNOWN.has(repo.name) || repo.fork || repo.private) return;
const a = document.createElement("a");
a.href = repo.html_url; a.target = "_blank"; a.rel = "noopener";
const n = document.createElement("span"); n.className = "n"; n.textContent = repo.name;
if (repo.description) { const d = document.createElement("small"); d.textContent = repo.description; n.append(d); }
const l = document.createElement("span"); l.className = "l"; l.textContent = repo.language || "";
const y = document.createElement("span"); y.className = "y"; y.textContent = pushed.slice(0, 4);
a.append(n, l, y);
const li = document.createElement("li"); li.append(a);
list.prepend(li);
});
})
.catch(() => {}); // offline or rate-limited: the page keeps what is written in it
// ---- hex rain that lights up around the pointer ----
const cv = document.getElementById("rain");
if (cv.getContext) {
const cx = cv.getContext("2d");
const glyphs = "0123456789ABCDEF<>/{}#$";
const size = 18;
let cols = 0, drops = [], w = 0, h = 0, px = -9999, py = -9999;
const fit = () => {
w = cv.width = innerWidth; h = cv.height = innerHeight;
cols = Math.ceil(w / size);
drops = Array.from({ length: cols }, () => Math.random() * -60);
};
fit(); addEventListener("resize", fit);
addEventListener("pointermove", (e) => { px = e.clientX; py = e.clientY; }, { passive: true });
addEventListener("pointerleave", () => { px = py = -9999; });
const glyph = () => glyphs[(Math.random() * glyphs.length) | 0];
let last = 0, wasOn = true;
const draw = (t) => {
requestAnimationFrame(draw);
if (!fx) { if (wasOn) { cx.clearRect(0, 0, w, h); wasOn = false; } return; }
wasOn = true;
if (document.hidden || t - last < 70) return;
last = t;
cx.fillStyle = "rgba(5,5,6,.14)"; cx.fillRect(0, 0, w, h);
cx.font = size - 4 + "px JetBrains Mono, monospace";
for (let i = 0; i < cols; i++) {
const x = i * size, y = drops[i] * size;
const near = Math.hypot(x - px, y - py) < 150;
cx.fillStyle = near || Math.random() < .04 ? "#ece5dd" : "#ff1f33";
cx.fillText(glyph(), x, y);
drops[i] = y > h && Math.random() > .975 ? 0 : drops[i] + 1;
}
// sparks of bright symbols right under the pointer
if (px > -999) {
cx.fillStyle = "#ece5dd";
for (let k = 0; k < 3; k++) {
const a = Math.random() * 6.283, r = Math.random() * 110;
cx.fillText(glyph(), Math.round((px + Math.cos(a) * r) / size) * size, Math.round((py + Math.sin(a) * r) / size) * size);
}
}
};
requestAnimationFrame(draw);
}
})();
</script>
</body>
</html>