* {
    box-sizing: border-box;
}

.login-body {
    min-height: 100vh;
    margin: 0;
    background: linear-gradient(135deg, #eef3ff, #f8fbff);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    font-family: Arial, sans-serif;
}

.login-shell {
    width: 100%;
    max-width: 430px;
    min-height: 720px;
    background: white;
    border-radius: 34px;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(15, 23, 42, 0.18);
}

.login-hero {
    min-height: 300px;
    background: linear-gradient(160deg, #2720c9, #4aa3df);
    color: white;
    padding: 34px 30px;
    position: relative;
    overflow: hidden;
}

.login-hero::before {
    content: "";
    position: absolute;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    top: -80px;
    left: -70px;
}

.login-hero::after {
    content: "";
    position: absolute;
    width: 130px;
    height: 130px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.14);
    bottom: -45px;
    right: -35px;
}

.hero-logo {
    width: 170px;
    background: white;
    border-radius: 24px;
    padding: 14px;
    margin-bottom: 34px;
    position: relative;
    z-index: 2;
}

.hero-logo img {
    width: 100%;
    display: block;
}

.login-hero h1 {
    position: relative;
    z-index: 2;
    font-size: 44px;
    margin: 0 0 6px 0;
    font-weight: 900;
}

.login-hero p {
    position: relative;
    z-index: 2;
    font-size: 17px;
    line-height: 1.4;
    max-width: 320px;
    opacity: 0.95;
    margin: 0;
}

.login-panel {
    background: white;
    padding: 34px 30px 28px;
    border-radius: 34px 34px 0 0;
    margin-top: -28px;
    position: relative;
    z-index: 5;
}

.login-panel-header h2 {
    color: #1f1bb8;
    font-size: 30px;
    margin: 0 0 6px 0;
}

.login-panel-header p {
    color: #64748b;
    margin: 0 0 26px 0;
    font-size: 15px;
    line-height: 1.4;
}

.login-alert {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
    border-radius: 14px;
    padding: 12px 14px;
    font-weight: 700;
    margin-bottom: 18px;
    line-height: 1.35;
}

.login-group {
    margin-bottom: 18px;
}

.login-group label {
    display: block;
    color: #1e293b;
    font-weight: 800;
    margin-bottom: 8px;
    font-size: 14px;
}

.login-group input:not(.codigo-input) {
    width: 100%;
    padding: 15px 16px;
    border: 1px solid #d6e0ee;
    border-radius: 999px;
    background: #f8fafc;
    font-size: 15px;
    outline: none;
    transition: 0.2s;
}

.login-group input:not(.codigo-input):focus {
    background: white;
    border-color: #312cff;
    box-shadow: 0 0 0 4px rgba(49, 44, 255, 0.12);
}

.btn-login {
    width: 100%;
    border: none;
    border-radius: 999px;
    padding: 15px;
    margin-top: 10px;
    background: linear-gradient(135deg, #3f2bff, #4aa3df);
    color: white;
    font-size: 16px;
    font-weight: 900;
    cursor: pointer;
    transition: 0.25s;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 22px rgba(63, 43, 255, 0.25);
}

.btn-secondary {
    border: none;
    background: #eef3ff;
    color: #312cff;
    cursor: pointer;
    transition: 0.25s;
}

.btn-secondary:hover {
    background: #dfe8ff;
    transform: translateY(-1px);
}

.login-footer {
    margin-top: 28px;
    text-align: center;
    color: #94a3b8;
    font-size: 14px;
}

.password-wrapper {
    position: relative;
}

.password-wrapper input {
    width: 100%;
    padding-right: 52px;
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
}

/* CÓDIGO DE VERIFICACIÓN EN CUADRITOS */
.login-group .codigo-boxes {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 12px;
    width: 100%;
}

.login-group .codigo-input {
    width: 54px;
    max-width: 54px;
    min-width: 54px;
    height: 58px;
    padding: 0;
    border: 2px solid #d7def0;
    border-radius: 14px;
    text-align: center;
    font-size: 24px;
    font-weight: 900;
    color: #1e293b;
    background: #ffffff;
    outline: none;
    transition: all 0.2s ease;
}

.login-group .codigo-input:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.14);
}

