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.

            
              <div class="section one">
   <div>
      HOVER
   </div>
</div>
<div class="section two">
   <div>
      HOVER
      <p></p><p></p>
   </div>
</div>
<div class="section three">
   <div>
      HOVER
      <img src="http://tobiasahlin.com/static/cursors/pointer@4x.png" draggable="false">
   </div> 
</div>
            
          
!
            
              $cubic : cubic-bezier(.55,0,.1,1);
@mixin mont(){
   font-family: 'Montserrat', sans-serif;
}
@mixin shadow($x...){
   -webkit-box-shadow: $x;
   -moz-box-shadow: $x;
   -o-box-shadow: $x;
   box-shadow: $x;
   
}
@mixin trans($time, $curve, $elem){
   -webkit-transition: $elem $time $curve;
   -moz-transition: $elem $time $curve;
   -o-transition: $elem $time $curve;
   transition: $elem $time $curve;
}
@mixin center(){
   top: 50%;
   left: 50%;
   -webkit-transform: translate(-50%, -50%);
   -moz-transform: translate(-50%, -50%);
   -o-transform: translate(-50%, -50%);
   transform: translate(-50%, -50%);
}
@mixin radius($r){
   -webkit-border-radius: $r;
   -moz-border-radius: $r;
   -o-border-radius: $r;
   border-radius: $r;
}
html{
   width: 100%;
   height: 100%;
   text-rendering: optimizeLegibility;
   
}
body{
   margin:0;
   padding:0;
   width: 100%;
   max-width: 100%;
   height: 100%;
   text-rendering: optimizeLegibility;
}
.section{
   width: 100%;
   height: 50%;
   position: absolute;
}
.one{
   top: 0%;
   left:0;
   background: #000;
   
   div{
      color: #fff;
      position: absolute;
      @include center();
      @include mont();
      font-size: 32px;
      cursor: pointer;

      padding: 20px;
      @include radius(10px);
      @include trans(all, 0.4s ,ease);
      z-index: 10;
      &:hover{
         color: #000;
      }
      &::after{
         content:" ";
         position: absolute;
         top:0px;
         left:0px;
         width: 100%;
         height: 100%;
         background: #fff;
         z-index: -10;
         @include radius(10px);
         opacity:0;
         @include trans(all, 0.3s, ease);
      }
      &::before{
         content:" ";
         position: absolute;
         top:0px;
         left:0px;
         width: 100%;
         height: 100%;
         z-index: -10;
         @include radius(10px);
         @include shadow(0px 0px 0px #ccc,0px 0px 0px #808080, 0px 0px 0px #505050);
         @include trans(all, 0.4s,$cubic );
         opacity:0;
      }
      &:hover::after{
         opacity:1.0;
      }
      &:hover::before{
         opacity:1.0;
         @include shadow(0px -10px 0px #ccc, 0px -20px 0px #808080, 0px -30px 0px #505050);
         animation: dribble 1s $cubic infinite alternate;
      }
      
   }
}
@keyframes dribble{
   50%{
      @include shadow(50px -30px 0px #808080,70px -40px 0px #505050);
   }
   100%{
      @include shadow(-50px 30px 0px #808080, -70px 40px 0px #505050);
   }
}
.two{
   top: 50%;
   left:0;
   background: #EA038C;
   div{
      position: absolute;
      @include center();
      color: #fff;
      @include mont();
      font-size: 32px;
      font-weight: 900;
      cursor: pointer;
      @include trans(all, 0.2s, $cubic);
      
      &::after{
         position: absolute;
         left:-10px;
         top:-10px;
         width: 100%;
         height: 100%;
         background:#3EADFF;
         content:" ";
         padding: 10px;
         z-index: -1;
         @include trans(all, 0.3s, $cubic);
         
         transform: scale(0.0);
      }
      &:hover{
         color: #000;
         transition-delay: 1.3s;
      }
      &:hover::after{
         transform: scale(1.2);
         transition-delay: 1.3s;
      }
      p:nth-child(1){
         position:absolute;
         width: 20px;
         height: 20px;
         border: solid 4px #01ADED;
         @include radius(100%);
         @include shadow(0px 2px 0px #003347, inset 0px 2px 0px #003347);
         top: 0px;
         left:-40px;
         @include trans(all,1s,$cubic);
         opacity:0.0;
      }
      p:nth-child(2){
         position:absolute;
         width: 20px;
         height: 20px;
         border: solid 4px #01ADED;
         @include radius(100%);
         @include shadow(0px 2px 0px #003347, inset 0px 2px 0px #003347);
         top: 0px;
         right:-40px;
         @include trans(all,1s,$cubic);
         opacity:0.0;
      }
      &:hover p:nth-child(1){
         animation: jump 1.5s $cubic;
      }
        &:hover p:nth-child(2){
         animation: jumping 1.5s $cubic;
      }
   }
}
@keyframes jump{
   20%{
      opacity:1.0;
      top:-40px;
      left: 10px;
   }
   40%{
      transform: rotateY(180deg);
      opacity:1;
      top:-20px;
      left:40px;
   }
   60%{
      opacity:1;
      top: -50px;
      left: 85px;
   }
   80%{
      opacity:1;
      top: -50px;
      left: 85px;
      transform: rotateY(-180deg);
   }
   100%{
       opacity:1;
      top: -20px;
      left: 105px;
   }
}
@keyframes jumping{
   20%{
      opacity:1.0;
      top:-40px;
      right: 10px;
   }
   40%{
      transform: rotateY(180deg);
      opacity:1;
      top:-20px;
      right:40px;
   }
   60%{
      opacity:1;
      top: -50px;
      right: 85px;
   }
   80%{
      opacity:1;
      top: -50px;
      right: 85px;
      transform: rotateY(-180deg);
   }
   100%{
       opacity:1;
      top: -20px;
      right: 105px;
   }
}
.three{
   position: absolute;
   top: 100%;
   left:0;
   background: #FDF300;
   div{
      position: absolute;
      @include center();
      @include mont();
      font-size: 32px;
      @include trans(all, 0.4s , $cubic);
      cursor: pointer;
      font-weight: 900;
       &::after{
            content: " ";
            position: absolute;
            top:0px;
            right:0px;
            width: 0; 
  height: 0; 
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  
  border-top: 10px solid #000;

          transform: rotate(20deg);
          opacity:0;
          @include trans(all, 0.2s, $cubic);
         }
      &::before{
            content: " ";
            position: absolute;
            top:-4px;
            right:8px;
            width: 0; 
  height: 0; 
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  
  border-top: 10px solid #000;

          transform: rotate(-20deg);
         opacity:0;
         @include trans(all, 0.1s, $cubic);
         }
      &:hover::after{
         opacity:1;
         top:-8px;
         transition-delay: 0.4s;
      }
       &:hover::before{
         opacity:1;
         top:-12px;
          transition-delay: 0.4s;
      }
      img{
         position: absolute;
         top: 28px;
         right: -40px;
         width: 32px;
         opacity:0.0;
         @include trans(all, 0.4s, $cubic);
        
      }
      &:hover img{
         opacity:1.0;
         right: -20px;
         top:10px;
         transform:rotate(-25deg);
         animation: click 0.1s $cubic;
         animation-delay:0.4s;
      }
   }
}
@keyframes click{
   100%{
      transform:rotate(-25deg) scale(0.8);
   }
}
            
          
!
999px
Loading ..................

Console