/* === SINGLE POST TEMPLATE CSS === */

/* Tema page-header gizle (fallback — PHP ile de kaldırılıyor) */
body.single-post #page-header,
body.single-post .wtbx-page-header { display: none !important; }

/* Header altına girmemesi */
@media (min-width: 992px) {
    body.single-post #page-wrap { padding-top: 160px !important; }
}
@media (max-width: 991px) {
    body.single-post #page-wrap { padding-top: 80px !important; }
}

/* Overflow fix — sticky için */
body.single-post #wrapper,
body.single-post #main,
body.single-post #page-wrap,
body.single-post article.post-entry,
body.single-post #container.row-inner,
.akf-single-layout,
.wtbx-content-body {
    overflow: visible !important;
}

/* Kategori badge */
.akf-post-cat-badge {
    display: inline-block;
    background: rgba(255,255,255,0.2);
    color: #fff !important;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}
.akf-post-cat-badge:hover {
    background: rgba(255,255,255,0.3);
    color: #fff !important;
}

/* Grid layout */
.akf-single-layout {
    display: grid !important;
    grid-template-columns: 1fr 280px !important;
    margin-top: 25px !important;
    gap: 30px !important;
    align-items: start !important;
}
.akf-single-content { min-width: 0; }

/* Sidebar: Sticky + Scroll */
.akf-post-sidebar {
    position: sticky !important;
    top: 90px !important;
    max-height: calc(100vh - 110px);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    scrollbar-width: thin;
    scrollbar-color: rgba(0,0,0,0.15) transparent;
}
.akf-post-sidebar::-webkit-scrollbar { width: 4px; }
.akf-post-sidebar::-webkit-scrollbar-track { background: transparent; }
.akf-post-sidebar::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.15); border-radius: 4px; }
.akf-post-sidebar:hover::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.25); }

/* İçerik tipografi */
.akf-single-content .entry-content { font-size: 15px; line-height: 1.75; color: #333; margin: 0 !important; }
.akf-single-content .entry-content h2 { font-size: 20px; font-weight: 700; color: #0d2f5e; margin: 30px 0 12px; padding-bottom: 8px; border-bottom: 2px solid #e2e8f0; }
.akf-single-content .entry-content h3 { font-size: 17px; font-weight: 600; color: #1a365d; margin: 22px 0 8px; }
.akf-single-content .entry-content p { margin-bottom: 14px; }
.akf-single-content .entry-content img { border-radius: 8px; max-width: 100%; height: auto; }
.akf-single-content .entry-content ul,
.akf-single-content .entry-content ol { margin: 12px 0; padding-right: 25px; }
.akf-single-content .entry-content li { margin-bottom: 6px; font-size: 15px; }

/* === FAQ Accordion === */
.akf-faq-item {
  border-bottom: 1px solid #e0e6ed;
}
.akf-faq-item:last-child {
  border-bottom: none;
}
.akf-faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
  cursor: pointer;
  font-size: 17px;
  font-weight: 600;
  color: #1a1a2e;
  transition: color 0.2s;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}
.akf-faq-question:hover {
  color: #1a5276;
}
.akf-faq-question::after {
  content: '+';
  font-size: 24px;
  font-weight: 300;
  color: #1a5276;
  transition: transform 0.3s;
  flex-shrink: 0;
  margin-right: 16px;
}
.akf-faq-item.active .akf-faq-question::after {
  content: '−';
}
.akf-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
  padding: 0;
  color: #4a4a6a;
  font-size: 15px;
  line-height: 1.7;
}
.akf-faq-item.active .akf-faq-answer {
  max-height: 500px;
  padding: 0 0 18px;
}
@media (max-width: 768px) {
  .akf-faq-question { font-size: 15px; padding: 14px 0; }
  .akf-faq-answer { font-size: 14px; }
}

/* Scape navigasyonu gizle */
.wtbx-navigation-wrapper { display: none !important; }

/* Bölüm başlığı */
.akf-section-label {
    font-size: 11px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

/* === İlgili Yazılar === */
.akf-related-section {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid #e2e8f0;
}
.akf-related-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 15px;
}
.akf-related-card {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    text-decoration: none !important;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.3s;
}
.akf-related-card:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,0.08);
}
.akf-related-img {
    width: 100%;
    height: 0;
    padding-bottom: 52%;
    background-size: cover;
    background-position: center top;
}
.akf-related-body {
    padding: 12px 14px;
    flex: 1;
}
.akf-related-title {
    font-size: 15px;
    font-weight: 700;
    color: #0d2f5e;
    line-height: 1.45;
}
.akf-related-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    border-top: 1px solid #f0f4f8;
    font-size: 11px;
    color: #9ca3af;
}
.akf-related-footer-author {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #0d2f5e;
    font-weight: 600;
}
.akf-related-footer-avatar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
}

