/* style.css */
body {
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-color: #1a1a2e;
    /* 다크 블루/퍼플 배경 */
    font-family: 'Malgun Gothic', sans-serif;
    user-select: none;
}

#game-container {
    position: relative;
    width: 800px;
    height: 600px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
    border-radius: 10px;
    overflow: hidden;
    background-color: #111;
    /* 기본 바닥 색상 */
}

#game-canvas {
    display: block;
    image-rendering: pixelated;
    /* 도트 그래픽 느낌을 낼 수도 있음 */
}

/* 안개 효과 (선택 사항) */
#fog {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* 플레이어 중심으로 밝혀지는 오버레이는 JS에서 Canvas에 직접 그릴 예정. 
       여기는 단순한 어두운 틴트용 */
    pointer-events: none;
    z-index: 5;
    background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0.4) 100%);
}

#ui-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}

#hud {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    display: flex;
    justify-content: space-between;
}

.hud-item {
    background: rgba(0, 0, 0, 0.6);
    padding: 10px 20px;
    border-radius: 20px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 20px;
    font-weight: bold;
    display: flex;
    gap: 15px;
    align-items: center;
}

.yoyo-hud span:last-child {
    color: #ffd54f;
    /* 골드 */
    font-size: 24px;
}

.survivor-hud span:last-child {
    color: #4caf50;
    /* 녹색 */
    font-size: 24px;
}

/* 스크린 UI */
.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    /* 꽤 어둡게 */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    z-index: 20;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease;
    pointer-events: auto;
}

.screen.active {
    opacity: 1;
    visibility: visible;
}

.screen h1 {
    font-size: 54px;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
    text-align: center;
}

.screen p {
    font-size: 22px;
    margin-bottom: 30px;
    text-align: center;
    line-height: 1.6;
}

.controls-guide {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 40px;
}

.controls-guide p {
    margin: 0;
    font-size: 18px;
    color: #ccc;
}

.action-btn {
    padding: 18px 40px;
    font-size: 24px;
    font-weight: bold;
    color: white;
    background-color: #6a1b9a;
    /* 보라색 계열로 호러틱하게 */
    border: 2px solid #ea80fc;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(106, 27, 154, 0.5);
    transition: all 0.2s ease;
}

.action-btn:hover {
    transform: scale(1.05);
    background-color: #8e24aa;
    box-shadow: 0 8px 25px rgba(234, 128, 252, 0.4);
}

.action-btn:active {
    transform: scale(0.95);
}