Site logo

Archived topic

Sticky Top Bar and Header

2 replies · Started by PJ on April 7, 2022

Viewing posts 1–3 of 3

Hi there,

I've used the following CSS to create a sticky top bar and header for clients. However, for some reason, the header turns transparent on this particular site. I've double checked the settings, ensured there is a background-color, etc., but nothing is working. Thoughts?

/* Sticky Top Bar */

@media screen and (min-width: 1000px) {
	
header {
	margin-top: 40px !important;
	position: relative !important;
}
	
.navigation-stick  {
	padding-top: 40px;
}
	
.top-bar {
	position: fixed;
	right: 0;
	left: 0;
	top: 0;
	z-index: 1000;
}

.admin-bar .top-bar {
	top: 32px;
}

#masthead {
		z-index: -1 !important;
}
}

Thank you!
Becky Sue

Nevermind: Got it! The #masthead z-index needed to be 1 instead of -1. Thank you.

Glad you figured it out :)

This archived topic is closed to new replies.