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
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
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>HOLOBOX - 8-bit Chiptune Jukebox</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://cdn.jsdelivr.net/npm/@tonejs/[email protected]/build/Midi.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/tone/14.8.49/Tone.js"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        @import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');
        
        body {
            background-color: #0a0a1a;
            font-family: 'Press Start 2P', cursive;
            overflow: hidden;
            height: 100vh;
            display: flex;
            justify-content: center;
            align-items: center;
        }
        
        .holobox {
            position: relative;
            width: 400px;
            height: 500px;
            background-color: #111;
            border-radius: 10px;
            box-shadow: 
                0 0 10px #0ff,
                0 0 20px #0ff,
                0 0 30px #0ff,
                inset 0 0 10px rgba(0, 255, 255, 0.5);
            padding: 20px;
            border: 4px solid #333;
        }
        
        .screen {
            width: 100%;
            height: 250px;
            background-color: #000;
            border: 4px solid #333;
            margin-bottom: 20px;
            position: relative;
            overflow: hidden;
            box-shadow: inset 0 0 20px rgba(0, 255, 255, 0.3);
        }
        
        .pixel-grid {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-image: 
                linear-gradient(rgba(0, 255, 255, 0.1) 1px, transparent 1px),
                linear-gradient(90deg, rgba(0, 255, 255, 0.1) 1px, transparent 1px);
            background-size: 20px 20px;
        }
        
        .title {
            color: #0ff;
            text-align: center;
            font-size: 24px;
            margin-bottom: 10px;
            text-shadow: 0 0 5px #0ff;
            letter-spacing: 2px;
        }
        
        .buttons {
            display: flex;
            justify-content: space-around;
            margin-top: 30px;
        }
        
        .btn {
            width: 80px;
            height: 80px;
            border-radius: 50%;
            background-color: #222;
            border: 4px solid #333;
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
            transition: all 0.3s;
            position: relative;
            box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
        }
        
        .btn:hover {
            transform: scale(1.05);
            box-shadow: 0 0 15px #0ff;
        }
        
        .btn.active {
            box-shadow: 0 0 20px #0ff, 0 0 30px #0ff;
            background-color: #0ff;
        }
        
        .btn i {
            font-size: 30px;
            color: #0ff;
        }
        
        .btn.active i {
            color: #000;
        }
        
        .btn::before {
            content: '';
            position: absolute;
            top: -5px;
            left: -5px;
            right: -5px;
            bottom: -5px;
            border-radius: 50%;
            border: 2px solid #0ff;
            opacity: 0;
            transition: all 0.3s;
        }
        
        .btn:hover::before {
            opacity: 1;
        }
        
        .btn.active::before {
            opacity: 1;
            animation: pulse 1.5s infinite;
        }
        
        @keyframes pulse {
            0% {
                transform: scale(1);
                opacity: 0.7;
            }
            70% {
                transform: scale(1.3);
                opacity: 0;
            }
            100% {
                transform: scale(1);
                opacity: 0;
            }
        }
        
        .display {
            background-color: #111;
            color: #0ff;
            padding: 10px;
            border: 2px solid #333;
            margin-top: 20px;
            font-size: 12px;
            text-align: center;
            min-height: 40px;
            display: flex;
            align-items: center;
            justify-content: center;
            text-shadow: 0 0 5px #0ff;
            box-shadow: inset 0 0 10px rgba(0, 255, 255, 0.2);
        }
        
        .pixel {
            position: absolute;
            width: 10px;
            height: 10px;
            background-color: #0ff;
            opacity: 0;
        }
        
        .equalizer {
            position: absolute;
            bottom: 10px;
            left: 0;
            width: 100%;
            height: 60px;
            display: flex;
            justify-content: center;
            align-items: flex-end;
            gap: 5px;
        }
        
        .bar {
            width: 10px;
            background-color: #0ff;
            border-radius: 2px;
            transition: height 0.1s;
            box-shadow: 0 0 5px #0ff;
        }
        
        .scanlines {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: linear-gradient(
                rgba(0, 0, 0, 0) 50%,
                rgba(0, 255, 255, 0.1) 50%
            );
            background-size: 100% 4px;
            pointer-events: none;
        }
        
        .glitch {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%"><rect width="100%" height="1" fill="%230ff" opacity="0.1"/></svg>');
            animation: glitch 5s infinite;
            opacity: 0.3;
            pointer-events: none;
        }
        
        @keyframes glitch {
            0%, 100% { transform: translate(0); }
            20% { transform: translate(-2px, 2px); }
            40% { transform: translate(-2px, -2px); }
            60% { transform: translate(2px, 2px); }
            80% { transform: translate(2px, -2px); }
        }
        
        .corner {
            position: absolute;
            width: 30px;
            height: 30px;
            border-color: #0ff;
            border-style: solid;
            border-width: 0;
            opacity: 0.7;
        }
        
        .corner-tl {
            top: 10px;
            left: 10px;
            border-top-width: 3px;
            border-left-width: 3px;
        }
        
        .corner-tr {
            top: 10px;
            right: 10px;
            border-top-width: 3px;
            border-right-width: 3px;
        }
        
        .corner-bl {
            bottom: 10px;
            left: 10px;
            border-bottom-width: 3px;
            border-left-width: 3px;
        }
        
        .corner-br {
            bottom: 10px;
            right: 10px;
            border-bottom-width: 3px;
            border-right-width: 3px;
        }
    </style>
