/* =========================================================================
   SECTIONS — 八个章节
   ========================================================================= */

/* =======================================================================
   01 · 序 · 蛋糕
   ======================================================================= */
.sec--hero {
  justify-content: space-between;
  align-items: center;
  text-align: center;
  padding-bottom: clamp(34px, 6vh, 64px);
}

.sec--hero::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 46%;
  width: min(900px, 120vw);
  height: min(900px, 120vw);
  transform: translate(-50%, -50%);
  background: radial-gradient(
    circle,
    rgba(242, 167, 101, 0.1) 0%,
    rgba(233, 192, 122, 0.05) 28%,
    transparent 62%
  );
  pointer-events: none;
}

/* 纸纤维：让开场那张「纸」看起来是真的纸 */
.sec--hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.85;
  background-image: radial-gradient(
      rgba(148, 114, 72, 0.055) 0.5px,
      rgba(255, 255, 255, 0) 0.6px
    ),
    radial-gradient(rgba(120, 88, 52, 0.045) 0.5px, rgba(255, 255, 255, 0) 0.6px),
    linear-gradient(
      172deg,
      rgba(255, 255, 255, 0.35) 0%,
      rgba(255, 255, 255, 0) 40%,
      rgba(196, 168, 126, 0.08) 100%
    );
  background-size: 4px 4px, 7px 7px, 100% 100%;
  background-position: 0 0, 2px 3px, 0 0;
}

.hero__meta {
  position: absolute;
  top: clamp(64px, 9vh, 104px);
  left: var(--gutter);
  right: var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 3;
}

.hero__coord {
  font-family: var(--num);
  font-size: 10px;
  letter-spacing: 0.28em;
  color: var(--faint);
}

.cake-wrap {
  position: relative;
  display: grid;
  place-items: end center;
  flex: 1;
  width: 100%;
  min-height: 0;
  padding-top: 20px;
}

.cake {
  position: relative;
  width: 420px;
  height: 520px;
  transform-origin: 50% 100%;
}

.cake__halo {
  position: absolute;
  left: 50%;
  bottom: 60px;
  width: 640px;
  height: 640px;
  transform: translate(-50%, 32%);
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(255, 186, 110, 0.22) 0%,
    rgba(255, 160, 90, 0.08) 36%,
    transparent 66%
  );
  filter: blur(12px);
  pointer-events: none;
  transition: opacity 1.2s ease, transform 1.6s var(--ease);
}

.cake.is-blown .cake__halo {
  opacity: 0.72;
  transform: translate(-50%, 30%) scale(1.06);
}

/* ---------- 蛋糕层 ---------- */
.layer {
  position: absolute;
  left: 50%;
  bottom: var(--b);
  width: var(--w);
  height: var(--h);
  transform: translate(-50%, -640px);
  opacity: 0;
  z-index: var(--z, 1);
}

.layer.is-dropped {
  animation: layerDrop 1.05s cubic-bezier(0.2, 1.32, 0.36, 1) forwards;
  animation-delay: var(--delay, 0s);
}

@keyframes layerDrop {
  0% {
    transform: translate(-50%, -640px);
    opacity: 0;
  }
  12% {
    opacity: 1;
  }
  56% {
    transform: translate(-50%, 8px);
  }
  70% {
    transform: translate(-50%, -18px) scaleY(1.03);
  }
  84% {
    transform: translate(-50%, 4px) scaleY(0.99);
  }
  100% {
    transform: translate(-50%, 0);
    opacity: 1;
  }
}

.layer__body {
  position: absolute;
  inset: 0;
  border-radius: 50% 50% 50% 50% / 12% 12% 17% 17%;
  background: linear-gradient(
      90deg,
      rgba(40, 18, 4, 0.42) 0%,
      rgba(255, 255, 255, 0.08) 16%,
      rgba(255, 255, 255, 0.14) 40%,
      rgba(255, 255, 255, 0.02) 62%,
      rgba(30, 12, 2, 0.16) 82%,
      rgba(30, 12, 2, 0.46) 100%
    ),
    var(--cake);
  box-shadow: inset 0 -18px 30px rgba(30, 10, 0, 0.26),
    inset 0 10px 18px rgba(255, 235, 210, 0.1), 0 16px 30px rgba(0, 0, 0, 0.26);
}

