Economic nationalists appeared to gain the upper hand in a White House battle over trade with the resignation of Donald Trump’s top economic adviser, Gary Cohn, on Tuesday in a move that could ramp up protectionist measures that risk igniting a global trade war.