"Why are you eating unhealthy food?"
Translation:Почему ты ешь вредную еду?
Yes, actually this is why I'm reading the comments here. One of the variants, "вредную" is not the same as unhealthy and seemed wrong to me.
It's one thing to eat something not quite good for you, but it's another thing to eat something outright harmful. Вредную means harmful, неполезную means unhealthy.
I'm a native speaker originally from Moscow.
No, it wouldn't, but I believe «вредная» is used more often in this meaning.
Duolingo generally doesn't accept Russian sentences with the pronoun dropped.
Such sentences only work in some contexts, but since Duolingo doesn't have any context for the sentences, it doesn't allow such sentences. Sentences with pronoun, on the other case, work well almost in any context, so you're encouraged to use them.
Полезный literally means “useful”. When applied to food, it means “healthy” or “good for your health” only because it is short for «полезный для здоровья». The opposite meaning is expressed by the word вредный (literally “harmful”). «Бесполезный» simply means “useless” and cannot be applied to food.