/* =====================================================================
   Auth forms stylesheet — Colégio Progresso
   Covers allauth login / signup / password / email pages rendered
   inside the site layout (templates/account/*.html overrides).
   ===================================================================== */

.auth-section {
    min-height: calc(100vh - 90px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 7.5rem 1rem 4rem;
    background:
        linear-gradient(135deg, rgba(6, 137, 132, 0.92) 0%, rgba(4, 102, 99, 0.96) 100%),
        url('https://images.unsplash.com/photo-1580582932707-520aed937b7b?auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    background: #FFFFFF;
    border-radius: 18px;
    box-shadow: 0 30px 60px rgba(4, 40, 39, 0.35);
    overflow: hidden;
    animation: authRise 0.5s ease both;
}

@keyframes authRise {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-card-header {
    background: linear-gradient(135deg, #068984 0%, #046663 100%);
    color: #FFFFFF;
    padding: 2rem 2rem 1.75rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.auth-card-header::after {
    content: '';
    position: absolute;
    inset: auto -30% -70% -30%;
    height: 120%;
    background: radial-gradient(circle at center, rgba(252, 232, 8, 0.22), transparent 65%);
    pointer-events: none;
}

.auth-card-header .auth-logo {
    width: 74px;
    height: 74px;
    object-fit: contain;
    background: #FFFFFF;
    border-radius: 50%;
    padding: 8px;
    margin: 0 auto 0.85rem;
    display: block;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    z-index: 1;
}

.auth-card-header h1,
.auth-card-header h2,
.auth-card-header .auth-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    position: relative;
    z-index: 1;
}

.auth-card-header .auth-subtitle {
    font-size: 0.9rem;
    opacity: 0.9;
    margin: 0.35rem 0 0;
    position: relative;
    z-index: 1;
}

.auth-card-body {
    padding: 2rem;
}

/* ---- allauth renders fields inside <p> via form.as_p ---- */
.auth-card-body form p,
.auth-card-body .auth-field {
    margin-bottom: 1.15rem;
}

.auth-card-body label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #2C3E50;
    margin-bottom: 0.4rem;
    letter-spacing: 0.01em;
}

.auth-card-body input[type="text"],
.auth-card-body input[type="email"],
.auth-card-body input[type="password"],
.auth-card-body input[type="number"],
.auth-card-body input[type="tel"],
.auth-card-body input:not([type]),
.auth-card-body textarea,
.auth-card-body select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1.5px solid #DEE2E6;
    border-radius: 10px;
    font-size: 1rem;
    font-family: inherit;
    color: #2C3E50;
    background: #F9FBFB;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.auth-card-body input:focus,
.auth-card-body textarea:focus,
.auth-card-body select:focus {
    outline: none;
    border-color: #068984;
    background: #FFFFFF;
    box-shadow: 0 0 0 4px rgba(6, 137, 132, 0.15);
}

.auth-card-body input::placeholder {
    color: #ADB5BD;
}

/* Checkbox rows (e.g. "Remember me", terms) */
.auth-card-body input[type="checkbox"] {
    width: 1.05rem;
    height: 1.05rem;
    accent-color: #068984;
    margin-right: 0.5rem;
    vertical-align: -2px;
}

.auth-card-body .auth-check {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.92rem;
    color: #566573;
}

.auth-card-body .auth-check label {
    margin: 0;
    font-weight: 500;
    cursor: pointer;
}

/* ---- Submit button ---- */
.auth-card-body button[type="submit"],
.auth-card-body .btn-auth-submit {
    width: 100%;
    padding: 0.8rem 1.5rem;
    border: 0;
    border-radius: 10px;
    background: linear-gradient(135deg, #068984 0%, #046663 100%);
    color: #FFFFFF;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(6, 137, 132, 0.3);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    margin-top: 0.35rem;
}

.auth-card-body button[type="submit"]:hover,
.auth-card-body .btn-auth-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(6, 137, 132, 0.4);
}

.auth-card-body button[type="submit"]:active {
    transform: translateY(0);
}

/* ---- Secondary buttons (passkey, codes, cancel, logout confirm) ---- */
.auth-card-body a.btn,
.auth-card-body .button,
.auth-card-body button.button {
    display: inline-block;
    width: 100%;
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    border: 1.5px solid #068984;
    background: #FFFFFF;
    color: #068984;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    margin-top: 0.5rem;
    transition: all 0.25s ease;
}

.auth-card-body a.btn:hover,
.auth-card-body .button:hover {
    background: #068984;
    color: #FFFFFF;
    text-decoration: none;
}

/* ---- Errors ---- */
.auth-card-body .errorlist,
.auth-card-body .messages .errorlist {
    list-style: none;
    padding: 0.65rem 0.9rem;
    margin: 0 0 1rem;
    background: #FDECEA;
    border: 1px solid #F5C6C3;
    border-radius: 10px;
    color: #B02A37;
    font-size: 0.88rem;
}

.auth-card-body .errorlist li {
    padding: 0.1rem 0;
}

.auth-card-body .non-field-errors {
    text-align: left;
}

/* ---- Helpers / links ---- */
.auth-card-body .auth-helper {
    font-size: 0.9rem;
    text-align: center;
    color: #6C757D;
    margin-top: 1.25rem;
    margin-bottom: 0;
}

.auth-card-body .auth-helper a,
.auth-card-body p a:not(.btn) {
    color: #068984;
    font-weight: 600;
    text-decoration: none;
}

.auth-card-body .auth-helper a:hover,
.auth-card-body p a:not(.btn):hover {
    color: #046663;
    text-decoration: underline;
}

.auth-card-body hr {
    opacity: 0.15;
    margin: 1.5rem 0;
}

.auth-card-body .auth-alt {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.95rem;
    color: #6C757D;
}

/* ---- Password reset / informational pages ---- */
.auth-card-body h1:first-child,
.auth-card-body h2:first-child {
    font-size: 1.35rem;
    font-weight: 700;
    color: #2C3E50;
    margin-bottom: 0.75rem;
    text-align: center;
}

.auth-card-body p {
    color: #566573;
    line-height: 1.6;
}

/* ---- Responsive ---- */
@media (max-width: 575.98px) {
    .auth-section {
        padding: 6.5rem 0.75rem 2.5rem;
        background-attachment: scroll;
    }
    .auth-card {
        border-radius: 14px;
    }
    .auth-card-body {
        padding: 1.5rem;
    }
}

