:root {
  color-scheme: dark;
  font-family: "Outfit", system-ui, sans-serif;
  background: #080b14;
  color: #f8fafc;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: #080b14;
}

button {
  font: inherit;
}

.ambient-background {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 15% 45%, rgba(79, 70, 229, 0.22), transparent 42%),
    radial-gradient(circle at 85% 25%, rgba(236, 72, 153, 0.15), transparent 42%),
    radial-gradient(circle at 50% 88%, rgba(14, 165, 233, 0.13), transparent 42%);
  filter: blur(58px);
  animation: pulse-background 15s ease-in-out infinite alternate;
}

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 62px 0;
}

.top-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 28px;
  direction: ltr;
}

.theme-switcher {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  width: 84px;
  padding: 2px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.22);
  backdrop-filter: blur(10px);
}

.theme-indicator {
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: 2px;
  width: calc(50% - 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(129, 140, 248, 0.18);
  transition: transform 240ms ease;
}

.theme-switcher.is-light .theme-indicator {
  transform: translateX(100%);
}

.theme-button {
  display: grid;
  place-items: center;
  position: relative;
  z-index: 1;
  min-width: 0;
  min-height: 28px;
  padding: 5px;
  border: 0;
  color: rgba(148, 163, 184, 0.74);
  background: transparent;
  cursor: pointer;
  font-size: 0.68rem;
  font-weight: 700;
  transition: color 180ms ease;
}

.theme-button.is-active {
  color: #fff;
}

.theme-icon {
  display: block;
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.theme-icon circle {
  fill: none;
}

.theme-icon-moon path {
  fill: currentColor;
  stroke: currentColor;
}

.theme-icon-sun path {
  fill: none;
}

.language-switcher {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 0;
}

.language-switcher label {
  color: rgba(203, 213, 225, 0.62);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.language-switcher select {
  min-width: 132px;
  height: 36px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  color: #f8fafc;
  background: rgba(15, 23, 42, 0.72);
  cursor: pointer;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  outline: 0;
  padding: 0 14px;
}

.language-switcher select:focus {
  border-color: rgba(129, 140, 248, 0.58);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.18);
}

.hero {
  max-width: 720px;
  margin: 0 auto 40px;
  text-align: center;
}

.eyebrow,
.section-eyebrow,
.player-kind {
  margin: 0;
  color: #818cf8;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

h1 {
  margin: 8px 0 14px;
  font-size: clamp(2.8rem, 7vw, 5.2rem);
  line-height: 0.98;
  letter-spacing: -0.07em;
  background: linear-gradient(120deg, #fff, #cbd5e1 68%, #94a3b8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy {
  max-width: 560px;
  margin: 0 auto;
  color: #94a3b8;
  font-size: 1.05rem;
  font-weight: 300;
}

.tabs {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  width: min(360px, 100%);
  margin: 0 auto 46px;
  padding: 4px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  background: rgba(30, 41, 59, 0.42);
  backdrop-filter: blur(16px);
}

.tab-indicator {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 4px;
  width: calc(50% - 4px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(129, 140, 248, 0.42), rgba(255, 255, 255, 0.06));
  transition: transform 240ms ease;
}

.tabs.is-channel .tab-indicator {
  transform: translateX(100%);
}

[dir="rtl"] .tabs .tab-indicator {
  right: 4px;
  left: auto;
}

[dir="rtl"] .tabs.is-channel .tab-indicator {
  transform: translateX(-100%);
}

.tab-button {
  position: relative;
  z-index: 1;
  padding: 12px 16px;
  border: 0;
  color: #94a3b8;
  background: transparent;
  cursor: pointer;
  font-weight: 600;
  transition: color 180ms ease;
}

.tab-button.is-active {
  color: #fff;
}

.content-container {
  min-height: 500px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.section-head h2,
.channel-section h2 {
  margin: 4px 0 0;
  font-size: 1.38rem;
}

.section-count {
  color: #94a3b8;
  font-size: 0.86rem;
}

.schedule {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.day-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0 2px 10px;
}

.day-label {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.day-date {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.day-number {
  font-size: 1.35rem;
  font-weight: 800;
}

.day-month {
  color: #cbd5e1;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.match-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
}

.match-card,
.channel-card {
  border: 0;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.match-card {
  position: relative;
  display: block;
  overflow: hidden;
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.42);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.match-card:hover,
.match-card:focus-visible {
  border-color: rgba(129, 140, 248, 0.42);
  background: rgba(30, 41, 59, 0.72);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.24);
  transform: translateY(-2px);
}

.score-board {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px minmax(0, 1fr);
  align-items: center;
  gap: 22px;
  min-height: 118px;
  padding: 14px 32px 16px;
}

.score-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
}

.score-team.is-away {
  flex-direction: column;
}

.score-team-badge {
  position: relative;
  display: grid;
  flex: 0 0 auto;
  width: 64px;
  height: 64px;
  place-items: center;
}

.score-team-badge img {
  max-width: 64px;
  max-height: 64px;
  object-fit: contain;
  filter: drop-shadow(0 7px 10px rgba(0, 0, 0, 0.35));
}

.score-team-initials {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border: 1px solid rgba(129, 140, 248, 0.42);
  border-radius: 50%;
  color: #e0e7ff;
  background: rgba(79, 70, 229, 0.2);
  font-size: 0.82rem;
  font-weight: 800;
}

.score-team-initials[hidden] {
  display: none;
}

.score-team-name {
  width: 100%;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.94);
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.score-team.is-away .score-team-name {
  text-align: center;
}

.score-center {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
}

.score-time {
  color: #fff;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.score-status {
  min-width: 68px;
  padding: 5px 9px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(148, 163, 184, 0.08);
  font-size: 0.63rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-align: center;
}

.score-status.is-live {
  border-color: rgba(248, 113, 113, 0.32);
  color: #fecaca;
  background: rgba(220, 38, 38, 0.18);
}

.score-vs {
  color: rgba(255, 255, 255, 0.34);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  transition: opacity 180ms ease, transform 180ms ease;
}

.score-play {
  position: absolute;
  bottom: -5px;
  left: 50%;
  width: 24px;
  height: 24px;
  border: 1px solid rgba(165, 180, 252, 0.58);
  border-radius: 50%;
  background: rgba(79, 70, 229, 0.42);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
  opacity: 0;
  transform: translate(-50%, 5px) scale(0.84);
  transition: opacity 180ms ease, transform 180ms ease;
}

.score-play::before {
  position: absolute;
  top: 50%;
  left: 53%;
  width: 0;
  height: 0;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  border-left: 6px solid #fff;
  content: "";
  transform: translate(-50%, -50%);
}

.match-card:hover .score-vs,
.match-card:focus-visible .score-vs {
  opacity: 0;
  transform: translateY(-4px);
}

.match-card:hover .score-play,
.match-card:focus-visible .score-play {
  opacity: 1;
  transform: translate(-50%, 0) scale(1);
}

.channel-list {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.channel-section h2 {
  margin-bottom: 12px;
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.channel-card {
  overflow: hidden;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 15px;
  background: rgba(18, 24, 38, 0.56);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.channel-card:hover,
.channel-card:focus-visible {
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.36);
  transform: translateY(-3px);
}

.channel-logo {
  display: grid;
  height: 94px;
  place-items: center;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.01));
}

.channel-logo img {
  max-width: 112px;
  max-height: 68px;
  object-fit: contain;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.5));
}

.channel-name {
  display: block;
  overflow: hidden;
  padding: 10px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.78rem;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sponsored-block {
  max-width: 100%;
  padding: 12px;
  border: 1px solid rgba(129, 140, 248, 0.17);
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.32);
}

.sponsored-label {
  display: block;
  margin-bottom: 8px;
  color: rgba(203, 213, 225, 0.56);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.sponsored-slots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 300px));
  align-items: flex-start;
  justify-content: center;
  gap: 12px;
  max-width: 100%;
}

.sponsored-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  justify-self: center;
  width: min(100%, 300px);
  max-width: 300px;
  min-width: 0;
  aspect-ratio: 6 / 5;
  min-height: 0;
  overflow: hidden;
}

.sponsored-slot iframe {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 100%;
  border: 0;
}

.sponsored-block.is-feed-sponsored {
  position: relative;
  overflow: hidden;
  padding: 4px 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.sponsored-block.is-feed-sponsored::before {
  display: none;
}

.sponsored-block.is-feed-sponsored .sponsored-label {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin-bottom: 8px;
  padding: 0 2px;
  border: 0;
  border-radius: 0;
  color: rgba(203, 213, 225, 0.34);
  background: transparent;
  font-size: 0.58rem;
}

.sponsored-block.is-feed-sponsored .sponsored-slots {
  position: relative;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 300px));
  gap: 12px;
  justify-content: center;
}

