"use client";

import { signOut } from "next-auth/react";
import { LogOut } from "lucide-react";

export function SignOutButton() {
  return (
    <button
      type="button"
      onClick={() => signOut({ callbackUrl: "/" })}
      className="flex items-center gap-1.5 rounded-md px-2 py-1.5 text-xs text-slate-500 hover:bg-rose-50 hover:text-rose-600 transition"
      title="Se déconnecter"
    >
      <LogOut className="h-3.5 w-3.5" />
      <span className="hidden sm:inline">Déconnexion</span>
    </button>
  );
}
