/* 第一页：红金婚礼风 · 背景 bg1 · 前景 s1 / 人物 s2 带动画 */

@font-face {
  font-family: 'CustomFont';
  src: url('./f.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'MaxwellLight';
  src: url('./MAXWELL-Light.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

:root {
  --p1-red: #9a1532;
  --p1-red-deep: #6e0f24;
  --p1-red-bright: rgb(191, 32, 38);
  --p1-gold: #e8c87a;
  --p1-white: #ffffff;

  /* 时间轴：姓名与 s2 同进同出 → 再 s1 显现；整体偏慢 */
  --p1-hero-dur: 4s;
  --p1-hero-end: var(--p1-hero-dur);
  --p1-s1-reveal-dur: 3.5s;
  --p1-s1-reveal-delay: 1s;
  --p1-s1-dance-delay: var(--p1-s1-reveal-delay);
  --p1-s2-zoom-dur: 20s;
  --p1-bg-fly-dur: 3.5s;
  --p1-name-en-scale: 0.78;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--p1-white);
  overflow: hidden;
  height: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-tap-highlight-color: transparent;
}

/* 音乐：右上角圆钮 */
.music-toggle {
  position: fixed;
  top: 3.2vw;
  right: 3.2vw;
  z-index: 100;
  width: 10.6vw;
  height: 10.6vw;
  border-radius: 50%;
  border: 0.3vw solid rgba(255, 255, 255, 0.55);
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  padding: 0;
}

.music-toggle::before {
  content: "";
  display: block;
  width: 4.8vw;
  height: 4.8vw;
  margin: 0 auto;
  background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='1.8'%3E%3Cpath d='M12 18a3 3 0 0 0 0-12v12z'/%3E%3Cpath d='M9 9v6M15 9v6'/%3E%3C/svg%3E");
  opacity: 0.95;
}

.music-toggle.playing {
  border-color: var(--p1-gold);
  background: rgba(154, 21, 50, 0.55);
  animation: p1-music-pulse 2s ease-in-out infinite;
}

.music-toggle.playing::before {
  background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23e8c87a'%3E%3Cpath d='M12 3v10.55c-.59-.34-1.27-.55-2-.55-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4V7h4V3h-6z'/%3E%3C/svg%3E");
}

@keyframes p1-music-pulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(232, 200, 122, 0.35);
  }

  50% {
    box-shadow: 0 0 0 1.6vw rgba(232, 200, 122, 0);
  }
}

.page1 {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

/* 上区：红底 + 背景图（背景层单独飞入动画） */
.p1-top {
  position: relative;
  flex: 1 1 auto;
  min-height: 78vh;
  padding: 10vh 4.8vw 6.4vh;
  color: var(--p1-white);
  background-color: var(--p1-red);
  overflow: hidden;
  isolation: isolate;
}

.p1-top::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-color: var(--p1-red);
  background-image: url("./images/p1/bg1.jpg");
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  transform-origin: 50% 40%;
  animation: p1-bg-fly-in var(--p1-bg-fly-dur) cubic-bezier(0.22, 1, 0.36, 1) both;
  will-change: transform, opacity;
}

.p1-top-t1 {
  position: absolute;
  top: 1.6vw;
  left: 50%;
  z-index: 2;
  width: min(58vw, 280px);
  transform: translateX(-50%);
}

@keyframes p1-bg-fly-in {
  0% {
    opacity: 0.45;
    transform: scale(1.28) translate(0, 18%);
  }

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

.p1-names {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 3.2vw;
  padding: 0 6.4vw;
  margin-top: -4vh;
  margin-bottom: 2.1vw;
}

.p1-name-block {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2.1vw;
  width: fit-content;
  max-width: 42%;
}

.p1-name-groom {
  align-items: flex-start;
}

.p1-name-bride {
  align-items: flex-end;
}

.p1-name-en {
  font-size: 2.4vw;
  letter-spacing: 0.2em;
  opacity: 0.88;
  text-transform: uppercase;
}

.p1-name-en-wrap {
  width: 100%;
  transform: scaleX(var(--p1-name-en-scale));
}

.p1-name-en-wrap--left {
  transform-origin: left center;
}

.p1-name-en-wrap--right {
  transform-origin: right center;
}

.p1-name-en-img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  opacity: 0.95;
  animation: p1-name-left-in var(--p1-hero-dur) cubic-bezier(0.22, 1, 0.36, 1) both;
}

