پیش‌نمایش زنده
کد HTML
<div class="container">
  <button class="btn">GO</button>
</div>
کد CSS
.container {
  /* background: linear-gradient(180deg, rgb(223, 223, 223), rgb(255, 255, 255)); */
  height: 100%;
  width: 100%;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: -1;
}

.btn {
  position: relative;
  background: linear-gradient(#ffffff 30%, #ffffff 30%, #d6d6d6);
  width: 8rem;
  height: 8rem;
  border-radius: 10rem;
  border: 0.15rem solid #ffffff;
  transition: 0.3s;
  box-shadow: 0 0.3rem 0.3rem rgb(18 18 18 / 35%);
  font-size: 2rem;
  color: grey;
  cursor: pointer;
}

.btn::before {
  content: "";
  width: 125%;
  height: 125%;
  background: rgb(224, 224, 224);
  box-shadow: 0 0.2rem 0.2rem inset #808080;
  position: absolute;
  left: -12%;
  top: -12%;
  z-index: -1;
  border-radius: inherit;
  transition: 0.3s;
}

.btn:focus {
  box-shadow:
    0 5px 3px rgb(18 18 18 / 35%),
    0 5px 25px rgba(2, 220, 89, 0.777);
  background: linear-gradient(0deg, #ffffff 30%, #ffffff 30%, #d6d6d6);
}
.btn:focus::before {
  box-shadow: 0 0.2rem 0.2rem inset #808080;
}
نوع: button
تاریخ ایجاد: 2026/06/05
آخرین بروزرسانی: 2026/06/05