/**
 * Ad Manager Affiliate - High-Converting Native Frontend Styles
 * Built specifically for KingTube theme & Hornysimp video post layouts.
 */

.mng-affiliate-spot {
    width: 100%;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
}

.mng-spot-display {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.mng-spot-display img,
.mng-spot-display iframe {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.mng-affiliate-slot {
    margin: 14px 0;
    width: 100%;
    box-sizing: border-box;
}

/* 1. Native Under-Player Action Bar */
.mng-native-cta-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #1e1b4b 0%, #0f172a 100%);
    border: 1px solid rgba(139, 92, 246, 0.35);
    border-radius: 10px;
    padding: 12px 18px;
    text-decoration: none !important;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    color: #ffffff !important;
    overflow: hidden;
}

.mng-native-cta-bar:hover {
    transform: translateY(-2px);
    border-color: #a855f7;
    box-shadow: 0 6px 20px rgba(168, 85, 247, 0.3);
}

.mng-cta-content {
    display: flex;
    align-items: center;
    gap: 14px;
    flex: 1;
    min-width: 0;
}

.mng-cta-media {
    width: 52px;
    height: 52px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.mng-cta-media img,
.mng-cta-media video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.mng-cta-text-wrap {
    min-width: 0;
}

.mng-cta-headline-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.mng-cta-badge {
    background: #ec4899;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    animation: mngPulse 2s infinite;
}

@keyframes mngPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.85; transform: scale(1.04); }
}

.mng-cta-headline {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.3;
}

.mng-cta-subtitle {
    font-size: 13px;
    color: #94a3b8;
    margin-top: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mng-cta-btn-wrap {
    margin-left: 16px;
    flex-shrink: 0;
}

.mng-cta-button {
    background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%);
    color: #ffffff !important;
    font-size: 13px;
    font-weight: 700;
    padding: 9px 18px;
    border-radius: 8px;
    display: inline-block;
    transition: background 0.2s ease, transform 0.2s ease;
    white-space: nowrap;
}

.mng-native-cta-bar:hover .mng-cta-button {
    transform: scale(1.05);
}

/* 2. In-Grid Pseudo-Video Card (Related Grid) */
.mng-affiliate-grid-item {
    position: relative;
}

.mng-grid-thumb-wrapper {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
}

.mng-grid-thumb-wrapper video,
.mng-grid-thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.mng-grid-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background: rgba(236, 72, 153, 0.95);
    color: #ffffff;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 3px;
    letter-spacing: 0.5px;
    z-index: 2;
}

.mng-grid-title {
    color: #ffffff;
    font-size: 13px !important;
    margin: 8px 0 4px 0 !important;
    line-height: 1.3 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.mng-grid-meta {
    font-size: 11px;
    color: #94a3b8;
}

.mng-sponsored-tag {
    color: #a855f7;
    font-weight: 600;
}

/* 3. Responsive Adjustments */
@media (max-width: 640px) {
    .mng-native-cta-bar {
        flex-direction: column;
        align-items: flex-start;
        padding: 12px 14px;
        gap: 10px;
    }

    .mng-cta-btn-wrap {
        width: 100%;
        margin-left: 0;
    }

    .mng-cta-button {
        display: block;
        text-align: center;
        width: 100%;
        box-sizing: border-box;
    }

    .mng-cta-subtitle {
        white-space: normal;
    }
}

/* 4. Global Header Billboards (After Menu Bar on All Pages) */
.mng-global-header-billboard-wrapper {
    width: 100%;
    margin: 12px auto;
    padding: 0 10px;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    overflow: hidden;
}

.mng-header-billboard-desktop {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin: 0 auto;
}

.mng-header-billboard-desktop img,
.mng-header-billboard-desktop iframe,
.mng-header-billboard-desktop video {
    max-width: 100% !important;
    height: auto;
    margin: 0 auto;
}

.mng-header-billboard-mobile {
    display: none;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin: 0 auto;
}

.mng-header-billboard-mobile img,
.mng-header-billboard-mobile iframe,
.mng-header-billboard-mobile video {
    max-width: 100% !important;
    height: auto;
    margin: 0 auto;
}

@media (max-width: 767px) {
    .mng-header-billboard-desktop {
        display: none !important;
    }
    .mng-header-billboard-mobile {
        display: flex !important;
    }
}

@media (min-width: 768px) {
    .mng-header-billboard-desktop {
        display: flex !important;
    }
    .mng-header-billboard-mobile {
        display: none !important;
    }
}


