/* ==========================================================================
   REKLAM

   Kaynak: "YB Reklam Gösterim ve Tıklama Sistemi" snippet'inin wp_head'e
   gömdüğü <style> bloğu — 7 KB, reklam olmayan sayfalar dahil HER
   sayfanın <head>'ine yazılıyordu. Kurallar birebir aynı.
   ========================================================================== */
/* Reklam sistemi genel kutu */
.yb-reklam-box {
    background: transparent;
    overflow: hidden;
}

/* Sağ sütun / dikey reklam alanları */
.yb-ad-side-box {
    width: 100% !important;
    max-width: 300px !important;
    height: 520px !important;
    min-height: 520px !important;
    margin: 0 auto 22px !important;
    padding: 0 !important;
    border-radius: 18px !important;
    overflow: hidden !important;
    background: transparent !important;
    box-shadow: 0 10px 26px rgba(15, 23, 42, .10) !important;
    display: block !important;
}

.yb-ad-side-box .yb-ad-link {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 18px !important;
    overflow: hidden !important;
}

.yb-ad-side-box img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 520px !important;
    object-fit: cover !important;
    object-position: center center !important;
    border-radius: 18px !important;
    margin: 0 !important;
    padding: 0 !important;
}

.yb-ad-side-box .yb-ad-video {
    position: relative !important;
    width: 100% !important;
    height: 520px !important;
    min-height: 520px !important;
    overflow: hidden !important;
    border-radius: 18px !important;
    background: #000 !important;
}

.yb-ad-side-box .yb-ad-video iframe,
.yb-ad-side-box .yb-ad-video embed,
.yb-ad-side-box .yb-ad-video object {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 520px !important;
    border: 0 !important;
    border-radius: 18px !important;
}

/* Piyasa Forum eski sağ sütun reklam kutusu ile çakışmayı sıfırlar */
.yb-home-sidebar > .yb-ad-box:has(.yb-ad-side-box),
.yb-home-sidebar .yb-side-box:has(.yb-ad-side-box) {
    padding: 0 !important;
    background: transparent !important;
    min-height: auto !important;
    box-shadow: none !important;
    border: 0 !important;
    display: block !important;
}

.yb-ad-empty {
    width: 100%;
    max-width: 300px;
    min-height: 420px;
    margin: 0 auto 22px;
    border: 1px dashed #cbd5e1;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 14px;
    background: #f8fafc;
}

/* Akış içi sponsorlu kart */
.yb-sponsored-post {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    padding: 22px;
    margin: 0 0 24px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .07);
    overflow: hidden;
    text-align: left !important;
}

.yb-sponsored-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    text-align: left !important;
    justify-content: flex-start !important;
}

.yb-sponsored-avatar {
    width: 48px;
    height: 48px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex: 0 0 auto;
    background: #1d6b56;
    color: #fff;
    font-weight: 950;
    text-decoration: none !important;
}

.yb-sponsored-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.yb-sponsored-info {
    min-width: 0;
    flex: 1;
    text-align: left !important;
}

.yb-sponsored-name {
    display: inline-flex;
    color: #102033 !important;
    font-size: 16px;
    font-weight: 950;
    text-decoration: none !important;
    line-height: 1.2;
    text-align: left !important;
}

.yb-sponsored-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
    color: #64748b;
    font-size: 13px;
    font-weight: 700;
}

.yb-sponsored-meta span:not(:last-child)::after {
    content: "•";
    margin-left: 6px;
    color: #cbd5e1;
}

.yb-sponsored-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff7d6;
    color: #7c5a00;
    border: 1px solid #ffcf4a;
    border-radius: 999px;
    padding: 7px 11px;
    font-size: 12px;
    font-weight: 950;
    white-space: nowrap;
    margin-left: auto !important;
}

.yb-sponsored-title {
    margin: 0 0 10px !important;
    color: #102033 !important;
    font-size: 23px !important;
    line-height: 1.22 !important;
    letter-spacing: -0.02em;
    text-align: left !important;
    width: 100%;
}

