/* ==========================================
   REELSNIP DIRECT AD SYSTEM
   ads/ads.css
   ========================================== */


/* ==========================================
   GENERAL AD SLOT
   ========================================== */
/* 720x90 Banner Ad */
.direct-ad.banner-ad {
    width: 100%;
    max-width: 728px;
    height: 90px;
    margin: 16px auto;
    overflow: hidden;
}

.direct-ad.banner-ad img,
.direct-ad.banner-ad video {
    display: block;
    width: 100%;
    height: 90px;
    object-fit: cover;
}

[data-ad-position] {
    width: 100%;
    max-width: 100%;
    margin: 16px auto;
    padding: 0;
    text-align: center;
    box-sizing: border-box;
    min-width: 0;
}


/* ==========================================
   MAIN AD CONTAINER
   ========================================== */

.direct-ad {
    position: relative;
    display: block;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
    overflow: hidden;
    box-sizing: border-box;
    min-width: 0;
}


/* ==========================================
   CLICKABLE AD
   ========================================== */

.direct-ad a {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    text-decoration: none;
    border: 0;
    outline: none;
    line-height: 0;
    box-sizing: border-box;
    transition: opacity 0.2s ease;
}

.direct-ad a:hover {
    opacity: 0.94;
}

.direct-ad a:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}


/* ==========================================
   IMAGE ADS
   ========================================== */

.direct-ad img {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
    border: 0;
    outline: none;
    box-sizing: border-box;
}


/* ==========================================
   TOP BANNER
   728 × 90
   ========================================== */

[data-ad-position="top"] {
    width: 100%;
    max-width: 100%;
    min-height: 90px;
}

[data-ad-position="top"] .direct-ad {
    display: block;
    width: 100%;
    max-width: 728px;
    height: 90px;
    margin: 0 auto;
}

[data-ad-position="top"] .direct-ad img {
    display: block;
    width: 100%;
    height: 90px;
    object-fit: contain;
}


/* ==========================================
   CONTENT BANNER
   728 × 90
   ========================================== */

[data-ad-position="content"] {
    width: 100%;
    max-width: 100%;
    min-height: 90px;
}

[data-ad-position="content"] .direct-ad {
    display: block;
    width: 100%;
    max-width: 728px;
    height: 90px;
    margin: 0 auto;
}

[data-ad-position="content"] .direct-ad img {
    display: block;
    width: 100%;
    height: 90px;
    object-fit: contain;
}


/* ==========================================
   FOOTER BANNER
   728 × 90
   ========================================== */

[data-ad-position="footer"] {
    width: 100%;
    max-width: 100%;
    min-height: 90px;
}

[data-ad-position="footer"] .direct-ad {
    display: block;
    width: 100%;
    max-width: 728px;
    height: 90px;
    margin: 0 auto;
}

[data-ad-position="footer"] .direct-ad img {
    display: block;
    width: 100%;
    height: 90px;
    object-fit: contain;
}


/* ==========================================
   SIDEBAR AD
   300 × 250
   ========================================== */

[data-ad-position="sidebar"] {
    width: 100%;
    max-width: 300px;
    min-height: 250px;
    margin-left: auto;
    margin-right: auto;
}

[data-ad-position="sidebar"] .direct-ad {
    width: 300px;
    max-width: 100%;
    height: 250px;
    margin: 0 auto;
}

[data-ad-position="sidebar"] .direct-ad img {
    display: block;
    width: 300px;
    max-width: 100%;
    height: 250px;
    object-fit: contain;
}


/* ==========================================
   VIDEO AD
   16:9
   ========================================== */

[data-ad-position="video"] {
    width: 100%;
    max-width: 100%;
    min-height: 0;
}


/* ==========================================
   VIDEO CONTAINER
   ========================================== */

[data-ad-position="video"] .direct-ad {
    position: relative;
    display: block;
    width: 100%;
    max-width: 640px;
    height: auto;
    aspect-ratio: 16 / 9;
    margin: 0 auto;
    padding: 0;
    overflow: hidden;
    background: #000;
    box-sizing: border-box;
}


/* ==========================================
   VIDEO WRAPPER
   ========================================== */

.video-ad-wrapper {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #000;
    box-sizing: border-box;
}


/* ==========================================
   VIDEO
   ========================================== */

.video-ad-wrapper video {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    outline: none;
    background: #000;
    object-fit: cover;
    box-sizing: border-box;
}


/* ==========================================
   GENERAL VIDEO FALLBACK
   ========================================== */

.direct-ad video {
    display: block;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
    background: #000;
    border: 0;
    outline: none;
    box-sizing: border-box;
}


/* ==========================================
   VIDEO CLICK AREA
   ========================================== */

.video-ad-wrapper a {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    line-height: 0;
    box-sizing: border-box;
}


/* ==========================================
   VIDEO SOUND BUTTON
   ========================================== */

.ad-sound-button {
    position: absolute;

    right: 10px;
    bottom: 10px;

    z-index: 100;

    width: 42px;
    height: 42px;

    margin: 0;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: rgba(0, 0, 0, 0.75);
    color: #fff;

    font-size: 18px;
    line-height: 1;

    cursor: pointer;

    display: flex;
    align-items: center;
    justify-content: center;

    opacity: 1;

    -webkit-tap-highlight-color: transparent;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.ad-sound-button:hover {
    background: rgba(0, 0, 0, 0.92);
    transform: scale(1.05);
}

.ad-sound-button:active {
    transform: scale(0.95);
}

.ad-sound-button:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}


/* ==========================================
   TABLET
   ========================================== */

@media (max-width: 768px) {

    [data-ad-position] {
        width: 100%;
        max-width: 100%;
        margin: 12px auto;
        padding: 0 8px;
    }


    /* ======================================
       TOP BANNER
       ====================================== */

    [data-ad-position="top"] {
        min-height: 100px;
    }

    [data-ad-position="top"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: 100px;
    }

    [data-ad-position="top"] .direct-ad img {
        width: 100%;
        height: 100px;
        object-fit: contain;
    }


    /* ======================================
       CONTENT BANNER
       ====================================== */

    [data-ad-position="content"] {
        min-height: 100px;
    }

    [data-ad-position="content"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: 100px;
    }

    [data-ad-position="content"] .direct-ad img {
        width: 100%;
        height: 100px;
        object-fit: contain;
    }


    /* ======================================
       FOOTER BANNER
       ====================================== */

    [data-ad-position="footer"] {
        min-height: 100px;
    }

    [data-ad-position="footer"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: 100px;
    }

    [data-ad-position="footer"] .direct-ad img {
        width: 100%;
        height: 100px;
        object-fit: contain;
    }


    /* ======================================
       SIDEBAR
       ====================================== */

    [data-ad-position="sidebar"] {
        width: 100%;
        max-width: 300px;
        min-height: 250px;
        margin-left: auto;
        margin-right: auto;
        padding: 0;
    }

    [data-ad-position="sidebar"] .direct-ad {
        width: 300px;
        max-width: 100%;
        height: 250px;
    }

    [data-ad-position="sidebar"] .direct-ad img {
        width: 300px;
        max-width: 100%;
        height: 250px;
        object-fit: contain;
    }


    /* ======================================
       VIDEO 16:9
       ====================================== */

    [data-ad-position="video"] {
        width: 100%;
        max-width: 100%;
        min-height: 0;
    }

    [data-ad-position="video"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }

    [data-ad-position="video"] .video-ad-wrapper {
        width: 100%;
        height: 100%;
        aspect-ratio: 16 / 9;
    }

    [data-ad-position="video"] .video-ad-wrapper video {
        width: 100%;
        height: 100%;
        max-width: 100%;
        aspect-ratio: 16 / 9;
        object-fit: cover;
    }

}


/* ==========================================
   SMALL MOBILE
   ========================================== */

@media (max-width: 480px) {

    [data-ad-position] {
        width: 100%;
        max-width: 100%;
        margin: 10px auto;
        padding: 0 5px;
    }


    /* ======================================
       TOP BANNER
       ====================================== */

    [data-ad-position="top"] {
        min-height: 90px;
    }

    [data-ad-position="top"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: 90px;
    }

    [data-ad-position="top"] .direct-ad img {
        width: 100%;
        height: 90px;
        object-fit: contain;
    }


    /* ======================================
       CONTENT BANNER
       ====================================== */

    [data-ad-position="content"] {
        min-height: 90px;
    }

    [data-ad-position="content"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: 90px;
    }

    [data-ad-position="content"] .direct-ad img {
        width: 100%;
        height: 90px;
        object-fit: contain;
    }


    /* ======================================
       FOOTER BANNER
       ====================================== */

    [data-ad-position="footer"] {
        min-height: 90px;
    }

    [data-ad-position="footer"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: 90px;
    }

    [data-ad-position="footer"] .direct-ad img {
        width: 100%;
        height: 90px;
        object-fit: contain;
    }


    /* ======================================
       SIDEBAR
       ====================================== */

    [data-ad-position="sidebar"] {
        width: 100%;
        max-width: 300px;
        min-height: 250px;
        margin-left: auto;
        margin-right: auto;
        padding: 0;
    }

    [data-ad-position="sidebar"] .direct-ad {
        width: 300px;
        max-width: 100%;
        height: 250px;
    }

    [data-ad-position="sidebar"] .direct-ad img {
        width: 300px;
        max-width: 100%;
        height: 250px;
        object-fit: contain;
    }


    /* ======================================
       VIDEO 16:9
       ====================================== */

    [data-ad-position="video"] {
        width: 100%;
        max-width: 100%;
        min-height: 0;
        padding: 0 5px;
    }

    [data-ad-position="video"] .direct-ad {
        width: 100%;
        max-width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }

    [data-ad-position="video"] .video-ad-wrapper {
        width: 100%;
        height: 100%;
        aspect-ratio: 16 / 9;
    }

    [data-ad-position="video"] .video-ad-wrapper video {
        width: 100%;
        height: 100%;
        max-width: 100%;
        aspect-ratio: 16 / 9;
        object-fit: cover;
    }


    /* ======================================
       SOUND BUTTON MOBILE
       ====================================== */

    .ad-sound-button {
        right: 8px;
        bottom: 8px;
        width: 38px;
        height: 38px;
        font-size: 16px;
    }

}


/* ==========================================
   HIDE EMPTY AD SLOTS
   ========================================== */

[data-ad-position]:empty {
    display: none;
}


/* ==========================================
   PREVENT VIDEO OVERFLOW
   ========================================== */

.video-ad-wrapper,
.video-ad-wrapper video {
    overflow: hidden;
}


/* ==========================================
   ACCESSIBILITY
   ========================================== */

.ad-sound-button[aria-label] {
    -webkit-tap-highlight-color: transparent;
}


/* ==========================================
   FLOATING AD
   Fixed on screen
   ========================================== */

[data-ad-position="floating"] {
    position: fixed !important;

    right: 20px;
    bottom: 20px;

    width: 320px;
    max-width: calc(100vw - 40px);

    margin: 0 !important;
    padding: 0 !important;

    z-index: 999999;

    text-align: center;

    pointer-events: auto;

    box-sizing: border-box;
}


/* ==========================================
   FLOATING AD CONTAINER
   ========================================== */

[data-ad-position="floating"] .direct-ad {
    position: relative;

    display: block;

    width: 100%;
    max-width: 320px;

    margin: 0 auto;
    padding: 0;

    overflow: hidden;

    border-radius: 8px;

    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.4);

    background: #000;

    box-sizing: border-box;
}


/* ==========================================
   FLOATING IMAGE
   ========================================== */

[data-ad-position="floating"] .direct-ad img {
    display: block;

    width: 100%;
    height: auto;

    max-width: 100%;
    max-height: 250px;

    margin: 0 auto;

    object-fit: contain;
}


/* ==========================================
   FLOATING VIDEO
   ========================================== */

[data-ad-position="floating"] .video-ad-wrapper {
    position: relative;

    width: 100%;
    height: auto;

    aspect-ratio: 16 / 9;

    overflow: hidden;

    background: #000;

    box-sizing: border-box;
}

[data-ad-position="floating"] .video-ad-wrapper video {
    display: block;

    width: 100%;
    height: 100%;

    max-width: 100%;

    margin: 0;
    padding: 0;

    object-fit: cover;
}


/* ==========================================
   FLOATING SOUND BUTTON
   ========================================== */

[data-ad-position="floating"] .ad-sound-button {
    position: absolute;

    right: 8px;
    bottom: 8px;

    z-index: 1000;

    width: 38px;
    height: 38px;

    margin: 0;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: rgba(0, 0, 0, 0.75);
    color: #fff;

    font-size: 16px;

    display: flex;
    align-items: center;
    justify-content: center;

    cursor: pointer;

    -webkit-tap-highlight-color: transparent;
}


/* ==========================================
   FLOATING AD - MOBILE
   ========================================== */

@media (max-width: 600px) {

    [data-ad-position="floating"] {
        right: 10px;
        bottom: 10px;

        width: 280px;
        max-width: calc(100vw - 20px);
    }

    [data-ad-position="floating"] .direct-ad {
        width: 100%;
        max-width: 280px;
    }

    [data-ad-position="floating"] .direct-ad img {
        max-width: 100%;
        max-height: 180px;
    }

    [data-ad-position="floating"] .ad-sound-button {
        right: 7px;
        bottom: 7px;
        width: 36px;
        height: 36px;
        font-size: 15px;
    }

}


