My prob is iI have already given margins for the body tag,
Don’t do that.
If you need to restrict the width of the content…create a container div and restrict the width of that…you can center it using
The Codepen doesn’t really demo anything useful….try using dummy images (perhaps from Lorempixel.com instead)…put borders around divs so we can see where they are.
Then clarify what exactly the problem is…it’s not clear.
My guess is that you haven’t got the hang of positioning yet. Chris has a video on it here…try searching for it.