* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #F7F4EC;
  --surface: #FFFFFF;
  --surface-hover: #FCFBF7;
  --ink: #161616;
  --muted: #6A665D;
  --line: #E5E0D5;
  --line-strong: #D0C9BA;
  --lime: #B3DF2A;
  --lime-soft: #E9F5BE;
  --orange: #FF6A1A;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

html, body {
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", "Hiragino Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
}

h1, .page-title, .post-title, .article-card h1 {
  text-wrap: balance;
}

.hl-mark {
  background: linear-gradient(transparent 62%, var(--lime) 62%, var(--lime) 94%, transparent 94%);
  padding: 0 3px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.top-bar {
  height: 3px;
  width: 100%;
  background: var(--ink);
  position: relative;
}

.top-bar.is-reading {
  position: sticky;
  top: 0;
  z-index: 50;
}

.top-bar.is-reading::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--read-progress, 0%);
  background: var(--lime);
  transition: width 0.08s linear;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

main {
  margin: 0 auto;
  padding: 36px 24px 56px;
}

.home-main {
  max-width: 1040px;
  padding-top: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.list-main {
  max-width: 1040px;
}

.article-main {
  max-width: 680px;
  padding-bottom: 60px;
}

.narrow-main {
  max-width: 600px;
  padding-top: 40px;
}

/* Site Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 45;
  border-bottom: 1px solid var(--line);
  background: rgba(247, 244, 236, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.site-header-inner {
  max-width: 1040px;
  margin: 0 auto;
  padding: 11px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.2px;
}

.site-brand img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #1B2A38;
  border: 1.5px solid var(--ink);
  display: block;
  flex-shrink: 0;
}

.site-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.site-nav a {
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--muted);
  text-decoration: none;
  border: 1px solid transparent;
  transition: color 0.14s ease, background 0.14s ease, border-color 0.14s ease, transform 0.14s ease;
}

.site-nav a:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.65);
}

.site-nav a.is-active {
  background: transparent;
  color: var(--ink);
  border-color: transparent;
  border-radius: 0;
  box-shadow: inset 0 -2px 0 var(--lime);
}

.site-nav a.nav-cta {
  background: var(--lime);
  color: var(--ink);
  border: 1.5px solid var(--ink);
  border-radius: 8px;
  padding: 6px 12px;
  margin-left: 4px;
}

.site-nav a.nav-cta:hover {
  background: var(--lime);
  border-color: var(--ink);
  transform: translateY(-1px);
}

.site-nav a.nav-cta.is-active {
  background: var(--ink);
  color: var(--lime);
  border-color: var(--ink);
  border-radius: 8px;
  box-shadow: none;
}

.nav-search-btn {
  height: 32px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 600;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color 0.14s ease, transform 0.14s ease;
}

.nav-search-btn:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
}

.nav-search-kbd {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  color: var(--muted);
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--bg);
  border: 1px solid var(--line);
}

@media (max-width: 640px) {
  input[type="email"],
  input[type="search"],
  .search-input,
  .search-dialog-head input {
    font-size: 16px !important;
  }

  .nav-search-label,
  .nav-search-kbd {
    display: none;
  }

  .nav-search-btn {
    width: 32px;
    padding: 0;
  }
}

@media (max-width: 520px) {
  .site-header-inner {
    padding: 10px 14px;
    gap: 8px;
    flex-wrap: nowrap;
  }

  .site-brand span {
    display: none;
  }

  .site-nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    gap: 4px;
    padding-bottom: 1px;
  }

  .site-nav::-webkit-scrollbar {
    display: none;
  }

  .site-nav a {
    padding: 5px 9px;
    font-size: 12.5px;
    white-space: nowrap;
    flex-shrink: 0;
  }
}

/* Home Hero & 65/35 Editorial Stage */
.home-hero-band {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 22px;
  padding: 8px 0 40px;
  border-bottom: 1px solid var(--line);
}

.home-hero-intro {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  min-width: 0;
}

.home-hero-nl {
  width: 100%;
  min-width: 0;
}

.home-main h1 {
  margin-top: 0;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.24;
  letter-spacing: -0.025em;
  text-align: left;
}

.bio {
  margin-top: 14px;
  font-size: 16px;
  line-height: 1.7;
  color: #3D3A34;
  text-align: left;
  max-width: 520px;
}

.hero-byline {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.hero-byline img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #1B2A38;
  border: 1.5px solid var(--ink);
  object-fit: cover;
  flex-shrink: 0;
}

.hero-byline-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.hero-byline-name {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--ink);
}

.hero-byline-name span {
  font-weight: 600;
  color: var(--muted);
  margin-left: 4px;
}

.hero-byline-meta {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.45;
}

