/* ============================================================
   Game Diary · 手账薄荷绿主题（notebook mint style）
   点阵纸背景 + 白色圆角卡片，参考"청사이"风格
   ============================================================ */

/* v10 问题6：安卓 WebView 点击瞬间会闪一块蓝色高亮（tap highlight），
   点按钮/链接时特别明显。全局关掉，不影响正常的 :hover / :focus 反馈。 */
html, body, * { -webkit-tap-highlight-color: transparent; }

:root {
  --bg: #e9f3ec;
  --card: #ffffff;
  --line: #cfe3d6;
  --line-soft: #e2efe7;
  --text: #2f4438;
  --muted: #334a3c;
  --green: #3e9e6d;
  --green-soft: #a5d9b6;
  --green-dark: #34845c;
  --mint: #e3f2e8;
  --mint-deep: #d3e9dc;
  --pink: #fde8ec;
  --pink-text: #d76a82;
  --gold: #b0885e;
  --shadow: 0 4px 14px rgba(80, 140, 110, 0.10);
  --radius: 16px;
  --sidebar-w: 244px;
  /* Repo 表：标签（作品：/时长：…）用淡色，冒号后的内容用深色 */
  --label-pale: #a8c49a;
  /* 四行小评分（美术/剧情/音乐/配音）的浅一档绿，取自参考图 #94b17c */
  --grade-soft: #94b17c;
}

/* 方正姚体（本机 C:\Windows\Fonts\FZYTK.TTF 转 woff2）——冒号后面的数值统一用它 */
@font-face {
  font-family: 'FZ YaoTi';
  src: url('/static/fonts/fzyt/fzyt.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
  /* 姚体自带的垂直度量 ascent 98.8% / descent 14.8%，基线在行盒里比粗黑宋标签低
     (98.8-14.8)/2 - (92.6-29.3)/2 = 10.3% em ≈ 18pt 下 2.5px，看起来就是内容整体往下沉。
     这里用 ascent-override 把度量对齐成粗黑宋（标签字体）的 92.6% / 29.3%，
     基线自动和「作品：/时长：/日期：」齐平，且不影响字形本身。
     v147 起生效 —— 只改 @font-face，不动各元素的位置，屏幕和导出会一起变好 */
  ascent-override: 92.6%;
  descent-override: 29.3%;
  line-gap-override: 0%;
}

/* 标签用的粗方正字（微软雅黑 Bold 子集）——"作品：/时长：/本篇/是"等标签用它，
   和冒号后纤细的姚体形成粗细对比，手机上也一致 */
@font-face {
  font-family: 'Label Bold';
  src: url('/static/fonts/labels/label-bold.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}

/* 方正粗黑宋简体（本机 C:\Windows\Fonts\方正粗黑宋简体.ttf 子集）——Repo 表所有标签用它 */
@font-face {
  font-family: 'FZ CuHeiSong';
  /* v302：原 102 字子集不含「盲狙/实际喜欢/最让人心疼」等可编辑标签用字，
     会静默回退文楷；换成本机全量 8112 字，新文件名避开浏览器旧缓存 */
  src: url('/static/fonts/labels/cuheisong_full.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "LXGW WenKai Screen", "Segoe Print", "YouYuan", "幼圆", "Microsoft YaHei", sans-serif;
  color: var(--text);
  line-height: 1.75;
  background-color: var(--bg);
  /* 书法绿水彩背景（白层很薄，保住水彩颜色浓度） */
  background-image:
    linear-gradient(rgba(246, 250, 247, 0.22), rgba(246, 250, 247, 0.22)),
    url('/static/bg.jpg?v=24');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}

/* 全站统一字体：表单控件与按钮默认不继承，这里强制继承霞鹜文楷 */
button, input, select, textarea, optgroup, option,
code, pre, kbd, samp {
  font-family: inherit;
}

/* ---------------- Sidebar ---------------- */
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar-w);
  padding: 22px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
  z-index: 10;
}
.side-profile {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px 14px;
  text-align: center;
}
.sp-avatar {
  width: 92px;
  height: 92px;
  margin: 0 auto 10px;
  border-radius: 50%;
  border: 2px solid var(--mint-deep);
  background: var(--mint);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 34px;
}
.sp-avatar img { width: 100%; height: 100%; object-fit: cover; }
.sp-name { font-size: 17px; font-weight: 700; letter-spacing: 2px; }
.sp-sub { font-size: 12px; font-weight: 500; color: var(--muted); margin: 2px 0 10px; }
.sp-pills { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.sp-btn {
  display: block;
  margin-top: 12px;
  background: var(--green);
  color: #fff;
  text-decoration: none;
  font-size: 12.5px;
  padding: 7px 0;
  border-radius: 999px;
  letter-spacing: 2px;
}
.sp-btn:hover { background: var(--green-dark); }

.side-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px 10px;
}
.side-cap {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--green);
  padding: 0 8px 8px;
}
.side-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  text-decoration: none;
  font-size: 13.5px;
  padding: 8px 10px;
  border-radius: 10px;
}
.side-item i { font-style: normal; font-size: 8px; color: var(--green); opacity: 0.7; }
.side-item em { font-style: normal; margin-left: auto; font-size: 11px; color: var(--muted); }
.side-item:hover { background: var(--mint); }
.side-item.active { background: var(--mint); font-weight: 700; color: var(--green-dark); }

.side-foot {
  margin-top: auto;
  text-align: center;
  font-size: 10.5px;
  color: var(--muted);
  letter-spacing: 1px;
  line-height: 1.9;
}

/* ---------------- Main ---------------- */
.main {
  margin-left: var(--sidebar-w);
  padding: 26px 34px 10px;
  max-width: calc(var(--sidebar-w) + 1020px);
}

/* ---------------- Identity Card ---------------- */
.idcard {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.idc-title {
  background: linear-gradient(180deg, #eaf6ee, #ddefe3);
  border-bottom: 1px solid var(--line);
  text-align: center;
  padding: 12px;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 5px;
  color: var(--green-dark);
}
.idc-title span { font-size: 11px; letter-spacing: 3px; color: var(--muted); font-weight: 400; }
/* 名片标题是居中的，锁用绝对定位贴右边，标题文字一点都不会移位 */
.idc-title { position: relative; }
.idc-title .sec-lock {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
}

.idc-grid {
  display: grid;
  grid-template-columns: 190px 1fr 0.78fr;
  grid-template-areas:
    "left mid right"
    "fav fav fav";
  gap: 16px;
  padding: 20px;
}
.idc-left { grid-area: left; display: flex; flex-direction: column; gap: 16px; }
.idc-mid { grid-area: mid; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-content: start; }
.idc-right { grid-area: right; }
.favbox { grid-area: fav; }

/* 左列头像卡 */
.pcard {
  background: var(--mint);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 12px;
  text-align: center;
}
.pcard-avatar {
  width: 104px;
  height: 118px;
  margin: 0 auto 10px;
  border-radius: 14px;
  border: 2px solid #fff;
  background: #fff;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 38px;
}
.pcard-avatar img { width: 100%; height: 100%; object-fit: cover; }
.pcard-name { font-size: 18px; font-weight: 700; letter-spacing: 3px; }
.pcard-sub { font-size: 12px; font-weight: 500; color: var(--muted); margin: 2px 0 10px; }
.pcard-pills { display: flex; justify-content: center; flex-wrap: wrap; gap: 5px; }

.picbox {
  flex: 0 0 auto;
  height: 170px;
  min-height: 0;
  background: var(--mint);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.picbox img { width: 100%; height: 100%; object-fit: cover; }
.picbox-ph { color: var(--muted); letter-spacing: 6px; font-size: 14px; }

/* 中列信息格 */
.ibox {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
}
.ibox h4 {
  margin: 0 0 4px;
  font-size: 14px;
  letter-spacing: 1.5px;
  color: var(--label);
  font-weight: 700;
}
.ibox p { margin: 0; font-size: 13px; font-weight: 500; color: var(--muted); }
/* 中列顶部的横跨长框 */
.ibox-wide { grid-column: 1 / -1; }

/* 右列 NOTE */
.notebox {
  background: var(--mint);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
}
.note-tags { display: flex; gap: 6px; margin-bottom: 8px; }
.notebox h4 {
  margin: 0 0 8px;
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--label);
}
.notebox p { margin: 0 0 8px; font-size: 13px; font-weight: 500; color: #445c4d; }

/* Favorite 横条：六栏竖排 */
.favbox {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px 18px 8px;
}
.favbox h4 {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  background: var(--card);
  padding: 0 14px;
  font-size: 16px;
  letter-spacing: 3px;
  color: var(--label);
  white-space: nowrap;      /* 装饰字符长标题不折行，避免白底块变高压到上面的框 */
  max-width: 96%;
  overflow: hidden;
}
.fav-cols {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0 16px;
  padding-bottom: 8px;
}
.fav-col h5 {
  margin: 0 0 6px;
  font-size: 10px;
  letter-spacing: 1.5px;
  color: var(--label);
  font-weight: 700;
  border-bottom: 1px dotted var(--line);
  padding-bottom: 4px;
}
.fav-col p { margin: 0; font-size: 13.5px; font-weight: 500; color: var(--muted); line-height: 1.8; }

/* PLAY PROGRESS 横带 */
.progress-band {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 20px 18px;
  background: var(--mint);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 24px;
}
.pb-cap {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--label);
  line-height: 1.5;
  flex: 0 0 auto;
  margin-right: 64px;
}
/* PLAY PROGRESS 右侧的所有项目均分剩余宽度 */
.pb-item, .pb-playing {
  flex: 1 1 0;
  justify-content: center;
  text-align: center;
}
.pb-item { text-align: center; }
.pb-item b {
  display: block;
  font-size: 24px;
  font-weight: 700;
  color: var(--green-dark);
  line-height: 1.2;
}
/* 合计游戏时长后面的 h+ 后缀，比数字略小一点 */
.pb-item b .pb-unit { font-size: .62em; font-weight: 700; letter-spacing: 0; margin-left: 1px; }
.pb-item i { font-style: normal; font-size: 12px; font-weight: 500; color: var(--muted); }
/* 正在打：横向排列，右侧填作品名字 */
.pb-playing {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}
.pb-playing i {
  font-style: normal;
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}
.pb-names {
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  border-bottom: 1px dotted var(--line);
  padding-bottom: 2px;
}

/* 底部两个大框 */
.idc-bottom {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 0 20px 20px;
}
.bigbox {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 26px 18px 14px;
  min-height: 0;
}
/* 标题骑在框线正中（同 Favorite 样式） */
.bigbox h4 {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  background: var(--card);
  padding: 0 12px;
  font-size: 16px;
  letter-spacing: 2px;
  color: var(--label);
  border-bottom: none;
  white-space: nowrap;
}
.bigbox p { margin: 0; font-size: 14.5px; font-weight: 500; color: var(--muted); line-height: 1.8; }

/* 绿色小长方形（纯装饰，骑在框顶，淡薄荷绿） */
.gtag {
  display: inline-block;
  width: 26px;
  height: 9px;
  background: var(--green-soft);
  border-radius: 3px;
  box-shadow: 0 2px 5px rgba(76, 175, 80, .18);
}
.gt-l { position: absolute; top: -5px; left: 16px; }
.gt-r { position: absolute; top: -5px; right: 16px; }
.bigbox > .gtag {
  position: absolute;
  top: -5px;
  left: 16px;
}

/* ---------------- Diary section ---------------- */
.diary { margin-top: 30px; }
.diary-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  border-bottom: 2px solid var(--green);
  padding-bottom: 8px;
  margin-bottom: 6px;
}
.diary-cap { font-size: 10px; letter-spacing: 2.5px; color: #214a33; }
.diary-title { font-size: 21px; font-weight: 700; letter-spacing: 4px; color: #214a33; }

/* 板块标题右边的小锁（只有主人看得到）：开 = 访客能看，关 = 访客整块看不到。
   板块头后面常压着照片背景，所以给它一个浅底 + 描边的小圆钮，不然淡色线条直接看不见。
   尺寸固定、只在名片标题里用 absolute，任何状态下都不推动原有文字。 */
.sec-lock {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  margin: 0 0 0 -4px;      /* 抵掉 .diary-head 的 gap，贴着标题 */
  align-self: center;      /* 不跟 baseline 跑，标题行高度不变 */
  border: 1px solid rgba(52, 132, 92, .5);
  background: rgba(255, 255, 255, .82);
  color: #2f6b4b;
  cursor: pointer;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(60, 110, 80, .18);
  transition: background .15s, border-color .15s, color .15s, transform .12s;
}
.sec-lock svg { width: 13px; height: 13px; display: block; }
.sec-lock:hover { background: #fff; border-color: var(--green-dark); transform: scale(1.06); }
/* 关掉（访客看不到）时：灰掉 + 虚线边，一眼能分出来 */
.sec-lock.off {
  color: #7f8b83;
  border-style: dashed;
  border-color: rgba(127, 139, 131, .75);
  background: rgba(255, 255, 255, .62);
}
.sec-lock .sh-open { display: none; }
.sec-lock.on .sh-closed { display: none; }
.sec-lock.on .sh-open { display: block; }
/* 侧栏：主人这边上了锁的标签变淡（访客根本看不到这条） */
.side-item.sec-off { opacity: .38; }

.tag-bar { margin: 16px 0 8px; display: flex; flex-wrap: wrap; gap: 8px; }
.tag-bar a {
  font-size: 12.5px;
  color: var(--green-dark);
  background: var(--card);
  border: 1px solid var(--line);
  padding: 3px 13px;
  border-radius: 999px;
  text-decoration: none;
}
.tag-bar a:hover { border-color: var(--green); }
.tag-bar a.active { background: var(--green); border-color: var(--green); color: #fff; }
.tag-bar a.all { color: var(--muted); }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
  margin: 18px 0 40px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  display: flex;
  flex-direction: column;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(80, 140, 110, 0.16); }
.card a.title { font-size: 17px; font-weight: 700; color: var(--text); text-decoration: none; }
.card a.title:hover { color: var(--green); }
.card .meta { color: var(--muted); font-size: 12.5px; font-weight: 500; margin: 6px 0; letter-spacing: 0.5px; }
.card .mood { font-size: 15px; }
.card .preview { color: #334a3c; font-size: 13.5px; font-weight: 500; margin-top: 8px; flex: 1; }
.card .tags { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.card .tags span {
  font-size: 11.5px;
  background: var(--mint);
  color: var(--green-dark);
  padding: 2px 10px;
  border-radius: 999px;
}

.empty { text-align: center; color: var(--muted); padding: 60px 0; }
.empty a { color: var(--green); }

/* ---------------- Pills ---------------- */
.pill {
  display: inline-block;
  font-size: 10.5px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--green);
  color: #fff;
  letter-spacing: 1px;
}
.pill.ghost { background: #fff; color: var(--green-dark); border: 1px solid var(--line); }
.pill.ng { background: var(--pink); color: var(--pink-text); }
.pill.member { background: var(--mint-deep); color: var(--green-dark); }

/* ---------------- Detail page ---------------- */
.article {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 34px;
  box-shadow: var(--shadow);
  margin: 10px 0 50px;
}
.article h1 { margin: 0 0 6px; letter-spacing: 1px; color: var(--green-dark); }
.article .meta { color: var(--muted); font-size: 13.5px; margin-bottom: 18px; }
.article a { color: var(--green); }

.markdown-body { font-size: 15.5px; }
.markdown-body h1, .markdown-body h2, .markdown-body h3 { margin-top: 1.4em; }
.markdown-body pre { background: #2f4438; color: #eaf6ee; padding: 14px; border-radius: 10px; overflow: auto; }
.markdown-body code { background: var(--mint); padding: 2px 6px; border-radius: 5px; font-size: 14px; }
.markdown-body pre code { background: none; padding: 0; }
.markdown-body img { max-width: 100%; border-radius: 10px; }
.markdown-body blockquote {
  border-left: 3px solid var(--green);
  margin: 1em 0;
  padding: 4px 16px;
  color: var(--muted);
  background: var(--mint);
}
.markdown-body table { border-collapse: collapse; width: 100%; }
.markdown-body th, .markdown-body td { border: 1px solid var(--line); padding: 6px 10px; }

/* ---------------- Admin form ---------------- */
form.write {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 30px;
  box-shadow: var(--shadow);
  margin: 10px 0 50px;
}
form.write label { display: block; font-size: 14px; font-weight: 700; margin: 14px 0 6px; }
form.write input[type=text], form.write textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 15px;
  font-family: inherit;
  background: #fbfefc;
}
form.write input:focus, form.write textarea:focus { outline: none; border-color: var(--green); }
form.write textarea { min-height: 260px; resize: vertical; }
form.write .row { display: flex; gap: 14px; }
form.write .row > div { flex: 1; }
form.write button {
  margin-top: 18px;
  background: var(--green);
  color: #fff;
  border: none;
  padding: 11px 30px;
  border-radius: 999px;
  font-size: 15px;
  letter-spacing: 2px;
  cursor: pointer;
}
form.write button:hover { background: var(--green-dark); }
#preview {
  margin-top: 8px;
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: 10px;
  min-height: 60px;
  background: #fbfefc;
}
.hint { font-size: 12px; color: var(--muted); }

footer.site {
  text-align: center;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 1.5px;
  padding: 26px 0 40px;
}

/* ---------------- Responsive ---------------- */
@media (max-width: 960px) {
  .fav-cols { grid-template-columns: repeat(3, 1fr); gap: 10px 16px; }
  .idc-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "left mid"
      "left right"
      "fav fav";
  }
  .idc-left { flex-direction: row; }
  .pcard { flex: 1; }
  .picbox { flex: 1; }
}
@media (max-width: 760px) {
  .sidebar {
    position: static;
    width: auto;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: stretch;
  }
  .side-profile { flex: 1; min-width: 200px; }
  .side-card { flex: 1; min-width: 180px; }
  .side-foot { display: none; }
  .main { margin-left: 0; padding: 18px 14px 10px; }
  .idc-grid {
    grid-template-columns: 1fr;
    grid-template-areas: "left" "mid" "right" "fav";
  }
  .fav-cols { grid-template-columns: repeat(2, 1fr); }
  .idc-mid { grid-template-columns: 1fr 1fr; }
  .progress-band { flex-wrap: wrap; gap: 18px; }
  .idc-bottom { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr; }
  form.write .row { flex-direction: column; gap: 0; }
}

/* ---------------- 中式字体：内容幼圆 / 标题中华仿宋 ---------------- */
/* 所有标题 → 中华仿宋 */
.idc-title, .favbox h4, .bigbox h4, .diary-title,
.ibox h4, .notebox h4, .pb-cap, .side-cap, .diary-cap,
.pcard-name, .sp-name, .card a.title, .article h1 {
  font-family: "LXGW WenKai Screen", "Segoe Print", "STFangsong", "华文仿宋", "FangSong", "Microsoft YaHei", sans-serif;
}

/* Favorite 标题带生僻装饰字符（꒰১໒꒱），文楷缺字会变形 → 保持原字体栈 */
.favbox h4 {
  font-family: "LXGW WenKai Screen", "Segoe Print", "STFangsong", "华文仿宋", "FangSong", "Microsoft YaHei", sans-serif;
}

/* ---------------- OC 立绘切换器（点击图片循环切换，标注=文件名） ---------------- */
.oc-art { position: relative; text-align: center; margin: 4px 0 12px; cursor: pointer; user-select: none; }
.oc-art img { display: block; margin: 0 auto; max-width: 92%; max-height: 300px; border-radius: 10px; transition: opacity .18s ease; }
.oc-art-label {
  display: table; margin: 8px auto 0; padding: 2px 14px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--card);
  font-size: 12px; letter-spacing: 2px; color: var(--label);
}
.oc-art-count { position: absolute; top: 8px; right: 10px; font-size: 11px; color: var(--muted); }
.oc-art-empty {
  padding: 28px 10px; border: 1px dashed var(--line); border-radius: 10px;
  font-size: 12px; line-height: 1.9; color: var(--muted);
}

:root { --label: #aadcbc; } /* 淡色小标题（参考 OTOME PROFILE 层次） */

/* ---------------- 透明内容框（通用）：给 bigbox 加 trans 类即可，任何板块可用 ---------------- */
.bigbox.trans {
  background: transparent;
  border-top: none;
}
/* 标题骑线改为"线—空隙—标题—空隙—线"：h4 变横跨框顶的弹性行，左右细线自动填满 */
.bigbox.trans h4 {
  background: transparent;
  top: 0;
  left: 0;
  right: auto;
  transform: translateY(-50%);
  width: 100%;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 14px;
}
.bigbox.trans h4::before, .bigbox.trans h4::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* ---------------- 侧栏锚点平滑滚动 ---------------- */
html { scroll-behavior: smooth; }

/* ---------------- 分组日记板块 ---------------- */
.dgroup { margin-bottom: 34px; }
.dgroup:last-child { margin-bottom: 0; }

/* ---------------- 推し photo carousel ---------------- */
.carousel {
  position: relative;
  margin: 18px 0 8px;
  overflow: hidden;
  padding: 10px 0 26px;
}
.car-track {
  display: flex;
  gap: 18px;
  will-change: transform;
}
.car-slide {
  flex: 0 0 auto;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--card);
  box-shadow: var(--shadow);
  opacity: 0.45;
  transform: scale(0.92);
  transition: opacity 0.4s, transform 0.4s;
}
.car-slide.is-center { opacity: 1; transform: scale(1); }
.car-slide img {
  display: block;
  height: 440px;
  width: auto;
  /* 竖图(3:4)约 330px 宽、横图等比放大，均按原始比例完整显示不裁切 */
}
.car-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(35, 50, 42, 0.78);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.car-btn:hover { background: var(--green-dark); }
.car-prev { left: 26px; }
.car-next { right: 26px; }
.car-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  display: flex;
  justify-content: center;
  gap: 8px;
}
.car-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--line);
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}
.car-dot.active { background: var(--green); transform: scale(1.25); }

/* ---------------- 后台删除按钮 ---------------- */
.del-row { margin-top: -12px; text-align: right; }
.del-btn {
  background: none; border: none; cursor: pointer; padding: 6px 4px;
  font-size: 12px; letter-spacing: 1px; color: #c07a7a;
}
.del-btn:hover { color: #d9534f; text-decoration: underline; }

/* ============================================================
   Report 写作系统（作品一览 / 录入 / 三大板块编辑页）
   ============================================================ */
/* 写作后台悬停菜单 */
.sp-write { position: relative; display: inline-block; }
.sp-write .write-menu {
  display: none; position: absolute; left: 50%; bottom: calc(100% + 6px);
  transform: translateX(-50%);
  background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow); padding: 6px; min-width: 128px; z-index: 30;
}
.sp-write:hover .write-menu { display: block; }
.sp-write .write-menu a {
  display: block; padding: 6px 12px; border-radius: 8px;
  font-size: 13px; color: var(--text); text-decoration: none; white-space: nowrap;
}
.sp-write .write-menu a:hover { background: var(--mint); color: var(--green-dark); }

/* 通用按钮 */
.btn-main {
  display: inline-block; background: var(--green-soft); color: #1f3d2b;
  border: 1px solid var(--line); border-radius: 999px; padding: 7px 18px;
  font-size: 14px; text-decoration: none; cursor: pointer;
  font-family: inherit; transition: background .15s ease;
}
.btn-main:hover { background: #8ecfa4; }
.btn-sub {
  display: inline-block; background: var(--card); color: var(--green-dark);
  border: 1px solid var(--line); border-radius: 999px; padding: 7px 18px;
  font-size: 14px; text-decoration: none; cursor: pointer;
  font-family: inherit; transition: background .15s ease;
}
.btn-sub:hover { background: var(--mint); }
.btn-main.sm, .btn-sub.sm { padding: 4px 12px; font-size: 12px; }

/* 作品一览页 */
.works-page { max-width: 980px; margin: 0 auto; padding-bottom: 30px; }
.works-search { display: flex; gap: 10px; margin: 18px 0 14px; }
.works-search input {
  flex: 1; padding: 9px 16px; border: 1px solid var(--line); border-radius: 999px;
  font-family: inherit; font-size: 14px; background: var(--card); color: var(--text);
}
.works-search button {
  padding: 9px 22px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--card); color: var(--green-dark); cursor: pointer; font-family: inherit;
}
.works-search button:hover { background: var(--mint); }

.works-add {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 12px 18px; margin-bottom: 20px;
}
.works-add summary { cursor: pointer; font-weight: 700; color: var(--green-dark); letter-spacing: 1px; }
.works-add-form { margin-top: 12px; }
.wa-row { display: flex; flex-wrap: wrap; gap: 18px; margin-bottom: 12px; }
.wa-row label { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.wa-row input[type="text"] {
  padding: 7px 12px; border: 1px solid var(--line); border-radius: 10px;
  font-family: inherit; font-size: 14px; width: 220px; background: #fff; color: var(--text);
}
/* v516：原生「选择文件」按钮太丑（Danmi 18:46 截图）——只给按钮和文件名重新上色，
   行为、选中逻辑、表单提交全不动。桌面/手机同一套。 */
.wa-row label input[type="file"] {
  font-family: inherit; font-size: 12px; color: #a2918c;
  background: #fff; border: 1.3px solid #e7d3cd; border-radius: 999px;
  padding: 3px 12px 3px 4px; max-width: 100%; cursor: pointer;
  width: -moz-fit-content; width: fit-content;   /* 贴着内容，不装成一个空框 */
}
.wa-row label input[type="file"]::-webkit-file-upload-button,
.wa-row label input[type="file"]::file-selector-button {
  font-family: inherit; font-size: 11px; color: #bd7777;
  background: #fdf4f2; border: 1.3px solid #d9b9b2; border-radius: 999px;
  padding: 5px 13px; margin: 0 9px 0 0; cursor: pointer;
}
.wa-row label input[type="file"]:hover::-webkit-file-upload-button,
.wa-row label input[type="file"]:hover::file-selector-button { background: #fbe9e5; }
/* v394：手机端并排「角色图」小按钮（wa-foot 内），桌面用不到一律隐藏；
   手机端把 wa-row 里的原「角色图」控件（.wa-img-src）缩成不可见但仍可被 label-for 触发 */
.wa-img-m { display: none; }

.works-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px; }
.work-card {
  position: relative; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px; text-align: center;
}
.wc-cover { display: block; height: auto; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: var(--mint); }
.wc-cover img { width: 100%; height: 100%; object-fit: cover; }
.wc-none { display: flex; align-items: center; justify-content: center; height: 100%; font-size: 34px; }
.wc-name { font-weight: 700; margin-top: 8px; color: var(--text); }
.wc-meta { font-size: 11px; color: var(--muted); opacity: .75; margin: 2px 0 8px; }


/* 卡带状态 / 游玩状态 胶囊（点一下切换，和首页 PLAY PROGRESS 联动） */
.wc-status { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.chip {
  padding: 2px 12px; border-radius: 999px; font-family: inherit; font-size: 12px;
  line-height: 1.7; letter-spacing: .5px; cursor: pointer; white-space: nowrap;
  border: 1px dashed var(--line); background: transparent; color: var(--muted);
  transition: background .15s ease, color .15s ease, border-color .15s ease, opacity .15s ease;
}
.chip:hover { filter: brightness(.98); border-color: var(--green-soft); }
.chip.saving { opacity: .5; cursor: progress; }
.chip.shake { animation: chipShake .35s ease; }
@keyframes chipShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-3px); }
  75% { transform: translateX(3px); }
}

