@import url('https://fonts.googleapis.com/css2?family=Atkinson+Hyperlegible:wght@400;700&family=Crimson+Pro:wght@400;500;600;700&display=swap');

/* ===== 基础变量 ===== */
:root {
  --red: #ff0000;
  --purple: #8b00ff;
  --dark: #261717;
  --dark2: #1a0f0f;
  --dark3: #0f0808;
  --glass-bg: rgba(255,255,255,0.08);
  --glass-bg-hover: rgba(255,255,255,0.14);
  --glass-border: rgba(255,255,255,0.18);
  --glass-border-strong: rgba(255,255,255,0.28);
  --blur: blur(15px);
  --blur-sm: blur(8px);
  --text-primary: #f5e6e6;
  --text-secondary: rgba(245,230,230,0.7);
  --text-dim: rgba(245,230,230,0.45);
  --font-body: 'Atkinson Hyperlegible', system-ui, sans-serif;
  --font-display: 'Crimson Pro', Georgia, serif;
  --nav-h: 100px;
  --radius: 0px;
  --scroll-margin: 110px;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  scroll-behavior: smooth;
  font-size: 17px;
  line-height: 1.65;
  -webkit-text-size-adjust: 100%;
}
body {
  font-family: var(--font-body);
  background-color: var(--dark3);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, menu { list-style: none; }
address { font-style: normal; }
summary { list-style: none; cursor: pointer; }
summary::-webkit-details-marker { display: none; }

/* ===== 背景装饰层 ===== */
.page-wrapper {
  position: relative;
  min-height: 100vh;
  isolation: isolate;
}
.bg-layer {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: radial-gradient(ellipse at 20% 10%, #3a0000 0%, var(--dark3) 50%),
              radial-gradient(ellipse at 80% 80%, #1a0030 0%, transparent 60%);
  overflow: hidden;
}
.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
  animation: orb-drift 18s ease-in-out infinite alternate;
}
.orb-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, #ff0000 0%, transparent 70%);
  top: -200px; left: -150px;
  animation-delay: 0s;
}
.orb-2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, #8b00ff 0%, transparent 70%);
  bottom: -100px; right: -100px;
  animation-delay: -6s;
}
.orb-3 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, #cc0044 0%, transparent 70%);
  top: 40%; left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: -12s;
}
@keyframes orb-drift {
  0%   { transform: translate(0, 0) scale(1); }
  33%  { transform: translate(40px, -30px) scale(1.08); }
  66%  { transform: translate(-20px, 50px) scale(0.95); }
  100% { transform: translate(20px, -20px) scale(1.05); }
}
.orb-3 { animation-name: orb-drift-3; }
@keyframes orb-drift-3 {
  0%   { transform: translate(-50%, -50%) scale(1); }
  50%  { transform: translate(calc(-50% + 60px), calc(-50% - 40px)) scale(1.1); }
  100% { transform: translate(calc(-50% - 40px), calc(-50% + 30px)) scale(0.9); }
}

