Humanity is teetering on the edge of extinction, and its future will be decided in the next half century