.back-to-top {
  position: fixed;
  right: 1.7rem;
  bottom: 2rem;
  z-index: 980;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.35s ease, transform 0.35s ease, visibility 0.35s ease, bottom 0.25s ease;
  pointer-events: none;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.back-to-top__btn {
  appearance: none;
  border: 0;
  padding: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: transparent;
  box-shadow: 0 8px 24px rgba(10, 12, 28, 0.25), 0 2px 0 0 rgba(0, 109, 111, 0.10);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
}

.back-to-top__btn:focus-visible {
  outline: 2px solid #29c8ff;
  outline-offset: 2px;
}

.back-to-top__btn:hover,
.back-to-top__btn:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(10, 12, 28, 0.35);
}

.back-to-top__btn:hover .back-to-top__bg,
.back-to-top__btn:focus-visible .back-to-top__bg {
  fill: #00585A;
}

.back-to-top__btn:active {
  transform: translateY(0) !important;
  box-shadow: 0 4px 16px rgba(10, 12, 28, 0.2) !important;
}

.back-to-top__btn:active .back-to-top__bg {
  fill: #003536 !important;
}

.back-to-top__icon {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.back-to-top__icon img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.back-to-top__bg {
  transition: fill 0.25s ease;
}

@media (prefers-reduced-motion: reduce) {
  .back-to-top {
    transition: none;
  }

  .back-to-top__btn {
    transition: none;
  }
}
