.ts-lazy-embed {
    --ts-lazy-embed-ratio: 16 / 9;
    position: relative;
    isolation: isolate;
    display: grid;
    width: 100%;
    min-height: 220px;
    aspect-ratio: var(--ts-lazy-embed-ratio);
    overflow: hidden;
    border: 1px solid rgba(0, 40, 100, 0.16);
    border-radius: 16px;
    background:
        linear-gradient(135deg, rgba(0, 40, 100, 0.96), rgba(18, 196, 227, 0.78));
    color: #fff;
}

.ts-lazy-embed--map {
    --ts-lazy-embed-ratio: 4 / 3;
}

#tsMap > .ts-lazy-embed--map {
    height: 100%;
    min-height: 0;
    aspect-ratio: auto;
    border: 0;
    border-radius: inherit;
}

.ts-lazy-embed iframe {
    position: absolute;
    z-index: 3;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: #fff;
}

.ts-lazy-embed__preview,
.ts-lazy-embed__content {
    grid-area: 1 / 1;
}

.ts-lazy-embed__preview {
    display: grid;
    place-items: center;
    opacity: 0.2;
}

.ts-lazy-embed__preview svg {
    width: clamp(90px, 20vw, 160px);
    fill: currentColor;
}

.ts-lazy-embed__preview circle {
    fill: #b6e30c;
}

.ts-lazy-embed__content {
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 24px;
    text-align: center;
}

.ts-lazy-embed__provider {
    font-size: 0.82rem;
    font-weight: 700;
    opacity: 0.8;
}

.ts-lazy-embed__activate,
.ts-lazy-embed__retry {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 8px 18px;
    border: 2px solid transparent;
    border-radius: 999px;
    background: #b6e30c;
    color: #002864;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.ts-lazy-embed__activate:hover,
.ts-lazy-embed__retry:hover {
    background: #fff;
}

.ts-lazy-embed__activate:focus-visible,
.ts-lazy-embed__retry:focus-visible,
.ts-lazy-embed__direct:focus-visible,
[data-ts-chat-launcher]:focus-visible {
    outline: 3px solid #b6e30c;
    outline-offset: 3px;
}

.ts-lazy-embed__direct {
    color: #fff;
    font-size: 0.86rem;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.ts-lazy-embed__status {
    margin: 0;
    color: inherit;
}

.ts-lazy-embed.is-loading .ts-lazy-embed__activate {
    pointer-events: none;
    opacity: 0.55;
}

.ts-lazy-embed.is-loaded .ts-lazy-embed__preview,
.ts-lazy-embed.is-loaded .ts-lazy-embed__content {
    visibility: hidden;
}

.ts-lazy-media-error {
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #fff1ee;
    color: #9b2415;
    font-size: 0.9rem;
}

.ts-lazy-media-error a {
    color: inherit;
    font-weight: 700;
    text-decoration: underline;
}

[data-theme="dark"] .ts-lazy-embed,
body.dark .ts-lazy-embed {
    border-color: rgba(255, 255, 255, 0.18);
    background:
        linear-gradient(135deg, rgba(4, 19, 31, 0.98), rgba(0, 82, 108, 0.9));
}

[data-theme="dark"] .ts-lazy-media-error,
body.dark .ts-lazy-media-error {
    background: #3a1712;
    color: #ffd3cc;
}

.online-support-panel {
    position: relative;
}

.online-support {
    position: relative;
    border: 0;
    color: inherit;
    cursor: pointer;
}

.modern-tooltip {
    position: absolute;
    top: -50px;
    left: 50%;
    padding: 12px 20px;
    transform: translateX(-50%);
    border-radius: 16px;
    background: linear-gradient(135deg, #002864, #12c4e3);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.online-support:hover .modern-tooltip,
.online-support:focus-visible .modern-tooltip,
.online-support.show-tooltip .modern-tooltip {
    opacity: 1;
    visibility: visible;
}

@media (max-width: 575.98px) {
    .ts-lazy-embed {
        min-height: 180px;
        border-radius: 12px;
    }

    .ts-lazy-embed__content {
        padding: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ts-lazy-embed *,
    .modern-tooltip,
    .icon-chat {
        scroll-behavior: auto !important;
        animation: none !important;
        transition: none !important;
    }
}
