我有一个服务列表,下面有一个联系按钮。服务列表分为左右两边,联系按钮应该在下方居中。联系人按钮的样式正确,但位置除外 - 它对将其移到下方和居中的尝试没有响应。我尝试clear:both;
了各种设置margin
都padding
无济于事。我错过了什么?
html
<div id="services">
<div class="refrsh">
<h2>service 1</h2>
<p>lorem ipsum blah blah</p>
</div><!-- end refrsh -->
<div class="a-la-carte">
<h2>service 2</h2>
<p>lorem ipsum blah blah v 2.0</p>
</div><!-- end a-la-carte -->
<a class="get-started" href="#contact"><span>LET'S GET STARTED</span></a>
</div><!-- end services -->
css
#services .refrsh {
float: left;
padding-left: 150px;
width: 312px;
}
#services .refrsh p {
padding-top: 10px;
}
#services .a-la-carte {
float: right;
padding-right: 150px;
width: 312px;
}
#services .a-la-carte p {
padding-top: 10px;
}
#services .get-started {
clear: both;
font-family: nevis-webfont;
padding:8px 18px;
background:#52c0a3;
color:#fff;
border: 1px solid #fff;
font-size: 14px;
-webkit-border-radius: 2px;
-moz-border-radius: 2px;
border-radius: 2px;
}
#services .get-started:hover {
background:#fff;
color:#515151;
border: 1px solid #52c0a3;
text-decoration: none;
}