:root {
  --bg: #f4f5f7;
  --card: #ffffff;
  --text: #16181d;
  --sub: #8b9099;
  --faint: #a8adb5;
  --line: #eef0f3;
  --line-2: #f4f5f7;
  --up: #d93a2b;
  --down: #0a9d5c;
  --brand: #d93a2b;
  --tab-h: 56px;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  padding: 0;
  background: #e9ebee;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", sans-serif;
  color: var(--text);
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

#app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
}

.num {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}

.up {
  color: var(--up);
}

.down {
  color: var(--down);
}

.muted {
  color: var(--sub);
}

/* ---------- 视图容器 ---------- */
.view {
  padding: 16px 12px calc(var(--tab-h) + 28px + env(safe-area-inset-bottom));
  min-height: 100vh;
}

.view.no-tab {
  padding-bottom: 40px;
}

/* ---------- 顶栏 ---------- */
.topbar {
  display: flex;
  align-items: center;
  height: 52px;
  padding: 0 6px;
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 20;
}

.topbar-title {
  flex: 1;
  text-align: center;
  font-size: 16px;
  font-weight: 600;
}

.topbar-btn {
  width: 56px;
  font-size: 14px;
  color: var(--sub);
  background: none;
  border: 0;
  padding: 8px 4px;
  cursor: pointer;
  text-align: left;
}

.topbar-btn.right {
  text-align: right;
  color: var(--brand);
  font-weight: 500;
}

/* ---------- 卡片 ---------- */
.hero {
  background: var(--card);
  border-radius: 16px;
  padding: 18px 16px 14px;
}

.hero-label {
  font-size: 13px;
  color: var(--sub);
}

.hero-value {
  margin-top: 6px;
  font-size: 36px;
  font-weight: 600;
  letter-spacing: -0.5px;
  line-height: 1.1;
}

.hero-value.small {
  font-size: 30px;
}

.hero-stats {
  display: flex;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.stat {
  flex: 1;
  min-width: 0;
}

.stat-v {
  font-size: 17px;
  font-weight: 600;
  white-space: nowrap;
}

.stat-k {
  margin-top: 3px;
  font-size: 11px;
  color: var(--sub);
}

.card {
  background: var(--card);
  border-radius: 14px;
  padding: 16px;
  margin-top: 12px;
}

.card-title {
  font-size: 13px;
  color: var(--sub);
}

/* ---------- 日期分组 / 记录行 ---------- */
.day {
  margin-top: 18px;
}

.day-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 4px 8px;
  font-size: 12px;
  color: var(--sub);
}

.day-body {
  background: var(--card);
  border-radius: 14px;
  overflow: hidden;
}

.trade {
  padding: 14px 16px;
  border-top: 1px solid var(--line-2);
  cursor: pointer;
}

.trade:first-child {
  border-top: 0;
}

.trade:active {
  background: #fafbfc;
}

.trade-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.trade-name {
  display: flex;
  align-items: baseline;
  min-width: 0;
  max-width: 62%;
}

.trade-name .n {
  font-size: 16px;
  font-weight: 600;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.trade-name .c {
  margin-left: 7px;
  font-size: 11px;
  color: var(--faint);
  flex-shrink: 0;
}

.trade-net {
  font-size: 17px;
  font-weight: 600;
}

.trade-net.pending {
  font-size: 13px;
  color: #d98700;
}

.pending-count {
  font-size: 12px;
  color: #d98700;
}

/* 半笔待平提示 */
.hero-pending {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  font-size: 11px;
  color: #d98700;
}

.trade-sub {
  margin-top: 5px;
}

.meta {
  font-size: 12px;
  color: var(--sub);
}

/* ---------- 悬浮按钮 ---------- */
.fab {
  position: fixed;
  right: max(16px, calc(50% - 240px + 16px));
  bottom: calc(var(--tab-h) + 16px + env(safe-area-inset-bottom));
  height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 23px;
  background: var(--brand);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  box-shadow: 0 6px 18px rgba(217, 58, 43, 0.3);
  cursor: pointer;
  z-index: 30;
}

/* ---------- 底部 tab ---------- */
.tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  max-width: 480px;
  margin: 0 auto;
  height: calc(var(--tab-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  display: flex;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  z-index: 40;
}

.tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--sub);
  cursor: pointer;
  border: 0;
  background: none;
}

