/* ============ 主题变量 ============ */
:root,
html[data-theme="dark"] {
  --bg: #0d1117;
  --panel: #161b22;
  --card: #161b22;
  --text: #e6edf3;
  --muted: #8b98a5;
  --up: #ff4d4f;      /* 涨：红（国内习惯），暗底提亮保证对比 */
  --down: #21d07a;    /* 跌：绿，暗底提亮保证对比 */
  --accent: #f0b90b;
  --accent-soft: rgba(240, 185, 11, .14);
  --border: #232b34;
  --shadow: 0 8px 26px rgba(0, 0, 0, .35);
  --shadow-hover: 0 14px 36px rgba(0, 0, 0, .45);
}

html[data-theme="light"] {
  /* 简约白色：去掉米黄/金色底，改为干净的中性白 */
  --bg: #ffffff;
  --panel: #ffffff;
  --card: #ffffff;
  --text: #1f2329;
  --muted: #5f6b76;
  --up: #e23242;
  --down: #15b366;
  --accent: #d4a017;
  --accent-soft: rgba(212, 160, 23, .10);
  --border: #e5e8ec;
  --shadow: 0 4px 18px rgba(15, 23, 42, .06);
  --shadow-hover: 0 10px 28px rgba(15, 23, 42, .10);
}

* { box-sizing: border-box; }

html { background: var(--bg); color: var(--text); }

body {
  margin: 0;
  /* 简约背景：纯色，去掉金色渐变晕染 */
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  transition: background .25s ease, color .25s ease;
  min-height: 100vh;
}

