Advertisement
victorumeh

web design

Feb 14th, 2022
1,117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SAS 3.85 KB | None | 0 0
  1. body {
  2.   margin: 1.5em;
  3.   font-family: "poppins", sans-serif;
  4. }
  5.  
  6. a {
  7.   text-decoration: none;
  8.   font-size: 1.3rem;
  9. }
  10.  
  11. .hero-img {
  12.   position: absolute;
  13.   top: 0;
  14.   left: 0;
  15.   background: url("../images/shoe.jpg");
  16.   width: 100%;
  17.   height: 100%;
  18.   z-index: -1;
  19.   background-size: cover;
  20.   background-position-x: 20%;
  21.   background-position-y: 20%;
  22.   animation: introLoad 2s forwards;
  23. }
  24. .logo {
  25.   color: white;
  26.   font-weight: bold;
  27. }
  28.  
  29. nav {
  30.   position: fixed;
  31.   right: 0;
  32.   top: 0;
  33.   background: white;
  34.   height: 100vh;
  35.   width: 50%;
  36.   z-index: 999;
  37.   text-transform: uppercase;
  38.   transform: translatex(100%);
  39.   transition: transform 0.5s ease-in-out;
  40.  
  41.   ul {
  42.     list-style-type: none;
  43.     padding: 0;
  44.     margin-top: 8em;
  45.  
  46.     a {
  47.       color: black;
  48.       padding: 0.75em 2em;
  49.       display: block;
  50.  
  51.       &:hover {
  52.         background: rgb(238, 234, 234);
  53.       }
  54.     }
  55.   }
  56.   .close {
  57.     float: right;
  58.     margin: 2em;
  59.     width: 2.5em;
  60.     top: 3em;
  61.   }
  62. }
  63.  
  64. header {
  65.   display: flex;
  66.   justify-content: space-between;
  67.  
  68.   svg {
  69.     width: 2.5em;
  70.     margin: -0.6em;
  71.     cursor: pointer;
  72.   }
  73. }
  74. h1 {
  75.   font-size: 3rem;
  76.   margin-top: 2em;
  77.   line-height: 3.3rem;
  78. }
  79.  
  80. .subhead {
  81.   font-size: 1.4rem;
  82. }
  83.  
  84. section.hero {
  85.   color: white;
  86.   height: 90vh;
  87.   animation: moveDown 1s ease-in-out forwards;
  88.   opacity: 0;
  89.  
  90.   .down-arrow {
  91.     stroke: white;
  92.     position: absolute;
  93.     bottom: 5em;
  94.     width: 1em;
  95.     animation: moveArrow 1s alternate-reverse infinite;
  96.  
  97.     path {
  98.       fill: white;
  99.     }
  100.   }
  101. }
  102.  
  103. .more-info {
  104.   img {
  105.     width: 100%;
  106.     object-fit: cover;
  107.     height: 11em;
  108.   }
  109.   .title {
  110.     font-weight: bold;
  111.     font-size: 1.25;
  112.   }
  113.   .desc {
  114.     line-height: 1.5rem;
  115.   }
  116. }
  117.  
  118. .open-nav {
  119.   transform: translateX(0);
  120. }
  121.  
  122. @media only screen and (min-width: 680px) {
  123.   body {
  124.     margin: 1.5em 5em;
  125.     font-family: "poppins", sans-serif;
  126.   }
  127. }
  128.  
  129. @media only screen and (min-width: 920px) {
  130.   .menu {
  131.     display: none;
  132.   }
  133.   nav {
  134.     transform: translatex(0);
  135.     position: unset;
  136.     display: block;
  137.     width: auto;
  138.     height: auto;
  139.     background: none;
  140.  
  141.     svg.close {
  142.       display: none;
  143.     }
  144.  
  145.     ul {
  146.       display: flex;
  147.       margin: 0;
  148.  
  149.       a {
  150.         color: white;
  151.         padding: 0.5em 1.5em;
  152.         font-size: 0.9rem;
  153.  
  154.         &:hover {
  155.           background: none;
  156.           text-decoration: underline;
  157.         }
  158.       }
  159.     }
  160.   }
  161.   .hero-img {
  162.     left: unset;
  163.     right: 0;
  164.     width: 50%;
  165.     height: 42em;
  166.   }
  167.  
  168.   .logo {
  169.     color: black;
  170.  
  171.     span {
  172.       color: red;
  173.     }
  174.   }
  175.   section.hero {
  176.     color: black;
  177.     height: auto;
  178.     width: 40%;
  179.     margin-bottom: 8em;
  180.  
  181.     svg.down-arrow {
  182.       stroke: black;
  183.       position: unset;
  184.       padding-top: 2em;
  185.  
  186.       path {
  187.         fill: black;
  188.       }
  189.     }
  190.   }
  191.   .feature {
  192.     display: grid;
  193.     grid-template-columns: repeat(2, auto);
  194.     gap: 3em;
  195.     margin-bottom: 8em;
  196.  
  197.     img {
  198.       width: 25em;
  199.     }
  200.  
  201.     .content {
  202.       text-align: right;
  203.       width: 25em;
  204.     }
  205.   }
  206.   .feature.left {
  207.     grid-template-areas: "left right";
  208.  
  209.     img {
  210.       grid-area: left;
  211.     }
  212.  
  213.     .content {
  214.       text-align: left;
  215.       width: 25em;
  216.       justify-self: left;
  217.     }
  218.   }
  219. }
  220.  
  221. @media only screen and (min-width: 920px) {
  222.   .container {
  223.     width: 1200px;
  224.     margin: 0 auto;
  225.   }
  226.   .feature {
  227.     gap: 0;
  228.   }
  229. }
  230. @keyframes introLoad {
  231.   from {
  232.     clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
  233.   }
  234.   to {
  235.     clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  236.   }
  237. }
  238.  
  239. @keyframes moveArrow {
  240.   from {
  241.     transform: translateY(-30px);
  242.   }
  243.   to {
  244.     transform: translateY(0);
  245.   }
  246. }
  247.  
  248. @keyframes moveDown {
  249.   from {
  250.     transform: translateY(-100px);
  251.   }
  252.   to {
  253.     transform: translateY(0);
  254.     opacity: 1;
  255.   }
  256. }
  257.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement