body{
  font-size: 20px;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 600;
  margin-left: 16%;
  margin-top: 3%;
}
.box {
  width: 150px; 
  height: 100px;
  background-color: blueviolet;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 99;
}
.box::before {
  content: '';
  width: 70px; 
  height: 200px;
  background-color: white;
  position: absolute;
  animation: 4s rotate linear infinite;
  z-index: -1;
}
.box::after {
  content: '';
  background-color: gold;
  position: absolute;
  inset: 5px;
  z-index: -1;
}
@keyframes rotate {
  0% {transform: rotate(0deg);}
  100% {transform: rotate(360deg);}
}