/* ============================================================ */
/* FriendlyBet - Main Styles                                    */
/* ============================================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  font-family: 'Heebo', -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(180deg, #0a1628 0%, #1a2942 100%);
  color: white;
  min-height: 100vh;
  overflow-x: hidden;
}

body {
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* ============================================================ */
/* App Container & Screens                                      */
/* ============================================================ */

#app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
}

.screen {
  display: none;
  min-height: 100vh;
  animation: fadeIn 0.3s ease-out;
}

.screen.active {
  display: flex;
  flex-direction: column;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================ */
/* Loading Screen                                               */
/* ============================================================ */

#loading-screen {
  justify-content: center;
  align-items: center;
}

.loading-content {
  text-align: center;
}

.logo-large {
  font-size: 80px;
  margin-bottom: 16px;
  animation: bounce 1s ease-in-out infinite;
}

.logo-xl {
  font-size: 96px;
  margin-bottom: 20px;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.loading-title {
  font-size: 28px;
  font-weight: 600;
  color: #d4a853;
  letter-spacing: 3px;
  margin-bottom: 24px;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(212, 168, 83, 0.2);
  border-top-color: #d4a853;
  border-radius: 50%;
  margin: 0 auto;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ============================================================ */
/* Container & Layout                                           */
/* ============================================================ */

.container {
  padding: 24px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* ============================================================ */
/* Top Bar                                                      */
/* ============================================================ */

.topbar {
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 0.5px solid rgba(212, 168, 83, 0.2);
  background: rgba(10, 22, 40, 0.95);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.topbar-title {
  font-size: 16px;
  font-weight: 500;
  color: white;
}

.topbar-title-small {
  font-size: 15px;
  font-weight: 500;
  color: white;
}

.topbar-step {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 1px;
}

.btn-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: #d4a853;
  cursor: pointer;
  font-size: 20px;
  padding: 0;
  border-radius: 8px;
  transition: background 0.2s;
}

.btn-icon:hover, .btn-icon:active {
  background: rgba(212, 168, 83, 0.1);
}

/* ============================================================ */
/* Progress Bar                                                 */
/* ============================================================ */

.progress-bar-container {
  padding: 10px 20px;
  background: rgba(212, 168, 83, 0.05);
}

.progress-bar {
  height: 3px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.progress-bar > div {
  height: 100%;
  background: linear-gradient(90deg, #d4a853 0%, #f4d77f 100%);
  border-radius: 2px;
  transition: width 0.3s ease-out;
}

/* ============================================================ */
/* Hero / Home Screen                                           */
/* ============================================================ */

.hero {
  text-align: center;
  padding: 40px 0 32px;
}

.hero-title {
  font-size: 40px;
  font-weight: 700;
  color: #d4a853;
  letter-spacing: 4px;
  margin-bottom: 8px;
}

.hero-subtitle {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 12px;
}

.hero-description {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
  white-space: pre-line;
}

.action-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 24px 0 10px;
}

/* v2.5.16: low-visual-weight recovery login link on home screen */
.welcome-recovery-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: auto;
  margin: 6px auto 18px;
  padding: 8px 14px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(255, 255, 255, 0.25);
  transition: color 0.15s;
}
.welcome-recovery-link:hover {
  color: #d4a853;
  text-decoration-color: rgba(212, 168, 83, 0.45);
}
.welcome-recovery-link i { font-size: 14px; }

/* v2.5.34: recovery code input - keep all 19 chars (16 + 3 hyphens) on
   one line on every viewport including narrow phones. Specificity
   .form-input.recovery-code-input beats the .form-input-large rule
   (24px + 6px letter-spacing) that previously won by source order. */
.form-input.recovery-code-input {
  font-family: 'SFMono-Regular', Consolas, 'Courier New', monospace;
  font-size: clamp(13px, 4vw, 20px);
  letter-spacing: 0;
  font-weight: 600;
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  overflow-x: hidden;
  text-overflow: clip;
  padding-inline: 10px;
  -webkit-text-fill-color: #d4a853;
  color: #d4a853;
}

/* v2.5.16: The UI was authored Hebrew-first - every topbar back uses
   ti-arrow-right and every primary "Continue" button uses ti-arrow-left.
   That's correct in Hebrew RTL (back points → toward the "back" direction,
   continue points ← toward the forward direction). In English LTR those
   directions are inverted, so we flip the icons here. Scoped to topbar
   icon buttons + primary/secondary CTA buttons so unrelated arrows
   elsewhere stay untouched. */
body.ltr .topbar .btn-icon .ti-arrow-right,
body.ltr .btn-primary .ti-arrow-right,
body.ltr .btn-secondary .ti-arrow-right,
body.ltr .btn-primary .ti-arrow-left,
body.ltr .btn-secondary .ti-arrow-left {
  transform: scaleX(-1);
  display: inline-block;
}

/* v2.5.33: back arrow follows the language convention.
   DOM order [back, title, action]; natural flex direction per language:
     - LTR English: back on LEFT  (visually first)
     - RTL Hebrew:  back on RIGHT (browser flips flex visually)
   Combined with the icon-flip rules below:
     - English: back on LEFT  pointing LEFT  (Tabler ti-arrow-right is flipped)
     - Hebrew:  back on RIGHT pointing RIGHT (Tabler ti-arrow-right unflipped;
                inline back-SVGs that draw a left-pointing arrow get flipped). */

.info-banner {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 8px;
  padding: 12px 14px;
  background: rgba(168, 85, 247, 0.06);
  border: 0.5px solid rgba(168, 85, 247, 0.2);
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 16px;
  text-align: start;
}

.info-banner > i {
  flex-shrink: 0;
  margin-top: 2px;
}

.info-banner a {
  color: #d4a853;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.info-banner a:hover {
  color: #e8bd66;
}

.info-banner i {
  color: #c4b5fd;
  font-size: 16px;
}

/* ============================================================ */
/* Buttons                                                      */
/* ============================================================ */

.btn-primary, .btn-secondary, .btn-whatsapp, .btn-telegram {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Heebo', sans-serif;
  border: none;
  text-align: center;
}

.btn-primary {
  background: #d4a853;
  color: #0a1628;
}

.btn-primary:hover, .btn-primary:active {
  background: #c19542;
  transform: translateY(-1px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: white;
  border: 0.5px solid rgba(212, 168, 83, 0.3);
}

.btn-secondary:hover, .btn-secondary:active {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(212, 168, 83, 0.5);
}

.btn-large {
  padding: 16px 24px;
  font-size: 16px;
}

.btn-small {
  padding: 8px 12px;
  font-size: 12px;
  background: rgba(212, 168, 83, 0.15);
  color: #d4a853;
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  transition: all 0.2s;
}

.btn-small:hover {
  background: rgba(212, 168, 83, 0.25);
}

.btn-whatsapp {
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: white;
}

.btn-telegram {
  background: linear-gradient(135deg, #229ED9 0%, #1B7BB0 100%);
  color: white;
}

/* ============================================================ */
/* Forms                                                        */
/* ============================================================ */

.form-section {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.form-icon {
  font-size: 48px;
  text-align: center;
  margin-bottom: 16px;
}

.form-title {
  font-size: 22px;
  font-weight: 600;
  color: white;
  text-align: center;
  margin-bottom: 8px;
}

.form-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  text-align: center;
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 8px;
  font-weight: 500;
}

.form-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 0.5px solid rgba(212, 168, 83, 0.4);
  color: white;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 16px;
  font-family: 'Heebo', sans-serif;
  outline: none;
  transition: all 0.2s;
  text-align: start;
}

.form-input:focus {
  border-color: #d4a853;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 3px rgba(212, 168, 83, 0.15);
}

.form-input::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.form-input-large {
  font-size: 24px;
  text-align: center;
  letter-spacing: 6px;
  font-weight: 600;
  font-family: 'Heebo', monospace;
  text-transform: uppercase;
}

/* Status messages under inputs */
#nickname-status {
  margin-top: 8px;
  font-size: 12px;
}

.status-checking {
  color: rgba(255, 255, 255, 0.5);
}

.status-available {
  color: #4ade80;
  display: flex;
  align-items: center;
  gap: 4px;
}

.status-taken {
  color: #fb7185;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ============================================================ */
/* Messages                                                     */
/* ============================================================ */

.error-message {
  background: rgba(244, 63, 94, 0.1);
  border: 0.5px solid rgba(244, 63, 94, 0.3);
  color: #fb7185;
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 16px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.warning-banner {
  display: flex;
  gap: 10px;
  background: rgba(251, 191, 36, 0.08);
  border: 0.5px solid rgba(251, 191, 36, 0.3);
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 16px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.5;
}

.warning-banner i {
  color: #fbbf24;
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

.warning-banner strong {
  color: #fbbf24;
}

.hint-text {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

.hint-text i {
  color: #c4b5fd;
}

/* ============================================================ */
/* Pool Found Card                                              */
/* ============================================================ */

.pool-info-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.08) 0%, rgba(212, 168, 83, 0.02) 100%);
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  border-radius: 12px;
  padding: 24px 20px;
  text-align: center;
}

.pool-name {
  font-size: 22px;
  font-weight: 600;
  color: white;
  margin-bottom: 4px;
}

.gold-mono {
  color: #d4a853;
  font-family: monospace;
  letter-spacing: 3px;
  font-weight: 600;
}

.pool-stats {
  margin: 24px 0;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  padding: 16px;
}

.stat-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
  text-align: start;
}

.stat-row:last-child {
  border-bottom: none;
}

.stat-icon-wrap {
  width: 36px;
  height: 36px;
  background: rgba(212, 168, 83, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.stat-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 2px;
}

.stat-value {
  font-size: 14px;
  color: white;
  font-weight: 500;
}

/* ============================================================ */
/* Recovery Code Display                                        */
/* ============================================================ */

.recovery-code-display {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.05) 100%);
  border: 1px solid #d4a853;
  border-radius: 12px;
  padding: 24px 16px;
  margin: 24px 0 16px;
  text-align: center;
}

.recovery-code-text {
  color: #d4a853;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: 3px;
  font-family: monospace;
  word-spacing: 4px;
}

.recovery-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

/* ============================================================ */
/* Pool Code Display (after creation)                          */
/* ============================================================ */

.success-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.success-icon {
  font-size: 64px;
  margin-bottom: 16px;
}

.pool-code-display {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.2) 0%, rgba(212, 168, 83, 0.05) 100%);
  border: 2px solid #d4a853;
  border-radius: 16px;
  padding: 32px 24px;
  margin: 24px 0;
  width: 100%;
}

.pool-code-large {
  font-size: 48px;
  font-weight: 700;
  color: #d4a853;
  letter-spacing: 8px;
  font-family: monospace;
}

.share-actions {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ============================================================ */
/* Suggestion Chips                                             */
/* ============================================================ */

.suggestion-chips {
  margin: 12px 0 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.suggestion-chips > p {
  width: 100%;
}

.chip {
  background: rgba(212, 168, 83, 0.08);
  border: 0.5px solid rgba(212, 168, 83, 0.25);
  color: #d4a853;
  padding: 6px 12px;
  border-radius: 12px;
  font-size: 12px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  transition: all 0.2s;
}

.chip:hover, .chip:active {
  background: rgba(212, 168, 83, 0.15);
  border-color: rgba(212, 168, 83, 0.4);
}

/* ============================================================ */
/* Admin Permissions Card                                       */
/* ============================================================ */

.admin-permissions-card {
  background: rgba(212, 168, 83, 0.06);
  border: 0.5px solid rgba(212, 168, 83, 0.2);
  border-radius: 10px;
  padding: 14px 16px;
  margin: 16px 0;
}

.admin-perm-title {
  font-size: 13px;
  font-weight: 500;
  color: white;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.perm-item {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
}

.perm-item i {
  color: #4ade80;
  font-size: 14px;
}

/* ============================================================ */
/* Dashboard                                                    */
/* ============================================================ */

.dashboard-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 24px;
}

.stat-block {
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

.stat-block-gold {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.12) 0%, rgba(212, 168, 83, 0.04) 100%);
  border-color: rgba(212, 168, 83, 0.3);
}

.stat-big {
  font-size: 32px;
  font-weight: 600;
  color: white;
  line-height: 1;
  margin-top: 4px;
}

.section-title {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 1px;
  margin: 24px 0 12px;
}

.bet-status-card {
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.bet-status-card.pending {
  background: rgba(212, 168, 83, 0.06);
  border-color: rgba(212, 168, 83, 0.25);
}

.bet-status-card.locked {
  opacity: 0.5;
}

.bet-status-card.completed {
  background: rgba(34, 197, 94, 0.06);
  border-color: rgba(34, 197, 94, 0.25);
}

.bet-status-content {
  flex: 1;
}

.bet-status-title {
  font-size: 14px;
  font-weight: 500;
  color: white;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}
/* v2.5.37: inline SVG used in bet-status-card titles (top scorer ball) */
.bet-status-card .bet-status-icon-svg {
  color: rgba(255, 255, 255, 0.45);
  flex-shrink: 0;
}

.bet-status-subtitle {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
}

.quick-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 24px;
}

.quick-action-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: white;
  font-size: 12px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  transition: all 0.2s;
}

.quick-action-btn:hover, .quick-action-btn:active {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(212, 168, 83, 0.3);
}

.quick-action-btn i {
  font-size: 22px;
}

/* ============================================================ */
/* Toast Notifications                                          */
/* ============================================================ */

#toast-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  pointer-events: none;
}

.toast {
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  margin-bottom: 8px;
  font-size: 14px;
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  backdrop-filter: blur(10px);
  animation: slideDown 0.3s ease-out;
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toast.success { border-color: rgba(34, 197, 94, 0.5); }
.toast.error { border-color: rgba(244, 63, 94, 0.5); }

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================ */
/* Utility classes                                              */
/* ============================================================ */

.gold { color: #d4a853 !important; }
.text-faint { color: rgba(255, 255, 255, 0.6) !important; }
.text-faint-2 { color: rgba(255, 255, 255, 0.4) !important; }

/* ============================================================ */
/* Menu Button - more prominent                                 */
/* ============================================================ */

.menu-button {
  width: 44px !important;
  height: 44px !important;
  background: rgba(212, 168, 83, 0.15) !important;
  border: 0.5px solid rgba(212, 168, 83, 0.35) !important;
  border-radius: 12px !important;
  font-size: 22px !important;
  color: #d4a853 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.menu-button svg {
  width: 22px;
  height: 22px;
  stroke: #d4a853;
}

.menu-button:hover, .menu-button:active {
  background: rgba(212, 168, 83, 0.25) !important;
  border-color: rgba(212, 168, 83, 0.55) !important;
  transform: scale(0.95);
}

/* ============================================================ */
/* Pool Code Card - prominent in dashboard                      */
/* ============================================================ */

.pool-code-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.04) 100%);
  border: 0.5px solid rgba(212, 168, 83, 0.4);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.pool-code-card:hover, .pool-code-card:active {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.22) 0%, rgba(212, 168, 83, 0.08) 100%);
  border-color: rgba(212, 168, 83, 0.6);
  transform: translateY(-1px);
}

.pool-code-card-content {
  flex: 1;
}

.pool-code-display-inline {
  font-size: 24px;
  font-weight: 700;
  color: #d4a853;
  letter-spacing: 5px;
  font-family: monospace;
  margin-top: 2px;
}

.pool-code-share {
  display: flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: white;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
}

.pool-code-share i {
  font-size: 16px;
}

/* ============================================================ */
/* Bottom Sheet Menu                                            */
/* ============================================================ */

.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease-out;
  backdrop-filter: blur(4px);
}

.menu-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.menu-sheet {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 480px;
  max-height: 88vh;
  background: linear-gradient(180deg, #0f1f3a 0%, #0a1628 100%);
  border-radius: 24px 24px 0 0;
  z-index: 101;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  border-top: 0.5px solid rgba(212, 168, 83, 0.3);
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5);
  -webkit-overflow-scrolling: touch;
}

.menu-sheet.active {
  transform: translateX(-50%) translateY(0);
}

.menu-handle {
  width: 40px;
  height: 4px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  margin: 10px auto 16px;
  flex-shrink: 0;
}

/* User section in menu */
.menu-user-section {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px 20px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.08);
}

.menu-avatar {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #d4a853 0%, #b88a3a 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #0a1628;
  font-size: 20px;
  font-weight: 600;
  flex-shrink: 0;
}

.menu-user-details {
  flex: 1;
  min-width: 0;
}

.menu-user-name {
  font-size: 16px;
  font-weight: 500;
  color: white;
  margin-bottom: 2px;
}

.menu-user-role {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
}

.menu-pool-badge {
  background: rgba(212, 168, 83, 0.1);
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  border-radius: 8px;
  padding: 6px 10px;
  text-align: center;
  flex-shrink: 0;
}

.menu-pool-name {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 1px;
}

.menu-pool-code-mini {
  font-size: 14px;
  font-weight: 600;
  color: #d4a853;
  font-family: monospace;
  letter-spacing: 2px;
}

/* Menu sections */
.menu-section {
  padding: 12px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}

.menu-section:last-of-type {
  border-bottom: none;
}

.menu-section-title {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 1px;
  padding: 6px 20px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.menu-section-title i {
  font-size: 14px;
}

/* Menu items */
.menu-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  background: transparent;
  border: none;
  color: white;
  font-size: 15px;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  text-align: start;
  transition: background 0.15s;
}

