/* ITVowel palette (matches hero.css: --main-color, .tg-btn purple, logo blue) */
:root {
  --blog-blue: #2E4E8A;
  --blog-blue-dark: #1c2b4a;
  --blog-purple: #7A3FA3;
  --blog-purple-dark: #5A2D82;
  --blog-gradient: linear-gradient(135deg, #2E4E8A 0%, #7A3FA3 100%);
  --off-white: #F6F8FC;
  --light-border: #E4EAF4;
}

/* style.css sets overflow-x:hidden on html/body, which turns body into a
   scroll container and silently disables position:sticky for the sidebar.
   clip still stops horizontal overflow without creating a scroll container.
   !important because component/header.html re-links style.css when header.js
   injects it, so style.css ends up *after* this file in the cascade. */
html, body { overflow-x: clip !important; }

/* ── LIST HERO ── */
.blog-hero-lead { max-width: 720px; font-size: 18px; }

/* ── LIST ── */
#blog-list-section { background: var(--off-white); padding: 70px 0 90px; }

.state-msg {
  text-align: center;
  color: #5a6a85;
  padding: 4rem 1rem;
  width: 100%;
  font-size: 15px;
}

.bc {
  border: 1px solid var(--light-border);
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
  height: 100%;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.bc:hover {
  box-shadow: 0 18px 48px rgba(46,78,138,0.16);
  transform: translateY(-6px);
  color: inherit;
  border-color: rgba(122,63,163,0.35);
}

/* Cover: post image when there is one, otherwise one soft off-white panel
   with faint blue/purple bubbles (same on every card), a topic chip and the
   topic icon in a small white badge. */
.bc-cover {
  position: relative;
  height: 150px;
  flex-shrink: 0;
  overflow: hidden;
  display: flex; align-items: flex-start;
  padding: 18px 20px;
  border-bottom: 1px solid var(--light-border);
  background:
    radial-gradient(circle at 88% 18%, rgba(122,63,163,0.10) 0 58px, transparent 59px),
    radial-gradient(circle at 8% 115%, rgba(46,78,138,0.08) 0 72px, transparent 73px),
    radial-gradient(circle at 58% 30%, rgba(122,63,163,0.07) 0 16px, transparent 17px),
    radial-gradient(circle at 40% 78%, rgba(46,78,138,0.07) 0 9px, transparent 10px),
    radial-gradient(circle at 72% 88%, rgba(122,63,163,0.06) 0 24px, transparent 25px),
    linear-gradient(180deg, #F8F7FE 0%, #FFFFFF 100%);
}
.bc-cover.has-img { background-size: cover; background-position: center; border-bottom: none; }
.bc-cover.has-img::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(28,43,74,0.05), rgba(28,43,74,0.45));
}
.bc-cover.has-img .bc-icon { display: none; }
.bc-chip {
  position: relative; z-index: 1;
  font-family: 'Poppins', sans-serif; font-size: 11px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--blog-purple); background: rgba(122,63,163,0.08);
  border: 1px solid rgba(122,63,163,0.15);
  padding: 5px 12px; border-radius: 30px;
}
.bc-cover.has-img .bc-chip { color: #fff; background: rgba(255,255,255,0.2); border-color: rgba(255,255,255,0.35); }
.bc-icon {
  position: absolute; right: 22px; bottom: 20px; z-index: 1;
  width: 58px; height: 58px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; line-height: 1; color: var(--blog-purple);
  background: #fff;
  box-shadow: 0 8px 22px rgba(122,63,163,0.14);
  transition: transform .3s, background .3s, color .3s;
}
.bc:hover .bc-icon { transform: translateY(-3px); background: var(--blog-purple); color: #fff; }

.bc-body {
  padding: 1.4rem 1.5rem 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.bc-title {
  font-family: 'Poppins', sans-serif;
  font-size: 1.08rem;
  font-weight: 700;
  color: var(--blog-blue-dark);
  margin-bottom: .6rem;
  line-height: 1.4;
  flex: 1;
  transition: color .2s;
}
.bc:hover .bc-title { color: var(--blog-purple); }
.bc-desc {
  font-size: .87rem;
  color: #5a6a85;
  line-height: 1.6;
  margin-bottom: 1.1rem;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.bc-meta {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  font-size: .8rem;
  color: #7a8aa5;
  font-weight: 500;
  border-top: 1px solid var(--light-border);
  padding-top: .9rem;
  margin-top: .4rem;
}
.bc-read { color: var(--blog-purple); font-weight: 600; white-space: nowrap; }
.bc-read i { display: inline-block; transition: transform .2s; }
.bc:hover .bc-read i { transform: translateX(4px); }

/* ── POST DETAIL ── */
#blog-post-view { background: var(--off-white); padding: 0 0 90px; }

/* Hero: post's own cover image behind the title + breadcrumb */
#post-hero {
  background: var(--blog-gradient);
  background-size: cover; background-position: center; background-repeat: no-repeat;
  position: relative; overflow: hidden;
  min-height: 360px;
  display: flex; align-items: flex-end;
  padding: 60px 0 55px;
}
#post-hero::before {
  content: ''; position: absolute; inset: 0; z-index: 1;
  /* dark overlay so title/breadcrumb stay legible over any cover photo */
  background: linear-gradient(180deg, rgba(28,43,74,0.35) 0%, rgba(28,43,74,0.45) 45%, rgba(28,43,74,0.85) 100%);
}
@media (max-width: 767px) {
  #post-hero { min-height: 280px; padding-bottom: 40px; }
}
.post-breadcrumb {
  font-family: 'Poppins', sans-serif; font-size: 13px; font-weight: 600;
  margin-bottom: 1.1rem;
}
.post-breadcrumb a { color: rgba(255,255,255,0.75); text-decoration: none; }
.post-breadcrumb a:hover { color: #fff; }
.post-breadcrumb i { font-size: 10px; margin: 0 8px; color: rgba(255,255,255,0.4); }
.post-hero-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.9rem, 3.8vw, 2.75rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.25;
  max-width: 820px;
  margin-bottom: .85rem;
}
.post-hero-meta { font-size: .85rem; color: #fff; font-weight: 600; }

/* Container that holds the sidebar + article below the hero */
#blog-post-view > .container { padding-top: 60px; }

.post-body {
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  line-height: 1.85;
  color: #33415c;
}
.post-body img { max-width: 100%; height: auto; border-radius: 14px; }
.post-body img[data-align="left"] { float: left; margin: 0.25rem 1.5rem 0.75rem 0; max-width: 50%; }
.post-body img[data-align="right"] { float: right; margin: 0.25rem 0 0.75rem 1.5rem; max-width: 50%; }
.post-body img[data-align="center"] { display: block; margin-left: auto; margin-right: auto; }
.post-body a { color: var(--blog-blue); font-weight: 600; }
.post-body a:hover { color: var(--blog-purple); }
.post-body h1, .post-body h2, .post-body h3, .post-body h4, .post-body h5, .post-body h6 {
  font-family: 'Poppins', sans-serif; color: var(--blog-blue); margin-top: 1.75rem;
  scroll-margin-top: 110px; /* keeps heading clear of the fixed navbar when jumped to */
}
.post-body blockquote {
  border-left: 4px solid var(--blog-purple);
  background: #fff;
  border-radius: 0 12px 12px 0;
  padding: 14px 20px;
  margin: 1.25rem 0;
  font-style: italic;
  color: var(--blog-blue-dark);
}

/* Blog editor's video embeds (YouTube/Vimeo) and tables */
.post-body .video-embed-wrapper { position: relative; width: 100%; padding-top: 56.25%; margin: 1.5rem 0; border-radius: 14px; overflow: hidden; background: #000; }
.post-body .video-embed-wrapper iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.post-body table { border-collapse: collapse; width: 100%; margin: 1.5rem 0; }
.post-body table td, .post-body table th { border: 1px solid var(--light-border); padding: 0.6rem 0.9rem; vertical-align: top; }
.post-body table th { background: var(--off-white); font-weight: 600; text-align: left; }

/* ── TWO-COLUMN LAYOUT: sticky sidebar (30%) + content (70%) ──
   The sidebar is one card (TOC + booking CTA) that stays pinned below the
   fixed navbar while only the article scrolls. No inner scrollbars. */
.post-layout { display: flex; gap: 2.75rem; align-items: flex-start; }
.post-sidebar { flex: 0 0 30%; max-width: 30%; position: sticky; top: 110px; }
.post-main { flex: 1 1 70%; min-width: 0; }

@media (max-width: 991px) {
  .post-layout { flex-direction: column; }
  .post-sidebar { position: static; flex: 1 1 auto; max-width: 100%; width: 100%; }
}

.sidebar-card {
  background: #fff; border: 1px solid var(--light-border); border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(46,78,138,0.08);
}
.toc-section { padding: 1.4rem 1.25rem 1.1rem; }
.toc-title {
  font-family: 'Poppins', sans-serif; font-size: 13px; font-weight: 700;
  color: var(--blog-blue-dark); text-transform: uppercase; letter-spacing: .06em;
  margin-bottom: 1rem;
}
#toc-list { list-style: none; margin: 0; padding: 0; }
#toc-list li { margin-bottom: 2px; }
#toc-list a {
  display: block; padding: 6px 10px; border-radius: 8px;
  font-size: 13px; color: #7a8aa5; text-decoration: none; line-height: 1.4;
  border-left: 2px solid transparent; transition: color .2s, background .2s, border-color .2s;
}
#toc-list a:hover { color: var(--blog-purple); background: var(--off-white); border-color: var(--blog-purple); }
#toc-list a.toc-top { font-size: 13.5px; font-weight: 600; color: #5a6a85; }
#toc-list a.toc-top:hover { color: var(--blog-blue-dark); }

/* ── BOOKING CTA (bottom of the sidebar card) — button opens the cal.com popup ── */
.sidebar-cta {
  background: var(--blog-gradient);
  padding: 1.4rem 1.25rem;
  text-align: center;
}
.sidebar-cta-title {
  font-family: 'Poppins', sans-serif; font-size: 15px; font-weight: 700;
  color: #fff; margin-bottom: .35rem;
}
.sidebar-cta-sub { font-size: 13px; color: rgba(255,255,255,0.85); line-height: 1.6; margin-bottom: 1rem; }
.btn-book-call {
  display: block; width: 100%;
  background: #fff; color: var(--blog-purple); border: none;
  padding: 12px 0; border-radius: 50px;
  font-family: 'Poppins', sans-serif; font-weight: 700; font-size: 14px;
  cursor: pointer;
  transition: background .2s, color .2s, transform .15s;
}
.btn-book-call:hover { background: #000; color: #fff; transform: translateY(-2px); }
