
The last Zoroastrian to fight back Muslims in Iran, Mardavij was pretty close to conquering Baghdad, having borders near ~100km away of Baghdad, he was a genius commander but got assassinated by Turkish slaves which he treated harshly, which ultimately decided future of the Iran as a consequence.
Born to a Zoroastrian family native to Gilan, Mardavij was an anti-Muslim, who sought to revive the Sasanian Empire which was conquered in the 7th century by the Muslims. He first started his career by joining the army of his kinsman Asfar ibn Shiruya. Mardavij, however, later betrayed and killed him, conquering much of Jibal. He then set out to conquer Hamadan, Dinavar and Isfahan from the Abbasid Caliphate, and thereafter declared himself king of Iran, making Isfahan his capital.