/* ==================== 全屏欢迎页面 ==================== */

#welcome-page {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  background-image: url('https://images.unsplash.com/photo-1519681393784-d120267933ba?w=1920&q=80');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  overflow: hidden;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.8s ease;
}

#welcome-page.hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

/* 遮罩层 */
#welcome-page::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.7), rgba(118, 75, 162, 0.7));
  z-index: 1;
}

/* 内容容器 */
.welcome-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: white;
  padding: 40px;
  animation: fadeInUp 1s ease-out;
}

/* 头像/Logo */
.welcome-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  margin: 0 auto 30px;
  animation: float 3s ease-in-out infinite;
  background: white;
  object-fit: cover;
}

/* 标题 */
.welcome-title {
  font-size: 48px;
  font-weight: 700;
  margin-bottom: 15px;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  letter-spacing: 2px;
  animation: fadeInUp 1s ease-out 0.2s backwards;
}

/* 副标题 */
.welcome-subtitle {
  font-size: 20px;
  margin-bottom: 40px;
  opacity: 0.9;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  animation: fadeInUp 1s ease-out 0.4s backwards;
}

/* 滚动提示 */
.scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  color: white;
  font-size: 14px;
  opacity: 0.8;
  animation: fadeInUp 1s ease-out 0.6s backwards, bounce 2s ease-in-out infinite;
  z-index: 2;
  cursor: pointer;
}

.scroll-hint-text {
  margin-bottom: 10px;
  font-weight: 500;
  letter-spacing: 1px;
}

.scroll-arrow {
  width: 30px;
  height: 30px;
  border: 2px solid white;
  border-radius: 50%;
  position: relative;
}

.scroll-arrow::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(45deg);
  width: 10px;
  height: 10px;
  border-bottom: 2px solid white;
  border-right: 2px solid white;
  margin-top: -3px;
}

/* 装饰元素 */
.welcome-decoration {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  overflow: hidden;
  z-index: 1;
}

.welcome-circle {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  animation: floatCircle 20s infinite;
}

.welcome-circle:nth-child(1) {
  width: 80px;
  height: 80px;
  top: 20%;
  left: 10%;
  animation-delay: 0s;
}

.welcome-circle:nth-child(2) {
  width: 120px;
  height: 120px;
  top: 60%;
  right: 15%;
  animation-delay: 2s;
}

.welcome-circle:nth-child(3) {
  width: 60px;
  height: 60px;
  bottom: 20%;
  left: 20%;
  animation-delay: 4s;
}

.welcome-circle:nth-child(4) {
  width: 100px;
  height: 100px;
  top: 30%;
  right: 25%;
  animation-delay: 1s;
}

/* 动画定义 */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  40% {
    transform: translateX(-50%) translateY(-10px);
  }
  60% {
    transform: translateX(-50%) translateY(-5px);
  }
}

@keyframes floatCircle {
  0%, 100% {
    transform: translateY(0px) translateX(0px);
  }
  25% {
    transform: translateY(-30px) translateX(30px);
  }
  50% {
    transform: translateY(-60px) translateX(0px);
  }
  75% {
    transform: translateY(-30px) translateX(-30px);
  }
}

/* 粒子效果 */
.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: white;
  border-radius: 50%;
  opacity: 0.6;
  animation: particleFloat 10s infinite;
}

@keyframes particleFloat {
  0% {
    transform: translateY(100vh) translateX(0);
    opacity: 0;
  }
  10% {
    opacity: 0.6;
  }
  90% {
    opacity: 0.6;
  }
  100% {
    transform: translateY(-100px) translateX(100px);
    opacity: 0;
  }
}

/* 响应式设计 */
@media screen and (max-width: 768px) {
  .welcome-title {
    font-size: 32px;
  }
  
  .welcome-subtitle {
    font-size: 16px;
  }
  
  .welcome-avatar {
    width: 90px;
    height: 90px;
  }
  
  .welcome-content {
    padding: 20px;
  }
  
  .scroll-hint {
    bottom: 30px;
  }
}

/* 深色模式适配 */
[data-theme='dark'] #welcome-page {
  background-image: url('https://images.unsplash.com/photo-1519681393784-d120267933ba?w=1920&q=80');
}

[data-theme='dark'] #welcome-page::before {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.8), rgba(118, 75, 162, 0.8));
}

/* 进入提示按钮 */
.enter-button {
  display: inline-block;
  padding: 15px 40px;
  margin-top: 30px;
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid white;
  border-radius: 50px;
  color: white;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  animation: fadeInUp 1s ease-out 0.8s backwards;
}

.enter-button:hover {
  background: white;
  color: #667eea;
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(255, 255, 255, 0.3);
}

/* Loading 动画 */
.welcome-loading {
  width: 50px;
  height: 50px;
  margin: 20px auto;
  position: relative;
}

.welcome-loading::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
