Sorry I haven't read all the responses, but the first thing that pops out at me is that you mentioned you changed his feed. It sounds like he's always had pain, so I don't think he'd be reacting in anticipation to pain, as he didn't react when there actually was pain. My thoughts are two good things combined for him - higher energy food and feeling good enough to use that energy.
What are you feeding him now? Could ulcers be a possibilty? Maybe a magnesium supplement would be useful.
Also, is he new to trails? If so keep it slow at first, perhaps try ponying him the first couple times if he ponies well. Or have someone ride with you for a few times, he'll be less likely to want to gallop off if his friend is just walking. Is there any clearing you can work him in? Not a trail but just an unfenced outdoor area? Ride him as if you were in the ring, but not. This will help be a middle ground between riding out and in.
You'll probably have to bring him back to the beginning of being supple, if he's completely resistng you so thoroughly he'll rear or fight you - regardless of if he's anticipating pain or not, he needs to be taught that you aren't going to hurt him and he still has to listen. So I'd start from the ground, practice having him give to the bit left and right and backing up off it. Apply a tiny amount of pressure to the rein you're using, wait, let him figet with it until he turns toward the pressure. Repeat this process in every direction until he's touching his nose to his girth area or backing up with just a tiny amount of pressure. Then practice these skills mounted but stationary, then mounted and walking and so on. Once he's readily giving to the bit without real pressure or fear or too much pressure, he'll be ready to try collecting. At this point he may anticipate pain, so it will take time AND you need to be SURE he's not in any pain at all before you ask him. If he is, the more you ask him the more you're proving to him that collection hurts.
So- check feed, make sure it's not too high energy, practice flexing, and make trails relaxing not exciting :)
ETA: I'd also suggest looking into line-driving rather than lunging. It's not as fast paced or as strenuous on the horse's joints, but works their mind plenty and shows off any little naughtiness they may have once you're mounted. If you get good at it with him you could even try ground driving him out on the trails, this whole change may help him look at trails differently and not anticipate the speed, it may also give you greater ability to stop him, as you can just turn him around and lead him in hand back and forth. Obviously don't try this unless you're very confident ground driving and feel you can control him if he gets feisty. Just a lunging alternative to look into.