/* ============================
   KERNED BLOG — public surfaces
   ============================ */
.blog-page, .blog-post-page {
  --bg:#fafaf7; --panel:#f8f8f3; --white:#fff;
  --ink:#0e0e0c; --muted:#6b6b66; --faint:#5a5a55; --body:#20232b;
  --accent:#d4ff01; --accent-soft:#fbffe5; --border:#e6e6e0;
  --dark:#0e0e0c; --inv:#fafaf7; --dmuted:#8a8f86;
  --display:'Space Grotesk',system-ui,sans-serif;
  --sans:'DM Sans',system-ui,sans-serif;
  --mono:'JetBrains Mono',ui-monospace,monospace;
  --serif:'Fraunces',Georgia,serif;
  background: var(--bg); color: var(--ink); font-family: var(--sans);
}

.blog-dot, .bp-dot { width:7px;height:7px;border-radius:50%;background:var(--accent); display:inline-block; }

/* ============================ INDEX ============================ */

.blog-head { padding: 64px 80px 32px; display: flex; flex-direction: column; gap: 24px; }
.blog-kicker { display: flex; gap: 8px; align-items: center; font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--muted); }
.blog-htop { display: flex; justify-content: space-between; align-items: flex-end; gap: 40px; flex-wrap: wrap; }
.blog-htext h1 { font-family: var(--display); font-size: 64px; font-weight: 700; letter-spacing: -3px; line-height: 1; margin: 0 0 14px; }
.blog-htext p { font-size: 17px; line-height: 1.5; color: var(--muted); max-width: 560px; margin: 0; }
.blog-cats { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.blog-cat {
  background: var(--white); border: 1px solid var(--border); border-radius: 999px;
  padding: 8px 15px; font-size: 13px; font-weight: 600; color: var(--ink);
  text-decoration: none; transition: background .15s, color .15s, border-color .15s;
}
.blog-cat:hover { border-color: var(--ink); }
.blog-cat.active { background: var(--ink); color: var(--inv); border-color: var(--ink); }

.blog-featured { padding: 8px 80px 40px; }
.blog-fcard {
  display: flex; background: var(--white); border: 1px solid var(--border);
  border-radius: 20px; overflow: hidden;
  transition: transform .15s, box-shadow .15s;
}
.blog-fcard:hover { transform: translateY(-2px); box-shadow: 0 16px 40px rgba(14,14,12,0.08); }
.blog-fvis {
  width: 540px; flex: none;
  aspect-ratio: 16 / 9; align-self: center;
  background: var(--dark); display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 14px;
}
.blog-fvis-aa { display: flex; align-items: flex-end; gap: 6px; }
.blog-fvis-A { font-family: var(--serif); font-size: 150px; color: var(--accent); line-height: .9; }
.blog-fvis-a { font-family: var(--display); font-size: 150px; font-weight: 700; color: var(--accent); line-height: .9; }
.blog-fvis-lab { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: 3px; color: var(--dmuted); }
.blog-fbody { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 16px; padding: 48px; }
.blog-fmeta { display: flex; gap: 10px; align-items: center; }
.blog-fpill { background: var(--accent); border-radius: 999px; padding: 5px 12px; font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: 1.5px; }
.blog-fcat { font-family: var(--mono); font-size: 11px; font-weight: 600; letter-spacing: 1.5px; color: var(--muted); }
.blog-fbody h2 { font-family: var(--display); font-size: 36px; font-weight: 700; letter-spacing: -1.5px; line-height: 1.08; margin: 0; }
.blog-fex { font-size: 16px; line-height: 1.55; color: var(--muted); margin: 0; }
.blog-author { display: flex; gap: 10px; align-items: center; padding-top: 6px; }
.blog-av { border-radius: 999px; background: var(--ink); color: var(--accent); display: grid; place-items: center; font-weight: 700; flex: none; }
.blog-aname { font-size: 14px; font-weight: 600; }
.blog-adate { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.blog-read {
  background: var(--ink); color: var(--inv); border-radius: 999px;
  padding: 12px 22px; display: inline-flex; gap: 8px; align-items: center;
  font-size: 14px; font-weight: 700; text-decoration: none; width: max-content;
  transition: transform .15s;
}
.blog-read:hover { transform: translateX(2px); }
.blog-read svg { color: var(--accent); }

.blog-posthead { padding: 24px 80px 0; display: flex; justify-content: space-between; align-items: flex-end; }
.blog-posthead h3 { font-family: var(--display); font-size: 22px; font-weight: 700; letter-spacing: -.5px; margin: 0; }
.blog-count { font-family: var(--mono); font-size: 11px; color: var(--muted); letter-spacing: 1px; }

.blog-grid { padding: 24px 80px 56px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.blog-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: 16px; overflow: hidden;
  display: flex; flex-direction: column;
  text-decoration: none; color: inherit;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.blog-card:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(14,14,12,0.06); border-color: var(--ink); }
.blog-thumb { aspect-ratio: 16 / 9; padding: 24px; display: flex; flex-direction: column; justify-content: center; gap: 6px; }
.blog-thumb--panel { background: var(--panel); color: var(--ink); }
.blog-thumb--dark  { background: var(--dark);  color: var(--inv); }
.blog-thumb--lime  { background: var(--accent); color: var(--ink); }
.blog-thumb-h { font-size: 30px; line-height: 1.05; font-family: var(--serif); }
.blog-thumb-l { font-size: 14px; opacity: .8; }
.blog-cbody { padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.blog-ccat { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: 1.5px; color: var(--muted); }
.blog-ctitle { font-family: var(--display); font-size: 20px; font-weight: 700; line-height: 1.2; }
.blog-cex { font-size: 14px; line-height: 1.5; color: var(--muted); }
.blog-cmeta { display: flex; gap: 8px; align-items: center; font-size: 13px; }
.blog-au { font-weight: 600; }
.blog-mt { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.blog-cdot { color: var(--muted); }

.blog-empty {
  grid-column: 1 / -1; text-align: center; padding: 80px 20px;
  color: var(--muted); font-size: 15px;
}
.blog-empty strong { display: block; color: var(--ink); font-size: 22px; font-family: var(--display); font-weight: 700; margin-bottom: 8px; letter-spacing: -.6px; }

/* Newsletter */
.blog-news {
  background: var(--dark); padding: 80px 40px;
  display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center;
}
.blog-news-eye { font-family: var(--mono); font-size: 13px; font-weight: 700; letter-spacing: 2px; color: var(--accent); }
.blog-news-h { display: flex; gap: 12px; align-items: flex-end; justify-content: center; font-size: 38px; flex-wrap: wrap; margin: 0; }
.blog-news-a { font-family: var(--display); font-weight: 700; color: var(--inv); }
.blog-news-b { font-family: var(--serif); font-style: italic; color: var(--accent); }
.blog-news-sub { font-size: 17px; color: var(--dmuted); max-width: 560px; margin: 0; }
.blog-news-form {
  width: 480px; max-width: 100%; height: 56px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15);
  border-radius: 999px; padding: 6px 6px 6px 24px;
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
}
.blog-news-form input {
  flex: 1; min-width: 0; background: transparent; border: 0; outline: 0;
  color: var(--inv); font-family: inherit; font-size: 15px;
}
.blog-news-form input::placeholder { color: var(--dmuted); }
.blog-news-form button {
  background: var(--accent); color: var(--ink); border: 0; border-radius: 999px;
  padding: 12px 22px; display: inline-flex; gap: 8px; align-items: center;
  font-size: 14.5px; font-weight: 700; cursor: pointer; font-family: inherit;
}

/* ============================ POST DETAIL ============================ */

.bp-head { display: flex; flex-direction: column; align-items: center; padding: 64px 24px 32px; }
.bp-head-col { width: 760px; max-width: 100%; display: flex; flex-direction: column; align-items: center; gap: 22px; }
.bp-crumb { display: flex; align-items: center; gap: 8px; }
.bp-crumb span { font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--muted); }
.bp-title { font-family: var(--display); font-weight: 700; font-size: 56px; letter-spacing: -2px; line-height: 1.05; text-align: center; margin: 0; }
.bp-deck { width: 640px; max-width: 100%; font-size: 20px; line-height: 1.5; text-align: center; color: var(--muted); margin: 0; }
.bp-byline { display: flex; align-items: center; gap: 12px; padding-top: 8px; flex-wrap: wrap; justify-content: center; }
.bp-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: var(--accent); display: grid; place-items: center; font-family: var(--sans); font-weight: 700; font-size: 14px; object-fit: cover; }
/* Brand-mode avatar — the lime square mark, not a fake person. */
.bp-avatar.bp-avatar-brand {
  background: var(--accent); border-radius: 8px;
  color: var(--ink); display: flex; align-items: flex-end; justify-content: center; gap: 1px;
  font-size: 0;
}
.bp-avatar-brand-s { font-family: 'Fraunces', serif; font-size: 14px; line-height: 1; }
.bp-avatar-brand-g { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 14px; line-height: 1; }
.bp-name { font-size: 15px; font-weight: 600; }
.bp-date { font-family: var(--mono); font-size: 12px; color: var(--muted); }

.bp-hero { display: flex; justify-content: center; padding: 0 80px 40px; }
.bp-banner {
  width: 100%; max-width: 1280px; height: 380px;
  background: var(--dark); border-radius: 24px; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
}
.bp-banner-img {
  width: 100%; max-width: 1280px;
  aspect-ratio: 16 / 9;
  border-radius: 24px; overflow: hidden;
}
.bp-banner-img img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }
.bp-amp { font-family: var(--serif); font-style: italic; font-size: 220px; line-height: .85; color: var(--accent); }
.bp-blabel { font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: 3px; color: var(--dmuted); }

.bp-body { display: flex; justify-content: center; padding: 16px 80px 72px; }
.bp-wrap { width: 760px; max-width: 100%; }
.bp-content { display: flex; flex-direction: column; gap: 16px; }

/* Markdown body */
.bp-md { font-size: 18px; line-height: 1.75; color: var(--body); }
.bp-md > *:first-child { margin-top: 0; }
.bp-md h2 { font-family: var(--display); font-weight: 700; font-size: 30px; letter-spacing: -.8px; margin: 40px 0 14px; line-height: 1.15; color: var(--ink); }
.bp-md h3 { font-family: var(--display); font-weight: 700; font-size: 22px; letter-spacing: -.4px; margin: 28px 0 10px; color: var(--ink); }
.bp-md h4 { font-family: var(--display); font-weight: 700; font-size: 18px; margin: 22px 0 8px; color: var(--ink); }
.bp-md p { margin: 0 0 18px; }
/* Inline body links — dark ink text + a visible ink underline. Lime stays
   the accent color but is too low-contrast on paper as the underline,
   so swap it to a lime hover highlight (dark text on lime) where the
   affordance is unmissable. */
.bp-content a,
.bp-md a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--ink);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  transition: background-color .15s ease, box-shadow .15s ease;
}
.bp-content a:hover,
.bp-md a:hover {
  background: var(--accent);
  box-shadow: 0 0 0 2px var(--accent);
  border-radius: 2px;
  text-decoration-color: var(--ink);
}
.bp-content a:focus-visible,
.bp-md a:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

