:root {
  --bg-main: #f0f4ff;

  --primary: #1d4ed8;
  --secondary: #dc2626;
  --accent: #16a34a;

  --text-main: #1e293b;
  --text-muted: #64748b;

  --card-bg: #ffffff;
  --border: #e5e7eb;
}

* {
  box-sizing: border-box;
}


body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: var(--bg-main);
  color: var(--text-main);
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 16px;
  overflow-x: hidden; /* 👈 important */
}

h1 {
  text-align: center;
  margin-bottom: 20px;
}

.card {
  background: white;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

input {
  width: 100%;
  padding: 10px;
  margin-bottom: 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 14px;
}

button {
  padding: 10px 14px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  background: var(--primary);
  color: white;
  font-size: 14px;
}

button.secondary {
  background: var(--secondary);
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px; /* 👈 ajoute de l’espace en dessous */
}

.row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.small-input {
  width: 48px;
  height: 42px;
  text-align: center;
  font-size: 1rem;
  font-weight: 600;
  padding: 0;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: #f8fafc;
}

.small-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.hint {
  color: #666;
  font-size: 0.95rem;
}

.empty-state {
  color: #666;
  font-style: italic;
}

.match {
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
  background: #fff;
}

.match-title {
  font-weight: bold;
  font-size: 1rem;
}

.my-prediction {
  margin-top: 8px;
  font-size: 0.95rem;
  color: #334155;
}

.sub-collapsible,
.predictions-collapsible {
  overflow: hidden;
}

.sub-collapsible summary,
.predictions-collapsible summary {
  cursor: pointer;
  font-weight: bold;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sub-collapsible summary::-webkit-details-marker,
.predictions-collapsible summary::-webkit-details-marker {
  display: none;
}

.sub-collapsible {
  margin-top: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 12px;
  background: #fafafa;
}

.section-content {
  margin-top: 12px;
}

summary::before {
  content: "[+]";
  font-family: Arial, sans-serif;
  font-weight: bold;
  color: #475569;
  min-width: 28px;
  display: inline-block;
}

details[open] > summary::before {
  content: "[-]";
}
.predictions-collapsible {
  margin-top: 10px;
  border: 1px solid #dbe3f0;
  border-radius: 10px;
  background: #f8fafc;
  padding: 10px 12px;
}

.predictions-collapsible-compact summary {
  display: grid;
  grid-template-columns: 28px 120px 52px 52px 24px;
  align-items: center;
  column-gap: 10px;
  font-weight: 700;
  color: #334155;
}

.predictions-summary-label,
.prediction-player,
.prediction-player-other {
  display: block;
  width: 120px;
  min-width: 120px;
  font-size: 0.95rem;
  font-weight: 700;
  color: #334155;
  line-height: 1.2;
  white-space: nowrap;
}

.predictions-list {
  margin-top: 8px;
  padding: 0;
  background: transparent;
  border-radius: 0;
}

.predictions-list-compact {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.prediction-row {
  display: grid;
  grid-template-columns: 28px 120px 52px 52px 24px;
  align-items: center;
  column-gap: 10px;
  padding: 4px 0;
}

.prediction-row-other::before {
  content: "";
  display: block;
  width: 28px;
  min-width: 28px;
}
.prediction-right,
.prediction-right-summary {
  display: contents;
}

.prediction-score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  min-width: 52px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: #e2e8f0;
  color: #1e293b;
  font-size: 0.95rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  white-space: nowrap;
}

.prediction-score-missing {
  background: #f1f5f9;
  color: #64748b;
}

.prediction-points {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  width: 52px;
  min-width: 52px;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.prediction-best-badge {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  font-size: 1rem;
  line-height: 1;
}

.predictions-empty {
  padding-left: 20px;
  color: #64748b;
  font-size: 0.9rem;
  font-style: italic;
}
@media (max-width: 700px) {
  .predictions-collapsible {
    padding: 8px 6px;
  }

  .predictions-collapsible-compact summary {
    grid-template-columns: 20px 74px 38px 32px 14px;
    column-gap: 4px;
  }

  .predictions-summary-label {
    width: 74px;
    min-width: 74px;
    font-size: 0.88rem;
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
  }

  .prediction-player,
  .prediction-player-other {
    width: auto;
    min-width: 0;
    font-size: 0.88rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .prediction-row {
    grid-template-columns: 20px minmax(0, 1fr) 38px 32px 14px;
    column-gap: 4px;
  }

  .prediction-row-other::before {
    width: 20px;
    min-width: 20px;
  }

  .prediction-score {
    width: 38px;
    min-width: 38px;
    height: 22px;
    font-size: 0.84rem;
    padding: 0 4px;
  }

  .prediction-points {
    width: 32px;
    min-width: 32px;
    font-size: 0.78rem;
  }

  .prediction-best-badge {
    font-size: 0.8rem;
    justify-content: flex-start;
  }

  .predictions-empty {
    padding-left: 12px;
    font-size: 0.82rem;
  }
}

/* ===== Classement ===== */

.ranking-table-wrapper {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  margin-top: 8px;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 14px;
  background: white;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.ranking-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 0;
  table-layout: fixed;
  background: white;
}

.ranking-table thead th {
  background: linear-gradient(to right, rgba(29, 78, 216, 0.08), rgba(22, 163, 74, 0.06));
  color: #0f172a;
  padding: 11px 8px;
  font-size: 0.9rem;

  /* important */
  white-space: normal;
  line-height: 1.2;
  text-align: center;

  border-bottom: 1px solid #e5e7eb;
}
.ranking-sortable {
  cursor: pointer;
  user-select: none;
  position: relative;
}

.ranking-sortable::after {
  content: "↕";
  margin-left: 6px;
  font-size: 0.72rem;
  opacity: 0.35;
}

.ranking-sortable.sorted-asc::after {
  content: "↑";
  opacity: 1;
}

.ranking-sortable.sorted-desc::after {
  content: "↓";
  opacity: 1;
}

.ranking-table tbody td {
  padding: 12px 8px;
  border-top: 1px solid #eef2f7;
  vertical-align: middle;

  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* en-têtes : peuvent passer sur plusieurs lignes */
.ranking-table tbody tr {
  transition: background 0.15s ease, transform 0.15s ease;
}

.ranking-table tbody tr:nth-child(even) {
  background: #fcfdff;
}

.ranking-table tbody tr:hover {
  background: #f8fbff;
}

.rank-cell {
  font-weight: 700;
  text-align: center;
  width: 80px;
}

.rank-cell .rank-position-circle {
  margin: 0 auto;
}

.rank-position-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  padding: 0 10px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #0f172a;
  font-weight: 700;
}
.rank-gold,
.rank-silver,
.rank-bronze {
  font-weight: 700;
}
.player-cell {
  min-width: 220px;
}

.ranking-me-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(29, 78, 216, 0.1);
  color: #1d4ed8;
  font-size: 0.78rem;
  font-weight: 700;
}

.ranking-stat-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #0f172a;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.ranking-stat-pill-muted {
  background: #fff1f2;
  color: #be123c;
}

.points-cell {
  font-weight: 700;
}

.ranking-points-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 54px;
  padding: 4px 8px;
  border-radius: 999px;
  background: linear-gradient(to right, #1d4ed8, #2563eb);
  color: white;
  font-weight: 700;
  font-size: 0.88rem;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 3px 8px rgba(37, 99, 235, 0.18);
}

/* Top 3 subtils */
.ranking-table tbody tr.rank-gold,
.ranking-mobile-card.rank-gold {
  background: linear-gradient(to right, rgba(245, 158, 11, 0.10), rgba(255, 255, 255, 1));
}

.ranking-table tbody tr.rank-silver,
.ranking-mobile-card.rank-silver {
  background: linear-gradient(to right, rgba(148, 163, 184, 0.12), rgba(255, 255, 255, 1));
}

.ranking-table tbody tr.rank-bronze,
.ranking-mobile-card.rank-bronze {
  background: linear-gradient(to right, rgba(180, 83, 9, 0.10), rgba(255, 255, 255, 1));
}

/* Ligne du joueur courant */
.ranking-table tbody tr.rank-current-user,
.ranking-mobile-card.rank-current-user {
  outline: 2px solid rgba(29, 78, 216, 0.18);
  outline-offset: -2px;
}

.ranking-mobile-card.rank-current-user {
  background: linear-gradient(to right, rgba(29, 78, 216, 0.06), #ffffff);
  border: 2px solid #93c5fd;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.12);
}

/* ===== Avatars classement ===== */

.ranking-avatar {
  width: 52px !important;
  height: 52px !important;
  min-width: 52px;
  min-height: 52px;
  max-width: 52px;
  max-height: 52px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  display: block;
  flex-shrink: 0;
  border: 1px solid #dbe3f0;
  background: #f8fafc;
}

.ranking-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 700;
  color: #475569;
  background: #e2e8f0;
}

.ranking-avatar-mobile {
	width: 44px;
	height: 44px;
	min-width: 44px;
	min-height: 44px;
	max-width: 44px;
	max-height: 44px;
	border-radius: 50%;
	object-fit: cover;
}

.ranking-mobile-list {
  display: none;
}

.ranking-mobile-card {
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 14px;
  margin-top: 12px;
  background: white;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.05);
}

.ranking-mobile-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.ranking-mobile-player {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.ranking-mobile-name-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.ranking-mobile-position {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ranking-mobile-name {
  font-weight: 700;
  color: #111827;
  word-break: break-word;
}

.ranking-mobile-points {
  white-space: nowrap;
  flex-shrink: 0;
}

.ranking-mobile-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.ranking-mobile-stat {
  background: #f8fafc;
  border-radius: 12px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border: 1px solid #eef2f7;
}

.ranking-mobile-label {
  font-size: 0.82rem;
  color: #64748b;
}

.ranking-mobile-value {
  font-weight: 700;
  color: #111827;
  font-size: 1rem;
}

/* ===== Navigation / onglets ===== */

.tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.tab {
  padding: 10px 14px;
  border-radius: 8px;
  border: none;
  background: #e2e8f0;
  color: #1e293b;
  cursor: pointer;
  font-weight: bold;
}

.tab.active {
  background: #2563eb;
  color: white;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* ===== Admin ===== */

.admin-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 0;
  font-size: 0.95rem;
}

.admin-toggle input {
  width: auto;
  margin: 0;
}

.admin-rules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 10px;
}

.admin-rules-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.admin-rules-grid span {
  font-size: 0.95rem;
  color: #334155;
  font-weight: 600;
}

/* ===== Sections Matchs ===== */

.sub-upcoming > summary {
  background: rgba(29, 78, 216, 0.1);
  color: var(--primary);
  padding: 10px 12px;
  border-radius: 8px;
}

.sub-live > summary {
  background: rgba(220, 38, 38, 0.15);
  color: var(--secondary);
  padding: 10px 12px;
  border-radius: 8px;
}

.sub-finished > summary {
  background: rgba(22, 163, 74, 0.12);
  color: var(--accent);
  padding: 10px 12px;
  border-radius: 8px;
}

.sub-collapsible summary {
  display: flex;
  align-items: center;
  gap: 6px;
}

.match-score-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  margin-bottom: 4px;
}

.match-score {
  margin-top: 10px;
  font-size: 1.05rem;
  font-weight: 600;
  color: #0f172a;
}

.match-kickoff {
  margin-top: 6px;
  font-size: 0.95rem;
  color: #334155;
}

.points-badge {
  font-weight: bold;
}

.points-3 {
  color: #16a34a;
  background: rgba(22, 163, 74, 0.1);
}

.points-1 {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.1);
}

