/* WXSSC V68.6-I3 flash-news terminal toolbar
   Visual only. Keep existing DOM / IDs / SSE / filters.
*/

:root{
  --wx-i3-blue:#2563eb;
  --wx-i3-blue-soft:#eff6ff;
  --wx-i3-red:#e11d48;
  --wx-i3-gold:#b7791f;
  --wx-i3-text:#0f172a;
  --wx-i3-muted:#64748b;
  --wx-i3-line:#e8eef7;
  --wx-i3-bg:#f8fbff;
}

/* 主卡片顶部：分类行 + 控制行整体更像交易终端 */
html body .wx55-main{
  background:#fff !important;
  border:1px solid rgba(148,163,184,.16) !important;
  border-radius:14px !important;
  overflow:hidden !important;
  box-shadow:0 8px 22px rgba(15,23,42,.045) !important;
}

/* 第一行：分类标签栏 */
html body .wx55-main .wx55-tabs[data-wx55-tabs]{
  position:sticky !important;
  top:72px !important;
  z-index:18 !important;
  display:flex !important;
  flex-wrap:wrap !important;
  align-items:center !important;
  gap:7px !important;
  min-height:46px !important;
  height:auto !important;
  padding:7px 14px 6px !important;
  background:linear-gradient(180deg,#ffffff,#fbfdff) !important;
  border-bottom:1px solid var(--wx-i3-line) !important;
  box-shadow:0 1px 0 rgba(255,255,255,.7) inset !important;
  overflow:visible !important;
}

/* 分类按钮统一为交易终端 chip */
html body .wx55-main .wx55-tab,
html body .wx55-main .wx55-chip{
  position:relative !important;
  flex:0 0 auto !important;
  height:30px !important;
  min-height:30px !important;
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  padding:0 12px !important;
  border-radius:999px !important;
  border:1px solid rgba(148,163,184,.20) !important;
  background:#f8fafc !important;
  color:#475569 !important;
  font-size:12px !important;
  font-weight:900 !important;
  line-height:1 !important;
  letter-spacing:0 !important;
  box-shadow:none !important;
  white-space:nowrap !important;
}

html body .wx55-main .wx55-tab.active,
html body .wx55-main .wx55-tab.is-active,
html body .wx55-main .wx55-tab[aria-selected="true"]{
  background:linear-gradient(135deg,#2563eb,#1d4ed8) !important;
  color:#fff !important;
  border-color:rgba(37,99,235,.70) !important;
  box-shadow:0 8px 16px rgba(37,99,235,.16) !important;
}

html body .wx55-main .wx55-chip{
  background:#fff7fb !important;
  color:#be123c !important;
  border-color:rgba(225,29,72,.14) !important;
}

html body .wx55-main .wx55-chip.active,
html body .wx55-main .wx55-chip.is-active,
html body .wx55-main .wx55-chip[aria-selected="true"]{
  background:#fff1f2 !important;
  color:#be123c !important;
  border-color:rgba(225,29,72,.28) !important;
  box-shadow:0 8px 16px rgba(225,29,72,.10) !important;
}

html body .wx55-main .wx55-tab.active:after,
html body .wx55-main .wx55-tab.is-active:after,
html body .wx55-main .wx55-tab[aria-selected="true"]:after{
  display:none !important;
}

/* 第二行：日期 + 重要开关 + 搜索 + 语音/自动/刷新 */
html body .wx55-tools{
  position:sticky !important;
  top:118px !important;
  z-index:17 !important;
  height:auto !important;
  min-height:42px !important;
  padding:6px 14px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:space-between !important;
  gap:12px !important;
  background:rgba(255,255,255,.96) !important;
  backdrop-filter:blur(10px) !important;
  border-bottom:1px solid var(--wx-i3-line) !important;
  box-shadow:0 8px 18px rgba(15,23,42,.035) !important;
}

html body .wx55-date{
  flex:0 0 auto !important;
  display:flex !important;
  align-items:center !important;
  gap:12px !important;
  min-width:0 !important;
  color:#334155 !important;
  font-size:13px !important;
  font-weight:900 !important;
  white-space:nowrap !important;
}

html body #wx55Date{
  display:inline-flex !important;
  align-items:center !important;
  height:28px !important;
  padding:0 10px !important;
  border-radius:999px !important;
  background:#f8fafc !important;
  border:1px solid rgba(148,163,184,.18) !important;
  color:#334155 !important;
  font-size:13px !important;
  font-weight:950 !important;
}

html body .wx55-check{
  height:28px !important;
  display:inline-flex !important;
  align-items:center !important;
  gap:6px !important;
  padding:0 10px !important;
  border-radius:999px !important;
  background:#fff !important;
  border:1px solid rgba(148,163,184,.18) !important;
  color:#64748b !important;
  font-size:12px !important;
  font-weight:850 !important;
  white-space:nowrap !important;
}

html body .wx55-check input{
  width:14px !important;
  height:14px !important;
  margin:0 !important;
  accent-color:var(--wx-i3-blue) !important;
}

/* 右侧工具组 */
html body .wx55-righttools{
  flex:1 1 auto !important;
  min-width:0 !important;
  display:flex !important;
  align-items:center !important;
  justify-content:flex-end !important;
  gap:7px !important;
}

html body .wx55-search{
  flex:1 1 260px !important;
  width:auto !important;
  max-width:300px !important;
  min-width:220px !important;
  height:30px !important;
  padding:0 13px 0 32px !important;
  border-radius:999px !important;
  border:1px solid rgba(148,163,184,.22) !important;
  background:
    linear-gradient(90deg,rgba(37,99,235,.08),rgba(37,99,235,.08)) left 11px center / 10px 10px no-repeat,
    #f8fafc !important;
  color:#0f172a !important;
  font-size:12px !important;
  font-weight:800 !important;
  outline:none !important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.80) !important;
}

