Ivory Coast's authorities have refused to explain why two gay men were sentenced to 18 months in prison in November 2016, as the country does not criminalise same-sex acts.

Considered a safe haven for LGBT people fleeing persecution elsewhere in a region where sexual minorities are criminalised in Cameroon, Gambia, Ghana, Guinea, Liberia, Sierra Leone and Togo, this is the first time gay men were prosecuted for acts related to their sexuality in Ivory Coast. No law prohibits discrimination on the grounds of sexual orientation, gender identity, or intersex status in Ivory Coast.

Yann, 31, and Abdoul, 19, who are openly gay, were arrested in October last year after Abdoul's uncle, who walked in on the pair having sex, filed a complaint for "public indecency" with the gendarmerie in the south-western seaside town of Sassandra.

During their appearance in court, the young men admitted the facts, stating that they had been lovers for a long time and that they did not see how their conduct constituted an offence.

The prosecutor, however, accused the pair of an "unnatural and indecent act", arguing that sexual intercourse between people of the same sex should be "sanctioned".

While there are no laws that criminalise same-sex conduct, gay couples can be prosecuted for public acts of indecency. Speaking from Sassandra prison, Yann said the pair were "convicted in an unjust manner". "If there is no law that that condemns it, I don't understand how we could have been convicted."

Activists, who say the indecency law is too vague, fear authorities could use the provision to jail gay people in the country.

"A vague law, arbitrary arrests and an unexplained conviction: this is completely contrary to the rule of law," Graeme Reid, director of the LGBT rights programme at HRW, said. "The government needs to come clean and offer an explanation to these two young men who have spent three months in jail for no apparent reason."

In the wake of the passing of same-sex marriage law in France in 2015, Ivory Coast was gripped by a passionate debate about homosexuality.