/* =========================================================
   blog.css — all rules scoped to .blog-page / .post-page
   Gold accent matches site theme-color (#b88a44)
   ========================================================= */

.blog-page {
  --b-bg: #faf8f4;
  --b-surface: #ffffff;
  --b-text: #1a1a1a;
  --b-muted: #6b6b6b;
  --b-line: rgba(0, 0, 0, 0.1);
  --b-accent: #b88a44;
  --b-accent-soft: #e9dcc3;
  --b-radius: 22px;
  --b-note: #cfe0dd;
  background: var(--b-bg);
  color: var(--b-text);
  padding: 48px clamp(16px, 4vw, 56px) 80px;
  max-width: 1280px;
  margin: 0 auto;
}

/* Dark theme: works with data-theme on <html> or <body>, and OS dark when set to auto */
[data-theme="dark"] .blog-page,
html[data-theme="dark"] body .blog-page {
  --b-bg: #0d0b12;
  --b-surface: #17141f;
  --b-text: #f1ede6;
  --b-muted: #a7a2ad;
  --b-line: rgba(255, 255, 255, 0.12);
  --b-accent-soft: #3a2f1c;
  --b-note: #1f2a2a;
}

@media (prefers-color-scheme: dark) {
  [data-theme="automatic"] .blog-page {
    --b-bg: #0d0b12;
    --b-surface: #17141f;
    --b-text: #f1ede6;
    --b-muted: #a7a2ad;
    --b-line: rgba(255, 255, 255, 0.12);
    --b-accent-soft: #3a2f1c;
    --b-note: #1f2a2a;
  }
}

.blog-page *,
.blog-page *::before,
.blog-page *::after {
  box-sizing: border-box;
}

.blog-page a {
  color: inherit;
  text-decoration: none;
}

.blog-page h1,
.blog-page h2,
.blog-page h3 {
  color: var(--b-text);
  letter-spacing: -0.02em;
}

.blog-page em {
  font-style: italic;
}

/* ---------- Hero ---------- */
.blog-hero {
  padding: 24px 0 56px;
  max-width: 760px;
}

.blog-eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--b-accent);
  font-weight: 600;
}

.blog-hero h1 {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  line-height: 1.02;
  margin: 12px 0 16px;
}

.blog-hero p {
  color: var(--b-muted);
  font-size: 1.1rem;
  line-height: 1.6;
  max-width: 56ch;
}

/* ---------- Section heads ---------- */
.blog-section {
  margin-bottom: 80px;
}

.section-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.section-head h2 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1;
  margin: 0;
  font-weight: 600;
}

.section-head.stacked {
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.lede {
  color: var(--b-muted);
  font-size: 1.1rem;
  line-height: 1.6;
  max-width: 60ch;
  margin: 0;
}

.link-arrow {
  font-size: 0.85rem;
  color: var(--b-muted);
}

.link-arrow:hover {
  color: var(--b-accent);
}

/* ---------- Pills / buttons ---------- */
.pill {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 500;
}

.pill-light {
  background: #fff;
  color: #111;
}

.pill-ghost {
  border: 1px solid rgba(255, 255, 255, 0.7);
  color: #fff;
}

.pill-outline {
  border: 1px solid currentColor;
}

.pill-tag {
  display: inline-block;
  font-size: 0.75rem;
  background: #fff;
  color: #111;
  padding: 4px 10px;
  border-radius: 8px 8px 0 0;
}

.round-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #111;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  transition: transform 0.25s;
}

.btn-primary {
  background: var(--b-text);
  color: var(--b-bg);
  border: 0;
  padding: 14px 32px;
  border-radius: 999px;
  font-size: 0.95rem;
  cursor: pointer;
  transition: transform 0.2s, background 0.2s;
}

.btn-primary:hover {
  background: var(--b-accent);
  color: #fff;
  transform: translateY(-2px);
}

