The US paid by far the most for defense and so had by far the most influence and power in the world, and the peace (at least in the Western world) that US defense brought made sure both the US and the EU could freely trade and benefit financially.
What now changed is that apparently the US thinks it does not need this hegemony anymore (by forcing the EU to become a competing military power), or that they can replace the role the EU played with some other combination of countries. Or alternatively, the US is just looking for some "splendid isolation".
To European spectators, the above seems ridiculous. But who knows, maybe Trump is correct... Either way, the US had a good thing going and is now abandoning that. Not strange that Europe is surprised by that move.