/* 基础重置和变量定义 */
:root {
  --primary-color: #ff1493;
  --secondary-color: #ff69b4;
  --gradient-start: #ee7752;
  --gradient-mid1: #e73c7e;
  --gradient-mid2: #23a6d5;
  --gradient-end: #23d5ab;
  --text-color: #333;
  --shadow-color: rgba(255, 20, 147, 0.2);
  --glow-color: rgba(255, 20, 147, 0.5);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 基础样式 */
body {
  font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
  min-height: 100vh;
  background: linear-gradient(-45deg,
      var(--gradient-start),
      var(--gradient-mid1),
      var(--gradient-mid2),
      var(--gradient-end));
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  color: var(--text-color);
  cursor: pointer
}

/* 主容器样式 */
.container {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 30px;
  padding: 3rem;
  text-align: center;
  width: min(90%, 500px);
  position: relative;
  z-index: 2;
  backdrop-filter: blur(10px);
  transform-style: preserve-3d;
  transform: perspective(1000px);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow:
    0 10px 50px rgba(0, 0, 0, 0.1),
    0 0 20px var(--shadow-color),
    0 0 40px var(--shadow-color);
}

.container::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg,
      transparent,
      rgba(255, 255, 255, 0.1),
      transparent);
  border-radius: inherit;
  z-index: -1;
}

.container:hover {
  transform: perspective(1000px) rotateX(5deg) rotateY(5deg) translateZ(20px);
  box-shadow:
    0 15px 60px rgba(0, 0, 0, 0.2),
    0 0 30px var(--shadow-color),
    0 0 50px var(--shadow-color);
}

/* 图片样式 */
#mainImage {
  width: min(200px, 50vw);
  height: auto;
  margin-bottom: 2rem;
  animation: float 3s ease-in-out infinite;
  filter: drop-shadow(0 10px 15px var(--shadow-color));
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: center;
}

#mainImage:hover {
  transform: scale(1.1) rotate(5deg);
  filter: drop-shadow(0 15px 25px var(--glow-color));
}

/* 问题文字样式 */
#question {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: clamp(1.5rem, 4vw, 1.8rem);
  margin-bottom: 2.5rem;
  font-weight: 700;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  animation: pulse 2s ease-in-out infinite;
}

#question::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 2px;
  background: linear-gradient(90deg,
      transparent,
      var(--primary-color),
      transparent);
  animation: lineWidth 2s ease-in-out infinite;
}

/* 按钮容器样式 */
.buttons {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: center;
  margin-top: 1rem;
}

/* 按钮基础样式 */
button {
  padding: 1rem 3rem;
  border: none;
  border-radius: 50px;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  min-width: 200px;
  position: relative;
  overflow: hidden;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Yes按钮样式 */
#yes {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  color: white;
  box-shadow: 0 5px 15px var(--shadow-color);
}

#yes:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 25px var(--glow-color);
  letter-spacing: 3px;
}

/* No按钮样式 */
#no {
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-color);
  border: 2px solid #eee;
  backdrop-filter: blur(5px);
}

#no:hover {
  background: #f8f9fa;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  color: var(--primary-color);
  border-color: var(--primary-color);
}

/* 特效样式 */
.particle {
  pointer-events: none;
  z-index: 100;
}

.heart-rain {
  position: fixed;
  pointer-events: none;
  z-index: 99;
  animation: heartFall linear forwards;
  filter: drop-shadow(0 0 5px var(--glow-color));
}

.sparkle {
  position: absolute;
  pointer-events: none;
  z-index: 98;
  animation: sparkle 1.5s linear infinite;
}

/* 动画定义 */
@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-15px);
  }
}

@keyframes pulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }
}

@keyframes lineWidth {

  0%,
  100% {
    width: 50px;
    opacity: 0.5;
  }

  50% {
    width: 100px;
    opacity: 1;
  }
}

@keyframes sparkle {
  0% {
    transform: scale(0) rotate(0deg);
    opacity: 0;
  }

  50% {
    transform: scale(1) rotate(180deg);
    opacity: 1;
  }

  100% {
    transform: scale(0) rotate(360deg);
    opacity: 0;
  }
}

@keyframes heartFall {
  0% {
    transform: translateY(-10vh) rotate(0deg);
    opacity: 1;
  }

  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}

/* 成功状态样式 */
.success-content {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 1s forwards;
}

.success-content h2 {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin-bottom: 1rem;
}

.success-content p {
  color: var(--text-color);
  font-size: 1.2rem;
  line-height: 1.6;
}

/* 响应式设计 */
@media (max-width: 480px) {
  .container {
    padding: 2rem;
    margin: 1rem;
  }

  button {
    padding: 0.8rem 2rem;
    font-size: 1rem;
    min-width: 150px;
  }

  #question {
    font-size: clamp(1.2rem, 5vw, 1.8rem);
  }
}

/* 光晕效果 */
.glow-effect {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center,
      var(--glow-color) 0%,
      transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

/* 波纹效果 */
.ripple {
  position: absolute;
  border-radius: 50%;
  transform: scale(0);
  animation: ripple 0.6s linear;
  background-color: rgba(255, 255, 255, 0.7);
}

@keyframes ripple {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

