/* Blog article page (frontend/blogs/show) and the visual blocks posts can use:
   .quick-answer, .cf-takeaways, .cf-stats > .cf-stat, .cf-callout(.is-warn), .cf-chart, .cf-table, .cf-steps,
   figure.cf-figure, .cf-sources, .cf-disclaimer */
:root {
  --post-ink: #0f172a;
  --post-text: #334155;
  --post-muted: #64748b;
  --post-line: #e2e8f0;
  --post-accent: #632adb;
  --post-accent-2: #00b4d8;
  --post-soft: #f5f3ff;
}

/* Header */
.post-hero { padding: 150px 0 36px; text-align: center; background: radial-gradient(900px 320px at 50% 0%, rgba(99, 42, 219, .10), transparent 70%); }
.post-crumbs { display: inline-flex; gap: 8px; align-items: center; font-size: 14px; font-weight: 600; color: var(--post-muted); margin-bottom: 18px; }
.post-crumbs a { color: var(--post-accent); text-decoration: none; }
.post-title { font-family: "Sora", sans-serif; font-weight: 700; font-size: clamp(30px, 4.4vw, 52px); line-height: 1.12; letter-spacing: -.02em; color: var(--post-ink); max-width: 900px; margin: 0 auto 18px; text-wrap: balance; }
.post-dek { font-size: clamp(17px, 1.6vw, 20px); line-height: 1.6; color: var(--post-text); max-width: 720px; margin: 0 auto 26px; }
.post-meta { display: inline-flex; align-items: center; gap: 12px; text-align: left; }
.post-meta-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.post-meta strong { display: block; color: var(--post-ink); font-size: 15px; }
.post-meta span { font-size: 14px; color: var(--post-muted); }

.post-cover { max-width: 1100px; margin: 0 auto 56px; }
.post-cover img { display: block; width: 100%; height: auto; aspect-ratio: 1200 / 630; object-fit: cover; border-radius: 24px; box-shadow: 0 30px 60px -30px rgba(15, 23, 42, .35); }

