body {
  margin: 0;
  font-family: Menlo, monospace;
  background: #e6e6fa;
  color: #fff;
}
.link-marquee, .link-track, .link-track a, .media-row, .video-item, .side-content-container, .exit-btn, .side-content-container * {
  font-family: Menlo, monospace !important;
}
.link-marquee {
  position: fixed !important;
  top: 0;
  left: 0;
  width: 100vw;
  z-index: 9999 !important;
  pointer-events: auto !important;
  overflow: hidden;
}
.link-track {
  display: inline-block;
  white-space: nowrap;
  animation: marquee 30s linear infinite !important;
  background: transparent;
  pointer-events: auto;
  will-change: transform;
}
.link-track a {
  color: #d48fff;
  text-decoration: none;
  font-size: 1.4rem;
  margin: 0 1.5rem;
  letter-spacing: 1px;
  font-weight: bold;
  transition: color 1.2s ease, transform 0.3s ease;
  text-shadow: 0 2px 8px rgba(0,0,0,0.25);
}
.link-track a:hover {
  background: linear-gradient(45deg, #FF00FF, #00FFFF, #FFFF00, #FF0080);
  background-size: 400% 400%;
  animation: y2kGradient 2s ease infinite;
  text-shadow: 0 0 10px currentColor, 0 0 20px currentColor;
  transform: scale(1.1);
  transition: all 0.3s ease;
}
@keyframes marquee {
  0% { 
    transform: translateX(0); 
  }
  100% { 
    transform: translateX(-50%); 
  }
}
@keyframes y2kGradient {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.main-flex {
  display: flex;
  flex-direction: column;
  width: 100vw;
  height: 100vh;
  align-items: stretch;
  justify-content: flex-start;
  transition: flex-direction 0.5s, background 0.8s cubic-bezier(.4,0,.2,1);
}
.media-wrapper{
  flex:1 1 auto;
  display:flex;
  flex-direction:column;
  overflow-y:auto;
  scroll-snap-type:y mandatory;
}

/* 每行仍横向 4 列，但高固定 100vh，以满屏呈现 */
.media-row{
  flex:0 0 100vh;
  height:100vh;
  display:flex;
  align-items:stretch;
  justify-content:stretch;
  gap:0;
  scroll-snap-align:start;
  opacity:0;
  transition:opacity .6s ease;
}
.media-row.visible{opacity:1;}   /* IntersectionObserver 控制淡显 */

/* 进入 side‑mode 时，禁止背景滚动 */
.main-flex.side-mode .media-wrapper{overflow:hidden;}

/* side-mode下media-wrapper的样式调整 */
.main-flex.side-mode .media-wrapper{
  flex: 0 0 60vw;
  width: 60vw;
  height: 100vh;
  overflow: hidden;
}

.video-item {
  flex: 1 1 0;
  min-width: 0;
  min-height: 0;
  position: relative;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: Menlo, monospace;
  cursor: pointer;
  border: none;
  background: transparent;
  overflow: hidden;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  transform: scale(1);
}

.video-item:hover {
  transform: scale(1.02);
  z-index: 10;
}

.video-item:hover::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(212, 143, 255, 0.1), rgba(255, 255, 255, 0.05));
  z-index: 1;
  animation: hoverGlow 0.6s ease-out;
}

@keyframes hoverGlow {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
  100% {
    opacity: 0.3;
    transform: scale(1);
  }
}
.video-item.stack-focus {
  flex: 0 0 60vw !important;
  z-index: 2;
  transform: none;
  opacity: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: focusExpand 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  transition: none !important;
}

@keyframes focusExpand {
  0% {
    transform: none;
    opacity: 0.8;
  }
  50% {
    transform: none;
    opacity: 0.9;
  }
  100% {
    transform: none;
    opacity: 1;
  }
}

/* 点击动画类 */
.video-item.clicking {
  transform: none !important;
  transition: none !important;
}

/* 退出动画类 */
.video-item.exiting {
  transform: none !important;
  opacity: 0 !important;
  transition: none !important;
}