/* ============ 顶栏 ============ */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 26px;
  background: color-mix(in srgb, var(--panel) 86%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 12px;
}
.title { font-size: 18px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 10px var(--accent);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

.meta { display: flex; align-items: center; gap: 14px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.updated { font-variant-numeric: tabular-nums; }

.refresh select {
  background: var(--card); color: var(--text); border: 1px solid var(--border);
  border-radius: 8px; padding: 5px 8px; margin-left: 6px; font-size: 13px; cursor: pointer;
}
.btn {
  background: var(--accent); color: #1a1a1a; border: none; border-radius: 8px;
  padding: 7px 14px; font-weight: 600; cursor: pointer; font-size: 13px;
  transition: filter .15s ease, transform .1s ease;
}
.btn:hover { filter: brightness(1.08); }
.btn:active { transform: scale(.97); }
.btn.ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn.active { background: var(--accent); color: #1a1a1a; border-color: var(--accent); }

/* ============ 容器 & 分区 ============ */
.container { max-width: 1240px; margin: 0 auto; padding: 26px 24px 10px; }

.block { margin-bottom: 28px; }
.block-head { display: flex; align-items: center; gap: 10px; margin: 4px 2px 16px; }
.block-head h2 { font-size: 16px; margin: 0; font-weight: 700; display: flex; align-items: center; }
.block-head h2::before {
  content: ""; display: inline-block; width: 4px; height: 16px;
  border-radius: 3px; margin-right: 9px;
}
.block-head .muted { font-size: 12px; color: var(--muted); }

.block-banks .block-head h2::before   { background: var(--accent); }
.block-a-share .block-head h2::before { background: #3b82f6; }
.block-metal .block-head h2::before   { background: #f59e0b; }
.block-fx .block-head h2::before      { background: #10b981; }
.block-market .block-head h2::before  { background: var(--accent); }

/* 行情子区块标题（黄金·美元 / 贵金属·商品 / A股） */
.sub-block { margin-top: 18px; }
.block-head h3 { font-size: 14px; margin: 0; font-weight: 700; display: flex; align-items: center; }
.block-head h3::before { content: ""; display: inline-block; width: 3px; height: 13px; border-radius: 3px; margin-right: 8px; background: var(--border); }
.sub-fx .block-head h3::before      { background: #10b981; }
.sub-silver .block-head h3::before   { background: #f59e0b; }
.sub-metal .block-head h3::before    { background: #f59e0b; }
.sub-ashare .block-head h3::before   { background: #3b82f6; }
.sub-asia-index .block-head h3::before { background: #ef4444; }
.sub-asia-fx .block-head h3::before  { background: #10b981; }

/* 黄金·美元页签：外汇与白银并排 */
.subgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 22px; }
@media (max-width: 760px) { .subgrid { grid-template-columns: 1fr; } }

/* ============ 卡片网格 ============ */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }

.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px 18px;
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform .15s ease, box-shadow .2s ease, background .25s ease;
}
.card::before {
  content: ""; position: absolute; left: 0; top: 0; width: 100%; height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: .55;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.card.primary::before { background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--accent) 20%, transparent)); opacity: 1; }

.card .bank { font-size: 14px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.card .bank .b-name { font-weight: 600; }
.card .bank .right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.badge { font-size: 11px; padding: 3px 9px; border-radius: 20px; background: var(--accent-soft); color: var(--accent); font-weight: 600; white-space: nowrap; }
/* 编辑模式：卡片左右边缘的圆形移动按钮（仅编辑态显示） */
.arr-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--accent);
  color: #1a1a1a;
  font-size: 17px; line-height: 1;
  display: none;
  align-items: center; justify-content: center;
  padding: 0; cursor: pointer;
  box-shadow: var(--shadow);
  z-index: 5;
}
.arr-btn[data-dir="left"] { left: 8px; }
.arr-btn[data-dir="right"] { right: 8px; }
.arr-btn:hover { filter: brightness(1.08); }
.arr-btn:active { transform: translateY(-50%) scale(.92); }
body.editing .card { border-color: color-mix(in srgb, var(--accent) 55%, var(--border)); user-select: none; padding-left: 42px; padding-right: 42px; }
body.editing .arr-btn { display: flex; }
.card.placeholder > * { visibility: hidden; }

.price {
  font-size: 36px; font-weight: 800; margin: 12px 0 6px; letter-spacing: .3px;
  font-variant-numeric: tabular-nums; line-height: 1.1;
}
.price.small { font-size: 30px; }
.price .sym { font-size: 18px; font-weight: 700; margin-right: 2px; opacity: .8; }

.sub { display: flex; align-items: center; gap: 14px; font-size: 14px; margin-top: 2px; }
.chg { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; font-variant-numeric: tabular-nums; padding: 2px 9px; border-radius: 8px; }
.chg .arr { font-size: 11px; }
.chg.up { color: var(--up); background: color-mix(in srgb, var(--up) 16%, transparent); }
.chg.down { color: var(--down); background: color-mix(in srgb, var(--down) 16%, transparent); }

.unit { font-size: 12px; color: var(--muted); font-weight: 400; }

.detail { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--border);
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; font-size: 13px; color: var(--muted); }
.detail b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }

.skeleton { color: transparent; text-align: left; padding: 16px 18px; overflow: hidden; }
.skeleton::before { display: none; }
.skeleton .sk { display: block; height: 13px; border-radius: 7px; margin: 10px 0; background: color-mix(in srgb, var(--text) 11%, transparent); }
.skeleton .sk.w-40 { width: 42%; } .skeleton .sk.w-70 { width: 72%; } .skeleton .sk.w-90 { width: 92%; }
.skeleton::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--text) 9%, transparent), transparent);
  background-size: 220% 100%; animation: shimmer 1.3s linear infinite;
}
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

.foot { text-align: center; color: var(--muted); font-size: 12px; padding: 26px 16px 34px; border-top: 1px solid var(--border); line-height: 1.7; }

@media (max-width: 600px) {
  .price { font-size: 32px; }
  .price.small { font-size: 26px; }
  .container { padding: 20px 16px 8px; }
  .cards { grid-template-columns: 1fr; }
  /* 移动端工具区表单进一步堆叠为单列 */
  .conv-row { grid-template-columns: 1fr; }
  .hold-form { grid-template-columns: 1fr; }
  .hold-sim { grid-template-columns: 1fr; }
  .mon-row { grid-template-columns: 1fr; }
  .mon-row label { margin-bottom: 4px; }
  .tool-card { padding: 14px 14px; }
  .tool-head { margin-bottom: 10px; }
  .mon-input, .conv-input { flex-wrap: wrap; }
}

/* 平板及以下：行情子区块（外汇/白银）堆叠 */
@media (max-width: 760px) {
  .subgrid { grid-template-columns: 1fr; }
  .conv-actions { flex-wrap: wrap; }
}

@media (min-width: 900px) {
  .cards { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
}

/* ============ 银行积存金下方：换算 & 监控 ============ */
.btn.sm { padding: 6px 12px; font-size: 12px; border-radius: 8px; }

.tool-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: var(--shadow);
}
.tool-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.tool-head h3 { font-size: 14px; margin: 0; font-weight: 700; }
.tool-head .muted { font-size: 11px; }
.hold-sync { font-size: 11px; color: var(--muted); margin-left: 2px; }

