/* ============================================================
 * FundBoard · fund.css  其他基金对比页专用样式
 * 页面骨架（页头 / 控制区 / 卡片 / 表格 / 说明列表）全部来自 base.css，
 * 这里只保留本页独有的徽章、焦点开关、概览胶囊与回撤修复区。
 * ============================================================ */

/* ---------- 提示区 ---------- */
.fund-notes {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}
#fund-loading { margin-top: 4px; }
.fund-empty-hint { margin-top: 6px; }

/* ---------- 卡片头部的静态徽章 ---------- */
.fund-badge {
  font-size: 11px;
  font-weight: 600;
  color: var(--fb-accent-deep);
  background: var(--fb-accent-soft);
  border-radius: 999px;
  padding: 3px 9px;
  white-space: nowrap;
}

/* ---------- 焦点基金开关 ---------- */
.fund-focus {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.fund-focus-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 190px;
  height: 28px;
  padding: 0 11px;
  border: 1px solid var(--fb-line-strong);
  border-radius: 999px;
  background: var(--fb-surface);
  color: var(--fb-text-2);
  font-size: 12px;
  cursor: pointer;
  transition: all .15s;
}
.fund-focus-btn:hover { border-color: #c3ccdd; color: var(--fb-text); background: var(--fb-surface-2); }
.fund-focus-btn.is-active {
  border-color: #b9c6fb;
  background: var(--fb-accent-soft);
  color: var(--fb-accent-deep);
  font-weight: 600;
}
.fund-focus-btn i {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  flex: none;
}
.fund-focus-btn span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- 指标卡下的概览胶囊 ---------- */
.fund-overview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.fund-overview:empty { display: none; }
.fund-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  font-size: 12px;
  color: var(--fb-text-2);
  background: var(--fb-surface-2);
  border: 1px solid var(--fb-line);
  border-radius: 999px;
  max-width: 100%;
}
.fund-pill .fb-legend-dot { margin-right: 0; flex: none; }
.fund-pill-label { color: var(--fb-text-3); flex: none; }
.fund-pill b {
  font-weight: 650;
  color: var(--fb-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 12em;
}
.fund-pill-value { font-weight: 650; font-variant-numeric: tabular-nums; flex: none; }
.fund-pill.is-warn {
  background: #fff9ec;
  border-color: #f6e3b8;
  color: #8a5d00;
}

/* ---------- 表格 ---------- */
.fund-click-table tbody tr { cursor: pointer; }
.fund-td-name { font-weight: 600; }

/* ---------- 回撤修复明细 ---------- */
.fund-ep-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.fund-ep-summary:empty { display: none; }
.fund-ep-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  font-size: 12px;
  color: var(--fb-text-2);
  background: var(--fb-surface-2);
  border: 1px solid var(--fb-line);
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.fund-ep-pill b { font-weight: 700; color: var(--fb-text); }
.fund-ep-pill.is-ok { background: #e8f7f1; border-color: #bfe8d9; color: #0c7a55; }
.fund-ep-pill.is-ok b { color: #0c7a55; }
.fund-ep-pill.is-warn { background: #fff9ec; border-color: #f6e3b8; color: #8a5d00; }
.fund-ep-pill.is-warn b { color: #8a5d00; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .fund-stats-card .fb-card-actions { margin-left: 0; width: 100%; }
  .fund-focus { justify-content: flex-start; }
  .fund-focus-btn { max-width: 160px; }
}

@media (max-width: 560px) {
  .fund-pill b { max-width: 8em; }
  .fund-focus-btn { max-width: 140px; }
}
