/* ============================================================
   content.css — StackViewer SEO content pages
   Used by: /blog/*, /vs/*, /alternatives/*, /portfolio-tracker/*, /tools/*
   Load AFTER style.css, landing.css and inner-pages.css.

   Ship step: copy this file to assets/css/content.css before
   publishing the first content page. Templates reference it at
   /assets/css/content.css (root-absolute — content pages are nested).
   ============================================================ */

/* ---------- 1. Article shell ---------- */
.content-page                 { background: var(--white); }
.content-wrap                 { max-width: 760px; margin: 0 auto; padding: 60px 20px 80px; }
.content-wrap--wide           { max-width: 1040px; }

.content-body                 { font-size: 18px; line-height: 1.75; color: var(--text-body); }
.content-body > * + *         { margin-top: 24px; }
.content-body h2              { font-family: 'Poppins', sans-serif; font-size: 30px; line-height: 1.3;
                                color: var(--text-heading); margin-top: 56px; margin-bottom: 8px; font-weight: 600; }
.content-body h3              { font-family: 'Poppins', sans-serif; font-size: 22px; line-height: 1.35;
                                color: var(--text-heading); margin-top: 36px; margin-bottom: 4px; font-weight: 600; }
.content-body p               { margin: 0; }
.content-body a               { color: #111; text-decoration: underline; text-underline-offset: 3px; }
.content-body a:hover         { color: #000; }
.content-body ul,
.content-body ol              { padding-left: 22px; margin: 0; }
.content-body li + li         { margin-top: 10px; }
.content-body strong          { color: var(--text-heading); font-weight: 600; }
.content-body img             { max-width: 100%; height: auto; border-radius: 10px;
                                border: 1px solid #e6e6e6; display: block; }
.content-body figure          { margin: 0; }
.content-body figcaption      { font-size: 14px; color: var(--text-muted); margin-top: 10px; }
.content-body blockquote      { border-left: 3px solid #111; padding: 4px 0 4px 20px; margin: 0;
                                font-size: 20px; color: var(--text-heading); }

/* ---------- 2. Meta / byline ---------- */
.content-meta                 { font-size: 14px; color: var(--text-on-dark-muted); margin-top: 18px; }
.content-meta span + span::before { content: "·"; margin: 0 8px; }
.content-updated              { font-size: 14px; color: var(--text-muted); margin-bottom: 28px; }

/* ---------- 3. Breadcrumbs ---------- */
.content-breadcrumb           { font-size: 13px; color: var(--text-on-dark-muted); margin-bottom: 14px; }
.content-breadcrumb a         { color: var(--text-on-dark-muted); text-decoration: none; }
.content-breadcrumb a:hover   { color: var(--white); }
.content-breadcrumb span      { margin: 0 6px; }

/* ---------- 4. Table of contents ---------- */
.content-toc                  { background: #f7f7f7; border-radius: 12px; padding: 22px 26px; }
.content-toc h2               { font-size: 14px !important; text-transform: uppercase; letter-spacing: .06em;
                                margin: 0 0 12px !important; color: var(--text-muted); font-weight: 600; }
.content-toc ol               { margin: 0; padding-left: 18px; font-size: 16px; }
.content-toc li + li          { margin-top: 6px; }

/* ---------- 5. Key-takeaway / answer box (AI-citation target) ---------- */
.content-answer               { background: #111; color: #fff; border-radius: 12px; padding: 26px 28px; }
.content-answer p             { color: #e8e8e8; font-size: 17px; line-height: 1.65; }
.content-answer p + p         { margin-top: 12px; }
.content-answer h2            { color: #fff !important; font-size: 15px !important; text-transform: uppercase;
                                letter-spacing: .06em; margin: 0 0 12px !important; }

/* ---------- 6. Comparison tables ---------- */
.content-table-scroll         { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.content-table                { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 620px; }
.content-table th,
.content-table td             { padding: 13px 14px; text-align: left; border-bottom: 1px solid #eaeaea;
                                vertical-align: top; }
.content-table thead th       { background: #111; color: #fff; font-weight: 600; font-size: 14px;
                                border-bottom: none; white-space: nowrap; }
.content-table tbody tr:nth-child(even) { background: #fafafa; }
.content-table td:first-child { font-weight: 600; color: var(--text-heading); }
.content-table .yes           { color: #1a7f4b; font-weight: 600; }
.content-table .no            { color: #b23b3b; font-weight: 600; }
.content-table .partial       { color: #a07400; font-weight: 600; }

/* ---------- 7. Verdict / who-it's-for cards ---------- */
.verdict-grid                 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.verdict-card                 { border: 1px solid #e6e6e6; border-radius: 12px; padding: 24px; background: #fff; }
.verdict-card h3              { margin-top: 0 !important; font-size: 19px !important; }
.verdict-card ul              { font-size: 16px; }
.verdict-card--ours           { border-color: #111; border-width: 2px; }
@media (max-width: 700px)     { .verdict-grid { grid-template-columns: 1fr; } }

/* ---------- 8. CTA blocks ---------- */
.content-cta                  { background: #111; border-radius: 14px; padding: 36px 34px; text-align: center;
                                margin: 56px 0 0; }
.content-cta h2               { color: #fff !important; margin: 0 0 10px !important; font-size: 26px !important; }
.content-cta p                { color: #b8b8b8; font-size: 16px; margin: 0 0 22px; }
.content-cta .btn-content-cta { display: inline-block; background: #fff; color: #111; border: none;
                                border-radius: 8px; padding: 14px 30px; font-weight: 600; font-size: 16px;
                                text-decoration: none; cursor: pointer; transition: opacity .2s; }
.content-cta .btn-content-cta:hover  { opacity: .85; color: #111; }
.content-cta .btn-content-ghost      { display: inline-block; margin-left: 12px; color: #fff; font-size: 15px;
                                text-decoration: underline; text-underline-offset: 3px; }
.content-cta .btn-content-ghost:hover{ color: #fff; opacity: .8; }
.content-cta-note             { color: #8a8a8a; font-size: 13px; margin: 16px 0 0; }
@media (max-width: 560px)     { .content-cta .btn-content-ghost { display: block; margin: 16px 0 0; } }

/* Inline mid-article CTA — lighter weight than the closing block */
.content-cta-inline           { border-left: 3px solid #111; background: #f7f7f7; border-radius: 0 10px 10px 0;
                                padding: 20px 24px; font-size: 16px; }
.content-cta-inline p         { margin: 0; }

/* ---------- 9. FAQ ---------- */
.content-faq dt               { font-family: 'Poppins', sans-serif; font-weight: 600; font-size: 18px;
                                color: var(--text-heading); margin-top: 26px; }
.content-faq dd               { margin: 8px 0 0; }

/* ---------- 10. Broker-page specifics ---------- */
.broker-hero-logo             { height: 44px; width: auto; margin-bottom: 18px; }
.sync-grid                    { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.sync-card                    { border: 1px solid #e6e6e6; border-radius: 10px; padding: 18px 20px; }
.sync-card h3                 { margin: 0 0 6px !important; font-size: 16px !important; }
.sync-card p                  { font-size: 15px; }

/* ---------- 11. Tool pages ---------- */
.tool-panel                   { background: #f7f7f7; border-radius: 14px; padding: 30px; }
.tool-field                   { margin-bottom: 18px; }
.tool-field label             { display: block; font-size: 14px; font-weight: 600; color: var(--text-heading);
                                margin-bottom: 6px; }
.tool-field input,
.tool-field select            { width: 100%; padding: 12px 14px; border: 1px solid #d8d8d8; border-radius: 8px;
                                font-size: 16px; background: #fff; }
.tool-field .hint             { font-size: 13px; color: var(--text-muted); margin-top: 5px; }
.tool-result                  { background: #111; color: #fff; border-radius: 12px; padding: 28px 30px;
                                margin-top: 24px; }
.tool-result .tool-figure     { font-family: 'Poppins', sans-serif; font-size: 44px; font-weight: 600;
                                line-height: 1.1; }
.tool-result .tool-caption    { color: #b8b8b8; font-size: 15px; margin-top: 8px; }
.tool-actions                 { margin-top: 18px; display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- 12. Index / hub pages ---------- */
.card-grid                    { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }
.content-card                 { border: 1px solid #e6e6e6; border-radius: 12px; padding: 24px; background: #fff;
                                text-decoration: none; display: block; transition: border-color .2s, transform .2s; }
.content-card:hover           { border-color: #111; transform: translateY(-2px); }
.content-card .card-kicker    { font-size: 12px; text-transform: uppercase; letter-spacing: .07em;
                                color: var(--text-muted); }
.content-card h3              { font-family: 'Poppins', sans-serif; font-size: 19px; color: var(--text-heading);
                                margin: 8px 0; font-weight: 600; }
.content-card p               { font-size: 15px; color: var(--text-body); margin: 0; }

/* ---------- 13. Related posts ---------- */
.content-related              { border-top: 1px solid #eaeaea; margin-top: 60px; padding-top: 34px; }
.content-related h2           { font-size: 15px !important; text-transform: uppercase; letter-spacing: .06em;
                                color: var(--text-muted); margin: 0 0 18px !important; }

/* ---------- 14. Disclaimer ---------- */
.content-disclaimer           { margin-top: 48px; padding-top: 22px; border-top: 1px solid #eaeaea;
                                font-size: 13px; line-height: 1.6; color: var(--text-muted); }

/* ---------- 15. Author box ---------- */
.content-author               { display: flex; gap: 16px; align-items: flex-start; background: #f7f7f7;
                                border-radius: 12px; padding: 22px 24px; margin-top: 44px; }
.content-author img           { width: 54px; height: 54px; border-radius: 50%; flex: 0 0 54px; border: none; }
.content-author p             { font-size: 15px; margin: 0; }
.content-author .author-name  { font-weight: 600; color: var(--text-heading); }

@media (max-width: 700px) {
  .content-wrap               { padding: 40px 18px 60px; }
  .content-body               { font-size: 17px; }
  .content-body h2            { font-size: 25px; margin-top: 44px; }
  .content-cta                { padding: 28px 22px; }
}

/* ============================================================
   16. Figures, diagrams and visual breaks
   Added 10 Sep 2026. Diagrams are hand-authored inline SVG:
   no libraries, no external images, no runtime.
   ============================================================ */

.content-figure                 { margin: 44px 0; }
.content-figure svg             { display: block; width: 100%; height: auto; }
.content-figure figcaption      { font-size: 14px; line-height: 1.6; color: var(--text-muted);
                                  margin-top: 14px; }
.content-figure figcaption b    { color: var(--text-heading); font-weight: 600; }

/* Diagram frame. `color` drives every currentColor stroke inside the SVG. */
.diagram                        { background: #fff; border: 1px solid #e8e8e8; border-radius: 14px;
                                  padding: 30px 28px; color: #111; }
.diagram--tint                  { background: #fafafa; }
.diagram text                   { font-family: 'Poppins', system-ui, sans-serif; }

/* Product screenshots are a dark UI — frame them so they don't float on white */
.screenshot                     { background: #111; border-radius: 14px; padding: 12px;
                                  border: 1px solid #111; }
.screenshot img                 { display: block; border-radius: 8px; border: none; width: 100%; height: auto; }

/* Pull quote — one sentence, used to break a long stretch of prose */
.pull-quote                     { margin: 44px 0; padding: 0 0 0 26px; border-left: 3px solid #111; }
.pull-quote p                   { font-family: 'Poppins', system-ui, sans-serif; font-size: 23px;
                                  line-height: 1.45; color: var(--text-heading); margin: 0; font-weight: 500; }
.pull-quote cite                { display: block; font-size: 14px; color: var(--text-muted);
                                  font-style: normal; margin-top: 10px; }

/* Labelled callout — "the rule", "worked example", "watch out" */
.callout                        { margin: 36px 0; border: 1px solid #e8e8e8; border-left: 3px solid #111;
                                  border-radius: 0 12px 12px 0; padding: 22px 26px; background: #fafafa; }
.callout > .callout-label       { display: block; font-size: 12px; font-weight: 600; letter-spacing: .08em;
                                  text-transform: uppercase; color: var(--text-muted); margin-bottom: 10px; }
.callout p                      { margin: 0; font-size: 16.5px; }
.callout p + p                  { margin-top: 12px; }
.callout--warn                  { border-left-color: #b23b3b; }
.callout--warn > .callout-label { color: #b23b3b; }

/* Verified-fact tiles. Only ever used for facts checked against the codebase. */
.stat-row                       { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
                                  gap: 14px; margin: 36px 0; }
.stat-tile                      { border: 1px solid #e8e8e8; border-radius: 12px; padding: 18px 20px;
                                  background: #fff; }
.stat-tile .stat-figure         { font-family: 'Poppins', system-ui, sans-serif; font-size: 30px;
                                  font-weight: 600; color: var(--text-heading); line-height: 1.1; }
.stat-tile .stat-label          { font-size: 13.5px; color: var(--text-muted); margin-top: 6px; display: block;
                                  line-height: 1.4; }

@media (max-width: 700px) {
  .diagram                      { padding: 20px 14px; border-radius: 12px; }
  .pull-quote p                 { font-size: 20px; }
  .content-figure               { margin: 34px 0; }
}

/* Broker logos on the directory cards */
.content-card .card-logo        { height: 24px; width: auto; max-width: 120px; display: block;
                                  margin: 0 0 14px; border: none; border-radius: 0; }
.content-card .card-logo-pad    { height: 24px; margin-bottom: 14px; }

/* ============================================================
   17. Stronger separation between sections
   Added 10 Sep 2026. Every top-level H2 in an article body now
   opens with a visible rule and a short accent bar, so the page
   reads as distinct sections rather than one continuous column.
   Boxed H2s (answer box, contents, CTA, related) are nested and
   deliberately excluded by the direct-child selector.
   ============================================================ */

.content-body > h2              { position: relative; border-top: 1px solid #d8d8d8;
                                  margin-top: 68px; padding-top: 40px; }
.content-body > h2::before      { content: ""; position: absolute; top: -2px; left: 0;
                                  width: 52px; height: 3px; background: #111; }
.content-body > h2:first-child  { border-top: none; margin-top: 0; padding-top: 0; }
.content-body > h2:first-child::before { display: none; }

/* Hairlines everywhere else, one step darker */
.content-table th,
.content-table td               { border-bottom: 1px solid #dcdcdc; }
.content-table                  { border-bottom: 2px solid #111; }
.content-related,
.content-disclaimer             { border-top: 1px solid #d8d8d8; }
.diagram                        { border: 1px solid #dcdcdc; }
.callout,
.stat-tile,
.content-card,
.verdict-card,
.sync-card                      { border-color: #dfdfdf; }
.content-toc                    { border: 1px solid #e4e4e4; }

@media (max-width: 700px) {
  .content-body > h2            { margin-top: 52px; padding-top: 30px; }
}

/* A little more air between paragraphs now that sections are ruled */
.content-body > * + *           { margin-top: 28px; }
.content-body > h3              { margin-top: 46px; }

/* ============================================================
   18. Blog index — visual post grid
   Cards carry a hand-drawn thumbnail so the index scans as
   pictures, not paragraphs. Added 10 Sep 2026.
   ============================================================ */

/* Cards are links inside .content-body — cancel the body underline.
   Needs `.content-body a.x` to outrank the `.content-body a` rule above. */
.content-body a.post-card,
.content-body a.content-card,
.content-body a.post-card:hover,
.content-body a.content-card:hover { text-decoration: none; }
.post-card *, .content-card * { text-decoration: inherit; }

/* --- cluster filter --- */
.cluster-filter                 { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 34px;
                                  padding-bottom: 28px; border-bottom: 1px solid #d8d8d8; }
.cluster-chip                   { font: 500 13px/1 'Poppins', system-ui, sans-serif; color: var(--text-body);
                                  background: #fff; border: 1px solid #dcdcdc; border-radius: 999px;
                                  padding: 9px 16px; cursor: pointer; transition: all .15s; }
.cluster-chip:hover             { border-color: #111; color: #111; }
.cluster-chip[aria-pressed="true"] { background: #111; border-color: #111; color: #fff; }

/* --- grid --- */
.post-grid                      { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
                                  gap: 26px; margin: 0; }
.post-card                      { display: flex; flex-direction: column; overflow: hidden;
                                  border: 1px solid #dcdcdc; border-radius: 14px; background: #fff;
                                  transition: border-color .18s, transform .18s, box-shadow .18s; }
.post-card:hover                { border-color: #111; transform: translateY(-3px);
                                  box-shadow: 0 10px 26px rgba(0,0,0,.07); }
.post-card .post-thumb          { display: block; background: #fafafa; border-bottom: 1px solid #ececec;
                                  padding: 0; line-height: 0; }
.post-card .post-thumb svg      { display: block; width: 100%; height: auto; color: #111; }
.post-card .post-text           { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.post-card .post-kicker         { font-size: 11.5px; font-weight: 600; text-transform: uppercase;
                                  letter-spacing: .08em; color: var(--text-muted); }
.post-card h3                   { font-family: 'Poppins', system-ui, sans-serif; font-size: 18.5px;
                                  line-height: 1.32; font-weight: 600; color: var(--text-heading);
                                  margin: 9px 0 10px; }
.post-card p                    { font-size: 14.5px; line-height: 1.55; color: var(--text-body); margin: 0;
                                  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
                                  overflow: hidden; }
.post-card .post-more           { margin-top: auto; padding-top: 16px; font-size: 13.5px; font-weight: 600;
                                  color: #111; }
.post-card:hover .post-more     { text-decoration: underline; text-underline-offset: 3px; }

/* --- featured lead post --- */
.post-card--featured            { grid-column: 1 / -1; flex-direction: row; align-items: stretch; }
.post-card--featured .post-thumb{ flex: 0 0 42%; border-bottom: none; border-right: 1px solid #ececec;
                                  display: flex; align-items: center; padding: 18px; }
.post-card--featured .post-text { padding: 34px 36px; justify-content: center; }
.post-card--featured h3         { font-size: 27px; line-height: 1.25; margin: 12px 0 12px; }
.post-card--featured p          { font-size: 16px; -webkit-line-clamp: 4; }
@media (max-width: 780px) {
  .post-card--featured          { flex-direction: column; }
  .post-card--featured .post-thumb { flex: none; border-right: none; border-bottom: 1px solid #ececec; padding: 0; }
  .post-card--featured .post-text  { padding: 22px; }
  .post-card--featured h3       { font-size: 22px; }
}
.post-empty                     { display: none; padding: 40px 0; color: var(--text-muted); font-size: 15px; }