.menu-item:hover, .menu-item:active {
  background: rgba(255, 255, 255, 0.04);
}

.menu-item > i:first-child {
  font-size: 20px;
  flex-shrink: 0;
  width: 24px;
  text-align: center;
}

.menu-item > span {
  flex: 1;
}

.menu-arrow {
  font-size: 16px !important;
  color: rgba(255, 255, 255, 0.3);
}

/* v2.5.26: inline SVG icons in the side menu */
.menu-icon-svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #d4a853;
  margin-inline-end: 4px;
}
.menu-section-title .menu-icon-svg {
  width: 16px;
  height: 16px;
}
.menu-item-danger .menu-icon-svg {
  color: #ef4444;
}
.menu-arrow-svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.35);
}
/* In English LTR the chevron should point in the trailing direction.
   Default SVG draws "<" pointing left (correct for Hebrew RTL). Flip in LTR. */
body.ltr .menu-arrow-svg {
  transform: scaleX(-1);
}

.menu-value {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

.menu-item-share {
  background: rgba(37, 211, 102, 0.08);
}

.menu-item-share:hover, .menu-item-share:active {
  background: rgba(37, 211, 102, 0.15);
}

.menu-item-danger {
  color: #fb7185;
}

.menu-item-danger > i:first-child {
  color: #fb7185 !important;
}

.menu-footer {
  text-align: center;
  padding: 20px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.3);
  display: flex;
  justify-content: center;
  gap: 8px;
}

.menu-version {
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: monospace;
}

/* ============================================================ */
/* Settings prompt (in share screen)                            */
/* ============================================================ */

.settings-prompt {
  background: rgba(168, 85, 247, 0.06);
  border: 0.5px solid rgba(168, 85, 247, 0.25);
  border-radius: 12px;
  padding: 14px;
  margin: 20px 0 16px;
  width: 100%;
}

.settings-prompt-content {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}

.settings-prompt-content > i {
  font-size: 20px;
  flex-shrink: 0;
  margin-top: 1px;
}

.settings-prompt-title {
  font-size: 13px;
  color: white;
  font-weight: 500;
  margin-bottom: 3px;
}

.settings-prompt-subtitle {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.4;
}

.btn-settings {
  width: 100%;
  background: rgba(168, 85, 247, 0.15);
  color: #c4b5fd;
  border: 0.5px solid rgba(168, 85, 247, 0.4);
  padding: 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: 'Heebo', sans-serif;
  transition: all 0.2s;
}

.btn-settings:hover, .btn-settings:active {
  background: rgba(168, 85, 247, 0.25);
}

.section-divider {
  position: relative;
  margin: 20px 0 16px;
  text-align: center;
  width: 100%;
}

.section-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.1);
}

.section-divider > span {
  position: relative;
  background: #0a1628;
  padding: 0 12px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 1px;
}

/* ============================================================ */
/* Settings Screen                                              */
/* ============================================================ */

.lock-banner {
  background: linear-gradient(90deg, rgba(251, 191, 36, 0.15) 0%, rgba(251, 191, 36, 0.05) 100%);
  border-bottom: 0.5px solid rgba(251, 191, 36, 0.3);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.lock-banner > i {
  color: #fbbf24;
  font-size: 22px;
  flex-shrink: 0;
}

.lock-banner strong {
  display: block;
  color: #fbbf24;
  font-size: 13px;
  margin-bottom: 2px;
}

.lock-banner > div > div {
  color: rgba(255, 255, 255, 0.7);
  font-size: 11px;
}

.settings-section {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  margin-bottom: 12px;
  overflow: hidden;
}

.settings-section-title {
  font-size: 12px;
  font-weight: 500;
  color: #d4a853;
  letter-spacing: 1px;
  padding: 12px 16px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 0.5px solid rgba(212, 168, 83, 0.15);
  background: rgba(212, 168, 83, 0.04);
}

.settings-section-title i {
  font-size: 16px;
}

.settings-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  gap: 12px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}

.settings-row:last-of-type {
  border-bottom: none;
}

.settings-row-display {
  background: rgba(0, 0, 0, 0.15);
}

.settings-label {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
  min-width: 0;
}

.settings-label i {
  font-size: 16px;
  color: rgba(212, 168, 83, 0.7);
  flex-shrink: 0;
}

.settings-input {
  background: rgba(255, 255, 255, 0.05);
  border: 0.5px solid rgba(255, 255, 255, 0.15);
  color: white;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 13px;
  font-family: 'Heebo', sans-serif;
  text-align: start;
  max-width: 180px;
  outline: none;
}

.settings-input:focus {
  border-color: #d4a853;
  background: rgba(255, 255, 255, 0.08);
}

.settings-input-small {
  max-width: 80px;
  text-align: center;
}

.settings-value {
  font-size: 14px;
  color: white;
  font-weight: 500;
}

.settings-value-mono {
  font-size: 16px;
  color: #d4a853;
  font-family: monospace;
  font-weight: 600;
  letter-spacing: 2px;
}

.settings-help {
  padding: 4px 16px 10px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.5;
  background: rgba(0, 0, 0, 0.1);
}

.settings-help .help-active {
  color: #d4a853;
  display: block;
  margin-bottom: 2px;
}

.settings-help .help-inactive {
  color: rgba(255, 255, 255, 0.4);
  font-size: 10px;
}

/* Toggle group */
.settings-toggle-group {
  display: inline-flex;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 8px;
  padding: 3px;
  gap: 2px;
}

.toggle-option {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  transition: all 0.2s;
}

.toggle-option.active {
  background: #d4a853;
  color: #0a1628;
  font-weight: 500;
}

.toggle-option:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 26px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.15);
  transition: 0.3s;
  border-radius: 26px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  inset-inline-start: 3px;
  bottom: 3px;
  background: white;
  transition: 0.3s;
  border-radius: 50%;
}

input:checked + .slider {
  background: #d4a853;
}

input:checked + .slider:before {
  transform: translateX(-20px);
}

body.ltr input:checked + .slider:before {
  transform: translateX(20px);
}

/* Risk marker centering in LTR */
body.ltr .sim-risk-marker {
  transform: translateX(-50%);
}

input:disabled + .slider {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Multipliers detail */
.multiplier-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}

.multiplier-row:last-child {
  border-bottom: none;
}

.mult-emoji {
  font-size: 18px;
}

.mult-name {
  flex: 1;
}

.mult-value {
  color: #d4a853;
  font-weight: 500;
  font-family: monospace;
}

/* v2.5.3: multipliers info block inside wizard step 2 */
.wizard-multipliers-info {
  margin-top: 18px;
  padding: 14px 16px 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(212, 168, 83, 0.18);
  border-radius: 12px;
}

.wizard-multipliers-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 6px;
}

.wizard-multipliers-title .gold {
  color: #d4a853;
}

.wizard-multipliers-help {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 8px;
}

.wizard-multipliers-rows .multiplier-row {
  padding: 6px 0;
}

/* v2.5.34: stepper inside multiplier row (custom mode) - tighter than the
   scoring-rules stepper since the row is denser. */
.wizard-multipliers-rows .mult-stepper {
  margin-inline-start: auto;
}
.wizard-multipliers-rows .mult-input {
  width: 56px;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  padding: 4px 4px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(212, 168, 83, 0.35);
  border-radius: 8px;
  color: #d4a853;
}

/* v2.5.34: collapsible per-team multipliers - visually minimal until opened. */
.wizard-team-mults {
  margin-top: 14px;
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.10), rgba(212, 168, 83, 0.04));
  border-radius: 10px;
  border: 1px dashed rgba(212, 168, 83, 0.55);
  overflow: hidden;
}
.wizard-team-mults[open] {
  background: rgba(0, 0, 0, 0.22);
  border-style: solid;
  border-color: rgba(212, 168, 83, 0.45);
}
/* v2.5.38: stronger button-like affordance so users understand the row
   is interactive. Gold tint + "Open / Close" pill + animated chevron. */
.wizard-team-mults-summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13.5px;
  font-weight: 700;
  color: #d4a853;
  user-select: none;
  transition: background 0.15s;
}
.wizard-team-mults-summary:hover {
  background: rgba(212, 168, 83, 0.08);
}
.wizard-team-mults-summary:active {
  background: rgba(212, 168, 83, 0.14);
}
.wizard-team-mults-summary::-webkit-details-marker { display: none; }
.wizard-team-mults-summary > i:first-child { color: #d4a853; font-size: 18px; }
.wizard-team-mults-summary > span { flex: 1; }
.wizard-team-mults-chevron {
  transition: transform 0.2s ease;
  color: #d4a853;
  font-size: 18px;
  background: rgba(212, 168, 83, 0.15);
  border-radius: 50%;
  padding: 3px;
}
.wizard-team-mults-summary:hover .wizard-team-mults-chevron {
  background: rgba(212, 168, 83, 0.3);
}
.wizard-team-mults[open] .wizard-team-mults-chevron { transform: rotate(180deg); }
.wizard-team-mults-hint {
  padding: 0 12px 8px;
  font-size: 11.5px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.55);
}
.wizard-team-mults-grid {
  padding: 6px 8px 10px;
  display: grid;
  /* v2.5.39: stepper buttons (-/+ around the value) make each row wider,
     so collapse to a single column on narrow phones and let it grow on
     wider viewports. */
  grid-template-columns: 1fr;
  gap: 4px 8px;
  max-height: 360px;
  overflow-y: auto;
}
@media (min-width: 420px) {
  .wizard-team-mults-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 640px) {
  .wizard-team-mults-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.wizard-team-mult-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 6px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid transparent;
  font-size: 12px;
}
.wizard-team-mult-row.overridden {
  background: rgba(212, 168, 83, 0.08);
  border-color: rgba(212, 168, 83, 0.35);
}
.wizard-team-mult-flag { font-size: 16px; line-height: 1; }
.wizard-team-mult-name {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: rgba(255, 255, 255, 0.85);
}
/* v2.5.39: stepper wraps the input with -/+ buttons */
.wizard-team-mult-stepper {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}
.wizard-team-mult-btn {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid rgba(212, 168, 83, 0.35);
  background: rgba(212, 168, 83, 0.08);
  color: #d4a853;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-shrink: 0;
  transition: background 0.12s;
}
.wizard-team-mult-btn:hover { background: rgba(212, 168, 83, 0.2); }
.wizard-team-mult-btn:active { transform: scale(0.92); }
.wizard-team-mult-input {
  width: 42px;
  text-align: center;
  font-size: 12.5px;
  font-weight: 600;
  padding: 3px 2px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(212, 168, 83, 0.3);
  border-radius: 6px;
  color: #d4a853;
  flex-shrink: 0;
}
.wizard-team-mults-reset {
  display: block;
  margin: 4px 10px 10px auto;
  background: transparent;
  border: 1px solid rgba(212, 168, 83, 0.35);
  color: #d4a853;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 11.5px;
  cursor: pointer;
}
.wizard-team-mults-reset:hover {
  background: rgba(212, 168, 83, 0.08);
}

/* v2.5.27: explanation paragraph for the risk-multipliers block */
.wizard-multipliers-explain {
  margin-top: 12px;
  padding: 10px 12px;
  background: rgba(0, 0, 0, 0.18);
  border-radius: 8px;
}
.wizard-multipliers-explain-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: #d4a853;
  margin-bottom: 4px;
}
.wizard-multipliers-explain-body {
  font-size: 12.5px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.7);
}

/* Scoring */
.scoring-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}

.scoring-row:last-of-type {
  border-bottom: none;
}

.scoring-row-highlight {
  background: rgba(212, 168, 83, 0.04);
}

.scoring-stage {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
}

.scoring-stage i {
  font-size: 16px;
}

.scoring-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.score-btn {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.05);
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  color: #d4a853;
  border-radius: 8px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 500;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Heebo', sans-serif;
}

.score-btn:hover, .score-btn:active {
  background: rgba(212, 168, 83, 0.15);
  border-color: #d4a853;
}

.score-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.score-value {
  min-width: 24px;
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  color: white;
  font-family: monospace;
}

.btn-reset-scoring {
  width: calc(100% - 32px);
  margin: 8px 16px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px dashed rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.6);
  padding: 8px;
  border-radius: 6px;
  font-size: 11px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s;
}

.btn-reset-scoring:hover {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.8);
}

/* Bonus options */
.bonus-options {
  display: flex;
  gap: 6px;
}

.bonus-btn {
  width: 42px;
  height: 36px;
  background: rgba(255, 255, 255, 0.05);
  border: 0.5px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
  font-family: 'Heebo', sans-serif;
}

.bonus-btn.active {
  background: #d4a853;
  border-color: #d4a853;
  color: #0a1628;
}

.bonus-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Save area */
.settings-save-area {
  margin: 24px 0 16px;
  padding: 16px;
  background: rgba(212, 168, 83, 0.04);
  border: 0.5px solid rgba(212, 168, 83, 0.2);
  border-radius: 12px;
}

/* Danger zone */
.settings-danger {
  background: rgba(244, 63, 94, 0.04) !important;
  border-color: rgba(244, 63, 94, 0.2) !important;
  margin-top: 24px !important;
}

.danger-title {
  color: #fb7185 !important;
  background: rgba(244, 63, 94, 0.06) !important;
  border-bottom-color: rgba(244, 63, 94, 0.15) !important;
}

.btn-danger {
  width: calc(100% - 32px);
  margin: 12px 16px;
  background: rgba(244, 63, 94, 0.1);
  color: #fb7185;
  border: 0.5px solid rgba(244, 63, 94, 0.3);
  padding: 12px;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Heebo', sans-serif;
  font-weight: 500;
  transition: all 0.15s;
}

.btn-danger:hover, .btn-danger:active {
  background: rgba(244, 63, 94, 0.18);
}

.danger-help {
  color: rgba(244, 63, 94, 0.6) !important;
}

/* ============================================================ */
/* Group Betting Screen                                         */
/* ============================================================ */

.topbar-center {
  text-align: center;
  flex: 1;
}

.group-progress-area {
  padding: 12px 20px;
  background: linear-gradient(90deg, rgba(212, 168, 83, 0.12) 0%, rgba(212, 168, 83, 0.04) 100%);
  border-bottom: 0.5px solid rgba(212, 168, 83, 0.2);
}

.group-progress-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.progress-counter {
  font-size: 12px;
}

.progress-numbers {
  display: flex;
  align-items: baseline;
  gap: 3px;
}

.gold-bold {
  color: #d4a853;
  font-weight: 600;
  font-size: 16px;
  font-family: monospace;
}

.picks-validation {
  margin-top: 8px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 11px;
  text-align: center;
}

.picks-validation.hidden {
  display: none;
}

.picks-validation.success {
  background: rgba(34, 197, 94, 0.1);
  color: #4ade80;
  border: 0.5px solid rgba(34, 197, 94, 0.3);
}

.picks-validation.warning {
  background: rgba(251, 191, 36, 0.1);
  color: #fbbf24;
  border: 0.5px solid rgba(251, 191, 36, 0.3);
}

.picks-validation.error {
  background: rgba(244, 63, 94, 0.1);
  color: #fb7185;
  border: 0.5px solid rgba(244, 63, 94, 0.3);
}

/* Group instructions */
.group-instructions {
  text-align: center;
  /* v2.5.35: tighter so the betting screen fits above the fold on mobile */
  margin-bottom: 12px;
}

.group-title-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 16px;
  color: white;
  font-weight: 500;
  margin-bottom: 4px;
}

.group-letter-large {
  color: #d4a853;
  font-size: 24px;
  font-weight: 700;
  font-family: monospace;
}

.group-subtitle {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* Teams list */
.teams-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  /* v2.5.35: tighter for above-the-fold mobile layout */
  margin-bottom: 10px;
}

.team-card {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.2s;
  opacity: 0.85;
  position: relative;
}

.team-card:hover, .team-card:active {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.15);
}

.team-card.selected {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.2) 0%, rgba(212, 168, 83, 0.05) 100%);
  border-color: #d4a853;
  opacity: 1;
}

.team-flag {
  width: 40px;
  height: 28px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 22px;
  overflow: hidden;
}

.team-info {
  flex: 1;
  min-width: 0;
}

.team-name {
  color: white;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 3px;
}

.team-card:not(.selected) .team-name {
  color: rgba(255, 255, 255, 0.85);
}

.team-tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 9px;
  font-weight: 500;
}

.team-tier-favorite {
  background: rgba(212, 168, 83, 0.9);
  color: #0a1628;
}

.team-tier-contender {
  background: rgba(192, 192, 192, 0.25);
  color: #f9fafb;
}

.team-tier-underdog {
  background: rgba(205, 127, 50, 0.3);
  color: #fbbf24;
}

.team-checkbox {
  width: 28px;
  height: 28px;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s;
  color: transparent;
}

/* v2.4.5: the SELECTED state now uses a clear SVG checkmark inside a
   green-tinted circle. Previously the "✓" character was rendered via a
   ::after pseudo-element which didn't always render crisply (especially
   on Windows). The SVG is sharp at any size and reads instantly. */
.team-card.selected .team-checkbox {
  background: #10b981;
  border-color: #10b981;
  color: #fff;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.18);
}
.team-checkbox svg {
  width: 16px;
  height: 16px;
  stroke-width: 3;
  display: block;
}

/* Group picks info */
.group-picks-info {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  /* v2.5.35: slimmer to keep two-phase betting page above the fold */
  padding: 7px 12px;
  margin-bottom: 10px;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.group-picks-info.valid {
  background: rgba(34, 197, 94, 0.08);
  color: #4ade80;
  border: 0.5px solid rgba(34, 197, 94, 0.25);
}

.group-picks-info.invalid {
  background: rgba(251, 191, 36, 0.08);
  color: #fbbf24;
  border: 0.5px solid rgba(251, 191, 36, 0.25);
}

/* Nav buttons */
.group-nav-buttons {
  display: flex;
  gap: 10px;
  /* v2.5.35: slimmer to keep this row above the fold */
  margin-bottom: 14px;
}

/* v2.5.27: prev/next group chevrons were drawn for Hebrew RTL (prev →,
   next ←). In English LTR that's backwards. Flip both in LTR so they
   point in the correct logical direction for the reading flow. */
body.ltr #prev-group-btn svg,
body.ltr #next-group-btn svg {
  transform: scaleX(-1);
}

.btn-half {
  flex: 1;
}

.btn-finish {
  margin-bottom: 24px;
  background: linear-gradient(135deg, #4ade80 0%, #22c55e 100%);
  color: white;
}

.btn-finish:hover, .btn-finish:active {
  background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
}

/* Quick groups navigation */
.quick-groups-nav-section {
  margin-top: 12px;
  padding-top: 16px;
  border-top: 0.5px solid rgba(255, 255, 255, 0.08);
}

.section-title-small {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
  margin-bottom: 10px;
  text-align: center;
}

/* v2.5.18: single-row grid of all 12 group pills. The pills are a single
   letter each (A..L), so 12 columns fit even on a 360px viewport - down
   to ~26px per pill which still comfortably shows one character. */
.quick-groups-nav {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 4px;
}

.group-nav-pill {
  position: relative;
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  padding: 7px 0;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 600;
  font-family: monospace;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
  min-width: 0;
}

/* On very narrow phones (< 360px) tighten further so it still fits one row */
@media (max-width: 360px) {
  .quick-groups-nav { gap: 3px; }
  .group-nav-pill { padding: 6px 0; font-size: 11px; }
}

.group-nav-pill:hover {
  background: rgba(255, 255, 255, 0.08);
}

.group-nav-pill.current {
  background: #d4a853;
  color: #0a1628;
  border-color: #d4a853;
  box-shadow: 0 0 0 2px rgba(212, 168, 83, 0.2);
}

/* v2.4.1: replace tiny 6px colored dots with full-pill tinting so the
   state is readable at a glance instead of relying on a corner pixel.
   The `has-two` / `has-three` / `partial` classes are set in app.js
   based on how many teams were picked in each group. */
.group-nav-pill.has-three {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.45);
  color: #6ee7b7;
}
.group-nav-pill.has-two {
  background: rgba(212, 168, 83, 0.12);
  border-color: rgba(212, 168, 83, 0.4);
  color: #fff;
}
.group-nav-pill.partial {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.45);
  color: #fca5a5;
}

/* Kill the legacy corner dots - the full-pill tint above replaces them. */
.group-nav-pill.completed::after,
.group-nav-pill.partial::after { display: none; }

/* Completion card */
.completion-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.04) 100%);
  border: 1px solid rgba(212, 168, 83, 0.3);
  border-radius: 12px;
  padding: 20px;
  margin: 20px 0;
  display: flex;
  align-items: center;
  width: 100%;
}

.completion-stat {
  flex: 1;
  text-align: center;
}

.completion-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 6px;
  letter-spacing: 1px;
}

.completion-value {
  font-size: 28px;
  font-weight: 600;
  color: white;
}

.completion-divider {
  width: 1px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
}

/* ============================================================ */
/* Status Modal                                                  */
/* ============================================================ */

.status-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease-out;
  backdrop-filter: blur(6px);
}

.status-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.status-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: calc(100% - 32px);
  max-width: 420px;
  max-height: 90vh;
  background: linear-gradient(180deg, #1a2942 0%, #0f1f3a 100%);
  border-radius: 20px;
  z-index: 201;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  border: 1px solid rgba(212, 168, 83, 0.3);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.status-modal.active {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

.status-modal-content {
  padding: 28px 20px 20px;
  position: relative;
  text-align: center;
}

.status-modal-close {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.05);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Heebo', sans-serif;
  transition: all 0.2s;
}

.status-modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

.status-modal-icon {
  font-size: 48px;
  margin-bottom: 8px;
  animation: bounce 1s ease-in-out;
}

.status-modal-title {
  font-size: 22px;
  font-weight: 600;
  color: white;
  margin-bottom: 4px;
}

.status-modal-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 20px;
}

.status-modal-summary {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-bottom: 20px;
}

.status-summary-item {
  text-align: center;
  flex: 1;
}

.status-summary-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 4px;
  letter-spacing: 1px;
}

.status-summary-value {
  font-size: 28px;
  font-weight: 700;
  color: white;
  font-family: monospace;
}

.status-summary-divider {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.1);
}

.status-modal-section {
  background: rgba(251, 191, 36, 0.06);
  border: 0.5px solid rgba(251, 191, 36, 0.2);
  border-radius: 10px;
  padding: 12px;
  margin-top: 8px;
}

.status-section-title {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 12px;
  text-align: start;
}

.status-modal-groups {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.status-modal-group-btn {
  background: rgba(212, 168, 83, 0.15);
  border: 0.5px solid rgba(212, 168, 83, 0.4);
  color: #d4a853;
  padding: 12px 4px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  font-family: monospace;
  cursor: pointer;
  transition: all 0.2s;
}

.status-modal-group-btn:hover, .status-modal-group-btn:active {
  background: #d4a853;
  color: #0a1628;
  transform: translateY(-2px);
}

/* ============================================================ */
/* Floating Status Button                                       */
/* ============================================================ */

.floating-status-btn {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  color: #0a1628;
  border: none;
  padding: 12px 20px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 600;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 50;
  box-shadow: 0 8px 24px rgba(251, 191, 36, 0.35), 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.3s;
  animation: floatingAppear 0.4s ease-out;
}

.floating-status-btn:hover, .floating-status-btn:active {
  transform: translateX(-50%) translateY(-2px);
  box-shadow: 0 12px 32px rgba(251, 191, 36, 0.5), 0 2px 8px rgba(0, 0, 0, 0.3);
}

.floating-status-emoji {
  font-size: 18px;
}

.floating-status-text {
  font-family: monospace;
  font-size: 15px;
}

@keyframes floatingAppear {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

/* Make sure content has padding when floating button is visible */
#group-betting-screen .container {
  padding-bottom: 80px;
}

/* ============================================================ */
/* Disabled "Next" button styling                                */
/* ============================================================ */

.btn-primary.btn-disabled-warning {
  background: rgba(244, 63, 94, 0.15) !important;
  color: #fb7185 !important;
  border: 0.5px solid rgba(244, 63, 94, 0.4) !important;
  cursor: not-allowed !important;
}

.btn-primary.btn-disabled-warning:hover,
.btn-primary.btn-disabled-warning:active {
  transform: none !important;
  background: rgba(244, 63, 94, 0.15) !important;
}

.next-btn-warning-text {
  font-size: 10px !important;
  line-height: 1.2;
}

/* v2.4.1: legacy corner dots removed - states now full-pill tinted above */
.group-nav-pill.has-two::after,
.group-nav-pill.has-three::after { display: none !important; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-4px); }
  40%, 80% { transform: translateX(4px); }
}

/* ============================================================ */
/* Leaderboard Screen                                           */
/* ============================================================ */

.lb-pool-info {
  text-align: center;
  padding: 16px 0 20px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 20px;
}

.lb-pool-name {
  font-size: 18px;
  font-weight: 600;
  color: white;
  margin-bottom: 4px;
}

.lb-pool-meta {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

.lb-dot {
  margin: 0 6px;
  color: rgba(255, 255, 255, 0.3);
}

/* Podium */
.lb-podium {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 28px;
  align-items: end;
  min-height: 180px;
}

.podium-spot {
  text-align: center;
  border-radius: 12px;
  padding: 12px 6px;
  position: relative;
}

.podium-spot.first {
  background: linear-gradient(180deg, rgba(212, 168, 83, 0.3) 0%, rgba(212, 168, 83, 0.1) 100%);
  border: 1px solid #d4a853;
  order: 2;
  padding-top: 24px;
  padding-bottom: 16px;
}

.podium-spot.second {
  background: linear-gradient(180deg, rgba(192, 192, 192, 0.15) 0%, rgba(192, 192, 192, 0.05) 100%);
  border: 0.5px solid rgba(192, 192, 192, 0.3);
  order: 1;
  margin-top: 16px;
}

.podium-spot.third {
  background: linear-gradient(180deg, rgba(205, 127, 50, 0.15) 0%, rgba(205, 127, 50, 0.05) 100%);
  border: 0.5px solid rgba(205, 127, 50, 0.3);
  order: 3;
  margin-top: 32px;
}

.podium-medal {
  font-size: 28px;
  margin-bottom: 8px;
}

.podium-first-crown {
  font-size: 32px;
}

.podium-name {
  font-size: 13px;
  font-weight: 500;
  color: white;
  margin-bottom: 4px;
  word-break: break-word;
}

.podium-points {
  font-size: 18px;
  font-weight: 700;
  color: #d4a853;
  font-family: monospace;
}

.podium-points-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
}

/* Full list */
.lb-full-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 12px;
}

.lb-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.lb-row.is-me {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.04) 100%);
  border-color: rgba(212, 168, 83, 0.4);
}

.lb-rank {
  font-size: 15px;
  font-weight: 700;
  color: #d4a853;
  font-family: monospace;
  min-width: 28px;
  text-align: center;
}

.lb-row:not(.is-me) .lb-rank {
  color: rgba(255, 255, 255, 0.5);
}

.lb-avatar-small {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #d4a853 0%, #b88a3a 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #0a1628;
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.lb-info {
  flex: 1;
  min-width: 0;
}

.lb-name {
  font-size: 14px;
  font-weight: 500;
  color: white;
  display: flex;
  align-items: center;
  gap: 6px;
}

.lb-badge {
  font-size: 9px;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(212, 168, 83, 0.2);
  color: #d4a853;
}

/* Admin badge - styled like a shield/medal */
.admin-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 9px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  background: linear-gradient(135deg, #d4a853 0%, #b88a3a 100%);
  color: #0a1628;
  letter-spacing: 0.3px;
  vertical-align: 1px;
  box-shadow: 0 1px 3px rgba(212, 168, 83, 0.3);
}

.admin-badge::before {
  content: "✓";
  font-size: 8px;
  font-weight: 700;
  margin-inline-end: 1px;
}

.lb-meta {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
}

.lb-points {
  font-size: 16px;
  font-weight: 700;
  color: white;
  font-family: monospace;
  text-align: left;
}

.lb-points-label {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 1px;
  text-align: left;
}

/* Empty state */
.lb-empty {
  text-align: center;
  padding: 40px 20px;
}

.lb-empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
  opacity: 0.6;
}

.lb-empty-title {
  font-size: 16px;
  font-weight: 500;
  color: white;
  margin-bottom: 6px;
}

.lb-empty-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* ============================================================ */
/* Members Screen                                               */
/* ============================================================ */

.members-summary {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.members-summary-item {
  flex: 1;
  text-align: center;
}

.members-summary-value {
  font-size: 26px;
  font-weight: 700;
  color: white;
  margin-bottom: 4px;
  font-family: monospace;
}

.members-summary-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
}

.members-summary-divider {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.1);
}

.members-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.member-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.member-card.is-me {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.12) 0%, rgba(212, 168, 83, 0.03) 100%);
  border-color: rgba(212, 168, 83, 0.3);
}

.member-card.is-admin .member-name {
  /* Admin badge handled via JS template */
}

.member-info {
  flex: 1;
  min-width: 0;
}

.member-name {
  font-size: 14px;
  font-weight: 500;
  color: white;
  margin-bottom: 3px;
}

.member-status {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.member-status.completed {
  color: #4ade80;
}

.member-status.partial {
  color: #fbbf24;
}

.member-status.not-started {
  color: rgba(255, 255, 255, 0.4);
}

.member-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.member-joined {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.5px;
}

/* ============================================================ */
/* Recovery Display Screen                                      */
/* ============================================================ */

.recovery-info-box {
  background: rgba(168, 85, 247, 0.06);
  border: 0.5px solid rgba(168, 85, 247, 0.25);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.recovery-info-box > svg {
  flex-shrink: 0;
  margin-top: 2px;
}

.recovery-info-title {
  font-size: 14px;
  font-weight: 500;
  color: white;
  margin-bottom: 6px;
}

.recovery-info-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.5;
}

/* ============================================================ */
/* Help Screen                                                  */
/* ============================================================ */

.help-section {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  margin-bottom: 12px;
  overflow: hidden;
}

.help-section-title {
  font-size: 14px;
  font-weight: 600;
  color: #d4a853;
  padding: 14px 16px 10px;
  border-bottom: 0.5px solid rgba(212, 168, 83, 0.15);
  background: rgba(212, 168, 83, 0.04);
}

.help-item {
  padding: 12px 16px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}

.help-item:last-child {
  border-bottom: none;
}

.help-q {
  font-size: 13px;
  font-weight: 500;
  color: white;
  margin-bottom: 6px;
}

.help-a {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.6;
}

.help-footer {
  margin-top: 24px;
  padding: 16px;
  text-align: center;
  border-top: 0.5px solid rgba(255, 255, 255, 0.08);
}

.help-footer-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* ============================================================ */
/* Matches Screen                                               */
/* ============================================================ */

.matches-filter-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  padding: 8px 16px;
  background: rgba(0, 0, 0, 0.2);
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}

.matches-filter-tab {
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  padding: 7px 4px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  transition: all 0.2s;
}

.matches-filter-tab.active {
  background: #d4a853;
  color: #0a1628;
  border-color: #d4a853;
  font-weight: 600;
}

.matches-last-updated {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  text-align: center;
  padding: 8px 0;
}

.matches-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.match-card {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.match-card.live {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.1) 0%, rgba(244, 63, 94, 0.02) 100%);
  border-color: rgba(244, 63, 94, 0.3);
  position: relative;
  overflow: hidden;
}

.match-card.live::before {
  content: '';
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  width: 3px;
  height: 100%;
  background: #fb7185;
  animation: livePulse 1.5s ease-in-out infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.match-card.finished {
  background: rgba(74, 222, 128, 0.04);
  border-color: rgba(74, 222, 128, 0.15);
}

.match-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
}

.match-stage-badge {
  background: rgba(212, 168, 83, 0.15);
  color: #d4a853;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.match-status-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 500;
}

.match-status-badge.live {
  color: #fb7185;
}

.match-status-badge.live::before {
  content: '';
  width: 6px;
  height: 6px;
  background: #fb7185;
  border-radius: 50%;
  animation: livePulse 1s ease-in-out infinite;
}

.match-status-badge.finished {
  color: #4ade80;
}

.match-status-badge.scheduled {
  color: rgba(255, 255, 255, 0.5);
}

.match-teams {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: center;
}

.match-team {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.match-team.away {
  flex-direction: row-reverse;
}

.match-team-flag {
  font-size: 24px;
  flex-shrink: 0;
}

.match-team-name {
  font-size: 14px;
  font-weight: 500;
  color: white;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.match-team-winner {
  color: #d4a853;
  font-weight: 600;
}

.match-team-loser {
  color: rgba(255, 255, 255, 0.4);
}

.match-score {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: monospace;
  font-size: 20px;
  font-weight: 700;
  color: white;
  background: rgba(0, 0, 0, 0.3);
  padding: 4px 12px;
  border-radius: 8px;
  min-width: 70px;
  justify-content: center;
}

.match-score.no-score {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.4);
  font-weight: 500;
}

.match-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  padding-top: 6px;
  border-top: 0.5px solid rgba(255, 255, 255, 0.05);
}

.match-empty {
  text-align: center;
  padding: 60px 20px;
}

.matches-empty {
  text-align: center;
  padding: 60px 20px;
}

.matches-empty-icon {
  font-size: 56px;
  margin-bottom: 12px;
  opacity: 0.4;
}

.matches-empty-title {
  font-size: 16px;
  color: white;
  font-weight: 500;
  margin-bottom: 6px;
}

.matches-empty-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.5;
  max-width: 280px;
  margin: 0 auto;
}

.matches-loading {
  text-align: center;
  padding: 60px 20px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 12px;
}

.loading-spinner-small {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(212, 168, 83, 0.2);
  border-top-color: #d4a853;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 12px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ============================================================ */
/* Admin Members Screen                                         */
/* ============================================================ */

.admin-action-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.1) 0%, rgba(212, 168, 83, 0.02) 100%);
  border: 1px solid rgba(212, 168, 83, 0.3);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-action-card.locked {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.1) 0%, rgba(244, 63, 94, 0.02) 100%);
  border-color: rgba(244, 63, 94, 0.3);
}

.admin-action-icon {
  font-size: 32px;
  flex-shrink: 0;
}

.admin-action-content {
  flex: 1;
  min-width: 0;
}

.admin-action-title {
  font-size: 14px;
  color: white;
  font-weight: 600;
  margin-bottom: 4px;
}

.admin-action-text {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.4;
}

.admin-action-btn {
  background: #d4a853;
  color: #0a1628;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
}

.admin-action-btn:hover {
  background: #e0b966;
  transform: translateY(-1px);
}

.admin-action-card.locked .admin-action-btn {
  background: #4ade80;
  color: #0a1628;
}

/* Admin stats */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 20px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.admin-stat-item {
  text-align: center;
}

.admin-stat-value {
  font-size: 24px;
  font-weight: 700;
  color: #d4a853;
  font-family: monospace;
  margin-bottom: 4px;
}

.admin-stat-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.5px;
}

/* Members list - admin view */
.admin-members-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-member-card {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.2s;
}

.admin-member-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(212, 168, 83, 0.25);
}

.admin-member-card.is-admin {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.08) 0%, rgba(212, 168, 83, 0.02) 100%);
  border-color: rgba(212, 168, 83, 0.2);
}

.admin-member-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d4a853, #b88a3a);
  color: #0a1628;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.admin-member-info {
  flex: 1;
  min-width: 0;
}

.admin-member-name {
  font-size: 13px;
  color: white;
  font-weight: 500;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-member-badge {
  display: inline-block;
  background: linear-gradient(135deg, #d4a853, #b88a3a);
  color: #0a1628;
  font-size: 9px;
  padding: 1px 5px;
  border-radius: 4px;
  margin-inline-end: 4px;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.admin-member-meta {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  display: flex;
  gap: 8px;
}

.admin-member-progress {
  display: flex;
  gap: 4px;
  margin-top: 4px;
}

.admin-member-progress-dot {
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.4);
}

.admin-member-progress-dot.done {
  background: rgba(74, 222, 128, 0.15);
  color: #4ade80;
}

.admin-member-arrow {
  color: rgba(255, 255, 255, 0.3);
  font-size: 20px;
  flex-shrink: 0;
}

/* Admin Action Modal */
.admin-action-modal {
  max-width: 380px;
}

.admin-action-modal-content {
  padding: 24px 20px;
}

.admin-action-user-info {
  text-align: center;
  padding: 16px 0 20px;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 20px;
}

.admin-action-user-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d4a853, #b88a3a);
  color: #0a1628;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 24px;
  margin: 0 auto 12px;
}

.admin-action-user-name {
  font-size: 18px;
  color: white;
  font-weight: 600;
  margin-bottom: 4px;
}

.admin-action-user-meta {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

.admin-action-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.admin-modal-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  color: white;
  padding: 14px 16px;
  border-radius: 10px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: start;
  transition: all 0.2s;
  width: 100%;
}

.admin-modal-btn:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(212, 168, 83, 0.3);
}

.admin-modal-btn-danger {
  border-color: rgba(244, 63, 94, 0.2);
}

.admin-modal-btn-danger:hover {
  background: rgba(244, 63, 94, 0.08);
  border-color: rgba(244, 63, 94, 0.4);
}

.admin-modal-btn-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.admin-modal-btn-text {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

/* ============================================================ */
/* Got It Right / Wrong Indicators                              */
/* ============================================================ */

/* Knockout match cards with results */
.ko-match-card.result-correct {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, rgba(34, 197, 94, 0.02) 100%);
  border-color: rgba(34, 197, 94, 0.4);
  position: relative;
}

.ko-match-card.result-correct::before {
  content: '';
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  width: 3px;
  height: 100%;
  background: #4ade80;
  border-radius: 3px;
}

.ko-match-card.result-wrong {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.05) 0%, rgba(244, 63, 94, 0.02) 100%);
  border-color: rgba(244, 63, 94, 0.25);
  opacity: 0.85;
}

.ko-match-card.result-wrong::before {
  content: '';
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  width: 3px;
  height: 100%;
  background: rgba(244, 63, 94, 0.5);
  border-radius: 3px;
}

/* Result badge in knockout cards */
.ko-result-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  margin-top: 6px;
}

.ko-result-badge.correct {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
}

.ko-result-badge.wrong {
  background: rgba(244, 63, 94, 0.12);
  color: #fb7185;
}

/* Team card result indicators (in group betting) */
.team-card.result-correct {
  border-color: rgba(34, 197, 94, 0.5);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.08) 0%, rgba(255, 255, 255, 0.04) 100%);
}

.team-card.result-wrong {
  border-color: rgba(244, 63, 94, 0.3);
  opacity: 0.75;
}

.team-result-badge {
  position: absolute;
  top: 6px;
  inset-inline-end: 6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.team-result-badge.correct {
  background: #4ade80;
  color: #0a1628;
}

.team-result-badge.wrong {
  background: #fb7185;
  color: white;
}

/* Bracket cards - highlight correct paths */
.bracket-card.result-correct {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15) 0%, #1a2942 100%);
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.3);
}

.bracket-card.result-wrong {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.1) 0%, #1a2942 100%);
  border-color: rgba(244, 63, 94, 0.3);
  opacity: 0.7;
}

/* ============================================================ */
/* Top Scorer Screen                                            */
/* ============================================================ */

.ts-hero {
  text-align: center;
  padding: 24px 16px;
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.02) 100%);
  border: 1px solid rgba(212, 168, 83, 0.3);
  border-radius: 14px;
  margin-bottom: 16px;
}

.ts-hero-trophy {
  font-size: 48px;
  margin-bottom: 8px;
}

.ts-hero-title {
  font-size: 18px;
  color: #d4a853;
  font-weight: 700;
  margin-bottom: 8px;
}

.ts-hero-desc {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
}

.ts-hero-desc strong {
  color: #d4a853;
}

/* Sync info banner */
.ts-sync-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  background: rgba(56, 189, 248, 0.08);
  border: 0.5px solid rgba(56, 189, 248, 0.25);
  border-radius: 10px;
  margin-bottom: 16px;
}

.ts-sync-icon {
  font-size: 20px;
  flex-shrink: 0;
  margin-top: 1px;
}

.ts-sync-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 11px;
  line-height: 1.5;
}

.ts-sync-text strong {
  color: #7dd3fc;
  font-size: 12px;
  font-weight: 600;
}

.ts-sync-text span {
  color: rgba(255, 255, 255, 0.6);
}

/* Current pick card */
.ts-current-pick {
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.1) 0%, rgba(74, 222, 128, 0.02) 100%);
  border: 1px solid rgba(74, 222, 128, 0.4);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
}

.ts-current-label {
  font-size: 11px;
  color: #4ade80;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}

.ts-current-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ts-current-flag {
  font-size: 32px;
  flex-shrink: 0;
}

.ts-current-info {
  flex: 1;
  min-width: 0;
}

.ts-current-name {
  font-size: 15px;
  font-weight: 600;
  color: white;
  margin-bottom: 2px;
}

.ts-current-club {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

.ts-change-btn {
  background: rgba(244, 63, 94, 0.1);
  border: 0.5px solid rgba(244, 63, 94, 0.3);
  color: #fb7185;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
}

.ts-change-btn:hover {
  background: rgba(244, 63, 94, 0.2);
  border-color: rgba(244, 63, 94, 0.5);
}

/* Search wrapper */
.ts-search-wrapper {
  position: relative;
  margin-bottom: 16px;
}

.ts-search-icon {
  position: absolute;
  top: 50%;
  inset-inline-start: 14px;
  transform: translateY(-50%);
  pointer-events: none;
  z-index: 1;
}

.ts-search-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 14px;
  font-family: 'Heebo', sans-serif;
  padding: 12px 44px 12px 44px;
  border-radius: 10px;
  outline: none;
  transition: all 0.2s;
}

.ts-search-input:focus {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(212, 168, 83, 0.4);
}

.ts-search-input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.ts-search-clear {
  position: absolute;
  top: 50%;
  inset-inline-end: 12px;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: rgba(255, 255, 255, 0.6);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.ts-search-clear:hover {
  background: rgba(255, 255, 255, 0.15);
  color: white;
}

/* Section title */
.ts-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 16px 4px 12px;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.5px;
}

.ts-section-title span:first-child {
  font-size: 16px;
}

/* Players list */
.ts-players-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ts-player-card {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.2s;
}

.ts-player-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(212, 168, 83, 0.25);
}

.ts-player-card.selected {
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.1) 0%, rgba(74, 222, 128, 0.02) 100%);
  border-color: rgba(74, 222, 128, 0.4);
}

.ts-player-card.star {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
  border-color: rgba(212, 168, 83, 0.15);
}

.ts-player-flag {
  font-size: 24px;
  flex-shrink: 0;
}

.ts-player-info {
  flex: 1;
  min-width: 0;
}

.ts-player-name {
  font-size: 14px;
  color: white;
  font-weight: 500;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-player-meta {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  display: flex;
  gap: 6px;
  align-items: center;
}

.ts-player-position {
  background: rgba(168, 85, 247, 0.15);
  color: #c4b5fd;
  padding: 1px 6px;
  border-radius: 8px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.ts-player-star-badge {
  background: linear-gradient(135deg, #d4a853, #b88a3a);
  color: #0a1628;
  font-size: 9px;
  padding: 1px 5px;
  border-radius: 4px;
  font-weight: 700;
  margin-inline-end: 4px;
}

.ts-player-action {
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.3);
  font-size: 20px;
}

.ts-player-card.selected .ts-player-action {
  color: #4ade80;
}

/* Highlight matching text in search */
.ts-highlight {
  background: rgba(212, 168, 83, 0.3);
  color: #d4a853;
  font-weight: 700;
  border-radius: 2px;
  padding: 0 2px;
}

/* Loading state */
.ts-loading {
  text-align: center;
  padding: 40px 20px;
  color: rgba(255, 255, 255, 0.4);
  font-size: 13px;
}

/* No results */
.ts-no-results {
  text-align: center;
  padding: 40px 20px;
}

.ts-no-results-icon {
  font-size: 48px;
  margin-bottom: 12px;
  opacity: 0.4;
}

.ts-no-results-title {
  font-size: 15px;
  color: white;
  font-weight: 500;
  margin-bottom: 6px;
}

.ts-no-results-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* Help text */
.ts-help-text {
  margin-top: 20px;
  padding: 12px;
  background: rgba(168, 85, 247, 0.06);
  border: 0.5px solid rgba(168, 85, 247, 0.15);
  border-radius: 8px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.5;
  text-align: center;
}

/* Expand button */
.ts-expand-btn {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.1) 0%, rgba(212, 168, 83, 0.03) 100%);
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  color: #d4a853;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
  transition: all 0.2s;
  width: 100%;
}

.ts-expand-btn:hover {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.05) 100%);
  border-color: rgba(212, 168, 83, 0.5);
  transform: translateY(-1px);
}

.ts-expand-btn:active {
  transform: translateY(0);
}

/* Results count info */
.ts-results-count {
  text-align: center;
  padding: 12px;
  color: rgba(255, 255, 255, 0.4);
  font-size: 11px;
  margin-top: 8px;
}

/* ============================================================ */
/* Top Scorer Locked View                                       */
/* ============================================================ */

.ts-locked-hero {
  text-align: center;
  padding: 32px 16px;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.1) 0%, rgba(168, 85, 247, 0.02) 100%);
  border: 1px solid rgba(168, 85, 247, 0.25);
  border-radius: 14px;
  margin-bottom: 20px;
}

.ts-locked-icon {
  font-size: 56px;
  margin-bottom: 12px;
  filter: grayscale(0.3);
}

.ts-locked-title {
  font-size: 20px;
  color: #c4b5fd;
  font-weight: 700;
  margin-bottom: 6px;
}

.ts-locked-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}

.ts-locked-explanation {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}

.ts-explain-row {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.ts-explain-icon {
  font-size: 24px;
  flex-shrink: 0;
  line-height: 1.2;
}

.ts-explain-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ts-explain-text strong {
  font-size: 13px;
  color: white;
  font-weight: 600;
}

.ts-explain-text span {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.5;
}

/* Countdown card */
.ts-countdown-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.12) 0%, rgba(212, 168, 83, 0.03) 100%);
  border: 1px solid rgba(212, 168, 83, 0.3);
  border-radius: 12px;
  padding: 18px;
  text-align: center;
  margin-bottom: 16px;
}

.ts-countdown-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 8px;
}

.ts-countdown-value {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  margin-bottom: 6px;
}

.ts-countdown-value > span:first-child {
  font-size: 40px;
  font-weight: 700;
  color: #d4a853;
  font-family: monospace;
  line-height: 1;
}

.ts-countdown-unit {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
}

.ts-countdown-date {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
}

.ts-status-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
  padding: 8px;
}

.ts-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* ============================================================ */
/* Knockout Screen                                              */
/* ============================================================ */

.ko-round-tabs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  padding: 10px 12px;
  background: rgba(0, 0, 0, 0.2);
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
  position: sticky;
  top: 0;
  z-index: 5;
}

.ko-tab {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  padding: 8px 4px;
  border-radius: 8px;
  font-size: 11px;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transition: all 0.2s;
}

.ko-tab.active {
  background: #d4a853;
  color: #0a1628;
  border-color: #d4a853;
  font-weight: 600;
}

.ko-tab-label {
  font-size: 11px;
  font-weight: 500;
}

.ko-tab-count {
  font-size: 10px;
  opacity: 0.7;
  font-family: monospace;
}

.ko-tab.active .ko-tab-count {
  opacity: 1;
}

.ko-progress-area {
  padding: 12px 20px;
  background: linear-gradient(90deg, rgba(212, 168, 83, 0.08) 0%, rgba(212, 168, 83, 0.02) 100%);
  border-bottom: 0.5px solid rgba(212, 168, 83, 0.15);
}

.ko-progress-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.ko-progress-numbers {
  display: flex;
  align-items: baseline;
  gap: 3px;
}

.ko-matches-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ko-match-card {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ko-match-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
}

.ko-match-number {
  font-family: monospace;
  font-weight: 600;
}

.ko-match-teams {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 10px;
  align-items: center;
}

.ko-team {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 8px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.ko-team:hover, .ko-team:active {
  background: rgba(255, 255, 255, 0.06);
}

.ko-team.selected {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.25) 0%, rgba(212, 168, 83, 0.1) 100%);
  border-color: #d4a853;
  box-shadow: 0 0 12px rgba(212, 168, 83, 0.2);
}

.ko-team.tbd {
  opacity: 0.4;
  cursor: not-allowed;
}

.ko-team-flag {
  font-size: 22px;
}

.ko-team-name {
  font-size: 11px;
  color: white;
  font-weight: 500;
  line-height: 1.2;
}

.ko-team.tbd .ko-team-name {
  color: rgba(255, 255, 255, 0.4);
  font-style: italic;
}

.ko-vs {
  font-size: 11px;
  color: #d4a853;
  font-weight: 600;
  font-family: monospace;
  padding: 0 4px;
}

.ko-match-points {
  font-size: 10px;
  text-align: center;
  color: rgba(255, 255, 255, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
}

.ko-match-points-value {
  background: rgba(212, 168, 83, 0.15);
  color: #d4a853;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 600;
  font-family: monospace;
}

/* Final declaration in match card */
.ko-final-declaration {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 10px;
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.2) 0%, rgba(212, 168, 83, 0.05) 100%);
  border: 0.5px solid rgba(212, 168, 83, 0.4);
  border-radius: 8px;
  font-size: 12px;
  color: #d4a853;
}

.ko-final-icon {
  font-size: 16px;
}

.ko-final-text strong {
  font-weight: 700;
}

/* Floating Bracket button - prominent, always visible.
   v2.5.0: positioned at the TOP end of the screen (inside the topbar area)
   so it never overlaps the nav buttons at the bottom. Anchored to the END
   side of the 480px-max app container regardless of viewport width. */
.floating-bracket-btn {
  position: fixed;
  top: 10px;
  inset-inline-end: max(12px, calc(50vw - 228px));
  left: auto;
  bottom: auto;
  background: linear-gradient(135deg, #d4a853 0%, #b88a3a 100%);
  color: #0a1628;
  border: none;
  padding: 7px 13px;
  border-radius: 100px;
  font-size: 12.5px;
  font-weight: 600;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 50;
  box-shadow: 0 6px 18px rgba(212, 168, 83, 0.4), 0 2px 6px rgba(0, 0, 0, 0.3);
  transition: all 0.25s;
  white-space: nowrap;
}

.floating-bracket-btn svg,
.floating-bracket-btn i {
  width: 16px;
  height: 16px;
  font-size: 16px;
}

/* v2.5.17: subtle inline bracket-view link, not a CTA. Sits below the
   team-selection card as a "view also" option, not a forward action. */
.ko-bracket-view-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: auto;
  margin: 12px auto 4px;
  padding: 6px 12px;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  border: none;
  font-size: 13px;
  font-weight: 500;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(255, 255, 255, 0.2);
  transition: color 0.15s;
}
.ko-bracket-view-inline:hover {
  color: #d4a853;
  text-decoration-color: rgba(212, 168, 83, 0.35);
}
.ko-bracket-view-inline i { font-size: 14px; }

.floating-bracket-btn:hover, .floating-bracket-btn:active {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(212, 168, 83, 0.55), 0 2px 6px rgba(0, 0, 0, 0.3);
}

/* Legacy two-phase knockout-screen keeps its prominent bottom-center pill
   because its topbar end corner already hosts the simulator icon. */
#knockout-screen .floating-bracket-btn {
  position: fixed;
  top: auto;
  bottom: 16px;
  inset-inline-end: auto;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 22px;
  font-size: 14px;
  gap: 8px;
  box-shadow: 0 8px 24px rgba(212, 168, 83, 0.4), 0 2px 8px rgba(0, 0, 0, 0.3);
}

#knockout-screen .floating-bracket-btn svg,
#knockout-screen .floating-bracket-btn i {
  width: 20px;
  height: 20px;
  font-size: 20px;
}

#knockout-screen .floating-bracket-btn:hover,
#knockout-screen .floating-bracket-btn:active {
  transform: translateX(-50%) translateY(-2px);
  box-shadow: 0 12px 32px rgba(212, 168, 83, 0.55), 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Bottom padding so the legacy floating btn doesn't cover the last item */
#knockout-screen .container {
  padding-bottom: 100px;
}

/* ============================================================ */
/* Bracket View - Professional Tournament Tree with SVG Lines   */
/* ============================================================ */

/* Bracket screen full-width */
#bracket-screen.active {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  z-index: 100;
  background: #0a1628;
  display: flex;
  flex-direction: column;
}

#bracket-screen .topbar {
  width: 100%;
  max-width: 100%;
  flex-shrink: 0;
}

/* Quick jump tabs */
.bracket-jump-tabs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.3);
  border-bottom: 0.5px solid rgba(212, 168, 83, 0.15);
  flex-shrink: 0;
}

/* Hide jump tabs on desktop - whole bracket is visible */
@media (min-width: 1024px) {
  .bracket-jump-tabs {
    display: none;
  }
  
  /* Also hide zoom button on desktop - bracket fits the screen */
  #bracket-zoom-btn {
    display: none;
  }
}

.bracket-jump-tab {
  background: rgba(255, 255, 255, 0.04);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  padding: 7px 4px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  transition: all 0.2s;
}

.bracket-jump-tab:hover {
  background: rgba(255, 255, 255, 0.08);
}

.bracket-jump-tab.has-picks {
  border-color: rgba(74, 222, 128, 0.3);
  color: #4ade80;
}

.bracket-jump-tab.active {
  background: #d4a853;
  color: #0a1628;
  border-color: #d4a853;
  font-weight: 600;
}

/* Hint banner */
.bracket-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 14px;
  background: linear-gradient(90deg, rgba(168, 85, 247, 0.15) 0%, rgba(168, 85, 247, 0.05) 50%, rgba(168, 85, 247, 0.15) 100%);
  color: rgba(255, 255, 255, 0.8);
  font-size: 12px;
  border-bottom: 0.5px solid rgba(168, 85, 247, 0.2);
  flex-shrink: 0;
}

/* Hide hint banner on desktop screens */
@media (min-width: 1024px) {
  .bracket-hint {
    display: none;
  }
}

.bracket-hint-arrow {
  color: #d4a853;
  font-size: 18px;
  font-weight: 700;
  animation: arrowBounce 1.5s ease-in-out infinite;
}

.bracket-hint-arrow:last-child {
  animation-delay: 0.5s;
}

@keyframes arrowBounce {
  0%, 100% { transform: translateX(0); opacity: 0.6; }
  50% { transform: translateX(4px); opacity: 1; }
}

/* Scroll container */
.bracket-scroll-container {
  overflow-x: auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  flex: 1;
  background: linear-gradient(180deg, #0a1628 0%, #0d1a30 100%);
  position: relative;
  width: 100%;
  /* Center content horizontally if smaller than viewport */
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.bracket-scroll-container::-webkit-scrollbar {
  height: 8px;
  width: 8px;
}

.bracket-scroll-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
}

.bracket-scroll-container::-webkit-scrollbar-thumb {
  background: rgba(212, 168, 83, 0.5);
  border-radius: 4px;
}

/* Bracket tree - the SVG-positioned bracket */
.bracket-tree {
  position: relative;
  padding: 20px 12px;
  direction: ltr;
  /* Allow tree to be larger than container (for scroll) */
  flex-shrink: 0;
  margin: 0 auto;
}

/* SVG layer for connector lines - sits behind cards */
.bracket-svg-layer {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 1;
}

/* Cards layer - absolutely positioned on top of SVG */
.bracket-cards-layer {
  position: relative;
  z-index: 2;
}

/* Match cards - absolutely positioned */
.bracket-card {
  position: absolute;
  background: #1a2942;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 5px 8px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.bracket-card:hover {
  background: #1f2f4f;
  border-color: rgba(212, 168, 83, 0.4);
  z-index: 3;
}

.bracket-card.done {
  background: linear-gradient(135deg, #1f3a2a 0%, #1a2942 100%);
  border-color: rgba(74, 222, 128, 0.35);
}

.bracket-card.pending {
  background: linear-gradient(135deg, #3a2f1a 0%, #1a2942 100%);
  border-color: rgba(251, 191, 36, 0.3);
}

.bracket-card.tbd {
  opacity: 0.45;
  cursor: not-allowed;
}

.bracket-card.final-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.3) 0%, rgba(212, 168, 83, 0.1) 100%);
  border: 1.5px solid #d4a853;
  box-shadow: 0 4px 16px rgba(212, 168, 83, 0.25);
}

/* Card team rows */
.bracket-card-team {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 3px;
  border-radius: 3px;
  overflow: hidden;
  white-space: nowrap;
}

.bracket-card-flag {
  font-size: 12px;
  flex-shrink: 0;
}

.bracket-card-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
  font-size: 10px;
}

.bracket-card-team.winner {
  background: rgba(212, 168, 83, 0.2);
}

.bracket-card-team.winner .bracket-card-name {
  color: #d4a853;
  font-weight: 600;
}

.bracket-card-team.loser .bracket-card-name {
  color: rgba(255, 255, 255, 0.3);
  text-decoration: line-through;
}

.bracket-card-team.neutral .bracket-card-name {
  color: rgba(255, 255, 255, 0.9);
}

.bracket-card-team.tbd .bracket-card-name {
  color: rgba(255, 255, 255, 0.3);
  font-style: italic;
  font-size: 9px;
}

/* Match number badge */
.bracket-card-num {
  position: absolute;
  top: -7px;
  left: 6px;
  background: #0a1628;
  border: 0.5px solid rgba(212, 168, 83, 0.5);
  color: #d4a853;
  font-size: 9px;
  padding: 1px 6px;
  border-radius: 8px;
  font-family: monospace;
  font-weight: 700;
}

/* Round headers - positioned at top */
.bracket-round-header {
  position: absolute;
  top: 0;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: #d4a853;
  letter-spacing: 1px;
  padding: 4px 10px;
  background: linear-gradient(180deg, rgba(212, 168, 83, 0.25), rgba(212, 168, 83, 0.05));
  border: 0.5px solid rgba(212, 168, 83, 0.4);
  border-radius: 6px;
  white-space: nowrap;
  z-index: 3;
}

/* Trophy icon for final */
.bracket-trophy-decoration {
  position: absolute;
  font-size: 32px;
  text-align: center;
  z-index: 3;
}

/* Champion display below final */
.bracket-champion-display {
  position: absolute;
  text-align: center;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.5));
  border: 1px solid rgba(212, 168, 83, 0.5);
  border-radius: 10px;
  padding: 10px;
  box-shadow: 0 4px 20px rgba(212, 168, 83, 0.2);
  z-index: 3;
}

.bracket-champion-display-label {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 1px;
  margin-bottom: 4px;
  font-weight: 500;
}

.bracket-champion-display-name {
  font-size: 13px;
  color: #d4a853;
  font-weight: 700;
}

.bracket-champion-display-name.tbd {
  color: rgba(255, 255, 255, 0.3);
  font-size: 11px;
  font-style: italic;
}

/* Hide old bracket styles */
.bracket-container,
.bracket-intro,
.bracket-half,
.bracket-half-content,
.bracket-column,
.bracket-round-label,
.bracket-r32-row,
.bracket-r16-row,
.bracket-qf-row,
.bracket-sf-row,
.bracket-flow-arrow,
.bracket-match-mini,
.bracket-final-section,
.bracket-final-container,
.bracket-final-trophy-icon,
.bracket-champion-row {
  display: none !important;
}


.ko-empty-state {
  text-align: center;
  padding: 60px 20px;
}

.ko-empty-icon {
  font-size: 56px;
  margin-bottom: 12px;
  opacity: 0.5;
}

.ko-empty-title {
  font-size: 16px;
  color: white;
  font-weight: 500;
  margin-bottom: 6px;
}

.ko-empty-text {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* ============================================================ */
/* Simulator Modal                                              */
/* ============================================================ */

.sim-modal {
  max-width: 440px;
}

.sim-section {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
}

.sim-section-title {
  font-size: 11px;
  color: #d4a853;
  letter-spacing: 1px;
  margin-bottom: 10px;
  text-align: start;
  font-weight: 500;
}

.sim-score-display {
  display: flex;
  align-items: center;
  justify-content: space-around;
}

.sim-score-item {
  text-align: center;
  flex: 1;
}

.sim-score-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 4px;
  letter-spacing: 0.5px;
}

.sim-score-value {
  font-size: 28px;
  font-weight: 700;
  color: white;
  font-family: monospace;
}

.sim-score-divider {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.1);
}

/* Risk meter */
.sim-risk-meter {
  margin-bottom: 10px;
}

.sim-risk-bar {
  position: relative;
  height: 10px;
  background: linear-gradient(90deg, 
    #4ade80 0%, 
    #fbbf24 50%, 
    #fb7185 100%);
  border-radius: 5px;
  overflow: visible;
}

.sim-risk-fill {
  display: none;
}

.sim-risk-marker {
  position: absolute;
  top: -4px;
  width: 18px;
  height: 18px;
  background: white;
  border: 2px solid #0a1628;
  border-radius: 50%;
  transform: translateX(50%);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  transition: right 0.4s ease-out;
}

.sim-risk-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 10px;
}

.sim-risk-label-safe { color: #4ade80; }
.sim-risk-label-bold { color: #fbbf24; }
.sim-risk-label-risky { color: #fb7185; }

.sim-risk-description {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  text-align: center;
  margin-top: 8px;
  line-height: 1.4;
}

/* Stages breakdown */
.sim-stages {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sim-stage-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 6px 8px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 6px;
  font-size: 12px;
}

.sim-stage-name {
  color: rgba(255, 255, 255, 0.85);
  min-width: 70px;
}

.sim-stage-progress {
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.sim-stage-progress-fill {
  height: 100%;
  background: #d4a853;
  border-radius: 2px;
  transition: width 0.4s;
}

.sim-stage-count {
  font-family: monospace;
  font-size: 11px;
  color: #d4a853;
  min-width: 36px;
  text-align: left;
}

.sim-recommendation {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.1) 0%, rgba(168, 85, 247, 0.03) 100%);
  border: 0.5px solid rgba(168, 85, 247, 0.3);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.sim-rec-icon {
  font-size: 22px;
  flex-shrink: 0;
}

.sim-rec-text {
  font-size: 13px;
  color: white;
  line-height: 1.5;
}

/* ============================================================ */
/* PWA Install Banner                                           */
/* ============================================================ */

.pwa-install-banner {
  position: fixed;
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 450px;
  background: linear-gradient(135deg, #1a2942 0%, #0a1628 100%);
  border: 1px solid rgba(212, 168, 83, 0.4);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  z-index: 9999;
  transition: bottom 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.pwa-install-banner.visible {
  bottom: 20px;
}

.pwa-banner-icon {
  font-size: 32px;
  flex-shrink: 0;
}

.pwa-banner-content {
  flex: 1;
  min-width: 0;
}

.pwa-banner-title {
  font-size: 14px;
  color: white;
  font-weight: 600;
  margin-bottom: 2px;
}

.pwa-banner-text {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.4;
}

.pwa-banner-install {
  background: linear-gradient(135deg, #d4a853, #b88a3a);
  color: #0a1628;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
}

.pwa-banner-install:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(212, 168, 83, 0.4);
}

.pwa-banner-dismiss {
  background: rgba(255, 255, 255, 0.05);
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.5);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
  padding: 0;
}

.pwa-banner-dismiss:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

/* Update toast */
.pwa-update-toast {
  position: fixed;
  top: -60px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #1a2942 0%, #0a1628 100%);
  border: 1px solid rgba(212, 168, 83, 0.4);
  border-radius: 100px;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: white;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  z-index: 9999;
  transition: top 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.pwa-update-toast.visible {
  top: 20px;
}

.pwa-update-toast button {
  background: linear-gradient(135deg, #d4a853, #b88a3a);
  color: #0a1628;
  border: none;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
  font-family: 'Heebo', sans-serif;
  cursor: pointer;
}

/* Adjust for iOS safe area */
@supports (padding: env(safe-area-inset-bottom)) {
  .pwa-install-banner.visible {
    bottom: calc(20px + env(safe-area-inset-bottom));
  }
}

/* ============================================================ */
/* Invite Friends - Dashboard CTA                               */
/* ============================================================ */

/* v2.4.1: Invite-friends CTA now sits at the top of "My bets" and
   gets a slightly stronger gold glow to feel like the primary first
   action (alongside the Start CTA below). */
.invite-friends-btn {
  width: 100%;
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.22) 0%, rgba(212, 168, 83, 0.08) 100%);
  border: 1.5px solid rgba(212, 168, 83, 0.55);
  border-radius: 16px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  margin: 4px 0 12px;
  text-align: start;
  transition: all 0.2s;
  box-shadow: 0 4px 18px rgba(212, 168, 83, 0.14);
}

.invite-friends-btn:hover {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.25) 0%, rgba(212, 168, 83, 0.1) 100%);
  border-color: rgba(212, 168, 83, 0.6);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(212, 168, 83, 0.15);
}

.invite-friends-icon {
  font-size: 32px;
  flex-shrink: 0;
  animation: bounce-icon 2s ease-in-out infinite;
  /* v2.5.14: switched from emoji to inline SVG - tint to gold */
  color: #d4a853;
  display: flex;
  align-items: center;
  justify-content: center;
}
.invite-friends-icon svg {
  width: 28px;
  height: 28px;
  display: block;
}

@keyframes bounce-icon {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

.invite-friends-content {
  flex: 1;
  min-width: 0;
}

.invite-friends-title {
  font-size: 15px;
  color: #d4a853;
  font-weight: 700;
  margin-bottom: 2px;
}

.invite-friends-subtitle {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.4;
}

.invite-friends-arrow {
  color: #d4a853;
  font-size: 20px;
  flex-shrink: 0;
}

/* ============================================================ */
/* Share Modal                                                  */
/* ============================================================ */

.share-modal {
  max-width: 420px;
  max-height: 90vh;
  overflow-y: auto;
}

.share-modal-content {
  padding: 24px 20px;
}

/* Header */
.share-header {
  text-align: center;
  margin-bottom: 20px;
}

.share-icon {
  font-size: 48px;
  margin-bottom: 8px;
  animation: bounce-icon 2s ease-in-out infinite;
}
/* v2.5.38: SVG variant of share-icon for the invite-friends modal */
.share-icon.share-icon-svg {
  width: 64px;
  height: 64px;
  margin: 0 auto 8px;
  border-radius: 50%;
  background: rgba(212, 168, 83, 0.12);
  border: 1px solid rgba(212, 168, 83, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #d4a853;
  font-size: 0;
}

.share-title {
  font-size: 20px;
  color: white;
  font-weight: 700;
  margin-bottom: 6px;
}

.share-subtitle {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.5;
}

/* Pool code card */
.share-code-card {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.15) 0%, rgba(212, 168, 83, 0.04) 100%);
  border: 1px solid rgba(212, 168, 83, 0.3);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
}

.share-code-card:hover {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.2) 0%, rgba(212, 168, 83, 0.06) 100%);
  border-color: rgba(212, 168, 83, 0.5);
}

.share-code-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.share-code-value {
  font-size: 28px;
  color: #d4a853;
  font-weight: 700;
  font-family: monospace;
  letter-spacing: 4px;
  margin-bottom: 4px;
}

.share-code-hint {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
}

/* Share options grid */
.share-options-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 20px;
}

.share-option {
  background: rgba(255, 255, 255, 0.03);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 10px 6px;
  cursor: pointer;
  font-family: 'Heebo', sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.share-option:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}

.share-option-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.share-option-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
}

/* QR Code section */
.share-qr-section {
  background: rgba(255, 255, 255, 0.02);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  margin-bottom: 16px;
}

.share-qr-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 12px;
}

.share-qr-wrapper {
  display: flex;
  justify-content: center;
}

.share-qr-code {
  background: white;
  padding: 8px;
  border-radius: 8px;
  display: inline-block;
  width: 200px;
  height: 200px;
}

.share-qr-code svg,
.share-qr-code img {
  width: 100%;
  height: 100%;
  display: block;
}

/* URL display */
.share-url-section {
  background: rgba(255, 255, 255, 0.02);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px;
}

.share-url-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 6px;
  letter-spacing: 0.5px;
}

.share-url-display {
  font-size: 11px;
  color: #7dd3fc;
  font-family: monospace;
  word-break: break-all;
  cursor: pointer;
  padding: 6px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  line-height: 1.4;
  transition: all 0.2s;
}

.share-url-display:hover {
  background: rgba(0, 0, 0, 0.3);
  color: #93c5fd;
}

/* ============================================================ */
/* Offline Banner                                               */
/* ============================================================ */

.offline-banner {
  position: fixed;
  top: -50px;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, #f97316, #ea580c);
  color: white;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 500;
  z-index: 10000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: top 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.offline-banner.visible {
  top: 0;
}

.offline-banner svg {
  flex-shrink: 0;
}

@supports (padding: env(safe-area-inset-top)) {
  .offline-banner.visible {
    padding-top: calc(8px + env(safe-area-inset-top));
  }
}

/* ============================================================ */
/* Member Approval System                                       */
/* ============================================================ */

/* Pending banner */
.admin-pending-banner {
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.15) 0%, rgba(249, 115, 22, 0.03) 100%);
  border: 1px solid rgba(249, 115, 22, 0.4);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  animation: pulse-pending 3s ease-in-out infinite;
}

@keyframes pulse-pending {
  0%, 100% { 
    box-shadow: 0 0 0 0 rgba(249, 115, 22, 0.3);
  }
  50% { 
    box-shadow: 0 0 0 8px rgba(249, 115, 22, 0);
  }
}

.admin-pending-banner-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.admin-pending-banner-content {
  flex: 1;
  min-width: 0;
}

.admin-pending-banner-title {
  font-size: 13px;
  color: white;
  font-weight: 600;
  margin-bottom: 2px;
}

.admin-pending-banner-title span {
  color: #fb923c;
  font-size: 16px;
  font-weight: 700;
}

.admin-pending-banner-subtitle {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
}

/* Pending member card */
.admin-member-card.is-pending {
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%);
  border-color: rgba(249, 115, 22, 0.3);
}

.admin-member-pending-badge {
  display: inline-block;
  background: rgba(249, 115, 22, 0.2);
  color: #fb923c;
  font-size: 9px;
  padding: 1px 6px;
  border-radius: 4px;
  margin-inline-end: 4px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

/* Quick action buttons */
.admin-member-quick-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
  flex-direction: column;
}

.admin-quick-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 10px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Heebo', sans-serif;
  font-size: 12px;
  font-weight: 600;
  min-width: 70px;
}

.admin-quick-btn span {
  font-size: 12px;
}

.admin-quick-btn.approve {
  background: linear-gradient(135deg, #4ade80, #16a34a);
  color: white;
}

.admin-quick-btn.approve:hover {
  background: linear-gradient(135deg, #5eea90, #20b250);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(74, 222, 128, 0.4);
}

.admin-quick-btn.reject {
  background: linear-gradient(135deg, #fb7185, #dc2626);
  color: white;
}

.admin-quick-btn.reject:hover {
  background: linear-gradient(135deg, #fb8195, #ef3636);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(251, 113, 133, 0.4);
}

/* Menu badge */
.menu-badge {
  background: linear-gradient(135deg, #fb923c, #f97316);
  color: white;
  font-size: 11px;
  font-weight: 700;
  min-width: 20px;
  height: 20px;
  border-radius: 10px;
  padding: 0 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  margin-right: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  animation: pulse-badge 2s ease-in-out infinite;
}

@keyframes pulse-badge {
  0%, 100% { 
    transform: scale(1);
  }
  50% { 
    transform: scale(1.08);
  }
}

/* ============================================================ */
/* Top Scorer - Goals Badge                                     */
/* ============================================================ */

.ts-player-goals-badge {
  display: inline-block;
  background: linear-gradient(135deg, #fb923c, #ea580c);
  color: white;
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 4px;
  margin-left: 6px;
  font-weight: 700;
  letter-spacing: 0.3px;
  box-shadow: 0 2px 4px rgba(251, 146, 60, 0.3);
}

/* ============================================================ */
/* Top Scorer - Search Hints                                    */
/* ============================================================ */

.ts-search-hints {
  background: rgba(255, 255, 255, 0.02);
  border: 0.5px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 16px;
  margin-top: 16px;
}

.ts-search-hints-title {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 600;
  margin-bottom: 12px;
}

.ts-search-hints-examples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.ts-search-hint-chip {
  display: inline-block;
  background: rgba(212, 168, 83, 0.15);
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  color: #d4a853;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Heebo', sans-serif;
}

.ts-search-hint-chip:hover {
  background: rgba(212, 168, 83, 0.25);
  border-color: rgba(212, 168, 83, 0.5);
  transform: translateY(-1px);
}

.ts-search-hints-note {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.5;
  padding-top: 10px;
  border-top: 0.5px solid rgba(255, 255, 255, 0.05);
}

/* ============================================================ */
/* LTR Support (English mode)                                   */
/* ============================================================ */

body.ltr {
  direction: ltr;
  text-align: left;
}

body.ltr .topbar {
  /* The back arrow flips */
}

/* v2.5.33: inline back-arrow SVGs are authored pointing LEFT (correct for
   English). In Hebrew RTL, flip them to point RIGHT. */
body.rtl [data-i18n-aria="common.back"] svg {
  transform: scaleX(-1);
}

body.ltr .admin-member-arrow {
  transform: scaleX(-1);
}

/* Flip directional Tabler icon fonts in LTR */
body.ltr .ti-arrow-right::before,
body.ltr .ti-arrow-left::before,
body.ltr .ti-chevron-right::before,
body.ltr .ti-chevron-left::before {
  display: inline-block;
  transform: scaleX(-1);
}

/* Hebrew icons that should NOT flip */
body.ltr [data-no-flip] {
  transform: none !important;
}

/* Form labels */
body.ltr .form-label,
body.ltr .form-input,
body.ltr label,
body.ltr input,
body.ltr textarea {
  text-align: left;
  direction: ltr;
}

/* Number inputs and codes stay LTR always */
input[type="number"],
input[type="tel"],
input[autocomplete="off"][maxlength="16"],
.recovery-code-display,
.pool-code-display,
.menu-version {
  direction: ltr !important;
  text-align: center !important;
}

/* Headers should align properly */
body.ltr .topbar-title,
body.ltr h1,
body.ltr h2,
body.ltr h3 {
  text-align: center;
}

/* Group betting cards */
body.ltr .group-letter-badge {
  /* No special change */
}

/* Player cards in top scorer - flex direction stays */
body.ltr .ts-player-card {
  flex-direction: row;
}

body.ltr .ts-player-info {
  text-align: start;
}

/* Toast messages */
body.ltr .toast {
  text-align: center;
}

/* Bracket */
body.ltr .bracket-svg-wrapper {
  /* SVG handles its own direction */
}

/* Menu items in English mode */
body.ltr .menu-item {
  flex-direction: row;
}

/* Language switcher in menu */
.menu-language-switcher {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: rgba(212, 168, 83, 0.05);
  border: 0.5px solid rgba(212, 168, 83, 0.15);
  border-radius: 10px;
  margin: 8px 0;
}

/* v2.4: only show the Hebrew toggle to Israeli users (timezone, browser
   language, or IP). Everyone else only sees the app in English. */
body:not(.is-israel) .menu-language-switcher {
  display: none;
}

.menu-language-switcher-label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
}

.menu-language-toggle {
  display: flex;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 8px;
  overflow: hidden;
  border: 0.5px solid rgba(255, 255, 255, 0.1);
}

.menu-language-toggle-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.5);
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  letter-spacing: 0.5px;
}

.menu-language-toggle-btn.active {
  background: #d4a853;
  color: #0a1628;
}

.menu-language-toggle-btn:not(.active):hover {
  color: rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.05);
}

/* ============================================================ */
/* Home Screen Language Toggle                                  */
/* ============================================================ */

.home-lang-toggle {
  position: absolute;
  top: 16px;
  left: 16px;
  display: none;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 10px;
  overflow: hidden;
  border: 0.5px solid rgba(255, 255, 255, 0.1);
  z-index: 10;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Show home language toggle only for users in Israel timezone */
body.is-israel .home-lang-toggle {
  display: flex;
}

/* In RTL mode (Hebrew default), position on left.
   In LTR mode (English), also on left for consistency */
body.ltr .home-lang-toggle {
  left: 16px;
  right: auto;
}

body.rtl .home-lang-toggle,
body:not(.ltr) .home-lang-toggle {
  left: 16px;
  right: auto;
}

.home-lang-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.55);
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  letter-spacing: 0.5px;
  min-width: 42px;
}

.home-lang-btn.active {
  background: #d4a853;
  color: #0a1628;
}

.home-lang-btn:not(.active):hover {
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.05);
}

.home-lang-btn:not(.active):active {
  transform: scale(0.95);
}

/* ============================================================ */
/* v2.0.0 - POOL WIZARD                                         */
/* ============================================================ */
.wizard-step-title {
  font-size: 22px;
  font-weight: 700;
  color: #d4a853;
  margin: 16px 0 6px;
  text-align: center;
}

.wizard-step-subtitle {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  text-align: center;
  margin-bottom: 24px;
}

.wizard-option-cards {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 24px;
}

.wizard-option-card {
  position: relative;
  background: rgba(255,255,255,0.04);
  border: 2px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 20px 18px 18px;
  cursor: pointer;
  transition: all .2s;
}

.wizard-option-card:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(212,168,83,0.3);
}

.wizard-option-card.selected {
  background: rgba(212,168,83,0.08);
  border-color: #d4a853;
  box-shadow: 0 0 0 4px rgba(212,168,83,0.12);
}

.wizard-option-card.selected .wizard-option-check {
  opacity: 1;
  transform: scale(1);
}

.wizard-option-check {
  position: absolute;
  top: 14px;
  inset-inline-end: 14px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #d4a853;
  color: #0a1628;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  opacity: 0;
  transform: scale(0.5);
  transition: all .2s;
}
/* v2.4.6: SVG checkmark inside the wizard option circle - the ti-check
   icon font wasn't always rendering on Windows, leaving an empty yellow
   ball. SVG is reliable and sharp. */
.wizard-option-check svg {
  width: 16px;
  height: 16px;
  stroke-width: 3;
  display: block;
}

.wizard-option-badge {
  position: absolute;
  top: -10px;
  inset-inline-start: 14px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .5px;
}

.wizard-badge-recommended { background: #10b981; color: #fff; }
.wizard-badge-advanced    { background: #3b82f6; color: #fff; }

.wizard-option-icon { font-size: 30px; margin-bottom: 8px; }
.wizard-option-title {
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 6px;
}
.wizard-option-desc {
  font-size: 13px;
  line-height: 1.5;
  color: rgba(255,255,255,0.65);
}

/* v2.5.7: redesigned scoring-rules step - pill toggle + grouped list */
.wizard-rules-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  padding: 4px;
  margin: 16px 0 14px;
}
.wizard-rules-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 8px;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.65);
  font-size: 14px;
  font-weight: 600;
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.18s;
}
.wizard-rules-toggle-btn i { font-size: 16px; }
.wizard-rules-toggle-btn:hover { color: rgba(255, 255, 255, 0.85); }
.wizard-rules-toggle-btn.selected {
  background: #d4a853;
  color: #0a1628;
  box-shadow: 0 2px 8px rgba(212, 168, 83, 0.35);
}

.wizard-rules-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.wizard-rules-group {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 10px 14px 8px;
}
.wizard-rules-group-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: #d4a853;
  margin-bottom: 6px;
}
.wizard-rules-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.05);
}
.wizard-rules-row:last-child { border-bottom: none; }
.wizard-rules-row-label { flex: 1; }
.wizard-rules-row-pts {
  color: #d4a853;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.wizard-rules-row-input {
  width: 48px;
  padding: 5px 4px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(212, 168, 83, 0.35);
  border-radius: 6px;
  color: #d4a853;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  /* Hide native browser steppers - we render our own */
  -moz-appearance: textfield;
}
.wizard-rules-row-input::-webkit-outer-spin-button,
.wizard-rules-row-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.wizard-rules-row-input:focus {
  outline: none;
  border-color: #d4a853;
  background: rgba(255, 255, 255, 0.1);
}

/* v2.5.12: +/- stepper around each custom-rule input */
.wizard-rules-stepper {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.wizard-rules-stepper-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(212, 168, 83, 0.35);
  background: rgba(212, 168, 83, 0.08);
  color: #d4a853;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}
.wizard-rules-stepper-btn:hover {
  background: rgba(212, 168, 83, 0.2);
  border-color: #d4a853;
}
.wizard-rules-stepper-btn:active {
  transform: scale(0.92);
}
.wizard-rules-group-compact {
  padding: 8px 12px 6px;
}
.wizard-rules-group-compact .wizard-rules-row {
  padding: 4px 0;
  font-size: 12px;
}

/* Legacy class kept for any unmigrated callers */
.wizard-rules-preview {
  margin-top: 14px;
  background: rgba(0,0,0,0.25);
  border-radius: 10px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.wizard-rules-preview .rule-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}
.wizard-rules-preview .rule-row .pts {
  color: #d4a853;
  font-weight: 600;
}

.wizard-rules-form {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.wizard-rules-form .rule-input-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(0,0,0,0.25);
  border-radius: 8px;
  padding: 8px 12px;
}
.wizard-rules-form .rule-input-row label {
  font-size: 13px;
  color: rgba(255,255,255,0.8);
}
.wizard-rules-form input[type="number"] {
  width: 70px;
  padding: 6px 8px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 6px;
  color: #fff;
  font-size: 14px;
  text-align: center;
}

.wizard-summary {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(212,168,83,0.2);
  border-radius: 16px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 24px;
}
.wizard-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.wizard-summary-label {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
}
.wizard-summary-value {
  font-size: 15px;
  font-weight: 600;
  color: #fff;
}
.wizard-summary-value.gold {
  color: #d4a853;
  font-size: 20px;
}
.wizard-summary-totals {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 14px;
}
.wizard-summary-rules {
  margin-top: 8px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
}
.wizard-summary-rules .rule-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: rgba(255,255,255,0.7);
}
.wizard-summary-rules .pts {
  color: #d4a853;
  font-weight: 600;
}

.wizard-footer {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}
.wizard-footer button { flex: 1; }

/* ============================================================ */
/* v2.0.0 - SINGLE-PHASE BETTING                                 */
/* ============================================================ */
.sp-section-instructions {
  background: rgba(255,255,255,0.04);
  border-inline-start: 3px solid #d4a853;
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 18px;
  font-size: 13px;
  color: rgba(255,255,255,0.8);
}

.sp-group-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.sp-group-letter {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #d4a853;
  color: #0a1628;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
}
.sp-group-title {
  font-size: 17px;
  font-weight: 600;
  color: rgba(255,255,255,0.85);
}

.sp-positions-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}
.sp-position-slot {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px dashed rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 12px 14px;
  min-height: 56px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}
.sp-position-slot.filled {
  border-style: solid;
  border-color: rgba(212,168,83,0.5);
  background: rgba(212,168,83,0.07);
}
.sp-position-slot.sp-draggable {
  cursor: grab;
}
.sp-position-slot.sp-draggable:active {
  cursor: grabbing;
}
.sp-position-slot.dragging {
  transition: none;
  z-index: 10;
  box-shadow: 0 14px 32px rgba(0,0,0,0.5), 0 0 0 1px rgba(212,168,83,0.7);
  background: rgba(212,168,83,0.14);
  cursor: grabbing;
}
.pos-drag-handle {
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.4);
  width: 22px;
  flex-shrink: 0;
  font-size: 18px;
  margin-inline-end: -4px;
}
.sp-position-slot .pos-rank {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #d4a853;
  flex-shrink: 0;
}
.sp-position-slot.filled .pos-rank {
  background: #d4a853;
  color: #0a1628;
}
.sp-position-slot .pos-flag { font-size: 26px; }
.sp-position-slot .pos-name { flex: 1; color: #fff; font-weight: 500; }
.sp-position-slot .pos-empty {
  flex: 1;
  color: rgba(255,255,255,0.4);
  font-style: italic;
}
.sp-position-slot .pos-remove {
  background: none;
  border: none;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  padding: 6px;
  font-size: 18px;
}
.sp-position-slot .pos-remove:hover { color: #ef4444; }

.sp-teams-pool {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 24px;
}
.sp-team-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  transition: all .15s;
  color: #fff;
  font-size: 14px;
  font-family: inherit;
}
.sp-team-chip:hover {
  background: rgba(212,168,83,0.1);
  border-color: rgba(212,168,83,0.4);
}
.sp-team-chip .chip-flag { font-size: 22px; }
.sp-team-chip.used { opacity: 0.35; pointer-events: none; }

.sp-group-nav {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}
.sp-group-nav button { flex: 1; }

.sp-bracket {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin-bottom: 18px;
}
.sp-bracket-round {
  background: rgba(255,255,255,0.03);
  border-radius: 14px;
  padding: 14px 12px;
}
.sp-bracket-round-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #d4a853;
  margin-bottom: 10px;
}
.sp-bracket-match {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: rgba(255,255,255,0.04);
  border-radius: 10px;
  padding: 8px;
  margin-bottom: 8px;
}
.sp-bracket-team {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 9px 12px;
  cursor: pointer;
  transition: all .15s;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  width: 100%;
  text-align: start;
}
.sp-bracket-team:hover { background: rgba(212,168,83,0.08); }
.sp-bracket-team.picked {
  background: rgba(212,168,83,0.18);
  border-color: #d4a853;
  font-weight: 600;
}
.sp-bracket-team .bt-flag { font-size: 20px; }
.sp-bracket-team .bt-name { flex: 1; }
.sp-bracket-team .bt-check { color: #d4a853; opacity: 0; }
.sp-bracket-team.picked .bt-check { opacity: 1; }
.sp-bracket-team:disabled,
.sp-bracket-team.tbd { opacity: 0.5; cursor: not-allowed; }
.sp-bracket-vs {
  text-align: center;
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  letter-spacing: 1px;
  padding: 2px 0;
}

.sp-winner-hero { text-align: center; margin-bottom: 24px; }
.sp-winner-icon { font-size: 56px; margin-bottom: 8px; }
.sp-winner-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 22px;
}
.sp-winner-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.05);
  border: 2px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 14px 10px;
  cursor: pointer;
  font-family: inherit;
  color: #fff;
}
.sp-winner-option.selected {
  background: rgba(212,168,83,0.15);
  border-color: #d4a853;
}
.sp-winner-option .wo-flag { font-size: 36px; }
.sp-winner-option .wo-name { font-size: 14px; font-weight: 600; }

.sp-summary-warning {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.3);
  border-radius: 10px;
  padding: 12px 14px;
  color: #fca5a5;
  font-size: 13px;
  margin-bottom: 16px;
}
.sp-summary-warning i { font-size: 22px; }

.sp-summary-card {
  background: rgba(255,255,255,0.04);
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 12px;
}
.sp-summary-section-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .5px;
  color: #d4a853;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.sp-summary-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
  font-size: 13px;
  color: rgba(255,255,255,0.85);
}
.sp-summary-row .sr-flag {
  font-size: 18px;
  flex-shrink: 0;
}
.sp-summary-row .sr-label {
  color: rgba(255,255,255,0.55);
  font-size: 12px;
  font-style: italic;
}
.sp-summary-row .sr-value { font-weight: 600; }
/* v2.2.2: position number used in group summary rows */
.sp-summary-row .sr-pos {
  color: rgba(255,168,83,0.85);
  font-size: 12px;
  font-weight: 600;
  min-width: 16px;
  flex-shrink: 0;
}

.sp-locked-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(16,185,129,0.08);
  border: 1px solid rgba(16,185,129,0.3);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 18px;
  color: #fff;
}
.sp-locked-banner i { font-size: 26px; }

.lb-breakdown {
  display: flex;
  gap: 8px;
  font-size: 11px;
  color: rgba(255,255,255,0.55);
  margin-top: 4px;
  flex-wrap: wrap;
}
.lb-breakdown span { white-space: nowrap; }
.lb-breakdown .lb-bd-gold { color: #d4a853; }
.lb-view-bracket-btn {
  background: none;
  border: 1px solid rgba(212,168,83,0.3);
  color: #d4a853;
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 6px;
  cursor: pointer;
  margin-inline-start: 8px;
  font-family: inherit;
}
.lb-view-bracket-btn:hover { background: rgba(212,168,83,0.1); }

.btn-small {
  padding: 6px 12px;
  font-size: 12px;
  margin-top: 8px;
}

#hypo-bracket-modal.modal {
  position: fixed;
  inset: 0;
  z-index: 1500;
  align-items: center;
  justify-content: center;
}
#hypo-bracket-modal .modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
}
#hypo-bracket-modal .modal-content {
  position: relative;
  background: #142030;
  border: 1px solid rgba(212,168,83,0.2);
  border-radius: 14px;
  padding: 18px;
  color: #fff;
  max-width: 480px;
  width: 92vw;
  max-height: 86vh;
  overflow-y: auto;
}
#hypo-bracket-modal .modal-close {
  position: absolute;
  top: 10px;
  inset-inline-end: 10px;
  background: rgba(255,255,255,0.08);
  border: none;
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}
#hypo-bracket-modal .modal-title {
  color: #d4a853;
  margin: 0 0 14px;
  text-align: center;
  font-size: 17px;
}

/* ============================================================ */
/* v2.1.4 - Dashboard reflow (pre-tournament + dominant Start)   */
/* ============================================================ */
/* v2.4.1: pre-tournament panel slimmed to a single inline notice so the
   "invite friends" + "start betting" CTAs below are the visual focus. */
.pre-tournament-card {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.025);
  border: 0.5px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 7px 10px;
  margin-bottom: 12px;
  font-size: 11.5px;
  color: rgba(255,255,255,0.55);
}
.pre-tournament-card > i {
  font-size: 13px;
  color: rgba(212,168,83,0.7);
  flex-shrink: 0;
}
.pre-tournament-text {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  line-height: 1.3;
}
.pre-tournament-title {
  font-size: 11.5px;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
}
.pre-tournament-subtitle {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
}
.pre-tournament-subtitle::before {
  content: "·";
  margin: 0 2px;
  color: rgba(255,255,255,0.25);
}

/* v2.5.36: state-aware progress card. The neutral "tournament not started"
   look is fine for default, but once we know the user's status we want a
   friendlier, more on-brand panel. */
.pre-tournament-card.progress-notStarted,
.pre-tournament-card.progress-partial,
.pre-tournament-card.progress-allSet {
  padding: 12px 14px;
  gap: 12px;
  align-items: flex-start;
}
.pre-tournament-card.progress-notStarted .pre-tournament-text,
.pre-tournament-card.progress-partial .pre-tournament-text,
.pre-tournament-card.progress-allSet .pre-tournament-text {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.pre-tournament-card.progress-notStarted .pre-tournament-title,
.pre-tournament-card.progress-partial .pre-tournament-title,
.pre-tournament-card.progress-allSet .pre-tournament-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}
.pre-tournament-card.progress-notStarted .pre-tournament-subtitle,
.pre-tournament-card.progress-partial .pre-tournament-subtitle,
.pre-tournament-card.progress-allSet .pre-tournament-subtitle {
  font-size: 12px;
  line-height: 1.45;
  color: rgba(255,255,255,0.65);
}
.pre-tournament-card.progress-notStarted .pre-tournament-subtitle::before,
.pre-tournament-card.progress-partial .pre-tournament-subtitle::before,
.pre-tournament-card.progress-allSet .pre-tournament-subtitle::before {
  content: none;
}
.pre-tournament-card.progress-notStarted > i,
.pre-tournament-card.progress-partial > i,
.pre-tournament-card.progress-allSet > i {
  font-size: 22px;
  align-self: center;
}
.pre-tournament-card.progress-notStarted {
  background: rgba(212, 168, 83, 0.06);
  border-color: rgba(212, 168, 83, 0.25);
}
.pre-tournament-card.progress-notStarted > i { color: #d4a853; }
.pre-tournament-card.progress-partial {
  background: rgba(245, 197, 24, 0.06);
  border-color: rgba(245, 197, 24, 0.28);
}
.pre-tournament-card.progress-partial > i { color: #f5c518; }
.pre-tournament-card.progress-allSet {
  background: rgba(34, 197, 94, 0.08);
  border-color: rgba(34, 197, 94, 0.4);
  box-shadow: 0 0 18px rgba(34, 197, 94, 0.08);
}
.pre-tournament-card.progress-allSet > i { color: #4ade80; }

/* Dominant Start CTA card (replaces the small "Start" button) */
.bet-cta-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  background: linear-gradient(135deg, rgba(212,168,83,0.18) 0%, rgba(212,168,83,0.06) 100%);
  border: 1.5px solid rgba(212,168,83,0.45);
  border-radius: 16px;
  padding: 18px 18px;
  margin-bottom: 12px;
  cursor: pointer;
  color: #fff;
  font-family: inherit;
  text-align: start;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
  box-shadow: 0 4px 18px rgba(212,168,83,0.12);
}
.bet-cta-card:hover {
  transform: translateY(-1px);
  border-color: #d4a853;
  box-shadow: 0 6px 22px rgba(212,168,83,0.22);
}
.bet-cta-card:active { transform: scale(0.99); }
.bet-cta-card.done {
  background: rgba(16,185,129,0.08);
  border-color: rgba(16,185,129,0.45);
  box-shadow: none;
}

/* v2.4.9: striking leading icon - solid gold gradient with bright white
   inline-SVG glyph + soft outer glow. Replaces the prior faint olive disc
   that was unreadable on dark backgrounds and depended on Tabler-icons
   font which sometimes fails to render on Windows/PWA installs. */
.bet-cta-icon-simple {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f5c518 0%, #d4a853 55%, #b88a3a 100%);
  border: 1px solid rgba(245, 197, 24, 0.65);
  color: #1a1d2e;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow:
    0 0 0 4px rgba(212, 168, 83, 0.10),
    0 6px 16px rgba(212, 168, 83, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    inset 0 -2px 6px rgba(0, 0, 0, 0.18);
}
.bet-cta-icon-simple .bet-cta-svg {
  filter: drop-shadow(0 1px 1px rgba(0,0,0,0.18));
}
.bet-cta-card:hover .bet-cta-icon-simple {
  box-shadow:
    0 0 0 5px rgba(245, 197, 24, 0.14),
    0 8px 22px rgba(245, 197, 24, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 -2px 6px rgba(0, 0, 0, 0.2);
}
.bet-cta-card.done .bet-cta-icon-simple {
  background: linear-gradient(135deg, #34d399 0%, #10b981 55%, #059669 100%);
  border-color: rgba(16, 185, 129, 0.7);
  color: #fff;
  box-shadow:
    0 0 0 4px rgba(16, 185, 129, 0.12),
    0 6px 16px rgba(16, 185, 129, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    inset 0 -2px 6px rgba(0, 0, 0, 0.18);
}

/* Horizontal progress bar at the bottom of the CTA card */
.bet-cta-progress-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}
.bet-cta-progress-bar {
  flex: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
}
.bet-cta-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #d4a853, #f5c518);
  border-radius: 999px;
  transition: width 0.5s ease-out, background 0.2s;
}
.bet-cta-card.done .bet-cta-progress-fill {
  background: linear-gradient(90deg, #10b981, #34d399);
}
.bet-cta-progress-text {
  font-size: 11.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.bet-cta-card.done .bet-cta-progress-text {
  color: #10b981;
}
.bet-cta-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.bet-cta-title {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  line-height: 1.25;
}
.bet-cta-subtitle {
  font-size: 12.5px;
  color: rgba(255,255,255,0.7);
}
.bet-cta-arrow {
  font-size: 20px;
  color: #d4a853;
  flex-shrink: 0;
}
body.ltr .bet-cta-arrow {
  transform: scaleX(-1);
}

/* ============================================================ */
/* v2.1.0 - RECOVERY CODE SCREEN (dramatic + celebratory)        */
/* ============================================================ */
#screen-recovery-code {
  background: linear-gradient(180deg, #0a1628 0%, #1a2942 100%);
}
.rc-container {
  position: relative;
  padding-top: 16px;
  padding-bottom: 32px;
}
/* v2.5.39: topbar on screen-recovery-code sits above the confetti layer */
.topbar-recovery {
  position: relative;
  z-index: 2;
  background: transparent;
  border-bottom: none;
  backdrop-filter: none;
}

/* Hero */
.rc-hero {
  text-align: center;
  margin-bottom: 18px;
}
.rc-hero-title {
  font-size: 24px;
  font-weight: 800;
  color: #d4a853;
  margin: 0 0 6px;
}
.rc-hero-subtitle {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  margin: 0;
}

.rc-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212,168,83,0.4), transparent);
  margin: 18px 0 22px;
}

/* Code label + card */
.rc-code-label {
  font-size: 14px;
  color: rgba(255,255,255,0.65);
  text-align: center;
  letter-spacing: .5px;
  margin-bottom: 10px;
}
.rc-code-card {
  position: relative;
  background: linear-gradient(140deg, rgba(212,168,83,0.08) 0%, rgba(212,168,83,0.02) 100%);
  border: 2px solid #d4a853;
  border-radius: 16px;
  padding: 28px 12px;
  margin-bottom: 18px;
  text-align: center;
  animation: rc-slide-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) both,
             rc-pulse 3s ease-in-out 0.7s infinite;
}
@keyframes rc-slide-up {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes rc-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(212,168,83,0.45), 0 0 18px rgba(212,168,83,0.18); }
  50%      { box-shadow: 0 0 0 6px rgba(212,168,83,0.0), 0 0 26px rgba(212,168,83,0.34); }
}
.rc-code-text {
  font-family: 'SFMono-Regular', 'Menlo', 'Consolas', 'Courier New', monospace;
  /* v2.4: shrink so XXXX-XXXX-XXXX-XXXX always fits on a single line. The
     code is 19 chars; we want it never to wrap. We use ch units so it scales
     to the chosen monospace font, plus a vw cap for narrow phones. */
  font-size: clamp(13px, 4.6vw, 24px);
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #fff;
  text-shadow: 0 0 14px rgba(212,168,83,0.35);
  user-select: all;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
}
.rc-code-text.rc-reveal { opacity: 0.7; }

/* Warning box */
.rc-warning-box {
  background: rgba(245, 197, 24, 0.06);
  border: 1px solid rgba(245, 197, 24, 0.25);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 18px;
}
/* v2.5.37: low-key "ask the admin for a new link" note - only shown to
   regular members (mode === 'joined'). Visually softer than the yellow
   warning so it doesn't compete for attention. */
.rc-admin-help-note {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: rgba(94, 174, 255, 0.06);
  border: 1px solid rgba(94, 174, 255, 0.22);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 18px;
}
.rc-admin-help-note > i { color: #5eaeff; font-size: 18px; margin-top: 1px; flex-shrink: 0; }
.rc-admin-help-title { font-size: 12.5px; font-weight: 600; color: #cfe3ff; margin-bottom: 2px; }
.rc-admin-help-text  { font-size: 12px; line-height: 1.45; color: rgba(255,255,255,0.62); }
.rc-warning-title {
  font-size: 14px;
  font-weight: 700;
  color: #f5c518;
  margin-bottom: 4px;
}
.rc-warning-text {
  font-size: 13px;
  color: rgba(255,255,255,0.78);
  line-height: 1.5;
}
.rc-warning-privacy {
  margin-top: 6px;
  font-size: 12px;
  color: rgba(255,255,255,0.55);
}

/* Action buttons - v2.4: three-up row (screenshot / email / download) */
.rc-actions-primary {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 8px;
}
/* v2.5.10: two-up variant (Screenshot + Email myself only) */
.rc-actions-primary-two {
  grid-template-columns: 1fr 1fr;
}
/* v2.5.5: small helper line below the 3 action buttons */
.rc-actions-hint {
  font-size: 12px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
  margin: 4px 4px 16px;
  padding: 8px 10px;
  background: rgba(212, 168, 83, 0.05);
  border-radius: 8px;
}
.rc-actions-secondary {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}
@media (max-width: 360px) {
  .rc-actions-primary { gap: 6px; }
  .rc-actions-primary .rc-action-btn { padding: 10px 6px; font-size: 12px; }
  .rc-actions-primary .rc-action-icon { font-size: 16px; }
  .rc-action-label { font-size: 11px; }
}
.rc-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: 12px 14px;
  color: #fff;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.18s;
  width: 100%;
}
.rc-action-btn:hover {
  background: rgba(212,168,83,0.1);
  border-color: rgba(212,168,83,0.4);
}
.rc-action-btn:active { transform: scale(0.97); }
.rc-action-btn.rc-success {
  background: rgba(16,185,129,0.18);
  border-color: rgba(16,185,129,0.55);
  color: #6ee7b7;
  animation: rc-success-glow 0.6s ease-out;
}
@keyframes rc-success-glow {
  0%   { box-shadow: 0 0 0 0 rgba(16,185,129,0.6); }
  100% { box-shadow: 0 0 0 14px rgba(16,185,129,0); }
}
.rc-action-icon { font-size: 18px; }
.rc-action-btn-secondary {
  background: transparent;
  border: 1px dashed rgba(255,255,255,0.18);
  font-size: 13px;
  padding: 10px 16px;
  max-width: 240px;
}

/* Continue button */
.rc-continue-btn {
  width: 100%;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border: none;
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  padding: 16px 18px;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(16,185,129,0.32);
  transition: transform 0.15s, box-shadow 0.15s;
}
.rc-continue-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(16,185,129,0.45);
}
.rc-continue-btn:active { transform: scale(0.98); }

/* Warning modal */
.rc-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  align-items: center;
  justify-content: center;
}
.rc-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(2px);
}
.rc-modal-content {
  position: relative;
  background: #142030;
  border: 1px solid rgba(212,168,83,0.25);
  border-radius: 16px;
  padding: 22px;
  width: min(92vw, 420px);
  color: #fff;
  box-shadow: 0 14px 40px rgba(0,0,0,0.6);
  animation: rc-modal-in 0.18s ease-out;
}
@keyframes rc-modal-in {
  from { opacity: 0; transform: translateY(8px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.rc-modal-title {
  font-size: 17px;
  font-weight: 700;
  color: #f5c518;
  margin-bottom: 10px;
}
.rc-modal-text {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255,255,255,0.8);
  margin-bottom: 18px;
}
.rc-modal-actions {
  display: flex;
  gap: 10px;
}
.rc-modal-actions button { flex: 1; }
.rc-modal-continue {
  background: rgba(239,68,68,0.16);
  border: 1px solid rgba(239,68,68,0.45);
  color: #fca5a5;
  border-radius: 10px;
  padding: 10px 14px;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
}
.rc-modal-continue:hover {
  background: rgba(239,68,68,0.24);
}

/* v2.4.4: positive-affirmation "Yes, I saved it - continue" button.
   Green because it's the happy-path answer to "did you save?" */
.rc-modal-continue-yes {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border: none;
  color: #fff;
  border-radius: 10px;
  padding: 10px 14px;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(16,185,129,0.25);
  transition: transform 0.15s, box-shadow 0.15s;
}
.rc-modal-continue-yes:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16,185,129,0.4);
}
.rc-modal-continue-yes:active { transform: scale(0.98); }

