:root {
  color-scheme: dark;
  --bg: #101114;
  --panel: #191b21;
  --panel-2: #22252d;
  --line: #343945;
  --text: #f4f7fb;
  --muted: #9aa3b2;
  --accent: #32d296;
  --accent-2: #ffca3a;
  --danger: #ff5d5d;
  --blue: #5bbcff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.overlay-body,
.overlay-body #overlay {
  background: transparent;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-2);
  color: var(--text);
  padding: 9px 12px;
  cursor: pointer;
}

button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #07110d;
  font-weight: 800;
}

button.danger {
  border-color: color-mix(in srgb, var(--danger), transparent 40%);
  color: #ffd9d9;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #111318;
  color: var(--text);
  padding: 10px 11px;
}

textarea {
  min-height: 92px;
  resize: vertical;
}

.admin-shell {
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(16, 17, 20, 0.96);
  backdrop-filter: blur(10px);
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand-row h1 {
  margin: 0;
  font-size: 20px;
}

.scene-switcher {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}

.scene-switcher button.active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 14px;
  padding: 18px;
}

.panel {
  grid-column: span 4;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 14px;
}

.panel.wide {
  grid-column: span 8;
}

.panel.full {
  grid-column: 1 / -1;
}

.control-panel {
  grid-column: 1 / -1;
  order: 0;
}

.user-panel {
  grid-column: 1 / -1;
  order: 12;
}

.scoreboard-panel {
  grid-column: span 8;
  order: 2;
}

.info-panel {
  grid-column: span 4;
  order: 3;
}

.lower-third-panel {
  grid-column: span 4;
  order: 4;
}

.ads-panel {
  grid-column: span 4;
  order: 5;
}

.schedule-panel {
  grid-column: span 8;
  order: 6;
}

.past-panel {
  grid-column: span 4;
  order: 7;
}

.bracket-panel {
  grid-column: 1 / -1;
  order: 8;
}

.groups-panel {
  grid-column: span 5;
  order: 9;
}

.teams-panel {
  grid-column: span 7;
  order: 10;
}

.standings-admin-panel {
  order: 11;
}

.panel h2 {
  margin: 0 0 12px;
  font-size: 16px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.form-grid .span {
  grid-column: 1 / -1;
}

.stack {
  display: grid;
  gap: 8px;
}

.list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #14161b;
}



.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.admin-user {
  align-self: center;
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 900;
}

.match-edit {
  grid-template-columns: minmax(0, 1fr) auto;
}

.ad-edit {
  grid-template-columns: minmax(0, 1fr) auto;
}

.user-row {
  grid-template-columns: minmax(180px, 1fr) minmax(320px, auto);
}

.user-password-form {
  align-items: center;
}

.user-password-form input {
  width: min(260px, 100%);
}

.ad-options {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.ad-row.is-active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(50, 210, 150, 0.52);
}