.home-stage {
  width: 100%;
  margin-top: 44px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

.home-main-col,
.home-side-col {
  min-width: 0;
}

.home-side-col {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.home-stage-label {
  font-size: 13px;
  font-weight: 800;
  color: var(--muted);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.home-lead-post {
  display: block;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
}

.home-lead-post.has-thumb {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: center;
}

.home-lead-body {
  min-width: 0;
}

.home-lead-meta {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.home-lead-kicker {
  font-family: inherit;
  font-weight: 800;
  color: var(--orange);
}

.home-lead-post h2 {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.32;
  letter-spacing: -0.02em;
  transition: color 0.14s ease;
}

.home-lead-post:hover h2 {
  text-decoration: underline;
  text-decoration-color: var(--lime);
  text-decoration-thickness: 3px;
  text-underline-offset: 4px;
}

.home-lead-desc {
  margin-top: 10px;
  font-size: 15px;
  line-height: 1.7;
  color: #3D3A34;
}

.home-lead-foot {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
}

.home-lead-foot .arrow {
  font-size: 15px;
}

.home-lead-thumb {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg);
}

.home-lead-thumb img {
  display: block;
  width: 100%;
  height: auto;
}

.editorial-list {
  display: flex;
  flex-direction: column;
}

.editorial-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
}

.editorial-row:hover .editorial-title {
  text-decoration: underline;
  text-decoration-color: var(--lime);
  text-decoration-thickness: 2.5px;
  text-underline-offset: 4px;
}

.editorial-row:hover .editorial-arrow {
  transform: translateX(3px);
}

.editorial-date {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  padding-top: 3px;
  white-space: nowrap;
}

.editorial-content {
  min-width: 0;
}

.editorial-title {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.42;
}

.editorial-desc {
  margin-top: 4px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--muted);
}

.editorial-submeta {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}

.editorial-arrow {
  display: none;
  font-size: 16px;
  font-weight: 700;
  color: var(--orange);
  transition: transform 0.14s ease;
}

.editorial-more-row {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 13.5px;
  font-weight: 700;
}

.editorial-more-row a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1.5px solid var(--lime);
  padding-bottom: 1px;
}

.editorial-more-row a:hover {
  border-bottom-color: var(--orange);
}

.series-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.series-home-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 18px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.14s ease, transform 0.14s ease;
}

.series-home-card:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
}

.series-home-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.series-home-badge {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--orange);
}

.series-read-progress {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
}

.series-home-title {
  font-size: 15.5px;
  font-weight: 800;
  line-height: 1.4;
}

.series-home-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
}

.series-progress-track {
  width: 100%;
  height: 3px;
  border-radius: 999px;
  background: var(--bg);
  overflow: hidden;
  margin-top: 2px;
}

.series-progress-fill {
  display: block;
  height: 100%;
  width: 0;
  background: var(--lime);
  transition: width 0.2s ease;
}

.series-home-cta {
  font-size: 12.5px;
  font-weight: 800;
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.editor-note-card {
  padding: 16px 18px;
  background: #FBF9F4;
  border: 1px solid var(--line);
  border-left: 3px solid var(--orange);
  border-radius: 0 12px 12px 0;
}

.editor-note-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 10px;
}

.editor-note-head img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #1B2A38;
  border: 1px solid var(--ink);
  flex-shrink: 0;
}

.editor-note-head span {
  font-size: 12px;
  font-weight: 800;
  color: var(--ink);
}

.editor-note-title {
  font-size: 14.5px;
  font-weight: 800;
  line-height: 1.45;
  color: var(--ink);
}

.editor-note-reason {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

.editor-note-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1.5px solid var(--lime);
}

.editor-note-link:hover {
  border-bottom-color: var(--orange);
}

@media (min-width: 640px) {
  .home-lead-post.has-thumb {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
    gap: 24px;
  }

  .editorial-row {
    grid-template-columns: 92px minmax(0, 1fr) auto;
    gap: 16px;
    align-items: start;
  }

  .editorial-arrow {
    display: inline-block;
    padding-top: 2px;
  }
}

@media (min-width: 860px) {
  .home-hero-band {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 44px;
    align-items: center;
    padding: 20px 0 48px;
  }

  .home-main h1 {
    font-size: 38px;
    line-height: 1.22;
  }

  .bio {
    font-size: 16.5px;
  }

  .home-hero-nl .newsletter-card.is-hero {
    margin-top: 0;
  }
}

@media (min-width: 900px) {
  .home-stage {
    grid-template-columns: minmax(0, 1.85fr) minmax(0, 1fr);
    gap: 48px;
    align-items: start;
  }

  .home-side-col {
    position: sticky;
    top: 76px;
  }
}

/* Top Nav */
.nav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.nav-top a {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.nav-top a:hover {
  color: var(--orange);
}

.rss-pill {
  font-size: 12px !important;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted) !important;
  text-decoration: none;
}

.rss-pill:hover {
  border-color: var(--ink);
  color: var(--ink) !important;
}

