/* ============================================
   AUTH PAGE STYLES — PREMIUM LIGHT THEME
   ============================================ */

.auth-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: calc(70px + var(--spacing-xl)) var(--spacing-md) var(--spacing-xl);
    background: #F9FAFB;
}

.auth-container {
    width: 100%;
    max-width: 460px;
}

/* ── Main card ── */
.auth-box {
    background: #ffffff;
    border: 1.5px solid #E5E7EB;
    border-radius: 24px;
    padding: 2.5rem 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.07), 0 2px 8px rgba(139, 92, 246, 0.06);
}

/* ── Header ── */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #0f172a;
}

.auth-header p {
    color: #6B7280;
    font-size: 0.95rem;
    margin: 0;
}

/* ── Tab switcher ── */
.auth-toggle {
    display: flex;
    gap: 0;
    margin-bottom: 2rem;
    background: #F3F4F6;
    border-radius: 12px;
    padding: 5px;
    border: 1.5px solid #E5E7EB;
}

.auth-toggle button {
    flex: 1;
    padding: 0.7rem 1rem;
    background: transparent;
    border: none;
    color: #6B7280;
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    font-size: 0.92rem;
    border-radius: 9px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.auth-toggle button:hover {
    color: #374151;
    background: rgba(139, 92, 246, 0.05);
}

.auth-toggle button.active {
    background: linear-gradient(135deg, #8B5CF6 0%, #6366F1 100%);
    color: #ffffff;
    box-shadow: 0 3px 10px rgba(139, 92, 246, 0.28);
}

/* ── Form ── */
.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
    animation: fadeInUp 0.4s ease;
}

.auth-form .form-group {
    margin-bottom: 1.25rem;
}

.auth-form label {
    display: block;
    margin-bottom: 0.4rem;
    color: #374151;
    font-weight: 600;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.auth-form input {
    width: 100%;
    padding: 0.875rem 1.125rem;
    background: #F9FAFB;
    border: 1.5px solid #E5E7EB;
    border-radius: 12px;
    color: #111827;
    font-family: 'Inter', sans-serif;
    font-size: 0.97rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-form input:focus {
    outline: none;
    border-color: #8B5CF6;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.12);
}

.auth-form input::placeholder {
    color: #4B5563;
}

/* ── Error / Success banners ── */
.auth-error {
    background: rgba(220, 38, 38, 0.08);
    border: 1px solid rgba(220, 38, 38, 0.3);
    border-radius: 10px;
    padding: 0.75rem 1rem;
    color: #b91c1c;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    display: none;
}

.auth-error.show {
    display: block;
    animation: slideDown 0.3s ease;
}

.auth-success {
    background: rgba(22, 163, 74, 0.08);
    border: 1px solid rgba(22, 163, 74, 0.3);
    border-radius: 10px;
    padding: 0.75rem 1rem;
    color: #15803d;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    display: none;
}

.auth-success.show {
    display: block;
    animation: slideDown 0.3s ease;
}

/* ── Submit button ── */
.auth-form .btn {
    width: 100%;
    margin-top: 1rem;
    background: linear-gradient(135deg, #8B5CF6 0%, #6366F1 100%);
    color: #ffffff;
    font-weight: 700;
    font-size: 1rem;
    padding: 0.9rem;
    border-radius: 12px;
    border: none;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.28);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.auth-form .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.36);
}

/* ── Footer / switch link ── */
.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1.5px solid #F3F4F6;
}

.auth-footer p {
    color: #6B7280;
    font-size: 0.9rem;
    margin: 0;
}

.auth-footer a,
.auth-switch a,
.terms-text a {
    color: #8B5CF6;
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover,
.auth-switch a:hover,
.terms-text a:hover {
    text-decoration: underline;
}

.auth-switch {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.875rem;
    color: #6B7280;
}

/* ── Forgot password link ── */
.forgot-password {
    color: #8B5CF6 !important;
    font-size: 0.85rem;
    font-weight: 500;
}

/* ── Loading spinner ── */
.auth-form .btn.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.auth-form .btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

/* ── Password toggle icon ── */
.password-toggle {
    color: #4B5563 !important;
}

.password-toggle:hover {
    color: #8B5CF6 !important;
}

/* ── reCAPTCHA ── */
.recaptcha-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin: 15px 0;
    overflow: hidden;
}

.g-recaptcha {
    transform-origin: center;
}

@media (max-width: 420px) {
    .g-recaptcha {
        transform: scale(0.85);
        transform-origin: left;
    }

    .auth-box {
        padding: 2rem 1.25rem;
    }
}

@media (max-width: 360px) {
    .g-recaptcha {
        transform: scale(0.75);
        transform-origin: left;
    }
}