/**
 * منى للدهانات - تنسيقات صفحة المدونة
 * ==================================================
 * 
 * المتغيرات الرئيسية:
 * --primary-gold: #d4a046 (اللون الذهبي الرئيسي)
 * --primary-navy: #1f2b44 (اللون الكحلي الرئيسي)
 * --section-padding: clamp(3rem, 5vw, 5rem) (المساحات العمودية للأقسام)
 * --transition-base: 0.3s (سرعة التأثيرات الانتقالية)
 * --border-radius: 8px (زوايا العناصر المدورة)
 */

:root {
  /* الألوان الأساسية */
  --primary-gold: #d4a046;
  --primary-gold-light: #e4b056;
  --primary-gold-dark: #c49036;
  --primary-navy: #1f2b44;
  --primary-navy-light: #24365b;
  --primary-navy-dark: #1a2338;

  /* الألوان التكميلية */
  --success: #22c55e;
  --danger: #ef4444;
  --warning: #f59e0b;
  --info: #3b82f6;

  /* خلفيات وألوان النص */
  --light-bg: #ffffff;
  --light-bg-alt: #f8f9fa;
  --light-bg-card: #ffffff;
  --light-text: #1f2b44;
  --light-text-muted: #6c757d;

  --dark-bg: #1f2b44;
  --dark-bg-alt: #1a2338;
  --dark-bg-card: #24365b;
  --dark-text: #ffffff;
  --dark-text-muted: #cbd5e1;

  /* الخطوط */
  --font-primary: "Cairo", sans-serif;
  --font-secondary: "Tajawal", sans-serif;

  /* الزوايا */
  --border-radius-sm: 4px;
  --border-radius: 8px;
  --border-radius-lg: 16px;
  --border-radius-xl: 24px;
  --border-radius-circle: 50%;

  /* المساحات */
  --section-padding: clamp(3rem, 5vw, 5rem);
  --grid-gap: 1.5rem;

  /* الظلال */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 6px 10px rgba(0, 0, 0, 0.08), 0 0 6px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 15px 20px rgba(0, 0, 0, 0.1);
  --shadow-float: 0 8px 15px rgba(0, 0, 0, 0.15);

  /* الانتقالات */
  --transition-fast: 0.2s;
  --transition-base: 0.3s;
  --transition-slow: 0.5s;
  --transition-timing: cubic-bezier(0.4, 0, 0.2, 1);
}

/* تطبيق المتغيرات حسب الوضع (فاتح/داكن) */
:root,
[data-bs-theme="light"] {
  --body-bg: var(--light-bg);
  --body-bg-alt: var(--light-bg-alt);
  --body-text: var(--light-text);
  --body-text-muted: var(--light-text-muted);
  --card-bg: var(--light-bg-card);
  --border-color: rgba(0, 0, 0, 0.1);
}

[data-bs-theme="dark"] {
  --body-bg: var(--dark-bg);
  --body-bg-alt: var(--dark-bg-alt);
  --body-text: var(--dark-text);
  --body-text-muted: var(--dark-text-muted);
  --card-bg: var(--dark-bg-card);
  --border-color: rgba(255, 255, 255, 0.1);
}

/* ===== ضبط عام ===== */
body {
  font-family: var(--font-primary);
  background-color: var(--body-bg);
  color: var(--body-text);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-secondary);
  font-weight: 700;
  color: var(--body-text);
  line-height: 1.3;
}

a {
  color: var(--primary-gold);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--primary-gold-dark);
}

img {
  max-width: 100%;
  height: auto;
}

.section-padding {
  padding: var(--section-padding) 0;
}

/* تعريف مخصص لـ text-primary */
.text-primary {
  color: var(--primary-gold) !important;
}

/* تعريف مخصص لـ btn-primary */
.btn-primary {
  background-color: var(--primary-gold);
  border-color: var(--primary-gold);
  color: white;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: var(--primary-gold-dark);
  border-color: var(--primary-gold-dark);
  color: white;
}

.btn-outline-primary {
  border-color: var(--primary-gold);
  color: var(--primary-gold);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background-color: var(--primary-gold);
  border-color: var(--primary-gold);
  color: white;
}

/* ===== قسم البطاقة الرئيسية (Hero) ===== */
.blog-hero {
  position: relative;
  margin-bottom: 3rem;
}

.blog-hero-bg {
  position: relative;
  background-size: cover;
  background-position: center;
  min-height: 500px;
  padding: 100px 0;
}

.blog-hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    120deg,
    rgba(31, 43, 68, 0.85),
    rgba(31, 43, 68, 0.7)
  );
}

.blog-hero-content {
  position: relative;
  z-index: 1;
  color: white;
  padding: 2rem 0;
}

.breadcrumb {
  background-color: rgba(255, 255, 255, 0.1);
  display: inline-flex;
  padding: 0.5rem 1rem;
  border-radius: 50px;
  margin-bottom: 1.5rem;
}

.breadcrumb-item + .breadcrumb-item::before {
  color: rgba(255, 255, 255, 0.6);
}

.breadcrumb a {
  color: white;
  font-weight: 500;
}

.breadcrumb a:hover {
  color: var(--primary-gold);
}

.breadcrumb-item.active {
  color: var(--primary-gold);
}

.blog-hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  margin-bottom: 1.25rem;
  color: white;
}

.blog-hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  margin-bottom: 2rem;
  max-width: 700px;
  opacity: 0.9;
}

.blog-hero-search {
  max-width: 550px;
  margin-bottom: 2rem;
}

.blog-hero-search .form-control {
  height: 54px;
  padding: 0.75rem 1.5rem;
  border-top-right-radius: var(--border-radius);
  border-bottom-right-radius: var(--border-radius);
  border: none;
  font-size: 1rem;
}

.blog-hero-search .btn {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  font-weight: 600;
  border-top-left-radius: var(--border-radius);
  border-bottom-left-radius: var(--border-radius);
}

.blog-hero-search .btn i {
  margin-left: 0.5rem;
}

.blog-hero-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.category-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all var(--transition-base);
}

.category-pill:hover {
  background-color: rgba(255, 255, 255, 0.2);
  color: white;
}

.category-pill.active {
  background-color: var(--primary-gold);
  color: white;
}

.category-pill i {
  font-size: 0.875rem;
}

.blog-hero-image {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.blog-hero-image img {
  max-height: 400px;
  width: auto;
}

/* ===== فلاتر المدونة ===== */
.blog-filters-wrapper {
  margin-bottom: 2.5rem;
}

.blog-search-results-info {
  margin-bottom: 1.5rem;
}

.search-info-card {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  padding: 1.5rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.search-info-icon {
  width: 60px;
  height: 60px;
  border-radius: var(--border-radius-circle);
  background-color: rgba(212, 160, 70, 0.1);
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.search-info-content {
  flex-grow: 1;
}

.search-info-title {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.search-info-meta {
  color: var(--body-text-muted);
  font-size: 0.95rem;
  margin-bottom: 0;
}

.search-actions {
  margin-top: 1rem;
}

.btn-outline-primary {
  padding: 0.5rem 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: var(--border-radius);
  transition: all var(--transition-base);
}

/* Advanced Categories */
.advanced-categories {
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  padding: 1.25rem;
  margin-bottom: 2rem;
  border: 1px solid var(--border-color);
}

.categories-scroll {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding: 0.5rem 0.25rem;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-gold) var(--body-bg-alt);
}

.categories-scroll::-webkit-scrollbar {
  height: 5px;
}

.categories-scroll::-webkit-scrollbar-track {
  background: var(--body-bg-alt);
}

.categories-scroll::-webkit-scrollbar-thumb {
  background-color: var(--primary-gold);
  border-radius: 10px;
}

.category-button {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  color: var(--body-text);
  font-weight: 500;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  transition: all var(--transition-base);
  flex-shrink: 0;
}

.category-button:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  color: var(--primary-gold);
}

.category-button.active {
  background-color: var(--primary-gold);
  color: white;
  border-color: var(--primary-gold);
}

.category-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--border-radius-circle);
  background-color: rgba(212, 160, 70, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-gold);
  font-size: 0.875rem;
}

.category-button.active .category-icon {
  background-color: rgba(255, 255, 255, 0.2);
  color: white;
}

.category-name {
  font-size: 0.95rem;
}

.category-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: var(--border-radius-circle);
  background-color: var(--body-bg-alt);
  color: var(--body-text-muted);
  font-size: 0.75rem;
  font-weight: 700;
}

.category-button.active .category-count {
  background-color: white;
  color: var(--primary-gold);
}

/* ===== تخطيط المدونة ===== */
.blog-layout {
  margin-bottom: 3rem;
}

/* ===== مقالات المدونة ===== */
.no-posts {
  padding: 4rem 2rem;
  text-align: center;
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  margin-bottom: 2rem;
  border: 1px solid var(--border-color);
}

.no-posts-icon {
  font-size: 4rem;
  color: var(--body-text-muted);
  margin-bottom: 1.5rem;
}

.no-posts-title {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  color: var(--body-text);
}

.no-posts-message {
  font-size: 1.1rem;
  color: var(--body-text-muted);
  max-width: 600px;
  margin: 0 auto 1.5rem;
}

.no-posts-actions {
  margin-top: 1.5rem;
}

/* ===== المقالة المميزة ===== */
.featured-post {
  margin-bottom: 2.5rem;
}

.featured-post-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
}

.featured-post-image {
  position: relative;
  height: 400px;
}

.featured-post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(212, 160, 70, 0.1);
  color: var(--primary-gold);
  font-size: 3rem;
}

