/* =====================================
   Live Score Feed Styles
   ===================================== */

body.scores-body {
  background: var(--bg);
  color: var(--fg);
  font-family: 'DM Sans', sans-serif;
  min-height: 100vh;
}

/* ---- Header ---- */
.scores-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: var(--bg-card);
  position: sticky;
  top: 0;
  z-index: 100;
}

.scores-logo {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 20px;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.live-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--coral-dim);
  color: var(--coral);
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid rgba(255,77,109,0.3);
}

.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--coral);
  animation: pulse-dot 1.5s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

/* ---- Event Bar ---- */
.event-bar {
  padding: 12px 20px;
  background: var(--bg-card);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.event-selector-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.event-select {
  background: var(--bg-card-hover);
  color: var(--fg);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 10px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%238899bb' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.event-select:focus {
  outline: none;
  border-color: var(--accent);
}

.event-meta {
  font-size: 12px;
  color: var(--fg-muted);
  padding-left: 4px;
}

/* ---- Division Tabs ---- */
.division-tabs {
  display: flex;
  overflow-x: auto;
  gap: 4px;
  padding: 10px 20px;
  background: var(--bg);
  scrollbar-width: none;
  -ms-overflow-style: none;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.division-tabs::-webkit-scrollbar { display: none; }

.div-tab {
  flex-shrink: 0;
  background: var(--bg-card);
  color: var(--fg-muted);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.div-tab:hover {
  background: var(--bg-card-hover);
  color: var(--fg);
}

.div-tab.active {
  background: var(--accent-dim);
  color: var(--accent);
  border-color: rgba(0,229,196,0.3);
}

/* ---- Score Feed ---- */
.scores-main {
  padding: 8px 16px 80px;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--fg-muted);
}

.empty-state p {
  margin-top: 16px;
  font-size: 15px;
}

/* ---- Leaderboard ---- */
.leaderboard {
  background: var(--bg-card);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.06);
}

.leaderboard-head {
  display: grid;
  grid-template-columns: 48px 1fr auto 40px;
  gap: 12px;
  padding: 12px 16px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--fg-muted);
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.score-row {
  display: grid;
  grid-template-columns: 48px 1fr auto 40px;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background 0.2s;
}

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

.score-row.row-performing {
  background: rgba(0,229,196,0.04);
  border-left: 3px solid var(--accent);
}

.score-row.row-scored {
  background: rgba(0,229,196,0.02);
}

/* Rank */
.sr-rank { display: flex; align-items: center; justify-content: center; }

.rank-num {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 16px;
  color: var(--fg-muted);
}

.rank-gold { color: #FFD700; }
.rank-silver { color: #C0C0C0; }
.rank-bronze { color: #CD7F32; }

.rank-live { display: flex; align-items: center; }

.mini-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
  animation: pulse-dot 1.5s ease-in-out infinite;
}

.rank-pending { color: rgba(136,153,187,0.4); font-size: 20px; }

/* Team info */
.sr-team { min-width: 0; }

.team-name {
  font-weight: 600;
  font-size: 15px;
  color: var(--fg);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.team-gym {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 2px;
}

.sr-status {
  display: inline-block;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.08em;
  padding: 2px 7px;
  border-radius: 4px;
  margin-top: 4px;
}

.status-scored { background: var(--accent-dim); color: var(--accent); }
.status-performing { background: var(--coral-dim); color: var(--coral); }
.status-pending { background: rgba(136,153,187,0.1); color: var(--fg-muted); }

/* Score */
.sr-score {
  text-align: right;
  min-width: 70px;
}

.score-num {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 18px;
  color: var(--fg);
  display: block;
}

.score-num.score-final { color: var(--accent); }
.score-pending { font-size: 18px; color: var(--fg-muted); opacity: 0.4; }

.score-breakdown {
  display: flex;
  gap: 6px;
  font-size: 10px;
  color: var(--fg-muted);
  margin-top: 4px;
  justify-content: flex-end;
}

.deduction { color: var(--coral); }

/* Follow button */
.follow-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.follow-btn:hover { background: var(--bg-card-hover); }
.follow-btn.following { background: var(--accent-dim); }

/* ---- Stream Status ---- */
.stream-status {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 12px;
  color: var(--fg-muted);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.stream-status.connected { color: var(--accent); }

.stream-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--fg-muted);
}

.stream-status.connected .stream-dot { background: var(--accent); animation: pulse-dot 1.5s ease-in-out infinite; }

/* Mobile responsive */
@media (max-width: 480px) {
  .leaderboard-head { padding: 10px 12px; }
  .score-row { padding: 12px; }
  .team-name { font-size: 14px; }
  .score-num { font-size: 16px; }
  .score-breakdown { display: none; }
}