Democrats rebounded Tuesday in some of the Rust Belt and Midwestern states that helped deliver Donald Trump the presidency, scoring statewide wins in Pennsylvania, Michigan, and Wisconsin — and offering the party hope that it might be able to reclaim a vital piece of the president's coalition.

En route to landslide victories, Gov. Wolf and Sen. Bob Casey carried key Pennsylvania counties rich with white working-class voters who flipped from Barack Obama to Trump in 2016.

Their reelections, plus big Democratic victories in the other states, provided evidence they could still compete in the states where many of those voters favored Trump two years ago. Winning those three states, along with each one carried by Hillary Clinton in 2016, would enable Democrats to win back the White House in 2020.

"What shocked Democrats in 2016 and what led to the election of Donald Trump was Democrats losing not Ohio, not Florida, but part of the so-called blue wall in Michigan, Pennsylvania, and Wisconsin," said J.J. Balaban, a Philadelphia-based Democratic strategist. "And the results on Tuesday night showed very clear signs of Democratic strength in Pennsylvania and Michigan," with more of a mixed verdict in Wisconsin, he said.

Of course, Trump wasn't on the ballot, and his unique brand defies easy comparison to other Republican candidates. But there were warning signs nonetheless.

In Wisconsin, Democrats knocked off Republican Gov. Scott Walker and swept other statewide races, though the GOP maintained its sizable majority in the legislature.

Democrats in Michigan easily won the governor's office, retained a U.S. Senate seat, flipped two House seats, and made inroads in the state legislature.

And alongside Wolf and Casey, Pennsylvania Democrats won three GOP-held U.S. House seats and ousted incumbent state Senate and House Republicans in the Philadelphia suburbs.

"I think it always was going to be a challenge" for Trump to hold the Rust Belt states, said John Brabender, a Republican consultant based in Virginia. "That was the only path, but it's not a path that's easy to repeat."

Trump won Pennsylvania, Michigan, and Wisconsin by the narrowest of margins, so even a small decrease in support or increase in opposition could rewrite the electoral map.

And, Brabender noted, Trump won't have the benefit in 2020 of running against the deeply unpopular Clinton, who became "the poster star of everything that's wrong with Washington."

The Democrats who won Tuesday, like Wolf, don't come with heavy baggage, Brabender said.

"If the election were held today and it was Trump and Joe Biden, Biden's winning Wisconsin, Michigan, and Pennsylvania," said U.S. Rep. Ryan Costello, a Chester County Republican who didn't seek reelection.

Analyses by Fox News and CNN both showed a majority of voters Tuesday had unfavorable opinions of Trump in the three states. He had better ratings in Ohio, where Democrats lost the governor's race, and where the GOP's grip appears more secure.

In a sign that some Trump voters are still open to voting for Democrats, 1 in 7 Trump voters who participated Tuesday voted for Wolf, according to exit polls, and 1 in 8 voted for Casey. Nearly all Clinton voters backed the Democrats again.

At the same time, Republicans and Democrats alike cautioned against reading too much into the midterm results. Democrats had established incumbents running in the Rust Belt Senate races. In addition, Trump's unique persona is difficult if not impossible to replicate, and the Democrats could well nominate another flawed candidate in 2020.

Nevertheless, the results were cause for concern for the GOP, especially in Pennsylvania, where the party's support among college-educated suburbanites continued to erode.

Consider Casey: He won the four suburban counties outside Philadelphia by 13 percentage points in his previous reelection, in 2012. On Tuesday he won the same counties by 25 points.

The Republican candidates at the top of the ticket represented two strains of Trumpism, Balaban said: Gubernatorial candidate Scott Wagner embraced Trump's blunt style, and Senate nominee Lou Barletta ran on Trump's hard-line immigration policies.

Both were defeated soundly — Wagner by 17 points and Barletta by nearly 13. Trump recruited Barletta to run and held rallies in the state during the campaign. Vice President Pence campaigned here and helped raise money.

Traditionally, Philadelphia's four Pennsylvania collar counties have been the bellwether for statewide campaigns. But in Pennsylvania and other swing states, Trump offset big losing margins in suburbs by drawing out droves of white, working-class voters who had traditionally supported Democrats.

The election hinted at cracks in that coalition.

After Trump captured three counties that Obama carried in 2012, Wolf and Casey won back two of them — Erie and Northampton.

In Barletta's home county of Luzerne — which Trump carried by 20 percentage points — Casey lost but held down the margin to 8 points. Wolf won the county narrowly.

Republicans also suffered defeats down ballot in these counties. Democrat Susan Wild, the Allentown lawyer who won a GOP-held House seat in Pennsylvania's Seventh District, carried Northampton, and Democratic Rep. Matt Cartwright won Luzerne as he was reelected.

Democrat Ronald DiNicola lost the 16th District congressional race by a slim margin, but he carried Erie County by nearly 20 percentage points. Turnout in the county was the highest for any midterm election since 1994.

"We want to put to rest the notion somehow that Erie turned red," said Jim Wertz, chairman of the Erie County Democratic Party.

Democrats say they can cut into Trump's rural advantage by playing up issues like health care, opioids, and infrastructure. Speaking Thursday in Washington, Democratic National Committee Chairman Tom Perez pointed to Tony Evers, who defeated Walker, as a prime example.

"He has spent a lot or time in rural Wisconsin and we were all organizing," said Perez, noting that voters there cared about protections for pre-existing medical conditions, and fighting opioid addiction.

Casey, in an interview, noted that health care has turned from a liability to an asset for Democrats, now that the party has pressed it more vigorously and that voters have seen a House repeal vote that would have brought real consequences, rather than earlier GOP protest votes.

When Democrats held the White House and could block the repeal efforts, he said, voters "never really felt the urgency of that threat."

Staff writer Jonathan Lai contributed to this article.