Well, you’re leaving out some important context re Iran, namely that there was that Cold War thing going on and we didn’t want Iran falling into the USSR’s orbit.
Helping to overthrow Iran, certainly made them like the USSR even more. Kinda weird.