/* Site-wide back-to-top control; positioned above the existing Chaty widget. */
.woao-back-to-top {
  position: fixed;
  z-index: 1098;
  right: max(32px, env(safe-area-inset-right));
  bottom: calc(96px + env(safe-area-inset-bottom));
  display: grid;
  width: 48px;
  height: 48px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 50%;
  background: #0a63a8;
  box-shadow: 0 6px 18px rgba(8, 79, 135, 0.22);
  color: #fff;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 160ms ease, visibility 160ms ease, transform 160ms ease, background-color 160ms ease;
}

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

.woao-back-to-top:hover {
  background: #084f87;
  color: #fff;
}

.woao-back-to-top:focus,
.woao-back-to-top:focus-visible {
  outline: 3px solid #79c8f2;
  outline-offset: 3px;
}

.woao-back-to-top svg {
  display: block;
}

@media (max-width: 980px) {
  .woao-back-to-top {
    right: max(33px, env(safe-area-inset-right));
    bottom: calc(88px + env(safe-area-inset-bottom));
    width: 46px;
    height: 46px;
  }
}

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