According to unofficial returns, Hogan won by double-digits, securing hundreds of thousands more votes than he got in 2014, when turnout was significantly lower across the state.

“Tonight, in a deep-blue state in this blue year, with a blue wave, it turns out I can surf,” Hogan, 62, told a boisterous crowd in Annapolis. “The people of our great state voted for civility, for bipartisanship and for common-sense leadership.”

AD

But Hogan’s immunity to a Democratic surge did not extend to other Maryland GOP candidates, who lost three key county executive races and at least eight competitive General Assembly seats, according to unofficial returns.

Hogan and his running mate, Lt. Gov. Boyd Rutherford, defeated Jealous in a year when Democrats across the country turned out in droves to protest the presidency of Donald Trump at the ballot box.

AD

“I’m voting for anyone who is a Democrat today,” said Steve Solomon, 61, a lawyer from Potomac. “Our president is a buffoon. . . . You got to send a message that Republicans didn’t stand up to the president.”

But for Solomon, and many others, that fury did not apply to Hogan. “I think he’s done a good job for Maryland,” Solomon said.

AD

In his concession speech, Jealous, a former NAACP president, sought middle ground.

“What’s important in a democracy is to figure out what we can agree on and to go get that done,” Jealous told supporters. “And I say to Governor Hogan tonight, find something we can agree on.”

Hogan remained popular throughout his term, earning goodwill from many Marylanders as he battled cancer in 2015; refusing to engage on the most divisive national issues; and distancing himself from Trump before and after the 2016 elections.

AD

“He’s not a Trump guy,” said David Krall, 70, a retired software developer who voted at Leisure World in Silver Spring and mostly supported Democrats. “He’s voted for a lot of things that are kind of against the standard Republican Party.”

Jealous built his progressive campaign around reducing inequality. He pitched a $15 minimum wage, universal health care, a recreational marijuana industry to pay for universal prekindergarten, debt-free college and huge boost in K-12 education spending.

AD

He and his running mate, Susan Turnbull, refused to take corporate donations.

“I came into this race as a movement leader, and I’ll go out of this race as a movement leader,” Jealous said Tuesday night.

Some Democrats, including many who said they liked the governor, jumped at the chance to cast a vote for Jealous as a way of sending a message to Trump.

AD

“It’s a blue wave,” said Etan Thomas, a 40-year-old retired NBA player, who voted a straight Democratic ticket in Prince George’s County. Of Jealous, he said, “I like what he is fighting for.”

Early voting smashed records this year in Maryland, and many precincts reported unusually high Election Day turnout as well, causing day-long delays in some ­places.

AD

In overwhelmingly Democratic Prince George’s County, a paper ballot shortage meant hundreds of voters were still waiting in line when polls closed statewide and news organizations began declaring Hogan the winner.

Jealous objected to the Associated Press calling the race at 9:07 p.m.

“Stay in line. Keep voting,” he told supporters on Twitter.

But by 11 p.m., with most results in and Hogan leading by a wide margin, Jealous called Hogan to congratulate him.

Establishment Democrats were slow to embrace Jealous’s candidacy, and he struggled to raise money and overcome the rapport Hogan had developed with Maryland voters.

AD

Hogan’s GOP allies spent more than $10 million on television ads painting Jealous as “extreme” and claiming that Maryland couldn’t afford his plans, while touting Hogan as a measured moderate willing to work across the aisle.

AD

Jealous’s campaign and Democratic allies waited until the closing weeks of the campaign to respond.

“I definitely wouldn’t vote for [Jealous],” said Patricia Fulkoski, an 86-year-old Democrat from Anne Arundel County. “I didn’t even hear of him before this, and all of a sudden he pops up. My son said, ‘Well, he was the president of the NAACP,’ but I didn’t even know that.”

Hogan, meanwhile, embraced Democratic proposals such as paid sick leave and free community college for some students, and repeatedly played down his ties to the Republican Party.

“I went into it not as a Republican, but as close as you can get to an independent,” Hogan told a crowd this summer.

