/* 交易页：对齐参考站期权交易（黑底、青 pill、买涨买跌） */
.am-trade.tabbar-page-beijing,
.am-trade {
  background: #000 !important;
  background-image: none !important;
  color: #fff;
  padding-bottom: calc(1.7 * 100vw / 7.5) !important;
}

.am-trade,
.am-trade div,
.am-trade span,
.am-trade button,
.am-trade b,
.am-trade p {
  font-family: Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
}

/* 参考站 .trade-head-box：margin 13px 13px 18.2px */
.am-trade .am-tr-nav {
  display: flex;
  align-items: center;
  gap: 0;
  margin: calc(0.25 * 100vw / 7.5) calc(0.25 * 100vw / 7.5) calc(0.35 * 100vw / 7.5);
  padding: 0;
  background: transparent;
}

/* 参考站 .tabBox：radius 10.4px、padding 2.6px，内部三个 tab 等分 */
.am-trade .am-tr-tabs {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  min-width: 0;
  padding: calc(0.05 * 100vw / 7.5);
  border-radius: calc(0.2 * 100vw / 7.5);
  background: transparent;
}

.am-trade .am-tr-back {
  flex: 0 0 auto;
  margin-right: calc(0.2 * 100vw / 7.5);
  width: calc(0.4615 * 100vw / 7.5);
  height: calc(0.4615 * 100vw / 7.5);
  padding: 0;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.am-trade .am-tr-back svg {
  width: calc(0.4615 * 100vw / 7.5);
  height: calc(0.4615 * 100vw / 7.5);
  display: block;
}

.am-trade .am-tr-title {
  flex: 1 1 auto;
  text-align: center;
  color: #fff;
  font-size: 16px;
  font-weight: 650;
}

.am-trade .am-tr-side {
  flex: 0 0 auto;
  width: calc(0.4615 * 100vw / 7.5);
}

/* 参考站 .tabContentBox：108x36、radius 7.28px、font 14.04px、常规 400 / 选中 700 */
.am-trade .am-tr-tab {
  flex: 1 1 0;
  min-width: 0;
  height: calc(0.6923 * 100vw / 7.5);
  line-height: calc(0.6923 * 100vw / 7.5);
  padding: 0;
  border: 0;
  border-radius: calc(0.14 * 100vw / 7.5);
  background: transparent;
  color: #fff;
  font-size: calc(0.27 * 100vw / 7.5);
  font-weight: 400;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.am-trade .am-tr-tab.on {
  background: #00f0ff;
  color: #111;
  font-weight: 700;
}

.am-trade .am-tr-quote {
  padding: calc(0.12 * 100vw / 7.5) calc(0.28 * 100vw / 7.5) calc(0.08 * 100vw / 7.5);
  background: #000;
}

/* 秒合约头部：参考站布局（对 + O/C + H/L，无大价格） */
.am-trade .am-tr-quote--second {
  padding: 8px 15px 4px;
  background: transparent;
}

.am-trade .am-tr-ohlc {
  display: flex;
  align-items: flex-start;
  margin-top: 14px;
}

/* 参考站 .change：font 14.56px、涨 #00f0ff / 跌 #ff4834 */
.am-trade .am-tr-pct {
  width: 48% !important;
  min-width: 0;
  font-size: calc(0.28 * 100vw / 7.5) !important;
  font-weight: 400 !important;
  line-height: 1.2;
  background: transparent !important;
}

.am-trade .am-tr-pct.rise,
.am-trade .am-tr-pct.buy,
.am-trade .am-tr-pct.rise.rfd-sign {
  color: #00f0ff !important;
}

.am-trade .am-tr-pct.fall,
.am-trade .am-tr-pct.sell,
.am-trade .am-tr-pct.fall.rfd-sign {
  color: #ff4834 !important;
}

.am-trade .am-tr-ohlc-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.am-trade .am-tr-ohlc-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
  line-height: 1.2;
}

.am-trade .am-tr-ohlc-item span {
  color: #8d8d96;
  font-size: 13px;
  font-weight: 400;
}

.am-trade .am-tr-ohlc-item b {
  color: #fff;
  font-size: 13px;
  font-weight: 400;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.am-trade .am-tr-pair-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.am-trade .am-tr-pair {
  display: inline-flex;
  align-items: center;
  gap: calc(0.08 * 100vw / 7.5);
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: calc(0.4 * 100vw / 7.5);
  font-weight: 700;
  line-height: 1.2;
}

.am-trade .am-tr-caret {
  width: calc(0.24 * 100vw / 7.5);
  height: calc(0.24 * 100vw / 7.5);
  display: block;
}

.am-trade .am-tr-star {
  width: calc(0.52 * 100vw / 7.5);
  height: calc(0.52 * 100vw / 7.5);
  padding: 0;
  border: 0;
  background: transparent;
  color: #d7d7de;
  line-height: 0;
}

.am-trade .am-tr-star svg {
  width: 100%;
  height: 100%;
  display: block;
}

.am-trade .am-tr-star.on {
  color: #00f0ff;
}

.am-trade .am-tr-px-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(0.2 * 100vw / 7.5);
  margin-top: calc(0.1 * 100vw / 7.5);
}

.am-trade .am-tr-chg.fall,
.am-trade .am-tr-chg.fall.rfd-sign {
  color: #f5354d !important;
}

.am-trade .am-tr-chg.rise,
.am-trade .am-tr-chg.rise.rfd-sign {
  color: #00f0ff !important;
}

.am-trade .second-contract-page,
.am-trade .second-contract-content-root {
  background: #000 !important;
}

.am-trade .third.third--second-contract,
.am-trade .third.third--second-contract .list,
.am-trade .kline-detail-wrap--second-contract .studyList {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
}

.am-trade .third.third--second-contract .list {
  padding: calc(0.06 * 100vw / 7.5) calc(0.22 * 100vw / 7.5) !important;
}

.am-trade .third.third--second-contract .thirdLeft {
  gap: calc(0.06 * 100vw / 7.5) !important;
  flex-wrap: nowrap;
}

.am-trade .third.third--second-contract .thirdLeft .item {
  margin: 0 !important;
  padding: 0 calc(0.14 * 100vw / 7.5) !important;
  height: calc(0.44 * 100vw / 7.5) !important;
  line-height: calc(0.44 * 100vw / 7.5) !important;
  font-size: calc(0.24 * 100vw / 7.5) !important;
  font-weight: 500 !important;
  border-radius: calc(0.08 * 100vw / 7.5) !important;
}

.am-trade .third.third--second-contract .normalItem {
  background: transparent !important;
  color: #c8c8d0 !important;
}

.am-trade .third.third--second-contract .hightItem {
  background: #00f0ff !important;
  color: #111 !important;
  font-weight: 700 !important;
}

.am-trade .kline-detail-wrap--second-contract .candlestick {
  height: calc(8.45 * 100vw / 7.5) !important;
  background: #000 !important;
}

.am-trade .kline-detail-wrap--second-contract .studyList {
  padding: calc(0.08 * 100vw / 7.5) calc(0.22 * 100vw / 7.5) calc(0.12 * 100vw / 7.5) !important;
  gap: calc(0.1 * 100vw / 7.5) !important;
  flex-wrap: nowrap !important;
}

.am-trade .kline-detail-wrap--second-contract .study-pill {
  padding: 0 calc(0.12 * 100vw / 7.5) !important;
  height: calc(0.42 * 100vw / 7.5) !important;
  line-height: calc(0.42 * 100vw / 7.5) !important;
  font-size: calc(0.22 * 100vw / 7.5) !important;
  font-weight: 600 !important;
  border-radius: calc(0.06 * 100vw / 7.5) !important;
}

.am-trade .kline-detail-wrap--second-contract .study-pill--idle {
  background: #22262f !important;
  color: #ececf1 !important;
}

.am-trade .kline-detail-wrap--second-contract .study-pill--active {
  background: #00f0ff !important;
  color: #111 !important;
}

.am-trade .kline-detail-wrap--second-contract .study-sep {
  flex: 0 0 auto;
  width: 1px;
  height: 14px;
  background: #3a3f4b;
  margin: 0 2px;
}

.am-trade .sc-order {
  background: #000 !important;
  padding-top: calc(0.08 * 100vw / 7.5) !important;
}

.am-trade .sc-order__tabs {
  border-bottom: none !important;
  min-height: calc(0.72 * 100vw / 7.5) !important;
  padding: 0 calc(0.28 * 100vw / 7.5) !important;
}

.am-trade .sc-order__tabs-inner {
  gap: calc(0.36 * 100vw / 7.5) !important;
}

.am-trade .sc-order__tab {
  font-size: calc(0.3 * 100vw / 7.5) !important;
  color: #8d8d96 !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
  padding-bottom: calc(0.1 * 100vw / 7.5) !important;
  /* 选中指示器加粗 */
  border-bottom: 3px solid transparent !important;
  border-radius: 2px !important;
  background: transparent !important;
}

.am-trade .sc-order__tab--active {
  color: #fff !important;
  font-weight: 700 !important;
  border-bottom-color: #00f0ff !important;
}

.am-trade .sc-order__refresh .entrustRUpdateImg,
.am-trade .sc-order__refresh i.entrustRUpdateImg {
  color: #00f0ff !important;
  font-size: 20px !important;
}

.am-trade .sc-order__divider,
.am-trade .second-contract-content-root > .line {
  display: none !important;
}

/* 空态：empty.svg 图标 + 一行灰色 No data */
.am-trade .sc-order__empty {
  padding: 60px 0 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.am-trade .sc-order__empty-icon {
  width: 94px;
  height: 70px;
  display: block;
  opacity: 0.9;
  pointer-events: none;
}

.am-trade .sc-order__empty-text {
  text-align: center;
  color: #8d8d96;
  font-size: 14px;
}

.am-trade .sc-second-fixed-actions {
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  padding: calc(0.16 * 100vw / 7.5) calc(0.28 * 100vw / 7.5) calc(0.22 * 100vw / 7.5) !important;
  background: #000 !important;
  z-index: 20 !important;
}

/* 参考站 .qqtrade-head-box：左右各留 17px，故清掉底部固定栏自带的 14.56px 内边距 */
.am-trade .sc-second-fixed-actions {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* 参考站 .qqBtnBox：padding 2.6px、radius 10.4px、两端对齐（非 gap） */
.am-trade .upsAndDowns {
  margin: 0 calc(0.327 * 100vw / 7.5) !important;
  padding: calc(0.05 * 100vw / 7.5) !important;
  border-radius: calc(0.2 * 100vw / 7.5) !important;
  gap: 0 !important;
  justify-content: space-between !important;
  max-width: none !important;
}

/* 参考站 .van-button：170x50、radius 7.488px、font 18.2px、font-weight 400 */
.am-trade .upsAndDowns .item {
  flex: 0 0 calc(3.269 * 100vw / 7.5) !important;
  height: calc(0.9615 * 100vw / 7.5) !important;
  line-height: calc(0.9615 * 100vw / 7.5) !important;
  border-radius: calc(0.144 * 100vw / 7.5) !important;
  font-size: calc(0.35 * 100vw / 7.5) !important;
  font-weight: 400 !important;
}

.am-trade .upsAndDowns .ups {
  background: #00f0ff !important;
  color: #000 !important;
}

.am-trade .upsAndDowns .downs {
  background: #f5354d !important;
  color: #fff !important;
}

/* —— 秒合约下单卡片（参考站样式，居中弹层） —— */
.am-trade .public-van-popup--sc-sheet.van-popup {
  background: transparent !important;
  overflow: visible;
}

.am-trade .sc-order-sheet {
  box-sizing: border-box;
  padding: 16px 16px 20px;
  background: #1b1b27;
  border-radius: 12px;
  color: #fff;
}

.am-trade .sc-order-sheet__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid #2b2b3c;
}

.am-trade .sc-order-sheet__title {
  font-size: 19px;
  font-weight: 700;
  color: #fff;
}

.am-trade .sc-order-sheet__close {
  font-size: 20px;
  color: #fff;
}

.am-trade .sc-order-sheet__pair-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0 2px;
}

.am-trade .sc-order-sheet__pair {
  font-size: 19px;
  font-weight: 700;
  color: #fff;
}

.am-trade .sc-order-sheet__pct {
  font-size: 14px;
  font-weight: 600;
}

.am-trade .sc-order-sheet__pct.opt-price--up {
  color: #00f0ff !important;
}

.am-trade .sc-order-sheet__pct.opt-price--down {
  color: #f5354d !important;
}

.am-trade .sc-order-sheet__label {
  margin: 14px 0 10px;
  font-size: 15px;
  color: #fff;
}

.am-trade .sc-order-sheet__cycles {
  display: flex;
  align-items: stretch;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}

.am-trade .sc-order-sheet__cycles::-webkit-scrollbar {
  display: none;
}

.am-trade .sc-order-sheet__cycle {
  flex: 0 0 auto;
  min-width: 82px;
  box-sizing: border-box;
  padding: 10px 8px;
  border-radius: 8px;
  background: #2b2b3c;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.am-trade .sc-order-sheet__cycle-period {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  line-height: 1.1;
}

.am-trade .sc-order-sheet__cycle-odds {
  font-size: 12px;
  color: #fff;
  line-height: 1.1;
}

.am-trade .sc-order-sheet__cycle.on {
  background: #00f0ff;
}

.am-trade .sc-order-sheet__cycle.on .sc-order-sheet__cycle-period,
.am-trade .sc-order-sheet__cycle.on .sc-order-sheet__cycle-odds {
  color: #000;
}

.am-trade .sc-order-sheet__types {
  display: flex;
  gap: 10px;
}

.am-trade .sc-order-sheet__types button {
  flex: 1;
  min-width: 0;
  height: 42px;
  border-radius: 6px;
  border: 1px solid #4a4a58;
  background: transparent;
  color: #fff;
  font-size: 15px;
  font-weight: 500;
}

.am-trade .sc-order-sheet__types button.on {
  border-color: #00f0ff;
  background: #00f0ff;
  color: #000;
  font-weight: 600;
}

.am-trade .sc-order-sheet__input {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin-top: 16px;
  height: 44px;
  padding: 0 14px;
  border: none;
  border-radius: 6px;
  background: #2b2b3c;
  color: #fff;
  font-size: 14px;
  outline: none;
}

.am-trade .sc-order-sheet__input::placeholder {
  color: #8d8d96;
}

.am-trade .sc-order-sheet__avail {
  margin: 16px 0;
  text-align: center;
  font-size: 13px;
  color: #8d8d96;
}

.am-trade .sc-order-sheet__confirm {
  display: block;
  width: 100%;
  height: 44px;
  border: none;
  border-radius: 6px;
  background: #00f0ff;
  color: #000;
  font-size: 16px;
  font-weight: 600;
}

/* ==========================================================================
   合约交易页（tradeKey=Ustandard）对齐参考站
   参考站实测（390px 视口）：表单列 209px @x16、盘口列 137px @x238、间隙 13px
   像素换算：1 单位 = 100vw / 7.5 = 52px
   ========================================================================== */

/* ---- 头部：币对 + 涨跌幅 + 右侧 K线/收藏 图标 ----
   参考站 .am-tr-pair 98x24@15,71；涨跌幅 56x21@158,73（两者间隔 45px） */
.am-trade .am-tr-quote--book .am-tr-pair-row {
  margin: calc(-0.077 * 100vw / 7.5) 0 0 calc(-0.288 * 100vw / 7.5);
}

/* 合约页限定，避免影响现货页 */
.am-trade .am-tr-quote--book .am-tr-inline-chg {
  margin-left: calc(0.865 * 100vw / 7.5);
}

.am-trade .am-tr-round {
  flex: 0 0 auto;
  width: calc(0.46 * 100vw / 7.5);
  height: calc(0.46 * 100vw / 7.5);
  margin-left: calc(0.18 * 100vw / 7.5);
  padding: 0;
  border: 0;
  background: transparent;
  color: #8d8d96;
  line-height: 0;
}

.am-trade .am-tr-round svg {
  width: 100%;
  height: 100%;
  display: block;
}

.am-trade .am-tr-round.on {
  color: #00f0ff;
}

.am-trade .am-tr-grow {
  flex: 1;
  min-width: 0;
}

/* 参考站 .change：17.68px，涨 #00f0ff / 跌 #ff4834 */
/* 全局 App.vue 有 `.rise { color: var(--ex-rfd-rise) !important }`，需同等 !important + 更高特异性 */
.am-trade .am-tr-inline-chg {
  margin-left: calc(0.16 * 100vw / 7.5);
  font-size: calc(0.34 * 100vw / 7.5) !important;
  font-weight: 400;
}

.am-trade .am-tr-inline-chg.rise {
  color: #00f0ff !important;
}

.am-trade .am-tr-inline-chg.fall {
  color: #ff4834 !important;
}

/* ---- 两列布局：左表单 / 右盘口 ---- */
.am-trade .ustd-trade-content-root .trade-layout-row {
  gap: calc(0.25 * 100vw / 7.5);
  padding: 0;
}

.am-trade .ustd-trade-content-root .content_handicap--row {
  flex: 0 0 calc(2.635 * 100vw / 7.5) !important;
  min-width: 0 !important;
}

/* 组件内 .handicapBox 会被内容撑到 156px，溢出右列——这里收回 100% */
.am-trade .ustd-trade-content-root .content_handicap--row .handicapBox {
  width: 100% !important;
  min-width: 0;
  box-sizing: border-box;
  overflow: visible;
}

.am-trade .ustd-trade-content-root .contract-order-panel {
  flex: 1 1 auto !important;
  min-width: 0 !important;
}

/* ---- 买入 / 卖出 选项卡：参考站 .btn-buy 105x36、圆角 3.12、14.56px ---- */
.am-trade .am-side-tabs {
  display: flex !important;
  align-items: center;
  gap: calc(0.02 * 100vw / 7.5);
  height: calc(0.692 * 100vw / 7.5);
  margin-bottom: calc(0.25 * 100vw / 7.5);
}

.am-trade .am-side {
  flex: 1 1 0;
  min-width: 0;
  height: calc(0.692 * 100vw / 7.5);
  padding: 0;
  border: 0;
  border-radius: calc(0.06 * 100vw / 7.5);
  background: transparent;
  color: #868b98;
  font-size: calc(0.28 * 100vw / 7.5);
  font-weight: 400;
  line-height: calc(0.692 * 100vw / 7.5);
  text-align: center;
}

.am-trade .am-side.on {
  background: #00f0ff;
  color: #000;
}

.am-trade .am-side.sell.on {
  background: #f5354d;
  color: #fff;
}

/* ---- 可用 / 手续费 / 保证金：参考站 .textA 13.52px #868b98
   组件内 `.rightSix.rightSix-available` 为 (0,2,0)+scoped，需下沉到 .ustd-trade-content-root ---- */
.am-trade .ustd-trade-content-root .rightSix.rightSix-available,
.am-trade .ustd-trade-content-root .rightSix.ust-meta {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  min-height: calc(0.29 * 100vw / 7.5);
  color: #868b98 !important;
  font-size: calc(0.26 * 100vw / 7.5) !important;
  font-weight: 400;
}

.am-trade .ustd-trade-content-root .ust-meta__k,
.am-trade .ustd-trade-content-root .ust-meta__v {
  color: #868b98 !important;
  font-size: calc(0.26 * 100vw / 7.5) !important;
  font-weight: 400;
}

/* 可用：数值与单位同行（参考站 Available ... USDT 居右） */
.am-trade .ustd-trade-content-root .available-balance-inner {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: calc(0.12 * 100vw / 7.5);
}

.am-trade .ustd-trade-content-root .available-balance-stack {
  flex-direction: row !important;
  align-items: baseline;
  gap: calc(0.08 * 100vw / 7.5);
}

.am-trade .ustd-trade-content-root .available-balance-num,
.am-trade .ustd-trade-content-root .available-balance-unit--usdt {
  color: #868b98 !important;
  font-size: calc(0.26 * 100vw / 7.5) !important;
  font-weight: 400;
}

/* ---- 止盈止损块：参考站 .km-box（勾选在上、两输入框常驻） ---- */
.am-trade .ust-tpsl-block {
  margin: calc(0.2 * 100vw / 7.5) 0;
}

.am-trade .ustd-trade-content-root .am-check {
  display: flex;
  align-items: center;
  gap: calc(0.1 * 100vw / 7.5);
  padding: 0;
  margin: 0;
  color: #868b98 !important;
  font-size: calc(0.26 * 100vw / 7.5) !important;
  font-weight: 400;
}

/* 参考站为 .checkZyzsImg 17x17 的细线方框（截屏实测边框 78,81,89） */
.am-trade .ustd-trade-content-root .am-check input[type='checkbox'] {
  flex: 0 0 auto;
  -webkit-appearance: none;
  appearance: none;
  width: calc(0.327 * 100vw / 7.5);
  height: calc(0.327 * 100vw / 7.5);
  margin: 0;
  border: 1px solid #4e5159 !important;
  border-radius: calc(0.04 * 100vw / 7.5);
  background: transparent !important;
  outline: none;
}

.am-trade .ustd-trade-content-root .am-check input[type='checkbox']:checked {
  border-color: #00f0ff !important;
  background: #00f0ff !important;
}

/* 组件内 `.rightSix { flex: 1 }`（flex-basis:0）会把止盈/止损行压扁成内容高度，
   这里改为 0 0 auto 让 height 生效；
   参考站为 **上下两行整宽**（.price-box2 209x42 @417 / @466，行距 7px） */
.am-trade .ustd-trade-content-root .content_right.contract-order-panel .rightSix.ust-tp-inputs {
  flex: 0 0 auto !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch;
  gap: calc(0.135 * 100vw / 7.5);
  margin-top: calc(0.135 * 100vw / 7.5);
}

.am-trade .ustd-trade-content-root .content_right.contract-order-panel .ust-tp-field {
  flex: 0 0 auto !important;
  width: 100%;
  min-width: 0;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  height: calc(0.808 * 100vw / 7.5) !important;
  box-sizing: border-box;
  /* 参考站：输入框 146px @x26、单位 USDT @x175，左右内边距 10px */
  padding: 0 calc(0.192 * 100vw / 7.5);
  border-radius: calc(0.06 * 100vw / 7.5);
  background: #2b2b3c !important;
}

.am-trade .ustd-trade-content-root .ust-tp-input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  background: transparent;
  color: #fff !important;
  font-size: calc(0.28 * 100vw / 7.5) !important;
}

