/* Сторінка «Освіта»: герой із фото, цифри громади, навчальні заклади,
   освітній потенціал і блок співпраці з бізнесом. */

.education-page__body {
  padding-top: 0;
  padding-bottom: 64px;
}

.education {
  color: #1C2633;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
}

/* ---------- Герой ---------- */

.education-hero {
  position: relative;
  overflow: hidden;
  background: #fff;
}

.education-hero__photo {
  position: absolute;
  top: 0;
  right: 0;
  width: 72%;
  height: 100%;
  object-fit: cover;
}

/* Світлий градієнт зліва: текст лягає на білу частину, фото лишається праворуч. */
.education-hero__shade {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: linear-gradient(90deg, #fff 0%, #fff 30%, rgba(255, 255, 255, 0.94) 44%, rgba(255, 255, 255, 0.55) 60%, rgba(255, 255, 255, 0) 78%);
}

.education-hero__inner {
  position: relative;
  padding-top: 26px;
  padding-bottom: 54px;
}

.education-hero__breadcrumb {
  margin-bottom: 18px;
  background: transparent;
}

.education-hero__breadcrumb a,
.education-hero__breadcrumb span {
  color: #65717F;
}

.education-hero__breadcrumb a:hover,
.education-hero__breadcrumb a:focus {
  color: #1B5FAF;
}

.education-hero__title {
  margin: 0 0 18px;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 54px;
  font-weight: 700;
  line-height: 1.1;
}

.education-hero__lead {
  max-width: 560px;
  margin: 0;
  color: #253349;
  font-size: 16px;
  line-height: 1.7;
}

/* ---------- Цифри громади ---------- */

.education__stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}

/* Як у макеті: іконка ліворуч, число і підпис праворуч, світло-блакитна підкладка. */
.education__stat {
  display: grid;
  min-width: 0;
  align-items: center;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 12px;
  padding: 18px 18px 20px;
  border-radius: 10px;
  background: #EAF2FB;
}

.education__stat-icon {
  display: flex;
  width: 46px;
  height: 46px;
  align-items: center;
  justify-content: center;
  color: #1B5FAF;
  font-size: 30px;
}

.education__stat-copy {
  min-width: 0;
}

.education__stat strong {
  display: block;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.15;
}

.education__stat-label {
  display: block;
  margin-top: 2px;
  color: #53677D;
  font-size: 13px;
  line-height: 1.4;
}

/* ---------- Типографіка секцій ---------- */

.education__section {
  margin-top: 46px;
}

.education__section-title {
  position: relative;
  margin: 0 0 24px;
  padding-bottom: 15px;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 30px;
  font-weight: 700;
  line-height: 1.25;
}

/* У макеті акцент під заголовками золотий, а не навігаційний темно-синій. */
.education__section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 56px;
  height: 4px;
  border-radius: 2px;
  background: #F2B716;
}

/* ---------- Навчальні заклади ---------- */

.education__institutions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.education__institution {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(37, 51, 73, 0.1);
  border-radius: 10px;
  background: #F5F8FC;
}

/* Висота задана явно, а не через aspect-ratio: у колонковому flex-контейнері
   відсоткова ширина разом з aspect-ratio згортається до власної висоти знімка. */
.education__institution-photo,
.education__institution-placeholder {
  display: block;
  width: 100%;
  height: 190px;
  flex: 0 0 auto;
  object-fit: cover;
}

/* Для «Професійної та фахової освіти» фото ще немає — замість знімка
   ілюстрація на світлій підкладці, щоб сітка лишалась рівною. */
.education__institution-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: #E3ECF7;
}

.education__institution-placeholder img {
  width: 76%;
  height: auto;
}

.education__institution-footer {
  display: flex;
  min-height: 86px;
  flex: 1 1 auto;
  align-items: center;
  gap: 12px;
  padding: 18px 18px 20px;
  background: #EAF2FB;
}

.education__institution-arrow {
  margin-left: auto;
  color: #1B5FAF;
  font-size: 18px;
}

.education__institution-link {
  display: flex;
  height: 100%;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}

.education__institution-link:hover,
.education__institution-link:focus {
  color: inherit;
  text-decoration: none;
}

.education__institution:hover {
  border-color: rgba(27, 95, 175, 0.4);
  box-shadow: 0 12px 26px rgba(18, 27, 38, 0.1);
}

.education__institution:hover .education__institution-arrow {
  transform: translateX(3px);
}

/* ---------- Перелік закладів одного типу ---------- */

.education__list {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.education__card {
  display: grid;
  align-items: start;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 22px;
  padding: 20px;
  border: 1px solid rgba(37, 51, 73, 0.1);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(18, 27, 38, 0.05);
}

.education__card-photo {
  display: block;
  width: 100%;
  height: 170px;
  border-radius: 8px;
  object-fit: cover;
}

.education__card-photo_empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #E3ECF7;
  color: #9BB4D4;
  font-size: 34px;
}

