/* Scroll to Top */
.scroll-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: none;
  border-radius: 50%;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  opacity: 0;
  visibility: hidden;
  cursor: pointer;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 900;
}

.scroll-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-top i {
  font-size: 1.5rem;
  transition: transform 0.3s;
}

/* Hover effects */
.scroll-top:hover {
  width: 140px;
  border-radius: 50px;
  background-color: rgb(181, 160, 255);
  align-items: center;
}

/* Move icon upwards */
.scroll-top:hover i {
  transform: translateY(-200%);
}

/* Add tooltip text */
.scroll-top::before {
  position: absolute;
  bottom: -20px;
  content: "Back to Top";
  color: white;
  font-size: 0px;
  transition: font-size 0.3s ease, bottom 0.3s ease;
}

.scroll-top:hover::before {
  font-size: 13px;
  bottom: unset;
}
