* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.game-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 1200px;
    width: 100%;
    overflow: hidden;
}

.game-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
}

.header-content {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
}

.back-btn {
    color: white;
    text-decoration: none;
    font-size: 1rem;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(-3px);
}

.game-header h1 {
    font-size: 2rem;
    font-weight: bold;
}

.score-board {
    display: flex;
    gap: 20px;
    font-size: 1.1rem;
}

.score-board span {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

.game-main {
    position: relative;
    min-height: 600px;
}

.game-canvas {
    width: 100%;
    height: 600px;
    background: #f0f0f0;
    position: relative;
    overflow: hidden;
    cursor: none;
}

.game-over {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    backdrop-filter: blur(5px);
}

.game-over h2 {
    font-size: 3rem;
    margin-bottom: 20px;
}

.game-over p {
    font-size: 1.5rem;
    margin-bottom: 30px;
}

.hidden {
    display: none !important;
}

.game-controls {
    padding: 30px;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.btn {
    padding: 12px 30px;
    font-size: 1.1rem;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    background: #6c757d;
    color: white;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5568d3 0%, #653a8b 100%);
}

.instructions {
    margin-top: 10px;
    color: #6c757d;
    text-align: center;
}

.instructions p {
    font-size: 0.9rem;
}

/* 게임 요소 스타일 */
.game-object {
    position: absolute;
    transition: all 0.1s linear;
}

.player {
    width: 35px;
    height: 35px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.enemy {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.collectible {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}

/* 반응형 디자인 */
@media (max-width: 600px) {
    .game-header h1 {
        font-size: 1.5rem;
    }

    .score-board {
        flex-direction: column;
        gap: 5px;
        font-size: 0.9rem;
    }

    .game-canvas {
        height: 400px;
    }

    .game-over h2 {
        font-size: 2rem;
    }
}