html body .wx55-search::placeholder{
  color:#94a3b8 !important;
  font-weight:760 !important;
}

html body .wx55-search:focus{
  border-color:rgba(37,99,235,.44) !important;
  background-color:#fff !important;
  box-shadow:0 0 0 3px rgba(37,99,235,.08) !important;
}

/* 工具按钮统一 */
html body .wx55-btn{
  flex:0 0 auto !important;
  height:30px !important;
  min-width:0 !important;
  padding:0 11px !important;
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  border-radius:999px !important;
  border:1px solid rgba(148,163,184,.18) !important;
  background:#f8fafc !important;
  color:#475569 !important;
  font-size:12px !important;
  font-weight:900 !important;
  line-height:1 !important;
  white-space:nowrap !important;
  box-shadow:none !important;
}

html body .wx55-btn:hover{
  border-color:rgba(37,99,235,.26) !important;
  color:var(--wx-i3-blue) !important;
  background:#fff !important;
}

html body #wx55Voice{
  background:#f8fafc !important;
}

html body #wx55Voice:before{
  content:"";
  width:7px;
  height:7px;
  border-radius:50%;
  margin-right:6px;
  background:#94a3b8;
}

html body #wx55Auto{
  color:#2563eb !important;
  background:#eff6ff !important;
  border-color:rgba(37,99,235,.18) !important;
}

html body #wx55Auto:before{
  content:"";
  width:7px;
  height:7px;
  border-radius:50%;
  margin-right:6px;
  background:#22c55e;
  box-shadow:0 0 0 4px rgba(34,197,94,.12);
}

html body #wx55Auto:not(.is-on){
  color:#64748b !important;
  background:#f8fafc !important;
}

html body #wx55Auto:not(.is-on):before{
  background:#94a3b8;
  box-shadow:none;
}

html body #wx55Refresh.wx55-btn,
html body .wx55-btn.primary{
  background:linear-gradient(135deg,#2563eb,#1d4ed8) !important;
  color:#fff !important;
  border-color:rgba(37,99,235,.70) !important;
  box-shadow:0 8px 16px rgba(37,99,235,.16) !important;
}

/* 新消息条继续轻量，不抢主信息流 */
html body .wx55-newbar{
  height:28px !important;
  min-height:28px !important;
  line-height:28px !important;
  padding:0 12px !important;
  color:#2563eb !important;
  background:linear-gradient(90deg,rgba(37,99,235,.06),rgba(14,165,233,.045)) !important;
  border-top:1px solid rgba(37,99,235,.08) !important;
  border-bottom:1px solid rgba(37,99,235,.08) !important;
  font-size:12px !important;
  font-weight:850 !important;
  text-align:center !important;
}

/* 与列表衔接：工具栏之后第一条更紧凑 */
html body .wx55-feed{
  border-top:0 !important;
}

/* 中等屏：保持双行，不挤爆 */
@media(max-width:1100px){
  html body .wx55-tools{
    align-items:stretch !important;
    flex-direction:column !important;
    gap:7px !important;
  }

  html body .wx55-date,
  html body .wx55-righttools{
    width:100% !important;
  }

  html body .wx55-righttools{
    justify-content:flex-start !important;
    flex-wrap:wrap !important;
  }

  html body .wx55-search{
    max-width:none !important;
    min-width:220px !important;
    flex:1 1 280px !important;
  }
}

/* 手机：简化为纵向工具栏 */
@media(max-width:760px){
  html body .wx55-main .wx55-tabs[data-wx55-tabs]{
    top:72px !important;
    padding:7px 10px !important;
    gap:6px !important;
  }

  html body .wx55-tools{
    top:auto !important;
    position:relative !important;
    padding:8px 10px !important;
  }

  html body .wx55-date{
    flex-wrap:wrap !important;
    gap:7px !important;
  }

  html body .wx55-righttools{
    display:grid !important;
    grid-template-columns:1fr auto auto !important;
    gap:7px !important;
  }

  html body .wx55-search{
    grid-column:1 / -1 !important;
    min-width:0 !important;
    width:100% !important;
  }

  html body .wx55-btn{
    padding:0 10px !important;
  }
}
