/*---------------------------------------
    TabelSkor supplementary styles
    Small additive utility classes layered on top of the Betlio theme
    (style.css) for informational scorecenter views that have no
    direct equivalent in the original betting template.
---------------------------------------*/

.ts-list-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  background-color: var(--card-bg);
  border-radius: 8px;
  padding: 12px 16px;
  color: var(--heading-color);
  box-shadow: var(--elevation-shadow);
}

.ts-list-row:hover {
  color: var(--heading-color);
}

.ts-icon-btn {
  height: 54px;
  width: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 0px;
  color: var(--heading-color);
  font-size: 20px;
  background-color: transparent;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.ts-icon-btn:hover {
  background-color: var(--colors-primary-default);
  color: var(--colors-on-color-primary);
}

.ts-box-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.ts-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background-color: var(--card-bg);
  border-radius: 8px;
  padding: 14px 12px;
  color: var(--heading-color);
  box-shadow: var(--elevation-shadow);
}

.ts-section-label {
  color: var(--text-color);
  font-size: 14px;
  margin-bottom: 8px;
}

/*---------------------------------------
    Match row (status | teams | star)
---------------------------------------*/

.ts-league-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 2px;
  color: var(--heading-color, #fff);
}

.ts-league-header__logo {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  object-fit: contain;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
}

