IMO better strategy and tactics made the difference, plus luck.
Was the Spanish Armada sailing into a winter storm bad luck or should they have known it was a dicey season to start a war?
The Spanish had large heavy ships loaded with naval infantry (Marines). They'd grapple along side and board enemy ships. The Brits had smaller, lighter and more maneuverable ships and favored long range cannon attacks.
The Armada, grouped together was impossible to conquer due to size and numbers. The Brits lit up fire ships; a ship loaded with gun powder, lit on fire and allowed to drift by winds and/or current into the Armada where the fire ships would blow up and light several Spanish ships ablaze. The Spanish captains broke formation and fled with their individual ships. This allowed the Brits to attack individual ships piece meal and led to
Battle of Gravelines (1588).
Overall, the Spaniards lost about 2/3s of their 130 ships and about 2/3s of their 30,000 sailors and soldiers. The Brits lost about 100 sailors in combat. Oddly, as the wiki link notes, they later lost up to 8000 from disease (mostly typhus).
https://en.wikipedia.org/wiki/Spanish_Armada
Results count; Spain went home with their tail tucked between their legs and Britain rose to become a global power. Human society turned course.