/* Стили для страницы AllMosqueCourses */
/* Этот файл содержит стили, специфичные для страницы all_mosque_courses */

.hero-section {
  position: relative;
  overflow: visible;
}

.all-mosque-courses-page .course-title {
  font-size: 32px !important;
}

.hero-info-name--green {
  margin-top: 8px;
  text-shadow: 0px 16px 25px #10866929;
}

@media (max-width: 768px) {
  .all-mosque-courses-page .hero-section .hero-info-name--black,
  .all-mosque-courses-page .hero-section .hero-info-name--green {
    margin-top: 6px !important;
  }

  .all-mosque-courses-page .hero-section .hero-info {
    align-items: flex-start !important;
  }

  .all-mosque-courses-page .hero-section .hero-info-title,
  .all-mosque-courses-page .hero-section .hero-info-name,
  .all-mosque-courses-page .hero-section .hero-info-description {
    text-align: left !important;
    width: 100%;
  }

  .all-mosque-courses-page .hero-section .hero-info-title {
    font-size: 16px !important;
  }

  .all-mosque-courses-page .hero-section .hero-info-description {
    font-size: 14px !important;
    margin-top: 10px !important;
  }

  .all-mosque-courses-page .hero-section .hero-info-buttons {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    width: 100%;
    margin-top: 24px !important;
    margin-bottom: 64px !important;
  }

  .all-mosque-courses-page .hero-section .hero-info-btn,
  .all-mosque-courses-page .hero-section .hero-info-btn--outline {
    width: 100% !important;
    box-sizing: border-box;
    display: block;
    text-align: center;
  }

  .all-mosque-courses-page .hero-section .hero-info-btn {
    background: var(--color-green) !important;
    color: #FFFFFF !important;
    border: none !important;
  }

  .all-mosque-courses-page .hero-section .hero-info-btn.hero-info-btn--outline {
    background: #FFFFFF !important;
    color: #108669 !important;
    border: 1px solid #108669 !important;
  }

  .all-mosque-courses-page .courses-header-title {
    font-size: 28px !important;
  }

  .all-mosque-courses-page .courses-header-btn {
    font-size: 16px !important;
    padding: 11px 24px !important;
  }

  .all-mosque-courses-page .courses-container {
    padding-inline: 20px !important;
    gap: 24px !important;
  }

  .courses-container {
    padding-inline: 20px !important;
  }

  .all-mosque-courses-page .courses-container {
    margin-bottom: 64px !important;
  }

  .all-mosque-courses-page .courses-info-row {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  .all-mosque-courses-page .course-params {
    font-size: 12px !important;
  }

  .all-mosque-courses-page .course-title {
    font-size: 24px !important;
  }

  .all-mosque-courses-page .course-text {
    font-size: 14px !important;
  }

  .all-mosque-courses-page .footer-container {
    padding-inline: 0 !important;
  }
}

.hero-info-buttons {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 40px;
  margin-bottom: 60px;
}

.hero-container {
  position: relative;
  max-width: 1500px;
  padding: 32px 24px 0px 24px;
  margin: 0 auto;
  z-index: 1;
}

.hero-info-btn {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.hero-info-btn--outline {
  background: #FFFFFF !important;
  color: #108669 !important;
  border: 1px solid #108669 !important;
}

.courses-container {
  max-width: 1500px;
  margin-left: auto;
  margin-right: auto;
  padding-inline: clamp(24px, calc(100px - (1440px - 100vw) * 76px / 416px), 100px);
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-bottom: 160px;
  position: relative;
  z-index: 1;
}

.courses-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.courses-header-title {
  font-family: 'SF Pro', system-ui, -apple-system, sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: 56px;
  line-height: 100%;
  color: #2B2B2B;
  margin: 0;
}

.courses-header-btn {
  border-radius: 36px;
  opacity: 1;
  padding: 16px 32px;
  gap: 10px;
  background: #FFFFFF !important;
  border: 1px solid #108669;
  cursor: pointer;
  font-family: system-ui, -apple-system, 'SF Pro', 'SF Pro Text', 'SF Pro Display', 'Segoe UI', sans-serif;
  font-weight: 590;
  font-style: normal;
  font-size: 20px;
  line-height: 100%;
  letter-spacing: -0.01em;
  color: #108669;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.courses-info-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  width: 100%;
  align-items: start;
  margin-bottom: 40px;
}

.courses-info-row:last-child {
  margin-bottom: 0;
}

@media (min-width: 769px) and (max-width: 1279px) {
  .all-mosque-courses-page .courses-info-row {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

.course-card {
  padding: 24px;
  border-radius: 32px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 24px;
  background: #FFFFFF;
  box-shadow: 0px 0px 24px 1px #2F2F2F0A,
              0px 1px 1px -0.5px #2F2F2F0A,
              0px 3px 3px -1.5px #2F2F2F0A,
              0px 6px 6px -3px #2F2F2F0A,
              0px 12px 12px -6px #2F2F2F0A,
              0px 24px 24px -12px #2F2F2F0A,
              0px 0px 0px 1px #2F2F2F0A;
}

.course-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.course-params {
  font-family: system-ui, -apple-system, 'SF Pro', 'SF Pro Text', 'SF Pro Display', 'Segoe UI', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 100%;
  color: #BABABA;
}

.course-title {
  font-family: system-ui, -apple-system, 'SF Pro', 'SF Pro Text', 'SF Pro Display', 'Segoe UI', sans-serif;
  font-weight: 510;
  font-size: 32px;
  line-height: 100%;
  color: #2B2B2B;
  margin: 0;
}

.course-photo-placeholder {
  width: 100%;
  aspect-ratio: 427 / 300;
  background: #D9D9D9;
  border-radius: 16px;
  flex-shrink: 0;
}

.course-text-block {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.course-text-container {
  margin-bottom: 0;
}

.course-text {
  font-family: system-ui, -apple-system, 'SF Pro', 'SF Pro Text', 'SF Pro Display', 'Segoe UI', sans-serif;
  font-weight: 400;
  font-size: 20px;
  line-height: 100%;
  color: #2B2B2B;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.courses-more-wrapper {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

.courses-more-btn {
  font-family: 'SF Pro', system-ui, -apple-system, sans-serif;
  font-weight: 510;
  font-style: normal;
  font-size: 16px;
  line-height: 100%;
  letter-spacing: -0.01em;
  background: #FFFFFF;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  position: relative;
  padding-bottom: 4px;
}

.courses-more-btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: #108669;
}

.courses-more-text {
  color: #108669;
}

.courses-more-btn .header-lang-arrow {
  filter: brightness(0) saturate(100%) invert(35%) sepia(73%) saturate(1126%) hue-rotate(126deg) brightness(99%) contrast(101%);
}

.courses-more-btn--hide .header-lang-arrow {
  transform: rotate(180deg);
}

.footer-container {
  max-width: 1500px;
  margin-left: auto;
  margin-right: auto;
  padding-inline: clamp(24px, calc(100px - (1440px - 100vw) * 76px / 416px), 100px);
}


/* Карточки курсов одной высоты, даже если название в две строки */
.courses-info-row {
  align-items: stretch;
}

.course-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

/* Фильтр курсов по мечети. Кнопка остаётся прежней («Мечеть» со стрелкой),
   под ней открывается список мечетей, у которых есть курсы. */
.courses-filter {
  position: relative;
  flex-shrink: 0;
}

.courses-filter-arrow--up {
  transform: rotate(180deg);
}

.courses-filter-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 10;
  min-width: max(100%, 260px);
  max-width: min(360px, calc(100vw - 48px));
  max-height: 320px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px;
  background: #FFFFFF;
  border: 1px solid #E4E4E4;
  border-radius: 20px;
  box-shadow: 0px 12px 32px rgba(47, 47, 47, 0.12);
}

.courses-filter-menu[hidden] {
  display: none;
}

.courses-filter-option {
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  padding: 12px 16px;
  border-radius: 14px;
  font-family: system-ui, -apple-system, 'SF Pro', 'SF Pro Text', 'SF Pro Display', 'Segoe UI', sans-serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 130%;
  color: #2B2B2B;
}

.courses-filter-option:hover,
.courses-filter-option:focus-visible {
  background: rgba(16, 134, 105, 0.07);
}

.courses-filter-option--active {
  color: #108669;
  font-weight: 590;
}

@media (max-width: 768px) {
  .all-mosque-courses-page .courses-filter-option {
    font-size: 16px !important;
    padding: 10px 14px !important;
  }

  .all-mosque-courses-page .courses-filter-menu {
    border-radius: 16px !important;
  }
}