/* 在side-mode下禁用所有过渡效果 */
.main-flex.side-mode .video-item.clicking,
.main-flex.side-mode .video-item.exiting {
  transition: none !important;
}
.video-item.stack-move-left,
.video-item.stack-move-right {
  display: none !important;
}
.video-preview {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #d8d8f0;
  border-radius: 0;
  box-shadow: none;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), filter 0.3s ease;
  filter: brightness(1) contrast(1);
}

.video-item:hover .video-preview {
  filter: brightness(1.1) contrast(1.05);
  transform: scale(1.02);
}
.side-content-container {
  display: none;
}

/* 点击后切换为三栏布局: 左滚动文本-中视频-右滚动文本 */
.main-flex.side-mode {
  flex-direction: row;
  align-items: center;
  justify-content: center;
}
.main-flex.side-mode .media-row {
  width: 60vw;
  height: 100vh;
  align-items: center;
  justify-content: center;
  background: transparent;
}
.main-flex.side-mode .video-item {
  flex: 0 0 100vw;
  width: 100vw;
  height: 100vh;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: none !important;
  background: none;
}
.main-flex.side-mode .video-item .footer {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: #d48fff;
  font-size: 1.3rem;
  font-weight: bold;
  letter-spacing: 2px;
  text-align: center;
  z-index: 10;
  display: block;
}
.main-flex.side-mode .video-preview {
  max-width: 92vw;
  max-height: 92vh;
  width: auto;
  height: auto;
  object-fit: contain;
  margin: 0 auto;
  display: block;
  transition: none !important;
  box-shadow: none;
  border-radius: 0.7em;
  background: #222;
}
.main-flex.side-mode .side-content-container {
  display: flex !important;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  width: 20vw;
  min-width: 120px;
  max-width: 350px;
  height: 100vh;
  background: transparent;
  border: none;
  padding: 0;
  font-size: 1.2rem;
  color: #fff;
  box-shadow: none;
  line-height: 1.7;
  z-index: 1;
  text-align: left;
  position: relative;
  overflow: hidden;
}
.main-flex.side-mode .side-content-container.left,
.main-flex.side-mode .side-content-container.right {
  background: none !important;
  pointer-events: auto !important;
}
.main-flex.side-mode .side-content-container .scroll-list-inner {
  padding-top: 48px;
  display: flex;
  flex-direction: column;
  animation: none;
  overflow: hidden;
  pointer-events: auto;
}
.main-flex.side-mode .side-content-container .scroll-list-line {
  height: 1.5em;
  line-height: 1.5em;
  white-space: nowrap;
  font-size: 1.1em;
  font-family: Menlo, monospace;
  opacity: 1 !important;
  transform: none;
  pointer-events: auto;
  color: #fff !important;
}
/* 移除逐行出现的动画延迟 */
/* 移除line-symmetry动画 */
.main-flex.side-mode .side-content-container .footer {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  color: #d48fff;
  font-size: 1.3rem;
  font-weight: bold;
  letter-spacing: 2px;
  text-align: left;
  display: none;
}
.exit-btn {
  position: fixed;
  top: 1.2rem;
  right: 1.2rem;
  background: none;
  color: #222;
  font-size: 1.1rem;
  border: none;
  box-shadow: none;
  cursor: pointer;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s, transform 0.3s ease;
  padding: 0.3em 1.1em;
  border-radius: 0.5em;
  opacity: 0.85;
  font-family: Menlo, monospace;
  font-weight: 500;
  background: rgba(255,255,255,0.12);
}
.exit-btn.show {
  display: flex !important;
}
.exit-btn:hover {
  color: #d48fff;
  background: #fff;
  transform: scale(1.08);
  box-shadow: none;
}

/* 视频详情页社交链接绝对定位到顶部 */
.main-flex.side-mode .link-marquee {
  position: fixed !important;
  top: 0;
  left: 0;
  width: 100vw;
  z-index: 9999 !important;
  pointer-events: auto !important;
  overflow: hidden;
}

/* 第五行文本在视频中间偏下位置, 样式突出 */
.main-flex.side-mode .video-item .water-text {
  position: absolute;
  left: 50%;
  top: 60%;
  transform: translate(-50%, 0);
  font-size: 1.5em;
  color: #fff;
  font-family: Menlo, monospace;
  text-shadow: 0 2px 16px #000, 0 0 2px #fff;
  pointer-events: none;
  z-index: 20;
  white-space: pre;
  opacity: 1;
  transition: opacity 0.3s;
  user-select: none;
}

