/* ------------------------------------------------------------------------------
 *
 *  # Login redesign (QualiTab)
 *
 *  Fundo full-screen (background-copa) + card branco flutuante a esquerda.
 *  Carregado apenas no layout de login para nao afetar os demais modulos.
 *
 * ---------------------------------------------------------------------------- */

:root {
    --ql-orange: #D9622B;
    --ql-orange-dark: #c2541f;
    --ql-charcoal: #2f2e2c;
    --ql-muted: #8a8780;
    --ql-border: #e0ded8;
    --ql-field-bg: #fafaf8;
}

/* Reset do background full-screen antigo */
body.login-cover {
    background: #fff;
}

/* Container: imagem cobrindo toda a tela */
.ql-login {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    width: 100%;
    padding: 40px 7%;
    box-sizing: border-box;
    background: url('../images/background-copa-right.png') center / cover no-repeat;
    font-family: 'Roboto', sans-serif;
}

/* Leve overlay para harmonizar o fundo com o card */
.ql-login::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(20, 20, 22, .12);
}

/* ---- Card flutuante ---- */
.ql-login__card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 16px;
    padding: 44px 40px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .22);
}

/* Logo no topo do card */
.ql-login__form-logo {
    text-align: center;
    margin-bottom: 34px;
}

.ql-login__form-logo img {
    height: 160px;
    width: auto;
}

/* Cabecalho (titulo + subtitulo) */
.ql-login__heading {
    text-align: center;
    margin-bottom: 26px;
}

.ql-login__heading h1 {
    font-size: 20px;
    font-weight: 500;
    color: var(--ql-charcoal);
    margin: 0 0 6px;
}

.ql-login__heading p {
    font-size: 13px;
    line-height: 1.5;
    color: var(--ql-muted);
    margin: 0;
}

.ql-login__heading strong {
    color: var(--ql-charcoal);
    font-weight: 500;
}

/* Link "voltar para o login" */
.ql-login__back {
    text-align: center;
    margin-top: 18px;
}

.ql-login__back a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--ql-muted);
    text-decoration: none;
}

.ql-login__back a:hover {
    color: var(--ql-orange);
}

/* Campos */
.ql-field {
    margin-bottom: 18px;
}

.ql-field__label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #5f5e5a;
    margin-bottom: 7px;
}

.ql-field__control {
    position: relative;
}

.ql-field__control > .ql-field__icon {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #a8a59e;
    font-size: 16px;
    pointer-events: none;
}

.ql-field__control input.form-control {
    height: 44px;
    padding-left: 40px;
    padding-right: 40px;
    border: 1px solid var(--ql-border);
    border-radius: 8px;
    background: var(--ql-field-bg);
    color: var(--ql-charcoal);
    font-size: 14px;
    box-shadow: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.ql-field__control input.form-control:focus {
    border-color: var(--ql-orange);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(217, 98, 43, .12);
    outline: none;
}

.ql-field__toggle {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a8a59e;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.ql-field__toggle:hover {
    color: var(--ql-orange);
}

/* Link esqueceu senha */
.ql-login__forgot {
    text-align: right;
    margin-bottom: 22px;
}

.ql-login__forgot a {
    font-size: 12px;
    color: var(--ql-orange);
    text-decoration: none;
}

.ql-login__forgot a:hover {
    text-decoration: underline;
}

/* Botao principal */
.ql-login__submit {
    width: 100%;
    height: 46px;
    background: var(--ql-orange);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background .15s ease;
}

.ql-login__submit:hover,
.ql-login__submit:focus {
    background: var(--ql-orange-dark);
    color: #fff;
}

/* Rodape centralizado na base da tela */
.ql-login__footer {
    position: absolute;
    z-index: 1;
    left: 0;
    right: 0;
    bottom: 22px;
    text-align: center;
    font-size: 12px;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, .45);
}

.ql-login__footer a {
    color: #fff;
    font-weight: 500;
    text-decoration: none;
}

.ql-login__footer a:hover {
    text-decoration: underline;
}

/* Mensagens flash do CakePHP */
.ql-login__form .alert {
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 18px;
}

/* ---- Responsivo ---- */
@media (max-width: 600px) {
    .ql-login {
        justify-content: center;
        padding: 24px 18px 70px;
    }
    .ql-login__card {
        max-width: 380px;
        padding: 36px 26px;
    }
}