/* Social Link Cards */
.links {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.link-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 16px;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.link-card:hover {
  border-color: var(--ink);
  background: var(--surface-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.05);
}

.link-card.primary {
  border: 2px solid var(--ink);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.link-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.icon-box {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--bg);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.link-card.primary .icon-box {
  background: var(--lime-soft);
  border-color: #C7DE78;
}

.icon-box svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.link-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.link-title {
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.pill {
  font-size: 11px;
  font-weight: 700;
  background: var(--lime);
  color: var(--ink);
  padding: 2px 8px;
  border-radius: 999px;
}

.link-sub {
  font-size: 13px;
  color: var(--muted);
}

.arrow {
  font-size: 18px;
  font-weight: 700;
  color: var(--orange);
  flex-shrink: 0;
  transition: transform 0.16s ease;
}

.link-card:hover .arrow {
  transform: translateX(3px);
}

/* Sections & Post Cards */
.section {
  width: 100%;
  margin-top: 32px;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 12px;
}

.section-head h2 {
  font-size: 16px;
  font-weight: 800;
}

.section-more {
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  text-decoration: none;
}

.section-more:hover {
  color: var(--ink);
}

.page-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.page-title {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.4px;
}

.lead {
  margin-top: 8px;
  margin-bottom: 22px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--muted);
}

.list-main .lead {
  max-width: 680px;
}

.search-box {
  margin-bottom: 14px;
}

.search-input {
  width: 100%;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 14px;
  font-family: inherit;
}

.list-main .search-input {
  max-width: 480px;
}

.search-input:focus {
  outline: none;
  border-color: var(--ink);
}

.empty-search {
  margin-top: 16px;
  padding: 20px;
  text-align: center;
  font-size: 14px;
  color: var(--muted);
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 14px;
}

.tag-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.filter-btn {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.14s ease;
}

.filter-btn:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.filter-btn.is-active {
  background: var(--lime);
  border-color: var(--ink);
  color: var(--ink);
  font-weight: 700;
}

.posts-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.post-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.post-card:hover {
  border-color: var(--ink);
  background: var(--surface-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

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

.post-meta {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
  font-variant-numeric: tabular-nums;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.post-latest-flag {
  font-family: inherit;
  font-size: 11px;
  font-weight: 800;
  color: var(--orange);
}

.post-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.post-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--muted);
}

.post-badge.is-series {
  color: var(--ink);
  border-color: var(--line-strong);
}

.read-badge {
  font-family: inherit;
  font-size: 11px;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: 6px;
  background: var(--lime-soft);
  border: 1px solid #C7DE78;
  color: var(--ink);
}

.post-title {
  font-size: 16.5px;
  font-weight: 800;
  line-height: 1.45;
}

.list-main .post-title {
  font-size: 17.5px;
}

.post-desc {
  margin-top: 7px;
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--muted);
}

.list-main .post-desc {
  font-size: 14px;
}

.post-tags {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.post-card-foot {
  margin-top: auto;
  padding-top: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.post-card-foot .post-tags {
  margin-top: 0;
}

.post-card-featured-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
}

.post-card-thumb {
  display: none;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg);
}

.post-card-thumb img {
  display: block;
  width: 100%;
  height: auto;
}

@media (min-width: 760px) {
  .posts-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    align-items: stretch;
  }

  .posts-grid:not(.is-filtered) .post-card.is-featured {
    grid-column: 1 / -1;
    padding: 26px 28px;
    border-color: var(--line-strong);
  }

  .posts-grid:not(.is-filtered) .post-card.is-featured.has-thumb {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(0, 0.55fr);
    gap: 24px;
    align-items: center;
  }

  .posts-grid:not(.is-filtered) .post-card.is-featured.has-thumb .post-card-thumb {
    display: block;
  }

  .posts-grid:not(.is-filtered) .post-card.is-featured .post-title {
    font-size: 22px;
  }

  .posts-grid:not(.is-filtered) .post-card.is-featured .post-desc {
    font-size: 15px;
    max-width: 780px;
  }
}

@media (min-width: 600px) and (max-width: 859px) {
  .posts-grid-3 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    align-items: stretch;
  }
}

@media (min-width: 860px) {
  .posts-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: stretch;
  }
}

@media (min-width: 820px) {
  .cards-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    align-items: start;
  }
}

.tag {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--muted);
}

/* Article & Prose */
.article-card,
.surface-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 32px 28px;
}

@media (max-width: 520px) {
  .article-card,
  .surface-card {
    padding: 24px 18px;
  }
}

.article-date {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.article-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.jump-prompt-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--lime-soft);
  border: 1px solid #C7DE78;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.jump-prompt-pill:hover {
  border-color: var(--ink);
}

.article-card h1 {
  margin-top: 8px;
  font-size: 28px;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -0.4px;
}

.prose {
  margin-top: 22px;
  padding-top: 24px;
  border-top: 3px double var(--line-strong);
  font-size: 16px;
  line-height: 1.85;
  letter-spacing: 0.015em;
  color: #24221F;
}

.prose h2 {
  margin-top: 30px;
  margin-bottom: 12px;
  padding-left: 11px;
  border-left: 4px solid var(--lime);
  font-size: 20px;
  font-weight: 800;
  line-height: 1.4;
  scroll-margin-top: 24px;
}

.prose h3 {
  margin-top: 22px;
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 700;
}

.prose p {
  margin-bottom: 16px;
}

.prose ul {
  margin: 0 0 18px 22px;
}

.prose ol {
  margin: 0 0 18px 0;
  padding-left: 0;
  list-style: none;
  counter-reset: step-counter;
}

