:root {
    --violeta: #5a32a8;
    --amarillo: #ffd700;
    --oscuro: #2d1a50;
    --blanco: #ffffff;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Open Sans', sans-serif;
    background-color: var(--blanco);
    color: var(--oscuro);
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 10%;
    background: var(--violeta);
    color: white;
}

.logo { font-family: 'Montserrat', sans-serif; font-size: 1.5rem; font-weight: bold; }
.logo span { color: var(--amarillo); }

nav button {
    padding: 10px 20px;
    margin-left: 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: 0.3s;
}

.btn-ingresar { background: transparent; color: white; border: 2px solid white !important; }
.btn-registrar { background: var(--amarillo); color: var(--oscuro); }

/* Presentación */
.hero {
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, #5a32a8 0%, #2d1a50 100%);
    color: white;
}

.hero h1 { font-size: 3rem; margin-bottom: 20px; }
.hero h1 span { color: var(--amarillo); }

.iconos-libreria { margin-top: 40px; }
.icono { width: 150px; margin: 0 20px; animation: flotar 3s infinite alternate; }

@keyframes flotar {
    from { transform: translateY(0); }
    to { transform: translateY(-20px); }
}

/* Modal Estilo */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.8);
    justify-content: center; align-items: center;
    z-index: 1000; /* Asegura que esté por encima de todo */
}

.modal-contenido {
    background: var(--blanco);
    padding: 50px 40px 40px 40px;
    border-radius: 15px;
    width: 350px;
    position: relative; /* Clave para posicionar la cruz */
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
}

/* --- AJUSTE DE LA CRUZ DE CERRAR --- */
.cerrar {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 2.5rem; /* Bien grande */
    color: var(--violeta); /* Violeta como pediste */
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    transition: transform 0.2s, color 0.2s;
}

.cerrar:hover {
    color: var(--oscuro); /* Cambia a un violeta más oscuro al pasar el mouse */
    transform: scale(1.1); /* Crece un poquito */
}

.oculto { display: none; }

.auth-form input {
    width: 100%; 
    padding: 12px; 
    margin: 10px 0;
    border: 1px solid #ddd; 
    border-radius: 5px;
    outline-color: var(--violeta); /* El borde brilla violeta al escribir */
}

.btn-accion {
    width: 100%; 
    padding: 12px; 
    background: var(--violeta);
    color: white; 
    border: none; 
    border-radius: 5px; 
    cursor: pointer;
    font-weight: bold;
    margin-top: 10px;
    transition: background 0.3s;
}

.btn-accion:hover {
    background: var(--oscuro);
}