.points-0 {
  color: #dc2626;
  background: rgba(220, 38, 38, 0.1);
}

.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--secondary);
  color: white;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1;
}

.live-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: white;
  animation: livePulse 1.2s infinite;
}

@keyframes livePulse {
  0% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
  100% { opacity: 1; transform: scale(1); }
}

#whoami {
  font-size: 0.95rem;
  color: #334155;
}

.match-title-with-crests {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  flex-wrap: wrap;
}

.team-side {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.team-side-left,
.team-side-right {
  justify-content: center;
}

.match-separator {
  margin: 0 4px;
  font-weight: bold;
  color: #475569;
}

.team-crest {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
}

.upcoming-save-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  padding: 10px 12px;
  border: 1px solid var(--primary);
  background: rgba(29, 78, 216, 0.08);
  border-radius: 10px;
}

.upcoming-save-toolbar button {
  flex-shrink: 0;
}

.match-prediction-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.match-edit-status {
  font-size: 0.9rem;
  color: #64748b;
}

.match-edit-status.pending {
  color: #d97706;
  font-style: italic;
}

.match-edit-status.saved {
  color: #16a34a;
  font-weight: 600;
}

.finished-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.filter-btn {
  background: #e2e8f0;
  color: #1e293b;
}

.filter-btn.active {
  background: #2563eb;
  color: white;
}

.load-more-wrapper {
  margin-top: 12px;
  display: flex;
  justify-content: center;
}

.load-more-wrapper:empty {
  display: none;
}

/* ===== Règles / messages ===== */

.rules-display {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.95rem;
  color: #334155;
  margin-bottom: 12px;
}

.save-success {
  color: #16a34a;
  font-weight: 600;
}

.missing-prediction-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  font-size: 0.9rem;
  font-weight: 600;
}

/* ===== Titre de l'app ===== */

.app-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  text-align: center;
  text-shadow: 0 2px 6px rgba(0,0,0,0.25);
  flex-wrap: nowrap;
  margin-bottom: 20px;
}

.app-title-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.08;
}

.app-title-main {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.2rem;
  font-weight: 700;
  color: white;
  letter-spacing: 0.01em;
}

.app-title-subtitle {
  margin-top: 10px;
  font-family: Arial, sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  opacity: 0.9;
}

.title-icon {
  width: 60px;
  height: 60px;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.25));
}

.title-icon.left {
  margin-right: 2px;
}

.title-icon.right {
  margin-left: 2px;
}

/* ===== Podium classement ===== */

.ranking-podium {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 0;
  margin-bottom: 18px;
  position: relative;
}
.ranking-podium::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 10%;
  width: 80%;
  height: 6px;
  background: #e2e8f0;
  border-radius: 4px;
}
.podium-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 1;
}

.podium-first {
  order: 2;
  z-index: 3;
  transform: translateY(-4px);
}

.podium-second {
  order: 1;
  z-index: 2;
}

.podium-third {
  order: 3;
  z-index: 1;
}

.ranking-podium-animate .podium-column {
  opacity: 0;
  animation: podiumRise 0.5s ease forwards;
}

.ranking-podium-animate .podium-first {
  animation-delay: 0.25s;
}

.ranking-podium-animate .podium-second {
  animation-delay: 0.15s;
}

.ranking-podium-animate .podium-third {
  animation-delay: 0.05s;
}

.podium-avatar-wrap {
  margin-bottom: 4px;
}

