﻿/* ============================================
   recuperarcontra.css
   Estilos para la pagina de recuperacion de contrasena
   ============================================ */

/* ===== Layout principal ===== */
.recuperar-page {
    display: flex;
    min-height: 92vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #414042;
    background: #F1F1F2;
}

/* ===== Panel izquierdo - visual ===== */
.recuperar-panel-visual {
    flex: 0 0 42%;
    background: linear-gradient(160deg, #1D3D6F 0%, #436AB3 50%, #0C949E 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 3rem;
}

    /* Circulos decorativos de fondo */
    .recuperar-panel-visual::before {
        content: '';
        position: absolute;
        top: -30%;
        right: -20%;
        width: 500px;
        height: 500px;
        border-radius: 50%;
        background: rgba(126, 203, 182, 0.12);
        pointer-events: none;
    }

    .recuperar-panel-visual::after {
        content: '';
        position: absolute;
        bottom: -20%;
        left: -15%;
        width: 400px;
        height: 400px;
        border-radius: 50%;
        background: rgba(209, 227, 155, 0.08);
        pointer-events: none;
    }

.visual-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: #FFFFFF;
}

.visual-logo {
    width: 180px;
    height: auto;
    margin-bottom: 2.5rem;
    filter: drop-shadow(0 4px 20px rgba(0,0,0,0.2));
    animation: rcFloatIn 0.8s ease-out;
}

.visual-title {
    font-size: 1.7rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
}

.visual-subtitle {
    font-size: 0.95rem;
    opacity: 0.8;
    line-height: 1.6;
    max-width: 320px;
    margin: 0 auto;
}

.visual-icon-group {
    margin-top: 3rem;
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    opacity: 0.3;
}

    .visual-icon-group i {
        font-size: 2rem;
    }

/* ===== Panel derecho - formulario ===== */
.recuperar-panel-form {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: #FFFFFF;
}

.recuperar-card {
    width: 100%;
    max-width: 460px;
    animation: rcSlideUp 0.6s ease-out;
}

.recuperar-card-header {
    margin-bottom: 2rem;
}

    .recuperar-card-header h1 {
        font-size: 1.65rem;
        font-weight: 700;
        color: #1D3D6F;
        margin-bottom: 0.5rem;
    }

    .recuperar-card-header p {
        color: #A7A9AC;
        font-size: 0.92rem;
        line-height: 1.5;
    }

/* ===== Pestanas de modo (Correo / Cedula) ===== */
.rc-mode-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 1.5rem;
    background: #F1F1F2;
    border-radius: 10px;
    padding: 4px;
    transition: opacity 0.3s ease;
}

    .rc-mode-tabs.disabled {
        opacity: 0.5;
        pointer-events: none;
    }

