/* =================================================================
   TryVinci – Experts ("Oni trenują z tryVinci")

   Mechanika karuzeli wg wzorca z bloku `categories` (drag + snap +
   kropki + strzałki), ale WSZYSTKIE klasy są namespace'owane
   (.tv-experts__…). Świadomie nie używam współdzielonych
   .tv-carousel-* — categories definiuje je globalnie w swoim
   style.css, a tu obowiązują inne odstępy (gap 1.5rem, brak
   padding-top). Redefinicja psułaby categories na stronie głównej.

   Wartości 1:1 z eksportem (App.tsx → ExpertsSection).
   Breakpointy Tailwind: sm 640, md 768, lg 1024.
   ================================================================= */

/* ── Sekcja: py-24 md:py-32 bg-white ── */
.tv-experts {
  position: relative;
  z-index: 10;
  width: 100%;
  padding: 6rem 0;
  background: #fff;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}
@media (min-width: 768px) {
  .tv-experts {
    padding: 8rem 0;
  }
}

/* ── Nagłówek: max-w-[1400px] px-6 mb-12, flex-col → md:flex-row ──
   Mobile: wszystko wyśrodkowane, strzałki pod tekstem.
   Desktop: tekst po lewej, strzałki w prawym górnym rogu.          */
.tv-experts__header {
  width: 100%;
  max-width: 87.5rem; /* 1400px */
  margin: 0 auto 3rem;
  padding: 0 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  text-align: center;
}
@media (min-width: 768px) {
  .tv-experts__header {
    flex-direction: row;
    text-align: left;
  }
}

.tv-experts__header-text {
  flex: 1 1 0%;
  min-width: 0;
}

/* eksport: mb-4 (globalny .tv-section-heading ma 1.5rem — nadpisujemy scoped) */
.tv-experts .tv-experts__heading {
  margin-bottom: 1rem;
}

/* eksport: text-zinc-500 text-lg max-w-2xl font-bold */
.tv-experts__subtext {
  color: #71717a;
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.625;
  max-width: 42rem;
  margin: 0;
}
@media (min-width: 768px) {
  .tv-experts__subtext {
    margin-right: auto;
  }
}

/* ── Strzałki: p-4 rounded-full bg-zinc-50 border-zinc-200 shadow-sm ── */
.tv-experts__arrows {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-shrink: 0;
}
.tv-experts__arrow {
  padding: 1rem;
  border-radius: 9999px;
  background: #fafafa;
  border: 1px solid #e4e4e7;
  color: #18181b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  transition: background-color 0.2s;
}
.tv-experts__arrow:hover {
  background: #f4f4f5;
}

/* ── Kropki: tylko poniżej lg (eksport: lg:hidden), mb-8 ── */
.tv-experts__dots-wrap {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-bottom: 2rem;
}
@media (min-width: 1024px) {
  .tv-experts__dots-wrap {
    display: none;
  }
}
.tv-experts__dots {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.tv-experts__dot {
  width: 0.375rem;   /* w-1.5 */
  height: 0.375rem;  /* h-1.5 */
  border-radius: 9999px;
  background: #e4e4e7;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: width 0.3s, background-color 0.3s;
}
.tv-experts__dot.is-active {
  width: 1.5rem;     /* w-6 */
  background: #ef6a23;
}

/* ── Tor: pl-6 md:pl-12, max-w-[1600px] ── */
.tv-experts__track-wrap {
  position: relative;
  width: 100%;
  max-width: 100rem; /* 1600px */
  margin: 0 auto;
  padding-left: 1.5rem;
}
@media (min-width: 768px) {
  .tv-experts__track-wrap {
    padding-left: 3rem;
  }
}

.tv-experts__track {
  display: flex;
  align-items: stretch;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 3rem;
  padding-right: 1.5rem;
  cursor: grab;
  /* no-scrollbar */
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.tv-experts__track::-webkit-scrollbar {
  display: none;
}
@media (min-width: 768px) {
  .tv-experts__track {
    padding-right: 3rem;
  }
}
/* Podczas przeciągania: bez snapowania i bez smooth, inaczej scrollLeft
   ustawiany z JS byłby wygładzany i drag „gumkowałby". Eksport robi to
   samo, przełączając scrollBehavior na 'auto'. */
.tv-experts__track.is-dragging {
  cursor: grabbing;
  user-select: none;
  scroll-snap-type: none;
  scroll-behavior: auto;
}

/* ─────────────────────────────────────────────────────────────────
   Karta: zdjęcie u góry + treść pod spodem.
   eksport: w-[85vw] md:w-[400px] lg:w-[450px], bg-zinc-50,
   border-zinc-100, rounded-[2.5rem], shadow-sm
   ───────────────────────────────────────────────────────────────── */
.tv-experts__card {
  scroll-snap-align: center;
  flex-shrink: 0;
  /* width (nie min-width): zdjęcie jest w przepływie, przy min-width jego
     intrinsic szerokość rozdymałaby slajd — jak w tv-cats__card. */
  width: 85vw;
  min-width: 0;
  display: flex;
  flex-direction: column;
  height: auto;
  background: #fafafa;
  border: 1px solid #f4f4f5;
  border-radius: 2.5rem;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  overflow: hidden;
  user-select: none;
}
@media (min-width: 768px) {
  .tv-experts__card {
    width: 25rem; /* 400px */
  }
}
@media (min-width: 1024px) {
  .tv-experts__card {
    width: 28.125rem; /* 450px */
  }
}

/* ── Kadr zdjęcia: aspect-[4/3] sm:aspect-[3/2] ──
   object-fit / object-position / tło ustawiane PER OSOBA inline
   w render.php — tu tylko wartości domyślne. */
.tv-experts__card-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  flex-shrink: 0;
  overflow: hidden;
  border-bottom: 1px solid #f4f4f5;
}
@media (min-width: 640px) {
  .tv-experts__card-img-wrap {
    aspect-ratio: 3 / 2;
  }
}
.tv-experts__card-img {
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
  transition: transform 0.7s;
}
.tv-experts__card:hover .tv-experts__card-img {
  transform: scale(1.05);
}

/* Brak pliku w Media Library → neutralne tło z inicjałem osoby.
   Świadomie bez zewnętrznego serwisu z obrazkami. */
.tv-experts__card-initial {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #a1a1aa;
  font-weight: 700;
  font-size: 3rem;
  line-height: 1;
}

/* ── Treść: p-6 sm:p-8, bg-white ── */
.tv-experts__card-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  background: #fff;
}
@media (min-width: 640px) {
  .tv-experts__card-text {
    padding: 2rem;
  }
}

.tv-experts__card-head {
  margin-bottom: 1.25rem; /* mb-5 */
}
.tv-experts__card-name {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.25;
  color: #18181b;
  margin: 0;
}
.tv-experts__card-role {
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.625;
  color: #ef6a23;
  margin: 0.375rem 0 0; /* mt-1.5 */
}
.tv-experts__card-quote {
  flex: 1;
  color: #52525b;
  font-style: italic;
  font-size: 1rem;
  line-height: 1.625;
}
@media (min-width: 640px) {
  .tv-experts__card-quote {
    font-size: 1.125rem;
  }
}