He said Tuesday night that while he disagreed with Jealous on many issues, the Democrat “has my respect, and I sincerely wish him well.”

Voters also reelected Attorney General Brian E. Frosh (D) by a wide margin over attorney Craig Wolf (R), in a race that was a referendum on how much the state’s chief lawyer should fight Trump’s policies.

AD

AD

“Democrats have to make a difference because this president is unpredictable and out of control,” said government worker Celeste Brannon, who voted for Frosh in Prince George’s County.

Some Republican voters, meanwhile, said they cast party-line votes as a measure of solidarity for the president. “I’d like Trump to be supported,” Andrea Johnson, 47, said after voting in Prince George’s County.

Hogan and the state Republican Party fell short in their quest to flip enough state Senate seats to break the supermajority Democrats have held in Annapolis for nearly 50 years. That longtime advantage means Democrats can easily assemble the votes they need to override Hogan’s vetoes and curtail his agenda.

AD

The Maryland GOP spent more than $100,000 on races in five Democrat-held Senate districts Hogan won comfortably four years ago. According to preliminary results, the GOP picked up two: Del. Chris West (R) won an open Senate seat in Baltimore County, and Del. Mary Beth Carozza (R) defeated incumbent Sen. James N. Mathias Jr. (D) in an Eastern Shore Senate seat.

AD

But Democrats also flipped at least five GOP-held seats in the House of Delegates.

U.S. Sen. Benjamin L. Cardin (D) easily defeated three challengers to win a third term. All the incumbent House members were reelected as well. In the state’s only open congressional race, Democrat David Trone won the 6th District seat being vacated in January by three-term Rep. John Delaney (D), defeating Republican Amie Hoeber.

AD

In Montgomery County, progressive Democrat Marc Elrich won an unusual three-way race for county executive by a wide margin. And in Prince George’s County, Democrat Angela Alsobrooks was unopposed in her quest to become the county’s first female executive.

While Hogan survived the Democratic wave, two incumbent Republican county executives in Maryland widely considered to be his potential successors did not.

AD

Anne Arundel County Executive Steve Schuh (R) lost his reelection bid to businessman Steuart Pittman (D), while Howard County Executive Allan Kittleman (R) lost to County Councilman Calvin Ball (D). The governor’s pick for the open Baltimore county executive seat, insurance commissioner Al Redmer, lost his race to progressive John “Johnny O” Olszewski, Jr. (D). Together, the GOP losses ensure Maryland’s most populous jurisdictions will be controlled by Democrats.

Maryland voters also approved ballot initiatives to amend the state constitution. One allows for same-day registration on Election Day, the other creates a “lockbox” to ensure money from casinos is always used to enhance K-12 education.

Both Hogan and Jealous emphasized pocketbook issues — but they focused on helping the pocketbooks of starkly different populations.

AD

Hogan pledged to build on modest tax cuts enacted during his first term, attract new businesses, expand college affordability efforts and keep the state moving in what he, and most voters, believe is a positive direction.

Jealous’s plans were far more expansive and included reducing the state’s prison population and creating the first state-run health- care system in the country.

“Ben Jealous is what is necessary for the reformation of our state,” said Patrick Sikorski, a 26-year-old Democrat from Baltimore County who said he trusted Jealous to help the poor and the least-educated.

“Hogan does small things and makes small gestures, but he is not doing enough to help the people.” Sikorski added. “There is a large group of people right now being ignored.”

Hogan, who had four years to build his campaign war chest, outraised Jealous more than 3 to 1, and the Democrat failed to launch effective attacks on how Hogan has governed

The Jealous campaign sought to portray Hogan as a conservative who had not stood up to Trump enough and whose approach was moderated by the Democratic-dominated General Assembly, which overrode many of his vetoes.

For many voters, that attack did not seem to stick.

“Hogan is not a real Republican,” said Michael Sheras, 74, of Rockville, who voted for Hogan but described himself as a loyal Democrat since the era of President Lyndon B. Johnson.

“He has done some really good things for the state.”