/* =========================================================
   كروت الصفحة الرئيسية — تصميم موحّد
   بيتحمّل في Site/home.blade.php بس، بعد style.css
   ========================================================= */

:root {
  --card-bg: #ffffff;
  --card-border: #E8ECF3;
  --card-radius: 18px;
  --card-shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 10px 28px -14px rgba(16, 24, 40, 0.16);
  --card-shadow-hover: 0 22px 44px -18px rgba(34, 133, 252, 0.38), 0 2px 6px rgba(16, 24, 40, 0.05);
  --card-brand: #2285FC;
  --card-brand-soft: #EAF3FF;
  --card-ink: #1A202C;
  --card-muted: #6B7280;
  --card-line: #EEF1F6;
  --card-ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- سلايدر: كل الكروت في الصف بنفس الارتفاع ---------- */
body #teachers .slick-track {
  display: flex !important;
}

body #teachers .slick-slide {
  height: auto;
  display: flex !important;
}

body #teachers .slick-slide > div {
  display: flex !important;
  width: 100%;
}

/* مساحة للظل والحركة جوه السلايدر */
body #teachers .slick-list {
  padding: 14px 0 26px !important;
  margin: -14px 0 -26px;
}

/* كارت الجامعة اتنقل لـ university-card.css (مشترك مع /coursesuniversity) */

/* =========================================================
   3) كارت المعلم
   ========================================================= */
body #teachers .slick-slide {
  margin: 0 10px;
}

body #teachers .item.teacher-card {
  position: relative;
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  max-width: none;
  margin-top: 0;
  padding: 0 0 0;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
  overflow: hidden;
  cursor: pointer;
  transition: transform .3s var(--card-ease), box-shadow .3s var(--card-ease), border-color .3s;
}

body #teachers .item.teacher-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--card-shadow-hover);
  border-color: #CFE2FF;
}

body #teachers .teacher-card .teacher-cover {
  width: 100%;
  height: 74px;
  background:
    radial-gradient(circle at 15% 120%, rgba(255, 255, 255, .35) 0 40px, transparent 41px),
    radial-gradient(circle at 90% -20%, rgba(255, 255, 255, .25) 0 50px, transparent 51px),
    linear-gradient(120deg, #2285FC, #69B8FF);
}

body #teachers .teacher-card .teacher-img {
  position: relative;
  top: auto;
  width: 96px;
  height: 96px;
  margin-top: -48px;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid #fff;
  background: #EEF3FA;
  box-shadow: 0 8px 20px -8px rgba(16, 24, 40, .35);
  /* لو الصورة اتكسرت ما نعرضش الـ alt جوه الدايرة */
  font-size: 0;
  color: transparent;
}

body #teachers .teacher-card .seperator {
  margin-top: 12px;
  padding: 0 16px;
  width: 100%;
  flex: 1 1 auto;
}

body #teachers .teacher-card h6 {
  max-width: 100%;
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 700;
  color: var(--card-ink);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body #teachers .teacher-card .teacher-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 16px;
}

body #teachers .teacher-card .teacher-subject {
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--card-brand-soft);
  color: var(--card-brand);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
}

body #teachers .teacher-card .teacher-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-top: auto;
  padding: 12px 16px;
  border-top: 1px solid var(--card-line);
  font-size: 13px;
}

body #teachers .teacher-card .teacher-count {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--card-muted);
  font-weight: 600;
}

body #teachers .teacher-card .teacher-count i {
  color: var(--card-brand);
}

body #teachers .teacher-card .teacher-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--card-brand);
  font-weight: 700;
  transition: gap .2s;
}

body #teachers .teacher-card:hover .teacher-link {
  gap: 10px;
}

/* =========================================================
   4) آراء الطلاب — صفين كروت بيتحركوا لوحدهم
   ========================================================= */
body #reviews.reviews-wall {
  position: relative;
  overflow: hidden;
  padding: 72px 0 80px;
  background:
    radial-gradient(60% 50% at 85% 20%, rgba(34, 133, 252, .08), transparent 70%),
    radial-gradient(50% 50% at 10% 85%, rgba(110, 193, 255, .12), transparent 70%),
    #F7FAFF;
}

body #reviews .reviews-wall__head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-bottom: 36px;
  text-align: center;
}

body #reviews .reviews-wall__eyebrow {
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--card-brand-soft);
  color: var(--card-brand);
  font-size: 13px;
  font-weight: 700;
}

body #reviews h4.reviews-wall__title {
  margin: 6px 0 2px;
  font-size: 30px;
  font-weight: 800;
  color: var(--card-ink);
}

body #reviews .reviews-wall__all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--card-brand);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: gap .2s;
}

body #reviews .reviews-wall__all:hover {
  gap: 12px;
}

body #reviews .reviews-wall__rows {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* الأطراف بتختفي بالتدريج */
body #reviews .reviews-marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
}

body #reviews .reviews-marquee__track {
  display: flex;
  width: max-content;
  padding: 10px 0 18px;
  animation: reviews-marquee var(--marquee-duration, 60s) linear infinite;
}

