import { SaudiRiyal } from "lucide-react";

interface SummaryItemProps {
  label: string;
  value: string;
  showCurrency?: boolean;
  currency?: string;
}

export default function SummaryItem({
  label,
  value,
  showCurrency = false,
  currency,
}: SummaryItemProps) {
  const currencySign =
    currency === "SAR" ? (
      <SaudiRiyal className="text-[14px] sm:text-[16px] font-bold" />
    ) : currency === "USD" ? (
      "$"
    ) : (
      currency
    );
  return (
    <div className="flex gap-10 justify-between sm:justify-start items-center">
      <span className="text-[14px] sm:text-[16px] font-bold w-[130px]">
        {label}
      </span>
      <div className="flex items-center gap-1">
        <span className="text-[14px] sm:text-[16px] font-bold">{value}</span>
        {showCurrency && currencySign}
      </div>
    </div>
  );
}
