Whether you think the arguments for leaving held water, they convinced a lot of people. Complaining that those people were stupid was guaranteed to piss them off and stiffen their resolve to spite you. Is this what happened? Maybe, maybe not, but this oft-implied attitude on the part of government officials and other members of the elite didn't help.
I think another big factor was a sense that a lot of those in the Leave camp were losing out economically. The elites in London didn't seem to give a damn about people who were being left behind by the roaring economy. That would be the global economy — the same global economy that has left so many behind in the U.S.
The U.S. government hasn't done much to ameliorate the plight of this country's left-behinds, preferring to focus on easing the way for the big corporations that dominate the global economy. In a sense, the federal government has been operating on a supply-side, very conservative economic model: help the companies and they'll "trickle down" jobs. This has been true since 1980 and under Democratic presidents as well as Republican ones.
Unquestionably our economy needs jobs for prosperity. However, the federal government has been blind to all but the stock market for too long. People outside the trendy sectors of the economy have been ignored.
The result? Trump (on the right) and Bernie Sanders (on the left).
Trump also benefits from a backlash against cultural changes. (This, too, was a likely driver of Leave votes in the UK.) To quote Cool Hand Luke, what we have here is a failure to communicate. The urban and cultural elites — and I plead guilty to being both, even if I'm not quite sure what the "cultural elite" is — haven't paid attention to our fellow citizens who don't agree with us on social issues and who were being left behind by the global economy.
It's too late for the U.S.'s urban and cultural elites to do anything about our deafness and blindness that will change the election. But even if Trump doesn't win the presidency, we're going to have to reckon with his supporters. We don't have to agree with (or do anything to encourage) the bigotry and divisiveness he has forced to the surface of the body politic, but we damned sure have to address the legitimate economic grievances that fueled his rise. We need to accord his supporters the respect they're due as our neighbors and fellow citizens. (We can also see about getting them to listen to us, too.)
If we don't come together, the U.S. will follow the UK's example, giving in to hyper-nationalism and isolationism out of a sense of legitimate but misplaced grievance.