:root {
  --bg: #14122a;
  --card: rgba(30, 26, 54, 0.55);
  --primary: #9aa6ff;
  --primary-dark: #7c8aff;
  --accent: #f6b894;
  --text: #eef0fb;
  --text-light: #a9a8c6;
  --border: rgba(255, 255, 255, 0.16);
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.38);
  --radius: 16px;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

[hidden] { display: none !important; }

html, body { height: 100%; }

body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.app {
  max-width: 560px;
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
}

/* ---------- 顶部 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: linear-gradient(135deg, #3f51b5, #f6b894);
  color: #fff;
  padding: 18px 20px 14px;
  border-radius: 0 0 22px 22px;
  box-shadow: 0 4px 14px rgba(63, 81, 181, 0.25);
}
.brand { font-size: 20px; font-weight: 700; letter-spacing: 1px; }
.topbar-sub { font-size: 13px; opacity: 0.92; margin-top: 2px; }

/* ---------- 内容 ---------- */
.content { flex: 1; padding: 16px 16px 24px; }

.page { display: none; }
.page.active { display: block; animation: fadeIn .3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.section-title { font-size: 15px; font-weight: 700; margin: 20px 4px 10px; }

.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px;
  margin-bottom: 14px;
}

.empty { color: var(--text-light); text-align: center; padding: 22px 10px; font-size: 14px; }

