On Election Day, finally, there was near-unanimity about one thing: 2020 is an ugly, mean bear, and Americans mean to do something about it.

In the ninth month of spending way too much time at home — when for many millions there was no real school, no church to go to, no work — people were determined to vote, which they did in unimaginable, perhaps unprecedented, numbers.

When the anxiously awaited day finally came, there was hope in Atlanta, where Raheem Nas, having concluded that “the state of our country is unacceptable,” cast his ballot for Joe Biden. Nas, 40, said he acted for his 6-year-old son and out of his own belief that Biden could heal America’s wounds and make it safe for a Black man like him to “change my damn tire on the freeway without getting killed.”

There was fear in Hoover, Ala., where Shannon Zuniga, a 64-year-old catering company employee, said Biden’s election would mean socialism, unrest, “total chaos.” She voted to keep President Trump in the White House because, she said, he would preserve religious freedom and because “he’s a man of his word. He is not always careful of his words. But he loves this country.”

There was humiliation in Kenosha, Wis., where the coronavirus has played havoc with Angela Van Dyke’s life. She lost her job in architecture in California when the pandemic kneecapped the economy. Now she was back in her Wisconsin hometown, taking advantage of same-day voter registration, wearing a gray mask and braving the crowd because she couldn’t trust her ballot to the mail system.

“I’m completely embarrassed over our political state,” said Van Dyke, 36. She voted for Biden as the antidote to Trump’s cavalier attitude toward the virus.

As the nation’s unusually intense election season ended Tuesday, with millions of votes pouring in by mail, in drop-boxes and in person, Americans — perhaps paradoxically — put their faith in the system. For all of this era’s unparalleled mistrust — of government, of institutions, of each other — voting is an intrinsically hopeful act, a statement that things can get better and that the leader of the country matters.

There was no shortage of despair in this vote. There was even, for some, a nagging fear that the election might spin into a chaotic cascade of street violence and court battles. But in churches, schools, town halls, community centers and fire stations across the country, Americans also gathered with some belief, some aspiration, that as Abraham Lincoln told a searingly divided nation in his first inaugural address, “We must not be enemies. Though passion may have strained, it must not break, our bonds of affection.”

In West Palm Beach, Fla., Stacy Savaria’s motive was simple: Heal the divisions, bring people together, get the virus under control.

Her vote was more complicated. Her mail-in ballot sat on her dining room table for two weeks while she pondered. Registered as a Democrat, she said she leans Republican on most issues, especially abortion. A Black professional, Savaria, 43, recalls when the Republican Party recruited people like her into what was going to be a bigger tent.

“I’m not big into politics, but I’m big into morals,” Savaria said. “Republicans used to get that right.” She didn’t vote for president in 2016; she disliked both Trump and Democrat Hillary Clinton.

“The Republican Party is not what it used to be,” she said, adding that she was appalled by Trump: “He mocks veterans. He laughs at people who have disabilities. He separated children from their families.”

Still, when a Democratic canvasser knocked on her door Sunday and told her the country would be lost if Trump won again, Savaria didn’t buy it. “I seriously doubt that America would let that happen,” she said.

That night, she decided she couldn’t vote for Trump, not “with the divisiveness of the country, with covid actually being mocked,” she said. She didn’t like some of Biden’s past statements about Black Americans, she said, but “he’s apologized for them and there is forgiveness after sin.

“So I was like, what if I was the last vote that could have voted in a better system?”

She opened her ballot and filled in the bubble for Biden and Sen. Kamala D. Harris (D-Calif.).

“Maybe one vote really does matter,” she said.

Millions of Americans could not imagine such doubt. They knew their decision long ago. Lincoln, they believed, was too much the idealist when he insisted that “the mystic chords of memory” would hold the country together, that Americans would reunite “when again touched, as surely they will be, by the better angels of our nature.”

These voters rejected any compromise with the other side. The other side, they said, is evil.

As the sun rose Tuesday in Cornelius, N.C., 20 miles north of Charlotte, Phyllis Driscoll was among the first voters at the town hall. She needed to be there for Trump because, she said, God had sent him to lead America.

Over the years, Driscoll, who is 62 and Black, has voted for Democrats and Republicans. She supported Barack Obama and George W. Bush. But she chose Trump in 2016 and again Tuesday because “God is using him to put things back in order” through his support for Israel and his withdrawal from the World Health Organization. Not that Trump was flawless; he could have done more sooner to combat the pandemic. But she forgave him that: “God is molding and shaping him,” she said.

Jamal Walker, a 58-year-old Black man in west Philadelphia, could not forgive the president’s handling of the virus. Walker and his wife fell ill with covid-19 in April. He missed 21 days of work.

Trump “is cold and callous” about the virus, he said. “So many parents lost their children, and children lost their parents. It’s no joke.”

Walker voted for Biden and remained nervous about whether his vote would be counted amid all the talk of vote suppression and ballots not delivered.

“I’m afraid for our country,” he said. “It feels like we’re from a Third World country.”

The travails of this year — the virus, the resulting economic collapse, the protests and violence that followed the killing of George Floyd by Minneapolis police officers — made this election a “significant source of stress” to more than two-thirds of Americans, according to a recent Harris Poll.

With emotions spiking, Americans learned more about the voting system this fall than most ever cared to know. They discovered a crazy quilt of laws and traditions governing how states collect and count votes.

With the coronavirus spreading at its fastest rate yet, Americans found alternatives to the centuries-old tradition of gathering with neighbors to vote. Before Election Day, the number of ballots cast already equaled nearly 70 percent of the total in 2016.

In Tuesday’s long queues, it became clear that a new country was coming out to vote. America is nearing the end of its history with a majority-White population.

