/*
Theme Name: Ajker Desh Bangla Pro
Theme URI: https://ajkerdeshbangla.com/
Author: BD IT Support
Author URI: https://bditsupport.com/
Description: Bengali newspaper theme with 20 modular sections, custom settings and WordPress template support.
Version: 5.2.0
Text Domain: ajker-deshbangla
*/

@import url('https://fonts.maateen.me/solaiman-lipi/font.css');

/* ========================================================
   ১. ভ্যারিয়েবল ও বেসিক রিসেট (CSS Variables & Global Reset)
======================================================== */
:root {
  --tt-primary: #C4002F;
  --tt-secondary: #004717;
  --tt-border: #e2e8f0;
  --tt-bg: #ffffff;
  --tt-card-bg: #ffffff;
  --tt-dark: #1a202c;
  --tt-muted: #64748b;
  --tt-footer-bg: #e3fff4;
  --bdit-topbar-bg: #ffffff;
  --bdit-menu-bg: #ffffff;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  font-family: 'SolaimanLipi', Arial, sans-serif;
  color: var(--tt-dark);
  background: var(--tt-bg);
  line-height: 1.6;
  margin: 0;
  padding: 0;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease-in-out;
}

a:hover {
  color: var(--tt-primary);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ========================================================
   ২. হেডার, টপবার ও সোশ্যাল মিডিয়া (Header & Topbar)
======================================================== */
.sub-top-header {
  background: rgba(0, 71, 23, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  font-size: 14px;
}

.top-main-header {
  border-bottom: 1px solid #eaeaea;
  background-color: var(--bdit-topbar-bg, #ffffff);
  color: #1e293b;
}

.top-main-header .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.top-main-header .site-logo,
.top-main-header .site-logo a {
  display: inline-block;
  line-height: 0;
}

.top-main-header .site-logo img,
.top-main-header a img,
.custom-logo {
  max-height: 65px !important;
  max-width: 250px !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain;
  margin: 0 auto;
}

.header-date-location {
  font-size: 14px;
  line-height: 1.4;
}

.header-date-location .location-text {
  font-weight: 600;
  color: #333;
}

.header-date-location .date-text {
  font-size: 13px;
}

.header-social-icons {
  white-space: nowrap;
}

.header-social-icons .social-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid #dcdcdc;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0077b5;
  font-size: 13px;
  background: #fff;
  transition: all 0.3s ease;
}

.header-social-icons .social-btn:hover {
  background: var(--tt-primary);
  color: #fff;
  border-color: var(--tt-primary);
}

/* ========================================================
   ৩. ন্যাভিগেশন বার, সার্চ ও অফক্যানভাস ড্রয়ার (Navigation & Drawer)
======================================================== */
.main-navbar-wrap {
  background-color: var(--bdit-menu-bg, #ffffff);
}

.header-primary-menu-wrap {
  overflow: hidden;
  white-space: nowrap;
}

.header-single-line-menu {
  flex-wrap: nowrap !important;
  overflow: hidden;
}

.header-single-line-menu li {
  flex-shrink: 0;
}

.navbar-nav .nav-link,
.header-single-line-menu a {
  font-size: 16px;
  padding: 6px 8px !important;
  color: #111 !important;
  white-space: nowrap;
}

.navbar-nav .nav-link:hover,
.header-single-line-menu a:hover {
  color: var(--tt-primary) !important;
}

.header-right-actions {
  font-size: 15px;
  white-space: nowrap;
}

.header-epaper-btn {
  color: #000;
  font-size: 15px;
  font-weight: bold;
}

.header-right-actions .divider {
  color: #ccc;
  margin: 0 4px;
}

.header-right-actions .action-icon {
  color: #000;
  padding: 0 4px;
  font-size: 16px;
  cursor: pointer;
}

.header-right-actions .action-icon:hover {
  color: var(--tt-primary);
}

/* সার্চ পপআপ বক্স */
.header-search-popup {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #ffffff;
  border-bottom: 2px solid var(--tt-primary, #C4002F);
  z-index: 1050;
  display: none;
}

.header-search-popup.active {
  display: block !important;
  animation: fadeInDown 0.2s ease-in-out;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* অফক্যানভাস ড্রয়ার এবং ওভারলে */
.offcanvas-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9998;
  display: none;
}

.offcanvas-overlay.show {
  display: block !important;
}

.offcanvas-drawer {
  position: fixed;
  top: 0;
  right: -320px;
  width: 300px;
  height: 100vh;
  background: #ffffff;
  z-index: 9999;
  box-shadow: -4px 0 15px rgba(0, 0, 0, 0.15);
  transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
}

.offcanvas-drawer.open {
  right: 0 !important;
}

.drawer-menu-list a {
  display: block;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 600;
  border-bottom: 1px solid #f1f5f9;
}

.drawer-menu-list a:hover {
  background-color: var(--tt-primary);
  color: #fff !important;
}

/* ========================================================
   ৪. ব্রেকিং নিউজ টিকার (Breaking News Ticker)
======================================================== */
.bg-ticker {
  background-color: #B30026;
  height: 42px;
  position: relative;
}

.ticker-badge {
  background-color: #990020;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  padding: 0 18px;
  height: 100%;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  z-index: 2;
}

.ticker-scroll-track {
  white-space: nowrap;
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.ticker-marquee-inner {
  display: inline-block;
  white-space: nowrap;
  padding-left: 100%;
  animation: tickerSlide var(--bdit-ticker-speed, 45s) linear infinite;
}

.ticker-marquee-inner:hover {
  animation-play-state: paused;
}

.ticker-item-wrap {
  display: inline-flex;
  align-items: center;
  margin-right: 35px;
}

.ticker-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #ffffff;
  display: inline-block;
  margin-right: 8px;
}

.ticker-link {
  color: #ffffff !important;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

.ticker-link:hover {
  text-decoration: underline;
}

@keyframes tickerSlide {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-100%, 0, 0); }
}

/* ========================================================
   ৫. আলোচিত টপিকস মেনু (Trending Topics)
======================================================== */
.header-trending-section {
  text-align: center;
}

.trending-title {
  font-size: 15px;
  color: #111;
  margin-right: 5px;
}

.trending-tags {
  list-style: none;
  padding: 0;
  margin: 0;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
}

.trending-tags li,
.trending-tag-item {
  display: inline-block;
}

.trending-tags li a,
.trending-tag-item {
  border: 1px solid #e2e8f0;
  background-color: #f8fafc;
  color: #334155 !important;
  font-size: 14px;
  padding: 3px 14px;
  border-radius: 4px;
  display: inline-block;
  text-decoration: none;
  transition: all 0.2s ease;
}

.trending-tags li a:hover,
.trending-tag-item:hover {
  background-color: var(--tt-primary) !important;
  color: #ffffff !important;
  border-color: var(--tt-primary) !important;
}

/* ========================================================
   ৬. ক্যাটাগরি পোস্ট, গ্রিড ও সেকশন (Category & Post Layouts)
======================================================== */
.heading-postcard {
  border-bottom: 2px solid var(--tt-primary);
  margin-bottom: 15px;
  padding-bottom: 4px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.heading-postcard h2 a {
  font-size: 20px;
  font-weight: 700;
  color: var(--tt-dark);
}

.heading-postcard .indicator-hp {
  font-size: 14px;
  color: var(--tt-muted);
}

/* প্রধান লিড পোস্ট */
.post-lead-main {
  background: var(--tt-card-bg);
  border: 1px solid var(--tt-border);
  border-radius: 6px;
  padding: 10px;
}

.post-lead-thumb-wrap {
  width: 100%;
  aspect-ratio: 16 / 10;
  max-height: 320px;
  overflow: hidden;
  border-radius: 6px;
  display: block;
  background-color: #f1f5f9;
}

.post-lead-thumb-wrap img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block;
}

/* গ্রিড পোস্ট কার্ড */
.post-card-box {
  background: var(--tt-card-bg);
  border: 1px solid var(--tt-border);
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.post-card-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
}

.post-thumb-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: #f1f5f9;
  display: block;
}

.post-thumb-wrapper img,
.ps-post-line-img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  display: block;
  transition: transform 0.3s ease;
}

.post-card-box:hover .post-thumb-wrapper img {
  transform: scale(1.05);
}

.post-content-area {
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.news-lead-title {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
  margin: 0;
  color: #1a202c;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.news-title-md {
  font-size: 16px;
  line-height: 1.45;
  font-weight: 600;
  color: #1a202c;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 2.9em;
}

.news-title-sm {
  font-size: 14px;
  line-height: 1.4;
  font-weight: 600;
  color: #1a202c;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 2.8em;
}

/* ছোট তালিকা পোস্ট */
.small-posts-list-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  height: 100%;
  justify-content: space-between;
}

.small-post-item {
  display: flex;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid var(--tt-border);
  padding: 8px 0;
  clear: both;
}

.small-post-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.small-post-thumb-wrap {
  width: 90px;
  height: 65px;
  flex-shrink: 0;
  border-radius: 4px;
  overflow: hidden;
  background-color: #f1f5f9;
  display: block;
}

.small-post-thumb-wrap img,
.small-post-thumb {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block;
}

.small-post-info {
  flex: 1;
  min-width: 0;
}

.small-post-title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ডানপাশের সকল জেলার খবর বক্স */
.district-box-wrap {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  position: relative;
  height: auto !important;
  display: block;
}

.map-container {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f8fafc;
  padding: 8px;
  border-radius: 6px;
}

/* ========================================================
   ৭. ফুটার ও সম্পাদক বক্স (Footer Area)
======================================================== */
.footer-wrap {
  background-color: var(--tt-footer-bg);
  border-top: 1px solid #c9ebd9;
}

.editor-box {
  display: flex;
  align-items: center;
  gap: 12px;
}

.editor-img {
  width: 85px;
  height: 85px;
  border-radius: 6px;
  object-fit: cover;
  border: 2px solid #fff;
}

/* ========================================================
   ৮. রেসপন্সিভ মিডিয়া কুয়েরি (Responsive Styles)
======================================================== */
@media (max-width: 768px) {
  .top-main-header .row {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .header-social-icons {
    justify-content: center;
  }
}

/* ========================================================
   ৯. সিঙ্গেল পেজ ও সাইডবার ট্যাব (Single Post & Tabs)
======================================================== */
.single-news-page {
  background-color: #f8fafc;
}

.shadow-xs {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.single-post-title {
  font-size: 28px;
  line-height: 1.42;
  color: #0f172a;
}

@media (min-width: 768px) {
  .single-post-title {
    font-size: 32px;
  }
}

.single-main-thumb img {
  max-height: 480px;
  width: 100%;
  object-fit: cover;
  border-radius: 6px;
}

.single-body-text {
  font-size: 19px;
  line-height: 1.85;
  color: #1e293b;
}

.single-body-text p {
  margin-bottom: 1.3rem;
  text-align: justify;
}

/* সোশ্যাল শেয়ার বাটন */
.single-share-btns .share-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  color: #ffffff !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.single-share-btns .share-icon:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}

.share-icon.fb { background-color: #1877f2; }
.share-icon.tw { background-color: #000000; }
.share-icon.wa { background-color: #25d366; }
.share-icon.cp { background-color: #64748b; }

/* সাইডবার ট্যাব */
#singleSidebarTabs .nav-link,
#sideTab .nav-link {
  color: #475569;
  border: none;
  font-size: 14px;
}

#singleSidebarTabs .nav-link.active,
#sideTab .nav-link.active {
  background-color: var(--tt-primary, #C4002F) !important;
  color: #ffffff !important;
}

/* সাইডবার ক্রমিক নম্বর ব্যাজ */
.sidebar-ranked-item {
  border-bottom: 1px solid #f1f5f9;
}

.sidebar-ranked-item:last-child {
  border-bottom: none !important;
}

.rank-badge {
  width: 22px;
  height: 22px;
  background-color: #f1f5f9;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid #e2e8f0;
}

.rank-badge.popular-rank {
  background-color: #fff1f2;
  color: #e11d48;
  border-color: #fecdd3;
}

/* সাইডবার স্টিকি ইফেক্ট */
@media (min-width: 992px) {
  .sidebar-sticky-wrap {
    position: -webkit-sticky;
    position: sticky;
    top: 20px;
  }
}

/* ========================================================
   ১০. ২০টি সেকশনের লেআউট সিএসএস (Section Layout Styles)
======================================================== */
.sec-thumb-frame {
  position: relative;
  width: 100%;
  display: block;
  overflow: hidden;
  background-color: #f1f5f9;
  border-radius: 4px;
}

.sec-thumb-frame img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  display: block;
  transition: transform 0.3s ease;
}

.sec-thumb-frame:hover img {
  transform: scale(1.05);
}

.aspect-16-9 {
  aspect-ratio: 16 / 9;
}

.aspect-16-10 {
  aspect-ratio: 16 / 10;
}

.sec-card-box {
  background: var(--tt-card-bg);
  border: 1px solid var(--tt-border);
  border-radius: 6px;
  overflow: hidden;
  height: 100%;
}

.sec-list-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sec-list-item {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 8px;
}

.sec-list-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.sec-mini-thumb {
  width: 80px;
  height: 55px;
  flex-shrink: 0;
  border-radius: 4px;
  overflow: hidden;
  display: block;
  background-color: #f1f5f9;
}

.sec-mini-thumb img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

.overlay-card {
  position: relative;
}

.overlay-text-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85), transparent);
}

.video-card-thumb i {
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
  pointer-events: none;
}

/* ========================================================
   ১১. স্ক্রল টু টপ বাটন স্টাইল (Back To Top Button)
======================================================== */
#backToTopBtn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 44px;
  height: 44px;
  background-color: var(--tt-primary, #C4002F);
  color: #ffffff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: bold;
  box-shadow: 0 4px 12px rgba(196, 0, 47, 0.35);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#backToTopBtn.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#backToTopBtn:hover {
  background-color: #990020;
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(196, 0, 47, 0.5);
}

@media (max-width: 768px) {
  #backToTopBtn {
    bottom: 20px;
    right: 20px;
    width: 38px;
    height: 38px;
    font-size: 16px;
  }
}

/* ========================================================
   ১২. পূর্ণাঙ্গ ডার্ক মোড ইঞ্জিন (Unified Dark Theme Engine)
======================================================== */
body.dark-theme {
  --tt-bg: #0f172a;
  --tt-card-bg: #1e293b;
  --tt-dark: #f8fafc;
  --tt-border: #334155;
  --tt-muted: #94a3b8;
  --tt-footer-bg: #0b1120;
  --bdit-topbar-bg: #1e293b;
  --bdit-menu-bg: #1e293b;
  background-color: var(--tt-bg) !important;
  color: var(--tt-dark) !important;
}

/* পেজ কন্টেইনার ও এরিয়া */
body.dark-theme .single-news-page,
body.dark-theme .site-content,
body.dark-theme .single-post-wrap,
body.dark-theme main {
  background-color: var(--tt-bg) !important;
  color: var(--tt-dark) !important;
}

/* কার্ড, বক্স ও ব্যাকগ্রাউন্ড ওভাররাইড */
body.dark-theme .top-main-header,
body.dark-theme .main-navbar-wrap,
body.dark-theme .navbar,
body.dark-theme .bg-white,
body.dark-theme .card,
body.dark-theme .sec-card-box,
body.dark-theme .post-card-box,
body.dark-theme .post-lead-main,
body.dark-theme .single-post-card,
body.dark-theme .single-article-wrap,
body.dark-theme .related-news-wrap,
body.dark-theme .related-news-card,
body.dark-theme .entry-content-wrap,
body.dark-theme .header-search-popup,
body.dark-theme .offcanvas-drawer,
body.dark-theme .list-group-item,
body.dark-theme .district-box-wrap,
body.dark-theme .map-container,
body.dark-theme .sec-photo-gallery {
  background-color: var(--tt-card-bg) !important;
  color: var(--tt-dark) !important;
  border-color: var(--tt-border) !important;
}

/* হেডার টেক্সট ও লিংক কালার */
body.dark-theme a,
body.dark-theme .navbar-nav .nav-link,
body.dark-theme .action-icon,
body.dark-theme .header-epaper-btn,
body.dark-theme .header-single-line-menu a,
body.dark-theme .drawer-menu-list a,
body.dark-theme .single-post-title,
body.dark-theme .news-lead-title,
body.dark-theme .news-title-md,
body.dark-theme .news-title-sm,
body.dark-theme .small-post-title,
body.dark-theme .heading-postcard h2 a,
body.dark-theme h1,
body.dark-theme h2,
body.dark-theme h3,
body.dark-theme h4,
body.dark-theme h5,
body.dark-theme h6,
body.dark-theme .text-dark {
  color: #f8fafc !important;
}

body.dark-theme a:hover,
body.dark-theme .navbar-nav .nav-link:hover,
body.dark-theme .sidebar-post-list a:hover {
  color: #f87171 !important;
}

body.dark-theme .text-muted,
body.dark-theme .text-secondary,
body.dark-theme .post-meta,
body.dark-theme .entry-meta,
body.dark-theme .indicator-hp {
  color: var(--tt-muted) !important;
}

body.dark-theme .header-date-location .location-text,
body.dark-theme .trending-title {
  color: #e2e8f0 !important;
}

/* বর্ডার ও বিভাজক রেখা */
body.dark-theme .border-bottom,
body.dark-theme .border-top,
body.dark-theme .border-start,
body.dark-theme .border-end,
body.dark-theme .border,
body.dark-theme .sec-list-item,
body.dark-theme .small-post-item,
body.dark-theme .sidebar-ranked-item {
  border-color: var(--tt-border) !important;
}

/* সোশ্যাল বাটন ও আইকন */
body.dark-theme .social-btn,
body.dark-theme .header-social-icons .social-btn {
  background-color: #334155;
  color: #f8fafc !important;
  border-color: #475569;
}

body.dark-theme .social-btn:hover {
  background-color: var(--tt-primary);
  border-color: var(--tt-primary);
}

/* টিকার ও ট্রেন্ডিং ট্যাগ */
body.dark-theme .bg-ticker {
  background-color: #1e293b !important;
  border: 1px solid var(--tt-border);
}

body.dark-theme .ticker-link {
  color: #f8fafc !important;
}

body.dark-theme .trending-tags li a,
body.dark-theme .trending-tag-item {
  background-color: var(--tt-card-bg) !important;
  border-color: var(--tt-border) !important;
  color: #cbd5e1 !important;
}

body.dark-theme .trending-tags li a:hover,
body.dark-theme .trending-tag-item:hover {
  background-color: var(--tt-primary) !important;
  color: #ffffff !important;
  border-color: var(--tt-primary) !important;
}

/* ফর্ম ও ইনপুট কন্ট্রোল */
body.dark-theme input.form-control,
body.dark-theme select.form-control,
body.dark-theme select {
  background-color: #0f172a !important;
  color: #ffffff !important;
  border-color: var(--tt-border) !important;
}

/* সাইডবার ট্যাব ও উইজেট ডার্ক ফিক্স */
body.dark-theme .nav-tabs,
body.dark-theme .tab-content,
body.dark-theme .sidebar-tab-header {
  background-color: var(--tt-card-bg) !important;
  border-color: var(--tt-border) !important;
}

body.dark-theme .nav-tabs .nav-link,
body.dark-theme #singleSidebarTabs .nav-link,
body.dark-theme #sideTab .nav-link {
  background-color: var(--tt-card-bg) !important;
  color: #cbd5e1 !important;
  border-color: var(--tt-border) !important;
}

