/* ═══ المكوّنات: البطاقاتُ والأزرارُ والألواحُ وما يتكرّر ═══ */

/* ───────────────── الصورة المصغّرة ───────────────── */
.thumb {
  position: relative;
  aspect-ratio: var(--ratio, 16/9);
  overflow: hidden;
  border-radius: var(--r-md);
  background:
    linear-gradient(135deg,
      color-mix(in srgb, var(--accent) 22%, var(--surface-2)),
      color-mix(in srgb, var(--accent) 6%, var(--surface-2)));
  isolation: isolate;
}
.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s cubic-bezier(.2, .7, .3, 1), filter var(--t-base);
}
.card:hover .thumb img, .poster:hover .thumb img { transform: scale(1.045); }
.thumb__fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 7vw, 4.6rem);
  font-weight: 900;
  color: color-mix(in srgb, var(--accent) 52%, transparent);
  user-select: none;
}
.thumb__play {
  position: absolute;
  inset-block-end: .6rem;
  inset-inline-start: .6rem;
  width: 40px; height: 40px;
  display: grid;
  place-items: center;
  border-radius: var(--r-full);
  background: rgb(12 10 18 / .78);
  color: #fff;
  backdrop-filter: blur(6px);
}

/* ───────────────── البطاقة ───────────────── */
.card { display: flex; flex-direction: column; gap: .85rem; min-width: 0; }
.card__body { display: flex; flex-direction: column; gap: .5rem; }
.card__title {
  font-size: var(--step-1);
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -.015em;
}
.card__title a { transition: color var(--t-fast); }
.card__title a:hover { color: var(--accent); }
.card__dek { font-size: .9rem; color: var(--muted); line-height: 1.75; }
.card__foot { display: flex; align-items: center; justify-content: space-between; gap: .6rem; margin-top: .1rem; }

.card--lead .card__title, .card--hero .card__title { font-size: var(--step-3); }
.card--hero .card__dek { font-size: 1rem; }

.card--list { flex-direction: row-reverse; align-items: flex-start; gap: .9rem; }
.card--list .card__media { flex: 0 0 108px; }
.card--list .card__title { font-size: 1.02rem; }
.card--list .card__dek { font-size: .84rem; }

.card--compact .card__title { font-size: .98rem; }

/* ───────────────── العناصرُ الصغيرة ───────────────── */
.kicker {
  display: inline-flex;
  align-items: center;
  gap: .38rem;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .05em;
  color: var(--accent);
  width: fit-content;
}
.kicker__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.kicker:hover { text-decoration: underline; text-underline-offset: 3px; }

.meta {
  display: flex;
  align-items: center;
  gap: .45rem;
  flex-wrap: wrap;
  font-size: .76rem;
  color: var(--muted);
  font-family: var(--font-mono);
}
.meta__sep { opacity: .5; }

.save {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: var(--r-full);
  color: var(--muted);
  flex-shrink: 0;
  transition: background var(--t-fast), color var(--t-fast), transform var(--t-fast);
}
.save:hover { background: var(--surface-2); color: var(--ink); }
.save.is-on { color: var(--brand); }
.save.is-on svg path { fill: currentColor; }
.save--compact { width: 30px; height: 30px; opacity: .55; }
.card:hover .save--compact { opacity: 1; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .3rem .72rem;
  border-radius: var(--r-full);
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: .8rem;
  font-weight: 600;
  color: var(--ink-2);
  transition: all var(--t-fast);
}
.chip:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
}
.chip--sm { padding: .18rem .55rem; font-size: .72rem; }
.chip__count { font-size: .68rem; color: var(--muted); font-family: var(--font-mono); }
.chips { display: flex; flex-wrap: wrap; gap: .42rem; }
.chips--wrap { gap: .5rem; }

