.telegram-promo {
  --telegram-promo-ready: 1;
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  display: grid;
  grid-template-columns: minmax(0, 430px) 132px minmax(300px, 1fr);
  column-gap: 12px;
  width: min(920px, calc(100vw - 48px));
  height: 304px;
  min-height: 0;
  max-height: calc(100dvh - 48px);
  overflow-x: hidden;
  overflow-y: auto;
  border-radius: 18px;
  background: #203e32;
  color: #f6f8ef;
  box-shadow: 0 26px 64px rgba(19, 42, 33, .34);
  opacity: 0;
  transform: translateY(18px) scale(.98);
  transform-origin: bottom right;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 220ms ease, transform 360ms cubic-bezier(.23, 1, .32, 1), visibility 0s linear 360ms;
}

.telegram-promo[hidden] {
  display: none !important;
}

.telegram-promo[data-state="visible"] {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
  visibility: visible;
  transition-delay: 0s;
}

.telegram-promo__visual {
  position: relative;
  min-width: 0;
  min-height: 304px;
  background: #203e32;
}

.telegram-promo__person {
  display: block;
  width: 100%;
  height: 100%;
  object-fit:contain;
  object-position: left center;
}

.telegram-promo__qr {
  align-self: center;
  justify-self: center;
  width: 132px;
  height: 132px;
  padding: 10px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(13, 30, 24, .28);
}

.telegram-promo__qr img {
  display: block;
  width: 100%;
  height: 100%;
}

.telegram-promo__content {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: center;
  gap: 12px;
  min-width: 0;
  padding: 34px 60px 34px 10px;
}

.telegram-promo h2 {
  max-width: 17ch;
  margin: 0;
  color: #fff;
  font-size: 31px;
  font-weight: 720;
  line-height: 1.03;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.telegram-promo__text {
  max-width: 39ch;
  margin: 0;
  color: #d7e1d3;
  font-size: 14px;
  line-height: 1.45;
}

.telegram-promo__action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 50px;
  margin-top: 4px;
  padding: 12px 15px;
  border-radius: 9px;
  background: #dcec9b;
  color: #19382e;
  font-size: 14px;
  font-weight: 780;
  text-decoration: none;
  transition: background-color 140ms ease, transform 140ms cubic-bezier(.23, 1, .32, 1);
}

.telegram-promo__action span {
  color: #52683f;
  font-weight: 600;
}

.telegram-promo__action:hover {
  background: #eef7c7;
  transform: translateY(-1px);
}

.telegram-promo__action:active {
  transform: scale(.985);
}

.telegram-promo__action:focus-visible,
.telegram-promo__close:focus-visible {
  outline: 3px solid #f0c86a;
  outline-offset: 3px;
}

.telegram-promo__close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #cbd9c5;
  cursor: pointer;
}

.telegram-promo__close:hover {
  background: rgba(255, 255, 255, .09);
  color: #fff;
}

.telegram-promo__close svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.8;
}

@media (max-width: 760px) {
  .telegram-promo {
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: minmax(0, 1fr) 104px;
    column-gap: 0;
    width: calc(100vw - 24px);
    height: auto;
    min-height: 0;
    max-height: calc(100dvh - 24px - env(safe-area-inset-bottom));
    overflow-y: auto;
    border-radius: 16px;
    transform-origin: bottom center;
  }

  .telegram-promo__visual {
    grid-column: 1 / -1;
    width: 100%;
    min-height: 0;
    aspect-ratio: 3 / 2;
  }

  .telegram-promo__person {
    object-position: center;
  }

  .telegram-promo__qr {
    grid-column: 2;
    grid-row: 2;
    align-self: start;
    width: 96px;
    height: 96px;
    margin: 18px 18px 0 0;
    padding: 7px;
    border-radius: 10px;
  }

  .telegram-promo__content {
    grid-column: 1;
    grid-row: 2;
    gap: 9px;
    padding: 18px 8px 20px 18px;
  }

  .telegram-promo h2 {
    max-width: 15ch;
    font-size: 25px;
    line-height: 1.04;
  }

  .telegram-promo__text {
    max-width: 44ch;
    font-size: 13px;
    line-height: 1.4;
  }

  .telegram-promo__action {
    min-height: 48px;
    margin-top: 2px;
    padding: 10px 13px;
    font-size: 13px;
  }

  .telegram-promo__close {
    top: 6px;
    right: 6px;
    background: rgba(22, 49, 39, .58);
  }
}

