/**
 * Experts archive — Chuyên gia grid with colorful profile cards.
 */

.apm-experts-archive {
  background: #f5f7fb;
}

.apm-experts-archive__header {
  background: #eef3f9;
  padding: 48px 0 40px;
  border-bottom: 1px solid #e2e8f0;
}

.apm-experts-archive__header h1 {
  margin: 0 0 10px;
  color: #0a2540;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.apm-experts-archive__header .apm-page-header__lead {
  max-width: 42rem;
  margin: 0;
  color: #64748b;
}

.apm-experts-archive__content {
  padding: 40px 0 72px;
}

.apm-experts-archive__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.apm-experts-archive__empty {
  margin: 0;
  padding: 48px 24px;
  text-align: center;
  color: #64748b;
  background: #fff;
  border: 1px solid #e8eef5;
  border-radius: 16px;
}

/* Profile cards (shared look with Academy instructors) */
.apm-experts-archive .apm-inst-card {
  margin: 0;
  height: 100%;
}

.apm-experts-archive .apm-inst-card__inner {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 440px;
  padding: 18px 16px;
  border-radius: 22px;
  overflow: hidden;
  isolation: isolate;
  text-decoration: none;
  color: inherit;
  background: #dbeafe;
  box-shadow: 0 14px 34px rgba(30, 78, 216, 0.14);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.apm-experts-archive a.apm-inst-card__inner:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(30, 78, 216, 0.22);
}

.apm-experts-archive .apm-inst-card__glow {
  position: absolute;
  inset: -18%;
  z-index: 0;
  background-position: center top;
  background-size: cover;
  background-repeat: no-repeat;
  filter: blur(28px) saturate(1.35) brightness(1.05);
  transform: scale(1.15);
  opacity: 0.95;
  pointer-events: none;
}

.apm-experts-archive .apm-inst-card__wash {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(120% 70% at 50% 18%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, rgba(219, 234, 254, 0.55) 0%, rgba(59, 130, 246, 0.28) 42%, rgba(29, 78, 216, 0.88) 100%);
}

.apm-experts-archive .apm-inst-card--tone-1 .apm-inst-card__wash {
  background:
    radial-gradient(120% 70% at 50% 18%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, rgba(219, 234, 254, 0.55) 0%, rgba(59, 130, 246, 0.28) 42%, rgba(29, 78, 216, 0.9) 100%);
}

.apm-experts-archive .apm-inst-card--tone-2 .apm-inst-card__wash {
  background:
    radial-gradient(120% 70% at 50% 18%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, rgba(224, 231, 255, 0.55) 0%, rgba(99, 102, 241, 0.28) 42%, rgba(67, 56, 202, 0.9) 100%);
}

.apm-experts-archive .apm-inst-card--tone-3 .apm-inst-card__wash {
  background:
    radial-gradient(120% 70% at 50% 18%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, rgba(207, 250, 254, 0.55) 0%, rgba(34, 211, 238, 0.28) 42%, rgba(8, 145, 178, 0.9) 100%);
}

.apm-experts-archive .apm-inst-card--tone-4 .apm-inst-card__wash {
  background:
    radial-gradient(120% 70% at 50% 18%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, rgba(219, 234, 254, 0.55) 0%, rgba(96, 165, 250, 0.3) 42%, rgba(30, 64, 175, 0.9) 100%);
}

.apm-experts-archive .apm-inst-card--tone-5 .apm-inst-card__wash {
  background:
    radial-gradient(120% 70% at 50% 18%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, rgba(224, 242, 254, 0.55) 0%, rgba(56, 189, 248, 0.28) 42%, rgba(2, 132, 199, 0.9) 100%);
}

.apm-experts-archive .apm-inst-card__role {
  position: relative;
  z-index: 3;
  display: block;
  max-width: 92%;
  min-height: 2.5em;
  margin: 0 0 4px;
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1.25;
  color: #1d4ed8;
  text-align: left;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.apm-experts-archive .apm-inst-card__photo {
  position: relative;
  z-index: 2;
  flex: 1 1 auto;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  margin: 0 -8px;
  min-height: 280px;
}

.apm-experts-archive .apm-inst-card__photo img {
  display: block;
  width: 118%;
  max-width: none;
  height: 300px;
  object-fit: cover;
  object-position: center top;
  border-radius: 0;
  -webkit-mask-image: linear-gradient(180deg, #000 62%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 62%, transparent 100%);
  filter: drop-shadow(0 18px 28px rgba(15, 23, 42, 0.28));
}

.apm-experts-archive .apm-inst-card__foot {
  position: relative;
  z-index: 3;
  margin-top: -6px;
  text-align: left;
  width: 100%;
}

.apm-experts-archive .apm-inst-card__name {
  display: block;
  margin-bottom: 8px;
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 10px rgba(15, 23, 42, 0.35);
}

.apm-experts-archive .apm-inst-card__badge {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.45;
  text-transform: uppercase;
  text-align: center;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(6px);
  white-space: normal;
  word-break: break-word;
  overflow: visible;
  min-height: 40px;
}

.apm-experts-archive .apm-pagination {
  margin-top: 40px;
}

@media (max-width: 1100px) {
  .apm-experts-archive__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 800px) {
  .apm-experts-archive__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .apm-experts-archive .apm-inst-card__inner {
    min-height: 400px;
  }

  .apm-experts-archive .apm-inst-card__photo {
    min-height: 240px;
  }

  .apm-experts-archive .apm-inst-card__photo img {
    height: 250px;
  }
}

@media (max-width: 480px) {
  .apm-experts-archive__header {
    padding: 36px 0 28px;
  }

  .apm-experts-archive__content {
    padding: 28px 0 56px;
  }

  .apm-experts-archive__grid {
    grid-template-columns: 1fr;
    max-width: 360px;
    margin: 0 auto;
  }
}
