.page-template-management {
  background-color: #f4f7fb;
}

.page-template-management .main-content {
  padding-top: 32px;
  padding-bottom: 36px;
}

.page-template-management .block-grid-item {
  display: flex;
}

.page-template-management .customer-link {
  display: flex;
  flex: 1;
  flex-direction: column;
  overflow: hidden;
  color: inherit;
  background: #fff;
  border: 1px solid #e1e8ef;
  border-radius: 16px;
  box-shadow: 0 5px 18px rgba(22, 50, 79, 0.08);
  text-align: right;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.page-template-management .customer-link:hover,
.page-template-management .customer-link:focus {
  background: #fff;
  border-color: #b7d9e8;
  box-shadow: 0 12px 28px rgba(22, 50, 79, 0.15);
  transform: translateY(-4px);
}

.page-template-management .customer-link:focus-visible {
  outline: 3px solid #168bb8;
  outline-offset: 3px;
}

.page-template-management .customer-link .customer-img {
  flex: none;
  height: clamp(240px, 27vw, 340px);
  min-height: 0;
  background-size: cover;
  background-position: center 28%;
  border: 0;
  border-radius: 0;
}

.page-template-management .customer-link .customer-description {
  flex: 1;
  min-height: 145px;
  padding: 21px 20px 24px;
  background: #fff;
}

.page-template-management .customer-link .customer-description .customer-title {
  margin-bottom: 8px;
  color: #087da8;
  font-size: 25px;
  line-height: 1.3;
}

.page-template-management .customer-link .customer-description .customer-about {
  color: #596875;
  font-size: 16px;
  line-height: 1.55;
}

.page-template-management .customer-link:hover .customer-title,
.page-template-management .customer-link:focus .customer-title {
  color: #075d80;
}

#fancybox-wrap {
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  width: min(920px, calc(100vw - 40px)) !important;
  height: auto !important;
  max-height: calc(100vh - 40px) !important;
  transform: translate(-50%, -50%) !important;
}

#fancybox-outer,
#fancybox-content {
  width: 100% !important;
  height: auto !important;
}

#fancybox-outer {
  overflow: visible;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 22px 65px rgba(9, 28, 45, 0.28);
}

#fancybox-close {
  top: 10px !important;
  right: 10px !important;
  left: auto !important;
}

#fancybox-content {
  overflow: visible !important;
  border-radius: 18px;
}

#fancybox-content > div {
  width: 100% !important;
  height: auto !important;
  max-width: none !important;
  max-height: none !important;
  overflow: visible !important;
  padding: 30px 34px !important;
  box-sizing: border-box;
}

#fancybox-content .media {
  display: flex;
  align-items: flex-start;
  gap: 26px;
  margin: 0;
}

#fancybox-content .media-left {
  display: block;
  flex: 0 0 170px;
  min-width: 0;
  padding-left: 0;
}

#fancybox-content .media-left img {
  display: block;
  width: 170px;
  height: 190px;
  border-radius: 12px;
  object-fit: cover;
}

#fancybox-content .media-body {
  display: block;
  flex: 1;
  min-width: 0;
  width: auto;
  color: #354451;
  font-size: 15px;
  line-height: 1.55;
}

#fancybox-content .media-heading {
  margin: 0 0 4px;
  color: #087da8;
  font-size: 25px;
  font-weight: 600;
  line-height: 1.3;
}

#fancybox-content .media-body h4 + h4 {
  margin: 0 0 16px;
  color: #687783;
  font-size: 16px;
  font-weight: 400;
}

#fancybox-content .media-body p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
}

@media (max-width: 767px) {
  .page-template-management .main-content {
    padding-top: 18px;
  }

  .page-template-management .customer-link .customer-img {
    height: clamp(230px, 65vw, 310px);
  }

  .page-template-management .customer-link .customer-description {
    min-height: 0;
    padding: 16px 18px 19px;
    text-align: center;
  }

  .page-template-management .customer-link .customer-description .customer-title {
    font-size: 22px;
  }

  #fancybox-wrap {
    width: calc(100vw - 28px) !important;
    height: auto !important;
    max-height: calc(100vh - 28px) !important;
  }

  #fancybox-content > div {
    padding: 22px 18px !important;
  }

  #fancybox-content .media {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  #fancybox-content .media-left {
    flex-basis: auto;
    align-self: flex-start;
  }

  #fancybox-content .media-left img {
    width: 112px;
    height: 124px;
  }

  #fancybox-content .media-heading {
    font-size: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-template-management .customer-link {
    transition: none;
  }
}

body.page-template-customers {
  background-color: #f4f7fb;
}

body.page-template-customers .page-template-cards .main-content {
  padding-top: 32px;
  padding-bottom: 36px;
}

body.page-template-customers .page-template-cards .categories {
  margin-bottom: 26px;
}

body.page-template-customers .page-template-cards .categories .btn-green {
  min-height: 48px;
  padding: 12px 28px;
  border: 0;
  border-radius: 24px;
  box-shadow: 0 5px 16px rgba(22, 50, 79, 0.12);
  font-size: 16px;
  font-weight: 600;
}

body.page-template-customers .page-template-cards .block-grid-item {
  display: flex;
}

body.page-template-customers .page-template-cards .customer-link {
  display: flex;
  flex: 1;
  flex-direction: column;
  overflow: hidden;
  color: inherit;
  background: #fff;
  border: 1px solid #e1e8ef;
  border-radius: 16px;
  box-shadow: 0 5px 18px rgba(22, 50, 79, 0.08);
  text-align: center;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

body.page-template-customers .page-template-cards .customer-link:hover,
body.page-template-customers .page-template-cards .customer-link:focus {
  background: #fff;
  border-color: #b7d9e8;
  box-shadow: 0 12px 28px rgba(22, 50, 79, 0.15);
  transform: translateY(-4px);
}

body.page-template-customers .page-template-cards .customer-link:focus-visible {
  outline: 3px solid #168bb8;
  outline-offset: 3px;
}

body.page-template-customers .page-template-cards .customer-link .customer-img {
  flex: none;
  height: 190px;
  min-height: 0;
  margin: 12px 12px 0;
  background-color: #fff;
  background-size: contain;
  background-position: center;
  border: 0;
  border-radius: 12px;
}

body.page-template-customers .page-template-cards .customer-link .customer-description {
  flex: 1;
  min-height: 150px;
  padding: 20px 18px 24px;
  background: #fff;
}

body.page-template-customers .page-template-cards .customer-link .customer-description .customer-title {
  margin-bottom: 8px;
  color: #087da8;
  font-size: 23px;
  line-height: 1.35;
}

body.page-template-customers .page-template-cards .customer-link .customer-description .customer-about {
  color: #596875;
  font-size: 15px;
  line-height: 1.6;
}

body.page-template-customers .page-template-cards .customer-link:hover .customer-title,
body.page-template-customers .page-template-cards .customer-link:focus .customer-title {
  color: #075d80;
}

body.page-template-customers .page-template-cards .customer-link:hover .customer-about,
body.page-template-customers .page-template-cards .customer-link:focus .customer-about {
  color: #465563;
}

@media (max-width: 767px) {
  body.page-template-customers .page-template-cards .main-content {
    padding-top: 18px;
  }

  body.page-template-customers .page-template-cards .customer-link .customer-img {
    height: clamp(150px, 48vw, 200px);
  }

  body.page-template-customers .page-template-cards .customer-link .customer-description {
    min-height: 0;
    padding: 16px 16px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.page-template-customers .page-template-cards .customer-link {
    transition: none;
  }
}
