لَا طَاعَةَ لِمَخْلُوقٍ فِي مَعْصِيَةِ الْخَالِقِ
There is no obedience to a created being in disobedience to the Creator.
No human authority can override divine law. Declining a particular sinful order is not identical to rejecting every other lawful instruction that person issues. The religious status of an instruction and the personal conduct of the authority must be distinguished.