/* ==========================================
   عباقرة الرياضيات - تنسيقات مخصصة
   ========================================== */

.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* ===== مبدّل الصف الدراسي ===== */
#gradeSwitcher { border: 1px solid #e2e8f0; }
.grade-btn {
  background-color: transparent;
  color: #64748b;
  white-space: nowrap;
  font-family: 'Readex Pro', sans-serif;
  transition: background-color .18s ease, color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.grade-btn:active { transform: scale(0.97); }
.grade-btn.is-active {
  background-color: #7c3aed;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(124, 58, 237, .35);
}

/* ===== الرسوم التوضيحية داخل الأسئلة ===== */
.illi-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 100%;
}
.illi-caption {
  font-size: 11px;
  font-weight: 700;
  color: #6d28d9;
  text-align: center;
  line-height: 1.5;
}
.illi-card-title {
  font-size: 11px;
  font-weight: 800;
  color: #3730a3;
  text-align: center;
}

/* خط الأعداد */
.illi-line {
  position: relative;
  width: 100%;
  max-width: 280px;
  height: 10px;
  border-radius: 9999px;
  background: linear-gradient(90deg, #38bdf8 0%, #e2e8f0 50%, #fbbf24 100%);
}
.illi-line-dot {
  position: absolute;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translate(-50%, -50%);
  border-radius: 9999px;
  background: #ffffff;
  border: 3px solid #7c3aed;
  box-shadow: 0 1px 4px rgba(15, 23, 42, .25);
}
.illi-chip {
  font-size: 11px;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 10px;
}
.illi-chip--cold { background: #e0f2fe; color: #075985; }
.illi-chip--warm { background: #fef3c7; color: #92400e; }

/* شريط النسبة المئوية */
.illi-bar {
  width: 100%;
  max-width: 260px;
  height: 22px;
  border-radius: 9999px;
  background: #ede9fe;
  overflow: hidden;
}
.illi-bar > span {
  display: block;
  height: 100%;
  border-radius: 9999px;
  background: linear-gradient(90deg, #a855f7, #ec4899);
  transition: width .4s ease;
}

/* التناسب */
.illi-pair {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
  max-width: 260px;
}
.illi-pair-box {
  background: #ffffff;
  border: 1px solid #ddd6fe;
  border-radius: 12px;
  padding: 8px 10px;
  text-align: center;
  font-weight: 800;
  font-size: 13px;
  color: #4c1d95;
}
.illi-pair-box--accent { background: #fdf4ff; border-color: #f0abfc; color: #86198f; }

/* بطاقات الخطوات والمعادلات */
.illi-rows {
  display: flex;
  flex-direction: column;
  gap: 5px;
  align-items: center;
  width: 100%;
}
.illi-row {
  background: #ffffff;
  border: 1px solid #e9d5ff;
  border-radius: 12px;
  padding: 6px 12px;
  font-weight: 800;
  font-size: 13px;
  color: #5b21b6;
  text-align: center;
  max-width: 100%;
  overflow-x: auto;
}

/* الأشكال الهندسية */
.illi-rect {
  position: relative;
  border: 3px solid #6366f1;
  border-radius: 12px;
  background: rgba(199, 210, 254, .45);
  max-width: 100%;
}
.illi-rect-side {
  position: absolute;
  left: 50%;
  bottom: -12px;
  transform: translateX(-50%);
  background: #ffffff;
  border-radius: 8px;
  padding: 1px 7px;
  font-size: 11px;
  font-weight: 800;
  color: #3730a3;
  white-space: nowrap;
}

/* الأعمدة البيانية */
.illi-cols {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 10px;
}
.illi-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.illi-col-bar {
  width: 26px;
  border-radius: 8px 8px 3px 3px;
  background: linear-gradient(180deg, #a5b4fc, #4f46e5);
}
.illi-col-val { font-size: 11px; font-weight: 800; color: #4338ca; }
.illi-col-label { font-size: 10px; font-weight: 700; color: #64748b; }

/* ===== احترام تفضيل تقليل الحركة ===== */
@media (prefers-reduced-motion: reduce) {
  .grade-btn, .illi-bar > span { transition: none; }
  .mentor-floating, .floating-badge { animation: none; }
}