/* =========================================================
   ScoreB - competition.html stylesheet
   Reuses base tokens + shared header/tab/table classes from
   style.css. Everything here is specific to the competition
   (league/cup) profile page.
   ========================================================= */

html, body { height: 100%; }

.profile-page-body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
}

.profile-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---------- Competition header ---------- */
.competition-header {
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
  padding: 22px 16px;
}

.team-header-loading {
  color: var(--text-dim);
  font-size: 13px;
  text-align: center;
  padding: 20px;
}

.competition-header-content {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.competition-logo {
  width: 64px;
  height: 64px;
  object-fit: contain;
  background: #fff;
  border-radius: var(--radius);
  padding: 8px;
  flex-shrink: 0;
}

.competition-header-text { flex: 1; min-width: 160px; }

.competition-header-text h2 {
  margin: 0 0 6px;
  font-size: 20px;
  color: var(--text);
}

.competition-meta {
  color: var(--text-dim);
  font-size: 13px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.competition-meta span i { margin-right: 5px; color: var(--accent); }

.season-select {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 7px 10px;
  font-size: 13px;
}

/* ---------- Tabs / content shell ---------- */
.competition-content {
  max-width: 760px;
  width: 100%;
  margin: 0 auto;
  flex: 1;
}

#competition-tabs { position: sticky; top: 0; z-index: 9; }

/* ---------- Top scorers tab ---------- */
.scorers-list { display: flex; flex-direction: column; gap: 2px; }

.scorer-row {
  display: grid;
  grid-template-columns: 24px 32px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 9px 4px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
}

.scorer-row:last-child { border-bottom: none; }
.scorer-row:hover { background: rgba(255, 255, 255, 0.03); }

.scorer-rank { font-size: 12px; color: var(--text-dim); font-weight: 700; text-align: center; }
.scorer-photo { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; background: var(--bg-card); }

.scorer-info { min-width: 0; }
.scorer-info .name { font-size: 13px; font-weight: 700; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.scorer-info .team { font-size: 11px; color: var(--text-dim); }

.scorer-goals { font-size: 16px; font-weight: 700; color: var(--accent); text-align: right; }

/* ---------- Overview tab ---------- */
.competition-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}

.competition-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
}

.competition-info-card .label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--text-dim);
  margin-bottom: 4px;
}

.competition-info-card .value { font-size: 14px; font-weight: 700; color: var(--text); }
