.performance-page {
  background:
    radial-gradient(circle at top, rgba(37, 99, 235, 0.20), transparent 40%),
    linear-gradient(180deg, #020617 0%, #0f172a 46%, #111827 100%);
  color: #e2e8f0;
}

.performance-main {
  padding: 7rem 1rem 4rem;
}

.performance-shell {
  max-width: 1240px;
  margin: 0 auto;
}

.performance-hero {
  padding: 1.5rem 0 2rem;
}

.performance-hero-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.85fr);
  align-items: end;
}

.performance-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(96, 165, 250, 0.35);
  background: rgba(15, 23, 42, 0.75);
  color: #93c5fd;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.performance-hero h1 {
  margin: 1rem 0 0.9rem;
  font-size: clamp(2.2rem, 4vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
  color: #f8fafc;
}

.performance-hero p {
  max-width: 56rem;
  margin: 0;
  color: rgba(226, 232, 240, 0.88);
  font-size: 1.02rem;
  line-height: 1.7;
}

.performance-summary-card {
  padding: 1.4rem;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 1.25rem;
  background: rgba(15, 23, 42, 0.82);
  box-shadow: 0 24px 60px rgba(2, 6, 23, 0.36);
}

.performance-summary-card h2 {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  color: #f8fafc;
}

.performance-summary-card ul {
  margin: 0;
  padding-left: 1.15rem;
  color: rgba(226, 232, 240, 0.82);
}

.performance-summary-card li + li {
  margin-top: 0.6rem;
}

.performance-controls {
  margin-top: 2rem;
  padding: 1.1rem;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 1.25rem;
  background: rgba(15, 23, 42, 0.78);
  display: grid;
  gap: 1rem;
}

.performance-status {
  padding: 0.85rem 1rem;
  border-radius: 0.9rem;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(2, 6, 23, 0.42);
  color: #cbd5e1;
  font-size: 0.95rem;
}

.performance-status[data-tone="success"] {
  color: #bbf7d0;
  border-color: rgba(34, 197, 94, 0.28);
  background: rgba(20, 83, 45, 0.25);
}

.performance-status[data-tone="error"] {
  color: #fecaca;
  border-color: rgba(239, 68, 68, 0.28);
  background: rgba(127, 29, 29, 0.26);
}

.performance-filter-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: end;
}

.performance-field {
  display: grid;
  gap: 0.45rem;
}

.performance-field label {
  font-size: 0.88rem;
  color: #cbd5e1;
}

.performance-field select,
.performance-field output {
  min-height: 3rem;
  width: 100%;
  min-width: 0;
  border-radius: 0.95rem;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(2, 6, 23, 0.65);
  color: #f8fafc;
  padding: 0.75rem 0.9rem;
  font-size: 0.97rem;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

.performance-field output {
  display: flex;
  align-items: center;
}

#performance-month-updated {
  display: block;
  white-space: normal;
  text-overflow: clip;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.performance-jump-hint {
  margin: 0;
  color: rgba(148, 163, 184, 0.92);
  font-size: 0.92rem;
}

.performance-carousel {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
}

.performance-arrow {
  display: none !important;
}

.performance-carousel-window {
  overflow: hidden;
  padding: 0 0.65rem;
}

.performance-carousel-track {
  display: flex;
  gap: 1.2rem;
  transition: transform 0.35s ease;
  will-change: transform;
}

.performance-card {
  flex: 0 0 min(1080px, calc(100vw - 9rem));
  width: min(1080px, calc(100vw - 9rem));
  padding: 1.2rem;
  border-radius: 1.45rem;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.96) 0%, rgba(17, 24, 39, 0.96) 100%);
  box-shadow: 0 28px 70px rgba(2, 6, 23, 0.36);
  opacity: 0.46;
  transform: scale(0.97);
  transition: opacity 0.35s ease, transform 0.35s ease, border-color 0.35s ease;
}

.performance-card.is-active {
  opacity: 1;
  transform: scale(1);
  border-color: rgba(96, 165, 250, 0.34);
}

.performance-card.is-neighbour {
  opacity: 0.74;
}

.performance-card-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
}

.performance-eyebrow {
  margin: 0;
  color: #93c5fd;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.77rem;
}

.performance-card-header h2 {
  margin: 0.45rem 0 0.3rem;
  color: #f8fafc;
  font-size: clamp(1.4rem, 2.2vw, 2rem);
}

.performance-headline {
  margin: 0;
  color: rgba(226, 232, 240, 0.9);
}

.performance-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: flex-end;
}

.performance-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.2rem;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(2, 6, 23, 0.52);
  color: #cbd5e1;
  font-size: 0.86rem;
  white-space: nowrap;
}

.performance-badge-primary {
  border-color: rgba(96, 165, 250, 0.34);
  color: #dbeafe;
}

