/* =======================================================
   Custom CSS cho Trang Chi Tiết Tin Tức (single-post.php)
   Lọc lại từ bộ style do người dùng cung cấp
========================================================= */

/* Hỗ trợ biến màu nếu theme chưa load kịp */
:root {
  --clr-main: #117552;
}

/* Container chính của nội dung */
.sfm-single-news {
  max-width: 100%;
  padding: 0px;
  margin: 0 auto;
  font-family: 'Montserrat', sans-serif;
  color: #333333;
}

.sfm-single-news .wrapper-content {
  --width: 1190px;
  max-width: min(100% - 30px, var(--width));
  margin: 0 auto;
}

@media (max-width: 575px) {
    .sfm-single-news .wrapper-content {
        max-width: 100%;
        padding: 0 15px;
    }
}

.news-template.pd-40 {
    padding: 40px 0;
}

/* Breadcrumbs đồng bộ với trang tin tức */
.sfm-breadcrumb-wrapper {
    height: 46.8px;
    background-color: #EEEEEE;
    display: flex;
    align-items: center;
    width: 100%;
    margin-top: 0px;
    margin-bottom: 0px;
}

.sfm-breadcrumb-inner {
    width: 100%;
    max-width: 1190px;
    margin: 0 auto;
    padding: 0 15px;
}

@media(min-width: 768px) {
    .sfm-breadcrumb-inner {
        padding: 0;
    }
}

/* Tablet (768px - 1024px): Margin left cho breadcrumbs */
@media (min-width: 768px) and (max-width: 1024px) {
    .sfm-breadcrumb-inner {
        margin-left: 10px;
        padding-left: 10px;
    }
}

.sfm-breadcrumbs {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.sfm-breadcrumbs .sfm-breadcrumbs-item,
.sfm-breadcrumbs .sfm-breadcrumbs-separator {
    display: flex;
    align-items: center;
    margin-right: 10px;
}

.sfm-breadcrumbs .sfm-breadcrumbs-item {
    padding: 0;
    font-family: "Montserrat", sans-serif;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    color: #333333;
}

.sfm-breadcrumbs .sfm-breadcrumbs-item a {
    color: #333333;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.3s ease;
}

.sfm-breadcrumbs .sfm-breadcrumbs-item:hover a {
    color: #117552;
}

.sfm-breadcrumbs .sfm-breadcrumbs-separator {
    font-family: "Montserrat", sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: #333333;
}

.sfm-breadcrumbs .sfm-breadcrumbs-icon {
    display: inline-flex;
    align-items: center;
    margin-right: 10px;
}

.sfm-breadcrumbs .sfm-breadcrumbs-icon svg {
    width: 14px;
    height: 14px;
    fill: #333333;
    transition: fill 0.3s ease;
}

.sfm-breadcrumbs .sfm-breadcrumbs-item:hover .sfm-breadcrumbs-icon svg {
    fill: #117552;
}

@media (max-width: 575px) {
    .sfm-breadcrumb-inner {
        padding: 0 15px;
    }
    .sfm-breadcrumbs .sfm-breadcrumbs-item {
        font-size: 10px;
    }
    .sfm-breadcrumbs .sfm-breadcrumbs-icon svg {
        width: 12px;
        height: 12px;
    }
}

/* Layout Flex (Dự phòng cho Bootstrap) */
.sfm-news-row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -15px;
    margin-left: -15px;
}
.sfm-news-col-9 {
    flex: 0 0 100%;
    max-width: 100%;
    padding: 0 15px;
}
.sfm-news-col-3 {
    flex: 0 0 100%;
    max-width: 100%;
    padding: 0 15px;
    margin-top: 30px;
}
@media (min-width: 992px) {
    .sfm-news-col-9 {
        flex: 0 0 75%;
        max-width: 75%;
    }
    .sfm-news-col-3 {
        flex: 0 0 25%;
        max-width: 25%;
        margin-top: 0;
    }
}

/* Tiêu đề & Slogan */
.section-heading.detail {
  margin-bottom: 30px;
  text-align: left;
}
.section-heading.detail .title {
  color: #421E13;
  text-transform: uppercase;
  font-size: clamp(24px, 3vw, 32px); /* Tự điều chỉnh mb */
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  margin-bottom: 0;
  line-height: 1.3;
}

.time-main {
  color: #999999;
}
.time-main i {
  vertical-align: top;
  margin: 3px 7px 0px 0px;
}
.time-main span {
  vertical-align: top;
  display: inline-block;
  font-size: 14px;
}

/* Box Share chung & Bài viết khác */
.share {
  padding: 17px 15px 10px 15px;
  line-height: normal;
  background: rgba(128, 128, 128, 0.15);
  margin-top: 25px;
  border-radius: 5px;
}
.share b {
  display: block;
  margin-bottom: 10px;
  font-weight: 700;
}

/* Cột phải Sidebar: Bài viết khác */
.othernews b {
  margin-bottom: 15px;
}
a.new-lq {
  display: flex;
  align-items: flex-start;
  margin-top: 15px;
  margin-bottom: 15px;
  text-decoration: none;
}
a.new-lq .images {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  border-radius: 5px;
  overflow: hidden;
}
a.new-lq .images img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
a.new-lq .info {
  width: calc(100% - 75px);
  margin-left: 15px;
  color: #333;
  font-size: 14px;
  line-height: 1.5;
  --line-clamp: 2;
  overflow: hidden;
  display: -webkit-box;
  text-overflow: ellipsis;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--line-clamp);
  transition: color 0.3s ease;
}
a.new-lq:hover .info {
    color: var(--clr-main);
}

/* Định dạng hình ảnh trong bài viết Content để tự responsive (Fix lỗi width cứng từ Ckeditor) */
.content-main img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: 5px;
    margin-bottom: 15px;
}

.content-main {
    font-size: 15px;
    line-height: 1.7;
    color: #444;
}