/* From Uiverse.io by Uncannypotato69 — adapté MAM Les Jolis Instants */

.team {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.team-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
  min-height: 0;
  padding: 2rem 1.75rem;
  border-radius: var(--radius);
  background: linear-gradient(145deg, #fdeee8 0%, var(--pink-light) 100%);
  color: var(--pink);
  font-family: var(--font-body);
  font-size: 1.05rem;
}

.team-card.glow-card {
  box-shadow: none;
}

.team-card__header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  width: 100%;
  height: fit-content;
}

.team-card--mirror .team-card__header {
  flex-direction: row-reverse;
}

.team-card--mirror .team-card__intro {
  align-items: flex-end;
  text-align: right;
}

.team-card--mirror .team-card__tag {
  flex-direction: row-reverse;
  text-align: right;
}

.team-card__photo {
  flex-shrink: 0;
  width: 112px;
  height: 112px;
  border-radius: 1.15rem;
  background: rgba(255, 255, 255, 0.65);
  border: 2px dashed rgba(36, 55, 81, 0.18);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  overflow: hidden;
}

.team-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(1rem - 2px);
}

.team-card__photo-icon {
  font-size: 1.85rem;
  line-height: 1;
  opacity: 0.55;
}

.team-card__photo-text {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgba(36, 55, 81, 0.45);
  text-align: center;
  line-height: 1.2;
  padding: 0 0.25rem;
}

.team-card__divider-v {
  flex-shrink: 0;
  width: 1px;
  height: 5.75rem;
  border-radius: 999px;
  background: hsla(336, 86%, 70%, 0.5);
}

.team-card__intro {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  min-width: 0;
}

.team-card__role {
  font-size: 0.85rem;
  font-weight: 400;
  color: rgba(36, 55, 81, 0.65);
}

.team-card__name {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
  margin: 0.2rem 0 0.35rem;
}

.team-card__tag {
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0.35rem;
}

.team-card__tag svg {
  flex-shrink: 0;
  width: 18px;
  height: auto;
  margin-top: 0.1rem;
}

.team-card__tag p {
  font-size: 0.82rem;
  font-weight: 400;
  color: rgba(36, 55, 81, 0.7);
  line-height: 1.35;
}

.team-card__divider-h {
  width: 100%;
  height: 0.5px;
  border-radius: 999px;
  background: hsla(336, 86%, 70%, 0.5);
}

.team-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: fit-content;
  gap: 1rem;
}

.team-card__stats {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  width: 100%;
  height: fit-content;
  font-size: 0.92rem;
  color: var(--navy);
}

.team-card__stat {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.35rem 0.25rem;
}

.team-card__stat-icon {
  flex-shrink: 0;
  font-size: 1.1rem;
  line-height: 1;
  width: 20px;
  text-align: center;
}

.team-card__stat-divider {
  flex-shrink: 0;
  width: 1px;
  height: 0.85rem;
  border-radius: 999px;
  background: hsla(336, 86%, 70%, 0.5);
}

.team-card__stat p {
  font-size: inherit;
  white-space: nowrap;
}

.team-card__stat p:last-child {
  font-weight: 700;
}

.team-card__mascot {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 7.5rem;
  padding: 0.35rem 0;
  font-size: 0.82rem;
  flex-shrink: 0;
}

.team-card__rainbow-wrap {
  position: relative;
  z-index: 0;
  width: 68px;
  height: 68px;
}

.team-card__rainbow {
  width: 68px;
  height: 68px;
  transition: transform 0.2s ease;
}

.team-card__rainbow-wrap:hover .team-card__rainbow {
  transform: translateY(-8px);
}

.team-card__rainbow-shadow {
  position: absolute;
  bottom: 8px;
  left: 50%;
  z-index: -1;
  width: 32px;
  height: 4px;
  transform: translateX(-50%);
  background: rgba(104, 8, 46, 0.35);
  filter: blur(6px);
  border-radius: 999px;
  transition: width 0.2s ease, filter 0.2s ease;
}

.team-card__rainbow-wrap:hover .team-card__rainbow-shadow {
  width: 16px;
  filter: blur(4px);
}

.team-card__rainbow-wrap--sun .team-card__rainbow-shadow {
  background: rgba(232, 176, 89, 0.45);
}

.team-card__mascot p {
  margin-top: 0.35em;
  text-align: center;
  font-weight: 400;
  color: rgba(36, 55, 81, 0.65);
  line-height: 1.3;
}

.team__note {
  text-align: center;
  font-size: 0.9rem;
  font-style: italic;
  opacity: 0.65;
  color: var(--navy);
}

@media (prefers-reduced-motion: reduce) {
  .team-card__rainbow,
  .team-card__rainbow-shadow {
    transition: none;
  }

  .team-card__rainbow-wrap:hover .team-card__rainbow {
    transform: none;
  }
}
