Mosques had been built in Iraq and North Africa by the end of the 7th century, as Islam spread outside the Arabian Peninsula with early caliphates. The Imam Husayn Shrine in Karbala is reportedly one of the oldest mosques in Iraq, although its present form - typical of Persian architecture - only goes back to the 11th century. The shrine, while still operating as a mosque, remains one of the holiest sites for Shi'ite Muslims, as it honors the death of the third Shia imam, and Muhammad's grandson, Hussein ibn Ali. The Mosque of Amr ibn al-As was reportedly the first mosque in Egypt, serving as a religious and social center for Fustat (present-day Cairo) during its prime. Like the Imam Husayn Shrine, though, nothing of its original structure remains. With the later Shia Fatimid Caliphate, mosques throughout Egypt evolved to include schools (known as madrasas), hospitals, and tombs.