@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400&family=Nunito:ital,wght@0,700;0,800;0,900;1,700&display=swap');

/* ============================
   CSS 变量 / 设计 Token
============================ */
:root {
  --c-lime: #80ff00;
  --c-green: #00ff00;
  --c-dark: #1f2617;
  --c-dark2: #141a0e;
  --c-dark3: #2a3520;
  --c-lime-dim: rgba(128,255,0,0.12);
  --c-lime-glow: rgba(128,255,0,0.35);
  --c-text: #e8f5d0;
  --c-text-muted: #a8c070;
  --c-white: #f5ffea;
  --font-round: 'Nunito', 'DM Sans', system-ui, sans-serif;
  --font-body: 'DM Sans', 'Nunito', system-ui, sans-serif;
  --radius-card: 18px;
  --radius-btn: 50px;
  --shadow-clay: 0 8px 32px rgba(0,0,0,0.45), 0 2px 8px rgba(128,255,0,0.18), inset 0 1px 0 rgba(255,255,255,0.08);
  --shadow-card: 6px 8px 0 rgba(128,255,0,0.55);
  --ticker-h: 36px;
  --header-h: 68px;
  --subnav-h: 48px;
  --scroll-offset: calc(var(--ticker-h) + var(--header-h) + var(--subnav-h));
}

/* ============================
   Reset / Base
============================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background: var(--c-dark2);
  color: var(--c-text);
}

body.hg-body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  background: var(--c-dark2);
  color: var(--c-text);
  overflow-x: hidden;
  min-height: 100vh;
}

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

a {
  color: var(--c-lime);
  text-decoration: none;
  transition: color 0.2s, opacity 0.2s;
}

a:hover, a:focus-visible {
  color: var(--c-green);
  text-decoration: underline;
  text-underline-offset: 3px;
}

ol, ul {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-round);
  font-weight: 900;
  line-height: 1.2;
  color: var(--c-white);
}

hr {
  border: none;
  border-top: 2px solid var(--c-lime);
  margin: 0.75rem 0 1rem;
  opacity: 0.6;
}

section {
  scroll-margin-top: var(--scroll-offset);
}

/* ============================
   Site Wrapper
============================ */
.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  position: relative;
}

/* ============================
   滚动公告条
============================ */
.top-ticker {
  background: var(--c-lime);
  color: var(--c-dark);
  height: var(--ticker-h);
  overflow: hidden;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 200;
  font-family: var(--font-round);
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.ticker-inner {
  display: flex;
  white-space: nowrap;
  animation: marquee-scroll 38s linear infinite;
}

.ticker-text {
  padding-right: 4rem;
}

@keyframes marquee-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ============================
   Header / 主导航
============================ */
.site-header {
  position: sticky;
  top: var(--ticker-h);
  z-index: 190;
  background: var(--c-dark);
  border-bottom: 2px solid var(--c-lime);
  height: var(--header-h);
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  gap: 1rem;
}

.nav-left, .nav-right {
  flex: 1;
}

.nav-right {
  display: flex;
  justify-content: flex-end;
}

.nav-left ol, .nav-right ol {
  display: flex;
  gap: 0.25rem;
  align-items: center;
}

.nav-left ol li a,
.nav-right ol li a {
  display: flex;
  align-items: center;
  height: 44px;
  padding: 0 0.75rem;
  font-family: var(--font-round);
  font-weight: 800;
  font-size: 0.82rem;
  color: var(--c-text);
  border-radius: 8px;
  transition: background 0.18s, color 0.18s, transform 0.15s;
  white-space: nowrap;
  letter-spacing: 0.02em;
}

.nav-left ol li a:hover,
.nav-right ol li a:hover,
.nav-left ol li a:focus-visible,
.nav-right ol li a:focus-visible {
  background: var(--c-lime-dim);
  color: var(--c-lime);
  text-decoration: none;
  transform: translateY(-1px);
}

/* 品牌中心 */
.brand-center {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.brand-logo {
  height: 44px;
  width: auto;
}

.brand-text {
  font-family: var(--font-round);
  font-weight: 900;
  font-size: 1.15rem;
  color: var(--c-lime);
  letter-spacing: -0.01em;
  text-shadow: 0 0 16px var(--c-lime-glow);
  white-space: nowrap;
}

.brand-link:hover {
  text-decoration: none;
}

.brand-link:hover .brand-text {
  color: var(--c-green);
  text-shadow: 0 0 24px rgba(0,255,0,0.5);
}

/* ============================
   粘性锚点二级导航
============================ */
.sticky-subnav {
  position: sticky;
  top: calc(var(--ticker-h) + var(--header-h));
  z-index: 180;
  background: var(--c-dark3);
  border-bottom: 1.5px solid rgba(128,255,0,0.25);
  height: var(--subnav-h);
  overflow: hidden;
}

.sticky-subnav ol {
  display: flex;
  align-items: center;
  height: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  gap: 0.15rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.sticky-subnav ol::-webkit-scrollbar {
  display: none;
}

.sticky-subnav ol li a {
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 0.9rem;
  font-family: var(--font-round);
  font-weight: 800;
  font-size: 0.78rem;
  color: var(--c-text-muted);
  border-radius: 20px;
  border: 1.5px solid transparent;
  white-space: nowrap;
  transition: all 0.18s;
  letter-spacing: 0.03em;
}

.sticky-subnav ol li a:hover,
.sticky-subnav ol li a:focus-visible {
  color: var(--c-lime);
  border-color: var(--c-lime);
  background: var(--c-lime-dim);
  text-decoration: none;
  transform: scale(1.04);
}

/* ============================
   Hero 区块
============================ */
.hero-section {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 560px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: saturate(140%) brightness(0.7);
}

.hero-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    120deg,
    rgba(31,38,23,0.92) 0%,
    rgba(31,38,23,0.55) 45%,
    rgba(31,38,23,0.2) 100%
  );
}

/* 超大背景装饰文字 */
.hero-deco-text {
  position: absolute;
  bottom: -0.1em;
  left: -0.05em;
  font-family: var(--font-round);
  font-weight: 900;
  font-size: clamp(8rem, 22vw, 20rem);
  color: transparent;
  -webkit-text-stroke: 2px rgba(128,255,0,0.15);
  text-stroke: 2px rgba(128,255,0,0.15);
  line-height: 1;
  z-index: 1;
  pointer-events: none;
  user-select: none;
  mix-blend-mode: screen;
  letter-spacing: -0.05em;
}

/* 文案内容：右对齐 */
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 560px;
  padding: 2.5rem;
  text-align: right;
  margin-right: clamp(1.5rem, 6vw, 8rem);
}

.hero-eyebrow {
  display: inline-block;
  background: var(--c-lime);
  color: var(--c-dark);
  font-family: var(--font-round);
  font-weight: 900;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.25rem 0.85rem;
  border-radius: 20px;
  margin-bottom: 1rem;
  transform: rotate(1.5deg);
  display: inline-block;
}

.hero-h1 {
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  font-weight: 900;
  color: var(--c-white);
  margin-bottom: 1rem;
  text-shadow: 0 4px 32px rgba(0,0,0,0.7), 0 0 40px rgba(128,255,0,0.2);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.hero-desc {
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  color: var(--c-text);
  margin-bottom: 2rem;
  line-height: 1.7;
  opacity: 0.92;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  height: 52px;
  padding: 0 2rem;
  background: var(--c-lime);
  color: var(--c-dark);
  font-family: var(--font-round);
  font-weight: 900;
  font-size: 1rem;
  border-radius: var(--radius-btn);
  box-shadow: var(--shadow-clay);
  transition: transform 0.18s, box-shadow 0.18s, background 0.18s;
  letter-spacing: 0.04em;
}

.hero-cta:hover, .hero-cta:focus-visible {
  background: var(--c-green);
  color: var(--c-dark);
  text-decoration: none;
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 12px 40px rgba(0,255,0,0.35), 0 2px 8px rgba(0,0,0,0.4);
}

/* 贴纸装饰 */
.hero-stickers {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}

.sticker {
  position: absolute;
  font-size: 2.5rem;
  animation: jitter 3s ease-in-out infinite;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.5));
}

.sticker-1 {
  top: 18%;
  left: 8%;
  animation-delay: 0s;
  transform: rotate(-12deg);
  font-size: 3.5rem;
}

.sticker-2 {
  top: 30%;
  left: 38%;
  animation-delay: 0.8s;
  transform: rotate(8deg);
}

.sticker-3 {
  bottom: 22%;
  right: 12%;
  animation-delay: 1.4s;
  transform: rotate(-5deg);
  font-size: 2rem;
}

.sticker-4 {
  top: 12%;
  right: 25%;
  animation-delay: 2s;
  transform: rotate(15deg);
  font-size: 2rem;
}

@keyframes jitter {
  0%, 100% { transform: rotate(var(--r, -8deg)) translateY(0); }
  25% { transform: rotate(calc(var(--r, -8deg) + 4deg)) translateY(-4px); }
  50% { transform: rotate(var(--r, -8deg)) translateY(2px); }
  75% { transform: rotate(calc(var(--r, -8deg) - 3deg)) translateY(-2px); }
}

/* ============================
   主内容区
============================ */
.site-main {
  flex: 1;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
}

