Navigation menu

<link href="https://fonts.googleapis.com/css?family=Heebo:100,300,400,500,700,800,900" rel="stylesheet">
 
  <main id=app>
 
    <nav>
      <!-- gooey menu background -->
      <aside class="goo">
        <ul>
          <li></li>
          <li></li>
          <li></li>
          <li></li>
        </ul>
      </aside>
      <!-- actual menu, cannot be inside gooey due to svg filter -->
      <ul class="menu">
        <li><a href="#">
          <svg viewBox="0 0 24 24"><use href="#home" /></svg></a></li>
        <li><a href="#">
          <svg viewBox="0 0 24 24"><use href="#heart" /></svg></a></li>
        <li><a href="#">
          <svg viewBox="0 0 24 24"><use href="#bag" /></svg></a></li>
        <li><a href="#">
          <svg viewBox="0 0 24 24"><use href="#settings" /></svg></a></li>
      </ul>
    </nav>
    
  </main>
  
  <svg viewBox="0 0 24 24">
    
    <!-- filter to make gooey effect -->
    <filter id="schlurp">
      <feGaussianBlur id="SourceGraphic" stdDeviation="10" />
      <feColorMatrix values="
         1 0 0 0 0
         0 1 0 0 0
         0 0 1 0 0 
         0 0 0 20 -10
      " />
    </filter>
    
    <defs>
      <g id="home">
        <path d="M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z" />
        <polyline points="9 22 9 12 15 12 15 22" />
      </g>
      <g id="heart">
        <path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z" />
      </g>
      <g id="bag">
        <path d="M6 2L3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4z" />
        <line x1="3" y1="6" x2="21" y2="6" />
        <path d="M16 10a4 4 0 0 1-8 0" />
      </g>
      <g id="settings">
        <line x1="4" y1="21" x2="4" y2="14" />
        <line x1="4" y1="10" x2="4" y2="3" />
        <line x1="12" y1="21" x2="12" y2="12" />
        <line x1="12" y1="8" x2="12" y2="3" />
        <line x1="20" y1="21" x2="20" y2="16" />
        <line x1="20" y1="12" x2="20" y2="3" />
        <line x1="1" y1="14" x2="7" y2="14" />
        <line x1="9" y1="8" x2="15" y2="8" />
        <line x1="17" y1="16" x2="23" y2="16" />
      </g>
    </defs>
    
  </svg>

  <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script> 
:root {
  --default: #00ffc3;
  --hover: #efceff;
  --size: 80px;
  --distance: calc(var(--size)*-1.1);
}

.goo,
.goo ul {
  background: inherit;
  filter: url("#schlurp");
}

ul {
  display: flex;
  justify-content: center;
  background: inherit;
  padding: 0 calc(var(--size) / 2);
}
ul li {
  width: var(--size);
  height: var(--size);
  background: var(--default);
  margin: 0 3px;
  color: black;
  position: relative;
}

.goo ul li:before {
  content: "";
  width: 100%;
  height: 100%;
  position: absolute;
  left: 0;
  top: 0;
  border-radius: 100%;
  background: inherit;
  transition: all 0.85s ease;
  transform: translate3d(0, 0, 0);
  will-change: transform;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
}
.goo ul li.hover:before {
  transition: all 0.5s cubic-bezier(0.09, 1.98, 0.41, 0.71);
  transform: translate3d(0, var(--distance), 0);
  background: var(--hover);
}

.menu {
  position: absolute;
  z-index: 1;
  background: transparent;
  text-align: center;
}

.menu li {
  background: transparent;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  transition: all 0.85s ease;
  height: calc(var(--size) * 2);
}
.menu li:hover {
  transition: all 0.5s cubic-bezier(0.09, 1.98, 0.41, 0.71);
  transform: translateY(-53%);
  color: white;
}
.menu li a {
  display: grid;
  grid-template-rows: 1fr 1fr;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(0, 0, 0, 0.6);
  transition: color 0.5s ease;
  width: 100%;
  height: 100%;
}
.menu li:hover a {
  color: rgba(0, 0, 0, 0.9);
}

nav {
  display: flex;
  justify-content: center;
  margin: 50px;
  background: var(--default);
  border-radius: 120px;
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
}

/* unimportant styles */
body {
  color: white;
  background: #333844;
  padding: 20px;
  font-family: "Heebo", sans-serif;
  display: flex;
  justify-content: center;
  text-align: center;
}

p {
  max-width: 70ch;
  font-weight: 200;
}

ul {
  list-style: none;
  margin: 0;
}

svg {
  width: calc(var(--size)/3);
  height: calc(var(--size)/3);
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
$(".menu li").on("mouseover touchstart", function() {
  let idx = $(this).index();
  $(".goo li").removeClass("hover");
  $("nav li").eq(idx).addClass("hover");
}).on("mouseout touchend", function() {
  $("nav li").removeClass("hover");
});