/* ===================================================
   ESTILO INTERFAZ ALIANZA (COMBINE) - ADAPTADO A STYLES2
   =================================================== */

/* Variables de styles.css unificadas en el entorno de styles2 */
:root {
    --bg-dark: #0b0b0b;                /* --combine-bg de styles.css */
    --bg-panel: rgba(20, 25, 30, 0.9); /* --combine-panel de styles.css */
    --border-blue: #305060;            /* --combine-border de styles.css */
    --text-main: #eaeaea;              /* Color de texto base de styles.css */
    --text-highlight: #5ba7c4;         /* El azul neón característico (--combine-blue) */
    --alert-yellow: #a88c22;
    --btn-hover: rgba(91, 167, 196, 0.1); /* Hover translúcido de styles.css */
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: "Alumni Sans SC", sans-serif;
    overflow-x: hidden;

    /* 👇 FUSIÓN: Tu imagen de fondo + El efecto de líneas de monitor CRT antiguo de styles.css 👇 */
    background-image: 
        linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), 
        linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06)),
        linear-gradient(rgba(5, 10, 16, 0.85), rgba(5, 10, 16, 0.85)), 
        url('imagenes/background.png');
    
    background-size: 100% 4px, 3px 100%, cover, cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* Utilidades */
.hidden { display: none !important; }
.hidden-filtro { display: none !important; }
.activa { display: block; animation: fadeIn 0.4s ease-in; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Navegación */
nav {
    background-color: var(--bg-panel);
    border-bottom: 2px solid var(--border-blue);
    padding: 15px; /* Padding sincronizado con styles.css */
    display: flex;
    justify-content: center;
    gap: 15px;
    position: sticky;
    top: 0;
    z-index: 50;
}

/* Botones con estilo militar y cortes geométricos de styles.css */
button {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-blue);
    padding: 10px 15px;
    font-family: 'Courier New', Courier, monospace;
    font-weight: bold;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s;
    /* Corte diagonal característico en la esquina inferior izquierda */
    clip-path: polygon(5% 0%, 100% 0%, 100% 100%, 0% 100%); 
}

button:hover {
    border-color: var(--text-highlight);
    color: var(--text-highlight);
    background: var(--btn-hover);
    box-shadow: 0 0 15px var(--text-highlight); /* Brillo neón */
}

.advertencia { color: #cc4444; font-weight: bold; margin-bottom: 20px; }
.pantalla { padding: 40px; text-align: center; }

#btn-menu { background-color: #4b1a1e; border-color: #961414; color: #c77070; clip-path: none; }
#btn-menu:hover { box-shadow: 0 0 12px rgba(150, 20, 20, 0.6); }

#btn-listo { background-color: #1a3c22; border-color: #2b6138; color: #8be0a4; clip-path: none; }
#btn-listo:hover { box-shadow: 0 0 12px rgba(43, 97, 56, 0.6); }

/* HUD Inventario Lateral */
#inventario {
    position: fixed;
    right: -220px;
    top: 20%;
    width: 250px;
    background: var(--bg-panel);
    border: 2px solid var(--border-blue);
    border-left: 4px solid var(--text-highlight); /* Remate lateral neón de styles.css */
    padding: 15px;
    transition: right 0.3s ease-in-out;
    z-index: 100;
}
#inventario:hover { right: 0; }
.slot { border-bottom: 1px solid var(--border-blue); padding: 10px 0; font-size: 0.9em; }

/* Grillas */
.grid-armas, .grid-final {
    display: flex; flex-wrap: wrap; gap: 20px;
    justify-content: center; margin-top: 30px;
}

/* Tarjetas adaptadas al diseño ".card-row" de informes de styles.css */
.tarjeta-arma {
    background: var(--bg-panel);
    border: 1px solid var(--border-blue);
    border-left: 4px solid var(--text-highlight); /* Línea distintiva Alianza */
    padding: 10px;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.tarjeta-arma img {
    width: 200px; height: 120px;
    object-fit: cover;
    border: 2px solid var(--border-blue); /* Marco de escaneo técnico */
    
}

.tarjeta-arma:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px var(--text-highlight);
    z-index: 50; 
}

/* Al hacer hover la imagen recupera su espectro de color (como en styles.css) */
.tarjeta-arma:hover img {
    filter: grayscale(0);
}

/* Tooltip (Nombre del arma al hover) */
.tooltip {
    visibility: hidden;
    background-color: var(--bg-dark);
    color: var(--text-highlight);
    text-align: center;
    padding: 6px 10px;
    border: 1px solid var(--border-blue);
    position: absolute;
    bottom: 105%; 
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
    white-space: nowrap;
    z-index: 100; 
}
.tarjeta-arma:hover .tooltip { visibility: visible; opacity: 1; }

/* Filtros HTML */
.filtros { margin-bottom: 25px; }
.filtro-btn { clip-path: none; } /* Mantiene formato rectangular original de tus filtros */
.filtro-btn:nth-child(1) { border-color: #2e3d52; }
.filtro-btn:nth-child(2) { border-color: #24444a; }
.filtro-btn:nth-child(3) { border-color: #3b284c; }
.filtro-btn:nth-child(4) { border-color: #4a3824; }

/* MODAL: DISEÑO DE DOS COLUMNAS */
.modal {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex; justify-content: center; align-items: center;
    z-index: 200;
}

.modal-contenido.dos-columnas {
    background: var(--bg-panel);
    border: 2px solid var(--border-blue);
    border-left: 5px solid var(--text-highlight);
    width: 850px; max-width: 95%;
    padding: 25px;
    position: relative;
    box-shadow: 0 0 30px rgba(0,0,0,0.8);
}

.cerrar {
    position: absolute; top: 10px; right: 20px;
    font-size: 28px; cursor: pointer; color: var(--text-highlight);
    text-shadow: 0 0 10px var(--text-highlight);
}

.modal-cuerpo {
    display: flex; gap: 30px; margin-top: 15px; text-align: left;
}

/* Columna Izquierda: Arma */
.col-arma {
    flex: 1.3;
    border-right: 1px solid var(--border-blue);
    padding-right: 25px;
}
.col-arma h2 { 
    color: var(--text-highlight); 
    margin-bottom: 10px; 
    text-transform: uppercase; 
    text-shadow: 0 0 10px var(--text-highlight); /* Brillo neón de títulos de styles.css */
    letter-spacing: 2px;
}
.col-arma img {
    width: 100%; height: 220px;
    object-fit: contain;
    background-color: rgba(0, 0, 0, 0.3);
    border: 2px solid var(--border-blue);
    margin-bottom: 15px;
}
.texto-accesorio { color: var(--alert-yellow); margin-top: 15px; font-style: italic; font-size: 0.95em; }

/* Columna Derecha: Módulos */
.col-modulos { flex: 1; }
.col-modulos h3 {
    color: var(--text-highlight);
    font-size: 1.1em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--border-blue);
    padding-bottom: 8px; margin-bottom: 15px;
}
.lista-opciones {
    display: flex; flex-direction: column; gap: 10px;
    max-height: 260px; overflow-y: auto; padding-right: 5px;
}

/* Botones de Módulos */
.btn-modulo {
    background: transparent; border: 1px solid #2a4b66; color: var(--text-main);
    padding: 12px; text-align: left; cursor: pointer; transition: all 0.2s;
    clip-path: none;
}
.btn-modulo:hover { background: #122130; border-color: var(--text-highlight); color: var(--text-highlight); }
.btn-modulo.seleccionado {
    background: var(--border-blue); border-color: var(--alert-yellow); color: var(--text-highlight);
    box-shadow: inset 4px 0 0 var(--alert-yellow);
}

.modal-footer { margin-top: 25px; border-top: 1px solid var(--border-blue); padding-top: 20px; }
.btn-destacado { background: var(--border-blue); font-weight: bold; width: 100%; font-size: 1.1em; clip-path: none; }
.btn-destacado:hover { background: var(--text-highlight); color: #000; box-shadow: 0 0 15px var(--text-highlight); }

/* Tarjetas Finales (Expositor) */
.tarjeta-expositor {
    background: var(--bg-panel); border: 2px solid var(--border-blue);
    border-left: 4px solid var(--text-highlight);
    padding: 20px; text-align: center; width: 280px;
}
.tarjeta-expositor img { 
    width: 240px; height: 140px; object-fit: contain; 
    filter: grayscale(0.3) contrast(1.1);
    border: 1px solid var(--border-blue);
}

/* Separadores: Reemplazado por la genial línea punteada repetitiva de styles.css */
.separator {
    height: 2px;
    background: repeating-linear-gradient(90deg, var(--border-blue), var(--border-blue) 10px, transparent 10px, transparent 20px);
    margin: 20px 0;
    border-radius: 0;
}

/* Toast */
#toast {
    position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%);
    background: #3a1e1e; border: 1px solid #aa3333; padding: 12px 25px;
    color: #ffcccc; z-index: 300; box-shadow: 0 0 15px rgba(0,0,0,0.5);
    font-family: 'Courier New', Courier, monospace;
}

/* --- SISTEMA DE RADIO --- */
#btn-toggle-radio {
    position: fixed;
    top: 15px;
    right: 20px;
    z-index: 300;
    background-color: var(--bg-panel);
    border: 1px solid var(--text-highlight);
    box-shadow: 0 0 10px rgba(139, 189, 212, 0.2);
    /* Se le aplica la animación "flicker" de parpadeo de logo de styles.css */
    animation: flicker 4s infinite; 
}

#mini-reproductor {
    position: fixed;
    top: 60px;
    right: 20px;
    width: 300px;
    background-color: var(--bg-panel);
    border: 2px solid var(--border-blue);
    border-left: 4px solid var(--text-highlight);
    padding: 15px;
    z-index: 300;
    box-shadow: 0 5px 20px rgba(0,0,0,0.8);
    backdrop-filter: blur(4px);
}

.radio-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-blue);
    padding-bottom: 5px;
    margin-bottom: 10px;
}

.radio-header h4 {
    color: var(--text-highlight);
    font-size: 0.9em;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.cerrar-radio {
    cursor: pointer;
    font-size: 1.5em;
    color: var(--text-highlight);
}

#radio-titulo {
    font-size: 1.1em;
    text-align: center;
    margin: 15px 0;
    color: var(--text-highlight);
}

.radio-controles {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
}

.radio-controles button {
    padding: 8px 12px;
    clip-path: none;
}

.radio-volumen {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 0.85em;
}

#slider-volumen {
    width: 100%;
    accent-color: var(--text-highlight); 
    cursor: pointer;
}

/* ANIMACIÓN DE PARPADEO INTERMITENTE (Portado de styles.css) */
@keyframes flicker {
    0% { opacity: 1; }
    5% { opacity: 0.8; }
    10% { opacity: 1; }
    15% { opacity: 0.9; }
    100% { opacity: 1; }
}