/* Google AdSense display units — always in document flow (never fixed/sticky) */
.nukta-adsense,
.nukta-ad-slot,
.nukta-house-ad {
    position: static;
}

/* Hide AdSense Auto ads sticky/anchor overlays that pin to the viewport */
ins.adsbygoogle[data-anchor-status],
.google-auto-placed[style*="position: fixed"],
.google-auto-placed[style*="position:fixed"],
aside.adsbygoogle-noablate[style*="position: fixed"],
aside.adsbygoogle-noablate[style*="position:fixed"] {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.nukta-adsense {
    margin: 1.25rem auto 1.5rem;
    max-width: 720px;
    width: 100%;
    min-height: 90px;
    overflow: hidden;
}

body.post-page-active .nukta-adsense {
    margin: 1.5rem 0 2rem;
}

.nukta-adsense--in-article {
    margin: 1.25rem auto;
    clear: both;
}

body.post-page-active .post-content .nukta-adsense--in-article {
    margin: 1.5rem 0;
}

body.post-page-active .post-content .nukta-ad-slot[data-unit="discover-display"],
body.post-page-active .post-content .nukta-adsense--post-banner,
body.post-page-active .post-content .nukta-adsense--discover {
    margin: 1.5rem 0;
    max-width: 100%;
    width: 100%;
}

body.post-page-active .post-content .nukta-ad-slot[data-unit="discover-display"] .nukta-ads-slot,
body.post-page-active .post-content .nukta-ads-slot--discover {
    max-width: 100%;
}

.discover-ad-slot {
    margin: 0 0 1rem;
    padding: 0 0.25rem;
    max-width: 100%;
}

.discover-ad-slot .nukta-adsense--discover {
    margin: 0 auto;
    max-width: 1100px;
}

/* Regional house ads (fallback while AdSense slots are empty) */
.nukta-ad-slot {
    position: relative;
    margin: 1.25rem auto 1.5rem;
    max-width: 720px;
    width: 100%;
    min-width: 280px;
    min-height: 0;
}

.discover-ad-slot .nukta-ad-slot {
    margin: 0 auto 1rem;
    max-width: 1100px;
}

.nukta-ad-slot .nukta-adsense {
    display: none;
    margin: 0;
    min-height: 0;
}

.nukta-ad-slot--adsense-filled .nukta-adsense {
    display: block;
}

.nukta-ad-slot .nukta-house-ad {
    position: relative;
    display: flex;
    gap: 0.85rem;
    align-items: center;
    text-decoration: none;
    color: inherit;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.98));
    padding: 0.85rem;
    transition: border-color 0.2s ease, transform 0.2s ease;
    overflow: hidden;
    max-height: 150px;
}

.nukta-ad-slot .nukta-house-ad--discover {
    max-height: 140px;
}

.nukta-ad-slot .nukta-house-ad:hover {
    border-color: rgba(96, 165, 250, 0.45);
    transform: translateY(-1px);
}

.nukta-house-ad__img-wrap {
    flex-shrink: 0;
    width: 120px;
    height: 90px;
    max-width: 120px;
    max-height: 90px;
    overflow: hidden;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.2);
}

.nukta-house-ad__img-wrap--discover {
    width: 160px;
    height: 96px;
    max-width: 160px;
    max-height: 96px;
}

.nukta-house-ad__img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
    object-position: center;
}

.nukta-house-ad__body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.nukta-house-ad__meta {
    font-size: 0.72rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: rgba(148, 163, 184, 0.95);
}

.nukta-house-ad__title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.35;
    color: #f8fafc;
}

.nukta-house-ad__excerpt {
    margin: 0;
    font-size: 0.82rem;
    line-height: 1.4;
    color: rgba(203, 213, 225, 0.9);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.nukta-house-ad__badge {
    position: absolute;
    top: 0.55rem;
    right: 0.55rem;
    font-size: 0.62rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: rgba(148, 163, 184, 0.85);
    background: rgba(15, 23, 42, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 0.15rem 0.45rem;
}

.nukta-house-ad--text {
    padding-top: 1.35rem;
}

.nukta-house-ad--fade {
    opacity: 0;
    transition: opacity 0.18s ease;
}

.nukta-ad-slot--adsense-filled .nukta-house-ad {
    display: none;
}

.nukta-ad-slot--adsense-filled .nukta-ads-slot,
.nukta-ad-slot--adsense-filled [data-plc] {
    display: none;
}

/* Nukta Ads (angaza) embed slots inside AdSense wrappers */
.nukta-ads-slot,
.nukta-ad-slot .nukta-ads-slot {
    width: 100%;
    max-width: 100%;
    min-height: 0;
    margin: 0;
}

.nukta-ads-slot--discover,
.discover-ad-slot .nukta-ads-slot--discover,
.nukta-ad-slot[data-unit="discover-display"] .nukta-ads-slot {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

.nukta-ads-slot--discover.nukta-ad--banner,
.nukta-ads-slot--discover .nukta-ad--banner,
.nukta-ads-slot--discover > a,
.discover-ad-slot .nukta-ad--banner,
.discover-ad-slot .nukta-ads-slot--discover > a {
    width: 100% !important;
    max-width: 100%;
    display: block;
}

.discover-ad-slot .nukta-ad-slot,
.discover-ad-slot .nukta-ads-slot--discover {
    width: 100%;
    max-width: 1100px;
}

@media (max-width: 640px) {
    .nukta-ads-slot--discover .nukta-ad--banner {
        height: 96px !important;
        min-height: 88px !important;
        max-height: 110px !important;
    }
}

.nukta-ad-slot--adsense-filled .nukta-adsense {
    margin: 1.25rem auto 1.5rem;
    min-height: 90px;
}

@media (max-width: 640px) {
    /* Keep a compact horizontal card — full-width stacked creatives eat ~half the viewport */
    .nukta-ad-slot .nukta-house-ad {
        flex-direction: row;
        align-items: center;
        gap: 0.65rem;
        padding: 0.65rem;
        max-height: 96px;
    }

    .nukta-house-ad__img-wrap,
    .nukta-house-ad__img-wrap--discover {
        width: 88px;
        max-width: 88px;
        height: 66px;
        max-height: 66px;
    }

    .nukta-house-ad__title {
        font-size: 0.86rem;
        line-height: 1.3;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .nukta-house-ad__excerpt {
        display: none;
    }

    .nukta-house-ad__badge {
        top: 0.35rem;
        right: 0.35rem;
        font-size: 0.55rem;
        padding: 0.1rem 0.35rem;
    }
}

/* Admin previews reuse house-ad markup */
.admin-ads-modal__preview .nukta-house-ad,
.admin-ad-preview-box .nukta-house-ad {
    max-height: 140px;
}

.admin-ads-modal__preview .nukta-house-ad__img-wrap,
.admin-ad-preview-box .nukta-house-ad__img-wrap,
.admin-ads-modal__preview .nukta-house-ad__img-wrap--discover,
.admin-ad-preview-box .nukta-house-ad__img-wrap--discover {
    max-width: 160px;
    max-height: 96px;
}
