Reorganisation of Earth’s biogeochemical cycles briefly oxygenated the oceans 520 Myr ago