

.image-wrapper {
    position: relative;
    height: 100%;
    overflow: hidden;
    width: 100%;
    margin: 0 auto;
    object-fit: cover;
    background: #0f172a;
}

.image-wrapper img {
    margin-top: 4.9rem;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
     border-radius: 80px 80px 0 0;
}


.image-wrapper::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0),
        #ffffff
    );
}



.Arabic-info {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 3rem;
  width: 100%;
  margin: 4rem auto 0;
  background: #fff;
  align-items: start;
}


.left-info {
  margin-top: 1rem;
}

.top-info {
  display: flex;
  gap: 25px;
  align-items: center;
}

.teacher-img {
  width: 150px;
  height: 150px;
  border-radius: 20px;
  object-fit: cover;
  border: 1px solid darksalmon;
}

.left-info h2 {
  font-size: clamp(36px, 6vw, 30px);
  font-weight: bold;
  margin-top: -0.6rem;
}


.subject {
  font-size: 17px;
  color: #0E2147;
}

.rating-2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18.5px !important;
  color: #0E2147;
}
.rating-2 small{
    font-size: 20px;
    margin-left: 0.3rem;
}

.rating-2 i {
  color: #fbbf24;
}



.desc-3 {
  font-size: 15px;
  line-height: 1.6;
  color: #555;
  max-width: 500px;
}

/* =========================
   AVATARS
========================= */
.avatars {
  display: flex;
  align-items: center;
  margin-top: 15px;
}

.avatars img {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  border: 2px solid #fff;
  margin-left: -10px;
}

.avatars span {
  margin-left: 10px;
  background: #fde2e2;
  padding: 6px 10px;
  border-radius: 50%;
  font-size: 13px;
}

/* =========================
   RIGHT SIDE
========================= */
.Teacher-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* buttons */
.teachers-actions {
  display: block;
  margin-top: 0.2rem;
}

.teachers-actions button {
 width: 100%;
  flex: 1;
  border: none;
  padding: 12px 0;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  margin-top: 10px;
  cursor: pointer;
}


/* Book */
.book-btn {
    background: darksalmon !important;
    color: #0f172a;
}




.book-btn:hover {
background: #0E2147;
color: #fff;
transition: background 0.3s ease, color 0.3s ease;
}

/* video */
.video-card {
  width: 100%;
  height: 260px;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  background: black;
}

.video-card video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-overlay {
  position: absolute;
  inset: 0;
  background-image: url('/images/ArabicCourse.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.teacher-meta h1{
    font-size: 40px;
    font-weight: 800;
}

.custom-play i {
  width: 65px;
  height: 65px;
  background: rgba(0, 194, 190, 0.9);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  animation: pulse 1.5s infinite;
}

.video-title {
   font-size: clamp(18px, 2vw, 18px);
  position: absolute;
  bottom: -5px;
  cursor: pointer;
  left: 15px;
  color: #fff;
  font-weight: 600;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}


/*RESPONSIVE */
@media (max-width: 768px) {
  .Arabic-info {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .teachers-actions {
    flex-direction: column;
  }

  .video-card {
    height: 220px;
  }


}


@media (max-width: 400px) {
  .teacher-img {
    width: 70px;
    height: 70px;
  }

  .left-info h2 {
    font-size: 18px;
  }

  .subject,
  .rating {
    font-size: 13px;
  }
}


.programs {
    width: 100%;
    padding: 20px 0 40px;
}

.programs h2 {
    font-size: clamp(28px, 5vw, 42px);
    font-weight: 900;
    margin-bottom: 40px;
    color: #1a1a2e;
}

/* ===== GRID ===== */
.programs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px 24px;
}

/* ===== CARD ===== */
.program-card {
    position: relative;
    background: #f6f6f6;
    border-radius: 16px;
    padding: 24px 22px;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.program-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.07);
}

.program-card.active {
    background: linear-gradient(135deg, #ffb6c1, #ffd6dc);
}

.program-card.has-border-right {
    border-right: 2px dashed #ccc;
}


.program-card.second-row-first {
    grid-column: 1;
}


.arrow-middle-cell {
    grid-column: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #555;
    opacity: 0.6;
    min-height: 220px;
}


.program-card.second-row-last {
    grid-column: 3;
}

/* ===== TITLE ===== */
.program-card h3 {
    font-size: 16px;
    font-weight: 800;
    text-align: center;
    color: #1a1a2e;
    line-height: 1.4;
    margin-bottom: 10px;
}

/* ===== DOT ===== */
.prog-dot {
    width: 22px;
    height: 22px;
    background: #aaa;
    border-radius: 50%;
    display: block;
    margin: 0 auto 16px;
    opacity: 0.6;
    flex-shrink: 0;
}

/* ===== LIST ===== */
.program-card ul {
    list-style: disc;
    padding-left: 18px;
    flex: 1;
}

.program-card li {
    font-size: 13px;
    color: #444;
    margin-bottom: 10px;
    line-height: 1.5;
    text-align: left;
}

.program-card li.placeholder-item {
    visibility: hidden;
    min-height: 20px;
}

/* ===== ARROWS ===== */
.prog-arrow {
    position: absolute;
    top: 45%;
    transform: translateY(-50%);
    font-size: 16px;
    z-index: 2;
    opacity: 0.7;
    color: #555;
}

.prog-arrow-right {
    right: -16px;
}

.prog-arrow-left-outside {
    left: -20px;
    position: absolute;
    top: 45%;
    transform: translateY(-50%);
    font-size: 16px;
    color: #555;
    opacity: 0.7;
}

.program-card.active .prog-arrow,
.program-card.active .prog-arrow-left-outside {
    color: #222;
    opacity: 1;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .programs-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .program-card.second-row-first,
    .program-card.second-row-middle,
    .program-card.second-row-last {
        grid-column: auto;
    }
    .arrow-middle-cell {
        display: none;
    }
}

@media (max-width: 600px) {
    .programs-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .prog-arrow,
    .prog-arrow-left-outside,
    .arrow-middle-cell,
    .program-card.has-border-right {
        display: none;
        border-right: none;
    }
    .program-card {
        min-height: 160px;
        grid-column: auto !important;
    }
}

/* end PROGRAMS  */


.teachers-wrapper {
    width: 100%;
    margin: 0 auto;
  position: relative;
  overflow: hidden;
  transition: max-height 0.6s ease;
}

.teachers-grid{
display: grid;
   width: 100% !important;
   grid-template-columns: 1fr 1fr;
  gap: 25px;
  margin: 0 auto;
   grid-auto-rows: 1fr;
}
.teachers-section h2{
    text-align: left;
    margin-top: 3rem;
   font-size: clamp(30px, 6vw, 40px);
   font-weight: bold;
}

.teachers-wrapper.collapsed {
  max-height: 400px; 
}


.teachers-wrapper.expanded {
  max-height: 2600px; 
}


.fade-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(
    to bottom,
    rgba(255,255,255,0),
    #fff
  );
  pointer-events: none;
  transition: opacity 0.4s ease;
}


