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

body {
    overflow: hidden;
    background-color: #000;
    font-family: 'Courier New', Courier, monospace;
    color: #fff;
}

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

#start-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url('intro_bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    padding-bottom: 50px;
    text-align: center;
    pointer-events: auto;
}

#game-over {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    background: rgba(20, 0, 0, 0.85);
    padding: 40px;
    border: 2px solid #800;
    border-radius: 8px;
    pointer-events: auto;
}

#start-screen h1 {
    font-size: 6rem;
    color: #fff;
    margin-bottom: 10px;
    text-shadow: 4px 4px 0 #000, -2px -2px 0 #f00;
    letter-spacing: 10px;
}

#game-over h1 {
    font-size: 4rem;
    color: #f00;
    margin-bottom: 10px;
    text-shadow: 2px 2px 5px #000;
    letter-spacing: 5px;
}

p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: #ccc;
}

button {
    background: #500;
    color: #fff;
    border: 2px solid #f00;
    padding: 15px 30px;
    font-size: 1.5rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: bold;
}

button:hover:not(:disabled) {
    background: #f00;
    color: #000;
    box-shadow: 0 0 15px #f00;
}

button:disabled {
    background: #333;
    color: #888;
    border-color: #555;
    cursor: not-allowed;
    box-shadow: none;
}

.char-btn {
    font-size: 1.5rem;
    padding: 10px 20px;
    background: #000;
    border: 3px solid #ffdd00;
    color: #ffdd00;
}
.char-btn:hover:not(:disabled) {
    background: #ffdd00;
    color: #000;
    box-shadow: 0 0 15px #ffdd00;
}

#hud {
    position: absolute;
    top: 20px;
    left: 40px;
    font-size: 2rem;
    font-weight: bold;
    color: #f00;
    text-shadow: 2px 2px 0 #000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.hidden {
    display: none !important;
}

@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0; }
    100% { opacity: 1; }
}

.blink-text {
    animation: blink 1s infinite;
}

#mute-button {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid #aaa;
    color: #fff;
    font-size: 1.5rem;
    pointer-events: auto;
    z-index: 50;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
}

#mobile-controls {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 5;
}

#joystick-zone {
    position: absolute;
    bottom: 20px;
    left: 20px;
    width: 150px;
    height: 150px;
    pointer-events: auto;
}

#action-buttons {
    position: absolute;
    bottom: 40px;
    right: 40px;
    display: flex;
    gap: 20px;
    pointer-events: auto;
}

#action-buttons button {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(80, 0, 0, 0.6);
    border: 3px solid #f00;
    color: #fff;
    font-size: 1rem;
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 10px #f00 inset, 0 0 10px #f00;
    user-select: none;
    -webkit-user-select: none;
}

#action-buttons button:active {
    background: rgba(255, 0, 0, 0.8);
    transform: scale(0.95);
}
