/* 基础与主题 */
:root {
  --bg-0: #f5f5f7;
  --bg-1: #ececef;
  --ink: #111;
  --ink-weak: rgba(0, 0, 0, 0.65);
  --glass: rgba(255, 255, 255, 0.25);
  --glass-2: rgba(255, 255, 255, 0.45);
  --shadow: rgba(0, 0, 0, 0.12);
  --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html, body, #app {
  height: 100%;
}

html, body {
  background: var(--bg-0);
  color: var(--ink);
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Noto Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.stage {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.stage[aria-hidden="true"] {
  pointer-events: none;
  opacity: 0;
  transition: opacity 300ms var(--ease-smooth);
}

.stage[aria-hidden="false"] {
  opacity: 1;
  transition: opacity 300ms var(--ease-smooth);
}

/* 玻璃风格背景 */
.glass-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(1200px 800px at 20% 20%, rgba(255,255,255,0.9), transparent 60%),
    radial-gradient(1000px 700px at 80% 70%, rgba(255,255,255,0.75), transparent 60%),
    linear-gradient(180deg, var(--bg-1), var(--bg-0));
  backdrop-filter: saturate(160%) blur(8px);
  -webkit-backdrop-filter: saturate(160%) blur(8px);
}

/* 加载界面文字 */
.loader-backdrop-title {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: clamp(64px, 14vw, 220px);
  font-style: italic;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink-weak);
  text-shadow: 0 10px 30px rgba(0,0,0,0.06);
  opacity: 0;
  transform: translate3d(0, 10px, 0);
  transition: opacity 900ms var(--ease-smooth), transform 900ms var(--ease-smooth);
  user-select: none;
  pointer-events: none;
  z-index: 2;
}

.loader-fore-title {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-weight: 800;
  letter-spacing: 0.02em;
  font-size: clamp(36px, 10vw, 120px);
  color: var(--ink);
  text-shadow: 0 8px 24px var(--shadow);
  animation: loaderPulse 1.8s ease-in-out infinite;
  z-index: 3;
}

@keyframes loaderPulse {
  0%, 100% { opacity: 0.65; }
  50% { opacity: 1; }
}

.enter-hint {
  position: absolute;
  left: 50%;
  bottom: 4vh;
  transform: translateX(-50%);
  font-size: clamp(14px, 2.2vw, 18px);
  color: var(--ink);
  background: var(--glass);
  border: 1px solid rgba(0,0,0,0.06);
  padding: 10px 16px;
  border-radius: 12px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.08);
  opacity: 0;
  pointer-events: none;
  transition: opacity 600ms var(--ease-smooth), transform 600ms var(--ease-smooth);
  z-index: 4;
}

#loader.ready .enter-hint {
  opacity: 1;
  pointer-events: auto;
  animation: hintBlink 1.3s steps(2, end) infinite;
}

@keyframes hintBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* 加载界面彩色空心大字背景 */
.loader-bg-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  opacity: 0.08;
}

.loader-bg-text {
  position: absolute;
  font-size: clamp(100px, 18vw, 280px);
  font-weight: 900;
  font-style: italic;
  color: transparent;
  -webkit-text-stroke: 2px #ff6b7a;
  white-space: nowrap;
  will-change: transform;
}

.loader-bg-text:nth-child(1) {
  top: 5%;
  left: -15%;
  -webkit-text-stroke-color: #ff7a7a;
  animation: loaderBgFloat1 35s linear infinite;
}

.loader-bg-text:nth-child(2) {
  top: 20%;
  right: -20%;
  -webkit-text-stroke-color: #7aa8ff;
  animation: loaderBgFloat2 42s linear infinite;
}

.loader-bg-text:nth-child(3) {
  top: 40%;
  left: -25%;
  -webkit-text-stroke-color: #7affd4;
  animation: loaderBgFloat3 38s linear infinite;
}

.loader-bg-text:nth-child(4) {
  top: 60%;
  right: -15%;
  -webkit-text-stroke-color: #ffb36b;
  animation: loaderBgFloat4 45s linear infinite;
}

.loader-bg-text:nth-child(5) {
  top: 75%;
  left: -30%;
  -webkit-text-stroke-color: #a77aff;
  animation: loaderBgFloat5 36s linear infinite;
}

.loader-bg-text:nth-child(6) {
  top: 90%;
  right: -25%;
  -webkit-text-stroke-color: #ff7ae7;
  animation: loaderBgFloat6 40s linear infinite;
}

@keyframes loaderBgFloat1 {
  from { transform: translateX(-100%); }
  to { transform: translateX(120%); }
}

@keyframes loaderBgFloat2 {
  from { transform: translateX(100%); }
  to { transform: translateX(-120%); }
}

@keyframes loaderBgFloat3 {
  from { transform: translateX(-100%); }
  to { transform: translateX(120%); }
}

@keyframes loaderBgFloat4 {
  from { transform: translateX(100%); }
  to { transform: translateX(-120%); }
}

