I think I know what you're looking for and worried about here. It's not so much that you're worried about being unfair to the fictional elves, it's that you're worried about unwittingly presenting stereotyped examples of real world ideas (i.e., the eco-fanatic elves) or superficial, cartoonish examples of fictional ideas (i.e., the AI government factions.)
I hope I've summarized that correctly. If so, I share your concern, and I spent a long time thinking about these issues for my previous game; and I am in a game that touches very heavily on these issues, too.
First, A Caveat
Little of what I've learned really applies to hard core, mustache-twirling bad guys. The local band of beholders, the Borg-like AI supremacists, the doomsday cult of Tharizdun, the Lich-Legion of Orcus... none of these guys really merit fair treatment.
They deserve characterization and motivation, but not fair treatment.
The Fundamental Unit Of Interaction Is...
...the character. Everything starts and ends with individual characters. Almost every scene in most RPGs is individual or small groups of PCs and NPCs. All social, political, and religious groups are made of individuals.
When I concentrated on trying to portray NPCs as individuals who belong to X, rather than minions of X or servants of X or whatever, it got easier. Individuals have different reasons for and ways of doing things, even when they're doing roughly the same thing.
Now, it is a herculean task to truly individualize and personalize each minor NPC. So at times, I resorted to just keeping track of things by numbers: "Well, the last two elves they met were hard core isolationist jerks, so I should really make this one friendlier." I often wouldn't even bother coming up with a reason why-- I would just note them on my NPC spreadsheet, and if they became recurring characters, I would back-rationalize something later.
In a similar vein, people are people no matter what else is true of them. Social movements are all going to be made of roughly the same proportion of heroes, saints, jerks, villains, and lumps who belong because their parents did. This applied (I sincerely hope) to the social groups in my campaign that I tended to agree with and expected the PCs to ally with, as well as those I expected to be generally adversarial.
Both Individuals And Social Groups Have Histories
But this works in different ways. The history of an individual can often inform why they join the groups they do. Sometimes these reasons are good, ("I have carefully considered the options, and these guys sound right to me,") and sometimes they are bad ("Dad was a member," "This will really piss off Mom," "A member of that other group cheated me at cards once, so screw them!") But this helps to focus on the NPCs as individuals.
The history of a group, though, is a little different. Groups have institutional memories that sometimes function like a subconscious-- a long history of abuse (which is almost cliche except for how much of real world history it explains) can shape a group profoundly, and have members acting in habitual ways that most have little conscious understanding of. Or a history of scarcity, or a history of some recurring environmental problem, etc.
My isolationist jerkwad elves were that way because of their history; my compulsive wandering nomads were that way because of their history; my doomsday cultists (not actual villains) were that way because of things they believed would happen based on history.
As GM, You Decide What Is True And Untrue
This is the big one, for me, and the more fantastic or science fictional your game, the more true it is. When you design (or adapt) your campaign world you are, in a literal sense, deciding what is true and false and who is right and wrong.
The single most useful thing I think I did in my game was to sit down in the design phase and write my basic bible: This is what actually happened and why the world is what it is. Then when designing my factions and group, I resolutely refused to give any of them a monopoly on truth-- they all had some things they believed that were true, some things that were wrong, and some things that started right and got corrupted over time.
This made it much harder for me to put my thumb down too hard on the scale of any one of my social groups, if I knew precisely and in advance what things they were just completely wrong about.
This was a high fantasy game, of course, which made this much easier.
A Final Postscript
This last does not directly address your question, but it is adjacent and I think it's useful. It approaches the level of an rpg stack cliche to bring up a Session Zero approach.
But here, I think it can be useful.
The reason is that many players are primed (by previous games or by computer games) to think in terms of black and white, us and them, good guys and bad guys. That's not necessarily a bad thing-- sometimes you just want to work out some aggro on some conveniently contrived mushroom minions of Zuggtmoy.
But if you're running something a little more nuanced, it doesn't hurt to be up front and overt about this when preparing your campaign.