html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Exo 2", system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 17px;
  line-height: 1.7;
  color: #172620;
  background-color: #eef9f4;
  background-image: radial-gradient(rgba(23, 38, 32, 0.13) 1.4px, transparent 1.4px);
  background-size: 22px 22px;
  overflow-x: hidden;
}

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

a {
  color: #12503f;
}

h1,
h2,
h3 {
  font-family: Orbitron, "Exo 2", system-ui, "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.3;
  letter-spacing: 0.01em;
}

/* ---------- 左侧竖排导航 ---------- */

.rail {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 266px;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: linear-gradient(160deg, #b4fde1 0%, #add8e6 100%);
  border-right: 4px solid #172620;
  box-shadow: inset -8px 0 18px rgba(23, 38, 32, 0.09);
  overflow-y: auto;
  z-index: 30;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  min-height: 48px;
  border: 3px solid #172620;
  border-radius: 20px;
  background: #ffffff;
  color: #172620;
  text-decoration: none;
  font-family: Orbitron, "Exo 2", system-ui, sans-serif;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.05em;
  box-shadow: inset -3px -3px 10px rgba(173, 216, 230, 0.85), 4px 4px 0 rgba(23, 38, 32, 0.9);
  transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}

.brand:hover {
  transform: translate(-1px, -2px);
  box-shadow: inset -3px -3px 10px rgba(173, 216, 230, 0.85), 6px 6px 0 rgba(23, 38, 32, 0.9);
}

.brand-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex: none;
  background: #b4fde1;
  border: 3px solid #172620;
  box-shadow: inset -2px -2px 4px rgba(23, 38, 32, 0.35);
}

.brand-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rail-nav {
  min-width: 0;
}

.rail-nav ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.rail-nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 9px 15px;
  border: 3px solid #172620;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
  color: #172620;
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.35;
  box-shadow: inset -2px -2px 7px rgba(173, 216, 230, 0.8), 3px 3px 0 rgba(23, 38, 32, 0.55);
  transition: transform 0.2s ease-out, background-color 0.2s ease-out, box-shadow 0.2s ease-out;
}

.rail-nav a:hover,
.rail-nav a:focus-visible {
  background: #ffffff;
  transform: translate(-1px, -2px);
  box-shadow: inset -2px -2px 7px rgba(173, 216, 230, 0.8), 5px 6px 0 rgba(23, 38, 32, 0.75);
}

.rail-nav a:active {
  transform: translate(1px, 1px);
  box-shadow: inset -2px -2px 7px rgba(173, 216, 230, 0.8), 2px 2px 0 rgba(23, 38, 32, 0.5);
}

.rail-contact {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 14px;
  border: 3px solid #172620;
  border-radius: 20px;
  background: linear-gradient(150deg, #ffffff, #b4fde1);
  color: #172620;
  text-decoration: none;
  font-weight: 700;
  font-size: 16px;
  box-shadow: inset -3px -3px 9px rgba(173, 216, 230, 0.9), 4px 4px 0 rgba(23, 38, 32, 0.85);
  transition: transform 0.2s ease-out;
}

.rail-contact:hover {
  transform: translate(-1px, -2px);
}

.rail-contact:active {
  transform: translate(1px, 2px);
}

/* ---------- 主区 ---------- */

main {
  margin-left: 266px;
  padding: 0 26px;
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 0 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 296px;
  gap: 26px;
  align-items: start;
}

.hero {
  grid-column: 1 / -1;
  position: relative;
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  grid-template-areas: "media text";
  min-height: 45vh;
  padding: 26px 28px;
  background: linear-gradient(150deg, #ffffff 0%, #d8fbee 55%, #c8ecf6 100%);
  border: 4px solid #172620;
  border-radius: 24px 24px 96px 24px;
  box-shadow: inset -6px -6px 16px rgba(173, 216, 230, 0.7), 9px 9px 0 rgba(23, 38, 32, 0.16);
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -40px -60px auto;
  width: 240px;
  height: 240px;
  background-image: radial-gradient(rgba(23, 38, 32, 0.16) 2px, transparent 2px);
  background-size: 16px 16px;
  border-radius: 50%;
  pointer-events: none;
}

.hero-text {
  grid-area: text;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  gap: 16px;
  text-align: right;
  position: relative;
  z-index: 1;
}

.hero h1 {
  margin: 0;
  font-size: clamp(28px, 3.6vw, 46px);
  font-weight: 700;
  text-wrap: balance;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 11px 22px;
  border: 3px solid #172620;
  border-radius: 999px;
  background: #b4fde1;
  color: #172620;
  text-decoration: none;
  font-weight: 700;
  font-size: 16px;
  box-shadow: inset -3px -3px 9px rgba(255, 255, 255, 0.9), 4px 5px 0 rgba(23, 38, 32, 0.9);
  transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}

.hero-cta:hover {
  transform: translate(-1px, -2px);
  box-shadow: inset -3px -3px 9px rgba(255, 255, 255, 0.9), 6px 7px 0 rgba(23, 38, 32, 0.9);
}

.hero-cta:active {
  transform: translate(1px, 2px);
  box-shadow: inset -3px -3px 9px rgba(255, 255, 255, 0.9), 2px 2px 0 rgba(23, 38, 32, 0.85);
}

.hero-media {
  grid-area: media;
  min-width: 0;
  border-radius: 18px;
  overflow: hidden;
  align-self: stretch;
}

.hero-media:empty {
  display: none;
}

.hero-media img {
  width: 100%;
  height: 100%;
  min-height: 200px;
  object-fit: cover;
  border: 3px solid #172620;
  border-radius: 18px;
}

/* ---------- 正文 ---------- */

.body-main {
  min-width: 0;
}

main div[id] {
  scroll-margin-top: 92px;
}

.prose {
  font-size: 17px;
  line-height: 1.8;
}

.prose > div {
  background: rgba(255, 255, 255, 0.74);
  border: 3px solid #172620;
  border-radius: 20px;
  padding: 22px 22px 18px;
  margin: 0 0 22px;
  box-shadow: inset -3px -3px 12px rgba(173, 216, 230, 0.55), 4px 6px 18px rgba(23, 38, 32, 0.13);
}

.prose h2 {
  margin: 0 0 14px;
  font-size: 23px;
  font-weight: 700;
}

.prose h2 span {
  display: inline-block;
  padding-bottom: 4px;
  border-bottom: 4px solid #b4fde1;
}

.prose h3 {
  margin: 20px 0 10px;
  font-size: 19px;
}

.prose p {
  margin: 0 0 14px;
}

.prose ul,
.prose ol {
  margin: 0 0 14px;
  padding-left: 1.3em;
}

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

.prose a {
  color: #0f4a3a;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  text-decoration-color: #add8e6;
}

.prose a:hover {
  text-decoration-color: #172620;
}

.prose img {
  border: 3px solid #172620;
  border-radius: 16px;
  margin: 6px 0 16px;
  box-shadow: inset -2px -2px 8px rgba(173, 216, 230, 0.6), 3px 4px 12px rgba(23, 38, 32, 0.16);
}

.prose strong {
  font-weight: 700;
}

.prose blockquote {
  margin: 0 0 16px;
  padding: 14px 18px;
  border-left: 5px solid #b4fde1;
  background: rgba(180, 253, 225, 0.35);
  border-radius: 0 16px 16px 0;
}

.prose time {
  display: inline-block;
  padding: 2px 10px;
  border: 2px solid #172620;
  border-radius: 999px;
  background: #ffffff;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 16px;
  font-size: 16px;
}

.prose th,
.prose td {
  border: 2px solid rgba(23, 38, 32, 0.55);
  padding: 8px 10px;
  text-align: left;
}

/* ---------- 右侧栏 ---------- */

.side {
  position: sticky;
  top: 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.side-card {
  padding: 16px;
  border: 3px solid #172620;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);
  box-shadow: inset -2px -2px 8px rgba(173, 216, 230, 0.6), 4px 4px 0 rgba(23, 38, 32, 0.18);
}

.side-title {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 700;
}

.side-title > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.side-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #add8e6;
  border: 2px solid #172620;
}

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

.side-list a {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 8px 12px;
  border: 2px solid #172620;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.8);
  color: #172620;
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  transition: transform 0.2s ease-out, background-color 0.2s ease-out;
}

.side-list a:hover {
  background: #b4fde1;
  transform: translateX(-2px);
}

/* ---------- 页脚 ---------- */

.foot {
  max-width: 1180px;
  margin: 34px auto 0;
  padding: 28px 0 44px;
  border-top: 4px solid #172620;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr auto;
  gap: 22px;
  align-items: start;
}

.foot p {
  margin: 0;
}

.foot-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.foot-brand {
  font-family: Orbitron, "Exo 2", system-ui, sans-serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.foot-btn {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 20px;
  border: 3px solid #172620;
  border-radius: 20px;
  background: linear-gradient(150deg, #b4fde1, #add8e6);
  color: #172620;
  text-decoration: none;
  font-weight: 700;
  font-size: 16px;
  box-shadow: inset -3px -3px 9px rgba(255, 255, 255, 0.85), 4px 4px 0 rgba(23, 38, 32, 0.8);
  transition: transform 0.2s ease-out;
}

.foot-btn:hover {
  transform: translate(-1px, -2px);
}

.foot-btn:active {
  transform: translate(1px, 2px);
}

.foot-col {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.foot-col a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: #172620;
  text-decoration: none;
  font-size: 16px;
  border-bottom: 2px solid transparent;
  width: fit-content;
}

.foot-col a:hover {
  border-bottom-color: #172620;
}

.foot-copy {
  font-size: 16px;
  align-self: end;
  white-space: nowrap;
}

/* ---------- 动效 ---------- */

.rv {
  opacity: 0;
  transform: translateY(16px);
}

.rv.in {
  opacity: 1;
  transform: none;
  transition: opacity 0.5s ease-out, transform 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
  transition-delay: calc(var(--i, 0) * 60ms);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .rv {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .brand,
  .rail-nav a,
  .hero-cta,
  .side-list a,
  .foot-btn {
    transition: none;
  }
}

/* ---------- 断点 ---------- */

@media (max-width: 960px) {
  .rail {
    position: sticky;
    top: 0;
    bottom: auto;
    left: auto;
    width: auto;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-right: 0;
    border-bottom: 4px solid #172620;
    box-shadow: inset 0 -6px 14px rgba(23, 38, 32, 0.08);
    overflow: visible;
  }

  .brand {
    padding: 8px 12px;
    font-size: 16px;
    flex: none;
  }

  .rail-nav {
    flex: 1;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

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

  .rail-nav ol {
    flex-direction: row;
    gap: 8px;
  }

  .rail-nav a {
    white-space: nowrap;
  }

  .rail-contact {
    display: none;
  }

  main {
    margin-left: 0;
    padding: 0 14px;
  }

  .wrap {
    grid-template-columns: minmax(0, 1fr);
    padding-top: 16px;
    gap: 18px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "text" "media";
    min-height: 0;
    padding: 20px;
    border-radius: 20px 20px 64px 20px;
  }

  .hero-text {
    align-items: flex-start;
    text-align: left;
  }

  .hero-media img {
    min-height: 180px;
  }

  .side {
    position: static;
  }

  .foot {
    grid-template-columns: 1fr 1fr;
    padding-bottom: 36px;
  }

  .foot-copy {
    align-self: start;
    grid-column: 1 / -1;
  }
}

@media (max-width: 560px) {
  .prose > div {
    padding: 18px 16px 14px;
  }

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

  .hero h1 {
    font-size: 27px;
  }
}

button[aria-expanded]{min-width:44px;min-height:44px}