/* Layout: sticky contents on the left, article column capped for comfortable reading */
.post-layout { display: grid; grid-template-columns: 240px minmax(0, 760px); justify-content: center; gap: 56px; padding-bottom: 40px; }
.post-aside-inner { position: sticky; top: 120px; }
.post-aside-label { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--post-muted); margin: 0 0 12px; }
.post-toc { list-style: none; padding: 0; margin: 0 0 28px; border-left: 2px solid var(--post-line); }
.post-toc li { margin: 0; }
.post-toc a { display: block; padding: 7px 0 7px 16px; margin-left: -2px; border-left: 2px solid transparent; font-size: 14px; line-height: 1.4; color: var(--post-text); text-decoration: none; }
.post-toc a:hover, .post-toc a.is-active { color: var(--post-accent); border-left-color: var(--post-accent); }
.post-share { display: flex; gap: 8px; }
.post-share a { width: 38px; height: 38px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--post-line); background: #fff; color: var(--post-ink); text-decoration: none; transition: .2s; }
.post-share a:hover { background: var(--post-accent); border-color: var(--post-accent); color: #fff; }

@media (max-width: 991.98px) {
  .post-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .post-aside { display: none; }
  .post-hero { padding-top: 130px; }
  .post-cover { margin-bottom: 36px; }
  .post-cover img { border-radius: 16px; }
}

/* Article typography */
.post-body { font-family: "Inter Tight", sans-serif; font-size: 18px; line-height: 1.8; color: var(--post-text); }
.post-body > * { margin-top: 0; margin-bottom: 1.25em; }
.post-body h2 { font-family: "Sora", sans-serif; font-size: clamp(24px, 2.6vw, 31px); font-weight: 700; line-height: 1.25; letter-spacing: -.01em; color: var(--post-ink); margin: 2.2em 0 .7em; scroll-margin-top: 120px; text-wrap: balance; }
.post-body h2::before { content: ""; display: block; width: 44px; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--post-accent), var(--post-accent-2)); margin-bottom: 16px; }
.post-body h3 { font-family: "Sora", sans-serif; font-size: 21px; font-weight: 700; line-height: 1.35; color: var(--post-ink); margin: 1.8em 0 .5em; }
.post-body a { color: var(--post-accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.post-body a:hover { text-decoration-thickness: 2px; }
.post-body strong { color: var(--post-ink); }
.post-body ul, .post-body ol { padding-left: 0; list-style: none; }
.post-body ul > li { position: relative; padding-left: 30px; margin-bottom: .6em; }
.post-body ul > li::before { content: ""; position: absolute; left: 4px; top: .62em; width: 10px; height: 10px; border-radius: 50%; background: linear-gradient(135deg, var(--post-accent), var(--post-accent-2)); }
.post-body ol { counter-reset: step; }
.post-body ol > li { position: relative; padding-left: 44px; margin-bottom: .8em; counter-increment: step; }
.post-body ol > li::before { content: counter(step); position: absolute; left: 0; top: .15em; width: 30px; height: 30px; border-radius: 50%; background: var(--post-soft); color: var(--post-accent); font-weight: 700; font-size: 15px; display: flex; align-items: center; justify-content: center; }
.post-body blockquote { margin: 1.8em 0; padding: 4px 0 4px 24px; border-left: 4px solid var(--post-accent); font-size: 21px; line-height: 1.6; font-style: italic; color: var(--post-ink); }
.post-body img { max-width: 100%; height: auto; border-radius: 16px; }
.post-body hr { border: 0; border-top: 1px solid var(--post-line); margin: 2.5em 0; }

/* Quick answer (top of every post) */
.post-body .quick-answer { position: relative; background: linear-gradient(135deg, #f5f3ff, #ecfeff); border: 1px solid #e4dcfb; border-left: 0; border-radius: 18px; padding: 22px 24px 22px 26px; font-size: 18px; color: var(--post-ink); }
.post-body .quick-answer::before { content: ""; position: absolute; left: 0; top: 16px; bottom: 16px; width: 4px; border-radius: 4px; background: linear-gradient(var(--post-accent), var(--post-accent-2)); }
.post-body .quick-answer strong { color: var(--post-accent); }

/* Key takeaways */
.cf-takeaways { background: var(--post-ink); color: #cbd5e1; border-radius: 20px; padding: 26px 28px; }
.cf-takeaways > p:first-child, .cf-takeaways-title { font-family: "Sora", sans-serif; font-size: 13px !important; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #67e8f9 !important; margin: 0 0 14px; }
.cf-takeaways ul { margin: 0; }
.cf-takeaways li { color: #e2e8f0; }
.cf-takeaways li:last-child { margin-bottom: 0; }
.cf-takeaways strong { color: #fff; }

/* Stat cards */
.cf-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; }
.cf-stat { background: #fff; border: 1px solid var(--post-line); border-radius: 18px; padding: 20px; }
.cf-stat-value { display: block; font-family: "Sora", sans-serif; font-size: 34px; font-weight: 700; line-height: 1.1; background: linear-gradient(90deg, var(--post-accent), var(--post-accent-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.cf-stat-label { display: block; margin-top: 8px; font-size: 15px; line-height: 1.45; color: var(--post-text); }
.cf-stat-source { display: block; margin-top: 8px; font-size: 12px; color: var(--post-muted); }
.cf-stat.is-up .cf-stat-value::after { content: " \2191"; color: #10b981; -webkit-text-fill-color: #10b981; font-size: .6em; }
.cf-stat.is-down .cf-stat-value::after { content: " \2193"; color: #e11d48; -webkit-text-fill-color: #e11d48; font-size: .6em; }

/* Callouts */
.cf-callout { display: flex; gap: 14px; background: #ecfeff; border: 1px solid #bae6fd; border-radius: 16px; padding: 18px 20px; font-size: 17px; color: var(--post-ink); }
.cf-callout::before { content: "i"; flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; background: #0891b2; color: #fff; font-weight: 700; font-size: 14px; display: flex; align-items: center; justify-content: center; margin-top: 2px; font-family: Georgia, serif; }
.cf-callout.is-warn { background: #fff7ed; border-color: #fed7aa; }
.cf-callout.is-warn::before { content: "!"; background: #ea580c; font-family: inherit; }
.cf-callout p { margin: 0; }

/* Charts */
.cf-chart { background: #fff; border: 1px solid var(--post-line); border-radius: 20px; padding: 22px 22px 16px; margin: 2em 0; }
.cf-chart-title { font-family: "Sora", sans-serif; font-size: 17px; font-weight: 700; color: var(--post-ink); margin: 0 0 14px; }
.cf-chart-canvas { position: relative; height: 320px; }
.cf-chart figcaption { margin-top: 12px; font-size: 13px; line-height: 1.5; color: var(--post-muted); }
@media (max-width: 575.98px) { .cf-chart-canvas { height: 260px; } .cf-chart { padding: 16px 12px 12px; } }

/* Figures */
.cf-figure { margin: 2em 0; }
.cf-figure img { display: block; width: 100%; border-radius: 18px; }
.cf-figure figcaption { margin-top: 10px; font-size: 14px; color: var(--post-muted); text-align: center; }

/* Tables (any table in the post, or wrapped in .cf-table for horizontal scroll on phones) */
.cf-table { overflow-x: auto; border: 1px solid var(--post-line); border-radius: 16px; margin: 2em 0; }
.post-body table { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 1.5; }
.post-body th { background: var(--post-ink); color: #fff; font-weight: 600; text-align: left; padding: 12px 16px; white-space: nowrap; }
.post-body td { padding: 12px 16px; border-top: 1px solid var(--post-line); vertical-align: top; }
.post-body tbody tr:nth-child(even) td { background: #f8fafc; }
.post-body td:first-child { font-weight: 600; color: var(--post-ink); }

/* Steps */
.cf-steps { display: grid; gap: 12px; counter-reset: cfstep; }
.cf-step { position: relative; background: #fff; border: 1px solid var(--post-line); border-radius: 16px; padding: 18px 20px 18px 70px; counter-increment: cfstep; }
.cf-step::before { content: counter(cfstep, decimal-leading-zero); position: absolute; left: 20px; top: 18px; font-family: "Sora", sans-serif; font-weight: 700; font-size: 22px; color: var(--post-accent); }
.cf-step strong { display: block; margin-bottom: 2px; }
.cf-step p { margin: 0; font-size: 16px; }

/* Sources and disclaimers */
.cf-sources { font-size: 14px; line-height: 1.6; color: var(--post-muted); border-top: 1px solid var(--post-line); padding-top: 16px; }
.cf-sources ol > li { padding-left: 30px; }
.cf-sources ol > li::before { width: 22px; height: 22px; font-size: 12px; top: .05em; }
.cf-sources a { color: var(--post-muted); }
.cf-disclaimer { font-size: 14px; line-height: 1.6; color: var(--post-muted); background: #f8fafc; border-radius: 12px; padding: 14px 16px; }

/* FAQ: every h3 after the FAQ heading becomes a card */
.post-body #frequently-asked-questions ~ h3 { font-size: 18px; background: #fff; border: 1px solid var(--post-line); border-bottom: 0; border-radius: 16px 16px 0 0; padding: 18px 22px 6px; margin: 14px 0 0; }
.post-body #frequently-asked-questions ~ h3 + p { background: #fff; border: 1px solid var(--post-line); border-top: 0; border-radius: 0 0 16px 16px; padding: 0 22px 18px; font-size: 16px; }
.post-body #frequently-asked-questions ~ h3 + p + p { margin-top: 2em; }

/* Tags, CTA, author */
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 36px; }
.post-tags a { font-size: 14px; color: var(--post-text); background: #f1f5f9; border-radius: 999px; padding: 6px 14px; text-decoration: none; }
.post-tags a:hover { background: var(--post-soft); color: var(--post-accent); }

.post-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 28px; background: linear-gradient(135deg, #1e0b4b, #3b1a8f 55%, #0e7490); color: #e2e8f0; border-radius: 24px; padding: 32px; margin-bottom: 24px; }
.post-cta > div:first-child { flex: 1 1 360px; }
.post-cta-kicker { font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #67e8f9; margin: 0 0 6px; }
.post-cta-title { font-family: "Sora", sans-serif; font-size: 26px; font-weight: 700; color: #fff; margin: 0 0 8px; }
.post-cta p { margin: 0; line-height: 1.6; }
.post-cta-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.post-cta-btn { background: #fff; color: #1e0b4b !important; font-weight: 700; padding: 13px 24px; border-radius: 999px; text-decoration: none; }
.post-cta-btn:hover { background: #67e8f9; }
.post-cta-link { color: #e2e8f0 !important; font-size: 15px; text-decoration: none; }

.post-author { display: flex; gap: 18px; align-items: flex-start; border: 1px solid var(--post-line); background: #fff; border-radius: 20px; padding: 22px; margin-top: 24px; }
.post-author img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.post-author-label { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--post-muted); margin: 0; }
.post-author-name { font-family: "Sora", sans-serif; font-size: 20px; font-weight: 700; color: var(--post-ink); margin: 2px 0 6px; }
.post-author p:last-child { margin: 0; font-size: 15px; line-height: 1.6; color: var(--post-text); }

/* Related */
.post-related { padding: 40px 0 80px; }
.post-related-title { font-family: "Sora", sans-serif; font-size: 28px; font-weight: 700; color: var(--post-ink); margin-bottom: 24px; }
.post-related-card { display: flex; flex-direction: column; height: 100%; background: #fff; border: 1px solid var(--post-line); border-radius: 20px; overflow: hidden; text-decoration: none; transition: transform .2s, box-shadow .2s; }
.post-related-card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px -24px rgba(15, 23, 42, .35); }
.post-related-card img { width: 100%; height: auto; aspect-ratio: 1200 / 630; object-fit: cover; }
.post-related-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 20px; flex-grow: 1; }
.post-related-cat { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--post-accent); }
.post-related-name { font-family: "Sora", sans-serif; font-size: 18px; font-weight: 700; line-height: 1.35; color: var(--post-ink); }
.post-related-more { margin-top: auto; font-size: 14px; font-weight: 700; color: var(--post-accent); }

@media (max-width: 575.98px) {
  .post-body { font-size: 17px; }
  .post-cta { padding: 24px; }
  .post-author { flex-direction: column; }
}
.post-related > .container-xl { max-width: 1100px; }
