/* =========================================================
   VALROCA · PORTAL DE CLIENTES
   RECUPERACIÓN DE CONTRASEÑA
   ========================================================= */

   :root {
    --fp-blue: #1E55A3;
    --fp-blue-dark: #102E63;
    --fp-blue-deep: #07172F;
    --fp-green: #31A836;
    --fp-green-hover: #38B83E;

    --fp-white: #FFFFFF;
    --fp-background: #F4F8FB;
    --fp-text: #162033;
    --fp-muted: #667085;

    --fp-border: #D7E0EA;
    --fp-border-hover: #AAB7C7;
    --fp-focus: rgba(30, 85, 163, 0.18);

    --fp-radius-large: 28px;
    --fp-radius-medium: 16px;
    --fp-radius-small: 12px;

    --fp-shadow: 0 24px 65px rgba(7, 23, 47, 0.13);
}

/* =========================================================
   BASE
   ========================================================= */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    color: var(--fp-text);
    background:
        radial-gradient(
            circle at 12% 15%,
            rgba(30, 85, 163, 0.08),
            transparent 32%
        ),
        radial-gradient(
            circle at 90% 85%,
            rgba(49, 168, 54, 0.07),
            transparent 28%
        ),
        var(--fp-background);

    font-family: "Inter", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.5;
}

a {
    color: var(--fp-blue);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--fp-blue-dark);
    text-decoration: none;
}

/* =========================================================
   CONTENEDOR PRINCIPAL
   ========================================================= */

.fp-page {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 100vh;
    padding: 32px 20px;
    overflow: hidden;
}

.fp-page::before {
    content: "";
    position: fixed;
    top: -180px;
    right: -180px;
    width: 420px;
    height: 420px;
    border: 75px solid rgba(30, 85, 163, 0.035);
    border-radius: 50%;
    pointer-events: none;
}

.fp-page::after {
    content: "";
    position: fixed;
    bottom: -230px;
    left: -160px;
    width: 470px;
    height: 470px;
    border: 90px solid rgba(49, 168, 54, 0.03);
    border-radius: 50%;
    pointer-events: none;
}

.fp-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
}

.fp-card {
    overflow: hidden;
    background: var(--fp-white);
    border: 1px solid rgba(30, 85, 163, 0.08);
    border-radius: var(--fp-radius-large);
    box-shadow: var(--fp-shadow);
}

.fp-layout {
    display: flex;
    min-height: 760px;
}

/* =========================================================
   PANEL VISUAL IZQUIERDO
   ========================================================= */

.fp-visual {
    position: relative;
    display: flex;
    flex: 0 0 46%;
    min-width: 0;
    overflow: hidden;
    background: var(--fp-blue-deep);
}

.fp-visual-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.fp-visual-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            180deg,
            rgba(7, 23, 47, 0.23) 0%,
            rgba(7, 23, 47, 0.84) 100%
        );
}

.fp-visual-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 100%;
    padding: 52px;
    color: var(--fp-white);
}

.fp-portal-badge {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: 8px;
    margin-bottom: 22px;
    padding: 9px 15px;
    color: var(--fp-white);
    background: rgba(255, 255, 255, 0.13);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.03em;
    backdrop-filter: blur(8px);
}

.fp-portal-badge i {
    font-size: 17px;
}

.fp-visual-title {
    max-width: 470px;
    margin: 0 0 16px;
    color: var(--fp-white);
    font-family: "Montserrat", Arial, sans-serif;
    font-size: clamp(34px, 4vw, 49px);
    font-weight: 600;
    line-height: 1.08;
}

.fp-visual-description {
    max-width: 450px;
    margin: 0;
    color: rgba(255, 255, 255, 0.84);
    font-size: 17px;
    line-height: 1.65;
}

.fp-benefits {
    display: flex;
    flex-wrap: wrap;
    gap: 11px;
    margin-top: 30px;
}

.fp-benefit {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 13px;
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 13px;
}

.fp-benefit i {
    color: #68D86D;
    font-size: 16px;
}

/* =========================================================
   PANEL DERECHO
   ========================================================= */

.fp-form-panel {
    display: flex;
    flex: 1;
    align-items: center;
    min-width: 0;
    padding: 48px 68px;
}

.fp-form-content {
    width: 100%;
    max-width: 470px;
    margin: 0 auto;
}

.fp-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 34px;
}

.fp-logo {
    display: block;
    width: auto;
    max-width: 190px;
    max-height: 62px;
    object-fit: contain;
}

.fp-security-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--fp-muted);
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
}

.fp-security-label i {
    color: var(--fp-green);
    font-size: 16px;
}