.yb-sponsored-title a {
    color: #102033 !important;
    text-decoration: none !important;
    text-align: left !important;
}

.yb-sponsored-text {
    color: #475569;
    line-height: 1.65;
    font-size: 15px;
    margin-bottom: 16px;
    text-align: left !important;
}

.yb-sponsored-media {
    margin: 14px 0 18px;
    border-radius: 18px;
    overflow: hidden;
    background: #f1f5f9;
}

.yb-sponsored-media img {
    width: 100%;
    height: auto;
    display: block;
}

.yb-sponsored-media .yb-ad-video {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #000;
}

.yb-sponsored-media .yb-ad-video iframe,
.yb-sponsored-media .yb-ad-video embed,
.yb-sponsored-media .yb-ad-video object {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    max-height: none !important;
    border: 0 !important;
}

.yb-sponsored-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.yb-sponsored-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #102033;
    color: #fff !important;
    text-decoration: none !important;
    border-radius: 999px;
    padding: 11px 16px;
    font-size: 14px;
    font-weight: 950;
}

.yb-sponsored-btn-light {
    background: #f1f5f9;
    color: #102033 !important;
}

.yenikent-ana-akis .yb-sponsored-post,
.yb-home-left .yb-sponsored-post,
.yb-akis-page-layout .yb-sponsored-post {
    text-align: left !important;
}

.yenikent-ana-akis .yb-sponsored-post h1,
.yenikent-ana-akis .yb-sponsored-post h2,
.yenikent-ana-akis .yb-sponsored-post h3,
.yenikent-ana-akis .yb-sponsored-post p,
.yenikent-ana-akis .yb-sponsored-post div,
.yenikent-ana-akis .yb-sponsored-post a {
    text-align: left;
}

@media(max-width: 640px) {
    .yb-ad-side-box {
        max-width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
    }

    .yb-ad-side-box .yb-ad-link,
    .yb-ad-side-box img {
        height: auto !important;
        min-height: 0 !important;
        object-fit: contain !important;
    }

    .yb-sponsored-post {
        padding: 18px;
        border-radius: 18px;
    }

    .yb-sponsored-head {
        align-items: flex-start;
    }

    .yb-sponsored-badge {
        font-size: 11px;
        padding: 6px 9px;
    }

    .yb-sponsored-title {
        font-size: 20px !important;
    }

    .yb-sponsored-actions a {
        width: 100%;
    }
}

/* --------------------------------------------------------------------------
   GENİŞ BANT REKLAM

   Sektör sayfasının içerik arası, sayfa genişliğinde bir alan. Dikey
   300x520 kutu oraya konunca hem yer boşa gidiyor hem de sayfanın
   akışını kesiyordu. Bant, kapsayıcısının genişliğini alıyor; görsel
   kendi oranını koruyor.
   -------------------------------------------------------------------------- */

.yb-ad-wide {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto 22px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 26px rgba( 15, 23, 42, .10 );
    background: #f8fafc;
}

.yb-ad-wide .yb-ad-link,
.yb-ad-wide .yb-ad-link img {
    display: block;
    width: 100%;
    height: auto;
    margin: 0;
}

.yb-ad-wide .yb-ad-video {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.yb-ad-wide .yb-ad-video iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* HERO reklamı — kutu ölçüsünü görselin kendi oranından alır. */

.yb-ad-hero {
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    line-height: 0;
}

.yb-ad-hero .yb-ad-link,
.yb-ad-hero img {
    display: block;
    width: 100%;
    height: auto;
    margin: 0;
    border-radius: 16px;
}

/* Mobil sürümü olan reklamlarda <picture> araya giriyor. */

.yb-ad-hero picture,
.yb-ad-wide picture,
.yb-ad-side-box picture {
    display: block;
    width: 100%;
    height: 100%;
}
