/* assets/css/ads/ad_pair.css
 * Ad Pair Component — Shrink-to-fit card, centered
 * ✅ Single AD badge in label row
 * ✅ No per-banner badge
 * ✅ No overlay buttons on ads (server-side content only)
 */

/* ═══════════════════════════════════════════════════════════
   WRAPPER
   ═══════════════════════════════════════════════════════════ */
.otvut-ad-pair-wrap {
    width: 100%;
    margin: 0 0 20px 0;
    padding: 0;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    clear: both;
}

/* ═══════════════════════════════════════════════════════════
   SINGLE CARD
   ═══════════════════════════════════════════════════════════ */
.otvut-ad-pair-container {
    position: relative;
    width: fit-content;
    max-width: 100%;
    background-color: var(--card-bg, #ffffff);
    border: 1px solid var(--card-border, rgba(249, 115, 22, 0.3));
    border-radius: 12px;
    overflow: hidden;
    box-sizing: border-box;
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    color: var(--text-main, #1e293b);
}

.dark .otvut-ad-pair-container,
[data-theme="dark"] .otvut-ad-pair-container {
    background-color: #0b0d19;
    border-color: rgba(249, 115, 22, 0.4);
    color: #e2e8f0;
}

/* ═══════════════════════════════════════════════════════════
   LABEL ROW — "SPONSORED" left, "AD" badge right
   ✅ Single label row with SPONSORED + AD
   ═══════════════════════════════════════════════════════════ */
.adbc-single-label {
    display: flex;
    align-items: center;
    justify-content: space-between;     /* ✅ SPONSORED left, AD right */
    gap: 8px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #71717a;
    user-select: none;
    line-height: 1;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.adbc-label-left {
    display: flex;
    align-items: center;
    gap: 6px;
}

.adbc-single-label .adbc-label-dot {
    width: 6px;
    height: 6px;
    border-radius: 9999px;
    background: #f97316;
    box-shadow: 0 0 8px rgba(249, 115, 22, .6);
    flex-shrink: 0;
}

/* ✅ Single "AD" badge on the right side of label row */
.adbc-single-label .adbc-ad-badge {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .06em;
    padding: 2px 7px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.06);
    color: #94a3b8;
    border: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.dark .adbc-single-label,
[data-theme="dark"] .adbc-single-label {
    color: #a1a1aa;
}
html:not(.dark) .adbc-single-label {
    border-bottom-color: rgba(0, 0, 0, 0.05);
}
html:not(.dark) .adbc-single-label .adbc-ad-badge {
    background: rgba(0, 0, 0, 0.04);
    color: #71717a;
    border-color: rgba(0, 0, 0, 0.06);
}

/* ═══════════════════════════════════════════════════════════
   INNER ROW — both ads at 280px height (Desktop)
   ═══════════════════════════════════════════════════════════ */
.otvut-ad-pair-row {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 280px;
}

.adbc-cell {
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    flex-shrink: 0;
    min-width: 0;
    height: 100%;
}

.adbc-cell--left {
    width: 75px;
    flex: 0 0 75px;
    max-width: 75px;
}

.adbc-cell--right {
    width: 336px;
    flex: 0 0 336px;
    max-width: 336px;
}

.adbc-slot {
    position: relative;
    width: 100%;
    height: 100%;
    background: transparent;
    border-radius: 8px;
    overflow: hidden;
    box-sizing: border-box;
    flex-shrink: 0;
    display: block;
}

.adbc-slot-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    overflow: hidden;
    position: relative;
    border-radius: 8px;
}

.adbc-slot-inner img,
.adbc-slot img,
.otvut-ad-slot img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover !important;
    object-position: center;
    background: transparent;
    border-radius: 8px;
}

.adbc-slot-inner a,
.adbc-slot a,
.otvut-ad-slot a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 8px;
}

.adbc-slot-inner a img,
.adbc-slot a img,
.otvut-ad-slot a img {
    width: 100%;
    height: 100%;
    object-fit: cover !important;
}

/* ── Placeholder ── */
.adbc-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: #52525b;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .04em;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
}
.adbc-placeholder i { font-size: 20px; color: #3f3f46; margin-bottom: 2px; }
.adbc-placeholder small { font-size: 9px; color: #3f3f46; font-weight: 500; }

html:not(.dark) .otvut-ad-pair-container {
    background-color: #ffffff;
    border-color: rgba(249, 115, 22, 0.3);
    color: #1e293b;
}
html:not(.dark) .adbc-placeholder {
    color: #a1a1aa;
    background: rgba(0, 0, 0, 0.02);
}
html:not(.dark) .adbc-placeholder i,
html:not(.dark) .adbc-placeholder small { color: #d4d4d8; }

.otvut-ad-pair-wrap[data-ad-pair-empty="1"] { display: none !important; }

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 767px) {
    .otvut-ad-pair-wrap {
        margin: 0 0 12px 0 !important;
        width: 100vw !important;
        position: relative;
        left: 50%;
        right: 50%;
        transform: translateX(-50%);
        display: block;
    }

    .otvut-ad-pair-container {
        width: 100% !important;
        max-width: 100% !important;
        border: none !important;
        border-radius: 0 !important;
        padding: 12px 10px 14px;
        gap: 10px;
    }

    .dark .otvut-ad-pair-container,
    [data-theme="dark"] .otvut-ad-pair-container {
        background-color: #0b0d19;
    }

    .otvut-ad-pair-row {
        gap: 8px;
        height: 240px;
    }

    .adbc-cell--left {
        width: 64px;
        flex: 0 0 64px;
        max-width: 64px;
    }

    .adbc-cell--right {
        width: 288px;
        flex: 0 0 288px;
        max-width: 288px;
    }

    .adbc-single-label {
        font-size: 9px;
        letter-spacing: .06em;
        padding-bottom: 8px;
    }
    .adbc-single-label .adbc-label-dot {
        width: 5px;
        height: 5px;
    }
    .adbc-single-label .adbc-ad-badge {
        font-size: 8px;
        padding: 1px 5px;
    }

    .adbc-placeholder i { font-size: 16px; }
    .adbc-placeholder span { font-size: 10px; }
    .adbc-placeholder small { font-size: 8px; }
}

@media (max-width: 400px) {
    .otvut-ad-pair-row {
        gap: 6px;
        height: 200px;
    }
    .adbc-cell--left {
        width: 53px;
        flex: 0 0 53px;
        max-width: 53px;
    }
    .adbc-cell--right {
        width: 240px;
        flex: 0 0 240px;
        max-width: 240px;
    }
}