/* Unified Obsidian Dark + Light Theme for Blog Home & Post Pages (matching /about/) */
:root {
  --bg: #07080c;
  --surface: #0e1017;
  --surface-2: #151924;
  --surface-bar: #121520;
  --border: rgba(255, 255, 255, 0.09);
  --specular: rgba(255, 255, 255, 0.16);
  --text: #f8fafc;
  --text-2: #d4dce8;
  --text-3: #9aa5b8;
  --cyan: #38bdf8;
  --violet: #a5b4fc;
  --emerald: #34d399;
  --amber: #f59e0b;
  --code-bg: #0a0d14;
}

html[data-theme="light"] {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-2: #f1f5f9;
  --surface-bar: #f8fafc;
  --border: rgba(15, 23, 42, 0.1);
  --specular: rgba(255, 255, 255, 0.95);
  --text: #0f172a;
  --text-2: #334155;
  --text-3: #64748b;
  --cyan: #0284c7;
  --violet: #4f46e5;
  --emerald: #059669;
  --amber: #d97706;
  --code-bg: #f1f5f9;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background-color: var(--bg);
  background-image:
    linear-gradient(rgba(56, 189, 248, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.035) 1px, transparent 1px);
  background-size: 36px 36px;
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: -0.006em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

html[data-theme="light"] body {
  background-image:
    linear-gradient(rgba(2, 132, 199, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(2, 132, 199, 0.055) 1px, transparent 1px);
}

#cursor-glow {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  background: radial-gradient(650px circle at var(--mx, 50%) var(--my, 20%), rgba(56, 189, 248, 0.08), transparent 55%);
}
html[data-theme="light"] #cursor-glow {
  background: radial-gradient(650px circle at var(--mx, 50%) var(--my, 20%), rgba(2, 132, 199, 0.07), transparent 55%);
}

a {
  color: var(--cyan);
  text-decoration: none;
  transition: color 0.15s ease;
}
a:hover {
  color: #7dd3fc;
  text-decoration: underline;
  text-underline-offset: 3px;
}
html[data-theme="light"] a:hover { color: #0369a1; }

/* Floating Glass Pill Topbar + Desktop Shell Badge */
.nav-shell {
  position: sticky;
  top: 14px;
  z-index: 40;
  max-width: 1380px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  pointer-events: none;
}
.nav-shell > * { pointer-events: auto; }
.nav-spacer { pointer-events: none; }

.nav-pill {
  grid-column: 2;
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(14, 16, 23, 0.8);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-top-color: var(--specular);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5);
  transition: opacity 0.28s cubic-bezier(0.22, 1, 0.36, 1), transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), filter 0.28s ease;
}
.nav-pill.is-dissolved {
  opacity: 0;
  transform: translateY(-6px) scale(0.92);
  filter: blur(4px);
  pointer-events: none;
}

#nav-particles {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 60;
}

