$type: zoom; // spin, zoom $width: 5px; $hue: 100; $speed: 10000ms; $zoom: 0; $deg: 180deg; body { background: #000; } #cube { position: fixed; top: 0; left: 0; right: 0; bottom: 0; margin: auto; -webkit-filter: blur(100px) contrast(100) saturate(10); polygon { fill: none; stroke-width: $width; transform-origin: 50% 50%; @for $i from 30 through 1 { &:nth-child(#{$i}) { stroke: hsl($hue * $i,100%,50%); animation: $type $speed / $i linear infinite; } } } } @keyframes zoom { 50% { transform: scale($zoom); } } @keyframes spin { 25% { transform: rotate($deg); } 75% { transform: rotate(-$deg); } }