.bannerpress-banner {
    text-align: center
}

.bannerpress-banner img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto
}

.bannerpress-banner.bp-sticky {
    position: sticky;
    top: 0;
    z-index: 9999
}

.bannerpress-popup {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    padding: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    z-index: 10000
}

.bannerpress-popup img {
    max-width: 90vw;
    max-height: 70vh
}

.bannerpress-popup .bannerpress-popup-close {
    display: block;
    margin-top: 8px
}


/* Close button styles for both header and popup banners */
.bannerpress-close,
.bannerpress-popup-close {
    position: absolute;
    top: 5px;
    right: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    z-index: 1000;
}

.bannerpress-close {
    top: 5px;
    right: 5px;
}

.bannerpress-popup-close {
    top: 6px;
    right: 8px;
}

.bannerpress-before-header {
    position: relative;
}

.bannerpress-before-header.sticky-banner {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999999;
    max-height: 100px;
    overflow: hidden
}

.bannerpress-before-header .bannerpress-banner {
    height: 70px;
    display: block;
    overflow: hidden;
}

.bannerpress-before-header .bannerpress-banner picture {
    height: 100%;
    display: block;
}

.bannerpress-before-header img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.bannerpress-before-header .bannerpress-close,
.bannerpress-popup-overlay .bannerpress-popup-close {
    width: 32px;
    height: 32px;
    padding: 0;
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    z-index: 3;
    margin: auto;
    min-height: 0;
    right: auto;
    border-radius: 50%;
    background: #333;
}

.bannerpress-before-header .bannerpress-close:hover,
.bannerpress-popup-overlay .bannerpress-popup-close:hover {
    background: #000;
}

.bannerpress-popup-overlay .bannerpress-popup-close {
    margin: -10px;
    left: 0;
}


.bannerpress-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999999;
    padding: 20px;
}

.bannerpress-popup-inner {
    max-width: 900px;
    position: relative;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.bannerpress-popup-inner img {
    max-width: 100%;
    height: auto;
    display: block;
}

.bannerpress-sidebar-banner.widget {
    padding: 0;
    box-shadow: none;
}