I'm generalising here so do not take it personally
I don’t think it is quite that simple. Unfortunately you lost money because the bike you had was one which, so far, has not really grabbed the attention of collectors therefore they have not appreciated in value. For some reason that era of bikes in general have not performed like those from before and after. There are signs that it may be changing. Very good examples of the GS1000 are just starting to climb, as are naked Gold Wings. I am sure the XS will have its day eventually.
I don’t believe the demand for classics is diminishing. Most classic bikes are owned by people who have at least one other bike and cover very few, if any miles. Many are just left on a SORN. I have owned many classics and been to view a huge amount and I could count on one hand the number that were the only bike in the garage. If you have a few grand sitting in the bank, buying a classic bike, or car, makes perfect sense. The interest on investments is virtually nil at present, so why not own something that is nice to look at and tinker with? The most important thing is to buy well. If buying something that is an established classic you must get one that is complete because certain parts can be unavailable or very expensive. In most cases it is best to buy one that is already in perfect, or very good, condition. If you buy a bad one and restore it you will struggle to get your money back. I have several bikes. Only three are currently taxed and mot’d. Two are stashed away in my mother-in-laws garage in the hope they will go up in value. As with all investments, there is a risk. Classic vehicle values soared and crashed last time we had a major recession, but they have bounced back to greater heights this time around. I am always on the look out for another. I quite fancy this GT in fact. I used to own a T500 which, apart from the tank and disc brake is pretty much the same bike.