/* ============================================================================
   FIXTURES PAGE — TOURNAMENT PICKER + STATUS BADGES
   ============================================================================
   Companion to history_theme.css. Loaded only on fixtures_by_date.html.
   Scoped under .hist-page so rules don't leak.
   ============================================================================ */

/* ============================================================================
   PAGE LOADER — pawn icon, random animation, gold glow
   Mirrors the chess/news/sim/blog loader pattern (140x140 wrap, 80x80 icon,
   180x180 gold radial glow, 420ms minimum dwell, 10 animation variants).
   ============================================================================ */
.fix-loader {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw; height: 100vh; margin: 0;
  z-index: 9999;
  background: rgba(12,14,22,0.94);
  backdrop-filter: blur(28px) saturate(1.25);
  -webkit-backdrop-filter: blur(28px) saturate(1.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s cubic-bezier(.4,0,.2,1);
}
.fix-loader.active { opacity: 1; pointer-events: auto; }

.fix-loader-wrap {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 140px; height: 140px;
  pointer-events: none;
}
.fix-loader-inner {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  opacity: 1;
  transition: opacity 0.45s cubic-bezier(.4,0,.2,1);
}
.fix-loader:not(.active) .fix-loader-inner { opacity: 0; }
.fix-loader:not(.active) .fix-loader-icon,
.fix-loader:not(.active) .fix-loader-glow { animation-play-state: paused; }

.fix-loader-glow {
  position: absolute;
  top: 50%; left: 50%;
  width: 180px; height: 180px;
  margin: -90px 0 0 -90px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(233,196,106,0.4) 0%, rgba(233,196,106,0.1) 45%, transparent 72%);
  animation: fixLdPulse 1.8s ease-in-out infinite;
  pointer-events: none;
}
.fix-loader-icon {
  position: relative;
  width: 80px; height: 80px;
  filter: invert(1) drop-shadow(0 0 14px rgba(233,196,106,0.75)) drop-shadow(0 0 28px rgba(233,196,106,0.35));
  transform-origin: center center;
  will-change: transform;
  opacity: 0; transition: opacity .3s ease;
}
.fix-loader-icon.icon-ready { opacity: 1; }

/* 10 animation variants */
.fix-loader-icon.anim-shake     { animation: fixLdShake 0.7s cubic-bezier(.36,.07,.19,.97) infinite !important; }
.fix-loader-icon.anim-hop       { animation: fixLdHop 0.85s cubic-bezier(.5,0,.5,1) infinite !important; }
.fix-loader-icon.anim-swing     { animation: fixLdSwing 1.4s ease-in-out infinite !important; }
.fix-loader-icon.anim-spin      { animation: fixLdSpin 1.6s cubic-bezier(.7,0,.3,1) infinite !important; }
.fix-loader-icon.anim-float     { animation: fixLdFloat 2.2s ease-in-out infinite !important; }
.fix-loader-icon.anim-knight    { animation: fixLdKnight 1.3s cubic-bezier(.5,0,.5,1) infinite !important; }
.fix-loader-icon.anim-tumble    { animation: fixLdTumble 1.5s cubic-bezier(.45,.05,.55,.95) infinite !important; }
.fix-loader-icon.anim-heartbeat { animation: fixLdHeartbeat 1.1s ease-out infinite !important; }
.fix-loader-icon.anim-wobble    { animation: fixLdWobble 1.2s ease-in-out infinite !important; }
.fix-loader-icon.anim-drop      { animation: fixLdDrop 1.1s cubic-bezier(.5,.05,.5,.95) infinite !important; }