/* === Diğer Konuları Keşfedin === */
.akf-explore-section {
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid #e2e8f0;
}
.akf-explore-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* Responsive */
@media (max-width: 768px) {
    /* İlgili yazılar + kategoriler: mobil padding */
    .akf-related-section,
    .akf-explore-section {
        margin-right: 15px;
        margin-left: 15px;
    }
    .akf-related-section {
        margin-top: 20px;
        padding-top: 20px;
    }
    .akf-related-grid {
        display: flex !important;
        gap: 10px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        margin: 0;
        padding: 0;
    }
    .akf-related-grid::-webkit-scrollbar { display: none; }
    .akf-related-card {
        min-width: 200px;
        flex-shrink: 0;
    }
    .akf-related-img {
        padding-bottom: 50%;
    }
    .akf-related-title {
        font-size: 12px;
    }
    .akf-related-footer {
        font-size: 10px;
        padding: 6px 12px;
    }
    /* Kategoriler: yatay scroll */
    .akf-explore-section {
        margin-top: 15px;
        padding-top: 15px;
    }
    .akf-explore-pills {
        flex-wrap: nowrap !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        margin: 0;
        padding: 0;
    }
    .akf-explore-pills::-webkit-scrollbar { display: none; }
    .akf-explore-pills .akf-pill {
        white-space: nowrap;
        flex-shrink: 0;
    }
}

/* Önceki / Sonraki Navigasyon */
.akf-post-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    margin-top: 40px;
    overflow: hidden;
}
.akf-post-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 20px;
    text-decoration: none !important;
    transition: background 0.2s;
}
.akf-post-nav-item:hover { background: #eef2f7; }
.akf-post-nav-next {
    border-right: 1px solid #e2e8f0;
    text-align: left;
}
.akf-post-nav-next .akf-post-nav-text { order: 1 !important; }
.akf-post-nav-next img { order: 2 !important; }
.akf-post-nav-prev:only-child { grid-column: 1 / -1; }
.akf-post-nav-next:only-child { grid-column: 1 / -1; border-right: none; }
.akf-post-nav-item img {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 8px;
    object-fit: cover;
}
.akf-post-nav-text { flex: 1; min-width: 0; }
.akf-post-nav-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #3a6ea5;
    margin-bottom: 3px;
}
.akf-post-nav-title {
    display: -webkit-box;
    font-size: 14px;
    font-weight: 600;
    color: #0d2f5e;
    line-height: 1.4;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive */
@media (max-width: 991px) {
    .akf-single-layout { grid-template-columns: 1fr 250px !important; gap: 20px !important; }
}
@media (max-width: 768px) {
    /* Layout: tek sütun */
    .akf-single-layout {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }

    /* Hero */
    .akf-cat-hero {
        margin-right: 15px !important;
        margin-left: 15px !important;
    }

    /* Container */
    #container.row-inner {
        padding-right: 0 !important;
        padding-left: 0 !important;
    }
    .akf-single-layout {
        padding-right: 15px !important;
        padding-left: 15px !important;
    }

    /* Sidebar */
    .akf-post-sidebar {
        position: static !important;
        max-height: none;
        overflow-y: visible;
        margin-top: 0 !important;
    }
    .akf-post-sidebar .akf-sidebar-doctor { display: none !important; }
    .akf-post-sidebar .akf-sidebar-cta { margin: 0 !important; }

    /* İçerik tipografi */
    .akf-single-content .entry-content { font-size: 14px; padding: 0 !important; }
    .akf-single-content .entry-content h2 { font-size: 17px; }
    .akf-single-content .entry-content h3 { font-size: 15px; }

    /* Sidebar mobilde padding sıfır */
    .akf-post-sidebar { margin-right: 0 !important; margin-left: 0 !important; padding: 0 !important; }

    /* Navigasyon mobil */
    .akf-post-nav { grid-template-columns: 1fr; margin-right: 15px; margin-left: 15px; }
    .akf-post-nav-item img { display: none; }
    .akf-post-nav-next { border-right: none; border-top: 1px solid #e2e8f0; flex-direction: row; text-align: right; }
    .akf-post-nav-item { padding: 14px 16px; }
    .akf-post-nav-label { font-size: 10px; }
    .akf-post-nav-title { font-size: 13px; -webkit-line-clamp: 1; }
}