.am-trade .ustd-trade-content-root .ust-tp-unit {
  flex: 0 0 auto;
  color: #e0e0e0 !important;
  font-size: calc(0.28 * 100vw / 7.5) !important;
}

/* ---- 仓位百分比：真实滑竿 —— 细轨道（青色填充/浅灰剩余）+ 大号青色圆形滑块
   + 25/50/75/100 位置灰色刻度圆点 ---- */
.am-trade .am-tr-slider.ust-pct.ust-range {
  height: auto;
  margin: calc(0.31 * 100vw / 7.5) 0 calc(0.29 * 100vw / 7.5);
}

.am-trade .ust-range-wrap {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  height: calc(0.42 * 100vw / 7.5);
}

/* 轨道由独立 div 绘制（4px 圆角条，青色填充由 sliderTrackStyle 内联控制），
   input 保持透明、高度与滑块一致，滑块由浏览器自动垂直居中 */
.am-trade .ust-range-wrap .ust-range-track {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: calc(0.075 * 100vw / 7.5);
  border-radius: calc(0.075 * 100vw / 7.5);
  background: #f0f0f0;
  transform: translateY(-50%);
  pointer-events: none;
}

.am-trade .ust-range-wrap input[type='range'] {
  -webkit-appearance: none !important;
  appearance: none !important;
  position: relative;
  z-index: 2;
  display: block;
  /* 原生 thumb 行程会被自身半径内缩，这里左右各外扩一个半径，
     使 thumb 中心恰好走完 0% → 100% 整条轨道（否则永远差 8px 到不了最右） */
  flex: 0 0 auto;
  width: calc(100% + 0.31 * 100vw / 7.5);
  height: calc(0.31 * 100vw / 7.5);
  margin: 0 calc(-0.155 * 100vw / 7.5);
  padding: 0;
  border: 0;
  border-radius: 0;
  outline: none;
  background: transparent;
}

