JSFiddle - React, Tailwind, and code Playground
HTML
<nav>
<ul class="pagination">
<li>
<a href="#">
1
<p class="pagination-text">Lorem Ipsum</p>
</a>
</li>
<li>
<a href="#">
2
<p class="pagination-text">Lorem Ipsum</p>
</a>
</li>
<li>
<a href="#">
3
<p class="pagination-text">Lorem Ipsum</p>
</a>
</li>
</ul>
</nav>
CSS
*,*:after,*:before{
box-sizing: border-box;
}
ul{
margin: 0;
padding: 0;
}
.pagination > li{
overflow: hidden;
position: relative;
margin-top: 25px;
width: 25%;
float: left;
list-style: none;
padding: 0;
}
.pagination > li p{
color: #000;
line-height: 1;
}
.pagination > li > a{
line-height: 50px;
text-decoration: none;
color: #000;
display: block;
text-align: center;
position: relative;
}
/*positon the circle*/
.pagination > li > a:before{
content:'';
position: absolute;
z-index: -1;
width: 50px; height: 50px;
left: 50%; margin-left: -25px;
border-radius: 100%;
border: 1px solid blue;
transition: all .2s;
}
/*positioning the line*/
.pagination > li:not(:last-of-type):after,
.pagination > li:not(:first-of-type):before{
content: '';
position: absolute;
background: blue;
top: 25px;
height: 1px;
}
.pagination > li:first-of-type:after{
left: 50%;
right: 0;
margin-left: 25px;
}
.pagination > li:not(:first-of-type):before{
left: 0;
right: 50%;
margin-right: 25px;
}
.pagination > li:not(:first-of-type):after{
right: 0;
left: 50%;
margin-left: 25px;
}
/*hover stuff*/
.pagination > li:hover a{
color: #fff;
}
.pagination > li:hover a:before{
background: blue;
}