/**
 * KDF shortcode styles (shared for Medexly)
 * For [top_doctors layout="location-specialists"], [top_doctors layout="table"],
 * [dab-location-specialists], and [dab-top-doctors-table-location].
 * Supports light and dark mode.
 */

.kdf-specialists-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 25px;
  border-top: 1px solid rgba(226, 232, 240, 0.32);
  padding-top: 20px;
}

.dark .kdf-specialists-container {
  border-top-color: rgba(55, 65, 81, 0.5);
}

.kdf-specialist-link {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f0f9ff;
  color: #0369a1;
  padding: 5px 15px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid #bae6fd !important;
  transition: all 0.2s ease;
  width: 100%;
  justify-content: center;
}

.kdf-specialist-link:hover {
  background: #e0f2fe;
  color: #0284c7;
}

.dark .kdf-specialist-link {
  background: rgba(12, 74, 110, 0.3);
  color: #7dd3fc;
  border-color: #0c4a6e;
}

.dark .kdf-specialist-link:hover {
  background: rgba(12, 74, 110, 0.5);
  color: #bae6fd;
}

.kdf-specialist-count {
  background: #dbeafe;
  color: #1e40af;
  padding: 2px 8px;
  border-radius: 9999px;
  font-size: 12px;
}

.dark .kdf-specialist-count {
  background: rgba(30, 64, 175, 0.4);
  color: #93c5fd;
}

.kdf-female-specialist-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #faf5ff;
  color: #6b21a8;
  padding: 8px 12px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid #d8b4fe;
  transition: opacity 0.2s ease;
}

.kdf-female-specialist-link:hover {
  opacity: 0.9;
}

.dark .kdf-female-specialist-link {
  background: rgba(88, 28, 135, 0.3);
  color: #e9d5ff;
  border-color: #6b21a8;
}

.kdf-female-specialist-count {
  font-size: 12px;
  opacity: 0.9;
}

.kdf-top-doctors-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  background: white;
  border-radius: 12px;
  overflow: hidden;
}

.dark .kdf-top-doctors-table {
  background: #1f2937;
  color: #f9fafb;
}

.kdf-table-header th {
  padding: 16px 12px;
  text-align: left;
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: none;
}

.kdf-table-body {
  background: white;
}

.dark .kdf-table-body {
  background: #1f2937;
}

.kdf-table-row {
  border-bottom: 1px solid #f3f4f6;
  transition: all 0.2s ease;
}

.kdf-table-row:nth-child(odd) {
  background-color: rgba(245, 245, 245, 0.56);
}

.dark .kdf-table-row:nth-child(odd) {
  background-color: rgba(31, 41, 55, 0.8);
}

.kdf-table-row:hover {
  background-color: #f8fafc;
}

.dark .kdf-table-row:hover {
  background-color: #111827;
}

.kdf-table-row:last-child {
  border-bottom: none;
}

.dark .kdf-table-row {
  border-bottom-color: #374151;
}

.kdf-col-rank {
  width: 60px;
  text-align: center;
  font-weight: 700;
  color: #0f766e;
  font-size: 18px;
}

.dark .kdf-col-rank {
  color: #5eead4;
}

.kdf-col-doctor {
  min-width: 280px;
  padding: 16px 12px;
}

.kdf-col-specialty {
  min-width: 150px;
  font-weight: 500;
  color: #0f766e;
}

.dark .kdf-col-specialty {
  color: #5eead4;
}

.kdf-col-action {
  width: 140px;
  text-align: center;
}

.kdf-doctor-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.kdf-doctor-avatar {
  flex-shrink: 0;
}

.kdf-avatar-img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #ccfbf1;
  transition: transform 0.2s ease;
}

.kdf-avatar-img:hover {
  border-color: #5eead4;
}

.kdf-avatar-placeholder {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #d1d5db;
}

.dark .kdf-avatar-placeholder {
  background: linear-gradient(135deg, #134e4a 0%, #115e59 100%);
  border-color: #0f766e;
}

.kdf-avatar-icon {
  width: 24px;
  height: 24px;
  color: #9ca3af;
}

.dark .kdf-avatar-icon {
  color: #5eead4;
}

.kdf-doctor-details {
  flex: 1;
  min-width: 0;
}

.kdf-doctor-name {
  margin: 5px 0;
  font-size: 18px !important;
  font-weight: 700;
  line-height: 1.2;
}

.kdf-doctor-name a {
  border-bottom: none;
}

.kdf-doctor-link {
  color: #0f766e;
  text-decoration: none;
  transition: color 0.2s ease;
}

.kdf-doctor-link:hover {
  color: #115e59;
}

.dark .kdf-doctor-link {
  color: #5eead4;
}

.dark .kdf-doctor-link:hover {
  color: #99f6e4;
}

.kdf-doctor-designation {
  margin: 0px !important;
  font-size: 16px !important;
  color: #374151;
  font-weight: 600;
  line-height: 1.3;
}

.dark .kdf-doctor-designation {
  color: #d1d5db;
}

.kdf-doctor-hospital {
  margin: 0px !important;
  font-size: 15px !important;
  color: #6b7280;
  font-weight: 500;
  line-height: 1.3;
}

.dark .kdf-doctor-hospital {
  color: #9ca3af;
}

.kdf-action-link {
  display: inline-block;
  padding: 8px 16px;
  background: linear-gradient(135deg, #14b8a6 0%, #0d9488 100%);
  color: #fff !important;
  text-decoration: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
}

.kdf-action-link:hover {
  background: linear-gradient(135deg, #0d9488 0%, #115e59 100%);
  color: #fff !important;
}

.kdf-no-results-message {
  text-align: center;
  color: #6b7280;
  font-style: italic;
  padding: 40px 20px;
  font-size: 16px;
}

.dark .kdf-no-results-message {
  color: #9ca3af;
}

@media (max-width: 768px) {
  .kdf-top-doctors-table {
    font-size: 14px;
  }

  .kdf-col-doctor {
    min-width: 200px;
    padding: 12px 8px;
  }

  .kdf-avatar-img,
  .kdf-avatar-placeholder {
    width: 48px;
    height: 48px;
  }

  .kdf-doctor-name {
    font-size: 16px;
  }

  .kdf-doctor-designation,
  .kdf-doctor-hospital {
    font-size: 12px;
  }

  .kdf-action-link {
    padding: 6px 12px;
    font-size: 12px;
  }

  .kdf-col-action {
    display: none;
  }
}

@media (max-width: 640px) {
  .kdf-top-doctors-table {
    font-size: 13px;
  }

  .kdf-col-rank {
    width: 40px;
    font-size: 16px;
  }

  .kdf-col-specialty {
    display: none;
  }

  .kdf-col-doctor {
    min-width: 150px;
  }

  .kdf-doctor-info {
    gap: 8px;
  }

  .kdf-avatar-img,
  .kdf-avatar-placeholder {
    width: 40px;
    height: 40px;
  }

  .kdf-doctor-name {
    font-size: 14px;
  }
}

