@charset "UTF-8";

:root {
  color-scheme: light;
  --ink: #111827;
  --ink-2: #1f2937;
  --muted: #64748b;
  --line: rgba(17, 24, 39, 0.14);
  --line-strong: rgba(17, 24, 39, 0.24);
  --teal: #14b8a6;
  --teal-soft: rgba(20, 184, 166, 0.12);
  --aqua: #21cbbd;
  --aqua-line: rgba(33, 203, 189, 0.36);
  --poly-bg: #eef7f5;
  --poly-card: rgba(250, 255, 253, 0.92);
  --amber: #f59e0b;
  --amber-soft: rgba(245, 158, 11, 0.14);
  --bg: #f8fafc;
  --panel: rgba(255, 255, 255, 0.82);
  --shadow: 0 18px 60px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, Manrope, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.05) 1px, transparent 1px) 0 0 / 48px 48px,
    linear-gradient(0deg, rgba(17, 24, 39, 0.04) 1px, transparent 1px) 0 0 / 48px 48px,
    radial-gradient(circle at 12% 16%, rgba(20, 184, 166, 0.16), transparent 32%),
    radial-gradient(circle at 88% 8%, rgba(245, 158, 11, 0.16), transparent 30%),
    var(--bg);
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

@media (max-width: 768px) {
  input,
  textarea,
  select {
    font-size: 16px !important;
  }
}

@media (hover: none), (pointer: coarse), (max-width: 768px) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
  textarea,
  select {
    font-size: 16px !important;
    transform: translateZ(0);
  }
}

.language-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.language-switch select {
  min-width: 88px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
}

.app-shell {
  position: relative;
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  min-height: 100vh;
  overflow: hidden;
}

.circuit-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.8;
}

.circuit-bg::before,
.circuit-bg::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(20, 184, 166, 0.22);
  border-left: 0;
  border-bottom: 0;
}

.circuit-bg::before {
  width: 38vw;
  height: 28vh;
  right: 6vw;
  top: 12vh;
}

.circuit-bg::after {
  width: 30vw;
  height: 36vh;
  left: 8vw;
  bottom: 10vh;
  border-color: rgba(245, 158, 11, 0.2);
}

.node {
  position: absolute;
  width: 8px;
  height: 8px;
  border: 2px solid var(--teal);
  background: var(--bg);
}

.node-a { right: 44vw; top: 12vh; }
.node-b { right: 6vw; top: 40vh; border-color: var(--amber); }
.node-c { left: 8vw; bottom: 46vh; border-color: var(--amber); }
.node-d { left: 38vw; bottom: 10vh; }

.side-rail {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 34px;
  padding: 22px 14px;
  border-right: 1px solid var(--line);
  background: rgba(248, 250, 252, 0.72);
  backdrop-filter: blur(16px);
}

.brand {
  display: grid;
  gap: 8px;
  color: inherit;
  text-decoration: none;
  text-align: center;
}

.brand img {
  width: 50px;
  height: 50px;
  border: 1px solid rgba(17, 24, 39, 0.08);
  border-radius: 14px;
}

.brand strong {
  display: block;
  font-size: 12px;
  line-height: 1;
}

.brand small {
  color: var(--muted);
  font-size: 11px;
}

.rail-nav {
  display: grid;
  gap: 12px;
}

.icon-btn,
.mobile-tabbar button {
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.58);
}

.icon-btn {
  width: 48px;
  height: 48px;
}

.icon-btn.active,
.mobile-tabbar button.active {
  border-color: rgba(20, 184, 166, 0.5);
  background: var(--teal-soft);
}

.icon-grid,
.icon-wave,
.icon-message,
.icon-wallet,
.icon-user {
  width: 20px;
  height: 20px;
  display: block;
  position: relative;
}

.icon-message {
  border: 2px solid var(--ink);
}

.icon-message::after {
  content: "";
  position: absolute;
  left: 3px;
  bottom: -6px;
  width: 8px;
  height: 8px;
  border-left: 2px solid var(--teal);
  border-bottom: 2px solid var(--teal);
}

.icon-grid {
  background:
    linear-gradient(var(--ink), var(--ink)) 0 0 / 8px 8px no-repeat,
    linear-gradient(var(--ink), var(--ink)) 12px 0 / 8px 8px no-repeat,
    linear-gradient(var(--ink), var(--ink)) 0 12px / 8px 8px no-repeat,
    linear-gradient(var(--teal), var(--teal)) 12px 12px / 8px 8px no-repeat;
}

.icon-wave::before {
  content: "";
  position: absolute;
  inset: 2px 0;
  border-top: 3px solid var(--ink);
  border-bottom: 3px solid var(--teal);
  transform: skewY(-18deg);
}

.icon-wallet {
  border: 2px solid var(--ink);
}

.icon-wallet::after {
  content: "";
  position: absolute;
  right: -2px;
  top: 6px;
  width: 9px;
  height: 7px;
  border: 2px solid var(--teal);
  background: var(--bg);
}

.icon-user {
  border: 2px solid var(--ink);
  border-radius: 50%;
}

.icon-user::after {
  content: "";
  position: absolute;
  left: -5px;
  right: -5px;
  bottom: -8px;
  height: 10px;
  border: 2px solid var(--teal);
  border-top: 0;
}

.rail-status {
  margin-top: auto;
  writing-mode: vertical-rl;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.signal-dot,
.pulse {
  width: 8px;
  height: 8px;
  background: var(--teal);
  box-shadow: 0 0 0 8px rgba(20, 184, 166, 0.12);
}

.workspace {
  position: relative;
  z-index: 1;
  padding: 28px;
}

.topbar,
.section-head,
.ticker-strip,
.layout-grid {
  width: min(100%, 1440px);
  margin-inline: auto;
}

.topbar,
.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(30px, 4vw, 64px);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 24px;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0;
  font-size: 17px;
  line-height: 1.28;
  letter-spacing: 0;
}

.top-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.line-btn,
.primary-btn,
.segmented button,
.pick-switch button {
  min-height: 42px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.65);
  color: var(--ink);
  font-weight: 800;
}

.line-btn,
.primary-btn {
  padding: 0 18px;
}

.primary-btn {
  border-color: var(--ink);
  background: var(--ink);
  color: white;
  box-shadow: 0 12px 30px rgba(17, 24, 39, 0.16);
}

.ticker-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 28px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.56);
  backdrop-filter: blur(14px);
}

.ticker-item {
  position: relative;
  display: grid;
  gap: 5px;
  padding: 18px;
  border-right: 1px solid var(--line);
}

.ticker-item:last-child {
  border-right: 0;
}

.ticker-item span,
.topic-main p,
.topic-meta span,
.seat small,
.balance-line span,
.estimate span,
.amount-field span,
.amount-field em {
  color: var(--muted);
  font-size: 12px;
}

.ticker-item strong {
  font-size: 22px;
}

.ticker-item em,
.tag,
.room-chip {
  width: fit-content;
  color: var(--muted);
  font-style: normal;
  font-size: 12px;
  font-weight: 800;
}

.ticker-item .up,
.up {
  color: var(--teal);
}

.ticker-item .down {
  color: #ef4444;
}

.layout-grid {
  display: grid;
  grid-template-columns: minmax(430px, 1.1fr) minmax(330px, 0.85fr) minmax(290px, 0.55fr);
  gap: 18px;
  margin-top: 18px;
  align-items: start;
}

.market-panel,
.voice-panel,
.trade-panel {
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.market-panel,
.voice-panel {
  padding: 18px;
}

.trade-panel {
  padding: 18px;
  position: sticky;
  top: 24px;
}

.segmented,
.pick-switch {
  display: grid;
  grid-auto-flow: column;
  border: 1px solid var(--line);
}

.segmented button,
.pick-switch button {
  min-height: 36px;
  padding: 0 13px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
}

.segmented button:last-child,
.pick-switch button:last-child {
  border-right: 0;
}

.segmented .active,
.pick-switch .active {
  color: var(--ink);
  background: var(--teal-soft);
}

.topic-row {
  position: relative;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  gap: 14px;
  margin-top: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(20, 184, 166, 0.07), transparent 42%),
    rgba(255, 255, 255, 0.48);
}

.topic-row.selected {
  border-color: rgba(20, 184, 166, 0.5);
}

.topic-rail {
  position: relative;
  display: grid;
  justify-items: center;
}

.topic-rail::after {
  content: "";
  position: absolute;
  top: 18px;
  bottom: -30px;
  width: 1px;
  background: var(--line-strong);
}

.topic-row:last-child .topic-rail::after {
  display: none;
}

.topic-rail span {
  position: relative;
  z-index: 1;
  width: 9px;
  height: 9px;
  margin-top: 6px;
  background: var(--ink);
}

.topic-title {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  justify-content: space-between;
}

.tag,
.room-chip {
  flex: 0 0 auto;
  padding: 5px 8px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.6);
}

.tag.teal {
  color: var(--teal);
}

.tag.amber {
  color: var(--amber);
}

.topic-main p {
  margin: 8px 0 0;
  line-height: 1.5;
}

.odds-line {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 14px;
}

.choice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  background: transparent;
}

.choice.odd {
  background: var(--teal-soft);
}

.choice.even {
  background: var(--amber-soft);
}

.choice span {
  color: var(--muted);
  font-weight: 800;
}

.choice strong {
  font-size: 21px;
}

.topic-meta {
  display: grid;
  align-content: center;
  justify-items: end;
  min-width: 74px;
}

.topic-meta strong {
  font-size: 24px;
}

.mini-flow {
  display: flex;
  align-items: center;
  width: min(100%, 240px);
  margin-top: 14px;
}

.mini-flow span {
  width: 8px;
  height: 8px;
  border: 1px solid var(--teal);
  background: white;
}

.mini-flow i {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, var(--teal), rgba(245, 158, 11, 0.72));
}

.voice-map {
  position: relative;
  min-height: 300px;
  margin-top: 18px;
  border: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.05) 1px, transparent 1px) 0 0 / 34px 34px,
    linear-gradient(0deg, rgba(17, 24, 39, 0.05) 1px, transparent 1px) 0 0 / 34px 34px,
    rgba(255, 255, 255, 0.42);
}

.link-lines {
  position: absolute;
  inset: 22px;
  width: calc(100% - 44px);
  height: calc(100% - 44px);
}

.link-lines path {
  fill: none;
  stroke: rgba(20, 184, 166, 0.52);
  stroke-width: 1.5;
  stroke-dasharray: 6 7;
}

.seat {
  position: absolute;
  display: grid;
  justify-items: center;
  gap: 4px;
  width: 120px;
  text-align: center;
}

.host {
  left: 50%;
  top: 24px;
  transform: translateX(-50%);
}

.seat-left {
  left: 24px;
  bottom: 34px;
}

.seat-right {
  right: 24px;
  bottom: 34px;
}

.seat-bottom {
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
}

.avatar {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: white;
  font-weight: 900;
}

.avatar.teal {
  border-color: var(--teal);
  background: white;
  color: var(--teal);
}

.avatar.amber {
  border-color: var(--amber);
  background: white;
  color: var(--amber);
}

.avatar.dark {
  background: white;
  color: var(--ink);
}

.vp-avatar {
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  background: #0f172a;
  color: #f8fafc;
  background-image: var(--vp-avatar-url);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  font-weight: 900;
}

.vp-avatar--image > span {
  opacity: 0;
}

.pm-market-icon.vp-avatar,
.pm-market-icon--creator.vp-avatar {
  width: 54px;
  height: 54px;
  border-radius: 50%;
}

.mobile-room-avatar-img.vp-avatar,
.mobile-room-avatar.vp-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
}

.mobile-mic-avatar-img.vp-avatar,
.mobile-mic-seat.vp-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
}

.topic-detail-comment-avatar.vp-avatar {
  float: left;
  width: 28px;
  height: 28px;
  margin: 1px 8px 4px 0;
  border-radius: 50%;
}

.guest-avatar.vp-avatar,
.profile-avatar.vp-avatar,
.party-host-avatar .vp-avatar,
.party-seat-avatar .vp-avatar {
  width: 100%;
  height: 100%;
  border-radius: inherit;
}

.party-host-avatar .vp-avatar,
.party-seat-avatar .vp-avatar {
  font-size: inherit;
  line-height: 1;
  background-color: #eaf0f7;
  background-size: contain;
}

.room-seat .vp-avatar {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  font-size: 0;
}

.seat strong {
  font-size: 13px;
}

.transcript {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.message {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.message span {
  display: grid;
  place-items: center;
  height: 28px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.message.ai span {
  color: white;
  background: var(--ink);
}

.message p {
  margin: 0;
  padding: 7px 0 8px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.45;
}

.compact {
  margin-bottom: 18px;
}

.balance-line,
.estimate {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.pick-switch {
  grid-template-columns: 1fr 1fr;
  margin-bottom: 14px;
}

.amount-field {
  position: relative;
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.amount-field input {
  width: 100%;
  height: 54px;
  padding: 0 52px 0 14px;
  border: 1px solid var(--line-strong);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.62);
  font-size: 22px;
  font-weight: 900;
}

.amount-field em {
  position: absolute;
  right: 14px;
  bottom: 16px;
  font-style: normal;
  font-weight: 900;
}

.wide {
  width: 100%;
  min-height: 50px;
}

.settlement-line {
  display: grid;
  grid-template-columns: 1px minmax(0, 1fr);
  gap: 14px;
  margin-top: 18px;
}

.settlement-line span {
  background: linear-gradient(var(--teal), var(--amber));
}

.settlement-line p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.mobile-tabbar {
  display: none;
}

@media (max-width: 1180px) {
  .layout-grid {
    grid-template-columns: minmax(0, 1fr) 340px;
  }

  .trade-panel {
    grid-column: 2;
    grid-row: 1 / span 2;
  }

  .voice-panel {
    grid-column: 1;
  }
}

@media (max-width: 820px) {
  body {
    padding-bottom: 0;
  }

  .app-shell {
    display: block;
  }

  .side-rail {
    display: none;
  }

  .workspace {
    padding: 18px 14px;
  }

  .topbar {
    display: grid;
  }

  .top-actions {
    justify-content: stretch;
  }

  .top-actions button {
    flex: 1;
  }

  .ticker-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .ticker-item:nth-child(2) {
    border-right: 0;
  }

  .ticker-item:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .layout-grid {
    grid-template-columns: 1fr;
  }

  .trade-panel {
    position: static;
    grid-column: auto;
    grid-row: auto;
  }

  .section-head {
    display: grid;
  }

  .topic-row {
    grid-template-columns: 18px minmax(0, 1fr);
  }

  .topic-meta {
    grid-column: 2;
    justify-items: start;
    display: flex;
    align-items: baseline;
    gap: 6px;
  }

  .topic-title {
    display: grid;
  }

  .voice-map {
    min-height: 280px;
  }

  .seat {
    width: 96px;
  }

  .seat-left {
    left: 10px;
  }

  .seat-right {
    right: 10px;
  }

  .mobile-tabbar {
    position: static;
    z-index: 10;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    margin: 0 14px 14px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.92);
    backdrop-filter: blur(18px);
  }

  .mobile-tabbar button {
    min-height: 56px;
    border: 0;
    border-right: 1px solid var(--line);
    gap: 3px;
  }

  .mobile-tabbar button:last-child {
    border-right: 0;
  }

  .mobile-tabbar small {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 38px;
  }

  .ticker-item {
    padding: 14px;
  }

  .market-panel,
  .voice-panel,
  .trade-panel {
    padding: 14px;
  }

  .odds-line {
    grid-template-columns: 1fr;
  }
}

/* Split to ./styles/*.css: removed original lines 967-1436. */
/* Split to ./styles/*.css: removed original lines 1437-1840. */
/* Split to ./styles/*.css: removed original lines 1841-3732. */
    --party-seat-gap: clamp(2px, 1vmin, 5px);
    --party-stack-seat-minh: clamp(48px, 9.5vmin, 64px);
    --party-avatar-guest: clamp(28px, 8vmin, 36px);
    --party-avatar-host: clamp(34px, 9.4vmin, 40px);
  }

  .party-core-card .pm-lead-pct {
    font-size: clamp(18px, 6vmin, 24px);
  }

  .party-mic-chat-stack {
    flex: 1 1 0;
  }
}

.party-inline-chat-head {
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 900;
  color: #94a3b8;
  border-bottom: 1px solid rgba(51, 65, 85, 0.7);
}

.party-inline-chat-body {
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 6px 8px;
}

.party-inline-chat:not(.party-inline-chat--watermark) .party-inline-chat-body {
  flex: 1 1 0;
  min-height: 0;
}

.party-inline-chat-body .room-chat-line-user {
  color: #5eead4;
}

.party-inline-chat-body .room-chat-line-text {
  color: #e2e8f0;
}

.party-inline-chat-body .room-chat-line-time {
  color: #64748b;
}

.room-chat-line--notice .room-chat-line-user {
  color: #94a3b8;
}

.room-chat-line--notice .room-chat-line-text {
  color: #cbd5e1;
  font-size: 11px;
  line-height: 1.5;
}

.room-chat-line--muted .room-chat-line-text {
  color: #64748b;
  font-size: 11px;
}

.party-dock-composer-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.party-dock-composer-row .party-dock-input {
  flex: 1 1 0;
  min-width: 0;
  width: auto;
}

.party-dock-input {
  min-height: 42px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(71, 85, 105, 0.95);
  background: rgba(15, 23, 42, 0.92);
  color: #f1f5f9;
  font-size: 13px;
}

.party-dock-input::placeholder {
  color: #64748b;
}

.party-dock-gift,
.party-dock-send {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  min-width: 44px;
  height: 42px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid rgba(71, 85, 105, 0.85);
  background: rgba(30, 41, 59, 0.9);
  color: #e2e8f0;
  font-size: 18px;
  font-weight: 900;
}

.party-dock-send {
  min-width: 56px;
  font-size: 12px;
  letter-spacing: 0.04em;
}

.party-gift-panel {
  border-radius: 12px;
  border: 1px solid rgba(51, 65, 85, 0.85);
  background: rgba(2, 6, 23, 0.55);
  padding: 10px 10px 12px;
}

.party-gift-panel-label {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 900;
  color: #94a3b8;
}

.party-gift-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}

.party-gift-tab {
  flex: 1;
  min-height: 32px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid rgba(71, 85, 105, 0.9);
  background: rgba(30, 41, 59, 0.75);
  color: #cbd5e1;
  font-size: 11px;
  font-weight: 900;
}

.party-gift-tab--active {
  border-color: rgba(251, 191, 36, 0.55);
  background: rgba(120, 53, 15, 0.35);
  color: #fde68a;
}

