/* =========================================================
   CoinASX V91 - 首页交易所风格行情
   主题颜色尽量继承现有站点，新增层不阻挡原功能
   ========================================================= */

.cx91-mini-market,
.cx91-market-shell,
.cx91-announcements{
  --cx91-bg:var(--bg,#0a0a0b);
  --cx91-panel:var(--panel,#171718);
  --cx91-text:var(--text,#f5f5f5);
  --cx91-muted:var(--muted,#8f9299);
  --cx91-up:var(--green,#10c79a);
  --cx91-down:var(--red,#ff4d57);
  color:var(--cx91-text);
}

/* ---------- 快捷功能下面4个小卡片 ---------- */
.cx91-mini-market{
  margin:22px 16px 26px;
}

.cx91-mini-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}

.cx91-mini-card{
  min-height:94px;
  padding:15px 14px 13px;
  border-radius:15px;
  background:var(--cx91-panel);
  position:relative;
  overflow:hidden;
}

.cx91-mini-title{
  display:flex;
  align-items:center;
  gap:7px;
  font-size:14px;
  line-height:20px;
  font-weight:800;
}

.cx91-mini-title small{
  color:var(--cx91-muted);
  font-size:12px;
  font-weight:700;
}

.cx91-mini-price{
  margin-top:16px;
  font-size:20px;
  line-height:24px;
  font-weight:800;
  letter-spacing:.1px;
}

.cx91-mini-change{
  margin-left:6px;
  font-size:13px;
  font-weight:800;
}

.cx91-up{color:var(--cx91-up)!important}
.cx91-down{color:var(--cx91-down)!important}

.cx91-spark{
  position:absolute;
  right:12px;
  bottom:15px;
  width:62px;
  height:27px;
  opacity:.95;
}

.cx91-spark svg{
  width:100%;
  height:100%;
  overflow:visible;
}

.cx91-spark polyline{
  fill:none;
  stroke:currentColor;
  stroke-width:2.2;
  stroke-linecap:round;
  stroke-linejoin:round;
}

/* ---------- 行情主体 ---------- */
.cx91-market-shell{
  margin:4px 16px 0;
}

.cx91-tabs{
  display:flex;
  align-items:center;
  gap:25px;
  overflow-x:auto;
  white-space:nowrap;
  scrollbar-width:none;
  padding:2px 0 13px;
}

.cx91-tabs::-webkit-scrollbar{display:none}

.cx91-tab{
  position:relative;
  flex:0 0 auto;
  border:0;
  padding:7px 0 10px;
  background:transparent;
  color:var(--cx91-muted);
  font-size:16px;
  line-height:20px;
  font-weight:800;
  cursor:pointer;
  -webkit-tap-highlight-color:transparent;
}

.cx91-tab.active{
  color:var(--cx91-text);
}

.cx91-tab.active:after{
  content:"";
  position:absolute;
  left:50%;
  bottom:0;
  width:24px;
  height:3px;
  border-radius:3px;
  background:currentColor;
  transform:translateX(-50%);
}

/* 自选时：原卡片容器继续使用 */
.cx91-watch-slot{
  margin-top:4px;
}

/* 列表模式 */
.cx91-list{
  display:none;
  margin-top:2px;
}

.cx91-market-shell[data-mode="watch"] .cx91-list{
  display:none;
}

.cx91-market-shell:not([data-mode="watch"]) .cx91-watch-slot{
  display:none!important;
}

.cx91-market-shell:not([data-mode="watch"]) .cx91-list{
  display:block;
}

.cx91-list-head,
.cx91-row{
  display:grid;
  grid-template-columns:minmax(0,1.45fr) minmax(90px,.8fr) minmax(82px,.62fr);
  align-items:center;
  column-gap:10px;
}

.cx91-list-head{
  min-height:40px;
  color:var(--cx91-muted);
  font-size:12px;
  font-weight:700;
}

.cx91-list-head > :nth-child(2),
.cx91-list-head > :nth-child(3){
  text-align:right;
}

.cx91-row{
  min-height:78px;
  border-bottom:1px solid rgba(128,128,128,.10);
}

.cx91-symbol{
  min-width:0;
}

.cx91-symbol-main{
  display:flex;
  align-items:center;
  gap:7px;
  min-width:0;
  font-size:16px;
  line-height:21px;
  font-weight:800;
}

.cx91-symbol-main b{
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.cx91-tag{
  flex:0 0 auto;
  padding:3px 6px;
  border-radius:6px;
  background:rgba(128,128,128,.14);
  color:var(--cx91-muted);
  font-size:10px;
  font-weight:700;
}

.cx91-volume{
  margin-top:5px;
  color:var(--cx91-muted);
  font-size:12px;
  font-weight:600;
}

.cx91-price{
  text-align:right;
}

.cx91-price-main{
  font-size:16px;
  line-height:21px;
  font-weight:800;
}

.cx91-price-sub{
  margin-top:4px;
  color:var(--cx91-muted);
  font-size:11px;
}

.cx91-change-box{
  justify-self:end;
  min-width:76px;
  padding:10px 8px;
  border-radius:9px;
  text-align:center;
  font-size:15px;
  line-height:20px;
  font-weight:800;
}

.cx91-change-box.up{
  color:var(--cx91-up);
  background:color-mix(in srgb,var(--cx91-up) 10%,transparent);
}

.cx91-change-box.down{
  color:var(--cx91-down);
  background:color-mix(in srgb,var(--cx91-down) 10%,transparent);
}

/* ---------- 公告 ---------- */
.cx91-announcements{
  margin:30px 16px 105px;
  padding-top:4px;
}

.cx91-ann-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:9px;
}

.cx91-ann-head h3{
  font-size:20px;
  font-weight:850;
}

.cx91-ann-more{
  color:var(--cx91-muted);
  font-size:22px;
}

.cx91-ann-item{
  display:block;
  padding:15px 0;
  border-bottom:1px solid rgba(128,128,128,.10);
  color:inherit;
  text-decoration:none;
}

.cx91-ann-title{
  font-size:14px;
  line-height:21px;
  font-weight:750;
}

.cx91-ann-time{
  margin-top:5px;
  color:var(--cx91-muted);
  font-size:12px;
}

/* 浅色主题兜底 */
html.light .cx91-mini-market,
html.light .cx91-market-shell,
html.light .cx91-announcements,
body.light .cx91-mini-market,
body.light .cx91-market-shell,
body.light .cx91-announcements,
[data-theme="light"] .cx91-mini-market,
[data-theme="light"] .cx91-market-shell,
[data-theme="light"] .cx91-announcements{
  --cx91-panel:#f4f5f7;
  --cx91-text:#111318;
  --cx91-muted:#858a94;
}

/* 禁止新增区域行情刷新时闪动 */
.cx91-mini-card,
.cx91-row{
  animation:none!important;
  transition:background-color .15s ease,color .15s ease!important;
}

@media(max-width:360px){
  .cx91-mini-market,
  .cx91-market-shell,
  .cx91-announcements{
    margin-left:12px;
    margin-right:12px;
  }

  .cx91-mini-card{
    min-height:88px;
    padding:13px 11px;
  }

  .cx91-mini-price{font-size:18px}
  .cx91-tabs{gap:20px}
  .cx91-tab{font-size:15px}

  .cx91-list-head,
  .cx91-row{
    grid-template-columns:minmax(0,1.3fr) minmax(82px,.76fr) minmax(72px,.6fr);
    column-gap:7px;
  }

  .cx91-symbol-main{font-size:14px}
  .cx91-price-main{font-size:14px}
  .cx91-change-box{min-width:69px;font-size:14px}
}