.podium-card {
  width: 210px;
  border: 1px solid #e5e7eb;
  border-radius: 14px 14px 0 0;
  padding: 8px 10px 10px;
  text-align: center;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.podium-first .podium-card {
  height: 130px;
  background: linear-gradient(to bottom, rgba(245, 158, 11, 0.10), #ffffff);
  border-color: rgba(245, 158, 11, 0.35);
}

.podium-second .podium-card {
  height: 112px;
  background: linear-gradient(to bottom, rgba(148, 163, 184, 0.10), #ffffff);
  border-color: rgba(148, 163, 184, 0.35);
  margin-right: -1px;
}

.podium-third .podium-card {
  height: 96px;
  background: linear-gradient(to bottom, rgba(180, 83, 9, 0.08), #ffffff);
  border-color: rgba(180, 83, 9, 0.30);
  margin-left: -1px;
}

.podium-current-user .podium-card {
  outline: 2px solid rgba(29, 78, 216, 0.20);
  outline-offset: -2px;
}

.podium-medal {
  font-size: 1.45rem;
  line-height: 1;
  margin: 0;
}

.podium-player {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  font-size: 0.82rem;
  font-weight: 700;
  color: #0f172a;
  text-align: center;
  word-break: break-word;
  line-height: 1.15;
  margin: 0;
}

.podium-avatar {
  width: 48px !important;
  height: 48px !important;
  min-width: 48px;
  min-height: 48px;
  max-width: 48px;
  max-height: 48px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  border: 2px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 3px 8px rgba(15, 23, 42, 0.08);
  background: #f8fafc;
}

.podium-me-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(29, 78, 216, 0.10);
  color: #1d4ed8;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
  margin: 0;
}

.podium-points {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 10px;
  border-radius: 999px;
  background: #1d4ed8;
  color: white;
  font-weight: 700;
  font-size: 0.82rem;
  line-height: 1;
  margin-top: auto;
}
/* ===== Profil ===== */

.profile-section {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.profile-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}
.profile-avatar-wrapper {
  display: flex;
  justify-content: center;
}

.profile-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  border: 3px solid white;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.12);
}
.profile-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}
.profile-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.2rem;
}
.profile-badge {
  font-size: 0.8rem;
  background: #e2e8f0;
  padding: 3px 8px;
  border-radius: 999px;
  color: #475569;
}
.profile-upload-box {
  padding: 14px;
  border-radius: 12px;
  background: #f1f5f9;
  border: 1px dashed #cbd5f5;
}

.profile-upload-label {
  font-size: 0.9rem;
  color: #475569;
  margin-bottom: 6px;
  display: block;
}
.profile-avatar-upload {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.profile-readonly-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.profile-label {
  color: #64748b;
}

/* ===== Modale crop avatar ===== */

.avatar-crop-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
}

.avatar-crop-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
}

.avatar-crop-dialog {
  position: relative;
  z-index: 1;
  max-width: 760px;
  width: calc(100% - 24px);
  margin: 40px auto;
  background: white;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
}

.avatar-crop-dialog h3 {
  margin-top: 0;
  margin-bottom: 12px;
}

.avatar-crop-container {
  width: 100%;
  max-height: 65vh;
  overflow: hidden;
  background: #f8fafc;
  border-radius: 12px;
}

.avatar-crop-container img {
  display: block;
  max-width: 100%;
}

/* optionnel mais utile pour être sûr qu'aucun style global ne casse les avatars */
.avatar-crop-container img,
.ranking-avatar,
.podium-avatar,
.profile-avatar {
  max-width: none;
}

.avatar-crop-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
}

/* ===== Responsive ===== */

@media (max-width: 700px) {
  .ranking-podium {
    display: none;
  }

  .ranking-table-wrapper {
    display: none;
  }

  .ranking-mobile-list {
    display: block;
  }

.ranking-mobile-card {
  padding: 14px 14px 12px;
  margin-top: 12px;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  background: linear-gradient(to bottom, #ffffff, #f8fbff);
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}
.ranking-mobile-card {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.ranking-mobile-card:active {
  transform: scale(0.985);
}

.ranking-mobile-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.ranking-mobile-player {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.ranking-mobile-name-wrap {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.ranking-mobile-name {
  font-size: 1.02rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.15;
  word-break: break-word;
}

.ranking-mobile-points {
  flex-shrink: 0;
}

.ranking-mobile-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  align-items: stretch;
}

.ranking-mobile-stat {
  padding: 8px 4px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #eef2f7;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  min-height: 68px;
}

.ranking-mobile-label {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 2.5em;
  font-size: 0.7rem;
  line-height: 1.15;
  text-align: center;
  color: #64748b;
  letter-spacing: 0.02em;
}

.ranking-mobile-value {
  margin-top: 6px;
  font-size: 1.05rem;
  line-height: 1;
  font-weight: 800;
  color: #111827;
  font-variant-numeric: tabular-nums;
}

.ranking-points-pill {
  min-width: 68px;
  padding: 6px 12px;
  font-size: 0.9rem;
  border-radius: 999px;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.2);
}

.ranking-me-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(29, 78, 216, 0.10);
  color: #1d4ed8;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1;
}

.ranking-avatar {
  width: 34px !important;
  height: 34px !important;
  min-width: 34px;
  min-height: 34px;
  max-width: 34px;
  max-height: 34px;
  border: 2px solid #dbe3f0;
}

.ranking-avatar.ranking-avatar-mobile {
  width: 48px !important;
  height: 48px !important;
  min-width: 48px !important;
  min-height: 48px !important;
  max-width: 48px !important;
  max-height: 48px !important;
}

  .avatar-crop-dialog {
    margin: 16px auto;
    padding: 12px;
  }

  .avatar-crop-container {
    max-height: 55vh;
  }

  .avatar-crop-actions {
    justify-content: stretch;
  }

  .avatar-crop-actions button {
    flex: 1;
  }
}

@media (max-width: 700px) {
  .app-title {
    gap: 14px;
    margin-bottom: 16px;
  }

  .title-icon {
    width: 46px;
    height: 46px;
  }

  .app-title-main {
    font-size: 1.55rem;
  }

  .app-title-subtitle {
    font-size: 0.75rem;
    margin-top: 8px;
    letter-spacing: 0.05em;
  }
}

@media (max-width: 500px) {
  .app-title {
    gap: 10px;
  }

  .title-icon {
    width: 30px;
    height: 30px;
  }

  .app-title-main {
    font-size: 1.2rem;
    white-space: nowrap;
  }

  .app-title-subtitle {
    font-size: 0.54rem;
    margin-top: 6px;
    letter-spacing: 0.03em;
    white-space: nowrap;
  }
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 6px;
  width: 100%;
}

.profile-stat-card {
  padding: 12px;
  border-radius: 12px;
  background: white;
  border: 1px solid #e2e8f0;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);

  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;

  min-height: 78px;
  transition: all 0.15s ease;
}

.profile-stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.profile-stat-label {
  font-size: 0.8rem;
  color: #64748b;
  text-align: center;
  line-height: 1.2;
  min-height: 2.4em;
}

.profile-stat-value {
  font-size: 1.2rem;
  font-weight: 700;
  color: #0f172a;
  text-align: center;
}

@media (max-width: 700px) {
  .profile-header {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .profile-info {
    align-items: center;
    width: 100%;
  }

  .profile-name {
    justify-content: center;
    flex-wrap: wrap;
  }

	.profile-stats {
	  grid-template-columns: repeat(2, 1fr);
	}
}
.ranking-chart-card {
  margin-top: 16px;
  transition: all 0.2s ease;
  position: relative;
}

.ranking-chart-card h3 {
  margin-top: 0;
  margin-bottom: 12px;
}
.ranking-chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.ranking-chart-header h3 {
  margin: 0;
}

.ranking-chart-expand-btn {
  flex-shrink: 0;
}
#ranking-history-chart {
  width: 100%;
  max-height: 420px;
}
/* Important : quand le graphe est agrandi, on autorise le débordement horizontal */
.container.chart-expanded {
  overflow-x: visible;
}
/* Mode agrandi */
.ranking-chart-card.expanded {
  width: calc(100vw - 32px);
  max-width: 1400px;
  margin-left: 50%;
  transform: translateX(-50%);
  z-index: 20;
}

.ranking-chart-card.expanded .ranking-chart-wrapper {
  min-height: 720px;
}

.ranking-chart-card.expanded #ranking-history-chart {
  max-height: none;
  height: 680px !important;
}

