Changing gender to be made easier in Scotland
Scotland has approved a self-identification system for people who want to change their legal gender.
The new rules lower the age that people can apply for a gender recognition certificate (GRC) to 16, and removes the need for a medical diagnosis of gender dysphoria.
It's the only nation in the UK to simplify the process of transitioning.
But the Westminster government says it has concerns about the legislation and could yet prevent it from becoming law.
The Scottish Parliament backed the controversial proposals by 86 to 39 in a vote on Thursday afternoon.
There were shouts of "shame on you" from protesters in the public gallery as the result was announced.
But there were also louds cheers and a standing ovation in the chamber from supporters of the reforms.
The UK government says it has concerns about the legislation and could seek to prevent it becoming law by blocking Royal Assent - when the Bill gets formal agreement by the King and becomes an Act of the Scottish Parliament.
Women and equalities minister Kemi Badenoch said its impact on the Equality Act raised questions, and the Scottish government had not addressed the full implication of it in the bill.
She said in a statement on Twitter: "The UK government is now looking at provisions that can prompt reconsideration and allow MSPs to address these issues."
However, a Scottish government spokesman said "any attempt by the UK government to undermine the democratic will of the Scottish Parliament will be vigorously contested".
People in Scotland have been able to change their legal gender from male to female or female to male since 2005.
The Scottish government believes the existing process can be intrusive and distressing and put people off applying for a Gender Recognition Certificate.
The new rules, which are expected to come into force sometime next year, will mean applicants will now only need to have lived in their acquired gender for three months - or six months if they are aged 16 and 17 - rather than two years.
There will be also be a three-month "reflection period" during which they can change their minds and it will be a criminal offence to make a false declaration or false application for a GRC, with anyone who does so potentially facing up to two years in prison.
It will be possible to de-transition by going through the process again.
Campaigners say a move to make trans peoples' lives easier is long overdue, and will allow them to "live with the dignity and recognition that everyone deserves."
Scottish Trans manager Vic Valentine said the change in the law would mean that trans men and women would be able to show a birth certificate "that reflects who they are" at important moments in their lives such as starting a job or giving notice to be married.
But critics including author JK Rowling have raised concerns about the potential impact on women-only services, spaces and legal protections.
They have argued that there are insufficient safeguards to protect women and girls from predatory men who they say could seek to change their gender in order to gain access to facilities such as women's prisons.
Speaking ahead of the vote, Social Justice Secretary Shona Robison said: "Trans rights are not in competition with women's rights, and as so often before, we can improve things for everyone when those discriminated against act as allies, not opponents."
And First Minister Nicola Sturgeon said she would "never apologise for trying to spread equality, not reduce it, in our country."
The UK government has not ruled out mounting a legal challenge, with Scottish Secretary Alister Jack saying it "shares the concerns that many people have regarding certain aspects of this Bill, and in particular the safety issues for women and children".
The government is understood to be concerned about the potential impact of people with gender recognition certificates moving from Scotland to other parts of the UK, where a different system will still be in place, and on things like passports, pensions and some benefits.
Under UK law, it can apply to have Scottish laws struck down by arguing they would conflict with UK-wide equalities legislation. This power has never been used before.
Efforts by some MSPs to keep the minimum age at 18 were voted down, as was an attempt by Conservative MSP Russell Findlay to prevent convicted sex offenders being allowed to change their gender.
The reforms were backed by most SNP, Labour, Liberal Democrat and Green MSPs but opposed by the majority of Conservatives, who accused the government of attempting to avoid proper scrutiny of the legislation by rushing it through before Christmas.
Nine SNP MSPs voted against the government - the biggest rebellion since the party came to power in 2007.
Scottish Conservative equalities spokeswoman Rachael Hamilton said the party supported trans rights - but it should not come "at the expense of the safety of women and girls, and their hard-won rights".
She added: "For a majority of MSPs to vote against an amendment that would have prevented convicted sex offenders from applying for a Gender Recognition Certificate will astonish and outrage most Scots."
The Bill, which was previously shelved by the government, has been been one of the most controversial pieces of legislation in the history of the Scottish Parliament, with Community Safety Minister Ash Regan resigning in October after saying she could not support the proposals.
The moment the bill passed was an emotional one at Holyrood.
There were big cheers from trans-rights campaigners and cries of "shame" from women's rights campaigners in the public gallery.
Two thirds of MSPs backed the bill with opinion divided in the three largest parties.
The MSP who resigned as an SNP minister to protest against the law, Ash Regan told me she was "ashamed" of the Scottish Parliament, while one of only three Tories to support the bill, Jamie Greene said he was "proud" of what had been decided.
The epic debate and vote on the gender recognition reform is not the end of the story.
It is likely to face a legal challenge from somewhere and the UK government is reserving the right to block the legislation, if they decide it could negatively impact on UK law.
The minister who fronted the reforms, Shona Robison, told me the legislation was "robust" and that she intends to put it into effect as soon as possible.
Speaking after the vote, Ms Regan told BBC Scotland she was "ashamed" of what the parliament had done.
MSPs considered more than 150 proposed amendments to the proposals in two marathon sessions on Tuesday and Wednesday - with the latter not finishing until 01:15 on Thursday.
The Conservatives were accused of attempting to delay the legislation by proposing numerous points of order and forcing almost all amendments to votes that were sometimes not required.
Nine other European countries have already adopted self-declaration systems for legal gender recognition, including Ireland, Denmark, Norway, Portugal and Switzerland.
Also on Thursday, Spain passed a bill bringing it a step closer to allowing people to change their officially registered gender by filling in a form.