.p1-name-en-img-right {
  animation-name: p1-name-right-in;
}

.p1-name-cn {
  display: block;
  font-size: clamp(18px, 5.2vw, 24px);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.2;
  color: rgb(252, 180, 41);
  white-space: nowrap;
}

.p1-name-groom .p1-name-cn {
  text-align: left;
  animation: p1-name-left-in var(--p1-hero-dur) cubic-bezier(0.22, 1, 0.36, 1) both;
}

.p1-name-bride .p1-name-en-img,
.p1-name-bride .p1-name-cn {
  animation: p1-name-right-in var(--p1-hero-dur) cubic-bezier(0.22, 1, 0.36, 1) both;
}

.p1-name-bride .p1-name-cn {
  text-align: right;
}

/* 中间叠层：s2 人物 + s1 前景字/囍 */
.p1-stage {
  position: relative;
  width: 90vw;
  max-width: 420px;
  margin: -12vh auto;
  min-height: 42vh;
}

.p1-s2-wrap {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  /* 等 s2 入场结束后再开始缓慢呼吸放大 */
  animation: p1-s2-zoom var(--p1-s2-zoom-dur) ease-in-out var(--p1-hero-end) infinite alternate;
  will-change: transform;
}

.p1-s2 {
  display: block;
  width: 50%;
  height: auto;
  object-fit: contain;
  pointer-events: none;
  animation: p1-s2-enter var(--p1-hero-dur) cubic-bezier(0.22, 1, 0.36, 1) both;
}

.p1-s1-wrap {
  position: absolute;
  left: 50%;
  top: 10vh;
  z-index: 3;
  width: 90vw;
  max-width: 420px;
  transform: translateX(-50%);
  pointer-events: none;
}

.p1-s1 {
  display: block;
  width: 100%;
  height: auto;
  max-height: 55vh;
  object-fit: contain;
  opacity: 0;
  animation: p1-s1-reveal var(--p1-s1-reveal-dur) cubic-bezier(0.22, 1, 0.36, 1) var(--p1-s1-reveal-delay) forwards, p1-s1-breathe 8s ease-in-out var(--p1-s1-dance-delay) infinite;
  animation-composition: add;
  will-change: transform;
  filter: drop-shadow(0 2.1vw 6.4vw rgba(0, 0, 0, 0.25));
}

