/* ============================================
   FolloFi Mobile (≤768px) — 2026-04-27 r34
   设计原则:底 5 tab + 首页今日重点 + 大字大留白
   ============================================ */

/* 仅小屏触发(防御:link 上已经 media query,这里再保险一层) */
@media (max-width: 768px) {

/* ============ 全局 ============ */
html, body {
  font-size: 16px;
  -webkit-tap-highlight-color: transparent;
}

/* 桌面元素全 hide */
header.nav,                       /* 桌面顶 nav */
.dashboard-grid,                  /* 桌面 5 列网格 */
.market,                          /* 桌面合约表 */
.topbar,                          /* 桌面 ticker + idx */
.ticker-wrap,                     /* 桌面 ticker(老版) */
.cta,                             /* 已删,但保险 */
footer.footer { display: none !important }

body { padding-bottom: 64px /* 底 tab 高度 */ }

/* ============ Mobile 顶栏 ============ */
.m-topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 11px 14px;
  background: rgba(10,13,20,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #1e2433;
  height: 52px;
}
.m-topbar .left {
  display: flex; align-items: center; gap: 8px;
}
.m-topbar .logo svg { display: block }
.m-topbar .title {
  font-size: 17px; font-weight: 600; color: #e6edf3;
  letter-spacing: 0.2px;
}
.m-topbar .right { display: flex; gap: 4px }
.m-topbar .ico-btn {
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 10px;
  color: #c9d1d9;
  cursor: pointer; user-select: none;
}
.m-topbar .ico-btn svg { display: block }
.m-topbar .ico-btn:active { background: rgba(255,255,255,0.08) }

/* ============ Mobile 底 tab ============ */
.m-tabs {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 50;
  display: flex; justify-content: space-around;
  background: rgba(10,13,20,0.96);
  backdrop-filter: blur(14px);
  border-top: 1px solid #1e2433;
  padding: 6px 0 calc(6px + env(safe-area-inset-bottom));
  height: calc(58px + env(safe-area-inset-bottom));
}
.m-tab {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px;
  color: #6e7681;
  font-size: 11px;
  text-decoration: none;
  cursor: pointer; user-select: none;
  position: relative;
  min-height: 52px;
  -webkit-tap-highlight-color: transparent;
}
.m-tab .ico {
  width: 24px; height: 24px; line-height: 0;
  transition: transform .15s;
  display: flex; align-items: center; justify-content: center;
}
.m-tab .ico svg { display: block }
.m-tab .lbl { font-size: 11px; font-weight: 500; letter-spacing: 0.2px }
.m-tab.active { color: #00d4aa }
.m-tab.active .ico { transform: translateY(-1px) scale(1.05) }
.m-tab.active::before {
  content: ""; position: absolute; top: 0; left: 30%; right: 30%;
  height: 2px; background: #00d4aa; border-radius: 0 0 2px 2px;
}
.m-tab:active { background: rgba(0,212,170,0.06) }

/* ============ 首页"今日重点" ============ */
.m-page {
  padding: 14px 14px 20px;
  max-width: 100%;
}

/* 大盘氛围 */
.m-vibe {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 12px; margin-bottom: 16px;
}
.m-vibe-card {
  background: linear-gradient(135deg, #131823, #0e131c);
  border: 1px solid #1e2433;
  border-radius: 14px;
  padding: 16px;
  display: flex; flex-direction: column; align-items: center;
  text-align: center;
}
.m-vibe-card .lbl {
  font-size: 11.5px; color: #7d8590; margin-bottom: 8px;
  letter-spacing: 0.4px;
}
.m-vibe-card .val {
  font-size: 28px; font-weight: 700; color: #e6edf3;
  line-height: 1;
}
.m-vibe-card .tag {
  font-size: 11px; color: #7d8590; margin-top: 6px;
}
.m-vibe-card.btc .val { color: #f5a524 }
.m-vibe-card.fng .val.fear { color: #f85149 }
.m-vibe-card.fng .val.greed { color: #3fb950 }
.m-vibe-card.fng .val.neutral { color: #f5a524 }
/* 双值卡 (山寨季 + 恐贪) */
.m-vibe-card.dual {
  flex-direction: column; align-items: stretch; justify-content: center;
  gap: 10px; padding: 14px;
}
.m-vibe-card.dual .dual-row {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: baseline; gap: 8px;
}
.m-vibe-card.dual .dual-row .lbl {
  font-size: 11px; color: #7d8590; margin: 0;
  letter-spacing: 0; text-align: left;
}
.m-vibe-card.dual .dual-row .val {
  font-size: 22px; font-weight: 700; line-height: 1;
  color: #e6edf3; text-align: center;
}
.m-vibe-card.dual .dual-row .tag {
  font-size: 10.5px; color: #7d8590; margin: 0;
  text-align: right;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.m-vibe-card.dual .val.fear { color: #f85149 }
.m-vibe-card.dual .val.greed { color: #3fb950 }
.m-vibe-card.dual .val.neutral { color: #f5a524 }
.m-vibe-card.dual .val.alt-btc { color: #f5a524 }
.m-vibe-card.dual .val.alt-mid { color: #58a6ff }
.m-vibe-card.dual .val.alt-season { color: #bd93f9 }

/* 章节标题 */
.m-sect-head {
  display: flex; align-items: center; justify-content: space-between;
  margin: 18px 4px 10px;
}
.m-sect-head .ttl {
  font-size: 15px; font-weight: 600; color: #e6edf3;
  display: flex; align-items: center; gap: 6px;
}
.m-sect-head .more {
  font-size: 12px; color: #00d4aa; text-decoration: none;
}

/* AI 关注 (轮播大卡) */
.m-ai-carousel {
  position: relative;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  display: flex; gap: 12px;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.m-ai-carousel::-webkit-scrollbar { display: none }
.m-ai-card {
  flex: 0 0 92%;
  scroll-snap-align: center;
  background: linear-gradient(135deg, #131823, #0e131c);
  border: 1px solid #1e2433;
  border-radius: 16px;
  padding: 16px 18px;
  display: flex; flex-direction: column; gap: 10px;
}
.m-ai-card.long { border-color: rgba(63,185,80,0.3); box-shadow: 0 0 20px rgba(63,185,80,0.06) }
.m-ai-card.short { border-color: rgba(248,81,73,0.3); box-shadow: 0 0 20px rgba(248,81,73,0.06) }
.m-ai-card .head {
  display: flex; align-items: center; justify-content: space-between;
}
.m-ai-card .sym { font-size: 22px; font-weight: 700; color: #e6edf3; letter-spacing: 0.5px }
.m-ai-card .dir {
  padding: 4px 12px; border-radius: 14px;
  font-size: 12px; font-weight: 600;
}
.m-ai-card .dir.long { background: rgba(63,185,80,0.14); color: #3fb950 }
.m-ai-card .dir.short { background: rgba(248,81,73,0.14); color: #f85149 }
.m-ai-card .reason {
  font-size: 13px; color: #c9d1d9; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  overflow: hidden;
}
.m-ai-card .meta {
  display: flex; gap: 8px; font-size: 11px; color: #7d8590;
}
.m-ai-card .ai-name {
  display: inline-block;
  padding: 2px 7px; border-radius: 4px;
  background: rgba(189,147,249,0.12); color: #bd93f9;
  font-weight: 500;
}

/* 聪明钱实时 list */
.m-sm-list { display: flex; flex-direction: column; gap: 6px }
.m-sm-row {
  display: grid; grid-template-columns: 56px 1fr auto;
  gap: 10px; align-items: center;
  padding: 11px 12px;
  background: #131823;
  border: 1px solid #1e2433;
  border-radius: 12px;
  text-decoration: none; color: inherit;
}
.m-sm-row .src {
  display: flex; align-items: center; justify-content: center;
  padding: 6px 4px;
  border-radius: 6px;
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.2px;
  flex-shrink: 0;
  text-align: center;
  line-height: 1.15;
}
.m-sm-row .src.hl { background: rgba(189,147,249,0.16); color: #bd93f9 }
.m-sm-row .src.binance_sm { background: rgba(240,185,11,0.16); color: #F0B90B }
.m-sm-row .src.bicoin { background: rgba(88,166,255,0.16); color: #58a6ff }
.m-sm-row .body { min-width: 0 }
.m-sm-row .body .name {
  font-size: 13.5px; font-weight: 600; color: #e6edf3;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.m-sm-row .body .desc {
  font-size: 12px; color: #7d8590; margin-top: 3px;
  display: flex; align-items: center; gap: 6px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.m-sm-row .body .desc .act {
  display: inline-block; flex-shrink: 0;
  padding: 2px 8px; border-radius: 5px;
  font-size: 11.5px; font-weight: 700;
  letter-spacing: 0.3px;
}
.m-sm-row .body .desc .act.long  { background: rgba(63,185,80,0.16);  color: #3fb950 }
.m-sm-row .body .desc .act.short { background: rgba(248,81,73,0.16); color: #f85149 }
.m-sm-row .body .desc .sym { color: #e6edf3; font-weight: 600; font-size: 12.5px }
.m-sm-row .body .desc .src-name { color: #6e7681; font-size: 11px; margin-left: auto }
.m-sm-row .ts { color: #6e7681; font-size: 11px; flex-shrink: 0 }

/* 共识 chips 横滑 */
.m-cons-row {
  display: flex; gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.m-cons-row::-webkit-scrollbar { display: none }
.m-cons-chip {
  flex-shrink: 0;
  padding: 9px 13px;
  background: #131823;
  border: 1px solid #1e2433;
  border-radius: 10px;
  display: flex; align-items: center; gap: 6px;
  font-size: 12px;
}
.m-cons-chip.bull { box-shadow: inset 0 0 0 1px rgba(63,185,80,0.4) }
.m-cons-chip.bear { box-shadow: inset 0 0 0 1px rgba(248,81,73,0.4) }
.m-cons-chip .base { color: #e6edf3; font-weight: 600 }
.m-cons-chip .longs { color: #3fb950 }
.m-cons-chip .shorts { color: #f85149 }

/* 加载状态 */
.m-loading {
  padding: 30px 14px;
  text-align: center;
  color: #7d8590; font-size: 13px;
}

/* 底 spacer 防内容被 tab 遮 */
.m-bottom-pad { height: 12px }

/* ============ 行情 tab (P2) ============ */
.m-rank-page main.page { display: none }  /* 隐藏 desktop Coming Soon */

.m-rank-tabs {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 6px; margin-bottom: 10px;
}
.m-rank-tab {
  padding: 10px 8px; text-align: center;
  background: #131823; border: 1px solid #1e2433;
  border-radius: 10px;
  font-size: 13px; font-weight: 600; color: #c9d1d9;
  cursor: pointer; user-select: none;
  transition: all .15s;
}
.m-rank-tab.active {
  background: rgba(0,212,170,0.12);
  border-color: #00d4aa;
  color: #00d4aa;
}
.m-rank-sub {
  display: flex; gap: 6px; margin-bottom: 12px;
}
.m-rank-sub .chip {
  /* P1 触摸目标 44pt 最佳实践:min-height:44px */
  min-height: 36px;
  display: inline-flex; align-items: center;
  padding: 8px 16px;
  background: #131823; border: 1px solid #1e2433;
  border-radius: 8px;
  font-size: 13px; color: #7d8590;
  cursor: pointer; user-select: none;
}
.m-rank-sub .chip.active {
  background: rgba(0,212,170,0.08);
  border-color: rgba(0,212,170,0.4);
  color: #00d4aa;
}
.m-rank-sub .chip.dir {
  margin-left: auto;
  min-width: 32px;
  padding: 6px 10px;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  color: #00d4aa;
  border-color: rgba(0,212,170,0.3);
}
.m-rank-list { display: flex; flex-direction: column; gap: 8px }
.m-rank-row {
  display: grid; grid-template-columns: 1fr auto;
  align-items: center; gap: 12px;
  padding: 12px 14px;
  background: #131823; border: 1px solid #1e2433;
  border-radius: 12px;
  text-decoration: none; color: inherit;
}
.m-rank-row .left .base {
  font-size: 16px; font-weight: 700; color: #e6edf3;
  letter-spacing: 0.3px;
}
.m-rank-row .left .meta {
  font-size: 11.5px; color: #7d8590; margin-top: 2px;
}
.m-rank-row .right { text-align: right }
.m-rank-row .right .val {
  font-size: 18px; font-weight: 700;
  letter-spacing: 0.2px;
}
.m-rank-row .right .val.up { color: #3fb950 }
.m-rank-row .right .val.down { color: #f85149 }
.m-rank-row .right .val.neu { color: #c9d1d9 }
.m-rank-row .right .price {
  font-size: 11.5px; color: #7d8590; margin-top: 2px;
  font-family: ui-monospace, monospace;
}

/* ============ 聪明钱 tab (P3) — 卡片缩 1 列 ============ */
.sm-cards { grid-template-columns: 1fr !important }
.sm-page { padding: 12px 14px 20px !important }
.sm-tabs { width: 100% !important; overflow-x: auto; flex-wrap: nowrap !important }
.sm-tabs::-webkit-scrollbar { display: none }
.sm-tab { white-space: nowrap; padding: 9px 14px !important; font-size: 13px !important }
.sm-cutoff-note { font-size: 13px !important; padding: 8px 10px !important; margin-bottom: 12px !important }
.sm-card {
  padding: 18px 16px !important;
  border-radius: 14px !important;
}
.sm-card .pnl-big { font-size: 32px !important; line-height: 1.05 !important }
.sm-card .head .avatar { width: 42px !important; height: 42px !important }
.sm-card .name { font-size: 15px !important }
.sm-card .src { font-size: 12px !important }
.sm-card .meta { gap: 5px !important }
.sm-card .tag { font-size: 11px !important; padding: 4px 9px !important }
.sm-consensus { padding: 12px 14px !important; margin-top: 16px !important }
.cons-item { font-size: 12px !important; padding: 7px 11px !important }

/* ============ Leader 详情页 ============ */
.ld-page { padding: 12px 14px 20px !important }
.ld-back { font-size: 13px !important; padding: 8px 0 !important }
.ld-head { padding: 16px !important; gap: 12px !important; flex-direction: column; align-items: flex-start !important }
.ld-head .avatar { width: 56px !important; height: 56px !important }
.ld-head .name { font-size: 19px !important }
.ld-head .acct { text-align: left !important; width: 100% }
.ld-head .acct-val { font-size: 22px !important }
.ld-stats { grid-template-columns: 1fr 1fr !important; gap: 8px !important }
.stat-card { padding: 12px 14px !important }
.stat-card .value { font-size: 19px !important }
.stat-card .label { font-size: 10.5px !important }
.ld-grid { grid-template-columns: 1fr !important }
.ld-chart-wrap { height: 220px !important }

/* ============ 图表页 ============ */
.chart-wrap { padding: 0 !important }
.chart-head { padding: 12px 14px 4px !important }
.chart-head .ttl { font-size: 17px !important }
.chart-head .hint { display: none !important }
.tv-container { height: calc(100vh - 240px) !important }
.sym-tabs { padding: 0 12px 8px !important; flex-wrap: nowrap !important; overflow-x: auto !important }
.sym-tabs::-webkit-scrollbar { display: none }
.sym-tabs .sym-tab { padding: 8px 14px !important; font-size: 13px !important; flex-shrink: 0 }
.sym-add { padding: 7px 14px !important; flex-shrink: 0 }
.sym-search-dd { left: 10px !important; min-width: 240px !important }

/* ============ 信息流(news 页适配)============ */
/* 暂仍显示 Coming Soon,P4 后再做内容 */

}  /* end @media */