.tab.on {
  color: var(--brand);
  font-weight: 600;
}

/* ---------- 表单 ---------- */
.sheet {
  background: var(--card);
  border-radius: 14px;
  padding: 0 16px;
  margin-top: 12px;
}

.cell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  border-top: 1px solid var(--line-2);
}

.cell:first-child {
  border-top: 0;
}

.cell-k {
  font-size: 14px;
  color: #52575f;
  flex-shrink: 0;
}

.cell-input {
  flex: 1;
  border: 0;
  outline: none;
  background: none;
  text-align: right;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  min-width: 0;
  padding: 14px 0;
}

.cell-input::placeholder {
  color: #c2c6cc;
}

.cell-num {
  font-size: 15px;
}

.tag {
  margin-left: 8px;
  font-size: 10px;
  color: var(--sub);
  background: var(--line-2);
  border-radius: 4px;
  padding: 2px 6px;
  flex-shrink: 0;
}

.seg {
  display: flex;
  margin-top: 10px;
}

.seg-i {
  flex: 1;
  text-align: center;
  height: 40px;
  line-height: 40px;
  font-size: 13px;
  color: #52575f;
  background: var(--line-2);
  border-radius: 8px;
  cursor: pointer;
}

.seg-i + .seg-i {
  margin-left: 8px;
}

.seg-i.on {
  background: #fdeceb;
  color: var(--brand);
  font-weight: 600;
}

.calc {
  margin-top: 12px;
  background: var(--card);
  border-radius: 14px;
  padding: 16px;
}