/* Author hook: render a font name in its own typeface inside body content
   (handy for tables comparing typefaces).
   Author writes either:
     <span style="font-family:'Calibri',sans-serif">Calibri</span>
   or, with this hook, the cleaner:
     <span class="ff" data-font="Inter, sans-serif">Inter</span>
   Web-safe families (Calibri, Arial, Georgia, Cambria, etc.) render via
   the system; Google Fonts need to be loaded separately in the page head. */
.bp-md .ff[data-font]      { font-family: attr(data-font type(<custom-ident>), sans-serif); }
@supports not (font-family: attr(data-font)) {
  .bp-md .ff[data-font="Inter"]        { font-family: 'Inter', sans-serif; }
  .bp-md .ff[data-font="Lora"]         { font-family: 'Lora', serif; }
  .bp-md .ff[data-font="Fraunces"]     { font-family: 'Fraunces', serif; }
  .bp-md .ff[data-font="Playfair"],
  .bp-md .ff[data-font="Playfair Display"] { font-family: 'Playfair Display', serif; }
  .bp-md .ff[data-font="DM Serif"]     { font-family: 'DM Serif Display', serif; }
  .bp-md .ff[data-font="Arial"]        { font-family: Arial, sans-serif; }
  .bp-md .ff[data-font="Calibri"]      { font-family: Calibri, sans-serif; }
  .bp-md .ff[data-font="Georgia"]      { font-family: Georgia, serif; }
  .bp-md .ff[data-font="Cambria"]      { font-family: Cambria, serif; }
  .bp-md .ff[data-font="Garamond"]     { font-family: 'EB Garamond', Garamond, serif; }
}
.bp-md strong { font-weight: 700; color: var(--ink); }
.bp-md em { font-style: italic; }
.bp-md ul, .bp-md ol { margin: 0 0 18px; padding-left: 24px; }
.bp-md li { margin-bottom: 6px; }
.bp-md blockquote {
  border-left: 3px solid var(--accent); margin: 24px 0;
  padding: 6px 0 6px 20px; font-family: var(--serif); font-style: italic;
  font-size: 22px; line-height: 1.5; color: var(--ink);
}
.bp-md code { font-family: var(--mono); background: rgba(14,14,12,.06); padding: 2px 6px; border-radius: 4px; font-size: 15px; }
.bp-md pre { background: var(--dark); color: var(--inv); padding: 20px; border-radius: 12px; overflow-x: auto; margin: 20px 0; font-family: var(--mono); font-size: 14px; line-height: 1.6; }
.bp-md pre code { background: transparent; padding: 0; color: inherit; }
.bp-md img { max-width: 100%; height: auto; border-radius: 12px; margin: 24px 0; display: block; }
.bp-md hr { border: 0; border-top: 1px solid var(--border); margin: 32px 0; }
.bp-md table { width: 100%; border-collapse: collapse; margin: 20px 0; }
.bp-md th, .bp-md td { border-bottom: 1px solid var(--border); padding: 10px 14px; text-align: left; font-size: 15px; }
.bp-md th { font-family: var(--display); font-weight: 700; }

