Siege of Algeciras
What happened
In 1339, the Marinid forces of Morocco, led by Abu Malik, captured the Rock of Gibraltar from the Castilians, a major strategic victory that opened the Strait of Gibraltar to Muslim naval power. This event reignited the Marinid-Castilian conflict and set the stage for the larger battles of Vega de Pagana and Río Salado. Gibraltar remained in Muslim hands until the Castilian recapture in 1462.
Literary impact
The loss of Gibraltar to the Marinids was lamented in Castilian and Andalusian poetry, becoming a symbol of Christian vulnerability. The event was frequently referenced in the 'Romancero' frontier ballads, which romanticized the warfare and heroism along the border. The narrative of loss and the eventual reconquest of Gibraltar became a persistent theme in Spanish epic poetry and nationalist literature.
Source: Wikipedia