@media (max-width: 900px) {
  .ranking-chart-card.expanded {
    width: calc(100vw - 20px);
  }

  .ranking-chart-card.expanded .ranking-chart-wrapper {
    min-height: 560px;
  }

  .ranking-chart-card.expanded #ranking-history-chart {
    height: 520px !important;
  }
}

@media (max-width: 700px) {
  #ranking-history-chart {
    max-height: 300px;
  }
}
.ranking-chart-wrapper {
  position: relative;
  min-height: 420px;
}

.ranking-chart-tooltip {
  position: absolute;
  z-index: 20;
  min-width: 220px;
  max-width: 280px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.96);
  color: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  pointer-events: none;
  font-size: 0.9rem;
}

.ranking-chart-tooltip[hidden] {
  display: none;
}

.ranking-chart-tooltip-title {
  font-weight: 700;
  margin-bottom: 2px;
}

.ranking-chart-tooltip-subtitle {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.78);
  margin-bottom: 10px;
}

.ranking-chart-tooltip-score {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 2px;
}

.ranking-chart-tooltip-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ranking-chart-tooltip-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ranking-chart-tooltip-player {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.ranking-chart-tooltip-avatar {
  width: 22px;
  height: 22px;
  min-width: 22px;
  min-height: 22px;
  max-width: 22px;
  max-height: 22px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.15);
}

.ranking-chart-tooltip-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
}

.ranking-chart-tooltip-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ranking-chart-tooltip-points {
  font-weight: 700;
  white-space: nowrap;
}

@media (max-width: 700px) {
  .ranking-chart-tooltip {
    display: none !important;
  }
}
@media (max-width: 700px) {
  .ranking-chart-card,
  #ranking-history-chart,
  .ranking-chart-wrapper,
  #ranking-chart-tooltip {
    display: none !important;
  }
}
.admin-match-points-table {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-match-points-header,
.admin-match-points-item {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 90px 90px 90px;
  gap: 10px;
  align-items: center;
}

.admin-match-points-header {
  padding: 0 6px 4px 6px;
  font-weight: 700;
  color: #334155;
  border-bottom: 1px solid #e5e7eb;
}

.admin-match-points-item {
  padding: 8px 6px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f8fafc;
}

.admin-match-match-cell {
  min-width: 0;
}

.admin-match-name {
  font-weight: 600;
  color: #0f172a;
  word-break: break-word;
}

.admin-match-date {
  font-size: 0.85rem;
  color: #64748b;
  margin-top: 2px;
}

.admin-match-points-input {
  width: 100%;
  margin-bottom: 0;
  text-align: center;
}

.admin-match-points-item.is-dirty {
  border-color: rgba(29, 78, 216, 0.35);
  box-shadow: 0 0 0 2px rgba(29, 78, 216, 0.08);
}

@media (max-width: 700px) {
  .admin-match-points-header {
    display: none;
  }

  .admin-match-points-table {
    gap: 12px;
  }

  .admin-match-points-item {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    padding: 12px;
    border-radius: 12px;
  }

  .admin-match-match-cell {
    grid-column: 1 / -1;
  }

  .admin-match-name {
    font-size: 0.98rem;
    line-height: 1.3;
  }

  .admin-match-date {
    font-size: 0.8rem;
  }

  .admin-match-points-item input {
    width: 100%;
    max-width: none;
    min-width: 0;
    text-align: center;
  }

  .admin-match-points-item::before {
    display: none;
  }

  .admin-match-points-item > input:nth-of-type(1) {
    grid-column: span 1;
  }

  .admin-match-points-item > input:nth-of-type(2) {
    grid-column: span 1;
  }

  .admin-match-points-item > input:nth-of-type(3) {
    grid-column: span 1;
  }

  .admin-match-points-item {
    position: relative;
  }

  .admin-match-points-item .admin-mobile-labels {
    display: none;
  }
}
.admin-match-mobile-field {
  display: contents;
}

.admin-match-mobile-label {
  display: none;
}
@media (max-width: 700px) {
  .admin-match-mobile-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .admin-match-mobile-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    color: #475569;
    text-align: center;
  }
}
.match-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.match-rules-info {
  position: relative;
  flex-shrink: 0;
}

.match-rules-trigger {
  width: 28px;
  height: 28px;
  min-width: 28px;
  padding: 0;
  border-radius: 50%;
  background: #e2e8f0;
  color: #334155;
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1;
}

.match-rules-trigger:hover {
  background: #cbd5e1;
}

.match-rules-tooltip {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 190px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.96);
  color: white;
  font-size: 0.85rem;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
  display: none;
  z-index: 20;
}

.match-rules-tooltip-title {
  font-weight: 700;
  margin-bottom: 6px;
}

.match-rules-info:hover .match-rules-tooltip,
.match-rules-info.is-open .match-rules-tooltip {
  display: block;
}

@media (max-width: 700px) {
  .match-title-row {
    align-items: center;
  }

  .match-rules-tooltip {
    left: auto;
    right: 0;
    min-width: 180px;
    max-width: min(220px, calc(100vw - 32px));
    white-space: normal;
  }
}
@keyframes podiumRise {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
body {
  background:
    radial-gradient(circle at 20% 20%, rgba(29,78,216,0.05), transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(22,163,74,0.05), transparent 40%),
    var(--bg-main);
}
.app-header {
  margin: -16px -16px 20px -16px; /* full width malgré le container */
  padding: 18px 16px;

	background: linear-gradient(
	  120deg,
	  rgba(29, 78, 216, 0.75),
	  rgba(37, 99, 235, 0.75),
	  rgba(220, 38, 38, 0.75),
	  rgba(22, 163, 74, 0.75)
	);

  border-bottom: 1px solid rgba(0,0,0,0.05);
}
@media (max-width: 700px) {
  .app-header {
    margin: -16px -16px 16px -16px;
    padding: 14px 12px;
  }
}
.whoami {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 0.95rem;
  color: #334155;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 14px;
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.whoami:hover {
  background: rgba(29, 78, 216, 0.08);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

.whoami:active {
  transform: scale(0.99);
}

.whoami-avatar {
  width: 68px;
  height: 68px;
  min-width: 68px;
  min-height: 68px;
  max-width: 68px;
  max-height: 68px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  display: block;
  flex-shrink: 0;
  border: 2px solid white;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
}

.whoami-text {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 1.05rem;
}
@media (max-width: 700px) {
  .topbar {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .whoami {
    width: 100%;
    min-width: 0;
    align-items: center;
  }

  .whoami-text {
    display: block;
    min-width: 0;
    font-size: 0.9rem;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }

	.whoami-avatar {
	  width: 54px;
	  height: 54px;
	  min-width: 54px;
	  min-height: 54px;
	  max-width: 54px;
	  max-height: 54px;
	}

  .topbar #btn-logout {
    display: none;
  }
}
/* ===== Cartes matchs à venir (nouveau design) ===== */

.match-upcoming-card {
  position: relative;
  padding: 14px 14px 12px;
  border: 1px solid #d9e2f2;
  border-radius: 16px;
  background: linear-gradient(to bottom, #ffffff, #f8fbff);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.match-upcoming-card .match-rules-info {
  position: absolute;
  top: 12px;
  right: 12px;
}

.match-upcoming-header {
  text-align: center;
  margin-bottom: 12px;
}

.match-upcoming-date {
  font-size: 1.05rem;
  font-weight: 800;
  color: #1e293b;
  line-height: 1.1;
}

.match-upcoming-time {
  margin-top: 2px;
  font-size: 0.95rem;
  font-weight: 600;
  color: #94a3b8;
  line-height: 1.1;
}

.match-upcoming-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  margin-bottom: 12px;
}

.match-upcoming-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-width: 0;
}

.match-upcoming-crest {
  width: 42px;
  height: 42px;
  object-fit: contain;
  margin-bottom: 8px;
}

.match-upcoming-team-name {
  font-size: 0.98rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.2;
  word-break: break-word;
}

.match-upcoming-vs {
  align-self: center;
  font-size: 1.1rem;
  font-weight: 800;
  color: #64748b;
  padding-top: 8px;
}

.match-upcoming-prediction-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  justify-items: center;
  gap: 10px;
  margin-top: 6px;
}
.match-upcoming-prediction-row input:first-child {
  justify-self: center;
}

.match-upcoming-prediction-row input:last-child {
  justify-self: center;
}

.match-upcoming-input {
  width: 52px;
  height: 46px;
  border-radius: 12px;
  border: 2px solid #1e293b;
  background: #ffffff;
  font-size: 1.05rem;
  font-weight: 700;
  text-align: center;
  box-shadow: none;
}

.match-upcoming-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.match-upcoming-input-separator {
  width: 12px;
  min-width: 12px;
}

.match-upcoming-edit-status {
  margin-top: 8px;
  text-align: center;
  min-height: 18px;
}

.match-upcoming-card .missing-prediction-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  margin: 0;
  padding: 4px 8px;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  z-index: 2;
}

.missing-prediction-badge-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.missing-prediction-badge-text {
  display: inline;
}

@media (max-width: 700px) {
  .match-upcoming-card .missing-prediction-badge {
    padding: 4px 6px;
    gap: 0;
    min-width: auto;
    min-height: auto;
  }

  .match-upcoming-card .missing-prediction-badge .missing-prediction-badge-text {
    display: none;
  }
}

.match-upcoming-card .hint {
  text-align: center;
}
@media (max-width: 700px) {
  .match-upcoming-card {
    padding: 12px 12px 10px;
    border-radius: 14px;
  }

  .match-upcoming-date {
    font-size: 1rem;
  }

  .match-upcoming-time {
    font-size: 0.9rem;
  }

  .match-upcoming-body {
    gap: 8px;
    margin-bottom: 10px;
  }

  .match-upcoming-crest {
    width: 36px;
    height: 36px;
    margin-bottom: 6px;
  }

  .match-upcoming-team-name {
    font-size: 0.92rem;
  }

  .match-upcoming-input {
    width: 48px;
    height: 42px;
    font-size: 1rem;
  }

  .match-upcoming-vs {
    font-size: 1rem;
    padding-top: 6px;
  }
}
/* ===== Cartes matchs en cours ===== */

.match-live-card {
  position: relative;
  padding: 14px 14px 12px;
  border: 1px solid #f1d7d7;
  border-radius: 16px;
  background: linear-gradient(to bottom, #ffffff, #fff8f8);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.match-live-card .match-rules-info {
  position: absolute;
  top: 12px;
  right: 12px;
}

.match-live-header {
  text-align: center;
  margin-bottom: 12px;
}

.match-live-date {
  font-size: 1.05rem;
  font-weight: 800;
  color: #1e293b;
  line-height: 1.1;
}

.match-live-time {
  margin-top: 2px;
  font-size: 0.95rem;
  font-weight: 600;
  color: #94a3b8;
  line-height: 1.1;
}

.match-live-body {
  display: grid;
  grid-template-columns: minmax(92px, 1fr) auto minmax(92px, 1fr);
  align-items: start;
  gap: 10px;
  margin-bottom: 12px;
}

.match-live-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-width: 0;
}

.match-live-crest {
  width: 42px;
  height: 42px;
  object-fit: contain;
  margin-bottom: 8px;
}

.match-live-team-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.18;
  text-align: center;

  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;

  overflow: hidden;
  text-overflow: ellipsis;

  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;

  min-height: 2.4em;
  max-width: 100%;
}

.match-live-score {
  margin-top: 10px;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  color: #dc2626;
}

.match-live-center {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  padding-top: 16px;
}

.match-live-card .my-prediction {
  margin-top: 0;
  font-size: 0.95rem;
  background: transparent;
  padding: 0;
  border-radius: 0;
}

.match-live-card .live-badge {
  background: #dc2626;
}

.match-live-card .prediction-best-badge {
  vertical-align: middle;
}
@media (max-width: 700px) {
  .match-live-card {
    padding: 12px 12px 10px;
    border-radius: 14px;
  }

	.match-live-body {
	  grid-template-columns: minmax(0, 1fr) 72px minmax(0, 1fr);
	  gap: 8px;
	  align-items: flex-start;
	}

  .match-live-team {
    min-width: 0;
	justify-content: flex-start;
  }

  .match-live-crest {
    width: 36px;
    height: 36px;
    margin-bottom: 6px;
  }
.match-live-team-name {
  font-size: 0.82rem;
  line-height: 1.15;

  word-break: normal;
  overflow-wrap: break-word;
  white-space: normal;
  hyphens: auto;

  text-align: center;
}
  .match-live-score {
    font-size: 1.7rem;
    margin-top: 8px;
  }

  .match-live-center {
    padding-top: 12px;
  }

  .match-live-card .my-prediction {
    font-size: 0.9rem;
    padding: 0;
  }
}
.match-live-card .other-predictions-toggle {
  font-size: 0.9rem;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 10px;
}
/* Réduction spécifique "Pronos des autres joueurs" en LIVE */
.match-live-card .toggle-button,
.match-live-card .other-predictions-toggle {
  font-size: 0.85rem;
  font-weight: 500;
  padding: 4px 6px;
  border-radius: 8px;
  background: transparent;
  color: #334155;
}

/* Le [+] moins dominant */
.match-live-card .toggle-button span,
.match-live-card .other-predictions-toggle span {
  font-weight: 600;
}
/* Corriger taille "Pronos des autres joueurs" en LIVE */
.match-live-card .predictions-collapsible summary {
  font-size: 0.78rem;
  font-weight: 500;
  color: #475569;
  padding: 6px 8px;
  gap: 6px;
}

.match-live-card .predictions-collapsible {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}
@media (max-width: 700px) {
  .match-live-card .match-rules-info {
    top: 8px;
    right: 8px;
  }

  .match-live-card .match-rules-trigger {
    width: 24px;
    height: 24px;
    min-width: 24px;
    font-size: 0.85rem;
  }

  .match-live-team-away {
    padding-right: 0;
  }
}
/* ===== Cartes matchs terminés ===== */

.match-finished-card {
  position: relative;
  border: 1px solid var(--border);
  background: var(--card-bg);
  border-radius: 10px;
  padding: 12px;
  transition: all 0.15s ease;
}

