Some of the ancient cities of palaces, mosques, public squares, and narrow streets date back to the 12th century and are still inhabited.