.party-gift-recipients {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
  max-height: 100px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.party-gift-recipient-pill {
  max-width: 100%;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(71, 85, 105, 0.85);
  background: rgba(30, 41, 59, 0.9);
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
}

.party-gift-recipient-pill--selected {
  border-color: rgba(45, 212, 191, 0.65);
  background: rgba(6, 78, 59, 0.4);
  color: #99f6e4;
}

.party-gift-empty {
  display: block;
  font-size: 11px;
  color: #64748b;
}

.party-gift-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.party-gift-item {
  min-height: 42px;
  padding: 4px 6px;
  border-radius: 10px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(30, 41, 59, 0.85);
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
}

.party-seat--empty {
  cursor: pointer;
}

.room-chat-empty {
  margin: 0;
  font-size: 11px;
  color: #64748b;
}

.room-chat-lines {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.room-chat-line {
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(51, 65, 85, 0.6);
}

.room-chat-line:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.room-chat-line-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 2px;
}

.room-chat-line-user {
  font-size: 11px;
  font-weight: 900;
}

.room-chat-line-time {
  font-size: 9px;
  font-weight: 800;
}

.room-chat-line-text {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  word-break: break-word;
}

@media (min-width: 0px) {
  body {
    padding-bottom: 0;
  }

  .desktop-home {
    display: none;
  }

  .mobile-home {
    position: relative;
    z-index: 1;
    display: block;
    width: min(100%, 520px);
    margin-inline: auto;
    padding: 12px 10px 18px;
    background:
      linear-gradient(90deg, rgba(33, 203, 189, 0.12) 1px, transparent 1px) 0 0 / 28px 28px,
      linear-gradient(0deg, rgba(33, 203, 189, 0.08) 1px, transparent 1px) 0 0 / 28px 28px,
      radial-gradient(circle at 8% 0%, rgba(33, 203, 189, 0.22), transparent 36%),
      var(--poly-bg);
  }

  .mobile-home-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin-bottom: 10px;
  }

  .mobile-home-nav .home-brand {
    flex: 0 0 auto;
    min-width: 0;
    gap: 8px;
  }

  .mobile-home-nav .home-brand span {
    flex: 0 1 auto;
    min-width: 0;
    max-width: min(104px, 28vw);
  }

  .mobile-home-nav .home-brand strong,
  .mobile-home-nav .home-brand small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-user-bar {
    display: inline-flex;
    align-items: center;
    flex: 0 1 auto;
    min-width: 0;
    width: fit-content;
    max-width: 100%;
    margin-left: auto;
    flex-wrap: nowrap;
    min-height: 32px;
    padding: 2px 4px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.52);
  }

  .mobile-user-bar-cluster {
    display: inline-flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 4px;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .mobile-user-bar-cluster::-webkit-scrollbar {
    display: none;
  }

  .mobile-user-bar-cluster > button:not(.mobile-user-logout) {
    flex: 0 0 auto;
    min-height: 26px;
    padding: 0 6px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--ink);
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
  }

  .mobile-user-bar-cluster > button[data-action="login"] {
    border-color: transparent;
    background: transparent;
    color: var(--muted);
  }

  .mobile-user-bar-cluster > button[data-action="share"] {
    border-color: var(--line);
    color: var(--ink);
    background: rgba(255, 255, 255, 0.72);
  }

  .mobile-user-status {
    flex: 0 0 auto;
    padding: 2px 5px;
    border: 1px solid rgba(20, 184, 166, 0.38);
    border-radius: 6px;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 10px;
    font-style: normal;
    font-weight: 900;
    white-space: nowrap;
  }

  .mobile-user-name {
    flex: 0 1 auto;
    min-width: 0;
    max-width: min(140px, 36vw);
    overflow: hidden;
    font-size: 12px;
    font-weight: 800;
    text-align: right;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-user-bar-cluster .mobile-user-logout {
    flex: 0 0 auto;
    min-height: 26px;
    padding: 0 6px;
    border: 1px solid rgba(180, 83, 9, 0.35);
    border-radius: 6px;
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
    color: #b45309;
    background: rgba(251, 191, 36, 0.12);
  }

  .mobile-home .home-brand img {
    width: 38px;
    height: 38px;
  }

  .mobile-hero {
    position: relative;
    padding: 6px 0 10px;
  }

  .mobile-hero::after {
    content: "";
    position: absolute;
    right: 0;
    top: 28px;
    width: 42%;
    height: 30px;
    border: 1px solid rgba(20, 184, 166, 0.24);
    border-left: 0;
    pointer-events: none;
  }

  .mobile-hero h1 {
    position: relative;
    max-width: 100%;
    margin-bottom: 12px;
    overflow: hidden;
    font-size: 22px;
    line-height: 1.1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-stats {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .mobile-stats::-webkit-scrollbar {
    display: none;
  }

  .mobile-stats span {
    flex: 0 0 auto;
    min-width: 82px;
    min-height: 54px;
    padding: 8px 10px;
    border: 1px solid rgba(17, 24, 39, 0.12);
    border-radius: 12px;
    background: rgba(250, 255, 253, 0.86);
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-align: left;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.76) inset;
  }

  .mobile-stats strong {
    display: block;
    color: var(--ink);
    font-size: clamp(16px, 4.2vw, 18px);
    font-weight: 900;
  }

  .mobile-market-nav,
  .mobile-market-filters {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    margin-top: 8px;
    padding: 2px 0 4px;
    scrollbar-width: none;
  }

  .mobile-market-nav::-webkit-scrollbar,
  .mobile-market-filters::-webkit-scrollbar {
    display: none;
  }

  .mobile-market-nav button,
  .mobile-market-filters button {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid rgba(17, 24, 39, 0.12);
    border-radius: 999px;
    background: rgba(250, 255, 253, 0.82);
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
  }

  .mobile-market-nav button.active,
  .mobile-market-filters button.active {
    border-color: var(--aqua-line);
    background: rgba(33, 203, 189, 0.13);
    color: var(--ink);
    box-shadow: 0 0 0 1px rgba(33, 203, 189, 0.12) inset;
  }

  .mobile-broadcast {
    margin-top: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.62);
    overflow: hidden;
  }

  .broadcast-head {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 40px;
    padding: 0 12px;
    border-bottom: 1px solid var(--line);
    font-size: 13px;
  }

  .broadcast-stack {
    position: relative;
    height: 210px;
    overflow: hidden;
  }

  .broadcast-stack::before,
  .broadcast-stack::after {
    content: "";
    position: absolute;
    z-index: 2;
    left: 0;
    right: 0;
    height: 24px;
    pointer-events: none;
  }

  .broadcast-stack::before {
    top: 0;
    background: linear-gradient(var(--panel), transparent);
  }

  .broadcast-stack::after {
    bottom: 0;
    background: linear-gradient(transparent, var(--panel));
  }

  .feed-track {
    display: grid;
    animation: feedScroll 18s linear infinite;
  }

  .feed-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--line);
  }

  .feed-item:last-child {
    border-bottom: 0;
  }

  .feed-item b {
    display: block;
    margin-bottom: 3px;
    color: var(--teal);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .feed-item span {
    display: block;
    color: var(--ink-2);
    font-size: 13px;
    line-height: 1.35;
  }

  .feed-item button {
    align-self: center;
    min-height: 30px;
    padding: 0 9px;
    border: 1px solid rgba(20, 184, 166, 0.46);
    background: var(--teal-soft);
    color: var(--ink);
    font-size: 11px;
    font-weight: 900;
  }

  @keyframes feedScroll {
    from {
      transform: translateY(0);
    }
    to {
      transform: translateY(-50%);
    }
  }

  .quick-match {
    display: grid;
    gap: 12px;
    margin-top: 14px;
    padding: 14px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.14), transparent 60%),
      rgba(255, 255, 255, 0.72);
    box-shadow: var(--shadow);
  }

  .quick-match-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
  }

  .quick-match-head h2 {
    font-size: 22px;
    line-height: 1.05;
  }

  .quick-match-head > span {
    flex: 0 0 auto;
    padding: 6px 9px;
    border: 1px solid rgba(20, 184, 166, 0.38);
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 950;
  }

  .quick-mode-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .quick-mode-tabs button,
  .quick-stakes button,
  .quick-match-card button {
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.8);
    color: var(--ink);
    font-weight: 950;
  }

  .quick-mode-tabs button {
    min-height: 40px;
    border-radius: 999px;
    color: var(--muted);
  }

  .quick-mode-tabs button.active {
    border-color: rgba(20, 184, 166, 0.46);
    background: var(--teal-soft);
    color: var(--ink);
  }

  .quick-mode-desc {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    line-height: 1.45;
  }

  .quick-stakes {
    display: flex;
    gap: 8px;
    margin-inline: -14px;
    padding: 0 14px 2px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .quick-stakes::-webkit-scrollbar {
    display: none;
  }

  .quick-stakes button {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 0 11px;
    border-radius: 999px;
    color: var(--muted);
    font-size: 12px;
    white-space: nowrap;
  }

  .quick-stakes button.active {
    border-color: rgba(245, 158, 11, 0.48);
    background: var(--amber-soft);
    color: var(--ink);
  }

  .quick-match-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 116px;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.66);
  }

  .quick-match-card span,
  .quick-match-card small {
    display: block;
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
  }

  .quick-match-card strong {
    display: block;
    margin: 4px 0;
    color: var(--ink);
    font-size: 22px;
    line-height: 1;
  }

  .quick-match-card button {
    min-height: 48px;
    border-color: var(--ink);
    background: var(--ink);
    color: white;
  }

  .mobile-actions {
    gap: 10px;
    margin-top: 14px;
  }

  .mobile-actions button {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    justify-items: start;
    align-items: center;
    gap: 9px;
    width: 100%;
    min-height: 88px;
    padding: 13px;
    border: 1px solid var(--line);
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.1), transparent 60%),
      rgba(255, 255, 255, 0.66);
    text-align: left;
  }

  .mobile-actions .create-icon {
    width: 36px;
    height: 36px;
  }

  .mobile-actions strong {
    font-size: 16px;
  }

  .mobile-actions small {
    grid-column: 2;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.4;
  }

  .mobile-section {
    margin-top: 12px;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }

  .mobile-section-head {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    padding: 0 2px;
  }

  .mobile-section-head h2 {
    font-size: 22px;
  }

  .mobile-section-head button {
    min-height: 34px;
    padding: 0 10px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.58);
    color: var(--muted);
    font-weight: 900;
  }

  .mobile-section-head .create-topic-inline {
    border-color: var(--aqua-line);
    border-radius: 999px;
    background: rgba(33, 203, 189, 0.13);
    color: var(--ink);
  }

  .mobile-topic {
    display: grid;
    gap: 10px;
    margin-top: 0;
    padding: 12px;
    border: 1px solid rgba(17, 24, 39, 0.12);
    border-radius: 14px;
    background: var(--poly-card);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.78) inset, 0 10px 24px rgba(15, 23, 42, 0.05);
  }

  .mobile-topic-list > .mobile-topic:nth-child(even) {
    background: rgba(250, 255, 253, 0.9);
    border-color: rgba(17, 24, 39, 0.1);
  }

  .mobile-topic-list > .mobile-topic:nth-child(odd) {
    background: rgba(244, 252, 250, 0.92);
    border-color: rgba(17, 24, 39, 0.12);
  }

  .mobile-topic-list > .mobile-topic.selected {
    border-color: var(--aqua-line);
    background:
      linear-gradient(120deg, rgba(33, 203, 189, 0.13), rgba(250, 255, 253, 0.72) 58%, rgba(255, 255, 255, 0.9));
    box-shadow: 0 0 0 1px rgba(33, 203, 189, 0.16), 0 10px 26px rgba(33, 203, 189, 0.08);
  }

  /* Polymarket 式卡片头：创建者 + 品种图标、标题、标签、成交量、时间 */
  .pm-topic-cover {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 8px 10px;
    align-items: start;
  }

  .pm-creator-col {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    width: 52px;
    flex-shrink: 0;
  }

  .pm-creator {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    width: 100%;
    min-height: 58px;
    padding-left: 2px;
  }

  .pm-follow-btn {
    position: absolute;
    left: 26px;
    top: -1px;
    z-index: 2;
    min-width: 36px;
    min-height: 20px;
    padding: 0 6px;
    border: 1px solid rgba(239, 68, 68, 0.32);
    border-radius: 999px;
    background: rgba(254, 242, 242, 0.9);
    color: #ef4444;
    font-size: 10px;
    font-weight: 950;
    line-height: 1;
    white-space: nowrap;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.72) inset;
  }

  .pm-follow-btn.is-followed {
    border-color: rgba(20, 184, 166, 0.34);
    background: var(--teal-soft);
    color: var(--teal);
  }

  .pm-creator-avatar {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(17, 24, 39, 0.12);
    background: var(--ink);
    color: white;
    font-size: 11px;
    font-weight: 900;
    line-height: 1;
  }

  .pm-creator-name {
    max-width: 52px;
    padding: 0 1px;
    font-size: 9px;
    font-weight: 800;
    line-height: 1.2;
    color: var(--muted);
    text-align: left;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    word-break: break-all;
  }

  .pm-creator-col .pm-icon {
    width: 44px;
    height: 44px;
    font-size: 11px;
    margin-left: 2px;
  }

  .pm-icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid var(--line-strong);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.78);
    font-size: 19px;
    font-weight: 900;
    line-height: 1;
    color: var(--ink);
  }

  .pm-icon--pulse {
    border-color: rgba(20, 184, 166, 0.55);
    box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.18);
  }

  .pm-cover-main {
    min-width: 0;
  }

  .pm-title-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: start;
  }

  .pm-title {
    margin: 0;
    font-size: 16px;
    line-height: 1.28;
    font-weight: 900;
    color: var(--ink);
  }

  .pm-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    margin-top: 7px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
    line-height: 1.25;
  }

  .pm-meta-row span:not(:last-child)::after {
    content: "·";
    margin-left: 8px;
    color: rgba(100, 116, 139, 0.72);
  }

  .pm-tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
  }

  .pm-tag {
    padding: 2px 9px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(248, 250, 252, 0.95);
    font-size: 11px;
    font-weight: 800;
    color: var(--muted);
  }

  .pm-vol-row {
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin-top: 8px;
    flex-wrap: wrap;
  }

  .pm-rule-btn {
    align-self: center;
    min-height: 24px;
    padding: 0 9px;
    border: 1px solid var(--aqua-line);
    border-radius: 999px;
    background: rgba(33, 203, 189, 0.12);
    color: #079488;
    font-size: 11px;
    font-weight: 950;
    white-space: nowrap;
  }

  .pm-vol-num {
    font-size: 18px;
    font-weight: 900;
    letter-spacing: -0.02em;
    color: var(--ink);
  }

  .pm-vol-suffix {
    font-size: 11px;
    font-weight: 800;
    color: var(--muted);
    letter-spacing: 0.08em;
  }

  .pm-status-chip {
    align-self: center;
    min-height: 23px;
    padding: 4px 8px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.1);
    color: var(--teal);
    font-size: 11px;
    font-weight: 950;
    line-height: 1;
    white-space: nowrap;
  }

  .pm-status-chip--round-ended {
    border-color: rgba(245, 158, 11, 0.42);
    background: rgba(245, 158, 11, 0.12);
    color: #b45309;
  }

  .pm-status-chip--settled {
    border-color: rgba(100, 116, 139, 0.34);
    background: rgba(100, 116, 139, 0.1);
    color: #64748b;
  }

  .market-topic-strip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0 2px 8px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 900;
  }

  .market-topic-strip strong {
    color: #0f766e;
    font-size: 12px;
  }

  .market-odds-rows {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .market-odds-rows--compact {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .market-odds-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 48px;
    padding: 9px 12px;
    border: 1px solid rgba(15, 118, 110, 0.18);
    border-radius: 10px;
    background: rgba(240, 253, 250, 0.82);
    color: var(--ink);
    text-align: left;
  }

  .market-odds-row--no {
    border-color: rgba(190, 18, 60, 0.16);
    background: rgba(255, 241, 242, 0.78);
  }

  .market-odds-row span {
    display: grid;
    gap: 2px;
    min-width: 0;
  }

  .market-odds-row strong {
    font-size: 13px;
    font-weight: 950;
    line-height: 1.1;
  }

  .market-odds-row small {
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    line-height: 1.1;
  }

  .market-odds-row em {
    margin-left: auto;
    color: #0f766e;
    font-size: 18px;
    font-style: normal;
    font-weight: 950;
    line-height: 1;
    white-space: nowrap;
  }

  .market-odds-row--no em {
    color: #be123c;
  }

  .market-mini-chart {
    display: block;
    width: 100%;
    height: 64px;
  }

  .market-mini-chart--empty {
    display: grid;
    place-items: center;
    border: 1px dashed rgba(15, 118, 110, 0.18);
    border-radius: 8px;
    color: rgba(15, 23, 42, 0.52);
    font-size: 12px;
    font-weight: 800;
  }

  .topic-detail-core--market .topic-detail-core-head strong {
    color: #0f766e;
  }

  .topic-detail-market-card {
    display: grid;
    gap: 10px;
    margin: 10px 0;
  }

  .topic-detail-market-chart {
    position: relative;
    overflow: hidden;
    min-height: 78px;
    padding: 10px 12px 4px;
    border: 1px solid rgba(15, 118, 110, 0.14);
    border-radius: 10px;
    background: rgba(248, 250, 252, 0.88);
  }

  .topic-detail-market-chart span {
    position: absolute;
    top: 8px;
    right: 12px;
    color: #0f766e;
    font-size: 12px;
    font-weight: 950;
  }

  .party-core-card--market {
    display: grid;
    gap: 10px;
    padding: 12px;
    border-color: rgba(94, 234, 212, 0.28);
    background:
      linear-gradient(180deg, rgba(20, 184, 166, 0.12), rgba(15, 23, 42, 0.16)),
      rgba(15, 23, 42, 0.76);
    color: #dffcf8;
  }

  .party-market-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    font-size: 12px;
    font-weight: 950;
  }

  .party-market-head span {
    color: #7dd3fc;
  }

  .party-market-head strong {
    color: #fef08a;
  }

  .party-market-chart {
    position: relative;
    min-height: 76px;
    padding: 8px 8px 2px;
    border: 1px solid rgba(94, 234, 212, 0.16);
    border-radius: 10px;
    background: rgba(2, 6, 23, 0.28);
  }

  .party-market-chart span {
    position: absolute;
    top: 7px;
    right: 10px;
    color: #5eead4;
    font-size: 12px;
    font-weight: 950;
  }

  .party-core-card--market .market-odds-row {
    min-height: 46px;
    border-color: rgba(94, 234, 212, 0.18);
    background: rgba(6, 78, 59, 0.36);
    color: #ecfeff;
  }

  .party-core-card--market .market-odds-row--no {
    border-color: rgba(251, 113, 133, 0.18);
    background: rgba(76, 5, 25, 0.34);
  }

  .party-core-card--market .market-odds-row small {
    color: rgba(226, 232, 240, 0.72);
  }

  .party-core-card--market .market-odds-row em {
    color: #5eead4;
  }

  .party-core-card--market .market-odds-row--no em {
    color: #fda4af;
  }

  .party-market-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .party-market-stats span {
    display: grid;
    gap: 2px;
    min-height: 42px;
    padding: 8px 10px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.36);
    color: rgba(226, 232, 240, 0.74);
    font-size: 10px;
    font-weight: 800;
  }

  .party-market-stats strong {
    color: #f8fafc;
    font-size: 12px;
  }

  .topic-detail-core--market {
    padding: 0;
    border: 0;
    background: transparent;
  }

  .topic-detail-market-inline {
    display: block;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .party-core-card--market {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .market-trading-card {
    --market-card-border: #e5e7eb;
    --market-card-bg: #ffffff;
    --market-card-text: #111827;
    --market-card-muted: #6b7280;
    --market-card-line: #e5e7eb;
    --market-chip-bg: #f9fafb;
    --market-chip-text: #0f766e;
    --market-green: #16a34a;
    --market-red: #dc2626;
    display: grid;
    gap: 7px;
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--market-card-border);
    border-radius: 8px;
    background: var(--market-card-bg);
    color: var(--market-card-text);
    padding: 7px;
    box-shadow: none;
  }

  .market-trading-card--room {
    --market-card-border: rgba(96, 165, 250, 0.58);
    --market-card-bg: linear-gradient(180deg, rgba(8, 34, 48, 0.92), rgba(6, 18, 33, 0.94));
    --market-card-text: #e5f6ff;
    --market-card-muted: #a6bdd3;
    --market-card-line: rgba(125, 211, 252, 0.18);
    --market-chip-bg: rgba(6, 95, 70, 0.50);
    --market-chip-text: #74f2a0;
    --market-green: #77e66f;
    --market-red: #ff545e;
    box-shadow: inset 0 0 20px rgba(14, 165, 233, 0.06);
  }

  .market-trading-card--room-live {
    gap: 6px;
    border: 0;
    border-radius: 8px;
    background:
      linear-gradient(135deg, rgba(6, 41, 47, 0.96), rgba(8, 24, 39, 0.98) 56%, rgba(16, 16, 31, 0.98)),
      #081622;
    padding: 8px 10px 10px;
  }

  .market-room-live-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-width: 0;
  }

  .market-trading-card--room-live .market-trading-tags {
    gap: 5px;
  }

  .market-trading-card--room-live .market-trading-tags i {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: #ff465a;
    box-shadow: 0 0 0 3px rgba(255, 70, 90, 0.12);
  }

  .market-trading-card--room-live .market-trading-tags em {
    color: #ff7080;
    font-size: 9px;
    font-style: normal;
    font-weight: 900;
    line-height: 1;
  }

  .market-room-countdown {
    display: inline-flex;
    align-items: baseline;
    gap: 7px;
    min-width: 0;
    white-space: nowrap;
  }

  .market-room-countdown small {
    color: #9fb0c2;
    font-size: 9px;
    font-weight: 800;
  }

  .market-room-countdown strong {
    color: #ffe66b;
    font-size: 12px;
    font-weight: 950;
  }

  .market-room-live-line {
    display: grid;
    grid-template-columns: auto minmax(70px, 1fr) auto auto;
    align-items: center;
    gap: 8px;
    min-height: 29px;
    padding: 0 8px;
    border: 1px solid rgba(35, 96, 107, 0.72);
    border-radius: 7px;
    background: linear-gradient(135deg, rgba(11, 62, 62, 0.86), rgba(16, 23, 44, 0.86));
  }

  .market-room-live-line span {
    color: #90a4b8;
    font-size: 9px;
    font-weight: 850;
  }

  .market-room-live-line strong {
    min-width: 0;
    color: #dbeafe;
    font-size: 13px;
    font-weight: 950;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .market-room-live-line strong.is-yes {
    color: #5fffc5;
  }

  .market-room-live-line strong.is-no {
    color: #ff7280;
  }

  .market-room-live-line em {
    color: #ffffff;
    font-size: 10px;
    font-style: normal;
    font-weight: 900;
    white-space: nowrap;
  }

  .market-room-live-line b {
    color: #ffe66b;
    font-size: 10px;
    font-weight: 950;
    white-space: nowrap;
  }

  .market-room-live-line.has-trade {
    animation: none;
  }

  .market-room-live-line.is-empty {
    border-color: rgba(148, 163, 184, 0.26);
    background: linear-gradient(135deg, rgba(15, 37, 48, 0.72), rgba(15, 23, 42, 0.74));
  }

  .market-room-live-line.is-empty strong {
    color: #cbd5e1;
  }

  .market-room-live-line.is-empty em,
  .market-room-live-line.is-empty b {
    color: #94a3b8;
  }

  .market-room-data-flash {
    animation: marketRoomDataFlash 760ms ease-out 1;
  }

  @keyframes marketRoomDataFlash {
    0% {
      background-color: rgba(94, 234, 212, 0.28);
      box-shadow: 0 0 0 0 rgba(94, 234, 212, 0.42);
      border-color: rgba(94, 234, 212, 0.86);
    }
    55% {
      background-color: rgba(94, 234, 212, 0.10);
      box-shadow: 0 0 0 5px rgba(94, 234, 212, 0.06);
    }
    100% {
      background-color: transparent;
      box-shadow: none;
      border-color: rgba(35, 96, 107, 0.72);
    }
  }

  .market-room-quote-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .market-room-quote {
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "label percent"
      "price depth";
    align-items: center;
    min-height: 34px;
    padding: 5px 9px 5px 8px;
    border: 1px solid rgba(36, 93, 100, 0.82);
    border-radius: 7px;
    background: rgba(8, 45, 48, 0.72);
  }

  .market-room-quote--no {
    border-color: rgba(89, 51, 74, 0.86);
    background: rgba(33, 21, 39, 0.78);
  }

  .market-room-quote small {
    grid-area: label;
    color: #9ab0bd;
    font-size: 9px;
    font-weight: 800;
  }

  .market-room-quote strong {
    grid-area: price;
    color: #52ffd1;
    font-size: 16px;
    font-weight: 950;
    line-height: 1;
    white-space: nowrap;
  }

  .market-room-quote--no strong {
    color: #ff6677;
  }

  .market-room-quote strong em {
    margin-left: 4px;
    font-size: 8px;
    font-style: normal;
    font-weight: 850;
  }

  .market-room-quote b {
    grid-area: percent;
    color: #8bff77;
    font-size: 10px;
    font-weight: 950;
    text-align: right;
  }

  .market-room-quote--no b {
    color: #ff8792;
  }

  .market-room-quote span {
    grid-area: depth;
    color: #7896a7;
    font-size: 8px;
    font-weight: 850;
    text-align: right;
    white-space: nowrap;
  }

  .market-room-tape {
    display: grid;
    grid-template-rows: 14px repeat(7, 13px);
    gap: 0;
    min-height: 106px;
    padding: 7px 8px 6px;
    border: 1px solid rgba(38, 63, 81, 0.86);
    border-radius: 7px;
    background: rgba(7, 26, 37, 0.84);
  }

  .market-room-tape-head,
  .market-room-tape-row {
    display: grid;
    grid-template-columns: 62px 56px 58px 48px minmax(0, 1fr);
    align-items: center;
    gap: 0;
    min-width: 0;
    margin: 0;
  }

  .market-room-tape-head span {
    color: #8090a2;
    font-size: 8px;
    font-weight: 850;
    white-space: nowrap;
  }

  .market-room-tape-head span:first-child {
    color: #91a8b6;
    font-size: 9px;
    font-weight: 900;
  }

  .market-room-tape-row i {
    display: block;
  }

  .market-room-tape-row span,
  .market-room-tape-row strong {
    min-width: 0;
    color: #8fa2b5;
    font-size: 9px;
    font-style: normal;
    font-weight: 800;
    line-height: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .market-room-tape-row strong {
    color: #f8fafc;
    font-weight: 950;
  }

  .market-room-tape-row strong.is-yes {
    color: #55ffd0;
  }

  .market-room-tape-row strong.is-no {
    color: #ff7280;
  }

  .market-room-tape-row span:last-child {
    text-align: right;
  }

  .market-room-tape-row.is-latest span,
  .market-room-tape-row.is-latest strong {
    color: #ffffff;
  }

  .market-room-tape-row.is-latest strong.is-yes {
    color: #55ffd0;
  }

  .market-room-tape-row.is-latest strong.is-no {
    color: #ff7280;
  }

  .market-room-tape-row--placeholder span,
  .market-room-tape-row--placeholder strong {
    color: #4d6476;
  }

  .market-trading-actions--room-live {
    gap: 10px;
  }

  .market-trading-actions--room-live .market-trading-action {
    min-height: 22px;
    border-radius: 6px;
  }

  .market-trading-actions--room-live .market-trading-action strong {
    font-size: 11px;
  }

  .market-trading-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
  }

  .market-trading-tags {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
  }

  .market-trading-tags span,
  .market-trading-tags strong {
    display: inline-flex;
    align-items: center;
    min-height: 16px;
    border: 1px solid rgba(16, 185, 129, 0.26);
    border-radius: 999px;
    background: var(--market-chip-bg);
    color: var(--market-chip-text);
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    padding: 0 6px;
    white-space: nowrap;
  }

  .market-trading-card--room .market-trading-tags span,
  .market-trading-card--room .market-trading-tags strong {
    min-height: 16px;
    font-size: 9px;
    padding: 0 5px;
  }

  .market-trading-my-data-chip {
    min-height: 18px;
    border: 1px solid rgba(20, 184, 166, 0.28);
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.08);
    color: #0f766e;
    font-size: 9px;
    font-weight: 850;
    line-height: 1;
    padding: 0 7px;
    white-space: nowrap;
  }

  .market-trading-percent {
    display: grid;
    justify-items: end;
    min-width: 56px;
    color: var(--market-green);
    line-height: 1;
  }

  .market-trading-percent small {
    font-size: 8px;
    font-weight: 800;
  }

  .market-trading-percent em {
    margin-top: 1px;
    font-size: 18px;
    font-style: normal;
    font-weight: 950;
    letter-spacing: 0;
  }

  .market-trading-card--room .market-trading-percent small {
    font-size: 9px;
  }

  .market-trading-card--room .market-trading-percent em {
    font-size: 18px;
  }

  .market-trading-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 3px;
    margin: 0;
  }

  .market-trading-metrics span {
    display: grid;
    gap: 2px;
    min-height: 28px;
    padding: 3px 5px;
    border: 1px solid var(--market-card-line);
    border-radius: 7px;
    background: rgba(148, 163, 184, 0.06);
  }

  .market-trading-metrics small {
    color: var(--market-card-muted);
    font-size: 8px;
    font-weight: 700;
  }

  .market-trading-metrics strong {
    color: var(--market-card-text);
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
  }

  .market-trading-metrics span:nth-child(2) strong {
    color: var(--market-green);
  }

  .market-trading-metrics span:nth-child(3) strong {
    color: var(--market-red);
  }

  .market-trading-ranges {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    height: 30px;
    overflow: hidden;
    border: 1px solid var(--market-card-line);
    border-radius: 10px;
    background: rgba(148, 163, 184, 0.08);
    margin: 4px 0 8px;
  }

  .market-trading-ranges button {
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: var(--market-card-muted);
    font-size: 13px;
    font-weight: 850;
  }

  .market-trading-ranges button.is-active {
    background: #0f172a;
    color: #ffffff;
    box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.22);
  }

  .market-trade-chart {
    display: block;
    width: 100%;
    height: auto;
    margin-top: 2px;
    font-family: inherit;
  }

  .market-trade-chart-wrap {
    display: grid;
    gap: 7px;
    margin-top: 2px;
  }

  .market-trade-chart--empty {
    display: grid;
    min-height: 96px;
    place-items: center;
    border: 1px dashed var(--market-card-line);
    border-radius: 8px;
    color: var(--market-card-muted);
    font-size: 12px;
    font-weight: 800;
  }

  .market-trade-chart-grid text,
  .market-trade-chart-volume-label,
  .market-trade-chart-volume-scale,
  .market-trade-chart-volume-caption,
  .market-trade-chart-x text {
    fill: var(--market-card-muted);
    font-size: 9px;
    font-weight: 780;
  }

  .market-trade-chart-grid line {
    stroke: var(--market-card-line);
    stroke-dasharray: 2 3;
  }

  .market-trade-chart-grid .market-trade-chart-midline {
    stroke: rgba(15, 23, 42, 0.28);
    stroke-dasharray: none;
    stroke-width: 1.2;
  }

  .market-trade-chart-side-label {
    fill: var(--market-card-muted);
    font-size: 9px;
    font-weight: 900;
    opacity: 0.82;
  }

  .market-trade-chart-side-label--yes {
    fill: #0f766e;
  }

  .market-trade-chart-side-label--no {
    fill: #dc2626;
  }

  .market-trade-chart-line {
    fill: none;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .market-trade-chart-line--yes {
    filter: drop-shadow(0 1px 3px rgba(22, 163, 74, 0.16));
  }

  .market-trade-chart-line--no {
    filter: drop-shadow(0 1px 3px rgba(220, 38, 38, 0.14));
  }

  .market-trade-chart-area {
    opacity: 0.9;
  }

  .market-trade-chart-cursor {
    stroke: rgba(15, 118, 110, 0.42);
    stroke-dasharray: 3 3;
    stroke-width: 1;
  }

  .market-trade-chart-dot--selected {
    stroke: #ecfdf5;
    stroke-width: 2;
  }

  .market-trade-chart-dot--yes {
    fill: #16a05d;
  }

  .market-trade-chart-dot--no {
    fill: #dc2626;
  }

  .market-trade-chart-hit {
    cursor: pointer;
    fill: transparent;
    stroke: transparent;
    outline: none;
  }

  .market-trade-chart-touch {
    cursor: crosshair;
    fill: transparent;
    pointer-events: all;
    stroke: transparent;
    outline: none;
  }

  .market-trade-chart-hit.is-selected,
  .market-trade-chart-hit:focus-visible {
    stroke: rgba(15, 118, 110, 0.32);
    stroke-width: 2;
  }

  .market-trade-chart-toast {
    pointer-events: none;
  }

  .market-trade-chart-toast rect {
    fill: rgba(15, 23, 42, 0.88);
    stroke: rgba(45, 212, 191, 0.38);
    stroke-width: 1;
  }

  .market-trade-chart-toast text {
    fill: #f8fafc;
    font-size: 9px;
    font-weight: 800;
  }

  .market-trade-chart-toast text:first-of-type {
    fill: #5eead4;
    font-size: 9px;
    font-weight: 900;
  }

  .market-trade-chart-click-dot {
    fill: #14b8a6;
    stroke: rgba(255, 255, 255, 0.92);
    stroke-width: 1.5;
  }

  .market-trade-chart-bars rect {
    rx: 1.6px;
  }

  .market-trade-chart-bars .market-trade-chart-bar-yes {
    fill: rgba(34, 197, 94, 0.58);
  }

  .market-trade-chart-bars .market-trade-chart-bar-no {
    fill: rgba(239, 68, 68, 0.52);
  }

  .market-trading-card--room .market-trade-chart-bars rect {
    opacity: 0.9;
  }

  .market-trade-chart-point-panel {
    display: grid;
    gap: 6px;
    padding: 8px 9px;
    border: 1px solid var(--market-card-line);
    border-radius: 8px;
    background: rgba(15, 118, 110, 0.055);
    color: var(--market-card-muted);
    font-size: 10px;
    font-weight: 780;
  }

  .market-trade-chart-point-head {
    display: grid;
    gap: 2px;
    min-width: 0;
  }

  .market-trade-chart-point-head span,
  .market-trade-chart-point-panel > span {
    color: var(--market-card-muted);
    min-width: 0;
  }

  .market-trade-chart-point-head strong,
  .market-trade-chart-point-panel > strong {
    color: var(--market-card-text);
    font-size: 11px;
    font-weight: 900;
    white-space: normal;
  }

  .market-trade-chart-point-panel dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
    margin: 0;
  }

  .market-trade-chart-point-panel dl span {
    min-width: 0;
    padding: 5px 6px;
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.58);
  }

  .market-trade-chart-point-panel dl span.is-wide {
    grid-column: 1 / -1;
  }

  .market-trade-chart-point-panel dt,
  .market-trade-chart-point-panel dd {
    margin: 0;
    white-space: normal;
    overflow-wrap: anywhere;
    line-height: 1.28;
  }

  .market-trade-chart-point-panel dt {
    color: var(--market-card-muted);
    font-size: 9px;
  }

  .market-trade-chart-point-panel dd {
    color: var(--market-card-text);
    font-size: 10px;
    font-weight: 900;
    margin-top: 2px;
  }

  .market-trade-chart-point-panel.is-empty {
    grid-template-columns: auto 1fr;
    align-items: center;
  }

  .market-trading-position {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 5px;
    min-height: 24px;
    margin-top: 0;
    border: 1px solid var(--market-card-line);
    border-radius: 7px;
    padding: 3px 6px;
    color: var(--market-card-muted);
    font-size: 9px;
    font-weight: 750;
  }

  .market-trading-position strong {
    color: var(--market-card-text);
    text-align: left;
    font-size: 10px;
    font-weight: 800;
  }

  .market-trading-position em {
    font-style: normal;
    font-size: 10px;
    font-weight: 850;
  }

  .market-trading-position em.is-positive {
    color: var(--market-green);
  }

  .market-trading-position em.is-negative {
    color: var(--market-red);
  }

  .market-trading-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    margin-top: 0;
  }

  .market-trading-action {
    min-height: 28px;
    border-radius: 7px;
    border: 1px solid var(--market-card-line);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    text-align: center;
  }

  .market-trading-action strong,
  .market-trading-action small {
    display: block;
    line-height: 1.15;
  }

  .market-trading-action strong {
    font-size: 10px;
  }

  .market-trading-action small {
    margin-top: 1px;
    font-size: 8px;
    font-weight: 700;
  }

  .market-trading-action--yes {
    border-color: rgba(22, 163, 74, 0.44);
    background: linear-gradient(180deg, #1dbb69, #139553);
  }

  .market-trading-action--no {
    border-color: rgba(220, 38, 38, 0.44);
    background: linear-gradient(180deg, #ef3c49, #cc2634);
  }

  .market-trading-action--position {
    background: transparent;
    color: var(--market-card-text);
  }

  .market-trading-card--room .market-trading-action--position {
    color: #f8fafc;
    background: rgba(2, 6, 23, 0.18);
  }

  .market-detail-full {
    display: grid;
    gap: 8px;
    margin-top: 8px;
  }

  .market-detail-section {
    display: grid;
    gap: 8px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #ffffff;
    padding: 8px;
  }

  .market-detail-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
  }

  .market-detail-section-head h3,
  .market-detail-user-grid h4,
  .market-detail-book-outcome h4 {
    margin: 0;
    color: #111827;
    font-size: 12px;
    font-weight: 900;
    line-height: 1.2;
  }

  .market-detail-section-head span {
    color: #6b7280;
    font-size: 10px;
    font-weight: 800;
  }

  .market-detail-decision {
    display: grid;
    gap: 8px;
  }

  .market-detail-decision-main {
    display: flex;
    align-items: center;
    gap: 7px;
    overflow-x: auto;
    border: 1px solid rgba(20, 184, 166, 0.22);
    border-radius: 8px;
    background: rgba(20, 184, 166, 0.07);
    padding: 8px;
    white-space: nowrap;
  }

  .market-detail-decision-main span,
  .market-detail-decision-main small,
  .market-detail-decision-main em {
    flex: 0 0 auto;
    color: #0f766e;
    font-size: 10px;
    font-style: normal;
    font-weight: 850;
  }

  .market-detail-decision-main strong {
    flex: 0 0 auto;
    color: #111827;
    font-size: 11px;
    font-weight: 950;
    line-height: 1.2;
  }

  .market-detail-decision-main em {
    color: #374151;
  }

  .market-detail-decision-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .market-detail-decision-grid span {
    display: grid;
    gap: 2px;
    min-width: 0;
    border: 1px solid #e5e7eb;
    border-radius: 7px;
    background: #f9fafb;
    padding: 6px;
  }

  .market-detail-decision-grid small {
    color: #6b7280;
    font-size: 9px;
    font-weight: 750;
  }

  .market-detail-decision-grid strong {
    color: #111827;
    font-size: 12px;
    font-weight: 900;
  }

  .market-detail-decision p,
  .market-detail-help {
    margin: 0;
    color: #6b7280;
    font-size: 10px;
    font-weight: 750;
    line-height: 1.45;
  }

  .market-detail-outcomes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }

  .market-detail-outcome {
    display: grid;
    gap: 7px;
    min-width: 0;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #f9fafb;
    padding: 8px;
  }

  .market-detail-outcome > div {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
  }

  .market-detail-outcome small {
    color: #6b7280;
    font-size: 10px;
    font-weight: 850;
  }

  .market-detail-outcome strong {
    color: #0f766e;
    font-size: 18px;
    font-weight: 950;
    line-height: 1;
    white-space: nowrap;
  }

  .market-detail-outcome--no strong {
    color: #dc2626;
  }

  .market-detail-outcome dl {
    display: grid;
    gap: 4px;
    margin: 0;
  }

  .market-detail-outcome dl span,
  .market-detail-rules p,
  .market-detail-user-row,
  .market-detail-book-row,
  .market-detail-table-head,
  .market-detail-table-row {
    display: grid;
    align-items: center;
    gap: 6px;
    min-width: 0;
    min-height: 24px;
    margin: 0;
    border-top: 1px solid rgba(229, 231, 235, 0.86);
    padding-top: 4px;
    color: #6b7280;
    font-size: 10px;
    font-weight: 750;
  }

  .market-detail-outcome dl span {
    grid-template-columns: 1fr auto;
  }

  .market-detail-change.is-up dd,
  .market-detail-table-row strong.is-up,
  .market-detail-result-card.is-profit strong:last-child {
    color: #0f766e;
  }

  .market-detail-change.is-down dd,
  .market-detail-table-row strong.is-down,
  .market-detail-result-card.is-loss strong:last-child {
    color: #dc2626;
  }

  .market-detail-outcome dt,
  .market-detail-outcome dd {
    margin: 0;
  }

  .market-detail-outcome dd,
  .market-detail-book-row strong,
  .market-detail-book-row em,
  .market-detail-table-row strong,
  .market-detail-table-row span,
  .market-detail-user-row strong,
  .market-detail-user-row em,
  .market-detail-rules strong {
    min-width: 0;
    color: #111827;
    font-size: 10px;
    font-weight: 850;
    text-align: right;
    overflow-wrap: anywhere;
  }

  .market-detail-metric-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
  }

  .market-detail-metric-grid span {
    display: grid;
    gap: 2px;
    min-height: 38px;
    border: 1px solid #e5e7eb;
    border-radius: 7px;
    background: #f9fafb;
    padding: 5px;
  }

  .market-detail-metric-grid small {
    color: #6b7280;
    font-size: 9px;
    font-weight: 750;
  }

  .market-detail-metric-grid strong {
    color: #111827;
    font-size: 10px;
    font-weight: 850;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }

  .market-detail-metric-grid .is-green strong {
    color: #0f766e;
  }

  .market-detail-advanced {
    display: grid;
    gap: 8px;
  }

  .market-detail-advanced summary {
    cursor: pointer;
    color: #0f766e;
    font-size: 10px;
    font-weight: 850;
  }

  .market-trading-ranges--detail {
    height: 28px;
    margin: 0;
    border-radius: 8px;
  }

  .market-trading-ranges--detail button {
    border-radius: 7px;
    font-size: 11px;
  }

  .market-detail-user-grid {
    display: grid;
    gap: 8px;
  }

  .market-detail-user-grid > div {
    display: grid;
    gap: 5px;
    min-width: 0;
  }

  .market-detail-book-panel {
    display: grid;
    gap: 8px;
    min-width: 0;
  }

  .market-detail-book-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
    border: 1px solid #e5e7eb;
    border-radius: 7px;
    background: #f9fafb;
    padding: 3px;
  }

  .market-detail-book-tabs button {
    min-height: 28px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #4b5563;
    font-size: 11px;
    font-weight: 900;
  }

  .market-detail-book-tabs button.is-active {
    background: #14b8a6;
    color: #ffffff;
    box-shadow: 0 8px 18px rgba(20, 184, 166, 0.18);
  }

  .market-detail-book-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-width: 0;
  }

  .market-detail-book-title strong {
    color: #111827;
    font-size: 11px;
    font-weight: 950;
    white-space: nowrap;
  }

  .market-detail-book-title span {
    min-width: 0;
    color: #6b7280;
    font-size: 9px;
    font-weight: 750;
    text-align: right;
  }

  .market-detail-book-table {
    display: grid;
    gap: 0;
    min-width: 0;
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #ffffff;
  }

  .market-detail-book-head,
  .market-detail-book-row {
    display: grid;
    grid-template-columns: .9fr .85fr 1fr;
    align-items: center;
    gap: 6px;
    min-height: 25px;
    margin: 0;
    padding: 4px 8px;
  }

  .market-detail-book-head {
    color: #9ca3af;
    font-size: 9px;
    font-weight: 800;
  }

  .market-detail-book-row {
    border-top: 0;
    border-bottom: 1px solid #eef2f7;
    color: #6b7280;
    font-size: 10px;
    font-weight: 800;
  }

  .market-detail-book-row span,
  .market-detail-book-row strong,
  .market-detail-book-row em {
    min-width: 0;
    color: #111827;
    font-size: 10px;
    font-style: normal;
    font-weight: 900;
    text-align: right;
    overflow-wrap: anywhere;
  }

  .market-detail-book-row span,
  .market-detail-book-head span:first-child {
    text-align: left;
  }

  .market-detail-book-row--ask span {
    color: #dc2626;
  }

  .market-detail-book-row--bid span {
    color: #0f766e;
  }

  .market-detail-book-row--empty span,
  .market-detail-book-row--empty strong,
  .market-detail-book-row--empty em {
    color: #9ca3af;
  }

  .market-detail-book-asks,
  .market-detail-book-bids {
    display: grid;
  }

  .market-detail-book-asks > b,
  .market-detail-book-bids > b {
    width: fit-content;
    margin: 3px 8px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 9px;
    font-weight: 900;
    line-height: 1;
    padding: 3px 6px;
  }

  .market-detail-book-asks > b {
    background: #ef4444;
  }

  .market-detail-book-bids > b {
    background: #16a34a;
  }

  .market-detail-book-divider {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 32px;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    background: #f9fafb;
    color: #6b7280;
    font-size: 10px;
    font-style: normal;
    font-weight: 850;
    padding: 5px 8px;
  }

  .market-detail-book-divider span,
  .market-detail-book-divider em {
    min-width: 0;
    font-style: normal;
    white-space: nowrap;
  }

  .market-detail-book-divider strong {
    color: #111827;
    font-size: 11px;
    font-weight: 950;
  }

  .market-detail-book-divider strong.is-up {
    color: #0f766e;
  }

  .market-detail-book-divider strong.is-down {
    color: #dc2626;
  }

  .market-detail-tape-wrap {
    display: grid;
    gap: 5px;
  }

  .market-detail-tape {
    display: grid;
    gap: 0;
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #ffffff;
  }

  .market-detail-empty {
    display: grid;
    min-height: 30px;
    place-items: center;
    margin: 0;
    border: 1px dashed #e5e7eb;
    border-radius: 7px;
    color: #9ca3af;
    font-size: 10px;
    font-weight: 800;
  }

  .market-detail-table {
    display: grid;
    gap: 3px;
  }

  .market-detail-table-head,
  .market-detail-table-row {
    grid-template-columns: 1.15fr .8fr .9fr .9fr;
    border-top: 0;
    border-bottom: 1px solid #e5e7eb;
    padding: 4px 0;
  }

  .market-detail-table-head {
    color: #9ca3af;
    font-size: 9px;
  }

  .market-detail-table-row span:last-child {
    color: #0f766e;
  }

  .market-detail-user-row {
    grid-template-columns: .9fr .85fr 1.2fr;
  }

  .market-detail-result-card {
    display: grid;
    gap: 7px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #f9fafb;
    padding: 8px;
  }

  .market-detail-result-card header {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
  }

  .market-detail-result-card header span,
  .market-detail-result-card p {
    color: #6b7280;
    font-size: 10px;
    font-weight: 800;
  }

  .market-detail-result-card header strong {
    color: #111827;
    font-size: 12px;
    font-weight: 900;
  }

  .market-detail-result-card div {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
  }

  .market-detail-result-card div span {
    display: grid;
    gap: 2px;
    min-width: 0;
    border: 1px solid #e5e7eb;
    border-radius: 7px;
    background: #ffffff;
    padding: 5px;
  }

  .market-detail-result-card small {
    color: #6b7280;
    font-size: 8px;
    font-weight: 750;
  }

  .market-detail-result-card div strong {
    color: #111827;
    font-size: 9px;
    font-weight: 850;
    overflow-wrap: anywhere;
  }

  .market-detail-result-card p {
    margin: 0;
    line-height: 1.4;
  }

  .market-detail-user-row--order {
    grid-template-columns: .9fr .8fr .7fr auto;
  }

  .market-detail-order-card {
    display: grid;
    gap: 6px;
    min-width: 0;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #f9fafb;
    padding: 7px;
  }

  .market-detail-order-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
  }

  .market-detail-order-head span {
    display: grid;
    gap: 3px;
    min-width: 0;
  }

  .market-detail-order-head strong,
  .market-detail-order-head b {
    color: #111827;
    font-size: 10px;
    font-weight: 900;
    line-height: 1.2;
  }

  .market-detail-order-head b {
    color: #0f766e;
    white-space: nowrap;
  }

  .market-detail-order-head em {
    width: fit-content;
    border: 1px solid rgba(20, 184, 166, 0.24);
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.08);
    color: #0f766e;
    font-size: 9px;
    font-style: normal;
    font-weight: 850;
    line-height: 1;
    padding: 3px 6px;
  }

  .market-detail-order-progress {
    height: 5px;
    overflow: hidden;
    border-radius: 999px;
    background: #e5e7eb;
  }

  .market-detail-order-progress span {
    display: block;
    width: var(--market-order-progress, 0%);
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #14b8a6, #0f766e);
  }

  .market-detail-order-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
  }

  .market-detail-order-stats span {
    display: grid;
    gap: 1px;
    min-width: 0;
    border: 1px solid #e5e7eb;
    border-radius: 7px;
    background: #ffffff;
    padding: 4px;
  }

  .market-detail-order-stats small {
    color: #6b7280;
    font-size: 8px;
    font-weight: 750;
  }

  .market-detail-order-stats strong {
    color: #111827;
    font-size: 9px;
    font-weight: 850;
    white-space: nowrap;
  }

  .market-detail-order-note {
    margin: 0;
    color: #6b7280;
    font-size: 9px;
    font-weight: 750;
    line-height: 1.35;
  }

  .market-detail-user-row button {
    min-height: 22px;
    border: 1px solid #fecaca;
    border-radius: 7px;
    background: #fff1f2;
    color: #b91c1c;
    font-size: 10px;
    font-weight: 850;
    padding: 0 7px;
  }

  .market-detail-order-card button {
    min-height: 24px;
    border: 1px solid #fecaca;
    border-radius: 7px;
    background: #fff1f2;
    color: #b91c1c;
    font-size: 10px;
    font-weight: 850;
  }

  .market-detail-rules {
    display: grid;
    gap: 4px;
  }

  .market-detail-rules p {
    grid-template-columns: 70px 1fr;
  }

  .market-detail-rules span {
    color: #6b7280;
    font-size: 10px;
    font-weight: 800;
  }

  .market-detail-rule-line strong {
    text-align: left;
  }

  .trading-market-backdrop {
    align-items: flex-end;
    background: rgba(3, 7, 18, 0.58);
    padding: 18px 10px;
    z-index: 90;
  }

  .trading-modal {
    position: relative;
    width: min(100%, 360px);
    max-height: min(86vh, 620px);
    overflow: auto;
    border: 1px solid rgba(33, 59, 86, 0.9);
    border-radius: 16px;
    background:
      linear-gradient(180deg, rgba(7, 25, 40, 0.96), rgba(5, 13, 25, 0.98)),
      repeating-linear-gradient(0deg, rgba(16, 34, 53, 0.14) 0 1px, transparent 1px 9px);
    color: #e5f7ff;
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.42);
    padding: 10px;
  }

  .trading-modal .modal-close {
    position: absolute;
    top: 10px;
    right: 12px;
    color: #d8f7ff;
    border-color: rgba(148, 163, 184, 0.32);
  }

  .trading-modal-head {
    padding: 2px 38px 8px 2px;
  }

  .trading-modal-head small {
    color: #5eead4;
    font-size: 10px;
    font-weight: 800;
  }

  .trading-modal-head h2 {
    margin: 3px 0;
    font-size: 13px;
    line-height: 1.3;
  }

  .trading-modal-head span {
    display: inline-flex;
    color: #facc15;
    font-size: 10px;
    font-weight: 800;
  }

  .trading-modal-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 14px 0;
  }

  .trading-modal-summary span,
  .trading-book-grid section,
  .trading-owned-grid section {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.72);
    padding: 10px;
  }

  .trading-modal-summary small,
  .trading-book-grid h3,
  .trading-owned-grid h3,
  .trading-modal-form label,
  .trading-complete-set label {
    color: #94a3b8;
    font-size: 11px;
    font-weight: 800;
  }

  .trading-modal-summary strong {
    display: block;
    margin-top: 4px;
    color: #f8fafc;
    font-size: 15px;
  }

  .trading-mode-tabs,
  .trading-outcome-switch {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    margin-top: 0;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 12px;
    background: rgba(6, 16, 29, 0.82);
    padding: 4px;
  }

  .trading-outcome-switch {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .trading-mode-tabs button,
  .trading-outcome-switch button {
    min-height: 35px;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: #f2f7ff;
    font-size: 13px;
    font-weight: 900;
  }

  .trading-mode-tabs button.is-active,
  .trading-outcome-switch button.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 0 18px rgba(20, 184, 166, 0.18);
  }

  .trading-pane[hidden] {
    display: none !important;
  }

  .trading-modal-form,
  .trading-complete-set {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
    margin-top: 14px;
  }

  .trading-modal-form input,
  .trading-modal-form select,
  .trading-complete-set input {
    width: 100%;
    border: 0;
    background: transparent;
    color: #f8fafc;
    font: inherit;
    font-size: 25px;
    font-weight: 950;
    line-height: 1;
    padding: 0;
    outline: none;
  }

  .trading-modal-form button,
  .trading-complete-set button {
    min-height: 39px;
    border: 0;
    border-radius: 10px;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    font-weight: 900;
  }

  .trading-modal-form button {
    grid-column: 1 / -1;
  }

  .trading-modal-form--quick {
    grid-template-columns: minmax(0, 1fr);
  }

  .trading-quick-amounts,
  .trading-position-tools {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }

  .trading-position-tools {
    align-items: center;
  }

  .trading-position-tools span,
  .trading-quote-line {
    color: #cbd5e1;
    font-size: 12px;
    font-weight: 800;
  }

  .trading-quick-amounts button,
  .trading-position-tools button {
    grid-column: auto;
    min-height: 38px;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 9px;
    background: rgba(6, 16, 29, 0.86);
    color: #f2f7ff;
    font-size: 13px;
    font-weight: 900;
  }

  .trading-quick-amounts button.is-active,
  .trading-position-tools button.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
  }

  .trading-quote-line {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
    min-height: 34px;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 9px;
    background: rgba(6, 16, 29, 0.82);
    color: #45ead4;
    padding: 8px 10px;
    overflow: hidden;
  }

  .trading-quote-line small {
    color: #8595aa;
    font-size: 11px;
    white-space: nowrap;
  }

  .trading-ticket-field {
    display: grid;
    gap: 6px;
  }

  .trading-outcome-switch {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .trading-outcome-switch button {
    min-height: 38px;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 9px;
    background: rgba(6, 16, 29, 0.74);
    color: #dbeafe;
    font-weight: 850;
    padding: 5px 8px;
  }

  .trading-outcome-switch button.is-active {
    border-color: rgba(45, 212, 191, 0.72);
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
  }

  .trading-outcome-switch button:disabled {
    opacity: 0.48;
    cursor: not-allowed;
  }

  .trading-outcome-switch strong,
  .trading-outcome-switch small {
    display: block;
    line-height: 1.15;
  }

  .trading-outcome-switch strong {
    font-size: 13px;
  }

  .trading-outcome-switch small {
    margin-top: 2px;
    font-size: 9px;
    font-weight: 750;
  }

  .trading-ticket-field--compact select {
    min-height: 36px;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 8px;
    background: rgba(6, 16, 29, 0.86);
    color: #f8fafc;
    font-size: 12px;
    font-weight: 850;
    padding: 0 10px;
  }

  .trading-sell-guide {
    display: grid;
    gap: 8px;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 9px;
    background: rgba(6, 16, 29, 0.82);
    padding: 10px;
  }

  .trading-sell-guide strong {
    color: #f8fafc;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.25;
  }

  .trading-sell-guide p {
    margin: 0;
    color: #8fa0b5;
    font-size: 11px;
    font-weight: 750;
    line-height: 1.4;
  }

  .trading-sell-guide-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .trading-sell-guide-actions button {
    min-height: 34px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    font-size: 11px;
    font-weight: 850;
  }

  .trading-ticket-input-wrap,
  .trading-sell-available {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 56px;
    border: 1px solid rgba(35, 58, 86, 0.95);
    border-radius: 10px;
    background: rgba(6, 16, 29, 0.86);
    padding: 0 14px;
  }

  .trading-ticket-input-wrap em,
  .trading-sell-available span {
    color: #8fa0b5;
    font-size: 12px;
    font-style: normal;
    font-weight: 900;
  }

  .trading-ticket-input-wrap input {
    flex: 1;
    min-width: 0;
  }

  .trading-sell-available {
    min-height: 43px;
  }

  .trading-sell-available strong {
    color: #f8fafc;
    font-size: 13px;
    font-weight: 950;
  }

  .trading-ticket-submit {
    margin-top: 2px;
  }

  .trading-ticket-note {
    margin: 9px 2px 0;
    color: #74869d;
    font-size: 10px;
    font-weight: 750;
  }

  .trading-modal-form button:disabled,
  .trading-complete-set button:disabled {
    background: rgba(100, 116, 139, 0.45);
    color: #cbd5e1;
  }

  .trading-market-backdrop {
    align-items: flex-end;
    justify-content: center;
    padding: 12px;
    background: rgba(17, 24, 39, 0.18);
    backdrop-filter: blur(10px);
  }

  .trading-market-backdrop--room {
    padding: 18px 10px;
    background: rgba(3, 7, 18, 0.58);
    backdrop-filter: none;
  }

  .trading-modal {
    width: min(100%, 430px);
    max-height: min(86vh, 620px);
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #ffffff;
    color: #111827;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.16);
    padding: 14px;
  }

  .trading-modal--room {
    width: min(100%, 360px);
    border: 1px solid rgba(33, 59, 86, 0.9);
    border-radius: 16px;
    background:
      linear-gradient(180deg, rgba(7, 25, 40, 0.96), rgba(5, 13, 25, 0.98)),
      repeating-linear-gradient(0deg, rgba(16, 34, 53, 0.14) 0 1px, transparent 1px 9px);
    color: #e5f7ff;
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.42);
    padding: 10px;
  }

  .trading-modal .modal-close {
    top: 12px;
    right: 12px;
    width: 30px;
    height: 30px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #ffffff;
    color: #6b7280;
    font-size: 19px;
  }

  .trading-modal--room .modal-close {
    top: 10px;
    right: 12px;
    border-color: rgba(148, 163, 184, 0.32);
    background: #ffffff;
    color: #0f172a;
  }

  .trading-modal-head small {
    color: #6b7280;
    font-size: 11px;
    font-weight: 750;
  }

  .trading-modal-head h2 {
    color: #111827;
    font-size: 16px;
    font-weight: 760;
    line-height: 1.28;
    letter-spacing: 0;
  }

  .trading-modal-head span {
    color: #0f766e;
    font-size: 12px;
    font-weight: 800;
  }

  .trading-modal--room .trading-modal-head small {
    color: #5eead4;
  }

  .trading-modal--room .trading-modal-head h2 {
    color: #e5f7ff;
    font-size: 13px;
    font-weight: 900;
  }

  .trading-modal--room .trading-modal-head span {
    color: #facc15;
    font-size: 10px;
  }

  .trading-modal .trading-mode-tabs {
    border-color: #e5e7eb;
    border-radius: 12px;
    background: #f9fafb;
  }

  .trading-modal .trading-mode-tabs button {
    color: #374151;
    font-size: 12px;
    font-weight: 700;
  }

  .trading-modal .trading-mode-tabs button.is-active {
    background: #111827;
    color: #ffffff;
    box-shadow: none;
  }

  .trading-modal--room .trading-mode-tabs {
    border-color: rgba(35, 58, 86, 0.95);
    background: rgba(6, 16, 29, 0.82);
  }

  .trading-modal--room .trading-mode-tabs button {
    color: #f2f7ff;
    font-weight: 900;
  }

  .trading-modal--room .trading-mode-tabs button.is-active {
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 0 18px rgba(20, 184, 166, 0.18);
  }

  .trading-modal .trading-modal-form label,
  .trading-modal .trading-complete-set label {
    color: #6b7280;
    font-size: 12px;
    font-weight: 700;
  }

  .trading-modal .trading-modal-form input,
  .trading-modal .trading-modal-form select,
  .trading-modal .trading-complete-set input {
    color: #111827;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
  }

  .trading-modal--room .trading-modal-form label,
  .trading-modal--room .trading-complete-set label {
    color: #94a3b8;
    font-weight: 800;
  }

  .trading-modal--room .trading-modal-form input,
  .trading-modal--room .trading-modal-form select,
  .trading-modal--room .trading-complete-set input {
    color: #f8fafc;
    font-weight: 950;
  }

  .trading-modal .trading-ticket-input-wrap,
  .trading-modal .trading-sell-available,
  .trading-modal .trading-quote-line,
  .trading-modal .trading-quick-amounts button,
  .trading-modal .trading-position-tools button {
    border-color: #e5e7eb;
    background: #f9fafb;
  }

  .trading-modal .trading-ticket-input-wrap {
    min-height: 48px;
    padding: 0 12px;
  }

  .trading-modal .trading-sell-available {
    min-height: 42px;
    padding: 0 12px;
  }

  .trading-modal .trading-ticket-input-wrap em,
  .trading-modal .trading-sell-available span,
  .trading-modal .trading-quote-line small {
    color: #6b7280;
  }

  .trading-modal .trading-sell-available strong,
  .trading-modal .trading-quick-amounts button,
  .trading-modal .trading-position-tools button {
    color: #111827;
  }

  .trading-modal .trading-quick-amounts button,
  .trading-modal .trading-position-tools button {
    min-height: 32px;
    font-size: 12px;
    font-weight: 700;
  }

  .trading-modal .trading-quick-amounts button.is-active,
  .trading-modal .trading-position-tools button.is-active {
    border-color: #111827;
    background: #111827;
    color: #ffffff;
  }

  .trading-modal .trading-quote-line {
    min-height: 32px;
    font-size: 11px;
    color: #0f766e;
  }

  .trading-modal .trading-ticket-submit,
  .trading-modal .trading-modal-form button,
  .trading-modal .trading-complete-set button {
    min-height: 42px;
    border: 1px solid #111827;
    background: #111827;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
  }

  .trading-modal .trading-modal-form button:disabled,
  .trading-modal .trading-complete-set button:disabled {
    border-color: #e5e7eb;
    background: #e5e7eb;
    color: #9ca3af;
  }

  .trading-modal .trading-ticket-note {
    color: #6b7280;
  }

  .trading-modal--room .trading-ticket-input-wrap,
  .trading-modal--room .trading-sell-available,
  .trading-modal--room .trading-quote-line,
  .trading-modal--room .trading-quick-amounts button,
  .trading-modal--room .trading-position-tools button {
    border-color: rgba(35, 58, 86, 0.95);
    background: rgba(6, 16, 29, 0.86);
  }

  .trading-modal--room .trading-ticket-input-wrap em,
  .trading-modal--room .trading-sell-available span {
    color: #8fa0b5;
  }

  .trading-modal--room .trading-sell-available strong,
  .trading-modal--room .trading-quick-amounts button,
  .trading-modal--room .trading-position-tools button {
    color: #f2f7ff;
  }

  .trading-modal--room .trading-quick-amounts button.is-active,
  .trading-modal--room .trading-position-tools button.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
  }

  .trading-modal--room .trading-quote-line {
    color: #45ead4;
  }

  .trading-modal--room .trading-quote-line small {
    color: #8595aa;
  }

  .trading-modal--room .trading-ticket-submit,
  .trading-modal--room .trading-modal-form button,
  .trading-modal--room .trading-complete-set button {
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    font-weight: 900;
  }

  .trading-modal--room .trading-modal-form button:disabled,
  .trading-modal--room .trading-complete-set button:disabled {
    background: rgba(100, 116, 139, 0.45);
    color: #cbd5e1;
  }

  .trading-modal--room .trading-ticket-note {
    color: #74869d;
  }

  .trading-market-backdrop.trading-market-backdrop--light {
    align-items: flex-end !important;
    justify-content: center !important;
    padding: 0 12px calc(18px + env(safe-area-inset-bottom, 0px)) !important;
    background: rgba(247, 248, 250, 0.72) !important;
    backdrop-filter: blur(10px) !important;
  }

  .trading-modal.trading-modal--light {
    width: min(calc(100vw - 24px), 360px) !important;
    max-height: min(80vh, 520px) !important;
    padding: 10px !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08) !important;
  }

  .trading-modal.trading-modal--light .modal-close {
    top: 8px !important;
    right: 8px !important;
    width: 26px !important;
    height: 26px !important;
    font-size: 16px !important;
  }

  .trading-modal.trading-modal--light .trading-modal-head {
    padding: 0 32px 7px 0;
  }

  .trading-modal.trading-modal--light .trading-modal-head small {
    font-size: 10px;
    font-weight: 700;
  }

  .trading-modal.trading-modal--light .trading-modal-head h2 {
    margin: 2px 0;
    font-size: 13px;
    font-weight: 760;
    line-height: 1.28;
  }

  .trading-modal.trading-modal--light .trading-modal-head span {
    font-size: 10px;
    font-weight: 760;
  }

  .trading-modal.trading-modal--light .trading-mode-tabs {
    padding: 3px;
    border-radius: 10px;
  }

  .trading-modal.trading-modal--light .trading-mode-tabs button {
    min-height: 30px;
    border-radius: 8px;
    font-size: 11px;
  }

  .trading-modal.trading-modal--light .trading-mode-tabs button.is-active {
    background: #0f766e;
    color: #ffffff;
  }

  .trading-modal.trading-modal--light .trading-modal-form,
  .trading-modal.trading-modal--light .trading-complete-set {
    gap: 7px;
    margin-top: 9px;
  }

  .trading-modal.trading-modal--light .trading-ticket-field {
    gap: 5px;
  }

  .trading-modal.trading-modal--light .trading-outcome-switch button,
  .trading-modal.trading-modal--light .trading-ticket-field--compact select {
    border-color: #e5e7eb;
    background: #f9fafb;
    color: #111827;
  }

  .trading-modal.trading-modal--light .trading-outcome-switch button.is-active {
    border-color: #0f766e;
    background: #0f766e;
    color: #ffffff;
  }

  .trading-modal.trading-modal--light .trading-sell-guide {
    border-color: #e5e7eb;
    background: #f9fafb;
  }

  .trading-modal.trading-modal--light .trading-sell-guide strong {
    color: #111827;
  }

  .trading-modal.trading-modal--light .trading-sell-guide p {
    color: #6b7280;
  }

  .trading-modal.trading-modal--light .trading-sell-guide-actions button {
    background: #0f766e;
  }

  .trading-modal.trading-modal--light .trading-modal-form label,
  .trading-modal.trading-modal--light .trading-complete-set label {
    font-size: 11px;
  }

  .trading-modal.trading-modal--light .trading-ticket-input-wrap,
  .trading-modal.trading-modal--light .trading-sell-available {
    min-height: 42px;
    border-radius: 8px;
    padding: 0 10px;
  }

  .trading-modal.trading-modal--light .trading-modal-form input,
  .trading-modal.trading-modal--light .trading-modal-form select,
  .trading-modal.trading-modal--light .trading-complete-set input {
    font-size: 14px;
    font-weight: 740;
  }

  .trading-modal.trading-modal--light .trading-ticket-input-wrap em,
  .trading-modal.trading-modal--light .trading-sell-available span {
    font-size: 10px;
  }

  .trading-modal.trading-modal--light .trading-quick-amounts,
  .trading-modal.trading-modal--light .trading-position-tools {
    gap: 6px;
  }

  .trading-modal.trading-modal--light .trading-quick-amounts button,
  .trading-modal.trading-modal--light .trading-position-tools button {
    min-height: 30px;
    border-color: #e5e7eb;
    border-radius: 8px;
    background: #f9fafb;
    color: #111827;
    font-size: 11px;
    font-weight: 700;
  }

  .trading-modal.trading-modal--light .trading-quick-amounts button.is-active,
  .trading-modal.trading-modal--light .trading-position-tools button.is-active {
    border-color: #0f766e;
    background: #0f766e;
    color: #ffffff;
  }

  .trading-modal.trading-modal--light .trading-quote-line {
    min-height: 30px;
    border-radius: 8px;
    padding: 6px 9px;
    font-size: 10px;
  }

  .trading-modal.trading-modal--light .trading-quote-line small {
    font-size: 10px;
  }

  .trading-modal.trading-modal--light .trading-ticket-submit,
  .trading-modal.trading-modal--light .trading-modal-form > button,
  .trading-modal.trading-modal--light .trading-complete-set button {
    min-height: 36px;
    border-radius: 9px;
    border-color: #0f766e;
    background: #0f766e;
    font-size: 12px;
    font-weight: 760;
  }

  .trading-modal.trading-modal--light .trading-modal-form > button:disabled,
  .trading-modal.trading-modal--light .trading-complete-set button:disabled {
    border-color: #e5e7eb;
    background: #e5e7eb;
  }

  .trading-modal.trading-modal--light .trading-ticket-note {
    margin-top: 7px;
    font-size: 10px;
    line-height: 1.35;
  }

  .trading-market-backdrop.trading-market-backdrop--room {
    align-items: flex-end !important;
    justify-content: center !important;
    padding: 0 12px calc(18px + env(safe-area-inset-bottom, 0px)) !important;
    background: rgba(3, 7, 18, 0.58) !important;
    backdrop-filter: none !important;
  }

  .trading-modal.trading-modal--room {
    width: min(calc(100vw - 24px), 360px) !important;
    max-height: min(80vh, 520px) !important;
    padding: 10px !important;
    border: 1px solid rgba(96, 165, 250, 0.58) !important;
    border-radius: 14px !important;
    background: linear-gradient(180deg, rgba(8, 34, 48, 0.92), rgba(6, 18, 33, 0.94)) !important;
    color: #e5f6ff !important;
    box-shadow: inset 0 0 20px rgba(14, 165, 233, 0.06), 0 18px 52px rgba(0, 0, 0, 0.38) !important;
  }

  .trading-modal.trading-modal--room .modal-close {
    top: 8px !important;
    right: 8px !important;
    width: 26px !important;
    height: 26px !important;
    border-color: rgba(125, 211, 252, 0.28) !important;
    background: rgba(6, 18, 33, 0.92) !important;
    color: #e5f6ff !important;
    font-size: 16px !important;
  }

  .trading-modal.trading-modal--room .trading-modal-head {
    padding: 0 32px 7px 0;
  }

  .trading-modal.trading-modal--room .trading-modal-head small {
    color: #74f2a0;
    font-size: 10px;
    font-weight: 700;
  }

  .trading-modal.trading-modal--room .trading-modal-head h2 {
    margin: 2px 0;
    color: #e5f6ff;
    font-size: 13px;
    font-weight: 760;
    line-height: 1.28;
  }

  .trading-modal.trading-modal--room .trading-modal-head span {
    color: #5eead4;
    font-size: 10px;
    font-weight: 760;
  }

  .trading-modal.trading-modal--room .trading-mode-tabs {
    padding: 3px;
    border-color: rgba(125, 211, 252, 0.2);
    border-radius: 10px;
    background: rgba(2, 6, 23, 0.18);
  }

  .trading-modal.trading-modal--room .trading-mode-tabs button {
    min-height: 30px;
    border-radius: 8px;
    color: #d7e8f5;
    font-size: 11px;
    font-weight: 760;
  }

  .trading-modal.trading-modal--room .trading-mode-tabs button.is-active {
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    box-shadow: none;
  }

  .trading-modal.trading-modal--room .trading-modal-form,
  .trading-modal.trading-modal--room .trading-complete-set {
    gap: 7px;
    margin-top: 9px;
  }

  .trading-modal.trading-modal--room .trading-ticket-field {
    gap: 5px;
  }

  .trading-modal.trading-modal--room .trading-outcome-switch button,
  .trading-modal.trading-modal--room .trading-ticket-field--compact select {
    border-color: rgba(125, 211, 252, 0.2);
    background: rgba(2, 6, 23, 0.18);
    color: #e5f6ff;
  }

  .trading-modal.trading-modal--room .trading-outcome-switch button.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
  }

  .trading-modal.trading-modal--room .trading-sell-guide {
    border-color: rgba(125, 211, 252, 0.2);
    background: rgba(2, 6, 23, 0.18);
  }

  .trading-modal.trading-modal--room .trading-modal-form label,
  .trading-modal.trading-modal--room .trading-complete-set label {
    color: #a6bdd3;
    font-size: 11px;
    font-weight: 700;
  }

  .trading-modal.trading-modal--room .trading-ticket-input-wrap,
  .trading-modal.trading-modal--room .trading-sell-available {
    min-height: 42px;
    border-color: rgba(125, 211, 252, 0.2);
    border-radius: 8px;
    background: rgba(2, 6, 23, 0.18);
    padding: 0 10px;
  }

  .trading-modal.trading-modal--room .trading-modal-form input,
  .trading-modal.trading-modal--room .trading-modal-form select,
  .trading-modal.trading-modal--room .trading-complete-set input {
    color: #f8fbff;
    font-size: 14px;
    font-weight: 740;
  }

  .trading-modal.trading-modal--room .trading-ticket-input-wrap em,
  .trading-modal.trading-modal--room .trading-sell-available span {
    color: #a6bdd3;
    font-size: 10px;
  }

  .trading-modal.trading-modal--room .trading-quick-amounts,
  .trading-modal.trading-modal--room .trading-position-tools {
    gap: 6px;
  }

  .trading-modal.trading-modal--room .trading-quick-amounts button,
  .trading-modal.trading-modal--room .trading-position-tools button {
    min-height: 30px;
    border-color: rgba(125, 211, 252, 0.2);
    border-radius: 8px;
    background: rgba(2, 6, 23, 0.18);
    color: #e5f6ff;
    font-size: 11px;
    font-weight: 700;
  }

  .trading-modal.trading-modal--room .trading-quick-amounts button.is-active,
  .trading-modal.trading-modal--room .trading-position-tools button.is-active {
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
  }

  .trading-modal.trading-modal--room .trading-quote-line {
    min-height: 30px;
    border-color: rgba(125, 211, 252, 0.2);
    border-radius: 8px;
    background: rgba(2, 6, 23, 0.18);
    color: #74f2a0;
    padding: 6px 9px;
    font-size: 10px;
  }

  .trading-modal.trading-modal--room .trading-quote-line small {
    color: #a6bdd3;
    font-size: 10px;
  }

  .trading-modal.trading-modal--room .trading-ticket-submit,
  .trading-modal.trading-modal--room .trading-modal-form > button,
  .trading-modal.trading-modal--room .trading-complete-set button {
    min-height: 36px;
    border-radius: 9px;
    border-color: transparent;
    background: linear-gradient(135deg, #42e7d0, #19c0aa);
    color: #ffffff;
    font-size: 12px;
    font-weight: 760;
  }

  .trading-modal.trading-modal--room .trading-modal-form > button:disabled,
  .trading-modal.trading-modal--room .trading-complete-set button:disabled {
    border-color: rgba(100, 116, 139, 0.2);
    background: rgba(100, 116, 139, 0.36);
    color: #cbd5e1;
  }

  .trading-modal.trading-modal--room .trading-ticket-note {
    margin-top: 7px;
    color: #a6bdd3;
    font-size: 10px;
    line-height: 1.35;
  }

  .trading-book-grid,
  .trading-owned-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
    margin-top: 12px;
  }

  .trading-book-grid h3,
  .trading-owned-grid h3 {
    margin: 0 0 8px;
    color: #cbd5e1;
  }

  .trading-book-grid section > span,
  .trading-position-row,
  .trading-order-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 27px;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    padding-top: 6px;
    margin-top: 6px;
    font-size: 12px;
  }

  .trading-book-grid em {
    color: #5eead4;
    font-style: normal;
    font-weight: 900;
  }

  .trading-book-grid strong,
  .trading-position-row strong,
  .trading-order-row strong {
    color: #f8fafc;
  }

  .trading-position-row,
  .trading-order-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .trading-position-row small {
    color: #94a3b8;
  }

  .trading-order-row button {
    align-self: stretch;
    border: 1px solid rgba(248, 113, 113, 0.42);
    border-radius: 8px;
    background: rgba(127, 29, 29, 0.18);
    color: #fecaca;
    font-weight: 800;
    padding: 6px 8px;
  }

  .trading-order-row-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
  }

  .trading-order-row-head span {
    display: grid;
    gap: 4px;
    min-width: 0;
  }

  .trading-order-row-head b {
    color: #5eead4;
    font-size: 11px;
    font-weight: 900;
    line-height: 1.2;
    white-space: nowrap;
  }

  .trading-order-row-head em {
    width: fit-content;
    border: 1px solid rgba(94, 234, 212, 0.24);
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.12);
    color: #5eead4;
    font-size: 9px;
    font-style: normal;
    font-weight: 850;
    line-height: 1;
    padding: 3px 6px;
  }

  .trading-order-progress {
    width: 100%;
    height: 5px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.18);
  }

  .trading-order-progress span {
    display: block;
    width: var(--trading-order-progress, 0%);
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #5eead4, #14b8a6);
  }

  .trading-order-qty-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
    width: 100%;
  }

  .trading-order-qty-grid span {
    display: grid;
    gap: 2px;
    min-width: 0;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 7px;
    background: rgba(15, 23, 42, 0.28);
    padding: 5px;
  }

  .trading-order-qty-grid small {
    color: #94a3b8;
    font-size: 9px;
    font-weight: 750;
  }

  .trading-order-qty-grid strong {
    color: #f8fafc;
    font-size: 10px;
    font-weight: 850;
    white-space: nowrap;
  }

  .trading-order-note {
    margin: 0;
    color: #94a3b8;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.35;
  }

  .trading-modal.trading-modal--light .trading-order-row {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #f9fafb;
    padding: 7px;
  }

  .trading-modal.trading-modal--light .trading-order-row-head strong,
  .trading-modal.trading-modal--light .trading-order-qty-grid strong {
    color: #111827;
  }

  .trading-modal.trading-modal--light .trading-order-row-head b {
    color: #0f766e;
  }

  .trading-modal.trading-modal--light .trading-order-row-head em {
    border-color: rgba(20, 184, 166, 0.24);
    background: rgba(20, 184, 166, 0.08);
    color: #0f766e;
  }

  .trading-modal.trading-modal--light .trading-order-progress {
    background: #e5e7eb;
  }

  .trading-modal.trading-modal--light .trading-order-qty-grid span {
    border-color: #e5e7eb;
    background: #ffffff;
  }

  .trading-modal.trading-modal--light .trading-order-qty-grid small,
  .trading-modal.trading-modal--light .trading-order-note {
    color: #6b7280;
  }

  .trading-empty {
    color: #64748b;
    font-size: 12px;
    margin: 0;
  }

  .pm-cover-time {
    grid-column: 2;
    justify-self: start;
    min-width: 0;
    margin-top: -2px;
    text-align: left;
  }

  .pm-cover-time em {
    display: inline-flex;
    max-width: 100%;
    color: #079488;
    font-size: 12px;
    font-style: normal;
    font-weight: 900;
    white-space: normal;
  }

  .pm-cover-category {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    padding: 0 9px;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    color: var(--ink);
    background: rgba(255, 255, 255, 0.82);
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
  }

  .pm-lead {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 4px;
  }

  .pm-lead-pct {
    font-size: 32px;
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1;
    color: var(--ink);
  }

  .pm-lead--binary .pm-lead-pct {
    color: var(--teal);
  }

  .pm-lead--meter .pm-lead-pct {
    color: var(--amber);
  }

  .pm-lead-note {
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    line-height: 1.35;
  }

  .pm-rule-summary {
    display: -webkit-box;
    margin: 4px 0 8px 62px;
    overflow: hidden;
    color: var(--ink-2);
    font-size: 13px;
    font-weight: 750;
    line-height: 1.45;
    text-align: left;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .pm-odds-pair {
    gap: 8px;
    margin-left: 62px;
  }

  .pm-odds-pair button:first-child {
    border-color: rgba(33, 203, 189, 0.5);
    background: rgba(33, 203, 189, 0.1);
  }

  .pm-odds-pair button:last-child {
    border-color: rgba(245, 158, 11, 0.48);
    background: var(--amber-soft);
  }

  .pm-odds-pair button strong {
    font-size: 18px;
  }

  .pm-topic-meter {
    margin-top: 2px;
  }

  .mic-seat-panel {
    margin: 4px 0 0 62px;
    padding: 9px 10px 8px;
    border: 1px solid var(--aqua-line);
    border-radius: 10px;
    background: rgba(33, 203, 189, 0.08);
  }

  .mic-seat-line {
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.4;
    color: var(--ink-2);
  }

  .mic-seat-panel .room-seat-strip {
    margin-bottom: 0;
  }

  .mobile-topic-top {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr) auto;
    gap: 8px;
    align-items: start;
  }

  .mobile-topic .topic-node {
    margin-top: 8px;
  }

  .mobile-topic .topic-node::after {
    height: 68px;
  }

  .mobile-topic h3 {
    font-size: 17px;
  }

  .mobile-topic em {
    color: var(--teal);
    font-size: 13px;
    font-style: normal;
    font-weight: 900;
  }

  .mobile-topic p,
  .mobile-topic-desc {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.48;
  }

  .mobile-topic-desc {
    color: var(--ink-2);
  }

  .mobile-topic-engage {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.58);
  }

  .mobile-topic-engage-item {
    padding: 10px 8px;
    border: 1px solid var(--line);
    text-align: center;
    font-size: 12px;
    color: var(--muted);
    font-weight: 800;
    line-height: 1.35;
  }

  .mobile-topic-engage-item strong {
    display: block;
    margin-bottom: 4px;
    color: var(--ink);
    font-size: 20px;
    font-weight: 900;
  }

  .mobile-odds {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .mobile-odds button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 44px;
    padding: 0 11px;
    border: 1px solid var(--line-strong);
    border-radius: 0;
    background: rgba(33, 203, 189, 0.1);
  }

  .mobile-odds button:last-child {
    background: var(--amber-soft);
  }

  .mobile-odds span {
    color: var(--muted);
    font-weight: 900;
  }

  .mobile-odds strong {
    font-size: 20px;
  }

  .mobile-room-line {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }

  .mobile-room-line span {
    padding: 7px;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    text-align: center;
  }

  .mobile-topic-actions {
    display: grid;
    gap: 8px;
    margin-left: 62px;
  }

  .mobile-topic-actions--pair {
    grid-template-columns: 1fr 1fr;
  }

  .mobile-topic-actions--triple {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .mobile-topic-actions--quad {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .mobile-enter {
    min-height: 44px;
    border: 1px solid var(--ink);
    background: var(--ink);
    color: white;
    font-weight: 900;
  }

  .mobile-enter.secondary {
    background: rgba(255, 255, 255, 0.58);
    color: var(--ink);
  }

  .mobile-enter.tertiary {
    border: 1px solid rgba(20, 184, 166, 0.45);
    background: var(--teal-soft);
    color: var(--ink);
    font-size: 13px;
  }

  .mobile-enter.danger {
    border-color: rgba(244, 63, 94, 0.38);
    background: rgba(244, 63, 94, 0.1);
    color: #be123c;
    font-size: 13px;
  }

  .mobile-bottom-nav {
    position: static;
    z-index: 20;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    margin-top: 14px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.94);
    backdrop-filter: blur(18px);
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.12);
  }

  .mobile-bottom-nav button {
    position: relative;
    display: grid;
    place-items: center;
    gap: 3px;
    min-height: 56px;
    border: 0;
    border-right: 1px solid var(--line);
    background: transparent;
  }

  .mobile-bottom-nav button:last-child {
    border-right: 0;
  }

  .mobile-bottom-nav .active {
    background: var(--teal-soft);
  }

  .mobile-bottom-nav small {
    color: var(--muted);
    font-size: 10px;
    font-weight: 900;
  }

  .modal-backdrop {
    position: fixed;
    z-index: 40;
    inset: 0;
    display: grid;
    place-items: end center;
    padding: 14px;
    background: rgba(17, 24, 39, 0.36);
  }

  .modal-backdrop[hidden] {
    display: none;
  }

  .auth-modal {
    position: relative;
    width: min(100%, 420px);
    padding: 22px 18px 18px;
    border: 1px solid var(--line);
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.1), transparent 56%),
      var(--bg);
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.24);
  }

  .modal-close,
  .modal-back {
    position: absolute;
    top: 12px;
    height: 34px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.62);
    color: var(--ink);
  }

  .modal-close {
    right: 12px;
    width: 34px;
    font-size: 22px;
    line-height: 1;
  }

  .modal-back {
    left: 12px;
    padding: 0 10px;
    font-size: 13px;
    font-weight: 900;
  }

  .modal-close[hidden],
  .modal-back[hidden] {
    display: none;
  }

  .auth-modal h2 {
    margin: 4px 44px 8px 0;
    line-height: 1.14;
  }

  .auth-modal p[data-modal-desc] {
    margin-bottom: 16px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.5;
  }

  .generated-user {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    padding: 10px;
    border: 1px solid rgba(20, 184, 166, 0.38);
    background: var(--teal-soft);
  }

  .generated-user[hidden] {
    display: none;
  }

  .generated-user strong {
    display: block;
    font-size: 14px;
  }

  .generated-user small {
    color: var(--muted);
    font-size: 11px;
  }

  .modal-field {
    display: grid;
    gap: 7px;
    margin-bottom: 14px;
  }

  .auth-modal > .modal-field,
  .auth-modal > .verify-row,
  .auth-modal > .modal-submit {
    margin-top: 0;
  }

  .modal-field span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
  }

  .modal-field input {
    width: 100%;
    height: 48px;
    box-sizing: border-box;
    padding: 0 12px;
    border: 1px solid var(--line-strong);
    background: rgba(255, 255, 255, 0.7);
    color: var(--ink);
    font-weight: 800;
  }

  .modal-submit {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--ink);
    background: var(--ink);
    color: white;
    font-weight: 900;
  }

  .verify-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 124px;
    gap: 10px;
    align-items: end;
    margin-bottom: 14px;
  }

  .verify-row .modal-field {
    margin-bottom: 0;
  }

  .verify-row[hidden] {
    display: none;
  }

  .verify-row button,
  .modal-later,
  .modal-link {
    min-height: 48px;
    border: 1px solid var(--line-strong);
    background: rgba(255, 255, 255, 0.65);
    color: var(--ink);
    font-weight: 900;
  }

  .verify-row button {
    width: 100%;
    white-space: nowrap;
  }

  .modal-later,
  .modal-link {
    width: 100%;
    margin-top: 8px;
  }

  .modal-link {
    border-color: transparent;
    background: transparent;
    color: var(--teal);
  }

  .modal-later[hidden],
  .modal-link[hidden] {
    display: none;
  }

  .toast {
    position: fixed;
    z-index: 160;
    left: 50%;
    bottom: 22px;
    transform: translateX(-50%);
    max-width: calc(100% - 28px);
    padding: 11px 14px;
    border: 1px solid rgba(20, 184, 166, 0.42);
    background: var(--ink);
    color: white;
    font-size: 13px;
    font-weight: 900;
    box-shadow: 0 12px 36px rgba(15, 23, 42, 0.2);
  }

  .toast[hidden] {
    display: none;
  }
}

