/* 年度足迹 H5 —— 深色沉浸式分屏滚动 */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { background: #07080d; }
body { font-family: -apple-system, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; color: #e8ebf5; }

#app { width: 100%; max-width: 480px; margin: 0 auto; height: calc(var(--vh, 100vh)); position: relative; box-shadow: 0 0 60px rgba(0,0,0,.8); }
@media (min-width: 700px) { body { background: #07080d radial-gradient(ellipse at 50% 0%, #171a2b 0%, #07080d 70%); } }

.slides {
  height: 100%;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.slides::-webkit-scrollbar { display: none; }

.slide {
  height: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 30px 70px;
  position: relative;
  overflow: hidden;
}
.s-cover   { background: linear-gradient(180deg, #1b0f18 0%, #12141f 55%, #0e1018 100%); }
.s-watch   { background: linear-gradient(180deg, #0e1018, #131a2e); }
.s-danmu   { background: linear-gradient(180deg, #131a2e, #1c1226); }
.s-comment { background: linear-gradient(180deg, #1c1226, #101725); }
.s-like    { background: linear-gradient(180deg, #101725, #191224); }
.s-fav     { background: linear-gradient(180deg, #191224, #12141f); }
.s-companion { background: linear-gradient(180deg, #12141f, #101b26); }
.s-life    { background: linear-gradient(180deg, #101b26, #1a1420); }
.s-badge   { background: linear-gradient(180deg, #1a1420, #241019); }
.s-share   { background: linear-gradient(180deg, #241019, #12141f); }
.mode-site .s-life { background: linear-gradient(180deg, #101b26, #1b0f18); }

/* 入场动画 */
.slide .tag, .slide h2, .slide .big, .slide .cap, .slide .row2,
.slide .story, .slide .rank, .slide .badge-title, .slide .badge-desc,
.slide .chips, .slide .avatar, .slide .nick, .slide .join, .slide .card-wrap,
.slide .hint, .slide .btns, .slide .year-badge, .slide .site-title, .slide .site-logo, .slide .note {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s ease, transform .7s ease;
}
.slide.active .tag, .slide.active h2, .slide.active .big, .slide.active .cap,
.slide.active .row2, .slide.active .story, .slide.active .rank,
.slide.active .badge-title, .slide.active .badge-desc, .slide.active .chips,
.slide.active .avatar, .slide.active .nick, .slide.active .join,
.slide.active .card-wrap, .slide.active .hint, .slide.active .btns,
.slide.active .year-badge, .slide.active .site-title, .slide.active .site-logo, .slide.active .note {
  opacity: 1;
  transform: none;
}
.slide.active *:nth-child(2) { transition-delay: .12s; }
.slide.active *:nth-child(3) { transition-delay: .22s; }
.slide.active *:nth-child(4) { transition-delay: .32s; }
.slide.active *:nth-child(5) { transition-delay: .42s; }
.slide.active *:nth-child(n+6) { transition-delay: .5s; }

/* 文本元素 */
.tag { font-size: 11px; letter-spacing: 4px; color: #e52958; font-weight: 700; margin-bottom: 14px; }
h2 { font-size: 15px; font-weight: 400; color: #8891a8; letter-spacing: 2px; margin-bottom: 34px; }
.big {
  font-size: 62px; font-weight: 900; line-height: 1.15;
  background: linear-gradient(180deg, #ffffff 30%, #ffb3c4);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #fff;
  margin-bottom: 10px; word-break: break-all;
}
.big.gold { background: linear-gradient(180deg, #ffe9c4 20%, #c07c32); -webkit-background-clip: text; background-clip: text; }
.big.dim { background: none; -webkit-text-fill-color: #3d4459; color: #3d4459; font-size: 44px; }
.cap { font-size: 14px; color: #98a1bd; margin-bottom: 26px; line-height: 1.8; }
.row2 { display: flex; gap: 18px; margin-bottom: 26px; }
.row2 > div { min-width: 120px; padding: 16px 14px; background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.07); border-radius: 14px; }
.row2 i { display: block; font-style: normal; font-size: 24px; font-weight: 800; color: #fff; margin-bottom: 6px; }
.row2 em { display: block; font-style: normal; font-size: 12px; color: #8891a8; }
.story { font-size: 15px; line-height: 2; color: #c6cde2; max-width: 320px; margin-bottom: 10px; }
.story a { color: #ff5c82; text-decoration: none; }
.story.big-story { font-size: 19px; line-height: 2; }
.note { font-size: 12px; color: #5d657e; margin-top: 14px; }

/* 封面 */
.year-badge { display: inline-block; padding: 7px 20px; border: 1px solid rgba(229,41,88,.65); color: #ff5c82; border-radius: 999px; font-size: 13px; letter-spacing: 3px; margin-bottom: 30px; }
.avatar { width: 76px; height: 76px; border-radius: 50%; border: 2px solid rgba(255,255,255,.22); object-fit: cover; margin-bottom: 18px; }
.avatar-txt { background: linear-gradient(135deg, #e52958, #ff7a9e); color: #fff; font-size: 34px; font-weight: 800; line-height: 76px; text-align: center; }
.nick { font-size: 26px; font-weight: 800; margin-bottom: 10px; }
.join { font-size: 14px; color: #98a1bd; }
.site-logo { width: 66px; height: 66px; border-radius: 18px; background: linear-gradient(135deg, #e52958, #ff7a9e); color: #fff; font-size: 26px; font-weight: 900; line-height: 66px; margin-bottom: 26px; }
.site-title { font-size: 38px; font-weight: 900; letter-spacing: 2px; margin-bottom: 12px; }
.swipe-hint { position: absolute; bottom: 38px; left: 0; right: 0; font-size: 12px; color: #5d657e; letter-spacing: 2px; }
.swipe-hint .arr { display: block; font-size: 16px; color: #e52958; margin-top: 6px; animation: bob 1.6s ease-in-out infinite; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(7px); } }

/* 徽章/总结 */
.badge-title {
  font-size: 40px; font-weight: 900; letter-spacing: 4px; margin-bottom: 12px;
  background: linear-gradient(180deg, #ffe9c4 20%, #c07c32); -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #e8c48a;
}
.badge-desc { font-size: 14px; color: #98a1bd; margin-bottom: 28px; }
.chips { margin-bottom: 30px; }
.chip { display: inline-block; padding: 7px 16px; margin: 4px 5px; border: 1px solid rgba(229,41,88,.5); color: #ff8aa5; border-radius: 999px; font-size: 13px; }

/* 榜单 */
.rank { list-style: none; text-align: left; width: 100%; max-width: 330px; margin-bottom: 14px; }
.rank li { padding: 11px 2px; border-bottom: 1px solid rgba(255,255,255,.07); font-size: 15px; color: #dfe3ef; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.rank li b { color: #e8c48a; font-weight: 800; margin-right: 10px; }
.rank li span { float: right; color: #8891a8; font-size: 13px; padding-left: 10px; }
.rank li a { color: #dfe3ef; text-decoration: none; }
.rank.wide li { white-space: normal; }
.rank.wide li span { float: right; }

/* 分享卡 */
.card-wrap { position: relative; width: 240px; margin-bottom: 18px; }
.card-wrap canvas, .card-wrap img { width: 100%; border-radius: 14px; display: block; box-shadow: 0 12px 40px rgba(0,0,0,.55); }
.card-wrap img { display: none; }
.card-wrap .load { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8891a8; font-size: 13px; background: rgba(18,20,31,.6); border-radius: 14px; }
.hint { font-size: 12px; color: #8891a8; margin-bottom: 24px; }

/* 按钮 */
.btns { display: flex; gap: 14px; margin-top: 10px; flex-wrap: wrap; justify-content: center; }
.btn { display: inline-block; padding: 13px 30px; border-radius: 999px; font-size: 15px; text-decoration: none; font-weight: 600; }
.btn.primary { background: linear-gradient(90deg, #e52958, #ff5c82); color: #fff; box-shadow: 0 8px 24px rgba(229,41,88,.35); }
.btn.ghost { border: 1px solid #39415e; color: #aeb6cf; }

/* 进度点 */
.dots { position: fixed; right: 10px; top: 50%; transform: translateY(-50%); z-index: 9; display: flex; flex-direction: column; gap: 9px; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.22); cursor: pointer; transition: all .3s; }
.dots i.on { background: #e52958; transform: scale(1.5); }
@media (max-width: 560px) { .dots { right: 6px; } }

/* ===== v2 增强：动画与新增屏 ===== */
/* 封面/致谢光斑 */
.orb { position: absolute; border-radius: 50%; filter: blur(42px); opacity: .55; animation: float 9s ease-in-out infinite; pointer-events: none; }
.o1 { width: 220px; height: 220px; background: rgba(229,41,88,.34); top: -50px; left: -70px; }
.o2 { width: 180px; height: 180px; background: rgba(120,68,192,.28); bottom: 30px; right: -60px; animation-delay: 2.2s; }
.o3 { width: 120px; height: 120px; background: rgba(255,138,165,.24); top: 42%; left: 62%; animation-delay: 4.4s; }
@keyframes float { 0%, 100% { transform: translate(0,0) scale(1); } 33% { transform: translate(18px,-14px) scale(1.07); } 66% { transform: translate(-14px,12px) scale(.95); } }

/* cc娘 素材位（/statics/annual/mascot.png，文件不存在自动隐藏） */
.mascot { width: 110px; margin-bottom: 10px; opacity: 0; transition: opacity 1s ease .3s; animation: bob 2.4s ease-in-out infinite; filter: drop-shadow(0 6px 18px rgba(229,41,88,.4)); }
.mascot.small { width: 84px; }
.slide.active .mascot { opacity: 1; }

/* 弹幕飞屏背景 */
.streaks { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.streaks i { position: absolute; left: 105%; font-size: 15px; font-style: normal; color: rgba(255,255,255,.15); white-space: nowrap; animation: fly 8s linear infinite; }
@keyframes fly { from { left: 105%; } to { left: -40%; } }

/* 弹幕回顾引用屏 */
.s-quote { background: linear-gradient(180deg, #1c1226, #101725); }
.quote-box { font-size: 22px; line-height: 1.9; color: #ffd9e3; max-width: 320px; }
.q-mark { color: #e52958; font-size: 28px; font-weight: 900; }
.slide.active .quote-box { animation: quoteIn 1s cubic-bezier(.34,1.56,.64,1) .25s both; }
@keyframes quoteIn { from { opacity: 0; transform: scale(.8); } to { opacity: 1; transform: scale(1); } }

/* 最爱领域 */
.s-cats { background: linear-gradient(180deg, #12141f, #101b26); }
.cats { width: 100%; max-width: 330px; margin-bottom: 20px; }
.cat-row { display: flex; align-items: center; width: 100%; margin-bottom: 20px; }
.cat-name { width: 96px; text-align: right; font-size: 14px; color: #c6cde2; padding-right: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.cat-bar { flex: 1; height: 14px; background: rgba(255,255,255,.07); border-radius: 999px; overflow: hidden; }
.cat-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #e52958, #ff7a9e); border-radius: 999px; transition: width 1.1s cubic-bezier(.22,1,.36,1) .4s; }
.slide.active .cat-bar i { width: var(--w); }
.cat-pct { width: 52px; padding-left: 10px; font-size: 13px; color: #ff8aa5; font-weight: 700; }

/* 出没时段柱状图 */
.s-hours { background: linear-gradient(180deg, #101b26, #191224); }
.bars { display: flex; align-items: flex-end; gap: 4px; height: 130px; width: 100%; max-width: 330px; margin-bottom: 44px; }
.bars i { flex: 1; height: 4%; background: rgba(255,255,255,.16); border-radius: 4px 4px 0 0; position: relative; transition: height .9s cubic-bezier(.22,1,.36,1); }
.slide.active .bars i { height: var(--h); }
.bars i.pk { background: linear-gradient(180deg, #ff7a9e, #e52958); box-shadow: 0 0 14px rgba(229,41,88,.5); }
.bars i b { position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%); font-size: 9px; color: #5d657e; font-weight: 400; }
.bars i.pk b { color: #ff8aa5; font-weight: 700; }

/* 年度等级 */
.s-level { background: linear-gradient(180deg, #191224, #1a1420); }
.lv-ring { width: 150px; height: 150px; border-radius: 50%; border: 3px solid rgba(192,124,50,.55); display: flex; align-items: center; justify-content: center; margin-bottom: 16px; background: radial-gradient(circle at 50% 32%, rgba(192,124,50,.2), rgba(0,0,0,0) 72%); animation: lvPulse 2.6s ease-in-out infinite; }
.lv-ring span { font-size: 40px; font-weight: 900; color: #e8c48a; }
@keyframes lvPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(192,124,50,.28); } 50% { box-shadow: 0 0 0 18px rgba(192,124,50,0); } }
.lv-name { font-size: 22px; font-weight: 800; margin-bottom: 24px; }
.lv-bar { width: 240px; height: 10px; background: rgba(255,255,255,.1); border-radius: 999px; overflow: hidden; margin-bottom: 14px; }
.lv-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #c07c32, #ffe9c4); border-radius: 999px; transition: width 1.3s ease .5s; }
.slide.active .lv-bar i { width: var(--w); }

/* 感谢屏 */
.th-title { font-size: 22px; color: #fff; font-weight: 800; margin-bottom: 30px; letter-spacing: 2px; }
.th-line { font-size: 15px; color: #c6cde2; line-height: 2.3; }
.th-line.strong { color: #ff8aa5; font-weight: 700; }
.th-sign { margin-top: 28px; font-size: 13px; color: #8891a8; }
.s-thanks { background: linear-gradient(180deg, #1b0f18, #241019); }

/* 新屏通用入场 */
.slide .quote-box, .slide .cats, .slide .bars, .slide .lv-ring, .slide .lv-name,
.slide .lv-bar, .slide .th-title, .slide .th-line, .slide .th-sign {
  opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease;
}
.slide.active .quote-box, .slide.active .cats, .slide.active .lv-ring, .slide.active .lv-name,
.slide.active .lv-bar, .slide.active .th-title, .slide.active .th-line, .slide.active .th-sign {
  opacity: 1; transform: none;
}
.slide.active *:nth-child(2) { transition-delay: .12s; }
.slide.active *:nth-child(3) { transition-delay: .22s; }
.slide.active *:nth-child(4) { transition-delay: .32s; }
.slide.active *:nth-child(5) { transition-delay: .42s; }
.slide.active *:nth-child(n+6) { transition-delay: .5s; }

/* 数字弹跳 */
.slide.active .big { animation: pop .7s cubic-bezier(.34,1.56,.64,1) .35s both; }
@keyframes pop { from { transform: scale(.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* 音效开关 */
.sfx-btn { position: fixed; top: 12px; right: 12px; z-index: 99; width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(255,255,255,.22); background: rgba(18,20,31,.65); color: #fff; font-size: 16px; cursor: pointer; }
.sfx-btn.off { opacity: .45; }
