﻿/* ========================================
   CSS PARA OLVIDAR CONTRASEÑA COCRIANZA
   Extiende Style_Login.css con elementos específicos
======================================== */

/* ========================================
   INPUT WRAPPER MEJORADO
======================================== */
.input-wrapper {
    position: relative;
}

    .input-wrapper .form-control {
        padding-right: 3rem;
    }

.input-highlight {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--cocrianza-coral-suave);
    transition: width 0.3s ease;
    border-radius: 0 0 12px 12px;
}

.form-control:focus + .input-highlight {
    width: 100%;
}

/* ========================================
   MENSAJE DE AYUDA
======================================== */
.help-message {
    background: rgba(255, 233, 220, 0.6);
    border: 1px solid rgba(255, 183, 165, 0.3);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    animation: slideInUp 0.6s ease-out 0.2s both;
}

    .help-message i {
        color: var(--cocrianza-coral-suave);
        font-size: 1.1rem;
        flex-shrink: 0;
    }

    .help-message span {
        color: var(--cocrianza-gris-calido);
        font-size: 0.9rem;
        line-height: 1.4;
    }

/* ========================================
   VALIDACIÓN DE CAMPOS
======================================== */
.validation-message {
    display: block;
    margin-top: 0.5rem;
    color: var(--cocrianza-error-secundario);
    font-size: 0.85rem;
    padding-left: 0.5rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

    .validation-message:not(:empty) {
        opacity: 1;
        transform: translateY(0);
    }

/* ========================================
   BOTÓN PRINCIPAL MEJORADO
======================================== */
.btn-cocrianza-primary {
    background: var(--cocrianza-coral-suave);
    border: 2px solid var(--cocrianza-coral-suave);
    border-radius: 14px;
    padding: 0.875rem 1.5rem;
    width: 100%;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 12px rgba(255, 183, 165, 0.25);
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

    .btn-cocrianza-primary:hover {
        background: #ff9f8a;
        border-color: #ff9f8a;
        color: white;
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(255, 183, 165, 0.35);
    }

    .btn-cocrianza-primary:active {
        transform: translateY(0);
        transition: transform 0.1s ease;
    }

    .btn-cocrianza-primary:focus {
        box-shadow: 0 0 0 3px rgba(255, 183, 165, 0.3);
    }

    /* Estado de carga del botón */
    .btn-cocrianza-primary.btn-loading {
        pointer-events: none;
        opacity: 0.8;
    }

        .btn-cocrianza-primary.btn-loading i {
            animation: spin 1s linear infinite;
        }

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* ========================================
   ENLACE DE RETORNO
======================================== */
.back-to-login {
    text-align: center;
    margin-top: 1rem;
}

    .back-to-login .btn-link {
        color: var(--cocrianza-coral-suave);
        text-decoration: none;
        font-size: 0.9rem;
        font-weight: 500;
        padding: 0.5rem 1rem;
        border-radius: 8px;
        transition: all 0.3s ease;
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
    }

        .back-to-login .btn-link:hover {
            background: rgba(255, 183, 165, 0.1);
            color: var(--cocrianza-coral-suave);
            text-decoration: none;
            transform: translateX(-3px);
        }

/* ========================================
   ANIMACIONES DE ENTRADA
======================================== */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-group {
    animation: slideInUp 0.6s ease-out;
}

    .form-group:nth-child(1) {
        animation-delay: 0.1s;
    }

    .form-group:nth-child(2) {
        animation-delay: 0.2s;
    }

.help-message {
    animation-delay: 0.3s;
}

.btn-cocrianza-primary {
    animation-delay: 0.4s;
}

/* ========================================
   RESPONSIVE
======================================== */
@media (max-width: 480px) {
    .login-card {
        padding: 1.5rem;
        margin: 0.5rem;
    }

    .welcome-title {
        font-size: 1.3rem;
    }

    .help-message {
        padding: 0.75rem;
        font-size: 0.85rem;
    }

    .btn-cocrianza-primary {
        padding: 0.75rem 1.25rem;
        font-size: 0.95rem;
    }
}

/* ========================================
   ESTADOS DE FOCO MEJORADOS
======================================== */
.form-control:focus {
    border-color: var(--cocrianza-coral-suave);
    box-shadow: 0 0 0 3px rgba(255, 183, 165, 0.15);
    background: white;
    outline: none;
}

/* Efecto de hover en inputs */
.form-control:hover:not(:focus) {
    border-color: rgba(255, 183, 165, 0.6);
}

/* ========================================
   MICRO INTERACCIONES
======================================== */
.form-control {
    transition: all 0.3s ease, transform 0.1s ease;
}

    .form-control:focus {
        transform: scale(1.01);
    }

.form-label i {
    transition: all 0.3s ease;
}

.form-group:hover .form-label i {
    transform: scale(1.1);
    color: var(--cocrianza-coral-suave);
}

/* ========================================
   SECCIÓN DE AYUDA ADICIONAL
======================================== */
.help-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--cocrianza-gris-perla);
    text-align: center;
}

.help-title {
    color: var(--cocrianza-gris-calido);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.help-items {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.help-item {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.5rem;
    font-size: 0.85rem;
    color: var(--cocrianza-gris-calido);
    opacity: 0.8;
}

    .help-item i {
        color: var(--cocrianza-coral-suave);
        font-size: 0.9rem;
        width: 16px;
        text-align: center;
        flex-shrink: 0;
    }

/* ========================================
   RESPONSIVE PARA AYUDA
======================================== */
@media (max-width: 480px) {
    .help-section {
        margin-top: 1.5rem;
        padding-top: 1rem;
    }

    .help-items {
        gap: 0.5rem;
    }

    .help-item {
        font-size: 0.8rem;
        padding: 0.25rem;
    }
}