@keyframes p1-name-left-in {
  0% {
    opacity: 0;
    transform: translateX(-10.6vw);
  }

  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes p1-name-right-in {
  0% {
    opacity: 0;
    transform: translateX(10.6vw);
  }

  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes p1-s2-enter {
  0% {
    opacity: 0;
    transform: scale(0.88) translateY(5.9vh);
  }

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

@keyframes p1-s2-zoom {

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

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

@keyframes p1-s1-reveal {
  0% {
    opacity: 0;
    transform: rotate(-18deg) scale(0.72);
  }

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

@keyframes p1-s1-breathe {


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

  50% {
    transform: rotate(0deg) scale(1.05);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInBottom {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: scale(0.3);
  }
  50% {
    opacity: 1;
    transform: scale(1.05);
  }
  70% {
    transform: scale(0.9);
  }
  100% {
    transform: scale(1);
  }
}

/* 分隔条 */
.p1-bar {
  flex: 0 0 auto;
  padding: 1vh 4.3vw;
  text-align: center;
  font-size: 2.9vw;
  letter-spacing: 0.25em;
  color: var(--p1-white);
  background: #7d060c;
}

/* 下区：诗句 */
.p1-bottom {
  flex: 0 0 auto;
  padding: 4vh 5.3vw 6vh;
  background: var(--p1-white);
  animation: fadeInUp 1.2s ease-out 0.5s both;
}

.p1-poem {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3.7vw;
  max-width: 360px;
  margin: 0 auto;
}

.p1-poem-mid {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3.2vw;
  min-width: 0;
}

.p1-t-wrap {
  width: 100%;
  transform: scaleX(1.18);
  transform-origin: center center;
}

.p1-t {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: brightness(0);
}

.p1-xi {
  flex: 0 0 auto;
  width: 7.5vw;
  height: auto;
  object-fit: contain;
  opacity: 0.95;
}

@media (min-width: 480px) {
  .p1-stage {
    min-height: 44vh;
  }
}

/* 滑动提示 */
.scroll-hint {
  position: absolute;
  bottom: 3vh;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  animation: bounce 1.5s ease-in-out infinite;
}

.scroll-arrow {
  display: block;
  width: 4vw;
  height: 7vw;
  border: 2px solid var(--p1-white);
  border-radius: 3vw;
  position: relative;
}

.scroll-arrow::after {
  content: '';
  position: absolute;
  width: 1vw;
  height: 1vw;
  background: var(--p1-white);
  border-radius: 50%;
  top: 1.5vw;
  left: 50%;
  transform: translateX(-50%);
  animation: scroll-dot 1.5s ease-in-out infinite;
}

@keyframes bounce {

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

  50% {
    transform: translateX(-50%) translateY(2vh);
  }
}

@keyframes scroll-dot {
  0% {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
  }

  100% {
    transform: translateX(-50%) translateY(3vw);
    opacity: 0;
  }
}

/* 第二页 */
.page2 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.page2.active {
  top: 0;
}

.page2.active .p2-header {
  animation: slideInLeft 2.5s ease-out 0.1s both;
}

.page2.active .p2-letter {
  animation: fadeInScale 2.5s ease-out 0.3s both;
}

.page2.active .p2-photo-section {
  animation: slideInRight 2.5s ease-out 0.5s both;
}

.page2.active .p2-footer {
  animation: bounceIn 2.5s ease-out 0.7s both;
}

.p2-content {
  height: 100vh;
  padding: 3vh 4.5vw;
  display: flex;
  flex-direction: column;
}

.p2-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 2vh;
}

.p2-title {
  font-size: 34px;
  font-weight: bold;
  font-family: 'SourceHanSansCN-Heavy', 'Helvetica Neue', sans-serif;
  color: var(--p1-red-bright);
  margin: 0;
  opacity: 1;
  letter-spacing: 0.15rem;
  writing-mode: lr-tb;
  padding: 6px;
  text-indent: 0rem;
  line-height: 1;
  margin-left: 5vw;
}

.p2-sweet-day {
  display: flex;
  align-items: flex-start;
  gap: 2px;
  margin-right: 10vw;
  margin-top: 5vh;

}

.p2-sweet-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.p2-bracket-left,
.p2-bracket-right {
  font-size: 16px;
  font-family: 'SourceHanSansCN-Heavy', 'Helvetica Neue', sans-serif;
  color: var(--p1-red-bright);
  opacity: 1;
  letter-spacing: 0rem;
  writing-mode: lr-tb;
  padding: 0.13333rem;
  text-indent: 0rem;
  text-align: left;
  line-height: 1;
  padding-top: 1.5vh;
}

.p2-sweet-text {
  font-size: 16px;
  font-weight: bold;
  font-family: 'SourceHanSansCN-Heavy', 'Helvetica Neue', sans-serif;
  color: var(--p1-red-bright);
  opacity: 1;
  letter-spacing: 0.15rem;
  writing-mode: lr-tb;
  padding: 0.13333rem;
  text-indent: 0rem;
  text-align: left;
  line-height: 1;
}

.p2-day-text {
  font-size: 16px;
  font-weight: bold;
  font-family: 'SourceHanSansCN-Heavy', 'Helvetica Neue', sans-serif;
  color: var(--p1-red-bright);
  opacity: 1;
  letter-spacing: 0.15rem;
  writing-mode: lr-tb;
  padding: 0.13333rem;
  text-indent: 0rem;
  text-align: left;
  line-height: 1;
}

.p2-letter {
  /* text-align: left; */
  margin-top: -3vh;
  margin-left: 10vw;
  margin-bottom: 2.5vh;
  flex-shrink: 0;
  padding: 5.73319px;
}

.p2-letter p {
  font-size: 13.76px;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-weight: normal;
  font-style: normal;
  color: #000000;
  line-height: 2;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.p2-photo-section {
  width: 100%;
  display: flex;
  gap: 2.5vw;
  margin-top: 2vh;
  margin-left: 6vw;
  flex-shrink: 0;
}

.p2-photo {
  flex: 1;
  width: 0;
  max-height: 38vh;
  max-width: 45vw;
  object-fit: cover;
  border-radius: 1.5vw;
}

.p2-names {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6vh;
  margin-left: -3.7vw;
  margin-top: 3vh;
}

.p2-name-item {
  display: flex;
  flex-direction: column;
  gap: 0.5vh;
}

.p2-name-top {
  display: flex;
  align-items: center;
  gap: 1.2vw;
}

.p2-dot {
  width: 2vw;
  height: 2vw;
  background: var(--p1-red-bright);
  border-radius: 50%;
}

.p2-name-label {
  margin-left: 4vw;
  font-size: 16px;
  color: var(--p1-red-bright);
  font-weight: bold;
}

.p2-name-value {
  font-size: 14px;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: #333;
  font-weight: 500;
  text-align: right;
  margin-left:22vw;
  margin-top:2vh;
}

.p2-footer {
  text-align: center;
  padding-top: 0;
  margin-top: 10vh;
}

.p2-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p2-quote {
  flex: 1;
  max-width: 280px;
}

.p2-t1 {
  width: 100%;
  height: auto;
}

.p2-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}

@media (prefers-reduced-motion: reduce) {
  .p1-top::before {
    animation: none !important;
    opacity: 1;
    transform: none;
  }

  .p1-name-en-img,
  .p1-name-groom .p1-name-cn,
  .p1-name-bride .p1-name-en-img,
  .p1-name-bride .p1-name-cn,
  .p1-s2-wrap,
  .p1-s2,
  .p1-s1-wrap,
  .p1-s1,
  .music-toggle.playing {
    animation: none !important;
  }

  .p1-s2 {
    opacity: 1;
    transform: none;
  }

  .p1-s1 {
    opacity: 1;
    transform: none;
  }
}

.page3 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.page3.active {
  top: 0;
}

.page3.active .p3-text {
  animation: fadeInUp 2.5s ease-out 0.2s both;
}

.page3.active .p3-photo:first-child {
  animation: slideInLeft 1s ease-out 0.4s both;
}

.page3.active .p3-photo:last-child {
  animation: slideInRight 2.5s ease-out 0.6s both;
}

.page3.active .p3-bar {
  animation: fadeIn 3.5s ease-out 0.8s both;
}

.page3.active .p3-footer {
  animation: bounceIn 2.5s ease-out 0.8s both;
}

.p3-content {
  height: 100vh;
  padding: 2vh 0;
  display: flex;
  flex-direction: column;
}

.p3-text {
  text-align: center;
  margin-top: 3vh;
  margin-bottom: 3vh;
}

.p3-text p {
  font-size: 13.76px;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-weight: normal;
  font-style: normal;
  color: #000000;
  line-height: 2;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.p3-photos {
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow: hidden;
  width: 100%;
  margin-top: 2vh;
}

.p3-photo {
  width: 100%;
  object-fit: cover;
  opacity: 0;
}

.p3-bar {
  flex: 0 0 auto;
  padding: 1vh 4.3vw;
  text-align: center;
  font-size: 2.9vw;
  letter-spacing: 0.95em;
  color: var(--p1-white);
  background: #7d060c;
  opacity: 0;
}

.p3-footer {
  text-align: center;
  padding-top: 3vh;
}

.p3-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p3-quote {
  flex: 1;
  max-width: 280px;
}

.p3-t1 {
  width: 100%;
  height: auto;
}

.p3-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}

.page4 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.page4.active {
  top: 0;
}

.page4.active .p4-header {
  animation: fadeInUp 2.5s ease-out 0.2s both;
}

.page4.active .p4-section1 {
  animation: fadeInScale 2.5s ease-out 0.4s both;
}

.page4.active .p4-section2 {
  animation: slideInRight 2.5s ease-out 0.6s both;
}

.page4.active .p4-footer-text {
  animation: fadeIn 2.5s ease-out 0.8s both;
}

.page4.active .p4-footer {
  animation: bounceIn 2.5s ease-out 1s both;
}

.p4-content {
  height: 100vh;
  padding: 3vh 4.5vw;
  display: flex;
  flex-direction: column;
}

.p4-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 2vh;
}

.p4-left {
  display: flex;
  flex-direction: column;
}

.p4-date {
  font-size: 24px;
  font-weight: bold;
  color: var(--p1-red-bright);
  font-family: sans-serif;
}

.p4-names {
  font-size: 12px;
  color: var(--p1-red-bright);
  font-family: 'MaxwellLight', sans-serif;
  margin-top: 0.5vh;
}

.p4-dots {
  display: flex;
  flex-direction: column;
  gap: 1.5vh;
}

.p4-dot {
  width: 10px;
  height: 10px;
  border: 2px solid var(--p1-red-bright);
  border-radius: 50%;
}

.p4-section1 {
  display: flex;
  gap: 3vw;
  margin-bottom: 2vh;
}

.p4-photo {
  object-fit: cover;
  border-radius: 2vw;
}

.p4-photo1 {
  width: 50vw;
}

.p4-text1 {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: right;
}

.p4-text1 p {
  opacity: 1;
  letter-spacing: 0.02667rem;
  writing-mode: lr-tb;
  padding: 0.13333rem;
  text-indent: 0rem;
  font-size: 20px;
  color: rgb(191, 32, 38);
  text-align: right;
  line-height: 1.8;
  font-family: 'MaxwellLight', sans-serif;
  margin: 0;
}

.p4-section2 {
  display: flex;
  gap: 3vw;
  margin-bottom: 2vh;
}

.p4-text2 {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.p4-title {
  font-size: 28px;
  font-weight: bold;
  color: var(--p1-red-bright);
  font-family: sans-serif;
  letter-spacing: 0.1em;
}

.p4-quote {
  position: relative;
  margin-top: 2vh;
}

.p4-quote-start,
.p4-quote-end {
  font-size: 24px;
  color: var(--p1-red-bright);
  font-family: 'STKaiti', 'KaiTi', serif;
}

.p4-quote-start {
  position: absolute;
  top: -0.5vh;
  left: 2vw;
}

.p4-quote-end {
  position: absolute;
  right: 4vw;
}

.p4-quote-text {
  flex: 1;
  padding: 0 1vw;
  text-align: center;
}

.p4-quote-text p {
  font-size: 13.76px;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-weight: normal;
  font-style: normal;
  color: #000000;
  line-height: 2;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.p4-photo2 {
  width: 50%;
}

.p4-footer-text {
  text-align: center;
  font-size: 14px;
  color: var(--p1-red-bright);
  font-family: 'MaxwellLight', sans-serif;
  margin-left: 44vw;
  margin-bottom: 2vh;
}

.p4-footer {
  text-align: center;
  padding-top: 2vh;
}

.p4-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p4-quote {
  flex: 1;
  max-width: 280px;
}

.p4-t1 {
  width: 100%;
  height: auto;
}

.p4-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}

.page5 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.page5.active {
  top: 0;
}

.page5.active .p5-main-photo {
  animation: fadeInScale 2.5s ease-out 0.2s both;
}

.page5.active .p5-header {
  animation: fadeInUp 2.5s ease-out 0.4s both;
}

.page5.active .p5-section {
  animation: slideInRight 2.5s ease-out 0.6s both;
}

.page5.active .p5-footer {
  animation: bounceIn 2.5s ease-out 0.8s both;
}

.p5-content {
  height: 100vh;
  display: flex;
  flex-direction: column;
}

.p5-main-photo {
  width: 100%;
  object-fit: cover;
}

.p5-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 3vh 4.5vw;
}

.p5-poem {
  flex: 1;
}

.p5-poem p {
  opacity: 1;
  letter-spacing: 0.02667rem;
  writing-mode: lr-tb;
  padding: 0.13333rem;
  text-indent: 0rem;
  font-size: 14px;
  color: rgb(191, 32, 38);
  text-align: left;
  line-height: 1.2;
  font-family: 'MaxwellLight', sans-serif;
  margin: 0.5vh 0;
  white-space: nowrap;
}

.p5-title {
  font-size: 20px;
  font-weight: bold;
  color: rgb(191, 32, 38);
  letter-spacing: 0.15rem;
  white-space: nowrap;
}

.p5-section {
  display: flex;
  gap: 3vw;
  padding: 0 4.5vw;
  flex: 1;
  margin-top: -10vh;
  align-items: center;
}

.p5-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.p5-love {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  margin-top: 3vh;
}

.p5-bracket-left,
.p5-bracket-right {
  font-size: 16px;
  color: rgb(191, 32, 38);
  font-family: sans-serif;
  padding-top: 1.5vh;
}

.p5-love-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 1vw;
}

.p5-love-text {
  font-size: 16px;
  color: rgb(191, 32, 38);
  font-family: sans-serif;
  letter-spacing: 0.1em;
  line-height: 1.5;
}

.p5-chinese {
  margin-top: 3vh;
  text-align: center;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif !important;
}

.p5-chinese p {
  font-size: 13.76px;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif !important;
  font-weight: 100 !important;
  font-style: normal;
  color: #000000;
  line-height: 2;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.p5-side-photo {
  width: 55vw;
  height: 50vh !important;
  flex-shrink: 0;
  object-fit: contain;
}

.p5-footer {
  text-align: center;
  padding: 2vh 4.5vw;
}

.p5-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p5-quote {
  flex: 1;
  max-width: 280px;
}

.p5-t1 {
  width: 100%;
  height: auto;
}

.p5-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}

.page6 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.page6.active {
  top: 0;
}

.page6.active .p6-header {
  animation: fadeInDown 2.5s ease-out 0.2s both;
}

.page6.active .p6-main-photo {
  animation: fadeInScale 2.5s ease-out 0.4s both;
}

.page6.active .p6-subtitle {
  animation: fadeIn 2.5s ease-out 0.6s both;
}

.page6.active .p6-section {
  animation: slideInUp 2.5s ease-out 0.8s both;
}

.page6.active .p6-footer {
  animation: bounceIn 2.5s ease-out 1s both;
}

.p6-content {
  height: 100vh;
  display: flex;
  flex-direction: column;
}

.p6-header {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 3vh 4.5vw;
  gap: 2vw;
}

.p6-circle {
  width: 12px;
  height: 12px;
  border: 2px solid rgb(191, 32, 38);
  border-radius: 50%;
}

.p6-title {
  font-size: 24px;
  font-weight: bold;
  color: rgb(191, 32, 38);
  letter-spacing: 0.1em;
}

.p6-main-photo {
  width: 85%;
  height: auto;
  margin: 0 auto;
  object-fit: cover;
}

.p6-subtitle {
  text-align: center;
  padding: 3vh 0;
  font-family: 'MaxwellLight', sans-serif;
  font-size: 16px;
  color: rgb(191, 32, 38);
  letter-spacing: 0.02667rem;
}

.p6-section {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 0 8vw;
  flex: 1;
}

.p6-chinese {
  flex: 1;
}

.p6-chinese p {
  font-size: 13.76px;
  font-family: 'CustomFont', 'siyuanheitijixi', 'Source Han Sans CN', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-weight: 100;
  font-style: normal;
  color: #000000;
  line-height: 2;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

.p6-initials {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5vh;
}

.p6-initials span {
  font-size: 24px;
  font-weight: bold;
  color: rgb(191, 32, 38);
  font-family: sans-serif;
}

.p6-footer {
  text-align: center;
  padding: 4vh 4.5vw;
}

.p6-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p6-quote {
  flex: 1;
  max-width: 280px;
}

.p6-t1 {
  width: 100%;
  height: auto;
}

.p6-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}

.page7 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  overflow: hidden;
}

.page7.active {
  top: 0;
}

.page7.active .p7-bg {
  animation: fadeIn 2.5s ease-out 0.1s both;
}

.page7.active .p7-header {
  animation: fadeInDown 2.5s ease-out 0.2s both;
}

.page7.active .p7-countdown {
  animation: fadeIn 2s ease-out 0.3s both;
}

.page7.active .p7-s1 {
  animation: p7-s1-reveal 3.5s cubic-bezier(0.22, 1, 0.36, 1) 1s both, p7-s1-breathe 4s ease-in-out 4s infinite;
}

.page7.active .p7-calendar {
  animation: fadeInUp 2.5s ease-out 1.5s both;
}

.page7.active .p7-footer {
  animation: bounceIn 2.5s ease-out 2.5s both;
}

.p7-content {
  height: 100vh;
  position: relative;
  display: flex;
  flex-direction: column;
}

.p7-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0;
}

.p7-header {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 2vh 4.5vw;
  color: var(--p1-white);
}

.p7-countdown {
  position: relative;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
  padding: 1vh 3vw;
}

.p7-countdown-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1vh 2vw;
}

