/* ============================================================
   TEAM — "Наша команда"  (Figma node 4:17849)
   heading row (title + nav arrows) + row of member cards
   ============================================================ */
.team {
  background: transparent; /* секция на сером фоне страницы; белые — только карточки */
  padding-bottom: 48px;
}

/* ---- heading row ---- */
.team__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
}
.team__title {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-family: 'Rubik', sans-serif;
  font-weight: 700;
  font-size: 24px;
  line-height: 1;
  letter-spacing: -1.092px;
  color: var(--text-primary);
}

/* nav arrows */
.team__nav {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}
.team__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-24);
  box-shadow: var(--shadow-s);
  transition: background .15s ease, opacity .15s ease;
}
.team__arrow img {
  width: 24px;
  height: 24px;
  display: block;
}
.team__arrow--prev img { transform: rotate(180deg); }
.team__arrow:hover { background: var(--bg-primary-bg); }

/* ---- cards row ---- */
.team__row {
  display: flex;
  align-items: stretch;
  gap: 24px;
  overflow-x: auto;
  padding-bottom: 4px;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}

/* member card */
.team__card {
  position: relative;
  flex: 0 0 380px;
  width: 380px;
  height: 228px;
  display: flex;
  align-items: stretch;
  gap: 16px;
  padding: 16px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-24);
  box-shadow: var(--shadow-s);
  overflow: hidden;
  scroll-snap-align: start;
}

/* photo column — fills card height, slightly cropped */
.team__photo {
  flex: 0 0 166px;
  width: 166px;
  align-self: stretch;
  overflow: hidden;
}
.team__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
}

/* text + button column */
.team__body {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  padding: 0 0 4px;
}
.team__info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.team__name {
  margin: 0;
  font-family: 'Geologica', sans-serif;
  font-weight: 600;
  font-size: 20px;
  line-height: 1.1;
  letter-spacing: -0.18px;
  color: var(--text-primary);
}
.team__role {
  margin: 0;
  font-family: 'Geologica', sans-serif;
  font-weight: 400;
  font-size: 14px;
  line-height: 1.15;
  color: var(--text-secondary);
}

/* "Задать вопрос" button */
.team__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 20px;
  background: var(--bg-primary);
  color: var(--text-primary-inverse);
  border-radius: var(--radius-pill);
  font-family: 'Geologica', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.25;
  white-space: nowrap;
  transition: opacity .15s ease;
}
.team__btn:hover { opacity: .88; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .team__card { flex-basis: 340px; width: 340px; }
}

@media (max-width: 480px) {
  .team__title { font-size: 20px; letter-spacing: -0.6px; }
  .team__arrow { width: 40px; height: 40px; }
  .team__nav { gap: 12px; }
  /* card narrows but keeps photo+text side-by-side; row scrolls */
  .team__card { flex-basis: 300px; width: 300px; height: 220px; }
  .team__photo { flex-basis: 130px; width: 130px; }
}
