/* Estilos para la página Game Over - Estética años 80s */

/* Importar fuente retro */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Share+Tech+Mono:wght@400&display=swap');

#game-over-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(45deg, #2d1b69, #1a0f3d, #0f0624);
    z-index: 99999;
    overflow: hidden;
    font-family: 'Share Tech Mono', monospace;
}

/* Efecto CRT */
.crt-effect {
    width: 100%;
    height: 100%;
    position: relative;
    background: 
        radial-gradient(ellipse at center, transparent 50%, rgba(0,0,0,0.3)),
        linear-gradient(45deg, #2d1b69 0%, #1a0f3d 50%, #0f0624 100%);
    animation: crt-flicker 0.15s infinite linear alternate;
}

.crt-effect::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(transparent 50%, rgba(0,255,0,0.03) 50%),
        linear-gradient(90deg, transparent 50%, rgba(255,0,0,0.02) 50%);
    background-size: 100% 4px, 4px 100%;
    pointer-events: none;
    z-index: 1;
}

/* Líneas de escaneo */
.scanlines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        transparent 50%,
        rgba(0, 255, 0, 0.05) 50%
    );
    background-size: 100% 4px;
    animation: scanlines-move 0.1s linear infinite;
    pointer-events: none;
    z-index: 2;
}

/* Contenido principal */
.game-over-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    z-index: 3;
    padding: 20px;
}

/* Calavera pixelada */
.skull-container {
    margin-bottom: 30px;
    animation: skull-glow 2s ease-in-out infinite alternate;
}

.pixel-skull {
    display: inline-block;
    transform: scale(3);
}

.skull-row {
    display: block;
    line-height: 1;
    margin: 1px 0;
}

.pixel {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin: 0 1px;
    background: transparent;
}

.pixel.filled {
    background: #ffff00;
    box-shadow: 
        0 0 5px #ffff00,
        0 0 10px #ffff00,
        0 0 15px #ffff00;
    animation: pixel-flicker 1.5s infinite alternate;
}

/* Texto GAME OVER */
.game-over-text {
    margin-bottom: 40px;
}

.pixel-text {
    font-family: 'Orbitron', monospace;
    font-size: 4rem;
    font-weight: 900;
    color: #ff0040;
    text-shadow: 
        0 0 10px #ff0040,
        0 0 20px #ff0040,
        0 0 30px #ff0040,
        0 0 40px #ff0040;
    letter-spacing: 8px;
    margin: 0;
    text-transform: uppercase;
}

/* Mensaje de advertencia */
.warning-message {
    margin-bottom: 40px;
    max-width: 600px;
}

.pixel-message {
    font-family: 'Share Tech Mono', monospace;
    font-size: 1.2rem;
    color: #00ff00;
    text-shadow: 
        0 0 5px #00ff00,
        0 0 10px #00ff00;
    line-height: 1.6;
    margin: 0;
    animation: text-glow 3s ease-in-out infinite alternate;
}

.codalea-brand {
    color: #00ffff;
    text-shadow: 
        0 0 5px #00ffff,
        0 0 10px #00ffff,
        0 0 15px #00ffff;
    font-weight: bold;
}

/* Contador regresivo */
.countdown {
    margin-bottom: 30px;
    padding: 15px 30px;
    border: 2px solid #ffff00;
    border-radius: 10px;
    background: rgba(255, 255, 0, 0.1);
    box-shadow: 
        0 0 20px rgba(255, 255, 0, 0.3),
        inset 0 0 20px rgba(255, 255, 0, 0.1);
}

.pixel-countdown {
    font-family: 'Orbitron', monospace;
    font-size: 1.5rem;
    color: #ffff00;
    text-shadow: 
        0 0 5px #ffff00,
        0 0 10px #ffff00;
    margin: 0;
    font-weight: 700;
}

#countdown-timer {
    font-size: 2rem;
    color: #ff4500;
    text-shadow: 
        0 0 5px #ff4500,
        0 0 10px #ff4500,
        0 0 15px #ff4500;
    animation: timer-pulse 1s ease-in-out infinite alternate;
}