@keyframes loaderBgFloat5 {
  from { transform: translateX(-100%); }
  to { transform: translateX(120%); }
}

@keyframes loaderBgFloat6 {
  from { transform: translateX(100%); }
  to { transform: translateX(-120%); }
}

/* SVG 丝线特效 */
.silk {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  filter: url(#softGlow);
  z-index: 1;
}

.silk-line {
  fill: none;
  stroke-width: 3.5;
  stroke-linecap: round;
  opacity: 0.85;
  stroke-dasharray: 8 12;
  animation: dashFlow 2.8s linear infinite;
}

@keyframes dashFlow {
  to { stroke-dashoffset: -80; }
}

.silk-group {
  transform: translate3d(0, 0, 0);
  opacity: 0;
}

.silk-group--left {
  animation: silkEnterLeft 1.2s var(--ease-smooth) forwards;
}

.silk-group--right {
  animation: silkEnterRight 1.2s var(--ease-smooth) 120ms forwards;
}

@keyframes silkEnterLeft {
  from { transform: translate3d(-14%, 0, 0); opacity: 0; }
  to { transform: translate3d(0, 0, 0); opacity: 1; }
}

@keyframes silkEnterRight {
  from { transform: translate3d(14%, 0, 0); opacity: 0; }
  to { transform: translate3d(0, 0, 0); opacity: 1; }
}

/* 当丝线在中间交织时，让背景空心大字淡入 */
#loader.interweave .loader-backdrop-title {
  opacity: 0.65;
  transform: translate3d(0, 0, 0);
}

/* 当加载完成，停止中间闪烁 */
#loader.ready .loader-fore-title {
  animation: none;
  opacity: 1;
}

/* 过渡界面（3行占满屏） */
.stage--transition {
  background: var(--bg-0);
  display: grid;
  grid-template-rows: 1fr 1fr 1fr;
  gap: 0;
}

.stage--transition .row {
  position: relative;
  overflow: hidden;
}

.stage--transition .ticker {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%) translateX(-100%);
  white-space: nowrap;
  will-change: transform;
  font-size: clamp(36px, 16vw, 140px);
  font-weight: 900;
  color: var(--ink);
  opacity: 1;
}

.stage--transition.run .ticker {
  animation: tickerRun 1.8s linear forwards;
}

@keyframes tickerRun {
  from { transform: translateY(-50%) translateX(-100%); }
  to { transform: translateY(-50%) translateX(110%); }
}

/* 主页面布局 */
.stage--main {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr; /* 1/4 | 1/2 | 1/4 */
  align-items: stretch;
  background: var(--bg-0);
  transition: opacity 560ms var(--ease-smooth) 100ms;
  position: relative;
}

/* 主页面彩色空心大字背景 */
.main-backdrop {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  opacity: 0.15;
}

.bg-text {
  position: absolute;
  font-size: clamp(120px, 20vw, 300px);
  font-weight: 900;
  font-style: italic;
  color: transparent;
  -webkit-text-stroke: 2.2px #ff6b7a;
  white-space: nowrap;
  will-change: transform;
}

.bg-text:nth-child(1) {
  top: 10%;
  left: -10%;
  -webkit-text-stroke-color: #ff7a7a;
  animation: bgFloat1 45s linear infinite;
}

.bg-text:nth-child(2) {
  top: 25%;
  right: -15%;
  -webkit-text-stroke-color: #7aa8ff;
  animation: bgFloat2 52s linear infinite;
}

.bg-text:nth-child(3) {
  top: 45%;
  left: -20%;
  -webkit-text-stroke-color: #7affd4;
  animation: bgFloat3 48s linear infinite;
}

.bg-text:nth-child(4) {
  top: 65%;
  right: -10%;
  -webkit-text-stroke-color: #ffb36b;
  animation: bgFloat4 55s linear infinite;
}

.bg-text:nth-child(5) {
  top: 80%;
  left: -25%;
  -webkit-text-stroke-color: #a77aff;
  animation: bgFloat5 46s linear infinite;
}

.bg-text:nth-child(6) {
  top: 95%;
  right: -20%;
  -webkit-text-stroke-color: #ff7ae7;
  animation: bgFloat6 50s linear infinite;
}

@keyframes bgFloat1 {
  from { transform: translateX(-100%); }
  to { transform: translateX(120%); }
}

@keyframes bgFloat2 {
  from { transform: translateX(100%); }
  to { transform: translateX(-120%); }
}

@keyframes bgFloat3 {
  from { transform: translateX(-100%); }
  to { transform: translateX(120%); }
}

@keyframes bgFloat4 {
  from { transform: translateX(100%); }
  to { transform: translateX(-120%); }
}

@keyframes bgFloat5 {
  from { transform: translateX(-100%); }
  to { transform: translateX(120%); }
}

@keyframes bgFloat6 {
  from { transform: translateX(100%); }
  to { transform: translateX(-120%); }
}

.stage--main > .side,
.stage--main > .center {
  position: relative;
  z-index: 1;
}

