/* Shared Gallery Module Styles */

/* Container */
.gallery-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    z-index: 1;
    gap: 40px;
    top: 30px;
    margin: auto;
}

/* Modifiers for Container Widths */
.gallery-container.gallery-wide {
    max-width: 1340px;
    width: 85%;
}

.gallery-container.gallery-standard {
    max-width: 1200px;
    width: 82%;
}

/* Title */
.gallery-title {
    position: relative;
    font-size: 3.5em;
    text-align: center;
    margin-top: 90px;
    top: 0%;
    color: #fff;
    filter: invert(var(--theme-invert-progress));
    transition: none;
    scroll-margin-top: 80px;
}

@media screen and (max-width: 640px) {
    .gallery-title {
        font-size: 2em;
    }
}

/* Grayscale effect when overlay is open */
.gallery-container.overlay-open .gallery-card-wrapper {
    filter: grayscale(100%);
    transition: filter 0.5s ease;
}

@keyframes filter-load {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes card-load {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.gallery-card-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    /* GSAP will handle animations */
}

.gallery-card-wrapper.hidden {
    /* GSAP will handle animations */
    display: none;
}

.gallery-card-link {
    text-decoration: none;
    display: block;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.gallery-card-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    text-align: center;
    background: rgba(0, 0, 0, 0.8);
    padding: 0 20px;
    padding-bottom: 180px; /* Center content visually */
    box-sizing: border-box;
    overflow: hidden;
    clip-path: polygon(0 100%, 100% 100%, 100% 100%, 0 100%);
    transition: clip-path 0.5s ease, padding-bottom 0.5s ease;
    z-index: 3;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    transform-style: preserve-3d;
    padding-bottom: 40px;
}

.gallery-container .gallery-card {
    position: relative;
    width: 300px;
    height: 250px;
    box-shadow: 20px 20px 50px rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgb(255, 255, 255);
    backdrop-filter: blur(5px);
    transition: background-size 2s ease, background-image 0.5s ease-in-out;
    background-size: 101%;
    transform-style: preserve-3d;
}

.gallery-container .gallery-card.lazy-placeholder {
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: center;
    align-items: center;
}

.gallery-loader {
    position: relative;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-left-color: #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 2;
}

.lazy-placeholder .gallery-loader {
    opacity: 1;
}

.gallery-card.poster-loaded .gallery-loader {
    display: none;
}

.gallery-card-poster {
    position: absolute;
    top: -1px;
    left: -1px;
    width: 101%;
    height: 101%;
    border: none;
    object-fit: cover;
    pointer-events: none;
    z-index: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.gallery-card.poster-loaded .gallery-card-poster {
    opacity: 1;
}

.gallery-card-iframe {
    position: absolute;
    top: -1px;
    left: -1px;
    width: 101%;
    height: 101%;
    border: none;
    transform-origin: center center;
    pointer-events: none;
    z-index: 1;
    opacity: 0;
    transition: opacity 1.5s ease;
}

.gallery-card.loaded .gallery-card-iframe {
    opacity: 1;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.gallery-container .gallery-card:not(.loaded) {
    background-image: none !important;
}

.gallery-card-info h3 {
    font-size: 2.5em;
    color: #fff;
    margin: 0 0 20px 0;
    transform: translateZ(30px);
    font-weight: 600;
    line-height: 1.1em;
    transition: opacity 0.3s ease 0.3s, height 0.3s ease 0.3s, margin 0.3s ease 0.3s;
}

.gallery-card-info .cta {
    font-size: 0.9em;
    color: #fff;
    font-weight: 400;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    transform: translateZ(40px);
    cursor: pointer;
    letter-spacing: 1px;
}

/* Filter / Autocomplete UI */
.filter-container {
    width: 90%;
    max-width: 1200px;
    margin: 40px auto;
    position: relative;
    z-index: 2;
    animation: filter-load 0.5s ease-out 0.1s both;
}

.filter-input {
    flex-grow: 1;
    padding: 15px 0;
    font-size: 16px;
    border: none;
    background: transparent;
    color: #fff;
    outline: none;
}

.filter-input::placeholder { color: #888; }

.project-count {
    color: #777;
    font-size: 13px;
    margin: 0 15px;
    white-space: nowrap;
    transition: opacity 0.3s ease;
}

.clear-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    margin-right: 15px;
    line-height: 1;
    opacity: 0.7;
    transition: opacity 0.3s, color 0.3s;
}

.clear-btn.hidden {
    opacity: 0;
    pointer-events: none;
}

.clear-btn svg {
    width: 14px;
    height: 14px;
    fill: #aaa;
    display: block;
}

.clear-btn:hover {
    opacity: 1;
}

.clear-btn:hover svg {
    fill: #fff;
}

.no-results-message {
    color: #888;
    font-size: 16px;
    text-align: center;
    width: 100%;
    padding: 40px 20px;
}


.gallery-clear-btn:hover {
    opacity: 1;
}
.gallery-clear-btn:hover svg {
    fill: #fff;
}

.gallery-autocomplete-list {
    list-style: none;
    margin: 0 auto;
    padding: 8px;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    max-width: 500px;
    background: rgba(30,30,30,0.9);
    border: 1px solid #333;
    border-radius: 16px;
    max-height: 280px;
    overflow-y: auto;
    backdrop-filter: blur(12px);
    z-index: 11;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    filter: invert(var(--theme-invert-progress));
    transition: none;
}

.gallery-autocomplete-list li {
    padding: 14px 20px;
    font-size: 15px;
    color: #eee;
    cursor: pointer;
    transition: background .2s;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-radius: 8px;
}

.gallery-autocomplete-list li:hover,
.gallery-autocomplete-list li.active { background: rgba(255,255,255,0.1); }

.gallery-autocomplete-list li b {
    font-weight: 600;
    color: #fff;
}

.hidden { display: none !important; }

.category-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    max-width: 800px;
    margin: 30px auto 0;
    animation: filter-load 0.8s ease-out 0.6s both;
}

.gallery-category-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 25px 0;
    animation: filter-load 0.8s ease-out 0.6s both;
    max-width: 800px;
    margin: 30px auto;
    margin-bottom: 0px;
}

.gallery-category-btn {
    padding: 9px 22px;
    font-size: 13px;
    font-weight: 200;
    color: #aaa;
    background: transparent;
    border: 1px solid #444;
    border-radius: 100px;
    cursor: pointer;
    filter: invert(var(--theme-invert-progress));
    transition: border-color 0.3s, box-shadow 0.3s;
    white-space: nowrap;
}

.gallery-category-btn:hover {
    background: rgba(255,255,255,0.05);
    color: #fff;
    border-color: #777;
}

.gallery-category-btn.active {
    background: #fff;
    color: #111;
    border-color: #fff;
    font-weight: 600;
}

/* Overlay Styles */
.gallery-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(3px);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.gallery-overlay:not(.hidden) {
    opacity: 1;
    pointer-events: auto;
}

.gallery-overlay-content {
    width: 500px;
    height: 417px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}
.gallery-overlay-content iframe {
    width: 100%;
    height: 100%;
    border: none;
    scale: 1.666;
    margin-left: 33.333%;
    margin-top: 27.9%;
}

@media (hover: hover) {
    .gallery-container.is-focused .gallery-card-wrapper {
        filter: blur(3px) grayscale(1);
        opacity: 0.5;
        transform: scale(1);
    }

    .gallery-container.is-focused .gallery-card-wrapper:hover {
        filter: none;
        opacity: 1;
        transform: scale(1.1) !important;
        z-index: 9;
    }
    
    .gallery-container.is-focused .gallery-card-wrapper:hover .gallery-card .gallery-card-info {
        clip-path: polygon(0 90%, 100% 80%, 100% 100%, 0 100%);
        padding-bottom: 20px;
    }

    .gallery-container.is-focused .gallery-card-wrapper:hover .gallery-card .gallery-card-info h3 {
        opacity: 0;
        height: 0;
        margin: 0;
        transition: opacity 0.3s ease, height 0.3s ease, margin 0.3s ease;
    }

    .gallery-card:hover .gallery-card-info {
        clip-path: polygon(0 40%, 100% 0%, 100% 100%, 0 100%);
    }

    .gallery-container .gallery-card:hover {
        background-size: 110%;
    }

    .gallery-container .gallery-card .gallery-card-info h3 {
        opacity: 0;
        transform: translate3d(0, 60px, 30px);
        transition: opacity 0.35s ease, transform 0.35s ease;
        will-change: transform, opacity;
    }

    .gallery-container .gallery-card .gallery-card-info .cta {
        opacity: 0;
        transform: translate3d(0, 60px, 40px);
        transition: opacity 0.35s ease, transform 0.35s ease;
        will-change: transform, opacity;
    }

    .gallery-container .gallery-card:hover .gallery-card-info h3 {
        opacity: 1;
        transform: translate3d(0, 0, 30px);
    }

    .gallery-container .gallery-card:hover .gallery-card-info .cta {
        opacity: 1;
        transform: translate3d(0, 0, 40px);
        transition-delay: 0.08s;
    }
}

@media (max-width: 768px) {
    .gallery-overlay-content iframe {
        width: 100%;
        height: 100%;
        border: none;
        scale: 1.333;
        margin-left: 16.6%;
        margin-top: 13.9%;
    }
    .gallery-overlay-content {
        width: 400px;
        height: 333px;
        border-radius: 10px;
        overflow: hidden;
        position: relative;
    }

    .gallery-card-iframe {
        pointer-events: none;
    }

    .gallery-card-wrapper.tile-active .gallery-card-iframe {
        pointer-events: auto;
    }

    body.tile-view-active .gallery-container .gallery-card-wrapper:not(.tile-active) {
        filter: grayscale(1) blur(2px);
        opacity: 0.5;
        transform: scale(0.95);
        transition: all 0.4s ease-in-out;
    }

    .gallery-filter-bar {
        margin-bottom: 30px;
    }

    .filter-input,
    .gallery-filter-input {
        padding-right: 0;
        min-width: 0;
    }

    .project-count,
    .gallery-project-count {
        position: static;
        transform: none;
        margin: 0 10px;
        flex-shrink: 0;
    }

    .clear-btn,
    .gallery-clear-btn {
        position: static;
        transform: none;
        margin-right: 15px;
        flex-shrink: 0;
    }

    .gallery-card-wrapper.tile-active {
        transform: scale(1.25) !important;
        transition: all 0.4s ease-in-out;
        z-index: 10;
    }

    .gallery-card-wrapper.tile-active .gallery-card-info {
        display: none;
    }
}

.gallery-close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: #fff;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
    line-height: 1;
    transition: transform 0.2s;
}

