/* Estilo general minimalista estilo Universal Paperclips */
body {
    font-family: 'Courier New', Courier, monospace;
    background-color: #fcfbf7;
    color: #1a1a1a;
    margin: 0;
    padding: 20px;
    height: 100vh;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

h1 {
    margin: 0 0 5px 0;
    font-size: 1.8em;
}

button {
    font-family: 'Courier New', Courier, monospace;
    background: #ffffff;
    border: 1px solid #1a1a1a;
    padding: 5px 10px;
    cursor: pointer;
    margin-bottom: 5px;
    width: 100%;
    text-align: left;
    box-sizing: border-box;
}

button:hover {
    background: #f0f0f0;
}

button:disabled {
    border: 1px dashed #999;
    color: #999;
    cursor: not-allowed;
    background: none;
}

hr {
    border: 0;
    border-top: 1px dashed #1a1a1a;
    margin: 15px 0;
    width: 100%;
}

.nombre-patatal {
    font-size: 1em;
    font-weight: bold;
    text-decoration: underline;
}

#btn-editar-nombre {
    width: auto; 
    display: inline-block; 
    padding: 2px 5px; 
    font-size: 0.8em; 
    margin-left: 10px;
}

.contenedor-principal {
    display: flex;
    flex: 1 1 auto;
    gap: 20px;
    min-height: 0;
}

.columna {
    flex: 1;
    background: #ffffff;
    border: 1px solid #1a1a1a;
    padding: 15px;
    box-sizing: border-box;
    overflow-y: auto;
}

.columna-defensa {
    background: #fafafa;
    border-left: 2px solid #1a1a1a;
}

/* Clases específicas de botones y textos */
.marcador-recursos {
    font-size: 1.1em; 
    margin-bottom: 15px;
}

.btn-accion-principal {
    padding: 15px; 
    font-weight: bold; 
    text-align: center;
}

.btn-venta {
    color: #006400; 
    border-color: #006400; 
    text-align: center;
}

.btn-militar {
    margin-top: 10px; 
    border-color: #8b0000; 
    color: #8b0000;
}

.btn-reset {
    color: #8b0000; 
    border-color: #8b0000; 
    font-size: 0.75em; 
    width: auto; 
    padding: 2px 8px;
}

.danger {
    color: #8b0000;
    font-weight: bold;
}

.item-tienda {
    margin-bottom: 12px;
    font-size: 0.9em;
}

/* Caja de alerta del zombie */
.zombie-alerta {
    border: 1px solid #8b0000;
    background: #fff5f5;
    padding: 12px;
    margin-top: 15px;
}

.zombie-img {
    max-width: 100px;
    max-height: 100px;
    display: block;
    margin: 10px 0;
    border: 1px dashed #8b0000;
    background: #eee;
}

/* --- CAMPO DE BATALLA VISUAL --- */
#campo-batalla {
    position: relative;
    width: 100%;
    height: 140px;
    background: #eaeaea;
    border: 1px solid #1a1a1a;
    overflow: hidden;
    margin-bottom: 15px;
}

/* Nuestra Base (Fija a la izquierda) */
#img-base {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 70px;
    height: 70px;
    z-index: 10;
    transition: transform 0.05s ease-in-out;
}

/* El contenedor del zombie que se desplazará */
.zombie-renderizado {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%); 
    width: 50px;
    height: 75px;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 5;
    transition: left 0.1s linear; 
}

.zombie-renderizado img {
    width: 45px;
    height: 45px;
    object-fit: contain;
}

/* Barra de vida flotante sobre la cabeza del zombie */
.zombie-hp-bar {
    width: 40px;
    height: 5px;
    background: #ffcccc;
    border: 1px solid #000;
    margin-bottom: 2px;
}

.zombie-hp-progreso {
    height: 100%;
    background: #ff0000;
}

/* --- NUEVA CABECERA DOBLE --- */
.cabecera {
    flex: 0 0 auto;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.marcador-tiempo {
    text-align: right;
    font-family: 'Courier New', Courier, monospace;
}

.dia-actual {
    font-size: 1.4em;
    font-weight: bold;
    color: #1a1a1a;
}

.info-oleada {
    font-size: 0.85em;
    color: #555;
    font-weight: bold;
}

.info-oleada.peligro-inminente {
    color: #8b0000;
    animation: parpadeo 1s infinite alternate;
}

@keyframes parpadeo {
    from { opacity: 0.5; }
    to { opacity: 1; }
}

/* --- INTERRUPTOR (SWITCH) ESTILO RETRO --- */
.switch-container {
    font-size: 0.85em;
    font-weight: bold;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}