/* 卡带状态：在库 / 未拥有 / 已出 / 外借 */
.chip[data-value="在库"] { background: var(--mint); border: 1px solid var(--green-soft); color: var(--green-dark); font-weight: 700; }
.chip[data-value="未拥有"] { background: #f4f6f4; border: 1px dashed #ceded6; color: #7b887f; }
.chip[data-value="已出"] { background: var(--pink); border: 1px solid #f6cfd8; color: var(--pink-text); }
.chip[data-value="外借"] { background: #f8efdf; border: 1px solid #e8d5b6; color: #a87c45; }

/* 游玩状态：待游玩 / 进行中 / 全通 */
.chip[data-value="待游玩"] { background: #f7fbf8; border: 1px dashed #c6ddcf; color: #6d8377; }
.chip[data-value="进行中"] { background: var(--mint-deep); border: 1px solid var(--green-soft); color: var(--green-dark); }
.chip[data-value="全通"] { background: var(--green); border: 1px solid var(--green); color: #fff; font-weight: 700; }

.wc-btns { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.wc-del { position: absolute; top: 8px; right: 8px; }
.wc-del button { background: none; border: none; cursor: pointer; font-size: 14px; opacity: .5; }
.wc-del button:hover { opacity: 1; }

/* 卡片左上角的置顶小圆点：点一下置顶，再点取消（点亮 = 已置顶，排到列表最前面）
   悬浮在封面角上，半透明白底 + 磨砂，别抢封面；访客只看得见已置顶的那个点 */
.wc-pin {
  position: absolute; top: 16px; left: 16px; z-index: 3;
  width: 13px; height: 13px; padding: 0; border-radius: 50%;
  border: 1px solid rgba(248, 181, 180, .8);
  background: rgba(248, 181, 180, .42);
  box-shadow: 0 1px 3px rgba(120, 60, 60, .16);
  -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px);
  cursor: pointer; opacity: .72;
  transition: opacity .15s ease, background .15s ease, transform .15s ease, box-shadow .15s ease;
}
.wc-pin:hover { opacity: 1; transform: scale(1.18); }
.wc-pin.saving { opacity: .5; }
.wc-pin.on {
  opacity: .9; background: rgba(248, 181, 180, .92); border-color: rgba(248, 181, 180, .95);
  box-shadow: 0 1px 5px rgba(200, 120, 120, .35), 0 0 0 2px rgba(253, 254, 251, .55);
}
.readonly .wc-pin { pointer-events: none; cursor: default; }
.readonly .wc-pin:not(.on) { display: none; }

/* 录入角色页 */
.manage-top { display: flex; gap: 18px; align-items: center; margin: 14px 0 18px; }
.manage-cover { width: 160px; border-radius: 10px; border: 1px solid var(--line); }
.manage-links { display: flex; gap: 10px; }
.chars-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.char-card {
  position: relative; background: var(--card); border: 1px solid var(--line);
  border-radius: 12px; box-shadow: var(--shadow); padding: 10px; text-align: center;
}
.char-card img { width: 100%; height: 160px; object-fit: cover; border-radius: 8px; }
.char-card .wc-none { height: 160px; font-size: 30px; }

/* 编辑页公共 */
.edit-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 14px 0 18px; flex-wrap: wrap; }
.edit-switch { display: inline-flex; gap: 8px; flex-wrap: wrap; }
.sw-btn {
  padding: 6px 16px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); color: var(--muted); text-decoration: none; font-size: 13px;
}
.sw-btn.on { background: var(--green-soft); color: #1f3d2b; font-weight: 700; }
.edit-foot { display: flex; justify-content: flex-end; align-items: center; gap: 14px; margin-top: 14px; }
.save-state { font-size: 12px; color: var(--green-dark); opacity: .85; }
.rp-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 14px; flex-wrap: wrap; }
.back-home { margin-top: 24px; }
.back-home a { color: var(--green-dark); }

/* 角色印象行 */
.imp-list { display: flex; flex-direction: column; gap: 14px; }
.imp-row {
  display: flex; gap: 26px; flex-wrap: wrap; align-items: center;
  padding: 14px 10px; background: #fff; border: 0; box-shadow: none; border-radius: 6px;
}
.imp-char { display: flex; flex-direction: column; align-items: center; gap: 10px; flex: 0 0 200px; }
.imp-list { gap: 30px; }
.imp-sel, .route-sel, .award-sel {
  padding: 6px 10px; border: 1px solid var(--line); border-radius: 10px;
  font-family: inherit; font-size: 13px; background: #fff; color: var(--text); max-width: 170px;
}
.imp-img, .route-img {
  width: 200px; height: 200px; border-radius: 4px;
  border: 1.5px dashed rgba(140,170,120,.8); background-color: #fff;
  background-size: cover; background-position: center; background-repeat: no-repeat;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.imp-img .ph, .route-img .ph { color: #b9c7a8; font-size: 14px; letter-spacing: 2px; }
/* v442：角色印象 / 分线评价 左侧角色图空位，中央统一成淡绿加号（与盲狙表同一套观感）。
   挂 edit-only → 访客只读自动隐藏；导出时被 repo_tools.js 的 strip 名单剔除，成品图不受影响。 */
.imp-img .ph-plus, .route-img .ph-plus {
  font-size: 22px; line-height: 1; color: var(--green-soft); opacity: .6;
  pointer-events: none;
}
.imp-img.filled .ph, .route-img.filled .ph { display: none; }
.imp-img.filled, .route-img.filled { border: none; }
.imp-img.filled:hover, .route-img.filled:hover { filter: brightness(.95); }
.imp-img:not(.filled), .route-img:not(.filled) { border-style: dashed; background-color: #fbfdf8; }
.award-name { font-weight: 700; font-size: 15px; color: #7a9c5e; letter-spacing: 1px; }
.imp-texts { flex: 1; min-width: 260px; display: flex; flex-direction: column; gap: 8px; min-height: 200px; align-self: flex-start; }
.imp-field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.imp-texts .imp-field.tone { min-height: 109px; }
.imp-field textarea { font-family: inherit; color: var(--text); resize: none; overflow: hidden; }
.imp-field textarea:focus { outline: none; }
.imp-label { font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-size: 16px; font-weight: 400; color: var(--green-dark); letter-spacing: 1px; }   /* v422：13→15；v424：15→16 */
/* 初印象：白底细框，占小份 */
.imp-field.plain {
  flex: 0 0 auto; min-height: 78px; background: #fff; border: 1px solid #dfe9d2;
  border-radius: 16px; padding: 9px 14px 11px;
}
.imp-field.plain textarea {
  border: none; border-radius: 0; padding: 2px 0 0;
  font-size: 18px; line-height: 1.85; background: transparent; min-height: 24px;   /* v422：14→16；v424：16→18 */
}
/* 现印象 / 碎碎念：浅绿大圆角框，占大份 */
.imp-field.tone {
  flex: 1 1 auto; min-height: 114px; background: #e8f4dd; border: 1px solid rgba(140,170,120,.18);
  border-radius: 16px; padding: 9px 14px 13px;
}
.imp-field.tone textarea {
  flex: 1 1 auto; border: none; background: transparent; padding: 2px 0 0;
  font-size: 18px; line-height: 1.85; min-height: 44px;   /* v422：14→16；v424：16→18 */
}

/* 印象排版 1/2 切换钮：放标题行最右；edit-only = 访客隐藏 + 导出剔除 */
.imp-mode-toggle {
  margin-left: auto; align-self: center;
  display: inline-flex; align-items: center; gap: 3px;
  padding: 3px; border-radius: 999px;
  background: rgba(255, 255, 255, .95);
  border: 1px solid rgba(122, 160, 91, .45);
  box-shadow: 0 1px 5px rgba(122, 160, 91, .16);
}
.imp-mode-toggle b {
  width: 19px; height: 19px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'LXGW WenKai Screen', serif; font-size: 12px; font-weight: 400;
  color: #7a9c5e; line-height: 1; cursor: pointer;
}
.imp-mode-toggle b:hover { background: rgba(122, 160, 91, .14); }
.imp-mode-toggle b.on { background: var(--green-dark); color: #fff; }
.imp-mode-toggle b.on:hover { background: var(--green-dark); }

/* 模式 2：初印象 / 现印象 左右并排 —— 两个框强制【等宽 + 等高】各占一半
   （.plain 基础是 flex:0 0 auto、.tone 基础是 flex:1 1 auto，
     这里用三级类名选择器 .imp-list.two-col .imp-field.plain/.tone 显式压平成 flex:1 1 0，
     保证并排时两框严格等长；align-items:stretch 保证等高） */
.imp-list.two-col .imp-texts { flex-direction: row; gap: 14px; align-items: stretch; }
.imp-list.two-col .imp-field { flex: 1 1 0; min-width: 0; }
/* 初印象略窄于现印象：0.85 : 1（原 1:1 完全等宽）；想让两框恢复等宽就把 0.85 改回 1 */
.imp-list.two-col .imp-field.plain { flex: .85 1 0; min-height: 0; }
.imp-list.two-col .imp-field.tone { flex: 1 1 0; min-height: 0; }
.imp-list.two-col .imp-field textarea { flex: 1 1 auto; }

.row-tools { display: flex; justify-content: center; gap: 10px; margin-top: 14px; }
.rt-add, .rt-del {
  width: 44px; height: 32px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); font-size: 17px; cursor: pointer; color: var(--green-dark); font-family: inherit;
}
.rt-add:hover, .rt-del:hover { background: var(--mint); }

/* ---------------- Notes（含未公开CG）模块 —— 比前三个模块大一圈 ---------------- */
/* Notes 页放宽：不受 works-page 980px 限宽（仅 Notes 页生效），两侧少留空 */
body:has(.nt-page) .main { max-width: none; }
.nt-page { max-width: none; }

.nt-list { display: flex; flex-direction: column; gap: 30px; }
.nt-row {
  display: flex; gap: 12px; align-items: stretch; flex-wrap: nowrap;
  padding: 16px 12px; background: #fff; border: 0; box-shadow: none; border-radius: 6px;
}
/* 角色图：正方形、比框矮一截、整体在高度上居中 */
.nt-left { flex: 0 0 200px; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.nt-char {
  width: 200px; height: 200px; border-radius: 4px;
  border: none; background-color: #fbfdf8;
  background-size: cover; background-position: center; background-repeat: no-repeat;
  cursor: pointer;
}
.nt-char.filled { background-color: #fff; }
.nt-char.filled:hover { filter: brightness(.95); }
/* 碎碎念：定高（和角色图等高），内容超出在框内滚动 */
.nt-mid { flex: 0 0 240px; display: flex; }
.nt-notes {
  flex: 1; resize: none; overflow-y: auto;
  background: #f3f7ed; border: none; border-radius: 4px; padding: 12px 14px;
  font-family: inherit; font-size: 14.5px; line-height: 1.8; color: var(--text);
}
.nt-notes:focus { outline: none; }
/* CG 区：占完剩余宽度，高度同样 340，轮播切换 */
.nt-rightcol { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.nt-right { flex: 1; min-height: 0; display: flex; align-items: stretch; gap: 6px; }
/* 外层只做布局（框在上、圆点在下），本身无框无填充——避免套出第二层框 */
.nt-cg-wrap {
  flex: 1; min-width: 0; display: flex; flex-direction: column;
  gap: 6px;
}
/* CG 显示区：16:9 横长方形，宽撑满右列（行高由它撑起来），无填充、只一条细线框 */
.nt-cg-view {
  flex: 0 0 auto; width: 100%; aspect-ratio: 16 / 9; border: 1px solid #dfe9d2; border-radius: 4px;
  background: transparent; display: flex; align-items: center; justify-content: center; overflow: hidden;
}
/* v442：CG 空位原来写「（CG 图）」文字，统一换成淡绿加号（Danmi：这些放图的地方也是） */
.nt-cg-ph { color: var(--green-soft); font-size: 24px; line-height: 1; letter-spacing: 0; opacity: .6; }
.nt-cg-view img { width: 100%; height: 100%; object-fit: cover; }
.nt-cg-view.filled { border: none; background: #fff; }
.nt-cg-bar { flex: 0 0 auto; display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 18px; }
.nt-cg-count { font-size: 12px; color: var(--muted); }
.nt-cg-dots { display: flex; gap: 6px; }
.nt-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #d5e2c4; cursor: pointer; display: inline-block;
}
.nt-dot.on { background: var(--green-dark); }
/* 选中条目：底部「上传CG/删除本张」的作用目标 */
.nt-row.active { outline: 2px solid rgba(140,170,120,.4); outline-offset: 2px; }
/* 每条自己的 CG 按钮：贴在圆点条最右侧，与「1/2 ● ●」同行 */
.nt-cg-bar { position: relative; }
.nt-cg-actions {
  position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  display: flex; gap: 8px;
}
.nt-cg-actions .nt-btn {
  padding: 2px 10px; font-size: 12px;
}
.nt-btn {
  border: 1px solid var(--line); background: var(--card); border-radius: 999px;
  color: var(--green-dark); font-size: 13px; cursor: pointer; padding: 6px 14px;
  white-space: nowrap; font-family: inherit;
}
.nt-btn:hover { background: var(--mint); }

/* 分线评价行 */
.routes-list { display: flex; flex-direction: column; gap: 14px; }
.route-row {
  display: flex; gap: 26px; flex-wrap: wrap; align-items: center;
  padding: 14px 10px; background: #fff; border: 0; box-shadow: none; border-radius: 6px;
}
.routes-list { gap: 30px; }
.route-left { display: flex; flex-direction: column; align-items: center; gap: 10px; flex: 0 0 200px; }
.route-right { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; min-height: 200px; }
/* 人设 / 剧情：绿色粗体数字 + 直接下拉选分（无下划线，与日期选择同一视觉） */
.route-scores { display: flex; flex-direction: column; gap: 2px; }
.score { display: flex; align-items: center; gap: 3px; font-size: 15px; color: #7a9c5e; font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; }
.score-k, .score-max { color: #7a9c5e; letter-spacing: 1px; white-space: nowrap; }
.score-sel {
  border: none; background: transparent; box-shadow: none;
  font-family: inherit; font-size: 15px; font-weight: 400; color: var(--green-dark);
  padding: 0 1px; width: 44px; cursor: pointer;
  text-align: center; text-align-last: center;
  -webkit-appearance: none; -moz-appearance: none; appearance: none;
}
.score-sel:hover { background: #f1f7ea; border-radius: 6px; }
.score-sel:focus { outline: none; }
.score-sel option { color: #1f3d2b; font-weight: 400; }
/* 碎碎念：浅绿大圆角框，占满右侧整宽 */
.route-notes { flex: 1 1 auto; min-width: 0; min-height: 138px; margin-top: 2px; }
.route-notes.imp-field.tone textarea { min-height: 56px; }

/* 日乙Repo表导出图「外面」：米绿菱格 + 星星（Danmi 指定 repo_outer.png，v308 由粉换绿）。
   只加背景，不改任何几何属性 → 网页与导出图同步，布局一像素不动。
   #capture 是四个作品编辑页共用的 id，所以必须用 report 页专属 class。 */
.rp-capture {
  background-color: #f3f5e9;
  background-image: url('/static/bg/repo_outer.png');
  background-size: 300px 300px;
  background-position: 0 0;
  background-repeat: repeat;
}
/* 日乙Report表 —— 严格对齐手绘模版：纸感卡框 + 虚线内框 */
.rp-sheet {
  /* v307 起卡片整层铺「外背景」；v308 外背景换绿菱格 → 实线框外 12px 也跟着变绿 */
  background: #f3f5e9 url('/static/bg/repo_outer.png') 0 0 / 300px 300px repeat;
  /* v309：Danmi 说卡片外沿「绿绿的细线」不要 → 1px 边框改透明，保留占位不动几何；
     3px 实线内框在 .rp-frame，照旧保留 */
  border: 1px solid transparent; border-radius: 6px;
  box-shadow: var(--shadow); padding: 26px 34px;
  position: relative; z-index: 0;   /* 建 stacking context，让 .rp-frame 能沉到内容下 */
}
/* 实线内框：用真实元素而非 ::before（截图库不重排伪元素几何，导出会错位） */
.rp-frame {
  position: absolute; inset: 12px; border: 3px solid rgba(122,160,91,.5);
  border-radius: 14px; pointer-events: none;
  /* 框内仍是白纸 + 淡粉点；z-index:-1 沉到内容之下（框外 12px 则露出上面的外格纹） */
  background: #fff url('/static/bg/repo_inner.png') 0 0 / 174px 174px repeat;
  z-index: -1;
}
.rp-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 14px; flex-wrap: wrap; }
.rp-head.center { justify-content: center; }
/* 标题在卡片外面：v310 Danmi 要「再大一点」32pt -> 36pt；
   固定行高 56pt（＝原 32pt×1.75）保住行盒，导出几何零改动 */
.rp-cap {
  font-size: 36pt; line-height: 56pt; font-weight: 500; color: var(--green-dark); letter-spacing: 2px;
  text-shadow: 2px 2px 0 rgba(122,160,91,.3), -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff;
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
}
.rp-worktitle {
  border: none; background: transparent;
  /* 作品名也是「作品：」冒号后的内容，v147 一起换成姚体（之前漏了这一处，还是文楷） */
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 18pt; font-weight: 400; color: var(--green-dark);
  padding: 0 2px; min-width: 7ch; max-width: 360px;
  field-sizing: content;  /* 输入框宽度跟着内容走，导出后也不会多出一截空白 */
  line-height: 32px;      /* v311 固定＝原 16pt×1.5，字号放大不撑高行盒 */
}
.rp-worktitle:focus { outline: none; }
.rp-worktitle::placeholder { color: #a8bda2; font-weight: 400; }
/* 手机端标题镜像（可编辑 span，做两行省略号）；桌面/导出隐藏，只用 #worktitle input */
.rp-worktitle-m { display: none; }


.rpt-top { display: flex; gap: 30px; margin-bottom: 20px; align-items: flex-start; }
.rp-cover-box { flex: 0 0 auto; display: flex; }
.rp-cover { border-radius: 2px; }
/* 卡带图：固定大框，背景图等比裁切，导出照片不变形 */
.rp-cover.big {
  width: 235px; height: 365px;
  border: 1.5px dashed rgba(122,160,91,.55);
  background-color: #fff; background-size: cover; background-position: center;
  background-repeat: no-repeat;
}
.rp-cover.big.none {
  display: flex; align-items: center; justify-content: center;
  color: #b9c7a8; font-size: 15px; letter-spacing: 2px;
}
/* 有图：虚线框消失，图片铺满 */
.rp-cover.big:not(.none) { border: none; }
.rpt-info { flex: 1; min-width: 300px; display: flex; flex-direction: column; gap: 20px; justify-content: center; padding-top: 2px; }
.rpt-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
/* 标签：方正粗黑宋简体 + 淡绿 #a8c49a。粗黑宋只有 400 一档，字形本身就是粗黑宋，
   不再叠 font-weight 700/800 —— 浏览器合成粗体只会把笔画糊掉
   配色规则（v144 起全表统一）：标签一律淡绿，冒号后的内容一律深绿 --green-dark。
   v301：标签由 #a8c49a 加深到 #8fae80（v303 曾改 #7ca478，v304 已回退） */
.rpt-label {
  font-family: 'FZ CuHeiSong', 'LXGW WenKai Screen', serif;
  font-weight: 400; color: #8fae80; font-size: 18pt; letter-spacing: .5px;
}
/* 全通：不是独立标签，是「全通：是/否」的引导词，和冒号后的内容同色（深绿） */
.rpt-label.mid { font-size: 18pt; color: var(--green-dark); }
.rpt-label.sm { font-family: 'FZ CuHeiSong', 'LXGW WenKai Screen', serif; font-size: 15pt; color: #8fae80; letter-spacing: .3px; }
/* 总体评价：同样粗黑宋，但不额外加粗 */
.rpt-label.xl { font-size: 20pt; font-weight: 400; letter-spacing: 1px; }
.rpt-label.gap { margin-left: 34px; }
.rpt-fill { flex: 1; }

/* ---------------- 作品评价小浮层（Repo 表） ----------------
   圆点绝对定位在「日期」那一行右侧空白，不占布局、不挤动任何现有元素；
   浮层 fixed 且挂在 #capture 外面 → 导出照片里不会出现。 */
.has-memo { position: relative; }
.rp-memo-dot {
  position: absolute; left: 81%; top: 50%; transform: translateY(-50%) translateY(24px);
  width: 46px; height: 46px; padding: 0; border-radius: 50%;
  border: 1px solid var(--line); background: rgba(255,255,255,.92);
  color: var(--green-dark); font-family: inherit; font-size: 0; line-height: 0;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; opacity: .8; box-shadow: 0 1px 3px rgba(157,111,104,.14);
  transition: opacity .15s ease, background .15s ease, border-color .15s ease;
}
.rp-memo-dot svg { display: block; }
.rp-memo-dot:hover { opacity: 1; background: var(--mint); border-color: #d9b9b2; }
.rp-memo-pop {
  position: fixed; z-index: 80; box-sizing: border-box;
  width: 265px; height: 340px; padding: 13px 14px 12px;
  display: flex; flex-direction: column;
  background: #fffdfc; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 12px 28px rgba(157,111,104,.18);
}
.rp-memo-pop[hidden] { display: none; }
.rp-memo-head {
  flex: 0 0 auto; text-align: center; margin-bottom: 8px;
  font-size: 13px; letter-spacing: .12em; color: var(--green-dark);
}
.rp-memo-text {
  flex: 1 1 auto; width: 100%; box-sizing: border-box;
  border: 0; outline: none; resize: none; background: transparent;
  font-family: inherit; font-size: 13.5px; line-height: 1.8; color: var(--text);
}
@media (max-width: 760px) { .rp-memo-dot { left: auto; right: 0; } }
/* 冒号后面的内容：统一方正姚体 + 深色（v146：全部改用 FZ YaoTi 完整版，
   姚体只有 400 一档，不再叠 font-weight，避免浏览器合成粗体糊笔画） */
.rp-text {
  width: 96px; border: none; background: transparent;
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 20pt; font-weight: 400; color: var(--green-dark);
  text-align: center; padding: 2px 4px;
  line-height: 33px;      /* v311 固定行盒，字号放大不撑高 */
}
.rp-text:focus { outline: none; }
.dategrp { display: inline-flex; align-items: center; gap: 1px; }
.dot { font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; color: var(--green-dark); font-weight: 400; margin: 0 1px; }
.dash { font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; color: var(--green-dark); font-weight: 400; letter-spacing: 2px; margin: 0 12px; }

/* 日期下拉：透明无边框，看起来像 0000.00.00 文本（小二 18pt，方正姚体） */
.numsel {
  border: none; background: transparent; font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 20pt; color: var(--green-dark); font-weight: 400; padding: 0 1px; cursor: pointer;
  -webkit-appearance: none; appearance: none; text-align: center;
  /* select 默认高度会被压到 1em（24px），而姚体 18pt 的字体盒要 29px，
     上下各被切掉 2.5px —— 数字看起来是被顶上去、还缺笔画。
     给足行高，让它和 .rp-text 一样有 33px 的内容盒 */
  line-height: 24.75pt;   /* v311 固定＝原 18pt×1.375＝33px */
  /* 宽度＝年份 4 个数字（2em）、月日 2 个数字（1em）+ 左右各 1px。
     v312：必须绑 em 随字号走；v311 曾写死成 36pt，20pt 字号下 4 位年份溢出、下拉点不开 */
  width: calc(2em + 2px);
  box-sizing: border-box;
}
#dfm, #dfd, #dtm, #dtd { width: calc(1em + 2px); }

/* 手输日期：下拉里选「编辑」后就地换成它。尺寸/字体/颜色/居中全部沿用上面的 .numsel，
   宽度与它分毫不差，所以换过去时原来的位置一点不动 */
.numfree {
  display: none; width: calc(2em + 2px); height: 24.75pt; line-height: 24.75pt;
  box-sizing: border-box; margin: 0; padding: 0 1px;
  border: none; background: transparent;
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 20pt; font-weight: 400; color: var(--green-dark);
  text-align: center;
}
.numfree.numfree-2 { width: calc(1em + 2px); }
.numfree:focus { outline: none; }
.numfree.on { display: inline-block; }
.numsel.off { display: none; }

/* 手输分数：和 .score-sel 同宽（44px）同字号，换过去时位置不动 */
.score-free {
  display: none; width: 44px; box-sizing: border-box; margin: 0; padding: 0 1px;
  border: none; background: transparent;
  font-family: inherit; font-size: 15px; font-weight: 400; color: var(--green-dark);
  text-align: center; line-height: normal;
}
.score-free:focus { outline: none; }
.score-free.on { display: inline-block; }
.score-sel.off { display: none; }

/* 打钩方块：文字 + 空心小方框。未选 = 和标签一样的淡绿；勾上 = 深绿（和冒号后的内容同色） */
.tick {
  cursor: pointer; color: var(--label-pale);
  font-family: 'FZ CuHeiSong', 'LXGW WenKai Screen', serif;
  font-size: 18pt; font-weight: 400; letter-spacing: .5px;
  user-select: none; display: inline-flex; align-items: center; gap: 8px;
}
.tick::after {
  content: ''; display: inline-block; width: 21px; height: 21px;
  border: 1.6px solid var(--label-pale); background: #fff; line-height: 21px;
  font-size: 15px; text-align: center; font-weight: 700; color: var(--green);
}
.tick.on::after { content: '✓'; border-color: var(--green-dark); }
/* 勾上后只换颜色（淡绿 → 深绿），不再加粗：粗黑宋只有 400 一档，
   叠加 700 是浏览器合成粗体，会把笔画糊掉 */
.tick.on { color: var(--green-dark); }

/* 「本篇/fd」「全通：是/否」整组左移：
   右侧留出和下面评分行等宽的空白，让最右边那个方框的右边缘正好落在
   「美术/剧情」「音乐/配音」两行最后一个 D 的右边缘上（同一条竖线）。
   605.81px = 两组评分并排时的总宽（组宽 285.91×2 + 组间距 34）；
   —— 圈从 25×32 改成 30×30 正圆后，每行宽了 30px，这个常量也要跟着改，
      实测第二组右边缘 = 行左端 + 605.81px。
   写成 100% 的算式是为了窗口变宽时自动补差，窄屏放不下两组时归零、不挤压内容 */
.tickgrp {
  display: inline-flex; align-items: center; gap: 8px;
  margin-right: max(0px, calc(100% - 605.81px));
}

/* 打圈评分：字号放大后两组并排放不下，改成一列四行、每组横向铺满，字母均匀分布 */
/* 2×2 排布（美术/剧情一行、音乐/配音一行）：组内间距压到最小才放得下两列 */
.ggrp { display: inline-flex; flex: 0 1 auto; align-items: center; gap: 7px; white-space: nowrap; }
.ggrp + .ggrp { margin-left: 26px; }
.ggrp .rpt-label.sm { margin-right: 3px; }
.grade-line { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
/* 宽高必须相等才是正圆：之前 min-width:25 / height:32 出来的是竖椭圆。
   30px 直径 ≈ 字母高(18.67px) 的 1.6 倍，S+ 两个字符也塞得下；
   flex:0 0 auto 防止被 flex 压缩（压缩后又会变扁）。
   弹性和下面 .tickgrp 的 calc 常量是按这个宽度算的，改尺寸要同步改那边 */
.grade {
  display: inline-flex; align-items: center; justify-content: center;
  flex: 0 0 auto; width: 30px; height: 30px; padding: 0; border-radius: 50%;
  border: none; cursor: pointer; color: var(--green-dark);
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 16pt; font-weight: 400; user-select: none; transition: background-color .12s ease;
}
/* 姚体只有 400 一档：选中态靠实心圆片区分，不叠 700（会合成糊字） */
.grade.big { font-size: 22pt; font-weight: 400; width: 46px; height: 46px; padding: 0; color: var(--green-dark); }
.grade:hover { background-color: rgba(168,196,154,.28); }
/* 选中 = 实心圆片（比框填充略深 #dde9d0）+ 深绿加粗字母；写在 :hover 之后，选中态不被 hover 覆盖 */
.grade.on { background-color: #dde9d0; color: var(--green-dark); font-weight: 700; }
/* 总体评价那一行同款圆片 */
.grade.big.on { background-color: #dde9d0; color: var(--green-dark); font-weight: 700; }


/* 攻略顺序 / 好感排名：整宽，标题带 ☆，内容为浅绿圆角框 */
.rpt-areas { display: flex; flex-direction: column; gap: 34px; margin-bottom: 34px; }
.rpt-area {
  position: relative; border: 1.5px solid rgba(140,170,120,.32);
  border-radius: 20px; background: #eaf1e2;
}
/* 标题夹在框的上边线上：用卡片底色遮住边框，两侧线条自然断在文字两旁 */
.rpt-area-title {
  position: absolute; top: 0; left: 22px; z-index: 3;
  transform: translateY(-50%);
  margin: 0; padding: 0 14px;
  /* 上半=卡片白底、下半=框内浅绿：盖住边框线但不留白块 */
  background: linear-gradient(to bottom, #fdfefb 0 50%, #eaf1e2 50% 100%);
  white-space: nowrap;
  /* 标题：方正粗黑宋简体，34px，字距 4px，夹在框线上 */
  font-family: 'FZ CuHeiSong', 'LXGW WenKai Screen', serif;
  font-size: 34px; font-weight: 400; line-height: 1.12;
  color: var(--green-dark); letter-spacing: 4px;
}
.rpt-area textarea {
  display: block; width: 100%; box-sizing: border-box; height: 96px; border: none; resize: none;
  /* 攻略顺序 / 好感排名 的正文：方正姚体（v146 改用姚体，字重保持 400 单档，靠字号撑气势） */
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 24pt; font-weight: 400; color: var(--text);   /* v424：Danmi「字体再大一点」22→24pt（手机 ≤720 有 9.5pt 覆盖，不受影响） */
  background: transparent; border-radius: 20px; padding: 0 20px; line-height: 1.5;
  text-align: center;
}
.rpt-area textarea::placeholder { font-weight: 400; color: #a8bda2; }
.rpt-area textarea:focus { outline: none; }

/* 8 个角色奖项：2 行 × 4 列图片卡片格（正方形，背景图等比裁切不变形） */
.awards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px 18px; }
.award-card { display: flex; flex-direction: column; align-items: center; gap: 8px; cursor: pointer; user-select: none; }
.award-box {
  width: 100%; height: 0; padding-top: 100%;
  border: 1.5px dashed rgba(122,160,91,.55); background: #fff; position: relative; overflow: hidden;
}
.award-imgbox {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  background-size: cover; background-position: center; background-repeat: no-repeat;
}
.award-box .ph {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  display: flex; align-items: center; justify-content: center;
  color: #b9c7a8; font-size: 13px; letter-spacing: 1px;
}
.award-box.filled .ph { display: none; }
/* v440：日乙Repo表 8 个奖项格，空位中央也统一成淡绿加号（与盲狙表 bpl-plus 同一套观感）。
   挂 edit-only → 访客只读时自动隐藏，导出时被 repo_tools.js 的 strip 名单剔除，不进成品图。 */
.award-box .award-plus {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; color: var(--green-soft); opacity: .6;
  pointer-events: none;
}
.award-box.filled .award-plus { display: none; }
.award-box.filled { border: none; }
/* 1 / 2 张图切换钮：居中方钮；默认藏起来，鼠标移到卡片上才浮现（不看图有没有放） */
.award-mode {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: inline-flex; align-items: center; gap: 3px; z-index: 3;
  padding: 3px; border-radius: 999px;
  background: rgba(255, 255, 255, .95);
  border: 1px solid rgba(122, 160, 91, .45);
  box-shadow: 0 1px 5px rgba(122, 160, 91, .16);
  transition: opacity .15s ease;
}
.award-mode b {
  width: 19px; height: 19px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'LXGW WenKai Screen', serif; font-size: 12px; font-weight: 400;
  color: #7a9c5e; line-height: 1; cursor: pointer;
}
.award-mode b:hover { background: rgba(122, 160, 91, .14); }
.award-mode b.on { background: var(--green-dark); color: #fff; }
.award-mode b.on:hover { background: var(--green-dark); }
.award-box .award-mode { opacity: 0; pointer-events: none; }
.award-card:hover .award-box .award-mode { opacity: 1; pointer-events: auto; }
.award-card:hover .award-box .award-mode b { pointer-events: auto; }
/* 触屏没有 hover：半透明常显，否则手机上切不回单图 */
@media (hover: none) {
  .award-box .award-mode { opacity: .6; pointer-events: auto; }
}
/* 两张模式：框里按住可以拖动照片调整位置（touch-action 关掉，否则手机上变成翻页） */
.award-card[data-two="1"] .award-box { cursor: grab; touch-action: none; }
.award-card.dragging .award-box { cursor: grabbing; }
.award-label {
  width: 100%; border: none; background: transparent;
  /* v310 Danmi 要「改回姚体然后加一点点大」：粗黑宋 -> 姚体，22px -> 24px */
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  text-align: center; font-weight: 400; font-size: 24px; color: var(--green-dark);
  padding: 0; margin: 0; cursor: text;
  /* 姚体 15px 的字体盒正好 18px，等于 input 默认高度——上下一点余量都没有，
     字被切成半截。放大行高留出余量 */
  /* v310 固定行盒 33px（＝原 22px×1.5）：字号 22->24px 不撑高卡片，导出几何零改动 */
  line-height: 33px;
}
.award-label:focus { outline: none; }
.award-label::placeholder { color: #b9c7a8; }

@media (max-width: 720px) {
  /* 窄屏放不下两列：模式 2 回退成上下两格 */
  .imp-list.two-col .imp-texts { flex-direction: column; }
  /* v313：回退成上下两格后必须撤掉并排用的 flex-basis:0，
     否则两框按 0.85:1 瓜分固定高度、长文字溢出框外被下框盖住 */
  .imp-list.two-col .imp-field,
  .imp-list.two-col .imp-field.plain,
  .imp-list.two-col .imp-field.tone { flex: 0 0 auto; }
  /* stretch 而不是 center：否则 .rpt-info 宽度按内容撑开，右侧勾选会被顶出卡片 */
  .rpt-top { flex-direction: column; align-items: stretch; }
  .rp-cover-box { align-self: center; }
  .awards { grid-template-columns: repeat(2, 1fr); }
  /* 手机 2 列，单格约 172px，加号跟着小一号；桌面 211px 格用 22px */
  .award-box .award-plus { font-size: 18px; }
  .rp-sheet { padding: 20px 14px; }
  .rp-cover.big { width: 200px; min-height: 300px; max-height: 380px; height: 300px; }
  /* 手机上整套字号收一号：标签是粗体、占位更宽，不缩会顶出卡片右边 */
  .rpt-info { min-width: 0; width: 100%; }
  .rpt-label, .rpt-label.mid { font-size: 13.5pt; letter-spacing: 0; }
  .rpt-label.xl { font-size: 15pt; letter-spacing: .3px; }
  .rpt-label.sm { font-size: 11pt; letter-spacing: 0; }
  .rpt-label.gap { margin-left: 12px; }
  .tick { font-size: 13.5pt; gap: 5px; letter-spacing: 0; }
  .tick::after { width: 17px; height: 17px; line-height: 17px; font-size: 12px; }
  .rpt-line { gap: 4px 6px; }
  .rpt-fill { flex: 0 1 0; min-width: 0; }
  .rp-text, .numsel, .numfree { font-size: 16pt; }
  .grade { width: 24px; height: 24px; font-size: 14pt; }
  .grade.big { width: 36px; height: 36px; font-size: 18pt; }
  .ggrp { gap: 5px; }
  .ggrp + .ggrp { margin-left: 14px; }
  .rpt-area-title { font-size: 23pt; letter-spacing: 1.5px; padding: 0 10px; }
  /* 正文在手机上 22pt 太满，缩到 17pt 并让顶部避开标题贴纸 */
  .rpt-area textarea { font-size: 14.5pt; padding: 12px 10px 0; line-height: 1.55; }
  .award-label { font-size: 18px; line-height: 27px; }
}

/* 首页 Report 作品轮播 */
.car-none {
  display: flex; align-items: center; justify-content: center; text-align: center;
  width: 220px; height: 150px; background: var(--mint); color: var(--muted);
  border-radius: 10px; font-size: 14px;
}
.car-name {
  display: block; text-align: center; font-size: 13px; font-weight: 700;
  color: var(--green-dark); margin-top: 6px;
}
.see-more { text-align: center; margin-top: 12px; }


/* ===== 修改录入数据页（作品 / 角色） ===== */
.info-form { display: flex; flex-direction: column; gap: 18px; }
.info-block {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 18px 20px;
}
.info-h { font-size: 15px; font-weight: 700; color: var(--green-dark); letter-spacing: 2px; margin: 0 0 14px; }
.info-count { font-size: 12px; color: var(--muted); font-weight: 400; letter-spacing: 0; margin-left: 8px; }
.info-work { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.info-cover {
  width: 130px; height: 170px; flex: 0 0 auto; border-radius: 10px;
  border: 1px solid var(--line-soft); background-color: #fff;
  background-size: cover; background-position: center; background-repeat: no-repeat;
  display: flex; align-items: center; justify-content: center;
}
/* v442：角色录入页缩略图的「（无图）」也统一成淡绿加号（120px 方框，flex 已居中） */
.ic-none { color: var(--green-soft); font-size: 18px; line-height: 1; letter-spacing: 0; opacity: .6; }
.info-fields { flex: 1; min-width: 260px; display: flex; flex-direction: column; gap: 10px; }
.if-row { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.if-label { min-width: 56px; font-weight: 700; color: var(--green-dark); flex: 0 0 auto; }
.if-row input[type="text"] {
  flex: 1; min-width: 0; padding: 7px 10px; border: 1px solid var(--line);
  border-radius: 9px; font-family: inherit; font-size: 14px; color: var(--text); background: #fff;
}
.if-row input[type="text"]:focus { outline: none; border-color: var(--green); }
.if-row input[type="file"] { font-family: inherit; font-size: 12px; color: var(--muted); flex: 1; min-width: 0; }
.if-check { font-size: 12px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.if-tip { font-size: 12px; color: var(--muted); margin: 0; }
.info-chars { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.info-char {
  background: var(--mint); border: 1px solid var(--line-soft); border-radius: 12px;
  padding: 12px; display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.ic-img {
  width: 120px; height: 120px; border-radius: 10px; border: 1px solid var(--line-soft);
  background-color: #fff; background-size: cover; background-position: center; background-repeat: no-repeat;
  display: flex; align-items: center; justify-content: center;
}
.info-char .if-row { width: 100%; }
.info-char .if-label { min-width: 40px; font-size: 12px; }
.info-actions { display: flex; gap: 12px; justify-content: flex-end; padding-bottom: 8px; }
.wc-edit { position: absolute; top: 8px; left: 8px; font-size: 14px; text-decoration: none; opacity: .5; }
.wc-edit:hover { opacity: 1; }
@media (max-width: 560px) {
  .info-work { flex-direction: column; align-items: center; }
  .info-chars { grid-template-columns: 1fr; }
}

/* 修改页：删除按钮 / 危险区 */
.ic-del {
  margin-top: 2px; padding: 4px 12px; border-radius: 999px;
  border: 1px solid #e8cccc; background: #fff8f8; color: #b45454;
  font-family: inherit; font-size: 12px; cursor: pointer;
}
.ic-del:hover { background: #fdeaea; border-color: #d9a5a5; }
.ic-del.big { padding: 8px 20px; font-size: 13px; }
.danger-zone { border-color: #eddcdc; background: #fffdfd; }
.danger-zone .info-h { color: #b45454; }
.danger-zone .if-tip { margin-bottom: 12px; }

/* 手机端：角色图与右侧内容改为上下排列（导出仍按 980px 桌面宽度，不受影响） */
@media (max-width: 640px) {
  .imp-row, .route-row { flex-direction: column; align-items: center; }
  .nt-row { flex-direction: column; align-items: center; }
  .nt-left, .nt-mid, .nt-rightcol { flex: 0 0 auto; width: 100%; }
  .nt-right { flex-direction: column; height: auto; }
  .nt-cg-wrap { width: 100%; }
  /* 窄屏：CG 按钮回到圆点同排流式布局，避免绝对定位压住圆点 */
  .nt-cg-bar { flex-wrap: wrap; row-gap: 4px; }
  .nt-cg-actions { position: static; transform: none; }
  .imp-texts, .route-right { width: 100%; }
  /* v313：手机端上下排列时内容区不再被 flex:1 钉在 200px，按文字自然撑高 */
  .imp-texts { flex: 0 0 auto; min-height: 0; }
  .imp-field textarea { flex: 0 0 auto; }
  .imp-char, .route-left { flex: 0 0 auto; }
}

/* ---------------- 只读分享模式 ---------------- */
/* 只读时：所有带 edit-only 的编辑/删除/上传/保存控件一律隐藏 */
.readonly .edit-only { display: none !important; }
/* 只读时：点击式交互全部失效（JS 已不绑事件，这里再兜底一层）——
   角色图(.imp-img/.route-img)、勾选框(.tick)、评分圈(.grade)、奖项卡片(.award-card)，
   以及 select 下拉（readonly 属性锁不住 select，用 pointer-events 直接点不动） */
.readonly .imp-img, .readonly .route-img, .readonly .tick, .readonly .grade,
.readonly .award-card, .readonly select { pointer-events: none; cursor: default; }
/* 作品卡片的状态胶囊：访客照样能看到「在库 / 全通」，但点不动 */
.readonly .chip { pointer-events: none; cursor: default; }
.readonly .chip:hover { filter: none; border-color: var(--line); }
/* 侧栏名片左上角的四叶草 / 皇冠（主人登录入口，代替原来的「访客浏览 · 主人登录」那行） */
.side-profile { position: relative; }
.sp-leaf {
  position: absolute; left: 9px; top: 7px;
  width: 28px; height: 28px; padding: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; line-height: 1; text-decoration: none;
  background: transparent; border: 0; border-radius: 50%;
  opacity: .62; cursor: pointer;
  transition: opacity .18s, transform .18s, background .18s;
}
.sp-leaf:hover { opacity: 1; transform: scale(1.12); background: rgba(120,180,140,.16); }
.sp-leaf.is-admin { opacity: .85; font-size: 15px; }
/* 解锁 / 登录页（同一输入框，自动识别访客/主人） */
.unlock-wrap { min-height: 72vh; display: flex; align-items: center; justify-content: center; }
.unlock-card {
  background: #fff; border: 1px solid #dfe9d2; border-radius: 16px;
  padding: 34px 30px; width: 320px; text-align: center;
  box-shadow: 0 10px 30px rgba(120,150,100,.12);
}
.unlock-cap { font-family: 'FZ YaoTi','LXGW WenKai Screen',serif; font-size: 22px; color: var(--green-dark); margin-bottom: 16px; }
.unlock-form { display: flex; flex-direction: column; gap: 10px; }
.unlock-form input {
  padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px;
  font-family: inherit; font-size: 14px; text-align: center;
}
.unlock-err { color: #c0533f; font-size: 13px; margin-bottom: 10px; }
.unlock-tip { color: var(--muted); font-size: 12px; margin-top: 14px; line-height: 1.7; }

/* ------------------------------------------------------------
   主人密码弹窗（点侧栏名片左上角 🍀 出现）
   和 /unlock 页同一套视觉，只是浮在当前页上，输完直接进编辑模式
   ------------------------------------------------------------ */
.lock-modal {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  background: rgba(38,66,50,.30);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
.lock-modal[hidden] { display: none; }
body.lock-open { overflow: hidden; }
.lock-card {
  position: relative;
  width: 300px; max-width: 100%;
  padding: 30px 28px 24px;
  background: #fff; border: 1px solid #dfe9d2; border-radius: 16px;
  text-align: center;
  box-shadow: 0 18px 44px rgba(60,100,70,.22);
  animation: lockIn .18s ease-out;
}
@keyframes lockIn {
  from { opacity: 0; transform: translateY(6px) scale(.98); }
  to   { opacity: 1; transform: none; }
}
.lock-cap { font-size: 20px; color: var(--green-dark); margin-bottom: 16px; letter-spacing: .04em; }
.lock-form { display: flex; flex-direction: column; gap: 10px; }
.lock-form input {
  padding: 9px 12px; border: 1px solid #c6d6bf; border-radius: 10px;
  font-family: inherit; font-size: 14px; text-align: center; letter-spacing: .12em;
  background: #fff;
}
.lock-form input:focus {
  outline: none; border-color: var(--mint-deep);
  box-shadow: 0 0 0 3px rgba(120,180,140,.16);
}
.lock-err { color: #c0533f; font-size: 12.5px; margin-top: 8px; }
.lock-x {
  position: absolute; right: 8px; top: 6px;
  width: 26px; height: 26px; line-height: 1;
  border: 0; border-radius: 50%; background: transparent;
  color: var(--muted); font-size: 17px; cursor: pointer;
}
.lock-x:hover { background: rgba(0,0,0,.06); color: var(--green-dark); }

/* ============================================================
   Repo 板块底部按钮（左 Blind Pick Log · 中 查看更多 · 右 Appraisal）
   三格布局：中间那格是 auto，所以「查看更多」仍然严格居中
   ============================================================ */
.repo-actions { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin-top: 12px; }
.repo-actions .see-more { margin-top: 0; }
/* grid 子项默认会被拉满整格，两个按钮要各自贴住左右边 */
.repo-actions .repo-act { justify-self: start; }
.repo-actions .act-right { justify-self: end; }

/* ============================================================
   Repo 工具页：Blind Pick Log / Appraisal
   ============================================================ */
.tool-page { max-width: 1000px; margin: 0 auto; padding-bottom: 30px; }
.tool-cap { font-size: 26pt; letter-spacing: 3px; }   /* v427 曾改 36pt 统一字号，v428 按 Danmi 要求回退原样 */
.nav-left { display: inline-flex; align-items: center; gap: 12px; }

/* ---------------- Blind Pick Log ---------------- */
/* 三列占比照模版：卡带图窄、盲狙中等、实际喜欢略宽 */
/* v407b：作品列加宽到 136，卡带图高度与该行最高的框对齐（具体高度由 JS 写死），
   这样「作品」和右边两个方框是齐平的，不再矮一截。 */
.bpl-labels, .bpl-row {
  --roh: 198px;                /* v407：每列最多 2 人 → 框变大，整行高度跟着加高 */
  display: grid;
  grid-template-columns: 136px minmax(0, 1fr) minmax(0, 1.02fr);
  gap: 8px;
}
.bpl-labels { margin: 0 0 7px; }
/* 表头要压在页面顶部的照片背景上，纯文字看不清：做成半透明磨砂小胶囊。
   v418：Danmi 定稿 —— **网页恢复最初的「透透的又能看清字」**
   （半透明白 55% + 磨砂 + 白描边 + 淡阴影），
   而**导出图走另一套**（空心实线框，见文件末尾 .gd-export-snap 那段）。 */
.bpl-labels span {
  justify-self: center;
  padding: 3px 10px 3px 14px;   /* letter-spacing 会在末字后多留4px，右侧少给一点找齐 */
  border-radius: 999px;
  background: rgba(255, 255, 255, .55);
  -webkit-backdrop-filter: blur(4px) saturate(140%);
  backdrop-filter: blur(4px) saturate(140%);
  border: 1px solid rgba(255, 255, 255, .55);
  box-shadow: 0 1px 2px rgba(52, 132, 92, .10);
  text-align: center; font-size: 19px; letter-spacing: 5px;   /* v411/412/413：Danmi 三次要求放大 → 13→15→17→19 */
  font-weight: 400; color: var(--green-dark);
  line-height: 1.45;
}
.bpl-row { margin-bottom: 16px; position: relative; transition: transform .16s ease; }
/* 正在拖的那一行：浮起来、压住下面的行 */
.bpl-row.dragging {
  transition: none; position: relative; z-index: 30;
  border-radius: 8px;
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 10px 26px rgba(47, 68, 56, .18);
}
/* v434：手机长按成立时的提示 —— 只改背景/阴影，不碰 transform（拖动位移是 transform，别打架） */
.bpl-row.drag-ready {
  border-radius: 8px;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 6px 18px rgba(47, 68, 56, .16);
}
/* v501：拖动把手 = 卡带图右下角的实心圆点（原来那根 15×30 的竖条＋点阵
   在手机上看像一根多余的竖线，Danmi 让删掉）。鼠标移到这一行才浮现。 */
.bpl-work { position: relative; }
.bpl-grip {
  position: absolute; right: -5px; left: auto; bottom: -5px; top: auto; transform: none;
  width: 15px; height: 15px; padding: 0; border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--green-dark);
  box-shadow: 0 1px 3px rgba(157, 111, 104, .22);
  z-index: 6;                       /* 压在卡带图之上，不然右下角那 5px 会被图盖住 */
  cursor: grab; opacity: 0; transition: opacity .15s;
  touch-action: none;
}
/* 圆点小、命中区不能小：透明撑到 26×26，手指才按得住 */
.bpl-grip::before {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 26px; height: 26px; transform: translate(-50%, -50%);
  border-radius: 50%;
}
.bpl-row:hover .bpl-grip, .bpl-grip:focus-visible { opacity: .8; }
.bpl-grip:active { cursor: grabbing; }
/* v500：长按一直不灵，改成「按住圆点直接拖」；长按整行仍当兜底，两条路都能换列。 */
@media (hover: none) { .bpl-grip { opacity: .65; } }

/* 删行的叉：卡带图左上角，鼠标移到这一行才浮现 */
.bpl-covwrap { position: relative; display: flex; }
.bpl-del {
  position: absolute; left: -5px; right: auto; top: -5px; z-index: 5;
  width: 15px; height: 15px; padding: 0;      /* v501e：整个圆圈按钮一起收小（18 → 15） */
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--line); background: #fff;
  box-shadow: 0 1px 3px rgba(157, 111, 104, .22);
  color: var(--green-dark);
  font-size: 11px; line-height: 1; font-family: Arial, sans-serif;
  cursor: pointer;
  opacity: 0; pointer-events: none;
  transition: opacity .15s, background .12s, color .12s, border-color .12s;
}
/* 圈画小了但手指还得点得中：靠一层不可见的伪元素把命中区向外撑到 26×26。
   不敢再往外撑（30 就会吃到封面左上角，误点时变成删行）。 */
.bpl-del::before {
  content: ''; position: absolute; left: 50%; top: 50%;
  width: 26px; height: 26px; transform: translate(-50%, -50%);
  border-radius: 50%;
}
.bpl-row:hover .bpl-del, .bpl-del:focus-visible { opacity: 1; pointer-events: auto; }
.bpl-del:hover {
  background: var(--green-dark); border-color: var(--green-dark); color: #fff;
}
@media (hover: none) { .bpl-del { opacity: .85; pointer-events: auto; width: 13px; height: 13px; font-size: 8.5px; left: -3px; right: auto; top: -3px; } }   /* v501d：手机上再收小，压在卡带上不抢画面 */

.bpl-work { display: flex; align-items: center; justify-content: center; }
/* v407b：默认高度 = 大框高度（196），宽按 2:3 卡带比例 → 131。
   有框时 JS 会把这张图改成「和该行最高的框一样高」，两边同高、底边齐。 */
.bpl-cover {
  position: relative; width: 125px; height: 188px;
  border: 1px dashed var(--green-soft); border-radius: 10px;
  background: #fff center / cover no-repeat;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 12px; letter-spacing: 1px;
}
.bpl-cover.editable { cursor: pointer; }
.bpl-cover.filled { border-color: transparent; }
/* v500：有图的卡带框一按下就锁住手势，不然「拖动改取景」会被页面滚动抢走 */
.bpl-cover.editable.filled { touch-action: none; }
.bpl-cover.editable:hover { border-color: var(--green-dark); }
.bpl-cover.editable.filled:hover { border-color: transparent; }

/* 盲狙 = 白底细框；实际喜欢 = 薄荷绿底（和参考图一致）
   --roh 决定整行高度（比卡带图高 4px，正好给 1/2/3 胶囊留位置） */
.bpl-pick, .bpl-like {
  position: relative; min-height: var(--roh); padding: 0 5px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
}
/* 盲狙列：底色用导出纸色 #fdfefb（近白，不是纯白 #fff），
   保留 1px 淡绿描边，否则在照片上几乎看不出轮廓 */
.bpl-pick { background: #fdfefb; border: 1px solid #cfe0d1; }
/* 薄荷绿那列也必须带 1px 边框：不然它比白框高 2px，两列方框的底边会差 1px。
   2026-11-08 用户要求两列都要有外轮廓、且颜色再深一点 → 从 transparent 改成和盲狙列同一个实色 */
/* 底色 = 角色印象页「现印象」框的 #e8f4dd 再淡两档 #f2f9eb（2026-11-06 用户要求「稍微淡一点」） */
.bpl-like { background: #f2f9eb; border: 1px solid #cfe0d1; }

/* 整行交替底色：第一行用盲狙列的纸色，第二行用实际喜欢列的薄荷绿，之后依次重复。
   左右两块在同一行同色，靠一行的整体色带区分，列的分界由两块之间的间隙给出。
   两个选择器都比基础规则的优先级高（0,2,0 > 0,1,0），写在后面即可覆盖 */
.bpl-row:nth-child(odd) .bpl-pick,
.bpl-row:nth-child(odd) .bpl-like { background: #fdfefb; }
.bpl-row:nth-child(even) .bpl-pick,
.bpl-row:nth-child(even) .bpl-like { background: #f2f9eb; }

/* 还空着的那一列：只有一块长方框，悬停才冒出 1/2/3 */
.bpl-empty-hint {
  font-size: 19px; color: var(--green-soft); opacity: .45;
  transition: opacity .14s;
}
.bpl-pick:hover .bpl-empty-hint, .bpl-like:hover .bpl-empty-hint { opacity: 0; }

/* 1/2/3 与 大/中/小：和奖项格那个 1/2 小胶囊同一套样子 */
.bpl-seg {
  display: inline-flex; align-items: center; gap: 3px; z-index: 4;
  padding: 3px; border-radius: 999px;
  background: rgba(255, 255, 255, .95);
  border: 1px solid rgba(122, 160, 91, .45);
  box-shadow: 0 1px 5px rgba(122, 160, 91, .16);
}
.bpl-seg b {
  width: 19px; height: 19px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'LXGW WenKai Screen', serif; font-size: 12px; font-weight: 400;
  color: #7a9c5e; line-height: 1; cursor: pointer; user-select: none;
}
.bpl-seg b:hover { background: rgba(122, 160, 91, .14); }
.bpl-seg b.on { background: var(--green-dark); color: #fff; }
.bpl-seg b.on:hover { background: var(--green-dark); }
/* 1/2/3：整列还空着时就在长方框正中间；选了数字、出现方框之后挪到框顶，
   并且——两个胶囊都只在鼠标停在这一块里时才出现，移开就消失 */
.bpl-count {
  --ctop: -4px;
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .14s ease, top .18s ease, transform .18s ease;
}
.bpl-pick:hover .bpl-count, .bpl-like:hover .bpl-count,
.bpl-pick:focus-within .bpl-count, .bpl-like:focus-within .bpl-count {
  opacity: 1; visibility: visible; pointer-events: auto;
}
.bpl-pick.has-boxes .bpl-count, .bpl-like.has-boxes .bpl-count {
  top: var(--ctop); transform: translate(-50%, 0);
}

/* 一排方框：整体居中（上下左右），组内底边对齐 */
.bpl-boxes {
  display: flex; align-items: flex-end; justify-content: center;
  gap: 6px; width: 100%;
}
/* 正方形人物框：宽度取 大/小；一行最多 2 个，所以每个最多占一半宽（减去中间 6px 缝） */
.bpl-cell {
  position: relative; flex: 0 0 auto;
  max-width: calc((100% - 6px) / 2);
  display: flex;
}
.bpl-box {
  position: relative; width: var(--s); max-width: 100%;
  aspect-ratio: 1 / 1;
  border: 1px dashed var(--green-soft); border-radius: 9px;
  background: #fff center / cover no-repeat;
  overflow: hidden;
}
.bpl-pick .bpl-box, .bpl-like .bpl-box { background-color: transparent; }
.bpl-box.filled { border-style: solid; border-color: transparent; }
.bpl-box img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; }
/* v439：空图位中央统一用淡绿加号（Danmi：卡带图 / 角色图 / 图 这些提示字全换成加号，
   和盲狙表空列那个 ＋ 同一套观感）。导出时 .bpl-plus 在 repo_tools.js 的 strip 名单里，
   不会进成品图。 */
.bpl-plus {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; color: var(--green-soft); opacity: .6;
  pointer-events: none;
}
/* 父级自己是 flex 居中的（.apr-img / .grid-img / .bpl-cover）就不用绝对定位去抢层 */
.apr-img > .bpl-plus, .bpl-cover > .bpl-plus {
  position: static; width: 100%; height: 100%;
}
.apr-img > .bpl-plus { font-size: 20px; }    /* 125px 的图框 */
.grid-img > .bpl-plus { font-size: 27px; }   /* 280px 的九宫格格子 */
.bpl-box.editable { cursor: pointer; }
.bpl-box.editable:hover { border-color: var(--green); }
.bpl-box.editable.filled:hover { border-color: transparent; }

/* 每个框自带的大/中/小胶囊：挂在框底边中间，鼠标停在这个框上才出现 */
.bpl-size-pill {
  position: absolute; left: 50%; bottom: -12px; transform: translateX(-50%);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .14s ease;
}
.bpl-cell:hover .bpl-size-pill, .bpl-cell:focus-within .bpl-size-pill {
  opacity: 1; visibility: visible; pointer-events: auto;
}
.bpl-size-pill b { width: 18px; height: 18px; font-size: 11.5px; }

/* 触屏没有 hover：胶囊直接常显，否则手机上根本点不到 */
@media (hover: none) {
  .bpl-count, .bpl-size-pill { opacity: 1; visibility: visible; pointer-events: auto; }
  .bpl-empty-hint { display: none; }
}

/* v407：只剩「大 / 小」两档，两档都放大了（原来 130 / 82）—— 因为一行最多 2 个，
   框可以占更宽，图自然更大。旧的「中」在取数时已按「小」处理，这里不再需要 .sz-中。
   v407c（13:18）：Danmi「稍微调小一点点」→ 196→188、136→130，只收 8 / 6px。 */
.sz-大 { --s: 188px; }
.sz-小 { --s: 152px; }   /* v429：130→142；v431：142→152（Danmi「小的再大一点」）。上限约 194px（两格并排 × 列宽） */
.sz-小 .bpl-size-pill b { width: 16px; height: 16px; font-size: 10.5px; }

.bpl-foot { display: flex; justify-content: center; gap: 12px; margin-top: 4px; }
.bpl-step {
  width: 54px; height: 30px; border-radius: 999px;
  border: 1px solid var(--line); background: #fff; color: var(--green-dark);
  font-size: 15px; font-family: inherit; cursor: pointer;
}
.bpl-step:hover { background: var(--mint); }

/* ---------------- Appraisal ---------------- */
/* v470（Danmi：「网页也改成那样，蛮好看的」）：一条 = 一张卡片，桌面与手机同构，只尺寸不同
     [添加]
     ┌──────────────────────────────────┐
     │ S+   [ （编辑文字） ]        ×   │  第一行：评级 + 长条文字框（叉在右上角）
     │ ┌─┐┌─┐┌─┐┌─┐┌─┐┌─┐              │  第二行：图横排
     │ └─┘└─┘└─┘└─┘└─┘└─┘           ●  │  左下角圆点 = 按住上下拖换位置
     └──────────────────────────────────┘
   做法：HTML 一行不改。`.apr-left{display:contents}` 把原来的左列盒子拆掉，
   让里面的「评级 / 文字框」直接成为 .apr-entry 网格的子项（第一行两格），
   .apr-panel 铺第二行；绝对定位的 grip/del 包含块自动落到卡片上。
   边框色用 var(--line)：桌面淡绿 #cfe3d6，手机玫瑰 #e7d3cd，各按各的主题走。 */
.apr-list { display: flex; flex-direction: column; gap: 22px; }

.apr-entry {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  grid-template-areas: "g t" "p p";
  column-gap: 26px; row-gap: 12px; align-items: center;
  padding: 12px 14px 14px;
  /* v474（Danmi：「最外面的边框粗一点」）：1px → 2px */
  background: #fff; border: 2px solid var(--line); border-radius: 8px;
  position: relative; transition: transform .16s ease;
}
/* 正在拖的那一条：浮起来、压住下面的（卡片本身已是白底，别用半透明白） */
.apr-entry.dragging {
  transition: none; z-index: 30;
  background: #fff;
  box-shadow: 0 10px 26px rgba(47, 68, 56, .18);
}
/* 左列盒子拆掉：评级 / 文字框升级成卡片网格的子项 */
.apr-left { display: contents; position: static; }

/* 拖动把手：卡片左下角的实心小圆点（v469 删掉了原来那串绿点阵） */
.apr-grip {
  position: absolute; left: -6px; bottom: -6px; top: auto; transform: none;
  width: 16px; height: 16px; padding: 0; border-radius: 50%;
  border: 1px solid #cfe6d6;
  /* v10c：颜色跟这一行的评级框走（--grade-c 由 appraisal.html 设在 wrap 上） */
  background: var(--grade-c, var(--green-dark));
  box-shadow: 0 1px 3px rgba(47, 68, 56, .22);
  cursor: grab; opacity: 0; transition: opacity .15s;
  touch-action: none;
}
.apr-entry:hover .apr-grip, .apr-grip:focus-visible { opacity: .75; }
.apr-grip:active { cursor: grabbing; }
/* v10c：Danmi「跟着框的颜色走但是要透明一点点」→ 比原来 .9 淡一档 */
@media (hover: none) { .apr-grip { opacity: .65; } }

/* 删这一条的叉：卡片右上角，鼠标移到这一条才浮现 */
.apr-del {
  position: absolute; right: -6px; top: -6px; z-index: 5;
  width: 20px; height: 20px; padding: 0;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  border: 1px solid #cfe6d6; background: #fff;
  box-shadow: 0 1px 3px rgba(47, 68, 56, .22);
  color: var(--green-dark);
  font-size: 14px; line-height: 1; font-family: Arial, sans-serif;
  cursor: pointer;
  opacity: 0; pointer-events: none;
  transition: opacity .15s, background .12s, color .12s, border-color .12s;
}
.apr-entry:hover .apr-del, .apr-del:focus-visible { opacity: 1; pointer-events: auto; }
.apr-del:hover {
  background: var(--green-dark); border-color: var(--green-dark); color: #fff;
}
@media (hover: none) { .apr-del { opacity: .85; pointer-events: auto; width: 22px; height: 22px; } }

/* 评级方块：正方形、浅绿底 + 虚线边，内容可直改（S+ 默认）。现在占卡片第一行左格 */
.apr-grade {
  grid-area: g; align-self: center;
  width: 112px; height: 112px; box-sizing: border-box; padding: 0;
  border: 1px dotted #9fc48f; border-radius: 5px; background: #ecf6e6;
  text-align: center; outline: none;
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 46pt; color: #4e8a41;
}
.apr-grade:focus { border-color: var(--green-dark); background: #e5f3dc; }

/* 可编辑文字：现在占卡片第一行右格，横贯到卡片右边
   v473（Danmi：「框不要，字大一点」）：去掉虚线框，平时完全无框无底，
   只在鼠标移上去 / 输入时给一层极淡的底当提示；字号 13 → 16。
   v474（「这个再大一点，然后从最右边开始写」→ 她随即更正「说错了是最左边」）：字号 16 → 18，**左对齐**（从最左边开始写）。
   v475（「字再大一点」）：字号 18 → 20。 */
.apr-text {
  grid-area: t; align-self: center;
  width: auto; min-width: 0; height: 34px; box-sizing: border-box; padding: 0 12px;
  border: 0; border-radius: 5px; background: transparent;
  text-align: left; outline: none;
  /* v10g「这里的字再大一点」：20 → 24px。顺手固定行高 1.35（24×1.35≈32px < 框高 34px），
     不然继承 body 的 1.75 会撑到 42px、把输入框裁掉。 */
  font-family: 'LXGW WenKai Screen', serif; font-size: 24px; line-height: 1.35; color: var(--green-dark);
  transition: background .12s;
}
.apr-text::placeholder { color: #8aa87c; opacity: .75; }
.apr-text:hover { background: rgba(236, 246, 230, .5); }
.apr-text:focus { background: rgba(236, 246, 230, .85); }

/* 图面板：铺卡片第二行；卡片自己就是那圈框，面板不再画边框
   v471（Danmi：「图片大一点」）→ v472（「一行放六个」）：flex 固定 125px 改成网格。
   固定 6 列（不是 auto-fill），保证任何窗口宽度下都是一排 6 张，
   每格等分剩余宽度，1280 下约 149.7（原来 125，一行 7 张）。
   注意：九宫格的 .grid-img 不在 .apr-panel 里，不受这两条影响。 */
.apr-panel {
  grid-area: p; position: static; align-self: stretch;
  padding: 0; border: 0; background: none;
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}
/* 图占满自己那一格，保持正方形（高矮由 aspect-ratio 撑，不写死像素） */
.apr-panel > .apr-img { width: 100%; height: auto; aspect-ratio: 1 / 1; }
/* 图框：按比例截取（cover），拖动只改 background-position，原图不动 */
.apr-img {
  width: 125px; height: 125px; box-sizing: border-box;
  border: 1px dotted #b6d3a8; border-radius: 5px;
  background: #fff center / cover no-repeat;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 12px;
  user-select: none; -webkit-user-select: none;
}
.apr-img.editable { cursor: pointer; }
.apr-img.filled { border-style: solid; border-color: transparent; cursor: grab; touch-action: none; }
.apr-img.dragging { cursor: grabbing; }

/* 长按拿起：跟着鼠标走的那张浮影 */
.apr-ghost {
  position: fixed; z-index: 900; pointer-events: none;
  border: 1px solid #cfe6d6; border-radius: 5px;
  background: #fff center / cover no-repeat;
  box-shadow: 0 10px 22px rgba(47, 68, 56, .30);
  opacity: .95;
}
/* 被拿起来的那张先变淡，等落位 */
.apr-img.picked { opacity: .28; }
/* 落点提示：插在这张图的前面 / 后面 */
.apr-img.drop-l { box-shadow: -3px 0 0 0 var(--green-dark); }
.apr-img.drop-r { box-shadow: 3px 0 0 0 var(--green-dark); }

/* 底栏：＋ / － 在面板正中 */
.apr-foot {
  grid-column: 2;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
}
/* 「添加」：骑在卡片左上角，鼠标移进这一条才浮现（面板不再是定位容器了） */
.apr-add {
  position: absolute; left: -6px; top: -11px; z-index: 3;
  height: 22px; padding: 0 10px;
  border: 1px solid #cfe6d6; border-radius: 999px; background: #fff;
  box-shadow: 0 1px 3px rgba(47, 68, 56, .18);
  color: var(--green-dark);
  font-family: inherit; font-size: 11.5px; line-height: 1; cursor: pointer;
  opacity: 0; pointer-events: none;
  transition: opacity .15s, background .12s, border-color .12s;
}
.apr-entry:hover .apr-add, .apr-add:focus-visible { opacity: 1; pointer-events: auto; }
.apr-add:hover { background: var(--mint); border-color: var(--green-soft); }
@media (hover: none) { .apr-add { opacity: .92; pointer-events: auto; } }
/* ＋ / －：只跟在最后一条后面出现一次，贴面板正中；常显（和盲狙页底部一致） */
.apr-step {
  grid-column: 2; justify-self: center; display: inline-flex; gap: 10px;
}
.apr-step button {
  width: 48px; height: 26px; border-radius: 999px;
  border: 1px solid var(--line); background: #fff; color: var(--green-dark);
  font-size: 13px; font-family: inherit; cursor: pointer;
}
.apr-step button:hover { background: var(--mint); }

/* ---------------- 通用：下拉选择列 / 小菜单 / 轻提示 ---------------- */
.rp-pop {
  position: fixed; z-index: 9000; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 12px 30px rgba(60, 110, 85, .18);
}
.rp-pop-search { padding: 8px; border-bottom: 1px solid var(--line-soft); }
.rp-pop-search input {
  width: 100%; box-sizing: border-box; padding: 6px 12px;
  border: 1px solid var(--line); border-radius: 999px;
  font-family: inherit; font-size: 13px; background: #fff; color: var(--text); outline: none;
}
.rp-pop-list { max-height: 260px; overflow-y: auto; overscroll-behavior: contain; padding: 6px; }
/* 一行 = 左缩略图（跨两行）+ 右文字块（主名一行、小字副标题一行）。
   主名与副标题都允许换行，两个都完整显示，不再出现省略号。
   （以前是单行 flex：副标题 flex:0 0 auto 不压缩，长作品名会把主名挤成 0 宽；
     给了 max-width 之后又变成副标题被截。改成两行才两个都完整。） */
.rp-pop-item {
  display: grid; grid-template-columns: 30px minmax(0, 1fr);
  column-gap: 8px; row-gap: 1px; align-items: center; width: 100%;
  padding: 6px 8px; border: 0; border-radius: 8px; background: none;
  font-family: inherit; font-size: 13px; color: var(--text);
  text-align: left; cursor: pointer;
}
.rp-pop-item:hover { background: var(--mint); }
.rp-pop-thumb {
  grid-column: 1; grid-row: 1 / span 2;
  width: 30px; height: 30px; border-radius: 6px;
  overflow: hidden; background: var(--mint);
}
.rp-pop-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rp-pop-name {
  grid-column: 2; grid-row: 1; min-width: 0;
  white-space: normal; overflow-wrap: anywhere; line-height: 1.35;
}
.rp-pop-sub {
  grid-column: 2; grid-row: 2; min-width: 0;
  font-size: 11px; color: var(--muted); opacity: .7;
  white-space: normal; overflow-wrap: anywhere; line-height: 1.3;
}
.rp-pop-empty { padding: 12px; text-align: center; font-size: 12px; color: var(--muted); }
.rp-pop-menu { display: flex; flex-direction: column; gap: 2px; padding: 6px; }
.rp-pop-menu button {
  padding: 5px 0; border: 0; border-radius: 6px; background: none;
  font-family: inherit; font-size: 13px; color: var(--text); cursor: pointer;
}
.rp-pop-menu button:hover { background: var(--mint); }

.repo-toast {
  position: fixed; left: 50%; bottom: 42px; z-index: 9500;
  transform: translate(-50%, 8px); opacity: 0; pointer-events: none;
  padding: 8px 18px; border-radius: 999px;
  background: var(--mint, #e3f2e8); color: var(--green-dark, #34845c); font-size: 13px;
  font-weight: 600; border: 1px solid rgba(0,0,0,.07);
  box-shadow: 0 6px 18px rgba(60, 40, 40, .14);
  transition: opacity .18s, transform .18s;
}
.repo-toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------------- 自定义九宫格（Appraisal 第三个 tab） ---------------- */
/* 整块做成一张白纸卡片：绿虚线框 / 绿字在白底上才看得清，
   而且导出照片的底色也是这张米白纸，页面所见≈导出所得 */
.grid-board {
  display: block; max-width: 940px; margin: 0 auto; box-sizing: border-box;
  padding: 4px 12px 16px; border-radius: 14px;
  background: rgba(253, 254, 251, .92);
  border: 1px solid rgba(255, 255, 255, .6);
}
.grid-head { position: relative; display: flex; justify-content: center; margin-bottom: 22px; }
/* 标题无外框：页面与导出照片都是一行纯文字（导出会抄 computed border/background） */
.grid-title {
  width: 200px; height: 62px; box-sizing: border-box; padding: 0 4px;
  border: 0; border-radius: 0; background: transparent;
  text-align: center; outline: none;
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
  font-size: 32px; font-weight: 400; color: #2e7853;
}
.grid-title::placeholder { color: #34845c; }
/* 聚焦也不补边线，保持纯文字 */
.grid-grip {
  position: absolute; left: 4px; top: 8px; width: 12px; height: 20px; padding: 0;
  background-image: radial-gradient(circle, #b4c8a8 1.3px, transparent 1.4px);
  background-size: 6px 6px;
}
.grid-cells {
  display: grid; grid-template-columns: repeat(3, 280px);
  justify-content: center; gap: 18px 20px;
}
.grid-cell { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.grid-img { width: 280px; height: 280px; }        /* 覆盖 .apr-img 的 125px */
.grid-img .apr-hint { color: #34845c; font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; }
.grid-label {
  width: 280px; box-sizing: border-box; padding: 2px 4px;
  border: 1px dotted transparent; border-radius: 4px; background: transparent;
  text-align: center; outline: none;
  font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-size: 19px; color: #34845c;
}
.grid-label::placeholder { color: #4f9470; }
/* v349k：编辑模式对齐 repo 奖项(.award-label)——聚焦不再冒出虚线框+白底，
   纯文字就地编辑。只动 focus 态；导出照片从不聚焦、placeholder 颜色未动 → 导出零影响 */
.grid-label:focus { border-color: transparent; background: transparent; }

/* ---------------- Blind Pick 分页 ---------------- */
/* 页码绝对定位，不占标题的 flex 位置 → 标题始终正中 */
.bpl-head { position: relative; }
.bpl-pager {
  position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  display: inline-flex; align-items: center; gap: 6px;
}
.bpl-pager button {
  width: 24px; height: 24px; padding: 0; border: 0; border-radius: 6px;
  background: rgba(255, 255, 255, .55); color: var(--green-dark); font-size: 12px;
  font-family: inherit; cursor: pointer;
}
.bpl-pager button:hover:not(:disabled) { background: var(--mint); }
.bpl-pager button:disabled { opacity: .45; cursor: default; }
.bpl-pager b {
  min-width: 26px; height: 26px; box-sizing: border-box; padding: 0 4px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid #c6dfae; border-radius: 4px; background: #fff;
  color: var(--green-dark); font-size: 13px; font-weight: 700;
}
.bpl-foot {
  display: flex; justify-content: center; align-items: flex-start; gap: 22px; margin-top: 12px;
}
.bpl-act { display: inline-flex; flex-direction: column; align-items: center; gap: 5px; }
/* v421：Danmi 要「扁一点」的胶囊（照抄盲狙表 .bpl-step 那个形状）。
   原来是 44×44 正圆，现在 54×30 扁胶囊；颜色 / 描边 / 下方标注全部不变，
   只把钮内文字缩一档（＋－ 18→16，页/删 14→13）。 */
.bpl-round {
  width: 54px; height: 30px; border-radius: 999px; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid #9fc48f; background: #fff; color: var(--green-dark);
  font-family: inherit; font-size: 16px; line-height: 1; cursor: pointer;
}
.bpl-round:hover { background: var(--mint); }
.bpl-round.act-page { border-color: #e0a55e; background: #fdf3e4; color: #a8722a; font-size: 13px; }
.bpl-round.act-delpage { border-color: #d98d8d; background: #fdf0f0; color: #a34b4b; font-size: 13px; }
.bpl-act span {
  font-size: 12px; color: #1f3d2b; padding: 1px 8px; border-radius: 999px;
  background: rgba(255, 255, 255, .68);
}

/* ---------------- 九宫格：底部两个编辑按钮 ---------------- */
/* 导出照片底端的水印由 repo_tools.js 的 ExportMark() 统一生成，页面里没有。
   这里只把九宫格页水印「上方」的空白压紧（原来 tool-page 底 30px 太松）；
   只作用于本页，其它页面与全站共用的水印盒子一像素不动。 */
.tool-page.grid-mode { padding-bottom: 8px; }
.tool-page.grid-mode .edit-nav { margin-bottom: 4px; }
.grid-foot { display: flex; justify-content: center; gap: 12px; margin: 14px 0 0; }
.grid-foot button {
  padding: 4px 13px; border-radius: 999px; border: 1px solid var(--line);
  background: rgba(255, 255, 255, .82); color: var(--green-dark);
  font-family: inherit; font-size: 12px; cursor: pointer;
}
.grid-foot button:hover { background: var(--mint); }

/* ---------------- 手机 / 窄屏 ---------------- */
@media (max-width: 720px) {
  .tool-cap { font-size: 19pt; letter-spacing: 1px; }

  .grid-board { padding: 3px 6px 12px; }
  /* 三列平分可用宽度：窄屏也不会把第三列顶到屏幕外 */
  .grid-cells { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 8px; }
  .grid-img { width: 100%; height: auto; aspect-ratio: 1 / 1; }
  .grid-label { width: 100%; font-size: 16px; min-width: 0; box-sizing: border-box; }
  .grid-title { width: 200px; height: 52px; font-size: 26px; }
  .bpl-head { padding-bottom: 30px; }
  .bpl-pager { top: auto; bottom: 0; right: 0; transform: none; }
  .bpl-foot { gap: 14px; }
  /* v495（Danmi：这排钮别黄绿红，跟背景统一；再扁一点）
     —— 原来「页」米黄、「删」粉红、＋－ 是绿边写死色号，压在粉白花草背景上很跳。
     统一成粉白族：边框 #d9b9b2、底半透明白；两个特殊键共用淡粉底 + 玫红字（仍能看出是"操作类"）。
     高度 28 → 24，比原来更扁。桌面（>720）保持绿系不动。 */
  .bpl-round { width: 48px; height: 24px; font-size: 15px;
    border-color: #d9b9b2; background: rgba(255, 255, 255, .72); }
  .bpl-round.act-page, .bpl-round.act-delpage { font-size: 12px;
    border-color: #d9b9b2; background: #fdf3f0; color: #bd7777; }
  .bpl-act span { color: #9d6f68; }

  /* v496（Danmi：所有「生成照片」这类主按钮也统一风格 + 扁一点）
     —— .btn-main 的底色/边框本来就吃粉白变量（--green-soft #f3e2dd / --line #e7d3cd），
     只有字色写死深绿 #1f3d2b，这里改跟玫红棕走；上下 padding 7→4、字号 14→13，整块变扁。
     各页已有作用域规则（.works-page .info-actions / .works-add .wa-foot / .btn-main.sm）
     特异性更高，那几处保持自己调过的值不受影响。桌面 >720 仍是绿系。 */
  .btn-main{ color: var(--green-dark); padding: 4px 16px; font-size: 13px; }

  /* ===== v432 · Danmi 手绘草图：手机端从「上下堆叠」改成「三列横排」=====
     作品(正方形卡带) | 盲狙(框内两格并排) | 实际喜欢(框内两格并排)，
     三个标签恢复显示在各自列上方（原来手机是 display:none）。
     列宽 82 / 1fr / 1.02fr：390 视口内容宽 362，扣两个 7px 缝后作品 82、另两列各 ~133。 */
  .bpl-labels { display: grid; margin-bottom: 5px; }
  .bpl-labels span { font-size: 13px; letter-spacing: 2px; padding: 2px 7px 2px 9px; }
  .bpl-labels, .bpl-row { grid-template-columns: 82px minmax(0, 1fr) minmax(0, 1.02fr); gap: 7px; }
  .bpl-row { margin-bottom: 10px; }
  .bpl-grip { right: -4px; left: auto; bottom: -4px; width: 11px; height: 11px; }   /* v501c：卡带图右下角的实心圆点 */
  .bpl-work { justify-content: center; }
  .bpl-cover { width: 82px; height: 82px; }   /* 正方形卡带（草图上标「正方形可拖动」） */
  .bpl-pick, .bpl-like { --roh: 66px; padding: 4px; border-radius: 7px; }
  .bpl-count { --ctop: -2px; }
  /* 三列并排后每列只剩 ~133px，两格并排 → 58 / 50 */
  .sz-大 { --s: 58px; }
  .sz-小 { --s: 50px; }
  .bpl-boxes { gap: 6px; }
  .bpl-cell { max-width: calc((100% - 6px) / 2); }
  .bpl-size-pill b { width: 14px; height: 14px; font-size: 9px; }
  /* v433：手机上 @media(hover:none) 让 1/2 胶囊常驻显示，三列小格里会盖住图，
     缩小一号并骑在框顶边缘（一半在框外） */
  .bpl-count { --ctop: -11px; }
  .bpl-count .bpl-seg { padding: 2px; gap: 2px; }
  .bpl-count .bpl-seg b { width: 15px; height: 15px; font-size: 10px; }

  /* v469 卡片化后：结构跟桌面同一套，手机这里只收尺寸（评级 62 / 图 78 / 间隙 9·8） */
  .apr-list { gap: 18px; }
  /* v480（Danmi 截图）：评级方块整体变小（62→48），文字框变大（10→14px） */
  .apr-entry {
    grid-template-columns: 48px minmax(0, 1fr);
    column-gap: 9px; row-gap: 8px;
    padding: 8px 9px 10px;
  }
  .apr-grade { width: 48px; height: 48px; font-size: 21pt; }
  .apr-text { height: 28px; padding: 0 6px; }
  /* 手机保持原样的固定小格（一行 4 张），不跟着桌面改成自适应网格 */
  /* v479：手机严格 5 列自适应 grid —— 图宽 = (面板宽 - 4×gap)/5，任何屏宽都一行 5 张、图尽量大
     之前写死 64px 在 360 窄屏放不下 5 张就换行成 4 张（Danmi 真机即此情况），改自适应后根治 */
  .apr-panel { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 5px; }
  .apr-panel > .apr-img { width: 100%; height: auto; aspect-ratio: 1 / 1; }
  .apr-grip { width: 15px; height: 15px; }
  .apr-foot { grid-template-columns: 1fr auto 1fr; }
  .apr-add { height: 22px; padding: 0 9px; font-size: 11.5px; }
  .apr-step button { width: 40px; }

  /* v476（Danmi 手机截图）：翻页器别跟标题挤一行，单独占一行居中；
     红圈的三个控件（添加 / × / 拖动圆点）都缩小一号 */
  #aprPager {
    position: static; transform: none; width: 100%;
    justify-content: center; margin-top: 2px;
  }
  .apr-add { height: 18px; padding: 0 7px; font-size: 10px; }
  .apr-del { width: 16px; height: 16px; font-size: 11px; }
  .apr-grip { width: 11px; height: 11px; left: -5px; bottom: -5px; }

  .repo-actions { grid-template-columns: 1fr 1fr; row-gap: 8px; }
  .repo-actions .see-more { grid-column: 1 / -1; grid-row: 1; }
}

/* ---------------- 一键导入角色（录入角色页） ---------------- */
.wa-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.ci-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 0; }
.ci-hint { font-size: 12px; color: var(--muted); }
.ci-done {
  margin-bottom: 14px; padding: 9px 14px; border-radius: 10px;
  background: #eef8e6; border: 1px solid #cfe4c0;
  color: var(--green-dark); font-size: 13px;
}
.ci-card { width: 420px; max-width: 100%; text-align: left; padding: 22px 20px 18px; }
.ci-card .lock-cap { text-align: center; margin-bottom: 12px; }
.ci-search {
  width: 100%; box-sizing: border-box; padding: 8px 12px;
  border: 1px solid #c6d6bf; border-radius: 10px;
  font-family: inherit; font-size: 13.5px; background: #fff; color: var(--text);
}
.ci-search:focus {
  outline: none; border-color: var(--mint-deep);
  box-shadow: 0 0 0 3px rgba(120,180,140,.16);
}
.ci-list { margin-top: 10px; max-height: min(56vh, 420px); overflow: auto; }
.ci-rowform { margin: 0; }
.ci-row {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 8px 10px; border: 0; border-radius: 9px; background: none;
  font-family: inherit; font-size: 13.5px; color: var(--text);
  text-align: left; cursor: pointer;
}
.ci-row:hover { background: var(--mint); }
.ci-t { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ci-n { flex: 0 0 auto; font-size: 11.5px; color: var(--muted); opacity: .8; }
.ci-empty { padding: 18px 6px; font-size: 13px; color: var(--muted); text-align: center; }

/* ============================================================
   模板体验（游客版）
   首页「模版」板块里的三个按钮 + 游客工作站的顶栏/卡片
   ============================================================ */

/* --- 首页模版板块里的入口按钮（和 bigbox trans 一样走毛玻璃，不抢背景） --- */
.gg-entry { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 16px; }
.gg-entry-btn {
  display: inline-flex; align-items: center; justify-content: center;
  flex: 1 1 0; min-width: 0; padding: 12px 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .72);
  border: 1px solid rgba(52, 132, 92, .26);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  color: var(--green-dark); font-size: 13.5px; text-decoration: none;
  white-space: nowrap;
  transition: background .18s, border-color .18s, transform .18s;
}
.gg-entry-btn:hover {
  background: rgba(255, 255, 255, .9); border-color: rgba(52, 132, 92, .45);
  transform: translateY(-1px);
}
.gg-entry-note {
  display: inline-block; margin-top: 12px;
  padding: 5px 12px; border-radius: 8px;
  background: rgba(253, 254, 251, .74);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  font-size: 12px; line-height: 1.8; color: #6f8f79;
}
@media (max-width: 640px) {
  .gg-entry { gap: 8px; }
  .gg-entry-btn { min-width: 0; flex: 1 1 100%; padding: 11px 14px; font-size: 13px; }
}

/* --- 游客工作站顶栏 --- */
/* 模板页的页面背景跟主站保持一致：这里不铺纸色，直接用 body 那条「bg.jpg + 薄白层」。
   导出照片截的是 #capture（内部 .rp-sheet 自带纸色），所以背景不会被带进图里 */
.gg-bar {
  position: sticky; top: 0; z-index: 60;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 10px 22px; background: rgba(253, 254, 251, .92);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1px solid #e8f0e9;
}
/* v8 A1.1：手机端去掉这层 92% 白磨砂，让 body 的粉白花草背景透上来。
   原生状态栏已是 #fbf3f1（styles.xml），桌面端保持原样不动。 */
@media (max-width: 720px) {
  .gg-bar {
    background: rgba(251, 243, 241, .55);
    -webkit-backdrop-filter: none; backdrop-filter: none;
    border-bottom-color: rgba(201, 163, 155, .28);
  }
}
.gg-brand { font-size: 14.5px; color: var(--green-dark); text-decoration: none; white-space: nowrap; }
.gg-nav { display: flex; gap: 4px; }
.gg-link {
  font-size: 12.5px; color: #6b8a76; text-decoration: none;
  padding: 4px 11px; border-radius: 999px; white-space: nowrap;
}
.gg-link:hover { background: #f2f9eb; }
.gg-link.on { background: #ecf6e6; color: var(--green-dark); }
.gg-acts { margin-left: auto; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.gg-acts .btn-sub { font-size: 12px; padding: 5px 12px; }
@media (max-width: 720px) {
  .gg-bar { padding: 8px 14px; gap: 8px; }
  .gg-brand { font-size: 13px; }
  .gg-acts { margin-left: 0; }
}

/* --- 模板首页 --- */
.gg-page { max-width: 1080px; margin: 0 auto; padding: 34px 22px 70px; }
/* 页面背景和主站一样是 bg.jpg 照片，顶部这段说明字小、色浅，直接压上去会糊 ——
   垫一层和主站 bigbox 同调的磨砂纸面 */
.gg-hero {
  padding: 18px 22px 20px; border-radius: 12px;
  background: rgba(253, 254, 251, .84);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, .55);
  box-shadow: 0 2px 10px rgba(52, 132, 92, .06);
}
.gg-hero-cap { font-size: 10.5px; letter-spacing: .22em; color: #a8bfae; }
.gg-hero-title { font-size: 26px; color: var(--green-dark); margin: 6px 0 12px; font-weight: normal; }
.gg-hero-sub { font-size: 13.5px; line-height: 1.95; color: #6b8a76; max-width: 740px; }
.gg-hero-sub strong { color: var(--green-dark); font-weight: normal; }
.gg-cards {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(238px, 1fr));
  gap: 14px; margin: 28px 0 24px;
}
.gg-card {
  display: flex; flex-direction: column; gap: 7px;
  padding: 18px 18px 16px; min-height: 168px;
  background: #fff; border: 1px solid #e8f0e9; border-radius: 12px;
  text-decoration: none; color: inherit;
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.gg-card:hover { border-color: #b7d4a8; box-shadow: 0 5px 16px rgba(52, 132, 92, .07); transform: translateY(-1px); }
.gg-card-cap { font-size: 10px; letter-spacing: .18em; color: #a8bfae; }
.gg-card-title { font-size: 17px; color: var(--green-dark); }
.gg-card-desc { font-size: 12.5px; line-height: 1.85; color: #7a9482; }
.gg-card-go { margin-top: auto; font-size: 12.5px; color: var(--green-dark); }
.gg-card.is-soon { opacity: .55; pointer-events: none; }
.gg-tips { background: #f6faf3; border: 1px solid #e8f0e9; border-radius: 12px; padding: 18px 22px 20px; }
.gg-tips-title { font-size: 14px; color: var(--green-dark); font-weight: normal; margin: 0 0 10px; }
.gg-tips-list { margin: 0; padding-left: 18px; font-size: 12.5px; line-height: 2; color: #6b8a76; }
.gg-tips-note { margin: 14px 0 0; font-size: 12px; line-height: 1.8; color: #9ab0a0; }
/* 「其他」块：不走上面两块那样的实底，用页面顶部说明卡那套磨砂透明，
   让背景照片透出来，透明度和顶部那张比再淡一点 */
.gg-other {
  margin-top: 16px; padding: 18px 22px 20px; border-radius: 12px;
  background: rgba(253, 254, 251, .62);
  -webkit-backdrop-filter: blur(7px) saturate(1.06);
  backdrop-filter: blur(7px) saturate(1.06);
  border: 1px solid rgba(255, 255, 255, .5);
  box-shadow: 0 2px 10px rgba(52, 132, 92, .06);
}
.gg-other-title { font-size: 14px; color: var(--green-dark); font-weight: normal; margin: 0 0 10px; }
.gg-other-list { margin: 0; padding-left: 18px; font-size: 12.5px; line-height: 2; color: #6b8a76; }

/* --- 建设中占位页 --- */
.gg-soon { max-width: 640px; margin: 90px auto; text-align: center; padding: 0 22px; }
.gg-soon h1 { font-size: 22px; color: var(--green-dark); font-weight: normal; margin-bottom: 12px; }
.gg-soon p { font-size: 13px; line-height: 2; color: #7a9482; }
.gg-soon a { display: inline-block; margin-top: 20px; font-size: 13px; color: var(--green-dark); }


/* --- 游客版 Repo 页：模板页没有侧栏，用和主站一致的内容左右留白 ---
   主站是 .main 提供 34px（窄屏 14px）内边距；模板页的 content 直接挂在 body 下，
   所以在这里补同样的留白，并把 max-width 加回 padding 的量，保证文字区仍是 980px。 */
.guest-page .works-page { max-width: 1048px; padding-left: 34px; padding-right: 34px; }
@media (max-width: 720px) {
  .guest-page .works-page { max-width: none; padding-left: 14px; padding-right: 14px; }
}

/* v351d：角色名标签只在手机端显示（图旁姚体名）；桌面/导出(1280) 隐藏 */
.imp-char-name, .route-char-name { display: none; }

/* ============================================================
   移动端 UI 大改（v314 起）
   仅 @media(max-width:720px) 内生效；桌面(>720)与导出(1280) 完全不受影响。
   粉白清透主题 + 底部固定 4 Tab + 顶部返回/胶囊切换器。
   桌面/导出默认隐藏 .m-top / .m-tabbar（见文末两条）。
   ============================================================ */
@media (max-width: 720px) {
  /* —— 手机专属主题：重定义同一套变量 → 清透粉白 —— */
  :root{
    --bg:#fbf3f1;
    --card: rgba(255,255,255,.82);
    --line:#e7d3cd;
    --line-soft:#f1e3de;
    --text:#5a4a47;
    --muted:#9b857f;
    --green:#c9a39b;
    --green-soft:#f3e2dd;
    --green-dark:#9d6f68;
    --mint:#f7ece9;
    --mint-deep:#f0ddd7;
    --pink:#fde8ec;
    --pink-text:#bd7777;
    --gold:#c2a08a;
    --shadow:0 6px 20px rgba(180,140,135,.16);
    --radius:18px;
  }
  /* 手机专属背景：花草书壁纸 + 白蒙版（80%，草图定为 78–86%），清透感 */
  body{
    background-color: var(--bg);
    background-image:
      linear-gradient(rgba(255,255,255,.80), rgba(255,255,255,.80)),
      url('/static/bg_mobile.jpg?v=1');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
  }

  /* 桌面侧栏在手机上整体隐藏，改用底部 Tab */
  .sidebar{ display:none !important; }
  .main{ margin-left:0; padding:0 14px 84px; max-width:100%; }
  .site{ display:none; }

  /* —— 顶部栏（返回 + 右侧胶囊/帮助占位） —— */
  .m-top{
    position:sticky; top:0; z-index:40;
    display:flex; align-items:center; gap:8px;
    height:50px; margin:0 0 10px; padding:0 14px;
    background:rgba(255,255,255,.86); backdrop-filter:blur(8px);
    border-bottom:1px solid var(--line-soft);
  }
  .m-back{
    border:1.3px solid var(--line); border-radius:12px;
    width:34px; height:30px; flex:0 0 auto;
    display:inline-flex; align-items:center; justify-content:center;
    font-size:17px; color:var(--green-dark); background:var(--card); cursor:pointer;
  }
  .m-rt{ margin-left:auto; display:flex; align-items:center; gap:8px; }
  .m-help{
    width:22px; height:22px; flex:0 0 auto;
    border:1.3px solid var(--line); border-radius:50%;
    display:inline-flex; align-items:center; justify-content:center;
    font-size:12px; color:var(--green-dark); background:var(--card); cursor:help;
  }
  /* 胶囊切换器（连体下拉） */
  .m-switch{
    position:relative;
    border:1.3px solid var(--line); border-radius:999px;
    padding:5px 12px; font-size:13px; color:var(--green-dark);
    background:var(--card); display:inline-flex; align-items:center; gap:5px;
    cursor:pointer; white-space:nowrap; max-width:62vw; overflow:hidden; text-overflow:ellipsis;
  }
  .m-switch .ar{ font-size:10px; opacity:.7; flex:0 0 auto; }
  .m-pop{
    position:absolute; right:0; top:40px; z-index:55;
    background:#fff; border:1.3px solid var(--line); border-radius:14px;
    min-width:130px; box-shadow:var(--shadow); overflow:hidden; display:none;
  }
  .m-pop.open{ display:block; }
  .m-pop a{
    display:block; padding:10px 14px; font-size:13px; color:var(--text);
    text-decoration:none; border-bottom:1px solid var(--line-soft);
  }
  .m-pop a:last-child{ border-bottom:none; }
  .m-pop a.on{ background:var(--mint); font-weight:700; }

  /* —— 底部固定 4 Tab —— */
  .m-tabbar{
    position:fixed; left:0; right:0; bottom:0; z-index:60;
    height:60px; display:flex; align-items:stretch;
    background:rgba(255,255,255,.92); backdrop-filter:blur(10px);
    border-top:1px solid var(--line-soft);
    padding-bottom:env(safe-area-inset-bottom,0);
  }
  .m-tabbar a{
    flex:1; display:flex; flex-direction:column; align-items:center; justify-content:center;
    gap:3px; text-decoration:none; color:var(--muted); font-size:11px; line-height:1;
  }
  .m-tabbar a i{ font-style:normal; font-size:0; line-height:0; display:block; }
  .m-tabbar a i svg{ width:21px; height:21px; display:block; }
  .m-tabbar a.on{ color:var(--pink-text); font-weight:700; }

  /* 首页：手机显示 A1 块，隐藏桌面全部内容 */
  .m-home{ display:block; }
  .idcard, .diary, #OC, #procreate, #模版, #公告, #关于我 { display:none !important; }

  /* 作品一览：单列横向列表式（封面左 + 信息右），贴线框 A2 */
  .works-grid{ grid-template-columns:1fr; gap:12px; }
  .work-card{
    display:flex; align-items:flex-start; gap:12px; text-align:left;
    padding:10px; border-radius:14px;
  }
  .wc-cover{ flex:0 0 74px; width:74px; margin:0; border-radius:10px; }
  .wc-name{ margin-top:0; font-size:15px; }
  .wc-meta{ margin:3px 0 6px; }
  .wc-status{ justify-content:flex-start; }
  .wc-btns{ justify-content:flex-start; }
  .wc-pin{ top:6px; left:auto; right:6px; width:11px; height:11px; }
  /* v402：手机端隐藏「🗑 删除作品」——主站站长模式每张卡右上角都顶着垃圾桶，
     与置顶点位置冲突且手机上误触风险高；删除入口保留在桌面与录入数据页（危险操作） */
  .wc-del{ display:none; }

  /* 首页横滑最新卡带：隐藏滚动条保持清透 */
  .mh-works{ scrollbar-width:none; }
  .mh-works::-webkit-scrollbar{ display:none; }

  /* 录入角色 B1：方形角色卡 3 列宫格 + 顶部封面缩小 */
  .chars-grid{ grid-template-columns:repeat(3,1fr); gap:12px; }
  .char-card img{ height:auto; aspect-ratio:1/1; }
  .char-card .wc-none{ height:auto; aspect-ratio:1/1; }
  .manage-top{ gap:12px; align-items:flex-start; flex-wrap:wrap; }
  .manage-cover{ width:84px; }
  .manage-links{ flex-wrap:wrap; gap:8px; }

  /* ---------------- v336 · B3 日乙Repo表 手机端按 Danmi 草图重排 ----------------
     标题=E1/E2 同款（19pt、左对齐、下移 29px）；卡带图+作品名一行；
     本篇/fd 与 全通:是否 同一行；美术/剧情/音乐/配音 各一行；奖项 4 个一排。
     纯 CSS（display:contents + grid），不碰 DOM；全部锁在 ≤720，桌面/导出(1280) 零影响 */
  /* v337：标题改居中（Danmi 定），字号仍是 19pt */
  .rp-capture .rp-head { justify-content: center; margin-top: 29px; margin-bottom: 8px; }
  .rp-capture .rp-head .rp-cap { font-size: 19pt; line-height: 1.35; letter-spacing: 1px; }

  /* v346：行距统一 —— 原来大格子间 grid row-gap:14px、美术→剧情/音乐→配音
     是 flex 换行的 4px（≤960 块的 gap:4px 6px），一紧一松；全部统一成 4px（图2 的距离） */
  .rp-capture .rpt-top { display: grid; grid-template-columns: auto 1fr;
    column-gap: 10px; row-gap: 4px; align-items: center; }
  .rp-capture .rpt-info, .rp-capture .rpt-line { display: contents; }
  .rp-capture .rpt-fill { display: none; }

  /* 行1：卡带图（方形取景）+ 作品名（草图没画「作品：」标签，藏掉）
     v337：撤 960 块的 min-height:300/max-height:380（它把方形撑成细长条）；
     有图的框 touch-action:none + grab 光标 = 手机上按住拖动改取景 */
  .rp-capture .rp-cover-box { grid-area: 1 / 1 / 2 / 2; }
  .rp-capture .rp-cover.big { width: 108px; height: 108px; min-height: 0; max-height: none; }
  .rp-capture .rp-cover.big:not(.none) { touch-action: none; cursor: grab; }
  .rp-capture .rp-cover.big.dragging { cursor: grabbing; }
  .rp-capture .rpt-line:nth-of-type(1) > .rpt-label { display: none; }
  .rp-capture .rpt-line:nth-of-type(1) > input.rp-worktitle {
    grid-area: 1 / 2 / 2 / 3; min-width: 0; max-width: none;
    field-sizing: fixed; width: 100%; text-align: left;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  /* 手机端标题：隐藏 input，用可编辑 span 做「两行 + 第 2 行末省略号」 */
  .rp-capture #worktitle { display: none; }
  .rp-capture .rpt-line:nth-of-type(1) > .rp-worktitle-m {
    grid-area: 1 / 2 / 2 / 3; min-width: 0; max-width: none;
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2;
    overflow: hidden; white-space: pre-wrap; word-break: break-word;
    text-align: left; line-height: 1.45; }

  /* 行2：本篇/fd（左） + 全通:是/否（右）同一行 */
  .rp-capture .rpt-line:nth-of-type(1) > .tickgrp { grid-area: 2 / 1 / 3 / 2; justify-self: start; }
  .rp-capture .rpt-line:nth-of-type(2) > .tickgrp { grid-area: 2 / 2 / 3 / 3; justify-self: start; }

  /* 行3：时长（草图没画这个框，但字段不能丢 —— 先单独一行，不想要再商量） */
  .rp-capture .rpt-line:nth-of-type(2) > .rpt-label { grid-area: 3 / 1 / 4 / 2; }
  .rp-capture .rpt-line:nth-of-type(2) > .rp-text {
    grid-area: 3 / 2 / 4 / 3; width: 100%; box-sizing: border-box; text-align: left; }

  /* 行4-7：日期 / 总体评价 / 美术剧情 / 音乐配音 —— 通栏（row-gap 与 grid 统一 4px） */
  .rp-capture .rpt-line:nth-of-type(3),
  .rp-capture .rpt-line:nth-of-type(4),
  .rp-capture .rpt-line:nth-of-type(5),
  .rp-capture .rpt-line:nth-of-type(6) { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; row-gap: 4px; }
  /* 美术/剧情/音乐/配音 各占一行（草图） */
  .rp-capture .rpt-line:nth-of-type(5) .ggrp,
  .rp-capture .rpt-line:nth-of-type(6) .ggrp { flex: 1 1 100%; }
  /* v343：四行左对齐 —— 一行装两组（美术+剧情/音乐+配音），第二组自带 26px
     左间距，换行后「剧情/配音」整体被顶进一截；手机端归零，四行齐左 */
  .rp-capture .rpt-line:nth-of-type(5) .ggrp + .ggrp,
  .rp-capture .rpt-line:nth-of-type(6) .ggrp + .ggrp { margin-left: 0; }

  /* 390px 下日期六格收一点字号才放得下（宽度绑 em，几何自洽） */
  .rp-capture .numsel, .rp-capture .numfree { font-size: 13pt; }
  /* v340：手机端标题字号再缩小（12pt），两行省略号 */
  .rp-capture .rp-worktitle-m { font-size: 12pt; }

  /* v339：手机端去 repo 外背景图 + 3px内框，内容直接贴页面，腾出空间（桌面/导出零影响） */
  .rp-capture { background: none; }
  .rp-capture .rp-frame { display: none; }
  /* v341：sheet 左右 padding 收到 2px —— 左边距原来是 main(14)+sheet(14) 两层叠加，
     卡带图离屏幕边 ~28px；录入角色页只有 main 一层 14px，用户要对齐 → 左右只留 2px */
  .rp-capture .rp-sheet { background: transparent; border: none; box-shadow: none; padding: 14px 2px; }
  .rp-capture .grade.big { width: 32px; height: 32px; font-size: 16pt; }

  /* 奖项 4 个一排（8 个 = 2 行），正方形小间距；覆盖 ≤960 的 2 列 */
  .rp-capture .awards { grid-template-columns: repeat(4, 1fr); gap: 6px 4px; }
  .rp-capture .award-label { font-size: 13px; line-height: 20px; }

  /* v344：v342 的描边胶囊被用户否决（「我不要有框框的」），整段删除 →
     手机端回落到桌面原生 .grade 样式 = 无边框 30px 圆片 + 选中实心绿(#dde9d0)。
     v343 的对齐修复（margin-left:0）保留不动。 */

  /* 攻略顺序 / 好感排名 间隙收紧 */
  .rp-capture .rpt-areas { gap: 18px; margin-bottom: 20px; }

  /* v347：攻略顺序/好感排名 手机端照草图改 —— 两个框压扁成等高扁长方形，
     标题字缩小到只比 11pt 块字大一点（12.5pt），仍夹在框线上（左上角） */
  .rp-capture .rpt-area { border-radius: 14px; }
  .rp-capture .rpt-area-title {
    font-size: 12.5pt; letter-spacing: 1px; left: 14px; padding: 0 10px; }
  .rp-capture .rpt-area textarea {
    height: 62px; border-radius: 14px; padding: 0 6px; }

  /* v345：本篇/fd/全通/时长/日期/总体评价/四项评级 整块字号统一到
     美术/剧情/音乐/配音 标签(.rpt-label.sm)的 11pt（用户指定参照图2）。
     圆片直径不动、只缩字母；时长输入行盒 33px→24px 防小字悬空 */
  .rp-capture .rpt-label,
  .rp-capture .rpt-label.mid,
  .rp-capture .rpt-label.xl,
  .rp-capture .rpt-label.sm { font-size: 11pt; letter-spacing: .3px; }
  .rp-capture .tick { font-size: 11pt; }
  .rp-capture .rp-text { font-size: 11pt; line-height: 24px; }
  .rp-capture .numsel, .rp-capture .numfree, .rp-capture .dot { font-size: 11pt; }
  .rp-capture .ggrp .grade { font-size: 11pt; }

  /* v349：攻略顺序/好感排名 框内文字对齐 11pt 块（用户指定同图2字号）。
     原本 ≤720 没覆盖 textarea 字号，吃到 ≤960 的 14.5pt；现压到 11pt，
     行高 24px 与 11pt 块同节奏。导出图 withDesktop() 1280 不受影响。
     v349b：长名单行排不下、折行难看 → 再压到 10pt/22px 让更多字进一排。
     v349c：还要再小一点 → 10pt→9.5pt/20px */
  /* v8 B2 → v10 校正：Danmi 原话「就改一点点大」，17pt 过了，退回 10.5pt
     （原值 9.5pt，只放大约 10%）。手机端真正生效的是这条
     （.rp-capture 双类特异性高于 :1522 的单类），所以改这里。
     标题 :2741 的 12.5pt 与框高 :2743 的 62px 一律不动 —— 保住 v347 的扁框排布。
     导出照片 withDesktop() 切 1280，不吃这条，成品图不变。 */
  .rp-capture .rpt-area textarea {
    font-size: 10.5pt; line-height: 22px; }
  .rp-capture .grade.big { font-size: 11pt; }
}

/* 桌面/导出(1280) 默认隐藏移动端壳 —— 只在 ≥721 隐藏，≤720 由上面 media 块负责显示 */
@media (min-width: 721px) {
  .m-top, .m-tabbar{ display:none; }
  .m-home{ display:none; }
}

/* —— 移动端首页 A1 内部样式 —— */
.mh-profile{ text-align:center; padding:26px 0 16px; }
.mh-avatar{ width:96px; height:96px; border-radius:50%; margin:0 auto 12px; overflow:hidden;
  background:var(--mint-deep,#f0ddd7); display:flex; align-items:center; justify-content:center; font-size:38px; }
.mh-avatar img{ width:100%; height:100%; object-fit:cover; }
.mh-name{ font-family:'FZ YaoTi','LXGW WenKai Screen',serif; font-size:24px; color:var(--text,#5a4a47); }
.mh-sub{ font-size:12px; color:var(--muted,#9b857f); margin-top:4px; }
.mh-section{ margin:16px 0; }
.mh-sec-title{ font-size:13px; color:var(--muted,#9b857f); padding:0 4px 10px; letter-spacing:1px; }
.mh-works{ display:flex; gap:12px; overflow-x:auto; padding:2px 4px 8px; }
.mh-work{ flex:0 0 86px; text-decoration:none; color:inherit; }
.mh-cover{ width:86px; height:108px; border-radius:12px; background:var(--mint-deep,#f0ddd7); overflow:hidden;
  display:flex; align-items:center; justify-content:center; color:#b89a93; font-size:12px; }
.mh-cover img{ width:100%; height:100%; object-fit:cover; }
.mh-wname{ margin-top:6px; font-size:11px; color:var(--text,#5a4a47); text-align:center;
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mh-empty{ font-size:12px; color:var(--muted,#9b857f); padding:10px 4px; }
.mh-quick{ display:flex; gap:10px; margin-top:6px; }
.mh-quick-btn{ flex:1; text-align:center; border:1.3px solid var(--line,#e7d3cd); border-radius:14px;
  background:var(--card,rgba(255,255,255,.82)); color:var(--pink-text,#bd7777); padding:14px 4px; font-size:13px; text-decoration:none; }
.mh-quick-btn.dev{ color:var(--muted,#9b857f); border-style:dashed; }

/* —— 移动端新页：我的游戏 / 我的（自包含配色，桌面也能看） —— */
.col-page, .me-page{ max-width:560px; margin:0 auto; }
.col-head{ text-align:left; margin:6px 2px 12px; }
.col-title{ font-family:'FZ YaoTi','LXGW WenKai Screen',serif; font-size:22px; color:#9d6f68; letter-spacing:1px; }
.col-sub{ font-size:12px; color:#9b857f; }
.col-search input{ width:100%; box-sizing:border-box; border:1.3px solid var(--line,#e7d3cd); border-radius:12px;
  padding:9px 14px; font-size:14px; background:#fff; color:#5a4a47; font-family:inherit; }
.col-import{ width:100%; margin-top:10px; border:1.3px dashed #d9b9b2; border-radius:12px; background:#fdf4f2;
  color:#bd7777; padding:10px; font-size:13px; cursor:pointer; }
.col-filters{ display:flex; gap:8px; margin:14px 0 12px; }
.col-filters .pill{ border:1.3px solid var(--line,#e7d3cd); border-radius:999px; padding:5px 14px; font-size:12px;
  color:#9b857f; text-decoration:none; background:#fff; }
.col-filters .pill.on{ background:#f3e2dd; color:#9d6f68; font-weight:700; border-color:#d9b9b2; }
.col-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:12px; }
.col-card{ position:relative; text-decoration:none; color:inherit; min-width:0; }
.col-cover{ aspect-ratio:3/4; border-radius:12px; background:#f0ddd7; overflow:hidden;
  display:flex; align-items:center; justify-content:center; color:#b89a93; font-size:12px; }
.col-cover img{ width:100%; height:100%; object-fit:cover; }
.col-name{ margin-top:6px; font-size:12px; color:#5a4a47; text-align:center;
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
/* v10c：置顶圆点小一点（Danmi） */
.col-pin{ position:absolute; top:6px; right:6px; width:8px; height:8px; border:1px solid #c98f86;
  border-radius:50%; }
.col-pin.on{ background:#c98f86; }
.col-empty{ text-align:center; color:#9b857f; margin-top:30px; font-size:13px; }

.me-page{ text-align:center; padding:24px 8px; }
.me-avatar{ width:92px; height:92px; border-radius:50%; margin:0 auto 12px; overflow:hidden;
  background:#f0ddd7; display:flex; align-items:center; justify-content:center; font-size:34px; }
.me-avatar img{ width:100%; height:100%; object-fit:cover; }
.me-name{ font-family:'FZ YaoTi','LXGW WenKai Screen',serif; font-size:22px; color:#5a4a47; margin-bottom:18px; }
.me-stats{ display:grid; grid-template-columns:repeat(4,1fr); gap:10px; margin-bottom:22px; }
.me-stat{ background:rgba(255,255,255,.82); border:1px solid #f0ddd7; border-radius:14px; padding:14px 4px; }
.me-stat b{ display:block; font-size:20px; color:#9d6f68; font-family:'FZ YaoTi','LXGW WenKai Screen',serif; }
.me-stat span{ font-size:11px; color:#9b857f; }
.me-ops{ display:flex; gap:10px; justify-content:center; }
.me-ops button{ flex:1; max-width:120px; border:1.3px solid #d9b9b2; border-radius:12px; background:#fdf4f2;
  color:#bd7777; padding:10px; font-size:13px; cursor:pointer; }
.me-note{ font-size:11px; color:#b09a93; margin-top:14px; }
/* v519 阶段 2A：「同步到主站」这一行有两个按钮，并排不挤 */
.me-op-duo{ display:flex; gap:6px; flex:0 0 auto; }
/* v10i（Danmi：在「我的」加一个使用说明按钮，点开看怎么用的简单说明）
   v10n（Danmi：做成弹窗，最下面放返回按钮）：原来是一条内联展开区，现在改成遮罩 + 居中卡片。
   卡片超出就内部滚动，底部「返回」始终在卡片里；手机端由 720 块再收一次边距。 */
.me-help-mask{ position:fixed; left:0; top:0; right:0; bottom:0; z-index:2147483000;
  background:rgba(74,58,55,.34); display:flex; align-items:center; justify-content:center;
  padding:24px; }
.me-help-mask[hidden]{ display:none; }
/* v483（Danmi：内容变长后「返回」被挤到滚动区底下）——卡片改成「标题 + 滚动内容区 + 常驻返回」三段，
   只有中间内容区滚动，返回按钮永远贴在卡片底部，打开就能点。 */
.me-help{ box-sizing:border-box; width:min(520px,100%); max-height:76vh;
  display:flex; flex-direction:column; overflow:hidden;
  padding:18px 20px 14px; text-align:left;
  border:1.3px solid #e7d3cd; border-radius:16px; background:#fffdfc;
  box-shadow:0 14px 44px rgba(93,74,71,.20); }
.me-help-t{ font-family:'FZ YaoTi', 'LXGW WenKai Screen', serif; font-size:16px; letter-spacing:2px;
  color:#9d6f68; margin-bottom:10px; flex:0 0 auto; }
.me-help-body{ flex:1 1 auto; min-height:0; overflow-y:auto; -webkit-overflow-scrolling:touch;
  overscroll-behavior:contain; padding-right:2px; }
.me-help p{ margin:7px 0; font-size:12.5px; line-height:1.75; color:#6d5754; }
.me-help p:first-child{ margin-top:0; }
.me-help p:last-child{ margin-bottom:0; }
/* v483（Danmi：说明改成「大标题 + 列点」）——小节标题做成浅粉小标签块，列点自绘粉灰圆点，
   配色跟弹窗的粉白主题走，不引全站那套绿色 .gg-tips。 */
.me-help-h{ display:inline-block; margin:15px 0 7px; padding:2px 10px 3px;
  font-size:12.5px; font-weight:400; letter-spacing:1.5px; line-height:1.5;
  color:#9d6f68; background:#fdf3f0;
  border:1px solid #e7d3cd; border-radius:8px; }
.me-help-body .me-help-h:first-child{ margin-top:0; }
.me-help-ul{ margin:0; padding:0; list-style:none; }
.me-help-ul li{ position:relative; margin:5px 0; padding-left:14px;
  font-size:12.5px; line-height:1.75; color:#6d5754;
  /* v483（Danmi：怎么换行）—— 让源码里的回车真正换行，改文案时在 <li> 里按回车即可；
     行首缩进仍会被折叠，不会因为缩进产生空格。想强制断行也可以直接写 <br>。 */
  white-space:pre-line; }
.me-help-ul li::before{ content:''; position:absolute; left:2px; top:.62em;
  width:4px; height:4px; border-radius:50%; background:#d9b9b2; }
.me-help b{ color:#9d6f68; font-weight:600; margin-right:2px; }
.me-help-back{ display:block; width:100%; margin-top:14px; padding:10px; cursor:pointer;
  flex:0 0 auto;
  border:1.3px solid #d9b9b2; border-radius:999px; background:#fdf4f2;
  color:#bd7777; font-size:13px; }
.me-help-back:active{ background:#fbe9e5; }
/* 弹窗打开会把焦点放到「返回」上（键盘/读屏友好），别让浏览器默认的黑框糊上去 */
.me-help-back:focus{ outline:2px solid #ecd6cf; outline-offset:2px; }
body.help-open{ overflow:hidden; }

/* ============================================================
   v317 · 2026-11-12 13:16 Danmi 反馈落地
   整块只在 ≤720 生效；≥721（含导出 1280）零影响。
   ① 顶部白框去掉 ② 底栏悬浮胶囊且拉开距离 ③ 统一标题（棕玫瑰细体+横线+固定高度）
   ④ 不要可见滚动条 ⑤ 首页左右两栏 ⑥ 卡带图放大 ⑦ 导出导入清除竖排
   ============================================================ */
@media (max-width: 720px) {
  /* 不要任何可见滚动条、不要横向可拖动 */
  html, body{ overflow-x:hidden; }
  *{ scrollbar-width:none !important; -ms-overflow-style:none !important; }
  *::-webkit-scrollbar{ display:none !important; width:0 !important; height:0 !important; }
  .main{ padding:0 14px 104px !important; }

  /* 统一标题框：所有屏严格等高 76px（Danmi 13:38 指认＝红框那个标题区，不是卡带）
     英文固定 26px 单行绝不折行；中文固定 32px 最多两行，长作品名显示得下但绝不撑高框；
     横线固定在盒子底边 → 每一屏的横线 y 坐标完全一致。 */
  .m-pghead{
    display:flex !important; flex-direction:column; align-items:stretch; justify-content:flex-start;
    height:76px; min-height:76px; max-height:76px; box-sizing:border-box;
    margin:16px 2px 14px; padding:0 2px 10px; text-align:left;
    border-bottom:1px solid #d3aca3; overflow:hidden; }
  /* 所有页面的标题框起点严格一致：抵消各页容器自身的 padding / 居中 */
  .works-page, .col-page, .me-page{ padding-left:0 !important; padding-right:0 !important; padding-top:0 !important; }
  .m-pghead-en, .m-pghead-cn{ text-align:left !important; }
  .m-pghead-en{ flex:0 0 26px; height:26px;
    font-family:Georgia,'Times New Roman',serif; font-weight:400;
    font-size:21px; line-height:26px; letter-spacing:.16em; color:#a87b70;
    white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
  .m-pghead-cn{ flex:0 0 32px; height:32px; margin-top:4px;
    font-weight:400; font-size:11px; line-height:16px;
    letter-spacing:.12em; color:#9b857f;
    display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical;
    overflow:hidden; }
  .diary-head, .col-head{ display:none !important; }

  /* 底部 Tab：悬浮圆角胶囊 + 4 项之间拉开距离（不要紧凑） */
  .m-tabbar{ left:14px !important; right:14px !important; bottom:14px !important;
    height:58px !important; align-items:stretch;
    justify-content:space-around; gap:12px; padding:0 12px;
    background:rgba(255,255,255,.88) !important;
    border:1.3px solid #e7d3cd !important; border-radius:999px !important;
    box-shadow:0 8px 24px rgba(180,140,135,.28) !important; }
  .m-tabbar a{ flex:1 1 0; gap:6px; font-size:11px; }
  .m-tabbar a i svg{ width:21px; height:21px; }

  /* 首页 A1：顶部设计背景图 + 头像压边 + 左大卡带 / 右竖排三入口 */
  .m-home{ padding-top:12px; }
  .mh-hero{ position:relative; height:108px; }
  .mh-hero-bg{ position:absolute; inset:0; border-radius:18px;
    border:1.3px solid var(--line);
    background:linear-gradient(rgba(255,255,255,.62),rgba(255,255,255,.62)),
               url('/static/bg_mobile.jpg?v=1') center/cover no-repeat; }
  .mh-avatar{ position:absolute; left:50%; bottom:-40px; transform:translateX(-50%);
    width:82px; height:82px; margin:0; border:3px solid #fff;
    box-shadow:var(--shadow); z-index:2; }
  .mh-name{ text-align:center; margin-top:48px; font-size:22px; }
  .mh-sub{ text-align:center; font-size:11px; margin-top:3px; }
  .mh-body{ display:flex; gap:8px; margin-top:14px; align-items:stretch; }
  .mh-latest{ flex:1 1 0; min-width:0; display:flex; flex-direction:column;
    background:var(--card); border:1.3px solid var(--line); border-radius:16px;
    padding:10px; box-shadow:var(--shadow); }
  .mh-sec-title{ font-size:11px; letter-spacing:.5px; padding:0 0 8px; }
  .mh-works{ display:flex; gap:0; overflow-x:auto; scroll-snap-type:x mandatory;
    padding:0 0 4px; margin:0; }
  .mh-work{ flex:0 0 100%; scroll-snap-align:start; }
  .mh-cover{ width:100%; height:auto; aspect-ratio:3/4; border-radius:12px; }
  .mh-wname{ font-size:11px; margin-top:6px; }
  .mh-dots{ display:flex; gap:5px; justify-content:center; padding-top:8px; margin-top:auto; }
  .mh-dots i{ width:5px; height:5px; border-radius:50%; background:#d9b9b2; display:block; cursor:pointer; }
  .mh-dots i.on{ background:#a87b70; }
  .mh-quick{ flex:0 0 96px; display:flex; flex-direction:column; gap:8px; margin-top:0; }
  .mh-quick-btn{ flex:1; display:flex; align-items:center; justify-content:center;
    padding:8px 4px; font-size:12px; line-height:1.4; border-radius:14px; }
  .mh-quick-btn.dev{ border-style:solid; }

  /* 作品一览：卡带图放大 + 文字按行排（grid 两列，禁止 flex 横排把文字挤成窄列） */
  .works-grid{ gap:10px; }
  .work-card{
    display:grid; grid-template-columns:92px minmax(0,1fr);
    column-gap:12px; row-gap:0; align-items:start; padding:10px; }
  .wc-cover{ grid-column:1; grid-row:1 / span 4;
    width:92px; height:122px; margin:0; border-radius:10px; }
  .wc-name{ grid-column:2; grid-row:1;
    font-size:15px; line-height:1.35; margin-top:0; }
  .wc-meta{ grid-column:2; grid-row:2;
    font-size:11px; line-height:1.5; margin:4px 0 8px; }
  .wc-status{ grid-column:2; grid-row:3;
    display:flex; flex-wrap:wrap; align-items:center; gap:6px; }
  .wc-btns{ grid-column:2; grid-row:4; display:flex; flex-wrap:wrap;
    align-items:center; gap:6px; margin-top:8px; }
  .wc-status .chip{ margin:0; }
  .wc-btns .btn-sub{ order:-1; }

  /* 录入角色 B1：卡带图放大 + 右侧按钮竖排（显隐继续跟随主人/访客模式） */
  /* v497（Danmi：三个框整体上下居中）→ 原来 flex-start 顶对齐，封面比按钮组高，下面会空一截 */
  .manage-top{ gap:12px; align-items:center; }
  .manage-cover{ width:116px; flex:0 0 116px; height:auto; aspect-ratio:3/4;
    object-fit:cover; border-radius:12px; }
  .manage-links{ flex:1 1 0; min-width:0; display:flex; flex-direction:column;
    gap:8px; flex-wrap:nowrap; }
  .manage-links a{ width:100%; box-sizing:border-box; text-align:left; }
  /* v497（Danmi：「去写 Repo」跟前两个框变相同）→ 它是 .btn-main，手机端又吃了 v496 那条
     4px/13px 的扁按钮规则，比两个 .btn-sub 矮一截。这里把三行拉回同一套尺码（同为 41 高），
     底色按 Danmi「颜色加深就是原来的」保留 .btn-main 原本的粉底（桌面端不动，导出图不受影响）。 */
  .manage-links a{ padding:7px 18px; font-size:14px; }
  .manage-links a.btn-main{ background:var(--green-soft); color:var(--green-dark); }
  .manage-links a.btn-main:hover{ background:var(--mint); }

  /* v497（Danmi：角色印象页的 ＋－ 按钮也扁一点）→ 44×32/17px 压到 48×24/14px，
     和盲狙表那排小胶囊同高。只锁 ≤720，桌面与导出（1280）不变。 */
  .row-tools .rt-add, .row-tools .rt-del{
    width:48px; height:24px; padding:0; line-height:1; font-size:14px;
  }
  .works-add .wa-row{ display:flex; flex-wrap:wrap; gap:8px; }

  /* 我的：导出/导入/清除竖排三行（左文字右按钮） */
  .me-page{ padding:8px 8px 24px; }
  .me-page .me-ops{ display:flex; flex-direction:column; gap:8px; }
  .me-page .me-op{ display:flex; align-items:center; justify-content:space-between;
    background:rgba(255,255,255,.82); border:1.3px solid #e7d3cd; border-radius:12px;
    padding:8px 10px 8px 14px; font-size:13px; color:#5a4a47; text-align:left; }
  /* v520：.me-op 是 display:flex，会把 [hidden] 自带的 display:none 盖掉 ——
     手机浏览器开网页版时「同步到主站」因此露出来过。这条必须排在 .me-op 规则之后。 */
  .me-page .me-op[hidden]{ display:none; }
  .me-page .me-op button{ flex:0 0 auto; max-width:none; width:auto;
    border:1.3px solid #d9b9b2; border-radius:999px; background:#fdf4f2;
    color:#bd7777; padding:6px 18px; font-size:12px; }
  /* v10i：使用说明；v10n 改弹窗 —— 手机端两边各留 16px，卡片内边距收紧一档 */
  .me-page .me-help{ padding:16px 14px 12px; }
  .me-page .me-help p{ font-size:12.5px; line-height:1.7; }
  .me-page .me-help-mask{ padding:16px; }
}

/* ≥721（含导出 1280）：移动端专属标题不显示 */
@media (min-width: 721px) {
  .m-pghead{ display:none !important; }
}

/* ============================================================
   v319 · 可写层（/template/*，base_guest.html）接入同一套移动端 UI
   只在 <=720 生效；>=721（含导出 1280）零影响。
   ============================================================ */
@media (max-width: 720px) {
  /* 模板页 content 直接挂在 body 下，没有主站 .main 那层内边距：
     补齐左右 14px 留白与底部 Tab 安全区，和主站标题框起点严格一致 */
  body.guest-page{ padding:0 14px 104px; }
  /* 旧的绿色 .gg-bar 顶栏让位给统一标题 + 底部 Tab；
     导出/导入/重置/检查更新已搬进「我的」页与页面内 */
  .guest-page .gg-bar{ display:none !important; }
  /* 模板首页的 PC「使用说明」在手机上收起，改显示 A1 首页 */
  .guest-page .gg-home{ display:none !important; }
  /* 可写层各页的标题框容器：抵消自身 max-width / 居中，交给 body 统一 */
  .guest-page .works-page, .guest-page .col-page, .guest-page .me-page{
    max-width:none !important; padding-left:0 !important; padding-right:0 !important;
  }
}


/* ============================================================
   v320 · 2026-11-12 18:0x Danmi 五条意见
   ① 标题整块（英文→中文→横线）上移、压缩留白；横线随框底上移后
      下方内容整体跟着上移，同屏能多显示一段（不是留空白）
   ② A1 删「最新编辑的卡带」小标题（DOM 已删）
   ③ A2「＋录入新作品」整块搬到 F2 顶部，替换「⊕ 导入我的游戏」
   ④ F2 筛选换 全部 / 在库 / 进行中 / 全通（DOM 已换）
   ⑤ 名字区：最多 2 行省略、一排统一等高、单行上下左右居中
   ⑥ 搜索按钮视觉收起，输入框回车仍可搜
   只在 <=720 生效；>=721（含导出 1280）零影响。
   ============================================================ */
@media (max-width: 720px) {
  /* 76→60px、上下 margin 16/14→8/10：横线随框底上移 24px，
     后续内容跟着上移 24px（Danmi 18:05 纠正：不是「只挪横线留空白」） */
  .m-pghead{ height:60px; min-height:60px; max-height:60px;
    margin:8px 2px 10px; padding:0 2px 8px; }
  .m-pghead-en{ flex:0 0 24px; height:24px; font-size:20px; line-height:24px; }
  /* 中文小标题紧跟英文、不加粗、单行不折 */
  .m-pghead-cn{ flex:0 0 22px; height:22px; margin-top:2px;
    line-height:22px; display:block; white-space:nowrap;
    overflow:hidden; text-overflow:ellipsis; }
  .m-home{ padding-top:6px; }

  /* 搜索：按钮 1px 视觉收起但留在 DOM，回车照样触发 submit */
  .works-search, .col-search{ position:relative; }
  .works-search button.hide-on-mobile, .col-search .sr-submit{
    position:absolute; right:0; bottom:0; width:1px; height:1px;
    padding:0; border:0; opacity:0; pointer-events:none; overflow:hidden; }

  /* 名字区：固定两行高度 → 一排严格等高；外层 flex 让单行上下左右居中；
     内层 -webkit-box 负责两行截断 + 省略。A2 卡片 / F2 宫格同一套规则 */
  .wc-name, .col-name{ height:2.8em; line-height:1.4; overflow:hidden;
    display:flex; align-items:center; justify-content:center; text-align:center; }
  .wc-name{ margin-top:0; justify-content:flex-start; text-align:left; }
  .col-name{ margin-top:6px; white-space:normal; text-overflow:clip; }
  .wc-name > span, .col-name > span{ width:100%; min-width:0;
    display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical;
    overflow:hidden; line-height:1.4; max-height:2.8em; word-break:break-word; }

  /* F2 顶部的录入框：沿用 A2 原按钮那套皮 */
  .col-add{ margin-top:10px; }
  .col-add summary{ cursor:pointer; list-style:none; font-weight:400; letter-spacing:0;
    border:1.3px dashed #d9b9b2; border-radius:12px; background:#fdf4f2;
    color:#bd7777; padding:10px; font-size:13px; text-align:center; }
  .col-add summary::-webkit-details-marker{ display:none; }
  .col-add .wa-row{ display:flex; flex-wrap:wrap; gap:8px; margin-top:10px; }
  .col-add .wa-row label{ display:block; font-size:12px; color:#5a4a47; }
  .col-add .wa-row input{ display:block; margin-top:4px; max-width:100%;
    border:1.3px solid #e7d3cd; border-radius:10px; padding:7px 10px;
    font-size:13px; background:#fff; color:#5a4a47; font-family:inherit; }
  .col-add .btn-main{ margin-top:10px; }

  /* 四个筛选胶囊平分一行 */
  .col-filters{ gap:6px; }
  .col-filters .pill{ flex:1 1 0; text-align:center; padding:5px 4px; font-size:12px; }
}


/* ============================================================
   v320 补 · 桌面统一（全局生效，避免 1280 冒出多余「搜索」按钮 / 白色录入框）
   ============================================================ */
.col-search{ position:relative; }
.col-search .sr-submit{
  position:absolute; right:0; bottom:0; width:1px; height:1px;
  padding:0; border:0; opacity:0; pointer-events:none; overflow:hidden; }
/* 录入框沿用原「⊕ 导入我的游戏」那颗粉色虚线按钮的皮，不套桌面白卡 */
.col-add{ background:none; border:0; box-shadow:none; padding:0;
  margin:10px 0 0; }
.col-add summary{ cursor:pointer; list-style:none; font-weight:400; letter-spacing:0;
  border:1.3px dashed #d9b9b2; border-radius:12px; background:#fdf4f2;
  color:#bd7777; padding:10px; font-size:13px; text-align:center; }
.col-add summary::-webkit-details-marker{ display:none; }


/* ============================================================
   v321 · 2026-11-12 18:3x Danmi 两条意见
   ① A2 卡片封面撑满整张卡片高度：object-fit:cover 裁切填满，图下方不再留白
   ② F2「＋ 录入新作品」换皮：实线圆角白底 + 左对齐深棕字 + ▸ 折叠三角
   只在 <=720 生效；>=721（含导出 1280）零影响。
   ============================================================ */
@media (max-width: 720px) {
  /* A2 封面：容器跟着右侧四行内容撑满卡片，图本身只等比缩放+居中裁剪，
     绝不拉伸变形、不改任何图片文件（Danmi 18:2x 硬约束） */
  .works-grid .work-card .wc-cover{
    position:relative; height:auto; min-height:122px;
    align-self:stretch; aspect-ratio:auto; overflow:hidden;
  }
  .works-grid .work-card .wc-cover img{
    position:absolute; inset:0; display:block;
    width:100%; height:100%; object-fit:cover; object-position:center;
  }
  .works-grid .work-card .wc-cover .wc-none{
    position:absolute; inset:0; height:auto;
  }

  /* F2 录入按钮：图6 同款 —— 实线白底圆角、左对齐、深棕字、左侧小三角 */
  .col-page .col-add{ margin-top:10px; }
  .col-page .col-add summary{
    display:flex; align-items:center; gap:8px;
    width:100%; box-sizing:border-box;
    border:1.3px solid #e7d3cd; border-radius:14px;
    background:rgba(255,255,255,.86);
    color:#5a4a47; font-size:14px; font-weight:400; letter-spacing:0;
    padding:11px 14px; text-align:left; line-height:1.4;
  }
  .col-page .col-add summary::before{
    content:'\25B8'; flex:0 0 auto; font-size:11px; color:#5a4a47;
  }
  .col-page .col-add[open] summary::before{ content:'\25BE'; }
}

/* ============================================================
   v322 · 内页「一排 pill」→ 右上胶囊 + 连体下拉（线框 v3.1 定稿）
   全局默认隐藏 => 桌面 1280 / 导出图零影响；仅 <=720 接管。
   两组独立：作品内组 4 项、Appraisal 组 3 项，由各页 .edit-switch 自己决定。
   ============================================================ */
.m-pgtools{ display:none; }

@media (max-width: 720px) {
  .edit-nav{ margin:8px 0 10px; gap:8px; flex-wrap:nowrap; }
  .edit-nav .edit-switch{ display:none !important; }
  /* v484（Danmi：手机上左上「← 录入角色 / ← Notes」比右边胶囊大一圈）——
     缩到和 .m-pgtools .m-switch 完全同尺寸：12px / 5px 10px。
     .tool-page 那条「← 返回首页」是 3 类选择器，特异性更高，不受影响。 */
  .edit-nav > .btn-sub{ font-size:12px; padding:5px 10px; }
  /* 注：appraisal / blind_pick 的「← 返回首页」包在 .nav-left 里（不是 .edit-nav 的直接子元素），
     子选择器命中不到，天然不受影响。 */
  .m-pgtools{
    display:flex; align-items:center; gap:6px; margin-left:auto;
    position:relative; flex:0 0 auto;
  }
  .m-pgtools .m-help{ width:22px; height:22px; font-size:12px; }
  .m-pgtools .m-switch{ font-size:12px; padding:5px 10px; max-width:52vw; }
  .m-pgtools .m-pop{
    top:100%; right:0; margin-top:0; min-width:132px;
    border-radius:0 0 14px 14px; border-top:none;
  }
  .m-pgtools .m-pop a{ padding:10px 12px; font-size:12.5px; }
}

/* ---------------- v323 · 九宫格文字标签放大 + 居中（仅页面显示） ---------------- */
/* appraisal.html 加载时给 body 加 .lbl-big；点「生成照片」前摘掉、导完恢复。
   导出走 fieldToDiv（复制 computed 样式），摘类后复制到的仍是旧值 → 导出图一像素不变。
   旧值：font-size 19px、无固定高、cell gap 6px（手机端 font-size 16px）。 */
body.lbl-big .grid-label { font-size: 23px; height: 38px; padding: 0 4px; }
body.lbl-big .grid-cell { gap: 2px; }
@media (max-width: 720px) {
  body.lbl-big .grid-label { font-size: 18px; height: 30px; }
}

/* ---------------- v324 手机端批次1：标题对齐E1/E2 + E3图大字小 ---------------- */
@media (max-width: 720px) {
  /* C区三页（角色印象/分线评价/Notes）标题 = E1/E2「☆Character Appraisal☆」同款大小位置 */
  .m-cap-head { justify-content: center; flex-wrap: wrap; row-gap: 4px; column-gap: 10px; margin-bottom: 8px; }
  .m-cap-head .rp-cap { font-size: 19pt; line-height: 1.35; letter-spacing: 1px; }
  .m-cap-head .rp-title { font-size: 14px; line-height: 22px; max-width: 200px; }

  /* D1 盲狙表：翻页 ◀1▶ 回到标题行右侧，与标题对齐 */
  .bpl-head { padding-bottom: 6px; }
  .bpl-pager { top: 50%; bottom: auto; transform: translateY(-50%); }

  /* E1/E2：评价（S+）下面的编辑文字框 —— v480 10→14px，v10g 14→16px（两端同放大），
     v10h 手机 16→15px，v10i（Danmi：手机端的这个字体再小一点）→ 14px。桌面 24px 不动。
     框高 :2337 的 28px 不变，14×1.35≈19px 仍装得下。 */
  .apr-text { font-size: 14px; }

  /* E3 自定义九宫格：3×3 不变，图片更大（收紧间隙）、文字更小（约10字/行），保持居中 */
  .grid-board { padding: 3px 8px 10px; }
  .grid-cells { gap: 8px 5px; }
  body.lbl-big .grid-label { font-size: 11px; height: 18px; padding: 0 2px; }
  body.lbl-big .grid-cell { gap: 1px; }
}

/* ---------------- v325 · Danmi 四条意见（仅手机端） ----------------
   ① C区三页标题不居中，从最左开始 ② E3 白框顶下移对齐 E1 标题行
   ④ E3 (标题) 缩小/图片再放大（评级框颜色由 v327 处理：半透明=九宫格大框） */
@media (max-width: 720px) {
  .m-cap-head { justify-content: flex-start; }

  .grid-board { margin-top: 30px; padding: 2px 5px 8px; }
  .grid-cells { gap: 6px 4px; }
  .grid-title { width: 200px; height: 30px; font-size: 14px; line-height: 30px; }
}

/* ---------------- v326 · Danmi 三条（仅手机端） ----------------
   ① E1/E2 评级框恢复淡绿底（v325 改白底是改错了）② C区三页标题下移对齐 E1/E2 标题行
   ③ E3 九宫格间隙再收紧、图片再放大 */
@media (max-width: 720px) {
  /* 手机端：评级框底 = 九宫格大框(board)同款半透明，透出壁纸绿，观感一致 */
  .apr-grade { background: rgba(253, 254, 251, .92); border-color: rgba(255, 255, 255, .6); }

  .m-cap-head { margin-top: 29px; }

  .grid-board { padding: 2px 0 6px; }
  .grid-cells { gap: 2px 2px; }
  body.lbl-big .grid-cell { gap: 0; }
  body.lbl-big .grid-label { min-height: 30px; font-size: 11px; }

  /* v349h：格子下文字框换成 textarea，可折两行、每行最多 7 字（maxLength=14）。
     width:7.5em≈7 字宽；word-break 任意折行；max-height 限 2 行、超出裁掉。
     列宽恢复 1fr → 照片撑满格子变大，间距让出来 */
  .grid-label {
    width: 7.5em; max-width: 100%; min-width: 0; box-sizing: border-box;
    display: block; margin: 0 auto; resize: none;
    text-align: center; white-space: normal; word-break: break-all;
    line-height: 1.35; max-height: 2.7em; overflow: hidden; }
}

/* ---------------- v328 · 左上角返回按钮文字（仅手机端显示层） ----------------
   C区已改 DOM 本体（v329），此处只剩 tool-page：D1/E区(tool-page)：← 返回模板首页/首页 → ← 返回首页。
   用 font-size:0 + ::after 换字，DOM 原文不动 → 桌面/导出零影响。 */
@media (max-width: 720px) {
  .tool-page .edit-nav .btn-sub { font-size: 0; }
  .tool-page .edit-nav .btn-sub::after { content: "\2190  返回首页"; font-size: 12px; }
}

/* ---------------- v331 · 手机端标题行防挤爆 ----------------
   作品名(rp-title)过长：同一行内单行省略号截断（出「…」），
   不折行到下一行、徽标(1/2)等后续元素仍贴右。桌面与导出图不受影响。 */
@media (max-width: 720px) {
  .m-cap-head { flex-wrap: nowrap; }
  /* 标题牌（⚝ 角色印象 等）不许被压缩/内部折行，宽度始终完整 */
  .m-cap-head .rp-cap { flex: 0 0 auto; white-space: nowrap; }
  .m-cap-head .rp-title {
    flex: 0 1 auto;
    min-width: 0;
    max-width: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

/* ---------------- v349j · E3 九宫格文字改单行(编辑方式) + 删九宫格外层半透淡绿大框（仅手机端） ----------------
   ① Like 九宫格文字标签：只改编辑方式 → 两行 textarea 改回单行 input（之前保底 min-height:30px，
      只写一行时下方空一截，单行后空隙消失）。字体样式保持原姚体(同 desktop .grid-label)，不改。
   ② 撤回误删：图2(repo 奖项)内部虚线框(award-box border)不动 —— 她要的是「外面那圈半透淡绿外框」。
   ③ 删掉图1(Like 九宫格)整页的 .grid-board 半透明白绿大框(background rgba(253,254,251,.92)+圆角)，
      透出壁纸绿即那圈「淡绿外框」。只动手机显示层；desktop 的框原样保留 → 导出照片(1280)不受影响。 */
@media (max-width: 720px) {
  .grid-label {
    width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box;
    height: 18px; line-height: 18px; padding: 0 2px; margin: 0;
    border: 0; background: transparent; border-radius: 0; outline: none;
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-weight: 400;
    font-size: 12px; color: #34845c;
    text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  body.lbl-big .grid-label { font-size: 12px; height: 18px; line-height: 18px; padding: 0 2px; min-height: 0; }
  body.lbl-big .grid-cell { gap: 4px; }

  .grid-board { background: transparent; border: none; box-shadow: none; }

  /* v349m：真凶修正式 —— ≤720 块里 2232 行 .apr-img{82px} 级联在 .grid-img{100%} 之后，
     同特异性后者被覆盖 → 九宫格照片一直只有 82px、在 1fr 格子里居中，
     两侧各剩 20+px 空隙（她圈的左边距）。双类选择器压回：照片撑满格子、左距贴边 */
  .apr-img.grid-img { width: 100%; height: auto; aspect-ratio: 1 / 1; }
}

/* ---------------- v350 · #48 C区手机端重排 ----------------
   草图：Danmi 11-13 手绘（角色印象/分线评价横排行）+ 线框 C3/C4 批注（Notes 拆两屏）。
   ① 角色印象：行改横排 = 角色图(92px)左 + 初印象/现印象右（模式1 两框并排 / 模式2 上下堆叠）。
   ② 分线评价：行改横排 = 角色图(92px)左 + 人设/剧情同排 + 评价框。
   ③ Notes：≤720 内隐藏旧竖排列表，换 C3 首屏（一排三个角色图+名字，点击进 C4）
      + C4 角色板块（CG 大图可滑动换张 + 1/N 计数 + 碎碎念 + 照片格子=添加张数）。
      数据源不变（NT 行），桌面 >720 仍走旧列表，导出照片（1280 视口）零影响。 */
.nt-mobile { display: none; }

@media (max-width: 720px) {
  /* ---- 角色印象横排行 ---- */
  .works-page .imp-row { flex-direction: row; align-items: flex-start; gap: 8px; }
  .works-page .imp-char { flex: 0 0 92px; }
  .works-page .imp-img { width: 92px; height: 92px; }
  /* 手机 92px 方框，加号跟着小一号；桌面 200px 框用 22px */
  .works-page .imp-img .ph-plus, .works-page .route-img .ph-plus { font-size: 16px; }
  .works-page .imp-texts { flex: 1 1 auto; min-width: 0; width: auto; min-height: 0; }
  .works-page .imp-list.two-col .imp-texts { flex-direction: row; gap: 6px; }
  .works-page .imp-list.two-col .imp-field,
  .works-page .imp-list.two-col .imp-field.plain,
  .works-page .imp-list.two-col .imp-field.tone { flex: 1 1 0; min-width: 0; min-height: 0; }
  .works-page .imp-list:not(.two-col) .imp-texts { flex-direction: column; gap: 6px; }
  .works-page .imp-field textarea { flex: 0 0 auto; }
  .works-page .imp-texts .imp-field.tone { min-height: 0; }
  /* v351d→v351e：角色名（姚体）= imp-row/route-row 直接子元素，排在图后同排（贴图+垂直居中）；
     imp-texts 因 max-content 过宽仍会 wrap 到图下一行（现状），名字不随它掉下去 */
  /* v351g：名字跟图上下居中（名字与图同属第一条 flex 线，center 即对图居中）、字号 18px；横距 14px 保留 */
  .works-page .imp-char-name, .works-page .route-char-name {
    display: block; flex: 0 1 auto; min-width: 0; align-self: center;
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-weight: 400;
    font-size: 18px; line-height: 22px; color: var(--green-dark);
    letter-spacing: 1px; text-align: left; margin: 0 0 0 14px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .works-page .imp-char-name:empty, .works-page .route-char-name:empty { display: none; }
  /* v351d：框内填写内容字号 14→13px（初印象/现印象/分线评价共用 .imp-field textarea） */
  /* v422 把桌面放大到 16px 内容 / 15px 标签（全局规则），手机端跟着变大——
     v423 Danmi 说「手机端刷新发现字比之前大了」→ 手机这层全部退回 v422 之前的原值：
     内容 13px（v351d 原值，初印象/现印象/分线评价共用）、标签 13px。
     桌面（>720）保持 16 / 15 不变。 */
  /* v484（Danmi：初印象/现印象框里的字再小一点）→ 内容与标签一起 13 → 12px。
     桌面走 3325 之前的全局规则（16/15），这里只动手机这层。 */
  .works-page .imp-field textarea { font-size: 12px; line-height: 1.8; }
  .works-page .imp-label { font-size: 12px; }

  /* ---- 分线评价横排行 ---- */
  .works-page .route-row { flex-direction: row; align-items: flex-start; gap: 8px; }
  .works-page .route-left { flex: 0 0 92px; }
  .works-page .route-img { width: 92px; height: 92px; }
  .works-page .route-right { flex: 1 1 auto; min-width: 0; width: auto; min-height: 0; }
  .works-page .route-scores { flex-direction: row; flex-wrap: wrap; gap: 2px 14px; }
  .works-page .route-notes textarea { min-height: 56px; }

  /* ---- Notes 双视图：旧列表退场 ---- */
  .nt-mobile { display: block; }
  .works-page.nt-page .nt-list,
  .works-page.nt-page .row-tools { display: none; }

  /* C3 首屏：一排三个角色图 + 下排名字 */
  .nt-chars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px 8px; }
  .nt-char-cell { display: flex; flex-direction: column; gap: 4px; align-items: center; cursor: pointer; }
  .nt-char-img {
    width: 100%; aspect-ratio: 1 / 1; border-radius: 4px; box-sizing: border-box;
    /* v10m（Danmi：框不要绿的）：原来的淡绿虚线 #b6d3a8 / 淡绿底 #fbfdf8 换成粉白玫瑰调，
       和手机端花草背景（--mint #f7ece9 / --green-dark #9d6f68）同族。 */
    border: 1px dashed #e3c7c0; background-color: #fdf8f6;
    background-size: cover; background-position: center;
  }
  .nt-char-img.filled { border-style: solid; }
  .nt-char-name {
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-size: 12px;
    color: #34845c; text-align: center; line-height: 1.3; max-width: 100%;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }

  /* C4 角色板块：CG 大图（左右滑动换张）+ 计数 + 碎碎念 + 照片格 */
  /* v350b：大图去框（空态/有图都不带边框）、比例改 2:1（参照她给的宽长方形示例） */
  /* v350d：按钮回到「1 / 4」计数两侧同一排（v350c 误放到图片两侧，已纠正）；图片恢复全宽 */
  /* v350e：大图圆角 8px（一点点）；碎碎念透明底+玫瑰灰实线框 #e7d3cd（图3 录入角色表单同款）；选中缩略图外框改 #e7d3cd（粗细 2px 不变） */
  .nt-cg-meta { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 6px; }
  .nt-cg-count-m { font-size: 12px; color: var(--muted); }
  .nt-cg-meta .nt-btn { padding: 2px 10px; font-size: 11px; }
  .nt-cg-view-m {
    flex: none; width: 100%; min-width: 0; aspect-ratio: 3 / 2; border: none; border-radius: 8px;
    background: transparent; background-size: cover; background-position: center;
    display: flex; align-items: center; justify-content: center; overflow: hidden;
    position: relative; touch-action: pan-y; cursor: grab; box-sizing: border-box;
  }
  .nt-cg-view-m.dragging { cursor: grabbing; }
  /* v380：CG 大图改「克隆三组 + transform 无缝轮播」（移植首页 _section.html 的 oshiCarousel 机制：
     自动播放 3.5s + 跟手滑动 + 末张→首张无回弹；不放 will-change，避免整轨合成超大纹理被显存回收白闪）。
     轨道绝对铺满 view，占位符在轨道之上居中显示。 */
  .nt-cg-track { position: absolute; inset: 0; display: flex; height: 100%; }
  .nt-cg-slide { flex: 0 0 100%; background-size: cover; background-position: center; }
  /* 每张图等比缩放+居中裁剪，绝不变形；pointer-events:none 让滑动手势落到 view 上 */
  .nt-cg-slide img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; pointer-events: none; }
  .nt-cg-view-m.no-cg .nt-cg-track { display: none; }
  /* v351b→v351c：碎碎念标签改「框内左上」（对齐角色印象「初印象：」样式：姚体+var(--green-dark)+字距），
     边框挪到外层 wrap，textarea 无边框贴标签下方 */
  .nt-notes-wrap-m {
    margin-top: 12px; width: 100%; box-sizing: border-box;
    padding: 6px 10px 4px;
    /* v487 曾填不透明 var(--mint)；v489 Danmi 要改回透明；v490 折中：半透明白
       —— 背景纹理仍透得出来，但文字底下有一层薄光，读起来不飘。 */
    border: 1px solid #e7d3cd; border-radius: 4px; background: rgba(255,255,255,.38);
  }
  /* v484（Danmi：Notes 碎碎念的字再小一点）→ 内容 14 → 12.5px、标签 13 → 12px。
     v486（Danmi：「改成 13px 试试」）→ 内容 12.5 → 13px，标签维持 12px。 */
  /* v491（Danmi：「碎碎念：」改成和内容一样大）→ 标签 12 → 13px，与 .nt-notes-m 同字号。
     v493（Danmi：给「碎碎念」这三个字本身加个外框）→ block 改 inline-block，
     框只包住文字不撑满一行；同款 1px #e7d3cd 细边框，跟外层 textarea 框同一套颜色。 */
  .nt-notes-lbl-m {
    display: inline-block; height: auto; line-height: 18px;
    padding: 1px 8px; border: 1px solid #e7d3cd; border-radius: 4px;
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-weight: 400;
    font-size: 14px; color: var(--green-dark); letter-spacing: 1px; text-align: left;
  }
  /* v488（Danmi：碎碎念文字有点密）—— 原先没设 line-height 走 normal（13px 约 15.6px 行高），
     字号收小后行距跟着挤。这里固定 1.7（13 × 1.7 ≈ 22px），跟角色印象的 1.8 同一档观感。 */
  .nt-notes-m {
    display: block; width: 100%; box-sizing: border-box; margin-top: 0; padding: 2px 0 4px;
    font-family: inherit; font-size: 13px; color: var(--text); line-height: 1.7;
    border: none; border-radius: 0; background: transparent;
    resize: none; overflow: hidden; min-height: 74px;
  }
  .nt-notes-m:focus { outline: none; }
  .nt-thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 10px; }
  /* v350b：没选中的缩略图不再有虚线框，选中的保留绿实线 */
  .nt-thumb {
    aspect-ratio: 1 / 1; border: none; border-radius: 4px; box-sizing: border-box;
    background-size: cover; background-position: center; cursor: pointer;
  }
  .nt-thumb.on { border: 2px solid #e7d3cd; }

  /* v351h：录入角色 B1 卡片——间隙 12→8px、卡内 padding 收窄让图更大；名字改姚体居中
     （.char-card .wc-name 双类压过上方 .wc-name 的 text-align:left，只作用角色卡不影响作品卡） */
  .chars-grid { gap: 8px; }
  .char-card { padding: 6px 6px 4px; }
  .char-card .wc-name {
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-weight: 400;
    justify-content: center; text-align: center; margin-top: 2px;
  }
}

/* ===== v386 · 录入数据页按钮精简（Danmi 19:4x 草图：换图/删除 小方框按钮） =====
   双 span 切换：.del-t 桌面全文（🗑 删除这个角色 / 🖼 选图），.del-s 手机短文（删除 / 换图）。
   站长版原生 file 控件整行藏掉，label.if-row-img 本身变「换图」小按钮（label 包裹 input，
   点击 label 仍触发选图，表单提交功能不变）。桌面 >=721 与导出 1280 零影响。 */
.del-s { display: none; }

/* ===== v384 · 修改录入数据页（work_info_edit）手机端大改（Danmi 19:2x 草图） =====
   ①标题 EDIT DATA/修改录入数据·作品名（m-pghead，模板补）；②作品卡封面左字段右；
   ③角色区 3 列网格：只读角色（站长录入，srcId!=null）→ 卡带瓦片（图+姚体名），
     自添角色/站长模式角色 → 同网格 1 格可编辑卡（方图上+姓名/换图/删除竖排，v385 一排三个）；
   ④取消/保存、危险操作照旧。桌面 >=721 与导出 1280 零影响（全部锁本块内）。 */
@media (max-width: 720px) {
  .works-page .info-form { gap: 10px; }
  .works-page .info-block {
    padding: 12px 12px 12px; border-radius: 14px;
  }
  .works-page .info-h { font-size: 13px; letter-spacing: 1.5px; margin: 0 0 10px; }

  /* 作品卡：卡带图左、字段右（对齐草图①②） */
  .works-page .info-work { flex-direction: row; flex-wrap: nowrap; align-items: flex-start; gap: 12px; }
  .works-page .info-cover { width: 96px; height: 128px; flex: 0 0 96px; }
  .works-page .info-fields { min-width: 0; gap: 8px; }
  .works-page .if-row { gap: 8px; font-size: 12px; }
  .works-page .if-label { min-width: 48px; font-size: 12px; }
  .works-page .if-row input[type="text"] { padding: 7px 10px; font-size: 14px; }
  .works-page .if-check { font-size: 11px; }
  .works-page .if-tip { font-size: 11px; line-height: 1.7; }

  /* 角色区：3 列网格；minmax(0,1fr) 允许格子压到任意宽（v385b：1fr 的 min-content
     会被原生「选择文件」输入框撑爆→整行超屏横向溢出） */
  .works-page .info-chars { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 8px; }

  /* 只读瓦片：无底无框，方图 + 姚体角色名居中（同录入角色页 char-card 观感） */
  .works-page .info-char.ro-tile {
    grid-column: auto; background: transparent; border: none; box-shadow: none;
    padding: 0; align-items: center; gap: 0;
  }
  .works-page .info-char.ro-tile .ic-img {
    width: 100%; height: auto; aspect-ratio: 1/1; border-radius: 10px;
  }
  .works-page .info-char.ro-tile .tile-name {
    width: 100%; margin-top: 4px; text-align: center;
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif; font-weight: 400;
    font-size: 14px; line-height: 18px; color: var(--green-dark); letter-spacing: 1px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }

  /* 可编辑卡（v385：一排三个，同一网格占 1 格）：方图在上，姓名/换图/删除竖排紧凑 */
  .works-page .info-char {
    grid-column: auto; flex-direction: column; align-items: stretch;
    gap: 6px; padding: 8px 8px 10px; border-radius: 12px;
    min-width: 0; overflow: hidden;
  }
  .works-page .info-char .ic-img {
    width: 100%; height: auto; aspect-ratio: 1/1; border-radius: 8px;
  }
  .works-page .info-char .if-row { width: auto; gap: 6px; min-width: 0; }
  .works-page .info-char .if-label { min-width: 30px; font-size: 11px; }
  .works-page .info-char .if-row input[type="text"] {
    flex: 1 1 0; min-width: 0; padding: 5px 8px; font-size: 13px;
  }
  /* 原生文件输入框可收缩（不收缩会把格子/整行撑爆），文字超长由控件自身截断 */
  .works-page .info-char input[type="file"] {
    flex: 1 1 0; min-width: 0; max-width: 100%; font-size: 11px;
  }
  .works-page .info-char .if-row .btn-sub { padding: 4px 10px; font-size: 12px; }
  .works-page .info-char .ic-del {
    align-self: stretch; padding: 5px 8px; font-size: 12px; text-align: center;
  }

  /* v386：换图/换封面 → 原生 file 控件整体不出现，label 变紧凑「换图」小按钮
     （草图：方框「换图」；label 包裹 input，点击仍触发选图，表单功能不变） */
  .works-page .if-row-img {
    display: inline-flex; align-items: center; justify-content: center;
    width: auto; flex: 0 0 auto; align-self: flex-start;
    gap: 0; border: 1px solid var(--line); border-radius: 8px;
    padding: 5px 14px; background: #fff; cursor: pointer;
  }
  .works-page .if-row-img .if-label { min-width: 0; font-size: 12px; }
  .works-page .if-row-img input[type="file"] { display: none; }
  /* 删除按钮手机端只显「删除」 */
  .works-page .ic-del .del-t { display: none; }
  .works-page .ic-del .del-s { display: inline; }

  /* v387：游客版「换图」与主站版对齐——只藏「换图」前缀文字，按钮本体保留，
     拉成主站同款满宽方框「换图」（绿字粗体、白底、var(--line) 边框、居中）；桌面不受影响 */
  .works-page .info-char .g-img-row .if-label { display: none; }
  .works-page .info-char .g-img-btn {
    display: flex; width: 100%; align-items: center; justify-content: center;
    gap: 0; border: 1px solid var(--line); border-radius: 8px;
    padding: 5px 14px; background: #fff; font-weight: 700;
    font-size: 12px; color: var(--green-dark);
  }
  .works-page .info-char .g-img-btn .del-t { display: none; }
  .works-page .info-char .g-img-btn .del-s { display: inline; }

  /* 取消/保存 与 危险操作 */
  .works-page .info-actions { padding-bottom: 4px; gap: 10px; }
  /* v500：Danmi 要求再扁一点、字随之小一点 */
  .works-page .info-actions .btn-sub,
  .works-page .info-actions .btn-main { padding: 5px 16px; font-size: 12px; }
  .works-page .danger-zone .ic-del.big {
    align-self: flex-start; padding: 5px 14px; font-size: 12px;
  }
}

/* ===== v388 · 录入数据页「作品名/姓名」去前缀标签 + 字号调小 + 图变大（Danmi 20:0x 截图） =====
   ①「作品名」「姓名」前缀标签手机端不显示，输入框直接占满整行（更贴近"直接编辑"）；
   ②输入文字调小：作品名 14→12px、姓名 13→12px；
   ③角色卡图片变大：卡内边距/列距逐版收紧（v388 8→6，v389 再→4px 左右），瓦片与可编辑卡同受益；桌面 >=721 与导出 1280 零影响。 */
@media (max-width: 720px) {
  .works-page .if-row-title .if-label,
  .works-page .info-char .if-row-name .if-label { display: none; }
  .works-page .if-row-title input[type="text"] {
    flex: 1 1 0; min-width: 0; width: 100%;
    padding: 6px 10px; font-size: 12px;
  }
  .works-page .info-char .if-row-name input[type="text"] {
    padding: 5px 8px; font-size: 12px;
  }
  .works-page .info-chars { gap: 8px 4px; }
  .works-page .info-char { gap: 4px; padding: 4px 4px 6px; }
}

/* ===== v390 · 换图/删除并排一行（Danmi 20:0x 截图：两钮竖排占地大，并排+字小） =====
   模板把换图（主站 label.if-row-img / 游客 label.g-img-row>button.g-img-btn）
   与删除 button.ic-del 包进 .ic-btns 行容器；≤720 内 flex 一行两钮等宽。
   字号 12→11px、padding 收紧；桌面 >=721 无 .ic-btns 规则、原竖排不变。 */
@media (max-width: 720px) {
  .works-page .info-char .ic-btns { display: flex; gap: 4px; width: auto; }
  /* v10 问题1：游客分支多一层 label.g-img-row，被 flex:1 1 0 挤到 35px，
     里面「换图」只剩 17px 宽 → 折成上下两行。给两钮留足 44px 并禁止折行。
     主站分支没有这层嵌套，网页端本来就是好的。 */
  .works-page .info-char .ic-btns > * { flex: 1 1 auto; min-width: 44px; }
  .works-page .info-char .ic-btns .if-row-img {
    align-self: stretch; width: auto; flex: 1 1 auto; padding: 4px 8px;
  }
  .works-page .info-char .ic-btns .if-row-img .if-label { font-size: 11px; }
  .works-page .info-char .ic-btns .g-img-btn { padding: 4px 8px; font-size: 11px; }
  .works-page .info-char .ic-btns .ic-del {
    align-self: stretch; padding: 4px 8px; font-size: 11px;
  }
  .works-page .info-char .ic-btns .del-s { white-space: nowrap; }
}

/* ===== v391 · 录入角色页（work_manage）角色卡图再放大（Danmi 20:1x 截图圈图） =====
   图改满铺卡顶（padding 归 0、图只圆上角），格子间距 8→6px；名字区自己留边。
   只作用 .char-card（角色卡），作品卡不受影响；桌面 >=721 与导出 1280 零影响。 */
@media (max-width: 720px) {
  .chars-grid { gap: 6px; }
  .char-card { padding: 0 0 4px; }
  .char-card img { border-radius: 8px 8px 0 0; }
  .char-card .wc-none { border-radius: 8px 8px 0 0; }
  .char-card .wc-name { margin-top: 3px; padding: 0 3px; }
}

/* ===== v392 · 改资料页（work_info_edit）角色可编辑卡图满铺卡顶（同录入角色页 char-card 铺满，Danmi 20:1x） =====
   info-char（自添/可编辑角色卡）原本缩在白底卡内（v388 留 4px 内边距），现在图满铺卡顶、
   卡 padding 归 0、图只圆上角（贴卡圆角）；姓名行与按钮行自留左右边距。
   只读瓦片 ro-tile 本就 padding:0 满铺，无需改。所有规则锁 ≤720，桌面 >=721 与导出 1280 零影响。 */
@media (max-width: 720px) {
  .works-page .info-char { padding: 0; }
  .works-page .info-char .ic-img { border-radius: 12px 12px 0 0; }
  .works-page .info-char .if-row-name { margin: 5px 4px 0; }
  .works-page .info-char .if-row-img { margin: 4px; }
  .works-page .info-char .g-img-row { margin: 0; }
  .works-page .info-char .ic-btns { margin: 4px; }
}

/* ===== v10 第二轮 ===== */
/* 问题1b：游客分支「换封面」按钮对齐主站那个小方形（padding / 字号 / 圆角都收小）。
   用 #coverBtn 的 ID 特异性，不怕 .btn-sub 的先后顺序。 */
@media (max-width: 720px) {
  .works-page .info-fields #coverBtn {
    padding: 4px 10px; font-size: 12px; font-weight: 700;
    border-radius: 8px; border: 1px solid var(--line);
    background: #fff; color: var(--green-dark);
    white-space: nowrap; line-height: 1.4;
  }
}

/* B2：Repo 表「本篇/fd ＋ 全通:是/否」那一块太挤，拉开距离。
   只加 margin / padding / gap，不动 grid 列宽和行高，其它排布一像素不变。 */
@media (max-width: 720px) {
  .rp-capture .rpt-line:nth-of-type(1) > .tickgrp,
  .rp-capture .rpt-line:nth-of-type(2) > .tickgrp { margin-top: 8px; }
  .rp-capture .rpt-line:nth-of-type(2) > .tickgrp { padding-left: 14px; }
  .rp-capture .tick { gap: 8px; }
}

/* B3 方案②：安卓软键盘弹出期间隐藏底部 4-Tab，收起后自动恢复。
   类由 base.html / base_guest.html 里的 visualViewport 监听加 / 删。 */
body.kb-open .m-tabbar { display: none !important; }

/* ===== v10f · 导出照片遮罩：和「正在翻开手账」等待页同一套视觉 =====
   独立一组 class，不复用 #gdBoot（它加载完就被移除；且导出时 withDesktop()
   会把 viewport 临时改成 1280，媒体查询会误判成桌面）。手机与否由 JS 在改
   viewport 之前记进 gd-export-phone 类。字体同样只用系统 serif，不碰 web font。 */
.gd-export-veil {
  position: fixed; left: 0; top: 0; right: 0; bottom: 0; z-index: 2147483647;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background-color: #fbf3f1;
  background-image:
    linear-gradient(rgba(246,250,247,.22), rgba(246,250,247,.22)),
    url('/static/bg.jpg?v=24');
  background-size: cover; background-position: center;
  font-family: serif;
}
.gd-export-veil.gd-export-phone {
  background-image:
    linear-gradient(rgba(255,255,255,.80), rgba(255,255,255,.80)),
    url('/static/bg_mobile.jpg?v=1');
  background-repeat: no-repeat;
}
.gd-export-title {
  font-size: 26px; letter-spacing: 5px; color: #9d6f68; margin-bottom: 16px;
}
.gd-export-tip {
  font-size: 12px; letter-spacing: 3px; color: #c9a39b;
  animation: gdExportPulse 1.6s ease-in-out infinite;
}
@keyframes gdExportPulse { 0%,100% { opacity:.5 } 50% { opacity:1 } }
@media (prefers-reduced-motion: reduce) { .gd-export-tip { animation:none; opacity:.8 } }

/* ===== v394 · 录入角色页「添加角色」表单：角色图按钮与「＋添加这个角色」并排一行 =====
   Danmi 20:2x 截图：wa-row 里「角色图 [🖼 选一张图]」整条改成一个小「角色图」按钮，
   挪到 wa-foot 与「＋ 添加这个角色」并排，字体调小。
   做法：wa-row 原「角色图」控件加 .wa-img-src（手机端缩成不可见但保留在表单里，
   主站版 file input 靠 wa-foot 的 <label for="charFileInput"> 外连触发，功能不变）；
   游客版 newCharImgBtnM 与原按钮绑同一 JS 处理。
   所有规则锁 ≤720，桌面 >=721 与导出 1280 零影响（.wa-img-m 桌面基础区 display:none）。 */
@media (max-width: 720px) {
  /* 原「角色图」行整体缩走（clip 而非 display:none，保证 file input 仍可被 label 触发） */
  .works-add .wa-img-src {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap;
  }
  /* 并排小按钮：主站版是 <label for>，游客版是真按钮，同款外观 */
  .works-add .wa-img-m {
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--card); color: var(--green-dark);
    border: 1px solid var(--line); border-radius: 999px;
    padding: 5px 14px; font-size: 12px; font-family: inherit;
    cursor: pointer; white-space: nowrap;
  }
  .works-add .wa-foot { justify-content: flex-start; gap: 8px; }
  /* 添加按钮字号同步调小 */
  .works-add .wa-foot .btn-main { font-size: 12px; padding: 5px 14px; }
}

/* ===== v396d · 录入角色页添加表单：三钮瘦长款 + 提示句同排（Danmi 20:5x 参考图） =====
   三钮（角色图/＋添加/⇩导入）统一瘦长药丸：padding 5px 20px、12px 字、常规字重；
   第二行提示句缩 11px + nowrap 不换行，与瘦长导入按钮同排靠右（参考图3 文字+按钮一行）。
   纯 CSS，模板 DOM 不动，桌面 >=721 与导出 1280 零影响。 */
@media (max-width: 720px) {
  /* 角色图 + 添加 一排靠左，瘦长同高 */
  .works-add .wa-foot { flex-wrap: wrap; justify-content: flex-start; gap: 8px; align-items: center; }
  .works-add .wa-img-m,
  .works-add .wa-foot .btn-main {
    flex: 0 0 auto; min-width: 0; padding: 5px 20px;
    font-size: 12px; white-space: nowrap; font-weight: 400;
    display: inline-flex; align-items: center; justify-content: center;
    box-sizing: border-box; line-height: 1.5;
  }
  /* 导入 + 提示句 同排靠右、不换行 */
  .works-add .ci-bar {
    display: flex; flex: 1 1 100%; flex-wrap: nowrap;
    justify-content: flex-end; align-items: center; gap: 8px;
    margin: 8px 0 0;
  }
  .works-add .ci-hint { margin: 0; text-align: right; font-size: 11px; white-space: nowrap; }
  .works-add .ci-open {
    flex: 0 0 auto; min-width: 0; padding: 5px 20px;
    font-size: 12px; font-weight: 400; white-space: nowrap;
    display: inline-flex; align-items: center; justify-content: center;
    box-sizing: border-box; line-height: 1.5;
  }
  /* 添加表单：标签字小 + 输入框随之变小 */
  .works-add .wa-row label { font-size: 13px; }
  .works-add .wa-row input[type="text"] {
    width: 160px; max-width: 60vw; padding: 5px 10px; font-size: 13px; border-radius: 8px;
  }
}

/* ===== v400 · 录入角色页添加表单整体收紧（Danmi 21:0x 截图圈整个表单：稍微紧凑一点，好多空） =====
   纯间距收紧，字号/按钮样式一律不动（v399 刚定稿）：表单内边距 12/18→8/12、
   表单下边距 20→12、姓名行下距 12→6、提示行上距 8→4。锁 ≤720，桌面零影响。 */
@media (max-width: 720px) {
  .works-add { padding: 8px 12px; margin-bottom: 12px; }
  .works-add .wa-row { margin-bottom: 6px; }
  .works-add .wa-foot { gap: 6px; }
  .works-add .ci-bar { margin: 4px 0 0; }
}

/* ===== v405 · 主站侧栏「数据」卡（CATEGORY 下、side-foot 上那块空地）=====
   和模板板块顶栏同款按钮文案；仅主人在 {% if editable %} 里渲染，访客根本拿不到 DOM。
   桌面侧栏专用：≤720 侧栏本就 display:none，不影响手机端与导出图。 */
.side-io { margin-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.side-io .side-cap { padding: 0 4px 2px; }
.side-io-btn {
  width: 100%; box-sizing: border-box; text-align: center;
  font-size: 12.5px; padding: 7px 6px; letter-spacing: .5px;
}
.side-io-btn:disabled { opacity: .55; cursor: wait; }
.side-io-note {
  font-size: 10.5px; color: var(--muted); opacity: .75;
  text-align: center; line-height: 1.5; margin-top: 2px;
}

/* ===== v404 · 游客资料占位符（名字 / 标签）=====
   仅当元素是 contenteditable 且带 data-ph 时生效；这些属性只在游客模式下由 JS 打上，
   主人模式（桌面 / 导出）不会出现，故对桌面与导出图零影响。 */
@media (max-width: 720px) {
  [contenteditable][data-ph]:empty::before {
    content: attr(data-ph);
    opacity: .45;
    pointer-events: none;
  }
}

/* ===== v406 · 2026-11-14 13:05 Danmi：主站网页不显示任何滚动条 =====
   桌面端截图上右侧那根带 ▲▼ 三角的灰色滚动条（= 浏览器视口滚动条）去掉。
   只隐藏「看得见的条」，滚轮 / 触屏 / 触控板滚动功能完全保留，页面高度与内容不变。
   桌面隐藏后视口多出约 15px 宽，卡片都是居中布局，版式不会变形；
   导出图走的是固定 1280 的离屏容器，不经过视口滚动条，故零影响。 */
html, body{
  scrollbar-width: none;          /* Firefox */
  -ms-overflow-style: none;       /* 老 Edge / IE */
}
html::-webkit-scrollbar, body::-webkit-scrollbar{
  width: 0 !important; height: 0 !important; display: none !important;
}
/* 页面内所有可滚动块（弹层列表 / 侧栏 / 表格）也一并去掉灰条，功能保留 */
*::-webkit-scrollbar{ width: 0 !important; height: 0 !important; display: none !important; }
*{ scrollbar-width: none; -ms-overflow-style: none; }

/* ===== v413 · 2026-11-14 13:26 Danmi：盲狙表底部空隙收一点 =====
   导出图底部 = .tool-page 的 padding-bottom(30) + 水印(6+10+12) + wrap 底边(16)，
   一共 74px，看着空。这里只把「盲狙表页」的 30 收到 16（少 14px，→ 60px），
   其他工具页（角色印象等）一点不动。 */
.tool-page.bpl-page { padding-bottom: 16px; }

/* ===== v418 · 2026-11-14 13:36 Danmi：网页「透透的能看清字」，导出图「空心实线框」 =====
   同一份 CSS 要管两个场合，靠作用域分开：
   · 网页（.tool-page 正常在页面里）→ 上面 .bpl-labels span 那套：半透明白 + 磨砂
   · 导出图 → repo_tools.js 的 build() 会给离屏截图容器加 .gd-export-snap 类，
     这里用更高特异性把磨砂/白底/阴影全部覆盖成「透明底 + 一条实线框」。
   html2canvas 不支持 backdrop-filter，所以导出必须走实线框这条路才看得见边界。 */
.gd-export-snap .bpl-labels span {
  background: transparent !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  border: 1.5px solid #b9d3bd !important;   /* v418：Danmi「外框再稍微粗一点」1 → 1.5px */
  box-shadow: none !important;
  text-shadow: none !important;
}

/* ===== v424 · 2026-11-14 15:35 Danmi：分线评价「人设/剧情」变并排 + 字号加大 =====
   这两个选择器手机端没有覆盖规则，直接改基础规则会把手机一起带走
   （Danmi 要求手机端排布/尺寸保持原样），所以整块包在 min-width:721 里，
   ≤720 仍是原来的上下两行 + 15px（那段在 3163 行的 .works-page 块里）。 */
@media (min-width: 721px) {
  .route-scores { flex-direction: row; flex-wrap: wrap; gap: 2px 18px; }
  .score { font-size: 19px; }                                  /* 15 → 17(v424) → 19(v425) */
  .score-sel, .score-free { font-size: 19px; width: 50px; }    /* 宽度随字号放宽，手输切换时位置仍对得上 */
  .score-k, .score-max { letter-spacing: .5px; }
}

/* ===== v425 · 2026-11-14 Danmi：初印象/现印象标签再大一点 =====
   同样只放桌面，手机端 3156 行的 .works-page .imp-label:13px 保持原样。 */
@media (min-width: 721px) {
  .imp-label { font-size: 18px; }   /* 16 → 18 */
}

/* ===== v426（靠左）已按 Danmi 15:57 要求整块回退，v428 起四个标题恢复居中 =====
   若要恢复：在文件末尾加
   @media (min-width: 721px) { .rp-head.center { justify-content: flex-start; } } */

/* ===== v435 · 2026-11-14 Danmi：手机长按别再弹「查看图片/保存图片/复制图片/分享图片」 =====
   那个菜单是安卓浏览器自己弹的，跟我们的代码无关：只要长按命中的是 <img>，系统就接管。
   三层一起上：
   ① 全站图片禁掉长按呼出（iOS 的 -webkit-touch-callout）与图片拖拽、选中；
   ② 纯触屏设备（手机/平板，hover:none）让 img 不接收指针事件 —— 长按落到父容器，
      系统就认不出这是图片，菜单根本不会弹；各页的 click 都绑在父容器或 <a> 上，
      点击行为不变。桌面上 hover 成立，鼠标 hover / 右键 / 拖图完全不受影响；
   ③ 盲狙表整块禁掉长按选字，420ms 长按只留给拖动。 */
img {
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
  -webkit-user-select: none;
  user-select: none;
}
@media (hover: none) {
  img { pointer-events: none; }
}
.bpl-list, .bpl-row, .bpl-box, .bpl-cover, .bpl-covwrap {
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

/* ===== v436 · 2026-11-14 Danmi：角色格改成背景图（根治手机长按弹系统图片菜单） =====
   v435 的 pointer-events:none 在部分国产浏览器上仍会被长按识别成图片，所以直接把
   <img> 元素去掉，改用 background-image —— 页面上不再有图片元素，系统无从接管。
   下面两条等价于原来的 .bpl-box img { object-fit:cover; object-position:50% 18% }；
   导出时 snap() 的 bakeBackgrounds 会把 cover 背景按 3 倍烘成位图，清晰度不变。 */
.bpl-box.filled {
  background-size: cover;
  background-position: 50% 18%;
  background-repeat: no-repeat;
}

/* v437：角色格上再铺一层空元素当「挡板」——长按命中的是这块没有内容、没有背景的 i，
   浏览器无法把它识别成图片。点击照常冒泡到 .bpl-box（换角色），拖动照常命中整行。 */
.bpl-shield {
  position: absolute; inset: 0; display: block;
  border-radius: inherit;
  background: transparent;
}

/* ===== v450 · 2026-11-14 Danmi 草图：手机端「点一下 → 一整块纸面选择面板」 =====
   电脑上那种贴边浮层（.rp-pop）和悬浮的 1·2 / 大·小 胶囊只该在电脑上出现；
   手机上点奖项格 / 角色框 / 作品卡带，弹的是这一整块：标题 + 副标题 + 列表 + 取消/确定。
   组件在 repo_tools.js 的 RepoSheet 里生成，只有 ≤720 才会被调用。 */
@media (max-width: 720px) {
  /* 桌面那两套「12 / 大小」胶囊，手机上一律不出现（改用面板里的 ① ② 决定大小） */
  .bpl-count,
  .bpl-size-pill,
  .award-box .award-mode { display: none !important; }

  .rs-mask {
    position: fixed; inset: 0; z-index: 9000;
    display: flex; align-items: stretch; justify-content: center;
    /* v452：顶部留 8vh，弹层起始位置往下压 —— 她说"初始低一点"，一打开不用抬头 */
    padding: 8vh 12px 12px;
    background: rgba(58, 78, 56, .30);
    -webkit-backdrop-filter: blur(1.5px);
    backdrop-filter: blur(1.5px);
  }
  .rs-card {
    width: 100%; max-width: 460px;
    display: flex; flex-direction: column;
    background: #fdfefb;
    border: 1.5px solid rgba(122, 160, 91, .45);
    border-radius: 18px;
    box-shadow: 0 12px 34px rgba(64, 92, 56, .22);
    overflow: hidden;
  }
  .rs-head {
    padding: 13px 16px 10px; text-align: center;
    border-bottom: 1px solid rgba(122, 160, 91, .24);
    background: #fbfdf7;
  }
  .rs-title {
    font-family: 'FZ YaoTi', 'LXGW WenKai Screen', serif;
    font-size: 25px; line-height: 1.25; letter-spacing: 2px;
    color: var(--green-dark);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  }
  .rs-sub {
    margin-top: 4px;
    font-size: 12.5px; line-height: 1.4; letter-spacing: .5px;
    color: #98ae8c;
  }
  .rs-search { padding: 10px 14px 0; }
  .rs-search input {
    width: 100%; box-sizing: border-box; height: 38px; padding: 0 14px;
    border: 1px solid #cfe0c6; border-radius: 999px;
    background: #fff; color: var(--text);
    font-family: inherit; font-size: 14px;
  }
  .rs-search input:focus {
    outline: none; border-color: #9fc48f;
    box-shadow: 0 0 0 3px rgba(120, 180, 140, .16);
  }
  .rs-list {
    flex: 1 1 auto; min-height: 0;
    overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
    padding: 12px 14px 8px;
    display: flex; flex-direction: column; gap: 9px;
  }
  .rs-row {
    display: flex; align-items: center; gap: 10px; width: 100%;
    box-sizing: border-box;   /* v451：不加这个，加上「大/小」胶囊后右侧序号会被挤出卡片 */
    padding: 5px 10px 5px 5px; border-radius: 12px;
    border: 1px solid #dde8d4; background: #fff;
    font-family: inherit; text-align: left; cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .rs-row.on { border-color: #86b673; background: #f4fbee; }
  .rs-thumb {
    /* v452：48 → 58，参考她给的图，缩略图更大更好认 */
    flex: 0 0 auto; width: 58px; height: 58px; border-radius: 10px;
    background: #f3f6ec center / cover no-repeat;
    border: 1px solid #e3ecd9;
  }
  .rs-row.on .rs-thumb { border-color: #cfe4c2; }
  .rs-names { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
  .rs-name {
    font-size: 15px; line-height: 1.3; color: var(--text);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  }
  .rs-sub2 {
    font-size: 11.5px; line-height: 1.3; color: #a6b89c;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  }
  /* 右侧标记：单选 ✓，多选 ① ②（数字按点击顺序，1 就画 1） */
  .rs-mark {
    flex: 0 0 auto; width: 27px; height: 27px; border-radius: 999px;
    display: flex; align-items: center; justify-content: center;
    border: 1.5px solid rgba(122, 160, 91, .40);
    font-family: 'LXGW WenKai Screen', serif; font-size: 14px; line-height: 1;
    color: #86b673; opacity: 0;
  }
  .rs-row.on .rs-mark { opacity: 1; background: #eaf7e1; border-color: #86b673; }
  .rs-empty { padding: 30px 0; text-align: center; font-size: 13px; color: var(--muted); opacity: .7; }
  .rs-foot {
    display: flex; gap: 12px;
    padding: 10px 16px 14px;
    border-top: 1px solid rgba(122, 160, 91, .20);
    background: #fbfdf7;
  }
  .rs-btn {
    flex: 1 1 0; height: 42px; border-radius: 999px;
    font-family: inherit; font-size: 15px; letter-spacing: 2px;
    cursor: pointer; -webkit-tap-highlight-color: transparent;
  }
  .rs-cancel { background: #fff; border: 1px solid #cfe0c6; color: #7d9670; }
  .rs-ok { background: var(--green-dark); border: 1px solid var(--green-dark); color: #fff; }
}

/* ===== v451 · 盲狙表「大 / 小」可选（Danmi 2026-11-14） =====
   手机上每个已选角色右侧多一个小胶囊「大 | 小」，点一下只改这一个人，
   别人不动 —— 所以「两个都大」「一大一小」「两个都小」都能选出来。
   默认值仍是草图那套：① 大、② 小。桌面不受影响（.rs-* 只在手机弹层里出现）。 */
@media (max-width: 720px) {
  .rs-size {
    flex: 0 0 auto;
    display: flex; align-items: center;
    height: 27px; box-sizing: border-box;
    border: 1.5px solid rgba(122, 160, 91, .40);
    border-radius: 999px; overflow: hidden;
    background: #fff;
  }
  .rs-size b {
    width: 25px; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-family: 'LXGW WenKai Screen', serif;
    font-size: 13px; font-weight: 400; line-height: 1;
    color: #86b673; cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .rs-size b.on { background: #86b673; color: #fff; }
  /* 已选行元素变多，名字别被挤到没宽度 */
  .rs-row.on .rs-names { min-width: 44px; }
}

/* ===== v453 · 弹层再往下 + 标题收小 + 底部按钮瘦身（Danmi 2026-11-14 21:02）=====
   她说"再低一点，上面的字再小多一点，下面的按钮再小一点瘦一点"：
   · 卡片起始 8vh → 12vh
   · 标题 25 → 20px（姚体，字距收一点），副标题 12.5 → 11.5，头部上下留白一起收
   · 底部两键：高度 42 → 34、字号 15 → 13.5、不再各占一半，改成固定宽居中 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 12vh; }

  .rs-head { padding: 10px 16px 8px; }
  .rs-title { font-size: 20px; letter-spacing: 1.5px; }
  .rs-sub { margin-top: 3px; font-size: 11.5px; letter-spacing: .3px; }

  .rs-foot {
    justify-content: center; gap: 14px;
    padding: 8px 16px 11px;
  }
  .rs-btn {
    flex: 0 0 auto; width: 38%; max-width: 132px;
    height: 34px; font-size: 13.5px; letter-spacing: 1px;
  }
}

/* ===== v454 · 弹层再下一档 + 头部字再收小（Danmi 2026-11-14 21:14）=====
   她说"再整体往下，上面文字再小一点"：
   · 卡片起始 12vh → 16vh（844 高手机上顶部再让出约 34px）
   · 标题 20 → 17px、副标题 11.5 → 10.5px，头部上下留白再压
   列表行、缩略图、大/小胶囊、底部按钮尺寸都不动。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 16vh; }
  .rs-head { padding: 8px 16px 7px; }
  .rs-title { font-size: 17px; letter-spacing: 1px; }
  .rs-sub { margin-top: 2px; font-size: 10.5px; letter-spacing: .2px; }
}

/* ===== v455 · 弹层再下压（Danmi 2026-11-14 21:16「再低一点」）=====
   卡片起始 16vh → 21vh（844 高屏上顶部再让出约 42px，落到 y≈177）。
   其余（标题 17px、副标题 10.5px、行高 70、缩略图 58、按钮 34px）一律不动。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 21vh; }
}

/* ===== v456 · 卡片顶对齐屏幕中线稍上（Danmi 2026-11-14 21:17）=====
   她说"就是到屏幕二分之一的上面一点"→ 顶部留白 21vh → 46vh（中线 50vh 稍上）。
   卡片变矮后列表靠 .rs-list 自身滚动，行高/缩略图/按钮尺寸仍不动。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 46vh; padding-bottom: 10px; }
}

/* ===== v456b · 卡片变矮后的列表适配（同 v456，2026-11-14 21:18）=====
   卡片顶到中线稍上后可视高度只有 ~430px，6 个人放不下 → 列表自己滚。
   这里只做两件事，让人察觉"还能往下滑"、且半截行不那么突兀：
   · 行高 70 → 66（上下 padding 6→4，缩略图 58 不变）
   · 列表底部 18px 渐隐遮罩 */
@media (max-width: 720px) {
  .rs-row { padding: 4px 10px 4px 4px; }
  .rs-list {
    padding-bottom: 12px;
    -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 18px), transparent);
    mask-image: linear-gradient(to bottom, #000 calc(100% - 18px), transparent);
  }
}

/* ===== v457 · 卡片顶到屏幕 2/3 处（Danmi 2026-11-14 21:19「屏幕三分之二的地方」）=====
   46vh → 66vh：面板落在屏幕下方 1/3，只有 ~270px 高，列表靠滚动看。
   为了多露出行，头部再压一点（标题/副标题字号不动）。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 66vh; }
  .rs-head { padding: 6px 14px 5px; }
}

/* ===== v458 · 修正：卡片高度占屏幕 2/3（Danmi 2026-11-14 21:2x「不是，我指的是高一点」）=====
   上一版把"屏幕三分之二"读成了"卡片顶到 2/3 处"（66vh）→ 卡片太矮。
   她的意思是卡片本身高约 2/3 屏 → 顶部留白 66vh → 34vh（卡片顶 y≈287，高 ≈547px，一屏能看 6 行）。
   头部 padding 恢复 8/16/7。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 34vh; }
  .rs-head { padding: 8px 16px 7px; }
}

/* ===== v459 · 卡片再高一点（Danmi 2026-11-14 21:21「再高一点」）=====
   34vh → 28vh：卡片顶 y≈287→236，高 ≈600px（约 71% 屏），6 个角色可以一屏放全。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 28vh; }
}

/* ===== v460 · 卡片再高（Danmi 2026-11-14 21:22「再高一点」）=====
   28vh → 24vh：卡片顶 y≈236→203，高 ≈631px（约 75% 屏）。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 24vh; }
}

/* ===== v461 · 卡片再高（Danmi 2026-11-14 21:24「再高一点」）=====
   24vh → 18vh：卡片顶 y≈203→152，高 ≈682px（约 81% 屏）。 */
@media (max-width: 720px) {
  .rs-mask { padding-top: 18vh; }
}

/* ===== v466 · 手机端盲狙表三处收紧（Danmi 2026-11-14 21:53）=====
   截图三个框的意见：
   ① 红框：标题「⚝ 盲狙表 ⚝」下面到「作品/盲狙/实际喜欢」之间空太大 → 收紧
   ② 绿框：右上翻页器 ◀ 1 ▶ 整体变小
   ③ 黄框：盲狙 / 实际喜欢 两列里的人像图变大
   全部只在 ≤720 生效：桌面排版、导出成品图（1280 走桌面那套）一像素不变。 */
@media (max-width: 720px) {
  /* ① 标题下空白。姚体标题行高 ≈2.95em（导出图几何守恒要求），手机端收一档；
        标题与标签之间也压紧（原 padding 6 + margin 14）。 */
  .bpl-head { margin-bottom: 10px; padding-bottom: 4px; }
  .bpl-head .rp-cap { line-height: 1.4; }

  /* ② 翻页器整体收小（原按钮 24×24 / 页码 26×26、字号 12/13、gap 6） */
  .bpl-pager { gap: 4px; }
  .bpl-pager button { width: 19px; height: 19px; border-radius: 5px; font-size: 10px; }
  .bpl-pager b { min-width: 21px; height: 21px; padding: 0 3px; border-radius: 3px; font-size: 11px; }

  /* ③ 图变大：先把列间距 7→4、作品列 82→78 把横向空间让出来（视觉几乎不变），
        框内 padding 3→2、两格缝 6→4，让图撑到列宽上限：大 58→63、小 50→56。
        这同时把框内上下空白从 11px 压到 ~5px，图看着更满。 */
  .bpl-labels, .bpl-row { grid-template-columns: 78px minmax(0, 1fr) minmax(0, 1.02fr); gap: 4px; }
  .bpl-cover { width: 78px; height: 78px; }
  .bpl-pick, .bpl-like { padding: 2px; }
  .bpl-boxes { gap: 4px; }
  .bpl-cell { max-width: calc((100% - 4px) / 2); }
  .sz-大 { --s: 63px; }
  .sz-小 { --s: 56px; }
}

/* ===== v467 · 手机端盲狙表微调（Danmi 2026-11-14 21:58）=====
   ① 红框：v466 把标题下空白收到 19px 她说"有点挤"，放回 24px（只松一点点）
   ② 绿框：翻页器的页码框原来是淡绿描边 + 绿字，改成瑰红色系（描边浅瑰红、数字深瑰红）
   仍然只在 ≤720 生效，桌面与导出成品图不受影响。 */
@media (max-width: 720px) {
  .bpl-head { margin-bottom: 15px; }

  .bpl-pager b {
    border-color: #cd8b99;
    color: #9e5b6a;
  }
}

/* ===== v468 · 页码框描边/数字 = 翻页箭头同一个颜色（Danmi 2026-11-14 22:01）=====
   她发箭头截图说"框框颜色就和左边那个箭头一样"。
   箭头（.bpl-pager button）用的是 var(--green-dark)，所以这里**也用同一个变量**，
   而不是写死一个色号 —— 她手机上那套绿色会被显示成藕玫瑰色（截图里标题/箭头都偏藕），
   用同一个值才能保证两者在她屏幕上永远一模一样。
   仍只在 ≤720 生效；桌面浮层与导出图不受影响。 */
@media (max-width: 720px) {
  .bpl-pager b {
    border-color: var(--green-dark);
    color: var(--green-dark);
  }
}


/* ============================================================
   v506 清单（Danmi 2026-11-16 定稿）
   「我的」页「使用说明」下面一行 → 点开和食用说明同款遮罩卡片。
   数据存 GuestStore.data().checklist / checklistLogs（导出整包自动带上）。
   本块是清单的全部样式，集中一处，别再分散改。
   ============================================================ */
.me-cl-mask{ position:fixed; inset:0; z-index:2147483100; background:rgba(70,55,52,.30);
  display:flex; align-items:center; justify-content:center; padding:16px; touch-action:none; }
.me-cl-mask[hidden]{ display:none; }
.me-cl{ box-sizing:border-box; width:min(520px,100%); height:76vh; background:#fffdfc;
  border:1.3px solid #e7d3cd; border-radius:16px; box-shadow:0 14px 44px rgba(93,74,71,.20);
  display:flex; flex-direction:column; padding:18px 8px 14px; text-align:center; }
.me-cl-t{ margin:0; font-size:16px; letter-spacing:2px; color:#5b4a45; }
.me-cl-hint{ font-size:10px; color:#ac9d98; margin:6px 0 0; line-height:1.5; }
.me-cl-lists{ flex:1 1 auto; min-height:0; overflow-y:auto; overscroll-behavior:contain; padding:8px 0 4px; text-align:left; }
.me-cl-row{ position:relative; box-sizing:border-box; width:100%; max-width:100%;
  margin:0 auto 8px; border:1.3px solid #e7d3cd; border-radius:12px;
  background:rgba(255,255,255,.85); padding:10px 9px 3px; }
.me-cl-row.done{ background:rgba(157,111,104,.07); border-color:#e0d0ca; }
.me-cl-row.done .me-cl-top{ opacity:.55; }
.me-cl-del{ position:absolute; left:4px; top:3px; width:11px; height:11px; border-radius:50%;
  border:1px solid #e8d8d3; background:#fff; color:#9d6f68; font-size:10px; line-height:1;
  cursor:pointer; padding:0; z-index:2; font-family:Arial,sans-serif; }
.me-cl-top{ display:flex; align-items:center; gap:4px; min-width:0; }
.me-cl-first{ flex:0 1 72px; min-width:36px; font-size:11px; color:#9d6f68;
  padding:5px 2px; cursor:text; text-align:center; line-height:1.25; word-break:break-all;
  display:flex; align-items:center; justify-content:center; }
.me-cl-cell{ flex:1 1 0; min-width:0; max-width:100%; text-align:center; }
.me-cl-dd{ border:1px solid #e8d8d3; border-radius:8px; background:#fff; color:#5b4a45;
  font-family:inherit; font-size:11px; padding:5px 4px; cursor:pointer; width:100%;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis; text-align:center; line-height:1.3; }
.me-cl-menu{ position:fixed; z-index:2147483200; background:#fffdfc; border:1px solid #c9a39b;
  border-radius:12px; box-shadow:0 8px 26px rgba(90,60,55,.22); padding:5px;
  min-width:104px; max-height:250px; overflow-y:auto; }
.me-cl-item{ padding:7px 11px; font-size:11px; color:#5b4a45; border-radius:8px;
  cursor:pointer; white-space:nowrap; text-align:center; }
.me-cl-item.sel{ background:#f7ece9; color:#9d6f68; }
.me-cl-note{ font-size:9px; color:#a2918c; line-height:1.35; margin-top:4px; cursor:text;
  min-height:13px; word-break:break-all; text-align:center; outline:none; border-radius:5px; padding:1px 2px; }
.me-cl-note:hover{ background:#fdf4f2; }
.me-cl-ck{ width:9px; height:9px; border:1px solid #c9a39b; border-radius:50%;
  background:#fff; color:#9d6f68; font-size:6px; cursor:pointer; padding:0; flex:none;
  display:flex; align-items:center; justify-content:center;
  align-self:center; margin-top:0; }
.me-cl-add{ display:flex; gap:7px; margin:6px 0 10px; align-items:center; }
.me-cl-input{ flex:1; min-width:0; border:1px solid #e8d8d3; background:#fff; border-radius:10px;
  padding:7px 10px; font-family:inherit; font-size:11px; color:#5b4a45; outline:none; }
.me-cl-foot{ display:flex; justify-content:space-between; align-items:center; padding-top:4px; }
.me-cl-add button, .me-cl-foot button, #meClLogBack, #meClLogClear{
  min-width:74px; border:1.3px solid #d9b9b2; background:#fdf4f2; border-radius:999px;
  color:#bd7777; font-size:11px; padding:6px 16px; cursor:pointer; font-family:inherit; }
.me-cl-add button:active, .me-cl-foot button:active, #meClLogBack:active, #meClLogClear:active{ background:#fbe9e5; }
.me-cl-log{ position:absolute; inset:18px 14px 14px; background:#fffdfc; border-radius:18px;
  z-index:3; display:none; flex-direction:column; padding:16px; text-align:left; }
.me-cl-log.on{ display:flex; }
.me-cl-log h3{ margin:0 0 12px; text-align:center; font-size:15px; color:#5b4a45; letter-spacing:2px; }
.me-cl-loglist{ flex:1 1 auto; overflow-y:auto; font-size:11px; color:#7f6f69; line-height:1.9; }
.me-cl-loglist div{ border-bottom:1px dashed #eee2de; padding:5px 0; display:flex; gap:6px; align-items:baseline; }
.me-cl-loglist span{ flex:1; }
.me-cl-mini{ border:1px solid #e8d8d3; background:#fff; color:#9d6f68; border-radius:6px;
  font-size:10px; padding:2px 6px; cursor:pointer; font-family:inherit; }
/* 弹层打开时锁背景。★ 必须连 html 一起锁：
   手机窄屏块里有 html,body{overflow-x:hidden}，它把滚动容器推到了 html 上
   （document.scrollingElement === HTML），只锁 body 等于没锁，
   列表内容没溢出时手势会一路穿透到 html → 背景跟着滚。
   JS 里给 html 和 body 同时 toggle('cl-open')。 */
html.cl-open, body.cl-open{ overflow:hidden; }

/* ================= v521：手机端日期 / 分数「自绘下拉」 =================
   原生 select 点开弹的是安卓 WebView 自己的列表（整屏白底、字巨大），
   字号配色归系统管，网页改不了。所以 ≤720 时由 static/gdselect.js 拦掉，
   改画下面这个小弹层。皮肤沿用清单弹层 .me-cl-menu 那套，不新起风格。
   电脑端（含导出 1280 视口）不创建这个元素，继续用浏览器原生下拉。 */
.gd-sel-menu{
  position:fixed; z-index:2147483100; background:#fffdfc;
  border:1px solid #c9a39b; border-radius:12px;
  box-shadow:0 8px 26px rgba(90,60,55,.22); padding:5px;
  min-width:86px; max-width:64vw; max-height:224px; overflow-y:auto;
  scrollbar-width:none; -webkit-overflow-scrolling:touch;
}
.gd-sel-menu::-webkit-scrollbar{ width:0; height:0; }
.gd-sel-item{
  padding:6px 14px; font-size:12px; color:#5b4a45; border-radius:8px;
  cursor:pointer; white-space:nowrap; text-align:center; line-height:1.55;
  -webkit-tap-highlight-color:transparent;
}
.gd-sel-item.sel{ background:#f7ece9; color:#9d6f68; }
/* 「编辑」置顶，下面拉一条虚线跟数字档位分开 */
.gd-sel-item.edit{
  color:#b08a83; font-size:11px; border-bottom:1px dashed #eee2de;
  border-radius:8px 8px 0 0; margin-bottom:3px; padding-bottom:8px;
}

/* 记录弹层底部：「清空全部」跟「返回」并排，红色系对应删除语义 */
#meClLogClear{
  border-color:#dcb0a8; background:#fdf0ee; color:#c06a63;
}
#meClLogClear:active{ background:#fbe3df; }
.me-cl-logfoot{ display:flex; justify-content:center; gap:10px; padding-top:10px; }

/* 手机上让这两个 select 彻底收不到点击，避免原生大列表抢在前面弹出来。
   点击会穿透到父元素，由 gdselect.js 按坐标认出是哪个 select，再画自己的弹层。
   只在 ≤720 生效 —— 电脑端（含导出 1280 视口）这条规则完全不进，原生下拉照旧。 */
@media (max-width:720px){
  select.numsel, select.score-sel{ pointer-events:none; }
}
