:root {
  --bg: #f6f8f6;
  --surface: #fff;
  --surface-2: #fbfcfb;
  --green: #109b65;
  --green-2: #0a8455;
  --green-soft: #e7f6f0;
  --green-soft-2: #f1fbf6;
  --text: #11161d;
  --muted: #717b89;
  --line: #e1e8e4;
  --shadow: 0 22px 55px rgba(17, 22, 29, .08);
  --shadow-soft: 0 12px 32px rgba(17, 22, 29, .055);
  --radius: 22px;
  --container: 1840px;
  --content-container: 1200px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.35;
  -webkit-font-smoothing: antialiased;
}

.i18n-pending body {
  opacity: 1;
}

.app-loading body {
  min-height: 100vh;
  overflow: hidden;
}

.app-loading body > * {
  opacity: 0;
  pointer-events: none;
}

.app-loading body::before {
  content: "BM";
  position: fixed;
  left: 50%;
  top: 42%;
  z-index: 9998;
  width: 76px;
  height: 76px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 72% 20%, rgba(255, 255, 255, .22), transparent 28%),
    linear-gradient(135deg, #10161d, #080b0f);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 23px;
  font-weight: 950;
  transform: translate(-50%, -50%);
  box-shadow:
    0 26px 60px rgba(17, 22, 29, .18),
    0 0 0 16px rgba(16, 155, 101, .08);
  animation: loadingPulse 1.2s ease-in-out infinite;
}

.app-loading body::after {
  content: "";
  position: fixed;
  left: 50%;
  top: calc(42% + 78px);
  z-index: 9998;
  width: min(320px, calc(100vw - 48px));
  height: 18px;
  border-radius: 26px;
  transform: translateX(-50%);
  background:
    linear-gradient(90deg, transparent 0, rgba(255, 255, 255, .72) 44%, transparent 88%) 0 2px / 180px 14px no-repeat,
    linear-gradient(90deg, rgba(16, 155, 101, .14), rgba(16, 155, 101, .28), rgba(16, 155, 101, .14)) 50% 2px / 260px 14px no-repeat;
  animation: loadingShimmer 1.15s linear infinite;
}

.app-loaded body::before,
.app-loaded body::after {
  content: none !important;
  display: none !important;
  animation: none !important;
}

.app-loaded body {
  overflow: auto;
}

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

button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.hidden { display: none !important; }

.svg-icon {
  width: 22px;
  height: 22px;
  display: inline-block;
  vertical-align: -.18em;
}

.flag {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .08);
  flex: 0 0 auto;
}

.flag-img {
  display: inline-grid;
  place-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, #f5fbf8, #e5f3ee);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  color: var(--green);
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0;
}

.team-logo {
  background-size: contain;
  background-color: rgba(255, 255, 255, .92);
  box-sizing: border-box;
  padding: 5px;
}

.flag.xs { width: 28px; height: 28px; }
.flag.sm { width: 34px; height: 34px; }
.flag.md { width: 42px; height: 42px; }
.flag.lg { width: 70px; height: 70px; }

.app-header {
  height: 112px;
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .94);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.app-header::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 6px;
  background: #26302e;
}

.header-inner {
  max-width: var(--container);
  height: 100%;
  margin: 0 auto;
  padding: 6px 42px 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 34px;
}

.brand,
.brand-link {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: 0 0 auto;
  min-width: max-content;
  position: relative;
  z-index: 2;
}

.brand-mark {
  width: 58px;
  height: 58px;
  border-radius: 15px;
  background: #05070a;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 900;
  letter-spacing: -.06em;
}

.brand-name {
  font-size: 38px;
  font-weight: 850;
  letter-spacing: -.04em;
}

.top-nav {
  display: flex;
  justify-content: flex-start;
  gap: 22px;
  min-width: 0;
  overflow: hidden;
}

.nav-link {
  min-height: 58px;
  border: 0;
  background: transparent;
  border-radius: 18px;
  padding: 0 20px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
  white-space: nowrap;
  transition: background-color .16s ease, color .16s ease, transform .16s ease;
}

.nav-link:hover {
  background: rgba(231, 246, 240, .72);
  color: var(--green-2);
  transform: translateY(-1px);
}

.nav-link.active {
  background: var(--green-soft);
  color: var(--green-2);
}

.nav-link.active::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: -18px;
  height: 4px;
  border-radius: 999px;
  background: var(--green);
}

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

body.auth-mode .top-nav,
body.auth-mode .header-actions,
body.auth-mode .mobile-menu-button,
body.auth-mode .mobile-drawer {
  display: none;
}

body.auth-mode .header-inner {
  justify-content: flex-start;
}

.account-menu-wrap {
  position: relative;
  flex: 0 0 auto;
}

.notification-wrap {
  position: relative;
  flex: 0 0 auto;
}

.wallet-chip,
.profile-chip,
.icon-chip {
  min-height: 60px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  font-weight: 800;
  box-shadow: 0 12px 28px rgba(17, 22, 29, .04);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.wallet-chip:hover,
.profile-chip:hover,
.icon-chip:hover {
  border-color: #cfe4db;
  box-shadow: 0 16px 34px rgba(17, 22, 29, .075);
  transform: translateY(-1px);
}

.account-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 12px);
  z-index: 35;
  width: 220px;
  padding: 8px;
  border: 1px solid rgba(225, 232, 228, .95);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(242, 251, 247, .96));
  box-shadow: 0 22px 48px rgba(17, 22, 29, .12);
  backdrop-filter: blur(14px);
}

.account-menu::before {
  content: "";
  position: absolute;
  right: 26px;
  top: -7px;
  width: 14px;
  height: 14px;
  border-left: 1px solid rgba(225, 232, 228, .95);
  border-top: 1px solid rgba(225, 232, 228, .95);
  background: rgba(255, 255, 255, .98);
  transform: rotate(45deg);
}

.account-menu a,
.account-menu button {
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 13px;
  background: transparent;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 850;
  text-align: left;
  transition: background-color .16s ease, color .16s ease, transform .16s ease;
}

.account-menu a:hover,
.account-menu button:hover {
  background: var(--green-soft);
  color: var(--green-2);
  transform: translateX(2px);
}

.language-menu-row {
  display: grid;
  gap: 10px;
  padding: 10px;
  margin-bottom: 4px;
  border: 1px solid rgba(16, 155, 101, .14);
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .13), transparent 44%),
    linear-gradient(135deg, rgba(16, 155, 101, .08), rgba(255, 255, 255, .82));
}

.language-menu-row > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.language-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.account-menu .language-toggle button {
  min-height: 36px;
  padding: 8px 10px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, .78);
  color: var(--muted);
  font-weight: 950;
  text-align: center;
}

.account-menu .language-toggle button:hover {
  background: rgba(16, 155, 101, .10);
  color: var(--green);
  transform: translateY(-1px);
}

.account-menu .language-toggle button.active {
  border-color: rgba(16, 155, 101, .32);
  background: var(--green-soft);
  color: var(--green);
  box-shadow: inset 0 0 0 1px rgba(16, 155, 101, .08);
}

.wallet-amount {
  font-weight: 900;
}

.wallet-top-up {
  color: var(--green);
  font-weight: 900;
}

.wallet-top-up::before {
  content: "+ ";
}

.icon-chip {
  width: 60px;
  padding: 0;
  justify-content: center;
  position: relative;
  border-radius: 50%;
}

.dot-badge {
  position: absolute;
  right: -4px;
  top: -5px;
  background: var(--green);
  color: #fff;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 900;
}

.notification-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 12px);
  z-index: 36;
  width: min(360px, calc(100vw - 32px));
  padding: 10px;
  border: 1px solid rgba(225, 232, 228, .95);
  border-radius: 22px;
  background:
    radial-gradient(circle at 88% 8%, rgba(16, 155, 101, .14), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(242, 251, 247, .96));
  box-shadow: 0 24px 54px rgba(17, 22, 29, .14);
  backdrop-filter: blur(16px);
}

.notification-menu::before {
  content: "";
  position: absolute;
  right: 24px;
  top: -7px;
  width: 14px;
  height: 14px;
  border-left: 1px solid rgba(225, 232, 228, .95);
  border-top: 1px solid rgba(225, 232, 228, .95);
  background: rgba(255, 255, 255, .98);
  transform: rotate(45deg);
}

.notification-menu-head {
  padding: 8px 10px 12px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
}

.notification-menu-head b {
  font-size: 17px;
}

.notification-menu-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.notification-menu button {
  width: 100%;
  min-height: 68px;
  border: 0;
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
  padding: 12px 48px 12px 40px;
  display: grid;
  gap: 3px;
  position: relative;
  text-align: left;
  color: var(--text);
}

.notification-menu button:hover {
  background: rgba(232, 247, 239, .94);
}

.notification-dot {
  position: absolute;
  left: 14px;
  top: 22px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 6px rgba(16, 155, 101, .1);
}

.notification-menu strong {
  font-size: 15px;
  font-weight: 950;
}

.notification-menu small,
.notification-empty {
  color: var(--muted);
  font-weight: 800;
}

.notification-count {
  position: absolute;
  right: 14px;
  top: 20px;
  min-width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--green);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
}

.notification-empty {
  padding: 18px 10px 14px;
  text-align: center;
}

.profile-avatar,
.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #efe8dc;
  display: grid;
  place-items: center;
  font-weight: 900;
  flex: 0 0 auto;
}

.profile-avatar {
  position: relative;
}

.profile-avatar::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--green);
  border: 2px solid #fff;
}

.mobile-menu-button {
  display: none;
  width: 54px;
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  font-weight: 900;
  font-size: 0;
  position: relative;
}

