Why, why, why, is turn order being recalculated at random times throughout the battle?

Why even bother putting it at the top of the screen if it doesn't matter and can change randomly based on factors that I have no knowledge of? I really am failing to understand. Sometimes I will get two turns in a row with the same character as a result of this.

There is no reason for this to be happening at all. Turn order should not change from the beginning of combat to the end. Why would it ever change/reset, at all? If a new combatant joins, then they'd get inserted in somewhere. Right?

Please explain what I am missing about this. If there is a "feature" here that I'm not aware of let me know, but I highly doubt I would call it a feature.