Tell us what’s happening:
Your code so far
<h1>On Being Well-Positioned</h1>
<p>I still think the h2 is where it normally sits.</p>
Your browser information:
User Agent is:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.116 Safari/537.36.
Challenge: Move a Relatively Positioned Element with CSS Offsets
Link to the challenge:
In general, you would use
offset instead of
margin spaces an element around adjacent elements, thereby directly affecting adjacent elements.
offset is more of a positioning tool just like saying
top: 10px;, but
offset is relative to the flow of the page, whilst
top is relative to the top of the page.
I hope that helps.