I am making a responsive design website. What I want to do, is have my logo always have a height of 15% the window. This causes issues on mobile devices because my logo is a little long.
I want the logo to start shrinking when we run out of horizontal room. Here is what I have so far:
<img style="height: 15%; max-width: 100%" src="logo.png"/>
This looks fine on a regular screen, but when I get down smaller, it shrinks horizontally, but not vertically (the logo happens to have a few pixels of alpha on the right):
As you can tell, this is not desired and I would like the height to scale with the width in this case.