Advertisement
Patrikrizek

lesson-3-banner-in-class

Nov 10th, 2022
651
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 2.61 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4.     <meta charset="UTF-8">
  5.     <meta http-equiv="X-UA-Compatible" content="IE=edge">
  6.     <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7.     <title>Banner</title>
  8.  
  9.     <style>
  10.         h1 {
  11.             font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  12.             line-height: 0.3em;
  13.             color: white;
  14.         }
  15.  
  16.         p {
  17.             font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  18.             font-size: 1em;
  19.             line-height: 1.3em;
  20.             color: white;
  21.         }
  22.  
  23.         img {
  24.             height: 100px;
  25.         }
  26.  
  27.         button {
  28.             font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  29.             background-color: transparent;
  30.             color: white;
  31.             border-style: solid;
  32.             border-color: white;
  33.             border-radius: 10px;
  34.             padding: 6px 24px 6px 24px;
  35.             margin-bottom: 10px;
  36.         }
  37.  
  38.         button:hover {
  39.             font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  40.             background-color: #fff;
  41.             color: #000;
  42.             border-style: solid;
  43.             border-color: #fff;
  44.             border-radius: 10px;
  45.             padding: 6px 24px;
  46.             margin-bottom: 10px;
  47.             cursor: pointer;
  48.         }
  49.  
  50.         /* Class */
  51.         .logo {
  52.             padding-right: 10px;
  53.         }
  54.  
  55.         .banner {
  56.             display: flex;
  57.             justify-content: center;
  58.             align-items: center;
  59.             margin: 10px;
  60.             padding: 10px;
  61.             border-radius: 20px;
  62.             height: 120px;
  63.             background: linear-gradient(-45deg, #e79e00, #ff0000, #ffe96c, #ff0000);
  64.             background-size: 200% 200%;
  65.             animation: gradient 15s ease infinite;
  66.         }
  67.  
  68.         @keyframes gradient {
  69.             0% { background-position: 0% 50%; }
  70.  
  71.             50% { background-position: 100% 50%; }
  72.  
  73.             100% { background-position: 0% 50%; }
  74.         }
  75.     </style>
  76.  
  77. </head>
  78. <body>
  79.     <div class="banner" onclick="myFunction()">
  80.         <script>
  81.             function myFunction() {
  82.                 alert("Thanks a lot!");
  83.             }
  84.         </script>
  85.  
  86.         <div class="logo">
  87.             <img src="https://picsum.photo/200" alt="random image">
  88.         </div>
  89.  
  90.         <div class="content">
  91.             <h1>Maiona Coding Course</h1>
  92.             <p>Coding is a creative process and we believe anyone can learn to code.</p>
  93.             <button>Sign up now!</button>
  94.         </div>
  95.     </div>
  96. </body>
  97. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement