Rights groups condemn detention of Islamists