.prose ol > li {
  counter-increment: step-counter;
  position: relative;
  padding-left: 32px;
  margin-bottom: 9px;
}

.prose ol > li::before {
  content: counter(step-counter);
  position: absolute;
  left: 0;
  top: 4px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--lime-soft);
  border: 1px solid #C7DE78;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  font-variant-numeric: tabular-nums;
}

.prose li {
  margin-bottom: 6px;
}

.prose blockquote {
  margin: 18px 0;
  padding: 13px 16px;
  background: #FBF9F4;
  border: 1px solid var(--line);
  border-left: 3px solid var(--ink);
  border-radius: 0 8px 8px 0;
  color: #3D3A34;
}

.prose blockquote.is-warn {
  background: #FFF8F3;
  border-left-color: var(--orange);
}

.prose blockquote p {
  margin-bottom: 0;
}

.prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.9em;
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 1px 5px;
  border-radius: 6px;
}

.code-block {
  position: relative;
  margin: 18px 0;
}

.prose pre,
.code-block pre {
  margin: 0;
  padding: 40px 16px 16px;
  background: #1C1B19;
  color: #F7F4EC;
  border-radius: 12px;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.65;
}

.prose pre code,
.code-block pre code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  background: none;
  border: none;
  padding: 0;
  color: inherit;
  font-size: 13px;
}

.ph-mark {
  background: rgba(179, 223, 42, 0.2);
  color: #E9F5BE;
  border-radius: 4px;
  padding: 0 3px;
  border-bottom: 1px dashed rgba(179, 223, 42, 0.7);
}

.prompt-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  scroll-margin-top: 84px;
  transition: border-color 0.14s ease;
}

.prompt-card:hover {
  border-color: var(--line-strong);
}

.prompt-card:target {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px var(--lime-soft);
}

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

.prompt-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 12px;
  margin-bottom: 8px;
}

.prompt-cat {
  font-size: 12px;
  font-weight: 800;
  color: var(--orange);
}

.prompt-models {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--muted);
}

.prompt-card h2 {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.4;
}

.prompt-summary {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

.prompt-card .code-block {
  margin: 14px 0 12px;
}

.prompt-card .code-block pre {
  background: #F3EFE5;
  color: #1E1D1A;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  white-space: pre-wrap;
  word-break: break-word;
}

.prompt-card .ph-mark {
  background: var(--lime-soft);
  color: var(--ink);
  border-bottom: 1.5px solid #9DC81E;
}

.prompt-card .copy-btn {
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font-weight: 700;
}

.prompt-card .copy-btn:hover {
  border-color: var(--ink);
  background: var(--lime-soft);
}

.prompt-card .copy-btn.is-copied {
  background: var(--lime);
  border-color: var(--ink);
  color: var(--ink);
}

.prompt-note {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
}

.prompt-footer {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.copy-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 10px;
  border-radius: 7px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #F7F4EC;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.14s ease, color 0.14s ease, border-color 0.14s ease;
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.16);
}

.copy-btn.is-copied {
  background: var(--lime);
  border-color: var(--lime);
  color: var(--ink);
}

.prose a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--orange);
  text-underline-offset: 3px;
}

.prose a.glossary-inline {
  text-decoration-style: dashed;
  text-decoration-color: var(--ink);
  background: rgba(233, 245, 190, 0.45);
  padding: 0 3px;
  border-radius: 4px;
}

.gloss-q {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  margin-left: 2px;
  border-radius: 50%;
  border: 1px solid var(--ink);
  background: var(--lime-soft);
  color: var(--ink);
  font-size: 10px;
  font-weight: 800;
  font-family: inherit;
  vertical-align: super;
  cursor: pointer;
}

.gloss-popover {
  position: fixed;
  z-index: 75;
  max-width: 300px;
  padding: 10px 12px;
  background: var(--ink);
  color: #F7F4EC;
  border-radius: 10px;
  font-size: 12.5px;
  line-height: 1.55;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.gloss-popover[hidden] {
  display: none;
}

.gloss-popover a {
  display: inline-block;
  margin-top: 4px;
  color: var(--lime);
  font-weight: 700;
  text-decoration: none;
}

.prose hr {
  margin: 24px 0;
  border: none;
  border-top: 1px solid var(--line);
}

.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--line);
  margin: 14px 0;
}

.table-hint {
  display: none;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  margin: 14px 0 -10px;
}

@media (max-width: 600px) {
  .table-hint {
    display: block;
  }
}

.prose .table-wrap {
  margin: 18px 0;
  overflow-x: auto;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.6;
  font-variant-numeric: tabular-nums;
}

.prose th,
.prose td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.prose th {
  background: var(--bg);
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
}

.prose td:first-child {
  font-weight: 700;
  white-space: nowrap;
}

.prose tbody tr:last-child td {
  border-bottom: none;
}

.refs-box {
  margin-top: 26px;
  padding: 16px 18px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--muted);
}

.refs-verified {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 6px;
}

.refs-box h2 {
  margin-top: 0 !important;
  font-size: 15px !important;
  color: var(--ink);
}

