/* The team section STARTS */

#team-section {
  text-align: center;
  background-color: var(--black);
  /* margin-bottom: 2.5rem */
}

.team-title {
  color: #fff;
  font-size: 1.6rem;
  letter-spacing: 0.15em;
  padding: 2.5rem;
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.6rem;
  margin: 0 auto;
  max-width: 1000px;
  padding: 0 2.5rem 2.5rem 2.5rem;
}


.team-card {
  background-color: #5d5d5d;
  border-radius: 1.4rem;
  padding: 1.4rem 1.1rem;
  display: flex;
  flex-direction: column;
  align-items: center;

  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);

  text-decoration: none;
  color: inherit;
  cursor: pointer;

  opacity: 0;
  transform: translateY(16px) scale(0.98);
  filter: blur(6px);

  transition:
    transform 700ms ease,
    background-color 300ms ease,
    opacity 3000ms cubic-bezier(0.2, 0.8, 0.2, 1),
    filter 500ms cubic-bezier(0.2, 0.8, 0.2, 1);

  will-change: transform, box-shadow;
}

/* stagger directions */
.team-card:nth-child(odd) {
  transform: translateX(-40px) translateY(16px) scale(0.98);
}

.team-card:nth-child(even) {
  transform: translateX(40px) translateY(16px) scale(0.98);
}

/* visible state */
.team-card.is-visible {
  opacity: 1;
  transform: translateX(0) translateY(0) scale(1);
  filter: blur(0);
}

/* FULL CARD hover effect */
.team-card:hover,
.team-card:focus-visible {
  transform: scale(1.1);
  background-color: #666;
}

/* image wrapper */
.team-card__image-wrapper {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 1.3rem;
}

.team-card__image {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 300ms ease, filter 200ms ease;
}

/* image reacts when CARD is hovered */
.team-card:hover .team-card__image,
.team-card:focus-visible .team-card__image {
  transform: scale(1.1);
  filter: saturate(1.1) contrast(1.05);
}

.team-card__name {
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 0.7rem;
}

.team-card__roles {
  font-size: 0.9rem;
  line-height: 1.5;
  color: #f5f5f5;
}

/* stagger timing */
.team-card:nth-child(1) { transition-delay: 0ms; }
.team-card:nth-child(2) { transition-delay: 80ms; }
.team-card:nth-child(3) { transition-delay: 160ms; }
.team-card:nth-child(4) { transition-delay: 240ms; }

/* Contact form starts here */
