Negative margins

suggest change

Margin is one of a few CSS properties that can be set to negative values. This property can be used to overlap elements without absolute positioning.

div {
  display: inline;
}

#over {
  margin-left: -20px;
}
<div>Base div</div>
<div id="over">Overlapping div</div>

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents