/* Batch 7B: shared, late-loaded UI consistency rules. */
:root {
  --color-primary: var(--cx-primary, #385c7b);
  --cx-purple: #6d5fa8;
  --cx-focus-ring: #f4b942;
  --cx-focus-shadow: 0 0 0 4px rgba(244, 185, 66, 0.24);
  --cx-surface-raised: #ffffff;
  --cx-info-soft: rgba(47, 143, 201, 0.11);
  --cx-warning-soft: rgba(244, 185, 66, 0.15);
}

.cx-btn:focus-visible,
.cx-tab:focus-visible,
.cx-filter-pill:focus-visible,
.cx-innings-tab:focus-visible,
.cx-btn-outline-light:focus-visible,
.cx-header-slider-arrow:focus-visible,
.cx-commentary-search-input:focus-visible,
.cx-commentary-filter-tabs button:focus-visible,
.cx-highlight-filter-tabs button:focus-visible,
.cx-scorecard-share-button:focus-visible,
.cx-match-poll button:focus-visible,
.lcw-fixture-status-btn:focus-visible {
  outline: 3px solid var(--cx-focus-ring) !important;
  outline-offset: 3px !important;
  box-shadow: var(--cx-focus-shadow) !important;
}

.cx-empty-state,
.lcw-empty-state {
  min-height: 112px;
  padding: 20px;
  border: 1px dashed var(--cx-primary-border, #bfd1df);
  background: var(--cx-soft-card, #f8fbfd);
  color: var(--cx-muted, #64748b);
}

.cx-empty-state p:last-child,
.lcw-empty-state p:last-child {
  margin-bottom: 0;
}

.cx-match-slider-track,
.cx-live-card,
.cx-live-card .cx-card-link-wrapper,
.cx-live-card .cx-match-card-top,
.cx-live-card .cx-match-vs-area,
.cx-live-card .cx-match-card-bottom {
  min-width: 0;
}

.cx-live-card .cx-header-series {
  min-width: 0;
  line-height: 1.3;
}

.cx-live-card .cx-match-status {
  display: -webkit-box !important;
  min-height: 34px;
  white-space: normal !important;
  line-height: 1.28;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.cx-live-card .cx-match-card-bottom,
.cx-live-card .cx-venue,
.cx-live-card .cx-crr {
  font-size: 11px !important;
  line-height: 1.35;
}

.cx-live-card-actions .cx-btn-outline-light {
  min-height: 30px !important;
  font-size: 12px !important;
}

.cx-fow-over-val,
.cx-ratio-labels,
.cx-role-label,
.cx-role-badge,
.cx-matchup-vs,
.cx-community-poll-footer,
.cx-community-poll-vs,
.cx-ball-chip,
.cx-fantasy-contrib i {
  font-size: 11px !important;
}

.cx-role-label {
  font-size: 10px !important;
}

.cx-context-alert-input {
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid var(--cx-border, #d7e1e8);
  border-radius: 6px;
  background: #ffffff;
  color: var(--cx-text, #20384d);
  box-shadow: inset 0 1px 2px rgba(23, 54, 79, 0.05);
}

.cx-live-filter-tabs .lcw-fixture-status-btn > span:last-child,
.cx-live-filter-tabs .lcw-fixture-status-btn > b:last-child,
.cx-team-hero .cx-team-ranking-tile small,
.lcw-ranking-v3.lcw-rank-player-view .lcw-table th {
  font-size: 11px !important;
  line-height: 1.3;
}

.cx-commentary-controls,
.cx-highlights-toolbar,
.cx-analytics-card,
.cx-fantasy-points-card,
.cx-win-prediction-card,
.cx-ground-snapshot-card,
.cx-top-players-card {
  border-color: rgba(56, 92, 123, 0.16);
}

.cx-commentary-search-input,
.cx-commentary-controls button,
.cx-highlight-filter-tabs button {
  min-height: 42px;
}

@media (max-width: 700px) {
  .cx-match-slider-frame {
    padding-right: 36px !important;
    padding-left: 36px !important;
  }

  .cx-header-slider-arrow {
    width: 32px !important;
    height: 32px !important;
  }

  .cx-header-slider-prev {
    left: 0 !important;
  }

  .cx-header-slider-next {
    right: 0 !important;
  }

  .cx-live-card .cx-match-status {
    min-height: 36px;
  }

  .cx-team-page .cx-match-team {
    align-items: flex-start;
  }

  .cx-team-page .cx-team-identity {
    flex: 1 1 auto;
  }

  .cx-team-page .cx-team-name {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
    line-height: 1.25;
  }

  .cx-match-card .cx-team-name {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
    line-height: 1.25;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cx-live-card,
  .cx-matchup-card,
  .cx-header-slider-arrow,
  .cx-btn,
  .cx-tab,
  .cx-filter-pill {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
