:root {
  color-scheme: dark;
  --ink: #f4f7f2;
  --muted: #a8b3ad;
  --panel: #121820;
  --panel-2: #18222d;
  --line: rgba(255, 255, 255, 0.11);
  --green: #18a058;
  --field: #0f6c43;
  --field-dark: #0b4d33;
  --amber: #ffc857;
  --red: #ff6b6b;
  --blue: #62a9ff;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
}

:root[data-theme="light"] {
  color-scheme: light;
  --ink: #18212a;
  --muted: #5d6873;
  --panel: #ffffff;
  --panel-2: #f2f5f7;
  --line: rgba(25, 34, 43, 0.14);
  --green: #11814b;
  --field: #2f9b6b;
  --field-dark: #247a57;
  --amber: #b98218;
  --red: #c94b54;
  --blue: #2368ad;
  --shadow: 0 18px 44px rgba(33, 44, 54, 0.15);
}

:root[data-theme="colorblind"] {
  color-scheme: dark;
  --ink: #f7f8fb;
  --muted: #b8c0c9;
  --panel: #151923;
  --panel-2: #202637;
  --line: rgba(255, 255, 255, 0.14);
  --green: #009e73;
  --field: #2a6f86;
  --field-dark: #1e5264;
  --amber: #f0e442;
  --red: #d55e00;
  --blue: #56b4e9;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(120deg, rgba(16, 33, 42, 0.96), rgba(12, 18, 26, 0.98)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 42%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root[data-theme="light"] body {
  background:
    linear-gradient(120deg, rgba(246, 248, 250, 0.98), rgba(230, 236, 241, 0.96)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.5), transparent 46%);
}

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

button {
  cursor: pointer;
}

button:disabled,
input:disabled,
select:disabled {
  cursor: wait;
  opacity: 0.65;
}

.app-shell {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  min-height: 100vh;
}

.control-panel {
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 24px;
  background: rgba(14, 20, 28, 0.96);
  border-right: 1px solid var(--line);
}

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

.brand-row > div:last-child {
  min-width: 0;
}

.mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  color: var(--amber);
  background: #1e2a32;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.mark svg {
  width: 27px;
  height: 27px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
}

h1 {
  margin: 0;
  font-size: 18px;
  line-height: 1.15;
  max-width: 240px;
  overflow-wrap: anywhere;
}

h1 span {
  display: block;
  white-space: nowrap;
}

p {
  margin: 0;
}

#dataSource {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.tab {
  min-height: 38px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
  border: 0;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.tab:nth-child(4n) {
  border-right: 0;
}

.tab:nth-last-child(-n + 4) {
  border-bottom: 0;
}

.tab.active {
  color: #07130c;
  background: var(--amber);
  font-weight: 800;
}

