/* Team Orbit Animation Styles */

.team-orbit-container {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 700px;
  margin: auto;
  overflow: visible;
}

@media (max-width: 1399px) {
  .team-orbit-container {
    display: none;
  }
}

.section-wrapper {
  position: relative;
  justify-content: center;
  display: flex;
  height: 700px;
  width: 700px;
  margin: auto;
  place-items: center;
}

/* Circle Background with Animation */
.slider-thumb {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 500px;
  height: 500px;
  z-index: 1;
}

.slider-thumb::before {
  position: absolute;
  content: "";
  width: 100%;
  height: 100%;
  background: linear-gradient(0deg, #384bff 10%, #b42af3 125.82%);
  border-radius: 62% 47% 82% 35% / 45% 45% 80% 66%;
  will-change: border-radius, transform, opacity;
  animation: sliderShape 10s ease-in-out infinite;
  display: block;
  z-index: 1;
  opacity: 0.3;
  filter: blur(5px);
}

@keyframes sliderShape {
  0%, 100% {
    border-radius: 42% 58% 70% 30% / 45% 45% 55% 55%;
    transform: translate3d(0, 0, 0) rotateZ(0.01deg);
  }
  34% {
    border-radius: 70% 30% 46% 54% / 30% 29% 71% 70%;
    transform: translate3d(0, 5px, 0) rotateZ(0.01deg);
  }
  50% {
    transform: translate3d(0, 0, 0) rotateZ(0.01deg);
  }
  67% {
    border-radius: 100% 60% 60% 100% / 100% 100% 60% 60%;
    transform: translate3d(0, -3px, 0) rotateZ(0.01deg);
  }
}

/* Team Cards Container */
.team-cards {
  position: relative;
  list-style: none;
  padding: 0;
  margin: 0;
  z-index: 3;
  width: 100%;
  height: 100%;
}

/* Individual Team Card */
.team-card {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 160px;
  height: 160px;
  margin: -80px 0 0 -80px;
  z-index: 2;
  --angle: calc((360deg / var(--nth-siblings)) * var(--nth-child));
  --radius: 220px;
  transform: 
    rotate(var(--angle)) 
    translate(var(--radius)) 
    rotate(calc(-1 * var(--angle)));
  animation: orbit 35s linear infinite;
  animation-delay: calc(-35s / var(--nth-siblings) * var(--nth-child));
}

@keyframes orbit {
  from {
    transform: 
      rotate(var(--angle)) 
      translate(var(--radius)) 
      rotate(calc(-1 * var(--angle)));
  }
  to {
    transform: 
      rotate(calc(var(--angle) + 360deg)) 
      translate(var(--radius)) 
      rotate(calc(-1 * (var(--angle) + 360deg)));
  }
}

.team-card:hover {
  z-index: 10;
}

.team-cards:hover .team-card:not(:hover) {
  opacity: 0.3;
}

/* Avatar Link Wrapper */
.avatar-link-wrapper {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  text-decoration: none;
}

/* Visual Container */
.visual {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid #5f2dee;
  box-shadow: 0 5px 20px rgba(95, 45, 238, 0.3);
  transition: all 0.3s ease;
  background: #fff;
}

.team-card:hover .visual {
  transform: scale(1.15);
  border-color: #7c4dff;
  box-shadow: 0 10px 35px rgba(95, 45, 238, 0.6);
}

/* Avatar Image */
.avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Tooltip */
.tooltiptext {
  position: absolute;
  bottom: 180px;
  left: 50%;
  transform: translateX(-50%) scale(0);
  background: linear-gradient(135deg, #5f2dee 0%, #7c4dff 100%);
  color: #fff;
  padding: 15px;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(95, 45, 238, 0.5);
  min-width: 220px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 100;
}

.tooltiptext::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 8px solid transparent;
  border-top-color: #7c4dff;
}

.team-card:hover .tooltiptext {
  opacity: 1;
  transform: translateX(-50%) scale(1);
  pointer-events: auto;
}

/* Team Name */
.team-name {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 10px 0;
  color: #fff;
}

/* Team Title */
.team-title {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 8px 0;
}

/* Team Bio */
.team-bio {
  font-size: 13px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
  margin: 0;
}

.team-content-wrapper {
  margin-top: 5px;
}

/* Tooltip text color override */
.tooltiptext p {
  color: #fff;
}

/* Responsive Design */
@media (max-width: 991px) {
  .team-orbit-container {
    padding: 40px 0;
  }
}

@media (max-width: 768px) {
  .section-wrapper {
    width: 500px;
    height: 500px;
  }
  
  .slider-thumb {
    width: 350px;
    height: 350px;
  }

  .team-card {
    --radius: 160px;
    width: 120px;
    height: 120px;
    margin: -60px 0 0 -60px;
  }
  
  .visual {
    width: 120px;
    height: 120px;
  }

  .tooltiptext {
    min-width: 180px;
    bottom: 140px;
  }

  .team-name {
    font-size: 16px;
  }

  .team-title {
    font-size: 12px;
  }

  .team-bio {
    font-size: 11px;
  }
}

@media (max-width: 480px) {
  .section-wrapper {
    width: 400px;
    height: 400px;
  }
  
  .slider-thumb {
    width: 280px;
    height: 280px;
  }

  .team-card {
    --radius: 130px;
    width: 100px;
    height: 100px;
    margin: -50px 0 0 -50px;
  }
  
  .visual {
    width: 100px;
    height: 100px;
  }
}