.fp-eyebrow {
    margin: 0 0 9px;
    color: var(--fp-blue);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.fp-title {
    margin: 0 0 12px;
    color: var(--fp-text);
    font-family: "Montserrat", Arial, sans-serif;
    font-size: clamp(30px, 4vw, 40px);
    font-weight: 600;
    line-height: 1.15;
}

.fp-description {
    margin: 0 0 30px;
    color: var(--fp-muted);
    font-size: 16px;
    line-height: 1.65;
}

/* =========================================================
   CAMPOS
   ========================================================= */

.fp-form-group {
    margin: 0 0 22px;
}

.fp-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 9px;
    color: var(--fp-text);
    font-size: 14px;
    font-weight: 600;
}

.fp-label-help {
    color: var(--fp-muted);
    font-size: 12px;
    font-weight: 400;
}

.fp-input-wrapper {
    position: relative;
}

.fp-input-icon {
    position: absolute;
    top: 50%;
    left: 17px;
    z-index: 2;
    color: #8190A5;
    font-size: 20px;
    transform: translateY(-50%);
    pointer-events: none;
}

.fp-input {
    display: block;
    width: 100%;
    height: 56px;
    margin: 0;
    padding: 13px 17px 13px 49px;
    color: var(--fp-text);
    background: var(--fp-white);
    border: 1px solid var(--fp-border);
    border-radius: var(--fp-radius-small);
    outline: none;
    font-family: "Inter", Arial, sans-serif;
    font-size: 15px;
    line-height: 1.4;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.fp-input::placeholder {
    color: #98A2B3;
}

.fp-input:hover {
    border-color: var(--fp-border-hover);
}

.fp-input:focus {
    border-color: var(--fp-blue);
    box-shadow: 0 0 0 4px var(--fp-focus);
}

/* Corregir estilos de Bootstrap */

.fp-page .fp-input.form-control {
    height: 56px;
    margin: 0;
    background-color: var(--fp-white);
    border-radius: var(--fp-radius-small);
}

.fp-page .fp-input.form-control:focus {
    background-color: var(--fp-white);
    border-color: var(--fp-blue);
    box-shadow: 0 0 0 4px var(--fp-focus);
}

/* =========================================================
   CAPTCHA
   ========================================================= */

.fp-captcha {
    margin: 4px 0 0;
    padding: 19px;
    background: var(--fp-background);
    border: 1px solid rgba(30, 85, 163, 0.1);
    border-radius: var(--fp-radius-medium);
}

.fp-captcha-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 17px;
}

.fp-captcha-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 39px;
    height: 39px;
    color: var(--fp-blue);
    background: rgba(30, 85, 163, 0.1);
    border-radius: 50%;
    font-size: 20px;
}

.fp-captcha-title {
    margin: 0 0 4px;
    color: var(--fp-text);
    font-size: 14px;
    font-weight: 600;
}

.fp-captcha-description {
    margin: 0;
    color: var(--fp-muted);
    font-size: 12px;
    line-height: 1.5;
}

.fp-captcha-row {
    display: grid;
    grid-template-columns: max-content minmax(130px, 1fr);
    align-items: center;
    gap: 16px;
}

.fp-captcha-equation {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 56px;
    padding: 10px 18px;
    color: var(--fp-blue-dark);
    background: var(--fp-white);
    border: 1px solid var(--fp-border);
    border-radius: var(--fp-radius-small);
    font-family: "Montserrat", Arial, sans-serif;
    font-size: 19px;
    font-weight: 600;
    white-space: nowrap;
}

.fp-captcha-sign,
.fp-captcha-equals {
    color: var(--fp-muted);
    font-size: 18px;
    font-weight: 600;
}

.fp-captcha-result {
    min-width: 0;
}

.fp-captcha-result .fp-input {
    padding: 13px 16px;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
}

/* Eliminar controles del input number */

.fp-captcha-result input[type="number"]::-webkit-inner-spin-button,
.fp-captcha-result input[type="number"]::-webkit-outer-spin-button {
    margin: 0;
    appearance: none;
}

.fp-captcha-result input[type="number"] {
    appearance: textfield;
    -moz-appearance: textfield;
}

/* =========================================================
   BOTÓN
   ========================================================= */

.fp-submit-area {
    display: block;
    width: 100%;
    margin-top: 28px !important;
}

.fp-submit-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 56px;
    margin: 0;
    padding: 14px 25px;
    color: var(--fp-white);
    background: var(--fp-green);
    border: 1px solid var(--fp-green);
    border-radius: 999px;
    box-shadow: 0 12px 24px rgba(49, 168, 54, 0.2);
    font-family: "Inter", Arial, sans-serif;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.fp-submit-button:hover {
    color: var(--fp-white);
    background: var(--fp-green-hover);
    border-color: var(--fp-green-hover);
    box-shadow: 0 15px 30px rgba(49, 168, 54, 0.25);
    transform: translateY(-1px);
}

.fp-submit-button:focus {
    outline: none;
    box-shadow:
        0 0 0 4px rgba(49, 168, 54, 0.18),
        0 12px 24px rgba(49, 168, 54, 0.2);
}

.fp-submit-button:active {
    transform: translateY(0);
}

