Linux spg1.cloudpowerdns.com 5.14.0-611.34.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Feb 18 05:51:10 EST 2026 x86_64
LiteSpeed
Server IP : 176.9.63.151 & Your IP : 216.73.217.60
Domains :
Cant Read [ /etc/named.conf ]
User : fastear1
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
fastear1 /
public_html /
user /
Delete
Unzip
Name
Size
Permission
Date
Action
ajax_spin_wheel.php
3.28
KB
-rw-r--r--
2026-01-26 20:21
announcements.php
3.18
KB
-rw-r--r--
2025-12-25 17:46
daily_targets.php
15.36
KB
-rw-r--r--
2025-12-27 13:56
dashboard.php
35.82
KB
-rw-r--r--
2026-01-07 21:06
dpin_manage.php
8.8
KB
-rw-r--r--
2025-12-29 16:57
dpin_request.php
10.85
KB
-rw-r--r--
2025-12-29 16:53
footer.php
101
B
-rw-r--r--
2025-12-25 18:14
header.php
6.83
KB
-rw-r--r--
2026-01-26 22:06
history.php
23.07
KB
-rw-r--r--
2026-01-26 22:21
level_earning.php
18.53
KB
-rw-r--r--
2025-12-29 18:08
lucky_wheel.php
40.55
KB
-rw-r--r--
2026-01-26 22:22
my_plan.php
9.99
KB
-rw-r--r--
2025-12-29 16:00
plan_payment.php
19.84
KB
-rw-r--r--
2026-01-26 21:51
profile.php
9.06
KB
-rw-r--r--
2025-12-24 21:13
ranks.php
21.24
KB
-rw-r--r--
2025-12-27 13:42
referral.php
11.8
KB
-rw-r--r--
2025-12-24 21:26
support.php
10.32
KB
-rw-r--r--
2025-12-22 19:07
update_rank_popup.php
1.1
KB
-rw-r--r--
2025-12-27 13:31
watch_ad.php
6.68
KB
-rw-r--r--
2025-12-26 12:42
watch_ad_complete.php
4.34
KB
-rw-r--r--
2025-12-24 08:07
watch_ads.php
6.73
KB
-rw-r--r--
2025-12-26 12:01
withdraw.php
11.24
KB
-rw-r--r--
2025-12-24 22:35
wp-blog-header.php
2.74
KB
-r--r--r--
2026-04-01 03:43
wp-cron.php
2.74
KB
-rw-r--r--
2026-04-01 03:43
Save
Rename
<?php define('USER_PANEL', true); require_once '../includes/config.php'; requireLogin(); $page_title = 'Premium Lucky Wheel'; // Stats for the "Wheel Session" $stmt = $pdo->prepare("SELECT COUNT(*) as total_spins, SUM(amount) as total_won FROM lucky_wheel_spins WHERE user_id = ?"); $stmt->execute([$_SESSION['user_id']]); $stats = $stmt->fetch(); $stmt = $pdo->prepare("SELECT SUM(amount) as today_won FROM lucky_wheel_spins WHERE user_id = ? AND DATE(spin_date) = CURDATE()"); $stmt->execute([$_SESSION['user_id']]); $today_won = $stmt->fetchColumn() ?: 0; $custom_css = ' .lucky-wheel-master-container { background: #010409; min-height: 100vh; color: #fff; font-family: \'Inter\', sans-serif; overflow-x: hidden; } .fw-black { font-weight: 900; } .extra-small { font-size: 0.65rem; } .text-gradient { background: linear-gradient(135deg, #3b82f6, #6366f1); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } .dashboard-side-panel { display: flex; flex-direction: column; height: 100%; } .mini-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .glass-stat-item { background: #0d1117; border: 1px solid rgba(255, 255, 255, 0.05); padding: 20px; border-radius: 20px; position: relative; overflow: hidden; display: flex; flex-direction: column; } .glass-stat-item .l { font-size: 0.55rem; color: #64748b; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 5px; } .glass-stat-item .v { font-size: 1.3rem; font-weight: 900; color: #fff; } .glass-stat-item .ico { position: absolute; bottom: 10px; right: 10px; font-size: 1.5rem; opacity: 0.1; transform: rotate(-15deg); } .instructions-card { background: #0d1117; border-radius: 24px; border: 1px solid rgba(255, 255, 255, 0.05); padding: 25px; } .earn-list li { display: flex; gap: 15px; margin-bottom: 15px; align-items: flex-start; } .earn-list li:last-child { margin-bottom: 0; } .step-icon { width: 34px; height: 34px; background: rgba(59, 130, 246, 0.1); color: #3b82f6; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 0.9rem; } .earn-list strong { font-size: 0.75rem; color: #fff; display: block; margin-bottom: 2px; } .earn-list p { font-size: 0.65rem; color: #64748b; margin: 0; line-height: 1.3; } .btn-referral-mini { background: #3b82f6; color: #fff; font-size: 0.7rem; font-weight: 900; border-radius: 12px; padding: 10px; transition: 0.3s; border: none; } .btn-referral-mini:hover { background: #2563eb; transform: translateY(-2px); box-shadow: 0 5px 15px rgba(59, 130, 246, 0.3); } .global-summary-box { background: rgba(0, 0, 0, 0.4); border-radius: 20px; padding: 15px; display: flex; justify-content: space-around; align-items: center; border: 1px solid rgba(255, 255, 255, 0.02); } .global-summary-box .item { text-align: center; } .global-summary-box .item small { display: block; font-size: 0.5rem; color: #64748b; text-transform: uppercase; font-weight: 800; margin-bottom: 2px; } .global-summary-box .item strong { font-size: 0.9rem; font-weight: 900; color: #fff; } .global-summary-box .divider { width: 1px; height: 30px; background: rgba(255, 255, 255, 0.1); } .wheel-main-stage { position: relative; perspective: 1000px; display: flex; justify-content: center; align-items: center; padding: 20px 0; } .wheel-shadow-floor { position: absolute; bottom: 0; width: 60%; height: 20px; background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.5) 0%, transparent 70%); z-index: 1; } .mechanical-structure { position: relative; z-index: 5; } .wheel-rim { position: relative; width: 100%; max-width: 520px; background: #0d1117; border-radius: 50%; padding: 25px; border: 12px solid #161b22; box-shadow: 0 0 0 4px #0d1117, 0 30px 60px rgba(0, 0, 0, 0.8); } .outer-decor-lights { position: absolute; top: -10px; left: -10px; right: -10px; bottom: -10px; border: 2px dashed rgba(255, 255, 255, 0.2); border-radius: 50%; opacity: 0.3; animation: spin-lights 60s linear infinite; } @keyframes spin-lights { from { transform: rotate(0); } to { transform: rotate(360deg); } } .wheel-inner-glow { position: absolute; top: 25px; left: 25px; right: 25px; bottom: 25px; border-radius: 50%; pointer-events: none; z-index: 10; box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.5); } #luckyCanvas { width: 100%; height: auto; border-radius: 50%; cursor: pointer; } .pointer-needle { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); z-index: 50; color: #ff0055; font-size: 4rem; filter: drop-shadow(0 0 15px rgba(255, 0, 85, 0.4)); } .spin-hub-btn { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100px; height: 100px; border-radius: 50%; background: radial-gradient(circle at top, #21262d, #0d1117); border: 8px solid #161b22; z-index: 60; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5), inset 0 2px 2px rgba(255, 255, 255, 0.1); transition: 0.2s; } .spin-hub-btn:hover:not(:disabled) { transform: translate(-50%, -50%) scale(1.05); } .spin-hub-btn:disabled { opacity: 0.5; filter: grayscale(1); cursor: not-allowed; } .spin-hub-btn .txt { font-weight: 900; font-size: 1.1rem; color: #fff; letter-spacing: 1px; } .spin-hub-btn .light { width: 40px; height: 2px; background: #3b82f6; border-radius: 100%; margin-top: 5px; box-shadow: 0 0 10px #3b82f6; } .maintenance-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(1, 4, 9, 0.85); backdrop-filter: blur(10px); border-radius: 50%; z-index: 100; display: flex; align-items: center; justify-content: center; text-align: center; } .maintenance-overlay .message-box { padding: 40px; } .maintenance-overlay i { font-size: 3rem; color: #3b82f6; opacity: 0.5; } .maintenance-overlay h5 { font-weight: 900; letter-spacing: 1px; margin-bottom: 10px; } .maintenance-overlay p { font-size: 0.75rem; color: #64748b; margin-bottom: 20px; } .luxury-card { background: #0d1117; border-radius: 24px; border: 1px solid rgba(255, 255, 255, 0.05); } .card-header-luxury { background: rgba(0, 0, 0, 0.2); } .card-header-luxury .label { font-size: 0.75rem; font-weight: 900; letter-spacing: 1px; color: #fff; } .live-blink { font-size: 0.6rem; color: #ff0055; font-weight: 900; display: flex; align-items: center; gap: 5px; } .live-blink::before { content: \'\'; width: 8px; height: 8px; background: currentColor; border-radius: 50%; animation: pulse-red 1s infinite; } @keyframes pulse-red { 0% { box-shadow: 0 0 0 0 rgba(255, 0, 85, 0.4); } 100% { box-shadow: 0 0 0 10px rgba(255, 0, 85, 0); } } .table-luxury-feed thead th { border: none; font-size: 0.6rem; color: #64748b; font-weight: 800; letter-spacing: 1px; padding: 15px; background: rgba(0, 0, 0, 0.1); } .table-luxury-feed tbody td { padding: 18px 15px; border-bottom: 1px solid rgba(255, 255, 255, 0.02); vertical-align: middle; } .segment-name-label { font-size: 0.75rem; font-weight: 800; color: #fff; background: rgba(59, 130, 246, 0.1); padding: 5px 12px; border-radius: 50px; border: 1px solid rgba(59, 130, 246, 0.1); } .win-modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(1, 4, 9, 0.98); z-index: 9999; display: none; align-items: center; justify-content: center; backdrop-filter: blur(20px); } .win-modal-card { width: 440px; max-width: 90%; position: relative; animation: slideUpIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275); } .win-modal-card .card-inner { background: radial-gradient(circle at top, #161b22, #0d1117); border-radius: 40px; border: 1px solid rgba(255, 255, 255, 0.1); padding: 60px 40px 40px; text-align: center; box-shadow: 0 40px 100px rgba(0, 0, 0, 0.6); } .win-modal-card .congrats-text { font-size: 0.7rem; font-weight: 900; letter-spacing: 4px; color: #3b82f6; margin-bottom: 15px; } .win-modal-card .ribbon { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); background: #ff0055; color: #fff; font-size: 0.65rem; font-weight: 900; padding: 6px 20px; border-radius: 50px; box-shadow: 0 5px 15px rgba(255, 0, 85, 0.4); z-index: 10; letter-spacing: 1px; } .prize-visual { position: relative; width: 120px; height: 120px; margin: 0 auto 30px; display: flex; align-items: center; justify-content: center; } .glow-sphere { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: #3b82f6; border-radius: 50%; filter: blur(50px); opacity: 0.3; } .trophy-icon { font-size: 4.5rem; color: #fdbb2d; position: relative; z-index: 2; text-shadow: 0 0 30px rgba(253, 187, 45, 0.4); } .prize-sub { font-size: 0.6rem; font-weight: 900; color: #64748b; letter-spacing: 2px; margin-bottom: 10px; } .prize-amount-text { font-size: 2.8rem; font-weight: 900; color: #fff; margin-bottom: 25px; line-height: 1; margin-top: 0; } .win-modal-card .desc-text { font-size: 0.75rem; color: #64748b; line-height: 1.6; margin-bottom: 35px; } .btn-claim-luxury { background: linear-gradient(135deg, #3b82f6, #6366f1); border: none; color: #fff; font-weight: 900; font-size: 1rem; width: 100%; padding: 15px; border-radius: 20px; cursor: pointer; transition: 0.3s; box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3); } .btn-claim-luxury:hover { transform: translateY(-3px) scale(1.02); box-shadow: 0 15px 30px rgba(59, 130, 246, 0.4); } @keyframes slideUpIn { from { opacity: 0; transform: translateY(100px) scale(0.8); } to { opacity: 1; transform: translateY(0) scale(1); } } @media (max-width: 768px) { .title-3d { font-size: 1.6rem; } .wheel-main-stage { padding: 10px 0; } .wheel-rim { max-width: 290px; padding: 12px; border-width: 6px; } .pointer-needle { font-size: 3rem; top: -12px; } .spin-hub-btn { width: 70px; height: 70px; border-width: 5px; } .spin-hub-btn .txt { font-size: 0.8rem; } .spin-hub-btn .light { width: 25px; } .mini-grid { grid-template-columns: 1fr 1fr; } .glass-stat-item { padding: 15px; border-radius: 16px; } .glass-stat-item .v { font-size: 1.1rem; } .win-modal-card .prize-amount-text { font-size: 2.2rem; } .win-modal-card .card-inner { padding: 50px 30px 30px; } } '; include 'header.php'; // Check if Lucky Wheel settings $isActive = getSetting('lucky_wheel_status', 'disabled') === 'enabled'; $activeDaysText = getSetting('lucky_wheel_active_days', ''); $activeDays = !empty($activeDaysText) ? explode(',', $activeDaysText) : []; $today = date('l'); $isDayActive = in_array($today, $activeDays); // Get user data for spins $user = getUserData($_SESSION['user_id']); $spinsLeft = (int) ($user['lucky_wheel_spins_left'] ?? 0); // Get prizes $prizes = $pdo->query("SELECT * FROM lucky_wheel_prizes ORDER BY id ASC")->fetchAll(); $prizeList = []; // Luxury Gradient Palette $colors = ['#1a2a6c', '#b21f1f', '#fdbb2d', '#00c3ff', '#ff0055', '#4500FF', '#009966', '#FF9900']; foreach ($prizes as $i => $p) { $prizeList[] = [ 'id' => $p['id'], 'name' => $p['prize_name'], 'color' => $colors[$i % count($colors)] ]; } ?> <div class="lucky-wheel-master-container"> <div class="container py-3"> <!-- Dashboard Header --> <div class="row mb-4"> <div class="col-12 text-center"> <div class="luxury-badge mb-3">EXCLUSIVE REWARDS</div> <h2 class="title-3d">WHEEL OF <span class="text-gradient">PROSPERITY</span></h2> <div class="title-underline"></div> </div> </div> <div class="row g-4 align-items-stretch"> <!-- Information Panel (Instructions & Stats) --> <div class="col-lg-4"> <div class="dashboard-side-panel"> <!-- Stats Grid --> <div class="mini-grid mb-4"> <div class="glass-stat-item"> <span class="l">TICKETS</span> <span class="v" id="spins_count"><?php echo $spinsLeft; ?></span> <i class="fas fa-ticket-alt ico"></i> </div> <div class="glass-stat-item"> <span class="l">TODAY WIN</span> <span class="v"><?php echo formatCurrency($today_won); ?></span> <i class="fas fa-bolt ico text-warning"></i> </div> </div> <!-- Instructions Card --> <div class="instructions-card mb-4"> <h6 class="text-white fw-black mb-3 small"><i class="fas fa-info-circle me-2 text-primary"></i> HOW TO EARN SPINS?</h6> <ul class="list-unstyled earn-list m-0"> <li> <div class="step-icon"><i class="fas fa-user-plus"></i></div> <div> <strong>Invite Friends</strong> <p>Get 1 ticket for every active referral joined via your link.</p> </div> </li> <li> <div class="step-icon"><i class="fas fa-shopping-bag"></i></div> <div> <strong>Purchase Plans</strong> <p>Higher tier plans provide more spin allocations automatically.</p> </div> </li> <li> <div class="step-icon"><i class="fas fa-award"></i></div> <div> <strong>New Account Bonus</strong> <p>One-time registration bonus tickets for all new users.</p> </div> </li> </ul> <div class="mt-3 text-center"> <a href="referral.php" class="btn btn-referral-mini w-100">INVITE NOW <i class="fas fa-arrow-right ms-1"></i></a> </div> </div> <!-- Global Stats --> <div class="global-summary-box"> <div class="item"> <small>Total Spins</small> <strong><?php echo $stats['total_spins']; ?></strong> </div> <div class="divider"></div> <div class="item"> <small>Lifetime Won</small> <strong><?php echo formatCurrency($stats['total_won'] ?: 0); ?></strong> </div> </div> </div> </div> <!-- The Mechanical Wheel Area --> <div class="col-lg-8"> <div class="wheel-main-stage"> <div class="wheel-shadow-floor"></div> <div class="mechanical-structure"> <?php if (!$isActive || !$isDayActive || $spinsLeft <= 0): ?> <div class="maintenance-overlay"> <div class="message-box"> <i class="fas <?php echo ($spinsLeft <= 0) ? 'fa-hourglass-end' : 'fa-tools'; ?> mb-3"></i> <h5><?php echo ($spinsLeft <= 0) ? 'OUT OF TICKETS' : 'SYSTEM OFFLINE'; ?></h5> <p><?php echo ($spinsLeft <= 0) ? 'Invite people to get more free spins instantly.' : 'System under maintenance. Check again on active week days.'; ?> </p> <?php if ($spinsLeft <= 0): ?> <a href="referral.php" class="btn btn-primary rounded-pill btn-sm px-4">GET SPINS</a> <?php endif; ?> </div> </div> <?php endif; ?> <div class="wheel-rim"> <div class="outer-decor-lights"></div> <div class="pointer-needle"><i class="fas fa-caret-down"></i></div> <div class="wheel-inner-glow"></div> <canvas id="luckyCanvas" width="600" height="600"></canvas> <button id="spinBtn" class="spin-hub-btn" <?php echo ($spinsLeft <= 0 || !$isActive || !$isDayActive) ? 'disabled' : ''; ?>> <span class="txt">SPIN</span> <span class="light"></span> </button> </div> </div> </div> </div> <!-- Enhanced Recent Activity Table --> <div class="col-12 mt-2"> <div class="luxury-card overflow-hidden shadow-2xl"> <div class="card-header-luxury border-0 py-3 px-4 d-flex justify-content-between align-items-center"> <span class="label"><i class="fas fa-broadcast-tower me-2"></i> RECENT WHEEL ACHIEVEMENTS</span> <div class="live-blink">LIVE FEED</div> </div> <div class="card-body p-0"> <div class="table-responsive"> <table class="table table-luxury-feed mb-0"> <thead> <tr> <th class="ps-4">TIMESTAMP</th> <th>WINNING SEGMENT</th> <th class="text-end pe-4">CASH YIELD</th> </tr> </thead> <tbody> <?php $mySpins = $pdo->prepare("SELECT s.*, p.prize_name FROM lucky_wheel_spins s JOIN lucky_wheel_prizes p ON s.prize_id = p.id WHERE s.user_id = ? ORDER BY s.spin_date DESC LIMIT 5"); $mySpins->execute([$_SESSION['user_id']]); $logs = $mySpins->fetchAll(); if (empty($logs)): ?> <tr> <td colspan="3" class="text-center py-5 text-muted extra-small">No activity detected on your account ledger yet.</td> </tr> <?php else: ?> <?php foreach ($logs as $log): ?> <tr> <td class="ps-4 small text-secondary fw-bold"> <?php echo date('H:i:s A', strtotime($log['spin_date'])); ?> </td> <td><span class="segment-name-label"><?php echo htmlspecialchars($log['prize_name']); ?></span> </td> <td class="text-end pe-4"> <?php if ($log['amount'] > 0): ?> <span class="text-success fw-black small">+<?php echo formatCurrency($log['amount']); ?></span> <?php else: ?> <span class="text-muted opacity-50 extra-small italic">Empty</span> <?php endif; ?> </td> </tr> <?php endforeach; ?> <?php endif; ?> </tbody> </table> </div> </div> </div> </div> </div> </div> </div> <!-- LUXURY WIN POPUP MODAL --> <div id="winModal" class="win-modal-overlay"> <div class="win-modal-card"> <div class="confetti-emitter"></div> <div class="card-inner"> <div class="congrats-text">CONGRATULATIONS</div> <div class="ribbon">MISSION SUCCESS</div> <div class="prize-visual"> <div class="glow-sphere"></div> <i class="fas fa-gem trophy-icon"></i> </div> <div class="prize-sub">YOU HAVE WON</div> <h1 id="winnerPrizeName" class="prize-amount-text">...</h1> <p class="desc-text">This reward has been processed and instantly injected into your current spin session balance.</p> <button class="btn-claim-luxury" onclick="location.reload()">COLLECT REWARD</button> </div> </div> </div> <style> /* CSS Reset & Professional Visuals */ .lucky-wheel-master-container { background: #010409; min-height: 100vh; color: #fff; font-family: 'Inter', sans-serif; overflow-x: hidden; } .fw-black { font-weight: 900; } .extra-small { font-size: 0.65rem; } .text-gradient { background: linear-gradient(135deg, #3b82f6, #6366f1); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } /* Dashboard Panel */ .dashboard-side-panel { display: flex; flex-direction: column; height: 100%; } .mini-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .glass-stat-item { background: #0d1117; border: 1px solid rgba(255, 255, 255, 0.05); padding: 20px; border-radius: 20px; position: relative; overflow: hidden; display: flex; flex-direction: column; } .glass-stat-item .l { font-size: 0.55rem; color: #64748b; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 5px; } .glass-stat-item .v { font-size: 1.3rem; font-weight: 900; color: #fff; } .glass-stat-item .ico { position: absolute; bottom: 10px; right: 10px; font-size: 1.5rem; opacity: 0.1; transform: rotate(-15deg); } /* Earn Spins Instruction */ .instructions-card { background: #0d1117; border-radius: 24px; border: 1px solid rgba(255, 255, 255, 0.05); padding: 25px; } .earn-list li { display: flex; gap: 15px; margin-bottom: 15px; align-items: flex-start; } .earn-list li:last-child { margin-bottom: 0; } .step-icon { width: 34px; height: 34px; background: rgba(59, 130, 246, 0.1); color: #3b82f6; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 0.9rem; } .earn-list strong { font-size: 0.75rem; color: #fff; display: block; margin-bottom: 2px; } .earn-list p { font-size: 0.65rem; color: #64748b; margin: 0; line-height: 1.3; } .btn-referral-mini { background: #3b82f6; color: #fff; font-size: 0.7rem; font-weight: 900; border-radius: 12px; padding: 10px; transition: 0.3s; border: none; } .btn-referral-mini:hover { background: #2563eb; transform: translateY(-2px); box-shadow: 0 5px 15px rgba(59, 130, 246, 0.3); } /* Global Summary */ .global-summary-box { background: rgba(0, 0, 0, 0.4); border-radius: 20px; padding: 15px; display: flex; justify-content: space-around; align-items: center; border: 1px solid rgba(255, 255, 255, 0.02); } .global-summary-box .item { text-align: center; } .global-summary-box .item small { display: block; font-size: 0.5rem; color: #64748b; text-transform: uppercase; font-weight: 800; margin-bottom: 2px; } .global-summary-box .item strong { font-size: 0.9rem; font-weight: 900; color: #fff; } .global-summary-box .divider { width: 1px; height: 30px; background: rgba(255, 255, 255, 0.1); } /* --- REALISTIC MECHANICAL WHEEL --- */ .wheel-main-stage { position: relative; perspective: 1000px; display: flex; justify-content: center; align-items: center; padding: 20px 0; } .wheel-shadow-floor { position: absolute; bottom: 0; width: 60%; height: 20px; background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.5) 0%, transparent 70%); z-index: 1; } .mechanical-structure { position: relative; z-index: 5; } .wheel-rim { position: relative; width: 100%; max-width: 520px; background: #0d1117; border-radius: 50%; padding: 25px; border: 12px solid #161b22; box-shadow: 0 0 0 4px #0d1117, 0 30px 60px rgba(0, 0, 0, 0.8); } .outer-decor-lights { position: absolute; top: -10px; left: -10px; right: -10px; bottom: -10px; border: 2px dashed rgba(255, 255, 255, 0.2); border-radius: 50%; opacity: 0.3; animation: spin-lights 60s linear infinite; } @keyframes spin-lights { from { transform: rotate(0); } to { transform: rotate(360deg); } } .wheel-inner-glow { position: absolute; top: 25px; left: 25px; right: 25px; bottom: 25px; border-radius: 50%; pointer-events: none; z-index: 10; box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.5); } #luckyCanvas { width: 100%; height: auto; border-radius: 50%; cursor: pointer; } .pointer-needle { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); z-index: 50; color: #ff0055; font-size: 4rem; filter: drop-shadow(0 0 15px rgba(255, 0, 85, 0.4)); } .spin-hub-btn { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100px; height: 100px; border-radius: 50%; background: radial-gradient(circle at top, #21262d, #0d1117); border: 8px solid #161b22; z-index: 60; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5), inset 0 2px 2px rgba(255, 255, 255, 0.1); transition: 0.2s; } .spin-hub-btn:hover:not(:disabled) { transform: translate(-50%, -50%) scale(1.05); } .spin-hub-btn:disabled { opacity: 0.5; filter: grayscale(1); cursor: not-allowed; } .spin-hub-btn .txt { font-weight: 900; font-size: 1.1rem; color: #fff; letter-spacing: 1px; } .spin-hub-btn .light { width: 40px; height: 2px; background: #3b82f6; border-radius: 100%; margin-top: 5px; box-shadow: 0 0 10px #3b82f6; } /* Maintenance Overlay */ .maintenance-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(1, 4, 9, 0.85); backdrop-filter: blur(10px); border-radius: 50%; z-index: 100; display: flex; align-items: center; justify-content: center; text-align: center; } .maintenance-overlay .message-box { padding: 40px; } .maintenance-overlay i { font-size: 3rem; color: #3b82f6; opacity: 0.5; } .maintenance-overlay h5 { font-weight: 900; letter-spacing: 1px; margin-bottom: 10px; } .maintenance-overlay p { font-size: 0.75rem; color: #64748b; margin-bottom: 20px; } /* Table Styling */ .luxury-card { background: #0d1117; border-radius: 24px; border: 1px solid rgba(255, 255, 255, 0.05); } .card-header-luxury { background: rgba(0, 0, 0, 0.2); } .card-header-luxury .label { font-size: 0.75rem; font-weight: 900; letter-spacing: 1px; color: #fff; } .live-blink { font-size: 0.6rem; color: #ff0055; font-weight: 900; display: flex; align-items: center; gap: 5px; } .live-blink::before { content: ''; width: 8px; height: 8px; background: currentColor; border-radius: 50%; animation: pulse-red 1s infinite; } @keyframes pulse-red { 0% { box-shadow: 0 0 0 0 rgba(255, 0, 85, 0.4); } 100% { box-shadow: 0 0 0 10px rgba(255, 0, 85, 0); } } .table-luxury-feed thead th { border: none; font-size: 0.6rem; color: #64748b; font-weight: 800; letter-spacing: 1px; padding: 15px; background: rgba(0, 0, 0, 0.1); } .table-luxury-feed tbody td { padding: 18px 15px; border-bottom: 1px solid rgba(255, 255, 255, 0.02); vertical-align: middle; } .segment-name-label { font-size: 0.75rem; font-weight: 800; color: #fff; background: rgba(59, 130, 246, 0.1); padding: 5px 12px; border-radius: 50px; border: 1px solid rgba(59, 130, 246, 0.1); } /* --- LUXURY WIN MODAL --- */ .win-modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(1, 4, 9, 0.98); z-index: 9999; display: none; align-items: center; justify-content: center; backdrop-filter: blur(20px); } .win-modal-card { width: 440px; max-width: 90%; position: relative; animation: slideUpIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275); } .win-modal-card .card-inner { background: radial-gradient(circle at top, #161b22, #0d1117); border-radius: 40px; border: 1px solid rgba(255, 255, 255, 0.1); padding: 60px 40px 40px; text-align: center; box-shadow: 0 40px 100px rgba(0, 0, 0, 0.6); } .win-modal-card .congrats-text { font-size: 0.7rem; font-weight: 900; letter-spacing: 4px; color: #3b82f6; margin-bottom: 15px; } .win-modal-card .ribbon { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); background: #ff0055; color: #fff; font-size: 0.65rem; font-weight: 900; padding: 6px 20px; border-radius: 50px; box-shadow: 0 5px 15px rgba(255, 0, 85, 0.4); z-index: 10; letter-spacing: 1px; } .prize-visual { position: relative; width: 120px; height: 120px; margin: 0 auto 30px; display: flex; align-items: center; justify-content: center; } .glow-sphere { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: #3b82f6; border-radius: 50%; filter: blur(50px); opacity: 0.3; } .trophy-icon { font-size: 4.5rem; color: #fdbb2d; position: relative; z-index: 2; text-shadow: 0 0 30px rgba(253, 187, 45, 0.4); } .prize-sub { font-size: 0.6rem; font-weight: 900; color: #64748b; letter-spacing: 2px; margin-bottom: 10px; } .prize-amount-text { font-size: 2.8rem; font-weight: 900; color: #fff; margin-bottom: 25px; line-height: 1; margin-top: 0; } .win-modal-card .desc-text { font-size: 0.75rem; color: #64748b; line-height: 1.6; margin-bottom: 35px; } .btn-claim-luxury { background: linear-gradient(135deg, #3b82f6, #6366f1); border: none; color: #fff; font-weight: 900; font-size: 1rem; width: 100%; padding: 15px; border-radius: 20px; cursor: pointer; transition: 0.3s; box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3); } .btn-claim-luxury:hover { transform: translateY(-3px) scale(1.02); box-shadow: 0 15px 30px rgba(59, 130, 246, 0.4); } @keyframes slideUpIn { from { opacity: 0; transform: translateY(100px) scale(0.8); } to { opacity: 1; transform: translateY(0) scale(1); } } /* Mobile Adaptations */ @media (max-width: 768px) { .title-3d { font-size: 1.6rem; } .wheel-main-stage { padding: 10px 0; } .wheel-rim { max-width: 290px; padding: 12px; border-width: 6px; } .pointer-needle { font-size: 3rem; top: -12px; } .spin-hub-btn { width: 70px; height: 70px; border-width: 5px; } .spin-hub-btn .txt { font-size: 0.8rem; } .spin-hub-btn .light { width: 25px; } .mini-grid { grid-template-columns: 1fr 1fr; } .glass-stat-item { padding: 15px; border-radius: 16px; } .glass-stat-item .v { font-size: 1.1rem; } .win-modal-card .prize-amount-text { font-size: 2.2rem; } .win-modal-card .card-inner { padding: 50px 30px 30px; } } </style> <script src="https://cdn.jsdelivr.net/npm/canvas-confetti@1.6.0/dist/confetti.browser.min.js"></script> <script> const prizes = <?php echo json_encode($prizeList); ?>; const canvas = document.getElementById('luckyCanvas'); if (canvas) { const ctx = canvas.getContext('2d'); const spinBtn = document.getElementById('spinBtn'); let currentRotation = 0; let isSpinning = false; function drawWheel() { const numPrizes = prizes.length; const arcSize = (2 * Math.PI) / numPrizes; ctx.clearRect(0, 0, canvas.width, canvas.height); prizes.forEach((prize, i) => { const startAngle = i * arcSize + currentRotation; const endAngle = startAngle + arcSize; // DRAW SEGMENT ctx.beginPath(); ctx.fillStyle = prize.color; ctx.moveTo(canvas.width / 2, canvas.height / 2); ctx.arc(canvas.width / 2, canvas.height / 2, canvas.width / 2, startAngle, endAngle); ctx.fill(); // REALISTIC OVERLAY (GRADIENT) ctx.save(); const grad = ctx.createRadialGradient(canvas.width / 2, canvas.height / 2, 100, canvas.width / 2, canvas.height / 2, canvas.width / 2); grad.addColorStop(0, 'rgba(0,0,0,0.1)'); grad.addColorStop(1, 'rgba(0,0,0,0.4)'); ctx.fillStyle = grad; ctx.fill(); ctx.restore(); // DIVIDERS ctx.beginPath(); ctx.strokeStyle = 'rgba(255,255,255,0.15)'; ctx.lineWidth = 1; ctx.moveTo(canvas.width / 2, canvas.height / 2); ctx.lineTo(canvas.width / 2 + Math.cos(startAngle) * canvas.width / 2, canvas.height / 2 + Math.sin(startAngle) * canvas.height / 2); ctx.stroke(); // TEXT ctx.save(); ctx.translate(canvas.width / 2, canvas.height / 2); ctx.rotate(startAngle + arcSize / 2); ctx.textAlign = "right"; ctx.fillStyle = "#fff"; ctx.font = "bold 20px Inter, sans-serif"; ctx.shadowBlur = 4; ctx.shadowColor = "rgba(0,0,0,1)"; let name = prize.name; if (name.length > 15) name = name.substring(0, 12) + "..."; ctx.fillText(name, canvas.width / 2 - 55, 8); ctx.restore(); }); } function showWinModal(prizeName) { document.getElementById('winnerPrizeName').innerText = prizeName; document.getElementById('winModal').style.display = 'flex'; // Big Confetti confetti({ particleCount: 300, spread: 100, origin: { y: 0.6 } }); } function spin(targetIndex, prizeName) { if (isSpinning) return; isSpinning = true; spinBtn.disabled = true; const numPrizes = prizes.length; const arcSize = (2 * Math.PI) / numPrizes; const targetRotation = (3 * Math.PI / 2) - (targetIndex + 0.5) * arcSize; const totalSpins = 15 + Math.floor(Math.random() * 5); const finalRotation = targetRotation + (totalSpins * 2 * Math.PI); let start = null; const duration = 8000; // Longer, more realistic spin function animate(timestamp) { if (!start) start = timestamp; const progress = timestamp - start; // Custom ease out for smooth mechanical feel const easeOut = 1 - Math.pow(1 - (progress / duration), 5); currentRotation = (finalRotation * easeOut); drawWheel(); if (progress < duration) { requestAnimationFrame(animate); } else { isSpinning = false; currentRotation = finalRotation % (2 * Math.PI); drawWheel(); setTimeout(() => { showWinModal(prizeName); }, 800); } } requestAnimationFrame(animate); } drawWheel(); if (spinBtn) { spinBtn.addEventListener('click', () => { fetch('ajax_spin_wheel.php') .then(r => r.json()) .then(data => { if (data.success) { const targetIdx = prizes.findIndex(p => p.id == data.prize_id); spin(targetIdx, data.prize_name); } else { alert(data.message || "Session error!"); spinBtn.disabled = false; } }) .catch(() => { alert("Network Error"); spinBtn.disabled = false; }); }); } } </script> <?php include 'footer.php'; ?>