/* ============================================================
   LINK RENGİ
   ============================================================ */
.blog-content a {
    color: #001f53;
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 600;
    transition: color 0.2s ease;
    word-break: break-word;
}
.blog-content a:hover { color: #003d85; text-decoration: none; }

/* ============================================================
   TYPOGRAFİ + CLS ÖNLEME
   ============================================================ */
.blog-content { font-size: 1.05rem; line-height: 1.8; color: #2d3748; }
.blog-content p { margin-bottom: 1.25rem; }
.blog-content h2 { font-size: 1.85rem; font-weight: 700; color: #1a202c; margin-top: 2.5rem; margin-bottom: 1rem; line-height: 1.3; scroll-margin-top: 100px; }
.blog-content h3 { font-size: 1.45rem; font-weight: 700; color: #2d3748; margin-top: 2rem; margin-bottom: 0.8rem; line-height: 1.4; scroll-margin-top: 100px; }
.blog-content h4 { font-size: 1.2rem; font-weight: 600; color: #2d3748; margin-top: 1.5rem; margin-bottom: 0.6rem; }
.blog-content ul, .blog-content ol { padding-left: 1.5rem; margin-bottom: 1.25rem; }
.blog-content li { margin-bottom: 0.5rem; }
.blog-content blockquote {
    border-left: 4px solid #001f53;
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    background: #f7fafc;
    font-style: italic;
    color: #4a5568;
    border-radius: 0 8px 8px 0;
}

/* CLS önleme: featured image aspect-ratio */
.blog-featured-image {
    aspect-ratio: 1200 / 630;
    width: 100%;
    height: auto;
    object-fit: cover;
    background: #f7fafc; /* image yüklenirken placeholder */
}

/* CLS önleme: post meta alanı yer ayırma */
.post-meta {
    min-height: 24px;
    margin-bottom: 1rem;
    font-size: 0.92rem;
}
.post-meta span { display: inline-flex; align-items: center; }

/* ============================================================
   TABLE OF CONTENTS (TOC)
   ============================================================ */
.toc-box {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-left: 4px solid #001f53;
    border-radius: 10px;
    padding: 18px 22px;
    margin: 24px 0 32px;
    box-shadow: 0 2px 8px rgba(0, 31, 83, 0.06);
    position: relative;
    z-index: 10;
    display: block;
    width: 100%;
    height: auto;
}
.toc-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-weight: 700;
    color: #001f53;
    font-size: 1.1rem;
}
.toc-toggle .toc-caret { transition: transform 0.25s ease; font-size: 0.85rem; }
.toc-toggle[aria-expanded="false"] .toc-caret { transform: rotate(-90deg); }
.toc-list {
    list-style: none;
    padding: 0;
    margin: 14px 0 0 0;
    counter-reset: toc-counter;
    max-height: 600px;
    overflow: hidden;
    transition: max-height 0.3s ease, margin-top 0.3s ease, opacity 0.25s ease;
    background: #eff6ff;
}
.toc-list[hidden] { max-height: 0; margin-top: 0; opacity: 0; display: block !important; }
.toc-item { margin: 0; padding: 0; position: relative; }
.toc-item.toc-level-2 { counter-increment: toc-counter; }
.toc-item.toc-level-2 > a::before {
    content: counter(toc-counter) ". ";
    color: #001f53;
    font-weight: 700;
    margin-right: 4px;
}
.toc-item.toc-level-3 { padding-left: 20px; }
.toc-item.toc-level-3 > a::before { content: "— "; color: #94a3b8; }
.toc-item a {
    display: block;
    padding: 7px 10px;
    color: #2d3748;
    text-decoration: none;
    border-radius: 6px;
    transition: background 0.18s ease, color 0.18s ease;
    font-size: 0.97rem;
    line-height: 1.4;
}
.toc-item a:hover { background: rgba(0, 31, 83, 0.08); color: #001f53; }
.toc-item a.active { background: #001f53; color: #fff !important; font-weight: 600; }
.toc-item a.active::before { color: #fff !important; }

/* ============================================================
   TABLO STİLLERİ (CKEditor çıktısı için) — SADELEŞTİRİLDİ
   ============================================================ */

/* CKEditor'un wrapper figure'ı — scroll container olarak çalışacak */
.blog-content figure.table {
    display: block;
    width: 100%;
    max-width: 100%;
    margin: 1.5rem 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    background: #fff;
}

/* JS ile sarılan bare tablolar için aynı görünüm */
.blog-content .table-responsive-wrapper {
    display: block;
    width: 100%;
    max-width: 100%;
    margin: 1.5rem 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* Tablo genel */
.blog-content table {
    width: 100%;
    min-width: 520px; /* çok daralmasın, mobilde scroll çıksın */
    border-collapse: collapse;
    margin: 0;
    background: #fff;
    font-size: 0.95rem;
}
.blog-content figure.table > table,
.blog-content .table-responsive-wrapper > table {
    border: 0; /* dış border zaten wrapper'da */
}

/* Hücreler */
.blog-content table th,
.blog-content table td {
    padding: 12px 16px;
    text-align: left;
    vertical-align: top;
    border: 1px solid #e2e8f0;
    line-height: 1.5;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* Başlık satırı — ilk tr veya thead */
.blog-content table thead th,
.blog-content table thead td,
.blog-content table > tbody > tr:first-child > th,
.blog-content table > tr:first-child > th {
    background: linear-gradient(180deg, #1a202c 0%, #2d3748 100%);
    color: #fff !important;
    font-weight: 600;
    font-size: 0.88rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-color: #2d3748;
}

/* İlk sütun (satır başlıkları) kalın */
.blog-content table tbody td:first-child,
.blog-content table tr td:first-child {
    font-weight: 600;
    color: #1a202c;
}

/* Zebra + hover */
.blog-content table tbody tr:nth-child(even),
.blog-content table > tr:nth-child(even) { background: #f8fafc; }
.blog-content table tbody tr:hover,
.blog-content table > tr:hover { background: #f0fdf4; }

/* Caption */
.blog-content table caption {
    caption-side: top;
    padding: 8px 12px;
    font-weight: 600;
    color: #4a5568;
    text-align: left;
}

/* ============================================================
   RECENT POSTS WIDGET — ÖZEL STİL
   ============================================================ */
.widget-recent {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 22px 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
.widget-recent .widget-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a202c !important;
    margin: 0 0 18px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid #001f53;
    position: relative;
}
.widget-recent .widget-post {
    list-style: none;
    padding: 0;
    margin: 0;
}
.widget-recent .widget-post li {
    border-bottom: 1px solid #edf2f7;
    margin: 0;
    padding: 0;
}
.widget-recent .widget-post li:last-child { border-bottom: none; }
.widget-recent .widget-post li a {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 0;
    color: #2d3748 !important;
    text-decoration: none !important;
    font-weight: 500;
    font-size: 0.97rem;
    line-height: 1.5;
    transition: color 0.2s ease, padding-left 0.2s ease;
}
.widget-recent .widget-post li a i {
    color: #001f53;
    font-size: 1rem;
    margin-top: 4px;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}
.widget-recent .widget-post li a span {
    flex: 1;
}
.widget-recent .widget-post li a:hover {
    color: #001f53 !important;
    padding-left: 4px;
}
.widget-recent .widget-post li a:hover i {
    transform: translateX(3px);
    color: #003d85;
}

/* ============================================================
   WHATSAPP CTA BANNER
   ============================================================ */
.blog-inline-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #f0fdf4;
    border: 1px solid #25D366;
    border-radius: 12px;
    padding: 20px;
    margin: 35px 0;
    gap: 20px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.08);
    transition: transform 0.3s;
}
.blog-inline-cta:hover { transform: translateY(-3px); }
.blog-inline-cta .cta-icon {
    font-size: 36px;
    color: #25D366;
    flex-shrink: 0;
    background: white;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.blog-inline-cta .cta-text { flex-grow: 1; }
.blog-inline-cta .cta-text strong { display: block; font-size: 1.15rem; color: #075e54; margin-bottom: 4px; }
.blog-inline-cta .cta-text span { font-size: 0.95rem; color: #4a4a4a; }
.blog-inline-cta .cta-btn {
    background-color: #25D366;
    color: #fff !important;
    padding: 12px 28px;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.3);
    transition: all 0.2s;
}
.blog-inline-cta .cta-btn:hover { background-color: #128c7e; box-shadow: 0 6px 15px rgba(37, 211, 102, 0.4); }

.blog-inline-cta.cta-dark { background-color: #1a1a1a; border: 1px solid #333; }
.blog-inline-cta.cta-dark .cta-icon { color: #1a1a1a; background: #ffcc00; }
.blog-inline-cta.cta-dark .cta-text strong { color: #ffffff; }
.blog-inline-cta.cta-dark .cta-text span { color: #cccccc; }
.blog-inline-cta.cta-dark .cta-btn { background-color: #ffcc00; color: #000 !important; box-shadow: 0 4px 10px rgba(255, 204, 0, 0.3); }
.blog-inline-cta.cta-dark .cta-btn:hover { background-color: #e6b800; }

/* ============================================================
   GÖRSELLER
   ============================================================ */
.blog-content figure.image { display: table; margin: 1.5rem auto; clear: both; text-align: center; max-width: 100%; }
.blog-content figure.image figcaption { display: table-caption; caption-side: bottom; padding: 8px 0; font-size: 0.88rem; color: #718096; font-style: italic; }
.blog-content img { max-width: 100%; height: auto; vertical-align: middle; border-radius: 8px; }
.blog-content .image-style-side, .blog-content .image-style-align-right { float: right; margin-left: 1.5rem; margin-bottom: 1rem; max-width: 50%; clear: none; }
.blog-content .image-style-align-left { float: left; margin-right: 1.5rem; margin-bottom: 1rem; max-width: 50%; clear: none; }
.blog-content .image-style-align-center { margin-left: auto; margin-right: auto; clear: both; }
.blog-content::after { content: ""; display: table; clear: both; }

/* ============================================================
   PAYLAŞIM KUTUSU
   ============================================================ */
.share-box .social-icons.s1 {
    line-height: 1.5 !important;
    display: flex !important;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.share-box .social-icons a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: 0;
    border-radius: 50%;
    background: #f0f4f8;
    color: #2d3748 !important;
    transition: all 0.25s ease;
    font-size: 1.15rem;
    text-decoration: none !important;
    border: 1px solid #e2e8f0;
}
.share-box .social-icons a i {
    display: inline-block !important;
    width: 1.15em !important;
    height: 1.15em !important;
    padding: 0 !important;
    margin: 0 !important;
    background-color: currentColor !important;
    background-image: none !important;
    color: #2d3748 !important;
    font-size: 1.15rem !important;
    line-height: 1 !important;
    mask-size: contain !important;
    -webkit-mask-size: contain !important;
    mask-repeat: no-repeat !important;
    -webkit-mask-repeat: no-repeat !important;
    mask-position: center !important;
    -webkit-mask-position: center !important;
    vertical-align: middle !important;
}
.share-box .social-icons a:hover {
    background: #001f53;
    color: #fff !important;
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 31, 83, 0.25);
    border-color: #001f53;
}
.share-box .social-icons a:hover i {
    color: #fff !important;
    background-color: #fff !important;
}

/* ============================================================
   SIDEBAR FORM
   ============================================================ */
#sidebar_phone::placeholder { text-align:center; color:#98a6b3; }
#sidebar_phone:not(:placeholder-shown) { text-align:left; }
#sidebar_contact_form .form-control:focus { border-color: #001f53; box-shadow: 0 0 0 3px rgba(0, 31, 83, 0.15); }

/* ============================================================
   STICKY SIDEBAR
   ============================================================ */
@media (min-width: 992px) {
    #stickySidebarForm.is-fixed { position: fixed; top: 96px; z-index: 3; }
    #stickySidebarForm.is-abs   { position: absolute; z-index: 2; }
}
@media (max-width: 991.98px) {
    #stickySidebarForm.is-fixed, #stickySidebarForm.is-abs {
        position: static !important;
        width: auto !important;
        left: auto !important;
        top: auto !important;
    }
}

/* ============================================================
   MOBİL RESPONSIVE
   ============================================================ */
@media (max-width: 991.98px) {
    .blog-content { font-size: 1rem; line-height: 1.75; }
    .blog-content h2 { font-size: 1.55rem; margin-top: 2rem; }
    .blog-content h3 { font-size: 1.25rem; }
    .toc-box {
        padding: 14px 16px;
        margin: 20px 0 24px;
        position: relative !important;
        display: block !important;
        width: 100% !important;
        height: auto !important;
        float: none !important;
        z-index: 10;
        background: #eff6ff !important;
    }
    .toc-list {
        background: #eff6ff !important;
    }
    .toc-item a { font-size: 0.92rem; padding: 6px 8px; }
    .blog-content table { min-width: 480px; }
    .blog-content table th,
    .blog-content table td { padding: 10px 12px; font-size: 0.88rem; }
    .widget-recent { padding: 18px 20px; }

    /* Subheader H1 mobil */
    #subheader h1 {
        font-size: 1.7rem !important;
        line-height: 1.3 !important;
        margin-bottom: 10px !important;
        word-break: break-word;
    }
    #subheader { padding: 80px 0 40px !important; }
    #subheader .crumb { font-size: 0.85rem; }

    /* CLS önleme: meta bilgi alanı için yer ayır */
    .post-meta { min-height: 28px; }
}

@media (max-width: 576px) {
    #subheader h1 {
        font-size: 1.35rem !important;
    }
    #subheader { padding: 70px 0 30px !important; }
    .blog-content h2 { font-size: 1.35rem; }
    .blog-content h3 { font-size: 1.15rem; }
}

@media (max-width: 768px) {
    .blog-inline-cta {
        flex-direction: column;
        text-align: center;
        padding: 22px 18px;
        gap: 14px;
    }
    .blog-inline-cta .cta-text { width: 100%; margin-bottom: 4px; }
    .blog-inline-cta .cta-btn { width: 100%; text-align: center; }
    .blog-content h2 { font-size: 1.4rem; }
    .blog-content h3 { font-size: 1.15rem; }
    .share-box .social-icons a { width: 40px; height: 40px; margin: 0 3px; }
    .post-meta { font-size: 0.88rem; }
    .blog-featured-image { border-radius: 8px !important; }
}

@media (max-width: 480px) {
    .blog-content { font-size: 0.98rem; }
    .toc-box { padding: 12px 14px; }
    .blog-inline-cta { margin: 25px 0; padding: 18px 14px; }
    .blog-inline-cta .cta-icon { width: 50px; height: 50px; font-size: 28px; }
    .blog-inline-cta .cta-text strong { font-size: 1.05rem; }
}

/* Azaltılmış hareket tercihi */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
