:root {
  --green: #009859;
  --green-dark: #063d2c;
  --green-soft: #eaf5f0;
  --ink: #12372c;
  --muted: #69847b;
  --line: #dce9e4;
  --paper: #ffffff;
  --wash: #f5f9f7;
  --blue: #2e6da4;
  --red: #b63b45;
  --amber: #9a6616;
  --shadow: 0 10px 28px rgba(8, 60, 43, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.75;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.site-header-inner,
.page-shell,
.article-shell,
.footer-inner {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  gap: 28px;
}

.brand img {
  width: 118px;
  height: auto;
}

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

.site-nav a {
  border-bottom: 2px solid transparent;
  color: var(--muted);
  padding: 19px 10px 17px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 650;
}

.site-nav a:hover,
.site-nav a.active {
  border-bottom-color: var(--green);
  color: var(--green-dark);
}

.site-nav .social-link {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 7px 11px;
  color: var(--green-dark);
}

.site-nav .social-link:hover {
  border-color: var(--green);
}

.library-hero {
  padding: 68px 0 42px;
  border-bottom: 1px solid var(--line);
  background: var(--wash);
}

.eyebrow,
.article-kicker,
.series-number {
  color: var(--green);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.library-hero h1 {
  max-width: 780px;
  margin: 12px 0 16px;
  color: var(--green-dark);
  font-family: Georgia, "Songti SC", serif;
  font-size: clamp(38px, 5vw, 62px);
  font-weight: 500;
  line-height: 1.16;
}

.library-hero h1 em {
  color: var(--green);
  font-style: normal;
}

.hero-summary {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
}

.series-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.series-facts span {
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 7px 11px;
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 12px;
}

.series-intro {
  display: grid;
  grid-template-columns: minmax(220px, 0.72fr) 1.28fr;
  align-items: center;
  gap: 54px;
  padding: 56px 0;
}

.series-cover {
  width: min(100%, 390px);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.series-copy h2,
.library-heading h2 {
  margin: 8px 0 14px;
  font-family: Georgia, "Songti SC", serif;
  font-size: 30px;
  font-weight: 500;
  line-height: 1.3;
}

.series-copy p {
  color: var(--muted);
}

.series-copy a,
.social-cta a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--green);
  border-radius: 6px;
  background: var(--green);
  color: #fff;
  padding: 8px 15px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
}

.article-library {
  padding: 0 0 72px;
}

.library-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--line);
  padding: 44px 0 24px;
}

.article-search {
  width: min(100%, 350px);
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: 0;
  background: var(--paper);
  color: var(--ink);
  padding: 0 13px;
  font: inherit;
  font-size: 14px;
}

.article-search:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(0, 152, 89, 0.12);
}

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

.article-card {
  display: grid;
  grid-template-columns: 172px minmax(0, 1fr);
  min-height: 190px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  text-decoration: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.article-card:hover {
  transform: translateY(-2px);
  border-color: #a8cfc0;
  box-shadow: var(--shadow);
}

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

.article-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-right: 1px solid var(--line);
}

.article-card-copy {
  display: flex;
  flex-direction: column;
  padding: 18px;
}

.article-card h3 {
  margin: 7px 0 8px;
  font-size: 17px;
  line-height: 1.45;
}

.article-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.read-more {
  margin-top: auto;
  padding-top: 12px;
  color: var(--green);
  font-size: 13px;
  font-weight: 700;
}

.empty-state {
  display: none;
  border: 1px dashed var(--line);
  padding: 28px;
  color: var(--muted);
  text-align: center;
}

.article-shell {
  max-width: 820px;
  padding-top: 32px;
  padding-bottom: 72px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
}

.breadcrumb a {
  text-decoration: none;
}

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

.article-header {
  padding: 48px 0 28px;
}

.article-header h1 {
  margin: 12px 0 18px;
  color: var(--green-dark);
  font-family: Georgia, "Songti SC", serif;
  font-size: clamp(34px, 5vw, 54px);
  font-weight: 500;
  line-height: 1.22;
}

.article-deck {
  max-width: 700px;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.article-hero-image {
  width: 100%;
  aspect-ratio: 15 / 6;
  border: 1px solid var(--line);
  background: var(--wash);
  object-fit: cover;
}

.article-body {
  padding-top: 26px;
  font-family: Georgia, "Noto Serif SC", "Songti SC", serif;
  font-size: 18px;
  line-height: 1.9;
}

.article-body h2 {
  margin: 50px 0 16px;
  color: var(--green-dark);
  font-family: Inter, "PingFang SC", sans-serif;
  font-size: 25px;
  line-height: 1.4;
}

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

.article-body ul,
.article-body ol {
  margin: 0 0 24px;
  border-left: 3px solid var(--green);
  background: var(--wash);
  padding: 18px 22px 18px 44px;
}

.article-body li + li {
  margin-top: 8px;
}

.article-figure {
  margin: 24px 0 30px;
}

.article-figure img {
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  background: #fff;
}

.social-cta {
  margin: 54px 0 30px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--green-soft);
  padding: 30px;
}

.social-cta h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.social-cta p {
  margin: 0 0 18px;
  color: var(--muted);
}

.article-pagination {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.article-pagination a,
.article-pagination span {
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 14px 16px;
  text-decoration: none;
}

.article-pagination a:hover {
  border-color: var(--green);
}

.article-pagination small {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 11px;
}

.article-pagination strong {
  font-size: 14px;
  line-height: 1.45;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--wash);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 82px;
  gap: 20px;
  color: var(--muted);
  font-size: 13px;
}

.footer-inner a {
  color: var(--green-dark);
}

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

  .series-cover {
    width: 260px;
  }

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

@media (max-width: 620px) {
  .site-header-inner,
  .page-shell,
  .article-shell,
  .footer-inner {
    width: min(100% - 28px, 1160px);
  }

  .site-header-inner {
    min-height: 60px;
  }

  .brand img {
    width: 96px;
  }

  .site-nav a {
    padding: 17px 5px 15px;
    font-size: 12px;
  }

  .site-nav a:first-child,
  .site-nav .social-link {
    display: none;
  }

  .library-hero {
    padding: 46px 0 32px;
  }

  .library-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .article-search {
    width: 100%;
  }

  .article-card {
    grid-template-columns: 124px minmax(0, 1fr);
    min-height: 170px;
  }

  .article-card-copy {
    padding: 14px;
  }

  .article-card h3 {
    font-size: 15px;
  }

  .article-card p {
    display: none;
  }

  .article-header {
    padding-top: 36px;
  }

  .article-deck,
  .article-body {
    font-size: 16px;
  }

  .article-body h2 {
    font-size: 22px;
  }

  .article-body ul,
  .article-body ol {
    padding: 16px 16px 16px 36px;
  }

  .article-pagination {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding: 18px 0;
  }
}