.side-docked-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  overflow: hidden;
  max-height: 0;
  margin-top: 0;
  padding-top: 0;
  border-top: 1px solid transparent;
  opacity: 0;
  transform: translateY(-6px) scale(0.96);
  pointer-events: none;
  transition:
    max-height 0.36s cubic-bezier(0.22, 1, 0.36, 1),
    margin-top 0.36s cubic-bezier(0.22, 1, 0.36, 1),
    padding-top 0.36s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.3s ease,
    opacity 0.28s ease,
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}
.side-docked-nav.is-open {
  max-height: 140px;
  margin-top: 14px;
  padding-top: 14px;
  border-top-color: var(--border);
}
.side-docked-nav.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.side-docked-nav a {
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--text-2);
  background: var(--surface-2);
  border: 1px solid var(--border);
  padding: 5px 9px;
  border-radius: 8px;
  transition: all 0.18s ease;
}
.side-docked-nav a:hover {
  border-color: var(--cyan);
  color: var(--text);
  text-decoration: none;
  transform: translateY(-1px);
}
.side-docked-nav.is-arriving a {
  border-color: rgba(56, 189, 248, 0.55);
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.22);
}
.nav-pill::-webkit-scrollbar { display: none; }
html[data-theme="light"] .nav-pill,
html[data-theme="light"] .shell-badge {
  background: rgba(255, 255, 255, 0.88);
  border-color: rgba(15, 23, 42, 0.1);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

.nav-pill a {
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s ease;
}
.nav-pill a:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  text-decoration: none;
}
html[data-theme="light"] .nav-pill a:hover {
  background: rgba(15, 23, 42, 0.06);
  color: var(--text);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin-left: 4px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-2);
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.18s ease;
}
.theme-toggle:hover {
  border-color: var(--cyan);
  color: var(--cyan);
  background: rgba(56, 189, 248, 0.1);
}
.theme-toggle svg { width: 15px; height: 15px; display: block; }
.theme-toggle .icon-moon { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun { display: none; }
html[data-theme="light"] .theme-toggle .icon-moon { display: block; }
html[data-theme="light"] .theme-toggle { background: rgba(15, 23, 42, 0.04); }

.shell-badge {
  grid-column: 3;
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(14, 16, 23, 0.8);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-top-color: var(--specular);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: var(--text-2);
  white-space: nowrap;
  transition: opacity 0.28s ease, transform 0.42s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.28s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}
.shell-badge.is-hidden {
  opacity: 0;
  transform: translateY(-14px) scale(0.9);
  filter: blur(4px);
  pointer-events: none;
}
.shell-badge.is-returning {
  border-color: rgba(56, 189, 248, 0.55);
  box-shadow: 0 0 22px rgba(56, 189, 248, 0.28), 0 12px 36px rgba(0, 0, 0, 0.5);
}
.shell-badge .prompt-sign { color: var(--emerald); font-weight: 700; }
.shell-badge strong { color: var(--text); font-weight: 600; }
.shell-badge .cursor {
  display: inline-block;
  width: 7px;
  height: 14px;
  background: var(--cyan);
  border-radius: 1.5px;
  animation: blink 1.1s steps(2) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* 3-Column Blog Shell */
.blog-shell {
  position: relative;
  z-index: 1;
  max-width: 1380px;
  margin: 0 auto;
  padding: 36px 24px 80px;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr) 280px;
  gap: 28px;
  align-items: start;
}

/* Left & Right Sidebars */
.post-sidebar-left,
.post-sidebar-right {
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.sidebar-author-info {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top-color: var(--specular);
  border-radius: 18px;
  padding: 22px 18px;
  text-align: center;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
}
html[data-theme="light"] .sidebar-author-info {
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06);
}
.sidebar-author-info .image {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  padding: 4px;
  border: 1px dashed rgba(56, 189, 248, 0.55);
  margin: 0 auto 12px;
  display: block;
}
.sidebar-author-info .name {
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0 0 2px;
  color: var(--text);
  letter-spacing: -0.02em;
}
.sidebar-author-info .title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.76rem;
  color: var(--cyan);
  margin-bottom: 10px;
}
.sidebar-author-info .sub-title {
  font-size: 0.84rem;
  line-height: 1.55;
  color: var(--text-3);
  margin-bottom: 12px;
}
.sidebar-author-info .social {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 10px 0 12px;
}
.sidebar-author-info .social img {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  opacity: 0.85;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.sidebar-author-info .social img:hover {
  transform: translateY(-2px);
  opacity: 1;
}
.sidebar-author-info .read-more a {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.76rem;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--cyan);
}
.sidebar-author-info .read-more a:hover {
  border-color: var(--cyan);
  text-decoration: none;
}

.sidebar-claps {
  display: flex;
  justify-content: center;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
}

