:root {
    --neon-green: #0f0;
    --dark-bg: #050505;
    --terminal-bg: rgba(0, 20, 0, 0.8);
    --purple: #b026ff;
    --text-color: #eee;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--dark-bg);
    background-image: url('assets/bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    font-family: 'Press Start 2P', cursive;
    color: var(--text-color);
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Scanlines Effect */
.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0),
        rgba(255,255,255,0) 50%,
        rgba(0,0,0,0.2) 50%,
        rgba(0,0,0,0.2)
    );
    background-size: 100% 4px;
    pointer-events: none;
    z-index: 10;
}

.container {
    width: 800px;
    max-width: 95%;
    background: var(--terminal-bg);
    border: 4px solid var(--neon-green);
    padding: 20px;
    box-shadow: 0 0 20px var(--neon-green), inset 0 0 20px var(--neon-green);
    position: relative;
    z-index: 5;
    min-height: 500px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.screen {
    display: none;
    width: 100%;
    text-align: center;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.screen.active {
    display: flex;
}

/* Start Screen */
.logo {
    max-width: 80%;
    margin-bottom: 40px;
    image-rendering: pixelated;
}

.blink {
    animation: blinker 1s linear infinite;
    color: var(--neon-green);
    margin-bottom: 20px;
    font-size: 1.2rem;
}

@keyframes blinker {
    50% { opacity: 0; }
}

button {
    background: var(--neon-green);
    color: #000;
    border: none;
    padding: 15px 30px;
    font-family: 'Press Start 2P', cursive;
    font-size: 1rem;
    cursor: pointer;
    text-transform: uppercase;
    box-shadow: 4px 4px 0px var(--purple);
    transition: transform 0.1s;
}

button:active {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px var(--purple);
}

button:hover {
    background: #fff;
}

/* Game Screen */
.header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    border-bottom: 2px solid var(--neon-green);
    padding-bottom: 10px;
    margin-bottom: 20px;
    color: var(--neon-green);
    font-size: 0.8rem;
}

.content-box {
    margin-bottom: 30px;
    width: 100%;
    text-align: left;
}

#level-title {
    color: var(--purple);
    margin-bottom: 15px;
    text-shadow: 2px 2px 0 #000;
}

#level-story {
    line-height: 1.6;
    font-size: 0.8rem;
    min-height: 100px;
}

.puzzle-box {
    width: 100%;
    border-top: 2px dashed var(--neon-green);
    padding-top: 20px;
}

#level-question {
    margin-bottom: 20px;
    color: var(--neon-green);
}

input[type="text"] {
    background: #000;
    border: 2px solid var(--neon-green);
    color: var(--neon-green);
    padding: 10px;
    font-family: 'Press Start 2P', cursive;
    width: 70%;
    margin-bottom: 20px;
    font-size: 0.8rem;
    outline: none;
}

#feedback-msg {
    margin-top: 15px;
    height: 20px;
    font-size: 0.8rem;
}

.success {
    color: var(--neon-green);
}

.error {
    color: red;
}

/* End Screen */
#end-screen h1 {
    color: var(--neon-green);
    margin-bottom: 30px;
    text-shadow: 4px 4px 0 var(--purple);
}

#end-screen p {
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Responsive */
@media (max-width: 600px) {
    .container {
        width: 100%;
        height: 100vh;
        border: none;
    }
    
    .logo {
        width: 100%;
    }
    
    input[type="text"] {
        width: 100%;
    }
}
