....can a thought be moral or immoral....
In principle, yes. Thinking is an action, arguably a deed.
If someone hates you, and wants to torture and kill you, and you know it, that causes you harm (distress) even if they never attack you.
I think I will go back to the example I made i PD, as it is equally valid in this side of the forum:
Thoughts can be immoral.
Thoughts cannot be unethical.
One may ask how this is not some kind of bizarre contradiction. It is quite simple insofar as morality can be seen as separate from ethics, as the way you drive your own experience, and exert agency.
But this is different from ethics insofar as ethics is created by social interaction, with respect to what obligations we have for each other if we would so have others bound to us.
For a concrete example, let us suppose one day I am accosted by someone on the train who starts screaming bad poetry. This man is black, and from the depths of my mind, I have an invasive thought "what a ------..."
This is a thought. It is most certainly not the sort of thought a person should want to have. It is so much a thought that I personally do not want to have that I spend the next ten minutes lecturing myself on why such thoughts are inappropriate.
The fact of the matter is, when a thought of such repugnance is had, a response is warranted.
But, nobody can punish this racist thought. It wasn't said out loud, was not even expressed in any intentional way. It was not unethical. It did not impose on anyone but me, and it came from me!
I would rather think that the tendencies of someone who pays no mind to the appropriateness of their thought would not be a good neighbor. I believe some guy named Camus wrote about someone who paid no reflection on his actions, and another named Voltaire had some things to say about such a failure to reflect as well.
... I would note that in the example, the obnoxious person was, still, a terrible neighbor.