Donald Trump does have a precarious - and politically explosive - path to keeping the White House. To do it he needs to get Joe Biden's wins in a series of states set aside.
With his claim that the Supreme Court would do that looking to have evaporated, instead he has to use the procedures of the Electoral College to turn it round.
And he needs to do it in a lot of states: if Georgia and Arizona stay on track for Joe Biden, he will have 306 votes, far above the 270 needed. Trump appears to be taking legal action, or intending to, in six states: Pennsylvania, with 20 Electoral College votes; Georgia, with 16; Michigan with 16; Arizona with 11; Wisconsin with 10; and Nevada with six.
He needs to get at least any two of the larger three states plus one more state to go Republican to get Biden under 270.
Here is how he might manage it:
STEP ONE: GET COURTS TO PUT HOLDS ON CERTIFYING THE VOTE IN TARGET STATES
The vote is not official until it is 'certified' - that is officially declared valid - which happens later in November. Georgia certifies on November 20, and Nevada and Wisconsin are last on December 1.
Trump is already trying to get certification put on hold in Pennsylvania and Michigan, claiming large-scale irregularities. That briefly appeared to succeed in Wayne County, MI, on Tuesday 17 when the Republicans on the bipartisan board of canvassers refused to certify - but only for a few hours before backing down. The next day they said they wanted to withdraw their signatures but it appeared to be too late under state laws; in the meantime Trump thanked them for their support.
OR: GET AN 'AUDIT' REQUESTED OR EVEN BETTER ORDERED - AND KEEP IT GOING PAST CERTIFICATION
Some Michigan Republican state senators have asked for an 'audit' claiming that allegations of irregularity need to be looked into. This could be a useful tool if courts don't come through: at the very least it would allow Republicans to say they don't trust the certification because it has not been audited.
STEP TWO: KEEP THE CERTIFICATION ON HOLD PAST DECEMBER 8
This is the 'safe harbor' deadline when all election disputes must be resolved. If they are not fully played out, whoever has a court ruling in their favor at this point keeps that result. So if Trump has certification on hold in target states, he has a chance to flip them to him starting now.
STEP THREE: GET REPUBLICAN LEGISLATURES TO AGREE TO APPOINT THEIR OWN ELECTORS
You were not voting for the president directly: you were voting for electors to the electoral college. But the Constitution does not say that electors are winners of a popular vote. Instead the Constitution says: 'Each State shall appoint, in such Manner as the Legislature thereof may direct, a Number of Electors.' In the early 19th century, states rapidly moved to make the appointment of the electors the result of the popular vote; by 1832 South Carolina was the only holdout. It stuck with that approach until secession.
So Republicans in at least three and possibly more states would have to decide that because the results are not certified - or because they claim they don't trust the certification because of an audit or the lack of one - that they can take back control for themselves. They would argue that because the results aren't certified or trustworthy, it's up to them to work out the will of the people.
Then - undoubtedly in the face of huge public protest - they would appoint Republicans who will vote for Trump.
This has happened in recent history: in 1960 Hawaii had disputed elections and sent two slates of electors.
STEP FOUR: SWEAT IT OUT WHEN GOVERNORS APPOINT THEIR OWN ELECTORS
All three of the biggest target states - Pennsylvania, Wisconsin and Michigan - have Republican legislatures and Democratic governors. So now the governors could simply appoint their own electors - voting for Biden - and say that their votes are what counts on January 6, when the Electoral College is counted and record in Washington D.C.
STEP FOUR: SURVIVE A SUPREME COURT CHALLENGE TO THE REPUBLICAN ELECTORS
Such a dramatic change would go to the Supreme Court. It has never directly ruled whether states could do that: in 2000, three of the five justices who gave the election to Bush over Gore said that state legislatures had complete control - but that is not a precedent. Now Trump's fate would be in the hands of nine justices, three of whom he appointed and one of whom - Clarence Thomas - said that legislatures are in charge.
Democrats would of course argue that the governors' electors are the right ones, and a titanic battle would play out. If Trump wins - again in the face of likely huge public protest - he is on to the final stage.
STEP FIVE: HOPE THAT THE PENNSYLVANIA REPUBLICAN SLATES DON'T GO FAITHLESS
If Pennsylvania is one of the states to ignore the popular vote, Trump needs its 20 Republican electors to stick to the plan - but the state allows faithless electors. So all, or even some, could make a difference in an already mathematically fraught bid to keep the presidency. But assuming he has enough votes not going to Biden, it is on to Washington D.C.
STEP FIVE: MAKE IT TO JANUARY 6
This is D-day for the plan: The newly-sworn in Congress meets to count the Electoral College votes. The vice-president, Mike Pence, presides, over a joint session. Normally the 'certificates' showing how each state voted are opened in front of the vice-president, the count is recorded and with a bang of the gavel, the electoral college winner is officially declared.
Now Trump needs Republicans in the House and Senate to work together. A member of the House and a senator can jointly object to a state's certificate when it is opened. The last time this happened was in 1877, which caused a months-long crisis, ended by compromise and followed by the Electoral Count Act of 1887.
This time the 1887 rules come into play. If there is an objection, they split into the House and Senate and there are two hours for debate. This has only happened once, in 2005, when a tiny number of Democrats objected to Ohio's vote count. But it was voted down overwhelmingly in both the House and Senate.
And finally, the vote count is in alphabetical order, so Arizona will be the first battleground state where all this could be tested.
STEP SIX: MAKE SURE THE RULES ARE IN YOUR FAVOR
As the Trump ships enters uncharted waters, one issue is unresolved: how do you work out what a majority of the Electoral College is? That seems simple but it might not be. If the House and the Senate come to different conclusions on a state with rival slates of electors, then the question is what happens next.
The most likely answer is that they are simply removed from Biden's total but not added to Trump. But does that mean the states still count in the Electoral College? The 1887 law is not clear: it seems to suggest both options are available, so Congress might have to try to decide - or Pence as president of the joint session could rule.
If Congress goes for the shrinking college, that favors Biden unless Trump has Arizona, Georgia, Michigan and Nevada, Pennsylvania and Wisconsin - all the states being targeted by Trump. But if it stays at 538, then Biden could well lose without Trump actually winning: once it falls below 270, there is no majority and therefore it is up to the House to decide.
STEP SEVEN: KEEP MITT ROMNEY, SUSAN COLLINS AND LISA MURKOWSKI ON TRUMP'S SIDE (AND HOPE PENCE CAN VOTE)
If Trump is to win, he has to have the Republicans in the Senate vote for Arizona's Republican slates as the first order of business.
This is where the Georgia Senate race comes into play.
If the Georgia runoffs are decided and Democrats take both seats, Pence would have to tie break in Trump's favor - if that is allowed. The rules say he is president of the joint session. But they are unclear on whether he retains his tie-break power as president of the Senate. The two roles are not identical and the 1887 law appears to give him a passive, rather than active, role in the session - more like the chief justice presiding over Trump's impeachment trial than a regular Senate session.
But if Republicans get one or both Georgia seats, the Senate will be 51-49 or 52-48, which means that any rebellion by Republicans is extremely dangerous. Assuming that Pence has a tie-break, it would take only two or three rebels to end Trump's run. There are three obvious candidates: Mitt Romney voted to impeach him, Susan Collins owes him nothing after he refused to campaign for her, and he has called for Lisa Murkowski to be primaried.
STEP EIGHT: WATCH A DEBATE WHICH HAS NO PRECEDENT
The 1887 law sets some ground rules for how the House and the Senate debate which slate of electors are valid. They have to decide what the true vote was at the safe harbor deadline - back on December 8 - and which slate of electors were appointed in line with state law. So the debate should - in theory - not be partisan but a determination of which side is valid. In principle, that could mean different outcomes for different states. But assuming that a Arizona goes Trump's way in the Senate and Biden's way in the House, that state is tied - and then it's on to a new constitutional crisis.
STEP NINE: NOW IT'S GETTING REALLY MESSY - COULD THERE BE TWO PRESIDENTS
The law says that Congress can't move on to the next state until debate is resolved over the one in question. But it also says that the meeting cannot be dissolved until all states are decided.
So the whole proceeding could be deadlocked at Arizona. And as long as it remains deadlocked, there is a looming deadline of January 20 - at which point Pence and Trump are out of office anyway. In that scenario, Nancy Pelosi becomes president automatically at noon.
However, Pence could break the deadlock on Arizona by ruling that the votes are not to be counted at all, and debate can resume on the next item.
Democrats clearly would not agree. In that scenario, it is impossible to say what would happen. They could walk out, say the debate is not resolved - which it would not be - and therefore Pelosi would be sworn in on January 20.
But Pence can then rule that the debate in fact is going on even without Democrats, run through the votes with only Republicans and come up with a Trump victory: meaning two rival presidents both claiming they are in charge. Both can be sworn in at noon on January 20, with only one with their personal items in the White House.
What happens then is impossible to say: the Supreme Court could try to rule between them, or the military might have to decide who is commander-in- chief.
THE OTHER STEP NINE: KEEP DEBATING (ALTHOUGH WHY WOULD DEMOCRATS WANT TO?
Of course Democrats could stick with the debate and keep going, debating each state as they go along.
If Trump overturns six states' votes, it is inevitable that Democrats lose, regardless of the rules. If he has fewer states, he will want the 538 figure kept in play to get Biden into a minority. This highly unlikely step gets to neither having a majority in the Electoral College.
STEP TEN: THE HOUSE DECIDES - TRUMP HAS DONE IT
If Trump and Biden end up here this is safer ground: the House has decided before. It does not vote under normal rules. Instead each state delegation gets one vote and has to decide among the delegation how to allot it.
So going by current House results, 27 states have Republican majorities, and all Trump has to do it get a simple majority of them. Trump has triumphed - but it is an exhaustingly long process to get back on the platform on January 20 to be sworn in.