@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --login-navy: #08224a;
    --login-navy-2: #0f3b78;
    --login-gold: #c58a11;
    --login-text: #0f172a;
    --login-muted: #64748b;
    --login-border: #dbe3ef;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-width: 320px;
    min-height: 100%;
}

body {
    margin: 0;
    overflow-x: hidden;
    color: var(--login-text);
    background: #f4f7fb;
    font-family: "Inter", "Segoe UI", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.login-page {
    position: relative;
    display: grid;
    min-height: 100dvh;
    grid-template-columns: minmax(320px, 0.92fr) minmax(390px, 0.78fr);
    place-content: center;
    align-items: center;
    gap: clamp(42px, 7vw, 100px);
    overflow: hidden;
    padding: clamp(34px, 5vw, 72px);
    background:
        linear-gradient(110deg, rgba(247,250,253,0.86), rgba(247,250,253,0.92)),
        url("../img/municipio-bg.jpg") center / cover no-repeat;
}

.login-page::before {
    position: absolute;
    inset: 0;
    pointer-events: none;
    content: "";
    background:
        radial-gradient(circle at 20% 48%, rgba(197,138,17,0.10), transparent 23rem),
        radial-gradient(circle at 78% 22%, rgba(37,99,235,0.08), transparent 20rem);
}

.login-left,
.login-card {
    position: relative;
    z-index: 1;
}

.login-left {
    width: 100%;
    max-width: 490px;
    justify-self: end;
    text-align: center;
}

.brand-card {
    padding: 28px;
}



.brand-card h1 {
    margin: 0;
    color: var(--login-navy);
    font-size: clamp(25px, 3vw, 32px);
    font-weight: 800;
    letter-spacing: -0.025em;
}

.brand-card h2 {
    margin: 6px 0 22px;
    color: var(--login-gold);
    font-size: clamp(19px, 2.4vw, 25px);
    font-weight: 700;
    letter-spacing: 0.13em;
}

.brand-card p {
    max-width: 355px;
    margin: 0 auto;
    color: var(--login-navy);
    font-size: 13px;
    line-height: 1.65;
}

.login-card {
    width: min(100%, 430px);
    justify-self: start;
    padding: clamp(28px, 4vw, 42px);
    border: 1px solid rgba(219,227,239,0.90);
    border-radius: 20px;
    background: rgba(255,255,255,0.95);
    box-shadow: 0 28px 70px rgba(8,34,74,0.18);
    backdrop-filter: blur(14px);
}

.login-card h3 {
    margin: 0 0 26px;
    color: var(--login-navy);
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.01em;
    text-align: center;
}

.alert-error {
    margin-bottom: 17px;
    padding: 12px 14px;
    border: 1px solid #fecaca;
    border-radius: 10px;
    color: #991b1b;
    background: #fee2e2;
    font-size: 12px;
    text-align: center;
}

.input-group {
    display: flex;
    height: 52px;
    align-items: center;
    margin-bottom: 14px;
    padding: 0 15px;
    border: 1px solid var(--login-border);
    border-radius: 11px;
    background: #ffffff;
    transition: border-color 180ms ease, box-shadow 180ms ease;
}

.input-group:focus-within {
    border-color: #8eaed8;
    box-shadow: 0 0 0 4px rgba(37,99,235,0.08);
}

.input-group span {
    margin-right: 11px;
    color: #8a9ab0;
}

.input-group input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    color: var(--login-text);
    background: transparent;
    font-size: 13px;
}

.input-group input::placeholder {
    color: #a0adbd;
}

.login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 7px 0 23px;
    color: var(--login-muted);
    font-size: 11px;
}

.login-options label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.login-options a {
    color: var(--login-navy);
    font-weight: 600;
    text-decoration: none;
}

.login-card button {
    width: 100%;
    height: 52px;
    border: 0;
    border-radius: 11px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--login-navy), var(--login-navy-2));
    box-shadow: 0 12px 24px rgba(8,34,74,0.22);
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.05em;
    transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.login-card button:hover {
    transform: translateY(-1px);
    background: linear-gradient(135deg, #0b2d60, #16488e);
    box-shadow: 0 15px 28px rgba(8,34,74,0.26);
}

.login-footer {
    margin-top: 28px;
    color: var(--login-muted);
    font-size: 10px;
    text-align: center;
}

@media (max-width: 900px) {
    .login-page {
        display: flex;
        min-height: 100dvh;
        flex-direction: column;
        justify-content: center;
        gap: 14px;
        padding: 24px 18px;
        background-position: 35% center;
    }

    .login-left,
    .login-card {
        width: 100%;
        max-width: 430px;
        justify-self: auto;
    }

    .brand-card {
        padding: 8px 20px 12px;
    }

    

    .brand-card h1 {
        font-size: 22px;
    }

    .brand-card h2 {
        margin-bottom: 10px;
        font-size: 17px;
    }

    .brand-card p {
        display: none;
    }

    .login-card {
        padding: 27px 22px;
        border-radius: 18px;
    }
}

@media (max-width: 480px) {
    .login-page {
        justify-content: center;
        padding-top: max(20px, env(safe-area-inset-top));
        padding-bottom: max(20px, env(safe-area-inset-bottom));
    }

    .login-card h3 {
        margin-bottom: 22px;
        font-size: 18px;
    }

    .login-options {
        align-items: center;
        font-size: 10px;
    }
}

/* =========================================================
   LOGOTIPO INSTITUCIONAL
========================================================= */

/* =========================================================
   LOGOTIPO INSTITUCIONAL
========================================================= */

.login-brand-logo {
    display: block;
    width: min(100%, 390px);
    height: 225px;
    margin: 0 auto 20px;
    object-fit: contain;
    mix-blend-mode: multiply;
    filter: drop-shadow(
        0 14px 24px rgba(8, 34, 74, 0.10)
    );
}

@media (max-width: 900px) {

    .login-brand-logo {
        width: min(100%, 270px);
        height: 145px;
        margin-bottom: 8px;
    }

}

@media (max-width: 480px) {

    .login-brand-logo {
        width: min(100%, 225px);
        height: 118px;
        margin-bottom: 5px;
    }

}