I dealt with constant weight gain and weight loss for 5 years. It wasn't easy. Like you, I couldn't fit anything I wanted to wear, and yet no new clothes made me feel good enough 'coz I had much cuter clothes in my closet that I really really wanted to fit into. The problem was that I was comparing-----all the time. I had a mental image of what I wanted to look like and what I wanted to dress up in, and I felt miserable when that didn't happen.
About two years ago I decided to give myself a fresh start. I threw out all the clothes I didn't fit into, I erased the mental picture I had, and I decided to try a complete makeover. In other words, I decided to start dressing for the body I was in at that very moment.
I don't know much about you, but for me the problem resolved the minute I stopped hankering over the latest fashion trends. I'm curvy and I'm a big size, so I decided to dress for my body and accept my body - lumps, bumps and all. Style really isn't about your size; I've seen many very stylish women who I'm sure are above size 18. The problem starts when we 'compare'.
In these 2 years my sense of style has evolved a lot. I completely stopped obsessing over my weight (something I've done since I was 16). I stopped trying to be a particular size and I stopped trying to 'lose'weight. I continued to get moderate exercise everyday, I ate healthy but didn't deprive myself of anything, and I wore clothes that looked good on me irrespective of what brand I could/could-not find sizes at. Somewhere in between I evolved a sense of style that gave me 100% confidence in myself. I no longer wish I was thinner. In fact I'm very comfortable being me. I also lost a little weight though I wasn't consciously trying. I went from UK size 16 to 14 and the change only opened up new style avenues for me.
All I'm trying to say is this - I know it's hard to gain weight and feel ashamed. But it's OK. You can and will look stylish even with the weight. Just be kinder to yourself. And believe me, the day you stop chasing a perceived idea of what size you should be and simply start enjoying your life and sense of style, you'll be on the right track for life.