:root {
  --bg: #061116;
  --panel: #0d2028;
  --panel-2: #122d36;
  --line: rgba(255, 255, 255, 0.13);
  --text: #f7fbfc;
  --muted: rgba(247, 251, 252, 0.66);
  --teal: #0db7b2;
  --lime: #b8ef45;
  --amber: #f4b544;
  --danger: #ef654f;
  --blue: #2a78ff;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 80% 0%, rgba(184, 239, 69, 0.18), transparent 34%),
    linear-gradient(135deg, #061116, #102b34 58%, #07151b);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button,
input,
select {
  font: inherit;
}

.tracker-shell {
  width: min(1480px, 100%);
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 14px;
  margin: 0 auto;
  padding: 18px;
}

.tracker-header,
.scoreboard,
.pitch-panel,
.side-panel section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(13, 32, 40, 0.86);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(14px);
}

.tracker-header {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #061116;
  background: linear-gradient(135deg, var(--lime), var(--teal));
  font-weight: 950;
}

.brand strong,
.brand span {
  display: block;
}

.brand span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.tracker-controls {
  display: grid;
  grid-template-columns: minmax(105px, 130px) minmax(90px, 110px) minmax(180px, 250px) minmax(140px, 175px) minmax(115px, 135px) auto;
  gap: 10px;
  align-items: end;
}

.tracker-controls label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.tracker-controls input,
.tracker-controls select,
.tracker-controls button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 10px;
}

.tracker-controls input,
.tracker-controls select {
  min-width: 0;
  color: var(--text);
  background-color: #132c35;
}

.tracker-controls select {
  color-scheme: dark;
  cursor: pointer;
}

.tracker-controls select option {
  color: #f7fbfc;
  background-color: #102832;
}

.tracker-controls select option:checked {
  color: #061116;
  background-color: var(--lime);
  font-weight: 900;
}

.language-control select {
  font-weight: 850;
}

.tracker-controls input:focus,
.tracker-controls select:focus {
  outline: 2px solid var(--lime);
  outline-offset: 2px;
  border-color: var(--lime);
}

.tracker-controls select:hover {
  border-color: rgba(184, 239, 69, 0.72);
}

.tracker-controls button {
  color: #061116;
  background: var(--lime);
  font-weight: 950;
  cursor: pointer;
}

body.embed .tracker-controls {
  display: none;
}

.scoreboard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 240px) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 14px;
}

.team {
  min-width: 0;
}

.team.away {
  text-align: right;
}

.team span,
.score span,
.score em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
  text-transform: uppercase;
}

.team strong {
  display: block;
  min-width: 0;
  overflow: hidden;
  margin-top: 4px;
  color: #ffffff;
  font-size: clamp(20px, 3vw, 34px);
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.score strong {
  color: var(--lime);
  font-size: clamp(34px, 6vw, 64px);
  line-height: 1;
}

.tracker-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.38fr) minmax(340px, 0.62fr);
  gap: 14px;
}

.pitch-panel {
  display: grid;
  grid-template-rows: minmax(420px, 1fr) auto auto;
  gap: 12px;
  min-height: 0;
  padding: 14px;
}

.danger-banner {
  --action-color: var(--blue);
  min-height: 54px;
  display: grid;
  grid-template-columns: minmax(130px, 0.42fr) minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-left: 5px solid var(--action-color);
  border-radius: 6px;
  padding: 8px 14px;
  color: var(--text);
  background: rgba(6, 17, 22, 0.96);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.24);
}

.danger-banner[data-team="away"] {
  --action-color: var(--amber);
}

.danger-banner span,
.danger-banner strong,
.danger-banner em {
  min-width: 0;
}

