There actually really aren't that many religious wars. And many "religious" wars really sort of fall apart as religious wars when you closely examine them.
For example, the 30 Years War was ostensibly Catholics vs. Protestants; however one of the leading figures on the "Protestant" side was France led by Catholic Cardinal Richelieu.
Iraqi Shiites almost universally fought hard against Iranian Shiites in the Iran-Iraq War, rather than assisting Iran...blood (Arab hatred of Persians) was thicker than Religion.
And over history Christians have been infinitely more efficient killers of other Christians, and Moslems more efficient killers of other Moslems, than Christians have been killing Moslems or vice-versa.
You are correct. The 30 years war was really over the authority of the Hapsburgs and their leadership of the so-called Holy Roman Empire.