@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Work+Sans:wght@300;400;500;600;700&display=swap');

/* ── 变量 ── */
:root {
  --c-bg: #1A1A1A;
  --c-accent: #FF5C00;
  --c-light: #F5F5F5;
  --c-mid: #2E2E2E;
  --c-muted: #888888;
  --c-border: #333333;
  --nav-w: 220px;
  --font-main: 'Outfit', 'Work Sans', system-ui, sans-serif;
  --radius: 4px;
  --transition: 0.3s ease;
}

/* ── 重置 ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: var(--font-main);
  line-height: 1.6;
  overflow-x: hidden;
  background: var(--c-bg);
}

section { scroll-margin-top: 72px; }

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ── 布局外壳 ── */
.site-shell {
  display: flex;
  min-height: 100vh;
}

/* ── 侧边导航 ── */
.side-nav {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--nav-w);
  background: #111111;
  border-right: 1px solid var(--c-border);
  display: flex;
  flex-direction: column;
  padding: 2rem 1.25rem;
  z-index: 100;
  overflow-y: auto;
}

.side-nav__brand {
  margin-bottom: 2.5rem;
}

.brand-link {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--c-accent);
  display: block;
  line-height: 1.2;
  transition: opacity var(--transition);
}

.brand-link:hover { opacity: 0.8; }

.side-nav__menu {
  flex: 1;
}

.side-nav__menu dl {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.nav-group-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--c-muted);
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.side-nav__menu dd {
  margin: 0;
}

.side-nav__menu dd a {
  display: block;
  padding: 0.6rem 0.5rem;
  font-size: 0.92rem;
  font-weight: 400;
  color: var(--c-light);
  border-left: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition), padding-left var(--transition);
  min-height: 40px;
  display: flex;
  align-items: center;
}

.side-nav__menu dd a:hover {
  color: var(--c-accent);
  border-left-color: var(--c-accent);
  padding-left: 0.875rem;
}

.side-nav__cta {
  margin-top: 2rem;
}

.cta-btn {
  display: block;
  background: var(--c-accent);
  color: #fff;
  text-align: center;
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius);
  letter-spacing: 0.04em;
  transition: background var(--transition), transform var(--transition);
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cta-btn:hover {
  background: #e54e00;
  transform: translateY(-1px);
}

/* ── 页面主体 ── */
.page-body {
  margin-left: var(--nav-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* ── Hero ── */
.hero {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 4rem 3rem 3rem;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--c-border);
}

.hero__inner {
  text-align: right;
  max-width: 900px;
  margin-left: auto;
}

.hero__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--c-accent);
  margin-bottom: 1.25rem;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.hero__eyebrow.revealed {
  opacity: 1;
  transform: translateY(0);
}

.hero__title {
  font-size: clamp(3rem, 10vw, 8rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--c-light) 40%, var(--c-accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1.5rem;
  overflow: hidden;
}

.hero__title .char {
  display: inline-block;
  opacity: 0;
  transform: translateY(60px) rotate(6deg);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.hero__title .char.drop-in {
  opacity: 1;
  transform: translateY(0) rotate(0deg);
}

.hero__sub {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  font-weight: 300;
  color: var(--c-muted);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.7s ease 0.3s, transform 0.7s ease 0.3s;
}

.hero__sub.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ── 跑马灯 ── */
.hero__ticker {
  margin-top: 2.5rem;
  overflow: hidden;
  border-top: 1px solid var(--c-border);
  padding-top: 1rem;
}

.ticker__track {
  display: flex;
  gap: 3rem;
  width: max-content;
  animation: ticker-scroll 18s linear infinite;
}

.ticker__track span {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--c-border);
  white-space: nowrap;
  text-transform: uppercase;
}

@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ── 主容器 ── */
main {
  flex: 1;
}

.wrap {
  max-width: 860px;
  margin: 0 auto;
  padding: 3rem 2rem 4rem;
}

.wrap > section > div.content-body {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--c-light);
}

/* ── 正文内部通用样式 ── */
.content-body h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--c-light);
  margin: 3rem 0 1rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.content-body h3 {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 600;
  color: var(--c-accent);
  margin: 2rem 0 0.75rem;
  line-height: 1.3;
}

