<div class="background">
<div class="face">
<div class="eye">
</div>
<div class="mouth"></div>
</div>
</div>
<!--
This illustration is based on the amazing work from this website:
https://jazzfm.ro/
-->
$bg-color: #660099;
$face: #FFC1D8;
$hair: #ED1D24;
$eye: #33CDFF;
body {
display: flex;
align-items: center;
justify-content: center;
height: 100vh;
background: #eee;
}
.background {
width: 400px;
height: 400px;
border-radius: 50%;
box-shadow: 0 0px 35px rgba(0, 0, 0, 0.35);
overflow: hidden;
background: radial-gradient(lighten($bg-color, 5), darken($bg-color, 8));
position: relative;
display: flex;
align-items: center;
justify-content: center;
}
:before,
:after {
content: "";
position: absolute;
}
.face {
width: 150px;
height: 200px;
background: $face;
border-radius: 0 100px 150px 150px;
position: relative;
right: 10px;
top: 10px;
&:before,
&:after {
background: $hair;
}
&:before {
width: 210px;
height: 115px;
top: -55px;
right: -30px;
border-radius: 290px 290px 0 0;
}
&:after {
width: 90px;
height: 200px;
z-index: 0;
border-radius: 0 0 140px 140px;
top: 50px;
right: -30px;
}
}
.eye {
width: 50px;
height: 50px;
background: white;
border-radius: 100px;
position: relative;
top: 30px;
left: 10px;
&:before {
width: 30px;
height: 30px;
background: $eye;
border-radius: 50px;
transform: translate(-50%, -50%);
top: 50%;
left: 50%;
}
}
.mouth {
width: 30px;
height: 30px;
border-top: 15px solid transparent;
border-left: 15px solid transparent;
border-bottom: 15px solid hotpink;
border-right: 15px solid hotpink;
border-radius: 50px;
position: absolute;
bottom: 20px;
&:before,
&:after {
width: 14px;
height: 14px;
border-radius: 100%;
background: hotpink;
position: absolute;
}
&:after {
top: -8px;
right: -8px;
}
&:before {
bottom: -8px;
left: -8px;
}
}
View Compiled
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.