import { generateSEOMetadata, generateStructuredData } from "@/lib/seo"
import { AboutPage } from "@/components/about-page"
import type { Metadata } from "next"
import { businessConfig } from "@/lib/seo-config"

export async function generateMetadata(): Promise<Metadata> {
  return {
    ...generateSEOMetadata({
      title: "About Rocky Mountain Vending | Utah Vending Company",
      description:
        "Learn about Rocky Mountain Vending, the Utah service-area business behind our vending placement, repair, sales, and support services.",
      path: "/about",
    }),
    alternates: {
      canonical: `${businessConfig.website}/about-us`,
    },
    robots: {
      index: false,
      follow: true,
    },
  }
}

export default function About() {
  const structuredData = generateStructuredData({
    title: "About Rocky Mountain Vending",
    description:
      "Learn about Rocky Mountain Vending, the Utah service-area business behind our vending placement, repair, sales, and support services.",
    url: "https://rockymountainvending.com/about-us/",
    type: "WebPage",
  })

  return (
    <>
      <script
        type="application/ld+json"
        dangerouslySetInnerHTML={{ __html: JSON.stringify(structuredData) }}
      />
      <AboutPage />
    </>
  )
}
