在将我的 CSS 菜单置于页面中间时,我已经尝试了所有方法。
您可以在 www.eyewitnesssurveillance.com 上查看 CSS 菜单
有人可以帮我把这个菜单放在页面中央吗?谢谢!
这是我正在使用的 CSS 代码:
.top-menu-wrap {
margin: 40px 0px 0 0px;
padding: 0;
z-index: 1;
position: relative;
margin: auto;
}
.top-menu-center {
position: center;
text-align: center;
}
.menu-toggle {
width:40px;
height:40px;
text-indent:-99999px;
cursor:pointer;
position:absolute;
opacity:1;
top:0px;
right:15px;
-webkit-transition: all 0.2s ease-in;
-moz-transition: all 0.2s ease-in;
transition: all 0.2s ease;
}
.menu-toggle:hover {
opacity:1;
-webkit-transition: all 0.2s ease-in;
-moz-transition: all 0.2s ease-in;
transition: all 0.2s ease;
}
.menu-toggle-off {
background: url(../../images/menu/menu_toggle.png) 0 top;}
.menu-toggle-on {
background: url(../../images/menu/menu_toggle.png) 0 bottom;}
.homemenu {
font-family: 'Open Sans', sans-serif;
text-transform: uppercase;
padding: 0;
margin: 0;
height: 85px;
background: url(../../images/gradients/white_to_fade.png) repeat-y right top;
overflow:hidden;
}
.homemenu a { color:#666; text-decoration:none;}
.homemenu ul li {
background:#fff;
background: rgba(255,255,255,0.7);
overflow:hidden;
}