/**
 * Educators Section — Editorial Premium Design
 * Vertical contextual photos, minimalist cards, magazine-style layout
 */

/* ─── Section header ─── */
.educators-section__header {
  text-align: center;
  margin-bottom: 80px;
}

.educators-section__title {
  font-size: clamp(2.25rem, 3.5vw, 3rem);
  font-weight: 300;
  line-height: 1.2;
  color: #111827;
  margin: 0;
  letter-spacing: -0.02em;
}

/* ─── Cycle label on each card ─── */
.educator-card__cycle {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1;
  color: var(--educators-accent, #487bff);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--educators-accent, #487bff);
  opacity: 0.7;
}

/* ─── Grid layout ─── */
.educators-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 60px 32px;
  max-width: 1600px;
  margin: 0 auto;
  position: relative;
}

/* ─── Educator cards (editorial style) ─── */
.educator-card {
  text-align: left;
  cursor: pointer;
  transition: transform 0.4s ease;
}

.educator-card:hover {
  transform: translateY(-4px);
}

.educator-card__toggle {
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
  padding: 0;
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: none;
}

.educator-card__toggle:focus-visible {
  outline: 2px solid #e5e7eb !important;
  outline-offset: 2px !important;
}

/* Editorial image - vertical format */
.educator-card__portrait {
  width: 100%;
  aspect-ratio: 3/4;
  border-radius: 12px;
  overflow: hidden;
  background: #f9fafb;
  margin-bottom: 20px;
}

.educator-card__portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.6s ease;
}

.educator-card:hover .educator-card__portrait img {
  transform: scale(1.02);
}

/* Minimal text info */
.educator-card__info {
  padding: 0 4px;
}

.educator-card__name {
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.3;
  color: #111827;
  margin: 0 0 4px;
  letter-spacing: -0.01em;
}

.educator-card__role {
  font-size: 0.95rem;
  font-weight: 400;
  line-height: 1.4;
  color: #6b7280;
  margin: 0;
}

.educator-card__campus {
  display: none; /* Hide campus in editorial style */
}

.educator-card__action {
  display: none; /* Hide CTA */
}

/* ─── Detail panel (editorial style) ─── */
.educator-detail {
  position: absolute;
  left: 50%;
  top: calc(100% + 32px);
  transform: translateX(-50%);
  width: 90vw;
  max-width: 1200px;
  padding: 48px 56px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  opacity: 0;
  transform: translateX(-50%) translateY(-12px);
  transition:
    opacity 0.4s ease,
    transform 0.4s ease;
  pointer-events: none;
  z-index: 1000;
}

.educator-detail[aria-hidden="false"] {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.educator-detail__content {
  display: flex;
  align-items: flex-start;
  gap: 48px;
  max-width: none;
}

.educator-detail__portrait {
  display: none; /* Hide portrait by default */
}

/* Show portrait only for Nadège */
.educator-detail[data-educator="nadege"] .educator-detail__portrait {
  display: block;
  width: 200px;
  height: 267px; /* 3:4 ratio */
  border-radius: 12px;
  overflow: hidden;
  background: #f3f4f6;
  flex-shrink: 0;
}

.educator-detail[data-educator="nadege"] .educator-detail__portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.educator-detail__info {
  flex: 1;
  text-align: left;
}

.educator-detail__name {
  font-size: 1.75rem;
  font-weight: 500;
  line-height: 1.2;
  color: #111827;
  margin: 0 0 8px;
  letter-spacing: -0.02em;
}

.educator-detail__role {
  font-size: 1.1rem;
  font-weight: 400;
  line-height: 1.3;
  color: #6b7280;
  margin: 0 0 24px;
}

.educator-detail__campus {
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.3;
  color: #9ca3af;
  margin: 0 0 32px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.educator-detail__bio {
  margin-bottom: 32px;
}

.educator-detail__bio p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #374151;
  margin: 0;
}

.educator-detail__languages,
.educator-detail__specialities {
  margin-bottom: 24px;
}

.educator-detail__label {
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.3;
  color: #6b7280;
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.educator-detail__languages p,
.educator-detail__specialities p {
  font-size: 1rem;
  line-height: 1.5;
  color: #374151;
  margin: 0;
}

/* Visual connection - subtle */
.educator-card--active .educator-card__portrait img {
  transform: scale(1.04);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.educator-card--active .educator-card__name {
  color: #111827;
}

/* ─── Responsive design ─── */
@media (max-width: 1400px) {
  .educators-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 48px 32px;
    max-width: 1400px;
  }

  .educator-detail {
    width: 90vw;
    max-width: 800px;
    padding: 40px 48px;
  }

  .educator-detail__content {
    gap: 32px;
  }

  .educator-detail[data-educator="nadege"] .educator-detail__portrait {
    width: 160px;
    height: 213px;
  }
}

@media (max-width: 1200px) {
  .educators-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 48px 32px;
    max-width: 1200px;
  }

  .educator-detail {
    width: 90vw;
    max-width: 800px;
    padding: 40px 48px;
  }

  .educator-detail__content {
    gap: 32px;
  }

  .educator-detail[data-educator="nadege"] .educator-detail__portrait {
    width: 160px;
    height: 213px;
  }
}

@media (max-width: 1024px) {
  .educators-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 48px 32px;
    max-width: 900px;
  }

  .educator-detail {
    width: 90vw;
    max-width: 800px;
    padding: 40px 48px;
  }

  .educator-detail__content {
    gap: 32px;
  }

  .educator-detail[data-educator="nadege"] .educator-detail__portrait {
    width: 160px;
    height: 213px;
  }
}

@media (max-width: 768px) {
  .educators-section__header {
    margin-bottom: 60px;
  }

  .educators-grid {
    grid-template-columns: 1fr;
    gap: 40px 24px;
    max-width: 500px;
  }

  .educator-card__portrait {
    margin-bottom: 16px;
  }

  .educator-card__name {
    font-size: 1.15rem;
  }

  .educator-card__role {
    font-size: 0.9rem;
  }

  .educator-detail {
    width: 95vw;
    max-width: none;
    margin: 24px 0 0;
    padding: 32px 24px;
    border-radius: 12px;
  }

  .educator-detail__content {
    flex-direction: column;
    gap: 24px;
  }

  .educator-detail[data-educator="nadege"] .educator-detail__portrait {
    width: 100%;
    height: 400px;
    max-width: 300px;
    margin: 0 auto;
  }

  .educator-detail__name {
    font-size: 1.5rem;
  }

  .educator-detail__role {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .educators-section__header {
    margin-bottom: 48px;
  }

  .educators-grid {
    gap: 32px 20px;
    max-width: 400px;
  }

  .educator-detail {
    padding: 24px 20px;
  }

  .educator-detail[data-educator="nadege"] .educator-detail__portrait {
    height: 320px;
  }
}