.p7-countdown-value {
  font-size: 28px;
  font-weight: bold;
  color: #ffd700;
  font-family: Arial, sans-serif;
}

.p7-countdown-label {
  font-size: 12px;
  color: #ffd700;
  margin-top: 0.5vh;
}

.p7-countdown-separator {
  font-size: 24px;
  color: #ffd700;
  font-weight: bold;
}

.p7-countdown-title {
  font-size: 16px;
  color: #ffd700;
  margin-right: 2vw;
  padding-right: 2vw;
  border-right: 1px solid #ffd700;
}

.p7-quote-start,
.p7-quote-end {
  font-size: 24px;
  color: var(--p1-gold);
}

.p7-header-text {
  font-size: 14px;
  font-weight: normal;
  letter-spacing: 0.1em;
}

.p7-s1-wrap {
  position: absolute;
  top: 9vh;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  width: 90vw;
}

.p7-s1 {
  width: 100%;
  max-width: none;
  height: auto;
  opacity: 0;
}

@keyframes p7-s1-reveal {
  0% {
    opacity: 0;
    transform: rotate(-18deg) scale(0.72);
  }
  100% {
    opacity: 1;
    transform: rotate(0) scale(1);
  }
}

@keyframes p7-s1-breathe {
  0%, 100% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(0deg) scale(1.05);
  }
}