.ts-league-header__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.ts-league-header__name {
  font-weight: 700;
  font-size: 16px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-league-header__sub {
  font-size: 12px;
  color: var(--muted-text, #8BBB92);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-league-header__chevron {
  flex-shrink: 0;
  color: var(--muted-text, #8BBB92);
  font-size: 14px;
}

.matchboard .match-card.ts-match-row {
  display: flex !important;
  align-items: center;
  padding: 0;
  overflow: visible;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.ts-match-row__link {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) max-content;
  align-items: center;
  column-gap: 12px;
  flex: 1;
  min-width: 0;
  color: inherit;
  padding: 10px 0;
}

.ts-match-row__status {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.ts-match-row__status-text {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted-text, #8BBB92);
  line-height: 1.167;
  text-align: left;
}

.ts-match-row__status-text.text-danger {
  color: var(--colors-status-live);
  font-weight: 700;
}

.ts-match-row__status-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 1px;
  line-height: 1.167;
  text-align: left;
}

.ts-match-row__status-date {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted-text, #8BBB92);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.ts-match-row__status-time {
  font-size: 12px;
  font-weight: 700;
  color: var(--heading-color, #ffffff);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.ts-match-row__divider {
  display: none;
}

.ts-match-row__teams {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  justify-content: center;
}

.ts-match-row__scores {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  gap: 6px;
  min-width: 1.25rem;
}

.ts-match-row__team {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  height: 20px;
}

.ts-match-row__name {
  flex: 1;
  min-width: 0;
  font-size: 14px;
  font-weight: 500;
  color: var(--heading-color, #ffffff);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-match-row__score {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  height: 20px;
  text-align: right;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  color: var(--heading-color, #ffffff);
  font-variant-numeric: tabular-nums;
}

.ts-match-fav {
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  margin: 0 0 0 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: transparent;
  color: #c5c8ce;
  padding: 0;
  cursor: pointer;
  line-height: 0;
}

.ts-match-fav svg {
  width: 14px;
  height: 14px;
  display: block;
}

.ts-match-fav svg path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linejoin: round;
}

.ts-match-fav:hover,
.ts-match-fav:focus-visible {
  color: var(--colors-status-val);
  outline: none;
}

.ts-match-fav.is-active,
.ts-match-fav[aria-pressed="true"] {
  color: var(--colors-status-val);
}

.ts-match-fav.is-active svg path,
.ts-match-fav[aria-pressed="true"] svg path {
  fill: currentColor;
  stroke: currentColor;
}

.ts-filter-select {
  background-color: var(--input-box);
  color: var(--heading-color);
  border: 0px;
  border-radius: 8px;
  font-family: var(--fonts-sans);
  font-size: var(--font-sizes-sm);
}

.ts-filter-select:focus {
  outline: none;
  color: var(--heading-color);
  background-color: var(--input-box);
}

.ts-divider {
  border-color: var(--surface-border) !important;
}

.ts-live-dot {
  font-size: 8px;
  color: var(--colors-status-live);
}

.ts-event-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
  display: block;
}

.ts-highlight-thumb {
  max-height: 180px;
  object-fit: cover;
  display: block;
}

.ts-highlight-play {
  cursor: pointer;
  display: block;
}

.ts-highlight-play-icon {
  font-size: 20px;
  pointer-events: none;
}

.ts-highlight-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 220px;
  border: 0;
  display: block;
  background: #000000;
}

/*---------------------------------------
    Standings table — readable on dark theme
---------------------------------------*/

.ts-standings-table {
  --bs-table-color: var(--heading-color);
  --bs-table-bg: transparent;
  --bs-table-border-color: var(--surface-border);
  --bs-table-striped-color: var(--heading-color);
  --bs-table-hover-color: var(--heading-color);
  color: var(--heading-color);
}

.ts-standings-table > :not(caption) > * > * {
  color: inherit;
  background-color: transparent;
  border-bottom-color: var(--surface-border);
}

.ts-standings-table thead th {
  color: var(--text-color);
  font-weight: 500;
  font-size: var(--font-sizes-xs);
  white-space: nowrap;
}

.ts-standings-table tbody td {
  color: var(--heading-color);
  vertical-align: middle;
}

.ts-standings-table tbody tr + tr td {
  border-top: 1px solid var(--surface-border);
}

.ts-standings-table .text-blue {
  color: var(--primary) !important;
}

.ts-standings-table .dark-text {
  color: var(--text-color) !important;
}

/*---------------------------------------
    News page — responsive overrides
---------------------------------------*/

.ts-news {
  overflow-x: clip;
  max-width: 100%;
}

.ts-news .search-box {
  gap: 8px;
}

.ts-news-search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.ts-news-search-field i,
.ts-news-search-field .ts-ui-icon {
  color: var(--muted-text);
  flex-shrink: 0;
}

.ts-ui-icon {
  display: block;
  flex-shrink: 0;
}

#preloader .img-container {
  width: min(280px, 72vw);
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

#preloader .ts-preloader-logo {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.ts-news-search-field input {
  width: 100%;
  min-width: 0;
  color: var(--heading-color);
  background: transparent;
  border: 0;
}

.ts-news-search-field input::placeholder {
  color: var(--muted-text);
  opacity: 1;
}

.ts-news-slider-wrap {
  overflow: hidden;
  margin-right: -12px;
  padding-right: 12px;
}

.ts-news .news-slider {
  overflow: visible;
}

.ts-news .news-card {
  min-width: 0;
  width: 100%;
  overflow: hidden;
  height: 100%;
}

.ts-news-card-link {
  display: block;
  color: inherit;
  height: 100%;
}

.ts-news .news-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
}

.ts-news-card-title {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 0.75rem;
  font-size: 16px;
  font-weight: 500;
  color: var(--heading-color);
  line-height: 1.334;
}

.ts-news-meta {
  white-space: nowrap;
  flex-shrink: 0;
  font-size: 14px;
}

.ts-news .latest-news-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.ts-news .latest-news {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  min-width: 0;
  min-height: 160px;
}

.ts-news .latest-news img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  border-radius: 16px;
}

.ts-news .latest-news .content {
  right: 8px;
  z-index: 1;
  color: var(--colors-on-color-primary);
}

.ts-news .latest-news .content h6 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--colors-on-color-primary);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.33;
  padding-right: 4px;
}

.ts-news .latest-news .content .dark-text {
  color: var(--colors-neutral-default) !important;
  font-size: 12px;
}

.ts-news .news-card-2 {
  align-items: stretch;
  overflow: hidden;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}

.ts-news .news-card-2 img {
  width: 110px;
  min-width: 110px;
  height: 110px;
  object-fit: cover;
  flex-shrink: 0;
}

.ts-news-card-2-body {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.ts-news .news-card-2 h6 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--heading-color);
  line-height: 1.334;
}

.bottom-navigation .single-nav span {
  font-size: 10px;
  text-align: center;
  line-height: 1.167;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 1px;
}

@media (min-width: 576px) {
  .ts-news .news-card img {
    height: 190px;
  }

  .ts-news .latest-news-container {
    grid-template-columns: 1.4fr 1fr;
    grid-template-rows: 1fr 1fr;
  }

  .ts-news .ts-latest-lead {
    grid-row: 1 / span 2;
  }

  .ts-news .ts-latest-lead img,
  .ts-news .ts-latest-side img {
    height: 100%;
    min-height: 120px;
  }

  .ts-news .ts-latest-lead,
  .ts-news .ts-latest-side {
    min-height: 0;
    height: 100%;
  }

  .ts-news .news-card-2 img {
    width: 140px;
    min-width: 140px;
    height: 120px;
  }
}

@media (min-width: 768px) {
  .ts-news-card-title {
    font-size: 20px;
  }

  .bottom-navigation .single-nav span {
    font-size: 12px;
  }
}

/* Home / global search field */
.search-box {
  background-color: var(--card-bg);
  border: 1px solid var(--surface-border);
  border-radius: 999px;
  padding: 10px 14px;
}

.search-box .ts-news-search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.search-box .ts-news-search-field input {
  width: 100%;
  min-width: 0;
  color: var(--heading-color);
  background: transparent;
  border: 0;
}

.search-box .ts-news-search-field input::placeholder {
  color: var(--muted-text);
  opacity: 1;
}

.search-box .ts-news-search-field input:focus {
  outline: none;
}

/* Search results news cards (outside .news page) */
.ts-search-news-card {
  display: flex;
  align-items: stretch;
  overflow: hidden;
  min-width: 0;
  text-decoration: none;
  color: inherit;
  background-color: var(--card-bg);
  border-radius: 8px;
  box-shadow: var(--elevation-shadow);
}

.ts-search-news-card img {
  width: 110px;
  min-width: 110px;
  height: 110px;
  object-fit: cover;
  flex-shrink: 0;
  border-radius: 8px;
}

.ts-search-news-card h6 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--heading-color);
  line-height: 1.334;
}

@media (min-width: 576px) {
  .ts-search-news-card img {
    width: 140px;
    min-width: 140px;
    height: 120px;
  }
}

/*---------------------------------------
    Theme toggle + light mode palette
---------------------------------------*/

:root,
[data-theme="dark"] {
  --body-color: #092328;
  --card-bg: #12544F;
  --match-bg: #12544F;
  --dark-bg: #092328;
  --heading-color: #ffffff;
  --text-color: #8BBB92;
  --muted-text: #8BBB92;
  --nav-text: #8BBB92;
  --nav-bg: #092328;
  --input-box: #12544F;
  --primary: #2A835F;
  --colors-primary-default: #2A835F;
  --colors-action-primary-default: #2A835F;
  --colors-status-success-default: #2A835F;
  --colors-status-live: #f40030;
  --surface-border: rgba(139, 187, 146, 0.18);
  --link-hover: #ffffff;
  --bs-primary: #2A835F;
  --bs-primary-rgb: 42, 131, 95;
  --bs-danger: #f40030;
  --bs-danger-rgb: 244, 0, 48;
  --bs-success: #2A835F;
  --bs-success-rgb: 42, 131, 95;
  --bs-body-bg: #092328;
  --bs-body-color: #ffffff;
}

[data-theme="light"] {
  --body-color: var(--colors-surface-s0);
  --text-color: var(--colors-neutrals-n-lv2);
  --card-bg: var(--colors-surface-s1);
  --input-box: rgba(229, 233, 239, 0.5);
  --match-bg: var(--colors-surface-s1);
  --dark-bg: var(--colors-surface-s1);
  --border-color: var(--colors-neutral-default);
  --heading-color: var(--colors-neutrals-n-lv1);
  --surface-border: rgba(34, 34, 38, 0.15);
  --nav-bg: var(--colors-surface-s1);
  --nav-text: var(--colors-neutrals-n-lv2);
  --muted-text: var(--colors-neutrals-n-lv3);
  --link-hover: var(--colors-primary-default);
}

.ts-theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--muted-text);
  line-height: 1;
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
  font-weight: 500;
  font-size: var(--font-sizes-xs);
  font-family: var(--fonts-sans);
}

.ts-theme-toggle:hover,
.ts-theme-toggle:focus-visible {
  color: var(--primary);
  background-color: var(--colors-primary-highlight);
  outline: none;
}

.ts-theme-icon {
  font-size: 16px;
}

[data-theme="dark"] .ts-theme-icon-light {
  display: inline-block;
}

[data-theme="dark"] .ts-theme-icon-dark {
  display: none;
}

[data-theme="light"] .ts-theme-icon-light {
  display: none;
}

