.telegram-fab {
    position: fixed;
    right: var(--space-6, 1.5rem);
    bottom: calc(var(--space-6, 1.5rem) + 72px);
    z-index: var(--z-toast, 60);
    width: 60px;
    height: 60px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    color: #fff;
    background: #229ed9;
    box-shadow: 0 4px 14px rgba(34, 158, 217, 0.45);
    transition: transform 0.2s ease, opacity 0.2s ease;
    text-decoration: none;
    animation: telegram-fab-pulse 2s ease-out infinite;
}

.telegram-fab:hover {
    transform: scale(1.06);
    color: #fff;
    animation-play-state: paused;
}

.telegram-fab:focus-visible {
    outline: 2px solid #229ed9;
    outline-offset: 2px;
}

.telegram-fab svg {
    width: 28px;
    height: 28px;
    display: block;
    animation: telegram-fab-icon 2s ease-out infinite;
}

.telegram-fab:hover svg {
    animation-play-state: paused;
}

@keyframes telegram-fab-pulse {
    0%,
    100% {
        box-shadow: 0 4px 14px rgba(34, 158, 217, 0.45);
        transform: scale(1);
    }

    50% {
        box-shadow:
            0 4px 18px rgba(34, 158, 217, 0.55),
            0 0 0 6px rgba(34, 158, 217, 0.18);
        transform: scale(1.04);
    }
}

@keyframes telegram-fab-icon {
    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-1px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .telegram-fab,
    .telegram-fab svg {
        animation: none;
    }
}

@media (width <= 1100px) {
    .telegram-fab {
        right: var(--space-4, 1rem);
        bottom: calc(var(--space-4, 1rem) + 72px);
    }
}

@media (width <= 900px) {
    .telegram-fab {
        right: var(--space-4, 1rem);
        bottom: calc(var(--bottom-nav-h, 64px) + var(--space-4, 1rem) + 72px + env(safe-area-inset-bottom, 0px));
    }
}