.content-body p {
  margin-bottom: 1.25rem;
  color: #cccccc;
}

.content-body ul,
.content-body ol {
  margin: 1rem 0 1.5rem 1.5rem;
  color: #cccccc;
}

.content-body li {
  margin-bottom: 0.5rem;
  line-height: 1.7;
}

.content-body a {
  color: var(--c-accent);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition);
}

.content-body a:hover {
  border-bottom-color: var(--c-accent);
}

.content-body strong { color: var(--c-light); font-weight: 600; }

.content-body blockquote {
  border-left: 3px solid var(--c-accent);
  padding: 0.75rem 1.25rem;
  margin: 1.5rem 0;
  background: var(--c-mid);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: #bbbbbb;
  font-style: normal;
}

.content-body section {
  border-top: 1px solid var(--c-border);
  padding-top: 2.5rem;
  margin-top: 2.5rem;
}

.content-body section:first-child {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

/* small 眉题（结构约束） */
small + h2,
small + h3 {
  margin-top: 0.3rem;
}

.content-body small {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  color: var(--c-accent);
  margin-bottom: 0.4rem;
}

/* 卡片（若正文含有） */
.content-body .card {
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin: 1.5rem 0;
  background: var(--c-mid);
  transition: border-color var(--transition);
}

.content-body .card:hover {
  border-color: var(--c-accent);
}

/* ── 滚动揭示动效 ── */
.js-reveal-block {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

.js-reveal-block.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── 视差层 ── */
.parallax-el {
  will-change: transform;
}

/* ── 页脚 ── */
.site-footer {
  border-top: 1px solid var(--c-border);
  padding: 3rem 3rem 2rem;
  background: #111111;
}

/* footer nav 结构约束：footer > nav > dl > dt/dd > a */
.footer-nav {
  margin-bottom: 2rem;
}

.footer-nav dl {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  align-items: baseline;
}

.footer-nav__label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--c-muted);
  width: 100%;
  margin-bottom: 0.5rem;
}

.footer-nav dd {
  margin: 0;
}

.footer-nav dd a {
  font-size: 0.85rem;
  color: var(--c-muted);
  padding: 0.5rem 0;
  display: inline-block;
  min-height: 40px;
  display: flex;
  align-items: center;
  transition: color var(--transition);
}

.footer-nav dd a:hover {
  color: var(--c-accent);
}

.footer-copy {
  font-size: 0.82rem;
  color: var(--c-muted);
  text-align: center;
  margin-bottom: 0.5rem;
}

.site-footer > small.footer-note {
  display: block;
  font-size: 0.75rem;
  color: #555555;
  text-align: center;
  line-height: 1.5;
}

/* ── 响应式 ── */
@media (max-width: 900px) {
  :root { --nav-w: 0px; }

  .side-nav {
    transform: translateX(-100%);
    transition: transform var(--transition);
    width: 240px;
  }

  .side-nav.open {
    transform: translateX(0);
  }

  .page-body {
    margin-left: 0;
  }

  .hero {
    padding: 5rem 1.5rem 2.5rem;
    min-height: 70vh;
  }

  .hero__inner {
    text-align: right;
  }

  .wrap {
    padding: 2rem 1.25rem 3rem;
  }

  .site-footer {
    padding: 2rem 1.25rem 1.5rem;
  }

  /* 移动端 hamburger */
  .nav-toggle {
    display: flex;
  }
}

@media (min-width: 901px) {
  .nav-toggle { display: none !important; }
  .nav-overlay { display: none !important; }
}

/* hamburger */
.nav-toggle {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 200;
  background: var(--c-accent);
  border: none;
  border-radius: var(--radius);
  width: 44px;
  height: 44px;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  display: none;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
}

.nav-overlay.show {
  opacity: 1;
  pointer-events: all;
}

@media (max-width: 600px) {
  .hero__title {
    font-size: clamp(2.5rem, 14vw, 4rem);
  }

  .content-body h2 {
    font-size: 1.3rem;
  }

  .footer-nav dl {
    flex-direction: column;
    gap: 0;
  }
}

/* ── prefers-reduced-motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .hero__eyebrow,
  .hero__sub,
  .hero__title .char,
  .js-reveal-block {
    opacity: 1 !important;
    transform: none !important;
  }
}
