It will be very hard to get used to the two words “President Trump,” but somehow we will have to figure out a way to survive and keep the country and world intact for the next four years. There are many factors behind the rise of Donald Trump. Clearly, a big part of Trump’s appeal lay in his open expressions of racism, xenophobia, and misogyny.

But this is not the whole story. Many of the white working class people who voted for Trump yesterday voted for Barack Obama just four years earlier. Their character was not transformed in the last four years.

Undoubtedly, part of the story is that some of these people could not bring themselves to vote for a woman for president, even if they could vote for a black man with a foreign-sounding name. There were endless accounts of open and hateful displays of sexism directed against Hillary Clinton and her supporters, many of them encouraged by the candidate himself.

However, even against this backdrop the election was still incredibly close, with states like Wisconsin, Pennsylvania, and Michigan certainly well within Clinton’s reach. There were many factors that depressed Clinton’s vote, most obviously the endless drumbeat about e-mails, which were amplified in the last days of the campaign by F.B.I. Director James Comey’s bizarre intervention into the race.

While many of these factors were beyond the control of Clinton and the Democrats, one factor that was under their control was the decision to push the Trans-Pacific Partnership (TPP). Needless to say, there is little public knowledge of the details of the TPP. But the TPP symbolized a pattern of trade that cost millions of manufacturing jobs in the prior decade and put downward pressure on the wages of the workers without college degrees more generally.

This pattern of trade has been an important factor in the wage stagnation of the last four decades. If the wages of workers without college degrees had kept pace with productivity growth since 1980, they would be more than 40 percent higher than they are today. This is a big deal to these workers and their families. Even if trade was not the whole story of income inequality, working class people are certainly correct to see it as a big part of the picture.

The TPP probably would not have substantially contributed, at least directly, to further depressing wages. We already have trade deals with six of the 11 countries in the pact and have extensive trade relations with the others. Rather the TPP was about putting in place a business-friendly structure of regulation. It also increased patent and copyright protection, with the goal of increasing the profits of the pharmaceutical, software, and entertainment industry. In other words, the TPP was about further extending a pattern of trade aimed at redistributing income upward.

It is important to understand that this is not some natural process of globalization. We deliberately placed our manufacturing workers in direct competition with low-paid workers in the developing world. The predicted and actual effect of this policy is to lower their wages. At the same time, we have left in place or even increased protections that benefit those at the high end. Our doctors earn on average more than $250,000 a year, twice the pay of their counterparts in other wealthy countries. This gap is in large part because we prohibit foreign doctors from practicing in the United States unless they complete a U.S. residency program. There is a similar story of protectionism for dentists who must graduate a U.S. dental school (or recently Canadian).

In addition, making patents and copyrights longer and stronger, both here and around the world, redistributes income from the bulk of the population to those in a position to profit from these protections. This is the story of the Hepatitis C drug Sovaldi, which has a list price of $84,000. The free market price is a couple hundred dollars. We will pay more than $430 billion this year for drugs that would sell for 10–20 percent of this amount in a free market.

There was nothing natural about the upward redistribution we have seen over the last four decades, it was deliberate policy. And the TPP was a symbol of this policy. It was a trade pact that was crafted by and for major business interests.

Although Clinton disowned the pact in the course of the campaign, few took this disavowal seriously. After all, she had overseen much of the negotiation process as Secretary of State and she has been closely associated with backers of this pattern of trade over the course of her political career.

President Obama’s decision to push the TPP this year was in effect waving a red cape in front of an angry bull. Trump made opposition to the TPP and other trade deals a centerpiece of his campaign. While he has presented no coherent alternative position, his explicit opposition likely appealed to many working class voters in key states.

It is certainly possible that pushing the TPP created the margin of Trump’s victory in several key states. The irony of Obama’s decision to push the TPP, rather than just letting it drop, is that the deal now appears genuinely dead. And as a side effect, we have President Trump.