.gallery-close-btn:hover {
    transform: scale(1.1);
    color: #ff4444;
}

.gallery-close-tile-btn {
    position: fixed;
    top: 20px;
    right: 30px;
    background: none;
    color: #fff;
    border: none;
    cursor: pointer;
    z-index: 1001;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 40px;
    line-height: 1;
    transition: transform 0.2s, opacity 0.3s, color 0.3s;
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
}

body.tile-view-active .gallery-close-tile-btn {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.gallery-close-tile-btn:hover {
    transform: scale(1.1);
    color: #ff4444;
}

.gallery-interaction-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
}

@media (max-width: 768px) {
    .gallery-interaction-overlay {
        pointer-events: auto;
    }
    
    .gallery-card-wrapper.tile-active .gallery-interaction-overlay {
        pointer-events: none;
    }
}

body.gallery-touch-mobile-view .gallery-card-wrapper {
    width: 100%;
    box-sizing: border-box;
}

body.gallery-touch-mobile-view .gallery-card-link {
    width: 100%;
}

@media (hover: hover) {
    .gallery-interaction-overlay {
        pointer-events: none;
    }
}

/* --- Gallery 03 Specific Overrides (HTML Creatives) --- */
#creative-container_03 .gallery-card {
    width: 300px;
    height: 250px;
}