.layer--1 {
  --w: 340px;
  --h: 92px;
  --b: 64px;
  --cake: linear-gradient(180deg, #f0d8b6 0%, #e2c39b 100%);
  --z: 1;
}

.layer--2 {
  --w: 272px;
  --h: 86px;
  --b: 156px;
  --cake: linear-gradient(180deg, #d09a6d 0%, #b87c50 100%);
  --z: 2;
}

.layer--3 {
  --w: 218px;
  --h: 102px;
  --b: 242px;
  --cake: linear-gradient(180deg, #83543a 0%, #67402c 100%);
  --z: 3;
}

.layer__cream {
  position: absolute;
  left: -2px;
  right: -2px;
  top: -13px;
  height: 27px;
  border-radius: 50%;
  background: radial-gradient(
    115% 175% at 50% 10%,
    #fffdf6 0%,
    #f9ecd6 46%,
    #e9d4af 100%
  );
  box-shadow: 0 7px 15px rgba(40, 18, 4, 0.22),
    inset 0 2px 0 rgba(255, 255, 255, 0.85);
}

.layer__cream::after {
  content: "";
  position: absolute;
  top: 40%;
  left: 3px;
  right: 3px;
  height: 32px;
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  background: radial-gradient(circle at 16px 0, #f7e9d1 0 15px, transparent 15.5px)
    0 0 / 48px 26px repeat-x;
  filter: drop-shadow(0 4px 3px rgba(40, 18, 4, 0.12));
}

.layer--3 .layer__cream::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background-image: radial-gradient(circle, #d98b93 0 2px, transparent 2.6px),
    radial-gradient(circle, #8fb0c9 0 2px, transparent 2.6px),
    radial-gradient(circle, #e9c07a 0 1.8px, transparent 2.4px);
  background-size: 34px 22px, 34px 22px, 34px 22px;
  background-position: 8px 9px, 22px 5px, 3px 15px;
  opacity: 0.55;
}

.layer__text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding-top: 16px;
  color: #f7dfb4;
  text-shadow: 0 2px 10px rgba(20, 8, 0, 0.45);
}

.layer__name {
  font-family: var(--serif);
  font-size: 21px;
  letter-spacing: 0.22em;
  text-indent: 0.22em;
  color: #f8e6c4;
}

.layer__age {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-family: var(--num);
  font-size: 46px;
  line-height: 1;
  color: var(--gold);
}

.layer__age small {
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 0.1em;
  color: rgba(248, 230, 196, 0.85);
}

/* ---------- 蜡烛 ---------- */
.candles {
  position: absolute;
  left: 50%;
  bottom: 348px;
  z-index: 6;
  display: flex;
  align-items: flex-end;
  gap: 36px;
  height: 76px;
  padding: 0 10px;
  transform: translateX(-50%);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.candle {
  position: relative;
  display: block;
  width: 12px;
  height: 76px;
}

.candle__stick {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 11px;
  height: 50px;
  transform: translateX(-50%);
  border-radius: 3px;
  background: repeating-linear-gradient(
    132deg,
    #f4dcc0 0 5px,
    #b8544c 5px 10px
  );
  box-shadow: inset -2px 0 3px rgba(90, 30, 20, 0.35),
    inset 2px 0 3px rgba(255, 255, 255, 0.35);
}

.candle__flame {
  position: absolute;
  left: 50%;
  top: 0;
  width: 15px;
  height: 25px;
  transform: translateX(-50%);
  border-radius: 50% 50% 46% 46% / 64% 64% 36% 36%;
  background: radial-gradient(
    circle at 50% 72%,
    #fffbe8 0%,
    #ffe6a6 22%,
    #ffc06a 48%,
    #ff8f3d 72%,
    rgba(255, 120, 40, 0) 100%
  );
  filter: drop-shadow(0 0 10px rgba(255, 176, 88, 0.95))
    drop-shadow(0 0 34px rgba(255, 140, 60, 0.5));
  transform-origin: 50% 90%;
  animation: flicker 1.7s ease-in-out infinite alternate;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.candle:nth-child(2) .candle__flame {
  animation-delay: -0.6s;
  animation-duration: 2.1s;
}

.candle:nth-child(3) .candle__flame {
  animation-delay: -1.2s;
  animation-duration: 1.5s;
}

@keyframes flicker {
  0% {
    transform: translateX(-50%) scale(1) rotate(-2deg);
    opacity: 0.92;
  }
  40% {
    transform: translateX(-50%) scale(1.06, 0.96) rotate(1.5deg);
    opacity: 1;
  }
  100% {
    transform: translateX(-50%) scale(0.94, 1.05) rotate(3deg);
    opacity: 0.86;
  }
}

.candle__smoke {
  position: absolute;
  left: 50%;
  top: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(226, 228, 232, 0.36);
  filter: blur(5px);
  opacity: 0;
  transform: translateX(-50%);
  pointer-events: none;
}

.candles:hover .candle__flame {
  transform: translateX(-50%) scale(1.12);
}

.cake.is-blown .candle__flame {
  opacity: 0;
  transform: translateX(-50%) scale(0.15);
  animation: none;
}

.cake.is-blown .candle__smoke {
  animation: smoke 2.6s cubic-bezier(0.2, 0.6, 0.3, 1) forwards;
}

.cake.is-blown .candle:nth-child(2) .candle__smoke {
  animation-delay: 0.12s;
}

.cake.is-blown .candle:nth-child(3) .candle__smoke {
  animation-delay: 0.24s;
}

@keyframes smoke {
  0% {
    opacity: 0.55;
    transform: translate(-50%, 0) scale(0.6);
  }
  55% {
    opacity: 0.28;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -86px) translateX(14px) scale(3.2);
  }
}

.candles {
  opacity: 0;
  transition: opacity 0.9s ease 0.15s;
}

.cake.is-ready .candles {
  opacity: 1;
}

.candles:disabled {
  cursor: default;
}

.cake.is-blown .candles {
  pointer-events: none;
}

.cake__plate {
  position: absolute;
  left: 50%;
  bottom: 34px;
  width: 374px;
  height: 38px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(
      120% 160% at 50% -20%,
      #fffdf8 0%,
      #ded6c8 38%,
      #a89d8c 72%,
      #6f6557 100%
    );
  box-shadow: 0 26px 50px rgba(0, 0, 0, 0.55),
    inset 0 -6px 10px rgba(0, 0, 0, 0.25),
    inset 0 3px 6px rgba(255, 255, 255, 0.5);
}

.cake__plate::after {
  content: "";
  position: absolute;
  inset: 8px 26px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  opacity: 0.6;
}

.cake__sparkles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 8;
}

.spark {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #ffe6b0;
  box-shadow: 0 0 8px 1px rgba(255, 214, 140, 0.9);
  opacity: 0;
  animation: sparkOut 1.5s cubic-bezier(0.1, 0.7, 0.3, 1) forwards;
}

@keyframes sparkOut {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(1);
  }
  70% {
    opacity: 0.9;
  }
  100% {
    opacity: 0;
    transform: translate(var(--sx), var(--sy)) scale(0.2);
  }
}

/* ---------- hero 文案 ---------- */
.hero__foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-height: 92px;
  z-index: 4;
}

.hero__hint {
  font-family: var(--serif);
  font-size: clamp(15px, 1.6vw, 19px);
  letter-spacing: 0.26em;
  text-indent: 0.26em;
  color: rgba(247, 233, 208, 0.92);
  transition: opacity 0.6s ease, transform 0.6s var(--ease);
}

.hero__sub {
  font-size: 10px;
  letter-spacing: 0.34em;
  color: var(--faint);
  transition: opacity 0.6s ease;
}

.hero__hint.is-swap {
  animation: hintSwap 0.9s var(--ease);
  color: var(--gold);
}

@keyframes hintSwap {
  0% {
    opacity: 0;
    transform: translateY(8px);
  }
  100% {
    opacity: 1;
    transform: none;
  }
}

.scroll-cue {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.8s ease, transform 0.8s var(--ease);
}

.scroll-cue.is-visible {
  opacity: 1;
  transform: none;
}

.scroll-cue i {
  position: relative;
  display: block;
  width: 1px;
  height: 46px;
  background: linear-gradient(
    180deg,
    rgba(233, 192, 122, 0.05),
    rgba(233, 192, 122, 0.45)
  );
  overflow: hidden;
}

.scroll-cue i::after {
  content: "";
  position: absolute;
  left: -1px;
  top: -12px;
  width: 3px;
  height: 12px;
  border-radius: 2px;
  background: var(--gold);
  box-shadow: 0 0 8px rgba(233, 192, 122, 0.8);
  animation: cueDown 2.2s ease-in-out infinite;
}

@keyframes cueDown {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  30% {
    opacity: 1;
  }
  100% {
    transform: translateY(58px);
    opacity: 0;
  }
}

.scroll-cue span {
  font-size: 9px;
  letter-spacing: 0.36em;
  color: var(--faint);
}

@media (max-height: 760px) and (min-width: 721px) {
  .cake {
    transform: scale(0.84);
  }
  .cake-wrap {
    padding-top: 0;
  }
}

/* 手机上只缩不放：.cake 的 height 必须保持 520px——蜡烛、层胚、盘子全是按它
   做绝对定位的，一旦把盒子压矮，蜡烛就被压进蛋糕里不见了。 */
@media (max-width: 720px) {
  .sec--hero {
    justify-content: center;
    gap: clamp(14px, 3vh, 30px);
  }
  .cake {
    transform: scale(0.8);
  }
  .cake-wrap {
    flex: 0 0 auto;
    height: calc(520px * 0.8);
  }
  .cake__halo {
    width: 520px;
    height: 520px;
  }
  .hero__hint {
    letter-spacing: 0.18em;
    font-size: 15px;
  }
}

@media (max-width: 420px) {
  .cake {
    transform: scale(0.68);
  }
  .cake-wrap {
    height: calc(520px * 0.68);
  }
  .candles {
    gap: 30px;
  }
}

@media (max-height: 700px) and (max-width: 720px) {
  .cake {
    transform: scale(0.62);
  }
  .cake-wrap {
    height: calc(520px * 0.62);
  }
}

/* =======================================================================
   02 · 相识
   ======================================================================= */
.sec--chat {
  background: radial-gradient(
    700px 520px at 82% 42%,
    rgba(70, 102, 142, 0.12),
    transparent 64%
  );
}

.chat-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(26px, 5vw, 80px);
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
}

.chat-copy {
  max-width: 380px;
  padding-top: 6px;
}

.chat-intro {
  font-family: var(--serif);
  font-size: clamp(16px, 1.7vw, 19px);
  line-height: 2.1;
  letter-spacing: 0.03em;
  color: rgba(233, 236, 243, 0.72);
}

.chat-mark {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: clamp(26px, 5vh, 44px) 0;
  font-family: var(--num);
  font-size: 30px;
  letter-spacing: 0.08em;
  color: rgba(233, 192, 122, 0.55);
}

.chat-mark i {
  flex: 1;
  height: 1px;
  background: linear-gradient(
    90deg,
    rgba(233, 192, 122, 0.4),
    rgba(233, 192, 122, 0.04)
  );
}

.chat-foot {
  padding-left: 14px;
  border-left: 1px solid rgba(233, 192, 122, 0.35);
  font-family: var(--serif);
  font-size: 15px;
  line-height: 2;
  color: rgba(233, 192, 122, 0.72);
}

.chat-replay {
  margin-top: 24px;
}

/* ---------- 手机 ---------- */
.phone {
  position: relative;
  width: min(356px, 84vw);
  padding: 9px;
  border-radius: 36px;
  background: linear-gradient(160deg, #2a3140 0%, #121722 48%, #080b12 100%);
  box-shadow: 0 44px 90px rgba(0, 0, 0, 0.58),
    0 0 0 1px rgba(255, 255, 255, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.phone::after {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 28px;
  pointer-events: none;
  background: linear-gradient(
    128deg,
    rgba(255, 255, 255, 0.09) 0%,
    transparent 24%,
    transparent 76%,
    rgba(255, 255, 255, 0.03) 100%
  );
  z-index: 5;
}

.phone__notch {
  position: absolute;
  top: 9px;
  left: 50%;
  z-index: 6;
  width: 92px;
  height: 20px;
  transform: translateX(-50%);
  border-radius: 0 0 13px 13px;
  background: #0a0d14;
}

.phone__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 54px;
  padding: 12px 20px 0;
  border-radius: 28px 28px 0 0;
  background: #151a24;
  color: rgba(240, 243, 249, 0.9);
}

.phone__back {
  font-size: 22px;
  line-height: 1;
  color: rgba(240, 243, 249, 0.5);
}

.phone__name {
  font-size: 13px;
  letter-spacing: 0.12em;
}

.phone__more {
  font-size: 14px;
  letter-spacing: 0.1em;
  color: rgba(240, 243, 249, 0.45);
}

.phone__screen {
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: min(56vh, 470px);
  padding: 16px 12px 8px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
  background: radial-gradient(
      120% 80% at 50% 0%,
      rgba(60, 80, 110, 0.18),
      transparent 60%
    ),
    #0e121a;
}

.phone__screen::-webkit-scrollbar {
  display: none;
}

.phone__input {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px 16px;
  border-radius: 0 0 28px 28px;
  background: #151a24;
}

.phone__field {
  flex: 1;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 11px;
  color: rgba(240, 243, 249, 0.32);
}

.phone__send {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: rgba(62, 181, 117, 0.55);
}

/* ---------- 气泡 ---------- */
.msg {
  display: flex;
  align-items: flex-end;
  gap: 7px;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.msg.is-in {
  opacity: 1;
  transform: none;
}

.msg--me {
  flex-direction: row-reverse;
}

.msg__avatar {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  font-family: var(--serif);
  font-size: 12px;
  color: #f4e6cf;
  background: linear-gradient(140deg, #6c4a38, #3a2a20);
}

.msg--me .msg__avatar {
  background: linear-gradient(140deg, #3d5a72, #24323f);
}

.bubble {
  position: relative;
  max-width: 76%;
  padding: 9px 13px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.65;
  letter-spacing: 0.02em;
  word-break: break-word;
}

.msg--who .bubble {
  border-top-left-radius: 3px;
  background: #262c37;
  color: #e4e8ef;
}

.msg--me .bubble {
  border-top-right-radius: 3px;
  background: #3eb575;
  color: #082014;
}

.msg--date {
  justify-content: center;
  opacity: 0;
  transform: none;
}

.msg--date .chip {
  padding: 2px 9px;
  border-radius: 4px;
  font-size: 9px;
  letter-spacing: 0.1em;
  color: rgba(240, 243, 249, 0.35);
  background: rgba(255, 255, 255, 0.04);
}

.msg--system {
  justify-content: center;
  opacity: 0;
  transform: none;
}

.msg--system .chip {
  max-width: 84%;
  text-align: center;
  font-size: 9px;
  line-height: 1.7;
  color: rgba(240, 243, 249, 0.3);
}

.typing .bubble {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 14px;
}

.typing i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: rgba(233, 236, 243, 0.55);
  animation: typingDot 1.1s ease-in-out infinite;
}

.typing i:nth-child(2) {
  animation-delay: 0.15s;
}

.typing i:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes typingDot {
  0%,
  60%,
  100% {
    transform: translateY(0);
    opacity: 0.35;
  }
  30% {
    transform: translateY(-3px);
    opacity: 1;
  }
}

@media (max-width: 900px) {
  .chat-layout {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 34px;
  }
  .chat-copy {
    max-width: 560px;
    width: 100%;
    text-align: left;
  }
  .chat-foot {
    max-width: 420px;
  }
  .phone__screen {
    height: min(48vh, 420px);
  }
}

@media (max-width: 420px) {
  .phone {
    width: 88vw;
  }
  .phone__screen {
    height: 50vh;
  }
}

/* =======================================================================
   03 · 了解 · 星图
   ======================================================================= */
.sec--graph {
  background: radial-gradient(
    820px 600px at 50% 44%,
    rgba(86, 78, 140, 0.14),
    transparent 68%
  );
}

.graph-stage {
  position: relative;
  width: min(100%, 900px);
  height: clamp(440px, 58vh, 600px);
  margin: 0 auto;
}

.graph-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}

.graph-lines line {
  stroke: rgba(233, 192, 122, 0.16);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 2 8;
  animation: lineDrift 26s linear infinite;
}

@keyframes lineDrift {
  to {
    stroke-dashoffset: -200;
  }
}

.gnode {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  max-width: 150px;
  transform: translate(-50%, -50%) translate(var(--dx, 0px), var(--dy, 0px));
  color: rgba(233, 236, 243, 0.72);
  transition: left 0.95s var(--ease), top 0.95s var(--ease),
    transform 0.55s var(--ease), opacity 0.55s ease, color 0.4s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  will-change: transform;
}

/* 手指按不准 9px 的小圆点，给它一个看不见的大靶子 */
.gnode::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 4.5px;
  width: 42px;
  height: 42px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
}

.graph-stage.is-pushing .gnode {
  transition: left 0.95s var(--ease), top 0.95s var(--ease),
    transform 0.09s linear, opacity 0.55s ease, color 0.4s ease;
}

.gnode__dot {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(233, 192, 122, 0.8);
  box-shadow: 0 0 0 4px rgba(233, 192, 122, 0.08),
    0 0 16px rgba(233, 192, 122, 0.25);
  transition: transform 0.45s var(--ease), background 0.4s ease,
    box-shadow 0.4s ease, width 0.45s var(--ease), height 0.45s var(--ease);
}

.gnode__label {
  font-size: 13px;
  letter-spacing: 0.14em;
  white-space: nowrap;
  transition: font-size 0.5s var(--ease), color 0.4s ease;
}

.gnode__detail {
  width: min(300px, 70vw);
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  font-size: 13.5px;
  line-height: 1.95;
  letter-spacing: 0.02em;
  text-align: center;
  color: rgba(233, 236, 243, 0.62);
  transition: max-height 0.7s var(--ease), opacity 0.5s ease 0.1s,
    margin-top 0.7s var(--ease);
}

.gnode:hover .gnode__dot,
.gnode:focus-visible .gnode__dot {
  transform: scale(1.5);
  background: #f6d79c;
}

.gnode:hover .gnode__label,
.gnode:focus-visible .gnode__label {
  color: #fff;
}

.gnode--center .gnode__dot {
  width: 12px;
  height: 12px;
  background: #f6d79c;
  box-shadow: 0 0 0 6px rgba(233, 192, 122, 0.09),
    0 0 34px rgba(233, 192, 122, 0.4);
}

.gnode--center .gnode__label {
  font-family: var(--serif);
  font-size: 16px;
  letter-spacing: 0.24em;
  color: rgba(247, 231, 205, 0.92);
}

.graph-stage.has-active .gnode:not(.is-active) {
  opacity: 0.14;
  pointer-events: none;
}

.graph-stage.has-active .gnode__detail {
  pointer-events: none;
}

.gnode.is-active {
  left: 50% !important;
  top: 43% !important;
  z-index: 6;
  max-width: min(380px, 84vw);
  color: #fff;
}

.gnode.is-active .gnode__dot {
  width: 15px;
  height: 15px;
  background: var(--gold);
  box-shadow: 0 0 0 10px rgba(233, 192, 122, 0.08),
    0 0 40px rgba(233, 192, 122, 0.55);
}

.gnode.is-active .gnode__label {
  font-family: var(--serif);
  font-size: clamp(25px, 3.6vw, 34px);
  letter-spacing: 0.2em;
  text-indent: 0.2em;
}

.gnode.is-active .gnode__detail {
  max-height: 320px;
  opacity: 1;
  margin-top: 10px;
  font-size: 14px;
  line-height: 2;
  color: rgba(233, 236, 243, 0.68);
}

.graph-hint {
  position: absolute;
  left: 50%;
  bottom: -6px;
  transform: translateX(-50%);
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--faint);
  white-space: nowrap;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.graph-stage.has-active .graph-hint {
  opacity: 0;
}

.graph-close {
  position: absolute;
  right: 0;
  top: 0;
  z-index: 8;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: rgba(233, 236, 243, 0.6);
  font-size: 15px;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease, border-color 0.4s ease;
}

.graph-stage.has-active .graph-close {
  opacity: 1;
  pointer-events: auto;
}

.graph-close:hover {
  border-color: rgba(233, 192, 122, 0.5);
  color: var(--gold);
}

.graph-stage.has-active .gnode--center {
  opacity: 0.14;
}

.graph-stage.is-dense .gnode {
  max-width: 92px;
}

/* 星星多的时候标签难免会碰在一起，给每个标签一圈暗晕，压住了也还读得清 */
.graph-stage.is-dense .gnode__label {
  font-size: 11px;
  letter-spacing: 0.02em;
  text-shadow: 0 0 5px rgba(6, 10, 18, 0.95), 0 0 12px rgba(6, 10, 18, 0.85),
    0 1px 2px rgba(6, 10, 18, 0.9);
}

@media (max-width: 720px) {
  .graph-stage {
    height: clamp(420px, 62vh, 540px);
  }
  .gnode {
    max-width: 104px;
  }
  .gnode__label {
    font-size: 12px;
    letter-spacing: 0.04em;
  }
  .gnode--center .gnode__label {
    font-size: 14px;
  }
  .gnode__dot {
    width: 10px;
    height: 10px;
  }
  /* 手机上的靶子再大一圈 */
  .gnode::after {
    top: 5px;
    width: 50px;
    height: 50px;
  }
  .gnode__detail {
    font-size: 12.5px;
  }
  .gnode.is-active .gnode__detail {
    font-size: 13px;
  }
  .graph-stage.is-dense .gnode {
    max-width: 78px;
  }
  .graph-stage.is-dense {
    height: clamp(460px, 70vh, 600px);
  }
  .graph-stage.is-dense .gnode__label {
    font-size: 10px;
    letter-spacing: 0;
  }
  .graph-stage.is-dense .gnode::after {
    width: 44px;
    height: 44px;
  }
}

/* =======================================================================
   04 · 雾 · 车窗
   ======================================================================= */
.sec--fog {
  background: radial-gradient(
    760px 560px at 16% 18%,
    rgba(96, 126, 166, 0.12),
    transparent 62%
  );
}

.window {
  position: relative;
  width: min(100%, 880px);
  margin: 0 auto;
  padding: 13px;
  border-radius: 26px;
  background: linear-gradient(160deg, #232a36 0%, #11151e 46%, #070a10 100%);
  box-shadow: 0 44px 100px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(255, 255, 255, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.window__inner {
  position: relative;
  aspect-ratio: 16 / 9.4;
  border-radius: 15px;
  overflow: hidden;
  background: #0a0d14;
  cursor: crosshair;
  touch-action: none;
  box-shadow: inset 0 0 60px rgba(0, 0, 0, 0.65);
}

.window__reveal {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: clamp(22px, 4.6vw, 60px);
  background: radial-gradient(
      90% 90% at 74% 18%,
      rgba(110, 50, 60, 0.38),
      transparent 62%
    ),
    linear-gradient(160deg, #141a24 0%, #090c13 100%);
}

.window__reveal h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(20px, 2.8vw, 28px);
  letter-spacing: 0.24em;
  color: rgba(217, 139, 147, 0.92);
}

.window__reveal p {
  white-space: pre-line;
  font-family: var(--serif);
  font-size: clamp(13px, 1.6vw, 17px);
  line-height: 2.15;
  letter-spacing: 0.04em;
  color: rgba(233, 236, 243, 0.72);
}

#fogCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  transition: opacity 1.2s ease;
  touch-action: none;
}

#fogCanvas.is-clear {
  opacity: 0;
  pointer-events: none;
}

.window__glare {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    118deg,
    rgba(255, 255, 255, 0.07) 0%,
    transparent 26%,
    transparent 74%,
    rgba(255, 255, 255, 0.035) 100%
  );
}

.window__chrome {
  position: absolute;
  inset: 13px;
  border-radius: 15px;
  pointer-events: none;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.09),
    inset 0 0 24px rgba(0, 0, 0, 0.5);
}

.window__handle {
  position: absolute;
  right: 26px;
  bottom: -11px;
  width: 74px;
  height: 16px;
  border-radius: 8px;
  background: linear-gradient(180deg, #3a4250, #171c25);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 6px 14px rgba(0, 0, 0, 0.45);
}

.window__hint {
  position: absolute;
  left: 50%;
  bottom: 26px;
  z-index: 3;
  transform: translateX(-50%);
  padding: 6px 14px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.42);
  color: rgba(30, 44, 60, 0.8);
  font-size: 10px;
  letter-spacing: 0.24em;
  white-space: nowrap;
  pointer-events: none;
  backdrop-filter: blur(4px);
  transition: opacity 0.5s ease;
  animation: hintFloat 2.8s ease-in-out infinite;
}

@keyframes hintFloat {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(-4px);
  }
}

.window__hint.is-hidden {
  opacity: 0;
}

.fog-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 26px;
  min-height: 40px;
}

.fog-note {
  font-size: 10px;
  letter-spacing: 0.24em;
  color: rgba(217, 139, 147, 0.72);
  opacity: 0;
  transition: opacity 0.6s ease;
}

.fog-note.is-on {
  opacity: 1;
}

@media (max-width: 640px) {
  .window {
    padding: 9px;
    border-radius: 20px;
  }
  .window__inner {
    aspect-ratio: 4 / 4.4;
  }
  .window__chrome {
    inset: 9px;
    border-radius: 12px;
  }
  .window__reveal {
    padding: 24px 22px;
    gap: 12px;
  }
  .window__hint {
    bottom: 16px;
    font-size: 9px;
  }
}

/* =======================================================================
   05 · 循环 · 唱片
   ======================================================================= */
.sec--vinyl {
  background: radial-gradient(
    720px 600px at 26% 52%,
    rgba(190, 122, 56, 0.11),
    transparent 64%
  );
}

.vinyl-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.86fr);
  align-items: center;
  gap: clamp(30px, 5vw, 76px);
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
}

.turntable {
  position: relative;
  width: min(100%, 460px);
  aspect-ratio: 1;
  margin: 0 auto;
}

.platter {
  position: absolute;
  inset: 3%;
  border-radius: 50%;
  background: linear-gradient(155deg, #262b34, #0b0e14 58%, #05070b);
  box-shadow: 0 36px 80px rgba(0, 0, 0, 0.62),
    inset 0 0 0 1px rgba(255, 255, 255, 0.06),
    inset 0 2px 20px rgba(255, 255, 255, 0.05);
}

.vinyl {
  position: absolute;
  inset: 4.5%;
  border-radius: 50%;
  background: repeating-radial-gradient(
      circle at 50% 50%,
      #101014 0 1.5px,
      #191920 1.5px 3px,
      #0a0a0e 3px 6px
    ),
    #0b0b0f;
  box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.95),
    0 12px 30px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.vinyl::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(
    from 210deg,
    transparent 0deg,
    rgba(255, 240, 220, 0.09) 26deg,
    transparent 60deg,
    transparent 190deg,
    rgba(255, 240, 220, 0.05) 220deg,
    transparent 260deg
  );
  pointer-events: none;
}

.turntable.is-playing .vinyl {
  animation: spin 7.5s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.vinyl__label {
  position: absolute;
  left: 50%;
  top: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 36%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(
      circle at 36% 30%,
      #f6e3c4 0%,
      #e2bd8c 42%,
      #c08a55 78%,
      #9a6a3e 100%
    );
  box-shadow: inset 0 0 0 1px rgba(90, 50, 20, 0.25),
    inset 0 0 22px rgba(90, 50, 20, 0.25);
  color: #4a2c15;
  text-align: center;
}

.vinyl__label-a {
  font-family: var(--num);
  font-size: clamp(9px, 1.2vw, 12px);
  letter-spacing: 0.28em;
  text-indent: 0.28em;
}

.vinyl__label-sub {
  font-size: clamp(6px, 0.8vw, 8px);
  letter-spacing: 0.16em;
  color: rgba(74, 44, 21, 0.62);
}

.vinyl__hole {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 8px;
  height: 8px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #0a0a0e;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.1);
  display: none;
}

.tonearm {
  position: absolute;
  top: 4%;
  right: 5%;
  z-index: 4;
  width: 7px;
  height: 40%;
  transform: rotate(24deg);
  transform-origin: 50% 4%;
  border-radius: 4px;
  background: linear-gradient(90deg, #6c7480, #cfd6df 45%, #5c636e);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5);
  transition: transform 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.tonearm::before {
  content: "";
  position: absolute;
  top: -14px;
  left: 50%;
  width: 26px;
  height: 26px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #aab2bd, #4a515b 70%);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.tonearm i {
  position: absolute;
  left: 50%;
  bottom: -13px;
  width: 15px;
  height: 26px;
  transform: translateX(-50%);
  border-radius: 3px;
  background: linear-gradient(90deg, #3a4049, #8d949f 50%, #343a43);
}

.turntable.is-playing .tonearm {
  transform: rotate(9deg);
}

.vinyl-hit {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 5;
  width: 36%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1px solid rgba(74, 44, 21, 0);
  transition: border-color 0.4s ease, box-shadow 0.4s ease;
  font-size: 0;
}

.vinyl-hit:hover,
.vinyl-hit:focus-visible {
  border-color: rgba(255, 240, 214, 0.7);
  box-shadow: 0 0 0 6px rgba(255, 226, 180, 0.14);
}

.vinyl-hit::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  transform: translate(-40%, -50%);
  border-style: solid;
  border-width: 7px 0 7px 12px;
  border-color: transparent transparent transparent rgba(74, 44, 21, 0.55);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.turntable.is-playing .vinyl-hit::after {
  opacity: 0;
}

.vinyl-hit:hover::after {
  opacity: 1;
}

.vinyl-spindle {
  display: none;
}

.now {
  display: flex;
  align-items: center;
  gap: 15px;
  max-width: 420px;
  margin-bottom: 24px;
  padding: 12px 14px 12px 12px;
  border: 1px solid rgba(96, 72, 46, 0.16);
  border-radius: 12px;
  background: rgba(255, 252, 244, 0.62);
  box-shadow: 0 22px 44px -36px rgba(60, 40, 24, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.85);
  transition: border-color 0.6s ease, background 0.6s ease;
}

.turntable.is-playing ~ .lyrics-wrap .now {
  border-color: rgba(156, 54, 39, 0.28);
  background: rgba(255, 252, 244, 0.82);
}

.now__cover {
  width: 78px;
  height: 78px;
  flex: none;
  border-radius: 9px;
  object-fit: cover;
  filter: saturate(0.96);
  box-shadow: 0 14px 26px -18px rgba(60, 40, 24, 0.9);
}

.now__meta {
  flex: 1;
  min-width: 0;
}

.now__title {
  font-family: var(--serif);
  font-size: 14.5px;
  letter-spacing: 0.04em;
  color: #3a2c1e;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.now__by {
  margin-top: 5px;
  font-size: 10px;
  letter-spacing: 0.18em;
  color: rgba(70, 54, 38, 0.5);
}

.now__bar {
  position: relative;
  height: 2px;
  margin-top: 13px;
  border-radius: 2px;
  background: rgba(96, 72, 46, 0.14);
  overflow: hidden;
}

.now__bar i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: linear-gradient(90deg, rgba(156, 54, 39, 0.5), #9c3627);
}

.now__time {
  display: flex;
  justify-content: space-between;
  margin-top: 7px;
  font-size: 9.5px;
  letter-spacing: 0.14em;
  color: rgba(70, 54, 38, 0.45);
  font-variant-numeric: tabular-nums;
}

.lyrics-wrap {
  max-width: 420px;
}

.lyrics-hint {
  margin-bottom: 22px;
  font-size: 10px;
  letter-spacing: 0.34em;
  color: var(--faint);
  transition: color 0.4s ease;
}

.turntable.is-playing ~ .lyrics-wrap .lyrics-hint {
  color: rgba(233, 192, 122, 0.8);
}

.lyrics {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 300px;
}

.line {
  font-family: var(--serif);
  font-size: clamp(16px, 1.9vw, 20px);
  line-height: 1.8;
  letter-spacing: 0.05em;
  color: rgba(233, 236, 243, 0.22);
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.7s var(--ease), color 0.7s ease,
    transform 0.7s var(--ease);
}

.line.is-in {
  opacity: 1;
  transform: none;
}

.line.is-on {
  color: #f3e7d2;
}

.line.is-on::before {
  content: "";
  display: inline-block;
  width: 16px;
  height: 1px;
  margin-right: 12px;
  vertical-align: middle;
  background: var(--gold);
  box-shadow: 0 0 8px rgba(233, 192, 122, 0.7);
}

.lyrics-note {
  margin-top: 26px;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: rgba(233, 236, 243, 0.28);
}

@media (max-width: 900px) {
  .vinyl-layout {
    grid-template-columns: 1fr;
    gap: 26px;
    justify-items: center;
  }
  .turntable {
    max-width: 360px;
  }
  .lyrics-wrap {
    max-width: 520px;
    width: 100%;
    text-align: center;
  }
  .now {
    max-width: 360px;
    margin-inline: auto;
    text-align: left;
  }
  .now__cover {
    width: 72px;
    height: 72px;
  }
  .lyrics {
    min-height: 0;
    gap: 10px;
  }
  .line {
    font-size: 15px;
  }
  .line.is-on::before {
    width: 10px;
    margin-right: 8px;
  }
}

/* =======================================================================
   06 · 草稿
   ======================================================================= */
.sec--drafts {
  background: radial-gradient(
    700px 520px at 84% 82%,
    rgba(86, 76, 118, 0.1),
    transparent 62%
  );
}

.drafts-intro {
  max-width: 620px;
  margin: 0 auto clamp(24px, 4vh, 38px);
  text-align: center;
  font-family: var(--serif);
  font-size: clamp(14px, 1.7vw, 17px);
  letter-spacing: 0.06em;
  line-height: 2;
  color: rgba(233, 236, 243, 0.5);
}

.drafts {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
}

.draft {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.018);
  transition: border-color 0.5s ease, background 0.5s ease;
  opacity: 0;
  transform: translateY(18px);
}

.draft.is-in {
  opacity: 1;
  transform: none;
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease),
    border-color 0.5s ease, background 0.5s ease;
  transition-delay: var(--d, 0s);
}

.draft:hover {
  border-color: rgba(233, 192, 122, 0.24);
}

.draft.is-open {
  border-color: rgba(233, 192, 122, 0.3);
  background: rgba(233, 192, 122, 0.035);
}

.draft__btn {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  width: 100%;
  padding: 18px 22px;
  text-align: left;
}

.draft__date {
  font-family: var(--num);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: rgba(233, 192, 122, 0.5);
  white-space: nowrap;
}

.draft__text {
  overflow: hidden;
  font-size: 13.5px;
  line-height: 1.8;
  color: rgba(233, 236, 243, 0.76);
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color 0.4s ease;
}

.draft.is-open .draft__text {
  white-space: normal;
  color: rgba(245, 246, 250, 0.92);
}

.draft__status {
  font-size: 9px;
  letter-spacing: 0.24em;
  color: rgba(217, 139, 147, 0.55);
  white-space: nowrap;
}

.draft__status::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 4px;
  margin-right: 7px;
  border-radius: 50%;
  background: currentColor;
  vertical-align: middle;
  opacity: 0.7;
}

.draft.is-open .draft__status {
  color: rgba(233, 192, 122, 0.7);
}

.draft__more {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.55s var(--ease);
}

.draft.is-open .draft__more {
  grid-template-rows: 1fr;
}

.draft__more-inner {
  overflow: hidden;
}

.draft__note {
  padding: 0 22px 20px 128px;
  font-family: var(--serif);
  font-size: 12.5px;
  line-height: 1.9;
  color: rgba(233, 236, 243, 0.42);
}

/* ---------- 写字区 ---------- */
.composer {
  width: 100%;
  max-width: 700px;
  margin: clamp(34px, 6vh, 56px) auto 0;
}

.composer__prompt {
  display: block;
  margin-bottom: 14px;
  font-family: var(--serif);
  font-size: clamp(14px, 1.6vw, 16px);
  letter-spacing: 0.08em;
  color: rgba(233, 192, 122, 0.78);
}

.composer__box {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding: 8px 8px 8px 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.025);
  transition: border-color 0.4s ease, background 0.4s ease;
}

