* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Orbitron', monospace;
    background: #000;
    color: #00ff00;
    overflow: hidden;
    height: 100vh;
    position: relative;
}

.container {
    position: relative;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* === EFECTOS DE FONDO === */
.background-effects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.laser-grid {
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(90deg, transparent 98%, #ff0000 100%),
        linear-gradient(0deg, transparent 98%, #ff0000 100%);
    background-size: 50px 50px;
    animation: gridMove 4s linear infinite;
    opacity: 0.3;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

.vault-door {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 300px;
    border: 10px solid #333;
    border-radius: 50%;
    background: radial-gradient(circle, #111 30%, #222 70%, #333 100%);
    box-shadow: 
        inset 0 0 50px rgba(255, 0, 0, 0.3),
        0 0 100px rgba(255, 0, 0, 0.2);
    animation: vaultRotate 10s linear infinite;
}

.vault-door::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: #ff0000;
    border-radius: 50%;
    box-shadow: 0 0 20px #ff0000;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes vaultRotate {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.5; transform: translate(-50%, -50%) scale(1.2); }
}

.sparks {
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, #ffff00 1px, transparent 1px),
        radial-gradient(circle at 80% 20%, #ff8800 1px, transparent 1px),
        radial-gradient(circle at 40% 40%, #ffffff 1px, transparent 1px);
    background-size: 100px 100px, 150px 150px, 75px 75px;
    animation: sparkle 3s linear infinite;
}

@keyframes sparkle {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

/* === OVERLAY DE SISTEMA COMPROMETIDO === */
.system-breach-overlay {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 100;
    text-align: center;
}

.breach-message {
    font-size: 24px;
    font-weight: 900;
    color: #ff0000;
    text-shadow: 0 0 10px #ff0000;
    animation: glitch 1s linear infinite;
}

.breach-warning {
    font-size: 14px;
    color: #ffff00;
    margin-top: 5px;
    animation: blink 2s linear infinite;
}

@keyframes glitch {
    0%, 100% { transform: translate(0); }
    10% { transform: translate(-2px, 2px); }
    20% { transform: translate(-2px, -2px); }
    30% { transform: translate(2px, 2px); }
    40% { transform: translate(2px, -2px); }
    50% { transform: translate(-2px, 2px); }
    60% { transform: translate(-2px, -2px); }
    70% { transform: translate(2px, 2px); }
    80% { transform: translate(-2px, -2px); }
    90% { transform: translate(2px, 2px); }
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* === BANNER INSTITUCIONAL === */
.institutional-banner {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 200;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.95), rgba(0, 50, 0, 0.9));
    border-bottom: 3px solid #00ff00;
    box-shadow: 
        0 5px 20px rgba(0, 255, 0, 0.3),
        inset 0 1px 0 rgba(0, 255, 0, 0.2);
    backdrop-filter: blur(10px);
    padding: 10px 0;
}

.banner-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
}

.banner-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(90deg, transparent 98%, #00ff00 100%),
        linear-gradient(0deg, transparent 95%, #00ff00 100%);
    background-size: 30px 30px;
    opacity: 0.1;
    pointer-events: none;
}

.logo-section {
    display: flex;
    align-items: center;
    z-index: 1;
}

.institution-logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2px solid #00ff00;
    box-shadow: 
        0 0 15px rgba(0, 255, 0, 0.5),
        inset 0 0 10px rgba(0, 255, 0, 0.2);
    filter: brightness(1.2) contrast(1.1);
    animation: logo-pulse 3s ease-in-out infinite;
    background: rgba(0, 0, 0, 0.5);
    padding: 3px;
}

@keyframes logo-pulse {
    0%, 100% { 
        box-shadow: 0 0 15px rgba(0, 255, 0, 0.5), inset 0 0 10px rgba(0, 255, 0, 0.2);
        transform: scale(1);
    }
    50% { 
        box-shadow: 0 0 25px rgba(0, 255, 0, 0.8), inset 0 0 15px rgba(0, 255, 0, 0.4);
        transform: scale(1.05);
    }
}

.program-info {
    flex: 1;
    text-align: center;
    z-index: 1;
}

.program-title {
    font-family: 'Orbitron', monospace;
    font-size: 24px;
    font-weight: 900;
    color: #00ff00;
    text-shadow: 
        0 0 10px #00ff00,
        0 0 20px #00ff00,
        0 0 30px #00ff00;
    letter-spacing: 3px;
    margin: 0;
    animation: title-glow 4s ease-in-out infinite;
    position: relative;
}

.program-title::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 0, 0.1), transparent);
    animation: scanner 3s linear infinite;
    pointer-events: none;
}

@keyframes title-glow {
    0%, 100% { 
        text-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00, 0 0 30px #00ff00;
    }
    50% { 
        text-shadow: 0 0 15px #00ff00, 0 0 25px #00ff00, 0 0 35px #00ff00, 0 0 45px #00ff00;
    }
}

@keyframes scanner {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.program-subtitle {
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    color: #88ff88;
    letter-spacing: 2px;
    margin-top: 5px;
    text-transform: uppercase;
    opacity: 0.8;
    animation: subtitle-flicker 2s linear infinite;
}

@keyframes subtitle-flicker {
    0%, 98% { opacity: 0.8; }
    99%, 100% { opacity: 0.3; }
}

.security-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(0, 255, 0, 0.1);
    border: 1px solid #00ff00;
    border-radius: 5px;
    padding: 8px 12px;
    z-index: 1;
    position: relative;
    overflow: hidden;
}

.security-badge::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(0, 255, 0, 0.1), transparent);
    animation: badge-scan 4s linear infinite;
}