.sponsored-block.is-feed-sponsored .sponsored-slot {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.035);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.14);
  box-shadow: none;
}

.sponsored-block.is-feed-sponsored .sponsored-slot iframe {
  border-radius: 6px;
}

.loading-message,
.error-message {
  padding: 46px 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  color: #94a3b8;
  background: rgba(15, 23, 42, 0.35);
  text-align: center;
}

.modal[hidden] {
  display: none;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 12px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(2, 6, 23, 0.84);
  cursor: pointer;
}

.player-panel {
  position: relative;
  z-index: 1;
  width: min(1080px, 100%);
  max-height: calc(100dvh - 24px);
  overflow: hidden auto;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 20px;
  background: #080b14;
  box-shadow: 0 26px 90px rgba(0, 0, 0, 0.68);
}

.player-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.player-header h2 {
  margin: 3px 0 0;
  font-size: 1.2rem;
}

.player-sources {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 10px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(15, 23, 42, 0.72);
}

.source-button {
  flex: 0 0 auto;
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 700;
}

.source-button:hover,
.source-button:focus-visible,
.source-button.is-active {
  border-color: rgba(129, 140, 248, 0.62);
  color: #fff;
  background: rgba(79, 70, 229, 0.34);
}

.player-close {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
}

.player-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  align-items: stretch;
  direction: ltr;
  min-width: 0;
}

