پیش‌نمایش زنده
کد HTML
<button class="luxury-button">
  <span class="button-text">Luxury Button</span>
  <span class="hover-bg"></span>
</button>
کد CSS
body {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  background: linear-gradient(to right, #4a90e2, #9013fe);
}

.luxury-button {
  position: relative;
  padding: 12px 24px;
  background: transparent;
  border: 2px solid transparent;
  border-radius: 8px;
  color: white;
  font-size: 1.25rem;
  font-weight: bold;
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.3s ease-in-out;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.luxury-button:hover {
  border-color: #f39c12;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
  transform: scale(1.05);
}

.button-text {
  position: relative;
  z-index: 2;
}

.hover-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 8px;
  background: linear-gradient(
    to right,
    #f39c12,
    #e74c3c
  ); /* Gradient for hover effect */
  transform: scale(0);
  transition: transform 0.3s ease-in-out;
  z-index: 1;
}

.luxury-button:hover .hover-bg {
  transform: scale(1);
}
نوع: button
تاریخ ایجاد: 2026/06/05
آخرین بروزرسانی: 2026/06/05