After debating through the night, Brazil's Senate voted early Thursday 55 to 22 to try President Dilma Rousseff on charges of manipulating the budget. The vote automatically suspends her from office.

The Senate had been widely expected to vote for Rousseff to be tried in impeachment proceedings. The final tally is a resounding defeat for Rousseff, easily surpassing the simple majority (41 votes) required.

In fact, two-thirds of the body voted for Rousseff to be tried. During trial proceedings, another two-thirds vote by the Senate would convict Rousseff and permanently remove her from the country's presidency.

The Senate's debate Wednesday night was a marathon — lasting more than 20 hours.

"Bleary-eyed legislators gathered in the early hours of the morning to cast their electronic vote," NPR's Lulu Garcia-Navarro reports.

"The tone of the Senate debate was markedly different from that of the lower house last month, where congressmen cheered and cried after casting their ballot. In the Senate there was only a smattering of applause after the results were announced. In the speeches throughout the night, many senators spoke about the economy and the legitimacy of the charges against Rousseff."

But, Lulu points out, many of Rousseff's critics and opponents are themselves caught up in scandal or suspicion.

"Almost 60 percent of the Senate is under some form of criminal investigation," she notes. "There were surreal moments when former President, now Sen., Fernando Collor took to the podium to discuss his own impeachment process in 1992. Some of the senators speaking out most vociferously against Rousseff are themselves under indictment — like Ivo Cassol from Rondonia, who has been found guilty by the Supreme Court but is still in office while he appeals his jail sentence on technicalities."

The charges against Rousseff aren't eye-popping or jaw-dropping; she's accused on fairly technical grounds of concealing the extent of the country's budgetary shortfall.

But there's more at play than the stated charges, Lulu says: Rousseff is deeply unpopular, with only 10 percent approval ratings, and Brazil's economy is suffering.

Rousseff's supporters, meanwhile, call the impeachment proceedings a "coup."

Speaking after the Senate vote, Rousseff herself called the impeachment process "fraudulent" — and said it was even more painful than the torture she experienced at the hands of Brazil's military dictatorship.

"I may have committed errors but I never committed crimes," Rousseff said, according to The Associated Press. "It's the most brutal of things that can happen to a human being — to be condemned for a crime you didn't commit. There is no more devastating injustice."

Vice President Michel Temer will serve as acting president as Rousseff is tried and will continue if Rousseff is permanently removed from office. The center-right politician's assumption of the office ends 13 years of the left's hold on the presidency.

As we reported Wednesday, Temer is among the politicians accused of profiting from a massive corruption scandal involving the state oil company Petrobras. The scandal has also touched Rousseff, at least indirectly, but was not officially included in her impeachment charges.

The Senate now has 180 days to try Rousseff. If she is convicted, she would be formally impeached (in Brazil, the term is used for a conviction, not simply a suspension from office).

Lulu reports some opposition lawmakers are calling for Rousseff to resign, to avoid a lengthy trial — but Rousseff has vowed to fight it out.

On All Things Considered on Wednesday, Lulu said she has been hearing there are plans to move the trial forward so it doesn't cast a shadow over the Rio Olympics this August. Still, some are concerned the nation's political upheaval will impact the games.

Copyright 2016 NPR. To see more, visit http://www.npr.org/.