Pen Settings

HTML

CSS

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.

+ add another resource

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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.

+ add another resource

Behavior

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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div class="notification">
  <span class="sobre"></span>
  <span class="sobreback"></span>
  <span class="carta"></span>
  <span class="sombra"></span>
  <span class="alerta"></span>
</div>
              
            
!

CSS

              
                body{
  background-color:#685EA7;
  display:flex;
  width:100%;
  height:100vh;
  justify-content:center;
  align-items:center;
}
span{
  transition:all 1s ease;
}
.sobre{
	width: 0px;
	height: 0px;
	position: relative;
	margin-bottom: 0;
	border-left:50px #E94961 solid;
	border-bottom: 20px #E94961 solid;
	border-right: 50px #E94961 solid;
	border-top: 20px rgba(0,0,0,0) solid;
	box-shadow: 0px 4px 0px 0px rgba(24,116,86,0);
	-webkit-box-shadow: 0px 4px 0px 0px rgba(24,116,86,0);
	z-index: 4;	
  animation: float_sobre 2s infinite;
}
.sobreback{
	width: 100px;
	height: 60px;
	background-color: #E94961;
	position: absolute;
	margin-bottom: 0;
	z-index: 3;
  transform:translatex(-103px) translatey(-22px);
  border:3px solid #47454E;
  border-radius:5px;
  animation: float_sobreback 2s infinite;
}

.carta{
	width: 85px;
	height: 100px;
	background-color: #fff;
  border:3px solid #47454E;
  border-radius:5px;
	z-index: 3;
  position:absolute;
  transform:translatex(-95px) translatey(-70px);
  animation: float_carta 2s infinite;
  &:before{
    content: ". .";
    font-size:30px;
    margin-left:35px;
  }
  &:after{
    position:absolute;
    content: ")";
    font-size:30px;
    transform: rotate(90deg) translatex(25px) translatey(15px);
  }
}
.sombra{
  position:absolute;
  background-color: rgba(0,0,0,0.4);
  width:100px;
  height:10px;
  border-radius:5px;
  transform:translatey(50px) translatex(-100px);
  animation: float_sombra 2s infinite;
}

@keyframes float_carta{
  0%{
    transform:translatey(-75px) translatex(-95px);
  }
  50%{
    transform:translatey(-70px) translatex(-95px);
  }
  100%{
    transform:translatey(-75px) translatex(-95px);
  }
}
@keyframes float_sobre{
  0%{
    transform:translatey(-5px);
  }
  50%{
    transform:translatey(-0px);
  }
  100%{
    transform:translatey(-5px);
  }
}

@keyframes float_sobreback{
  0%{
    transform:translatex(-103px) translatey(-27px);
  }
  50%{
    transform:translatex(-103px) translatey(-22px);
  }
  100%{
    transform:translatex(-103px) translatey(-27px);
  }
}
@keyframes float_sombra{
  0%{
    opacity:0.7;
  }
  50%{
    opacity:1;
  }
  100%{
    opacity:0.7;
  }
}

.alerta{
  position:absolute;
  width:20px;
  height:20px;
  background-color: #E94961;
  border: 3px solid #47454E;;
  border-radius: 50%;
  transform: translatey(-85px) translatex(-20px);
  z-index:6;
  animation: float_alerta 2s infinite , scale 5s infinite;
}
@keyframes float_alerta{
  0%{
    transform: translatey(-85px) translatex(-20px);
  }
  50%{
    transform: translatey(-80px) translatex(-20px);
  }
  100%{
    transform: translatey(-85px) translatex(-20px);
  }
}
@keyframes scale{
  0%{
    transform: scale(0);
  }
  50%{
    transform: scale(1);
  }
  100%{
    transform: scale(0);
  }
}


              
            
!

JS

              
                
              
            
!
999px

Console