/* =========================================================
   08 RUN Battle - Team Panel Only Override
   이 파일은 홈의 "팀 순위 · 멤버 기여도" 칸만 잡는다.
   기존 style.css와 충돌하지 않도록 team-only-* 클래스만 강제 적용.
   ========================================================= */

.team-only-panel {
  overflow: hidden !important;
}

.team-only-panel h2 {
  margin-bottom: 22px !important;
}

.team-only-list {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 18px !important;
  width: 100% !important;
}

.team-only-card {
  display: block !important;
  width: 100% !important;
  padding: 18px !important;
  border-radius: 20px !important;
  border: 1px solid rgba(148, 163, 184, 0.24) !important;
  background: rgba(15, 23, 42, 0.46) !important;
  box-sizing: border-box !important;
}

.team-only-top {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: start !important;
  gap: 16px !important;
  width: 100% !important;
  margin-bottom: 12px !important;
}

.team-only-namebox {
  display: flex !important;
  align-items: flex-start !important;
  gap: 10px !important;
  min-width: 0 !important;
}

.team-only-dot {
  display: inline-block !important;
  width: 12px !important;
  height: 12px !important;
  border-radius: 999px !important;
  flex: 0 0 auto !important;
  margin-top: 7px !important;
}

.team-only-title {
  display: block !important;
  font-size: 21px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
  color: var(--text) !important;
  white-space: nowrap !important;
}

.team-only-meta {
  display: block !important;
  margin-top: 6px !important;
  font-size: 13px !important;
  line-height: 1.45 !important;
  color: var(--muted) !important;
}

.team-only-total {
  display: block !important;
  text-align: right !important;
  font-size: 21px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
  color: var(--text) !important;
  white-space: nowrap !important;
  font-variant-numeric: tabular-nums !important;
}

.team-only-progress {
  display: block !important;
  width: 100% !important;
  height: 10px !important;
  margin: 12px 0 16px !important;
  border-radius: 999px !important;
  background: rgba(2, 6, 23, 0.58) !important;
  overflow: hidden !important;
}

.team-only-progress i {
  display: block !important;
  height: 100% !important;
  min-width: 2px !important;
  border-radius: 999px !important;
}

.team-only-member-title {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
  margin: 0 0 10px !important;
  color: var(--muted) !important;
  font-size: 13px !important;
  line-height: 1.3 !important;
}

.team-only-member-title b {
  color: var(--text) !important;
  font-size: 13px !important;
  font-weight: 900 !important;
}

.team-only-table {
  display: block !important;
  width: 100% !important;
  border: 1px solid rgba(148, 163, 184, 0.16) !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  background: rgba(2, 6, 23, 0.20) !important;
  box-sizing: border-box !important;
}

.team-only-head,
.team-only-row {
  display: grid !important;
  grid-template-columns: minmax(130px, 1.3fr) minmax(150px, 1fr) 96px 58px !important;
  gap: 12px !important;
  align-items: center !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.team-only-head {
  padding: 10px 12px !important;
  background: rgba(2, 6, 23, 0.40) !important;
  color: var(--muted) !important;
  font-size: 12px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
}

.team-only-row {
  padding: 11px 12px !important;
  border-top: 1px solid rgba(148, 163, 184, 0.12) !important;
  background: rgba(255, 255, 255, 0.035) !important;
}

.team-only-row:hover {
  background: rgba(255, 255, 255, 0.06) !important;
}

.team-only-member {
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
  min-width: 0 !important;
  overflow: hidden !important;
}

.team-only-member b {
  display: block !important;
  min-width: 0 !important;
  max-width: 180px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  font-size: 14px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
  color: var(--text) !important;
}

.team-only-member em {
  display: inline-flex !important;
  flex: 0 0 auto !important;
  font-style: normal !important;
  font-size: 10px !important;
  line-height: 1 !important;
  font-weight: 900 !important;
  color: #fde68a !important;
  padding: 3px 6px !important;
  border-radius: 999px !important;
  background: rgba(245, 158, 11, 0.14) !important;
  border: 1px solid rgba(245, 158, 11, 0.28) !important;
}

.team-only-contrib {
  display: grid !important;
  grid-template-columns: 50px minmax(70px, 1fr) !important;
  align-items: center !important;
  gap: 9px !important;
  min-width: 0 !important;
}

.team-only-contrib strong {
  display: block !important;
  text-align: right !important;
  font-size: 13px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
  color: var(--text) !important;
  font-variant-numeric: tabular-nums !important;
}

.team-only-mini {
  display: block !important;
  width: 100% !important;
  height: 7px !important;
  border-radius: 999px !important;
  background: rgba(2, 6, 23, 0.60) !important;
  overflow: hidden !important;
}

.team-only-mini i {
  display: block !important;
  height: 100% !important;
  min-width: 2px !important;
  border-radius: 999px !important;
}

.team-only-km,
.team-only-act {
  display: block !important;
  text-align: right !important;
  white-space: nowrap !important;
  font-size: 13px !important;
  line-height: 1.2 !important;
  font-weight: 800 !important;
  font-variant-numeric: tabular-nums !important;
}

.team-only-km {
  color: var(--text) !important;
}

.team-only-act {
  color: var(--muted) !important;
}

.team-only-empty {
  display: block !important;
  padding: 14px !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, 0.045) !important;
  color: var(--muted) !important;
  font-size: 13px !important;
  line-height: 1.3 !important;
}

/* 기존 누적 CSS가 끼어드는 것 방지 */
.team-only-panel .team-row,
.team-only-panel .team-head,
.team-only-panel .team-member-box,
.team-only-panel .team-member-row,
.team-only-panel .team-member-list,
.team-only-panel .team-contrib-card,
.team-only-panel .clean-team-card {
  all: unset !important;
}

/* 모바일/좁은 화면 */
@media (max-width: 760px) {
  .team-only-top {
    grid-template-columns: 1fr !important;
  }

  .team-only-total {
    text-align: left !important;
    font-size: 18px !important;
  }

  .team-only-table {
    overflow-x: auto !important;
  }

  .team-only-head,
  .team-only-row {
    min-width: 590px !important;
  }
}
