Arab-plan or hypostyle mosques are the earliest type of mosques, pioneered under the Umayyad Dynasty. These mosques are square or rectangular in plan with an enclosed courtyard and a covered prayer hall. Historically, because of the warm Mediterranean and Middle Eastern climates, the courtyard served to accommodate the large number of worshippers during Friday prayers. Most early hypostyle mosques have flat roofs on top of prayer halls, necessitating the use of numerous columns and supports. One of the most notable hypostyle mosques is the Mosque–Cathedral of Córdoba, Spain, as the building is supported by over 850 columns. Frequently, hypostyle mosques have outer arcades so that visitors can enjoy some shade. Arab-plan mosques were constructed mostly under the Umayyad and Abbasid dynasties; subsequently, however, the simplicity of the Arab plan limited the opportunities for further development, and as a result, these mosques gradually fell out of popularity.