.featured-badge {
  position: absolute;
  top: 20px;
  left: 20px;
  background-color: var(--primary-gold);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius-lg);
  font-size: 0.875rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow);
}

.featured-post-content {
  padding: 2rem;
}

.post-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
  color: var(--body-text-muted);
  font-size: 0.875rem;
}

.post-meta a {
  color: var(--primary-gold);
}

.post-meta a:hover {
  text-decoration: underline;
}

.post-category {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.post-date {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.post-views {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.post-title {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  font-weight: 700;
  line-height: 1.3;
}

.post-title a {
  color: var(--body-text);
  transition: color var(--transition-base);
}

.post-title a:hover {
  color: var(--primary-gold);
}

.post-excerpt {
  color: var(--body-text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.post-author {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--border-radius-circle);
  overflow: hidden;
}

.author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar-placeholder {
  width: 100%;
  height: 100%;
  background-color: var(--primary-navy);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: 700;
}

.author-info {
  display: flex;
  flex-direction: column;
}

.author-name {
  font-weight: 600;
  color: var(--body-text);
  margin-bottom: 0.25rem;
}

.author-role {
  font-size: 0.875rem;
  color: var(--body-text-muted);
}

.post-actions {
  margin-left: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  padding: 0.625rem 1.25rem;
  border-radius: var(--border-radius);
  transition: all var(--transition-base);
}

/* ===== شبكة المقالات ===== */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.blog-card {
  height: 100%;
}

.blog-card-inner {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
  height: 100%;
  transition: all var(--transition-base);
  display: flex;
  flex-direction: column;
}

.blog-card-inner:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.blog-card-image {
  position: relative;
  height: 200px;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-base);
}

.blog-card-inner:hover .blog-card-image img {
  transform: scale(1.1);
}

.image-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to top,
    rgba(31, 43, 68, 0.7),
    rgba(31, 43, 68, 0) 50%
  );
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

.blog-card-inner:hover .image-overlay {
  opacity: 1;
}

.read-more {
  width: 40px;
  height: 40px;
  border-radius: var(--border-radius-circle);
  background-color: var(--primary-gold);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(20px);
  transition: all var(--transition-base) 0.1s;
  opacity: 0;
}

.blog-card-inner:hover .read-more {
  transform: translateY(0);
  opacity: 1;
}

.post-category-badge {
  position: absolute;
  bottom: 15px;
  left: 15px;
  background-color: var(--primary-gold);
  color: white;
  padding: 0.3rem 0.75rem;
  border-radius: var(--border-radius);
  font-size: 0.75rem;
  font-weight: 600;
  z-index: 2;
  transition: all var(--transition-base);
}

.post-category-badge:hover {
  background-color: var(--primary-gold-dark);
  color: white;
}

.blog-card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-card-content .post-meta {
  margin-bottom: 0.75rem;
}

.blog-card-content .post-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.blog-card-content .post-excerpt {
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.post-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.read-more-link {
  color: var(--primary-gold);
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all var(--transition-base);
}

.read-more-link:hover {
  color: var(--primary-gold-dark);
}

.post-share-dropdown {
  position: relative;
}

.share-button {
  width: 36px;
  height: 36px;
  border-radius: var(--border-radius-circle);
  background-color: rgba(212, 160, 70, 0.1);
  color: var(--primary-gold);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

.share-button:hover {
  background-color: var(--primary-gold);
  color: white;
}

.share-dropdown-content {
  position: absolute;
  bottom: 100%;
  right: 0;
  background-color: var(--card-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 0.5rem;
  margin-bottom: 0.5rem;
  display: flex;
  gap: 0.5rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all var(--transition-base);
  z-index: 10;
  border: 1px solid var(--border-color);
}

.post-share-dropdown:hover .share-dropdown-content {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.share-link {
  width: 32px;
  height: 32px;
  border-radius: var(--border-radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transition: all var(--transition-base);
}

.share-link:hover {
  transform: scale(1.1);
  color: white;
}

.share-link.facebook {
  background-color: #3b5998;
}

.share-link.twitter {
  background-color: #1da1f2;
}

.share-link.whatsapp {
  background-color: #25d366;
}

/* ===== التصفح ===== */
.blog-pagination {
  margin-top: 3rem;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
}

.page-item {
  margin: 0 0.1rem;
}

.page-link {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
  color: var(--body-text);
  transition: all var(--transition-base);
  font-weight: 600;
  background-color: var(--card-bg);
}

.page-link:hover {
  background-color: rgba(212, 160, 70, 0.1);
  color: var(--primary-gold);
  border-color: var(--primary-gold);
}

.page-item.active .page-link {
  background-color: var(--primary-gold);
  color: white;
  border-color: var(--primary-gold);
}

.page-item.disabled .page-link {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ===== الشريط الجانبي ===== */
.blog-sidebar {
  position: sticky;
  top: 100px;
}

.sidebar-widget {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
}

.widget-title {
  position: relative;
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
  font-weight: 700;
}

.widget-title::after {
  content: "";
  position: absolute;
  bottom: -1px;
  right: 0;
  width: 50px;
  height: 3px;
  background-color: var(--primary-gold);
  border-radius: 3px;
}

/* ===== البحث ===== */
.sidebar-search-form {
  position: relative;
}

.sidebar-search-form .form-control {
  height: 50px;
  padding: 0.75rem 1rem 0.75rem 3rem;
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
  color: var(--body-text);
  font-size: 0.95rem;
  background-color: var(--body-bg);
  transition: all var(--transition-base);
}

.sidebar-search-form .form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(212, 160, 70, 0.15);
}

.sidebar-search-form .btn {
  position: absolute;
  left: 0;
  top: 0;
  height: 50px;
  width: 50px;
  border-radius: var(--border-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
}

/* ===== الفئات ===== */
.categories-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.category-item {
  margin-bottom: 0.75rem;
}

.category-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background-color: var(--body-bg);
  border-radius: var(--border-radius);
  color: var(--body-text);
  transition: all var(--transition-base);
  border: 1px solid var(--border-color);
}

.category-link:hover {
  background-color: rgba(212, 160, 70, 0.05);
  color: var(--primary-gold);
  transform: translateX(-5px);
}

.category-link.active {
  background-color: var(--primary-gold);
  color: white;
  border-color: var(--primary-gold);
}

.category-link .category-name {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.category-link .category-name i {
  width: 24px;
  text-align: center;
}

/* ===== المقالات الشائعة ===== */
.popular-post {
  display: flex;
  align-items: flex-start;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-color);
  gap: 1rem;
  position: relative;
}

.popular-post:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.popular-post:first-child {
  padding-top: 0;
}

.post-number {
  position: absolute;
  top: 0.5rem;
  right: 0;
  width: 20px;
  height: 20px;
  background-color: var(--primary-gold);
  color: white;
  border-radius: var(--border-radius-circle);
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.post-image {
  width: 80px;
  height: 80px;
  border-radius: var(--border-radius);
  overflow: hidden;
  flex-shrink: 0;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-placeholder-small {
  width: 100%;
  height: 100%;
  background-color: rgba(212, 160, 70, 0.1);
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.post-info {
  flex-grow: 1;
}

.post-info .post-title {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.post-info .post-meta {
  font-size: 0.75rem;
  margin-bottom: 0;
}

/* ===== آخر المقالات ===== */
.recent-posts-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.recent-post {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-color);
}

.recent-post:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.recent-post:first-child {
  padding-top: 0;
}

.post-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--border-radius);
  background-color: rgba(212, 160, 70, 0.1);
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.recent-post .post-title {
  font-size: 0.95rem;
  margin-bottom: 0.35rem;
}

.recent-post .post-meta {
  font-size: 0.75rem;
  margin-bottom: 0;
  display: flex;
  gap: 1rem;
}

/* ===== الوسوم ===== */
.tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  background-color: var(--body-bg);
  border-radius: var(--border-radius);
  color: var(--body-text);
  font-size: 0.85rem;
  transition: all var(--transition-base);
  border: 1px solid var(--border-color);
}

.tag-link:hover {
  background-color: var(--primary-gold);
  color: white;
  border-color: var(--primary-gold);
}

.tag-count {
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background-color: rgba(0, 0, 0, 0.1);
  border-radius: var(--border-radius-circle);
}

.tag-link:hover .tag-count {
  background-color: rgba(255, 255, 255, 0.2);
}

/* ===== النشرة البريدية ===== */
.newsletter-card {
  background-color: var(--primary-navy);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  padding: 1.5rem;
  text-align: center;
  color: white;
  position: relative;
  z-index: 1;
}

.newsletter-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M36 0H24v12h-12v12h12v12h12V24h12V12H36z' fill='%23ffffff' fill-opacity='0.03'/%3E%3C/svg%3E");
  z-index: -1;
}

.newsletter-icon {
  width: 60px;
  height: 60px;
  border-radius: var(--border-radius-circle);
  background-color: rgba(212, 160, 70, 0.2);
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin: 0 auto 1rem;
}

.newsletter-title {
  color: white;
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.newsletter-description {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 1.25rem;
  font-size: 0.95rem;
}

.newsletter-form {
  margin-bottom: 1rem;
}

.newsletter-form .form-control {
  height: 48px;
  margin-bottom: 1rem;
  border-radius: var(--border-radius);
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
}

.newsletter-form .form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(212, 160, 70, 0.15);
}

.newsletter-form .form-control::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.newsletter-privacy {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}

/* ===== CTA Widget ===== */
.cta-card {
  background-color: var(--primary-navy-light);
  background-image: linear-gradient(
    135deg,
    var(--primary-navy-light) 0%,
    var(--primary-navy) 100%
  );
  border-radius: var(--border-radius-lg);
  padding: 2rem 1.5rem;
  text-align: center;
  color: white;
}

.cta-title {
  color: white;
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.cta-text {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 1.5rem;
}

/* ===== قسم الاشتراك ===== */
.subscribe-section {
  margin-top: 3rem;
  margin-bottom: -2rem;
}

.subscribe-bg {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 4rem 0;
  border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
  overflow: hidden;
}

.subscribe-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(31, 43, 68, 0.85);
}

.subscribe-content {
  position: relative;
  z-index: 1;
  color: white;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.subscribe-icon {
  width: 80px;
  height: 80px;
  border-radius: var(--border-radius-circle);
  background-color: rgba(212, 160, 70, 0.2);
  color: var(--primary-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 1.5rem;
}

.subscribe-title {
  color: white;
  margin-bottom: 1rem;
  font-size: 2rem;
}

.subscribe-text {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

.subscribe-form {
  max-width: 500px;
  margin: 0 auto;
}

.subscribe-form .form-control {
  height: 54px;
  border-top-right-radius: var(--border-radius);
  border-bottom-right-radius: var(--border-radius);
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  padding-left: 1.5rem;
}

.subscribe-form .form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 3px rgba(212, 160, 70, 0.15);
}

.subscribe-form .form-control::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.subscribe-form .btn {
  padding-right: 1.5rem;
  padding-left: 1.5rem;
  border-top-left-radius: var(--border-radius);
  border-bottom-left-radius: var(--border-radius);
  font-weight: 600;
}

/* ===== زر العودة للأعلى ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  left: 30px;
  width: 50px;
  height: 50px;
  border-radius: var(--border-radius-circle);
  background-color: var(--primary-gold);
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  box-shadow: var(--shadow-float);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-base);
  z-index: 999;
  cursor: pointer;
}

.back-to-top.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background-color: var(--primary-gold-dark);
  transform: translateY(-5px);
}

/* ===== Modal النشرة البريدية ===== */
.modal-content {
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  border: none;
}

.modal-header {
  background-color: var(--primary-gold);
  color: white;
  border: none;
}

.modal-title {
  font-weight: 700;
}

.success-icon {
  font-size: 3rem;
  color: var(--success);
  margin-bottom: 1rem;
}

/* ===== تخصيصات الوضع الداكن ===== */
[data-bs-theme="dark"] .search-info-card {
  background-color: var(--dark-bg-alt);
}

[data-bs-theme="dark"] .category-button {
  background-color: var(--dark-bg-alt);
}

[data-bs-theme="dark"] .post-placeholder {
  background-color: rgba(212, 160, 70, 0.2);
}

[data-bs-theme="dark"] .post-placeholder-small {
  background-color: rgba(212, 160, 70, 0.2);
}

/* ===== التجاوب مع الشاشات المختلفة ===== */
@media (max-width: 1199px) {
  .blog-hero-content {
    padding: 1rem 0;
  }

  .blog-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  }
}

@media (max-width: 991px) {
  .blog-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  }

  .featured-post-image {
    height: 350px;
  }

  .blog-sidebar {
    margin-top: 3rem;
  }
}

@media (max-width: 767px) {
  .blog-hero-bg {
    min-height: 400px;
    padding: 80px 0 40px;
  }

  .blog-hero-title {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
  }

  .featured-post-image {
    height: 300px;
  }

  .blog-grid {
    grid-template-columns: repeat(auto-fill, minmax(100%, 1fr));
  }

  .post-author {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  .subscribe-title {
    font-size: 1.75rem;
  }

  .subscribe-form .input-group {
    flex-direction: column;
  }

  .subscribe-form .form-control {
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
  }

  .subscribe-form .btn {
    border-radius: var(--border-radius);
    width: 100%;
  }
}

@media (max-width: 575px) {
  .blog-hero-bg {
    padding: 60px 0 30px;
    min-height: 350px;
  }

  .blog-hero-categories {
    display: none;
  }

  .featured-post-image {
    height: 250px;
  }

  .featured-post-content {
    padding: 1.5rem;
  }

  .post-meta {
    gap: 0.75rem;
  }

  .blog-card-image {
    height: 180px;
  }

  .back-to-top {
    width: 40px;
    height: 40px;
    bottom: 20px;
    left: 20px;
    font-size: 1rem;
  }
}
/* ===== صفحة المقالة المنفردة ===== */

/* رأس المقالة */
.post-header {
  position: relative;
  margin-bottom: 2rem;
}

.post-header-bg {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 100px 0 50px;
}

.post-header-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(31, 43, 68, 0.9),
    rgba(31, 43, 68, 0.7)
  );
}

.post-header-content {
  position: relative;
  z-index: 1;
  color: white;
  padding: 2rem 0;
}

.post-title {
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  margin-bottom: 1.5rem;
  font-weight: 800;
  color: white;
  line-height: 1.3;
}

.post-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.meta-category {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.75rem;
  border-radius: var(--border-radius);
  background-color: var(--category-color, var(--primary-gold));
  color: white;
  font-weight: 500;
  font-size: 0.85rem;
  text-decoration: none;
}

.meta-category:hover {
  background-color: var(--primary-gold-dark);
  color: white;
}

.meta-date,
.meta-time,
.meta-views {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.85);
}

.post-author {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  overflow: hidden;
  background-color: white;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.author-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    var(--primary-gold),
    var(--primary-gold-dark)
  );
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.25rem;
}

.avatar-placeholder.large {
  font-size: 2.5rem;
}

.author-info {
  display: flex;
  flex-direction: column;
}

.author-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: white;
}

.author-role {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
}

/* المقال */
.post-article {
  margin-bottom: 3rem;
}

.post-featured-image {
  margin-bottom: 2rem;
  position: relative;
}

.post-featured-image figure {
  margin: 0;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.post-featured-image img {
  width: 100%;
  height: auto;
  border-radius: var(--border-radius-lg);
}

.post-excerpt {
  font-size: 1.25rem;
  color: var(--primary-navy);
  font-weight: 500;
  line-height: 1.8;
  margin-bottom: 2rem;
  padding-right: 1rem;
  border-right: 4px solid var(--primary-gold);
}

.post-text {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--body-text);
  margin-bottom: 2rem;
}

/* تنسيقات عناصر المقالة */
.post-text h2 {
  font-size: 1.75rem;
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
  font-weight: 700;
  position: relative;
  padding-right: 1rem;
}

.post-text h2::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: var(--primary-gold);
  border-radius: 4px;
}

.post-text h3 {
  font-size: 1.5rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 600;
}

.post-text h4 {
  font-size: 1.25rem;
  margin-top: 1.5rem;
  margin-bottom: 0.85rem;
  font-weight: 600;
}

.post-text p {
  margin-bottom: 1.5rem;
}

.post-text ul,
.post-text ol {
  margin-bottom: 1.5rem;
  padding-right: 1.5rem;
}

.post-text li {
  margin-bottom: 0.75rem;
}

.post-text a {
  color: var(--primary-gold);
  text-decoration: none;
  border-bottom: 1px dotted var(--primary-gold);
  transition: all var(--transition-base);
}

.post-text a:hover {
  color: var(--primary-gold-dark);
  border-bottom-color: var(--primary-gold-dark);
}

.post-text blockquote {
  border-right: 4px solid var(--primary-gold);
  padding: 1.25rem;
  margin: 1.5rem 0 2rem;
  background-color: rgba(212, 160, 70, 0.05);
  font-style: italic;
  border-radius: 0 var(--border-radius) var(--border-radius) 0;
  position: relative;
}

.post-text blockquote::before {
  content: "\201D";
  font-family: Arial, sans-serif;
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 3rem;
  color: rgba(212, 160, 70, 0.2);
  line-height: 1;
}

.post-text blockquote p:last-child {
  margin-bottom: 0;
}

.post-text img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
  margin: 1.5rem 0;
}

.post-text figure {
  margin: 2rem 0;
}

.post-text figcaption {
  text-align: center;
  font-size: 0.9rem;
  color: var(--body-text-muted);
  margin-top: 0.75rem;
}

.post-text table {
  margin-bottom: 1.5rem;
  width: 100%;
}

.post-text code {
  background-color: rgba(0, 0, 0, 0.05);
  padding: 0.2rem 0.4rem;
  border-radius: var(--border-radius-sm);
  font-size: 0.9em;
}

.post-text pre {
  background-color: rgba(0, 0, 0, 0.05);
  padding: 1rem;
  border-radius: var(--border-radius);
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

.post-text pre code {
  background-color: transparent;
  padding: 0;
  border-radius: 0;
}

.post-text .table-responsive {
  margin-bottom: 1.5rem;
}

/* عنصر ربط العناوين */
.heading-anchor {
  margin-right: 0.5rem;
  font-size: 0.85rem;
  color: var(--primary-gold);
  opacity: 0;
  transition: all var(--transition-base);
  text-decoration: none;
}

.post-text h2:hover .heading-anchor,
.post-text h3:hover .heading-anchor,
.post-text h4:hover .heading-anchor {
  opacity: 1;
}

/* معرض الصور */
.post-gallery {
  margin: 2.5rem 0;
}

.post-gallery h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  font-weight: 600;
  position: relative;
  padding-right: 1rem;
}

.post-gallery h3::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background-color: var(--primary-gold);
  border-radius: 3px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
}

