/* 节日灯笼红包雨 · 全站漂浮层 */

.ln-g-stage {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9989;
  overflow: hidden;
  transform: translateZ(0);
  will-change: transform;
}

/* ---------- 灯笼 ---------- */
.lg-deng-box {
  position: absolute;
  top: 18px;
  pointer-events: none;
  margin: 0;
  padding: 0;
}
.lg-db1 { right: 46px; }
.lg-db2 { right: 128px; }
.lg-db3 { left: 128px; }
.lg-db4 { left: 46px; }

.lg-deng {
  position: relative;
  width: 76px;
  height: 58px;
  background: linear-gradient(135deg, rgba(216, 0, 15, .92), rgba(154, 6, 8, .96));
  border-radius: 50% 50%;
  transform-origin: 50% -66px;
  box-shadow: -3px 3px 15px 1px rgba(250, 108, 0, .55), inset 0 0 10px rgba(255, 255, 255, .18);
  border: 1px solid rgba(255, 210, 90, .35);
  animation: lg-swing 4s infinite ease-in-out;
}
.lg-db2 .lg-deng { animation-duration: 4.5s; animation-delay: .3s; }
.lg-db3 .lg-deng { animation-duration: 3.8s; animation-delay: .1s; }
.lg-db4 .lg-deng { animation-duration: 4.2s; animation-delay: .2s; }

@keyframes lg-swing {
  0%, 100% { transform: rotate(-7deg); }
  50% { transform: rotate(7deg); }
}

.lg-a {
  width: 66px;
  height: 48px;
  margin: 8px 5px 5px 5px;
  border-radius: 50% 50%;
  border: 1px solid rgba(220, 143, 3, .4);
  background: radial-gradient(60% 60% at 35% 30%, rgba(255, 190, 150, .16), rgba(216, 0, 15, .06));
}
.lg-b {
  width: 30px;
  height: 40px;
  margin: 4px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lg-t {
  font-size: 18px;
  color: #ffe08a;
  font-weight: 700;
  line-height: 1;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .8), 0 0 6px rgba(255, 215, 0, .5);
}
.lg-xian {
  position: absolute;
  top: -14px;
  left: 37px;
  width: 1px;
  height: 14px;
  background: linear-gradient(to bottom, #dc8f03, #ffa500);
  box-shadow: 0 0 3px rgba(255, 165, 0, .5);
}
.lg-deng::before {
  content: " ";
  position: absolute;
  top: -5px;
  left: 18px;
  height: 8px;
  width: 40px;
  border-radius: 3px 3px 0 0;
  border: solid 1px rgba(220, 143, 3, .8);
  background: linear-gradient(90deg, #dc8f03, #ffc107, #ffa500, #ffc107, #dc8f03);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6), 0 1px 2px rgba(0, 0, 0, .2);
}
.lg-deng::after {
  content: " ";
  position: absolute;
  bottom: -5px;
  left: 18px;
  height: 8px;
  width: 40px;
  border-radius: 0 0 3px 3px;
  border: solid 1px rgba(220, 143, 3, .8);
  background: linear-gradient(90deg, #dc8f03, #ffc107, #ffa500, #ffc107, #dc8f03);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, .6), 0 -1px 2px rgba(0, 0, 0, .2);
}
.lg-shui { position: absolute; bottom: -26px; left: 50%; transform: translateX(-50%); }
.lg-shui-c {
  width: 7px;
  height: 20px;
  background: linear-gradient(to bottom, #dc8f03, #ffa500);
  border-radius: 0 0 3px 3px;
  box-shadow: 0 0 3px rgba(255, 165, 0, .6);
}
.lg-shui-b {
  position: absolute;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(135deg, #dc8f03, #ffa500);
  box-shadow: 0 0 3px rgba(255, 165, 0, .6);
}

/* ---------- 红包 ---------- */
.lg-pkts { position: absolute; inset: 0; pointer-events: none; }

.lg-pkt {
  position: absolute;
  top: -76px;
  width: 36px;
  height: 46px;
  border-radius: 7px;
  background: linear-gradient(140deg, #ffe889 0%, #f7cb35 42%, #d29a10 78%, #b07c08 100%);
  box-shadow: 0 4px 12px rgba(120, 70, 0, .34), 0 0 12px rgba(255, 186, 60, .45), inset 0 0 10px rgba(255, 250, 205, .55);
  border: 1px solid rgba(255, 240, 175, .85);
  pointer-events: auto;
  cursor: pointer;
  will-change: transform, top;
  animation: lg-fall linear forwards, lg-rock 2.4s ease-in-out infinite;
  transform: translateZ(0);
}
.lg-pkt::before {
  content: "福";
  position: absolute;
  top: 54%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #a8100b;
  font-size: 16px;
  font-weight: 700;
  text-shadow: 0 1px 1px rgba(255, 253, 230, .75);
}
.lg-pkt::after {
  content: "";
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 8px;
  background: linear-gradient(180deg, #fff4c2, #e9b52c);
  border-radius: 4px 4px 2px 2px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .3);
}
.lg-pkt.hit { animation-play-state: paused; transform: scale(1.16); }

@keyframes lg-fall {
  0% { top: -76px; opacity: 0; }
  8% { opacity: 1; }
  92% { opacity: 1; }
  100% { top: 106%; opacity: 0; }
}
@keyframes lg-rock {
  0%, 100% { rotate: -7deg; }
  50% { rotate: 7deg; }
}

/* ---------- 飘字 ---------- */
.lg-floats { position: absolute; inset: 0; pointer-events: none; }
.lg-float {
  position: absolute;
  transform: translate(-50%, -50%);
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
  animation: lg-pop 1.8s ease-out forwards;
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
}
.lg-float.hit { color: #e01a06; font-size: 19px; -webkit-text-stroke: 1.4px #fff; paint-order: stroke fill; }
.lg-float.empty { color: #a01006; font-size: 16px; -webkit-text-stroke: 1.4px #fff; paint-order: stroke fill; }
.lg-float.blocked { color: #b3310a; font-size: 16px; -webkit-text-stroke: 1.4px #fff; paint-order: stroke fill; }

@keyframes lg-pop {
  0% { opacity: 0; transform: translate(-50%, -30%) scale(.85); }
  18% { opacity: 1; transform: translate(-50%, -60%) scale(1.12); }
  70% { opacity: 1; transform: translate(-50%, -135%) scale(1.04); }
  100% { opacity: 0; transform: translate(-50%, -195%) scale(1); }
}

/* ---------- 烟花 ---------- */
.lg-fw { position: absolute; inset: 0; pointer-events: none; }
.lg-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  animation: lg-burst 1.5s ease-out forwards;
}
@keyframes lg-burst {
  0% { opacity: 1; transform: translate(0, 0) scale(1); }
  100% { opacity: 0; transform: translate(var(--x), var(--y)) scale(.55); }
}

/* ---------- 场外开抢倒计时 ---------- */
.lg-box {
  position: fixed;
  top: 48px;
  left: 10px;
  right: 10px;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 0;
  padding: 0;
  z-index: 9992;
  pointer-events: none;
  white-space: nowrap;
  font-family: "Microsoft YaHei", "PingFang SC", "SimHei", sans-serif;
}

.lg-center {
  color: #c4140a;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 2px;
  text-align: center;
  text-shadow: 0 1px 2px rgba(255, 255, 255, .85), 0 1px 3px rgba(120, 10, 0, .35);
}
@keyframes lg-float {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, -5px); }
}

.lg-hint {
  margin-top: 8px;
  color: #8c0f04;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .5px;
  text-align: center;
  pointer-events: auto;
  cursor: pointer;
  text-shadow: 0 1px 0 rgba(255, 255, 255, .6);
}
.lg-hint:active { opacity: .82; }

/* ---------- 手机端 ---------- */
@media screen and (max-width: 700px) {
  .lg-deng-box { top: 10px; transform: scale(.74); transform-origin: top center; }
  .lg-db1 { right: 4px; }
  .lg-db2 { right: 54px; }
  .lg-db3 { left: 54px; }
  .lg-db4 { left: 4px; }
  .lg-deng { width: 52px; height: 40px; }
  .lg-a { width: 44px; height: 32px; margin: 6px 3px 3px 3px; }
  .lg-b { width: 20px; height: 28px; margin-top: 2px; }
  .lg-t { font-size: 14px; }
  .lg-deng::before, .lg-deng::after { width: 28px; left: 12px; height: 6px; }
  .lg-xian { left: 25px; }
  .lg-shui { bottom: -20px; }
  .lg-shui-c { height: 14px; }
  .lg-pkt { width: 30px; height: 39px; border-radius: 6px; }
  .lg-pkt::before { font-size: 13px; }
  .lg-pkt::after { width: 17px; height: 7px; }
  .lg-float { font-size: 14px; }
  .lg-box { top: 46px; }
  .lg-center { font-size: 15px; letter-spacing: 1.2px; }
  .lg-hint { margin-top: 8px; font-size: 11px; letter-spacing: .2px; }
}
