.top-nav-item.is-active {
  color: var(--blue);
}

.match-center-page {
  display: grid;
  align-content: start;
  gap: 0;
  min-height: calc(100vh - 56px);
}

.match-center-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 0.75fr) minmax(0, 2fr);
  gap: 14px 18px;
  padding: 18px 28px;
  border-bottom: 2px solid var(--line);
  background: #fff;
}

.match-center-title {
  display: grid;
  align-content: center;
  gap: 3px;
}

.match-center-title h1 {
  font-size: 26px;
  line-height: 1.08;
}

.match-center-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: flex-end;
  gap: 10px;
  min-width: 0;
}

.match-center-field {
  display: grid;
  gap: 5px;
  min-width: 150px;
}

.match-center-field span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

.match-center-field input,
.match-center-field select {
  width: 100%;
  min-height: 34px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.match-center-datebar {
  display: flex;
  align-items: end;
  gap: 6px;
}

.match-center-datebar .match-center-field {
  min-width: 150px;
}

.match-center-icon-button,
.match-center-text-button {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  min-height: 34px;
  border: 1px solid var(--line);
  background: #fff;
  font-weight: 700;
}

.match-center-icon-button {
  font-size: 20px;
  line-height: 1;
}

.match-center-text-button {
  padding: 0 10px;
  text-transform: uppercase;
}

.match-center-icon-button:hover,
.match-center-icon-button:focus-visible,
.match-center-text-button:hover,
.match-center-text-button:focus-visible,
.match-center-tabs button:hover,
.match-center-tabs button:focus-visible {
  background: var(--soft-blue);
  outline: 0;
}

.match-center-tabs {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.match-center-tabs button {
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-weight: 700;
  text-transform: uppercase;
}

.match-center-tabs button[aria-selected="true"] {
  background: var(--ink);
  color: #fff;
}

.match-center-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  border-bottom: 2px solid var(--line);
  background: #fff;
}

.match-center-refresh {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 12px;
  padding: 10px 28px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.match-center-refresh strong {
  font-size: 12px;
  line-height: 1.1;
  text-transform: uppercase;
}

.match-center-refresh span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.match-center-refresh.is-live {
  box-shadow: inset 6px 0 0 var(--red);
}

.match-center-refresh.is-stale,
.match-center-refresh.is-warning {
  background: var(--soft-amber);
  box-shadow: inset 6px 0 0 var(--amber);
}

.match-center-stat {
  min-width: 0;
  padding: 12px 18px;
  border-right: 1px solid var(--fine);
}

.match-center-stat:last-child {
  border-right: 0;
}

.match-center-stat span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

.match-center-stat strong {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  font-size: 18px;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.match-center-list {
  display: grid;
  gap: 18px;
  width: min(1160px, calc(100% - 56px));
  margin: 0 auto;
  padding: 20px 0 40px;
}

.match-center-day {
  border: 2px solid var(--line);
  background: #fff;
}

.match-center-day-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--soft-gray);
}

.match-center-day-header h2 {
  font-size: 17px;
  line-height: 1.12;
}

.match-center-day-header span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.match-center-group {
  display: grid;
}

.match-center-group + .match-center-group {
  border-top: 2px solid var(--line);
}

.match-center-group-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--fine);
  background: #fff;
}

.match-center-group-title strong {
  font-size: 14px;
}

.match-center-group-title span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.match-center-row {
  display: grid;
  grid-template-columns: minmax(96px, 0.6fr) minmax(0, 2.4fr) minmax(190px, 1fr) minmax(156px, 0.78fr);
  gap: 12px;
  align-items: center;
  min-height: 78px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--fine);
  color: inherit;
  text-decoration: none;
}

.match-center-row:last-child {
  border-bottom: 0;
}

.match-center-row.is-live {
  background: var(--soft-red);
  box-shadow: inset 6px 0 0 var(--red);
}

.match-center-row.is-finished {
  background: #fff;
}

.match-center-row.is-interrupted {
  background: var(--soft-amber);
}

.match-center-status {
  display: grid;
  gap: 5px;
}

.match-center-status strong {
  font-size: 15px;
  line-height: 1.1;
}

