/* 站内信 + 帮助共享样式（assets/inbox.js 配套，2026-08-24 v20260824c）
   暖纸系配色跟 site.css 雾光变量走；所有类名 mmi- 前缀，不跟各页面样式打架 */

.mmi-anchor { position: relative; display: inline-flex; align-items: center; gap: 10px; margin-left: 10px; }
.mmi-anchor.mmi-fixed { position: fixed; top: 10px; right: 12px; z-index: 9999; }

.mmi-bell {
  position: relative; border: 1px solid var(--line, rgba(41,38,49,.12)); background: #fff;
  border-radius: 999px; padding: 6px 12px; font-size: 14px; line-height: 1;
  cursor: pointer; color: var(--ink, #292631); font-family: inherit;
}
.mmi-bell:hover { border-color: var(--accent, #292631); }

/* 消息未读徽标：红底感叹号，闪烁提醒 */
.mmi-badge {
  position: absolute; top: -7px; right: -7px; min-width: 16px; height: 16px;
  border-radius: 8px; background: #c0392b; color: #fff; font-size: 11px;
  line-height: 16px; text-align: center; padding: 0 4px; font-weight: 700;
  animation: mmi-blink 1s steps(2, start) infinite; pointer-events: none;
}
@keyframes mmi-blink { 50% { opacity: .2; } }

/* 帮助徽标：静态小圆点，不闪烁（有回复/状态变化才出） */
.mmi-hbadge {
  position: absolute; top: -4px; right: -4px; width: 9px; height: 9px;
  border-radius: 50%; background: #c0392b; border: 1.5px solid #fff; pointer-events: none;
}

.mmi-panel {
  position: fixed; top: 52px; right: 12px; z-index: 9999; width: 330px;
  max-width: calc(100vw - 24px); max-height: 72vh; display: flex; flex-direction: column;
  background: #ffffff; border: 1px solid var(--line, rgba(41,38,49,.12)); border-radius: 14px;
  box-shadow: 0 10px 34px rgba(41,38,49,.16); overflow: hidden;
  font-size: 13px; color: var(--ink, #292631);
}
.mmi-panel[hidden] { display: none; }

.mmi-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; border-bottom: 1px dashed var(--line, rgba(41,38,49,.12));
  font-weight: 600; font-size: 14px;
}
.mmi-head button {
  border: 0; background: none; color: var(--accent, #292631); font-size: 12px;
  cursor: pointer; font-family: inherit; padding: 0;
}

.mmi-list { overflow-y: auto; flex: 1; }
.mmi-empty { text-align: center; color: var(--ink-faint, #716c78); padding: 18px 0; font-size: 12.5px; }

.mmi-msg { border-bottom: 1px dashed var(--line, rgba(41,38,49,.12)); padding: 10px 14px; cursor: pointer; }
.mmi-msg:hover { background: rgba(200,222,231,.35); }
.mmi-msg.unread { background: var(--accent-soft, rgba(201,190,220,.30)); }
.mmi-msg-top { display: flex; align-items: center; gap: 6px; }
.mmi-kind {
  flex-shrink: 0; font-size: 11px; border-radius: 6px; padding: 1px 7px;
  background: #eef1f7; color: var(--ink-dim, #716c78);
}
.mmi-kind.redeem { background: var(--accent-soft, rgba(201,190,220,.30)); color: #292631; border: 1px solid rgba(41,38,49,.25); }
.mmi-kind.help_reply { background: #e8f0e4; color: #4a7d4f; }
.mmi-kind.payment_notice { background: #f6e3e1; color: #a0392f; }
.mmi-dot { flex-shrink: 0; width: 7px; height: 7px; border-radius: 50%; background: #c0392b; }
.mmi-title { flex: 1; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mmi-title:empty::before { content: "（无标题）"; color: var(--ink-faint, #716c78); font-weight: 400; }
.mmi-time { flex-shrink: 0; font-size: 11px; color: var(--ink-faint, #716c78); font-variant-numeric: tabular-nums; }
.mmi-body { display: none; margin-top: 7px; line-height: 1.8; white-space: pre-wrap; word-break: break-word; color: var(--ink, #292631); }
.mmi-msg.open .mmi-body { display: block; }

/* 帮助面板：整片滚动（case 列表 + 提交表单） */
.mmi-hwrap { overflow-y: auto; flex: 1; padding: 10px 14px 14px; }
.mmi-sec { font-size: 12px; font-weight: 600; color: var(--ink-2, #716c78); margin: 8px 0 6px; }

/* case 列表：编号 + 状态章 + 时间，点开展开正文和回复串 */
.mmi-case { border: 1px solid var(--line, rgba(41,38,49,.12)); border-radius: 10px; padding: 8px 10px; margin-bottom: 6px; cursor: pointer; background: #fff; }
.mmi-case:hover { border-color: var(--accent, #292631); }
.mmi-case-top { display: flex; align-items: center; gap: 6px; }
.mmi-cno { flex: 1; min-width: 0; font-weight: 600; font-size: 12.5px; }
.mmi-st { flex-shrink: 0; font-size: 11px; border-radius: 6px; padding: 1px 7px; background: #eef1f7; color: var(--ink-dim, #716c78); }
.mmi-st.st-reviewing { background: #fdf0dd; color: #9a6b1f; }
.mmi-st.st-done { background: #e8f0e4; color: #4a7d4f; }
.mmi-excerpt { margin-top: 4px; font-size: 12px; color: var(--ink-dim, #716c78); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mmi-case-detail { display: none; margin-top: 8px; border-top: 1px dashed var(--line, rgba(41,38,49,.12)); padding-top: 8px; }
.mmi-case.open .mmi-case-detail { display: block; }
.mmi-case.open .mmi-excerpt { display: none; }
.mmi-cbody { line-height: 1.8; white-space: pre-wrap; word-break: break-word; }
.mmi-reply { margin-top: 8px; background: var(--accent-soft, rgba(201,190,220,.30)); border-radius: 8px; padding: 7px 9px; }
.mmi-reply-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 2px; }
.mmi-reply-tag { font-size: 11px; font-weight: 600; color: #292631; }

/* 「提交新帮助」表单 */
.mmi-report { margin-top: 2px; }
.mmi-report .mmi-uid { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.mmi-report .mmi-uid label { font-size: 12px; color: var(--ink-2, #716c78); font-weight: 600; }
.mmi-report .mmi-uid input {
  width: 110px; border: 1px solid var(--line, rgba(41,38,49,.12)); border-radius: 8px; padding: 6px 10px;
  font-size: 13px; font-family: inherit; color: var(--ink, #292631); background: #fff;
}
.mmi-report textarea {
  width: 100%; box-sizing: border-box; min-height: 96px; resize: vertical;
  border: 1px solid var(--line, rgba(41,38,49,.12)); border-radius: 10px; padding: 10px 12px;
  font-size: 13px; font-family: inherit; color: var(--ink, #292631); background: #fff; line-height: 1.7;
}
.mmi-report .mmi-tip { font-size: 11.5px; color: var(--ink-faint, #716c78); margin: 6px 0; line-height: 1.7; }
.mmi-tip { font-size: 11.5px; color: var(--ink-faint, #716c78); }
.mmi-thumbs { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0; }
.mmi-thumbs .mmi-thumb { position: relative; width: 52px; height: 52px; border-radius: 8px; overflow: hidden; background: #eef1f7; }
.mmi-thumbs .mmi-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mmi-thumbs .mmi-thumb button {
  position: absolute; top: 2px; right: 2px; border: 0; border-radius: 50%; width: 16px; height: 16px;
  line-height: 16px; padding: 0; font-size: 10px; cursor: pointer; background: rgba(0, 0, 0, .55); color: #fff;
}
.mmi-report .mmi-send {
  width: 100%; margin-top: 8px; border: 0; border-radius: 10px; padding: 9px 0;
  font-size: 13px; cursor: pointer; font-family: inherit;
  background: var(--accent, #292631); color: #fff; font-weight: 600;
}
.mmi-report .mmi-send:disabled { opacity: .55; cursor: default; }
.mmi-ok {
  color: #4a7d4f; background: #e8f0e4; border-radius: 10px;
  padding: 9px 12px; margin-bottom: 8px; line-height: 1.7;
}
.mmi-err { color: #c0453f; font-size: 12px; margin-top: 6px; }
