/* Play Queue — multi-link · social · cast out */

.mq-body {
  min-height: 100dvh;
  background: #0c0c0f;
  color: var(--text);
}

.mq-page {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
}

.mq-hero { margin-bottom: 1.1rem; }
.mq-hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  letter-spacing: -0.03em;
  margin: 0.2rem 0 0.45rem;
}
.mq-lede {
  color: var(--muted);
  font-size: 0.95rem;
  max-width: 42rem;
  line-height: 1.5;
}
.mq-lede strong { color: var(--text); }

.mq-panel {
  background: rgba(20, 20, 28, 0.92);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0.9rem 1rem 1rem;
  margin-bottom: 0.85rem;
}
.mq-panel h2 {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0;
  letter-spacing: -0.02em;
}

.mq-label {
  display: block;
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--faint);
  margin-bottom: 0.35rem;
}
.mq-label input {
  display: block;
  width: 100%;
  margin-top: 0.25rem;
  background: #0a0a10;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  padding: 0.45rem 0.55rem;
  font: 0.78rem/1.3 var(--mono);
}

#mq-input {
  width: 100%;
  box-sizing: border-box;
  background: #0a0a10;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 0.65rem 0.75rem;
  font: 0.82rem/1.4 var(--mono);
  resize: vertical;
  min-height: 4.5rem;
}
#mq-input:focus {
  outline: none;
  border-color: rgba(125, 211, 252, 0.45);
}

.mq-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin-top: 0.55rem;
}
.mq-hint {
  margin: 0.55rem 0 0;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}
.mq-hint.mono, .mq-hint code, .mono {
  font-family: var(--mono);
  font-size: 0.68rem;
  word-break: break-all;
}

.mq-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  gap: 0.85rem;
  margin-bottom: 0.85rem;
}
@media (max-width: 820px) {
  .mq-grid { grid-template-columns: 1fr; }
}

.mq-player-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.55rem;
}
.mq-status {
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--faint);
  max-width: 60%;
  text-align: right;
}
.mq-status.is-live { color: var(--live); }
.mq-status.is-err { color: var(--err); }
.mq-count {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--accent);
  font-weight: 500;
}

.mq-stage {
  position: relative;
  background: #050508;
  border-radius: 12px;
  border: 1px solid #1a1a22;
  overflow: hidden;
  min-height: 220px;
  aspect-ratio: 16 / 9;
}
.mq-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  display: block;
}
.mq-audio {
  width: 100%;
  margin-top: 0.35rem;
}
.mq-multi {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  width: 100%;
  height: 100%;
  background: #000;
}
.mq-multi-cell {
  position: relative;
  min-height: 0;
  background: #0a0a0e;
}
.mq-multi-cell video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.mq-multi-lab {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 0.2rem 0.35rem;
  font: 0.58rem/1.2 var(--mono);
  color: #c8c8d4;
  background: linear-gradient(transparent, rgba(0,0,0,0.85));
  pointer-events: none;
}

.mq-scrub-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.55rem;
}
.mq-scrub-row input[type="range"] {
  flex: 1 1 8rem;
  min-width: 6rem;
  accent-color: #6ee7b7;
}
.mq-time {
  font-family: var(--mono);
  font-size: 0.62rem;
  color: var(--faint);
  min-width: 5.5rem;
  text-align: right;
}
.mq-hint kbd {
  font-family: var(--mono);
  font-size: 0.65rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.05rem 0.28rem;
  background: #12121a;
}
.mq-transport {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  margin-top: 0.65rem;
}
.mq-mode {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--faint);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.mq-mode select {
  background: #12121a;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  padding: 0.3rem 0.4rem;
  font: 0.72rem/1 var(--mono);
}

