Evan Vucci / AP

In last week’s election, the bill came due on the defining bet placed by congressional Republicans during the Donald Trump era.

Led by House Speaker Paul Ryan and Senate Majority Leader Mitch McConnell, House and Senate Republicans made a strategic decision to lock arms around Trump over the past two years. They resolutely rejected any meaningful oversight of his administration; excused, or even actively defended, his most incendiary remarks; buried legislation to protect Special Counsel Robert Mueller; and worked in harness with the president to pass an agenda aimed almost entirely at the preferences and priorities of voters within the GOP coalition, including tax cuts and the unsuccessful attempt to repeal the Affordable Care Act. Even as Trump’s presidency careened through daily storms, many of his own making, they lashed themselves to its mast.

In the election, the consequences of that decision became clear. The general trend in midterm elections is that voters’ decisions, for both the House and the Senate, increasingly correspond with their attitudes about the president. But the 2018 results raised that long-term trajectory to a new peak.

In the midterms of 2006, 2010, and 2014, between 84 and 87 percent of voters who approved of the president’s job performance voted for his party’s candidate in their local House race, according to exit polls. Last week, 88 percent of Trump approvers said they backed Republicans for the House, according to results from the Edison Research exit poll, which was conducted for the National Election Pool and published on the CNN website.

Likewise, in those previous three midterm exit polls, between 82 and 84 percent of voters who disapproved of the president voted against his party’s candidates for the House. But on Tuesday, that number soared: Fully 90 percent of Trump disapprovers said they voted for Democrats for the lower chamber. That was the worst performance for the president’s party among disapproving voters since Ronald Reagan in 1982.

Political strategists in both parties generally consider it easier for senators to establish an independent identity from the president. But attitudes about Trump were a powerful force in those races, too. Exit polls were conducted for 21 Senate contests in which a Republican faced a Democrat. Democrats won at least 90 percent of voters who disapproved of Trump in 15 of those 21 contests, and up to 89 percent in five more. Scandal-tarred New Jersey Senator Bob Menendez was the only Democratic candidate to win a smaller share of voters who disapproved of Trump, at 79 percent.

Meanwhile, Republicans carried at least 90 percent of Trump approvers in seven of the 21 Senate races, and between 80 and 89 percent in 13 others. Joe Manchin in West Virginia was the only Democrat to hold his Republican opponent to less than 80 percent of Trump supporters.

The power of these relationships shaped the outcome in both chambers. In total, the tightened connection between votes for Congress and attitudes about Trump was a negative for Republicans because significantly more voters disapproved of him (54 percent) than approved (45 percent) in the national House exit poll.

Those topline numbers contained a stark divergence that drove the pattern of congressional results. This year’s exit poll found that just over three-fifths of whites without a college degree approved of Trump’s performance. That helps explain why Democrats made only very modest gains in rural or heavily blue-collar House districts. (Northeast Iowa and two upstate New York seats were among the few exceptions.)

That support also powered the Republican Senate victories in the preponderantly white and blue-collar heartland states of Indiana, Missouri, and North Dakota. Huge margins among working-class whites also keyed the apparent GOP wins in the Florida and Georgia governor’s races, and in Florida’s close Senate race. The biggest exceptions to this pattern were two folksy Democrats, Manchin in West Virginia and Jon Tester in Montana, and the populist Sherrod Brown in Ohio, who each won in predominantly blue-collar states where a majority of voters said they approved of Trump’s performance.

On the other side of the ledger, almost exactly three-fifths of whites with a four-year-college degree or more disapproved of Trump, as did just over 70 percent of nonwhites. That gale-force rejection powered the sweeping Democratic gains in white-collar and diverse metropolitan House districts across the country. Democrats swept away Republicans clinging to House seats in otherwise blue metropolitan areas in and around New York, New Jersey, Philadelphia, Northern Virginia, Miami, Chicago, Detroit, Minneapolis, Denver, Tucson, Seattle, and the northern exurbs of Los Angeles.

The recoil from Trump extended even to many of the metro areas where the GOP had maintained an advantage in recent years. Republicans lost House seats in Richmond, Charleston, Atlanta, Houston, Dallas, Oklahoma City, Kansas City, California’s Orange County, and possibly Salt Lake City. For Republican members in both varieties of suburbs, occasional votes against party positions or tepid and intermittent public quibbles with Trump’s behavior could not mollify voters dismayed by the GOP’s overall subservience to his leadership.

The same dynamics were evident in statewide contests. In Senate and governor’s races, Democrats scored decisive victories in suburban counties that have moved toward them in recent years, from Arapahoe and Jefferson Counties in Colorado; to Montgomery, Delaware, Bucks, and Chester Counties in Pennsylvania; to Oakland County in Michigan; to Hillsborough and Orange Counties in Florida. But as in the House races, the collapse also extended to places that had functioned as the GOP’s last outposts inside metro America.

Trump in 2016 carried only 13 of the nation’s 100 largest counties, according to data compiled for me by the Pew Research Center. But last week, about half of that already modest group shifted toward Democrats in statewide races. Maricopa County, which includes Phoenix and its surrounding suburbs in Arizona, was the largest county that Trump won. But as of Tuesday night, it provided the Democrat Kyrsten Sinema a decisive margin of about 40,000 votes in her Senate victory over the Republican Martha McSally.

