.back-to-top {
  position: fixed;
  right: calc(18px + env(safe-area-inset-right, 0px));
  bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  z-index: 8;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid #ddd;
  border-radius: 50%;
  background: #f5f5f5;
  color: #222;
  box-shadow: 0 2px 8px #0001;
}
.back-to-top:hover { background: #e9e9e9; }
.back-to-top:focus-visible { outline: 2px solid #222; outline-offset: 3px; }
.back-to-top[hidden], body:has(dialog[open]) .back-to-top { display: none; }

@media (max-width: 767px) {
  .back-to-top { width: 38px; height: 38px; }
  .back-to-top svg { width: 16px; height: 16px; }
}

button[data-centered-arrow] {
  padding: 0 !important;
  place-items: center;
  align-content: center;
  line-height: 1;
}
button[data-centered-arrow] > svg {
  display: block;
  width: 1em;
  height: 1em;
  margin-inline: auto;
  pointer-events: none;
}
