WARNING: Content may upset some readers
She stood defiant in the dock. Blood poured from her mouth and nose, while her body was covered with bruises - the result of another savage beating by her Islamic State captors, who used cables and weapons in addition to their fists and feet.
Once again Lamiya Haji Bashar had tried to escape her tormentors. And once again, the Yazidi teenager had been caught.
A judge in Mosul's sharia court stared at her. After being told Lamiya kept trying to escape - this time she had been caught leading a breakout of several other girls seized by the terror group - he made his ruling, the Daily Mail reports.
"He said that either they must kill me or cut off my foot to stop me escaping," Lamiya recalls.
So how did she respond to such a terrifying sentence?
"I told him that if you cut off one foot then I will escape with the other. I told the judge I would never give up. So they replied they would keep on torturing me if I tried to escape."
She showed immense bravery, yet it was typical of this remarkable teenager. Eventually her life - and her feet - were saved by a senior IS official, who argued that she should be sold to a new 'owner'.
Lamiya was one of the several thousand Yazidi women and girls condemned to sex slavery, traded like animals and abused by barbarous fanatics. Another year of fear, agony and assaults lay ahead of her, held captive by a cruel surgeon, who traded kidnapped women and children when not stitching up wounded jihadis.
But now Lamiya is free, though even her escape was etched in pain and tragedy. She was injured in an explosion that left extensive physical scars on her face to go with the deep psychological scars on her mind.
I met Lamiya in a quiet hotel in Germany, where this extraordinary, softly spoken young woman told me her story - a tale of savagery far beyond anyone's worst nightmare.
She heard her father and brothers being shot, was enslaved by their cruel killers, and then beaten and raped for almost two years by a succession of older men.
During her time trapped in the IS heartland of Syria and northern Iraq, Lamiya saw children sold to old men as sex slaves, and she was forced to help make suicide bombs.
At one point Lamiya was thrown into a room to be gang-raped by 40 fanatics. Yet she never buckled. "These men were more than monsters," she says. "That's why I stayed strong, because I wanted to challenge the life they gave me."
Now, showing remarkable courage, she has taken the unusual step for her gender, her religion and her region, in speaking openly about the horrors.
It is hard to believe that she is still only 18. Lamiya's stance was recognised last month with the EU's top human rights award - the Sakharov Prize. Nadia Murad, another Yazidi sex slave survivor, was also honoured.
Their stories remind the world that so many more Yazidi women and girls remain caught in similarly appalling circumstances by bigots who view them as infidels due to their ancient beliefs.
The 400,000-strong Yazidi community is persecuted by extreme Muslims for devil-worship since their religion, blending aspects of ancient Middle East traditions, reveres an angel which takes the form of a blue peacock. I first broke news about their plight in 2014.
Lamiya comes from the Yazidi village of Kocho in northern Iraq, where the 1,800 residents were told by IS to convert to Islam or die. Until then she had had a happy childhood, growing up on a prosperous farm owned by a wealthy family. She went to school, worked hard and hoped to become a teacher.
"When I first heard of Daesh [another term for IS] on television I thought it was some kind of new animal," she says, underlining her youth. "I didn't know they were a terror gang."
When IS swept into Mosul, Iraq's second city, 80 miles west of Kocho, elders realised their village might become caught up in the spiralling conflict, but they never thought peaceful civilians like them would be targeted.
However, in early August 2014, after capturing the nearby city of Sinjar, two cars filled with IS fighters arrived.
"They asked us to convert, but said they would do no harm," Lamiya says. The village was surrounded, yet a few families managed to flee.
Then, on August 15, a large force of black-clad men stormed the village - locals recognised some as those from nearby towns.
Everyone was ordered into the school, stripped of all their possessions, and females were taken to the first floor.
"I was so scared. I was thinking of my father, my family, my life," says Lamiya. "Then they took all our men - fathers, sons, brothers."
It was the last time she saw her father and two brothers. IS told the terrified women that the men were being sent to Mount Sinjar, where many Yazidi had sought refuge. "Ten minutes later we heard the shooting start," recalls Lamiya.
The men were slaughtered in their own streets. Then the women were split up: married women and younger children were taken to nearby Tal Afar, while unmarried women and teenagers were sent to Mosul. Older women were shot dead the next day.
Lamiya and three of her sisters soon got a taste of the fate that lay ahead. "The men began attacking us, touching us and kissing us."
In Mosul, the captives were forced into a big building filled with hundreds of similar-aged Yazidi. It turned out to be a market for militants to buy sex slaves. "Men came all the time to choose girls. If someone refused to go, they were beaten with cables," says Lamiya.
"It was so painful to see these old men, these monsters, attack the girls. Even girls of nine and ten were crying and begging not to be attacked. I can't describe how horrible it was."
A Saudi man in his 40s bought Lamiya and one of her sisters, taking them to the IS stronghold of Raqqa and keeping them handcuffed much of the time. "He was a very bad man," she says.
"He beat us for the three days we were with him.
"Once he tried to kill me with his hands around my neck because I rejected his advances."
To soften up the sisters, the man took the pair to an IS base and threw them into a room. "There were about 40 fighters who abused us. You can't imagine this - two small girls at the hands of so many monsters. Terrible things happened to us."
Afterwards the girls were sold to different fighters, fetching about £100 each. Lamiya ended up with an even more brutal man from Mosul.
Although kept in a locked room, she made the first of five escape attempts when alone in an apartment by jumping from a window. Spotting a local man, she begged him for help and he took her to hide in his home for three days.
"The family asked if a relative could come and pick me up, but they were all in captivity. The family was afraid of Daesh, so after three days the man called two fighters, saying he had found a girl."
Her 'owner' was quickly tracked down thanks to a computerised registration system used by IS to record sales of women. Before being handed back, Lamiya was tortured by six men before her furious master beat her viciously.
After her second escape attempt, the man sold her. When I tell Lamiya she was obviously trouble, she smiles shyly for the first time.
"Every time I tried to escape they tortured me, but it made me stronger. I never gave up.
"I saw so many atrocities, so many crimes. This gave me the power to keep fighting against them."
She was taken by a white-haired man from Mosul, who lived with his wife and son. "I told him you cannot take me into your family as a slave," says Lamiya. "Please don't do things with me there. Then he raped me.
"I once asked his wife and mother to help protect me from the sexual abuse but they said that was his right since I was an infidel."
This man held her for two months. Later Lamiya discovered he had another wife: a blonde, blue-eyed younger woman who spoke German. "She was very nice but I could not believe she accepted this man."
After another escape attempt, Lamiya was passed on to an IS emir. "Each man was worse than the one before," she admits. "Everyone said I was difficult, so they beat me from the start. They were always beating me, always abusing me."
The IS leader was an expert bomb-maker, with a big basement in Mosul filled with cars, liquid explosives and electrical equipment. Lamiya was made to work beside men making suicide vests - she was taught to connect the wiring as they churned out 50 devices each day.
As she worked, she heard air raids and missiles exploding nearby.
"I hoped they would attack us and we would die," Lamiya says. "I wanted to end my suffering. I also wanted them to destroy this terrible place because it was making bombs."
At one point, when some other Yazidi girls were bought down to the basement, Lamiya persuaded them all to make a dash for freedom. This led to another brutal beating and her being hauled before the sharia court.
She was later kept by a surgeon, who made her run errands in his hospital. Eventually he gave her a mobile phone so that he could summon her - but Lamiya used it to contact an uncle in Kurdistan.
At that point, she was being held close to the Kurdish front line, and her uncle paid a smuggler $7,500 (about £6,100) to get her out.
She walked through the night with Katherine, another teenager from Kocho, and a nine-year-old girl called Almas. But at 4am, Katherine inadvertently stepped on a mine, killing her and the nine-year-old, and leaving Lamiya with her terrible injuries.
Lamiya remembers little after the explosion, which happened nine months ago. Kurdish soldiers carried her to hospital, where doctors were forced to remove one of her eyes. They also treated her wounds before her uncle came for her.
Later she was taken to Germany by Luftbrucke Irak (Air Bridge Iraq), a charity that helps children and terror victims. The charity funded two more operations, restoring some sight to her left eye, and laser treatment to soften her facial scars.
Unsurprisingly, Lamiya remains traumatised and is plagued by nightmares. "I think about the suffering of all those other girls," she says.
They include her nine-year-old sister, Mayada, glimpsed only in a snatched photograph standing before a black IS flag. Five other sisters have managed to escaped the clutches of jihadis.
One day Lamiya wants to restart her studies and go to university. But for now, this courageous teenager speaks out to remind the world that 3,600 Yazidi women and girls are still enslaved by IS.
"These people wanted to eliminate my people and my religion but we will survive," says Lamiya. "My job is to tell those women and girls that they are not alone. And we will demand justice for those monsters who hurt us so much."