* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  overflow: hidden;
  font-family: "Microsoft JhengHei", "Segoe UI", sans-serif;
}

/* ---------- 背景：深夜藍 + 星星 + 月亮 + 海浪 ---------- */
.background {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: linear-gradient(180deg, #020314 0%, #061238 35%, #0a2350 65%, #0d3568 100%);
  overflow: hidden;
}

.stars {
  position: absolute;
  inset: 0;
}

.star {
  position: absolute;
  background: #fff;
  border-radius: 50%;
  animation: twinkle 3s ease-in-out infinite;
}

@keyframes twinkle {
  0%, 100% { opacity: 0.2; }
  50% { opacity: 1; }
}

.moon {
  position: absolute;
  top: 8%;
  right: 12%;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: #fdf6d8;
  box-shadow:
    0 0 40px 10px rgba(253, 246, 216, 0.6),
    inset -18px -8px 0 0 rgba(200, 190, 150, 0.35);
}

.waves {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 45%;
}

.wave {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 200%;
  height: 100%;
  background-repeat: repeat-x;
  background-size: 50% 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 200' preserveAspectRatio='none'%3E%3Cpath d='M0,100 C150,180 350,20 500,100 C650,180 750,60 800,100 L800,200 L0,200 Z' fill='%23FFFFFF'/%3E%3C/svg%3E");
  animation: wave-move 12s linear infinite;
}

.wave1 { opacity: 0.10; animation-duration: 16s; bottom: 0; }
.wave2 { opacity: 0.16; animation-duration: 11s; bottom: 2%; }
.wave3 { opacity: 0.24; animation-duration: 8s;  bottom: 4%; }

@keyframes wave-move {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ---------- 場景共用 ---------- */
.scene {
  position: relative;
  z-index: 1;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
  text-align: center;
}

.hidden {
  display: none;
}

h1 {
  color: #fefefe;
  font-size: clamp(1.6rem, 4.5vw, 2.6rem);
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.35);
  line-height: 1.5;
}

/* ---------- 按鈕 ---------- */
.btn-area {
  position: relative;
  width: 100%;
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.btn {
  border: none;
  border-radius: 999px;
  cursor: pointer;
  font-weight: bold;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.big-btn {
  padding: 1.2rem 2.4rem;
  font-size: 1.4rem;
  background: linear-gradient(135deg, #ff6fa5, #ffd93d);
  color: #2a1a12;
  box-shadow: 0 6px 24px rgba(255, 130, 170, 0.55);
}

.big-btn:hover {
  transform: translateY(-3px) scale(1.06);
  box-shadow: 0 8px 30px rgba(255, 130, 170, 0.75);
}

.small-btn {
  position: fixed;
  padding: 0.6rem 1.2rem;
  font-size: 0.95rem;
  background: rgba(255, 255, 255, 0.15);
  color: #eaf2ff;
  border: 1px solid rgba(255, 255, 255, 0.4);
  transition: top 0.35s ease, left 0.35s ease, transform 0.15s ease;
}

/* ---------- 慶祝畫面 ---------- */
#celebrationScene {
  overflow: hidden;
}

#fireworks {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.big-heart {
  position: relative;
  z-index: 2;
  width: 220px;
  filter: drop-shadow(0 0 30px rgba(255, 111, 165, 0.75));
  animation: heart-pop-in 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both,
             heart-beat 1.4s ease-in-out 0.6s infinite;
}

.heart-svg {
  width: 100%;
  display: block;
}

@keyframes heart-pop-in {
  0%   { transform: scale(0); opacity: 0; }
  60%  { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes heart-beat {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.08); }
}

.celebrate-text {
  position: relative;
  z-index: 2;
  color: #fff5f8;
  font-size: clamp(1.3rem, 3.5vw, 2rem);
  text-shadow: 0 0 16px rgba(255, 200, 220, 0.5);
}
