"use client";
import { usePathname } from "next/navigation";
import Navigation from "@/src/components/reusables/navigation/navigation";
import Sidebar from "@/src/components/reusables/navigation/sidebar/sidebar";

export default function UserLayout({
  children,
}: Readonly<{
  children: React.ReactNode;
}>) {
  const pathname = usePathname();

  const hideNavAndSidebar = pathname === "/user/forgot-password" || pathname === '/user/contact' || pathname === '/user/terms-and-conditions';

  return (
    <main className="bg-[#F6F6F6] min-h-screen relative">
      {!hideNavAndSidebar && <Navigation />}
      {!hideNavAndSidebar && <Sidebar />}
      {children}
    </main>
  );
}
