It seems fairly obvious to us that a mirror flips things in horizontal direction. That is, your left hand becomes the right hand of your mirror image, and vice-versa. But it doesn't appear to flip things vertically. Ever thought about it? Now that you do, it sounds strange that all those years of your existence you either have not wondered about it, or, even if you have, you've failed to find an answer.
Physics Girl, a popular Youtuber explains in her channel why this seemingly uncanny thing happens. Here is the video.
To brief it, the mirror does not differentiate between horizontal and vertical. It doesn't do any flipping in either directions. It flips stuff neither in x-direction, nor in y-direction. It flips things in z-direction! And an interpolation of that concept causes all the confusion! Amazing? You're welcome!
We recommend following her for more great content, if you're a Physics fan like we are.