body.dark-theme .nav-tabs .nav-link.active,
body.dark-theme #singleSidebarTabs .nav-link.active,
body.dark-theme #sideTab .nav-link.active {
  background-color: var(--tt-primary, #C4002F) !important;
  color: #ffffff !important;
  border-color: var(--tt-primary, #C4002F) !important;
}

body.dark-theme .rank-badge,
body.dark-theme .tab-post-number {
  background-color: #334155 !important;
  color: #38bdf8 !important;
  border-color: #475569 !important;
}

body.dark-theme .rank-badge.popular-rank {
  background-color: #4c0519 !important;
  color: #fb7185 !important;
  border-color: #9f1239 !important;
}

/* সিঙ্গেল পোস্ট বডি কনটেন্ট ও ব্রেডক্রাম্ব */
body.dark-theme .single-body-text,
body.dark-theme .entry-content,
body.dark-theme .entry-content p {
  color: #cbd5e1 !important;
}

body.dark-theme .breadcrumb,
body.dark-theme .breadcrumb-item {
  background-color: transparent !important;
  color: var(--tt-muted) !important;
}

body.dark-theme .breadcrumb-item a {
  color: #cbd5e1 !important;
}

body.dark-theme .share-buttons {
  border-color: var(--tt-border) !important;
}

/* =========================================================
   THEMESONE 5.2 — unified responsive and complete dark mode
========================================================= */
:root {
  --bdit-surface: #ffffff;
  --bdit-surface-soft: #f8fafc;
  --bdit-text: #172033;
  --bdit-text-muted: #64748b;
  --bdit-line: #e2e8f0;
}
.bdit-brand-logo {
  display:block;
  width:auto !important;
  height:auto !important;
  max-width:min(100%, 360px) !important;
  max-height:var(--bdit-logo-height, 65px) !important;
  object-fit:contain;
  margin:0 auto;
}
.bdit-footer-logo {
  width:auto;
  max-width:min(82vw, 280px);
  max-height:62px;
  height:auto;
  object-fit:contain;
  margin:0 auto;
}
.top-main-header,
.main-navbar-wrap,
.header-search-popup,
.header-trending-section,
.header-ticker-section,
.offcanvas-drawer,
.footer-wrap,
.site-content,
main,
article,
aside,
.widget,
.post-card-box,
.sec-card-box,
.post-lead-main,
.single-news-page {
  min-width:0;
}
.main-navbar-wrap { isolation:isolate; }
.header-primary-menu-wrap { flex:1 1 auto; }
.header-single-line-menu { overflow:visible; }
.header-ticker-section {
  display:block;
  width:100%;
  clear:both;
  position:relative;
  z-index:1;
  margin:12px auto 0;
}
.header-ticker-section .ticker-scroll-track {
  min-width:0;
  overflow:hidden;
}
.header-ticker-section .ticker-marquee-inner {
  will-change:transform;
  animation-duration:var(--bdit-ticker-speed, 45s) !important;
}
.header-ticker-section .ticker-marquee-inner:hover {
  animation-play-state:paused;
}
body.dark-theme {
  color-scheme:dark;
  --tt-bg:#0b1220;
  --tt-card-bg:#151f30;
  --tt-dark:#f1f5f9;
  --tt-border:#2b3a50;
  --tt-muted:#a7b4c7;
  --tt-footer-bg:#080e19;
  --bdit-topbar-bg:#111b2b;
  --bdit-menu-bg:#111b2b;
  --bdit-surface:#151f30;
  --bdit-surface-soft:#101a29;
  --bdit-text:#f1f5f9;
  --bdit-text-muted:#a7b4c7;
  --bdit-line:#2b3a50;
  background:#0b1220 !important;
  color:#f1f5f9 !important;
}
body.dark-theme,
body.dark-theme #page,
body.dark-theme .site,
body.dark-theme .site-content,
body.dark-theme main,
body.dark-theme .single-news-page,
body.dark-theme .archive-page,
body.dark-theme .category-page,
body.dark-theme .container-fluid {
  background-color:#0b1220 !important;
  color:#f1f5f9 !important;
}
body.dark-theme .top-main-header,
body.dark-theme .main-navbar-wrap,
body.dark-theme .navbar,
body.dark-theme .header-search-popup,
body.dark-theme .header-trending-section,
body.dark-theme .bg-white,
body.dark-theme .bg-light,
body.dark-theme .card,
body.dark-theme .card-body,
body.dark-theme .post-card-box,
body.dark-theme .post-lead-main,
body.dark-theme .sec-card-box,
body.dark-theme .single-post-card,
body.dark-theme .single-article-wrap,
body.dark-theme .related-news-wrap,
body.dark-theme .related-news-card,
body.dark-theme .entry-content-wrap,
body.dark-theme .offcanvas-drawer,
body.dark-theme .district-box-wrap,
body.dark-theme .map-container,
body.dark-theme .tab-content,
body.dark-theme .nav-tabs,
body.dark-theme .nav-pills,
body.dark-theme .list-group-item,
body.dark-theme .widget,
body.dark-theme .widget-area,
body.dark-theme .search-results,
body.dark-theme .archive-header,
body.dark-theme .breadcrumb,
body.dark-theme .table,
body.dark-theme .table th,
body.dark-theme .table td {
  background-color:#151f30 !important;
  color:#e5edf7 !important;
  border-color:#2b3a50 !important;
}
body.dark-theme .header-date-location .location-text,
body.dark-theme .header-date-location .date-text,
body.dark-theme .navbar-nav .nav-link,
body.dark-theme .header-single-line-menu .nav-link,
body.dark-theme .header-right-actions .action-icon,
body.dark-theme .header-epaper-btn,
body.dark-theme .trending-title,
body.dark-theme .trending-tag-item,
body.dark-theme .news-lead-title,
body.dark-theme .news-title-md,
body.dark-theme .news-title-sm,
body.dark-theme .small-post-title,
body.dark-theme .single-post-title,
body.dark-theme .single-body-text,
body.dark-theme .entry-content,
body.dark-theme .entry-content p,
body.dark-theme .heading-postcard h2 a,
body.dark-theme .drawer-menu-list a,
body.dark-theme .widget-title,
body.dark-theme .text-dark,
body.dark-theme h1, body.dark-theme h2, body.dark-theme h3,
body.dark-theme h4, body.dark-theme h5, body.dark-theme h6,
body.dark-theme label {
  color:#e5edf7 !important;
}
body.dark-theme .text-muted,
body.dark-theme .text-secondary,
body.dark-theme .post-meta,
body.dark-theme .entry-meta,
body.dark-theme .indicator-hp,
body.dark-theme small,
body.dark-theme .description {
  color:#a7b4c7 !important;
}
body.dark-theme .border,
body.dark-theme .border-top,
body.dark-theme .border-bottom,
body.dark-theme .border-start,
body.dark-theme .border-end,
body.dark-theme hr,
body.dark-theme .sec-list-item,
body.dark-theme .small-post-item,
body.dark-theme .sidebar-ranked-item {
  border-color:#2b3a50 !important;
}
body.dark-theme input,
body.dark-theme textarea,
body.dark-theme select,
body.dark-theme .form-control,
body.dark-theme .form-select {
  background:#0b1220 !important;
  color:#f1f5f9 !important;
  border-color:#34445b !important;
}
body.dark-theme .header-social-icons .social-btn,
body.dark-theme .header-right-actions .action-icon,
body.dark-theme .rank-badge,
body.dark-theme .trending-tag-item {
  background:#1e2b40 !important;
  color:#e5edf7 !important;
  border-color:#34445b !important;
}
body.dark-theme .footer-wrap {
  background:#080e19 !important;
  color:#d5deea !important;
}
body.dark-theme .footer-wrap a { color:#e5edf7 !important; }
body.dark-theme .footer-wrap .border-bottom,
body.dark-theme .footer-wrap .border-top { border-color:#26364b !important; }
body.dark-theme .header-search-popup input { background:#0b1220 !important; }
body.dark-theme .header-trending-section { background:#111b2b !important; }
body.dark-theme .bg-ticker {
  background:#111b2b !important;
  border-color:#34445b !important;
}
body.dark-theme .ticker-link { color:#f1f5f9 !important; }
body.dark-theme .nav-tabs .nav-link,
body.dark-theme .nav-pills .nav-link {
  color:#cbd5e1 !important;
  background:transparent !important;
}
body.dark-theme .nav-tabs .nav-link.active,
body.dark-theme .nav-pills .nav-link.active {
  background:var(--bdit-primary, #c4002f) !important;
  color:#fff !important;
}
body.dark-theme .offcanvas-overlay { background:rgba(0,0,0,.72); }

/* Consistent desktop-to-mobile design language; only dimensions reflow. */
@media (max-width: 991.98px) {
  .bdit-brand-logo { max-width:min(70vw, 320px) !important; }
  .header-primary-menu-wrap { overflow-x:auto !important; }
  .header-single-line-menu { width:max-content; min-width:100%; }
}
@media (max-width: 767.98px) {
  .top-main-header { padding:10px 0 !important; }
  .top-main-header .row { display:flex; flex-direction:column; gap:8px; }
  .top-main-header .site-logo { order:0; width:100%; }
  .top-main-header .col-lg-4:first-child { order:1; width:100%; text-align:center; }
  .top-main-header .col-lg-4:last-child { order:2; width:100%; text-align:center !important; }
  .header-date-location .location-text,
  .header-date-location .date-text { justify-content:center; }
  .header-social-icons { justify-content:center; flex-wrap:wrap; }
  .main-navbar-wrap > .container { align-items:center; }
  .header-single-line-menu .nav-link { font-size:var(--bdit-menu-font-size,13px) !important; }
  .header-ticker-section { margin-top:8px !important; }
  .post-content-area { padding:9px 10px; }
  .single-post-title { font-size:clamp(22px,5vw,30px); }
  .single-body-text { font-size:18px; line-height:1.8; }
  .bdit-footer-logo { max-height:52px; }
}
@media (max-width: 420px) {
  .header-right-actions { gap:4px !important; }
  .header-right-actions .action-icon { width:28px; height:28px; }
  .header-epaper-btn { padding:3px 6px; font-size:11px; }
  .header-ticker-section .ticker-badge { padding:0 8px; font-size:12px; }
  .header-ticker-section .ticker-link { font-size:12px; }
  .small-post-thumb-wrap { width:76px; height:56px; }
  .sec-mini-thumb { width:72px; height:52px; }
}

/* Dashboard: modern card-based controls and submenu-aware active state. */
