/* ============================================
   LOGIN / RECUPERAR CONTRASEÑA - BOXEANDO POR LA PAZ
   ============================================ */
* { box-sizing: border-box; }

body {
    font-family: "Montserrat", sans-serif;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    background: linear-gradient(180deg, #FFFFFF 40%, #EFE1CB);
    min-height: 100vh;
}
main { max-width: 100%; overflow-x: hidden; }
p { margin-bottom: 0; }
a, a:hover, a:focus { text-decoration: none; outline: none; }
button { outline: none; border: 0; cursor: pointer; background: transparent; }

/* --- HEADER --- */
header.gmx { height: 116px; }

nav#menuOficinas {
    display: block;
    background: white;
    width: 100%;
    text-align: center;
    top: 58px;
    height: 60px;
    position: fixed;
    z-index: 999;
}
.topnav {
    max-width: 100% !important;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: auto;
    text-align: left;
    height: 60px;
    overflow: visible;
    margin-bottom: 0;
}
.topnav a {
    float: left;
    display: block;
    color: #e43250;
    text-align: center;
    padding: 14px 10px;
    text-decoration: none;
    font-size: 1.3rem;
    font-weight: 600;
}
#logojovenes {
    display: flex;
    align-items: center;
    gap: 12px;
    background: white;
    padding: 8px 15px;
    height: 60px;
    border-radius: 0px 0px 20px 0px;
    flex-shrink: 1;
    min-width: 0;
    overflow: hidden;
    cursor: default;
}
.logojovenes__divider {
    display: inline-block;
    width: 1px;
    height: 30px;
    background-color: #ccc;
    flex-shrink: 0;
}
.logostps { height: 40px; flex-shrink: 1; min-width: 0; object-fit: contain; }
.logobienestar { height: 40px; flex-shrink: 1; min-width: 0; object-fit: contain; }
.logojcf  { height: 40px; flex-shrink: 1; min-width: 0; object-fit: contain; }
.logowbc  { height: 40px; flex-shrink: 1; min-width: 0; object-fit: contain; }

#btnDer { position: relative; flex-shrink: 0; }