/* ---------- 首页 ---------- */
.hero {
  background: linear-gradient(135deg, #3f51b5, #f6b894);
  color: #fff;
  border-radius: 22px;
  padding: 26px 20px;
  text-align: center;
  box-shadow: 0 8px 24px rgba(63, 81, 181, 0.28);
}
.hero-label { font-size: 14px; opacity: 0.92; }
.hero-days {
  font-size: 72px;
  font-weight: 800;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.hero-days-label { font-size: 16px; opacity: 0.95; }
.hero-date { font-size: 13px; opacity: 0.85; margin-top: 8px; }

.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  text-align: center;
  cursor: pointer;
  transition: transform .15s;
}
.stat-card:active { transform: scale(.97); }
.stat-num { font-size: 30px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 13px; color: var(--text-light); margin-top: 2px; }

.anni-list { display: flex; flex-direction: column; gap: 10px; }
.anni-item {
  background: var(--card);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.anni-name { font-weight: 600; font-size: 15px; }
.anni-date { font-size: 12px; color: var(--text-light); }
.anni-count {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  background: #eef0fb;
  padding: 4px 10px;
  border-radius: 20px;
  white-space: nowrap;
}
.anni-count.today { background: var(--primary); color: #fff; }

/* ---------- 表单 ---------- */
.input {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 11px 12px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  background: #fff;
  outline: none;
  transition: border-color .15s;
}
.input:focus { border-color: var(--primary); }
.textarea { resize: none; }
.date-input { flex: 1; }
.row { display: flex; gap: 10px; margin: 10px 0; align-items: center; }
.row .input { flex: 1; }
.field-label { display: block; font-size: 13px; color: var(--text-light); margin: 12px 0 5px; }
.checkbox { display: flex; align-items: center; gap: 6px; font-size: 14px; margin: 10px 0; }

.btn {
  border: none;
  border-radius: 12px;
  padding: 11px 18px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: opacity .15s, transform .1s;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: linear-gradient(135deg, #3f51b5, #5c6bc0); color: #fff; }
.btn-ghost { background: #eef0fb; color: var(--primary); }
.btn-block { width: 100%; margin-top: 10px; }

/* ---------- 发布框 ---------- */
.composer-top { display: flex; gap: 10px; margin-bottom: 10px; }
.who-toggle {
  display: flex;
  background: #eef0fb;
  border-radius: 12px;
  padding: 3px;
  flex-shrink: 0;
}
.who-option {
  padding: 7px 16px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-light);
  cursor: pointer;
}
.who-option.active { background: var(--primary); color: #fff; }

.mood-row { display: flex; align-items: center; gap: 4px; margin: 10px 0; flex-wrap: wrap; }
.mood-label { font-size: 13px; color: var(--text-light); margin-right: 4px; }
.mood-btn {
  border: none;
  background: transparent;
  font-size: 22px;
  padding: 4px 5px;
  cursor: pointer;
  border-radius: 8px;
  transition: background .15s, transform .1s;
}
.mood-btn:hover, .mood-btn.active { background: #eef0fb; }
.mood-btn:active { transform: scale(1.2); }

.composer-footer { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.image-preview { position: relative; margin-top: 12px; }
.image-preview img { width: 100%; border-radius: 12px; display: block; }
.remove-img {
  position: absolute; top: 8px; right: 8px;
  border: none; background: rgba(0,0,0,.5); color: #fff;
  width: 28px; height: 28px; border-radius: 50%; cursor: pointer; font-size: 14px;
}

/* ---------- 时光轴 ---------- */
.timeline { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.moment {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
  position: relative;
}
.moment-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.moment-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, #3f51b5, #f6b894);
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 15px; flex-shrink: 0;
}
.moment-author { font-weight: 600; font-size: 14px; }
.moment-time { font-size: 12px; color: var(--text-light); }
.moment-mood { margin-left: auto; font-size: 20px; }
.moment-content { font-size: 15px; white-space: pre-wrap; word-break: break-word; }
.moment-content:empty { display: none; }
.moment-img { width: 100%; border-radius: 12px; margin-top: 10px; cursor: pointer; display: block; }
.moment-del {
  position: absolute; top: 10px; right: 10px;
  border: none; background: transparent; color: #ccc; font-size: 16px; cursor: pointer;
  padding: 2px 6px;
}
.moment-del:hover { color: #e53935; }

/* ---------- 想去列表 ---------- */
.filter-row { display: flex; gap: 8px; margin-bottom: 14px; }
.chip {
  border: 1.5px solid var(--border);
  background: #fff;
  border-radius: 20px;
  padding: 6px 16px;
  font-size: 14px;
  cursor: pointer;
  color: var(--text-light);
  font-family: inherit;
}
.chip.active { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }

.wish-level { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
.star {
  border: none; background: transparent; font-size: 22px; color: #e4e6f0; cursor: pointer; padding: 0 2px;
  transition: color .1s, transform .1s;
}
.star.active { color: #e8a05c; }
.star:active { transform: scale(1.2); }

.place-list { display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }
.place-item {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
  position: relative;
}
.place-item.done { opacity: .65; }
.place-name { font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 8px; }
.place-cat {
  font-size: 12px; background: #eef0fb; color: var(--primary);
  padding: 2px 10px; border-radius: 20px; font-weight: 600;
}
.place-stars { color: #e8a05c; font-size: 14px; margin-left: 2px; letter-spacing: 1px; }
.place-addr { font-size: 13px; color: var(--text-light); margin-top: 4px; }
.place-note { font-size: 14px; margin-top: 6px; color: var(--text); }
.place-actions { display: flex; gap: 8px; margin-top: 10px; }
.mini-btn {
  border: 1.5px solid var(--border);
  background: #fff;
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  color: var(--text);
}
.mini-btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.mini-btn.danger { color: #e53935; border-color: #f5c6cb; }
.place-del { position: absolute; top: 10px; right: 10px; border: none; background: transparent; color: #ccc; cursor: pointer; font-size: 16px; }

/* ---------- 出门/转盘 ---------- */
.roulette-wrap { text-align: center; margin-bottom: 6px; }
.roulette {
  width: 250px; height: 250px;
  margin: 10px auto 16px;
  border-radius: 50%;
  position: relative;
  overflow: hidden;
  background: conic-gradient(
    #3f51b5 0 45deg, #f6b894 45deg 90deg, #e8a05c 90deg 135deg, #5c6bc0 135deg 180deg,
    #7986cb 180deg 225deg, #f48fb1 225deg 270deg, #3f51b5 270deg 315deg, #f6b894 315deg 360deg
  );
  box-shadow: 0 8px 30px rgba(63, 81, 181, 0.3);
  cursor: pointer;
  transition: transform 4s cubic-bezier(.17,.67,.12,.99);
  border: 6px solid #fff;
}
.roulette-center {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 64px; height: 64px; border-radius: 50%;
  background: #fff; color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 18px;
  box-shadow: 0 2px 10px rgba(0,0,0,.15);
  z-index: 2;
}
.roulette-result {
  font-size: 20px; font-weight: 700; color: var(--primary);
  min-height: 34px; margin-bottom: 4px;
}
.roulette-source { display: flex; gap: 18px; flex-wrap: wrap; margin-bottom: 6px; }

/* ---------- 底部导航 ---------- */
.tabbar {
  position: sticky;
  bottom: 0;
  z-index: 20;
  display: flex;
  background: #fff;
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 14px rgba(0,0,0,.05);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.tab {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 22px;
  padding: 6px 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: var(--text-light);
  font-family: inherit;
}
.tab span { font-size: 11px; }
.tab.active { color: var(--primary); font-weight: 700; }

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 90px;
  transform: translateX(-50%) translateY(20px);
  background: rgba(0,0,0,.78);
  color: #fff;
  padding: 10px 20px;
  border-radius: 24px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: all .25s;
  z-index: 99;
  max-width: 80vw;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- 图片查看 ---------- */
.lightbox {
  position: fixed; inset: 0; background: rgba(0,0,0,.9);
  display: flex; align-items: center; justify-content: center;
  z-index: 100; cursor: zoom-out;
}
.lightbox img { max-width: 94vw; max-height: 94vh; border-radius: 8px; }

/* ---------- 发布框按钮组 ---------- */
.composer-actions { display: flex; gap: 8px; align-items: center; }

/* ---------- 登录浮层 ---------- */
.login-overlay {
  position: fixed; inset: 0;
  background: linear-gradient(135deg, #3f51b5, #f6b894);
  display: flex; align-items: center; justify-content: center;
  z-index: 200; padding: 24px;
}
.login-box {
  background: #fff; border-radius: 20px;
  padding: 30px 24px; width: 100%; max-width: 340px;
  text-align: center; box-shadow: 0 12px 40px rgba(0,0,0,.2);
}
.login-title { font-size: 22px; font-weight: 800; color: var(--primary); }
.login-sub { font-size: 13px; color: var(--text-light); margin: 4px 0 16px; }
.login-err { color: #e53935; font-size: 13px; margin-top: 10px; min-height: 18px; }

/* ---------- 时光轴月份分组 ---------- */
.month-header {
  font-size: 13px; font-weight: 700; color: var(--text-light);
  margin: 14px 4px 0; display: flex; align-items: center; gap: 8px;
}
.month-header::after { content: ""; flex: 1; height: 1px; background: var(--border); }

/* ---------- 编辑按钮 ---------- */
.moment-edit {
  position: absolute; top: 10px; right: 40px;
  border: none; background: transparent; color: #ccc; font-size: 16px;
  cursor: pointer; padding: 2px 6px;
}
.moment-edit:hover { color: #e8a05c; }

/* ---------- 地图 ---------- */
.map-legend {
  display: flex; gap: 16px; align-items: center;
  margin-bottom: 10px; font-size: 13px; color: var(--text);
}
.legend-item { display: flex; align-items: center; gap: 5px; }
.dot {
  width: 12px; height: 12px; border-radius: 50%; display: inline-block;
  border: 2px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3);
}
.dot.visited { background: #3f51b5; }
.dot.wish { background: #e8a05c; }

.map-search { display: flex; gap: 8px; margin-bottom: 10px; }
.map-search .input { flex: 1; }

.map-search-results { display: flex; flex-direction: column; gap: 6px; margin-bottom: 10px; }
.geo-item {
  background: #fff; border-radius: 12px; padding: 10px 12px;
  display: flex; justify-content: space-between; align-items: center;
  gap: 10px; box-shadow: var(--shadow); cursor: pointer;
}
.geo-name { font-size: 14px; flex: 1; word-break: break-word; }

.map-container {
  height: 380px; border-radius: 16px; overflow: hidden;
  box-shadow: var(--shadow);
  position: relative; isolation: isolate; z-index: 0;
  margin-bottom: 12px;
}

.unlocated { margin-top: 4px; }

@media (min-width: 560px) {
  .app { box-shadow: 0 0 40px rgba(0,0,0,.06); }
}

/* =========================================================
   v3 朋友圈模式 + 双人身份
   ========================================================= */
[hidden] { display: none !important; }

/* ---- 顶栏身份切换 ---- */
.who-switch {
  margin-left: auto;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,.85);
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  background: #eef0fb;
  flex-shrink: 0;
}
.who-switch img { width: 100%; height: 100%; object-fit: cover; display: block; }
.who-switch span {
  display: flex; width: 100%; height: 100%;
  align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 14px;
}

/* ---- 发布框：身份 + 多图 ---- */
.composer-who { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.composer-who-name { font-weight: 700; font-size: 14px; }
.composer-who-empty { font-size: 13px; color: var(--text-light); }
.composer-top { align-items: center; }
.img-count { font-size: 12px; opacity: .7; }

.thumb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.thumb { position: relative; }
.thumb img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 8px; display: block; background: #eee; }
.thumb-del {
  position: absolute; top: 4px; right: 4px;
  width: 22px; height: 22px; border-radius: 50%;
  border: none; background: rgba(0,0,0,.55); color: #fff;
  cursor: pointer; font-size: 12px; line-height: 1;
}
#momentLocation { margin-top: 10px; }

/* ---- 头像 ---- */
.id-avatar {
  width: 64px; height: 64px; border-radius: 50%;
  overflow: hidden; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--primary); color: #fff;
  font-size: 26px; font-weight: 700;
}
.id-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.id-avatar.small { width: 28px; height: 28px; font-size: 14px; }

.moment-avatar { overflow: hidden; flex-shrink: 0; }
.moment-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- 朋友圈卡片 ---- */
.moment-meta { flex: 1; min-width: 0; }
.moment-sub {
  display: flex; gap: 8px; align-items: center; flex-wrap: wrap;
  font-size: 12px; color: var(--text-light); margin-top: 2px;
}
.moment-sub .moment-mood { margin-left: 0; font-size: 14px; }
.moment-loc { font-size: 12px; color: var(--text-light); }

.moment-images { display: grid; gap: 4px; margin-top: 10px; }
.moment-images.g1 { grid-template-columns: 1fr; max-width: 70%; }
.moment-images.g2 { grid-template-columns: repeat(2, 1fr); max-width: 78%; }
.moment-images.g3 { grid-template-columns: repeat(3, 1fr); }
.moment-images img {
  width: 100%; aspect-ratio: 1 / 1; object-fit: cover;
  border-radius: 6px; cursor: pointer; display: block; background: #eee;
}
.moment-images.g1 img {
  aspect-ratio: auto; max-height: 320px; object-fit: contain;
  border-radius: 10px; background: transparent;
}

.moment-bar {
  display: flex; gap: 12px; margin-top: 10px;
  padding-top: 8px; border-top: 1px solid var(--border);
}
.bar-btn {
  border: none; background: transparent; cursor: pointer;
  font-size: 13px; color: var(--text-light);
  padding: 4px 8px; border-radius: 8px;
}
.bar-btn:hover { background: #eef0fb; }
.bar-btn.on { color: #e53935; font-weight: 600; }

.moment-likes {
  margin-top: 8px; font-size: 13px; color: var(--text-light);
  background: #f7f8fd; padding: 6px 10px; border-radius: 8px;
}
.moment-comments {
  margin-top: 6px; background: #f7f8fd;
  border-radius: 8px; padding: 8px 10px;
}
.cmt { font-size: 13px; line-height: 1.7; position: relative; padding-right: 22px; }
.cmt-name { font-weight: 600; }
.cmt-text { word-break: break-word; }
.cmt-del {
  position: absolute; right: 0; top: 3px;
  border: none; background: transparent; color: #bbb;
  cursor: pointer; font-size: 12px;
}
.cmt-del:hover { color: #e53935; }
.comment-box { display: flex; gap: 8px; margin-top: 8px; }
.comment-box .input { flex: 1; }

/* ---- 身份选择浮层 ---- */
.identity-cards { display: flex; gap: 12px; margin: 18px 0 6px; }
.identity-card {
  flex: 1; border: 2px solid var(--border); border-radius: 16px;
  padding: 16px 8px; cursor: pointer; text-align: center;
  background: var(--card);
  transition: transform .15s, box-shadow .15s;
}
.identity-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.id-name { font-weight: 700; font-size: 15px; }
.id-pin { font-size: 12px; color: var(--text-light); margin-top: 4px; }
.pin-box { margin-top: 14px; }

/* ---- 设置页身份管理 ---- */
.id-row { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.id-fields { flex: 1; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.id-color { width: 100%; height: 38px; padding: 2px; }
#identityManage { margin-top: 10px; }

/* ---- 大图浏览 ---- */
#lightbox {
  position: fixed; inset: 0; z-index: 1200;
  background: rgba(0,0,0,.92);
  display: flex; align-items: center; justify-content: center;
}
#lightbox img { max-width: 92vw; max-height: 88vh; border-radius: 8px; }
.lb-close {
  position: absolute; top: 14px; right: 16px;
  width: 36px; height: 36px; border-radius: 50%;
  border: none; background: rgba(255,255,255,.14); color: #fff;
  font-size: 16px; cursor: pointer;
}
.lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 50%;
  border: none; background: rgba(255,255,255,.14); color: #fff;
  font-size: 28px; line-height: 1; cursor: pointer;
}
.lb-prev { left: 10px; }
.lb-next { right: 10px; }
.lb-count {
  position: absolute; bottom: 22px; left: 0; right: 0;
  text-align: center; color: rgba(255,255,255,.8); font-size: 14px;
}

/* =========================================================
   电影感动态背景 + 玻璃拟态（去除 AI 扁平感）
   ========================================================= */
/* 背景舞台：固定全屏，置于内容之后 */
.bg-stage {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  background: #161325;
}
.bg-layer {
  position: absolute;
  inset: -24px;                 /* 留出缩放出血，避免露边 */
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.12) translateZ(0);
  transition: opacity 1.8s ease, transform 9s ease;
  will-change: opacity, transform;
}
.bg-layer.is-on {
  opacity: 1;
  transform: scale(1) translateZ(0);
}
/* 强暗化蒙版：背景只做氛围，所有文字都落在深色之上 */
.bg-veil {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 70% at 50% -8%, rgba(255,255,255,.10), transparent 50%),
    linear-gradient(180deg, rgba(16,12,30,.60) 0%, rgba(16,12,30,.76) 55%, rgba(16,12,30,.86) 100%);
}

/* 漂浮光点：缓慢上浮，营造氛围 */
.floaters {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.floaters span {
  position: absolute;
  bottom: -14px;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, rgba(255,255,255,.95), rgba(246,184,148,.55) 70%, transparent);
  box-shadow: 0 0 10px rgba(255,255,255,.55);
  opacity: 0;
  animation: floatUp 16s linear infinite;
}
.floaters span:nth-child(1) { left: 8%;  width: 7px;  height: 7px;  animation-duration: 15s; animation-delay: 0s; }
.floaters span:nth-child(2) { left: 18%; width: 11px; height: 11px; animation-duration: 19s; animation-delay: 2s; }
.floaters span:nth-child(3) { left: 27%; width: 6px;  height: 6px;  animation-duration: 13s; animation-delay: 5s; }
.floaters span:nth-child(4) { left: 38%; width: 10px; height: 10px; animation-duration: 21s; animation-delay: 1.5s; }
.floaters span:nth-child(5) { left: 47%; width: 8px;  height: 8px;  animation-duration: 17s; animation-delay: 7s; }
.floaters span:nth-child(6) { left: 56%; width: 5px;  height: 5px;  animation-duration: 14s; animation-delay: 3s; }
.floaters span:nth-child(7) { left: 65%; width: 12px; height: 12px; animation-duration: 23s; animation-delay: 0.5s; }
.floaters span:nth-child(8) { left: 74%; width: 7px;  height: 7px;  animation-duration: 16s; animation-delay: 6s; }
.floaters span:nth-child(9) { left: 84%; width: 9px;  height: 9px;  animation-duration: 20s; animation-delay: 4s; }
.floaters span:nth-child(10){ left: 92%; width: 6px;  height: 6px;  animation-duration: 18s; animation-delay: 9s; }

@keyframes floatUp {
  0%   { transform: translateY(0) scale(.6); opacity: 0; }
  12%  { opacity: .9; }
  88%  { opacity: .9; }
  100% { transform: translateY(-106vh) scale(1.1); opacity: 0; }
}

/* 内容容器透出背景 */
.app { background: transparent; box-shadow: none; }

/* 暗色玻璃拟态：卡片为深色拉丝玻璃，浮于电影背景之上 */
.card,
.stat-card,
.anni-item,
.place-item,
.composer,
.identity-card,
.geo-item,
.tabbar,
.login-box {
  background: rgba(30, 26, 54, 0.55);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  backdrop-filter: blur(20px) saturate(1.3);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.40);
  color: var(--text);
}
/* 顶栏渐变保留并加磨砂 */
.topbar {
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  background: linear-gradient(135deg, rgba(63,81,181,.92), rgba(246,184,148,.92));
}
/* 表单控件：深色玻璃 + 浅色字，保证可读 */
.input,
.card .input,
.composer .input {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  border: 1.5px solid rgba(255, 255, 255, 0.18);
}
.input:focus { border-color: var(--primary); }
.input::placeholder { color: rgba(233, 235, 251, 0.45); }
/* 次级按钮：深色玻璃 */
.btn-ghost { background: rgba(255, 255, 255, 0.12); color: var(--primary); }
/* 过滤芯片 */
.chip { background: rgba(255,255,255,.12); color: var(--text-light); border-color: rgba(255,255,255,.2); }
.chip.active { background: var(--primary); border-color: var(--primary); color: #14122a; font-weight: 600; }
/* 身份切换胶囊 */
.who-toggle { background: rgba(255,255,255,.12); }
.who-option { background: rgba(255,255,255,.10); color: var(--text-light); }
.who-option.active { background: var(--primary); color: #14122a; }
/* 纪念日计数胶囊 */
.anni-count { background: rgba(255,255,255,.16); color: #fff; }
.anni-count.today { background: var(--primary); color: #14122a; }
/* 地点分类标签 */
.place-cat { background: rgba(255,255,255,.16); color: var(--primary); }
/* 迷你按钮 */
.mini-btn { background: rgba(255,255,255,.10); border-color: rgba(255,255,255,.2); color: var(--text); }
.mini-btn.primary { background: var(--primary); border-color: var(--primary); color: #14122a; }
.mini-btn.danger { color: #ff8a8a; border-color: rgba(255,138,138,.4); }
/* 点赞/评论底色 */
.moment-likes,
.moment-comments { background: rgba(255, 255, 255, 0.08); }
/* 时光轴分隔线 / 月份标题 / 年份归档 */
.month-header::after { background: rgba(255,255,255,.30); }
.month-header { color: rgba(255,255,255,.95); text-shadow: 0 1px 6px rgba(0,0,0,.45); }
.year-header {
  font-size: 19px; font-weight: 800; color: var(--accent);
  margin: 24px 4px 6px; letter-spacing: 1px;
  display: flex; align-items: center; gap: 10px;
  text-shadow: 0 1px 8px rgba(0,0,0,.5);
}
.year-header::after {
  content: ""; flex: 1; height: 2px;
  background: linear-gradient(90deg, rgba(246,184,148,.65), transparent);
}
/* hover 态 */
.bar-btn:hover { background: rgba(255,255,255,.12); }
.mood-btn:hover, .mood-btn.active { background: rgba(255,255,255,.12); }
/* 星星 */
.star { color: rgba(255,255,255,.28); }
.star.active { color: #f6b894; }

@media (prefers-reduced-motion: reduce) {
  .bg-layer { transition: opacity 1.2s ease; transform: none; }
  .floaters span { animation: none; opacity: .5; }
}
