/*
 * ThePlugBase blog — single post + archive.
 * Ported from theplugbase-blog-archive.html / theplugbase-blog-single.html.
 *
 * Everything is scoped to .tpb-blog (the <main> element of the templates) so it doesn't touch the
 * Elementor header/footer, and the colour tokens live on .tpb-blog instead of :root because
 * mu-plugins/plugbase-loops.php prints a dark :root palette that uses the same variable names.
 */

/* ── TOKENS & BASE ── */
.tpb-blog {
  --cream:   #FDFAF5;
  --cream2:  #F5F1E8;
  --cream3:  #EDE8DC;
  --white:   #FFFFFF;
  --line:    #E8E2D6;
  --line2:   #D8D0C0;
  --body:    #5C5648;
  --muted:   #9C9080;
  --heading: #1E1A14;
  --v:       #5B50E8;
  --vl:      #7B72F0;
  --vbg:     #EEEDFB;
  --vring:   rgba(91,80,232,0.15);
  --orange:  #E8732A;
  --obg:     #FDF0E8;
  --oring:   rgba(232,115,42,0.2);
  --green:   #2A9E6E;
  --gbg:     #E8F5EF;
  --gold:    #C49A28;
  --goldbg:  #FBF4E0;
  --font:    'Plus Jakarta Sans', sans-serif;

  display: block;
  background: var(--cream);
  color: var(--body);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
body.tpb-blog-page { background: #FDFAF5; }
html:has(body.tpb-blog-page) { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html:has(body.tpb-blog-page) { scroll-behavior: auto; } }

/* Reset for the layout chrome. Post content (.article-prose) keeps normal flow spacing. */
.tpb-blog :where(*:not(.article-prose *)),
.tpb-blog :where(*:not(.article-prose *))::before,
.tpb-blog :where(*:not(.article-prose *))::after { box-sizing: border-box; margin: 0; padding: 0; }

.tpb-blog a { color: inherit; text-decoration: none; background-color: transparent; }
.tpb-blog button { font-family: var(--font); cursor: pointer; }
.tpb-blog a:focus-visible,
.tpb-blog button:focus-visible,
.tpb-blog input:focus-visible { outline: 2px solid var(--v); outline-offset: 2px; }

/* ── BREADCRUMB ── */
.tpb-blog .bc { background: var(--white); border-bottom: 1px solid var(--line); padding: 12px 48px; display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; }
.tpb-blog .bc a { color: var(--muted); transition: color .2s; flex-shrink: 0; }
.tpb-blog .bc a:hover { color: var(--v); }
.tpb-blog .bc i { font-size: 12px; flex-shrink: 0; }
.tpb-blog .bc-current { color: var(--heading); font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; }

/* ═════════════════════════ ARCHIVE ═════════════════════════ */

/* ── BLOG HERO ── */
.tpb-blog .blog-hero { background: var(--white); border-bottom: 1px solid var(--line); padding: 52px 48px 44px; position: relative; overflow: hidden; }
.tpb-blog .bh-blob { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .22; pointer-events: none; }
.tpb-blog .bh-blob-1 { width: 450px; height: 380px; background: #C8C4FA; top: -120px; right: -80px; }
.tpb-blog .bh-blob-2 { width: 300px; height: 280px; background: #FAE4C8; bottom: -60px; left: 5%; }
.tpb-blog .bh-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap; position: relative; }
.tpb-blog .bh-eyebrow { display: inline-flex; align-items: center; gap: 6px; background: var(--vbg); border: 1px solid var(--vring); border-radius: 99px; padding: 4px 14px; font-size: 11px; font-weight: 700; color: var(--v); letter-spacing: .06em; text-transform: uppercase; margin-bottom: 16px; }
.tpb-blog .bh-title { font-family: var(--font); font-size: 40px; font-weight: 800; color: var(--heading); letter-spacing: -1.2px; line-height: 1.1; margin-bottom: 10px; }
.tpb-blog .bh-title .accent { color: var(--v); }
.tpb-blog .bh-sub { font-size: 15px; color: var(--muted); max-width: 440px; line-height: 1.7; }
.tpb-blog .bh-search { display: flex; align-items: center; gap: 10px; background: var(--cream2); border: 1.5px solid var(--line2); border-radius: 12px; padding: 6px 6px 6px 16px; width: 280px; transition: border-color .2s; }
.tpb-blog .bh-search:focus-within { border-color: var(--v); }
.tpb-blog .bh-search i { font-size: 17px; color: var(--muted); flex-shrink: 0; }
.tpb-blog .bh-search input[type="search"],
.tpb-blog .bh-search input[type="search"]:focus { flex: 1; min-width: 0; width: auto; background: transparent; border: none; border-radius: 0; box-shadow: none; outline: none; padding: 0; font-size: 13px; line-height: 1.5; color: var(--heading); font-family: var(--font); -webkit-appearance: none; appearance: none; }
.tpb-blog .bh-search input::placeholder { color: var(--muted); }
.tpb-blog .bh-search input::-webkit-search-cancel-button { -webkit-appearance: none; }
.tpb-blog .bh-search-btn,
.tpb-blog .bh-search-btn:hover,
.tpb-blog .bh-search-btn:focus { background: var(--v); color: #fff; border: none; border-radius: 8px; padding: 8px 16px; font-size: 13px; font-weight: 700; line-height: 1.5; white-space: nowrap; transition: background .2s; }
.tpb-blog .bh-search-btn:hover,
.tpb-blog .bh-search-btn:focus { background: #4840cc; }

/* ── CATEGORY TABS ── */
.tpb-blog .cat-tabs { background: var(--white); border-bottom: 1px solid var(--line); padding: 0 48px; }
.tpb-blog .cat-tabs-inner { max-width: 1200px; margin: 0 auto; display: flex; gap: 0; overflow-x: auto; scrollbar-width: none; }
.tpb-blog .cat-tabs-inner::-webkit-scrollbar { display: none; }
.tpb-blog .cat-tab { font-size: 13px; font-weight: 600; color: var(--muted); padding: 16px 20px; border-bottom: 2px solid transparent; white-space: nowrap; cursor: pointer; transition: all .2s; display: flex; align-items: center; gap: 6px; }
.tpb-blog .cat-tab:hover { color: var(--heading); }
.tpb-blog .cat-tab.active { color: var(--v); border-bottom-color: var(--v); }
.tpb-blog .cat-tab-count { font-size: 10px; font-weight: 700; color: var(--muted); background: var(--cream2); border-radius: 99px; padding: 1px 7px; }
.tpb-blog .cat-tab.active .cat-tab-count { background: var(--vbg); color: var(--v); }

/* ── MAIN LAYOUT ── */
.tpb-blog .blog-body { max-width: 1200px; margin: 0 auto; padding: 48px 48px 72px; display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.tpb-blog .blog-main { min-width: 0; }

/* ── FEATURED POST ── */
.tpb-blog .featured-post { background: var(--white); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; margin-bottom: 32px; display: grid; grid-template-columns: 1.1fr 1fr; box-shadow: 0 4px 20px rgba(30,26,20,.07); transition: all .2s; }
.tpb-blog .featured-post:hover { box-shadow: 0 8px 32px rgba(30,26,20,.1); transform: translateY(-2px); }
.tpb-blog .fp-img { background: var(--cream2); min-height: 320px; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.tpb-blog .fp-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tpb-blog .fp-img-placeholder { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.tpb-blog .fp-img-placeholder i { font-size: 44px; color: var(--muted); opacity: .3; }
.tpb-blog .fp-featured-badge { position: absolute; top: 14px; left: 14px; z-index: 1; background: var(--orange); color: #fff; font-size: 10px; font-weight: 700; padding: 4px 12px; border-radius: 99px; display: flex; align-items: center; gap: 5px; }
.tpb-blog .fp-featured-badge i { font-size: 10px; }
.tpb-blog .fp-body { padding: 36px 32px; display: flex; flex-direction: column; justify-content: center; }
.tpb-blog .fp-cat { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--v); background: var(--vbg); border: 1px solid var(--vring); border-radius: 5px; padding: 2px 9px; margin-bottom: 14px; width: fit-content; }
.tpb-blog .fp-title { font-family: var(--font); font-size: 24px; font-weight: 800; color: var(--heading); letter-spacing: -.5px; line-height: 1.25; margin-bottom: 12px; }
.tpb-blog .fp-title a:hover { color: var(--v); }
.tpb-blog .fp-excerpt { font-size: 14px; color: var(--body); line-height: 1.75; margin-bottom: 20px; }
.tpb-blog .fp-meta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.tpb-blog .fp-author { display: flex; align-items: center; gap: 8px; }
.tpb-blog .fp-av { width: 28px; height: 28px; border-radius: 50%; background: var(--vbg); border: 2px solid var(--vring); display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: var(--v); flex-shrink: 0; }
.tpb-blog .fp-author-name { font-size: 13px; font-weight: 600; color: var(--heading); }
.tpb-blog .fp-sep { width: 3px; height: 3px; border-radius: 50%; background: var(--line2); }
.tpb-blog .fp-date { font-size: 12px; color: var(--muted); }
.tpb-blog .fp-read { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 4px; }
.tpb-blog .fp-read i { font-size: 13px; }
.tpb-blog .fp-read-more { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--v); margin-top: 18px; transition: gap .2s; }
.tpb-blog .fp-read-more:hover { gap: 10px; color: var(--v); }
.tpb-blog .fp-read-more i { font-size: 14px; }

/* ── POST GRID ── */
.tpb-blog .posts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.tpb-blog .post-card { position: relative; background: var(--white); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; transition: all .2s; cursor: pointer; }
.tpb-blog .post-card:hover { border-color: var(--v); box-shadow: 0 6px 24px rgba(91,80,232,.08); transform: translateY(-2px); }
.tpb-blog .pc-img { height: 180px; background: var(--cream2); display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.tpb-blog .pc-img img { width: 100%; height: 100%; object-fit: cover; }
.tpb-blog .pc-img-ph { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.tpb-blog .pc-img-ph i { font-size: 32px; color: var(--muted); opacity: .28; }
.tpb-blog .pc-cat-badge { position: absolute; top: 10px; left: 10px; font-size: 10px; font-weight: 700; padding: 3px 10px; border-radius: 99px; }
.tpb-blog .pcb-v { background: var(--vbg); color: var(--v); border: 1px solid var(--vring); }
.tpb-blog .pcb-o { background: var(--obg); color: var(--orange); border: 1px solid var(--oring); }
.tpb-blog .pcb-g { background: var(--gbg); color: var(--green); border: 1px solid rgba(42,158,110,.2); }
.tpb-blog .pcb-gold { background: var(--goldbg); color: var(--gold); border: 1px solid rgba(196,154,40,.2); }
.tpb-blog .pc-body { padding: 18px; }
.tpb-blog .pc-title { font-family: var(--font); font-size: 15px; font-weight: 700; color: var(--heading); line-height: 1.35; margin-bottom: 8px; }
.tpb-blog .pc-title a:hover { color: var(--v); }
.tpb-blog .pc-title a::after { content: ""; position: absolute; inset: 0; z-index: 1; } /* whole card is clickable */
.tpb-blog .pc-excerpt { font-size: 13px; color: var(--muted); line-height: 1.65; margin-bottom: 14px; }
.tpb-blog .pc-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.tpb-blog .pc-author { display: flex; align-items: center; gap: 7px; min-width: 0; }
.tpb-blog .pc-av { width: 24px; height: 24px; border-radius: 50%; background: var(--vbg); display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; color: var(--v); flex-shrink: 0; }
.tpb-blog .pc-author-name { font-size: 12px; font-weight: 600; color: var(--body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tpb-blog .pc-read { font-size: 11px; color: var(--muted); display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.tpb-blog .pc-read i { font-size: 12px; }

/* ── PAGINATION ── */
.tpb-blog .pagination { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 6px; margin: 36px 0 0; }
.tpb-blog .page-btn { width: 38px; height: 38px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 600; border: 1.5px solid var(--line); background: var(--white); color: var(--muted); cursor: pointer; transition: all .2s; }
.tpb-blog .page-btn:hover { border-color: var(--v); color: var(--v); }
.tpb-blog .page-btn.active,
.tpb-blog .page-btn.active:hover { background: var(--v); color: #fff; border-color: var(--v); cursor: default; }
.tpb-blog .page-btn-arrow { width: 38px; height: 38px; border-radius: 9px; border: 1.5px solid var(--line); background: var(--white); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all .2s; }
.tpb-blog .page-btn-arrow:hover { border-color: var(--v); color: var(--v); }
.tpb-blog .page-btn-arrow i { font-size: 16px; color: var(--muted); }
.tpb-blog .page-btn-arrow:hover i { color: var(--v); }
.tpb-blog .page-btn-arrow.is-disabled { opacity: .45; cursor: default; pointer-events: none; }
.tpb-blog .page-dots { font-size: 13px; color: var(--muted); padding: 0 4px; }

/* ── EMPTY STATE ── */
.tpb-blog .blog-empty { background: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 56px 32px; text-align: center; display: flex; flex-direction: column; align-items: center; }
.tpb-blog .blog-empty i.ti-file-search { font-size: 40px; color: var(--muted); opacity: .45; }
.tpb-blog .blog-empty h2 { font-family: var(--font); font-size: 20px; font-weight: 800; color: var(--heading); line-height: 1.3; margin: 12px 0 6px; }
.tpb-blog .blog-empty p { font-size: 14px; color: var(--muted); max-width: 380px; }

/* ── SIDEBAR (shared) ── */
.tpb-blog .blog-sidebar,
.tpb-blog .article-sidebar { min-width: 0; }
.tpb-blog .sb-card { background: var(--white); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; margin-bottom: 16px; }
.tpb-blog .sb-header { background: var(--cream2); border-bottom: 1px solid var(--line); padding: 14px 18px; font-size: 13px; font-weight: 700; color: var(--heading); display: flex; align-items: center; gap: 7px; }
.tpb-blog .sb-header i { font-size: 15px; color: var(--v); }
.tpb-blog .sb-body { padding: 16px 18px; }

/* author widget */
.tpb-blog .sb-author { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 24px 18px; }
.tpb-blog .sb-author-av { width: 64px; height: 64px; border-radius: 50%; background: var(--vbg); border: 3px solid var(--vring); display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 800; color: var(--v); margin-bottom: 12px; }
.tpb-blog .sb-author-name { font-size: 16px; font-weight: 800; color: var(--heading); margin-bottom: 4px; }
.tpb-blog .sb-author-role { font-size: 12px; color: var(--muted); margin-bottom: 12px; }
.tpb-blog .sb-author-bio { font-size: 13px; color: var(--body); line-height: 1.65; }

/* categories */
.tpb-blog .sb-cat-list { display: flex; flex-direction: column; }
.tpb-blog .sb-cat-item { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--line); cursor: pointer; transition: all .2s; }
.tpb-blog .sb-cat-item:last-child { border-bottom: none; }
.tpb-blog .sb-cat-item:hover .sb-cat-name { color: var(--v); }
.tpb-blog .sb-cat-name { font-size: 13px; font-weight: 600; color: var(--body); display: flex; align-items: center; gap: 8px; transition: color .2s; }
.tpb-blog .sb-cat-name i { font-size: 14px; color: var(--v); }
.tpb-blog .sb-cat-count { font-size: 11px; font-weight: 700; color: var(--muted); background: var(--cream2); border: 1px solid var(--line); border-radius: 99px; padding: 1px 8px; }

/* popular posts */
.tpb-blog .sb-popular-list { display: flex; flex-direction: column; gap: 14px; }
.tpb-blog .sb-popular-item { display: flex; gap: 12px; cursor: pointer; }
.tpb-blog .sb-popular-item:hover .sb-popular-title { color: var(--v); }
.tpb-blog .sb-popular-thumb { width: 58px; height: 44px; border-radius: 8px; background: var(--cream2); border: 1px solid var(--line); flex-shrink: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.tpb-blog .sb-popular-thumb img { width: 100%; height: 100%; object-fit: cover; }
.tpb-blog .spt-ph i { font-size: 18px; color: var(--muted); opacity: .35; }
.tpb-blog .sb-popular-title { font-size: 13px; font-weight: 700; color: var(--heading); line-height: 1.4; margin-bottom: 4px; transition: color .2s; }
.tpb-blog .sb-popular-meta { font-size: 11px; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.tpb-blog .sb-popular-meta i { font-size: 12px; }

/* tags */
.tpb-blog .sb-tags { display: flex; gap: 7px; flex-wrap: wrap; }
.tpb-blog .sb-tag { font-size: 12px; color: var(--body); background: var(--cream2); border: 1px solid var(--line); border-radius: 7px; padding: 5px 11px; cursor: pointer; transition: all .2s; }
.tpb-blog .sb-tag:hover { border-color: var(--v); color: var(--v); background: var(--vbg); }

/* newsletter */
.tpb-blog .sb-newsletter { padding: 20px 18px; }
.tpb-blog .sb-newsletter p { font-size: 13px; color: var(--body); line-height: 1.65; margin-bottom: 14px; }
.tpb-blog .sb-nl-form { display: flex; flex-direction: column; gap: 8px; position: relative; }
.tpb-blog .sb-nl-input,
.tpb-blog .sb-nl-input:focus { width: 100%; background: var(--cream); border: 1.5px solid var(--line); border-radius: 9px; padding: 10px 13px; font-size: 13px; line-height: 1.5; color: var(--heading); font-family: var(--font); outline: none; box-shadow: none; transition: border-color .2s; }
.tpb-blog .sb-nl-input:focus { border-color: var(--v); }
.tpb-blog .sb-nl-input::placeholder { color: var(--muted); }
.tpb-blog .sb-nl-btn,
.tpb-blog .sb-nl-btn:hover,
.tpb-blog .sb-nl-btn:focus { width: 100%; background: var(--v); color: #fff; border: none; border-radius: 9px; padding: 11px; font-size: 13px; font-weight: 700; line-height: 1.5; font-family: var(--font); transition: background .2s; }
.tpb-blog .sb-nl-btn:hover,
.tpb-blog .sb-nl-btn:focus { background: #4840cc; }
.tpb-blog .sb-nl-note { font-size: 11px; color: var(--muted); text-align: center; margin-top: 6px; }
.tpb-blog .sb-nl-error { font-size: 12px; font-weight: 600; color: #C2410C; }
.tpb-blog .sb-nl-msg { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--green); background: var(--gbg); border: 1px solid rgba(42,158,110,.2); border-radius: 9px; padding: 10px 12px; }
.tpb-blog .sb-nl-msg i { font-size: 16px; }
.tpb-blog .sb-nl-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ═════════════════════════ SINGLE ═════════════════════════ */

/* ── ARTICLE HERO ── */
.tpb-blog .article-hero { background: var(--white); border-bottom: 1px solid var(--line); padding: 52px 48px 48px; }
.tpb-blog .article-hero-inner { max-width: 780px; margin: 0 auto; }
.tpb-blog .ah-cat { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--v); background: var(--vbg); border: 1px solid var(--vring); border-radius: 5px; padding: 3px 10px; margin-bottom: 18px; }
.tpb-blog .ah-cat:hover { color: var(--v); border-color: var(--v); }
.tpb-blog .ah-title { font-family: var(--font); font-size: 38px; font-weight: 800; color: var(--heading); letter-spacing: -1.2px; line-height: 1.12; margin-bottom: 18px; }
.tpb-blog .ah-excerpt { font-size: 17px; color: var(--muted); line-height: 1.75; margin-bottom: 28px; }
.tpb-blog .ah-meta { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding-bottom: 28px; border-bottom: 1px solid var(--line); margin-bottom: 0; }
.tpb-blog .ah-author { display: flex; align-items: center; gap: 10px; }
.tpb-blog .ah-av { width: 36px; height: 36px; border-radius: 50%; background: var(--vbg); border: 2px solid var(--vring); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; color: var(--v); flex-shrink: 0; }
.tpb-blog .ah-author-name { font-size: 14px; font-weight: 700; color: var(--heading); }
.tpb-blog .ah-author-role { font-size: 12px; color: var(--muted); margin-top: 1px; }
.tpb-blog .ah-sep { width: 1px; height: 28px; background: var(--line2); }
.tpb-blog .ah-stat { display: flex; align-items: center; gap: 5px; font-size: 13px; color: var(--muted); }
.tpb-blog .ah-stat i { font-size: 15px; }
.tpb-blog .ah-share { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.tpb-blog .ah-share-label { font-size: 12px; color: var(--muted); font-weight: 500; }
.tpb-blog .ah-share-btn,
.tpb-blog .ah-share-btn:hover,
.tpb-blog .ah-share-btn:focus { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line); background: var(--white); padding: 0; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all .2s; }
.tpb-blog .ah-share-btn:hover,
.tpb-blog .ah-share-btn:focus { border-color: var(--v); background: var(--vbg); }
.tpb-blog .ah-share-btn i { font-size: 15px; color: var(--muted); }
.tpb-blog .ah-share-btn:hover i,
.tpb-blog .ah-share-btn.is-copied i { color: var(--v); }
.tpb-blog .ah-share-btn.is-copied { border-color: var(--v); background: var(--vbg); }

/* ── FEATURED IMAGE ── */
.tpb-blog .article-featured-img { background: var(--white); border-bottom: 1px solid var(--line); }
.tpb-blog .afi-inner { max-width: 960px; margin: 0 auto; padding: 32px 48px; }
.tpb-blog .afi-img { width: 100%; aspect-ratio: 16/8; background: var(--cream2); border: 1px solid var(--line); border-radius: 16px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.tpb-blog .afi-img img { width: 100%; height: 100%; object-fit: cover; border-radius: 16px; }
.tpb-blog .afi-caption { text-align: center; font-size: 12px; color: var(--muted); margin-top: 10px; font-style: italic; }

/* ── ARTICLE BODY ── */
.tpb-blog .article-body { max-width: 1200px; margin: 0 auto; padding: 52px 48px 80px; display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; align-items: start; }
.tpb-blog .article-main { min-width: 0; }

/* ── TABLE OF CONTENTS (sticky sidebar top) ──
   The sidebar stretches to the article's full height so the TOC stays pinned while reading;
   the cards below it scroll up underneath, as in the design. */
.tpb-blog .article-sidebar { align-self: stretch; }
.tpb-blog .toc-card { background: var(--white); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; margin-bottom: 16px; position: sticky; top: 24px; z-index: 2; }
body.admin-bar .tpb-blog .toc-card { top: 56px; }
.tpb-blog .toc-list { max-height: calc(100vh - 120px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.tpb-blog .toc-header { background: var(--cream2); border-bottom: 1px solid var(--line); padding: 14px 18px; font-size: 13px; font-weight: 700; color: var(--heading); display: flex; align-items: center; gap: 7px; }
.tpb-blog .toc-header i { font-size: 15px; color: var(--v); }
.tpb-blog .toc-list { padding: 12px 18px; display: flex; flex-direction: column; gap: 4px; }
.tpb-blog .toc-item { display: flex; align-items: center; gap: 8px; font-size: 13px; line-height: 1.45; color: var(--muted); padding: 5px 0 5px 10px; cursor: pointer; transition: color .2s; border-left: 2px solid transparent; margin-left: -2px; }
.tpb-blog .toc-item:hover { color: var(--v); border-left-color: var(--vring); }
.tpb-blog .toc-item.active { color: var(--v); font-weight: 600; border-left-color: var(--v); }
.tpb-blog .toc-item-sub { padding-left: 22px; font-size: 12px; }

/* ── PROSE (post content) ── */
.tpb-blog .article-prose { max-width: 680px; color: var(--body); overflow-wrap: break-word; }
.tpb-blog .article-prose > :first-child { margin-top: 0; }
.tpb-blog .article-prose h2 { font-family: var(--font); font-size: 26px; font-weight: 800; color: var(--heading); letter-spacing: -.5px; line-height: 1.3; margin: 44px 0 16px; padding-top: 8px; }
.tpb-blog .article-prose h3 { font-family: var(--font); font-size: 19px; font-weight: 700; color: var(--heading); line-height: 1.35; margin: 32px 0 12px; }
.tpb-blog .article-prose h4 { font-family: var(--font); font-size: 17px; font-weight: 700; color: var(--heading); line-height: 1.4; margin: 28px 0 10px; }
.tpb-blog .article-prose :is(h2, h3, h4) { scroll-margin-top: 24px; }
body.admin-bar .tpb-blog .article-prose :is(h2, h3, h4) { scroll-margin-top: 56px; }
.tpb-blog .article-prose :is(h2, h3, h4, p):empty { display: none; }
.tpb-blog .article-prose p { font-size: 16px; color: var(--body); line-height: 1.85; margin: 0 0 20px; }
.tpb-blog .article-prose ul,
.tpb-blog .article-prose ol { padding-left: 22px; margin: 0 0 20px; }
.tpb-blog .article-prose li { font-size: 16px; color: var(--body); line-height: 1.8; margin-bottom: 8px; }
.tpb-blog .article-prose li > :is(ul, ol) { margin: 8px 0 0; }
.tpb-blog .article-prose strong,
.tpb-blog .article-prose b { color: var(--heading); font-weight: 700; }
.tpb-blog .article-prose a { color: var(--v); text-decoration: underline; text-decoration-color: var(--vring); text-underline-offset: 3px; }
.tpb-blog .article-prose a:hover { color: var(--v); text-decoration-color: var(--v); }
.tpb-blog .article-prose code { background: var(--cream2); border: 1px solid var(--line); border-radius: 5px; padding: 2px 7px; font-size: 13px; font-family: 'Courier New', monospace; color: var(--v); }
.tpb-blog .article-prose pre { background: var(--heading); border: none; border-radius: 12px; padding: 20px 24px; margin: 20px 0; overflow-x: auto; white-space: pre; }
.tpb-blog .article-prose pre code { background: transparent; border: none; padding: 0; color: #AFA9EC; font-size: 13px; line-height: 1.7; }
.tpb-blog .article-prose blockquote { margin: 28px 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--v); }
.tpb-blog .article-prose blockquote p { font-size: 17px; color: var(--heading); font-style: italic; margin-bottom: 10px; }
.tpb-blog .article-prose blockquote p:last-child { margin-bottom: 0; }
.tpb-blog .article-prose img { max-width: 100%; height: auto; }
.tpb-blog .article-prose img:not(.emoji):not(.wp-smiley) { border-radius: 12px; }
.tpb-blog .article-prose :is(figure, .wp-caption) { margin: 24px 0; max-width: 100%; }
.tpb-blog .article-prose :is(figcaption, .wp-caption-text, .wp-element-caption) { text-align: center; font-size: 12px; color: var(--muted); margin-top: 10px; font-style: italic; line-height: 1.5; }
.tpb-blog .article-prose .aligncenter { display: block; margin-left: auto; margin-right: auto; }
.tpb-blog .article-prose .alignleft { float: left; margin: 6px 24px 16px 0; }
.tpb-blog .article-prose .alignright { float: right; margin: 6px 0 16px 24px; }
.tpb-blog .article-prose table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 14px; }
.tpb-blog .article-prose :is(th, td) { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }
.tpb-blog .article-prose th { background: var(--cream2); color: var(--heading); font-weight: 700; }
.tpb-blog .article-prose hr { border: 0; border-top: 1px solid var(--line); margin: 36px 0; }
.tpb-blog .article-prose :is(iframe, video, embed, object) { max-width: 100%; }
.tpb-blog .article-prose::after { content: ""; display: table; clear: both; }

/* callout boxes — usable inside post content: <div class="callout callout-v">… */
.tpb-blog .callout { border-radius: 12px; padding: 18px 20px; margin: 24px 0; display: flex; gap: 14px; align-items: flex-start; }
.tpb-blog .callout-v { background: var(--vbg); border: 1px solid var(--vring); }
.tpb-blog .callout-o { background: var(--obg); border: 1px solid var(--oring); }
.tpb-blog .callout-g { background: var(--gbg); border: 1px solid rgba(42,158,110,.2); }
.tpb-blog .callout-gold { background: var(--goldbg); border: 1px solid rgba(196,154,40,.2); }
.tpb-blog .callout-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.tpb-blog .callout-v .callout-icon { color: var(--v); }
.tpb-blog .callout-o .callout-icon { color: var(--orange); }
.tpb-blog .callout-g .callout-icon { color: var(--green); }
.tpb-blog .callout-gold .callout-icon { color: var(--gold); }
.tpb-blog .callout-title { font-size: 14px; font-weight: 700; color: var(--heading); margin-bottom: 5px; }
.tpb-blog .callout-text { font-size: 13px; color: var(--body); line-height: 1.65; }

/* image in content — <div class="article-img"><img …></div> */
.tpb-blog .article-img { width: 100%; background: var(--cream2); border: 1px solid var(--line); border-radius: 12px; aspect-ratio: 16/9; display: flex; align-items: center; justify-content: center; margin: 24px 0; overflow: hidden; }
.tpb-blog .article-img img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
.tpb-blog .article-img-caption { text-align: center; font-size: 12px; color: var(--muted); margin-top: -16px; margin-bottom: 24px; font-style: italic; }

/* tags row */
.tpb-blog .article-tags { max-width: 680px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); }
.tpb-blog .article-tag-label { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.tpb-blog .article-tag { font-size: 12px; color: var(--body); background: var(--cream2); border: 1px solid var(--line); border-radius: 7px; padding: 4px 11px; cursor: pointer; transition: all .2s; }
.tpb-blog .article-tag:hover { border-color: var(--v); color: var(--v); background: var(--vbg); }

/* author card bottom */
.tpb-blog .author-card { max-width: 680px; background: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 24px; display: flex; gap: 18px; align-items: flex-start; margin-top: 36px; }
.tpb-blog .author-card-av { width: 56px; height: 56px; border-radius: 50%; background: var(--vbg); border: 3px solid var(--vring); display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 800; color: var(--v); flex-shrink: 0; }
.tpb-blog .author-card-name { font-size: 16px; font-weight: 800; color: var(--heading); margin-bottom: 3px; }
.tpb-blog .author-card-name a:hover { color: var(--v); }
.tpb-blog .author-card-role { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.tpb-blog .author-card-bio { font-size: 13px; color: var(--body); line-height: 1.65; }

/* product cta */
.tpb-blog .product-cta-card { background: var(--white); border: 2px solid var(--v); border-radius: 16px; overflow: hidden; margin-bottom: 16px; box-shadow: 0 4px 20px rgba(91,80,232,.1); }
.tpb-blog .pcc-img { height: 90px; background: var(--vbg); display: flex; align-items: center; justify-content: center; border-bottom: 1px solid var(--vring); position: relative; }
.tpb-blog .pcc-img i { font-size: 36px; color: var(--v); opacity: .35; }
.tpb-blog .pcc-badge { position: absolute; top: 8px; right: 8px; font-size: 10px; font-weight: 700; color: var(--orange); background: var(--obg); border: 1px solid var(--oring); border-radius: 5px; padding: 2px 8px; }
.tpb-blog .pcc-body { padding: 16px 18px; }
.tpb-blog .pcc-label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--v); margin-bottom: 6px; }
.tpb-blog .pcc-name { font-size: 15px; font-weight: 800; color: var(--heading); margin-bottom: 6px; }
.tpb-blog .pcc-desc { font-size: 12px; color: var(--muted); line-height: 1.55; margin-bottom: 14px; }
.tpb-blog .pcc-price-row { display: flex; align-items: baseline; gap: 6px; margin-bottom: 12px; }
.tpb-blog .pcc-price { font-size: 24px; font-weight: 800; color: var(--heading); }
.tpb-blog .pcc-period { font-size: 12px; color: var(--muted); }
.tpb-blog .pcc-btn,
.tpb-blog .pcc-btn:hover,
.tpb-blog .pcc-btn:focus { display: block; width: 100%; background: var(--v); color: #fff; border: none; border-radius: 9px; padding: 11px; font-size: 13px; font-weight: 700; text-align: center; font-family: var(--font); box-shadow: 0 2px 10px rgba(91,80,232,.22); transition: background .2s; margin-bottom: 8px; }
.tpb-blog .pcc-btn:hover,
.tpb-blog .pcc-btn:focus { background: #4840cc; }
.tpb-blog .pcc-link { display: block; text-align: center; font-size: 12px; color: var(--muted); transition: color .2s; }
.tpb-blog .pcc-link:hover { color: var(--v); }

/* related posts sidebar */
.tpb-blog .sb-related { display: flex; flex-direction: column; gap: 14px; padding: 14px 18px; }
.tpb-blog .sb-rel-item { display: flex; gap: 11px; cursor: pointer; }
.tpb-blog .sb-rel-item:hover .sb-rel-title { color: var(--v); }
.tpb-blog .sb-rel-thumb { width: 56px; height: 42px; border-radius: 8px; background: var(--cream2); border: 1px solid var(--line); flex-shrink: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.tpb-blog .sb-rel-thumb img { width: 100%; height: 100%; object-fit: cover; }
.tpb-blog .srt-ph i { font-size: 16px; color: var(--muted); opacity: .35; }
.tpb-blog .sb-rel-title { font-size: 13px; font-weight: 700; color: var(--heading); line-height: 1.35; margin-bottom: 3px; transition: color .2s; }
.tpb-blog .sb-rel-meta { font-size: 11px; color: var(--muted); }

/* ── MORE ARTICLES ── */
.tpb-blog .more-articles { background: var(--white); border-top: 1px solid var(--line); padding: 64px 48px; }
.tpb-blog .ma-inner { max-width: 1200px; margin: 0 auto; }
.tpb-blog .ma-title { font-family: var(--font); font-size: 22px; font-weight: 800; color: var(--heading); letter-spacing: -.4px; line-height: 1.3; margin-bottom: 28px; }
.tpb-blog .ma-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.tpb-blog .ma-card { display: block; background: var(--cream); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; transition: all .2s; cursor: pointer; }
.tpb-blog .ma-card:hover { border-color: var(--v); box-shadow: 0 4px 16px rgba(91,80,232,.08); transform: translateY(-2px); }
.tpb-blog .ma-card:hover .ma-post-title { color: var(--v); }
.tpb-blog .ma-img { height: 150px; background: var(--cream2); display: flex; align-items: center; justify-content: center; border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }
.tpb-blog .ma-img img { width: 100%; height: 100%; object-fit: cover; }
.tpb-blog .ma-img-ph { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.tpb-blog .ma-img-ph i { font-size: 28px; color: var(--muted); opacity: .28; }
.tpb-blog .ma-cat { position: absolute; top: 8px; left: 8px; font-size: 10px; font-weight: 700; padding: 3px 10px; border-radius: 99px; }
.tpb-blog .ma-body { padding: 16px; }
.tpb-blog .ma-post-title { font-family: var(--font); font-size: 14px; font-weight: 700; color: var(--heading); line-height: 1.35; margin-bottom: 8px; transition: color .2s; }
.tpb-blog .ma-meta { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.tpb-blog .ma-meta i { font-size: 13px; }

/* ═════════════════════════ RESPONSIVE ═════════════════════════ */
@media (max-width: 1100px) {
  .tpb-blog .bc,
  .tpb-blog .blog-hero,
  .tpb-blog .cat-tabs,
  .tpb-blog .article-hero,
  .tpb-blog .more-articles { padding-left: 32px; padding-right: 32px; }
  .tpb-blog .blog-body { grid-template-columns: minmax(0, 1fr) 280px; gap: 32px; padding: 40px 32px 64px; }
  .tpb-blog .article-body { grid-template-columns: minmax(0, 1fr) 280px; gap: 40px; padding: 44px 32px 72px; }
  .tpb-blog .afi-inner { padding: 28px 32px; }
}

@media (max-width: 1024px) {
  .tpb-blog .featured-post { grid-template-columns: 1fr; }
  .tpb-blog .fp-img { min-height: 260px; }
  .tpb-blog .fp-body { padding: 28px 28px 30px; }
}

@media (max-width: 900px) {
  .tpb-blog .blog-body,
  .tpb-blog .article-body { grid-template-columns: minmax(0, 1fr); }
  .tpb-blog .blog-sidebar,
  .tpb-blog .article-sidebar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
  .tpb-blog .blog-sidebar > *,
  .tpb-blog .article-sidebar > * { margin-bottom: 0; }
  .tpb-blog .toc-card { position: static; }
  .tpb-blog .toc-list { max-height: none; }
  .tpb-blog .article-prose,
  .tpb-blog .article-tags,
  .tpb-blog .author-card { max-width: none; }
  .tpb-blog .ma-grid { grid-template-columns: repeat(2, 1fr); }
  .tpb-blog .bh-search { width: 100%; max-width: 420px; }
}

@media (max-width: 640px) {
  .tpb-blog .bc,
  .tpb-blog .blog-hero,
  .tpb-blog .cat-tabs,
  .tpb-blog .article-hero,
  .tpb-blog .more-articles { padding-left: 16px; padding-right: 16px; }
  .tpb-blog .blog-hero { padding-top: 36px; padding-bottom: 32px; }
  .tpb-blog .bh-inner { gap: 24px; }
  .tpb-blog .bh-title { font-size: 30px; letter-spacing: -.8px; }
  .tpb-blog .bh-search { max-width: none; }
  .tpb-blog .cat-tab { padding: 14px 14px; }
  .tpb-blog .blog-body { padding: 28px 16px 56px; gap: 28px; }
  .tpb-blog .posts-grid { grid-template-columns: 1fr; }
  .tpb-blog .fp-img { min-height: 210px; }
  .tpb-blog .fp-body { padding: 22px 20px 24px; }
  .tpb-blog .fp-title { font-size: 21px; }
  .tpb-blog .blog-sidebar,
  .tpb-blog .article-sidebar { grid-template-columns: minmax(0, 1fr); }

  .tpb-blog .article-hero { padding-top: 36px; padding-bottom: 32px; }
  .tpb-blog .ah-title { font-size: 28px; letter-spacing: -.8px; }
  .tpb-blog .ah-excerpt { font-size: 16px; margin-bottom: 22px; }
  .tpb-blog .ah-meta { gap: 10px 16px; padding-bottom: 22px; }
  .tpb-blog .ah-author { width: 100%; }
  .tpb-blog .ah-sep { display: none; }
  .tpb-blog .ah-share { margin-left: 0; width: 100%; }
  .tpb-blog .afi-inner { padding: 20px 16px; }
  .tpb-blog .afi-img,
  .tpb-blog .afi-img img { border-radius: 12px; }
  .tpb-blog .article-body { padding: 32px 16px 56px; gap: 36px; }
  .tpb-blog .article-prose h2 { font-size: 22px; margin-top: 36px; }
  .tpb-blog .article-prose h3 { font-size: 18px; }
  .tpb-blog .article-prose :is(p, li) { font-size: 15.5px; }
  .tpb-blog .article-prose :is(.alignleft, .alignright) { float: none; margin: 20px auto; }
  .tpb-blog .article-prose table { display: block; overflow-x: auto; }
  .tpb-blog .author-card { padding: 20px; gap: 14px; }
  .tpb-blog .author-card-av { width: 48px; height: 48px; font-size: 19px; }
  .tpb-blog .more-articles { padding-top: 44px; padding-bottom: 44px; }
  .tpb-blog .ma-grid { grid-template-columns: 1fr; }
}
