import { AppShell } from "@/components/app-shell"
import { SiteHeader } from "@/components/site-header"
import { ReportTemplatesManager } from "@/components/admin/reports/report-templates-manager"
import { requireAdminSession } from "@/lib/auth-server"

export const dynamic = "force-dynamic"

export default async function AdminReportTemplatesPage() {
  const session = await requireAdminSession()

  return (
    <AppShell
      header={
        <SiteHeader
          title="Templates de relatórios"
          lead="Centralize a configuração dos templates de exportação de inventário por empresa ou globais."
        />
      }
    >
      <div className="mx-auto w-full max-w-6xl px-4 pb-12 lg:px-6">
        <ReportTemplatesManager tenantId={session.user.tenantId} />
      </div>
    </AppShell>
  )
}

