Image-orientation is the CSS property used generally to fix the intended orientation of an image. This can be done using 90 degree increments or based on the image’s exif data using the “from-image” value.
This feature is currently only supported by Firefox.
You can use image-orientation like this:
More information can be found here.