Spaces:
Running

File size: 28,569 Bytes
2a164d0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
d8f0f21
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
<!DOCTYPE html>
<html lang="ru">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Clip of The Year | FrunyaShow</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link href="https://unpkg.com/aos@2.3.1/dist/aos.css" rel="stylesheet">
    <script src="https://unpkg.com/aos@2.3.1/dist/aos.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
    <script src="https://unpkg.com/feather-icons"></script>
    <script src="https://cdn.jsdelivr.net/npm/vanta@latest/dist/vanta.globe.min.js"></script>
    <script src="https://apis.google.com/js/api.js"></script>
    <script src="https://extension-files.twitch.tv/helper/v1/twitch-ext.min.js"></script>
    <style>
        .nomination-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
        }
        #vanta-bg {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            z-index: -1;
            opacity: 0.2;
        }
        .clip-preview {
            aspect-ratio: 16/9;
        }
    </style>
</head>
<body class="bg-gray-900 text-white">
    <div id="vanta-bg"></div>
    
    <!-- Header -->
    <header class="bg-black bg-opacity-80 backdrop-blur-md sticky top-0 z-50">
        <div class="container mx-auto px-4 py-4 flex justify-between items-center">
            <div class="flex items-center space-x-2">
                <i data-feather="award" class="text-purple-500"></i>
                <h1 class="text-2xl font-bold bg-gradient-to-r from-purple-500 to-pink-500 bg-clip-text text-transparent">Clip of The Year</h1>
            </div>
            <div id="auth-section">
                <button id="twitch-login" class="bg-purple-600 hover:bg-purple-700 px-4 py-2 rounded-md flex items-center space-x-2 transition">
                    <i data-feather="log-in"></i>
                    <span>Войти через Twitch</span>
                </button>
                <div id="user-profile" class="hidden flex items-center space-x-4">
                    <img id="user-avatar" class="w-10 h-10 rounded-full" src="" alt="Profile">
                    <span id="username" class="font-medium"></span>
                    <button id="logout-btn" class="text-gray-400 hover:text-white">
                        <i data-feather="log-out"></i>
                    </button>
                </div>
            </div>
        </div>
    </header>

    <!-- Hero Section -->
    <section class="py-20 px-4 text-center">
        <div class="max-w-4xl mx-auto" data-aos="fade-up">
            <h2 class="text-4xl md:text-6xl font-bold mb-6">Премия <span class="bg-gradient-to-r from-purple-500 to-pink-500 bg-clip-text text-transparent">Clip of The Year</span></h2>
            <p class="text-xl text-gray-300 mb-8">Отмечаем лучшие моменты стримеров в 10 уникальных номинациях</p>
            <div class="flex flex-col sm:flex-row justify-center gap-4">
                <a href="#nominations" class="bg-purple-600 hover:bg-purple-700 px-6 py-3 rounded-md font-medium transition">Номинации</a>
                <button id="submit-clip-btn" class="bg-pink-600 hover:bg-pink-700 px-6 py-3 rounded-md font-medium transition hidden">Подать клип</button>
            </div>
        </div>
    </section>

    <!-- Nominations Section -->
    <section id="nominations" class="py-16 px-4">
        <div class="container mx-auto">
            <h2 class="text-3xl font-bold mb-12 text-center" data-aos="fade-up">Номинации</h2>
            
            <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
                <!-- Nomination 1 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-purple-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="smile" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Бу! Испугался?"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Самая эмоциональная (смешная/испуганная и тд) реакция на скример</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="1">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 2 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-blue-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="target" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Брошу стримы и пойду в киберспорт"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Лучший скилловый игровой момент а.к.а ноускоуп 360 или блекхол в 5ых. В любой игре.</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="2">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 3 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-red-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="user" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Буду как ЧА"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Самый лучший образ (да тот самый бюджетный косплеер)</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="3">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 4 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-green-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="users" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Команда мечты"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Лучший момент из кооп стримов</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="4">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 5 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-yellow-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="zap" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"АУФ-момент"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Самый мудрый/АУФный момент из стрима</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="5">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 6 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-indigo-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="heart" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"BibleThump"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Самый драматичный момент</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="6">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 7 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-pink-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="thumbs-up" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Ягами позавидует"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Лучший смех твича. Например, заразительный или смех злодея</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="7">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 8 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-orange-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="alert-triangle" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Это фиаско, братан"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Самый фейловый момент. Смешной/фейл</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="8">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 9 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-teal-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="star" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Мимимимими"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Самый милый момент. Игра, стример или даже питомец</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="9">Выбрать</button>
                    </div>
                </div>

                <!-- Nomination 10 -->
                <div class="bg-gray-800 rounded-xl p-6 nomination-card transition duration-300" data-aos="fade-up">
                    <div class="flex items-center mb-4">
                        <div class="bg-gray-500 rounded-full w-10 h-10 flex items-center justify-center mr-4">
                            <i data-feather="award" class="text-white"></i>
                        </div>
                        <h3 class="text-xl font-bold">"Какая-то еще номинация"</h3>
                    </div>
                    <p class="text-gray-300 mb-4">Если вдруг есть клип, который не попал в список номинаций, но он крутой</p>
                    <div class="flex justify-between items-center">
                        <span class="text-sm text-gray-400">Макс. клипов: 1</span>
                        <button class="nomination-select bg-gray-700 hover:bg-gray-600 px-3 py-1 rounded text-sm transition" data-nomination="10">Выбрать</button>
                    </div>
                </div>
            </div>
        </div>
    </section>

    <!-- Submission Modal -->
    <div id="submission-modal" class="fixed inset-0 bg-black bg-opacity-70 z-50 hidden flex items-center justify-center p-4">
        <div class="bg-gray-800 rounded-xl max-w-2xl w-full max-h-[90vh] overflow-y-auto">
            <div class="p-6">
                <div class="flex justify-between items-center mb-6">
                    <h3 class="text-2xl font-bold" id="modal-title">Подача клипа</h3>
                    <button id="close-modal" class="text-gray-400 hover:text-white">
                        <i data-feather="x"></i>
                    </button>
                </div>
                
                <form id="clip-form" class="space-y-4">
                    <input type="hidden" id="nomination-id">
                    
                    <div>
                        <label for="clip-url" class="block mb-2 font-medium">Ссылка на клип (Twitch Clip)</label>
                        <input type="url" id="clip-url" class="w-full bg-gray-700 border border-gray-600 rounded-md px-4 py-2 focus:outline-none focus:ring-2 focus:ring-purple-500" placeholder="https://clips.twitch.tv/..." required>
                    </div>
                    
                    <div>
                        <label for="clip-description" class="block mb-2 font-medium">Описание (почему этот клип достоин победы?)</label>
                        <textarea id="clip-description" rows="3" class="w-full bg-gray-700 border border-gray-600 rounded-md px-4 py-2 focus:outline-none focus:ring-2 focus:ring-purple-500" required></textarea>
                    </div>
                    
                    <div id="clip-preview-container" class="hidden">
                        <label class="block mb-2 font-medium">Предпросмотр клипа</label>
                        <div class="clip-preview bg-black rounded-md overflow-hidden">
                            <iframe id="clip-preview" class="w-full h-full" frameborder="0" allowfullscreen></iframe>
                        </div>
                    </div>
                    
                    <div id="eligibility-message" class="hidden bg-red-900 bg-opacity-50 p-4 rounded-md">
                        <div class="flex items-start">
                            <i data-feather="alert-circle" class="mr-2 mt-1"></i>
                            <div>
                                <p class="font-medium">У вас пока недостаточно подписчиков для участия</p>
                                <p class="text-sm mt-1">Вы можете предложить своему стримеру поучаствовать на премии</p>
                            </div>
                        </div>
                    </div>
                    
                    <div class="pt-4">
                        <button type="submit" id="submit-clip" class="w-full bg-purple-600 hover:bg-purple-700 px-6 py-3 rounded-md font-medium transition">Отправить клип</button>
                    </div>
                </form>
            </div>
        </div>
    </div>

    <!-- User Submissions Section -->
    <section id="my-submissions" class="py-16 px-4 hidden">
        <div class="container mx-auto">
            <h2 class="text-3xl font-bold mb-8 text-center">Мои заявки</h2>
            
            <div class="grid grid-cols-1 md:grid-cols-2 gap-6" id="submissions-list">
                <!-- Submissions will be loaded here -->
            </div>
        </div>
    </section>

    <!-- Footer -->
    <footer class="bg-black bg-opacity-80 py-8 px-4">
        <div class="container mx-auto text-center">
            <p class="text-gray-400">Организатор: <span class="text-purple-400">FrunyaShow</span></p>
            <p class="text-gray-500 text-sm mt-2">© 2023 Clip of The Year. Все права защищены.</p>
        </div>
    </footer>

    <script>
        // Initialize animations and icons
        document.addEventListener('DOMContentLoaded', function() {
            AOS.init({
                duration: 800,
                easing: 'ease-in-out',
                once: true
            });
            
            feather.replace();
            
            // Vanta.js background
            VANTA.GLOBE({
                el: "#vanta-bg",
                mouseControls: true,
                touchControls: true,
                gyroControls: false,
                minHeight: 200.00,
                minWidth: 200.00,
                scale: 1.00,
                scaleMobile: 1.00,
                color: 0x7e22ce,
                backgroundColor: 0x111827,
                size: 0.8
            });
            
            // Modal handling
            const modal = document.getElementById('submission-modal');
            const closeModalBtn = document.getElementById('close-modal');
            const nominationSelectBtns = document.querySelectorAll('.nomination-select');
            const clipUrlInput = document.getElementById('clip-url');
            const clipPreviewContainer = document.getElementById('clip-preview-container');
            const clipPreview = document.getElementById('clip-preview');
            const submitClipBtn = document.getElementById('submit-clip-btn');
            const mySubmissionsSection = document.getElementById('my-submissions');
            
            // Mock user data (replace with actual Twitch auth)
            let currentUser = null;
            let userSubmissions = [];
            
            // Twitch login button
            document.getElementById('twitch-login').addEventListener('click', function() {
                // In a real implementation, this would redirect to Twitch OAuth
                mockTwitchLogin();
            });
            
            // Logout button
            document.getElementById('logout-btn').addEventListener('click', function() {
                currentUser = null;
                document.getElementById('twitch-login').classList.remove('hidden');
                document.getElementById('user-profile').classList.add('hidden');
                submitClipBtn.classList.add('hidden');
                mySubmissionsSection.classList.add('hidden');
            });
            
            // Nomination selection
            nominationSelectBtns.forEach(btn => {
                btn.addEventListener('click', function() {
                    const nominationId = this.getAttribute('data-nomination');
                    const nominationTitle = this.closest('.nomination-card').querySelector('h3').textContent;
                    
                    document.getElementById('nomination-id').value = nominationId;
                    document.getElementById('modal-title').textContent = `Подача клипа: ${nominationTitle}`;
                    
                    // Reset form
                    document.getElementById('clip-form').reset();
                    clipPreviewContainer.classList.add('hidden');
                    
                    // Show modal
                    modal.classList.remove('hidden');
                    
                    // Check eligibility if user is logged in
                    if (currentUser) {
                        document.getElementById('eligibility-message').classList.add('hidden');
                    }
                });
            });
            
            // Close modal
            closeModalBtn.addEventListener('click', function() {
                modal.classList.add('hidden');
            });
            
            // Clip URL input change
            clipUrlInput.addEventListener('change', function() {
                const url = this.value.trim();
                if (url.includes('clips.twitch.tv')) {
                    const clipId = url.split('/').pop();
                    const embedUrl = `https://clips.twitch.tv/embed?clip=${clipId}&parent=${window.location.hostname}`;
                    clipPreview.src = embedUrl;
                    clipPreviewContainer.classList.remove('hidden');
                } else {
                    clipPreviewContainer.classList.add('hidden');
                }
            });
            
            // Form submission
            document.getElementById('clip-form').addEventListener('submit', function(e) {
                e.preventDefault();
                
                if (!currentUser) {
                    alert('Пожалуйста, войдите через Twitch чтобы подать клип');
                    return;
                }
                
                if (currentUser.followers < 50) {
                    document.getElementById('eligibility-message').classList.remove('hidden');
                    return;
                }
                
                const submission = {
                    id: Date.now(),
                    nominationId: document.getElementById('nomination-id').value,
                    nominationTitle: document.getElementById('modal-title').textContent.replace('Подача клипа: ', ''),
                    clipUrl: document.getElementById('clip-url').value,
                    description: document.getElementById('clip-description').value,
                    date: new Date().toLocaleDateString(),
                    status: 'На рассмотрении'
                };
                
                // In a real implementation, this would save to Google Sheets
                userSubmissions.push(submission);
                updateSubmissionsList();
                
                // Close modal and show success message
                modal.classList.add('hidden');
                alert('Ваш клип успешно отправлен!');
            });
            
            // Submit clip button
            submitClipBtn.addEventListener('click', function() {
                mySubmissionsSection.classList.remove('hidden');
                mySubmissionsSection.scrollIntoView({ behavior: 'smooth' });
            });
            
            // Mock Twitch login function
            function mockTwitchLogin() {
                currentUser = {
                    id: '123456',
                    name: 'TestStreamer',
                    displayName: 'Test Streamer',
                    avatar: 'https://static-cdn.jtvnw.net/jtv_user_pictures/asmongold-profile_image-f7ddcbd0332f5d28-300x300.png',
                    followers: 75 // Change to <50 to test eligibility
                };
                
                document.getElementById('twitch-login').classList.add('hidden');
                document.getElementById('user-profile').classList.remove('hidden');
                document.getElementById('user-avatar').src = currentUser.avatar;
                document.getElementById('username').textContent = currentUser.displayName;
                
                submitClipBtn.classList.remove('hidden');
                
                // Load user submissions
                if (currentUser.followers >= 50) {
                    // In a real implementation, this would fetch from Google Sheets
                    userSubmissions = [
                        {
                            id: 1,
                            nominationId: '2',
                            nominationTitle: '"Брошу стримы и пойду в киберспорт"',
                            clipUrl: 'https://clips.twitch.tv/InventiveSuspiciousTrufflePogChamp',
                            description: 'Сделал 360 ноускоуп в CS:GO',
                            date: '01.11.2023',
                            status: 'На рассмотрении'
                        }
                    ];
                    updateSubmissionsList();
                }
            }
            
            // Update submissions list
            function updateSubmissionsList() {
                const submissionsList = document.getElementById('submissions-list');
                submissionsList.innerHTML = '';
                
                if (userSubmissions.length === 0) {
                    submissionsList.innerHTML = '<p class="text-gray-400 col-span-2 text-center">У вас пока нет отправленных клипов</p>';
                    return;
                }
                
                userSubmissions.forEach(sub => {
                    const submissionElement = document.createElement('div');
                    submissionElement.className = 'bg-gray-800 rounded-xl p-6';
                    submissionElement.innerHTML = `
                        <div class="flex justify-between items-start mb-4">
                            <h3 class="text-xl font-bold">${sub.nominationTitle}</h3>
                            <span class="text-sm px-2 py-1 rounded ${sub.status === 'На рассмотрении' ? 'bg-yellow-900 text-yellow-200' : 'bg-green-900 text-green-200'}">${sub.status}</span>
                        </div>
                        <p class="text-gray-300 mb-4">${sub.description}</p>
                        <div class="flex justify-between items-center text-sm text-gray-400">
                            <span>${sub.date}</span>
                            <a href="${sub.clipUrl}" target="_blank" class="text-purple-400 hover:text-purple-300 flex items-center">
                                <i data-feather="external-link" class="w-4 h-4 mr-1"></i>
                                Посмотреть клип
                            </a>
                        </div>
                    `;
                    submissionsList.appendChild(submissionElement);
                });
                
                feather.replace();
            }
        });
    </script>
</body>
</html>