I need help with my HTML and CSS code. Here's the setup:
<div id="container">
<div id="content"></div>
<div id="close-button"></div>
</div>
For the CSS part, I have:
#container {
width: 50%;
}
#content {
width: 100%;
height: 50px;
background-color: gray;
}
#close-button {
float: right;
margin-left: 100%;
height: 50px;
width: 50px;
background-color: red;
}
If you check out this JSFiddle link here, you'll see that the red box is below the gray one. How can I make it so that the red box overlays on top of the gray box instead, regardless of the container's width? I want the gray box to cover 100% of the container and the red box to align to the very right.