.am-trade .ust-range-wrap input[type='range']::-webkit-slider-thumb {
  -webkit-appearance: none !important;
  appearance: none !important;
  width: calc(0.31 * 100vw / 7.5);
  height: calc(0.31 * 100vw / 7.5);
  margin: 0;
  border: 0;
  border-radius: 50%;
  background: #00f0ff;
  box-shadow: none;
  cursor: pointer;
}

.am-trade .ust-range-wrap input[type='range']::-moz-range-thumb {
  width: calc(0.31 * 100vw / 7.5);
  height: calc(0.31 * 100vw / 7.5);
  border: 0;
  border-radius: 50%;
  background: #00f0ff;
  cursor: pointer;
}

.am-trade .ust-range-wrap input[type='range']::-moz-range-track {
  height: calc(0.075 * 100vw / 7.5);
  border-radius: calc(0.075 * 100vw / 7.5);
  background: transparent;
}

/* 刻度圆点：25/50/75/100，与轨道同色（#f0f0f0）——这样即使被青色填充/滑块覆盖区域
   也能看清；层级高于 input，拖动到任意位置都不会被滑块挡住。
   注意必须 pointer-events:none：0% 刻度正好压在滑块初始位置上，若可点击会吞掉
   mousedown，导致滑块（尤其初始状态）完全拖不动；点击跳转由原生 input 轨道点击完成 */
.am-trade .ust-range-wrap .ust-range-dot {
  position: absolute;
  top: 50%;
  /* z-index 高于 input：刻度永远画在滑块之上（初始位置第一个刻度被滑块压住时也不丢失） */
  z-index: 4;
  width: calc(0.23 * 100vw / 7.5);
  height: calc(0.23 * 100vw / 7.5);
  border-radius: 50%;
  /* 未选中：目标站 .kedu 为 #d4d4d4（比轨道 #f0f0f0 略深一级，浅底色上清晰可见） */
  background: #d4d4d4;
  transform: translate(-50%, -50%);
  transition: background-color 0.15s linear;
  pointer-events: none;
}

/* 滑块刮过的刻度：变成与滑块同一抹青色 #00f0ff（0% 那一格初始即满足，所以首刻度常青） */
.am-trade .ust-range-wrap .ust-range-dot--passed {
  background: #00f0ff;
}

/* ---- 下拉行：参考站 .price-box / .ggBox 为 42px 高、圆角 3.12 ---- */
.am-trade .ustd-trade-content-root .contract-order-panel .entrustSelect,
.am-trade .ustd-trade-content-root .contract-order-panel .entrustSelect2 {
  height: calc(0.808 * 100vw / 7.5) !important;
  box-sizing: border-box;
  border-radius: calc(0.06 * 100vw / 7.5);
  color: #fff !important;
}

