/* ============================================================
   أقسام الخبر (partials/news-sections) تحت المقال في صفحة الخبر:
   بطاقة بنفس شكل بطاقتي المقال والأخبار المتعلقة (news-detail-page.css)،
   فيها مجموعات البطولة ثم الأندية ثم اللاعبين، وكل عنصر حبّة بشعار أو صورة واسم.
   الأساس داكن و html.light:not(.dark) يعيد الألوان الفاتحة كبقية الصفحة.
   ============================================================ */
.news-sections {
  margin: 0 0 28px;
  padding: 22px 24px;
  border-radius: 18px;
  background: #131521;
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.2);
}

.news-sections__title {
  margin: 0 0 16px;
  padding: 0;
  font-size: 15px;
  font-weight: 900;
  color: #39dbbf;
}

.news-sections__group + .news-sections__group {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.news-sections__label {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 700;
  color: #9aa0b5;
}

.news-sections__items {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.news-sections__item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
  padding: 5px;
  padding-inline-end: 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #e3e6f0;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

a.news-sections__item:hover,
a.news-sections__item:focus-visible {
  background: rgba(57, 219, 191, 0.1);
  border-color: rgba(57, 219, 191, 0.25);
  color: #39dbbf;
}

.news-sections__media {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.news-sections__media img {
  max-width: 22px;
  max-height: 22px;
  object-fit: contain;
}

/* صورة اللاعب تملأ الدائرة */
.news-sections__item--player .news-sections__media img {
  max-width: none;
  max-height: none;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-sections__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.news-sections__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.news-sections__sub {
  font-size: 11px;
  font-weight: 500;
  color: #9aa0b5;
}

@media (max-width: 767px) {
  .news-sections {
    padding: 18px 16px;
  }

  .news-sections__item {
    font-size: 13px;
  }
}

/* —— الوضع الفاتح —— */
html.light:not(.dark) .news-sections {
  background: #fff;
  border-color: rgba(15, 20, 40, 0.08);
  box-shadow: 0 10px 30px rgba(15, 20, 40, 0.06);
}

html.light:not(.dark) .news-sections__title {
  color: #0a8f78;
}

html.light:not(.dark) .news-sections__group + .news-sections__group {
  border-top-color: rgba(15, 20, 40, 0.08);
}

html.light:not(.dark) .news-sections__label,
html.light:not(.dark) .news-sections__sub {
  color: #5c6478;
}

html.light:not(.dark) .news-sections__item {
  background: #f0f2f8;
  border-color: rgba(15, 20, 40, 0.08);
  color: #1a2133;
}

html.light:not(.dark) a.news-sections__item:hover,
html.light:not(.dark) a.news-sections__item:focus-visible {
  background: rgba(57, 219, 191, 0.12);
  border-color: rgba(57, 219, 191, 0.3);
  color: #0a8f78;
}

html.light:not(.dark) .news-sections__media {
  background: #fff;
}

/* —— الموضع: القائمة الجانبية على الكمبيوتر، وتحت المقال على الجوال والتابلت ——
   (نفس نقطة انقسام عمودي الصفحة col-lg: 992px) */
.news-sections--aside {
  display: none;
}

@media (min-width: 992px) {
  .news-sections--main {
    display: none;
  }

  .news-sections--aside {
    display: block;
    margin: 16px 0 0;
    padding: 18px;
  }

  /*
      الأخبار المتعلقة كانت ثابتة أثناء التمرير بارتفاع الشاشة وتمرير داخلي
      (news-detail-page.css). صارت القائمة الجانبية كلها تتحرك مع الصفحة،
      فتظهر أقسام الخبر تحتها مباشرة بلا شريط تمرير ثانٍ.
  */
  .news-detail-page-root .news-page__aside-sticky .news-related {
    position: static;
    max-height: none;
    overflow: visible;
  }

  .news-sections--aside .news-sections__items {
    gap: 6px;
  }

  .news-sections--aside .news-sections__item {
    font-size: 13px;
  }
}
