.path-spiel .native-match-page {
  padding-block-start: 3.5rem;
}

@media (max-width: 47.999rem) {
  .top-bar .top-bar__content:has(> .top-bar__tools:empty) {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .top-bar .top-bar__tools:empty {
    display: none;
  }

  .top-bar .top-bar__context {
    min-width: 0;
  }
}

@media (min-width: 48rem) {
  .path-spiel .native-match-page {
    padding-block-start: 4.5rem;
  }
}

/* Native match statistics keep Drupal's accessible table and form markup. */
.path-matches #main-content:has(.match-stats-page) {
  min-height: 70vh;
  background: var(--color-adesso-gray-10, #f3f2f1);
}

.path-matches #main-content:has(.match-stats-page) .nebula-native-title {
  padding: 5.5rem max(1.25rem, calc((100vw - 80rem) / 2)) 2.5rem;
  background: var(--color-club-stage, #006ec7);
  color: #fff;
}

.path-matches #main-content:has(.match-stats-page) .nebula-native-title h1 {
  margin: 0;
  font-family: var(--font-primary, "Klavika", "Fira Sans", sans-serif);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
}

.path-matches .match-stats-page {
  display: grid;
  gap: 1.5rem;
  max-width: 82.5rem;
  margin-inline: auto;
  padding: 2rem 1.25rem 4rem;
  color: var(--color-club-canvas, #1a1a1a);
  font-family: var(--font-secondary, "Fira Sans", sans-serif);
}

.path-matches .match-stats-page__filters {
  display: grid;
  gap: 1rem;
  align-items: end;
  padding: 1.5rem;
  border-top: 0.25rem solid var(--color-club-accent, #c8b600);
  background: #fff;
}

.path-matches .match-stats-page__filter {
  display: grid;
  gap: 0.5rem;
  min-width: 0;
  font-size: 0.875rem;
  font-weight: 700;
}

.path-matches .match-stats-page__filter select,
.path-matches .match-stats-page__filters button {
  width: 100%;
  min-height: 2.75rem;
  border: 1px solid var(--color-club-border, #e8e4e1);
  border-radius: 0;
  font: inherit;
}

.path-matches .match-stats-page__filter select {
  padding-inline: 0.75rem;
  background: #fff;
  color: inherit;
}

.path-matches .match-stats-page__filters button {
  padding-inline: 1rem;
  border-color: var(--color-club-primary, #006ec7);
  background: var(--color-club-primary, #006ec7);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.path-matches .match-stats-page__filters button:hover {
  background: var(--color-club-primary-hover, #005ba3);
}

.path-matches .match-stats-page__filters :is(select, button):focus-visible,
.path-matches .match-stats-page__form a:focus-visible {
  outline: 3px solid var(--color-club-accent, #c8b600);
  outline-offset: 3px;
}

.path-matches .match-stats-page__summary,
.path-matches .match-stats-page__form,
.path-matches .match-stats-page__scorers,
.path-matches .match-stats-page__empty {
  width: 100%;
  margin: 0;
  padding: 1.5rem;
  background: #fff;
}

.path-matches .match-stats-page__summary,
.path-matches .match-stats-page__scorers table {
  border-collapse: collapse;
}

.path-matches .match-stats-page__summary caption,
.path-matches .match-stats-page h2 {
  margin: 0 0 1rem;
  color: var(--color-club-primary, #006ec7);
  font-family: var(--font-primary, "Klavika", "Fira Sans", sans-serif);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.1;
  text-align: start;
  text-transform: uppercase;
}

.path-matches .match-stats-page__summary :is(th, td),
.path-matches .match-stats-page__scorers :is(th, td) {
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--color-club-border, #e8e4e1);
  text-align: start;
}

.path-matches .match-stats-page__summary :is(th, td) {
  padding-inline: 1.25rem;
}

.path-matches .match-stats-page__summary td,
.path-matches .match-stats-page__scorers td:last-child,
.path-matches .match-stats-page__scorers th:last-child {
  text-align: end;
  font-weight: 700;
}

.path-matches .match-stats-page__scorers table {
  width: 100%;
}

.path-matches .match-stats-page__form-list {
  display: grid;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.path-matches .match-stats-page__form-item a {
  display: grid;
  grid-template-columns: 2rem 3.5rem minmax(0, 1fr);
  gap: 0.5rem;
  align-items: center;
  padding: 0.75rem;
  background: var(--color-club-surface-secondary, #f0edeb);
  color: inherit;
  text-decoration: none;
}

.path-matches .match-stats-page__form-item a:hover {
  color: var(--color-club-primary, #006ec7);
}

.path-matches .match-stats-page__form-label {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  background: var(--color-club-primary, #006ec7);
  color: #fff;
  font-weight: 700;
}

.path-matches .match-stats-page__form-result {
  font-weight: 700;
}

.path-matches .match-stats-page__form-opponent {
  min-width: 0;
}

.path-matches .match-stats-page__form-date {
  grid-column: 3;
  color: var(--color-club-muted, #6f655f);
  font-size: 0.875rem;
}

@media (min-width: 48rem) {
  .path-matches #main-content:has(.match-stats-page) .nebula-native-title {
    padding-block-start: 7rem;
    padding-block-end: 3.5rem;
  }

  .path-matches .match-stats-page {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding-block: 3rem 6rem;
  }

  .path-matches .match-stats-page__filters {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr)) auto;
  }

  .path-matches .match-stats-page__filters button {
    width: auto;
  }

  .path-matches .match-stats-page__scorers {
    grid-column: 1 / -1;
  }
}

/* The public Drupal standings route uses a semantic table outside Canvas. */
.path-matches #main-content:has(.standings-table) {
  min-height: 70vh;
  background: var(--color-adesso-gray-10, #f3f2f1);
}

.path-matches .standings-table__hero {
  padding: 5.5rem max(1.25rem, calc((100vw - 80rem) / 2)) 2.5rem;
  background: var(--color-club-stage, #006ec7);
  color: #fff;
}

.path-matches .standings-table__hero h1 {
  margin: 0;
  font-family: var(--font-primary, "Klavika", "Fira Sans", sans-serif);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
}

.path-matches .standings-table__hero p {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.25rem 0 0;
  font-weight: 700;
}

.path-matches .standings-table__content {
  max-width: 82.5rem;
  margin-inline: auto;
  padding: 2rem 1.25rem 4rem;
}

.path-matches .standings-table__scroll {
  max-width: 100%;
  overflow-x: auto;
  background: #fff;
}

.path-matches .standings-table__scroll:focus-visible {
  outline: 3px solid var(--color-club-accent, #c8b600);
  outline-offset: 3px;
}

.path-matches .standings-table table {
  width: 100%;
  min-width: 58rem;
  border-collapse: collapse;
  font-family: var(--font-secondary, "Fira Sans", sans-serif);
  text-align: start;
}

.path-matches .standings-table :is(th, td) {
  padding: 1rem 0.75rem;
  border-bottom: 1px solid var(--color-club-border, #e8e4e1);
  white-space: nowrap;
}

.path-matches .standings-table th {
  background: var(--color-club-stage, #006ec7);
  color: #fff;
  font-size: 0.8125rem;
  text-align: start;
  text-transform: uppercase;
}

.path-matches .standings-table tbody tr:nth-child(even) {
  background: var(--color-adesso-gray-10, #f3f2f1);
}

.path-matches .standings-table tbody tr.standings-table__row--active-club {
  background: var(--color-club-primary-soft, #f0edeb);
  font-weight: 700;
}

.path-matches .standings-table__row--active-club td:first-child {
  box-shadow: inset 4px 0 0 var(--color-club-primary, #006ec7);
}

.path-matches .standings-table td:last-child {
  font-weight: 700;
}

.path-matches .standings-table__empty {
  margin: 0;
  padding: 1.5rem;
  background: #fff;
}

@media (min-width: 48rem) {
  .path-matches .standings-table__hero {
    padding-block-start: 7rem;
    padding-block-end: 3.5rem;
  }

  .path-matches .standings-table__content {
    padding-block: 3rem 6rem;
  }
}

/* Core account routes need Drupal's page title and message regions. */
.path-user #main-content {
  min-height: 70vh;
  background: var(--color-adesso-gray-10, #f3f2f1);
}

.path-user .nebula-native-title {
  padding: 5.5rem max(1.25rem, calc((100vw - 80rem) / 2)) 2.5rem;
  background: var(--color-club-stage, #006ec7);
  color: #fff;
}

.path-user .nebula-native-title h1 {
  margin: 0;
  font-family: var(--font-primary, "Klavika", "Fira Sans", sans-serif);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1;
}

.path-user .nebula-native-content {
  max-width: 82.5rem;
  margin-inline: auto;
  padding: 2rem 1.25rem 4rem;
}

.path-user .nebula-native-content .region-content {
  padding: 1.5rem;
  background: #fff;
}

@media (min-width: 48rem) {
  .path-user .nebula-native-title {
    padding-block-start: 7rem;
    padding-block-end: 3.5rem;
  }

  .path-user .nebula-native-content {
    padding-block: 3rem 6rem;
  }
}