.player-layout.is-chat-hidden {
  grid-template-columns: minmax(0, 1fr);
}

.player-stage {
  position: relative;
  display: grid;
  width: 100%;
  min-height: 0;
  aspect-ratio: 16 / 9;
  max-height: 420px;
  overflow: hidden;
  place-items: center;
  background: #000;
}

.player-stage video,
.player-stage iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
  object-fit: contain;
}

.player-stage:fullscreen,
.player-stage:-webkit-full-screen {
  width: 100vw;
  height: 100vh;
  max-height: none;
  aspect-ratio: auto;
}

.player-fullscreen {
  position: absolute;
  top: 12px;
  right: 12px;
  bottom: auto;
  z-index: 4;
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  color: #fff;
  background: rgba(2, 6, 23, 0.58);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.32);
  cursor: pointer;
  opacity: 0.82;
  transition: opacity 160ms ease, transform 160ms ease, background 160ms ease;
}

.player-fullscreen.is-match-player {
  top: auto;
  right: 12px;
  bottom: 12px;
}

.player-fullscreen.is-channel-player {
  top: 12px;
  right: 12px;
  bottom: auto;
}

.player-fullscreen[hidden] {
  display: none;
}

.player-fullscreen:hover,
.player-fullscreen:focus-visible,
.player-fullscreen.is-active {
  background: rgba(15, 23, 42, 0.88);
  opacity: 1;
  transform: translateY(-1px);
}

