/* 색상 변수 설정 */
:root {
    --primary-color: #0f0f0f;
    --secondary-color: #519ae4;
    --background-color: #dfe6e9;
    --text-color: #2d3436;
    --accent-color: #4cd3ad;
}

body {
    font-family: 'Nanum Gothic', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.game-container {
    text-align: center;
    width: 100%;
    max-width: 400px;
}

h1 {
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.scoreboard {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.score, .lives {
    font-size: 18px;
}

.score i {
    color: var(--accent-color);
    margin-right: 5px;
}

.lives i {
    color: #e74c3c;
    margin: 0 2px;
}

.game-area {
    width: 100%;
    height: 60dvh;
    border: 3px solid var(--primary-color);
    border-radius: 15px;
    position: relative;
    overflow: hidden;
    background-color: #ffffff;
    margin-bottom: 20px;
}

.word {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    font-size: 28px;
    font-weight: 700;
    color: var(--secondary-color);
    
}

input {
    padding: 12px 20px;
    width: 100%;
    max-width: 300px;
    border: 2px solid var(--secondary-color);
    border-radius: 30px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.3s;
}

input:focus {
    border-color: var(--primary-color);
}

.game-over {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(45, 52, 54, 0.9);
    justify-content: center;
    align-items: center;
}

.game-over-content {
    background-color: #ffffff;
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    color: var(--text-color);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.game-over-content h2 {
    font-size: 32px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.game-over-content p {
    font-size: 20px;
    margin-bottom: 30px;
}

button {
    padding: 15px 30px;
    border: none;
    background-color: var(--accent-color);
    color: #ffffff;
    border-radius: 30px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #00b894;
}

.countdown-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(45, 52, 54, 0.9);
    justify-content: center;
    align-items: center;
}

.countdown-content {
    font-size: 80px;
    color: #ffffff;
    font-weight: bold;
}

@media (max-width: 600px) {
    .game-area {
        height: 300px;
    }
}

.meaning {
    font-size: 20px;
    color: #e74c3c;
    font-weight: bold;
    text-align: center;
}


.game-over-content p {
    font-size: 20px;
    margin-bottom: 15px; /* 기존 30px에서 조정 */
}

.scoreboard {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.timer {
    font-size: 18px;
}


.rpm-gauge {
    margin-top: 20px;
    text-align: center;
}

.gauge {
    width: 150px;
    height: 75px;
    background: #ecf0f1;
    border-top-left-radius: 150px;
    border-top-right-radius: 150px;
    position: relative;
    margin: 0 auto;
    overflow: hidden;
}

.gauge-needle {
    width: 4px;
    height: 75px;
    background: #e74c3c;
    position: absolute;
    bottom: 0;
    left: 50%;
    /* 회전 축을 바늘의 아래쪽 중심으로 설정 */
    transform-origin: bottom center;
    /* 초기 회전 각도를 -90도로 설정하여 바늘이 왼쪽을 가리키도록 함 */
    transform: rotate(-90deg);
}


.rpm-display {
    margin-top: 10px;
    font-size: 18px;
}