.gallery-item {
  position: relative;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.gallery-image {
  display: block;
  width: 100%;
  height: 150px;
}

.gallery-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-base);
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(31, 43, 68, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all var(--transition-base);
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-overlay i {
  color: white;
  font-size: 1.5rem;
}

/* الكلمات المفتاحية */
.post-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 2.5rem 0;
  padding: 1.5rem;
  background-color: rgba(212, 160, 70, 0.05);
  border-radius: var(--border-radius-lg);
}

.tags-label {
  font-weight: 600;
  color: var(--body-text);
}

.tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-link {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.85rem;
  background-color: var(--primary-gold);
  color: white;
  border-radius: var(--border-radius);
  font-size: 0.85rem;
  font-weight: 500;
  transition: all var(--transition-base);
}

.tag-link:hover {
  background-color: var(--primary-gold-dark);
  color: white;
  transform: translateY(-3px);
}

/* أزرار المشاركة */
.post-share {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2.5rem;
  padding: 1.5rem 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.share-label {
  font-weight: 600;
  color: var(--body-text);
  margin-left: 0.5rem;
}

.share-buttons {
  display: flex;
  gap: 0.75rem;
}

.share-button {
  width: 40px;
  height: 40px;
  border-radius: var(--border-radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
  transition: all var(--transition-base);
  border: none;
  cursor: pointer;
}

.share-button:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.share-button.facebook {
  background-color: #3b5998;
}

.share-button.twitter {
  background-color: #1da1f2;
}

.share-button.whatsapp {
  background-color: #25d366;
}

.share-button.linkedin {
  background-color: #0077b5;
}

.share-button.email {
  background-color: #f39c12;
}

.share-button.copy-link {
  background-color: #3498db;
}

/* صندوق الكاتب */
.post-author-box {
  display: flex;
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  padding: 2rem;
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
  gap: 1.5rem;
}

.post-author-box .author-avatar {
  width: 120px;
  height: 120px;
  flex-shrink: 0;
}

.post-author-box .author-info {
  flex-grow: 1;
}

.post-author-box .author-name {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  font-weight: 700;
  color: var(--body-text);
}

.author-bio {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--body-text-muted);
  margin-bottom: 1.25rem;
}

.author-social {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  width: 36px;
  height: 36px;
  border-radius: var(--border-radius-circle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
  transition: all var(--transition-base);
}

.social-link:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.social-link.facebook {
  background-color: #3b5998;
}

.social-link.twitter {
  background-color: #1da1f2;
}

.social-link.instagram {
  background-color: #e4405f;
}

.social-link.linkedin {
  background-color: #0077b5;
}

.social-link.youtube {
  background-color: #ff0000;
}

/* التنقل بين المقالات */
.post-navigation {
  margin-bottom: 3rem;
}

.post-nav-links {
  display: flex;
  gap: 1.5rem;
}

.post-nav {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 1.25rem;
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  text-decoration: none;
  color: var(--body-text);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
  border: 1px solid var(--border-color);
  gap: 1rem;
  min-height: 100px;
}

.post-nav:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
  color: var(--primary-gold);
}

.post-nav-arrow {
  font-size: 1.25rem;
  color: var(--primary-gold);
  flex-shrink: 0;
}

.post-nav-content {
  flex-grow: 1;
}

.post-nav-label {
  display: block;
  font-size: 0.85rem;
  color: var(--body-text-muted);
  margin-bottom: 0.25rem;
}

.post-nav-title {
  font-size: 1rem;
  margin: 0;
  font-weight: 600;
}

.post-nav.prev {
  text-align: right;
}

.post-nav.next {
  text-align: left;
  justify-content: space-between;
}

.post-nav-placeholder {
  flex: 1;
}

/* المقالات ذات الصلة */
.related-posts {
  margin-bottom: 3rem;
}

.section-title {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  font-weight: 700;
  position: relative;
  padding-right: 1rem;
}

.section-title::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: var(--primary-gold);
  border-radius: 4px;
}

