/* Telegram group access: prominent on the landing page, compact everywhere else. */
.landing-telegram-link,
.telegram-floating-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid #168bd2;
  background: #229ed9;
  color: #fff;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 9px 20px rgba(34, 158, 217, 0.2);
  transition: transform 0.16s ease, background-color 0.16s ease, box-shadow 0.16s ease;
}

.landing-telegram-link:hover,
.telegram-floating-link:hover {
  background: #168bd2;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(34, 158, 217, 0.28);
}

.landing-telegram-link:focus-visible,
.telegram-floating-link:focus-visible {
  outline: 3px solid rgba(34, 158, 217, 0.32);
  outline-offset: 3px;
}

.landing-telegram-link {
  min-height: 38px;
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 13px;
  white-space: nowrap;
}

.landing-telegram-link svg,
.telegram-floating-link svg {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.telegram-floating-link {
  position: fixed;
  left: 50%;
  bottom: max(14px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 90;
  min-height: 46px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
}

.telegram-floating-link:hover {
  transform: translateX(-50%) translateY(-1px);
}

@media (max-width: 1180px) {
  .landing-telegram-link span {
    display: none;
  }

  .landing-telegram-link {
    width: 38px;
    padding: 7px;
  }
}

@media (max-width: 720px) {
  .telegram-floating-link {
    left: 50%;
    bottom: max(10px, env(safe-area-inset-bottom));
    width: 46px;
    padding: 10px;
    border-radius: 50%;
  }

  .telegram-floating-link span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
}

@media (max-width: 520px) {
  .landing-actions .landing-telegram-link {
    width: 32px;
    min-height: 32px;
    padding: 5px;
  }

  .landing-actions .landing-telegram-link svg {
    width: 18px;
    height: 18px;
  }
}

body[data-theme="dark"] .landing-telegram-link,
body[data-theme="dark"] .telegram-floating-link {
  border-color: #55b9e8;
  background: #168bd2;
  color: #fff;
}
