/* ============ 1. RESET ============ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Noto Sans CJK Regular', 'Source Han Sans CN', 'Microsoft YaHei', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  background: var(--bg-deep);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

img, svg {
  display: block;
  max-width: 100%;
}

ul {
  list-style: none;
}

a {
  color: var(--neon);
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

button {
  font: inherit;
  border: 0;
  background: none;
  cursor: pointer;
}

h1, h2, h3, h4 {
  font-family: 'Noto Sans CJK Black', 'Source Han Sans CN', 'Microsoft YaHei', sans-serif;
  font-weight: 900;
  color: var(--text-bright);
  line-height: 1.2;
}

h1 {
  font-size: clamp(36px, 5vw, 72px);
  letter-spacing: .01em;
}

h2 {
  font-size: clamp(24px, 3.4vw, 36px);
}

h3 {
  font-size: clamp(18px, 2vw, 24px);
}

p {
  margin-bottom: 12px;
}

/* ============ 2. VALUES ============ */
:root {
  --bg-deep: #0B1B3D;
  --bg-darker: #0A1226;
  --bg-violet: #1B1040;
  --neon: #39FF14;
  --neon-soft: #2EE59D;
  --purple: #9D00FF;
  --text: #C8D0E0;
  --text-bright: #F2F5FA;
  --orange: #FF7A00;
  --card-line: rgba(200, 208, 224, .12);
  --shadow-neon: 0 0 24px rgba(57, 255, 20, .35);
  --shadow-purple: 0 0 30px rgba(157, 0, 255, .3);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-pill: 999px;
  --font-heading: 'Noto Sans CJK Black', 'Source Han Sans CN', 'Microsoft YaHei', sans-serif;
  --font-body: 'Noto Sans CJK Regular', 'Source Han Sans CN', 'Microsoft YaHei', sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
  --container-width: 1200px;
  --header-space: 96px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

/* ============ 3. TYPO & SELECTION ============ */
::selection {
  background: rgba(157, 0, 255, .6);
  color: var(--text-bright);
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--neon);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ============ 4. MAIN & CONTAINER ============ */
.site-main {
  display: block;
}

#main-content {
  display: block;
  padding-top: var(--header-space);
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: clamp(16px, 3vw, 40px);
}

.section {
  position: relative;
  padding-block: clamp(56px, 7vw, 100px);
}

.section--tight {
  padding-block: clamp(32px, 4vw, 56px);
}

/* ============ 5. HEADER ============ */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  padding: 14px 18px 0;
  transition: padding .3s var(--ease);
}

.header-inner {
  max-width: 1100px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(10, 18, 38, .85);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(57, 255, 20, .18);
  border-radius: var(--radius-pill);
  padding: 8px 10px 8px 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, .45), inset 0 0 0 1px rgba(157, 0, 255, .1);
  transition: padding .3s var(--ease), background .3s var(--ease), box-shadow .3s var(--ease);
}

.site-header[data-scrolled] .header-inner {
  padding: 6px 10px 6px 16px;
  background: rgba(10, 18, 38, .94);
  box-shadow: 0 6px 24px rgba(0, 0, 0, .5), inset 0 0 0 1px rgba(157, 0, 255, .18);
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: linear-gradient(145deg, var(--bg-violet), var(--bg-deep));
  border: 1px solid var(--purple);
  box-shadow: 0 0 10px rgba(157, 0, 255, .3);
  flex-shrink: 0;
}

.brand-mark i {
  width: 3px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--neon), var(--purple));
  display: block;
}

.brand-mark i:nth-child(1) {
  height: 10px;
  transform: rotate(-10deg);
}

.brand-mark i:nth-child(2) {
  height: 16px;
}

.brand-mark i:nth-child(3) {
  height: 12px;
  transform: rotate(10deg);
}

.brand-text strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 18px;
  line-height: 1.1;
  color: var(--text-bright);
  letter-spacing: .04em;
}

.brand-text small {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--neon);
  letter-spacing: .22em;
  line-height: 1;
  margin-top: 3px;
}

