/* === RESET & BASE === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --neon-cyan: #00f0ff;
    --neon-magenta: #ff00e5;
    --neon-green: #39ff14;
    --neon-yellow: #f0ff00;
    --neon-orange: #ff6600;
    --neon-purple: #bf00ff;
    --neon-pink: #ff2d7b;
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: #1a1a2e;
    --text-primary: #e0e0e8;
    --text-muted: #6a6a80;
    --border-glow: rgba(0, 240, 255, 0.15);
}

html, body {
    width: 100%; height: 100%;
    overflow: hidden;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: '';
    position: fixed; inset: 0;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(0, 240, 255, 0.03) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 20%, rgba(255, 0, 229, 0.03) 0%, transparent 60%),
        radial-gradient(ellipse at 50% 80%, rgba(57, 255, 20, 0.02) 0%, transparent 60%);
    pointer-events: none; z-index: 0;
}

#app {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    position: relative; z-index: 1;
}

/* === SCREENS === */
.screen { display: none; flex-direction: column; align-items: center; justify-content: center; gap: 2rem; width: 100%; height: 100%; padding: 2rem; }
.screen.active { display: flex; }

.overlay {
    display: none; flex-direction: column; align-items: center; justify-content: center; gap: 1.5rem;
    position: fixed; inset: 0; z-index: 100;
    background: rgba(10, 10, 15, 0.92);
    backdrop-filter: blur(12px);
}
.overlay.active { display: flex; }

/* === LOGO === */
.logo-container { text-align: center; }
.logo {
    font-family: 'Orbitron', sans-serif;
    font-weight: 900; font-size: clamp(3rem, 8vw, 5.5rem);
    letter-spacing: 0.15em;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 30px rgba(0, 240, 255, 0.4)) drop-shadow(0 0 60px rgba(255, 0, 229, 0.2));
    animation: logoPulse 3s ease-in-out infinite;
}
@keyframes logoPulse {
    0%, 100% { filter: drop-shadow(0 0 30px rgba(0, 240, 255, 0.4)) drop-shadow(0 0 60px rgba(255, 0, 229, 0.2)); }
    50% { filter: drop-shadow(0 0 40px rgba(0, 240, 255, 0.6)) drop-shadow(0 0 80px rgba(255, 0, 229, 0.35)); }
}
.tagline {
    font-family: 'Orbitron', sans-serif;
    font-weight: 400; font-size: 0.85rem;
    letter-spacing: 0.5em; text-transform: uppercase;
    color: var(--text-muted); margin-top: 0.5rem;
}

/* === MENU === */
.menu { display: flex; flex-direction: column; align-items: center; gap: 1rem; width: 100%; max-width: 320px; }

input[type="text"],
input[type="email"] {
    width: 100%; padding: 0.9rem 1.2rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-glow);
    border-radius: 8px;
    color: var(--text-primary);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.8rem; letter-spacing: 0.15em;
    text-align: center; outline: none;
    transition: border-color 0.3s, box-shadow 0.3s;
}
input[type="text"]::placeholder,
input[type="email"]::placeholder { color: var(--text-muted); }
input[type="text"]:focus,
input[type="email"]:focus {
    border-color: var(--neon-cyan);
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.15), inset 0 0 20px rgba(0, 240, 255, 0.05);
}

/* === DISCLAIMER === */
.disclaimer {
    width: 100%; padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    text-align: center;
}
.disclaimer-prize {
    font-size: 0.7rem; line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 0.6rem;
}
.disclaimer-prize strong { color: var(--text-primary); }
.disclaimer-prize a {
    color: var(--neon-cyan);
    text-decoration: none;
    border-bottom: 1px solid rgba(0, 240, 255, 0.3);
    transition: border-color 0.3s;
}
.disclaimer-prize a:hover { border-color: var(--neon-cyan); }
.prize-list {
    display: flex; justify-content: center; gap: 0.8rem;
    margin-bottom: 0.6rem;
}
.prize {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; font-size: 0.65rem;
    letter-spacing: 0.1em; padding: 0.3rem 0.6rem;
    border-radius: 4px;
}
.prize.gold {
    color: #f0ff00; border: 1px solid rgba(240, 255, 0, 0.3);
    background: rgba(240, 255, 0, 0.05);
}
.prize.silver {
    color: var(--neon-cyan); border: 1px solid rgba(0, 240, 255, 0.3);
    background: rgba(0, 240, 255, 0.05);
}
.prize.bronze {
    color: var(--neon-magenta); border: 1px solid rgba(255, 0, 229, 0.3);
    background: rgba(255, 0, 229, 0.05);
}
.disclaimer-legal {
    font-size: 0.55rem; line-height: 1.5;
    color: var(--text-muted); opacity: 0.7;
}

/* === BUTTONS === */
.btn-neon {
    width: 100%; max-width: 320px; padding: 0.9rem 2rem;
    background: transparent;
    border: 1px solid var(--neon-cyan);
    border-radius: 8px;
    color: var(--neon-cyan);
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; font-size: 0.85rem;
    letter-spacing: 0.2em; cursor: pointer;
    transition: all 0.3s;
    position: relative; overflow: hidden;
}
.btn-neon::before {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(0, 240, 255, 0.1), transparent);
    opacity: 0; transition: opacity 0.3s;
}
.btn-neon:hover::before { opacity: 1; }
.btn-neon:hover {
    box-shadow: 0 0 25px rgba(0, 240, 255, 0.3), inset 0 0 25px rgba(0, 240, 255, 0.05);
    transform: translateY(-1px);
}
.btn-neon:active { transform: translateY(0); }

