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

/* ============================================================
   CSS 变量 & 重置
============================================================ */
:root {
  --c-bg: #0D0D0D;
  --c-accent: #E63462;
  --c-cream: #F5F0E8;
  --c-dark: #0D0D0D;
  --c-surface: #161616;
  --c-surface2: #1e1e1e;
  --c-border: rgba(246,240,232,0.1);
  --c-text: #F5F0E8;
  --c-text-muted: rgba(245,240,232,0.55);
  --c-accent-glow: rgba(230,52,98,0.35);
  --f-head: 'Outfit', 'Rubik', system-ui, sans-serif;
  --f-body: 'Rubik', 'Outfit', system-ui, sans-serif;
  --nav-h: 68px;
  --anchor-h: 44px;
  --radius: 4px;
  --shadow-card: 0 8px 32px rgba(0,0,0,0.55), 0 2px 8px rgba(230,52,98,0.1);
  --transition: 0.3s cubic-bezier(0.4,0,0.2,1);
  scroll-behavior: smooth;
}

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

html { font-size: 16px; line-height: 1.6; }

body {
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--f-body);
  font-size: 1rem;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ol, ul { list-style: none; }
button, input { font-family: inherit; font-size: inherit; }

/* ============================================================
   滚动锚点偏移
============================================================ */
article[id] {
  scroll-margin-top: calc(var(--nav-h) + var(--anchor-h) + 12px);
}

/* ============================================================
   站点包裹
============================================================ */
.site-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ============================================================
   顶部导航
============================================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(13,13,13,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--c-border);
}

.header-inner {
  max-width: 1440px;
  margin: 0 auto;
  height: 100%;
  padding: 0 24px;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 16px;
}

.nav-left,
.nav-right {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}

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

.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 10px 12px;
  font-family: var(--f-head);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--c-text-muted);
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
  min-height: 44px;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--c-cream);
  background: rgba(245,240,232,0.06);
  outline: none;
}

.brand-center {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  min-height: 44px;
}

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

.brand-text {
  font-family: var(--f-head);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  background: linear-gradient(120deg, var(--c-cream) 30%, var(--c-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  min-height: 44px;
  background: var(--c-accent);
  color: var(--c-cream);
  font-family: var(--f-head);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  border-radius: var(--radius);
  transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
  white-space: nowrap;
}

.nav-cta:hover,
.nav-cta:focus-visible {
  background: #c4274f;
  box-shadow: 0 0 20px var(--c-accent-glow);
  transform: translateY(-1px);
  outline: none;
}

/* ============================================================
   粘性锚点条
============================================================ */
.anchor-bar {
  position: sticky;
  top: var(--nav-h);
  z-index: 90;
  height: var(--anchor-h);
  background: var(--c-surface);
  border-bottom: 1px solid var(--c-border);
}

.anchor-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
}

.anchor-list {
  display: flex;
  align-items: center;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  width: 100%;
}

.anchor-list::-webkit-scrollbar { display: none; }

.anchor-link {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  min-height: 40px;
  font-family: var(--f-head);
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--c-text-muted);
  border-right: 1px solid var(--c-border);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
}

.anchor-link:first-child { padding-left: 0; }

.anchor-link:hover,
.anchor-link:focus-visible {
  color: var(--c-accent);
  outline: none;
}

/* ============================================================
   Hero 区块
============================================================ */
.hero-block {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: calc(var(--nav-h) + var(--anchor-h));
  background: var(--c-bg);
}

/* 超大背景文字 */
.hero-bg-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--f-head);
  font-size: clamp(120px, 22vw, 320px);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(230,52,98,0.12);
  user-select: none;
  pointer-events: none;
  white-space: nowrap;
  z-index: 0;
}

/* 错位拼贴双图块 */
.hero-collage {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.hero-tile {
  position: absolute;
  width: clamp(160px, 22vw, 320px);
  aspect-ratio: 9/14;
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}

.hero-tile--a {
  top: 12%;
  left: 4%;
  background: linear-gradient(145deg, #1a0a10 0%, #2d0d1c 50%, var(--c-accent) 120%);
  transform: rotate(-4deg);
  animation: tileFloat 6s ease-in-out infinite;
}

.hero-tile--b {
  bottom: 10%;
  right: 4%;
  background: linear-gradient(145deg, #0d0d18 0%, #1a1030 50%, #6b2ca8 120%);
  transform: rotate(3.5deg);
  animation: tileFloat 7s ease-in-out infinite reverse;
}

.tile-inner {
  width: 100%;
  padding: 16px;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, transparent 100%);
}

.tile-label {
  display: block;
  font-family: var(--f-head);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--c-cream);
  opacity: 0.85;
}

.tile-number {
  font-family: var(--f-head);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--c-accent);
  line-height: 1;
  letter-spacing: -0.04em;
}

@keyframes tileFloat {
  0%, 100% { transform: rotate(-4deg) translateY(0); }
  50%       { transform: rotate(-4deg) translateY(-14px); }
}

.hero-tile--b { animation-name: tileFloatB; }
@keyframes tileFloatB {
  0%, 100% { transform: rotate(3.5deg) translateY(0); }
  50%       { transform: rotate(3.5deg) translateY(-10px); }
}

/* Hero 文案 */
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 40px 24px;
  max-width: 900px;
  width: 100%;
}

.hero-h1 {
  font-family: var(--f-head);
  font-size: clamp(2.6rem, 8vw, 7rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 1.4rem;
}

.hero-line {
  display: block;
  background: linear-gradient(90deg, var(--c-cream) 0%, var(--c-accent) 55%, #c4274f 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 打字机动效 */
.type-anim {
  overflow: hidden;
  border-right: 3px solid var(--c-accent);
  white-space: nowrap;
  width: 0;
  animation: typeIn 1.8s steps(8, end) 0.4s forwards, blinkCaret 0.75s step-end 2.2s 4;
}

@keyframes typeIn {
  from { width: 0; }
  to   { width: 100%; }
}

@keyframes blinkCaret {
  0%, 100% { border-color: var(--c-accent); }
  50%       { border-color: transparent; }
}

.hero-sub {
  font-family: var(--f-body);
  font-size: clamp(1rem, 2vw, 1.2rem);
  font-weight: 300;
  color: var(--c-text-muted);
  max-width: 560px;
  margin: 0 auto 2rem;
  letter-spacing: 0.01em;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  padding: 14px 36px;
  min-height: 52px;
  background: var(--c-accent);
  color: var(--c-cream);
  font-family: var(--f-head);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  border-radius: var(--radius);
  transition: background var(--transition), box-shadow var(--transition), transform var(--transition);
}

.hero-btn:hover,
.hero-btn:focus-visible {
  background: #c4274f;
  box-shadow: 0 0 36px var(--c-accent-glow);
  transform: translateY(-2px);
  outline: none;
}

/* reveal 动效 */
.reveal-fade {
  opacity: 0;
  transform: translateY(20px);
  animation: revealFade 0.8s ease 2s forwards;
}

@keyframes revealFade {
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   正文主容器
============================================================ */
.site-main {
  flex: 1;
  width: 100%;
  padding: 80px 24px;
}

.content-section {
  max-width: 1300px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 220px 1fr;
  grid-template-rows: auto 1fr;
  gap: 48px 56px;
  align-items: start;
}

/* aside 在左侧 */
.content-aside {
  grid-column: 1;
  grid-row: 1 / 3;
  position: sticky;
  top: calc(var(--nav-h) + var(--anchor-h) + 24px);
}

.aside-inner {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--shadow-card);
}

.aside-eyebrow {
  display: block;
  font-family: var(--f-head);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--c-accent);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.aside-title {
  font-family: var(--f-head);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--c-cream);
  margin-bottom: 16px;
  letter-spacing: 0.03em;
}

.aside-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.aside-link {
  display: block;
  padding: 8px 10px;
  min-height: 40px;
  font-size: 0.82rem;
  color: var(--c-text-muted);
  border-radius: var(--radius);
  border-left: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition), background var(--transition);
  line-height: 1.4;
  display: flex;
  align-items: center;
}

.aside-link:hover,
.aside-link:focus-visible {
  color: var(--c-cream);
  border-left-color: var(--c-accent);
  background: rgba(230,52,98,0.08);
  outline: none;
}

/* figure 装饰 */
.content-figure {
  grid-column: 1;
  grid-row: 2;
  margin: 0;
}

.figure-deco {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  max-width: 180px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.deco-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--c-accent);
  animation: spinRing 12s linear infinite;
}

