/* Matchup analyzer styles (shared by /today) */

.today-page,
.homepage-shell {
  --homepage-border: #d7e1ec;
  --homepage-header-border: #ccd8e5;
  --homepage-row-border: #dde6ef;
  --homepage-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(148, 163, 184, 0.1);
  --homepage-shadow-hover: 0 2px 4px rgba(15, 23, 42, 0.05), 0 14px 32px rgba(148, 163, 184, 0.14);
  --homepage-accent-hot: #ea580c;
  --homepage-accent-cold: #0284c7;
  --homepage-header-bg: linear-gradient(180deg, #eaf1f8 0%, #f8fbff 100%);
  --homepage-panel-bg: linear-gradient(180deg, #fbfdff 0%, #f3f7fb 100%);
  --homepage-panel-subtle-bg: #f8fbfe;
  --homepage-panel-solid-bg: #fbfdff;
  --homepage-card-title: #14253d;
  --homepage-text: #14253d;
  --homepage-muted: #5f7288;
  --homepage-muted-soft: #718398;
  --homepage-summary-text: #2d445d;
  --homepage-pill-text: #39516d;
  --homepage-tab-shell-bg: #f4f7fb;
  --homepage-tab-shell-border: #d7e1ec;
  --homepage-tab-text: #5f7288;
  --homepage-tab-text-hover: #17304d;
  --homepage-tab-active-bg: linear-gradient(180deg, #17304d 0%, #1f4d7a 100%);
  --homepage-tab-active-text: #f8fbff;
  --homepage-tab-active-shadow: 0 10px 20px rgba(23, 48, 77, 0.14);
  --homepage-feature-bg: linear-gradient(180deg, #f9fbfe 0%, #edf4fb 100%);
  --homepage-feature-border: #d9e4ef;
  --homepage-feature-shadow: 0 10px 24px rgba(15, 23, 42, 0.05);
  --homepage-flag-bg: #e9f0f7;
  --homepage-flag-text: #17304d;
  --homepage-stat-bg: rgba(255, 255, 255, 0.82);
  --homepage-stat-border: #dbe6f1;
  --homepage-pill-bg: #eff5fb;
  --homepage-pill-border: #d8e3ef;
  --homepage-row-bg: #fbfdff;
  --homepage-overlay: rgba(15, 23, 42, 0.58);
  --homepage-modal-bg: linear-gradient(180deg, #ffffff 0%, #f4f8fc 100%);
  --homepage-modal-border: rgba(255, 255, 255, 0.5);
  --homepage-modal-header-bg: linear-gradient(180deg, #eff5fb 0%, #f7fbff 100%);
  --homepage-modal-surface: rgba(255, 255, 255, 0.88);
  --homepage-control-bg: #ffffff;
  --homepage-control-border: #d5e0ec;
  --homepage-control-text: #32455c;
  --homepage-chip-bg: #f7fbff;
  --homepage-chip-border: #dbe7f2;
  --homepage-gap-section: 0.9rem;
  --homepage-gap-inner: 0.55rem;
  --homepage-pad-x: 0.72rem;
  --homepage-pad-y: 0.58rem;
  --homepage-pill-pad-y: 0.14rem;
  --homepage-pill-pad-x: 0.24rem;
  --homepage-metric-gap: 0.16rem;
  --homepage-metric-pad-y: 0.16rem;
  --homepage-metric-pad-x: 0.22rem;
}

[data-theme="dark"] .today-page,
[data-theme="dark"] .homepage-shell {
  --homepage-border: var(--border-line);
  --homepage-header-border: #273546;
  --homepage-row-border: #263445;
  --homepage-shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 12px 28px rgba(0, 0, 0, 0.28);
  --homepage-shadow-hover: 0 2px 6px rgba(0, 0, 0, 0.25), 0 18px 36px rgba(0, 0, 0, 0.35);
  --homepage-accent-hot: #fb923c;
  --homepage-accent-cold: #38bdf8;
  --homepage-header-bg: linear-gradient(180deg, #17212d 0%, #111925 100%);
  --homepage-panel-bg: linear-gradient(180deg, #141d29 0%, #0f1620 100%);
  --homepage-panel-subtle-bg: #101822;
  --homepage-panel-solid-bg: #121b27;
  --homepage-card-title: var(--text-primary);
  --homepage-text: var(--text-primary);
  --homepage-muted: #94a8bc;
  --homepage-muted-soft: #8196ab;
  --homepage-summary-text: #c2cfdb;
  --homepage-pill-text: #bed2e6;
  --homepage-tab-shell-bg: #101722;
  --homepage-tab-shell-border: #2a394a;
  --homepage-tab-text: #94a8bc;
  --homepage-tab-text-hover: #e6edf3;
  --homepage-tab-active-bg: linear-gradient(180deg, #1f5fbf 0%, #2d79ee 100%);
  --homepage-tab-active-text: #f8fbff;
  --homepage-tab-active-shadow: 0 12px 24px rgba(1, 4, 9, 0.35);
  --homepage-feature-bg: linear-gradient(180deg, #121b26 0%, #182334 100%);
  --homepage-feature-border: #2a394a;
  --homepage-feature-shadow: 0 12px 28px rgba(1, 4, 9, 0.24);
  --homepage-flag-bg: #19314c;
  --homepage-flag-text: #cfe1ff;
  --homepage-stat-bg: rgba(13, 17, 23, 0.72);
  --homepage-stat-border: #2a394a;
  --homepage-pill-bg: #0f1c2a;
  --homepage-pill-border: #2a394a;
  --homepage-row-bg: #101722;
  --homepage-overlay: rgba(1, 4, 9, 0.78);
  --homepage-modal-bg: linear-gradient(180deg, #161f2b 0%, #0e141d 100%);
  --homepage-modal-border: rgba(230, 237, 243, 0.08);
  --homepage-modal-header-bg: linear-gradient(180deg, #1a2431 0%, #121a24 100%);
  --homepage-modal-surface: rgba(13, 17, 23, 0.72);
  --homepage-control-bg: #0d1117;
  --homepage-control-border: #2a394a;
  --homepage-control-text: #d8e4f0;
  --homepage-chip-bg: #0f1722;
  --homepage-chip-border: #2a394a;
}

.homepage-matchup-card {
      overflow: visible;
    }

.dash-card-header .info-tip,
    .matchup-table .info-tip,
    .matchup-hr-section-title .info-tip,
    .matchup-ps .info-tip,
    .matchup-pitch-breakdown-stats .info-tip {
      position: relative;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 14px;
      height: 14px;
      margin-left: 4px;
      border-radius: 50%;
      border: 1px solid var(--border-line);
      color: var(--text-secondary);
      font-size: 10px;
      font-weight: 700;
      text-transform: none;
      cursor: help;
      vertical-align: middle;
      line-height: 1;
    }

.matchup-table .info-tip,
    .matchup-hr-section-title .info-tip,
    .matchup-ps .info-tip,
    .matchup-pitch-breakdown-stats .info-tip {
      z-index: 3;
    }

.dash-card-header .info-tip .tip-text,
    .matchup-table .info-tip .tip-text,
    .matchup-hr-section-title .info-tip .tip-text,
    .matchup-ps .info-tip .tip-text,
    .matchup-pitch-breakdown-stats .info-tip .tip-text {
      visibility: hidden;
      opacity: 0;
      position: absolute;
      bottom: auto;
      top: calc(100% + 8px);
      left: 50%;
      transform: translateX(-50%);
      z-index: 1000;
      width: min(280px, calc(100vw - 32px));
      max-width: calc(100vw - 32px);
      padding: 6px 10px;
      border-radius: 6px;
      background: #1e293b;
      color: #f1f5f9;
      font-size: 0.8rem;
      font-weight: 400;
      text-transform: none;
      letter-spacing: normal;
      line-height: 1.4;
      text-align: left;
      white-space: normal;
      overflow-wrap: break-word;
      pointer-events: none;
      box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
      transition: opacity 0.15s ease;
    }

.dash-card-header .info-tip:hover .tip-text,
    .dash-card-header .info-tip:focus .tip-text,
    .matchup-table .info-tip:hover .tip-text,
    .matchup-table .info-tip:focus .tip-text,
    .matchup-hr-section-title .info-tip:hover .tip-text,
    .matchup-hr-section-title .info-tip:focus .tip-text,
    .matchup-ps .info-tip:hover .tip-text,
    .matchup-ps .info-tip:focus .tip-text,
    .matchup-pitch-breakdown-stats .info-tip:hover .tip-text,
    .matchup-pitch-breakdown-stats .info-tip:focus .tip-text {
      visibility: visible;
      opacity: 1;
    }

[data-theme="dark"] .dash-card-header .info-tip,
    [data-theme="dark"] .matchup-table .info-tip,
    [data-theme="dark"] .matchup-hr-section-title .info-tip,
    [data-theme="dark"] .matchup-ps .info-tip,
    [data-theme="dark"] .matchup-pitch-breakdown-stats .info-tip {
      border-color: var(--border-line);
      color: var(--text-secondary);
    }

[data-theme="dark"] .dash-card-header .info-tip .tip-text,
    [data-theme="dark"] .matchup-table .info-tip .tip-text,
    [data-theme="dark"] .matchup-hr-section-title .info-tip .tip-text,
    [data-theme="dark"] .matchup-ps .info-tip .tip-text,
    [data-theme="dark"] .matchup-pitch-breakdown-stats .info-tip .tip-text {
      background: #0f172a;
      color: #e2e8f0;
    }

[data-theme="dark"] .matchup-elo-strip-value.batter-edge,
    [data-theme="dark"] .matchup-elo-contrib-row strong.up,
    [data-theme="dark"] .matchup-hr-pill.high,
    [data-theme="dark"] .matchup-hr-pill.elite,
    [data-theme="dark"] .matchup-hr-pill.batter-edge,
    [data-theme="dark"] .matchup-reg-improve,
    [data-theme="dark"] .matchup-adv-yes,
    [data-theme="dark"] .matchup-hand-S,
    [data-theme="dark"] .matchup-wh-low,
    [data-theme="dark"] .matchup-delta-up,
    [data-theme="dark"] .matchup-pill-speed {
      background: rgba(63, 185, 80, 0.16);
      color: #86efac;
    }

[data-theme="dark"] .matchup-elo-strip-value.pitcher-edge,
    [data-theme="dark"] .matchup-elo-contrib-row strong.down,
    [data-theme="dark"] .matchup-hr-pill.pitcher-edge,
    [data-theme="dark"] .matchup-reg-regress,
    [data-theme="dark"] .matchup-adv-no,
    [data-theme="dark"] .matchup-wh-elite,
    [data-theme="dark"] .matchup-delta-dn,
    [data-theme="dark"] .matchup-pill-chase {
      background: rgba(248, 81, 73, 0.16);
      color: #fca5a5;
    }

[data-theme="dark"] .matchup-hand-L,
    [data-theme="dark"] .matchup-wh-avg,
    [data-theme="dark"] .matchup-pill-xwoba,
    [data-theme="dark"] .matchup-hr-pill.moderate {
      background: rgba(59, 130, 246, 0.16);
      color: #93c5fd;
    }

[data-theme="dark"] .matchup-hand-R,
    [data-theme="dark"] .matchup-wh-high,
    [data-theme="dark"] .matchup-pill-power {
      background: rgba(249, 115, 22, 0.16);
      color: #fdba74;
    }

[data-theme="dark"] .matchup-bat-speed-trend-up { color: #86efac; }

[data-theme="dark"] .matchup-bat-speed-trend-down { color: #fca5a5; }

[data-theme="dark"] .matchup-elo-strip-value.neutral-edge,
    [data-theme="dark"] .matchup-hr-pill.low,
    [data-theme="dark"] .matchup-hr-pill.neutral-edge,
    [data-theme="dark"] .matchup-hr-pill.unavailable,
    [data-theme="dark"] .matchup-adv-neu {
      background: rgba(148, 163, 184, 0.14);
      color: #cbd5e1;
    }

[data-theme="dark"] .matchup-error,
    [data-theme="dark"] .matchup-hr-state-error {
      border-color: rgba(248, 81, 73, 0.3);
      background: rgba(248, 81, 73, 0.12);
      color: #fca5a5;
    }

/* ── Matchup Analyzer ── */

.matchup-live-dot {
      width: 8px; height: 8px; border-radius: 50%;
      background: var(--primary); flex-shrink: 0;
      box-shadow: 0 0 0 3px rgba(37,99,235,.2);
      animation: matchupPulse 2s infinite;
    }

.matchup-banner {
      display: flex; align-items: center; gap: 10px;
      padding: 0.6rem 0.9rem;
      background: rgba(37,99,235,.05);
      border: 1px solid rgba(37,99,235,.15);
      border-radius: var(--radius-sm);
      font-size: 0.78rem; color: var(--text-secondary);
      margin-bottom: 1rem;
    }

.matchup-banner strong { color: var(--text-primary); }

.homepage-matchup-shell {
      display: grid;
      gap: 0.7rem;
    }

.homepage-matchup-heading {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      gap: 0.75rem;
    }

.homepage-matchup-heading-copy h3 {
      margin: 0;
      font-size: 0.84rem;
      font-weight: 800;
      letter-spacing: 0.04em;
      color: var(--homepage-card-title);
    }

.homepage-matchup-heading-copy p {
      margin: 0.16rem 0 0;
      font-size: 0.72rem;
      line-height: 1.38;
      color: var(--text-secondary);
    }

.homepage-matchup-live {
      display: inline-flex;
      align-items: center;
      gap: 0.42rem;
      padding: 0.3rem 0.58rem;
      border-radius: 999px;
      border: 1px solid rgba(37,99,235,.14);
      background: rgba(37,99,235,.06);
      font-size: 0.6rem;
      font-weight: 800;
      letter-spacing: 0.06em;
      text-transform: uppercase;
      color: var(--primary);
      white-space: nowrap;
    }

.matchup-date-nav {
      display: flex; align-items: center; gap: 0.4rem;
      flex-wrap: wrap;
    }

.matchup-date-nav button {
      background: var(--bg-white); border: 1px solid var(--border-line);
      border-radius: 999px; padding: 0.34rem 0.66rem;
      font-size: 0.72rem; cursor: pointer; color: var(--text-primary);
      font-family: inherit;
    }

.matchup-date-nav button:hover { background: var(--bg-page); }

.matchup-date-nav button.active {
      background: var(--primary); color: #fff; border-color: var(--primary);
    }

#matchup-date-input {
      padding: 0.34rem 0.62rem; border: 1px solid var(--border-line);
      border-radius: 999px; font-size: 0.72rem;
      background: var(--bg-white); color: var(--text-primary);
      font-family: inherit;
    }

.matchup-load-btn {
      background: var(--primary); color: #fff; border: none;
      padding: 0.45rem 1rem; border-radius: var(--radius-sm);
      font-size: 0.8rem; font-weight: 600; cursor: pointer;
      font-family: inherit;
    }

.matchup-load-btn:hover { background: var(--primary-hover); }

.matchup-chips {
      display: flex; gap: 0.32rem; flex-wrap: wrap;
    }

.homepage-matchup-control-rail {
      display: grid;
      gap: 0.55rem;
      padding: 0.68rem 0.72rem;
      border: 1px solid var(--homepage-header-border);
      border-radius: 0.85rem;
      background:
        linear-gradient(180deg, rgba(255,255,255,0.95) 0%, rgba(244,247,251,0.95) 100%);
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
    }

.homepage-matchup-games-shell {
      display: grid;
      gap: 0.75rem;
    }

.homepage-matchup-workspace {
      position: relative;
      min-width: 0;
    }

.matchup-chip {
      padding: 0.24rem 0.58rem; border-radius: 999px; font-size: 0.68rem;
      cursor: pointer; border: 1px solid var(--border-line);
      background: var(--bg-white); color: var(--text-primary);
      font-family: inherit; font-weight: 700;
    }

.matchup-chip:hover { background: var(--bg-page); }

.matchup-chip.active {
      background: rgba(37,99,235,.08); color: var(--primary);
      border-color: var(--primary);
    }

.matchup-chip.today { font-weight: 700; }

.matchup-games-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
      gap: 0.55rem;
    }

.matchup-game-card {
      background: var(--bg-page); border: 1px solid var(--border-line);
      border-radius: 0.8rem; padding: 0.62rem 0.72rem;
      transition: box-shadow .15s;
    }

.matchup-game-card:hover { box-shadow: var(--shadow-sm); }

.matchup-game-header {
      display: flex; justify-content: space-between;
      align-items: center; margin-bottom: 0.4rem;
    }

.matchup-game-title { font-size: 0.84rem; font-weight: 700; color: var(--text-primary); }

.matchup-game-time { font-size: 0.66rem; color: var(--text-secondary); }

.matchup-game-venue { font-size: 0.64rem; color: var(--text-secondary); margin-bottom: 0.38rem; display: flex; align-items: center; gap: 0.28rem; }

.matchup-rain-icon { width: 1rem; height: 1rem; color: #60a5fa; flex-shrink: 0; vertical-align: middle; }

.matchup-pitcher-row {
      display: flex; align-items: center; gap: 0.42rem;
      padding: 0.34rem 0.5rem; border-radius: 0.68rem;
      margin-bottom: 0.26rem; cursor: pointer;
      border: 1px solid transparent; transition: all .15s;
      position: relative;
    }

.matchup-pitcher-row:hover { background: var(--bg-white); border-color: var(--border-line); }

.matchup-pitcher-row.active {
      background: rgba(37,99,235,.08); border-color: var(--primary);
      box-shadow: inset 0 0 0 1px rgba(37,99,235,.14);
    }

.matchup-pitcher-side {
      font-size: 0.56rem; font-weight: 700; text-transform: uppercase;
      letter-spacing: .05em; color: var(--text-secondary); min-width: 30px;
    }

.matchup-pitcher-name { font-size: 0.74rem; font-weight: 700; color: var(--text-primary); line-height: 1.15; }

.matchup-pitcher-stats { font-size: 0.66rem; color: var(--text-secondary); margin-top: 1px; }

.matchup-tier-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

.matchup-tbd { font-size: 0.75rem; color: var(--text-secondary); font-style: italic; }

#matchup-lineup-panel {
      background:
        linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(246,249,252,0.98) 100%);
      border: 1px solid rgba(37,99,235,.18);
      border-radius: 0.9rem;
      padding: 0.78rem;
      display: none;
      box-shadow: 0 16px 36px rgba(15, 23, 42, 0.08);
    }

#matchup-lineup-panel.show { display: block; }

#matchup-hr-deep-dive {
      margin-top: 0;
      border: 1px solid var(--border-line);
      border-radius: 0.9rem;
      background: var(--homepage-panel-bg);
      overflow: hidden;
    }

.matchup-workspace-stack {
      display: grid;
      gap: 0.68rem;
    }

.matchup-lp-overview {
      display: grid;
      gap: 0.58rem;
      margin-bottom: 0.7rem;
    }

.matchup-lp-top-grid {
      display: grid;
      grid-template-columns: minmax(16rem, 22rem) minmax(19rem, 25rem) minmax(30rem, 1fr);
      gap: 0.62rem;
      align-items: stretch;
      justify-content: start;
      max-width: 96rem;
      min-width: 0;
    }

.matchup-lp-top-grid.matchup-lp-top-grid-single {
      grid-template-columns: minmax(18rem, 26rem);
    }

.matchup-lp-top-grid.matchup-lp-top-grid-duo {
      grid-template-columns: minmax(18rem, 24rem) minmax(19rem, 27rem);
      max-width: 52rem;
    }

.matchup-hr-header {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      gap: 0.75rem;
      padding: 0.82rem 0.95rem 0.72rem;
      background: var(--homepage-header-bg);
      border-bottom: 1px solid var(--homepage-header-border);
    }

.matchup-hr-title {
      font-size: 0.92rem;
      font-weight: 800;
      letter-spacing: 0.03em;
      color: var(--homepage-card-title);
      text-transform: uppercase;
    }

.matchup-hr-subtitle {
      margin-top: 0.2rem;
      font-size: 0.77rem;
      color: var(--text-secondary);
    }

.matchup-hr-body {
      padding: 0.75rem 0.8rem 0.82rem;
    }

.matchup-analysis-shell {
      display: grid;
      gap: 0.72rem;
    }

.matchup-analysis-primary,
    .matchup-analysis-secondary {
      min-width: 0;
    }

.matchup-analysis-secondary {
      display: contents;
    }

.matchup-drilldown-panel {
      border: 1px solid rgba(148, 163, 184, 0.18);
      border-radius: 0.82rem;
      background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(248,250,252,0.98) 100%);
      padding: 0.68rem 0.74rem;
      min-width: 0;
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.45);
    }

.matchup-drilldown-top-rail {
      display: grid;
      gap: 0.56rem;
    }

.matchup-drilldown-topline {
      display: grid;
      grid-template-columns: minmax(220px, 0.92fr) minmax(0, 1.38fr);
      gap: 0.56rem;
      align-items: start;
    }

.matchup-drilldown-title-wrap {
      display: grid;
      gap: 0.18rem;
      min-width: 0;
    }

.matchup-drilldown-title {
      font-size: 1rem;
      font-weight: 800;
      color: var(--text-primary);
      line-height: 1.2;
    }

.matchup-drilldown-subtitle,
    .matchup-drilldown-section-subtitle {
      font-size: 0.73rem;
      line-height: 1.42;
      color: var(--text-secondary);
    }

.matchup-drilldown-summary-strip,
    .matchup-elo-strip {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
      gap: 0.42rem;
    }

.matchup-elo-strip-item {
      border: 1px solid rgba(148, 163, 184, 0.16);
      border-radius: 0.72rem;
      background: rgba(255,255,255,0.72);
      padding: 0.45rem 0.54rem;
      min-width: 0;
    }

.matchup-elo-strip-label {
      display: block;
      font-size: 0.59rem;
      font-weight: 800;
      letter-spacing: 0.06em;
      text-transform: uppercase;
      color: var(--text-secondary);
      margin-bottom: 0.18rem;
    }

.matchup-elo-strip-value {
      display: block;
      font-size: 0.88rem;
      font-weight: 800;
      color: var(--text-primary);
      line-height: 1.15;
      overflow-wrap: anywhere;
    }

.matchup-elo-strip-value.batter-edge {
      color: #166534;
    }

.matchup-elo-strip-value.pitcher-edge {
      color: #b91c1c;
    }

.matchup-elo-strip-value.neutral-edge {
      color: #334155;
    }

.matchup-drilldown-main-grid {
      display: grid;
      grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
      gap: 0.72rem;
      align-items: start;
    }

.matchup-drilldown-context-grid {
      display: grid;
      grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
      gap: 0.72rem;
      align-items: start;
    }

.matchup-analysis-secondary > :nth-child(1),
    .matchup-analysis-secondary > :nth-child(2) {
      grid-column: 1;
    }

.matchup-analysis-secondary > :nth-child(3) {
      grid-column: 2;
      grid-row: 1 / span 2;
    }

.matchup-drilldown-context-sections {
      display: grid;
      min-width: 0;
    }

.matchup-drilldown-context-sections .matchup-hr-sections {
      grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }

.matchup-drilldown-context-sections .matchup-hr-list {
      display: flex;
      flex-wrap: wrap;
      gap: 0.34rem;
    }

.matchup-drilldown-context-sections .matchup-hr-list-row {
      display: inline-flex;
      align-items: baseline;
      justify-content: flex-start;
      gap: 0.3rem;
      width: fit-content;
      padding: 0.18rem 0.42rem;
      border: 1px solid rgba(226,232,240,.9);
      border-radius: 999px;
      background: rgba(248,250,252,.9);
      white-space: nowrap;
    }

.matchup-drilldown-context-sections .matchup-hr-list-row strong {
      text-align: left;
    }

.matchup-drilldown-section-head {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 0.6rem;
      margin-bottom: 0.48rem;
      flex-wrap: wrap;
    }

.matchup-drilldown-panel-tag {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 0.16rem 0.42rem;
      border-radius: 999px;
      background: rgba(37, 99, 235, 0.08);
      color: var(--primary);
      font-size: 0.62rem;
      font-weight: 700;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      white-space: nowrap;
    }

.matchup-drilldown-elo-board {
      display: grid;
      gap: 0.56rem;
    }

.matchup-elo-board-grid {
      display: grid;
      grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr);
      gap: 0.56rem;
    }

.matchup-drilldown-subpanel {
      display: grid;
      gap: 0.42rem;
      padding: 0.08rem 0.1rem 0;
    }

.matchup-elo-prob-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 0.34rem;
    }

.matchup-elo-prob-card {
      border: 1px solid rgba(148, 163, 184, 0.16);
      border-radius: 0.62rem;
      background: rgba(255,255,255,0.74);
      padding: 0.48rem 0.44rem;
      text-align: center;
    }

.matchup-elo-prob-card strong {
      display: block;
      font-size: 0.88rem;
      font-weight: 800;
      color: var(--text-primary);
      line-height: 1.1;
    }

.matchup-elo-prob-card span {
      display: block;
      margin-top: 0.18rem;
      font-size: 0.63rem;
      color: var(--text-secondary);
      text-transform: uppercase;
      letter-spacing: 0.04em;
      line-height: 1.25;
    }

.matchup-elo-contrib-list {
      display: grid;
      gap: 0.14rem;
    }

.matchup-elo-contrib-row {
      display: flex;
      justify-content: space-between;
      gap: 0.5rem;
      padding: 0.32rem 0;
      border-bottom: 1px solid var(--homepage-row-border);
      font-size: 0.72rem;
      color: var(--text-secondary);
    }

.matchup-elo-contrib-row:last-child {
      border-bottom: none;
      padding-bottom: 0;
    }

.matchup-elo-contrib-row strong {
      color: var(--text-primary);
      font-weight: 800;
      font-variant-numeric: tabular-nums;
    }

.matchup-elo-contrib-row strong.up {
      color: #166534;
    }

.matchup-elo-contrib-row strong.down {
      color: #b91c1c;
    }

.matchup-hr-state {
      padding: 0.56rem 0.64rem;
      border: 1px dashed var(--homepage-header-border);
      border-radius: 0.72rem;
      background: rgba(255,255,255,0.72);
      font-size: 0.73rem;
      line-height: 1.42;
      color: var(--text-secondary);
    }

.matchup-hr-state strong {
      color: var(--text-primary);
    }

.matchup-hr-state-error {
      border-style: solid;
      border-color: #fecaca;
      background: #fef2f2;
      color: #b91c1c;
    }

.matchup-hr-summary-card,
    .matchup-hr-section {
      border: 1px solid rgba(148, 163, 184, 0.16);
      border-radius: 0.78rem;
      background: rgba(255,255,255,0.72);
      padding: 0.62rem 0.68rem;
    }

.matchup-hr-label {
      font-size: 0.6rem;
      font-weight: 800;
      letter-spacing: 0.06em;
      text-transform: uppercase;
      color: var(--text-secondary);
    }

.matchup-hr-score-row {
      display: flex;
      align-items: center;
      gap: 0.45rem;
      margin: 0.28rem 0 0.24rem;
      flex-wrap: wrap;
    }

.matchup-hr-score {
      font-size: 1.2rem;
      font-weight: 800;
      color: var(--text-primary);
      line-height: 1;
    }

.matchup-hr-pill {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 0.16rem 0.42rem;
      border-radius: 999px;
      font-size: 0.61rem;
      font-weight: 800;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      background: #dbeafe;
      color: #1d4ed8;
    }

.matchup-hr-pill.low {
      background: #e2e8f0;
      color: #475569;
    }

.matchup-hr-pill.moderate {
      background: #dbeafe;
      color: #1d4ed8;
    }

.matchup-hr-pill.high,
    .matchup-hr-pill.elite {
      background: #dcfce7;
      color: #15803d;
    }

.matchup-hr-pill.batter-edge {
      background: #dcfce7;
      color: #166534;
    }

.matchup-hr-pill.pitcher-edge {
      background: #fee2e2;
      color: #b91c1c;
    }

.matchup-hr-pill.neutral-edge {
      background: #e2e8f0;
      color: #334155;
    }

.matchup-hr-pill.unavailable {
      background: #f1f5f9;
      color: #64748b;
    }

.matchup-hr-explanation {
      font-size: 0.73rem;
      line-height: 1.42;
      color: var(--text-secondary);
    }

.matchup-hr-meta {
      display: grid;
      gap: 0.24rem;
    }

.matchup-hr-meta-item {
      display: flex;
      justify-content: space-between;
      gap: 0.45rem;
      font-size: 0.72rem;
      color: var(--text-secondary);
      padding-bottom: 0.24rem;
      border-bottom: 1px solid rgba(226,232,240,.9);
    }

.matchup-hr-meta-item:last-child {
      border-bottom: none;
      padding-bottom: 0;
    }

.matchup-hr-meta-item strong {
      color: var(--text-primary);
      text-align: right;
    }

.matchup-hr-sections {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
      gap: 0.52rem;
    }

.matchup-hr-section-title {
      margin-bottom: 0.34rem;
      font-size: 0.72rem;
      font-weight: 700;
      color: var(--text-primary);
    }

.matchup-hr-list {
      display: grid;
      gap: 0.24rem;
    }

.matchup-hr-list-row {
      display: flex;
      justify-content: space-between;
      gap: 0.45rem;
      font-size: 0.71rem;
      color: var(--text-secondary);
      padding-bottom: 0.22rem;
      border-bottom: 1px solid rgba(226,232,240,.78);
    }

.matchup-hr-list-row:last-child {
      border-bottom: none;
      padding-bottom: 0;
    }

.matchup-hr-list-row strong {
      color: var(--text-primary);
      text-align: right;
    }

.matchup-lp-header {
      display: flex; align-items: flex-start;
      justify-content: space-between; gap: 0.75rem;
      margin-bottom: 0.6rem; flex-wrap: wrap;
    }

.matchup-lp-title { font-size: 0.92rem; font-weight: 700; color: var(--text-primary); margin-bottom: 1px; }

.matchup-lp-sub { font-size: 0.7rem; color: var(--text-secondary); }

.matchup-close-btn {
      background: none; border: 1px solid var(--border-line);
      border-radius: var(--radius-sm); padding: 0.24rem 0.62rem;
      font-size: 0.68rem; cursor: pointer; color: var(--text-secondary);
      white-space: nowrap; font-family: inherit;
    }

.matchup-close-btn:hover { background: var(--bg-page); }

.matchup-sp-strip,
    .matchup-pitcher-splits {
      min-width: 0;
      padding: 0.68rem 0.72rem;
      border: 1px solid rgba(203, 213, 225, 0.88);
      border-radius: 0.86rem;
      background: linear-gradient(180deg, rgba(255,255,255,0.96) 0%, rgba(248,250,252,0.96) 100%);
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.88);
    }

.matchup-overview-card-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 0.7rem;
      margin-bottom: 0.52rem;
    }

.matchup-overview-card-title {
      font-size: 0.68rem;
      font-weight: 850;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--text-primary);
      white-space: nowrap;
    }

.matchup-overview-card-badge,
    .matchup-ls-trend {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 1.35rem;
      padding: 0.16rem 0.44rem;
      border: 1px solid rgba(148, 163, 184, 0.26);
      border-radius: 999px;
      background: rgba(241,245,249,0.9);
      color: var(--text-secondary);
      font-size: 0.6rem;
      font-weight: 800;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      white-space: nowrap;
    }

.matchup-ls-trend-good {
      border-color: rgba(22, 163, 74, 0.18);
      background: rgba(22, 163, 74, 0.1);
      color: #15803d;
    }

.matchup-ls-trend-bad {
      border-color: rgba(220, 38, 38, 0.18);
      background: rgba(220, 38, 38, 0.1);
      color: #b91c1c;
    }

.matchup-overview-empty {
      padding: 0.55rem 0;
      color: var(--text-secondary);
      font-size: 0.74rem;
    }

.matchup-sp-table {
      width: 100%;
      border-collapse: collapse;
      table-layout: fixed;
      font-size: 0.72rem;
      font-variant-numeric: tabular-nums;
    }

.matchup-sp-table th,
    .matchup-sp-table td {
      padding: 0.34rem 0;
      border-top: 1px solid rgba(226,232,240,.86);
      vertical-align: middle;
    }

.matchup-sp-table tr:first-child th,
    .matchup-sp-table tr:first-child td {
      border-top: none;
      padding-top: 0;
    }

.matchup-sp-table tr:last-child th,
    .matchup-sp-table tr:last-child td {
      padding-bottom: 0;
    }

.matchup-sp-table th {
      width: 25%;
      padding-right: 0.52rem;
      text-align: left;
      color: var(--text-secondary);
      font-size: 0.58rem;
      font-weight: 850;
      letter-spacing: 0.07em;
      text-transform: uppercase;
      white-space: nowrap;
    }

.matchup-sp-table td {
      width: 25%;
      color: var(--text-primary);
      font-size: 0.78rem;
      font-weight: 800;
      text-align: right;
      white-space: nowrap;
    }

.matchup-sp-table td + th {
      padding-left: 0.78rem;
    }

.matchup-sp-empty {
      border-top-color: transparent !important;
    }

.matchup-splits-table {
      width: 100%;
      border-collapse: collapse;
      table-layout: fixed;
      font-size: 0.7rem;
      font-variant-numeric: tabular-nums;
    }

.matchup-splits-table th,
    .matchup-splits-table td {
      padding: 0.3rem 0.32rem;
      border-top: 1px solid rgba(226,232,240,.86);
      vertical-align: middle;
      white-space: nowrap;
    }

.matchup-splits-table thead th {
      padding-top: 0;
      color: var(--text-secondary);
      font-size: 0.54rem;
      font-weight: 850;
      letter-spacing: 0.07em;
      text-transform: uppercase;
      text-align: right;
    }

.matchup-splits-table thead th:first-child {
      text-align: left;
    }

.matchup-splits-table tbody th {
      width: 36%;
      text-align: left;
      color: var(--text-primary);
    }

.matchup-splits-table td {
      text-align: right;
      color: var(--text-primary);
      font-weight: 800;
    }

.matchup-splits-table tbody tr:last-child th,
    .matchup-splits-table tbody tr:last-child td {
      padding-bottom: 0;
    }

.matchup-split-label,
    .matchup-split-scope,
    .matchup-split-sample {
      display: block;
      line-height: 1.12;
    }

.matchup-split-label {
      font-size: 0.68rem;
      font-weight: 900;
      letter-spacing: 0.04em;
    }

.matchup-split-scope,
    .matchup-split-sample {
      margin-top: 0.12rem;
      color: var(--text-secondary);
      font-size: 0.56rem;
      font-weight: 750;
      letter-spacing: 0.02em;
      text-transform: uppercase;
    }

.matchup-table-wrap { overflow-x: auto; overflow-y: visible; position: relative; }

.matchup-table {
      width: 100%; border-collapse: collapse; font-size: 0.75rem;
    }

.matchup-table th {
      text-align: left; padding: 0.38rem 0.3rem;
      background: var(--bg-page);
      font-weight: 700; font-size: 0.6rem;
      text-transform: uppercase; letter-spacing: .05em; color: var(--text-secondary);
      border-bottom: 1px solid var(--border-line);
      white-space: nowrap; position: relative; overflow: visible;
    }

.matchup-table td {
      padding: 0.38rem 0.3rem; border-bottom: 1px solid var(--border-line);
      vertical-align: middle; color: var(--text-primary); white-space: nowrap;
    }

.matchup-table tr:last-child td { border-bottom: none; }

.matchup-table tr:hover td { background: var(--bg-page); }

.matchup-order { font-size: 0.64rem; color: var(--text-secondary); font-weight: 600; min-width: 14px; }

.matchup-batter-name { font-weight: 700; }

.matchup-batter-trigger {
      display: inline-flex;
      align-items: center;
      gap: 0.24rem;
      border: none;
      padding: 0;
      background: none;
      color: var(--text-primary);
      font: inherit;
      font-weight: 700;
      font-size: 0.72rem;
      line-height: 1.1;
      cursor: pointer;
      text-align: left;
    }

.matchup-batter-trigger:hover {
      color: var(--primary);
      text-decoration: underline;
    }

.matchup-batter-trigger.active {
      color: var(--primary);
    }

.matchup-pos-badge {
      font-size: 0.6rem; background: var(--bg-page); color: var(--text-secondary);
      border: 1px solid var(--border-line);
      border-radius: 4px; padding: 1px 4px; display: inline-block;
      margin-left: 4px;
    }

.matchup-hand-badge {
      display: inline-block; font-size: 0.6rem; font-weight: 700;
      padding: 1px 4px; border-radius: 4px;
    }

.matchup-hand-L { background: #eff6ff; color: #1d4ed8; }

.matchup-hand-R { background: #fff7ed; color: #c2410c; }

.matchup-hand-S { background: #f0fdf4; color: #15803d; }

.matchup-adv-badge {
      display: inline-block; font-size: 0.6rem; font-weight: 600;
      padding: 1px 4px; border-radius: 4px; white-space: nowrap;
    }

.matchup-adv-yes { background: #f0fdf4; color: #15803d; }

.matchup-adv-no  { background: #fef2f2; color: #b91c1c; }

.matchup-adv-neu { background: var(--bg-page); color: var(--text-secondary); }

.matchup-score-cell { white-space: nowrap; display: flex; align-items: center; gap: 0.4rem; }

.matchup-bar-wrap {
      display: inline-block; width: 46px; height: 4px;
      background: var(--border-line); border-radius: 3px;
      vertical-align: middle; overflow: hidden;
    }

.matchup-bar { height: 100%; border-radius: 3px; }

.matchup-score-num { font-size: 0.72rem; font-weight: 700; }

.matchup-spinner { text-align: center; padding: 2rem; color: var(--text-secondary); font-size: 0.85rem; }

.matchup-error {
      background: #fef2f2; color: #b91c1c;
      padding: 0.65rem 0.9rem; border-radius: var(--radius-sm);
      font-size: 0.8rem; margin: 0.5rem 0; border: 1px solid #fecaca;
    }

.matchup-no-games { text-align: center; padding: 2.5rem; color: var(--text-secondary); font-size: 0.85rem; }

.matchup-footnote { font-size: 0.7rem; color: var(--text-secondary); margin-top: 0.75rem; line-height: 1.5; }

.matchup-reg-strip { display: flex; gap: 0.4rem; flex-wrap: wrap; }

.matchup-reg-badge {
      font-size: 0.66rem; font-weight: 600; padding: 2px 7px; border-radius: 6px;
      display: inline-flex; align-items: center; gap: 3px;
    }

.matchup-reg-improve { background: #f0fdf4; color: #15803d; }

.matchup-reg-regress { background: #fef2f2; color: #b91c1c; }

.matchup-last-starts {
      min-width: 0;
      padding: 0.68rem 0.72rem;
      border: 1px solid rgba(203, 213, 225, 0.88);
      border-radius: 0.86rem;
      background: linear-gradient(180deg, rgba(248,250,252,0.96) 0%, rgba(241,245,249,0.96) 100%);
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.88);
    }

.matchup-ls-scroll {
      overflow-x: auto;
      scrollbar-gutter: stable;
      -webkit-overflow-scrolling: touch;
    }

.matchup-ls-table {
      width: 100%;
      min-width: 42rem;
      border-collapse: collapse;
      table-layout: fixed;
      font-size: 0.7rem;
      font-variant-numeric: tabular-nums;
    }

.matchup-ls-table th,
    .matchup-ls-table td {
      padding: 0.34rem 0.48rem;
      border-bottom: 1px solid rgba(226,232,240,.92);
      text-align: left;
      white-space: nowrap;
    }

.matchup-ls-table th {
      color: var(--text-secondary);
      font-size: 0.56rem;
      font-weight: 850;
      letter-spacing: 0.07em;
      text-transform: uppercase;
    }

.matchup-ls-table td {
      color: var(--text-primary);
    }

.matchup-ls-table th:first-child,
    .matchup-ls-table td:first-child {
      padding-left: 0;
    }

.matchup-ls-table th:last-child,
    .matchup-ls-table td:last-child {
      padding-right: 0;
    }

.matchup-ls-table tbody tr:last-child td {
      border-bottom: none;
    }

.matchup-ls-date { color: var(--text-secondary); }

.matchup-ls-opp { font-weight: 600; }

.matchup-ls-ip  { color: var(--text-secondary); }

.matchup-ls-er  { font-weight: 700; }

.matchup-ls-k   { color: var(--text-secondary); }

.matchup-ls-pitches,
    .matchup-ls-whiffs,
    .matchup-ls-swstr,
    .matchup-ls-csw,
    .matchup-ls-cswpct {
      color: var(--text-secondary);
      font-variant-numeric: tabular-nums;
    }

.matchup-status-bar {
      font-size: 0.68rem; color: var(--text-secondary);
      background: var(--bg-page); border-radius: var(--radius-sm);
      padding: 0.3rem 0.62rem;
      border: 1px solid var(--border-line); display: none;
    }

.matchup-status-bar.show { display: block; }

.matchup-tab-bar {
      display: inline-flex;
      align-items: center;
      gap: 0.16rem;
      width: fit-content;
      margin-bottom: 0.64rem;
      padding: 0.18rem;
      border: 1px solid rgba(203, 213, 225, 0.9);
      border-radius: 0.78rem;
      background: rgba(241,245,249,0.82);
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.72);
    }

.matchup-tab-btn {
      appearance: none;
      min-width: 4.8rem;
      padding: 0.36rem 0.74rem;
      border-radius: 0.58rem;
      font-size: 0.68rem;
      font-weight: 800;
      cursor: pointer;
      border: 1px solid transparent;
      background: transparent;
      color: var(--text-secondary);
      font-family: inherit;
      letter-spacing: 0.01em;
      transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    }

.matchup-tab-btn:hover {
      color: var(--text-primary);
      background: rgba(255,255,255,0.72);
    }

.matchup-tab-btn.active {
      background: #14253d;
      color: #fff;
      border-color: rgba(20, 37, 61, 0.78);
      box-shadow: 0 8px 18px rgba(20, 37, 61, 0.16);
    }

.matchup-tab-btn:focus-visible {
      outline: 2px solid rgba(37, 99, 235, 0.35);
      outline-offset: 2px;
    }

.matchup-panel-cols {
      display: grid;
      grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.45fr);
      gap: 0.68rem;
      align-items: start;
    }

.matchup-surface-panel {
      min-width: 0;
      padding: 0.72rem;
      border: 1px solid rgba(203, 213, 225, 0.9);
      border-radius: 0.92rem;
      background: linear-gradient(180deg, rgba(255,255,255,0.92) 0%, rgba(248,250,252,0.92) 100%);
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.82);
    }

.matchup-arsenal-section {
      display: grid;
      gap: 0.62rem;
      align-content: start;
    }

.matchup-panel-cols[data-view="arsenal"],
    .matchup-panel-cols[data-view="lineup"] {
      grid-template-columns: minmax(0, 1fr);
    }

@media (max-width: 900px) {
      .matchup-panel-cols,
      .matchup-panel-cols[data-view="both"],
      .matchup-panel-cols[data-view="arsenal"],
      .matchup-panel-cols[data-view="lineup"] {
        grid-template-columns: 1fr;
      }
      .matchup-lp-top-grid,
      .matchup-lp-top-grid.matchup-lp-top-grid-single,
      .matchup-lp-top-grid.matchup-lp-top-grid-duo {
        grid-template-columns: 1fr;
        max-width: none;
      }
      .matchup-drilldown-main-grid,
      .matchup-drilldown-context-grid {
        grid-template-columns: 1fr;
      }
      .matchup-analysis-secondary {
        display: grid;
        gap: 0.72rem;
      }
      .matchup-analysis-secondary > :nth-child(1),
      .matchup-analysis-secondary > :nth-child(2),
      .matchup-analysis-secondary > :nth-child(3) {
        grid-column: auto;
        grid-row: auto;
      }
      .matchup-drilldown-context-sections .matchup-hr-sections {
        grid-template-columns: 1fr;
      }
      .matchup-pitch-breakdown-row {
        grid-template-columns: minmax(0, 1fr) auto;
      }
      .matchup-pitch-breakdown-stats {
        grid-column: 1 / -1;
        justify-content: flex-start;
      }
      .matchup-drilldown-topline,
      .matchup-elo-board-grid {
        grid-template-columns: 1fr;
      }
      .matchup-elo-prob-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }
    }

.matchup-col-hd {
      font-size: 0.72rem; font-weight: 700; color: var(--text-primary);
      margin-bottom: 0.45rem; display: flex; align-items: center; gap: 0.35rem;
    }

.matchup-legend {
      display: flex;
      flex-wrap: wrap;
      gap: 0.28rem;
      margin-top: 0.32rem;
    }

.matchup-legend-item {
      display: inline-flex;
      align-items: center;
      gap: 0.28rem;
      padding: 0.16rem 0.42rem;
      border: 1px solid rgba(226,232,240,.9);
      border-radius: 999px;
      background: rgba(248,250,252,.88);
      font-size: 0.61rem;
      color: var(--text-secondary);
      line-height: 1.2;
      white-space: nowrap;
    }

.matchup-legend-swatch {
      display: inline-block;
      width: 0.5rem;
      height: 0.5rem;
      border-radius: 999px;
      flex: 0 0 auto;
    }

.matchup-legend-note {
      margin-top: 0.32rem;
      font-size: 0.63rem;
      line-height: 1.35;
      color: var(--text-secondary);
    }

.matchup-lineup-section,
    .matchup-analysis-section {
      display: grid;
      gap: 0.58rem;
      min-width: 0;
    }

.matchup-analysis-section {
      margin-top: 0.15rem;
    }

.matchup-arsenal-box {
      display: grid;
      gap: 0.42rem;
      background: transparent;
      border-radius: 0;
      border: none;
      padding: 0;
    }

.matchup-pitch-card {
      background: rgba(255,255,255,0.82);
      border-radius: 0.72rem;
      border: 1px solid rgba(226,232,240,.92);
      padding: 0.58rem 0.66rem;
      margin-bottom: 0;
      box-shadow: inset 0 1px 0 rgba(255,255,255,0.74);
    }

.matchup-pitch-row1 {
      display: flex; align-items: center;
      justify-content: space-between; margin-bottom: 3px;
    }

.matchup-pitch-name { font-size: 0.78rem; font-weight: 700; }

.matchup-pitch-usg { font-size: 0.72rem; color: var(--text-secondary); }

.matchup-pitch-bar-w {
      background: var(--border-line); border-radius: 3px; height: 4px;
      overflow: hidden; margin-bottom: 5px;
    }

.matchup-pitch-bar { height: 100%; border-radius: 3px; }

.matchup-pitch-stats {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(5.5rem, 1fr));
      gap: 0.28rem;
    }

.matchup-ps {
      min-width: 0;
      padding: 0.24rem 0.3rem;
      border-radius: 0.46rem;
      background: rgba(248,250,252,.92);
      font-size: 0.68rem;
      color: var(--text-secondary);
    }

.matchup-ps strong { color: var(--text-primary); }

.matchup-pitch-breakdown-card {
      display: grid;
      gap: 0.44rem;
      background: linear-gradient(180deg, rgba(37, 99, 235, 0.035) 0%, rgba(255, 255, 255, 0.96) 100%);
    }

.matchup-pitch-breakdown-table {
      display: grid;
      gap: 0.26rem;
    }

.matchup-pitch-breakdown-grid {
      display: grid;
      gap: 0.24rem;
    }

.matchup-pitch-breakdown-row {
      display: grid;
      grid-template-columns: minmax(120px, 1.08fr) auto auto minmax(0, 1.55fr);
      align-items: center;
      gap: 0.42rem;
      padding: 0.34rem 0.18rem;
      border-radius: 0.62rem;
      border-top: 1px solid rgba(148, 163, 184, 0.16);
      background: transparent;
    }

.matchup-pitch-breakdown-row:first-child {
      border-top: none;
      padding-top: 0;
    }

.matchup-pitch-breakdown-name {
      font-size: 0.78rem;
      font-weight: 800;
      color: var(--text-primary);
      line-height: 1.18;
      min-width: 0;
    }

.matchup-pitch-breakdown-usage {
      font-size: 0.65rem;
      font-weight: 700;
      color: var(--text-secondary);
      white-space: nowrap;
    }

.matchup-pitch-breakdown-stats {
      display: flex;
      justify-content: flex-start;
      gap: 0.34rem;
      flex-wrap: wrap;
      font-size: 0.66rem;
      color: var(--text-secondary);
      min-width: 0;
    }

.matchup-pitch-breakdown-stats span {
      white-space: nowrap;
    }

.matchup-pitch-breakdown-note {
      font-size: 0.64rem;
      font-weight: 700;
      color: var(--text-secondary);
    }

.matchup-pitch-verdict {
      display: inline-flex;
      align-items: center;
      padding: 0.1rem 0.34rem;
      border-radius: 999px;
      font-size: 0.58rem;
      font-weight: 800;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      background: rgba(148, 163, 184, 0.14);
      border: 1px solid transparent;
    }

.matchup-pitch-verdict-good {
      color: var(--delta-up);
      background: rgba(22, 163, 74, 0.12);
      border-color: rgba(22, 163, 74, 0.18);
    }

.matchup-pitch-verdict-neutral {
      color: var(--primary);
      background: rgba(37, 99, 235, 0.1);
      border-color: rgba(37, 99, 235, 0.18);
    }

.matchup-pitch-verdict-weak {
      color: var(--delta-down);
      background: rgba(220, 38, 38, 0.1);
      border-color: rgba(220, 38, 38, 0.18);
    }

.matchup-whiff-badge {
      display: inline-block; font-size: 0.65rem; font-weight: 600;
      padding: 1px 5px; border-radius: 3px; margin-left: 3px;
    }

.matchup-wh-elite { background: #fef2f2; color: #b91c1c; }

.matchup-wh-high  { background: #fff7ed; color: #c2410c; }

.matchup-wh-avg   { background: #eff6ff; color: #1d4ed8; }

.matchup-wh-low   { background: #f0fdf4; color: #15803d; }

.matchup-table th.sortable { cursor: pointer; user-select: none; }

.matchup-table th.sortable:hover { color: var(--primary); }

.matchup-table th.matchup-season-2026-col {
      background: rgba(245, 158, 11, 0.14);
      color: #9a5b00;
    }

.matchup-table td.matchup-season-2026-cell {
      background: rgba(245, 158, 11, 0.08);
    }

.matchup-table tr:hover td.matchup-season-2026-cell {
      background: rgba(245, 158, 11, 0.14);
    }

.matchup-delta-up { background: #f0fdf4; color: #15803d; font-size: 0.7rem; font-weight: 700; padding: 1px 5px; border-radius: 4px; display: inline-block; }

.matchup-delta-dn { background: #fef2f2; color: #b91c1c; font-size: 0.7rem; font-weight: 700; padding: 1px 5px; border-radius: 4px; display: inline-block; }

.matchup-delta-fl { background: var(--bg-page); color: var(--text-secondary); font-size: 0.7rem; font-weight: 700; padding: 1px 5px; border-radius: 4px; display: inline-block; }

.matchup-bat-speed-cell { display: inline-flex; align-items: center; gap: 0.22rem; white-space: nowrap; }

.matchup-bat-speed-trend { font-size: 0.68rem; line-height: 1; font-weight: 900; }

.matchup-bat-speed-trend-up { color: #15803d; }

.matchup-bat-speed-trend-down { color: #b91c1c; }

.matchup-pill-row { display: flex; gap: 3px; flex-wrap: wrap; margin-top: 2px; }

.matchup-pill {
      font-size: 0.6rem; padding: 1px 4px; border-radius: 3px; white-space: nowrap;
    }

.matchup-pill-power  { background: #fff7ed; color: #c2410c; }

.matchup-pill-speed  { background: #f0fdf4; color: #15803d; }

.matchup-pill-chase  { background: #fef2f2; color: #b91c1c; }

.matchup-pill-xwoba  { background: #eff6ff; color: #1d4ed8; }

.matchup-lineup-tools {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      margin-bottom: 0.28rem;
      flex-wrap: wrap;
      gap: 0.45rem;
    }

.matchup-lineup-actions {
      display: flex;
      flex: 1;
      justify-content: flex-end;
      min-width: min(100%, 460px);
    }

.matchup-sort-label {
      font-size: 0.6rem;
      font-weight: 800;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--text-secondary);
      padding: 0.22rem 0.06rem;
    }

.matchup-sort-chips {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 0.28rem;
      flex-wrap: wrap;
      width: 100%;
    }

.matchup-sort-chip {
      appearance: none;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 0.22rem 0.5rem;
      border-radius: 999px;
      border: 1px solid var(--homepage-control-border);
      background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(241,245,249,0.98) 100%);
      color: var(--text-secondary);
      font-size: 0.64rem;
      font-weight: 700;
      letter-spacing: 0.01em;
      cursor: pointer;
      font-family: inherit;
      transition: transform 0.15s ease, border-color 0.15s ease, color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
    }

.matchup-sort-chip:hover {
      transform: translateY(-1px);
      border-color: rgba(37,99,235,.35);
      color: var(--primary);
    }

.matchup-sort-chip.active,
    .matchup-sort-chip[aria-pressed="true"] {
      background: linear-gradient(180deg, rgba(20, 37, 61, 0.96) 0%, rgba(31, 77, 122, 0.96) 100%);
      border-color: rgba(20, 37, 61, 0.75);
      color: #f8fbff;
      box-shadow: 0 8px 16px rgba(20, 37, 61, 0.16);
    }

.matchup-sort-chip:focus-visible {
      outline: 2px solid rgba(37, 99, 235, 0.35);
      outline-offset: 2px;
    }

.matchup-fantasy-note {
      font-size: 0.68rem;
      color: var(--text-secondary);
      margin-bottom: 0.25rem;
      line-height: 1.45;
      padding: 0.56rem 0.64rem;
      border: 1px solid rgba(226,232,240,.9);
      border-radius: 0.85rem;
      background: rgba(255,255,255,.72);
    }

.matchup-table-shell {
      border: 1px solid rgba(226,232,240,.9);
      border-radius: 0.9rem;
      background: rgba(255,255,255,.88);
      overflow: hidden;
    }

.matchup-footnote {
      font-size: 0.64rem;
      color: var(--text-secondary);
      line-height: 1.5;
      padding: 0.58rem 0.68rem;
      border: 1px solid rgba(226,232,240,.9);
      border-radius: 0.85rem;
      background: rgba(248,250,252,.9);
      margin-top: 0;
    }

@media (max-width: 600px) {
      .matchup-games-grid { grid-template-columns: 1fr; }
      .matchup-elo-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .matchup-elo-prob-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .matchup-hr-header { padding: 0.75rem 0.8rem 0.65rem; }
      .matchup-hr-body { padding: 0.68rem 0.72rem 0.74rem; }
      .homepage-matchup-heading,
      .matchup-lineup-tools {
        flex-direction: column;
        align-items: stretch;
      }
      .homepage-matchup-live {
        align-self: flex-start;
      }
      .matchup-date-nav {
        width: 100%;
      }
      .matchup-date-nav button,
      #matchup-date-input {
        flex: 1 1 calc(50% - 0.3rem);
        min-width: 0;
        justify-content: center;
      }
      .matchup-sort-chips {
        justify-content: flex-start;
      }
      .matchup-tab-bar {
        width: 100%;
      }
      .matchup-tab-btn {
        flex: 1 1 0;
        min-width: 0;
      }
      .matchup-sp-table {
        table-layout: auto;
      }
      .matchup-splits-table {
        table-layout: auto;
      }
      .matchup-sp-table th,
      .matchup-sp-table td {
        width: auto;
      }
      .matchup-drilldown-summary-strip,
      .matchup-elo-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }
      .matchup-drilldown-panel {
        padding: 0.58rem 0.62rem;
      }
    }

.homepage-momentum-card > .dash-card-header h3::before,
    .homepage-matchup-heading-copy h3::before {
      display: none;
    }

.homepage-matchup-heading-copy h3 {
      padding-left: 0.55rem;
      border-left: 3px solid var(--primary);
    }

.homepage-yesterday-pitchers-nav-btn,
    .matchup-date-nav button,
    .matchup-chip {
      transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
    }

.homepage-yesterday-pitchers-nav-btn:not(:disabled):hover,
    .matchup-date-nav button:hover,
    .matchup-chip:hover {
      border-color: color-mix(in srgb, var(--border-line) 50%, var(--primary) 50%);
    }

.matchup-game-card {
      transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
    }

.matchup-game-card:hover {
      border-color: color-mix(in srgb, var(--border-line) 55%, var(--primary) 45%);
      box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
      transform: translateY(-1px);
    }

.homepage-matchup-card.dash-card:hover {
      transform: none;
    }

.homepage-shell .matchup-chip {
      padding: 0.18rem 0.44rem;
      font-size: 0.64rem;
    }

.homepage-shell .matchup-date-nav button,
    .homepage-shell #matchup-date-input {
      padding: 0.28rem 0.52rem;
      font-size: 0.68rem;
    }

.homepage-shell .homepage-matchup-control-rail {
      gap: 0.38rem;
      padding: 0.48rem 0.52rem;
    }

