:root {
  --bg: #fff8fb;
  --bg-2: #fff1f6;
  --text-primary: #4a3f46;
  --text-secondary: #6f5f66;
  --accent: #ff7aa8;
  --accent-2: #ff9fc5;
  --accent-3: #ffd1e6;
  --card: #ffffff;
  --border: rgba(255, 122, 168, 0.25);
  --shadow: 0 30px 60px -40px rgba(255, 122, 168, 0.9);
  --glow: 0 0 60px rgba(255, 122, 168, 0.35);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  scroll-behavior: smooth;
}

body {
  background: radial-gradient(circle at 20% 10%, #fff9fc, var(--bg));
  color: var(--text-primary);
  line-height: 1.8;
  overflow-x: hidden;
}

/* ===== 梦幻背景流光 ===== */
body::before {
  content: "";
  position: fixed;
  inset: -20%;
  background:
    radial-gradient(circle at 20% 30%, rgba(255, 154, 197, 0.25), transparent 45%),
    radial-gradient(circle at 80% 70%, rgba(255, 209, 230, 0.35), transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.6), transparent 60%);
  filter: blur(40px);
  z-index: -2;
  animation: bg-flow 18s ease-in-out infinite alternate;
}

@keyframes bg-flow {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-4%, 6%) scale(1.08); }
  100% { transform: translate(4%, -6%) scale(1.04); }
}

#hearts {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: -1;
}

.cursor-heart {
  position: fixed;
  width: 14px;
  height: 14px;
  pointer-events: none;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: translate(-50%, -50%);
}

.cursor-heart.show {
  opacity: 1;
}

.cursor-heart span {
  display: block;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, #ff9fc5, #ff7aa8);
  clip-path: path("M7 12.5C4 10 1 8 1 5.5 1 3.5 2.5 2 4.5 2 5.5 2 6.5 2.5 7 3.5 7.5 2.5 8.5 2 9.5 2 11.5 2 13 3.5 13 5.5 13 8 10 10 7 12.5Z");
  filter: drop-shadow(0 0 6px rgba(255, 122, 168, 0.6));
  animation: cursor-pop 0.8s ease forwards;
}

@keyframes cursor-pop {
  0% { transform: scale(0); opacity: 1; }
  100% { transform: scale(1); opacity: 0; }
}