@keyframes badge-scan {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.badge-icon {
    font-size: 20px;
    animation: badge-pulse 2s ease-in-out infinite;
}

@keyframes badge-pulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 5px #00ff00); }
    50% { transform: scale(1.1); filter: drop-shadow(0 0 10px #00ff00); }
}

.badge-text {
    font-family: 'Orbitron', monospace;
    font-size: 10px;
    font-weight: 700;
    color: #00ff00;
    text-align: center;
    line-height: 1.2;
    letter-spacing: 1px;
}

/* === LOGO ESQUINA INFERIOR DERECHA === */
.corner-logo {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 150;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #00ff00;
    border-radius: 50%;
    padding: 8px;
    box-shadow: 
        0 0 20px rgba(0, 255, 0, 0.4),
        inset 0 0 10px rgba(0, 255, 0, 0.1);
    backdrop-filter: blur(5px);
    animation: corner-logo-pulse 4s ease-in-out infinite;
}

.central-logo {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: block;
    filter: brightness(1.2) contrast(1.1);
    transition: all 0.3s ease;
}

.corner-logo:hover {
    transform: scale(1.1);
    box-shadow: 
        0 0 30px rgba(0, 255, 0, 0.6),
        inset 0 0 15px rgba(0, 255, 0, 0.2);
}

.corner-logo:hover .central-logo {
    filter: brightness(1.4) contrast(1.3);
}

@keyframes corner-logo-pulse {
    0%, 100% { 
        box-shadow: 0 0 20px rgba(0, 255, 0, 0.4), inset 0 0 10px rgba(0, 255, 0, 0.1);
    }
    50% { 
        box-shadow: 0 0 30px rgba(0, 255, 0, 0.6), inset 0 0 15px rgba(0, 255, 0, 0.2);
    }
}

/* Ajustar el contenido principal para dejar espacio al banner */
.main-panel {
    margin-top: 100px;
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid #00ff00;
    border-radius: 10px;
    padding: 30px;
    min-width: 500px;
    box-shadow: 
        0 0 30px rgba(0, 255, 0, 0.5),
        inset 0 0 20px rgba(0, 255, 0, 0.1);
    z-index: 10;
    position: relative;
}

.system-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    border-bottom: 1px solid #00ff00;
    padding-bottom: 15px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.skull {
    font-size: 30px;
    animation: skull-glow 2s ease-in-out infinite;
}

@keyframes skull-glow {
    0%, 100% { filter: drop-shadow(0 0 5px #ff0000); }
    50% { filter: drop-shadow(0 0 15px #ff0000); }
}

.title {
    font-size: 24px;
    font-weight: 900;
    color: #ff0000;
    text-shadow: 0 0 10px #ff0000;
}

.status {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
}

.status-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ff0000;
    animation: pulse 1s ease-in-out infinite;
}

/* === CONTADOR === */
.countdown-container {
    text-align: center;
    margin: 30px 0;
}

.countdown-label {
    font-size: 16px;
    color: #00ff00;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.countdown-display {
    font-size: 80px;
    font-weight: 900;
    font-family: 'Share Tech Mono', monospace;
    color: #00ff00;
    text-shadow: 0 0 20px #00ff00;
    margin: 20px 0;
    position: relative;
}

.countdown-display.warning {
    color: #ffff00;
    text-shadow: 0 0 20px #ffff00;
    animation: warning-pulse 1s ease-in-out infinite;
}

.countdown-display.critical {
    color: #ff0000;
    text-shadow: 0 0 20px #ff0000;
    animation: critical-pulse 0.5s ease-in-out infinite;
}

@keyframes warning-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes critical-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.separator {
    animation: blink 1s linear infinite;
}

.countdown-sublabel {
    font-size: 12px;
    color: #888;
    letter-spacing: 1px;
}

/* === CONTROLES === */
.controls {
    margin: 30px 0;
}

.time-adjuster {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
}

.time-adjuster label {
    font-size: 14px;
    color: #00ff00;
}

.time-adjuster input {
    background: #000;
    border: 1px solid #00ff00;
    color: #00ff00;
    padding: 5px 10px;
    border-radius: 3px;
    width: 80px;
    font-family: 'Orbitron', monospace;
}

.time-adjuster input:focus {
    outline: none;
    box-shadow: 0 0 10px #00ff00;
}

.time-adjuster button {
    background: #000;
    border: 2px solid #00ff00;
    color: #00ff00;
    padding: 10px 20px;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.time-adjuster button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 0, 0.2), transparent);
    transition: left 0.5s;
}

.time-adjuster button:hover::before {
    left: 100%;
}

.time-adjuster button:hover {
    box-shadow: 0 0 15px #00ff00;
    transform: translateY(-2px);
}

.action-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.action-buttons button {
    background: #000;
    border: 2px solid #00ff00;
    color: #00ff00;
    padding: 10px 20px;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.action-buttons button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 255, 0, 0.2), transparent);
    transition: left 0.5s;
}

.action-buttons button:hover::before {
    left: 100%;
}

.action-buttons button:hover {
    box-shadow: 0 0 15px #00ff00;
    transform: translateY(-2px);
}

.action-buttons button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-start {
    border-color: #00ff00 !important;
    color: #00ff00 !important;
}

.btn-pause {
    border-color: #ffff00 !important;
    color: #ffff00 !important;
}

.btn-reset {
    border-color: #ff0000 !important;
    color: #ff0000 !important;
}

/* === PANEL DE ESTADO === */
.status-panel {
    border-top: 1px solid #00ff00;
    padding-top: 20px;
    margin-top: 20px;
}

.security-level {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 14px;
}

.level-critical {
    color: #ff0000;
    font-weight: 700;
    animation: blink 1s linear infinite;
}

.data-progress {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

.progress-bar {
    flex: 1;
    height: 10px;
    background: #333;
    border-radius: 5px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #00ff00, #ffff00, #ff0000);
    width: 0%;
    transition: width 1s ease;
}

/* === PERSONAJES ANIMADOS === */
.characters {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

.police-car {
    position: absolute;
    font-size: 40px;
    animation: patrol 8s linear infinite;
}

.police-1 {
    top: 80%;
    animation-delay: 0s;
}

.police-2 {
    top: 20%;
    animation-delay: 4s;
}

@keyframes patrol {
    0% { left: -50px; }
    50% { left: 50%; }
    100% { left: calc(100% + 50px); }
}

.helicopter {
    position: absolute;
    top: 10%;
    font-size: 30px;
    animation: helicopter-search 6s ease-in-out infinite;
}

@keyframes helicopter-search {
    0%, 100% { left: 10%; transform: rotate(-5deg); }
    50% { left: 80%; transform: rotate(5deg); }
}

.officer {
    position: absolute;
    font-size: 25px;
    animation: officer-search 4s ease-in-out infinite;
}

.officer-1 {
    bottom: 10%;
    left: 10%;
    animation-delay: 0s;
}

.officer-2 {
    bottom: 10%;
    right: 10%;
    animation-delay: 2s;
}

@keyframes officer-search {
    0%, 100% { transform: translateX(0) scaleX(1); }
    50% { transform: translateX(20px) scaleX(-1); }
}

/* === EFECTOS DE TERMINAL === */
.terminal-effects {
    position: fixed;
    bottom: 20px;
    left: 20px;
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    color: #00ff00;
    z-index: 100;
}

.terminal-line {
    margin: 5px 0;
    opacity: 0;
    animation: terminal-type 4s ease-in-out infinite;
}

.terminal-line:nth-child(2) {
    animation-delay: 1.5s;
}

.terminal-line:nth-child(3) {
    animation-delay: 3s;
}

@keyframes terminal-type {
    0%, 90% { opacity: 0; }
    10%, 80% { opacity: 1; }
}

/* === ALERTAS === */
.final-alert,
.success-alert {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: alert-appear 0.5s ease-out;
}

.hidden {
    display: none !important;
}

@keyframes alert-appear {
    0% { opacity: 0; transform: scale(0.8); }
    100% { opacity: 1; transform: scale(1); }
}

.alert-content {
    text-align: center;
    background: rgba(255, 0, 0, 0.1);
    border: 2px solid #ff0000;
    border-radius: 10px;
    padding: 40px;
    box-shadow: 0 0 50px rgba(255, 0, 0, 0.5);
}

.success-alert .alert-content {
    background: rgba(0, 255, 0, 0.1);
    border-color: #00ff00;
    box-shadow: 0 0 50px rgba(0, 255, 0, 0.5);
}

.alert-content h2 {
    font-size: 36px;
    margin-bottom: 20px;
    animation: glitch 1s linear infinite;
}

.alert-content p {
    font-size: 18px;
    margin: 10px 0;
}

.alert-content button {
    margin-top: 30px;
    background: #000;
    border: 2px solid #ff0000;
    color: #ff0000;
    padding: 15px 30px;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.success-alert .alert-content button {
    border-color: #00ff00;
    color: #00ff00;
}

.alert-content button:hover {
    box-shadow: 0 0 20px currentColor;
    transform: scale(1.05);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    /* Banner responsive */
    .institutional-banner {
        padding: 5px 0;
    }
    
    .banner-content {
        flex-direction: column;
        gap: 10px;
        padding: 0 10px;
    }
    
    .institution-logo {
        width: 40px;
        height: 40px;
    }
    
    .program-title {
        font-size: 16px;
        letter-spacing: 1px;
    }
    
    .program-subtitle {
        font-size: 10px;
        letter-spacing: 1px;
    }
    
    .security-badge {
        padding: 5px 8px;
    }
    
    .badge-text {
        font-size: 8px;
    }
    
    /* Ajustar margen del panel principal */
    .main-panel {
        margin-top: 120px;
        min-width: 90%;
        padding: 20px;
    }
    
    /* Logo esquina responsive */
    .corner-logo {
        bottom: 10px;
        right: 10px;
        padding: 5px;
    }
    
    .central-logo {
        width: 35px;
        height: 35px;
    }
    
    .countdown-display {
        font-size: 60px;
    }
    
    .system-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .action-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .time-adjuster {
        flex-direction: column;
        gap: 5px;
    }
}
