:root {
    --nav-gradient: linear-gradient(90deg, #4b1a63, #1a4b63);
    --color-verde-suave: #27ae60;
    --texto: #ffffff;
    --desenfoque: 10px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    min-height: 100vh;
    color: white;
    background-image: url('fondo_sistema.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

.login-page {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-image: url('fondo_login.jpg');
    background-size: cover;
    background-position: center;
}

.login-box {
    background: rgba(255, 255, 255, 0.03);
    padding: 50px 40px;
    border-radius: 20px;
    backdrop-filter: blur(var(--desenfoque));
    -webkit-backdrop-filter: blur(var(--desenfoque));
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    width: 380px;
    text-align: center;
}

.login-box h2 {
    color: white;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 3px;
}

/* --- CORRECCIÓN DE CLIC EN INPUTS --- */
.input-container {
    position: relative;
    margin-bottom: 25px;
    text-align: left;
    cursor: text; /* Muestra cursor de texto en todo el contenedor */
}

.input-container input {
    width: 100%;
    padding: 12px 10px; /* Un poco más de espacio para clickear */
    border: none;
    border-bottom: 2px solid #3498db;
    background: transparent;
    outline: none;
    color: white;
    font-size: 16px;
    display: block;
    position: relative;
    z-index: 2; /* El input queda por encima de la etiqueta */
}

.input-container label {
    position: absolute;
    left: 10px;
    top: 12px;
    color: #888;
    transition: 0.3s;
    z-index: 1; /* La etiqueta queda atrás */
    /* CLAVE: El clic atraviesa la etiqueta y toca el input */
    pointer-events: none; 
}

.input-container input:focus ~ label,
.input-container input:valid ~ label {
    top: -15px;
    font-size: 12px;
    color: #3498db;
    font-weight: bold;
}

.btn-ingresar {
    width: 100%;
    background: var(--nav-gradient);
    color: white;
    padding: 12px;
    border-radius: 25px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    text-transform: uppercase;
    transition: 0.3s;
}

.btn-ingresar:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

/* --- NAVBAR (Corrección de despliegue) --- */
.navbar {
    background: var(--nav-gradient);
    width: 100%;
    position: fixed;
    top: 0; left: 0;
    display: flex;
    justify-content: center;
    z-index: 1000;
}

.navbar ul {
    list-style: none;
    display: flex;
}

.navbar > ul > li {
    position: relative;
}

.navbar > ul > li > a {
    display: block;
    padding: 20px 22px;
    color: var(--texto);
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: rgba(20, 20, 20, 0.95);
    min-width: 170px;
    border: 1px solid #333;
    margin-top: -1px; /* Evita huecos para que el mouse no se pierda */
}

.navbar li:hover > .dropdown-menu {
    display: block;
}

.dropdown-menu a {
    color: #ccc;
    padding: 12px 15px;
    text-decoration: none;
    display: block;
    font-size: 12px;
    border-bottom: 1px solid #222;
}

.dropdown-menu a:hover {
    background-color: var(--color-verde-suave);
    color: white;
    padding-left: 20px;
}