.side {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: stretch;
}

.side--left {
  justify-content: flex-start;
  padding-left: 1vw;
}

.side--right {
  justify-content: flex-end;
  padding-right: 1vw;
}

.scroll-container {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  writing-mode: vertical-rl;
  text-orientation: upright;
}

.text-stream {
  position: absolute;
  font-weight: 900;
  font-size: clamp(42px, 8vw, 180px);
  color: var(--ink);
  opacity: 0.9;
  white-space: nowrap;
  writing-mode: vertical-rl;
  text-orientation: upright;
  letter-spacing: 0.3em;
  line-height: 1.2;
  will-change: transform;
  animation: verticalFlow 28s linear infinite;
}

.side--left .text-stream {
  left: 0;
  text-align: left;
}

.side--right .text-stream {
  right: 0;
  text-align: right;
}

@keyframes verticalFlow {
  from {
    transform: translateY(100vh);
  }
  to {
    transform: translateY(-100%);
  }
}

.center {
  position: relative;
  display: grid;
  place-items: center;
  gap: 16px;
}

.org-name {
  font-weight: 600;
  font-size: clamp(18px, 3.6vw, 32px);
  color: var(--ink-weak);
  letter-spacing: 0.1em;
  text-align: center;
  opacity: 0.9;
  transform: translateY(-8px);
  min-height: 1.5em;
  display: flex;
  align-items: center;
  justify-content: center;
}

#typewriter-text {
  display: inline-block;
}

.cursor {
  display: inline-block;
  animation: cursorBlink 1s infinite;
  margin-left: 2px;
  color: var(--ink);
}

@keyframes cursorBlink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* LOGO容器和长按效果 */
.logo-container {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.logo {
  max-width: min(35vw, 450px);
  width: clamp(220px, 30vw, 450px);
  height: auto;
  filter: drop-shadow(0 12px 28px rgba(0,0,0,0.15));
  transform: translateZ(0);
  cursor: pointer;
  user-select: none;
  transition: all 300ms var(--ease-smooth);
}

.logo:hover {
  transform: scale(1.02);
  filter: drop-shadow(0 16px 32px rgba(0,0,0,0.2));
}

/* 长按进度条 */
.press-progress-container {
  opacity: 0;
  transform: translateY(10px);
  transition: all 200ms var(--ease-smooth);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 10;
  position: relative;
}

.press-progress-container.show {
  opacity: 1;
  transform: translateY(0);
}

.press-progress-bar {
  width: 250px;
  height: 16px;
  background: rgba(0, 0, 0, 0.2);
  border: 3px solid rgba(0, 0, 0, 0.5);
  border-radius: 0;
  overflow: hidden;
  position: relative;
  box-shadow: 
    inset 0 0 0 1px rgba(255, 255, 255, 0.3),
    0 4px 8px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.1);
}

.press-progress-fill {
  height: 100%;
  width: 0%;
  background: 
    repeating-linear-gradient(
      90deg,
      #ff2d55 0px,
      #ff2d55 6px,
      #ff4757 6px,
      #ff4757 12px
    );
  transition: width 100ms linear;
  position: relative;
  box-shadow: 
    0 0 10px rgba(255, 45, 85, 0.4),
    inset 0 0 10px rgba(255, 255, 255, 0.2);
}

.press-progress-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: repeating-linear-gradient(
    90deg,
    transparent 0px,
    rgba(255, 255, 255, 0.3) 2px,
    transparent 4px
  );
  animation: pixelShift 0.3s linear infinite;
}

@keyframes pixelShift {
  0% { transform: translateX(0); }
  100% { transform: translateX(8px); }
}

.press-hint {
  font-size: 12px;
  color: var(--ink-weak);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.center-title {
  font-weight: 900;
  font-size: clamp(28px, 6vw, 64px);
  letter-spacing: 0.02em;
  transition: transform 420ms var(--ease-smooth), opacity 420ms var(--ease-smooth);
  will-change: transform, opacity;
  cursor: pointer;
  user-select: none;
}

.center-title:hover {
  transform: scale(1.05);
  opacity: 0.8;
}

.center-title.jumping {
  transition: transform 140ms cubic-bezier(0.26, 0.02, 0.37, 0.99);
}

/* 进入主页面时的淡入 */
.stage--main.show {
  opacity: 1;
}

/* 初始隐藏 */
#transition[aria-hidden="true"], #main[aria-hidden="true"] {
  opacity: 0;
}

/* 协会介绍界面 */
.stage--intro {
  background: var(--bg-0);
  position: relative;
}

/* 保留过渡背景（三行滚动） */
.intro-background {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: 1fr 1fr 1fr;
  gap: 0;
  z-index: 0;
  opacity: 0.3;
}

.intro-background .row {
  position: relative;
  overflow: hidden;
}

.bg-ticker {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%) translateX(-100%);
  white-space: nowrap;
  will-change: transform;
  font-size: clamp(36px, 16vw, 140px);
  font-weight: 900;
  color: var(--ink);
  animation: bgTickerRun 8s linear infinite;
}

