I have 4 boxes. In one of the boxes, I have placed 3 smaller boxes and I want to align them to the left, center, and right while still keeping them on the same line. I've attempted using inline-block, but it doesn't seem to be working properly. Can you please review my code below and see where I might have gone wrong?
#boxContainer {
border: 1px solid black;
width: 500px;
height: 500px;
}
#leftBox {
text-align:left;
border: 1px solid black;
display: inline-block;
width: 100%;
}
#centerBox {
text-align:center;
border: 1px solid black;
display: inline-block;
width: 100%;
}
#rightBox {
text-align:right;
border: 1px solid black;
display: inline-block;
width: 100%;
}
span {
border: 1px solid red;
}
<div id='boxContainer'>
<div id='leftBox'><span>Left</span></div>
<div id='centerBox'><span>Center</span></div>
<div id='rightBox'><span>Right</span></div>
</div>