I'm trying to center this image vertically inside a div. As you can see I've accomplished that, however, it's still pushed slightly towards the bottom of the div. I can't find any reasons why this would be and I've even tried a different image.
HTML:
<div class="site-header">
<img class="logo" src="CGLOGO.png" alt="logo">
</div>
My CSS:
html, body {
margin: 0;
background: #F7B267;
}
.site-header {
background: #eee;
color: #555;
height: 3.125em;
line-height: 3.125em;
margin-bottom: 1rem;
}
.logo {
max-height: 75%;
vertical-align: middle;
}
Result: