cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

Quick-add: + add another resource

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

Quick-add: + add another resource

Code Indentation

     

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

            
              .shield__center
  .shield__wrap
    .shield__glass
      .pane
      .pane
      .pane
    .shield__glass
      .pane
      .pane
      .pane
    .emitter
      -(1..14).each do |i|
        .emitter__node
          .emitter__node-side
          .emitter__node-side
          .emitter__node-side
    .floor
      -(1..8).each do |i|
        .floor__dot
.echo
  .echo__wave
            
          
!
            
              @import "bourbon"

// --- colors
$color-background: #66FFCC
$color-glass: #FFADD6
$color-line: #3D007A
$color-particles: #fff
$color-ripples: #00E6E6
$color-dots: #FFF

// --- vars
$width: 40vh
$height: 50vh
$perspective: 600px

=block($w, $h)
  display: block
  width: $w
  height: $h
  
=absolute($w, $h)
  position: absolute
  top: $w
  left: $h
  
body
  background: $color-background
  
// ---  shield
.shield__center
  +block($width, $height)
  +absolute(50%, 50%)
  transform: translateX(-50%) translateY(-50%)
  transform-style: preserve-3d
  perspective: $perspective
  z-index: 1
 
.shield__wrap
  +block(100%, 100%)
  +animation(spinY 10.0s linear)
  +animation-iteration-count(infinite)
  transform-style: preserve-3d
    
.shield__glass
  +block($width, $height)
  +absolute(0, 0)
  transform: rotateX(-7.5deg)
  transform-style: preserve-3d
  transform-origin: top center
  perspective: $perspective

  .pane
    +block(33.333%, 100%)
    float: left
    background: $color-glass
    position: absolute
    opacity: .5
    border: 1px solid $color-line

    &:nth-child(1)
      +triangle($width/3 $height, $color-glass, up-right)
      background: none
      left: 0
      transform: rotateY(-30deg)
      transform-origin: left center

    &:nth-child(2)
      transform: translateZ($width/6) translateX(-50%)
      left: 50%
      width: 44%

    &:nth-child(3)
      +triangle($width/3 $height, $color-glass, up-left)
      transform: rotateY(30deg)
      background: none
      transform-origin: right center
      right: 0

.shield__glass + .shield__glass
  transform: rotateX(7.5deg) rotateY(180deg)
  transform-style: preserve-3d
  transform-origin: top center
  perspective: $perspective
  
// --- particle and emitter
.emitter
  +block($width/4, $width/4)
  +animation(spinY 1s linear)
  +animation-iteration-count(infinite)
  +absolute($width/10, 50%)
  margin-left: $width/16 * -1
  transform-style: preserve-3d
  
.emitter__node
  +block(100%, 100%)
  +absolute(0, 0)
  transform-style: preserve-3d
  
  @for $i from 1 through 14
    &:nth-child(#{$i})
      +animation(particle #{$i}s linear)
      +animation-iteration-count(infinite)
  
  
.emitter__node-side
  +block(100%, 100%)
  +absolute(0, 0)
  background: $color-particles
  border-radius: 50%
  
  &:nth-child(2)
    transform: rotateY(60deg)
  &:nth-child(3)
    transform: rotateY(-60deg)
  
// --- hover state echo
.echo
  +block(80vh, 80vh)
  +absolute(50%, 50%)
  transform: translateX(-50%) translateY(-50%)
  z-index: 0
  
.echo__wave
  +block(100%, 100%)
  +absolute(50%, 50%)
  transform: translateX(-50%) translateY(-50%)
  border-radius: 50%
  box-sizing: border-box
  border: 2vh solid $color-ripples
  opacity: 0
  +animation(ripple 1s)
  +animation-iteration-count(infinite)
    
  &:nth-child(1)
    animation-duration: 2s
    animation-delay: 0s
    
// -- floor loader?
.floor
  +block($width, $width)
  position: absolute
  bottom: 0
  transform: translateY(55%) rotateX(90deg)
  
.floor__dot
  +block($width/5, $width/5)
  +absolute(0, 0)
  background: $color-dots
  border-radius: 50%
  transform-origin: $width/2 $width/2
  +animation(ripple 1s)
  +animation-iteration-count(infinite)

  @for $i from 1 through 8
    &:nth-child(#{$i})
      transform: rotate(#{(360/8)*$i}deg)

  
// --- animations
+keyframes(spinY)
  0%
    +transform(rotateY(0deg))
  100%
    +transform(rotateY(-360deg))
    
+keyframes(ripple)
  0%
    width: 0
    height: 0
    opacity: 0
  50%
    opacity: .5
  100%
    opacity: 0
    border-width: 100vh
    
+keyframes(particle)
  0%
    transform: translateY(0%)
    opacity: 0
  30%
    transform: translateY(-200%) translateX(60%)
    opacity: 1
  60%
    transform: translateY(-300%) translateX(-60%)
  75%
    transform: translateY(-400%) translateX(60%)
  100%
    transform: translateY(-500%)
    opacity: 0
            
          
!
999px
Loading ..................

Console