.performance-card-body {
  margin-top: 1.2rem;
  display: grid;
  gap: 1.2rem;
  grid-template-columns: minmax(0, 1.04fr) minmax(320px, 0.96fr);
  align-items: start;
}

.performance-chart-panel,
.performance-details-panel {
  min-width: 0;
}

.performance-chart-panel {
  padding: 1rem;
  border-radius: 1.2rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.36);
  position: relative;
}

.performance-mobile-arrows {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  padding: 0 0.8rem;
}

.performance-overlay-arrow {
  pointer-events: auto;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.25);
  color: #f8fafc;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: background 0.2s, transform 0.2s, border-color 0.2s;
  box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

.performance-overlay-arrow:hover {
  background: rgba(30, 41, 59, 0.95);
  transform: scale(1.08);
  border-color: rgba(96, 165, 250, 0.4);
}

.performance-overlay-arrow svg {
  width: 22px;
  height: 22px;
}

.performance-chart-panel img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0.9rem;
  background: #020617;
}

.performance-details-panel {
  display: grid;
  gap: 1rem;
}

.performance-stat-grid {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.performance-stat-grid-duo {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}



.performance-x10-highlight {
  font-size: clamp(2.2rem, 5vw, 2.85rem);
  font-weight: 800;
  color: #bae6fd;
  text-shadow: 0 0 20px rgba(56, 189, 248, 0.45);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.performance-base-move {
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  color: #94a3b8;
  font-weight: 500;
}

.performance-stat-card {
  padding: 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.46);
  display: grid;
  gap: 0.3rem;
}

.performance-stat-card strong {
  color: #f8fafc;
  font-size: 1.18rem;
}

.performance-stat-card-accent {
  border-color: rgba(56, 189, 248, 0.45) !important;
  background: linear-gradient(135deg, rgba(8, 47, 73, 0.65) 0%, rgba(2, 6, 23, 0.9) 100%) !important;
  box-shadow: 0 0 25px rgba(56, 189, 248, 0.12);
}

.performance-hero-stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem !important;
  border-width: 1px;
}

.performance-hero-stat-left {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.performance-hero-stat-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.3rem;
}

.performance-hero-label {
  color: #38bdf8 !important;
  font-size: 0.95rem !important;
  margin-bottom: 0 !important;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.performance-controls-slot .performance-controls {
  margin-top: 0;
  margin-bottom: 0.9rem;
  background: rgba(2, 6, 23, 0.35);
  border: 1px solid rgba(148, 163, 184, 0.12);
}

.performance-card-badges-start {
  justify-content: flex-start;
}

.performance-section {
  padding: 1rem;
  border-radius: 1.05rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.42);
}

.performance-section-nested {
  padding: 0;
  border: 0;
  background: transparent;
}

.performance-trailing-window {
  margin-top: 1.35rem;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
}

.performance-trailing-header {
  margin-bottom: 0.95rem;
}

.performance-card-body-subsection {
  margin-top: 0.95rem;
}

.performance-trailing-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(0, 1.04fr) minmax(320px, 0.96fr);
  align-items: start;
}

.performance-trailing-visual {
  display: grid;
  gap: 0.7rem;
}

.performance-chart-panel-secondary {
  background: rgba(2, 6, 23, 0.28);
}

.performance-trailing-details {
  gap: 0.95rem;
}

.performance-trailing-hint {
  margin: 0;
  text-align: center;
  color: rgba(148, 163, 184, 0.9);
  font-size: 0.86rem;
  display: none;
}

.performance-trailing-note {
  margin: 0;
  padding: 0.95rem 1rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.42);
  color: rgba(148, 163, 184, 0.94);
}

.performance-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.performance-section-head-wrap {
  flex-wrap: wrap;
}

.performance-section-head h3 {
  margin: 0;
  color: #f8fafc;
}

.performance-section-caption {
  margin: 0.35rem 0 0;
  color: rgba(148, 163, 184, 0.92);
  font-size: 0.92rem;
  line-height: 1.55;
}

.performance-section-head span,
.performance-mini-label,
.performance-muted {
  color: rgba(148, 163, 184, 0.9);
}

.performance-mini-label {
  display: block;
  font-size: 0.8rem;
  margin-bottom: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.performance-div-grid {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.performance-div-grid-range {
  padding: 1rem;
  border-radius: 1.05rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.42);
}

.performance-pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.performance-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.38rem 0.68rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.16);
  color: #e2e8f0;
  font-size: 0.82rem;
  line-height: 1.35;
}

.performance-move-list {
  display: grid;
  gap: 0.8rem;
}

.performance-move-card {
  padding: 0.9rem;
  border-radius: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(15, 23, 42, 0.72);
}

.performance-move-card-muted {
  background: rgba(15, 23, 42, 0.44);
}

.performance-move-head {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: center;
  flex-wrap: wrap;
}

.performance-rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  padding: 0.25rem 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(96, 165, 250, 0.25);
  color: #93c5fd;
  font-size: 0.82rem;
}

.performance-move-change {
  color: #f8fafc;
  font-weight: 700;
}

.performance-move-change-highlight {
  color: #bae6fd !important;
  font-weight: 800 !important;
  font-size: 1.05rem !important;
  text-shadow: 0 0 10px rgba(56, 189, 248, 0.4);
  background: rgba(14, 165, 233, 0.15);
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.performance-move-body {
  margin-top: 0.75rem;
  display: grid;
  gap: 0.8rem;
}

.performance-move-points {
  display: grid;
  gap: 0.7rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.performance-move-point {
  padding: 0.8rem;
  border-radius: 0.85rem;
  background: rgba(2, 6, 23, 0.48);
  border: 1px solid rgba(148, 163, 184, 0.12);
  display: grid;
  gap: 0.28rem;
}

.performance-move-point strong {
  color: #f8fafc;
}

.performance-move-point-label {
  color: #93c5fd;
  text-transform: uppercase;
  font-size: 0.76rem;
  letter-spacing: 0.05em;
}

.performance-mini-section {
  display: grid;
  gap: 0.8rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.performance-mini-section > div {
  padding: 0.8rem;
  border-radius: 0.85rem;
  background: rgba(2, 6, 23, 0.48);
  border: 1px solid rgba(148, 163, 184, 0.12);
}

.performance-empty {
  margin: 0;
  color: rgba(148, 163, 184, 0.92);
}

.performance-raw-summary {
  padding: 1rem;
  border-radius: 1.05rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(2, 6, 23, 0.42);
}

.performance-raw-summary summary {
  cursor: pointer;
  color: #f8fafc;
  font-weight: 600;
}

.performance-raw-summary pre {
  margin: 0.9rem 0 0;
  white-space: pre-wrap;
  word-break: break-word;
  color: #cbd5e1;
  font-size: 0.84rem;
  line-height: 1.6;
}

@media screen and (max-width: 991px) {
  .performance-hero-grid,
  .performance-card-body,
  .performance-trailing-grid,
  .performance-stat-grid-duo,
  .performance-div-grid,
  .performance-move-points,
  .performance-mini-section {
    grid-template-columns: 1fr;
  }
  .performance-filter-grid {
    grid-template-columns: 1fr;
  }

  #performance-month-updated {
    font-size: 0.92rem;
  }

  .performance-card-body {
    display: flex;
    flex-direction: column;
  }

  .performance-main {
    padding-top: 6.25rem;
  }

  .performance-card {
    flex-basis: calc(100vw - 5rem);
    width: calc(100vw - 5rem);
  }
}

@media screen and (max-width: 767px) {
  .performance-main {
    padding: 5.6rem 0.85rem 3.5rem;
  }

  .performance-controls,
  .performance-card,
  .performance-summary-card {
    border-radius: 1rem;
  }

  .performance-carousel {
    grid-template-columns: 1fr;
  }

  .performance-arrow {
    display: none;
  }

  .performance-carousel-window {
    order: -1;
    padding: 0;
  }

  .performance-filter-grid {
    grid-template-columns: 1fr;
  }

  .performance-card {
    flex-basis: calc(100vw - 1.7rem);
    width: calc(100vw - 1.7rem);
  }

  .performance-card-header {
    flex-direction: column;
  }

  .performance-card-badges {
    justify-content: flex-start;
  }

  .performance-trailing-window {
    margin-top: 1rem;
    padding-top: 1rem;
  }

  .performance-trailing-grid {
    gap: 0.9rem;
  }

  .performance-trailing-window .performance-card-header {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 0.7rem;
  }

  .performance-trailing-window .performance-card-badges {
    width: 100%;
    justify-content: flex-start;
    gap: 0.5rem;
  }

  .performance-trailing-window .performance-badge {
    min-height: 2rem;
    padding: 0.35rem 0.72rem;
    font-size: 0.8rem;
  }

  .performance-trailing-window .performance-chart-panel {
    padding: 0.75rem;
  }

  .performance-trailing-hint {
    display: block;
  }

  .performance-trailing-window .performance-hero-stat {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem !important;
  }

  .performance-trailing-window .performance-hero-stat-right {
    align-items: flex-start;
  }

  .performance-trailing-window .performance-stat-grid {
    gap: 0.75rem;
  }

  .performance-trailing-window .performance-stat-grid-duo {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
  }

  .performance-trailing-window .performance-stat-card {
    padding: 0.9rem;
  }

  .performance-trailing-window .performance-stat-card strong {
    font-size: 1.05rem;
  }

  .performance-trailing-window .performance-div-grid-range {
    padding: 0.9rem;
  }

  .performance-trailing-window .performance-move-head {
    align-items: flex-start;
  }
}

@media screen and (max-width: 420px) {
  .performance-trailing-window .performance-stat-grid-duo {
    grid-template-columns: 1fr;
  }
}