/* ───────────────── القوائمُ المرقّمة ───────────────── */
.ranks { display: grid; gap: .1rem; }
.rank {
  display: flex;
  gap: .8rem;
  align-items: baseline;
  padding-block: .72rem;
  border-bottom: 1px solid var(--line-soft);
}
.rank:last-child { border-bottom: 0; }
.rank__num {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  font-weight: 700;
  color: color-mix(in srgb, var(--accent) 75%, transparent);
  flex-shrink: 0;
}
.rank__title { font-weight: 700; font-size: .94rem; line-height: 1.5; }
.rank__title:hover { color: var(--brand); }
.rank__meta { font-size: .72rem; color: var(--muted); margin-top: .2rem; font-family: var(--font-mono); }

/* ───────────────── الألواح الجانبيّة ───────────────── */
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 1.15rem 1.25rem;
}
.panel__eyebrow {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .11em;
  color: var(--muted);
  margin-bottom: .8rem;
}
.panel__title { font-size: 1.12rem; font-weight: 800; line-height: 1.45; margin-bottom: .55rem; }
.panel__text { font-size: .87rem; color: var(--muted); line-height: 1.8; margin-bottom: 1rem; }
.panel__link { display: inline-block; margin-top: .9rem; font-size: .82rem; font-weight: 700; color: var(--brand); }
.panel--scale {
  background: linear-gradient(150deg, color-mix(in srgb, var(--brand) 14%, var(--surface)), var(--surface));
  border-color: color-mix(in srgb, var(--brand) 28%, var(--line));
}
.panel--follow { background: var(--surface-2); }

/* ───────────────── الأزرار ───────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  padding: .62rem 1.35rem;
  border-radius: var(--r-full);
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 700;
  font-size: .9rem;
  border: 1px solid transparent;
  transition: transform var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn:active { transform: translateY(0); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn--light { background: #fff; color: #15141B; }
.btn--full { width: 100%; }
.btn--sm { padding: .42rem 1rem; font-size: .82rem; }
.btn:disabled { opacity: .42; cursor: not-allowed; transform: none; box-shadow: none; }

/* ───────────────── الترقيم ───────────────── */
.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .7rem;
  margin-top: var(--gap-lg);
  padding-top: var(--gap);
  border-top: 1px solid var(--line);
}
.pager__list { display: flex; gap: .3rem; }
.pager__num, .pager__arrow {
  display: grid;
  place-items: center;
  min-width: 38px;
  height: 38px;
  padding-inline: .7rem;
  border-radius: var(--r-sm);
  font-size: .88rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--ink-2);
}
.pager__num:hover, .pager__arrow:hover { background: var(--surface-2); }
.pager__num.is-current { background: var(--ink); color: var(--paper); }
.pager__arrow.is-off { opacity: .35; pointer-events: none; }

/* ───────────────── حالاتٌ وشرائح ───────────────── */
.empty {
  display: grid;
  justify-items: center;
  gap: .7rem;
  padding: clamp(2.5rem, 8vw, 5rem) 1rem;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: var(--r-lg);
}
.empty__text { font-size: 1.05rem; font-weight: 600; color: var(--ink-2); }
.empty__hint { font-size: .85rem; }

.onboarding { padding-block: clamp(3rem, 10vw, 7rem); text-align: center; display: grid; gap: 1rem; justify-items: center; }
.onboarding h1 { font-size: var(--step-4); }
.onboarding p { color: var(--muted); max-width: 60ch; line-height: 1.9; }
.onboarding code {
  background: var(--surface-2);
  padding: .12em .5em;
  border-radius: 5px;
  border: 1px solid var(--line);
}

.scroller {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(215px, 1fr);
  gap: var(--gap);
  overflow-x: auto;
  padding-bottom: .6rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
}
.poster { scroll-snap-align: start; display: grid; gap: .65rem; }
.poster__title { font-weight: 700; font-size: .94rem; line-height: 1.5; }
.poster:hover .poster__title { color: var(--accent); }

/* ───────────────── الموضوعات ───────────────── */
.topic-grid, .section-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
  gap: var(--gap);
}
.section-grid { margin-top: var(--gap-lg); }
.topic-card {
  position: relative;
  display: grid;
  gap: .3rem;
  align-content: start;
  padding: 1.15rem 1.2rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  transition: transform var(--t-fast), box-shadow var(--t-fast), border-color var(--t-fast);
}
.topic-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
}
.topic-card__bar {
  position: absolute;
  inset-block-start: 0;
  inset-inline: 0;
  height: 3px;
  background: var(--accent);
}
.topic-card b { font-size: 1.06rem; font-weight: 800; }
.topic-card__count { font-size: .76rem; color: var(--muted); font-family: var(--font-mono); }
.topic-card__dek { font-size: .84rem; color: var(--muted); line-height: 1.7; margin-top: .35rem; }

/* ───────────────── الأرشيف ───────────────── */
.archive-year { margin-bottom: var(--gap-lg); }
.archive-year__title {
  font-size: var(--step-3);
  font-weight: 900;
  color: var(--muted);
  border-bottom: 2px solid var(--ink);
  padding-bottom: .5rem;
  margin-bottom: var(--gap);
  font-family: var(--font-mono);
}
.archive-month { margin-bottom: var(--gap); }
.archive-month__title {
  font-size: .95rem;
  font-weight: 800;
  color: var(--brand);
  margin-bottom: .5rem;
  display: flex;
  align-items: center;
  gap: .5rem;
}
.archive-month__title small {
  font-family: var(--font-mono);
  font-size: .72rem;
  color: var(--muted);
  background: var(--surface-2);
  border-radius: var(--r-full);
  padding: .05rem .5rem;
}
.archive-list li {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  gap: .9rem;
  align-items: baseline;
  padding-block: .6rem;
  border-bottom: 1px solid var(--line-soft);
}
.archive-list__tag {
  font-size: .7rem;
  font-weight: 700;
  color: var(--accent);
  font-family: var(--font-body);
}
.archive-list a { font-weight: 600; font-size: .95rem; }
.archive-list a:hover { color: var(--brand); }
.archive-list time { font-size: .72rem; color: var(--muted); font-family: var(--font-mono); }

/* ───────────────── البحث ───────────────── */
.bigsearch {
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: .9rem 1.2rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  box-shadow: var(--shadow-sm);
  color: var(--muted);
  margin-bottom: 1.2rem;
}
.bigsearch:focus-within { border-color: var(--brand); box-shadow: var(--ring); }
.bigsearch input {
  flex: 1;
  border: 0;
  background: none;
  outline: none;
  font-size: 1.06rem;
  color: var(--ink);
}
.bigsearch__clear { font-size: 1.4rem; line-height: 1; color: var(--muted); padding: 0 .3rem; }

.filters { display: flex; flex-wrap: wrap; gap: .45rem; margin-bottom: 1.2rem; }
.filter {
  padding: .34rem .85rem;
  border-radius: var(--r-full);
  border: 1px solid var(--line);
  font-size: .82rem;
  font-weight: 600;
  color: var(--ink-2);
  transition: all var(--t-fast);
}
.filter:hover { border-color: var(--brand); }
.filter.is-on { background: var(--ink); color: var(--paper); border-color: var(--ink); }

.results-count { font-size: .84rem; color: var(--muted); margin-bottom: 1rem; font-family: var(--font-mono); }

.hit {
  display: flex;
  gap: .9rem;
  align-items: flex-start;
  padding: .8rem 1.2rem;
  border-bottom: 1px solid var(--line-soft);
  transition: background var(--t-fast);
}
.hit:hover, .hit.is-active { background: var(--surface-2); }
.hit__thumb {
  flex: 0 0 62px;
  width: 62px;
  height: 47px;
  border-radius: var(--r-sm);
  object-fit: cover;
  background: var(--surface-2);
}
.hit__body { flex: 1 1 auto; min-width: 0; display: block; }
.hit__title { display: block; font-weight: 700; font-size: .96rem; line-height: 1.45; }
.hit__meta { display: block; font-size: .74rem; color: var(--muted); margin-top: .2rem; }
.hit mark { background: color-mix(in srgb, var(--amber) 42%, transparent); color: inherit; border-radius: 3px; padding: 0 .12em; }

.saved-tools { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }

/* ───────────────── فريقٌ وأرقام ───────────────── */
.team { display: grid; gap: .85rem; }
.team__member { display: flex; align-items: center; gap: .7rem; }
.team__avatar, .byline__avatar {
  width: 38px; height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--r-full);
  background: linear-gradient(140deg, var(--brand), var(--spark));
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  flex-shrink: 0;
}
.team__member b { display: block; font-size: .94rem; font-weight: 700; }
.team__member small { font-size: .76rem; color: var(--muted); }

.stats { display: grid; gap: .8rem; }
.stats li { display: flex; align-items: baseline; gap: .6rem; }
.stats b { font-family: var(--font-mono); font-size: 1.5rem; font-weight: 700; color: var(--brand); }
.stats span { font-size: .84rem; color: var(--muted); }

/* ───────────────── 404 ───────────────── */
.notfound { padding-block: clamp(2.5rem, 7vw, 5rem); text-align: center; display: grid; justify-items: center; gap: 1rem; }
.notfound__code {
  font-family: var(--font-display);
  font-size: clamp(4rem, 16vw, 9rem);
  font-weight: 900;
  line-height: 1;
  background: linear-gradient(135deg, var(--brand), var(--spark));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.notfound__title { font-size: var(--step-3); }
.notfound__text { color: var(--muted); max-width: 56ch; line-height: 1.9; }
.notfound__actions { display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center; }
.notfound__sections { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: center; margin-top: 1rem; }
.notfound__sections a {
  font-size: .82rem;
  font-weight: 700;
  color: var(--accent);
  border-bottom: 2px solid color-mix(in srgb, var(--accent) 35%, transparent);
  padding-bottom: .1rem;
}
.notfound .strip { width: 100%; text-align: start; margin-top: var(--gap-lg); }

/* ───────────────── التنبيه العائم ───────────────── */
.toast {
  position: fixed;
  inset-block-end: 1.4rem;
  inset-inline-end: 1.4rem;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  padding: .7rem 1.2rem;
  border-radius: var(--r-full);
  font-size: .88rem;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  animation: toast-in var(--t-base);
}
@keyframes toast-in { from { transform: translateY(14px); opacity: 0; } }

/* ───────────────── الإطاراتُ المدمجة ───────────────── */
.embed {
  position: relative;
  aspect-ratio: 16/9;
  border-radius: var(--r-md);
  overflow: hidden;
  background: #000;
}
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ───────────────── الموادُّ الحيّة (قبل إعادة البناء) ───────────────── */
.fresh-tag {
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .05em;
  color: #fff;
  background: var(--spark);
  border-radius: var(--r-full);
  padding: .1rem .45rem;
  margin-inline-start: .35rem;
}
.card.is-fresh { animation: fresh-in .5s cubic-bezier(.2,.7,.3,1); }
@keyframes fresh-in { from { opacity: 0; transform: translateY(10px); } }

/* ───────────────── الهيكلُ العظميُّ أثناء التحميل ───────────────── */
@keyframes skel-shine { to { background-position-x: -200%; } }

.skel {
  display: block;
  border-radius: var(--r-sm);
  background: linear-gradient(
    100deg,
    var(--surface-2) 28%,
    color-mix(in srgb, var(--ink) 8%, var(--surface-2)) 48%,
    var(--surface-2) 68%
  );
  background-size: 220% 100%;
  animation: skel-shine 1.5s linear infinite;
}

.skel--media { aspect-ratio: 16/9; border-radius: var(--r-md); }
.skel--kicker { width: 74px; height: .72rem; }
.skel--title { width: 100%; height: 1.15rem; }
.skel--short { width: 62%; }
.skel--line { width: 88%; height: .78rem; }
.skel--line + .skel--line { width: 70%; }
.skel--meta { width: 40%; height: .68rem; margin-top: .3rem; }
.skel--hero { aspect-ratio: 21/9; border-radius: var(--r-lg); }
.skel--h1 { height: 2.4rem; width: 92%; }
.skel--para { height: .95rem; width: 100%; }

.card--skeleton { pointer-events: none; }
.card--skeleton .card__body { gap: .55rem; }

/* الصورةُ ريثما تصل: وميضٌ مكانَ الفراغ */
.thumb.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    color-mix(in srgb, var(--ink) 4%, var(--surface-2)) 28%,
    color-mix(in srgb, var(--ink) 10%, var(--surface-2)) 48%,
    color-mix(in srgb, var(--ink) 4%, var(--surface-2)) 68%
  );
  background-size: 220% 100%;
  animation: skel-shine 1.5s linear infinite;
  z-index: 1;
}
/* الفئةُ تُضاف بالـ JS فقط، فبدونه تظهر الصورةُ كالمعتاد */
.thumb img { transition: opacity .45s ease; }
.thumb.is-loading img { opacity: 0; }

