WASHINGTON – Congress could not have been more fractured after last month’s bitterly partisan impeachment trial of President Donald Trump.

Prospects that Republicans and Democrats could work together on anything of substance seemed far-fetched, especially given the simmering feud between Trump and House Speaker Nancy Pelosi, D-Calif.

Then the coronavirus showed up on America’s doorstep.

A bipartisan spirit – borne of necessity – emerged. Within weeks, congressional leaders working hand-in-hand with administration officials forged a deal on a historic federal response to a pandemic that has killed hundreds, walloped the economy and derailed America’s daily routines.

Late Wednesday, the Senate voted 96-0 to pass a $2 trillion relief package that would provide checks of up to $1,200 for most adults, give billions in potentially forgivable loans to small businesses and rescue the battered airlines industry. The House is likely to take the bill up Friday and pass it.

Weeks after slamming Democrats for impeaching Trump, Senate Majority Leader Mitch McConnell, called the overwhelming passage of the coronavirus relief bill Wednesday a "proud moment" for the U.S. Senate.

"If I were writing your headline I’d say the Senate has pivoted from one of the most contentious, partisan periods in the nation’s history to passing this rescue package (unanimously) all in one quarter of this year," he told reporters. It "says a lot about the United States Senate as an institution, our willingness to put aside our differences, to do something really significant for the country."

Coronavirus live updates: Half of New Yorkers could face infection; details coming on $2 trillion stimulus; Prince Charles sick

College debt:Student loan borrowers will see coronavirus relief from wage garnishments, collections

How were lawmakers able to – mostly – set aside partisan differences so quickly? They had no choice, said Sen. Marco Rubio, R-Fla., who joined others in comparing the virus’ devastation to war.

“It really is important for us to realize, not just for this bill but moving forward, that there's no such thing as an outcome here that's good for half of us and bad for the other half,” he said on the Senate floor Wednesday. “There is no possible political victory here. None.”

Compromise was complicated by the hostility between Pelosi and Trump (neither has spoken to the other since mid-October when she upbraided him in a White House meeting over his Syria policy.).

Negotiations weren't helped when the virus began infecting members of Congress and forced social distancing in a Capitol known for glad-handing and face-to-face discussions. Nearly three dozen House and Senate lawmakers and even more staff have self-quarantined either because they tested positive for COVID-19 or said they'd been exposed to it.

Seeing members fall victim to the virus or its consequences might have reinforced the urgency. The White House sidestepped political friction by appointing Treasury Secretary Steve Mnuchin as the unassuming and affable point person on negotiations.

Mnuchin and Pelosi spoke frequently this month as they crafted a smaller relief package that promised free coronavirus testing to all Americans and guaranteed two weeks of sick leave for workers affected by the crisis.

As soon as that passed, Mnuchin returned to the Capitol for round-the-clock negotiations with Senate leaders Mitch McConnell, R-Ky., and Chuck Schumer, D-N.Y., on the sweeping $2 trillion stimulus.

When Mnuchin spoke from the podium at a White House news conference Wednesday, he not only thanked his political ally McConnell but also Schumer "for the enormous bipartisan support we have" for the bill.

That night, in the same chamber that voted almost entirely along party lines last month to acquit the president at his impeachment trial, much of the discussion was about the remarkable act of unity that produced the sweeping compromise and its overwhelming approval by the Senate.

"Representatives from both sides of the aisle and both ends of Pennsylvania Avenue have forged a bipartisan agreement in highly partisan times with very little time to spare," Schumer said before the vote. "Its been a long, hard road with a remarkable number of twists and turns, but for the sake of millions of Americans, it will be worth it.”

Pelosi, who described her relationship with Mnuchin as "professional" and "respectful," has worked with him on other big deals, including a two-year extension of the debt limit and spending caps in July. Rep. Peter Welch, D-Vt., said the Treasury secretary “has been very cooperative” with Democrats.

The result of the bipartisan partnership was a bill so expansive it carries a price tag more than half the $3.5 trillion the IRS was expected to collect in tax revenue this year.

At roughly $2 trillion, the measure has something for almost everyone in Congress, a legislative bromide that helped soothe partisan heartburn for all but those lawmakers who still fret about the soaring federal debt.

Park closures:These national and state parks are closed amid coronavirus outbreak

Royal mess:Prince Charles' coronavirus diagnosis is a huge deal for Brits, the monarchy. Here's why.

Democrats won protections for workers, students facing college debt defaults and low-income families at risk of eviction. Republicans secured lifelines for airlines, small businesses and other industries rocked by the economic fallout. Both sides liked the idea of direct payments to help constituents back home.

Among the provisions:

$1,200 cash assistance for individuals, $2,400 for married couples and $500 for each eligible child. This money would be available within three weeks of the bill's passage for all U.S. residents with an income up to $75,000, including those with no income or who depend on Social Security.

Unemployment insurance benefits would be expanded, increasing the maximum benefit by $600 a week for up to four months. Benefits would be available to workers who are part-time, self-employed or part of the gig economy. People who are still unemployed after state benefits end could get an additional 13 weeks of help.

More than $100 billion for hospitals and medical centers to handle surging caseloads.

Food assistance programs would get a boost, as would programs to help low-income households avoid eviction and a program to improve internet access in rural areas.

Small businesses would have access to a nearly $350 billion loan program to cover monthly expenses such as payroll, rent and utilities. The loans would not have to be repaid if businesses maintained their workforce.

Tax credits for companies that keep on workers despite a significant loss of revenue.

A financial lifeline to the hardest-hit industries, including passenger and cargo airlines. Another pot of money would be available to help other businesses for a combined $500 billion.

$150 billion to help state and local governments, which have had major unanticipated expenses while losing revenue.

"Whether it is enough or whether it is a mere bandage depends on how long the pandemic will last," said Peter Koveos, a professor of finance at Syracuse University’s Whitman School of Management. "It gives people some hope and the revelation that the government still functions. We will pay for this later, but the cost will be even greater if we do nothing now.”

Contributing: Nicholas Wu, Maureen Groppe

.