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

/* ============================================================
   CSS 变量 & 重置
   ============================================================ */
:root {
  --c-red: #ff0000;
  --c-pink: #ff006e;
  --c-dark: #1a1a2e;
  --c-darker: #0d0d1a;
  --c-black: #06060f;
  --c-cyan: #00ffff;
  --c-neon-blue: #0080ff;
  --c-white: #f0f0ff;
  --c-muted: #8888aa;
  --c-glass-bg: rgba(255, 0, 110, 0.06);
  --c-glass-border: rgba(255, 0, 110, 0.25);
  --c-glass-border-bright: rgba(255, 0, 0, 0.5);
  --glow-red: 0 0 8px #ff0000, 0 0 20px #ff000066, 0 0 40px #ff000033;
  --glow-pink: 0 0 8px #ff006e, 0 0 20px #ff006e66;
  --glow-cyan: 0 0 8px #00ffff, 0 0 20px #00ffff66;
  --font-display: 'Libre Bodoni', Georgia, serif;
  --font-body: 'Public Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'Courier New', Courier, monospace;
  --nav-h: 68px;
  --radius: 0px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  background: var(--c-black);
  overflow-x: hidden;
  min-height: 100vh;
  padding-bottom: calc(var(--nav-h) + 12px);
}

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

/* ============================================================
   全局装饰层：扫描线 & 噪点
   ============================================================ */
.scanlines-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9000;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0px,
    transparent 3px,
    rgba(0, 0, 0, 0.18) 3px,
    rgba(0, 0, 0, 0.18) 4px
  );
  mix-blend-mode: multiply;
}

.noise-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 8999;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 200px 200px;
}

/* ============================================================
   HERO
   ============================================================ */
.site-hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--c-black) 0%, var(--c-darker) 50%, #120a1e 100%);
  overflow: hidden;
  padding: 6rem 2rem 8rem;
}

.site-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 60% at 20% 50%, rgba(255,0,110,0.12) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 80% 30%, rgba(255,0,0,0.08) 0%, transparent 60%);
  pointer-events: none;
}

.hero-geo-strip {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.geo-line {
  position: absolute;
  background: var(--c-pink);
  opacity: 0.15;
}
.geo-line-1 { top: 0; left: 0; width: 2px; height: 100%; animation: geo-pulse 3s ease-in-out infinite; }
.geo-line-2 { top: 30%; left: 0; width: 40%; height: 1px; animation: geo-pulse 4s ease-in-out infinite 1s; }
.geo-line-3 { bottom: 20%; right: 0; width: 60%; height: 1px; animation: geo-pulse 5s ease-in-out infinite 0.5s; }

@keyframes geo-pulse {
  0%, 100% { opacity: 0.1; }
  50% { opacity: 0.35; }
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 820px;
  width: 100%;
}

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.3em;
  color: var(--c-pink);
  text-shadow: var(--glow-pink);
  margin-bottom: 1rem;
}

.eyebrow-bracket {
  color: var(--c-red);
}

.hero-h1 {
  font-family: var(--font-display);
  font-size: clamp(3rem, 10vw, 7rem);
  font-weight: 700;
  line-height: 1.05;
  color: var(--c-white);
  text-shadow: var(--glow-red);
  margin-bottom: 1.5rem;
  position: relative;
}

/* Glitch effect */
.glitch-text {
  animation: glitch-main 6s infinite;
}

.glitch-text::before,
.glitch-text::after {
  content: attr(data-text);
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  overflow: hidden;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
}

.glitch-text::before {
  color: var(--c-cyan);
  text-shadow: none;
  clip-path: polygon(0 0, 100% 0, 100% 35%, 0 35%);
  animation: glitch-top 6s infinite;
  opacity: 0.8;
}

.glitch-text::after {
  color: var(--c-pink);
  text-shadow: none;
  clip-path: polygon(0 65%, 100% 65%, 100% 100%, 0 100%);
  animation: glitch-bot 6s infinite;
  opacity: 0.8;
}

@keyframes glitch-main {
  0%, 90%, 100% { transform: none; }
  91% { transform: skewX(-1deg); }
  93% { transform: skewX(1.5deg) translateX(2px); }
  95% { transform: skewX(-0.5deg); }
  97% { transform: none; }
}

@keyframes glitch-top {
  0%, 90%, 100% { transform: none; opacity: 0; }
  91% { transform: translateX(-4px); opacity: 0.8; }
  93% { transform: translateX(3px); opacity: 0.8; }
  95% { opacity: 0; }
}