@keyframes bgTickerRun {
  from { transform: translateY(-50%) translateX(-100%); }
  to { transform: translateY(-50%) translateX(110%); }
}

/* 左上方竖幅菜单栏 */
.vertical-menu {
  position: fixed;
  left: 20px;
  top: 20px;
  width: 200px;
  height: calc(100vh - 40px);
  background: linear-gradient(135deg, var(--glass), var(--glass-2));
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  z-index: 10;
  transform: translateY(-100%);
  transition: transform 800ms var(--ease-smooth);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.stage--intro.show .vertical-menu {
  transform: translateY(0);
}

.menu-header {
  padding: 20px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.menu-title {
  font-size: clamp(18px, 3.2vw, 22px);
  font-weight: 900;
  color: var(--ink);
  flex: 1;
  text-align: center;
}

.back-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, rgba(255, 122, 122, 0.15), rgba(122, 168, 255, 0.15));
  border: 1px solid rgba(255, 122, 122, 0.3);
  border-radius: 50%;
  color: var(--ink);
  cursor: pointer;
  transition: all 300ms var(--ease-smooth);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.back-btn:hover {
  background: linear-gradient(135deg, rgba(255, 122, 122, 0.25), rgba(122, 168, 255, 0.25));
  border-color: rgba(255, 122, 122, 0.5);
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(255, 122, 122, 0.3);
}

.back-btn:active {
  transform: scale(0.95);
}

.back-btn svg {
  width: 18px;
  height: 18px;
  transition: transform 300ms var(--ease-smooth);
}

.back-btn:hover svg {
  transform: translateX(-1px);
}

.menu-nav {
  flex: 1;
  padding: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.menu-item {
  display: block;
  width: 100%;
  padding: 14px 20px;
  text-align: left;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink-weak);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 300ms var(--ease-smooth);
  position: relative;
  border-radius: 8px;
  margin: 0 8px;
}

.menu-item:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--ink);
  transform: translateX(4px);
}

.menu-item.active {
  background: linear-gradient(135deg, rgba(255, 122, 122, 0.2), rgba(122, 168, 255, 0.2));
  color: var(--ink);
  box-shadow: 0 4px 12px rgba(255, 122, 122, 0.3);
}

.menu-item.active::before {
  content: '';
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 60%;
  background: linear-gradient(to bottom, #ff7a7a, #7aa8ff);
  border-radius: 2px;
}

/* 从菜单中间向右拉出的内容区域 */
.content-panel {
  position: fixed;
  left: 240px;
  top: 20px;
  right: 20px;
  height: calc(100vh - 40px);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  z-index: 8;
  overflow: hidden;
  transform: translateX(100%);
  transition: transform 900ms var(--ease-smooth) 400ms;
}

.stage--intro.show .content-panel {
  transform: translateX(0);
}

.content-panel.content-loaded {
  overflow-y: auto;
}

/* 终端加载界面 */
.terminal-loader {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow: hidden;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  z-index: 10;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.terminal-header {
  display: none;
}

.terminal-controls {
  display: none;
}

.control {
  display: none;
}

.terminal-title {
  display: none;
}

.terminal-body {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: transparent;
}

.terminal-content {
  max-width: 800px;
  width: 90%;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.6;
  text-align: center;
}

.ascii-art {
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: clamp(8px, 1.2vw, 12px);
  line-height: 1;
  white-space: pre;
  color: #007acc;
  margin-bottom: 30px;
  text-shadow: 0 2px 8px rgba(0, 122, 204, 0.3);
  font-weight: bold;
}

.loading-messages {
  margin-bottom: 30px;
  text-align: left;
  max-width: 600px;
}

.loading-message {
  color: var(--ink);
  margin-bottom: 12px;
  opacity: 0;
  animation: fadeInMessage 0.4s forwards;
  font-size: 15px;
  font-weight: 500;
}

/* 首页海报弹窗 */
.poster-modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center; /* 居中显示 */
  background: rgba(0, 0, 0, 0.6);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms var(--ease-smooth);
}

.poster-modal[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}

.poster-modal .modal-inner {
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  max-width: min(88vw, 1100px);
  max-height: min(88vh, 1100px);
  transform: translateY(-8vh) scale(0.97); /* 居中并上调一些 */
  transition: transform 220ms var(--ease-smooth);
  will-change: transform;
}

.poster-modal .poster-image {
  display: block;
  width: auto;
  height: auto;
  max-width: min(85vw, 1000px);
  max-height: min(85vh, 1000px);
  object-fit: contain;
  border-radius: 0;
}

.poster-modal[aria-hidden="false"] .modal-inner {
  transform: translateY(-8vh) scale(1);
}

.loading-message.error {
  color: #dc3545;
}

.loading-message.warning {
  color: #fd7e14;
}

.loading-message.success {
  color: #198754;
}

@keyframes fadeInMessage {
  from { opacity: 0; transform: translateX(-10px); }
  to { opacity: 1; transform: translateX(0); }
}

.progress-container {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 30px;
  max-width: 500px;
}

.progress-label {
  color: var(--ink);
  font-weight: 600;
  min-width: 90px;
  font-size: 15px;
}

.progress-bar {
  flex: 1;
  height: 24px;
  background: rgba(0, 0, 0, 0.1);
  border: 2px solid rgba(0, 122, 204, 0.3);
  border-radius: 12px;
  overflow: hidden;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #007acc, #0099ff);
  width: 0%;
  transition: width 0.3s ease;
  position: relative;
  border-radius: 10px;
}

.progress-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
  animation: progressShine 2s infinite;
}

