I created a circle in CSS and I created another circle using pseudo-elements 'after'. but the created pseudo-element circle is not properly centred in the main circle.
can someone tell me what are the different ways to centre pseudo elements?
Thanks.
.main{
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
}
.first{
width: 100px;
height: 100px;
border-radius: 50%;
background-color: rgb(202, 202, 202);
cursor: pointer;
box-shadow: 0 0 6px 1px #e8eef6;
position: relative;
}
.first::after{
content: '';
height: 70px;
width: 70px;
border-radius: 50%;
background-color: rgb(78, 78, 78);
position: absolute;
}
<div class="main">
<div class="first"></div>
</div>