.header-socials {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.telegram-channel-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.13em;
  text-decoration: none;
  text-transform: uppercase;
  transition: color 220ms ease;
}

.telegram-channel-link:hover,
.telegram-channel-link:focus-visible {
  color: var(--fg);
}

.telegram-channel-link svg,
.telegram-action svg {
  display: block;
  flex: 0 0 auto;
  transition: transform 220ms ease;
}

.telegram-channel-link:hover svg,
.telegram-channel-link:focus-visible svg,
.telegram-action:hover svg,
.telegram-action:focus-visible svg {
  transform: translate(1px, -1px);
}

.telegram-action {
  gap: 10px;
}

.blog-telegram-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.post-telegram-publication {
  margin: 22px 0 clamp(34px, 5vw, 54px);
}

.post-telegram-action {
  min-height: 44px;
  padding: 12px 16px;
  font-size: 11px;
}

/* Article polish. This layer loads after the main stylesheet. */
.post-article [data-lang-content] {
  min-width: 0;
}

.post-article h1 {
  max-width: 16ch;
  margin-top: 18px;
  font-size: clamp(42px, 6vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.post-article h2 {
  max-width: 20ch;
  line-height: 1.06;
  text-wrap: balance;
}

.post-article p,
.post-article ul,
.post-article ol,
.post-article blockquote {
  max-width: 780px;
}

.post-article ul,
.post-article ol {
  margin: 20px 0 30px;
  padding-left: 1.35em;
  color: var(--muted-2);
  font-size: clamp(17px, 1.55vw, 20px);
  line-height: 1.65;
}

.post-article li {
  padding-left: 0.3em;
}

.post-article li + li {
  margin-top: 0.55em;
}

.post-article blockquote {
  margin: 30px 0;
  padding: 20px 22px;
  border-left: 3px solid var(--accent-red);
  background: var(--panel);
}

.post-article blockquote p {
  margin: 0;
  color: var(--fg);
  font-size: clamp(17px, 1.55vw, 20px);
  line-height: 1.6;
}

.post-article pre {
  max-width: 100%;
  margin: 28px 0 38px;
  padding: clamp(18px, 3vw, 26px);
  overflow-x: auto;
  border: 1px solid var(--line);
  background: var(--panel);
  white-space: pre-wrap;
}

.post-article pre code {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted-2);
  font-size: clamp(12px, 1.35vw, 14px);
  line-height: 1.7;
}

@media (max-width: 640px) {
  .header-socials {
    gap: 10px;
  }

  .telegram-channel-link span {
    display: none;
  }

  .telegram-channel-link {
    min-width: 20px;
    justify-content: center;
  }

  .blog-telegram-actions .telegram-action,
  .post-telegram-action {
    width: 100%;
  }

  .post-article h1 {
    max-width: none;
    font-size: clamp(38px, 12vw, 58px);
    line-height: 1;
    letter-spacing: -0.02em;
  }

  .post-article h2 {
    max-width: none;
    font-size: clamp(27px, 8vw, 38px);
  }

  .post-article ul,
  .post-article ol {
    padding-left: 1.15em;
  }

  .post-article blockquote {
    padding: 17px 18px;
  }
}
