.performance-lineup,
.performance-program {
  --show-ink: #1b1822;
  --show-panel: #282334;
  --show-control: #392f48;
  --show-action: #675094;
  --show-action-hover: #755ca5;
  --show-highlight: #d9cbf7;
  --show-soft-text: #e6e1ef;
  --show-selected: #efe7fc;
  --show-control-rule: color-mix(in srgb, var(--show-highlight) 56%, var(--show-panel));
}

.performance-lineup:has(.performance-stage[data-show="newt"]),
.performance-program[data-show="newt"] {
  --show-panel: #193b35;
  --show-control: #254c44;
  --show-action: #206553;
  --show-action-hover: #287360;
  --show-highlight: #b8f4dd;
  --show-soft-text: #e4f2ed;
  --show-selected: #e1f9f0;
}

.performance-lineup:has(.performance-stage[data-show="library"]),
.performance-program[data-show="library"] {
  --show-panel: #40283a;
  --show-control: #552f49;
  --show-action: #824567;
  --show-action-hover: #925074;
  --show-highlight: #f4c3da;
  --show-soft-text: #f4e7ee;
  --show-selected: #fbe3f1;
}

:where(.performance-lineup, .performance-program) .button-primary {
  --action: var(--show-action);
  --action-hover: var(--show-action-hover);
  --violet: var(--show-control);
  --blue-border: var(--show-highlight);
  --blue-selected: var(--show-selected);
}

.performance-lineup {
  --lineup-measure: 1080px;
  --lineup-rule: color-mix(in srgb, var(--show-highlight) 19%, var(--show-ink));
  --lineup-light: var(--show-soft-text);
  color: var(--white);
  background: var(--show-ink);
}

.performance-lineup .show-heading {
  display: grid;
  justify-items: center;
  gap: .1em;
  font-size: clamp(3.25rem, 7.8vw, 5.85rem);
  font-weight: 850;
  line-height: 1.04;
  letter-spacing: -.07em;
  text-align: center;
}

.show-heading-prefix {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: .2em .55em;
  color: var(--white);
  font-size: .42em;
  font-weight: 820;
  line-height: 1.16;
  letter-spacing: -.035em;
}

.show-heading-join {
  display: inline-flex;
  align-items: center;
  gap: .3em;
  color: var(--show-soft-text);
  font-size: .76em;
  font-weight: 740;
  white-space: nowrap;
}

.show-heading-plus {
  display: inline-grid;
  inline-size: 1.52em;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid #9af7ff80;
  border-radius: 50%;
  background: #2c304b;
  color: #b6f5ff;
  box-shadow: 0 0 .65em #a78ae06b;
  font-weight: 840;
  line-height: 1;
}

.show-heading-main {
  max-inline-size: 100%;
  color: var(--show-highlight);
  font-size: clamp(2rem, 8.4vw, 5.85rem);
  letter-spacing: -.045em;
  overflow-wrap: anywhere;
  text-shadow: 0 0 .35em color-mix(in srgb, var(--show-highlight) 18%, transparent);
}

@supports (background-clip: text) or (-webkit-background-clip: text) {
  .show-heading-main {
    background-image: repeating-linear-gradient(90deg, #9af7ff 0%, #c7b2ff 17%, #ffb1ed 35%, #9af7ff 50%);
    background-size: 200% 100%;
    background-position: 0% 50%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: none;
    filter: drop-shadow(0 0 .07em #c7b2ff88) drop-shadow(0 0 .24em #b578f86e);
  }

  @media (prefers-reduced-motion: no-preference) {
    .show-heading-main {
      animation: performance-neon-flow 7.5s linear infinite paused;
    }

    .show-heading-main[data-neon-visible] {
      animation-play-state: running;
    }
  }
}

@keyframes performance-neon-flow {
  from { background-position: 0% 50%; }
  to { background-position: 100% 50%; }
}

@media (forced-colors: active) {
  .show-heading-plus { box-shadow: none; }

  .performance-lineup .show-heading-main {
    background: none;
    color: CanvasText;
    text-shadow: none;
    filter: none;
    animation: none;
  }
}

.performance-lineup :focus-visible { outline-color: var(--show-highlight); }

.performance-lineup .section-heading,
.performance-tabs,
.performance-stage {
  width: min(100%, var(--lineup-measure));
  margin-inline: auto;
}

.performance-tabs {
  --lineup-tab-inset: 4px;
  --lineup-tab-gap: 4px;
  --lineup-tab-size: calc((100% - 2 * (var(--lineup-tab-inset) + var(--lineup-tab-gap))) / 3);
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--lineup-tab-gap);
  margin-bottom: clamp(12px, 1.55vw, 20px);
  padding: var(--lineup-tab-inset);
  border-radius: var(--radius);
  background: var(--show-panel);
}

.performance-tabs:has([aria-selected="true"])::before {
  content: '';
  position: absolute;
  inset-block: var(--lineup-tab-inset);
  inset-inline-start: var(--lineup-tab-inset);
  inline-size: var(--lineup-tab-size);
  border-radius: var(--control-radius);
  background: var(--show-action);
  transform: translateX(calc(var(--lineup-tab-index, 0) * (100% + var(--lineup-tab-gap))));
  pointer-events: none;
}

.performance-tabs button {
  position: relative;
  min-width: 0;
  min-height: 52px;
  padding: 9px clamp(11px, 1.35vw, 18px);
  border: 1px solid transparent;
  border-radius: var(--control-radius);
  color: var(--lineup-light);
  background: transparent;
  font-size: clamp(.95rem, 1.24vw, 1.07rem);
  font-weight: 690;
  line-height: 1.3;
  text-align: center;
}

.performance-tabs button:hover { border-color: var(--show-control-rule); color: var(--white); }
.performance-tabs button[aria-selected="true"] {
  border-color: var(--show-highlight);
  color: var(--white);
}

.performance-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(15px, 2.35vw, 30px);
  padding: clamp(12px, 3vw, 38px);
  border-radius: var(--radius);
  background: var(--show-panel);
}