/* Footer retro */
.retro-footer {
    margin-top: 40px;
}

.pixel-small {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.8rem;
    color: #888;
    text-shadow: 0 0 3px #888;
    line-height: 1.4;
    margin: 0;
    opacity: 0.7;
}

/* Estilos adicionales para la versión avanzada */

/* Header de seguridad */
.security-header {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10;
}

.security-badge {
    background: rgba(255, 0, 64, 0.2);
    border: 2px solid #ff0040;
    border-radius: 20px;
    padding: 8px 16px;
    animation: badge-pulse 2s infinite alternate;
}

.badge-text {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.8rem;
    color: #ff0040;
    text-shadow: 0 0 5px #ff0040;
    font-weight: bold;
}

/* Huesos cruzados */
.crossbones {
    position: relative;
    width: 60px;
    height: 60px;
    margin: 10px auto;
}

.bone {
    position: absolute;
    width: 40px;
    height: 6px;
    background: #ffff00;
    box-shadow: 0 0 10px #ffff00;
    border-radius: 3px;
    top: 50%;
    left: 50%;
}

.bone::before,
.bone::after {
    content: '';
    position: absolute;
    width: 10px;
    height: 10px;
    background: #ffff00;
    border-radius: 50%;
    box-shadow: 0 0 5px #ffff00;
}

.bone::before {
    top: -2px;
    left: -5px;
}

.bone::after {
    top: -2px;
    right: -5px;
}

.bone-left {
    transform: translate(-50%, -50%) rotate(45deg);
}

.bone-right {
    transform: translate(-50%, -50%) rotate(-45deg);
}

/* Subtítulo */
.subtitle {
    font-family: 'Orbitron', monospace;
    font-size: 1.5rem;
    color: #ff4500;
    text-shadow: 0 0 10px #ff4500;
    margin-top: 10px;
    letter-spacing: 3px;
    animation: subtitle-flicker 3s infinite;
}

/* Caja de advertencia mejorada */
.warning-box {
    background: rgba(0, 255, 0, 0.1);
    border: 2px solid #00ff00;
    border-radius: 15px;
    padding: 20px;
    margin: 20px 0;
    position: relative;
    overflow: hidden;
}

.warning-box::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #00ff00, #ffff00, #00ff00);
    border-radius: 15px;
    z-index: -1;
    animation: border-flow 3s linear infinite;
}

/* Información del sistema */
.system-info {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #666;
    border-radius: 10px;
    padding: 15px;
    margin: 20px 0;
    font-family: 'Share Tech Mono', monospace;
    max-width: 400px;
}

.info-line {
    display: flex;
    justify-content: space-between;
    margin: 5px 0;
    font-size: 0.9rem;
}

.info-label {
    color: #888;
}

.info-value {
    color: #00ff00;
    text-shadow: 0 0 3px #00ff00;
}

.info-value.error {
    color: #ff0040;
    text-shadow: 0 0 5px #ff0040;
    animation: error-blink 1s infinite;
}

/* Barra de progreso */
.progress-bar {
    width: 100%;
    height: 10px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #ffff00;
    border-radius: 5px;
    margin-top: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff0040, #ff4500, #ffff00);
    width: 0%;
    transition: width 1s linear;
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(255, 255, 0, 0.5);
}

/* Efecto matriz */
.matrix-text {
    margin-bottom: 10px;
    font-family: 'Share Tech Mono', monospace;
    letter-spacing: 10px;
}

.matrix-char {
    color: #00ff00;
    text-shadow: 0 0 5px #00ff00;
    font-size: 0.8rem;
    animation: matrix-flicker 0.1s infinite;
}

/* Animaciones */
@keyframes crt-flicker {
    0% { opacity: 1; }
    98% { opacity: 1; }
    99% { opacity: 0.98; }
    100% { opacity: 1; }
}

@keyframes scanlines-move {
    0% { transform: translateY(0); }
    100% { transform: translateY(4px); }
}