.p7-calendar {
  position: absolute;
  z-index: 2;
  left: 19vw;
  top: 45vh;
  transform: translateX(-50%);
  margin: 0;
  padding: 2vh 3vw;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 1.5vw;
  width: 65vw;
  min-height: 32vh;
}

.p7-date {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.5vw;
  margin-bottom: 2vh;
}

.p7-month {
  font-size: 48px;
  font-weight: bold;
  color: var(--p1-gold);
  font-family: sans-serif;
}

.p7-slash {
  font-size: 24px;
  color: var(--p1-white);
}

.p7-day {
  font-size: 48px;
  font-weight: bold;
  color: var(--p1-gold);
  font-family: sans-serif;
}

.p7-year {
  font-size: 16px;
  color: var(--p1-white);
  margin-left: 2vw;
}

.p7-weekdays {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1.5vh;
}

.p7-weekdays span {
  font-size: 12px;
  color: var(--p1-white);
  text-align: center;
  width: 14%;
}

.p7-days {
  display: flex;
  flex-wrap: wrap;
}

.p7-days span {
  font-size: 14px;
  color: var(--p1-white);
  text-align: center;
  width: 14%;
  padding: 1vh 0;
  position: relative;
}

.p7-days span.p7-selected {
  color: var(--p1-gold);
  background: transparent;
  border-radius: 0;
  width: 32px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  animation: p7-heartbeat 2s ease-in-out infinite;
  position: relative;
  font-weight: bold;
}