/* 参考站 .price-box/.ggBox 为实心 #2b2b3c（截屏实测），组件内
   `background: transparent !important` 特异性 (0,5,0)，这里再深一层压过 */
.am-trade
  .ustd-trade-content-root
  .content_right.contract-order-panel
  .rightFirst
  .entrustSelect.spot-shell {
  background: #2b2b3c !important;
  border-color: transparent !important;
}

/* 委托方式 / 杠杆文案：参考站 .price 14.56px、.gg 13.52px。
   组件模板内原为内联 `font-size:12px !important`，已改为 .ustd-sel-txt 类 */
.am-trade .ustd-sel-txt {
  font-weight: 400;
}

.am-trade .ustd-sel-txt--lg {
  font-size: calc(0.28 * 100vw / 7.5) !important;
}

.am-trade .ustd-sel-txt--sm {
  font-size: calc(0.26 * 100vw / 7.5) !important;
}

/* 杠杆格：参考站 .ggBox 76x42，内容居中（左右各留 17px，含箭头 13px） */
.am-trade
  .ustd-trade-content-root
  .contract-order-panel
  .entrustSelect2.ustd-field-tap--center {
  padding: 0 calc(0.327 * 100vw / 7.5) !important;
  justify-content: center !important;
}

/* 委托方式 + 杠杆 一行两列：参考站 126 / 76，间隙 6px */
.am-trade .ustd-trade-content-root .contract-order-panel .rightFirst.ustd-split-row {
  /* 组件内 `.content_right .rightFirst { height: 33px }` 会把 42px 的下拉挤出容器 */
  height: calc(0.808 * 100vw / 7.5) !important;
  margin-top: 0 !important;
  gap: calc(0.115 * 100vw / 7.5);
}

