import { LucideIcon } from "lucide-react"; import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card"; interface StatsCardProps { title: string; value: string | number; change?: string; trend?: "up" | "down" | "neutral"; icon: LucideIcon; color?: "blue" | "green" | "purple" | "orange"; } export function StatsCard({ title, value, change, trend, icon: Icon, color = "blue" }: StatsCardProps) { const colorStyles = { blue: { bg: "bg-gradient-to-br from-blue-600 to-blue-700", iconBg: "bg-blue-500/20 text-blue-300", light: "from-blue-50 to-blue-100/50", }, green: { bg: "bg-gradient-to-br from-emerald-600 to-emerald-700", iconBg: "bg-emerald-500/20 text-emerald-300", light: "from-emerald-50 to-emerald-100/50", }, purple: { bg: "bg-gradient-to-br from-purple-600 to-purple-700", iconBg: "bg-purple-500/20 text-purple-300", light: "from-purple-50 to-purple-100/50", }, orange: { bg: "bg-gradient-to-br from-orange-600 to-orange-700", iconBg: "bg-orange-500/20 text-orange-300", light: "from-orange-50 to-orange-100/50", }, }; const styles = colorStyles[color]; return (
{title}
{value}
{change && (

{trend === "up" ? "↑" : trend === "down" ? "↓" : "→"} {change}

vs last month
)}
); }