If I recall correctly the transplant doctor was sent back because she had gone to the Hezbollah leaders funeral, and the state department interpreted that as work for the organization.
It's very hard to avoid the accusation that you endorse terrorist beliefs if you attend the funeral of the head of Hezbollah. It's hard to say you didn't know the implications of that. As a visa holder, all you need is the accusation for CBP to deny you entry.
What terrorist beliefs in particular?
Believing that Palestinians shouldn't be slowly exterminated probably.
American zionists, particularly in the Trump government, seem to think that anything other than complete loyalty to Israel is terrorism.