The group that calls itself Islamic State (IS or Isis) has a special punishment for gay people - it kills them by throwing them off high buildings. Taim, a 24-year-old medical student, tells the story of how he only escaped this fate by fleeing from Iraq to Lebanon.
In our society, being gay means death. When Isis kills gays, most people are happy because they think we're sick.
I first realised I was gay when I was about 13 or 14. I too thought homosexuality was a sickness and I just wanted to feel normal. During my first year of college, I started having therapy for it. My therapist told me to tell friends that I was going through a "difficult phase" and to ask for their support.
I'm of Muslim background but my ex-boyfriend was from a Christian background and I had a bunch of Christian friends, whom I used to hang out with. In 2013 I got into a fight with a fellow student, Omar - who later joined Isis - about hanging out with Christians. A friend of mine told him to go easy on me because I was going through a hard time, having treatment for being gay. That's how people knew. I think my friend's intention was noble but what happened as a result ruined my life.
In November 2013, Omar attacked me with two of his friends. I was just walking home after a really lovely day. They beat me, threw me to the ground and shaved my head, saying to me: "This is just a lesson to you for the moment, because your father is a religious man. Watch what you do!" He meant that I wouldn't be killed then and there out of respect for my dad, because I'm from a religious family.
I left town for a few days and didn't go to university but then I went back, and in March 2014 I made Omar angry again, this time by suggesting that non-Muslims shouldn't have to pay the "jizya", the tax paid by non-Muslims to a Muslim government. I was washing my hands in the university bathroom when he and others attacked me again. They came at me from behind, but I recognised one of them from his green watch. It was the same group. They kicked me half-unconscious. I was barely able to walk and stopped going to university for a month.
Then, in the middle of final exams, Isis took over. Omar called me and asked me to repent and join them. I hung up the phone.
On 4 July, a group of fighters from Isis came to my home. My father answered the door and apparently they said to him: "Your son is an infidel and a homosexual and we have come to carry out God's punishment on him."
My dad is a religious man and luckily for me he was able to tell them to come back the next day, to give him time to find out whether the accusation was correct. He came inside the house and started screaming. Finally, he said: "If these accusations are true, I will hand you over to them myself, happily." And I just stood there, not knowing what to do and what to say, or how to defend myself.
I was in shock. But my mother decided that I should leave the house immediately, and she started working on getting me out of Iraq for good. It was midnight and she said to me: "We're leaving right now." She took me to her sister's house. The next day she booked me a plane ticket to Turkey and got me a visa. But I had to travel via Erbil and they wouldn't let us into Kurdistan. I stayed in a village near Erbil for two weeks, trying to get in but I never managed it. I tried to leave via Baghdad but there were clashes on the road and the driver wouldn't go on. I tried to get out so many times, and failed.
Eventually, in August, after weeks in hiding, my mum arranged somehow for me to get to Kirkuk, driving there through fields and on unpaved roads. From there, I went to Sulaymaniyah. I'd planned to go to Turkey but the first available flight was to Beirut and I didn't need a visa - so here I am.
If I'd stayed, Isis would have come for me and killed me the way they've killed others. If Isis didn't get me, members of my family would have done it. A few days after I left, I learned that my uncle - my father's brother - had taken an oath to cleanse the family honour.
Recently, I received an anonymous Facebook message - but my mother thinks it was from my uncle. It said: "I know you're in Beirut. Even if you went to hell, I would follow you there."
All I want now is to be in a safe place, unreachable by my dad or anyone with extremist thoughts. I want to be safe, to be free, and to be myself - to get my degree and start living… I just want to start living.
Human rights lawyers from the Iraqi Refugee Assistance Project have helped me get refugee status and are working on getting me resettled in another country, where I want to continue my studies. Here I'm living in one room, the size of my bathroom back home. I'm in limbo.
I think I will recover eventually but there will always be a memory of this dark period when I literally had to run for my life to avoid being killed. It was very stressful, but luckily I made it.
I've lost contact with most of my family. A month after I fled, my younger brother sent me a Facebook message saying: "I have had to leave town. The family is shattered and it's all because of you."
I was angry and didn't reply. But then on New Year's Eve I missed him, so I wrote to him, saying: "It's not my fault that I was born this way. They (Isis) are the criminals." And after that we had a long conversation on Facebook about our childhoods.
I've not spoken to my father. What he did was very hurtful. He's my father. He's supposed to protect me and defend me, no matter what. But when he said that he'd hand me over to Isis, he knew what they were going to do to me. He knew. Maybe in the future I can forgive him, but right now I don't even want to think about him. I want him out of my life.
I talk to my mum every week, though. It's hard for her because there's no network coverage and she has to go out of town to get a signal. She's the most amazing woman in the whole world. She's cultured, respectful - very bright. She loves me and when she was trying to smuggle me out, we never discussed my homosexuality. She was just focused on getting me to safety. Because she is my mother, I think she always knew that I was gay. But all I felt from her was her love, her ultimate love. I never said goodbye to her because when I actually managed to escape, there had been so many failed attempts that I was sure I would be back and see her again.
All I need is a hug from her.
I still have gay friends at home but we're not in contact any more, for their own safety.
Earlier this year one of my best friends, who stayed behind, was killed.
He was thrown off the main government building.
He was a great man - a very kind person. He was 22 years old, a medical student, and he was really calm and really smart - a bit of a genius. He used to talk to me about the latest scientific discoveries.
He always got straight As. You never saw him without a book.
We met first online - gay Iraqis hang out a lot in online communities - and then face to face. In person, he was quite quiet - but online he never stopped talking. Sometimes he would chat until the power went off and we lost the internet. He shared his deepest secrets with me. As gay men, we all had to lead secret lives. But he was the kind of person you love to talk to.
I don't know how he was outed because he was very careful - but maybe through a text or online message. When Isis capture people, they go through all their contacts.
The last time I saw him in the flesh was a few days after Isis took over our town, but we continued talking online until I fled.
When I first saw the pictures of him, I can't describe what I felt. The video images follow me in my nightmares. I see myself falling through the air. I dream that I'm arrested and then thrown from a building - facing the same fate as my friend.
It was devastating to see him go in that brutal way. He was blindfolded but I knew it was him from his skin tone and from his build. It looked like he died immediately but a friend told me he didn't - perhaps the building wasn't high enough. The friend said he'd been stoned to death.
I wanted to break down. I couldn't believe it. One day he was alive, active, just living his life.
And now he is gone.
Even before Isis arrived, I was living in constant fear. There are no laws to protect you. Militiamen were killing people in secret, and no-one would say anything. To them, we're just a bunch of dirty criminals they need to get rid of because we bring God's anger and are - as they see it - the source of all evil.
For the past few years it's been really, really hard. There were militiamen or security men who - if they found out someone was gay - would arrest him, rape him, torture him. There were lots of murders supervised by the Iraqi army. Videos came out of people being burned alive or stoned and you can see soldiers there. I have seen a video where some gay men had ropes put around their necks and they were dragged around the streets and people were throwing stones at them and when they were half-dead they were set on fire. Some people had their rectums glued up and were then left to die in the desert.
Before Isis, I think that maybe the power of my family protected me. But let's assume that Isis disappeared this second, the threat to my life would be just as serious, now that I've been identified as gay.
The difference now is that Isis has only one horrible method of killing people - throwing them off buildings and, if they don't die, stoning them. I know that if Isis had captured me, that would have been my fate.
What's also changed is that the media are focusing on what Isis is doing, because it's Isis. And Isis films everything and releases the video and says: "We killed these people for being gay and this is their punishment according to our Holy Book."
Isis are also professional when it comes to tracking gay people. They hunt them down one by one. When they capture people, they go through his phone and his contacts and Facebook friends. They are trying to track down every gay man. And it's like dominoes. If one goes, the others will be taken down too.
It's devastating to see the public reaction to the killings. Usually, when Isis posts pictures online, people sympathise with the victims - but not if they're gay. You should see the Facebook comments after they post video of the killings. It's devastating. "We hate Isis but when they do things like this, we love them. God bless you Isis." "I am against Isis but I am totally with Isis when they kill gays." "Amazing news. This is the least that gays deserve." "The most horrible crime on earth is homosexuality. Good job Isis." "The scene is ugly but they deserve it." "Those dirty people deserve Isis."
And there are thousands of people agreeing with these comments full of hate. That is what is so disturbing. This is the society I fled from.
Islam is against homosexuality. My father made me study Sharia law for six years because he wanted me to be a religious man like him. There is a hadith [an ethical guideline thought to be a saying of the prophet] that instructs gay men to be thrown off a cliff and then it's up to a judge or the Caliph to decide if they should be burned or stoned to death.
Imam and Islamic scholar Dr Usama Hasan from the Quilliam Foundation says there are many hadiths and traditions ascribed to the Prophet Muhammad and his disciples on the subject of punishment for homosexuals. "However, all are disputed and there has never been any consensus on them, especially since they seem to contradict the Koran, 4:15-16." He adds that some scholars have argued that Muhammad could not have given any such ruling since no confirmed case of homosexuality was ever brought to him.
I think Isis is throwing gay men from buildings because our society hates us and it's a way of gaining support.
I try not to look at Isis's videos. But to be honest I do look for their martyrdom videos. I want to see if I can see Omar, the man who ruined my life.
I worry a lot about the gay men still left there. I have dozens of friends who can't leave because they can't afford to. But, after our friend's death, I said goodbye to them online and blocked them, for their own safety.
I'm speaking out to honour my friend who was killed - and for the gay men I know who are still in Iraq. I want Iraqis to know that we're human beings, we're not criminals. We have feelings and we have souls. Stop hating us just because we're born different.
I was lucky to get out. I saved my soul. But what about them? Will they be lucky enough to survive? And, if they survive, will they recover from the trauma of being hunted? It's a disaster. They're all targets.
Taim told his story to the BBC's Caroline Hawley. Taim is not his real name, nor is Omar the real name of his persecutor.
Subscribe to the BBC News Magazine's email newsletter to get articles sent to your inbox.