What would it take to get it back in line with TOS? Maybe a dose of optimism and belief in conquering great evils and striving for a greater society. Maybe it just isn't a widely held set of beliefs anymore
I like to think that the decline of Trek is a combination of various factors. If we disregard TOS, the series that is most in line with that line of thought is TNG. Picard (in the series at least) holds those ideas in high regard and acts in nearly all episodes as a strong moral compass. The hand of Roddenberry is strong in that series, but Gene Roddenberry died during the making of TNG yet somehow Picard hasn't made a complete 180 and the show retained much of its popularity.
The change in the Trek universe is much more visible in the series of DS9, which sets an overall darker tone with the Dominion war. The point has been brought up before that DS9 battled for viewers with B5 where the tone in general about the future is far less resembling the Trek utopia, although comparing it to most modern scifi it's not all that "grimdark". To be honest, one of my favourite episodes in all of Trek is "In the Pale Moonlight", where Sisko basically goes against everything he stands for because it was necessary to get the Romulans on their side.
Once you get to Voyager, the change is irreversable. Voyager pretty much throws nearly continuity and Trek philosophy out of the airlock as Captain Janeway happily trods her way through the delta quadrant making alliances with the Borg, violating the prime directive in an almost action-hero kind of style, using warp 9 at an almost daily basis (despite it being forbidden in TNG by starfleet), contemplating genocide with the Borg, oh and in the series finale violates the temporal prime directive... It did make for good TV though. Compare Janeway to Picard (in the series) and you'll notice that they embody totally different ideologies. You could argue that over 70 years away from the federation they had little choice but to go with the flow, but just imagine Picard in that position.
A lot of Trek fans attribute the change in Trek to Rick Berman, but I think it's more complex. The audience has changed, and above all science fiction (or rather special effects) became relatively cheap to make. Trek suddenly had to compete with a lot more shows, and instead of focusing on storytelling the choice was made to focus on things like action and effects. Voyager is the best example of having a lot of characters they could build incredible stories about, but opted not to. They take on a Maquis crew, but aside from a few episodes it hardly gets mentioned what kind of problems this causes. Bellana as a half-human, half-klingon could have had so much more character development but barely got any aside from 2 episodes in 7 years. The only character to really get any character development was 7 of 9, and even there the plot always felt so underwhelming.
By the time Enterprise came out, I think most Trek fans were giving up on the franchise. I remember at the time that few people had something good to say about the show, so I skipped out on it.
As for the Trek movies. Picard in the TNG movies is no longer the Picard from the series. A complex man who upholds his principles and beliefs above all else was written into the role of an action hero,and in some movies even has a one-liner to finish off the villain. The TNG trek movies are action movies in line with the Trek universe, and I think the Trek reboot just makes the gap between the Trek ideas even bigger. I don't think they are bad movies, as long as you watch them as action movies and not as TNG Trek.
The problem with Trek, I think, is that the franchise is overused. The only way it can continue on and attract an audience is in a way that derivates from the original work but strays as far from it as possible. The traditional Trek audience won't be happy unless Picard 2.0 comes along, and the traditional Trek audience simply isn't as big as the generic-action-movie audience. With how cheap special effects have become, any new Trek series would have to compete with generic cheap scifi show X.
I think that for all purposes and intents, Star Trek is dead. There's not a lot left to do with the universe that fits into the Trek vision, especially if you want to keep a sense of continuity. Really, start something new that incorporates the philosophy of Trek, but dumps the setting. Trek has always had to carry its own history with it, which is what eventually lead to a ridiculous attempt at rebooting the Trek universe into a hyper-energized mirror of itself recently. It's a pity because we love the iconic things this series has given us, but at this point I think the franchise is far beyond salvation.