/* ===== 顶部导航：两行 ===== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(38,23,23,0.6);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: 0 4px 32px rgba(0,0,0,0.4);
}

/* 第一行：品牌 */
.header-brand {
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.header-brand .inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.site-logo { height: 36px; width: auto; }
.brand-text {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--red);
  letter-spacing: 0.02em;
  text-shadow: 0 0 20px rgba(255,0,0,0.5);
}
.brand-tagline {
  font-size: 0.82rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 第二行：菜单 */
.header-nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 8px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

/* details + summary 结构：桌面下 details 始终展开，summary 隐藏 */
.nav-details {
  flex: 1;
  min-width: 0;
}
.nav-summary {
  display: none;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  padding: 10px 16px;
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
  -webkit-backdrop-filter: var(--blur-sm);
  backdrop-filter: var(--blur-sm);
  min-height: 44px;
  user-select: none;
}
.nav-summary::after {
  content: '▾';
  margin-left: auto;
  transition: transform 0.25s;
}
.nav-details[open] .nav-summary::after {
  transform: rotate(180deg);
}

/* 药丸胶囊按钮组 */
.nav-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.nav-menu li a {
  display: inline-flex;
  align-items: center;
  padding: 8px 18px;
  border-radius: 9999px;
  font-size: 0.88rem;
  font-weight: 400;
  color: var(--text-secondary);
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  -webkit-backdrop-filter: var(--blur-sm);
  backdrop-filter: var(--blur-sm);
  transition: background 0.2s, color 0.2s, border-color 0.2s, box-shadow 0.2s;
  white-space: nowrap;
  min-height: 40px;
}
.nav-menu li a:hover,
.nav-menu li a:focus-visible {
  background: rgba(255,0,0,0.18);
  color: #fff;
  border-color: rgba(255,0,0,0.5);
  box-shadow: 0 0 12px rgba(255,0,0,0.25);
  outline: none;
}

/* 右侧主 CTA 按钮 */
.cta-btn {
  display: inline-flex;
  align-items: center;
  padding: 10px 24px;
  border-radius: 9999px;
  font-size: 0.92rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--red) 0%, var(--purple) 100%);
  border: 1px solid rgba(255,255,255,0.25);
  box-shadow: 0 4px 20px rgba(255,0,0,0.35);
  transition: transform 0.2s, box-shadow 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
  min-height: 44px;
}
.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(255,0,0,0.5);
}

/* ===== Hero 区：100vh 纯文字 ===== */
.site-main {
  padding-top: var(--nav-h);
}
.hero-section {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px 24px 60px;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  scroll-margin-top: var(--scroll-margin);
}

/* 浮动徽章 - hero aside */
.hero-aside {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 36px;
}
.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  border: 1px solid var(--glass-border-strong);
  background: var(--glass-bg);
  -webkit-backdrop-filter: var(--blur-sm);
  backdrop-filter: var(--blur-sm);
  color: var(--text-primary);
  border-radius: 9999px;
  text-transform: uppercase;
  animation: badge-float 3s ease-in-out infinite alternate;
}
.badge-live {
  border-color: rgba(255,0,0,0.5);
  color: #ff6666;
  animation-delay: 0s;
}
.badge-free {
  border-color: rgba(139,0,255,0.5);
  color: #cc88ff;
  animation-delay: -1s;
}
.badge-hd {
  border-color: rgba(255,80,0,0.5);
  color: #ffaa66;
  animation-delay: -2s;
}
@keyframes badge-float {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-6px); }
}

/* hero figure：文案左对齐 */
.hero-figure {
  text-align: left;
  max-width: 820px;
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 5.5rem);
  font-weight: 700;
  line-height: 1.15;
  color: #fff;
  text-shadow: 0 0 40px rgba(255,0,0,0.4), 0 2px 0 rgba(0,0,0,0.5);
  margin-bottom: 24px;
  letter-spacing: -0.01em;
}
.hero-sub {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
}

/* ===== 正文内容区 ===== */
.content-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 24px 80px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 40px;
  align-items: start;
}

/* aside 侧边栏：右侧（grid 列序：aside 在右，实际排列 content-main 先） */
.content-aside {
  order: 2;
  position: sticky;
  top: calc(var(--nav-h) + 20px);
  background: var(--glass-bg);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  border: 1px solid var(--glass-border);
  padding: 24px 20px;
  border-radius: var(--radius);
}
.content-main { order: 1; }

.eyebrow {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--red);
  margin-bottom: 8px;
  text-transform: uppercase;
}
.aside-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--glass-border);
}
.aside-nav li { margin-bottom: 4px; }
.aside-nav li a {
  display: block;
  padding: 8px 12px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  border: 1px solid transparent;
  border-radius: 4px;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  min-height: 40px;
  display: flex;
  align-items: center;
}
.aside-nav li a:hover {
  background: rgba(255,0,0,0.12);
  color: #fff;
  border-color: rgba(255,0,0,0.3);
}

.content-heading {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 32px;
}

/* ===== page.content 内部样式 ===== */
.page-content {
  line-height: 1.75;
}
.page-content article {
  scroll-margin-top: var(--scroll-margin);
  margin-bottom: 64px;
  padding: 40px;
  background: var(--glass-bg);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  border: 1px solid var(--glass-border);
  border-top: 2px solid rgba(255,0,0,0.4);
  position: relative;
  overflow: hidden;
}
.page-content article::before {
  content: '';
  position: absolute;
  top: -60px; left: -60px;
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(139,0,255,0.12) 0%, transparent 70%);
  pointer-events: none;
}
.page-content h2 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 16px;
  margin-top: 8px;
}
.page-content h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 24px 0 12px;
}
.page-content p {
  margin-bottom: 16px;
  color: var(--text-secondary);
  font-size: 1rem;
}
.page-content ul, .page-content ol {
  margin: 16px 0 20px 20px;
  color: var(--text-secondary);
}
.page-content li {
  margin-bottom: 8px;
  line-height: 1.65;
}
.page-content a {
  color: #ff8888;
  border-bottom: 1px solid rgba(255,136,136,0.3);
  transition: color 0.2s, border-color 0.2s;
}
.page-content a:hover {
  color: #fff;
  border-color: rgba(255,255,255,0.5);
}
.page-content strong { color: var(--text-primary); font-weight: 700; }
.page-content em { color: #cc88ff; font-style: normal; }

/* ===== small 眉题（契约：h2 前有 small） ===== */
small.eyebrow + h2,
small.eyebrow + h3 {
  margin-top: 0;
}

/* ===== 页脚 ===== */
.site-footer {
  background: rgba(15,8,8,0.8);
  -webkit-backdrop-filter: var(--blur-sm);
  backdrop-filter: var(--blur-sm);
  border-top: 1px solid var(--glass-border);
  padding: 20px 24px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.footer-address {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.footer-brand {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--red);
}
.footer-copy {
  font-size: 0.8rem;
  color: var(--text-dim);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}
.footer-links li a {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  font-size: 0.8rem;
  color: var(--text-dim);
  border: 1px solid transparent;
  border-radius: 4px;
  transition: color 0.2s, border-color 0.2s;
  min-height: 40px;
}
.footer-links li a:hover {
  color: var(--text-secondary);
  border-color: var(--glass-border);
}

/* ===== 分隔线感 ===== */
.page-content article + article {
  border-top: none;
}

/* ===== 视差层（parallax JS 配合） ===== */
.hero-figure { will-change: transform; }
.bg-orb { will-change: transform; }

/* ===== 焦点可访问性 ===== */
a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
  .content-section {
    grid-template-columns: 1fr;
  }
  .content-aside {
    order: 1;
    position: static;
  }
  .content-main { order: 2; }
}

@media (max-width: 680px) {
  :root {
    --nav-h: 120px;
    --scroll-margin: 130px;
  }
  .header-brand .inner {
    padding: 8px 16px;
  }
  .brand-text { font-size: 1.3rem; }
  .brand-tagline { display: none; }

  .header-nav {
    padding: 6px 16px;
    flex-wrap: wrap;
    gap: 8px;
  }
  .nav-details { width: 100%; }
  .nav-summary {
    display: flex;
  }
  .nav-details:not([open]) .nav-menu {
    display: none;
  }
  .nav-menu {
    padding: 12px 0 4px;
    flex-wrap: wrap;
  }
  .nav-menu li a {
    font-size: 0.84rem;
    padding: 10px 14px;
    min-height: 44px;
  }
  .cta-btn {
    width: 100%;
    justify-content: center;
    min-height: 44px;
  }

  .hero-section {
    padding: 40px 16px 40px;
  }
  .hero-title {
    font-size: clamp(2rem, 9vw, 3rem);
  }
  .hero-sub { font-size: 0.95rem; }
  .hero-aside { gap: 8px; }
  .badge { font-size: 0.72rem; padding: 6px 12px; }

  .content-section {
    padding: 40px 16px 60px;
    gap: 24px;
  }
  .page-content article {
    padding: 24px 20px;
    margin-bottom: 32px;
  }
  .page-content h2 { font-size: 1.35rem; }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .footer-links {
    flex-wrap: wrap;
  }
}

@media (max-width: 375px) {
  .hero-title { font-size: 1.9rem; }
  .nav-menu li a { font-size: 0.8rem; padding: 10px 12px; }
}

/* ===== prefers-reduced-motion ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  html { scroll-behavior: auto; }
}

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