:root {
  --ts-bg: #eef0f5;
  --ts-ink: #10141f;
  --ts-muted: #5c6478;
  --ts-line: rgba(16, 20, 31, 0.08);
  --ts-surface: #fff;
  --ts-accent: #fe5900;
  --ts-navy: #0c1020;
  --ts-ok: #16a34a;
  --ts-radius: 18px;
  --ts-topbar: 60px;
  --ts-tabbar: calc(64px + env(safe-area-inset-bottom, 0px));
  --ts-shadow: 0 10px 30px rgba(12, 16, 32, 0.08);
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

.ts-app {
  margin: 0;
  min-height: 100%;
  background: var(--ts-bg);
  color: var(--ts-ink);
  font-family: Outfit, "Plus Jakarta Sans", system-ui, sans-serif;
  padding-bottom: 0;
}

.ts-app a { color: inherit; }

.ts-topbar {
  position: sticky;
  top: 0;
  z-index: 80;
  height: var(--ts-topbar);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 16px;
  padding-top: env(safe-area-inset-top, 0px);
  background: var(--ts-navy);
  background: color-mix(in srgb, var(--ts-navy) 92%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: #fff;
}

.ts-topbar__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  text-decoration: none;
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.ts-topbar__brand img {
  height: 36px;
  width: 36px;
  object-fit: contain;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  padding: 3px;
  flex-shrink: 0;
}

.ts-topbar__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 15px;
}

.ts-topbar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.ts-topbar__ghost {
  display: none;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.ts-topbar__menu {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ts-topnav {
  display: none;
  position: sticky;
  top: var(--ts-topbar);
  z-index: 70;
  background: var(--ts-navy);
  background: color-mix(in srgb, var(--ts-navy) 96%, transparent);
  padding: 14px 16px 16px;
  overflow-x: auto;
  scrollbar-width: none;
}

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

.ts-topnav ul {
  display: flex;
  gap: 8px;
  list-style: none;
  margin: 0 auto;
  padding: 0;
  max-width: 1120px;
}

.ts-topnav a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
}

.ts-topnav a i { font-size: 12px; color: var(--ts-accent); }
.ts-topnav a:hover,
.ts-topnav a.is-active {
  background: #fff;
  color: var(--ts-navy);
}

.ts-hero {
  background:
    radial-gradient(1200px 280px at 80% -20%, color-mix(in srgb, var(--ts-accent) 45%, transparent), transparent 55%),
    linear-gradient(160deg, var(--ts-navy) 0%, color-mix(in srgb, var(--ts-navy) 82%, #fff) 58%, color-mix(in srgb, var(--ts-accent) 28%, var(--ts-navy)) 140%);
  color: #fff;
  padding: 28px 16px 36px;
}

.ts-hero__inner {
  max-width: 1120px;
  margin: 0 auto;
}

.ts-hero__logo {
  height: 64px;
  width: 64px;
  object-fit: contain;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  padding: 6px;
  margin-bottom: 14px;
}

.ts-hero h1 {
  margin: 0 0 10px;
  font-size: clamp(24px, 6vw, 40px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  text-transform: none;
}

.ts-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  opacity: 1;
  font-weight: 600;
}
.ts-hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.ts-hero__btn {
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 0 16px;
  border-radius: 10px;
  background: var(--ts-accent, #fe5900);
  color: #fff !important;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
}
.ts-hero__btn--ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,.35);
}

.ts-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 12px;
  font-weight: 650;
}

.ts-hero h1 .tournament-done-badge,
.ts-ended-badge,
.tournament-done-badge {
  display: inline-flex;
  width: auto;
  margin: 0;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #d8f5e4;
  background: rgba(22, 163, 74, 0.28);
  border: 1px solid rgba(216, 245, 228, 0.28);
}

.ts-wrap,
.ts-app .container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 16px;
}

.ts-section {
  padding: 28px 0;
  scroll-margin-top: 84px;
}

.ts-section--alt { background: transparent; }

.ts-section h2,
.ts-info-head h2 {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-transform: none;
  margin: 0 0 16px;
}

.ts-info-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.ts-info-head h2 { margin: 0; }

.ts-acc-toggle {
  width: 100%;
  appearance: none;
  font: inherit;
  color: inherit;
  background: var(--ts-surface);
  border: 1px solid var(--ts-line);
  border-radius: var(--ts-radius);
  box-shadow: var(--ts-shadow);
  padding: 16px 18px;
  cursor: pointer;
  text-align: left;
  margin-bottom: 0;
}

.ts-acc-toggle[aria-expanded="true"] {
  border-radius: var(--ts-radius) var(--ts-radius) 0 0;
}

.ts-acc-right {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.ts-acc-toggle > .fa-chevron-down,
.ts-acc-right > .fa-chevron-down {
  color: var(--ts-muted);
  font-size: 14px;
  transition: transform 0.2s ease;
}

.ts-acc-toggle[aria-expanded="true"] .fa-chevron-down {
  transform: rotate(180deg);
}

.ts-acc-panel {
  padding-top: 12px;
}

.ts-acc-toggle[aria-expanded="true"] + .ts-acc-panel {
  padding-top: 12px;
}

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

.ts-info-card,
.ts-card,
.ts-table-wrap {
  background: var(--ts-surface);
  border: 1px solid var(--ts-line);
  border-radius: var(--ts-radius);
  box-shadow: var(--ts-shadow);
}

.ts-info-card {
  padding: 18px;
}

.ts-info-card i {
  color: var(--ts-accent);
  font-size: 18px;
  margin-bottom: 8px;
  display: block;
}

.ts-info-card h3 {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ts-muted);
  margin: 0 0 10px;
}

.ts-info-card > p {
  margin: 0;
  font-weight: 750;
  font-size: 18px;
}

.ts-podium-cat { margin: 0 0 14px; }
.ts-podium-cat:last-child { margin-bottom: 0; }
.ts-podium-cat strong {
  display: block;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ts-accent);
  margin-bottom: 6px;
}
.ts-podium-cat p {
  margin: 0 0 3px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
}