.am-trade .ustd-trade-content-root .contract-order-panel .rightFirst .firstItem {
  height: 100% !important;
}

.am-trade .ustd-trade-content-root .contract-order-panel .ustd-split-row__grow {
  flex: 1 1 auto !important;
  min-width: 0;
}

.am-trade .ustd-trade-content-root .contract-order-panel .ustd-split-row__lever {
  flex: 0 0 calc(1.462 * 100vw / 7.5) !important;
}

/* ---- 价格行：参考站 .sjBox 209x42，文案居中 14.56px #aaa ---- */
.am-trade
  .ustd-trade-content-root
  .contract-order-panel
  .rightThird.spot-shell--hint {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: calc(0.808 * 100vw / 7.5) !important;
  margin-top: calc(0.135 * 100vw / 7.5) !important;
  border-radius: calc(0.06 * 100vw / 7.5);
  /* 参考站 .sjBox 为实心 #2b2b3c（截屏实测），不描边 */
  background: #2b2b3c !important;
  border-color: transparent !important;
  color: #aaa !important;
  font-size: calc(0.28 * 100vw / 7.5) !important;
  font-weight: 400;
}

/* ---- 数量行：参考站 .num-box 209x42；输入框 146px @x26 + 右侧 19x19 步进 ---- */
.am-trade .ustd-trade-content-root .contract-order-panel .rightFifth {
  margin-top: calc(0.135 * 100vw / 7.5) !important;
}

.am-trade .ustd-trade-content-root .contract-order-panel .rightFifth .amount.spot-shell {
  height: calc(0.808 * 100vw / 7.5) !important;
  padding: 0 calc(0.192 * 100vw / 7.5) !important;
  gap: calc(0.096 * 100vw / 7.5);
  justify-content: flex-start !important;
  border-radius: calc(0.06 * 100vw / 7.5);
  /* 参考站 .num-box 为实心 #2b2b3c（截屏实测） */
  background: #2b2b3c !important;
  border-color: transparent !important;
}

.am-trade
  .ustd-trade-content-root
  .contract-order-panel
  .rightFifth
  .spot-amount-input {
  flex: 1 1 auto;
  height: calc(0.31 * 100vw / 7.5) !important;
  line-height: calc(0.31 * 100vw / 7.5);
  font-size: calc(0.28 * 100vw / 7.5) !important;
  color: #fff !important;
  text-align: left;
}

/* 参考站占位文字 #aaa（截屏实测 170,170,170） */
.am-trade
  .ustd-trade-content-root
  .contract-order-panel
  .rightFifth
  .spot-amount-input::placeholder,
.am-trade .ustd-trade-content-root .contract-order-panel .ust-tp-input::placeholder {
  color: #aaaaaa !important;
  opacity: 1;
}

/* 通用步进按钮：清掉 <button> 原生底色（buttonface，深色面板上呈现为白色底块/边框）。
   合约页原本只有带 .ustd-trade-content-root 前缀的规则，现货页吃不到，故提升为通用。 */
.am-trade .am-step {
  flex: 0 0 calc(0.365 * 100vw / 7.5);
  display: flex;
  align-items: center;
  justify-content: center;
  width: calc(0.365 * 100vw / 7.5);
  height: calc(0.365 * 100vw / 7.5);
  padding: 0;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none;
  line-height: 1;
  appearance: none;
  -webkit-appearance: none;
}

.am-trade .ustd-trade-content-root .contract-order-panel .rightFifth .am-step {
  flex: 0 0 calc(0.365 * 100vw / 7.5);
  display: flex;
  align-items: center;
  justify-content: center;
  width: calc(0.365 * 100vw / 7.5);
  height: calc(0.365 * 100vw / 7.5);
  padding: 0;
  border: 0;
  background: transparent;
  line-height: 1;
}

/* ---- 数量输入框步进按钮：-/+ 图标换为 public/minus.png、public/add.png ---- */
.am-trade .am-step .am-step__icon {
  display: block;
  width: calc(0.365 * 100vw / 7.5);
  height: calc(0.365 * 100vw / 7.5);
  -webkit-user-drag: none;
  user-select: none;
  pointer-events: none;
}

/* ---- 行间距：严格按参考站实测 gap 重排 ----
   tabs→委托 13 | 委托→价格 7 | 价格→数量 7 | 数量→可开 13
   可开→百分比 16 | 百分比→TP/SL 15 | 勾选→止盈 7 | 止盈→止损 7
   止损→可用 10 | 可用→手续费 11 | 手续费→保证金 10 | 保证金→按钮 16 */