.composer__box:focus-within {
  border-color: rgba(233, 192, 122, 0.4);
  background: rgba(233, 192, 122, 0.035);
}

.composer textarea {
  flex: 1;
  min-height: 30px;
  max-height: 140px;
  padding: 8px 0;
  border: 0;
  outline: 0;
  resize: none;
  background: transparent;
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.9;
  color: rgba(245, 246, 250, 0.92);
}

.composer textarea::placeholder {
  color: rgba(233, 236, 243, 0.28);
}

.composer__note {
  min-height: 26px;
  margin-top: 12px;
  padding-left: 4px;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: rgba(233, 192, 122, 0.7);
  opacity: 0;
  transition: opacity 0.6s ease;
}

.composer__note.is-on {
  opacity: 1;
}

.composer.is-sent .composer__box {
  opacity: 0.4;
  pointer-events: none;
}

/* 纸飞机 */
.plane {
  position: fixed;
  z-index: 90;
  width: 38px;
  height: 38px;
  pointer-events: none;
  color: #f4e3c6;
  animation: planeFly 2.4s cubic-bezier(0.3, 0.1, 0.4, 1) forwards;
}

.plane svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 10px rgba(233, 192, 122, 0.45));
}

@keyframes planeFly {
  0% {
    opacity: 0;
    transform: translate(0, 0) rotate(-6deg) scale(0.5);
  }
  12% {
    opacity: 1;
    transform: translate(6px, -16px) rotate(-10deg) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(34vw, -58vh) rotate(18deg) scale(0.7);
  }
}