.calc-main {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.calc-k {
  font-size: 13px;
  color: var(--sub);
}

.calc-v {
  font-size: 24px;
  font-weight: 600;
}

.calc-sub {
  display: flex;
  gap: 14px;
  margin-top: 8px;
  font-size: 11px;
  color: var(--sub);
  flex-wrap: wrap;
}

.btn {
  width: 100%;
  height: 48px;
  border: 0;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}

.btn-primary {
  background: var(--brand);
  color: #fff;
  margin-top: 20px;
}

.btn-primary:disabled {
  background: #e6a8a3;
}

.btn-ghost {
  background: #fff;
  color: var(--text);
  border: 1px solid var(--line);
}

.danger-link {
  text-align: center;
  margin-top: 18px;
  font-size: 14px;
  color: var(--sub);
  padding: 10px;
  cursor: pointer;
}

.hint {
  margin: 10px 4px 0;
  font-size: 11px;
  color: var(--faint);
  line-height: 1.6;
}

.form-err {
  margin: 10px 4px 0;
  font-size: 13px;
  color: var(--brand);
}

/* ---------- 分析 ---------- */
.seg-type {
  display: flex;
  background: #eceef1;
  border-radius: 9px;
  padding: 3px;
}

.seg-t {
  flex: 1;
  text-align: center;
  height: 32px;
  line-height: 32px;
  font-size: 14px;
  color: #52575f;
  border-radius: 7px;
  cursor: pointer;
}

.seg-t.on {
  background: #fff;
  color: var(--text);
  font-weight: 600;
}

.period {
  display: flex;
  align-items: center;
  margin-top: 6px;
}

.nav {
  width: 40px;
  height: 40px;
  line-height: 40px;
  text-align: center;
  font-size: 22px;
  color: #52575f;
  cursor: pointer;
  border: 0;
  background: none;
  padding: 0;
}

.nav.off {
  color: #d5d8dc;
  cursor: default;
}

.period-mid {
  flex: 1;
  text-align: center;
}

.period-title {
  font-size: 15px;
  font-weight: 600;
}

.period-sub {
  margin-top: 2px;
  font-size: 11px;
  color: var(--sub);
}

.chart {
  position: relative;
  height: 132px;
  margin-top: 14px;
}

.chart-axis {
  position: absolute;
  left: 0;
  right: 0;
  top: 55px;
  height: 1px;
  background: var(--line);
}

.cols {
  position: relative;
  display: flex;
  height: 110px;
}

.col {
  position: relative;
  flex: 1;
  height: 110px;
}

.bar {
  position: absolute;
  left: 20%;
  right: 20%;
  border-radius: 2px;
}

.bar.up {
  background: var(--up);
}

.bar.down {
  background: var(--down);
}

.col-l {
  position: absolute;
  bottom: -18px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 9px;
  color: var(--faint);
}

.col-l.today {
  color: var(--brand);
  font-weight: 600;
}

.srow {
  display: flex;
  align-items: center;
  padding: 11px 0;
  border-top: 1px solid var(--line-2);
}

.srow:first-of-type {
  border-top: 0;
  padding-top: 6px;
}

.s-main {
  flex: 1;
  display: flex;
  align-items: baseline;
  min-width: 0;
}

.s-name {
  font-size: 14px;
  font-weight: 500;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  max-width: 120px;
}

.s-code {
  margin-left: 6px;
  font-size: 10px;
  color: var(--faint);
}

.s-meta {
  font-size: 11px;
  color: var(--sub);
  margin-right: 12px;
  white-space: nowrap;
}

.s-net {
  font-size: 15px;
  font-weight: 600;
}

.kv {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 0;
  border-top: 1px solid var(--line-2);
  font-size: 14px;
}

.kv:first-of-type {
  border-top: 0;
}

.kv-k {
  color: var(--sub);
  font-size: 13px;
}

/* ---------- 我的 ---------- */
.profile {
  padding: 6px 4px 14px;
}

.profile-name {
  font-size: 20px;
  font-weight: 600;
}

.profile-sub {
  margin-top: 4px;
  font-size: 12px;
  color: var(--sub);
}

.grid {
  display: flex;
  flex-wrap: wrap;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.grid-i {
  width: 50%;
  padding: 6px 0;
}

.grid-v {
  font-size: 16px;
  font-weight: 600;
}

.grid-k {
  margin-top: 2px;
  font-size: 11px;
  color: var(--sub);
}

.note-line {
  margin-top: 6px;
  font-size: 12px;
  color: var(--sub);
  line-height: 1.65;
}

/* ---------- 登录 ---------- */
.login {
  padding: 64px 24px;
  margin: 0 auto;
}

.login-title {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.login-sub {
  margin-top: 8px;
  font-size: 13px;
  color: var(--sub);
}

.login-body {
  margin-top: 36px;
}

.field {
  display: flex;
  align-items: center;
  background: var(--line-2);
  border-radius: 10px;
  height: 50px;
  padding: 0 14px;
  margin-bottom: 10px;
}

.field input {
  flex: 1;
  border: 0;
  outline: none;
  background: none;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  min-width: 0;
}

.field input::placeholder {
  color: var(--faint);
}

.send {
  font-size: 13px;
  color: var(--brand);
  font-weight: 500;
  padding-left: 10px;
  cursor: pointer;
  white-space: nowrap;
}

.send.off {
  color: var(--faint);
  cursor: default;
}

.login-btn {
  margin-top: 14px;
  height: 48px;
}

/* 微信登录 */
.wechat-btn {
  background: #07c160;
  color: #fff;
  height: 52px;
  font-size: 17px;
  margin-top: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wechat-btn:active {
  background: #06ad56;
}

.login-or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--faint);
  font-size: 12px;
}

.login-or::before,
.login-or::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #dde1e6;
}

.login-note {
  margin-top: 44px;
  font-size: 12px;
  color: var(--faint);
  line-height: 1.7;
  text-align: center;
}

.login-tip {
  margin-top: 12px;
  font-size: 12px;
  color: var(--down);
}

.login-err {
  margin-top: 12px;
  font-size: 12px;
  color: var(--brand);
}

.login-switch {
  margin-top: 32px;
  text-align: center;
  font-size: 13px;
  color: var(--sub);
  cursor: pointer;
}

/* ---------- 状态 ---------- */
.empty {
  padding: 56px 20px;
  text-align: center;
  color: var(--sub);
  font-size: 13px;
  line-height: 1.8;
}

.empty-title {
  display: block;
  font-size: 15px;
  color: #52575f;
  margin-bottom: 6px;
}

.center-btn {
  margin: 16px auto 0;
  width: auto;
  padding: 0 22px;
  height: 38px;
  font-size: 14px;
}

/* 桌面端：加个外框阴影，别太空旷 */
@media (min-width: 520px) {
  #app {
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.06);
    min-height: 100vh;
  }
}

