:root {
  --left-color: 228;
  --right-color: 90;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  display: flex;
  color: black;
  align-content: center;
  align-items: center;
  height: 100vh;
  width: 100vw;
  justify-content: center;
}

h1 {
  font-size: 10vh;

}

.circles-box {
  position: absolute;
  width: 100%;
  height: 100%;
  z-index: -1;
  display: flex;
  align-items: center;
  justify-content: center;
}

svg {
  width: 50vmin;
  height: 50vmin;
}

svg circle {
  animation-name: opacity;
  animation-duration: 15s;
}

svg circle:nth-element(3n) {
  animation-duration: 10s;
}

svg circle:nth-element(2n) {
  animation-duration: 8s;
}

svg circle:nth-element(4n) {
  animation-duration: 11s;
}

@keyframes opacity {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.left, .right {
  width: 50vw;
  height: 100vh;
  color: white;
  display: flex;
  font-size: 20vh;
  align-items: center;
  justify-content: center;
  position: relative;
  background-size: 400% 400%;
  animation: background 15s ease infinite;
  transition: opacity 1s ease;
  overflow: hidden;
  transform-style: preserve3d;

}

.left {
  background-image: linear-gradient(270deg, hsl(var(--left-color), 100%, 85%), hsl(var(--left-color), 100%, 70%));
  opacity: 0;
}

.right {
  background-image: linear-gradient(45deg, hsl(var(--left-color), 100%, 85%), hsl(var(--right-color), 100%, 70%));
  opacity: 0;
}

.left.active {
  background-image: linear-gradient(270deg, hsl(var(--left-color), 100%, 85%), hsl(var(--left-color), 100%, 70%));
  opacity: 1;
}

.right.active {
  background-image: linear-gradient(45deg, hsl(var(--left-color), 100%, 85%), hsl(var(--right-color), 100%, 70%));
  opacity: 1;
}