/* image cards fall back to a gradient if the image is missing */
.card-img {
  background-image: var(--img), linear-gradient(135deg, #8a6a35, #2b2236);
  background-size: cover;
  background-position: center;
}

/* ---------- Bento ---------- */
.bento {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
}

.bento-main {
  position: relative;
  min-height: 520px;
  border-radius: var(--b-radius);
  overflow: hidden;
  display: flex;
  padding: 24px;
  gap: 10px;
  align-items: flex-start;
  flex-wrap: wrap;
  align-content: flex-start;
  transition: transform 0.35s;
}

.bento-main:hover {
  transform: translateY(-4px);
}

.bento-main:hover .round-btn {
  transform: rotate(45deg);
}

.bento-title {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 90px;
  max-width: 420px;
}

.bento-title h3 {
  background: #fff;
  color: #111;
  margin: 0;
  padding: 14px 18px;
  border-radius: 0 16px 16px 16px;
  font-size: clamp(1.3rem, 2.4vw, 1.9rem);
  line-height: 1.15;
  font-weight: 500;
}

.bento-main .round-btn {
  position: absolute;
  right: 24px;
  bottom: 24px;
}

.bento-side {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 20px;
}

.bento-note {
  background: var(--b-note);
  border-radius: var(--b-radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bento-note .pill-outline {
  align-self: flex-start;
  margin-bottom: 14px;
}

.bento-note h3 {
  font-size: 1.7rem;
  line-height: 1.1;
  margin: 4px 0 8px;
  font-weight: 500;
}

.note-small {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0;
  opacity: 0.7;
}

.note-copy {
  font-size: 0.9rem;
  opacity: 0.8;
  margin: 0 0 18px;
}

.link-underline {
  font-size: 0.85rem;
  text-decoration: underline !important;
  align-self: flex-end;
}

.bento-pick {
  position: relative;
  min-height: 280px;
  border-radius: var(--b-radius);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 20px;
}

.count-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, .8);
  color: #fff;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.8rem;
}

.cta-white {
  background: #fff;
  color: #111;
  padding: 16px 32px;
  border-radius: 999px;
  font-weight: 500;
  transition: transform 0.2s;
}

.bento-pick:hover .cta-white {
  transform: scale(1.04);
}

/* ---------- Filter bar ---------- */
.filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--b-line);
  padding-bottom: 14px;
  margin-bottom: 32px;
}

.filter-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.filter-tabs button {
  background: none;
  border: 0;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.9rem;
  color: var(--b-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.filter-tabs button:hover {
  color: var(--b-text);
}

.filter-tabs button.active {
  color: var(--b-text);
  background: var(--b-accent-soft);
  font-weight: 600;
}

.blog-search {
  background: var(--b-surface);
  color: var(--b-text);
  border: 1px solid var(--b-line);
  border-radius: 999px;
  padding: 10px 18px;
  min-width: 220px;
  font-size: 0.9rem;
}

.blog-search:focus {
  outline: 2px solid var(--b-accent);
  outline-offset: 1px;
}

/* ---------- Post cards ---------- */
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px 24px;
}

.post-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.post-card[hidden] {
  display: none;
}

.post-thumb {
  display: block;
  aspect-ratio: 4 / 3;
  border-radius: 16px;
  background-image: var(--img), linear-gradient(135deg, #8a6a35, #2b2236);
  background-size: cover;
  background-position: center;
  transition: transform 0.35s, box-shadow 0.35s;
}

.post-card:hover .post-thumb {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(0, 0, 0, .18);
}

.post-meta {
  display: flex;
  gap: 12px;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--b-accent);
  font-weight: 600;
  margin-top: 6px;
}

.post-meta span+span {
  color: var(--b-muted);
  font-weight: 400;
}

.post-card h3 {
  font-size: 1.35rem;
  line-height: 1.2;
  margin: 0;
  font-weight: 600;
}

.post-card h3 a {
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size 0.3s;
}

.post-card:hover h3 a {
  background-size: 100% 1px;
}

.post-card p {
  color: var(--b-muted);
  font-size: 0.95rem;
  line-height: 1.55;
  margin: 0;
}

.post-card footer {
  font-size: 0.75rem;
  color: var(--b-muted);
  margin-top: 4px;
}

.load-more-wrap {
  text-align: center;
  margin-top: 48px;
}

.no-results {
  text-align: center;
  color: var(--b-muted);
  padding: 40px 0;
}

/* ---------- Post page ---------- */
.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--b-accent, #b88a44);
  z-index: 9999;
}

