.telegram-promo {
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    margin: 18px 0 0;
    padding: 18px 20px;
    color: var(--text-primary);
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, 0.18), transparent 40%),
        linear-gradient(135deg, rgba(2, 132, 199, 0.12), rgba(15, 118, 110, 0.08)),
        var(--surface-card);
    border: 1px solid rgba(56, 189, 248, 0.22);
    border-radius: 16px;
    box-shadow: var(--shadow-card);
    overflow: hidden;
}

.telegram-promo::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    border-radius: inherit;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.telegram-promo--compact {
    padding: 16px 18px;
}

.telegram-promo__icon {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    color: #ffffff;
    font-size: 24px;
    background: linear-gradient(135deg, #38bdf8, #0284c7);
    box-shadow: 0 10px 24px rgba(56, 189, 248, 0.22);
}

.telegram-promo__body {
    min-width: 0;
}

.telegram-promo__kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #38bdf8;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.telegram-promo__body h2 {
    margin: 6px 0 0;
    color: var(--text-primary);
    font-size: clamp(18px, 2.1vw, 26px);
    line-height: 1.18;
}

.telegram-promo__body p {
    margin: 8px 0 0;
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.6;
    max-width: 680px;
}

.telegram-promo__actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    min-width: 180px;
}

.telegram-promo__join,
.telegram-promo__secondary {
    min-height: 44px;
    padding: 0 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.telegram-promo__join {
    color: #ffffff;
    background: linear-gradient(135deg, #38bdf8, #0284c7);
    box-shadow: 0 10px 22px rgba(56, 189, 248, 0.22);
}

.telegram-promo__join:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 26px rgba(56, 189, 248, 0.28);
}

.telegram-promo__secondary {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--border-color);
}

.telegram-promo__secondary:hover {
    transform: translateY(-1px);
    border-color: rgba(56, 189, 248, 0.35);
}

.telegram-promo--home {
    margin-top: 14px;
    padding: 16px 18px;
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, 0.10), transparent 35%),
        var(--surface-card);
    border-color: rgba(56, 189, 248, 0.14);
    box-shadow: none;
    max-width: 960px;
}

.telegram-promo--home .telegram-promo__icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    font-size: 21px;
    box-shadow: 0 8px 18px rgba(56, 189, 248, 0.16);
}

.telegram-promo--home .telegram-promo__body h2 {
    font-size: clamp(17px, 1.8vw, 22px);
}

.telegram-promo--home .telegram-promo__body p {
    max-width: 620px;
    font-size: 12px;
}

.telegram-promo--home .telegram-promo__actions {
    min-width: 160px;
}

.telegram-promo--home .telegram-promo__secondary {
    min-height: auto;
    padding: 0;
    border: 0;
    background: transparent;
    color: #0284c7;
    font-size: 12px;
    justify-content: flex-start;
    box-shadow: none;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.dark-mode .telegram-promo {
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, 0.16), transparent 40%),
        linear-gradient(135deg, rgba(2, 132, 199, 0.16), rgba(15, 118, 110, 0.08)),
        var(--surface-card);
}

.dark-mode .telegram-promo--home {
    background:
        radial-gradient(circle at top left, rgba(56, 189, 248, 0.08), transparent 35%),
        var(--surface-card);
    border-color: rgba(56, 189, 248, 0.10);
}

.dark-mode .telegram-promo--home .telegram-promo__secondary {
    background: transparent;
    color: #7dd3fc;
}

.dark-mode .telegram-promo__secondary {
    color: var(--text-primary);
    background: rgba(15, 23, 42, 0.55);
}

@media (max-width: 860px) {
    .telegram-promo {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 14px;
        margin-top: 14px;
    }

    .telegram-promo__icon {
        width: 42px;
        height: 42px;
        border-radius: 14px;
        font-size: 20px;
    }

    .telegram-promo__body h2 {
        font-size: 17px;
    }

    .telegram-promo__body p {
        margin-top: 6px;
        font-size: 12px;
        line-height: 1.5;
    }

    .telegram-promo__actions {
        min-width: 0;
        width: 100%;
        gap: 8px;
    }

    .telegram-promo__join,
    .telegram-promo__secondary {
        width: 100%;
    }

    .telegram-promo--home {
        margin-top: 12px;
        padding: 14px;
    }
}
