
/* login.css */

@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;700;800&display=swap");

:root {
    --cor-padrao:           #15489e;
    --cor-padrao-hover:     #0094da;
    --cor-btn-border:       #435ebe;
    --cor-btn-border-hover: #0074aa;
    --cor-footer:           #435ebe;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background: #EAEEF4;
    font-family: "Montserrat", sans-serif;
    min-height: 100vh;
    position: relative;
}

.card {
    width: 550px;
    height: 577.15px;
    background-color: #FFFFFF80;
    border-radius: 10px;
    box-shadow: 0px 4px 4px 4px rgba(0, 0, 0, 0.2);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -60%);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    gap: 1rem;
    overflow: hidden;
    padding: 30px 30px;
}

/* ── BRASÃO ── */
.brasao {
    width: 250px;
    height: 150px;
    margin-top: 28px;
    object-fit: contain;
    margin-bottom: 10px;
    transition: width 0.1s ease;
}

/* ── SUBTÍTULO ── */
.subtitulo {
    font-size: 20px;
    font-weight: 500;
    line-height: 22px;
    letter-spacing: 0.5px;
    color: #030303;
    text-align: center;
    margin: 8px 0 12px;
    margin-top: 0px;
    max-width: 400px;
    font-family: "Montserrat", sans-serif;
}

.destaque-subtitulo{
    display: block;
    color: #1f3b8b;
    font-size: 25px;
    font-weight: 800;
    margin-top: 4px;
    letter-spacing: 0.5px;
}

/* ── CAMPOS ── */
.campo {
    width: 85%;
    margin-bottom: 25px;
    margin-top: 5px;
}

/* Input group */
.input-wrap {
    display: flex;
    align-items: center;
    box-shadow: 0px 6px 6px 0px rgba(0, 0, 0, 0.25);
    border-radius: 8px;
    width: 100%;
    height: 44px;
    overflow: hidden;
    background: #fff;
    border: none;
    font-size: 15px;
    margin-top: 0px;
    font-family: Arial, Helvetica, sans-serif;
}

.input-wrap .icone {
    color: #15489e;
    background-color: #fff;
    border-radius: 10px 0 0 10px;
    height: 100%;
    padding: 0 20px;
    display: flex;
    align-items: center;
    font-size: 1.5em;
    min-width: 1.5em;
    max-width: 2.5em;
    flex-shrink: 0;
    pointer-events: none;
}

.input-wrap input {
    flex: 1;
    height: 100%;
    border: none;
    outline: none;
    background-color: #fff;
    font-size: 15px;
    font-family: "Montserrat", sans-serif;
    color: #333;
    padding: 0 3px;
}

/* Linha fina azul ao redor do grupo inteiro quando o input estiver em foco */
.input-wrap:focus-within {
    box-shadow: 0px 6px 6px 0px rgba(0, 0, 0, 0.25), 0 0 0 1.0px #3a6fca; 
    border-radius: 8px;
    outline: none; 
}

/* Remove qualquer borda ou outline do input interno */
.input-wrap input:focus {
    outline: none;
    border: none;
}

.input-wrap input::placeholder { color: #aab0c0; }

.toggle-senha {
    background-color: #fff;
    color: #15489e;
    border: none;
    height: 38px;
    width: 38px;
    border-radius: 8px;
    font-size: 17px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}
.toggle-senha:hover { color: var(--cor-padrao-hover); }

/* ── BOTÃO ── */
.login-button {
    border: 1px solid transparent;
    border-radius: 0.25rem;
    background-color: #15489e;
    border-color: #435ebe;
    color: white;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    padding: 0.375rem 0.75rem !important;
    text-align: center;
    text-decoration: none;
    transition: color 0.15s ease-in-out;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-family: "Montserrat", sans-serif;
    margin-top: 10px;

}

#login-button:active  { transform: scale(0.95); }
#login-button:focus   { outline: none; }
#login-button:hover   {
    background-color: var(--cor-padrao-hover);
    border-color: var(--cor-btn-border-hover);
}


/* Spinner */
.spinner {
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.35);
    border-top-color: white;
    border-radius: 50%;
    margin-left: 8px;
    animation: spin 0.65s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
#login-button.carregando .spinner   { display: block; }


/* ── FOOTER (fixo) ── */
.footer {
    position: fixed;
    bottom: 40px;           
    left: 0;
    right: 0;
    text-align: center;
    font-family: "Montserrat", sans-serif;
    font-size: 13.8px;
}

.footer-link {
    color: #808080;           
    text-decoration: none;    
    background: transparent;
}

.footer-link:hover {
    color: #808080;           
    text-decoration: none;    
}

/* ── RESPONSIVO MOBILE ── */

@media (max-width: 500px) {
    body {
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 100vh;
        padding: 20px 16px 60px;
    }

    .card {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: 100%;
        height: auto;
        padding: 28px 20px 32px;
    }

    .brasao {
        width: 130px;
        height: auto;
        margin-top: 0;
        margin-bottom: 8px;
    }

    .subtitulo {
        font-size: 14px;
        margin-bottom: 16px;
    }

    .input-wrap {
        height: 48px;
    }

    .input-wrap .icone {
        font-size: 1.2rem;
        padding: 0 12px;
    }

    .toggle-senha {
        width: 44px;
    }

    .footer {
        font-size: 11px;
        padding: 8px 0;
    }
}

@media (max-width: 360px) {
    .card {
        padding: 20px 16px 28px;
    }

    .brasao {
        width: 105px;
    }

    .subtitulo {
        font-size: 12px;
    }

    .input-wrap {
        height: 44px;
    }

    .input-wrap .icone {
        font-size: 1rem;
        padding: 0 10px;
    }

    .login-button {
        font-size: 0.85rem;
    }
}

@media (max-height: 650px) and (max-width: 500px) {
    body {
        align-items: flex-start;
        padding-top: 20px;
    }

    .brasao {
        width: 100px;
        margin-bottom: 4px;
    }

    .subtitulo {
        font-size: 12px;
        margin-bottom: 10px;
    }

    .campo {
        margin-bottom: 12px;
    }

    .input-wrap {
        height: 42px;
    }

    .login-button {
        margin-top: 4px;
    }
}

/* ── ALERTA LOGIN ── */
.login-alert {
    width: 97%;
    background: #fff3f3;
    color: #d32f2f;
    border-left: 4px solid #d32f2f;
    margin-top: 15px;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 14px;
    margin-bottom: 10px;
    text-align: left;
    font-family: "Montserrat", sans-serif;
    animation: fadeIn 0.3s ease;
}

/* animação suave */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}