/* BanglaTrack Blog Styles */

/* Archive grid */
.bt-blog-archive { max-width: 1200px; margin: 0 auto; }

.bt-blog-header { margin-bottom: 48px; }
.bt-blog-header h1 { font-size: clamp(28px, 4vw, 42px); font-weight: 800; }
.bt-blog-desc { font-size: 16px; color: var(--text2); margin-top: 8px; line-height: 1.7; max-width: 560px; }

.bt-blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.bt-blog-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color .2s, box-shadow .2s;
}

.bt-blog-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(13, 107, 80, .1);
}

.bt-blog-card-thumb img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.bt-blog-card-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }

.bt-blog-meta {
  font-size: 12px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 10px;
}

.bt-blog-meta a { color: var(--accent); text-decoration: none; }

.bt-blog-card-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  margin: 0 0 12px;
}

.bt-blog-card-title a { color: var(--text); text-decoration: none; }
.bt-blog-card-title a:hover { color: var(--accent); }

.bt-blog-card-excerpt {
  font-size: 14px;
  color: var(--text2);
  line-height: 1.7;
  margin-bottom: 20px;
  flex: 1;
}

.bt-blog-read-more {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  margin-top: auto;
}

/* Pagination */
.bt-pagination { display: flex; justify-content: center; margin-top: 48px; gap: 8px; }
.bt-pagination .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: var(--r-sm);
  border: 1px solid var(--border); color: var(--text2);
  text-decoration: none; font-size: 14px; font-weight: 600;
  transition: all .15s;
}
.bt-pagination .page-numbers.current { background: var(--accent); color: #fff; border-color: var(--accent); }
.bt-pagination .page-numbers:hover:not(.current) { border-color: var(--accent); color: var(--accent); }
.bt-pagination .prev, .bt-pagination .next { width: auto; padding: 0 16px; }

/* Single post layout */
.bt-single-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 60px;
  align-items: start;
}

