.article-page .lang-en {
  display: none;
}

html[data-lang="en"] .article-page .lang-zh {
  display: none;
}

html[data-lang="en"] .article-page .lang-en {
  display: inline;
}

html[data-lang="en"] .article-page p.lang-en,
html[data-lang="en"] .article-page .article-deck.lang-en,
html[data-lang="en"] .article-page .article-lead.lang-en {
  display: block;
}

.article-page {
  background: #f8f5ee;
  color: var(--ink);
}

.article-hero {
  padding: clamp(118px, 12vw, 176px) clamp(22px, 7vw, 110px) clamp(54px, 7vw, 96px);
  background:
    radial-gradient(circle at 82% 18%, rgba(182, 151, 91, 0.16), transparent 27%),
    linear-gradient(135deg, #f3eee4 0%, #fffdf8 62%, #eee6d7 100%);
  border-bottom: 1px solid rgba(93, 87, 72, 0.14);
}

.article-hero-inner {
  width: min(1080px, 100%);
  margin: 0 auto;
}

.article-breadcrumb {
  display: inline-flex;
  margin-bottom: 30px;
  color: #8f7957;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.article-hero h1 {
  max-width: 980px;
  margin: 0;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: clamp(36px, 5.2vw, 72px);
  font-weight: 500;
  line-height: 1.16;
  letter-spacing: -0.035em;
}

.article-deck {
  max-width: 790px;
  margin: 28px 0 0;
  color: #6f685b;
  font-size: clamp(17px, 1.6vw, 21px);
  line-height: 1.8;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 26px;
  margin-top: 34px;
  color: #8b8376;
  font-size: 13px;
  letter-spacing: 0.06em;
}

.article-meta > * + *::before {
  content: "";
  display: inline-block;
  width: 1px;
  height: 12px;
  margin-right: 26px;
  background: rgba(93, 87, 72, 0.3);
  vertical-align: -1px;
}

.article-share {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.share-button,
.copy-button,
.back-link {
  min-height: 44px;
  padding: 0 20px;
  border: 1px solid rgba(83, 73, 56, 0.34);
  background: transparent;
  color: #3f382f;
  font: inherit;
  font-size: 14px;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: 180ms ease;
}

.share-button {
  background: #25221e;
  color: #fffdf8;
  border-color: #25221e;
}

.share-button:hover,
.share-button:focus-visible {
  background: #9a7a45;
  border-color: #9a7a45;
}

.copy-button:hover,
.copy-button:focus-visible,
.back-link:hover,
.back-link:focus-visible {
  border-color: #9a7a45;
  color: #7b5e32;
}

.share-status {
  min-height: 20px;
  color: #7b5e32;
  font-size: 13px;
}

.article-cover {
  width: min(1240px, calc(100% - 44px));
  margin: clamp(34px, 5vw, 68px) auto 0;
  background: #e9e3d7;
  box-shadow: 0 26px 70px rgba(61, 52, 40, 0.14);
}

.article-cover img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 720px;
  object-fit: cover;
}

.article-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 760px);
  gap: clamp(44px, 7vw, 96px);
  width: min(1100px, calc(100% - 44px));
  margin: clamp(54px, 8vw, 104px) auto clamp(82px, 10vw, 132px);
  align-items: start;
}

.article-toc {
  position: sticky;
  top: 112px;
  display: grid;
  gap: 12px;
  padding: 24px 0;
  border-top: 1px solid rgba(93, 87, 72, 0.22);
  border-bottom: 1px solid rgba(93, 87, 72, 0.22);
}

.article-toc strong {
  margin-bottom: 8px;
  font-size: 13px;
  letter-spacing: 0.14em;
  color: #8b795c;
}

.article-toc a {
  color: #777064;
  font-size: 13px;
  line-height: 1.55;
  transition: color 160ms ease;
}

.article-toc a:hover,
.article-toc a:focus-visible {
  color: #8e6c37;
}

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

.article-content section {
  scroll-margin-top: 120px;
  margin-bottom: 62px;
}

.article-content h2 {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 0 0 24px;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: clamp(26px, 3vw, 38px);
  font-weight: 500;
  line-height: 1.35;
}

.section-number {
  color: #b19159;
  font-family: Georgia, serif;
  font-size: 15px;
  letter-spacing: 0.1em;
}