.fullscreen-icon {
  display: block;
  width: 17px;
  height: 17px;
  background:
    linear-gradient(currentColor, currentColor) 0 0 / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 0 0 / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) 100% 0 / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 100% 0 / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) 0 100% / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 0 100% / 2px 7px no-repeat,
    linear-gradient(currentColor, currentColor) 100% 100% / 7px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 100% 100% / 2px 7px no-repeat;
}

.player-stage:fullscreen .player-fullscreen,
.player-stage:-webkit-full-screen .player-fullscreen {
  top: 18px;
  right: 18px;
  bottom: auto;
}

.player-stage:fullscreen .player-fullscreen.is-match-player,
.player-stage:-webkit-full-screen .player-fullscreen.is-match-player {
  top: auto;
  right: 18px;
  bottom: 18px;
}

.player-status {
  max-width: 620px;
  padding: 20px;
  color: #cbd5e1;
  text-align: center;
}

.player-status.is-error {
  color: #fecaca;
}

.chat-panel {
  display: flex;
  min-width: 0;
  min-height: 0;
  flex-direction: column;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.72), rgba(8, 11, 20, 0.92)),
    #080b14;
}

[dir="rtl"] .chat-panel {
  direction: rtl;
}

[dir="rtl"] .eyebrow,
[dir="rtl"] .section-eyebrow,
[dir="rtl"] .player-kind,
[dir="rtl"] .chat-eyebrow,
[dir="rtl"] .sponsored-label,
[dir="rtl"] .language-switcher label,
[dir="rtl"] .day-label,
[dir="rtl"] .day-month {
  letter-spacing: 0;
  text-transform: none;
}

[dir="rtl"] h1 {
  letter-spacing: 0;
}

.chat-panel[hidden] {
  display: none;
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 12px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.chat-eyebrow {
  display: block;
  color: rgba(129, 140, 248, 0.78);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.chat-header h3 {
  margin: 3px 0 0;
  color: #f8fafc;
  font-size: 0.92rem;
  line-height: 1.2;
}

.chat-profile {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.chat-profile label {
  display: block;
  margin-bottom: 7px;
  color: rgba(203, 213, 225, 0.58);
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.chat-name-row,
.chat-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.chat-name-row input,
.chat-form input {
  min-width: 0;
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 10px;
  color: #f8fafc;
  background: rgba(2, 6, 23, 0.42);
  outline: 0;
}

.chat-name-row input {
  height: 34px;
  padding: 0 10px;
  font-size: 0.82rem;
}

.chat-form input {
  height: 38px;
  padding: 0 11px;
  font-size: 0.86rem;
}

.chat-name-row input:focus,
.chat-form input:focus {
  border-color: rgba(129, 140, 248, 0.46);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.16);
}

.chat-name-row button,
.chat-form button {
  min-width: 0;
  border: 1px solid rgba(129, 140, 248, 0.32);
  border-radius: 10px;
  color: #f8fafc;
  background: rgba(79, 70, 229, 0.28);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 800;
}

.chat-name-row button {
  width: 42px;
}

.chat-form button {
  padding: 0 12px;
}

.chat-name-row button:hover,
.chat-name-row button:focus-visible,
.chat-form button:hover,
.chat-form button:focus-visible {
  border-color: rgba(165, 180, 252, 0.56);
  background: rgba(79, 70, 229, 0.44);
}

.chat-form input:disabled,
.chat-form button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.chat-messages {
  display: flex;
  min-height: 0;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  padding: 12px;
}

.chat-empty {
  margin: auto;
  color: rgba(203, 213, 225, 0.42);
  font-size: 0.82rem;
  text-align: center;
}

.chat-pinned {
  margin: 0;
  padding: 10px 11px;
  border: 1px solid rgba(129, 140, 248, 0.24);
  border-radius: 10px;
  color: rgba(226, 232, 240, 0.94);
  background: rgba(49, 46, 129, 0.28);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.35;
}

.chat-message {
  max-width: 94%;
  padding: 9px 10px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.64);
}

.chat-message.is-own {
  align-self: flex-end;
  border-color: rgba(129, 140, 248, 0.22);
  background: rgba(49, 46, 129, 0.34);
}

.chat-message-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}

.chat-author {
  min-width: 0;
  overflow: hidden;
  color: rgba(248, 250, 252, 0.88);
  font-size: 0.72rem;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-time {
  flex: 0 0 auto;
  color: rgba(203, 213, 225, 0.42);
  font-size: 0.68rem;
  font-weight: 700;
}

.chat-text {
  margin: 0;
  overflow-wrap: anywhere;
  color: rgba(226, 232, 240, 0.9);
  font-size: 0.82rem;
  line-height: 1.35;
}

.chat-form {
  padding: 10px 12px 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.player-sponsored {
  padding: 10px 14px 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(8, 11, 20, 0.7), rgba(10, 14, 24, 0.96)),
    rgba(8, 11, 20, 0.88);
}

.player-sponsored .is-player-sponsored {
  position: relative;
  overflow: hidden;
  padding: 10px;
  border-color: rgba(148, 163, 184, 0.13);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.78), rgba(8, 11, 20, 0.96) 48%, rgba(24, 31, 46, 0.72)),
    #090d16;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 16px 38px rgba(0, 0, 0, 0.32);
}

