In the past, sick people were considered morally corrupt
You don't have to look all that hard to find people who still think this way. Isn't humanity splendid?
Yes but we are talking about junkies and addicts, not social drinking. No one on 24th Century Earth needs to depend on drugs to make their life tolerable so there is no reason to develop a dependency.
I'm really not sure it's that simple, that drug abuse and dependency can be reduced to such a binary phenomena. Nor am I sure that people in the 24th century are quite so uniformly content, regardless of circumstances. There is still death, loss, warfare, criminality. People still get divorced, fight, experience failure and despair. They still suffer mental health problems, they are still born with addictive personalities, they still become self destructive and suicidal.
Trek isn't religious(that much) but there are still hints of a remaining metaphysical.
With a couple of exceptions trek is almost uniformly secular, lambasting religion on a frequent basis