/* ============================================================
   唯品客 · 蛋糕研发所
   ------------------------------------------------------------
   配色与字体取自《VIPCAKE 唯品客品牌手册》：
     主色 勃艮第 #4F0B24（手册 VI 页色块实测）
     辅色 燕麦驼 #C6AF8E（品牌主视觉底色实测）
     标志 深棕黑 #251716（标志笔画实测）
   字体沿用手册「经典凿刻文字的厚重肌理 + 西餐刀具的利落收锋」，
   品牌层用衬线/宋体，功能层用 PingFang 保证手机可读性。
   ============================================================ */

:root {
  /* —— 品牌色 —— */
  --burgundy: #4F0B24;
  --burgundy-deep: #350616;
  --burgundy-soft: #7A2745;
  --burgundy-wash: #F6EDF0;
  --oat: #C6AF8E;
  --oat-light: #DFCDB2;
  --oat-pale: #F1E8DA;
  --ink: #251716;
  --ink-soft: #6B5B52;
  --ink-faint: #A2917F;
  --cream: #FAF6F0;
  --white: #FFFFFF;
  --gold: #B8912F;
  --line: #EBE0D0;

  /* —— 字体 —— */
  --font-serif: "Optima", "Palatino", "Baskerville", "Didot", "Songti SC", "STSong", Georgia, serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue",
               "Microsoft YaHei", "Source Han Sans SC", sans-serif;

  /* —— 尺寸 —— */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-full: 999px;
  --shadow-sm: 0 1px 3px rgba(37, 23, 22, .06);
  --shadow-md: 0 4px 16px rgba(37, 23, 22, .09);
  --shadow-lg: 0 10px 34px rgba(37, 23, 22, .14);
  --app-max: 480px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

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

html, body {
  margin: 0; padding: 0;
  background: var(--oat-pale);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

button { font-family: inherit; font-size: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea { font-family: inherit; font-size: inherit; color: inherit; }

/* ============ App 外壳 ============ */
#app {
  max-width: var(--app-max);
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--cream);
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 60px rgba(37, 23, 22, .07);
}

/* ============ 品牌标志 ============ */
.logo-mark { display: block; flex: none; }
.logo-lockup { display: inline-flex; align-items: center; gap: 9px; }
.logo-words { display: flex; flex-direction: column; line-height: 1.05; }
.logo-en {
  font-family: var(--font-serif);
  font-size: 15px; letter-spacing: .19em; font-weight: 600;
}
.logo-cn { font-size: 10.5px; letter-spacing: .34em; opacity: .72; margin-top: 2px; }

/* ============ 顶栏 ============ */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 12px;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 40;
}
.topbar .logo-lockup { color: var(--burgundy); }
.topbar-act { display: flex; gap: 8px; align-items: center; }
.icon-btn {
  width: 36px; height: 36px; border-radius: var(--r-full);
  display: grid; place-items: center;
  background: var(--oat-pale); color: var(--ink-soft);
  font-size: 15px; transition: .16s;
}
.icon-btn:active { transform: scale(.93); }
.icon-btn.badge { position: relative; }
.icon-btn.badge::after {
  content: attr(data-n); position: absolute; top: -2px; right: -2px;
  min-width: 16px; height: 16px; padding: 0 4px;
  background: var(--burgundy); color: #fff;
  font-size: 10px; line-height: 16px; text-align: center;
  border-radius: var(--r-full); font-weight: 600;
}

