The role of microbial mats in the production of reduced gases on the early Earth