/* Froggy Jump - 样式 */

.frog-page {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background: linear-gradient(135deg, #e8dff5 0%, #fce1e4 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    user-select: none;
    -webkit-user-select: none;
}

#game-container {
    position: relative;
    box-shadow: 0 20px 50px rgba(0,0,0,0.1);
    border-radius: 20px;
    overflow: hidden;
}

canvas {
    display: block;
    border-radius: 20px;
    cursor: pointer;
}

#ui {
    position: absolute;
    top: 40px;
    left: 0;
    width: 100%;
    text-align: center;
    pointer-events: none;
    z-index: 10;
}

#score {
    font-size: 60px;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

#best-score {
    font-size: 14px;
    color: rgba(255,255,255,0.6);
    margin-top: 2px;
}

#message {
    margin-top: 10px;
    font-size: 18px;
    color: #fff;
    opacity: 0.8;
    letter-spacing: 2px;
    transition: transform 0.3s, color 0.3s;
}

/* game over 面板 */
#game-over {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s;
    z-index: 20;
}

#game-over.visible {
    opacity: 1;
    pointer-events: auto;
}

#game-over h1 {
    color: #555;
    margin: 0 0 10px;
    font-size: 28px;
}

.game-over-sub {
    color: #888;
    margin: 0 0 20px;
}

.game-over-score {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 30px;
}

.game-over-score span:first-child {
    color: #aaa;
    font-size: 14px;
}

.game-over-score #final-score {
    font-size: 48px;
    font-weight: 800;
    color: #88cc00;
}

#game-over button {
    background: #88cc00;
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 20px;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(136, 204, 0, 0.4);
    transition: transform 0.2s;
}

#game-over button:hover { transform: scale(1.05); }
#game-over button:active { transform: scale(0.95); }

/* 右上角排行榜 */
#leaderboard {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 130px;
    background: rgba(255,255,255,0.45);
    backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 10px 12px;
    z-index: 15;
    pointer-events: none;
}

.lb-title {
    font-size: 13px;
    font-weight: 700;
    color: #7c6fa0;
    margin-bottom: 6px;
    text-align: center;
}

.lb-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 3px 0;
    font-size: 12px;
    color: #666;
}

.lb-row.me {
    color: #88cc00;
    font-weight: 700;
}

.lb-name {
    max-width: 70px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lb-score {
    font-weight: 600;
    color: #9b7ec7;
}
