﻿/* Estilos específicos para el login */
.login-container {
    min-height: calc(100vh - 180px); /* Ajustado de 200px */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: .5rem 1rem;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    font-family: 'Montserrat', sans-serif;
}

.login-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(28, 42, 89, 0.1);
    width: 100%;
    max-width: 450px;
    padding: 2.5rem;
    border-top: 5px solid #1C2A59;
    position: relative;
    overflow: hidden;
}

    .login-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 5px;
        background: linear-gradient(90deg, #1C2A59, #0072BB, #13c2c2);
    }

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.login-escudo {
    height: 60px;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.login-brand {
    text-align: left;
}

.login-brand-1 {
    font-weight: 700;
    font-size: 1.3rem;
    color: #1C2A59;
    line-height: 1.2;
}

.login-brand-2 {
    font-weight: 600;
    font-size: 0.9rem;
    color: #0072BB;
    opacity: 0.9;
}

.login-subtitle {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 0;
    font-weight: 500;
}

/* Alertas */
.alert-login {
    border-radius: 10px;
    border: none;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
    border-left: 4px solid #ffc107;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

/* Formulario */
.login-form {
    margin-bottom: 1.5rem; /* Reducido de 2rem */
}

.form-group-login {
    margin-bottom: 1.5rem;
}

.form-label-login {
    display: block;
    font-weight: 600;
    color: #1C2A59;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.input-group-login {
    position: relative;
}

.form-control-login {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border: 2px solid #e1e5eb;
    border-radius: 10px;
    font-size: 1rem;
    font-family: 'Montserrat', sans-serif;
    transition: all 0.3s ease;
    background-color: #f8fafc;
}

    .form-control-login:focus {
        outline: none;
        border-color: #0072BB;
        box-shadow: 0 0 0 3px rgba(0, 114, 187, 0.1);
        background-color: white;
    }

    .form-control-login::placeholder {
        color: #a0aec0;
        font-weight: 400;
    }

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #0072BB;
    font-size: 1.1rem;
}

.password-toggle {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #a0aec0;
    cursor: pointer;
    font-size: 1rem;
    padding: 0.25rem;
    transition: color 0.3s ease;
}

    .password-toggle:hover {
        color: #0072BB;
    }

/* Opciones */
.login-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem; /* Reducido de 2rem */
    font-size: 0.9rem;
}

.form-check-login {
    display: flex;
    align-items: center;
}

.form-check-input-login {
    margin-right: 0.5rem;
    width: 1.1em;
    height: 1.1em;
    border: 2px solid #cbd5e0;
    border-radius: 4px;
    cursor: pointer;
}

    .form-check-input-login:checked {
        background-color: #0072BB;
        border-color: #0072BB;
    }

.form-check-label-login {
    color: #4a5568;
    cursor: pointer;
    font-weight: 500;
}

.forgot-password-link {
    color: #0072BB;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

    .forgot-password-link:hover {
        color: #1C2A59;
        text-decoration: underline;
    }

/* Botón de submit */
.btn-login-submit {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, #1C2A59 0%, #0072BB 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Montserrat', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0.5rem;
}

    .btn-login-submit:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(28, 42, 89, 0.3);
        background: linear-gradient(135deg, #0072BB 0%, #1C2A59 100%);
    }

    .btn-login-submit:active {
        transform: translateY(0);
    }

/* Footer del login - MODIFICADO (sin "Volver a la página principal") */
.login-footer {
    margin-top: 1.5rem; /* Reducido de 2rem */
    padding-top: 1.5rem;
    border-top: 1px solid #e1e5eb;
    text-align: center;
}

.login-help {
    color: #666;
    font-size: 0.85rem;
    margin-bottom: 0; /* Eliminado margen inferior ya que no hay botón debajo */
}

.login-help-link {
    color: #0072BB;
    text-decoration: none;
    font-weight: 600;
}

    .login-help-link:hover {
        text-decoration: underline;
    }

/* ELIMINADO: .back-to-home y todo su CSS relacionado */

/* Responsive */
@media (max-width: 576px) {
    .login-card {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }

    .login-logo {
        flex-direction: column;
        gap: 0.5rem;
    }

    .login-brand {
        text-align: center;
    }

    .login-options {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .forgot-password-link {
        align-self: flex-end;
    }
}
