Skip to content

Instantly share code, notes, and snippets.

@rynbyjn
Last active October 20, 2021 22:53
Show Gist options
  • Save rynbyjn/acc6c9af785a60a5b477dc0a086e099a to your computer and use it in GitHub Desktop.
Save rynbyjn/acc6c9af785a60a5b477dc0a086e099a to your computer and use it in GitHub Desktop.
Blobs
* {
box-sizing: border-box;
}
body {
background: #fff;
}
.container {
align-items: center;
display: flex;
height: 100vh;
justify-content: center;
}
.shape {
background: rgba(200, 200, 200, 0.4);
animation: morph 8s ease-in-out infinite;
border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
height: 400px;
transition: all 1s ease-in-out;
width: 400px;
z-index: 5;
}
@keyframes morph {
0% {
border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}
50% {
border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
}
100% {
border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}
}
<html>
<body>
<div class="container">
<div class="shape"></div>
<div class="shape" style="transform: scale(-1); position: absolute;"></div>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment