/**
 * Trang danh sách giáo viên — /doi-ngu-giang-vien
 * Desktop: xen kẽ ảnh trái/phải; mobile: ảnh trên, thông tin dưới.
 */

body.teachers-listing-page {
  background: #fff;
}

.teachers-listing-page__root {
  padding-bottom: clamp(56px, 7vw, 96px);
}

/* —— Hero —— */
.teachers-listing-hero {
  padding-bottom: clamp(32px, 4.5vw, 52px);
}

.teachers-listing-hero__heading {
  position: relative;
  z-index: 1;
  max-width: 920px;
  margin-top: clamp(12px, 2vw, 24px);
}

.teachers-listing-hero__kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 116, 24, 0.2);
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 243, 234, 0.92) 100%);
  color: var(--sunny-dark, #ff7418);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 0 8px 24px rgba(255, 116, 24, 0.08);
}

.teachers-listing-hero__lead {
  margin: 20px 0 0;
  max-width: 720px;
  color: #5f5a5d;
  font-size: clamp(15px, 1.2vw, 19px);
  line-height: 1.65;
}

/* —— Main area —— */
.teachers-listing-main {
  position: relative;
  margin-top: clamp(4px, 1.5vw, 14px);
}

.teachers-listing-main::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -40px;
  transform: translateX(-50%);
  width: min(920px, 92vw);
  height: 280px;
  background: radial-gradient(ellipse at 50% 0%, rgba(255, 116, 24, 0.07) 0%, transparent 72%);
  pointer-events: none;
}

.teachers-listing-stack {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: clamp(28px, 4vw, 44px);
}

/* —— Card row —— */
.teachers-listing-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(300px, 0.94fr) minmax(340px, 1.06fr);
  align-items: stretch;
  min-height: 380px;
  border-radius: 32px;
  overflow: hidden;
  border: 1px solid rgba(242, 214, 200, 0.85);
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 116, 24, 0.09) 0%, transparent 42%),
    radial-gradient(circle at 0% 100%, rgba(255, 116, 24, 0.05) 0%, transparent 48%),
    linear-gradient(145deg, #fffdfb 0%, #fff8f2 48%, #fffaf7 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 24px 56px rgba(233, 93, 0, 0.09),
    0 8px 22px rgba(30, 34, 38, 0.05);
  transition:
    transform 0.38s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.38s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.38s ease;
}

.teachers-listing-row:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 116, 24, 0.28);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.98) inset,
    0 32px 68px rgba(233, 93, 0, 0.13),
    0 12px 28px rgba(30, 34, 38, 0.07);
}

.teachers-listing-row__glow {
  position: absolute;
  inset: auto auto -80px -80px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 116, 24, 0.14) 0%, transparent 68%);
  pointer-events: none;
  z-index: 0;
}

.teachers-listing-row--reverse .teachers-listing-row__glow {
  inset: auto -80px -80px auto;
}

.teachers-listing-row__dots {
  position: absolute;
  top: 22px;
  right: 24px;
  width: 72px;
  height: 72px;
  background-image: radial-gradient(rgba(255, 116, 24, 0.45) 1.4px, transparent 1.4px);
  background-size: 12px 12px;
  opacity: 0.55;
  pointer-events: none;
  z-index: 2;
}

.teachers-listing-row--reverse .teachers-listing-row__dots {
  right: auto;
  left: 24px;
}

.teachers-listing-row--reverse {
  grid-template-columns: minmax(340px, 1.06fr) minmax(300px, 0.94fr);
}

.teachers-listing-row--reverse .teachers-listing-row__media {
  order: 2;
  border-right: none;
  border-left: 1px solid rgba(242, 214, 200, 0.75);
}

.teachers-listing-row--reverse .teachers-listing-row__body {
  order: 1;
}

/* —— Photo column —— */
.teachers-listing-row__media {
  position: relative;
  z-index: 1;
  margin: 0;
  min-height: 100%;
  display: flex;
  align-items: stretch;
  justify-content: center;
  padding: clamp(18px, 2.4vw, 28px);
  background: linear-gradient(180deg, #fff1e6 0%, #fff8f2 55%, #fffdfb 100%);
  border-right: 1px solid rgba(242, 214, 200, 0.75);
  overflow: hidden;
}

.teachers-listing-row__index {
  position: absolute;
  top: clamp(14px, 2vw, 22px);
  left: clamp(14px, 2vw, 22px);
  z-index: 3;
  display: grid;
  place-items: center;
  min-width: 52px;
  height: 52px;
  padding: 0 10px;
  border-radius: 16px;
  border: 1px solid rgba(255, 116, 24, 0.22);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--sunny-dark, #ff7418);
  font-family: "Quicksand", "Google Sans Flex", sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.06em;
  box-shadow: 0 10px 28px rgba(255, 116, 24, 0.12);
}

.teachers-listing-row--reverse .teachers-listing-row__index {
  left: auto;
  right: clamp(14px, 2vw, 22px);
}

.teachers-listing-row__photo-shell {
  position: relative;
  flex: 1 1 auto;
  display: flex;
  align-items: stretch;
  justify-content: center;
  width: 100%;
  min-height: 100%;
  padding: clamp(12px, 1.8vw, 20px) clamp(12px, 1.8vw, 20px) clamp(8px, 1.2vw, 14px);
  border-radius: 24px;
  border: 1px solid rgba(242, 214, 200, 0.95);
  background:
    radial-gradient(circle at 50% 88%, rgba(255, 116, 24, 0.1) 0%, transparent 58%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.72) 0%, rgba(255, 251, 247, 0.96) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  overflow: hidden;
}

.teachers-listing-row__photo-link {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 300px;
}

.teachers-listing-row__photo {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: min(440px, 100%);
  display: block;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 16px 32px rgba(30, 34, 38, 0.14));
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.teachers-listing-row:hover .teachers-listing-row__photo {
  transform: scale(1.035) translateY(-4px);
}

.teachers-listing-row__photo-shade {
  position: absolute;
  inset: auto 0 0 0;
  height: 38%;
  background: linear-gradient(180deg, transparent 0%, rgba(255, 248, 242, 0.55) 100%);
  pointer-events: none;
}

/* —— Body column —— */
.teachers-listing-row__body {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0;
  min-width: 0;
  padding: clamp(28px, 3.2vw, 42px) clamp(26px, 3.4vw, 44px);
}

.teachers-listing-row__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  margin-bottom: 18px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid rgba(255, 116, 24, 0.16);
  background: rgba(255, 116, 24, 0.08);
  color: var(--sunny-dark, #ff7418);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.teachers-listing-row__eyebrow i {
  font-size: 13px;
  color: var(--sunny, #ff7418);
}

.teachers-listing-row__topline {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 18px;
  align-items: center;
}

.teachers-listing-row__badge {
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  border: 1.5px solid rgba(255, 116, 24, 0.32);
  border-radius: 50%;
  color: var(--sunny, #ff7418);
  background: rgba(255, 255, 255, 0.96);
  box-shadow:
    0 14px 32px rgba(255, 116, 24, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
  flex-shrink: 0;
}

.teachers-listing-row__badge svg {
  width: 34px;
  height: 34px;
  fill: currentColor;
  stroke: none;
}

.teachers-listing-row__identity {
  min-width: 0;
}

.teachers-listing-row__name {
  margin: 0;
  color: #07070a;
  font-size: clamp(26px, 2.4vw, 38px);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.024em;
  text-wrap: balance;
}

.teachers-listing-row__name-link {
  color: inherit;
  text-decoration: none;
  transition: color 0.22s ease;
}

.teachers-listing-row__name-link:hover {
  color: var(--sunny-dark, #ff7418);
}

.teachers-listing-row__role {
  margin: 10px 0 0;
  color: var(--sunny-dark, #ff7418);
  font-size: clamp(15px, 1.15vw, 18px);
  line-height: 1.3;
  font-weight: 600;
}

.teachers-listing-row__content {
  margin-top: 22px;
}

.teachers-listing-row__points {
  margin: 0;
  padding: 22px 0 0;
  list-style: none;
  display: grid;
  gap: 14px;
  border-top: 1px dashed rgba(255, 116, 24, 0.34);
}

.teachers-listing-row__points li {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 14px;
  align-items: center;
}

.teachers-listing-row__point-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 116, 24, 0.28);
  border-radius: 50%;
  color: var(--sunny, #ff7418);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 22px rgba(255, 116, 24, 0.1);
  flex-shrink: 0;
}

.teachers-listing-row__point-icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.teachers-listing-row__point-text {
  color: #2e2829;
  font-size: clamp(14px, 1.05vw, 16px);
  line-height: 1.5;
  font-weight: 500;
}

.teachers-listing-row__actions {
  margin-top: clamp(22px, 2.8vw, 30px);
  padding-top: 4px;
}

.teachers-listing-row__cta {
  min-height: 52px;
  padding-inline: 26px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 16px 36px rgba(255, 116, 24, 0.22);
}

.teachers-listing-row__cta svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.teachers-listing-row:hover .teachers-listing-row__cta {
  box-shadow: 0 20px 42px rgba(255, 116, 24, 0.28);
}

/* —— Empty + footer CTA —— */
.teachers-listing-empty,
.teachers-listing-foot {
  text-align: center;
}

.teachers-listing-empty {
  padding: clamp(40px, 5vw, 64px) 28px;
  border-radius: 28px;
  border: 1px solid rgba(255, 116, 24, 0.14);
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 116, 24, 0.08) 0%, transparent 55%),
    linear-gradient(180deg, #fffaf7 0%, #fff 100%);
  box-shadow: 0 18px 44px rgba(255, 116, 24, 0.07);
}

.teachers-listing-empty p {
  margin: 0 0 22px;
  color: #5f5a5d;
  font-size: 16px;
  line-height: 1.65;
}

.teachers-listing-foot {
  margin-top: clamp(44px, 6vw, 64px);
}

.teachers-listing-foot .course-btn {
  min-height: 54px;
  padding-inline: 32px;
  box-shadow: 0 18px 40px rgba(255, 116, 24, 0.2);
}

/* —— Responsive —— */
@media (max-width: 991.98px) {
  .teachers-listing-row,
  .teachers-listing-row--reverse {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .teachers-listing-row--reverse .teachers-listing-row__media,
  .teachers-listing-row--reverse .teachers-listing-row__body {
    order: unset;
  }

  .teachers-listing-row__media {
    border-right: none;
    border-bottom: 1px solid rgba(242, 214, 200, 0.75);
    padding: 16px 16px 12px;
  }

  .teachers-listing-row--reverse .teachers-listing-row__media {
    border-left: none;
    border-bottom: 1px solid rgba(242, 214, 200, 0.75);
  }

  .teachers-listing-row__index,
  .teachers-listing-row--reverse .teachers-listing-row__index {
    left: 16px;
    right: auto;
  }

  .teachers-listing-row__dots,
  .teachers-listing-row--reverse .teachers-listing-row__dots {
    right: 16px;
    left: auto;
  }

  .teachers-listing-row__photo-link {
    min-height: 260px;
  }

  .teachers-listing-row__photo {
    max-height: min(360px, 100%);
  }

  .teachers-listing-row__body {
    padding: 22px 20px 26px;
  }

  .teachers-listing-row__topline {
    grid-template-columns: 60px 1fr;
    gap: 14px;
  }

  .teachers-listing-row__badge {
    width: 60px;
    height: 60px;
  }

  .teachers-listing-row__badge svg {
    width: 30px;
    height: 30px;
  }

  .teachers-listing-row__points li {
    grid-template-columns: 40px 1fr;
    gap: 12px;
  }

  .teachers-listing-row__point-icon {
    width: 40px;
    height: 40px;
  }
}

@media (max-width: 575.98px) {
  .teachers-listing-row {
    border-radius: 24px;
  }

  .teachers-listing-row__photo-shell {
    border-radius: 18px;
  }

  .teachers-listing-row__photo-link {
    min-height: 220px;
  }

  .teachers-listing-row__index {
    min-width: 46px;
    height: 46px;
    font-size: 16px;
    border-radius: 14px;
  }

  .teachers-listing-row__eyebrow {
    font-size: 10px;
    padding: 5px 11px;
  }

  .teachers-listing-row__actions .course-btn,
  .teachers-listing-row__cta {
    width: 100%;
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .teachers-listing-row,
  .teachers-listing-row__photo {
    transition: none;
  }

  .teachers-listing-row:hover {
    transform: none;
  }

  .teachers-listing-row:hover .teachers-listing-row__photo {
    transform: none;
  }
}