/* Right Sidebar Widgets (Medium card, Recent posts, Twitter) */
.post-sidebar-right .page-contain {
  background: transparent !important;
  font-family: inherit !important;
}
.post-sidebar-right .data-card {
  margin: 0 !important;
  max-width: 100% !important;
  min-height: auto !important;
  padding: 22px 20px !important;
  border-radius: 18px !important;
  background: var(--surface) !important;
  border: 1px solid var(--border) !important;
  border-top-color: var(--specular) !important;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.25) !important;
}
html[data-theme="light"] .post-sidebar-right .data-card {
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06) !important;
}
.post-sidebar-right .data-card h3 {
  color: var(--text) !important;
  font-size: 2.2rem !important;
  border-bottom-color: var(--violet) !important;
}
.post-sidebar-right .data-card h4 {
  color: var(--text-3) !important;
  font-size: 0.78rem !important;
  margin-bottom: 1rem !important;
}
.post-sidebar-right .data-card p {
  opacity: 1 !important;
  transform: none !important;
  color: var(--text-2) !important;
  font-size: 0.85rem !important;
  font-weight: 400 !important;
  line-height: 1.55 !important;
}
.post-sidebar-right .data-card .link-text {
  color: var(--cyan) !important;
  font-size: 0.86rem !important;
}
.post-sidebar-right .data-card .link-text svg path {
  fill: var(--cyan) !important;
}
.post-sidebar-right .data-card:hover {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.16), rgba(129, 140, 248, 0.2)) , var(--surface) !important;
  border-color: rgba(56, 189, 248, 0.45) !important;
}
.post-sidebar-right .data-card:hover h3,
.post-sidebar-right .data-card:hover h4,
.post-sidebar-right .data-card:hover p,
.post-sidebar-right .data-card:hover .link-text {
  color: var(--text) !important;
}

.recent-posts {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px;
}
.recent-posts h3 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--cyan);
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.recent-posts ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.recent-posts li {
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--text-3);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.recent-posts li:last-child { border-bottom: none; padding-bottom: 0; }
.recent-posts .post-link {
  display: block;
  color: var(--text);
  font-weight: 600;
  margin-bottom: 2px;
}
.recent-posts .post-link:hover { color: var(--cyan); }

.recent-tweets {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 14px;
  overflow: hidden;
}

/* Main Column: Home Post Feed */
.blog-main {
  min-width: 0;
}