.bt-single-header { margin-bottom: 32px; }
.bt-single-categories { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--accent); margin-bottom: 12px; }
.bt-single-categories a { color: var(--accent); text-decoration: none; }
.bt-single-article h1 { font-size: clamp(26px, 4vw, 38px); font-weight: 800; line-height: 1.25; margin-bottom: 16px; }
.bt-single-meta { font-size: 13px; color: var(--text3); display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* Article body */
.bt-single-body h2 { font-size: 22px; font-weight: 700; margin: 40px 0 12px; }
.bt-single-body h3 { font-size: 17px; font-weight: 700; margin: 28px 0 10px; }
.bt-single-body p  { line-height: 1.8; color: var(--text2); margin-bottom: 18px; font-size: 15px; }
.bt-single-body ul,
.bt-single-body ol { padding-left: 24px; margin-bottom: 18px; }
.bt-single-body li { line-height: 1.75; color: var(--text2); font-size: 15px; margin-bottom: 6px; }
.bt-single-body a  { color: var(--accent); }
.bt-single-body img { max-width: 100%; border-radius: var(--r); margin: 12px 0; }
.bt-single-body blockquote {
  border-left: 3px solid var(--accent);
  padding: 12px 20px;
  margin: 24px 0;
  background: var(--surface2);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  color: var(--text2);
  font-style: italic;
}
.bt-single-body code {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  background: var(--surface2);
  border: 1px solid var(--border);
  padding: 2px 6px;
  border-radius: 4px;
}
.bt-single-body pre {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 16px;
  overflow-x: auto;
  margin-bottom: 24px;
}
.bt-single-body pre code { background: none; border: none; padding: 0; font-size: 13px; }

/* Footer */
.bt-single-footer { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); }
.bt-post-nav { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.bt-post-nav a { font-size: 13px; font-weight: 600; color: var(--accent); text-decoration: none; max-width: 48%; }

/* Sidebar */
.bt-blog-sidebar { position: sticky; top: 88px; }
.bt-sidebar-widget {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
  margin-bottom: 20px;
}
.bt-sidebar-title { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 12px; color: var(--text3); }
.bt-sidebar-cat-list { list-style: none; padding: 0; margin: 0; }
.bt-sidebar-cat-list a { display: flex; justify-content: space-between; padding: 6px 0; font-size: 13px; color: var(--text2); text-decoration: none; border-bottom: 1px solid var(--border); }
.bt-sidebar-cat-list a:hover { color: var(--accent); }
.bt-sidebar-cat-list li:last-child a { border-bottom: none; }

@media (max-width: 900px) {
  .bt-single-layout { grid-template-columns: 1fr; }
  .bt-blog-sidebar { position: static; }
}

/* ── Default widget styling (Appearance → Widgets output) ───────
   Any core widget dropped into a registered sidebar inherits the
   same card look as the hand-built .bt-sidebar-widget blocks above. */
.widget {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
  margin-bottom: 20px;
}
.widget-title {
  font-size: 13px; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; margin-bottom: 12px; color: var(--text3);
}
.widget ul { list-style: none; padding: 0; margin: 0; }
.widget li { padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
.widget li:last-child { border-bottom: none; }
.widget a { color: var(--text2); text-decoration: none; }
.widget a:hover { color: var(--accent); }
.widget select,
.widget input[type="text"],
.widget input[type="search"],
.widget input[type="email"] {
  width: 100%; padding: 8px 12px; border: 1px solid var(--border2);
  border-radius: var(--r-sm); background: var(--bg); color: var(--text);
  font-family: inherit; font-size: 13px;
}

/* ── Comments (single.php → comments.php) ───────────────────── */
.bt-comments { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--border); }
.bt-comments-title { font-size: 20px; font-weight: 800; margin-bottom: 24px; }
.bt-comment-list { list-style: none; padding: 0; margin: 0 0 32px; }
.bt-comment-list .children { list-style: none; padding-left: 44px; margin: 0; }
.bt-comment {
  display: flex; gap: 14px; padding: 20px 0; border-bottom: 1px solid var(--border);
}
.bt-comment-list > li:first-child > .bt-comment { padding-top: 0; }
.bt-comment-avatar img { border-radius: 50%; display: block; }
.bt-comment-body { flex: 1; min-width: 0; }
.bt-comment-meta { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.bt-comment-author { font-size: 14px; font-weight: 700; color: var(--text); }
.bt-comment-date { font-size: 12px; color: var(--text3); }
.bt-comment-content p { font-size: 14px; line-height: 1.7; color: var(--text2); margin-bottom: 10px; }
.bt-comment-pending { font-size: 12px; color: var(--accent4); font-style: italic; margin-bottom: 8px; }
.bt-comment-reply a {
  font-size: 12px; font-weight: 700; color: var(--accent); text-decoration: none;
}
.bt-comments-closed { font-size: 14px; color: var(--text2); margin-bottom: 24px; }

/* Comment form (comment_form()) */
.bt-comment-form { max-width: 640px; }
.bt-comment-form-row { margin-bottom: 16px; }
.bt-comment-form-row label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; color: var(--text2); }
.bt-comment-form-row input,
.bt-comment-form-row textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--border2);
  border-radius: var(--r-sm); background: var(--surface); color: var(--text);
  font-family: inherit; font-size: 14px; transition: border-color .15s; resize: vertical;
}
.bt-comment-form-row input:focus,
.bt-comment-form-row textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(13,107,80,.1); }
.comment-form-cookies-consent { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 13px; color: var(--text2); }
.comment-form-cookies-consent label { margin: 0; font-weight: 400; }
@media (min-width: 560px) {
  .bt-comment-form-row-half { display: inline-block; width: calc(50% - 8px); }
  .bt-comment-form-row-half:first-of-type { margin-right: 16px; }
}
