<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
<style>
* {
margin:0;
padding:0;
}
ul {
list-style:none;
}
body {
min-width:320px;
max-width:540px;
margin:auto;
}
header {
width:100%;
height: 100px;
/* 继承Body的宽度 */
}
header img {
width:100%;
/* 继承header的宽度 */
height:100%;
}
nav {
padding:5px;
}
.row {
height: 90px;
width:100%;
background-color: #ff697a;
border-radius:8px;
display: flex;
margin-bottom:5px;
}
nav .row:nth-child(2) {
background-color: #3d98ff;
}
nav .row:nth-child(3) {
background-color: #44c522;
}
nav .row:nth-child(4) {
background-color: #fc9720;
}
.row3 {
border-left:1px solid #fff;
flex:1;
}
.row div:first-child {
border:0;
}
.hotel {
display: flex;
flex-direction:column;
}
.hotel a {
flex:1;
font-size:16px;
color:#fff;
text-align:center;
line-height:45px;
text-decoration:none;
text-shadow:0 2px 2px rgba(0,0,0,0.7);
}
.hotel a:first-child {
border-bottom:1px solid #fff;
}
</style>
</head>
<body>
<header>
<img src="header.png" height="154" width="768" alt="">
</header>
<nav>
<div class="row">
<div class="row3"></div>
<div class="row3 hotel">
<a href="#">海外酒店</a>
<a href="#">特价酒店</a>
</div>
<div class="row3 hotel">
<a href="#">团购</a>
<a href="#">同福客栈</a>
</div>
</div>
<div class="row">
<div class="row3"></div>
<div class="row3 hotel">
<a href="#">海外酒店</a>
<a href="#">特价酒店</a>
</div>
<div class="row3 hotel">
<a href="#">团购</a>
<a href="#">同福客栈</a>
</div>
</div>
<div class="row">
<div class="row3"></div>
<div class="row3 hotel">
<a href="#">海外酒店</a>
<a href="#">特价酒店</a>
</div>
<div class="row3 hotel">
<a href="#">团购</a>
<a href="#">同福客栈</a>
</div>
</div>
<div class="row">
<div class="row3 hotel">
<a href="#">海外酒店</a>
<a href="#">特价酒店</a>
</div>
<div class="row3 hotel">
<a href="#">海外酒店</a>
<a href="#">特价酒店</a>
</div>
<div class="row3 hotel">
<a href="#">团购</a>
<a href="#">同福客栈</a>
</div>
</div>
</nav>
</body>
</html>