Understanding the appeal of legalism