Navigation Margins
-
Hi Everyone,
I am having difficulty with the margins underneath my navigation bar. When I try and change the margin so the header is below the nav bar, the drop down menus don’t work for some reason. Here is the code I am using:
#nav { width: 100%; float: left; margin: 0 0 6em 0; background-color: #ffffff; text-transform: lowercase; opacity:0.7; clear: both; overflow: hidden; } #nav .wrap { color: #777; font-family: 'Verdana', arial, sans-serif; letter-spacing: 2px; margin: 0 auto; width: 600px; } #nav ul { float: left; width: 100%; } #nav li { float: left; list-style-type: none; } #nav li a { color: #336699; display: block; font-size: 13px; padding: 12px 15px 14px; text-decoration: none; position: relative; } #nav li a:hover, #nav li a:active, #nav .current_page_item a, #nav .current-cat a, #nav .current-menu-item a { color: #ccc; } #nav li li a, #nav li li a:link, #nav li li a:visited { background-color: #fff; border: none; border-top-width: 0; color: #336699; font-size: 11px; letter-spacing: 1px; padding: 5px 10px; position: relative; text-transform: none; width: 138px; } #nav li li a:hover, #nav li li a:active { background-color: #ccc; } #nav li ul { height: auto; left: -9999px; position: absolute; width: 160px; z-index: 9999; } #nav li ul a { width: 140px; } #nav li ul ul { margin: -33px 0 0 159px; } #nav li:hover>ul, #nav li.sfHover ul { left: auto; }Does anyone have any insight on this? My page is located here
Thank you!
-
replace
#nav { width: 100%; float: left; margin: 0 0 6em 0; background-color: #ffffff; text-transform: lowercase; opacity:0.7; clear: both; overflow: hidden; }with
#nav { width: 100%; margin: 0 0 6em 0; background-color: #ffffff; text-transform: lowercase; opacity:0.7; clear: both; overflow: hidden; }Hi wprock,
Thank you for the response, I made the the change, but it hasn’t changed the margin at all. Do you think it may be something with the header margin?
/* Header ------------------------------------------------------------ */ #header { margin: 0 auto; min-height: 150px; overflow: hidden; width: 960px; } #title-area { float: left; overflow: hidden; padding: 30px 0 25px; width: 480px; } #title { font-family: 'Pacifico', arial, serif; font-size: 48px; line-height: 60px; margin: 0 0 5px; text-shadow: #fff 1px 1px; text-align:center; } .header-full-width #title { text-align: center; } #title a, #title a:hover { color: #8f8d85; text-decoration: none; } #description { color: #938868; font-size: 14px; font-style: italic; text-shadow: #fff 1px 1px; } .header-full-width #description { text-align: center; } #header .widget-area { float: right; width: 470px; }Do you see anything unusual there?
Your header image (logo) have extra white spaces at top. Please remove those extra space from logo using photoshop and re-upload again via Dashboard. This will reduce much spaces below the navigation.
another way you can do this by CSS
go to line no 218 and replace
height:80pxtoheight: 0go to line no 348 and add this elements in the #nav css
#nav{ position: static; z-index: 99; }reduce the navigation margin now
Thank you for your help! I inserted the code and got rid of the white space on my header. There’s still a small gap, but it is better than it was before. I think this thing has a mind of its own! Thank you again!
try to reduce the nav margin
#nav {margin: 0 0 2.3em 0;}Amazing!! Thank you!!
The topic ‘Navigation Margins’ is closed to new replies.