.teachers-wrapper.expanded .fade-overlay {
  opacity: 0;
}


.view-more {
  margin: 30px auto 0;
  display: block;
  background: none;
  border: none;
  font-size: 25px;
  font-weight: 900;
  cursor: pointer;
  position: relative;
  top: -2rem;
  color: #000;
}
.view-more:hover {
  color: #000;
}

.view-more::after {
  content: "";
  display: block;
  width: 150px;
  height: 2px;
  background: #000;
  margin: 6px auto 0;
}



.teacher-card {
 display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 240px;
  background: #f7f7f7;
  border-radius: 20px;
  padding: 18px;
  transition: 0.3s;
}

.teacher-card:hover {
  background: #a5dbec;
}
.teacher-card .book-btn a{
    color: #0E2147 !important;
    text-decoration: none;
}
.teacher-card:hover button a{
    color: #0E2147 !important;
    transition: 0.7s;
}
.teacher-card:hover .follow-btn{
    background: transparent !important;
    color: #0E2147 !important;
    border: 1px solid #0E2147 !important;
}
.teacher-card .book-btn{
    color: #0E2147;
}
/* top */
.card-top {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* avatar */
.avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 20px;
}

.avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.avatar.dark {
  background: #0f172a;
  color: #fff;
}

/* info */
.info h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
}

.subject {
  font-size: 12.5px;
  color: black;
  font-weight: 700;
}

.rating {
  margin-top: 4px;
  font-size: 13px;
  color: #444;
}

.rating i {
  color: #fbbf24;
}

/* actions */
.actions {
  margin-left: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.actions i {
  cursor: pointer;
  font-size: 18px;
}




/* desc */
.desc {
  margin: 20px 0 14px;
    font-size: 14px;
    color: #555;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    position: relative;
    flex: 1;
    min-height: 63px;
  position: relative;
}
.desc::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1.9em;
  background: linear-gradient(to bottom, rgba(247, 247, 247, 0), #fff);

}
.teacher-card:hover .desc::after {
    transition: all;
  background: linear-gradient(
    to bottom,
    rgba(233, 243, 246, 0),
    #a5dbec
  );
}


/* button */
.btn-click {
    display: flex;
    gap: 12px;
}


.btn-click > * {
    all: unset;
    box-sizing: border-box;
    flex: 1;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
}

/* Book */
.book-btn {
    background: darksalmon !important;
    color: #0f172a;
}

/* Follow */
.follow-btn {
    background: #0f172a !important;
    color: darksalmon;
}

.book-btn,
.follow-btn{
transition: background 0.3s ease, color 0.3s ease;
}

@media (max-width: 767px) {


/* start of CARD */

.teachers-section{
    padding: 60px 20px;
}

.teachers-grid {
    display: grid;
    width: 100% !important;
   grid-template-columns: 1fr !important;
    gap: 25px;
    margin: 0 auto;
    grid-auto-rows: 1fr;
}


}


/* pagination */
.pagination{
  display:flex;
  justify-content:center;
  align-items:center;
  gap: 10px;
  margin-top:40px;
  font-weight: 600;
  color: white;
}

.pagination button{
  background:#fff;
  border:none;
  width:28px;
  height:28px;
  font-size: 17px;
  border-radius:5px;
  cursor:pointer;
  display: flex;
  justify-content: center;
  color: #0E2147;
  align-items: center;
}

.page{
  cursor:pointer;
  padding: 0.9px 10px;
  border-radius:8px;
  text-align: center;
}

.page.active{
  background: #ffffff71;
  color:#fff;
}
.heart-btn {
  cursor: pointer;
  transition: color 0.3s ease, transform 0.2s ease;
}

.heart-btn.active {
  color: #e11d48;
  font-weight: 900;
}

.heart-btn.active:hover {
  transform: scale(1.1);
}
.info small{
    font-size: 12px;
}
@media (max-width: 915px) {
  .teachers-section h2{
    text-align: left;
    margin: 0 auto;
    position: relative;
    top: 1rem;
  }
}

/* mobile */
@media (max-width: 600px) {
  .teachers-grid {
    grid-template-columns: 1fr;
  }

  .card-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .actions {
    flex-direction: row;
    width: 100%;
    justify-content: space-between;
  }
}