.quick-search,
.preference-card,
.follow-card,
.model-lab {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.search-results {
  display: grid;
  gap: 6px;
}

.search-results:empty {
  display: none;
}

.search-results button {
  display: grid;
  gap: 3px;
  min-height: 44px;
  padding: 8px 10px;
  color: var(--ink);
  text-align: left;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.search-results span,
.search-empty {
  color: var(--muted);
  font-size: 12px;
}

.popular-teams {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.popular-teams button,
.group-switcher button,
.filter-tabs button,
.link-button {
  min-height: 32px;
  padding: 0 9px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.group-switcher button.active,
.filter-tabs button.active {
  color: #07130c;
  background: var(--amber);
  border-color: var(--amber);
}

.preference-card {
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

.preference-card .secondary {
  grid-column: 1 / -1;
  min-height: 38px;
}

.filter-tabs,
.group-switcher {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 1px;
  scrollbar-width: none;
}

.filter-tabs::-webkit-scrollbar,
.group-switcher::-webkit-scrollbar {
  display: none;
}

[data-field="scheduleQuick"] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.follow-head,
.model-lab-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.follow-head span,
.model-lab-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.link-button {
  min-height: 28px;
  color: var(--blue);
  background: transparent;
}

.favorite-grid {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: none;
}

.favorite-grid::-webkit-scrollbar {
  display: none;
}

.favorite-chip {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 9px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.favorite-chip.active {
  color: #07130c;
  background: var(--amber);
  border-color: var(--amber);
}

.favorite-chip input {
  width: 14px;
  min-height: 0;
  height: 14px;
  accent-color: var(--green);
}

.model-lab label:not(.switch) {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.model-lab input[type="range"] {
  padding: 0;
  min-height: 24px;
  accent-color: var(--amber);
}

.switch.compact {
  min-height: 34px;
}

.data-health {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.data-health-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.data-health-head span,
.data-health-meta,
.sync-hint {
  color: var(--muted);
  font-size: 12px;
}

.data-health-head span {
  font-weight: 800;
}

.data-health-head strong {
  min-width: 0;
  color: var(--amber);
  text-align: right;
  overflow-wrap: anywhere;
  font-size: 13px;
}

.data-health[data-state="fresh"] .data-health-head strong {
  color: #5ee081;
}

.data-health[data-state="idle"] .data-health-head strong {
  color: #5ee081;
}

.data-health[data-state="stale"] .data-health-head strong,
.data-health[data-state="bad"] .data-health-head strong {
  color: var(--red);
}

.data-health-meta {
  line-height: 1.45;
}

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

.sync-row select,
.sync-row button {
  min-height: 38px;
}

.sync-row button {
  min-width: 86px;
}

.sync-hint {
  min-height: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  line-height: 1.4;
}

.key-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.key-chip.ok {
  color: #5ee081;
  background: rgba(94, 224, 129, 0.1);
  border-color: rgba(94, 224, 129, 0.35);
}

.key-chip.off {
  color: var(--amber);
  background: rgba(255, 200, 87, 0.1);
  border-color: rgba(255, 200, 87, 0.35);
}

.key-chip.optional {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.045);
  border-color: var(--line);
}

.sync-hint[data-tone="good"] {
  color: #5ee081;
}

.sync-hint[data-tone="mixed"] {
  color: var(--muted);
}

.sync-hint[data-tone="bad"] {
  color: var(--red);
}

.sync-hint[data-tone="loading"] {
  color: var(--amber);
}

.auth-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.auth-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.auth-head span,
.auth-hint,
.auth-signed-in p {
  color: var(--muted);
  font-size: 12px;
}

.auth-head span {
  font-weight: 800;
}

.auth-head strong {
  color: #5ee081;
  text-align: right;
  font-size: 13px;
}

.auth-signed-out,
.auth-signed-in {
  display: grid;
  gap: 8px;
}

.auth-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.auth-actions .primary,
.auth-actions .secondary,
.auth-signed-in .secondary {
  min-height: 38px;
}

.auth-hint {
  line-height: 1.45;
}

.form-stack {
  display: grid;
  gap: 14px;
}

.field {
  display: grid;
  gap: 7px;
}

label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

select,
input,
textarea {
  width: 100%;
  color: var(--ink);
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  outline: none;
}

select,
input {
  min-height: 42px;
}

textarea {
  min-height: 86px;
  padding-top: 10px;
  resize: vertical;
}

select:focus,
input:focus,
textarea:focus {
  border-color: rgba(255, 200, 87, 0.78);
  box-shadow: 0 0 0 3px rgba(255, 200, 87, 0.15);
}

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

.switch {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 10px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
}

.switch input {
  width: 15px;
  height: 15px;
  min-height: 0;
  accent-color: var(--amber);
}

.button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.primary,
.secondary {
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 800;
}

.primary {
  color: #08120b;
  background: var(--green);
}

.secondary {
  color: var(--ink);
  background: transparent;
  border-color: var(--line);
}

.secondary.active {
  color: #07130c;
  background: var(--amber);
  border-color: var(--amber);
}

.status-line {
  margin-top: auto;
  min-height: 38px;
  display: flex;
  align-items: center;
  color: var(--muted);
  border-top: 1px solid var(--line);
  padding-top: 16px;
  font-size: 12px;
}

.workspace {
  min-width: 0;
  padding: 24px;
  display: grid;
  gap: 18px;
  align-content: start;
}

.stadium {
  min-height: 330px;
}

body[data-mode="scoremap"] .stadium {
  display: none;
}

body[data-mode="schedule"] .stadium {
  display: none;
}

.pitch {
  position: relative;
  min-height: 330px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  background:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.045) 0 70px, transparent 70px 140px),
    linear-gradient(135deg, var(--field), var(--field-dark));
}

.pitch::before,
.pitch::after {
  content: "";
  position: absolute;
  inset: 22px;
  border: 2px solid rgba(255, 255, 255, 0.58);
}

.pitch::after {
  inset: 52px auto 52px 50%;
  width: 0;
  border-left: 2px solid rgba(255, 255, 255, 0.58);
  border-right: 0;
  border-top: 0;
  border-bottom: 0;
}

.pitch-lines {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 108px;
  height: 108px;
  transform: translate(-50%, -50%);
  border: 2px solid rgba(255, 255, 255, 0.58);
  border-radius: 50%;
}

.scoreboard {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(680px, calc(100% - 48px));
  transform: translate(-50%, -50%);
  display: grid;
  gap: 16px;
  padding: 22px;
  background: rgba(13, 20, 27, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.44);
}

.score-status,
.score-note {
  color: var(--muted);
  text-align: center;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.score-note {
  letter-spacing: 0;
  font-weight: 600;
}

.score-teams {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}

.score-teams > div:not(.score-separator) {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
}

.score-teams > div:last-child {
  grid-template-columns: auto minmax(0, 1fr);
}

.score-teams span {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 24px;
  font-weight: 900;
}

.score-teams strong {
  font-size: clamp(50px, 7vw, 92px);
  line-height: 0.9;
  color: var(--amber);
  font-variant-numeric: tabular-nums;
}

.score-separator {
  text-align: center;
  color: var(--muted);
  font-size: 44px;
  font-weight: 300;
}

.scoreboard[data-mode="schedule"] #awayScore:empty,
.scoreboard[data-mode="scoremap"] #awayScore:empty,
.scoreboard[data-mode="preview"] #awayScore:empty {
  display: none;
}

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

.metric {
  min-height: 74px;
  display: grid;
  gap: 6px;
  align-content: center;
  padding: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.metric span {
  color: var(--muted);
  font-size: 12px;
}

.metric strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 17px;
}

.result-area {
  display: grid;
  gap: 14px;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}

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

.panel-body {
  padding: 16px;
}

.bar-list {
  display: grid;
  gap: 11px;
}

.bar-row {
  display: grid;
  grid-template-columns: minmax(90px, 160px) 1fr 56px;
  gap: 12px;
  align-items: center;
}

.bar-label {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.bar-track {
  height: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
}

.bar-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--green), var(--amber));
}

.bar-value {
  color: var(--muted);
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
}

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

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

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

th {
  color: var(--muted);
  font-weight: 800;
}

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

.standings-group {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
}

.standings-group summary {
  min-height: 44px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 0 12px;
  cursor: pointer;
  font-weight: 900;
}

.standings-group summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.standings-table {
  min-width: 720px;
}

.record-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  min-height: 24px;
  padding: 0 7px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 900;
}

.record-chip.win {
  color: #07130c;
  background: var(--green);
}

.record-chip.draw {
  color: #07130c;
  background: var(--amber);
}

.record-chip.loss {
  color: #fff;
  background: var(--red);
}

.reason-list {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.reason-list li + li {
  margin-top: 8px;
}

.ai-report {
  color: var(--ink);
  line-height: 1.72;
  font-size: 14px;
}

.config-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.config-pill {
  min-height: 68px;
  display: grid;
  gap: 6px;
  align-content: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.config-pill span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.config-pill strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 15px;
}

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

.detail-grid section,
.transparency-grid section {
  min-width: 0;
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.detail-grid h3,
.transparency-grid h3,
.lineup-side h3 {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
}

.event-timeline {
  display: grid;
  gap: 8px;
}

.event-row {
  display: grid;
  grid-template-columns: 42px 64px minmax(0, 1fr);
  gap: 9px;
  align-items: baseline;
  color: var(--muted);
  font-size: 12px;
}

.event-row time {
  color: var(--amber);
  font-weight: 900;
}

.event-row strong {
  color: var(--ink);
}

.stats-board {
  display: grid;
  gap: 8px;
}

.stat-compare {
  display: grid;
  grid-template-columns: 1fr minmax(84px, auto) 1fr;
  gap: 8px;
  align-items: center;
}

.stat-compare strong {
  font-variant-numeric: tabular-nums;
  font-size: 16px;
}

.stat-compare strong:first-child {
  text-align: right;
}

.stat-compare span {
  color: var(--muted);
  text-align: center;
  font-size: 12px;
}

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

.lineup-side {
  display: grid;
  gap: 6px;
}

.lineup-side strong {
  color: var(--amber);
  font-size: 12px;
}

.lineup-side p,
.panel-note {
  color: var(--muted);
  line-height: 1.55;
  font-size: 12px;
}

.h2h-list,
.history-grid {
  display: grid;
  gap: 8px;
}

.h2h-list > div,
.history-fixture,
.model-logic,
.content-grid > div,
.flow-grid > div,
.ops-grid > div {
  display: grid;
  gap: 5px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.h2h-list span,
.history-fixture span,
.model-logic span,
.content-grid span,
.flow-grid span,
.ops-grid span {
  color: var(--muted);
  line-height: 1.45;
  font-size: 12px;
}

.model-logic {
  margin-top: 12px;
}

.content-grid,
.flow-grid,
.ops-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
}

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

.viz-card {
  min-width: 0;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.viz-card h3 {
  margin: 0;
  font-size: 14px;
}

.radar-chart,
.trend-chart {
  width: 100%;
  min-height: 180px;
}

.radar-chart text {
  fill: var(--muted);
  font-size: 9px;
  text-anchor: middle;
}

.radar-grid {
  fill: none;
  stroke: var(--line);
  stroke-width: 1.2;
}

.radar-grid.inner {
  opacity: 0.75;
}

.radar-home,
.radar-away {
  stroke-width: 2;
}

.radar-home {
  fill: rgba(24, 160, 88, 0.24);
  stroke: var(--green);
}

.radar-away {
  fill: rgba(98, 169, 255, 0.18);
  stroke: var(--blue);
}

.trend-chart line {
  stroke: var(--line);
  stroke-width: 1;
}

.trend-chart path {
  fill: none;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.trend-home {
  stroke: var(--green);
}

.trend-away {
  stroke: var(--blue);
}

.chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
}

.home-dot,
.away-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.home-dot {
  background: var(--green);
}

.away-dot {
  background: var(--blue);
}

.heatmap-pitch {
  position: relative;
  min-height: 176px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, transparent 49%, rgba(255,255,255,0.32) 49% 51%, transparent 51%),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.045) 0 38px, transparent 38px 76px),
    linear-gradient(135deg, var(--field), var(--field-dark));
}

.heatmap-pitch::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(255,255,255,0.55);
}

.heatmap-pitch span {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: calc(46px * var(--s));
  height: calc(46px * var(--s));
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: rgba(255, 200, 87, 0.44);
  box-shadow: 0 0 24px rgba(255, 200, 87, 0.36);
}

.heatmap-pitch span.away {
  background: rgba(86, 180, 233, 0.42);
  box-shadow: 0 0 24px rgba(86, 180, 233, 0.36);
}

.community-box {
  display: grid;
  gap: 10px;
}

.community-actions {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.community-actions .primary {
  min-width: 90px;
  min-height: 38px;
}

.community-actions span,
.community-post span {
  color: var(--muted);
  font-size: 12px;
}

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

.community-post {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.community-post p {
  line-height: 1.55;
  color: var(--ink);
  font-size: 13px;
}

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

.editorial-grid section {
  display: grid;
  gap: 10px;
  align-content: start;
}

.editorial-grid h3 {
  margin: 0;
  font-size: 14px;
}

.content-card-grid,
.player-chip-grid {
  display: grid;
  gap: 8px;
}

.content-card {
  display: grid;
  gap: 5px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.content-card span,
.content-card p {
  color: var(--muted);
  line-height: 1.45;
  font-size: 12px;
}

.player-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.player-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 9px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.ops-warning-list {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.ops-warning-list span,
.ops-ok {
  display: block;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.ops-warning-list span {
  color: var(--red);
  background: rgba(255, 107, 107, 0.08);
}

.ops-ok {
  margin-top: 12px;
  color: var(--green);
  background: rgba(24, 160, 88, 0.08);
}

.loading-state {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  min-height: 52px;
}

.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.16);
  border-top-color: var(--amber);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.score-card {
  min-height: 78px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.score-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

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

.market-card {
  min-height: 114px;
  display: grid;
  gap: 7px;
  align-content: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.market-card span,
.market-card small,
.market-meta {
  color: var(--muted);
  font-size: 12px;
}

.market-card strong {
  color: var(--amber);
  font-size: 26px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.market-card em {
  font-style: normal;
  font-weight: 900;
  font-size: 13px;
}

.market-card em.pos {
  color: #5ee081;
}

.market-card em.neg {
  color: var(--red);
}

.market-card em.flat {
  color: var(--blue);
}

.market-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.actual-result {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 12px 16px;
  align-items: center;
}

.actual-team {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 12px;
  min-width: 0;
}

.actual-team.away {
  justify-content: flex-start;
}

.actual-team span {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 18px;
  font-weight: 900;
}

.actual-team strong {
  color: var(--amber);
  font-size: clamp(36px, 6vw, 64px);
  line-height: 0.95;
  font-variant-numeric: tabular-nums;
}

.actual-mid {
  display: grid;
  gap: 4px;
  justify-items: center;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
}

.actual-mid span {
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.actual-mid small,
.actual-meta,
.actual-prediction {
  color: var(--muted);
  font-size: 12px;
}

.actual-meta,
.actual-prediction {
  grid-column: 1 / -1;
  text-align: center;
}

.actual-prediction {
  color: var(--blue);
  font-weight: 800;
}

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

.fixture-card {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 86px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, transform 0.16s ease;
}

.schedule-spotlight.fixture-card {
  grid-template-columns: minmax(0, 1.25fr) minmax(210px, 0.55fr) auto;
  min-height: 136px;
  padding: 18px;
  border-color: rgba(255, 200, 87, 0.32);
  background:
    linear-gradient(135deg, rgba(24, 160, 88, 0.24), rgba(255, 200, 87, 0.14)),
    var(--panel);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}

.spotlight-copy {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.spotlight-eyebrow {
  color: var(--amber);
  font-size: 12px;
  font-weight: 900;
}

.spotlight-copy h2 {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.12;
}

.spotlight-copy h2 span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.spotlight-copy h2 strong {
  color: var(--amber);
  font-size: 1.08em;
  font-variant-numeric: tabular-nums;
}

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

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

.spotlight-kpis div {
  display: grid;
  gap: 4px;
  place-items: center;
  min-height: 76px;
  padding: 10px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(6, 11, 16, 0.28);
}

.spotlight-kpis strong {
  color: var(--ink);
  font-size: 24px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.spotlight-kpis span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.spotlight-actions {
  display: grid;
  gap: 10px;
  align-content: center;
  min-width: 116px;
}

.fixture-card:hover,
.fixture-card:focus {
  border-color: rgba(255, 200, 87, 0.55);
  background: rgba(255, 255, 255, 0.06);
  outline: none;
}

.fixture-card:active {
  transform: translateY(1px);
}

.fixture-time {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.fixture-time strong {
  color: var(--amber);
  font-size: 18px;
}

.fixture-main {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.fixture-teams {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 17px;
  font-weight: 900;
}

.fixture-teams span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.fixture-score {
  color: var(--amber);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.fixture-meta {
  color: var(--muted);
  font-size: 12px;
}

.fixture-odds {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
  font-size: 12px;
  font-weight: 800;
}

.status-pill.ft {
  color: #08120b;
  background: var(--amber);
}

.status-pill.live {
  color: #07130c;
  background: #5ee081;
}

.status-pill.pending {
  color: var(--ink);
  background: rgba(98, 169, 255, 0.2);
  border-color: rgba(98, 169, 255, 0.5);
}

.fixture-actions {
  display: grid;
  gap: 8px;
  min-width: 80px;
}

.fixture-action {
  min-width: 74px;
  min-height: 36px;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-weight: 800;
}

.fixture-action.report {
  color: #07130c;
  background: var(--amber);
  border-color: var(--amber);
}

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

.pricing-card,
.report-match-card,
.order-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.pricing-card {
  display: grid;
  gap: 12px;
}

.pricing-card-head {
  display: grid;
  gap: 5px;
}

.pricing-card-head span {
  width: fit-content;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  color: #07130c;
  background: var(--amber);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.pricing-card-head strong {
  font-size: 18px;
}

.price-line {
  display: flex;
  gap: 8px;
  align-items: baseline;
}

.price-line strong {
  color: var(--amber);
  font-size: 34px;
  line-height: 1;
}

.price-line span,
.pricing-card p,
.feature-list,
.report-match-card small,
.order-card span,
.order-card small,
.commerce-plan span {
  color: var(--muted);
  font-size: 12px;
}

.feature-list {
  display: grid;
  gap: 7px;
  margin: 0;
  padding-left: 18px;
  line-height: 1.45;
}

.report-list {
  display: grid;
  gap: 10px;
}

.report-match-card,
.order-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.report-match-main {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.report-match-main strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 17px;
}

.report-match-main strong span {
  color: var(--amber);
  white-space: nowrap;
}

.report-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, auto));
  gap: 8px;
}

.report-actions .primary,
.report-actions .secondary {
  min-height: 38px;
  padding: 0 12px;
  white-space: nowrap;
}

.commerce-result {
  margin-top: 12px;
}

.order-card > div {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.order-card strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 16px;
}

.checkout-link {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  color: #07130c;
  background: var(--amber);
  border-radius: 8px;
  text-decoration: none;
  font-weight: 900;
}

.checkout-link.muted {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}

.commerce-plan {
  display: grid;
  gap: 10px;
}

.commerce-plan > div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.commerce-plan > div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.score-map {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(98, 169, 255, 0.12), transparent 28%, rgba(255, 255, 255, 0.035) 28% 29%, transparent 29% 61%, rgba(255, 255, 255, 0.035) 61% 62%, transparent 62%),
    linear-gradient(160deg, rgba(24, 160, 88, 0.22), rgba(18, 24, 32, 0.96));
}

.score-map::before {
  content: "";
  position: absolute;
  inset: 32px 46px 42px 34px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.1);
  clip-path: polygon(11% 19%, 28% 9%, 43% 14%, 58% 23%, 75% 21%, 87% 34%, 80% 49%, 71% 53%, 70% 67%, 57% 77%, 43% 73%, 33% 85%, 23% 75%, 15% 57%, 7% 45%);
}

.map-label {
  position: absolute;
  top: 14px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.map-label.west {
  left: 16%;
}

.map-label.central {
  left: 45%;
}

.map-label.east {
  right: 14%;
}

.score-pin {
  position: absolute;
  left: var(--x);
  top: var(--y);
  transform: translate(-50%, -50%);
  display: grid;
  justify-items: center;
  gap: 6px;
  max-width: 180px;
  color: var(--ink);
  background: transparent;
  border: 0;
  padding: 0;
  text-align: center;
}

.pin-dot {
  width: 16px;
  height: 16px;
  border: 3px solid var(--panel);
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 3px rgba(255, 200, 87, 0.26), 0 12px 26px rgba(0, 0, 0, 0.45);
}

.score-pin.live .pin-dot {
  background: #5ee081;
  box-shadow: 0 0 0 3px rgba(94, 224, 129, 0.24), 0 12px 26px rgba(0, 0, 0, 0.45);
}

.score-pin.pending .pin-dot {
  background: var(--blue);
  box-shadow: 0 0 0 3px rgba(98, 169, 255, 0.24), 0 12px 26px rgba(0, 0, 0, 0.45);
}

.pin-card {
  display: grid;
  gap: 3px;
  min-width: 128px;
  padding: 9px 10px;
  background: rgba(13, 20, 27, 0.92);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.36);
}

.pin-card strong,
.pin-card em,
.pin-card small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.pin-card strong {
  color: var(--amber);
  font-size: 12px;
}

.pin-card em {
  font-style: normal;
  font-size: 13px;
  font-weight: 900;
}

.pin-card small {
  color: var(--muted);
  font-size: 11px;
}

.score-feed {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.score-feed-card {
  display: grid;
  gap: 7px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  cursor: pointer;
}

.score-feed-card:hover,
.score-feed-card:focus {
  border-color: rgba(255, 200, 87, 0.55);
  background: rgba(255, 255, 255, 0.06);
  outline: none;
}

.score-feed-card > div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.score-feed-card strong {
  font-size: 16px;
}

.score-feed-card strong span {
  color: var(--amber);
}

.score-feed-card small {
  color: var(--muted);
}

.route-list {
  display: grid;
  gap: 10px;
}

.route-step {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.route-stage {
  color: var(--amber);
  font-weight: 900;
}

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

.bracket-scroll {
  overflow-x: auto;
}

.bracket {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(230px, 1fr);
  gap: 12px;
  min-width: 980px;
}

.round {
  display: grid;
  gap: 10px;
  align-content: start;
}

.round h3 {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.match-card {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  font-size: 13px;
}

.match-line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}

.winner {
  color: var(--amber);
  font-weight: 900;
}

.hidden {
  display: none !important;
}

.empty-state {
  padding: 20px;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.empty-state.compact {
  padding: 12px;
}

.legal-risk {
  display: grid;
  gap: 8px;
  margin-top: 4px;
  padding: 14px 16px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 200, 87, 0.24);
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.62;
}

.legal-risk strong {
  color: var(--amber);
  font-size: 13px;
}

.legal-risk p {
  margin: 0;
}

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

  .control-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 720px) {
  .workspace,
  .control-panel {
    padding: 16px;
  }

  .tabs {
    grid-template-columns: repeat(2, 1fr);
  }

  .tab:nth-child(4n) {
    border-right: 1px solid var(--line);
  }

  .tab:nth-child(3n) {
    border-right: 1px solid var(--line);
  }

  .tab:nth-child(2n) {
    border-right: 0;
  }

  .tab:nth-last-child(-n + 3) {
    border-bottom: 1px solid var(--line);
  }

  .tab:nth-last-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .tab:last-child {
    border-bottom: 0;
  }

  .summary-grid,
  .button-row,
  .switch-grid {
    grid-template-columns: 1fr;
  }

  .score-teams {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .score-teams > div:not(.score-separator),
  .score-teams > div:last-child {
    grid-template-columns: 1fr;
  }

  .score-teams strong {
    order: -1;
  }

  .score-separator {
    display: none;
  }

  .scoreboard[data-mode="schedule"] .score-teams,
  .scoreboard[data-mode="scoremap"] .score-teams {
    gap: 8px;
  }

  .scoreboard[data-mode="schedule"] .score-teams > div:not(.score-separator),
  .scoreboard[data-mode="schedule"] .score-teams > div:last-child,
  .scoreboard[data-mode="scoremap"] .score-teams > div:not(.score-separator),
  .scoreboard[data-mode="scoremap"] .score-teams > div:last-child {
    display: flex;
    grid-template-columns: unset;
    justify-content: center;
    align-items: baseline;
    gap: 8px;
  }

  .scoreboard[data-mode="schedule"] .score-teams strong,
  .scoreboard[data-mode="scoremap"] .score-teams strong {
    order: 0;
    font-size: clamp(34px, 10vw, 54px);
    line-height: 1;
  }

  .scoreboard[data-mode="schedule"] .score-teams span,
  .scoreboard[data-mode="scoremap"] .score-teams span {
    font-size: 20px;
  }

  .bar-row {
    grid-template-columns: 1fr 52px;
  }

  .bar-track {
    grid-column: 1 / -1;
    order: 3;
  }

  .fixture-card {
    grid-template-columns: 1fr;
  }

  .schedule-spotlight.fixture-card {
    grid-template-columns: 1fr;
  }

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

  .spotlight-actions .status-pill {
    grid-column: 1 / -1;
  }

  .fixture-action {
    width: 100%;
  }

  .actual-result {
    grid-template-columns: 1fr;
  }

  .actual-team,
  .actual-team.away {
    justify-content: center;
  }

  .score-map {
    min-height: 560px;
  }

  .score-pin {
    max-width: 148px;
  }

  .pin-card {
    min-width: 112px;
    padding: 8px;
  }
}

@media (max-width: 720px) {
  body {
    overflow-x: hidden;
  }

  .app-shell {
    min-height: auto;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  .control-panel {
    width: 100%;
    min-width: 0;
    max-width: 100vw;
    gap: 14px;
    padding: 14px;
  }

  .brand-row {
    gap: 10px;
    align-items: flex-start;
  }

  .mark {
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
  }

  .mark svg {
    width: 23px;
    height: 23px;
  }

  h1 {
    max-width: none;
    font-size: 16px;
    line-height: 1.2;
  }

  h1 span {
    white-space: normal;
  }

  #dataSource {
    font-size: 11px;
    line-height: 1.35;
  }

  .tabs {
    display: flex;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }

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

  .tab,
  .tab:nth-child(2n),
  .tab:nth-child(3n),
  .tab:nth-child(4n),
  .tab:nth-last-child(-n + 2),
  .tab:nth-last-child(-n + 3),
  .tab:last-child {
    flex: 0 0 auto;
    min-width: 78px;
    min-height: 40px;
    border-right: 1px solid var(--line);
    border-bottom: 0;
  }

  .tab:last-child {
    border-right: 0;
  }

  .data-health {
    min-width: 0;
    max-width: 100%;
    gap: 8px;
    padding: 10px;
  }

  .auth-card {
    gap: 8px;
    padding: 10px;
  }

  .data-health-head {
    align-items: flex-start;
  }

  .data-health-head strong {
    max-width: 52%;
    font-size: 12px;
  }

  .sync-row {
    grid-template-columns: minmax(0, 1fr) auto;
    min-width: 0;
  }

  .sync-row select {
    width: 100%;
    min-width: 0;
  }

  .sync-row select,
  .sync-row button,
  .auth-card input,
  select,
  input {
    min-height: 40px;
  }

  .form-stack {
    min-width: 0;
    max-width: 100%;
    gap: 10px;
  }

  .switch-grid,
  .button-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .switch {
    min-height: 36px;
    padding: 0 9px;
  }

  .status-line {
    min-height: 28px;
    padding-top: 10px;
  }

  .workspace {
    width: 100%;
    min-width: 0;
    max-width: 100vw;
    gap: 14px;
    padding: 14px;
  }

  .workspace > *,
  .result-area,
  .panel,
  .legal-risk {
    min-width: 0;
    max-width: 100%;
  }

  .stadium,
  .pitch {
    min-height: 220px;
  }

  .pitch::before {
    inset: 14px;
  }

  .pitch::after {
    inset: 34px auto 34px 50%;
  }

  .pitch-lines {
    width: 74px;
    height: 74px;
  }

  .scoreboard {
    width: calc(100% - 22px);
    gap: 9px;
    padding: 14px;
  }

  .score-status,
  .score-note {
    font-size: 10px;
  }

  .score-teams {
    grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr);
    gap: 4px;
    text-align: center;
  }

  .score-teams > div:not(.score-separator),
  .score-teams > div:last-child {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 5px;
  }

  .score-teams span {
    font-size: 14px;
    line-height: 1.2;
  }

  .score-teams strong,
  .scoreboard[data-mode="schedule"] .score-teams strong,
  .scoreboard[data-mode="scoremap"] .score-teams strong {
    order: 0;
    font-size: clamp(34px, 12vw, 50px);
    line-height: 0.95;
  }

  .score-separator {
    display: block;
    font-size: 24px;
  }

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

  .metric {
    min-height: 62px;
    padding: 10px;
  }

  .metric span {
    font-size: 11px;
  }

  .metric strong {
    font-size: 13px;
  }

  .panel-head {
    padding: 12px;
    align-items: flex-start;
  }

  .panel-head h2 {
    font-size: 15px;
  }

  .panel-body {
    padding: 12px;
  }

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

  .market-card {
    min-height: 78px;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 5px 10px;
  }

  .market-card strong {
    grid-column: 2;
    grid-row: 1 / span 3;
    font-size: 24px;
  }

  .market-meta {
    gap: 6px;
  }

  .fixture-card {
    gap: 10px;
    min-height: auto;
    padding: 12px;
  }

  .schedule-spotlight.fixture-card {
    gap: 14px;
    padding: 14px;
  }

  .spotlight-copy h2 {
    gap: 7px;
    font-size: 21px;
  }

  .spotlight-kpis div {
    min-height: 62px;
    padding: 8px 6px;
  }

  .spotlight-kpis strong {
    font-size: 20px;
  }

  .fixture-time {
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
  }

  .fixture-time strong {
    font-size: 17px;
  }

  .fixture-teams {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 7px;
    align-items: center;
    font-size: 16px;
  }

  .fixture-teams span:first-child {
    text-align: right;
  }

  .fixture-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-width: 0;
  }

  .fixture-action {
    width: 100%;
    min-height: 38px;
  }

  .pricing-grid,
  .report-match-card,
  .order-card,
  .commerce-plan > div {
    grid-template-columns: 1fr;
  }

  .pricing-card {
    padding: 12px;
  }

  .price-line strong {
    font-size: 28px;
  }

  .report-match-card,
  .order-card {
    gap: 10px;
  }

  .report-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .report-actions .primary,
  .report-actions .secondary,
  .checkout-link {
    width: 100%;
    min-height: 38px;
    padding: 0 9px;
    font-size: 12px;
  }

  .actual-result {
    gap: 10px;
  }

  .actual-team span {
    font-size: 16px;
  }

  .score-map {
    min-height: 480px;
  }

  .legal-risk {
    padding: 12px;
    font-size: 11px;
    line-height: 1.58;
  }
}

@media (max-width: 380px) {
  .switch-grid {
    grid-template-columns: 1fr;
  }

  .metric {
    padding: 9px 8px;
  }

  .scoreboard {
    padding: 12px;
  }

  .score-teams span {
    font-size: 13px;
  }

  .fixture-teams {
    font-size: 15px;
  }

  .spotlight-kpis,
  .spotlight-actions {
    grid-template-columns: 1fr;
  }

  .spotlight-copy h2 {
    display: grid;
    font-size: 19px;
  }

  .report-actions {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .quick-search,
  .preference-card,
  .follow-card,
  .model-lab {
    padding: 10px;
  }

  .preference-card {
    grid-template-columns: 1fr;
  }

  [data-field="scheduleQuick"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-tabs button,
  .group-switcher button,
  .popular-teams button {
    min-height: 38px;
    padding: 0 11px;
  }

  .fixture-list {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 4px;
  }

  .fixture-card {
    flex: 0 0 min(88vw, 360px);
    scroll-snap-align: start;
  }

  .detail-grid,
  .transparency-grid,
  .lineup-board {
    grid-template-columns: 1fr;
  }

  .event-row {
    grid-template-columns: 36px minmax(48px, auto) minmax(0, 1fr);
  }

  .stat-compare {
    grid-template-columns: 54px minmax(78px, 1fr) 54px;
  }

  .content-grid,
  .flow-grid,
  .ops-grid,
  .visual-grid {
    grid-template-columns: 1fr;
  }

  .community-actions {
    grid-template-columns: 1fr;
  }

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