The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS How to close a gap

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • #243261


    I wanted to find out if it is possible to close a gap in my design which is created by a div being moved via position:relative. A visual of the issue is here:

    The page in question is here:

    I’m not sure how to recreate the CSS in Codepen since it’s scattered around in my stylesheet. I tried using a Chrome extension to extract the code but it doesn’t seem to work. Hopefully someone can suggest a fix just by looking at the site in Chrome webtools.

    Thanks in advance.

    Cheers, R


    No, it’s not.

    That’s the way relative positioning works. The page remembers where it was and allocates that space as though the element was still there.

    I’d use (negative) margin.

    I made a demo explaining the differences a while ago.


    Thanks Paulie_D:

    I appreciate the reply and demonstration. I thought that was the case but I wanted to check with the community before I rethinking the design. I appreciate your time.

    Kind regards, R

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘CSS’ is closed to new topics and replies.