The Stag Hunt and the Evolution of Social Structure