/* ============ 视图切换 ============ */
.view { display: none; flex: 1; flex-direction: column; min-height: 0; }
.view.on { display: flex; animation: fade .26s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ============ 首页 ============ */
.hero {
  flex: 1; display: flex; flex-direction: column;
  align-items: center;
  padding: 24px 22px calc(30px + var(--safe-b));
  text-align: center;
  background:
    radial-gradient(120% 70% at 50% 0%, #fff 0%, var(--cream) 60%),
    var(--cream);
}
.hero-logo { color: var(--burgundy); margin-bottom: 12px; }
/* 品牌名要够大——这是顾客扫码后看到的第一眼 */
.hero-brand {
  font-family: var(--font-serif);
  font-size: 46px; font-weight: 700; letter-spacing: .16em;
  margin: 0; color: var(--burgundy); line-height: 1.1;
  text-indent: .16em;
}
.hero-en {
  font-family: var(--font-serif);
  font-size: 15px; letter-spacing: .46em; color: var(--oat);
  margin-top: 6px; text-indent: .46em; font-weight: 600;
}
.hero-line {
  width: 54px; height: 1.5px; background: var(--oat-light);
  margin: 16px 0 14px;
}
.hero-title {
  font-family: var(--font-serif);
  font-size: 22px; font-weight: 600; letter-spacing: .1em;
  margin: 0 0 8px; color: var(--ink); text-indent: .1em;
}
.hero-sub { color: var(--ink-soft); font-size: 13.5px; margin: 0; line-height: 1.6; }
.hero-slogan {
  font-family: var(--font-serif);
  color: var(--burgundy); font-size: 15px; letter-spacing: .1em;
  margin: 20px 0 0; padding-top: 18px;
  border-top: 1px solid var(--line); width: 100%; max-width: 280px;
}
.hero-promises {
  display: grid; grid-template-columns: 1fr 1fr; gap: 9px;
  margin: 20px 0 4px; width: 100%; max-width: 340px;
}
.promise {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 10px 8px;
  box-shadow: var(--shadow-sm);
}
.promise b { display: block; font-size: 12.5px; color: var(--burgundy); font-weight: 600; }
.promise span { font-size: 10px; color: var(--ink-faint); line-height: 1.45; display: block; margin-top: 3px; }
.hero-cta { margin-top: 18px; width: 100%; max-width: 340px; display: grid; gap: 11px; }

/* 大按钮：深色实心，和米色背景拉开对比 */
.btn-hero {
  flex-direction: column; gap: 3px;
  padding: 17px 20px; border-radius: 18px;
}
.btn-hero span { font-size: 18px; font-weight: 700; letter-spacing: .08em; }
.btn-hero em { font-style: normal; font-size: 11.5px; opacity: .74; font-weight: 400; letter-spacing: .02em; }
.btn-dark {
  background: var(--ink); color: #fff;
  box-shadow: 0 4px 14px rgba(37, 23, 22, .24);
}
.btn-primary.btn-hero { box-shadow: 0 6px 20px rgba(79, 11, 36, .32); }

/* 本月大奖 */
.prize-card {
  width: 100%; max-width: 340px; margin-top: 18px;
  background: linear-gradient(135deg, var(--burgundy), var(--burgundy-deep));
  color: #fff; border-radius: 18px; padding: 14px 16px 12px;
  text-align: left; position: relative; overflow: hidden;
  box-shadow: 0 6px 22px rgba(79, 11, 36, .26);
}
.prize-card::after {
  content: ''; position: absolute; right: -30px; top: -34px;
  width: 130px; height: 130px; border-radius: 50%;
  background: rgba(198, 175, 142, .18);
}
.prize-tag {
  display: inline-block; font-size: 10.5px; letter-spacing: .2em;
  background: rgba(255,255,255,.18); padding: 3px 9px; border-radius: var(--r-full);
  position: relative;
}
.prize-main { display: flex; align-items: center; gap: 11px; margin: 9px 0 10px; position: relative; }
.prize-emoji { font-size: 30px; }
.prize-main b { display: block; font-size: 19px; font-weight: 700; letter-spacing: .02em; }
.prize-main span { font-size: 11.5px; opacity: .8; }
.prize-foot {
  display: flex; align-items: center; justify-content: space-between;
  border-top: 1px solid rgba(255,255,255,.16); padding-top: 9px;
  font-size: 11.5px; position: relative;
}
.prize-cd b { font-size: 14px; font-family: var(--font-serif); }
.prize-more { opacity: .8; }

.prize-detail { display: grid; gap: 10px; margin-bottom: 14px; }
.prize-rank1 {
  background: linear-gradient(135deg, #FBF3DC, var(--oat-pale));
  border: 1px solid var(--oat-light); border-radius: var(--r-md); padding: 13px 14px;
}
.prize-rank1 b { display: block; font-size: 12px; color: var(--gold); letter-spacing: .1em; }
.prize-rank1 span { display: block; font-family: var(--font-serif); font-size: 20px; font-weight: 600; margin: 3px 0 5px; }
.prize-rank1 em { font-style: normal; font-size: 12px; color: var(--ink-soft); line-height: 1.55; }
.prize-rank2 {
  background: var(--cream); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 11px 14px;
}
.prize-rank2 b { font-size: 12px; color: var(--ink-faint); margin-right: 8px; }
.prize-rank2 span { font-size: 13px; }
.prize-how h4 { margin: 0 0 8px; font-size: 13px; color: var(--ink-soft); letter-spacing: .06em; }
.prize-how ol { margin: 0; padding-left: 18px; font-size: 13px; color: var(--ink-soft); line-height: 1.9; }

/* 首页快捷入口 */
.hero-quick {
  display: flex; gap: 8px; margin-top: 14px; width: 100%; max-width: 340px;
}
.hero-quick button {
  flex: 1; padding: 9px 4px; border-radius: var(--r-md);
  background: var(--white); border: 1px solid var(--line);
  font-size: 11.5px; color: var(--ink-soft); box-shadow: var(--shadow-sm);
}
.hero-quick button:active { transform: scale(.97); }

/* ============ 按钮 ============ */
.btn {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  padding: 14px 20px; border-radius: var(--r-full);
  font-size: 15px; font-weight: 600; letter-spacing: .04em;
  transition: transform .14s, box-shadow .14s, opacity .14s;
}
.btn:active { transform: scale(.975); }
.btn-primary { background: var(--burgundy); color: #fff; box-shadow: 0 4px 14px rgba(79, 11, 36, .26); }
.btn-primary:disabled { background: var(--oat-light); color: #fff; box-shadow: none; opacity: .8; cursor: not-allowed; }
.btn-ghost { background: var(--white); color: var(--burgundy); border: 1px solid var(--oat-light); }
.btn-plain { background: var(--oat-pale); color: var(--ink-soft); }
.btn-sm { padding: 9px 15px; font-size: 13px; font-weight: 500; }

/* ============ 设计器：预览区 ============ */
.stage {
  position: sticky; top: 62px; z-index: 30;
  background: linear-gradient(180deg, var(--white) 0%, #FDFAF5 76%, var(--cream) 100%);
  border-bottom: 1px solid var(--line);
  padding: 6px 0 0;
}
.stage-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 16px 2px;
}
.stage-name {
  font-family: var(--font-serif); font-size: 15px; font-weight: 600;
  color: var(--ink); letter-spacing: .03em;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 58%;
}
.stage-name .ph { color: var(--ink-faint); font-weight: 400; }
.view-switch { display: flex; background: var(--oat-pale); border-radius: var(--r-full); padding: 3px; gap: 2px; }
.view-switch button {
  padding: 5px 12px; border-radius: var(--r-full);
  font-size: 12px; color: var(--ink-soft); transition: .16s;
}
.view-switch button.on { background: var(--white); color: var(--burgundy); font-weight: 600; box-shadow: var(--shadow-sm); }
.cake-wrap { display: grid; place-items: center; padding: 0 8px; }
.cake-svg { width: 100%; max-width: 340px; height: auto; display: block; }
.stage-meta {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  padding: 0 16px 9px; font-size: 11.5px; color: var(--ink-faint);
}
.stage-meta b { color: var(--burgundy); font-weight: 600; }
.stage-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--oat); }

/* ============ 设计器：分类导航 ============ */
.cats {
  display: flex; gap: 7px; overflow-x: auto; scrollbar-width: none;
  padding: 11px 16px; background: var(--cream);
  position: sticky; z-index: 25; border-bottom: 1px solid var(--line);
}
.cats::-webkit-scrollbar { display: none; }
.cat {
  flex: none; padding: 7px 12px; border-radius: var(--r-full);
  background: var(--white); border: 1px solid var(--line);
  font-size: 12.5px; color: var(--ink-soft); white-space: nowrap;
  transition: .16s; position: relative;
}
.cat.on { background: var(--burgundy); border-color: var(--burgundy); color: #fff; font-weight: 600; }
.cat .n {
  display: inline-block; margin-left: 5px; padding: 0 5px;
  background: var(--oat-pale); color: var(--ink-soft);
  border-radius: var(--r-full); font-size: 10.5px; font-weight: 600;
}
.cat.on .n { background: rgba(255,255,255,.24); color: #fff; }
.cat.need::after {
  content: ''; position: absolute; top: 6px; right: 7px;
  width: 5px; height: 5px; border-radius: 50%; background: var(--gold);
}

/* ============ 设计器：材料网格 ============ */
.picker { flex: 1; overflow-y: auto; padding: 13px 16px calc(96px + var(--safe-b)); -webkit-overflow-scrolling: touch; }
.cat-hint {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 10px; margin: 0 2px 11px;
}
.cat-hint p { margin: 0; font-size: 12.5px; color: var(--ink-faint); }
.cat-hint .limit { font-size: 11.5px; color: var(--oat); flex: none; }

.mats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.mat {
  background: var(--white); border: 1.5px solid var(--line);
  border-radius: var(--r-md); padding: 8px 6px 9px;
  text-align: center; position: relative; overflow: hidden;
  transition: border-color .16s, transform .14s, box-shadow .16s;
}
.mat:active { transform: scale(.965); }
.mat.on { border-color: var(--burgundy); box-shadow: 0 3px 12px rgba(79, 11, 36, .15); }
.mat.on::after {
  content: '✓'; position: absolute; top: 0; right: 0;
  width: 21px; height: 21px; background: var(--burgundy); color: #fff;
  font-size: 11px; line-height: 21px; border-bottom-left-radius: 9px;
}
.mat.locked { opacity: .48; }
.mat.locked::before {
  content: '🔒'; position: absolute; top: 5px; right: 6px; font-size: 11px;
}
.mat-svg, .mat-photo { display: block; margin: 0 auto; width: 54px; height: 54px; object-fit: cover; border-radius: 7px; }
.mat-name { font-size: 11.5px; font-weight: 500; margin-top: 4px; line-height: 1.3; color: var(--ink); }
.mat-rare {
  position: absolute; top: 5px; left: 5px;
  font-size: 9px; padding: 1px 5px; border-radius: var(--r-full);
  font-weight: 600; letter-spacing: .04em;
}
.mat-rare.advanced { background: var(--oat-pale); color: var(--oat); }
.mat-rare.limited { background: #FBF3DC; color: var(--gold); }
.mat.season-now .mat-name::after { content: ' 🌤'; font-size: 9px; }

/* 材料详情弹层 */
.sheet-mat { display: flex; gap: 13px; align-items: flex-start; }
.sheet-mat .mat-svg, .sheet-mat .mat-photo { width: 76px; height: 76px; flex: none; }
.sheet-mat h4 { margin: 0 0 2px; font-size: 16px; font-family: var(--font-serif); }
.sheet-mat .en { font-size: 11px; color: var(--ink-faint); letter-spacing: .08em; text-transform: uppercase; }
.sheet-mat p { margin: 7px 0 0; font-size: 13px; color: var(--ink-soft); }
.attr-bars { margin-top: 13px; display: grid; gap: 6px; }
.attr-row { display: grid; grid-template-columns: 40px 1fr; align-items: center; gap: 9px; font-size: 11.5px; color: var(--ink-faint); }
.attr-track { height: 5px; background: var(--oat-pale); border-radius: var(--r-full); overflow: hidden; }
.attr-fill { height: 100%; background: var(--oat); border-radius: var(--r-full); transition: width .3s; }

/* ============ 底部操作条 ============ */
.dock {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: var(--app-max); z-index: 45;
  background: rgba(255, 255, 255, .93);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
  padding: 10px 16px calc(10px + var(--safe-b));
  display: flex; gap: 10px; align-items: center;
}
.dock .btn { flex: 1; }
.dock-score { flex: none; text-align: center; padding-right: 4px; min-width: 52px; }
.dock-score b { display: block; font-family: var(--font-serif); font-size: 21px; line-height: 1; color: var(--burgundy); }
.dock-score span { font-size: 10px; color: var(--ink-faint); letter-spacing: .06em; }

/* ============ 弹层 ============ */
.mask {
  position: fixed; inset: 0; background: rgba(37, 23, 22, .42);
  z-index: 60; opacity: 0; pointer-events: none; transition: opacity .24s;
}
.mask.on { opacity: 1; pointer-events: auto; }
.sheet {
  position: fixed; left: 50%; bottom: 0; transform: translate(-50%, 100%);
  width: 100%; max-width: var(--app-max); z-index: 61;
  background: var(--white);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  padding: 20px 20px calc(20px + var(--safe-b));
  max-height: 84vh; overflow-y: auto;
  transition: transform .3s cubic-bezier(.32, .72, 0, 1);
  box-shadow: var(--shadow-lg);
}
.sheet.on { transform: translate(-50%, 0); }
.sheet-grip { width: 34px; height: 4px; border-radius: var(--r-full); background: var(--line); margin: -8px auto 14px; }
/* 弹层里的按钮要撑满，否则在 flex 里会缩成内容宽度 */
.sheet .btn { width: 100%; }
/* 主操作按钮吸在弹层底部，内容再长也不用先滚动才能提交 */
.sheet-foot {
  position: sticky; bottom: calc(-1 * var(--safe-b));
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, var(--white) 26%);
  padding: 16px 0 2px; margin-top: 6px;
}
.sheet h3 {
  margin: 0 0 4px; font-family: var(--font-serif);
  font-size: 18px; font-weight: 600; letter-spacing: .03em;
}
.sheet .sub { margin: 0 0 16px; font-size: 12.5px; color: var(--ink-faint); }

/* ============ 命名 ============ */
.name-input {
  width: 100%; padding: 14px 15px; border-radius: var(--r-md);
  border: 1.5px solid var(--line); background: var(--cream);
  font-family: var(--font-serif); font-size: 18px; text-align: center;
  letter-spacing: .06em; transition: border-color .16s;
}
.name-input:focus { outline: none; border-color: var(--burgundy); background: var(--white); }
.name-count { text-align: right; font-size: 11px; color: var(--ink-faint); margin-top: 5px; }
.name-ideas { display: grid; gap: 8px; margin-top: 14px; }
.idea {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 11px 14px; border-radius: var(--r-md);
  background: var(--cream); border: 1px solid var(--line);
  text-align: left; transition: .16s;
}
.idea:active { transform: scale(.98); }
.idea.on { border-color: var(--burgundy); background: var(--burgundy-wash); }
.idea b { font-family: var(--font-serif); font-size: 16px; font-weight: 600; letter-spacing: .04em; }
.idea span { font-size: 11px; color: var(--ink-faint); display: block; margin-top: 2px; }
.idea .tag { flex: none; font-size: 10px; color: var(--oat); border: 1px solid var(--oat-light); padding: 2px 7px; border-radius: var(--r-full); }
.regen { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 12px; width: 100%; padding: 11px; border-radius: var(--r-md); background: var(--oat-pale); color: var(--ink-soft); font-size: 13px; }

/* ============ 成果页 ============ */
.result { flex: 1; overflow-y: auto; padding: 18px 16px calc(96px + var(--safe-b)); }
.card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 18px 16px; margin-bottom: 13px;
  box-shadow: var(--shadow-sm);
}
.result-hero { text-align: center; padding-top: 8px; }
.result-hero .cake-svg { max-width: 280px; margin: -6px auto 0; }
.result-name {
  font-family: var(--font-serif); font-size: 25px; font-weight: 600;
  letter-spacing: .05em; margin: 4px 0 3px; color: var(--ink);
}
.result-sub { font-size: 12px; color: var(--ink-faint); letter-spacing: .05em; }
.score-big {
  display: flex; align-items: baseline; justify-content: center; gap: 5px;
  margin: 14px 0 2px;
}
.score-big b { font-family: var(--font-serif); font-size: 46px; line-height: 1; color: var(--burgundy); font-weight: 600; }
.score-big span { font-size: 13px; color: var(--ink-faint); }
.score-tier {
  display: inline-block; margin-top: 6px; padding: 4px 13px;
  border-radius: var(--r-full); font-size: 12px; font-weight: 600;
  background: var(--burgundy-wash); color: var(--burgundy);
}
.radar-wrap { display: grid; place-items: center; padding: 4px 0 0; }
.radar { width: 100%; max-width: 250px; height: auto; }
.card h4 {
  margin: 0 0 10px; font-size: 13px; font-weight: 600;
  color: var(--ink-soft); letter-spacing: .07em;
}
.notes { display: grid; gap: 9px; }
.note {
  display: flex; gap: 9px; align-items: flex-start;
  font-size: 13px; line-height: 1.55; color: var(--ink-soft);
}
.note i { flex: none; font-style: normal; font-size: 13px; margin-top: 1px; }
.note.plus i { color: #3E8B4A; }
.note.minus i { color: #C0392B; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; }
.badge-item {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 12px; border-radius: var(--r-full);
  background: linear-gradient(135deg, #FBF3DC, var(--oat-pale));
  border: 1px solid var(--oat-light); font-size: 12px; font-weight: 500;
}
.badge-item em { font-style: normal; font-size: 14px; }
.recipe { display: grid; gap: 8px; }
.recipe-row { display: grid; grid-template-columns: 52px 1fr; gap: 10px; font-size: 13px; align-items: start; }
.recipe-row dt { color: var(--ink-faint); font-size: 11.5px; padding-top: 2px; }
.recipe-row dd { margin: 0; display: flex; flex-wrap: wrap; gap: 5px; }
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 9px; border-radius: var(--r-full);
  background: var(--cream); border: 1px solid var(--line); font-size: 12px;
}
.chip svg, .chip img { width: 15px; height: 15px; border-radius: 3px; }

/* ============ 人气榜 ============ */
.board { flex: 1; overflow-y: auto; padding: 14px 16px calc(30px + var(--safe-b)); }
.board-head {
  background: linear-gradient(135deg, var(--burgundy), var(--burgundy-deep));
  color: #fff; border-radius: var(--r-lg); padding: 18px 17px;
  margin-bottom: 14px; position: relative; overflow: hidden;
}
.board-head::after {
  content: ''; position: absolute; right: -28px; top: -28px;
  width: 130px; height: 130px; border-radius: 50%;
  background: rgba(198, 175, 142, .17);
}
.board-head h3 { margin: 0 0 5px; font-family: var(--font-serif); font-size: 19px; letter-spacing: .04em; position: relative; }
.board-head p { margin: 0; font-size: 12px; opacity: .82; line-height: 1.55; position: relative; }
.board-head .cd { display: inline-block; margin-top: 9px; padding: 4px 11px; background: rgba(255,255,255,.16); border-radius: var(--r-full); font-size: 11.5px; position: relative; }
.rank { display: grid; gap: 10px; }
.rank-item {
  display: flex; gap: 11px; align-items: center;
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 10px 12px 10px 10px;
  box-shadow: var(--shadow-sm); transition: .16s; text-align: left; width: 100%;
}
.rank-item:active { transform: scale(.985); }
.rank-no {
  flex: none; width: 26px; text-align: center;
  font-family: var(--font-serif); font-size: 16px; font-weight: 600; color: var(--ink-faint);
}
.rank-item:nth-child(1) .rank-no { color: var(--gold); font-size: 19px; }
.rank-item:nth-child(2) .rank-no,
.rank-item:nth-child(3) .rank-no { color: var(--oat); font-size: 17px; }
/* 缩略图让整张蛋糕等比缩进去，不能裁掉上下 */
.rank-thumb { flex: none; width: 64px; height: 53px; display: grid; place-items: center; }
.rank-thumb .cake-svg { width: 100%; height: 100%; max-width: none; }
.rank-info { flex: 1; min-width: 0; }
.rank-info b { display: block; font-family: var(--font-serif); font-size: 14.5px; font-weight: 600; letter-spacing: .03em;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-info span { font-size: 11px; color: var(--ink-faint); display: block; margin-top: 1px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-vote { flex: none; display: flex; flex-direction: column; align-items: center; gap: 2px; padding-left: 4px; }
.vote-btn {
  width: 34px; height: 34px; border-radius: var(--r-full);
  background: var(--burgundy-wash); color: var(--burgundy);
  display: grid; place-items: center; font-size: 14px; transition: .16s;
}
.vote-btn.on { background: var(--burgundy); color: #fff; }
.vote-btn:active { transform: scale(.9); }
.rank-vote span { font-size: 10.5px; color: var(--ink-faint); font-weight: 600; }

.empty { text-align: center; padding: 46px 20px; color: var(--ink-faint); }
.empty .em { font-size: 34px; display: block; margin-bottom: 10px; opacity: .55; }
.empty p { margin: 0 0 4px; font-size: 13.5px; }

/* 我的作品小列表 */
.mine { display: grid; gap: 9px; }
.mine-item {
  display: flex; gap: 10px; align-items: center;
  padding: 9px 11px; border-radius: var(--r-md);
  background: var(--cream); border: 1px solid var(--line); text-align: left; width: 100%;
}
.mine-item .rank-thumb { width: 56px; height: 46px; }
.mine-item b { font-family: var(--font-serif); font-size: 14px; display: block; }
.mine-item span { font-size: 11px; color: var(--ink-faint); }
.mine-item .sc { margin-left: auto; font-family: var(--font-serif); font-size: 17px; color: var(--burgundy); font-weight: 600; }

/* ============ 分享卡 ============ */
.share-card {
  background: linear-gradient(168deg, var(--white) 0%, var(--cream) 62%, var(--oat-pale) 100%);
  border-radius: var(--r-lg); padding: 22px 20px 18px;
  border: 1px solid var(--oat-light); text-align: center;
  position: relative; overflow: hidden;
}
.share-card .logo-lockup { color: var(--burgundy); }
.share-card .cake-svg { max-width: 230px; margin: 6px auto 0; }
.share-card .sc-name { font-family: var(--font-serif); font-size: 22px; font-weight: 600; letter-spacing: .05em; margin: 2px 0 4px; }
.share-card .sc-meta { font-size: 11.5px; color: var(--ink-faint); }
.share-card .sc-score { font-family: var(--font-serif); font-size: 15px; color: var(--burgundy); margin-top: 8px; letter-spacing: .05em; }
.share-card .sc-foot {
  margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--oat-light);
  font-size: 10.5px; color: var(--ink-faint); letter-spacing: .1em;
}

/* ============ 提示 ============ */
.toast {
  position: fixed; left: 50%; bottom: calc(94px + var(--safe-b));
  transform: translate(-50%, 12px); z-index: 80;
  background: var(--ink); color: #fff;
  padding: 10px 18px; border-radius: var(--r-full);
  font-size: 13px; opacity: 0; pointer-events: none;
  transition: opacity .22s, transform .22s; max-width: 80%; text-align: center;
}
.toast.on { opacity: .96; transform: translate(-50%, 0); }

/* ============ 加载/骨架 ============ */
.spin {
  width: 17px; height: 17px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.32); border-top-color: #fff;
  animation: spin .7s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============ 桌面适配 ============ */
@media (min-width: 900px) {
  body { background: var(--oat-pale); }
  #app { margin: 22px auto; min-height: calc(100vh - 44px); border-radius: 26px; overflow: hidden; }
  .dock { position: sticky; bottom: 0; transform: none; left: auto; }
}

/* 减少动效偏好 */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ============================================================
   以下为「更像游戏」改版新增的样式
   ============================================================ */

/* ---------- 通用页头 ---------- */
.page-head { padding: 18px 16px 10px; }
.page-head h2 {
  margin: 0 0 4px; font-family: var(--font-serif);
  font-size: 22px; font-weight: 600; letter-spacing: .06em; color: var(--burgundy);
}
.page-head p { margin: 0; font-size: 12.5px; color: var(--ink-faint); line-height: 1.6; }
.empty .dim { font-size: 12px; opacity: .8; }
.empty .btn { display: inline-flex; margin-top: 16px; }
.offline-tip { text-align: center; font-size: 11.5px; color: var(--ink-faint); margin-top: 14px; }

/* ---------- 尺寸 / 模具选项卡 ---------- */
.mats-2 { grid-template-columns: repeat(2, 1fr) !important; }
.opt-big {
  font-family: var(--font-serif); font-size: 26px; font-weight: 600;
  color: var(--burgundy); padding: 8px 0 2px;
}
.opt-sub { font-size: 10.5px; color: var(--ink-faint); margin-top: 3px; line-height: 1.4; }
.shape-grid { grid-template-columns: repeat(2, 1fr) !important; }
.shape-card { padding: 4px 6px 10px; }
.shape-pic { height: 76px; overflow: hidden; display: grid; place-items: center; }
.shape-pic .cake-svg { width: 150%; max-width: none; }
.shape-fee {
  position: absolute; top: 6px; right: 7px; font-size: 10px;
  color: var(--gold); background: #FBF3DC; padding: 1px 6px; border-radius: var(--r-full);
}
.mat.opt .mat-name { font-size: 12.5px; }

/* ---------- 材料卡上的图鉴按钮 ---------- */
.mat { padding-top: 10px; }
.mat-info {
  position: absolute; top: 4px; right: 4px;
  width: 17px; height: 17px; border-radius: 50%;
  background: var(--oat-pale); color: var(--ink-faint);
  font-size: 10px; font-style: italic; font-weight: 700;
  line-height: 17px; text-align: center; z-index: 2;
}
.mat.on .mat-info { background: rgba(255,255,255,.3); color: #fff; }
.mat .season { font-style: normal; font-size: 9px; }
.picker-tip { text-align: center; font-size: 11px; color: var(--ink-faint); margin: 14px 0 0; }
.picker-tip i { font-style: italic; font-weight: 700; }

/* ---------- 模板 ---------- */
.tpl-list { display: grid; gap: 10px; }
.tpl {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  background: var(--cream); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 8px 12px 8px 8px;
}
.tpl:active { transform: scale(.985); }
.tpl-pic { width: 74px; height: 62px; flex: none; display: grid; place-items: center; }
.tpl-pic .cake-svg { width: 100%; height: 100%; max-width: none; }
.tpl-info { flex: 1; min-width: 0; }
.tpl-info b { display: block; font-family: var(--font-serif); font-size: 15px; font-weight: 600; }
.tpl-info span { font-size: 11.5px; color: var(--ink-faint); display: block; margin-top: 2px; line-height: 1.5; }
.tpl-tag {
  display: inline-block !important; margin-left: 7px; font-size: 10px !important;
  color: var(--burgundy) !important; background: var(--burgundy-wash);
  padding: 1px 7px; border-radius: var(--r-full); vertical-align: middle;
}

/* ---------- 食材图鉴 ---------- */
.lore-page { flex: 1; overflow-y: auto; padding-bottom: calc(24px + var(--safe-b)); }
.lore-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
  padding: 12px 16px;
}
.lore-item {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 7px 5px 9px; text-align: center;
  box-shadow: var(--shadow-sm); position: relative;
}
.lore-item:active { transform: scale(.96); }
.lore-item .ink-svg { width: 100%; height: auto; border-radius: 7px; }
.lore-item b { display: block; font-size: 11.5px; margin-top: 5px; font-weight: 500; }
.lore-item-title {
  display: block; font-size: 9.5px; color: var(--ink-faint);
  font-family: var(--font-serif); margin-top: 1px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.lore-item-rare { display: block; font-size: 9px; margin-top: 2px; }
.lore-item.new::after {
  content: 'NEW'; position: absolute; top: 4px; right: 4px;
  font-size: 7.5px; letter-spacing: .06em; background: var(--burgundy);
  color: #fff; padding: 1px 4px; border-radius: 3px;
}

.lore-card { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.lore-pic { flex: none; }
.lore-pic .ink-svg { border-radius: 10px; box-shadow: var(--shadow-md); }
.lore-head { flex: 1; min-width: 0; }
.lore-rare { font-size: 12px; letter-spacing: .1em; font-weight: 600; }
.lore-title {
  font-family: var(--font-serif); font-size: 22px; font-weight: 600;
  margin: 4px 0 5px; letter-spacing: .04em; line-height: 1.25;
}
.lore-name { font-size: 13px; color: var(--ink-soft); }
.lore-name span {
  font-size: 10px; color: var(--ink-faint); letter-spacing: .08em;
  text-transform: uppercase; margin-left: 4px;
}
.lore-text {
  font-size: 14px; line-height: 1.85; color: var(--ink);
  margin: 0 0 14px; padding: 14px 15px;
  background: linear-gradient(135deg, #FBF6EA, var(--oat-pale));
  border-radius: var(--r-md); border-left: 3px solid var(--oat);
  font-family: var(--font-serif);
}
.lore-know {
  background: var(--cream); border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 13px 14px; margin-bottom: 14px;
}
.lore-know h4 { margin: 0 0 7px; font-size: 12px; color: var(--ink-soft); letter-spacing: .08em; }
.lore-know p { margin: 0; font-size: 12.5px; line-height: 1.75; color: var(--ink-soft); }
.lore-meta {
  display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px;
  padding-top: 10px; border-top: 1px dashed var(--oat-light);
  font-size: 11px; color: var(--ink-faint);
}

/* ---------- 恭喜完成 ---------- */
.celebrate {
  flex: 1; position: relative; overflow: hidden;
  background: radial-gradient(120% 62% at 50% 0%, #fff 0%, var(--cream) 62%), var(--cream);
}
.cel-inner {
  position: relative; z-index: 2; padding: 18px 20px calc(28px + var(--safe-b));
  text-align: center;
}
.cel-tag {
  display: inline-block; font-size: 11.5px; letter-spacing: .3em;
  color: var(--burgundy); background: var(--burgundy-wash);
  padding: 5px 16px; border-radius: var(--r-full); text-indent: .3em;
  animation: pop .5s cubic-bezier(.34,1.56,.64,1) both;
}
.cel-cake {
  margin: 6px auto 0; max-width: 290px;
  animation: pop .6s .1s cubic-bezier(.34,1.56,.64,1) both;
}
.cel-name {
  font-family: var(--font-serif); font-size: 30px; font-weight: 700;
  letter-spacing: .06em; margin: 0 0 4px; color: var(--ink);
  animation: pop .5s .24s cubic-bezier(.34,1.56,.64,1) both;
}
.cel-sub { font-size: 12.5px; color: var(--ink-faint); margin: 0 0 16px;
  animation: pop .5s .3s both; }
.cel-score {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 15px; box-shadow: var(--shadow-md); margin-bottom: 14px;
  animation: pop .5s .38s cubic-bezier(.34,1.56,.64,1) both;
}
.cel-score-num { display: flex; align-items: baseline; justify-content: center; gap: 6px; }
.cel-score-num b {
  font-family: var(--font-serif); font-size: 54px; line-height: 1;
  color: var(--burgundy); font-weight: 700;
}
.cel-score-num span { font-size: 14px; color: var(--ink-faint); }
.cel-tier {
  display: inline-block; margin-top: 9px; padding: 5px 15px;
  border-radius: var(--r-full); font-size: 13px; font-weight: 600;
  background: var(--burgundy); color: #fff;
}
.cel-badges { margin-bottom: 18px; }
.cel-badges h3 {
  font-size: 13px; color: var(--ink-soft); letter-spacing: .08em;
  margin: 0 0 10px; font-weight: 600;
}
.badge-wall { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.badge-wall .badge-item { animation: pop .44s cubic-bezier(.34,1.56,.64,1) both; }
.cel-cta { display: grid; gap: 10px; max-width: 320px; margin: 0 auto; }
@keyframes pop {
  from { opacity: 0; transform: scale(.72) translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* 撒花 */
.confetti { position: absolute; inset: 0; pointer-events: none; z-index: 1; overflow: hidden; }
.confetti i {
  position: absolute; top: -24px; border-radius: 2px; opacity: .92;
  animation-name: fall; animation-timing-function: linear; animation-iteration-count: 1;
}
@keyframes fall {
  0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(105vh) rotate(620deg); opacity: .1; }
}

/* ---------- 徽章 ---------- */
.badge-item {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 12px; border-radius: var(--r-full);
  font-size: 12px; font-weight: 500; border: 1px solid var(--oat-light);
  background: linear-gradient(135deg, #F5EEE1, var(--oat-pale));
}
.badge-item em { font-style: normal; font-size: 14px; }
.badge-item b { font-weight: 500; }
.badge-item.t-rare { background: linear-gradient(135deg,#FBF0D2,#F3E4B8); border-color: #E8D08A; color: #8A6A18; }
.badge-item.t-epic { background: linear-gradient(135deg,#F2E4F7,#E6D0EF); border-color: #D3B0E4; color: #6B2480; }
.badge-tip { margin: 10px 0 0; font-size: 11px; color: var(--ink-faint); }
.badge-more {
  display: inline-flex; align-items: center; padding: 7px 12px;
  font-size: 12px; color: var(--ink-faint);
}

/* ---------- 成绩单 ---------- */
.result-by {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--ink-soft); margin-bottom: 4px;
}
.result-by svg { border-radius: 50%; }
.result-tierdesc { font-size: 12.5px; color: var(--ink-faint); margin: 10px 0 0; line-height: 1.6; }
.result-cta { display: grid; gap: 10px; margin-top: 4px; }
.result-foot { text-align: center; font-size: 11px; color: var(--ink-faint); margin: 16px 0 0; line-height: 1.7; }
.part-grid {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; margin-top: 10px;
}
.part { text-align: center; }
.part-bar {
  height: 42px; width: 100%; max-width: 16px; margin: 0 auto 5px;
  background: var(--oat-pale); border-radius: 4px;
  display: flex; align-items: flex-end; overflow: hidden;
}
.part-bar i { display: block; width: 100%; background: var(--burgundy); border-radius: 4px; }
.part b { display: block; font-family: var(--font-serif); font-size: 14px; color: var(--burgundy); font-weight: 600; }
.part span { font-size: 9.5px; color: var(--ink-faint); }
.part em { font-style: normal; opacity: .65; }

/* ---------- 署名 / 头像 ---------- */
.signer { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--oat-light); }
.signer h4 { margin: 0 0 10px; font-size: 12px; color: var(--ink-soft); letter-spacing: .08em; }
.signer-row { display: flex; align-items: center; gap: 11px; }
.signer-avatar { flex: none; border-radius: 50%; overflow: hidden; line-height: 0; }
.signer-avatar:active { transform: scale(.94); }
.signer-name {
  flex: 1; padding: 11px 13px; border-radius: var(--r-md);
  border: 1.5px solid var(--line); background: var(--cream); font-size: 15px;
}
.signer-name:focus { outline: none; border-color: var(--burgundy); background: #fff; }
.signer-tip { margin: 9px 0 0; font-size: 11px; color: var(--ink-faint); line-height: 1.6; }
.avatar-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px;
}
.avatar-opt {
  padding: 8px 4px; border-radius: var(--r-md); border: 1.5px solid var(--line);
  background: var(--white); text-align: center;
}
.avatar-opt.on { border-color: var(--burgundy); box-shadow: 0 3px 10px rgba(79,11,36,.14); }
.avatar-opt span { display: block; font-size: 10px; color: var(--ink-faint); margin-top: 3px; }
.avatar-opt svg { border-radius: 50%; }
.ideas-loading { text-align: center; padding: 18px; color: var(--ink-faint); font-size: 13px; }

/* ---------- 打星与评价 ---------- */
.review-box { margin-top: 4px; }
.review-hint { font-size: 11.5px; color: var(--ink-faint); margin: -4px 0 10px; }
.stars { display: flex; gap: 2px; justify-content: center; margin-bottom: 6px; }
.star {
  font-size: 22px; color: var(--line); line-height: 1;
  transition: color .12s, transform .12s;
}
.star.on { color: #E8B92C; }
.star:active { transform: scale(1.2); }
.star-now { text-align: center; font-size: 11.5px; color: var(--ink-faint); margin-bottom: 10px; }
.review-text {
  width: 100%; padding: 11px 13px; border-radius: var(--r-md);
  border: 1.5px solid var(--line); background: var(--cream);
  font-size: 13.5px; resize: none; line-height: 1.6;
}
.review-text:focus { outline: none; border-color: var(--burgundy); background: #fff; }
.review-box .btn { margin-top: 9px; width: 100%; }
.review-list { display: grid; gap: 11px; margin-top: 14px; }
.review { display: flex; gap: 10px; align-items: flex-start; }
.review svg { flex: none; border-radius: 50%; }
.review-main { flex: 1; min-width: 0; }
.review-main b { font-size: 12.5px; font-weight: 600; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.review-stars { font-style: normal; color: #E8B92C; font-size: 10.5px; letter-spacing: -1px; }
.review-main p { margin: 3px 0 0; font-size: 13px; color: var(--ink-soft); line-height: 1.6; }
.review-work { font-size: 10.5px; color: var(--ink-faint); display: block; margin-top: 3px; }
.review-empty { text-align: center; font-size: 12px; color: var(--ink-faint); padding: 14px 0; }

/* ---------- 论坛 ---------- */
.forum { flex: 1; overflow-y: auto; padding-bottom: calc(24px + var(--safe-b)); }
.forum-tabs {
  display: flex; gap: 8px; padding: 0 16px 12px;
}
.forum-tabs button {
  flex: 1; padding: 9px; border-radius: var(--r-full);
  background: var(--white); border: 1px solid var(--line);
  font-size: 13px; color: var(--ink-soft);
}
.forum-tabs button.on { background: var(--burgundy); border-color: var(--burgundy); color: #fff; font-weight: 600; }
#forumBody { padding: 0 16px; }
.voice-form { display: grid; gap: 11px; }
.voice-tip { font-size: 12.5px; color: var(--ink-faint); line-height: 1.7; margin: 0; }
.voice-form .signer-row { margin-bottom: 0; }

/* ---------- 榜单增强 ---------- */
.board-prize {
  display: inline-block; margin-top: 8px; padding: 4px 11px;
  background: rgba(255,255,255,.16); border-radius: var(--r-full);
  font-size: 11.5px; position: relative;
}
.rank-by {
  display: flex !important; align-items: center; gap: 5px;
  font-size: 11px; color: var(--ink-soft); margin-top: 2px;
}
.rank-by svg { border-radius: 50%; flex: none; }
.rank-meta { font-size: 10.5px; color: var(--ink-faint); display: block; margin-top: 1px; }
.rank-info { background: none; border: none; padding: 0; text-align: left; }
.rank-item.top1 { border-color: #E8D08A; box-shadow: 0 3px 14px rgba(184,145,47,.18); }
.rank-item.top2, .rank-item.top3 { border-color: var(--oat-light); }

/* ---------- 我的作品 ---------- */
.mine-head { display: flex; align-items: center; gap: 13px; margin-bottom: 14px; }
.mine-head h3 { margin: 0; }
.mine-head .sub { margin: 2px 0 0; }
.mine-badges { margin-bottom: 14px; }
.mine-info { flex: 1; min-width: 0; }
.mine-info b { display: block; font-family: var(--font-serif); font-size: 14px; }
.mine-info span { font-size: 11px; color: var(--ink-faint); }
.unlock-tip { text-align: center; font-size: 11.5px; color: var(--ink-faint); margin: 9px 0 0; }

/* ---------- 桌面端 ---------- */
@media (min-width: 900px) {
  .lore-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ============ 背景音乐 ============ */
/* 顶栏那个跳动的小均衡器 */
.eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 13px; }
.eq i {
  width: 2.5px; height: 4px; border-radius: 1.5px;
  background: var(--ink-soft); transition: background .2s;
}
.icon-btn.playing .eq i { background: var(--burgundy); animation: eqjump .9s ease-in-out infinite; }
.icon-btn.playing .eq i:nth-child(2) { animation-duration: .68s; animation-delay: .12s; }
.icon-btn.playing .eq i:nth-child(3) { animation-duration: 1.05s; animation-delay: .26s; }
@keyframes eqjump { 0%, 100% { height: 4px; } 50% { height: 12px; } }

.music-now {
  display: flex; align-items: center; gap: 13px;
  background: linear-gradient(135deg, var(--burgundy), var(--burgundy-deep));
  color: #fff; border-radius: var(--r-lg); padding: 15px 16px; margin-bottom: 14px;
}
.music-play {
  flex: none; width: 46px; height: 46px; border-radius: 50%;
  background: rgba(255,255,255,.16); color: #fff;
  font-size: 15px; display: grid; place-items: center; transition: .16s;
}
.music-play.on { background: #fff; color: var(--burgundy); }
.music-play:active { transform: scale(.92); }
.music-meta { flex: 1; min-width: 0; }
.music-meta b { display: block; font-family: var(--font-serif); font-size: 17px; letter-spacing: .04em; }
.music-meta span { font-size: 11.5px; opacity: .78; }
.eq.big { height: 22px; gap: 3px; }
.eq.big i { width: 3px; height: 5px; background: rgba(255,255,255,.4); }
.eq.big.playing i { background: #fff; animation: eqjumpbig .9s ease-in-out infinite; }
.eq.big.playing i:nth-child(2) { animation-duration: .64s; animation-delay: .1s; }
.eq.big.playing i:nth-child(3) { animation-duration: 1.1s; animation-delay: .22s; }
.eq.big.playing i:nth-child(4) { animation-duration: .78s; animation-delay: .34s; }
@keyframes eqjumpbig { 0%, 100% { height: 5px; } 50% { height: 21px; } }

.music-vol { display: flex; align-items: center; gap: 11px; margin-bottom: 18px; font-size: 13px; }
.music-vol input {
  flex: 1; -webkit-appearance: none; appearance: none; height: 4px;
  background: var(--line); border-radius: var(--r-full); outline: none;
}
.music-vol input::-webkit-slider-thumb {
  -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%;
  background: var(--burgundy); cursor: pointer; box-shadow: 0 1px 4px rgba(79,11,36,.3);
}
.music-vol input::-moz-range-thumb {
  width: 18px; height: 18px; border: none; border-radius: 50%; background: var(--burgundy);
}
.music-h { margin: 0 0 10px; font-size: 12px; color: var(--ink-soft); letter-spacing: .08em; }
.track-list { display: grid; gap: 8px; }
.track {
  display: flex; align-items: center; gap: 11px; width: 100%; text-align: left;
  padding: 11px 13px; border-radius: var(--r-md);
  background: var(--cream); border: 1.5px solid var(--line); transition: .16s;
}
.track.on { border-color: var(--burgundy); background: var(--burgundy-wash); }
.track:active { transform: scale(.985); }
.track-dot {
  flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: var(--line); transition: .16s;
}
.track.on .track-dot { background: var(--burgundy); box-shadow: 0 0 0 3px rgba(79,11,36,.14); }
.track-info { flex: 1; min-width: 0; }
.track-info b { display: block; font-size: 14px; font-weight: 600; }
.track-info span { font-size: 11px; color: var(--ink-faint); }
.track-bpm { flex: none; font-size: 11px; color: var(--ink-faint); font-family: var(--font-serif); }
.music-tip { margin: 16px 0 0; font-size: 11px; color: var(--ink-faint); line-height: 1.75; }

/* ============ 音量键 ============ */
.vol-btn { color: var(--burgundy); }
.vol-btn.muted { color: var(--ink-faint); background: var(--line); }
.vol-ico { display: grid; place-items: center; line-height: 0; }
.vol-ico svg { display: block; }
.music-acts { display: flex; gap: 8px; margin-bottom: 16px; }
.music-acts .btn { flex: 1; }
.vol-mini { font-size: 13px; opacity: .7; }

/* ============ 大量徽章的展示 ============ */
/* 一次能拿三四十枚，chip 要够紧凑，不然恭喜页拉不到底 */
.badge-wall { gap: 6px; }
.badge-wall .badge-item,
.badges .badge-item {
  padding: 5px 10px; font-size: 11.5px; gap: 4px; border-radius: var(--r-full);
}
.badge-item em { font-size: 12.5px; }
.cel-badges h3 { font-size: 14px; margin-bottom: 4px; }
.cel-badge-sum {
  font-family: var(--font-serif); font-size: 34px; font-weight: 700;
  color: var(--burgundy); line-height: 1.1;
}
.cel-badge-sum span { font-size: 14px; font-weight: 400; color: var(--ink-faint); margin-left: 4px; }
.cel-badge-tip { font-size: 11.5px; color: var(--ink-faint); margin: 2px 0 12px; }
.badge-more-btn {
  display: block; margin: 12px auto 0; padding: 8px 18px;
  border-radius: var(--r-full); background: var(--oat-pale);
  color: var(--ink-soft); font-size: 12.5px;
}
.badge-group-title {
  font-size: 11px; color: var(--ink-faint); letter-spacing: .1em;
  margin: 12px 0 7px; text-align: left;
}
