interface AlarmBadgeProps {
  severity: string
}

export default function AlarmBadge({ severity }: AlarmBadgeProps) {
  const map: Record<string, string> = {
    CRITICAL: 'bg-red-500/20    text-red-400    border border-red-500/40',
    HIGH:     'bg-orange-500/20 text-orange-400 border border-orange-500/40',
    MEDIUM:   'bg-yellow-500/20 text-yellow-400 border border-yellow-500/40',
    LOW:      'bg-gray-500/20   text-gray-400   border border-gray-500/40',
  }
  const cls = map[severity] || map.LOW
  return (
    <span className={`px-2 py-0.5 rounded text-xs font-medium ${cls}`}>{severity}</span>
  )
}
