/* Main stylesheet for Orbital Descent v23 */

body {
    background-color: #000000;
    color: #FFBF00;
    font-family: 'Courier New', monospace;
    margin: 0;
    padding: 0;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

#game-container {
    width: 100vw;
    height: 100vh;
    position: relative;
    background-color: #000000;
    overflow: hidden;
}

#start-screen {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    width: 80%;
    z-index: 10;
}

#start-screen h1 {
    font-size: 2.5em;
    text-shadow: 0 0 10px #FFBF00;
    margin: 0;
    letter-spacing: 2px;
}

.subtitle {
    font-size: 1.2em;
    margin-top: 10px;
    opacity: 0.8;
}

#drop-btn {
    background-color: #000000;
    color: #FFBF00;
    border: 2px solid #FFBF00;
    padding: 15px 30px;
    font-size: 1.5em;
    font-family: 'Courier New', monospace;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 0 20px rgba(255, 191, 0, 0.5);
    margin-top: 30px;
}

#drop-btn:hover {
    box-shadow: 0 0 30px rgba(255, 191, 0, 0.8);
}

#descent-ui {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 5;
}

#thermal-scope {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    overflow: hidden;
}

#phosphor-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(rgba(255, 191, 0, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 191, 0, 0.1) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: grid-flicker 0.1s infinite;
    filter: blur(0.5px);
}

@keyframes grid-flicker {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

#altitude-indicator {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 1.2em;
    text-shadow: 0 0 5px #FFBF00;
}

#timer {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2em;
    text-shadow: 0 0 10px #FFBF00;
    animation: timer-pulse 1s infinite;
}

@keyframes timer-pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

#target-indicator {
    position: absolute;
    bottom: 20px;
    left: 20px;
    font-size: 1.2em;
    text-shadow: 0 0 5px #FFBF00;
}

#altitude-button-container {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

#altitude-btn {
    background-color: rgba(0, 0, 0, 0.7);
    color: #FFBF00;
    border: 2px solid #FFBF00;
    padding: 15px 30px;
    font-size: 1.2em;
    font-family: 'Courier New', monospace;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(255, 191, 0, 0.5);
}

#altitude-btn:hover {
    box-shadow: 0 0 25px rgba(255, 191, 0, 0.8);
}

#status-display {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    z-index: 10;
    font-size: 1.2em;
    text-shadow: 0 0 5px #FFBF00;
}

#impact-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 1000;
}

#impact-text {
    font-size: 4em;
    text-shadow: 0 0 30px #FFBF00;
    margin-bottom: 50px;
    animation: impact-pulse 0.5s infinite;
}

@keyframes impact-pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

#impact-animation {
    width: 80%;
    height: 200px;
    background-color: #FFBF00;
    opacity: 0.1;
    animation: glitch 0.5s infinite;
    filter: blur(2px);
}

@keyframes glitch {
    0% { transform: translate(0); }
    20% { transform: translate(-2px, 2px); }
    40% { transform: translate(-2px, -2px); }
    60% { transform: translate(2px, 2px); }
    80% { transform: translate(2px, -2px); }
    100% { transform: translate(0); }
}

/* Glitch effect for phosphor grid */
.glitch-effect {
    position: relative;
    animation: glitch-anim 0.5s infinite;
}

@keyframes glitch-anim {
    0% { transform: translate(0); }
    20% { transform: translate(-2px, 2px); }
    40% { transform: translate(-2px, -2px); }
    60% { transform: translate(2px, 2px); }
    80% { transform: translate(2px, -2px); }
    100% { transform: translate(0); }
}

/* Connection lost static effect */
.connection-lost {
    background: 
        linear-gradient(rgba(255, 0, 0, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 0, 0, 0.1) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: static 0.2s infinite;
    filter: blur(0.5px);
}

@keyframes static {
    0% { transform: translate(0, 0); }
    10% { transform: translate(1px, 0); }
    20% { transform: translate(0, 1px); }
    30% { transform: translate(-1px, 0); }
    40% { transform: translate(0, -1px); }
    50% { transform: translate(1px, 1px); }
    60% { transform: translate(-1px, -1px); }
    70% { transform: translate(0, 0); }
    80% { transform: translate(1px, -1px); }
    90% { transform: translate(-1px, 1px); }
    100% { transform: translate(0, 0); }
}

/* Impact screen tear effect */
.impact-tear {
    animation: tear 0.3s ease-out;
}

@keyframes tear {
    0% { 
        filter: blur(0) grayscale(0);
        opacity: 1;
    }
    100% { 
        filter: blur(5px) grayscale(1);
        opacity: 0;
    }
}

/* Timer color transition */
.timer-red {
    color: #FF0000;
    text-shadow: 0 0 10px #FF0000;
}

.hidden {
    display: none !important;
}