@keyframes progressShine {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.progress-text {
  color: var(--ink);
  font-weight: 600;
  min-width: 50px;
  text-align: right;
  font-size: 15px;
}

.cursor {
  color: #007acc;
  animation: cursorBlink 1s infinite;
  font-weight: bold;
}

@keyframes cursorBlink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* 添加一些技术感的视觉效果 */
.terminal-loader::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 30%, rgba(0, 122, 204, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(0, 153, 255, 0.08) 0%, transparent 50%),
    linear-gradient(135deg, rgba(0, 122, 204, 0.05) 0%, transparent 50%);
  pointer-events: none;
  z-index: -1;
}

.loading-message::before {
  content: '▶ ';
  color: #007acc;
  font-weight: bold;
  margin-right: 4px;
}

.loading-message.success::before {
  content: '✓ ';
  color: #198754;
}

.loading-message.error::before {
  content: '✗ ';
  color: #dc3545;
}

.loading-message.warning::before {
  content: '⚠ ';
  color: #fd7e14;
}

.content-section {
  padding: 32px 40px;
  max-width: 1000px;
  margin: 0 auto;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms var(--ease-smooth), transform 600ms var(--ease-smooth);
}

.content-section.show {
  opacity: 1;
  transform: translateY(0);
}

.content-section h2 {
  font-size: clamp(28px, 5vw, 36px);
  font-weight: 900;
  color: var(--ink);
  margin-bottom: 24px;
  border-bottom: 3px solid #ff7a7a;
  padding-bottom: 12px;
  position: relative;
}

.content-section h2::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, #7aa8ff, #7affd4);
}

.content-section h3 {
  font-size: clamp(20px, 4vw, 24px);
  font-weight: 700;
  color: var(--ink);
  margin: 28px 0 16px;
}

.content-section p {
  font-size: 16px;
  line-height: 1.8;
  color: var(--ink-weak);
  margin-bottom: 20px;
}

.research-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.research-item {
  padding: 24px;
  background: var(--glass);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 300ms var(--ease-smooth);
  position: relative;
  overflow: hidden;
}

.research-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ff7a7a, #7aa8ff, #7affd4);
  opacity: 0;
  transition: opacity 300ms var(--ease-smooth);
}

.research-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.research-item:hover::before {
  opacity: 1;
}

.research-item h3 {
  margin: 0 0 12px;
  font-size: 18px;
  color: var(--ink);
}

.research-item p {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
}

.member-group {
  margin-bottom: 32px;
}

.expand-btn {
  background: linear-gradient(135deg, #ff7a7a, #7aa8ff);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 300ms var(--ease-smooth);
  margin-left: 16px;
  box-shadow: 0 4px 12px rgba(255, 122, 122, 0.3);
}

.expand-btn:hover {
  transform: scale(1.05) translateY(-1px);
  box-shadow: 0 6px 16px rgba(255, 122, 122, 0.4);
}

.member-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 16px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.member-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--glass);
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 300ms var(--ease-smooth);
}

.member-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.member-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff7a7a, #7aa8ff);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 12px;
  text-align: center;
  line-height: 1;
  box-shadow: 0 4px 12px rgba(255, 122, 122, 0.3);
}

.member-info {
  flex: 1;
}

.member-name {
  display: block;
  font-weight: 600;
  color: var(--ink);
  font-size: 15px;
}

.member-year {
  display: block;
  font-size: 12px;
  color: var(--ink-weak);
  margin-top: 2px;
}

.member-desc {
  display: block;
  font-size: 12px;
  color: var(--ink-weak);
  font-style: italic;
  margin-top: 4px;
}

.department-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.department-item {
  padding: 24px;
  background: var(--glass);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 300ms var(--ease-smooth);
  position: relative;
  overflow: hidden;
}

.department-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #7aa8ff, #7affd4, #ffb36b);
  opacity: 0;
  transition: opacity 300ms var(--ease-smooth);
}

.department-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.department-item:hover::before {
  opacity: 1;
}

.department-item h4 {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 700;
  color: var(--ink);
}

.department-item p {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
}