.danger-banner span {
  overflow: hidden;
  color: var(--action-color);
  font-size: 13px;
  font-weight: 950;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.danger-banner strong {
  overflow: hidden;
  color: #ffffff;
  font-size: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.danger-banner em {
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 5px 7px;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.danger-banner.danger {
  --action-color: var(--danger);
  background: rgba(43, 17, 17, 0.96);
}

.danger-banner.score-event {
  --action-color: var(--lime);
  background: rgba(16, 37, 23, 0.98);
  box-shadow: 0 0 0 1px rgba(184, 239, 69, 0.72), 0 0 28px rgba(184, 239, 69, 0.42);
  animation: scoreEventPulse 0.72s ease-in-out infinite alternate;
}

@keyframes scoreEventPulse {
  from { transform: scale(1); filter: brightness(1); }
  to { transform: scale(1.012); filter: brightness(1.12); }
}

.pitch {
  position: relative;
  min-height: 420px;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(255, 255, 255, 0.52);
  border-radius: 8px;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.18),
    inset 0 28px 80px rgba(255, 255, 255, 0.08),
    inset 0 -40px 90px rgba(0, 0, 0, 0.22),
    0 28px 80px rgba(0, 0, 0, 0.34);
  background:
    radial-gradient(circle at 72% 24%, rgba(184, 239, 69, 0.16), transparent 23%),
    linear-gradient(90deg, transparent 49.8%, rgba(255, 255, 255, 0.72) 49.8% 50.2%, transparent 50.2%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 9%),
    repeating-linear-gradient(90deg, #12603f 0 8.33%, #1d7a51 8.33% 16.66%);
}

.three-stage {
  position: absolute;
  z-index: 6;
  inset: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 26%, rgba(255, 255, 255, 0.1), transparent 26%),
    linear-gradient(180deg, rgba(7, 17, 24, 0.24), rgba(2, 6, 9, 0.82));
  transition: opacity 0.22s ease;
}

.three-stage canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.field-scoreboard {
  position: absolute;
  z-index: 9;
  top: 12px;
  left: 50%;
  width: min(620px, calc(100% - 28px));
  min-height: 42px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  opacity: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-top: 3px solid var(--lime);
  border-radius: 5px;
  padding: 6px 10px;
  color: #ffffff;
  background: rgba(5, 15, 20, 0.94);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.34);
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 0.2s ease;
}

body.view-3d .field-scoreboard {
  opacity: 1;
}

.field-scoreboard span {
  min-width: 0;
  overflow: hidden;
  font-size: 12px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.field-scoreboard span:nth-of-type(2) {
  text-align: right;
}

.field-scoreboard strong {
  color: var(--lime);
  font-size: 20px;
}

.field-scoreboard em {
  border-left: 1px solid var(--line);
  padding-left: 10px;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  text-transform: uppercase;
}

body.view-3d .pitch {
  border-color: rgba(255, 255, 255, 0.2);
  background: #050b10;
}

body.view-3d .three-stage {
  opacity: 1;
  pointer-events: auto;
}

body.view-3d .pitch::before,
body.view-3d .pitch::after,
body.view-3d .pitch-zone,
body.view-3d .center-circle,
body.view-3d .box,
body.view-3d .danger-zone,
body.view-3d .ball,
body.view-3d #playersLayer,
body.view-3d #shotsLayer {
  opacity: 0;
  visibility: hidden;
}

.pitch::before {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 50% auto auto 50%;
  width: min(22vw, 150px);
  height: min(22vw, 150px);
  border: 2px solid rgba(255, 255, 255, 0.68);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.pitch::after {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.14), transparent 34%),
    radial-gradient(circle at 50% 50%, transparent 0 54%, rgba(0, 0, 0, 0.2) 100%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 18px);
  mix-blend-mode: soft-light;
}

.pitch.sport-basketball {
  border-color: rgba(255, 247, 227, 0.62);
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.15), transparent 16%),
    linear-gradient(90deg, transparent 49.82%, rgba(105, 58, 24, 0.58) 49.82% 50.18%, transparent 50.18%),
    repeating-linear-gradient(0deg, rgba(95, 53, 24, 0.32) 0 1px, transparent 1px 38px),
    repeating-linear-gradient(90deg, rgba(255, 236, 188, 0.24) 0 1px, transparent 1px 72px),
    linear-gradient(90deg, #c27a34, #e0aa63 22%, #c9863e 49%, #e0aa63 78%, #bd7431);
}

.pitch.sport-basketball::before {
  width: min(20vw, 136px);
  height: min(20vw, 136px);
  border-color: rgba(89, 45, 18, 0.64);
  background: rgba(255, 255, 255, 0.05);
}

