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
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
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>ScreenVivid - 3D Video Animation Tool</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        .timeline-clip {
            min-width: 60px;
        }
        .gizmo {
            position: absolute;
            width: 100px;
            height: 100px;
            pointer-events: none;
        }
        .gizmo-arrow {
            position: absolute;
            width: 20px;
            height: 20px;
            background-color: rgba(255,255,255,0.7);
            border: 1px solid #333;
            cursor: pointer;
        }
        .gizmo-x { background-color: #ff4d4d; }
        .gizmo-y { background-color: #4dff4d; }
        .gizmo-z { background-color: #4d4dff; }
        .keyframe {
            width: 8px;
            height: 8px;
            background-color: #3b82f6;
            position: absolute;
            bottom: 0;
            transform: translateX(-50%) rotate(45deg);
            cursor: pointer;
        }
        .playhead {
            position: absolute;
            top: 0;
            bottom: 0;
            width: 2px;
            background-color: #ef4444;
            z-index: 10;
        }
        .playhead::after {
            content: '';
            position: absolute;
            top: 0;
            left: -4px;
            width: 10px;
            height: 10px;
            background-color: #ef4444;
            border-radius: 50%;
        }
        .canvas-container {
            position: relative;
            background-color: #1e293b;
        }
        .aspect-ratio-guide {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            border: 1px dashed rgba(255,255,255,0.3);
            pointer-events: none;
        }
        .timeline-track {
            height: 40px;
            border-bottom: 1px solid #334155;
            position: relative;
        }
        .timeline-ruler {
            height: 20px;
            background-color: #1e293b;
            border-bottom: 1px solid #334155;
            position: relative;
        }
        .timeline-ruler-mark {
            position: absolute;
            bottom: 0;
            width: 1px;
            height: 6px;
            background-color: #64748b;
        }
        .timeline-ruler-label {
            position: absolute;
            bottom: 8px;
            transform: translateX(-50%);
            font-size: 10px;
            color: #94a3b8;
        }
    </style>
</head>
<body class="bg-slate-900 text-white h-screen flex flex-col overflow-hidden">
    <!-- Top Navigation -->
    <header class="bg-slate-800 p-2 flex items-center justify-between border-b border-slate-700">
        <div class="flex items-center space-x-4">
            <h1 class="text-xl font-bold text-blue-400 flex items-center">
                <i class="fas fa-film mr-2"></i> ScreenVivid
            </h1>
            <div class="hidden md:flex space-x-2">
                <button class="px-3 py-1 bg-slate-700 hover:bg-slate-600 rounded text-sm flex items-center">
                    <i class="fas fa-plus mr-1"></i> New
                </button>
                <button class="px-3 py-1 bg-slate-700 hover:bg-slate-600 rounded text-sm flex items-center">
                    <i class="fas fa-folder-open mr-1"></i> Open
                </button>
                <button class="px-3 py-1 bg-blue-600 hover:bg-blue-500 rounded text-sm flex items-center">
                    <i class="fas fa-file-export mr-1"></i> Export
                </button>
            </div>
        </div>
        <div class="flex items-center space-x-4">
            <button class="p-2 hover:bg-slate-700 rounded-full">
                <i class="fas fa-question-circle"></i>
            </button>
            <button class="p-2 hover:bg-slate-700 rounded-full">
                <i class="fas fa-cog"></i>
            </button>
        </div>
    </header>

    <!-- Main Content Area -->
    <div class="flex flex-1 overflow-hidden">
        <!-- Left Panel - Media Library -->
        <div class="w-64 bg-slate-800 border-r border-slate-700 flex flex-col">
            <div class="p-3 border-b border-slate-700 flex justify-between items-center">
                <h2 class="font-medium">Media Library</h2>
                <button class="p-1 hover:bg-slate-700 rounded">
                    <i class="fas fa-ellipsis-v"></i>
                </button>
            </div>
            <div class="p-3 border-b border-slate-700">
                <button id="upload-btn" class="w-full py-2 bg-blue-600 hover:bg-blue-500 rounded flex items-center justify-center">
                    <i class="fas fa-upload mr-2"></i> Upload Media
                </button>
                <input type="file" id="file-input" class="hidden" accept="video/mp4,video/webm" multiple>
            </div>
            <div class="flex-1 overflow-y-auto p-2">
                <div class="grid grid-cols-2 gap-2" id="media-library">
                    <!-- Media items will be added here -->
                    <div class="media-item bg-slate-700 rounded overflow-hidden cursor-pointer">
                        <div class="aspect-video bg-slate-600 flex items-center justify-center">
                            <i class="fas fa-video text-2xl text-slate-400"></i>
                        </div>
                        <div class="p-2">
                            <p class="text-xs font-medium truncate">Sample Video.mp4</p>
                            <p class="text-xs text-slate-400">1920x1080</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- Center Canvas -->
        <div class="flex-1 flex flex-col">
            <!-- Preview Canvas -->
            <div class="canvas-container flex-1 relative">
                <div class="aspect-ratio-guide" style="width: 80%; height: 45%;"></div>
                <div class="absolute top-4 left-4 z-10">
                    <div class="bg-slate-800 bg-opacity-70 rounded p-2 text-xs">
                        <div class="flex items-center mb-1">
                            <span class="w-16">FPS:</span>
                            <span id="fps-counter">60</span>
                        </div>
                        <div class="flex items-center">
                            <span class="w-16">Time:</span>
                            <span id="time-display">00:00:00</span>
                        </div>
                    </div>
                </div>
                <div class="absolute top-4 right-4 z-10 flex space-x-2">
                    <button class="p-2 bg-slate-800 bg-opacity-70 hover:bg-slate-700 rounded-full">
                        <i class="fas fa-expand"></i>
                    </button>
                </div>
                <!-- 3D Gizmo -->
                <div class="gizmo" id="gizmo">
                    <div class="gizmo-arrow gizmo-x" style="left: 40px; top: 40px;"></div>
                    <div class="gizmo-arrow gizmo-y" style="left: 40px; top: 20px;"></div>
                    <div class="gizmo-arrow gizmo-z" style="left: 20px; top: 40px;"></div>
                </div>
            </div>

            <!-- Playback Controls -->
            <div class="bg-slate-800 p-2 flex items-center justify-center space-x-4 border-t border-slate-700">
                <button class="p-2 hover:bg-slate-700 rounded-full">
                    <i class="fas fa-step-backward"></i>
                </button>
                <button id="play-btn" class="p-3 bg-blue-600 hover:bg-blue-500 rounded-full">
                    <i class="fas fa-play"></i>
                </button>
                <button class="p-2 hover:bg-slate-700 rounded-full">
                    <i class="fas fa-step-forward"></i>
                </button>
                <div class="flex items-center space-x-2">
                    <span class="text-xs">00:00</span>
                    <input type="range" min="0" max="100" value="0" class="w-64 h-1 bg-slate-600 rounded-lg appearance-none cursor-pointer">
                    <span class="text-xs">01:30</span>
                </div>
                <button class="p-2 hover:bg-slate-700 rounded-full">
                    <i class="fas fa-expand"></i>
                </button>
            </div>
        </div>

        <!-- Right Panel - Properties -->
        <div class="w-64 bg-slate-800 border-l border-slate-700 flex flex-col">
            <div class="p-3 border-b border-slate-700 flex justify-between items-center">
                <h2 class="font-medium">Properties</h2>
                <button class="p-1 hover:bg-slate-700 rounded">
                    <i class="fas fa-ellipsis-v"></i>
                </button>
            </div>
            <div class="flex-1 overflow-y-auto p-3">
                <div class="mb-4">
                    <h3 class="text-sm font-medium mb-2 flex items-center justify-between">
                        <span>Transform</span>
                        <button class="text-xs text-blue-400 hover:text-blue-300">Reset</button>
                    </h3>
                    <div class="space-y-2">
                        <div class="flex items-center">
                            <label class="w-8 text-xs">X:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="0">
                        </div>
                        <div class="flex items-center">
                            <label class="w-8 text-xs">Y:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="0">
                        </div>
                        <div class="flex items-center">
                            <label class="w-8 text-xs">Z:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="0">
                        </div>
                    </div>
                </div>

                <div class="mb-4">
                    <h3 class="text-sm font-medium mb-2">Rotation</h3>
                    <div class="space-y-2">
                        <div class="flex items-center">
                            <label class="w-8 text-xs">X:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="0">
                        </div>
                        <div class="flex items-center">
                            <label class="w-8 text-xs">Y:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="0">
                        </div>
                        <div class="flex items-center">
                            <label class="w-8 text-xs">Z:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="0">
                        </div>
                    </div>
                </div>

                <div class="mb-4">
                    <h3 class="text-sm font-medium mb-2">Scale</h3>
                    <div class="space-y-2">
                        <div class="flex items-center">
                            <label class="w-8 text-xs">X:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="1" step="0.1">
                        </div>
                        <div class="flex items-center">
                            <label class="w-8 text-xs">Y:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="1" step="0.1">
                        </div>
                        <div class="flex items-center">
                            <label class="w-8 text-xs">Z:</label>
                            <input type="number" class="flex-1 bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm" value="1" step="0.1">
                        </div>
                        <div class="flex items-center text-xs">
                            <input type="checkbox" id="lock-aspect" class="mr-2" checked>
                            <label for="lock-aspect">Lock Aspect Ratio</label>
                        </div>
                    </div>
                </div>

                <div class="mb-4">
                    <h3 class="text-sm font-medium mb-2">Opacity</h3>
                    <div class="flex items-center">
                        <input type="range" min="0" max="100" value="100" class="flex-1 h-1 bg-slate-600 rounded-lg appearance-none cursor-pointer">
                        <span class="text-xs ml-2 w-8">100%</span>
                    </div>
                </div>

                <div class="mb-4">
                    <h3 class="text-sm font-medium mb-2">Animation</h3>
                    <select class="w-full bg-slate-700 border border-slate-600 rounded px-2 py-1 text-sm mb-2">
                        <option>None</option>
                        <option>Fade In</option>
                        <option>Slide From Left</option>
                        <option>3D Rotate</option>
                    </select>
                    <div class="text-xs text-slate-400">Keyframes will be automatically added</div>
                </div>
            </div>
        </div>
    </div>

    <!-- Timeline Area -->
    <div class="bg-slate-800 border-t border-slate-700 h-48 flex flex-col">
        <!-- Timeline Tools -->
        <div class="p-2 border-b border-slate-700 flex items-center justify-between">
            <div class="flex space-x-2">
                <button class="p-1 bg-slate-700 hover:bg-slate-600 rounded">
                    <i class="fas fa-cut text-xs"></i>
                </button>
                <button class="p-1 bg-slate-700 hover:bg-slate-600 rounded">
                    <i class="fas fa-layer-group text-xs"></i>
                </button>
                <button class="p-1 bg-slate-700 hover:bg-slate-600 rounded">
                    <i class="fas fa-magnet text-xs"></i>
                </button>
            </div>
            <div class="flex items-center space-x-2">
                <button class="p-1 bg-slate-700 hover:bg-slate-600 rounded">
                    <i class="fas fa-search-minus text-xs"></i>
                </button>
                <input type="range" min="1" max="100" value="50" class="w-24 h-1 bg-slate-600 rounded-lg appearance-none cursor-pointer">
                <button class="p-1 bg-slate-700 hover:bg-slate-600 rounded">
                    <i class="fas fa-search-plus text-xs"></i>
                </button>
            </div>
        </div>

        <!-- Timeline Ruler -->
        <div class="timeline-ruler">
            <div class="playhead" style="left: 50px;"></div>
            <!-- Ruler marks will be added here -->
            <div class="timeline-ruler-mark" style="left: 0;"></div>
            <div class="timeline-ruler-mark" style="left: 50px;"></div>
            <div class="timeline-ruler-mark" style="left: 100px;"></div>
            <div class="timeline-ruler-mark" style="left: 150px;"></div>
            <div class="timeline-ruler-mark" style="left: 200px;"></div>
            <div class="timeline-ruler-label" style="left: 0;">0:00</div>
            <div class="timeline-ruler-label" style="left: 100px;">1:00</div>
            <div class="timeline-ruler-label" style="left: 200px;">2:00</div>
        </div>

        <!-- Timeline Tracks -->
        <div class="flex-1 overflow-y-auto">
            <div class="timeline-track">
                <div class="absolute top-0 bottom-0 left-0 w-20 bg-slate-700 flex items-center justify-center text-xs">
                    Video 1
                </div>
                <div class="absolute top-0 bottom-0 left-20 right-0">
                    <div class="timeline-clip bg-blue-600 absolute top-1 bottom-1 rounded" style="left: 50px; width: 100px;">
                        <div class="absolute inset-0 flex items-center justify-center text-xs">Clip 1</div>
                        <div class="keyframe" style="left: 25%;"></div>
                        <div class="keyframe" style="left: 75%;"></div>
                    </div>
                </div>
            </div>
            <div class="timeline-track">
                <div class="absolute top-0 bottom-0 left-0 w-20 bg-slate-700 flex items-center justify-center text-xs">
                    Video 2
                </div>
                <div class="absolute top-0 bottom-0 left-20 right-0">
                    <div class="timeline-clip bg-purple-600 absolute top-1 bottom-1 rounded" style="left: 120px; width: 80px;">
                        <div class="absolute inset-0 flex items-center justify-center text-xs">Clip 2</div>
                    </div>
                </div>
            </div>
            <div class="timeline-track">
                <div class="absolute top-0 bottom-0 left-0 w-20 bg-slate-700 flex items-center justify-center text-xs">
                    Text
                </div>
                <div class="absolute top-0 bottom-0 left-20 right-0">
                    <div class="timeline-clip bg-green-600 absolute top-1 bottom-1 rounded" style="left: 80px; width: 120px;">
                        <div class="absolute inset-0 flex items-center justify-center text-xs">Title</div>
                        <div class="keyframe" style="left: 20%;"></div>
                        <div class="keyframe" style="left: 50%;"></div>
                        <div class="keyframe" style="left: 80%;"></div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script>
        // Basic functionality for the UI
        document.addEventListener('DOMContentLoaded', function() {
            // Upload button functionality
            const uploadBtn = document.getElementById('upload-btn');
            const fileInput = document.getElementById('file-input');
            
            uploadBtn.addEventListener('click', () => {
                fileInput.click();
            });
            
            fileInput.addEventListener('change', (e) => {
                if (e.target.files.length > 0) {
                    // In a real app, we would process these files
                    alert(`${e.target.files.length} file(s) selected for upload`);
                }
            });
            
            // Play/pause button toggle
            const playBtn = document.getElementById('play-btn');
            playBtn.addEventListener('click', () => {
                const icon = playBtn.querySelector('i');
                if (icon.classList.contains('fa-play')) {
                    icon.classList.remove('fa-play');
                    icon.classList.add('fa-pause');
                    // Start playback in a real app
                } else {
                    icon.classList.remove('fa-pause');
                    icon.classList.add('fa-play');
                    // Pause playback in a real app
                }
            });
            
            // Simulate FPS counter
            setInterval(() => {
                document.getElementById('fps-counter').textContent = 
                    Math.floor(50 + Math.random() * 10); // Random FPS between 50-60
            }, 1000);
            
            // Simulate time display
            let seconds = 0;
            setInterval(() => {
                seconds++;
                const mins = Math.floor(seconds / 60);
                const secs = seconds % 60;
                document.getElementById('time-display').textContent = 
                    `00:${mins.toString().padStart(2, '0')}:${secs.toString().padStart(2, '0')}`;
            }, 1000);
            
            // Drag and drop for media items
            const mediaItems = document.querySelectorAll('.media-item');
            mediaItems.forEach(item => {
                item.setAttribute('draggable', 'true');
                item.addEventListener('dragstart', (e) => {
                    e.dataTransfer.setData('text/plain', 'media-item');
                    e.target.classList.add('opacity-50');
                });
                item.addEventListener('dragend', (e) => {
                    e.target.classList.remove('opacity-50');
                });
            });
            
            // Timeline tracks as drop targets
            const tracks = document.querySelectorAll('.timeline-track > div:last-child');
            tracks.forEach(track => {
                track.addEventListener('dragover', (e) => {
                    e.preventDefault();
                    track.classList.add('bg-slate-700', 'bg-opacity-50');
                });
                track.addEventListener('dragleave', () => {
                    track.classList.remove('bg-slate-700', 'bg-opacity-50');
                });
                track.addEventListener('drop', (e) => {
                    e.preventDefault();
                    track.classList.remove('bg-slate-700', 'bg-opacity-50');
                    // In a real app, we would create a new clip at the drop position
                    alert('Media dropped on timeline');
                });
            });
        });
    </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=tamnvcc/editor" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>