import type { Metadata } from "next";
import { SitePage } from "@/app/(site)/_components/SitePage";
import { SiteHeader } from "@/app/(site)/_components/SiteHeader";
import { SiteFooter } from "@/app/(site)/_components/SiteFooter";
import { GLOBAL_STRATEGY_DEFAULTS } from "@/app/(site)/_components/pages/global-strategy/defaults";
import { GLOBAL_STRATEGY_SECTIONS } from "@/app/(site)/_components/pages/global-strategy/sections";
import { renderSections } from "@/app/(site)/_components/pages/render";
import { getPage } from "@/app/(site)/_lib/cms";

export const metadata: Metadata = {
  title: "Unionists Group Global Strategy Division — Unionists Group",
};

export default async function Page() {
  const data = await getPage("global-strategy");
  return (
    <SitePage className="global-strategy-page">
      <a className="skip-link" href="#main">
        Skip to main content
      </a>{" "}
      <SiteHeader active="/about" activeItem="/global-strategy" />
      <main id="main">{renderSections("global-strategy", data, GLOBAL_STRATEGY_DEFAULTS, GLOBAL_STRATEGY_SECTIONS)}</main>
      <SiteFooter />
    </SitePage>
  );
}