@keyframes fixLdPulse {
  0%, 100% { opacity: 0.55; transform: scale(0.9); }
  50%      { opacity: 1;    transform: scale(1.12); }
}
@keyframes fixLdShake {
  0%, 100% { transform: translate(0,0) rotate(0deg); }
  15% { transform: translate(-3px,-1px) rotate(-4deg); }
  30% { transform: translate(3px,1px) rotate(4deg); }
  45% { transform: translate(-3px,1px) rotate(-3deg); }
  60% { transform: translate(3px,-1px) rotate(3deg); }
  75% { transform: translate(-1px,0) rotate(-1deg); }
}
@keyframes fixLdHop {
  0%, 100% { transform: translateY(0) scaleY(1) scaleX(1); }
  20% { transform: translateY(0) scaleY(0.85) scaleX(1.1); }
  50% { transform: translateY(-18px) scaleY(1.1) scaleX(0.92); }
  80% { transform: translateY(0) scaleY(0.9) scaleX(1.08); }
}
@keyframes fixLdSwing {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(14deg); }
  75% { transform: rotate(-14deg); }
}
@keyframes fixLdSpin {
  0%   { transform: rotate(0deg) scale(1); }
  40%  { transform: rotate(180deg) scale(1.05); }
  100% { transform: rotate(360deg) scale(1); }
}
@keyframes fixLdFloat {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50%      { transform: translateY(-10px) rotate(2deg); }
}
@keyframes fixLdKnight {
  0%   { transform: translate(0,0); }
  25%  { transform: translate(0,-14px); }
  50%  { transform: translate(10px,-14px); }
  75%  { transform: translate(10px,0); }
  100% { transform: translate(0,0); }
}
@keyframes fixLdTumble {
  0%   { transform: rotate(0deg) translateY(0); }
  25%  { transform: rotate(90deg) translateY(-6px); }
  50%  { transform: rotate(180deg) translateY(0); }
  75%  { transform: rotate(270deg) translateY(-6px); }
  100% { transform: rotate(360deg) translateY(0); }
}
@keyframes fixLdHeartbeat {
  0%, 50%, 100% { transform: scale(1); }
  15% { transform: scale(1.18); }
  30% { transform: scale(0.95); }
}
@keyframes fixLdWobble {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  15% { transform: translateX(-10px) rotate(-6deg); }
  30% { transform: translateX(8px) rotate(5deg); }
  45% { transform: translateX(-6px) rotate(-4deg); }
  60% { transform: translateX(4px) rotate(3deg); }
  75% { transform: translateX(-2px) rotate(-1deg); }
}
@keyframes fixLdDrop {
  0%   { transform: translateY(-20px) scale(1,0.8); opacity: 0.6; }
  40%  { transform: translateY(0) scale(1.12,0.88); opacity: 1; }
  55%  { transform: translateY(-6px) scale(0.96,1.08); }
  80%  { transform: translateY(0) scale(1.04,0.96); }
  100% { transform: translateY(0) scale(1,1); }
}
.fix-loader-icon.anim-nod     { animation: fixLdNod 1.8s ease-in-out infinite !important; }
.fix-loader-icon.anim-peek    { animation: fixLdPeek 2.4s ease-in-out infinite !important; }
.fix-loader-icon.anim-breathe { animation: fixLdBreathe 2.6s ease-in-out infinite !important; }
.fix-loader-icon.anim-wiggle  { animation: fixLdWiggle 1.4s ease-in-out infinite !important; }
.fix-loader-icon.anim-tiptoe  { animation: fixLdTiptoe 1.6s ease-in-out infinite !important; }
.fix-loader-icon.anim-nuzzle  { animation: fixLdNuzzle 2s ease-in-out infinite !important; }
@keyframes fixLdNod {
    0%, 100% { transform: rotate(0) translateY(0); }
    30%      { transform: rotate(3deg) translateY(-3px); }
    60%      { transform: rotate(-2deg) translateY(-1px); }
}
@keyframes fixLdPeek {
    0%, 100% { transform: translateX(0) rotate(0); }
    25%      { transform: translateX(5px) rotate(3deg); }
    50%      { transform: translateX(0) rotate(0); }
    75%      { transform: translateX(-5px) rotate(-3deg); }
}
@keyframes fixLdBreathe {
    0%, 100% { transform: scale(1) translateY(0); }
    50%      { transform: scale(1.06) translateY(-3px); }
}
@keyframes fixLdWiggle {
    0%, 100% { transform: rotate(0); }
    20%      { transform: rotate(5deg); }
    40%      { transform: rotate(-4deg); }
    60%      { transform: rotate(3deg); }
    80%      { transform: rotate(-2deg); }
}
@keyframes fixLdTiptoe {
    0%, 100% { transform: translateY(0) scaleY(1); }
    40%      { transform: translateY(-6px) scaleY(1.03); }
    55%      { transform: translateY(-4px) scaleY(1); }
    70%      { transform: translateY(-6px) scaleY(1.02); }
}
@keyframes fixLdNuzzle {
    0%, 100% { transform: translate(0,0) rotate(0); }
    20%      { transform: translate(3px,-2px) rotate(4deg); }
    50%      { transform: translate(-2px,-3px) rotate(-3deg); }
    80%      { transform: translate(1px,-1px) rotate(2deg); }
}

