If this was me, and from what you have to do financially, I'd buy something that I can use on and offroad with slightly less cash output. The offroad trails would be hand picked because of the amount of loan and potential damage. You can quickly mod all models to handle better. The newer, the better resale if that is in the short term (5-7 yrs) goal (reflecting on owning 3 97s). Remember, you won't get what you put into it back, but what you put into it will better serve your immediate needs.
JKs are much wider than the TJ/YJ. They come better suited for a street/offroad blend. Larger tires are easily handled stock or with slight lift. More suspension options are available as well. Engine and trans will be covered by warranty for some time. Dealerships are handing out deals to move vehicles off their lots. If you can take the full burden of a $25k new vehicle loan, then I'd say JK Rubicon 4dr convt/hdtop. Add self fab or cheap cost protection and have fun.
As the model year gets older, the loan amount gets smaller as well as higher in rate. Loan is also dependent on you. Time to pay it off should be in alignment with ownership length of less than 5 yrs. You drive the vehicle off the lot and it has taken a drop in resale immediately.
Each model has its + and - and you've experienced the TJ side several times. The YJs are a tad roomier inside up front due to the flat dash. But its more a utility than the TJ.