JSFiddle - React, Tailwind, and code Playground
by davidxmartins
HTML
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Trapezoid Buttons with Rustic Texture</title>
<style>
body {
font-family: Arial, sans-serif;
background-color: #f5f5dc; /* Light beige background for a rustic feel */
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}
.menu {
display: flex;
gap: 20px;
}
.button {
width: 150px;
height: 70px;
background-color: #8b4513; /* Saddle brown color */
color: white;
text-align: center;
line-height: 70px;
font-size: 18px;
font-weight: bold;
text-decoration: none;
position: relative;
display: inline-block;
clip-path: polygon(10% 0%, 90% 0%, 100% 100%, 0% 100%);
background-image: url('path/to/texture.jpg'); /* Add your texture image here */
background-size: cover;
background-blend-mode: multiply;
transition: transform 0.3s;
}
.button:hover {
transform: scale(1.1);
}
</style>
</head>
<body>
<div class="menu">
<a href="#" class="button">Button 1</a>
<a href="#" class="button">Button 2</a>
<a href="#" class="button">Button 3</a>
<a href="#" class="button">Button 3</a>
<a href="#" class="button">Button 3</a>
</div>
</body>
</html>