[css] 二级菜单---仿照京东_html


[css] 二级菜单---仿照京东_html_02

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
*{
margin: 0;
padding: 0;
}
ul{
list-style: none;
}
.box{
width: 600px;
height: 40px;
margin: 0 auto;
margin-top: 100px;
background-color: rgb(247, 165, 165);
}
.box li{
float: left;
width: 100px;
text-align: center;
line-height: 40px;
}
.box li .zixun{
width: 200px;
height: 200px;
background-color: rgb(202, 134, 134);
font-size: 30px;
font-weight: bold;
text-align: center;
}
.box li .wuliu{
width: 200px;
height: 300px;
background-color: rgb(181, 214, 102);
font-size: 30px;
font-weight: bold;
text-align: center;
position: relative;
left:-100px;
}
.box li .lianxi{
width: 600px;
height: 300px;
background-color: rgb(59, 161, 122);
font-size: 30px;
font-weight: bold;
text-align: center;
position: relative;
left:-400px;
}
.box li div{
display: none;
}
.box li:hover{
background-color: #ccc;

}
.box li:hover>div{
display: block;
background-color: #ccc;
}
</style>
</head>
<body>
<ul class="box">
<li>首页</li>
<li>商品信息</li>
<li>
商品咨询
<div class="zixun">
商品咨询内容
</div>
</li>
<li>
物流快递
<div class="wuliu">
物流快递内容
</div>
</li>
<li>
联系我们
<div class="lianxi">
联系我们内容
</div>
</li>
<li>
咨询售后
</li>
</ul>
</body>
</html>

[css] 二级菜单---仿照京东_html_03


[css] 二级菜单---仿照京东_html_04