.post-header {
  max-width: 820px;
  padding: 16px 0 48px;
}

.post-header h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.05;
  margin: 16px 0;
  font-weight: 600;
}

.crumbs {
  font-size: 0.8rem;
  color: var(--b-muted);
}

.crumbs a:hover {
  color: var(--b-accent);
}

.post-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

.post-side {
  position: sticky;
  top: 100px;
  display: grid;
  gap: 28px;
}

.side-block h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--b-muted);
  margin: 0 0 10px;
  font-weight: 500;
}

.side-block p {
  margin: 0;
  font-size: 0.9rem;
}

.author-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
}

.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--b-accent);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: 0.8rem;
}

.toc {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 1px solid var(--b-line);
}

.toc a {
  display: block;
  padding: 8px 14px;
  font-size: 0.85rem;
  color: var(--b-muted);
  border-left: 2px solid transparent;
  margin-left: -1px;
  transition: all 0.2s;
}

.toc a:hover {
  color: var(--b-text);
}

.toc a.active {
  color: var(--b-text);
  border-left-color: var(--b-accent);
  background: var(--b-accent-soft);
}

.share {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.share button {
  background: var(--b-surface);
  color: var(--b-text);
  border: 1px solid var(--b-line);
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s;
}

.share button:hover {
  background: var(--b-accent);
  color: #fff;
  border-color: var(--b-accent);
}

.post-body {
  max-width: 720px;
  font-size: 1.08rem;
  line-height: 1.8;
}

.post-body h2 {
  font-size: 1.8rem;
  margin: 2.4em 0 0.6em;
  scroll-margin-top: 110px;
  font-weight: 600;
}

.post-body p {
  margin: 0 0 1.3em;
  color: var(--b-text);
}

.post-body a {
  color: var(--b-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.post-hero {
  aspect-ratio: 16 / 9;
  border-radius: var(--b-radius);
  margin: 0 0 40px;
}

.post-body blockquote {
  margin: 2em 0;
  padding: 4px 0 4px 24px;
  border-left: 3px solid var(--b-accent);
  font-size: 1.3rem;
  font-style: italic;
  line-height: 1.5;
}

.post-body p strong {
  font-weight: 600;
  color: rgba(11, 58, 80, 0.951);
}


.callout {
  background: var(--b-accent-soft);
  border-radius: 16px;
  padding: 20px 24px;
  margin: 2em 0;
  font-size: 1rem;
  line-height: 1.6;
}

.callout strong {
  color: rgba(11, 58, 80, 0.951)!important;

}


/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .bento {
    grid-template-columns: 1fr;
  }

  .bento-side {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }

  .post-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .post-layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .post-side {
    position: static;
    grid-template-columns: 1fr 1fr;
  }

  .side-block:has(.toc) {
    grid-column: 1 / -1;
    order: 5;
  }
}

@media (max-width: 640px) {
  .blog-page {
    padding-top: 32px;
  }

  .bento-main {
    min-height: 420px;
  }

  .bento-title {
    bottom: 80px;
  }

  .bento-side {
    grid-template-columns: 1fr;
  }

  .post-grid {
    grid-template-columns: 1fr;
  }

  .blog-search {
    width: 100%;
  }

  .post-side {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .blog-page * {
    transition: none !important;
  }
}

/* =========================================================
   blog-post.css — light, plain-white blog post layout
   Scoped to .post-page so it never touches other pages.
   Load it LAST (after style.css, kj-style.css, nav-bar.css, home-refine.css).
   ========================================================= */

.post-page {
  --bp-bg: #ffffff;
  --bp-surface: #faf6ee;
  --bp-text: #24211d;
  --bp-muted: #6b645a;
  --bp-line: #e8e2d6;
  --bp-gold: #b88a44;
  --bp-link: #8a6420;
  --bp-serif: Georgia, "Times New Roman", serif;
  --bp-sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --bp-nav-offset: 90px; /* height of your fixed navbar, for anchor jumps */
}

/* Optional dark override (matches the Auto/Dark toggle if it sets one of these) */
html[data-theme="dark"] .post-page,
body.dark-theme .post-page,
body.dark .post-page {
  --bp-bg: #14120f;
  --bp-surface: #1d1a15;
  --bp-text: #ece6da;
  --bp-muted: #a39a8a;
  --bp-line: #2e2a22;
  --bp-link: #d4a95c;
}

/* ---------- page background ---------- */
body:has(.post-page) {
  background: #fff;
}
html[data-theme="dark"] body:has(.post-page),
body.dark-theme:has(.post-page),
body.dark:has(.post-page) {
  background: #14120f;
}
html:has(.post-page) {
  scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) {
  html:has(.post-page) {
    scroll-behavior: auto;
  }
}

.post-page {
  background: var(--bp-bg);
  color: var(--bp-text);
  font-family: var(--bp-serif);
  max-width: none;
  margin: 0;
  padding: calc(var(--bp-nav-offset) + 1rem) 1.25rem 5rem;
}

/* ---------- reading progress ---------- */
.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--bp-gold, #b88a44);
  transform: scaleX(0);
  transform-origin: 0 50%;
  z-index: 10000;
  pointer-events: none;
}

/* ---------- header ---------- */
.post-page .post-header {
  max-width: 1080px;
  margin: 0 auto 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--bp-line);
}
.post-page .crumbs {
  font-family: var(--bp-sans);
  font-size: 0.85rem;
  color: var(--bp-muted);
  margin-bottom: 1.25rem;
}
.post-page .crumbs a {
  color: var(--bp-muted);
  text-decoration: none;
}
.post-page .crumbs a:hover {
  color: var(--bp-link);
  text-decoration: underline;
}
.post-page .post-header h1 {
  font-family: var(--bp-serif);
  font-size: clamp(2rem, 4.6vw, 3.2rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--bp-text);
  margin: 0 0 1rem;
  text-wrap: balance;
}
.post-page .lede {
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  line-height: 1.6;
  color: var(--bp-muted);
  max-width: 46rem;
  margin: 0;
}

/* ---------- two-column layout ---------- */
.post-page .post-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 3.5rem;
  max-width: 1080px;
  margin: 0 auto;
  align-items: start;
}

