/**
 * Flashtech Knowledge Base article styling.
 *
 * Matches the new blog's visual language (reading width, typography, heading hierarchy, figures,
 * captions, CTA buttons — mirrors Magefan_Blog/web/css/blog-custom.css) and adds technical
 * installation-guide components (table of contents, callouts, step galleries, FAQ).
 *
 * SCOPED to .flashtech-kb-article so it can never affect other pages, and loaded ONLY on KB
 * article pages via app/design/frontend/Sm/autostore/Mirasvit_Kb/layout/kbase_article_view.xml.
 * Reusable across every Knowledge Base guide — new articles just use these classes.
 */

.flashtech-kb-article {
    max-width: 820px;      /* comfortable measure, close to the blog's 760px; diagrams still fill it */
    margin: 0 auto;
    color: #2c2c2c;
    font-size: 17px;
    line-height: 1.75;
    word-wrap: break-word;
}
.flashtech-kb-article img { max-width: 100%; height: auto; }
.flashtech-kb-article p { margin: 0 0 1.15em; }
.flashtech-kb-article a { color: #d81f26; text-decoration: underline; }
.flashtech-kb-article strong { color: #111; }

/* Heading hierarchy — blog sizing, with a restrained brand-red rule for the technical feel.
 * The page title is the H1 (Mirasvit renders it); the article body uses H2/H3 only. */
.flashtech-kb-article h2 {
    font-size: 27px; line-height: 1.25; font-weight: 700; color: #111;
    margin: 2em 0 .6em; padding-bottom: .3em; border-bottom: 2px solid #d81f26;
    scroll-margin-top: 20px;
}
.flashtech-kb-article h3 {
    font-size: 20px; font-weight: 700; color: #111; margin: 1.7em 0 .4em; scroll-margin-top: 20px;
}
.flashtech-kb-article ul, .flashtech-kb-article ol { margin: 0 0 1.35em 1.3em; padding: 0; }
.flashtech-kb-article li { margin: .35em 0; }

/* Lead image + lead paragraph */
.flashtech-kb-article .kb-hero { margin: 0 0 1.3em; text-align: center; }
.flashtech-kb-article .kb-hero img { border-radius: 8px; max-width: 560px; }
.flashtech-kb-article .kb-lead { font-size: 19px; line-height: 1.6; }

/* Shop buttons (top row) — mirrors the blog's .ft-cta button */
.flashtech-kb-article .kb-cta-buttons { margin: 0 0 1.4em; }
.flashtech-kb-article a.kb-btn {
    display: inline-block; background: #d81f26; color: #fff; text-decoration: none;
    font-weight: 700; font-size: 15px; padding: 12px 22px; border-radius: 6px;
    margin: 5px 10px 5px 0; transition: background .15s;
}
.flashtech-kb-article a.kb-btn:hover { background: #b0161c; color: #fff; }

/* Callouts: note (brand red), warning (amber), tip (green) */
.flashtech-kb-article .kb-note,
.flashtech-kb-article .kb-warning,
.flashtech-kb-article .kb-tip {
    padding: 15px 18px; margin: 1.5em 0; border-left: 4px solid #999;
    background: #f6f6f6; border-radius: 0 6px 6px 0;
}
.flashtech-kb-article .kb-note    { border-left-color: #d81f26; background: #f7f7f7; }
.flashtech-kb-article .kb-warning { border-left-color: #e5a400; background: #fff8e6; }
.flashtech-kb-article .kb-tip     { border-left-color: #2e9c4a; background: #eef9f0; }
.flashtech-kb-article .kb-note p:last-child,
.flashtech-kb-article .kb-warning p:last-child,
.flashtech-kb-article .kb-tip p:last-child { margin-bottom: 0; }

/* Table of contents / quick navigation */
.flashtech-kb-article .kb-toc {
    border: 1px solid #e3e3e3; border-radius: 8px; background: #fafafa;
    padding: 16px 20px; margin: 1.6em 0 2em;
}
.flashtech-kb-article .kb-toc__title {
    font-weight: 700; color: #111; margin: 0 0 .5em; font-size: 14px;
    text-transform: uppercase; letter-spacing: .04em;
}
.flashtech-kb-article .kb-toc ul { columns: 2; column-gap: 34px; margin: 0 0 0 1.1em; padding: 0; }
.flashtech-kb-article .kb-toc li { margin: .3em 0; }

/* Figures + captions (blog style) */
.flashtech-kb-article figure { margin: 1.6em 0; text-align: center; }
.flashtech-kb-article figure img { border-radius: 8px; }
.flashtech-kb-article figcaption { font-size: 14px; color: #777; margin-top: .5em; }

/* Two-up image gallery — collapses to one column on mobile */
.flashtech-kb-article .kb-gallery { display: flex; gap: 20px; flex-wrap: wrap; margin: 1.6em 0; }
.flashtech-kb-article .kb-gallery figure { flex: 1 1 280px; margin: 0; }

/* FAQ */
.flashtech-kb-article .kb-faq h3 { font-size: 19px; margin: 1.4em 0 .3em; }

/* Bottom product CTA (dark panel) */
.flashtech-kb-article .kb-cta {
    background: #111; color: #fff; padding: 26px 28px; border-radius: 8px; margin: 2.4em 0 1em;
}
.flashtech-kb-article .kb-cta h2 { color: #fff; border: 0; padding: 0; margin: 0 0 .4em; font-size: 26px; }
.flashtech-kb-article .kb-cta p:last-child { margin-bottom: 0; }
.flashtech-kb-article .kb-cta a { color: #fff; text-decoration: underline; }
/* the CTA links are wrapped in <strong>; without this the body's dark strong color would render
   the link text black-on-black (invisible). Keep all text in the dark panel white. */
.flashtech-kb-article .kb-cta,
.flashtech-kb-article .kb-cta strong,
.flashtech-kb-article .kb-cta a strong { color: #fff; }

/* Responsive: single column below 600px */
@media (max-width: 600px) {
    .flashtech-kb-article { font-size: 16px; }
    .flashtech-kb-article h2 { font-size: 23px; }
    .flashtech-kb-article h3 { font-size: 19px; }
    .flashtech-kb-article .kb-toc ul { columns: 1; }
    .flashtech-kb-article .kb-gallery { gap: 14px; }
}
