I don't think it's modern TV. Star Trek always has been relatively distinctive in the world of sci-fi TV and movie in presenting a more optimistic, scientifically progressive world for humanity.
Most Sci-fi, even in the 50s and 60s, always present us a more pessimistic view of science and the future. Post-apocalyptic world, alien or tyrant taking over earth, nuclear/environmental holocaust, science creating monsters, freedom abolished, war with human-made android, dystopian world, etc, etc. It is based on our fear of science and the future. It serve as a warning of things to avoid. Star Trek posit that in the world of space travel and progressing science, humanity will settle their petty political squabbles and more current problems related to our materialistic world would be solved (poverty, hunger, war, many current diseases, etc). Technology like replicators, space travel, holodeck, advanced medicine solving many ills of our current time. In the world of Star Trek, it's humanity vs the universe. The Star Trek future world is still full of danger, evil aliens and various perils of space exploration.
Pessimistic and dystopian view of the future of humanity in Sci-fi movies and TV series is not new. In fact, it's largely the most common form of sci-fi entertainment since the birth of TV and cinema.