.conv-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.conv-field label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.conv-input { display: flex; gap: 8px; }
.conv-input input, .mon-input input, .mon-row input {
  flex: 1; min-width: 0; background: var(--card); color: var(--text);
  border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.conv-input input:focus, .mon-input input:focus, .mon-row input:focus { outline: none; border-color: var(--accent); }

.conv-result {
  margin-top: 14px; padding: 12px 14px; border-radius: 10px;
  background: var(--accent-soft); color: var(--text); font-size: 13px; line-height: 1.9;
}
.conv-result b { color: var(--accent); font-variant-numeric: tabular-nums; }
.conv-result .row { display: flex; gap: 8px; }

.conv-actions { display: flex; gap: 10px; margin-top: 14px; }

.conv-list { margin-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.conv-list:empty { display: none; }
.conv-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--card); font-size: 13px;
}
.conv-item .ci-main { font-weight: 600; font-variant-numeric: tabular-nums; }
.conv-item .ci-sub { color: var(--muted); font-size: 12px; }
.conv-item .ci-del {
  margin-left: auto; background: transparent; border: 1px solid var(--border); color: var(--muted);
  border-radius: 8px; width: 26px; height: 26px; cursor: pointer; font-size: 15px; line-height: 1;
}
.conv-item .ci-del:hover { color: var(--down); border-color: var(--down); }

.mon-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.mon-field label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.mon-input { display: flex; gap: 8px; }
.mon-input select {
  background: var(--card); color: var(--text); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px; font-size: 13px; cursor: pointer;
}
.mon-row { display: grid; grid-template-columns: 88px 1fr; align-items: center; gap: 10px; margin-top: 12px; }
.mon-row label { font-size: 12px; color: var(--muted); }
.mon-status { margin-top: 0; font-size: 13px; }
.mon-status.on { color: var(--down); }
.mon-status.off { color: var(--muted); }
.mon-tip { font-size: 11px; color: var(--muted); margin-bottom: 12px; line-height: 1.6; }
.mon-now { font-size: 12px; color: var(--muted); margin-top: 7px; font-variant-numeric: tabular-nums; }
.mon-now b { color: var(--text); font-weight: 700; }
.mon-now .mn.hit { color: var(--up); font-weight: 700; }
.mon-now .mn.idle { color: var(--down); }
.mon-foot { display: flex; align-items: center; gap: 12px; margin-top: 14px; flex-wrap: wrap; }

.switch { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: var(--muted); cursor: pointer; }
.switch input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; }

