/* Buyer guides on the blog (pricing, platform and channel guides).
   Adds the parts a reader expects from a long guide: published and updated dates,
   key takeaways, a contents list, worked examples, a dated sources list and one closing call.
   White surfaces, hairline borders, brand blue (#2563eb) as the only accent. */

.article-meta-bar time { font-variant-numeric: tabular-nums; }
.article-meta-bar .ck-updated { color: #2563eb; font-weight: 500; }

/* Key takeaways */
.ck-takeaways {
    margin: 0 0 2.4rem;
    padding: 1.5rem 1.6rem 1.2rem;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #fff;
}
.ck-guide-kicker {
    margin: 0 0 .9rem !important;
    color: #2563eb;
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
}
.article-body .ck-takeaways ul { margin: 0; padding: 0; list-style: none; }
.article-body .ck-takeaways li {
    position: relative;
    margin: 0 0 .75rem;
    padding-left: 1.7rem;
    font-size: 1rem;
    line-height: 1.65;
    color: #1e293b;
}
.article-body .ck-takeaways li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .42em;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background: #2563eb url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2 7 10.6l4.6-5' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}

/* Contents */
.ck-toc {
    margin: 0 0 2.8rem;
    padding: 1.3rem 1.6rem 1rem;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
}
.article-body .ck-toc ol {
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: toc;
    columns: 2;
    column-gap: 2rem;
}
.article-body .ck-toc li {
    counter-increment: toc;
    break-inside: avoid;
    margin: 0 0 .55rem;
    font-size: .98rem;
    line-height: 1.45;
}
.article-body .ck-toc li::before {
    content: counter(toc, decimal-leading-zero);
    display: inline-block;
    min-width: 1.9rem;
    color: #94a3b8;
    font-size: .82rem;
    font-variant-numeric: tabular-nums;
}
.ck-toc a { color: #111111; text-decoration: none; }
.ck-toc a:hover { color: #2563eb; text-decoration: underline; text-underline-offset: 3px; }
.article-body h2[id], .article-body h3[id] { scroll-margin-top: 96px; }

/* Wide tables scroll inside their own box on phones */
.ck-table-wrap { margin: 2rem 0; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.ck-table-wrap .article-table { margin: 0; min-width: 560px; }
.article-table caption { caption-side: bottom; padding-top: .7rem; color: #64748b; font-size: .85rem; text-align: left; }
.article-table td { vertical-align: top; }

/* Worked examples */
.ck-examples { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 2rem 0 2.2rem; }
.ck-example {
    padding: 1.3rem 1.4rem 1.2rem;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #fff;
}
.article-body .ck-example h3 { margin: 0 0 .5rem; font-size: 1.2rem; }
.article-body .ck-example p { margin: 0 0 .7rem; font-size: .96rem; line-height: 1.6; }
.ck-example dl { display: grid; grid-template-columns: auto 1fr; gap: .35rem 1rem; margin: 0 0 .8rem; font-size: .95rem; }
.ck-example dt { color: #64748b; }
.ck-example dd { margin: 0; color: #111111; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ck-example .ck-total { display: flex; justify-content: space-between; gap: 1rem; padding-top: .7rem; border-top: 1px solid #e2e8f0; font-weight: 600; color: #111111; font-variant-numeric: tabular-nums; }
.ck-example .ck-total span:last-child { color: #2563eb; }

/* Short notes in the flow (method, caveats) */
.ck-note {
    margin: 2rem 0;
    padding: 1.1rem 1.3rem;
    border-left: 3px solid #2563eb;
    background: #fff;
    border-radius: 0 12px 12px 0;
    box-shadow: inset 0 0 0 1px #e2e8f0;
}
.article-body .ck-note p { margin: 0; font-size: .97rem; line-height: 1.65; color: #334155; }

/* Diagram (inline SVG) */
.ck-figure { margin: 2.2rem 0 2.4rem; }
.ck-figure svg { display: block; width: 100%; height: auto; }
.ck-figure figcaption { margin-top: .7rem; color: #64748b; font-size: .88rem; line-height: 1.5; }

/* Sources */
.ck-sources { margin: 3rem 0 0; padding-top: 1.6rem; border-top: 1px solid #e2e8f0; }
.article-body .ck-sources h2 { margin-top: 0; font-size: 1.35rem; }
.article-body .ck-sources p, .article-body .ck-sources li { font-size: .92rem; line-height: 1.6; color: #475569; }
.article-body .ck-sources ol { padding-left: 1.2rem; }

/* Closing call */
.ck-guide-cta {
    margin: 3rem 0 0;
    padding: 1.8rem 1.8rem 1.6rem;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    background: #fff;
}
.article-body .ck-guide-cta h2 { margin: 0 0 .6rem; font-size: 1.6rem; }
.article-body .ck-guide-cta p { margin: 0 0 1.2rem; font-size: 1rem; }
.ck-guide-cta .ck-cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.ck-guide-cta a.ck-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: 999px;
    background: #2563eb;
    color: #fff !important;
    font-size: .95rem;
    font-weight: 600;
    text-decoration: none !important;
}
.ck-guide-cta a.ck-btn.is-quiet { background: #fff; color: #2563eb !important; box-shadow: inset 0 0 0 1px #bfdbfe; }

@media (max-width: 767px) {
    .article-body .ck-toc ol { columns: 1; }
    .ck-examples { grid-template-columns: 1fr; }
    .ck-takeaways, .ck-guide-cta { padding: 1.2rem 1.1rem 1rem; }
    .ck-toc { padding: 1.1rem 0 .8rem; }
    .article-body .ck-takeaways li { font-size: .98rem; }
}

/* Flow diagram in HTML (readable at any width): channels -> one system of record -> operations */
.ck-flow { display: grid; grid-template-columns: 1fr 28px 1fr 28px 1fr; align-items: stretch; gap: 0; margin: 2.2rem 0 2.4rem; }
.ck-flow-col { padding: 1.1rem 1.1rem .9rem; border: 1px solid #e2e8f0; border-radius: 16px; background: #fff; }
.ck-flow-col.is-hub { border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37, 99, 235, .08); }
.article-body .ck-flow-head { margin: 0 0 .6rem; color: #111111; font-size: .95rem; font-weight: 600; }
.ck-flow-col.is-hub .ck-flow-head { color: #2563eb; }
.article-body .ck-flow-col ul { margin: 0; padding: 0; list-style: none; }
.article-body .ck-flow-col li { margin: 0 0 .4rem; padding: .35rem .6rem; border-radius: 8px; background: #f6f8fb; color: #334155; font-size: .9rem; line-height: 1.35; }
.article-body .ck-flow-note { margin: .6rem 0 0; color: #64748b; font-size: .82rem; }
.ck-flow-arrow { position: relative; }
.ck-flow-arrow::before { content: ""; position: absolute; left: 4px; right: 8px; top: 50%; height: 2px; background: #2563eb; }
.ck-flow-arrow::after { content: ""; position: absolute; right: 4px; top: calc(50% - 5px); border: 6px solid transparent; border-left: 8px solid #2563eb; border-right: 0; }
.ck-flow figcaption { grid-column: 1 / -1; }
@media (max-width: 767px) {
    .ck-flow { grid-template-columns: 1fr; }
    .ck-flow-arrow { height: 30px; }
    .ck-flow-arrow::before { left: 50%; right: auto; top: 4px; bottom: 9px; width: 2px; height: auto; }
    .ck-flow-arrow::after { left: calc(50% - 5px); right: auto; top: auto; bottom: 2px; border: 6px solid transparent; border-top: 8px solid #2563eb; border-bottom: 0; }
}