.main-flex.side-mode .video-item .water-text.water-link {
  color: #8fd6ff;
  text-decoration: underline;
  font-size: 1.1em;
  cursor: pointer;
  background: rgba(0,0,0,0.25);
  border-radius: 0.5em;
  padding: 0.2em 0.7em;
  transition: background 0.2s, color 0.2s;
}
.main-flex.side-mode .video-item .water-text.water-link:hover {
  color: #fff;
  background: #23607a;
}

.main-flex.side-mode .video-item .water-text.water-box {
  background: rgba(30,30,40,0.65);
  color: #e0e0e0;
  font-size: 0.92em;
  border-radius: 0.7em;
  padding: 0.7em 1.2em;
  box-shadow: 0 4px 24px 0 #0008;
  max-width: 50vw;
  min-width: 100px;
  max-height: 18vh;
  overflow: hidden;
  word-break: break-all;
  text-align: center;
  font-family: Menlo, monospace;
  pointer-events: auto;
  opacity: 0.7;
  user-select: text;
  line-height: 1.7;
  letter-spacing: 0.01em;
  position: absolute;
  left: 50%;
  top: 80%;
  transform: translate(-50%, 0);
  transition: opacity 0.2s, background 0.2s;
}
.main-flex.side-mode .video-item .water-text.water-box:hover {
  opacity: 1;
  background: rgba(30,30,40,0.92);
}

.main-flex.side-mode .video-item .water-text.water-short {
  background: none;
  color: #fff;
  font-size: 1.1em;
  top: 65%;
  opacity: 0.95;
  box-shadow: none;
  padding: 0.2em 1em;
}

.main-flex.side-mode .video-item .water-text.water-scroll {
  max-height: 28vh;
  font-size: 0.88em;
  overflow: hidden;
}

.link-marquee .link-track {
  pointer-events: auto !important;
}

.link-marquee a {
  pointer-events: auto !important;
}

/* 确保在side-mode下链接也可以点击 */
.main-flex.side-mode .link-marquee .link-track {
  pointer-events: auto !important;
  z-index: 9999 !important;
  animation: marquee 30s linear infinite !important;
}

.main-flex.side-mode .link-marquee a {
  pointer-events: auto !important;
  z-index: 9999 !important;
}

/* 确保链接在所有情况下都可以点击 */
.link-marquee,
.link-marquee *,
.link-track,
.link-track * {
  pointer-events: auto !important;
  z-index: 9999 !important;
}

/* 强制marquee动画在所有情况下都工作 */
.link-track,
.link-marquee .link-track,
.main-flex.side-mode .link-marquee .link-track {
  animation: marquee 30s linear infinite !important;
  will-change: transform !important;
}

.video-item-empty {
  background: transparent !important;
  pointer-events: none;
}

.logo-img {
  height: 2.2rem;
  vertical-align: middle;
  margin: 0 2.2rem;
  display: inline-block;
  border-radius: 0.5rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  background: #fff;
}
.link-track .logo-img {
  position: relative;
  top: 0.2rem;
}

