Calories in calories out is 100% valid for weight loss. The problem is that people interpret it to somehow be a claim on overall health when it is just a statement on weight gain and loss, which while can be beneficial to health, isn't everything.
A calorie is just a calorie, so much as color is color. Its a single property of food that can be compared. If you want to lose weight that is the property you primarily need to look at. If you care about overall health then obviously there is a lot more to it than just calories. People somehow interpreted a calorie is just a calorie as a claim that all food is the same when its just saying that from a weight loss perspective, the energy component from any food source is the same -- there are no further claims about nutrition content.