SAO PAULO, May 9 (Reuters) - When Brazil's former President Luiz Inacio Lula da Silva and Judge Sergio Moro meet for the first time in a courtroom on Wednesday, the contrasts - and the stakes - could hardly be greater.
One is the country's most popular president ever and the front-runner in next year's election - a former union leader who still whips up crowds with his fiery and folksy oratory. The other, a soft-spoken law professor who represents Lula's main obstacle to power.
The legacy and political future of Brazil's first working-class president are on the line as Lula faces one of the five criminal cases against him, part of the biggest corruption probe in the country's history.
While denying any wrongdoing, Lula and his lawyers have turned his defense into an attack on Moro himself, arguing the judge's track record in overseeing the graft probe has undermined his impartiality. Lula's supporters are travelling from across Brazil to the southern city of Curitiba to protest outside the court.
Local media has fed expectations of a confrontation with a breathless buildup to Wednesday's hearing. One news magazine's cover painted the two as masked wrestlers going head to head. On another, they are boxers "Settling Scores."
Pollster Datafolha found Moro was one of the few public figures who could beat Lula in the 2018 presidential race - though Moro denies he will enter politics.
The 44-year-old judge has avoided addressing the electoral impact of his decisions and discouraged portrayals of him as David to Lula's political Goliath.
Lula's testimony is just one more step in a three-year-old operation, insists Moro, who has kept lecturing public university students on criminal law as he runs the probe.
"I'm a little concerned by this climate of confrontation, these heightened expectations about something that may be totally banal," the judge said at a public event on Monday, regarding this week's hearing.
Moro has already sentenced dozens of businessmen and money launderers for a bribery scheme paying billions of dollars to politicians in return for public contracts, political favors and deals with state firms such as oil giant Petrobras.
Office holders in Brasilia must be tried by the Supreme Court, so prosecution has moved more slowly against alleged beneficiaries in the ruling Brazilian Democratic Movement Party and the Workers Party, which ran the country under Lula and his successor Dilma Rousseff from 2003 to 2016.
Prosecutors say Lula masterminded the scheme during his eight years in office, but Wednesday's hearing focuses on whether he traded influence for the refurbishing of a beach condo.
On Monday, Moro began hearing testimony in a second trial against Lula, regarding 12 million reais ($4 million) of land bought by a construction firm to be used for his institute.
A conviction in either case, if upheld in an appeals court before elections in October next year, would bar him from seeking office.
While Lula's allies are calling for tens of thousands of partisans to convene in Curitiba, Moro posted a Facebook video discouraging a rival march by supporters of the investigation.
Yet even that call for restraint stirred controversy.
"Judge Moro, who ought to be impartial, is speaking directly to his supporters. That is not normal in a democratic system. In a democracy, politicians have supporters and adversaries - not judges," said Lula attorney Cristiano Zanin in a video response.
The exchange underscored that while both Lula and Moro face public scrutiny, the judge may have more to lose if the interrogation devolves into a contentious exchange.
A courtroom spat would stoke complaints from Lula supporters who call the investigation a political witch hunt and bolster his lawyers' demands that another judge try the case.
Attempts at such a legal maneuver are not uncommon, said Oscar Vilhena Vieira, dean of the law school at the Getulio Vargas Foundation. In Brazil, the same judge is usually responsible for overseeing an investigation and then ruling on a case.
Yet relations between Moro and Lula's team are especially tense amid their campaign to discredit him, which included the lawyers' complaint to the United Nations that the judge violated Lula's human rights during the corruption investigation.
Moro often cites the value of public support for the task force he oversees, pointing to the lessons of Italy's "Mani Pulite" graft probe in the 1990s to show the importance of popular opinion to sustain a major corruption investigation.
"From a political perspective, there is a greater risk for Judge Moro," said Vieira. "His rhetorical options are far more limited. He has to take great care not to fall into the traps set by Lula's lawyers." ($1 = 3.2 reais) (Reporting by Brad Haynes; Editing by Brad Brooks, Daniel Flynn and Andrew Hay)