.refs-box ul {
  margin-bottom: 0;
}

.article-end-mark {
  margin: 24px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}

.article-end-mark::before,
.article-end-mark::after {
  content: "";
  height: 1px;
  width: 44px;
  background: var(--line);
}

.article-end-mark img {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid var(--ink);
  background: #1B2A38;
  margin: 0;
}

.helpful-row {
  margin-top: 18px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  color: #3D3A34;
}

.helpful-btn {
  padding: 6px 12px;
  border-radius: 8px;
  border: 1.5px solid var(--ink);
  background: var(--surface);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
}

.helpful-btn:hover:not(:disabled) {
  background: var(--lime-soft);
}

.helpful-btn.is-done {
  background: var(--lime);
  cursor: default;
}

.share-row {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

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

.share-copy-btn {
  padding: 7px 14px;
  border-radius: 9px;
  border: 1.5px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: border-color 0.14s ease, background 0.14s ease;
}

.share-copy-btn:hover {
  border-color: var(--ink);
}

.share-copy-btn.is-copied {
  background: var(--lime-soft);
  border-color: var(--ink);
}

.share-threads-link {
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  text-decoration: none;
}

.share-threads-link:hover {
  color: var(--ink);
}

/* Newsletter Card — Deep Ink Protagonist */
.newsletter-card {
  position: relative;
  width: 100%;
  margin-top: 40px;
  padding: 26px 24px 22px;
  background: var(--ink);
  color: #F7F4EC;
  border: 1.5px solid var(--ink);
  border-radius: 12px;
  box-shadow: 0 10px 26px rgba(22, 22, 22, 0.12);
}

.newsletter-card.is-hero {
  margin-top: 0;
}

.newsletter-card.is-hero .nl-avatar {
  display: none;
}

.nl-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}

.nl-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #1B2A38;
  border: 1.5px solid var(--lime);
  flex-shrink: 0;
  display: block;
  margin-top: 2px;
}

.nl-head-text {
  min-width: 0;
  flex: 1;
}

.nl-badge {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--lime);
  margin-bottom: 5px;
  letter-spacing: 0.01em;
}

.newsletter-card h2 {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.38;
  margin-bottom: 0;
  color: #FFFFFF;
}

.nl-sub {
  font-size: 13.5px;
  line-height: 1.65;
  color: rgba(247, 244, 236, 0.82);
  margin-bottom: 14px;
}

.nl-gift {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  margin-bottom: 16px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.55;
  color: #F7F4EC;
}

.nl-gift-tag {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: 4px;
  background: rgba(179, 223, 42, 0.16);
  border: 1px solid var(--lime);
  color: var(--lime);
  margin-top: 1px;
}

.nl-trust {
  margin-top: 11px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 12px;
  font-size: 12px;
  line-height: 1.5;
  color: rgba(247, 244, 236, 0.72);
}

.nl-sample-link {
  color: var(--lime);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid rgba(179, 223, 42, 0.5);
}

.nl-sample-link:hover {
  border-bottom-color: var(--lime);
}

.newsletter-form {
  display: flex;
  gap: 8px;
}

.newsletter-form input[type="email"] {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.1);
  color: #FFFFFF;
  font-size: 14px;
  font-family: inherit;
}

.newsletter-form input[type="email"]::placeholder {
  color: rgba(247, 244, 236, 0.56);
}

.newsletter-form input[type="email"]:focus {
  outline: none;
  border-color: var(--lime);
  background: rgba(255, 255, 255, 0.14);
}

.newsletter-form button {
  padding: 10px 16px;
  border-radius: 8px;
  border: 1.5px solid var(--lime);
  background: var(--lime);
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.14s ease, filter 0.14s ease;
}

.newsletter-form button:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.04);
}

.newsletter-form button:disabled {
  opacity: 0.65;
  cursor: wait;
}

.newsletter-msg {
  margin-top: 12px;
  margin-bottom: 0;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.5;
  font-weight: 600;
}

.newsletter-msg.is-success {
  background: rgba(179, 223, 42, 0.16);
  border: 1px solid var(--lime);
  color: #E9F5BE;
}

.newsletter-msg.is-error {
  background: rgba(255, 106, 26, 0.16);
  border: 1px solid var(--orange);
  color: #FFD7C2;
}

.surface-card.newsletter-hero {
  background: var(--ink);
  color: #F7F4EC;
  border-color: var(--ink);
  box-shadow: 0 10px 26px rgba(22, 22, 22, 0.12);
}

.surface-card.newsletter-hero h1 {
  color: #FFFFFF;
}

.surface-card.newsletter-hero p {
  color: rgba(247, 244, 236, 0.84);
}

.surface-card.newsletter-hero .pill-badge {
  background: transparent;
  border: none;
  padding: 0;
  color: var(--lime);
  margin-bottom: 8px;
}

.surface-card.newsletter-hero .nl-gift {
  margin-top: 16px;
}

.surface-card.newsletter-hero .newsletter-form {
  margin-top: 14px;
}

.nl-copy,
.nl-action {
  min-width: 0;
}