</head>
<body>
    <div class="holobox">
        <div class="corner corner-tl"></div>
        <div class="corner corner-tr"></div>
        <div class="corner corner-bl"></div>
        <div class="corner corner-br"></div>
        
        <div class="title">HOLOBOX</div>
        <div class="screen">
            <div class="pixel-grid"></div>
            <div class="glitch"></div>
            <div class="scanlines"></div>
            <div class="equalizer" id="equalizer"></div>
        </div>
        <div class="display" id="display">READY</div>
        <div class="buttons">
            <div class="btn" id="btn1" data-song="1">
                <i class="fas fa-space-shuttle"></i>
            </div>
            <div class="btn" id="btn2" data-song="2">
                <i class="fas fa-robot"></i>
            </div>
            <div class="btn" id="btn3" data-song="3">
                <i class="fas fa-gamepad"></i>
            </div>
        </div>
    </div>

    <script>
        document.addEventListener('DOMContentLoaded', function() {
            // Initialize Tone.js
            Tone.start();
            
            // Create equalizer bars
            const equalizer = document.getElementById('equalizer');
            for (let i = 0; i < 30; i++) {
                const bar = document.createElement('div');
                bar.className = 'bar';
                bar.style.height = '5px';
                equalizer.appendChild(bar);
            }
            
            // Create pixel animation
            const screen = document.querySelector('.screen');
            for (let i = 0; i < 50; i++) {
                const pixel = document.createElement('div');
                pixel.className = 'pixel';
                pixel.style.left = Math.random() * 100 + '%';
                pixel.style.top = Math.random() * 100 + '%';
                pixel.style.opacity = Math.random() * 0.5;
                screen.appendChild(pixel);
                
                animatePixel(pixel);
            }
            
            function animatePixel(pixel) {
                const duration = 2000 + Math.random() * 3000;
                const delay = Math.random() * 5000;
                
                setTimeout(() => {
                    pixel.style.transition = `all ${duration}ms linear`;
                    pixel.style.left = Math.random() * 100 + '%';
                    pixel.style.top = Math.random() * 100 + '%';
                    
                    setTimeout(() => {
                        pixel.style.transition = 'none';
                        pixel.style.left = Math.random() * 100 + '%';
                        pixel.style.top = Math.random() * 100 + '%';
                        animatePixel(pixel);
                    }, duration);
                }, delay);
            }
            
            // MIDI player setup
            let currentPlayer = null;
            const display = document.getElementById('display');
            const buttons = document.querySelectorAll('.btn');
            
            // Sample MIDI files (in reality you would load actual MIDI files)
            const songs = [
                { 
                    name: "GALACTIC CRUISE", 
                    // This would be replaced with actual MIDI file loading
                    play: function() {
                        display.textContent = "PLAYING: GALACTIC CRUISE";
                        startEqualizer();
                        return { stop: function() { stopEqualizer(); } };
                    }
                },
                { 
                    name: "ROBOT DANCE", 
                    play: function() {
                        display.textContent = "PLAYING: ROBOT DANCE";
                        startEqualizer();
                        return { stop: function() { stopEqualizer(); } };
                    }
                },
                { 
                    name: "ARCADE BLAST", 
                    play: function() {
                        display.textContent = "PLAYING: ARCADE BLAST";
                        startEqualizer();
                        return { stop: function() { stopEqualizer(); } };
                    }
                }
            ];
            
            // Equalizer animation
            let equalizerInterval;
            function startEqualizer() {
                const bars = document.querySelectorAll('.bar');
                clearInterval(equalizerInterval);
                
                equalizerInterval = setInterval(() => {
                    bars.forEach(bar => {
                        const height = 5 + Math.random() * 55;
                        bar.style.height = height + 'px';
                        bar.style.opacity = 0.1 + (height / 60) * 0.9;
                    });
                }, 100);
            }
            
            function stopEqualizer() {
                clearInterval(equalizerInterval);
                const bars = document.querySelectorAll('.bar');
                bars.forEach(bar => {
                    bar.style.height = '5px';
                    bar.style.opacity = '0.1';
                });
            }
            
            // Button click handlers
            buttons.forEach(btn => {
                btn.addEventListener('click', function() {
                    const songIndex = parseInt(this.getAttribute('data-song')) - 1;
                    
                    // Stop current song if playing
                    if (currentPlayer) {
                        currentPlayer.stop();
                        document.querySelector('.btn.active')?.classList.remove('active');
                    }
                    
                    // Start new song
                    currentPlayer = songs[songIndex].play();
                    this.classList.add('active');
                });
            });
            
            // Simulate CRT power-on effect
            setTimeout(() => {
                screen.style.boxShadow = 'inset 0 0 20px rgba(0, 255, 255, 0.5)';
                display.style.textShadow = '0 0 5px #0ff';
            }, 500);
        });
    </script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=porkz/holobox" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>