/* ==========================================================
   PÁGINAS DE AUTENTICAÇÃO (LOGIN E CADASTRO) - TABLE
========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Ledger&family=Montserrat:ital,wght@0,100..900;1,100..900&family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap');
:root {
    --fundo-pagina-inicio: #492499;
    --fundo-pagina-fim: #190e35;
    --fundo-cartao: #ffffff;
    --cor-primaria: #5b2be0;
    --cor-secundaria: #311C81;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Montserrat", sans-serif;
}

html {
    scroll-behavior: smooth;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #1f1a2c;
}

::-webkit-scrollbar-thumb {
    background-color: #4a4063;
    border-radius: 10px;
    border: 2px solid #1f1a2c;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #5b507a;
}


/* ==========================================================
   FUNDO ANIMADO (EFEITO ONDA/GRADIENTE)
========================================================== */

body.pagina-autenticacao {
    min-height: 100vh;
    margin: 0;
    /* Gradiente com múltiplas cores da paleta para criar o efeito */
    background: linear-gradient(-45deg, var(--fundo-pagina-inicio), var(--fundo-pagina-fim), var(--cor-primaria), var(--cor-secundaria));
    /* Aumenta o tamanho do fundo para permitir a movimentação */
    background-size: 400% 400%;
    /* Aplica a animação contínua */
    animation: moverOndasGradiente 15s ease infinite;
    /* Trava o fundo na viewport, evitando cortes no scroll */
    background-attachment: fixed;
    color: #525252;
}

.pagina-autenticacao a {
    color: #000;
    text-decoration: none;
}

.pagina-autenticacao a:hover {
    color: color-mix(in srgb, #000, white 20%);
}

.autenticacao-wrapper {
    min-height: 100vh;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    box-sizing: border-box;
}

.autenticacao-caixa {
    background-color: var(--fundo-cartao);
    padding: 30px;
    border-radius: 50px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
    text-align: center;
    width: 100%;
    max-width: 600px;
}

.autenticacao-caixa .logotipo {
    width: 250px;
    height: auto;
    margin: 0 auto 20px auto;
    display: block;
}

.autenticacao-caixa h2 {
    font-size: 2em;
    margin-bottom: 20px;
    text-align: left;
    color: #000;
}

.grupo-formulario {
    margin-bottom: 20px;
    text-align: left;
}

.grupo-formulario label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #525252;
}

.grupo-input {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icone {
    position: absolute;
    left: 14px;
    color: #a3a3a3;
    font-size: 1.1em;
    z-index: 3;
}

.grupo-formulario input {
    width: 100%;
    padding: 12px 15px 12px 40px;
    border: 1px solid #dcdcdc;
    border-radius: 10px;
    background-color: #fafafa;
    color: #525252;
    font-size: 1em;
    transition: all 0.25s ease;
}

.grupo-formulario input[type="password"] {
    padding-right: 45px !important;
}

.grupo-formulario input::placeholder {
    color: #9c9c9c;
    opacity: 1;
}

.grupo-formulario input:focus {
    outline: none;
    background-color: #fff;
    border-color: #492499;
    box-shadow: 0 0 0 4px rgba(115, 59, 246, 0.15);
}

.botao-cheio {
    width: 100%;
    margin-top: 20px;
    padding: 15px;
    font-size: 1.1em;
}

.botao-gradiente {
    background: linear-gradient(270deg, #6539C7, #311C81, #6539C7);
    background-size: 200% 200%;
    color: white;
    border-radius: 1000px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: gradientFlow 4s linear infinite;
}

.botao-gradiente:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(73, 36, 153, 0.35);
}

.botao-gradiente:active {
    transform: translateY(0);
    box-shadow: 0 3px 8px rgba(73, 36, 153, 0.25);
}

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.autenticacao-link {
    margin-top: 20px;
    font-size: 0.95em;
    color: #525252;
}

.autenticacao-link a {
    color: #000;
    font-weight: 600;
}

.senha-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.alternar-senha {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #a3a3a3;
    cursor: pointer;
    font-size: 1.1em;
    transition: color 0.2s ease;
    z-index: 3;
}

.alternar-senha:hover {
    color: var(--cor-primaria);
}

.erro-validacao {
    color: #e74c3c;
    font-size: 0.9em;
    margin-top: 5px;
    display: block;
    height: 1.2em;
}

.erro-validacao:empty {
    display: none;
}


/* ==========================================================
   FIX PARA FONT AWESOME
========================================================== */

.fas,
.fa-solid,
.fa-brands,
.far,
.fa-regular {
    font-family: "Font Awesome 6 Free" !important;
}


/* ==========================================================
   KEYFRAMES PARA O FUNDO ONDULADO
========================================================== */

@keyframes moverOndasGradiente {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}