@media (max-width: 640px) {
  .draft__btn {
    grid-template-columns: 1fr auto;
    gap: 8px 12px;
    padding: 15px 16px;
  }
  .draft__date {
    grid-column: 1 / -1;
  }
  .draft__note {
    padding: 0 16px 16px;
  }
  .composer__box {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 12px 12px 12px 16px;
  }
  .composer__box .solid-btn {
    align-self: flex-end;
  }
}

/* =======================================================================
   07 · 十七件小事
   ======================================================================= */
.sec--numbers {
  background: radial-gradient(
    760px 640px at 50% 52%,
    rgba(160, 116, 56, 0.11),
    transparent 64%
  );
}

.number-stage {
  position: relative;
  width: min(88vw, 520px);
  aspect-ratio: 1;
  margin: 0 auto;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

.number-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.number-ring circle {
  fill: none;
  stroke: rgba(233, 192, 122, 0.16);
  stroke-width: 1;
}

.number-ring .ring-tick {
  stroke: rgba(233, 192, 122, 0.42);
  stroke-width: 1.2;
  transition: stroke 0.4s ease, stroke-width 0.4s ease;
}

.number-ring .ring-tick.is-on {
  stroke: #f3d59a;
  stroke-width: 2.4;
}

.number-hand {
  position: absolute;
  inset: 0;
  transform: rotate(var(--a, -90deg));
  transition: transform 0.55s var(--ease);
  pointer-events: none;
}

.number-hand i {
  position: absolute;
  left: 50%;
  top: 12.5%;
  width: 7px;
  height: 7px;
  margin-left: -3.5px;
  border-radius: 50%;
  background: #f6d79c;
  box-shadow: 0 0 0 6px rgba(233, 192, 122, 0.1),
    0 0 22px rgba(233, 192, 122, 0.7);
}

.number-core {
  position: absolute;
  inset: 24%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px;
  text-align: center;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(233, 192, 122, 0.06),
    transparent 68%
  );
}

