In the early 20th century
In the early 20th century, this country fought the Rif Wars, and this country was defeated at the Battle of Aljubaratta. In the 19th century, this country was home to the Carlist Wars, and this country took over one of its neighbors after the death of the last king from the Aviz Dynasty. During the Thirty Years War this country was led by the Duke of Olivares. Despite the leadership of generals like the Alexander Farnese and the Duke of Alba, this country lost the Eighty Years War to the Netherlands, and fire ships were used by Sir Francis Drake to defeat this country's armada. For 10 points, name this European country with capital at Madrid.
In the early 20th century, this country fought the Rif Wars, and this country was defeated at the Battle of Aljubaratta.
{Spain}