/* 本机版：大字入口与备份对话框 */
.login-label { display:block; text-align:left; margin:16px 0 8px; color:#565d66; font-size:16px; }
.login .field { margin-bottom:12px; }
.guide-link { display:block; text-align:center; color:var(--brand); margin:20px 0; font-size:16px; }
.list-heading { display:flex; justify-content:space-between; align-items:center; margin:20px 4px 4px; font-size:16px; font-weight:600; }
.text-button { border:0; background:transparent; color:var(--brand); padding:10px; font-size:16px; cursor:pointer; }
.home-actions { display:grid; grid-template-columns:1fr; gap:10px; margin:10px 0 14px; }
a.btn { display:flex; align-items:center; justify-content:center; text-decoration:none; }
button:disabled { opacity:.55; cursor:wait; }
.home-dialog { width:min(92vw,440px); max-height:86vh; border:0; border-radius:18px; padding:22px; color:var(--text); font:16px/1.6 -apple-system,BlinkMacSystemFont,"PingFang SC",sans-serif; }
.home-dialog::backdrop { background:rgba(20,24,29,.5); }
.dialog-head { display:flex; justify-content:space-between; align-items:center; gap:16px; }
.dialog-head h2 { font-size:22px; margin:0; }
.home-dialog label { display:block; margin:16px 0; }
.home-dialog input:not([type=checkbox]) { display:block; width:100%; border:1px solid #d8dce1; border-radius:9px; padding:12px; font-size:18px; margin-top:6px; }
.home-dialog .check-row { display:flex; gap:8px; align-items:flex-start; }
.home-dialog .check-row input { margin-top:6px; }
.home-dialog pre { white-space:pre-wrap; overflow-wrap:anywhere; font-size:12px; background:#f4f5f7; padding:10px; border-radius:8px; }
.dialog-error { color:var(--brand); margin:10px 0; }
input, button { touch-action:manipulation; }
.cell-input, .field input { font-size:17px; }
.note-line, .hint { line-height:1.65; }

/* 家庭手机：自动复盘与第四个问答页，320px 起保持导航与输入可用。 */
.auto-review{background:#fff;border:1px solid var(--line);border-radius:14px;padding:16px;margin-top:14px;overflow-wrap:anywhere}.auto-review-title{font-weight:650;font-size:16px;display:flex;flex-wrap:wrap;gap:4px 10px;justify-content:space-between}.auto-review-title span{font-size:11px;color:var(--sub);font-weight:400}.auto-review-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:16px 0}.auto-review-grid span{display:block;color:var(--sub);font-size:12px}.auto-review-grid strong{display:block;font-size:19px;overflow-wrap:anywhere}.auto-review ul{padding-left:18px;font-size:13px;line-height:1.7}.auto-review-note{font-size:11px;color:var(--sub);line-height:1.6;margin:12px 0 0}.question-title{font-size:23px;margin:4px 0 8px}.question-gate{background:#eef5ef;border-radius:10px;padding:12px;font-size:13px;line-height:1.65;margin:14px 0}.question-gate button{display:block;margin-top:8px;min-height:32px}.question-compose{background:white;border:1px solid var(--line);padding:15px;border-radius:14px;margin-top:16px}.question-compose>label{font-size:14px;font-weight:600}.question-compose textarea{display:block;width:100%;box-sizing:border-box;min-width:0;resize:vertical;border:1px solid #d4ddd7;border-radius:9px;font-family:inherit;font-size:16px;line-height:1.6;padding:10px;margin-top:10px;min-height:110px}.question-compose .btn{width:100%;min-height:44px}.question-compose .note-line,.question-view>.note-line{font-size:12px;line-height:1.65;white-space:normal}.question-exchange{margin:18px 0;border-radius:12px;background:#fff;border:1px solid var(--line);overflow:hidden}.question-user,.question-answer{padding:14px;overflow-wrap:anywhere}.question-user{background:#edf4ef}.question-exchange b{font-size:12px;color:var(--sub)}.question-exchange p{white-space:pre-wrap;line-height:1.7;font-size:14px;margin:8px 0 0}.question-sources{padding-left:20px;font-size:12px;line-height:1.7}.question-sources a{overflow-wrap:anywhere}.question-progress{font-size:13px;color:var(--brand);line-height:1.6}.question-error{color:#b83227;font-size:13px;line-height:1.5;overflow-wrap:anywhere}.tab{min-width:0;min-height:44px;white-space:nowrap}.question-view{overflow-wrap:anywhere}

.premarket-brief{white-space:pre-wrap;line-height:1.7;font-size:14px;margin:12px 0;overflow-wrap:anywhere}

.holdings-view .note-line{white-space:normal;line-height:1.6}.holdings-position,.holdings-form{background:white;border:1px solid var(--line);border-radius:12px;padding:14px;margin:14px 0;overflow-wrap:anywhere}.holdings-position p{font-size:13px;line-height:1.6;margin:7px 0}.holdings-actions{display:flex;gap:10px}.holdings-actions button{min-height:44px;flex:1}.holdings-form h2{font-size:17px;margin:0 0 12px}.holdings-form label{display:block;font-size:13px;margin:12px 0}.holdings-form input{display:block;width:100%;min-width:0;box-sizing:border-box;border:1px solid var(--line);border-radius:8px;font-size:16px;padding:11px;margin-top:6px}.holdings-form>.btn{width:100%;margin-top:8px;min-height:44px}.holdings-view{overflow-wrap:anywhere}

/* V2 · 组合优先的手机工作流 */
:root{--brand:#246851;--tab-h:62px}.portfolio-header{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:4px 0 20px}.portfolio-header p{font-size:12px;color:#738078;margin:0 0 7px}.portfolio-header h1{font-size:27px;line-height:1.2;letter-spacing:-.7px;margin:0;color:#233d31}.utility-link{flex:none;color:#335f4c;text-decoration:none;font-size:13px;padding:10px 14px;border:1px solid #dce5dd;border-radius:22px;background:white}.page-subline{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:12px;color:#718078;margin:0 0 14px}.page-subline button{min-height:40px}.portfolio-hero{background:linear-gradient(135deg,#214f3e,#36765a);color:#fff;border-radius:20px;padding:24px 20px;box-shadow:0 9px 24px #20483116;overflow-wrap:anywhere}.portfolio-hero .eyebrow{font-size:13px;color:#dcebe1}.portfolio-amount{font-size:clamp(28px,8vw,39px);font-weight:700;letter-spacing:-1.1px;line-height:1.4;margin:12px 0}.portfolio-amount small{font-size:13px;letter-spacing:0;margin-left:8px;font-weight:400}.valuation-badge{display:inline-block;font-size:11px;line-height:1.6;border:1px solid #ffffff40;border-radius:20px;padding:4px 9px;background:#ffffff0b}.portfolio-hero p{font-size:12px;line-height:1.8;color:#e0e9e2;margin:16px 0 0}.empty-portfolio h2{font-size:27px;line-height:1.45;margin:14px 0 0;letter-spacing:-.5px}.empty-portfolio .portfolio-primary{margin-top:20px;background:#f2f7e9;color:#244d3b}.portfolio-primary,.portfolio-secondary{font:inherit;font-weight:600;display:inline-flex;align-items:center;justify-content:center;min-height:46px;box-sizing:border-box;border-radius:11px;padding:11px 15px;text-decoration:none;text-align:center;cursor:pointer;border:0;line-height:1.5}.portfolio-primary{background:#28664e;color:white}.portfolio-secondary{background:#edf3ed;color:#2f5b45;border:1px solid #d8e4d8}.portfolio-primary:disabled,.portfolio-secondary:disabled{opacity:.45;cursor:not-allowed}.portfolio-metrics{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px;margin:14px 0}.portfolio-metrics section{background:white;border:1px solid #e4e8e2;border-radius:15px;padding:16px 13px;overflow-wrap:anywhere}.portfolio-metrics span{font-size:12px;color:#68776e;display:block;line-height:1.5}.portfolio-metrics strong{display:block;font-size:22px;font-weight:650;margin:10px 0 7px;line-height:1.35;overflow-wrap:anywhere}.portfolio-metrics small{font-size:11px;line-height:1.6;display:block;color:#829087}.portfolio-card{background:white;border:1px solid #e4e8e2;border-radius:16px;padding:18px 16px;margin:15px 0;overflow-wrap:anywhere}.section-title{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 15px}.section-title h2{font-size:17px;margin:0;color:#243d30;font-weight:650}.section-title a{font-size:12px;color:#38694e;text-decoration:none;padding:6px 0}.soft-label{font-size:11px;color:#7b887f;flex:none}.concentration-line{display:flex;justify-content:space-between;align-items:center;font-size:14px}.concentration-line b{font-size:23px;font-weight:650;color:#3e5c49}.portfolio-caption{font-size:12px!important;color:#78857b;line-height:1.75!important;margin:10px 0!important;white-space:normal!important}.portfolio-findings{font-size:13px;line-height:1.75;padding-left:17px;color:#46594a;margin:13px 0 0}.portfolio-findings li+li{margin-top:7px}.portfolio-footnote{font-size:11px;line-height:1.8;color:#879086;margin:20px 4px 5px}.portfolio-warning{font-size:13px;line-height:1.7;border:1px solid #e7d9b8;background:#fffaeb;color:#7a6637;padding:12px;border-radius:12px;overflow-wrap:anywhere}.portfolio-steps{padding:2px 0;list-style:none;margin:20px 0}.portfolio-steps li{display:flex;align-items:center;gap:12px;margin:15px 0;font-size:14px;font-weight:600}.portfolio-steps b{display:grid;place-items:center;width:31px;height:31px;border-radius:50%;background:#e5ede2;color:#547452;flex:none}.portfolio-steps small{display:block;font-size:12px;color:#7c897d;font-weight:400;margin-top:5px}.t-today{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.t-today span,.t-today small{font-size:12px;display:block;color:#758176;line-height:1.6}.t-today b{display:block;font-size:22px;margin:10px 0;overflow-wrap:anywhere}.portfolio-card>.portfolio-secondary{display:flex;margin-top:15px}.portfolio-empty{text-align:left;font-size:14px;line-height:1.8;color:#728074;padding:24px 18px}.portfolio-empty h2{color:#36513e;font-size:18px}.portfolio-position{background:white;border:1px solid #e1e8de;border-radius:15px;padding:17px 15px;margin:12px 0;overflow-wrap:anywhere}.position-top{display:flex;justify-content:space-between;gap:8px;align-items:flex-start}.position-top h2{font-size:18px;line-height:1.4;margin:0;color:#283d2e}.position-top p{font-size:11px;color:#82907e;line-height:1.5;margin:5px 0 0}.position-top button{min-height:44px;min-width:44px;flex:none}.position-values{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin:17px 0 10px}.position-values span{font-size:11px;color:#83907e;display:block}.position-values b{font-size:15px;margin-top:8px;display:block;line-height:1.5;font-weight:600}.add-position{width:100%;margin:8px 0 4px}.holdings-form{border-color:#bbd0ba;padding:18px 16px;scroll-margin-top:14px}.holdings-form label{font-size:12px;color:#52644e;line-height:1.5}.holdings-form input,.holdings-form select,.cash-input-line input{font-family:inherit;width:100%;min-width:0;box-sizing:border-box;padding:12px 10px;border:1px solid #d9e1d4;border-radius:9px;background:#fff;font-size:16px;min-height:46px;color:#263b2b;margin-top:7px}.form-pair{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.holdings-form>.portfolio-primary{width:100%;margin-top:12px}.manual-quote{border-top:1px solid #e7ece3;margin-top:18px;padding-top:14px}.manual-quote summary{font-size:13px;color:#536c4e;padding:5px 0;cursor:pointer;min-height:32px}.holding-delete{border:0;background:none;color:#9d584a;width:100%;font-size:13px;min-height:44px;margin-top:10px;cursor:pointer}.cash-card label{font-size:12px;color:#758171}.cash-input-line{display:flex;gap:9px;align-items:stretch;margin-top:8px}.cash-input-line input{margin:0;flex:1;width:0}.cash-input-line button{flex:none;font-size:12px;padding:9px 12px}.tabbar{background:#fffffff5;border-top-color:#e0e7dd}.tab{font-size:13px;letter-spacing:.5px;min-height:48px}.tab.on{color:#285e3e;background:#edf4e952}.visually-hidden{position:absolute!important;clip:rect(0,0,0,0);width:1px;height:1px;overflow:hidden}.today-view,.holdings-view{background:#f5f7f1}.today-view a:focus-visible,.holdings-view button:focus-visible,.portfolio-primary:focus-visible{outline:3px solid #d2a94f;outline-offset:3px}@media(max-width:350px){.portfolio-header h1{font-size:24px}.portfolio-hero{padding:21px 17px}.portfolio-metrics strong{font-size:20px}.portfolio-card{padding:16px 13px}.portfolio-metrics{gap:8px}.position-values b{font-size:14px}.cash-input-line button{padding:8px;font-size:11px}}

.quote-source-link{display:inline-flex;align-items:center;min-height:40px;color:#35644a;font-size:12px;text-decoration:none}

.portfolio-drivers{padding:0;list-style:none;margin:0}.portfolio-drivers li{display:flex;justify-content:space-between;gap:12px;font-size:13px;padding:10px 0;border-bottom:1px solid #edf0e9}.portfolio-drivers li:last-child{border:0}.portfolio-drivers b{font-weight:600;flex:none}.portfolio-drivers span{overflow-wrap:anywhere}

/* v2.0.2：今日页显著分析入口，不借用 hash 路由。 */
.analysis-shortcuts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:0 0 16px}.analysis-shortcuts button{display:flex;flex-direction:column;justify-content:center;align-items:flex-start;gap:6px;min-width:0;min-height:76px;padding:13px 12px;border:1px solid #bdd0be;border-radius:14px;background:#e9f2e6;color:#28533b;font-family:inherit;text-align:left;cursor:pointer}.analysis-shortcuts button+button{background:#edf0e4;border-color:#d0d8bc;color:#4b633b}.analysis-shortcuts strong{font-size:18px;line-height:1.4;white-space:nowrap}.analysis-shortcuts span{font-size:11px;line-height:1.6;overflow-wrap:anywhere}.analysis-shortcuts button:disabled{opacity:.5;cursor:wait}.analysis-shortcuts button:focus-visible{outline:3px solid #cba64b;outline-offset:3px}.analysis-heading{scroll-margin-top:20px}.analysis-heading:focus{outline:2px solid #b9cead;outline-offset:5px;border-radius:3px}.empty-portfolio h2.analysis-heading{font-size:20px;margin:0 0 16px;line-height:1.4}.empty-portfolio h3{font-size:25px;line-height:1.5;margin:12px 0 0;font-weight:600}@media(max-width:350px){.analysis-shortcuts{gap:8px}.analysis-shortcuts button{padding:12px 10px}.analysis-shortcuts strong{font-size:17px}.analysis-shortcuts span{font-size:10px}}

/* v2.0.3b：回答完整展示与手机来源链接。 */
.question-answer,.question-answer>p{max-height:none;overflow:visible}.question-answer>p{white-space:pre-wrap;overflow-wrap:anywhere;word-break:normal}.question-sources a{display:flex;align-items:center;box-sizing:border-box;min-height:44px;padding:8px 0;line-height:1.6;overflow-wrap:anywhere;word-break:normal;color:#2d6551}.question-sources li{min-width:0}.question-answer-notice{background:#fff7df;border:1px solid #ead7a7;border-radius:8px;padding:10px!important;color:#7a6231;font-size:12px!important}.question-compose{scroll-margin-bottom:calc(var(--tab-h) + env(safe-area-inset-bottom) + 20px)}

/* v2.0.4：固定外壳与底栏，数据刷新只更新主内容。 */
#app-main{min-height:100dvh}#app-navigation[hidden]{display:none!important}#app-navigation .tab{touch-action:manipulation;-webkit-tap-highlight-color:transparent}#app-navigation .tabbar{isolation:isolate}html{scroll-behavior:auto}

/* Real provider snapshots; safe wrapping at 320/390px. */
.question-live,.question-summary{min-width:0;max-width:100%;overflow-wrap:anywhere;word-break:break-word}.question-live{margin:14px 0;padding:14px;border:1px solid #e4e7ed;border-radius:14px;background:#fff}.question-summary{margin:12px 0;padding:12px;border-radius:10px;background:#f3f5f8;font-size:14px;line-height:1.65}.question-summary p{white-space:pre-wrap;margin:7px 0 0}.question-live .question-progress{margin-top:0}.question-live .note-line{overflow-wrap:anywhere}.question-live .question-answer{max-width:100%}

/* Stable small viewport avoids Safari toolbar resize changing page minimums. */
#app,#app-main,.view{min-height:100vh;min-height:100svh}
#app-navigation .tabbar{background:#fff;backdrop-filter:none;-webkit-backdrop-filter:none}

.holding-name-note{min-height:3.5em;overflow-wrap:anywhere}
