请老师检查
来源:5-2 编程练习
Gavinnn
2019-07-28 11:18:03
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<style>
/* 在此处补充代码*/
header {
display:flex;
justify-content:space-around;
align-items:center;
background:#000;
color:#fff;
font-size:18px;
}
.nav{
list-style:none;
width:400px;
display:flex;
justify-content:space-between;
}
.login{
width: 110px;
display:flex;
justify-content:space-between;
}
.login input{
background:#ffa500;
color:#fff;
font-size:16px;
border:none;
border-radius:2px;
height: 30px;
}
section{
height: 250px;
display:flex;
justify-content: space-around;
align-items: center;
}
.section{
width: 40%;
height: 200px;
display:flex;
align-items: center;
justify-content: space-around;
background: #add8e6;
border-radius: 5px;
}
.section .box{
display: flex;
flex-direction:column;
justify-content: space-around;
font-weight: bold;
height: 200px;
}
.section .btn{
width: 150px;
height: 50px;
background:#ffa500;
color:#fff;
font-size: 20px;
font-weight: bold;
line-height: 50px;
text-align: center;
border-radius: 5px;
}
.section .btn:hover{
color:#808080;
cursor:pointer;
}
</style>
</head>
<body>
<!-- 头部 -->
<header>
<div class="logo">
<img src="http://climg.mukewang.com/59197ab000014f1503000100.jpg" alt="">
</div>
<ul class="nav">
<li>课程</li>
<li>路径</li>
<li>猿问</li>
<li>手记</li>
</ul>
<div class="login">
<input type="button" value="登录">
<input type="button" value="注册">
</div>
</header>
<!-- 主体内容 -->
<section>
<div class="section">
<div class="box">
<p>《前端小白入门手册》</p>
<div>适用人群:没有任何前端基础的小白</div>
<div>费用:¥499</div>
</div>
<div class="shopping">
<div class="btn">加入购物车</div>
</div>
</div>
<div class="section">
<div class="box">
<p>《HTML5月CSS3实现动态网页》</p>
<div>适用人群:有html和css基础的童鞋</div>
<div>费用:¥599</div>
</div>
<div class="shopping">
<div class="btn">加入购物车</div>
</div>
</div>
</section>
<section>
<div class="section">
<div class="box">
<p>《前端小白入门手册》</p>
<div>适用人群:没有任何前端基础的小白</div>
<div>费用:¥499</div>
</div>
<div class="shopping">
<div class="btn">加入购物车</div>
</div>
</div>
<div class="section">
<div class="box">
<p>《HTML5月CSS3实现动态网页》</p>
<div>适用人群:有html和css基础的童鞋</div>
<div>费用:¥599</div>
</div>
<div class="shopping">
<div class="btn">加入购物车</div>
</div>
</div>
</section>
</body>
</html>
1回答
好帮手慕糖
2019-07-28
同学你好,效果实现是可以的,继续加油!
祝学习愉快!