:root {
  --ink: #182020;
  --muted: #66706f;
  --paper: #f8f5ef;
  --white: #fffdf9;
  --mist: #e8f0ee;
  --teal: #1d6a64;
  --teal-dark: #164d49;
  --brass: #b78245;
  --clay: #a65b44;
  --sage: #70886f;
  --line: #d8d0c3;
  --shadow: 0 18px 50px rgba(24, 32, 32, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.72;
}

body.nav-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 20;
  background: var(--ink);
  color: var(--white);
  padding: 10px 14px;
  border-radius: 6px;
}

.skip-link:focus {
  top: 16px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(216, 208, 195, 0.76);
  background: rgba(248, 245, 239, 0.94);
  backdrop-filter: blur(14px);
}

.nav-wrap {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 180px;
}

.brand strong {
  font-size: 18px;
}

.brand span {
  color: var(--muted);
  font-size: 13px;
}

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

.nav-links a {
  border-radius: 6px;
  color: #33403f;
  font-size: 15px;
  padding: 9px 12px;
}

.nav-links a:hover,
.nav-links a.active {
  background: var(--mist);
  color: var(--teal-dark);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

.container {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.narrow {
  width: min(820px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  position: relative;
  min-height: 580px;
  height: 78vh;
  max-height: 760px;
  overflow: hidden;
  background: #1b2522;
  color: var(--white);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(16, 24, 23, 0.86) 0%, rgba(16, 24, 23, 0.66) 38%, rgba(16, 24, 23, 0.18) 78%),
    url("hero-resolution-table.png");
  background-position: center;
  background-size: cover;
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 0 72px;
}

.eyebrow {
  margin: 0 0 14px;
  color: #d7c7a7;
  font-size: 14px;
  font-weight: 700;
}

.hero h1 {
  width: min(900px, 100%);
  margin: 0;
  font-size: 50px;
  line-height: 1.12;
  font-weight: 800;
}

.page-hero h1 {
  width: min(820px, 100%);
  margin: 0;
  font-size: 50px;
  line-height: 1.12;
  font-weight: 800;
}

.hero-lead {
  width: min(700px, 100%);
  margin: 22px 0 0;
  color: rgba(255, 253, 249, 0.86);
  font-size: 19px;
}

.hero-actions,
.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 10px 18px;
  font-size: 15px;
  font-weight: 700;
}

.button.primary {
  background: var(--brass);
  color: #171513;
}

.button.primary:hover {
  background: #c59358;
}

.button.secondary {
  border-color: rgba(255, 253, 249, 0.48);
  color: var(--white);
}

.button.secondary:hover {
  background: rgba(255, 253, 249, 0.12);
}

.button.outline {
  border-color: var(--line);
  color: var(--teal-dark);
  background: var(--white);
}

.button.outline:hover {
  border-color: var(--teal);
}

.cred-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border-bottom: 1px solid var(--line);
}

.cred-item {
  background: var(--white);
  padding: 24px;
}

.cred-item strong {
  display: block;
  color: var(--teal-dark);
  font-size: 23px;
  line-height: 1.2;
}

.cred-item span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.section {
  padding: 76px 0;
}

.section.alt {
  background: var(--white);
}

.section.soft {
  background: var(--mist);
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(280px, 0.65fr);
  gap: 42px;
  align-items: end;
  margin-bottom: 34px;
}

