/* 리더보드 화면 스타일 */
#leaderboardScreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 30, 0.98), rgba(10, 0, 40, 0.98));
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10001;
    overflow-y: auto;
}

.leaderboard-content {
    max-width: 900px;
    width: 90%;
    padding: 40px;
    background: linear-gradient(135deg, rgba(10, 20, 60, 0.95), rgba(20, 10, 40, 0.95));
    border: 3px solid rgba(0, 212, 255, 0.6);
    border-radius: 30px;
    box-shadow: 0 0 60px rgba(0, 212, 255, 0.8);
}

.leaderboard-content h1 {
    font-size: 48px;
    color: #ffd700;
    text-align: center;
    margin-bottom: 40px;
    text-shadow: 0 0 30px rgba(255, 215, 0, 1);
    animation: titleGlow 2s ease-in-out infinite;
}

@keyframes titleGlow {
    0%, 100% {
        text-shadow: 0 0 30px rgba(255, 215, 0, 1);
    }
    50% {
        text-shadow: 0 0 50px rgba(255, 215, 0, 1), 0 0 80px rgba(255, 165, 0, 0.8);
    }
}

#leaderboardTable {
    margin-bottom: 30px;
}

.leaderboard-header {
    display: grid;
    grid-template-columns: 60px 1fr 120px 120px 150px;
    gap: 15px;
    padding: 15px 20px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2), rgba(138, 43, 226, 0.2));
    border-radius: 15px;
    margin-bottom: 15px;
    font-weight: bold;
    color: #00d4ff;
    font-size: 16px;
}

.leaderboard-row {
    display: grid;
    grid-template-columns: 60px 1fr 120px 120px 150px;
    gap: 15px;
    padding: 15px 20px;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.2));
    border-radius: 15px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.leaderboard-row:hover {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2), rgba(138, 43, 226, 0.2));
    border-color: rgba(0, 212, 255, 0.5);
    transform: translateX(10px);
}

.leaderboard-row.rank-1 {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.3), rgba(255, 165, 0, 0.2));
    border-color: #ffd700;
}

.leaderboard-row.rank-2 {
    background: linear-gradient(135deg, rgba(192, 192, 192, 0.3), rgba(169, 169, 169, 0.2));
    border-color: #c0c0c0;
}

.leaderboard-row.rank-3 {
    background: linear-gradient(135deg, rgba(205, 127, 50, 0.3), rgba(184, 115, 51, 0.2));
    border-color: #cd7f32;
}

.leaderboard-rank {
    font-size: 24px;
    font-weight: bold;
    text-align: center;
}

.rank-1 .leaderboard-rank {
    color: #ffd700;
    text-shadow: 0 0 15px rgba(255, 215, 0, 1);
}

.rank-2 .leaderboard-rank {
    color: #c0c0c0;
    text-shadow: 0 0 15px rgba(192, 192, 192, 1);
}

.rank-3 .leaderboard-rank {
    color: #cd7f32;
    text-shadow: 0 0 15px rgba(205, 127, 50, 1);
}

.leaderboard-name {
    font-size: 18px;
    color: #ffffff;
    font-weight: 600;
}

.leaderboard-score,
.leaderboard-time,
.leaderboard-ship {
    font-size: 16px;
    color: #00d4ff;
    text-align: center;
}

.leaderboard-close-btn {
    width: 100%;
    padding: 15px;
    font-size: 20px;
    font-weight: bold;
    background: linear-gradient(135deg, #00d4ff, #8a2be2);
    color: white;
    border: 2px solid rgba(0, 212, 255, 0.6);
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}

.leaderboard-close-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 40px rgba(0, 212, 255, 0.8);
}

/* 이름 입력 섹션 */
.name-input-section {
    margin: 30px 0;
    padding: 25px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.1), rgba(138, 43, 226, 0.1));
    border-radius: 15px;
    border: 2px solid rgba(0, 212, 255, 0.3);
}

.name-input-section label {
    display: block;
    font-size: 18px;
    color: #00d4ff;
    margin-bottom: 10px;
    font-weight: 600;
}

.name-input-section input {
    width: 100%;
    padding: 12px;
    font-size: 18px;
    border: 2px solid rgba(0, 212, 255, 0.5);
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.name-input-section input:focus {
    outline: none;
    border-color: #00d4ff;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.5);
}

.save-btn {
    width: 100%;
    padding: 12px;
    font-size: 18px;
    font-weight: bold;
    background: linear-gradient(135deg, #00ff88, #00d4ff);
    color: white;
    border: 2px solid #00ff88;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.save-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(0, 255, 136, 0.8);
}

.badge-btn {
    background: linear-gradient(135deg, #ff6600, #ff0066);
    border: 3px solid #ffd700;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.5), inset 0 0 20px rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    line-height: 1.3;
}

.badge-btn::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.badge-btn:hover {
    box-shadow: 0 0 40px rgba(255, 215, 0, 0.9), 0 0 60px rgba(255, 102, 0, 0.6), inset 0 0 30px rgba(255, 255, 255, 0.2);
    transform: scale(1.08) translateY(-2px);
    border-color: #ffee00;
}

.leaderboard-btn {
    background: linear-gradient(135deg, #ffd700, #ffaa00);
    border: 2px solid #ffd700;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
}

.leaderboard-btn:hover {
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.8);
    transform: scale(1.05) translateY(-2px);
}

.home-modal-btn {
    background: linear-gradient(135deg, #6a11cb, #2575fc);
    border: 2px solid #2575fc;
    box-shadow: 0 0 15px rgba(37, 117, 252, 0.4);
}

.home-modal-btn:hover {
    box-shadow: 0 0 30px rgba(37, 117, 252, 0.8);
    transform: scale(1.05) translateY(-2px);
}

.modal-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 10px;
}

.modal-btn {
    flex: 1;
    min-width: 140px;
    padding: 16px 24px;
    font-size: 15px;
    font-weight: bold;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.4s ease;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    position: relative;
}

.empty-leaderboard {
    text-align: center;
    padding: 40px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 18px;
}
