/* ============================== */
/*  Estilos de Autenticación      */
/* ============================== */

:root {
    --primary-color: #3a6ea5;
    --secondary-color: #f8f9fa;
    --accent-color: #ff6b6b;
    --dark-color: #2c3e50;
    --light-color: #ffffff;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
}

.auth-container {
    position: relative;
    min-height: 100vh;
    display: flex;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    overflow: hidden;
}

/* Fondo decorativo */
.auth-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('images/bg-auth.jpg') center/cover no-repeat;
    z-index: 0;
}

.auth-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(42, 82, 152, 0.85);
    backdrop-filter: blur(2px);
}

/* Contenedor de formularios */
.auth-forms-container {
    position: relative;
    z-index: 2;
    width: 45%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.1);
}

/* Panel informativo */
.auth-info-panel {
    position: relative;
    z-index: 2;
    width: 55%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: white;
}

.auth-info-content {
    max-width: 500px;
    animation: fadeInUp 1s ease-out;
}

.auth-info-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.auth-info-content > p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.auth-features {
    list-style: none;
    padding: 0;
    margin-bottom: 3rem;
}

.auth-features li {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.auth-features i {
    font-size: 1.5rem;
    margin-right: 1rem;
    color: #ffd700;
    width: 30px;
    text-align: center;
}

.auth-quote {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: 10px;
    border-left: 4px solid #ffd700;
    backdrop-filter: blur(5px);
}

.auth-quote p {
    font-style: italic;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.auth-quote span {
    font-weight: 600;
    color: #ffd700;
}

/* Formularios de autenticación */
.auth-form {
    width: 100%;
    max-width: 450px;
    display: none;
    animation: fadeIn 0.5s ease;
}

.auth-form.active {
    display: block;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-icon {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    animation: bounce 2s infinite;
}

.auth-header h2 {
    font-size: 2rem;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.auth-header p {
    color: #6c757d;
    font-size: 1rem;
}

.auth-form-content {
    width: 100%;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
    flex: 1;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark-color);
}

.input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 15px;
    color: #6c757d;
    z-index: 2;
}

.input-group input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(58, 110, 165, 0.1);
}

.password-toggle {
    position: absolute;
    right: 15px;
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    z-index: 2;
}

.password-toggle:hover {
    color: var(--primary-color);
}

/* Indicador de fuerza de contraseña */
.password-strength {
    margin-top: 0.5rem;
}

.strength-bar {
    height: 5px;
    background: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.strength-fill {
    height: 100%;
    width: 0%;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.strength-text {
    font-size: 0.8rem;
    color: #6c757d;
}

/* Opciones del formulario */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.remember-me, .terms-agreement {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.remember-me input, .terms-agreement input {
    margin: 0;
}

.remember-me label, .terms-agreement label {
    margin: 0;
    font-size: 0.9rem;
    color: #6c757d;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.forgot-password:hover {
    color: var(--dark-color);
    text-decoration: underline;
}

.terms-agreement a {
    color: var(--primary-color);
    text-decoration: none;
}

.terms-agreement a:hover {
    text-decoration: underline;
}

/* Botón de autenticación */
.auth-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, var(--primary-color), #2a5298);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 15px rgba(58, 110, 165, 0.3);
}

.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(58, 110, 165, 0.4);
}

.auth-btn:active {
    transform: translateY(0);
}

/* Divisor */
.auth-divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e9ecef;
}

.auth-divider span {
    background: white;
    padding: 0 1rem;
    color: #6c757d;
    font-size: 0.9rem;
}

/* Autenticación social */
.social-auth {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    background: white;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.social-btn.facebook {
    color: #1877f2;
}

.social-btn.facebook:hover {
    background: #1877f2;
    color: white;
    border-color: #1877f2;
}

.social-btn.google {
    color: #db4437;
}

.social-btn.google:hover {
    background: #db4437;
    color: white;
    border-color: #db4437;
}

/* Enlace para cambiar entre formularios */
.auth-switch {
    text-align: center;
}

.auth-switch p {
    color: #6c757d;
    margin: 0;
}

.auth-switch a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.auth-switch a:hover {
    color: var(--dark-color);
    text-decoration: underline;
}

/* Animaciones */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Estados de fuerza de contraseña */
.password-weak .strength-fill {
    background: var(--danger-color);
    width: 25%;
}

.password-medium .strength-fill {
    background: var(--warning-color);
    width: 50%;
}

.password-strong .strength-fill {
    background: var(--success-color);
    width: 75%;
}

.password-very-strong .strength-fill {
    background: var(--success-color);
    width: 100%;
}

.password-weak .strength-text {
    color: var(--danger-color);
}

.password-medium .strength-text {
    color: var(--warning-color);
}

.password-strong .strength-text,
.password-very-strong .strength-text {
    color: var(--success-color);
}

/* Responsive */
@media (max-width: 992px) {
    .auth-container {
        flex-direction: column;
    }
    
    .auth-forms-container {
        width: 100%;
        min-height: auto;
        order: 2;
    }
    
    .auth-info-panel {
        width: 100%;
        min-height: auto;
        order: 1;
        padding: 2rem 1rem;
    }
    
    .auth-info-content {
        text-align: center;
    }
    
    .auth-features li {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .auth-forms-container {
        padding: 1rem;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .auth-header h2 {
        font-size: 1.75rem;
    }
    
    .auth-info-content h2 {
        font-size: 2rem;
    }
}