/* section 直接子元素包含 figure 和 aside */
.content-section {
  display: grid;
  grid-template-columns: 1fr 280px;
  grid-template-rows: auto 1fr;
  gap: 2rem;
  align-items: start;
}

/* figure 装饰区 */
.content-figure {
  grid-column: 1 / 2;
  grid-row: 1 / 2;
  display: flex;
  gap: 0.75rem;
  align-items: center;
  padding: 1.25rem 0 0.5rem;
  margin: 0;
  overflow: visible;
}

.fig-decoration {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
}

.fig-block {
  border-radius: 8px;
  animation: jitter 4s ease-in-out infinite;
}

.fig-block-1 {
  width: 48px;
  height: 48px;
  background: var(--c-lime);
  --r: -6deg;
  animation-delay: 0s;
}

.fig-block-2 {
  width: 32px;
  height: 32px;
  background: var(--c-green);
  --r: 10deg;
  animation-delay: 0.6s;
}

.fig-block-3 {
  width: 22px;
  height: 22px;
  background: rgba(128,255,0,0.4);
  border: 2px solid var(--c-lime);
  --r: -14deg;
  animation-delay: 1.2s;
}

/* aside 侧边栏 */
.content-aside {
  grid-column: 2 / 3;
  grid-row: 1 / 3;
  position: sticky;
  top: var(--scroll-offset);
  align-self: start;
}

.aside-inner {
  background: var(--c-dark3);
  border: 2px solid var(--c-lime);
  border-radius: var(--radius-card);
  padding: 1.5rem 1.25rem;
  box-shadow: var(--shadow-card);
}

.aside-title {
  font-size: 0.95rem;
  font-weight: 900;
  color: var(--c-lime);
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

.aside-nav-list {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 1.25rem;
}

.aside-nav-list li {
  counter-increment: aside-count;
}

.aside-nav-list li a {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.6rem;
  font-size: 0.83rem;
  font-weight: 700;
  color: var(--c-text);
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
  min-height: 40px;
}

.aside-nav-list li a::before {
  content: counter(aside-count, decimal-leading-zero);
  font-family: var(--font-round);
  font-size: 0.7rem;
  color: var(--c-lime);
  font-weight: 900;
  flex-shrink: 0;
  width: 24px;
}

.aside-nav-list li a:hover,
.aside-nav-list li a:focus-visible {
  background: var(--c-lime-dim);
  color: var(--c-lime);
  text-decoration: none;
}

.aside-badge {
  display: inline-block;
  background: var(--c-lime);
  color: var(--c-dark);
  font-family: var(--font-round);
  font-weight: 900;
  font-size: 0.72rem;
  padding: 0.3rem 0.7rem;
  border-radius: 20px;
  margin-top: 0.5rem;
  transform: rotate(-2deg);
  display: block;
  text-align: center;
}

.aside-badge-2 {
  background: var(--c-dark);
  color: var(--c-lime);
  border: 1.5px solid var(--c-lime);
  transform: rotate(1.5deg);
  margin-top: 0.4rem;
}

/* 正文内容体 */
.content-body {
  grid-column: 1 / 2;
  grid-row: 2 / 3;
  min-width: 0;
}

/* page.content 内部样式 */
.content-body h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 900;
  color: var(--c-lime);
  margin-top: 3rem;
  margin-bottom: 0.4rem;
  letter-spacing: -0.01em;
  position: relative;
}

.content-body h2:first-child {
  margin-top: 0;
}

.content-body h2 + hr,
.content-body h3 + hr {
  margin-bottom: 1.25rem;
}

.content-body h3 {
  font-size: clamp(1.1rem, 2.2vw, 1.45rem);
  font-weight: 800;
  color: var(--c-text);
  margin-top: 2rem;
  margin-bottom: 0.4rem;
}

.content-body p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--c-text);
  margin-bottom: 1.1rem;
}

.content-body ul,
.content-body ol {
  padding-left: 1.5rem;
  margin-bottom: 1.1rem;
}

.content-body ul {
  list-style: none;
  padding-left: 0;
}

.content-body ul li {
  padding: 0.35rem 0 0.35rem 1.5rem;
  position: relative;
  color: var(--c-text);
  line-height: 1.7;
}

.content-body ul li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--c-lime);
  font-weight: 900;
}

.content-body ol {
  list-style: decimal;
}

.content-body ol li {
  color: var(--c-text);
  padding: 0.25rem 0;
  line-height: 1.7;
}

.content-body a {
  color: var(--c-lime);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 700;
}

.content-body a:hover {
  color: var(--c-green);
}

.content-body strong, .content-body b {
  color: var(--c-lime);
  font-weight: 800;
}