.performance-stage[hidden] { display: none; }
.performance-copy { min-width: 0; }

#lineup-add {
  min-height: 44px;
  margin-top: clamp(12px, 1.5vw, 20px);
  padding: 6px 13px;
  font-size: .875rem;
}

.performance-screen {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  min-height: 200px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--control-radius);
  color: var(--lineup-light, var(--program-muted, var(--paper)));
  background: var(--show-ink);
}

.performance-screen iframe {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

#lineup-video,
.lineup-gallery {
  width: min(100%, 48rem);
  min-width: 0;
  margin-inline: auto;
}

.lineup-gallery {
  padding-block-start: clamp(14px, 2.35vw, 28px);
  border-block-start: 1px solid var(--lineup-rule);
}

.lineup-gallery-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 14px;
  margin-bottom: 12px;
}

.lineup-gallery-heading h4 {
  margin: 0;
  font-size: clamp(1.05rem, 1.55vw, 1.32rem);
  font-weight: 750;
  line-height: 1.28;
}

.lineup-photo-controls {
  display: flex;
  flex: none;
  align-items: center;
  gap: 6px;
}

#lineup-photo-counter {
  position: relative;
  min-width: 3.6em;
  padding-block-end: 5px;
  color: var(--lineup-light);
  font-size: .9rem;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

#lineup-photo-counter::before,
#lineup-photo-counter::after {
  content: '';
  position: absolute;
  inset-inline: 5px;
  inset-block-end: 0;
  block-size: 2px;
  border-radius: 2px;
}

#lineup-photo-counter::before { background: color-mix(in srgb, var(--show-highlight) 44%, var(--show-panel)); }
#lineup-photo-counter::after {
  background: var(--show-highlight);
  transform: scaleX(var(--gallery-position, 0));
  transform-origin: left;
}

.lineup-photo-controls button {
  display: grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 1px solid var(--show-control-rule);
  border-radius: 10px;
  color: var(--white);
  background: var(--show-control);
  font-size: 1.15rem;
  line-height: 1;
}

.lineup-photo-controls button:disabled {
  color: var(--show-control-rule);
  cursor: default;
}

.lineup-photo-controls button:not(:disabled):hover { border-color: var(--show-highlight); }

.lineup-photo-track {
  position: relative;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 100%;
  gap: 12px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--show-control-rule) var(--show-ink);
}

.lineup-photo-slide {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border-radius: var(--control-radius);
  scroll-snap-align: start;
  background: var(--show-ink);
}

.lineup-photo-slide img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: contain;
}

@media (max-width: 620px) {
  .performance-tabs {
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: minmax(48px, 1fr);
  }

  .performance-tabs:has([aria-selected="true"])::before {
    inset-block: var(--lineup-tab-inset) auto;
    inset-inline: var(--lineup-tab-inset);
    inline-size: auto;
    block-size: var(--lineup-tab-size);
    transform: translateY(calc(var(--lineup-tab-index, 0) * (100% + var(--lineup-tab-gap))));
  }

  .performance-tabs button { min-height: 48px; }
  .lineup-gallery-heading { margin-bottom: 9px; }
}

@media (prefers-reduced-motion: no-preference) {
  .performance-tabs:has([aria-selected="true"])::before { transition: transform 260ms cubic-bezier(.2, .75, .25, 1); }
  .performance-tabs button { transition: color 170ms ease, border-color 170ms ease; }
  #lineup-photo-counter::after { transition: transform 210ms ease-out; }
}

@media (forced-colors: active) {
  .performance-tabs:has([aria-selected="true"])::before { display: none; }
  .performance-tabs button[aria-selected="true"] {
    forced-color-adjust: none;
    border-color: Highlight;
    color: HighlightText;
    background: Highlight;
  }

  .performance-tabs button:focus-visible { outline-color: Highlight; }
  #lineup-photo-counter::before,
  #lineup-photo-counter::after { forced-color-adjust: none; }
  #lineup-photo-counter::before { background: GrayText; }
  #lineup-photo-counter::after { background: Highlight; }
}
