/* MoonBank — 移动端优先；浅色应用壳（与截图一致）+ 深色登录/注册表单 */

:root {
  --brand: #6236ff;
  --brand-hover: #5129e6;
  --brand-soft: rgba(98, 54, 255, 0.1);
  --text: #111827;
  --text-secondary: #6b7280;
  --line: #e5e7eb;
  --page-bg: #f5f6fa;
  --card-bg: #ffffff;
  --shadow: 0 8px 24px rgba(17, 24, 39, 0.08);
  --radius-lg: 14px;
  --accent2: #10b981;
  --danger: #f43f5e;
  --radius-xl: 16px;
  --dock-h: calc(56px + env(safe-area-inset-bottom));
  font-family:
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    "PingFang SC",
    "Microsoft YaHei",
    sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
}

a {
  color: var(--brand);
  text-decoration: none;
}

/* ----------- 浅色应用页（首页 / Tab 内页） ----------- */
body.app-light {
  background: var(--page-bg);
  color: var(--text);
}

body.app-light a:hover {
  color: var(--brand-hover);
}

.app-root {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding-bottom: var(--dock-h);
}

.home-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 14px 16px 12px;
  background: var(--card-bg);
}

.home-greet {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.home-sub {
  margin: 6px 0 0;
  font-size: 0.92rem;
  font-weight: 700;
}

.home-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.icon-bell {
  position: relative;
  padding: 4px;
  border: none;
  background: none;
  color: var(--text);
  cursor: pointer;
  border-radius: 10px;
}

.icon-bell:active {
  background: rgba(98, 54, 255, 0.08);
}

.icon-bell-dot {
  position: absolute;
  bottom: 6px;
  right: 6px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ff7a33;
}

.link-logout {
  font-size: 0.78rem;
  color: var(--text-secondary);
  padding: 4px 8px;
}

/* Banner */
.home-banner-wrap {
  margin: 0 14px;
}

.home-banner-viewport {
  overflow: hidden;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

.home-banner-track {
  display: flex;
  transition: transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-banner-slide {
  flex: 0 0 100%;
}

.home-banner-img-wrap {
  position: relative;
  aspect-ratio: 16 / 7.8;
  background: #e8e9ef;
}

.home-banner-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.home-banner-fallback {
  position: absolute;
  inset: 0;
  background-image: url("../images/a2.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: grid;
  place-items: center;
}

.home-banner-caption {
  margin: 0;
  font-size: clamp(1rem, 4.2vw, 1.2rem);
  font-weight: 700;
}

.home-banner-caption--overlay {
  position: absolute;
  left: 14px;
  bottom: 16px;
  color: #fff;
  max-width: 68%;
  line-height: 1.35;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.45);
}

.home-banner-caption--center {
  color: #fff;
}

.home-banner-slide--alt,
.home-banner-slide--alt2 {
  aspect-ratio: 16 / 7.8;
  border-radius: var(--radius-xl);
  background-image: url("../images/a1.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
}

.home-banner-slide--alt2 {
  background-image: url("../images/a3.png");
}

.home-banner-slide--alt .home-banner-caption,
.home-banner-slide--alt2 .home-banner-caption {
  position: absolute;
  left: 14px;
  bottom: 16px;
  color: #fff;
}

.home-banner-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  padding: 12px 0 10px;
}

.home-banner-dots button {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  background: #ddd;
  cursor: pointer;
}

.home-banner-dots button.active {
  width: 20px;
  border-radius: 8px;
  background: var(--brand);
}

/* 加密银行卡精选 */
.home-products {
  padding: 4px 14px 20px;
}

.home-products-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 14px 0 12px;
}

.home-products-title {
  margin: 0;
  font-size: 1.06rem;
  font-weight: 700;
}

.home-products-more {
  font-size: 0.86rem;
  color: var(--text-secondary);
}

.home-product-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.home-product-row {
  display: flex;
  gap: 12px;
  align-items: stretch;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 12px;
  margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.home-product-thumb {
  border-radius: 10px;
  position: relative;
  overflow: hidden;
  flex: 1;
}

.home-product-thumb--gold {
  background-image: url("../images/t1.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.home-product-thumb--game {
  background-image: url("../images/t2.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.home-product-thumb--t3 {
  background-image: url("../images/t3.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.home-product-body {
  width: 159px;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.home-product-name {
  margin: 0 0 8px;
  font-size: 1rem;
  font-weight: 700;
}

.home-product-bullets {
  margin: 0 0 12px;
  padding-left: 1.05em;
  color: var(--text-secondary);
  font-size: 0.82rem;
  line-height: 1.55;
}

.btn-apply {
  align-self: flex-start;
  border: none;
  border-radius: 999px;
  padding: 8px 20px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  background: var(--brand);
  cursor: pointer;
  margin-top: auto;
}

.btn-apply:active {
  background: var(--brand-hover);
}

a.btn-apply {
  box-sizing: border-box;
}

/* 底部四栏 Dock */
body.app-light .app-dock {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  max-width: 480px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  padding: 6px 6px calc(8px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  box-shadow: 0 -6px 20px rgba(15, 23, 42, 0.06);
}

body.app-light .dock-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 2px;
  padding: 4px;
  border-radius: 12px;
  font-size: 0.62rem;
  color: var(--text-secondary);
  text-decoration: none;
}

body.app-light .dock-tab.active {
  color: var(--brand);
  font-weight: 600;
}

.dock-svg {
  width: 22px;
  height: 22px;
}

/* ----------- 浅色内页（卡·账户 / 金融 / 会员） ----------- */
.page-shell {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding-bottom: var(--dock-h);
  background: var(--page-bg);
}

.page-shell .page-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: var(--card-bg);
  border-bottom: 1px solid var(--line);
}

.page-shell .page-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.page-shell .page-signout {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.page-body {
  padding: 14px 16px 24px;
}

.page-card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 14px;
  margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.page-card h3 {
  margin: 0 0 6px;
  font-size: 0.96rem;
}

.page-muted {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* 法律文档 / 关于页（长文可读） */
.page-shell--legal {
  padding-bottom: calc(20px + env(safe-area-inset-bottom));
}

.legal-back {
  font-size: 0.82rem;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.legal-back:hover {
  color: var(--brand-hover);
}

.legal-topbar-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.page-shell .legal-topbar-inner .page-title {
  flex: 1;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.legal-updated {
  margin: 0 0 10px;
  font-size: 0.76rem;
  color: var(--text-secondary);
}

.legal-card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.legal-card h2 {
  margin: 1.35em 0 0.5em;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text);
}

.legal-card h2:first-child {
  margin-top: 0;
}

.legal-card p {
  margin: 0 0 0.75em;
  font-size: 0.86rem;
  line-height: 1.62;
  color: var(--text);
}

.legal-card p:last-child {
  margin-bottom: 0;
}

.legal-card ol,
.legal-card ul {
  margin: 0 0 0.85em;
  padding-left: 1.35em;
  font-size: 0.86rem;
  line-height: 1.62;
}

.legal-card li {
  margin-bottom: 0.45em;
}

.legal-note {
  margin-top: 0;
  padding: 10px 12px;
  background: var(--brand-soft);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(98, 54, 255, 0.18);
}

.legal-note p {
  font-size: 0.82rem !important;
  margin-bottom: 0.35em !important;
}

.about-tagline {
  margin: -4px 0 14px;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

.about-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 8px;
}

.about-metric {
  text-align: center;
  padding: 12px 6px;
  background: rgba(98, 54, 255, 0.06);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
}

.about-metric strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--brand);
}

.about-metric span {
  display: block;
  margin-top: 4px;
  font-size: 0.7rem;
  color: var(--text-secondary);
}

body.auth-dark {
  min-height: 100dvh;
  background: radial-gradient(900px 500px at 50% -10%, #2a3370 0%, #0f1117 52%);
  color: #eef1ff;
}

.auth-dark a {
  color: #aab8ff;
}

.panel {
  max-width: 400px;
  margin: 0 auto;
  padding: 28px 20px;
}

.logo-block {
  text-align: center;
  margin-bottom: 22px;
}

.logo-ring {
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  border-radius: 18px;
  background-image: url("../images/logo.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.auth-dark .hero-title {
  font-size: clamp(1.35rem, 4.5vw, 1.6rem);
  font-weight: 700;
}

.auth-dark .muted {
  color: #9aa4bf;
}

.form-row {
  margin-bottom: 14px;
}

.form-row label {
  display: block;
  font-size: 0.8rem;
  color: #9aa4bf;
  margin-bottom: 6px;
}

.field {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 18, 28, 0.75);
  color: #eef1ff;
  padding: 11px 12px;
  font-size: 1rem;
}

.field:focus {
  outline: 2px solid rgba(98, 54, 255, 0.45);
}

.btn {
  border: none;
  border-radius: 12px;
  padding: 12px;
  font-size: 1rem;
  width: 100%;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, #7b5dff, var(--brand));
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: #aab8ff;
  border: 1px solid rgba(98, 54, 255, 0.45);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #eef1ff;
}

.hint-row {
  display: flex;
  justify-content: space-between;
  margin-top: 18px;
  font-size: 0.82rem;
}

.alert {
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 0.84rem;
}

.alert-error {
  background: rgba(255, 107, 129, 0.12);
  border: 1px solid rgba(255, 107, 129, 0.3);
}

.alert-success {
  background: rgba(77, 225, 193, 0.12);
  border: 1px solid rgba(77, 225, 193, 0.25);
}

.badge-pill {
  font-size: 0.72rem;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-weight: 600;
}

/* ========== 卡·账户页（与首页 / 个人中心同色浅色壳） ========== */
.wallet-shell--light {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding-bottom: var(--dock-h);
  background: var(--page-bg);
}

.wallet-page-header {
  background: var(--card-bg);
  border-bottom: 1px solid var(--line);
  padding: 12px 16px 14px;
}

.wallet-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.wallet-card-picker {
  flex: 1;
  min-width: 0;
}

.wallet-card-picker-placeholder {
  flex: 1;
  min-width: 0;
}

.wallet-single-card-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.wallet-card-tabs {
  display: inline-flex;
  align-items: stretch;
  max-width: 100%;
  padding: 3px;
  border-radius: 12px;
  background: #f3f4f6;
  border: 1px solid var(--line);
  gap: 2px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.wallet-card-tabs::-webkit-scrollbar {
  display: none;
}

.wallet-card-tab {
  appearance: none;
  border: none;
  padding: 7px 14px;
  font-size: 0.76rem;
  font-weight: 700;
  border-radius: 9px;
  cursor: pointer;
  color: var(--text-secondary);
  background: transparent;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s, box-shadow 0.15s;
}

.wallet-card-tab.active {
  background: #fff;
  color: var(--brand);
  box-shadow: 0 1px 4px rgba(98, 54, 255, 0.12);
}

.wallet-bell-light {
  position: relative;
  border: none;
  background: rgba(98, 54, 255, 0.08);
  color: var(--text);
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}

.wallet-bell-light:active {
  background: rgba(98, 54, 255, 0.14);
}

.wallet-bell-dot-light {
  position: absolute;
  bottom: 8px;
  right: 9px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ef4444;
}

.wallet-intro {
  margin-top: 12px;
}

.wallet-welcome-light {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.wallet-page-title-light {
  margin: 4px 0 0;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}

.wallet-panels-wrap {
  padding: 5px 0 24px;
}

.wallet-card-slot {
  display: none;
}

.wallet-card-slot.active {
  display: block;
}

.wallet-card-multi .wallet-debit-card {
  margin-bottom: 0;
}

.wallet-body-below-cards {
  padding-top: 4px;
}

.wallet-debit-card--visa {
  background: radial-gradient(ellipse 120% 90% at 50% 120%, rgba(30, 58, 138, 0.35), transparent 55%),
    linear-gradient(145deg, #172554 0%, #1e3a5f 42%, #0f172a 100%);
}

.wcard-visa-badge {
  flex-shrink: 0;
  align-self: flex-end;
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.95);
  opacity: 0.9;
}

.wallet-view-panel[hidden] {
  display: none !important;
}

.wallet-card-panel--light {
  /*margin: 0 14px;*/
  /*background: var(--card-bg);*/
  /*border: 1px solid var(--line);*/
  /*border-radius: var(--radius-xl);*/
  /*padding: 16px;*/
  /*box-shadow: var(--shadow);*/
}

.wallet-empty-hint-light {
  margin: 0;
  font-size: 0.84rem;
  color: var(--text-secondary);
  text-align: center;
  padding: 28px 12px;
}

.wallet-debit-card {
  position: relative;
  border-radius: 16px;
  min-height: 168px;
  padding: 14px 16px 16px;
  background: radial-gradient(ellipse 120% 90% at 50% 120%, rgba(80, 80, 90, 0.5), transparent 55%),
    linear-gradient(145deg, #0a0a0c 0%, #1a1a20 42%, #0d0d12 100%);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.wcard-glow {
  position: absolute;
  inset: -40% -20% auto;
  height: 70%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.07) 0%, transparent 65%);
  pointer-events: none;
}

.wcard-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 2;
}

.wcard-brand {
  display: flex;
  align-items: center;
  gap: 6px;
}

.wcard-brand-moon {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #f8fafc, #94a3b8 45%, #64748b);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.wcard-brand-txt {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: rgba(248, 250, 252, 0.95);
}

.wcard-type {
  font-size: 0.74rem;
  color: rgba(226, 232, 240, 0.75);
}

.wcard-moon-art {
  position: absolute;
  right: -8%;
  top: 18%;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(255, 255, 255, 0.95), rgba(200, 210, 220, 0.55) 28%, transparent 72%);
  box-shadow: inset -12px -8px 24px rgba(0, 0, 0, 0.35);
  opacity: 0.92;
  pointer-events: none;
}

.wcard-chip {
  position: relative;
  z-index: 2;
  width: 38px;
  height: 28px;
  margin-top: 18px;
  border-radius: 6px;
  background: linear-gradient(135deg, #d4af37 0%, #fde68a 35%, #b45309 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.wcard-pan {
  position: relative;
  z-index: 2;
  margin-top: 14px;
  font-size: 1.02rem;
  letter-spacing: 0.14em;
  font-weight: 500;
  color: #e2e8f0;
  font-variant-numeric: tabular-nums;
}

.wcard-bottom {
  position: relative;
  z-index: 2;
  margin-top: 14px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
}

.wcard-name {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: rgba(226, 232, 240, 0.78);
}

.wcard-exp {
  font-size: 0.72rem;
  color: rgba(226, 232, 240, 0.65);
  margin-left: auto;
  margin-right: 8px;
}

.wcard-network {
  position: relative;
  width: 44px;
  height: 26px;
  flex-shrink: 0;
}

.wcard-network::before,
.wcard-network::after {
  content: "";
  position: absolute;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  top: 0;
  opacity: 0.88;
}

.wcard-network::before {
  left: 0;
  background: #eb001b;
}

.wcard-network::after {
  left: 14px;
  background: #f79e1b;
}

.wallet-card-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.wcard-act-light {
  flex: 1;
  border: 1px solid var(--line);
  background: #f9fafb;
  color: var(--text);
  border-radius: 999px;
  padding: 9px 6px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
}

.wcard-act-light:active {
  background: var(--brand-soft);
  border-color: rgba(98, 54, 255, 0.25);
}

.wallet-body-light {
  padding: 0 10px;
  /*margin-top: 20px;*/
}

.wallet-section-title {
  margin: 0 0 10px;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text);
}

.wallet-account-list {
  list-style: none;
  margin: 0;
  padding: 0;
  background: #fff;
  border-radius: 14px;
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: 0 2px 14px rgba(15, 23, 42, 0.05);
}

.wallet-account-row {
  padding: 14px;
  border-bottom: 1px solid #eef0f4;
}

.wallet-account-row:last-child {
  border-bottom: 0;
}

.wallet-account-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wallet-flag {
  /*font-size: 1.35rem;*/
  /*line-height: 1;*/
  width: 50px;
  /*text-align: center;*/
}
.wallet-flag img{
  width: 50px;
}

.wallet-account-meta {
  flex: 1;
  min-width: 0;
}

.wallet-account-name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 700;
  color: #111827;
}

.wallet-badge-primary {
  font-size: 0.6rem;
  font-weight: 700;
  color: #854d0e;
  background: #fef08a;
  padding: 2px 7px;
  border-radius: 6px;
}

.wallet-balance {
  font-size: 0.9rem;
  font-weight: 700;
  color: #111827;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.wallet-account-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.wallet-pill-act {
  border: 1px solid var(--line);
  min-width: 100px;
  background: #f9fafb;
  color: var(--text);
  border-radius: 9px;
  padding: 9px 6px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
}

.wallet-pill-act:active {
  filter: brightness(0.96);
}

.wallet-account-actions a.wallet-pill-act {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: inherit;
  box-sizing: border-box;
}

/* ----------- TRC20 充值（全屏收款，参考移动端钱包收款页） ----------- */
body.trc20-layer-open {
  overflow: hidden;
}

.trc20-layer {
  position: fixed;
  inset: 0;
  z-index: 160;
  display: flex;
  flex-direction: column;
  max-width: 480px;
  margin: 0 auto;
  background: linear-gradient(180deg, #1b6bdc 0%, #4dabf7 52%, #7ec8fb 100%);
  color: #fff;
}

.trc20-layer-top {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(12px + env(safe-area-inset-top)) 12px 10px;
  gap: 8px;
}

.trc20-back-btn {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  text-decoration: none;
  box-sizing: border-box;
}

a.trc20-back-btn {
  border: none;
}

.trc20-back-btn:active {
  background: rgba(255, 255, 255, 0.22);
}

.trc20-layer-title {
  flex: 1;
  text-align: center;
  font-size: 1.02rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin: 0;
}

.trc20-layer-scroll {
  flex: 1;
  overflow: auto;
  padding: 6px 14px 20px;
  -webkit-overflow-scrolling: touch;
}

.trc20-sheet {
  background: #fff;
  border-radius: 18px;
  padding: 14px 14px 12px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.16);
  color: var(--text);
}

.trc20-warn {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #fff4e6;
  border: 1px solid #ffd8a8;
  color: #9a3412;
  font-size: 0.78rem;
  line-height: 1.45;
  margin-bottom: 16px;
}

.trc20-warn-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fb923c;
  color: #fff;
  font-weight: 800;
  font-size: 0.72rem;
  display: grid;
  place-items: center;
}

.trc20-qr-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 14px;
}

.trc20-qr-frame {
  position: relative;
  padding: 10px;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px solid #eef2f7;
}

.trc20-qr-canvas-wrap {
  position: relative;
  display: inline-block;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.trc20-qr-canvas-wrap canvas {
  display: block;
  vertical-align: top;
}

.trc20-qr-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #e8f5ef;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 0.62rem;
  font-weight: 800;
  color: #059669;
  line-height: 1.05;
  pointer-events: none;
}

.trc20-qr-badge span {
  font-weight: 700;
  opacity: 0.78;
}

.trc20-qr-placeholder {
  width: 240px;
  height: 240px;
  border-radius: 10px;
  background: repeating-linear-gradient(
    -45deg,
    #f1f5f9,
    #f1f5f9 10px,
    #e9eef5 10px,
    #e9eef5 20px
  );
  display: grid;
  place-items: center;
  text-align: center;
  padding: 14px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  border: 1px dashed var(--line);
}

.trc20-addr-panel {
  background: #f4f6f9;
  border-radius: 12px;
  padding: 12px 12px 10px;
  margin-bottom: 6px;
}

.trc20-addr-label {
  margin: 0 0 6px;
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.trc20-addr-value {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.48;
  word-break: break-all;
  font-variant-numeric: tabular-nums;
}

.trc20-amount-hint {
  margin: 10px 0 0;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--brand);
  text-align: center;
  min-height: 1.2em;
}

.trc20-actions {
  display: grid;
  grid-template-columns: 1fr 1px 1fr 1px 1fr;
  align-items: stretch;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid #eef0f4;
}

.trc20-actions-split {
  background: linear-gradient(#fff, #e5e7eb, #fff);
}

.trc20-act {
  border: none;
  background: none;
  display: flex;
  flex-direction: inherit;
  align-items: center;
  /*gap: 4px;*/
  padding: 6px 4px 4px;
  cursor: pointer;
  color: #374151;
  font-size: 0.7rem;
  font-weight: 600;
}

.trc20-act:active {
  opacity: 0.78;
}

.trc20-act svg {
  width: 26px;
  height: 26px;
  color: var(--brand);
}

.trc20-toast {
  position: fixed;
  left: 50%;
  bottom: calc(88px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 170;
  background: rgba(17, 24, 39, 0.88);
  color: #fff;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  max-width: min(86vw, 360px);
  text-align: center;
}

.trc20-toast.is-on {
  opacity: 1;
}

.trc20-brand-foot {
  flex-shrink: 0;
  text-align: center;
  padding: 10px 12px calc(12px + env(safe-area-inset-bottom));
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.78);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.12);
}

/* 移除本页 Dock 金色高亮：沿用全局紫色选中态 */

/* ========== 个人中心 ========== */
.profile-shell {
  overflow: hidden;
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding-bottom: var(--dock-h);
  background: var(--page-bg);
}

.profile-top {
  padding: 14px 16px 10px;
  background: var(--card-bg);
  border-bottom: 1px solid var(--line);
}

.profile-top-title {
  margin: 0;
  font-size: 1.12rem;
  font-weight: 800;
}

.profile-hero-card {
  margin: 12px 14px 0;
  padding: 18px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, #5c3ee8 0%, var(--brand) 48%, #4c1d95 100%);
  color: #fff;
  display: flex;
  gap: 14px;
  align-items: center;
  box-shadow: 0 14px 32px rgba(98, 54, 255, 0.32);
}

.profile-avatar {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(6px);
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  font-weight: 800;
  border: 2px solid rgba(255, 255, 255, 0.35);
}

.profile-hero-main {
  min-width: 0;
  flex: 1;
}

.profile-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-name {
  font-size: 1.15rem;
  font-weight: 800;
}

.profile-level {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.profile-email {
  margin: 8px 0 0;
  font-size: 0.78rem;
  opacity: 0.88;
  word-break: break-all;
}

.profile-id-hint {
  margin: 6px 0 0;
  font-size: 0.65rem;
  opacity: 0.65;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 12px 14px 0;
  padding: 14px;
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
}

.profile-stat {
  text-align: center;
}

.profile-stat strong {
  display: block;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
}

.profile-stat span {
  font-size: 0.68rem;
  color: var(--text-secondary);
  margin-top: 4px;
  display: block;
}

.profile-block {
  margin: 14px 14px 0;
}

.profile-block-title {
  margin: 0 0 8px 8px;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.profile-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--card-bg);
}

.profile-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 14px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.92rem;
  border-bottom: 1px solid #f3f4f6;
}

.profile-menu li:last-child .profile-menu-item {
  border-bottom: 0;
}

.profile-menu-item:active {
  background: #f9fafb;
}

.profile-mi-icon {
  width: 28px;
  text-align: center;
  flex-shrink: 0;
}

.profile-mi-text {
  flex: 1;
  min-width: 0;
  font-weight: 600;
}

.profile-mi-tag {
  font-size: 0.58rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(90deg, #f59e0b, #ea580c);
  padding: 2px 6px;
  border-radius: 6px;
}

.profile-mi-meta {
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.profile-mi-chevron {
  color: #c4c9d4;
  font-size: 1.2rem;
  font-weight: 300;
}

.profile-logout-wrap {
  padding: 20px 14px 28px;
}

.profile-logout-btn {
  display: block;
  text-align: center;
  padding: 13px;
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  border: 1px solid var(--line);
  color: #dc2626;
  font-weight: 700;
  font-size: 0.94rem;
  text-decoration: none;
}

.profile-logout-btn:active {
  background: #fef2f2;
}

/* ========== 申请卡片（二级页） ========== */
.apply-page-body .apply-shell {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding-bottom: var(--dock-h);
  background: var(--page-bg);
}

.apply-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 8px 10px 4px;
  background: var(--card-bg);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.apply-back {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--text);
  text-decoration: none;
  border-radius: 10px;
}

.apply-back:active {
  background: #f3f4f6;
}

.apply-nav-title {
  flex: 1;
  margin: 0;
  font-size: 1.06rem;
  font-weight: 800;
  text-align: center;
}

.apply-nav-spacer {
  width: 40px;
}

.apply-scroll {
  padding: 16px 16px 32px;
}

.apply-lead {
  margin: 0 0 16px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

.apply-alert {
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 0.84rem;
}

.apply-alert-error {
  background: rgba(244, 63, 94, 0.1);
  border: 1px solid rgba(244, 63, 94, 0.35);
  color: #be123c;
}

.apply-field {
  margin-bottom: 16px;
}

.apply-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.apply-optional {
  font-weight: 500;
  color: var(--text-secondary);
}

.apply-input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--card-bg);
  color: var(--text);
  padding: 12px 14px;
  font-size: 1rem;
  box-sizing: border-box;
}

.apply-input:focus {
  outline: 2px solid rgba(98, 54, 255, 0.35);
  border-color: rgba(98, 54, 255, 0.45);
}

.apply-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12'%3E%3Cpath fill='%236e6e80' d='M2 4l4 5 4-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.apply-textarea {
  resize: vertical;
  min-height: 88px;
}

.apply-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.76rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 18px 0 20px;
  cursor: pointer;
}

.apply-check input {
  margin-top: 2px;
  accent-color: var(--brand);
}

.apply-check a {
  color: var(--brand);
}

.apply-submit {
  width: 100%;
  border: none;
  border-radius: 14px;
  padding: 14px;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #7b5dff, var(--brand));
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(98, 54, 255, 0.28);
}

.apply-submit:active {
  filter: brightness(0.95);
}

/* 卡·账户：申请入口与成功提示 */
.wallet-intro-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.wallet-apply-link {
  flex-shrink: 0;
  font-size: 0.76rem;
  font-weight: 700;
  color: #fff;
  background: var(--brand);
  padding: 7px 12px;
  border-radius: 999px;
  text-decoration: none;
  white-space: nowrap;
  margin-top: 2px;
}

.wallet-apply-link:active {
  filter: brightness(0.93);
}

.wallet-flash {
  margin: 0 14px 12px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 600;
}

.wallet-flash-ok {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.28);
  color: #047857;
}

.wallet-panel-apply-more {
  display: block;
  margin-top: 12px;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--brand);
  text-decoration: none;
}

.wallet-panel-apply-more:active {
  opacity: 0.85;
}