.match-center-status span,
.match-center-meta span,
.match-center-market span,
.match-center-team span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.match-center-teams {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.match-center-team {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.match-center-team strong {
  overflow: hidden;
  font-size: 16px;
  line-height: 1.12;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.match-center-score {
  min-width: 32px;
  font-size: 17px;
  font-weight: 800;
  text-align: right;
}

.match-center-meta {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.match-center-meta strong,
.match-center-market strong {
  display: block;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.18;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.match-center-market {
  display: grid;
  gap: 7px;
  justify-items: end;
  min-width: 0;
  text-align: right;
}

.match-center-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.match-center-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.1;
  text-decoration: none;
}

.match-center-pill.is-live {
  border-color: var(--red);
  background: var(--red);
  color: #fff;
}

.match-center-pill.is-muted {
  border-color: var(--fine);
  color: var(--muted);
}

.match-center-pill.is-detail {
  border-color: var(--blue);
  color: var(--blue);
}

.match-center-pill.is-warning {
  border-color: var(--amber);
  background: var(--soft-amber);
  color: var(--amber);
}

.match-center-panel {
  display: grid;
  gap: 7px;
  min-height: 150px;
  padding: 22px;
  border: 2px solid var(--line);
  background: #fff;
}

.match-center-panel strong {
  font-size: 18px;
  line-height: 1.15;
}

.match-center-panel span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.match-center-skeleton {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 2px solid var(--line);
  background: #fff;
}

.match-center-skeleton-row {
  display: grid;
  grid-template-columns: 96px 1fr 190px 156px;
  gap: 12px;
  min-height: 54px;
}

.match-center-skeleton-line {
  background: linear-gradient(90deg, #f1f1ef 0%, #ffffff 45%, #f1f1ef 90%);
  background-size: 220% 100%;
  border: 1px solid var(--fine);
  animation: match-center-loading 1.1s linear infinite;
}

.match-detail-page {
  gap: 16px;
  padding: 20px 0 44px;
}

.match-detail-page > section {
  width: min(980px, calc(100% - 56px));
  margin: 0 auto;
}

.match-detail-hero,
.match-detail-section {
  border: 2px solid var(--line);
  background: #fff;
}

.match-detail-hero {
  display: grid;
  gap: 16px;
  padding: 18px;
}

.match-detail-hero.is-live {
  background: var(--soft-red);
  box-shadow: inset 6px 0 0 var(--red);
}

.match-detail-kicker,
.match-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.match-detail-kicker span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.match-detail-scoreboard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(150px, 0.7fr) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.match-detail-team {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.match-detail-team span,
.match-detail-score span,
.match-detail-grid dt,
.match-detail-score-list span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.match-detail-team strong {
  overflow-wrap: anywhere;
  font-size: 28px;
  line-height: 1.02;
}

.match-detail-score {
  display: grid;
  gap: 6px;
  justify-items: center;
  text-align: center;
}

.match-detail-score strong {
  font-size: 34px;
  line-height: 1;
}

.match-detail-section {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.match-detail-section h2 {
  font-size: 18px;
  line-height: 1.1;
}

.match-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.match-detail-grid div,
.match-detail-score-list div {
  display: grid;
  gap: 5px;
  padding: 10px;
  border: 1px solid var(--fine);
  background: var(--soft-gray);
}

.match-detail-grid dd {
  margin: 0;
  overflow-wrap: anywhere;
  font-weight: 800;
}

.match-detail-score-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.match-detail-score-list strong {
  font-size: 18px;
}

.match-detail-section p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.match-detail-state {
  width: min(760px, calc(100% - 56px));
  margin: 20px auto;
}

@keyframes match-center-loading {
  from {
    background-position: 0 0;
  }
  to {
    background-position: -220% 0;
  }
}

@media (max-width: 900px) {
  .match-center-page {
    min-height: auto;
  }

  .match-center-toolbar {
    grid-template-columns: 1fr;
    padding: 14px 12px;
  }

  .match-center-controls {
    justify-content: stretch;
  }

  .match-center-field,
  .match-center-window {
    min-width: min(100%, 170px);
    flex: 1 1 150px;
  }

  .match-center-datebar {
    flex: 1 1 100%;
  }

  .match-center-datebar .match-center-field {
    flex: 1 1 auto;
    min-width: 0;
  }

  .match-center-icon-button,
  .match-center-text-button,
  .match-center-tabs button {
    min-height: 44px;
  }

  .match-center-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .match-center-list {
    width: calc(100% - 24px);
    padding: 14px 0 28px;
  }

  .match-center-row {
    grid-template-columns: 68px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
  }

  .match-center-meta,
  .match-center-market {
    grid-column: 2;
    justify-items: start;
    text-align: left;
  }

  .match-center-actions {
    justify-content: flex-start;
  }

  .match-center-team strong,
  .match-center-meta strong,
  .match-center-market strong {
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .match-center-skeleton-row {
    grid-template-columns: 68px 1fr;
  }

  .match-center-skeleton-row .match-center-skeleton-line:nth-child(n+3) {
    grid-column: 2;
  }

  .match-center-refresh {
    padding: 10px 12px;
  }

  .match-detail-page > section,
  .match-detail-state {
    width: calc(100% - 24px);
  }

  .match-detail-scoreboard,
  .match-detail-grid,
  .match-detail-score-list {
    grid-template-columns: 1fr;
  }

  .match-detail-score {
    justify-items: start;
    text-align: left;
  }

  .match-detail-team strong {
    font-size: 22px;
  }
}

@media (max-width: 520px) {
  .match-center-title h1 {
    font-size: 22px;
  }

  .match-center-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .match-center-tabs button {
    width: 100%;
  }

  .match-center-summary {
    grid-template-columns: 1fr;
  }
}