.skel-article { display: grid; gap: 1rem; padding-block: 1.5rem; }
.skel-article .skel--h1 { margin-bottom: .4rem; }

/* ═══ الإعلانات ═══════════════════════════════════════════════
   الوحدةُ تحجز ارتفاعَها قبل وصول الإعلان فلا يقفز النصُّ تحتها،
   وتُطوى تماماً إن لم يأتِ إعلان.
   ═════════════════════════════════════════════════════════ */
.ad {
  position: relative;
  display: block;
  margin-inline: auto;
  overflow: hidden;
  isolation: isolate;
}
.ad__label {
  display: block;
  font-size: .62rem;
  font-weight: 600;
  letter-spacing: .08em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: .35rem;
  opacity: .75;
}
.ad .adsbygoogle { display: block; width: 100%; }
.ad.is-collapsed { display: none; }

.ad--band {
  width: min(100%, var(--shell));
  padding-inline: var(--pad);
  margin-block: var(--gap-lg);
  min-height: 130px;
}
.shell > .ad--band, .article__foot .ad--band { padding-inline: 0; }

.ad--flow {
  margin-block: 2.2rem;
  padding-block: 1rem;
  border-block: 1px solid var(--line-soft);
  min-height: 200px;
}

.ad--side {
  margin-block: 1.25rem;
  min-height: 250px;
}
.ad--side .adsbygoogle { min-height: 250px; }

.ad--cell {
  min-height: 260px;
  border: 1px dashed var(--line);
  border-radius: var(--r-md);
  padding: .8rem;
  display: grid;
  align-content: center;
}
.ad--cell.is-filled { border-style: solid; }

/* العمودُ الجانبيُّ يلاحق القارئ في الشاشات الواسعة */
@media (min-width: 1100px) {
  .river__side .ad--side, .toc .ad--side {
    position: sticky;
    inset-block-start: calc(var(--header-h) + 1rem);
  }
}

/* وضعُ المعاينة — لا يظهر للقارئ، إنّما لصاحب الموقع قبل التفعيل */
.ad--test {
  display: grid;
  place-content: center;
  gap: .3rem;
  text-align: center;
  min-height: 130px;
  border: 1px dashed color-mix(in srgb, var(--brand) 45%, var(--line));
  border-radius: var(--r-md);
  background:
    repeating-linear-gradient(135deg,
      color-mix(in srgb, var(--brand) 5%, transparent) 0 10px,
      transparent 10px 20px);
  padding: 1.2rem;
}
.ad--test.ad--flow { min-height: 180px; }
.ad--test.ad--side, .ad--test.ad--cell { min-height: 250px; }
.ad__test-name {
  font-family: var(--font-mono);
  font-size: .82rem;
  font-weight: 700;
  color: var(--brand);
  direction: ltr;
}
.ad__test-note { font-size: .74rem; color: var(--muted); }

/* ═══ الإشعارات ═══════════════════════════════════════════ */
.icon-btn--bell .ico-bell-off { display: none; }
.icon-btn--bell.is-on { color: var(--brand); }
.icon-btn--bell.is-on .ico-bell { display: none; }
.icon-btn--bell.is-on .ico-bell-off { display: block; }

.badge--pulse { background: var(--brand); animation: badge-in .3s cubic-bezier(.2, .9, .3, 1.4); }
@keyframes badge-in { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }

.notify-invite {
  position: fixed;
  inset-block-end: 1rem;
  inset-inline-start: 1rem;
  z-index: 60;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  gap: .85rem;
  padding: 1.05rem 1.15rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  transform: translateY(120%);
  opacity: 0;
  transition: transform var(--t-base), opacity var(--t-base);
}
.notify-invite.is-in { transform: none; opacity: 1; }
.notify-invite__body { display: grid; gap: .25rem; }
.notify-invite__body strong { font-family: var(--font-display); font-size: 1.02rem; }
.notify-invite__body span { color: var(--muted); font-size: .86rem; line-height: 1.6; }
.notify-invite__acts { display: flex; gap: .5rem; }

@media (max-width: 520px) {
  .notify-invite { inset-inline: .6rem; max-width: none; }
}
@media (prefers-reduced-motion: reduce) {
  .notify-invite { transition: opacity .2s linear; transform: none; }
}

/* ═══ صفحةُ الاشتراك ══════════════════════════════════════ */
.follow-grid {
  display: grid;
  gap: var(--gap);
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  margin-block-end: var(--gap-lg);
}
.follow-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: .7rem;
  padding: 1.6rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
}
.follow-card--lead {
  grid-column: 1 / -1;
  border-color: color-mix(in srgb, var(--brand) 40%, var(--line));
  background: linear-gradient(160deg, color-mix(in srgb, var(--brand) 7%, var(--surface)), var(--surface) 60%);
}
.follow-card__num {
  position: absolute;
  inset-block-start: 1.1rem;
  inset-inline-end: 1.3rem;
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 900;
  line-height: 1;
  color: color-mix(in srgb, var(--ink) 7%, transparent);
}
.follow-card__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: var(--r-md);
  background: color-mix(in srgb, var(--brand) 11%, transparent);
  color: var(--brand);
}
.follow-card h2 { font-family: var(--font-display); font-size: var(--step-2); margin: 0; }
.follow-card p { margin: 0; color: var(--ink-2); line-height: 1.85; }
.follow-card__act { display: flex; gap: .6rem; flex-wrap: wrap; margin-block-start: .4rem; }
.follow-card__label { font-size: .82rem; font-weight: 600; color: var(--muted); }

.follow-card__state {
  display: none;
  align-items: center;
  gap: .5rem;
  font-size: .88rem;
  padding: .6rem .8rem;
  border-radius: var(--r-sm);
  background: var(--surface-2);
}
[data-notify-state="on"] .follow-card__state--on,
[data-notify-state="blocked"] .follow-card__state--blocked,
[data-notify-state="unsupported"] .follow-card__state--unsupported { display: flex; }
[data-notify-state="on"] [data-state-on-hide],
[data-notify-state="blocked"] [data-state-on-hide],
[data-notify-state="unsupported"] [data-state-on-hide] { display: none; }
[data-state-on-show] { display: none; }
[data-notify-state="on"] [data-state-on-show] { display: inline-flex; }
[data-notify-state="unsupported"] .follow-card__act,
[data-notify-state="blocked"] .follow-card__act { display: none; }

.dot--live {
  width: 9px;
  height: 9px;
  border-radius: var(--r-full);
  background: #16A34A;
  box-shadow: 0 0 0 4px color-mix(in srgb, #16A34A 20%, transparent);
  flex: none;
}

.feed-field {
  display: flex;
  gap: .5rem;
  align-items: center;
  flex-wrap: wrap;
  margin-block-start: .4rem;
}
.feed-field code {
  flex: 1 1 220px;
  min-width: 0;
  direction: ltr;
  text-align: left;
  font-size: .8rem;
  padding: .55rem .7rem;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--paper);
  overflow-x: auto;
  white-space: nowrap;
}

.reader-links { display: flex; flex-wrap: wrap; gap: .5rem; }
.reader {
  padding: .42rem .95rem;
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  font-size: .84rem;
  font-weight: 600;
  color: var(--ink-2);
  transition: border-color var(--t-fast), color var(--t-fast), background var(--t-fast);
}
.reader:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); }