/* FAQ block — mirrors .bp-body's centering pattern so the inner 760px column
   lines up with the article body above it. The bottom margin keeps the
   accordion clearly off the author card below. */
.bp-faq {
  display: flex; justify-content: center;
  padding: 0 80px;
  margin-bottom: 64px;
}
.bp-faq .bp-wrap { width: 760px; max-width: 100%; }
.bp-faq-h {
  font-family: var(--display);
  font-size: 36px; font-weight: 700;
  letter-spacing: -1.2px; line-height: 1.15;
  margin: 48px 0 20px; color: var(--ink);
}
.bp-faq-list { display: flex; flex-direction: column; gap: 12px; }
.bp-faq-item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0; overflow: hidden;
}
.bp-faq-item summary {
  cursor: pointer; list-style: none;
  padding: 18px 22px;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  font-family: var(--display);
  font-weight: 600; font-size: 17px; line-height: 1.4;
  color: var(--ink);
}
.bp-faq-item summary::-webkit-details-marker { display: none; }
.bp-faq-item summary svg { flex: none; transition: transform .15s; }
.bp-faq-item[open] summary svg { transform: rotate(180deg); }
.bp-faq-body {
  padding: 0 22px 22px;
  font-family: 'Lora', serif;
  font-size: 16.5px; line-height: 1.7; color: var(--body, #3A3A36);
}

/* Author / tags / share */
.bp-author { display: flex; flex-direction: column; align-items: center; padding: 0 80px 56px; }
.bp-author-col { width: 760px; max-width: 100%; display: flex; flex-direction: column; gap: 28px; }
.bp-tags { display: flex; gap: 10px; flex-wrap: wrap; }
.bp-tag { background: var(--panel); border-radius: 999px; padding: 8px 16px; font-size: 13px; font-weight: 600; color: var(--muted); }
.bp-author-div { height: 1px; background: var(--border); }
.bp-author-card { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.bp-author-info { display: flex; align-items: center; gap: 16px; }
.bp-av { width: 64px; height: 64px; border-radius: 50%; background: var(--ink); color: var(--accent); display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 22px; flex: none; object-fit: cover; }
/* Brand-mode author-card avatar. */
.bp-av.bp-av-brand {
  background: var(--accent); border-radius: 12px;
  color: var(--ink);
  display: flex; align-items: flex-end; justify-content: center; gap: 2px;
  font-size: 0;
}
.bp-av-brand-s { font-family: 'Fraunces', serif; font-size: 26px; line-height: 1; }
.bp-av-brand-g { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 26px; line-height: 1; }
.bp-author-meta { display: flex; flex-direction: column; gap: 4px; }
.bp-author-nm { font-family: var(--display); font-weight: 700; font-size: 18px; }
.bp-author-role { font-size: 15px; color: var(--muted); }
.bp-author-bio { font-size: 14px; color: var(--muted); max-width: 420px; }
.bp-share { display: flex; align-items: center; gap: 10px; }
.bp-share-lbl { font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: 1.5px; color: var(--muted); }
.bp-share-btn {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--white); border: 1px solid var(--border);
  display: grid; place-items: center; cursor: pointer; color: var(--ink);
  transition: border-color .15s;
}
.bp-share-btn:hover { border-color: var(--ink); }

/* Related */
.bp-related { background: #f2f2ec; display: flex; flex-direction: column; align-items: center; padding: 72px 80px; }
.bp-related-col { width: 1280px; max-width: 100%; display: flex; flex-direction: column; gap: 36px; }
.bp-related-head { display: flex; align-items: flex-end; justify-content: space-between; }
.bp-related-head h2 { font-family: var(--display); font-weight: 700; font-size: 30px; margin: 0; letter-spacing: -.6px; }
.bp-all-link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; text-decoration: none; color: var(--ink); }
.bp-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.bp-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: 16px; overflow: hidden; display: flex; flex-direction: column;
  text-decoration: none; color: inherit; transition: transform .15s, border-color .15s;
}
.bp-card:hover { transform: translateY(-2px); border-color: var(--ink); }
.bp-thumb { height: 180px; padding: 24px; display: flex; flex-direction: column; justify-content: center; gap: 6px; }
.bp-thumb--panel { background: var(--panel); color: var(--ink); }
.bp-thumb--dark  { background: var(--dark);  color: var(--inv); }
.bp-thumb--lime  { background: var(--accent); color: var(--ink); }
.bp-thumb-word { font-size: 28px; line-height: 1.1; font-family: var(--serif); }
.bp-thumb-line { font-size: 13px; opacity: .8; }
.bp-card-body { padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.bp-card-cat { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: 1.5px; color: var(--muted); }
.bp-card-title { font-family: var(--display); font-weight: 700; font-size: 19px; line-height: 1.2; }
.bp-card-meta { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.bp-mav { width: 22px; height: 22px; border-radius: 50%; background: var(--ink); color: var(--accent); display: grid; place-items: center; font-size: 9px; font-weight: 700; }

/* Responsive */
@media (max-width: 1080px) {
  .blog-head, .blog-featured, .blog-posthead, .blog-grid,
  .bp-hero, .bp-body, .bp-faq, .bp-author, .bp-related { padding-left: 32px; padding-right: 32px; }
  .blog-grid, .bp-cards { grid-template-columns: 1fr 1fr; }
  .blog-fcard { flex-direction: column; }
  .blog-fvis { width: 100%; }
}
@media (max-width: 680px) {
  .blog-head { padding: 48px 20px 28px; }
  .blog-htext h1 { font-size: 44px; letter-spacing: -1.6px; }
  .blog-htop { flex-direction: column; align-items: flex-start; }
  .blog-grid, .bp-cards { grid-template-columns: 1fr; }
  .bp-title { font-size: 38px; letter-spacing: -1px; }
  .bp-deck { font-size: 18px; }
  .bp-banner { height: 280px; }
  .bp-amp { font-size: 110px; }
  .bp-body { padding: 16px 24px 48px; }
  .bp-faq  { padding: 0 24px; margin-bottom: 48px; }
  .bp-faq-h { font-size: 28px; margin: 32px 0 16px; }
}
