/* Login - Estilos Minimalistas Modernos */
/* Paleta de colores: #0a0a0a, #210056, #7f1ffc, #c88dff, #ff0080 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', -apple-system, sans-serif;
    background: #0a0a0a;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

/* Fondo con gradiente sutil animado */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(33, 0, 86, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(127, 31, 252, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(255, 0, 128, 0.1) 0%, transparent 50%);
    z-index: 0;
    pointer-events: none;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.8;
    }
}

/* Contenedor principal del login */
.login-container {
    position: relative;
    z-index: 1;
    background: rgba(15, 15, 15, 0.8);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(127, 31, 252, 0.3);
    border-radius: 24px;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 80px rgba(127, 31, 252, 0.1);
    display: flex;
    overflow: hidden;
    max-width: 900px;
    /* Reducido de 1000px a 900px */
    width: 90%;
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Imagen lateral izquierda - Tamaño pequeño */
.login-image-left {
    flex: 0.5;
    /* Más pequeña */
    position: relative;
    overflow: hidden;
    min-width: 280px;
    /* Ancho mínimo reducido */
    max-width: 350px;
    /* Ancho máximo reducido */
}

.login-image-left img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.7) saturate(1.2);
    transition: transform 0.3s ease;
}

.login-image-left::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(127, 31, 252, 0.3), rgba(255, 0, 128, 0.2));
    pointer-events: none;
}

.login-image-left:hover img {
    transform: scale(1.05);
}

/* Formulario de login */
.login-form {
    flex: 1.5;
    /* Más espacio para el formulario */
    padding: 3rem 4rem;
    /* Más padding horizontal */
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 450px;
    /* Más ancho para el formulario */
}

/* Logo en el formulario */
.login-image-right {
    max-width: 200px;
    height: auto;
    margin: 0 auto 1rem auto;
    display: block;
    filter: drop-shadow(0 4px 12px rgba(127, 31, 252, 0.3));
    transition: transform 0.3s ease;
}

.login-image-right:hover {
    transform: scale(1.05);
}

/* Título */
.login-form h2 {
    color: #ffffff;
    font-size: 2rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 2rem;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #c88dff, #ff0080);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Campos del formulario */
.login-form form p {
    margin-bottom: 1.5rem;
}

.login-form label {
    display: block;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    letter-spacing: 0.3px;
}

.login-form input[type="text"],
.login-form input[type="password"],
.login-form input[type="email"] {
    width: 100%;
    padding: 0.875rem 1rem;
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid rgba(127, 31, 252, 0.3);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    transition: all 0.3s ease;
    outline: none;
}

.login-form input:focus {
    border-color: #7f1ffc;
    box-shadow: 0 0 0 3px rgba(127, 31, 252, 0.15);
    background: rgba(25, 25, 25, 0.9);
}

.login-form input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

/* Mensajes de error */
.errorlist {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 0 0;
}

.errorlist li {
    color: #ff0080;
    font-size: 0.85rem;
    padding: 0.5rem;
    background: rgba(255, 0, 128, 0.1);
    border-left: 3px solid #ff0080;
    border-radius: 6px;
    margin-top: 0.5rem;
}

/* Contenedor del botón */
.btn-container {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

/* Botón de login */
.btn-primary {
    background: linear-gradient(135deg, #7f1ffc, #c88dff);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 0.875rem 2.5rem;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(127, 31, 252, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #c88dff, #ff0080);
    transition: left 0.4s ease;
    z-index: -1;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(127, 31, 252, 0.5);
}

.btn-primary:hover::before {
    left: 0;
}

.btn-primary:active {
    transform: translateY(0);
}

/* Links adicionales */
.login-form a {
    color: #c88dff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.login-form a:hover {
    color: #ff0080;
    text-decoration: underline;
}

/* Texto adicional */
.login-form .text-center {
    text-align: center;
    margin-top: 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .login-container {
        flex-direction: column;
        max-width: 500px;
    }

    .login-image-left {
        min-width: auto;
        height: 200px;
    }

    .login-form {
        min-width: auto;
        padding: 2rem;
    }

    .login-form h2 {
        font-size: 1.75rem;
    }
}

/* Animación de carga */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* Efecto de partículas en el fondo (opcional) */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(127, 31, 252, 0.3);
    border-radius: 50%;
    animation: float 20s infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        transform: translateY(-100vh) translateX(100px);
        opacity: 0;
    }
}