The European Parliament has voted to pursue disciplinary action against Hungary under Article 7 of the European Union treaty.
The right-wing Hungarian government has been accused of attacks on the media, minorities and the rule of law - charges denied by Prime Minister Viktor Orban.
Article 7 is designed to protect the European Union's fundamental values.
It sets out ways various EU bodies can act if they believe those values are at risk, or have been seriously breached.
These values are founded on respect for:
- human dignity
- the rule of law
- respect for human rights, including the rights of persons belonging to minorities.
"These values are common to the member states in a society in which pluralism, non-discrimination, tolerance, justice, solidarity and equality between women and men prevail," according to the EU.
Invoking Article 7
The debate on Hungary is the first time the European Parliament has formally voted on an Article 7 resolution.
It follows a highly critical report on the country issued by a European Parliament committee this year.
It highlighted concerns about freedom of expression, academic freedom, judicial independence, the electoral system and the treatment of minorities as well as asylum seekers and refugees.
It described the country as being "at clear risk of a serious breach of EU values" and called for a full parliamentary vote on the matter.
The only other occasion the EU has formally resorted to Article 7 is over Poland, where there's been an ongoing dispute with its authorities over judicial reforms - but there has been no parliamentary vote on the issue.
The EU had voiced concern about the independence of the courts following Polish government moves to change or remove judges.
It was the executive, the EU Commission, which decided to act in that case, invoking Article 7 in December 2017 after concluding that there was "a clear risk of a serious breach of the rule of law in Poland".
The arguments with Poland are continuing.
It's important to make clear that Article 7 is a process rather than an end in itself.
And the process is divided into separate parts, with one not necessarily dependent on the other.
Under the preventative mechanism, the commission, the European Council or the Parliament can start the Article 7 process to determine whether there is a "clear risk of a serious breach of EU values".
The parliament has to agree by two-thirds of those MEPs who take part in the vote, which must also be an absolute majority of all MEPs, to start the process.
It then goes to the EU Council - the heads of government of the member states.
The council must agree by a four-fifths majority that there is a risk of breaching EU values (and then recommend specific actions to be taken by the country concerned).
European Parliament sources say there is no particular timeframe for this process - and that, in theory, the council could do nothing and simply ignore the vote by the parliament.
Under the sanctions mechanism enshrined in Article 7, only the council or the commission can trigger the process.
The council then has to decide unanimously that "a serious and persistent breach of EU values has taken place".
It has to also get the agreement of two-thirds of the parliament to this.
Once that has been done, the council has the power to suspend some of the country's membership rights - such as voting rights in the council itself.
However, it is not clear what other rights can be suspended.
And the council can only take this ultimate step by a qualified majority amounting to 72% of member states.
At the moment, this is not the course of action being proposed in the case of Hungary, although in theory that route remains open to the EU at a later stage.