/* ===================================================================
   幻梦 · AI 生图 - 前台样式（参考截图：白底 + 浅灰卡片 + 深色按钮）
   =================================================================== */

[v-cloak] { display: none; }

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  max-width: 100vw;
  overflow-x: hidden;
}

html, body, #app {
  margin: 0; padding: 0;
  background: #f5f6f8;
  color: #1f2937;
  font-family: 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden !important;
  position: relative;
}

/* 强制所有元素不超出屏幕宽度 */
@media (max-width: 768px) {
  body * {
    max-width: 100vw;
  }
}

a { cursor: pointer; color: inherit; text-decoration: none; }

/* ============ 顶部导航 ============ */
.hm-header {
  background: #f5f6f8;
  border-bottom: 1px solid #ececef;
  position: sticky; top: 0; z-index: 100;
  width: 100%;
}
.hm-header-inner {
  max-width: 1280px; margin: 0 auto;
  padding: 10px 24px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  width: 100%;
}
.hm-brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.hm-logo-dot {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: #111827;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
}
.hm-brand-name { font-size: 16px; font-weight: 700; color: #111827; line-height: 1.1; }
.hm-brand-sub { font-size: 11px; color: #9ca3af; margin-top: 2px; }

.hm-nav { display: flex; gap: 2px; flex-shrink: 1; flex-wrap: wrap; }
.hm-nav-item {
  padding: 6px 10px;
  border-radius: 999px;
  color: #4b5563;
  font-size: 13px;
  display: inline-flex; align-items: center; gap: 4px;
  transition: all .15s;
  white-space: nowrap;
}
.hm-nav-item:hover { background: #fff; color: #111827; }
.hm-nav-item i { font-size: 11px; }

.hm-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; flex-wrap: wrap; }

/* 按钮系统 */
.hm-btn {
  border: 0;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 5px;
  font-weight: 500;
  transition: all .15s;
  outline: none;
  white-space: nowrap;
}
.hm-btn-dark { background: #111827; color: #fff; }
.hm-btn-dark:hover { background: #1f2937; }
.hm-btn-dark:disabled { background: #9ca3af; cursor: not-allowed; }
.hm-btn-ghost { background: #fff; color: #111827; border: 1px solid #e5e7eb; }
.hm-btn-ghost:hover { background: #f9fafb; }
.hm-btn-lg { padding: 12px 24px; font-size: 15px; }
.hm-btn-sm { padding: 5px 12px; font-size: 12px; }
.hm-btn-block { width: 100%; justify-content: center; }

.hm-credit-chip {
  background: #fff;
  border: 1px solid #e5e7eb;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  color: #374151;
  display: inline-flex; align-items: center; gap: 5px;
  font-weight: 500;
  white-space: nowrap;
}
.hm-credit-chip i { color: #f59e0b; }

.hm-user-chip {
  background: #111827; color: #fff;
  padding: 5px 10px; border-radius: 999px;
  font-size: 12px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 5px;
  white-space: nowrap;
}
.hm-user-chip:hover { background: #1f2937; }

/* ============ 主体 ============ */
.hm-main {
  max-width: 1280px;
  width: 100%;
  margin: 0 auto;
  padding: 24px 24px 48px;
  overflow-x: hidden;
}

/* 未登录欢迎页 */
.hm-hero {
  display: flex; justify-content: center;
  padding: 60px 0;
}
.hm-hero-card {
  background: #fff;
  border-radius: 20px;
  padding: 48px 56px;
  text-align: center;
  max-width: 640px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
  border: 1px solid #eef0f3;
}
.hm-hero-title { font-size: 28px; font-weight: 700; margin-bottom: 12px; color: #111827; }
.hm-hero-desc { color: #6b7280; font-size: 15px; margin-bottom: 28px; line-height: 1.6; }
.hm-hero-actions { display: flex; gap: 12px; justify-content: center; }

/* 未登录提示条 */
.hm-guest-bar {
  display: flex; align-items: center; justify-content: space-between;
  background: linear-gradient(90deg, #eef2ff, #fdf4ff);
  border: 1px solid #e0e7ff;
  border-radius: 12px;
  padding: 10px 16px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #4338ca;
}
.hm-guest-text i { color: #6366f1; margin-right: 6px; }
.hm-guest-actions { display: flex; gap: 8px; }

/* 工作台双栏 */
.hm-workspace {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
@media (max-width: 1024px) {
  .hm-workspace { grid-template-columns: 1fr; }
  .hm-header-inner { flex-wrap: wrap; }
  .hm-nav { order: 3; width: 100%; justify-content: center; }
}

/* ============ 移动端适配 ============ */
@media (max-width: 768px) {
  .hm-header { position: relative; }
  .hm-header-inner {
    padding: 10px 12px;
    gap: 6px;
    flex-wrap: wrap;
  }
  .hm-brand { flex-shrink: 0; }
  .hm-brand-name { font-size: 14px; }
  .hm-brand-sub { display: none; }
  .hm-logo-dot { width: 28px; height: 28px; font-size: 12px; border-radius: 8px; }

  /* 导航横向滚动 */
  .hm-nav {
    order: 3; width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    flex-wrap: nowrap;
    padding: 6px 0 2px;
    border-top: 1px solid #eef0f3;
    margin-top: 4px;
    -webkit-overflow-scrolling: touch;
    -ms-overflow-style: none;
    scrollbar-width: none;
  }
  .hm-nav::-webkit-scrollbar { display: none; }
  .hm-nav-item { padding: 4px 8px; font-size: 12px; flex-shrink: 0; }

  /* 右侧操作区：只保留关键按钮 */
  .hm-actions {
    gap: 4px;
    margin-left: auto;
  }
  .hm-actions .hm-btn { padding: 4px 6px; font-size: 11px; gap: 2px; }
  .hm-actions .hm-btn i { font-size: 12px; }
  /* 移动端隐藏按钮文字，只显示图标 */
  .hm-actions .hm-btn span { display: none; }
  .hm-credit-chip { padding: 4px 8px; font-size: 11px; gap: 3px; max-width: none; }
  .hm-user-chip { padding: 4px 8px; font-size: 11px; gap: 3px; }
  .hm-user-chip span { display: none; }

  /* 主体 */
  .hm-main { padding: 12px 8px 32px; width: 100%; }
  .hm-guest-bar {
    flex-direction: column; gap: 8px;
    text-align: center; font-size: 12px;
    padding: 8px 10px;
  }
  .hm-workspace { grid-template-columns: 1fr; gap: 12px; }

  .hm-card { padding: 12px; border-radius: 12px; width: 100%; }
  .hm-card-title { font-size: 14px; }
  .hm-card-sub { font-size: 11px; }

  /* label 换行 */
  .hm-label {
    font-size: 11px;
    display: flex; flex-wrap: wrap;
    justify-content: space-between; align-items: center;
    gap: 4px;
  }
  .hm-label-meta { font-size: 10px; color: #9ca3af; }
  .hm-label-row {
    flex-wrap: wrap; gap: 4px;
  }
  .hm-label-row .hm-link { font-size: 11px; }

  .hm-field { margin-bottom: 10px; }
  .hm-grid-2 { grid-template-columns: 1fr; gap: 8px; }
  .hm-grid-3 { grid-template-columns: 1fr 1fr 1fr; gap: 6px; }

  /* 防止 select/input 撑出容器 */
  .hm-card .el-select, .hm-card .el-input, .hm-card .el-textarea {
    max-width: 100% !important;
  }

  .hm-generate-btn { padding: 12px; font-size: 14px; border-radius: 10px; }
  .hm-credit-hint { font-size: 10px; text-align: center; }

  .hm-preview-box { min-height: 240px; padding: 10px; }
  .hm-preview-info { gap: 4px; }
  .hm-chip { font-size: 10px; padding: 2px 6px; }
  .hm-preview-img { max-height: 280px; }

  .hm-history-card { margin-top: 12px; }
  .hm-history-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: 8px;
  }
  .hm-history-meta { display: none; }

  .hm-upload { padding: 16px 10px; font-size: 11px; }
  .hm-upload i { font-size: 18px; margin-bottom: 4px; }

  .hm-link { font-size: 11px; }

  /* 弹窗 */
  .el-dialog { width: 94vw !important; max-width: 94vw !important; margin: 8px auto !important; }
  .el-dialog__body { padding: 8px 14px 14px !important; }
  .el-dialog__header { padding: 14px 14px 0 !important; }

  .hm-auth-title { font-size: 17px; }
  .hm-pack-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .hm-pack { padding: 12px 8px; }
  .hm-pack-amount { font-size: 18px; }

  .hm-pay-box { flex-direction: column; gap: 16px; }
  .hm-qr-wrap { flex: auto; }
  .hm-qr-img { width: 180px; height: 180px; }

  .hm-wheel-prizes { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .hm-wheel-item { padding: 10px 6px; }
  .hm-wheel-credits { font-size: 16px; }

  .hm-verify-row { gap: 6px; }
  .hm-verify-input { height: 36px; padding: 0 10px; font-size: 13px; }
  .hm-verify-btn { height: 36px; padding: 0 10px; font-size: 11px; }
}

@media (max-width: 480px) {
  .hm-grid-3 { grid-template-columns: 1fr 1fr; gap: 6px; }
  .hm-pack-grid { grid-template-columns: 1fr; }
  .hm-history-grid { grid-template-columns: repeat(3, 1fr); }
  .hm-wheel-prizes { grid-template-columns: repeat(2, 1fr); }
}

/* 卡片 */
.hm-card {
  background: #fff;
  border-radius: 16px;
  padding: 24px;
  border: 1px solid #eef0f3;
  box-shadow: 0 1px 2px rgba(0,0,0,.02);
}
.hm-card-head { margin-bottom: 18px; }
.hm-card-title {
  font-size: 16px; font-weight: 700; color: #111827;
  display: inline-flex; align-items: center; gap: 8px;
}
.hm-card-sub { font-size: 12px; color: #9ca3af; margin-top: 4px; }
.hm-icon-blue { color: #6366f1; }

/* 表单 */
.hm-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}
.hm-grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}
.hm-field { margin-bottom: 14px; }
.hm-label {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 12px; color: #6b7280;
  margin-bottom: 6px; font-weight: 500;
}
.hm-label-row {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 6px;
}
.hm-label-meta { font-size: 11px; color: #9ca3af; font-weight: normal; }
.hm-link { color: #6366f1; cursor: pointer; font-size: 12px; }
.hm-link:hover { text-decoration: underline; }

/* 比例示意小方块（下拉选项内） */
.hm-ratio-box {
  display: inline-block;
  border: 1.5px solid #9ca3af;
  border-radius: 2px;
  background: #f3f4f6;
  flex-shrink: 0;
}

/* 画质卡片 */
.hm-res-cards {
  display: flex; gap: 10px;
}
.hm-res-card {
  flex: 1;
  border: 1.5px solid #e5e7eb;
  border-radius: 10px;
  padding: 14px 12px;
  text-align: center;
  cursor: pointer;
  transition: all .15s;
}
.hm-res-card:hover { border-color: #cbd5e1; }
.hm-res-card.active {
  border-color: #6366f1;
  background: #f5f3ff;
  box-shadow: 0 0 0 1px #6366f1;
}
.hm-res-name { font-size: 18px; font-weight: 700; color: #111827; }
.hm-res-desc { font-size: 11px; color: #9ca3af; margin-top: 2px; }
.hm-res-price { font-size: 12px; color: #6366f1; font-weight: 500; margin-top: 4px; }

/* 像素尺寸提示 */
.hm-pixel-hint {
  margin-top: 8px;
  font-size: 12px;
  color: #6b7280;
  display: flex;
  align-items: center;
  gap: 5px;
}
.hm-pixel-hint i { color: #9ca3af; font-size: 11px; }

/* 暂无模型提示 */
.hm-no-models {
  padding: 12px 14px;
  background: #fef3c7;
  border: 1px solid #fde68a;
  border-radius: 8px;
  font-size: 13px;
  color: #92400e;
  display: flex;
  align-items: center;
}

/* 并发数卡片 */
.hm-qty-cards {
  display: flex; gap: 8px;
}
.hm-qty-card {
  width: 40px; height: 40px;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 600; color: #374151;
  cursor: pointer; transition: all .15s;
}
.hm-qty-card:hover { border-color: #cbd5e1; }
.hm-qty-card.active {
  border-color: #6366f1;
  background: #f5f3ff;
  color: #6366f1;
  box-shadow: 0 0 0 1px #6366f1;
}

/* 上传 */
.hm-upload {
  border: 1.5px dashed #d1d5db;
  background: #fafbfc;
  border-radius: 12px;
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  color: #9ca3af;
  font-size: 13px;
  transition: all .15s;
}
.hm-upload:hover, .hm-upload.is-drag {
  border-color: #6366f1; background: #f5f3ff; color: #6366f1;
}
.hm-upload i { font-size: 24px; margin-bottom: 6px; display: block; }

.hm-refs {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 8px;
}
.hm-ref-item {
  position: relative; aspect-ratio: 1; border-radius: 8px;
  overflow: hidden; border: 1px solid #e5e7eb;
}
.hm-ref-item img { width: 100%; height: 100%; object-fit: cover; }
.hm-ref-rm {
  position: absolute; top: 4px; right: 4px;
  width: 20px; height: 20px; border-radius: 50%;
  background: rgba(0,0,0,.6); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; cursor: pointer;
}
.hm-ref-add {
  border: 1.5px dashed #d1d5db; border-radius: 8px;
  aspect-ratio: 1; display: flex; align-items: center; justify-content: center;
  color: #9ca3af; cursor: pointer;
}
.hm-ref-add:hover { border-color: #6366f1; color: #6366f1; }

/* 生成按钮 */
.hm-generate-btn {
  width: 100%;
  background: #111827; color: #fff; border: 0;
  padding: 14px; border-radius: 12px;
  font-size: 15px; font-weight: 600;
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  margin-top: 8px;
  transition: all .15s;
}
.hm-generate-btn:hover:not(:disabled) { background: #1f2937; }
.hm-generate-btn:disabled { background: #9ca3af; cursor: not-allowed; }
.hm-credit-hint {
  margin-top: 10px; text-align: center;
  font-size: 12px; color: #9ca3af;
}
.hm-credit-hint b { color: #111827; }

/* 预览面板 */
.hm-preview-card { display: flex; flex-direction: column; align-self: stretch; }
.hm-preview-box {
  background: #fafbfc;
  border-radius: 12px;
  border: 1px solid #eef0f3;
  padding: 16px;
  flex: 1;
  display: flex; flex-direction: column;
  min-height: 420px;
}
.hm-preview-info {
  display: flex; gap: 6px; flex-wrap: wrap;
  margin-bottom: 12px;
}
.hm-chip {
  font-size: 11px; padding: 3px 10px; border-radius: 999px;
  display: inline-flex; align-items: center; gap: 4px;
}
.hm-chip-soft { background: #fff; color: #4b5563; border: 1px solid #e5e7eb; }
.hm-chip-load { font-weight: 500; }
.hm-chip-load.load-idle { background: #f0fdf4; color: #16a34a; border: 1px solid #bbf7d0; }
.hm-chip-load.load-low { background: #f0fdf4; color: #16a34a; border: 1px solid #bbf7d0; }
.hm-chip-load.load-mid { background: #fefce8; color: #b45309; border: 1px solid #fde68a; }
.hm-chip-load.load-high { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }
.hm-chip-tiny { padding: 2px 8px; font-size: 10px; }

.hm-preview-area {
  flex: 1;
  display: flex; align-items: center; justify-content: center;
  min-height: 320px;
  color: #9ca3af;
  position: relative;
}
.hm-preview-empty { font-size: 13px; }
.hm-preview-loading { text-align: center; }
.hm-preview-loading i { font-size: 32px; margin-bottom: 8px; }
.hm-preview-err {
  max-width: 360px; font-size: 12px; color: #ef4444;
  margin-top: 8px; padding: 8px 12px;
  background: #fef2f2; border-radius: 6px;
}
.hm-preview-img {
  max-width: 100%; max-height: 420px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,.08);
}
.hm-preview-actions {
  position: absolute; top: 8px; right: 8px;
  display: flex; gap: 6px;
}
.hm-icon-btn {
  width: 34px; height: 34px; border-radius: 8px;
  background: rgba(255,255,255,.95);
  border: 1px solid #e5e7eb;
  color: #374151; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.hm-icon-btn:hover { background: #fff; color: #111827; }

/* ============ 历史记录 ============ */
.hm-history-card { margin-top: 20px; }
.hm-history-head {
  display: flex; align-items: flex-start; justify-content: space-between;
}
.hm-empty-block {
  padding: 60px 20px; text-align: center; color: #9ca3af;
}
.hm-empty-block i { font-size: 40px; display: block; margin-bottom: 10px; color: #d1d5db; }

.hm-history-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
.hm-history-item { cursor: pointer; }
.hm-history-thumb {
  position: relative;
  aspect-ratio: 1; border-radius: 12px; overflow: hidden;
  border: 1px solid #eef0f3; background: #fafbfc;
}
.hm-history-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s; }
.hm-history-item:hover .hm-history-thumb img { transform: scale(1.05); }
.hm-history-loading {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: #9ca3af; font-size: 24px;
}
.hm-history-del {
  position: absolute; top: 6px; right: 6px;
  width: 24px; height: 24px; border-radius: 50%;
  background: rgba(0,0,0,.5); color: #fff;
  display: none; align-items: center; justify-content: center;
  font-size: 10px; cursor: pointer;
}
.hm-history-item:hover .hm-history-del { display: flex; }
.hm-history-del:hover { background: #dc2626; }

.hm-history-meta {
  margin-top: 8px; display: flex; gap: 4px; flex-wrap: wrap;
}

/* ============ 弹窗通用 ============ */
.el-dialog {
  border-radius: 16px !important;
  overflow: hidden;
}
.el-dialog__body { padding: 8px 24px 24px !important; }
.el-dialog__header { padding: 20px 24px 0 !important; }

.hm-auth { padding: 8px 0 4px; }
.hm-auth-title {
  font-size: 20px; font-weight: 700; text-align: center;
  margin-bottom: 24px;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.hm-auth-switch { text-align: center; color: #6b7280; font-size: 13px; margin-top: 16px; }
.hm-auth-switch a { color: #6366f1; cursor: pointer; }
.hm-auth-switch a:hover { text-decoration: underline; }

/* 验证码行 */
.hm-verify-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 20px;
}
.hm-verify-input {
  flex: 1;
  height: 40px;
  padding: 0 15px;
  border: 1px solid #dcdfe6;
  border-radius: 8px;
  font-size: 14px;
  outline: none;
  color: #1f2937;
  transition: border-color .2s;
}
.hm-verify-input:focus {
  border-color: #6366f1;
}
.hm-verify-input::placeholder {
  color: #a8abb2;
}
.hm-verify-btn {
  flex-shrink: 0;
  height: 40px;
  padding: 0 16px;
  border: 1px solid #6366f1;
  border-radius: 8px;
  background: #fff;
  color: #6366f1;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all .15s;
}
.hm-verify-btn:hover {
  background: #6366f1;
  color: #fff;
}
.hm-verify-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background: #f3f4f6;
  color: #9ca3af;
  border-color: #e5e7eb;
}

/* 充值 */
.hm-recharge-head {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 0 0 20px;
}
.hm-muted { color: #9ca3af; font-size: 13px; }
.hm-recharge-body { }

.hm-pack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.hm-pack {
  position: relative;
  border: 1.5px solid #eef0f3;
  border-radius: 14px;
  padding: 16px 14px 18px;
  cursor: pointer;
  transition: all .15s;
  text-align: center;
}
.hm-pack:hover { border-color: #cbd5e1; transform: translateY(-2px); }
.hm-pack.active {
  border-color: #111827; background: #fafbfc;
  box-shadow: 0 4px 12px rgba(17,24,39,.08);
}
.hm-pack-badge {
  position: absolute; top: -10px; right: 10px;
  background: #ef4444; color: #fff;
  font-size: 11px; padding: 2px 10px;
  border-radius: 999px;
}
.hm-pack-title { font-size: 13px; color: #6b7280; margin-bottom: 6px; }
.hm-pack-amount { font-size: 24px; font-weight: 700; color: #111827; margin-bottom: 4px; }
.hm-pack-credit { font-size: 13px; color: #374151; margin-bottom: 6px; }
.hm-pack-bonus { color: #ef4444; font-size: 11px; margin-left: 4px; }
.hm-pack-desc { font-size: 11px; color: #9ca3af; }

.hm-custom-amount { margin-bottom: 20px; }
.hm-tip {
  padding: 10px 14px; border-radius: 8px;
  font-size: 12px;
  margin-top: 10px;
}
.hm-tip-warn { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }

.hm-pay-box {
  display: flex; gap: 24px; padding-top: 16px;
  flex-wrap: wrap;
}
.hm-pay-info { flex: 1; min-width: 200px; }
.hm-pay-row {
  display: flex; justify-content: space-between;
  padding: 10px 0; border-bottom: 1px dashed #eef0f3;
  font-size: 13px; color: #6b7280;
}
.hm-pay-row b { color: #111827; font-weight: 600; }
.hm-qr-wrap {
  text-align: center; flex: 0 0 280px;
}
.hm-qr-img {
  width: 240px; height: 240px; border-radius: 12px;
  border: 1px solid #eef0f3; padding: 8px;
  background: #fff;
}
.hm-pay-status {
  margin-top: 12px; color: #374151; font-size: 13px;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.hm-pay-note { margin-top: 6px; font-size: 11px; }
.hm-pay-actions { margin-top: 16px; display: flex; gap: 8px; justify-content: center; }

/* 用户中心 */
.hm-center { padding: 0; }
.hm-center-tabs {
  display: flex; gap: 4px;
  border-bottom: 1px solid #eef0f3; margin-bottom: 16px;
}
.hm-tab {
  padding: 10px 16px; cursor: pointer;
  color: #6b7280; font-size: 14px;
  border-bottom: 2px solid transparent;
  display: inline-flex; align-items: center; gap: 6px;
}
.hm-tab.active { color: #111827; border-bottom-color: #111827; font-weight: 600; }
.hm-center-body { min-height: 280px; }

.hm-table {
  width: 100%; border-collapse: collapse; font-size: 13px;
}
.hm-table th, .hm-table td {
  padding: 10px 12px; text-align: left;
  border-bottom: 1px solid #f3f4f6;
}
.hm-table th { font-weight: 600; color: #6b7280; background: #fafbfc; }
.hm-table td { color: #374151; }
.hm-empty-cell { text-align: center !important; color: #9ca3af; padding: 40px !important; }

.hm-status {
  display: inline-block;
  padding: 2px 10px; border-radius: 999px; font-size: 11px;
  background: #f3f4f6; color: #6b7280;
}
.st-paid { background: #dcfce7; color: #16a34a; }
.st-pending { background: #fef3c7; color: #b45309; }
.st-cancelled { background: #f3f4f6; color: #6b7280; }
.st-failed { background: #fee2e2; color: #dc2626; }

.lt-recharge, .lt-pay { background: #dcfce7; color: #16a34a; }
.lt-consume { background: #fee2e2; color: #dc2626; }
.lt-refund, .lt-gift, .lt-admin_adjust { background: #dbeafe; color: #2563eb; }

/* 占位信息 */
.hm-info-dialog { padding: 0 0 8px; }

/* 公告弹窗 */
.hm-announce-popup { padding: 0; }
.hm-announce-content {
  background: #fafbfc;
  border: 1px solid #eef0f3;
  border-radius: 10px;
  padding: 16px 18px;
  font-size: 14px;
  color: #374151;
  line-height: 1.8;
  margin-bottom: 18px;
  white-space: pre-wrap;
}
.hm-announce-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.hm-announce-check {
  display: flex; align-items: center; gap: 6px;
  font-size: 13px; color: #6b7280; cursor: pointer;
}
.hm-announce-check input { cursor: pointer; }

/* 签到 */
.hm-signin { text-align: center; padding: 8px 0; }
.hm-signin-done { padding: 40px 0; }
.hm-wheel-prizes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 16px;
}
.hm-wheel-item {
  border: 1.5px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px 8px;
  text-align: center;
  transition: all .3s;
}
.hm-wheel-item.highlight {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99,102,241,.3);
  transform: scale(1.05);
}
.hm-wheel-credits { font-size: 22px; font-weight: 700; color: #111827; }
.hm-wheel-name { font-size: 12px; color: #6b7280; margin-top: 4px; }
.hm-signin-result {
  margin-top: 16px;
  padding: 12px;
  background: #fefce8;
  border: 1px solid #fde68a;
  border-radius: 8px;
  color: #92400e;
  font-size: 14px;
  font-weight: 500;
}

/* 邀请 */
.hm-invite-rules {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 20px;
}
.hm-invite-rule {
  font-size: 13px;
  color: #166534;
  padding: 4px 0;
  display: flex; align-items: center; gap: 8px;
}
.hm-invite-rule i { color: #16a34a; width: 16px; }
.hm-invite-rule b { color: #111827; }
.hm-invite-code-box { }
.hm-invite-stats {
  display: flex; gap: 24px; justify-content: center;
  margin-top: 20px; padding-top: 16px;
  border-top: 1px solid #eef0f3;
}
.hm-invite-stat { text-align: center; }
.hm-invite-stat-val { font-size: 24px; font-weight: 700; color: #111827; }
.hm-invite-stat-label { font-size: 12px; color: #9ca3af; margin-top: 4px; }
.hm-info-text { color: #374151; line-height: 1.7; font-size: 14px; }
.hm-info-text i { color: #9ca3af; margin-right: 6px; }

/* 提示词库 */
.hm-promptlib-dialog .el-dialog__body { padding: 0 !important; }
.hm-promptlib-dialog .el-dialog__header { display: none !important; }
.hm-plib {
  padding: 24px 28px 32px;
  background: #f5f6f8;
  min-height: 80vh;
}
.hm-plib-header { margin-bottom: 16px; }
.hm-plib-title {
  font-size: 20px; font-weight: 700; color: #111827;
  display: flex; align-items: center; gap: 8px;
}
.hm-plib-subtitle { font-size: 13px; color: #9ca3af; margin-top: 4px; }

.hm-plib-search {
  display: flex; gap: 10px; margin-bottom: 16px;
}
.hm-plib-search-box {
  flex: 1;
  display: flex; align-items: center; gap: 10px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 0 14px;
  height: 42px;
}
.hm-plib-search-box i { color: #9ca3af; }
.hm-plib-search-box input {
  flex: 1; border: 0; outline: 0; font-size: 14px; color: #1f2937;
  background: transparent;
}
.hm-plib-search-box input::placeholder { color: #a8abb2; }

.hm-plib-tags {
  display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 20px;
}
.hm-plib-tag {
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 13px;
  cursor: pointer;
  background: #fff;
  border: 1px solid #e5e7eb;
  color: #4b5563;
  transition: all .15s;
}
.hm-plib-tag:hover { border-color: #111827; color: #111827; }
.hm-plib-tag.active {
  background: #111827; color: #fff; border-color: #111827;
}

.hm-plib-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.hm-plib-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #eef0f3;
  transition: all .2s;
}
.hm-plib-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  transform: translateY(-3px);
}
.hm-plib-thumb {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
}
.hm-plib-thumb img {
  width: 100%; height: 100%; object-fit: cover;
}
.hm-plib-cat-badge {
  position: absolute; top: 8px; left: 8px;
  background: rgba(0,0,0,.6); color: #fff;
  font-size: 11px; padding: 2px 8px;
  border-radius: 4px;
}
.hm-plib-body { padding: 12px 14px 14px; }
.hm-plib-prompt {
  font-size: 12px; color: #4b5563; line-height: 1.5;
  overflow: hidden; text-overflow: ellipsis;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  margin-bottom: 10px;
  min-height: 54px;
}
.hm-plib-footer {
  display: flex; gap: 8px; align-items: center;
}
.hm-plib-use-btn {
  flex: 1;
  background: #111827; color: #fff; border: 0;
  padding: 7px 0; border-radius: 6px;
  font-size: 12px; font-weight: 500;
  cursor: pointer; transition: background .15s;
}
.hm-plib-use-btn:hover { background: #1f2937; }
.hm-plib-copy-btn {
  width: 32px; height: 32px;
  border: 1px solid #e5e7eb; border-radius: 6px;
  background: #fff; color: #6b7280;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all .15s;
}
.hm-plib-copy-btn:hover { border-color: #6366f1; color: #6366f1; }

.hm-detail-meta {
  margin-top: 12px; color: #374151; font-size: 13px; line-height: 1.8;
}
.hm-detail-meta b { color: #6b7280; font-weight: 500; }

/* ============ Element Plus 样式微调 ============ */
.el-select .el-input__wrapper, .el-textarea__inner, .el-input__wrapper {
  border-radius: 8px !important;
}
.el-textarea__inner {
  resize: vertical;
  font-family: inherit;
}
.el-overlay { max-width: 100vw !important; overflow-x: hidden !important; }

/* ============ 蒙版编辑 ============ */
.hm-mode-tabs {
  display: flex; gap: 4px; margin-bottom: 16px;
  background: #fff; border-radius: 10px; padding: 4px;
  border: 1px solid #eef0f3; width: fit-content;
}
.hm-mode-tab {
  padding: 8px 18px; border-radius: 8px; font-size: 13px; font-weight: 500;
  color: #6b7280; cursor: pointer; transition: all .15s;
  display: flex; align-items: center; gap: 6px;
}
.hm-mode-tab:hover { color: #111827; }
.hm-mode-tab.active { background: #6366f1; color: #fff; }

.hm-inpaint-toolbar {
  display: flex; gap: 6px; align-items: center; margin-bottom: 10px; flex-wrap: wrap;
}
.hm-inpaint-tool {
  background: #f3f4f6; border: 1px solid #e5e7eb; color: #374151;
  border-radius: 6px; padding: 6px 10px; font-size: 12px; cursor: pointer;
  display: flex; align-items: center; gap: 4px; transition: all .15s;
}
.hm-inpaint-tool:hover { border-color: #6366f1; color: #6366f1; }
.hm-inpaint-tool.active { background: #6366f1; color: #fff; border-color: #6366f1; }
.hm-inpaint-sep { width: 1px; height: 20px; background: #e5e7eb; margin: 0 4px; }
.hm-inpaint-size-label { font-size: 11px; color: #9ca3af; min-width: 24px; text-align: center; }
.hm-inpaint-slider { width: 90px; accent-color: #6366f1; }

.hm-inpaint-canvas-wrap {
  position: relative;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px dashed #d1d5db;
  min-height: 360px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.hm-inpaint-placeholder {
  text-align: center; padding: 40px 20px; cursor: pointer; color: #9ca3af;
}
.hm-inpaint-placeholder i { font-size: 40px; margin-bottom: 10px; display: block; }

.hm-inpaint-upload {
  border: 1.5px dashed #d1d5db; border-radius: 8px; padding: 12px;
  text-align: center; cursor: pointer; font-size: 12px; color: #6b7280;
  transition: border-color .15s;
}
.hm-inpaint-upload:hover { border-color: #6366f1; }
.hm-inpaint-upload i { margin-right: 6px; }

.hm-inpaint-cursor {
  position: absolute;
  border: 2px solid rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3);
  z-index: 10;
}
