In a curt public statement on Feb. 19, Bolsonaro canned the head of state-run oil firm Petrobras, who had infuriated the president by raising fuel prices. Bolsonaro then named a retired Army general with no experience in the oil and gas industry to lead Latin America's biggest crude producer.

The abrupt move, coming after assurances from Bolsonaro that he would not "interfere" in the publicly listed company, triggered panic selling of Petrobras shares and other Brazilian equities. Analysts quickly downgraded a slew of Brazilian assets from state banks to sovereign debt.

Petrobras has lost 18% of its value this year, dragging São Paulo's Bovespa index to the steepest drop of any major world index.

While the Petrobras bombshell took some investors by surprise, it was consistent with Bolsonaro's track record. An ex-Army captain and outspoken admirer of Brazil's former military dictatorship, he has long espoused a brand of right-wing populism that, in his support for government-controlled industries, overlaps with that of the leftist politicians he loves to trash. In nearly three decades as a legislator, Bolsonaro voted repeatedly to maintain state monopolies.

During his 2018 presidential campaign, however, Bolsonaro pivoted to win the support of the country's business class. He portrayed himself as a free-market convert ready to unleash a trillion dollars worth of privatizations. He named some market-friendly economists to his team and promised to let Petrobras be run like a private company.

The president's recent moves have strained that tenuous alliance.

In recent months, Bolsonaro has harangued the head of a state bank over staff cuts, slow-walked privatizations of state-run enterprises and derailed promised reforms, including one that would have made it easier to fire civil servants and cut their benefits. In the process, he has drawn comparisons in local press to another military man-turned-president: Venezuela's late leader Hugo Chavez, the socialist firebrand.

Looking ahead to the 2022 presidential election, Bolsonaro may have little incentive to change course. Former President Luiz Inácio Lula da Silva - a lion of the Brazilian political left and avowed foe of privatization - now looms as a possible opponent.

Such pressure may push Bolsonaro even further from the already weakened market-friendly wing of his cabinet.

"All these controversial reforms have lost their appeal for a president who was never a fan of orthodox economic policies," said Leonardo Barreto, director at the political consultancy Vector in Brasília. "Bolsonaro will increasingly wear a populist vest."

Petrobras declined to comment.

Bolsonaro did not respond to requests for comment. He said recently that Brazil's state companies must have a "social vision" and that any CEO who did not share that vision had to go.

DIESEL PRICE SPAT

Bolsonaro is just the latest Brazilian leader to intervene in Petrobras, whose virtual refining monopoly gives it control over domestic fuel prices.

Leftist President Dilma Rousseff, for example, subsidized fuel prices from 2011 to 2014 to control inflation, a move that cost Petrobras $40 billion. Her centrist successor, Michel Temer, let prices rise for a time, only to face a nationwide truckers' strike that paralyzed the economy.

Like Rousseff and Temer, Bolsonaro faced pressure this year as global oil prices rebounded to a one-year high, spurring Petrobras Chief Executive Roberto Castello Branco to raise prices six times from early November through January. Truckers responded by threatening another strike in late January, testing Bolsonaro's professed commitment to an independent Petrobras.

Castello Branco, a 76-year old University of Chicago-trained economist installed two years ago to restructure the company, said during a Jan. 28 webinar that the truckers' demands for lower diesel prices were "not Petrobras' problem," a comment that irked Bolsonaro, two sources told Reuters.

The issue came to a head on Friday, Feb. 5 when Castello Branco arrived in Brasília for an in-person meeting to discuss fuel prices with Bolsonaro and his cabinet.

At a post-meeting press conference, Bolsonaro said the government would lower pump prices by cutting fuel taxes, but would not intervene in the oil company.

"We will never control Petrobras' prices," he pledged, flanked by Castello Branco and cabinet ministers. "Petrobras and its own policies are part of the international market and we respect that."

His declaration was undermined that very afternoon when Reuters published a story revealing how Petrobras leadership had delayed the company's adjustment of its prices to international crude fluctuations, a move that allowed pump prices to remain artificially low.

The story triggered a 4% drop in Petrobras shares, reversing an initial 3.5% rally on Bolsonaro's "hands off" promise. Analyst downgrades followed.

Castello Branco - eager to show his independence, according to a person close to him - raised diesel by a further 6% on Feb. 8.

An even bigger diesel hike of 15.2% on Feb. 18 left Bolsonaro in a rage, according to two sources close to the situation. He viewed it as destabilizing to government efforts to calm truckers, the people said.

That evening, during a weekly broadcast on social media platforms, the president griped about the "excessive" price increase and leveled a threat: "Something will happen at Petrobras in the coming days," he said, without elaborating.

Castello Branco was fired the next day in the Facebook post that shocked the market. He'll be out for good on March 20, when his term ends.

Castello Branco declined to comment.

Replacing him will be retired general and former Defense Minister Joaquim Silva e Luna, the latest in a slew of active duty and former military men Bolsonaro has surrounded himself with since he took office.

Asked by Reuters about public speculation that he would give the government disproportionate influence in the company, Luna noted Petrobras has mixed private-public ownership, calling its governance "very well-balanced and controlled."

He declined further comment.

DOUBTS ON PRIVATIZATIONS

Bolsonaro said last month that the privatization of state companies, specifically the post office and state-run electricity company Centrais Eletricas Brasileiras, or Eletrobras, were among his legislative priorities this year.

His commitment to that effort remains to be seen.

In mid-January, he came close to firing Banco do Brasil Chief Executive Andre Brandao over his plan to close 361 branches as part of a cost-cutting program.

On Jan. 25, Eletrobras CEO Wilson Ferreira Junior, who had been appointed by Temer in 2017 with a directive to privatize the company, stepped down saying he lacked support to do so. In conference calls with analysts and journalists, he blamed Congress, not Bolsonaro.

The same day, Petrobras refinery chief Analise Lara retired. She was the face of an ambitious program to sell off eight refineries nationwide, or roughly 50% of Brazil's refining capacity. Analysts from BTG Pactual and other banks said that plan is now in doubt given the company's new leadership.

Days later, Petrobras Chief Compliance Officer Marcelo Zenkner also departed.

Worries about government interference at Petrobras played a role in their decisions, two people close to the former executives told Reuters.

Zenkner did not respond to a request for comment. Lara declined to comment and referred Reuters to the Petrobras press office, which reiterated its earlier statements that Lara had retired and that Zenkner had left for personal reasons.

Investors still looking for Bolsonaro to shake up Brazil's state companies are deluding themselves, said Mauro Cunha, a former Petrobras independent board member and ex-head of a minority shareholders' rights group.

"The arguments that 'this time it's different' are like a childish dream," Cunha said.

(Additional reporting by Tatiana Bautzer, Anthony Boadle, Rodrigo Viga Gaier, Jamie McGeever and Gabriel Araujo; writing by Christian Plumb and Brad Haynes; editing by Marla Dickerson)

By Sabrina Valle, Gram Slattery and Lisandra Paraguassu