/* ============================================================================
   MILLIONAIRE MOUNTAIN — Shared Design System
   Extracted from the original mockups. Responsive: phone -> desktop.
   ============================================================================ */

:root {
  --purple: #7c3aed;
  --purple-light: #ede9fe;
  --blue: #1d4ed8;
  --blue-light: #dbeafe;
  --green: #16a34a;
  --green-light: #dcfce7;
  --red: #dc2626;
  --red-light: #fee2e2;
  --orange: #f97316;
  --amber: #f59e0b;
  --amber-light: #fef3c7;
  --yellow: #eab308;
  --pink: #ec4899;
  --teal: #14b8a6;
  --indigo: #6366f1;
  --ink: #1d1d1f;
  --gray: #6b7280;
  --gray-light: #9ca3af;
  --line: #e5e7eb;
  --line-soft: #f3f4f6;
  --bg: #fafafa;
  --card: #ffffff;
  --sidebar-w: 220px;
  --radius: 16px;
  --shadow: 0 1px 3px rgba(0, 0, 0, .06);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, .08);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--ink);
  min-width: 320px;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { max-width: 100%; display: block; }

/* ---------------------------------------------------------------- Layout -- */
.app-shell { display: flex; min-height: 100vh; }

/* ---------------------------------------------------------------- Sidebar - */
.sidebar {
  position: fixed; left: 0; top: 0;
  width: var(--sidebar-w); height: 100vh;
  background: var(--card); border-right: 1px solid var(--line);
  padding: 20px; z-index: 50; overflow-y: auto;
}
.sidebar .logo { font-size: 18px; font-weight: 800; color: var(--ink); margin-bottom: 24px; }
.sidebar .logo span { color: var(--purple); }

.user-switch {
  width: 100%; padding: 10px 12px; margin-bottom: 20px;
  border: 1px solid var(--line); border-radius: 10px;
  font-size: 14px; font-weight: 600; color: var(--ink);
  background: var(--line-soft);
}

.sidebar nav a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 8px;
  font-size: 14px; color: var(--ink); margin-bottom: 4px;
  transition: all .15s;
}
.sidebar nav a.active, .sidebar nav a:hover { background: var(--purple-light); color: var(--purple); font-weight: 600; }
.sidebar nav a .nav-icon {
  width: 28px; height: 28px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; background: var(--line-soft); flex-shrink: 0;
}
.sidebar nav a.active .nav-icon, .sidebar nav a:hover .nav-icon { background: var(--purple-light); }

/* --------------------------------------------------------------- Main area */
.main { margin-left: var(--sidebar-w); flex: 1; min-width: 0; padding-bottom: 80px; }

/* ------------------------------------------------------- Mobile top bar --- */
.topbar {
  display: none;
  position: sticky; top: 0; z-index: 40;
  background: var(--card); border-bottom: 1px solid var(--line);
  /* Top safe-area so the notch/status bar doesn't overlap the bar in standalone PWA mode. */
  padding: calc(12px + env(safe-area-inset-top)) 16px 12px; align-items: center; justify-content: space-between;
}
.topbar .logo { font-size: 16px; font-weight: 800; }
.topbar .logo span { color: var(--purple); }

/* ---------------------------------------------- Mobile bottom tab bar ----- */
.tabbar {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 50;
  background: var(--card); border-top: 1px solid var(--line);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  justify-content: space-around;
}
.tabbar a {
  flex: 1; text-align: center; font-size: 10px; color: var(--gray);
  padding: 4px 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  min-height: 44px; /* comfortable tap target */
}
.tabbar a .ti { font-size: 20px; }
.tabbar a.active { color: var(--purple); font-weight: 700; }

/* --------------------------------------------------------------- Hero ----- */
.mountain-hero { background: linear-gradient(180deg, var(--purple-light) 0%, #fff 100%); padding: 30px 40px 0; position: relative; }
.hero-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; gap: 16px; flex-wrap: wrap; }
/* Brand logo chip on the Summit page — distinct from the personal greeting:
   same text size (26px) but set apart as a bordered pill with the mountain mark. */
.summit-brand {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 26px; font-weight: 800; color: var(--ink); letter-spacing: -0.3px;
  background: #fff; border: 2px solid var(--purple);
  border-radius: 999px; padding: 6px 18px; margin-bottom: 16px;
  box-shadow: 0 3px 10px rgba(124,58,237,.15);
}
.summit-brand span { color: var(--purple); }
.greeting h1 { font-size: 26px; font-weight: 800; }
.greeting p { font-size: 14px; color: var(--gray); }
.net-worth { text-align: left; margin-top: 14px; }
.net-worth .value { font-size: 32px; font-weight: 800; color: var(--purple); }
.net-worth .label { font-size: 14px; }

.chip-row { margin-top: 10px; display: inline-flex; gap: 8px; flex-wrap: wrap; }
.chip {
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  padding: 8px 14px; display: flex; align-items: center; gap: 8px; box-shadow: var(--shadow);
}
.chip .ic { width: 28px; height: 28px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.chip .k { font-size: 13px; color: var(--ink); font-weight: 500; }
.chip .v { font-size: 15px; font-weight: 700; }

/* The SVG inside carries viewBox 0 0 1000 250 (4:1) and sizes width:100%/
   height:auto, so the container's height follows the SVG's intrinsic ratio at
   EVERY width — markers stay locked to the trail on phone and desktop alike.
   aspect-ratio reserves the box so layout doesn't jump before the SVG paints. */
.mountain-container { position: relative; width: 100%; aspect-ratio: 1000 / 250; margin: 10px 0 0; }
.camp { position: absolute; text-align: center; font-size: 13px; font-weight: 600; color: #4b5563; transform: translateX(-50%); }
.camp-badge { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 3px; font-size: 14px; border: 2px solid; }
.camp-done { background: var(--green-light); border-color: var(--green); }
.camp-active { background: var(--blue-light); border-color: var(--blue); animation: pulse 2s infinite; }
.camp-future { background: var(--line-soft); border-color: #d1d5db; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(29,78,216,.3); } 50% { box-shadow: 0 0 0 8px rgba(29,78,216,0); } }

/* ------------------------------------------------------------ Dashboard --- */
.dashboard { padding: 30px 40px; }
.page-pad { padding: 30px 40px; }
.page-title { font-size: 22px; font-weight: 800; margin-bottom: 6px; }
.page-sub { font-size: 14px; color: var(--gray); margin-bottom: 20px; }

.stats-bar { display: flex; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.stat-pill { flex: 1; min-width: 140px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px; text-align: center; }
.stat-pill .value { font-size: 22px; font-weight: 800; margin-bottom: 2px; }
.stat-pill .label { font-size: 13px; color: var(--gray); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 24px; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-bottom: 24px; }

.widget { background: #fff; border-radius: var(--radius); padding: 24px; border: 1px solid var(--line); }
.widget h3 { font-size: 16px; font-weight: 700; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.widget h3 .wi { width: 28px; height: 28px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; font-size: 14px; }

.list-item { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line-soft); font-size: 14px; }
.list-item:last-child { border-bottom: none; }
.row-total { border-top: 2px solid var(--line); padding-top: 12px; font-weight: 700; }

.badge { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 13px; font-weight: 600; }
.badge-green { background: var(--green-light); color: var(--green); }
.badge-red { background: var(--red-light); color: var(--red); }
.badge-purple { background: var(--purple-light); color: var(--purple); }

.metric-card { border-radius: 12px; padding: 20px; text-align: center; cursor: pointer; transition: transform .2s; }
.metric-card:hover { transform: scale(1.02); }
.metric-card .emoji { font-size: 24px; margin-bottom: 6px; }
.metric-card .num { font-size: 24px; font-weight: 800; }
.metric-card .cap { font-size: 13px; margin-top: 4px; }

.surplus-card { background: var(--green-light); border-radius: 12px; padding: 20px; text-align: center; margin-bottom: 24px; }
.surplus-card .amount { font-size: 32px; font-weight: 800; color: var(--green); }
.surplus-card .label { font-size: 14px; color: var(--green); margin-top: 4px; }

/* ---------------------------------------------------------- Stacked cards - */
.cards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.stack { border-radius: 14px; border: 1px solid var(--line); background: #fff; overflow: hidden; }
.stack-head { padding: 10px 16px; font-size: 13px; font-weight: 700; color: #fff; display: flex; justify-content: space-between; align-items: center; }
.stack-dots { display: flex; gap: 4px; }
.stack-dots span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.4); }
.stack-dots span.on { background: #fff; }
.stack-body { padding: 16px; min-height: 150px; }
.stack-foot { display: flex; justify-content: space-between; padding: 8px 16px; border-top: 1px solid var(--line-soft); font-size: 12px; color: var(--gray); align-items: center; }
.stack-foot button { background: none; border: none; color: var(--purple); font-weight: 600; font-size: 12px; }
.stack-foot button:disabled { color: #d1d5db; }

.card-title { font-size: 14px; font-weight: 700; margin-bottom: 10px; display: flex; justify-content: space-between; align-items: center; }
.card-line { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 5px 0; border-bottom: 1px solid var(--line-soft); font-size: 13px; }
.card-line .lbl { color: #4b5563; }
.btn-rm { color: #d1d5db; cursor: pointer; font-size: 15px; }
.btn-rm:hover { color: var(--red); }
.btn-add { display: block; width: 100%; padding: 7px; border: 1px dashed #d1d5db; border-radius: 8px; background: none; color: var(--gray); font-size: 12px; margin-top: 8px; }
.btn-add:hover { border-color: var(--purple); color: var(--purple); }

/* Inline editable fields */
.editable { cursor: text; border-radius: 4px; padding: 0 2px; }
.editable:hover { background: var(--amber-light); outline: 1px dashed var(--amber); }
.editable:focus { background: #fff; outline: 2px solid var(--purple); }

/* ------------------------------------------------- Budget Partner char --- */
/* Gentle idle bob for the whole character. */
.bp-char { display: block; animation: bp-bob 2.4s ease-in-out infinite; transform-origin: center bottom; }
@keyframes bp-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }

/* Waving front arm. */
.bp-wave { transform-box: fill-box; transform-origin: 50% 100%; animation: bp-wave 0.9s ease-in-out infinite; }
@keyframes bp-wave {
  0%   { transform: rotate(8deg); }
  25%  { transform: rotate(-22deg); }
  50%  { transform: rotate(8deg); }
  75%  { transform: rotate(-22deg); }
  100% { transform: rotate(8deg); }
}

/* Mouth opens/closes a touch, like it's talking. */
.bp-mouth { transform-box: fill-box; transform-origin: center; animation: bp-talk 0.4s ease-in-out infinite; }
@keyframes bp-talk { 0%,100% { transform: scaleY(0.4); } 50% { transform: scaleY(1); } }

/* Chest breathing. */
.bp-breathe { transform-box: fill-box; transform-origin: center bottom; animation: bp-breathe 3.4s ease-in-out infinite; }
@keyframes bp-breathe { 0%,100% { transform: scale(1,1); } 50% { transform: scale(1.02,.985); } }

/* Eyes blink occasionally. */
.bp-blink { transform-box: fill-box; transform-origin: center; animation: bp-blink 4.2s ease-in-out infinite; }
@keyframes bp-blink { 0%,92%,100% { transform: scaleY(1); } 96% { transform: scaleY(0.1); } }

/* Promo block: character + speech bubble, used on login and app pages. */
.bp-promo { display: flex; align-items: center; gap: 14px; }
.bp-stage { flex-shrink: 0; }
.bp-bubble {
  position: relative; background: #fff; color: var(--ink);
  border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px;
  box-shadow: var(--shadow); flex: 1; min-width: 0;
}
.bp-bubble::before {
  content: ""; position: absolute; left: -9px; top: 28px;
  border-width: 9px 9px 9px 0; border-style: solid;
  border-color: transparent #fff transparent transparent;
}
.bp-bubble-title { font-size: 14px; font-weight: 800; color: var(--purple); margin-bottom: 4px; }
.bp-bubble-text { font-size: 13px; color: var(--gray); line-height: 1.5; }
.bp-bubble-text b { color: var(--ink); font-weight: 700; }

/* On the dark login panel the bubble flips to a translucent light style. */
.login-left .bp-promo .bp-bubble { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.25); color: #fff; box-shadow: none; }
.login-left .bp-promo .bp-bubble::before { border-color: transparent rgba(255,255,255,.14) transparent transparent; }
.login-left .bp-promo .bp-bubble-title { color: #fff; }
.login-left .bp-promo .bp-bubble-text { color: rgba(255,255,255,.9); }
.login-left .bp-promo .bp-bubble-text b { color: #fff; }

/* Gold bucket coins bob. */
@keyframes drop { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ----------------------------------------------- Floating Noah chat ------- */
.noah-fab {
  position: fixed; right: 20px; bottom: 20px; z-index: 90;
  width: 60px; height: 60px; border-radius: 50%; border: none;
  background: var(--purple); color: #fff; font-size: 26px; cursor: pointer;
  box-shadow: var(--shadow-lg); display: flex; align-items: center; justify-content: center;
  transition: transform .15s;
}
.noah-fab:hover { transform: scale(1.08); }

.noah-chat {
  position: fixed; right: 20px; bottom: 92px; z-index: 95;
  width: 340px; max-width: calc(100vw - 32px); height: 460px; max-height: calc(100vh - 120px);
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  box-shadow: var(--shadow-lg); display: none; flex-direction: column; overflow: hidden;
}
.noah-chat.open { display: flex; }
.noah-chat-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: var(--purple); color: #fff;
}
.noah-chat-title { font-size: 14px; font-weight: 800; }
.noah-chat-close { background: none; border: none; color: #fff; font-size: 22px; line-height: 1; cursor: pointer; }
.noah-chat-char { display: flex; justify-content: center; padding: 8px 0 0; }
.noah-chat-char .bp-char { width: 90px; }
.noah-chat-log { flex: 1; overflow-y: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.noah-msg { max-width: 80%; padding: 9px 12px; border-radius: 14px; font-size: 13px; line-height: 1.4; }
.noah-msg.user { align-self: flex-end; background: var(--purple); color: #fff; border-bottom-right-radius: 4px; }
.noah-msg.noah { align-self: flex-start; background: var(--line-soft); color: var(--ink); border-bottom-left-radius: 4px; }
.noah-chat-input { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); }
.noah-chat-input input { flex: 1; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font-family: inherit; font-size: 14px; outline: none; }
.noah-chat-input input:focus { border-color: var(--purple); }
.noah-chat-input button { padding: 10px 16px; background: var(--purple); color: #fff; border: none; border-radius: 10px; font-weight: 700; font-size: 14px; cursor: pointer; }
@media (max-width: 768px) {
  .noah-fab { bottom: 84px; }               /* sit above the mobile tab bar */
  .noah-chat { bottom: 150px; }
}

/* --------------------------------------------- Mobile "More" sheet -------- */
.more-sheet {
  position: fixed; inset: 0; z-index: 120; display: none;
  background: rgba(0,0,0,.35);
}
.more-sheet.open { display: block; }
.more-sheet-panel {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: #fff; border-radius: 18px 18px 0 0; padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
  box-shadow: 0 -8px 30px rgba(0,0,0,.18); max-height: 80vh; overflow-y: auto;
}
.more-sheet-head { display: flex; justify-content: space-between; align-items: center; font-weight: 800; font-size: 16px; margin-bottom: 12px; }
.more-close { font-size: 24px; color: var(--gray); cursor: pointer; line-height: 1; }
.more-sheet-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.more-sheet-grid + .more-section { margin-top: 14px; }
/* Section header inside the mobile More sheet (matches the sidebar sections). */
.more-section {
  font-size: 10px; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase;
  color: #9ca3af; margin: 14px 2px 6px;
}
.more-section:first-of-type { margin-top: 2px; }
.more-item {
  display: flex; align-items: center; gap: 10px; padding: 14px 12px;
  border: 1px solid var(--line); border-radius: 12px; font-size: 14px; font-weight: 600; color: var(--ink);
}
.more-item.active { background: var(--purple-light); color: var(--purple); border-color: var(--purple); }
.more-item .more-ic { font-size: 18px; }

/* ---------------------------------------------------------------- Footer -- */
.footer { text-align: center; padding: 20px; font-size: 13px; color: #aeaeb2; }

/* --------------------------------------------------------- Install prompt - */
.install-banner {
  position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%);
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 999px;
  display: none; align-items: center; gap: 12px; z-index: 100; box-shadow: var(--shadow-lg);
  font-size: 14px;
}
.install-banner button { background: var(--purple); color: #fff; border: none; padding: 7px 14px; border-radius: 999px; font-weight: 700; font-size: 13px; }
.install-banner .close { background: none; color: #9ca3af; font-size: 18px; padding: 0 4px; }

/* ------------------------------------------------------------- Buttons ---- */
.btn { padding: 10px 18px; border-radius: 10px; border: none; font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; min-height: 44px; }
.btn-primary { background: var(--purple); color: #fff; }
.btn-ghost { background: var(--line-soft); color: var(--ink); }

/* =========================================================== RESPONSIVE === */
@media (max-width: 900px) {
  .grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .sidebar { display: none; }
  /* Clear the fixed bottom tab bar (~56px) plus the device safe-area inset so
     content isn't hidden behind it in standalone PWA mode. */
  .main { margin-left: 0; padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
  .topbar { display: flex; }
  .tabbar { display: flex; }
  .mountain-hero { padding: 20px 16px 0; }
  .hero-top { flex-direction: column; align-items: stretch; }
  .net-worth { text-align: left; }
  .dashboard, .page-pad { padding: 20px 16px; }
  .greeting h1 { font-size: 22px; }
  .net-worth .value { font-size: 28px; }
  /* No fixed height override: .mountain-container uses aspect-ratio so the SVG
     (and its camp/climber/bullseye markers) scales correctly at phone width. */

  /* --- Responsive polish (B) for the newer pages/widgets --- */
  /* Budget Chat promo: stack character above the bubble on phones. */
  .bp-promo { flex-direction: column; text-align: center; }
  .bp-bubble::before { display: none; }            /* hide the sideways arrow when stacked */
  /* Keep the floating Noah button clear of the bottom tab bar. */
  .noah-fab { right: 14px; bottom: 80px; width: 54px; height: 54px; font-size: 22px; }
  .noah-chat { right: 10px; left: 10px; width: auto; bottom: 148px; }
  /* Grids collapse to a single column on phones. */
  .grid-auto, .cards-grid { grid-template-columns: 1fr; }
  .stats-bar { gap: 10px; }
  .stat-pill { min-width: 0; flex: 1 1 45%; }       /* 2-up stat pills instead of cramped */
  /* Net-worth panel impact cards stack nicely. */
  .widget { padding: 16px; }
  /* Calculator inputs: let labels/inputs wrap instead of overflowing. */
  .page-pad input[type="number"], .page-pad input[type="text"] { max-width: 100%; }
  /* Milestone goal / starter cards full width. */
  .milestones-preview { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 1400px) {
  .main { max-width: 1400px; }
}

/* =============================================================== LOGIN ==== */
#loginRoot {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.login-container {
  display: flex; width: 100%; max-width: 1000px; min-height: 600px;
  border-radius: 20px; overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,.08); background: #fff;
}
.login-left {
  flex: 1; background: linear-gradient(135deg,#7c3aed 0%,#4f46e5 50%,#1d4ed8 100%);
  padding: 50px; display: flex; flex-direction: column; justify-content: center;
  color: #fff; position: relative; overflow: hidden;
}
.login-left::before {
  content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,.05) 0%, transparent 60%);
  animation: drift 20s linear infinite;
}
@keyframes drift { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
.login-left h1 { font-size: 32px; font-weight: 800; margin-bottom: 12px; position: relative; }
.login-left p { font-size: 16px; opacity: .85; line-height: 1.6; margin-bottom: 30px; position: relative; }

/* Brand with "Millionaire" / "Mountain" stacked + aligned (the two M's line up).
   The mountain icon sits beside "Millionaire" (top line), not centered. */
.brand-stack { display: flex; align-items: flex-start; gap: 10px; position: relative; margin-bottom: 14px; }
.brand-stack .brand-mtn { font-size: 30px; line-height: 1.05; }
.brand-stack .brand-words { display: flex; flex-direction: column; line-height: 1.05; font-weight: 800; font-size: 30px; }
.intro-tag { font-size: 18px; opacity: .95; line-height: 1.5; margin-bottom: 22px; position: relative; }

/* Feature tiles: equal-width grid so none get cut off */
.feature-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; position: relative; }
.feature-tile {
  display: flex; align-items: center; gap: 10px;
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.25);
  border-radius: 12px; padding: 12px 14px; font-size: 14px; font-weight: 600;
}
.feature-tile .feature-ic { font-size: 20px; flex-shrink: 0; }

/* Noah promo on the login left panel: give the bubble text a readable size
   (the .bp-promo/.bp-bubble base styles already handle layout + the waving char). */
.login-left .bp-promo { margin-top: 18px; }
.login-left .bp-promo .bp-bubble-text { font-size: 15px; line-height: 1.5; }
/* Noah promo on the right (sign-in) panel, under the invite toggle link */
.login-right .bp-promo { margin-top: 20px; }

/* Live "Earnings Beat" preview under Noah (animated sweep line + ratings) */
.eb-preview {
  margin-top: 16px; background: #fff; border-radius: 14px; padding: 16px 18px;
  box-shadow: 0 6px 20px rgba(0,0,0,.18); color: #1d1d1f;
}
.eb-head { text-align: center; font-size: 26px; font-weight: 800; letter-spacing: -1px; }
.eb-sub { text-align: center; font-size: 12px; color: #6b7280; margin: 4px 0 14px; }
.eb-grad {
  background: linear-gradient(135deg,#4c1d95,#7c3aed,#4c1d95);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; font-weight: 800;
}
.eb-shimmer {
  background: linear-gradient(90deg,#1d1d1f 0%,#1d1d1f 10%,#7c3aed 30%,#ffffff 50%,#7c3aed 70%,#1d1d1f 90%,#1d1d1f 100%);
  background-size: 300% auto; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  animation: eb-shimmer 2.5s ease-in-out infinite; font-weight: 800;
}
@keyframes eb-shimmer { 0%{background-position:0% 50%} 50%{background-position:100% 50%} 100%{background-position:0% 50%} }
.eb-pulse { animation: eb-pulse 2.5s ease-in-out infinite; }
@keyframes eb-pulse { 0%,100%{filter:drop-shadow(0 0 2px rgba(124,58,237,.3))} 50%{filter:drop-shadow(0 0 8px rgba(124,58,237,.6))} }
.eb-sweep { stroke-dasharray: 60; stroke-dashoffset: 60; animation: eb-sweep 2s ease-in-out infinite alternate; }
@keyframes eb-sweep { 0%{stroke-dashoffset:60} 100%{stroke-dashoffset:0} }
.eb-ratings { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.eb-card { border: 1px solid #e5e7eb; border-radius: 12px; padding: 12px; text-align: center; }
.eb-card-title { font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.eb-legend { margin-top: 10px; text-align: left; font-size: 11.5px; color: #4b5563; line-height: 1.8; }
.eb-legend span { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; }
.eb-legend b { color: #1d1d1f; font-weight: 700; }

/* Mountain-climb hero image (under a brand logo on either panel).
   Negative top margin pulls it UP into the space under the logo to fill the gap. */
.hero-climb-img {
  display: block; width: 100%; height: auto; border-radius: 14px;
  margin: -8px 0 14px; box-shadow: 0 6px 20px rgba(0,0,0,.18);
}
/* On the right (sign-in) panel: no logo above it now, so sit at the top; add an
   extra line of space below before the BETA TESTING badge. */
.login-right .hero-climb-img { margin-top: 0; margin-bottom: 30px; }

/* Beta badge on the sign-in panel */
.beta-badge {
  display: inline-block; background: #fef3c7; color: #92400e;
  border: 1px solid #f59e0b; border-radius: 999px; padding: 5px 12px;
  font-size: 12px; font-weight: 700; margin-bottom: 12px;
}
.mountain-graphic { opacity: .15; position: absolute; bottom: 0; left: 0; right: 0; }
.milestones-preview { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; position: relative; }
.milestone-chip { background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.25); border-radius: 20px; padding: 8px 10px; font-size: 13px; font-weight: 500; text-align: center; white-space: nowrap; }
.login-right { flex: 1; padding: 50px; display: flex; flex-direction: column; justify-content: center; }
.login-right .logo { font-size: 22px; font-weight: 800; color: #1d1d1f; margin-bottom: 8px; }
.login-right .logo span { color: #7c3aed; }
.login-right .subtitle { font-size: 14px; color: #6b7280; margin-bottom: 30px; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: #4b5563; margin-bottom: 6px; }
.form-group input { width: 100%; padding: 12px 16px; border: 1.5px solid #e5e7eb; border-radius: 10px; font-size: 14px; transition: border .2s; outline: none; font-family: inherit; }
.form-group input:focus { border-color: #7c3aed; }
.login-right .btn-primary { width: 100%; padding: 14px; background: #7c3aed; color: #fff; border: none; border-radius: 10px; font-size: 15px; font-weight: 700; cursor: pointer; transition: background .2s; }
.login-right .btn-primary:hover { background: #6d28d9; }
.divider { display: flex; align-items: center; gap: 12px; margin: 20px 0; font-size: 13px; color: #9ca3af; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: #e5e7eb; }
.btn-social { width: 100%; padding: 12px; border: 1.5px solid #e5e7eb; border-radius: 10px; background: #fff; font-size: 14px; font-weight: 500; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 10px; transition: border .2s; }
.btn-social:hover { border-color: #7c3aed; }
.bottom-link { text-align: center; margin-top: 20px; font-size: 14px; color: #6b7280; }
.bottom-link a { color: #7c3aed; text-decoration: none; font-weight: 600; }
@media (max-width: 768px) {
  .login-container { flex-direction: column; max-width: 400px; }
  .login-left { padding: 30px; min-height: 200px; }
  .login-right { padding: 30px; }
}

/* ============================================================================
   PART R — new components (debt payoff cards, stock-game performance cards,
   stock-pick cards, past-champions scroller, milestones calendar).
   Ported from the approved previews/*.html <style> blocks.
   ============================================================================ */

/* Segmented toggle (snowball/avalanche, month/year) */
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { padding: 8px 16px; border: none; background: #fff; font-size: 13px; font-weight: 600; color: var(--gray); }
.seg button.on { background: var(--purple); color: #fff; }

/* Debt Profile — payoff cards (R.6) */
.debt-card { border-radius: 14px; border: 1px solid var(--line); background: #fff; overflow: hidden; box-shadow: var(--shadow); }
.debt-head { padding: 12px 16px; color: #fff; display: flex; justify-content: space-between; align-items: center; font-weight: 700; font-size: 15px; }
.debt-body { padding: 16px; }
.debt-body .bar-track { height: 10px; background: var(--line-soft); border-radius: 999px; overflow: hidden; margin: 8px 0; }
.debt-body .bar-fill { height: 100%; border-radius: 999px; }
.debt-row { display: flex; justify-content: space-between; font-size: 13px; padding: 4px 0; color: #4b5563; }
.debt-actions { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line-soft); }
.mini-btn { flex: 1; padding: 7px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-size: 12px; font-weight: 600; color: var(--purple); }

/* Stock Picks — research cards (R.7) */
.pick-card { border-radius: 14px; border: 1px solid var(--line); background: #fff; overflow: hidden; box-shadow: var(--shadow); }
.pick-head { padding: 12px 16px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line-soft); }
.pick-tier { font-size: 10px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase; padding: 2px 8px; border-radius: 4px; }
.tier-safe { background: var(--blue-light); color: var(--blue); }
.tier-growth { background: var(--green-light); color: var(--green); }
.pick-body { padding: 14px 16px; }
.pstat { display: flex; justify-content: space-between; font-size: 12px; padding: 3px 0; color: #4b5563; }
.noah-pick { background: linear-gradient(135deg,#faf5ff,#f0fdfa); border: 2px solid #7c3aed; border-radius: 12px; padding: 10px 14px; text-align: center; min-width: 150px; }
.disc { background: var(--amber-light); border: 1px solid var(--amber); border-radius: 10px; padding: 10px 14px; font-size: 12px; color: #92400e; }

/* Stock Game — performance cards + past champions scroller (R.5) */
.perf-card { border-radius: 16px; border: 1px solid var(--line); background: #fff; overflow: hidden; box-shadow: var(--shadow); }
.perf-card.me { outline: 2px solid var(--purple); outline-offset: -1px; }
.perf-head { padding: 14px 16px; color: #fff; display: flex; align-items: center; gap: 10px; }
.perf-head .av { width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,.25); display: flex; align-items: center; justify-content: center; font-size: 18px; position: relative; }
.perf-head .av .mark { position: absolute; bottom: -4px; right: -4px; font-size: 15px; background: #fff; border-radius: 50%; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.perf-head .nm { font-weight: 800; font-size: 15px; }
.perf-head .rk { margin-left: auto; font-weight: 800; font-size: 14px; background: rgba(255,255,255,.25); border-radius: 999px; padding: 3px 12px; }
.perf-body { padding: 16px; }
.perf-gain { font-size: 30px; font-weight: 800; }
.perf-bar { height: 8px; background: var(--line-soft); border-radius: 999px; overflow: hidden; margin: 8px 0 12px; }
.perf-actions { display: flex; gap: 6px; padding: 12px 16px; border-top: 1px solid var(--line-soft); flex-wrap: wrap; }
.pa { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line); background: #fff; font-size: 12px; font-weight: 600; color: #4b5563; }
.pa.follow { color: var(--purple); border-color: var(--purple); }

.win-scroll { display: flex; gap: 12px; overflow-x: auto; padding: 4px 2px 12px; scroll-snap-type: x mandatory; margin-bottom: 8px; }
.win-chip { scroll-snap-align: start; flex: 0 0 auto; width: 150px; border-radius: 14px; border: 1px solid var(--line); background: #fff; padding: 14px; text-align: center; box-shadow: var(--shadow); }
.win-chip .mo { font-size: 11px; font-weight: 700; color: var(--gray); text-transform: uppercase; letter-spacing: .5px; }
.win-chip .av { font-size: 30px; margin: 6px 0 2px; position: relative; display: inline-block; }
.win-chip .nm { font-weight: 800; font-size: 13px; }
.win-chip .gn { font-size: 18px; font-weight: 800; color: var(--green); margin-top: 4px; }
.win-chip.live { border: 2px dashed var(--purple); background: var(--purple-light); }

/* Milestones — month/year calendar (R.10) */
.cal { display: grid; grid-template-columns: repeat(7,1fr); gap: 6px; }
.cal .dow { font-size: 11px; font-weight: 700; color: var(--gray); text-align: center; padding: 4px 0; }
.cal .day { aspect-ratio: 1; border: 1px solid var(--line); border-radius: 8px; padding: 4px; font-size: 12px; position: relative; cursor: pointer; }
.cal .day .n { font-weight: 600; color: #4b5563; }
.cal .day.blackout { background: var(--red-light); border-color: var(--red); }
.cal .day.party { background: var(--green-light); border-color: var(--green); }
.cal .day.goal { background: var(--purple-light); border-color: var(--purple); }
.cal .day .dot { position: absolute; bottom: 4px; left: 4px; font-size: 11px; }
.yearrow { display: grid; grid-template-columns: 90px repeat(4,1fr); gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line-soft); font-size: 13px; }
.yearrow .m { font-weight: 700; }

/* ============================================================================
   PART R — SECOND WAVE components (nav sections + stacked logo, winner banner,
   full-page Noah chat, Goal Party room, animated Noah shorts stage, Help FAQ,
   Community act rows / toggles / show-more). Ported from the approved previews.
   ============================================================================ */

/* --- Nav section headers + Help utility links + stacked logo (preview-nav) - */
.sidebar nav .nav-section {
  font-size: 10px; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase;
  color: #9ca3af; padding: 0 12px; margin: 16px 0 6px;
}
.sidebar nav .nav-section:first-child { margin-top: 4px; }
.sidebar nav a.nav-logout { color: var(--red); }
.sidebar nav a.nav-logout:hover { background: var(--red-light); color: var(--red); }
.sidebar nav a.nav-logout .nav-icon { background: var(--red-light); }
/* Stacked two-line logo: "Mountain" (purple) on line 2, M aligned under the M
   in "Millionaire" (indented past the mountain mark + space). */
.sidebar .logo-stack { display: flex; flex-direction: column; line-height: 1.15; margin-bottom: 20px; }
.sidebar .logo-stack .logo-line { display: block; }
.sidebar .logo-stack .logo-mark { display: inline-block; width: 1.6em; }
.sidebar .logo-stack .logo-word2 { padding-left: 1.6em; color: var(--purple); }
.sidebar .logo-stack .logo-word2 span { color: var(--purple); }

/* --- Stock Game: last month's winner banner (PALE LAVENDER, R.5) ---------- */
.winner-hero { position: relative; overflow: hidden; border-radius: 18px; padding: 22px 24px; margin-bottom: 22px;
  background: linear-gradient(135deg,#f5f3ff 0%,#ede9fe 55%,#faf5ff 100%); border: 1px solid #c4b5fd; }
.winner-hero::before { content: '🎉'; position: absolute; font-size: 120px; opacity: .10; right: 10px; top: -20px; }
.winner-hero::after { content: '🏆'; position: absolute; font-size: 90px; opacity: .08; left: -10px; bottom: -30px; }
.winner-tag { font-size: 11px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; color: #6d28d9; }
.winner-row { display: flex; align-items: center; gap: 16px; margin-top: 8px; flex-wrap: wrap; position: relative; z-index: 1; }
.winner-av { width: 72px; height: 72px; border-radius: 50%; background: #fff; border: 3px solid #a78bfa; display: flex; align-items: center; justify-content: center; font-size: 38px; position: relative; box-shadow: 0 4px 14px rgba(124,58,237,.25); }
.winner-av .crown { position: absolute; top: -18px; left: 50%; transform: translateX(-50%); font-size: 26px; }
.winner-name { font-size: 24px; font-weight: 800; color: #1d1d1f; }
.winner-gain { font-size: 15px; font-weight: 700; color: var(--green); }
.winner-bio { position: relative; z-index: 1; margin-top: 14px; display: flex; gap: 14px; flex-wrap: wrap; }
.winner-box { background: rgba(255,255,255,.75); border: 1px solid #ddd6fe; border-radius: 12px; padding: 12px 16px; flex: 1; min-width: 220px; }
.winner-box .bl { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: #6d28d9; margin-bottom: 4px; }
.winner-quote { font-size: 15px; font-style: italic; color: #1d1d1f; }

/* --- Chat with Noah: full page ------------------------------------------- */
.noah-page { display: flex; flex-direction: column; min-height: calc(100vh - 120px); max-width: 860px; margin: 0 auto; }
.noah-hero { display: flex; align-items: center; gap: 14px; padding: 4px 0 14px; }
.noah-face { width: 60px; height: 60px; border-radius: 50%; background: linear-gradient(135deg,#ede9fe,#dbeafe); display: flex; align-items: center; justify-content: center; font-size: 32px; border: 2px solid var(--purple); flex-shrink: 0; }
.nplog { flex: 1; min-height: 260px; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: 16px; margin-bottom: 12px; }
.nmsg { max-width: 72%; padding: 12px 16px; border-radius: 16px; font-size: 14px; line-height: 1.5; }
.nmsg.user { align-self: flex-end; background: var(--purple); color: #fff; border-bottom-right-radius: 5px; }
.nmsg.noah { align-self: flex-start; background: var(--line-soft); color: var(--ink); border-bottom-left-radius: 5px; }
.nmsg .who { font-size: 11px; font-weight: 700; opacity: .75; display: block; margin-bottom: 3px; }
.np-input { display: flex; gap: 10px; align-items: flex-end; }
.np-input textarea { flex: 1; min-height: 64px; max-height: 200px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; font-family: inherit; font-size: 14px; resize: vertical; outline: none; }
.np-input textarea:focus { border-color: var(--purple); }
.np-send { padding: 14px 22px; background: var(--purple); color: #fff; border: none; border-radius: 12px; font-weight: 700; font-size: 14px; cursor: pointer; height: 64px; }
.np-suggest { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.np-chip { font-size: 12px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--purple); cursor: pointer; font-weight: 600; }
.np-chip:hover { background: var(--purple-light); }

/* --- Goal Party room ----------------------------------------------------- */
.room { position: relative; min-height: calc(100vh - 60px); overflow: hidden;
  background: linear-gradient(135deg,#faf5ff 0%,#ede9fe 25%,#dbeafe 50%,#dcfce7 75%,#fef3c7 100%);
  background-size: 400% 400%; animation: bgshift 18s ease infinite; }
@keyframes bgshift { 0%{background-position:0% 50%} 50%{background-position:100% 50%} 100%{background-position:0% 50%} }
.decor { position: absolute; font-size: 34px; opacity: .5; animation: float 7s ease-in-out infinite; pointer-events: none; z-index: 0; }
@keyframes float { 0%,100%{transform:translateY(0) rotate(-4deg)} 50%{transform:translateY(-22px) rotate(4deg)} }
.confetti { position: absolute; top: -20px; width: 9px; height: 14px; opacity: .9; z-index: 1; animation: fall linear infinite; border-radius: 2px; }
@keyframes fall { 0%{transform:translateY(-20px) rotate(0)} 100%{transform:translateY(105vh) rotate(540deg)} }
.room-inner { position: relative; z-index: 2; max-width: 1000px; margin: 0 auto; padding: 20px 20px 60px; }
.room .top-bar { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.room .leave { font-size: 13px; font-weight: 700; color: var(--purple); text-decoration: none; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px; }
.room .party-title { font-size: 26px; font-weight: 800; color: #1d1d1f; }
.goal-banner { background: rgba(255,255,255,.85); border: 2px solid var(--purple); border-radius: 18px; padding: 18px 22px; margin-bottom: 16px; text-align: center; box-shadow: 0 8px 30px rgba(124,58,237,.18); }
.goal-banner .big { font-size: 30px; font-weight: 800; color: var(--purple); }
.goal-banner .meta { font-size: 13px; color: var(--gray); margin-top: 4px; }
.goal-stats { display: flex; justify-content: center; gap: 22px; margin-top: 12px; flex-wrap: wrap; }
.goal-stat .v { font-size: 20px; font-weight: 800; }
.goal-stat .l { font-size: 11px; color: var(--gray); }
.room-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; }
.room .panel { background: rgba(255,255,255,.9); border: 1px solid var(--line); border-radius: 16px; padding: 16px; }
.room .panel h3 { font-size: 15px; font-weight: 800; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.host-card { background: linear-gradient(135deg,#fff7ed,#fef3c7); border: 2px solid var(--amber); border-radius: 16px; padding: 16px; margin-bottom: 16px; }
.host-row { display: flex; align-items: center; gap: 12px; }
.host-av { width: 54px; height: 54px; border-radius: 50%; background: #fff; border: 3px solid var(--amber); display: flex; align-items: center; justify-content: center; font-size: 28px; }
.host-quote { font-size: 15px; font-style: italic; color: #1d1d1f; margin-top: 10px; line-height: 1.5; }
.music { background: rgba(255,255,255,.9); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; margin-bottom: 16px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.music select { padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; font-family: inherit; font-size: 13px; }
.music .play { width: 42px; height: 42px; border-radius: 50%; border: none; background: var(--purple); color: #fff; font-size: 16px; cursor: pointer; }
.eq { display: inline-flex; gap: 3px; align-items: flex-end; height: 22px; }
.eq span { width: 4px; background: var(--purple); border-radius: 2px; animation: eq .9s ease-in-out infinite; }
.eq span:nth-child(2){ animation-delay: .15s } .eq span:nth-child(3){ animation-delay: .3s } .eq span:nth-child(4){ animation-delay: .45s }
.eq.paused span { animation-play-state: paused; height: 5px !important; }
@keyframes eq { 0%,100%{height:5px} 50%{height:20px} }
.chat-log { height: 260px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 4px; margin-bottom: 10px; }
.chat-msg { max-width: 85%; padding: 8px 12px; border-radius: 14px; font-size: 13px; line-height: 1.4; }
.chat-msg.me { align-self: flex-end; background: var(--purple); color: #fff; border-bottom-right-radius: 4px; }
.chat-msg.them { align-self: flex-start; background: var(--line-soft); color: var(--ink); border-bottom-left-radius: 4px; }
.chat-msg .who { font-size: 11px; font-weight: 700; opacity: .8; display: block; margin-bottom: 2px; }
.chat-input { display: flex; gap: 8px; }
.chat-input input { flex: 1; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font-family: inherit; font-size: 14px; }
.chat-input button { padding: 10px 16px; background: var(--purple); color: #fff; border: none; border-radius: 10px; font-weight: 700; cursor: pointer; }
.att { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line-soft); }
.att:last-child { border-bottom: none; }
.att .av { font-size: 22px; }
.att .nm { flex: 1; font-weight: 600; font-size: 14px; }
.met-btn { font-size: 12px; font-weight: 700; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--green); background: #fff; color: var(--green); cursor: pointer; }
.met-btn.on { background: var(--green); color: #fff; }

/* --- Stock Education: animated Noah shorts stage (Approach A) ------------- */
.noah-stage { position: relative; height: 260px; border-radius: 14px; overflow: hidden;
  background: linear-gradient(180deg,#ede9fe 0%,#dbeafe 60%,#dcfce7 100%); border: 1px solid var(--line); }
.stage-sky { position: absolute; inset: 0; }
.noah-char { position: absolute; left: 18px; bottom: 4px; z-index: 3; }
.noah-char.bob { animation: bob 1.8s ease-in-out infinite; transform-origin: center bottom; }
@keyframes bob { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-7px)} }
#noahArm.wave { animation: wave 0.7s ease-in-out infinite; }
@keyframes wave { 0%,100%{transform:rotate(-8deg)} 50%{transform:rotate(22deg)} }
.stage-objects { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.vis-pop { position: absolute; right: 22px; top: 50%; transform: translateY(-50%) scale(.8); opacity: 0; text-align: center; max-width: 48%; }
.vis-pop.go { animation: vispop .4s ease-out forwards; }
@keyframes vispop { to { opacity: 1; transform: translateY(-50%) scale(1); } }
.vis-pop .vlabel { margin-top: 8px; font-size: 12px; font-weight: 700; color: #1f2328; background: rgba(255,255,255,.85); border-radius: 8px; padding: 3px 8px; display: inline-block; }
.vis-pop .bigemoji { font-size: 40px; line-height: 1.3; }
.bars { display: flex; gap: 8px; align-items: flex-end; justify-content: center; height: 90px; }
.bars span { width: 16px; height: 0; background: linear-gradient(180deg,#86efac,#16a34a); border-radius: 4px 4px 0 0; animation: grow .5s ease-out forwards; }
.bars span:nth-child(1){ animation-delay: .05s } .bars span:nth-child(2){ animation-delay: .2s }
.bars span:nth-child(3){ animation-delay: .35s } .bars span:nth-child(4){ animation-delay: .5s }
@keyframes grow { to { height: var(--h); } }
.qrow { display: flex; gap: 6px; justify-content: center; }
.qrow span { width: 34px; height: 40px; border-radius: 6px; background: #fff; border: 2px solid var(--blue); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; color: var(--blue); opacity: 0; animation: qpop .35s ease-out forwards; }
.qrow span:nth-child(1){ animation-delay: .05s } .qrow span:nth-child(2){ animation-delay: .25s }
.qrow span:nth-child(3){ animation-delay: .45s } .qrow span:nth-child(4){ animation-delay: .65s }
@keyframes qpop { from{opacity:0;transform:translateY(10px)} to{opacity:1;transform:none} }
.vs { display: flex; gap: 20px; justify-content: center; align-items: flex-end; }
.vs-col { text-align: center; }
.vs-bar { width: 30px; border-radius: 5px 5px 0 0; margin: 0 auto; animation: grow2 .5s ease-out; }
@keyframes grow2 { from{height:0} }
.vs-cap { font-size: 11px; font-weight: 700; margin-top: 4px; }
.coinstack { font-size: 22px; line-height: 1.1; }
.pie { font-size: 46px; }
.ceo { animation: shake .5s ease-in-out 2; }
@keyframes shake { 0%,100%{transform:translateX(0)} 25%{transform:translateX(-4px)} 75%{transform:translateX(4px)} }
.crash { animation: crashfall .7s ease-in forwards; }
@keyframes crashfall { 0%{transform:translateY(-14px)} 60%{transform:translateY(4px)} 100%{transform:translateY(0) rotate(-4deg)} }
.stage-caption { background: #1f2328; color: #fff; font-size: 14px; font-weight: 600; padding: 12px 16px; line-height: 1.45; border-radius: 0 0 14px 14px; min-height: 46px; display: flex; align-items: center; gap: 8px; }
.stage-caption .sub-ic { font-size: 16px; opacity: .8; }
.stage-play { position: absolute; top: 12px; right: 12px; z-index: 5; border: none; border-radius: 999px; background: var(--purple); color: #fff; font-weight: 700; font-size: 13px; padding: 8px 16px; cursor: pointer; }
.stage-mute { position: absolute; top: 12px; right: 92px; z-index: 5; border: none; border-radius: 999px; background: rgba(255,255,255,.9); color: var(--ink); font-weight: 700; font-size: 13px; padding: 8px 12px; cursor: pointer; }
.short-tile { text-align: center; background: var(--line-soft); border: 2px solid transparent; border-radius: 12px; padding: 16px 12px; cursor: pointer; font-family: inherit; color: var(--ink); }
.short-tile:hover { border-color: var(--purple-light); }
.short-tile.on { border-color: var(--purple); background: var(--purple-light); }

/* --- Get Help: FAQ accordion --------------------------------------------- */
details.faq { border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px; background: #fff; overflow: hidden; }
details.faq summary { list-style: none; cursor: pointer; padding: 14px 16px; font-weight: 700; font-size: 14px; display: flex; align-items: center; gap: 10px; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary:hover { background: var(--line-soft); }
details.faq summary .q { flex: 1; }
details.faq summary .c { color: var(--gray); transition: transform .15s; }
details.faq[open] summary .c { transform: rotate(90deg); }
details.faq .a { padding: 12px 16px 16px; font-size: 13px; color: #4b5563; line-height: 1.6; border-top: 1px solid var(--line-soft); }

/* --- Community: action rows, notification toggle, show-more, timestamps --- */
.act-row { display: flex; gap: 8px; font-size: 13px; flex-wrap: wrap; align-items: center; margin-top: 8px; }
.act { font-size: 12px; padding: 5px 12px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: #4b5563; cursor: pointer; font-weight: 600; }
.act:hover { border-color: var(--purple); color: var(--purple); }
.act.on { background: var(--purple); color: #fff; border-color: var(--purple); }
.notif { margin-left: auto; display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--gray); }
.toggle { width: 38px; height: 22px; border-radius: 999px; background: var(--line); position: relative; cursor: pointer; transition: background .15s; flex-shrink: 0; }
.toggle::after { content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: left .15s; }
.toggle.on { background: var(--green); }
.toggle.on::after { left: 18px; }
.feed-item, .party-item { border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-bottom: 12px; }
.ts { font-size: 11px; color: var(--gray-light); font-weight: 500; margin-top: 3px; }
.show-more { display: block; width: 100%; text-align: center; padding: 9px; border: 1px dashed var(--line); border-radius: 8px; background: none; color: var(--purple); font-size: 13px; font-weight: 600; cursor: pointer; margin-top: 4px; }
.show-more:hover { border-color: var(--purple); background: var(--purple-light); }
.archive-note { font-size: 11px; color: var(--gray-light); margin-top: 8px; display: flex; align-items: center; gap: 6px; }

/* Phone: party room grid collapses to one column. */
@media (max-width: 820px) { .room-grid { grid-template-columns: 1fr; } }
