The <b>
tag overrides the <section>
tag, see the example when I use padding
:
Noticeintheimageabovethatthelightgraybarreferstosection
isshorterthantheb
tag.Thatis,theinnertagoverlaps.
AlsowhenIresizethebrowserthetagb
overlaysitself,withoutgivingthespacingdue.Seetheexamplebelow:
HTML
<sectionclass="compartilhar">
<span>Compartilhar:</span>
<span>Compartilhar:</span>
<span>Compartilhar:</span>
<span>Compartilhar:</span>
<span>Compartilhar:</span>
<span>Compartilhar:</span>
</section>
CSS
section.compartilhar{
width: 100%;
max-width: 1200px;
margin: auto;
padding: 10px;
box-sizing: border-box;
background-color: #ccc;
}
section.compartilhar span{
background-color: #333;
padding: 15px;
box-sizing: border-box
font-size: 18px;
}