Almeida, Portugal the current name was first used, in the form of the Arabic "al-Ma'ida" ('the plateau'). The village of Almeida was captured from the Moors by the second king of Portugal, Sancho I in the 12th century because of its strategic position on the new country of Portugal's border with Spain. So important to the security of the country, Sancho had the village heavily fortified. The castle was refortified on three further occasions by King Dinis, King Manuel I and by King João VI. The present 12 pointed star fortification was constructed in 1641 to a Vaubanesque plan on which the
Portugal in the Middle Ages privileges and favours given to the Roman Catholic Church were compensated. In the papal bull " Manifestis Probatum", Pope Alexander III acknowledged Afonso as King and Portugal as an independent land with the right to conquer lands from the Moors. With this papal blessing, Portugal was at last secured as a country and safe from any Leonese attempts at annexation. In 1184, in spite of his great age, King Afonso of Portugal still had sufficient energy to relieve his son Sancho, who was besieged in Santarém by the Moors. He died shortly after, on December 6, 1185. Afonso had already