/* Barre verticale */
.match-finished-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 5px;
  border-radius: 4px;
  background: transparent;
}

/* 🎯 EXACT (vert léger) */
.match-finished-card.result-exact {
  background: linear-gradient(to right, rgba(22,163,74,0.08), #ffffff 40%);
}
.match-finished-card.result-exact::before {
  background: #16a34a;
}

/* 👍 BON VAINQUEUR (orange léger) */
.match-finished-card.result-winner {
  background: linear-gradient(to right, #fffbeb, #ffffff 40%);
}
.match-finished-card.result-winner::before {
  background: #f59e0b;
}

/* ❌ FAUX (rouge léger) */
.match-finished-card.result-wrong {
  background: linear-gradient(to right, #fef2f2, #ffffff 40%);
}
.match-finished-card.result-wrong::before {
  background: #dc2626;
}

/* Hover discret */
.match-finished-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
.match-finished-header {
  position: relative;
  min-height: 24px;
}

.match-finished-card .match-rules-info {
  position: absolute;
  top: 0;
  right: 0;
}

.match-finished-scoreboard {
  display: inline-flex;
  flex-direction: column;
  gap: 8px;
}

.match-finished-row {
  display: grid;
  grid-template-columns: auto 24px;
  align-items: center;
  gap: 8px;
}

.match-finished-team {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 0 1 auto;
}

.match-finished-crest {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
}

.match-finished-team-name {
  font-size: 0.98rem;
  font-weight: 700;
  color: #0f172a;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.match-finished-score {
  width: 22px;
  text-align: right;
  font-size: 1rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #334155;
}

.match-finished-card .my-prediction {
  margin-top: 12px;
  font-size: 0.95rem;
  background: transparent;
  padding: 0;
  border-radius: 0;
}

.match-finished-card .predictions-collapsible {
  margin-top: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
  padding: 10px;
}

.match-finished-card .predictions-collapsible summary {
  font-size: 0.85rem;
  font-weight: 500;
  color: #475569;
  gap: 6px;
}
@media (max-width: 700px) {
  .match-finished-card {
    padding: 10px 10px 9px;
    border-radius: 12px;
  }

  .match-finished-row {
    gap: 10px;
  }

  .match-finished-crest {
    width: 20px;
    height: 20px;
  }

  .match-finished-team-name {
    font-size: 0.92rem;
  }

  .match-finished-score {
	  width: 20px;
	  min-width: 20px;
	  text-align: right;
	  font-size: 0.92rem;
	  font-weight: 600;
	  font-variant-numeric: tabular-nums;
	  color: #334155;
	}

  .match-finished-card .my-prediction {
	  font-size: 0.9rem;
	  padding: 0;
	}

  .match-finished-card .predictions-collapsible summary {
    font-size: 0.8rem;
  }
}
.predictions-collapsible-compact summary::before {
  width: 30px;
  min-width: 30px;
  text-align: left;
}

.prediction-row-other::before {
  width: 30px;
  min-width: 30px;
  text-align: left;
}
.predictions-collapsible-compact summary {
  background: linear-gradient(to right, rgba(37, 99, 235, 0.06), transparent);
  border-radius: 8px;
  padding: 4px 6px;
}
/* ===== Questions bonus ===== */

.bonus-question-card {
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 14px;
  background: linear-gradient(to bottom, #ffffff, #fcfcff);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
  position: relative;
}

.bonus-missing-answer-badge {
  margin-top: 0;
  margin-bottom: 12px;
}

.bonus-question-card-missing {
  border-color: #fed7aa;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.08);
}

.bonus-question-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.bonus-question-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.3;
}

.bonus-question-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.bonus-pill {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  background: #eef2ff;
  color: #3730a3;
  font-size: 0.85rem;
  font-weight: 600;
}

.bonus-pill.locked {
  background: #fff7ed;
  color: #c2410c;
}

.bonus-pill.resolved {
  background: #ecfdf5;
  color: #15803d;
}

.bonus-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bonus-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f8fafc;
}

.bonus-option input {
  width: auto;
  margin: 0;
}

.bonus-question-actions {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bonus-answer-summary {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}

.bonus-answers-list {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bonus-answer-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #eef2f7;
}

.bonus-answer-player {
  font-weight: 600;
  color: #0f172a;
}

.bonus-answer-choice {
  color: #475569;
  text-align: right;
}

.admin-bonus-form textarea {
  width: 100%;
  padding: 10px;
  margin-bottom: 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 14px;
  resize: vertical;
}

.admin-bonus-item {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 10px;
  background: #f8fafc;
}

.admin-bonus-title {
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
}

.admin-bonus-options {
  font-size: 0.9rem;
  color: #475569;
  margin-bottom: 8px;
}

.admin-bonus-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

@media (max-width: 700px) {
	
.bonus-missing-answer-badge .missing-prediction-badge-text {
    display: inline;
  }
  .bonus-question-header,
  .bonus-answer-row {
    flex-direction: column;
  }

  .bonus-answer-choice {
    text-align: left;
  }
}
.bonus-select {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: white;
  font-size: 14px;
}
.bonus-option.is-selected {
  border-color: #2563eb;
  background: rgba(37, 99, 235, 0.08);
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.12);
}

.bonus-selected-choice {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e3a8a;
  font-size: 0.92rem;
  font-weight: 500;
}

.bonus-selected-choice strong {
  font-weight: 700;
}
.rank-position-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  font-weight: 800;
  font-size: 0.9rem;
  line-height: 1;
  background: #e2e8f0;
  color: #1e293b;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.04);
}

.rank-position-gold {
  background: linear-gradient(135deg, #facc15, #eab308);
  color: white;
}

.rank-position-silver {
  background: linear-gradient(135deg, #d1d5db, #9ca3af);
  color: white;
}

.rank-position-bronze {
  background: linear-gradient(135deg, #cd7f32, #8d5a2b);
  color: white;
}
.bonus-predictions-collapsible {
  margin-top: 12px;
}
.bonus-answer-summary + .bonus-predictions-collapsible {
  margin-top: 10px;
}

.bonus-predictions-collapsible summary {
  background: linear-gradient(to right, rgba(37, 99, 235, 0.06), transparent);
  border-radius: 8px;
  padding: 4px 6px;
}
@media (max-width: 700px) {
  .bonus-predictions-collapsible .predictions-summary-label,
  .bonus-predictions-collapsible .prediction-player,
  .bonus-predictions-collapsible .prediction-player-other {
    width: auto;
    min-width: 0;
    font-size: 0.84rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .bonus-predictions-collapsible .prediction-row-other::before,
  .bonus-predictions-collapsible.predictions-collapsible-compact summary::before {
    width: 20px;
    min-width: 20px;
  }

  .bonus-predictions-collapsible .prediction-score {
    width: auto;
    min-width: 0;
    max-width: 100%;
    height: 22px;
    padding: 0 8px;
    font-size: 0.82rem;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .bonus-predictions-collapsible .prediction-points {
    width: 54px;
    min-width: 54px;
    justify-content: flex-start;
    font-size: 0.74rem;
  }
  .bonus-predictions-collapsible .predictions-summary-label {
    font-size: 0.82rem;
  }
	.bonus-predictions-collapsible .prediction-score {
	  min-width: 44px;
	  width: fit-content;
	  max-width: max-content;
	  padding: 0 8px;
	  justify-self: start;
	}
}
/* ===== Alignement propre réponses bonus corrigées ===== */

.bonus-predictions-collapsible.predictions-collapsible-compact summary,
.bonus-prediction-row.prediction-row {
  display: grid;
  align-items: center;
  column-gap: 10px;
  grid-template-columns: 28px 120px max-content 70px;
}

.bonus-predictions-collapsible.predictions-collapsible-compact summary::before,
.bonus-prediction-row.prediction-row-other::before {
  width: 28px;
  min-width: 28px;
}

.bonus-predictions-collapsible .prediction-right-summary,
.bonus-predictions-collapsible .prediction-right {
  display: contents;
}

.bonus-predictions-collapsible .prediction-score {
  width: fit-content;
  min-width: 52px;
  max-width: max-content;
  justify-content: center;
  justify-self: start;
  padding: 0 10px;
}

.bonus-predictions-collapsible .prediction-points {
  width: 70px;
  min-width: 70px;
  justify-content: flex-start;
  justify-self: start;
}

@media (max-width: 700px) {
	.bonus-predictions-collapsible.predictions-collapsible-compact summary,
	.bonus-prediction-row.prediction-row {
	  grid-template-columns: 20px 90px max-content 54px;
	  column-gap: 6px;
	}

  .bonus-predictions-collapsible.predictions-collapsible-compact summary::before,
  .bonus-prediction-row.prediction-row-other::before {
    width: 20px;
    min-width: 20px;
  }

  .bonus-predictions-collapsible .prediction-score {
    min-width: 44px;
    padding: 0 8px;
  }

  .bonus-predictions-collapsible .prediction-points {
    width: 54px;
    min-width: 54px;
    font-size: 0.74rem;
  }
}
.bonus-predictions-collapsible .prediction-score {
  width: fit-content;
  min-width: 52px;
  max-width: max-content;
  justify-content: center;
  justify-self: start;
  padding: 0 10px;
}

.bonus-predictions-collapsible .prediction-points {
  width: 70px;
  min-width: 70px;
  justify-content: flex-start;
  justify-self: start;
  text-align: left;
}

@media (max-width: 700px) {
  .bonus-predictions-collapsible .prediction-score {
    min-width: 44px;
    padding: 0 8px;
  }

  .bonus-predictions-collapsible .prediction-points {
    width: 54px;
    min-width: 54px;
    font-size: 0.74rem;
    text-align: left;
  }
}
/* ===== Onglet Règles ===== */

.rules-intro {
  margin-top: 0;
  margin-bottom: 18px;
  padding: 12px 14px;
  border-radius: 12px;
  background: linear-gradient(to right, rgba(29, 78, 216, 0.08), rgba(22, 163, 74, 0.06));
  border: 1px solid #dbe7f5;
  color: #334155;
  font-size: 0.98rem;
  line-height: 1.5;
}

.rules-page-section + .rules-page-section {
  margin-top: 24px;
}

.rules-page-section h3 {
  margin-bottom: 10px;
  color: #0f172a;
}

.rules-page-list {
  margin: 0;
  padding-left: 20px;
  color: #334155;
  line-height: 1.6;
}

.rules-page-list li + li {
  margin-top: 6px;
}

.rules-table-wrapper {
  width: 100%;
  overflow-x: auto;
  margin-top: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: white;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.05);
}

.rules-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

.rules-table thead th {
  background: linear-gradient(to right, rgba(29, 78, 216, 0.08), rgba(22, 163, 74, 0.06));
  color: #0f172a;
  text-align: left;
  padding: 12px;
  font-size: 0.92rem;
  border-bottom: 1px solid #e5e7eb;
}

.rules-table tbody td {
  padding: 12px;
  border-top: 1px solid #eef2f7;
  color: #334155;
  vertical-align: middle;
}

.rules-table tbody tr:nth-child(even) {
  background: #fcfdff;
}

.rules-table tbody tr:hover {
  background: #f8fbff;
}

.rules-points-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  padding: 5px 10px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1;
  white-space: nowrap;
}

.rules-points-exact {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
}

.rules-points-winner {
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.rules-points-wrong {
  background: rgba(220, 38, 38, 0.10);
  color: #b91c1c;
}
.ranking-chart-toolbar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.ranking-chart-filter {
  background: #e2e8f0;
  color: #1e293b;
  font-weight: 700;
}

.ranking-chart-filter.active {
  background: #2563eb;
  color: white;
}
@media (max-width: 700px) {
  .ranking-mobile-card-v2 {
    padding: 12px;
    border-radius: 16px;
    background: linear-gradient(to bottom, #ffffff, #f8f8f8);
    border: 1px solid #d6d6d6;
    box-shadow: 0 3px 10px rgba(15, 23, 42, 0.08);
  }

  .ranking-mobile-card-v2 .ranking-mobile-top {
    align-items: center;
    margin-bottom: 12px;
  }

  .ranking-mobile-card-v2 .ranking-mobile-player {
    gap: 10px;
    min-width: 0;
  }

  .ranking-mobile-card-v2 .ranking-mobile-name {
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.1;
  }

  .ranking-mobile-card-v2 .ranking-mobile-position .rank-position-circle {
    width: 34px;
    height: 34px;
    min-width: 34px;
    font-size: 0.95rem;
  }

  .ranking-mobile-card-v2 .ranking-avatar.ranking-avatar-mobile {
    width: 46px !important;
    height: 46px !important;
    min-width: 46px !important;
    min-height: 46px !important;
    max-width: 46px !important;
    max-height: 46px !important;
    border: 2px solid #dbe3f0;
  }

  .ranking-mobile-card-v2 .ranking-points-pill {
    min-width: 78px;
    padding: 8px 14px;
    font-size: 0.95rem;
    font-weight: 800;
    border-radius: 999px;
  }

	.ranking-mobile-stats-single {
	  display: grid;
	  grid-template-columns: repeat(5, 1fr);
	  gap: 4px;
	  padding: 8px;
	  border-radius: 14px;
	  background: #f1f5f9;
	  border: 1px solid #e2e8f0;
	  align-items: stretch;
	}

	.ranking-mobile-card-v2 .ranking-mobile-stat {
	  width: 100%;
	  min-width: 0;
	  min-height: 78px;
	  padding: 8px 2px;
	  border-radius: 12px;
	  background: transparent;
	  border: none;
	  box-shadow: none;
	  display: grid;
	  grid-template-rows: 2.6em 34px;
	  justify-items: center;
	  align-items: start;
	  row-gap: 8px;
	  text-align: center;
	}

	.ranking-mobile-card-v2 .ranking-mobile-label {
	  width: 100%;
	  min-height: 0;
	  font-size: 0.72rem;
	  line-height: 1.15;
	  color: #444;
	  display: flex;
	  align-items: flex-start;
	  justify-content: center;
	  text-align: center;
	}

	.ranking-mobile-card-v2 .ranking-mobile-value {
	  width: 34px;
	  height: 34px;
	  min-width: 34px;
	  min-height: 34px;
	  border-radius: 999px;
	  display: flex;
	  align-items: center;
	  justify-content: center;
	  justify-self: center;
	  font-weight: 800;
	  font-size: 1.05rem;
	  background: #e2e8f0;
	  font-variant-numeric: tabular-nums;
	}

  .ranking-mobile-stat-exact .ranking-mobile-value {
    background: #dcfce7;
    color: #16a34a;
  }

  .ranking-mobile-stat-winner .ranking-mobile-value {
    background: #fef3c7;
    color: #d97706;
  }

  .ranking-mobile-stat-wrong .ranking-mobile-value {
    background: #fee2e2;
    color: #dc2626;
  }

  .ranking-mobile-stat-match .ranking-mobile-value,
  .ranking-mobile-stat-bonus .ranking-mobile-value {
    background: #dbeafe;
    color: #1d4ed8;
  }

  .ranking-mobile-card-v2 .ranking-me-badge {
    margin-top: 4px;
  }
}
.rules-cards-mobile {
  display: none;
}

.rules-card-mobile {
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: white;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
  padding: 12px;
}

.rules-card-mobile + .rules-card-mobile {
  margin-top: 12px;
}

.rules-card-mobile-title {
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 10px;
  font-size: 0.98rem;
}

.rules-card-mobile-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
}

.rules-card-mobile-row + .rules-card-mobile-row {
  border-top: 1px solid #eef2f7;
}

.rules-card-mobile-row span:first-child {
  color: #334155;
  font-size: 0.92rem;
}

@media (max-width: 700px) {
  .rules-table-wrapper {
    display: none;
  }

  .rules-cards-mobile {
    display: block;
    margin-top: 10px;
  }
}
.bonus-question-card {
  position: relative;
}

/* Barre verticale */
.bonus-question-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 5px;
  border-radius: 4px;
  background: transparent;
}

/* Question bonus terminée - bonne réponse */
.bonus-question-card.bonus-result-correct {
  background: linear-gradient(to right, #f0fdf4, #ffffff 40%);
}

.bonus-question-card.bonus-result-correct::before {
  background: #16a34a;
}

/* Question bonus terminée - mauvaise réponse */
.bonus-question-card.bonus-result-wrong {
  background: linear-gradient(to right, #fef2f2, #ffffff 40%);
}

.bonus-question-card.bonus-result-wrong::before {
  background: #dc2626;
}
#tab-admin .sub-collapsible + .sub-collapsible {
  margin-top: 14px;
}

#tab-admin .section-content .sub-collapsible {
  margin-top: 10px;
}
.sub-admin summary {
  background: linear-gradient(
    to right,
    rgba(29, 78, 216, 0.08),
    rgba(29, 78, 216, 0.03)
  );
}
@keyframes liveCardFlash {
  0% {
    box-shadow: 0 0 0 rgba(220, 38, 38, 0);
    transform: scale(1);
  }
  30% {
    box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.14);
    transform: scale(1.008);
  }
  100% {
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
    transform: scale(1);
  }
}

@keyframes liveScoreBump {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  35% {
    transform: scale(1.16);
    opacity: 0.9;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.match-live-card.score-just-updated {
  animation: liveCardFlash 0.8s ease;
}

.match-live-score.score-bump {
  animation: liveScoreBump 0.55s ease;
}
@keyframes rankingRowFlash {
  0% {
    background-color: rgba(37, 99, 235, 0);
  }
  35% {
    background-color: rgba(37, 99, 235, 0.08);
  }
  100% {
    background-color: transparent;
  }
}

.ranking-row-updated {
  animation: rankingRowFlash 1.1s ease;
}
.ranking-col-position {
  width: 92px;
}

.ranking-col-player {
  width: 220px;
}

.ranking-col-predictions {
  width: 90px;
}

.ranking-player-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.ranking-player-main {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex-wrap: nowrap;
  flex: 1;
}

.ranking-player-name {
  font-weight: 700;
  color: #0f172a;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-rank-wrap,
.ranking-points-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.ranking-change-slot {
  min-height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ranking-change-slot-rank {
  min-height: 20px;
}

.ranking-change-slot-points {
  min-height: 22px;
}

.ranking-change-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  border: 1px solid transparent;
}
.ranking-change-badge.animate {
  animation: rankingBadgePop 0.35s ease;
}

.ranking-change-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.ranking-change-text {
  line-height: 1;
}

.ranking-change-badge-rank {
  font-size: 0.68rem;
  padding: 2px 7px;
  opacity: 0.92;
}

.ranking-change-badge-points {
  font-size: 0.74rem;
  padding: 4px 9px;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.08);
}

.ranking-change-badge.positive {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
  border-color: rgba(22, 163, 74, 0.18);
}

.ranking-change-badge.negative {
  background: rgba(220, 38, 38, 0.12);
  color: #b91c1c;
  border-color: rgba(220, 38, 38, 0.18);
}

.ranking-change-badge-points.positive {
  background: linear-gradient(to right, rgba(22, 163, 74, 0.16), rgba(22, 163, 74, 0.08));
}

.ranking-change-badge-points.negative {
  background: linear-gradient(to right, rgba(220, 38, 38, 0.16), rgba(220, 38, 38, 0.08));
}

.ranking-mobile-name-wrap,
.ranking-mobile-points {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.ranking-mobile-name-wrap .ranking-change-slot,
.ranking-mobile-points .ranking-change-slot {
  justify-content: flex-start;
}

.ranking-mobile-points {
  align-items: flex-end;
}

@keyframes rankingBadgePop {
  0% {
    opacity: 0;
    transform: translateY(4px) scale(0.92);
  }
  70% {
    opacity: 1;
    transform: translateY(0) scale(1.04);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 700px) {
  .ranking-change-slot {
    min-height: 18px;
  }

  .ranking-change-badge-rank {
    font-size: 0.64rem;
    padding: 2px 6px;
  }

  .ranking-change-badge-points {
    font-size: 0.68rem;
    padding: 3px 7px;
  }
}
.live-goal-ticker {
  margin: -8px -16px 14px -16px;
  padding: 8px 0;
  background: linear-gradient(to right, rgba(220, 38, 38, 0.10), rgba(255, 255, 255, 0.96), rgba(220, 38, 38, 0.10));
  border-top: 1px solid rgba(220, 38, 38, 0.12);
  border-bottom: 1px solid rgba(220, 38, 38, 0.12);
  overflow: hidden;
}

.live-goal-ticker-track {
  display: block;
  width: 100%;
  overflow: hidden;
}
.live-goal-ticker-text {
  display: inline-block;
  white-space: nowrap;
  font-size: 0.98rem;
  font-weight: 800;
  color: #991b1b;
  padding-left: 100%;
  will-change: transform;
}

.live-goal-score-highlight {
  color: #dc2626;
  font-weight: 900;
  animation: goalScorePop 0.35s ease;
}

@keyframes goalScorePop {
  0% {
    transform: scale(0.8);
    opacity: 0.6;
  }
  70% {
    transform: scale(1.15);
    opacity: 1;
  }
  100% {
    transform: scale(1);
  }
}
.live-goal-ticker-text.ticker-reset {
  animation: liveGoalTickerScroll 17s linear infinite;
}

@keyframes liveGoalTickerScroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-100% - 70vw));
  }
}

@media (max-width: 700px) {
	.live-goal-ticker {
	margin: -6px -16px 12px -16px;
	padding: 7px 0;
	}
	.live-goal-ticker-text {
	  font-size: 0.88rem;
	}

	.live-goal-ticker-text.ticker-reset {
	  animation-duration: 9s;
	}
}
.match-upcoming-status {
  margin-bottom: 10px;
  text-align: center;
  font-size: 0.92rem;
  font-weight: 700;
}

.match-upcoming-status.waiting-kickoff {
  color: #b45309;
}

.match-upcoming-input-waiting {
  background: #f3f4f6;
  border-color: #d1d5db;
  color: #6b7280;
  cursor: not-allowed;
  opacity: 0.9;
}

.match-upcoming-input-waiting:focus {
  outline: none;
  box-shadow: none;
  border-color: #d1d5db;
}
.ticker-icon {
  width: 16px;
  height: 16px;
  vertical-align: -2px; /* ajuste si besoin */
  margin-right: 6px;
}