OP, have a motherly hug.
Breathe. Eat, drink. When you can, sleep. Otherwise watch trashy action films. I took to weaving on card, like in primary school, because I couldn't keep still physically or mentally.
Thank goodness you have your home, no children with him and aren't married. Your effort can go into dealing with the emotional pain. Commit the feeling now to memory, and never have him back.
It takes a while to get over. Get some talking therapy if you can.
Remember, he's a total cunt. He's one of the great band of men who are cunts and want cunts.
About other things you've mentioned:
Nothing is ever wasted. The time you spent being your best self for him was you putting good things in the universe that can never be taken away. He didn't appreciate what he had, and now it's time for all those good feelings and efforts to pour their goodness on you and help you heal.
He's always in your head even when apart. Say 'No!' firmly to your brain every time it pushes him forward, and think of something else. It's like training a puppy. Your brain will learn if you are firm and consistent.
Good luck.