/* ============ 页签导航 ============ */
.tabs-wrap { margin-top: 22px; }
.tabs {
  display: flex; gap: 4px; margin-bottom: 16px; flex-wrap: wrap;
  border-bottom: 1px solid var(--border);
}
.tab-btn {
  background: transparent; border: none; cursor: pointer;
  color: var(--muted); font-size: 14px; font-weight: 600;
  padding: 11px 18px; border-radius: 10px 10px 0 0;
  position: relative; transition: color .15s ease; white-space: nowrap;
}
.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--accent); }
.tab-btn.active::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: -1px;
  height: 3px; border-radius: 3px 3px 0 0; background: var(--accent);
}
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: tabIn .22s ease; }
@keyframes tabIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ============ 我的持仓 ============ */
.hold-form {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px; align-items: end;
}
.hold-field label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.hold-field input, .hold-field select {
  width: 100%; background: var(--card); color: var(--text);
  border: 1px solid var(--border); border-radius: 8px; padding: 9px 10px; font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.hold-field input:focus, .hold-field select:focus { outline: none; border-color: var(--accent); }
.hold-fee { display: flex; gap: 8px; }
.hold-fee input { flex: 1; min-width: 0; }
.hold-fee select { width: 66px; flex: none; }
.hold-field input[type="date"] { font-variant-numeric: tabular-nums; cursor: pointer; }
html[data-theme="dark"] .hold-field input[type="date"] { color-scheme: dark; }
html[data-theme="light"] .hold-field input[type="date"] { color-scheme: light; }
.hold-field input[type="date"]::-webkit-calendar-picker-indicator {
  cursor: pointer; opacity: .6; transition: opacity .15s ease; margin-left: 4px;
}
.hold-field input[type="date"]:hover::-webkit-calendar-picker-indicator { opacity: 1; }
.hold-add { display: flex; align-items: flex-end; }
.hold-add .btn { width: 100%; }

.hold-summary {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 12px; margin-top: 16px; padding: 14px 16px; border-radius: 12px;
  background: var(--accent-soft);
}
.hold-summary .hs-item { font-size: 12px; color: var(--muted); display: flex; flex-direction: column; gap: 2px; }
.hold-summary .hs-val { font-size: 19px; font-weight: 800; font-variant-numeric: tabular-nums; }

.hold-list { margin-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.hold-list:empty { display: none; }
.hold-item {
  display: grid; grid-template-columns: 1.4fr 1fr 0.8fr 1fr 1.1fr 1.1fr 1.2fr 0.9fr auto; gap: 12px;
  align-items: center; padding: 12px 14px; border: 1px solid var(--border);
  border-radius: 12px; background: var(--card); font-size: 13px;
  transition: border-color .15s ease;
}
.hold-item .hi-date { text-align: center; font-variant-numeric: tabular-nums; color: var(--muted); font-size: 12px; }
.hold-item .hi-num { text-align: right; font-variant-numeric: tabular-nums; line-height: 1.4; }
.hold-item .hi-num b { font-size: 14px; }
.hold-item .hi-num.up { color: var(--up); font-weight: 700; }
.hold-item .hi-num.down { color: var(--down); font-weight: 700; }
.hold-item:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.hold-item .hi-bank { font-weight: 700; }
.hold-item .hi-sub { color: var(--muted); font-size: 11px; margin-top: 2px; }
.hold-item .hi-val { font-variant-numeric: tabular-nums; line-height: 1.5; }
.hold-item .hi-val b { font-size: 14px; }
.hold-item .hi-profit { font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.4; text-align: right; }
.hold-item .hi-profit small { font-weight: 500; font-size: 11px; opacity: .85; }
.hold-item .hi-profit.up { color: var(--up); }
.hold-item .hi-profit.down { color: var(--down); }
.hold-item .hi-del {
  background: transparent; border: 1px solid var(--border); color: var(--muted);
  border-radius: 8px; width: 28px; height: 28px; cursor: pointer; font-size: 15px; line-height: 1;
  flex: none;
}
.hold-item .hi-del:hover { color: var(--down); border-color: var(--down); }
.hold-empty { color: var(--muted); font-size: 13px; text-align: center; padding: 24px 16px; border: 1px dashed var(--border); border-radius: 12px; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.hold-empty .btn { margin-top: 8px; }

@media (max-width: 760px) {
  .hold-item { grid-template-columns: repeat(3, 1fr); gap: 8px 10px; padding: 12px; }
  .hold-item .hi-bank { grid-column: 1 / -1; text-align: left; }
  .hold-item > div { min-width: 0; }
  .hold-item > div:not(.hi-actions)::before {
    content: attr(data-label);
    display: block; font-size: 10px; color: var(--muted); margin-bottom: 2px;
  }
  .hold-item .hi-date, .hold-item .hi-num, .hold-item .hi-profit { text-align: right; }
  .hold-item .hi-val, .hold-item .hi-num, .hold-item .hi-profit { overflow-wrap: anywhere; word-break: break-word; }
  .hold-item .hi-actions { grid-column: 3; align-self: center; justify-self: end; }
  .hold-item.merge { grid-template-columns: repeat(3, 1fr); }
}

/* ============ 行情卡品牌色 ============ */
.card.brand-gold::before  { background: linear-gradient(90deg, #f5b301, color-mix(in srgb, #f5b301 12%, transparent)); opacity: 1; }
.card.brand-blue::before  { background: linear-gradient(90deg, #3b82f6, color-mix(in srgb, #3b82f6 12%, transparent)); opacity: 1; }
.card.brand-red::before   { background: linear-gradient(90deg, #ef4444, color-mix(in srgb, #ef4444 12%, transparent)); opacity: 1; }
.card.brand-green::before { background: linear-gradient(90deg, #10b981, color-mix(in srgb, #10b981 12%, transparent)); opacity: 1; }
.card.brand-amber::before { background: linear-gradient(90deg, #f59e0b, color-mix(in srgb, #f59e0b 12%, transparent)); opacity: 1; }
.card.brand-purple::before { background: linear-gradient(90deg, #8b5cf6, color-mix(in srgb, #8b5cf6 12%, transparent)); opacity: 1; }
.card.brand-gold  { border-top-color: color-mix(in srgb, #f5b301 40%, var(--border)); }
.card.brand-blue  { border-top-color: color-mix(in srgb, #3b82f6 40%, var(--border)); }
.card.brand-red   { border-top-color: color-mix(in srgb, #ef4444 40%, var(--border)); }
.card.brand-green { border-top-color: color-mix(in srgb, #10b981 40%, var(--border)); }
.card.brand-amber { border-top-color: color-mix(in srgb, #f59e0b 40%, var(--border)); }
.card.brand-purple { border-top-color: color-mix(in srgb, #8b5cf6 40%, var(--border)); }

/* ============ 自动刷新倒计时 ============ */
.refresh-count { font-variant-numeric: tabular-nums; color: var(--muted); margin-left: 2px; white-space: nowrap; }

/* ============ 持仓工具条 ============ */
.hold-toolbar { display: flex; gap: 8px; flex-wrap: wrap; }
.hold-toolbar .btn.sm { font-size: 12px; }
.hold-toolbar .btn.active { background: var(--accent); color: #1a1a1a; border-color: var(--accent); }

/* ============ 持仓汇总卡片 ============ */
.hold-summary {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px; margin-top: 16px; padding: 0; border-radius: 0; background: transparent;
}
.hold-summary .hs-item {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; box-shadow: var(--shadow);
  transition: transform .15s ease, box-shadow .2s ease;
}
.hold-summary .hs-item:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.hold-summary .hs-label { font-size: 12px; color: var(--muted); }
.hold-summary .hs-val { font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }

/* ============ 持仓列表表头 ============ */
.hold-head {
  display: grid; grid-template-columns: 1.4fr 1fr 0.8fr 1fr 1.1fr 1.1fr 1.2fr 0.9fr auto; gap: 12px;
  align-items: center; padding: 6px 14px; margin-top: 16px;
  font-size: 11px; color: var(--muted); border-bottom: 1px solid var(--border);
}
.hold-head span:nth-child(2) { text-align: center; }
.hold-head span:nth-child(3),
.hold-head span:nth-child(4),
.hold-head span:nth-child(5),
.hold-head span:nth-child(6),
.hold-head span:nth-child(7),
.hold-head span:nth-child(8),
.hold-head span:nth-child(9) { text-align: right; }
@media (max-width: 760px) { .hold-head { display: none; } }

/* ============ 持仓行（含每克盈亏、目标徽标、编辑） ============ */
.hold-item .hi-badges { display: flex; gap: 6px; margin-top: 5px; flex-wrap: wrap; }
.hi-badge { font-size: 10px; padding: 1px 7px; border-radius: 10px; background: var(--down); color: #fff; font-weight: 600; white-space: nowrap; }
.hi-badge.reached { background: var(--up); }
.hi-profit .perg { font-size: 11px; opacity: .8; font-weight: 500; margin-top: 2px; }
.hi-badge.reached { box-shadow: 0 0 0 2px color-mix(in srgb, var(--up) 25%, transparent); }
.hold-item .hi-actions { display: flex; gap: 6px; justify-content: flex-end; }
.hold-item .hi-edit {
  background: transparent; border: 1px solid var(--border); color: var(--muted);
  border-radius: 8px; width: 28px; height: 28px; cursor: pointer; font-size: 13px; line-height: 1; flex: none;
}
.hold-item .hi-edit:hover { color: var(--accent); border-color: var(--accent); }
.hold-item.merge .merge-tag { color: var(--muted); font-size: 12px; text-align: right; }

/* ============ 模拟加仓面板 ============ */
.hold-sim {
  margin-top: 14px; padding: 14px; border: 1px dashed var(--border); border-radius: 12px;
  background: var(--accent-soft); display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px; align-items: end;
}
.hold-sim .hs-field label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.hold-sim .hs-field input, .hold-sim .hs-field select {
  width: 100%; background: var(--card); color: var(--text); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 10px; font-size: 13px; font-variant-numeric: tabular-nums;
}
.hold-sim .hs-out { grid-column: 1 / -1; font-size: 13px; font-variant-numeric: tabular-nums; line-height: 1.7; }
.hold-sim .hs-out b { color: var(--accent); }