.login-group .codigo-input.error {
    border-color: #dc2626;
    background: #fef2f2;
}

.codigo-separador {
    font-size: 30px;
    font-weight: 900;
    color: #64748b;
    line-height: 1;
    margin: 0 2px;
}

/* ESCRITORIO */
@media (min-width: 900px) {
    .login-shell {
        max-width: 980px;
        min-height: 560px;
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .login-hero {
        min-height: 560px;
        padding: 55px 50px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .hero-logo {
        width: 230px;
        margin-bottom: 40px;
    }

    .login-hero h1 {
        font-size: 52px;
    }

    .login-panel {
        margin-top: 0;
        border-radius: 0;
        padding: 70px 55px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
}

/* CELULAR */
@media (max-width: 480px) {
    .login-body {
        padding: 0;
        align-items: stretch;
    }

    .login-shell {
        min-height: 100vh;
        border-radius: 0;
        box-shadow: none;
    }

    .login-hero {
        min-height: 285px;
        padding: 28px 24px;
    }

    .hero-logo {
        width: 145px;
        margin-bottom: 28px;
    }

    .login-hero h1 {
        font-size: 38px;
    }

    .login-hero p {
        font-size: 15px;
    }

    .login-panel {
        padding: 30px 24px;
    }

    .login-group .codigo-boxes {
        gap: 7px;
    }

    .login-group .codigo-input {
        width: 42px;
        max-width: 42px;
        min-width: 42px;
        height: 50px;
        font-size: 21px;
        border-radius: 12px;
    }

    .codigo-separador {
        font-size: 24px;
        margin: 0 1px;
    }
}
.login-group input#codigoCompleto {
    display: none !important;
}

.login-group .codigo-boxes {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    margin-top: 14px !important;
}

.login-group .codigo-grupo {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}

.login-group .codigo-boxes input.codigo-input {
    width: 52px !important;
    min-width: 52px !important;
    max-width: 52px !important;
    height: 58px !important;
    padding: 0 !important;
    border: 2px solid #d7def0 !important;
    border-radius: 10px !important;
    background: #f8fafc !important;
    text-align: center !important;
    font-size: 26px !important;
    font-weight: 900 !important;
    color: #1e293b !important;
    outline: none !important;
    box-shadow: none !important;
}

.login-group .codigo-boxes input.codigo-input:focus {
    background: #ffffff !important;
    border-color: #312cff !important;
    box-shadow: 0 0 0 4px rgba(49, 44, 255, 0.14) !important;
}

.login-group .codigo-boxes input.codigo-input.error {
    border-color: #dc2626 !important;
    background: #fef2f2 !important;
}

.codigo-separador {
    font-size: 30px !important;
    font-weight: 900 !important;
    color: #64748b !important;
    line-height: 1 !important;
    margin: 0 2px !important;
}

@media (max-width: 480px) {
    .login-group .codigo-boxes {
        gap: 8px !important;
    }

    .login-group .codigo-grupo {
        gap: 6px !important;
    }

    .login-group .codigo-boxes input.codigo-input {
        width: 40px !important;
        min-width: 40px !important;
        max-width: 40px !important;
        height: 48px !important;
        font-size: 22px !important;
        border-radius: 9px !important;
    }

    .codigo-separador {
        font-size: 24px !important;
    }
}
.login-extra {
    text-align: right;
    margin-top: -6px;
    margin-bottom: 14px;
}

.forgot-link {
    color: #312cff;
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
}

.forgot-link:hover {
    text-decoration: underline;
}
.password-wrapper {
    position: relative;
}

.password-wrapper input {
    width: 100%;
    padding-right: 52px;
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
}