餐饮类网站滑动导航

index.html

<!DOCTYPE html>
<html lang="en"head>
    meta charset="UTF-8"title>index</link rel="stylesheet" href="css/reset.css"="css/style.css"bodynav id="menu">
        ul>
            li class="rocket"><a href="">Item menu 1a></li="wine">Item menu 2="burger">Item menu 3="comment">Item menu 4="sport">Item menu 5="earth">Item menu 6div ="current">
                ="top-arrow"div="current-back"="bottom-arrow"navhtml>

reset.css

html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:border:font-size:100%;font:inherit;vertical-align:baseline}article,section{display:block}body{line-height:1}ol,ul{list-style:none}blockquote,q{quotes:blockquote:before,blockquote:after,q:before,q:after{content:'';table{border-collapse:collapse;border-spacing:0}

style.css

#menu{
    display: inline-block;
    height: 135px;
    width: 80%;
    vertical-align: middle;
    white-space: nowrap;
    margin-left:10%;
    margin-top:100px;
}
#menu ul li{
    position: relative;
    z-index: 2; block;
    float: left; 15%;
    line-height: 220px;
    margin-right: 1.42857%;
    background-position: 50%;
    text-align: center;
}
.rocket {
    background: url('../images/rocket-large.png')no-repeat; 1.42857%;
}

.wine { url('../images/wine-large.png')no-repeat;
}

.burger { url('../images/burger-large.png')no-repeat;
}

.comment { url('../images/comment-large.png')no-repeat;
}

.sport { url('../images/sport-large.png')no-repeat;
}

.earth { url('../images/earth-large.png')no-repeat;
}
#menu ul { relative;
}

#menu ul:after {
    content: "";
    clear: both;
}
#menu a {
    color: #D8D8D8;
    text-decoration: none; 100%;
    text-shadow: 0 -1px 0 #000;
}

#menu li:after { 9.5238%; absolute;
    top: 0;
    right: -9.5238%; url('../images/menu-bg.png');
}
.rocket:before {
    left: url('../images/menu-bg.png');
    border-radius: 5px 0px 0px 5px;
}

.earth:after { 0px 5px 5px 0px;
}

.current { -13px; 8.92857%; -49px; 95px; 165px;
    -webkit-transition: all 400ms cubic-bezier(.45,1.92,.9,1.54);
    -moz-transition:
    -o-transition:
    -ms-transition:
    transition: all 400ms cubic-bezier(.16,1.23,.87,1.18);
}

.current-back { #c39449; 5px;
    border-bottom: 2px solid rgba(0,0.09);
    border-top: 2px solid rgba(255,0.1);
}

.top-arrow {
    overflow: hidden; 12px; 13px; 2;
}

.top-arrow:before { 10px; -10px; 10%; 20%;
    box-shadow: 0 0 10px black;
}

.top-arrow:after { 0px; 8px solid #c39449;
    border-left: 6px solid transparent;
    border-right: -6px; 50%;
}

.bottom-arrow {
    bottom: 17px;

.bottom-arrow:before {

.bottom-arrow:after { 12px solid #c39449; 8px solid transparent; -8px;

.wine:hover~ .current { 25.5%;
}

.burger:hover~ .current { 42%;
}

.comment:hover~ .current { 58.5%;
}

.sport:hover~ .current { 75%;
}

.earth:hover~ .current { 91.1%;
}            

图片素材如下:

 

相关文章

Css常用的排序方式权重分配 排序方式: 1、按类型&#160;...
原文:https://www.cnblogs.com/wenruo/p/9732704.html 先上...
css属性:word-wrap:break-word; 与 word-break:break-all 的...
https://destiny001.gitee.io/color/
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML...
css之background的cover和contain的缩放背景图 对于这两个属...