.arsb-overlay {
    position: absolute;
    inset: 0;
    z-index: var(--arsb-z-index, 5);
    pointer-events: none;
    /* Clip the bubble layer to the hero. The Ken Burns mirror scales
       .arsb-slide to follow the background zoom, which would otherwise push
       past the hero edges and create page-level horizontal scroll. */
    overflow: hidden;
}

/* Each slide's bubbles are shown only while its background image is active,
   synced with the real Elementor slideshow, and fade out when it changes. */
.arsb-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 350ms ease;
}

.arsb-slide.is-active {
    opacity: 1;
    pointer-events: auto;
}

.arsb-bubble {
    position: absolute;
    left: var(--arsb-x-desktop);
    top: var(--arsb-y-desktop);
    transform: translate(-50%, -50%);
    pointer-events: auto;
}

.arsb-bubble__dot {
    position: relative;
    display: block;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 3px solid var(--arsb-dot, #fff);
    border-radius: 50%;
    background: var(--arsb-accent, #ffcc00);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
    cursor: pointer;
    outline-offset: 4px;
    transition: transform 160ms ease, box-shadow 160ms ease;
}

.arsb-bubble__dot:hover,
.arsb-bubble__dot:focus-visible {
    transform: scale(1.18);
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.34);
}

.arsb-bubble--pulse .arsb-bubble__dot::after {
    content: "";
    position: absolute;
    inset: -9px;
    border: 2px solid var(--arsb-accent, #ffcc00);
    border-radius: 50%;
    animation: arsb-pulse 1.8s ease-out infinite;
    pointer-events: none;
}

.arsb-card {
    position: absolute;
    left: calc(100% + 16px);
    top: 50%;
    width: min(300px, calc(100vw - 32px));
    overflow: hidden;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.30);
    color: #1d2327;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-50%) scale(0.94);
    transform-origin: left center;
    transition: opacity 220ms cubic-bezier(0.16, 1, 0.3, 1), transform 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

.arsb-bubble.is-open .arsb-card {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(-50%) scale(1);
}

.arsb-card--pos-left {
    right: calc(100% + 16px);
    left: auto;
    transform-origin: right center;
}

.arsb-card--pos-top {
    top: auto;
    bottom: calc(100% + 16px);
    left: 50%;
    transform: translateX(-50%) scale(0.94);
    transform-origin: center bottom;
}

.arsb-bubble.is-open .arsb-card--pos-top {
    transform: translateX(-50%) scale(1);
}

.arsb-card--pos-bottom {
    top: calc(100% + 16px);
    left: 50%;
    transform: translateX(-50%) scale(0.94);
    transform-origin: center top;
}

.arsb-bubble.is-open .arsb-card--pos-bottom {
    transform: translateX(-50%) scale(1);
}

/* Close button — hardened against theme/Elementor global button styles. */
.arsb-card .arsb-card__close {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    min-height: 0;
    margin: 0;
    padding: 0;
    border: 0 !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.95) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.20);
    color: #1d2327 !important;
    font-size: 20px;
    font-weight: 400;
    line-height: 1;
    cursor: pointer;
    transition: background 150ms ease, transform 150ms ease;
}

.arsb-card .arsb-card__close:hover {
    background: #fff !important;
    transform: scale(1.08);
}

.arsb-card__image {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.arsb-card__body {
    padding: 16px;
}

.arsb-card h3 {
    display: -webkit-box;
    margin: 0 0 10px;
    overflow: hidden;
    color: #1d2327;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.arsb-card__price {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 0 0 12px;
    color: #1d2327;
    font-size: 18px;
    font-weight: 800;
}

.arsb-card__price del {
    color: #8a8f94;
    font-size: 14px;
    font-weight: 500;
}

.arsb-card__price span, .arsb-card__stock {
    display: inline-flex;
    align-items: center;
    padding: 0;
    /* background: #1d2327; */
    color: #1d2327;
    font-size: 19px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.arsb-card__stock {
    margin: 0 0 12px;
    background: #b32d2e;
}

.arsb-card__cta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    width: 100%;
    box-sizing: border-box;
    padding: 12px 14px;
    border: 0;
    background: var(--arsb-accent, #ffcc00) !important;
    color: #1d2327 !important;
    font-weight: 800;
    text-decoration: none;
    transition: filter 150ms ease, transform 150ms ease;
}

.arsb-card__cta:hover {
    filter: brightness(0.94);
    transform: translateY(-1px);
}

.arsb-card__cta span {
    transition: transform 150ms ease;
}

.arsb-card__cta:hover span {
    transform: translateX(3px);
}

.arsb-overlay__backdrop {
    position: absolute;
    inset: 0;
    pointer-events: auto;
}

.arsb-overlay.has-open-card[data-dim="1"] .arsb-bubble:not(.is-open) {
    opacity: 0.4;
}

.arsb-is-paused .elementor-bg-slideshow,
.arsb-is-paused .elementor-background-slideshow__slide,
.arsb-is-paused .elementor-background-slideshow__slide__image {
    animation-play-state: paused !important;
}

@media (max-width: 1024px) {
    .arsb-bubble {
        left: var(--arsb-x-tablet);
        top: var(--arsb-y-tablet);
    }

    .arsb-hidden-tablet {
        display: none;
    }
}

@media (max-width: 767px) {
    .arsb-bubble {
        left: var(--arsb-x-mobile);
        top: var(--arsb-y-mobile);
    }

    .arsb-hidden-mobile {
        display: none;
    }

    .arsb-card {
        width: min(280px, calc(100vw - 24px));
    }
}

@media (min-width: 1025px) {
    .arsb-hidden-desktop {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .arsb-slide,
    .arsb-bubble__dot::after,
    .arsb-card {
        animation: none;
        transition: none;
    }
}

@keyframes arsb-pulse {
    0% {
        opacity: 0.75;
        transform: scale(0.7);
    }
    100% {
        opacity: 0;
        transform: scale(1.35);
    }
}
