.main-content .soccer-stats-teams-page {
  margin-top: 4.3rem;
}

.main-content .soccer-stats-teams-page .heading-and-dropdown-container h2 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 3.25rem;
  margin-bottom: 1.15rem;
  font-size: 1.25rem;
  line-height: 2.0625rem;
}

.main-content .soccer-stats-teams-page .heading-and-dropdown-container h2 .team-flag {
  width: 2rem;
  height: 2rem;
  object-fit: contain;
}

/* Teams grid - ESPN-inspired card layout */
.teams-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0 2.5rem;
}

@media (min-width: 576px) {
  .teams-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  }
}

@media (min-width: 992px) {
  .teams-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
}

/* Team card */
.team-card {
  border-radius: 0.5rem;
  background-color: var(--white-gray-bkg, #fff);
  border: 1px solid var(--light-gray-border, #efefef);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  overflow: hidden;
}

.team-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.team-card-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem 1rem 1rem;
  text-decoration: none;
  color: var(--text-white, #040504);
  gap: 0.75rem;
}

.team-card-crest {
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.team-card-crest img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.team-card-name {
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: center;
  margin: 0;
  line-height: 1.3;
  color: var(--text-white, #040504);
}

.team-card-cta {
  font-size: 0.7rem;
  color: #149688;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.team-card a.team-card-link:hover .team-card-name {
  color: #149688;
}

/* No data message */
.no-data-message {
  text-align: center;
  padding: 2rem;
  color: var(--light-white, #9a9999);
  font-style: italic;
}

/* Dark mode */
body.dark .team-card {
  background-color: var(--white-gray-bkg, #040504);
  border-color: var(--light-gray-border, #2a2a2d);
}

body.dark .team-card-name {
  color: var(--text-white, #dedada);
}

body.dark .team-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}
