/* Blog pages: loaded after legal.css, which carries the shared tokens, nav, header and footer.
   Lime stays a fill or text on night; on paper, violet stands in (same rule as the landing page). */

.eyebrow a { color: inherit; text-decoration: none; }
.post-head h1 { font-size: clamp(40px, 5.4vw, 80px); line-height: 1; max-width: 17em; text-wrap: balance; }

/* Article: prose on the left, a sticky install card on the right */
.post { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding-block: clamp(56px, 7vw, 104px) clamp(80px, 9vw, 136px); }
.prose { grid-column: 1 / 9; min-width: 0; color: var(--body); font-size: 19px; line-height: 1.7; }
.prose > * { margin-bottom: 0; }
.prose > * + * { margin-top: 22px; }
.prose h2 { margin-top: 64px; font-size: clamp(28px, 2.6vw, 38px); font-weight: 650; letter-spacing: -.03em; line-height: 1.15; color: var(--ink); text-wrap: balance; scroll-margin-top: 24px; }
.prose h3 { margin-top: 40px; font-size: 23px; font-weight: 650; letter-spacing: -.02em; line-height: 1.3; color: var(--ink); scroll-margin-top: 24px; }
.prose h2 + *, .prose h3 + * { margin-top: 16px; }
.prose > :first-child { margin-top: 0; }
.prose strong { font-weight: 650; color: var(--ink); }
.prose a { color: var(--violet); font-weight: 600; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: 10px; }
.prose li::marker { color: var(--violet); font-weight: 650; }
.prose blockquote { margin: 0; padding: 4px 0 4px 24px; border-left: 3px solid var(--violet); color: var(--ink); font-size: 21px; line-height: 1.55; }
.prose code { font-family: var(--mono); font-size: .86em; background: var(--surface); border-radius: 6px; padding: .12em .4em; color: var(--ink); }
.prose pre { background: var(--night); color: var(--lavender); border-radius: 16px; padding: 22px 24px; overflow-x: auto; font-size: 15.5px; line-height: 1.6; }
.prose pre code { background: none; padding: 0; color: inherit; font-size: inherit; }
.prose hr { border: 0; border-top: 1px solid var(--hair); margin-block: 48px; }
.prose img { display: block; max-width: 100%; height: auto; border-radius: 14px; box-shadow: 0 0 0 1px var(--hair); }
.prose table { width: 100%; border-collapse: collapse; background: var(--card); border-radius: 16px; overflow: hidden; box-shadow: 0 0 0 1px var(--hair); font-size: 16px; line-height: 1.5; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 12px 16px; border-bottom: 1px solid var(--hair); }
.prose th { font-size: 13px; font-weight: 650; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); background: #fbfafd; }
.prose tr:last-child td { border-bottom: 0; }

.post-aside { grid-column: 10 / 13; align-self: start; position: sticky; top: 24px; }
.aside-card { background: var(--night); color: #fff; border-radius: 22px; padding: 28px; box-shadow: 0 30px 80px -24px rgba(26, 18, 56, .35); }
.aside-h { margin-top: 14px; font-size: 24px; font-weight: 650; letter-spacing: -.025em; line-height: 1.2; }
.aside-card p:not(.eyebrow):not(.aside-h) { margin-top: 12px; font-size: 16px; line-height: 1.55; color: var(--lavender); }
.aside-card .btn { margin-top: 22px; width: 100%; }

/* Index: one row per post, the whole row is the link */
.blog-list { padding-block: clamp(56px, 7vw, 104px) clamp(80px, 9vw, 136px); }
.posts { border-top: 1px solid var(--ink); }
.post-card { position: relative; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); padding: 36px 0 40px; border-bottom: 1px solid var(--hair); }
.post-card .meta { grid-column: 1 / 4; margin-top: 8px; color: var(--muted); }
.post-card .txt { grid-column: 4 / 11; }
.post-card h2 { font-size: clamp(26px, 2.6vw, 36px); font-weight: 650; letter-spacing: -.03em; line-height: 1.15; text-wrap: balance; }
.post-card h2 a { text-decoration: none; }
.post-card h2 a::after { content: ""; position: absolute; inset: 0; }
.post-card .txt p { margin-top: 12px; color: var(--body); max-width: 62ch; }
.post-card .go { grid-column: 11 / 13; justify-self: end; align-self: center; display: inline-flex; align-items: center; gap: 8px; font-weight: 650; font-size: 16px; color: var(--violet); }
.post-card .go svg { width: 16px; height: 16px; }
.empty { color: var(--muted); }

.more-posts { border-top: 1px solid var(--hair); padding-block: clamp(56px, 6vw, 88px); }
.more-posts h2 { font-size: 14px; font-weight: 650; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.more-posts ol { margin-top: 18px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.more-posts a { display: block; height: 100%; padding: 24px; border-radius: 18px; background: var(--card); box-shadow: 0 0 0 1px var(--hair); text-decoration: none; }
.more-posts b { display: block; font-size: 20px; font-weight: 650; letter-spacing: -.02em; line-height: 1.25; }
.more-posts span { display: block; margin-top: 10px; font-family: var(--mono); font-size: 13px; color: var(--muted); }

/* Closing band, as on the landing page */
.field-lime { background: var(--lime); color: var(--night); }
.field-lime :focus-visible { outline-color: var(--night); }
.closer { padding-block: clamp(80px, 9vw, 136px); text-align: center; }
.closer .vf { position: relative; display: inline-block; padding: clamp(28px, 4vw, 56px) clamp(28px, 5vw, 80px); }
.vf > i { position: absolute; width: clamp(26px, 3vw, 44px); height: clamp(26px, 3vw, 44px); border: 0 solid var(--night); pointer-events: none; }
.vf > i:nth-of-type(1) { top: -14px; left: -14px; border-width: 3px 0 0 3px; border-top-left-radius: 14px; }
.vf > i:nth-of-type(2) { top: -14px; right: -14px; border-width: 3px 3px 0 0; border-top-right-radius: 14px; }
.vf > i:nth-of-type(3) { bottom: -14px; right: -14px; border-width: 0 3px 3px 0; border-bottom-right-radius: 14px; }
.vf > i:nth-of-type(4) { bottom: -14px; left: -14px; border-width: 0 0 3px 3px; border-bottom-left-radius: 14px; }
.closer h2 { font-size: clamp(36px, 5vw, 72px); font-weight: 700; letter-spacing: -.05em; line-height: 1; max-width: 13em; margin: 0 auto; }
.closer .ctas { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 20px; margin-top: 32px; }
.closer .note { font-size: 16px; font-weight: 550; }
.btn svg { width: 16px; height: 16px; margin-left: 10px; }
.btn-night { background: var(--night); color: var(--lime); }

@media (hover: hover) {
  .prose a:hover { text-decoration-thickness: 2.5px; }
  .post-card:hover h2 a { text-decoration: underline; text-decoration-thickness: 2px; }
  .more-posts a:hover { box-shadow: 0 0 0 1.5px var(--violet); }
  .btn-night:hover { background: var(--indigo); }
}

@media (max-width: 900px) {
  .prose { grid-column: 1 / 13; font-size: 18px; }
  .post-aside { position: static; grid-column: 1 / 13; margin-top: 56px; }
  .post-card { row-gap: 10px; }
  .post-card .meta, .post-card .txt { grid-column: 1 / 13; margin-top: 0; }
  .post-card .go { grid-column: 1 / 13; justify-self: start; margin-top: 6px; }
  .more-posts ol { grid-template-columns: 1fr; }
}
