.ni-back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 80;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(62, 52, 54, .22);
  border-radius: 50%;
  background: rgba(253, 252, 251, .96);
  box-shadow: 0 12px 30px rgba(62, 52, 54, .16);
  color: #3e3436;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(12px);
  transition:
    opacity .22s ease,
    visibility .22s ease,
    transform .22s ease,
    color .18s ease,
    background-color .18s ease,
    border-color .18s ease;
  -webkit-tap-highlight-color: transparent;
}

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

.ni-back-to-top:hover {
  border-color: #3e3436;
  background: #3e3436;
  color: #fff;
}

.ni-back-to-top:focus-visible {
  outline: 3px solid rgba(119, 183, 95, .42);
  outline-offset: 3px;
}

.ni-back-to-top svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

@media (max-width: 576px) {
  .ni-back-to-top {
    right: 16px;
    bottom: 18px;
    width: 44px;
    height: 44px;
  }

  .ni-back-to-top svg {
    width: 18px;
    height: 18px;
  }
}

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