I summarized the position of the emperor (and his court) between the Kamakura and the early Edo here. Please give it a read.