I had the exact same problem before. I absolutely could not get it running again. The problem started on a very hot day in 1997 when the air conditioning was broken. So I figured something melted and it was hopeless.
So my poor A4000/040 sat in a box for several years. Finally, in 2004 I gave it away FOR FREE to an experienced Amiga guy. He got it running on the very first day! He didn't even swap out any parts! WTH!? He said he just took everything apart, cleaned it thoroughly and put it all back together and it worked.
Then he sold it on Ebay for a zillion $.