.related-posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.related-post-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
  height: 100%;
  transition: all var(--transition-base);
}

.related-post-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.related-post-card .post-image {
  position: relative;
  height: 180px;
  overflow: hidden;
}

.related-post-card .post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-base);
}

.related-post-card:hover .post-image img {
  transform: scale(1.1);
}

.related-post-card .post-content {
  padding: 1.25rem;
}

.related-post-card .post-title {
  font-size: 1.1rem;
  margin-bottom: 0;
  line-height: 1.4;
  font-weight: 600;
}

.related-post-card .post-title a {
  color: var(--body-text);
  text-decoration: none;
  transition: color var(--transition-base);
}

.related-post-card .post-title a:hover {
  color: var(--primary-gold);
}

.related-post-card .post-meta {
  margin-bottom: 0.5rem;
}

/* قسم التعليقات */
.post-comments {
  margin-top: 3rem;
}

.no-comments {
  padding: 2rem;
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  text-align: center;
  margin-bottom: 2rem;
}

.comments-list {
  margin-bottom: 3rem;
}

.comment-item {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-color);
}

.comment-item:last-child {
  border-bottom: none;
}

.comment-avatar {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
}

.comment-body {
  flex-grow: 1;
}

.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.comment-author {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
}

.comment-date {
  font-size: 0.85rem;
  color: var(--body-text-muted);
}

