"use client";

import { useRouter } from "next/navigation";

export default function LogoutButton() {
  const router = useRouter();

  const handleLogout = async () => {
    try {
      // Add your custom logout logic here

      router.push("/login");
    } catch (error) {
      console.error("Error logging out:", error.message);
    }
  };

  return (
    <div className="container pt-30">
      <button className="btn btn-no-arrow" onClick={handleLogout}>
        Log Out
      </button>
    </div>
  );
}
