The best advice I’ve gotten for handling unwanted thoughts and emotions is simple. It doesn’t involve pushing them away or drowning them in affirmations. That only makes them stronger.
I let myself feel them without judgement. They’re there, then they go away, and they’ll likely pop up again. It’s pointless to pile thoughts on top of them - those thoughts do the real damage.