CSS Button with Transitions

Size
2,310 Kb
Views
28,336

How do I make an css button with transitions?

Practice building buttons with "animation" in CSS.. What is a css button with transitions? How do you make a css button with transitions? This script and codes were developed by Vanessa Vevoda on 12 September 2022, Monday.

CSS Button with Transitions Previews

CSS Button with Transitions - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>CSS Button with Transitions</title> <link rel="stylesheet" href="css/style.css">
</head>
<body> <section> <a class="a_demo_btn">Button 1</a> <a href="#" class="a_demo_btn--2">Button</a> <a href="#" class="a_demo_btn--3">Button </a>
</section>
</body>
</html>

CSS Button with Transitions - Script Codes CSS Codes

section { margin: 0 auto; padding: 3em; text-align: center; border:1px solid red; width:50%; height:auto; overflow: hidden;
}
a {margin:20px;}
.a_demo_btn {	background-color:#4b3f39;	font-family: 'Open Sans', sans-serif;	font-size:12px;	text-decoration:none;	color:#fff;	position:relative;	padding:10px 20px;	background-image: linear-gradient(bottom, rgb(62,51,46) 0%, rgb(101,86,78) 100%);	border-radius: 5px;	webkit-box-shadow: inset 0px 1px 0px #9e8d84, 0px 5px 0px 0px #322620, 0px 10px 5px #999; box-shadow: inset 0px 1px 0px #9e8d84, 0px 5px 0px 0px #322620, 0px 10px 5px #999;
}
.a_demo_btn:active {	top:3px;	background-image: linear-gradient(bottom, rgb(62,51,46) 100%, rgb(101,86,78) 0%);	box-shadow: inset 0px 1px 0px #9e8d84, 0px 2px 0px 0px #322620, 0px 5px 3px #999;
}
.a_demo_btn--2 { background-color:#b77777; /* Needed for IEs */ font-family: 'Open Sans', sans-serif; font-size: 1em; text-decoration:none; text-shadow: 2px; padding: 20px 40px; color: #905c5c; position: relative; /*top:0px;*/ transition: top 0.1s ease-in-out; border-radius: 6px; border: 1px solid #cba2a2; background-image: linear-gradient(to bottom, #eadada 0%, #e5cccc 70%); box-shadow: inset 0px 0px 0px #905c5c , 0px 0px 0px 0px #cba2a2, 0px 7px 6px 0px #eadada; /*box-shadow: [offset-x] [offset-y] [blur radius] [optional spread radius] [color];*/
}
.a_demo_btn--2:active { color: #805151; top: 4px; background-image: linear-gradient(to top, #f3e4e4 0%, #e5cccc 85%); box-shadow: inset 0px 0px 0px #905c5c , 0px 3px 0px 0px #905c5c, 0px 8px 4px 1px #eadada;
}
.a_demo_btn--3 { background-color:#ca8888; /* Needed for IEs */ font-family: 'Open Sans', sans-serif; font-size: 1em; text-decoration:none; text-shadow: 2px; padding: 15px 25px; color: #fff; position: relative; /*top:0px;*/ transition: top 0.4s ease-in-out; border-radius: 6px; border: 1px solid #a26f6f; background-image: linear-gradient(to bottom, #ca8888 0%, #d59494 90%); box-shadow: inset 0px 0px 0px #905c5c , 0px 5px 0px 0px #905c5c, 0px 12px 6px 0px #d5bdbd; /*box-shadow: [offset-x] [offset-y] [blur radius] [optional spread radius] [color];*/
}
.a_demo_btn--3:active { color: #805151; top: 2px; background-image: linear-gradient(to top, #f3e4e4 0%, #e5cccc 85%); box-shadow: inset 0px 0px 0px #905c5c , 0px 2px 0px 0px #905c5c, 0px 8px 4px 1px #eadada;
}
.a_demo_btn--3::after { position: relative; margin-left:5px; content:"→"; padding:3px 6px 1px 6px; border: 1px solid #ca8888; border-radius: 50%; background-color: #ca8888; color: #fff; box-shadow: inset 0px 2px 1px 1px #e5cccc, 1px 1px 1px 0px #905c5c, 0px 1px 0px 1px #b77777;
}
.a_demo_btn--3:active::after { top:-2px; box-shadow: inset 0px 2px 1px 1px #e5cccc, 1px 1px 1px 0px #aaaaaa, 0px 2px 1px 0px #aaaaaa;
}
/* ///// QUERIE R US @ 66ems ///// */
@media screen and (max-width: 66em) { a { margin: 10px auto; display: block; }
} 
CSS Button with Transitions - Script Codes
CSS Button with Transitions - Script Codes
Home Page Home
Developer Vanessa Vevoda
Username vanessav
Uploaded September 12, 2022
Rating 3
Size 2,310 Kb
Views 28,336
Do you need developer help for CSS Button with Transitions?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Vanessa Vevoda (vanessav) Script Codes
Create amazing captions with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!