/* Profile and Leaderboard Styles */
#profileModal, #leaderboardModal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.leaderboard-content, .profile-content {
    background: rgba(10, 10, 20, 0.95);
    border: 2px solid #ff00ff;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.5), inset 0 0 10px rgba(255, 0, 255, 0.2);
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    padding: 20px;
    position: relative;
    color: #fff;
}

.close-button {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: #ff00ff;
    font-size: 24px;
    cursor: pointer;
    z-index: 10;
}

.leaderboard-content h2, .profile-content h2 {
    color: #ff00ff;
    text-align: center;
    margin-bottom: 20px;
    font-size: 24px;
    text-shadow: 0 0 10px rgba(255, 0, 255, 0.5);
}

/* Leaderboard Table Styles */
.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 14px;
}

.leaderboard-table th, .leaderboard-table td {
    padding: 8px 10px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 0, 255, 0.2);
}

.leaderboard-table th {
    color: #ff00ff;
    font-weight: bold;
    text-transform: uppercase;
    background: rgba(255, 0, 255, 0.1);
}

.leaderboard-table tr:hover {
    background: rgba(255, 0, 255, 0.05);
}

.leaderboard-table tr.current-user {
    background: rgba(255, 0, 255, 0.15);
    font-weight: bold;
}

.leaderboard-loading, .profile-loading {
    text-align: center;
    color: #ff00ff;
    padding: 20px;
    font-size: 16px;
    animation: pulse 1.5s infinite;
}

.leaderboard-error, .profile-error {
    text-align: center;
    color: #ff4444;
    padding: 20px;
    background: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.3);
    border-radius: 4px;
    margin: 20px 0;
}

.leaderboard-message {
    text-align: center;
    color: #ffff00;
    padding: 20px;
}

/* Profile Styles */
#profileStats {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 30px;
}

.stat-box {
    flex: 1;
    min-width: 120px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #ff00ff;
    border-radius: 5px;
    padding: 10px;
    margin: 5px;
    text-align: center;
}

.stat-box h3 {
    color: #ff00ff;
    font-size: 14px;
    margin-bottom: 10px;
}

.stat-box div {
    font-size: 18px;
    color: #ffffff;
}

.rank-badge {
    display: inline-block;
    font-size: 11px;
    background: rgba(255, 0, 255, 0.2);
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 5px;
    color: #ffffff;
}

/* Car Selection Styles */
.car-selection {
    margin-top: 20px;
}

.car-selection h3 {
    color: #ff00ff;
    text-align: center;
    margin-bottom: 15px;
    font-size: 18px;
}

.car-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.car-option {
    width: 80px;
    background: #111;
    border: 2px solid #333;
    border-radius: 5px;
    padding: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.car-option:hover {
    border-color: #ff00ff;
    transform: translateY(-2px);
}

.car-option.selected {
    border-color: #ff00ff;
    box-shadow: 0 0 10px rgba(255, 0, 255, 0.5);
}

.car-preview {
    width: 100%;
    height: 60px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    margin-bottom: 5px;
}

.car-name {
    text-align: center;
    font-size: 12px;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

/* Mobile responsive adjustments */
@media (max-width: 480px) {
    .leaderboard-content, .profile-content {
        padding: 15px 10px;
        width: 95%;
    }
    
    .leaderboard-table {
        font-size: 12px;
    }
    
    .leaderboard-table th, .leaderboard-table td {
        padding: 6px 4px;
    }
    
    .stat-box {
        min-width: 90px;
        padding: 8px 5px;
    }
    
    .car-option {
        width: 70px;
    }
    
    .car-preview {
        height: 50px;
    }
} 