Can anybody explain to me when each of this variations of "porque" should be used?
Por qué asks the question why.
Porque means because.
Porqué translates roughly to reason.
Check the RAE for a deep explanation of this. There are several combinations (porque vs. por que as one or two words and then que/qué with or without the accent)
1- You use por qué as two words and with the accents for questions:
Or in exclamation:
Using por que in a question is a misspelling. You need the accent.
2- You use porque, as a single word and without the accent to explain something.
3- Porqué, is a noun. We could actually understand is as a pronoun which stands for "the reason or the rationale behind this or that"
4- Por que (two words, no accent) is the use of the preposition por and the relative pronoun que, which is quite complex (not only for this specific use, but for many others). Basically that que is introducing a second sentence, subordinate to the firs one. Along with the user of the preposition por the second sentence is explaining the why or the first sentence.
As a note apart, see that you could use this construction with other prepositions, like para:
The use of para here also helps introducing the subordinate sentence that explains the first sentence.
But, please, check the link I gave you. It is really good. If you have problems understating that in Spanish tell us and we can help with some translations of those rules.