.am-trade .ustd-trade-content-root .contract-order-panel .am-openable {
  margin-top: calc(0.25 * 100vw / 7.5);
}

/* 参考站间隔：百分比标签底 → TP/SL 15px。本地 .ust-pct 已有 15.08 的下外边距，
   这里不能再叠加，否则整块下移 15px */
.am-trade .ustd-trade-content-root .contract-order-panel .ust-tpsl-block {
  margin: 0;
}

.am-trade .ustd-trade-content-root .contract-order-panel .ust-contract-meta-group {
  margin-top: calc(0.192 * 100vw / 7.5);
}

/* 参考站：TP/SL 块底 → 可用 11px；本地块高 115 含 1px 溢出，取 9px 令落点与 518 对齐 */
.am-trade .ustd-trade-content-root .contract-order-panel .rightSix.rightSix-available {
  margin-top: calc(0.173 * 100vw / 7.5) !important;
  min-height: calc(0.288 * 100vw / 7.5);
}

/* 参考站 .km-box 三行资金信息均为 15px 高；组件内 `.rightSix { flex: 1 }`
   会让 flex-basis:0 盖掉 height，这里先取消弹性再定高。
   注意组件内存在 `.content_right.contract-order-panel .ust-contract-meta-group
   .rightSix.ust-meta[data-v]` (0,6,0) 的 min-height，必须再下沉一层 */
.am-trade
  .ustd-trade-content-root
  .contract-order-panel
  .ust-contract-meta-group
  .rightSix.ust-meta {
  flex: none !important;
  height: calc(0.288 * 100vw / 7.5) !important;
  min-height: calc(0.288 * 100vw / 7.5) !important;
}

.am-trade .ustd-trade-content-root .contract-order-panel .rightSix.ust-meta > * {
  line-height: calc(0.288 * 100vw / 7.5) !important;
}

/* 参考站可用行只有「可用 + 数值单位」，无充值加号 */
.am-trade
  .ustd-trade-content-root
  .contract-order-panel
  .rightSix-available
  .addIcon {
  display: none !important;
}

.am-trade .ustd-trade-content-root .contract-order-panel .rightSix.ust-meta--mb {
  margin-top: calc(0.25 * 100vw / 7.5) !important;
}

.am-trade .ustd-trade-content-root .contract-order-panel .rightSeven {
  margin-top: calc(0.31 * 100vw / 7.5) !important;
}

/* ---- 可开仓：参考站 .km-box.flex-b 12.48px #868b98，两端对齐 ---- */
.am-trade .am-openable {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  color: #868b98;
  font-size: calc(0.24 * 100vw / 7.5);
  font-weight: 400;
}

/* ---- 主按钮：参考站 .btn-buy2 209x42、圆角 3.12、#00f0ff 黑字 ---- */
.am-trade .ustd-trade-content-root .content_right.contract-order-panel .rightSeven .maybutton {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: calc(0.808 * 100vw / 7.5) !important;
  border: 0;
  border-radius: calc(0.06 * 100vw / 7.5) !important;
  background: #00f0ff !important;
  font-size: calc(0.28 * 100vw / 7.5);
  font-weight: 400;
}

.am-trade .ustd-trade-content-root .content_right.contract-order-panel .rightSeven .maybutton.hightColorRed {
  background: #f5354d !important;
}

.am-trade .ustd-trade-content-root .content_right.contract-order-panel .maybutton__txt {
  color: #000 !important;
}

.am-trade
  .ustd-trade-content-root
  .content_right.contract-order-panel
  .maybutton.hightColorRed
  .maybutton__txt {
  color: #fff !important;
}

/* ---- 盘口：表头 Price(USDT) / Quantity(BTC) 12.48px #868b98 ---- */
.am-trade .ustd-trade-content-root .handicapBox .title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  height: calc(0.54 * 100vw / 7.5);
  margin-bottom: calc(0.25 * 100vw / 7.5);
}

.am-trade .ustd-trade-content-root .handicapBox .title_left,
.am-trade .ustd-trade-content-root .handicapBox .title_right {
  color: #868b98;
  font-size: calc(0.24 * 100vw / 7.5);
  font-weight: 400;
  line-height: 1.15;
}

.am-trade .ustd-trade-content-root .handicapBox .title_right {
  text-align: right;
}

.am-trade .ustd-trade-content-root .handicapBox .title .name,
.am-trade .ustd-trade-content-root .handicapBox .title .unit {
  color: #868b98 !important;
  font-size: calc(0.24 * 100vw / 7.5) !important;
  font-weight: 400 !important;
}

/* 盘口行：卖盘（上）青、买盘（下）红 —— 与参考站 .scroll/.scroll2 一致
   注：组件内 .fall/.rise/.itemName/.hightItem 均带 !important 且嵌套 5 层，
   这里必须带上 .leftList/.item 保证特异性（0,8,0）压过组件 scoped 规则 */
.am-trade .ustd-trade-content-root .handicapBox .leftList .itemList.asks .item .fall {
  color: #00f0ff !important;
  font-size: calc(0.26 * 100vw / 7.5);
  font-weight: 400;
}

.am-trade .ustd-trade-content-root .handicapBox .leftList .itemList .item.itemHight .rise {
  color: #ff4834 !important;
  font-size: calc(0.26 * 100vw / 7.5);
  font-weight: 400;
}

.am-trade .ustd-trade-content-root .handicapBox .leftList .itemList .item .itemName {
  color: #fff !important;
  font-size: calc(0.26 * 100vw / 7.5);
  font-weight: 400;
  text-align: right;
}