[data-theme="light"] .ts-theme-icon-dark {
  display: inline-block;
}

[data-theme="light"] body {
  color: var(--heading-color);
}

[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] h5,
[data-theme="light"] h6 {
  color: var(--heading-color);
}

[data-theme="light"] .dark-text {
  color: var(--muted-text) !important;
}

[data-theme="light"] a:hover {
  color: var(--link-hover);
}

[data-theme="light"] .search-box input,
[data-theme="light"] .search-box input:focus {
  color: var(--heading-color);
}

[data-theme="light"] .search-box input::placeholder {
  color: var(--muted-text);
}

[data-theme="light"] .matchboard .nav .nav-link {
  color: var(--heading-color);
  border-color: var(--border-color);
}

[data-theme="light"] .matchboard .nav .nav-link.active {
  color: var(--colors-on-color-primary);
  border-color: var(--colors-primary-default);
  background: var(--colors-primary-default);
}

[data-theme="light"] .matchboard .match-card .card-inner-border {
  border-bottom-color: var(--surface-border);
}

[data-theme="light"] .matchboard .match-card .score-btn,
[data-theme="light"] .matchboard .match-card .score-btn-red,
[data-theme="light"] .matchboard .match-card .score-btn-green {
  color: var(--heading-color);
  border-color: var(--border-color);
}

[data-theme="light"] .matchboard .match-card .score-btn-green,
[data-theme="light"] .matchboard .match-card .score-btn-red {
  color: var(--colors-on-color-primary);
}

[data-theme="light"] .bottom-navigation {
  background-color: var(--nav-bg);
  box-shadow: var(--elevation-shadow);
}

[data-theme="light"] .bottom-navigation .single-nav span {
  color: var(--nav-text);
}

[data-theme="light"] .bottom-navigation .single-nav.active span,
[data-theme="light"] .bottom-navigation .single-nav.active i {
  color: var(--primary);
}

[data-theme="light"] .ts-list-row,
[data-theme="light"] .ts-list-row:hover,
[data-theme="light"] .ts-box {
  color: var(--heading-color);
}

[data-theme="light"] .ts-icon-btn {
  color: var(--heading-color);
  border-color: var(--border-color);
}

[data-theme="light"] .ts-icon-btn:hover,
[data-theme="light"] .matchboard .game:hover {
  color: var(--colors-on-color-primary);
  background-color: var(--colors-primary-default);
}

[data-theme="light"] .ts-filter-select,
[data-theme="light"] .ts-filter-select:focus {
  color: var(--heading-color);
}

[data-theme="light"] .ts-divider {
  border-color: var(--surface-border) !important;
}

[data-theme="light"] .ts-standings-table {
  --bs-table-color: var(--heading-color);
  --bs-table-striped-color: var(--heading-color);
  --bs-table-hover-color: var(--heading-color);
  --bs-table-border-color: var(--surface-border);
  color: var(--heading-color);
}

[data-theme="light"] .ts-standings-table tbody td {
  color: var(--heading-color);
}

[data-theme="light"] .ts-standings-table tbody tr + tr td {
  border-top-color: var(--surface-border);
}

[data-theme="light"] .ts-news-card-title,
[data-theme="light"] .ts-news .news-card-2 h6,
[data-theme="light"] .ts-search-news-card h6 {
  color: var(--heading-color);
}

[data-theme="light"] .matchboard .bet-card,
[data-theme="light"] .matchboard .bet-card-2,
[data-theme="light"] .matchboard .match-card,
[data-theme="light"] .matchboard .match-card-sm {
  box-shadow: var(--elevation-shadow);
}

[data-theme="light"] .ts-league-header {
  color: var(--heading-color);
}

[data-theme="light"] .ts-league-header__logo {
  background: rgba(34, 34, 38, 0.15);
}

[data-theme="light"] .ts-match-row__divider {
  background: var(--surface-border);
}

[data-theme="light"] .ts-match-row__status-text,
[data-theme="light"] .ts-match-row__status-time,
[data-theme="light"] .ts-match-row__name,
[data-theme="light"] .ts-match-row__score {
  color: var(--heading-color);
}

[data-theme="light"] .ts-match-row__status-date {
  color: var(--muted-text);
}

[data-theme="light"] .ts-match-fav {
  color: var(--muted-text);
}

