/* ============================================================
   KHILADIBATTLE INSPIRATIONS: SOCIAL PROOF, MODES & STATS
   ============================================================ */

/* 1. Live Recent Withdrawals Vertical Feed (Removed per user request) */
.withdrawals-ticker-strip {
  display: none;
}

.withdrawals-ticker-strip::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #10b981 0%, #f59e0b 50%, #3b82f6 100%);
  opacity: 0.8;
}

.withdrawals-ticker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.withdrawals-ticker-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 5px 12px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 800;
  color: #10b981;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.withdrawals-live-tag {
  font-size: 11px;
  color: var(--text-dim);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

.withdrawals-vertical-container {
  height: 142px;
  overflow: hidden;
  position: relative;
  mask-image: linear-gradient(to bottom, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, transparent, black 8%, black 92%, transparent);
}

.withdrawals-track-vertical {
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: withdrawalsScrollVertical 24s linear infinite;
  will-change: transform;
}

.withdrawals-ticker-strip:hover .withdrawals-track-vertical {
  animation-play-state: paused;
}

@keyframes withdrawalsScrollVertical {
  0% { transform: translateY(0); }
  100% { transform: translateY(-50%); }
}

.withdrawal-card-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  padding: 8px 12px;
  border-radius: 10px;
  transition: all 0.2s ease;
}

.withdrawal-card-item:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(16, 185, 129, 0.3);
  transform: translateX(3px);
}

.withdrawal-player-col {
  display: flex;
  align-items: center;
  gap: 10px;
}

.withdrawal-meta-col {
  display: flex;
  align-items: center;
  gap: 10px;
}

.live-dot-pulse {
  width: 7px;
  height: 7px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 8px #10b981;
  animation: liveDotBlink 1.8s infinite ease-in-out;
}

@keyframes liveDotBlink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.chip-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.chip-user {
  font-size: 13px;
  font-weight: 700;
  color: #f1f5f9;
  letter-spacing: 0.2px;
}

.chip-amount {
  font-size: 13px;
  font-weight: 800;
  color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.chip-tag {
  font-size: 10.5px;
  font-weight: 700;
  color: #059669;
  background: rgba(16, 185, 129, 0.15);
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.chip-time {
  font-size: 10.5px;
  color: var(--text-dim);
}
  color: #94a3b8;
  background: rgba(16, 185, 129, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid rgba(16, 185, 129, 0.2);
}

/* 2. Tournament Modes Section */
.modes-section-block {
  margin: 26px 0 20px 0;
}

.section-title-wrap {
  text-align: center;
  margin-bottom: 16px;
}

.section-tag-badge {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  padding: 4px 10px;
  border-radius: 20px;
  display: inline-block;
  margin-bottom: 6px;
}

.section-heading {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #fff;
  margin: 4px 0;
}

.section-subheading {
  font-size: 13px;
  color: #94a3b8;
  max-width: 500px;
  margin: 0 auto;
}

.modes-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.mode-card {
  position: relative;
  background: linear-gradient(180deg, rgba(22, 28, 40, 0.9) 0%, rgba(14, 18, 27, 0.95) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 18px;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.mode-card:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: 0 10px 25px rgba(245, 158, 11, 0.12);
}

.mode-card-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  font-size: var(--fs-xs);
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
  text-transform: uppercase;
}

.mode-badge-gold {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.3);
}

.mode-badge-cyan {
  background: rgba(2, 132, 199, 0.15);
  color: #38bdf8;
  border-color: rgba(2, 132, 199, 0.3);
}

.mode-card-icon {
  width: 44px;
  height: var(--icon-btn);
  border-radius: 10px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.25);
  color: #f59e0b;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.mode-card-title {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: 700;
  color: #fff;
  margin: 0 0 6px 0;
  text-transform: uppercase;
}

.mode-card-desc {
  font-size: var(--fs-sm);
  color: #94a3b8;
  line-height: 1.45;
  margin: 0 0 16px 0;
  flex: 1;
}

.mode-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 10px;
  font-size: var(--fs-sm);
}

.mode-feature {
  color: #64748b;
  font-weight: 600;
}

.mode-cta-link {
  color: #f59e0b;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* Compact native home dashboard: secondary content remains available in dedicated tabs. */
#tab-home .home-secondary-content {
  display: none;
}

#tab-home .tournament-flow-strip,
#tab-home .compact-site-footer {
  display: block;
}

#tab-home .tournament-flow-strip {
  margin: 16px 0;
}

.platform-availability-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  padding: 11px 14px;
  border: 1px solid rgba(255, 85, 0, 0.28);
  border-radius: var(--radius-md);
  background: rgba(255, 85, 0, 0.08);
  color: var(--accent);
  justify-content: center;
  text-align: center;
}

