octocatstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

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>
        <div>
            <div class="logo">
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <div>
                    <div class="inside"></div>
                </div>
                <img src="http://unleash-it.co.uk/images/unleash-logo.png" alt="Unleash IT" style="display: block; width: 250px; height: auto; margin-left: -55px; padding-top: 60px;">
            </div>
        </div>
    </div>
            
          
!
            
              @import "compass/css3";

$blue: #4cbbcf;
$secs: 0.6s;

@mixin animation($name, $seconds, $style, $totaltime) {
    animation: $name $seconds $style $totaltime;
    -ms-animation: $name $seconds $style $totaltime;
    -webkit-animation: $name $seconds $style $totaltime;
    -moz-animation: $name $seconds $style $totaltime;
    -o-animation: $name $seconds $style $totaltime;
}

@mixin rotate($deg, $distancex, $distancey) {
    -webkit-transform: rotate(#{$deg}deg) translate($distancex, $distancey);
    -moz-transform: rotate(#{$deg}deg) translate($distancex, $distancey);
    -ms-transform: rotate(#{$deg}deg) translate($distancex, $distancey);
    -o-transform: rotate(#{$deg}deg) translate($distancex, $distancey);
    transform: rotate(#{$deg}deg) translate($distancex, $distancey);
}

@mixin delay($nth) {
    -webkit-animation-delay: ($nth*0.035) + s;
    -moz-animation-delay: ($nth*0.035) + s;
    -ms-animation-delay: ($nth*0.035) + s;
    -o-animation-delay: ($nth*0.035) + s;
    animation-delay: ($nth*0.035) + s;

}

@-webkit-keyframes rumble {
    0% { margin: 0; opacity: 1; }
    50% { margin: 0 0 0 -25px; opacity: 0.5; }
    100% { margin: 0; opacity: 1; }
}@-moz-keyframes rumble {
    0% { margin: 0; }
    50% { margin: 0 0 0 -25px; }
    100% { margin: 0; }
}@keyframes rumble {
    0% { margin: 0; opacity: 1; }
    50% { margin: 0 0 0 -25px; opacity: 0.5; }
    100% { margin: 0; opacity: 1;}
}

@mixin rumblekeyframe($mixinname, $left, $newleft) {
    @-webkit-keyframes $mixinname {
    0% { margin: 0 0 0 $left; }
    50% { margin: 0 0 0 $newleft; opacity: 0.5;}
    100% { margin: 0 0 0 $left; }
    }
    @-moz-keyframes $mixinname {
        0% { margin: 0 0 0 $left; }
        50% { margin: 0 0 0 $newleft; opacity: 0.5;}
        100% { margin: 0 0 0 $left; }
    }
    @keyframes $mixinname {
        0% { margin: 0 0 0 $left; }
        50% { margin: 0 0 0 $newleft; opacity: 0.5;}
        100% { margin: 0 0 0 $left; }
    }  
}

@include rumblekeyframe(rumble44, -4px, -35px);
@include rumblekeyframe(rumble45, 10px, -35px);
@include rumblekeyframe(rumble46, -20px, -35px);
@include rumblekeyframe(rumble47, -10px, -45px);
@include rumblekeyframe(rumble48, 5px, -35px);
@include rumblekeyframe(rumble49, -13px, -45px);
@include rumblekeyframe(rumble50, -30px, -55px);
@include rumblekeyframe(rumble51, 5px, -35px);
@include rumblekeyframe(rumble52, -9px, -41px);
@include rumblekeyframe(rumble53, 8px, -35px);
@include rumblekeyframe(rumble54, -12px, -39px);
@include rumblekeyframe(rumble55, -6px, -35px);
@include rumblekeyframe(rumble56, 3px, -35px);

@-webkit-keyframes final {
    0% {opacity: 1; -webkit-transform: scale(1); }
    50% {opactiy: 0.1; -webkit-transform: scale(1.2);}
    100% {opacity: 1; -webkit-transform: scale(1);}
}@-moz-keyframes final {
    0% {-moz-transform: scale(1);}
    50% {-moz-transform: scale(1.2);}
    100% {-moz-transform: scale(1);}
}@keyframes final {
    0% {opacity: 1; transform: scale(1); }
    50% {opactiy: 0.1; transform: scale(1.2);}
    100% {opacity: 1; transform: scale(1);}
}

.logo {
    width: 144px;
    height: 144px;
    list-style: none;
    margin: 0 auto;
    padding: 150px 0 0;
    position: relative;
    @include animation(final, 0.65s, linear, 1);
    @include delay(75);
}

.logo > div {
    position: absolute;
    top: 37%;
    left: 44.5%;
    display: block;
    background: white;
}


.inside {
    position: absolute;
    display: block;
    color: $blue;
    width: 25px;
    height: 5px;
    padding: 0;
    margin-left: 0;
    background: $blue;
    @include animation(rumble, $secs, ease-in-out, 1);
}

.logo > div {
    &:nth-child(1) {
        @include rotate(90, -90px, 0);
    }
    &:nth-child(2) {
        @include rotate(96, -90px, 0);
        .inside {
            @include delay(1);
        }
    }
    &:nth-child(3) {
        @include rotate(102, -90px, 0);
        .inside {
            @include delay(2);
        }
    }
    &:nth-child(4) {
        @include rotate(108, -90px, 0);
        .inside {
            @include delay(3);
        }
    }
    &:nth-child(5) {
        @include rotate(114, -90px, 0);
        .inside {
            @include delay(5);
        }
    }
    &:nth-child(6) {
        @include rotate(120, -90px, 0);
        .inside {
            @include delay(6);
        }
    }
    &:nth-child(7) {
        @include rotate(126, -90px, 0);
        .inside {
            @include delay(7);
        }
    }
    &:nth-child(8) {
        @include rotate(132, -90px, 0);
        .inside {
            @include delay(8);
        }
    }
    &:nth-child(9) {
        @include rotate(138, -90px, 0);
        .inside {
            @include delay(9);
        }
    }
    &:nth-child(10) {
        @include rotate(144, -90px, 0);
        .inside {
            @include delay(10);
        }
    }
    &:nth-child(11) {
        @include rotate(150, -90px, 0);
        .inside {
            @include delay(11);
        }
    }
    &:nth-child(12) {
        @include rotate(156, -90px, 0);
        .inside {
            @include delay(12);
        }
    }
    &:nth-child(13) {
        @include rotate(162, -90px, 0);
        .inside {
            @include delay(13);
        }
    }
    &:nth-child(14) {
        @include rotate(168, -90px, 0);
        .inside {
            @include delay(14);
        }
    }
    &:nth-child(15) {
        @include rotate(174, -90px, 0);
        .inside {
            @include delay(15);
        }
    }



    &:nth-child(16) {
        @include rotate(180, -90px, 0);
        .inside {
            @include delay(16);
        }
    }
    &:nth-child(17) {
        @include rotate(186, -90px, 0);
        .inside {
            @include delay(17);
        }
    }
    &:nth-child(18) {
        @include rotate(192, -90px, 0);
        .inside {
            @include delay(18);
        }
    }
    &:nth-child(19) {
        @include rotate(198, -90px, 0);
        .inside {
            @include delay(19);
        }
    }
    &:nth-child(20) {
        @include rotate(204, -90px, 0);
        .inside {
            @include delay(20);
        }
    }
    &:nth-child(21) {
        @include rotate(210, -90px, 0);
        .inside {
            @include delay(21);
        }
    }
    &:nth-child(22) {
        @include rotate(216, -90px, 0);
        .inside {
            @include delay(22);
        }
    }
    &:nth-child(23) {
        @include rotate(222, -90px, 0);
        .inside {
            @include delay(23);
        }
    }
    &:nth-child(24) {
        @include rotate(228, -90px, 0);
        .inside {
            @include delay(24);
        }
    }
    &:nth-child(25) {
        @include rotate(234, -90px, 0);
        .inside {
            @include delay(25);
        }
    }
    &:nth-child(26) {
        @include rotate(240, -90px, 0);
        .inside {
            @include delay(26);
        }
    }
    &:nth-child(27) {
        @include rotate(246, -90px, 0);
        .inside {
            @include delay(27);
        }
    }
    &:nth-child(28) {
        @include rotate(252, -90px, 0);
        .inside {
            @include delay(28);
        }
    }
    &:nth-child(29) {
        @include rotate(258, -90px, 0);
        .inside {
            @include delay(29);
        }
    }
    &:nth-child(30) {
        @include rotate(264, -90px, 0);
        .inside {
            @include delay(30);
        }
    }



    &:nth-child(31) {
        @include rotate(270, -90px, 0);
        .inside {
            @include delay(31);
        }
    }
    &:nth-child(32) {
        @include rotate(276, -90px, 0);
        .inside {
            @include delay(32);
        }
    }
    &:nth-child(33) {
        @include rotate(282, -90px, 0);
        .inside {
            @include delay(33);
        }
    }
    &:nth-child(34) {
        @include rotate(288, -90px, 0);
        .inside {
            @include delay(34);
        }
    }
    &:nth-child(35) {
        @include rotate(294, -90px, 0);
        .inside {
            @include delay(35);
        }
    }
    &:nth-child(36) {
        @include rotate(300, -90px, 0);
        .inside {
            @include delay(36);
        }
    }
    &:nth-child(37) {
        @include rotate(306, -90px, 0);
        .inside {
            @include delay(37);
        }
    }
    &:nth-child(38) {
        @include rotate(312, -90px, 0);
        .inside {
            @include delay(38);
        }
    }
    &:nth-child(39) {
        @include rotate(318, -90px, 0);
        .inside {
            @include delay(39);
        }
    }
    &:nth-child(40) {
        @include rotate(324, -90px, 0);
        .inside {
            @include delay(40);
        }
    }
    &:nth-child(41) {
        @include rotate(330, -90px, 0);
        .inside {
            @include delay(41);
        }
    }
    &:nth-child(42) {
        @include rotate(336, -90px, 0);
        .inside {
            @include delay(42);
        }
    }
    &:nth-child(43) {
        @include rotate(342, -90px, 0);
        .inside {
            @include delay(43);
        }
    }
    &:nth-child(44) {
        @include rotate(348, -90px, 0);
        .inside {
            margin-left: -4px;
            @include delay(44);
            @include animation(rumble44, $secs, ease-in-out, 1);
            @include delay(45);
        }
    }
    &:nth-child(45) {
        @include rotate(354, -90px, 0);
        .inside {
            margin-left: 10px;
            @include animation(rumble45, $secs, ease-in-out, 1);
            @include delay(45);
        }
    }




    &:nth-child(46) {
        @include rotate(0, -90px, 0);
        .inside {
            margin-left: -20px;
            @include animation(rumble46, $secs, ease-in-out, 1);
            @include delay(46);
        }
    }
    &:nth-child(47) {
        @include rotate(6, -90px, 0);
        .inside {
            margin-left: -10px;
            @include animation(rumble47, $secs, ease-in-out, 1);
            @include delay(47);
        }
    }
    &:nth-child(48) {
        @include rotate(12, -90px, 0);
        .inside {
            margin-left: 5px;
            @include animation(rumble48, $secs, ease-in-out, 1);
            @include delay(48);
        }
    }
    &:nth-child(49) {
        @include rotate(18, -90px, 0);
        .inside {
            margin-left: -13px;
            @include animation(rumble49, $secs, ease-in-out, 1);
            @include delay(49);
        }
    }
    &:nth-child(50) {
        @include rotate(24, -90px, 0);
        .inside {
            margin-left: -30px;
            @include animation(rumble50, $secs, ease-in-out, 1);
            @include delay(50);
        }
    }
    &:nth-child(51) {
        @include rotate(30, -90px, 0);
        .inside {
            margin-left: 5px;
            @include animation(rumble51, $secs, ease-in-out, 1);
            @include delay(51);
        }
    }
    &:nth-child(52) {
        @include rotate(36, -90px, 0);
        .inside {
            margin-left: -9px;
            @include animation(rumble52, $secs, ease-in-out, 1);
            @include delay(52);
        }
    }
    &:nth-child(53) {
        @include rotate(42, -90px, 0);
        .inside {
            margin-left: 8px;
            @include animation(rumble53, $secs, ease-in-out, 1);
            @include delay(53);
        }
    }
    &:nth-child(54) {
        @include rotate(48, -90px, 0);
        .inside {
            margin-left: -12px;
            @include animation(rumble54, $secs, ease-in-out, 1);
            @include delay(54);
        }
    }
    &:nth-child(55) {
        @include rotate(54, -90px, 0);
        .inside {
            margin-left: -6px;
            @include animation(rumble55, $secs, ease-in-out, 1);
            @include delay(55);
        }
    }
    &:nth-child(56) {
        @include rotate(60, -90px, 0);
        .inside {
            margin-left: 3px;
            @include animation(rumble56, $secs, ease-in-out, 1);
            @include delay(56);
        }
    }
    &:nth-child(57) {
        @include rotate(66, -90px, 0);
        .inside {
            @include delay(57);
        }
    }
    &:nth-child(58) {
        @include rotate(72, -90px, 0);
        .inside {
            @include delay(58);
        }
    }
    &:nth-child(59) {
        @include rotate(78, -90px, 0);
        .inside {
            @include delay(59);
        }
    }
    &:nth-child(60) {
        @include rotate(84, -90px, 0);
        .inside {
            @include delay(60);
        }
    }
}

body {
  padding-top: 40px;
  background: url('http://unleash-it.co.uk/images/background.jpg') repeat;
}
            
          
!
            
              // I wanted to go with :after elements but sadly they can't be animated as vendors haven't yet picked it up. Ended up going DIV crazy to implement it, not sure if we'll use it or something similar on our new site but for now it's a fun proof of concept!
// Feel free to hit me up on Twitter @andyunleash if any questions! 
// -- ♥ Andy



//     This is how it started originally before crazy div town;
//        &:after {
//           content: "";
//           display: block;
//           color: $blue;
//           width: 20px;
//           height: 5px;
//           margin: 0;
//           padding: 0;
//           margin-left: 0;
//           background: $blue;
//        }
            
          
!
999px
Close

Asset uploading is a PRO feature.

As a PRO member, you can drag-and-drop upload files here to use as resources. Images, Libraries, JSON data... anything you want. You can even edit them anytime, like any other code on CodePen.

Go PRO

Loading ..................

Console