The nation is more severely separated by class and culture than ever before, with many people viewing themselves as members of a political tribe, an identity group — something more tightly defined than simply “American.”

Race was a driving force behind many voters’ decisions. Jenifer LaVault registered to vote Tuesday in Manchester, N.H., because she was desperate to cast a ballot for Biden — or, really, against Trump. “I have a biracial son,” said LaVault, who is White, “so it’s personal for me.”

LaVault, 47, said Trump’s failure to speak out against racist violence struck her as an attack on her son. She was sufficiently worried about the election’s outcome that she did more than vote Tuesday. “We’re stocking up,” she said. “Food. Supplies.” The future felt that tenuous.

Although voting mainly proceeded peacefully on Election Day, it was still a trying time for people such as Tamira Jones, 21, a college student in Mesa, Ariz. Even her brief walk to a voting center on Main Street felt intimidating. Her mother, grandmother and her dance and cheer coach all told her to stay safe.

Jones had seen videos of ugly confrontations such as the frightening incident on a Texas highway where drivers waving Trump flags hemmed in a Biden campaign bus. Jones, who is Black, voted for Biden thinking about how Trump has treated minority groups. She craves a president who won’t “egg on” extremists.

“We all live in the same country,” she said. “There shouldn’t be this much tension.”

Voters said the country had fallen into sharply binary thinking: People either love Trump or hate him, said Jo Ann Crooks, 66, who was overseeing a voting center in Tempe, Ariz.

Crooks fell in the dwindling middle: She emailed the White House asking the president to “please stop Twittering.” She prays every night for God to “guide him.” But she was raised Catholic and believes that abortion is immoral. That issue made her choice clear.

She recognized, however, that younger people may see things differently. “The deciding point in this election,” she said, “is going to be whether there’s enough old people around like me to say, ‘Okay, we’re still in charge,’ or there’s enough young people around who are going to vote and say, ‘We’re ready to take over.’”

The new electorate was not exclusively young. Brian Dalley, 60, had never voted before Tuesday. He arrived at Ada Bible Church in Cascade, Mich., at 5:50 a.m., first in a line of about 70 voters that stretched along the edge of the parking lot under a waning moon.

Standing in his plumber’s uniform and a faded American flag hat, Dalley said he’d never felt the need to vote before. The country ran fine without his input.

But in April, after heart surgery, he began tuning in to the news. He did not like what he saw: Protests against the president, protests for racial justice turning violent, people tearing down statues.

“All the chaos and all the looting going on,” Dalley said. “You can be upset, but you don’t have to ruin people’s livelihoods.”

He voted straight Republican.

The biggest change in many voters’ lives this year has been the virus. The cultural rift over how to combat the pandemic was evident at polling places where tensions flared between the masked and the unmasked.

In Green Bay, Wis., outside the Packers’ home of Lambeau Field, Adrian Van Slaars waited to cast his vote for Biden with the virus foremost on his mind.

“I lost a family member to covid. I almost lost a friend. I lost my job,” said Van Slaars, 36, a microbiology lab technician. “I need a president who is not going to take the safety net away from my parents, my grandparents and my disabled daughter.”

Van Slaars’s voice caught as he recalled Trump’s attitude toward the pandemic. “He openly denied it, called it a hoax,” he said. “He countermanded his scientists. I don’t understand how anybody can be so flippant when 230,000 people have died.”

Nearby, Dan Lindner wore a paper surgical mask as he jammed his hands into his pockets in the chill. He was first in the queue to vote, and he’d had his mind made up for a long time.

Trump has handled the virus properly, said Lindner, a retired truck driver: “I honestly think in a few months we will be talking about something else.”

Since the painful 2008 economic collapse, many Americans have been searching for answers; millions have gravitated — with a big assist from the algorithms of the social media companies — toward dark notions about forces conspiring against ordinary Americans.

They’ve embraced the QAnon fantasies of a deep state of bureaucrats undermining the president, obsessed over the economic impact of illegal immigration, and accepted as fact the exaggerations and falsehoods that Trump posts on Twitter.

Lea and Wes Wilson, both 27, had lots of worries as they voted at Arrowhead Stadium in Kansas City, Mo., including the fear that a coronavirus vaccine will be forced on them. They do not vaccinate their toddler son.

“I’ve heard people are going to find out how you vote and come and burn your house down if you vote for Trump. I heard it on the news,” said Lea, who works as a substitute teacher.

“No, it was a friend of ours,” her husband, an assistant manager at an Amazon fulfillment center, corrected her gently. “It’s unfounded.”

Among many voters, there was a craving for something calmer, more decent.

In Jackson, Miss., Deborah Hines, 65, brought a folding chair to her polling place in case anyone needed a break from standing in line. Hines, a real estate broker, offered the chair to Minta Davis, who is 81. Davis declined, choosing to lean on her cane for over an hour.

“We are all blood and we bleed just like each other. And if we don’t help each other, do things for each other, this world is not going to ever be worth anything,” Hines said.

It was her turn to vote.

“I’m voting for humanity,” she said. “Humanity is on the line.”

Rosza reported from West Palm Beach, Fla., and Knowles from Phoenix. Moriah Balingit in Ada, Mich.; Kim Bellware in Kenosha, Wis.; Maura Ewing in Philadelphia; Sarah Fowler in Jackson, Miss.; Mark Guarino in Des Moines; Pam Kelley in Cornelius, N.C.; Peter Kendall in Green Bay, Wis.; Keith O’Brien in Manchester, N.H.; Reis Thebault in Atlanta, Annie Gowen in Kansas City, Mo., and Eric Velasco in Hoover, Ala., contributed to this report.