.platform-availability-banner span {
  display: grid;
  gap: 2px;
  text-align: center;
}

.platform-availability-banner strong {
  color: var(--text-main);
  font-size: 13px;
}

.platform-availability-banner small {
  color: var(--text-dim);
  font-size: 11px;
  line-height: 1.4;
}

#tab-home .esports-hero-banner {
  min-height: 160px;
  height: clamp(190px, 28vw, 340px);
  max-height: 340px;
  padding: 16px;
  margin-bottom: 14px;
  align-items: center;
  text-align: center;
  animation: native-surface-enter 180ms ease-out both;
}

#tab-home .hero-slide-item {
  transform: none;
  transition: none;
  background-position: center 28%;
}

#tab-home .hero-slider-overlay {
  background: rgba(6, 10, 17, 0.7);
}

#tab-home .hero-top-row,
#tab-home .hero-content-flex {
  justify-content: center;
  text-align: center;
}

#tab-home .hero-top-row {
  margin-bottom: 8px;
}

#tab-home .hero-title {
  max-width: 320px;
  margin-bottom: 4px;
  font-size: clamp(21px, 6vw, 30px);
  text-align: center;
}

#tab-home .hero-subtitle {
  max-width: 360px;
  margin: 0 auto;
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
}

#tab-home .modes-section-block {
  margin: 0;
}

#tab-home .section-title-wrap {
  margin-bottom: 10px;
  text-align: center;
}

#tab-home .section-tag-badge,
#tab-home .section-subheading {
  display: none;
}

#tab-home .section-heading {
  margin: 0;
  font-size: 18px;
}

#tab-home .modes-card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

#tab-home .mode-card {
  min-height: auto;
  padding: 12px;
  border-radius: 12px;
  background: #111722;
  border-color: rgba(148, 163, 184, 0.14);
  box-shadow: none;
  align-items: center;
  text-align: center;
  animation: native-surface-enter 180ms ease-out both;
}

#tab-home .mode-card:hover {
  transform: translateY(-1px);
  border-color: rgba(203, 213, 225, 0.26);
  box-shadow: none;
}

#tab-home .mode-card::after {
  display: none;
}

#tab-home .mode-card:focus-visible {
  outline: 2px solid var(--mode-accent, #f59e0b);
  outline-offset: 2px;
}

#tab-home .mode-card:active {
  transform: scale(0.98);
}

#tab-home .mode-card-icon {
  width: 34px;
  height: var(--icon-btn);
  margin-bottom: 10px;
  border-radius: 8px;
  color: #cbd5e1;
  background: #1b2432;
  border-color: rgba(148, 163, 184, 0.18);
}

#tab-home .mode-card-badge {
  top: 9px;
  right: 9px;
  max-width: 74px;
  overflow: hidden;
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #e2e8f0;
  background: #202938;
  border-color: rgba(148, 163, 184, 0.18);
}

#tab-home .mode-card-title {
  margin-bottom: 8px;
  font-size: var(--fs-base);
}

#tab-home .mode-card-desc {
  display: none;
}

#tab-home .mode-card-footer {
  width: 100%;
  justify-content: center;
  gap: 10px;
  margin-top: auto;
  padding-top: 7px;
  font-size: var(--fs-xs);
}

#tab-home .mode-cta-link {
  color: #f8fafc;
}

@keyframes native-surface-enter {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  #tab-home .esports-hero-banner,
  #tab-home .mode-card {
    animation: none;
    transition: none;
  }
}

@media (max-width: 420px) {
  .app-header {
    padding-inline: 12px;
  }
}

@media (min-width: 880px) {
  #tab-home .modes-card-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  #tab-home .mode-card {
    min-height: auto;
  }

  #tab-home .mode-card-desc {
    display: block;
    margin-bottom: 10px;
    font-size: var(--fs-sm);
  }
}

@media (max-width: 600px) {
  #tab-home .esports-hero-banner { height: clamp(170px, 48vw, 240px); }
}

/* App-style mode inner screen: the selected mode replaces the mode picker. */
#tab-matches.mode-screen-open > .rooms-header-card,
#tab-matches.mode-screen-open > #recent-match-toggle {
  display: none;
}

.mode-screen-header {
  position: relative;
  min-height: 108px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  background: #111827;
}

.mode-screen-cover,
.mode-screen-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.mode-screen-cover {
  object-fit: cover;
}

.mode-screen-shade {
  background: linear-gradient(90deg, rgba(7, 10, 17, 0.94) 0%, rgba(7, 10, 17, 0.7) 58%, rgba(7, 10, 17, 0.24) 100%);
}

.mode-screen-back {
  position: absolute;
  z-index: 3;
  top: auto;
  bottom: 42px;
  left: 0;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background: rgba(7, 10, 17, 0.72);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  transform: none;
}

.mode-screen-heading {
  position: relative;
  z-index: 2;
  min-height: 108px;
  padding: 14px 16px 13px 48px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.mode-screen-heading h2 {
  margin: 2px 0;
  color: #fff;
  font-family: var(--font-display);
  font-size: clamp(20px, 5vw, 26px);
  line-height: 1;
}

.mode-screen-heading > span:last-child {
  color: #cbd5e1;
  font-size: 12px;
}

.mode-screen-kicker {
  color: #f59e0b;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.9px;
  text-transform: uppercase;
}

.mode-screen-filters {
  margin-top: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.mode-screen-filters::-webkit-scrollbar {
  display: none;
}

/* Compact tournament feed cards: real match data remains the visual focus. */
#matches-list-container {
  grid-template-columns: repeat(auto-fit, minmax(280px, 340px));
  gap: 12px;
}

.match-card {
  min-height: 0;
  max-width: 340px;
  border-radius: 12px;
  box-shadow: none;
}

.match-card-banner {
  height: var(--card-art-h);
}

.match-card-tags {
  top: 7px;
  left: 8px;
  right: 8px;
}

.mode-tag,
.match-status-badge {
  font-size: 9px;
  padding: 3px 6px;
  backdrop-filter: none;
  box-shadow: none;
}

.match-card-body {
  padding: 8px 10px 10px;
  gap: 5px;
}

.match-info-icon-btn {
  width: var(--icon-btn);
  height: var(--icon-btn);
  flex: 0 0 var(--icon-btn);
  border-radius: 50%;
}

.match-title {
  font-size: 15px;
  min-height: 2.3em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  white-space: normal;
  overflow-wrap: anywhere;
}

@media (max-width: 599px) {
  #explore-section .explore-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  #matches-list-container {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    padding-inline: 2px;
  }

  #matches-list-container .tournament-match-card {
    width: 100%;
    max-width: none;
    border-radius: 12px;
  }

  #matches-list-container .tournament-match-card .match-card-banner {
    height: calc(var(--match-card-art-h) - var(--space-2));
  }

  #matches-list-container .tournament-match-card .match-card-body {
    padding: 8px 11px 9px;
    gap: 3px;
  }

  #matches-list-container .tournament-match-card .match-title {
    min-height: 0;
    font-size: var(--fs-base);
    white-space: nowrap;
    text-overflow: ellipsis;
    -webkit-line-clamp: 1;
  }

  #matches-list-container .tournament-match-card .match-meta-row {
    gap: 7px;
    font-size: var(--fs-xs);
  }

  #matches-list-container .tournament-match-card .slot-progress-wrap { margin-block: 1px; }
  #matches-list-container .tournament-match-card .slot-progress-labels { margin-bottom: 2px; }
  #matches-list-container .tournament-match-card .match-card-body .btn {
    min-height: var(--btn-h-sm);
    height: var(--btn-h-sm);
  }
}

.meta-item {
  font-size: 11px;
}

.metrics-grid {
  padding: 5px 4px;
  border-radius: 8px;
}

.metric-label {
  font-size: 8px;
}

.metric-value {
  font-size: 12px;
}

.slot-progress-wrap {
  margin: 0;
}

.slot-progress-labels {
  margin-bottom: 4px;
  font-size: 10px;
}

.slot-bar {
  height: 4px;
}

.slot-progress-wrap.is-filling-fast .slot-progress-labels {
  color: #fb923c;
  font-weight: 700;
}

.slot-progress-wrap.is-filling-fast .slot-fill {
  background: linear-gradient(90deg, #f97316, #ef4444);
  box-shadow: none;
}

.match-card-body .btn {
  height: auto;
  min-height: var(--btn-h);
  margin-top: auto;
  padding: 6px 8px;
  border-radius: 8px;
  line-height: 1.25;
  white-space: normal;
  overflow-wrap: anywhere;
}

@media (max-width: 640px) {
  #matches-list-container {
    gap: 10px;
  }

  .match-card {
    max-width: 100%;
    border-radius: 12px;
  }

  .match-card-banner {
    height: var(--card-art-h);
  }

  .match-card-body {
    padding: 8px 10px 10px;
    gap: 5px;
  }

  .match-title {
    font-size: 15px;
  }
}

@media (min-width: 1200px) {
  #matches-list-container {
    grid-template-columns: repeat(4, minmax(260px, 1fr));
    max-width: 1440px;
  }

  .match-card {
    max-width: none;
  }
}

.refer-link-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 10px;
  padding: 10px 12px;
  margin: 10px 0;
  text-align: left;
}

.refer-link-label {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #f59e0b;
  margin-bottom: 4px;
}

.refer-link-display {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.refer-link-text {
  font-size: 11px;
  color: #cbd5e1;
  font-family: monospace;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: rgba(0, 0, 0, 0.3);
  padding: 4px 8px;
  border-radius: 6px;
  flex: 1;
}

.btn-copy-link {
  background: #f59e0b;
  color: #0b0e13;
  font-size: var(--fs-xs);
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
}

/* 4. Refer & Earn Home Banner */
.refer-earn-home-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.12) 0%, rgba(220, 38, 38, 0.08) 100%);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 14px;
  padding: 14px 18px;
  margin: 18px 0;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
  flex-wrap: wrap;
}

.refer-earn-home-strip:hover {
  transform: translateY(-2px);
  border-color: #f59e0b;
}

.refer-home-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 240px;
}

.refer-home-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: rgba(245, 158, 11, 0.18);
  border: 1px solid rgba(245, 158, 11, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f59e0b;
  flex-shrink: 0;
}

.refer-home-text h4 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 2px 0;
}

.refer-home-text p {
  font-size: 12px;
  color: #cbd5e1;
  margin: 0;
  line-height: 1.4;
}

.refer-home-btn {
  background: #f59e0b;
  color: #0b0e13;
  font-size: var(--fs-sm);
  font-weight: 800;
  padding: 9px 18px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
  white-space: nowrap;
  letter-spacing: 0.5px;
}

/* 5. Explore Mode Cards Interactive Selection & In-Card Open System */
.explore-card.is-active {
  border-color: #f59e0b;
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.4), 0 8px 24px rgba(245, 158, 11, 0.25);
  transform: translateY(-2px);
}

.explore-active-indicator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding: 11px 16px;
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.16) 0%, rgba(245, 158, 11, 0.14) 100%);
  border: 1.5px solid #10b981;
  border-radius: 12px;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.25);
}

.explore-active-indicator-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.explore-active-pill {
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  color: #0b0e13;
  background: linear-gradient(135deg, #10b981, #34d399);
  padding: 3px 9px;
  border-radius: 6px;
  letter-spacing: 0.6px;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
}

.explore-active-name {
  font-family: var(--font-display);
  font-weight: 900;
  color: #ffffff;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.7);
}

.explore-active-count {
  font-size: 12px;
  color: #a7f3d0;
  font-weight: 700;
}

.explore-close-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e2e8f0;
  font-size: var(--fs-xs);
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.explore-close-btn:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.4);
  color: #ef4444;
}

.explore-mode-prompt {
  text-align: center;
  padding: 38px 20px;
  background: linear-gradient(180deg, rgba(18, 23, 34, 0.6) 0%, rgba(13, 17, 25, 0.7) 100%);
  border: 1px dashed rgba(245, 158, 11, 0.25);
  border-radius: 14px;
  margin: 14px 0 24px 0;
}

.explore-mode-prompt-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 12px auto;
  border-radius: 12px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f59e0b;
}

.explore-mode-prompt-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #f1f5f9;
}

.explore-mode-prompt-desc {
  margin: 6px 0 0 0;
  font-size: 13px;
  color: #94a3b8;
}

/* Native tournament phase 2: compact matte cards and clear mobile hierarchy. */
#tab-home .mode-card {
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

#tab-home .mode-card-title {
  max-width: 100%;
  overflow-wrap: anywhere;
}

#tab-home .mode-card-footer {
  flex-wrap: wrap;
}

.mode-screen-header,
.mode-screen-heading {
  min-height: 112px;
}

.mode-screen-back {
  top: 26px;
  bottom: auto;
  left: 0;
  width: 32px;
  height: 32px;
  border-color: rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  font-size: 19px;
}

.mode-screen-heading {
  padding: 14px 14px 12px 48px;
  text-align: center;
  align-items: center;
}

.mode-screen-heading h2 {
  font-size: clamp(20px, 5.4vw, 27px);
}

.mode-screen-filters {
  justify-content: center;
  margin-top: 8px;
}

#matches-list-container {
  grid-template-columns: repeat(auto-fit, minmax(280px, 357px));
}

.match-card {
  max-width: 357px;
  background: #111722;
  border-color: rgba(148, 163, 184, 0.16);
  box-shadow: none;
}

.match-card::before {
  display: none;
}

.match-card:hover {
  transform: translateY(-1px);
  border-color: rgba(203, 213, 225, 0.26);
  box-shadow: none;
}

.match-title {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  text-align: center;
}

.match-title-time {
  color: #cbd5e1;
  font-size: 0.78em;
  font-weight: 600;
  white-space: nowrap;
}

.match-status-badge.status-live {
  background: #dc2626;
  color: #ffffff;
  border-color: #f87171;
}

.match-status-badge.status-upcoming {
  background: #075985;
  color: #e0f2fe;
  border-color: #38bdf8;
}

.match-status-badge.status-open {
  background: #166534;
  color: #dcfce7;
  border-color: #4ade80;
}

.match-status-badge.status-full {
  background: #9a3412;
  color: #ffedd5;
  border-color: #fb923c;
}

.match-status-badge.status-completed {
  background: #334155;
  color: #f1f5f9;
  border-color: #64748b;
}

.explore-card {
  aspect-ratio: 16 / 10;
  background: #111722;
  box-shadow: none;
}

.explore-card:hover,
.explore-card:focus-visible,
.explore-card.has-live-rooms,
.explore-card.has-live-rooms:hover {
  border-color: rgba(248, 113, 113, 0.72);
  box-shadow: none;
  transform: translateY(-1px);
}

.explore-count.is-live {
  background: #dc2626;
  border-color: #f87171;
  box-shadow: none;
  animation: none;
}

.explore-count.is-total {
  background: rgba(15, 23, 42, 0.9);
  color: #ffffff;
  border: 1px solid rgba(248, 113, 113, 0.72);
  box-shadow: none;
}

.explore-count.is-total .live-dot-pulse {
  background: #ef4444;
  box-shadow: none;
}

.room-active-tag {
  background: #b91c1c;
  border-color: #f87171;
  box-shadow: none;
}

.mode-title-survival,
.mode-title-free,
.mode-title-perkill,
.mode-title-cs,
.mode-title-lw {
  background: none;
  -webkit-text-fill-color: #ffffff;
  color: #ffffff;
  filter: none;
}

@media (max-width: 360px) {
  #tab-home .mode-card-footer {
    gap: 4px;
  }

  #tab-home .mode-feature {
    display: none;
  }

  #tab-home .mode-card-badge {
    max-width: calc(100% - 18px);
  }
}

.home-promo-slider {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 6;
  min-height: 150px;
  margin: 16px 0;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  background: #111722;
}

.home-promo-track,
.home-promo-item {
  position: absolute;
  inset: 0;
}

.home-promo-item {
  display: flex;
  align-items: flex-end;
  padding: 22px;
  color: #fff;
  background-position: center;
  /* Preserve the complete administrator-uploaded artwork. Cover was
     cropping banners with text/logos on phones and wide desktop layouts. */
  background-size: contain;
  background-repeat: no-repeat;
  background-color: #0b101a;
  opacity: 0;
  transform: translateX(2%);
  transition: opacity 700ms ease, transform 700ms ease;
  pointer-events: none;
}

.home-promo-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(3, 7, 18, 0.88));
}

.home-promo-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  pointer-events: none;
}

.home-promo-item.active {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.home-promo-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 3px;
  text-shadow: 0 2px 12px #000;
}

.home-promo-copy strong { font-size: clamp(1rem, 3vw, 1.4rem); }
.home-promo-copy small { color: #e2e8f0; }

.home-promo-dots {
  position: absolute;
  right: 14px;
  bottom: 12px;
  z-index: 2;
  display: flex;
  gap: 6px;
}

.home-promo-dots button {
  width: 7px;
  height: var(--btn-h);
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  transition: width 400ms ease, background 400ms ease;
}

.home-promo-dots button.active { width: 20px; background: #fff; }

.home-promo-nav {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 34px;
  height: var(--header-h);
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  color: #fff;
  background: rgba(3, 7, 18, 0.55);
  font-size: var(--fs-h1);
  line-height: 1;
  transform: translateY(-50%);
}

.home-promo-prev { left: 10px; }
.home-promo-next { right: 10px; }

@media (prefers-reduced-motion: reduce) {
  .home-promo-item,
  .home-promo-dots button { transition: none; }
}

.home-trust-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 18px;
}

.home-live-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.home-live-stats article {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 14px 10px;
  border: 1px solid rgba(255, 115, 32, 0.22);
  border-radius: 14px;
  background: #111722;
  text-align: center;
}

.home-live-stats strong { color: #fff; font-size: clamp(18px, 4vw, 26px); }
.home-live-stats span { color: var(--text-muted); font-size: 11px; font-weight: 700; }

.mode-card-headshot .mode-card-icon { color: #f87171; }

@media (max-width: 520px) {
  .home-live-stats { gap: 6px; }
  .home-live-stats article { padding: 11px 5px; }
  .home-live-stats span { font-size: 9px; }
}

.home-trust-grid article {
  display: grid;
  gap: 5px;
  min-height: 112px;
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.82), rgba(15, 23, 42, 0.95));
}

.home-trust-grid article > span {
  color: var(--primary);
  font-size: 11px;
  font-weight: 800;
}

.home-trust-grid article strong { color: #fff; font-size: 14px; }
.home-trust-grid article small { color: var(--text-muted); line-height: 1.45; }

.brand-intro-card {
  position: relative;
  overflow: hidden;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid rgba(255, 115, 32, 0.24);
  border-radius: 20px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 92, 20, 0.18), transparent 42%),
    linear-gradient(145deg, rgba(22, 30, 44, 0.98), rgba(9, 14, 24, 0.98));
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.24), inset 0 1px rgba(255, 255, 255, 0.05);
}