.education__card-name {
  margin: 0 0 10px;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
}

.education__card-text {
  margin: 0 0 14px;
  color: #53677D;
  font-size: 15px;
  line-height: 1.6;
}

.education__card-contacts {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.education__card-contacts li {
  display: grid;
  align-items: start;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  color: #253349;
  font-size: 14px;
  line-height: 1.5;
}

.education__card-contacts i {
  margin-top: 3px;
  color: #1B5FAF;
  text-align: center;
}

.education__card-contacts a {
  color: #1B5FAF;
  word-break: break-word;
}

/* ---------- Сторінка «Освіта та бізнес» ---------- */

.education__intro {
  display: grid;
  align-items: center;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.42fr);
  gap: 32px;
  margin-top: 8px;
}

.education__intro-lead {
  margin: 0;
  color: #253349;
  font-size: 18px;
  line-height: 1.7;
}

.education__intro-art {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  border-radius: 10px;
  background: #E3ECF7;
}

.education__intro-art img {
  width: 86%;
  height: auto;
}

.education__links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.education__link-card {
  display: grid;
  align-items: center;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 14px;
  padding: 18px 20px;
  border: 1px solid rgba(37, 51, 73, 0.1);
  border-radius: 10px;
  background: #F5F8FC;
  color: inherit;
  text-decoration: none;
  transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease;
}

.education__link-card:hover,
.education__link-card:focus {
  border-color: rgba(27, 95, 175, 0.45);
  background: #EDF4FC;
  box-shadow: 0 10px 24px rgba(18, 27, 38, 0.07);
  color: inherit;
  text-decoration: none;
}

.education__link-icon {
  display: flex;
  width: 48px;
  height: 48px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #EAF2FB;
  color: #1B5FAF;
  font-size: 22px;
}

.education__link-copy {
  min-width: 0;
}

.education__link-title {
  display: block;
  color: #10254B;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
}

.education__link-text {
  display: block;
  margin-top: 3px;
  color: #65717F;
  font-size: 13px;
  line-height: 1.5;
}

.education__link-arrow {
  color: #1B5FAF;
  font-size: 18px;
  transition: transform .18s ease;
}

.education__link-card:hover .education__link-arrow {
  transform: translateX(3px);
}

.education__contacts {
  display: grid;
  align-items: start;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 24px;
  margin-top: 46px;
  padding: 30px 32px;
  border: 1px solid rgba(27, 95, 175, 0.16);
  border-radius: 10px;
  background: #EAF2FB;
}

.education__contacts-icon {
  display: flex;
  width: 72px;
  height: 72px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #1B5FAF;
  color: #fff;
  font-size: 32px;
}

.education__contacts-title {
  margin: 0 0 8px;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.3;
}

.education__contacts-text {
  max-width: 720px;
  margin: 0 0 18px;
  color: #53677D;
  font-size: 15px;
  line-height: 1.65;
}

