Vertical align div background and header
by robdodson
HTML
<div id="container">
<div id="cat-icon"></div>
<h1>Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? Ain't that neat? </h1>
</div>
CSS
#container {
margin-left: 104px;
}
#cat-icon {
display: inline-block;
vertical-align: middle;
margin-left: -104px;
width: 100px;
height: 100px;
background: url('http://placekitten.com/g/100/100');
}
h1 {
display: inline-block;
vertical-align: middle;
max-width: 100%;
}