@media (min-width: 0px) {
  .verify-row button {
    min-height: 44px;
  }

  .mobile-page[hidden] {
    display: none !important;
  }

  .mobile-page-messages {
    min-height: calc(100vh - 130px);
  }

  .mobile-page-wallet {
    min-height: calc(100vh - 130px);
  }

  .mobile-page-profile {
    min-height: calc(100vh - 130px);
  }

  .profile-identity-card {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--line);
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.14), transparent 58%),
      rgba(255, 255, 255, 0.78);
    box-shadow: var(--shadow);
  }

  .profile-avatar {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    border: 1px solid rgba(20, 184, 166, 0.42);
    border-radius: 50%;
    background: var(--ink);
    color: white;
    font-size: 17px;
    font-weight: 950;
  }

  .profile-identity-main {
    min-width: 0;
  }

  .profile-identity-main span {
    display: inline-flex;
    margin-bottom: 4px;
    padding: 2px 7px;
    border: 1px solid rgba(20, 184, 166, 0.36);
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 900;
  }

  .profile-identity-main h2,
  .profile-identity-main p {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .profile-identity-main h2 {
    margin: 0 0 4px;
    font-size: 21px;
    line-height: 1.05;
  }

  .profile-identity-main p {
    margin: 0;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
  }

  .profile-identity-card > button,
  .profile-panel-head button,
  .profile-list-item button {
    border: 1px solid rgba(20, 184, 166, 0.38);
    background: var(--teal-soft);
    color: var(--ink);
    font-weight: 900;
  }

  .profile-identity-card > button {
    min-height: 34px;
    padding: 0 10px;
    white-space: nowrap;
  }

  .profile-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    margin-top: 12px;
    border: 1px solid var(--line);
    background: rgba(17, 24, 39, 0.1);
    overflow: hidden;
  }

  .profile-stats span {
    min-width: 0;
    padding: 10px 5px;
    background: rgba(255, 255, 255, 0.82);
    color: var(--muted);
    font-size: 10px;
    font-weight: 900;
    text-align: center;
  }

  .profile-stats strong {
    display: block;
    overflow: hidden;
    margin-bottom: 4px;
    color: var(--ink);
    font-size: 17px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .profile-panel {
    margin-top: 12px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  }

  .profile-panel[hidden] {
    display: none;
  }

  .profile-panel-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
  }

  .profile-panel-head h3 {
    margin: 0;
    font-size: 18px;
  }

  .profile-panel-head button {
    min-height: 34px;
    padding: 0 10px;
    white-space: nowrap;
  }

  .profile-switch {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-top: 12px;
  }

  .profile-switch button {
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
  }

  .profile-switch button.active {
    border-color: rgba(20, 184, 166, 0.48);
    background: var(--teal-soft);
    color: var(--ink);
  }

  .profile-list,
  .profile-setting-list {
    display: grid;
    gap: 8px;
  }

  .profile-list-item {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.84);
  }

  .profile-list-item > span {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    border-radius: 50%;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 900;
  }

  .profile-list-item div {
    min-width: 0;
  }

  .profile-list-item strong,
  .profile-list-item small,
  .profile-list-item em {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .profile-list-item strong {
    color: var(--ink);
    font-size: 13px;
  }

  .profile-list-item small {
    margin-top: 3px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
  }

  .profile-list-item em {
    margin-top: 3px;
    color: var(--teal);
    font-size: 11px;
    font-style: normal;
    font-weight: 900;
  }

  .profile-list-item button {
    min-height: 32px;
    padding: 0 9px;
    font-size: 11px;
    white-space: nowrap;
  }

  .profile-music-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
  }

  .profile-music-actions button:disabled {
    opacity: 0.45;
  }

  .profile-setting-list button {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    min-height: 48px;
    padding: 0 12px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.84);
    color: var(--ink);
    font-weight: 900;
    text-align: left;
  }

  .profile-setting-list strong {
    color: var(--muted);
    font-size: 12px;
    white-space: nowrap;
  }

  .profile-agent-panel {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .agent-stack {
    display: grid;
    gap: 12px;
  }

  .agent-hero,
  .agent-level-card,
  .agent-rule-card,
  .agent-section {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.8);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  }

  .agent-hero {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
    padding: 14px;
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.16), transparent 58%),
      rgba(255, 255, 255, 0.82);
  }

  .agent-hero h3 {
    margin: 0;
    color: var(--ink);
    font-size: 22px;
    line-height: 1.05;
  }

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

  .agent-hero span,
  .agent-level-card p,
  .agent-rule-card span,
  .agent-section-head span,
  .agent-team-grid small,
  .agent-record small,
  .agent-record em {
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
  }

  .agent-hero button,
  .agent-section-head button {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 0 10px;
    border: 1px solid rgba(20, 184, 166, 0.38);
    background: var(--teal-soft);
    color: var(--ink);
    font-size: 11px;
    font-weight: 950;
    white-space: nowrap;
  }

  .agent-hero-actions {
    display: grid;
    gap: 6px;
    justify-content: flex-end;
    justify-items: end;
    max-width: min(58%, 320px);
  }

  .agent-hero-action-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
  }

  .agent-summary-toggle {
    min-height: 30px;
    padding: 0 11px;
    border-color: rgba(15, 23, 42, 0.12) !important;
    background: rgba(255, 255, 255, 0.72) !important;
    color: var(--muted) !important;
  }

  .agent-summary-toggle::after {
    content: "⌃";
    display: inline-block;
    margin-left: 5px;
    color: var(--teal);
    font-size: 12px;
  }

  .is-agent-summary-collapsed .agent-summary-toggle::after {
    content: "⌄";
  }

  .agent-summary-detail {
    display: grid;
    gap: 12px;
  }

  .agent-level-card,
  .agent-rule-card,
  .agent-section {
    padding: 12px;
  }

  .agent-level-top,
  .agent-section-head,
  .agent-record {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
  }

  .agent-level-top strong,
  .agent-section-head h4,
  .agent-rule-card strong,
  .agent-record strong,
  .agent-team-grid strong {
    color: var(--ink);
    font-weight: 950;
  }

  .agent-level-top span {
    color: var(--teal);
    font-size: 13px;
    font-weight: 950;
  }

  .agent-level-bar {
    height: 8px;
    margin-top: 10px;
    border: 1px solid rgba(20, 184, 166, 0.24);
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.08);
    overflow: hidden;
  }

  .agent-level-bar i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--teal), var(--amber));
  }

  .agent-level-card p {
    margin: 8px 0 0;
    line-height: 1.45;
  }

  .agent-metrics {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .agent-metrics span {
    min-width: 0;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.82);
    color: var(--muted);
    font-size: 11px;
    font-weight: 900;
  }

  .agent-metrics strong {
    display: block;
    overflow: hidden;
    margin-bottom: 5px;
    color: var(--ink);
    font-size: 18px;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .agent-metrics em {
    display: block;
    margin-top: 3px;
    color: var(--teal);
    font-style: normal;
  }

  .agent-rule-card {
    display: grid;
    gap: 12px;
  }

  .confirm-modal.agent-rule-modal {
    box-sizing: border-box;
    width: min(calc(100vw - 40px), 380px);
    max-width: 380px;
    max-height: min(86vh, 760px);
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    display: grid;
    gap: 10px;
    padding-bottom: 16px;
    color: var(--ink);
    font-size: 13px;
    line-height: 1.55;
    text-align: left;
  }

  .confirm-modal.agent-rule-modal h3 {
    margin: 0 38px 2px 0;
    color: var(--ink);
    font-size: 18px;
    line-height: 1.25;
    font-weight: 950;
  }

  .confirm-modal.agent-rule-modal p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.55;
    font-weight: 750;
  }

  .confirm-modal.agent-rule-modal .agent-rule-card {
    min-width: 0;
    gap: 8px;
    padding: 10px;
    border-radius: 8px;
    box-shadow: none;
  }

  .confirm-modal.agent-rule-modal .agent-rule-card strong,
  .confirm-modal.agent-rule-modal .agent-team-grid strong {
    color: var(--ink);
    font-size: 13px;
    line-height: 1.35;
    font-weight: 950;
  }

  .confirm-modal.agent-rule-modal .agent-rule-card span,
  .confirm-modal.agent-rule-modal .agent-team-grid small,
  .confirm-modal.agent-rule-modal .agent-team-grid em,
  .confirm-modal.agent-rule-modal .agent-rule-levels span {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
    font-weight: 750;
  }

  .confirm-modal.agent-rule-modal .agent-bucket-row span {
    min-width: 0;
    display: block;
    padding: 8px 5px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.35;
    font-weight: 800;
  }

  .confirm-modal.agent-rule-modal .agent-bucket-row b {
    margin-bottom: 2px;
    color: var(--teal);
    font-size: 14px;
    line-height: 1.2;
    font-weight: 950;
  }

  .confirm-modal.agent-rule-modal .agent-team-grid {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .confirm-modal.agent-rule-modal .agent-team-grid article {
    min-width: 0;
    display: grid;
    gap: 3px;
    padding: 9px;
  }

  .confirm-modal.agent-rule-modal .agent-team-grid article > span {
    width: fit-content;
    min-width: 0;
    height: auto;
    margin: 0;
    padding: 3px 8px;
    font-size: 11px;
    line-height: 1.2;
  }

  .confirm-modal.agent-rule-modal .agent-rule-levels {
    gap: 6px;
  }

  .confirm-modal.agent-rule-modal .agent-rule-levels span {
    min-width: 0;
    padding: 8px;
  }

  .confirm-modal.agent-rule-modal .agent-rule-levels b {
    margin-bottom: 2px;
    color: var(--ink);
    font-size: 12px;
    line-height: 1.25;
    font-weight: 950;
  }

  .confirm-modal.agent-rule-modal .confirm-actions {
    position: sticky;
    bottom: -16px;
    z-index: 1;
    display: flex;
    justify-content: center;
    margin: 10px -2px 0;
    padding: 10px 2px 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), var(--bg) 34%);
  }

  .confirm-modal.agent-rule-modal .confirm-actions button {
    min-width: 150px;
    min-height: 42px;
    padding: 0 22px;
    border: 1px solid rgba(20, 184, 166, 0.42);
    border-radius: 999px;
    background: var(--teal);
    color: #fff;
    font-size: 14px;
    font-weight: 950;
    box-shadow: 0 12px 26px rgba(20, 184, 166, 0.24);
  }

  .agent-rule-card div:first-child {
    display: grid;
    gap: 5px;
  }

  .agent-bucket-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    border: 1px solid rgba(17, 24, 39, 0.12);
    background: rgba(17, 24, 39, 0.1);
    overflow: hidden;
  }

  .agent-bucket-row span {
    min-width: 0;
    padding: 9px 6px;
    background: rgba(248, 250, 252, 0.86);
    text-align: center;
  }

  .agent-bucket-row b {
    display: block;
    color: var(--teal);
    font-size: 16px;
  }

  .agent-rule-levels {
    display: grid;
    gap: 6px;
  }

  .agent-rule-levels span {
    display: grid;
    gap: 2px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(248, 250, 252, 0.82);
  }

  .agent-rule-levels b {
    color: var(--ink);
    font-size: 12px;
  }

  .agent-section-head {
    margin-bottom: 10px;
    align-items: baseline;
  }

  .agent-section-head h4 {
    margin: 0;
    font-size: 16px;
  }

  .agent-team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .agent-team-grid article {
    min-width: 0;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(248, 250, 252, 0.82);
  }

  .agent-team-grid article > span {
    display: inline-grid;
    place-items: center;
    min-width: 30px;
    height: 24px;
    margin-bottom: 8px;
    border: 1px solid rgba(20, 184, 166, 0.32);
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 950;
  }

  .agent-team-grid strong,
  .agent-team-grid small,
  .agent-team-grid em {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .agent-team-grid strong {
    font-size: 12px;
  }

  .agent-team-grid em {
    margin-top: 5px;
    color: var(--teal);
    font-size: 12px;
    font-style: normal;
    font-weight: 950;
  }

  .agent-record-list {
    display: grid;
    gap: 8px;
  }

  .agent-record {
    min-height: 58px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(248, 250, 252, 0.82);
  }

  .agent-record div {
    min-width: 0;
  }

  .agent-record strong,
  .agent-record small,
  .agent-record em {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .agent-record b {
    flex: 0 0 auto;
    color: var(--ink);
    font-size: 13px;
    font-style: normal;
    font-weight: 950;
    white-space: nowrap;
  }

  .agent-record {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
  }

  .agent-record > span {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    border-radius: 50%;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 950;
  }

  .messages-head,
  .wallet-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 14px 14px;
    border: 1px solid var(--line);
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.12), transparent 62%),
      rgba(255, 255, 255, 0.7);
    box-shadow: var(--shadow);
  }

  .messages-head h2,
  .wallet-head h2 {
    font-size: 24px;
    line-height: 1.05;
  }

  .messages-head button,
  .message-tabs button,
  .message-card-side button {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.72);
    color: var(--ink);
    font-weight: 900;
  }

  .messages-head button {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 0 10px;
    color: var(--teal);
  }

  .wallet-rule {
    flex: 0 0 auto;
    padding: 8px 10px;
    border: 1px solid rgba(20, 184, 166, 0.42);
    background: var(--teal-soft);
    color: var(--ink);
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
  }

  .wallet-balance-card {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    margin-top: 12px;
    border: 1px solid rgba(17, 24, 39, 0.14);
    background: rgba(17, 24, 39, 0.12);
    box-shadow: var(--shadow);
    overflow: hidden;
  }

  .wallet-balance-card > div {
    min-width: 0;
    padding: 16px 14px;
    background:
      linear-gradient(135deg, rgba(20, 184, 166, 0.12), transparent 62%),
      rgba(255, 255, 255, 0.84);
  }

  .wallet-balance-card > div:last-child {
    grid-column: 1 / -1;
  }

  .wallet-balance-card span {
    display: block;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
  }

  .wallet-balance-card strong {
    display: block;
    overflow: hidden;
    color: var(--ink);
    font-size: clamp(20px, 6vw, 26px);
    font-weight: 950;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .wallet-mode-tabs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 12px;
  }

  .wallet-mode-tabs button {
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
  }

  .wallet-mode-tabs button.active {
    border-color: rgba(20, 184, 166, 0.48);
    background: var(--teal-soft);
    color: var(--ink);
  }

  .wallet-panel {
    display: grid;
    gap: 12px;
    margin-top: 12px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
  }

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

  [data-wallet-deposit-help][hidden] {
    display: none;
  }

  [data-wallet-deposit-dev][hidden] {
    display: none;
  }

  .wallet-panel-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: baseline;
  }

  .wallet-panel-head h3 {
    margin: 0;
    font-size: 17px;
  }

  .wallet-panel-head span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 900;
    text-align: right;
  }

  .wallet-field {
    display: grid;
    gap: 7px;
  }

  .wallet-field-grid {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 10px;
  }

  .wallet-withdraw-address-book {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: end;
  }

  .wallet-withdraw-address-book button {
    height: 46px;
    padding: 0 14px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    border-radius: 12px;
    background: var(--teal-soft);
    color: var(--teal);
    font-weight: 950;
  }

  .wallet-withdraw-address-preview {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 12px;
    border: 1px solid rgba(20, 184, 166, 0.28);
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(236, 254, 255, 0.72), rgba(248, 250, 252, 0.92));
  }

  .wallet-withdraw-address-preview div {
    min-width: 0;
    display: grid;
    gap: 5px;
  }

  .wallet-withdraw-address-preview span,
  .wallet-withdraw-address-preview em {
    color: var(--muted);
    font-size: 11px;
    font-style: normal;
    font-weight: 850;
  }

  .wallet-withdraw-address-preview strong {
    min-width: 0;
    color: var(--ink);
    font-size: 13px;
    line-height: 1.35;
    font-weight: 950;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .wallet-withdraw-address-preview button {
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal);
    font-weight: 950;
  }

  .wallet-withdraw-address-preview button:disabled {
    opacity: 0.5;
  }

  .wallet-field span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
  }

  .wallet-field input,
  .wallet-field select {
    width: 100%;
    height: 46px;
    padding: 0 12px;
    border: 1px solid var(--line-strong);
    background: rgba(248, 250, 252, 0.82);
    color: var(--ink);
    font-weight: 900;
  }

  .wallet-flow-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  .wallet-flow-steps span {
    min-width: 0;
    padding: 8px 6px;
    border: 1px solid rgba(20, 184, 166, 0.28);
    background: rgba(20, 184, 166, 0.08);
    color: var(--ink);
    font-size: 11px;
    font-weight: 900;
    text-align: center;
  }

  .wallet-quick-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
  }

  .wallet-quick-row button,
  .wallet-address-box button,
  .wallet-withdraw-summary button,
  .wallet-deposit-actions button:not(.wallet-primary) {
    min-height: 34px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    background: var(--teal-soft);
    color: var(--teal);
    font-weight: 950;
  }

  .wallet-address-box,
  .wallet-deposit-order,
  .wallet-withdraw-summary,
  .wallet-risk-note {
    display: grid;
    gap: 7px;
    padding: 12px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.8);
  }

  .wallet-address-box {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }

  .wallet-address-box span,
  .wallet-withdraw-summary span,
  .wallet-risk-note {
    color: var(--muted);
    font-size: 12px;
    font-weight: 850;
  }

  .wallet-address-box span {
    grid-column: 1 / -1;
  }

  .wallet-address-box strong,
  .wallet-withdraw-summary strong {
    min-width: 0;
    overflow: hidden;
    color: var(--ink);
    font-size: 14px;
    font-weight: 950;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .wallet-deposit-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .wallet-deposit-meta span {
    display: grid;
    gap: 3px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
  }

  .wallet-deposit-meta strong {
    min-width: 0;
    overflow: hidden;
    color: var(--ink);
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .wallet-qr-wrap {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
  }

  .wallet-qr {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    gap: 2px;
    width: 96px;
    height: 96px;
    padding: 8px;
    border: 1px solid var(--line-strong);
    background: white;
  }

  .wallet-qr i {
    display: block;
    background: rgba(15, 23, 42, 0.12);
  }

  .wallet-qr i.on {
    background: var(--ink);
  }

  .wallet-qr-wrap strong,
  .wallet-qr-wrap small {
    display: block;
  }

  .wallet-qr-wrap strong {
    overflow: hidden;
    color: var(--ink);
    font-size: 14px;
    font-weight: 950;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .wallet-qr-wrap small {
    margin-top: 5px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
    line-height: 1.35;
  }

  .wallet-deposit-actions {
    display: grid;
    grid-template-columns: 1fr 0.72fr 0.92fr;
    gap: 8px;
  }

  .wallet-deposit-actions button {
    min-width: 0;
    padding: 8px 6px;
    font-size: 11px;
    line-height: 1.2;
    white-space: normal;
  }

  .wallet-deposit-overlay {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.42);
    backdrop-filter: blur(12px);
  }

  .wallet-deposit-overlay[hidden] {
    display: none;
  }

  .wallet-deposit-progress {
    display: grid;
    gap: 14px;
    width: min(360px, 100%);
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.52);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
  }

  .wallet-deposit-progress h3 {
    margin: 0;
    color: var(--ink);
    font-size: 20px;
    line-height: 1.15;
  }

  .wallet-deposit-progress-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
  }

  .wallet-deposit-progress-steps span {
    display: grid;
    place-items: center;
    min-height: 38px;
    padding: 6px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.86);
    color: var(--muted);
    font-size: 11px;
    font-weight: 950;
    text-align: center;
  }

  .wallet-deposit-progress-steps span.active {
    border-color: rgba(20, 184, 166, 0.56);
    background: var(--teal-soft);
    color: var(--ink);
  }

  .wallet-deposit-progress-steps span.done {
    border-color: rgba(16, 185, 129, 0.46);
    background: rgba(16, 185, 129, 0.12);
    color: #047857;
  }

  .wallet-deposit-progress-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .wallet-deposit-progress-meta span {
    display: grid;
    gap: 4px;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.82);
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
  }

  .wallet-deposit-progress-meta strong {
    min-width: 0;
    overflow: hidden;
    color: var(--ink);
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .wallet-deposit-progress p:last-child {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 850;
    line-height: 1.45;
  }

  .wallet-withdraw-summary {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }

  .wallet-withdraw-summary span {
    grid-column: 1 / -1;
  }

  .wallet-convert-box {
    display: grid;
    gap: 5px;
    padding: 12px;
    border: 1px solid rgba(20, 184, 166, 0.32);
    background: var(--teal-soft);
  }

  .wallet-convert-box span,
  .wallet-convert-box small {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
  }

  .wallet-convert-box strong {
    color: var(--ink);
    font-size: 24px;
    line-height: 1;
  }

  .wallet-exchange-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  .wallet-exchange-grid button {
    display: grid;
    gap: 5px;
    min-height: 74px;
    align-content: center;
    padding: 10px 8px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.82);
    color: var(--ink);
    text-align: center;
  }

  .wallet-exchange-grid button.active {
    border-color: rgba(20, 184, 166, 0.48);
    background: var(--teal-soft);
  }

  .wallet-exchange-grid button:disabled {
    opacity: 0.48;
  }

  .wallet-exchange-grid strong {
    font-size: 14px;
    line-height: 1;
  }

  .wallet-exchange-grid span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 900;
  }

  .wallet-primary {
    min-height: 48px;
    border: 1px solid var(--ink);
    background: var(--ink);
    color: white;
    font-weight: 900;
  }

  .wallet-primary:disabled {
    border-color: rgba(148, 163, 184, 0.48);
    background: rgba(148, 163, 184, 0.42);
    color: rgba(255, 255, 255, 0.92);
  }

  .wallet-fee-grid {
    display: grid;
    gap: 8px;
  }

  .wallet-fee-grid span {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    min-height: 42px;
    align-items: center;
    padding: 0 12px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.78);
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
  }

  .wallet-fee-grid strong {
    color: var(--ink);
    font-size: 15px;
    white-space: nowrap;
  }

  .wallet-record-list {
    display: grid;
    gap: 8px;
  }

  .wallet-record {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    min-height: 62px;
    padding: 10px;
    border: 1px solid var(--line);
    background: rgba(248, 250, 252, 0.82);
  }

  .wallet-record > span {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(20, 184, 166, 0.34);
    border-radius: 50%;
    background: var(--teal-soft);
    color: var(--teal);
    font-size: 11px;
    font-weight: 900;
  }

  .wallet-record div {
    min-width: 0;
  }

  .wallet-record strong,
  .wallet-record small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .wallet-record strong {
    color: var(--ink);
    font-size: 13px;
  }

  .wallet-record small {
    margin-top: 3px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
  }

  .wallet-record em {
    color: var(--ink);
    font-size: 13px;
    font-style: normal;
    font-weight: 950;
    white-space: nowrap;
  }

  .message-tabs {
    display: flex;
    gap: 8px;
    margin: 12px -14px 0;
    padding: 0 14px 2px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .message-tabs::-webkit-scrollbar {
    display: none;
  }

  .message-tabs button {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 0 13px;
    border-radius: 999px;
    color: var(--muted);
    font-size: 12px;
  }

  .message-tabs button.active {
    border-color: rgba(20, 184, 166, 0.48);
    background: var(--teal-soft);
    color: var(--ink);
  }

  .message-list {
    display: grid;
    gap: 10px;
    margin-top: 12px;
  }

  .message-card {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: stretch;
    min-height: 112px;
    padding: 12px;
    border: 1px solid rgba(17, 24, 39, 0.13);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.76);
    overflow: hidden;
  }

  .message-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 12px;
    bottom: 12px;
    width: 3px;
    background: rgba(100, 116, 139, 0.24);
  }

  .message-card.is-unread {
    border-color: rgba(20, 184, 166, 0.42);
    background:
      linear-gradient(90deg, rgba(20, 184, 166, 0.1), transparent 42%),
      rgba(255, 255, 255, 0.82);
  }

  .message-card.is-unread::before {
    background: #ff0000;
  }

  .message-card-main {
    min-width: 0;
    padding-left: 4px;
  }

  .message-card-top {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
  }

  .message-card-top time {
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
  }

  .message-card h3 {
    margin: 0 0 5px;
    font-size: 16px;
    line-height: 1.25;
    color: var(--ink);
    overflow-wrap: anywhere;
  }

  .message-card p {
    margin: 0;
    color: var(--ink-2);
    font-size: 13px;
    line-height: 1.45;
    overflow-wrap: anywhere;
  }

  .message-card-side {
    display: grid;
    justify-items: end;
    align-content: space-between;
    gap: 10px;
    min-width: 82px;
  }

  .message-unread-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: transparent;
  }

  .message-delete-btn {
    min-height: 24px;
    padding: 0 8px;
    border: 1px solid #fecaca;
    border-radius: 999px;
    background: #fff5f5;
    color: #dc2626;
    font-size: 11px;
    font-weight: 800;
  }

  .is-unread .message-unread-dot {
    background: #ff0000;
    box-shadow: 0 0 0 5px rgba(255, 0, 0, 0.14);
  }

  .message-card-side button {
    min-height: 32px;
    max-width: 86px;
    padding: 0 9px;
    border-color: rgba(20, 184, 166, 0.38);
    background: var(--teal-soft);
    color: var(--ink);
    font-size: 11px;
    white-space: nowrap;
  }

  .message-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 22px;
    padding: 0 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: 11px;
    font-weight: 900;
  }

  .message-badge--cyan {
    border-color: rgba(20, 184, 166, 0.42);
    background: rgba(20, 184, 166, 0.12);
    color: #0f766e;
  }

  .message-badge--amber {
    border-color: rgba(245, 158, 11, 0.42);
    background: rgba(245, 158, 11, 0.14);
    color: #b45309;
  }

  .message-badge--green {
    border-color: rgba(34, 197, 94, 0.38);
    background: rgba(34, 197, 94, 0.12);
    color: #15803d;
  }

  .message-badge--blue {
    border-color: rgba(59, 130, 246, 0.34);
    background: rgba(59, 130, 246, 0.1);
    color: #1d4ed8;
  }

  .message-badge--purple {
    border-color: rgba(124, 58, 237, 0.34);
    background: rgba(124, 58, 237, 0.1);
    color: #6d28d9;
  }

  .message-badge--pink {
    border-color: rgba(236, 72, 153, 0.34);
    background: rgba(236, 72, 153, 0.1);
    color: #be185d;
  }

  .message-badge--slate {
    border-color: rgba(100, 116, 139, 0.32);
    background: rgba(100, 116, 139, 0.1);
    color: #475569;
  }

  .message-empty {
    display: grid;
    gap: 5px;
    min-height: 140px;
    place-content: center;
    border: 1px dashed var(--line-strong);
    color: var(--muted);
    text-align: center;
    font-size: 13px;
  }

  .message-empty strong {
    color: var(--ink);
    font-size: 16px;
  }

  .mobile-bottom-nav [data-page="messages"]::after {
    content: "";
    position: absolute;
    top: 8px;
    right: calc(50% - 18px);
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: transparent;
  }

  .mobile-bottom-nav [data-page="messages"][data-has-unread]::after {
    background: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.12);
  }
}

@media (max-width: 520px) {
  .mobile-hero h1 {
    font-size: 20px;
  }

  .topic-dual-fields {
    grid-template-columns: 1fr;
  }
}

.topic-create-backdrop.modal-backdrop {
  align-items: flex-start;
  padding-top: max(18px, env(safe-area-inset-top));
  z-index: 45;
}

.topic-rule-backdrop.modal-backdrop {
  z-index: 46;
}

.topic-rule-modal {
  max-height: min(84vh, 560px);
  overflow-y: auto;
}

.topic-rule-modal h2 {
  margin-right: 38px;
  font-size: 20px;
  line-height: 1.25;
}

.topic-rule-content {
  margin-top: 14px;
}

.bet-modal-backdrop.modal-backdrop {
  z-index: 47;
}

.bet-modal {
  width: min(100%, 420px);
  border-color: rgba(20, 184, 166, 0.34);
  background:
    linear-gradient(135deg, rgba(20, 184, 166, 0.16), transparent 48%),
    linear-gradient(315deg, rgba(245, 158, 11, 0.14), transparent 52%),
    var(--bg);
}

.bet-modal h2 {
  margin-right: 40px;
  font-size: 22px;
}

.bet-modal-desc {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
}

.bet-modal-choice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding: 0 14px;
  border: 1px solid rgba(20, 184, 166, 0.5);
  background: var(--teal-soft);
}

.bet-modal-choice span {
  color: var(--muted);
  font-size: 18px;
  font-weight: 1000;
}

.bet-modal-choice strong {
  color: var(--ink);
  font-size: 24px;
  font-weight: 1000;
}

.bet-modal-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 10px 0 12px;
}

.bet-modal-meta span {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.bet-modal-meta strong {
  color: var(--ink);
  font-size: 15px;
}

.bet-stake-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.bet-stake-grid button {
  min-height: 48px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.66);
  color: var(--ink);
  font-weight: 1000;
}

.bet-stake-grid button.active {
  border-color: rgba(20, 184, 166, 0.7);
  background: var(--teal-soft);
  box-shadow: inset 0 0 0 2px rgba(20, 184, 166, 0.14);
}

.bet-stake-grid button:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.bet-submit[disabled] {
  cursor: not-allowed;
  opacity: 0.5;
}

.topic-rule-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.topic-rule-list li {
  display: grid;
  gap: 5px;
  padding: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.62);
}

.topic-rule-list strong {
  color: var(--ink);
  font-size: 13px;
}

.topic-rule-list span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.topic-create-modal {
  max-height: min(88vh, 680px);
  overflow-y: auto;
}

.topic-modal-lead {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.field-req,
.field-opt {
  margin-left: 6px;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.field-req {
  color: var(--teal);
}

.field-opt {
  color: var(--muted);
}

.field-inline-link {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--teal);
  font: inherit;
  font-size: 11px;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 2px;
  box-shadow: none;
}

.modal-field > span .field-inline-link {
  font-size: 12px;
}

.field-inline-link:disabled {
  color: var(--muted);
  cursor: not-allowed;
  opacity: 0.56;
}

.topic-opening-price-field {
  align-self: stretch;
}

.topic-opening-price-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.topic-opening-price-grid label {
  display: grid;
  gap: 4px;
}

.topic-opening-price-grid small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
}

.topic-opening-price-grid input {
  width: 100%;
  min-width: 0;
  border-color: rgba(16, 185, 129, 0.24);
  background: rgba(255, 255, 255, 0.76);
}

.topic-create-modal .modal-field textarea {
  width: 100%;
  min-height: 88px;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  font-weight: 600;
  line-height: 1.45;
  resize: vertical;
}

.topic-create-modal .topic-rule-edit-field textarea {
  min-height: 138px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
  white-space: pre-wrap;
}

.topic-create-modal .modal-field select {
  width: 100%;
  height: 48px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  font-weight: 800;
}

.topic-template-picker {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  position: relative;
}

.topic-type-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.topic-type-switch button {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--ink);
  font-weight: 800;
  box-shadow: none;
}

.topic-type-switch button.is-active {
  border-color: rgba(20, 184, 166, 0.48);
  background: rgba(20, 184, 166, 0.12);
  color: var(--ink);
}

.topic-create-modal select.topic-template-native {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  min-height: 1px !important;
  padding: 0 !important;
  border: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.topic-create-modal .topic-template-select {
  min-width: 0;
  min-height: 44px;
  padding: 8px 10px 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  text-align: left;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.05);
  font-size: 12px !important;
}

.topic-create-modal .topic-template-select span {
  min-width: 0;
  color: var(--ink) !important;
  display: -webkit-box;
  overflow: hidden;
  font-size: 12px !important;
  font-weight: 850;
  line-height: 1.25;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.topic-create-modal .topic-template-select i {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: rgba(20, 184, 166, 0.1);
  color: var(--teal);
  display: inline-grid;
  place-items: center;
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
  transition: transform 0.16s ease;
}

.topic-create-modal .topic-template-select[aria-expanded="true"] i {
  transform: rotate(180deg);
}

.topic-template-options {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: min(260px, 46vh);
  padding: 6px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.topic-template-options[hidden] {
  display: none;
}

.topic-template-option {
  width: 100%;
  min-height: 42px;
  padding: 9px 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  display: block;
  text-align: left;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

.topic-template-option + .topic-template-option {
  margin-top: 2px;
}

.topic-template-option.is-selected {
  background: rgba(20, 184, 166, 0.12);
  color: #0f766e;
}

.topic-rule-template-modal {
  width: min(520px, calc(100vw - 28px));
  max-height: min(86vh, 680px);
  overflow-y: auto;
}

.topic-rule-template-backdrop.modal-backdrop {
  z-index: 52;
}

.topic-rule-template-lead {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
}

.topic-rule-template-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 12px;
}

.topic-rule-template-summary span {
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid rgba(20, 184, 166, 0.18);
  border-radius: 10px;
  background: rgba(20, 184, 166, 0.08);
  color: #0f766e;
  font-size: 11px;
  font-weight: 850;
  line-height: 1.35;
}

.topic-rule-template-list {
  display: grid;
  gap: 10px;
}

.topic-rule-template-card {
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
}

.topic-rule-template-card.is-selected {
  border-color: rgba(20, 184, 166, 0.42);
  background: rgba(20, 184, 166, 0.08);
}

.topic-rule-template-card > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 8px;
}

.topic-rule-template-card strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.topic-rule-template-card > div span {
  color: var(--teal);
  font-size: 11px;
  font-weight: 900;
  text-align: right;
}

.topic-rule-template-card ul {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.topic-rule-template-card li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.topic-rule-template-card li b {
  color: var(--ink);
  font-weight: 900;
  text-align: right;
}

.topic-rule-template-empty {
  margin: 0;
  padding: 12px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.topic-template-delete {
  min-height: 48px;
  padding: 0 12px;
  border: 1px solid rgba(220, 38, 38, 0.28);
  border-radius: 12px;
  background: rgba(254, 242, 242, 0.9);
  color: #b91c1c;
  font-size: 12px;
  font-weight: 900;
}

.topic-sports-event-panel {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(20, 184, 166, 0.22);
  border-radius: 12px;
  background: rgba(20, 184, 166, 0.07);
}

.topic-sports-event-panel[hidden] {
  display: none !important;
}

.topic-sports-source-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.topic-sports-source-switch button,
.topic-sports-filter-row button {
  min-height: 34px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.topic-sports-source-switch button.is-active {
  border-color: rgba(20, 184, 166, 0.45);
  background: rgba(20, 184, 166, 0.15);
  color: #08796f;
}

.topic-sports-filter-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 8px;
}

.topic-sports-filter-row:has(input[type="search"]) {
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr) auto;
}

.topic-sports-filter-row input,
.topic-sports-filter-row select,
.topic-sports-event-panel input,
.topic-sports-event-panel select {
  min-width: 0;
}

.topic-sports-event-card {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.topic-sports-event-card strong {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.25;
}

.topic-sports-event-card small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  line-height: 1.35;
}

.topic-dual-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.topic-play-panel {
  display: grid;
  gap: 10px;
  margin: 8px 0 10px;
  padding: 12px;
  border: 1px solid rgba(20, 184, 166, 0.28);
  background:
    linear-gradient(135deg, rgba(20, 184, 166, 0.12), transparent 70%),
    rgba(255, 255, 255, 0.56);
}

.topic-hash-config {
  display: grid;
  gap: 10px;
}

.topic-hash-config[hidden] {
  display: none !important;
}

.topic-readonly-value {
  min-height: 36px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(20, 184, 166, 0.18);
  border-radius: 8px;
  background: rgba(20, 184, 166, 0.08);
  color: #0f766e;
  font-weight: 850;
}

.topic-create-modal [data-topic-custom-stake],
.topic-create-modal [data-topic-custom-round-min] {
  margin-top: 7px;
}

.topic-custom-time-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  margin-top: 7px;
}

.topic-custom-time-row input[hidden] {
  display: none !important;
}

.topic-custom-time-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.topic-hash-note {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.topic-step[hidden] {
  display: none !important;
}

.topic-modal-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.topic-footer-ghost {
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.65);
  color: var(--ink);
  font-weight: 900;
}

.topic-footer-primary {
  flex: 1;
  min-width: 120px;
}

.topic-preview-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.58);
}

.topic-preview-card h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.28;
}

.topic-preview-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.topic-preview-odds {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.topic-preview-odds span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  background: var(--teal-soft);
  font-size: 13px;
}

.topic-preview-odds span:last-child {
  background: var(--amber-soft);
}

.topic-preview-odds strong {
  font-size: 18px;
}

.topic-preview-odds--digits {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
}

.topic-preview-odds--digits span,
.topic-preview-odds--digits span:last-child {
  justify-content: center;
  min-height: 34px;
  padding: 0;
  border-radius: 999px;
  background: #f0fbf6;
  color: #0f7f58;
  font-size: 14px;
  font-weight: 950;
}

.topic-preview-play {
  display: grid;
  gap: 4px;
  margin: 0 0 10px;
  padding: 10px;
  border: 1px solid rgba(20, 184, 166, 0.34);
  background: var(--teal-soft);
}

.topic-preview-play span,
.topic-preview-play small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.topic-preview-play strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 950;
}

.topic-preview-hint {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.mobile-topic-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.topic-voice-panel {
  margin-top: 8px;
  padding: 14px 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.55);
}

.topic-voice-panel-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.topic-voice-tag {
  padding: 4px 8px;
  border: 1px solid rgba(20, 184, 166, 0.45);
  background: var(--teal-soft);
  color: var(--teal);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.topic-voice-heading {
  margin: 0;
  font-size: 15px;
  font-weight: 900;
  line-height: 1.25;
}

.topic-voice-rules {
  margin: 0 0 14px;
  padding-left: 18px;
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.55;
}

.topic-voice-rules li {
  margin-bottom: 4px;
}

.topic-sync-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.72);
  cursor: pointer;
}

.topic-sync-card > input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--teal);
  cursor: pointer;
  flex-shrink: 0;
}

.topic-sync-card-body {
  display: grid;
  gap: 4px;
}

.topic-sync-card-body strong {
  font-size: 15px;
}

.topic-sync-card-body small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.topic-password-card {
  cursor: pointer;
}

.topic-password-code {
  margin-top: 6px;
}

.password-code-control {
  display: grid;
  gap: 7px;
  width: 100%;
}

.password-code-control[hidden] {
  display: none !important;
}

.password-code-cells {
  position: relative;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 6px;
  width: min(100%, 252px);
}

.password-code-cell {
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1;
  min-height: 34px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--ink);
  font-size: 18px;
  font-weight: 950;
  line-height: 1;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}

.password-code-cell.is-filled {
  border-color: rgba(20, 184, 166, 0.62);
  background: rgba(240, 253, 250, 0.96);
}

.password-code-cell.is-active {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.16);
}

.password-code-input {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  opacity: 0 !important;
  background: transparent !important;
  color: transparent !important;
  caret-color: transparent !important;
  cursor: text !important;
  z-index: 2 !important;
}

.password-code-hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.room-password-modal .password-code-cells {
  width: min(100%, 276px);
  margin: 4px auto 0;
}

.room-password-modal .password-code-cell {
  min-height: 38px;
}

.room-password-error {
  min-height: 18px;
  margin: 0;
  color: #ef4444;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
  text-align: center;
}

.room-password-error[hidden] {
  display: none !important;
}

.room-password-backdrop.is-verifying .password-code-cells {
  opacity: 0.72;
  pointer-events: none;
}

.topic-mic-panel {
  padding: 12px;
  border: 1px solid rgba(20, 184, 166, 0.38);
  background: var(--teal-soft);
}

.topic-mic-panel[hidden] {
  display: none !important;
}

.topic-mic-panel-head {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 10px;
}

.topic-mic-panel-head span:first-child {
  font-size: 12px;
  font-weight: 900;
  color: var(--teal);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.topic-mic-panel-sub {
  font-size: 12px;
  color: var(--ink-2);
}

.topic-mic-roster {
  margin-bottom: 12px;
  padding: 10px;
  border: 1px dashed rgba(17, 24, 39, 0.18);
  background: rgba(255, 255, 255, 0.65);
}

.topic-mic-range-field {
  margin-bottom: 0;
}

.topic-mic-range-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topic-mic-range-row input[type="range"] {
  flex: 1;
  min-width: 0;
  accent-color: var(--teal);
}

.topic-mic-panel.is-locked .topic-mic-range-row input[type="range"] {
  opacity: 0.48;
}

.topic-mic-range-row output {
  min-width: 32px;
  padding: 6px 10px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.85);
  font-size: 16px;
  font-weight: 900;
  text-align: center;
}

.topic-mic-total {
  margin: 10px 0 0;
  font-size: 12px;
  font-weight: 800;
  color: var(--ink-2);
}

.topic-create-status,
.topic-create-error {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.topic-create-status[hidden],
.topic-create-error[hidden] {
  display: none !important;
}

.topic-create-status.is-loading {
  display: flex;
  align-items: center;
  gap: 8px;
  border-color: rgba(20, 184, 166, 0.42);
  color: var(--teal);
}

.topic-create-status.is-loading::before {
  content: "";
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  border: 2px solid rgba(20, 184, 166, 0.22);
  border-top-color: var(--teal);
  border-radius: 50%;
  animation: topicCreateSpin 0.8s linear infinite;
}

.topic-create-backdrop.is-submitting .modal-close {
  pointer-events: none;
  opacity: 0.45;
}

@keyframes topicCreateSpin {
  to {
    transform: rotate(360deg);
  }
}

.topic-create-error {
  border-color: rgba(239, 68, 68, 0.38);
  background: rgba(254, 242, 242, 0.86);
}

.topic-create-error strong {
  display: block;
  margin-bottom: 4px;
  color: #991b1b;
  font-size: 13px;
}

.topic-create-error p {
  margin: 0 0 10px;
  color: var(--ink-2);
}

.topic-create-error-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.topic-voice-no-room {
  padding: 12px;
  border: 1px solid rgba(245, 158, 11, 0.42);
  background: var(--amber-soft);
}

.topic-voice-no-room[hidden] {
  display: none !important;
}

.topic-voice-no-room-title {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 900;
  color: var(--ink);
}

.topic-voice-no-room-desc {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--ink-2);
}

.room-seat-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.room-seat {
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  font-size: 11px;
  font-weight: 900;
}

.room-seat.host {
  width: 34px;
  height: 34px;
  border-color: var(--ink);
  background: var(--ink);
  color: white;
}

.room-seat.host.off {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.7);
  color: transparent;
}

.room-seat.guest {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: #0f172a;
  font-size: 9px;
  letter-spacing: -0.04em;
}

.room-seat.guest.on {
  border-color: var(--teal);
  background: var(--teal-soft);
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.2);
}

.room-seat.guest.off {
  background: rgba(255, 255, 255, 0.7);
  color: transparent;
}

.room-seat-legend {
  flex-basis: 100%;
  width: 100%;
  margin: 8px 0 0;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
}

.room-seat-legend-host {
  display: inline-block;
  margin-right: 4px;
  padding: 0 5px;
  border-radius: 4px;
  background: var(--ink);
  color: white;
  font-size: 10px;
}

.room-seat-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin: 0 3px 0 6px;
  border-radius: 50%;
  vertical-align: middle;
}

.room-seat-dot.on {
  background: var(--teal);
}

.room-seat-dot.off {
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.8);
}

.topic-preview-room {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.58);
}

.topic-preview-room--live {
  border-color: rgba(20, 184, 166, 0.4);
  background: var(--teal-soft);
}

.topic-preview-room--off {
  border-color: rgba(245, 158, 11, 0.38);
  background: var(--amber-soft);
}

.topic-preview-room-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.topic-preview-room-head span:first-child {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  color: var(--ink);
}

.topic-preview-room-pill {
  padding: 3px 8px;
  border: 1px solid rgba(20, 184, 166, 0.5);
  background: rgba(255, 255, 255, 0.75);
  font-size: 10px;
  font-weight: 900;
  color: var(--teal);
}

.topic-preview-room-pill--off {
  border-color: rgba(245, 158, 11, 0.45);
  color: var(--amber);
}

.topic-preview-room-line {
  margin: 0 0 8px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--ink-2);
}

.topic-preview-room-note {
  margin: 8px 0 0;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.4;
}

.topic-preview-room .room-seat.host {
  width: 28px;
  height: 28px;
  font-size: 10px;
}

.topic-preview-room .room-seat.guest {
  width: 22px;
  height: 22px;
}

/* Fixed bottom navigation for every mobile page. */
.mobile-home {
  padding-bottom: calc(98px + env(safe-area-inset-bottom, 0px)) !important;
}

.mobile-page {
  padding-bottom: calc(22px + env(safe-area-inset-bottom, 0px));
}

.mobile-bottom-nav {
  position: fixed !important;
  left: max(12px, calc((100vw - 520px) / 2 + 14px));
  right: max(12px, calc((100vw - 520px) / 2 + 14px));
  bottom: max(10px, env(safe-area-inset-bottom, 0px));
  z-index: 1000;
  margin-top: 0 !important;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.24), 0 1px 0 rgba(255, 255, 255, 0.72) inset;
}

@media (min-width: 0px) {
  body {
    background: #ffffff;
    color: #111827;
  }

  .home-shell {
    background: #ffffff;
  }

  .mobile-home {
    width: min(100%, 560px);
    padding: 0 14px 18px;
    background: #ffffff;
  }

  .mobile-home-nav {
    position: sticky;
    top: 0;
    z-index: 20;
    min-height: 62px;
    margin: 0 -14px;
    padding: 0 22px;
    border-bottom: 1px solid #e5e7eb;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(14px);
  }

  .mobile-home-nav .home-brand img {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 0;
  }

  .mobile-home-nav .home-brand strong {
    font-size: 22px;
    letter-spacing: -0.04em;
  }

  .mobile-home-nav .home-brand small {
    display: none;
  }

  .mobile-user-bar {
    margin-left: auto;
    padding: 0;
    border: 0;
    background: transparent;
  }

  .mobile-user-bar-cluster {
    gap: 12px;
    overflow: visible;
  }

  .mobile-user-bar-cluster > button:not(.mobile-user-logout),
  .mobile-user-bar-cluster .mobile-user-logout,
  .mobile-user-status,
  .mobile-user-name {
    display: none;
  }

  .mobile-user-bar-cluster > button[data-action="share"] {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    min-height: 30px;
    padding: 0;
    border: 0;
    background: transparent;
    color: transparent;
    overflow: hidden;
  }

  .mobile-user-bar-cluster > button[data-action="share"]::before {
    content: "♡";
    color: #6b7280;
    font-size: 23px;
    line-height: 1;
  }

  .mobile-user-bar-cluster > button[data-action="login"] {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, #7c3aed, #ef4444, #f59e0b);
    color: transparent;
    overflow: hidden;
  }

  .mobile-hero,
  .mobile-broadcast,
  .quick-match,
  .mobile-topic-engage,
  .mic-seat-panel {
    display: none !important;
  }

  .mobile-market-nav {
    position: sticky;
    top: 62px;
    z-index: 19;
    margin: 0 -14px;
    padding: 10px 22px 9px;
    border-bottom: 1px solid #eef0f3;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(14px);
  }

  .mobile-market-nav button {
    min-height: 26px;
    padding: 0 2px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: #6b7280;
    font-size: 14px;
    font-weight: 800;
  }

  .mobile-market-nav button.active {
    background: transparent;
    color: #111827;
    box-shadow: none;
  }

  .mobile-market-nav button.home-scope-reset.active {
    background: transparent;
    color: #111827;
    box-shadow: none;
  }

  .mobile-market-nav button.home-scope-switch {
    color: #12b8a6;
    font-weight: 900;
  }

  .mobile-market-nav button.active::before {
    content: "↗";
    margin-right: 4px;
    font-size: 13px;
  }

  .mobile-market-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 36px 36px;
    align-items: center;
    gap: 10px;
    padding: 12px 0 10px;
  }

  .mobile-search-box {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 12px;
    border-radius: 9px;
    background: #f3f4f6;
    color: #9ca3af;
  }

  .mobile-search-box input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: #111827;
    font-size: 15px;
  }

  .mobile-search-box input::placeholder {
    color: #9ca3af;
  }

  .mobile-market-search > button {
    width: 36px;
    height: 36px;
    border: 0;
    background: transparent;
    color: #111827;
    font-size: 20px;
  }

  .mobile-market-filters {
    margin: 0 -14px;
    padding: 5px 22px 12px;
    border-bottom: 1px solid #eef0f3;
  }

  .mobile-market-filters button {
    min-height: 30px;
    padding: 0 11px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #6b7280;
    font-size: 14px;
    font-weight: 800;
  }

  .mobile-market-filters button.active {
    background: #eef2ff;
    color: #2563eb;
    box-shadow: none;
  }

  .mobile-section {
    margin-top: 12px;
  }

  .mobile-section-head {
    display: none;
  }

  .mobile-topic-list {
    gap: 12px;
  }

  .mobile-topic {
    gap: 13px;
    padding: 13px 12px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #ffffff !important;
    box-shadow: 0 7px 18px rgba(15, 23, 42, 0.06);
  }

  .mobile-topic-list > .mobile-topic.selected {
    border-color: #e5e7eb;
    background: #ffffff;
    box-shadow: 0 7px 18px rgba(15, 23, 42, 0.06);
  }

  .pm-topic-cover {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 58px;
    gap: 10px;
    align-items: start;
  }

  .pm-market-icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 8px;
    background: #ff8a1f;
    color: #ffffff;
    font-size: 12px;
    font-weight: 950;
    line-height: 1;
    overflow: hidden;
  }

  .pm-title-row {
    display: block;
  }

  .pm-title {
    margin-top: 2px;
    color: #111827;
    font-size: 15px;
    font-weight: 900;
    line-height: 1.35;
    letter-spacing: -0.02em;
  }

  .pm-rule-btn {
    display: none;
  }

  .pm-meta-row {
    margin-top: 13px;
    color: #6b7280;
    font-size: 12px;
    font-weight: 800;
  }

  .pm-meta-row span:not(:last-child)::after {
    content: "·";
    margin-left: 7px;
  }

  .pm-card-volume {
    margin-top: 10px;
    color: #7b8794;
    font-size: 14px;
    font-weight: 800;
  }

  .pm-probability {
    position: relative;
    display: grid;
    justify-items: center;
    gap: 0;
    width: 54px;
    min-height: 62px;
    padding-top: 16px;
    color: #111827;
  }

  .pm-probability::before {
    content: "";
    position: absolute;
    top: 0;
    width: 48px;
    height: 48px;
    border: 5px solid #e5e7eb;
    border-bottom-color: transparent;
    border-left-color: #ef4444;
    border-radius: 999px;
    transform: rotate(36deg);
  }

  .pm-probability strong {
    position: relative;
    z-index: 1;
    font-size: 16px;
    font-weight: 950;
    line-height: 1;
  }

  .pm-probability small {
    position: relative;
    z-index: 1;
    margin-top: 3px;
    color: #6b7280;
    font-size: 12px;
    font-weight: 800;
  }

  .pm-rule-summary {
    margin: 0;
    color: #374151;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.45;
    -webkit-line-clamp: 2;
  }

  .pm-odds-pair,
  .mobile-odds {
    margin-left: 0;
    gap: 8px;
  }

  .mobile-odds button {
    min-height: 41px;
    padding: 0 12px;
    border: 0;
    border-radius: 7px;
    background: #e7f6ec;
    color: #16a34a;
  }

  .mobile-odds button:last-child {
    background: #fff1f2;
    color: #ef4444;
  }

  .mobile-odds span,
  .mobile-odds strong {
    color: inherit;
    font-size: 14px;
    font-weight: 900;
  }

  .mobile-topic-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-left: 0;
    min-height: 24px;
  }

  .mobile-topic-actions--pair,
  .mobile-topic-actions--triple,
  .mobile-topic-actions--quad {
    grid-template-columns: none;
  }

  .mobile-enter,
  .mobile-enter.secondary,
  .mobile-enter.tertiary,
  .mobile-enter.danger {
    min-height: 24px;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: #6b7280;
    font-size: 12px;
    font-weight: 900;
  }

  .mobile-enter::before {
    content: "□";
    margin-right: 2px;
    color: #6b7280;
  }

  .mobile-enter:not(.secondary):not(.tertiary)::before {
    content: "↗";
  }
}

@media (min-width: 0px) {
  .mobile-home-nav {
    min-height: 54px;
    padding: 0 18px;
  }

  .mobile-home-nav .home-brand img {
    width: 28px;
    height: 28px;
  }

  .mobile-home-nav .home-brand strong {
    font-size: 19px;
    font-weight: 850;
    letter-spacing: -0.045em;
  }

  .mobile-market-nav {
    top: 54px;
    padding: 8px 18px 8px;
  }

  .mobile-market-nav button {
    min-height: 24px;
    font-size: 13px;
    font-weight: 750;
  }

  .mobile-market-search {
    grid-template-columns: minmax(0, 1fr) 32px 32px;
    gap: 8px;
    padding: 10px 0 8px;
  }

  .mobile-search-box {
    min-height: 38px;
    border-radius: 8px;
  }

  .mobile-search-box input {
    font-size: 14px;
  }

  .mobile-market-search > button {
    width: 32px;
    height: 32px;
    font-size: 17px;
  }

  .mobile-market-filters {
    padding: 4px 18px 10px;
  }

  .mobile-market-filters button {
    min-height: 28px;
    padding: 0 10px;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 750;
  }

  .mobile-topic-list {
    gap: 10px;
  }

  .mobile-topic {
    gap: 11px;
    padding: 12px 12px 9px;
    border-radius: 14px;
    box-shadow: 0 5px 16px rgba(15, 23, 42, 0.045);
  }

  .pm-topic-cover {
    grid-template-columns: 40px minmax(0, 1fr) 50px;
    gap: 9px;
  }

  .pm-market-icon {
    width: 34px;
    height: 34px;
    border-radius: 7px;
    font-size: 10px;
    font-weight: 850;
  }

  .pm-title {
    margin-top: 1px;
    font-size: 14px;
    font-weight: 820;
    line-height: 1.34;
    letter-spacing: -0.015em;
  }

  .pm-meta-row {
    margin-top: 9px;
    gap: 3px 6px;
    font-size: 11px;
    font-weight: 700;
  }

  .pm-meta-row span:not(:last-child)::after {
    margin-left: 6px;
  }

  .pm-card-volume {
    margin-top: 8px;
    font-size: 12px;
    font-weight: 700;
  }

  .pm-probability {
    width: 48px;
    min-height: 54px;
    padding-top: 14px;
  }

  .pm-probability::before {
    width: 42px;
    height: 42px;
    border-width: 4px;
  }

  .pm-probability strong {
    font-size: 14px;
    font-weight: 850;
  }

  .pm-probability small {
    margin-top: 2px;
    font-size: 10px;
    font-weight: 700;
  }

  .pm-rule-summary {
    font-size: 12px;
    font-weight: 650;
    line-height: 1.42;
    color: #4b5563;
  }

  .mobile-odds button {
    min-height: 38px;
    padding: 0 11px;
    border-radius: 7px;
  }

  .mobile-odds span,
  .mobile-odds strong {
    font-size: 13px;
    font-weight: 780;
  }

  .mobile-topic-actions {
    gap: 6px;
    min-height: 22px;
  }

  .mobile-enter,
  .mobile-enter.secondary,
  .mobile-enter.tertiary,
  .mobile-enter.danger {
    min-height: 22px;
    font-size: 11px;
    font-weight: 750;
  }
}

@media (min-width: 0px) {
  .mobile-home-nav .home-brand strong {
    font-size: 20px;
    font-weight: 780;
  }

  .mobile-market-nav button {
    font-size: 13px;
    font-weight: 650;
  }

  .mobile-market-filters button {
    font-size: 13px;
    font-weight: 650;
  }

  .mobile-search-box input {
    font-size: 14px;
  }

  .pm-title {
    font-size: 14px;
    font-weight: 760;
    line-height: 1.35;
  }

  .pm-meta-row {
    font-size: 12px;
    font-weight: 560;
  }

  .pm-card-volume {
    font-size: 12px;
    font-weight: 560;
  }

  .pm-probability strong {
    font-size: 14px;
    font-weight: 760;
  }

  .pm-probability small {
    font-size: 11px;
    font-weight: 560;
  }

  .pm-rule-summary {
    font-size: 12px;
    font-weight: 480;
  }

  .mobile-odds span,
  .mobile-odds strong {
    font-size: 13px;
    font-weight: 650;
  }

  .mobile-enter,
  .mobile-enter.secondary,
  .mobile-enter.tertiary,
  .mobile-enter.danger {
    font-size: 11px;
    font-weight: 600;
  }
}

@media (min-width: 0px) {
  .pm-title {
    font-size: 13px;
    line-height: 1.34;
  }

  .mobile-odds button[disabled] strong,
  .mobile-odds button[aria-disabled="true"] strong {
    font-size: 11px;
    font-weight: 600;
  }
}

@media (min-width: 0px) {
  .mobile-odds button[disabled] strong,
  .mobile-odds button[aria-disabled="true"] strong {
    font-size: 13px;
    font-weight: 650;
  }
}

@media (min-width: 0px) {
  .mobile-user-bar {
    max-width: calc(100vw - 160px);
  }

  .mobile-user-bar-cluster {
    gap: 6px;
    overflow-x: auto;
  }

  .mobile-user-bar-cluster > button:not(.mobile-user-logout),
  .mobile-user-bar-cluster .mobile-user-logout,
  .mobile-user-status,
  .mobile-user-name {
    display: inline-flex;
  }

  .mobile-user-bar-cluster > button[data-action="login"],
  .mobile-user-bar-cluster > button[data-action="register-guest"],
  .mobile-user-bar-cluster > button[data-action="share"],
  .mobile-user-bar-cluster .mobile-user-logout {
    align-items: center;
    justify-content: center;
    width: auto;
    height: 28px;
    min-height: 28px;
    padding: 0 9px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #ffffff;
    color: #374151;
    overflow: visible;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
  }

  .mobile-user-bar-cluster > button[data-action="login"] {
    border-color: #bfdbfe;
    background: #eff6ff;
    color: #2563eb;
  }

  .mobile-user-bar-cluster > button[data-action="register-guest"] {
    border-color: #bbf7d0;
    background: #f0fdf4;
    color: #16a34a;
  }

  .mobile-user-bar-cluster > button[data-action="share"]::before {
    content: none;
  }

  .mobile-user-bar-cluster .mobile-user-logout {
    color: #6b7280;
  }

  .mobile-user-status {
    align-items: center;
    height: 28px;
    padding: 0 8px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #f9fafb;
    color: #6b7280;
    font-size: 12px;
    font-style: normal;
    font-weight: 700;
  }

  .mobile-user-name {
    align-items: center;
    max-width: 92px;
    height: 28px;
    overflow: hidden;
    color: #111827;
    font-size: 12px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-user-bar-cluster > [hidden],
  .mobile-user-bar-cluster > button[hidden],
  .mobile-user-bar-cluster > em[hidden],
  .mobile-user-bar-cluster > strong[hidden] {
    display: none !important;
  }
}

@media (min-width: 0px) {
  .modal-backdrop {
    place-items: end center;
    padding: 12px;
    background: rgba(17, 24, 39, 0.18);
    backdrop-filter: blur(10px);
  }

  .auth-modal {
    width: min(100%, 430px);
    padding: 18px 16px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.16);
  }

  .modal-close,
  .modal-back {
    top: 12px;
    height: 30px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #ffffff;
    color: #6b7280;
  }

  .modal-close {
    right: 12px;
    width: 30px;
    font-size: 19px;
  }

  .modal-back {
    left: 12px;
    padding: 0 10px;
    font-size: 12px;
    font-weight: 700;
  }

  .auth-modal .eyebrow {
    color: #6b7280;
    font-size: 11px;
    font-weight: 750;
    letter-spacing: 0.08em;
  }

  .auth-modal h2 {
    margin: 3px 42px 7px 0;
    color: #111827;
    font-size: 22px;
    font-weight: 820;
    letter-spacing: -0.035em;
  }

  .auth-modal p[data-modal-desc] {
    margin-bottom: 14px;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.48;
  }

  .generated-user {
    grid-template-columns: 38px minmax(0, 1fr);
    gap: 10px;
    margin-bottom: 13px;
    padding: 10px;
    border: 1px solid #e5e7eb;
    border-radius: 13px;
    background: #f9fafb;
  }

  .generated-user .guest-avatar,
  .guest-avatar {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    background: #111827;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
  }

  .generated-user strong {
    font-size: 13px;
    font-weight: 760;
  }

  .generated-user small {
    color: #6b7280;
    font-size: 11px;
  }

  .modal-field {
    gap: 6px;
    margin-bottom: 12px;
  }

  .modal-field span {
    color: #6b7280;
    font-size: 12px;
    font-weight: 700;
  }

  .modal-field input {
    height: 42px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #f9fafb;
    color: #111827;
    font-size: 14px;
    font-weight: 500;
  }

  .verify-row {
    grid-template-columns: minmax(0, 1fr) 104px;
    gap: 8px;
    margin-bottom: 12px;
  }

  .verify-row button,
  .modal-later,
  .modal-link {
    min-height: 42px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #ffffff;
    color: #374151;
    font-size: 13px;
    font-weight: 700;
  }

  .modal-submit {
    min-height: 44px;
    border: 1px solid #111827;
    border-radius: 10px;
    background: #111827;
    color: #ffffff;
    font-size: 14px;
    font-weight: 760;
  }

  .modal-link {
    border-color: transparent;
    background: transparent;
    color: #2563eb;
  }

  .mobile-topic-footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding-top: 8px;
    border-top: 1px solid #f0f1f3;
  }

  .mobile-room-footer-info {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    min-width: 0;
  }

  .mobile-room-avatar {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: #111827;
    color: #ffffff;
    font-size: 11px;
    font-weight: 850;
  }

  .mobile-room-footer-info strong,
  .mobile-room-footer-info small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-room-footer-info strong {
    color: #111827;
    font-size: 13px;
    font-weight: 760;
  }

  .mobile-room-footer-info small {
    margin-top: 2px;
    color: #6b7280;
    font-size: 11px;
    font-weight: 550;
  }

  .mobile-room-footer-info--empty .mobile-room-avatar {
    background: #f3f4f6;
    color: #6b7280;
  }

  .mobile-topic-footer .mobile-topic-actions {
    margin-left: 0;
    justify-content: flex-end;
    white-space: nowrap;
  }

  .mobile-topic-footer .mobile-enter,
  .mobile-topic-footer .mobile-enter.secondary,
  .mobile-topic-footer .mobile-enter.tertiary,
  .mobile-topic-footer .mobile-enter.danger {
    font-size: 11px;
    font-weight: 650;
  }
}

@media (min-width: 0px) {
  .mobile-mic-inline {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    margin: -2px 0 0;
    padding: 3px 0 1px;
  }

  .mobile-mic-seats {
    display: flex;
    align-items: center;
    min-width: 0;
    overflow: hidden;
  }

  .mobile-mic-avatar,
  .mobile-mic-seat {
    flex: 0 0 auto;
    width: 25px;
    height: 25px;
    margin-right: -5px;
    border: 2px solid #ffffff;
    border-radius: 999px;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.12);
  }

  .mobile-mic-avatar {
    display: grid;
    place-items: center;
    background: #111827;
    color: #ffffff;
    font-size: 9px;
    font-weight: 800;
  }

  .mobile-mic-avatar.is-empty {
    background: #f3f4f6;
    color: transparent;
  }

  .mobile-mic-seat {
    display: grid;
    place-items: center;
    background: #f3f4f6;
    color: #0f172a;
    font-size: 8px;
    font-weight: 900;
    letter-spacing: -0.04em;
  }

  .mobile-mic-seat.is-on {
    background: #bff3df;
    color: #065f46;
  }

  .mobile-mic-meta {
    color: #6b7280;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
  }

  .mobile-topic-actions {
    padding-top: 7px;
    border-top: 1px solid #f0f1f3;
  }
}

@media (min-width: 0px) {
  .pm-topic-cover {
    grid-template-columns: 48px minmax(0, 1fr) 50px;
  }

  .pm-market-icon-wrap {
    position: relative;
    width: 44px;
    padding-top: 2px;
  }

  .pm-market-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    font-size: 11px;
  }

  .pm-market-icon-wrap .pm-follow-btn {
    position: absolute;
    top: -8px;
    right: -7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    min-height: 18px;
    padding: 0 5px;
    border: 1px solid #fecaca;
    border-radius: 999px;
    background: #ffffff;
    color: #ef4444;
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
  }

  .pm-market-icon-wrap .pm-follow-btn.is-followed {
    border-color: #bbf7d0;
    color: #16a34a;
  }
}

@media (min-width: 0px) {
  .pm-market-icon--creator {
    border-radius: 999px;
    background: #111827;
    color: #ffffff;
    font-size: 11px;
    letter-spacing: -0.02em;
  }
}

.vp-avatar.vp-avatar--image {
  background-color: #0f172a;
  background-image: var(--vp-avatar-url) !important;
  background-position: center !important;
  background-size: cover !important;
  background-repeat: no-repeat !important;
}

@media (min-width: 0px) {
  .mobile-mic-inline {
    margin-top: 0;
    padding: 6px 8px 5px;
    border-radius: 10px;
    background: #f1f3f5;
  }

  .mobile-mic-avatar,
  .mobile-mic-seat {
    width: 27px;
    height: 27px;
  }
}

@media (min-width: 0px) {
  .mobile-mic-inline {
    margin: -2px 0 0;
    padding: 3px 0 1px;
    border-radius: 0;
    background: transparent;
  }

  .mobile-mic-seat {
    background: #d9dee6;
    color: #0f172a;
    font-size: 8px;
    font-weight: 900;
    letter-spacing: -0.04em;
  }

  .mobile-mic-seat.is-on {
    background: #bff3df;
    color: #065f46;
  }
}

@media (min-width: 0px) {
  .mobile-page {
    padding-bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  }

  .mobile-bottom-nav {
    left: max(14px, calc((100vw - 520px) / 2 + 14px));
    right: max(14px, calc((100vw - 520px) / 2 + 14px));
    bottom: max(10px, env(safe-area-inset-bottom, 0px));
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    min-height: 58px;
    padding: 6px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 14px 38px rgba(15, 23, 42, 0.14), 0 1px 0 rgba(255, 255, 255, 0.9) inset;
    backdrop-filter: blur(18px);
    overflow: visible;
  }

  .mobile-bottom-nav button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-height: 46px;
    border: 0;
    border-radius: 13px;
    background: transparent;
    color: #6b7280;
  }

  .mobile-bottom-nav button:last-child {
    border-right: 0;
  }

  .mobile-bottom-nav .active {
    background: #eff6ff;
    color: #111827;
  }

  .mobile-bottom-nav small {
    color: currentColor;
    font-size: 11px;
    font-weight: 700;
  }

  .mobile-bottom-nav span[class^="icon-"] {
    width: 18px;
    height: 18px;
    opacity: 0.88;
    transform: scale(0.92);
  }

  .mobile-bottom-nav .active span[class^="icon-"] {
    opacity: 1;
  }
}

@media (min-width: 0px) {
  .mobile-topic {
    position: relative;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08), 0 1px 0 rgba(255, 255, 255, 0.96) inset;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background-color 180ms ease;
    will-change: transform;
  }

  .mobile-topic::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    opacity: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), transparent 44%, rgba(16, 185, 129, 0.07));
    transition: opacity 180ms ease;
  }

  .mobile-topic:hover,
  .mobile-topic:focus-within {
    transform: translateY(-2px);
    border-color: #d7dee8;
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.12), 0 1px 0 rgba(255, 255, 255, 0.98) inset;
  }

  .mobile-topic:hover::after,
  .mobile-topic:focus-within::after {
    opacity: 1;
  }

  .mobile-topic:active {
    transform: translateY(1px) scale(0.992);
    box-shadow: 0 7px 18px rgba(15, 23, 42, 0.09), 0 1px 0 rgba(255, 255, 255, 0.98) inset;
  }
}

@media (min-width: 0px) {
  .mobile-odds button {
    transition: background-color 160ms ease, color 160ms ease, transform 120ms ease, box-shadow 160ms ease;
  }

  .mobile-odds button:first-child:hover,
  .mobile-odds button:first-child:focus-visible {
    background: #c9f0d8;
    color: #15803d;
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.12);
  }

  .mobile-odds button:last-child:hover,
  .mobile-odds button:last-child:focus-visible {
    background: #ffe0e3;
    color: #dc2626;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.12);
  }

  .mobile-odds button:active {
    transform: translateY(1px) scale(0.992);
  }

  .mobile-odds button[disabled],
  .mobile-odds button[aria-disabled="true"] {
    opacity: 0.82;
  }
}

@media (min-width: 0px) {
  .mobile-odds button:first-child {
    background: #e1f4e8;
    color: #159447;
  }

  .mobile-odds button:last-child {
    background: #fbe9eb;
    color: #e11d2e;
  }

  .mobile-odds button:first-child:hover,
  .mobile-odds button:first-child:focus-visible {
    background: #cfeedd;
    color: #0f7f38;
    box-shadow: 0 5px 14px rgba(21, 148, 71, 0.12);
  }

  .mobile-odds button:last-child:hover,
  .mobile-odds button:last-child:focus-visible {
    background: #f7dadd;
    color: #c81024;
    box-shadow: 0 5px 14px rgba(225, 29, 46, 0.12);
  }
}

@media (min-width: 0px) {
  .mobile-odds button:first-child {
    background: #ccefd9;
    color: #0f7f38;
  }

  .mobile-odds button:last-child {
    background: #f8dadd;
    color: #c81024;
  }

  .mobile-odds button:first-child:hover,
  .mobile-odds button:first-child:focus-visible {
    background: #b7e8ca;
    color: #0b6f2f;
  }

  .mobile-odds button:last-child:hover,
  .mobile-odds button:last-child:focus-visible {
    background: #f2c6cb;
    color: #ad1020;
  }
}

@media (min-width: 0px) {
  .pm-trade-floats {
    display: grid;
    gap: 3px;
    min-height: 43px;
    margin: -2px 0 -4px;
    padding-left: 8px;
    color: #16a34a;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.15;
    pointer-events: none;
  }

  .pm-trade-floats span {
    width: max-content;
    opacity: 0.92;
    animation: pmTradeFloat 2.6s ease-in-out infinite;
    animation-delay: calc(var(--float-i) * 220ms);
  }

  @keyframes pmTradeFloat {
    0%, 100% { transform: translateY(0); opacity: 0.72; }
    45% { transform: translateY(-3px); opacity: 1; }
  }

  .mobile-topic-footer-row {
    display: grid;
    grid-template-columns: minmax(96px, 1fr) auto;
    align-items: center;
    gap: 8px;
    padding-top: 7px;
    border-top: 1px solid #f0f1f3;
  }

  .mobile-topic-market-info {
    display: inline-flex;
    align-items: center;
    min-width: 0;
    color: #6b7280;
    font-size: 12px;
    font-weight: 650;
    white-space: nowrap;
  }

  .mobile-topic-market-info i {
    width: 7px;
    height: 7px;
    margin-right: 5px;
    border-radius: 999px;
    background: #ef4444;
  }

  .mobile-topic-market-info span {
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .mobile-topic-footer-row .mobile-topic-actions {
    margin-left: 0;
    padding-top: 0;
    border-top: 0;
    justify-content: flex-end;
  }
}

@media (min-width: 0px) {
  .mobile-odds button {
    position: relative;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    min-height: 48px;
    padding: 0 10px 0 56px;
    overflow: visible;
  }

  .mobile-odds button::before {
    content: attr(data-side-label);
    position: absolute;
    left: 10px;
    top: 50%;
    z-index: 0;
    max-width: 42%;
    color: rgba(15, 23, 42, 0.07);
    font-size: clamp(15px, 3.5vw, 19px);
    font-weight: 1000;
    line-height: 1;
    transform: translateY(-50%);
    transform-origin: left center;
    white-space: nowrap;
    pointer-events: none;
  }

  .mobile-odds button > strong {
    position: relative;
    z-index: 1;
    width: auto;
  }

  .mobile-odds button > strong {
    flex: 0 0 auto;
    text-align: right;
  }

  .pm-side-prediction {
    position: relative;
    z-index: 1;
    flex: 1 1 auto;
    display: block;
    min-width: 0;
    color: rgba(15, 23, 42, 0.58);
    font-size: 10px;
    font-weight: 850;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: right;
    white-space: nowrap;
  }

  .pm-bet-float {
    position: absolute;
    left: 12px;
    top: -15px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    min-width: 38px;
    color: #16a34a;
    font-size: 12px;
    font-weight: 850;
    line-height: 1;
    opacity: 1;
    transform: none;
    pointer-events: none;
  }

  .mobile-odds button:last-child .pm-bet-float {
    color: #ef4444;
  }

  .pm-bet-float.is-floating {
    animation: none;
  }

  .pm-bet-float-item {
    display: block;
    min-width: 42px;
    padding: 2px 4px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.1);
    color: currentColor;
    font-style: normal;
    opacity: 0;
    transform: translate(0, 8px);
    white-space: nowrap;
    animation: betFloatOnce var(--bet-float-duration, 1900ms) ease-out forwards;
  }

  @keyframes betFloatOnce {
    0% { opacity: 0; transform: translate(0, 8px); }
    14% { opacity: 1; transform: translate(0, 0); }
    76% { opacity: 1; transform: translate(var(--bet-float-drift, 0), calc(var(--bet-float-rise, 36px) * -0.72)); }
    100% { opacity: 0; transform: translate(var(--bet-float-drift, 0), calc(var(--bet-float-rise, 36px) * -1)); }
  }
}

@media (min-width: 0px) {
  .mobile-topic-market-info:not(.is-realtime) {
    padding-left: 0;
  }
}

@media (min-width: 0px) {
  .pm-probability--empty {
    color: #9ca3af;
  }

  .pm-probability--empty::before {
    border-color: #eef0f3;
    border-bottom-color: transparent;
    border-left-color: #eef0f3;
  }
}

@media (min-width: 0px) {
  .pm-probability {
    --p: 0;
    --progress-color: #ef4444;
  }

  .pm-probability::before {
    border: 0;
    background: conic-gradient(from 225deg, var(--progress-color) 0deg calc(var(--p) * 1.8deg), #e5e7eb calc(var(--p) * 1.8deg) 180deg, transparent 180deg 360deg);
    -webkit-mask: radial-gradient(circle, transparent 53%, #000 55%);
    mask: radial-gradient(circle, transparent 53%, #000 55%);
    transform: none;
  }

  .pm-probability--empty {
    --p: 0;
    --progress-color: #e5e7eb;
  }

  .pm-probability--empty::before {
    background: conic-gradient(from 225deg, #e5e7eb 0deg 180deg, transparent 180deg 360deg);
  }
}

@media (min-width: 0px) {
  .pm-probability {
    --p: 0;
    --progress-color: #7cc7a0;
    width: 54px;
    min-height: 56px;
    padding-top: 15px;
  }

  .pm-probability > span {
    position: absolute;
    inset: 0;
    pointer-events: none;
  }

  .pm-probability::before {
    top: 0;
    left: 50%;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    background: conic-gradient(from 270deg, var(--progress-color) 0deg calc(var(--p) * 1.8deg), #e5e7eb calc(var(--p) * 1.8deg) 180deg, transparent 180deg 360deg);
    -webkit-mask: radial-gradient(circle, transparent 56%, #000 58%);
    mask: radial-gradient(circle, transparent 56%, #000 58%);
    transform: translateX(-50%);
  }

  .pm-probability > span::after {
    content: "";
    position: absolute;
    left: 3px;
    top: 28px;
    width: 5px;
    height: 8px;
    border-radius: 999px;
    background: #ef4444;
    transform: rotate(-8deg);
  }

  .pm-probability--down {
    --progress-color: #ef9aa3;
  }

  .pm-probability strong {
    position: relative;
    z-index: 1;
    color: #111827;
    font-size: 16px;
    font-weight: 800;
    line-height: 1;
  }

  .pm-probability small {
    position: relative;
    z-index: 1;
    margin-top: 3px;
    color: #6b7280;
    font-size: 12px;
    font-weight: 650;
    line-height: 1;
  }

  .pm-probability--empty::before {
    background: conic-gradient(from 270deg, #e5e7eb 0deg 180deg, transparent 180deg 360deg);
  }

  .pm-probability--empty > span::after {
    display: none;
  }
}

@media (min-width: 0px) {
  .pm-probability {
    --a: 50;
  }

  .pm-probability::before {
    background: conic-gradient(from 270deg, #7cc7a0 0deg calc(var(--a) * 1.8deg), #ef9aa3 calc(var(--a) * 1.8deg) 180deg, transparent 180deg 360deg);
  }

  .pm-probability--empty::before {
    background: conic-gradient(from 270deg, #e5e7eb 0deg 180deg, transparent 180deg 360deg);
  }
}

@media (min-width: 0px) {
  .pm-probability > span::after {
    display: none !important;
  }

  .pm-probability[style*="--a:0"]::before {
    background: conic-gradient(from 270deg, #ef9aa3 0deg 180deg, transparent 180deg 360deg);
  }

  .pm-probability[style*="--a:100"]::before {
    background: conic-gradient(from 270deg, #7cc7a0 0deg 180deg, transparent 180deg 360deg);
  }
}

@media (min-width: 0px) {
  .pm-probability--empty strong,
  .pm-probability--empty small {
    color: #9ca3af !important;
  }

.pm-probability--empty::before {
    background: conic-gradient(from 270deg, #e5e7eb 0deg 180deg, transparent 180deg 360deg) !important;
  }
}

/* Split to ./styles/*.css: removed original lines 9007-9136. */
/* Split to ./styles/*.css: removed original lines 9137-9537. */
/* Split to ./styles/*.css: removed original lines 9538-9646. */
/* Split to ./styles/*.css: removed original lines 9647-9702. */
/* Split to ./styles/*.css: removed original lines 9703-10012. */
/* Page-scoped overrides were split into ./styles/*.css to prevent cross-page style pollution. */

@media (hover: none), (pointer: coarse), (max-width: 768px) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
  textarea,
  select {
    font-size: 16px !important;
  }
}

/* Keep business modals aligned with the user auth/register bottom-sheet style. */
.topic-create-backdrop,
.topic-rule-backdrop,
.topic-rule-template-backdrop,
.bet-modal-backdrop {
  display: flex !important;
  align-items: flex-end !important;
  justify-content: center !important;
  padding: 0 12px calc(84px + env(safe-area-inset-bottom, 0px)) !important;
  background: linear-gradient(
    180deg,
    rgba(247, 248, 250, 0.08) 0%,
    rgba(247, 248, 250, 0.18) 45%,
    rgba(247, 248, 250, 0.72) 100%
  ) !important;
  backdrop-filter: blur(14px) !important;
}

.topic-create-backdrop[hidden],
.topic-rule-backdrop[hidden],
.topic-rule-template-backdrop[hidden],
.bet-modal-backdrop[hidden] {
  display: none !important;
}

.topic-create-modal,
.topic-rule-modal,
.topic-rule-template-modal,
.bet-modal {
  width: min(100%, 430px) !important;
  max-height: calc(100vh - 104px - env(safe-area-inset-bottom, 0px)) !important;
  margin: 0 auto !important;
  border: 1px solid var(--vp-line, #e5e7eb) !important;
  border-radius: 22px 22px 0 0 !important;
  background: rgba(255, 255, 255, 0.98) !important;
  color: var(--vp-ink, #111827) !important;
  box-shadow: 0 -18px 45px rgba(15, 23, 42, 0.16) !important;
  overflow-y: auto !important;
  scrollbar-width: none;
}

.topic-create-modal {
  display: flex !important;
  flex-direction: column !important;
  height: min(calc(100vh - 104px - env(safe-area-inset-bottom, 0px)), 680px) !important;
}

.topic-rule-modal,
.topic-rule-template-modal,
.bet-modal {
  height: min(calc(100vh - 104px - env(safe-area-inset-bottom, 0px)), 520px) !important;
}

.topic-create-modal::before,
.topic-rule-modal::before,
.topic-rule-template-modal::before,
.bet-modal::before {
  content: "";
  display: block;
  width: 42px;
  height: 4px;
  margin: -8px auto 12px;
  border-radius: 999px;
  background: #d1d5db;
}

.topic-create-modal::-webkit-scrollbar,
.topic-rule-modal::-webkit-scrollbar,
.topic-rule-template-modal::-webkit-scrollbar,
.bet-modal::-webkit-scrollbar {
  display: none;
}

.topic-create-modal .modal-close,
.topic-rule-modal .modal-close,
.topic-rule-template-modal .modal-close,
.bet-modal .modal-close {
  border: 1px solid var(--vp-line, #e5e7eb) !important;
  background: #ffffff !important;
  color: var(--vp-ink, #111827) !important;
}

.topic-create-modal .modal-field input,
.topic-create-modal .modal-field select,
.topic-create-modal .modal-field textarea,
.topic-create-modal .topic-template-select,
.topic-rule-modal .modal-field input,
.topic-rule-modal .modal-field select,
.topic-rule-modal .modal-field textarea,
.bet-modal .modal-field input,
.bet-modal .modal-field select,
.bet-modal .modal-field textarea {
  border: 1px solid var(--vp-line-strong, #d7dde5) !important;
  background: #f9fafb !important;
  color: var(--vp-ink, #111827) !important;
}

.topic-create-modal textarea,
.topic-rule-modal textarea,
.bet-modal textarea {
  scrollbar-width: none;
}

.topic-create-modal textarea::-webkit-scrollbar,
.topic-rule-modal textarea::-webkit-scrollbar,
.bet-modal textarea::-webkit-scrollbar {
  display: none;
}

.topic-create-modal .topic-type-switch button {
  min-height: 36px !important;
  border: 1px solid var(--vp-line, #e5e7eb) !important;
  border-radius: 10px !important;
  background: #ffffff !important;
  color: var(--vp-ink, #111827) !important;
  font-size: 13px !important;
  font-weight: 820 !important;
}

.topic-create-modal .topic-type-switch button.is-active {
  border-color: rgba(20, 184, 166, 0.48) !important;
  background: rgba(20, 184, 166, 0.1) !important;
  color: #0f766e !important;
}

.topic-create-modal .topic-step {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  padding-right: 2px !important;
  scrollbar-width: none !important;
}

.topic-create-modal .topic-step::-webkit-scrollbar {
  display: none;
}

.topic-create-modal .topic-modal-footer {
  flex: 0 0 auto !important;
  gap: 8px !important;
  justify-content: flex-end !important;
  margin-top: 10px !important;
  padding-top: 10px !important;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.98) 32%) !important;
}

.topic-create-modal .topic-footer-ghost,
.topic-create-modal .topic-footer-primary,
.topic-create-modal .modal-submit,
.bet-modal .bet-submit,
.bet-modal [data-action="bet-recharge-submit"],
.bet-modal .bet-recharge-choice-row button,
.bet-modal .bet-recharge-address button {
  min-height: 36px !important;
  padding: 0 12px !important;
  border-radius: 10px !important;
  font-size: 13px !important;
  font-weight: 820 !important;
  box-shadow: none !important;
}

.topic-create-modal .topic-footer-primary,
.topic-create-modal .modal-submit {
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: 112px !important;
}

.bet-modal .bet-submit {
  display: block !important;
  width: auto !important;
  min-width: 128px !important;
  margin: 10px auto 0 !important;
}

.topic-create-modal .topic-footer-primary,
.topic-create-modal .modal-submit,
.bet-modal .bet-submit,
.bet-modal [data-action="bet-recharge-submit"] {
  border: 1px solid rgba(20, 184, 166, 0.52) !important;
  background: rgba(20, 184, 166, 0.12) !important;
  color: #0f766e !important;
}

.topic-create-modal .topic-footer-ghost,
.bet-modal .bet-recharge-choice-row button,
.bet-modal .bet-recharge-address button {
  border: 1px solid rgba(20, 184, 166, 0.24) !important;
  background: #ffffff !important;
  color: #0f766e !important;
}

.bet-modal .bet-stake-grid button {
  min-height: 38px !important;
  border-radius: 10px !important;
  font-size: 13px !important;
}

.bet-modal .bet-stake-grid button.active {
  border-color: rgba(20, 184, 166, 0.52) !important;
  background: rgba(20, 184, 166, 0.1) !important;
  color: #0f766e !important;
}

@media (max-height: 720px) {
  .topic-create-modal,
  .topic-rule-modal,
  .topic-rule-template-modal,
  .bet-modal {
    max-height: calc(100vh - 92px - env(safe-area-inset-bottom, 0px)) !important;
    height: calc(100vh - 92px - env(safe-area-inset-bottom, 0px)) !important;
    padding-top: 16px !important;
    padding-bottom: 14px !important;
  }
}

/* Market buy/sell dialogs: homepage, detail page, and voice room. */
.trading-market-backdrop.trading-market-backdrop--light,
.trading-market-backdrop.trading-market-backdrop--room {
  align-items: flex-end !important;
  justify-content: center !important;
  padding: 0 12px calc(18px + env(safe-area-inset-bottom, 0px)) !important;
}

.trading-modal.trading-modal--light,
.trading-modal.trading-modal--room {
  --trading-accent: #14b8a6;
  --trading-accent-text: #0f766e;
  display: flex !important;
  flex-direction: column !important;
  width: min(calc(100vw - 24px), 360px) !important;
  height: min(calc(100vh - 94px - env(safe-area-inset-bottom, 0px)), 500px) !important;
  max-height: min(calc(100vh - 94px - env(safe-area-inset-bottom, 0px)), 500px) !important;
  overflow: hidden !important;
  border-radius: 14px !important;
}

.trading-modal.trading-modal--room {
  --trading-accent-text: #5eead4;
}

.trading-modal .trading-pane:not([hidden]) {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  scrollbar-width: none !important;
}

.trading-modal .trading-pane:not([hidden])::-webkit-scrollbar {
  display: none;
}

.trading-modal .trading-modal-head,
.trading-modal .trading-mode-tabs,
.trading-modal .trading-ticket-note {
  flex: 0 0 auto !important;
}

.trading-modal .trading-mode-tabs button,
.trading-modal .trading-outcome-switch button,
.trading-modal .trading-quick-amounts button,
.trading-modal .trading-position-tools button,
.trading-modal .trading-sell-guide-actions button,
.trading-modal .trading-ticket-submit,
.trading-modal .trading-modal-form > button,
.trading-modal .trading-complete-set button {
  min-height: 32px !important;
  border-radius: 8px !important;
  font-size: 11px !important;
  font-weight: 760 !important;
  box-shadow: none !important;
}

.trading-modal .trading-outcome-switch button,
.trading-modal .trading-quick-amounts button,
.trading-modal .trading-position-tools button,
.trading-modal .trading-sell-guide-actions button {
  grid-column: auto !important;
  width: auto !important;
  min-width: 0 !important;
}

.trading-modal .trading-mode-tabs button.is-active,
.trading-modal .trading-outcome-switch button.is-active,
.trading-modal .trading-quick-amounts button.is-active,
.trading-modal .trading-position-tools button.is-active {
  border-color: rgba(20, 184, 166, 0.5) !important;
  background: rgba(20, 184, 166, 0.12) !important;
  color: var(--trading-accent-text) !important;
}

.trading-modal .trading-ticket-submit,
.trading-modal .trading-modal-form > button,
.trading-modal .trading-complete-set button,
.trading-modal .trading-sell-guide-actions button {
  border: 1px solid rgba(20, 184, 166, 0.5) !important;
  background: rgba(20, 184, 166, 0.12) !important;
  color: var(--trading-accent-text) !important;
}

.trading-modal .trading-ticket-submit {
  width: auto !important;
  min-width: 128px !important;
  justify-self: center !important;
  margin: 2px auto 0 !important;
  padding: 0 14px !important;
}

.trading-modal .trading-ticket-input-wrap,
.trading-modal .trading-sell-available {
  min-height: 40px !important;
}

.trading-modal .trading-quote-line {
  min-height: 28px !important;
}

.trading-modal.trading-modal--light .trading-mode-tabs button.is-active,
.trading-modal.trading-modal--light .trading-outcome-switch button.is-active,
.trading-modal.trading-modal--light .trading-quick-amounts button.is-active,
.trading-modal.trading-modal--light .trading-position-tools button.is-active,
.trading-modal.trading-modal--light .trading-ticket-submit,
.trading-modal.trading-modal--light .trading-modal-form > button,
.trading-modal.trading-modal--light .trading-complete-set button,
.trading-modal.trading-modal--light .trading-sell-guide-actions button {
  color: #0f766e !important;
}

.trading-modal.trading-modal--room .trading-mode-tabs button.is-active,
.trading-modal.trading-modal--room .trading-outcome-switch button.is-active,
.trading-modal.trading-modal--room .trading-quick-amounts button.is-active,
.trading-modal.trading-modal--room .trading-position-tools button.is-active,
.trading-modal.trading-modal--room .trading-ticket-submit,
.trading-modal.trading-modal--room .trading-modal-form > button,
.trading-modal.trading-modal--room .trading-complete-set button,
.trading-modal.trading-modal--room .trading-sell-guide-actions button {
  color: #5eead4 !important;
}

.trading-modal.trading-modal--light .trading-outcome-switch,
.trading-modal.trading-modal--light .trading-sell-guide-actions {
  border: 1px solid #e5e7eb !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  padding: 4px !important;
}

.trading-modal.trading-modal--light .trading-outcome-switch [data-trading-outcome-toggle="YES"] {
  border-color: #99f6e4 !important;
  background: #f0fdfa !important;
  color: #0f766e !important;
}

.trading-modal.trading-modal--light .trading-outcome-switch [data-trading-outcome-toggle="NO"] {
  border-color: #fecdd3 !important;
  background: #fff1f2 !important;
  color: #be123c !important;
}

.trading-modal.trading-modal--light .trading-outcome-switch [data-trading-outcome-toggle="YES"].is-active {
  border-color: #14b8a6 !important;
  background: #12b8a6 !important;
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(18, 184, 166, 0.28) !important;
}

.trading-modal.trading-modal--light .trading-outcome-switch [data-trading-outcome-toggle="NO"].is-active {
  border-color: #e11d48 !important;
  background: #e11d48 !important;
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(225, 29, 72, 0.24) !important;
}

.trading-modal.trading-modal--light .trading-sell-guide-actions [data-trading-outcome-toggle="YES"] {
  border-color: #99f6e4 !important;
  background: #f0fdfa !important;
  color: #0f766e !important;
}

.trading-modal.trading-modal--light .trading-sell-guide-actions [data-trading-outcome-toggle="NO"] {
  border-color: #fecdd3 !important;
  background: #fff1f2 !important;
  color: #be123c !important;
}

.trading-modal.trading-modal--room .trading-outcome-switch [data-trading-outcome-toggle="YES"] {
  border-color: rgba(94, 234, 212, 0.22) !important;
  background: rgba(20, 184, 166, 0.08) !important;
  color: #5eead4 !important;
}

.trading-modal.trading-modal--room .trading-outcome-switch [data-trading-outcome-toggle="NO"] {
  border-color: rgba(251, 113, 133, 0.22) !important;
  background: rgba(244, 63, 94, 0.08) !important;
  color: #fda4af !important;
}

.trading-modal.trading-modal--room .trading-outcome-switch [data-trading-outcome-toggle="YES"].is-active {
  border-color: #12b8a6 !important;
  background: #12b8a6 !important;
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(18, 184, 166, 0.32) !important;
}

.trading-modal.trading-modal--room .trading-outcome-switch [data-trading-outcome-toggle="NO"].is-active {
  border-color: #e11d48 !important;
  background: #e11d48 !important;
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(225, 29, 72, 0.3) !important;
}

.trading-modal.trading-modal--room .trading-sell-guide-actions [data-trading-outcome-toggle="YES"] {
  border-color: rgba(94, 234, 212, 0.32) !important;
  background: rgba(20, 184, 166, 0.14) !important;
  color: #5eead4 !important;
}

.trading-modal.trading-modal--room .trading-sell-guide-actions [data-trading-outcome-toggle="NO"] {
  border-color: rgba(251, 113, 133, 0.34) !important;
  background: rgba(244, 63, 94, 0.14) !important;
  color: #fda4af !important;
}

.trading-modal .trading-modal-form > button:disabled,
.trading-modal .trading-complete-set button:disabled {
  border-color: #e5e7eb !important;
  background: #e5e7eb !important;
  color: #9ca3af !important;
}

.trading-modal.trading-modal--room .trading-modal-form > button:disabled,
.trading-modal.trading-modal--room .trading-complete-set button:disabled {
  border-color: rgba(100, 116, 139, 0.24) !important;
  background: rgba(100, 116, 139, 0.26) !important;
  color: #94a3b8 !important;
}

@media (max-height: 640px) {
  .trading-modal.trading-modal--light,
  .trading-modal.trading-modal--room {
    height: calc(100vh - 84px - env(safe-area-inset-bottom, 0px)) !important;
    max-height: calc(100vh - 84px - env(safe-area-inset-bottom, 0px)) !important;
  }
}

body.topic-detail-open .topic-detail-stack--market {
  padding-bottom: calc(78px + env(safe-area-inset-bottom, 0px)) !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky {
  position: fixed !important;
  left: 50% !important;
  bottom: calc(12px + env(safe-area-inset-bottom, 0px)) !important;
  z-index: 82 !important;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 8px !important;
  width: min(calc(100vw - 24px), 420px) !important;
  margin: 0 !important;
  padding: 8px !important;
  border: 1px solid rgba(229, 231, 235, 0.96) !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, 0.96) !important;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.18) !important;
  transform: translateX(-50%) !important;
  backdrop-filter: blur(16px) !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky button {
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  min-width: 0 !important;
  min-height: 44px !important;
  overflow: hidden !important;
  border: 1px solid rgba(20, 184, 166, 0.42) !important;
  border-radius: 10px !important;
  background: #f0fdfa !important;
  color: #0f766e !important;
  padding: 6px 8px !important;
  box-shadow: none !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky button:last-child {
  border-color: rgba(225, 29, 72, 0.3) !important;
  background: #fff1f2 !important;
  color: #be123c !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky button::before,
body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky .pm-bet-float {
  display: none !important;
  content: none !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky strong,
body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky small {
  position: relative !important;
  z-index: 1 !important;
  min-width: 0 !important;
  max-width: 100% !important;
  color: inherit !important;
  text-align: center !important;
  white-space: nowrap !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky strong {
  font-size: 12px !important;
  font-weight: 950 !important;
  line-height: 1.15 !important;
}

body.topic-detail-open .topic-detail-stack--market .pm-odds-pair--market-sticky small {
  flex: 0 0 auto !important;
  font-size: 10px !important;
  font-weight: 850 !important;
  opacity: 0.82 !important;
}

.market-my-data-backdrop {
  align-items: flex-end !important;
  justify-content: center !important;
  padding: 0 12px calc(14px + env(safe-area-inset-bottom, 0px)) !important;
  background: rgba(15, 23, 42, 0.42) !important;
  z-index: 94 !important;
}

.market-my-data-backdrop[hidden] {
  display: none !important;
}

.market-my-data-modal {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 10px;
  width: min(calc(100vw - 24px), 430px);
  height: min(68vh, 560px);
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 18px 18px 0 0;
  background: #ffffff;
  color: #111827;
  box-shadow: 0 -18px 48px rgba(15, 23, 42, 0.18);
  padding: 14px 10px 12px;
}

.market-my-data-modal .modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  border-color: #e5e7eb;
  background: #ffffff;
  color: #111827;
}

.market-my-data-head {
  display: grid;
  gap: 3px;
  padding: 0 42px 0 2px;
}

.market-my-data-head small {
  color: #0f766e;
  font-size: 10px;
  font-weight: 850;
}

.market-my-data-head h2 {
  margin: 0;
  color: #111827;
  font-size: 15px;
  font-weight: 950;
  line-height: 1.2;
}

.market-my-data-head p {
  margin: 0;
  color: #6b7280;
  font-size: 10px;
  font-weight: 750;
  line-height: 1.4;
}

.market-my-data-body {
  display: grid;
  gap: 8px;
  min-height: 0;
  overflow: auto;
  padding-right: 2px;
  scrollbar-width: none;
}

.market-my-data-body::-webkit-scrollbar {
  display: none;
}
