<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="shortcut icon" href="../img/logo/3084627.png" type="image/icon">
    <title>Face Art CSS</title>
    <link rel="stylesheet" href="/css/facestyle1.css">
</head>
<body>
    <div class="setup">
        <div class="face"></div>
        <div class="hair"></div>
        <div class="eyes"><div class="eyeball"></div></div>
        <div class="nose"></div>
        <div class="smile"></div>
    </div>
</body>
</html>
*{
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    background-color: aliceblue;
}

body{
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

.setup{
    background: #fafafa;
    width: 550px;
    position: relative;
    height: 550px;
    border: #232323 solid 4px;
    border-radius: 50%;
}

.hair{
    background-color: #6e3a25;
    width: 160px;
    height: 50px;
    position: absolute;
    border-radius: 40px 4px 4px 5px;
     left: 35%;
     transform: translateX(-50%);
     top: 80px;
}

.hair::before{
    content: '';
    background-color: #6e3a25;
    width: 165px;
    height: 50px;
    position: absolute;
    border-radius: 40px 4px 4px 5px;
     left: 49%;
     transform: translateX(50%) rotate(180deg);
     top: 0px;
}

.face{
    background-color: #ebdac6;
    width: 300px;
    height: 350px;
    border-radius: 0% 0% 50% 50%;
    position: absolute;
     left: 50%;
     transform: translateX(-50%);
    bottom: 70px;
}

.eyes{
    border-radius: 100%;
    background: #fff;
    border: #232323 solid 3px;
    width: 70px;
    height: 70px;
    left: 50%;
    position: absolute;
    top: 160px;
    transform: translateX(50%);
}

.eyes::before{
    content: '';
    border-radius: 100%;
    background: #fff;
    border: #232323 solid 3px;
    width: 65px;
    height: 65px;
    left: -300%;
    position: absolute;
    top: 0;
    transform: translateX(50%);
}

.eyeball{
    background: #232323;
    width: 35px;
    border-radius: 100%;
    left: 50%;
    position: absolute;
    top: 20px;
    transform: translateX(-50%);
    height: 35px;
}

.eyeball:before{
    content:'';
    background: #232323;
    width: 35px;
    border-radius: 100%;
    left: -390%;
    position: absolute;
    top: 0;
    transform: translateX(-50%);
    height: 35px;
}

.nose{
    background: #efd3b1;
    width: 45px;
    border-radius: 100%;
    left: 50%;
    position: absolute;
    top: 280px;
    transform: translateX(-50%);
    height: 45px;
}

.smile{
    height: 60px;
    width: 150px;
    border-radius: 0% 0% 100% 100%;
    border-bottom: #232323 solid 6px;
    background-color: transparent;
    left: 50%;
    position: absolute;
    top: 350px;
    transform: translateX(-50%);
}
Run Pen

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.