:root {
  --bg: #050a14;
  --panel: rgba(7,14,27,.92);
  --gold: #ffd700;
  --gold-light: #fff0a1;
  --blue: #1e90ff;
  --blue-light: #77c0ff;
  --white: #f7f9ff;
  --muted: #94a4ba;
  --line-gold: rgba(255,215,0,.36);
  --line-blue: rgba(30,144,255,.30);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--white);
  font-family: "Aptos Display", system-ui, sans-serif;
  background:
    radial-gradient(900px 520px at 8% 8%, rgba(255,215,0,.11), transparent 64%),
    radial-gradient(980px 600px at 92% 88%, rgba(30,144,255,.15), transparent 66%),
    linear-gradient(145deg, #02060d 0%, #07101f 52%, #030812 100%);
}

.shell {
  width: min(1540px, calc(100% - 34px));
  margin: 0 auto;
  padding: 22px 0 40px;
}

.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  padding: 0 4px 12px;
}

.eyebrow {
  margin: 0 0 6px;
  color: #b7c4d5;
  font-size: .72rem;
  letter-spacing: .30em;
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 3.6vw, 3.6rem);
  line-height: .95;
  letter-spacing: .07em;
  background: linear-gradient(90deg, var(--gold), var(--gold-light) 48%, var(--blue));
  -webkit-background-clip: text;
  color: transparent;
}

.subtitle {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: .9rem;
}


.player-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.86fr) minmax(320px, .76fr);
  gap: 16px;
  align-items: start;
}

.player-panel {
  padding: 9px;
  border: 1px solid var(--line-gold);
  border-radius: 18px;
  background: rgba(4,9,18,.82);
}

.screen-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  border-radius: 12px;
  background: #000;
  border: 1px solid var(--line-blue);
}

.media-mode {
  position: absolute;
  inset: 0;
}

.hidden {
  display: none !important;
}

video {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
  object-fit: contain;
}

#audioMode {
  background: #02050a;
}

.audio-poster {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  background: #02050a;
}

.audio-controls-wrap {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 14px;
  z-index: 3;
  padding: 10px 12px;
  border: 1px solid rgba(255,215,0,.22);
  border-radius: 11px;
  background: rgba(3,8,16,.82);
}

.audio-controls-wrap audio {
  width: 100%;
  display: block;
}

.screen-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: radial-gradient(circle at center, #12223c 0%, #07101e 54%, #02050a 100%);
}

.play-mark {
  color: var(--gold);
  font-size: 2rem;
}

.now-strip {
  display: grid;
  grid-template-columns: auto 1fr;
  margin-top: 14px;
  min-height: 48px;
  border: 1px solid var(--line-gold);
  border-radius: 10px;
  overflow: hidden;
}

.now-label {
  display: flex;
  align-items: center;
  padding: 0 17px;
  color: var(--gold);
  border-right: 1px solid var(--line-gold);
  font-size: .67rem;
  font-weight: 800;
  letter-spacing: .13em;
}

.ticker-window {
  overflow: hidden;
  display: flex;
  align-items: center;
}

.ticker-track {
  width: max-content;
  white-space: nowrap;
  padding-left: 100%;
}

.ticker-running {
  animation: tickerMove 16s linear infinite;
}

@keyframes tickerMove {
  from { transform: translateX(0); }
  to { transform: translateX(-100%); }
}

.playlist-panel {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border: 1px solid var(--line-blue);
  border-radius: 18px;
  background: rgba(5,10,19,.88);
  overflow: hidden;
}

.playlist-window {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,215,0,.58) rgba(5,10,19,.45);
}

.playlist-window::-webkit-scrollbar {
  width: 8px;
}

.playlist-window::-webkit-scrollbar-track {
  background: rgba(5,10,19,.45);
}

.playlist-window::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(255,215,0,.72), rgba(30,144,255,.58));
  border-radius: 999px;
}

.playlist-header {
  padding: 17px 16px 14px;
  border-bottom: 1px solid rgba(255,215,0,.18);
}

.playlist-header h2 {
  margin: 0;
  color: var(--gold);
  font-size: .96rem;
  letter-spacing: .18em;
}

.playlist-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
}

.playlist-studio {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 2px 2px;
  padding: 9px 11px;
  border-left: 3px solid var(--gold);
  border-radius: 7px;
  color: var(--gold-light);
  background: linear-gradient(90deg, rgba(255,215,0,.08), rgba(30,144,255,.035));
  font-size: .80rem;
  font-weight: 900;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.playlist-studio:first-child {
  margin-top: 0;
}

.playlist-studio span {
  white-space: nowrap;
}

.playlist-group {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 2px 0;
  color: var(--gold);
  font-size: .70rem;
  font-weight: 800;
  letter-spacing: .16em;
}

.playlist-group::before,
.playlist-group::after {
  content: "";
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, rgba(255,215,0,.32));
}

