Antiochus III ("the Great") conducted several vigorous campaigns to retake all the lost provinces of the empire since the death of Seleucus I. After being defeated by Ptolemy IV's forces at Raphia (217 BC), Antiochus III led a long campaign to the east to subdue the far eastern breakaway provinces (212–205 BC) including Bactria, Parthia, Ariana, Sogdiana, Gedrosia and Drangiana. He was successful, bringing back most of these provinces into at least nominal vassalage and receiving tribute from their rulers. After the death of Ptolemy IV (204 BC), Antiochus took advantage of the weakness of Egypt to conquer Coele-Syria in the fifth Syrian war (202–195 BC). He then began expanding his influence into Pergamene territory in Asia and crossed into Europe, fortifying Lysimachia on the Hellespont, but his expansion into Anatolia and Greece was abruptly halted after a decisive defeat at the Battle of Magnesia (190 BC). In the Treaty of Apamea which ended the war, Antiochus lost all of his territories in Anatolia west of the Taurus and was forced to pay a large indemnity of 15,000 talents.