@media (min-width: 860px) {
  .list-main > .newsletter-card {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: 28px;
    align-items: center;
    padding: 28px 32px;
  }

  .list-main > .newsletter-card .nl-gift {
    margin-bottom: 0;
  }
}

.newsletter-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.newsletter-split > *,
.newsletter-split .section {
  margin-top: 0;
  min-width: 0;
}

@media (min-width: 880px) {
  .newsletter-split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 20px;
    align-items: start;
  }
}

/* Email Preview Card */
.email-preview {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.03);
}

.email-preview-head {
  padding: 14px 20px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted);
}

.email-preview-head strong {
  color: var(--ink);
}

.email-preview-subject {
  margin-top: 4px;
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
}

.email-preview-body {
  padding: 20px;
}

.email-preview-block + .email-preview-block {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.email-preview-kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--lime-soft);
  border: 1px solid #C7DE78;
  color: var(--ink);
  margin-bottom: 6px;
}

.email-preview-block h3 {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 4px;
}

.email-preview-block p {
  font-size: 13.5px;
  line-height: 1.65;
  color: #3D3A34;
}

.email-preview-foot {
  padding: 12px 20px;
  background: var(--bg);
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}

/* Copy Toast */
.copy-toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translate(-50%, 16px);
  opacity: 0;
  width: calc(100% - 32px);
  max-width: 560px;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: var(--ink);
  color: #F7F4EC;
  border: 1.5px solid var(--ink);
  border-radius: 14px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.copy-toast[hidden] {
  display: none;
}

.copy-toast.is-visible {
  transform: translate(-50%, 0);
  opacity: 1;
}

.copy-toast-text {
  font-size: 13px;
  line-height: 1.5;
  font-weight: 600;
}

.copy-toast-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.copy-toast-cta {
  padding: 7px 12px;
  border-radius: 8px;
  border: 1px solid var(--lime);
  background: var(--lime);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
}

.copy-toast-close {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: transparent;
  color: #F7F4EC;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

/* Starter Kit (/welcome/) */
.kit-card {
  scroll-margin-top: 20px;
}

.kit-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.kit-step + .kit-step {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.kit-step-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--lime-soft);
  border: 1px solid #C7DE78;
  color: var(--ink);
  margin-bottom: 6px;
}

.kit-prompts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 14px;
}

.kit-prompts-grid .kit-mini-prompt {
  margin-top: 0;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.kit-prompts-grid .kit-mini-prompt .code-block {
  margin-top: auto;
}

@media (min-width: 820px) {
  .kit-prompts-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    align-items: stretch;
  }
}

.kit-mini-prompt {
  margin-top: 14px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.kit-mini-prompt h4 {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 4px;
}

.kit-mini-prompt p {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
  margin-bottom: 8px;
}

.kit-mini-prompt .code-block {
  margin: 8px 0 0;
}

@media (max-width: 520px) {
  .newsletter-card {
    padding: 20px 16px 18px;
  }

  .copy-toast {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .copy-toast-actions {
    justify-content: flex-end;
  }
}

@media (max-width: 480px) {
  .newsletter-form {
    flex-direction: column;
  }
}

/* Breadcrumb, Stepper, TOC, Embedded Cards & Charts */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

.breadcrumb a {
  color: var(--ink);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--orange);
}

.series-stepper {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 16px;
  padding: 10px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.stepper-node {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 7px 9px;
  border-radius: 9px;
  background: var(--surface);
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.4;
}

.stepper-node strong {
  font-size: 11px;
  color: var(--ink);
}

.stepper-node.is-current {
  background: var(--lime-soft);
  border-color: var(--ink);
  color: var(--ink);
}

.stepper-node.is-read {
  border-color: #9BBF22;
}

@media (max-width: 560px) {
  .series-stepper {
    grid-template-columns: 1fr;
  }
}

.article-layout {
  position: relative;
}

.toc-desktop {
  display: none;
}

@media (min-width: 1180px) {
  .toc-desktop {
    display: block;
    position: fixed;
    top: 108px;
    left: calc(50% + 368px);
    width: 210px;
    padding: 4px 0 4px 16px;
    background: transparent;
    border: none;
    border-left: 1px solid var(--line);
    border-radius: 0;
    font-size: 12px;
  }
}

.toc-title {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--muted);
  margin-bottom: 10px;
}

.toc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.toc-list a {
  color: var(--muted);
  text-decoration: none;
  line-height: 1.45;
  display: block;
  padding-left: 10px;
  margin-left: -17px;
  border-left: 2px solid transparent;
  transition: color 0.14s ease, border-color 0.14s ease;
}

.toc-list a:hover {
  color: var(--ink);
}

.toc-list a.is-active {
  color: var(--ink);
  font-weight: 700;
  border-left-color: var(--lime);
}

.toc-mobile {
  margin-bottom: 18px;
  padding: 10px 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.toc-mobile summary {
  font-size: 13px;
  font-weight: 800;
  color: var(--ink);
  cursor: pointer;
}

.toc-mobile .toc-list {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

@media (min-width: 1180px) {
  .toc-mobile {
    display: none;
  }
}

.article-card-fig {
  margin: 0 0 20px;
  padding: 12px;
  background: var(--bg);
  border: 1.5px solid var(--line);
  border-radius: 14px;
}

.article-card-fig img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--line);
  cursor: zoom-in;
  margin: 0;
}

.article-card-cap {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12.5px;
  color: var(--muted);
}

.card-dl-btn {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid var(--ink);
  background: var(--surface);
  color: var(--ink) !important;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none !important;
}

.card-dl-btn:hover {
  background: var(--lime-soft);
}

.data-chart-card {
  margin: 0 0 22px;
  padding: 16px;
  background: var(--bg);
  border: 1.5px solid var(--line);
  border-radius: 14px;
}

.data-chart-card svg {
  width: 100%;
  height: auto;
  display: block;
}

/* Lightbox & Search Modal */
.lightbox,
.search-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(22, 22, 22, 0.72);
}

