import type { Metadata } from "next";
import Link from "@/components/Link";
import SiteEffects from "@/components/SiteEffects";
import { allowIndexing } from "@/lib/site";

export const metadata: Metadata = {
  title: "Page Not Found",
  description: "We couldn’t find that page. Head back home or browse our advertising channels.",
  // Overrides the site-wide index, follow, which would otherwise sit beside Next's own noindex on 404s.
  robots: { index: false, follow: allowIndexing },
};

export default function NotFound() {
  return (
    <>
      <section className="an-section">
      <div className="an-wrap an-stack">
        <span className="an-eyebrow">404</span>
        <h1 className="an-h1">We couldn’t find that page</h1>
        <p className="an-lede">The page may have moved. Head back home or browse our channels.</p>
        <div className="an-actions">
          <Link className="an-btn an-btn--primary" href="/">Back to home</Link>
          <Link className="an-btn an-btn--ghost" href="/solutions">Explore channels</Link>
        </div>
      </div>
    </section>
    <SiteEffects />
    </>
  );
}
