All very good observations from you guys, so thank you.
However, there are some things to consider that I haven't specified yet:
- I don't intend full occupation of the Maghreb. I agree with the general consensus that Early Modern Spain absorbing even the majority of the land north of the Atlas Mountains and west of El Taref is completely unfeasible. What I mean is more along the lines of strategic occupation of harbors and coastline - primarily in Tingitana, the Moroccan Gharb, and around Oran, Algiers, and the OTL Portuguese possessions on the Atlantic coast - during the 16th through possibly the late 18th centuries. These possessions will wax and wane in size but occupation of the important areas I've specified will mostly be static. This pattern of occupation involves a lot of puppet states akin to the one the Spanish maintained IOTL with the Hafsids in Tunisia, as well as a lot of cooperation with the Genoese, who have similarly invested themselves in this quasi-colonial scheme.
- This occupation preempts a lot of developments that we may take for granted when it comes to how difficult European conquest of the Maghreb might have been. For instance, the reason the Portuguese were expelled from Morocco was due primarily to the power of the highly energetic Saadi dynasty, which revitalized Morocco after its nadir under the Wattasid dynasty. It's not an exaggeration to consider the Wattasid era to have been perhaps Morocco's weakest state since pre-Roman times, and the same could be said for the concurrent Tlemceni sultante in Algeria. IOTL neither the Portuguese nor the Spanish fully took advantage of this low point in the robustness of the North African sultanates, so let's posit that they do in this case. A major military victory on land isn't out of the question.
- Likewise, the involvement of the Turkish corsairs in the Western Mediterranean - which transformed Barbary piracy into the real scourge of the seas it came to be regarded as - has also been seriously curtailed in this scenario, in part due to much earlier and much heavier Spanish involvement in the Maghreb than IOTL. Turkish involvement in the Maghreb quickly brought the area up to speed in terms of military technology and foreign investment, so apart from removing the breather the corsairs gave to North African independence, this also means the Spanish are in uninterrupted control of the ports of Algeria.
- Further, it's important to remember that most of the North African states are still deeply riven along tribal lines at nearly every societal stratum. They've achieved unity on the basis of religion, geography, and history, but none of them are true nation-states in the same sense as Early Modern Spain. Holy war against the intrusive Spaniards will most certainly bring these divided groups into close cooperation, but once they realize that they are unable to fully oust the Spanish, the temptation to use these foreigners in an effort to subvert a rival tribe will grow considerably.
It'll probably involve a bit of ethnic cleansing here and there, most notably in the coast, due to the whole Reconquista mind-set and the conquistadors pushing moral boundaries above all else. The settlement of Europeans in the mid to late 16th century would be followed by ethnic cleansing and expulsion towards the innards of the Sahara creating ethnic tensions between Maghrebis and Berbers.
I expect the Conquistadors to act horrifically, but then again it was the time of the Reconquista Renaissance.
The Conquistadors did bad and evil thinks in the Americas. Apply those bad and evil things in North Africa during the 16th century.
The behavior of the men termed conquistadors was not the official modus operandi of the Spanish or Portuguese militaries or of their foreign policy. Cortes, Pizarro, Alvarado, and the like were all freebooters, usually from disgraced, lowborn, or otherwise desperate backgrounds, operating thousands of sea miles away from royal oversight, in a land they didn't understand against enemies they understood even less and who far outnumbered them. Their actions were scarcely different than those of many of their English, French, or Dutch counterparts who found themselves in the same circumstances. Keep in mind that when Bartolome de Las Casas and his compatriots reported back on the cruelties they'd witnessed in Spanish America, it caused widespread moral outrage in Spain, in turn leading to a formal debate on the matter which ended in condemnation of any savagery committed towards the Amerindians.
None of this is to say that there wouldn't be atrocities committed in a war of conquest against the Muslim North Africans, but there really is no comparison with what occurred in the Americas. The Reconquista saw the Christian Iberians gradually absorbing large numbers of Muslims into their kingdoms for hundreds of years, and any instances of ethnic cleansing during this process are extremely few. Even after the Inquisition was formed or the issue of "limpieza de sangre" ("cleanliness of blood") came to the fore, the subject of racial tension was almost always the Jewry, while one's Muslim ancestry was virtually ignored.
You call creating the first global empire in history "wasted potential"?
No. I call repeatedly bankrupting the Spanish treasury through 80+ years of hopeless warfare against the Dutch, English, French, and German Protestants to the point of full scale economic collapse and the premature curbing of the Spanish empire "wasted potential."