Unlike the above, Dialga and Palkia are not enemies, but have a more neutral relation to each other. They are not in opposition, they exist together in harmony. Time and Space needs to coexist, and so does these two dragons. If they fight, it is completely unnatural, like when Cyrus forced them to battle against each other in Pokémon Adventures. Meanwhile, Giratina represents antimatter and resides in the Distortion World, which is where it was banished to for its violence. It is mostly neutral towards the other two in the games. This does not appear to be the case in the anime though. From what I have understood, all three fought with each other there? Though it seems like they also fought together against Arceus. I haven’t seen those movies so I don’t know how they were handled there.
I believe they fought each other in the anime only because their dimensions collided (when they never should have) and they each perceived the other to be invading their own territory. Dialga and Palkia's clash left a lot of toxic clouds in Giratina's Reverse World (basically the anime's Distortion World) and Giratina was pissed about their clash defiling its home dimension and attacked Dialga whenever it was in the real world because it wanted revenge. They're not inherently hostile to each other but their dimensions clashing led to them battling until they did eventually reconcile in the 12th movie, and eventually collaborated to try to hold off Arceus when the latter appeared into the real world to destroy all humans, and the three attempted to stop it with Palkia bending space to restrain Arceus and Dialga sending Ash and crew back into time to change events so that Arceus would no longer be hostile and angry at humanity.
Xerneas and Yveltal are also in conflict as they are representing life and death, respectively. While this isn’t touched upon in the games all that much, it is explained deeper in Pokémon Adventures (as well as in the anime, I believe?). In Pokémon Adventures, Xerneas and Yveltal are in a never-ending conflict. When Xerneas gives life, Yveltal steals life. And so it goes on for all eternity. The only one who can stop them and create order is Zygarde. And that's exactly what it ends up doing.
The anime puts an interesting spin on their relationship. In Movie 17 and in that one special about their legend it seems they exchange places on a 1000 year interval: one roams Kalos, while the other lays dormant, and vice versa. So when Yveltal is awake, it flies around Kalos, then when it reaches the end of its 1000 years phase, it absorbs all the life force around it then becomes a cocoon and sleeps for 1000 years: at the same time, Xerneas will awaken and share its life force with all around it, revitalizing the land and making it even more lush. And then it wanders around Kalos or the next 1000 years, and then Yveltal will awaken and destroy the life around it again, while Xerneas will share its life energy then go to sleep as a tree. Meanwhile Zygarde ensures that the cycle is never disrupted with all of its cells and cores being scattered all around Kalos and observing the ecosystem and if one of them is harmed, Zygarde will step in and punish those who dare to disrupt the ecosystem.
And even so, while Xerneas and Yveltal do represent opposing forces, both forces must remain in existence and in fact are both needed to keep the vitality of life and nature going on. Just as everything ends, so does everything begin. In a sense, one cannot exist without the other. Yveltal ends all life around it, withering it all, yet Xerneas will always be there to revitalize it, making the life around it even more alive and lush than before. Without one, the other cannot happen: Xerneas's ability to give life would be useless if nothing was taken, which Yveltal takes: but without Xerneas, Yveltal would no longer have any life to take. In a sense, they are forces of nature, and their combined powers ensure the cycle of life continues to flourish. In a sense, their relationship is symbiotic and mutually beneficial, and they rarely battle in the anime verse, but exchange places in a never ending cycle, which Zygarde ensures remains in place.
Zygarde's many signature moves imply its role as well: Land's Wrath and Core Enforcer effectively are punishment to those who disrupt Kalos's ecosystem while Thousand Arrows/Waves seems to be to restrain Yveltal or Xerneas.
Solgaleo and Lunala are basically allies (mates?), both being final evolutions of Cosmog. They coexist in harmony. Necrozma is the enemy here as it wants to steal their light (and light in general), by absorbing them to change forms, and ultimately to regain its true form as Ultra Necrozma. Solgaleo/Lunala fought with the four Tapu to defeat Necrozma in the past, and Necrozma was banished from Alola afterwards.
Interestingly this is one of the few cases where it's implied in multiple canons that multiples of Solgaleo and Lunala exist. While there's only a single specimen of the likes of Dialga/Palkia/Giratina, Kyogre/Groudon/Rayquaza, Reshiram/Zekrom/Kyurem, Xerneas/Yveltal/Zygarde, and Zacian/Zamazenta/Eternatus, in this case at least multiple individuals of Solgaleo and Lunala could potentially exist thanks to the existence of Cosmog: in some cases a Solgaleo and Lunala can meet and spawn a singular Cosmog, which eventually evolves into a Cosmoem and then one or the other. Nebby is but one individual that becomes a Solgaleo or Lunala, and though legends speak of an individual from an era long past, the one we see in the game is obviously a different individual as it starts as a Cosmog that Lillie was attempting to protect.
All three of them are also implied to be Ultra Beasts that came from the Ultra Space dimension and have the power to move into the real world or into their own dimensional universe.
Overall I really liked your post though, just had a few things to weigh in here.