#creative-container_03 .gallery-card-info {
    padding-bottom: 40px;
}

#creative-container_03 .gallery-card-iframe {
    top: -1px;
    left: -1px;
    width: 101%;
    height: 101%;
    transform: none;
}

#creative-container_03 .gallery-card-poster {
    top: -1px;
    left: -1px;
    width: 101%;
    height: 101%;
    transform: none;
}

#creative-container_03 .gallery-card-info h3 {
    font-size: 1.5em;
}

body.gallery-touch-mobile-view #creative-container_03 .gallery-card {
    --gallery-campaign-card-scale: 1;
    width: 100%;
    height: auto;
    aspect-ratio: 300 / 250;
}

body.gallery-touch-mobile-view #creative-container_03 .gallery-card-poster {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: none;
}

body.gallery-touch-mobile-view #creative-container_03 .gallery-card-iframe {
    top: 0;
    left: 0;
    width: 300px;
    height: 250px;
    transform-origin: 0 0;
    transform: scale(var(--gallery-campaign-card-scale));
    transition: none;
}

body.gallery-touch-mobile-view #creative-container_03 .gallery-card.loaded .gallery-card-poster {
    opacity: 0;
}

/* --- Gallery 05 Specific Overrides (Mobile Ads) --- */
#creative-container_05 .gallery-card {
    width: 260px;
    height: auto;
    aspect-ratio: 390 / 680;
}