.number-core__idx {
  font-family: var(--num);
  font-size: clamp(34px, 6vw, 56px);
  line-height: 1;
  letter-spacing: 0.04em;
  color: rgba(233, 192, 122, 0.9);
  transition: opacity 0.35s ease;
}

.number-core__text {
  max-width: 92%;
  font-family: var(--serif);
  font-size: clamp(13px, 1.8vw, 16.5px);
  line-height: 1.95;
  letter-spacing: 0.03em;
  color: rgba(233, 236, 243, 0.82);
  transition: opacity 0.35s ease;
}

.number-core.is-fading .number-core__idx,
.number-core.is-fading .number-core__text {
  opacity: 0;
}

.number-meta {
  margin-top: clamp(18px, 3vh, 30px);
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.26em;
  color: var(--faint);
}

.number-meta b {
  font-weight: 400;
  color: rgba(233, 192, 122, 0.85);
}

@media (max-width: 560px) {
  .number-stage {
    width: 92vw;
  }
  .number-core {
    inset: 25%;
  }
  .number-core__text {
    font-size: 12.5px;
    line-height: 1.8;
  }
}

/* =======================================================================
   08 · 信
   ======================================================================= */
.sec--letter {
  background: radial-gradient(
    860px 680px at 50% 44%,
    rgba(180, 134, 70, 0.12),
    transparent 66%
  );
}

.letter-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  margin-top: 4px;
}

.envelope {
  position: relative;
  width: min(78vw, 470px);
  aspect-ratio: 1.55;
  perspective: 1300px;
  filter: drop-shadow(0 40px 60px rgba(0, 0, 0, 0.55));
  transition: transform 1s var(--ease);
}

.envelope:hover {
  transform: translateY(-4px);
}

.env__shadow {
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -34px;
  height: 44px;
  border-radius: 50%;
  background: radial-gradient(
    ellipse,
    rgba(0, 0, 0, 0.55),
    transparent 70%
  );
  filter: blur(8px);
}

.env__body {
  position: absolute;
  inset: 0;
  border-radius: 5px;
  background: linear-gradient(158deg, #ecdbc0 0%, #dcc4a0 52%, #c9ad86 100%);
  box-shadow: inset 0 0 0 1px rgba(110, 80, 45, 0.22),
    inset 0 0 40px rgba(120, 84, 42, 0.16);
}

.env__letter {
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: 7%;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  height: 84%;
  border-radius: 3px;
  background: linear-gradient(180deg, #fdf6e7, #f6ead4);
  box-shadow: 0 -2px 10px rgba(90, 60, 25, 0.16);
  transition: transform 1.15s cubic-bezier(0.34, 1.1, 0.4, 1) 0.1s;
}

.env__letter span {
  font-family: var(--serif);
  font-size: clamp(12px, 1.6vw, 15px);
  letter-spacing: 0.3em;
  color: rgba(90, 62, 34, 0.68);
}

.env__letter i {
  width: 44px;
  height: 1px;
  background: rgba(90, 62, 34, 0.25);
}

.envelope.is-open .env__letter {
  transform: translateY(-34%);
}

.env__pocket {
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: 5px;
  background: linear-gradient(200deg, #e6d2b2 0%, #d8bf9a 46%, #cdb18a 100%);
  clip-path: polygon(0 0, 50% 54%, 100% 0, 100% 100%, 0 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.env__pocket::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
      118deg,
      rgba(255, 255, 255, 0.16) 0%,
      transparent 34%,
      transparent 66%,
      rgba(80, 50, 20, 0.12) 100%
    );
}

.env__flap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 4;
  height: 58%;
  border-radius: 5px 5px 0 0;
  background: linear-gradient(184deg, #f3e4cb 0%, #e4cfae 62%, #d8c29e 100%);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: 50% 0;
  transition: transform 1.1s cubic-bezier(0.5, 0, 0.3, 1),
    z-index 0s linear 0.5s;
  box-shadow: 0 2px 8px rgba(90, 60, 25, 0.12);
}

.envelope.is-open .env__flap {
  transform: rotateX(178deg);
  z-index: 1;
}

.env__from {
  position: absolute;
  left: 8%;
  bottom: 7%;
  z-index: 5;
  font-family: var(--serif);
  font-size: clamp(8px, 1vw, 10px);
  letter-spacing: 0.18em;
  color: rgba(90, 62, 34, 0.5);
  transition: opacity 0.5s ease;
}

.envelope.is-open .env__from {
  opacity: 0;
}

.env__seal {
  position: absolute;
  left: 50%;
  top: 54%;
  z-index: 6;
  width: clamp(56px, 8vw, 72px);
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(
      circle at 34% 26%,
      #b5494a 0%,
      #8e3138 46%,
      #611f27 100%
    );
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.45),
    inset 0 2px 4px rgba(255, 255, 255, 0.2),
    inset 0 -4px 10px rgba(40, 4, 8, 0.45);
  color: rgba(255, 236, 214, 0.9);
  transition: transform 0.5s var(--ease), opacity 0.6s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: none;
}

.env__seal:hover {
  transform: translate(-50%, -50%) scale(1.04);
}

.env__seal-num {
  position: relative;
  z-index: 2;
  font-family: var(--num);
  font-size: clamp(18px, 2.4vw, 23px);
  letter-spacing: 0.06em;
}

.env__seal-ring {
  position: absolute;
  inset: -7px;
  border-radius: 50%;
  background: conic-gradient(
    rgba(243, 213, 154, 0.95) calc(var(--p, 0) * 1%),
    rgba(255, 255, 255, 0.09) 0
  );
  -webkit-mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 3px),
    #000 calc(100% - 2px)
  );
  mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 3px),
    #000 calc(100% - 2px)
  );
  pointer-events: none;
}

.envelope.is-open .env__seal {
  opacity: 0;
  transform: translate(-50%, -50%) scale(1.25);
  pointer-events: none;
}

.letter-hint {
  font-size: 10px;
  letter-spacing: 0.32em;
  color: var(--faint);
  transition: color 0.4s ease;
}

.letter-hint.is-pressing {
  color: rgba(233, 192, 122, 0.85);
}

/* ---------- 信纸阅读层 ---------- */
.letter-view {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: clamp(10px, 3vh, 40px);
}

.letter-view[hidden] {
  display: none;
}

.letter-view__scrim {
  position: absolute;
  inset: 0;
  background: rgba(5, 7, 12, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  transition: opacity 0.7s ease;
}

.paper {
  position: relative;
  width: min(660px, 94vw);
  max-height: 88svh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: clamp(30px, 5.4vw, 62px) clamp(26px, 5vw, 60px)
    clamp(36px, 5vw, 56px);
  border-radius: 3px;
  color: #3a2c20;
  background: linear-gradient(180deg, #fbf3e3 0%, #f6ecd8 58%, #f0e3ca 100%);
  box-shadow: 0 50px 120px rgba(0, 0, 0, 0.65), inset 0 0 0 1px rgba(120, 90, 50, 0.12),
    inset 0 0 80px rgba(150, 110, 60, 0.08);
  opacity: 0;
  transform: translateY(34px) scale(0.98);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  scrollbar-width: thin;
  scrollbar-color: rgba(120, 90, 50, 0.3) transparent;
}

.paper::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: repeating-linear-gradient(
      0deg,
      transparent 0 31px,
      rgba(120, 90, 50, 0.055) 31px 32px
    ),
    radial-gradient(120% 60% at 90% 0%, rgba(255, 255, 255, 0.5), transparent 60%);
  opacity: 0.7;
}

.letter-view.is-open .letter-view__scrim {
  opacity: 1;
}

.letter-view.is-open .paper {
  opacity: 1;
  transform: none;
}

/* 内联纸页：直接长在第 9 页里，不遮挡整页。
   用 .paper.paper--inline 提高优先级——paper.css 在本文件之后加载，会盖掉 .paper 的 max-height。 */
.paper.paper--inline {
  width: min(620px, 100%);
  max-height: none;
  overflow: visible;
  margin: clamp(18px, 3.6vh, 34px) auto 0;
  padding: clamp(26px, 4.6vw, 52px) clamp(22px, 4.4vw, 50px)
    clamp(30px, 4.4vw, 48px);
  box-shadow: 0 26px 64px rgba(122, 92, 52, 0.16),
    0 2px 0 rgba(255, 255, 255, 0.5) inset, inset 0 0 0 1px rgba(120, 90, 50, 0.11);
  transform: translateY(16px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.paper--inline.is-open {
  opacity: 1;
  transform: none;
}

.paper--inline .paper__close {
  position: absolute;
  top: clamp(12px, 2.4vw, 20px);
  right: clamp(12px, 2.4vw, 20px);
  float: none;
  margin: 0;
}

/* 内联时印章不再绝对定位，改跟署名一起排在正文末尾，避免压住最后一段 */
.paper--inline .paper__seal {
  position: static;
  width: 58px;
  height: 58px;
  margin: 22px 0 0 auto;
  bottom: auto;
  right: auto;
}

@media (max-width: 700px) {
  .paper.paper--inline {
    padding: 34px 22px 34px;
    margin-top: 16px;
    border-radius: 2px;
  }

  .paper--inline .paper__body p {
    font-size: 15px;
    line-height: 2.15;
  }
}

.paper__close {
  position: sticky;
  top: 0;
  float: right;
  z-index: 3;
  margin: -12px -12px 0 0;
  padding: 6px 12px;
  border-radius: 99px;
  border: 1px solid rgba(90, 62, 34, 0.2);
  background: rgba(251, 243, 227, 0.9);
  color: rgba(90, 62, 34, 0.62);
  font-size: 9px;
  letter-spacing: 0.2em;
  backdrop-filter: blur(4px);
  transition: border-color 0.3s ease, color 0.3s ease;
}

.paper__close:hover {
  border-color: rgba(90, 62, 34, 0.5);
  color: #5a3e22;
}

.paper__to {
  font-family: var(--serif);
  font-size: clamp(17px, 2vw, 20px);
  letter-spacing: 0.18em;
  color: #4a3423;
  margin-bottom: 26px;
}

.paper__body p {
  margin-bottom: 18px;
  font-family: var(--serif);
  font-size: clamp(14px, 1.7vw, 16.5px);
  line-height: 2.2;
  letter-spacing: 0.045em;
  color: #453427;
  text-align: justify;
}

.paper__body p:last-child {
  margin-bottom: 0;
}

.paper__sign {
  margin-top: 34px;
  text-align: right;
  font-family: var(--serif);
  font-size: 14px;
  letter-spacing: 0.08em;
  color: #5c4430;
}

.paper__date {
  margin-top: 4px;
  text-align: right;
  font-family: var(--num);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: rgba(92, 68, 48, 0.6);
}

.paper__seal {
  position: absolute;
  right: clamp(20px, 5vw, 46px);
  bottom: clamp(24px, 4vw, 44px);
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border: 2px solid rgba(150, 40, 45, 0.55);
  border-radius: 50%;
  transform: rotate(-11deg);
  font-family: var(--serif);
  font-size: 10px;
  line-height: 1.4;
  letter-spacing: 0.12em;
  color: rgba(150, 40, 45, 0.7);
  text-align: center;
  opacity: 0.8;
  pointer-events: none;
}

/* ---------- 页脚 ---------- */
.site-end {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  padding: clamp(40px, 8vh, 80px) 24px clamp(50px, 9vh, 90px);
  text-align: center;
}

.site-end__line {
  font-family: var(--serif);
  font-size: clamp(13px, 1.6vw, 15px);
  letter-spacing: 0.32em;
  color: rgba(233, 192, 122, 0.6);
}

.paper__body p,
.paper__sign,
.paper__to {
  text-wrap: pretty;
}

@media (max-width: 560px) {
  .letter-stage {
    gap: 24px;
  }
  .envelope {
    width: 86vw;
  }
  .paper {
    max-height: 86svh;
  }
  .paper__body p {
    line-height: 2.1;
  }
}

/* ---------- 蛋糕尺寸收尾 ---------- */
.cake__plate {
  width: 410px;
  height: 40px;
}

.cake__halo {
  width: 720px;
  height: 720px;
}

@media (max-width: 720px) {
  .cake {
    transform: scale(0.82);
    height: 520px;
  }
}

@media (max-width: 420px) {
  .cake {
    transform: scale(0.72);
    height: 520px;
  }
}

@media (max-height: 700px) and (max-width: 720px) {
  .cake {
    transform: scale(0.66);
    height: 520px;
  }
}

/* ---------- 手机端首屏：蛋糕 + 文案作为一组居中，别再让上方空一大片 ---------- */
@media (max-width: 720px) {
  .sec--hero {
    justify-content: center;
    gap: 6px;
    padding-top: clamp(10px, 3vh, 34px);
    padding-bottom: clamp(16px, 3.6vh, 40px);
  }

  .cake-wrap {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    flex: 0 0 auto;
    height: calc(520px * 0.82);
    padding-top: 0;
  }

  .hero__foot {
    flex: 0 0 auto;
  }
}

@media (max-width: 420px) {
  .cake-wrap {
    height: calc(520px * 0.72);
  }
}

@media (max-height: 700px) and (max-width: 720px) {
  .cake-wrap {
    height: calc(520px * 0.66);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .grain {
    animation: none;
  }
}