Tarrant County in Texas, which includes Fort Worth, was the second-largest county that Trump carried. But last week, it narrowly backed the Democrat Beto O’Rourke over the Republican Ted Cruz. Among the other large counties that Trump took in 2016, Suffolk (New York), Pinellas and Duval (Florida), Macomb (Michigan), and Oklahoma (in Oklahoma) all broke for Democrats in governor and/or Senate races.

Texas offered perhaps the most dramatic example of the undertow Trump has created for Republicans in metropolitan areas. In addition to his slim win in Tarrant County, O’Rourke carried Harris County (including Houston) by about 200,000 votes, Dallas and Travis Counties (including Austin) by around 240,000 votes each, and Bexar County (including San Antonio) by roughly 110,000 votes. As recently as 2012, Barack Obama’s combined margin across those four counties had been only about 175,000 votes. (He lost Tarrant by 94,000 votes, whereas O’Rourke won it by about 6,000.)

The surge toward Democrats in Harris County was so strong that the party elected a slate of candidates to posts across the government, including 17 African American women to county judgeships and a 27-year-old Latina who had never held public office to the job of the county’s chief executive. Democrats also won a majority on the county commission.

And O’Rourke extended his gains beyond core urban counties to win surrounding suburban areas, including the counties of Fort Bend (near Houston) and Williamson and Hayes (outside Austin). Obama lost all three in 2012 and Hillary Clinton lost the latter two in 2016; she carried Fort Bend only narrowly. Democrats still face an uphill climb in Texas, but by consolidating their advantages in its largest urban centers in the O’Rourke race, they have established a foundation from which to plausibly contest the state for the first time since the early 1990s.

Even with the GOP’s net gain in the Senate, these patterns represent a heavy price to Republicans for the choice congressional leaders made to bind the party to Trump. Paul Ryan, who had been among the most openly skeptical of Trump during the 2016 election, sublimated any private doubts to a posture of public deference and a policy of legislative cooperation. Now Ryan leaves Washington as the architect of the GOP’s biggest loss of House seats in any election since Watergate.

Kevin McCarthy, who House Republicans selected Wednesday to replace Ryan as their leader, pressured his fellow California Republicans to stand with Trump on key votes. As of now, Republicans have already lost four of their California House seats; as the vote counts continue, they are highly likely to lose a fifth (Mimi Walters’s seat in Orange County), and could surrender a sixth (the open Orange County seat vacated by Ed Royce). Even a seventh loss (for Representative David Valadao in the Central Valley) remains possible, though not probable at this point. After following McCarthy’s lead, California Republicans will emerge from the midterm elections holding no more than 10, and possibly as few as seven, of the state’s 53 congressional seats. It appears that no Republican will capture even 40 percent of the vote in any statewide California election either.

These reversals don’t mean Trump can’t win in 2020. Midterm elections have not consistently predicted presidential results two years later. Big midterm losses for the president’s party in 1958, 1966, 1974, 1978, and 2006 did foreshadow a shift in control of the White House in the next presidential contest. But Dwight Eisenhower in 1954, Ronald Reagan in 1982, Bill Clinton in 1994, and Barack Obama in 2010 all recovered from significant losses in their first midterms to win reelection with margins that ranged from comfortable (Clinton and Obama) to overwhelming (Eisenhower and Reagan).

In this election, Democrats demonstrated renewed strength by winning Senate and governor’s races in the three Rust Belt states that keyed Trump’s victory: Pennsylvania, Michigan, and Wisconsin. And they sent a clear message that Republicans in 2020 can’t entirely count on the emerging Sun Belt battlegrounds of Georgia, Arizona, and Texas. North Carolina, where Republicans lead by about 80,000 ballots in the total House popular vote, also remains highly competitive, if leaning slightly toward the GOP.

But Trump is likely to be a much stronger competitor in the big three midwestern states than the Republicans who were on the ballot last week. And while Democrats don’t necessarily need to win Ohio or Florida in 2020, last week’s results offered them more reason for concern than optimism in those states, which have been the past quarter century’s most fiercely contested swing states. Ohio, at least, is unlikely to again draw the huge investment of time and money from Democrats that it has in the past.

Whatever it augurs for Trump’s own chances, though, the 2018 results underscored how he has truncated the opportunities for congressional Republicans. So long as the party is defined by his racially infused nationalism, it will be a strong competitor in states and House districts dominated by older, blue-collar, and evangelical white voters. But at the same time, the party seems guaranteed to struggle in suburban areas. It will also face growing challenges in Sun Belt states from Democrats who can mobilize an urbanized coalition of Millennials, minorities, and college-educated whites. This year, those voters elected to the Senate Sinema in Arizona and Jacky Rosen in Nevada. And they allowed O’Rourke in Texas and Stacey Abrams in the Georgia governor’s race to run more competitively than any Democrat had in those states for decades. That same formula in 2020 could threaten Republican Senate seats in Colorado, North Carolina, Arizona, and possibly Texas.

Over the past two years, Republicans up and down the ballot could have tried to establish an identity divorced from Trump. Instead, led by Ryan and Mitch McConnell, they sent voters an unmistakable signal that they would not act in any meaningful way to restrain, or even to oversee, him. In 2018, voters in turn sent Republicans an equally unmistakable signal: that their fate is now inextricably bound to the volatile president they have embraced as their leader.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.