.btn-secondary {
    border-color: var(--text-muted);
    color: var(--text-muted);
}
.btn-secondary::before { background: linear-gradient(135deg, rgba(255,255,255,0.05), transparent); }
.btn-secondary:hover {
    border-color: var(--text-primary); color: var(--text-primary);
    box-shadow: 0 0 15px rgba(255,255,255,0.1);
}

.btn-gear {
    display: inline-block; text-align: center; text-decoration: none;
    margin-top: 0.5rem;
    border-color: #FF10F0; color: #FF10F0;
    font-size: 0.7rem; letter-spacing: 0.1em;
}
.btn-gear:hover {
    box-shadow: 0 0 25px rgba(255, 16, 240, 0.3), inset 0 0 25px rgba(255, 16, 240, 0.05);
    border-color: #FF10F0; color: #FF10F0;
}
.btn-gear::before { background: linear-gradient(135deg, rgba(255, 16, 240, 0.1), transparent); }

.btc-address {
    margin-top: 1.5rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.6rem; color: #ffffff;
    letter-spacing: 0.05em; opacity: 0.7;
    word-break: break-all;
}

/* === HUD === */
.game-hud {
    display: flex; justify-content: space-between; align-items: center;
    width: 100%; max-width: 600px; padding: 0 1rem; margin-bottom: 1rem;
}
.hud-label {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.6rem; letter-spacing: 0.3em;
    color: var(--text-muted); margin-bottom: 0.25rem;
}
.hud-value {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; font-size: 1.4rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 15px rgba(0, 240, 255, 0.5);
}
.hud-center { text-align: center; }
.hud-right { text-align: right; }

/* === CANVAS === */
#game-canvas {
    border: 1px solid var(--border-glow);
    border-radius: 12px;
    background: var(--bg-secondary);
    box-shadow: 0 0 40px rgba(0, 240, 255, 0.05), inset 0 0 60px rgba(0, 0, 0, 0.3);
    max-width: 100%; max-height: 70vh;
}

/* === CONTROLS HINT === */
.game-controls-hint {
    display: flex; gap: 1.5rem; margin-top: 1rem;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.55rem; letter-spacing: 0.15em;
    color: var(--text-muted);
}

/* === OVERLAYS === */
.overlay h2 {
    font-family: 'Orbitron', sans-serif;
    font-weight: 900; font-size: 2.5rem;
    letter-spacing: 0.15em;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-magenta));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.final-score { text-align: center; margin: 1rem 0; }
.final-score .hud-value { font-size: 2.5rem; }

/* === LEADERBOARD === */
.section-title {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; font-size: 1.5rem;
    letter-spacing: 0.2em; color: var(--neon-cyan);
    text-shadow: 0 0 20px rgba(0, 240, 255, 0.3);
}
.leaderboard-list {
    width: 100%; max-width: 420px;
    max-height: 60vh; overflow-y: auto;
    display: flex; flex-direction: column; gap: 0.5rem;
}
.leaderboard-list::-webkit-scrollbar { width: 4px; }
.leaderboard-list::-webkit-scrollbar-track { background: transparent; }
.leaderboard-list::-webkit-scrollbar-thumb { background: var(--text-muted); border-radius: 2px; }

.lb-row {
    display: flex; align-items: center; gap: 1rem;
    padding: 0.75rem 1.2rem;
    background: var(--bg-card);
    border: 1px solid rgba(255,255,255,0.04);
    border-radius: 8px;
    transition: border-color 0.3s;
}
.lb-row:hover { border-color: var(--border-glow); }
.lb-row.top-1 { border-color: var(--neon-yellow); box-shadow: 0 0 15px rgba(240, 255, 0, 0.1); }
.lb-row.top-2 { border-color: var(--neon-cyan); box-shadow: 0 0 10px rgba(0, 240, 255, 0.08); }
.lb-row.top-3 { border-color: var(--neon-magenta); box-shadow: 0 0 10px rgba(255, 0, 229, 0.08); }

.lb-rank {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; font-size: 0.9rem; min-width: 2rem;
    color: var(--text-muted);
}
.lb-row.top-1 .lb-rank { color: var(--neon-yellow); }
.lb-row.top-2 .lb-rank { color: var(--neon-cyan); }
.lb-row.top-3 .lb-rank { color: var(--neon-magenta); }

.lb-name {
    flex: 1;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.75rem; letter-spacing: 0.1em;
    color: var(--text-primary);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.lb-score {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; font-size: 0.85rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 10px rgba(0, 240, 255, 0.3);
}
.lb-date {
    font-size: 0.6rem; color: var(--text-muted);
    letter-spacing: 0.05em;
}
.lb-empty {
    text-align: center; padding: 3rem 1rem;
    color: var(--text-muted);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.75rem; letter-spacing: 0.15em;
}

/* === RESPONSIVE === */
@media (max-width: 600px) {
    .game-controls-hint { flex-wrap: wrap; justify-content: center; gap: 0.8rem; }
    .logo { font-size: 2.5rem; }
    .overlay h2 { font-size: 1.8rem; }
}
