@import "vars.css";

#trainers .tc {
  position: relative;
  padding-inline: 56px;
}

#trainers .tc-viewport {
  --slides-per-view: 1;
  overflow: hidden;
}

@media (min-width: 600px) {
  #trainers .tc-viewport {
    --slides-per-view: 2;
  }
}

@media (min-width: 980px) {
  #trainers .tc-viewport {
    --slides-per-view: 3;
  }
}

#trainers .tc-track {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1rem;
  will-change: transform;
  align-items: stretch;
}

#trainers .tc-slide {
  box-sizing: border-box;
  flex: 0 0 calc(100% / var(--slides-per-view));
  padding: 0.75rem;
}

#trainers .tc-card {
  text-align: left;
  background: rgba(0, 0, 0, 0.07);
  border-radius: 12px;
  padding: 1.25rem 1.25rem 1rem;
  height: 100%;
  display: grid;
  grid-template-rows: auto auto auto 1fr;
  gap: 0.25rem;
  overflow: hidden;
  box-sizing: border-box;
}

#trainers .tc-card > * {
  min-width: 0;
}

@media (max-width: 980px) {
  #trainers .tc-card {
    text-align: center;
  }
}

#trainers .tc-card img {
  object-fit: cover;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  display: block;
  margin: 0 0 1rem 0;
}

@media (max-width: 980px) {
  #trainers .tc-card img {
    margin: 0 auto 1rem;
  }
}

#trainers .tc-card h3 {
  line-height: 1.25;
  margin-bottom: 0.5rem;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  min-height: calc(1.25em * 2);
}

#trainers .tc-contact {
  display: block;
  margin-top: 0.25rem;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

#trainers .tc-contact a {
  display: block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: clamp(11px, 0.6vw + 8px, 14px);
  text-decoration: none;
  overflow-wrap: normal;
  word-break: normal;
}

#trainers .tc-card p {
  font-size: 80%;
  margin: 0 10px 0 0;
  opacity: 0.95;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
}

#trainers .tc-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  padding: 0;
  margin: 0;
  border: none;
  outline: none;
  box-shadow: none;
  background: none;
  color: var(--gold1);
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0.9;
  transition:
    opacity 150ms ease,
    transform 150ms ease;
}

#trainers .tc-btn:hover {
  opacity: 1;
  transform: translateY(-50%) scale(1.06);
}

#trainers .tc-btn:active {
  opacity: 0.75;
  transform: translateY(-50%) scale(0.94);
}

#trainers .tc-btn.tc-prev {
  left: -10px;
}

#trainers .tc-btn.tc-next {
  right: -10px;
}

@media (max-width: 420px) {
  #trainers .tc {
    padding-inline: 44px;
  }

  #trainers .tc-btn {
    font-size: 32px;
  }

  #trainers .tc-btn.tc-prev {
    left: 4px;
  }

  #trainers .tc-btn.tc-next {
    right: 4px;
  }
}

#trainers .tc-more-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.9rem;
  margin-top: 0.5rem;
  border-radius: 999px;
  border: none;
  background: var(--gold1);
  color: #000;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

#trainers .tc-more-btn:focus-visible {
  outline: 2px solid #000;
  outline-offset: 2px;
}

@media (max-width: 980px) {
  #trainers .tc-more-btn {
    justify-self: center;
  }
}