.section-head h2 {
  margin: 0;
  font-size: 34px;
  line-height: 1.22;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

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

.card {
  min-height: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 24px;
  box-shadow: 0 8px 24px rgba(24, 32, 32, 0.05);
}

.card.compact {
  padding: 20px;
}

.card h3 {
  margin: 0 0 10px;
  font-size: 21px;
  line-height: 1.35;
}

.card p {
  margin: 0;
  color: var(--muted);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.tag {
  border: 1px solid rgba(29, 106, 100, 0.26);
  border-radius: 6px;
  color: var(--teal-dark);
  background: #f5faf8;
  padding: 5px 9px;
  font-size: 13px;
  line-height: 1.3;
}

.method {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 36px;
  align-items: start;
}

.method-panel {
  position: sticky;
  top: 104px;
}

.method-panel h2 {
  margin: 0 0 14px;
  font-size: 34px;
  line-height: 1.22;
}

.method-panel p {
  margin: 0;
  color: var(--muted);
}

.steps {
  display: grid;
  gap: 14px;
}

.step {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 16px;
  border-left: 4px solid var(--teal);
  background: var(--white);
  padding: 18px;
}

.step-number {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--mist);
  color: var(--teal-dark);
  font-weight: 800;
}

.step h3 {
  margin: 0 0 6px;
  font-size: 19px;
}

.step p {
  margin: 0;
  color: var(--muted);
}

.quote-band {
  background: var(--teal-dark);
  color: var(--white);
  padding: 54px 0;
}

.quote-band blockquote {
  width: min(940px, calc(100% - 40px));
  margin: 0 auto;
  font-size: 27px;
  line-height: 1.45;
}

.quote-band cite {
  display: block;
  margin-top: 18px;
  color: rgba(255, 253, 249, 0.74);
  font-size: 15px;
  font-style: normal;
}

.article-list {
  display: grid;
  gap: 14px;
}

.article-card {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 18px;
}

.article-meta {
  color: var(--muted);
  font-size: 14px;
}

.article-card h3 {
  margin: 4px 0 8px;
  font-size: 22px;
  line-height: 1.35;
}

.article-card p {
  margin: 0;
  color: var(--muted);
}

.article-card:hover h3 {
  color: var(--teal);
}

.page-hero {
  background: var(--white);
  border-bottom: 1px solid var(--line);
  padding: 72px 0 56px;
}

.page-hero p {
  width: min(760px, 100%);
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.toc {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  padding: 14px 0;
}

.toc .container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.toc a {
  border-radius: 6px;
  background: var(--white);
  color: var(--teal-dark);
  padding: 7px 11px;
  font-size: 14px;
}

.split {
  display: grid;
  grid-template-columns: 0.76fr 1.24fr;
  gap: 42px;
}

.side-note {
  border-left: 4px solid var(--brass);
  background: var(--white);
  padding: 20px;
}

.side-note h2,
.side-note h3 {
  margin: 0 0 10px;
  font-size: 20px;
}

.side-note p {
  margin: 0;
  color: var(--muted);
}

.rich-text h2 {
  margin: 42px 0 12px;
  font-size: 28px;
  line-height: 1.28;
}

.rich-text h3 {
  margin: 28px 0 8px;
  font-size: 21px;
}

.rich-text p,
.rich-text li {
  color: #394442;
}

.rich-text ul,
.rich-text ol {
  padding-left: 22px;
}

.rich-text a {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.callout {
  border: 1px solid rgba(183, 130, 69, 0.4);
  border-left: 5px solid var(--brass);
  background: #fff8eb;
  padding: 20px;
  margin: 28px 0;
}

.faq {
  display: grid;
  gap: 12px;
}

.faq details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: 18px 20px;
}

.faq summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 800;
}

.faq p {
  margin: 10px 0 0;
  color: var(--muted);
}

.contact-band {
  background: #232c2a;
  color: var(--white);
  padding: 68px 0;
}

.contact-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 40px;
  align-items: center;
}

.contact-inner h2 {
  margin: 0;
  font-size: 34px;
  line-height: 1.22;
}

.contact-inner p {
  margin: 14px 0 0;
  color: rgba(255, 253, 249, 0.76);
}

.contact-box {
  border: 1px solid rgba(255, 253, 249, 0.18);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.06);
  padding: 22px;
}

.contact-box strong {
  display: block;
  margin-bottom: 8px;
}

.contact-box span {
  color: rgba(255, 253, 249, 0.76);
  font-size: 14px;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--white);
  padding: 28px 0;
  color: var(--muted);
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-links a {
  color: var(--teal-dark);
}

@media (max-width: 900px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    position: fixed;
    left: 0;
    right: 0;
    top: 72px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    padding: 12px 20px 20px;
  }

  body.nav-open .nav-links {
    display: flex;
  }

  .nav-links a {
    padding: 13px 12px;
  }

  .hero {
    min-height: 520px;
    height: 74vh;
  }

  .hero h1,
  .page-hero h1 {
    font-size: 40px;
  }

  .hero-lead,
  .page-hero p {
    font-size: 17px;
  }

  .cred-row,
  .grid-3,
  .grid-2,
  .section-head,
  .method,
  .split,
  .contact-inner {
    grid-template-columns: 1fr;
  }

  .method-panel {
    position: static;
  }

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

  .article-meta {
    order: 2;
  }
}

@media (max-width: 560px) {
  .container,
  .narrow,
  .nav-wrap,
  .hero-content {
    width: min(100% - 28px, 1160px);
  }

  .brand {
    min-width: 0;
  }

  .brand span {
    display: none;
  }

  .hero {
    min-height: 500px;
    height: 72vh;
  }

  .hero::before {
    background-image:
      linear-gradient(90deg, rgba(16, 24, 23, 0.9), rgba(16, 24, 23, 0.58)),
      url("hero-resolution-table.png");
    background-position: 60% center;
  }

  .hero h1,
  .page-hero h1 {
    font-size: 32px;
  }

  .section,
  .page-hero {
    padding: 54px 0;
  }

  .section-head h2,
  .method-panel h2,
  .contact-inner h2 {
    font-size: 28px;
  }

  .quote-band blockquote {
    font-size: 22px;
  }

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

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