Once again, Democrats overperformed in a special election in Trump country. They didn't win a special congressional election in Arizona on Tuesday to replace former GOP congressman Trent Franks, but they came surprisingly close.

Across the country, in New York, Democrats flipped their 40th state legislative seat of the Trump era. It was the first time a Democrat won this state legislative district in more than three decades.

Let's go back to Arizona. On paper, Arizona's 8th Congressional District is not one where Democrats were expected to come close to victory. Franks ran unopposed in this Phoenix-area district for more than a decade before resigning in December over a scandal that involved asking staff members to have his baby. Donald Trump won this seat by 21 points in 2016. So did the past two GOP presidential nominees.

On Tuesday, the Republican, Debbie Lesko, won her race by five points. Hours before the election, a progressive Democrat told The Fix that Lesko winning by seven or eight points would be a reason for Democrats to celebrate.

“We see districts that are written off suddenly having progressive energy,” said Josselyn Berry of Progress Now Arizona, which organized with other progressive groups in the district for Democrat Hiral Tipirneni. “A lot of people write off Democrats not being able to win in deep red districts. We are living in a new political reality, and we can't assume what we always assume.”

Democrats do keep upending political assumptions about what districts are safe for Republicans. In Pennsylvania last month, Rep. Conor Lamb (D) ate into a 20-point Trump margin to win his special election.

Democrats didn't win in Arizona, but they didn't need to. The 8th District is not the kind that Democrats need to win or even come close to winning to take back the House in November. About 147 GOP districts are more competitive than this one, according to a ranking by the nonpartisan Cook Political Report.

That doesn't mean all 147 of those suddenly became competitive. But Democrats need to flip a net of 23 seats to take back the House. They came within five points on Tuesday to flipping the 147th-most competitive. Also worth noting: Twenty-three Republican members of Congress are holding districts that Hillary Clinton won in November.

In Arizona, Democrats hope to build on Tuesday's momentum — and the organizing network they set up deep in Republican territory — to try to win state legislative seats that previously weren't competitive. Berry said Democrats have a candidate in every state legislative district, a first for them.

It's not all good news for Democrats lately. Their margin in a key poll asking whether voters prefer them over Republicans has narrowed recently as President Trump's approval rating has risen, according to a Washington Post-ABC News poll this month.

But when it comes to getting their voters to the polls and/or converting reluctant Trump voters in special elections, Democrats have been performing in a way they could only dream of a year and a half ago. They have outperformed Clinton in six out of seven competitive special congressional elections since Trump took office. They've flipped a Senate seat in Alabama, a governor's seat in New Jersey and a House seat in Pennsylvania. And they've flipped 40 state legislative seats nationwide, including some that Trump won heavily.

This is all despite the fact that Republicans have poured millions into these normally safe congressional seats to try to keep them in their hands. Come November, they'll have to spread out those resources. (Although, so will Democrats, Republicans point out.)

But all of this is why after Tuesday, just as they have after every special election this year, Republicans are sounding the alarm about what November could mean for their party.