.back-to-top {
  position: fixed;
  right: 32px;
  bottom: 32px;
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 6px 20px rgba(30, 91, 255, 0.18);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  z-index: 1000;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.3s ease,
              background-color 0.3s ease;
}

.back-to-top:hover,
.back-to-top.is-hovering {
  transform: translateY(-4px) scale(1.08);
  background: var(--color-primary, #1E5BFF);
  box-shadow: 0 10px 28px rgba(30, 91, 255, 0.35);
}

.back-to-top:active {
  transform: translateY(-2px) scale(1.02);
}

/* 进度环 */
.progress-ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.progress-ring-bg {
  fill: none;
  stroke: rgba(30, 91, 255, 0.12);
  stroke-width: 2.5;
}

.progress-ring-fg {
  fill: none;
  stroke: var(--color-primary, #1E5BFF);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 138.23;
  transition: stroke-dashoffset 0.15s ease;
}

.back-to-top:hover .progress-ring-fg,
.back-to-top.is-hovering .progress-ring-fg {
  stroke: #ffffff;
}

.back-to-top:hover .progress-ring-bg,
.back-to-top.is-hovering .progress-ring-bg {
  stroke: rgba(255, 255, 255, 0.25);
}

/* 箭头图标 */
.backtop-arrow {
  width: 22px;
  height: 22px;
  color: var(--color-primary, #1E5BFF);
  transition: color 0.3s ease, transform 0.3s ease;
  z-index: 1;
}

.back-to-top:hover .backtop-arrow,
.back-to-top.is-hovering .backtop-arrow {
  color: #ffffff;
  transform: translateY(-2px);
}

/* 出现/消失动画 */
.backtop-fade-enter-active,
.backtop-fade-leave-active {
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.backtop-fade-enter-from,
.backtop-fade-leave-to {
  opacity: 0;
  transform: translateY(20px) scale(0.6);
}

/* 响应式：移动端缩小 */
@media (max-width: 768px) {
  .back-to-top {
    right: 16px;
    bottom: 16px;
    width: 46px;
    height: 46px;
  }

  .backtop-arrow {
    width: 20px;
    height: 20px;
  }
}
