import type { Metadata } from "next";
import { ThemeProvider } from "@/app/ThemeProvider";
import { FamilyProvider } from "@/app/FamilyProvider";
import { PageTransition } from "@/components/PageTransition";
import { BottomNav } from "@/components/BottomNav";
import { InstallPrompt } from "@/components/InstallPrompt";

// Private, authenticated app — never index these pages.
export const metadata: Metadata = {
  robots: { index: false, follow: false },
};

export default function AppLayout({
  children,
}: {
  children: React.ReactNode;
}) {
  return (
    <ThemeProvider>
      <FamilyProvider>
        <PageTransition>{children}</PageTransition>
        <BottomNav />
        <InstallPrompt />
      </FamilyProvider>
    </ThemeProvider>
  );
}