.admin-standings-group {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.admin-standings-group h3 {
  margin: 0;
  color: var(--accent-2);
  font-size: 14px;
  text-transform: uppercase;
}

.admin-standings-table {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #14161b;
}

.admin-standings-grid {
  display: grid;
  grid-template-columns: 42px minmax(120px, 1fr) repeat(3, 54px) 66px 58px;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  gap: 8px;
  border-bottom: 1px solid var(--line);
}

.admin-standings-grid:last-child {
  border-bottom: 0;
}

.admin-standings-grid.labels {
  min-height: 34px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.match-edit .form-grid {
  align-items: center;
}

.muted {
  color: var(--muted);
  font-size: 13px;
}

.score-control {
  display: grid;
  grid-template-columns: 1fr 80px 80px;
  gap: 8px;
  align-items: end;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.checkbox-row input {
  width: auto;
}

.overlay-body {
  overflow: hidden;
  background: transparent;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.login-card {
  display: grid;
  gap: 12px;
  width: min(430px, 100%);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  padding: 26px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

.login-card h1 {
  margin: 0 0 8px;
  font-size: 30px;
  line-height: 1;
}

.login-kicker {
  margin: 0 0 8px;
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.overlay-root {
  width: 100vw;
  min-height: 100vh;
  padding: 36px;
  display: grid;
  align-items: center;
}

@keyframes overlay-card-in {
  from {
    opacity: 0;
    transform: translateY(22px) scale(0.985);
    filter: blur(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes overlay-title-in {
  from {
    opacity: 0;
    transform: translateX(-28px);
    clip-path: inset(0 100% 0 0);
  }
  to {
    opacity: 1;
    transform: translateX(0);
    clip-path: inset(0 0 0 0);
  }
}

@keyframes overlay-item-in {
  from {
    opacity: 0;
    transform: translateX(-18px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}


.overlay-card {
  width: min(1580px, 100%);
  margin: auto;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(12, 13, 16, 0.94);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
  padding: 34px;
  animation: overlay-card-in 520ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.overlay-title {
  margin: 0 0 28px;
  color: #19c8ff;
  font-size: 56px;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1;
  text-transform: uppercase;
  animation: overlay-title-in 620ms 120ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

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

.table th,
.table td {
  padding: 12px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.13);
  text-align: left;
}

.table th {
  color: var(--muted);
  font-size: 14px;
  text-transform: uppercase;
}

.positioned-scene,
.scoreboard-scene {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  min-height: 0;
  display: flex;
  padding: 42px 48px;
  background: transparent;
  pointer-events: none;
}

.position-bottom-left {
  align-items: flex-end;
  justify-content: flex-start;
}

.position-bottom-center {
  align-items: flex-end;
  justify-content: center;
}

.position-bottom-right {
  align-items: flex-end;
  justify-content: flex-end;
}

.position-top,
.position-top-center {
  align-items: flex-start;
  justify-content: center;
}

.position-top-left {
  align-items: flex-start;
  justify-content: flex-start;
}

.position-top-right {
  align-items: flex-start;
  justify-content: flex-end;
}

.scorebug {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 128px 166px 128px minmax(220px, 1fr);
  align-items: stretch;
  width: min(1120px, calc(100vw - 96px));
  min-height: 112px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
  animation: scorebug-in 520ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.scorebug.no-timer {
  grid-template-columns: minmax(260px, 1fr) 150px 150px minmax(260px, 1fr);
}

.team {
  display: grid;
  align-content: center;
  padding: 18px 22px;
  background: rgba(17, 19, 24, 0.9);
  animation: score-piece-in 460ms 90ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.team.away {
  text-align: right;
  animation-delay: 210ms;
}

.team b {
  font-size: 28px;
  line-height: 1.05;
}

.score {
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #06100c;
  font-size: 58px;
  font-weight: 900;
  animation: score-piece-in 420ms 150ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.timer {
  display: grid;
  place-items: center;
  background: rgba(255, 202, 58, 0.94);
  color: #171204;
  font-size: 34px;
  font-weight: 900;
  animation: score-piece-in 420ms 180ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.lower-third {
  display: grid;
  grid-template-columns: 12px minmax(260px, 620px);
  align-items: stretch;
  width: min(680px, calc(100vw - 72px));
  min-height: 108px;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(12, 13, 16, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.45);
  animation: scorebug-in 520ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.lower-third-accent {
  background: linear-gradient(180deg, var(--accent), var(--blue));
}

.lower-third > div:last-child {
  display: grid;
  align-content: center;
  gap: 8px;
  min-width: 0;
  padding: 20px 28px;
}

.lower-third-title {
  color: var(--text);
  font-size: 36px;
  font-weight: 950;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.lower-third-subtitle {
  color: var(--accent-2);
  font-size: 22px;
  font-weight: 850;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.period {
  color: var(--accent-2);
  font-weight: 800;
  text-transform: uppercase;
}

.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.overlay-stack {
  display: grid;
  gap: 24px;
}

.overlay-section {
  display: grid;
  gap: 16px;
}

.info-timer {
  justify-self: start;
  min-width: 210px;
  border: 1px solid rgba(255, 202, 58, 0.38);
  border-radius: 8px;
  background: rgba(255, 202, 58, 0.94);
  color: #171204;
  padding: 14px 24px;
  text-align: center;
  font-size: 48px;
  font-weight: 950;
  line-height: 1;
}

.section-heading {
  color: var(--text);
  font-size: 30px;
  font-weight: 900;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--blue);
}

.groups-showcase {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
  gap: 24px;
}

.groups-showcase.single {
  grid-template-columns: minmax(420px, 780px);
  justify-content: center;
}

.groups-showcase.mini {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
}

.group-showcase-card {
  min-height: 300px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(50, 210, 150, 0.16), rgba(91, 188, 255, 0.08) 42%, rgba(255, 255, 255, 0.045));
  padding: 26px 30px;
  animation: overlay-item-in 480ms 160ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.group-showcase-card.compact {
  min-height: 0;
}

.group-showcase-card.standings-card {
  min-height: 270px;
  padding-bottom: 28px;
}

.group-showcase-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
  padding-bottom: 14px;
  border-bottom: 3px solid var(--blue);
}

.group-showcase-head h2 {
  margin: 0;
  font-size: 42px;
  line-height: 1;
}

.team-pill-list {
  display: grid;
  gap: 12px;
}

.team-pill {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 52px;
  border-radius: 7px;
  background: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 8px 0 13px;
  font-size: 26px;
  font-weight: 750;
  animation: overlay-item-in 420ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.team-pill span {
  display: grid;
  place-items: center;
  width: 30px;
  color: var(--muted);
  font-size: 24px;
  font-weight: 800;
}

.standings-showcase {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.standings-table {
  display: grid;
  gap: 0;
}

.standings-grid {
  display: grid;
  grid-template-columns: 50px minmax(150px, 1fr) repeat(3, 56px) 68px 62px;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  column-gap: 8px;
}

.standings-labels {
  min-height: 36px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 900;
  text-transform: uppercase;
}

.standings-entry {
  color: var(--text);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 21px;
  animation: overlay-item-in 420ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.standings-entry.is-top {
  background: rgba(91, 188, 255, 0.12);
}

.standings-entry:nth-child(3).is-top {
  background: rgba(91, 188, 255, 0.17);
}

.rank,
.points-cell {
  color: #19d4ff;
  font-weight: 950;
}

.team-cell {
  font-weight: 900;
}

.points-cell {
  text-align: center;
}

.message-standings {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.broadcast-list {
  display: grid;
  gap: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(50, 210, 150, 0.13), rgba(91, 188, 255, 0.07) 46%, rgba(255, 255, 255, 0.04));
}

.broadcast-row {
  display: grid;
  align-items: center;
  min-height: 68px;
  gap: 18px;
  padding: 14px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 24px;
  animation: overlay-item-in 420ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

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

.match-row {
  grid-template-columns: minmax(80px, 120px) minmax(230px, 1fr) minmax(210px, 300px) 190px;
}

.standings-head,
.standings-row {
  grid-template-columns: 58px minmax(280px, 1fr) repeat(4, 76px) 110px;
}

.standings-head {
  min-height: 46px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 900;
  text-transform: uppercase;
}

.row-kicker {
  color: var(--muted);
  font-weight: 850;
}

.row-main {
  color: var(--text);
  font-weight: 850;
  min-width: 0;
}

.row-main span,
.row-meta {
  color: var(--muted);
  font-weight: 700;
  min-width: 0;
}

.row-meta {
  overflow-wrap: anywhere;
}

.row-score {
  color: var(--accent-2);
  font-size: 30px;
  font-weight: 950;
  text-align: left;
  min-width: 0;
  overflow-wrap: anywhere;
}

.message-panel {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(50, 210, 150, 0.16), rgba(91, 188, 255, 0.08) 42%, rgba(255, 255, 255, 0.045));
  padding: 28px 30px;
  font-size: 34px;
  font-weight: 750;
  line-height: 1.28;
}

.advertising-scene {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  width: 100vw;
  height: 100vh;
  background: #050608;
  overflow: hidden;
}

.advertising-media {
  position: relative;
  min-width: 0;
  min-height: 0;
  background: #000;
}

.advertising-media iframe,
.advertising-media video {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  object-fit: contain;
  background: #000;
}

.advertising-caption {
  position: absolute;
  left: 36px;
  right: 36px;
  bottom: 32px;
  display: flex;
  justify-content: flex-start;
  pointer-events: none;
}

.advertising-caption > div {
  max-width: min(760px, calc(100vw - 72px));
  border-left: 8px solid var(--accent-2);
  border-radius: 8px;
  background: rgba(12, 13, 16, 0.9);
  padding: 16px 22px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
  animation: scorebug-in 520ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.advertising-caption span {
  display: block;
  color: var(--accent-2);
  font-size: 14px;
  font-weight: 950;
  text-transform: uppercase;
}

.advertising-caption b {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 34px;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.advertising-caption p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 18px;
  font-weight: 750;
}

.advertising-banner-scene {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 100vw;
  height: 100vh;
  padding: 42px 48px;
  background: transparent;
  pointer-events: none;
}

.advertising-banner {
  display: grid;
  grid-template-columns: auto minmax(240px, 760px);
  align-items: center;
  gap: 18px;
  max-width: min(980px, calc(100vw - 96px));
  min-height: 112px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-left: 9px solid var(--accent-2);
  border-radius: 8px;
  background: rgba(12, 13, 16, 0.93);
  padding: 18px 24px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
  animation: scorebug-in 520ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.advertising-banner img {
  width: 92px;
  height: 92px;
  border-radius: 7px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.08);
}

.advertising-banner div {
  min-width: 0;
}

.advertising-banner span {
  display: block;
  color: var(--accent-2);
  font-size: 15px;
  font-weight: 950;
  text-transform: uppercase;
}

.advertising-banner b {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 36px;
  line-height: 1.04;
  overflow-wrap: anywhere;
}

.advertising-banner p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 20px;
  font-weight: 750;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.sponsor-rotation-layer {
  position: fixed;
  left: 48px;
  right: 48px;
  bottom: 78px;
  z-index: 20;
  display: flex;
  justify-content: center;
  pointer-events: none;
}

.broadcast-ticker {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;
  overflow: hidden;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(12, 13, 16, 0.94);
  color: var(--text);
  pointer-events: none;
}

.broadcast-ticker div {
  width: max-content;
  min-width: 100%;
  padding: 12px 24px;
  color: var(--accent-2);
  font-size: 24px;
  font-weight: 900;
  white-space: nowrap;
  animation: ticker-scroll 24s linear infinite;
}

@keyframes ticker-scroll {
  from {
    transform: translateX(100vw);
  }
  to {
    transform: translateX(-100%);
  }
}

.silent-alert {
  position: fixed;
  top: 70px;
  left: 50%;
  z-index: 30;
  min-width: min(620px, calc(100vw - 80px));
  transform: translateX(-50%);
  border: 2px solid rgba(255, 202, 58, 0.5);
  border-radius: 8px;
  background: rgba(12, 13, 16, 0.92);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
  padding: 18px 28px;
  text-align: center;
  pointer-events: none;
  animation: silent-alert-pop 6.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.silent-alert span {
  display: block;
  color: var(--accent-2);
  font-size: 16px;
  font-weight: 950;
  text-transform: uppercase;
}

.silent-alert b {
  display: block;
  margin-top: 6px;
  color: var(--text);
  font-size: 46px;
  line-height: 1;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.silent-alert.matchball {
  border-color: rgba(255, 93, 93, 0.72);
}

.silent-alert.matchball span {
  color: var(--danger);
}

.silent-alert.setball {
  border-color: rgba(91, 188, 255, 0.72);
}

.silent-alert.setball span {
  color: var(--blue);
}

@keyframes silent-alert-pop {
  0% {
    opacity: 0;
    transform: translate(-50%, -18px) scale(0.96);
  }
  10%,
  82% {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -14px) scale(0.98);
  }
}

.bracket-tree {
  position: relative;
  display: grid;
  grid-template-columns: 1.2fr 1.1fr 1.05fr 1fr;
  gap: 38px;
  min-height: 0;
  height: min(820px, calc(100vh - 200px));
}

.bracket-column {
  position: relative;
  display: grid;
  grid-template-rows: 54px repeat(8, 1fr);
  gap: 0;
}

.bracket-round-title {
  align-self: start;
  color: var(--muted);
  font-size: 18px;
  font-weight: 950;
  text-transform: uppercase;
}

.tree-match {
  position: relative;
  z-index: 1;
  align-self: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(50, 210, 150, 0.16), rgba(91, 188, 255, 0.08) 46%, rgba(255, 255, 255, 0.045));
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.22);
  overflow: visible;
  animation: overlay-item-in 460ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.tree-match::after {
  display: none;
}

.semi-column .tree-match::before,
.final-column .tree-match::before {
  display: none;
}

.final-column .tree-match::after,
.podium-column .tree-match::after {
  display: none;
}

.tree-match.slot-1 {
  grid-row: 2 / span 1;
}

.tree-match.slot-2 {
  grid-row: 4 / span 1;
}

.tree-match.slot-3 {
  grid-row: 6 / span 1;
}

.tree-match.slot-4 {
  grid-row: 8 / span 1;
}

.semi-column .tree-match.slot-1 {
  grid-row: 3 / span 1;
}

.semi-column .tree-match.slot-2 {
  grid-row: 7 / span 1;
}

.final-column .tree-match {
  grid-row: 5 / span 1;
}

.podium-column .winner-card {
  grid-row: 3 / span 2;
}

.podium-column .tree-match {
  grid-row: 7 / span 1;
}

.connector {
  display: none;
}

.quarter-column .pair-a {
  top: calc(54px + (100% - 54px) * 0.0625);
  height: calc((100% - 54px) * 0.25);
}

.quarter-column .pair-b {
  top: calc(54px + (100% - 54px) * 0.5625);
  height: calc((100% - 54px) * 0.25);
}

.semi-column .final-link {
  top: calc(54px + (100% - 54px) * 0.1875);
  height: calc((100% - 54px) * 0.5);
}

.match-label {
  padding: 8px 14px 6px;
  color: #19d4ff;
  font-size: 13px;
  font-weight: 950;
  text-transform: uppercase;
}

.tree-team {
  display: flex;
  align-items: center;
  min-height: 36px;
  padding: 6px 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text);
  font-size: 20px;
  font-weight: 850;
}

.tree-score {
  position: absolute;
  right: 12px;
  bottom: 9px;
  min-width: 58px;
  border: 1px solid rgba(255, 202, 58, 0.35);
  border-radius: 7px;
  background: rgba(255, 202, 58, 0.94);
  color: #171204;
  padding: 3px 9px;
  text-align: center;
  font-size: 18px;
  font-weight: 950;
}

.tree-match.featured {
  transform: scale(1.04);
  border-color: rgba(25, 212, 255, 0.55);
}

.winner-card {
  align-self: center;
  border: 1px solid rgba(255, 202, 58, 0.4);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(255, 202, 58, 0.24), rgba(50, 210, 150, 0.12));
  padding: 24px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.24);
  animation: overlay-item-in 520ms 280ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.winner-card span {
  display: block;
  color: var(--accent-2);
  font-size: 16px;
  font-weight: 950;
  text-transform: uppercase;
}

.winner-card b {
  display: block;
  margin-top: 8px;
  color: var(--text);
  font-size: 34px;
  line-height: 1;
}

.group-showcase-card:nth-child(2),
.broadcast-row:nth-child(2),
.team-pill:nth-child(2),
.standings-entry:nth-child(3),
.tree-match:nth-of-type(2) {
  animation-delay: 220ms;
}

.group-showcase-card:nth-child(3),
.broadcast-row:nth-child(3),
.team-pill:nth-child(3),
.standings-entry:nth-child(4),
.tree-match:nth-of-type(3) {
  animation-delay: 280ms;
}

.group-showcase-card:nth-child(4),
.broadcast-row:nth-child(4),
.team-pill:nth-child(4),
.standings-entry:nth-child(5),
.tree-match:nth-of-type(4) {
  animation-delay: 340ms;
}

.group-showcase-card:nth-child(5),
.broadcast-row:nth-child(5),
.team-pill:nth-child(5),
.standings-entry:nth-child(6),
.tree-match:nth-of-type(5) {
  animation-delay: 400ms;
}

.group-showcase-card:nth-child(n + 6),
.broadcast-row:nth-child(n + 6),
.team-pill:nth-child(n + 6),
.standings-entry:nth-child(n + 7),
.tree-match:nth-of-type(n + 6) {
  animation-delay: 460ms;
}

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

@media (max-width: 950px) {
  .panel,
  .panel.wide,
  .control-panel,
  .user-panel,
  .scoreboard-panel,
  .info-panel,
  .lower-third-panel,
  .ads-panel,
  .schedule-panel,
  .past-panel,
  .groups-panel,
  .teams-panel,
  .standings-admin-panel {
    grid-column: 1 / -1;
  }

  .scorebug,
  .user-row,
  .match-row,
  .standings-head,
  .standings-row {
    grid-template-columns: 1fr;
  }

  .user-password-form input {
    width: 100%;
  }

  .bracket-tree {
    grid-template-columns: 1fr;
    gap: 22px;
    min-height: 0;
  }

  .bracket-column {
    grid-template-rows: auto;
    gap: 14px;
  }

  .tree-match,
  .tree-match.slot-1,
  .tree-match.slot-2,
  .tree-match.slot-3,
  .tree-match.slot-4,
  .semi-column .tree-match.slot-1,
  .semi-column .tree-match.slot-2,
  .final-column .tree-match,
  .podium-column .winner-card,
  .podium-column .tree-match {
    grid-row: auto;
  }

  .tree-match::after,
  .tree-match::before,
  .connector {
    display: none;
  }

  .two-col,
  .groups-showcase,
  .standings-showcase {
    grid-template-columns: 1fr;
  }

  .standings-grid {
    grid-template-columns: 34px minmax(95px, 1fr) repeat(3, 34px) 42px 42px;
    padding: 0 12px;
    column-gap: 5px;
    font-size: 15px;
  }

  .admin-standings-grid {
    grid-template-columns: 34px minmax(95px, 1fr) repeat(3, 34px) 42px 42px;
    padding: 0 10px;
    gap: 5px;
    font-size: 13px;
  }

  .scorebug {
    max-width: 520px;
  }

  .positioned-scene,
  .scoreboard-scene {
    padding: 20px;
  }

  .lower-third {
    width: min(520px, calc(100vw - 40px));
    min-height: 92px;
  }

  .lower-third-title {
    font-size: 28px;
  }

  .lower-third-subtitle {
    font-size: 18px;
  }

  .info-timer {
    width: 100%;
    min-width: 0;
    font-size: 36px;
  }

  .overlay-root {
    padding: 20px;
  }

  .advertising-caption {
    left: 20px;
    right: 20px;
    bottom: 20px;
  }

  .advertising-caption > div {
    max-width: calc(100vw - 40px);
  }

  .advertising-caption b {
    font-size: 26px;
  }

  .advertising-banner-scene {
    padding: 20px;
  }

  .advertising-banner {
    grid-template-columns: auto minmax(0, 1fr);
    max-width: calc(100vw - 40px);
    min-height: 88px;
    padding: 14px 16px;
  }

  .advertising-banner img {
    width: 64px;
    height: 64px;
  }

  .advertising-banner b {
    font-size: 25px;
  }

  .advertising-banner p {
    font-size: 16px;
  }

  .sponsor-rotation-layer {
    left: 20px;
    right: 20px;
    bottom: 64px;
  }

  .broadcast-ticker div {
    padding: 10px 18px;
    font-size: 17px;
  }

  .silent-alert {
    top: 36px;
    min-width: calc(100vw - 40px);
    padding: 14px 18px;
  }

  .silent-alert b {
    font-size: 30px;
  }
}