/* ==========================================
   VERY SMALL MOBILE
   ========================================== */

@media (max-width: 360px) {

    [data-ad-position="floating"] {
        right: 5px;
        bottom: 5px;

        width: calc(100vw - 10px);
        max-width: calc(100vw - 10px);
    }

    [data-ad-position="floating"] .direct-ad {
        width: 100%;
        max-width: 100%;
    }

}


/* ==========================================
   REDUCED MOTION
   ========================================== */

@media (prefers-reduced-motion: reduce) {

    .direct-ad a,
    .ad-sound-button {
        transition: none;
    }

}


/* ==========================================
   PRINT
   ========================================== */

@media print {

    [data-ad-position] {
        display: none !important;
    }

}
/* ==========================================
   FLOATING BANNER - 16:9
   ========================================== */

[data-ad-position="floating-banner"] {
    position: fixed !important;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);

    width: 420px;
    max-width: calc(100vw - 20px);

    margin: 0 !important;
    padding: 0 !important;

    z-index: 999999;
    box-sizing: border-box;
}

/* 16:9 Banner Container */
[data-ad-position="floating-banner"] .direct-ad {
    position: relative;
    display: block;

    width: 100%;
    max-width: 420px;

    height: auto;
    aspect-ratio: 16 / 9;

    margin: 0 auto;
    padding: 0;

    overflow: visible;

    border-radius: 10px;
    background: #000;

    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.4);

    box-sizing: border-box;
}

/* 16:9 Banner Image */
[data-ad-position="floating-banner"] .direct-ad img {
    display: block;

    width: 100%;
    height: 100%;

    max-width: 100%;

    margin: 0;
    padding: 0;

    border: 0;

    aspect-ratio: 16 / 9;
    object-fit: cover;

    border-radius: 10px;

    box-sizing: border-box;
}

/* ==========================================
   CLOSE BUTTON
   ========================================== */

[data-ad-position="floating-banner"] .ad-close-button {
    position: absolute;

    top: -12px;
    right: -12px;

    width: 28px;
    height: 28px;

    z-index: 1000000;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #000;
    color: #fff;

    font-size: 21px;
    font-weight: 700;
    line-height: 1;

    cursor: pointer;

    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

[data-ad-position="floating-banner"] .ad-close-button:hover {
    background: #222;
}

/* ==========================================
   MOBILE - 16:9
   ========================================== */

@media (max-width: 600px) {

    [data-ad-position="floating-banner"] {
        width: calc(100vw - 20px);
        max-width: 400px;
        bottom: 10px;
    }

    [data-ad-position="floating-banner"] .direct-ad {
        width: 100%;
        max-width: 100%;

        height: auto;
        aspect-ratio: 16 / 9;
    }

    [data-ad-position="floating-banner"] .direct-ad img {
        width: 100%;
        height: 100%;

        aspect-ratio: 16 / 9;
        object-fit: cover;
    }

    [data-ad-position="floating-banner"] .ad-close-button {
        top: -10px;
        right: -5px;

        width: 26px;
        height: 26px;

        font-size: 19px;
    }
}

/* ==========================================
   VERY SMALL MOBILE
   ========================================== */

@media (max-width: 360px) {

    [data-ad-position="floating-banner"] {
        width: calc(100vw - 16px);
        bottom: 8px;
    }
}
}
/* ==========================================
   FLOATING VIDEO - SKIP AD BUTTON
   ========================================== */

[data-ad-position="floating-video"] .ad-skip-button {
    position: absolute;
    right: 10px;
    bottom: 10px;

    z-index: 2000;

    padding: 8px 14px;

    border: 1px solid rgba(255,255,255,0.35);
    border-radius: 5px;

    background: rgba(0,0,0,0.78);
    color: #fff;

    font-family: Arial, sans-serif;
    font-size: 13px;
    font-weight: 600;

    line-height: 1;

    cursor: pointer;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 2px 8px rgba(0,0,0,0.35);

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

[data-ad-position="floating-video"] .ad-skip-button:hover {
    background: rgba(0,0,0,0.95);
    transform: translateY(-1px);
}

[data-ad-position="floating-video"] .ad-skip-button:active {
    transform: scale(0.96);
}


/* ==========================================
   FLOATING VIDEO SKIP - MOBILE
   ========================================== */

@media (max-width: 600px) {

    [data-ad-position="floating-video"] .ad-skip-button {
        right: 7px;
        bottom: 7px;

        padding: 7px 11px;

        font-size: 12px;
    }

}

