Direct benefits and evolutionary transitions to complex societies