Skip to content

Instantly share code, notes, and snippets.

@sguzik
Created May 8, 2012 18:39
Show Gist options
  • Save sguzik/2638352 to your computer and use it in GitHub Desktop.
Save sguzik/2638352 to your computer and use it in GitHub Desktop.
CSS For menus
.navbar ul {
position: relative;
left: 0;
display: block;
float: left;
margin: 10px 10px 0 0;
}
.navbar ul li {
display: block;
float: left;
margin:0 10px;
}
.navbar ul li a {
color: #999;
font-size:18px;
text-decoration:none;
font-weight:200;
}
.navbar ul li a:hover {
color:#fff;
text-decoration:none;
}
.navbar ul li.current_page_item a {
color: #fff;
}
.nav-collapse ul ul {
display: none;
float: left;
margin: 0;
position: absolute;
top: 3em;
left: inherit;
width: 188px;
z-index: 99999;
}
.nav-collapse ul ul ul {
left: 100%;
top: 0;
}
.nav-collapse ul ul li {
background: #000;
border-bottom: 1px dotted #ddd;
color: #999;
font-size: 13px;
font-weight: normal;
height: auto;
line-height: 1.4em;
padding: 10px 10px;
width: 168px;
}
.nav-collapse ul li:hover > ul {
display: block;
}
.nav-collapse .current-menu-item > a,
.nav-collapse .current-menu-ancestor > a,
.nav-collapse .current_page_item > a,
.nav-collapse .current_page_ancestor > a {
color: #fff;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment