Long-Term Dynamics of Institutions