Nicola Sturgeon encouraged a gathering of young people to keep “our fingers crossed” against Donald Trump becoming the next US president.
The First Minister also appeared to back the Democrat candidate Hilary Clinton during her intervention in the race for the White House.
She was speaking as part of a question and answer session with 450 teenagers at a Young Scot event.
Ms Sturgeon admitted she was defying a convention that leaders do not comment on elections in other countries.
But she added: “I really hope that Donald Trump does not become President of America. It’s not up to me, it’s not up to us, it’s up to the people of America.
“All I say is as the first woman First Minster it would be nice at some point to have the first woman president of America as well, but that’s a personal opinion.”
Ms Sturgeon, who was asked if Mr Trump should be allowed to enter the UK if he becomes president, said she finds his views “really abhorrent”, particularly those made about the Muslim community.
“I actually believe that the good sense of the American people – a great country, great people – will prevail here and we won’t have the particular issue to confront that you spoke about.
So let’s keep our fingers crossed,” she said.
Ms Sturgeon admitted the Scottish Government was not doing enough for transgender young people as she fielded questions from young people who spoke of the discrimination they faced over their gender status.
One young person, who was been waiting more than a year to access a gender identity clinic in Glasgow, told the First Minister: “If an individual had a tumour growing in their body there would be no hesitation to remove it, but my body’s a tumour to my brain and it causes me agony each day.”
Ms Sturgeon said: “We do not do enough to help transgender young people be themselves and I will freely admit that.
“The commitment that I am going to make to you today is that we need to and we will do much more.”
In a wide-ranging Q&A, topics also raised by the young people aged 16-19 included the educational attainment gap, support for children with additional needs in schools, mental health services for young people and gender equality.