I get that the defeat of the Armada crushed Spain and they receded from power in Europe. But why did they never resurge and join the other powerful nations of Western Europe as a world power? They’ve had hundreds of years to rebuild?!?! And why didn’t they participate in any major wars in the 19th or 20th century?
I’ve taken a lot of world/European history classes and this has always confused me.
You're really missing a lot of history there. The Spanish didn't just suddenly slide into irrelevance at the end of 1588 when their invasion of England failed. They continued to be a major power in Europe well into the next century at the very least, participating very heavily in campaigns in Italy, the Netherlands, and western Germany. Unfortunately I'm not particularly well versed in Spain's history post-30-Years'-War, but in general Spain's decline is portrayed as a long process that really seemed to have a lot to do with being a victim of their own success.
Spain's status as arguably the greatest power in Europe came about because of their lucky marriages and inheritances that provided them with domains across Europe and their early claim to colonies in the Americas. After the collapse and conquest of the Incan and Aztec empires, Spain began to benefit from hugely profitable extractive industries that it was able to monopolize on, perhaps the most important being the silver mines at Potosi in modern Bolivia. Spain ended up flooded with incredible wealth, which ended up going towards a few domestic vanity projects and defending its domains across Europe.
Unfortunately, this massive influx of wealth was a double-edged sword. Silver flooding into Europe caused inflation which would be endemic and a lingering problem. The expulsion of the Moriscos and Jews would severely damage the economies in many areas, particularly Valencia, and Spain's far flung possessions in Europe were quickly turning into liabilities. Not only was Spain constantly contesting control of northern Italy and the Low Countries with France, but they were also contesting the Mediterranean with the Ottomans and supporting their Hapsburg family in Austria. Even the massive influx of money from the Americas often wasn't enough to support these endeavors, so the Spanish were increasingly turning to loans and selling off some titles of nobility to make ends meet. Meanwhile, Spain's enemies were starting to target the American colonies to cut off their funding at its source (most notable being Piet Hein stealing the entire Spanish Treasure Fleet in 1628) while subverting them closer to home. The Dutch Revolt began in 1568 and chugged along for another 80 years, staying as a constant thorn in Spain's side, and various wars across the continent continued to drain the treasury. With all these problems, it's no surprise that Spain fell into bankruptcy several times through the 1500s (1557, 1559, 1576, 1596), a trend that would continue through the next century as well.
What really killed Spain on top of all these financial troubles, however, was its population growth. Spain was already less populous than many of the other continental powerhouses, particularly France, in 1500 (8 million versus ~15 million). But poor financial, economic, and domestic policy did little to encourage population growth and, as the economy sagged and the occasional plague hit, Spain's population remained somewhat stagnant (8.5 million in 1600, down to 7 million by 1700) while the rest of the continent gradually grew. France, meanwhile, had reached 21 million by 1700, and England 9 million. Spain was arguably still a major world power going into the Napoleonic Wars, but following the devastation of the Peninsular War and subsequent loss of most of its American colonies, Spain really had no hope of remaining a world power.