The evolution of institutions in transition