/* =========================================================
   Professionals Card — Custom Design (Final v3)
   Namespace: rd-
   Mobile-first; enhance on larger screens
   ========================================================= */

/* ---------- Grid wrappers ---------- */
.rd-grid {
  display: grid;
  gap: 16px;
}

/* Profession terms (parent/child) */
.rd-grid--terms {
  grid-template-columns: repeat(2, 1fr);
}

/* Company/professional posts */
.rd-grid--cards {
  grid-template-columns: 1fr;
}

/* ---------- Term (subcategory) card ---------- */
.rd-term-card {
  display: block;
  text-decoration: none;
  background: #fff;
  border: 1px solid #e9e9ee;
  border-radius: 16px;
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
}
.rd-term-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
}
.rd-term-card__img {
  aspect-ratio: 16/9;
  background: #f7f7fb;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rd-term-card__img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.rd-term-card__title {
  margin: 12px 14px 16px;
  color: #111827;
  font-size: 16px;
  line-height: 1.35;
  text-align:center;
}

/* ---------- Main professional card ---------- */
.rd-card {
  position: relative; /* for verified badge */
  background: #fff;
  border: 1px solid #e9e9ee;
  border-radius: 16px;
  overflow: hidden;
  padding: 16px;
  box-shadow: 0 2px 6px rgba(17,24,39,0.05);
  transition: box-shadow .25s ease, transform .25s ease;
}
.rd-card:hover {
  box-shadow: 0 6px 20px rgba(17,24,39,0.08);
  transform: translateY(-2px);
}

/* Top row: logo, headings, badge */
.rd-card__top {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  align-items: center;
  gap: 12px;
}
.rd-card__logo img {
  width: 96px;
  height: 96px;
  object-fit: contain;
}

/* Chips under title */
.rd-card__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 2px;
}
.rd-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  line-height: 1;
  padding: 6px 10px;
  background: #f3f4f6;
  color: #374151;
  border-radius: 999px;
  border: 1px solid #e5e7eb;
  white-space: nowrap;
}

/* Verified badge — top-right corner */
.rd-card__verified {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 13px;
  color: #0e7a3c;
  background: #e8f7ee;
  border: 1px solid #bde7cd;
  padding: 6px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

/* Title + meta */
.rd-card__title {
  font-size: 22px;
  color: #111827;
  line-height: 1.2;
  margin: 6px 0 4px;
}
.rd-card__title a {
  color: inherit;
  text-decoration: none;  /* underline disable */
}
.rd-card__title a:hover {
  color: #0f172a;          /* hover pe sirf color change */
}

/* Firm/Company tab hover fix */
.rd-card__tabs .rd-tab a {
  text-decoration: none;
  color: inherit;
}
.rd-card__tabs .rd-tab a:hover {
  color: #0f172a;          /* sirf color change, no underline */
}

.rd-card__meta {
  display: flex;
  gap: 14px;
  align-items: center;
  margin: 4px 0 8px;
}
.rd-meta__exp {
  font-size: 14px;
  color: #374151;
}

/* Rating (Site Reviews shortcode wrapper) */
.rd-meta__stars {
  font-size: 14px;
  color: #f59e0b;           /* star color */
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.rd-rating-num {
  color: #111827;
  margin-right: 6px;
  font-weight: 600;
}

/* ---------- Tabs row: Firm | City | Contact Info ---------- */
.rd-card__tabs {
  display: flex;
  gap: 18px;
  padding: 10px 0 12px;
  border-top: 1px solid #f1f1f5;
  border-bottom: 1px solid #f1f1f5;
  color: #374151;
  font-size: 14px;
}
.rd-card__tabs .rd-tab {
  display: inline-flex;
  align-items: center;   /* keep icons/text vertically centered */
  gap: 6px;
  position: relative;
}
.rd-card__tabs .rd-tab + .rd-tab::before {
  content: "|";
  position: absolute;
  left: -12px;
  color: #d1d5db;
}

/* ---------- Description (clamped) ---------- */
.rd-card__desc {
  color: #374151;
  font-size: 14px;
  line-height: 1.6;
  margin: 12px 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 5;  /* visual clamp; PHP also trims */
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------- CTA buttons ---------- */
.rd-card__cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 6px;
}
.rd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 16px;
  border-radius: 10px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: transform .15s ease, background .15s ease, color .15s ease, border-color .15s ease;
}
.rd-btn:hover { transform: translateY(-1px); }

/* Dark button */
.rd-btn--dark {
  background: #0f172a;
  color: #fff;
}
.rd-btn--dark:hover {
  background: #1e293b;     /* bg change */
  color: #e5e7eb;          /* text color change */
}

/* Brand button */
.rd-btn--brand {
  background: #ff7a45;
  color: #fff;
}
.rd-btn--brand:hover {
  background: #e86b39;     /* bg change */
  color: #fffbe6;          /* text color change */
}

/* ---------- Generic icon helper (optional) ---------- */
.rd-icon {
  width: 16px;
  height: 16px;
  display: inline-block;
  margin-right: 6px;
  vertical-align: -2px;
}

/* ---------- Responsive ---------- */
@media (min-width: 640px) {
  .rd-grid--terms { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 768px) {
  .rd-grid--cards { grid-template-columns: repeat(2, 1fr); } /* two cards/row */
}