/* 深度条：卖 rgba(0,240,255,.8) / 买 rgba(255,72,52,.8) */
.am-trade .ustd-trade-content-root .handicapBox .leftList .itemList.asks .item .hightItem {
  background: rgba(0, 240, 255, 0.8) !important;
}

.am-trade
  .ustd-trade-content-root
  .handicapBox
  .leftList
  .itemList
  .item.itemHight
  .hightItem {
  background: rgba(255, 72, 52, 0.8) !important;
}

/* 参考站每侧 7 行、.item-li 26px 且行间无间隙（182 = 7 × 26） */
.am-trade .ustd-trade-content-root .handicapBox .leftList .itemList {
  gap: 0 !important;
}

/* 组件内为底部下拉预留的 22px 内边距：本页下拉已在 .leftList 之外，需清掉 */
.am-trade .ustd-trade-content-root .handicapBox .leftList {
  padding-bottom: 0 !important;
}

/* 中间最新价：参考站 .centerBox 41px（20 + 6 + 15），无上下内边距；
   上下各留 18px 与买卖盘分隔（参考站 337→355、396→414） */
.am-trade .ustd-trade-content-root .handicapBox .itemCenter {
  padding: 0 !important;
  margin: calc(0.346 * 100vw / 7.5) 0 !important;
}

/* 参考站 .item-li 26px，组件内 .item 为 min-height:24 + padding:2 */
.am-trade .ustd-trade-content-root .handicapBox .leftList .itemList .item {
  height: calc(0.5 * 100vw / 7.5) !important;
  min-height: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}

/* 参考站 .centerBox .font-32：16.64px 加粗 */
.am-trade .ustd-trade-content-root .handicapBox .centername {
  font-size: calc(0.32 * 100vw / 7.5) !important;
  font-weight: 700 !important;
  text-align: center;
}

/* 中间最新价随涨跌着色。这里用的是 _isRFD2 产出的 rise2/fall2，
   需压过全局 `.rise2 { color: var(--ex-rfd-rise) !important }` / `.fall2` */
.am-trade .ustd-trade-content-root .handicapBox .centername.rise,
.am-trade .ustd-trade-content-root .handicapBox .centername.rise2 {
  color: #00f0ff !important;
}

/* 中间价跌色为参考站 .c-f23249（实测 rgb(242,50,73)），与盘口跌色 #ff4834 不同 */
.am-trade .ustd-trade-content-root .handicapBox .centername.fall,
.am-trade .ustd-trade-content-root .handicapBox .centername.fall2 {
  color: #f23249 !important;
}

.am-trade .ustd-trade-content-root .handicapBox .center-usd-approx {
  margin-top: calc(0.115 * 100vw / 7.5);
  color: #868b98 !important;
  font-size: calc(0.25 * 100vw / 7.5) !important;
  font-weight: 400;
  text-align: center;
}

/* 底部下拉容器：参考站 .flex-b.mt-20 137x39@607，与买盘末行间隔 11px */
.am-trade .ustd-trade-content-root .handicapBox .leftBottom {
  margin-top: calc(0.212 * 100vw / 7.5) !important;
  height: calc(0.75 * 100vw / 7.5);
}

/* 底部 0.01 下拉：参考站 .jdBox 90x35、底 #2b2b3c */
.am-trade .ustd-trade-content-root .handicapBox .jdBox {
  height: calc(0.67 * 100vw / 7.5);
  padding: 0 calc(0.16 * 100vw / 7.5);
  border-radius: calc(0.06 * 100vw / 7.5);
  background: #2b2b3c;
  color: #fff;
  font-size: calc(0.26 * 100vw / 7.5);
}

/* ---- 下方持仓区 Tab：参考站 .van-tab 79/105/121 宽、44 高、14px ----
   参考站买入按钮底 642 → .tabNewBox 677，间隔 35px */
.am-trade .contract-order-box .spot-order-tabs-head {
  padding-left: 0;
  padding-right: 0;
  margin-top: calc(0.462 * 100vw / 7.5);
}

/* 参考站 .van-tabs 起点被负外边距推到 x=-3，首个 .van-tab 落在 x=5；
   这里让本地首个 Tab 同样落在 x=5，并去掉 Tab 之间的间隙 */
.am-trade .contract-order-box .spot-order-tabs-row {
  display: flex;
  align-items: center;
  gap: 0;
  margin-left: calc(-0.212 * 100vw / 7.5);
}

.am-trade .contract-order-tab {
  position: relative;
  height: calc(0.846 * 100vw / 7.5);
  padding: 0 calc(0.25 * 100vw / 7.5) calc(0.1 * 100vw / 7.5) !important;
  border: 0;
  border-bottom: 3px solid transparent !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #8d8d96 !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  line-height: 1.5;
}

.am-trade .contract-order-tab.is-active {
  color: #fff !important;
  font-weight: 700 !important;
  border-bottom-color: #00f0ff !important;
}

/* 组件内为 `.spot-order-refresh :deep(.entrustRUpdateImg)` (0,3,0) + !important，
   这里需再下沉一层到 .contract-order-box 才能压过 */
.am-trade .contract-order-box .spot-order-refresh .entrustRUpdateImg,
.am-trade .sc-order__refresh .entrustRUpdateImg {
  color: #00f0ff !important;
  font-size: 20px !important;
}

/* 空态：沿用 empty.svg 图标 */
.am-trade .sc-order__empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 60px 0 40px;
  text-align: center;
  color: #8d8d96;
  font-size: 14px;
}

.am-trade .sc-order__empty-icon {
  width: 94px;
  height: 70px;
  opacity: 0.9;
}