.fp-submit-button i {
    font-size: 19px;
}

/* =========================================================
   AVISO DE SEGURIDAD
   ========================================================= */

.fp-security-note {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    width: 100%;
    margin-top: 22px !important;
    padding: 15px 16px;
    color: var(--fp-muted);
    background: rgba(30, 85, 163, 0.055);
    border-left: 3px solid var(--fp-blue);
    border-radius: 0 11px 11px 0;
    font-size: 12px;
    line-height: 1.55;
}

.fp-security-note i {
    flex: 0 0 auto;
    margin-top: 1px;
    color: var(--fp-blue);
    font-size: 18px;
}

/* =========================================================
   MENSAJES DEL SISTEMA
   ========================================================= */

.fp-messages {
    margin-top: 20px;
}

.fp-messages:empty {
    display: none;
}

.fp-messages .alert {
    margin: 0 0 12px;
    border: 0;
    border-radius: 12px;
    font-size: 14px;
}

/* =========================================================
   REGRESAR AL LOGIN
   ========================================================= */

.fp-back-login {
    margin: 26px 0 0 !important;
    color: var(--fp-muted);
    font-size: 14px;
    text-align: center;
}

.fp-back-login a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 700;
}

/* =========================================================
   FOOTER
   ========================================================= */

.fp-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px 18px;
    margin-top: 32px;
    color: var(--fp-muted);
    font-size: 12px;
    text-align: center;
}

.fp-footer a {
    color: var(--fp-muted);
}

.fp-footer a:hover {
    color: var(--fp-blue);
}

.fp-footer-divider {
    width: 4px;
    height: 4px;
    background: #BCC5D0;
    border-radius: 50%;
}

/* =========================================================
   LOADER
   ========================================================= */

#divLoading {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(7, 23, 47, 0.78);
    backdrop-filter: blur(4px);
}

#divLoading > div {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 82px;
    height: 82px;
    background: var(--fp-white);
    border-radius: 22px;
    box-shadow: var(--fp-shadow);
}

#divLoading img {
    width: 44px;
    height: 44px;
}

#divLoading.show,
#divLoading.active,
#divLoading.visible {
    display: flex;
}

/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 991.98px) {
    .fp-page {
        padding: 24px;
    }

    .fp-layout {
        min-height: 720px;
    }

    .fp-visual {
        flex-basis: 41%;
    }

    .fp-visual-content {
        padding: 36px;
    }

    .fp-form-panel {
        padding: 42px 38px;
    }

    .fp-brand {
        margin-bottom: 30px;
    }

    .fp-benefits {
        display: none;
    }

    .fp-captcha-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .fp-captcha-equation {
        width: 100%;
    }
}

/* =========================================================
   MÓVIL
   ========================================================= */

@media (max-width: 767.98px) {
    .fp-page {
        align-items: flex-start;
        padding: 16px;
    }

    .fp-card {
        border-radius: 22px;
    }

    .fp-layout {
        display: block;
        min-height: auto;
    }

    .fp-visual {
        min-height: 240px;
    }

    .fp-visual-content {
        justify-content: flex-end;
        padding: 28px;
    }

    .fp-visual-title {
        margin-bottom: 8px;
        font-size: 29px;
    }

    .fp-visual-description {
        display: none;
    }

    .fp-portal-badge {
        margin-bottom: 12px;
    }

    .fp-form-panel {
        padding: 38px 28px;
    }

    .fp-brand {
        margin-bottom: 30px;
    }

    .fp-logo {
        max-width: 165px;
    }

    .fp-security-label {
        display: none;
    }
}

@media (max-width: 479.98px) {
    .fp-page {
        padding: 0;
        background: var(--fp-white);
    }

    .fp-page::before,
    .fp-page::after {
        display: none;
    }

    .fp-card {
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .fp-visual {
        min-height: 210px;
    }

    .fp-visual-content {
        padding: 23px;
    }

    .fp-portal-badge {
        padding: 7px 12px;
        font-size: 11px;
    }

    .fp-visual-title {
        font-size: 25px;
    }

    .fp-form-panel {
        padding: 32px 22px 38px;
    }

    .fp-title {
        font-size: 29px;
    }

    .fp-description {
        margin-bottom: 27px;
        font-size: 14px;
    }

    .fp-input,
    .fp-page .fp-input.form-control {
        height: 54px;
    }

    .fp-captcha {
        padding: 16px;
    }

    .fp-captcha-header {
        margin-bottom: 15px;
    }

    .fp-captcha-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .fp-captcha-equation {
        width: 100%;
        min-height: 52px;
    }

    .fp-submit-area {
        margin-top: 26px !important;
    }

    .fp-security-note {
        margin-top: 20px !important;
    }

    .fp-footer {
        flex-direction: column;
        gap: 7px;
    }

    .fp-footer-divider {
        display: none;
    }
}

/* =========================================================
   ACCESIBILIDAD
   ========================================================= */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}