Advertisement
Guest User

Untitled

a guest
Feb 23rd, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 4.49 KB | None | 0 0
  1. @import "http://fonts.googleapis.com/css?family=Dosis:300,400,500,600,700";
  2.  
  3. // Variables
  4. $bg-body: #f9f9f9;
  5.  
  6. $red: #ee4d4d;
  7. $blue: #2b2e48;
  8. $primary-color: $red;
  9. $secondary-color: $blue;
  10.  
  11.  
  12. // Typography
  13. $base-font: helvetica, arial, tahoma, verdana;
  14. $base-font-title: "Dosis", arial, tahoma, verdana;
  15.  
  16. $base-font-color: #726f77;
  17.  
  18. // Timeline
  19. $timeline-color: $primary-color;
  20.  
  21.  
  22. // Mixins and Placeholders
  23. %clearfix {
  24.     &:after, &:before {
  25.         content: '';
  26.         display: block;
  27.         width: 100%;
  28.         clear: both;
  29.     }
  30. }
  31.  
  32. @mixin prefix($prop, $val) {
  33.     @each $prefix in '-webkit-', '-moz-', '-ms-', '' {
  34.         #{$prefix}#{$prop}: $val;
  35.     }
  36. }
  37. *, *:before, *:after {
  38.     box-sizing: border-box;
  39.     -webkit-box-sizing: border-box;
  40.     -moz-box-sizing: border-box;
  41. }
  42.  
  43. body, html {
  44.     height: 100%;
  45. }
  46. body {
  47.     background: $bg-body;
  48.     background-size: cover;
  49.     margin: 0;
  50.     padding: 0;
  51.     font-family: $base-font;
  52.     line-height: 20px;
  53.     font-size: 14px;
  54.     color: $base-font-color;
  55. }
  56.  
  57. img {max-width: 100%;}
  58.  
  59. a {
  60.     text-decoration: none;
  61. }
  62.  
  63. .container {
  64.     max-width: 1100px;
  65.     margin: 0 auto;
  66. }
  67.  
  68. h1, h2, h3, h4 {
  69.   font:{
  70.         family: $base-font-title;
  71.         weight: 500;
  72.     }
  73. }
  74.  
  75. .project-name {
  76.   text-align: center;
  77.   padding: 10px 0;
  78. }
  79.  
  80. // Header
  81. header {   
  82.     background: $secondary-color;
  83.     padding: 10px;
  84.     @include prefix(box-shadow, 0 3px 3px rgba(0,0,0,0.05));
  85.     @extend %clearfix;
  86.  
  87.     .logo {
  88.         color: $primary-color;
  89.         float: left;
  90.         font:{
  91.             family: $base-font-title;
  92.             size: 22px;
  93.             weight: 500;
  94.         }
  95.        
  96.         > span {
  97.             color: lighten($primary-color, 20%);
  98.             font-weight: 300;
  99.         }
  100.     }
  101.  
  102.     .social {
  103.         float: right;
  104.         .btn {
  105.             font-family: "Dosis";
  106.             font-size: 14px;
  107.             margin: 10px 5px;
  108.         }
  109.     }
  110. }
  111.  
  112.  
  113. // Timeline
  114. #timeline {
  115.     width: 100%;
  116.   margin: 30px auto;
  117.     position: relative;
  118.   padding: 0 10px;
  119.     @include prefix(transition, all .4s ease);
  120.  
  121.     &:before {
  122.        
  123.          
  124.                  content: "";
  125.               position: absolute;
  126.               left: 100px;
  127.               bottom: 0;
  128.               right: 0;
  129.               background-repeat: repeat-y;
  130.               height: 10px;
  131.               background-size: 20px 20px;
  132.               background-image: radial-gradient(circle at -5px 10px, transparent 12px, aquamarine 13px);
  133.         content:"";
  134.         width: 150px;
  135.         height: 100%;
  136.         left: 50%;
  137.         top: 0;
  138.         position: absolute;
  139.     }
  140.  
  141.     &:after {
  142.         content: "";
  143.         clear: both;
  144.         display: table;
  145.         width: 100%;
  146.     }
  147.    
  148.     .timeline-item {
  149.         margin-bottom: 50px;
  150.         position: relative;
  151.         @extend %clearfix;
  152.  
  153.         .timeline-icon {
  154.             background: $timeline-color;
  155.             width: 50px;
  156.             height: 50px;
  157.             position: absolute;
  158.             top: 0;
  159.             left: 50%;
  160.             overflow: hidden;
  161.             margin-left: -23px;
  162.             @include prefix(border-radius, 50%);
  163.  
  164.             svg {
  165.                 position: relative;
  166.                 top: 14px;
  167.                 left: 14px;
  168.             }
  169.         }
  170.  
  171.         .timeline-content {
  172.             width: 45%;
  173.             background: #fff;
  174.             padding: 20px;
  175.             @include prefix(box-shadow, 0 3px 0 rgba(0,0,0,0.1));
  176.             @include prefix(border-radius, 5px);
  177.             @include prefix(transition, all .3s ease);
  178.  
  179.             h2 {
  180.                 padding: 15px;
  181.                 background: $timeline-color;
  182.                 color: #fff;
  183.                 margin: -20px -20px 0 -20px;
  184.                 font-weight: 300;
  185.                 @include prefix(border-radius, 3px 3px 0 0);
  186.             }
  187.  
  188.             &:before {
  189.  
  190.                
  191.                
  192.                 border-top: 7px solid transparent;
  193.                 border-bottom: 7px solid transparent;
  194.                 border-left:7px solid $timeline-color;
  195.             }
  196.  
  197.             &.right {
  198.                 float: right;
  199.  
  200.                 &:before {
  201.                     content: '';
  202.                     right: 45%;
  203.                     left: inherit;
  204.                     border-left: 0;
  205.                     border-right: 7px solid $timeline-color;
  206.                 }
  207.             }
  208.         }
  209.     }
  210. }
  211.  
  212. // Buttons
  213. .btn {
  214.     padding: 5px 15px;
  215.     text-decoration: none;
  216.     background: transparent;
  217.     border: 2px solid lighten($primary-color, 10%);
  218.     color: lighten($primary-color, 10%);
  219.     display: inline-block;
  220.     position: relative;
  221.     text-transform: uppercase;
  222.     font-size: 30px;
  223.     @include prefix(border-radius, 5px);
  224.     @include prefix(transition, background .3s ease);
  225.     @include prefix(box-shadow, 2px 2px 0 lighten($primary-color, 10%));
  226.  
  227.     &:hover {
  228.         box-shadow: none ;
  229.         top: 2px;
  230.         left: 2px;
  231.         @include prefix(box-shadow, 2px 2px 0 transparent);
  232.     }
  233. }
  234.  
  235. @media screen and (max-width: 768px) {
  236.     #timeline {
  237.         margin: 30px;
  238.         padding: 0px;
  239.     width: 90%;
  240.         &:before {
  241.             left: 0;
  242.         }
  243.        
  244.         .timeline-item {
  245.             .timeline-content {
  246.                 width: 90%;
  247.                 float: right;
  248.                
  249.                 &:before, &.right:before {
  250.                     left: 10%;
  251.                     margin-left: -6px;
  252.                     border-left: 0;
  253.                     border-right: 7px solid $timeline-color;
  254.                 }
  255.             }
  256.  
  257.             .timeline-icon {
  258.                 left: 0;
  259.             }
  260.         }
  261.     }
  262. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement