/* VanSnow Core Application Styles — Clean-sheet, Zero Legacy Bloat */
*, *::before, *::after { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: var(--text-md);
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.vip-mode {
  background: var(--vip-bg);
  color: var(--vip-text);
}
button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}
button { cursor: pointer; }
img { display: block; max-width: 100%; }

/* ============ Desktop Phone Preview Frame Wrapper ============ */
body.phone-frame {
  background: radial-gradient(circle at 20% 10%, #172B47 0%, #090F1B 70%);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 20px 16px;
}
body.phone-frame .app-shell {
  width: 393px;
  max-width: 100%;
  height: 852px;
  max-height: calc(100vh - 40px);
  border-radius: 42px;
  overflow: hidden;
  border: 6px solid #1E2E45;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255,255,255,0.08);
  position: relative;
  background: var(--bg);
  display: flex;
  flex-direction: column;
}
body.phone-frame.vip-mode .app-shell { background: var(--vip-bg); }
body.phone-frame .app-main {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding-bottom: 92px;
}
body.phone-frame .bottom-nav {
  position: absolute;
  left: 0; right: 0; bottom: 0;
}
body.phone-frame .splash-overlay,
body.phone-frame .auth-overlay {
  position: absolute;
}
body.phone-frame .desktop-only { display: none !important; }

/* ============ App Shell & Sticky Header ============ */
.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
}
.app-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
  transition: background 0.3s ease, border-color 0.3s ease;
}
body.vip-mode .app-header {
  background: rgba(8, 13, 24, 0.88);
  border-bottom-color: var(--vip-line);
}
.header-inner {
  max-width: var(--max-w);
  height: 100%;
  margin: 0 auto;
  padding: 0 var(--sp-4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
}
.brand-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 0;
  background: transparent;
  padding: 0;
  min-height: var(--tap);
  color: inherit;
}
.brand-btn img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  box-shadow: 0 2px 8px rgba(18, 35, 58, 0.18);
}
.brand-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
}
.brand-title {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--navy);
}
body.vip-mode .brand-title { color: var(--vip-gold-light); }
.brand-city {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 4px;
}
body.vip-mode .brand-city { color: var(--vip-muted); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.pill-btn {
  min-height: 36px;
  height: 38px;
  padding: 0 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--navy);
  font-size: var(--text-xs);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.pill-btn:hover { background: var(--surface-subtle); }
body.vip-mode .pill-btn {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--vip-line);
  color: var(--vip-gold-light);
}
.pill-btn.active {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}

/* ============ Main Content Container ============ */
.app-main {
  flex: 1;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--sp-4) var(--sp-4) calc(var(--bottom-nav-h) + 28px);
}
.view-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}
.view-eyebrow {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--glacier);
  margin-bottom: 2px;
}
.view-title {
  margin: 0;
  font-size: var(--title-md);
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--navy);
  line-height: 1.2;
}
.view-sub {
  margin: 4px 0 0;
  font-size: var(--text-sm);
  color: var(--muted);
}

/* ============ Buttons & Controls (all >= 44px tap target) ============ */
.btn {
  min-height: var(--tap);
  padding: 0 18px;
  border-radius: var(--r-md);
  border: 1px solid transparent;
  font-size: var(--text-md);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.14s ease, background 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: linear-gradient(135deg, var(--navy) 0%, #1B3B63 100%);
  color: #fff;
  box-shadow: 0 6px 18px rgba(18, 35, 58, 0.22);
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-glacier {
  background: linear-gradient(135deg, #1D74C6 0%, #3E9CE0 100%);
  color: #fff;
  box-shadow: 0 6px 16px rgba(29, 116, 198, 0.24);
}
.btn-outline {
  background: var(--surface);
  color: var(--navy);
  border-color: var(--line-strong);
}
.btn-outline:hover { background: var(--surface-subtle); }
.btn-ghost {
  background: transparent;
  color: var(--muted);
}
.btn-sm {
  min-height: 40px;
  padding: 0 14px;
  font-size: var(--text-sm);
  border-radius: var(--r-sm);
}
.btn-block { width: 100%; }

/* Segmented Tabs & Horizontal Filter Pills (compact, single-row, no vertical bloat) */
.seg-control {
  display: inline-flex;
  background: var(--surface-subtle);
  padding: 4px;
  border-radius: var(--r-md);
  gap: 4px;
  width: 100%;
  margin-bottom: var(--sp-3);
}
.seg-btn {
  flex: 1;
  min-height: var(--tap);
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--muted);
  font-size: var(--text-md);
  font-weight: 700;
  transition: all 0.2s ease;
}
.seg-btn.active {
  background: var(--surface);
  color: var(--navy);
  box-shadow: var(--shadow-sm);
}

.filter-scroll {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin-bottom: var(--sp-3);
  scrollbar-width: none;
}
.filter-scroll::-webkit-scrollbar { display: none; }
.chip {
  min-height: var(--tap);
  padding: 0 14px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--text-sm);
  font-weight: 600;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.18s ease;
  flex-shrink: 0;
}
.chip.active {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}
.chip.official-chip {
  border-color: rgba(29, 116, 198, 0.35);
  background: var(--glacier-soft);
  color: var(--navy);
}
.chip.official-chip.active {
  background: var(--glacier);
  color: #fff;
  border-color: var(--glacier);
}

/* ============ Glass Bottom Navigation (5 Core Tabs) ============ */
.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 45;
  height: var(--bottom-nav-h);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: center;
  transition: background 0.3s ease, border-color 0.3s ease;
}
body.vip-mode .bottom-nav {
  background: rgba(8, 13, 24, 0.94);
  border-top-color: var(--vip-line);
}
.bottom-nav-inner {
  width: 100%;
  max-width: 600px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  align-items: center;
  padding: 0 2px;
}
.nav-tab {
  min-height: 54px;
  border: 0;
  background: transparent;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 10.5px;
  font-weight: 700;
  position: relative;
  padding: 0 2px;
  white-space: nowrap;
  transition: color 0.2s ease, transform 0.15s ease;
}
.nav-tab svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.nav-tab.active { color: var(--navy); }
body.vip-mode .nav-tab { color: var(--vip-muted); }
body.vip-mode .nav-tab.active { color: var(--vip-gold-light); }

/* Special Golden Diamond Styling for the VIP Find Buddies Tab */
.nav-tab.vip-tab {
  color: #9A742B;
}
.nav-tab.vip-tab .vip-icon-wrap {
  width: 40px;
  height: 30px;
  border-radius: 12px;
  background: linear-gradient(135deg, #111A2C 0%, #1F2E49 100%);
  border: 1px solid rgba(229, 196, 124, 0.55);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--vip-gold-light);
  box-shadow: 0 4px 14px rgba(18, 35, 58, 0.25);
}
.nav-tab.vip-tab.active .vip-icon-wrap {
  background: linear-gradient(135deg, #E5C47C 0%, #C69A4A 100%);
  color: #080D18;
  box-shadow: 0 4px 18px rgba(229, 196, 124, 0.45);
}
.nav-tab.vip-tab.active { color: var(--vip-gold-light); }
body:not(.vip-mode) .nav-tab.vip-tab { color: #8A6520; }

/* ============ Co-Branded Splash Screen (VanSnow × Infinity Ski) ============ */
.splash-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: radial-gradient(circle at 50% 28%, #1A375D 0%, #0C182B 58%, #060B14 100%);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow: hidden;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}
.splash-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.splash-skip {
  position: absolute;
  top: 20px;
  right: 20px;
  min-height: 40px;
  padding: 0 16px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.9);
  font-size: var(--text-xs);
  font-weight: 700;
}
.splash-lockup {
  display: flex;
  align-items: center;
  gap: 18px;
  animation: splashRise 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.splash-logo-card {
  width: 74px;
  height: 74px;
  border-radius: 20px;
  padding: 4px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(111, 183, 232, 0.35);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
}
.splash-x {
  font-size: 22px;
  font-weight: 300;
  color: var(--vip-gold);
  opacity: 0.9;
}
.splash-partner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}
.splash-partner img {
  height: 36px;
  width: auto;
}
.splash-partner-tag {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--vip-gold-light);
  opacity: 0.85;
}
.splash-logo-clean {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.38);
}
.splash-inf-cutout {
  height: 66px;
  width: auto;
  display: block;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.45));
}
.splash-tagline-zh {
  margin: 8px 0 4px;
  font-size: 18px;
  font-weight: 700;
  color: #F4F9FD;
  letter-spacing: 0.1em;
  text-align: center;
  animation: splashRise 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.splash-tagline-en {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: #9CCCF0;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  animation: splashRise 1.1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.ad-card.photo-ad {
  min-height: 118px;
  border-color: rgba(111, 183, 232, 0.48);
  box-shadow: 0 10px 28px rgba(11, 22, 38, 0.22);
}
.splash-headline {
  margin: 14px 0 6px;
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-align: center;
  animation: splashRise 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.splash-quote {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  color: #B6DCFA;
  letter-spacing: 0.02em;
  text-align: center;
  animation: splashRise 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.splash-sub {
  margin: 0;
  font-size: var(--text-xs);
  color: rgba(243, 248, 252, 0.72);
  text-align: center;
  max-width: 340px;
  line-height: 1.5;
  animation: splashRise 1.1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.splash-bar-track {
  margin-top: 28px;
  width: 230px;
  height: 4px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.14);
  overflow: hidden;
}
.splash-bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #6FB7E8 0%, #E5C47C 100%);
  border-radius: var(--r-pill);
  animation: splashFill 3.65s cubic-bezier(0.22, 0.8, 0.28, 1) forwards;
}
.splash-addr {
  position: absolute;
  bottom: 26px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.48);
  letter-spacing: 0.04em;
}
@keyframes splashRise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes splashFill {
  from { width: 0%; }
  to { width: 100%; }
}

/* ============ 5-Way Auth Screen ============ */
.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 150;
  background: linear-gradient(165deg, #0D1E34 0%, #132C4A 45%, #0A1424 100%);
  color: #fff;
  overflow-y: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}
.auth-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.auth-card {
  width: 100%;
  max-width: 400px;
  background: rgba(17, 29, 49, 0.86);
  backdrop-filter: blur(22px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  padding: 28px 22px 22px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}
.auth-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.auth-cobrand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: var(--r-pill);
  background: rgba(229, 196, 124, 0.12);
  border: 1px solid rgba(229, 196, 124, 0.3);
  font-size: 11px;
  font-weight: 700;
  color: var(--vip-gold-light);
}
.auth-title {
  margin: 0 0 6px;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.auth-sub {
  margin: 0 0 20px;
  font-size: var(--text-sm);
  color: rgba(240, 246, 252, 0.74);
  line-height: 1.5;
}
.oauth-stack {
  display: grid;
  gap: 10px;
}
.oauth-btn {
  min-height: 48px;
  width: 100%;
  border-radius: var(--r-md);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-size: var(--text-md);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.14s ease, filter 0.2s ease;
}
.oauth-btn:active { transform: scale(0.98); }
.oauth-apple { background: #FFFFFF; color: #0B0F17; border-color: #FFFFFF; }
.oauth-google { background: rgba(255, 255, 255, 0.1); color: #FFFFFF; }
.oauth-x { background: #07090D; color: #FFFFFF; border-color: rgba(255,255,255,0.22); }
.oauth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
  color: rgba(255, 255, 255, 0.45);
  font-size: var(--text-xs);
}
.oauth-divider::before, .oauth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.14);
}
.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  border-radius: var(--r-md);
  margin-bottom: 12px;
}
.auth-tab {
  min-height: 40px;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: rgba(255, 255, 255, 0.65);
  font-size: var(--text-sm);
  font-weight: 700;
}
.auth-tab.active {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}
.auth-input-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.auth-input {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border-radius: var(--r-md);
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
  outline: none;
}
.auth-input::placeholder { color: rgba(255, 255, 255, 0.42); }
.auth-input:focus { border-color: var(--glacier-bright); }
.auth-code-btn {
  min-height: 46px;
  padding: 0 14px;
  border-radius: var(--r-md);
  border: 1px solid rgba(111, 183, 232, 0.4);
  background: rgba(111, 183, 232, 0.14);
  color: #B9E2FC;
  font-weight: 700;
  font-size: var(--text-xs);
  white-space: nowrap;
}
.auth-guest {
  margin-top: 14px;
  width: 100%;
  min-height: var(--tap);
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.78);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.auth-footnote {
  margin: 10px 0 0;
  text-align: center;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.44);
}

/* ============ Cards, Events, Coaches, Carpool, Xianyu Market ============ */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.stack { display: grid; gap: var(--sp-3); }
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--sp-3);
}
@media (max-width: 640px) {
  .grid-2.desktop-2 { grid-template-columns: 1fr; }
}

/* Event Card */
.event-card {
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.event-card:hover { box-shadow: var(--shadow-md); }
.event-cover {
  position: relative;
  height: 176px;
  background: var(--navy);
  overflow: hidden;
}
.event-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.event-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11,22,38,0.08) 0%, rgba(11,22,38,0.72) 100%);
}
.event-badges {
  position: absolute;
  top: 12px;
  left: 12px;
  right: 12px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  flex-shrink: 0;
}
.badge-navy { background: rgba(18, 35, 58, 0.85); color: #fff; backdrop-filter: blur(8px); }
.badge-gold { background: linear-gradient(135deg, #E5C47C, #C89B45); color: #0B1220; }
.badge-glacier { background: var(--glacier-soft); color: var(--glacier); }
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }

.event-cover-bottom {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 12px;
  z-index: 2;
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 8px;
}
.event-cover-title {
  font-size: 17px;
  font-weight: 800;
  margin: 0;
  line-height: 1.25;
}
.event-price {
  font-size: 16px;
  font-weight: 800;
  color: var(--vip-gold-light);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.event-body {
  padding: 14px;
  display: grid;
  gap: 10px;
}
.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: var(--text-xs);
  color: var(--muted);
  font-weight: 600;
}
.event-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

/* Native Editorial Sponsored Ad Card */
.ad-card {
  position: relative;
  border-radius: var(--r-lg);
  padding: 16px;
  background: linear-gradient(135deg, #0E223A 0%, #17375D 65%, #1C4B7A 100%);
  color: #fff;
  border: 1px solid rgba(111, 183, 232, 0.35);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.ad-card.gold-ad {
  background: linear-gradient(135deg, #111827 0%, #1F2937 60%, #2B2418 100%);
  border-color: rgba(229, 196, 124, 0.45);
}
.ad-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.14);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #CFE9FA;
  margin-bottom: 6px;
}
.ad-title {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 800;
}
.ad-desc {
  margin: 0;
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.45;
}
.ad-cta {
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--r-pill);
  border: 0;
  background: #fff;
  color: var(--navy);
  font-size: var(--text-xs);
  font-weight: 800;
  white-space: nowrap;
  flex-shrink: 0;
}
.ad-card.gold-ad .ad-cta {
  background: linear-gradient(135deg, #E5C47C, #F5E0AC);
  color: #0B1220;
}

/* Coach Card */
.coach-card {
  padding: 16px;
  display: grid;
  gap: 12px;
}
.coach-top {
  display: flex;
  align-items: center;
  gap: 12px;
}
.coach-avatar {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  object-fit: cover;
  border: 2px solid var(--glacier-soft);
}
.coach-rate {
  margin-left: auto;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.coach-rate strong { font-size: 18px; color: var(--navy); display: block; }
.coach-rate span { font-size: 11px; color: var(--muted); }

/* Carpool Card (Vertical Route Timeline) */
.date-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 14px 0 8px;
  font-size: var(--text-sm);
  font-weight: 800;
  color: var(--navy);
}
.trip-card {
  padding: 15px;
  display: grid;
  gap: 12px;
}
.trip-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.trip-time {
  font-size: 18px;
  font-weight: 800;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
}
.trip-price {
  font-size: 17px;
  font-weight: 800;
  color: var(--glacier);
  font-variant-numeric: tabular-nums;
}
.route-line {
  display: grid;
  gap: 6px;
  padding-left: 16px;
  border-left: 2px dashed rgba(29, 116, 198, 0.35);
  position: relative;
}
.route-node {
  position: relative;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.route-node::before {
  content: "";
  position: absolute;
  left: -21px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--glacier);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--glacier);
}
.route-node.dest::before { background: var(--navy); box-shadow: 0 0 0 1px var(--navy); }
.trip-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.driver-mini {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.driver-dot {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.disclaimer-box {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: var(--r-md);
  background: var(--surface-subtle);
  font-size: var(--text-xs);
  color: var(--muted);
  line-height: 1.5;
}

/* Secondhand Xianyu 2-Column Market Grid */
.market-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
@media (min-width: 760px) {
  .market-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.gear-card {
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.2s ease;
}
.gear-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.gear-img-wrap {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--surface-subtle);
  overflow: hidden;
}
.gear-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gear-cond {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(18, 35, 58, 0.82);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}
.gear-body {
  padding: 10px 12px 12px;
  display: grid;
  gap: 6px;
}
.gear-title {
  margin: 0;
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.35;
}
.gear-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
}
.gear-price {
  font-size: 17px;
  font-weight: 800;
  color: #C93A2B;
  font-variant-numeric: tabular-nums;
}
.gear-orig {
  font-size: 11px;
  color: var(--muted);
  text-decoration: line-through;
}
.gear-inspect {
  font-size: 11px;
  font-weight: 700;
  color: var(--glacier);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ============ Profile, Commercial Hub, Ads Media Kit & Vision ============ */
.profile-hero {
  background: linear-gradient(135deg, #0E223A 0%, #193A62 100%);
  color: #fff;
  border-radius: var(--r-xl);
  padding: 18px;
  display: grid;
  gap: 14px;
  margin-bottom: var(--sp-4);
  box-shadow: var(--shadow-md);
}
.profile-top {
  display: flex;
  align-items: center;
  gap: 14px;
}
.profile-avatar {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: linear-gradient(135deg, #6FB7E8, #E5C47C);
  color: #0B1220;
  font-size: 22px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.profile-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--r-md);
  padding: 10px 8px;
  text-align: center;
}
.profile-stats strong { display: block; font-size: 17px; font-variant-numeric: tabular-nums; }
.profile-stats span { font-size: 11px; color: rgba(255, 255, 255, 0.72); }

.hub-card {
  padding: 16px;
  border-radius: var(--r-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  border: 1px solid var(--line);
  background: var(--surface);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
  text-align: left;
  width: 100%;
}
.hub-card:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.hub-card.hub-vip {
  background: linear-gradient(135deg, #0D1424 0%, #1C263B 100%);
  border-color: rgba(229, 196, 124, 0.45);
  color: #fff;
}
.hub-card.hub-ads {
  background: linear-gradient(135deg, #102B4A 0%, #1C4D7D 100%);
  border-color: rgba(111, 183, 232, 0.4);
  color: #fff;
}

/* Sub-pages inside Profile (VIP / Ads / Vision) */
.subpage-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: var(--sp-4);
}
.rate-table {
  display: grid;
  gap: 10px;
}
.rate-row {
  padding: 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.vision-timeline {
  display: grid;
  gap: 12px;
}
.vision-step {
  padding: 16px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--surface);
  display: grid;
  gap: 6px;
}
.sport-pill-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.sport-tile {
  padding: 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--surface-subtle);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sport-tile.live {
  background: linear-gradient(135deg, #12233A, #1C4B7A);
  color: #fff;
  border-color: transparent;
}

/* ============ Modal & Toast ============ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 180;
  background: rgba(8, 13, 24, 0.82);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 12px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.22s ease;
}
@media (min-width: 640px) {
  .modal-backdrop { align-items: center; }
}
.modal-backdrop.open {
  opacity: 1;
  visibility: visible;
}
.modal-sheet {
  width: 100%;
  max-width: 480px;
  max-height: 86vh;
  overflow-y: auto;
  background: var(--surface);
  color: var(--ink);
  border-radius: 24px;
  padding: 20px;
  box-shadow: var(--shadow-lg);
  transform: translateY(20px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.modal-backdrop.open .modal-sheet { transform: translateY(0); }
.modal-sheet.vip-sheet {
  background: linear-gradient(180deg, #121B2E 0%, #0A101D 100%);
  color: var(--vip-text);
  border: 1px solid var(--vip-line);
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.modal-title { margin: 0; font-size: 18px; font-weight: 800; }
.close-btn {
  width: var(--tap);
  height: var(--tap);
  border-radius: 50%;
  border: 0;
  background: var(--surface-subtle);
  color: var(--ink);
  font-size: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.vip-sheet .close-btn {
  background: rgba(255, 255, 255, 0.08);
  color: var(--vip-gold-light);
}

.form-group { display: grid; gap: 6px; margin-bottom: 12px; }
.form-label { font-size: var(--text-xs); font-weight: 700; color: var(--muted); }
.form-input, .form-select, .form-textarea {
  width: 100%;
  min-height: var(--tap);
  padding: 10px 12px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  outline: none;
}
.form-textarea { min-height: 84px; resize: vertical; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--glacier); }
.form-error {
  font-size: var(--text-xs);
  color: var(--danger);
  font-weight: 600;
}

.toast {
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translateX(-50%) translateY(-16px);
  z-index: 250;
  background: var(--navy-deep);
  color: #fff;
  padding: 10px 18px;
  border-radius: var(--r-pill);
  font-size: var(--text-sm);
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: all 0.24s ease;
  max-width: calc(100vw - 28px);
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
}
@media (max-width: 767px) {
  .desktop-only { display: none !important; }
}

/* ============ V11 Additions: Interactive Map, AI Appraisal & Profile Moments ============ */
.gmap-card {
  position: relative;
  border-radius: var(--r-xl);
  overflow: hidden;
  border: 1px solid rgba(18, 35, 58, 0.14);
  background: #DCEBF6;
  box-shadow: var(--shadow-md);
  margin-bottom: var(--sp-3);
}
.gmap-svg {
  display: block;
  width: 100%;
  height: 224px;
}
.gmap-toolbar {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}
.gmap-pill {
  pointer-events: auto;
  padding: 6px 11px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(18, 35, 58, 0.12);
  font-size: 11px;
  font-weight: 800;
  color: var(--navy);
  box-shadow: 0 3px 10px rgba(15, 30, 51, 0.12);
}
.gmap-pin-btn {
  cursor: pointer;
  transition: transform 0.18s ease;
}
.gmap-pin-btn:hover { opacity: 0.92; }
.gmap-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 14px;
  background: rgba(255, 255, 255, 0.95);
  border-top: 1px solid var(--line);
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
}

/* Simple 3-Mode Carpool Segmented Bar */
.cp-simple-card {
  padding: 14px 16px;
  display: grid;
  gap: 10px;
}
.cp-route-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: var(--r-md);
  background: var(--surface-subtle);
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
}
.cp-route-arrow {
  color: var(--glacier);
  font-weight: 900;
}

/* AI Gear Appraisal Banner & Consignment Box */
.ai-banner {
  border-radius: var(--r-xl);
  padding: 16px;
  margin-bottom: var(--sp-3);
  background: linear-gradient(135deg, #0D1E36 0%, #17365E 55%, #1E4D7B 100%);
  color: #fff;
  border: 1px solid rgba(229, 196, 124, 0.45);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.ai-scan-box {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 2px dashed rgba(29, 116, 198, 0.4);
  background: var(--surface-subtle);
  min-height: 150px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}
.ai-scan-box img {
  width: 100%;
  height: 170px;
  object-fit: cover;
}
.ai-scan-line {
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, #38BDF8, #E5C47C, transparent);
  box-shadow: 0 0 14px #38BDF8;
  animation: aiScan 1.1s ease-in-out infinite;
}
@keyframes aiScan {
  0% { top: 0%; }
  50% { top: 96%; }
  100% { top: 0%; }
}
.consign-choice {
  padding: 13px;
  border-radius: var(--r-md);
  border: 2px solid var(--line-strong);
  background: var(--surface);
  display: grid;
  gap: 4px;
  cursor: pointer;
  text-align: left;
}
.consign-choice.selected {
  border-color: var(--glacier);
  background: var(--glacier-soft);
}
.consign-choice.gold-selected {
  border-color: #D8B46A;
  background: linear-gradient(135deg, #FFFBF0, #FEF4DA);
}

/* Profile Personal Card & Ski Moments Feed */
.me-showcase {
  position: relative;
  border-radius: var(--r-xl);
  overflow: hidden;
  background: linear-gradient(145deg, #0D192B 0%, #172E4E 65%, #12233A 100%);
  color: #fff;
  box-shadow: var(--shadow-md);
  margin-bottom: var(--sp-4);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.me-showcase-banner {
  height: 92px;
  background: url('../assets/event-whistler.jpg') center/cover no-repeat;
  position: relative;
}
.me-showcase-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13,25,43,0.15) 0%, rgba(13,25,43,0.92) 100%);
}
.me-showcase-body {
  padding: 0 18px 18px;
  margin-top: -40px;
  position: relative;
  z-index: 2;
  display: grid;
  gap: 12px;
}
.me-photo-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}
.me-photo {
  width: 78px;
  height: 78px;
  border-radius: 22px;
  object-fit: cover;
  border: 3px solid #fff;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
}
.me-bio {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  color: rgba(244, 248, 252, 0.88);
  background: rgba(255, 255, 255, 0.07);
  padding: 10px 12px;
  border-radius: var(--r-md);
}
.moment-card {
  padding: 14px;
  display: grid;
  gap: 10px;
}
.moment-img {
  width: 100%;
  height: 185px;
  object-fit: cover;
  border-radius: var(--r-md);
}
.moment-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

/* ============ V12 WeChat-Style Grouped List, Profile & Settings ============ */
.wx-me-card {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 18px 16px 16px;
  margin-bottom: 10px;
  border: 1px solid var(--wx-hairline);
  box-shadow: var(--shadow-sm);
}
.wx-me-top {
  display: flex;
  align-items: center;
  gap: 14px;
}
.wx-avatar {
  width: 66px;
  height: 66px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.wx-me-name {
  margin: 0;
  font-size: var(--title-sm);
  font-weight: 800;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 8px;
}
.wx-me-id {
  font-size: var(--text-xs);
  color: var(--muted);
  margin-top: 3px;
}
.wx-me-bio {
  margin: 12px 0 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--surface-subtle);
  font-size: var(--text-sm);
  color: #3A4352;
  line-height: 1.5;
}
.wx-photo-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 10px;
}
.wx-photo-strip img {
  width: 100%;
  height: 76px;
  object-fit: cover;
  border-radius: 8px;
}
.wx-group {
  background: var(--surface);
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--wx-hairline);
  margin-bottom: 10px;
  box-shadow: var(--shadow-sm);
}
.wx-cell {
  width: 100%;
  min-height: 54px;
  padding: 12px 16px;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  color: var(--ink);
  position: relative;
}
.wx-cell + .wx-cell::before {
  content: "";
  position: absolute;
  top: 0;
  left: 54px;
  right: 0;
  height: 1px;
  background: var(--wx-hairline);
}
.wx-cell:active { background: #F4F5F7; }
.wx-cell-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.wx-ico {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.wx-cell-title {
  font-size: var(--text-md);
  font-weight: 600;
  color: var(--ink);
}
.wx-cell-sub {
  font-size: var(--text-xs);
  color: var(--muted);
  margin-top: 1px;
}
.wx-cell-right {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: var(--text-xs);
  flex-shrink: 0;
}
.wx-chevron {
  font-size: 18px;
  color: #B9C0CB;
  line-height: 1;
}

/* WeChat Green Toggle Switch */
.wx-switch {
  width: 48px;
  height: 28px;
  border-radius: 999px;
  border: 0;
  padding: 2px;
  background: #D9DDE3;
  position: relative;
  transition: background 0.2s ease;
  flex-shrink: 0;
}
.wx-switch::after {
  content: "";
  display: block;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(0,0,0,0.18);
  transition: transform 0.2s ease;
}
.wx-switch.on { background: var(--wx-green); }
.wx-switch.on::after { transform: translateX(20px); }

/* WeChat Font Size Preview Box */
.wx-font-preview {
  background: #EDEDED;
  border-radius: var(--r-md);
  padding: 14px;
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}
.wx-bubble-row { display: flex; gap: 8px; align-items: flex-start; }
.wx-bubble-row.right { justify-content: flex-end; }
.wx-bubble {
  padding: 9px 12px;
  border-radius: 8px;
  font-size: var(--text-md);
  line-height: 1.45;
  max-width: 82%;
}
.wx-bubble.white { background: #fff; color: #191919; }
.wx-bubble.green { background: #95EC69; color: #191919; }

/* WeChat Moments Cover & Comment Box */
.wx-moments-cover {
  position: relative;
  height: 180px;
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-bottom: 24px;
  background: url('../assets/event-whistler.jpg') center/cover no-repeat;
}
.wx-moments-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05) 45%, rgba(0,0,0,0.55) 100%);
}
.wx-moments-me {
  position: absolute;
  right: 16px;
  bottom: 12px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 800;
  font-size: 16px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
}
.wx-moments-me img {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  object-fit: cover;
  border: 2px solid #fff;
}
.wx-comment-box {
  background: #F7F7F7;
  border-radius: 6px;
  padding: 8px 10px;
  font-size: var(--text-xs);
  display: grid;
  gap: 4px;
}
.wx-comment-author {
  color: var(--wx-blue);
  font-weight: 700;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