/* ---------- sidebar ---------- */
.post-page .post-side {
  position: sticky;
  top: calc(var(--bp-nav-offset) + 0.5rem);
  max-height: calc(100vh - var(--bp-nav-offset) - 1.5rem);
  overflow-y: auto;
  font-family: var(--bp-sans);
  font-size: 0.9rem;
  padding-right: 0.25rem;
}
.post-page .side-block {
  margin-bottom: 1.6rem;
}
.post-page .side-block h4 {
  margin: 0 0 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bp-muted);
}
.post-page .side-block p {
  margin: 0;
  color: var(--bp-text);
}
.post-page .author-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--bp-text);
  text-decoration: none;
  font-weight: 600;
}
.post-page .author-chip:hover {
  color: var(--bp-link);
}
.post-page .avatar {
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--bp-gold);
  color: #fff;
  font-weight: 700;
}

.post-page .toc {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--bp-line);
}
.post-page .toc li {
  margin: 0;
}
.post-page .toc a {
  display: block;
  padding: 0.35rem 0 0.35rem 0.9rem;
  margin-left: -2px;
  border-left: 2px solid transparent;
  color: var(--bp-muted);
  text-decoration: none;
  line-height: 1.35;
}
.post-page .toc a:hover {
  color: var(--bp-text);
}
.post-page .toc a.active {
  color: var(--bp-link);
  border-left-color: var(--bp-gold);
  font-weight: 600;
}