.btn_inicio {
    position: relative;
    width: 200px;
    height: 60px;
    padding: 10px;
    text-align: center;
    background-color: #9F2241;
    transition: 1s background;
}
.tit_der {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    color: white;
    font-weight: 700;
    text-align: center;
    font-size: 18px;
    margin-bottom: 0;
}
.dos {
    position: absolute;
    background: #9F2241;
    top: 50%;
    transform: translateY(-50%);
    left: -20px;
    margin: 0 auto;
    width: 45px;
    height: 45px;
    border-radius: 100px;
    transition: 1s background;
}
.img_enlace_dere {
    width: 31px;
    margin-top: 7px;
    transition: transform 1.5s ease-in-out;
}
.btn_inicio:hover,
.btn_inicio:hover .dos { background: #691C32; }
.btn_inicio:hover .img_enlace_dere { transform: rotate(360deg); }

/* --- LAYOUT PRINCIPAL --- */
.login-page {
    display: flex;
    min-height: calc(100vh - 116px);
    width: 100%;
}

/* === COLUMNA IZQUIERDA === */
.login-page__left {
    flex: 0 0 35%;
    max-width: 35%;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}
.login-page__left-bg {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    z-index: 0;
}
/* Recuadro blanco con borde dorado */
.login-page__brand-card {
    position: relative;
    z-index: 2;
    background: #FFFFFF;
    border: 5px solid #BC955C;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.18);
    padding: 18px 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    max-width: 85%;
}
.login-page__brand-logo {
    width: 100%;
    max-width: 230px;
    height: auto;
}
/* Boxeador encima del recuadro */
.login-page__boxer {
    position: relative;
    z-index: 1;
    width: 70%;
    max-width: 320px;
    height: auto;
    margin-bottom: -10px;
    object-fit: contain;
}

/* === COLUMNA DERECHA === */
.login-page__right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 30px;
    background: linear-gradient(180deg, #FFFFFF 40%, #EFE1CB);
}

/* --- CAJA DE LOGIN / RECUPERACIÓN --- */
.login_box {
    max-width: 420px;
    width: 100%;
    padding: 18px;
    background: #9F2241;
    border-radius: 25px;
    box-shadow: 0px 2px 12px 0px rgba(0,0,0,0.18);
}
.box_int {
    background: white;
    border-radius: 20px;
    overflow: hidden;
}
.box_int__header {
    background: linear-gradient(180deg, #9F2241 0%, #691C32 100%);
    padding: 22px 20px 18px;
    text-align: center;
}
.box_int__header h2 {
    color: #fff;
    font-size: 1.6rem;
    font-weight: 900;
    letter-spacing: 2px;
    margin: 0;
    text-transform: uppercase;
}
.box_int__subtitle {
    color: #fff;
    font-size: 0.75rem;
    font-weight: 400;
    margin-top: 6px;
    opacity: 0.9;
}
.box_info {
    padding: 22px 20px 18px;
}
.boxInput {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    padding: 0 5px;
}
.iconLogin { flex-shrink: 0; width: 38px; }
.img_cred { width: 35px; }
.inputLogin { flex: 1; }
.inp {
    border: none;
    border-bottom: 2px solid #BC955C;
    padding: 8px 10px;
    outline: none;
    background-color: white;
    width: 100%;
    font-size: .85rem;
    font-weight: 500;
    color: #4d4d4d;
    font-family: "Montserrat", sans-serif;
}
.inp:focus { font-weight: 600; }
.inp::placeholder { color: #999; }

/* reCAPTCHA */
.login-recaptcha {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 14px 0 18px;
}

/* Botones */
.form-actions {
    text-align: center;
    padding: 0 10px;
}
.btn_gral {
    position: relative;
    min-width: 200px;
    border: 2.5px solid;
    border-radius: 15px;
    padding: 10px 15px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 700;
    background: transparent;
    transition: .5s background, .5s color;
    font-family: "Montserrat", sans-serif;
    cursor: pointer;
}
.btn_gral p { margin-bottom: 0; padding-right: 30px; }
.btn_ginda { border-color: #9f2241; color: #9f2241; }
.btn_ginda:hover { background: #9f2241; color: white; }
.next {
    -webkit-mask: url("../imgs/NEXT.svg") no-repeat;
    mask: url("../imgs/NEXT.svg") no-repeat;
    float: left;
    background: #9f2241;
}
.btn_ginda:hover .next { background: white; }
.icon-prim {
    position: absolute;
    top: 7px;
    right: 30px;
    width: 25px;
    height: 25px;
    transition: .5s background;
}

/* Enlace recuperar contraseña (login) */
.btnrecupera {
    color: #BC955C;
    background: none;
    text-decoration: none;
    padding: 0px;
    margin: 10px auto;
    display: block;
    font-size: .8rem;
    font-weight: 700;
    transition: .5s color;
    text-align: center;
}
.btnrecupera:hover { color: #9F2241; }

/* Enlace volver (recuperar contraseña) */
.btn-volver {
    color: #BC955C;
    background: none;
    text-decoration: none;
    padding: 0px;
    margin: 12px auto;
    display: block;
    font-size: .8rem;
    font-weight: 700;
    transition: .5s color;
    text-align: center;
}
.btn-volver:hover { color: #9F2241; }

/* Cerrar sesión */
.logout-wrap {
    text-align: center;
    padding: 60px 20px;
}
.logout-wrap button {
    background: #9F2241;
    color: #fff;
    border: none;
    padding: 12px 30px;
    border-radius: 15px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    font-family: "Montserrat", sans-serif;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media all and (max-width: 768px) {
    .topnav { height: auto; }
    #logojovenes { gap: 8px; padding: 6px 10px; height: 50px; }
    .logojovenes__divider { height: 24px; }
    .logostps { height: 28px; }
    .logobienestar { height: 28px; }
    .logojcf  { height: 28px; }
    .logowbc  { height: 28px; }
    .btn_inicio { width: 120px; height: 50px; padding: 6px; }
    .tit_der { font-size: 11px; right: 5px; }
    .dos { left: -15px; width: 32px; height: 32px; }
    .img_enlace_dere { width: 16px !important; margin-top: 5px; }
}

@media all and (max-width: 992px) {
    .login-page {
        flex-direction: column;
    }
    .login-page__left {
        flex: none;
        max-width: 100%;
        width: 100%;
        min-height: 350px;
        flex-direction: column;
        align-items: center;
        justify-content: flex-end;
    }
    .login-page__boxer {
        width: 45%;
        max-width: 250px;
    }
    .login-page__brand-card {
        max-width: 280px;
        padding: 14px 20px;
        margin-bottom: 20px;
    }
    .login-page__right {
        padding: 30px 20px 40px;
    }
}

@media all and (max-width: 576px) {
    header.gmx { height: auto; min-height: 100px; }
    nav#menuOficinas { top: 50px; height: auto; }
    .topnav { height: auto; }

    .login-page__left {
        min-height: 280px;
    }
    .login-page__boxer {
        width: 50%;
        max-width: 200px;
    }
    .login-page__brand-card {
        max-width: 220px;
        padding: 12px 16px;
        margin-bottom: 15px;
    }
    .login-page__brand-logo {
        max-width: 170px;
    }
    .login_box {
        max-width: 100%;
        padding: 12px;
    }
    .box_int__header h2 {
        font-size: 1.2rem;
    }
    .box_info {
        padding: 18px 14px 14px;
    }
}

@media all and (max-width: 480px) {
    nav#menuOficinas { height: auto; }
    .topnav { flex-wrap: wrap; height: auto; }
    #logojovenes { gap: 6px; padding: 5px 8px; height: auto; min-height: 40px; flex: 1 1 auto; border-radius: 0; }
    .logojovenes__divider { height: 18px; }
    .logostps { height: 20px; }
    .logobienestar { height: 20px; }
    .logojcf  { height: 20px; }
    .logowbc  { height: 20px; }
    #btnDer { flex: 0 0 auto; }
    .btn_inicio { width: auto; min-width: 70px; height: 40px; padding: 4px 8px; }
    .tit_der { font-size: 8px; position: relative; top: auto; right: auto; transform: none; }
    .dos { display: none; }
}