#creative-container_05 .gallery-card-info {
    padding-bottom: 130px;
}

#creative-container_05 .gallery-card-iframe {
    top: 50%;
    left: 50%;
    width: 200%;
    height: 200%;
    transform: translate(-50%, -50%) scale(0.67);
}

#creative-container_05 .gallery-card-poster {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: none;
}

#creative-container_05 .gallery-card-info h3 {
    font-size: 2.2em;
}

body.gallery-touch-mobile-view #creative-container_05 .gallery-card {
    --gallery-mobile-ad-preview-scale: 1;
    width: 100%;
    height: auto;
    aspect-ratio: 390 / 680;
}

body.gallery-touch-mobile-view #creative-container_05 .gallery-card-iframe {
    top: 50%;
    left: 50%;
    width: 390px;
    height: 686px;
    transform-origin: 50% 50%;
    transform: translate(-50%, -50%) scale(var(--gallery-mobile-ad-preview-scale));
    transition: none;
}

body.gallery-touch-mobile-view #creative-container_05 .gallery-card-poster {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: none;
}

.gallery-wrapper {
    position: absolute;
    height: 100%;
    width: 100%;
    top: 0px;
    overflow-y: scroll;
}

/* Filter Bar Container */
.gallery-filter-bar {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    position: relative;
    background: rgba(37, 37, 37, 0.7);
    border-radius: 100px;
    border: 1px solid #444;
    backdrop-filter: blur(10px);
    filter: invert(var(--theme-invert-progress));
    transition: border-color 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.gallery-filter-bar:focus-within {
    border-color: #888;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.gallery-search-icon {
    width: 20px;
    height: 20px;
    fill: #888;
    margin: 0 10px 0 20px;
}

/* Category Buttons */
.category-btn {
    background: transparent;
    border: 1px solid #444;
    color: #888;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    filter: invert(var(--theme-invert-progress));
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    font-size: 14px;
    margin: 5px;
}

.category-btn:hover {
    border-color: #fff;
    color: #fff;
}

.category-btn.active {
    background: #fff;
    color: #000;
    border-color: #fff;
}

/* --- Overlay Overrides --- */

/* Gallery 03 (HTML Creatives) - Matches style.css */
#creativeOverlay_03 .overlay-content {
    width: 500px;
    height: 417px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    transform: none;
}

