/* ===============================
   🎨 Internal Linker Plugin v2.1 (Clean CSS)
   =============================== */

/* عناوين الصفحات في لوحة التحكم */
.wrap h2 {
  font-size: 22px;
  margin-bottom: 15px;
  color: #0073aa;
}

/* الجداول */
table.widefat {
  border-collapse: collapse;
  width: 100%;
  margin-top: 10px;
}

table.widefat th,
table.widefat td {
  padding: 10px;
  border-bottom: 1px solid #ddd;
  text-align: right;
  vertical-align: middle;
}

table.widefat th {
  background-color: #f1f1f1;
  font-weight: 600;
  color: #333;
}

table.widefat tr:nth-child(even) {
  background-color: #fafafa;
}

/* 🔍 شريط البحث والتحكم */
.il-search-box {
  margin: 15px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.il-search-box input[type="text"] {
  padding: 7px 10px;
  width: 220px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

.il-search-box select {
  padding: 6px;
  border-radius: 6px;
  border: 1px solid #ccc;
}

.il-search-box button {
  background: #0073aa;
  border: none;
  color: #fff;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.il-search-box button:hover {
  background: #005f8d;
}

/* 📄 ترقيم الصفحات */
.il-pagination {
  margin-top: 15px;
  display: flex;
  justify-content: flex-end;
  gap: 5px;
}

.il-pagination a,
.il-pagination span {
  display: inline-block;
  padding: 6px 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  text-decoration: none;
  color: #0073aa;
  background: #fff;
  transition: 0.3s;
}

.il-pagination a:hover {
  background: #0073aa;
  color: #fff;
}

.il-pagination .current {
  background: #0073aa;
  color: #fff;
  border-color: #0073aa;
}

/* 🗂️ صفحة التصنيفات */
.il-category-checkbox {
  transform: scale(1.2);
  cursor: pointer;
}

.il-category-checkbox:checked {
  accent-color: #0073aa;
}

/* ===============================
   📦 الصندوق داخل المقال (نسخة منقّحة ومتجاوبة)
   =============================== */
.il-related-box {
  display: inline-flex;
  align-items: center;
  flex-wrap: nowrap; /* ← مهم علشان يمنع الكسر */
  width: 100%;
  background: #f6faff;
  border: 2px solid #e0ecff;
  border-left: 5px solid #0073aa;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 16px;
  line-height: 1.6;
  margin: 15px 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  box-sizing: border-box;
  white-space: normal;
}

.il-related-box strong {
  display: inline-flex;
  align-items: center;
  color: #0073aa;
  font-weight: 600;
  margin-right: 6px;
  white-space: nowrap; /* ← يمنع انقسام "قد يهمك أيضًا" */
}

.il-related-box strong::before {
  content: "\1F4D6"; /* رمز 📖 */
  margin-left: 6px;
  font-size: 17px;
  line-height: 1;
}

.il-related-box a {
  display: inline;
  color: #111;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
  margin-right: 4px;
  word-break: break-word;
}

.il-related-box a:hover {
  color: #0073aa;
  text-decoration: underline;
}

/* 📱 دعم الموبايل */
@media (max-width: 600px) {
  .il-related-box {
    flex-wrap: nowrap; /* ← يمنع عمودين في الموبايل */
    align-items: center;
    justify-content: flex-start;
  }
  .il-related-box strong {
    margin-bottom: 0;
  }
  .il-related-box a {
    margin-top: 0;
  }
}