.mq-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: min(52vh, 420px);
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.mq-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.35rem 0.5rem;
  padding: 0.5rem 0.55rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #0a0a10;
  cursor: pointer;
}
.mq-item.is-on {
  border-color: rgba(125, 211, 252, 0.45);
  background: rgba(125, 211, 252, 0.07);
}
.mq-item.is-playing {
  border-color: rgba(74, 222, 128, 0.5);
  box-shadow: inset 0 0 0 1px rgba(74, 222, 128, 0.15);
}
.mq-item.is-err { border-color: rgba(248, 113, 113, 0.4); }
.mq-item-title {
  font-size: 0.82rem;
  font-weight: 500;
  line-height: 1.3;
  word-break: break-word;
}
.mq-item-meta {
  font-family: var(--mono);
  font-size: 0.6rem;
  color: var(--faint);
  margin-top: 0.15rem;
}
.mq-item-meta .live { color: var(--live); }
.mq-item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem;
  align-content: start;
  justify-content: flex-end;
}
.mq-item-actions button {
  appearance: none;
  border: 1px solid var(--border);
  background: #14141c;
  color: var(--muted);
  border-radius: 6px;
  padding: 0.2rem 0.35rem;
  font: 600 0.6rem/1 var(--mono);
  cursor: pointer;
}
.mq-item-actions button:hover { color: var(--accent); border-color: rgba(125,211,252,0.4); }

.mq-out-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.45rem;
  margin-top: 0.55rem;
}
@media (max-width: 700px) {
  .mq-out-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 420px) {
  .mq-out-grid { grid-template-columns: 1fr; }
}
.mq-out-card {
  appearance: none;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #0a0a10;
  color: var(--text);
  padding: 0.7rem 0.75rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  transition: border-color 0.12s, background 0.12s;
}
.mq-out-card strong { font-size: 0.88rem; }
.mq-out-card span { font-size: 0.7rem; color: var(--faint); line-height: 1.35; }
.mq-out-card:hover {
  border-color: rgba(125, 211, 252, 0.4);
  background: rgba(125, 211, 252, 0.06);
}
.mq-hub-row { margin-top: 0.75rem; }
.mq-hub-row .mq-label { flex: 1 1 14rem; margin: 0; }

.mq-ingest { margin-top: 0.75rem; }
.mq-ingest-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.4rem;
  max-height: 9rem;
  overflow: auto;
}
.mq-ingest-chip {
  appearance: none;
  border: 1px solid var(--border);
  background: #0a0a10;
  color: var(--text);
  border-radius: 999px;
  padding: 0.3rem 0.65rem;
  font: 600 0.68rem/1.2 var(--mono);
  cursor: pointer;
  max-width: 100%;
}
.mq-ingest-chip:hover { border-color: rgba(125, 211, 252, 0.45); color: var(--accent); }
.mq-ingest-chip.is-ready { border-color: rgba(110, 231, 183, 0.35); }
.mq-ingest-chip:not(.is-ready) { opacity: 0.55; }
.mq-ingest-chip .bmd { color: #fbbf24; }
.mq-ingest-chip .xr { color: #c084fc; }

/* TV / player out mode — chrome minimal */
body.mq-out-tv .nav,
body.mq-out-tv .mq-hero,
body.mq-out-tv .mq-add,
body.mq-out-tv .mq-list-wrap,
body.mq-out-tv .mq-out,
body.mq-out-tv .mq-browse {
  display: none !important;
}
body.mq-out-tv .mq-page { max-width: none; padding: 0; }
body.mq-out-tv .mq-grid { display: block; margin: 0; }
body.mq-out-tv .mq-player-wrap {
  border: 0;
  border-radius: 0;
  min-height: 100dvh;
  background: #000;
  padding: 0;
}
body.mq-out-tv .mq-stage {
  min-height: 100dvh;
  aspect-ratio: auto;
  border: 0;
  border-radius: 0;
}
body.mq-out-tv .mq-transport {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 5;
  padding: 0.75rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.9));
  opacity: 0;
  transition: opacity 0.2s;
}
body.mq-out-tv .mq-player-wrap:hover .mq-transport,
body.mq-out-tv .mq-transport:focus-within {
  opacity: 1;
}
body.mq-out-tv .mq-player-head {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 5;
  padding: 0.65rem 0.85rem;
  background: linear-gradient(rgba(0,0,0,0.75), transparent);
  opacity: 0;
}
body.mq-out-tv .mq-player-wrap:hover .mq-player-head { opacity: 1; }
