How did Iran catch the mightier US and Israel on the back foot?

How did Iran catch the mightier US and Israel on the back foot