.education__contacts-list {
  display: grid;
  gap: 12px;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.education__contacts-list li {
  display: grid;
  align-items: start;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  color: #253349;
  font-size: 14px;
  line-height: 1.5;
}

.education__contacts-list i {
  margin-top: 2px;
  color: #1B5FAF;
  text-align: center;
}

.education__contacts-list a {
  color: #253349;
  text-decoration: none;
  word-break: break-word;
}

.education__contacts-list a:hover,
.education__contacts-list a:focus {
  color: #1B5FAF;
  text-decoration: underline;
}

.education__empty {
  margin: 0;
  padding: 28px 22px;
  border: 1px dashed rgba(37, 51, 73, 0.2);
  border-radius: 10px;
  color: #53677D;
  font-size: 15px;
  text-align: center;
}

.education__institution-icon {
  display: flex;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  color: #1B5FAF;
  font-size: 24px;
}

.education__institution-name {
  margin: 0;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
}

/* ---------- Освітній потенціал ---------- */

/* Макет: знімок ліворуч, світла панель із чотирма пунктами праворуч. */
.education__potential-layout {
  display: grid;
  align-items: stretch;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 20px;
}

.education__potential-media {
  display: flex;
  min-height: 340px;
  align-items: center;
  justify-content: center;
  padding: 24px;
  border-radius: 10px;
  background: #E3ECF7;
}

.education__potential-media img {
  width: 82%;
  max-width: 420px;
  height: auto;
}

.education__potential {
  display: grid;
  align-content: start;
  gap: 10px;
  margin: 0;
  padding: 22px;
  border-radius: 10px;
  background: #EAF2FB;
  list-style: none;
}

.education__potential-item {
  display: grid;
  min-width: 0;
  align-items: start;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 16px;
  padding: 14px 16px;
  border-radius: 8px;
  background: transparent;
}

.education__potential-icon {
  display: flex;
  width: 54px;
  height: 54px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #fff;
  color: #1B5FAF;
  font-size: 24px;
}

.education__potential-item h3 {
  margin: 0 0 8px;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
}

.education__potential-item p {
  margin: 0;
  color: #53677D;
  font-size: 14px;
  line-height: 1.6;
}

/* ---------- Освіта та бізнес ---------- */

.education__business {
  position: relative;
  display: grid;
  align-items: center;
  grid-template-columns: minmax(0, 0.32fr) 72px minmax(0, 1fr);
  gap: 24px;
  margin-top: 46px;
  padding: 24px 28px;
  overflow: hidden;
  border: 1px solid rgba(27, 95, 175, 0.16);
  border-radius: 10px;
  background: #EAF2FB;
}

/* Знімок для банера замовник ще не надав — поки ілюстрація. */
.education__business-media {
  display: flex;
  min-height: 150px;
  align-items: center;
  justify-content: center;
  padding: 14px;
  border-radius: 8px;
  background: #DCE7F5;
}

.education__business-media img {
  width: 84%;
  height: auto;
}

.education__business-copy {
  position: relative;
  z-index: 1;
  min-width: 0;
}

/* Декоративні книги праворуч, як у макеті. */
.education__business-decor {
  position: absolute;
  right: 26px;
  bottom: 0;
  width: 168px;
  height: auto;
  pointer-events: none;
}

.education__business-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 12px 26px;
  border: 1px solid #123C6E;
  border-radius: 6px;
  background: #123C6E;
  color: #fff;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color .18s ease, border-color .18s ease;
}

.education__business-btn:hover,
.education__business-btn:focus {
  border-color: #0C2B51;
  background: #0C2B51;
  color: #fff;
  text-decoration: none;
}

.education__business-btn i {
  transition: transform .18s ease;
}

.education__business-btn:hover i {
  transform: translateX(3px);
}

.education__business-icon {
  display: flex;
  width: 72px;
  height: 72px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #1B5FAF;
  color: #fff;
  font-size: 32px;
}

.education__business-title {
  margin: 0 0 8px;
  color: #10254B;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: 26px;
  font-weight: 700;
  line-height: 1.25;
}

.education__business-text {
  max-width: 760px;
  margin: 0;
  color: #53677D;
  font-size: 15px;
  line-height: 1.65;
}

/* ---------- Адаптив ---------- */

@media (max-width: 1199.98px) {
  .education-hero__title {
    font-size: 46px;
  }

  .education__institutions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .education__institution-photo,
  .education__institution-placeholder {
    height: 240px;
  }
}

@media (max-width: 991.98px) {
  .education-hero__photo {
    width: 100%;
  }

  /* Фото займає всю ширину, тому світлу вуаль тримаємо щільною —
     інакше темний текст героя стає нечитабельним. */
  .education-hero__shade {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.97) 0%, rgba(255, 255, 255, 0.93) 55%, rgba(255, 255, 255, 0.82) 100%);
  }

  .education-hero__title {
    font-size: 38px;
  }

  .education__stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 24px;
  }

  .education__section-title {
    font-size: 24px;
  }

  .education__potential-layout {
    grid-template-columns: 1fr;
  }

  .education__potential-media {
    min-height: 220px;
  }
}

@media (max-width: 767.98px) {
  .education-page__body {
    padding-bottom: 44px;
  }

  .education-hero__inner {
    padding-bottom: 40px;
  }

  .education-hero__title {
    font-size: 32px;
  }

  .education__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .education__section {
    margin-top: 36px;
  }

  .education__business {
    grid-template-columns: 1fr;
    padding: 22px 20px 24px;
  }

  .education__business-media {
    min-height: 170px;
  }

  .education__business-decor {
    display: none;
  }

  .education__card {
    grid-template-columns: 1fr;
  }

  .education__card-photo {
    height: 200px;
  }

  .education__intro,
  .education__links {
    grid-template-columns: 1fr;
  }

  .education__contacts {
    grid-template-columns: 1fr;
    padding: 22px 20px 24px;
  }
}

@media (max-width: 575.98px) {
  .education {
    font-size: 16px;
  }

  .education__institutions {
    grid-template-columns: 1fr;
  }

  /* П'ять метрик в один стовпчик надто розтягують сторінку — лишаємо дві колонки. */
  .education__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .education__stat {
    padding: 18px 12px 20px;
  }

  .education__stat strong {
    font-size: 26px;
  }

  .education__institution-photo,
  .education__institution-placeholder {
    height: 200px;
  }
}
