Hillary Clinton and Donald Trump won Tuesday night in Virginia. But the details of their victories should make Democrats happy and Republicans nervous.

The state is a crucial battleground for both parties in November. Most analysts say that the winning candidate will be whoever dominates in the voter-rich suburbs and exurbs of Northern Virginia.

In Fairfax, Loudoun and — narrowly — Prince William counties, Sen. Marco Rubio (Fla.) outperformed Trump on Super Tuesday, and Ohio Gov. John Kasich had his own strong current of support.

“Ground zero now is all those Rubio and Kasich voters in Northern Virginia,” said Dan Scandling, a longtime aide to former Republican congressman Frank R. Wolf.

Virginia primary exit poll results

If Trump is the GOP nominee, he said, “where are they going to be in November? Do they stay with the party? Do they vote Democratic? Or do they just not vote in the presidential race?”

Exit polling suggests the latter two options are possible. A majority of Virginia Republican voters — 55 percent— said they would be dissatisfied with Trump as their party’s nominee.

In addition, several Republican voters told The Washington Post on Tuesday that they probably would not vote for Trump in November. Dario Sotomayor, 30, a Rubio voter in Arlington, said that if Trump gets the nomination, he will actively work for the Democratic nominee.

“Trump is forgetting where [his family] came from. He’s forgotten the roots of this country,” said Sotomayor, a Texas-born businessman of Mexican descent. “He’s inciting everyone into thinking racism is right.”

By contrast, 78 percent of Democratic voters said they would be satisfied with Clinton as their party’s nominee. Her victory in the state crossed all demographic lines: She won among men and women, among low-income and high-income voters, and in every region but the rural west. She also won with every age group except 17-to-29-year-olds.

Republican officials took comfort from the high Republican turnout on primary day — twice as many voters as in 2008, the party’s most recent non-incumbent presidential primary. “We just blew the Democrats’ numbers out of the water,” said the state party chairman, John Whitbeck. “It was a great night for us.”

Republican presidential candidate Donald Trump said “the loser of the night was Marco Rubio” during his celebratory speech on Super Tuesday. “At least you can say that Ted has won something,” the front-runner said. (Video: Reuters/Photo: Jabin Botsford)

Democratic turnout, on the other hand, sank by a fifth.

But with nearly all precincts reporting Tuesday night, Clinton had received 497,581 votes, and Trump had 352,833. In Loudoun, where voters have backed the winning general-election candidate in every presidential race since 2000, Rubio and Kasich combined to win a majority of the Republican votes, and Trump lost to Rubio by double digits.

“To me, the most important and impressive story of the night so far is the breadth and diversity of the @HillaryClinton coalition in Virginia,” tweeted Democratic pollster Geoff Garin, who advises a pro-Clinton super PAC.

Some Clinton supporters were openly speculating that the surge in Republican votes Tuesday came in part from Democrats who plan to support their party’s nominee in the fall but chose to cast Republican ballots in Virginia’s open primary.

One bright spot for Trump: He essentially tied Rubio in Prince William, an increasingly diverse county that — like Loudoun — has been a bellwether in recent elections. Anger over illegal immigration runs high among Republicans there, and Corey A. Stewart, the county board chairman, stood strongly behind the business mogul, chairing his statewide campaign.

“Trump is the only one who is likely to do anything about illegal immigration, and I think that definitely hits a nerve in Prince William County,” Stewart said.

In 2014, U.S. Senate hopeful Mark R. Warner (D) narrowly lost Loudoun to Republican Ed Gillespie. But Warner beat Gillespie in Prince William and went on to win the state, and Stewart suggested Wednesday that Trump could forge a similar path to victory.

At the same time, Clinton got thousands more primary votes in Prince William than Trump did.

Former congressman Thomas M. Davis, who is helping Kasich, said it is still too early to assume that Trump will be the party’s nominee.

“John Kasich could actually beat Hillary Clinton up here in November,” said Davis, who represented Fairfax while in Congress.

He also disputed the idea that Kasich cost Rubio a win in Virginia by splitting the anti-Trump vote. “At this point, we’re all on the same team,” Davis said, with the common goal of stopping Trump at the Republican convention. For that to happen, he maintained, Kasich needs to stay in the race until Ohio’s March 15 primary.

Stewart, meanwhile, argued that it is “too hard to extrapolate the results of a primary to a general election. No poll, no exit poll of any kind, can tell us how people are going to feel eight months from now.”