.playlist-group::after {
  background: linear-gradient(90deg, rgba(30,144,255,.32), transparent);
}

.playlist-group span {
  white-space: nowrap;
}

.media-card {
  width: 100%;
  display: grid;
  grid-template-columns: 124px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  color: inherit;
  text-align: left;
  cursor: pointer;
  border-radius: 12px;
  border: 1px solid rgba(255,215,0,.16);
  background: rgba(9,17,31,.86);
}

.media-card.active {
  border-color: rgba(255,215,0,.68);
  box-shadow: inset 3px 0 0 var(--blue);
}

.thumb {
  position: relative;
  width: 124px;
  aspect-ratio: 16/9;
  overflow: hidden;
  border-radius: 8px;
  background: #06101e;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.type-badge {
  position: absolute;
  left: 6px;
  bottom: 6px;
  padding: 3px 6px;
  border: 1px solid rgba(255,215,0,.48);
  border-radius: 5px;
  color: var(--gold);
  background: rgba(2,6,12,.82);
  font-size: .64rem;
  font-weight: 800;
}

.media-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.media-info small {
  color: var(--muted);
}

.status-panel {
  display: grid;
  grid-template-columns: 190px 150px 150px 150px 140px 130px 1fr;
  margin-top: 16px;
  border: 1px solid rgba(30,144,255,.22);
  border-radius: 15px;
  overflow: hidden;
  background: rgba(8,15,28,.94);
}

.status-item,
.status-control {
  min-height: 78px;
}

.status-item {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 14px 20px;
  border-right: 1px solid rgba(255,255,255,.08);
}

.status-item span,
.status-control span {
  color: var(--muted);
  font-size: .68rem;
  letter-spacing: .12em;
}

.status-time strong {
  color: var(--blue-light);
  margin-top: 5px;
}

.status-control {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 12px 14px;
  color: var(--white);
  font: inherit;
  cursor: pointer;
  border: 0;
  border-right: 1px solid rgba(255,255,255,.08);
  background: transparent;
}

.status-control strong {
  color: var(--gold-light);
  font-size: 1.15rem;
  line-height: 1;
}

.status-control:hover,
.status-control:focus-visible {
  background: rgba(255,215,0,.055);
  outline: none;
}









.status-live strong {
  color: var(--muted);
  margin-top: 5px;
}

.status-live strong.online {
  color: var(--blue-light);
}

.live-mode {
  background: #000;
}

.live-mode iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  background: #000;
}

.live-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, #12223c 0%, #07101e 58%, #02050a 100%);
}

.live-dot {
  color: var(--gold);
  font-size: 1.65rem;
  text-shadow: 0 0 16px rgba(255,215,0,.32);
}

.live-card {
  border-color: rgba(30,144,255,.45);
}



@media (max-width: 760px) {
  .status-panel {
    grid-template-columns: repeat(2, 1fr);
  }

  .status-item,
  .status-control {
    min-height: 68px;
  }

  .status-live {
    border-right: 1px solid rgba(255,255,255,.08);
  }

  .status-invite {
    min-height: 68px;
  }
}

@media (max-width: 1100px) {
  .player-layout {
    grid-template-columns: 1fr;
  }

  .playlist-panel {
    height: auto !important;
  }

  .playlist-window {
    max-height: 620px;
  }
}


/* Węższy panel sterowania — ostatnie pole wykorzystujemy na zaproszenie. */



.status-repeat.active {
  background: rgba(255,215,0,.08);
}

.status-repeat.active strong,
.status-repeat.active span {
  color: var(--gold);
}

.status-invite {
  min-height: 78px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  padding: 14px 20px;
  text-align: right;
}

.status-invite span {
  color: var(--muted);
  font-size: .98rem;
  letter-spacing: .12em;
  white-space: nowrap;
}

.status-invite strong {
  color: var(--gold-light);
  margin-top: 5px;
}

@media (max-width: 980px) {
  .status-invite {
    align-items: flex-start;
    text-align: left;
  }
}


.status-radio {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 3px 6px;
  border-right: 1px solid rgba(255,255,255,.08);
  background: rgba(5,10,19,.26);
  text-decoration: none;
}

.status-radio-image {
  width: 100%;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 10px;
}

.status-radio img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center;
  transition: transform .18s ease, filter .18s ease;
}

.status-radio:hover img,
.status-radio:focus-visible img {
  transform: scale(1.035);
  filter: brightness(1.12);
}

.status-radio:focus-visible {
  outline: 2px solid var(--blue-light);
  outline-offset: -3px;
}

@media (max-width: 980px) {
  .status-panel {
    grid-template-columns: repeat(2, 1fr);
  }

  .status-radio {
    min-height: 68px;
  }

  .status-radio-image {
    height: 58px;
  }
}
