export function Notice({ success, error }: { success?: string; error?: string }) {
  const message = error || success;
  if (!message) return null;
  return (
    <p
      className={`mb-5 rounded-md border-r-4 px-4 py-3 text-sm font-semibold ${
        error ? "border-[var(--danger)] bg-[#fae5e5] text-[#922f31]" : "border-[#278253] bg-[#e2f3e9] text-[#17613b]"
      }`}
      role="status"
    >
      {message}
    </p>
  );
}
