“Have a great day.”
“Thanks, you too.”
Unless you’re living secluded in the woods, little exchanges like this are a common part of daily life. And a common mistake for language learners, because what they often respond if someone wished them a “schönen Abend” or a relaxed shift or whatever is this:
Technically, this is a correct translation for you too.
But usually it’s not the proper reply, and it sounds quite strange actually. What we need in these situations is
And that’s because in German, these things are usually thought of as wishes. You wish something TO the other person. A bit like saying “A good day to you.”, to which the proper reply is “To you too.”
And this “to you” is exactly what dir is. The Dative of du.
Now, Germans also do say stuff like “Hab einen schönen Tag!” (Have a great day.). And then the correct reply is indeed “Du auch.”
But if you get JUST the wish, so if someone says “Schönen Feierabend.” or “Viel Spaß.”, in a German brain that is “XYZ to you.” and that’s why the right reply is:
“Danke, dir auch.”