During the classical era, several independent kingdoms became established in what is now Georgia, such as Colchis and Iberia. Georgians officially adopted Christianity in the early fourth century, which contributed to the spiritual and political unification of early Georgian states. In the Middle Ages, the unified Kingdom of Georgia emerged and reached its Golden Age during the reign of King David the Builder and Queen Tamar the Great in the 12th and early 13th centuries. Thereafter, the kingdom declined and eventually disintegrated under the hegemony of various regional powers, including the Mongols, the Ottoman Empire and successive dynasties of Persia. In 1783, one of the Georgian kingdoms entered an alliance with the Russian Empire, which proceeded to annex the territory of modern Georgia in a piecemeal fashion throughout the 19th century.