#loading-overlay {
  position: fixed;
  z-index: 99999;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #2A2AFF;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  width: 100vw;
  transition: opacity 0.5s;
  font-family: 'Press Start 2P', 'Menlo', monospace, sans-serif;
}
.loading-logo-y2k {
  width: 40vw;
  max-width: 600px;
  min-width: 200px;
  height: auto;
  margin-top: 0;
  image-rendering: pixelated;
  filter: drop-shadow(0 0 32px #fff8) drop-shadow(0 0 8px #00f8);
  border-radius: 0.5rem;
  background: #fff;
  box-shadow: 0 4px 32px #0008;
  animation: y2k-flicker 1.2s infinite alternate;
}
@keyframes y2k-flicker {
  0% { filter: drop-shadow(0 0 32px #fff8) drop-shadow(0 0 8px #00f8) brightness(1.1); }
  40% { filter: drop-shadow(0 0 40px #fff) drop-shadow(0 0 16px #00f) brightness(1.3); }
  60% { filter: drop-shadow(0 0 24px #fff8) drop-shadow(0 0 4px #00f8) brightness(0.9); }
  100% { filter: drop-shadow(0 0 32px #fff8) drop-shadow(0 0 8px #00f8) brightness(1.1); }
}
.y2k-loading-bar {
  width: 60vw;
  max-width: 700px;
  height: 24px;
  background: #fff;
  border-radius: 12px;
  margin: 3vh auto 0 auto;
  box-shadow: 0 2px 12px #0006;
  overflow: hidden;
  border: 4px solid #0000ff;
  position: relative;
  display: flex;
  align-items: center;
}
.y2k-bar-inner {
  width: 0%;
  height: 100%;
  background: repeating-linear-gradient(
    90deg,
    #00f 0 16px,
    #fff 16px 32px
  );
  animation: y2k-bar-move 1.2s linear infinite, y2k-bar-grow 2.5s cubic-bezier(.4,0,.2,1) forwards;
  border-radius: 8px;
  box-shadow: 0 0 8px #00f8;
}
@keyframes y2k-bar-move {
  0% { background-position-x: 0; }
  100% { background-position-x: 64px; }
}
@keyframes y2k-bar-grow {
  0% { width: 0%; }
  80% { width: 90%; }
  100% { width: 100%; }
}
.loading-text-y2k {
  font-size: 1.2rem;
  color: #fff;
  letter-spacing: 2px;
  margin-top: 2.5vh;
  text-shadow: 0 0 8px #00f, 0 0 2px #fff;
  font-family: 'Press Start 2P', 'Menlo', monospace, sans-serif;
  animation: y2k-flicker-text 1.1s infinite alternate;
}
@keyframes y2k-flicker-text {
  0% { opacity: 1; }
  40% { opacity: 0.7; }
  60% { opacity: 0.5; }
  100% { opacity: 1; }
}
#loading-overlay.hide {
  opacity: 0;
  pointer-events: none;
}
.loading-social-bar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  width: 100vw;
  z-index: 100000;
  background: transparent;
  padding-bottom: 2vh;
  pointer-events: none;
}
.loading-social-bar .link-marquee {
  position: static !important;
  width: 100vw;
  background: transparent;
  box-shadow: none;
  pointer-events: auto !important;
}
#loading-overlay .link-track {
  font-size: 1.2rem;
  filter: drop-shadow(0 0 8px #fff) drop-shadow(0 0 2px #00f8);
}

.chunslut-link {
  font-family: 'Press Start 2P', Menlo, monospace;
  font-size: 1.6rem;
  color: #fff;
  background: #2A2AFF;
  padding: 0.2em 1.2em;
  border-radius: 0.5em;
  margin: 0 2.2rem;
  letter-spacing: 2px;
  text-shadow: 0 0 12px #fff, 0 0 4px #00f;
  border: 2px solid #fff;
  transition: background 0.2s, color 0.2s;
}
.chunslut-link:hover {
  background: #fff;
  color: #2A2AFF;
  text-shadow: none;
}

#loading-overlay .loading-social-bar {
  display: flex;
  justify-content: center;
  gap: 2.2vw;
  margin-top: 2.5vh;
  margin-bottom: 0.5vh;
  font-size: 1.1rem;
  font-family: Menlo, monospace;
  color: #fff;
  opacity: 0.85;
}
#loading-overlay .loading-social-bar a {
  color: #fff;
  text-decoration: none;
  opacity: 0.7;
  transition: opacity 0.2s, color 0.2s;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 0.1em 0.7em;
  border-radius: 0.4em;
}
#loading-overlay .loading-social-bar a:hover {
  opacity: 1;
  color: #d48fff;
  background: #fff2;
}

#loading-overlay .loading-link-marquee {
  width: 100vw;
  overflow: hidden;
  margin: 2.5vh auto 0.5vh auto;
}
#loading-overlay .loading-link-track {
  display: inline-block;
  white-space: nowrap;
  animation: loading-marquee 18s linear infinite;
  font-size: 1.1rem;
  font-family: Menlo, monospace;
  opacity: 0.85;
}
#loading-overlay .loading-link-track a {
  pointer-events: auto;
  position: relative;
  z-index: 1;
}
#loading-overlay .loading-link-track {
  pointer-events: none;
}
#loading-overlay .loading-link-track a {
  pointer-events: auto;
}
@keyframes loading-marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
} 