.org-page {
  padding: 12px 0 80px;
}

.org-page__header {
  margin-bottom: 34px;
}

.org-page__title {
  margin: 0;
  color: #1f2937;
  font-size: 34px;
  font-weight: 700;
  line-height: 1.25;
}

.org-page__description {
  max-width: 720px;
  margin: 16px 0 0;
  color: #5d6776;
  font-size: 17px;
  line-height: 1.75;
}

.org-diagram {
  --org-coral: #ff6f5e;
  --org-coral-soft: #ff8e74;
  --org-blue: #8abbe6;
  --org-line: #d7dce2;
  position: relative;
  max-width: 1080px;
  margin: 0 auto;
  padding-top: 18px;
}

.org-diagram__stack {
  position: relative;
  display: grid;
  gap: 58px;
  justify-items: center;
  padding-bottom: 60px;
}

.org-diagram__stack::before {
  content: "";
  position: absolute;
  top: 74px;
  left: 50%;
  width: 1px;
  height: 58px;
  background: var(--org-line);
  transform: translateX(-50%);
}

.org-diagram__stack::after {
  content: "";
  position: absolute;
  top: calc(100% - 60px);
  left: 50%;
  width: 1px;
  height: 60px;
  background: var(--org-line);
  transform: translateX(-50%);
}

.org-node {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 74px;
  padding: 16px 34px;
  border: 2px solid var(--org-coral-soft);
  border-radius: 999px;
  background: #ffffff;
  color: var(--org-coral);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  word-break: keep-all;
}

.org-node--fill,
.org-node--director {
  background: var(--org-coral);
  color: #ffffff;
}

.org-node--secondary,
.org-node--deputy {
  border-color: var(--org-blue);
  color: var(--org-blue);
}

.org-diagram__branches {
  --org-branch-gap: 36px;
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--org-branch-gap);
  padding-top: 58px;
}

.org-diagram__branches::before {
  content: "";
  position: absolute;
  top: 0;
  left: calc((100% - var(--org-branch-gap)) / 4);
  right: calc((100% - var(--org-branch-gap)) / 4);
  height: 1px;
  background: var(--org-line);
}

.org-branch {
  position: relative;
}

.org-branch::before {
  content: "";
  position: absolute;
  top: -58px;
  left: 50%;
  width: 1px;
  height: 58px;
  background: var(--org-line);
  transform: translateX(-50%);
}

.org-branch__title {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 74px;
  margin: 0 0 18px;
  padding: 16px 24px;
  border: 2px solid var(--org-coral-soft);
  border-radius: 999px;
  background: #ffffff;
  color: var(--org-coral);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
}

.org-branch:nth-child(2) .org-branch__title {
  border-color: var(--org-blue);
  color: var(--org-blue);
}

.org-branch__list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.org-branch__list li {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 78px;
  padding: 16px 20px;
  border: 2px solid #eceef2;
  border-radius: 24px;
  background: #ffffff;
  color: #364152;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.45;
  text-align: center;
  word-break: keep-all;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.04);
}

@media (max-width: 1100px) {
  .org-diagram__branches {
    --org-branch-gap: 20px;
  }

  .org-node {
    width: min(100%, 520px);
    font-size: 21px;
  }

  .org-branch__title {
    font-size: 20px;
  }

  .org-branch__list li {
    font-size: 16px;
  }
}

@media (max-width: 860px) {
  .org-page__title {
    font-size: 28px;
  }

  .org-page__description {
    font-size: 16px;
  }

  .org-diagram {
    max-width: 360px;
    padding-top: 8px;
  }

  .org-diagram__stack {
    gap: 28px;
    padding-bottom: 22px;
  }

  .org-diagram__stack::before {
    top: 64px;
    height: 28px;
  }

  .org-diagram__stack::after {
    top: calc(100% - 22px);
    height: 22px;
  }

  .org-node {
    width: 100%;
    min-height: 64px;
    padding: 14px 20px;
    font-size: 18px;
  }

  .org-diagram__branches {
    grid-template-columns: 1fr;
    gap: 18px;
    padding-top: 22px;
  }

  .org-diagram__branches::before,
  .org-branch::before {
    display: none;
  }

  .org-branch__title {
    min-height: 62px;
    margin-bottom: 12px;
    padding: 14px 18px;
    font-size: 18px;
  }

  .org-branch__list {
    gap: 10px;
  }

  .org-branch__list li {
    min-height: 64px;
    padding: 14px 16px;
    border-radius: 20px;
    font-size: 15px;
  }
}
