BANGKOK (AP) — A court in military-ruled Myanmar convicted former leader Aung San Suu Kyi of corruption and sentenced her to five years in prison Wednesday in the first of several corruption cases against her.

Suu Kyi, 76, who was ousted by an army takeover last year, has denied the allegation that she accepted gold and hundreds of thousands of dollars in a bribe from a top political colleague.

Her supporters and independent legal experts consider Suu Kyi’s prosecution an unjust attempt to discredit her and legitimize the military’s seizure of power while preventing her from returning to an active role in politics.

The daughter of Aung San, Myanmar’s founding father, Suu Kyi became a public figure in 1988 during a failed uprising against a previous military government when she helped found the National League for Democracy party. She spent 15 of the next 21 years under house arrest for leading a nonviolent struggle for democracy that earned her the 1991 Nobel Peace Prize. When the army allowed an election in 2015, her party won a landslide victory and she became the de facto head of state. Her party won a greater majority in the 2020 polls.

Suu Kyi is widely revered at home for her role in the country’s pro-democracy movement — and was long viewed abroad as an icon of that struggle, epitomized by her years under house arrest.

But she also has been heavily criticized for showing deference to the military while ignoring and, at times, even defending rights violations — most notably a 2017 crackdown on Rohingya Muslims that rights groups have labeled genocide. While she has disputed allegations that army personnel killed Rohingya civilians, torched houses and raped women and she remains immensely popular at home, that stance has tarnished her reputation abroad.

She has already been sentenced to six years’ imprisonment in other cases and faces 10 more corruption charges. The maximum punishment under the Anti-Corruption Act is 15 years in prison and a fine for each charge. Convictions in the other cases could bring sentences of more than 100 years in prison in total.

U.N. Secretary-General Antonio Guterres reiterated his appeal Tuesday for Myanmar’s military to release all political prisoners including Suu Kyi and his condemnation of the military takeover of the country on Feb. 1, 2021, U.N. deputy spokesman Farhan Haq said.

The U.N. chief also repeated his call for an immediate end to violence and repression in Myanmar and for respect for the Universal Declaration of Human Rights, “which enshrines the principles of equality before the law, the presumption of innocence, the right to a fair and public hearing by an independent and impartial tribunal, and all the guarantees necessary for a person’s defense,” Haq said.

“These are trumped-up charges, politically motivated, to keep her inside prison for such a long time and also are designed to keep her away from the political limelight,” said Wai Hnin Pwint Thon, a Geneva-based activist with the pro-democracy group Burma Campaign UK. “And I’m sure the military is also thinking, by sentencing her, they are grabbing the hope away from people but, in reality, it’s doing completely the opposite because people haven’t lost hope. They are still standing up against the military.”

Suu Kyi’s trial in the capital, Naypyitaw, was closed to the media, diplomats and spectators, and her lawyers were barred from speaking to the media. The evening newscast on state television confirmed the sentence.

Following the victory of Suu Kyi’s party in the 2020 general election, lawmakers were not allowed to take their seats when the army seized power on Feb. 1, 2021, arresting Suu Kyi and many senior colleagues in her party and government. The army said it acted because there had been massive electoral fraud, but independent election observers didn’t find any major irregularities.

The takeover was met with large nonviolent protests nationwide which security forces quashed with lethal force, killing almost 1,800 civilians, according to a watchdog group, the Assistance Association for Political Prisoners.

As repression escalated, armed resistance against the military government grew, and some U.N. experts now characterize the country as being in a state of civil war.

Suu Kyi has not been seen or allowed to speak in public since she was detained and is being held in an undisclosed location. However, at last week’s final hearing in the case, she appeared to be in good health and asked her supporters to “stay united,” said a legal official familiar with the proceedings who asked not to be identified because he was not authorized to release information.

In earlier cases, Suu Kyi was sentenced to six years’ imprisonment on charges of illegally importing and possessing walkie-talkies, violating coronavirus restrictions and sedition.

In the case decided Wednesday, she was accused of receiving $600,000 and seven gold bars in 2017-18 from Phyo Min Thein, the former chief minister of Yangon, the country’s biggest city, and a senior member of her political party. Her lawyers, before they were served with gag orders late last year, said she rejected all his testimony against her as “absurd.”

The nine other cases currently being tried under the Anti-Corruption Act include several related to the purchase and rental of a helicopter by one of her former Cabinet ministers.

Suu Kyi is also charged with diverting money meant as charitable donations to build a residence, and with misusing her position to obtain rental properties at lower-than-market prices for a foundation named after her mother. The state Anti-Corruption Commission has declared that several of her alleged actions deprived the state of revenue it would otherwise have earned.

Another corruption charge alleging that she accepted a bribe has not yet gone to trial.

Suu Kyi is also being tried on a charge of violating the Official Secrets Act, which carries a maximum sentence of 14 years, and on a charge alleging election fraud, which carries a maximum sentence of three years.

“The days of Aung San Suu Kyi as a free woman are effectively over. Myanmar’s junta and the country’s kangaroo courts are walking in lockstep to put Aung San Suu Kyi away for what could ultimately be the equivalent of a life sentence, given her advanced age,” said Phil Robertson, deputy Asia director of Human Rights Watch. “Destroying popular democracy in Myanmar also means getting rid of Aung San Suu Kyi, and the junta is leaving nothing to chance.”