/* =========================================================
   AFMS Auth Pages
   مسیر فایل:
   static/css/auth.css
   ========================================================= */

.auth-page {
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.auth-card {
    width: 100%;
    max-width: 520px;
    background: rgba(19, 19, 31, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.34);
    padding: 1.45rem;
    color: #f8fafc;
}

html:not([data-theme="dark"]) .auth-card {
    background: rgba(255, 255, 255, 0.94);
    border-color: rgba(15, 23, 42, 0.08);
    color: #0f172a;
    box-shadow: 0 22px 60px rgba(15, 23, 42, 0.10);
}

.auth-title {
    font-size: 1.35rem;
    font-weight: 950;
    text-align: center;
    margin-bottom: 0.5rem;
    color: inherit;
}

.auth-subtitle {
    color: #a1a1aa;
    text-align: center;
    font-weight: 650;
    line-height: 1.9;
    margin-bottom: 1.4rem;
}

html:not([data-theme="dark"]) .auth-subtitle {
    color: #64748b;
}

.auth-field-label {
    display: block;
    color: inherit;
    font-weight: 900;
    margin-bottom: 0.55rem;
}

.auth-card .form-control {
    height: 48px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #f8fafc;
    font-weight: 700;
    text-align: right;
}

.auth-card .form-control::placeholder {
    color: #94a3b8;
}

.auth-card .form-control:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(129, 140, 248, 0.85);
    box-shadow: 0 0 0 0.22rem rgba(129, 140, 248, 0.16);
    color: #f8fafc;
}

html:not([data-theme="dark"]) .auth-card .form-control {
    background: #f8fafc;
    border-color: rgba(15, 23, 42, 0.10);
    color: #0f172a;
}

html:not([data-theme="dark"]) .auth-card .form-control:focus {
    background: #ffffff;
    color: #0f172a;
}

.auth-card .form-text {
    color: #71717a;
    font-size: 0.78rem;
    line-height: 1.8;
}

html:not([data-theme="dark"]) .auth-card .form-text {
    color: #64748b;
}

/* ---------- Reset Method Radio ---------- */

.reset-method-list {
    display: grid;
    gap: 0.65rem;
}

.reset-method-option {
    position: relative;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    direction: rtl;
    padding: 0.75rem 0.9rem;
    border-radius: 15px;
    cursor: pointer;
    user-select: none;
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: 0.18s ease;
}

html:not([data-theme="dark"]) .reset-method-option {
    background: #f8fafc;
    border-color: rgba(15, 23, 42, 0.10);
}

.reset-method-option:hover {
    border-color: rgba(129, 140, 248, 0.65);
    background: rgba(129, 140, 248, 0.10);
}

.reset-method-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.reset-method-dot {
    width: 20px;
    height: 20px;
    border-radius: 999px;
    border: 2px solid #94a3b8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.reset-method-dot::after {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: transparent;
    transform: scale(0.3);
    transition: 0.18s ease;
}

.reset-method-text {
    color: inherit;
    font-weight: 850;
    line-height: 1.5;
}

.reset-method-option input:checked + .reset-method-dot {
    border-color: #8b5cf6;
}

.reset-method-option input:checked + .reset-method-dot::after {
    background: #8b5cf6;
    transform: scale(1);
}

.reset-method-option:has(input:checked) {
    border-color: rgba(139, 92, 246, 0.75);
    background: rgba(139, 92, 246, 0.14);
}

/* ---------- Buttons ---------- */

.auth-card .btn {
    min-height: 48px;
    border-radius: 14px;
    font-weight: 900;
}

.auth-card .btn-primary {
    background: linear-gradient(135deg, #7c3aed, #93c5fd);
    border: none;
    color: #ffffff;
}

.auth-card .btn-primary:hover {
    filter: brightness(1.04);
}

.auth-card .btn-outline-secondary {
    border-color: rgba(148, 163, 184, 0.55);
    color: #cbd5e1;
}

.auth-card .btn-outline-secondary:hover {
    background: rgba(148, 163, 184, 0.14);
    color: #f8fafc;
}

html:not([data-theme="dark"]) .auth-card .btn-outline-secondary {
    color: #475569;
    border-color: rgba(71, 85, 105, 0.35);
}

html:not([data-theme="dark"]) .auth-card .btn-outline-secondary:hover {
    background: #f1f5f9;
    color: #0f172a;
}

/* ---------- Alerts ---------- */

.auth-card .alert {
    border-radius: 14px;
    font-weight: 800;
    line-height: 1.8;
}

@media (max-width: 575.98px) {
    .auth-page {
        padding: 1rem 0.7rem;
        align-items: flex-start;
    }

    .auth-card {
        border-radius: 20px;
        padding: 1.1rem;
    }

    .auth-title {
        font-size: 1.18rem;
    }

    .auth-subtitle {
        font-size: 0.84rem;
    }

    .reset-method-option {
        min-height: 46px;
        padding: 0.7rem 0.8rem;
    }
}