a.menu-dropdown-button {
  display: block;
  width: 40px;
  text-align: center;
  padding: 5px;
  border: 1px solid var(--color-main);
  cursor: pointer;
}
a.menu-dropdown-button svg {
  fill: var(--color-main);
}
.meta-toc-fixed {
  display: none;
  position: fixed;
  left: 5px;
  top: 80px;
  z-index: 111;
}
.meta-toc-fixed.fixed {
  display: block;
}

.meta-toc-fixed .wrap-toc {
  display: none;
  max-height: 410px;
}
.meta-toc-fixed.fixed .toc-head .bi-caret-down-fill {
  display: none;
}
.meta-toc-fixed.fixed .toc-list {
  max-height: 350px;
  margin-top: 10px;
  padding-left: 15px;
}
.meta-toc-fixed.fixed .toc-list > li > a::before {
  left: -15px;
}

.wrap-toc {
  display: block;
  padding: 10px;
  background-color: #ffffff;
  width: 100%;
  margin-top: 2px;
  border: 2px solid var(--color-main);
  font-size: 13px;
  margin-bottom: 10px;
}
.wrap-toc .toc-head svg {
  fill: var(--color-main);
  margin-right: 10px;
}
.wrap-toc .toc-head {
  position: relative;
  display: flex;
  align-items: center;
  font-size: 20px;
  font-weight: 600;
  color: var(--color-main);
  line-height: 1;
  cursor: pointer;
}

.meta-toc.fixed .wrap-toc {
  width: 350px;
  display: none;
}
.toc-list {
  margin-top: 20px;
  max-height: 500px;
  overflow-y: auto;
}
.toc-list li {
  list-style: none;
}
.toc-list li a {
  display: block;
  padding: 4px 0px;
  cursor: pointer;
  color: var(--color-main) !important;
}
.toc-list li a:hover,
.toc-list li a.active {
  color: var(--color-submain) !important;
}

.toc-list > li > a {
  position: relative;
  font-size: 16px;
  font-weight: 500;
}
.toc-list > li > a::before {
  content: "\25be";
  display: block;
  position: absolute;
  width: 20px;
  height: 20px;
  left: -20px;
  top: 3px;
}

.toc-list > li > a:only-child::before {
  content: "";
}

.toc-list ul {
  padding-left: 20px;
}
.toc-list > li > ul li a {
  font-size: 15px;
}

/* DA SUA: Sidebar trang chi tiet news giu sticky tren desktop de muc luc/bai lien quan/banner di theo khi scroll. */
.news-detail-sidebar {
  position: sticky;
  top: 110px;
}

/* DA SUA: Muc luc trong sidebar mac dinh an, chi hien khi JS them class active sau khi scroll qua muc luc ban dau. */
.news-detail-sidebar-toc {
  display: none;
}

.news-detail-sidebar-toc.active {
  display: block;
}

.news-detail-sidebar-toc .wrap-toc {
  margin-top: 0;
}

/* DA SUA: Gioi han chieu cao muc luc sidebar va cho scroll rieng. */
.news-detail-sidebar-toc .toc-list {
  display: block;
  max-height: 320px;
  margin-top: 12px;
  padding-left: 15px;
  padding-right: 8px;
  scrollbar-color: var(--color-main) transparent;
  scrollbar-width: thin;
}

/* DA SUA: Lam dep thanh scroll muc luc sidebar news, scroll mong va bo tron giong style web mau. */
.news-detail-sidebar-toc .toc-list::-webkit-scrollbar {
  width: 3px;
}

.news-detail-sidebar-toc .toc-list::-webkit-scrollbar-track {
  background: transparent;
  border-radius: 10px;
}

.news-detail-sidebar-toc .toc-list::-webkit-scrollbar-thumb {
  background: var(--color-main);
  border-radius: 10px;
}

.news-detail-sidebar-toc .toc-list::-webkit-scrollbar-thumb:hover {
  background: #d30000;
}

.news-detail-sidebar-toc .toc-list > li > a::before {
  left: -15px;
}

/* DA SUA: Khoang cach giua cac block trong sidebar: muc luc, bai lien quan, banner. */
.news-detail-sidebar-block {
  margin-bottom: 20px;
}

.news-detail-sidebar-row {
  --bs-gutter-x: 12px;
}

.news-detail-sidebar-related .title-main-detail {
  margin-bottom: 15px;
}

.news-detail-sidebar-related .title-main-detail h2 {
  font-size: 20px;
  line-height: 1.3;
  margin-bottom: 0;
}

/* DA SUA: Item bai viet lien quan rieng cho sidebar, khong su dung blocks/post.php. */
.news-detail-related-item {
  display: flex;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid #e9e9e9;
}

.news-detail-related-item:last-child {
  padding-bottom: 0;
  margin-bottom: 0;
  border-bottom: 0;
}

.news-detail-related-image {
  display: block;
  flex: 0 0 86px;
  border-radius: 6px;
  overflow: hidden;
}

.news-detail-related-image img {
  aspect-ratio: 4 / 3;
  border-radius: 6px;
  object-fit: cover;
}

.news-detail-related-info {
  flex: 1;
  min-width: 0;
}

.news-detail-related-name {
  font-size: 14px;
  line-height: 1.4;
  margin-bottom: 4px;
}

.news-detail-related-name a {
  color: #222;
  text-decoration: none;
}

.news-detail-related-date {
  color: #888;
  font-size: 12px;
  line-height: 1.4;
  margin-bottom: 4px;
}

.news-detail-related-desc {
  color: #555;
  font-size: 13px;
  line-height: 1.4;
}
