/* === Reset y buenas prácticas === */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: url('/assets/img/logo/login-fondo.webp') no-repeat center center fixed;
    background-size: cover;
    font-family: 'Poppins', sans-serif;
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Capa oscura + blur mejorado */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.55); /* Un tono azul oscuro/gris profundo mejora el contraste */
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 0;
}

/* CONTENEDOR */
.login-container {
    position: relative;
    z-index: 2;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
}

/* TARJETA LOGIN (Glassmorphism Pulido) */
.login-card {
    width: 100%;
    max-width: 400px;
    padding: 50px 35px;
    background: rgba(255, 255, 255, 0.12); /* Menos opacidad blanca para un look más "glass" */
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    text-align: center;
}

/* LOGO */
.login-logo {
    max-width: 130px;
    height: auto;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2)); /* Le da profundidad al logo */
}

/* TITULO */
.login-card h1 {
    font-size: 1.75rem;
    margin-bottom: 2rem;
    color: #ffffff;
    font-weight: 600;
    letter-spacing: -0.5px;
}

/* MENSAJE DE ERROR */
.error-message {
    background: rgba(230, 57, 70, 0.15);
    border: 1px solid rgba(230, 57, 70, 0.3);
    color: #ff858d;
    padding: 12px;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* FORMULARIO E INPUTS */
.login-card form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem; /* Controla el espaciado vertical uniformemente */
}

.input-group {
    position: relative;
    width: 100%;
}

.login-card form input {
    width: 100%;
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.95);
    font-size: 0.95rem;
    color: #1e293b;
    transition: all 0.3s ease;
}

/* Cambiar el placeholder para que sea sutil */
.login-card form input::placeholder {
    color: #94a3b8;
}

/* Focus estilizado y limpio */
.login-card form input:focus {
    background: #ffffff;
    border-color: #F29522;
    box-shadow: 0 0 0 4px rgba(242, 149, 34, 0.25);
    outline: none;
}

/* BOTÓN INGRESAR */
.login-card form button {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    color: #ffffff;
    background: #F29522;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(242, 149, 34, 0.3);
    margin-top: 0.5rem;
}

.login-card form button:hover {
    background: #e08413;
    box-shadow: 0 6px 20px rgba(242, 149, 34, 0.45);
    transform: translateY(-1px);
}

.login-card form button:active {
    transform: translateY(1px);
}

/* === Botón flotante de volver (FAB) === */
.fab-back {
    position: fixed;
    top: 24px;
    left: 24px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #ffffff;
    font-size: 18px;
    text-decoration: none;
    z-index: 10;
    transition: all 0.25s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.fab-back:hover {
    background: rgba(255, 255, 255, 1);
    color: #1e293b;
    transform: translateX(-3px); /* Efecto sutil hacia la izquierda indicando retorno */
}

/* === RESPONSIVE === */
@media (max-width: 480px) {
    .login-card {
        padding: 40px 24px;
    }

    .login-card h1 {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .fab-back {
        top: 16px;
        left: 16px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}