.brand-intro-card::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(110deg, transparent 25%, rgba(255, 255, 255, 0.035) 48%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
}

.brand-intro-card:hover::after { transform: translateX(100%); }
.brand-intro-kicker { color: var(--primary); font-size: 11px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }
.brand-intro-card h2 { margin: 7px 0 9px; color: #fff; font-size: clamp(20px, 4vw, 30px); line-height: 1.15; }
.brand-intro-card p { max-width: 780px; margin: 0; color: var(--text-muted); font-size: var(--fs-sm); line-height: 1.65; }
.brand-intro-points { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.brand-intro-points span { padding: 6px 10px; border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 999px; color: var(--text-main); background: rgba(255, 255, 255, 0.045); font-size: 11px; font-weight: 700; }

.mode-screen-header,
.mode-screen-heading {
  min-height: 76px;
}

.mode-screen-header {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(255, 85, 0, 0.14), #111827 58%, rgba(56, 189, 248, 0.1));
}

.mode-screen-heading {
  position: relative;
  inset: auto;
  z-index: 1;
  display: grid;
  place-content: center;
  justify-items: center;
  width: 100%;
  padding: 8px 56px;
  text-align: center;
}

.mode-screen-back-wrap { position: absolute; top: 50%; left: 12px; z-index: 3; transform: translateY(-50%); }
.mode-screen-back-wrap .compact-back-btn { border-color: rgba(255, 255, 255, 0.22); background: rgba(255, 255, 255, 0.08); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.22); }
.mode-screen-back-wrap .compact-back-btn:hover,
.mode-screen-back-wrap .compact-back-btn:focus-visible { border-color: var(--primary); background: rgba(255, 85, 0, 0.18); transform: translateX(-2px) scale(1.06); }

.tab-content.active {
  animation: ap-content-enter calc(160ms * var(--screen-animation-scale)) ease-out both;
}

.compact-menu-item,
.contact-method-card,
.match-card,
.home-trust-grid article {
  transition: transform 160ms ease, border-color 160ms ease, background-color 160ms ease, opacity 160ms ease;
}

.compact-menu-item:hover,
.contact-method-card:hover,
.home-trust-grid article:hover {
  transform: translateY(-2px);
}

@keyframes ap-content-enter {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.wallet-history-pagination { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 14px 4px 2px; color: var(--text-muted); font-size: 12px; }
.wallet-history-pagination .btn { min-width: 86px; transition: transform 320ms ease, opacity 320ms ease, background-color 320ms ease; }
.rule-language-block { padding: 12px; border: 1px solid var(--border); border-radius: 12px; background: rgba(255,255,255,.025); animation: ap-content-enter 320ms cubic-bezier(0.22,1,0.36,1) both; }
.rule-language-block + .rule-language-block { margin-top: 10px; }
.rule-language-block > strong, .rules-for-all-grid h5 { display: block; margin-bottom: 8px; color: var(--primary); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.rule-language-block p { margin: 0 0 7px; }
.rule-language-block p:last-child { margin-bottom: 0; }
.rules-for-all-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
.rules-for-all-grid section { padding: 12px; border: 1px solid var(--border); border-radius: 12px; background: rgba(255,255,255,.025); }
.rules-for-all-grid p { margin: 0 0 10px; }
@media (max-width: 640px) { .rules-for-all-grid { grid-template-columns: 1fr; } }

.admin-tab-pane { animation: ap-content-enter 320ms cubic-bezier(0.22,1,0.36,1) both; }
.modal-card, .match-details-content, .notification-item, .tx-item-card, .admin-card, .table-card, .dropdown-menu {
  transition: transform 320ms cubic-bezier(0.22,1,0.36,1), opacity 320ms ease, border-color 320ms ease, background-color 320ms ease;
}

@media (max-width: 640px) {
  .home-trust-grid { grid-template-columns: 1fr; }
  .home-trust-grid article { min-height: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .tab-content.active { animation: none; }
  .compact-menu-item,
  .contact-method-card,
  .match-card,
  .home-trust-grid article,
  .mode-screen-back { transition: none; }
}

/* Consistent touch targets and centered, fluid tournament cards. */
html,
body { max-width: 100%; }

img,
video { max-width: 100%; }

.btn {
  min-height: var(--btn-h);
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.form-input,
.form-select,
select,
textarea { min-width: 0; max-width: 100%; }

#matches-list-container {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 340px));
  justify-content: center;
  width: min(100%, 1440px);
  margin-inline: auto;
  padding-inline: 12px;
}

.match-card {
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.match-card-banner,
.match-card-banner img { width: 100%; }

.match-card-banner img { object-position: center; }

.match-card-tags,
.match-chips-left {
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
}

.match-card-tags { justify-content: space-between; }
.match-chips-left { max-width: calc(100% - 84px); }
.match-card-tags .mode-tag,
.match-status-badge { max-width: 100%; overflow-wrap: anywhere; }

.match-card-body { min-width: 0; }
.match-card-prize { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--text-muted); font-size: var(--fs-xs); }
.match-card-prize strong { color: var(--primary); font-size: var(--fs-sm); }
.match-title { min-height: 2.3em; overflow-wrap: anywhere; }
.match-title-time { display: inline; white-space: normal; }
.match-card-body .btn { min-height: var(--btn-h); height: auto; white-space: normal; }

@media (max-width: 640px) {
  #matches-list-container {
    grid-template-columns: minmax(0, 1fr);
    width: min(100%, 460px);
    padding-inline: 12px;
  }

  .match-card-banner { height: clamp(84px, 24vw, 112px); }
  .match-card-body { padding: 12px; gap: 8px; }
  .match-card-tags { left: 8px; right: 8px; }
  .match-chips-left { max-width: calc(100% - 76px); }
}

/* Compact, consistent player-side sizing inspired by familiar shopping apps. */
.app-container .btn { min-height: var(--btn-h-sm); padding: 8px 12px; border-radius: 8px; font-size: var(--fs-sm); }
.app-container .btn.btn-sm { min-height: var(--btn-h-sm); padding: 6px 10px; font-size: var(--fs-sm); }
.app-container .form-input,
.app-container .form-select,
.app-container select { min-height: var(--input-h); padding-block: 8px; }
.app-container .section-title-wrap { margin-bottom: 10px; }
.app-container .section-heading { font-size: clamp(16px, 2vw, 19px); }
.app-container .home-promo-slider { min-height: 128px; margin-block: 12px; border-radius: 14px; }
.app-container .home-promo-item { padding: 14px; }
.app-container .home-promo-nav { width: 32px; height: var(--header-h); font-size: var(--fs-h2); }
.app-container .wallet-card { border-radius: 14px; }
.app-container .wallet-history-section { margin-top: 12px; }
.app-container .tx-item-card,
.app-container .notification-item { border-radius: 11px; }

@media (max-width: 640px) {
  #tab-home .esports-hero-banner { min-height: 138px; padding: 12px; margin-bottom: 10px; }
  #tab-home .hero-title { font-size: clamp(20px, 5.5vw, 26px); }
  #tab-home .hero-subtitle { font-size: 11px; }
  #tab-home .modes-card-grid { gap: 8px; }
  #tab-home .mode-card { min-height: auto; padding: 9px; border-radius: 11px; }
  #tab-home .mode-card-icon { width: 30px; height: var(--icon-btn); margin-bottom: 7px; }
  #tab-home .mode-card-title { margin-bottom: 5px; font-size: var(--fs-base); }
  #tab-home .mode-card-footer { padding-top: 5px; }
  .app-container .home-promo-slider { min-height: 116px; aspect-ratio: 16 / 7; }
  .app-container .btn { min-height: var(--btn-h); padding-inline: 10px; }
  .app-container .btn.btn-sm { min-height: var(--btn-h-sm); }
  .app-container .match-card-banner { height: clamp(76px, 20vw, 92px); }
  .app-container .match-card-body { padding: 9px 10px; gap: 6px; }
  .app-container .match-card-body .btn { min-height: var(--btn-h); }
  .app-container .wallet-history-pagination { gap: 8px; padding-block: 10px 2px; }
}

/* Keep home surfaces aligned and readable at every viewport width. */
#tab-home { width: min(100%, 1280px); margin-inline: auto; padding: 12px; }
#tab-home .esports-hero-banner,
#tab-home .home-promo-slider,
#tab-home .modes-section-block { width: 100%; margin-inline: auto; }
#tab-home .esports-hero-banner { height: clamp(150px, 18vw, 228px); max-height: 228px; }
#tab-home .home-promo-slider { height: auto; min-height: 0; aspect-ratio: 16 / 9; max-width: 1180px; }
#tab-home .home-promo-item { text-decoration: none; }
#tab-home .home-promo-copy { max-width: calc(100% - 32px); overflow-wrap: anywhere; padding: 7px 10px; border-radius: 8px; background: rgba(3, 7, 18, 0.76); }
#tab-home .home-promo-copy strong { font-size: 13px; line-height: 1.25; }
#tab-home .home-promo-copy small { font-size: 11px; line-height: 1.3; }
#tab-home .modes-card-grid { grid-auto-rows: 1fr; }
#tab-home .mode-card { min-width: 0; min-height: auto; }
#tab-home .mode-card-title,
#tab-home .mode-card-desc,
#tab-home .mode-card-footer { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
#tab-home .mode-card-footer { flex-wrap: wrap; }

.app-header { gap: 8px; }
.app-header .brand { min-width: 0; gap: 6px; }
.app-header .brand-icon { width: 28px; height: 28px; flex: none; }
.app-header .brand-title { min-width: 0; font-size: clamp(11px, 2.8vw, 15px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.header-actions { flex: none; }

@media (max-width: 600px) {
  #tab-home { padding: 8px; }
  #tab-home .esports-hero-banner { height: clamp(138px, 40vw, 190px); }
  #tab-home .mode-card { min-height: auto; }
}

@media (prefers-reduced-motion: no-preference) {
  #tab-home .mode-card, .match-card {
    transition: transform 180ms ease-out, border-color 180ms ease-out, background-color 180ms ease-out;
  }
}

/* Compact app shell polish; selectors intentionally preserve the existing JS contract. */
.app-header { min-height: 44px; border-color: color-mix(in srgb, var(--border) 75%, transparent); }
.tab-content { padding-inline: clamp(8px, 2vw, 16px); }
.match-card, .wallet-card, .profile-card, .notification-item { box-shadow: var(--shadow-card); }
.desktop-nav-link, .bottom-nav-item { transition-duration: var(--motion-fast); }
.app-container :is(button, a, [role="button"]):focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
@media (max-width: 640px) {
  .app-header { padding-inline: 10px; }
  .tab-content { padding-inline: 8px; }
  .app-container .section-heading { letter-spacing: -0.02em; }
}

@media (max-width: 599px) {
  #explore-section .explore-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  #explore-section .explore-card { aspect-ratio: 4 / 3; }

  #matches-list-container {
    width: 100%;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    padding-inline: 2px;
  }

  #matches-list-container .tournament-match-card {
    width: 100%;
    max-width: none;
  }

  #matches-list-container .tournament-match-card .match-card-body,
  #my-rooms-container .room-card .match-card-body {
    padding: 8px 11px 9px;
    gap: var(--space-1);
  }

  #matches-list-container .tournament-match-card .match-title,
  #my-rooms-container .room-card .match-title {
    min-height: 0;
    font-size: var(--fs-base);
    line-height: 1.2;
    white-space: normal;
    overflow-wrap: anywhere;
    -webkit-line-clamp: unset;
  }

  #matches-list-container .tournament-match-card .match-card-body .btn,
  #my-rooms-container .room-card .room-card-expand {
    min-height: var(--btn-h);
    height: auto;
  }

  #my-rooms-container { gap: 8px; }
  #my-rooms-container .room-card { width: 100%; max-width: 340px; }
}


:root { --screen-animation-scale: 1.8; }


.app-container :is(#tab-matches, #tab-rooms) > .rooms-header-card {
  padding-block: 0.65rem;
  min-height: 0;
}
.app-container :is(#tab-matches, #tab-rooms) > .rooms-header-card .rooms-header-title {
  margin-block: 0 0.25rem;
}
@media (max-width: 768px) {
  .app-container { --bottom-nav-h: 52px; --page-pad: 12px; }
  .app-container .bottom-nav .nav-item span { font-size: var(--fs-xs); }
  .app-container .bottom-nav .nav-icon { height: var(--bottom-nav-icon-size); }
}

.help-inline-link { font: inherit; color: inherit; padding: 0; background: none; border: 0; text-decoration: underline; cursor: pointer; }
.contact-method-card[hidden] { display: none; }