.player-sponsored .is-player-sponsored::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.08), transparent 42%, rgba(30, 41, 59, 0.16));
  content: "";
}

.player-sponsored .sponsored-label {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin-bottom: 8px;
  padding: 0 9px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 999px;
  color: rgba(203, 213, 225, 0.58);
  background: rgba(2, 6, 23, 0.42);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.player-sponsored .sponsored-slots {
  position: relative;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 300px));
  gap: 10px;
  justify-content: center;
}

.player-sponsored .sponsored-slot {
  position: relative;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01)),
    rgba(2, 6, 23, 0.5);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 12px 24px rgba(0, 0, 0, 0.22);
}

.player-sponsored .sponsored-slot iframe {
  border-radius: 8px;
}

[data-theme="light"] {
  background: #f5f7fb;
  color: #0f172a;
}

[data-theme="light"] body {
  background: #f5f7fb;
  color: #0f172a;
}

[data-theme="light"] .ambient-background {
  background:
    radial-gradient(circle at 14% 38%, rgba(99, 102, 241, 0.18), transparent 40%),
    radial-gradient(circle at 82% 22%, rgba(14, 165, 233, 0.16), transparent 40%),
    radial-gradient(circle at 52% 88%, rgba(244, 114, 182, 0.1), transparent 38%);
  opacity: 0.74;
}

[data-theme="light"] .language-switcher label,
[data-theme="light"] .section-count,
[data-theme="light"] .hero-copy,
[data-theme="light"] .day-label,
[data-theme="light"] .sponsored-label {
  color: rgba(71, 85, 105, 0.72);
}

[data-theme="light"] .language-switcher select,
[data-theme="light"] .theme-switcher,
[data-theme="light"] .tabs {
  border-color: rgba(15, 23, 42, 0.12);
  color: #0f172a;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] .theme-indicator,
[data-theme="light"] .tab-indicator {
  border-color: rgba(15, 23, 42, 0.1);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(224, 231, 255, 0.86));
  box-shadow: 0 8px 20px rgba(79, 70, 229, 0.14);
}

[data-theme="light"] .theme-button,
[data-theme="light"] .tab-button {
  color: #64748b;
}

[data-theme="light"] .theme-switcher {
  border-color: rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.44);
  box-shadow: none;
}

[data-theme="light"] .theme-indicator {
  border-color: rgba(15, 23, 42, 0.06);
  background: rgba(226, 232, 240, 0.72);
  box-shadow: none;
}

[data-theme="light"] .theme-button {
  color: rgba(71, 85, 105, 0.72);
}

[data-theme="light"] .theme-button.is-active,
[data-theme="light"] .tab-button.is-active {
  color: #111827;
}

[data-theme="light"] h1 {
  background: linear-gradient(120deg, #0f172a, #334155 68%, #64748b);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

[data-theme="light"] .section-head h2,
[data-theme="light"] .channel-section h2,
[data-theme="light"] .day-number,
[data-theme="light"] .score-time {
  color: #0f172a;
}

[data-theme="light"] .day-month,
[data-theme="light"] .score-team-name,
[data-theme="light"] .channel-name {
  color: rgba(15, 23, 42, 0.9);
}

[data-theme="light"] .match-card,
[data-theme="light"] .channel-card,
[data-theme="light"] .loading-message,
[data-theme="light"] .error-message {
  border-color: rgba(15, 23, 42, 0.1);
  color: #0f172a;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.07);
}

[data-theme="light"] .match-card:hover,
[data-theme="light"] .match-card:focus-visible,
[data-theme="light"] .channel-card:hover,
[data-theme="light"] .channel-card:focus-visible {
  border-color: rgba(79, 70, 229, 0.28);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.12);
}

[data-theme="light"] .score-team-initials {
  color: #3730a3;
  background: rgba(224, 231, 255, 0.82);
}

[data-theme="light"] .score-status {
  border-color: rgba(100, 116, 139, 0.24);
  color: #475569;
  background: rgba(241, 245, 249, 0.9);
}

[data-theme="light"] .score-status.is-live {
  border-color: rgba(220, 38, 38, 0.26);
  color: #b91c1c;
  background: rgba(254, 226, 226, 0.82);
}

[data-theme="light"] .score-vs {
  color: rgba(71, 85, 105, 0.46);
}

[data-theme="light"] .channel-logo {
  background: linear-gradient(135deg, rgba(248, 250, 252, 0.95), rgba(226, 232, 240, 0.58));
}

[data-theme="light"] .sponsored-block {
  border-color: rgba(79, 70, 229, 0.12);
  background: rgba(255, 255, 255, 0.52);
}

[data-theme="light"] .sponsored-block.is-feed-sponsored .sponsored-slot {
  border-color: rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.38);
}

[data-theme="light"] .modal-backdrop {
  background: rgba(15, 23, 42, 0.42);
}

[data-theme="light"] .player-panel,
[data-theme="light"] .chat-panel {
  border-color: rgba(15, 23, 42, 0.1);
  color: #0f172a;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(241, 245, 249, 0.94)),
    #f8fafc;
}

[data-theme="light"] .player-header,
[data-theme="light"] .player-sources,
[data-theme="light"] .chat-header,
[data-theme="light"] .chat-profile,
[data-theme="light"] .chat-form,
[data-theme="light"] .player-sponsored {
  border-color: rgba(15, 23, 42, 0.1);
}

[data-theme="light"] .player-sources,
[data-theme="light"] .player-sponsored {
  background: rgba(248, 250, 252, 0.88);
}

[data-theme="light"] .source-button,
[data-theme="light"] .player-close,
[data-theme="light"] .chat-name-row input,
[data-theme="light"] .chat-form input {
  border-color: rgba(15, 23, 42, 0.12);
  color: #0f172a;
  background: rgba(255, 255, 255, 0.86);
}

[data-theme="light"] .source-button:hover,
[data-theme="light"] .source-button:focus-visible,
[data-theme="light"] .source-button.is-active,
[data-theme="light"] .chat-name-row button,
[data-theme="light"] .chat-form button {
  border-color: rgba(79, 70, 229, 0.3);
  color: #312e81;
  background: rgba(224, 231, 255, 0.92);
}

[data-theme="light"] .chat-eyebrow,
[data-theme="light"] .chat-profile label,
[data-theme="light"] .chat-time,
[data-theme="light"] .chat-empty {
  color: rgba(71, 85, 105, 0.68);
}