/* ===== 开场仪式 ===== */
.intro {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: radial-gradient(circle at center, #fff9fc, #fff1f6);
  transition: opacity 1.2s ease, transform 1.2s ease;
}

.intro.hide {
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
}

.intro-inner {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
  animation: fade-in-up 1.6s ease;
}

.intro-line {
  letter-spacing: 0.8rem;
  text-transform: uppercase;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.intro-title {
  font-size: clamp(3rem, 12vw, 9rem);
  font-weight: 600;
  letter-spacing: 1rem;
  text-indent: 1rem;
  background: linear-gradient(120deg, #ff7aa8, #ff9fc5, #ffd1e6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.intro-hint {
  color: var(--text-secondary);
  font-size: 0.95rem;
  animation: blink 2s infinite;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 1.5rem;
}

/* 原本这里有一层覆盖整个首屏的白色径向渐变，滚动时会露出一条白雾带
   和下面的粉色背景断开。首屏氛围由 body::before 的流光提供，这层去掉。 */

.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  animation: fade-in-up 1.6s ease;
}

.hero-subtitle {
  letter-spacing: 0.8rem;
  text-transform: uppercase;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.hero-title {
  font-size: clamp(3rem, 12vw, 9rem);
  font-weight: 600;
  letter-spacing: 1rem;
  text-indent: 1rem;
  background: linear-gradient(120deg, #ff7aa8, #ff9fc5, #ffd1e6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-desc {
  color: var(--text-secondary);
  font-size: clamp(1rem, 2vw, 1.2rem);
}

.hero-btn {
  margin-top: 2rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.9rem 2.8rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: linear-gradient(120deg, rgba(255, 154, 197, 0.9), rgba(255, 122, 168, 0.9));
  color: #fff;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-btn:hover {
  transform: translateY(-6px);
  box-shadow: 0 40px 70px -40px rgba(255, 122, 168, 1);
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.scroll-indicator span {
  width: 1px;
  height: 3rem;
  background: linear-gradient(to bottom, transparent, var(--accent));
  position: relative;
  overflow: hidden;
}

.scroll-indicator span::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent, #fff);
  animation: scroll-line 2s infinite;
}

main {
  display: flex;
  flex-direction: column;
  gap: 6rem;
}

.section {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5.5rem 1.5rem;
  min-height: 100vh;
  min-height: 100svh;
}

.section > .container {
  width: 100%;
}

/* 每一节底部的「下一站」按钮 */
.section-next {
  text-align: center;
  padding-top: 0.5rem;
}

.next-btn {
  display: inline-block;
  padding: 0.85rem 2.4rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.98), rgba(255, 241, 246, 0.92));
  color: var(--text-primary);
  font-size: 0.95rem;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease, color 0.3s ease;
}

.next-btn::after {
  content: "↓";
  margin-left: 0.55rem;
  color: var(--accent);
  display: inline-block;
  transition: transform 0.3s ease;
}

.next-btn:hover {
  transform: translateY(-5px);
  color: var(--accent);
  box-shadow: 0 34px 64px -42px rgba(255, 122, 168, 1);
}

.next-btn:hover::after {
  transform: translateY(3px);
}

.container {
  width: min(1100px, 100%);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.section-header {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.section-title {
  font-size: clamp(2rem, 6vw, 4rem);
  letter-spacing: 0.6rem;
  text-indent: 0.6rem;
}

.section-subtitle {
  color: var(--text-secondary);
}

/* ===== 滚动渐入 ===== */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}

.reveal.show {
  opacity: 1;
  transform: translateY(0);
}

/* ===== 倒计时 ===== */
.together {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  text-align: center;
}

.together-total {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.together-total span {
  font-size: clamp(6rem, 18vw, 14rem);
  line-height: 0.8;
  background: linear-gradient(120deg, #ff7aa8, #ff9fc5, #ffd1e6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.together-total p {
  margin-top: 1rem;
  letter-spacing: 1rem;
  text-indent: 1rem;
  color: var(--text-secondary);
}

.together-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 4vw, 2rem);
}

.together-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(1.6rem, 6vw, 3rem);
  border-radius: 1.6rem;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.98), rgba(255, 241, 246, 0.9));
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  min-width: clamp(9rem, 20vw, 14rem);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.together-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 40px 70px -40px rgba(255, 122, 168, 1);
}

.together-item span {
  font-size: clamp(3rem, 10vw, 6rem);
  background: linear-gradient(120deg, #ff7aa8, #ff9fc5);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.together-item p {
  margin-top: 0.8rem;
  letter-spacing: 0.8rem;
  text-indent: 0.8rem;
  color: var(--text-secondary);
}

.together-start {
  color: var(--text-secondary);
}

/* ===== 照片墙 ===== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(1rem, 3vw, 1.6rem);
}

.gallery-item {
  grid-column: span 6;
  position: relative;
  border-radius: 1.4rem;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  aspect-ratio: 4 / 3;
  cursor: zoom-in;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  transform-style: preserve-3d;
  perspective: 1000px;
}

.gallery-item:nth-child(3n) {
  grid-column: span 12;
  aspect-ratio: 16 / 7;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
  transform: translateZ(20px);
}

.gallery-item:hover img {
  transform: scale(1.08) translateZ(20px);
}

.gallery-item:hover {
  transform: translateY(-10px);
  box-shadow: var(--glow), var(--shadow);
}

/* 说明文字：平时若隐若现地贴着图片底部，吸引人点开 */
.gallery-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 2.6rem 1.05rem 0.9rem;
  background: linear-gradient(to top,
      rgba(74, 63, 70, 0.78),
      rgba(74, 63, 70, 0.3) 46%,
      rgba(74, 63, 70, 0));
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.88rem;
  line-height: 1.55;
  letter-spacing: 0.02em;
  text-shadow: 0 1px 8px rgba(40, 25, 35, 0.55);
  opacity: 0.82;
  transition: opacity 0.35s ease, background 0.35s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  pointer-events: none;
}

.gallery-item:hover .gallery-caption {
  opacity: 1;
  background: linear-gradient(to top,
      rgba(74, 63, 70, 0.88),
      rgba(74, 63, 70, 0.42) 46%,
      rgba(74, 63, 70, 0));
}

/* 桌面端悬停时右上角浮出「查看大图」提示 */
.gallery-item::after {
  content: "查看大图";
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  padding: 0.3rem 0.75rem;
  font-size: 0.72rem;
  color: #fff;
  background: rgba(74, 63, 70, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 999px;
  backdrop-filter: blur(6px);
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.gallery-item:hover::after {
  opacity: 1;
  transform: translateY(0);
}

.gallery-more {
  text-align: center;
  margin-top: 1rem;
}

.gallery-more-btn {
  border: 1px solid var(--border);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.98), rgba(255, 241, 246, 0.9));
  color: var(--text-primary);
  padding: 0.8rem 2.4rem;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  font-size: 0.95rem;
}

.gallery-more-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 30px 60px -40px rgba(255, 122, 168, 1);
}

.lightbox-caption {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  font-size: 1.05rem;
  max-width: min(80vw, 800px);
  text-align: center;
  background: rgba(74, 63, 70, 0.5);
  backdrop-filter: blur(8px);
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.lightbox.active .lightbox-caption {
  opacity: 1;
  animation: fade-in-up 0.4s ease;
}

/* ===== 时间轴 ===== */
.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2.4rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--accent), transparent);
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: center;
  gap: 2rem;
}