.home-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 20px;
  background: var(--surface-bar);
  border: 1px solid var(--border);
  border-radius: 14px;
  margin-bottom: 18px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.76rem;
  color: var(--text-3);
}
.home-header-left {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.win-dots { display: inline-flex; gap: 5px; }
.win-dots i { width: 9px; height: 9px; border-radius: 50%; display: block; opacity: 0.75; }
.win-dots i:nth-child(1) { background: #ef4444; }
.win-dots i:nth-child(2) { background: #f59e0b; }
.win-dots i:nth-child(3) { background: #10b981; }
.home-header-left strong { color: var(--text); }

.home .post-info {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top-color: var(--specular);
  border-radius: 16px;
  padding: 0;
  margin-bottom: 20px;
  transition: border-color 0.2s ease, transform 0.2s ease;
  overflow: hidden;
}
.home .post-info:hover {
  border-color: rgba(56, 189, 248, 0.38);
  transform: translateY(-2px);
}
html[data-theme="light"] .home .post-info {
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.post-card-bar {
  padding: 13px 20px;
  background: var(--surface-bar);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}
.post-card-bar-left {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  min-width: 0;
}
.post-card-bar-left .win-dots {
  margin-top: 7px;
  flex-shrink: 0;
}
.post-card-date {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.74rem;
  color: var(--text-3);
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 3px;
}
.post-card-body {
  padding: 18px 22px 22px;
  overflow: hidden;
}
.home .post-header {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.38;
  letter-spacing: -0.015em;
}
.home .post-header .post-link {
  color: var(--text);
}
.home .post-header .post-link:hover {
  color: var(--cyan);
  text-decoration: none;
}
.home .post-meta-home {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.74rem;
  color: var(--text-3);
  margin: 0 0 12px;
}
.home .post-meta-home a {
  color: var(--cyan);
}
.home .post-description {
  display: block;
  font-size: 0.94rem;
  color: var(--text-2);
  line-height: 1.65;
}
.home .post-description img {
  border-radius: 10px;
  border: 1px solid var(--border);
}
.home .read-more {
  display: inline-block;
  margin-top: 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  font-weight: 600;
}

/* Home bottom widget-self */
.home-bio-footer {
  margin-top: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 26px;
}
.home-bio-footer .widget-self {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 16px;
}
.home-bio-footer .section-image img {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border);
}
.home-bio-footer .profile-name { margin: 0 0 2px; font-size: 1.5rem; }
.home-bio-footer .profile-name a { color: var(--text); }
.home-bio-footer .profile-title { font-weight: 600; color: var(--cyan); font-size: 0.92rem; }
.home-bio-footer .profile-location { font-size: 0.84rem; color: var(--text-3); }
.home-bio-footer .about-quotes .quote {
  color: var(--text-2);
  font-size: 0.92rem;
  margin-top: 12px;
}

/* Main Column: Single Blog Post Article */
.post-article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top-color: var(--specular);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.3);
}
html[data-theme="light"] .post-article {
  box-shadow: 0 12px 36px rgba(15, 23, 42, 0.06);
}
.post-file-bar {
  padding: 11px 22px;
  background: var(--surface-bar);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.74rem;
  color: var(--text-3);
}
.post-body-wrap {
  padding: 34px 36px 40px;
}
.page-header {
  margin-bottom: 26px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}
.post-title {
  font-size: clamp(1.75rem, 3.2vw, 2.35rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin: 0 0 12px;
  color: var(--text);
}
.post-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: var(--text-3);
  margin: 0;
}

/* Table of Contents (TOC) */
.post-toc {
  margin: 0 0 28px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--cyan);
  border-radius: 0 12px 12px 0;
  padding: 16px 20px;
}
.post-toc-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--cyan);
  margin-bottom: 10px;
}
.post-toc ul {
  margin: 0;
  padding-left: 18px;
  font-size: 0.9rem;
  line-height: 1.6;
}
.post-toc li { margin-bottom: 4px; color: var(--text-2); }
.post-toc a { color: var(--text-2); }
.post-toc a:hover { color: var(--cyan); }

/* Markdown-to-HTML Content Styling */
.post-content {
  color: var(--text-2);
  font-size: 1rem;
  line-height: 1.78;
  word-wrap: break-word;
}
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
  color: var(--text);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 1.8em 0 0.7em;
  line-height: 1.3;
}
.post-content h2 {
  font-size: 1.5rem;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.post-content h3 { font-size: 1.25rem; }
.post-content h4 { font-size: 1.08rem; }
.post-content p { margin: 0 0 1.15em; }
.post-content strong { color: var(--text); font-weight: 600; }
.post-content ul,
.post-content ol {
  margin: 0 0 1.2em;
  padding-left: 24px;
}
.post-content li { margin-bottom: 0.45em; }
.post-content hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2em 0;
}
.post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--border);
  display: block;
  margin: 1.4em auto;
}
.post-content blockquote {
  margin: 1.4em 0;
  padding: 14px 20px;
  background: var(--surface-2);
  border-left: 3px solid var(--violet);
  border-radius: 0 10px 10px 0;
  color: var(--text-2);
  font-style: italic;
}
.post-content blockquote p:last-child { margin-bottom: 0; }

/* Tables */
.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5em 0;
  font-size: 0.9rem;
  display: block;
  overflow-x: auto;
}
.post-content th,
.post-content td {
  padding: 10px 14px;
  border: 1px solid var(--border);
  text-align: left;
}
.post-content th {
  background: var(--surface-2);
  color: var(--text);
  font-weight: 600;
}
.post-content tr:nth-child(even) td {
  background: rgba(255, 255, 255, 0.02);
}
html[data-theme="light"] .post-content tr:nth-child(even) td {
  background: rgba(15, 23, 42, 0.02);
}