body #reviews .reviews-marquee--reverse .reviews-marquee__track {
  animation-direction: reverse;
}

/* الصف التاني مزاح نص كارت زي الطوب */
body #reviews .reviews-marquee--reverse {
  margin-inline-start: -180px;
}

body #reviews .reviews-marquee:hover .reviews-marquee__track {
  animation-play-state: paused;
}

body #reviews .reviews-marquee__group {
  display: flex;
  gap: 22px;
  padding-inline-end: 22px;
}

/* RTL: المجموعة الأولى يمين والنسخة شمالها، فنحرك بعرض مجموعة واحدة (نص التراك) */
@keyframes reviews-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(50%); }
}

body #reviews .review-card {
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  width: 360px;
  padding: 22px 24px 20px;
  background: #fff;
  border: 1px solid rgba(227, 233, 243, .8);
  border-radius: 22px;
  box-shadow: 0 0 30px rgba(34, 133, 252, .10);
  transition: transform .3s var(--card-ease), box-shadow .3s var(--card-ease);
}

body #reviews .review-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px -16px rgba(34, 133, 252, .35);
}

body #reviews .review-card__head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

body #reviews .review-card__avatar {
  flex-shrink: 0;
  width: 58px;
  height: 58px;
  padding: 2px;
  border-radius: 50%;
  object-fit: cover;
  background: linear-gradient(135deg, #6EC1FF, #2285FC);
}

body #reviews .review-card__who {
  min-width: 0;
}

body #reviews h6.review-card__name {
  margin: 0 0 6px;
  overflow: hidden;
  color: var(--card-ink);
  font-size: 16px;
  font-weight: 800;
  white-space: nowrap;
  text-overflow: ellipsis;
}

body #reviews .review-card__rating {
  display: flex;
  align-items: center;
  gap: 6px;
}

body #reviews .review-card__score {
  color: var(--card-ink);
  font-size: 13px;
  font-weight: 700;
}

body #reviews .review-card__stars {
  display: inline-flex;
  gap: 3px;
  font-size: 13px;
  color: #E3E7EE;
}

body #reviews .review-card__stars .is-on {
  color: #FFB400;
}

body #reviews p.review-card__text {
  flex: 1 1 auto;
  margin: 0 0 14px !important;
  color: #4B5563;
  font-size: 14px;
  line-height: 1.9;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

body #reviews .review-card__course {
  align-self: flex-start;
  max-width: 100%;
  overflow: hidden;
  padding: 5px 12px;
  border-radius: 999px;
  background: #F3F6FB;
  color: var(--card-muted);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

body #reviews .review-card__course i {
  margin-inline-end: 4px;
  color: var(--card-brand);
}

@media (max-width: 575px) {
  body #reviews.reviews-wall {
    padding: 48px 0 56px;
  }

  body #reviews h4.reviews-wall__title {
    font-size: 24px;
  }

  body #reviews .review-card {
    width: 280px;
    padding: 18px;
  }

  body #reviews .reviews-marquee--reverse {
    margin-inline-start: -140px;
  }
}

/* اللي مفعّل تقليل الحركة: من غير حركة، ويقدر يسحب بإيده */
@media (prefers-reduced-motion: reduce) {
  body #reviews .reviews-marquee {
    overflow-x: auto;
    -webkit-mask-image: none;
    mask-image: none;
  }

  body #reviews .reviews-marquee__track {
    animation: none;
  }

  body #reviews .reviews-marquee__group[aria-hidden="true"] {
    display: none;
  }
}

/* =========================================================
   5) ليش يوستدي — كروت المميزات
   ========================================================= */
body #why_choose_us .item {
  align-items: flex-start;
  gap: 16px;
  margin: 0 0 16px;
  padding: 18px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
  transition: transform .3s var(--card-ease), box-shadow .3s var(--card-ease);
}

body #why_choose_us .item:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
}

/* كل الأيقونات نفس المقاس بالظبط */
body #why_choose_us .item .icon-wrapper {
  flex: 0 0 56px;
  width: 56px;
  height: 56px;
  padding: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #2285FC, #4FA3FF);
  box-shadow: 0 10px 20px -10px rgba(34, 133, 252, .8);
}

body #why_choose_us .item .icon-wrapper i {
  font-size: 1.4rem;
}

body #why_choose_us .item .text-wrapper {
  margin: 0;
}

body #why_choose_us .item .text-wrapper h6 {
  margin: 2px 0 6px;
  font-size: 16px;
  font-weight: 700;
  color: var(--card-ink);
}

body #why_choose_us .item .text-wrapper p {
  margin: 0 !important;
  font-size: 14px;
  line-height: 1.7;
  color: var(--card-muted);
}

/* =========================================================
   موبايل
   ========================================================= */
@media (max-width: 575px) {
  body #teachers .slick-slide {
    margin: 0 6px;
  }

  body #why_choose_us .item {
    padding: 14px;
  }
}

/* اللي مفعّل تقليل الحركة */
@media (prefers-reduced-motion: reduce) {
  body #teachers .item.teacher-card,
  body #why_choose_us .item {
    transition: none;
  }
}
