پیش‌نمایش زنده
کد HTML
<button class="button">Button</button>
کد CSS
.button {
  background: linear-gradient(145deg, #6f6f6f, #434343);
  border: 2px solid #555;
  border-radius: 12px;
  box-shadow:
    4px 4px 8px rgba(0, 0, 0, 0.2),
    -4px -4px 8px rgba(255, 255, 255, 0.5);
  color: #fff;
  cursor: pointer;
  font-size: 16px;
  font-weight: bold;
  padding: 12px 24px;
  text-align: center;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 300%;
  height: 300%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.2) 10%,
    transparent 30%
  );
  transition: transform 0.4s ease;
  transform: translate(-50%, -50%) scale(0);
  z-index: 0;
}

.button:hover::before {
  transform: translate(-50%, -50%) scale(1);
}

.button:hover {
  background: linear-gradient(145deg, #434343, #6f6f6f);
  border: 2px solid #888;
  box-shadow:
    8px 8px 16px rgba(0, 0, 0, 0.3),
    -8px -8px 16px rgba(255, 255, 255, 0.6);
  transform: rotate(3deg);
}

.button span {
  position: relative;
  z-index: 1;
}
نوع: button
تاریخ ایجاد: 2026/06/05
آخرین بروزرسانی: 2026/06/05