bbennett36 bbennett36 - 2 months ago 11
CSS Question

Image is overlapping in navbar

Can't figure out why the image is overlapping on this page.

http://brennanbennett-firstclassmvc.rhcloud.com/

screenshot of what im seeing

The image is wrapped in a link tag, and when I inspect it the link tag is in the correct place but the img appears slightly below it and im not sure why. When I inspect the img there is no margins or anything. Any tips?

Answer

If you are telling about the overlapping here:

overlap

Then it is because the <a> element has padding. This is because of this rule:

.navbar-brand {padding: 15px 15px;}

Please remove it, or override it, so that, it looks like this:

corrected

CSS Solution

.navbar-brand {padding: 0;}