.p7-days span.p7-selected::before {
  content: '♥';
  position: absolute;
  font-size: 32px;
  color: transparent;
  -webkit-text-stroke: 2px var(--p1-gold);
  text-stroke: 2px var(--p1-gold);
  line-height: 1;
  animation: p7-heartbeat 2s ease-in-out infinite;
}

@keyframes p7-heartbeat {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.9;
  }
}

.p7-footer {
  position: absolute;
  z-index: 1;
  bottom: 0;
  left: 0;
  right: 0;
  text-align: center;
  padding: 3vh 4.5vw;
  background: var(--p1-white);
}

.p7-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p7-quote {
  flex: 1;
  max-width: 280px;
}

.p7-t1 {
  width: 100%;
  height: auto;
}

.p7-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}

/* 第8页样式 */
.page8 {
  position: fixed;
  top: 100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--p1-white);
  z-index: 100;
  transition: top 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.page8.active {
  top: 0;
}

.page8.active .p8-bg {
  animation: fadeIn 2.5s ease-out 0.1s both;
}

.page8.active .p8-header {
  animation: fadeInDown 2.5s ease-out 0.3s both;
}

.page8.active .p8-map {
  animation: fadeInUp 2.5s ease-out 0.8s both;
}

.page8.active .p8-address {
  animation: fadeIn 2.5s ease-out 1.2s both;
}

