/*
 * Pinpraise blog (/blog/): loaded after landing.css, on the blog pages only.
 * Pages are written by deploy/blog/build.py. Colours come from landing.css tokens,
 * so both themes and the site owner's colour theme work without anything here.
 */

/* The article column: the static pages' column (.ld-legal), with a reading measure. */
.ld-post { max-width: 760px; }
.ld-post h1 { font-size: clamp(28px, 4.2vw, 40px); line-height: 1.12; margin-bottom: 14px; }
.ld-post h2 { border-top: 0; padding-top: 0; margin: 40px 0 12px; font-size: 24px; line-height: 1.2; scroll-margin-top: 84px; }
.ld-post h3 { font-size: 18px; margin: 26px 0 8px; line-height: 1.3; }
.ld-post p, .ld-post li { font-size: 17px; line-height: 1.7; }
.ld-post ol { padding-left: 24px; margin: 10px 0; }
.ld-post ol + p, .ld-post p + ol, .ld-post blockquote + p, .ld-post p + blockquote, .ld-post .ld-post-table + p { margin-top: 12px; }
.ld-post-lead { font-size: 19px !important; color: var(--text); }

.ld-crumbs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 18px; padding: 0; list-style: none; font-size: 14px; font-weight: 700; color: var(--muted); }
.ld-crumbs li { font-size: 14px; margin: 0; color: var(--muted); }
.ld-crumbs li + li { margin-top: 0; }
.ld-crumbs li + li::before { content: "\203A"; margin-right: 6px; color: var(--muted); }
.ld-crumbs a { text-decoration: none; }
.ld-crumbs a:hover { text-decoration: underline; }

.ld-post-meta { color: var(--muted); font-size: 14px !important; font-weight: 600; margin: 0 0 28px; }

/* Scripts, message templates and example replies. */
.ld-post blockquote { margin: 14px 0; padding: 14px 18px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: var(--r-sm); }
.ld-post blockquote p { font-size: 16px; line-height: 1.6; margin: 0; }
.ld-post blockquote p + p { margin-top: 8px; }

.ld-post-table { overflow-x: auto; margin: 16px 0; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.ld-post-table table { width: 100%; border-collapse: collapse; font-size: 15px; }
.ld-post-table th, .ld-post-table td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.ld-post-table th { font-weight: 800; background: var(--surface-2); white-space: nowrap; }
.ld-post-table tr:last-child td { border-bottom: 0; }

.ld-toc { margin: 0 0 8px; padding: 16px 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.ld-toc strong { display: block; font-size: 14px; margin-bottom: 6px; }
.ld-toc ol { margin: 0; padding-left: 20px; }
.ld-toc li { font-size: 15px; line-height: 1.5; }
.ld-toc li + li { margin-top: 4px; }
.ld-toc a { text-decoration: none; font-weight: 600; }
.ld-toc a:hover { text-decoration: underline; }

.ld-post-cta { margin: 44px 0 0; padding: 24px; background: var(--brand-soft); border-radius: var(--r-lg); }
.ld-post-cta h2 { margin: 0 0 8px; font-size: 22px; color: var(--brand-soft-text); }
.ld-post-cta p { color: var(--brand-soft-text); font-size: 16px; margin: 0 0 16px; }
.ld-post-cta .ld-btn { text-decoration: none; }
.ld-post-cta small { display: block; margin-top: 10px; font-size: 13px; color: var(--brand-soft-text); }

.ld-related { margin-top: 44px; padding-top: 28px; border-top: 1px solid var(--line); }
.ld-related h2 { margin: 0 0 14px; font-size: 20px; }
.ld-related ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.ld-related li { margin: 0; }
.ld-related li + li { margin-top: 0; }
.ld-related a { display: block; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); font-weight: 700; text-decoration: none; color: var(--text); font-size: 16px; line-height: 1.35; }
.ld-related a:hover { border-color: var(--brand); color: var(--brand-hover); }

/* The index: /blog/ */
.ld-blog { max-width: 1120px; margin: 0 auto; padding: 56px 20px 88px; }
.ld-blog-head { max-width: 720px; margin-bottom: 28px; }
.ld-blog-head h1 { font-size: clamp(30px, 4vw, 42px); font-weight: 800; margin-bottom: 12px; }
.ld-blog-head p { color: var(--muted); font-size: 18px; margin: 0; }
.ld-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 8px; padding: 0; list-style: none; }
.ld-chips a { display: inline-flex; align-items: center; min-height: 36px; padding: 6px 14px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); color: var(--text); font-weight: 700; font-size: 14px; }
.ld-chips a:hover { border-color: var(--brand); color: var(--brand-hover); }
.ld-blog-group { margin-top: 44px; scroll-margin-top: 84px; }
.ld-blog-group h2 { font-size: 24px; font-weight: 800; margin-bottom: 16px; }
.ld-blog-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; list-style: none; margin: 0; padding: 0; }
.ld-blog-card { display: flex; flex-direction: column; height: 100%; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-sm); color: var(--text); }
.ld-blog-card:hover { border-color: var(--brand); text-decoration: none; }
.ld-blog-card h3 { font-size: 18px; line-height: 1.3; font-weight: 800; margin-bottom: 8px; letter-spacing: -.01em; }
.ld-blog-card:hover h3 { color: var(--brand-hover); }
.ld-blog-card p { color: var(--muted); font-size: 15px; line-height: 1.55; margin: 0 0 14px; }
.ld-blog-card span { margin-top: auto; font-size: 13px; font-weight: 700; color: var(--muted); }

@media (max-width: 960px) { .ld-blog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
    .ld-blog { padding: 36px 16px 64px; }
    .ld-blog-grid { grid-template-columns: minmax(0, 1fr); }
    .ld-post h2 { font-size: 22px; }
    .ld-post-cta { padding: 20px; }
    .ld-post-cta .ld-btn { width: 100%; justify-content: center; text-align: center; }
    .ld-chips a { min-height: 40px; }
}

/* Subject pages (/blog/category-*.html) and the "all posts" line under each subject on /blog/. */
.ld-blog-group h2 a { color: var(--text); }
.ld-blog-group h2 a:hover { color: var(--brand-hover); text-decoration: none; }
.ld-blog-more { margin: 16px 0 0; font-weight: 800; }
.ld-chips a[aria-current="page"] { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.ld-blog-head .ld-crumbs { margin-bottom: 12px; }
.ld-blog-card[lang="hi"] h3, .ld-blog-card[lang="gu"] h3, html[lang="hi"] .ld-post h1, html[lang="gu"] .ld-post h1 { line-height: 1.4; letter-spacing: 0; }
html[lang="hi"] .ld-post h2, html[lang="gu"] .ld-post h2, html[lang="hi"] .ld-post h3, html[lang="gu"] .ld-post h3 { line-height: 1.45; letter-spacing: 0; }