@media (prefers-reduced-motion: reduce) {
  .fix-loader-icon, .fix-loader-glow { animation: none !important; }
}

/* ===== Tournament picker popup (vertical) ===== */
.fix-tp { position: relative; }

.fix-tp-trigger {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.3rem 0.65rem;
  border-radius: 6px;
  border: 1px solid var(--hi-border-lit, rgba(255,255,255,0.12));
  background: rgba(0,0,0,0.25);
  color: var(--hi-accent, #e9c46a);
  font-size: 0.62rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.8px;
  cursor: var(--cur-pointer, pointer);
  transition: border-color 0.2s, background 0.2s;
  white-space: nowrap;
  user-select: none;
}
.fix-tp-trigger-year {
  font-size: 0.72rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

/* Trigger flag — tighter than the default badge-xs (28px) so the trigger
   pill stays compact. Override scoped to the trigger only. */
.fix-tp-trigger .fix-tp-flag {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.fix-tp-trigger .fix-tp-flag .country-badge-wrapper.badge-xs {
  width: 20px;
  height: 20px;
}
.fix-tp-trigger .fix-tp-flag .country-badge.badge-xs,
.fix-tp-trigger .fix-tp-flag .country-badge-glass.badge-xs {
  width: 16px;
  height: 16px;
}
.fix-tp-trigger:hover {
  border-color: rgba(233,196,106,0.4);
  background: rgba(233,196,106,0.08);
}
.fix-tp.open .fix-tp-trigger .fix-tp-caret { transform: rotate(180deg); }

.fix-tp-popup {
  position: absolute;
  top: 50%;
  right: 0;
  transform-origin: right center;
  width: 180px;
  max-height: 340px;
  background: var(--hi-surface, #1a1f2e);
  border: 1px solid var(--hi-border-lit, rgba(255,255,255,0.12));
  border-radius: 10px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.5), 0 0 0 1px rgba(0,0,0,0.2);
  padding: 0;
  z-index: 1000;
  opacity: 0;
  transform: translateY(-50%) scale(0.97);
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
  overflow: hidden;
}
.fix-tp.open .fix-tp-popup {
  opacity: 1;
  transform: translateY(-50%) scale(1);
  pointer-events: auto;
}

/* Rail: vertical scroll */
.fix-tp-rail {
  overflow-y: auto; overflow-x: hidden;
  max-height: 336px;
  scrollbar-width: none;
  border-radius: 10px;
}
.fix-tp-rail::-webkit-scrollbar { display: none; }

/* Track: vertical column */
.fix-tp-track {
  display: flex; flex-direction: column;
  padding: 0.35rem 0;
}

/* Pills */
.fix-tp-pill {
  display: flex; align-items: center; gap: 0.55rem;
  padding: 0.4rem 0.75rem;
  border-left: 2px solid transparent;
  background: transparent;
  color: var(--hi-text-sec, #9ca3af);
  font-size: 0.65rem; font-weight: 600;
  text-decoration: none;
  cursor: var(--cur-pointer, pointer);
  transition: all 0.15s;
  white-space: nowrap;
  user-select: none;
}
.fix-tp-pill:hover {
  background: rgba(255,255,255,0.04);
  color: var(--hi-text, #f0f0f0);
  border-left-color: var(--pill-accent, transparent);
}
.fix-tp-pill.active {
  background: var(--hi-accent-dim, rgba(233,196,106,0.12));
  border-left-color: var(--hi-accent, #e9c46a);
  color: var(--hi-accent, #e9c46a);
  font-weight: 800;
}
.fix-tp-pill-flag {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.fix-tp-pill-text {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.05rem;
  min-width: 0;
}
.fix-tp-pill-year {
  font-size: 0.72rem; font-weight: 900;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.fix-tp-pill-host {
  font-size: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  opacity: 0.65;
  line-height: 1.1;
}

/* Pull glow bars (top / bottom) */
.fix-tp-pull {
  position: absolute; left: 0; right: 0;
  height: 5px; pointer-events: none;
  opacity: 0; z-index: 5;
  transition: opacity 0.15s;
}
.fix-tp-pull-top {
  top: 0;
  background: linear-gradient(180deg, var(--hi-accent, #e9c46a) 0%, transparent 100%);
}
.fix-tp-pull-bottom {
  bottom: 0;
  background: linear-gradient(0deg, var(--hi-accent, #e9c46a) 0%, transparent 100%);
}

/* Edge fades (top / bottom) */
.fix-tp-popup::before,
.fix-tp-popup::after {
  content: ''; position: absolute; left: 0; right: 0;
  height: 24px; pointer-events: none; z-index: 4;
}
.fix-tp-popup::before {
  top: 0;
  background: linear-gradient(180deg, var(--hi-surface, #1a1f2e) 0%, transparent 100%);
}
.fix-tp-popup::after {
  bottom: 0;
  background: linear-gradient(0deg, var(--hi-surface, #1a1f2e) 0%, transparent 100%);
}

/* ===== Icon base — consistent emoji treatment (matches chess mr-icon + blog glow) ===== */
.fix-icon {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
  vertical-align: middle;
  white-space: nowrap;
  font-family: 'Segoe UI Symbol', 'Apple Symbols', 'Noto Sans Symbols', 'Noto Sans Symbols 2', 'Noto Emoji', system-ui, sans-serif !important;
  font-variant-emoji: text;
  filter: brightness(0) invert(1);
  opacity: 0.6;
  transition: opacity 0.25s ease, filter 0.3s ease, transform 0.3s ease;
}

/* Hover: white glow */
a:hover .fix-icon,
button:hover .fix-icon,
.fix-icon-glow {
  opacity: 1;
  filter:
    brightness(0) invert(1)
    drop-shadow(0 0 0.6px rgba(255,255,255,0.85))
    drop-shadow(0 0 1.4px rgba(255,255,255,0.35));
}

/* Active/selected: gold glow */
.active .fix-icon,
.fix-icon-active {
  opacity: 1;
  filter:
    brightness(0) invert(1)
    drop-shadow(0 0 0.6px rgba(233,196,106,0.95))
    drop-shadow(0 0 1.6px rgba(233,196,106,0.45));
}

/* Prev/next navigation arrows — inline with button text */
.fix-nav-arrow {
  font-size: 0.55rem;
  opacity: 0.5;
  vertical-align: baseline;
  display: inline !important;
}
.btn:hover .fix-nav-arrow {
  opacity: 1;
  filter:
    brightness(0) invert(1)
    drop-shadow(0 0 0.6px rgba(233,196,106,0.95))
    drop-shadow(0 0 1.6px rgba(233,196,106,0.45));
}

/* Tournament picker caret — inherits .fix-icon base, custom sizing */
.fix-icon.fix-tp-caret {
  font-size: 0.5rem;
  opacity: 0.5;
}
.fix-tp-trigger:hover .fix-icon.fix-tp-caret {
  opacity: 0.8;
  filter:
    brightness(0) invert(1)
    drop-shadow(0 0 0.6px rgba(233,196,106,0.85))
    drop-shadow(0 0 1.2px rgba(233,196,106,0.35));
}
.fix-tp.open .fix-icon.fix-tp-caret {
  opacity: 1;
  filter:
    brightness(0) invert(1)
    drop-shadow(0 0 0.6px rgba(233,196,106,0.95))
    drop-shadow(0 0 1.6px rgba(233,196,106,0.45));
}

/* ===== Match status badges ===== */
.fix-match-status {
  display: inline-flex; align-items: center; gap: 0.25rem;
  font-size: 0.48rem; font-weight: 800;
  font-family: 'Segoe UI Symbol', 'Apple Symbols', 'Noto Sans Symbols', 'Noto Sans Symbols 2', 'Noto Emoji', system-ui, sans-serif;
  font-variant-emoji: text;
  text-transform: uppercase; letter-spacing: 0.6px;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  line-height: 1;
  white-space: nowrap;
  transition: filter 0.25s ease;
}
.fix-match-status.status-live {
  color: var(--hi-green, #4ade80);
  background: rgba(74,222,128,0.12);
}
.fix-match-row:hover .fix-match-status.status-live {
  filter:
    drop-shadow(0 0 1px rgba(74,222,128,0.7))
    drop-shadow(0 0 3px rgba(74,222,128,0.3));
}
.fix-match-status.status-ft {
  color: var(--hi-text-sec, #9ca3af);
  background: rgba(255,255,255,0.05);
}
.fix-match-row:hover .fix-match-status.status-ft {
  filter:
    drop-shadow(0 0 0.6px rgba(255,255,255,0.5))
    drop-shadow(0 0 1.4px rgba(255,255,255,0.2));
}
.fix-match-status.status-scheduled {
  color: var(--hi-text-dim, rgba(255,255,255,0.3));
}

/* Live pulsing dot */
.fix-live-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--hi-green, #4ade80);
  animation: fix-pulse 1.4s ease-in-out infinite;
  box-shadow: 0 0 0 rgba(74,222,128,0);
  transition: box-shadow 0.25s ease;
}
.fix-match-row:hover .fix-live-dot {
  box-shadow: 0 0 4px rgba(74,222,128,0.6), 0 0 8px rgba(74,222,128,0.25);
}
@keyframes fix-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.4; transform: scale(0.7); }
}

/* ===== Live match row — green accent ===== */
.fix-match-row[data-status="LIVE"] {
  border-color: rgba(74,222,128,0.30);
  border-left-color: #4ade80;
  background: color-mix(in srgb, #4ade80 8%, var(--hi-surface, #1a1f2e));
  animation: fix-row-breathe 2.8s ease-in-out infinite;
}
.fix-match-row[data-status="LIVE"]:hover {
  border-color: rgba(74,222,128,0.50);
  background: color-mix(in srgb, #4ade80 14%, var(--hi-surface, #1a1f2e));
}
.fix-match-row[data-status="LIVE"] .fix-match-score {
  color: #4ade80;
  text-shadow: 0 0 8px rgba(74,222,128,0.35);
}
.fix-match-row[data-status="LIVE"] .sc-sep {
  color: rgba(74,222,128,0.5);
}
.fix-match-row[data-status="LIVE"] .fix-stage-chip {
  color: #4ade80;
  border-color: rgba(74,222,128,0.30);
  background: rgba(74,222,128,0.08);
}
@keyframes fix-row-breathe {
  0%, 100% { box-shadow: 0 0 0 rgba(74,222,128,0); }
  50%      { box-shadow: 0 0 12px rgba(74,222,128,0.08), inset 0 0 12px rgba(74,222,128,0.03); }
}

/* Penalty shootout score */
.fix-match-pens {
  font-size: 0.52rem;
  font-weight: 700;
  color: var(--hi-text-sec, #9ca3af);
  text-align: center;
  margin-top: 1px;
}

/* TBD placeholder team label */
.fix-tbd {
  color: var(--hi-text-dim, rgba(255,255,255,0.3));
  font-style: italic;
  letter-spacing: 0.3px;
}

.fix-match-stage { text-align: right; }
/* Stage chip (inline) */
.fix-stage-chip {
  display: inline-block;
  font-size: 0.48rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.5px;
  color: var(--hi-text-sec, #9ca3af);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--hi-border, rgba(255,255,255,0.06));
  border-radius: 4px;
  padding: 0.12rem 0.4rem;
  white-space: nowrap;
  transition: color 0.2s, border-color 0.2s;
}
.fix-match-row:hover .fix-stage-chip {
  color: var(--hi-accent, #e9c46a);
  border-color: color-mix(in srgb, var(--hi-accent, #e9c46a) 25%, transparent);
}

/* ===== Hero day-summary chip strip ===== */
.fix-day-summary {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.85rem;
}
.fix-summary-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.32rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--hi-border, rgba(255, 255, 255, 0.08));
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.55rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--hi-text-sec, #9ca3af);
  white-space: nowrap;
  transition: border-color 0.25s, background 0.25s, color 0.25s;
}
.fix-summary-chip .fix-summary-num {
  font-size: 0.78rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  color: var(--hi-text, #f0f0f0);
}
.fix-summary-chip .fix-summary-lbl {
  opacity: 0.75;
}
.fix-summary-chip.total {
  border-color: color-mix(in srgb, var(--hi-accent, #e9c46a) 30%, transparent);
  background: color-mix(in srgb, var(--hi-accent, #e9c46a) 8%, transparent);
}
.fix-summary-chip.total .fix-summary-num {
  color: var(--hi-accent, #e9c46a);
  text-shadow: 0 0 8px color-mix(in srgb, var(--hi-accent, #e9c46a) 35%, transparent);
}
.fix-summary-chip.live {
  border-color: rgba(74, 222, 128, 0.45);
  background: rgba(74, 222, 128, 0.1);
  color: #4ade80;
}
.fix-summary-chip.live .fix-summary-num {
  color: #4ade80;
  text-shadow: 0 0 8px rgba(74, 222, 128, 0.5);
}
.fix-summary-chip.live .fix-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 6px rgba(74, 222, 128, 0.7);
  animation: fix-pulse 1.4s ease-in-out infinite;
}
.fix-summary-chip.ft {
  border-color: rgba(255, 255, 255, 0.1);
}
.fix-summary-chip.upcoming .fix-summary-num {
  color: var(--hi-text, #f0f0f0);
  opacity: 0.85;
}
@media (max-width: 576px) {
  .fix-day-summary { gap: 0.35rem; }
  .fix-summary-chip { padding: 0.28rem 0.55rem; font-size: 0.5rem; }
  .fix-summary-chip .fix-summary-num { font-size: 0.7rem; }
}

/* ===== Stage section header (when matches are grouped by stage) ===== */
.fix-stage-section-title {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin: 1.1rem 0 0.45rem;
  padding: 0 0.15rem;
}
.fix-stage-section-title:first-child {
  margin-top: 0;
}
a.fix-stage-link {
  text-decoration: none;
  cursor: var(--cur-pointer, pointer);
  transition: opacity 0.2s;
}
a.fix-stage-link:hover .fix-stage-section-label {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.fix-stage-section-label {
  font-size: 0.6rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--hi-accent, #e9c46a);
  white-space: nowrap;
  text-shadow: 0 0 8px color-mix(in srgb, var(--hi-accent, #e9c46a) 40%, transparent);
}
.fix-stage-section-rule {
  flex: 1 1 auto;
  height: 1px;
  background: linear-gradient(
    90deg,
    color-mix(in srgb, var(--hi-accent, #e9c46a) 35%, transparent) 0%,
    rgba(255, 255, 255, 0.04) 100%
  );
}
.fix-stage-section-count {
  font-size: 0.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--hi-text-dim, rgba(255, 255, 255, 0.35));
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* ===== Empty state ===== */
.fix-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 3rem 1rem;
  text-align: center;
  color: var(--hi-text-dim, rgba(255,255,255,0.3));
}
.fix-empty-icon.fix-icon {
  font-size: 2.2rem;
  margin-bottom: 0.6rem;
  opacity: 0.35;
  transition: opacity 0.4s ease, filter 0.4s ease;
}
.fix-empty:hover .fix-empty-icon.fix-icon {
  opacity: 0.55;
  filter:
    brightness(0) invert(1)
    drop-shadow(0 0 1px rgba(255,255,255,0.6))
    drop-shadow(0 0 3px rgba(255,255,255,0.2));
}
.fix-empty-title {
  font-size: 0.8rem; font-weight: 700;
  color: var(--hi-text-sec, #9ca3af);
  margin-bottom: 0.25rem;
}
.fix-empty-sub {
  font-size: 0.62rem;
  color: var(--hi-text-dim, rgba(255,255,255,0.3));
}

/* Venue label under kickoff time */
.fix-match-venue {
  display: block;
  font-size: 0.48rem;
  font-weight: 600;
  color: var(--hi-text-dim, rgba(255,255,255,0.3));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 90px;
  margin-top: 1px;
  transition: color 0.2s, max-width 0.3s ease;
}
.fix-match-row:hover .fix-match-venue {
  color: var(--hi-text-sec, #9ca3af);
  max-width: 220px;
  overflow: visible;
  text-overflow: clip;
}

/* ===== SPA fade transition (match content only) ===== */
#fixMatchContent {
  transition: opacity 0.16s ease;
}

/* ===== Mobile — controls bar ===== */
@media (max-width: 576px) {
  .fix-controls {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
  }
  .fix-controls > .fix-nav-group {
    order: 1;
    justify-content: flex-start;
  }
  .fix-controls > .fix-tp {
    order: 2;
    align-self: center;
  }
  .fix-tp-popup {
    right: 0; left: auto;
    transform: translateY(-50%) scale(0.97);
    transform-origin: right center;
  }
  .fix-tp.open .fix-tp-popup {
    transform: translateY(-50%) scale(1);
  }
}

/* ===== Mobile — match rows ===== */
@media (max-width: 576px) {
  .fix-match-row {
    grid-template-columns: 36px 1fr auto 1fr;
    gap: 0.3rem;
    padding: 0.5rem 0.6rem;
  }
  .fix-match-time {
    font-size: 0.62rem;
  }
  .fix-match-team {
    font-size: 0.62rem;
  }
  .fix-match-score {
    font-size: 0.7rem;
    min-width: 36px;
  }
  .fix-match-venue {
    max-width: 80px;
    font-size: 0.44rem;
  }
  .fix-match-stage {
    display: none;
  }
  .fix-stage-section-label {
    font-size: 0.52rem;
    letter-spacing: 1px;
  }
  .fix-stage-section-count {
    font-size: 0.42rem;
  }
}

/* ===== Mobile — venue label: allow 2-line wrap on touch (no hover) ===== */
@media (hover: none) and (max-width: 576px) {
  .fix-match-venue {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    line-height: 1.2;
    max-width: 90px;
  }
}

/* ===== Mobile — tournament picker popup ===== */
@media (max-width: 576px) {
  .fix-tp-popup {
    width: 200px;
  }
  .fix-tp-pill {
    padding: 0.35rem 0.6rem;
    font-size: 0.6rem;
  }
}

/* ===== Mobile — hero text scaling ===== */
@media (max-width: 576px) {
  .hist-page .hist-hero-title { font-size: 1.6rem; }
  .hist-page .hist-hero-sub   { font-size: 0.7rem; }
}

/* ===== Mobile — touch-friendly nav buttons ===== */
@media (max-width: 576px) {
  .fix-controls .btn {
    min-height: 36px;
    padding: 0.3rem 0.6rem;
    font-size: 0.55rem;
    min-width: 62px;
    text-align: center;
    justify-content: center;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
  }
  .fix-controls .btn-group {
    gap: 0;
  }
  .fix-tp-trigger {
    min-height: 44px;
    padding: 0.4rem 0.7rem;
  }
  .fix-date-nav-item {
    min-height: 44px;
    justify-content: center;
  }
}

/* ===== Mobile — date nav pills (single row handled by history_theme) ===== */
@media (max-width: 400px) {
  .fix-date-num {
    font-size: 0.62rem;
  }
}
