export function isDatabaseUnavailableError(error: unknown): boolean {
  if (!error || typeof error !== 'object') return false
  const candidate = error as { code?: string; message?: string }
  return candidate.code === 'P1001' || candidate.message?.includes("Can't reach database server") === true
}