.ts-card {
  padding: 16px;
  height: 100%;
}

.ts-empty { opacity: 0.7; margin: 0; color: var(--ts-muted); }

.ts-table-wrap {
  overflow: auto;
}

.ts-table {
  width: 100%;
  border-collapse: collapse;
  background: transparent;
}

.ts-table th,
.ts-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--ts-line);
  text-align: left;
  font-size: 13px;
}

.ts-table th {
  background: #f6f7fb;
  color: var(--ts-muted);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.04em;
  position: sticky;
  top: 0;
}

.ts-table tbody tr:last-child td { border-bottom: 0; }
.ts-table a { text-decoration: none; font-weight: 700; }

.ts-match-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ts-match-card {
  display: block;
  text-decoration: none;
  background: var(--ts-surface);
  border: 1px solid var(--ts-line);
  border-radius: 14px;
  box-shadow: var(--ts-shadow);
  padding: 12px 14px;
}

.ts-match-card__meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  color: var(--ts-muted);
  margin-bottom: 8px;
}

.ts-match-card__row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}

.ts-match-card__team {
  font-size: 13px;
  font-weight: 750;
  line-height: 1.25;
  min-width: 0;
  overflow-wrap: anywhere;
}

.ts-match-card__team--away { text-align: right; }

.ts-match-card__score {
  font-size: 16px;
  font-weight: 800;
  white-space: nowrap;
  background: #f4f5f9;
  border-radius: 10px;
  padding: 4px 8px;
}

.ts-match-card__status {
  margin-top: 8px;
  font-size: 11px;
  font-weight: 800;
  color: var(--ts-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ts-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.ts-tabs::-webkit-scrollbar { display: none; }

.ts-tab {
  border: 0;
  background: #fff;
  color: var(--ts-ink);
  font-weight: 750;
  padding: 10px 14px;
  cursor: pointer;
  text-transform: none;
  font-size: 13px;
  border-radius: 999px;
  white-space: nowrap;
  box-shadow: var(--ts-shadow);
}

.ts-tab.active {
  background: var(--ts-navy);
  color: #fff;
}

.ts-panel { display: none; }
.ts-panel.active { display: block; }

.ts-footer {
  background: transparent;
  color: var(--ts-muted);
  padding: 24px 16px 28px;
  font-size: 13px;
}

.ts-footer .container,
.ts-footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.ts-footer a { color: var(--ts-accent); }

.ts-tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
  border-top: 1px solid var(--ts-line);
  padding: 6px 6px calc(6px + env(safe-area-inset-bottom, 0px));
}

.ts-tabbar a,
.ts-tabbar button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ts-muted);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  font-weight: 750;
  padding: 6px 0;
}