.follow-steps { display: grid; gap: .45rem; margin: .2rem 0 .6rem; padding: 0; list-style: none; }
.follow-steps li {
  font-size: .89rem;
  color: var(--ink-2);
  padding-inline-start: 1rem;
  position: relative;
}
.follow-steps li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  inset-block-start: .7em;
  width: 5px;
  height: 5px;
  border-radius: var(--r-full);
  background: var(--brand);
}
.follow-steps b { color: var(--ink); }

.follow-note {
  max-width: var(--shell-narrow);
  margin: 0 auto;
  padding: 1.5rem;
  border-inline-start: 3px solid var(--brand);
  background: var(--surface-2);
  border-radius: var(--r-md);
}
.follow-note h2 { font-family: var(--font-display); font-size: var(--step-1); margin: 0 0 .5rem; }
.follow-note p { margin: 0; color: var(--ink-2); line-height: 1.9; }
.follow-note a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }

.btn--lg { padding: .8rem 1.6rem; font-size: 1rem; }

/* ═══ المشاهدات والإعجاب والتعليقات ═══════════════════════ */
.meta__eye { display: inline-flex; align-items: center; gap: .28rem; }
.meta__eye svg { opacity: .7; }

.reactbar {
  display: flex;
  align-items: center;
  gap: .9rem;
  flex-wrap: wrap;
  padding-block: 1.2rem;
  border-block-start: 1px solid var(--line-soft);
}
.react {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .58rem 1.15rem;
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  font-weight: 600;
  color: var(--ink-2);
  background: var(--surface);
  transition: color var(--t-fast), border-color var(--t-fast), background var(--t-fast), transform var(--t-fast);
}
.react:hover { border-color: var(--spark); color: var(--spark); }
.react.is-on { border-color: var(--spark); color: var(--spark); background: color-mix(in srgb, var(--spark) 10%, transparent); }
.react.is-on svg path { fill: currentColor; }
.react.is-pop { transform: scale(1.07); }
.react__count {
  font-family: var(--font-mono);
  font-size: .82rem;
  padding-inline-start: .5rem;
  border-inline-start: 1px solid var(--line);
}
.reactbar__note { margin: 0; font-size: .78rem; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .react.is-pop { transform: none; } }

.comments {
  max-width: var(--shell-narrow);
  margin-inline: auto;
  padding-block: var(--gap-lg);
}
.comments__head { margin-block-end: 1.2rem; }
.comments__head h2 { font-family: var(--font-display); font-size: var(--step-2); margin: 0; }
.comments__count { color: var(--muted); font-weight: 400; }
.comments__head p { margin: .3rem 0 0; color: var(--muted); font-size: .88rem; }

.comment-form {
  display: grid;
  gap: .6rem;
  padding: 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
  margin-block-end: 1.6rem;
}
.comment-form .field__input {
  width: 100%;
  padding: .6rem .8rem;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--paper);
  font: inherit;
  color: inherit;
}
.comment-form textarea { resize: vertical; line-height: 1.8; min-height: 90px; }
.comment-form .field__input:focus { outline: none; border-color: var(--brand); box-shadow: var(--ring); }
.comment-form__row { display: flex; gap: .6rem; }
.comment-form__foot { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.comment-form__foot .btn { margin-inline-start: auto; }
.comment-form__note { margin: 0; font-size: .84rem; color: var(--brand); font-weight: 600; }
.comment-form__trap { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

.comment-list { display: grid; gap: 1rem; margin: 0; padding: 0; list-style: none; }
.comment { display: flex; gap: .75rem; }
.comment--empty { color: var(--muted); font-size: .9rem; justify-content: center; padding-block: 1.4rem; }
.comment__avatar {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand);
  font-family: var(--font-display);
  font-weight: 700;
}
.comment__body {
  flex: 1;
  min-width: 0;
  background: var(--surface-2);
  border-radius: var(--r-md);
  padding: .7rem .9rem;
}
.comment__head { display: flex; gap: .6rem; align-items: baseline; margin: 0 0 .2rem; }
.comment__head b { font-size: .9rem; }
.comment__head time { font-size: .74rem; color: var(--muted); }
.comment__text { margin: 0; line-height: 1.85; white-space: pre-wrap; overflow-wrap: anywhere; }
