/* ============================================================
   校园动物图鉴 · Web 版组件样式
   与 miniprogram 各页 wxss 一一对应，图标 / 植物全部纯 CSS 绘制
   ============================================================ */

/* ---------------- 顶栏 ---------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 600;
  height: var(--top-h);
  display: flex;
  align-items: center;
  padding: 0 14px;
  background: rgba(251, 244, 232, 0.94);
  backdrop-filter: saturate(1.1) blur(8px);
  -webkit-backdrop-filter: saturate(1.1) blur(8px);
  border-bottom: 1px solid rgba(216, 199, 174, 0.55);
}
.topbar.is-hidden { display: none; }
.tb-back {
  flex: 0 0 auto;
  width: 30px; height: 30px;
  margin-right: 4px;
  border: none; background: transparent;
  padding: 0; cursor: pointer;
  position: relative;
}
.tb-back::before {
  content: '';
  position: absolute; left: 8px; top: 9px;
  width: 11px; height: 11px;
  border-left: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  transform: rotate(45deg);
  opacity: 0.7;
}
.tb-title {
  flex: 1;
  min-width: 0;
  font-family: var(--font-hand);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.tb-act {
  flex: 0 0 auto;
  font-size: 13px;
  color: #7A5C2B;
  border: 1.5px solid rgba(216, 199, 174, 0.9);
  background: var(--spirit);
  border-radius: var(--r-pill);
  padding: 5px 14px;
  cursor: pointer;
  letter-spacing: 1px;
}
.tb-logo {
  flex: 1;
  font-family: var(--font-hand);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 3px;
}
.tb-logo small {
  display: block;
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 1px;
  color: #A08C75;
  margin-top: 1px;
}
.tb-paw {
  position: relative;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: #F1E3C2;
  border: 1.5px solid rgba(216, 199, 174, 0.9);
  flex: 0 0 34px;
  cursor: pointer;
}
.tb-paw .pad {
  position: absolute; left: 50%; bottom: 7px;
  width: 17px; height: 14px; margin-left: -8.5px;
  background: #A8926F; opacity: 0.78;
  border-radius: 50% 50% 46% 46% / 56% 56% 44% 44%;
}
.tb-paw .toe {
  position: absolute;
  width: 6.5px; height: 8px;
  background: #A8926F; opacity: 0.78;
  border-radius: 50%;
}
.tb-paw .t1 { left: 5px; top: 9px; transform: rotate(-18deg); }
.tb-paw .t2 { left: 12px; top: 6px; }
.tb-paw .t3 { left: 20px; top: 6px; }
.tb-paw .t4 { left: 27px; top: 9px; transform: rotate(18deg); }

/* ---------------- 搜索 ---------------- */
.search {
  display: flex;
  align-items: center;
  margin: 14px 20px 0;
  height: 42px;
  padding: 0 13px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.85);
  border-radius: 999px;
  box-shadow: 0 2px 0 rgba(74, 59, 47, 0.04);
}
.search-ico {
  position: relative;
  width: 15px; height: 15px;
  border: 2px solid #C0AC92;
  border-radius: 50%;
  margin-right: 8px;
  flex: 0 0 15px;
}
.search-ico::after {
  content: '';
  position: absolute; right: -5px; bottom: -3px;
  width: 7px; height: 2px;
  background: #C0AC92;
  border-radius: 2px;
  transform: rotate(45deg);
}
.search input {
  flex: 1;
  min-width: 0;
  border: none; outline: none; background: transparent;
  font-size: 13px;
  color: var(--ink);
}
.search input::placeholder { color: #BFAE98; }

/* ---------------- 两个榜 ---------------- */
.ranks {
  display: flex;
  align-items: flex-start;
  padding: 18px 20px 0;
}
.rank-card {
  position: relative;
  flex: 1;
  padding: 13px 12px 15px;
  border-radius: 13px 16px 12px 15px / 15px 12px 16px 13px;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
  -webkit-tap-highlight-color: transparent;
}
.rank-spirit {
  background: #F6E9C9;
  border: 1.5px solid #E4CE9A;
  transform: rotate(-2.4deg);
  margin-right: 11px;
  box-shadow: 0 3px 0 rgba(190, 163, 108, 0.18);
}
.rank-mischief {
  background: #CFD8C3;
  border: 1.5px solid #B9C6AC;
  transform: rotate(1.8deg);
  box-shadow: 0 3px 0 rgba(140, 152, 126, 0.2);
}
.rank-card.on {
  transform: rotate(0deg) translateY(-3px);
  box-shadow: 0 5px 0 rgba(120, 100, 72, 0.22);
  border-width: 2.5px;
}
.rank-title {
  display: block;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 3px;
  font-family: var(--font-hand);
  color: var(--ink);
}
.rank-emoji { font-size: 13px; margin-left: 2px; opacity: 0.7; }
.rank-desc {
  display: block;
  font-size: 10.5px;
  color: var(--ink-2);
  letter-spacing: 1px;
  margin-top: 5px;
}
.rank-mark { display: flex; align-items: center; margin-top: 7px; }
.mark-line {
  width: 20px; height: 2px;
  background: rgba(140, 123, 107, 0.45);
  border-radius: 2px;
  margin-right: 5px;
}
.mark-line.short { width: 11px; }

/* ---------------- 分区标题 ---------------- */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 22px 20px 9px;
}

/* ---------------- 列表 ---------------- */
.list { padding: 0 16px; }

.skeleton {
  height: 84px;
  border-radius: 15px;
  background: linear-gradient(90deg, #F5ECDC 25%, #FBF4E8 37%, #F5ECDC 63%);
  background-size: 400% 100%;
  animation: shimmer 1.3s ease infinite;
  margin-bottom: 11px;
}
@keyframes shimmer {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}

/* ---------------- 动物卡片 ---------------- */
.ac {
  display: flex;
  align-items: flex-start;
  padding: 13px 11px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.85);
  border-radius: 15px 17px 14px 16px / 16px 14px 17px 15px;
  box-shadow: 0 2.5px 0 rgba(74, 59, 47, 0.045);
  margin-bottom: 11px;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease;
  -webkit-tap-highlight-color: transparent;
}
.ac:active { transform: scale(0.988); background: #FFFBF2; }

.ac-avatar {
  position: relative;
  width: 58px; height: 58px;
  flex: 0 0 58px;
  border-radius: 13px 15px 12px 14px / 14px 12px 15px 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid rgba(74, 59, 47, 0.08);
  overflow: visible;
}
.tone-blue { background: #B3C9DA; }
.tone-mint { background: #A9CCBD; }
.tone-clay { background: #E3B7A4; }
.tone-apricot { background: #EDCFA2; }
.tone-spirit { background: #F1E3C2; }
.tone-sage { background: #C6D3BA; }

.ac-char {
  font-size: 27px;
  font-weight: 700;
  color: rgba(74, 59, 47, 0.72);
  font-family: var(--font-hand);
  line-height: 1;
}
.ac-avatar img {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 13px 15px 12px 14px / 14px 12px 15px 13px;
}
.ac-species {
  position: absolute;
  right: -4px; bottom: -4px;
  min-width: 18px; height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.9);
  font-size: 9.5px;
  color: var(--ink-2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.ac-body { flex: 1; min-width: 0; padding-left: 11px; }
.ac-name-row { display: flex; align-items: center; flex-wrap: wrap; }
.ac-name {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 1px;
  font-family: var(--font-hand);
  margin-right: 5px;
  color: var(--ink);
}
.ac-gender {
  font-size: 10.5px;
  color: #A08C75;
  border: 1px solid rgba(216, 199, 174, 0.9);
  border-radius: 4px;
  padding: 0 4px;
  margin-right: 5px;
  line-height: 1.6;
}
.ac-health {
  font-size: 9.5px;
  padding: 1px 5px;
  border-radius: 999px;
  line-height: 1.7;
}
.ac-health-watch { background: #F4E3C3; color: #9A6E29; }
.ac-health-sick { background: #F3D6CD; color: #A85C47; }
.ac-health-urgent { background: #EEC3B8; color: #96382A; }

.ac-tags { display: flex; flex-wrap: wrap; margin-top: 6px; }
.ac-pill {
  font-size: 10.5px;
  color: #7E6C58;
  background: #F3EAD9;
  border: 1px solid rgba(216, 199, 174, 0.75);
  border-radius: 6px 8px 5px 7px;
  padding: 1.5px 7px;
  margin: 0 5px 4px 0;
  line-height: 1.55;
}
.ac-pill-empty { color: var(--ink-3); background: transparent; border-style: dashed; }

.ac-meta { display: flex; align-items: center; margin-top: 2px; }
.ac-dot {
  width: 4px; height: 4px;
  border-radius: 50%;
  background: #C8B69C;
  margin-right: 4px;
  flex: 0 0 4px;
}
.ac-meta-text { font-size: 10.5px; color: #A08C75; letter-spacing: 0.5px; }

/* 手绘小草（纯 CSS） */
.ac-plant { position: relative; width: 20px; height: 13px; margin-left: 6px; flex: 0 0 20px; }
.leaf {
  position: absolute;
  width: 7px; height: 11px;
  background: #9CAC7C;
  border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  opacity: 0.85;
}
.leaf-1 { left: 1px; top: 3px; transform: rotate(-26deg); height: 9px; }
.leaf-2 { left: 7px; top: 0; transform: rotate(4deg); }
.leaf-3 { left: 12px; top: 4px; transform: rotate(28deg); height: 8px; opacity: 0.7; }

.ac-right {
  flex: 0 0 54px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding-top: 3px;
}
.ac-score {
  font-family: var(--font-num);
  font-size: 23px;
  font-weight: 700;
  color: #5C4535;
  line-height: 1.1;
}
.ac-score-unit { font-size: 9.5px; color: var(--ink-3); margin-top: 2px; }

/* ---------------- 表单 ---------------- */
.form-page { padding: 12px 14px 40px; }
.form { padding: 6px 13px 13px; margin-bottom: 12px; }
.field { padding: 11px 0; border-bottom: 1px dashed rgba(216, 199, 174, 0.7); }
.field:last-child { border-bottom: none; }
.label {
  display: block;
  font-size: 12.5px;
  color: #6F5F4E;
  letter-spacing: 1px;
  margin-bottom: 7px;
  font-weight: 600;
}
.label-row { display: flex; align-items: baseline; justify-content: space-between; }
.req { color: var(--danger); margin-left: 2px; }
.input, .textarea {
  width: 100%;
  font-size: 14px;
  color: var(--ink);
  background: var(--bg);
  border: 1.5px solid rgba(216, 199, 174, 0.75);
  border-radius: 8px 10px 7px 9px;
  padding: 0 10px;
  outline: none;
}
.input { height: 36px; }
.textarea { height: 85px; padding: 8px 10px; line-height: 1.6; resize: none; }
.input:focus, .textarea:focus { border-color: #DCC183; background: #FFFDF8; }
.input::placeholder, .textarea::placeholder { color: #C0AF99; font-size: 13px; }

select.input {
  appearance: none;
  -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #BFAE98 50%),
                    linear-gradient(135deg, #BFAE98 50%, transparent 50%);
  background-position: calc(100% - 16px) 16px, calc(100% - 11px) 16px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.chips { display: flex; align-items: center; flex-wrap: wrap; }
.chips-wrap { margin-top: 2px; }
.chip {
  min-width: 48px;
  padding: 6px 13px;
  margin: 0 8px 8px 0;
  text-align: center;
  font-size: 13.5px;
  color: #7E6C58;
  background: var(--bg);
  border: 1.5px solid rgba(216, 199, 174, 0.75);
  border-radius: 8px 10px 7px 9px;
  cursor: pointer;
  transition: all 0.12s ease;
  -webkit-tap-highlight-color: transparent;
}
.chip-sm {
  font-size: 11.5px;
  padding: 4px 9px;
  min-width: 0;
  margin: 0 6px 6px 0;
  border-radius: 6px 8px 5px 7px;
}
.chip.on {
  background: #F6E9C9;
  border-color: #DCC183;
  color: #7A5C2B;
  font-weight: 600;
  box-shadow: 0 1.5px 0 rgba(180, 150, 90, 0.22);
}

.score-slider { margin: 5px 2px 0; }
.score-slider input[type=range] {
  width: 100%;
  appearance: none; -webkit-appearance: none;
  height: 4px;
  background: linear-gradient(90deg, #E4CE9A, #B9C6AC);
  border-radius: 4px;
  outline: none;
}
.score-slider input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #FFFDF8;
  border: 2px solid #DCC183;
  box-shadow: 0 2px 0 rgba(180, 150, 90, 0.25);
  cursor: pointer;
}
.score-slider input[type=range]::-moz-range-thumb {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: #FFFDF8;
  border: 2px solid #DCC183;
  cursor: pointer;
}

/* 图片选择格子 */
.picker-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.picker-cell {
  position: relative;
  width: 72px; height: 72px;
  border-radius: 12px 14px 10px 13px;
  border: 1.5px dashed rgba(216, 199, 174, 0.9);
  background: var(--bg-soft);
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-3);
  font-size: 22px;
  cursor: pointer;
  overflow: hidden;
}
.picker-cell img { width: 100%; height: 100%; object-fit: cover; }
.picker-del {
  position: absolute; right: -4px; top: -4px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: rgba(74, 59, 47, 0.72);
  color: #FFF;
  font-size: 13px;
  line-height: 20px;
  text-align: center;
  cursor: pointer;
}

/* ---------------- 论坛 ---------------- */
.post {
  padding: 14px 15px;
  margin-bottom: 11px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.8);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
}
.post-head { display: flex; align-items: center; }
.post-ava {
  width: 30px; height: 30px;
  flex: 0 0 30px;
  border-radius: 9px 11px 8px 10px / 10px 8px 11px 9px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-hand);
  font-size: 15px; font-weight: 700;
  color: rgba(74, 59, 47, 0.72);
  margin-right: 9px;
}
.post-name { font-size: 13px; font-weight: 600; color: var(--ink); }
.post-time { font-size: 10.5px; color: var(--ink-3); margin-left: auto; }
.post-body { font-size: 13.5px; line-height: 1.65; margin-top: 8px; white-space: pre-wrap; word-break: break-word; }
.post-ref {
  display: inline-flex;
  align-items: center;
  margin-top: 8px;
  font-size: 11px;
  color: #7A5C2B;
  background: var(--spirit);
  border: 1px solid #E4CE9A;
  border-radius: 999px;
  padding: 2px 10px;
}
.post-imgs { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.post-imgs img {
  width: 96px; height: 96px;
  object-fit: cover;
  border-radius: 10px 12px 9px 11px;
  border: 1.5px solid rgba(216, 199, 174, 0.8);
}
.post-foot {
  display: flex; align-items: center; gap: 18px;
  margin-top: 10px;
  padding-top: 9px;
  border-top: 1px dashed rgba(216, 199, 174, 0.7);
}
.post-act {
  display: flex; align-items: center; gap: 5px;
  font-size: 12px; color: var(--ink-2);
  cursor: pointer;
  background: none; border: none; padding: 0;
  -webkit-tap-highlight-color: transparent;
}
.post-act .mini-ico { width: 14px; height: 14px; position: relative; display: inline-block; }
.mini-heart::before {
  content: '';
  position: absolute; left: 0; top: 3px;
  width: 8px; height: 8px;
  background: #C9A9A0;
  border-radius: 50% 50% 0 0;
  transform: rotate(-45deg);
}
.mini-heart::after {
  content: '';
  position: absolute; left: 6px; top: 3px;
  width: 8px; height: 8px;
  background: #C9A9A0;
  border-radius: 50% 50% 0 0;
  transform: rotate(45deg);
}
.post-act.on .mini-heart::before,
.post-act.on .mini-heart::after { background: #C4705C; }
.mini-comment::before {
  content: '';
  position: absolute; left: 0; top: 1px;
  width: 14px; height: 10px;
  border: 1.5px solid #BFAE98;
  border-radius: 6px 6px 5px 5px;
}
.mini-comment::after {
  content: '';
  position: absolute; left: 3px; bottom: 0;
  width: 6px; height: 6px;
  border-left: 1.5px solid #BFAE98;
  border-bottom: 1.5px solid #BFAE98;
  transform: rotate(-45deg);
}

.cm {
  display: flex;
  gap: 9px;
  padding: 10px 0;
  border-bottom: 1px dashed rgba(216, 199, 174, 0.55);
}
.cm:last-child { border-bottom: none; }
.cm-ava {
  width: 26px; height: 26px; flex: 0 0 26px;
  border-radius: 8px 10px 7px 9px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-hand);
  font-size: 13px; font-weight: 700;
  color: rgba(74, 59, 47, 0.72);
}
.cm-main { flex: 1; min-width: 0; }
.cm-name { font-size: 11.5px; color: var(--ink-2); }
.cm-text { font-size: 13px; line-height: 1.6; margin-top: 2px; word-break: break-word; }
.cm-time { font-size: 10px; color: var(--ink-3); margin-top: 3px; }

.comment-bar {
  position: sticky;
  bottom: calc(var(--bar-h) + env(safe-area-inset-bottom, 0px));
  display: flex; gap: 8px;
  padding: 8px 14px;
  background: rgba(251, 244, 232, 0.96);
  backdrop-filter: blur(6px);
  border-top: 1px solid rgba(216, 199, 174, 0.6);
  z-index: 500;
}
.comment-bar input {
  flex: 1; min-width: 0;
  height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1.5px solid rgba(216, 199, 174, 0.8);
  background: #FFFDF8;
  outline: none;
  font-size: 13px;
}
.comment-bar button {
  flex: 0 0 auto;
  height: 34px;
  padding: 0 16px;
  border-radius: 999px;
  border: none;
  background: var(--apricot);
  color: #5A4322;
  font-size: 13px; font-weight: 600;
  cursor: pointer;
}

/* ---------------- 救助 ---------------- */
.seg {
  display: flex;
  gap: 6px;
  padding: 12px 16px 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.seg::-webkit-scrollbar { display: none; }
.seg-item {
  flex: 0 0 auto;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 12.5px;
  color: var(--ink-2);
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.8);
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.seg-item.on { background: var(--spirit); color: #7A5C2B; border-color: #E4CE9A; font-weight: 600; }

.rsc {
  padding: 14px 15px;
  margin-bottom: 11px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.8);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.rsc-top { display: flex; align-items: center; gap: 8px; }
.rsc-lv {
  font-size: 10.5px;
  padding: 2px 8px;
  border-radius: 999px;
  flex: 0 0 auto;
}
.lv-watch { background: #F4E3C3; color: #9A6E29; }
.lv-sick { background: #F3D6CD; color: #A85C47; }
.lv-urgent { background: #EEC3B8; color: #96382A; }
.rsc-status {
  font-size: 10.5px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(216, 199, 174, 0.35);
  color: var(--ink-2);
  flex: 0 0 auto;
}
.st-open { background: #F6E9C9; color: #7A5C2B; }
.st-claimed { background: #CFD8C3; color: #4E5B45; }
.st-treating { background: #B3C9DA; color: #3F5568; }
.st-done { background: rgba(216, 199, 174, 0.4); color: #8C7B6B; }
.rsc-title { font-size: 14.5px; font-weight: 700; margin-top: 8px; line-height: 1.5; }
.rsc-desc { font-size: 12.5px; color: var(--ink-2); margin-top: 5px; line-height: 1.6; }
.rsc-meta { font-size: 10.5px; color: var(--ink-3); margin-top: 8px; display: flex; gap: 10px; flex-wrap: wrap; }

.timeline { padding: 4px 0; }
.tl-item { display: flex; gap: 10px; padding: 8px 0; }
.tl-dot {
  flex: 0 0 9px;
  width: 9px; height: 9px;
  margin-top: 5px;
  border-radius: 50%;
  background: #DCC183;
  border: 1.5px solid #FFFDF8;
  box-shadow: 0 0 0 1.5px #E4CE9A;
}
.tl-text { flex: 1; font-size: 12.5px; line-height: 1.6; }
.tl-time { font-size: 10px; color: var(--ink-3); margin-top: 2px; }

/* ---------------- 拍摄 ---------------- */
.cap-wrap { padding: 16px; }
.cap-stage {
  position: relative;
  height: 260px;
  border-radius: var(--r-card);
  border: 2px dashed rgba(216, 199, 174, 0.9);
  background: var(--bg-soft);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  overflow: hidden;
  gap: 10px;
}
.cap-stage img { width: 100%; height: 100%; object-fit: cover; }
.cap-hint { font-size: 12.5px; color: var(--ink-3); text-align: center; line-height: 1.8; padding: 0 24px; }
.cap-big {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--apricot);
  border: 3px solid #FFFDF8;
  box-shadow: 0 4px 0 rgba(184, 140, 74, 0.3);
}
.cap-scan {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(74, 59, 47, 0.42);
  color: #FFFDF8;
  font-size: 13px;
  letter-spacing: 1px;
}
.cap-dot { display: inline-block; animation: capPulse 1s ease-in-out infinite; }
@keyframes capPulse { 0%,100% { opacity: 0.3; } 50% { opacity: 1; } }

.ai-note {
  margin-top: 12px;
  padding: 12px 14px;
  background: var(--spirit);
  border: 1px solid #E4CE9A;
  border-radius: var(--r-card);
  font-size: 12.5px;
  color: #7A5C2B;
  line-height: 1.7;
}
.ai-note b { font-weight: 700; }

.cand {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  margin-bottom: 8px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.85);
  border-radius: var(--r-sm);
  cursor: pointer;
}
.cand-sim {
  flex: 0 0 auto;
  font-family: var(--font-num);
  font-size: 15px; font-weight: 700;
  color: #5C4535;
}

/* ---------------- 我的 ---------------- */
.me-head {
  padding: 18px 16px 14px;
  display: flex; align-items: center; gap: 14px;
}
.me-ava {
  width: 62px; height: 62px; flex: 0 0 62px;
  border-radius: 16px 19px 14px 17px / 17px 14px 19px 16px;
  background: var(--spirit);
  border: 1.5px solid #E4CE9A;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-hand);
  font-size: 28px; font-weight: 700; color: #7A5C2B;
}
.me-nick { font-family: var(--font-hand); font-size: 19px; font-weight: 700; letter-spacing: 1px; }
.me-role { font-size: 11px; color: var(--ink-2); margin-top: 3px; }

.coin-card {
  margin: 0 16px 12px;
  padding: 16px;
  background: linear-gradient(170deg, #F6E9C9 0%, #EFDDB4 100%);
  border: 1.5px solid #E4CE9A;
  border-radius: var(--r-card);
  box-shadow: 0 3px 0 rgba(190, 163, 108, 0.2);
}
.coin-num {
  font-family: var(--font-num);
  font-size: 40px; font-weight: 700;
  color: #5C4535; line-height: 1;
}
.coin-unit { font-size: 12px; color: #8A6C3C; margin-left: 6px; }
.coin-row { display: flex; align-items: baseline; margin-bottom: 12px; }
.coin-streak { margin-left: auto; font-size: 12px; color: #8A6C3C; }

.stat-grid { display: flex; margin: 0 16px 12px; gap: 10px; }
.stat {
  flex: 1;
  padding: 12px 8px;
  text-align: center;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.8);
  border-radius: var(--r-card);
}
.stat-num { font-family: var(--font-num); font-size: 20px; font-weight: 700; color: #5C4535; }
.stat-label { font-size: 10.5px; color: var(--ink-2); margin-top: 3px; }

.menu { margin: 0 16px; border-radius: var(--r-card); overflow: hidden; border: 1.5px solid rgba(216, 199, 174, 0.8); background: #FFFDF8; }
.menu-item {
  display: flex; align-items: center;
  padding: 14px 16px;
  border-bottom: 1px dashed rgba(216, 199, 174, 0.7);
  cursor: pointer;
  font-size: 14px;
  -webkit-tap-highlight-color: transparent;
}
.menu-item:last-child { border-bottom: none; }
.menu-item .arrow { margin-left: auto; color: var(--ink-3); font-size: 14px; }
.menu-item:active { background: #FFFBF2; }

/* ---------------- 底栏 ---------------- */
.tabbar {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  z-index: 900;
}
.tabbar-band {
  display: flex;
  align-items: flex-start;
  justify-content: space-around;
  height: var(--bar-h);
  padding: 0 4px;
  background: linear-gradient(180deg, #AEAE72 0%, #9C9D62 100%);
  border-top-left-radius: 22px 15px;
  border-top-right-radius: 22px 15px;
  box-shadow: 0 -3px 9px rgba(74, 59, 47, 0.12);
}
.safe-area { height: env(safe-area-inset-bottom, 0px); background: #9C9D62; }

.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 8px;
  position: relative;
  cursor: pointer;
  transition: transform 0.15s ease;
  -webkit-tap-highlight-color: transparent;
  background: none; border: none;
}
.tab-item:active { transform: scale(0.94); }

.bubble {
  width: 34px; height: 34px;
  border-radius: 11px 12px 10px 12px / 12px 10px 12px 11px;
  display: flex; align-items: center; justify-content: center;
  border: 1.5px solid rgba(255, 250, 240, 0.5);
  box-shadow: 0 2px 0 rgba(74, 59, 47, 0.10);
}
.tab-item.is-center { padding-top: 0; }
.tab-item.is-center .bubble {
  width: 56px; height: 56px;
  border-radius: 50%;
  margin-top: -22px;
  background: #E9C58F;
  border: 2.5px solid #FBF4E8;
  box-shadow: 0 4px 0 rgba(74, 59, 47, 0.14);
}
.tab-item.is-center .label { margin-top: 2px; }

.tab-label {
  margin-top: 4px;
  font-size: 10.5px;
  letter-spacing: 1px;
  color: rgba(251, 244, 232, 0.86);
  line-height: 1.4;
}
.tab-item.is-on .tab-label { color: #FFFDF8; font-weight: 700; }
.tab-item.is-on .bubble {
  box-shadow: 0 2px 0 rgba(74, 59, 47, 0.18), 0 0 0 2px rgba(255, 253, 248, 0.35);
}

/* ===== 纯 CSS 图标（不引入任何图片） ===== */
.ico { position: relative; width: 21px; height: 21px; color: var(--ink); }
.tab-item.is-center .ico { width: 25px; height: 25px; color: #5A4322; }
.ico .i-a, .ico .i-b, .ico .i-c { position: absolute; }

/* 图鉴：小册子 */
.ico-book .i-a {
  left: 1px; top: 2px; right: 1px; bottom: 2px;
  border: 2px solid currentColor;
  border-radius: 3px 6px 3px 5px;
}
.ico-book .i-b {
  left: 6px; top: 6px;
  width: 2px; height: 9px;
  background: currentColor;
  border-radius: 2px;
  opacity: 0.75;
}
.ico-book .i-c {
  left: 11px; top: 7px;
  width: 6px; height: 2px;
  background: currentColor;
  border-radius: 2px;
  opacity: 0.55;
}

/* 论坛：气泡 + 小尾巴 */
.ico-chat .i-a {
  left: 1px; top: 2px; right: 1px; bottom: 5px;
  border: 2px solid currentColor;
  border-radius: 8px 8px 7px 7px;
}
.ico-chat .i-b {
  left: 5px; bottom: 1px;
  width: 7px; height: 7px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg) skew(0deg, 8deg);
  border-bottom-left-radius: 2px;
}

/* 拍摄：相机 */
.ico-camera .i-a {
  left: 0; top: 4.5px; right: 0; bottom: 1.5px;
  border: 2px solid currentColor;
  border-radius: 6px;
}
.ico-camera .i-b {
  left: 50%; top: 50%;
  width: 10px; height: 10px;
  margin: -5px 0 0 -5px;
  border: 2px solid currentColor;
  border-radius: 50%;
}
.ico-camera .i-c {
  left: 50%; top: 1px;
  width: 10px; height: 4px;
  margin-left: -5px;
  border: 2px solid currentColor;
  border-bottom: none;
  border-radius: 3px 3px 0 0;
}

/* 救助：十字 */
.ico-aid .i-a {
  left: 1.5px; top: 1.5px; right: 1.5px; bottom: 1.5px;
  border: 2px solid currentColor;
  border-radius: 6px;
}
.ico-aid .i-b {
  left: 50%; top: 50%;
  width: 3px; height: 11px;
  margin: -5.5px 0 0 -1.5px;
  background: currentColor;
  border-radius: 2px;
}
.ico-aid .i-c {
  left: 50%; top: 50%;
  width: 11px; height: 3px;
  margin: -1.5px 0 0 -5.5px;
  background: currentColor;
  border-radius: 2px;
}

/* 我的：头像 */
.ico-user .i-a {
  left: 50%; top: 1.5px;
  width: 9px; height: 9px;
  margin-left: -4.5px;
  border: 2px solid currentColor;
  border-radius: 50%;
}
.ico-user .i-b {
  left: 50%; bottom: 2px;
  width: 16px; height: 9px;
  margin-left: -8px;
  border: 2px solid currentColor;
  border-bottom: none;
  border-radius: 9px 9px 0 0;
}

/* ---------------- 底部弹层 ---------------- */
.sheet-mask {
  position: fixed;
  left: 50%; bottom: 0;
  transform: translateX(-50%);
  width: 100%; max-width: 430px;
  height: 100vh;
  background: rgba(74, 59, 47, 0.4);
  z-index: 1000;
  display: none;
}
.sheet-mask.on { display: block; }
.sheet {
  position: fixed;
  left: 50%; bottom: 0;
  transform: translateX(-50%) translateY(105%);
  width: 100%; max-width: 430px;
  background: var(--bg-soft);
  border-top-left-radius: 22px 16px;
  border-top-right-radius: 22px 16px;
  padding: 18px 16px calc(20px + env(safe-area-inset-bottom, 0px));
  z-index: 1001;
  transition: transform 0.24s cubic-bezier(0.25, 0.9, 0.3, 1);
  box-shadow: 0 -6px 24px rgba(74, 59, 47, 0.16);
}
.sheet.on { transform: translateX(-50%) translateY(0); }
.sheet-title {
  font-family: var(--font-hand);
  font-size: 17px; font-weight: 700;
  letter-spacing: 1px;
  text-align: center;
  margin-bottom: 4px;
}
.sheet-sub { font-size: 11.5px; color: var(--ink-2); text-align: center; margin-bottom: 14px; }

/* ---------------- Toast ---------------- */
.toast {
  position: fixed;
  left: 50%;
  top: 42%;
  transform: translate(-50%, -50%) scale(0.94);
  max-width: 78%;
  padding: 11px 20px;
  background: rgba(74, 59, 47, 0.92);
  color: #FBF4E8;
  font-size: 13.5px;
  line-height: 1.6;
  border-radius: 14px 16px 13px 15px;
  text-align: center;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.toast.on { opacity: 1; transform: translate(-50%, -50%) scale(1); }

/* ---------------- 加载遮罩 ---------------- */
.loading-mask {
  position: fixed;
  left: 50%; top: 0;
  transform: translateX(-50%);
  width: 100%; max-width: 430px;
  height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: rgba(74, 59, 47, 0.25);
  z-index: 1500;
}
.loading-box {
  padding: 16px 26px;
  background: rgba(74, 59, 47, 0.9);
  color: #FBF4E8;
  border-radius: 14px 16px 13px 15px;
  font-size: 13.5px;
}

/* ---------------- 详情页通用 ---------------- */
.detail-hero {
  margin: 14px 16px 0;
  padding: 16px;
  background: #FFFDF8;
  border: 1.5px solid rgba(216, 199, 174, 0.85);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
}
.hero-top { display: flex; align-items: center; gap: 14px; }
.hero-ava {
  width: 72px; height: 72px; flex: 0 0 72px;
  position: relative;
  border-radius: 16px 19px 14px 17px / 17px 14px 19px 16px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-hand);
  font-size: 34px; font-weight: 700;
  color: rgba(74, 59, 47, 0.72);
  border: 1.5px solid rgba(74, 59, 47, 0.08);
  overflow: visible;
}
.hero-ava img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.hero-ava .ac-species { right: -5px; bottom: -5px; }
.hero-name { font-family: var(--font-hand); font-size: 24px; font-weight: 700; letter-spacing: 2px; }
.hero-meta { font-size: 11.5px; color: var(--ink-2); margin-top: 4px; }
.hero-pill-row { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }

.kv { display: flex; padding: 9px 0; border-bottom: 1px dashed rgba(216, 199, 174, 0.6); }
.kv:last-child { border-bottom: none; }
.kv-k { flex: 0 0 68px; font-size: 12px; color: var(--ink-2); }
.kv-v { flex: 1; font-size: 13px; line-height: 1.6; word-break: break-word; }

.bar-row { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.bar-track {
  flex: 1;
  height: 8px;
  background: rgba(216, 199, 174, 0.4);
  border-radius: 999px;
  overflow: hidden;
}
.bar-fill { height: 100%; border-radius: 999px; }
.bar-spirit { background: linear-gradient(90deg, #E4CE9A, #D9B870); }
.bar-mischief { background: linear-gradient(90deg, #B9C6AC, #93A77F); }
.bar-num { flex: 0 0 auto; font-family: var(--font-num); font-size: 13px; font-weight: 700; }