.deco-ring--1 {
  width: 100%;
  height: 100%;
  opacity: 0.25;
}

.deco-ring--2 {
  width: 70%;
  height: 70%;
  opacity: 0.15;
  animation-direction: reverse;
  animation-duration: 8s;
}

@keyframes spinRing {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.deco-label {
  font-family: var(--f-head);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--c-accent);
  text-align: center;
  position: relative;
  z-index: 1;
}

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

/* ============================================================
   正文内容排版（page.content 里的 HTML）
============================================================ */
.page-content-wrap h2 {
  font-family: var(--f-head);
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--c-cream);
  margin-top: 3rem;
  margin-bottom: 1rem;
  padding-top: 2rem;
  border-top: 1px solid var(--c-border);
}

.page-content-wrap h2:first-child { margin-top: 0; padding-top: 0; border-top: none; }

.page-content-wrap h3 {
  font-family: var(--f-head);
  font-size: clamp(1.15rem, 2vw, 1.6rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--c-cream);
  margin-top: 2.2rem;
  margin-bottom: 0.8rem;
}

.page-content-wrap h4 {
  font-family: var(--f-head);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--c-accent);
  margin-top: 1.8rem;
  margin-bottom: 0.6rem;
}

.page-content-wrap p {
  color: var(--c-text-muted);
  margin-bottom: 1.2rem;
  font-size: 1rem;
  line-height: 1.8;
}

.page-content-wrap strong {
  color: var(--c-cream);
  font-weight: 600;
}

.page-content-wrap a {
  color: var(--c-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: opacity var(--transition);
}

.page-content-wrap a:hover { opacity: 0.8; }

.page-content-wrap ul,
.page-content-wrap ol {
  padding-left: 1.4rem;
  margin-bottom: 1.2rem;
  list-style: disc;
}

.page-content-wrap ol { list-style: decimal; }

.page-content-wrap li {
  color: var(--c-text-muted);
  margin-bottom: 0.5rem;
  font-size: 1rem;
  line-height: 1.7;
}

.page-content-wrap blockquote {
  border-left: 3px solid var(--c-accent);
  padding: 12px 20px;
  margin: 1.6rem 0;
  background: var(--c-surface);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.page-content-wrap blockquote p {
  margin: 0;
  font-style: italic;
  color: var(--c-cream);
}

.page-content-wrap table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.6rem;
  font-size: 0.92rem;
}

.page-content-wrap th,
.page-content-wrap td {
  padding: 10px 14px;
  border: 1px solid var(--c-border);
  text-align: left;
}

.page-content-wrap th {
  background: var(--c-surface2);
  color: var(--c-cream);
  font-family: var(--f-head);
  font-weight: 600;
}

.page-content-wrap td { color: var(--c-text-muted); }

/* article 内的标题装饰 small + h2 同级 */
.page-content-wrap small {
  display: block;
  font-family: var(--f-head);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--c-accent);
  text-transform: uppercase;
  margin-bottom: 6px;
}

/* article 区块（page.content 里） */
.page-content-wrap article {
  margin-bottom: 4rem;
  padding: 40px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

.page-content-wrap article::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--c-accent), transparent);
}

/* Scroll reveal via JS */
.js-reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.js-reveal-delay-1 { transition-delay: 0.1s; }
.js-reveal-delay-2 { transition-delay: 0.2s; }
.js-reveal-delay-3 { transition-delay: 0.3s; }

/* ============================================================
   页脚
============================================================ */
.site-footer {
  background: var(--c-surface);
  border-top: 1px solid var(--c-border);
  margin-top: auto;
}

.footer-top {
  max-width: 1300px;
  margin: 0 auto;
  padding: 72px 24px 56px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 48px 40px;
  align-items: start;
}

.footer-brand-col {}

.footer-logo-link { display: inline-block; margin-bottom: 16px; }

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

