/* «Сообщество»: лента из группы Telegram — в стиле карточек сайта */
.tgp-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; margin: -8px 0 26px; }
.tgp-pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 99px; background: var(--u-surface, rgba(255,255,255,.8));
  border: 1px solid var(--u-border, rgba(200,210,230,.55)); font-size: .82rem; font-weight: 600; color: var(--text-secondary); box-shadow: var(--u-shadow); }
.tgp-dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,.5); animation: tgp-live 2s infinite; }
@keyframes tgp-live { 70% { box-shadow: 0 0 0 8px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
.tgp-join { padding: 9px 20px; font-size: .86rem; }

.fanzone-grid.tgp-grid { display: block; column-count: 3; column-gap: 16px; }
.tgp { break-inside: avoid; margin-bottom: 16px; cursor: default; display: flex; flex-direction: column; }
.tgp .fan-post-header { position: relative; }
.tgp-who { min-width: 0; flex: 1; }
.tgp-tg { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--blue-50); color: #229ed9; }
.tgp-text { white-space: normal; word-wrap: break-word; overflow-wrap: anywhere; }
.tgp-text a { color: var(--blue-600); font-weight: 500; text-decoration: underline; text-decoration-color: var(--blue-200); }
.tgp-text.is-long { display: -webkit-box; -webkit-line-clamp: 8; -webkit-box-orient: vertical; overflow: hidden; }
.tgp.is-open .tgp-text.is-long { display: block; }
.tgp-toggle { align-self: flex-start; margin: -4px 0 10px; padding: 0; border: 0; background: none; font: 600 .82rem var(--font-body); color: var(--blue-600); cursor: pointer; }
.tgp-link { color: var(--blue-600); font-weight: 600; }
.tgp-link:hover { text-decoration: underline; }

.tgp-media { display: grid; gap: 4px; margin: 0 -4px 12px; border-radius: var(--radius-sm); overflow: hidden; }
.tgp-media.n2 { grid-template-columns: 1fr 1fr; }
.tgp-media.n3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; }
.tgp-media.n3 .tgp-m:first-child { grid-row: 1 / 3; }
.tgp-media.n4 { grid-template-columns: 1fr 1fr; }
.tgp-m { position: relative; display: block; padding: 0; border: 0; background: #e8eef7; cursor: zoom-in; overflow: hidden; min-height: 0; }
.tgp-media.n1 .tgp-m { max-height: 460px; }
.tgp-media:not(.n1) .tgp-m { aspect-ratio: 1; }
.tgp-media.n3 .tgp-m:first-child { aspect-ratio: auto; }
.tgp-m img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s var(--ease); }
.tgp-m:hover img { transform: scale(1.03); }
video.tgp-m { width: 100%; max-height: 460px; background: #0f172a; cursor: default; }
.tgp-vid { cursor: pointer; }
.tgp-play { position: absolute; left: 50%; top: 50%; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; background: rgba(255,255,255,.92); box-shadow: 0 6px 20px rgba(15,23,42,.3); }
.tgp-play::after { content: ''; position: absolute; left: 21px; top: 16px; border-style: solid; border-width: 10px 0 10px 16px; border-color: transparent transparent transparent var(--blue-600); }
.tgp-more { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(15,23,42,.5); color: #fff; font: 800 1.4rem var(--font-display); }
.tgp-more-row { display: flex; justify-content: center; margin-top: 10px; }

.tgp-lb { position: fixed; inset: 0; z-index: 10050; display: grid; place-items: center; background: rgba(15,23,42,.92); animation: tgp-fade .2s ease both; }
@keyframes tgp-fade { from { opacity: 0; } }
.tgp-lb img { max-width: 94vw; max-height: 84vh; border-radius: 12px; box-shadow: 0 30px 60px rgba(0,0,0,.4); }
.tgp-lb-bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 12px; padding: 14px 18px; color: rgba(255,255,255,.85); font-size: .84rem; }
.tgp-lb-bar span { margin-right: auto; }
.tgp-lb-bar button, .tgp-lb-nav { border: 0; background: rgba(255,255,255,.14); color: #fff; cursor: pointer; }
.tgp-lb-bar button { width: 40px; height: 40px; border-radius: 10px; font-size: 1.3rem; }
.tgp-lb-nav { position: absolute; top: 50%; width: 48px; height: 48px; margin-top: -24px; border-radius: 50%; font-size: 1.8rem; line-height: 1; }
.tgp-lb-nav.prev { left: 16px; } .tgp-lb-nav.next { right: 16px; }

@media (max-width: 1000px) { .fanzone-grid.tgp-grid { column-count: 2; } }
@media (max-width: 640px) { .fanzone-grid.tgp-grid { column-count: 1; } .tgp-head { justify-content: center; } }
@media (prefers-reduced-motion: reduce) { .tgp-dot { animation: none; } }