[data-theme="light"] .chat-header h3,
[data-theme="light"] .chat-author,
[data-theme="light"] .chat-text,
[data-theme="light"] .player-status {
  color: #0f172a;
}

[data-theme="light"] .chat-pinned {
  border-color: rgba(79, 70, 229, 0.18);
  color: #312e81;
  background: rgba(224, 231, 255, 0.78);
}

[data-theme="light"] .chat-message {
  border-color: rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.76);
}

[data-theme="light"] .chat-message.is-own {
  border-color: rgba(79, 70, 229, 0.18);
  background: rgba(224, 231, 255, 0.82);
}

[data-theme="light"] .player-sponsored .is-player-sponsored {
  border-color: rgba(15, 23, 42, 0.1);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(241, 245, 249, 0.92)),
    #f8fafc;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] .player-sponsored .sponsored-label {
  color: rgba(71, 85, 105, 0.6);
  background: rgba(255, 255, 255, 0.64);
}

[data-theme="light"] .player-sponsored .sponsored-slot {
  border-color: rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

@media (max-width: 980px) {
  .player-layout {
    grid-template-columns: 1fr;
  }

  .chat-panel {
    max-height: 360px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-left: 0;
  }

  .channel-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .modal {
    padding: 10px;
  }

  .top-controls {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
  }

  .theme-switcher {
    width: 84px;
    margin: 0 auto;
  }

  .language-switcher {
    justify-content: center;
  }

  .player-panel {
    max-height: calc(100dvh - 20px);
    border-radius: 14px;
  }

  .chat-panel {
    max-height: 330px;
  }

  .chat-header,
  .chat-profile,
  .chat-messages,
  .chat-form {
    padding-right: 12px;
    padding-left: 12px;
  }

  .page-shell {
    width: min(100% - 24px, 620px);
    padding-top: 42px;
  }

  .match-grid {
    gap: 8px;
  }

  .match-card {
    border-radius: 10px;
  }

  .score-board {
    grid-template-columns: minmax(0, 1fr) 76px minmax(0, 1fr);
    gap: 7px;
    min-height: 106px;
    padding: 10px 8px 12px;
  }

  .score-team,
  .score-team.is-away {
    flex-direction: column;
    gap: 7px;
  }

  .score-team-badge,
  .score-team-badge img {
    width: 50px;
    height: 50px;
    max-width: 50px;
    max-height: 50px;
  }

  .score-team-initials {
    width: 46px;
    height: 46px;
    font-size: 0.7rem;
  }

  .score-team-name,
  .score-team.is-away .score-team-name {
    width: 100%;
    font-size: 0.72rem;
    text-align: center;
  }

  .score-time {
    font-size: 0.92rem;
  }

  .score-status {
    min-width: 58px;
    padding: 4px 6px;
    font-size: 0.54rem;
  }

  .channel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 9px;
  }

  .channel-logo {
    height: 80px;
  }

  .channel-logo img {
    max-width: 88px;
    max-height: 56px;
  }

  .sponsored-block {
    padding: 10px;
  }

  .sponsored-block.is-feed-sponsored {
    padding: 2px 0;
  }

  .sponsored-block.is-feed-sponsored .sponsored-slots {
    grid-template-columns: minmax(0, min(100%, 300px));
  }

  .player-sponsored {
    padding: 12px;
  }

  .player-sponsored .is-player-sponsored {
    padding: 10px;
    border-radius: 14px;
  }

  .player-sponsored .sponsored-slots {
    grid-template-columns: minmax(0, min(100%, 300px));
  }
}

@media (max-width: 420px) {
  .channel-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@keyframes pulse-background {
  from {
    opacity: 0.82;
    transform: scale(1);
  }

  to {
    opacity: 1;
    transform: scale(1.08);
  }
}

@keyframes pulse-live {
  50% {
    opacity: 0.48;
  }
}