.footer-brand-name {
  display: block;
  font-family: var(--f-head);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  background: linear-gradient(90deg, var(--c-cream), var(--c-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

.footer-brand-desc {
  font-size: 0.85rem;
  color: var(--c-text-muted);
  line-height: 1.6;
}

.footer-eyebrow {
  display: block;
  font-family: var(--f-head);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--c-accent);
  text-transform: uppercase;
  margin-bottom: 10px;
}

.footer-col-title {
  font-family: var(--f-head);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--c-cream);
  margin-bottom: 18px;
}

.footer-nav-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

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

.footer-nav-link:hover,
.footer-nav-link:focus-visible {
  color: var(--c-accent);
  outline: none;
}

.footer-info-text {
  font-size: 0.82rem;
  color: var(--c-text-muted);
  line-height: 1.6;
  margin-bottom: 0.75rem;
}

.footer-contact-item {
  font-size: 0.85rem;
  color: var(--c-text-muted);
  margin-bottom: 8px;
}

.contact-label {
  color: var(--c-cream);
  font-weight: 500;
}

.footer-contact-link {
  color: var(--c-accent);
  transition: opacity var(--transition);
}

.footer-contact-link:hover { opacity: 0.8; }

.footer-form { margin-top: 20px; }

.footer-form-label {
  font-size: 0.8rem;
  color: var(--c-text-muted);
  margin-bottom: 10px;
}

.subscribe-form {
  display: flex;
  gap: 8px;
}

.subscribe-input {
  flex: 1;
  min-width: 0;
  padding: 10px 14px;
  min-height: 44px;
  background: var(--c-surface2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  color: var(--c-cream);
  font-size: 0.85rem;
  outline: none;
  transition: border-color var(--transition);
}

.subscribe-input::placeholder { color: var(--c-text-muted); }

.subscribe-input:focus { border-color: var(--c-accent); }

.subscribe-btn {
  padding: 10px 18px;
  min-height: 44px;
  background: var(--c-accent);
  color: var(--c-cream);
  border: none;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: background var(--transition), box-shadow var(--transition);
  white-space: nowrap;
}

.subscribe-btn:hover {
  background: #c4274f;
  box-shadow: 0 0 16px var(--c-accent-glow);
}

.footer-bottom {
  border-top: 1px solid var(--c-border);
  padding: 28px 24px;
  text-align: center;
}

.footer-copyright {
  font-size: 0.82rem;
  color: var(--c-text-muted);
  margin-bottom: 6px;
}

.footer-disclaimer {
  font-size: 0.76rem;
  color: rgba(245,240,232,0.35);
  margin-bottom: 4px;
}

.footer-icp {
  font-size: 0.76rem;
  color: rgba(245,240,232,0.3);
}

/* ============================================================
   响应式 — 平板
============================================================ */
@media (max-width: 1024px) {
  .content-section {
    grid-template-columns: 180px 1fr;
    gap: 32px 36px;
  }

  .footer-top {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 32px;
  }
}

/* ============================================================
   响应式 — 移动端
============================================================ */
@media (max-width: 768px) {
  :root {
    --nav-h: 60px;
    --anchor-h: 40px;
  }

  /* 导航：隐藏中间项，只留 brand + cta */
  .nav-left { display: none; }
  .nav-right .nav-link { display: none; }
  .nav-right { gap: 0; justify-content: flex-end; }

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

  .anchor-link {
    padding: 8px 10px;
    font-size: 0.7rem;
  }

  /* Hero */
  .hero-tile {
    width: clamp(100px, 28vw, 180px);
  }

  .hero-tile--a { left: -2%; top: 8%; }
  .hero-tile--b { right: -2%; bottom: 6%; }

  .hero-content { padding: 32px 16px; }

  /* 正文 */
  .content-section {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .content-aside {
    grid-column: 1;
    grid-row: auto;
    position: static;
  }

  .content-figure {
    display: none;
  }

  .page-content-wrap {
    grid-column: 1;
    grid-row: auto;
  }

  .page-content-wrap article {
    padding: 24px 20px;
  }

  /* 页脚 */
  .footer-top {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 48px 20px 36px;
  }

  .subscribe-form {
    flex-direction: column;
  }

  .subscribe-btn { width: 100%; }

  /* 打字机：移动端允许换行 */
  .type-anim {
    white-space: normal;
    width: auto;
    border-right: none;
    animation: revealFade 0.8s ease 0.3s both;
  }
}

@media (max-width: 480px) {
  .hero-block { padding-top: calc(var(--nav-h) + var(--anchor-h) + 8px); }
  .site-main { padding: 48px 16px; }
  .hero-bg-text { font-size: 28vw; }
}

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

  .type-anim {
    width: 100%;
    border-right: none;
  }

  .reveal-fade { opacity: 1; transform: none; }
  .js-reveal  { opacity: 1; transform: none; }
}