.page8.active .p8-footer {
  opacity: 1;
  animation: bounceIn 2.5s ease-out 1.8s both;
}

.p8-content {
  height: 100vh;
  position: relative;
  display: flex;
  flex-direction: column;
}

.p8-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0;
}

.p8-header {
  position: relative;
  z-index: 1;
  text-align: center;
  margin-top: 8vh;
  opacity: 0;
}

.p8-date-line {
  font-size: 18px;
  color: #ffd700;
  font-weight: bold;
  margin-bottom: 1vh;
}

.p8-lunar-line {
  font-size: 16px;
  color: #ffd700;
}

.p8-map {
  position: relative;
  z-index: 1;
  margin-top: 55vh;
  padding: 0 8vw;
  opacity: 0;
}

.p8-map-header {
  text-align: center;
  margin-bottom: 2vh;
}

.p8-date-line {
  font-size: 18px;
  color: #ffffff;
  font-weight: bold;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.p8-lunar-line {
  font-size: 16px;
  color: #ffffff;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.p8-map img {
  width: 100%;
  height: auto;
  border-radius: 2vw;
}

.p8-map-overlay {
  position: absolute;
  bottom: 1.5vw;
  right: 10vw;
  background: rgba(125, 6, 12, 0.8);
  color: #ffffff;
  padding: 1vw 3vw;
  border-radius: 2vw;
  font-size: 14px;
  cursor: pointer;
}

.p8-address {
  position: relative;
  z-index: 1;
  text-align: center;
  font-size: 18px;
  color: #7d060c;
  margin-top: 3vh;
  opacity: 0;
}

.p8-footer {
  position: absolute;
  z-index: 1;
  left: 0;
  right: 0;
  bottom: 0;
  text-align: center;
  padding: 3vh 4.5vw;
  background: var(--p1-white);
  opacity: 0;
}

.p8-quote-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2vw;
}

.p8-quote {
  flex: 1;
  max-width: 280px;
}

.p8-t1 {
  width: 100%;
  height: auto;
}

.p8-xi {
  font-size: 24px;
  color: var(--p1-red);
  font-weight: bold;
  font-family: 'STKaiti', 'KaiTi', serif;
}}