/* ==========================================================================
   POST STYLE (TÁCH RIÊNG CHO CHI-TIẾT-BÀI-VIẾT.PHP)
   ================================================================---------- */

.site-main-layout {
    max-width: 1200px;
    margin: 35px auto 60px auto;
    padding: 0 15px;
    display: grid;
    grid-template-columns: 2.3fr 1.15fr;
    gap: 25px;
}

.article-main-card {
    background: #ffffff;
    padding: 35px;
    border-radius: 14px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.02);
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.article-breadcrumb {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.article-breadcrumb a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s;
}
.article-breadcrumb a:hover {
    color: #eb1838;
}

.article-title { 
    font-size: 30px; 
    font-weight: 500; 
    color: #0f172a; 
    margin-bottom: 12px; 
    line-height: 1.3; 
    word-break: break-word; 
}

.article-meta { 
    font-size: 13px; 
    color: #64748b; 
    margin-bottom: 22px; 
    display: flex; 
    gap: 18px; 
    border-bottom: 1px solid #f1f5f9; 
    padding-bottom: 15px; 
    font-weight: 500; 
}

.article-content { 
    font-size: 16px; 
    color: #1e293b; 
    word-break: break-word; 
    overflow-wrap: break-word; 
}
.article-content img { 
    max-width: 100% !important; 
    height: auto !important; 
    border-radius: 8px; 
    margin: 20px 0; 
    display: block; 
}
.article-content p { margin-bottom: 18px; }
.article-content h2 { font-size: 22px; color: #eb1838; margin: 25px 0 12px; font-weight: 500; }
.article-content h3 { font-size: 18px; color: #0f172a; margin: 20px 0 10px; font-weight: 500; }

/* Danh sách thụt lề chuẩn */
.article-content ul, 
.article-content ol {
    padding-left: 35px !important;
    margin-bottom: 15px !important;
}
.article-content li {
    margin-bottom: 8px !important;
}

/* Khung cuộn ngang bảng */
.table-responsive-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 20px 0;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
    background: #fff;
}
.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    font-size: 14px;
    background: #fff;
}
.article-content table th {
    background: #eb1838;
    color: #fff;
    font-weight: 500;
    text-transform: uppercase;
    padding: 12px 16px;
    text-align: left;
    letter-spacing: 0.5px;
}
.article-content table td {
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    vertical-align: middle;
}
.article-content table tr:nth-child(even) { background-color: #f8fafc; }
.article-content table tr:hover { background-color: #f1f5f9; }
.article-content table td:last-child, 
.article-content table th:last-child {
    text-align: right;
    font-weight: 500;
    color: #eb1838;
    white-space: nowrap;
}

/* Cố định cột bên phải (Sidebar bài viết liên quan) khi cuộn chuột */
aside {
    position: sticky;
    top: 90px; /* Khoảng cách cách mép trên trình duyệt khi trượt tới */
    align-self: flex-start; /* Giúp sidebar không bị kéo giãn theo chiều cao của phần nội dung chính */
}

/* Sidebar Bài viết cùng chủ đề */
.sidebar-widget {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 22px;
    margin-bottom: 25px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.02);
}
.sidebar-widget-title {
    font-size: 16px;
    font-weight: 500;
    color: #0f172a;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f1f5f9;
    display: flex;
    align-items: center;
    gap: 8px;
}
.sidebar-widget-title i { color: #eb1838; }

.related-post-item {
    display: flex;
    gap: 14px;
    margin-bottom: 14px;
    align-items: center;
    text-decoration: none;
    transition: 0.2s;
}
.related-post-item:last-child { margin-bottom: 0; }
.related-post-thumb {
    width: 85px;
    height: 62px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
    background: #f8fafc;
}
.related-post-info h5 {
    font-size: 13.5px;
    font-weight: 500;
    color: #0f172a;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 4px;
}
.related-post-item:hover .related-post-info h5 { color: #eb1838; }
.related-post-date { font-size: 11px; color: #94a3b8; }

/* Responsive riêng cho bài viết */
@media(max-width: 992px) {
    .site-main-layout { grid-template-columns: 1fr; padding: 0 10px; margin: 15px auto; }
    .article-main-card { padding: 20px; border-radius: 12px; }
    .article-title { font-size: 24px; }
}

.article-content strong, 
.article-content b {
    font-weight: 600 !important;
}

/* Định dạng khung trích dẫn (Blockquote) nổi bật trong bài viết */
.article-content blockquote {
    margin: 20px 0;
    padding: 15px 20px;
    background: #f8fafc;
    border-left: 4px solid #eb1838;
    color: #334155;
    font-style: italic;
    border-radius: 0 8px 8px 0;
}

.article-content blockquote p {
    margin: 0;
    line-height: 1.6;
}