body{
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #0e1520;
    min-height: 100vh;
}

.element{
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20em;
    height: 20em;
    box-shadow: 20px 18px 20px rgba(0, 0, 0, .5);
    border-radius: 1em;
    background-color: rgba(0, 0, 0, .5);
    overflow: hidden;
}

.element::before{
    content: '';
    position: absolute;
    width: 10em;
    height: 140%;
    background: linear-gradient(cyan, magenta);
    animation: rotate 5s linear infinite;
}

.element::after{
    content: '';
    position: absolute;
    inset: 5px;
    background-color: #0e1520;
    border-radius: .8em;
}

@keyframes rotate {
    to{
        transform: rotate(360deg);
    }
}
