/* Self-contained group card component. */
.match-panel .panel-toolbar {
  grid-template-columns: 1fr;
  align-items: start;
}

.match-panel .group-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 24px;
  width: 100%;
  max-width: 100%;
  align-items: stretch;
  overflow: visible;
}

.match-panel .group-tabs .group-card {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 220px;
  max-height: 235px;
  flex-direction: column;
  justify-content: flex-start;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: 22px;
  box-sizing: border-box;
  background:
    radial-gradient(circle at 88% 4%, rgba(105, 168, 255, 0.15), transparent 42%),
    linear-gradient(145deg, #172635, #101b27);
  color: #f7fbff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 16px 32px rgba(6, 13, 21, 0.24);
  text-align: left;
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.match-panel .group-tabs .group-card:hover,
.match-panel .group-tabs .group-card:focus-visible {
  border-color: rgba(255, 255, 255, 0.2);
  outline: none;
  transform: translateY(-3px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 20px 38px rgba(6, 13, 21, 0.3);
}

.group-card__top {
  display: flex;
  width: 100%;
  align-items: flex-start;
  justify-content: flex-start;
  margin-bottom: 20px;
}

.match-panel .group-tabs .group-card__title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  color: #f7fbff;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.1;
  white-space: nowrap;
}

.group-card__flags {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
  max-width: 100%;
  margin-top: 0;
  align-items: stretch;
  justify-content: center;
  justify-items: stretch;
}

.group-card__flag {
  display: block;
  width: 100%;
  height: 50px;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 16px rgba(3, 9, 16, 0.24);
}

.group-card__flag img {
  display: block;
  width: 100%;
  height: 50px;
  max-width: none;
  object-fit: cover;
}

.group-card__flag span {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  font-size: 1.4rem;
}

.match-panel .group-tabs .group-card--active,
.match-panel .group-tabs .group-card.is-active {
  border-color: #5cff65;
  background:
    radial-gradient(circle at 88% 5%, rgba(92, 255, 101, 0.2), transparent 44%),
    linear-gradient(145deg, #101f2b, #0b1620);
  box-shadow:
    inset 0 0 0 1px rgba(92, 255, 101, 0.12),
    0 0 24px rgba(92, 255, 101, 0.25),
    0 18px 34px rgba(5, 13, 21, 0.32);
}

@media (max-width: 980px) {
  .match-panel .group-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 560px) {
  .match-panel .group-tabs {
    grid-template-columns: 1fr !important;
  }
}