.comment-content {
  margin-bottom: 1rem;
  line-height: 1.7;
}

.comment-content p:last-child {
  margin-bottom: 0;
}

.comment-footer {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.reply-btn {
  background: none;
  border: none;
  color: var(--primary-gold);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  padding: 0;
  cursor: pointer;
  transition: color var(--transition-base);
}

.reply-btn:hover {
  color: var(--primary-gold-dark);
}

.reply-form-container {
  margin-top: 1.5rem;
  display: none;
}

.comment-replies {
  margin-top: 1.5rem;
  padding-right: 2rem;
  border-right: 2px dashed var(--border-color);
}

.reply-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.reply-item:last-child {
  margin-bottom: 0;
}

.reply-avatar {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.reply-body {
  flex-grow: 1;
}

.reply-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.reply-author {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.reply-date {
  font-size: 0.8rem;
  color: var(--body-text-muted);
}

.reply-content {
  font-size: 0.95rem;
  line-height: 1.6;
}

.reply-content p:last-child {
  margin-bottom: 0;
}

/* نموذج التعليق */
.comment-form-container {
  background-color: var(--body-bg-alt);
  border-radius: var(--border-radius-lg);
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
}

.form-title {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.form-title i {
  color: var(--primary-gold);
}

.comment-form label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.comment-form .form-control {
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
  padding: 0.75rem;
}

.comment-form .form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 0.2rem rgba(212, 160, 70, 0.25);
}

.form-policy {
  color: var(--body-text-muted);
}

.reply-form .form-title {
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
}

/* جدول المحتويات */
.toc-container {
  max-height: 400px;
  overflow-y: auto;
  padding-left: 1rem;
}

.toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.toc-item {
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.toc-item.toc-level-3 {
  padding-right: 1rem;
}

.toc-item.toc-level-4 {
  padding-right: 2rem;
}

.toc-link {
  color: var(--body-text);
  text-decoration: none;
  display: block;
  padding: 0.5rem 0;
  border-right: 3px solid transparent;
  padding-right: 0.75rem;
  transition: all var(--transition-base);
  line-height: 1.3;
}

.toc-link:hover,
.toc-link.active {
  color: var(--primary-gold);
  border-right-color: var(--primary-gold);
  background-color: rgba(212, 160, 70, 0.05);
}

.toc-loading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--body-text-muted);
  font-size: 0.95rem;
  padding: 1rem 0;
}

/* قسم الدعوة للعمل */
.blog-cta {
  position: relative;
  margin-top: 3rem;
}

.cta-bg {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 4rem 0;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(31, 43, 68, 0.9),
    rgba(31, 43, 68, 0.8)
  );
}

.cta-content {
  position: relative;
  z-index: 1;
  color: white;
  text-align: center;
}

.cta-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin-bottom: 1rem;
  font-weight: 700;
}