.lightbox[hidden],
.search-modal[hidden] {
  display: none;
}

.lightbox-inner {
  position: relative;
  max-width: 780px;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.lightbox-inner img {
  max-width: 100%;
  max-height: 82vh;
  border-radius: 12px;
  border: 2px solid var(--surface);
  background: var(--bg);
}

.lightbox-close {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--surface);
  background: var(--ink);
  color: var(--surface);
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
}

.search-dialog {
  width: 100%;
  max-width: 560px;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 2px solid var(--ink);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.25);
}

.search-dialog-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}

.search-dialog-head input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  font-size: 15px;
  font-family: inherit;
  color: var(--ink);
}

.search-dialog-head input:focus {
  outline: none;
}

.search-results {
  overflow-y: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-result-item {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  text-decoration: none;
  color: var(--ink);
}

.search-result-item:hover {
  border-color: var(--ink);
  background: var(--bg);
}

.search-result-type {
  font-size: 11px;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--lime-soft);
  border: 1px solid #C7DE78;
  color: var(--ink);
  margin-right: 6px;
}

.search-result-title {
  font-size: 14px;
  font-weight: 700;
}

.search-result-sub {
  margin-top: 3px;
  font-size: 12px;
  color: var(--muted);
}

/* Back to top */
.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 20px;
  z-index: 45;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--ink);
  background: var(--surface);
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.back-to-top[hidden] {
  display: none;
}

/* Welcome Checklist & About Stats */
.kit-check-bar {
  margin: 14px 0 18px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1.5px solid var(--line);
  border-radius: 12px;
}

.kit-check-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 10px;
}

.kit-check-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.kit-check-item {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
}

.kit-check-item input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: var(--ink);
}

.kit-check-item.is-checked span {
  text-decoration: line-through;
  color: var(--muted);
}

.about-stats-grid {
  margin: 18px 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.about-stat-box {
  padding: 12px 10px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-align: center;
}

.about-stat-num {
  font-size: 18px;
  font-weight: 800;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.about-stat-label {
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--muted);
  font-weight: 600;
}

.about-collab-grid {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.about-collab-card {
  padding: 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.about-collab-card strong {
  display: block;
  font-size: 14px;
  color: var(--ink);
  margin-bottom: 4px;
}

.about-collab-card p {
  font-size: 12.5px !important;
  line-height: 1.55 !important;
  color: var(--muted) !important;
  margin-top: 0 !important;
}

@media (max-width: 560px) {
  .about-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .about-collab-grid {
    grid-template-columns: 1fr;
  }
}

.print-brand-head {
  display: none;
}

@media print {
  html, body {
    background: #FFFFFF;
    color: #000000;
  }

  .top-bar,
  .site-header,
  footer,
  .copy-btn,
  .share-copy-btn,
  .no-print,
  .copy-toast,
  .toc-desktop,
  .toc-mobile,
  .breadcrumb,
  .series-stepper,
  .series-next-card,
  .newsletter-card,
  .helpful-row,
  .share-row,
  .back-to-top,
  .search-modal,
  .lightbox,
  .gloss-popover,
  .card-dl-btn {
    display: none !important;
  }

  .print-brand-head {
    display: block;
    font-size: 12px;
    color: #666666;
    border-bottom: 1px solid #CCCCCC;
    padding-bottom: 6px;
    margin-bottom: 14px;
  }

  main {
    max-width: 100%;
    padding: 0;
  }

  .surface-card,
  .article-card {
    border: none;
    box-shadow: none;
    padding: 0;
  }

  .prose pre,
  .code-block pre {
    padding: 12px 14px;
    background: #F4F4F4;
    color: #111111;
    border: 1px solid #CCCCCC;
    white-space: pre-wrap;
    word-break: break-word;
  }

  .kit-step,
  .kit-mini-prompt,
  .data-chart-card {
    break-inside: avoid;
  }

  .kit-prompts-grid {
    display: block;
  }

  .kit-prompts-grid .kit-mini-prompt {
    margin-top: 14px;
  }
}

/* Glossary (/decoder/) */
.glossary-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  scroll-margin-top: 84px;
  transition: border-color 0.14s ease;
}

.glossary-card:hover {
  border-color: var(--line-strong);
}

.glossary-card:target {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px var(--lime-soft);
}

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

.glossary-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.glossary-level {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}

.glossary-level::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--line-strong);
  flex-shrink: 0;
}

