Can't get my ex dom out of my head

I had an amazing year-long relationship with an online Daddy and I was sure we would evolve into a real life relationship, but he ended it expectedly in February, saying he wanted to keep in touch as friends, then ghosted me at the end of April. I'm past him, don't want him back, aware that he was shitty to me, etc. My problem is that when I'm a my most vulnerable I can't stop thinking of him as my source of comfort, or when I'm getting myself off, thinking of him as my source of arousal. It's like he pops into my head without any choice on my part. This usually throws me off, upsets me more, and ends in a panic attack. Any suggestions on getting my head past this or replacing those thoughts with something else? This dynamic just went so deep for me and I can't seem to get rid of those last attachments to him

(obligatory statement about how awful, manipulative, and predatory online doms can be, and how much more profound and vulnerable dynamics can be over vanilla relationships)