.cta-text {
  font-size: clamp(1rem, 2vw, 1.15rem);
  margin-bottom: 1.5rem;
  opacity: 0.9;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Toast Notification */
.toast {
  z-index: 1060;
}

/* Media Queries */
@media (max-width: 991px) {
  .post-header-bg {
    padding: 80px 0 40px;
  }

  .post-navigation .post-nav-title {
    font-size: 0.95rem;
  }

  .post-author-box {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .post-author-box .author-social {
    justify-content: center;
  }

  .related-posts-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }

  .toc-widget {
    display: none;
  }
}

@media (max-width: 767px) {
  .post-title {
    font-size: 1.75rem;
  }

  .post-meta {
    gap: 0.75rem;
    font-size: 0.85rem;
  }

  .post-text {
    font-size: 1rem;
  }

  .post-text h2 {
    font-size: 1.5rem;
  }

  .post-text h3 {
    font-size: 1.25rem;
  }

  .post-text h4 {
    font-size: 1.15rem;
  }

  .post-tags {
    padding: 1rem;
  }

  .post-navigation .post-nav-links {
    flex-direction: column;
  }

  .post-navigation .post-nav {
    margin-bottom: 1rem;
  }

  .comment-item {
    flex-direction: column;
    gap: 1rem;
  }

  .comment-replies {
    padding-right: 1rem;
  }

  .comment-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .related-posts-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575px) {
  .post-author {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .post-share {
    justify-content: center;
  }

  .form-title {
    text-align: center;
  }

  .cta-buttons {
    flex-direction: column;
  }

  .cta-buttons .btn {
    width: 100%;
  }
}
/* ===== تفضيلات تقليل الحركة ===== */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
