/* متغیرهای رنگی پایه تعریف شده توسط شما */
:root {
  --palette-primary: #00967D;
  --palette-primary-tint: #DCF6F1;
  --palette-ink: #434343;
  --palette-gray-mid: #BBBBBB;
  --palette-gray-light: #EBEBEB;
  --palette-gray-lighter: #F5F5F5;
  --palette-surface: #FCFCFC;
  --palette-white: #FFFFFF;
  --palette-dark-bg: #161616;
  --palette-dark-surface: #303030;
  --palette-dark-elevated: #232323;

  /* متغیرهای معنایی حالت لایت */
  --author-card-bg: var(--palette-surface);
  --author-card-border: var(--palette-gray-light);
  --author-text-primary: var(--palette-ink);
  --author-text-muted: #6b7280;
  --author-tag-bg: var(--palette-primary-tint);
  --author-tag-text: var(--palette-primary);
  --author-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.05);
}

/* اعمال متغیرها برای حالت دارک [data-theme=dark] */
[data-theme="dark"] {
  --author-card-bg: var(--palette-dark-elevated);
  --author-card-border: var(--palette-dark-surface);
  --author-text-primary: var(--palette-white);
  --author-text-muted: var(--palette-gray-mid);
  --author-tag-bg: rgba(0, 150, 125, 0.15);
  --author-tag-text: #4ed9c0;
  --author-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.35);
}

/* ساختار بخش نویسندگان */
.article-authors-section {
  margin: 40px 0 20px;
  font-family: inherit;
}

.authors-header {
  margin-bottom: 20px;
}

.authors-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--author-text-primary);
  margin: 0;
}

.authors-title .icon-title {
  width: 22px;
  height: 22px;
  stroke: var(--palette-primary);
}

/* شبکه کارت‌ها (پشتیبانی از تک و چند نویسنده) */
.authors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
  margin-top: 15px;
}

/* بدنه کارت */
.author-card {
  background-color: var(--author-card-bg);
  border: 1px solid var(--author-card-border);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--author-shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, border-color 0.25s ease;
  margin-top: 15px;
}

.author-card:hover {
  transform: translateY(-2px);
  border-color: var(--palette-primary);
}

/* هدر کارت: آواتار و مشخصات اصلی */
.author-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.author-avatar-wrapper {
  position: relative;
  width: 68px;
  height: 68px;
  flex-shrink: 0;
}

.author-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--palette-primary);
}

/* بج تأیید وکیل */
.verified-badge {
  position: absolute;
  bottom: 0;
  left: 0;
  background-color: var(--palette-primary);
  color: #fff;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--author-card-bg);
}

.verified-badge svg {
  width: 12px;
  height: 12px;
}

/* اطلاعات متنی بالای کارت */
.author-meta {
  flex-grow: 1;
}

.author-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.author-name {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.author-name a {
  color: var(--author-text-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.author-name a:hover {
  color: var(--palette-primary);
}

.experience-badge {
  font-size: 0.75rem;
  background: rgba(0, 150, 125, 0.08);
  color: var(--palette-primary);
  padding: 3px 8px;
  border-radius: 20px;
  font-weight: 600;
}

.author-degree {
  margin: 0;
  font-size: 0.85rem;
  color: var(--author-text-muted);
}

/* تخصص‌ها */
.author-specialties {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.specialty-tag {
  background-color: var(--author-tag-bg);
  color: var(--author-tag-text);
  font-size: 0.78rem;
  padding: 4px 10px;
  border-radius: 8px;
  font-weight: 500;
}

/* بیوگرافی کوتاه */
.author-bio {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--author-text-muted);
  margin: 0 0 16px 0;
  display: -webkit-box;
  -webkit-line-clamp: 3; /* حداکثر ۳ خط متن نمایش داده شود */
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* دکمه مشاهده پروفایل */
.author-footer {
  margin-top: auto;
  border-top: 1px dashed var(--author-card-border);
  padding-top: 14px;
}

.btn-profile {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--palette-primary);
  text-decoration: none;
  transition: gap 0.2s ease;
}

.btn-profile svg {
  width: 16px;
  height: 16px;
  transition: transform 0.2s ease;
}

.btn-profile:hover {
  opacity: 0.85;
}

.btn-profile:hover svg {
  transform: translateX(-4px); /* انیمیشن فلش به سمت چپ در حالت RTL */
}

/* بهینه‌سازی برای موبایل */
@media (max-width: 480px) {
  .authors-grid {
    grid-template-columns: 1fr;
  }
  .author-header {
    align-items: flex-start;
  }
  .author-name-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
}
.bold{
    font-weight: 900;
  margin: 10px 0;
}
