/* ============================================================
   شريط «الالتقاط المداريّ» — خاصّ بـ/free-course.
   مُنطاق تحت .capture-wrap فلا يمسّ بقيّة الصفحة ولا خريطة المحطّات.
   ============================================================ */

.capture-wrap{
  --c-vio:#7C3AED; --c-vio2:#A678F5; --c-lav:#DDD1F8; --c-dim:#4A2F7D;
  --c-ink:#F7F3FF; --c-ink2:#BCA9E2; --c-ink3:#8E7CB4; --c-cut:#08070d;
  position:relative; width:100%; max-width:1180px; margin:clamp(26px,4vw,52px) auto 0;
  padding-inline:16px;
}
.capture-wrap svg{width:100%;height:auto;display:block;overflow:visible}

/* ── الكوكب المركزيّ ─────────────────────────────────────── */
.capture-wrap .core-c{fill:url(#cPlanet)}
.capture-wrap .core-t{font-size:19px;font-weight:900;fill:#fff;
  text-anchor:middle;dominant-baseline:central}
.capture-wrap .core-s{font-size:10.5px;font-weight:500;fill:var(--c-lav);
  text-anchor:middle;dominant-baseline:central}

/* ── المدار ──────────────────────────────────────────────── */
.capture-wrap .ring{fill:none}
.capture-wrap .ring.back{stroke:var(--c-dim);stroke-width:2.2}
.capture-wrap .ring.front{stroke:url(#cRing);stroke-width:3;stroke-linecap:round}

/* ── مسار الوصول: يُرسم من خارج الإطار إلى الحلقة ────────── */
.capture-wrap .approach{fill:none;stroke:url(#cApp);stroke-width:2.6;
  stroke-linecap:round;stroke-dasharray:1 7}
.capture-wrap .approach-lead{fill:none;stroke:#F3EDFF;stroke-width:3.4;
  stroke-linecap:round;opacity:0;
  filter:drop-shadow(0 0 8px rgba(221,209,248,.9))}

/* الرسم عند الظهور: المسار يُخطّ ثم يمشي عليه ضوء مرّة واحدة */
.js-cap .capture-wrap .approach{stroke-dasharray:100;stroke-dashoffset:100;
  transition:stroke-dashoffset 2.1s cubic-bezier(.3,.9,.4,1) .15s}
.capture-wrap.drawn .approach{stroke-dashoffset:0}
.capture-wrap.drawn .approach-lead{stroke-dasharray:7 93;
  animation:capLead 2.25s cubic-bezier(.3,.9,.4,1) .15s 1 forwards}
@keyframes capLead{
  0%{stroke-dashoffset:0;opacity:1}
  88%{opacity:1}
  100%{stroke-dashoffset:-100;opacity:0}}

.js-cap .capture-wrap .ring{stroke-dasharray:100;stroke-dashoffset:100;
  transition:stroke-dashoffset 1.1s cubic-bezier(.22,1,.36,1) 1.5s}
.capture-wrap.drawn .ring{stroke-dashoffset:0}

/* ── نقاط الأيام السبع ───────────────────────────────────── */
.capture-wrap .day{cursor:default}
.js-cap .capture-wrap .day{opacity:0;transition:opacity .5s ease var(--d,0s)}
.capture-wrap.drawn .day{opacity:1}
.capture-wrap .day-dot{fill:var(--c-cut);stroke:var(--c-vio);stroke-width:2.4;
  transition:fill .22s ease,stroke .22s ease}
.capture-wrap .day-n{font-size:12.5px;font-weight:800;fill:var(--c-vio2);
  text-anchor:middle;dominant-baseline:central;pointer-events:none;
  transition:fill .22s ease}
.capture-wrap .day-lbl{font-size:12px;font-weight:600;fill:var(--c-ink3);
  text-anchor:middle;dominant-baseline:central;pointer-events:none;
  transition:fill .22s ease}
.capture-wrap .day-halo{fill:none;stroke:var(--c-vio);stroke-width:1.6;opacity:0;
  transition:opacity .22s ease}
.capture-wrap .day:hover .day-dot,.capture-wrap .day:focus .day-dot{fill:var(--c-vio)}
.capture-wrap .day:hover .day-n,.capture-wrap .day:focus .day-n{fill:#fff}
.capture-wrap .day:hover .day-lbl,.capture-wrap .day:focus .day-lbl{fill:var(--c-ink)}
.capture-wrap .day:hover .day-halo,.capture-wrap .day:focus .day-halo{opacity:.4}
.capture-wrap .day:focus{outline:none}

/* اليوم السابع هو نقطة الالتقاط — ممتلئ ونابض */
.capture-wrap .day.captured .day-dot{fill:var(--c-vio);stroke:var(--c-vio2);stroke-width:3}
.capture-wrap .day.captured .day-n{fill:#fff}
.capture-wrap .day.captured .day-lbl{fill:var(--c-lav);font-weight:800}
.capture-wrap .day.captured .day-halo{opacity:.3;animation:capPulse 2.6s ease-in-out infinite 2.6s}
@keyframes capPulse{0%,100%{opacity:.16;r:26}50%{opacity:.42;r:31}}

/* ── النجوم والأجسام الدائرة ─────────────────────────────── */
.capture-wrap .ostar{fill:var(--c-lav);animation:capTwinkle 5s ease-in-out infinite}
@keyframes capTwinkle{
  0%,100%{opacity:calc(var(--peak,.5) * .3)}
  50%{opacity:var(--peak,.5)}}
.capture-wrap .orbiter{pointer-events:none}
.capture-wrap .orbiter-dot{filter:drop-shadow(0 0 7px currentColor)}

/* ── التسمية تحت الشريط ──────────────────────────────────── */
.capture-cap{text-align:center;font-size:13.5px;color:var(--c-ink3);
  margin:10px auto 0;max-width:60ch;line-height:1.8}

/* ── قائمة الأيام: مخفيّة على الشاشات الواسعة ────────────── */
.capture-days{display:none;list-style:none;margin:16px auto 0;padding:0;max-width:560px;
  grid-template-columns:1fr 1fr;gap:9px 14px}
.capture-days li{display:flex;align-items:center;gap:9px;font-size:14px;color:var(--c-ink2)}
.capture-days b{flex:0 0 auto;width:24px;height:24px;border-radius:50%;
  display:grid;place-items:center;font-size:12.5px;font-weight:800;
  background:rgba(124,58,237,.18);color:var(--c-lav);border:1px solid rgba(124,58,237,.35)}
.capture-days li:last-child b{background:var(--c-vio);color:#fff;border-color:var(--c-vio)}
.capture-days li:last-child span{color:var(--c-ink);font-weight:700}

/* دون ٧٦٠px تُرسم تسميات الـSVG بأقلّ من ٧px — تُخفى، وتكبر الأرقام
   والنقاط بالقدر الذي يعيدها فوق ١٠px بعد تصغير الإطار. */
@media(max-width:760px){
  .capture-wrap .day-lbl{display:none}
  .capture-wrap .day-dot{r:30}
  .capture-wrap .day.captured .day-dot{r:38}
  .capture-wrap .day-halo{r:44}
  .capture-wrap .day.captured .day-halo{r:54}
  .capture-wrap .day-n{font-size:34px}
  .capture-wrap .core-t{font-size:40px}
  .capture-wrap .core-s{font-size:22px}
  .capture-days{display:grid}
  @keyframes capPulse{0%,100%{opacity:.16;r:54}50%{opacity:.42;r:62}}
}
@media(max-width:430px){.capture-days{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){
  .capture-wrap *{animation:none!important;transition:none!important}
  .capture-wrap .approach,.capture-wrap .ring{stroke-dashoffset:0}
  .capture-wrap .day{opacity:1}
  .capture-wrap .approach-lead{display:none}
}
