WASHINGTON — On Wednesday morning, the Senate appeared headed down an unavoidable collision course with potentially calamitous consequences: Republicans refused to allow a vote raising the federal debt ceiling to pay the government’s bills unless Democrats capitulated to their procedural demands. Democrats would not do so, and no obvious plan to avoid an unprecedented federal default was anywhere was in sight.

But hours later, as senators were set to take a key procedural vote that would have heightened the confrontation, an off-ramp appeared: Senate Minority Leader Mitch McConnell, R-Ky., announced Republicans would allow Democrats to advance a roughly two-month debt increase.

Senate Democrats chose to accept the deal, crowing that it represented a Republican capitulation: "McConnell caved," announced Sen. Elizabeth Warren, D-Mass., Wednesday as she left a private meeting.

But the political scorekeeping behind the deal, which passed Thursday night, is not quite so simple. Like most deals on Capitol Hill, the agreement to punt the debt-limit fight into December reflects a convergence of interests that is not always obvious in the heat of the moment. And, like most deals on Capitol Hill, it has left mixed feelings on both sides and involves implications that could take months to sort out.

For most Republicans, the notion of backing off their once-ironclad negotiating position has been hard to swallow. Since July, McConnell insisted that Democrats would have to raise the debt limit themselves using budget reconciliation, a process that can allow legislation to pass with a simple 51-vote majority, bypassing the 60-vote threshold needed to break a filibuster.

McConnell's Wednesday offer clearly retreated from that position, to the chagrin of former president Donald Trump, who said he was "folding to the Democrats," and even to some of McConnell's closest allies.

"Is anybody excited about this?" Sen. John Cornyn, R-Texas, mused to reporters, hours before Senate Republicans huddled privately to work out who among them would have to cast a difficult procedural vote that would allow Democrats to pass the two-month debt patch.

Yet even some of those opposed made clear that they saw the logic in McConnell’s move. “I think there are plenty of respectable reasons to be a yes,” said Sen. Kevin Cramer, R-N.D., going so far to call the move “elegant” just hours before voting against advancing the deal.

On the most superficial level, Republicans are calling Democrats' bluff: As the GOP insisted that Democrats use the convoluted budget reconciliation process to raise the debt ceiling on party lines, Democrats protested that it would be too perilous and time-consuming to do so, risking a possible default.

Those protestations didn't hold much water: Democrats have already used reconciliation once this year to pass their $1.9 trillion American Rescue Plan, and they are halfway through the process of using it again to advance Build Back Better, their massive domestic policy agenda. The short-term extension would seem to remove any fig-leaf excuse that time was an issue.

The political implications of using reconciliation, however, were a genuine issue for Democrats. Doing so would create an explicit link between the rising national debt and their ambitious legislative plans, which Republicans are eager to cast as a radical expansion of federal government, even as Democrats insist that tax hikes, prescription drug savings and other offsets would prevent any additional budget deficits.

Moreover, due to the vagaries of Senate reconciliation rules, Democrats likely would have had to raise the debt ceiling to a specific number — likely $30 trillion or more — rather than simply suspending it into the future as most recent Congresses have done.

That, to many Republicans, was the sine qua non of their debt ceiling stance: creating a number that Democrats would have to defend in their 2022 midterm campaigns, never mind that the GOP has done more than its fair share to add to the present debt.

"Our goal has always been … they need to do it on their own.," said Sen. Ron Johnson, R-Wis. "And it can't just be a suspension. We can't give them a blank check. They've got to put a dollar amount to it."

The debt patch passed by the Senate Thursday includes just such a number: $480 billion. While that is only a fraction of what Republicans hope Democrats will ultimately approve, and it did not happen through reconciliation, it has broken the Democrats' tacit insistence on simply suspending the limit into the future.

While those could be considered tactical victories for Republicans, the other GOP interests are strategic. Democrats on Tuesday made clear that they were entertaining a dramatic Plan B if Republicans did not call of their intransigence: a modification of the filibuster — the cornerstone of minority power in the Senate — to allow the debt ceiling to be raised with a simple majority vote.

Liberal Democrats have maneuvered for months to push for a weakening of the filibuster to advance their policy agenda, but the vocal opposition of Sen. Joe Manchin III, D-W.Va., Sen. Kyrsten Sinema, D-Ariz., and a handful of other skeptical institutionalists has kept it off the front burner. An imminent federal default with no other option, however, could change that.

In a private GOP lunch Wednesday, McConnell made clear that the possibility was on this mind — explicitly noting to colleagues, according to multiple attendees, that the short-term punt was a solution that Manchin and Sinema would go along with. Put simply, it was an alternative that would avert a potentially costly confrontation over the Senate rules.

The "integrity of the Senate," McConnell told his colleagues, was at stake.

There was also another, unspoken reason for the punt: After Democrats had spent all of September bitterly divided over the shape of their domestic agenda — pitting liberals against moderates in increasingly messy clashes — the debt limit fight had united them in battle against Republicans' brazen demand: Pass a necessary debt limit hike by yourselves, under a process we dictate, so we can attack you for it in next year's election.

The two-month delay, according to Republicans familiar with McConnell's thinking, aligns the debt fight to an early-December government shutdown deadline, allowing Democrats to return to the messy business of their own internecine policy warfare, knowing that more tough votes on spending and debt lie on the other side, two months closer to Election Day.

"Take all the time you want," Cramer said. "That's certainly how I view it. Time is not their friend."

For Democrats, meanwhile, the calculations were much simpler: With a Washington “trifecta” — in control of the House, Senate and White House — the party is keenly aware of its governing burden, and of the difficulty of blaming a catastrophic federal default on Republican procedural tactics. Blowing past a Republican off-ramp on the road to crisis would have made that task even harder.

"With so many things happening here in Washington," Majority Leader Charles Schumer, D-N.Y., said Thursday, "the last thing the American people need is for the government to grind to a halt."

For Democrats, the ability to claim that they had bested McConnell in an old-fashioned Capitol Hill staring contest was icing on the cake, with the internal strife McConnell invited inside his own party from Trump and his allies, who shared Warren's assessment of a "cave," looking a lot like whipped cream and sprinkles.

But the most important thing that Democrats got out of the punt is time. A self-imposed end-of-month deadline for coming to an internal agreement on the shape of the Build Back Better plan looms, and an extended debt limit confrontation threatened to upend that effort. Now Democrats can spend the month hashing out their differences and getting the centerpieces of their governing agenda on President Joe Biden's desk.

"We cleared the deck so we can work on our most important priority," said Sen. Brian Schatz, D-Hawaii. "I do think we got the better of this arrangement."

If they succeed in delivering trillions of dollars of infrastructure, climate, health care, and other legislative priorities to form the basis of 2022′s midterm campaigns, Democrats may find that swallowing a big debt limit increase alongside it to be almost palatable. And if they don’t, McConnell and Senate Republicans will be the ones crowing.