import { cva, type VariantProps } from "class-variance-authority";
import { cn } from "@/lib/utils";

const badgeVariants = cva(
  "inline-flex items-center rounded-full px-2.5 py-0.5 text-[11px] font-bold tracking-wide uppercase",
  {
    variants: {
      variant: {
        default: "bg-gold-ink text-gold-foreground",
        muted: "bg-gold-ink text-gold-foreground",
        success: "bg-success text-success-foreground",
        warning: "bg-gold-ink text-gold-foreground",
        destructive: "bg-destructive text-destructive-foreground",
        outline: "bg-gold-ink text-gold-foreground",
        live: "bg-success text-success-foreground",
      },
    },
    defaultVariants: { variant: "default" },
  },
);

export function Badge({
  className,
  variant,
  ...props
}: React.ComponentProps<"span"> & VariantProps<typeof badgeVariants>) {
  return <span className={cn(badgeVariants({ variant }), className)} {...props} />;
}