/* Inline Code & Rouge Syntax Highlighting */
.post-content code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.86em;
  background: var(--surface-2);
  color: var(--cyan);
  padding: 2px 6px;
  border-radius: 5px;
  border: 1px solid var(--border);
}
.post-content pre {
  margin: 1.4em 0;
  padding: 16px 18px;
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow-x: auto;
  line-height: 1.55;
  font-size: 0.86rem;
}
.post-content pre code {
  background: transparent;
  border: none;
  padding: 0;
  color: var(--text);
  font-size: inherit;
}
.highlight { background: transparent; margin: 1.4em 0; }
.highlight pre { margin: 0; }
/* Dark syntax tokens */
.highlight .c, .highlight .c1, .highlight .cm { color: #64748b; font-style: italic; }
.highlight .k, .highlight .kd, .highlight .kn, .highlight .kp, .highlight .kr, .highlight .kt { color: #c084fc; }
.highlight .s, .highlight .s1, .highlight .s2, .highlight .sb, .highlight .sc { color: #34d399; }
.highlight .nf, .highlight .nc, .highlight .nx { color: #38bdf8; }
.highlight .mi, .highlight .mf, .highlight .mh, .highlight .m { color: #fbbf24; }
.highlight .o, .highlight .p { color: #94a3b8; }
.highlight .na, .highlight .nb { color: #7dd3fc; }
.highlight .nt { color: #f472b6; }
/* Light syntax tokens */
html[data-theme="light"] .highlight .k,
html[data-theme="light"] .highlight .kd,
html[data-theme="light"] .highlight .kn,
html[data-theme="light"] .highlight .kt { color: #7c3aed; }
html[data-theme="light"] .highlight .s,
html[data-theme="light"] .highlight .s1,
html[data-theme="light"] .highlight .s2 { color: #059669; }
html[data-theme="light"] .highlight .nf,
html[data-theme="light"] .highlight .nc { color: #0284c7; }
html[data-theme="light"] .highlight .mi,
html[data-theme="light"] .highlight .mf { color: #d97706; }
html[data-theme="light"] .highlight .nt { color: #db2777; }

/* Post Medium Referral & Footer */
.post-medium-referral {
  margin: 28px 0;
  padding: 18px 20px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text-2);
}
.post-footer {
  margin-top: 28px;
  color: var(--text-2);
}
.post-footer hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 24px 0;
}
.post-footer h3, .post-footer h4 { color: var(--text); }

/* Site Footer */
.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 28px 24px 40px;
  text-align: center;
  color: var(--text-3);
  font-size: 0.84rem;
}
.site-footer .footer-col-wrapper {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-bottom: 12px;
}

/* Responsive */
@media (max-width: 1180px) {
  .blog-shell {
    grid-template-columns: 240px minmax(0, 1fr);
  }
  .post-sidebar-right {
    grid-column: 1 / -1;
    position: static;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
}

@media (max-width: 960px) {
  .nav-shell { display: flex; justify-content: center; padding: 0 16px; }
  .nav-spacer, .shell-badge, #nav-particles, .side-docked-nav { display: none !important; }
  .nav-pill.is-dissolved { opacity: 1 !important; transform: none !important; filter: none !important; pointer-events: auto !important; }
  .blog-shell {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 22px 16px 64px;
  }
  .post-sidebar-left,
  .post-sidebar-right {
    position: static;
    display: flex;
    flex-direction: column;
  }
  .blog-main { order: -1; }
  .post-body-wrap { padding: 24px 20px 28px; }
}

@media (max-width: 600px) {
  .nav-shell { top: 10px; padding: 0 10px; }
  .nav-pill { padding: 5px 8px; gap: 2px; justify-content: flex-start; }
  .nav-pill a { font-size: 0.78rem; padding: 6px 10px; }
  .home .post-info { padding: 0; }
  .post-card-bar { padding: 12px 15px; flex-direction: column; gap: 6px; }
  .post-card-body { padding: 15px 16px 18px; }
  .home .post-description img { float: none !important; max-width: 100% !important; margin: 0 0 12px !important; }
  .home-bio-footer .widget-self { flex-direction: column; text-align: center; }
}