@media (max-width: 360px) {
  .telegram-promo__qr {
    width: 84px;
    height: 84px;
    margin: 16px 12px 0 0;
    padding: 6px;
  }

  .telegram-promo__content {
    padding: 16px 16px 18px;
  }

  .telegram-promo h2 {
    font-size: 23px;
  }

  .telegram-promo__text,
  .telegram-promo__action {
    font-size: 12px;
  }

  .telegram-promo__action span {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .telegram-promo,
  .telegram-promo__action {
    transition: none;
  }

  .telegram-promo {
    transform: none;
  }
}

/* Approved compact layout 1, 2026-11-03. Scoped to the promo only. */
.telegram-promo { box-sizing:border-box; width:min(560px,calc(100vw - 48px)); height:300px; display:block; }
.telegram-promo *, .telegram-promo *::before, .telegram-promo *::after { box-sizing:border-box; }
.telegram-promo__visual { position:absolute; left:0; bottom:0; width:252px; height:168px; min-height:0; }
.telegram-promo__person { object-fit:contain; }
.telegram-promo__content { display:block; margin-left:252px; padding:32px 24px 18px 4px; }
.telegram-promo h2 { font-size:25px; line-height:1.12; max-width:none; letter-spacing:-.025em; }
.telegram-promo__text { font-size:14px; line-height:1.45; margin-top:14px; }
.telegram-promo__action { position:absolute; right:24px; bottom:18px; left:256px; min-height:48px; margin:0; }
.telegram-promo__qr { position:absolute; left:28px; top:18px; width:100px; height:100px; padding:8px; box-shadow:none; }
.telegram-promo__close { top:4px; right:4px; }
@media(max-width:600px) {
 /* Mobile no-overlap layout 2026-11-05: image, copy and CTA use separate zones. */
 .telegram-promo {
   right:10px;
   bottom:max(10px,env(safe-area-inset-bottom));
   width:calc(100vw - 20px);
   height:236px;
   max-height:calc(100dvh - 20px - env(safe-area-inset-bottom));
   overflow:hidden;
   border-radius:16px;
 }
 .telegram-promo__qr { display:none; }
 .telegram-promo__visual {
   left:12px;
   bottom:66px;
   width:112px;
   height:142px;
   aspect-ratio:auto;
 }
 .telegram-promo__person { object-position:left bottom; }
 .telegram-promo__content {
   position:absolute;
   top:18px;
   right:52px;
   bottom:68px;
   left:128px;
   display:block;
   margin:0;
   padding:0;
 }
 .telegram-promo h2 {
   max-width:12ch;
   margin:0;
   font-size:21px;
   line-height:1.08;
 }
 .telegram-promo__text {
   min-height:0;
   margin:10px 0 0;
   font-size:13px;
   line-height:1.35;
 }
 .telegram-promo__action {
   position:absolute;
   right:12px;
   bottom:12px;
   left:12px;
   min-height:48px;
   margin:0;
   padding:11px 14px;
   font-size:14px;
 }
 .telegram-promo__action span { display:inline; }
 .telegram-promo__close {
   top:6px;
   right:6px;
   width:44px;
   height:44px;
   background:rgba(22,49,39,.58);
 }
}
@media(max-width:360px) {
 .telegram-promo { height:228px; }
 .telegram-promo__visual { width:96px; height:132px; }
 .telegram-promo__content { right:48px; left:110px; }
 .telegram-promo h2 { font-size:19px; }
 .telegram-promo__text { font-size:12px; }
}
