JSFiddle - React, Tailwind, and code Playground
by ozzon91
HTML
<div class="hi-icon-wrap">
<a href="#set-9" class="hi-icon">1</a>
<a href="#set-9" class="hi-icon">2</a>
<a href="#set-9" class="hi-icon">3</a>
<a href="#set-9" class="hi-icon">4</a>
<a href="#set-9" class="hi-icon">5</a>
<a href="#set-9" class="hi-icon">6</a>
<a href="#set-9" class="hi-icon">7</a>
<a href="#set-9" class="hi-icon">8</a>
<a href="#set-9" class="hi-icon">9</a>
<a href="#set-9" class="hi-icon">10</a>
</div>
CSS
body {background: #000; font-family: arial;}
.hi-icon-wrap {
text-align: center;
margin: 0 auto;
padding: 1em 0 2em;
}
.hi-icon {
display: inline-block;
font-size: 20px;
cursor: pointer;
margin: 15px 10px;
width: 51px;
height: 51px;
line-height: 51px;
text-decoration: none;
border-radius: 50%;
text-align: center;
position: relative;
z-index: 1;
color: #D78328;
}
.hi-icon:after {
pointer-events: none;
position: absolute;
width: 100%;
height: 100%;
border-radius: 50%;
content: '';
-webkit-box-sizing: content-box;
-moz-box-sizing: content-box;
box-sizing: content-box;
}
.hi-icon:before {
font-size: 48px;
line-height: 90px;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
display: block;
-webkit-font-smoothing: antialiased;
}
/* Effect */
.hi-icon {
-webkit-transition: box-shadow 0.2s;
-moz-transition: box-shadow 0.2s;
transition: box-shadow 0.2s;
}
.hi-icon:after {
top: 0;
left: 0;
padding: 0;
box-shadow: 0 0 0 3px #D78328;
-webkit-transition: -webkit-transform 0.2s, opacity 0.2s;
-moz-transition: -moz-transform 0.2s, opacity 0.2s;
transition: transform 0.2s, opacity 0.2s;
}
.hi-icon:hover:after {
-webkit-transform: scale(0.85);
-moz-transform: scale(0.85);
-ms-transform: scale(0.85);
transform: scale(0.85);
opacity: 0.5;
box-shadow: 0 0 0 3px #ec1c23;
}
.hi-icon:hover {
box-shadow: 0 0 0 10px #ec1c23;
color: #ec1c23;
}