/* === History === */

.history {
  padding: 100px 0 200px;
  overflow: hidden;
}

.history-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 80px;
  row-gap: 50px;
  position: relative;
}

.history-list::after {
  content: "";
  position: absolute;
  top: -45px;
  bottom: -130px;
  width: 80px;
  background-color: var(--text-primary);
  left: 50%;
  transform: translateX(-50%);
  -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-1.2 -6.2 2.4 15.4'><path d='M 1 -6 C 1 -4 -1 -5 -1 -3 C -1 -1 1 -2 1 0 C 1 2 -1 1 -1 3 C -1 5 1 4 1 6 C 1 8 -1 7 -1 9' fill='none' stroke='white' stroke-width='0.1'/></svg>");
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-1.2 -6.2 2.4 15.4'><path d='M 1 -6 C 1 -4 -1 -5 -1 -3 C -1 -1 1 -2 1 0 C 1 2 -1 1 -1 3 C -1 5 1 4 1 6 C 1 8 -1 7 -1 9' fill='none' stroke='white' stroke-width='0.1'/></svg>");
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}

.history-item {
  display: flex;
  align-items: center;
  gap: 20px;
  width: calc((100% - 80px) / 2);
  position: relative;
}

.history-item::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -73px;
  left: 100%;
  transform: translateY(-50%);
  height: 2px;
  background-color: var(--text-primary);
}

.history-item:nth-child(even)::after {
  right: 100%;
  left: -73px;
}

.history-item::before {
  content: "";
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  right: -80px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background-color: var(--primary-color);
  z-index: 3;
}

.history-item:nth-child(even)::before {
  right: auto;
  left: -80px;
}

.history-item:nth-child(even) {
  flex-direction: row-reverse;
}

.history-item:nth-child(odd) {
  margin-bottom: -180px;
}

.history-item-content {
  width: calc(100% - 140px);
}

.history-item-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 120px;
  border: 5px solid var(--primary-color);
  border-radius: 50%;
  color: var(--text-primary);
  font-size: 32px;
}

@media screen and (max-width: 768px) {
  .history-content {
    margin-bottom: 40px;
  }

  .history-item {
    width: 100%;
  }

  .history-item:nth-child(even) {
    flex-direction: row;
  }

  .history-item:nth-child(odd) {
    margin-bottom: 0;
  }

  .history-item::after,
  .history-item::before,
  .history-list::after {
    display: none;
  }
}

/* === Founders === */

.founders {
  padding: 100px 0;
}

.founders-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-bottom: 50px;
}

.founders-content .title {
  margin-bottom: 20px;
}

.founders-content .descr {
  max-width: 800px;
}

.founders-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 45px;
}

.founders-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: calc((100% - 90px) / 3);
  position: relative;
  padding: 20px 20px 30px;
  border-radius: var(--border-radius-primary);
  border: 1px solid #000;
  box-shadow: 8px 8px 0 0 #333;
  overflow: hidden;
}

.founders-item::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 30%;
  background-color: var(--primary-color);
  z-index: -1;
}

.founders-item-wrap {
  width: 140px;
  height: 140px;
  border: 5px solid var(--text-secondary);
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 20px;
}

.founders-item-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.founders-item-content .subtitle {
  margin-bottom: 6px;
}

.founders-item-descr {
  font-size: 18px;
  margin-bottom: 15px;
}

@media screen and (max-width: 768px) {
  .founders-item {
    width: calc((100% - 45px) / 2);
  }
}

@media screen and (max-width: 500px) {
  .founders-item {
    width: 100%;
  }
}

/* === Our Services === */

.goals {
  padding: 100px 0 160px;
}

.goals-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  margin-bottom: 50px;
}

.goals-content .title {
  margin-bottom: 15px;
}

.goals-content .descr {
  max-width: 800px;
}

.swiperGoals {
  padding-top: 20px;
}

.goals-item {
  display: flex;
  gap: 20px;
  padding: 30px 20px 20px;
  border: 1px solid #000;
}

.swiper-slide {
  height: auto;
}

.goals-item-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 180px;
  height: 150px;
  margin-top: -50px;
}

.goals-item-bg {
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: -1;
  background: var(--primary-color);
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 6 5"><path d="M 0 0 L 0 2 C 0 3 1 5 1 5 L 5 5 C 5 5 6 3 6 2 L 6 0" fill="white"/></svg>')
    center / contain no-repeat;
  -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 6 5"><path d="M 0 0 L 0 2 C 0 3 1 5 1 5 L 5 5 C 5 5 6 3 6 2 L 6 0" fill="white"/></svg>')
    center / contain no-repeat;
}

.goals-item-wrap::after {
  content: "";
  position: absolute;
  top: -1px;
  left: -21px;
  clip-path: polygon(100% 100%, 0% 100%, 100% 0);
  width: 21px;
  height: 20px;
  background-color: var(--primary-hover);
}

.goals-item-wrap::before {
  content: "";
  position: absolute;
  top: -1px;
  right: -21px;
  clip-path: polygon(100% 100%, 0% 100%, 0 0);
  width: 21px;
  height: 20px;
  background-color: var(--primary-hover);
}

.goals-item-wrap img {
  width: 100px;
  object-fit: contain;
}

.goals-item-content {
  width: calc((100% - 200px));
}

.goals-item-content .subtitle {
  margin-bottom: 6px;
}
