/* Blog post template (src/pages/blog/[slug].astro).
   Light theme only. The markdown plugins emit Tailwind utility classes for
   callouts, quote and CTA blocks, highlights, definition lists and footnotes;
   Tailwind is not loaded on these pages, so every one of those pieces is
   styled here by its structural class instead. */

/* ---- header ---------------------------------------------------------------- */
.la-post-hero { padding-bottom: 0 !important; }
.la-post-head { max-width: 760px; margin: 56px auto 0; text-align: left; }
.la-post-back { display: inline-block; margin-bottom: 22px; font-size: 14px; color: #536ee5; text-decoration: none; }
.la-post-back:hover { color: #1B44C8; }
.la-post-title { margin: 0 0 16px; font-family: var(--brand-font-heading); font-size: clamp(34px, 4.6vw, 52px); line-height: 1.08; letter-spacing: -.03em; color: #232323; }
.la-post-dek { margin: 0 0 22px; font-size: 19px; line-height: 1.6; color: #4B5563; }
.la-post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; color: #6B7280; }
.la-post-avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; margin-right: 4px; }
.la-post-author { font-weight: 600; color: #232323; }
.la-post-author a { color: inherit; text-decoration: none; }
.la-post-author a:hover { color: #536ee5; }
.la-post-dot { opacity: .5; }
.la-post-updated { flex-basis: 100%; font-size: 13px; color: #9CA3AF; }
.la-post-cover { max-width: 1040px; margin: 40px auto 0; border-radius: 20px; overflow: hidden; aspect-ratio: 1200 / 560; background: #EEF1F8; }
.la-post-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- body ------------------------------------------------------------------ */
.la-post-section { padding-top: 40px !important; }
.la-post-hero .section-wrapper, .la-post-hero { min-height: 0 !important; }
.la-post-body { max-width: 720px; margin: 0 auto; font-size: 18px; line-height: 1.75; color: #2C3444; }
.la-post-body > :first-child { margin-top: 0; }
.la-post-body p { margin: 0 0 1.25em; }
.la-post-body h1, .la-post-body h2, .la-post-body h3, .la-post-body h4, .la-post-body h5, .la-post-body h6 {
  font-family: var(--brand-font-heading); color: #232323; letter-spacing: -.02em; scroll-margin-top: 120px; }
.la-post-body h1 { font-size: 2.1rem; line-height: 1.15; margin: 2.2em 0 .6em; }
.la-post-body h2 { font-size: 1.75rem; line-height: 1.2; margin: 2em 0 .6em; }
.la-post-body h3 { font-size: 1.35rem; line-height: 1.3; margin: 1.8em 0 .5em; }
.la-post-body h4 { font-size: 1.15rem; margin: 1.6em 0 .5em; }
.la-post-body h5 { font-size: 1rem; margin: 1.4em 0 .4em; }
.la-post-body h6 { font-size: .9rem; margin: 1.4em 0 .4em; text-transform: uppercase; letter-spacing: .06em; color: #6B7280; }
.la-post-body a:not(.cta-button) { color: #536ee5; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.la-post-body a:not(.cta-button):hover { color: #1B44C8; }
.la-post-body strong { color: #232323; font-weight: 700; }
.la-post-body ul, .la-post-body ol { margin: 0 0 1.25em; padding-left: 1.4em; }
.la-post-body ul { list-style: disc; }
.la-post-body ol { list-style: decimal; }
.la-post-body li { margin: .35em 0; }
.la-post-body li > ul, .la-post-body li > ol { margin: .35em 0 0; }
.la-post-body li:has(> input[type="checkbox"]) { list-style: none; margin-left: -1.4em; }
.la-post-body li > input[type="checkbox"] { width: 16px; height: 16px; margin: 0 10px 0 0; vertical-align: -2px; accent-color: #536ee5; }
.la-post-body blockquote { margin: 1.6em 0; padding: 4px 0 4px 22px; border-left: 3px solid #536ee5; color: #4B5563; font-style: normal; }
.la-post-body blockquote blockquote { margin: .8em 0 0; border-left-color: #C9D3F7; }
.la-post-body hr { margin: 2.4em 0; border: 0; border-top: 1px solid #E4E9F5; }
.la-post-body img { max-width: 100%; height: auto; border-radius: 14px; display: block; margin: 1.6em auto; }
.la-post-body iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; border-radius: 14px; margin: 1.6em 0; }
.la-post-body code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .86em; padding: .15em .4em; border-radius: 6px; background: #EEF1FD; color: #3B4FC0; }
.la-post-body pre { margin: 1.6em 0; padding: 18px 20px; border-radius: 14px; background: #1B1F33; overflow-x: auto; line-height: 1.6; }
.la-post-body pre code { padding: 0; background: none; color: #E6E9F5; font-size: 14px; }
.la-post-body table { width: 100%; margin: 1.6em 0; border-collapse: collapse; font-size: 15px; border: 1px solid #E4E9F5; border-radius: 12px; overflow: hidden; display: table; }
.la-post-body th { text-align: left; padding: 12px 14px; background: #F4F6FE; font-family: var(--brand-font-heading); font-weight: 600; color: #232323; border-bottom: 1px solid #E4E9F5; }
.la-post-body td { padding: 12px 14px; border-bottom: 1px solid #EEF1F8; vertical-align: top; }
.la-post-body tbody tr:last-child td { border-bottom: 0; }
.la-post-body del { color: #9CA3AF; }

/* highlights: ==text== */
.la-post-body mark, .la-post-body [class*="bg-yellow-200"] { background: #FFF1B8; color: #5B4400; padding: 0 .25em; border-radius: 4px; }

/* callouts: > [!note] and friends */
.la-post-body .callout { margin: 1.6em 0; padding: 18px 20px; border-left: 4px solid; border-radius: 0 12px 12px 0; }
.la-post-body .callout-title { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-family: var(--brand-font-heading); font-weight: 600; }
.la-post-body .callout-title svg { flex: none; }
.la-post-body .callout-content p { margin: 0 0 .6em; }
.la-post-body .callout-content p:last-child { margin-bottom: 0; }
.la-post-body .callout.bg-blue-50 { background: #EEF3FF; border-color: #7C95F0; }
.la-post-body .callout.bg-blue-50 .callout-title, .la-post-body .callout.bg-blue-50 .callout-content { color: #26398C; }
.la-post-body .callout.bg-green-50 { background: #ECF8F1; border-color: #5CC08A; }
.la-post-body .callout.bg-green-50 .callout-title, .la-post-body .callout.bg-green-50 .callout-content { color: #1D5E3B; }
.la-post-body .callout.bg-orange-50 { background: #FFF4E8; border-color: #F0A45A; }
.la-post-body .callout.bg-orange-50 .callout-title, .la-post-body .callout.bg-orange-50 .callout-content { color: #7A3F0B; }
.la-post-body .callout.bg-red-50 { background: #FDEEEE; border-color: #E5746F; }
.la-post-body .callout.bg-red-50 .callout-title, .la-post-body .callout.bg-red-50 .callout-content { color: #8A1F1B; }

/* [!quote] and [!cta] blocks share a frame */
.la-post-body [class*="bg-primary/5"] { position: relative; margin: 2em 0; padding: 34px 28px; border-radius: 18px; background: #F4F6FE; text-align: center; overflow: hidden; }
.la-post-body [class*="bg-primary/5"] .absolute { display: none; }
.la-post-body [class*="max-w-[530px]"] { max-width: 540px; margin: 0 auto; }
.la-post-body [class*="bg-primary/5"] svg.fill-current { width: 38px; height: 38px; fill: #536ee5; display: inline-block; }
.la-post-body [class*="bg-primary/5"] [class*="mb-[14px]"] { display: flex; justify-content: center; margin-bottom: 12px; }
.la-post-body [class*="bg-primary/5"] p { margin: 0 0 12px; }
.la-post-body [class*="bg-primary/5"] p.italic, .la-post-body [class*="bg-primary/5"] .italic { font-style: italic; }
.la-post-body [class*="bg-primary/5"] [class*="text-xs"] { font-size: 13px; color: #6B7280; }
.la-post-body .cta-button { display: inline-flex; align-items: center; justify-content: center; padding: 12px 26px; border-radius: 999px; background: #536ee5; color: #FFFFFF; font-family: var(--brand-font-heading); font-weight: 600; text-decoration: none; transition: background-color .18s ease; }
.la-post-body .cta-button:hover { background: #1B44C8; color: #FFFFFF; }
/* raw HTML buttons authors drop into posts */
.la-post-body button { padding: 12px 24px; border: 0; border-radius: 999px; background: #536ee5; color: #FFFFFF; font-weight: 600; cursor: pointer; }
.la-post-body a.no-underline { text-decoration: none !important; }

/* definition lists */
.la-post-body dl { margin: 0 0 1.4em; }
.la-post-body dt { font-family: var(--brand-font-heading); font-weight: 600; color: #232323; margin-top: .8em; }
.la-post-body dd { margin: .2em 0 0 1.2em; color: #4B5563; }

/* footnotes */
.la-post-body sup a, .la-post-body a[href^="#footnote-"] { text-decoration: none !important; font-size: .75em; }
.la-post-body .footnotes { margin-top: 3em; padding-top: 1.4em; border-top: 1px solid #E4E9F5; font-size: 15px; color: #4B5563; }
.la-post-body .footnotes h2, .la-post-body .footnotes h3, .la-post-body .footnotes [class*="text-lg"] { font-size: 1.05rem; margin: 0 0 .8em; }
.la-post-body .footnotes ol { padding-left: 1.2em; }
.la-post-body [id^="footnote-"], .la-post-body [id^="footnote-ref-"] { scroll-margin-top: 120px; }

/* ---- after the article ------------------------------------------------------- */
.la-post-tags { max-width: 720px; margin: 36px auto 0; font-size: 14px; color: #6B7280; }
.la-post-authorcard { max-width: 720px; margin: 22px auto 0; padding: 18px 20px; display: flex; align-items: center; gap: 14px; border: 1px solid #E4E9F5; border-radius: 16px; background: #FFFFFF; }
.la-post-authorcard img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
.la-post-authorcard-name { font-family: var(--brand-font-heading); font-weight: 600; color: #232323; }
.la-post-authorcard-title { font-size: 14px; color: #6B7280; }
.la-post-related-title { margin: 0 0 24px; font-family: var(--brand-font-heading); font-size: 32px; letter-spacing: -.02em; color: #232323; text-align: center; }
.la-post-related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.la-post-card { display: flex; flex-direction: column; border-radius: 16px; overflow: hidden; background: #EEF3FA; text-decoration: none; color: inherit; transition: background-color .18s ease; }
.la-post-card:hover { background: #E6ECFA; }
.la-post-card-img { aspect-ratio: 1080 / 608; overflow: hidden; }
.la-post-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.la-post-card-body { padding: 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.la-post-card-title { font-family: var(--brand-font-heading); font-size: 18px; line-height: 1.35; color: #232323; }
.la-post-card-date { margin-top: auto; font-size: 13px; color: #6B7280; }

@media (max-width: 767px) {
  .la-post-head { margin-top: 28px; }
  .la-post-dek { font-size: 17px; }
  .la-post-body { font-size: 17px; }
  .la-post-cover { border-radius: 14px; }
  .la-post-related-grid { grid-template-columns: 1fr; }
}

/* The template container pads 80px top and bottom; between the cover and the
   article that stacked into a 200px gap. */
.la-post-hero > .w-container { padding-bottom: 0 !important; }
.la-post-section > .w-container { padding-top: 0 !important; }
.la-post-related { padding-top: 24px !important; }