.timeline-dot {
  position: absolute;
  left: 50%;
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: radial-gradient(circle, #fff, var(--accent));
  box-shadow: 0 0 0 0.6rem rgba(255, 122, 168, 0.12);
  transform: translate(-50%, -50%);
  top: 50%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-item:hover .timeline-dot {
  transform: translate(-50%, -50%) scale(1.5);
  box-shadow: 0 0 0 0.8rem rgba(255, 122, 168, 0.25), var(--glow);
}

.timeline-card {
  grid-column: 1;
  justify-self: end;
  width: min(420px, 100%);
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  padding: clamp(1.8rem, 4vw, 2.6rem);
  border-radius: 1.4rem;
  background: var(--card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  text-align: right;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  transform-style: preserve-3d;
  perspective: 1000px;
}

.timeline-card:hover {
  transform: translateY(-6px) rotateX(2deg) rotateY(-2deg);
  box-shadow: var(--glow), var(--shadow);
}

.timeline-item:nth-child(even) .timeline-card {
  grid-column: 2;
  justify-self: start;
  text-align: left;
}

.timeline-date {
  letter-spacing: 0.6rem;
  text-indent: 0.6rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.timeline-title {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
}

.timeline-text {
  color: var(--text-secondary);
}

/* ===== 信封开信 ===== */
#letter {
  padding: 2rem 1.2rem 16rem;
}

.letter-wrap {
  width: min(860px, 100%);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.envelope {
  position: relative;
  width: min(420px, 90vw);
  height: 280px;
  cursor: pointer;
  perspective: 1000px;
  transition: transform 0.4s ease, opacity 0.5s ease;
}

.envelope:hover {
  transform: translateY(-6px);
}

/* 点开后整个信封柔化退场，把位置让给信纸，不再遮挡上方标题 */
.envelope.open {
  opacity: 0;
  transform: scale(0.86);
  pointer-events: none;
}

.envelope-flap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 60%;
  background: linear-gradient(135deg, #ff9fc5, #ff7aa8);
  clip-path: polygon(0 0, 50% 100%, 100% 0);
  transform-origin: top;
  transition: transform 0.9s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 2;
  border-radius: 0.4rem 0.4rem 0 0;
  box-shadow: 0 10px 30px -10px rgba(255, 122, 168, 0.5);
}

.envelope.open .envelope-flap {
  transform: rotateX(180deg) scale(0.9);
  opacity: 0;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
}

.envelope-body {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #fff7fa, #fff1f6);
  border: 1px solid var(--border);
  border-radius: 0.6rem;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.envelope-seal {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: radial-gradient(circle, #ff9fc5, #ff7aa8);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.6rem;
  box-shadow: 0 10px 30px -10px rgba(255, 122, 168, 0.8);
  z-index: 3;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.envelope.open .envelope-seal {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0);
}

.envelope-hint {
  position: absolute;
  bottom: -2rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--text-secondary);
  font-size: 0.9rem;
  animation: blink 2s infinite;
}

.letter-card {
  display: none;
  width: 100%;
  flex-direction: column;
  border-radius: 1.8rem;
  background: radial-gradient(circle at top, #fff, #fff7fa);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
}

/* 信纸直接接替信封的位置，出现在眼前，不用再往下滑去找 */
.letter-card.open {
  display: flex;
  animation: letterIn 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes letterIn {
  from {
    opacity: 0;
    transform: translateY(-18px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.letter-header {
  display: flex;
  justify-content: space-between;
  padding: clamp(1.4rem, 4vw, 2rem) clamp(1.6rem, 6vw, 3.2rem);
  color: var(--text-secondary);
}

.letter-body {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  align-content: flex-start;
  gap: 0.4rem;
  padding: 0 clamp(1.6rem, 6vw, 3.2rem);
  min-height: clamp(16rem, 40vw, 24rem);
  font-size: clamp(1.1rem, 2.6vw, 1.6rem);
  white-space: pre-wrap;
}

.cursor {
  display: inline-block;
  margin-left: 0.2rem;
  animation: blink 1s infinite;
}

/* 打字机输出区：独占整行，里面按段落分开排 */
#typewriter {
  width: 100%;
}

/* 每段单独排版，避免最后一行只剩一两个字（孤字行） */
.letter-paragraph {
  width: 100%;
  margin-bottom: 1.1em;
  line-height: 1.9;
  text-wrap: pretty;
}

.letter-paragraph:last-child {
  margin-bottom: 0;
}

.letter-footer {
  padding: clamp(1.4rem, 4vw, 2rem) clamp(1.6rem, 6vw, 3.2rem);
  text-align: right;
  color: var(--text-secondary);
}

/* ===== 随机情话 ===== */
.surprise-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  text-align: center;
}

.surprise-btn {
  border: none;
  background: linear-gradient(120deg, rgba(255, 154, 197, 0.95), rgba(255, 122, 168, 0.95));
  color: #fff;
  padding: 1rem 3.6rem;
  border-radius: 999px;
  font-size: 1.05rem;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.surprise-btn:hover {
  transform: translateY(-6px);
  box-shadow: 0 40px 70px -40px rgba(255, 122, 168, 1);
}

.surprise-text {
  width: min(720px, 100%);
  padding: clamp(2rem, 6vw, 3.6rem);
  border-radius: 1.6rem;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.98), rgba(255, 241, 246, 0.9));
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  min-height: 10rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

.surprise-text.pop {
  transform: scale(1.04);
}

.footer {
  margin-top: 6rem;
  padding: 2rem 1.5rem;
  text-align: center;
  color: var(--text-secondary);
}

/* ===== 灯箱 ===== */
.lightbox {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(74, 63, 70, 0.4);
  backdrop-filter: blur(6px);
  z-index: 10;
}

.lightbox.active {
  display: flex;
}

.lightbox.active .lightbox-img {
  animation: lightbox-in 0.4s ease;
}

@keyframes lightbox-in {
  from { transform: scale(0.85); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.lightbox-close {
  position: absolute;
  top: 2rem;
  right: 2rem;
  border: none;
  background: transparent;
  color: #fff;
  font-size: 3rem;
  cursor: pointer;
}

.lightbox-img {
  max-width: min(90vw, 1600px);
  max-height: min(90vh, 1100px);
  border-radius: 1rem;
  box-shadow: 0 60px 120px -80px rgba(0, 0, 0, 0.8);
}

/* ===== 动画 ===== */
@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scroll-line {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100%); }
}

@keyframes blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

/* ===== 响应式 ===== */
@media (max-width: 980px) {
  .timeline::before {
    left: 1rem;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    padding-left: 3rem;
  }

  .timeline-dot {
    left: 1rem;
  }

  .timeline-card {
    grid-column: 1;
    justify-self: stretch;
    text-align: left;
  }

  .timeline-item:nth-child(even) .timeline-card {
    grid-column: 1;
    justify-self: stretch;
    text-align: left;
  }

  .gallery-item,
  .gallery-item:nth-child(3n) {
    grid-column: span 12;
    aspect-ratio: 16 / 10;
  }

  .hero-title {
    letter-spacing: 0.6rem;
    text-indent: 0.6rem;
  }

  .hero-subtitle {
    letter-spacing: 0.4rem;
  }
}

@media (max-width: 680px) {
  .section {
    padding: 3.6rem 1.2rem;
  }

  .container {
    gap: 2.2rem;
  }

  .section-title {
    font-size: clamp(1.7rem, 7.5vw, 2.6rem);
    letter-spacing: 0.24rem;
    text-indent: 0.24rem;
  }

  .section-next {
    padding-top: 0.2rem;
  }

  .next-btn {
    padding: 0.75rem 1.9rem;
    font-size: 0.9rem;
  }

  .together {
    gap: 1.4rem;
  }

  .together-total span {
    font-size: clamp(3.4rem, 17vw, 5.2rem);
  }

  .together-total p {
    margin-top: 0.45rem;
    font-size: 0.85rem;
    letter-spacing: 0.36rem;
    text-indent: 0.36rem;
  }

  /* 手机上时分秒横排，一屏就能看完 */
  .together-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.6rem;
    width: 100%;
  }

  .together-item {
    width: auto;
    min-width: 0;
    padding: 0.85rem 0.3rem;
    border-radius: 1rem;
  }

  .together-item span {
    font-size: clamp(1.45rem, 8.5vw, 2.3rem);
    line-height: 1.1;
  }

  .together-item p {
    margin-top: 0.32rem;
    font-size: 0.72rem;
    letter-spacing: 0.16rem;
    text-indent: 0.16rem;
  }

  .together-start {
    font-size: 0.85rem;
  }

  .gallery-caption {
    opacity: 0.9;
    font-size: 0.82rem;
    padding: 2rem 0.85rem 0.7rem;
  }

  .cursor-heart {
    display: none;
  }
}

/* ===== 密码锁 ===== */
html.locked body > *:not(#lock) {
  display: none !important;
}

.lock {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background:
    radial-gradient(circle at 25% 20%, rgba(255, 154, 197, 0.35), transparent 55%),
    radial-gradient(circle at 75% 80%, rgba(255, 209, 230, 0.45), transparent 55%),
    linear-gradient(160deg, #fff8fb, #fff1f6 60%, #ffe9f2);
}

.lock-card {
  width: min(92vw, 380px);
  padding: 2rem 1.6rem 1.5rem;
  text-align: center;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--border);
  border-radius: 26px;
  box-shadow: var(--shadow), var(--glow);
  backdrop-filter: blur(12px);
  animation: lockIn 0.5s ease both;
}

@keyframes lockIn {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.lock-icon { font-size: 2rem; line-height: 1; }

.lock-title {
  margin: 0.7rem 0 0.35rem;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
}

.lock-sub {
  margin-bottom: 1.3rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.lock-form {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.lock-input {
  width: 100%;
  padding: 0.8rem 1rem;
  font-size: 1rem;
  text-align: center;
  letter-spacing: 0.12em;
  color: var(--text-primary);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 999px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.lock-input::placeholder {
  letter-spacing: normal;
  color: #c9b6bf;
}

.lock-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(255, 122, 168, 0.16);
}

.lock-btn {
  padding: 0.78rem 1rem;
  font-size: 1rem;
  font-weight: 500;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border: none;
  border-radius: 999px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.lock-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 26px -14px rgba(255, 122, 168, 0.95);
}

.lock-btn:active { transform: translateY(0); }

.lock-err {
  min-height: 1.2em;
  margin-top: 0.55rem;
  font-size: 0.85rem;
  color: #e2557f;
}

.lock-hint {
  margin-top: 0.2rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
  opacity: 0.9;
}

.lock.shake .lock-card {
  animation: lockShake 0.42s ease;
}

@keyframes lockShake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px); }
  60% { transform: translateX(8px); }
  80% { transform: translateX(-4px); }
}