The effect of demand-driven structural transformations on growth and technological change