Product landing page - navigation element

Hi everybody. I am working on my product landing page and have a bit of struggle with navigation section element. I understand the functionality, but after I click on lets say ,tarifs, from navigation bar; I want to get on the part of the page that shows me all info about tarifs, instead I get on the part of the page where I see about 80 percent of info about tarifs. I added 2 photos, first one is what I would like to achieve and second one is what I actually get. Can you pls help? Thanks


Same thing happens also in this FCC muster project: https://codepen.io/freeCodeCamp/full/RKRbwL

This is happening because your header has a position of “fixed”. With fixed positioning the element is taken out of the document flow and the space it would have taken up is removed. Here is an article that provides multiple ways to fix this depending on specific conditions. Try to use that as guidance and if you are still having trouble post your codepen and I will try to help further.

2 Likes

@CitrineDragon Thank you a lot!