#creativeOverlay_03 .overlay-content iframe {
    width: 100%;
    height: 100%;
    border: none;
    scale: 1.666;
    margin-left: 33.333%;
    margin-top: 27.9%;
}

/* Gallery 05 (Mobile Ads) - Matches style-gallery-05.css */
#creativeOverlay_05 .overlay-content {
    width: 430px;
    height: 870px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    transform: scale(0.9);
}

#creativeOverlay_05 .overlay-content iframe {
    width: 100%;
    height: 100%;
    border: none;
    scale: 1;
    margin-left: 0%;
    margin-top: 0%;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay {
    --gallery-overlay-control-size: 48px;
    --gallery-overlay-menu-center-offset: calc(15px + 50px);
    --gallery-overlay-control-edge: calc(var(--gallery-overlay-menu-center-offset) - (var(--gallery-overlay-control-size) / 2));
    --gallery-overlay-close-top: var(--gallery-overlay-control-edge);
    --gallery-overlay-close-right: var(--gallery-overlay-control-edge);
    z-index: 2147483000;
    background: transparent;
    backdrop-filter: none;
    overflow: hidden;
    transition: none;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .overlay-content {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
    overflow: hidden;
    position: relative;
    transform: none;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .overlay-content iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
    scale: 1;
    margin: 0;
    display: block;
    transform-origin: 50% 50%;
    will-change: transform, opacity;
}

.gallery-overlay-controls {
    display: none;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-controls {
    display: block;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-close,
#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-nav {
    position: fixed;
    z-index: 2147483001;
    width: var(--gallery-overlay-control-size);
    height: var(--gallery-overlay-control-size);
    border: 0;
    background: transparent;
    color: #fff;
    padding: 0;
    cursor: pointer;
    line-height: 1;
    transform-origin: 50% 50%;
    -webkit-tap-highlight-color: transparent;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-close {
    top: max(var(--gallery-overlay-close-top), env(safe-area-inset-top));
    right: max(var(--gallery-overlay-close-right), env(safe-area-inset-right));
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-prev,
#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-next {
    bottom: max(var(--gallery-overlay-control-edge), env(safe-area-inset-bottom));
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-prev {
    left: max(var(--gallery-overlay-control-edge), env(safe-area-inset-left));
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-next {
    right: max(var(--gallery-overlay-control-edge), env(safe-area-inset-right));
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-surface {
    width: var(--gallery-overlay-control-size);
    height: var(--gallery-overlay-control-size);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: transparent;
    position: relative;
    pointer-events: none;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-fill {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.18);
    opacity: 1;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-circle-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    transform: rotate(-90deg);
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-circle-line {
    fill: none;
    stroke: #fff;
    stroke-width: 1;
    stroke-dasharray: 142;
    stroke-dashoffset: 0;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-icon {
    overflow: visible;
    position: relative;
    z-index: 1;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-arrow-icon {
    width: 16px;
    height: 22px;
    transform: translateX(2px);
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-prev .gallery-overlay-arrow-icon {
    transform: rotate(180deg) translateX(2px);
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-close-icon {
    width: 21px;
    height: 21px;
}

#creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-line {
    fill: none;
    stroke: #fff;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 27;
    stroke-dashoffset: 0;
}

@media (hover: hover) {
    #creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control:hover .gallery-overlay-control-fill {
        background: rgba(0, 0, 0, 0.3);
    }
}

@media (max-width: 640px) {
    #creativeOverlay_05.fullscreen-mobile-ad-overlay {
        --gallery-overlay-control-size: 44px;
    }

    #creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-close,
    #creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-nav,
    #creativeOverlay_05.fullscreen-mobile-ad-overlay .gallery-overlay-control-surface {
        width: var(--gallery-overlay-control-size);
        height: var(--gallery-overlay-control-size);
    }
}
