
.agreen-auto-popup {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    padding: 24px;
}

.agreen-auto-popup.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.agreen-auto-popup__backdrop {
    display: none;
}

.agreen-auto-popup__dialog {
    position: relative;
    width: min(90vw, 340px);
    max-height: 80vh;
    overflow: visible;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 14px 42px rgba(0, 0, 0, 0.26);
    transform: translateY(8px) scale(0.98);
    transition: transform 0.25s ease;
    pointer-events: auto;
}

.agreen-auto-popup.is-open .agreen-auto-popup__dialog {
    transform: translateY(0) scale(1);
}

.agreen-auto-popup__close {
    position: absolute;
    top: -12px;
    right: -12px;
    z-index: 3;
    width: 34px;
    height: 34px;
    border: 2px solid #ffffff;
    border-radius: 999px;
    background: #000000;
    color: #ffffff;
    cursor: pointer;
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.agreen-auto-popup__close span {
    transform: translateY(-2px);
    display: inline-block;
}

.agreen-auto-popup__close:hover,
.agreen-auto-popup__close:focus {
    background: #222222;
    color: #ffffff;
    outline: none;
}

.agreen-auto-popup__media img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px 16px 0 0;
}

.agreen-auto-popup__content {
    padding: 10px 14px 13px;
    text-align: center;
}

.agreen-auto-popup__title,
.agreen-auto-popup__subtitle {
    margin: 0;
    color: inherit;
    font-family: inherit;
}

.agreen-auto-popup__title {
    font-size: 1rem;
    line-height: 1.25;
}

.agreen-auto-popup__subtitle {
    margin-top: 5px;
    font-size: 0.9rem;
    line-height: 1.25;
}

.agreen-auto-popup__services-link {
    color: inherit;
    font: inherit;
    text-decoration: underline;
    text-underline-offset: 0.16em;
}

.agreen-auto-popup__services-link:hover,
.agreen-auto-popup__services-link:focus {
    color: inherit;
    text-decoration-thickness: 2px;
    outline: none;
}

body.agreen-auto-popup-open {
    overflow: auto;
}

@media (max-width: 767px) {
    .agreen-auto-popup {
        inset: auto 10px 10px auto;
        padding: 0;
        display: block;
        pointer-events: none;
    }

    .agreen-auto-popup.is-open {
        pointer-events: none;
    }

    .agreen-auto-popup__dialog {
        width: auto;
        max-width: none;
        max-height: none;
        overflow: visible;
        border-radius: 999px;
        background: transparent;
        box-shadow: none;
        transform: none;
        pointer-events: auto;
    }

    .agreen-auto-popup__media,
    .agreen-auto-popup__title,
    .agreen-auto-popup__close {
        display: none !important;
    }

    .agreen-auto-popup__content {
        padding: 0;
    }

    .agreen-auto-popup__subtitle {
        display: block;
        margin: 0;
        line-height: 1;
    }

    .agreen-auto-popup__services-link {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 72px;
        min-height: 26px;
        padding: 6px 10px;
        border-radius: 999px;
        background: #000000;
        color: #ffffff !important;
        font-size: 0;
        font-weight: 700;
        line-height: 1;
        text-decoration: none !important;
        box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
    }

    .agreen-auto-popup__services-link::after {
        content: "Car Rent";
        font-size: 11px;
        line-height: 1;
        white-space: nowrap;
    }
}
