Advertisement
viktormorales

SCSS + COMPASS: animated intro

Apr 24th, 2016
141
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 1.71 KB | None | 0 0
  1. #presentation {
  2.     color: #fff;
  3.     text-shadow: 0 0 10px #fff;
  4.  
  5.     a {
  6.         text-shadow: 0 !important;
  7.         color: #fff;
  8.     }
  9.    
  10.     .background {
  11.         position: fixed;
  12.         background-color: #222;
  13.         top: 0;
  14.         left: 0;
  15.         right: 0;
  16.         bottom: 0;
  17.         z-index:999;
  18.         @include animation-delay(9s);
  19.         @include animation-duration(2.5s);
  20.         @include animation-iteration-count(1);
  21.         @include animation-fill-mode(both);
  22.         @include animation-name(last);
  23.     }
  24.    
  25.     > div {
  26.         position: absolute;
  27.         top: 50%;
  28.         left: 10%;
  29.         right: 10%;
  30.         text-align: center;
  31.         z-index: 999;
  32.         font-size: 40px;
  33.        
  34.         &.first {  
  35.             @include animation-delay(1s);
  36.             @include animation-duration(2.5s);
  37.             @include animation-iteration-count(1);
  38.             @include animation-fill-mode(both);
  39.             @include animation-name(scale);
  40.         }
  41.         &.second {
  42.             @include animation-delay(3s);
  43.             @include animation-duration(2.5s);
  44.             @include animation-iteration-count(1);
  45.             @include animation-fill-mode(both);
  46.             @include animation-name(scale);
  47.         }
  48.         &.third {
  49.             @include animation-delay(5s);
  50.             @include animation-duration(2.5s);
  51.             @include animation-iteration-count(1);
  52.             @include animation-fill-mode(both);
  53.             @include animation-name(scale);
  54.         }
  55.         &.fourth {
  56.             @include animation-delay(7s);
  57.             @include animation-duration(2.5s);
  58.             @include animation-iteration-count(1);
  59.             @include animation-fill-mode(both);
  60.             @include animation-name(scale);
  61.         }
  62.     }
  63. }
  64. @include keyframes(scale) {
  65.     0% { transform: scale(0); }
  66.     10% { transform: scale(1.2); }
  67.     20% { transform: scale(1); }
  68.     70% { transform: scale(1.2); }
  69.     100% { transform: scale(0); }
  70. }
  71. @include keyframes(last) {
  72.     0% { opacity: 1; }
  73.     10% { transform: scaleY(0); }
  74.     100% { opacity: 0; transform: scaleY(0); }
  75. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement