/* Shared navigation for the public homepage and overview only. */
.back-to-top,
.back-to-top-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 16px;
  font: 600 14px/1.4 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-decoration: none;
  cursor: pointer;
}

.back-to-top {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 20;
  border: 1px solid #7cbef0;
  border-radius: 999px;
  background: #102a43;
  color: #fff;
  box-shadow: 0 4px 16px #07192f26;
}

.back-to-top[hidden] {
  display: none;
}

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

.back-to-top-inline {
  border-radius: 9px;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 4px;
}

footer .back-to-top-inline {
  margin-left: auto;
}

.reader-end {
  display: flex;
  justify-content: flex-end;
  padding-bottom: 12px;
}

.back-to-top:focus-visible,
.back-to-top-inline:focus-visible {
  outline: 3px solid #168bff;
  outline-offset: 4px;
}

.steps > button.step:focus-visible {
  box-shadow: 0 5px 15px #123c651a;
}

@media (hover: hover) and (pointer: fine) {
  .back-to-top:hover {
    background: #1b405f;
  }
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .steps > button.step {
    transition: transform 140ms ease, box-shadow 140ms ease;
  }

  .steps > button.step:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 18px #123c651a;
  }
}

@media (hover: none), (pointer: coarse), (prefers-reduced-motion: reduce) {
  .button:hover,
  .steps > button.step:hover {
    transform: none;
  }
}