.pitch.sport-basketball::after {
  inset: 0;
  background:
    radial-gradient(circle at 7% 50%, transparent 0 13%, rgba(83, 42, 17, 0.52) 13% 13.5%, transparent 13.8%),
    radial-gradient(circle at 93% 50%, transparent 0 13%, rgba(83, 42, 17, 0.52) 13% 13.5%, transparent 13.8%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.22), transparent 30%),
    radial-gradient(circle at 50% 50%, transparent 0 58%, rgba(60, 30, 12, 0.2) 100%);
  mix-blend-mode: multiply;
}

.pitch.sport-tennis {
  border-color: rgba(255, 255, 255, 0.7);
  background:
    radial-gradient(circle at 50% 50%, rgba(99, 209, 255, 0.16), transparent 24%),
    linear-gradient(90deg, transparent 49.65%, rgba(255, 255, 255, 0.86) 49.65% 50.35%, transparent 50.35%),
    linear-gradient(180deg, #17765f 0 13%, #236fca 13% 87%, #17765f 87% 100%);
}

.pitch.sport-tennis::before {
  inset: 18% auto auto 50%;
  width: 0;
  height: 64%;
  border: 0;
  border-left: 4px solid rgba(255, 255, 255, 0.82);
  border-radius: 0;
  transform: translateX(-50%);
}

.pitch.sport-tennis::after {
  inset: 24% 8%;
  border-top: 2px solid rgba(255, 255, 255, 0.82);
  border-bottom: 2px solid rgba(255, 255, 255, 0.82);
  background:
    linear-gradient(90deg, transparent 49.7%, rgba(255, 255, 255, 0.76) 49.7% 50.3%, transparent 50.3%),
    linear-gradient(180deg, transparent 49.4%, rgba(255, 255, 255, 0.76) 49.4% 50.6%, transparent 50.6%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.18), transparent 36%);
  mix-blend-mode: normal;
}

.pitch-zone,
.center-circle,
.box,
.danger-zone {
  pointer-events: none;
  position: absolute;
}

.pitch-zone {
  z-index: 1;
  inset: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 6px;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 0 80px rgba(0, 0, 0, 0.12);
}

.center-circle {
  z-index: 2;
  inset: 50% auto auto 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 0 18px rgba(255, 255, 255, 0.42);
  transform: translate(-50%, -50%);
}

.box {
  z-index: 2;
  top: 25%;
  width: 17%;
  height: 50%;
  border: 2px solid rgba(255, 255, 255, 0.58);
}

.box::before,
.box::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.box.left {
  left: -2px;
  border-left: 0;
}

.box.right {
  right: -2px;
  border-right: 0;
}

.pitch.sport-soccer .box::before {
  top: 23%;
  width: 42%;
  height: 54%;
  border: 2px solid rgba(255, 255, 255, 0.42);
}

.pitch.sport-soccer .box.left::before {
  left: -2px;
  border-left: 0;
}

.pitch.sport-soccer .box.right::before {
  right: -2px;
  border-right: 0;
}

.pitch.sport-soccer .box::after {
  top: 50%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.78);
  transform: translateY(-50%);
}

.pitch.sport-soccer .box.left::after {
  right: 22%;
}

.pitch.sport-soccer .box.right::after {
  left: 22%;
}

.pitch.sport-basketball .box {
  top: 24%;
  width: 18%;
  height: 52%;
  border-color: rgba(79, 48, 22, 0.5);
  background: rgba(89, 45, 18, 0.12);
}

.pitch.sport-basketball .box.left {
  border-radius: 0 64px 64px 0;
}

.pitch.sport-basketball .box.right {
  border-radius: 64px 0 0 64px;
}

.pitch.sport-basketball .box::before {
  top: 50%;
  width: 15px;
  height: 15px;
  border: 3px solid rgba(255, 246, 220, 0.86);
  border-radius: 50%;
  transform: translateY(-50%);
}

.pitch.sport-basketball .box.left::before {
  left: 7px;
}

.pitch.sport-basketball .box.right::before {
  right: 7px;
}

.pitch.sport-basketball .box::after {
  top: 19%;
  width: 62%;
  height: 62%;
  border: 2px solid rgba(89, 45, 18, 0.45);
  border-radius: 50%;
}

.pitch.sport-basketball .box.left::after {
  right: -30%;
}

.pitch.sport-basketball .box.right::after {
  left: -30%;
}

