/* ============================================================
   PropertyDesk Africa — Auth Pages Stylesheet
   Shared by: login, register, forgot-password, reset-password
   ============================================================ */

/* ── Auth layout ──────────────────────────────────────────── */
.auth-page {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
}

/* Left panel — branding / illustration */
.auth-panel {
    background: var(--primary);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 48px 56px;
    position: relative;
    overflow: hidden;
}
.auth-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(255,255,255,.06) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255,255,255,.04) 0%, transparent 50%);
}
.auth-panel-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    position: relative;
    z-index: 1;
}
.auth-panel-logo span {
    font-size: 1.2rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.1;
}
.auth-panel-logo small {
    display: block;
    font-size: .72rem;
    font-weight: 500;
    color: rgba(255,255,255,.65);
}
.auth-panel-body {
    position: relative;
    z-index: 1;
}
.auth-panel-body h2 {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    color: #fff;
    margin-bottom: 16px;
    line-height: 1.2;
}
.auth-panel-body p {
    color: rgba(255,255,255,.75);
    font-size: 1rem;
    line-height: 1.7;
    max-width: 380px;
}
.auth-panel-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 40px;
    position: relative;
    z-index: 1;
}
.auth-stat {
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 14px;
    padding: 20px;
}
.auth-stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 4px;
}
.auth-stat-label {
    font-size: .78rem;
    color: rgba(255,255,255,.65);
    font-weight: 500;
}
.auth-panel-footer {
    position: relative;
    z-index: 1;
}
.auth-panel-footer p {
    font-size: .8rem;
    color: rgba(255,255,255,.5);
}

/* Right panel — form */
.auth-form-panel {
    background: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px 64px;
    overflow-y: auto;
}
.auth-form-header {
    margin-bottom: 36px;
}
.auth-form-header h1 {
    font-size: 1.75rem;
    color: var(--text-dark);
    margin-bottom: 8px;
}
.auth-form-header p {
    color: var(--text-muted);
    font-size: .95rem;
}

/* Role selector (register page) */
.role-selector {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 28px;
}
.role-option {
    position: relative;
}
.role-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.role-option label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px 16px;
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all .2s;
    text-align: center;
}
.role-option label:hover {
    border-color: var(--primary-light);
    background: var(--primary-soft);
}
.role-option input:checked + label {
    border-color: var(--primary);
    background: var(--primary-soft);
    box-shadow: 0 0 0 3px rgba(44,45,158,.12);
}
.role-icon {
    width: 48px;
    height: 48px;
    background: var(--primary-soft);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: var(--primary);
    transition: all .2s;
}
.role-option input:checked + label .role-icon {
    background: var(--primary);
    color: #fff;
}
.role-option label strong {
    font-size: .9rem;
    color: var(--text-dark);
}
.role-option label span {
    font-size: .75rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Password strength */
.password-strength {
    margin-top: 8px;
}
.strength-bar {
    display: flex;
    gap: 4px;
    margin-bottom: 6px;
}
.strength-segment {
    height: 4px;
    flex: 1;
    border-radius: 2px;
    background: var(--border);
    transition: background .3s;
}
.strength-segment.weak   { background: var(--danger); }
.strength-segment.fair   { background: var(--warning); }
.strength-segment.good   { background: #65a30d; }
.strength-segment.strong { background: var(--success); }
.strength-label {
    font-size: .75rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Password toggle eye */
.input-group {
    position: relative;
}
.input-group .form-control {
    padding-right: 44px;
}
.input-eye {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 18px;
    padding: 0;
    transition: color .2s;
    display: flex;
    align-items: center;
}
.input-eye:hover { color: var(--primary); }

/* Form row */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Divider */
.auth-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 24px 0;
    color: var(--text-muted);
    font-size: .85rem;
}
.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* Auth footer link */
.auth-footer-link {
    text-align: center;
    margin-top: 28px;
    font-size: .9rem;
    color: var(--text-muted);
}
.auth-footer-link a {
    color: var(--primary);
    font-weight: 600;
}
.auth-footer-link a:hover { text-decoration: underline; }

/* Terms text */
.terms-text {
    font-size: .8rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-top: 16px;
    text-align: center;
}
.terms-text a { color: var(--primary); }

/* Pending approval notice */
.pending-notice {
    background: #fef3c7;
    border: 1px solid #fde68a;
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    text-align: center;
}
.pending-icon {
    width: 72px;
    height: 72px;
    background: #fef9ee;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 32px;
    color: #d97706;
}

/* Checkbox custom */
.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: .875rem;
    color: var(--text-body);
    line-height: 1.5;
}
.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    margin-top: 1px;
    flex-shrink: 0;
    cursor: pointer;
}

/* ── Mobile responsive ────────────────────────────────────── */
@media (max-width: 900px) {
    .auth-page {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    .auth-panel {
        padding: 36px 32px;
        min-height: auto;
    }
    .auth-panel-stats { display: none; }
    .auth-form-panel  { padding: 40px 32px; }
    .form-row         { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .auth-panel       { padding: 28px 20px; }
    .auth-form-panel  { padding: 32px 20px; }
    .role-selector    { grid-template-columns: 1fr; }
    .auth-form-header h1 { font-size: 1.5rem; }
}