.content-body em {
  color: var(--c-text-muted);
  font-style: italic;
}

.content-body blockquote {
  border-left: 4px solid var(--c-lime);
  background: var(--c-lime-dim);
  border-radius: 0 12px 12px 0;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--c-text);
}

.content-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.92rem;
}

.content-body th {
  background: var(--c-lime);
  color: var(--c-dark);
  font-weight: 800;
  padding: 0.6rem 0.85rem;
  text-align: left;
}

.content-body td {
  border-bottom: 1px solid rgba(128,255,0,0.15);
  padding: 0.6rem 0.85rem;
  color: var(--c-text);
}

.content-body tr:hover td {
  background: var(--c-lime-dim);
}

.content-body section {
  margin-bottom: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(128,255,0,0.12);
  scroll-margin-top: var(--scroll-offset);
}

.content-body section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

/* 卡片风格 - claymorphism */
.content-body .card,
.content-body [class*="card"] {
  background: var(--c-dark3);
  border-radius: var(--radius-card);
  border: 2px solid rgba(128,255,0,0.2);
  padding: 1.5rem;
  box-shadow: var(--shadow-clay);
  margin-bottom: 1.25rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.content-body .card:hover,
.content-body [class*="card"]:hover {
  transform: translateY(-4px);
  box-shadow: 8px 12px 0 rgba(128,255,0,0.6), 0 8px 32px rgba(0,0,0,0.4);
}

/* ============================
   页脚
============================ */
.site-footer {
  background: var(--c-dark2);
  border-top: 2px solid var(--c-lime);
  padding: 1rem 0;
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  min-height: 56px;
}

.footer-logo-wrap {
  flex-shrink: 0;
}

.footer-logo {
  height: 32px;
  width: auto;
}

.footer-brand-text {
  font-family: var(--font-round);
  font-weight: 900;
  font-size: 1rem;
  color: var(--c-lime);
}

.footer-nav {
  flex: 1;
}

.footer-nav ol {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-nav ol li a {
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 0.7rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--c-text-muted);
  border-radius: 8px;
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
}

.footer-nav ol li a:hover {
  color: var(--c-lime);
  background: var(--c-lime-dim);
  text-decoration: none;
}

.footer-copy {
  font-size: 0.75rem;
  color: var(--c-text-muted);
  white-space: nowrap;
  opacity: 0.7;
}

/* ============================
   Hover Micro-interactions
============================ */
.nav-left ol li a:active,
.nav-right ol li a:active {
  transform: scale(0.96);
}

.hero-cta:active {
  transform: scale(0.97);
}

/* ============================
   响应式
============================ */
@media (max-width: 1024px) {
  .content-section {
    grid-template-columns: 1fr 240px;
  }
}

@media (max-width: 768px) {
  :root {
    --header-h: 58px;
  }

  .header-inner {
    padding: 0 1rem;
    gap: 0.5rem;
  }

  .nav-left ol li a,
  .nav-right ol li a {
    font-size: 0.73rem;
    padding: 0 0.45rem;
  }

  .brand-text {
    font-size: 0.95rem;
  }

  .hero-content {
    margin-right: 1.25rem;
    max-width: 90%;
    padding: 1.5rem;
  }

  .hero-deco-text {
    font-size: 30vw;
  }

  .content-section {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
  }

  .content-figure {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
  }

  .content-aside {
    grid-column: 1 / 2;
    grid-row: 3 / 4;
    position: static;
  }

  .content-body {
    grid-column: 1 / 2;
    grid-row: 2 / 3;
  }

  .site-main {
    padding: 2rem 1rem 3rem;
  }

  .sticky-subnav ol {
    padding: 0 1rem;
    gap: 0;
  }

  .sticky-subnav ol li a {
    padding: 0 0.6rem;
    font-size: 0.72rem;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
  }

  .footer-nav ol {
    justify-content: flex-start;
  }
}

@media (max-width: 480px) {
  .nav-left, .nav-right {
    display: none;
  }

  .header-inner {
    justify-content: center;
  }

  .brand-center {
    flex: 1;
    justify-content: center;
  }

  .hero-content {
    text-align: left;
    margin: auto;
    padding: 1.25rem;
    max-width: 100%;
  }

  .hero-h1 {
    font-size: clamp(1.8rem, 9vw, 2.5rem);
  }

  .sticker-1 { font-size: 2rem; }
  .sticker-2 { display: none; }
}

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

  .ticker-inner {
    animation: none;
  }

  .sticker,
  .fig-block {
    animation: none;
  }

  .hero-cta,
  .nav-left ol li a,
  .nav-right ol li a,
  .sticky-subnav ol li a,
  .content-body .card {
    transition: none;
  }
}