.ts-tabbar i { font-size: 16px; }
.ts-tabbar a.is-active,
.ts-tabbar button.is-active { color: var(--ts-accent); }

.ts-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(86vw, 340px);
  background: #fff;
  z-index: 120;
  transform: translateX(110%);
  transition: transform 0.22s ease;
  box-shadow: -12px 0 40px rgba(0, 0, 0, 0.18);
  padding: calc(18px + env(safe-area-inset-top, 0px)) 18px 24px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ts-app.is-menu-open .ts-drawer { transform: translateX(0); }

.ts-drawer__title {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ts-muted);
  margin: 8px 4px 10px;
}

.ts-drawer a {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  padding: 12px 12px;
  border-radius: 14px;
  font-weight: 750;
  color: var(--ts-ink);
}

.ts-drawer a i {
  width: 18px;
  color: var(--ts-accent);
}

.ts-drawer a:hover,
.ts-drawer a.is-active { background: #f4f5f9; }

.ts-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 10, 18, 0.45);
  z-index: 110;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.ts-app.is-menu-open .ts-backdrop {
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 899px) {
  .ts-app { padding-bottom: var(--ts-tabbar); overflow-x: hidden; }
  .ts-section { scroll-margin-top: 72px; scroll-margin-bottom: 88px; }
  .ts-footer { padding-bottom: 12px; }

  .ts-app .table-responsive,
  .ts-app .ts-table-wrap {
    overflow: visible;
  }

  .ts-tabs {
    flex-wrap: wrap;
    overflow: visible;
  }

  .ts-standings {
    table-layout: fixed;
    width: 100%;
  }
  .ts-standings th,
  .ts-standings td {
    padding: 8px 6px;
    font-size: 12px;
  }
  .ts-standings th:nth-child(1),
  .ts-standings td:nth-child(1) { width: 28px; text-align: center; }
  .ts-standings th:nth-child(3),
  .ts-standings td:nth-child(3),
  .ts-standings th:nth-child(9),
  .ts-standings td:nth-child(9),
  .ts-standings th:nth-child(10),
  .ts-standings td:nth-child(10) { width: 32px; text-align: center; }
  .ts-standings td:nth-child(2) {
    overflow-wrap: anywhere;
    line-height: 1.25;
  }
  .ts-standings th:nth-child(4),
  .ts-standings th:nth-child(5),
  .ts-standings th:nth-child(6),
  .ts-standings th:nth-child(7),
  .ts-standings th:nth-child(8),
  .ts-standings td:nth-child(4),
  .ts-standings td:nth-child(5),
  .ts-standings td:nth-child(6),
  .ts-standings td:nth-child(7),
  .ts-standings td:nth-child(8) { display: none; }

  .ts-scorers th,
  .ts-scorers td { padding: 8px 8px; font-size: 12px; }

  .ts-card h4,
  #liveMatchesGrid h4 {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 8px;
    align-items: center;
    font-size: 14px;
  }
  .live-home, .live-away { overflow-wrap: anywhere; }
  .live-away { text-align: right; }
  .live-score { white-space: nowrap; }
}

@media (min-width: 900px) {
  .ts-topbar { padding: 0 24px; }
  .ts-topbar__ghost { display: inline-flex; }
  .ts-topbar__menu { display: none; }
  .ts-topnav {
    display: block;
    padding: 16px 24px 18px;
  }
  .ts-tabbar { display: none; }
  .ts-hero { padding: 40px 24px 48px; }
  .ts-wrap,
  .ts-app .container { padding: 0 24px; }
  .ts-info-grid {
    grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr));
  }
  .ts-section { padding: 36px 0; }
  .ts-match-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
}

@media (min-width: 600px) and (max-width: 899px) {
  .ts-info-grid { grid-template-columns: 1fr 1fr; }
  .ts-info-grid .ts-info-card:first-child { grid-column: 1 / -1; }
}

.ts-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  font-weight: 700;
  font-size: 14px;
  color: var(--ts-muted);
  text-decoration: none;
}
.ts-back:hover { color: var(--ts-accent); }

.ts-live-link { display: block; text-decoration: none; color: inherit; }
.ts-live-link:hover { transform: none; }

.ts-match-page { padding-top: 20px; }
.ts-app--match .ts-footer { margin-top: 8px; }

.ts-app .md-card {
  background: var(--ts-surface);
  border-radius: var(--ts-radius);
  box-shadow: var(--ts-shadow);
  overflow: hidden;
}
.ts-app .md-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  background: var(--ts-navy);
  color: #fff;
}
.ts-app .md-comp { color: #fff; font-weight: 700; }
.ts-app .md-status {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: #cbd5e1;
}
.ts-app .md-status.is-live { color: #fb7185; }
.ts-app .md-scoreboard {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 28px 18px 20px;
}
.ts-app .md-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}
.ts-app .md-team img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  background: #eef1f6;
}
.ts-app .md-team strong { font-size: 16px; }
.ts-app .md-score { text-align: center; }
.ts-app .md-score b { display: block; font-size: 32px; line-height: 1.1; }
.ts-app .md-score small { color: var(--ts-muted); font-size: 13px; }
.ts-app .md-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  list-style: none;
  margin: 0;
  padding: 0 18px 18px;
  color: var(--ts-muted);
  font-size: 13px;
}
.ts-app .md-meta i { color: var(--ts-accent); margin-right: 4px; }
.ts-app .md-events {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--ts-line);
}
.ts-app .md-col { padding: 18px; }
.ts-app .md-col + .md-col { border-left: 1px solid var(--ts-line); }
.ts-app .md-col h3,
.ts-app .md-officials h3,
.ts-app .md-video h3,
.ts-app .md-pens h3 {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 12px;
}
.ts-app .md-col ul,
.ts-app .md-officials ul { list-style: none; margin: 0; padding: 0; }
.ts-app .md-col li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 14px;
}
.ts-app .md-min { font-weight: 700; color: var(--ts-accent); min-width: 36px; }
.ts-app .md-empty { color: var(--ts-muted); font-size: 13px; margin: 0; }
.ts-app .md-flag.yellow,
.ts-app .md-flag.red {
  display: inline-block;
  width: 10px;
  height: 14px;
  border-radius: 2px;
  flex-shrink: 0;
}
.ts-app .md-flag.yellow { background: #facc15; }
.ts-app .md-flag.red { background: #dc2626; }
.ts-app .md-officials,
.ts-app .md-video,
.ts-app .md-pens,
.ts-app .md-notes {
  padding: 18px;
  border-top: 1px solid var(--ts-line);
}
.ts-app .md-officials li { padding: 4px 0; font-size: 14px; }
.ts-app .md-officials a { color: inherit; font-weight: 600; }
.ts-app .md-officials a:hover { color: var(--ts-accent); }
.ts-app .md-notes { margin: 0; color: var(--ts-muted); }
.ts-app .md-embed { position: relative; padding-top: 56.25%; }
.ts-app .md-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ts-app .md-video-link { margin: 12px 0 0; }
.ts-app .md-video-link a { color: var(--ts-accent); font-weight: 600; }
.ts-app .md-pens p { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; }
.ts-app .md-pens .is-in { color: var(--ts-ok); }
.ts-app .md-pens .is-out { color: #dc2626; }

@media (max-width: 767px) {
  .ts-app .md-events { grid-template-columns: 1fr; }
  .ts-app .md-col + .md-col { border-left: 0; border-top: 1px solid var(--ts-line); }
  .ts-app .md-score b { font-size: 24px; }
  .ts-app .md-team img { width: 48px; height: 48px; }
}

.ts-sponsors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.ts-sponsor {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 92px;
  padding: 16px;
  background: var(--ts-surface);
  border-radius: var(--ts-radius);
  box-shadow: var(--ts-shadow);
  text-decoration: none;
}
.ts-sponsor img {
  max-width: 100%;
  max-height: 64px;
  object-fit: contain;
}
.ts-sponsor:hover { outline: 2px solid var(--ts-accent); }

.ts-drive-embed {
  background: var(--ts-surface);
  border-radius: var(--ts-radius);
  box-shadow: var(--ts-shadow);
  overflow: hidden;
  min-height: 420px;
}
.ts-drive-embed iframe {
  display: block;
  width: 100%;
  height: 520px;
  border: 0;
  background: #fff;
}
.ts-drive-open {
  margin: 14px 0 0;
}
.ts-drive-open a {
  color: var(--ts-accent);
  font-weight: 700;
  text-decoration: none;
}
.ts-drive-open a:hover { text-decoration: underline; }

@media (min-width: 700px) {
  .ts-sponsors { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
