/* ==========================================================
   Blog article styles
   Scope: <main id="app"> <article> ... </article> </main>

   NOTE: your theme sets html { font-size: 62.5% }, so 1rem = 10px.
   This file therefore uses px (and em) only, never rem.
   Tune the look by editing the variables below.
   ========================================================== */

#app article {
    /* ---- Easy settings ---- */
    --a-font-size: 16px;                 /* body text, desktop */
    --a-font-size-mobile: 16px;          /* body text, phones */
    --a-line-height: 1.75;
    --a-max-width: 720px;
    --a-line-color: rgba(128, 128, 128, 0.3);
    --a-table-border: rgba(128, 128, 128, 0.35);
    --a-table-head-bg: rgba(128, 128, 128, 0.12);
    --a-table-stripe-bg: rgba(128, 128, 128, 0.05);
    --a-btn-bg: #222222;                 /* CTA button color: change to your brand color */
    --a-btn-text: #ffffff;

    max-width: var(--a-max-width);
    margin: 0 auto;
    padding: 24px 16px 64px;
    font-size: var(--a-font-size);
    line-height: var(--a-line-height);
    overflow-wrap: break-word;
}

/* Optional: a more readable body font than a thin display serif.
   Uncomment to use. Headings keep your theme's font.
#app article p,
#app article li,
#app article td,
#app article th {
  font-family: Georgia, "Times New Roman", serif;
}
*/

/* ---------- Headings ---------- */
#app article h1 {
    font-size: 28px;
    line-height: 1.25;
    margin: 0 0 16px;
}
#app article h2 {
    font-size: 21px;
    line-height: 1.3;
    margin: 36px 0 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--a-line-color);
}
#app article h3 {
    font-size: 18px;
    line-height: 1.35;
    margin: 24px 0 6px;
}

/* ---------- Paragraphs and text ---------- */
#app article p {
    margin: 0 0 1.1em;
    font-size: 1em;
    line-height: inherit;
}
#app article strong {
    font-weight: 700;
}
#app article a {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ---------- Lists (restores bullets/numbers that themes often reset) ---------- */
#app article ul,
#app article ol {
    margin: 0 0 1.3em;
    padding-left: 1.6em;
}
#app article ul {
    list-style: disc outside;
}
#app article ol {
    list-style: decimal outside;
}
#app article ul ul {
    list-style-type: circle;
}
#app article li {
    display: list-item;
    margin: 0 0 0.55em;
    padding-left: 0.2em;
    font-size: 1em;
    line-height: inherit;
}
#app article li > ul,
#app article li > ol {
    margin-top: 0.5em;
    margin-bottom: 0.3em;
}

/* ---------- Tables ---------- */
#app article .table-wrap {
    overflow-x: auto;
    margin: 0 0 1.6em;
    -webkit-overflow-scrolling: touch;
}
#app article table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95em;
    line-height: 1.55;
}
#app article table td:first-child,
#app article table th:first-child {
    width: 22%;
    white-space: nowrap;
}

/* Only wider tables (3+ columns) get a minimum width and scroll on phones */
#app article table:has(th:nth-child(3)) {
    min-width: 520px;
}
#app article th,
#app article td {
    border: 1px solid var(--a-table-border);
    padding: 9px 13px;
    text-align: left;
    vertical-align: top;
    font-size: 1em;
}
#app article thead th {
    background: var(--a-table-head-bg);
    font-weight: 700;
}
#app article tbody tr:nth-child(even) td {
    background: var(--a-table-stripe-bg);
}
/* Tables pasted without the .table-wrap div still scroll safely */
#app article > table {
    display: block;
    overflow-x: auto;
    margin-bottom: 1.6em;
}

/* ---------- Images ---------- */
#app article img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 24px auto;
}
#app article figure {
    margin: 28px 0;
}
#app article figcaption {
    margin-top: 8px;
    font-size: 0.85em;
    text-align: center;
    opacity: 0.75;
}

/* ---------- Quotes and dividers ---------- */
#app article blockquote {
    margin: 28px 0;
    padding: 4px 0 4px 20px;
    border-left: 4px solid var(--a-line-color);
}
#app article hr {
    border: 0;
    border-top: 1px solid var(--a-line-color);
    margin: 40px 0;
}

/* ---------- Call to action and related links ---------- */
#app article p.cta {
    margin: 36px 0 18px;
}
#app article p.cta a {
    display: inline-block;
    padding: 12px 26px;
    border-radius: 4px;
    background: var(--a-btn-bg);
    color: var(--a-btn-text);
    font-size: 0.95em;
    font-weight: 700;
    text-decoration: none;
}
#app article p.cta a:hover,
#app article p.cta a:focus {
    opacity: 0.75;
}
#app article p.related {
    font-size: 0.92em;
    padding-top: 16px;
    border-top: 1px solid var(--a-line-color);
}

/* ---------- Mobile ---------- */
@media (max-width: 600px) {
    #app article {
        font-size: var(--a-font-size-mobile);
        padding: 16px 14px 48px;
    }
    #app article h1 { font-size: 24px; }
    #app article h2 { font-size: 20px; margin-top: 30px; }
    #app article h3 { font-size: 17px; }
    #app article th,
    #app article td { padding: 8px 10px; }
}