.pitch.sport-tennis .box {
  top: 24%;
  width: 42%;
  height: 52%;
  border-color: rgba(255, 255, 255, 0.72);
}

.pitch.sport-tennis .box.left {
  left: 8%;
  border-left: 2px solid rgba(255, 255, 255, 0.72);
}

.pitch.sport-tennis .box.right {
  right: 8%;
  border-right: 2px solid rgba(255, 255, 255, 0.72);
}

.pitch.sport-tennis .box::before {
  top: 0;
  bottom: 0;
  left: 50%;
  border-left: 2px solid rgba(255, 255, 255, 0.72);
}

.danger-zone {
  z-index: 2;
  top: 15%;
  width: 30%;
  height: 70%;
  opacity: 0;
  border: 1px solid rgba(255, 214, 112, 0.34);
  background:
    linear-gradient(90deg, rgba(239, 101, 79, 0.36), rgba(244, 181, 68, 0.18)),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 10px);
  box-shadow:
    inset 0 0 58px rgba(239, 101, 79, 0.6),
    0 0 36px rgba(239, 101, 79, 0.24);
  transition: opacity 0.25s ease;
}

.danger-zone.active {
  opacity: 1;
  animation: dangerPulse 1.8s ease-in-out infinite;
}

.danger-zone.left {
  left: 0;
}

.danger-zone.right {
  right: 0;
}

.pitch.sport-basketball .danger-zone {
  top: 20%;
  width: 28%;
  height: 60%;
}

.pitch.sport-tennis .danger-zone {
  top: 24%;
  width: 42%;
  height: 52%;
}

.ball,
.player,
.shot {
  position: absolute;
  display: block;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.ball {
  z-index: 5;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(6, 17, 22, 0.22);
  background:
    radial-gradient(circle at 34% 30%, #ffffff 0 18%, #eaf2f4 19% 54%, #bbc8cc 55% 100%);
  box-shadow:
    0 0 0 8px rgba(255, 255, 255, 0.14),
    0 0 30px rgba(184, 239, 69, 0.82),
    0 14px 18px rgba(0, 0, 0, 0.32);
  transition: left 0.35s ease, top 0.35s ease;
  animation: demoBallTravel 3.6s ease-in-out infinite;
}

.pitch.sport-basketball .ball {
  border-color: rgba(89, 45, 18, 0.36);
  background:
    linear-gradient(90deg, transparent 47%, rgba(80, 36, 14, 0.56) 47% 53%, transparent 53%),
    radial-gradient(circle at 32% 28%, #ffb35b 0 24%, #dc6f24 25% 100%);
  box-shadow:
    0 0 0 8px rgba(255, 179, 91, 0.16),
    0 0 28px rgba(255, 179, 91, 0.72),
    0 14px 18px rgba(0, 0, 0, 0.32);
}

.pitch.sport-tennis .ball {
  width: 17px;
  height: 17px;
  border-color: rgba(6, 17, 22, 0.18);
  background:
    radial-gradient(circle at 35% 30%, #f6ff7a 0 24%, #c9ee37 25% 100%);
  box-shadow:
    0 0 0 8px rgba(201, 238, 55, 0.16),
    0 0 28px rgba(201, 238, 55, 0.8),
    0 12px 16px rgba(0, 0, 0, 0.28);
}

.player {
  z-index: 4;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  box-shadow:
    0 8px 16px rgba(0, 0, 0, 0.3),
    inset 0 2px 5px rgba(255, 255, 255, 0.22);
}

.player:nth-child(3n + 1) {
  animation: demoPlayerMoveA 3.2s ease-in-out infinite alternate;
}

.player:nth-child(3n + 2) {
  animation: demoPlayerMoveB 4.1s ease-in-out infinite alternate;
}

.player:nth-child(3n) {
  animation: demoPlayerMoveC 3.7s ease-in-out infinite alternate;
}

@keyframes demoBallTravel {
  0%, 100% { transform: translate(-50%, -50%) translate(-8px, 5px) scale(1); }
  35% { transform: translate(-50%, -50%) translate(24px, -10px) scale(1.14); }
  68% { transform: translate(-50%, -50%) translate(-18px, -18px) scale(0.94); }
}

@keyframes demoPlayerMoveA {
  from { transform: translate(-50%, -50%) translate(-5px, 3px); }
  to { transform: translate(-50%, -50%) translate(14px, -9px); }
}

@keyframes demoPlayerMoveB {
  from { transform: translate(-50%, -50%) translate(7px, -8px); }
  to { transform: translate(-50%, -50%) translate(-13px, 10px); }
}

@keyframes demoPlayerMoveC {
  from { transform: translate(-50%, -50%) translate(-9px, -5px); }
  to { transform: translate(-50%, -50%) translate(11px, 8px); }
}

.player.home {
  background: var(--blue);
}

.player.away {
  background: var(--amber);
}

.shot {
  z-index: 3;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.9);
  background: rgba(239, 101, 79, 0.86);
  box-shadow:
    0 0 0 5px rgba(239, 101, 79, 0.16),
    0 0 22px rgba(239, 101, 79, 0.52);
}

.shot.goal {
  background: var(--lime);
}

.shot.three,
.shot.ace,
.shot.break {
  background: var(--lime);
}

.shot.free-throw,
.shot.point,
.shot.game {
  background: var(--amber);
}

.shot.double-fault,
.shot.turnover {
  background: var(--danger);
}

#playersLayer,
#shotsLayer {
  position: absolute;
  inset: 0;
  z-index: 3;
}

#shotsLayer {
  z-index: 4;
}

@keyframes dangerPulse {
  0%,
  100% {
    filter: saturate(1);
  }

  50% {
    filter: saturate(1.28) brightness(1.08);
  }
}

.pressure-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 120px;
  gap: 10px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.pressure-row span:last-child {
  text-align: right;
}

.pressure-track {
  height: 13px;
  overflow: hidden;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(42, 120, 255, 0.35), rgba(244, 181, 68, 0.35));
}

