/* RESET */
* {
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

/* BODY NEUTRO PARA O SISTEMA */
body {
    margin: 0;
    background: #F4F6F8;
    opacity: 0;
    transition: opacity 0.6s ease;
}

body.loaded {
    opacity: 1;
}

/* FUNDO AZUL SOMENTE NO LOGIN */
.login-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #0F4C75, #1FA2D6);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* BOX LOGIN */
.login-box {
    background: #ffffff;
    width: 380px;
    border-radius: 10px;
    padding: 35px 30px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.25);
    text-align: center;
    border-top: 6px solid #1FA2D6;
    opacity: 0;
    transform: translateY(25px) scale(0.98);
    transition: all 0.5s ease;
}

.login-box.show {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* LOGO COM EFEITO HOVER */
.login-box img {
    transition: all 0.3s ease;
    cursor: pointer;
    max-width: 220px;
    margin-bottom: 20px;
    border-radius: 10%;
}

.login-box img:hover {
    box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.25);
    transform: translateY(-1px);
}

.login-box img:active {
    transform: translateY(-2px);
}

/* BOTÃO GENÉRICO */
.formBtn {
    cursor: pointer;
    border: none;
    border-radius: 2rem;
    text-transform: uppercase;
    color: #0F4C75;
    font-size: 0.9rem;
    font-weight: 600;
    background-color: #1FA2D6;
    padding: 0.9rem 3.5rem;
    transition: all 0.3s ease;
    min-height: 44px;
}

.formBtn:hover {
    box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.25);
    transform: translateY(-2%);
}

.formBtn:active {
    transform: translateY(0);
}

/* TÍTULO */
.login-box h2 {
    color: #0F4C75;
    margin-bottom: 25px;
    font-weight: bold;
    font-size: 20px;
}

/* WRAP SENHA */
.password-wrap {
    position: relative;
    width: 100%;
}

/* INPUTS */
.login-box input {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 15px;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 14px;
    outline: none;
    transition: all 0.25s ease;
}

.login-box input:focus {
    border-color: #1FA2D6;
    box-shadow: 0 0 0 2px rgba(31,162,214,0.15);
    transform: translateY(-1px);
}

/* INPUT DE SENHA COM ESPAÇO PARA ÍCONE */
.password-wrap input {
    padding-right: 42px;
}

/* ÍCONE MOSTRAR/OCULTAR SENHA */
.toggle-password {
    position: absolute;
    right: 12px;
    top: 40%;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 16px;
    opacity: 0.65;
    transition: opacity 0.2s ease;
    user-select: none;
    line-height: 1;
}

.toggle-password:hover {
    opacity: 1;
}

/* BOTÃO LOGIN */
.login-box button {
    width: 100%;
    padding: 12px;
    background: #0F4C75;
    border: none;
    color: #ffffff;
    font-size: 16px;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.3s;
    font-weight: bold;
    min-height: 44px;
}

.login-box button:hover {
    background: #083354;
    box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.25);
    transform: translateY(-2px);
}

.login-box button:active {
    transform: translateY(0);
}

.login-box button.loading {
    pointer-events: none;
    opacity: 0.8;
}

/* SPINNER */
.btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid #fff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
    animation: spin 0.7s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* MENSAGEM DE ERRO */
.login-box .error {
    background: #ffe5e5;
    color: #b30000;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 14px;
}

/* MENSAGEM DE SUCESSO */
.login-box .success {
    background: #e0f9e0;
    color: #1b5e20;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 14px;
}

/* LINK "ESQUECI MINHA SENHA" */
.esqueci-senha {
    margin-top: 10px;
    text-align: center;
}

.esqueci-senha a {
    color: #0F4C75;
    font-size: 14px;
    text-decoration: none;
    transition: 0.3s;
    display: inline-block;
}

.esqueci-senha a:hover {
    text-decoration: underline;
    color: #083354;
}

/* RESPONSIVO */
@media (max-width: 480px) {
    .login-box {
        width: 90%;
        padding: 30px 20px;
    }

    .login-box img {
        max-width: 180px;
    }

    .toggle-password {
        right: 10px;
        font-size: 15px;
    }
}