/* Titles explain the service; compact process maps illustrate the actual work. */
.services .service-step-list {
  gap: 30px;
}

.services .service-step-card {
  --step-padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0 var(--step-padding) 24px;
  text-align: left;
  border-radius: 20px;
}

.services .service-step-label {
  flex: none;
  height: 52px;
  padding-block: 6px;
  margin: 0 calc(-1 * var(--step-padding));
  border-radius: 19px 19px 0 0;
}

.service-step-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  margin: 14px 0 12px;
}

.service-step-list--four .service-step-title,
.service-step-list--two .service-step-title {
  min-height: 44px;
}

.services .service-step-title h5 {
  display: block;
  min-height: 0;
  margin: 0;
  color: #000;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.55;
  text-align: left;
  text-wrap: pretty;
}

.service-step-map {
  display: flex;
  align-items: stretch;
  gap: 6px;
  min-height: 0;
  margin-bottom: 18px;
  padding: 10px 0;
  border-block: 1px solid #e6ecf2;
}

.service-step-map > span {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
  min-height: 140px;
  padding: 12px 4px;
  border: 1px solid #dce7f1;
  border-radius: 16px;
  background: #f4f8fc;
  color: var(--blue-dark);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
  text-align: center;
  text-wrap: pretty;
}

.service-process-node > img {
  flex: none;
  width: 64px;
  max-width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: contain;
}

.service-process-node > span {
  width: 100%;
}

.service-step-map > img {
  flex: none;
  align-self: center;
  width: 16px;
  height: 16px;
}

.services .service-step-card > p {
  margin: 0;
  color: #000;
  font-size: 16px;
  line-height: 1.9;
}

/* Four steps keep readable card widths on smaller desktop screens. */
@media (min-width: 961px) and (max-width: 1240px) {
  #training .service-step-title h5 {
    font-size: 20px;
  }

  .services .service-step-list--four {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .services .service-step-list--four .service-step-card::after {
    display: none;
  }
}

@media (max-width: 960px) {
  .services .service-step-list,
  .services .service-step-list--four,
  .services .service-step-list--two {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .service-step-title,
  .service-step-list--four .service-step-title,
  .service-step-list--two .service-step-title {
    min-height: 0;
  }

  .services .service-step-card:not(:last-child)::after {
    top: auto;
    right: auto;
    bottom: -23px;
    left: calc(50% - 9px);
    width: 18px;
    height: 18px;
    transform: rotate(90deg);
  }
}

@media (max-width: 760px) {
  .services .service-step-label {
    height: 48px;
  }

  .services .service-step-card {
    --step-padding: 18px;
    padding-bottom: 22px;
  }

  .services .service-step-title h5 {
    font-size: 20px;
  }

}

@media (max-width: 360px) {
  .services .service-step-card {
    --step-padding: 14px;
  }

  .service-step-title {
    gap: 10px;
  }

  .services .service-step-title h5 {
    font-size: 19px;
  }

  .service-step-map {
    gap: 4px;
  }

  .service-step-map > span {
    font-size: 13px;
  }
}