.post-page .share {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.post-page .share button {
  font: inherit;
  font-size: 0.82rem;
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--bp-line);
  border-radius: 999px;
  background: transparent;
  color: var(--bp-text);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.post-page .share button:hover {
  border-color: var(--bp-gold);
  color: var(--bp-link);
}

/* ---------- article body ---------- */
.post-page .post-body {
  max-width: 720px;
  min-width: 0;
  font-size: 1.14rem;
  line-height: 1.8;
  color: var(--bp-text);
}
.post-page .post-hero {
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 0 0 2rem;
  border-radius: 6px;
  background-color: var(--bp-surface);
  background-image: var(--img);
  background-size: cover;
  background-position: center 25%;
}
.post-page .post-body p {
  margin: 0 0 1.35rem;
}
.post-page .post-body h2 {
  font-family: var(--bp-serif);
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  line-height: 1.2;
  color: var(--bp-text);
  margin: 3.2rem 0 1rem;
  scroll-margin-top: var(--bp-nav-offset);
  text-wrap: balance;
}
.post-page .post-body h3 {
  font-family: var(--bp-serif);
  font-size: 1.25rem;
  line-height: 1.3;
  margin: 2rem 0 0.5rem;
  color: var(--bp-text);
}
.post-page .post-body a {
  color: var(--bp-link);
  text-decoration: underline;
  text-decoration-color: rgba(184, 138, 68, 0.5);
  text-underline-offset: 3px;
}
.post-page .post-body a:hover {
  text-decoration-color: currentColor;
}
.post-page .post-body ul,
.post-page .post-body ol {
  margin: 0 0 1.5rem;
  padding-left: 1.4rem;
}
.post-page .post-body li {
  margin: 0.45rem 0;
}

.post-page .post-body blockquote {
  margin: 2.5rem 0;
  padding: 0.4rem 0 0.4rem 1.5rem;
  border-left: 3px solid var(--bp-gold);
  font-size: 1.3rem;
  font-style: italic;
  line-height: 1.6;
  color: var(--bp-text);
}

.post-page .callout {
  margin: 2rem 0;
  padding: 1.1rem 1.3rem;
  background: var(--bp-surface);
  border: 1px solid var(--bp-line);
  border-left: 3px solid var(--bp-gold);
  border-radius: 4px;
  font-size: 1.02rem;
  line-height: 1.7;
}
.post-page .callout strong {
  color: var(--bp-link);
}

#postBody ol strong,
#postBody ul strong {
  color: rgba(11, 58, 80, 0.951);
}

/* ---------- note + citation markers ---------- */
.post-page sup.note-ref,
.post-page sup.cite-ref {
  font-family: var(--bp-sans);
  font-size: 0.7em;
  line-height: 0;
  margin-left: 1px;
  scroll-margin-top: calc(var(--bp-nav-offset) + 20px);
}
.post-page sup.note-ref a,
.post-page sup.cite-ref a {
  text-decoration: none;
  font-weight: 600;
  padding: 0 1px;
}
.post-page sup.note-ref a {
  color: var(--bp-link);
}
.post-page sup.cite-ref a {
  color: var(--bp-gold);
}
.post-page sup a:hover {
  text-decoration: underline;
}

/* ---------- notes + references ---------- */
.post-page .post-body .narrative-block.notes-section {
  max-width: none;
  margin: 3.5rem 0 0;
  padding: 2rem 0 0;
  border-top: 1px solid var(--bp-line);
  background: none;
}
.post-page .notes-section h2 {
  margin-top: 0;
  font-size: 1.5rem;
}
.post-page .notes-list {
  margin: 0;
  padding-left: 1.6rem;
  font-size: 0.97rem;
  line-height: 1.65;
  color: var(--bp-muted);
}
.post-page .notes-list li {
  margin: 0 0 0.9rem;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  scroll-margin-top: calc(var(--bp-nav-offset) + 20px);
}
.post-page .notes-list li p {
  margin: 0;
}
.post-page .notes-list li::marker {
  color: var(--bp-gold);
  font-weight: 600;
}
.post-page .notes-list a[aria-label^="Return"] {
  margin-left: 0.35rem;
  text-decoration: none;
  font-family: var(--bp-sans);
}

