import { Info } from 'lucide-react'; import { PageHeader } from '@/components/shared/page-header'; import { RegistryDrivenForm } from '@/components/admin/shared/registry-driven-form'; import { SalesEmailConfigCard } from '@/components/admin/sales-email-config-card'; import { EmailRoutingCard } from '@/components/admin/email-routing-card'; import { SmtpTestSendCard } from '@/components/admin/email/smtp-test-send-card'; export default function EmailSettingsPage() { return (
{/* Explainer for the "two accounts" model — addresses the recurring UAT question "why are there separate SMTP credentials for sales and noreply?". Keeps the answer in front of the admin before they reach the per-card form below. */}

Why two accounts? Transactional emails (signing invites, notifications, password resets) ship from your noreply mailbox over the SMTP credentials below. Rep-authored sales emails (one-off messages, proposal sends) ship from the sales mailbox with separate credentials so replies land in a human-monitored inbox.

The noreply credentials are also used by the supplemental-info workflow + portal activation, i.e. anywhere the platform sends on its own initiative. The sales credentials are only used when a rep clicks Send in the compose UI.

{/* Registry-driven so each field shows the "Using env fallback / port / global / default" badge inline — admins can tell at a glance which fields are coming from .env vs. UI overrides. */}
); }