How can you move the beginning of the page down to start under nav bar on all pages apart from Home page!

Hi, I’m working on a site and I’ve got the top of the Home page as I want it (nav bar transparent going over the top of a slider), but by adding CSS to do this, all the other pages start at the very top of the page instead of under the nav bar. I’ve tried adding .home before the CSS so it applies only to the Home page, but it doesn’t work.

The CSS I’m using is:

.x-navbar-fixed-top-active .masthead {
    position: absolute;
    top: 0;
    width: 100%;
}
.x-navbar-fixed-top-active .x-navbar {
background-color: transparent;
border-bottom: none;
}
.x-navbar {
    background-color: transparent;
    border:0;
}
.x-topbar-fixed-top,
.x-logobar-fixed-top {
     position:fixed;
     top:0;
     width:100%;
}

I’d appreciate it if you could take a look and let me know what I’m doing wrong!

I’ll put the URL in a secure note as it’s on a temp link.

Thanks!

Hi there,

Thanks for writing in! Please replace this part of your code:

.x-navbar-fixed-top-active .masthead {
    position: absolute;
    top: 0;
    width: 100%;
}

With this:

.home.x-navbar-fixed-top-active .masthead {
    position: absolute;
    top: 0;
    width: 100%;
}

If you would like to learn CSS, I am sharing few resources that you take a look to get started with CSS and an interesting tool that you can use to speed up the development process.

I recommend you to watch following video that will help you to get started with CSS.

https://www.youtube.com/watch?v=MFR4WXiLzpc

Sometimes it can get a bit difficult to find out the right selector to be able to write the required CSS codes. A handy tool that can help you in this is Google Chrome dev tools. I am sharing the resource that you can refer to get started with dev tools.

https://developers.google.com/web/tools/chrome-devtools/css/

https://developers.google.com/web/tools/chrome-devtools/

https://www.youtube.com/watch?v=tP_kXBJWPhQ&t=200s

Cheers!

Thank you! I’m hoping one of these days CSS will all make sense and I wont have to bother you asking for help with it!

Thanks!

Glad we could help.

Cheers!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.