.teacher-slider {
  position: relative;
  width: 100%;
  padding: 2rem 0;
  overflow: hidden;
}

.teacher-slider__track {
  display: flex;
  gap: 2rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 2rem 1rem 4rem 1rem; /* More padding bottom for shadows */
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;
}

.teacher-slider__track::-webkit-scrollbar {
  display: none;
}

/* Card Container */
.teacher-card {
  flex: 0 0 320px;
  background: #0c0a14;
  border-radius: 1.25rem; /* Rounded corners */
  overflow: hidden;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.3);
  scroll-snap-align: center;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(220, 38, 38, 0.15);
  position: relative;
}

.teacher-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px -10px rgba(220, 38, 38, 0.25);
  border-color: rgba(220, 38, 38, 0.35);
}

/* Image Area */
.teacher-card__image-wrapper {
  position: relative;
  width: 100%;
  height: 340px;
  overflow: hidden;
  background-color: #0a0812;
}

.teacher-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.teacher-card:hover .teacher-card__image {
  transform: scale(1.05);
}

/* Social Overlay */
.teacher-card__socials {
  position: absolute;
  bottom: 1rem;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 1rem;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.4s ease;
  z-index: 2;
}

.teacher-card:hover .teacher-card__socials {
  opacity: 1;
  transform: translateY(0);
}

.teacher-card__social-link {
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #333;
  transition: all 0.2s ease;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.teacher-card__social-link:hover {
  background: #dc2626; /* Rock red */
  color: #fff;
  transform: translateY(-3px);
}

/* Content Area */
.teacher-card__content {
  padding: 1.75rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  background: #0c0a14;
}

/* Badge */
.teacher-card__header {
  margin-bottom: 0.75rem;
}

.teacher-card__badge {
  display: inline-block;
  padding: 0.35em 0.8em;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #fecaca;
  background-color: rgba(220, 38, 38, 0.2);
  border-radius: 50rem;
}

.teacher-card__name {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
  color: #f1f5f9;
  letter-spacing: -0.02em;
}

.teacher-card__bio {
  font-size: 0.95rem;
  color: #94a3b8;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 1.5rem;
}

/* "See More" Button */
.teacher-card__more {
  margin-top: auto;
  background: none;
  border: none;
  padding: 0;
  color: #ef4444;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: gap 0.2s ease;
}

.teacher-card__more::after {
  content: "→";
  font-family: system-ui;
  transition: transform 0.2s ease;
}

.teacher-card__more:hover {
  text-decoration: underline;
  gap: 0.75rem;
}

.teacher-card.is-expanded .teacher-card__bio {
  -webkit-line-clamp: initial;
  display: block;
  max-height: none;
  overflow: visible;
}

.teacher-card.is-expanded .teacher-card__more::after {
  transform: rotate(90deg);
}

.teacher-card__more[hidden] {
  display: none;
}

/* Navigation Buttons - Floating Style */
.teacher-slider__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #0c0a14;
  border: 1px solid rgba(220, 38, 38, 0.3);
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  color: #f1f5f9;
  opacity: 0; /* Hidden by default until hover over section */
}

.teacher-slider:hover .teacher-slider__nav {
  opacity: 1;
}

.teacher-slider__nav:hover {
  background: #dc2626;
  box-shadow: 0 8px 25px rgba(220, 38, 38, 0.3);
  transform: translateY(-50%) scale(1.1);
  color: #fff;
  border-color: #dc2626;
}

.teacher-slider__nav--prev {
  left: 1rem;
}

.teacher-slider__nav--next {
  right: 1rem;
}

/* Responsive Adjustments */
@media (min-width: 768px) {
  .teacher-card {
    flex: 0 0 360px;
  }

  /* Pull nav buttons outside on larger screens */
  .teacher-slider__nav--prev {
    left: 0;
    transform: translate(-50%, -50%);
  }
  .teacher-slider__nav--prev:hover {
    transform: translate(-50%, -50%) scale(1.1);
  }

  .teacher-slider__nav--next {
    right: 0;
    transform: translate(50%, -50%);
  }
  .teacher-slider__nav--next:hover {
    transform: translate(50%, -50%) scale(1.1);
  }
  
  .eg-container {
     /* Ensure container has enough padding/margin for the overflowing buttons if needed */
     position: relative;
  }
}
