(Reuters) - A Hungarian judge on Wednesday granted house arrest in Budapest to an Italian anti-fascist activist held in Hungary for allegedly assaulting far-right militants, the Italian Foreign and Justice ministers and her lawyer said.

Ilaria Salis, a 39-year-old teacher, has been in a Hungarian jail for more than a year in a case that prompted the Italian Green and Left Alliance to nominate her among their candidates at the European ballot.

Members of the European Parliament enjoy strong legal immunity from prosecution, even if the allegations relate to offences committed before their election.

"Good, that's what we wanted, house arrest. Let's hope she can be acquitted and return to Italy as soon as possible," Foreign Minister Antonio Tajani said, while Justice Minister Carlo Nordio welcomed the news in Parliament.

"Finally a nightmare ends for her. A detention in inhuman conditions that lasted over 15 months," Salis' lawyer, Eugenio Losco, told Reuters, adding that "obviously her battle is not over, it is an unfair trial, there is disproportionality of the punishment to what actually happened".

Losco said that Salis' father has to pay bail of 41,000 euros ($44,456), adding that she will spend her arrest at the home of a woman who has made her house available.

The case drew outrage in Italy in February when she was led into a court hearing with her feet and hands bound and a chain around her waist.

The issue is politically sensitive due to the longstanding ties between Italy's right-wing prime minister, Giorgia Meloni, and her Hungarian counterpart, Viktor Orban.

Italy's rightist government was put in an unusual position because although its leaders are close to the Hungarian cabinet and they may feel little sympathy for Salis' alleged actions, they have made comments supportive of the activist after the public outrage over her treatment.

The family of Salis and opposition parties have accused the government of paying too little attention to the case.

Meloni has subsequently raised Salis' case with Orban, calling for the activist to be granted a quick trial.

Hungarian prosecutors are seeking an 11-year jail term for Salis for her alleged role in an assault on two far-right militants by a group of anti-fascist activists in Budapest in February 2023. She pleaded not guilty in January.

($1 = 0.9223 euro)

(Reporting by Emilio Parodi in Milan and Angelo Amante in Rome; Editing by Matthew Lewis)