That said, I was reflecting upon many of the stories that I love. Harry Potter. The Lord of the Rings. The Hunger Games. Star Wars (to a lesser extent). And, heck, I'll even throw in Atlas Shrugged. What these have in common is that they do not in any way match my avowed ideal depiction of good versus evil. At best, these stories try to generate sympathy for the villains by showing where they 'went wrong,' like with Smeagol or Tom Riddle. But, while the 'merit' of evil is not always unambiguously placed at the feet of the character, there is no doubt that evil is the result.
Now, in my defense, I like quite a few stories where things are less black and white. The Stars My Destination, anything by UK Le Guin, the Ender series (the first one), Song of Ice and Fire, Star Trek on good days... but it's not the overwhelming majority that I would have guessed.
So, what's the purpose of sharp distinctions between good and evil? By making one side unambiguously evil, it frees up the story to explore what it means to be 'good.' By caricaturing one side, all of the focus can be on the exploration of, and a more complex depiction of, what it means to be good, to live a good life, and so on. Angels vs Demons is boring, to be sure, but complexly imagined good guys vs Demons is something that works. In Harry Potter, we get a very clear vision of good: one who is forgiving, reliant on friends, compassionate, imperfect, and so on. In LoTR, the good is pastoral, simple, self-reliant as much as possible, and so on. The villains may have some level of complexity, but their values do not. It's probably why Rand was a Romantic: it allowed her to spend the time presenting her image of the good, which was the entire point of her project. Imagining the villains of Atlas Shrugged complexly would have been more realistic, but it would have made the endeavor less successful; LoTR would not have been improved by complexly imagining Sauron's philosophy.
I will say that when it comes to historical or contemporary fiction, especially when dealing with somewhat political events, my original 'good and evil should both be imagined complexly and not as a dichotomy in reality' maxim still applies. I think that's why I found The Book Thief by Marcus Zuzak so non-compelling. He tries to depict a real life situation, Nazi Germany, and does so by clearly labeling people 'good guys' and 'bad guys' depending on their relationship to the party. I get it, Nazis are evil. But if you are going to depict a group of people who actually existed, there should be some attempt to try to get inside their heads. At the very least, you will be able to discover how normal people can find 'evil' so compelling. Perhaps this is one of the benefits science fiction and fantasy, where depicting someone as 'pure evil' does not dehumanize actual people, and so understandings about what is 'good' can be explored more acceptably.
(This is my "Ryan discovers what he would have learned in week 3 of his Lit 101 class" post)