<ul class='posts'>
<li class='post'>
<h2>Post Title</h2>
</li>
<li class='post'>
<h2>Post Title</h2>
</li>
<li class='post'>
<h2>Post Title</h2>
</li>
</ul>
.posts {
list-style: none;
margin: 0;
padding: 20px;
max-width: 650px;
margin: 4rem auto;
background: #f8f8f8;
}
.post {
color: red;
}
.post:not(:last-of-type) {
border-bottom: 1px solid #eee;
margin-bottom: .5rem;
padding-bottom: .5rem;
}
body{margin:30px;}