File size: 28,293 Bytes
b017833
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Aviator Predictor Pro</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        .blur-effect {
            filter: blur(5px);
            transition: filter 0.3s ease;
        }
        .blur-effect:hover {
            filter: blur(0);
        }
        .gradient-bg {
            background: linear-gradient(135deg, #1e3a8a 0%, #0f172a 100%);
        }
        .prediction-card {
            box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2), 0 4px 6px -2px rgba(0, 0, 0, 0.1);
        }
        .signal-indicator {
            animation: pulse 2s infinite;
        }
        @keyframes pulse {
            0% { opacity: 1; }
            50% { opacity: 0.5; }
            100% { opacity: 1; }
        }
    </style>
</head>
<body class="bg-gray-100 font-sans">
    <!-- Auth Modal -->
    <div id="authModal" class="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50 hidden">
        <div class="bg-white rounded-lg p-6 w-full max-w-md">
            <div class="flex justify-between items-center mb-4">
                <h3 class="text-xl font-bold text-gray-800">Welcome to Aviator Predictor</h3>
                <button onclick="toggleAuthModal()" class="text-gray-500 hover:text-gray-700">
                    <i class="fas fa-times"></i>
                </button>
            </div>
            <div id="authTabs" class="flex border-b mb-4">
                <button id="loginTab" class="px-4 py-2 font-medium text-blue-600 border-b-2 border-blue-600">Login</button>
                <button id="registerTab" class="px-4 py-2 font-medium text-gray-500">Register</button>
            </div>
            <div id="loginForm">
                <div class="mb-4">
                    <label class="block text-gray-700 mb-2" for="loginEmail">Email</label>
                    <input type="email" id="loginEmail" class="w-full px-3 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500">
                </div>
                <div class="mb-4">
                    <label class="block text-gray-700 mb-2" for="loginPassword">Password</label>
                    <input type="password" id="loginPassword" class="w-full px-3 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500">
                </div>
                <button onclick="login()" class="w-full bg-blue-600 text-white py-2 rounded-lg hover:bg-blue-700 transition">Login</button>
                <p class="text-center mt-4 text-gray-600">Don't have an account? <a href="#" onclick="switchToRegister()" class="text-blue-600">Register</a></p>
            </div>
            <div id="registerForm" class="hidden">
                <div class="mb-4">
                    <label class="block text-gray-700 mb-2" for="registerEmail">Email</label>
                    <input type="email" id="registerEmail" class="w-full px-3 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500">
                </div>
                <div class="mb-4">
                    <label class="block text-gray-700 mb-2" for="registerPassword">Password</label>
                    <input type="password" id="registerPassword" class="w-full px-3 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500">
                </div>
                <div class="mb-4">
                    <label class="block text-gray-700 mb-2" for="confirmPassword">Confirm Password</label>
                    <input type="password" id="confirmPassword" class="w-full px-3 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500">
                </div>
                <button onclick="register()" class="w-full bg-blue-600 text-white py-2 rounded-lg hover:bg-blue-700 transition">Register</button>
                <p class="text-center mt-4 text-gray-600">Already have an account? <a href="#" onclick="switchToLogin()" class="text-blue-600">Login</a></p>
            </div>
        </div>
    </div>

    <!-- Subscription Modal -->
    <div id="subscriptionModal" class="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50 hidden">
        <div class="bg-white rounded-lg p-6 w-full max-w-md">
            <div class="flex justify-between items-center mb-4">
                <h3 class="text-xl font-bold text-gray-800">Upgrade to Premium</h3>
                <button onclick="toggleSubscriptionModal()" class="text-gray-500 hover:text-gray-700">
                    <i class="fas fa-times"></i>
                </button>
            </div>
            <div class="mb-6">
                <p class="text-gray-700 mb-4">Unlock full access to real-time predictions with 90%+ accuracy</p>
                <div class="bg-blue-50 p-4 rounded-lg">
                    <div class="flex items-center mb-2">
                        <i class="fas fa-check text-green-500 mr-2"></i>
                        <span>Real-time crash point predictions</span>
                    </div>
                    <div class="flex items-center mb-2">
                        <i class="fas fa-check text-green-500 mr-2"></i>
                        <span>AI-powered pattern recognition</span>
                    </div>
                    <div class="flex items-center mb-2">
                        <i class="fas fa-check text-green-500 mr-2"></i>
                        <span>Historical data analysis</span>
                    </div>
                    <div class="flex items-center">
                        <i class="fas fa-check text-green-500 mr-2"></i>
                        <span>High confidence betting suggestions</span>
                    </div>
                </div>
            </div>
            <div class="mb-6">
                <h4 class="font-medium text-gray-800 mb-2">Choose Payment Method</h4>
                <div class="grid grid-cols-2 gap-2">
                    <button onclick="selectPayment('momo')" class="border rounded-lg p-3 flex items-center justify-center hover:bg-gray-50">
                        <i class="fas fa-mobile-alt text-purple-600 mr-2"></i>
                        <span>Mobile Money</span>
                    </button>
                    <button onclick="selectPayment('airtel')" class="border rounded-lg p-3 flex items-center justify-center hover:bg-gray-50">
                        <i class="fas fa-sim-card text-blue-600 mr-2"></i>
                        <span>Airtel Money</span>
                    </button>
                </div>
            </div>
            <div class="mb-6">
                <h4 class="font-medium text-gray-800 mb-2">Select Plan</h4>
                <div class="grid grid-cols-3 gap-2">
                    <button onclick="selectPlan('daily')" class="border rounded-lg p-3 hover:bg-blue-50 hover:border-blue-200">
                        <div class="font-medium">Daily</div>
                        <div class="text-sm text-gray-600">$2.99</div>
                    </button>
                    <button onclick="selectPlan('weekly')" class="border rounded-lg p-3 hover:bg-blue-50 hover:border-blue-200">
                        <div class="font-medium">Weekly</div>
                        <div class="text-sm text-gray-600">$9.99</div>
                    </button>
                    <button onclick="selectPlan('monthly')" class="border rounded-lg p-3 bg-blue-50 border-blue-200">
                        <div class="font-medium">Monthly</div>
                        <div class="text-sm text-gray-600">$24.99</div>
                    </button>
                </div>
            </div>
            <button onclick="processPayment()" class="w-full bg-blue-600 text-white py-2 rounded-lg hover:bg-blue-700 transition">Subscribe Now</button>
        </div>
    </div>

    <!-- Main App -->
    <div class="min-h-screen flex flex-col">
        <!-- Header -->
        <header class="gradient-bg text-white p-4 shadow-md">
            <div class="container mx-auto flex justify-between items-center">
                <div class="flex items-center">
                    <i class="fas fa-rocket text-xl mr-2"></i>
                    <h1 class="text-xl font-bold">Aviator Predictor Pro</h1>
                </div>
                <div class="flex items-center space-x-4">
                    <button id="authButton" onclick="toggleAuthModal()" class="px-4 py-2 bg-white text-blue-600 rounded-lg font-medium hover:bg-gray-100 transition">Login</button>
                    <button id="userMenuButton" class="hidden relative">
                        <div class="w-8 h-8 rounded-full bg-blue-500 flex items-center justify-center text-white font-medium">U</div>
                    </button>
                </div>
            </div>
        </header>

        <!-- Main Content -->
        <main class="flex-grow container mx-auto p-4">
            <!-- Signal Status -->
            <div class="bg-white rounded-lg shadow-md p-4 mb-4">
                <div class="flex items-center justify-between">
                    <div class="flex items-center">
                        <div class="w-3 h-3 rounded-full bg-green-500 mr-2 signal-indicator"></div>
                        <span class="font-medium">Signal Status: <span class="text-green-600">Live</span></span>
                    </div>
                    <div class="text-gray-600">
                        <i class="fas fa-sync-alt mr-1"></i>
                        <span>Updated: <span id="lastUpdated">Just now</span></span>
                    </div>
                </div>
            </div>

            <!-- Prediction Card -->
            <div class="bg-white rounded-lg shadow-md p-4 mb-4 prediction-card">
                <div class="flex justify-between items-center mb-2">
                    <h2 class="text-lg font-bold text-gray-800">Next Prediction</h2>
                    <div class="flex items-center">
                        <i class="fas fa-bolt text-yellow-500 mr-1"></i>
                        <span class="text-sm font-medium">AI-Powered</span>
                    </div>
                </div>
                
                <div id="premiumPrediction" class="text-center py-6">
                    <div class="text-4xl font-bold text-blue-600 mb-2" id="predictionValue">2.47x</div>
                    <div class="flex items-center justify-center">
                        <div class="w-full bg-gray-200 rounded-full h-2.5 mr-2">
                            <div class="bg-green-600 h-2.5 rounded-full" style="width: 92%"></div>
                        </div>
                        <span class="text-sm font-medium text-gray-700">92%</span>
                    </div>
                    <p class="text-gray-600 mt-2">Next round likely to crash at <span class="font-medium">2.47x</span></p>
                </div>
                
                <div id="freePrediction" class="text-center py-6 blur-effect relative hidden">
                    <div class="text-4xl font-bold text-blue-600 mb-2">2.47x</div>
                    <div class="flex items-center justify-center">
                        <div class="w-full bg-gray-200 rounded-full h-2.5 mr-2">
                            <div class="bg-green-600 h-2.5 rounded-full" style="width: 92%"></div>
                        </div>
                        <span class="text-sm font-medium text-gray-700">92%</span>
                    </div>
                    <p class="text-gray-600 mt-2">Next round likely to crash at <span class="font-medium">2.47x</span></p>
                    <div class="absolute inset-0 flex items-center justify-center">
                        <button onclick="toggleSubscriptionModal()" class="px-4 py-2 bg-blue-600 text-white rounded-lg font-medium hover:bg-blue-700 transition">
                            <i class="fas fa-lock mr-1"></i> Upgrade to See Prediction
                        </button>
                    </div>
                </div>
                
                <div class="mt-4 p-3 bg-blue-50 rounded-lg">
                    <div class="flex items-start">
                        <i class="fas fa-lightbulb text-yellow-500 mt-1 mr-2"></i>
                        <div>
                            <p class="font-medium text-gray-800">Betting Suggestion</p>
                            <p class="text-gray-600">Safe to cash out below 2.0x in next 3 rounds</p>
                        </div>
                    </div>
                </div>
            </div>

            <!-- Countdown and Stats -->
            <div class="grid grid-cols-2 gap-4 mb-4">
                <div class="bg-white rounded-lg shadow-md p-4">
                    <h3 class="text-sm font-medium text-gray-500 mb-1">Next Round In</h3>
                    <div class="text-2xl font-bold text-blue-600" id="countdown">00:12</div>
                </div>
                <div class="bg-white rounded-lg shadow-md p-4">
                    <h3 class="text-sm font-medium text-gray-500 mb-1">Last Crash Point</h3>
                    <div class="text-2xl font-bold text-red-600">1.24x</div>
                </div>
            </div>

            <!-- Chart -->
            <div class="bg-white rounded-lg shadow-md p-4 mb-4">
                <div class="flex justify-between items-center mb-4">
                    <h2 class="text-lg font-bold text-gray-800">Recent Rounds</h2>
                    <div class="flex space-x-2">
                        <button class="px-2 py-1 text-xs bg-gray-100 rounded hover:bg-gray-200">10</button>
                        <button class="px-2 py-1 text-xs bg-blue-100 text-blue-600 rounded">20</button>
                        <button class="px-2 py-1 text-xs bg-gray-100 rounded hover:bg-gray-200">50</button>
                    </div>
                </div>
                <div class="h-64">
                    <canvas id="crashChart"></canvas>
                </div>
            </div>

            <!-- History -->
            <div class="bg-white rounded-lg shadow-md p-4">
                <h2 class="text-lg font-bold text-gray-800 mb-4">Prediction History</h2>
                <div class="overflow-x-auto">
                    <table class="min-w-full divide-y divide-gray-200">
                        <thead class="bg-gray-50">
                            <tr>
                                <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase">Round</th>
                                <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase">Prediction</th>
                                <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase">Actual</th>
                                <th class="px-4 py-2 text-left text-xs font-medium text-gray-500 uppercase">Status</th>
                            </tr>
                        </thead>
                        <tbody class="bg-white divide-y divide-gray-200">
                            <tr>
                                <td class="px-4 py-2 whitespace-nowrap text-sm font-medium text-gray-900">#4872</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">2.47x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">2.53x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600 font-medium">Accurate</td>
                            </tr>
                            <tr>
                                <td class="px-4 py-2 whitespace-nowrap text-sm font-medium text-gray-900">#4871</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">1.87x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">1.24x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-red-600 font-medium">Missed</td>
                            </tr>
                            <tr>
                                <td class="px-4 py-2 whitespace-nowrap text-sm font-medium text-gray-900">#4870</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">3.12x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">3.05x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600 font-medium">Accurate</td>
                            </tr>
                            <tr>
                                <td class="px-4 py-2 whitespace-nowrap text-sm font-medium text-gray-900">#4869</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">1.52x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">1.55x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600 font-medium">Accurate</td>
                            </tr>
                            <tr>
                                <td class="px-4 py-2 whitespace-nowrap text-sm font-medium text-gray-900">#4868</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">2.01x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-gray-500">2.01x</td>
                                <td class="px-4 py-2 whitespace-nowrap text-sm text-green-600 font-medium">Perfect</td>
                            </tr>
                        </tbody>
                    </table>
                </div>
            </div>
        </main>

        <!-- Footer -->
        <footer class="bg-gray-800 text-white p-4">
            <div class="container mx-auto text-center">
                <p class="text-sm">© 2023 Aviator Predictor Pro. All rights reserved.</p>
                <div class="flex justify-center space-x-4 mt-2">
                    <a href="#" class="text-gray-300 hover:text-white"><i class="fab fa-facebook"></i></a>
                    <a href="#" class="text-gray-300 hover:text-white"><i class="fab fa-twitter"></i></a>
                    <a href="#" class="text-gray-300 hover:text-white"><i class="fab fa-telegram"></i></a>
                </div>
            </div>
        </footer>
    </div>

    <script>
        // Simulate user authentication state
        let isLoggedIn = false;
        let isPremium = false;
        let selectedPaymentMethod = null;
        let selectedPlan = 'monthly';
        
        // Initialize Chart
        const ctx = document.getElementById('crashChart').getContext('2d');
        const crashChart = new Chart(ctx, {
            type: 'line',
            data: {
                labels: Array.from({length: 20}, (_, i) => `#${4872 - i}`).reverse(),
                datasets: [{
                    label: 'Crash Points',
                    data: [1.24, 2.53, 1.87, 3.12, 1.52, 2.01, 1.67, 2.89, 1.33, 2.45, 1.76, 2.12, 1.98, 3.45, 1.22, 2.67, 1.54, 2.33, 1.89, 2.76],
                    borderColor: 'rgb(59, 130, 246)',
                    backgroundColor: 'rgba(59, 130, 246, 0.1)',
                    tension: 0.3,
                    fill: true,
                    pointBackgroundColor: function(context) {
                        const index = context.dataIndex;
                        const value = context.dataset.data[index];
                        return value > 2.5 ? 'rgb(239, 68, 68)' : 'rgb(59, 130, 246)';
                    }
                }]
            },
            options: {
                responsive: true,
                maintainAspectRatio: false,
                plugins: {
                    legend: {
                        display: false
                    },
                    tooltip: {
                        callbacks: {
                            label: function(context) {
                                return `Crash: ${context.parsed.y}x`;
                            }
                        }
                    }
                },
                scales: {
                    y: {
                        beginAtZero: false,
                        min: 1.0,
                        ticks: {
                            callback: function(value) {
                                return value + 'x';
                            }
                        }
                    }
                }
            }
        });
        
        // Countdown timer
        let seconds = 12;
        const countdownElement = document.getElementById('countdown');
        
        function updateCountdown() {
            seconds--;
            if (seconds < 0) {
                seconds = 30;
                // Simulate new prediction
                document.getElementById('lastUpdated').textContent = 'Just now';
                // Update chart with new data point
                const newData = [...crashChart.data.datasets[0].data];
                newData.shift();
                newData.push((Math.random() * 2 + 1).toFixed(2));
                crashChart.data.datasets[0].data = newData;
                crashChart.update();
                
                // Update prediction value
                const prediction = (Math.random() * 2 + 1).toFixed(2);
                document.getElementById('predictionValue').textContent = prediction + 'x';
            }
            const mins = Math.floor(seconds / 60);
            const secs = seconds % 60;
            countdownElement.textContent = `${mins.toString().padStart(2, '0')}:${secs.toString().padStart(2, '0')}`;
        }
        
        setInterval(updateCountdown, 1000);
        
        // Auth Modal Functions
        function toggleAuthModal() {
            document.getElementById('authModal').classList.toggle('hidden');
        }
        
        function switchToRegister() {
            document.getElementById('loginForm').classList.add('hidden');
            document.getElementById('registerForm').classList.remove('hidden');
            document.getElementById('loginTab').classList.remove('border-blue-600', 'text-blue-600');
            document.getElementById('loginTab').classList.add('text-gray-500');
            document.getElementById('registerTab').classList.add('border-blue-600', 'text-blue-600');
            document.getElementById('registerTab').classList.remove('text-gray-500');
        }
        
        function switchToLogin() {
            document.getElementById('registerForm').classList.add('hidden');
            document.getElementById('loginForm').classList.remove('hidden');
            document.getElementById('registerTab').classList.remove('border-blue-600', 'text-blue-600');
            document.getElementById('registerTab').classList.add('text-gray-500');
            document.getElementById('loginTab').classList.add('border-blue-600', 'text-blue-600');
            document.getElementById('loginTab').classList.remove('text-gray-500');
        }
        
        function login() {
            const email = document.getElementById('loginEmail').value;
            const password = document.getElementById('loginPassword').value;
            
            if (email && password) {
                // Simulate successful login
                isLoggedIn = true;
                document.getElementById('authButton').classList.add('hidden');
                document.getElementById('userMenuButton').classList.remove('hidden');
                toggleAuthModal();
                
                // For demo purposes, show premium features if email contains "premium"
                isPremium = email.includes('premium');
                updatePremiumUI();
            } else {
                alert('Please enter both email and password');
            }
        }
        
        function register() {
            const email = document.getElementById('registerEmail').value;
            const password = document.getElementById('registerPassword').value;
            const confirmPassword = document.getElementById('confirmPassword').value;
            
            if (email && password && confirmPassword) {
                if (password !== confirmPassword) {
                    alert('Passwords do not match');
                    return;
                }
                
                // Simulate successful registration
                isLoggedIn = true;
                document.getElementById('authButton').classList.add('hidden');
                document.getElementById('userMenuButton').classList.remove('hidden');
                toggleAuthModal();
                
                // New users start as free by default
                isPremium = false;
                updatePremiumUI();
            } else {
                alert('Please fill in all fields');
            }
        }
        
        // Subscription Modal Functions
        function toggleSubscriptionModal() {
            document.getElementById('subscriptionModal').classList.toggle('hidden');
        }
        
        function selectPayment(method) {
            selectedPaymentMethod = method;
            // Update UI to show selected payment method
            const buttons = document.querySelectorAll('#subscriptionModal [onclick^="selectPayment"]');
            buttons.forEach(btn => {
                btn.classList.remove('border-blue-300', 'bg-blue-50');
            });
            event.target.classList.add('border-blue-300', 'bg-blue-50');
        }
        
        function selectPlan(plan) {
            selectedPlan = plan;
            // Update UI to show selected plan
            const buttons = document.querySelectorAll('#subscriptionModal [onclick^="selectPlan"]');
            buttons.forEach(btn => {
                btn.classList.remove('border-blue-300', 'bg-blue-50');
            });
            event.target.classList.add('border-blue-300', 'bg-blue-50');
        }
        
        function processPayment() {
            if (!selectedPaymentMethod) {
                alert('Please select a payment method');
                return;
            }
            
            // Simulate successful payment
            isPremium = true;
            toggleSubscriptionModal();
            updatePremiumUI();
            
            // Show success message
            alert(`Payment successful via ${selectedPaymentMethod === 'momo' ? 'Mobile Money' : 'Airtel Money'}! You now have premium access.`);
        }
        
        function updatePremiumUI() {
            if (isPremium) {
                document.getElementById('premiumPrediction').classList.remove('hidden');
                document.getElementById('freePrediction').classList.add('hidden');
            } else {
                document.getElementById('premiumPrediction').classList.add('hidden');
                document.getElementById('freePrediction').classList.remove('hidden');
            }
        }
        
        // Initialize tabs
        document.getElementById('loginTab').addEventListener('click', switchToLogin);
        document.getElementById('registerTab').addEventListener('click', switchToRegister);
        
        // For demo purposes, show auth modal on load
        // In a real app, you would check if user is already logged in
        // setTimeout(toggleAuthModal, 1000);
    </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=joeljossaih/ai-powered-aviator-predictor" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>