.desktop-only {
  display: table;
}

.scroll-layout {
  display: none;
}

.group-tabs {
  margin-top: 130px;
  display: flex;
  gap: 10px;
  position: relative;
}

.tab-btn {
  /* border: 1px solid white; */
  color: white;
  background: rgba(0, 0, 0, 0.5);
  padding: 8px 16px;
  cursor: pointer;
  font-size: 14px;
  margin: 3px;
  border-radius: 6px;
  transition: background 0.3s, color 0.3s, transform 0.1s;
  white-space: nowrap;
  width: 80px;
  text-align: center;
  box-sizing: content-box;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.1);
}

.tab-btn:hover {
  /* background: rgba(255, 255, 255, 0.12); */
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
}

.tab-btn.active {
  background: rgb(255, 255, 255);
  color: black;
  font-weight: bold;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
}

.tab-content {
  margin-top: 20px;
}

.hidden {
  display: none;
}

.standings-wrapper {
  padding: 20px 10px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 12px;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.2);
  color: white;
  margin: 20px auto;
  max-width: 80%;
}

#teamTitle {
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 20px;
  color: #ffffff;
  font-weight: bold;
}

.standings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  color: white;
}

.standings-table td:first-child {
  text-align: left;
}

.standings-table tr th {
  font-size: 18px;
}

.standings-table th,
.standings-table td {
  padding: 10px 8px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 14px;
}

.standings-table tbody td:first-child {
  position: relative;
}

/* Add green bar under place numbers 1 and 2 */
.standings-table tbody tr:nth-child(1) td:first-child::after,
.standings-table tbody tr:nth-child(2) td:first-child::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 3px;
  /* adjust to match number position */
  width: 18px;
  height: 5px;
  background-color: #00ff00;
  border-radius: 15px;
}

.standings-table thead {
  background-color: rgba(255, 255, 255, 0.15);
}

.standings-table tbody tr:nth-child(even) {
  background-color: rgba(255, 255, 255, 0.05);
}

.standings-table tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.group-standings-header h2 {
  color: white;
  margin-top: 10px;
  padding: 0 20px 20px;
  font-size: 30px;
  text-align: center;
  margin-bottom: 5px;
  padding: 40px;
}

#backBtn {
  color: white;
  background: #1d1d1d;
  padding: 6px 3px;
  cursor: pointer;
  font-size: 14px;
  border-radius: 6px;
  transition: background 0.3s, color 0.3s, transform 0.1s;
  white-space: nowrap;
  width: 80px;
  text-align: center;
  box-sizing: content-box;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
  position: fixed;
  margin-left: 3px;
}

#backBtn:hover {
  background: black;
}

#backBtn:active {
  transform: scale(0.96);
}

.backButtn {
  color: white;
  background: #1d1d1d;
  padding: 6px 3px;
  cursor: pointer;
  font-size: 14px;
  border-radius: 6px;
  transition: background 0.3s, color 0.3s, transform 0.1s;
  white-space: nowrap;
  width: 80px;
  text-align: center;
  box-sizing: content-box;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
  position: fixed;
}

.backButtn:hover {
  background: black;
}

.backButtn:active {
  transform: scale(0.96);
}

#nationalBackBtn {
  color: white;
  background: #1d1d1d;
  padding: 6px 3px;
  cursor: pointer;
  font-size: 14px;
  border-radius: 6px;
  transition: background 0.3s, color 0.3s, transform 0.1s;
  white-space: nowrap;
  width: 80px;
  text-align: center;
  box-sizing: content-box;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
  position: fixed;
  margin-left: 3px;
}

#nationalBackBtn:hover {
  background: black;
}

#nationalBackBtn:active {
  transform: scale(0.96);
}



@media (max-width: 600px) {

  .group-tabs {
    margin-top: 60px;
    display: flex;
    gap: 10px;
    position: fixed;
  }

  .group-standings-header h2 {
    color: white;
    margin-top: 130px;
    font-size: 30px;
    text-align: center;
    margin-bottom: 5px;
    padding: 10px;
  }

  #backBtn {
    color: white;
    background: #1d1d1d;
    padding: 6px 3px;
    cursor: pointer;
    font-size: 12px;
    border-radius: 6px;
    transition: background 0.3s, color 0.3s, transform 0.1s;
    white-space: nowrap;
    width: 60px;
    text-align: center;
    box-sizing: content-box;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
    position: fixed;
  }

  .backButtn {
    color: white;
    background: #1d1d1d;
    padding: 6px 3px;
    cursor: pointer;
    font-size: 12px;
    border-radius: 6px;
    transition: background 0.3s, color 0.3s, transform 0.1s;
    white-space: nowrap;
    width: 60px;
    text-align: center;
    box-sizing: content-box;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
    position: fixed;
    margin-left: -15px;
  }

  #nationalBackBtn {
    color: white;
    background: #1d1d1d;
    padding: 6px 3px;
    cursor: pointer;
    font-size: 12px;
    border-radius: 6px;
    transition: background 0.3s, color 0.3s, transform 0.1s;
    white-space: nowrap;
    width: 60px;
    text-align: center;
    box-sizing: content-box;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
    position: fixed;
  }

  .standings-wrapper {
    padding: 20px 10px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 12px;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.2);
    color: white;
    margin: 20px auto;
    max-width: 100%;
  }

  .desktop-only {
    display: none;
  }

  .mobile-standings-container {
    margin-top: 12px;
  }

  .scroll-layout {
    display: flex;
  }

  .fixed-clubs {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .club-header {
    font-size: 14px;
    font-weight: bold;
    color: white;
    padding: 3.5px 2px;
    white-space: nowrap;
  }

  .club-name {
    font-size: 12px;
    width: 170px;
    font-weight: bold;
    color: white;
    padding: 3.8px 3%;
    white-space: nowrap;
  }

  .stats-scroll-wrapper {
    overflow-x: auto;
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding-left: 10px;
    scrollbar-width: thin;
  }

  .stats-scroll-wrapper::-webkit-scrollbar {
    height: 4px;
  }

  .stats-scroll-wrapper::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 2px;
  }

  .stats-scroll-row {
    display: flex;
    gap: 8px;
  }

  .stat-head,
  .stat-cell {
    min-width: 30px;
    text-align: center;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    padding: 4px 6px;
    border-radius: 4px;
    font-size: 13px;
  }

  .header-row {
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    font-weight: bold;
  }

  .club-name:nth-child(2),
  .club-name:nth-child(3) {
    position: relative;
  }

  .club-name:nth-child(2)::after,
  .club-name:nth-child(3)::after {
    content: '';
    position: absolute;
    bottom: 0.5px;
    left: 2px;
    /* adjust to position under number */
    width: 13px;
    height: 3px;
    background-color: #00ff00;
    border-radius: 2px;
  }


}