.glossary-level.is-daily {
  color: var(--ink);
}

.glossary-level.is-daily::before {
  background: var(--lime);
  box-shadow: 0 0 0 1px var(--ink);
}

.glossary-level.is-know {
  color: var(--ink);
}

.glossary-level.is-know::before {
  background: var(--ink);
}

.glossary-level.is-dev {
  color: var(--muted);
}

.glossary-en {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
}

.glossary-card h2 {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.4;
}

.glossary-oneliner {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink);
  font-weight: 600;
}

.glossary-rel {
  margin-top: 8px;
  margin-bottom: 10px;
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--muted);
}

.glossary-verdict {
  margin-top: 2px;
  margin-bottom: 14px;
  align-self: flex-start;
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--ink);
}

.glossary-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

/* Timeline (/whats-new/) */
.whats-new-timeline,
.whats-new-aside {
  min-width: 0;
}

@media (min-width: 900px) {
  .whats-new-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 32px;
    align-items: start;
  }

  .whats-new-aside .skip-card {
    margin-top: 28px;
    position: sticky;
    top: 76px;
  }
}
.timeline-group + .timeline-group {
  margin-top: 26px;
}

.timeline-period {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 12px;
}

.timeline-list {
  position: relative;
  padding-left: 20px;
  border-left: 2px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.timeline-item {
  position: relative;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -27px;
  top: 22px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--lime);
  border: 2px solid var(--ink);
}

.timeline-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.timeline-platform {
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--orange);
}

.timeline-item h3 {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.45;
  color: var(--ink);
}

.timeline-item p {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.65;
  color: #3D3A34;
}

.timeline-links {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  font-weight: 700;
}

.timeline-links a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--orange);
  text-underline-offset: 3px;
}

.skip-card {
  margin-top: 28px;
  padding: 18px 20px;
  background: #FBF9F4;
  border: 1px solid var(--line);
  border-left: 3px solid var(--orange);
  border-radius: 0 12px 12px 0;
}

.skip-card-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 12px;
}

.skip-card-head img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #1B2A38;
  border: 1px solid var(--ink);
  flex-shrink: 0;
}

.skip-card h2 {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 0;
}

.skip-item + .skip-item {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.skip-item strong {
  display: block;
  font-size: 14px;
  color: var(--ink);
  margin-bottom: 2px;
}

.skip-item p {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--muted);
}

/* Series Navigation */
.series-banner {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 3px 9px;
  margin-bottom: 12px;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
}

.series-next-card {
  display: block;
  margin-top: 20px;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  transition: transform 0.14s ease, border-color 0.14s ease;
}

.series-next-card:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
}

.series-next-kicker {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--orange);
  margin-bottom: 4px;
}

.series-next-hook {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
  margin-bottom: 6px;
}

.series-next-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 16px;
  font-weight: 800;
}

/* About, Empty, 404 */
.pill-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--muted);
  margin-bottom: 12px;
}

.surface-card h1 {
  font-size: 26px;
  font-weight: 800;
  line-height: 1.35;
}

.surface-card h2 {
  margin-top: 24px;
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 800;
}

.surface-card p,
.surface-card li {
  font-size: 15px;
  line-height: 1.75;
  color: #3D3A34;
}

.surface-card p + p {
  margin-top: 10px;
}

.surface-card ul {
  margin: 8px 0 0 20px;
}

.surface-card li + li {
  margin-top: 6px;
}

.surface-card a.inline-link {
  color: var(--ink);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--orange);
  text-underline-offset: 3px;
}

.tip-box {
  margin-top: 16px;
  padding: 14px 16px;
  background: var(--bg);
  border-left: 3px solid var(--lime);
  border-radius: 0 8px 8px 0;
}

.tip-box p {
  font-size: 14px;
  line-height: 1.65;
}

.actions {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.btn-primary {
  background: var(--lime);
  border: 1.5px solid var(--ink);
  color: var(--ink);
}

.btn-secondary {
  background: var(--bg);
  border: 1px solid var(--line-strong);
  color: var(--ink);
}

/* Editorial Footer */
footer.site-footer {
  margin-top: 56px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  width: 100%;
  font-size: 13px;
  color: var(--muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 720px) {
  .footer-grid {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
  }
}

.footer-brand {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.footer-brand img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #1B2A38;
  border: 1.5px solid var(--ink);
  flex-shrink: 0;
}

.footer-brand-name {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--ink);
}

.footer-brand-desc {
  margin-top: 4px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

.footer-social {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  font-size: 12.5px;
}

.footer-social a {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
}

.footer-social a:hover {
  border-bottom-color: var(--orange);
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 20px;
}

.footer-nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
}

.footer-nav a:hover {
  color: var(--ink);
}

.footer-bottom {
  margin-top: 24px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px 16px;
  font-size: 12px;
  color: var(--muted);
}
