/* ========================================================
   SINGLE POST PAGE — FORZA THEME
   ======================================================== */
.single-post-page { background: #f8faff; }

/* Breadcrumb */
.single-breadcrumb {
    padding: 14px 0;
    background: #fff;
    border-bottom: 1px solid #e8edf8;
    font-size: 13px;
    color: #94a3b8;
}
.single-breadcrumb a { color: #6366f1; text-decoration: none; }
.single-breadcrumb i { margin: 0 8px; font-size: 10px; }

/* Header */
.single-header { padding: 48px 0 32px; background: #fff; }
.single-header-inner { max-width: 780px; }
.single-title {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 800;
    color: #0f172a;
    line-height: 1.3;
    margin: 16px 0 24px;
}
.single-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}
.author-info { display: flex; align-items: center; gap: 12px; }
.author-info img { border-radius: 50%; }
.author-name { display: block; font-weight: 600; font-size: 14px; color: #0f172a; }
.post-date { font-size: 13px; color: #64748b; }
.single-meta-right { font-size: 13px; color: #64748b; }
.single-meta-right i { margin-right: 4px; }

/* Hero image */
.single-hero-img { padding: 0 0 32px; background: #fff; }

/* Layout */
.single-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 32px;
    padding-top: 40px;
    padding-bottom: 80px;
    align-items: start;
}

/* Content */
.single-content { background: #fff; border-radius: 20px; padding: 40px; border: 1px solid #e8edf8; }
.post-body { line-height: 1.85; color: #334155; font-size: 16px; }
.post-body h2, .post-body h3 { color: #0f172a; font-weight: 700; margin: 32px 0 16px; }
.post-body p { margin-bottom: 20px; }

/* Images & Alignment */
.post-body img { max-width: 100%; border-radius: 12px; margin: 16px 0; height: auto; }
.post-body .aligncenter { display: block; margin-left: auto; margin-right: auto; }
.post-body .alignleft { float: left; margin-right: 24px; margin-bottom: 16px; }
.post-body .alignright { float: right; margin-left: 24px; margin-bottom: 16px; }

/* Image Captions */
.post-body figure,
.post-body .wp-caption { 
    margin: 24px 0; 
    max-width: 100%; 
}
.post-body figure img,
.post-body .wp-caption img { 
    margin: 0 auto; 
    display: block; 
}
.post-body figcaption,
.post-body .wp-caption-text {
    text-align: center;
    font-size: 14.5px;
    font-style: italic;
    color: #64748b;
    margin-top: 10px;
    margin-bottom: 0;
    line-height: 1.6;
}

.post-body a { color: #6366f1; }
.post-body ul, .post-body ol { padding-left: 24px; margin-bottom: 20px; }
.post-body li { margin-bottom: 8px; }
.post-body blockquote {
    border-left: 4px solid #6366f1;
    padding: 16px 24px;
    background: #f0f4ff;
    border-radius: 0 12px 12px 0;
    margin: 24px 0;
    font-style: italic;
    color: #475569;
}

/* Tags */
.post-tags { margin-top: 32px; padding-top: 24px; border-top: 1px solid #e8edf8; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.post-tags span { font-weight: 600; color: #475569; font-size: 14px; }
.post-tag {
    padding: 5px 14px;
    background: #f0f4ff;
    color: #6366f1;
    border-radius: 50px;
    font-size: 13px;
    text-decoration: none;
    border: 1px solid #e0e7ff;
    transition: all 0.2s;
}
.post-tag:hover { background: #6366f1; color: #fff; }

/* Post Nav */
.post-nav {
    display: flex;
    gap: 16px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid #e8edf8;
}
.post-nav-btn {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: #f8faff;
    border: 1px solid #e8edf8;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
}
.post-nav-next { justify-content: flex-end; text-align: right; }
.post-nav-btn:hover { border-color: #6366f1; background: #f0f4ff; }
.post-nav-btn span { display: block; font-size: 12px; color: #94a3b8; margin-bottom: 4px; }
.post-nav-btn strong { font-size: 14px; color: #0f172a; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post-nav-btn i { color: #6366f1; flex-shrink: 0; }

/* Sidebar */
.single-sidebar { position: sticky; top: 80px; display: flex; flex-direction: column; gap: 20px; }
.sidebar-box {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    border: 1px solid #e8edf8;
}
.sidebar-title { font-size: 15px; font-weight: 700; color: #0f172a; margin: 0 0 16px; }

/* Related Posts */
.related-post-item {
    display: flex;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #f1f5f9;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s;
}
.related-post-item:last-child { border-bottom: none; }
.related-post-item:hover { opacity: 0.8; }
.related-thumb { width: 72px; height: 56px; border-radius: 8px; overflow: hidden; flex-shrink: 0; }
.related-thumb img { width: 100%; height: 100%; object-fit: cover; }
.related-info h5 { font-size: 13px; font-weight: 600; color: #0f172a; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin: 0 0 4px; }
.related-info span { font-size: 12px; color: #94a3b8; }

/* Sidebar categories */
.sidebar-cats { list-style: none; padding: 0; margin: 0; }
.sidebar-cats li { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; border-bottom: 1px solid #f1f5f9; font-size: 14px; }
.sidebar-cats li:last-child { border-bottom: none; }
.sidebar-cats a { color: #475569; text-decoration: none; transition: color 0.2s; }
.sidebar-cats a:hover { color: #6366f1; }
.sidebar-cats a i { margin-right: 6px; color: #a5b4fc; }
.sidebar-cats span { background: #f1f5f9; color: #64748b; font-size: 12px; padding: 2px 8px; border-radius: 20px; }

@media (max-width: 900px) {
    .single-layout { grid-template-columns: 1fr; }
    .single-sidebar { position: static; }
}

/* ── Table of Contents (Mục lục) ── */
.single-toc-container {
    max-width: 800px;
    margin: 0 auto;
}
.forza-toc-container {
    margin: 0;
    clear: both;
}
.forza-toc {
    background: #f8faff;
    border: 1px solid #c7d2fe;
    padding: 24px 32px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.08);
    font-family: 'Inter', sans-serif;
}
.forza-toc-header {
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #e0e7ff;
    padding-bottom: 12px;
}
.forza-toc-header i {
    color: #6366f1;
}
.forza-toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: toc-main;
}
.forza-toc-list > li {
    margin-bottom: 12px;
    position: relative;
    line-height: 1.6;
}
.forza-toc-list > li:last-child {
    margin-bottom: 0;
}
.forza-toc-list > li > a {
    font-size: 15px;
    color: #334155;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}
.forza-toc-list > li > a:hover {
    color: #6366f1;
}
.forza-toc-list > li::before {
    counter-increment: toc-main;
    content: counter(toc-main) ". ";
    color: #6366f1;
    font-size: 15px;
    font-weight: 700;
    margin-right: 6px;
}
.forza-toc-list > li > ul {
    list-style: none;
    padding-left: 24px;
    margin-top: 10px;
    margin-bottom: 10px;
    counter-reset: toc-sub;
}
.forza-toc-list > li > ul > li {
    margin-bottom: 8px;
    position: relative;
    line-height: 1.6;
}
.forza-toc-list > li > ul > li:last-child {
    margin-bottom: 0;
}
.forza-toc-list > li > ul > li > a {
    font-size: 14px;
    color: #475569;
    font-weight: 400;
    text-decoration: none;
    transition: color 0.2s;
}
.forza-toc-list > li > ul > li > a:hover {
    color: #6366f1;
}
.forza-toc-list > li > ul > li::before {
    counter-increment: toc-sub;
    content: counter(toc-main) "." counter(toc-sub) " ";
    color: #94a3b8;
    font-size: 14px;
    font-weight: 500;
    margin-right: 6px;
}