.article-content p,
.article-content li {
  color: #514b42;
  font-size: 17px;
  line-height: 1.95;
}

.article-content p {
  margin: 0 0 20px;
}

.article-content .article-lead {
  margin-bottom: 34px;
  color: #39342d;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: clamp(19px, 2vw, 23px);
  line-height: 1.9;
}

.article-content ul,
.article-content ol {
  margin: 22px 0 28px;
  padding-left: 1.35em;
}

.article-content li + li {
  margin-top: 13px;
}

.article-content blockquote {
  margin: 30px 0;
  padding: 24px 28px;
  border-left: 3px solid #aa8a53;
  background: #f0eadf;
}

.article-content blockquote p {
  margin: 0;
  color: #403930;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: 18px;
}

.article-table-wrap {
  overflow-x: auto;
  margin: 30px 0;
  border: 1px solid rgba(83, 73, 56, 0.18);
  background: #fffdf8;
}

.article-content table {
  width: 100%;
  min-width: 660px;
  border-collapse: collapse;
}

.article-content th,
.article-content td {
  padding: 18px 20px;
  border-bottom: 1px solid rgba(83, 73, 56, 0.13);
  border-right: 1px solid rgba(83, 73, 56, 0.1);
  text-align: left;
  vertical-align: top;
  font-size: 15px;
  line-height: 1.7;
}

.article-content th {
  background: #eee7da;
  color: #4d4438;
  font-weight: 600;
}

.article-content tr:last-child td {
  border-bottom: 0;
}

.article-content th:last-child,
.article-content td:last-child {
  border-right: 0;
}

.comparison-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 28px;
}

.comparison-grid > div {
  padding: 28px;
  background: #fffdf8;
  border: 1px solid rgba(83, 73, 56, 0.16);
}

.comparison-grid strong {
  display: block;
  margin-bottom: 14px;
  color: #8a6936;
  font-size: 15px;
  letter-spacing: 0.06em;
}

.comparison-grid p:last-child {
  margin-bottom: 0;
}

.article-callout {
  margin-top: 32px;
  padding: 30px;
  background: #28241f;
  color: #fffaf1;
}

.article-callout strong {
  display: block;
  margin-bottom: 12px;
  color: #d8bd8d;
  letter-spacing: 0.12em;
}

.article-callout p {
  margin: 0;
  color: #eee8dd;
}

.article-references {
  padding-top: 36px;
  border-top: 1px solid rgba(83, 73, 56, 0.18);
}

.article-bottom-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 34px;
  border-top: 1px solid rgba(83, 73, 56, 0.18);
}

.back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 900px) {
  .article-layout {
    grid-template-columns: 1fr;
  }

  .article-toc {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .article-toc strong {
    grid-column: 1 / -1;
  }
}

@media (max-width: 680px) {
  .article-hero {
    padding-inline: 20px;
  }

  .article-cover,
  .article-layout {
    width: calc(100% - 28px);
  }

  .article-meta > * + *::before {
    display: none;
  }

  .article-toc,
  .comparison-grid {
    grid-template-columns: 1fr;
  }

  .article-content h2 {
    display: block;
  }

  .section-number {
    display: block;
    margin-bottom: 7px;
  }

  .article-content p,
  .article-content li {
    font-size: 16px;
  }

  .article-content blockquote,
  .comparison-grid > div,
  .article-callout {
    padding: 22px;
  }

  .article-bottom-actions > * {
    width: 100%;
  }
}

/* Bilingual long-form article blocks */
.article-language-block.lang-zh { display: block; }
.article-language-block.lang-en { display: none; }
html[data-lang="en"] .article-language-block.lang-zh { display: none; }
html[data-lang="en"] .article-language-block.lang-en { display: block; }
.article-toc a.lang-zh { display: block; }
.article-toc a.lang-en { display: none; }
html[data-lang="en"] .article-toc a.lang-zh { display: none; }
html[data-lang="en"] .article-toc a.lang-en { display: block; }
.article-page.long-title .article-hero h1 { font-size: clamp(32px, 4.25vw, 60px); }
.article-content h3 {
  margin: 34px 0 16px;
  color: #403930;
  font-family: "Noto Serif SC", "Songti SC", Georgia, serif;
  font-size: clamp(21px, 2.2vw, 28px);
  font-weight: 500;
  line-height: 1.45;
}
.article-language-block > section:last-child { margin-bottom: 28px; }