/* v2.4: knockout first-time single-match walkthrough */
.ko-single-progress-wrap {
  padding: 0 16px;
  margin-top: 4px;
  margin-bottom: 6px;
}
.ko-single-progress-bar {
  height: 4px;
  background: rgba(255,255,255,0.08);
  border-radius: 4px;
  overflow: hidden;
}
.ko-single-progress-bar > div {
  height: 100%;
  background: linear-gradient(90deg, #d4a853, #f5c518);
  transition: width 0.3s ease-out;
}
.ko-single-container {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 130px);
}
.ko-single-instructions {
  text-align: center;
  color: rgba(255,255,255,0.7);
  font-size: 14px;
  margin: 10px 0 16px;
}
.ko-single-card {
  flex: 0 0 auto;
  background: linear-gradient(140deg, rgba(212,168,83,0.08), rgba(212,168,83,0.02));
  border: 1px solid rgba(212,168,83,0.25);
  border-radius: 18px;
  padding: 22px 16px;
  margin-bottom: 18px;
}
.ko-single-match-header {
  text-align: center;
  font-size: 12px;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.ko-single-points {
  text-align: center;
  font-size: 12px;
  color: #d4a853;
  margin-bottom: 18px;
}
.ko-single-teams {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.ko-single-team {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(0,0,0,0.25);
  border: 2px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 18px 16px;
  cursor: pointer;
  transition: all 0.18s;
  font-family: inherit;
  color: #fff;
  text-align: start;
  width: 100%;
}
.ko-single-team:hover {
  border-color: rgba(212,168,83,0.5);
  background: rgba(212,168,83,0.08);
}
.ko-single-team:active { transform: scale(0.985); }
.ko-single-team.tbd {
  opacity: 0.45;
  cursor: not-allowed;
}
.ko-single-team .ko-single-flag {
  font-size: 32px;
  line-height: 1;
}
.ko-single-team .ko-single-name {
  flex: 1;
  font-size: 17px;
  font-weight: 700;
}
/* v2.5.44: small ×N badge next to the team name showing the pool-resolved
   risk multiplier (per-team override → category → default). */
.ko-single-team .ko-single-mult {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #d4a853;
  background: rgba(212, 168, 83, 0.12);
  border: 1px solid rgba(212, 168, 83, 0.32);
  margin-inline-end: 8px;
  flex-shrink: 0;
}
.ko-single-team.selected .ko-single-mult {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.4);
  color: #4ade80;
}
.ko-single-team .ko-single-check {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: 1.5px solid rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  transition: all 0.2s;
  flex-shrink: 0;
}
.ko-single-team.selected {
  border-color: #10b981;
  background: rgba(16,185,129,0.12);
  box-shadow: 0 0 0 1px rgba(16,185,129,0.3), 0 8px 28px rgba(16,185,129,0.18);
}
.ko-single-team.selected .ko-single-check {
  background: #10b981;
  border-color: #10b981;
  color: #fff;
}
.ko-single-vs {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.15em;
  margin: -2px 0 -2px;
}
.ko-single-nav {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: auto;
  padding-bottom: 8px;
}
.ko-single-nav .btn-secondary { flex: 1; }
.ko-single-nav .btn-ghost {
  flex: 1;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.55);
  font-family: inherit;
  font-size: 13px;
  padding: 12px;
  cursor: pointer;
}
.ko-single-nav .btn-ghost:hover { color: rgba(255,255,255,0.85); }

/* v2.4.6: simplified share-modal styles. The previous .share-options-grid
   (2x2) + QR code is replaced with two big WhatsApp + Telegram buttons
   and an inline URL+copy row. The legacy classes below are kept so any
   stale references don't break, but no longer used in the visible layout. */
.share-modal-close-x {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  width: 34px;
  height: 34px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  transition: all 0.18s;
  padding: 0;
}
.share-modal-close-x:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
}
.share-options-primary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 18px 0 14px;
}
.share-option-large {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 12px;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}
.share-option-large:hover {
  transform: translateY(-1px);
  filter: brightness(1.06);
}
.share-option-large:active { transform: scale(0.98); }
.share-option-whatsapp {
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
}
.share-option-telegram {
  background: linear-gradient(135deg, #2AABEE 0%, #229ED9 100%);
  box-shadow: 0 4px 14px rgba(42, 171, 238, 0.35);
}
.share-url-row {
  display: flex;
  align-items: stretch;
  gap: 8px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 4px;
}
.share-url-row .share-url-display {
  flex: 1;
  background: transparent;
  border: none;
  padding: 10px 12px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 12px;
  font-family: 'SFMono-Regular', 'Menlo', 'Consolas', monospace;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: start;
  user-select: all;
}
.share-url-row .share-url-display:hover {
  color: #fff;
}
.share-url-copy-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(212, 168, 83, 0.18);
  border: 1px solid rgba(212, 168, 83, 0.45);
  color: #d4a853;
  border-radius: 8px;
  padding: 0 14px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
  white-space: nowrap;
  transition: all 0.15s;
}
.share-url-copy-btn:hover {
  background: rgba(212, 168, 83, 0.3);
  color: #fff;
}
.share-url-copy-btn:active { transform: scale(0.97); }

/* v2.4.6: dynamic points-per-position hint shown on group betting screens.
   Lists what each position / correct team is worth so the user knows the
   scoring on THIS pool (not a hardcoded default). */
.sp-points-hint, .group-points-hint {
  margin-top: 8px;
  display: flex;
  /* v2.5.36: force one row on mobile - chips were wrapping to two lines
     and eating vertical space. Smaller font + tighter padding + shorter
     "#1" labels make all four pills fit on a 320px viewport. */
  flex-wrap: nowrap;
  justify-content: center;
  gap: 4px;
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.55);
}
.sp-points-hint .pts-pill, .group-points-hint .pts-pill {
  background: rgba(212, 168, 83, 0.1);
  border: 0.5px solid rgba(212, 168, 83, 0.3);
  color: #d4a853;
  padding: 2px 6px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}
/* v2.5.36: tournament-winner pill stands out from the per-stage chips */
.sp-points-hint .pts-pill.pts-pill-winner {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.32), rgba(212, 168, 83, 0.15));
  border-color: rgba(212, 168, 83, 0.7);
  color: #fff;
}
/* v2.5.38: very small clarification under the points pills */
.sp-mult-note {
  margin-top: 4px;
  text-align: center;
  font-size: 10px;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.42);
  font-style: italic;
  font-variant-numeric: tabular-nums;
}

/* v2.4.7: bilateral bracket view modal. Shows both sides of the bracket
   (R16L → QFL → SFL → FINAL ← SFR ← QFR ← R16R) with connector lines so
   it's instantly readable as a tournament tree. Falls back to side-tabs
   on narrow screens so users can focus on the half they care about. */
.sp-bracket-view-modal-content {
  width: min(98vw, 1080px);
  max-width: 1080px;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  padding: 14px 14px 12px;
  overflow: hidden;
}
.sp-bv-close-x {
  position: absolute;
  top: 10px;
  inset-inline-end: 10px;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  padding: 0;
  transition: all 0.18s;
}
.sp-bv-close-x:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}
.sp-bv-header {
  flex-shrink: 0;
  padding-bottom: 6px;
}
.sp-bv-side-tabs {
  display: none;
  gap: 6px;
  margin-top: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.sp-bv-side-tab {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
  border-radius: 999px;
  padding: 5px 12px;
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}
.sp-bv-side-tab.active {
  background: rgba(212, 168, 83, 0.18);
  border-color: rgba(212, 168, 83, 0.5);
  color: #d4a853;
}
.sp-bv-hint {
  flex-shrink: 0;
  text-align: center;
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.4);
  margin-top: 4px;
}

.sp-bracket-view-scroll {
  flex: 1;
  overflow-x: auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 8px 2px;
  position: relative;
}

/* The tree: 7-column CSS Grid. The match rows are positioned by
   justify-content:space-around inside each column, so deeper rounds
   naturally line up with the midpoint between their feeders. */
.sp-bracket-tree {
  display: grid;
  grid-template-columns:
    [r16l] minmax(115px, 1fr)
    [qfl]  minmax(115px, 1fr)
    [sfl]  minmax(115px, 1fr)
    [fin]  minmax(140px, 1.2fr)
    [sfr]  minmax(115px, 1fr)
    [qfr]  minmax(115px, 1fr)
    [r16r] minmax(115px, 1fr);
  gap: 6px;
  min-width: 880px;
  align-items: stretch;
  position: relative;
}
.sp-bv-col {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  padding: 4px 0;
  position: relative;
  min-height: 460px;
}
.sp-bv-col-fin {
  justify-content: center;
  gap: 12px;
}
.sp-bv-col-title {
  font-size: 10px;
  text-align: center;
  color: #d4a853;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  padding: 3px 0 6px;
  border-bottom: 1px solid rgba(212, 168, 83, 0.15);
  margin-bottom: 8px;
  flex-shrink: 0;
}
.sp-bv-col-stack {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  flex: 1;
  gap: 6px;
}
.sp-bv-match {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 6px 7px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
  font-size: 11px;
}
.sp-bv-team {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 7px;
  border-radius: 5px;
  color: rgba(255, 255, 255, 0.65);
  background: rgba(0, 0, 0, 0.22);
  min-height: 22px;
  line-height: 1.15;
}
.sp-bv-team.picked {
  background: rgba(16, 185, 129, 0.16);
  color: #fff;
  font-weight: 600;
  border: 1px solid rgba(16, 185, 129, 0.45);
}
.sp-bv-team.tbd {
  color: rgba(255, 255, 255, 0.32);
  font-style: italic;
}
.sp-bv-team-flag {
  font-size: 14px;
  flex-shrink: 0;
  line-height: 1;
}
.sp-bv-team-name {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 11px;
}
.sp-bv-team-check {
  width: 12px;
  height: 12px;
  color: #10b981;
  flex-shrink: 0;
}
.sp-bv-team:not(.picked) .sp-bv-team-check { display: none; }
.sp-bv-match-vs {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.3);
  text-align: center;
  letter-spacing: 0.1em;
  padding: 1px 0;
}

/* Champion card - bigger, gold, prominent */
.sp-bv-champion {
  background: linear-gradient(135deg, rgba(212, 168, 83, 0.25) 0%, rgba(212, 168, 83, 0.05) 100%);
  border: 1.5px solid rgba(212, 168, 83, 0.55);
  border-radius: 12px;
  padding: 12px 8px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  box-shadow: 0 4px 18px rgba(212, 168, 83, 0.15);
}
.sp-bv-champion.tbd {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}
.sp-bv-champion-trophy { font-size: 22px; }
.sp-bv-champion-label {
  font-size: 9.5px;
  color: #d4a853;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
}
.sp-bv-champion-flag { font-size: 26px; line-height: 1; }
.sp-bv-champion-name {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
}
.sp-bv-champion.tbd .sp-bv-champion-name {
  color: rgba(255, 255, 255, 0.4);
  font-style: italic;
}

/* ===== Connector lines via pseudo-elements =====
   Each non-final match has a short horizontal stub going OUT toward its
   parent. The vertical "bracket" piece is drawn on the OUTER edge of
   each match (top half + bottom half) using a 1px right/left border so
   adjacent feeder pairs visually connect. */
.sp-bv-col-r16l .sp-bv-match::after,
.sp-bv-col-qfl  .sp-bv-match::after,
.sp-bv-col-sfl  .sp-bv-match::after {
  content: '';
  position: absolute;
  inset-inline-end: -7px;
  top: 50%;
  width: 7px;
  height: 1px;
  background: rgba(212, 168, 83, 0.4);
  pointer-events: none;
  z-index: 1;
}
.sp-bv-col-r16r .sp-bv-match::before,
.sp-bv-col-qfr  .sp-bv-match::before,
.sp-bv-col-sfr  .sp-bv-match::before {
  content: '';
  position: absolute;
  inset-inline-start: -7px;
  top: 50%;
  width: 7px;
  height: 1px;
  background: rgba(212, 168, 83, 0.4);
  pointer-events: none;
  z-index: 1;
}

/* Vertical connector spanning each feeder pair to their parent.
   Implemented on the COLUMN's child wrappers (sp-bv-pair-wrap). */
.sp-bv-pair-wrap {
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-around;
  position: relative;
  padding: 0;
}
.sp-bv-pair-wrap.left::after {
  content: '';
  position: absolute;
  inset-inline-end: 0;
  top: 25%;
  bottom: 25%;
  width: 1px;
  background: rgba(212, 168, 83, 0.4);
  pointer-events: none;
  z-index: 0;
}
.sp-bv-pair-wrap.right::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 25%;
  bottom: 25%;
  width: 1px;
  background: rgba(212, 168, 83, 0.4);
  pointer-events: none;
  z-index: 0;
}

/* ===== Side-tab focus: hide opposite half on narrow screens ===== */
.sp-bracket-tree[data-side="left"] .sp-bv-col-sfr,
.sp-bracket-tree[data-side="left"] .sp-bv-col-qfr,
.sp-bracket-tree[data-side="left"] .sp-bv-col-r16r {
  display: none;
}
.sp-bracket-tree[data-side="right"] .sp-bv-col-r16l,
.sp-bracket-tree[data-side="right"] .sp-bv-col-qfl,
.sp-bracket-tree[data-side="right"] .sp-bv-col-sfl {
  display: none;
}
.sp-bracket-tree[data-side="left"],
.sp-bracket-tree[data-side="right"] {
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  min-width: 480px;
}

/* Mobile: show side-tabs, keep grid scrollable */
@media (max-width: 720px) {
  .sp-bv-side-tabs { display: flex; }
  .sp-bracket-view-modal-content {
    padding: 14px 10px 10px;
  }
  .sp-bracket-tree {
    min-width: 760px;
  }
  .sp-bracket-tree[data-side="left"],
  .sp-bracket-tree[data-side="right"] {
    min-width: 440px;
  }
}

/* v2.4: exit-app modal */
.rc-modal-exit {
  text-align: center;
}
.exit-modal-icon {
  font-size: 38px;
  margin-bottom: 10px;
  color: #d4a853;
}
.rc-modal-title-center { text-align: center; }
.rc-modal-text-center { text-align: center; }

/* v2.4: screenshot instructions modal */
.rc-modal.rc-modal-show { display: flex !important; }
.rc-modal-screenshot {
  width: min(94vw, 460px);
  text-align: start;
}
.rc-modal-close {
  position: absolute;
  /* v2.5.7: always physically top-right, regardless of language direction.
     Previously inset-inline-end put it on the LEFT in Hebrew RTL mode. */
  right: 12px;
  top: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}
.rc-modal-close:hover { background: rgba(255,255,255,0.16); color: #fff; }
.rc-modal-code-card {
  background: linear-gradient(135deg, rgba(212,168,83,0.18), rgba(212,168,83,0.08));
  border: 1px solid rgba(212,168,83,0.45);
  border-radius: 14px;
  padding: 14px 16px;
  margin: 4px 0 14px;
  text-align: center;
  box-shadow: 0 0 18px rgba(212,168,83,0.18);
}
.rc-modal-code-label {
  font-size: 12px;
  font-weight: 600;
  color: rgba(245,197,24,0.95);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.rc-modal-code-text {
  font-family: 'SFMono-Regular', 'Menlo', 'Consolas', 'Courier New', monospace;
  font-size: clamp(15px, 5.2vw, 26px);
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #fff;
  text-shadow: 0 0 14px rgba(212,168,83,0.4);
  white-space: nowrap;
  user-select: all;
}
/* v2.5.6: auto-generated screenshot preview area */
.rc-screenshot-preview {
  margin: 4px 0 14px;
  min-height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.25);
  border-radius: 14px;
  padding: 10px;
}
.rc-screenshot-preview .rc-screenshot-img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.45);
}
.rc-screenshot-loading {
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  padding: 30px 12px;
  text-align: center;
}

.rc-screenshot-instructions {
  background: rgba(212,168,83,0.06);
  border: 1px solid rgba(212,168,83,0.2);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 14px;
}
.rc-screenshot-instructions ol {
  padding-inline-start: 22px;
  margin: 0;
  color: rgba(255,255,255,0.92);
  font-size: 14px;
  line-height: 1.65;
}
.rc-screenshot-instructions li {
  margin-bottom: 4px;
}
.rc-screenshot-instructions .rc-key-combo {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.18);
  padding: 2px 8px;
  border-radius: 6px;
  font-family: 'SFMono-Regular', 'Menlo', 'Consolas', monospace;
  font-size: 12px;
  color: #f5c518;
  margin: 0 2px;
}
.rc-modal-tip {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 12px;
  color: rgba(255,255,255,0.65);
  margin-bottom: 16px;
  line-height: 1.5;
}
.rc-modal-tip i { color: #d4a853; flex-shrink: 0; margin-top: 2px; }
.rc-modal-continue-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* Minimal gold sparkles (replaces confetti) */
.rc-confetti-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.rc-sparkle {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #d4a853;
  box-shadow: 0 0 6px rgba(212, 168, 83, 0.7);
  opacity: 0;
  animation: rc-sparkle-fade 2.4s ease-out forwards;
}
@keyframes rc-sparkle-fade {
  0%   { opacity: 0; transform: scale(0.4) translateY(0); }
  30%  { opacity: 1; transform: scale(1) translateY(-6px); }
  100% { opacity: 0; transform: scale(0.5) translateY(-22px); }
}
.rc-container > * { position: relative; z-index: 1; }
