<body>
<h1>This is a CSS styled Heading</h1>
<p id="rcorners">Rounded corners!</p>
<button class="button">HOVER OVER</button>
<div></div>
</body>
body {
background-color: #d0e4fe;
}
h1 {
color: teal;
text-align: center;
}
p {
font-family: "Times New Roman";
font-size: 20px;
color:#009688;
}
#rcorners {
border-radius: 10px;
color: white;
background: #E91E63;
padding: 10px;
width: 150px;
height: 25px;
}
.button {
background-color: white;
color: black;
border: 2px solid #CDDC39;
padding: 16px 32px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 16px;
margin: 4px 2px;
-webkit-transition-duration: 0.4s; /* Safari */
transition-duration: 0.4s;
cursor: pointer;
box-shadow: 0 8px 16px 0 rgba(0,0,0,0.2), 0 6px 20px 0 rgba(0,0,0,0.19);
}
.button:hover {
background-color: #CDDC39;
color: white;
}
div {
width: 100px;
height: 100px;
background-color: red;
position: relative;
-webkit-animation-name: example; /* Chrome, Safari, Opera */
-webkit-animation-duration: 4s; /* Chrome, Safari, Opera */
-webkit-animation-iteration-count: 3; /* Chrome, Safari, Opera */
-webkit-animation-direction: alternate; /* Chrome, Safari, Opera */
animation-name: example;
animation-duration: 4s;
animation-iteration-count: 3;
animation-direction: alternate;
}
/* Chrome, Safari, Opera */
@-webkit-keyframes example {
0% {background-color:red; left:0px; top:0px;}
25% {background-color:yellow; left:200px; top:0px;}
50% {background-color:blue; left:200px; top:200px;}
75% {background-color:green; left:0px; top:200px;}
100% {background-color:red; left:0px; top:0px;}
}
/* Standard syntax */
@keyframes example {
0% {background-color:red; left:0px; top:0px;}
25% {background-color:yellow; left:200px; top:0px;}
50% {background-color:blue; left:200px; top:200px;}
75% {background-color:green; left:0px; top:200px;}
100% {background-color:red; left:0px; top:0px;}
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.