/* 页面震动和崩坏效果 */
@keyframes pageShake {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  10% { transform: translate(-1px, -1px) rotate(-0.5deg); }
  20% { transform: translate(1px, -1px) rotate(0.5deg); }
  30% { transform: translate(-1px, 1px) rotate(-0.5deg); }
  40% { transform: translate(1px, 1px) rotate(0.5deg); }
  50% { transform: translate(-1px, -1px) rotate(-0.5deg); }
  60% { transform: translate(1px, -1px) rotate(0.5deg); }
  70% { transform: translate(-1px, 1px) rotate(-0.5deg); }
  80% { transform: translate(1px, 1px) rotate(0.5deg); }
  90% { transform: translate(-1px, -1px) rotate(-0.5deg); }
}

@keyframes pageShakeIntense {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  10% { transform: translate(-3px, -2px) rotate(-1deg); }
  20% { transform: translate(3px, -3px) rotate(1deg); }
  30% { transform: translate(-2px, 3px) rotate(-1deg); }
  40% { transform: translate(2px, 2px) rotate(1deg); }
  50% { transform: translate(-3px, -3px) rotate(-1deg); }
  60% { transform: translate(3px, -2px) rotate(1deg); }
  70% { transform: translate(-2px, 3px) rotate(-1deg); }
  80% { transform: translate(2px, 3px) rotate(1deg); }
  90% { transform: translate(-3px, -2px) rotate(-1deg); }
}

@keyframes pageGlitch {
  0%, 100% { transform: translate(0, 0) rotate(0deg) scale(1); }
  20% { transform: translate(-5px, -3px) rotate(-2deg) scale(1.01); }
  40% { transform: translate(5px, -5px) rotate(2deg) scale(0.99); }
  60% { transform: translate(-3px, 5px) rotate(-1deg) scale(1.02); }
  80% { transform: translate(3px, 3px) rotate(1deg) scale(0.98); }
}

.stage--main.shake-light {
  animation: pageShake 0.1s infinite;
}

.stage--main.shake-medium {
  animation: pageShakeIntense 0.08s infinite;
}

.stage--main.shake-heavy {
  animation: pageGlitch 0.06s infinite;
}

/* 黑色正方形崩坏效果 */
.glitch-square {
  position: fixed;
  background: #000;
  z-index: 1000;
  animation: glitchSquareAppear 0.3s ease-out;
}

@keyframes glitchSquareAppear {
  0% {
    opacity: 0;
    transform: scale(0) rotate(45deg);
  }
  50% {
    opacity: 1;
    transform: scale(1.2) rotate(0deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

/* 隐藏彩蛋界面 */
.stage--secret {
  background: #000;
  z-index: 9999;
}

.glitch-overlay {
  position: absolute;
  inset: 0;
  background: #000;
  opacity: 0;
  transition: opacity 800ms ease-out;
}

.glitch-overlay.show {
  opacity: 1;
}

/* 三连空格彩蛋：闪屏与黑场 */
.flash-layer {
  position: absolute;
  inset: 0;
  background: #fff;
  opacity: 0;
  pointer-events: none;
}

.flash-layer.run {
  animation: screenFlash 650ms ease-out forwards;
}

@keyframes screenFlash {
  0% { opacity: 0; background: #fff; }
  10% { opacity: 1; }
  20% { opacity: 0; }
  35% { opacity: 1; }
  50% { opacity: 0; }
  65% { opacity: 1; }
  80% { opacity: 0.6; }
  100% { opacity: 0; background: #000; }
}

/* 三连空格彩蛋：上下滚动大字区域 */
.secret-scroll-zone {
  position: absolute;
  left: 0;
  right: 0;
  height: 20vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.secret-scroll-zone.top { top: 0; }
.secret-scroll-zone.bottom { bottom: 0; }

.secret-scroll-zone .row { width: 100%; }
.secret-scroll-zone .ticker {
  white-space: nowrap;
  font-weight: 900; /* 黑体粗重感 */
  font-size: clamp(42px, 8vw, 112px);
  color: #0d47a1; /* 深蓝 */
}
.secret-scroll-zone .bg-ticker span {
  color: #0d47a1; /* 深蓝 */
  text-shadow: 0 0 10px rgba(13,71,161,0.18);
}

/* 复用 intro 背景滚动动画 */
.secret-scroll-zone .bg-ticker { animation: bgTickerRun 8s linear infinite; }

/* 中部蓝色条带与挖空字样 */
.blue-band {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(85vw, 1400px);
  height: clamp(140px, 22vh, 220px);
  background: linear-gradient(180deg, #0d47a1, #0b3d91);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(30,124,242,0.35), inset 0 -8px 24px rgba(0,0,0,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
}

.blue-band .cutout-text {
  font-weight: 900;
  font-size: clamp(72px, 14vw, 200px);
  letter-spacing: 0.06em;
  /* 视觉“镂空”：使用黑色模拟孔洞（背景为黑场） */
  color: #000;
  text-transform: uppercase;
  filter: drop-shadow(0 2px 0 rgba(255,255,255,0.22));
}

/* 用彩色字母填充镂空处 */
.blue-band .fill-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  font-weight: 900;
  font-size: clamp(72px, 14vw, 200px);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.blue-band .fill-text .ch {
  display: inline-block;
  margin: 0 0.02em;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.35));
}

/* 下方输入提示（打字光标） */
.type-prompt {
  position: absolute;
  left: 50%;
  bottom: 4vh;
  transform: translateX(-50%);
  color: #fff;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: clamp(18px, 2.8vw, 28px);
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.type-prompt .hint { color: #8fb9ff; }
.type-prompt .typed { color: #fff; font-weight: 700; }
.type-prompt .cursor { margin-left: 2px; animation: secretCursorBlink 1s infinite; }

/* 每次按键爆炸的像素粒子 */
.particle-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.pixel {
  position: absolute;
  width: 7px;
  height: 7px;
  background: #cde0ff;
  image-rendering: pixelated;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.1);
  opacity: 1;
  transition: transform 860ms cubic-bezier(0.2, 0.8, 0.2, 1), opacity 860ms linear;
}

/* 震动效果（通用类） */
.shake-impact {
  animation: pageGlitch 120ms ease-out;
}

/* 完成输入后的黑屏与字幕淡入淡出 */
.witness-overlay {
  position: absolute;
  inset: 0;
  background: #000;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}
.witness-text {
  color: #fff;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-weight: 700;
  letter-spacing: 2px;
  font-size: clamp(28px, 7vw, 80px);
  opacity: 0;
  transition: opacity 800ms var(--ease-smooth);
}

/* 见证后小球交互阶段 */
.circle-stage {
  position: absolute;
  inset: 0;
  background: #000;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.white-expander {
  position: absolute;
  inset: 0;
  background: #fff;
  clip-path: circle(0px at 50% 50%);
  transition: clip-path 160ms cubic-bezier(0.2, 0.8, 0.2, 1);
  z-index: 1;
}
.circle-frame {
  position: relative;
  z-index: 2;
  width: clamp(220px, 36vw, 420px);
  height: clamp(220px, 36vw, 420px);
  border: 6px solid #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 28px rgba(255,255,255,0.18), inset 0 0 0 0 rgba(0,0,0,0);
  overflow: hidden;
}
.ball3d {
  position: absolute;
  width: 36%;
  height: 36%;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #ffffff 0%, #eaf0ff 30%, #c6d2ff 55%, #8fa3ff 75%, #3b55a9 100%);
  box-shadow: 0 8px 28px rgba(255,255,255,0.35), inset 0 -8px 22px rgba(0,0,0,0.35);
  transform: scale(1);
  transition: transform 120ms var(--ease-smooth);
}
.hubusec-splash {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-weight: 900;
  letter-spacing: 2px;
  font-size: clamp(36px, 10vw, 150px);
  opacity: 0;
  transition: opacity 700ms var(--ease-smooth);
  z-index: 3;
}
.hubusec-splash.show { opacity: 1; }

/* 移动端控制按钮 */
.circle-controls {
  position: absolute;
  z-index: 4;
  bottom: 6vh;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 18px;
}
.circle-controls .ctrl-btn {
  min-width: clamp(80px, 22vw, 140px);
  padding: 14px 18px;
  border-radius: 14px;
  border: 2px solid rgba(255,255,255,0.7);
  background: rgba(255,255,255,0.12);
  color: #fff;
  font-weight: 700;
  letter-spacing: 1px;
  text-align: center;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.3), inset 0 0 0 0 rgba(255,255,255,0.2);
  cursor: pointer;
  user-select: none;
  touch-action: none;
  transition: transform 120ms var(--ease-smooth), background 160ms var(--ease-smooth);
}
.circle-controls .ctrl-btn:active { transform: scale(0.96); background: rgba(255,255,255,0.18); }

/* 小球阶段成员名字叠层 */
.name-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.name-overlay-dark { z-index: 0; color: #fff; }
.name-overlay-light { z-index: 2; color: #000; }
.name-label {
  position: absolute;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 600ms var(--ease-smooth);
  font-weight: 600;
  letter-spacing: 0.5px;
  font-size: clamp(12px, 2.2vh, 22px);
  text-shadow: 0 1px 2px rgba(0,0,0,0.35);
}

.secret-content {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
}

.secret-message {
  color: #fff;
  font-size: clamp(24px, 4vw, 48px);
  font-weight: 300;
  letter-spacing: 2px;
  text-align: center;
}

.secret-cursor {
  color: #fff;
  font-size: clamp(24px, 4vw, 48px);
  margin-left: 4px;
  animation: secretCursorBlink 1s infinite;
}

@keyframes secretCursorBlink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* CTF彩蛋专用动画 */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
  20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/* CTF终端样式 */
.ctf-terminal-container {
  scrollbar-width: thin;
  scrollbar-color: #fff #000;
}

.ctf-terminal-container::-webkit-scrollbar {
  width: 8px;
}

.ctf-terminal-container::-webkit-scrollbar-track {
  background: #000;
}

.ctf-terminal-container::-webkit-scrollbar-thumb {
  background: #fff;
  border-radius: 4px;
}

.ctf-terminal-container::-webkit-scrollbar-thumb:hover {
  background: #ccc;
}

/* 移动端适配 */
@media (max-width: 768px) {
  /* 主页面移动端适配 */
  .stage--main {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr auto;
    padding: 10px;
  }
  
  .side {
    display: none;
  }
  
  .center {
    padding: 20px 10px;
  }
  
  .logo {
    max-width: min(70vw, 300px);
    width: clamp(180px, 60vw, 300px);
  }
  
  .press-progress-bar {
    width: 200px;
  }
  
  .center-title {
    font-size: clamp(24px, 8vw, 48px);
  }
  
  .org-name {
    font-size: clamp(16px, 4vw, 24px);
  }
  
  /* 协会介绍页面移动端适配 */
  .vertical-menu {
    position: fixed;
    left: 10px;
    top: 10px;
    right: 10px;
    width: auto;
    height: auto;
    max-height: 200px;
    flex-direction: row;
    overflow-x: auto;
    z-index: 20;
  }
  
  .menu-header {
    min-width: 150px;
    flex-shrink: 0;
  }
  
  .menu-nav {
    flex-direction: row;
    padding: 16px;
    gap: 10px;
    overflow-x: auto;
  }
  
  .menu-item {
    white-space: nowrap;
    margin: 0 5px;
    min-width: 100px;
    text-align: center;
  }
  
  .content-panel {
    left: 10px;
    top: 220px;
    right: 10px;
    height: calc(100vh - 230px);
  }
  
  .terminal-loader {
    padding: 10px;
  }
  
  .ascii-art {
    font-size: 8px;
    line-height: 0.9;
    overflow-x: auto;
    white-space: pre;
  }
  
  .content-section {
    padding: 20px 16px;
  }
  
  .research-grid {
    grid-template-columns: 1fr;
  }
  
  .department-grid {
    grid-template-columns: 1fr;
  }
  
  .member-list {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
  }
  
  /* CTF彩蛋移动端适配 */
  .ctf-easter-egg-container {
    padding: 20px 15px !important;
  }
  
  .ctf-type-container {
    font-size: 18px !important;
    line-height: 1.4 !important;
  }
  
  .ctf-type-container div {
    font-size: 20px !important;
    margin-bottom: 15px !important;
  }
  
  .ctf-type-container div:first-child {
    font-size: 24px !important;
  }
  
  /* Flag输入移动端适配 */
  .ctf-easter-egg-container input[type="text"] {
    width: 90% !important;
    max-width: 300px !important;
    font-size: 16px !important;
    padding: 10px 15px !important;
  }
  
  .ctf-easter-egg-container button {
    padding: 10px 25px !important;
    font-size: 16px !important;
  }
  
  /* 故事文本移动端适配 */
  .ctf-easter-egg-container > div > div {
    font-size: 24px !important;
    margin: 15px 0 !important;
  }
  
  /* CTF终端移动端适配 */
  .ctf-terminal-container {
    padding: 15px !important;
    font-size: 12px !important;
  }
  
  .ctf-terminal-container .ascii-art {
    font-size: 6px !important;
    line-height: 0.8 !important;
    margin-bottom: 15px !important;
    overflow-x: auto !important;
    white-space: pre !important;
  }
  
  .terminal-output {
    font-size: 12px !important;
    line-height: 1.3 !important;
  }
  
  .ctf-terminal-container input {
    font-size: 12px !important;
  }
  
  .ctf-terminal-container span {
    font-size: 12px !important;
  }
  
  /* 最终故事移动端适配 */
  .ctf-easter-egg-container a {
    font-size: 18px !important;
    word-break: break-all !important;
  }
  
  .ctf-easter-egg-container button:last-child {
    padding: 12px 25px !important;
    font-size: 16px !important;
  }
}

@media (max-width: 480px) {
  /* 超小屏幕适配 */
  .ctf-terminal-container .ascii-art {
    font-size: 5px !important;
    line-height: 0.7 !important;
  }
  
  .ctf-terminal-container {
    font-size: 11px !important;
  }
  
  .ctf-easter-egg-container input[type="text"] {
    width: 95% !important;
    font-size: 14px !important;
  }
  
  .vertical-menu {
    max-height: 150px;
  }
  
  .content-panel {
    top: 170px;
    height: calc(100vh - 180px);
  }
}

/* 无障碍：减少动画偏好时降级 */
@media (prefers-reduced-motion: reduce) {
  .silk-line { animation: none; }
  .silk-group--left, .silk-group--right { animation-duration: 0.01ms; }
  .loader-fore-title { animation: none; }
  .stage--transition .ticker { animation-duration: 0.01ms !important; }
  .side .column { animation-duration: 0.01ms; }
  .bg-ticker { animation: none; }
  .press-progress-fill::after { animation: none; }
  .stage--main.shake-light,
  .stage--main.shake-medium,
  .stage--main.shake-heavy {
    animation: none;
  }
}