@keyframes skull-glow {
    0% { 
        filter: brightness(1) drop-shadow(0 0 10px #ffff00); 
        transform: scale(3);
    }
    100% { 
        filter: brightness(1.2) drop-shadow(0 0 20px #ffff00); 
        transform: scale(3.1);
    }
}

@keyframes pixel-flicker {
    0% { opacity: 1; }
    95% { opacity: 1; }
    96% { opacity: 0.7; }
    97% { opacity: 1; }
    98% { opacity: 0.8; }
    100% { opacity: 1; }
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.7; }
}

@keyframes text-glow {
    0% { 
        text-shadow: 
            0 0 5px #00ff00,
            0 0 10px #00ff00;
    }
    100% { 
        text-shadow: 
            0 0 10px #00ff00,
            0 0 20px #00ff00,
            0 0 30px #00ff00;
    }
}

@keyframes timer-pulse {
    0% { 
        transform: scale(1);
        text-shadow: 
            0 0 5px #ff4500,
            0 0 10px #ff4500,
            0 0 15px #ff4500;
    }
    100% { 
        transform: scale(1.05);
        text-shadow: 
            0 0 10px #ff4500,
            0 0 20px #ff4500,
            0 0 30px #ff4500,
            0 0 40px #ff4500;
    }
}

@keyframes badge-pulse {
    0% { 
        box-shadow: 0 0 5px #ff0040;
        transform: scale(1);
    }
    100% { 
        box-shadow: 0 0 20px #ff0040;
        transform: scale(1.05);
    }
}

@keyframes subtitle-flicker {
    0%, 90% { opacity: 1; }
    95% { opacity: 0.7; }
    100% { opacity: 1; }
}

@keyframes border-flow {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes error-blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.5; }
}

@keyframes matrix-flicker {
    0% { opacity: 1; }
    98% { opacity: 1; }
    99% { opacity: 0.3; }
    100% { opacity: 1; }
}

/* Responsive design */
@media (max-width: 768px) {
    .pixel-text {
        font-size: 2.5rem;
        letter-spacing: 4px;
    }
    
    .pixel-message {
        font-size: 1rem;
    }
    
    .pixel-countdown {
        font-size: 1.2rem;
    }
    
    #countdown-timer {
        font-size: 1.5rem;
    }
    
    .pixel-skull {
        transform: scale(2);
    }
    
    .skull-container {
        margin-bottom: 20px;
    }
    
    .security-header {
        top: 10px;
        right: 10px;
    }
    
    .badge-text {
        font-size: 0.7rem;
    }
    
    .subtitle {
        font-size: 1.2rem;
        letter-spacing: 2px;
    }
    
    .system-info {
        padding: 10px;
        margin: 15px 0;
    }
    
    .info-line {
        font-size: 0.8rem;
    }
    
    .crossbones {
        width: 40px;
        height: 40px;
    }
    
    .bone {
        width: 30px;
        height: 4px;
    }
}

@media (max-width: 480px) {
    .pixel-text {
        font-size: 2rem;
        letter-spacing: 2px;
    }
    
    .pixel-message {
        font-size: 0.9rem;
    }
    
    .pixel-skull {
        transform: scale(1.5);
    }
    
    .countdown {
        padding: 10px 20px;
    }
    
    .security-badge {
        padding: 5px 10px;
    }
    
    .badge-text {
        font-size: 0.6rem;
    }
    
    .warning-box {
        padding: 15px;
        margin: 15px 0;
    }
    
    .matrix-text {
        letter-spacing: 5px;
    }
    
    .matrix-char {
        font-size: 0.7rem;
    }
}

/* Efectos adicionales de partículas (opcional) */
.game-over-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, rgba(255, 255, 0, 0.5), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(0, 255, 255, 0.5), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(255, 0, 64, 0.5), transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(0, 255, 0, 0.5), transparent);
    background-repeat: repeat;
    background-size: 200px 200px;
    animation: particles-float 20s linear infinite;
    pointer-events: none;
    opacity: 0.3;
    z-index: -1;
}

@keyframes particles-float {
    0% { transform: translateY(0) translateX(0); }
    50% { transform: translateY(-100px) translateX(50px); }
    100% { transform: translateY(0) translateX(0); }
}
