Greetings;
If you are $500 upside down in the vehicle, you really don't have much of an option but to repair the car. With the amount of the repair estimate you have, it obviously needs a lot of work so it likley does not ahve a lot of resale or trade in value in it's present condition. Even if it did, you would still have to cough up $5000 to break even.
This is an unfortunate situation to be in, but the only way to get out of it is to at some point pay off a vehicle instead of trading so often. If you managed to trade the vehicle again instead of repairing it, then you would probably find yourself in a similiar situation in another year or two, only this time $8000 or $10000 upside down, and at some point you simply run out of financing options and cannot borrow enough to buy a new one. The only cure for this is to get the car loan paid off, or very close to paid off, before getting another vehicle. Since this means driving your present car for another couple of years, repairing it seems like the only sensible option.
I hope this is helpful to you, if so, an accept would be most appreciated! Thanks!