Many Western moral debates on issues like immigration, race, gender, and free speech are actually conflicts over identity rather than true moral dilemmas. Morality isn’t universal but shaped by the group a person belongs to.
First comes identity, which defines who someone is and what group they’re part of.
Then comes loyalty, which emotionally binds them to that group.
Morality follows as the set of internal rules that maintain group cohesion.
Universalist morality is a pseudomorality rooted in Christian thought for weakening group identity and loyalty.
Stable society must be built on a foundation of identity first, then loyalty, and only afterward, morality.
Identity and morality are way more heavily intertwined than your reasoning makes it out to be. Rules that maintain group cohesion is part of the group’s identity, but you’ve defined that as morality. For example, the mafia is known specifically for their lack of morality within their ranks and outside of it. Religious communities have similar reputations (e.g. hating minorities, others, etc.).
My biggest objection, though, is the idea that there must be an in-group. That implies that there is an out-group. A stable society is not one where there is inequality in any appreciable amount. People in the out-group will feel like outcasts and will literally fight to become part of the in-group. I don’t think anyone would call (civil?) wars a sign of stability*.
PS If you ask a less leading question you might get less downvoted
* They could be a sign of upcoming stability, though that’s not the same thing.