With Light, the creators said themselves that they weren't focused on right and wrong for most of the story, and just wanted the reader to enjoy the battle between Light and L. Then toward the end, they started to get disturbed by how many were rooting for Light, so they suddenly made him way more gratuitously evil and made his defeat as humiliating as possible in an attempt to address that. The problem is it makes the story fairly unpleasant to watch toward the end.