the unstable particles like leptons and such are formed during inflation where energy condenses into matter, post-inflation the universe cools and the particles interact and decay to form electrons, protons and neutrons. During nucleosynthesis the universe further cools and allows the protons...