[data-theme="light"] .ts-match-fav:hover,
[data-theme="light"] .ts-match-fav:focus-visible,
[data-theme="light"] .ts-match-fav.is-active,
[data-theme="light"] .ts-match-fav[aria-pressed="true"] {
  color: var(--colors-status-val);
}

[data-theme="light"] .matchboard .game {
  border-color: var(--border-color);
  color: var(--heading-color);
}

[data-theme="light"] ::-webkit-scrollbar-track {
  background: var(--colors-surface-s0);
}

[data-theme="light"] ::-webkit-scrollbar-thumb {
  background: var(--colors-neutral-default);
}

[data-theme="light"] ::-webkit-scrollbar-thumb:hover {
  background: var(--colors-neutrals-n-lv1);
}

.ts-team-logo {
  flex-shrink: 0;
  display: block;
}

.ts-match-row__team .ts-team-logo {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.ts-brand {
  text-decoration: none;
}

.ts-brand-logo {
  display: block;
  height: 42px;
  width: auto;
  max-width: min(150px, 48vw);
  object-fit: contain;
}

/*---------------------------------------
    Bootstrap pagination — dark theme
---------------------------------------*/

.ts-pagination {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}

.ts-pagination nav {
  width: 100%;
}

.ts-pagination .pagination {
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 0;
}

/* Mobile prev/next: push Next to the right */
.ts-pagination .d-sm-none .pagination {
  width: 100%;
  justify-content: space-between;
}

.ts-pagination .page-link {
  background-color: var(--card-bg);
  border-color: var(--surface-border);
  color: var(--text-color);
  min-width: 2.25rem;
  text-align: center;
  border-radius: 8px !important;
  margin: 0;
  font-weight: 500;
  font-size: var(--font-sizes-xs);
  font-family: var(--fonts-sans);
  transition: background-color 0.15s ease-out, color 0.15s ease-out, border-color 0.15s ease-out;
}

.ts-pagination .page-link:hover,
.ts-pagination .page-link:focus {
  background-color: var(--colors-primary-highlight);
  border-color: var(--primary);
  color: var(--heading-color);
  z-index: 1;
}

.ts-pagination .page-item.active .page-link {
  background-color: var(--primary);
  border-color: var(--primary);
  color: var(--colors-on-color-primary);
  font-weight: 700;
}

.ts-pagination .page-item.disabled .page-link {
  background-color: transparent;
  border-color: var(--surface-border);
  color: var(--colors-neutral-default);
  opacity: 0.65;
}

.ts-pagination .small.text-muted {
  color: var(--muted-text) !important;
}

[data-theme="light"] .ts-pagination .page-link {
  background-color: var(--card-bg);
  border-color: var(--surface-border);
  color: var(--heading-color);
}

[data-theme="light"] .ts-pagination .page-link:hover,
[data-theme="light"] .ts-pagination .page-link:focus {
  background-color: var(--colors-primary-highlight);
  color: var(--heading-color);
}

[data-theme="light"] .ts-pagination .page-item.disabled .page-link {
  background-color: var(--input-box);
  border-color: var(--surface-border);
  color: var(--muted-text);
}

.fw-semibold {
  font-weight: 700 !important;
}

.small {
  font-size: var(--font-sizes-xs);
}

/*---------------------------------------
    Dark shell: sport tabs, board, score
---------------------------------------*/

:root {
  --ts-safe-top: env(safe-area-inset-top, 0px);
  --ts-safe-right: env(safe-area-inset-right, 0px);
  --ts-safe-bottom: env(safe-area-inset-bottom, 0px);
  --ts-safe-left: env(safe-area-inset-left, 0px);
}

.matchboard {
  overflow: visible;
  padding-bottom: calc(70px + var(--ts-safe-bottom, 0px));
}

.ts-shell-head {
  background: var(--body-color);
  border-bottom: 1px solid var(--surface-border);
  padding-top: var(--ts-safe-top, 0px);
  padding-left: var(--ts-safe-left, 0px);
  padding-right: var(--ts-safe-right, 0px);
}

.ts-shell-body {
  padding: 8px 12px 0;
}

.ts-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px 6px;
}

.ts-shell-search {
  margin: 0 12px 8px;
  width: auto;
}

.ts-lang {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted-text);
  font-size: 12px;
  font-weight: 700;
}

.ts-lang a {
  color: var(--muted-text);
}

.ts-lang a.is-active {
  color: #ffffff;
}

.ts-sport-tabs {
  position: relative;
  z-index: 12;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 4px 8px 0;
  background: var(--body-color);
  scrollbar-width: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ts-sport-tabs.is-stuck {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding-top: calc(8px + var(--ts-safe-top, 0px));
  padding-right: calc(8px + var(--ts-safe-right, 0px));
  padding-bottom: 6px;
  padding-left: calc(8px + var(--ts-safe-left, 0px));
  box-shadow: rgba(0, 0, 0, 0.45) 0px 8px 16px -10px;
  transform: translateY(0);
}

.ts-sport-tabs.is-stuck.is-entering {
  transform: translateY(-100%);
  transition: none;
}

.ts-sport-tabs::-webkit-scrollbar {
  display: none;
}

.ts-sport-tab {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 72px;
  padding: 8px 10px 10px;
  color: var(--muted-text);
  font-size: 12px;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  text-decoration: none;
}

.ts-sport-tab > .ts-sport-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(18, 84, 79, 0.72);
  color: inherit;
  box-shadow: inset 0 0 0 1px rgba(139, 187, 146, 0.16);
}

.ts-sport-icon .ts-ui-icon {
  width: 20px;
  height: 20px;
  display: block;
}

.ts-sport-tab.is-active {
  color: #ffffff;
  border-bottom-color: var(--primary);
}

.ts-sport-tab.is-active > .ts-sport-icon {
  background: linear-gradient(160deg, #2A835F 0%, #12544F 100%);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(42, 131, 95, 0.35);
}

.ts-sport-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 16px 4px 8px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
}

.ts-board-toolbar {
  display: flex;
  align-items: center;
  margin: 8px 0 12px;
}

.ts-date-nav {
  display: flex;
  align-items: center;
  gap: 2px;
}

.ts-date-nav__btn {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid var(--surface-border);
  border-radius: 50%;
  background: var(--card-bg);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  box-sizing: border-box;
}

.ts-date-nav__btn svg {
  width: 16px;
  height: 16px;
  display: block;
}

.ts-date-nav__label {
  min-width: 0;
  padding: 0 8px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
}

.ts-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: none;
}

.ts-chips::-webkit-scrollbar {
  display: none;
}

.ts-chip {
  flex: 0 0 auto;
  border: 0;
  border-radius: 20px;
  background: var(--card-bg);
  color: var(--heading-color);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  padding: 8px 14px;
}

.ts-chip.is-active {
  background: #8BBB92;
  color: #092328;
}

.ts-chip--live.is-active {
  background: var(--colors-status-live);
  color: #ffffff;
}

.ts-league {
  margin-bottom: 8px;
}

.ts-league.is-collapsed .ts-league__body {
  display: none;
}

.ts-league-header {
  padding: 8px 2px;
}

.ts-league-header__main {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--heading-color);
}

.ts-league-header__count {
  flex: 0 0 auto;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--muted-text);
  font-size: 12px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ts-league-header__toggle {
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: var(--muted-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ts-league.is-collapsed .ts-league-header__toggle i {
  transform: rotate(180deg);
}

.ts-league .match-card.ts-match-row {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  margin: 0;
}

.ts-league .ts-match-row + .ts-match-row {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ts-board-empty,
#ts-favorites-list .ts-match-row {
  padding: 0;
}

.ts-favorites {
  margin: 0 0 8px;
}

.ts-favorites .ts-sport-label {
  margin: 0 0 2px;
}

.bottom-navigation {
  background: var(--nav-bg);
  box-shadow: none;
  padding: 8px calc(4px + var(--ts-safe-right, 0px)) calc(10px + var(--ts-safe-bottom, 0px)) calc(4px + var(--ts-safe-left, 0px));
  border-top: 1px solid var(--surface-border);
  transition: transform 0.3s ease;
  will-change: transform;
}

.bottom-navigation.is-hidden {
  transform: translateY(100%);
}

.bottom-navigation .single-nav {
  gap: 2px;
}

.bottom-navigation .single-nav i,
.bottom-navigation .single-nav .ts-ui-icon {
  color: var(--muted-text);
  font-size: 18px;
  height: 24px;
  width: 22px;
  display: block;
  margin: 0 auto;
}

.bottom-navigation .single-nav span {
  color: var(--muted-text);
  font-size: 10px;
  line-height: 1.167;
}

.bottom-navigation .single-nav.active i,
.bottom-navigation .single-nav.active .ts-ui-icon,
.bottom-navigation .single-nav.active span {
  color: #8BBB92;
}

.bottom-navigation .single-nav.active .ts-ui-icon {
  filter: drop-shadow(0 0 6px rgba(139, 187, 146, 0.35));
}

.ts-crumb {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 8px 0;
  color: var(--muted-text);
  font-size: 12px;
  line-height: 1.334;
}

.ts-crumb a {
  color: var(--primary);
}

.ts-match-when {
  text-align: center;
  color: var(--muted-text);
  font-size: 12px;
  margin-bottom: 12px;
}

.ts-scoreboard {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 16px;
}

.ts-scoreboard__side {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: flex-start;
  gap: 4px;
}

.ts-scoreboard__side--away {
  justify-content: flex-end;
}

.ts-scoreboard__team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 0;
}

.ts-scoreboard__name {
  font-size: 14px;
  font-weight: 700;
  text-align: center;
}

.ts-scoreboard__scorer {
  color: var(--muted-text);
  font-size: 12px;
  text-align: center;
}

.ts-scoreboard__center {
  flex: 0 0 auto;
  text-align: center;
  padding-top: 12px;
}

.ts-scoreboard__score {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0;
}

.ts-scoreboard__status {
  margin: 4px 0 0;
  color: var(--muted-text);
  font-size: 12px;
  font-weight: 500;
}

.ts-scoreboard .ts-match-fav {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  margin: 0;
  border: 0;
  font-size: 16px;
}

.matchboard .ts-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  scrollbar-width: none;
  flex-wrap: nowrap;
}

.matchboard .ts-tabs .nav-link {
  background: transparent;
  border-radius: 0;
  color: var(--muted-text);
  font-weight: 500;
  font-size: 14px;
  padding: 10px 12px;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.matchboard .ts-tabs .nav-link.active {
  background: transparent;
  color: #ffffff;
  border-bottom-color: var(--primary);
}

.ts-stat-card {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 16px 14px 8px;
}

.ts-stat-card__title {
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 12px;
}

.ts-stat {
  margin-bottom: 14px;
}

.ts-stat__values {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 6px;
}

.ts-stat__label {
  flex: 1;
  text-align: center;
  color: var(--muted-text);
  font-size: 12px;
  font-weight: 500;
}

.ts-stat__bars {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.ts-stat__track {
  display: flex;
  height: 6px;
}

.ts-stat__bar {
  display: block;
  height: 6px;
  border-radius: 8px;
}

.ts-stat__bar--home {
  margin-left: auto;
  background: var(--colors-status-success-default);
}

.ts-stat__bar--away {
  background: var(--primary);
}

.ts-hero {
  display: block;
  position: relative;
  margin: 4px 0 14px;
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  background: #092328;
  aspect-ratio: 1024 / 500;
  max-height: 220px;
}

.ts-hero__media {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.ts-ad {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 72px;
  margin: 0 0 8px;
  padding: 0 12px;
  border-radius: 12px;
  background: var(--card-bg);
  border: 1px solid var(--surface-border);
  color: #ffffff;
  overflow: hidden;
  text-decoration: none;
}

.ts-ad img {
  width: 96px;
  height: 64px;
  object-fit: contain;
  flex-shrink: 0;
}

.ts-ad__copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.2;
}

.ts-ad__label {
  color: var(--muted-text);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.ts-ad strong {
  font-size: 14px;
  font-weight: 700;
}

.ts-ad small {
  color: var(--muted-text);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ts-date-nav__label {
  font-size: 16px;
  font-weight: 700;
}

.ts-league-header--inline {
  padding: 14px 0 2px;
}

.ts-league-header--inline .ts-league-header__logo {
  width: 20px;
  height: 20px;
  border-radius: 0;
  background: transparent;
}

.ts-league-header__crumb {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.ts-league-header__crumb > span[aria-hidden] {
  margin: 0 4px;
  color: var(--muted-text);
  font-weight: 400;
}

.ts-board .ts-league .ts-match-row + .ts-match-row {
  border-top: 0;
}

.ts-board .ts-league {
  margin-bottom: 4px;
}