.brand-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--neon);
  border: 1px solid rgba(57, 255, 20, .3);
  border-radius: var(--radius-pill);
  padding: 4px 10px;
  margin-left: 8px;
  letter-spacing: .12em;
  white-space: nowrap;
  flex-shrink: 0;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--neon);
  box-shadow: 0 0 8px var(--neon);
  animation: livePulse 1.8s infinite ease-in-out;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .4; transform: scale(.75); }
}

.site-nav {
  margin-left: auto;
  margin-right: 4px;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav a {
  display: block;
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
  transition: background .25s var(--ease), color .25s var(--ease), box-shadow .25s var(--ease);
}

.site-nav a:hover {
  color: var(--neon);
  background: rgba(57, 255, 20, .08);
}

.site-nav a[aria-current="page"] {
  color: var(--bg-deep);
  background: var(--neon);
  box-shadow: var(--shadow-neon);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.header-lang {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  opacity: .75;
  letter-spacing: .08em;
  white-space: nowrap;
}

.header-cta {
  background: var(--neon);
  color: var(--bg-deep);
  border-radius: var(--radius-pill);
  font-weight: 900;
  font-size: 14px;
  padding: 10px 18px;
  letter-spacing: .02em;
  box-shadow: 0 0 0 0 rgba(57, 255, 20, .4);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
  white-space: nowrap;
}

.header-cta:hover {
  box-shadow: 0 0 26px rgba(57, 255, 20, .55);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: rgba(157, 0, 255, .14);
  border: 1px solid rgba(157, 0, 255, .5);
  align-items: center;
  justify-content: center;
  gap: 5px;
  position: relative;
  flex-shrink: 0;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text-bright);
  border-radius: var(--radius-pill);
  transition: transform .3s var(--ease), opacity .3s var(--ease);
}

.site-header[data-nav-open] .nav-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.site-header[data-nav-open] .nav-toggle span:nth-child(2) {
  opacity: 0;
}

.site-header[data-nav-open] .nav-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 210;
  pointer-events: none;
}

.scroll-progress::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, var(--neon), var(--purple));
  transform: scaleX(var(--scroll-progress, 0));
  transform-origin: 0 0;
  will-change: transform;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 300;
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  background: var(--neon);
  color: var(--bg-deep);
  font-weight: 900;
  box-shadow: var(--shadow-neon);
  transform: translateY(-160%);
  transition: transform .25s var(--ease);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

/* ============ 6. FOOTER ============ */
.site-footer {
  background: var(--bg-darker);
  color: var(--text);
  border-top: 1px solid rgba(157, 0, 255, .25);
  padding: 0 0 28px;
  position: relative;
  overflow: hidden;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--neon) 20%, var(--purple) 60%, transparent);
  opacity: .6;
}

.site-footer::after {
  content: '';
  position: absolute;
  bottom: -120px;
  right: -80px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(157, 0, 255, .18), transparent 70%);
  pointer-events: none;
}

.footer-accent {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--neon), var(--purple), transparent);
  opacity: .4;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.2fr .9fr;
  gap: clamp(24px, 5vw, 64px);
  padding-block: clamp(32px, 5vw, 56px) 24px;
}

.footer-brand-col {
  position: relative;
  z-index: 1;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.site-footer .brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 14px;
}

.footer-brand strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 22px;
  color: var(--text-bright);
  letter-spacing: .04em;
}

.footer-brand small {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neon);
  letter-spacing: .2em;
  margin-top: 2px;
}