@keyframes glitch-bot {
  0%, 88%, 100% { transform: none; opacity: 0; }
  89% { transform: translateX(4px); opacity: 0.8; }
  91% { transform: translateX(-2px); opacity: 0.8; }
  93% { opacity: 0; }
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--c-muted);
  max-width: 560px;
  margin-bottom: 2.5rem;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 0.8rem 2rem;
  background: linear-gradient(90deg, var(--c-red), var(--c-pink));
  color: #fff;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.05em;
  border: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  box-shadow: 0 0 20px rgba(255,0,110,0.4);
  min-height: 48px;
}

.btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  opacity: 0;
  transition: opacity var(--transition);
}

.btn-primary:hover::after { opacity: 1; }
.btn-primary:hover { box-shadow: 0 0 30px rgba(255,0,0,0.6), 0 0 60px rgba(255,0,110,0.3); }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  padding: 0.8rem 2rem;
  background: transparent;
  color: var(--c-cyan);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  border: 1px solid var(--c-cyan);
  cursor: pointer;
  transition: var(--transition);
  text-shadow: var(--glow-cyan);
  box-shadow: 0 0 10px rgba(0,255,255,0.15) inset;
  min-height: 48px;
}

.btn-ghost:hover {
  background: rgba(0,255,255,0.08);
  box-shadow: 0 0 20px rgba(0,255,255,0.3), 0 0 10px rgba(0,255,255,0.15) inset;
}

/* Hero slash divider */
.hero-slash {
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 80px;
  background: var(--c-black);
  clip-path: polygon(0 60%, 100% 0, 100% 100%, 0 100%);
  z-index: 3;
}

.hero-slash::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--c-red), var(--c-pink), transparent);
  transform: skewY(-2deg);
}

/* ============================================================
   MAIN CONTENT
   ============================================================ */
.site-main {
  position: relative;
  z-index: 1;
}

.content-shell {
  display: grid;
  grid-template-columns: auto 1fr 300px;
  grid-template-areas: "deco content aside";
  gap: 0 2rem;
  max-width: 1280px;
  margin: 0 auto;
  padding: 4rem 2rem;
  align-items: start;
}

.content-deco-figure {
  grid-area: deco;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding-top: 0.5rem;
  width: 24px;
}

.deco-line {
  display: block;
  width: 2px;
  background: linear-gradient(to bottom, var(--c-red), var(--c-pink));
}

.deco-v1 { height: 80px; }
.deco-v2 { height: 120px; opacity: 0.4; }

.deco-dot {
  display: block;
  width: 8px;
  height: 8px;
  background: var(--c-red);
  border-radius: 50%;
  box-shadow: var(--glow-red);
  animation: dot-pulse 2s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.7; }
}

.content-body {
  grid-area: content;
  min-width: 0;
}

/* page.content sections */
.content-body section {
  margin-bottom: 4rem;
  scroll-margin-top: calc(var(--nav-h) + 1.5rem);
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.content-body section.is-visible {
  opacity: 1;
  transform: none;
}

.content-body h2 {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 700;
  color: var(--c-white);
  text-shadow: var(--glow-red);
  line-height: 1.2;
  margin-bottom: 0.6rem;
}

.content-body h2 + hr,
.content-body h3 + hr {
  border: none;
  border-top: 1px solid var(--c-glass-border-bright);
  margin-bottom: 1.5rem;
  box-shadow: 0 0 8px rgba(255,0,0,0.2);
}

.content-body h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--c-pink);
  text-shadow: var(--glow-pink);
  margin: 2rem 0 0.5rem;
}

.content-body p {
  font-size: 1rem;
  line-height: 1.75;
  color: #ccccee;
  margin-bottom: 1rem;
}

.content-body a {
  color: var(--c-cyan);
  text-shadow: var(--glow-cyan);
  border-bottom: 1px solid rgba(0,255,255,0.3);
  transition: color var(--transition), border-color var(--transition);
}

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

.content-body ul, .content-body ol {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
  list-style: none;
}

.content-body ul li::before {
  content: '▸';
  color: var(--c-red);
  margin-right: 0.5rem;
}

.content-body ol {
  counter-reset: ol-cnt;
}

.content-body ol li {
  counter-increment: ol-cnt;
}

.content-body ol li::before {
  content: counter(ol-cnt, decimal-leading-zero) '.';
  color: var(--c-pink);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  margin-right: 0.5rem;
}

.content-body blockquote {
  border-left: 3px solid var(--c-red);
  padding: 0.8rem 1.2rem;
  margin: 1.5rem 0;
  background: rgba(255,0,0,0.06);
  color: var(--c-muted);
  font-style: italic;
}

.content-body strong { color: var(--c-white); font-weight: 700; }
.content-body em { color: var(--c-pink); }

.content-body code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  color: var(--c-cyan);
  background: rgba(0,255,255,0.08);
  padding: 0.1em 0.4em;
}

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

.content-body th {
  background: rgba(255,0,110,0.15);
  color: var(--c-pink);
  font-weight: 700;
  padding: 0.6rem 1rem;
  border: 1px solid var(--c-glass-border);
  text-align: left;
}

.content-body td {
  padding: 0.6rem 1rem;
  border: 1px solid rgba(255,255,255,0.06);
  color: #ccccee;
}

.content-body tr:nth-child(even) td {
  background: rgba(255,255,255,0.02);
}

/* ============================================================
   ASIDE
   ============================================================ */
.content-aside {
  grid-area: aside;
  position: sticky;
  top: calc(var(--nav-h) + 1.5rem);
}

.aside-glass {
  background: var(--c-glass-bg);
  border: 1px solid var(--c-glass-border);
  padding: 1.5rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 0 20px rgba(255,0,110,0.08), inset 0 1px 0 rgba(255,255,255,0.05);
}

.aside-heading {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--c-pink);
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.aside-glass hr {
  border: none;
  border-top: 1px solid var(--c-glass-border);
  margin-bottom: 1rem;
}

.aside-nav-list {
  margin-bottom: 1.5rem;
}

.aside-nav-list li {
  margin-bottom: 0.4rem;
}

.aside-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #ccccee;
  padding: 0.3rem 0.5rem;
  transition: color var(--transition), background var(--transition);
  min-height: 40px;
}

.aside-link:hover {
  color: var(--c-cyan);
  background: rgba(0,255,255,0.05);
}

.aside-arrow {
  color: var(--c-red);
  font-size: 0.65rem;
  flex-shrink: 0;
}

.aside-tag-block {
  border-top: 1px solid var(--c-glass-border);
  padding-top: 1rem;
}

.aside-tag-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--c-muted);
  letter-spacing: 0.15em;
  margin-bottom: 0.5rem;
}

.aside-tag {
  display: inline-block;
  padding: 0.3em 0.8em;
  border: 1px solid var(--c-red);
  color: var(--c-red);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-shadow: var(--glow-red);
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--c-darker);
  border-top: 1px solid var(--c-glass-border);
  position: relative;
  z-index: 2;
  margin-top: 2rem;
}

.footer-top-bar {
  height: 3px;
  background: linear-gradient(90deg, var(--c-red), var(--c-pink), var(--c-cyan), var(--c-pink), var(--c-red));
  background-size: 200% 100%;
  animation: bar-slide 4s linear infinite;
}

@keyframes bar-slide {
  0% { background-position: 0 0; }
  100% { background-position: 200% 0; }
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 3rem 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.footer-logo {
  margin-bottom: 1rem;
}

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

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

.brand-text-logo {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--c-white);
  text-shadow: var(--glow-red);
}

.logo-mark {
  color: var(--c-red);
  font-size: 1.1em;
}

.footer-brand-desc {
  font-size: 0.9rem;
  color: var(--c-muted);
  line-height: 1.6;
  margin-bottom: 1.5rem;
  max-width: 360px;
}

.footer-contact {
  margin-bottom: 1rem;
}

.contact-row {
  display: block;
  font-size: 0.85rem;
  color: var(--c-muted);
}

.contact-row a {
  color: var(--c-cyan);
  text-shadow: var(--glow-cyan);
}

.footer-social-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.footer-social-link {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 1rem;
  border: 1px solid var(--c-glass-border);
  color: var(--c-muted);
  font-size: 0.85rem;
  transition: color var(--transition), border-color var(--transition);
  min-height: 40px;
}

.footer-social-link:hover {
  color: var(--c-pink);
  border-color: var(--c-pink);
  text-shadow: var(--glow-pink);
}

.footer-nav-block {
  padding-top: 0.5rem;
}

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

.footer-nav-dt {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--c-pink);
  margin-bottom: 0.75rem;
}

.footer-nav-dd {
  margin: 0;
}

.footer-nav-link {
  display: flex;
  align-items: center;
  padding: 0.45rem 0;
  font-size: 0.9rem;
  color: var(--c-muted);
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: color var(--transition), padding-left var(--transition);
  min-height: 40px;
}

.footer-nav-link:hover {
  color: var(--c-white);
  padding-left: 0.5rem;
}

.footer-bottom-bar {
  border-top: 1px solid rgba(255,255,255,0.05);
  padding: 1.2rem 2rem;
  text-align: center;
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--c-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}

/* ============================================================
   BOTTOM FIXED CAPSULE NAV
   ============================================================ */
.bottom-nav-wrap {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9500;
  width: calc(100% - 32px);
  max-width: 900px;
}

.bottom-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(13, 13, 26, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--c-glass-border);
  border-radius: 999px;
  padding: 0.4rem 1rem;
  box-shadow: 0 0 30px rgba(255,0,110,0.15), 0 4px 24px rgba(0,0,0,0.6);
  gap: 0.5rem;
  height: var(--nav-h);
}

.bottom-nav-brand {
  flex-shrink: 0;
  order: 2;
}

.bottom-nav-brand .brand-text-logo {
  font-size: 1rem;
  white-space: nowrap;
}

.bottom-nav-brand .brand-logo-img {
  height: 28px;
}

.bottom-nav-dl {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: nowrap;
}

.bottom-nav-left { order: 1; }
.bottom-nav-right { order: 3; }

.bottom-nav-dl dt { display: none; }

.bottom-nav-dl dd { margin: 0; }

.nav-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--c-muted);
  white-space: nowrap;
  transition: color var(--transition), background var(--transition), box-shadow var(--transition);
  min-height: 40px;
}

.nav-pill:hover {
  color: var(--c-white);
  background: rgba(255,255,255,0.07);
}

.nav-cta {
  background: linear-gradient(90deg, var(--c-red), var(--c-pink));
  color: #fff !important;
  font-weight: 700;
  box-shadow: 0 0 12px rgba(255,0,110,0.4);
  padding: 0.45rem 1.1rem;
}

.nav-cta:hover {
  background: linear-gradient(90deg, #ff2020, #ff3388) !important;
  box-shadow: 0 0 20px rgba(255,0,110,0.6) !important;
}

/* ============================================================
   SCROLL REVEAL (JS 控制)
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ============================================================
   HR 通用样式
   ============================================================ */
hr {
  border: none;
  border-top: 1px solid var(--c-glass-border);
  margin: 1rem 0;
}

/* ============================================================
   Scroll margin for anchor sections
   ============================================================ */
div[id] {
  scroll-margin-top: calc(var(--nav-h) + 1.5rem);
}

/* ============================================================
   RESPONSIVE: Tablet
   ============================================================ */
@media (max-width: 1024px) {
  .content-shell {
    grid-template-columns: auto 1fr;
    grid-template-areas:
      "deco content"
      "deco aside";
  }

  .content-aside {
    position: static;
    margin-top: 2rem;
  }

  .aside-glass {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
  }

  .aside-nav-list { min-width: 200px; }
}

@media (max-width: 768px) {
  .content-shell {
    grid-template-columns: 1fr;
    grid-template-areas:
      "content"
      "aside";
    padding: 2rem 1rem;
  }

  .content-deco-figure { display: none; }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 2rem 1rem;
  }

  .hero-h1 { font-size: clamp(2.2rem, 12vw, 4rem); }

  .site-hero {
    padding: 4rem 1.25rem 6rem;
    min-height: 65vh;
  }
}

/* ============================================================
   RESPONSIVE: Mobile 375px
   ============================================================ */
@media (max-width: 480px) {
  .bottom-nav-inner {
    border-radius: 999px;
    padding: 0.3rem 0.5rem;
    gap: 0.2rem;
  }

  .nav-pill {
    padding: 0.4rem 0.55rem;
    font-size: 0.7rem;
  }

  .nav-cta { padding: 0.4rem 0.7rem; }

  .bottom-nav-brand .brand-text-logo { font-size: 0.85rem; }

  .hero-actions { flex-direction: column; }

  .btn-primary, .btn-ghost {
    width: 100%;
    justify-content: center;
  }

  .content-shell { padding: 1.5rem 1rem; }

  .footer-bottom-bar { padding: 1rem; }
  .footer-copy { font-size: 0.72rem; }
}

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

  html { scroll-behavior: auto; }

  .content-body div,
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}
