/* ===== 上帝墙（匿名信墙版） ===== */
.wall-hero { text-align: center; padding: 8vh 6vw 3vh; }
.wall-hero h1 {
  font-family: var(--serif); font-size: clamp(2rem, 5vw, 3rem); letter-spacing: 10px;
  background: linear-gradient(180deg, #fff8e3, var(--gold-bright) 70%, var(--gold));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}

/* --- 暖色信墙 --- */
.wall-panel {
  position: relative; max-width: 980px; margin: 0 auto 60px;
  padding: 44px 34px 40px; border-radius: 18px; overflow: hidden;
  background:
    radial-gradient(ellipse 45% 32% at 18% 22%, rgba(255, 240, 200, .4), transparent 70%),
    radial-gradient(ellipse 38% 30% at 80% 62%, rgba(255, 232, 180, .3), transparent 70%),
    linear-gradient(168deg, #e8dabb 0%, #d9c69c 52%, #c8ae7d 100%);
  border: 1px solid rgba(150, 120, 70, .55);
  box-shadow: inset 0 0 70px rgba(120, 90, 40, .28), 0 26px 70px rgba(0, 0, 0, .45);
}
/* 墙面顶光 */
.wall-light {
  position: absolute; top: -40%; left: 50%; transform: translateX(-50%);
  width: 70%; height: 90%;
  background: radial-gradient(ellipse at center, rgba(255, 244, 210, .55), transparent 65%);
  pointer-events: none; animation: lightBreath 6s ease-in-out infinite;
}
@keyframes lightBreath { 50% { opacity: .6; } }

/* --- 挂绳与小信封 --- */
.wall-string { position: relative; display: flex; justify-content: space-around; padding: 18px 8px 26px; }
.wall-string::before {
  content: ""; position: absolute; left: 1%; right: 1%; top: 6px; height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, rgba(122, 88, 44, .6) 6%, rgba(122, 88, 44, .6) 94%, transparent);
  box-shadow: 0 2px 3px rgba(60, 40, 10, .2);
}
.env-slot { display: flex; flex-direction: column; align-items: center; }
.env-wrap {
  position: relative; width: 2px; height: 14px;
  background: rgba(122, 88, 44, .5);
  transform-origin: top center;
  animation: sway ease-in-out infinite;
}
@keyframes sway { 0%, 100% { transform: rotate(-3.5deg); } 50% { transform: rotate(3.5deg); } }
.env {
  position: absolute; top: 14px; left: 50%; transform: translateX(-50%);
  width: 22px; height: 16px; border-radius: 2px;
  background: linear-gradient(180deg, #fff9ea 0%, #f2e4c2 100%);
  border: 1px solid rgba(150, 120, 60, .6);
  box-shadow: 0 3px 5px rgba(60, 40, 10, .3);
  transition: box-shadow .3s, transform .3s;
}
/* 信封盖 */
.env::before {
  content: ""; position: absolute; top: -1px; left: -1px; right: -1px; height: 8px;
  background: linear-gradient(180deg, #eadfbc, #e2d3a8);
  border: 1px solid rgba(150, 120, 60, .45); border-bottom: none;
  border-radius: 2px 2px 0 0;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
}
.env.real { cursor: pointer; }
.env.real:hover { box-shadow: 0 3px 5px rgba(60,40,10,.3), 0 0 14px rgba(255, 214, 120, .95); }
/* 匹配发光后弹走 */
.env.found {
  animation: foundGlow .8s ease forwards;
}
@keyframes foundGlow {
  40% { box-shadow: 0 0 0 rgba(255, 220, 130, 0); transform: translateX(-50%) scale(1.5); }
  100% { box-shadow: 0 0 26px rgba(255, 220, 130, 1); transform: translateX(-50%) scale(0); opacity: 0; }
}
/* 找不到时墙体轻晃 */
.wall-panel.shake { animation: wallShake .5s ease; }
@keyframes wallShake {
  20% { transform: translateX(-7px); } 40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); } 80% { transform: translateX(3px); }
}

/* --- 寻信输入 --- */
.find-bar {
  position: relative; display: flex; gap: 14px; align-items: center; justify-content: center;
  margin-top: 8px; flex-wrap: wrap;
}
.find-input-wrap {
  position: relative; flex: 1; max-width: 430px;
  background: rgba(255, 250, 235, .92);
  border: 1px solid rgba(150, 120, 60, .5); border-radius: 999px;
  box-shadow: inset 0 2px 6px rgba(120, 90, 40, .18);
  display: flex; align-items: center;
}
.find-icon { padding: 0 4px 0 16px; font-size: .95rem; opacity: .8; }
#find-pw {
  flex: 1; border: none; outline: none; background: transparent;
  padding: 13px 18px 13px 8px; font-size: .95rem; color: #4a3a1c;
  letter-spacing: 2px;
}
#find-pw::placeholder { color: rgba(90, 70, 30, .5); letter-spacing: 1px; }
.find-bar .btn {
  padding: 12px 30px; font-size: .95rem;
  background: linear-gradient(135deg, #cfa53d, #b8912a);
  color: #fff8e3; box-shadow: 0 4px 18px rgba(150, 110, 30, .45);
}
.find-msg {
  text-align: center; margin-top: 16px; min-height: 1.5em;
  font-size: .88rem; color: #6b5426; letter-spacing: 1px; line-height: 1.8;
}

/* --- 墙面光尘 --- */
.wall-dust { position: absolute; inset: 0; pointer-events: none; }
.dust {
  position: absolute; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 244, 200, .95), rgba(255, 230, 170, .2) 60%, transparent);
  animation: dustFloat linear infinite;
}
@keyframes dustFloat {
  0% { transform: translateY(0); opacity: 0; }
  15% { opacity: .8; }
  100% { transform: translateY(-70px) translateX(18px); opacity: 0; }
}

/* --- 弹出的信封排列区 --- */
.tray-section {
  max-width: 980px; margin: 0 auto 90px; text-align: center; padding: 0 5vw;
  animation: trayIn .7s ease both;
}
@keyframes trayIn { from { opacity: 0; transform: translateY(40px); } }
.tray-title { font-family: var(--serif); font-size: 1.4rem; letter-spacing: 4px; color: var(--gold-bright); }
.tray-sub { margin: 10px 0 34px; opacity: .65; font-size: .9rem; letter-spacing: 2px; }
.tray-grid { display: flex; flex-wrap: wrap; gap: 26px; justify-content: center; }
.tray-card {
  position: relative; cursor: pointer; width: 138px; padding: 30px 14px 22px;
  border-radius: 12px; text-align: center;
  background: linear-gradient(170deg, #fff9ea 0%, #efe0bd 100%);
  border: 1px solid rgba(160, 128, 66, .55);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .38), 0 0 24px rgba(255, 220, 130, .22);
  color: #4a3a1c;
  transition: transform .25s ease, box-shadow .25s ease;
  animation: popOut .6s cubic-bezier(.18, .9, .32, 1.35) both;
}
@keyframes popOut {
  0% { opacity: 0; transform: translateY(90px) scale(.3) rotate(-8deg); }
  100% { opacity: 1; transform: translateY(0) scale(1) rotate(0); }
}
.tray-card:hover {
  transform: translateY(-8px) rotate(-1deg);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .45), 0 0 34px rgba(255, 220, 130, .45);
}
.tray-card .wax-seal {
  width: 46px; height: 46px; margin: 0 auto 12px; font-size: 1.1rem;
  display: flex; align-items: center; justify-content: center; border-radius: 50%;
  color: #ffe9b8;
  background: radial-gradient(circle at 35% 30%, #c0392b, #8e2216 70%);
  box-shadow: inset 0 2px 4px rgba(255,255,255,.3), 0 3px 8px rgba(0,0,0,.35);
}
.tray-card .t-date { font-size: .74rem; opacity: .55; letter-spacing: 1px; }
.tray-card .t-tip { margin-top: 10px; font-size: .76rem; opacity: .6; letter-spacing: 1px; }

/* --- 空态 --- */
.wall-empty { text-align: center; padding: 40px 0 90px; }
.empty-dove { font-size: 3rem; margin-bottom: 18px; display: inline-block; animation: floaty 2.4s ease-in-out infinite; }
.wall-empty p { font-family: var(--serif); letter-spacing: 3px; opacity: .8; }
.wall-empty .empty-sub { opacity: .5; margin: 8px 0 30px; font-size: .9rem; }

/* ===== 信纸模态框 ===== */
.letter-modal {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  background: rgba(4, 6, 16, .78);
  backdrop-filter: blur(6px);
}
.letter-paper {
  width: min(560px, 94vw); max-height: 86vh; overflow-y: auto;
  padding: 46px 44px 40px; border-radius: 8px; text-align: center;
  background: linear-gradient(rgba(255,252,240,.94), rgba(255,252,240,.94)),
    repeating-linear-gradient(0deg, transparent, transparent 30px, rgba(120, 90, 40, .06) 31px);
  color: #3a2c14;
  border: 1px solid rgba(180, 140, 60, .45);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .6), 0 0 60px rgba(240, 207, 107, .2);
  animation: paperUnfold .5s cubic-bezier(.2, .9, .3, 1.2) both;
}
@keyframes paperUnfold { from { opacity: 0; transform: translateY(50px) rotate(-2deg) scale(.92); } }
.letter-quote {
  font-size: .88rem; opacity: .7; line-height: 1.9; text-align: left;
  padding: 4px 18px; border-left: 3px solid rgba(180, 140, 60, .4);
}
.letter-reply {
  margin-top: 26px; font-family: var(--serif);
  font-size: 1.02rem; line-height: 2.2; letter-spacing: 1px; white-space: pre-wrap;
}
.letter-sign { margin-top: 20px; font-size: .82rem; opacity: .55; letter-spacing: 3px; }
.letter-body .btn.ghost { color: #6b5426; border-color: #a3801e; margin-top: 28px; }

@media (max-width: 640px) {
  .wall-panel { padding: 28px 14px 28px; }
  .find-bar { gap: 10px; }
  .letter-paper { padding: 34px 22px 30px; }
}
