@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

@keyframes neonGlow {
    0%, 100% {
        text-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00, 0 0 30px #00ff00, 0 0 40px #00ff00;
    }
    50% {
        text-shadow: 0 0 20px #00ffff, 0 0 30px #00ffff, 0 0 40px #00ffff, 0 0 50px #00ffff;
    }
}

@keyframes starfield {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(100%);
    }
}

@keyframes ufoHover {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

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

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'Press Start 2P', cursive;
    overflow: hidden;
    background-color: #000;
}

#background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('images/backgroundmain.jpg');
    background-size: cover;
    background-position: center -200px;
    z-index: 0;
    filter: brightness(0.7);
}

#starfield {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 200%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, #eee, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 40px 70px, #fff, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 50px 160px, #ddd, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 90px 40px, #fff, rgba(0,0,0,0)),
        radial-gradient(2px 2px at 130px 80px, #fff, rgba(0,0,0,0));
    background-repeat: repeat;
    background-size: 200px 200px;
    animation: starfield 10s linear infinite;
    opacity: 0.5;
    z-index: -0;
}

#menu-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #00ff00;
    background-color: rgba(0, 0, 0, 0.8);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 0 30px #00ff00;
    transition: all 0.3s ease;
}

#menu-container:hover {
    box-shadow: 0 0 50px #00ffff;
}

.game-title {
    font-size: 48px;
    margin-bottom: 40px;
    animation: neonGlow 2s ease-in-out infinite;
    position: relative;
}

.game-title::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    background-image: url('images/ufo-icon.png');
    background-size: contain;
    background-repeat: no-repeat;
    animation: ufoHover 3s ease-in-out infinite;
}

.button-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.menu-button {
    font-family: 'Press Start 2P', cursive;
    font-size: 24px;
    margin: 20px 0;
    padding: 15px 30px;
    background-color: transparent;
    color: #00ff00;
    border: 3px solid #00ff00;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    position: relative;
    overflow: hidden;
    animation: buttonPulse 2s infinite;
}

.menu-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent,
        rgba(0, 255, 0, 0.4),
        transparent
    );
    transition: all 0.5s;
}

.menu-button:hover::before {
    left: 100%;
}

.menu-button:hover {
    background-color: #00ff00;
    color: #000;
    box-shadow: 0 0 20px #00ff00;
    transform: scale(1.1);
}

@media (max-width: 768px) {
    .game-title {
        font-size: 36px;
    }
    
    .menu-button {
        font-size: 18px;
        padding: 10px 20px;
    }
}
