/* =========================
   ПЕРШИЙ ЕКРАН — КОМАНДА
========================= */

.hero-team-card {
  position: relative;
  overflow: hidden;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 32px;
  background:
    radial-gradient(
      circle at 72% 18%,
      rgba(92, 124, 255, 0.28),
      transparent 28%
    ),
    linear-gradient(145deg, #151c2a, #0d111b 72%);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.32);
}

.hero-team-card::before {
  content: "";
  position: absolute;
  inset: 88px 34px 112px;
  border: 2px solid rgba(122, 149, 255, 0.26);
  border-radius: 28px;
  transform: rotate(6deg);
}

.hero-team-headline {
  position: relative;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  color: var(--ink);
  background: var(--lime);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-team-photos {
  position: relative;
  z-index: 1;
  min-height: 500px;
  margin-top: 18px;
}

.hero-team-photo {
  position: absolute;
  bottom: 0;
  width: auto;
  max-width: none;
  object-fit: contain;
  object-position: bottom;
  filter: drop-shadow(0 18px 28px rgba(0, 0, 0, 0.28));
  backface-visibility: hidden;
  transform: translateZ(0);
  user-select: none;
  pointer-events: none;
}

/* Олег на першому екрані */

.hero-team-photo-oleh {
  left: -3%;
  width: 49%;
  z-index: 1;
}

/* Катя на першому екрані */

.hero-team-photo-katya {
  right: -2%;
  width: 59%;
  z-index: 2;
}

.hero-team-info-grid {
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: -18px;
}

.person-card {
  padding: 16px;
  color: var(--white);
  background: rgba(12, 16, 26, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  backdrop-filter: blur(14px);
}

.person-card-link {
  transition:
    transform 0.18s ease,
    border-color 0.18s ease;
}

.person-card-link:hover {
  border-color: var(--lime);
  transform: translateY(-2px);
}

.person-name {
  font-size: 20px;
  font-weight: 800;
  line-height: 1.08;
}

.person-role {
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
  line-height: 1.4;
}

.person-note {
  margin-top: 10px;
  color: var(--lime);
  font-size: 12px;
  font-weight: 700;
}


/* =========================
   НИЖНІЙ БЛОК КОМАНДИ
========================= */

.mentor-section {
  background: #f5f4ef;
}

.mentor-section-inner {
  display: grid;
  gap: 32px;
}

.section-team-heading h2 {
  margin: 8px 0 0;
  font-size: clamp(32px, 4vw, 54px);
}

.mentor-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.mentor-card {
  overflow: hidden;
  background: #ffffff;
  border: 1px solid #d9d7cf;
  border-radius: 28px;
  box-shadow: 0 24px 55px rgba(0, 0, 0, 0.08);
}

.mentor-photo-wrap {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  height: 420px;
  padding: 36px 36px 0;
  overflow: hidden;
}

.mentor-photo-wrap-oleh {
  background: #b8ea5a;
}

.mentor-photo-wrap-katya {
  background: #dce6c9;
}

.mentor-photo {
  width: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: bottom;
  backface-visibility: hidden;
  transform: translateZ(0);
}

.mentor-card-body {
  padding: 28px;
}

.mentor-card-body h3 {
  margin: 0;
  font-size: 40px;
  line-height: 1.02;
}

.mentor-role {
  margin: 10px 0 22px;
  color: #6f7380;
  font-size: 18px;
  line-height: 1.4;
}

.mentor-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding-left: 24px;
  color: #20232b;
  font-size: 18px;
  line-height: 1.55;
}

.mentor-link {
  display: inline-flex;
  margin-top: 22px;
  color: #3654d9;
  font-weight: 700;
}


/* =========================
   ПЛАНШЕТ
========================= */

@media (max-width: 1040px) {
  .mentor-cards {
    grid-template-columns: 1fr;
  }
}


/* =========================
   МОБІЛЬНА ВЕРСІЯ
========================= */

@media (max-width: 760px) {
  .hero-team-card {
    padding: 16px;
    border-radius: 24px;
  }

  .hero-team-card::before {
    inset: 72px 22px 150px;
    border-radius: 24px;
  }

  .hero-team-headline {
    padding: 10px 18px;
    font-size: 11px;
  }

  /*
   * Збільшили висоту фотозони.
   * Завдяки цьому обличчя й тіла стають помітно більшими.
   */

  .hero-team-photos {
    min-height: 500px;
    margin-top: 0;
  }

  /*
   * Олег:
   * більша ширина;
   * зміщення вліво, щоб тіло не витискало Катю;
   * нижня частина ховається під інформаційною карткою.
   */

  .hero-team-photo-oleh {
    left: -20%;
    bottom: -2px;
    width: 82%;
    z-index: 1;
  }

  /*
   * Катя:
   * трохи більша за Олега;
   * стоїть попереду;
   * зміщена вправо.
   */

  .hero-team-photo-katya {
    right: -22%;
    bottom: -2px;
    width: 92%;
    z-index: 2;
  }

  /*
   * Підтягуємо картки ближче до людей,
   * щоб не залишати порожню дірку між фото та текстом.
   */

  .hero-team-info-grid {
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: -48px;
  }

  .person-card {
    padding: 15px 16px;
  }

  .person-name {
    font-size: 19px;
  }

  .person-role {
    margin-top: 6px;
    font-size: 13px;
    line-height: 1.35;
  }

  .person-note {
    margin-top: 8px;
    font-size: 12px;
  }

  /*
   * Нижній блок команди.
   * Тут розміри фото лишаємо такими,
   * як на твоєму другому скрині.
   */

  .mentor-section-inner {
    gap: 24px;
  }

  .mentor-photo-wrap {
    height: 320px;
    padding: 24px 18px 0;
  }

  .mentor-card-body {
    padding: 22px 18px 24px;
  }

  .mentor-card-body h3 {
    font-size: 28px;
  }

  .mentor-role,
  .mentor-list {
    font-size: 16px;
  }
}


/* =========================
   ДУЖЕ ВУЗЬКІ ЕКРАНИ
========================= */

@media (max-width: 390px) {
  .hero-team-photos {
    min-height: 470px;
  }

  .hero-team-photo-oleh {
    left: -23%;
    width: 84%;
  }

  .hero-team-photo-katya {
    right: -25%;
    width: 95%;
  }

  .hero-team-info-grid {
    margin-top: -44px;
  }
}
