How upside down text works
Two things happen. Each letter is replaced with a character that looks like it's been rotated 180 degrees: a becomes ɐ (Latin small letter turned a), e becomes ǝ, h becomes ɥ. Then the order is reversed, so the last letter comes first. Together they make the line read correctly when the screen is turned upside down.
Upside down alphabet
ɐ q ɔ p ǝ ɟ ƃ ɥ ı ɾ ʞ l ɯ u o d b ɹ s ʇ n ʌ ʍ x ʎ z
∀ ᗺ Ɔ ᗡ Ǝ Ⅎ ⅁ H I ſ ꓘ ⅂ Ɯ N O Ԁ Ό ᴚ S ⊥ ∩ Ʌ M X ⅄ Z
Letters like o, s, x and z look the same either way, so they stay. For other tricks, try small text or small caps.