.pressure-track i {
  display: block;
  height: 100%;
  width: 50%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--teal), var(--lime));
  transition: width 0.25s ease;
}

.side-panel {
  min-height: 0;
  display: grid;
  gap: 14px;
}

.side-panel section {
  padding: 14px;
}

.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.panel-title h2 {
  margin: 0;
  color: #ffffff;
  font-size: 18px;
}

.risk-badge,
#quoteLock,
#eventCount {
  border-radius: 999px;
  padding: 5px 9px;
  color: #061116;
  background: var(--lime);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.risk-badge.medium {
  background: var(--amber);
}

.risk-badge.high {
  color: #ffffff;
  background: var(--danger);
}

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

.stat-grid div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.06);
}

.stat-grid strong,
.stat-grid span {
  display: block;
}

.stat-grid strong {
  color: #ffffff;
  font-size: 26px;
}

.stat-grid span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.timeline {
  max-height: 250px;
  overflow: auto;
  display: grid;
  gap: 8px;
}

.event-item {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px;
  background: rgba(255, 255, 255, 0.06);
}

.event-item strong {
  color: var(--lime);
}

.event-item span {
  min-width: 0;
  overflow: hidden;
  color: #ffffff;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.event-item em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  text-transform: uppercase;
}

.risk-reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.risk-reasons span {
  border-radius: 999px;
  padding: 7px 9px;
  color: rgba(247, 251, 252, 0.82);
  background: rgba(255, 255, 255, 0.08);
  font-size: 12px;
  font-weight: 850;
}

.empty {
  color: var(--muted);
}

@media (max-width: 1040px) {
  .tracker-grid,
  .tracker-header {
    display: grid;
    grid-template-columns: 1fr;
  }

  .tracker-controls {
    grid-template-columns: 1fr 1fr;
  }
}

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

  .tracker-controls,
  .scoreboard,
  .pressure-row {
    grid-template-columns: 1fr;
  }

  .team,
  .team.away,
  .pressure-row span:last-child {
    text-align: center;
  }

  .pitch-panel {
    grid-template-rows: 320px auto auto;
  }

  .pitch {
    min-height: 320px;
  }

  .stat-grid {
    grid-template-columns: 1fr;
  }

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

  .danger-banner strong {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .field-scoreboard {
    top: 8px;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 7px;
    padding: 5px 8px;
  }

  .field-scoreboard em {
    display: none;
  }

  .field-scoreboard span {
    font-size: 10px;
  }
}
