Pi Network Explained: Mobile Mining, SCP Consensus and Halving