.footer-about {
  font-size: 14px;
  line-height: 1.8;
  color: rgba(200, 208, 224, .78);
  max-width: 360px;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.footer-legal a {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(157, 0, 255, .45);
  transition: border-color .25s var(--ease), color .25s var(--ease), box-shadow .25s var(--ease);
}

.footer-legal a:hover {
  border-color: var(--neon);
  color: var(--neon);
  box-shadow: 0 0 14px rgba(57, 255, 20, .2);
}

.footer-contact {
  position: relative;
  z-index: 1;
}

.footer-heading {
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: .16em;
  color: var(--text-bright);
  font-weight: 700;
}

.footer-index {
  color: var(--neon);
  margin-right: 6px;
}

.footer-contact ul {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.footer-contact li {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
}

.contact-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  color: var(--purple);
  margin-bottom: 2px;
}

.footer-note {
  margin-top: 18px;
  font-size: 13px;
  color: rgba(200, 208, 224, .6);
  border-left: 2px solid rgba(157, 0, 255, .5);
  padding-left: 12px;
}

.footer-bottom {
  border-top: 1px solid rgba(200, 208, 224, .12);
  padding-top: 20px;
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: rgba(200, 208, 224, .7);
  font-family: var(--font-mono);
}

.footer-icp {
  opacity: .85;
}

/* ============ 7. PAGE & SECTION COMPONENTS ============ */
.section-head {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: clamp(24px, 4vw, 40px);
  position: relative;
}

.section-head-main {
  flex: 1;
}

.section-index {
  font-family: var(--font-mono);
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 800;
  line-height: 1;
  color: var(--neon);
  letter-spacing: .02em;
  user-select: none;
}

.section-title {
  font-size: clamp(22px, 3vw, 36px);
  line-height: 1.15;
  margin-bottom: 6px;
}

.section-note {
  writing-mode: vertical-rl;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--purple);
  border-left: 2px solid var(--purple);
  padding-left: 6px;
  white-space: nowrap;
  text-transform: uppercase;
}

.page-hero {
  position: relative;
  padding-block: clamp(80px, 12vh, 140px) clamp(48px, 6vw, 72px);
}

.frame-hero {
  position: relative;
  border: 1px solid rgba(157, 0, 255, .4);
  background: linear-gradient(135deg, rgba(11, 27, 61, .6), rgba(27, 16, 64, .5));
  border-radius: 28px;
  padding: clamp(24px, 4vw, 56px);
  box-shadow: inset 0 0 40px rgba(157, 0, 255, .08);
}

.frame-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(57, 255, 20, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(57, 255, 20, .05) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
  border-radius: 28px;
}

.frame-tick {
  position: absolute;
  width: 38px;
  height: 38px;
  border: 0 solid var(--neon);
  opacity: .8;
  z-index: 2;
}

.frame-tick--tl {
  top: -2px;
  left: -2px;
  border-top-width: 2px;
  border-left-width: 2px;
  border-top-left-radius: 14px;
}

.frame-tick--tr {
  top: -2px;
  right: -2px;
  border-top-width: 2px;
  border-right-width: 2px;
  border-top-right-radius: 14px;
}

.frame-tick--bl {
  bottom: -2px;
  left: -2px;
  border-bottom-width: 2px;
  border-left-width: 2px;
  border-bottom-left-radius: 14px;
}

.frame-tick--br {
  bottom: -2px;
  right: -2px;
  border-bottom-width: 2px;
  border-right-width: 2px;
  border-bottom-right-radius: 14px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  padding-block: 16px;
  color: var(--text);
}

.breadcrumb a {
  color: var(--text);
  font-weight: 700;
  transition: color .2s var(--ease);
}

.breadcrumb a:hover {
  color: var(--neon);
}

.breadcrumb .sep {
  color: var(--purple);
  font-family: var(--font-mono);
}

.breadcrumb .current {
  color: var(--neon);
}

/* ============ 8. BENTO & PANEL ============ */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(16px, 2vw, 28px);
}

.span-3 {
  grid-column: span 3;
}

.span-4 {
  grid-column: span 4;
}

.span-6 {
  grid-column: span 6;
}

.span-8 {
  grid-column: span 8;
}

.span-12 {
  grid-column: 1 / -1;
}

.panel {
  background: linear-gradient(145deg, rgba(11, 27, 61, .85), rgba(27, 16, 64, .9));
  border: 1px solid var(--card-line);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 32px);
  position: relative;
  transition: border-color .3s var(--ease), box-shadow .3s var(--ease);
}

.panel:hover {
  border-color: rgba(57, 255, 20, .4);
}

.panel--neon {
  border-color: rgba(57, 255, 20, .35);
}

.panel--violet {
  border-color: rgba(157, 0, 255, .35);
}

/* ============ 9. BUTTONS, TAGS, DATA ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-weight: 900;
  font-size: 15px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: box-shadow .25s var(--ease), transform .25s var(--ease), border-color .25s var(--ease);
  cursor: pointer;
}

.btn-accent {
  background: var(--neon);
  color: var(--bg-deep);
}

.btn-accent:hover {
  box-shadow: var(--shadow-neon);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  border-color: rgba(157, 0, 255, .6);
  color: var(--text-bright);
}

.btn-ghost:hover {
  border-color: var(--neon);
  color: var(--neon);
  box-shadow: 0 0 16px rgba(57, 255, 20, .2);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(157, 0, 255, .16);
  color: var(--text-bright);
  font-size: 13px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(157, 0, 255, .45);
}

.data-card {
  background: linear-gradient(145deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
  border: 1px solid rgba(200, 208, 224, .16);
  border-radius: 20px;
  padding: 20px;
}

.data-card-label {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .14em;
  color: var(--text);
  opacity: .8;
}

.data-card-value {
  font-family: var(--font-mono);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  color: var(--neon);
  line-height: 1.1;
  margin-block: 4px 2px;
}

.data-card-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  opacity: .7;
}

.glow-line {
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--purple), var(--neon), transparent);
  border: 0;
  opacity: .7;
}

/* ============ 10. MEDIA ============ */
.media-frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(157, 0, 255, .2);
  background: linear-gradient(145deg, var(--bg-violet), var(--bg-deep));
  aspect-ratio: 16 / 10;
}

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 24px rgba(11, 27, 61, .4);
}

.media-frame--ratio-wide {
  aspect-ratio: 16 / 8;
}

.media-frame--square {
  aspect-ratio: 1 / 1;
}

.media-frame--portrait {
  aspect-ratio: 3 / 4;
}

/* ============ 11. REVEAL ============ */
[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}

[data-reveal-visible] {
  opacity: 1;
  transform: none;
}

/* ============ 12. RESPONSIVE ============ */
@media (max-width: 1199px) {
  .span-3,
  .span-4,
  .span-6,
  .span-8 {
    grid-column: span 6;
  }

  .span-12 {
    grid-column: 1 / -1;
  }
}

@media (max-width: 991px) {
  .header-lang {
    display: none;
  }

  .brand-live {
    display: none;
  }

  .site-header {
    padding: 12px 14px 0;
  }

  .header-inner {
    padding: 7px 8px 7px 14px;
    border-radius: 24px;
  }

  .header-cta {
    padding: 9px 14px;
    font-size: 13px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: fixed;
    top: 78px;
    right: 18px;
    bottom: 18px;
    width: min(340px, 82vw);
    background: rgba(10, 18, 38, .96);
    border: 1px solid rgba(157, 0, 255, .4);
    border-radius: 24px;
    padding: 24px 20px;
    transform: translateX(calc(100% + 24px));
    transition: transform .35s var(--ease), visibility .35s;
    visibility: hidden;
    z-index: 110;
    overflow-y: auto;
  }

  .site-nav[data-open] {
    transform: translateX(0);
    visibility: visible;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }

  .nav-list a {
    display: block;
    font-size: 16px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
  }

  .nav-list a[aria-current="page"] {
    background: var(--neon);
    color: var(--bg-deep);
  }
}

@media (max-width: 767px) {
  .section-note {
    display: none;
  }

  .frame-hero {
    padding: 20px;
  }

  .footer-top {
    grid-template-columns: 1fr;
    padding-top: 24px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .span-3,
  .span-4,
  .span-6,
  .span-8,
  .span-12 {
    grid-column: 1 / -1;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