.mobile-menu-button::before,
.mobile-menu-button::after,
.mobile-menu-button span {
  content: "";
  width: 22px;
  height: 2px;
  border-radius: 999px;
  background: var(--text);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.mobile-menu-button::before {
  top: 18px;
  box-shadow: 0 8px 0 var(--text);
}
.mobile-menu-button span { top: 26px; }
.mobile-menu-button::after { top: 34px; }

.mobile-menu-button span:not(:first-child) {
  display: none;
}

.mobile-drawer {
  display: none;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 20px 48px rgba(17, 22, 29, .08);
  padding: 14px 18px 20px;
}

.mobile-drawer.open {
  display: grid;
  gap: 10px;
}

.mobile-drawer .nav-link {
  justify-content: flex-start;
  width: 100%;
}

.screen {
  max-width: var(--content-container);
  margin: 0 auto;
  padding: 34px 36px 64px;
}

.layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
}

.main-col,
.side-col { min-width: 0; }

.hero-card,
.panel,
.room-card,
.metric-card,
.auth-card,
.created-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.hero-card {
  min-height: 292px;
  padding: 30px;
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 26px;
  align-items: center;
  overflow: hidden;
  position: relative;
}

.hero-card::before {
  content: "";
  position: absolute;
  right: 220px;
  top: 60px;
  width: 145px;
  height: 145px;
  border-radius: 40px;
  background: radial-gradient(circle at 50% 50%, rgba(16, 155, 101, .22), rgba(16, 155, 101, .04) 65%, transparent 70%);
  transform: rotate(12deg);
}

.hero-left,
.hero-actions { position: relative; z-index: 1; }

.pill {
  min-height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  font-weight: 850;
  font-size: 13px;
  text-transform: uppercase;
}

.pill-green { background: var(--green-soft); color: var(--green-2); }
.pill-gray { background: #eef1f0; color: #65707b; }

.match-title-row {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 26px;
  flex-wrap: wrap;
}

.match-title-row h1 {
  font-size: 54px;
  line-height: 1;
  margin: 0 0 0 16px;
  letter-spacing: -.06em;
}

.vs-small {
  font-size: 22px;
  font-weight: 900;
  color: #6e7680;
}

.meta-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 22px;
  color: var(--muted);
  font-weight: 650;
  flex-wrap: wrap;
}

.dot-sep {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #89929e;
  display: inline-block;
  margin: 0 4px;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 34px;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
}

.stat-item {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 17px 18px;
  border-right: 1px solid var(--line);
}

.stat-item:last-child { border-right: 0; }
.stat-item span { display: block; color: var(--muted); font-size: 13px; font-weight: 750; text-transform: uppercase; }
.stat-item b { font-size: 21px; }

.stat-icon,
.metric-icon,
.activity-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--green-soft);
  color: var(--green);
  flex: 0 0 auto;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-self: center;
}

.hero-actions .btn { width: 100%; }

.btn {
  min-height: 54px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 850;
  letter-spacing: -.01em;
  transition: .15s ease;
}

.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--green); border-color: var(--green); color: #fff; box-shadow: 0 14px 24px rgba(16, 155, 101, .22); }
.btn-ghost { background: #fff; color: var(--green); border-color: var(--green); }
.room-leave-btn {
  color: #dc2438;
  border-color: rgba(220, 36, 56, .38);
  background:
    radial-gradient(circle at 86% 20%, rgba(220, 36, 56, .12), transparent 34%),
    rgba(255, 255, 255, .94);
}
.room-leave-btn:hover {
  border-color: rgba(220, 36, 56, .58);
  box-shadow: 0 14px 30px rgba(220, 36, 56, .14);
}
.btn-soft { background: var(--green-soft); color: var(--green-2); border-color: transparent; }
.btn.big { min-height: 76px; font-size: 20px; }
.btn.full { width: 100%; }
.btn:disabled { opacity: .55; cursor: default; transform: none; }
.btn.is-loading,
.chat-input button.is-loading {
  position: relative;
  overflow: hidden;
}
.btn.is-loading::after,
.chat-input button.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, .34) 42%, transparent 72%);
  transform: translateX(-100%);
  animation: buttonLoadingSweep 1.05s ease-in-out infinite;
}
@keyframes buttonLoadingSweep {
  to { transform: translateX(100%); }
}

.steps-strip {
  background: linear-gradient(90deg, #f0fbf6, #f8fbfb);
  border: 1px solid #d7eee5;
  border-radius: 22px;
  padding: 24px 30px;
  margin-top: 22px;
  display: grid;
  gap: 20px;
}

.steps-strip.two { grid-template-columns: 1fr 1fr; }
.flow-block h3 { margin: 0 0 18px; text-align: center; color: var(--green-2); font-size: 21px; }
.step-flow {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) 34px minmax(120px, 1fr) 34px minmax(120px, 1fr);
  align-items: start;
  justify-items: center;
  max-width: 720px;
  margin: 0 auto;
  gap: 18px;
}
.step-flow > span {
  width: 100%;
  display: grid;
  place-items: center;
  gap: 8px;
  font-weight: 850;
  text-align: center;
}
.step-flow > span .svg-icon { width: 58px; height: 58px; padding: 14px; border-radius: 50%; background: #fff; color: var(--green); box-shadow: var(--shadow-soft); }
.step-flow > .svg-icon {
  align-self: flex-start;
  color: #97a09b;
  width: 28px;
  height: 58px;
  padding: 15px 0;
}

.section-head,
.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.section-head { margin: 28px 4px 14px; }
.section-head h2,
.panel h2 { margin: 0; font-size: 24px; letter-spacing: -.03em; }
.section-head a,
.panel-title-row a { color: var(--green); font-weight: 850; display: flex; align-items: center; gap: 6px; }

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

.room-card {
  padding: 22px;
}

.room-card.selected {
  border-color: var(--green);
  background: linear-gradient(180deg, #fff, #f5fffa);
}

.room-card.is-pending {
  opacity: .58;
  pointer-events: none;
  transform: scale(.995);
  transition: opacity .16s ease, transform .16s ease;
}

.room-card-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.room-card-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.room-card-action {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(213, 27, 42, .18);
  border-radius: 50%;
  background: #fff;
  color: #d51b2a;
  display: inline-grid;
  place-items: center;
  transition: transform .16s ease, background-color .16s ease, border-color .16s ease;
}
.room-card-action.is-archive {
  border-color: rgba(16, 155, 101, .2);
  color: var(--green);
}
.room-card-action:hover {
  transform: translateY(-1px);
  background: #fff5f6;
  border-color: rgba(213, 27, 42, .38);
}
.room-card-action.is-archive:hover {
  background: var(--green-soft);
  border-color: rgba(16, 155, 101, .38);
}
.room-card-action .svg-icon {
  width: 18px;
  height: 18px;
}
.room-chat-badge {
  min-width: 48px;
  height: 34px;
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(16, 155, 101, .95), rgba(9, 133, 88, .92));
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 950;
  box-shadow: 0 12px 28px rgba(16, 155, 101, .22);
}
.room-chat-badge .svg-icon {
  width: 15px;
  height: 15px;
}
.room-chat-badge b {
  line-height: 1;
}
.room-card-action:disabled {
  opacity: .55;
  cursor: wait;
}
.team-pair {
  min-width: 92px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.room-card .team-pair .flag {
  width: 40px;
  height: 40px;
}
.team-pair .flag + .flag { margin-left: 0; }
.status-chip {
  background: var(--green-soft);
  color: var(--green-2);
  border-radius: 999px;
  padding: 6px 12px;
  font-weight: 850;
  font-size: 12px;
  white-space: nowrap;
}
.status-chip.is-waiting {
  background: #eef4f1;
  color: #64716d;
}
.status-chip.is-open {
  background: var(--green-soft);
  color: var(--green-2);
}
.status-chip.is-warning {
  background: #fff4dc;
  color: #a26100;
}
.status-chip.is-closed {
  background: #f4f6f7;
  color: #6b7280;
}
.status-chip.is-settled {
  background: #101820;
  color: #fff;
}
.room-card h3 { font-size: 22px; margin: 18px 0 8px; }
.room-top-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}
.room-betting-pill {
  min-height: 46px;
  gap: 9px;
  padding: 8px 18px;
  text-transform: none;
  background:
    radial-gradient(circle at 90% 18%, rgba(16, 155, 101, .13), transparent 36%),
    var(--green-soft);
  color: var(--green-2);
}
.room-betting-pill .svg-icon {
  width: 19px;
  height: 19px;
}
.room-betting-pill b {
  font-size: 18px;
  color: var(--green);
  line-height: 1;
}
.room-betting-pill.is-ended {
  background:
    radial-gradient(circle at 88% 18%, rgba(100, 113, 109, .10), transparent 34%),
    #f2f5f4;
  color: #64716d;
}
.room-betting-pill.is-ended b {
  color: #64716d;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0;
}
.room-meta-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 10px;
}
.room-meta-badge {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border-radius: 999px;
  padding: 5px 10px;
  background: #f5f7f6;
  color: #64716d;
  font-size: 12px;
  font-weight: 850;
}
.room-meta-badge.is-public {
  background: var(--green-soft);
  color: var(--green-2);
}
.room-meta-badge .svg-icon {
  width: 16px;
  height: 16px;
}
.muted-line,
.hint,
.muted { color: var(--muted); }

.room-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin: 18px 0;
  padding: 16px 0;
  gap: 12px;
}

.room-stats span,
.metric-title,
.summary-lines span {
  display: block;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

.room-stats b { font-size: 18px; }

.room-terms-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: -4px 0 18px;
}
.room-terms-stats > div {
  min-width: 0;
  border: 1px solid rgba(16, 155, 101, .16);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(231, 246, 240, .82), rgba(255, 255, 255, .96));
  padding: 11px 12px;
}
.room-terms-stats > div:only-child {
  grid-column: 1 / -1;
}
.room-terms-stats span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.room-terms-stats b {
  display: block;
  margin-top: 3px;
  font-size: 18px;
  line-height: 1.22;
  overflow-wrap: anywhere;
  word-break: normal;
}

.room-card-outcomes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: -2px 0 18px;
}
.room-card-outcome {
  min-width: 0;
  border: 1px solid rgba(16, 155, 101, .14);
  border-radius: 13px;
  background:
    radial-gradient(circle at 88% 12%, rgba(16, 155, 101, .10), transparent 34%),
    linear-gradient(135deg, rgba(248, 252, 250, .94), rgba(255, 255, 255, .98));
  padding: 9px 10px;
}
.room-card-outcome span {
  display: block;
  min-height: 30px;
  color: #101820;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.18;
  overflow-wrap: anywhere;
}
.room-card-outcome b {
  display: block;
  margin-top: 7px;
  color: var(--green);
  font-size: 18px;
  font-weight: 950;
  line-height: 1;
}
.room-card-outcome em {
  display: inline-flex;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green-2);
  padding: 3px 7px;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.benefit-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  margin-top: 28px;
  padding: 20px 24px;
}

.rooms-screen {
  display: grid;
  gap: 24px;
}

.rooms-hero {
  border: 1px solid rgba(16, 155, 101, .22);
  border-radius: var(--radius);
  padding: 34px;
  background:
    radial-gradient(circle at 88% 18%, rgba(16, 155, 101, .20), transparent 30%),
    linear-gradient(135deg, rgba(255, 255, 255, .98), rgba(242, 253, 247, .90));
  box-shadow: var(--shadow-soft);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: end;
}

.rooms-hero h1 {
  margin: 22px 0 8px;
  font-size: 58px;
  line-height: .95;
  letter-spacing: -.06em;
}

.rooms-hero p {
  margin: 0;
  max-width: 680px;
  color: var(--muted);
  font-weight: 750;
  font-size: 18px;
}

.rooms-tabs {
  width: fit-content;
  display: grid;
  grid-template-columns: repeat(2, auto);
  gap: 10px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .84);
}

.rooms-tabs button {
  min-height: 52px;
  border: 0;
  border-radius: 14px;
  padding: 0 18px;
  background: transparent;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.rooms-tabs button.active {
  background: var(--green-soft);
  color: var(--green);
}

.rooms-panel {
  display: grid;
  gap: 16px;
}

.rooms-subsection-head {
  margin-top: 34px;
  padding-top: 18px;
  border-top: 1px solid rgba(11, 18, 32, .08);
}

.empty-room-panel {
  grid-column: 1 / -1;
  min-height: 158px;
  display: grid;
  place-content: center;
  justify-items: center;
  text-align: center;
  border: 1px dashed rgba(16, 155, 101, .32);
  border-radius: 20px;
  padding: 32px;
  background:
    radial-gradient(circle at 50% 0%, rgba(16, 155, 101, .12), transparent 42%),
    rgba(255, 255, 255, .76);
}

.empty-room-panel h2 {
  margin: 0 0 8px;
}

.empty-room-panel p {
  margin: 0;
  color: var(--muted);
  font-weight: 750;
}

.bets-overview-screen {
  max-width: 1500px;
}

.bets-hero {
  min-height: 270px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  padding: 38px 42px;
  border: 1px solid rgba(16, 155, 101, .22);
  border-radius: 24px;
  background:
    radial-gradient(circle at 88% 12%, rgba(16, 155, 101, .22), transparent 34%),
    radial-gradient(circle at 22% 100%, rgba(210, 244, 232, .62), transparent 36%),
    linear-gradient(135deg, rgba(255, 255, 255, .95), rgba(244, 253, 249, .92));
  box-shadow: 0 28px 80px rgba(17, 22, 29, .08);
  overflow: hidden;
  position: relative;
}

.bets-hero::after {
  content: "BM";
  position: absolute;
  right: 18px;
  bottom: -42px;
  color: rgba(16, 155, 101, .055);
  font-size: 190px;
  line-height: 1;
  font-weight: 950;
  letter-spacing: -.08em;
  pointer-events: none;
}

.bets-hero h1 {
  position: relative;
  z-index: 1;
  margin: 18px 0 8px;
  font-size: clamp(44px, 6vw, 84px);
  line-height: .94;
}

.bets-hero p {
  position: relative;
  z-index: 1;
  max-width: 760px;
  color: var(--muted);
  font-size: 21px;
  font-weight: 750;
}

.bets-hero .btn {
  position: relative;
  z-index: 1;
  min-width: 210px;
}

.history-hero {
  background:
    radial-gradient(circle at 86% 14%, rgba(16, 155, 101, .18), transparent 34%),
    radial-gradient(circle at 15% 100%, rgba(255, 255, 255, .92), transparent 42%),
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(238, 249, 244, .94));
}

.wallet-screen {
  max-width: 1500px;
}

.wallet-hero {
  min-height: 310px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
  align-items: stretch;
  gap: 24px;
  padding: 26px;
  border: 1px solid rgba(16, 155, 101, .24);
  border-radius: 28px;
  background:
    radial-gradient(circle at 88% 16%, rgba(16, 155, 101, .24), transparent 30%),
    radial-gradient(circle at 18% 100%, rgba(210, 244, 232, .72), transparent 38%),
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(243, 253, 249, .94));
  box-shadow: 0 28px 80px rgba(17, 22, 29, .08);
  overflow: hidden;
  position: relative;
}

.wallet-hero::after {
  content: "$";
  position: absolute;
  left: 44%;
  bottom: -86px;
  color: rgba(16, 155, 101, .06);
  font-size: 260px;
  line-height: 1;
  font-weight: 950;
  pointer-events: none;
}

.wallet-hero-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12px 10px 12px 16px;
}

.wallet-hero h1 {
  margin: 18px 0 10px;
  font-size: clamp(48px, 7vw, 92px);
  line-height: .92;
}

.wallet-hero p {
  max-width: 760px;
  color: var(--muted);
  font-size: 21px;
  font-weight: 750;
}

.wallet-balance-card {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: center;
  gap: 14px;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, .72);
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .86), rgba(246, 253, 250, .72));
  box-shadow: 0 22px 60px rgba(16, 155, 101, .14);
  backdrop-filter: blur(18px);
}

.wallet-balance-card > span {
  color: var(--muted);
  font-weight: 900;
}

.wallet-balance-card strong {
  display: block;
  color: var(--text);
  font-size: clamp(44px, 6vw, 68px);
  line-height: .95;
  font-weight: 950;
}

.wallet-balance-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.wallet-operation-list {
  display: grid;
  gap: 14px;
}

.wallet-operation {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .08), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(250, 253, 252, .94));
  box-shadow: var(--shadow-soft);
}

.wallet-operation.is-debit {
  background:
    radial-gradient(circle at 100% 0%, rgba(235, 87, 87, .08), transparent 32%),
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(253, 250, 250, .94));
}

.wallet-operation-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  color: var(--green);
  background: var(--green-soft);
}

.wallet-operation.is-debit .wallet-operation-icon {
  color: #b94949;
  background: rgba(235, 87, 87, .10);
}

.wallet-operation-main {
  min-width: 0;
}

.wallet-operation-main b,
.wallet-operation-main span {
  display: block;
}

.wallet-operation-main b {
  font-size: 18px;
  font-weight: 950;
}

.wallet-operation-main span,
.wallet-operation-main p {
  color: var(--muted);
  font-weight: 750;
}

.wallet-operation-main p {
  margin: 6px 0 0;
  font-size: 14px;
}

.wallet-operation-right {
  display: grid;
  justify-items: end;
  gap: 6px;
}

.wallet-operation-right strong {
  font-size: 24px;
  font-weight: 950;
}

.wallet-operation.is-credit .wallet-operation-right strong {
  color: var(--green);
}

.wallet-operation.is-debit .wallet-operation-right strong {
  color: #b94949;
}

.wallet-operation-right time {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.wallet-side-card .side-stat-list b {
  font-size: 12px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 18%, rgba(16, 155, 101, .18), transparent 34%),
    rgba(9, 18, 28, .42);
  backdrop-filter: blur(14px);
}

.modal-panel {
  position: relative;
  max-height: calc(100vh - 48px);
  overflow: auto;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, .64);
  border-radius: 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .14), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, .96), rgba(246, 253, 250, .90));
  box-shadow: 0 30px 90px rgba(5, 12, 20, .28);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, .78);
  color: var(--text);
  font-size: 25px;
  line-height: 1;
  cursor: pointer;
}

.wallet-top-up-modal {
  width: min(500px, calc(100vw - 32px));
}

.wallet-top-up-modal h2 {
  margin: 14px 0 8px;
  font-size: 34px;
}

.wallet-top-up-modal p {
  color: var(--muted);
  font-weight: 750;
}

.top-up-presets {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 20px 0 4px;
}

.top-up-presets button {
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .76);
  color: var(--text);
  font-size: 16px;
  font-weight: 950;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.top-up-presets button:hover,
.top-up-presets button.active {
  transform: translateY(-2px);
  border-color: rgba(16, 155, 101, .42);
  background: var(--green-soft);
  color: var(--green);
}

.top-up-assets {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.top-up-assets button {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .78);
  color: var(--text);
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.top-up-assets button:not(:disabled):hover,
.top-up-assets button.active {
  transform: translateY(-2px);
  border-color: rgba(16, 155, 101, .42);
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .14), transparent 42%),
    var(--green-soft);
}

.top-up-assets button:disabled {
  cursor: default;
  color: var(--muted);
}

.top-up-asset-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff center / contain no-repeat;
  box-shadow: 0 8px 20px rgba(17, 22, 29, .10);
  flex: 0 0 auto;
}

.top-up-assets b,
.top-up-assets small {
  display: block;
}

.top-up-assets b {
  font-size: 14px;
  font-weight: 950;
}

.top-up-assets small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.top-up-invoice {
  display: grid;
  gap: 16px;
  margin-top: 18px;
}

.top-up-status-row {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(16, 155, 101, .20);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .14), transparent 42%),
    rgba(255, 255, 255, .72);
  color: var(--green);
  font-weight: 950;
}

.top-up-pulse {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 rgba(16, 155, 101, .34);
  animation: walletPulse 1.4s ease-out infinite;
}

.top-up-invoice.is-paid .top-up-status-row {
  color: var(--green);
  border-color: rgba(16, 155, 101, .34);
  background: var(--green-soft);
}

.top-up-invoice.is-failed .top-up-status-row {
  color: #b94949;
  border-color: rgba(185, 73, 73, .24);
  background: rgba(255, 241, 241, .76);
}

.top-up-invoice.is-paid .top-up-pulse,
.top-up-invoice.is-failed .top-up-pulse {
  animation: none;
}

.top-up-invoice.is-failed .top-up-pulse {
  background: #b94949;
}

.payment-instruction {
  padding: 18px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(17, 22, 29, .96), rgba(20, 38, 33, .94)),
    #11161d;
  color: #fff;
  box-shadow: 0 18px 42px rgba(17, 22, 29, .20);
}

.payment-instruction span,
.payment-instruction b,
.payment-instruction em {
  display: block;
}

.payment-instruction span {
  color: rgba(255, 255, 255, .72);
  font-size: 13px;
  font-weight: 850;
}

.payment-instruction b {
  margin-top: 5px;
  font-size: 30px;
  line-height: 1.05;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.payment-instruction em {
  margin-top: 6px;
  color: rgba(255, 255, 255, .70);
  font-style: normal;
  font-weight: 800;
}

.payment-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.payment-detail-grid div,
.payment-address-box {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
}

.payment-detail-grid span,
.payment-address-box span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.payment-detail-grid b,
.payment-address-box code {
  display: block;
  margin-top: 6px;
  color: var(--text);
  font-weight: 950;
  overflow-wrap: anywhere;
}

.payment-detail-grid b {
  font-size: 14px;
}

.payment-address-box code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
  line-height: 1.45;
}

.top-up-copy-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@keyframes walletPulse {
  0% { box-shadow: 0 0 0 0 rgba(16, 155, 101, .34); }
  100% { box-shadow: 0 0 0 14px rgba(16, 155, 101, 0); }
}

.overview-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin: 24px 0 10px;
}

.overview-metric-card {
  min-height: 118px;
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  gap: 16px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .96), rgba(248, 253, 251, .92));
  box-shadow: var(--shadow-soft);
}

.overview-metric-card > span {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--green-soft);
  color: var(--green);
}

.overview-metric-card small {
  display: block;
  color: var(--muted);
  font-weight: 900;
}

.overview-metric-card b {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 28px;
  font-weight: 950;
}

.overview-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

.overview-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.bet-item,
.overview-side-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .10), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(250, 253, 252, .95));
  box-shadow: var(--shadow-soft);
}

.bet-item {
  padding: 24px;
}

.bet-item.is-win {
  border-color: rgba(16, 155, 101, .42);
  background:
    radial-gradient(circle at 100% 0%, rgba(16, 155, 101, .18), transparent 36%),
    linear-gradient(145deg, rgba(247, 255, 252, .98), rgba(255, 255, 255, .96));
}

.bet-item.is-loss {
  background:
    radial-gradient(circle at 100% 0%, rgba(235, 87, 87, .10), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(253, 250, 250, .95));
}

.bet-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.bet-item h3 {
  margin: 18px 0 8px;
  font-size: 26px;
  line-height: 1.08;
}

.bet-item-pick {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 20px 0 0;
  padding: 14px 16px;
  border-radius: 16px;
  background: var(--green-soft);
}

.bet-item-pick span {
  color: var(--muted);
  font-weight: 850;
}

.bet-item-pick b {
  color: var(--green);
  font-weight: 950;
}

.bet-item-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin-top: 18px;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  overflow: hidden;
  border-radius: 16px;
}

.bet-item-grid div {
  padding: 14px 16px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .62);
}

.bet-item-grid span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.bet-item-grid b {
  display: block;
  margin-top: 5px;
  font-size: 20px;
  font-weight: 950;
}

.bet-note {
  margin: 14px 2px 18px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.overview-side {
  position: sticky;
  top: calc(var(--header-h) + 24px);
}

.overview-side-card {
  padding: 26px;
}

.overview-side-card h2 {
  margin: 0 0 12px;
  font-size: 26px;
}

.overview-side-card p {
  color: var(--muted);
  font-weight: 750;
  line-height: 1.45;
}

.side-stat-list {
  display: grid;
  gap: 0;
  margin: 18px 0 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
}

.side-stat-list div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, .72);
}

.side-stat-list div + div {
  border-top: 1px solid var(--line);
}

.side-stat-list span {
  color: var(--muted);
  font-weight: 850;
}

.side-stat-list b {
  text-align: right;
  font-weight: 950;
}

.overview-empty {
  min-height: 280px;
}

.metric-card {
  padding: 22px;
  display: flex;
  gap: 18px;
  align-items: center;
  box-shadow: none;
}

.metric-icon { width: 54px; height: 54px; }
.metric-icon .svg-icon { width: 28px; height: 28px; }
.metric-value { font-size: 28px; font-weight: 900; letter-spacing: -.04em; }
.metric-sub { color: var(--muted); font-weight: 600; margin-top: 3px; }

.panel { padding: 28px; }
.side-col { display: flex; flex-direction: column; gap: 20px; }

.activity-row {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.activity-row:last-of-type { border-bottom: 0; }
.activity-icon { width: 48px; height: 48px; }
.activity-row b,
.activity-row span { display: block; }
.activity-row span,
.activity-row time { color: var(--muted); }
.activity-row time { font-size: 13px; }

.mini-bet {
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.mini-bet b,
.mini-bet span { display: block; }
.mini-bet span { color: var(--muted); }

.auth-wrap {
  min-height: calc(100vh - 92px);
  display: grid;
  place-items: center;
  padding: 34px 18px;
}

.auth-card {
  width: min(560px, 100%);
  padding: 30px;
}

.auth-card h1 {
  margin: 0 0 8px;
  font-size: 42px;
  letter-spacing: -.05em;
}

.field {
  display: grid;
  gap: 8px;
  margin: 16px 0;
}

.field span {
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}

.field input,
.field select {
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 0 16px;
}

.field select {
  appearance: none;
  padding-right: 46px;
  font-weight: 800;
  color: var(--muted);
  background:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%) right 20px center / 7px 7px no-repeat,
    linear-gradient(135deg, var(--muted) 50%, transparent 50%) right 14px center / 7px 7px no-repeat,
    #fff;
}

.field select:focus,
.field input:focus {
  outline: 0;
  border-color: rgba(16, 155, 101, .65);
  box-shadow: 0 0 0 4px rgba(16, 155, 101, .1);
}

.subtle-action {
  border: 0;
  background: transparent;
  color: var(--green);
  font-weight: 850;
  margin-top: 12px;
}

.status {
  min-height: 22px;
  margin-top: 14px;
  font-weight: 750;
}

.status.error { color: #d51b2a; }
.status.ok { color: var(--green); }

.toast-stack {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 80;
  width: min(620px, calc(100vw - 28px));
  display: grid;
  gap: 10px;
  pointer-events: none;
}

.toast-panel {
  min-height: 54px;
  border-radius: 18px;
  padding: 14px 16px 14px 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  align-items: center;
  gap: 12px;
  border: 1px solid rgba(213, 27, 42, .32);
  background:
    radial-gradient(circle at 94% 10%, rgba(213, 27, 42, .12), transparent 36%),
    linear-gradient(135deg, rgba(255, 244, 246, .98), rgba(255, 255, 255, .96));
  color: #d51b2a;
  box-shadow: 0 22px 48px rgba(17, 22, 29, .14);
  backdrop-filter: blur(16px);
  font-weight: 900;
  pointer-events: auto;
  animation: toast-in .18s ease-out;
}

.toast-panel.is-warning {
  border-color: rgba(176, 114, 0, .32);
  background:
    radial-gradient(circle at 94% 10%, rgba(245, 174, 45, .18), transparent 36%),
    linear-gradient(135deg, rgba(255, 248, 232, .98), rgba(255, 255, 255, .96));
  color: #946000;
}

.toast-panel span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.toast-close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .74);
  color: currentColor;
  display: grid;
  place-items: center;
  font-size: 22px;
  line-height: 1;
  font-weight: 900;
}

.toast-close svg,
.share-sheet-close svg {
  width: 18px;
  height: 18px;
  display: block;
}

.toast-close path,
.share-sheet-close path {
  fill: none;
  stroke: currentColor;
  stroke-width: 2.8;
  stroke-linecap: round;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(-10px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes loadingPulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50% { transform: translate(-50%, -50%) scale(1.045); }
}

@keyframes loadingShimmer {
  from { background-position: -180px 2px, 50% 2px; }
  to { background-position: calc(100% + 180px) 2px, 50% 2px; }
}

.profile-screen {
  display: grid;
  gap: 22px;
}

.profile-hero {
  min-height: 230px;
  padding: 30px;
  border: 1px solid rgba(16, 155, 101, .2);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 82% 22%, rgba(16, 155, 101, .18), transparent 30%),
    linear-gradient(135deg, #ffffff 0%, #f3fbf7 46%, #ffffff 100%);
  box-shadow: var(--shadow-soft);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  overflow: hidden;
  position: relative;
}

.profile-hero::after {
  content: "BM";
  position: absolute;
  right: -18px;
  bottom: -56px;
  color: rgba(16, 155, 101, .055);
  font-size: 170px;
  font-weight: 950;
  line-height: 1;
  pointer-events: none;
}

.profile-hero > * {
  position: relative;
  z-index: 1;
}

.profile-hero h1 {
  margin: 18px 0 8px;
  font-size: clamp(42px, 6vw, 72px);
  line-height: .95;
  letter-spacing: 0;
}

.profile-hero p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
  font-weight: 750;
}

.profile-identity {
  min-width: 280px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, .76);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 18px 38px rgba(17, 22, 29, .06);
}

.profile-avatar.xl {
  width: 72px;
  height: 72px;
  font-size: 24px;
}

.profile-identity b,
.profile-identity span {
  display: block;
}

.profile-identity b {
  font-size: 22px;
  line-height: 1.1;
}

.profile-identity span {
  color: var(--muted);
  font-weight: 750;
  overflow-wrap: anywhere;
}

.profile-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.profile-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-soft);
}

.profile-card-head {
  min-height: 82px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 14px;
  margin-bottom: 12px;
}

.profile-card h2 {
  margin: 0 0 4px;
  font-size: 22px;
}

.profile-card p {
  margin: 0;
  color: var(--muted);
  font-weight: 750;
}

.profile-card .hint {
  margin: 10px 0 0;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--green);
  font-weight: 850;
  margin: 8px 0 24px;
}

.access-modal {
  width: min(1160px, 100%);
  margin: 0 auto;
  background: #fff;
  padding: 58px;
  border-radius: 24px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  text-align: center;
}

.access-modal h1 {
  font-size: 44px;
  letter-spacing: -.05em;
  margin: 18px 0 8px;
}

.access-modal > p {
  font-size: 21px;
  color: var(--muted);
  margin: 0;
}

.large-circle {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
}

.large-circle .svg-icon {
  width: 48px;
  height: 48px;
}

.preview-match {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 26px;
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  gap: 20px;
  align-items: center;
  text-align: left;
  margin: 34px auto;
  max-width: 880px;
  background: linear-gradient(180deg, #fff, #fbfefc);
}

.preview-match.large {
  grid-template-columns: auto auto auto 1fr;
}

.preview-match h2 {
  font-size: 34px;
  margin: 0;
  letter-spacing: -.04em;
}

.preview-match p {
  margin: 8px 0 0;
  color: var(--muted);
}

.summary-lines {
  margin-top: 22px;
}

.summary-lines > div,
.info-lines > div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  padding: 13px 0;
  text-align: left;
}

.summary-lines > div:last-child,
.info-lines > div:last-child {
  border-bottom: 0;
}

.summary-lines.compact {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  margin-top: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  background: #fff;
}

.summary-lines.compact > div {
  display: block;
  border-bottom: 0;
  border-right: 1px solid var(--line);
  padding: 18px 16px;
}

.summary-lines.compact > div:last-child {
  border-right: 0;
}

.summary-lines b,
.info-lines b {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.invite-terms,
.invite-auth {
  width: min(720px, 100%);
  margin: 24px auto 0;
  text-align: left;
}

.outcome-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.outcome-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--green-soft-2);
  color: var(--green-2);
  font-size: 13px;
  font-weight: 850;
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 24px;
}

.action-row.small {
  width: min(720px, 100%);
  margin-left: auto;
  margin-right: auto;
}

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

.room-layout,
.bet-layout,
.result-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 440px;
  gap: 28px;
  align-items: start;
}

.room-main-col,
.bet-main {
  min-width: 0;
}

.room-side {
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-width: 0;
}

.room-top,
.chat-panel,
.table-card,
.result-hero,
.mini-event-head {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.setup-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
}

.setup-workflow {
  display: grid;
  gap: 28px;
}

.create-stepper {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 28px;
  align-items: start;
}

.create-stepper div {
  min-height: 96px;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 14px;
  position: relative;
  color: var(--muted);
  font-weight: 900;
  cursor: pointer;
}

.create-stepper div:not(:last-child)::after {
  content: "";
  position: absolute;
  left: calc(50% + 70px);
  right: calc(-50% + 70px);
  top: 30px;
  height: 1px;
  background: #cad6d0;
}

.create-stepper span {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  font-size: 22px;
}

.create-stepper .active,
.create-stepper .done {
  color: var(--green);
}

.create-stepper .active span,
.create-stepper .done span {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.setup-main {
  min-height: 560px;
  border: 1px solid rgba(16, 155, 101, .22);
  border-radius: var(--radius);
  padding: 34px;
  background:
    radial-gradient(circle at 88% 10%, rgba(16, 155, 101, .18), transparent 28%),
    linear-gradient(145deg, rgba(255, 255, 255, .98), rgba(244, 252, 248, .96));
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}

.setup-main::after {
  content: "BM";
  position: absolute;
  right: -12px;
  bottom: -52px;
  color: rgba(16, 155, 101, .055);
  font-size: 220px;
  line-height: 1;
  font-weight: 950;
  letter-spacing: -.08em;
  pointer-events: none;
}

.setup-main > * {
  position: relative;
  z-index: 1;
}

.setup-main h1 {
  margin: 22px 0 8px;
  font-size: 68px;
  line-height: .95;
  letter-spacing: -.06em;
}

.setup-step h1 {
  font-size: 34px;
  line-height: 1.05;
  margin: 0 0 26px;
  letter-spacing: -.04em;
}

.search-field {
  min-height: 66px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
}

.search-field input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 19px;
  font-weight: 800;
}

.segmented,
.chip-row,
.share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.segmented {
  margin: 22px 0;
}

.segmented button,
.chip-row button,
.share-row button {
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 0 22px;
  font-weight: 900;
  transition: border-color .16s ease, background .16s ease, color .16s ease, transform .16s ease;
}

.segmented button.active,
.chip-row button.selected {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.chip-row button.selected {
  background: var(--green-soft);
  color: var(--green);
}

.stake-mode-toggle {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 6px;
  border: 1px solid rgba(0, 160, 98, .16);
  border-radius: 18px;
  background:
    radial-gradient(circle at 0 0, rgba(0, 160, 98, .14), transparent 42%),
    rgba(246, 253, 250, .82);
}

.stake-mode-toggle button,
.stake-stepper button {
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: rgba(255, 255, 255, .86);
  color: var(--ink);
  font-weight: 950;
}

.stake-mode-toggle button.selected {
  background: var(--green);
  color: #fff;
  box-shadow: 0 14px 30px rgba(0, 160, 98, .18);
}

.stake-stepper {
  width: min(360px, 100%);
  min-height: 64px;
  display: grid;
  grid-template-columns: 56px 1fr 56px;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border: 1px solid rgba(0, 160, 98, .22);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(232, 249, 242, .92), rgba(255, 255, 255, .9)),
    rgba(255, 255, 255, .82);
  box-shadow: 0 18px 44px rgba(18, 34, 28, .08);
}

.stake-stepper strong {
  text-align: center;
  font-size: 24px;
  font-weight: 950;
}

.stake-stepper button {
  font-size: 24px;
  color: var(--green);
  cursor: pointer;
}

.setup-stake-stepper,
.stake-mode-note {
  margin-top: 12px;
}

.setup-match-list {
  display: grid;
  gap: 18px;
}

.setup-match-list + .btn {
  margin-top: 24px;
}

.setup-match-list + .btn + .setup-next {
  margin-top: 18px;
}

.setup-match-option {
  width: 100%;
  min-height: 106px;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px;
  background: #fff;
  display: grid;
  grid-template-columns: auto 1fr auto 36px;
  align-items: center;
  gap: 18px;
  text-align: left;
  position: relative;
}

.setup-match-option.selected {
  border-color: var(--green);
  background: var(--green-soft-2);
}

.setup-match-option b,
.setup-match-option em {
  display: block;
}

.setup-match-option b {
  font-size: 20px;
}

.setup-match-option em {
  color: var(--muted);
  font-style: normal;
  font-weight: 700;
  margin-top: 3px;
}

.setup-match-option i {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  display: grid;
  place-items: center;
  justify-self: end;
}

.setup-next {
  margin-top: 18px;
}

.setup-option-block {
  margin: 26px 0;
}

.setup-option-block h2,
.setup-step > h2 {
  margin: 0 0 12px;
  font-size: 20px;
  letter-spacing: -.02em;
}

.setup-option-block p {
  margin: 14px 0 0;
  color: var(--muted);
  font-weight: 700;
  font-size: 17px;
}

.setup-field-popover {
  width: fit-content;
  max-width: 100%;
  margin-top: 12px;
  padding: 11px 14px;
  border: 1px solid rgba(213, 27, 42, .24);
  border-radius: 14px;
  background:
    radial-gradient(circle at 12% 0%, rgba(213, 27, 42, .12), transparent 38%),
    rgba(255, 245, 246, .96);
  color: #d51b2a;
  box-shadow: 0 14px 32px rgba(213, 27, 42, .12);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.35;
}

.access-choice {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  min-height: 118px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 18px;
  align-items: center;
  background: #fff;
  cursor: pointer;
}

.access-choice + .access-choice {
  margin-top: 18px;
}

#setupPublishBlock.hidden + .access-choice {
  margin-top: 18px;
}

.access-choice.selected {
  border-color: var(--green);
  background: var(--green-soft-2);
}

.access-choice > .svg-icon {
  color: var(--green);
}

.access-choice p {
  margin: 3px 0 0;
}

.access-choice > span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid var(--line);
}

.access-choice.selected > span {
  border-color: var(--green);
  background: var(--green);
}

.publish-check {
  margin: 10px 0 12px;
  border: 1px dashed rgba(16, 155, 101, .45);
  border-radius: 14px;
  padding: 14px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--green);
  background: rgba(231, 246, 240, .52);
}

.publish-check input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--green);
}

.publish-check span,
.publish-check b,
.publish-check em {
  display: block;
}

.publish-check b {
  font-weight: 900;
}

.publish-check em {
  margin-top: 4px;
  color: var(--muted);
  font-style: normal;
  font-weight: 700;
  line-height: 1.35;
}

.setup-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 28px;
}

.room-code-large,
.invite-link-box {
  width: 100%;
  border: 1px solid var(--green);
  border-radius: 18px;
  background: var(--green-soft-2);
  min-height: 92px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--green);
}

.room-code-large b {
  font-size: 42px;
  letter-spacing: .06em;
}

#setupStepInvite .room-code-large {
  margin-bottom: 28px;
}

#setupStepInvite .muted {
  margin: 0 0 24px;
}

.invite-link-box {
  justify-content: space-between;
  min-height: 66px;
  background: #fff;
  color: var(--muted);
  border-color: var(--line);
  font-weight: 850;
}

.invite-link-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 20px;
}

.invite-link-actions .invite-link-box {
  margin-bottom: 0;
}

.invite-link-box span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.share-invite-btn {
  height: 66px;
  min-height: 0;
  border: 1px solid var(--green);
  border-radius: 18px;
  background: var(--green-soft);
  color: var(--green);
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 900;
  align-self: center;
  white-space: nowrap;
}

.invite-link-box b,
.share-row button {
  color: var(--green);
}

.share-sheet {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(17, 22, 29, .32);
  backdrop-filter: blur(10px);
}

.share-sheet-panel {
  width: min(460px, 100%);
  border: 1px solid rgba(16, 155, 101, .18);
  border-radius: 22px;
  background:
    radial-gradient(circle at 90% 8%, rgba(16, 155, 101, .14), transparent 30%),
    #fff;
  box-shadow: var(--shadow);
  padding: 24px;
  position: relative;
}

.share-sheet-panel h2 {
  margin: 0 42px 6px 0;
  font-size: 28px;
}

.share-sheet-panel p {
  margin: 0 0 18px;
  color: var(--muted);
  font-weight: 700;
}

.share-link-copy {
  width: 100%;
  min-height: 62px;
  margin: 0 0 12px;
  border: 1px solid rgba(16, 155, 101, .22);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(16, 155, 101, .08), rgba(255, 255, 255, .92)),
    #fff;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  text-align: left;
  box-shadow: 0 16px 36px rgba(20, 30, 25, .07);
}

.share-link-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text);
  font-weight: 800;
}

.share-link-copy b {
  color: var(--green);
  font-size: 13px;
  text-transform: uppercase;
}

.share-link-copy.is-copied {
  border-color: rgba(16, 155, 101, .42);
  background:
    linear-gradient(135deg, rgba(16, 155, 101, .16), rgba(232, 247, 239, .96)),
    #fff;
  box-shadow: 0 18px 42px rgba(16, 155, 101, .16);
}

.share-link-copy.is-copied b {
  color: #fff;
  background: var(--green);
  border-radius: 999px;
  padding: 8px 12px;
}

.share-sheet-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--text);
  display: grid;
  place-items: center;
}

.share-sheet-actions {
  display: grid;
  gap: 10px;
}

.share-sheet-actions button {
  min-height: 58px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  padding: 0 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--green);
  font-weight: 900;
}

.share-qr-panel {
  margin-top: 14px;
  padding: 18px;
  border: 1px solid rgba(16, 155, 101, .18);
  border-radius: 20px;
  background:
    radial-gradient(circle at 50% 10%, rgba(16, 155, 101, .12), transparent 52%),
    rgba(244, 251, 248, .86);
  text-align: center;
}

.share-qr-panel img {
  display: block;
  width: min(260px, 100%);
  aspect-ratio: 1;
  margin: 0 auto 12px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(20, 30, 25, .1);
}

.share-qr-panel p {
  margin: 0;
  font-size: 14px;
}

.known-invite-block {
  margin-top: 24px;
}

.known-invite-block h2 {
  margin-bottom: 6px;
}

.known-invite-block p {
  margin: 0 0 14px;
  color: var(--muted);
  font-weight: 700;
}

.known-invite-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.known-invite-list button {
  min-height: 72px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  padding: 12px;
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 12px;
  align-items: center;
  text-align: left;
}

.known-invite-list button.selected {
  border-color: var(--green);
  background: linear-gradient(135deg, rgba(16, 155, 101, .13), rgba(16, 155, 101, .05));
  box-shadow: 0 16px 34px rgba(16, 155, 101, .12);
}

.known-invite-list .avatar {
  grid-row: span 2;
}

.known-invite-list b,
.known-invite-list em {
  display: block;
}

.known-invite-list b {
  font-weight: 900;
}

.known-invite-list em {
  color: var(--green);
  font-style: normal;
  font-weight: 800;
  font-size: 13px;
}

.setup-summary-match {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr) 60px;
  align-items: center;
  gap: 10px;
  text-align: center;
  overflow: hidden;
}

.setup-summary-match > div {
  min-width: 0;
}

.setup-summary-match .flag {
  width: 58px;
  height: 58px;
}

.setup-summary-match h3 {
  margin: 2px 0;
  font-size: 22px;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.setup-summary-match span,
.setup-summary-match p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.setup-main > p {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
  font-weight: 700;
  font-size: 19px;
}

.setup-match-card {
  margin-top: 30px;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 22px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 20px;
  align-items: center;
  background: rgba(255, 255, 255, .78);
  backdrop-filter: blur(12px);
}

.setup-match-card h2 {
  margin: 4px 0;
  font-size: 32px;
  line-height: 1;
  letter-spacing: -.04em;
}

.setup-match-card span,
.setup-match-card p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.setup-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.public-toggle {
  margin-top: 22px;
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 18px 20px;
  display: grid;
  grid-template-columns: auto auto 1fr;
  gap: 14px;
  align-items: center;
  background: rgba(255, 255, 255, .82);
  cursor: pointer;
}

.public-toggle input {
  width: 22px;
  height: 22px;
  accent-color: var(--green);
}

.public-toggle > span {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--green);
  background: var(--green-soft);
}

.public-toggle b {
  display: block;
  font-size: 19px;
  letter-spacing: -.02em;
}

.public-toggle em {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-style: normal;
  font-weight: 700;
}

.setup-side {
  position: sticky;
  top: 134px;
  display: grid;
  gap: 18px;
}

.setup-steps {
  display: grid;
  gap: 10px;
}

.setup-steps div {
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
}

.setup-steps span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #eef1f0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.setup-steps .done span,
.setup-steps .active span {
  background: var(--green);
  color: #fff;
}

.setup-steps .active {
  border-color: rgba(16, 155, 101, .35);
  background: var(--green-soft-2);
}

.room-top {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  padding: 32px;
  overflow: hidden;
}

.match-title-room {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 28px;
  flex-wrap: wrap;
}

.match-title-room h1 {
  font-size: 52px;
  line-height: 1;
  margin: 0;
  letter-spacing: -.06em;
  max-width: 520px;
}

.match-title-room span {
  font-size: 22px;
  font-weight: 900;
  color: #6e7680;
}

.room-control {
  display: grid;
  gap: 18px;
}

.room-info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  align-items: stretch;
}

.room-actions-panel {
  border-top: 1px solid var(--line);
  padding-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.room-code {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  background: #fff;
  text-align: left;
  min-width: 0;
}

.room-code.as-button {
  cursor: pointer;
  grid-column: span 2;
}

.room-code span,
.countdown span {
  display: block;
  color: var(--muted);
  font-weight: 750;
  font-size: 13px;
}

.room-code b {
  display: inline-block;
  font-size: 21px;
  margin-top: 4px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.room-code .svg-icon {
  width: 18px;
  height: 18px;
  color: var(--muted);
  margin-left: 6px;
}

.countdown {
  border: 1px solid rgba(16, 155, 101, .22);
  border-radius: 14px;
  padding: 14px;
  background: linear-gradient(135deg, rgba(16, 155, 101, .11), rgba(255, 255, 255, .86));
}

.countdown.is-ended {
  border-color: rgba(100, 113, 109, .20);
  background: linear-gradient(135deg, rgba(244, 246, 247, .94), rgba(255, 255, 255, .96));
}

.countdown b {
  display: block;
  font-size: 34px;
  color: var(--green);
  letter-spacing: -.04em;
}

.countdown.is-ended b {
  color: #64716d;
  font-size: 20px;
  line-height: 1.18;
  letter-spacing: 0;
  margin-top: 10px;
}

.room-actions-panel .btn {
  min-height: 64px;
  width: 100%;
}

.outcomes-grid {
  display: grid;
  gap: 22px;
  margin-top: 34px;
}

.outcomes-grid.three {
  grid-template-columns: repeat(3, 1fr);
}

.outcome-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  box-shadow: var(--shadow-soft);
  min-height: 218px;
  cursor: default;
}

.outcome-card[onclick] {
  cursor: pointer;
}

.outcome-card.selected {
  border-color: var(--green);
  background: linear-gradient(180deg, #f5fffa, #fff);
  padding-top: 36px;
}

.card-check {
  position: absolute;
  right: 18px;
  top: -14px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  display: grid;
  place-items: center;
  border: 4px solid #fff;
  box-shadow: 0 12px 24px rgba(16, 155, 101, .22);
}

.outcome-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
}

.outcome-head h3 {
  margin: 0;
  font-size: 24px;
  letter-spacing: -.03em;
}

.pool-pill,
.pick {
  border-radius: 999px;
  padding: 6px 10px;
  font-weight: 850;
  font-size: 12px;
}

.pool-pill,
.pick-green {
  background: var(--green-soft);
  color: var(--green-2);
}

.pick-blue {
  background: #e9f1ff;
  color: #2e6fd0;
}

.pick-gray {
  background: #eef1f0;
  color: #67717d;
}

.outcome-line {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: 14px;
}

.outcome-line span {
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

.chat-panel {
  padding: 28px;
  margin-top: 28px;
}

.chat-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.chat-row {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 10px 12px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  background: #fff;
}

.chat-row.mine {
  background: var(--green-soft-2);
  border-color: #d5eee3;
}

.chat-avatar {
  grid-row: span 2;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #efe8dc;
  display: grid;
  place-items: center;
  font-weight: 900;
}

.chat-row b,
.chat-row p {
  margin: 0;
}

.chat-row time {
  color: var(--muted);
  font-size: 13px;
}

.chat-input {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  margin-top: 18px;
}

.chat-input input {
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 16px;
}
.chat-input input:disabled {
  color: var(--muted);
  background: rgba(244, 249, 247, .92);
}

.chat-input button {
  min-height: 54px;
  border: 0;
  border-radius: 14px;
  background: var(--green);
  color: #fff;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 850;
}
.chat-input button:disabled {
  cursor: default;
  opacity: .78;
  transform: none;
}

.person-row {
  display: grid;
  grid-template-columns: 42px 1fr auto auto;
  gap: 12px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

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

.person-row b,
.person-row span {
  display: block;
}

.person-row span {
  color: var(--muted);
}

.person-row > .avatar {
  display: grid;
  place-items: center;
  line-height: 1;
  text-align: center;
}

.bet-layout {
  grid-template-columns: minmax(0, 1120px);
  justify-content: center;
  gap: 28px;
}

.bet-main .outcomes-grid.three {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}

.mini-event-head {
  padding: 28px 32px 30px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  position: relative;
  overflow: hidden;
}

.mini-event-head::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 88% 16%, rgba(14, 165, 112, .13), transparent 34%),
    linear-gradient(135deg, rgba(255,255,255,.94), rgba(238, 252, 247, .68));
}

.mini-event-head > * {
  position: relative;
  z-index: 1;
}

.mini-event-flags {
  display: flex;
  align-items: center;
  gap: 14px;
}

.mini-event-flags span {
  color: var(--muted);
  font-weight: 900;
  font-size: 18px;
}

.mini-event-head h1 {
  margin: 0;
  max-width: 620px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: .98;
  letter-spacing: 0;
}

.mini-event-head p {
  margin: -6px 0 0;
  color: var(--muted);
  font-size: 18px;
  font-weight: 700;
}

.large-title {
  margin: 42px 0 18px;
  font-size: 50px;
  line-height: 1;
  letter-spacing: -.06em;
}

.bet-side {
  position: static;
  align-self: start;
  width: 100%;
  max-width: 1120px;
  display: grid;
  grid-template-columns: minmax(240px, 320px) minmax(0, 1fr);
  gap: 18px 24px;
  align-items: start;
}

.bet-side h2 {
  grid-column: 1 / -1;
}

.bet-side .amount-input {
  grid-column: 1;
}

.bet-side .bet-summary {
  grid-column: 2;
  grid-row: 2 / span 2;
  margin: 0;
}

.bet-side .btn {
  grid-column: 1;
}

.bet-side .terms {
  grid-column: 1 / -1;
}

.amount-input {
  height: 70px;
  border: 1px solid var(--line);
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 20px;
  margin: 10px 0 20px;
}

.amount-input span,
.amount-input b {
  font-size: 26px;
}

.amount-input .svg-icon {
  margin-left: auto;
  color: #fff;
  background: var(--green);
  border-radius: 50%;
  padding: 4px;
}

.bet-summary {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
  margin: 10px 0 20px;
}

.bet-summary > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}

.bet-summary > div:last-child {
  border-bottom: 0;
}

.bet-summary span {
  color: var(--muted);
}

.bet-summary .receive {
  background: var(--green-soft-2);
  margin: 12px -6px -6px;
  padding: 14px;
  border-radius: 10px;
}

.bet-summary strong {
  font-size: 24px;
  color: var(--green);
}

.terms {
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.result-hero {
  padding: 28px;
  display: grid;
  grid-template-columns: 1fr 560px;
  gap: 28px;
  align-items: center;
}

.winner-box {
  background: var(--green-soft-2);
  border: 1px solid #d5eee3;
  border-radius: 18px;
  text-align: center;
  padding: 28px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
}

.winner-box span,
.winner-box p {
  grid-column: 1 / -1;
}

.winner-box span {
  text-transform: uppercase;
  color: var(--green);
  font-weight: 900;
}

.winner-box h1 {
  font-size: 42px;
  margin: 0;
}

.winner-box p {
  margin: 0;
  color: var(--muted);
  font-size: 20px;
}

.result-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  margin: 26px 0;
}

.result-grid {
  grid-template-columns: minmax(0, 1fr) 480px;
  gap: 32px;
}

.panel.big {
  padding: 28px;
}

.winner-row {
  display: grid;
  grid-template-columns: 34px 1fr auto auto;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.winner-row > span:first-child {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: var(--muted);
}

.winner-row em {
  background: var(--green-soft);
  color: var(--green);
  border-radius: 999px;
  padding: 4px 8px;
  font-style: normal;
  font-size: 12px;
  font-weight: 850;
}

.winner-row strong {
  color: var(--green);
  font-size: 20px;
}

@media (max-width: 1760px) {
  .header-inner {
    gap: 22px;
    padding-left: 28px;
    padding-right: 28px;
  }

  .brand-link {
    gap: 14px;
  }

  .brand-mark {
    width: 52px;
    height: 52px;
  }

  .brand-name {
    font-size: 32px;
  }

  .top-nav {
    gap: 10px;
  }

  .nav-link {
    min-height: 54px;
    padding: 0 14px;
  }

  .wallet-chip,
  .profile-chip,
  .icon-chip {
    min-height: 54px;
    border-radius: 18px;
    padding-left: 14px;
    padding-right: 14px;
  }

  .icon-chip {
    width: 54px;
  }

  .profile-chip b {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

@media (max-width: 1560px) and (min-width: 1200px) {
  .room-layout {
    grid-template-columns: minmax(0, 1fr) minmax(360px, 390px);
    gap: 22px;
  }

  .room-top {
    padding: 28px;
  }

  .outcomes-grid {
    gap: 16px;
  }

  .outcomes-grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .outcome-card {
    padding: 22px 20px;
    min-height: 210px;
    border-radius: 18px;
  }

  .outcome-card.selected {
    padding-top: 32px;
  }

  .outcome-head {
    gap: 10px;
  }

  .outcome-head .flag {
    width: 42px;
    height: 42px;
    min-width: 42px;
  }

  .outcome-head h3 {
    min-width: 0;
    font-size: 21px;
    line-height: 1.05;
    overflow-wrap: anywhere;
  }

  .pool-pill {
    padding: 5px 9px;
    font-size: 11px;
  }

  .outcome-line {
    gap: 10px;
  }

  .header-inner {
    gap: 14px;
    padding-left: 18px;
    padding-right: 18px;
  }

  .brand-link {
    gap: 10px;
  }

  .brand-mark {
    width: 46px;
    height: 46px;
    border-radius: 14px;
  }

  .brand-name {
    font-size: 28px;
  }

  .top-nav {
    gap: 4px;
  }

  .nav-link {
    min-height: 48px;
    gap: 6px;
    padding: 0 8px;
    border-radius: 14px;
    font-size: 14px;
  }

  .nav-link .svg-icon {
    width: 18px;
    height: 18px;
  }

  .nav-link.active::after {
    left: 10px;
    right: 10px;
    bottom: -20px;
  }

  .header-actions {
    gap: 8px;
  }

  .wallet-chip,
  .profile-chip,
  .icon-chip {
    min-height: 48px;
    height: 48px;
    border-radius: 15px;
    gap: 8px;
    padding-left: 10px;
    padding-right: 10px;
    font-size: 14px;
  }

  .icon-chip {
    width: 48px;
  }

  .profile-avatar,
  .avatar {
    width: 34px;
    height: 34px;
  }

  .profile-chip b {
    max-width: 76px;
  }
}

@media (max-width: 1320px) and (min-width: 1200px) {
  .room-layout {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 350px);
    gap: 18px;
  }

  .outcomes-grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  .outcome-card {
    padding: 18px 14px;
    min-height: 226px;
  }

  .outcome-card.selected {
    padding-top: 28px;
  }

  .card-check {
    right: 12px;
    top: -12px;
    width: 34px;
    height: 34px;
    border-width: 3px;
  }

  .outcome-head {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 8px;
    align-items: start;
  }

  .outcome-head .flag {
    width: 36px;
    height: 36px;
    min-width: 36px;
  }

  .outcome-head h3 {
    font-size: 19px;
    line-height: 1.08;
    white-space: normal;
  }

  .pool-pill {
    padding: 4px 8px;
    font-size: 10px;
  }
}

@media (max-width: 1199px) {
  .layout-grid,
  .hero-card,
  .setup-layout,
  .room-layout,
  .bet-layout,
  .result-grid,
  .room-top,
  .result-hero {
    grid-template-columns: 1fr;
  }

  .side-col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }

  .header-inner {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    gap: 18px;
    padding: 0 18px;
  }

  .mobile-menu-button {
    display: grid;
    place-items: center;
  }

  .top-nav {
    display: none;
  }

  .screen {
    padding: 24px 18px 80px;
  }

  .room-info-grid,
  .room-actions-panel {
    grid-template-columns: 1fr;
  }

  .room-code.as-button {
    grid-column: auto;
  }

  .match-title-room h1 {
    max-width: 100%;
  }

  .room-grid,
  .outcomes-grid.three,
  .steps-strip.two,
  .benefit-strip,
  .profile-grid,
  .result-stats {
    grid-template-columns: 1fr;
  }

  .profile-hero {
    grid-template-columns: 1fr;
  }

  .bet-side {
    grid-template-columns: 1fr;
  }

  .bet-side h2,
  .bet-side .amount-input,
  .bet-side .bet-summary,
  .bet-side .btn,
  .bet-side .terms {
    grid-column: 1;
    grid-row: auto;
  }

  .rooms-hero {
    grid-template-columns: 1fr;
    padding: 24px;
  }

  .rooms-hero h1 {
    font-size: 42px;
  }

  .rooms-tabs {
    width: 100%;
    grid-template-columns: 1fr 1fr;
  }

  .rooms-tabs button {
    justify-content: center;
  }

  .profile-identity {
    width: 100%;
    min-width: 0;
  }

  .setup-side {
    position: static;
  }

  .create-stepper {
    gap: 12px;
  }

  .create-stepper div:not(:last-child)::after {
    left: calc(50% + 44px);
    right: calc(-50% + 44px);
  }
}

@media (max-width: 1180px) {
  .overview-shell {
    grid-template-columns: 1fr;
  }

  .overview-side {
    position: static;
  }
}

@media (max-width: 760px) {
  .app-header { height: 78px; }
  .app-header::before { height: 4px; }
  .header-inner {
    padding: 4px 14px 0;
    gap: 10px;
  }
  .brand-link { gap: 10px; }
  .brand-mark { width: 42px; height: 42px; border-radius: 12px; }
  .brand-name { font-size: 25px; }
  .header-actions { gap: 8px; }
  .wallet-chip,
  .profile-chip,
  .icon-chip,
  .mobile-menu-button {
    min-height: 46px;
    height: 46px;
    border-radius: 15px;
  }
  .wallet-chip {
    width: 46px;
    justify-content: center;
    padding: 0;
  }
  .wallet-chip .wallet-amount,
  .wallet-chip .wallet-top-up {
    display: none;
  }
  .icon-chip {
    width: 46px;
  }
  .profile-chip {
    width: 46px;
    padding: 0;
    justify-content: center;
  }
  .profile-chip b,
  .profile-chip > .svg-icon {
    display: none;
  }
  .profile-avatar,
  .avatar {
    width: 34px;
    height: 34px;
    font-size: 13px;
  }
  .dot-badge {
    width: 20px;
    height: 20px;
    font-size: 10px;
  }
  .notification-menu {
    position: fixed;
    left: 12px;
    right: 12px;
    top: 72px;
    width: auto;
    max-width: none;
    max-height: calc(100vh - 92px);
    overflow-y: auto;
    z-index: 90;
  }
  .notification-menu::before {
    display: none;
  }
  .mobile-menu-button {
    width: 46px;
  }
  .mobile-menu-button::before {
    top: 15px;
    box-shadow: 0 7px 0 var(--text);
  }
  .mobile-menu-button span { top: 22px; }
  .mobile-menu-button::after { top: 29px; }
  .mobile-drawer {
    padding: 10px 14px 16px;
  }
  .mobile-drawer .nav-link {
    min-height: 48px;
    border-radius: 14px;
  }
  .bets-hero {
    min-height: 0;
    grid-template-columns: 1fr;
    padding: 24px;
    border-radius: 18px;
  }
  .wallet-hero {
    min-height: 0;
    grid-template-columns: 1fr;
    padding: 20px;
    border-radius: 20px;
  }
  .wallet-hero h1 {
    font-size: 44px;
  }
  .wallet-hero p {
    font-size: 17px;
  }
  .wallet-balance-card {
    padding: 22px;
    border-radius: 20px;
  }
  .top-up-presets {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .payment-detail-grid,
  .top-up-copy-actions {
    grid-template-columns: 1fr;
  }
  .payment-instruction b {
    font-size: 24px;
  }
  .bets-hero h1 {
    font-size: 42px;
  }
  .bets-hero p {
    font-size: 17px;
  }
  .bets-hero .btn {
    width: 100%;
    min-width: 0;
  }
  .overview-metrics,
  .overview-list {
    grid-template-columns: 1fr;
  }
  .wallet-operation {
    grid-template-columns: 48px minmax(0, 1fr);
    align-items: start;
    padding: 16px;
  }
  .wallet-operation-icon {
    width: 48px;
    height: 48px;
    border-radius: 16px;
  }
  .wallet-operation-right {
    grid-column: 1 / -1;
    grid-template-columns: 1fr auto;
    justify-items: start;
    align-items: center;
  }
  .wallet-operation-right time {
    justify-self: end;
  }
  .overview-metric-card {
    min-height: 96px;
  }
  .bet-item {
    padding: 20px;
    border-radius: 20px;
  }
  .bet-item h3 {
    font-size: 24px;
  }
  .bet-item-pick,
  .bet-item-top {
    align-items: flex-start;
  }
  .bet-item-pick {
    flex-direction: column;
    gap: 6px;
  }
  .bet-item-grid {
    grid-template-columns: 1fr;
  }
  .hero-card { padding: 22px; border-radius: 18px; }
  .setup-main {
    min-height: 0;
    padding: 22px;
    border-radius: 18px;
  }
  .setup-main h1 {
    font-size: 42px;
  }
  .create-stepper {
    grid-template-columns: 1fr;
  }
  .create-stepper div {
    min-height: 54px;
    grid-template-columns: 46px 1fr;
    justify-items: start;
    align-items: center;
  }
  .create-stepper div:not(:last-child)::after {
    display: none;
  }
  .create-stepper span {
    width: 46px;
    height: 46px;
    font-size: 18px;
  }
  .setup-main > p {
    font-size: 16px;
  }
  .setup-match-card,
  .setup-form-grid,
  .public-toggle {
    grid-template-columns: 1fr;
  }
  .setup-match-card .team-pair {
    justify-content: flex-start;
  }
  .public-toggle {
    align-items: start;
  }
  .setup-match-option {
    grid-template-columns: auto 1fr;
  }
  .setup-match-option > svg:last-of-type,
  .setup-match-option > .flag:last-of-type {
    grid-column: 1;
  }
  .setup-match-option i {
    grid-column: 2;
    grid-row: 2;
    justify-self: end;
  }
  .setup-actions,
  .setup-summary-match,
  .invite-link-actions {
    grid-template-columns: 1fr;
  }
  .room-code-large b {
    font-size: 32px;
  }
  .profile-hero,
  .profile-card {
    padding: 22px;
    border-radius: 18px;
  }
  .profile-hero h1 { font-size: 42px; }
  .profile-card-head { min-height: 0; }
  .match-title-row h1 { width: 100%; margin-left: 0; font-size: 38px; }
  .flag.lg { width: 56px; height: 56px; }
  .hero-metrics { grid-template-columns: 1fr; }
  .stat-item { border-right: 0; border-bottom: 1px solid var(--line); }
  .stat-item:last-child { border-bottom: 0; }
  .side-col { grid-template-columns: 1fr; }
  .panel,
  .auth-card { padding: 22px; border-radius: 18px; }
  .step-flow {
    grid-template-columns: minmax(78px, 1fr) 22px minmax(78px, 1fr) 22px minmax(78px, 1fr);
    gap: 8px;
  }
  .step-flow > span .svg-icon { width: 48px; height: 48px; }
  .step-flow > .svg-icon { height: 48px; padding: 10px 0; }
  .room-stats { grid-template-columns: 1fr; }
  .mini-bet { grid-template-columns: auto auto 1fr; }
  .mini-bet strong { grid-column: 3; }
  .match-title-room h1,
  .large-title { width: 100%; margin-left: 0; font-size: 38px; }
  .room-info-grid,
  .room-actions-panel,
  .chat-input,
  .winner-row {
    grid-template-columns: 1fr;
  }
  .person-row {
    grid-template-columns: 42px minmax(0, 1fr) auto;
    gap: 10px 12px;
    align-items: center;
  }
  .person-row .pick {
    grid-column: 2 / 4;
    justify-self: start;
    max-width: 100%;
    width: auto;
    display: inline-flex;
    align-items: center;
    min-width: 0;
  }
  .person-row strong {
    grid-column: 2 / 4;
    justify-self: start;
  }
  .mini-event-head {
    padding: 24px;
    gap: 16px;
  }
  .mini-event-flags {
    gap: 12px;
  }
  .mini-event-head h1 {
    max-width: 100%;
    font-size: 34px;
  }
  .mini-event-head p {
    font-size: 16px;
  }
  .countdown,
  .room-actions-panel .btn {
    grid-column: auto;
  }
  .winner-box { grid-template-columns: 1fr; }
  .access-modal { padding: 32px 18px; }
  .access-modal h1 { font-size: 34px; }
  .preview-match,
  .preview-match.large,
  .summary-lines.compact,
  .action-row {
    grid-template-columns: 1fr;
  }
  .summary-lines.compact > div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .summary-lines.compact > div:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 430px) {
  .room-terms-stats b {
    font-size: 16px;
  }
  .room-card-outcomes {
    gap: 6px;
  }
  .room-card-outcome {
    border-radius: 12px;
    padding: 8px 7px;
  }
  .room-card-outcome span {
    font-size: 11px;
  }
  .room-card-outcome b {
    font-size: 16px;
  }

  .brand-name {
    display: none;
  }

  .header-inner {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
  }
}