.rc-mode-tab {
    flex: 1;
    padding: 0.6rem 1rem;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #A7A9AC;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

    .rc-mode-tab:hover:not(.active):not(:disabled) {
        color: #414042;
    }

    .rc-mode-tab.active {
        background: #FFFFFF;
        color: #1D3D6F;
        box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    }

    .rc-mode-tab i {
        font-size: 0.82rem;
    }

/* ===== Indicadores de pasos ===== */
.recuperar-steps {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.step-indicator {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.9rem;
    border-radius: 100px;
    font-size: 0.78rem;
    font-weight: 600;
    background: #F1F1F2;
    color: #A7A9AC;
    transition: all 0.4s ease;
    user-select: none;
}

    .step-indicator.active {
        background: #1D3D6F;
        color: #FFFFFF;
    }

    .step-indicator.completed {
        background: #7ECBB6;
        color: #1D3D6F;
    }

    .step-indicator .step-num {
        width: 22px;
        height: 22px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.7rem;
        font-weight: 700;
        background: rgba(0,0,0,0.06);
        flex-shrink: 0;
    }

    .step-indicator.active .step-num {
        background: rgba(255,255,255,0.25);
    }

    .step-indicator.completed .step-num {
        background: #1D3D6F;
        color: #FFFFFF;
    }

/* ===== Alertas ===== */
.rc-alert {
    padding: 0.8rem 1rem;
    border-radius: 10px;
    font-size: 0.88rem;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    animation: rcFadeIn 0.3s ease;
    line-height: 1.4;
}

.rc-alert-success {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

    .rc-alert-success::before {
        content: '\f058';
        font-family: 'Font Awesome 6 Free';
        font-weight: 900;
        color: #10b981;
        flex-shrink: 0;
    }

.rc-alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

    .rc-alert-error::before {
        content: '\f06a';
        font-family: 'Font Awesome 6 Free';
        font-weight: 900;
        color: #D94040;
        flex-shrink: 0;
    }

.rc-alert-info {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

    .rc-alert-info::before {
        content: '\f05a';
        font-family: 'Font Awesome 6 Free';
        font-weight: 900;
        color: #436AB3;
        flex-shrink: 0;
    }

/* ===== Campos del formulario ===== */
.rc-form-field {
    margin-bottom: 1.25rem;
}

    .rc-form-field label {
        display: block;
        font-size: 0.85rem;
        font-weight: 600;
        color: #1D3D6F;
        margin-bottom: 0.4rem;
    }

.rc-input-wrapper {
    position: relative;
    display: flex;
    align-items: stretch;
}

.rc-input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #A7A9AC;
    font-size: 0.92rem;
    pointer-events: none;
    transition: color 0.3s ease;
    z-index: 1;
}

.rc-input {
    width: 100%;
    padding: 0.78rem 1rem 0.78rem 2.6rem;
    border: 2px solid #e2e4e9;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.93rem;
    color: #414042;
    background: #FFFFFF;
    transition: all 0.3s ease;
    outline: none;
}

    .rc-input:focus {
        border-color: #436AB3;
        box-shadow: 0 0 0 4px rgba(67, 106, 179, 0.1);
    }

        .rc-input:focus ~ .rc-input-icon {
            color: #436AB3;
        }

    .rc-input::placeholder {
        color: #c0c4cc;
    }

    .rc-input[readonly] {
        background: #F1F1F2;
        color: #A7A9AC;
        cursor: not-allowed;
    }

/* Campo con boton adjunto */
.rc-input-with-btn {
    display: flex;
    gap: 0.5rem;
}

    .rc-input-with-btn .rc-input-wrapper {
        flex: 1;
    }

.btn-verificar {
    padding: 0 1.2rem;
    border: none;
    border-radius: 10px;
    background: #0C949E;
    color: #FFFFFF;
    font-family: inherit;
    font-size: 0.83rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

    .btn-verificar:hover:not(:disabled) {
        background: #0a7d85;
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(12, 148, 158, 0.3);
    }

    .btn-verificar:disabled {
        opacity: 0.6;
        cursor: not-allowed;
        transform: none;
    }

    .btn-verificar.enviado {
        background: #7ECBB6;
        opacity: 1;
    }

    .btn-verificar .spinner {
        display: none;
        width: 16px;
        height: 16px;
        border: 2px solid rgba(255,255,255,0.3);
        border-top-color: white;
        border-radius: 50%;
        animation: rcSpin 0.6s linear infinite;
    }

    .btn-verificar.loading .spinner {
        display: inline-block;
    }

    .btn-verificar.loading .btn-text {
        display: none;
    }

/* Campo codigo verificacion */
.campo-codigo {
    display: none;
}

    .campo-codigo.visible {
        display: block;
        animation: rcSlideDown 0.4s ease-out;
    }

.codigo-hint {
    font-size: 0.78rem;
    color: #A7A9AC;
    margin-top: 0.35rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

    .codigo-hint i {
        font-size: 0.72rem;
        color: #0C949E;
    }

/* ===== Validacion ===== */
.recuperar-page .text-danger {
    color: #D94040;
    font-size: 0.8rem;
    margin-top: 0.3rem;
    display: block;
}

/* ===== Boton principal ===== */
/* ===== Boton principal (oculto inicialmente) ===== */
#btnSubmitContainer {
    animation: rcSlideDown 0.4s ease-out;
}

.btn-submit {
    width: 100%;
    padding: 0.85rem;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #1D3D6F, #436AB3);
    color: #FFFFFF;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

    .btn-submit:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(29, 61, 111, 0.35);
    }

    .btn-submit:active {
        transform: translateY(0);
    }

/* ===== Link volver ===== */
.rc-back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    color: #436AB3;
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

    .rc-back-link:hover {
        color: #1D3D6F;
        gap: 0.7rem;
    }

    .rc-back-link i {
        font-size: 0.8rem;
        transition: transform 0.3s ease;
    }

    .rc-back-link:hover i {
        transform: translateX(-3px);
    }

/* ===== Animaciones ===== */
@keyframes rcFloatIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes rcSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes rcSlideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes rcFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes rcSpin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .recuperar-page {
        flex-direction: column;
    }

    .recuperar-panel-visual {
        flex: none;
        padding: 2rem 1.5rem;
        min-height: auto;
    }

    .visual-logo {
        width: 120px;
        margin-bottom: 1.25rem;
    }

    .visual-title {
        font-size: 1.3rem;
    }

    .visual-subtitle {
        font-size: 0.85rem;
    }

    .visual-icon-group {
        display: none;
    }

    .recuperar-panel-form {
        padding: 1.5rem;
    }

    .recuperar-card-header h1 {
        font-size: 1.35rem;
    }
}

@media (max-width: 500px) {
    .recuperar-panel-visual {
        padding: 1.5rem 1rem;
    }

    .visual-logo {
        width: 100px;
        margin-bottom: 1rem;
    }

    .visual-title {
        font-size: 1.15rem;
    }

    .rc-input-with-btn {
        flex-direction: column;
    }

    .btn-verificar {
        padding: 0.7rem 1rem;
        justify-content: center;
    }

    .recuperar-steps {
        flex-wrap: wrap;
    }

    .step-indicator {
        font-size: 0.72rem;
        padding: 0.38rem 0.7rem;
    }

    .recuperar-card-header p {
        font-size: 0.85rem;
    }
}
