/**
 * Estilos Rediseñados de Alta Elegancia: Team Box Kidney Care
 * Kidney Care San Martín Child Theme
 * Estilo médico de prestigio, armonía cromática y tipográfica institucional.
 */

.kidney-team-box {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  box-sizing: border-box;
  background: linear-gradient(165deg, #004B9B 0%, #003670 60%, #002652 100%);
  border-radius: 24px;
  padding: 26px 20px 20px 20px;
  box-shadow: 0 16px 36px -6px rgba(0, 38, 82, 0.28), 
              0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1),
              box-shadow 0.4s cubic-bezier(0.165, 0.84, 0.44, 1),
              border-color 0.4s ease;
  overflow: hidden;
  text-align: center;
  z-index: 1;
}

/* Brillo superior sutil de iluminación clínica (Glass reflection) */
.kidney-team-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent 0%, rgba(0, 168, 150, 0.6) 25%, rgba(255, 255, 255, 0.8) 50%, rgba(0, 168, 150, 0.6) 75%, transparent 100%);
  opacity: 0.85;
  transition: opacity 0.4s ease, height 0.4s ease;
  z-index: 2;
}

/* Efecto de resplandor ambiental en esquina */
.kidney-team-box::after {
  content: '';
  position: absolute;
  top: -30px;
  right: -30px;
  width: 120px;
  height: 120px;
  background: radial-gradient(circle, rgba(0, 168, 150, 0.22) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  transition: transform 0.5s ease, opacity 0.5s ease;
}

.kidney-team-box:hover {
  transform: translateY(-8px);
  box-shadow: 0 26px 52px -8px rgba(0, 38, 82, 0.38),
              0 0 0 1px rgba(0, 168, 150, 0.35) inset;
}

.kidney-team-box:hover::before {
  opacity: 1;
  height: 3.5px;
}

.kidney-team-box:hover::after {
  transform: scale(1.3);
  opacity: 0.35;
}

/* 1. Cabecera: Nombre y Credenciales */
.kidney-team-box__header {
  position: relative;
  z-index: 2;
  margin-bottom: 16px;
  width: 100%;
}

.kidney-team-box__name {
  font-family: var(--kc-font-headings, 'Montserrat', sans-serif);
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: #FFFFFF;
  line-height: 1.3;
  margin: 0 0 8px 0;
  text-shadow: 0 2px 4px rgba(0, 20, 50, 0.25);
  transition: color 0.3s ease;
}

/* Credenciales presentadas como distintivo académico refinado */
.kidney-team-box__credentials {
  display: inline-block;
  font-family: var(--kc-font-body, 'Inter', sans-serif);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: #D6ECFB;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 30px;
  padding: 4px 14px;
  line-height: 1.4;
  margin: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.kidney-team-box:hover .kidney-team-box__credentials {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(0, 168, 150, 0.4);
  color: #FFFFFF;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
}

/* 2. Zona Central: Marco de la Fotografía */
.kidney-team-box__photo-wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  background-color: rgba(0, 20, 45, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 10px 24px rgba(0, 20, 45, 0.22);
  line-height: 0;
}

/* Degradado inferior sutil sobre la foto para dar calidez y profundidad */
.kidney-team-box__photo-wrap::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 25%;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 25, 55, 0.35) 100%);
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.3s ease;
}

.kidney-team-box__photo-link {
  display: block;
  width: 100%;
  height: 100%;
  text-decoration: none;
  cursor: pointer;
  overflow: hidden;
}

.kidney-team-box__photo {
  width: 100%;
  height: 330px;
  max-height: 370px;
  object-fit: cover;
  object-position: top center;
  display: block;
  transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1), filter 0.4s ease;
}

.kidney-team-box__photo-link:hover .kidney-team-box__photo,
.kidney-team-box:hover .kidney-team-box__photo {
  transform: scale(1.04);
}

/* 3. Zona Inferior: Barra de Redes Sociales y Bandera */
.kidney-team-box__footer {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  width: 100%;
  box-sizing: border-box;
}

.kidney-team-box__footer--center {
  justify-content: center;
}

/* Redes Sociales */
.kidney-team-box__social-list {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
  flex-wrap: wrap;
}

.kidney-team-box__social-item {
  margin: 0;
  padding: 0;
}

.kidney-team-box__social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #FFFFFF;
  color: var(--kc-primary, #004B9B);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(255, 255, 255, 0.4);
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  font-size: 15px;
  flex-shrink: 0;
}

.kidney-team-box__social-link svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
  transition: fill 0.3s ease, transform 0.3s ease;
}

.kidney-team-box__social-link:hover,
.kidney-team-box__social-link:focus {
  background: linear-gradient(135deg, var(--kc-accent, #008B8B) 0%, var(--kc-accent-light, #00A896) 100%);
  color: #FFFFFF;
  transform: translateY(-3px) scale(1.08);
  box-shadow: 0 8px 18px rgba(0, 168, 150, 0.4), 0 0 0 2px rgba(255, 255, 255, 0.6);
}

.kidney-team-box__social-link:hover svg {
  fill: #FFFFFF;
  transform: scale(1.1);
}

/* Bandera de Nacionalidad */
.kidney-team-box__flag-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border-radius: 6px;
  padding: 2px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.kidney-team-box__flag-img {
  width: 38px;
  height: 25px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.25);
  display: block;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.kidney-team-box:hover .kidney-team-box__flag-wrap {
  transform: scale(1.06);
  border-color: rgba(0, 168, 150, 0.4);
}

/* Responsividad */
@media (max-width: 767px) {
  .kidney-team-box {
    padding: 22px 16px 18px 16px;
    border-radius: 20px;
  }
  .kidney-team-box__name {
    font-size: 1.18rem;
  }
  .kidney-team-box__credentials {
    font-size: 0.78rem;
    padding: 3px 11px;
  }
  .kidney-team-box__photo {
    height: 290px;
  }
  .kidney-team-box__social-link {
    width: 34px;
    height: 34px;
    font-size: 14px;
  }
  .kidney-team-box__social-link svg {
    width: 13px;
    height: 13px;
  }
  .kidney-team-box__flag-img {
    width: 34px;
    height: 22px;
  }
}
