TEHRAN, Iran — Iran international goalkeeper Sosha Makani has been suspended for six months for “inappropriate” conduct, including the wearing of what media have dubbed “SpongeBob pants,” ISNA news agency reported on Wednesday.

The Iranian soccer federation’s morality committee cited Makani’s clothing as one of the reasons for handing out the punishment.

“Among the matters reviewed was Sosha Makani’s unconventional and inappropriate clothing,” it said about the 29-year-old, who played for Persepolis in the Iranian first division last season.

Get The Times of Israel's Daily Edition by email and never miss our top stories Free Sign Up

The ruling is not final and can be appealed, ISNA said.

Iran is a deeply conservative Islamic republic with strict clothing laws, including the obligatory wearing of a headscarf for women.

Makani’s clothing has grabbed the attention of local media, who likened his outfits to that of the American animation character SpongeBob.

In a photo that was posted to social media, Makani was seen in a colorful outfit, wearing yellow pants with black dots, a blue t-shirt, black belt, and blue-patterned converse shoes.

Morality committee of Iran football fed. bans Persian Gulf Pro League goalkeeper for 6 months over SpongeBob pantspic.twitter.com/rGzydeHXfs — Sobhan Hassanvand (@Hassanvand) June 8, 2016

The penalty could also be related to a previous controversy in January when Makani was arrested and taken briefly to Tehran’s infamous Evin prison after pictures of him in the presence of a woman were leaked online.

In the photos he was seen dancing with her and hugging her. In another group photo, the same woman was seen in a dress with a low neckline while Makani and another man were wearing shorts with their bowtie and suit.

Media reported he claimed to be engaged with the woman and was later released on bail.

Iran also has strict laws against the mixing of unrelated men and women.

In recent months, Iran has arrested, and sometimes lashed, hundreds of men and women for mixed partying and drinking alcohol — both against Islamic Sharia, in force in the country since 1979.

Soccer player Mehrdad Oladi died in April at the age of 30 due to a heart attack, which the Judiciary spokesman Gholam Hossein Mohseni-Ejeie later said was caused by use of drugs and alcohol.

Following the 2015/16 season, Persepolis didn’t renew Makani’s contract.