/* briefly highlight whatever a note/citation link jumps to */
.post-page .notes-list li:target,
.post-page sup:target a {
  background: rgba(184, 138, 68, 0.18);
  outline: 2px solid rgba(184, 138, 68, 0.35);
  border-radius: 3px;
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .post-page .post-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .post-page .post-side {
    position: static;
    max-height: none;
    overflow: visible;
    padding: 0 0 1.25rem;
    border-bottom: 1px solid var(--bp-line);
  }
  .post-page .post-side .side-block:nth-child(3) {
    display: none; /* hide the long TOC on small screens */
  }
  .post-page .post-body {
    font-size: 1.08rem;
    max-width: none;
  }
}
@media (max-width: 560px) {
  .post-page {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  .post-page .post-body blockquote {
    font-size: 1.15rem;
    padding-left: 1rem;
  }
}

@media print {
  .read-progress,
  .post-page .post-side,
  .navbar,
  .appearance-panel {
    display: none !important;
  }
  .post-page {
    padding: 0;
  }
  .post-page .post-layout {
    display: block;
  }
}
sup.cite a, sup.note-ref a { text-decoration: none; font-weight: 600; padding: 0 1px; }
sup.note-ref a { font-style: italic; }
.notes-section li { scroll-margin-top: 90px; }

.post-page .concept-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.5rem 0 2rem;
}

@media (max-width: 560px) {
  .post-page .concept-grid {
    grid-template-columns: 1fr;
  }
}

.post-page .concept-card {
  padding: 1rem 1.2rem;
  border: 1px solid var(--bp-line);
  border-radius: 4px;
  background: var(--bp-surface);
}
.post-page .concept-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.1rem;
}
.post-page .concept-card p {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.65;
  color: var(--bp-muted);
}


/* =========================================================
   HOBBES vs LOCKE — COMPARISON TABLE
   White academic style
   ========================================================= */

.comparison-table-wrapper {
  width: 100%;
  margin: 2rem 0;
  overflow-x: auto;
  background: #ffffff;
  border: 1px solid #d8d8d8;
  border-radius: 6px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.06);
  -webkit-overflow-scrolling: touch;
}

/* Keyboard focus */
.comparison-table-wrapper:focus {
  outline: 2px solid #b88a44;
  outline-offset: 3px;
}

/* Table */
.comparison-table-wrapper table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  background: #ffffff;
  color: #242424;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.55;
}

/* Caption */
.comparison-table-wrapper caption {
  caption-side: top;
  padding: 1rem 1.2rem;
  background: #f7f5f1;
  border-bottom: 1px solid #d8d8d8;
  color: #2b2b2b;
  font-family: "Cinzel", Georgia, serif;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-align: left;
}

/* Header */
.comparison-table-wrapper thead th {
  padding: 0.9rem 1rem;
  background: #f1eee8;
  color: #252525;
  border-bottom: 2px solid #b88a44;
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-align: left;
}

/* First header column */
.comparison-table-wrapper thead th:first-child {
  width: 25%;
}

/* Body cells */
.comparison-table-wrapper tbody th,
.comparison-table-wrapper tbody td {
  padding: 0.95rem 1rem;
  border-bottom: 1px solid #e1e1e1;
  vertical-align: top;
}

/* Row labels */
.comparison-table-wrapper tbody th {
  background: #fafafa;
  color: #333333;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  text-align: left;
}

/* Alternating rows */
.comparison-table-wrapper tbody tr:nth-child(even) td {
  background: #fcfcfc;
}

/* Hover effect */
.comparison-table-wrapper tbody tr:hover td,
.comparison-table-wrapper tbody tr:hover th {
  background: #f8f3ea;
}

/* Remove final border */
.comparison-table-wrapper tbody tr:last-child th,
.comparison-table-wrapper tbody tr:last-child td {
  border-bottom: none;
}

/* Gold accent between philosopher columns */
.comparison-table-wrapper thead th:nth-child(2),
.comparison-table-wrapper tbody td:nth-child(2) {
  border-left: 1px solid #dedede;
}

.comparison-table-wrapper thead th:nth-child(3),
.comparison-table-wrapper tbody td:nth-child(3) {
  border-left: 1px solid #dedede;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 700px) {

  .comparison-table-wrapper {
    margin: 1.5rem 0;
    border-radius: 4px;
  }

  .comparison-table-wrapper table {
    min-width: 620px;
    font-size: 1rem;
  }

  .comparison-table-wrapper caption {
    padding: 0.85rem 1rem;
    font-size: 0.9rem;
  }

  .comparison-table-wrapper thead th,
  .comparison-table-wrapper tbody th,
  .comparison-table-wrapper tbody td {
    padding: 0.8rem;
  }
}