Advertisement
grozdana

Untitled

Sep 28th, 2018
375
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.86 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Positioning elements</title>
  5. <link rel="stylesheet" type="text/css" href="style/style.css">
  6. </head>
  7. <body>
  8. <header id="showcase">
  9. <h1>Welcome to my site</h1>
  10. </header>
  11. <div id="content" class="container">
  12. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
  13. tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
  14. quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
  15. consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
  16. cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
  17. proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
  18. </div>
  19. <a href="#" class="btn">Read More</a>
  20. </body>
  21. </html>
  22.  
  23. *{
  24. margin: 0;
  25. padding: 0;
  26. }
  27. body{
  28.  
  29. font-family: Arial, Helvetica, sans-serif;
  30. background-color: #12475f;
  31. color: #fff;
  32. line-height: 1.6;
  33. text-align: center;
  34. }
  35. .container{
  36. max-width: 960px;
  37. margin: auto;
  38. padding: 0 30px;
  39. }
  40. #showcase{
  41. height: 300px;
  42. }
  43. #showcase h1{
  44. font-size: 50px;
  45. line-height: 1.3;
  46. position: relative;
  47. animation-name: heading;
  48. animation-duration: 3s;
  49. animation-fill-mode: forwards;
  50.  
  51. }
  52. @keyframes heading{
  53. 0% {top: -50px;}
  54. 100% {top:200px;}
  55.  
  56.  
  57. }
  58. #content{
  59. position: relative;
  60. animation-name: content;
  61. animation-duration: 3s;
  62. animation-fill-mode: forwards;
  63.  
  64. }
  65. @keyframes content {
  66. 0% {left: -1000px;}
  67. 100% {left: 0;}
  68.  
  69.  
  70. }
  71. .btn{
  72. display: inline-block;
  73. color:#fff;
  74. text-decoration: none;
  75. padding: 1rem 2rem;
  76. border:#fff 1px solid;
  77. margin-top: 40px;
  78. opacity: 0;
  79. animation-name: btn;
  80. animation-duration: 3s;
  81. animation-delay: 3s;
  82. animation-fill-mode: forwards;
  83.  
  84. transition-property: transform;
  85. transition-duration: 1s;
  86. }
  87. .btn:hover{
  88. transform: rotateY(180deg);
  89. }
  90. @keyframes btn{
  91. 0% {opacity:0}
  92. 100%{opacity: 1}
  93.  
  94. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement