From ece35e64c54edc55205b9d298704714f733021ef Mon Sep 17 00:00:00 2001 From: Michelle Aquilera Date: Mon, 24 Nov 2025 13:38:21 +0700 Subject: [PATCH 1/3] Leaaderboard --- Leaderboard.css | 277 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 277 insertions(+) create mode 100644 Leaderboard.css diff --git a/Leaderboard.css b/Leaderboard.css new file mode 100644 index 0000000..5f6b51b --- /dev/null +++ b/Leaderboard.css @@ -0,0 +1,277 @@ +/* ========== LEADERBOARD CONTAINER ========== */ +.leaderboard { + position: relative; + z-index: 2; + background: rgba(20, 0, 40, 0.65); + border-radius: 20px; + padding: 40px 30px; + width: 90%; + max-width: 450px; + + border: 2px solid rgba(0, 255, 255, 0.4); + box-shadow: + 0 0 25px rgba(0, 255, 255, 0.4), + 0 0 60px rgba(255, 0, 255, 0.25), + inset 0 0 40px rgba(0, 255, 255, 0.2); + animation: scanGlow 4s ease-in-out infinite alternate; +} + +/* ========== LEADERBOARD TITLE ========== */ +.leaderboard-title { + text-align: center; + font-size: 1.8rem; + margin-bottom: 30px; + background: linear-gradient(90deg, #00d9ff 0%, #ff00ff 100%); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; + background-clip: text; + text-transform: uppercase; + letter-spacing: 3px; + font-weight: bold; + display: flex; + align-items: center; + justify-content: center; + gap: 12px; +} + +.leaderboard-title::before { + content: '🏆'; + -webkit-text-fill-color: initial; + font-size: 1.6rem; + filter: drop-shadow(0 0 8px #ffd700); +} + +/* ========== LEADERBOARD LIST ========== */ +.leaderboard-list { + list-style: none; + display: flex; + flex-direction: column; + gap: 12px; +} + +/* ========== LEADERBOARD ITEM ========== */ +.leaderboard-item { + display: flex; + align-items: center; + gap: 15px; + padding: 16px 18px; + border-radius: 14px; + background: rgba(30, 0, 50, 0.5); + border: 1px solid rgba(0, 255, 255, 0.2); + transition: all 0.3s ease; +} + +.leaderboard-item:hover { + transform: translateX(6px); + border-color: rgba(0, 255, 255, 0.5); + box-shadow: 0 0 20px rgba(0, 255, 255, 0.3); +} + +/* ========== RANK 1 - GOLD/CYAN ========== */ +.leaderboard-item.rank-1 { + background: linear-gradient(135deg, rgba(0, 234, 255, 0.2), rgba(255, 0, 255, 0.15)); + border: 2px solid rgba(0, 234, 255, 0.6); + box-shadow: + 0 0 20px rgba(0, 234, 255, 0.4), + inset 0 0 20px rgba(0, 234, 255, 0.1); +} + +.leaderboard-item.rank-1:hover { + box-shadow: + 0 0 30px rgba(0, 234, 255, 0.6), + 0 0 50px rgba(255, 0, 255, 0.3); +} + +/* ========== RANK 2 - MAGENTA ========== */ +.leaderboard-item.rank-2 { + background: linear-gradient(135deg, rgba(255, 0, 255, 0.15), rgba(150, 0, 200, 0.2)); + border: 2px solid rgba(255, 0, 255, 0.4); + box-shadow: 0 0 15px rgba(255, 0, 255, 0.25); +} + +.leaderboard-item.rank-2:hover { + box-shadow: 0 0 25px rgba(255, 0, 255, 0.5); +} + +/* ========== RANK 3 - PURPLE ========== */ +.leaderboard-item.rank-3 { + background: linear-gradient(135deg, rgba(138, 43, 226, 0.2), rgba(75, 0, 130, 0.25)); + border: 2px solid rgba(138, 43, 226, 0.4); + box-shadow: 0 0 12px rgba(138, 43, 226, 0.25); +} + +.leaderboard-item.rank-3:hover { + box-shadow: 0 0 22px rgba(138, 43, 226, 0.5); +} + +/* ========== RANK BADGE ========== */ +.rank-badge { + width: 38px; + height: 38px; + border-radius: 50%; + display: flex; + align-items: center; + justify-content: center; + font-size: 15px; + font-weight: bold; + flex-shrink: 0; + transition: all 0.3s ease; +} + +.rank-1 .rank-badge { + background: linear-gradient(135deg, #00eaff, #00ff88); + color: #0c001a; + box-shadow: 0 0 18px rgba(0, 234, 255, 0.7); + animation: pulseBadge 2s ease-in-out infinite; +} + +.rank-2 .rank-badge { + background: linear-gradient(135deg, #ff00ff, #cc00ff); + color: #ffffff; + box-shadow: 0 0 15px rgba(255, 0, 255, 0.6); +} + +.rank-3 .rank-badge { + background: linear-gradient(135deg, #8a2be2, #4b0082); + color: #ffffff; + box-shadow: 0 0 12px rgba(138, 43, 226, 0.5); +} + +.rank-other .rank-badge { + background: rgba(60, 20, 80, 0.8); + color: rgba(200, 200, 255, 0.7); + border: 1px solid rgba(0, 255, 255, 0.2); +} + +@keyframes pulseBadge { + 0%, 100% { + transform: scale(1); + box-shadow: 0 0 18px rgba(0, 234, 255, 0.7); + } + 50% { + transform: scale(1.08); + box-shadow: 0 0 25px rgba(0, 234, 255, 0.9); + } +} + +/* ========== PLAYER INFO ========== */ +.player-name { + flex: 1; + font-weight: 600; + font-size: 16px; + color: #e1e8ff; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + text-shadow: 0 0 8px rgba(0, 234, 255, 0.3); +} + +.rank-1 .player-name { + background: linear-gradient(90deg, #00eaff, #00ff88); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; + background-clip: text; + text-shadow: none; + filter: drop-shadow(0 0 6px rgba(0, 234, 255, 0.5)); +} + +.player-score { + font-weight: 700; + font-size: 16px; + color: #00eaff; + text-shadow: 0 0 10px rgba(0, 234, 255, 0.6); +} + +.rank-1 .player-score { + font-size: 18px; + background: linear-gradient(90deg, #00eaff, #ff00ff); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; + background-clip: text; + filter: drop-shadow(0 0 8px rgba(0, 234, 255, 0.7)); +} + +.rank-2 .player-score { + color: #ff00ff; + text-shadow: 0 0 10px rgba(255, 0, 255, 0.6); +} + +.rank-3 .player-score { + color: #a855f7; + text-shadow: 0 0 10px rgba(138, 43, 226, 0.5); +} + +/* ========== EMPTY STATE ========== */ +.leaderboard-empty { + text-align: center; + padding: 30px 20px; + color: rgba(200, 200, 255, 0.5); + font-size: 15px; + border: 2px dashed rgba(0, 255, 255, 0.2); + border-radius: 14px; +} + +.leaderboard-empty::before { + content: '🎮'; + display: block; + font-size: 40px; + margin-bottom: 10px; + opacity: 0.6; +} + +/* ========== YOUR RANK HIGHLIGHT ========== */ +.leaderboard-item.your-rank { + position: relative; + border-color: #00ff88 !important; + box-shadow: + 0 0 20px rgba(0, 255, 136, 0.5), + inset 0 0 15px rgba(0, 255, 136, 0.1) !important; +} + +.leaderboard-item.your-rank::after { + content: 'YOU'; + position: absolute; + right: -8px; + top: -8px; + background: linear-gradient(135deg, #00ff88, #00eaff); + color: #0c001a; + font-size: 10px; + font-weight: bold; + padding: 4px 8px; + border-radius: 6px; + box-shadow: 0 0 10px rgba(0, 255, 136, 0.6); +} + +/* ========== RESPONSIVE ========== */ +@media (max-width: 480px) { + .leaderboard { + padding: 30px 20px; + } + + .leaderboard-title { + font-size: 1.5rem; + } + + .leaderboard-item { + padding: 14px 15px; + gap: 12px; + } + + .rank-badge { + width: 32px; + height: 32px; + font-size: 13px; + } + + .player-name { + font-size: 14px; + } + + .player-score { + font-size: 14px; + } + + .rank-1 .player-score { + font-size: 16px; + } +} \ No newline at end of file From c5eeade5c5e0f0c80a878bdee8eaa69574acfef7 Mon Sep 17 00:00:00 2001 From: Michelle Aquilera Date: Mon, 24 Nov 2025 14:40:23 +0700 Subject: [PATCH 2/3] Leaderboard --- Leaderboard.css | 389 +++++++++++++++++++++++++++++++++++++---------- Leaderboard.html | 111 ++++++++++++++ 2 files changed, 422 insertions(+), 78 deletions(-) create mode 100644 Leaderboard.html diff --git a/Leaderboard.css b/Leaderboard.css index 5f6b51b..ed0b000 100644 --- a/Leaderboard.css +++ b/Leaderboard.css @@ -1,13 +1,50 @@ +* { + margin: 0; + padding: 0; + box-sizing: border-box; +} + +body { + font-family: 'Arial', sans-serif; + background: radial-gradient(circle at 20% 20%, #3b0066, #0c001a 70%); + min-height: 100vh; + display: flex; + justify-content: center; + align-items: center; + overflow: hidden; + position: relative; +} + +/* Neon Particles */ +#particles { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 1; +} + +.particle { + position: absolute; + width: 5px; + height: 5px; + border-radius: 50%; + background: radial-gradient(circle, #00ffff, #0099ff); + box-shadow: 0 0 10px #00eaff, 0 0 25px #0088ff; + pointer-events: none; +} + /* ========== LEADERBOARD CONTAINER ========== */ -.leaderboard { +.container { position: relative; z-index: 2; background: rgba(20, 0, 40, 0.65); border-radius: 20px; padding: 40px 30px; width: 90%; - max-width: 450px; - + max-width: 380px; + border: 2px solid rgba(0, 255, 255, 0.4); box-shadow: 0 0 25px rgba(0, 255, 255, 0.4), @@ -16,8 +53,25 @@ animation: scanGlow 4s ease-in-out infinite alternate; } -/* ========== LEADERBOARD TITLE ========== */ -.leaderboard-title { +@keyframes scanGlow { + 0% { + border-color: #00eaff; + box-shadow: + 0 0 20px rgba(0, 255, 255, 0.3), + 0 0 40px rgba(0, 255, 255, 0.2), + inset 0 0 25px rgba(0, 255, 255, 0.1); + } + 100% { + border-color: #ff00ff; + box-shadow: + 0 0 30px rgba(255, 0, 255, 0.4), + 0 0 70px rgba(255, 0, 255, 0.3), + inset 0 0 35px rgba(255, 0, 255, 0.2); + } +} + +/* ========== TITLE ========== */ +h1 { text-align: center; font-size: 1.8rem; margin-bottom: 30px; @@ -26,19 +80,19 @@ -webkit-text-fill-color: transparent; background-clip: text; text-transform: uppercase; - letter-spacing: 3px; + letter-spacing: 2px; font-weight: bold; display: flex; align-items: center; justify-content: center; - gap: 12px; + gap: 10px; } -.leaderboard-title::before { +h1::before { content: '🏆'; -webkit-text-fill-color: initial; font-size: 1.6rem; - filter: drop-shadow(0 0 8px #ffd700); + filter: drop-shadow(0 0 10px #ffd700); } /* ========== LEADERBOARD LIST ========== */ @@ -53,66 +107,67 @@ .leaderboard-item { display: flex; align-items: center; - gap: 15px; - padding: 16px 18px; - border-radius: 14px; + gap: 12px; + padding: 14px 16px; + border-radius: 12px; background: rgba(30, 0, 50, 0.5); border: 1px solid rgba(0, 255, 255, 0.2); transition: all 0.3s ease; + position: relative; } .leaderboard-item:hover { - transform: translateX(6px); + transform: translateX(4px); border-color: rgba(0, 255, 255, 0.5); box-shadow: 0 0 20px rgba(0, 255, 255, 0.3); } -/* ========== RANK 1 - GOLD/CYAN ========== */ +/* ========== RANK 1 - CHAMPION ========== */ .leaderboard-item.rank-1 { - background: linear-gradient(135deg, rgba(0, 234, 255, 0.2), rgba(255, 0, 255, 0.15)); + background: linear-gradient(135deg, rgba(0, 234, 255, 0.25), rgba(0, 255, 136, 0.2)); border: 2px solid rgba(0, 234, 255, 0.6); box-shadow: - 0 0 20px rgba(0, 234, 255, 0.4), - inset 0 0 20px rgba(0, 234, 255, 0.1); + 0 0 25px rgba(0, 234, 255, 0.4), + inset 0 0 25px rgba(0, 234, 255, 0.15); } .leaderboard-item.rank-1:hover { box-shadow: - 0 0 30px rgba(0, 234, 255, 0.6), - 0 0 50px rgba(255, 0, 255, 0.3); + 0 0 35px rgba(0, 234, 255, 0.6), + 0 0 60px rgba(0, 255, 136, 0.4); } -/* ========== RANK 2 - MAGENTA ========== */ +/* ========== RANK 2 - RUNNER UP ========== */ .leaderboard-item.rank-2 { - background: linear-gradient(135deg, rgba(255, 0, 255, 0.15), rgba(150, 0, 200, 0.2)); - border: 2px solid rgba(255, 0, 255, 0.4); - box-shadow: 0 0 15px rgba(255, 0, 255, 0.25); + background: linear-gradient(135deg, rgba(255, 0, 255, 0.2), rgba(204, 0, 255, 0.15)); + border: 2px solid rgba(255, 0, 255, 0.5); + box-shadow: 0 0 18px rgba(255, 0, 255, 0.3); } .leaderboard-item.rank-2:hover { - box-shadow: 0 0 25px rgba(255, 0, 255, 0.5); + box-shadow: 0 0 30px rgba(255, 0, 255, 0.5); } -/* ========== RANK 3 - PURPLE ========== */ +/* ========== RANK 3 - THIRD PLACE ========== */ .leaderboard-item.rank-3 { - background: linear-gradient(135deg, rgba(138, 43, 226, 0.2), rgba(75, 0, 130, 0.25)); - border: 2px solid rgba(138, 43, 226, 0.4); - box-shadow: 0 0 12px rgba(138, 43, 226, 0.25); + background: linear-gradient(135deg, rgba(138, 43, 226, 0.25), rgba(75, 0, 130, 0.2)); + border: 2px solid rgba(138, 43, 226, 0.5); + box-shadow: 0 0 15px rgba(138, 43, 226, 0.3); } .leaderboard-item.rank-3:hover { - box-shadow: 0 0 22px rgba(138, 43, 226, 0.5); + box-shadow: 0 0 25px rgba(138, 43, 226, 0.5); } /* ========== RANK BADGE ========== */ .rank-badge { - width: 38px; - height: 38px; + width: 36px; + height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; - font-size: 15px; + font-size: 14px; font-weight: bold; flex-shrink: 0; transition: all 0.3s ease; @@ -121,49 +176,56 @@ .rank-1 .rank-badge { background: linear-gradient(135deg, #00eaff, #00ff88); color: #0c001a; - box-shadow: 0 0 18px rgba(0, 234, 255, 0.7); + box-shadow: 0 0 20px rgba(0, 234, 255, 0.8); animation: pulseBadge 2s ease-in-out infinite; } .rank-2 .rank-badge { background: linear-gradient(135deg, #ff00ff, #cc00ff); color: #ffffff; - box-shadow: 0 0 15px rgba(255, 0, 255, 0.6); + box-shadow: 0 0 18px rgba(255, 0, 255, 0.7); } .rank-3 .rank-badge { background: linear-gradient(135deg, #8a2be2, #4b0082); color: #ffffff; - box-shadow: 0 0 12px rgba(138, 43, 226, 0.5); + box-shadow: 0 0 15px rgba(138, 43, 226, 0.6); } .rank-other .rank-badge { background: rgba(60, 20, 80, 0.8); color: rgba(200, 200, 255, 0.7); - border: 1px solid rgba(0, 255, 255, 0.2); + border: 1px solid rgba(0, 255, 255, 0.3); } @keyframes pulseBadge { 0%, 100% { transform: scale(1); - box-shadow: 0 0 18px rgba(0, 234, 255, 0.7); + box-shadow: 0 0 20px rgba(0, 234, 255, 0.8); } 50% { - transform: scale(1.08); - box-shadow: 0 0 25px rgba(0, 234, 255, 0.9); + transform: scale(1.1); + box-shadow: 0 0 30px rgba(0, 234, 255, 1); } } /* ========== PLAYER INFO ========== */ -.player-name { +.player-info { flex: 1; - font-weight: 600; - font-size: 16px; + display: flex; + flex-direction: column; + gap: 3px; + min-width: 0; +} + +.player-name { + font-weight: 700; + font-size: 15px; color: #e1e8ff; + text-shadow: 0 0 8px rgba(0, 234, 255, 0.3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; - text-shadow: 0 0 8px rgba(0, 234, 255, 0.3); } .rank-1 .player-name { @@ -173,65 +235,75 @@ background-clip: text; text-shadow: none; filter: drop-shadow(0 0 6px rgba(0, 234, 255, 0.5)); + font-size: 16px; } +.player-level { + font-size: 11px; + color: rgba(200, 200, 255, 0.6); + text-transform: uppercase; + letter-spacing: 0.5px; +} + +.rank-1 .player-level { + color: rgba(0, 255, 136, 0.8); +} + +/* ========== SCORE ========== */ .player-score { font-weight: 700; font-size: 16px; color: #00eaff; - text-shadow: 0 0 10px rgba(0, 234, 255, 0.6); + text-shadow: 0 0 12px rgba(0, 234, 255, 0.7); + display: flex; + flex-direction: column; + align-items: flex-end; + gap: 2px; + flex-shrink: 0; } -.rank-1 .player-score { - font-size: 18px; +.score-value { + font-size: 17px; +} + +.rank-1 .score-value { + font-size: 19px; background: linear-gradient(90deg, #00eaff, #ff00ff); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; - filter: drop-shadow(0 0 8px rgba(0, 234, 255, 0.7)); + filter: drop-shadow(0 0 10px rgba(0, 234, 255, 0.8)); } .rank-2 .player-score { color: #ff00ff; - text-shadow: 0 0 10px rgba(255, 0, 255, 0.6); + text-shadow: 0 0 12px rgba(255, 0, 255, 0.7); } .rank-3 .player-score { color: #a855f7; - text-shadow: 0 0 10px rgba(138, 43, 226, 0.5); + text-shadow: 0 0 12px rgba(138, 43, 226, 0.6); } -/* ========== EMPTY STATE ========== */ -.leaderboard-empty { - text-align: center; - padding: 30px 20px; +.score-label { + font-size: 10px; + text-transform: uppercase; + letter-spacing: 0.5px; color: rgba(200, 200, 255, 0.5); - font-size: 15px; - border: 2px dashed rgba(0, 255, 255, 0.2); - border-radius: 14px; -} - -.leaderboard-empty::before { - content: '🎮'; - display: block; - font-size: 40px; - margin-bottom: 10px; - opacity: 0.6; } /* ========== YOUR RANK HIGHLIGHT ========== */ .leaderboard-item.your-rank { - position: relative; border-color: #00ff88 !important; box-shadow: - 0 0 20px rgba(0, 255, 136, 0.5), - inset 0 0 15px rgba(0, 255, 136, 0.1) !important; + 0 0 25px rgba(0, 255, 136, 0.6), + inset 0 0 20px rgba(0, 255, 136, 0.15) !important; } .leaderboard-item.your-rank::after { content: 'YOU'; position: absolute; - right: -8px; + right: -6px; top: -8px; background: linear-gradient(135deg, #00ff88, #00eaff); color: #0c001a; @@ -239,22 +311,120 @@ font-weight: bold; padding: 4px 8px; border-radius: 6px; - box-shadow: 0 0 10px rgba(0, 255, 136, 0.6); + box-shadow: 0 0 15px rgba(0, 255, 136, 0.8); + letter-spacing: 1px; +} + +/* ========== EMPTY STATE ========== */ +.leaderboard-empty { + text-align: center; + padding: 35px 20px; + color: rgba(200, 200, 255, 0.5); + font-size: 14px; + border: 2px dashed rgba(0, 255, 255, 0.2); + border-radius: 12px; + background: rgba(30, 0, 50, 0.3); +} + +.leaderboard-empty::before { + content: '🎮'; + display: block; + font-size: 42px; + margin-bottom: 10px; + opacity: 0.6; + filter: drop-shadow(0 0 10px rgba(0, 234, 255, 0.4)); +} + +/* ========== BACK BUTTON ========== */ +.btn-back { + width: 100%; + padding: 14px; + margin-top: 22px; + + background: linear-gradient(90deg, #00eaff, #ff00ff); + border: none; + border-radius: 12px; + + color: #fff; + font-weight: bold; + text-transform: uppercase; + font-size: 16px; + + letter-spacing: 2px; + cursor: pointer; + + box-shadow: 0 5px 25px rgba(0, 217, 255, 0.4); + transition: all 0.25s ease; +} + +.btn-back:hover { + transform: translateY(-3px); + box-shadow: + 0 8px 35px rgba(0, 217, 255, 0.7), + 0 0 20px rgba(255, 0, 255, 0.6); +} + +.btn-back:active { + transform: translateY(0); +} + +/* ========== STATS SECTION (OPTIONAL) ========== */ +.stats-container { + display: grid; + grid-template-columns: repeat(3, 1fr); + gap: 10px; + margin-bottom: 25px; +} + +.stat-box { + background: rgba(30, 0, 50, 0.5); + border: 1px solid rgba(0, 255, 255, 0.2); + border-radius: 10px; + padding: 12px 8px; + text-align: center; + transition: all 0.3s ease; +} + +.stat-box:hover { + border-color: rgba(0, 255, 255, 0.5); + box-shadow: 0 0 15px rgba(0, 255, 255, 0.3); +} + +.stat-label { + font-size: 10px; + text-transform: uppercase; + letter-spacing: 0.5px; + color: rgba(200, 200, 255, 0.6); + margin-bottom: 5px; +} + +.stat-value { + font-size: 18px; + font-weight: bold; + color: #00eaff; + text-shadow: 0 0 10px rgba(0, 234, 255, 0.6); } /* ========== RESPONSIVE ========== */ @media (max-width: 480px) { - .leaderboard { - padding: 30px 20px; + .container { + padding: 25px 20px; + max-width: 95%; } - .leaderboard-title { - font-size: 1.5rem; + h1 { + font-size: 1.6rem; + gap: 8px; + margin-bottom: 25px; + } + + h1::before { + font-size: 1.4rem; } .leaderboard-item { - padding: 14px 15px; - gap: 12px; + padding: 12px 14px; + gap: 10px; } .rank-badge { @@ -267,11 +437,74 @@ font-size: 14px; } - .player-score { - font-size: 14px; + .rank-1 .player-name { + font-size: 15px; } - .rank-1 .player-score { + .player-level { + font-size: 10px; + } + + .score-value { + font-size: 15px; + } + + .rank-1 .score-value { + font-size: 17px; + } + + .score-label { + font-size: 9px; + } + + .btn-back { + padding: 12px; + font-size: 15px; + } + + .stats-container { + gap: 8px; + margin-bottom: 20px; + } + + .stat-box { + padding: 10px 6px; + } + + .stat-value { font-size: 16px; } + + .stat-label { + font-size: 9px; + } +} + +@media (max-width: 360px) { + .container { + padding: 20px 15px; + } + + h1 { + font-size: 1.4rem; + } + + .leaderboard-item { + padding: 10px 12px; + gap: 8px; + } + + .rank-badge { + width: 28px; + height: 28px; + font-size: 12px; + } + + .player-name { + font-size: 13px; + } + + .score-value { + font-size: 14px; + } } \ No newline at end of file diff --git a/Leaderboard.html b/Leaderboard.html new file mode 100644 index 0000000..55cc7a6 --- /dev/null +++ b/Leaderboard.html @@ -0,0 +1,111 @@ + + + + + + Leaderboard - 2048 + + + + +
+ +
+

Leaderboard

+ +
+
+
Players
+
142
+
+
+
Your Rank
+
--
+
+
+
Top Score
+
0
+
+
+ +
    + +
  • +
    1
    +
    +
    CyberKing
    +
    Level 99
    +
    +
    +
    9,850
    +
    Points
    +
    +
  • + +
  • +
    2
    +
    +
    NeonMaster
    +
    Level 87
    +
    +
    +
    8,200
    +
    Points
    +
    +
  • + +
  • +
    3
    +
    +
    PixelHunter
    +
    Level 75
    +
    +
    +
    6,950
    +
    Points
    +
    +
  • + +
  • +
    4
    +
    +
    StarGazer
    +
    Level 62
    +
    +
    +
    5,420
    +
    Points
    +
    +
  • + +
  • +
    5
    +
    +
    CodeNinja
    +
    Level 58
    +
    +
    +
    4,890
    +
    Points
    +
    +
  • + +
  • +
    12
    +
    +
    You
    +
    Level 42
    +
    +
    +
    3,120
    +
    Points
    +
    +
  • +
+ + +
+ + \ No newline at end of file From cc905ac01b781f8f65c3fd49b22f614f2a9e2803 Mon Sep 17 00:00:00 2001 From: Michelle Aquilera Date: Mon, 24 Nov 2025 14:44:49 +0700 Subject: [PATCH 3/3] leaderboard css --- Leaderboard.css | 183 ++++++++++++++++++++++++++---------------------- Leaderboard.js | 0 2 files changed, 100 insertions(+), 83 deletions(-) create mode 100644 Leaderboard.js diff --git a/Leaderboard.css b/Leaderboard.css index ed0b000..3793923 100644 --- a/Leaderboard.css +++ b/Leaderboard.css @@ -41,9 +41,9 @@ body { z-index: 2; background: rgba(20, 0, 40, 0.65); border-radius: 20px; - padding: 40px 30px; - width: 90%; - max-width: 380px; + padding: 40px 100px; + width: 98%; + max-width: 1600px; border: 2px solid rgba(0, 255, 255, 0.4); box-shadow: @@ -73,25 +73,25 @@ body { /* ========== TITLE ========== */ h1 { text-align: center; - font-size: 1.8rem; - margin-bottom: 30px; + font-size: 2.2rem; + margin-bottom: 35px; background: linear-gradient(90deg, #00d9ff 0%, #ff00ff 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; text-transform: uppercase; - letter-spacing: 2px; + letter-spacing: 3px; font-weight: bold; display: flex; align-items: center; justify-content: center; - gap: 10px; + gap: 15px; } h1::before { content: '🏆'; -webkit-text-fill-color: initial; - font-size: 1.6rem; + font-size: 2rem; filter: drop-shadow(0 0 10px #ffd700); } @@ -100,16 +100,16 @@ h1::before { list-style: none; display: flex; flex-direction: column; - gap: 12px; + gap: 14px; } /* ========== LEADERBOARD ITEM ========== */ .leaderboard-item { display: flex; align-items: center; - gap: 12px; - padding: 14px 16px; - border-radius: 12px; + gap: 20px; + padding: 18px 25px; + border-radius: 14px; background: rgba(30, 0, 50, 0.5); border: 1px solid rgba(0, 255, 255, 0.2); transition: all 0.3s ease; @@ -117,7 +117,7 @@ h1::before { } .leaderboard-item:hover { - transform: translateX(4px); + transform: translateX(6px); border-color: rgba(0, 255, 255, 0.5); box-shadow: 0 0 20px rgba(0, 255, 255, 0.3); } @@ -161,13 +161,13 @@ h1::before { /* ========== RANK BADGE ========== */ .rank-badge { - width: 36px; - height: 36px; + width: 45px; + height: 45px; border-radius: 50%; display: flex; align-items: center; justify-content: center; - font-size: 14px; + font-size: 17px; font-weight: bold; flex-shrink: 0; transition: all 0.3s ease; @@ -214,13 +214,13 @@ h1::before { flex: 1; display: flex; flex-direction: column; - gap: 3px; + gap: 4px; min-width: 0; } .player-name { font-weight: 700; - font-size: 15px; + font-size: 18px; color: #e1e8ff; text-shadow: 0 0 8px rgba(0, 234, 255, 0.3); white-space: nowrap; @@ -235,14 +235,14 @@ h1::before { background-clip: text; text-shadow: none; filter: drop-shadow(0 0 6px rgba(0, 234, 255, 0.5)); - font-size: 16px; + font-size: 19px; } .player-level { - font-size: 11px; + font-size: 12px; color: rgba(200, 200, 255, 0.6); text-transform: uppercase; - letter-spacing: 0.5px; + letter-spacing: 1px; } .rank-1 .player-level { @@ -252,22 +252,22 @@ h1::before { /* ========== SCORE ========== */ .player-score { font-weight: 700; - font-size: 16px; + font-size: 18px; color: #00eaff; text-shadow: 0 0 12px rgba(0, 234, 255, 0.7); display: flex; flex-direction: column; align-items: flex-end; - gap: 2px; + gap: 3px; flex-shrink: 0; } .score-value { - font-size: 17px; + font-size: 22px; } .rank-1 .score-value { - font-size: 19px; + font-size: 25px; background: linear-gradient(90deg, #00eaff, #ff00ff); -webkit-background-clip: text; -webkit-text-fill-color: transparent; @@ -286,9 +286,9 @@ h1::before { } .score-label { - font-size: 10px; + font-size: 11px; text-transform: uppercase; - letter-spacing: 0.5px; + letter-spacing: 1px; color: rgba(200, 200, 255, 0.5); } @@ -303,14 +303,14 @@ h1::before { .leaderboard-item.your-rank::after { content: 'YOU'; position: absolute; - right: -6px; - top: -8px; + right: -8px; + top: -10px; background: linear-gradient(135deg, #00ff88, #00eaff); color: #0c001a; - font-size: 10px; + font-size: 11px; font-weight: bold; - padding: 4px 8px; - border-radius: 6px; + padding: 5px 10px; + border-radius: 8px; box-shadow: 0 0 15px rgba(0, 255, 136, 0.8); letter-spacing: 1px; } @@ -318,69 +318,36 @@ h1::before { /* ========== EMPTY STATE ========== */ .leaderboard-empty { text-align: center; - padding: 35px 20px; + padding: 40px 20px; color: rgba(200, 200, 255, 0.5); - font-size: 14px; + font-size: 16px; border: 2px dashed rgba(0, 255, 255, 0.2); - border-radius: 12px; + border-radius: 14px; background: rgba(30, 0, 50, 0.3); } .leaderboard-empty::before { content: '🎮'; display: block; - font-size: 42px; - margin-bottom: 10px; + font-size: 50px; + margin-bottom: 12px; opacity: 0.6; filter: drop-shadow(0 0 10px rgba(0, 234, 255, 0.4)); } -/* ========== BACK BUTTON ========== */ -.btn-back { - width: 100%; - padding: 14px; - margin-top: 22px; - - background: linear-gradient(90deg, #00eaff, #ff00ff); - border: none; - border-radius: 12px; - - color: #fff; - font-weight: bold; - text-transform: uppercase; - font-size: 16px; - - letter-spacing: 2px; - cursor: pointer; - - box-shadow: 0 5px 25px rgba(0, 217, 255, 0.4); - transition: all 0.25s ease; -} - -.btn-back:hover { - transform: translateY(-3px); - box-shadow: - 0 8px 35px rgba(0, 217, 255, 0.7), - 0 0 20px rgba(255, 0, 255, 0.6); -} - -.btn-back:active { - transform: translateY(0); -} - /* ========== STATS SECTION (OPTIONAL) ========== */ .stats-container { display: grid; grid-template-columns: repeat(3, 1fr); - gap: 10px; - margin-bottom: 25px; + gap: 15px; + margin-bottom: 30px; } .stat-box { background: rgba(30, 0, 50, 0.5); border: 1px solid rgba(0, 255, 255, 0.2); - border-radius: 10px; - padding: 12px 8px; + border-radius: 12px; + padding: 16px 12px; text-align: center; transition: all 0.3s ease; } @@ -391,21 +358,76 @@ h1::before { } .stat-label { - font-size: 10px; + font-size: 11px; text-transform: uppercase; - letter-spacing: 0.5px; + letter-spacing: 1px; color: rgba(200, 200, 255, 0.6); - margin-bottom: 5px; + margin-bottom: 6px; } .stat-value { - font-size: 18px; + font-size: 22px; font-weight: bold; color: #00eaff; text-shadow: 0 0 10px rgba(0, 234, 255, 0.6); } /* ========== RESPONSIVE ========== */ +@media (max-width: 768px) { + .container { + padding: 35px 30px; + max-width: 90%; + } + + h1 { + font-size: 2rem; + gap: 12px; + } + + h1::before { + font-size: 1.8rem; + } + + .leaderboard-item { + padding: 16px 20px; + gap: 16px; + } + + .rank-badge { + width: 40px; + height: 40px; + font-size: 16px; + } + + .player-name { + font-size: 17px; + } + + .rank-1 .player-name { + font-size: 18px; + } + + .score-value { + font-size: 20px; + } + + .rank-1 .score-value { + font-size: 23px; + } + + .stats-container { + gap: 12px; + } + + .stat-box { + padding: 14px 10px; + } + + .stat-value { + font-size: 20px; + } +} + @media (max-width: 480px) { .container { padding: 25px 20px; @@ -457,11 +479,6 @@ h1::before { font-size: 9px; } - .btn-back { - padding: 12px; - font-size: 15px; - } - .stats-container { gap: 8px; margin-bottom: 20px; diff --git a/Leaderboard.js b/Leaderboard.js new file mode 100644 index 0000000..e69de29