Trump’s threats and hectoring have rattled Europe, but growing defense budgets and lasting mutual interests mean the alliance is more likely to endure than to collapse.