@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Nunito:wght@200;300;400;500;600;700;800;900;1000&family=Roboto:wght@300;400;500;700&display=swap");

/* -------------------- Base Styles -------------------- */

*, *::before, *::after {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

body {
  font-family: "Nunito", sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background-image: url(https://cdn.midjourney.com/a462dd1e-9667-43ad-b46e-6b94a2976ebe/0_3.png);
  background-repeat: no-repeat;
  background-size: cover;
}

.demo-mode-top-button {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1200;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  color: #fff;
  background: rgba(254, 31, 169, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 10px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.demo-mode-top-button:hover {
  background: rgba(254, 31, 169, 0.98);
  border-color: rgba(255, 255, 255, 0.65);
  transform: translateY(-1px);
}

.demo-mode-top-button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

nav {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -o-user-select: none;
}

nav ul,
nav ul li {
  outline: 0;
}

nav ul li a {
  text-decoration: none;
}

img {
  width: 100%;
}

h1 {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
}

/* -------------------- Main Layout -------------------- */

main {
  display: block;
  width: 95%;
  height: 95vh;
  margin: 2.5vh auto;
  background: rgba(5, 5, 5, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 15px;
  box-shadow:
    0 0.5px 0 1px rgba(255, 255, 255, 0.23) inset,
    0 1px 0 0 rgba(255, 255, 255, 0.6) inset,
    0 4px 16px rgba(0, 0, 0, 0.12);
  z-index: 10;
  padding: 0;
  overflow: hidden;
}

/* -------------------- Main Menu -------------------- */

.main-menu {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.5);
  min-width: max-content;
}

.user-info {
  display: flex;
  align-items: center;
  min-width: max-content;
}

.user-info img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 10px;
  flex-shrink: 0;
}

.user-info p {
  color: #fff;
  font-size: clamp(0.8rem, 3vw, 1rem);
  font-weight: 500;
}

.nav-items {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 20px;
  min-width: max-content;
}

.nav-item {
  white-space: nowrap;
}

.nav-item a {
  display: flex;
  align-items: center;
  color: #fff;
  text-decoration: none;
  font-size: 0.9rem;
  padding: 8px 12px;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

.nav-item.active a,
.nav-item a:hover {
  background: rgba(106, 109, 155, 0.5);
}

.nav-icon {
  margin-right: 8px;
}

/* -------------------- Content Sections -------------------- */

/* Slider */
.slider-container {
  position: relative;
  padding: 20px 0;
}

.categories-slider {
  display: flex;
  gap: 20px;
  transition: transform 0.3s ease;
  padding: 10px 0;
}

.category-card {
  flex: 0 0 280px;
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  transition: transform 0.3s ease;
}

.category-card:hover {
  transform: translateY(-5px);
}

/* Navigation Buttons */
.slider-navigation {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  pointer-events: none;
  z-index: 10;
  padding: 0 10px;
}

.slider-prev,
.slider-next {
  background: rgba(0, 0, 0, 0.7);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: auto;
  transition: all 0.3s ease;
  color: white;
}

.slider-prev:hover,
.slider-next:hover {
  background: rgba(0, 0, 0, 0.9);
  transform: scale(1.1);
}

.slider-prev:disabled,
.slider-next:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Hide scrollbar but keep functionality */
.twitch-categories-container {
  overflow-x: hidden;
  margin: 0 -10px;
  padding: 0 10px;
}

.swiper {
  width: 100%;
  height: 100%;
  padding: 0px 0 5px;
  margin-bottom: 25px;
}

.swiper-slide {
  position: relative;
  width: auto;
  height: 240px;
  transition: transform 0.3s;
}

.swiper-slide-active {
  transform: scale(1.1);
}

.category-card {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 20px;
  aspect-ratio: 3 / 4;
}

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 2px solid rgba(159, 160, 168, 0.5);
  border-radius: 20px;
}

.slide-overlay {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  row-gap: 8px;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.7) 70%,
    rgba(0, 0, 0, 0.9) 100%
  );
  border-radius: 20px;
  padding: 12px;
  text-align: center;
}

.slide-overlay h2 {
  font-size: clamp(0.8rem, 2vw, 1rem);
  font-weight: 700;
  color: #fff;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
  margin-bottom: 4px;
}

.slide-overlay p {
  font-size: clamp(0.7rem, 1.5vw, 0.9rem);
  color: #e0e0e0;
  margin-bottom: 8px;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.slide-overlay button {
  display: flex;
  align-items: center;
  justify-content: center;
  column-gap: 5px;
  width: max-content;
  padding: 6px 10px;
  background: #e9e6eb2a;
  color: #e8e5e5;
  border: 1px solid rgba(159, 160, 168, 0.4);
  border-radius: 12px;
  outline: 0;
  font-size: clamp(0.6rem, 1.5vw, 0.8rem);
  font-weight: 500;
  text-transform: uppercase;
  box-shadow:
    rgba(0, 0, 0, 0.16) 0px 10px 36px 0px,
    rgba(0, 0, 0, 0.06) 0px 0px 0px 1px;
  transition: all 0.4s linear;
  cursor: pointer;
}

.slide-overlay button:hover {
  background: #ffffff2a;
  color: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.4);
  border-radius: 6px;
  transform: scale(1.05);
  transition: transform 0.3s ease;
}

/* Artists */
.artists {
  margin-top: 10px;
}

.artists h1 {
  margin-bottom: 24px;
}

.artists-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.artists-header h1 {
  margin-bottom: 8px;
  margin-right: 16px;
  flex-basis: 100%;
}

#streamSearch {
  flex-grow: 1;
  margin-right: 8px;
  margin-bottom: 8px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  color: #fff;
  font-family: "Nunito", sans-serif;
  font-size: 0.9rem;
  padding: 8px 16px;
  width: 200px;
  outline: none;
  transition: all 0.3s ease;
}

#streamSearch::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

#streamSearch:focus {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
}

.artist-container,
#backupStreams {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 12px;
  margin-bottom: 15px;
}

.artist,
.backup-stream,
.top-stream {
  position: relative;
  flex: 0 0 auto;
  width: 100px;
  margin-right: 12px;
  text-align: center;
}

.artist-img-container,
.backup-stream-img-container,
.top-stream-image-container {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 2px solid rgba(130, 130, 130, 0.5);
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 6px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
  overflow: hidden;
}

.artist img,
.backup-stream img,
.top-stream img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.artist:hover img,
.backup-stream:hover img,
.top-stream:hover img {
  transform: scale(1.1);
}

.artist p,
.backup-stream p {
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  font-weight: 500;
  margin-top: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#addStream,
#clearInitialStreams,
#clearBackupStreams {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  color: #fff;
  font-family: "Nunito", sans-serif;
  font-size: 0.9rem;
  padding: 8px 16px;
  margin-left: 10px;
  outline: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

#addStream:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
}

#clearInitialStreams:hover,
#clearBackupStreams:hover {
  background: rgba(255, 0, 0, 0.2);
  border-color: rgba(255, 0, 0, 0.3);
}

/* Albums */
.albums h1 {
  margin: 30px 0 10px;
}

.album-container {
  column-gap: 24px;
}

.album {
  display: grid;
  grid-auto-flow: dense;
  grid-template-rows: 5fr 2fr;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -o-user-select: none;
}

.album-frame {
  position: relative;
  width: 180px;
  aspect-ratio: 1 / 1;
  border: 2px solid rgba(169, 150, 253, 0.5);
  border-radius: 10px;
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 8px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
  margin-bottom: 15px;
  overflow: hidden;
}

.album-frame img {
  position: absolute;
  inset: 0;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s;
  pointer-events: none;
}

.album-frame:hover img {
  transform: rotate(3deg) scale(1.2);
}

.album h2 {
  font-size: clamp(0.9rem, 4vw, 1.1rem);
  font-weight: 500;
  line-height: 1.3;
  max-height: 2.6em;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-box-orient: vertical;
}

.album p {
  font-size: clamp(0.9rem, 4vw, 1rem);
  opacity: 0.5;
}

/* Songs */
.recommended-songs {
  margin-top: 20px;
}

.song-container {
  align-items: center;
}

.song {
  display: grid;
  grid-template-columns: 26% auto 10%;
  align-items: center;
  margin-bottom: 10px;
}

.song-img {
  position: relative;
  width: 60px;
  border-radius: 6px;
}

.song-img img {
  aspect-ratio: 4 / 3;
  border-radius: inherit;
  object-fit: cover;
  border: 2px solid rgba(159, 160, 168, 0.5);
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 6px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
  transition: all 0.2s;
  pointer-events: none;
}

.song-img .overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 92%;
  background-color: rgba(169, 150, 253, 0.6);
  border-radius: inherit;
  font-size: 1.75rem;
  opacity: 0;
  transition: all 0.4s linear;
  cursor: pointer;
}

.song-img:hover .overlay {
  opacity: 1;
}

.song h2 {
  font-size: 1rem;
}

.song p,
.song span {
  font-size: 0.8rem;
  font-weight: 300;
}

.song p {
  opacity: 0.8;
}

/* Featured Streamer */
.featured-streamer {
  flex-shrink: 0;
  margin-bottom: 20px;
}

.featured-streamer h1 {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.featured-streamer h1 #featuredStreamerName {
  margin-left: 10px;
  color: #a996fd;
  font-size: 0.9em;
}

.featured-streamer #featuredStreamerLink {
  margin-left: auto;
  color: #ffffff;
  text-decoration: none;
  font-size: 0.9em;
  transition: color 0.3s ease;
}

.featured-streamer #featuredStreamerLink:hover {
  color: #a996fd;
  text-decoration: underline;
}

.stream-embed {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  border-radius: 12px;
  overflow: hidden;
}

.stream-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Watch Parties */
.watch-parties {
  margin-top: 20px;
  height: auto;
}

.watch-parties h1 {
  margin: 0 0 10px;
}

.watch-party-container {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  padding-bottom: 15px;
  gap: 24px;
  height: auto;
  min-height: 275px;
}

.watch-party {
  display: inline-block;
  vertical-align: top;
  margin-right: 24px;
  white-space: normal;
  width: 180px;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  flex-shrink: 0;
}

.watch-party:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.watch-party:last-child {
  margin-right: 0;
}

.watch-party-frame {
  position: relative;
  width: 180px;
  height: 180px;
  border: 2px solid rgba(48, 53, 59, 0.5);
  border-radius: 10px;
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 8px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
  margin-bottom: 15px;
  overflow: hidden;
}

.watch-party-frame img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.8s;
}

.watch-party-frame:hover img {
  transform: scale(1.1);
}

.watch-party h2 {
  font-size: clamp(0.9rem, 4vw, 1.1rem);
  font-weight: 500;
  line-height: 1.3;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.watch-party p {
  font-size: clamp(0.8rem, 3.5vw, 0.9rem);
  opacity: 0.7;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Favorite Streamers */
.favorite-streamers {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  margin-top: 10px;
}

.favorite-streamers h1 {
  margin-bottom: 10px;
  align-content: center;
}

.favorite-streamers-container {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  overflow: hidden;
  width: 100%;
  max-height: calc(100vh - 250px);
  padding-right: -10px;
  padding-left: -10px;
  padding-top: 10px;
}

.favorite-streamer {
  flex: 0 0 calc(25% - 15px);
  max-width: calc(25% - 15px);
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.favorite-streamer .top-stream-container {
  width: 100%;
  padding-bottom: 100%;
  position: relative;
}

.favorite-streamer .top-stream-image-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(130, 130, 130, 0.5);
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 6px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
}

.favorite-streamer .top-stream-image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.favorite-streamer:hover .top-stream-image-container img {
  transform: scale(1.1);
}

.favorite-streamer .add-stream-btn {
  position: absolute;
  top: 0;
  right: 0;
  background-color: #0cb300;
  color: white;
  border: none;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  font-size: 18px;
  line-height: 24px;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.3s;
  z-index: 10;
}

.favorite-streamer .add-stream-btn:hover {
  background-color: #065700;
  transform: scale(1.35);
}

.favorite-streamer .top-stream-info {
  width: 100%;
  text-align: center;
  margin-top: 8px;
}

.favorite-streamer h3 {
  margin: 0;
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.favorite-streamer .top-stream-info p {
  font-size: clamp(0.7rem, 2vw, 0.8rem);
  opacity: 0.7;
  margin-top: 4px;
}

/* -------------------- Scrollbar Styles -------------------- */

/* Containers Scrollbar Style */
.artist-container::-webkit-scrollbar,
.album-container::-webkit-scrollbar,
.watch-party-container::-webkit-scrollbar {
  height: 10px;
}

.artist-container::-webkit-scrollbar-track,
.album-container::-webkit-scrollbar-track,
.watch-party-container::-webkit-scrollbar-track {
  box-shadow: inset 0 0 0.3rem rgb(79, 78, 78);
  border-radius: 40px;
}

.artist-container::-webkit-scrollbar-thumb,
.album-container::-webkit-scrollbar-thumb,
.watch-party-container::-webkit-scrollbar-thumb {
  box-shadow: inset 0 0 0.5rem rgb(116, 116, 116);
  background-color: rgba(25, 43, 206, 0.2);
  outline: none;
  border-radius: 40px;
}

/* Favorite Streamers Scrollbar */
.favorite-streamers-container::-webkit-scrollbar {
  width: 8px;
}

.favorite-streamers-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.favorite-streamers-container::-webkit-scrollbar-thumb {
  background-color: rgba(169, 150, 253, 0.5);
  border-radius: 4px;
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.favorite-streamers-container::-webkit-scrollbar-thumb:hover {
  background-color: rgba(169, 150, 253, 0.7);
}

/* -------------------- Notifications -------------------- */

.custom-notification {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 15px 20px;
  border-radius: 10px;
  background: rgba(16, 21, 61, 0.9);
  color: #fff;
  font-size: 0.9rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  transition: opacity 0.3s ease, transform 0.3s ease;
  opacity: 0;
  transform: translateY(-20px);
}

.custom-notification.show {
  opacity: 1;
  transform: translateY(0);
}

.custom-notification.error {
  background: rgba(220, 53, 69, 0.9);
}

/* -------------------- Twitch Discovery States -------------------- */

.discovery-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 110px;
  padding: 20px;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
  background: rgba(5, 13, 20, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  box-sizing: border-box;
}

.discovery-state p {
  max-width: 640px;
  margin: 0;
}

.discovery-retry {
  padding: 8px 14px;
  color: #fff;
  background: rgba(169, 150, 253, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  cursor: pointer;
}

.discovery-retry:hover {
  background: rgba(169, 150, 253, 0.55);
}

/* -------------------- Buttons -------------------- */

/* Add, Remove, and Move Stream Buttons */
.add-stream-btn,
.remove-stream-btn,
.move-stream-btn {
  position: absolute;
  background-color: #0cb300; /* Default for add-stream-btn */
  color: white;
  border: none;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  font-size: 18px;
  line-height: 24px;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.3s;
  z-index: 10;
}

.remove-stream-btn {
  background-color: #9e0000;
}

.move-stream-btn {
  top: 5px;
  left: 5px;
  background-color: #4a4a4a;
}

.add-stream-btn,
.remove-stream-btn {
  top: 5px;
  right: 5px;
}

.add-stream-btn:hover {
  background-color: #065700;
  transform: scale(1.35);
}

.remove-stream-btn:hover {
  background-color: #800000;
  transform: scale(1.35);
}

.move-stream-btn:hover {
  background-color: #2a2a2a;
  transform: scale(1.35);
}

/* -------------------- Launch Watch Party -------------------- */

.launch-watch-party {
  margin: 30px 0 20px;
  display: flex;
  justify-content: center;
  align-items: center;
}

#launchWatchParty {
  background: linear-gradient(45deg, #511142 0%, #fb1fa7 100%);
  border: black;
  border-radius: 25px;
  color: #fff;
  cursor: pointer;
  font-family: "Nunito", sans-serif;
  font-size: 1rem;
  font-weight: 600;
  text-shadow: 0.5px 0.5px #000000;
  padding: 12px 24px;
  transition: all 0.3s ease;
  box-shadow:
    0 4px 6px rgba(28, 35, 51, 0.11),
    0 1px 3px rgba(0, 0, 0, 0.08);
}

#launchWatchParty:hover {
  transform: translateY(-2px);
  box-shadow:
    0 7px 14px rgba(50, 50, 93, 0.1),
    0 3px 6px rgba(0, 0, 0, 0.08);
  animation: bounce 0.3s infinite alternate;
}

#launchWatchParty:active {
  transform: translateY(1px);
}

@keyframes bounce {
  0% { transform: translateY(0); }
  100% { transform: translateY(-5px); }
}

/* -------------------- Watch Parties Container -------------------- */

.top-streams-container {
  display: none;
  margin-top: 10px;
  background: rgba(5, 13, 20, 0.5);
  border-radius: 15px;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 2px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  cursor: default;
  overflow: hidden;
}

.top-streams-title {
  margin-bottom: 5px;
  color: #fff;
}

.top-streams-wrapper {
  position: relative;
  overflow-x: auto;
  padding: 10px 0;
  cursor: default;
}

.top-streams {
  display: flex;
  gap: 12px;
  padding-bottom: 10px;
}

.top-stream {
  position: relative;
  flex: 0 0 auto;
  width: 100px;
  margin-right: 12px;
  margin-left: 12px;
  text-align: center;
}

.top-stream-image-container {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 2px solid rgba(130, 130, 130, 0.5);
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 6px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
}

.top-stream-image-container:hover,
.top-stream:hover .top-stream-image-container {
  border-color: #0cb300;
  transform: scale(1.05);
}

.top-stream-image-container:hover ~ .add-stream-btn,
.top-stream:hover .add-stream-btn {
  background-color: #065700;
  transform: scale(1.35);
  opacity: 1;
}

.top-stream-image-container:focus {
  outline: none;
  border-color: #0cb300;
  box-shadow: 0 0 0 2px rgba(12, 179, 0, 0.3);
}

.top-stream img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.top-stream:hover img {
  transform: scale(1.1);
}

.top-stream-info {
  margin-top: 12px;
  padding: 0 4px;
  cursor: default;
}

.top-stream-info h3 {
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-stream-info p {
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  font-weight: 500;
  margin-top: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.viewer-count {
  position: absolute;
  top: 0;
  right: 0;
  background: rgba(169, 150, 253, 0.9);
  color: white;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  transform: translate(25%, -25%);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.top-streams-container {
  background: rgba(5, 13, 20, 0.5);
  border-radius: 15px;
  padding: 20px;
  margin-top: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.top-streams-title {
  font-size: 1.2rem;
  color: #fff;
  margin-bottom: 16px;
  padding-left: 8px;
}

/* Twitch Categories */
.twitch-categories-container {
  position: relative;
  overflow: hidden;
  padding: 10px 0;
  cursor: grab;
}

.twitch-categories-container.dragging {
  cursor: grabbing;
  user-select: none;
}

#twitchCategories {
  display: flex;
  gap: 20px;
  transition: transform 0.3s ease;
  user-select: none;
}

/* Update the top streams container styles */
.top-streams-wrapper {
  position: relative;
  overflow-x: auto;
  padding: 10px 0;
  cursor: default;
}

.top-streams {
  display: flex;
  gap: 12px;
  padding-bottom: 10px;
}

/* Add the containers class styles to top streams */
.top-streams-wrapper.containers {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding: 20px;
  scroll-behavior: smooth;
  background: rgba(5, 13, 20, 0.5);
  border-radius: 15px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* Remove old scrollbar styles for these containers */
.top-streams {
  overflow-x: visible;
  padding-bottom: 0;
}

/* Hide scrollbars but keep functionality */
.twitch-categories-container,
.top-streams-wrapper {
  overflow-x: hidden;
  margin: 0 -10px;
  padding: 0 10px;
}

/* Remove old slider navigation styles */
.slider-navigation {
  display: none;
}

@keyframes scrollCategories {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

#twitchCategories::after {
  content: '';
  display: block;
  clear: both;
}

#twitchCategories:hover {
  animation-play-state: paused;
}

.category-card {
  flex: 0 0 auto;
  width: 200px;
  user-select: none;
}

/* -------------------- Content Divider -------------------- */

.content-divider {
  border-top: 1px solid rgba(255, 255, 255, 0.5);
  margin: 20px 0;
}

/* Update the base nav styles */
.nav-items {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  min-width: max-content;
}

/* Update media queries */
@media (max-width: 1500px) {
  .content {
    grid-template-columns: 70% 30%;
  }
}

/* Only collapse nav when absolutely necessary - moved to smaller breakpoint */
@media (max-width: 800px) {
  .nav-icon {
    text-align: center;
    transform: translateY(2px);
  }

  .nav-text {
    display: none;
  }
}

/* Adjust other responsive layouts */
@media (max-width: 1100px) {
  .content {
    grid-template-columns: 60% 40%;
  }
}

.content {
  display: grid;
  grid-template-columns: 75% 25%;
  gap: 10px;
  height: 100%;
  overflow: hidden;
  padding: 15px;
}

.left-content {
  padding: 10px;
  color: #e5e5e5;
  overflow-y: auto;
  height: 100%;
}

.right-content {
  height: 100%;
  padding: 10px;
  border-left: 1px solid rgba(255, 255, 255, 0.5);
  color: #e5e5e5;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

/* Right Navigation */
.right-nav {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.nav-link {
  flex: 1;
  min-width: calc(50% - 8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  color: #fff;
  text-decoration: none;
  transition: all 0.3s ease;
  text-align: center;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.nav-link i {
  font-size: 1.2rem;
  width: 24px;
  text-align: center;
  margin-right: 8px;
}

.nav-link span {
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

/* Media query for smaller screens */
@media (max-width: 768px) {
  .nav-link {
    min-width: 100%;
  }
}

@media (max-width: 600px) {
  .demo-mode-top-button {
    top: 10px;
    right: 10px;
    padding: 8px 10px;
    font-size: 0.78rem;
  }
}

/* Modern Scrollbar Styles */
.right-content::-webkit-scrollbar {
  width: 8px;
  background: transparent;
}

.right-content::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
}

.right-content::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  transition: background 0.3s ease;
}

.right-content::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Firefox Scrollbar */
.right-content {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) rgba(255, 255, 255, 0.05);
}

/* Featured Streamer Button Styles */
.featured-streamer-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.featured-streamer-btn {
  padding: 8px 16px;
  background: rgba(169, 150, 253, 0.2);
  border: 1px solid rgba(169, 150, 253, 0.4);
  border-radius: 8px;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.featured-streamer-btn:hover {
  background: rgba(169, 150, 253, 0.3);
  transform: translateY(-2px);
}

/* Modern Scrollbar Styles - Unified */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
  background: transparent;
}

::-webkit-scrollbar-track {
  background: rgba(5, 13, 20, 0.5);
  border-radius: 0;
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-right: none;
}

::-webkit-scrollbar-thumb {
  background: rgb(43, 43, 43, 0.3);
  border-radius: 0;
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-right: none;
  transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: rgb(255, 255, 255, 0.5);
  cursor: grab;
}

::-webkit-scrollbar-thumb:active {
  background: rgb(79, 79, 79, 0.7);
  cursor: grabbing;
}

::-webkit-scrollbar-corner {
  background: transparent;
}

/* Firefox Scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: rgb(97, 97, 97, 0.3) rgba(5, 13, 20, 0.5);
}

*:hover {
  scrollbar-color: rgb(255, 255, 255, 0.5) rgba(5, 13, 20, 0.5);
}

/* Right Navigation - Single Button */
.right-nav {
  display: flex;
  justify-content: center;
  margin-bottom: 10px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  color: #fff;
  text-decoration: none;
  transition: all 0.3s ease;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.nav-link i {
  font-size: 1.2rem;
}

.nav-link span {
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Custom scrollbar positioning for left content */
.left-content::-webkit-scrollbar {
  width: 10px;
  position: absolute;
  right: 5px;
}

.left-content::-webkit-scrollbar-track {
  background: rgba(5, 13, 20, 0.5);
  border-radius: 0;
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-right: none;
  margin-right: -10px;
}

.left-content::-webkit-scrollbar-thumb {
  background: rgb(43, 43, 43, 0.3);
  border-radius: 0;
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-right: none;
  margin-right: -10px;
}

/* Reset cursor to default for containers */
.top-streams-container {
  cursor: default;
}

/* Remove cursor: pointer from general elements */
.top-stream {
  position: relative;
  flex: 0 0 auto;
  width: 100px;
  margin-right: 12px;
  text-align: center;
  cursor: default;
}

.top-stream-image-container {
  /* ... existing styles ... */
  cursor: default;
}

.top-stream-info {
  margin-top: 5px;
  padding: 0 4px;
  cursor: default;
}

/* Keep pointer cursor only for interactive elements */
.add-stream-btn,
.remove-stream-btn,
.move-stream-btn {
  cursor: pointer;
}

/* Maintain pointer cursor for scrollbar interactions */
::-webkit-scrollbar-thumb:hover {
  cursor: grab;
}

::-webkit-scrollbar-thumb:active {
  cursor: grabbing;
}

/* Add specific scrollbar styles for top streams */
.top-streams::-webkit-scrollbar {
  width: 10px;
  height: 10px;
  background: transparent;
}

.top-streams::-webkit-scrollbar-track {
  background: rgba(5, 13, 20, 0.5);
  border-radius: 0;
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-right: none;
}

.top-streams::-webkit-scrollbar-thumb {
  background: rgb(43, 43, 43, 0.3);
  border-radius: 0;
  border-top-left-radius: 8px;
  border-bottom-left-radius: 8px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-right: none;
  transition: background 0.3s ease;
  cursor: grab;
}

.top-streams::-webkit-scrollbar-thumb:hover {
  background: rgb(255, 255, 255, 0.5);
  cursor: grab;
}

.top-streams::-webkit-scrollbar-thumb:active {
  background: rgb(79, 79, 79, 0.7);
  cursor: grabbing;
}

/* Firefox scrollbar styles for top streams */
.top-streams {
  scrollbar-width: thin;
  scrollbar-color: rgb(43, 43, 43, 0.3) rgba(5, 13, 20, 0.5);
}

.top-streams:hover {
  scrollbar-color: rgb(255, 255, 255, 0.5) rgba(5, 13, 20, 0.5);
}

/* Add these new styles */
.watch-party-frame {
  position: relative;
  /* ... existing styles ... */
}

.coming-soon-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  border-radius: 10px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.coming-soon-overlay span {
  color: #fff;
  font-size: 1.2rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 10px 20px;
  border: 2px solid #fff;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.5);
}

.watch-party:hover .coming-soon-overlay {
  opacity: 1;
}

/* Tutorial Styles */
.tutorial-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.01);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10000;
}

.tutorial-content {
  background: rgba(31, 31, 31, 0.95);
  padding: 10px;
  border-radius: 15px;
  max-width: 450px;
  width: 90%;
  text-align: left;
  color: #fff;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.tutorial-content h2 {
  margin-bottom: 15px;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.tutorial-content p {
  margin-bottom: 20px;
  font-size: 1.1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.tutorial-buttons {
  display: flex;
  gap: 10px;
}

.tutorial-content button {
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

#tutorial-prev {
  background-color: rgba(189, 13, 0, 0.7);
  color: white;
}

#tutorial-next {
  background-color: rgba(0, 143, 5, 0.7);
  color: white;
}

#tutorial-skip {
  background-color: rgba(0, 93, 168, 0.7);
  color: white;
}

.highlight {
  position: relative;
  z-index: 9999;
  animation: tutorialPulse 2s infinite alternate;
  box-shadow: 0 0 0 4px rgba(169, 150, 253, 0.5);
  border-radius: 8px;
  pointer-events: auto;
}

@keyframes tutorialPulse {
  0% {
    box-shadow: 0 0 0 4px rgba(169, 150, 253, 0.5);
  }
  100% {
    box-shadow: 0 0 0 8px rgba(169, 150, 253, 0.2);
  }
}

body.tutorial-active .content {
  position: relative;
  z-index: 1;
}

/* Add styles to dim non-highlighted content */
body.tutorial-active::before {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.01);
  z-index: 9998;
  pointer-events: none;
}

/* Ensure highlighted elements remain clickable */
body.tutorial-active .highlight {
  position: relative;
  z-index: 9999;
  pointer-events: auto;
}

/* Add these new styles for the tutorial button overlay */
.tutorial-btn {
    position: relative;
    overflow: hidden;
}

.tutorial-btn::before {
    content: 'Coming Soon';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.8rem;
    font-weight: 600;
    opacity: 0;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    border-radius: 8px;
}

.tutorial-btn:hover::before {
    opacity: 1;
}

/* Make the button appear slightly disabled */
.tutorial-btn {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Update cursor styles for stream elements */
.top-stream:has(.add-stream-btn:hover) {
  cursor: default;
}

.top-streams-wrapper:has(.add-stream-btn:hover) {
  cursor: default;
}

/* Enable pointer events for specific interactive elements */
.top-stream-image-container,
.add-stream-btn,
.top-stream-info {
  pointer-events: auto;
}

/* Ensure add button maintains pointer cursor */
.add-stream-btn {
  cursor: pointer !important;
  z-index: 2;
}

/* Reset cursor only for the add button hover state */
.add-stream-btn:hover {
  cursor: pointer !important;
}

/* Add custom scrollbar styles for the top streams wrapper */
.top-streams-wrapper::-webkit-scrollbar {
  height: 8px;
  background: transparent;
}

.top-streams-wrapper::-webkit-scrollbar-track {
  background: rgba(5, 13, 20, 0.5);
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.top-streams-wrapper::-webkit-scrollbar-thumb {
  background: rgba(169, 150, 253, 0.3);
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: background 0.3s ease;
}

.top-streams-wrapper::-webkit-scrollbar-thumb:hover {
  background: rgba(169, 150, 253, 0.5);
}

/* Firefox scrollbar styles */
.top-streams-wrapper {
  scrollbar-width: thin;
  scrollbar-color: rgba(169, 150, 253, 0.3) rgba(5, 13, 20, 0.5);
}

.top-streams-wrapper:hover {
  scrollbar-color: rgba(169, 150, 253, 0.5) rgba(5, 13, 20, 0.5);
}

/* Add these new styles */
.watch-party {
  position: relative;
  cursor: not-allowed;
  opacity: 0.9;
}

.watch-party::before {
  content: 'Coming Soon';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.2rem;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  border-radius: 12px;
  z-index: 10;
}

.watch-party:hover::before {
  opacity: 1;
}

/* Update cursor styles for stream images */
.top-stream-image-container {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 2px solid rgba(130, 130, 130, 0.5);
  box-shadow:
    rgba(221, 221, 221, 0.3) 0px 6px 18px -3px,
    rgba(221, 221, 221, 0.2) 0px -3px 0px inset;
  overflow: hidden;
  cursor: pointer !important;
}

/* Update cursor for favorite streamer images */
.favorite-streamer .top-stream-image-container {
  cursor: pointer !important;
}

/* Remove the default cursor styles */
.top-stream,
.top-streams-wrapper,
.top-stream-info {
  cursor: default;
}

/* Ensure the cursor remains pointer on hover */
.top-stream-image-container:hover,
.favorite-streamer .top-stream-image-container:hover {
  cursor: pointer !important;
}

/* -------------------- Add Stream Control Polish -------------------- */

.add-stream-btn {
  top: -3px;
  right: -3px;
  display: grid;
  width: 27px;
  height: 27px;
  padding: 0;
  place-items: center;
  border: 2px solid rgba(5, 13, 20, 0.92);
  border-radius: 50%;
  outline: 1px solid rgba(111, 242, 145, 0.42);
  background: linear-gradient(145deg, #55e982 0%, #16b84c 64%, #07923a 100%);
  color: #fff;
  font-family: "Nunito", sans-serif;
  font-size: 17px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 62, 20, 0.55);
  box-shadow:
    0 5px 12px rgba(0, 0, 0, 0.36),
    0 0 0 2px rgba(4, 20, 10, 0.28),
    inset 0 1px 1px rgba(255, 255, 255, 0.48),
    inset 0 -2px 4px rgba(0, 61, 24, 0.28);
  transform: translateZ(0) scale(0.98);
  transition:
    transform 180ms cubic-bezier(0.22, 0.61, 0.36, 1),
    background 180ms ease,
    box-shadow 180ms ease,
    outline-color 180ms ease;
}

.favorite-streamer .add-stream-btn {
  top: -3px;
  right: -3px;
  width: 27px;
  height: 27px;
  border: 2px solid rgba(5, 13, 20, 0.92);
  font-size: 17px;
}

.add-stream-btn:hover {
  outline-color: rgba(157, 255, 180, 0.92);
  background: linear-gradient(145deg, #8af7a8 0%, #27d864 62%, #0aa342 100%);
  box-shadow:
    0 8px 16px rgba(0, 0, 0, 0.42),
    0 0 0 3px rgba(72, 231, 116, 0.15),
    inset 0 1px 1px rgba(255, 255, 255, 0.64),
    inset 0 -2px 4px rgba(0, 61, 24, 0.2);
  transform: translateZ(0) scale(1.12);
}

.favorite-streamer .add-stream-btn:hover {
  outline-color: rgba(157, 255, 180, 0.92);
  background: linear-gradient(145deg, #8af7a8 0%, #27d864 62%, #0aa342 100%);
  transform: translateZ(0) scale(1.12);
}

.add-stream-btn:focus-visible {
  outline: 3px solid rgba(226, 255, 234, 0.98);
  outline-offset: 3px;
}

.favorite-streamer .add-stream-btn:focus-visible {
  outline: 3px solid rgba(226, 255, 234, 0.98);
  outline-offset: 3px;
}

.add-stream-btn:active {
  transform: translateZ(0) scale(0.9);
}

.favorite-streamer .add-stream-btn:active {
  transform: translateZ(0) scale(0.9);
}

@media (prefers-reduced-motion: reduce) {
  .add-stream-btn {
    transition: none;
  }
}

/* -------------------- Dashboard Visual Polish -------------------- */

.dashboard-three-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0.72;
  transition: opacity 240ms ease;
}

.dashboard-three-layer[hidden] {
  display: none;
}

.dashboard-three-layer canvas {
  display: block;
  width: 100%;
  height: 100%;
}

:root {
  color-scheme: dark;
  --dashboard-ink: #f4f5ff;
  --dashboard-muted: rgba(218, 222, 244, 0.68);
  --dashboard-surface: rgba(9, 17, 32, 0.62);
  --dashboard-surface-strong: rgba(7, 13, 26, 0.8);
  --dashboard-border: rgba(183, 190, 232, 0.24);
  --dashboard-border-strong: rgba(187, 169, 255, 0.48);
  --dashboard-accent: #a996fd;
  --dashboard-accent-cyan: #7bd8e8;
}

body {
  color: var(--dashboard-ink);
  background-color: #080d1b;
  background-blend-mode: normal;
}

main {
  position: relative;
  background: linear-gradient(
    135deg,
    rgba(8, 17, 33, 0.72),
    rgba(10, 10, 25, 0.62)
  );
  border-color: rgba(210, 215, 248, 0.34);
  box-shadow:
    0 0.5px 0 1px rgba(255, 255, 255, 0.14) inset,
    0 1px 0 0 rgba(255, 255, 255, 0.32) inset,
    0 24px 70px rgba(0, 0, 0, 0.34),
    0 0 44px rgba(92, 109, 255, 0.08);
}

h1,
h2,
h3 {
  color: var(--dashboard-ink);
  letter-spacing: -0.015em;
}

.left-content,
.right-content {
  color: var(--dashboard-ink);
}

.right-content {
  border-left-color: rgba(183, 190, 232, 0.25);
  background: rgba(4, 9, 20, 0.16);
}

.demo-mode-top-button {
  background: linear-gradient(135deg, rgba(237, 60, 186, 0.88), rgba(126, 91, 238, 0.86));
  border-color: rgba(255, 255, 255, 0.42);
  box-shadow:
    0 8px 22px rgba(31, 9, 58, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}

.demo-mode-top-button:hover {
  background: linear-gradient(135deg, rgba(247, 85, 196, 0.96), rgba(145, 107, 248, 0.94));
  box-shadow:
    0 10px 26px rgba(31, 9, 58, 0.38),
    0 0 0 1px rgba(255, 255, 255, 0.16) inset;
}

.slider-container > h1,
.artists h1,
.watch-parties > h1,
.favorite-streamers h1 {
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.34);
}

#streamSearch {
  background: rgba(8, 17, 33, 0.58);
  border-color: var(--dashboard-border);
  box-shadow:
    0 6px 18px rgba(0, 0, 0, 0.12),
    0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

#streamSearch::placeholder {
  color: rgba(218, 222, 244, 0.48);
}

#streamSearch:focus {
  background: rgba(10, 20, 40, 0.78);
  border-color: rgba(123, 216, 232, 0.58);
  box-shadow:
    0 0 0 3px rgba(123, 216, 232, 0.11),
    0 8px 20px rgba(0, 0, 0, 0.18),
    0 1px 0 rgba(255, 255, 255, 0.08) inset;
}

#addStream,
#clearInitialStreams,
#clearBackupStreams {
  background: linear-gradient(180deg, rgba(173, 161, 245, 0.24), rgba(91, 97, 150, 0.2));
  border-color: rgba(203, 205, 244, 0.3);
  box-shadow:
    0 6px 16px rgba(0, 0, 0, 0.16),
    0 1px 0 rgba(255, 255, 255, 0.12) inset;
  font-weight: 600;
}

#addStream:hover,
#clearInitialStreams:hover,
#clearBackupStreams:hover {
  background: linear-gradient(180deg, rgba(192, 180, 255, 0.34), rgba(105, 111, 168, 0.28));
  border-color: rgba(225, 226, 255, 0.56);
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.22),
    0 1px 0 rgba(255, 255, 255, 0.18) inset;
  transform: translateY(-1px);
}

#clearInitialStreams:hover,
#clearBackupStreams:hover {
  background: linear-gradient(180deg, rgba(238, 124, 153, 0.28), rgba(125, 72, 105, 0.22));
  border-color: rgba(255, 177, 196, 0.52);
}

.artist-container,
#backupStreams {
  border-top: 1px solid rgba(183, 190, 232, 0.12);
  border-bottom: 1px solid rgba(183, 190, 232, 0.12);
  background: linear-gradient(90deg, rgba(8, 16, 31, 0.28), rgba(14, 16, 34, 0.16));
}

.artist-img-container,
.backup-stream-img-container,
.top-stream-image-container {
  border-color: rgba(183, 190, 232, 0.38);
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.24),
    0 0 0 1px rgba(123, 216, 232, 0.08),
    0 -3px 0 rgba(255, 255, 255, 0.08) inset;
}

.artist p,
.backup-stream p,
.favorite-streamer .top-stream-info p,
.top-stream-info p {
  color: var(--dashboard-muted);
}

.favorite-streamers {
  background: rgba(7, 14, 28, 0.26);
  border: 1px solid rgba(183, 190, 232, 0.14);
  border-radius: 16px;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.12);
}

.favorite-streamers h1 {
  color: #eef0ff;
}

.favorite-streamer .top-stream-image-container,
.top-streams .top-stream-image-container {
  border-color: rgba(183, 190, 232, 0.38);
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.24),
    0 0 0 1px rgba(123, 216, 232, 0.08),
    0 -3px 0 rgba(255, 255, 255, 0.08) inset;
}

.favorite-streamer .top-stream-info h3,
.top-streams .top-stream-info h3 {
  color: #f1f2ff;
  font-weight: 600;
}

.top-streams-container {
  background: linear-gradient(135deg, rgba(9, 18, 34, 0.74), rgba(15, 12, 31, 0.68));
  border-color: rgba(183, 190, 232, 0.2);
  box-shadow:
    0 18px 42px rgba(0, 0, 0, 0.28),
    0 1px 0 rgba(255, 255, 255, 0.08) inset;
}

.top-streams-title {
  color: #f4f1ff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.32);
}

.launch-watch-party button,
#launchWatchParty {
  background: linear-gradient(135deg, rgba(169, 150, 253, 0.94), rgba(221, 47, 165, 0.88));
  border: 1px solid rgba(255, 255, 255, 0.32);
  box-shadow:
    0 10px 24px rgba(64, 18, 89, 0.26),
    0 1px 0 rgba(255, 255, 255, 0.18) inset;
}

.launch-watch-party button:hover,
#launchWatchParty:hover {
  background: linear-gradient(135deg, rgba(187, 172, 255, 1), rgba(237, 68, 184, 0.96));
  border-color: rgba(255, 255, 255, 0.56);
  box-shadow:
    0 12px 28px rgba(64, 18, 89, 0.34),
    0 1px 0 rgba(255, 255, 255, 0.24) inset;
  transform: translateY(-1px);
}

.content-divider {
  border-top-color: rgba(183, 190, 232, 0.22);
}

.watch-party-frame {
  border-color: rgba(183, 190, 232, 0.3);
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.24),
    0 0 0 1px rgba(169, 150, 253, 0.08),
    0 -3px 0 rgba(255, 255, 255, 0.08) inset;
}

.watch-party:hover {
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(169, 150, 253, 0.24);
}

.discovery-state {
  background: rgba(8, 17, 33, 0.52);
  border-color: rgba(183, 190, 232, 0.24);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.14);
}

button,
input {
  font-family: "Nunito", sans-serif;
}

button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline-color: rgba(183, 221, 255, 0.94);
}

@media (prefers-reduced-motion: reduce) {
  .dashboard-three-layer {
    opacity: 0.42;
    transition: none;
  }
}

::-webkit-scrollbar-track {
  background: rgba(6, 13, 26, 0.42);
}

::-webkit-scrollbar-thumb {
  background: rgba(169, 150, 253, 0.28);
  border-color: rgba(255, 255, 255, 0.08);
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(169, 150, 253, 0.5);
}

/* -------------------- Lookbook Category Picker -------------------- */

.twitch-categories-shell {
  position: relative;
  isolation: isolate;
}

.twitch-categories-container {
  position: relative;
  isolation: isolate;
  overflow-x: auto;
  overflow-y: visible;
  margin: 0;
  padding: 22px 46px 28px;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
  cursor: grab;
}

.twitch-categories-container::-webkit-scrollbar {
  display: none;
}

.twitch-categories-container.dragging {
  cursor: grabbing;
}

.twitch-categories-container::before,
.twitch-categories-container::after {
  position: absolute;
  z-index: 4;
  top: 0;
  bottom: 0;
  width: 46px;
  content: "";
  pointer-events: none;
}

.twitch-categories-container::before {
  left: 0;
  background: linear-gradient(90deg, rgba(5, 13, 20, 0.78), transparent);
}

.twitch-categories-container::after {
  right: 0;
  background: linear-gradient(270deg, rgba(5, 13, 20, 0.78), transparent);
}

#twitchCategories {
  display: flex;
  align-items: stretch;
  gap: 18px;
  width: max-content;
  min-width: 100%;
  min-height: 286px;
  padding: 0 4px;
  transform: none !important;
  transition: none;
}

#twitchCategories .category-card {
  position: relative;
  z-index: 1;
  flex: 0 0 clamp(176px, 15.5vw, 214px);
  width: auto;
  height: clamp(240px, 25vw, 286px);
  aspect-ratio: auto;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 22px;
  background: rgba(10, 18, 29, 0.72);
  box-shadow:
    0 18px 34px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(0, 0, 0, 0.25);
  filter: saturate(0.84) brightness(0.84);
  opacity: 0.9;
  overflow: hidden;
  scroll-snap-align: center;
  transform: scale(0.94);
  transform-origin: center center;
  transition:
    transform 260ms cubic-bezier(0.22, 0.61, 0.36, 1),
    filter 260ms ease,
    opacity 260ms ease,
    box-shadow 260ms ease,
    border-color 260ms ease;
  will-change: transform;
}

#twitchCategories .category-card img {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: inherit;
  object-fit: cover;
  transform: scale(1.045);
  transition: transform 520ms cubic-bezier(0.22, 0.61, 0.36, 1), filter 320ms ease;
}

#twitchCategories .category-card:hover,
#twitchCategories .category-card:focus-visible,
#twitchCategories .category-card:focus-within,
#twitchCategories .category-card.is-selected {
  z-index: 3;
  border-color: rgba(255, 255, 255, 0.7);
  box-shadow:
    0 24px 42px rgba(0, 0, 0, 0.44),
    0 0 0 1px rgba(214, 119, 255, 0.32),
    0 0 28px rgba(172, 95, 255, 0.18);
  filter: saturate(1.1) brightness(1.04);
  opacity: 1;
  transform: translateY(-10px) scale(1.08);
}

#twitchCategories:has(.category-card:hover) .category-card:not(:hover):not(.is-selected) {
  filter: saturate(0.7) brightness(0.72);
  opacity: 0.72;
  transform: scale(0.9);
}

#twitchCategories .category-card:hover img,
#twitchCategories .category-card:focus-visible img,
#twitchCategories .category-card:focus-within img,
#twitchCategories .category-card.is-selected img {
  filter: saturate(1.08) contrast(1.03);
  transform: scale(1.12);
}

#twitchCategories .category-card:focus-visible {
  outline: 3px solid rgba(231, 180, 255, 0.95);
  outline-offset: 3px;
}

#twitchCategories .slide-overlay {
  justify-content: flex-end;
  padding: 20px 14px 15px;
  background: linear-gradient(
    180deg,
    rgba(3, 7, 12, 0.02) 20%,
    rgba(3, 7, 12, 0.28) 42%,
    rgba(3, 7, 12, 0.92) 100%
  );
  transition: background 260ms ease;
}

#twitchCategories .category-card:hover .slide-overlay,
#twitchCategories .category-card:focus-within .slide-overlay,
#twitchCategories .category-card.is-selected .slide-overlay {
  background: linear-gradient(
    180deg,
    rgba(3, 7, 12, 0.02) 12%,
    rgba(3, 7, 12, 0.18) 38%,
    rgba(3, 7, 12, 0.88) 100%
  );
}

#twitchCategories .slide-overlay h2 {
  max-width: 100%;
  margin: 0;
  overflow: hidden;
  font-size: clamp(0.82rem, 1.2vw, 1rem);
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#twitchCategories .slide-overlay p {
  margin: 0;
  font-size: clamp(0.72rem, 1vw, 0.86rem);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

#twitchCategories .slide-overlay button {
  min-height: 34px;
  margin-top: 2px;
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 999px;
  background: rgba(14, 18, 27, 0.46);
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  transition:
    background 180ms ease,
    border-color 180ms ease,
    transform 180ms ease,
    box-shadow 180ms ease;
}

#twitchCategories .slide-overlay button:hover,
#twitchCategories .slide-overlay button:focus-visible {
  border-color: rgba(255, 255, 255, 0.85);
  background: rgba(172, 95, 255, 0.46);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.28);
  transform: translateY(-2px);
}

.category-picker-control {
  position: absolute;
  z-index: 6;
  top: 50%;
  display: grid;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: rgba(7, 11, 18, 0.78);
  color: #fff;
  cursor: pointer;
  opacity: 0.9;
  place-items: center;
  transform: translateY(-50%);
  transition:
    opacity 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.category-picker-control--prev {
  left: 8px;
}

.category-picker-control--next {
  right: 8px;
}

.category-picker-control svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.category-picker-control:hover,
.category-picker-control:focus-visible {
  border-color: rgba(255, 255, 255, 0.68);
  background: rgba(172, 95, 255, 0.48);
  opacity: 1;
  outline: none;
  transform: translateY(-50%) scale(1.08);
}

.category-picker-control:disabled {
  cursor: default;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 700px) {
  .twitch-categories-container {
    padding: 18px 34px 24px;
  }

  #twitchCategories {
    gap: 14px;
    min-height: 242px;
  }

  #twitchCategories .category-card {
    flex-basis: 164px;
    height: 228px;
  }

  .category-picker-control {
    width: 32px;
    height: 32px;
  }

  .category-picker-control svg {
    width: 16px;
    height: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .twitch-categories-container {
    scroll-behavior: auto;
  }

  #twitchCategories .category-card,
  #twitchCategories .category-card img,
  #twitchCategories .slide-overlay,
  #twitchCategories .slide-overlay button,
  .category-picker-control {
    transition: none;
  }
}

/* -------------------- Lookbook Cover Treatment -------------------- */

.twitch-categories-shell::after {
  position: absolute;
  right: 48px;
  bottom: 8px;
  left: 48px;
  height: 1px;
  content: "";
  pointer-events: none;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(183, 190, 232, 0.22) 16%,
    rgba(123, 216, 232, 0.3) 50%,
    rgba(183, 190, 232, 0.22) 84%,
    transparent
  );
  opacity: 0.72;
}

.twitch-categories-container {
  padding: 24px 46px 30px;
  background: linear-gradient(
    180deg,
    rgba(8, 16, 31, 0.24),
    rgba(8, 16, 31, 0.06) 72%,
    transparent
  );
}

#twitchCategories {
  align-items: center;
  gap: 16px;
  min-height: 292px;
  padding: 0 8px 8px;
}

#twitchCategories .category-card {
  flex-basis: clamp(184px, 15.25vw, 214px);
  height: clamp(250px, 25vw, 286px);
  border-color: rgba(213, 219, 255, 0.3);
  border-radius: 18px;
  background: rgba(10, 18, 29, 0.82);
  box-shadow:
    0 20px 34px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(7, 13, 26, 0.6),
    0 0 22px rgba(123, 216, 232, 0.05);
  transform: translateY(7px) scale(0.94);
}

#twitchCategories .category-card:nth-child(even):not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected) {
  transform: translateY(0) scale(0.97);
}

#twitchCategories .category-card::before {
  position: absolute;
  z-index: 1;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: inherit;
  content: "";
  pointer-events: none;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.12),
    transparent 28%,
    transparent 72%,
    rgba(123, 216, 232, 0.08)
  );
}

#twitchCategories .slide-overlay {
  z-index: 2;
  padding: 20px 15px 15px;
}

#twitchCategories .slide-overlay h2 {
  font-size: clamp(0.84rem, 1.16vw, 1rem);
  font-weight: 750;
  letter-spacing: 0.01em;
}

#twitchCategories .slide-overlay p {
  color: rgba(230, 233, 250, 0.78);
  font-size: clamp(0.72rem, 0.96vw, 0.84rem);
}

#twitchCategories .slide-overlay button {
  min-height: 32px;
  padding: 7px 13px;
  border-color: rgba(215, 221, 255, 0.42);
  border-radius: 8px;
  background: rgba(7, 13, 26, 0.62);
  font-weight: 700;
  letter-spacing: 0.065em;
}

#twitchCategories .category-card:hover,
#twitchCategories .category-card:focus-visible,
#twitchCategories .category-card:focus-within,
#twitchCategories .category-card.is-selected {
  border-color: rgba(174, 232, 255, 0.8);
  box-shadow:
    0 26px 44px rgba(0, 0, 0, 0.46),
    0 0 0 1px rgba(169, 150, 253, 0.46),
    0 0 30px rgba(123, 216, 232, 0.14);
  transform: translateY(-10px) scale(1.06);
}

#twitchCategories .slide-overlay button:hover,
#twitchCategories .slide-overlay button:focus-visible {
  border-color: rgba(174, 232, 255, 0.86);
  background: rgba(123, 216, 232, 0.2);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
}

@media (max-width: 700px) {
  .twitch-categories-shell::after {
    right: 34px;
    left: 34px;
  }

  .twitch-categories-container {
    padding: 20px 34px 26px;
  }

  #twitchCategories {
    min-height: 246px;
    padding-bottom: 6px;
  }

  #twitchCategories .category-card {
    flex-basis: 164px;
    height: 228px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #twitchCategories .category-card,
  #twitchCategories .slide-overlay button {
    transition: none;
  }
}

/* -------------------- Scroll-Driven Carousel Focus -------------------- */

.twitch-categories-container {
  perspective: 1200px;
}

#twitchCategories {
  transform-style: preserve-3d;
}

#twitchCategories .category-card {
  transform-style: preserve-3d;
  backface-visibility: hidden;
}

#twitchCategories .category-card:not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected) {
  border-color: rgba(213, 219, 255, 0.3);
  filter: saturate(var(--carousel-saturation, 0.84)) brightness(var(--carousel-brightness, 0.84));
  opacity: var(--carousel-opacity, 0.9);
  transform: translateY(var(--carousel-lift, 7px)) scale(var(--carousel-scale, 0.94)) rotateY(var(--carousel-tilt, 0deg));
}

#twitchCategories .category-card[data-carousel-active="true"]:not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected) {
  z-index: 5;
  border-color: rgba(174, 232, 255, 0.56);
  box-shadow:
    0 30px 48px rgba(0, 0, 0, 0.48),
    0 0 0 1px rgba(123, 216, 232, 0.18),
    0 0 30px rgba(123, 216, 232, 0.16);
  transform: translate3d(0, var(--carousel-lift, -10px), 28px)
    scale(var(--carousel-scale, 1.12))
    rotateY(var(--carousel-tilt, 0deg));
}

#twitchCategories .category-card:hover,
#twitchCategories .category-card:focus-visible,
#twitchCategories .category-card:focus-within,
#twitchCategories .category-card.is-selected {
  z-index: 5;
  box-shadow:
    0 30px 50px rgba(0, 0, 0, 0.52),
    0 0 0 1px rgba(169, 150, 253, 0.52),
    0 0 34px rgba(123, 216, 232, 0.18);
  transform: translate3d(0, -14px, 44px) scale(1.12) rotateY(0deg);
}

#twitchCategories:has(.category-card:hover) .category-card:not(:hover):not(.is-selected) {
  filter: saturate(0.7) brightness(0.7);
  opacity: 0.68;
  transform: scale(0.9);
}

@media (prefers-reduced-motion: reduce) {
  #twitchCategories .category-card {
    backface-visibility: visible;
  }
}

/* -------------------- Editorial Category Lookbook -------------------- */

.twitch-categories-shell {
  position: relative;
  overflow: visible;
  border: 1px solid rgba(186, 198, 238, 0.16);
  border-radius: 22px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 78, 111, 0.14), transparent 36%),
    linear-gradient(145deg, rgba(7, 15, 30, 0.9), rgba(18, 12, 31, 0.78));
  box-shadow:
    0 22px 48px rgba(0, 0, 0, 0.2),
    0 1px 0 rgba(255, 255, 255, 0.08) inset;
}

.twitch-categories-container {
  min-height: 394px;
  padding: 36px 74px 48px;
  border-radius: 22px 22px 0 0;
  background:
    radial-gradient(circle at 50% 46%, rgba(55, 186, 215, 0.11), transparent 36%),
    linear-gradient(180deg, rgba(4, 10, 22, 0.14), rgba(4, 10, 22, 0.58));
}

.twitch-categories-container::before,
.twitch-categories-container::after {
  width: 88px;
  background: linear-gradient(90deg, rgba(4, 9, 20, 0.92), transparent);
}

.twitch-categories-container::after {
  background: linear-gradient(270deg, rgba(4, 9, 20, 0.92), transparent);
}

#twitchCategories {
  align-items: center;
  gap: 13px;
  min-height: 342px;
  padding: 18px 18px 24px;
}

#twitchCategories .category-card {
  flex-basis: clamp(212px, 18vw, 248px);
  height: clamp(298px, 29vw, 344px);
  border: 1px solid rgba(211, 222, 255, 0.26);
  border-radius: 22px;
  background: rgba(6, 13, 26, 0.84);
  box-shadow:
    0 20px 32px rgba(0, 0, 0, 0.34),
    0 0 0 1px rgba(5, 9, 20, 0.72),
    0 0 26px rgba(93, 203, 232, 0.04);
  transform: translate3d(0, var(--carousel-lift, 9px), 0)
    scale(calc(var(--carousel-scale, 0.92) * 0.94))
    rotateY(var(--carousel-tilt, 0deg));
  transform-origin: center center;
}

#twitchCategories .category-card::after {
  position: absolute;
  z-index: 2;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: inherit;
  content: "";
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.13), transparent 24%),
    linear-gradient(315deg, rgba(112, 222, 239, 0.1), transparent 28%);
}

#twitchCategories .category-card img {
  object-position: center;
  transform: scale(1.04);
}

#twitchCategories .category-card[data-carousel-active="true"]:not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected),
#twitchCategories .category-card:hover,
#twitchCategories .category-card:focus-visible,
#twitchCategories .category-card:focus-within,
#twitchCategories .category-card.is-selected {
  z-index: 10;
  border-color: rgba(173, 233, 255, 0.84);
  box-shadow:
    0 34px 54px rgba(0, 0, 0, 0.52),
    0 0 0 1px rgba(255, 102, 146, 0.44),
    0 0 34px rgba(82, 215, 239, 0.2);
  filter: saturate(1.08) brightness(1.04);
  opacity: 1;
  transform: translate3d(0, -17px, 42px)
    scale(calc(var(--carousel-scale, 1.12) * 1.14))
    rotateY(0deg);
}

#twitchCategories .category-card[data-carousel-active="true"]::before {
  position: absolute;
  z-index: 3;
  top: 12px;
  right: 12px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  content: "";
  pointer-events: none;
  background: #ff5979;
  box-shadow: 0 0 0 4px rgba(255, 89, 121, 0.14), 0 0 15px rgba(255, 89, 121, 0.7);
}

#twitchCategories .slide-overlay {
  z-index: 4;
  align-items: flex-start;
  padding: 22px 20px 18px;
  text-align: left;
  background: linear-gradient(
    180deg,
    rgba(3, 7, 14, 0.02) 18%,
    rgba(3, 7, 14, 0.22) 42%,
    rgba(3, 7, 14, 0.96) 100%
  );
}

#twitchCategories .slide-overlay h2 {
  width: 100%;
  font-size: clamp(0.84rem, 1.24vw, 1.12rem);
  font-weight: 760;
  letter-spacing: 0.01em;
  text-align: left;
}

#twitchCategories .slide-overlay p {
  display: flex;
  align-items: center;
  gap: 7px;
  color: rgba(237, 241, 255, 0.78);
  font-size: clamp(0.72rem, 0.98vw, 0.86rem);
}

#twitchCategories .slide-overlay p::before {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  content: "";
  background: #ff5979;
  box-shadow: 0 0 10px rgba(255, 89, 121, 0.7);
}

#twitchCategories .slide-overlay button {
  align-self: flex-start;
  min-height: 38px;
  margin-top: 8px;
  padding: 8px 16px;
  border: 1px solid rgba(209, 228, 255, 0.52);
  border-radius: 10px;
  background: rgba(5, 11, 22, 0.7);
  box-shadow: 0 7px 16px rgba(0, 0, 0, 0.25);
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.07em;
}

#twitchCategories .slide-overlay button:hover,
#twitchCategories .slide-overlay button:focus-visible {
  border-color: rgba(208, 249, 255, 0.95);
  background: linear-gradient(135deg, rgba(99, 215, 235, 0.34), rgba(176, 95, 255, 0.36));
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.36), 0 0 20px rgba(88, 213, 237, 0.18);
  transform: translateY(-2px);
}

.category-lookbook-index {
  position: relative;
  z-index: 3;
  padding: 13px 58px 15px;
  border-top: 1px solid rgba(183, 204, 239, 0.14);
  border-radius: 0 0 22px 22px;
  background: rgba(3, 8, 18, 0.58);
}

.category-lookbook-index-track {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding: 2px 0 4px;
  scrollbar-width: none;
}

.category-lookbook-index-track::-webkit-scrollbar {
  display: none;
}

.category-lookbook-index-item {
  position: relative;
  flex: 0 0 70px;
  height: 54px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(193, 207, 244, 0.24);
  border-radius: 11px;
  background: rgba(10, 18, 33, 0.82);
  cursor: pointer;
  opacity: 0.58;
  transform: translateY(0) scale(0.96);
  transition:
    opacity 180ms ease,
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.category-lookbook-index-item img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.78) brightness(0.78);
  transition: filter 180ms ease;
}

.category-lookbook-index-item:hover,
.category-lookbook-index-item:focus-visible,
.category-lookbook-index-item.is-active {
  border-color: rgba(150, 232, 255, 0.9);
  box-shadow:
    0 7px 16px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 94, 143, 0.38),
    0 0 18px rgba(93, 217, 236, 0.16);
  opacity: 1;
  transform: translateY(-3px) scale(1.02);
  outline: none;
}

.category-lookbook-index-item:hover img,
.category-lookbook-index-item:focus-visible img,
.category-lookbook-index-item.is-active img {
  filter: saturate(1.08) brightness(1.04);
}

.category-picker-control {
  top: 38%;
  border-color: rgba(187, 215, 246, 0.36);
  background: rgba(6, 12, 25, 0.86);
  box-shadow: 0 9px 20px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(123, 216, 232, 0.08);
}

.category-picker-control:hover,
.category-picker-control:focus-visible {
  border-color: rgba(208, 249, 255, 0.86);
  background: linear-gradient(135deg, rgba(99, 215, 235, 0.46), rgba(176, 95, 255, 0.42));
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.36), 0 0 22px rgba(93, 217, 236, 0.2);
}

@media (max-width: 700px) {
  .twitch-categories-shell {
    border-radius: 18px;
  }

  .twitch-categories-container {
    min-height: 298px;
    padding: 28px 42px 38px;
    border-radius: 18px 18px 0 0;
  }

  #twitchCategories {
    gap: 10px;
    min-height: 252px;
    padding: 12px 8px 20px;
  }

  #twitchCategories .category-card {
    flex-basis: 176px;
    height: 240px;
  }

  #twitchCategories .category-card[data-carousel-active="true"]:not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected),
  #twitchCategories .category-card:hover,
  #twitchCategories .category-card:focus-visible,
  #twitchCategories .category-card:focus-within,
  #twitchCategories .category-card.is-selected {
    transform: translate3d(0, -10px, 24px)
      scale(calc(var(--carousel-scale, 1.12) * 1.06))
      rotateY(0deg);
  }

  .category-lookbook-index {
    padding: 10px 40px 12px;
    border-radius: 0 0 18px 18px;
  }

  .category-lookbook-index-item {
    flex-basis: 58px;
    height: 46px;
  }

  .category-picker-control {
    top: 37%;
    width: 32px;
    height: 32px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .category-lookbook-index-item,
  .category-lookbook-index-item img {
    transition: none;
  }
}

/* -------------------- Stream Card Control Polish -------------------- */

.artist .remove-stream-btn,
.backup-stream .remove-stream-btn,
.artist .move-stream-btn,
.backup-stream .move-stream-btn {
  top: 4px;
  display: grid;
  width: 28px;
  height: 28px;
  padding: 0;
  place-items: center;
  border: 2px solid rgba(5, 13, 20, 0.9);
  border-radius: 50%;
  color: #f8fbff;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.52);
  transform: translateZ(0) scale(0.98);
  transition:
    transform 180ms cubic-bezier(0.22, 0.61, 0.36, 1),
    background 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease,
    outline-color 180ms ease;
}

.artist .move-stream-btn,
.backup-stream .move-stream-btn {
  left: 4px;
  background: linear-gradient(145deg, #76879a 0%, #4a596c 62%, #344154 100%);
  outline: 1px solid rgba(189, 219, 241, 0.34);
  box-shadow:
    0 5px 12px rgba(0, 0, 0, 0.38),
    0 0 0 2px rgba(7, 17, 31, 0.24),
    inset 0 1px 1px rgba(255, 255, 255, 0.38),
    inset 0 -2px 4px rgba(8, 18, 34, 0.32);
}

.artist .remove-stream-btn,
.backup-stream .remove-stream-btn {
  right: 4px;
  background: linear-gradient(145deg, #ff7180 0%, #d63b54 62%, #a91e38 100%);
  outline: 1px solid rgba(255, 164, 176, 0.48);
  box-shadow:
    0 5px 12px rgba(0, 0, 0, 0.38),
    0 0 0 2px rgba(42, 7, 15, 0.24),
    inset 0 1px 1px rgba(255, 255, 255, 0.42),
    inset 0 -2px 4px rgba(91, 7, 25, 0.28);
}

.artist .move-stream-btn:hover,
.backup-stream .move-stream-btn:hover {
  background: linear-gradient(145deg, #b5d5ea 0%, #668aa7 62%, #4c6d89 100%);
  border-color: rgba(226, 244, 255, 0.92);
  outline-color: rgba(193, 231, 255, 0.9);
  box-shadow:
    0 8px 16px rgba(0, 0, 0, 0.44),
    0 0 0 3px rgba(118, 200, 245, 0.16),
    inset 0 1px 1px rgba(255, 255, 255, 0.62),
    inset 0 -2px 4px rgba(22, 58, 84, 0.22);
  transform: translateZ(0) scale(1.12) translateY(-1px);
}

.artist .remove-stream-btn:hover,
.backup-stream .remove-stream-btn:hover {
  background: linear-gradient(145deg, #ffabb4 0%, #f04e67 62%, #c52b47 100%);
  border-color: rgba(255, 236, 239, 0.94);
  outline-color: rgba(255, 168, 181, 0.92);
  box-shadow:
    0 8px 16px rgba(0, 0, 0, 0.44),
    0 0 0 3px rgba(255, 87, 111, 0.16),
    inset 0 1px 1px rgba(255, 255, 255, 0.64),
    inset 0 -2px 4px rgba(110, 7, 27, 0.2);
  transform: translateZ(0) scale(1.12) translateY(-1px);
}

.artist .move-stream-btn:focus-visible,
.backup-stream .move-stream-btn:focus-visible,
.artist .remove-stream-btn:focus-visible,
.backup-stream .remove-stream-btn:focus-visible {
  outline: 3px solid rgba(230, 244, 255, 0.98);
  outline-offset: 3px;
}

.artist .move-stream-btn:active,
.backup-stream .move-stream-btn:active,
.artist .remove-stream-btn:active,
.backup-stream .remove-stream-btn:active {
  transform: translateZ(0) scale(0.9);
}

@media (prefers-reduced-motion: reduce) {
  .artist .remove-stream-btn,
  .backup-stream .remove-stream-btn,
  .artist .move-stream-btn,
  .backup-stream .move-stream-btn {
    transition: none;
  }
}

/* -------------------- Screenshot-Matched Category Showcase -------------------- */

.twitch-categories-shell {
  min-height: 667px;
  isolation: isolate;
  overflow: hidden;
  border: 1px solid rgba(151, 173, 215, 0.24);
  border-radius: 16px;
  background:
    radial-gradient(circle at 78% 5%, rgba(225, 38, 67, 0.28), transparent 31%),
    radial-gradient(circle at 18% 56%, rgba(19, 131, 189, 0.15), transparent 38%),
    linear-gradient(135deg, rgba(2, 12, 27, 0.98), rgba(16, 7, 25, 0.97) 64%, rgba(5, 10, 22, 0.98));
  box-shadow:
    0 24px 55px rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.twitch-categories-shell::before {
  position: absolute;
  z-index: -1;
  top: -78px;
  right: 9%;
  width: 310px;
  height: 220px;
  border-radius: 50%;
  content: "";
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 49, 72, 0.2), transparent 67%);
  filter: blur(16px);
}

.twitch-categories-shell::after {
  right: 32px;
  bottom: 175px;
  left: 32px;
  opacity: 0.7;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(96, 205, 238, 0.24) 14%,
    rgba(144, 170, 218, 0.18) 52%,
    rgba(255, 80, 111, 0.2) 86%,
    transparent
  );
}

.category-lookbook-title {
  position: relative;
  z-index: 5;
  padding: 34px 42px 9px;
  color: #f7f8ff;
  font-size: clamp(1.7rem, 2vw, 1.95rem);
  font-weight: 850;
  letter-spacing: -0.025em;
  line-height: 1.15;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.42);
}

.twitch-categories-container {
  height: 411px;
  min-height: 411px;
  padding: 0;
  overflow-x: auto;
  overflow-y: hidden;
  border-radius: 0;
  background:
    radial-gradient(circle at 37% 48%, rgba(48, 154, 190, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(2, 7, 17, 0.02), rgba(2, 7, 17, 0.3));
  perspective: 1450px;
}

.twitch-categories-container::before,
.twitch-categories-container::after {
  z-index: 12;
  width: 92px;
}

.twitch-categories-container::before {
  background: linear-gradient(90deg, rgba(2, 9, 21, 0.96), rgba(2, 9, 21, 0.48) 46%, transparent);
}

.twitch-categories-container::after {
  background: linear-gradient(270deg, rgba(5, 8, 20, 0.94), rgba(5, 8, 20, 0.42) 46%, transparent);
}

#twitchCategories {
  align-items: center;
  gap: 2px;
  width: max-content;
  min-width: 100%;
  height: 411px;
  min-height: 411px;
  padding: 0 168px 11px 159px;
}

#twitchCategories .category-card {
  flex: 0 0 240px;
  width: 240px;
  height: 360px;
  border: 1px solid rgba(163, 185, 224, 0.3);
  border-radius: 14px;
  background: rgba(3, 10, 22, 0.94);
  box-shadow:
    0 20px 38px rgba(0, 0, 0, 0.42),
    0 0 0 1px rgba(3, 8, 18, 0.72);
  transform: translate3d(0, var(--carousel-lift, 7px), 0)
    scale(calc(var(--carousel-scale, 0.92) * 0.94))
    rotateY(var(--carousel-tilt, 0deg));
  transform-origin: center center;
  transition:
    flex-basis 300ms cubic-bezier(0.22, 0.61, 0.36, 1),
    width 300ms cubic-bezier(0.22, 0.61, 0.36, 1),
    height 300ms cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 300ms cubic-bezier(0.22, 0.61, 0.36, 1),
    filter 240ms ease,
    opacity 240ms ease,
    border-color 240ms ease,
    box-shadow 240ms ease;
}

#twitchCategories .category-card:not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected):not([data-carousel-active="true"]),
#twitchCategories .category-card:nth-child(even):not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected):not([data-carousel-active="true"]) {
  transform: translate3d(
      0,
      calc(var(--carousel-lift, 7px) + var(--carousel-depth-drop, 0px)),
      0
    )
    scale(var(--carousel-stage-scale, 0.96))
    rotateY(var(--carousel-tilt, 0deg))
    rotateZ(var(--carousel-roll, 0deg));
}

#twitchCategories .category-card::after {
  border-color: rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), transparent 24%),
    linear-gradient(315deg, rgba(72, 204, 238, 0.08), transparent 28%);
}

#twitchCategories .category-card[data-carousel-active="true"] {
  flex-basis: 405px;
  width: 405px;
  height: 376px;
}

#twitchCategories .category-card[data-carousel-active="true"]::before {
  display: none;
}

#twitchCategories .category-card[data-carousel-active="true"]:not(:hover):not(:focus-visible):not(:focus-within):not(.is-selected),
#twitchCategories .category-card[data-carousel-active="true"]:hover,
#twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
#twitchCategories .category-card[data-carousel-active="true"]:focus-within,
#twitchCategories .category-card[data-carousel-active="true"].is-selected {
  z-index: 10;
  border-color: rgba(133, 225, 255, 0.92);
  box-shadow:
    0 32px 58px rgba(0, 0, 0, 0.58),
    0 0 0 1px rgba(255, 81, 117, 0.78),
    -7px 0 24px rgba(71, 211, 248, 0.16),
    8px 0 28px rgba(255, 72, 106, 0.14);
  filter: saturate(1.08) brightness(1.02);
  opacity: 1;
  transform: translate3d(0, 0, 50px) scale(1) rotateY(0deg);
}

#twitchCategories .category-card:hover:not([data-carousel-active="true"]),
#twitchCategories .category-card:focus-visible:not([data-carousel-active="true"]),
#twitchCategories .category-card:focus-within:not([data-carousel-active="true"]),
#twitchCategories .category-card.is-selected:not([data-carousel-active="true"]) {
  z-index: 8;
  border-color: rgba(151, 226, 255, 0.76);
  box-shadow:
    0 28px 48px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 93, 131, 0.38),
    0 0 28px rgba(86, 213, 242, 0.16);
  filter: saturate(1.04) brightness(0.98);
  opacity: 1;
  transform: translate3d(0, -8px, 34px) scale(1.06) rotateY(0deg);
}

#twitchCategories .category-card img {
  object-position: center 44%;
  transform: scale(1.025);
}

#twitchCategories .category-card[data-carousel-active="true"] img {
  object-position: center 43%;
}

#twitchCategories .slide-overlay {
  z-index: 4;
  align-items: center;
  justify-content: flex-end;
  padding: 24px 18px 18px;
  text-align: center;
  background: linear-gradient(
    180deg,
    rgba(2, 6, 14, 0.01) 26%,
    rgba(2, 6, 14, 0.2) 49%,
    rgba(2, 6, 14, 0.96) 100%
  );
}

#twitchCategories .slide-overlay h2 {
  width: 100%;
  font-size: clamp(0.86rem, 1.1vw, 1.02rem);
  font-weight: 800;
  text-align: center;
}

#twitchCategories .slide-overlay p {
  justify-content: center;
  width: 100%;
  color: rgba(232, 237, 249, 0.72);
  font-size: clamp(0.76rem, 0.9vw, 0.88rem);
}

#twitchCategories .slide-overlay p::before {
  display: none;
}

#twitchCategories .category-card[data-carousel-active="true"] .slide-overlay {
  padding: 28px 28px 24px;
}

#twitchCategories .category-card[data-carousel-active="true"] .slide-overlay h2 {
  font-size: clamp(1.02rem, 1.25vw, 1.18rem);
}

#twitchCategories .category-card[data-carousel-active="true"] .slide-overlay p {
  font-size: clamp(0.88rem, 1vw, 1rem);
}

#twitchCategories .category-card[data-carousel-active="true"] .slide-overlay p::before {
  display: block;
  width: 7px;
  height: 7px;
}

#twitchCategories .slide-overlay button {
  align-self: center;
  min-width: 132px;
  min-height: 38px;
  margin-top: 9px;
  padding: 8px 15px;
  border: 1px solid rgba(173, 200, 232, 0.52);
  border-radius: 9px;
  background: rgba(4, 10, 21, 0.68);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.32);
  color: #f8f9ff;
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.07em;
}

#twitchCategories .category-card[data-carousel-active="true"] .slide-overlay button {
  min-width: 188px;
  min-height: 48px;
  padding: 11px 22px;
  border-color: rgba(151, 216, 255, 0.78);
  box-shadow:
    0 10px 26px rgba(0, 0, 0, 0.42),
    0 0 0 1px rgba(255, 89, 133, 0.34),
    0 0 18px rgba(92, 179, 255, 0.12);
  font-size: 0.86rem;
}

.category-lookbook-index {
  position: relative;
  z-index: 8;
  height: 176px;
  padding: 11px 38px 14px;
  border-top: 1px solid rgba(145, 172, 218, 0.22);
  border-radius: 0;
  background: linear-gradient(180deg, rgba(4, 10, 22, 0.64), rgba(2, 8, 18, 0.86));
  box-shadow: inset 0 12px 28px rgba(0, 0, 0, 0.16);
}

.category-lookbook-index-track {
  align-items: stretch;
  gap: 8px;
  height: 100%;
  padding: 0;
}

.category-lookbook-index-item {
  flex: 0 0 116px;
  height: 142px;
  border-color: rgba(155, 177, 216, 0.24);
  border-radius: 10px;
  opacity: 0.7;
  transform: none;
}

.category-lookbook-index-item img {
  object-position: center;
  filter: saturate(0.86) brightness(0.82);
}

.category-lookbook-index-item:hover,
.category-lookbook-index-item:focus-visible,
.category-lookbook-index-item.is-active {
  border-color: rgba(102, 220, 255, 0.95);
  box-shadow:
    0 8px 22px rgba(0, 0, 0, 0.44),
    0 0 0 1px rgba(255, 82, 117, 0.78),
    0 0 18px rgba(75, 205, 244, 0.18);
  opacity: 1;
  transform: translateY(-1px);
}

.category-picker-control {
  top: 44.5%;
  width: 54px;
  height: 54px;
  border-color: rgba(154, 185, 224, 0.38);
  background: rgba(5, 13, 27, 0.82);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.44),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.category-picker-control--prev {
  left: 54px;
}

.category-picker-control--next {
  top: 48%;
  right: 38px;
  border-color: rgba(255, 93, 126, 0.7);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.46),
    0 0 18px rgba(255, 71, 105, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.category-picker-control:disabled {
  cursor: default;
  opacity: 0.48;
  pointer-events: none;
}

@media (max-width: 1100px) {
  .twitch-categories-shell {
    min-height: 555px;
  }

  .category-lookbook-title {
    padding: 24px 28px 8px;
    font-size: 1.45rem;
  }

  .twitch-categories-container,
  #twitchCategories {
    height: 360px;
    min-height: 360px;
  }

  #twitchCategories {
    gap: 4px;
    padding: 10px 110px 10px 80px;
  }

  #twitchCategories .category-card {
    flex-basis: 210px;
    width: 210px;
    height: 300px;
  }

  #twitchCategories .category-card[data-carousel-active="true"] {
    flex-basis: 330px;
    width: 330px;
    height: 330px;
  }

  .category-lookbook-index {
    height: 132px;
    padding: 10px 26px 12px;
  }

  .category-lookbook-index-item {
    flex-basis: 84px;
    height: 108px;
  }

  .twitch-categories-shell::after {
    bottom: 131px;
  }

  .category-picker-control {
    top: 43%;
    width: 44px;
    height: 44px;
  }

  .category-picker-control--prev {
    left: 12px;
  }

  .category-picker-control--next {
    right: 12px;
  }
}

@media (max-width: 700px) {
  .twitch-categories-shell {
    min-height: 430px;
    border-radius: 13px;
  }

  .category-lookbook-title {
    padding: 18px 18px 8px;
    font-size: 0.95rem;
    letter-spacing: -0.015em;
    white-space: nowrap;
  }

  .twitch-categories-container,
  #twitchCategories {
    height: 286px;
    min-height: 286px;
  }

  #twitchCategories {
    gap: 4px;
    padding: 10px 46px 10px 20px;
  }

  #twitchCategories .category-card {
    flex-basis: 132px;
    width: 132px;
    height: 206px;
    border-radius: 11px;
  }

  #twitchCategories .category-card[data-carousel-active="true"] {
    flex-basis: 184px;
    width: 184px;
    height: 244px;
  }

  #twitchCategories .slide-overlay {
    padding: 16px 9px 10px;
  }

  #twitchCategories .slide-overlay h2,
  #twitchCategories .category-card[data-carousel-active="true"] .slide-overlay h2 {
    font-size: 0.7rem;
  }

  #twitchCategories .slide-overlay p,
  #twitchCategories .category-card[data-carousel-active="true"] .slide-overlay p {
    font-size: 0.62rem;
  }

  #twitchCategories .slide-overlay button,
  #twitchCategories .category-card[data-carousel-active="true"] .slide-overlay button {
    min-width: 104px;
    min-height: 32px;
    margin-top: 5px;
    padding: 6px 8px;
    border-radius: 7px;
    font-size: 0.58rem;
  }

  .category-lookbook-index {
    height: 96px;
    padding: 8px 12px 10px;
  }

  .category-lookbook-index-track {
    gap: 6px;
  }

  .category-lookbook-index-item {
    flex-basis: 58px;
    height: 74px;
    border-radius: 7px;
  }

  .twitch-categories-shell::after {
    right: 14px;
    bottom: 95px;
    left: 14px;
  }

  .category-picker-control {
    top: 43%;
    width: 30px;
    height: 30px;
  }

  .category-picker-control--prev {
    left: 4px;
  }

  .category-picker-control--next {
    right: 4px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #twitchCategories .category-card,
  .category-lookbook-index-item,
  .category-picker-control {
    transition: none;
  }
}

/* -------------------- Screenshot-matched dashboard layout -------------------- */

:root {
  --mono-bg: #070a0b;
  --mono-panel: #0b0e0f;
  --mono-card: #0e1112;
  --mono-card-raised: #111415;
  --mono-border: #343839;
  --mono-border-soft: #292d2e;
  --mono-text: #f4f5f5;
  --mono-muted: #a7acad;
  --mono-dim: #727a7c;
}

html {
  min-width: 320px;
  background: var(--mono-bg);
}

body {
  display: block;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: var(--mono-text);
  background-color: var(--mono-bg);
  background-image:
    radial-gradient(circle at 48% 0%, rgba(83, 91, 93, 0.09), transparent 32%),
    radial-gradient(circle at 86% 92%, rgba(45, 52, 53, 0.08), transparent 28%);
}

main.dashboard-frame {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(320px, 23.5vw, 384px);
  gap: 18px;
  width: calc(100% - 18px);
  height: auto;
  min-height: calc(100vh - 45px);
  margin: 10px 9px 25px;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.dashboard-main {
  container: dashboard-main / inline-size;
  min-width: 0;
  min-height: calc(100vh - 45px);
  padding: 16px 22px 18px;
  overflow: hidden;
  border: 1px solid var(--mono-border);
  border-radius: 10px;
  background: rgba(10, 13, 14, 0.94);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.025) inset;
}

.dashboard-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  min-height: 65px;
  padding: 1px 10px 0;
}

.dashboard-header h1 {
  margin: 6px 0 0;
  color: var(--mono-text);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.launch-button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-width: 288px;
  height: 48px;
  margin-top: 0;
  padding: 0 17px 0 30px;
  border: 1px solid #777d7d;
  border-radius: 26px;
  background: #0b0e0f;
  color: var(--mono-text);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.launch-button .fa-play {
  font-size: 15px;
}

.launch-button .fa-chevron-down {
  color: #b4b9b9;
  font-size: 13px;
}

.launch-button:hover,
.launch-button:focus-visible {
  border-color: #b8bdbd;
  background: #15191a;
  transform: translateY(-1px);
}

.section-heading,
.rail-card-heading,
.party-queue-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.section-heading {
  min-height: 28px;
  margin: 0 1px 12px;
}

.section-heading--categories {
  gap: 20px;
  margin-bottom: 14px;
}

.section-heading--categories .category-search {
  flex: 1 1 auto;
  margin: 0;
}

.section-heading-label,
.rail-heading-label {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.section-heading-icon,
.rail-heading-label > i {
  display: inline-grid;
  flex: 0 0 auto;
  width: 27px;
  height: 27px;
  margin-right: 11px;
  place-items: center;
  color: #f3f4f4;
  font-size: 18px;
}

.section-heading h2,
.rail-card-heading h2 {
  color: var(--mono-text);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.2;
}

.section-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 0;
  background: transparent;
  color: #d3d7d7;
  font: inherit;
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
}

.section-link i {
  color: #f2f3f3;
  font-size: 13px;
}

.section-link:hover,
.section-link:focus-visible {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.twitch-categories-shell {
  position: relative;
  min-height: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.twitch-categories-shell::before,
.twitch-categories-shell::after,
.twitch-categories-container::before,
.twitch-categories-container::after,
.category-card::before,
.category-card::after {
  display: none !important;
}

.category-lookbook-title {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.twitch-categories-container {
  height: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow: visible;
  perspective: none;
  cursor: default;
}

#twitchCategories {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: stretch;
  gap: 17px;
  width: 100%;
  min-width: 0;
  height: auto;
  min-height: 0;
  padding: 0;
  transform: none !important;
}

#twitchCategories .category-card {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  width: auto;
  height: 295px;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #3a3e3f;
  border-radius: 9px;
  background: var(--mono-card);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.25);
  opacity: 1 !important;
  transform: none !important;
  filter: none !important;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

#twitchCategories .category-card:hover,
#twitchCategories .category-card:focus-visible,
#twitchCategories .category-card:focus-within,
#twitchCategories .category-card.is-selected {
  z-index: 2;
  border-color: #797f80;
  box-shadow: 0 9px 22px rgba(0, 0, 0, 0.36);
  transform: translateY(-2px) !important;
}

.category-card-media {
  position: relative;
  flex: 0 0 148px;
  overflow: hidden;
  background: #161a1b;
}

#twitchCategories .category-card-media img {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
  object-fit: cover;
  object-position: center;
  transform: none !important;
  filter: none;
}

.category-live-badge {
  position: absolute;
  top: 12px;
  left: 16px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 21px;
  padding: 2px 7px;
  border-radius: 4px;
  background: #f2f4f4;
  color: #111415;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1;
}

.category-live-badge i {
  font-size: 5px;
}

.category-card-body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  padding: 11px 16px 12px;
}

.category-stats {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: #d0d4d4;
  font-size: 13px;
  line-height: 1.25;
}

.category-stats li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.category-stats li i {
  color: #f1f3f3;
  font-size: 5px;
}

.category-browse-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 39px;
  margin-top: auto;
  padding: 0 10px 0 12px;
  border: 1px solid #3e4344;
  border-radius: 7px;
  background: #171a1b;
  color: #f2f4f4;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
}

.category-browse-button:hover,
.category-browse-button:focus-visible {
  border-color: #7e8485;
  background: #242829;
}

.category-browse-button i {
  font-size: 12px;
}

.category-picker-control,
.category-lookbook-index {
  display: none !important;
}

.top-streams-container {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--mono-border);
  border-radius: 9px;
  background: var(--mono-panel);
}

.top-streams-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.top-streams-title {
  color: var(--mono-text);
  font-size: 17px;
}

.top-streams-wrapper {
  overflow-x: auto;
}

.party-queue {
  margin-top: 13px;
  padding: 0 12px 17px;
  border: 1px solid var(--mono-border);
  border-radius: 10px;
  background: var(--mono-panel);
}

.party-queue-header {
  min-height: 57px;
  padding: 0 0;
}

.queue-heading-icon {
  font-size: 21px;
}

.queue-header-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.queue-menu {
  position: relative;
  display: inline-flex;
}

.queue-menu-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 100;
  display: grid;
  min-width: 178px;
  padding: 6px;
  border: 1px solid var(--daylight-border, #3b4142);
  border-radius: 9px;
  background: var(--daylight-surface, #171b1c);
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.3);
}

.queue-menu-panel[hidden] {
  display: none;
}

.queue-menu-item {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  min-height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--daylight-ink, #e7eaea);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}

.queue-menu-item:hover,
.queue-menu-item:focus-visible {
  background: var(--daylight-surface-blue, #24292a);
  color: var(--daylight-primary, #ffffff);
  outline: none;
}

.queue-menu-item i {
  width: 15px;
  text-align: center;
}

.queue-menu-item--danger {
  color: #d24a53;
}

body[data-theme="dark"] .queue-menu-item--danger {
  color: #ff8c97;
}

.queue-menu-item--warning {
  color: #bd7f28;
}

body[data-theme="dark"] .queue-menu-item--warning {
  color: #f1c36d;
}

.secondary-button,
.icon-button {
  border: 1px solid #3b4142;
  border-radius: 7px;
  background: #171b1c;
  color: #e7eaea;
  font: inherit;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
}

.secondary-button {
  min-height: 34px;
  padding: 0 13px;
  font-size: 13px;
  font-weight: 600;
}

.icon-button {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  padding: 0;
  background: transparent;
  border-color: transparent;
}

.secondary-button:hover,
.secondary-button:focus-visible,
.icon-button:hover,
.icon-button:focus-visible {
  border-color: #7a8081;
  background: #24292a;
}

.queue-group {
  margin-bottom: 17px;
  padding: 13px 14px 14px;
  border: 1px solid var(--mono-border-soft);
  border-radius: 9px;
  background: #0b0e0f;
}

.queue-group-heading {
  display: flex;
  align-items: flex-start;
  min-height: 34px;
  margin-bottom: 9px;
}

.queue-group-heading h3 {
  display: flex;
  align-items: center;
  gap: 0;
  color: var(--mono-text);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.queue-group-heading p {
  display: inline;
  margin: 0 0 0 16px;
  color: #8f9698;
  font-size: 12px;
  line-height: 1.4;
}

.queue-count {
  display: inline-grid;
  min-width: 31px;
  height: 23px;
  margin-left: 10px;
  padding: 0 8px;
  place-items: center;
  border-radius: 8px;
  background: #24292a;
  color: #ecf0f0;
  font-size: 13px;
  font-weight: 600;
}

#initialStreams,
#backupStreams {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  min-height: 74px;
  padding: 0;
  overflow: visible;
  border: 0;
  background: transparent;
}

.artist,
.backup-stream {
  position: relative;
  display: grid;
  grid-template-columns: 17px 18px 42px minmax(0, 1fr) max-content;
  align-items: center;
  gap: 7px;
  min-width: 0;
  height: 74px;
  padding: 10px 9px;
  overflow: hidden;
  border: 1px solid #2d3233;
  border-radius: 8px;
  background: #101415;
  box-shadow: none;
  cursor: default;
  transition: border-color 160ms ease, background 160ms ease, opacity 160ms ease,
    transform 160ms ease;
}

.queue-stream-order {
  color: #f0f2f2;
  font-size: 16px;
  line-height: 1;
}

.queue-stream-handle {
  display: inline-grid;
  width: 18px;
  height: 30px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #f0f2f2;
  font-size: 15px;
  line-height: 1;
  cursor: grab;
}

.queue-stream-handle:hover,
.queue-stream-handle:focus-visible {
  background: #282e2f;
  color: #fff;
  outline: none;
}

.queue-stream-handle:active {
  cursor: grabbing;
}

.artist.queue-stream-dragging,
.backup-stream.queue-stream-dragging {
  opacity: 0.42;
  transform: scale(0.985);
}

.artist.queue-stream-drop-target,
.backup-stream.queue-stream-drop-target {
  border-color: #7a8586;
  background: #1a2021;
}

.artist-img-container.queue-stream-avatar,
.backup-stream-img-container.queue-stream-avatar {
  width: 42px;
  height: 42px;
  margin: 0;
  border: 1px solid #777e7f;
  border-radius: 50%;
  box-shadow: none;
}

.artist-img-container.queue-stream-avatar img,
.backup-stream-img-container.queue-stream-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.queue-stream-copy {
  min-width: 0;
}

.queue-stream-name {
  overflow: hidden;
  margin: 0;
  color: #f0f2f2;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-stream-subtitle {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  color: #979d9f;
  font-size: 12px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-stream-signal {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  color: #bfc5c6;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.queue-stream-live-dot {
  display: inline-block;
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.queue-stream-live-dot.is-live {
  background: #25d980;
  box-shadow: 0 0 0 2px rgba(37, 217, 128, 0.12);
}

.queue-stream-live-dot.is-offline {
  background: #f15b63;
  box-shadow: 0 0 0 2px rgba(241, 91, 99, 0.12);
}

.queue-stream-viewers {
  overflow: hidden;
  color: #32e18a;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-stream-signal.is-checking {
  color: #99a1a2;
}

.queue-stream-actions {
  position: absolute;
  top: 5px;
  right: 5px;
  display: none;
  gap: 3px;
}

.artist:hover .queue-stream-actions,
.backup-stream:hover .queue-stream-actions,
.artist:focus-within .queue-stream-actions,
.backup-stream:focus-within .queue-stream-actions {
  display: inline-flex;
}

.queue-stream-actions button {
  display: inline-grid;
  width: 22px;
  height: 22px;
  place-items: center;
  padding: 0;
  border: 1px solid #555b5c;
  border-radius: 5px;
  background: #121617;
  color: #eef1f1;
  font-size: 11px;
  cursor: pointer;
}

.queue-stream-actions button:hover {
  background: #2b3031;
}

.queue-add-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 62px;
  border: 1px dashed #707778;
  border-radius: 8px;
  background: transparent;
  color: #c2c8c8;
  font: inherit;
  font-size: 16px;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.queue-add-more:hover,
.queue-add-more:focus-visible {
  border-color: #c2c7c7;
  background: #171b1c;
  color: #fff;
}

.queue-builder {
  display: grid;
  gap: 9px;
  margin-top: 12px;
  padding: 13px;
  border: 1px solid var(--mono-border-soft);
  border-radius: 8px;
  background: #0e1213;
}

.queue-builder[hidden] {
  display: none;
}

.queue-builder-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 8px;
}

.queue-builder-row label {
  color: #e2e6e6;
  font-size: 12px;
  font-weight: 600;
}

.queue-builder-row input {
  min-width: 0;
  height: 34px;
  padding: 0 10px;
  border: 1px solid #3d4445;
  border-radius: 6px;
  outline: 0;
  background: #080b0c;
  color: #f2f4f4;
  font: inherit;
  font-size: 12px;
}

.queue-builder-row input:focus {
  border-color: #8a9192;
  box-shadow: 0 0 0 2px rgba(210, 215, 215, 0.12);
}

.dashboard-rail {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 14px;
}

.rail-card {
  min-width: 0;
  overflow: hidden;
  padding: 16px 14px;
  border: 1px solid var(--mono-border);
  border-radius: 10px;
  background: #0b0e0f;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.02) inset;
}

.channel-card {
  display: flex;
  align-items: center;
  min-height: 90px;
  padding: 13px 16px;
}

.youtube-mark {
  display: grid;
  flex: 0 0 50px;
  width: 50px;
  height: 36px;
  margin-right: 16px;
  place-items: center;
  border-radius: 9px;
  background: #f10e14;
  color: #fff;
  font-size: 25px;
}

.channel-copy {
  min-width: 0;
}

.channel-copy h2 {
  margin: 0 0 4px;
  color: var(--mono-text);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.1;
}

.channel-copy a {
  display: block;
  overflow: hidden;
  color: #e1e5e5;
  font-size: 16px;
  line-height: 1.2;
  text-overflow: ellipsis;
  text-decoration: none;
  white-space: nowrap;
}

.channel-copy a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.rail-chevron {
  margin-left: auto;
  color: #b7bdbd;
  font-size: 13px;
}

.support-card {
  padding: 14px;
}

.support-card .rail-card-heading,
.social-card .rail-card-heading {
  margin-bottom: 10px;
}

.support-card .rail-heading-label > i,
.social-card .rail-heading-label > i {
  width: 20px;
  height: 20px;
  margin-right: 9px;
  color: #c6cdcd;
  font-size: 16px;
}

.support-card .rail-card-heading h2,
.social-card .rail-card-heading h2 {
  font-size: 16px;
}

.support-card-copy {
  margin: -1px 0 10px;
  color: #98a0a1;
  font-size: 11px;
  line-height: 1.35;
}

.support-links {
  display: grid;
  gap: 7px;
}

.support-link {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 48px;
  padding: 7px 8px;
  border: 1px solid #2d3334;
  border-radius: 8px;
  background: #111617;
  color: #eef1f1;
  text-decoration: none;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

a.support-link:hover,
a.support-link:focus-visible {
  border-color: #747d7e;
  background: #1b2021;
  outline: none;
}

.support-link--placeholder,
.support-link--placeholder:disabled {
  width: 100%;
  opacity: 0.7;
  cursor: not-allowed;
}

.support-card .support-link--placeholder {
  min-height: 44px;
}

.support-link-icon {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  font-size: 16px;
}

.support-link-icon--x {
  background: #e9eeee;
  color: #101415;
}

.support-link-icon--x svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.support-link-icon--youtube {
  background: #f10e14;
  color: #fff;
}

.support-link-icon--twitch {
  background: #9146ff;
  color: #fff;
}

.support-link-icon--coffee {
  background: #d8a56b;
  color: #24170d;
}

.support-link-copy {
  display: grid;
  min-width: 0;
  gap: 2px;
  text-align: left;
}

.support-link-copy strong,
.support-link-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-link-copy strong {
  color: #eef1f1;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.2;
}

.support-link-copy small {
  color: #98a0a1;
  font-size: 11px;
  line-height: 1.2;
}

.support-link-arrow {
  color: #aeb5b5;
  font-size: 11px;
}

.support-placeholder-badge {
  padding: 3px 6px;
  border: 1px solid #555d5e;
  border-radius: 999px;
  color: #c5cccc;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.favorites-card {
  height: 383px;
}

.groups-card {
  height: 326px;
}

.rail-card-heading {
  min-height: 27px;
}

.rail-heading-label > i {
  width: 24px;
  height: 24px;
  margin-right: 10px;
  font-size: 21px;
}

.rail-card-heading h2 {
  font-size: 18px;
}

.favorite-streamers-container {
  height: 314px;
  margin-top: 11px;
  overflow: hidden;
}

.favorite-streamer {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  min-width: 0;
  min-height: 52px;
  border-bottom: 1px solid #292e2f;
}

.favorite-streamer:last-child {
  border-bottom: 0;
}

.favorite-streamer .top-stream-container {
  display: contents;
}

.favorite-streamer .top-stream-image-container {
  grid-column: 1;
  width: 40px;
  height: 40px;
  margin: 0;
  border: 1px solid #737a7b;
  box-shadow: none;
}

.favorite-streamer .top-stream-image-container img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.favorite-streamer .top-stream-info {
  display: block;
  grid-column: 2 / 4;
  min-width: 0;
}

.favorite-name-line {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 8px;
}

.favorite-name-line h3 {
  min-width: 0;
  flex: 1 1 auto;
}

.favorite-live-dot {
  display: inline-block;
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #20c778;
  box-shadow: 0 0 0 2px rgba(32, 199, 120, 0.1);
}

.favorite-streamer .top-stream-info h3 {
  overflow: hidden;
  color: #f1f3f3;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.favorite-streamer .top-stream-info p {
  overflow: hidden;
  margin-top: 3px;
  color: #aeb5b5;
  font-size: 11px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.favorite-viewers {
  flex: 0 0 auto;
  color: #32e18a;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
}

.favorites-card .add-stream-btn {
  display: none;
}

.groups-card .rail-card-heading {
  margin-bottom: 12px;
}

.watch-party-container {
  display: grid;
  gap: 8px;
}

.groups-card .watch-party,
.watch-party.group-card {
  position: relative;
  display: grid;
  grid-template-columns: 49px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 75px;
  padding: 8px 10px;
  overflow: visible;
  border: 1px solid #303536;
  border-radius: 8px;
  background: #101415;
  cursor: pointer;
  opacity: 1;
}

.groups-card .group-card {
  width: 100% !important;
  max-width: none !important;
  flex: 0 0 auto !important;
}

.groups-card .watch-party::before,
.groups-card .watch-party::after {
  display: none !important;
}

.group-icon {
  display: grid;
  width: 49px;
  height: 49px;
  place-items: center;
  border: 1px solid #3d4344;
  border-radius: 8px;
  color: #f0f2f2;
  font-size: 24px;
}

.group-copy {
  min-width: 0;
}

.group-copy h3 {
  overflow: hidden;
  margin: 0;
  color: #f1f3f3;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.group-copy p {
  margin: 3px 0 4px;
  color: #9ba2a3;
  font-size: 11px;
  line-height: 1.15;
}

.group-avatars {
  display: flex;
  align-items: center;
  height: 15px;
}

.group-avatars span {
  display: grid;
  width: 15px;
  height: 15px;
  margin-right: -2px;
  place-items: center;
  border: 1px solid #111415;
  border-radius: 50%;
  background: #b86c3a;
  color: #151819;
  font-size: 7px;
}

.group-avatars span:nth-child(2) { background: #7e9ca7; }
.group-avatars span:nth-child(3) { background: #b8a453; }
.group-avatars span:nth-child(4) { background: #7f7f8c; }

.group-join {
  min-width: 65px;
  height: 37px;
  padding: 0 12px;
  border: 1px solid #505657;
  border-radius: 7px;
  background: #1c2021;
  color: #ecefef;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
}

.group-join:hover,
.group-join:focus-visible,
.group-card:hover {
  border-color: #7b8283;
  background: #1b2021;
}

.loading-indicator,
.discovery-state {
  color: #aeb5b5;
  font-size: 13px;
}

.favorite-streamers-container .discovery-state {
  padding-top: 14px;
}

@media (max-width: 1280px) {
  main.dashboard-frame {
    grid-template-columns: minmax(0, 1fr) 330px;
  }

  .dashboard-main {
    padding-right: 16px;
    padding-left: 16px;
  }

  .dashboard-header,
  .section-heading {
    padding-right: 4px;
    padding-left: 4px;
  }

  .launch-button {
    min-width: 250px;
  }

  #twitchCategories,
  #initialStreams,
  #backupStreams {
    gap: 10px;
  }

  #twitchCategories .category-card {
    height: 286px;
  }

  .category-card-media {
    flex-basis: 138px;
  }

  .category-card-body {
    padding-right: 11px;
    padding-left: 11px;
  }

  .category-card-body h2 {
    font-size: 17px !important;
  }

  .artist,
  .backup-stream {
    grid-template-columns: 15px 14px 36px minmax(0, 1fr) max-content;
    gap: 5px;
    padding-right: 6px;
    padding-left: 6px;
  }

  .queue-stream-handle {
    width: 14px;
  }

  .artist-img-container.queue-stream-avatar,
  .backup-stream-img-container.queue-stream-avatar {
    width: 36px;
    height: 36px;
  }
}

@media (max-width: 1040px) {
  main.dashboard-frame {
    grid-template-columns: minmax(0, 1fr);
  }

  .dashboard-rail {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }

  .dashboard-rail .support-card {
    grid-column: 1 / -1;
  }

  .channel-card,
  .favorites-card,
  .groups-card {
    height: auto;
    min-height: 90px;
  }

  .favorites-card,
  .groups-card {
    min-height: 326px;
  }
}

@media (max-width: 760px) {
  main.dashboard-frame {
    width: calc(100% - 16px);
    margin: 8px;
  }

  .dashboard-main {
    padding: 14px 12px;
  }

  .dashboard-header {
    min-height: 114px;
    flex-direction: column;
    gap: 14px;
  }

  .launch-button {
    width: 100%;
    min-width: 0;
  }

  #twitchCategories {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #initialStreams,
  #backupStreams {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-rail {
    grid-template-columns: 1fr;
  }

  .queue-group-heading {
    min-height: 52px;
  }

  .queue-group-heading p {
    display: block;
    margin: 4px 0 0;
  }
}

@media (max-width: 480px) {
  .dashboard-header h1 {
    font-size: 25px;
  }

  .section-heading h2,
  .rail-card-heading h2 {
    font-size: 17px;
  }

  #twitchCategories,
  #initialStreams,
  #backupStreams {
    grid-template-columns: 1fr;
  }

  #twitchCategories .category-card {
    height: 284px;
  }

  .queue-builder-row {
    grid-template-columns: 1fr auto auto;
  }

  .queue-builder-row label {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .launch-button,
  .category-card,
  .category-browse-button,
  .secondary-button,
  .icon-button,
  .queue-add-more,
  .group-join {
    transition: none;
  }

  .dashboard-three-layer {
    opacity: 0.28;
  }
}

/* Resolve legacy carousel sizing after the screenshot grid takes over. */

.twitch-categories-container {
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scrollbar-width: none;
}

.twitch-categories-container::-webkit-scrollbar {
  display: none;
}

#twitchCategories {
  display: grid !important;
  grid-template-columns: none !important;
  grid-template-rows: minmax(0, 1fr) !important;
  grid-auto-flow: column !important;
  grid-auto-columns: calc((100% - 51px) / 4) !important;
  width: 100% !important;
  min-width: 100% !important;
}

#twitchCategories .category-card,
#twitchCategories .category-card[data-carousel-active="true"],
#twitchCategories .category-card[data-carousel-active="true"]:hover,
#twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
#twitchCategories .category-card[data-carousel-active="true"]:focus-within,
#twitchCategories .category-card[data-carousel-active="true"].is-selected {
  width: 100% !important;
  height: 295px !important;
  flex: 0 0 auto !important;
  transform: none !important;
}

#favorite-streamers .favorite-streamers-container {
  display: flex !important;
  flex-direction: column !important;
  flex-wrap: nowrap !important;
  width: 100% !important;
}

#favorite-streamers .favorite-streamer {
  display: grid !important;
  flex: 0 0 52px !important;
  align-self: stretch !important;
  grid-template-columns: 40px minmax(0, 1fr) !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  height: 52px !important;
  min-height: 52px !important;
}

#favorite-streamers .favorite-streamer .top-stream-container {
  display: contents !important;
  width: auto !important;
  min-width: 0 !important;
}

#favorite-streamers .favorite-streamer .top-stream-image-container {
  grid-column: 1 !important;
  width: 40px !important;
  height: 40px !important;
}

#favorite-streamers .favorite-streamer .top-stream-info {
  grid-column: 2 !important;
  width: auto !important;
  min-width: 0 !important;
}

#favorite-streamers .favorite-streamer .add-stream-btn {
  display: none !important;
}

#initialStreams > .artist,
#backupStreams > .backup-stream {
  width: 100% !important;
  min-width: 0 !important;
  flex: 0 0 auto !important;
}

#launchWatchParty.launch-button {
  border-color: #777d7d !important;
  background: #0b0e0f !important;
  box-shadow: none !important;
  color: var(--mono-text) !important;
}

#launchWatchParty.launch-button:hover,
#launchWatchParty.launch-button:focus-visible {
  border-color: #b8bdbd !important;
  background: #15191a !important;
}

.demo-mode-top-button[hidden] {
  display: none !important;
}

@media (max-width: 1280px) {
  #twitchCategories .category-card,
  #twitchCategories .category-card[data-carousel-active="true"],
  #twitchCategories .category-card[data-carousel-active="true"]:hover,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-within,
  #twitchCategories .category-card[data-carousel-active="true"].is-selected {
    height: 286px !important;
  }
}

/* Page-Surface Cleanup: keep the dashboard on the page instead of nesting panels. */

.dashboard-main {
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
  padding-right: 12px;
  padding-left: 12px;
}

.twitch-categories-container {
  background: transparent !important;
}

.category-card-media {
  flex-basis: 162px;
}

#twitchCategories .category-card {
  height: 310px !important;
}

#twitchCategories .category-card-media img {
  object-fit: contain;
  object-position: center;
  background: #161a1b;
}

.top-streams-container,
.top-streams-wrapper,
.top-streams-wrapper.containers {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.top-streams-container {
  padding: 0;
}

.top-streams-wrapper,
.top-streams-wrapper.containers {
  padding: 0;
}

.party-queue {
  margin-top: 34px;
  padding: 0 0 22px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.queue-group {
  margin: 0;
  padding: 18px 0 16px;
  border: 0;
  border-top: 1px solid var(--mono-border-soft);
  border-radius: 0;
  background: transparent;
}

.queue-group:first-of-type {
  border-top: 0;
}

.dashboard-rail {
  gap: 0;
}

@media (max-width: 1040px) {
  .dashboard-rail {
    column-gap: 16px;
  }
}

.rail-card {
  padding: 0 0 18px;
  border: 0;
  border-bottom: 1px solid var(--mono-border-soft);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.rail-card + .rail-card {
  padding-top: 18px;
}

.rail-card:last-child {
  border-bottom: 0;
}

.channel-card,
.support-card {
  min-height: 90px;
  padding-right: 0;
  padding-left: 0;
}

.favorites-card,
.groups-card {
  height: auto;
}

@media (max-width: 1280px) {
  .dashboard-main {
    padding-right: 8px;
    padding-left: 8px;
  }

  #twitchCategories .category-card {
    height: 300px !important;
  }

  .category-card-media {
    flex-basis: 152px;
  }
}

@media (max-width: 760px) {
  .dashboard-main {
    padding-right: 0;
    padding-left: 0;
  }

  #twitchCategories .category-card {
    height: 292px !important;
  }

  .category-card-media {
    flex-basis: 144px;
  }
}

/* -------------------------------------------------------------------------- */
/* Accepted daylight visual system                                            */
/* -------------------------------------------------------------------------- */

:root {
  color-scheme: light;
  --daylight-bg: #f5f6f2;
  --daylight-surface: #fbfbf8;
  --daylight-surface-subtle: #f1f3ef;
  --daylight-surface-blue: #edf3fb;
  --daylight-ink: #132e62;
  --daylight-ink-strong: #102858;
  --daylight-muted: #6f7f9d;
  --daylight-dim: #8d9ab4;
  --daylight-border: #dfe6f1;
  --daylight-border-soft: #e9eef6;
  --daylight-primary: #2563eb;
  --daylight-primary-hover: #1d4ed8;
  --daylight-online: #19b77c;
  --daylight-offline: #ff6670;
  --daylight-shadow: 0 5px 14px rgba(31, 61, 113, 0.08),
    0 1px 2px rgba(31, 61, 113, 0.04);
  --mono-bg: var(--daylight-bg);
  --mono-panel: var(--daylight-surface);
  --mono-card: var(--daylight-surface);
  --mono-card-raised: var(--daylight-surface);
  --mono-border: var(--daylight-border);
  --mono-border-soft: var(--daylight-border-soft);
  --mono-text: var(--daylight-ink);
  --mono-muted: var(--daylight-muted);
  --mono-dim: var(--daylight-dim);
}

html {
  background: var(--daylight-bg) !important;
}

body {
  color: var(--daylight-ink);
  background: var(--daylight-bg) !important;
  background-image: none !important;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
}

.dashboard-three-layer {
  display: none !important;
}

main.dashboard-frame {
  background: transparent;
  box-shadow: none;
}

.dashboard-main {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}

.dashboard-rail {
  border-left: 1px solid var(--daylight-border-soft);
  padding-left: 14px;
}

.dashboard-header h1,
.section-heading h2,
.rail-card-heading h2,
.party-queue h2,
.queue-group-heading h3,
.channel-copy h2,
.group-copy h3,
.favorite-streamer .top-stream-info h3,
.top-streams-title {
  color: var(--daylight-ink-strong) !important;
}

.dashboard-header h1 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.launch-button,
#launchWatchParty.launch-button {
  min-width: 256px;
  border: 1px solid #6f9bf1 !important;
  border-radius: 15px;
  background: var(--daylight-surface) !important;
  box-shadow: 0 1px 2px rgba(31, 61, 113, 0.04);
  color: var(--daylight-primary) !important;
  font-size: 15px;
  font-weight: 600;
}

.launch-button .fa-chevron-down {
  color: var(--daylight-primary);
}

.launch-button:hover,
.launch-button:focus-visible,
#launchWatchParty.launch-button:hover,
#launchWatchParty.launch-button:focus-visible {
  border-color: var(--daylight-primary) !important;
  background: var(--daylight-surface-blue) !important;
  color: var(--daylight-primary-hover) !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.section-heading,
.party-queue-header {
  margin-bottom: 12px;
}

.section-heading-icon,
.rail-heading-label > i,
.queue-heading-icon {
  color: var(--daylight-primary) !important;
}

.section-heading h2,
.rail-card-heading h2 {
  font-weight: 700;
}

.section-link {
  color: var(--daylight-muted);
}

.section-link i,
.section-link:hover,
.section-link:focus-visible {
  color: var(--daylight-primary);
}

#twitchCategories .category-card {
  border-color: var(--daylight-border) !important;
  border-radius: 9px;
  background: var(--daylight-surface) !important;
  box-shadow: var(--daylight-shadow);
}

#twitchCategories .category-card:hover,
#twitchCategories .category-card:focus-visible,
#twitchCategories .category-card:focus-within {
  border-color: #9ebcf7 !important;
  box-shadow: 0 8px 18px rgba(31, 61, 113, 0.12);
}

#twitchCategories .category-card.is-selected {
  border-color: var(--daylight-primary) !important;
  box-shadow: 0 0 0 1px var(--daylight-primary),
    0 9px 20px rgba(37, 99, 235, 0.14);
}

#twitchCategories .category-card[data-carousel-active="true"],
#twitchCategories .category-card[data-carousel-active="true"]:hover,
#twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
#twitchCategories .category-card[data-carousel-active="true"]:focus-within {
  border-color: var(--daylight-border) !important;
  background: var(--daylight-surface) !important;
  box-shadow: var(--daylight-shadow);
  transform: none !important;
}

#twitchCategories .category-card[data-carousel-active="true"].is-selected {
  border-color: var(--daylight-primary) !important;
  box-shadow: 0 0 0 1px var(--daylight-primary),
    0 9px 20px rgba(37, 99, 235, 0.14);
}

#twitchCategories .category-card[data-carousel-active="true"],
#twitchCategories .category-card[data-carousel-active="true"]:hover,
#twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
#twitchCategories .category-card[data-carousel-active="true"]:focus-within {
  box-shadow: var(--daylight-shadow) !important;
}

#twitchCategories .category-card[data-carousel-active="true"].is-selected {
  box-shadow: 0 0 0 1px var(--daylight-primary),
    0 9px 20px rgba(37, 99, 235, 0.14) !important;
}

.category-card-media,
#twitchCategories .category-card-media img {
  background: var(--daylight-surface-subtle);
}

#twitchCategories .category-card-media img {
  border-radius: 7px;
}

.category-live-badge {
  border-radius: 5px;
  background: var(--daylight-primary) !important;
  color: #ffffff !important;
}

#twitchCategories .category-card-body h2 {
  color: var(--daylight-ink-strong) !important;
  font-size: 19px;
  font-weight: 700;
}

.category-stats {
  color: #40567c;
}

.category-stats li i {
  color: #304d82;
}

.category-browse-button {
  border-color: #d3def0;
  border-radius: 8px;
  background: var(--daylight-surface);
  color: var(--daylight-primary);
  font-weight: 600;
}

.category-browse-button:hover,
.category-browse-button:focus-visible,
#twitchCategories .category-card.is-selected .category-browse-button {
  border-color: var(--daylight-primary);
  background: var(--daylight-primary);
  color: #ffffff;
  box-shadow: 0 3px 8px rgba(37, 99, 235, 0.16);
}

.party-queue {
  border-color: transparent;
  background: transparent;
}

.secondary-button,
.icon-button {
  border-color: #cbd8ed;
  border-radius: 8px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
}

.secondary-button:hover,
.secondary-button:focus-visible,
.icon-button:hover,
.icon-button:focus-visible {
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.queue-group {
  border-color: var(--daylight-border-soft);
  background: transparent;
}

.queue-group-heading p,
.queue-stream-subtitle,
.loading-indicator,
.discovery-state,
.support-card-copy,
.support-link-copy small,
.group-copy p,
.favorite-streamer .top-stream-info p {
  color: var(--daylight-muted) !important;
}

.queue-count {
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.artist,
.backup-stream {
  border-color: var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface);
  box-shadow: var(--daylight-shadow);
}

.artist:hover,
.backup-stream:hover,
.artist.queue-stream-drop-target,
.backup-stream.queue-stream-drop-target {
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
}

.queue-stream-order,
.queue-stream-handle,
.queue-stream-name {
  color: var(--daylight-ink-strong);
}

.artist .queue-stream-name,
.backup-stream .queue-stream-name {
  color: var(--daylight-ink-strong) !important;
  font-weight: 600;
}

.queue-stream-handle:hover,
.queue-stream-handle:focus-visible {
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.artist-img-container.queue-stream-avatar,
.backup-stream-img-container.queue-stream-avatar {
  border-color: #a8b7cf;
}

.queue-stream-viewers,
.favorite-viewers {
  color: var(--daylight-online) !important;
}

.queue-stream-live-dot.is-live,
.favorite-live-dot {
  background: var(--daylight-online);
  box-shadow: 0 0 0 2px rgba(25, 183, 124, 0.12);
}

.queue-stream-live-dot.is-offline {
  background: var(--daylight-offline);
  box-shadow: 0 0 0 2px rgba(255, 102, 112, 0.12);
}

.queue-stream-actions button {
  border-color: #cbd8ed;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
}

.queue-stream-actions button:hover {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.queue-add-more {
  border-color: #b8ccef;
  background: var(--daylight-surface);
  color: var(--daylight-primary);
}

.queue-add-more:hover,
.queue-add-more:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

.queue-builder {
  border-color: var(--daylight-border);
  background: var(--daylight-surface-subtle);
}

.queue-builder-row label {
  color: var(--daylight-ink);
}

.queue-builder-row input {
  border-color: #cbd8ed;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
}

.queue-builder-row input:focus {
  border-color: var(--daylight-primary);
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.12);
}

.rail-card {
  border-color: var(--daylight-border-soft);
  background: transparent;
}

.channel-copy a {
  color: var(--daylight-muted);
}

.rail-chevron,
.support-link-arrow {
  color: var(--daylight-muted);
}

.support-link {
  border-color: var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  box-shadow: 0 2px 6px rgba(31, 61, 113, 0.04);
}

a.support-link:hover,
a.support-link:focus-visible {
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
}

.support-link-icon--x {
  background: #e6efff;
  color: var(--daylight-primary);
}

.support-link-icon--youtube {
  background: #ffe4e5;
  color: #d10f17;
}

.support-link-icon--twitch {
  background: #efe1ff;
  color: #7b2dc1;
}

.support-link-icon--coffee {
  background: #fff0c9;
  color: #bb7a13;
}

.support-link-copy strong {
  color: var(--daylight-ink-strong);
}

.support-placeholder-badge {
  border-color: #b8ccef;
  color: var(--daylight-primary);
}

.favorite-streamer {
  border-color: var(--daylight-border-soft);
}

.favorite-streamer .top-stream-image-container {
  border-color: #a8b7cf;
}

.favorite-viewers {
  font-variant-numeric: tabular-nums;
}

.groups-card .watch-party,
.watch-party.group-card {
  border-color: var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface);
  box-shadow: 0 2px 7px rgba(31, 61, 113, 0.05);
}

.groups-card .watch-party:hover,
.groups-card .watch-party:focus-within,
.watch-party.group-card:hover {
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
}

.group-icon {
  border-color: #d7e2f5;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.group-copy h3 {
  color: var(--daylight-ink-strong) !important;
}

.group-join {
  border-color: var(--daylight-primary);
  border-radius: 8px;
  background: var(--daylight-primary);
  color: #ffffff;
  box-shadow: 0 3px 8px rgba(37, 99, 235, 0.14);
}

.group-join:hover,
.group-join:focus-visible {
  border-color: var(--daylight-primary-hover);
  background: var(--daylight-primary-hover);
}

@media (max-width: 1040px) {
  .dashboard-rail {
    border-left: 0;
    padding-left: 0;
  }
}

@media (max-width: 760px) {
  .launch-button,
  #launchWatchParty.launch-button {
    min-width: 0;
  }
}

/* -------------------------------------------------------------------------- */
/* Color-tinted dark mode                                                     */
/* -------------------------------------------------------------------------- */

.dashboard-header-actions {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.dashboard-remote-button {
  display: inline-flex;
  min-width: 154px;
  height: 48px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid var(--daylight-border);
  border-radius: 15px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease,
    box-shadow 160ms ease, transform 160ms ease;
}

.dashboard-remote-button i {
  color: var(--daylight-primary);
  font-size: 15px;
}

.dashboard-remote-button:hover,
.dashboard-remote-button:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-ink-strong);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
  outline: none;
  transform: translateY(-1px);
}

body[data-theme="dark"] .dashboard-remote-button:hover,
body[data-theme="dark"] .dashboard-remote-button:focus-visible {
  border-color: #858585;
  background: var(--daylight-surface-subtle);
  color: #fff;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.07);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid #cbd8ed;
  border-radius: 50%;
  background: var(--daylight-surface);
  color: var(--daylight-primary);
  font-size: 15px;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease,
    transform 160ms ease;
}

@media (min-width: 761px) {
  .dashboard-header-actions .theme-toggle {
    position: absolute;
    top: 3px;
    right: calc(100% + 10px);
  }
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
  transform: translateY(-1px);
}

html[data-theme="dark"] {
  color-scheme: dark;
  background: #181818 !important;
}

body[data-theme="dark"] {
  /* Keep dark mode neutral so artwork and semantic accents carry the color. */
  --daylight-bg: #181818;
  --daylight-surface: #242424;
  --daylight-surface-subtle: #2b2b2b;
  --daylight-surface-blue: #323232;
  --daylight-ink: #ededed;
  --daylight-ink-strong: #ffffff;
  --daylight-muted: #b1b1b1;
  --daylight-dim: #888888;
  --daylight-border: #484848;
  --daylight-border-soft: #353535;
  --daylight-primary: #d7d7d7;
  --daylight-primary-hover: #ffffff;
  --daylight-online: #4ad486;
  --daylight-offline: #ff6872;
  --daylight-shadow: 0 5px 14px rgba(0, 0, 0, 0.22),
    0 1px 2px rgba(0, 0, 0, 0.24);
  --mono-bg: var(--daylight-bg);
  --mono-panel: var(--daylight-surface);
  --mono-card: var(--daylight-surface);
  --mono-card-raised: var(--daylight-surface);
  --mono-border: var(--daylight-border);
  --mono-border-soft: var(--daylight-border-soft);
  --mono-text: var(--daylight-ink);
  --mono-muted: var(--daylight-muted);
  --mono-dim: var(--daylight-dim);
  color: var(--daylight-ink);
  background: var(--daylight-bg) !important;
  background-image: none !important;
}

body[data-theme="dark"] main.dashboard-frame,
body[data-theme="dark"] .dashboard-main {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

body[data-theme="dark"] .dashboard-rail {
  border-left-color: var(--daylight-border-soft);
}

body[data-theme="dark"] .dashboard-header h1,
body[data-theme="dark"] .section-heading h2,
body[data-theme="dark"] .rail-card-heading h2,
body[data-theme="dark"] .party-queue h2,
body[data-theme="dark"] .queue-group-heading h3,
body[data-theme="dark"] .channel-copy h2,
body[data-theme="dark"] .group-copy h3,
body[data-theme="dark"] .favorite-streamer .top-stream-info h3,
body[data-theme="dark"] .top-streams-title {
  color: var(--daylight-ink-strong) !important;
}

body[data-theme="dark"] .theme-toggle {
  border-color: #505050;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-primary);
}

body[data-theme="dark"] .theme-toggle:hover,
body[data-theme="dark"] .theme-toggle:focus-visible {
  border-color: #7c7c7c;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

body[data-theme="dark"] .launch-button,
body[data-theme="dark"] #launchWatchParty.launch-button {
  border-color: #606060 !important;
  background: var(--daylight-surface) !important;
  color: var(--daylight-primary) !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .launch-button .fa-chevron-down {
  color: var(--daylight-primary);
}

body[data-theme="dark"] .launch-button:hover,
body[data-theme="dark"] .launch-button:focus-visible,
body[data-theme="dark"] #launchWatchParty.launch-button:hover,
body[data-theme="dark"] #launchWatchParty.launch-button:focus-visible {
  border-color: var(--daylight-primary) !important;
  background: var(--daylight-surface-subtle) !important;
  color: var(--daylight-primary-hover) !important;
  box-shadow: 0 0 0 3px rgba(215, 215, 215, 0.14);
}

body[data-theme="dark"] .section-heading-icon,
body[data-theme="dark"] .rail-heading-label > i,
body[data-theme="dark"] .queue-heading-icon {
  color: var(--daylight-primary) !important;
}

body[data-theme="dark"] .section-link,
body[data-theme="dark"] .channel-copy a,
body[data-theme="dark"] .rail-chevron,
body[data-theme="dark"] .support-link-arrow {
  color: var(--daylight-muted);
}

body[data-theme="dark"] .section-link i,
body[data-theme="dark"] .section-link:hover,
body[data-theme="dark"] .section-link:focus-visible {
  color: var(--daylight-primary);
}

body[data-theme="dark"] #twitchCategories .category-card,
body[data-theme="dark"] #twitchCategories .category-card[data-carousel-active="true"],
body[data-theme="dark"]
  #twitchCategories
  .category-card[data-carousel-active="true"]:hover,
body[data-theme="dark"]
  #twitchCategories
  .category-card[data-carousel-active="true"]:focus-visible,
body[data-theme="dark"]
  #twitchCategories
  .category-card[data-carousel-active="true"]:focus-within {
  border-color: var(--daylight-border) !important;
  border-radius: 9px;
  background: var(--daylight-surface-subtle) !important;
  box-shadow: 0 5px 14px rgba(0, 0, 0, 0.2) !important;
}

body[data-theme="dark"] #twitchCategories .category-card:hover,
body[data-theme="dark"] #twitchCategories .category-card:focus-visible,
body[data-theme="dark"] #twitchCategories .category-card:focus-within {
  border-color: #707070 !important;
  background: var(--daylight-surface-blue) !important;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(215, 215, 215, 0.08) !important;
}

body[data-theme="dark"] #twitchCategories .category-card.is-selected,
body[data-theme="dark"]
  #twitchCategories
  .category-card[data-carousel-active="true"].is-selected {
  border-color: var(--daylight-primary) !important;
  background: #383838 !important;
  box-shadow: 0 0 0 1px var(--daylight-primary),
    0 9px 20px rgba(0, 0, 0, 0.28) !important;
}

body[data-theme="dark"] .category-card-media,
body[data-theme="dark"] #twitchCategories .category-card-media img {
  background: var(--daylight-surface);
}

body[data-theme="dark"] .category-live-badge {
  border-color: #5c77ad;
  background: #2e4267 !important;
  color: #d7e3ff !important;
}

body[data-theme="dark"] #twitchCategories .category-card-body h2 {
  color: var(--daylight-ink-strong) !important;
}

body[data-theme="dark"] .category-stats {
  color: var(--daylight-muted);
}

body[data-theme="dark"] .category-stats li i {
  color: var(--daylight-primary);
}

body[data-theme="dark"] .category-browse-button {
  border-color: #626262;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-primary);
}

body[data-theme="dark"] .category-browse-button:hover,
body[data-theme="dark"] .category-browse-button:focus-visible,
body[data-theme="dark"]
  #twitchCategories
  .category-card.is-selected
  .category-browse-button {
  border-color: var(--daylight-primary);
  background: var(--daylight-primary);
  color: #202020;
  box-shadow: 0 3px 8px rgba(215, 215, 215, 0.16);
}

body[data-theme="dark"] .party-queue {
  border-color: transparent;
  background: transparent;
}

body[data-theme="dark"] .secondary-button,
body[data-theme="dark"] .icon-button {
  border-color: #505050;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
}

body[data-theme="dark"] .secondary-button:hover,
body[data-theme="dark"] .secondary-button:focus-visible,
body[data-theme="dark"] .icon-button:hover,
body[data-theme="dark"] .icon-button:focus-visible {
  border-color: #777777;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

body[data-theme="dark"] .queue-group {
  border-color: var(--daylight-border-soft);
  background: transparent;
}

body[data-theme="dark"] .queue-group-heading p,
body[data-theme="dark"] .queue-stream-subtitle,
body[data-theme="dark"] .loading-indicator,
body[data-theme="dark"] .discovery-state,
body[data-theme="dark"] .support-card-copy,
body[data-theme="dark"] .support-link-copy small,
body[data-theme="dark"] .group-copy p,
body[data-theme="dark"] .favorite-streamer .top-stream-info p {
  color: var(--daylight-muted) !important;
}

body[data-theme="dark"] .queue-count {
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

body[data-theme="dark"] .artist,
body[data-theme="dark"] .backup-stream {
  border-color: var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface-subtle);
  box-shadow: 0 5px 12px rgba(0, 0, 0, 0.18);
}

body[data-theme="dark"] .artist:hover,
body[data-theme="dark"] .backup-stream:hover,
body[data-theme="dark"] .artist.queue-stream-drop-target,
body[data-theme="dark"] .backup-stream.queue-stream-drop-target {
  border-color: #707070;
  background: var(--daylight-surface-blue);
}

body[data-theme="dark"] .queue-stream-order,
body[data-theme="dark"] .queue-stream-handle,
body[data-theme="dark"] .queue-stream-name,
body[data-theme="dark"] .artist .queue-stream-name,
body[data-theme="dark"] .backup-stream .queue-stream-name {
  color: var(--daylight-ink-strong) !important;
}

body[data-theme="dark"] .queue-stream-handle:hover,
body[data-theme="dark"] .queue-stream-handle:focus-visible {
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

body[data-theme="dark"] .artist-img-container.queue-stream-avatar,
body[data-theme="dark"] .backup-stream-img-container.queue-stream-avatar,
body[data-theme="dark"] .favorite-streamer .top-stream-image-container {
  border-color: #666666;
}

body[data-theme="dark"] .queue-stream-viewers,
body[data-theme="dark"] .favorite-viewers {
  color: var(--daylight-online) !important;
}

body[data-theme="dark"] .queue-stream-live-dot.is-live,
body[data-theme="dark"] .favorite-live-dot {
  background: var(--daylight-online);
  box-shadow: 0 0 0 2px rgba(74, 212, 134, 0.14);
}

body[data-theme="dark"] .queue-stream-live-dot.is-offline {
  background: var(--daylight-offline);
  box-shadow: 0 0 0 2px rgba(255, 104, 114, 0.14);
}

body[data-theme="dark"] .queue-stream-actions button:not(.remove-stream-btn) {
  border-color: #505050;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
}

body[data-theme="dark"] .queue-stream-actions button:not(.remove-stream-btn):hover {
  border-color: #777777;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

body[data-theme="dark"] .queue-add-more {
  border-color: #6b6b6b;
  background: transparent;
  color: var(--daylight-primary);
}

body[data-theme="dark"] .queue-add-more:hover,
body[data-theme="dark"] .queue-add-more:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

body[data-theme="dark"] .queue-builder {
  border-color: var(--daylight-border-soft);
  background: #202020;
}

body[data-theme="dark"] .queue-builder-row label {
  color: var(--daylight-ink);
}

body[data-theme="dark"] .queue-builder-row input {
  border-color: #505050;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
}

body[data-theme="dark"] .queue-builder-row input:focus {
  border-color: var(--daylight-primary);
  box-shadow: 0 0 0 2px rgba(215, 215, 215, 0.14);
}

body[data-theme="dark"] .rail-card {
  border-color: var(--daylight-border-soft);
  background: transparent;
}

body[data-theme="dark"] .support-link {
  border-color: var(--daylight-border-soft);
  border-radius: 8px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  box-shadow: none;
}

body[data-theme="dark"] a.support-link:hover,
body[data-theme="dark"] a.support-link:focus-visible {
  border-color: #707070;
  background: var(--daylight-surface-blue);
}

body[data-theme="dark"] .support-link-icon--x {
  background: #e6efff;
  color: #2563eb;
}

body[data-theme="dark"] .support-link-icon--youtube {
  background: #ffe4e5;
  color: #d10f17;
}

body[data-theme="dark"] .support-link-icon--twitch {
  background: #efe1ff;
  color: #7b2dc1;
}

body[data-theme="dark"] .support-link-icon--coffee {
  background: #fff0c9;
  color: #bb7a13;
}

body[data-theme="dark"] .support-link-copy strong {
  color: var(--daylight-ink-strong);
}

body[data-theme="dark"] .support-placeholder-badge {
  border-color: #6b6b6b;
  color: var(--daylight-primary);
}

body[data-theme="dark"] .favorite-streamer {
  border-color: var(--daylight-border-soft);
}

body[data-theme="dark"] .groups-card .watch-party,
body[data-theme="dark"] .watch-party.group-card {
  border-color: var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface-subtle);
  box-shadow: var(--daylight-shadow);
}

body[data-theme="dark"] .groups-card .watch-party:hover,
body[data-theme="dark"] .groups-card .watch-party:focus-within,
body[data-theme="dark"] .watch-party.group-card:hover {
  border-color: #707070;
  background: var(--daylight-surface-blue);
}

body[data-theme="dark"] .group-icon {
  border-color: #6b6b6b;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

body[data-theme="dark"] .group-join {
  border-color: #6b6b6b;
  border-radius: 8px;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
  box-shadow: 0 3px 8px rgba(215, 215, 215, 0.12);
}

body[data-theme="dark"] .group-join:hover,
body[data-theme="dark"] .group-join:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-primary);
  color: #202020;
}

body[data-theme="dark"] .group-avatars span {
  border-color: var(--daylight-surface-subtle);
  background: #d18a5b !important;
  color: #1a1f2a;
}

body[data-theme="dark"] .group-avatars span:nth-child(2) {
  background: #9ebac5 !important;
}

body[data-theme="dark"] .group-avatars span:nth-child(3) {
  background: #d2c16d !important;
}

body[data-theme="dark"] .group-avatars span:nth-child(4) {
  background: #a9acbf !important;
}

@media (max-width: 760px) {
  .dashboard-header-actions {
    width: 100%;
  }

  .dashboard-header-actions .theme-toggle {
    position: static;
  }

  .dashboard-header-actions .launch-button,
  .dashboard-header-actions #launchWatchParty.launch-button {
    flex: 1 1 auto;
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .theme-toggle {
    transition: none;
  }
}

/* -------------------------------------------------------------------------- */
/* Category card framing                                                     */
/* -------------------------------------------------------------------------- */

#twitchCategories {
  grid-auto-rows: 295px;
}

#twitchCategories .category-card,
#twitchCategories .category-card[data-carousel-active="true"],
#twitchCategories .category-card[data-carousel-active="true"]:hover,
#twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
#twitchCategories .category-card[data-carousel-active="true"]:focus-within,
#twitchCategories .category-card[data-carousel-active="true"].is-selected {
  height: 295px !important;
  min-height: 295px;
  max-height: 295px;
}

#twitchCategories .category-card-media {
  flex: 0 0 162px;
  height: 162px;
  min-height: 162px;
}

#twitchCategories .category-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: transparent;
}

#twitchCategories .category-card-body {
  min-height: 0;
}

#twitchCategories .category-card-body h2 {
  min-height: 21px;
}

@media (max-width: 1280px) {
  #twitchCategories {
    grid-auto-rows: 300px;
  }

  #twitchCategories .category-card,
  #twitchCategories .category-card[data-carousel-active="true"],
  #twitchCategories .category-card[data-carousel-active="true"]:hover,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-within,
  #twitchCategories .category-card[data-carousel-active="true"].is-selected {
    height: 300px !important;
    min-height: 300px;
    max-height: 300px;
  }

  #twitchCategories .category-card-media {
    flex-basis: 152px;
    height: 152px;
    min-height: 152px;
  }
}

@media (max-width: 760px) {
  #twitchCategories {
    grid-auto-rows: 292px;
    grid-auto-columns: minmax(176px, calc((100% - 51px) / 4)) !important;
  }

  #twitchCategories .category-card,
  #twitchCategories .category-card[data-carousel-active="true"],
  #twitchCategories .category-card[data-carousel-active="true"]:hover,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-within,
  #twitchCategories .category-card[data-carousel-active="true"].is-selected {
    height: 292px !important;
    min-height: 292px;
    max-height: 292px;
  }

  #twitchCategories .category-card-media {
    flex-basis: 144px;
    height: 144px;
    min-height: 144px;
  }
}

@media (max-width: 480px) {
  #twitchCategories {
    grid-auto-rows: 284px;
    grid-auto-columns: minmax(176px, calc((100% - 34px) / 2)) !important;
  }

  #twitchCategories .category-card,
  #twitchCategories .category-card[data-carousel-active="true"],
  #twitchCategories .category-card[data-carousel-active="true"]:hover,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
  #twitchCategories .category-card[data-carousel-active="true"]:focus-within,
  #twitchCategories .category-card[data-carousel-active="true"].is-selected {
    height: 284px !important;
    min-height: 284px;
    max-height: 284px;
  }
}

/* -------------------------------------------------------------------------- */
/* Twitch-style top stream strip                                             */
/* -------------------------------------------------------------------------- */

/*
 * This strip is intentionally a compact, neutral-black surface. It mirrors
 * Twitch's dense browse treatment without changing the dashboard's light/dark
 * page theme or the live data supplied by Twitch.
 */
.top-streams-container {
  color: #f1f1f1;
  background: #101010;
}

.top-streams-heading {
  min-height: 36px;
  margin-left: -6px;
  margin-bottom: 10px;
}

.top-streams-title {
  margin: 0;
  color: #f1f1f1 !important;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 20px;
}

.top-streams-heading .section-link {
  display: inline-grid;
  width: 20px;
  height: 20px;
  padding: 0;
  place-items: center;
  color: #b5b5b5;
}

.top-streams-heading .section-link i {
  color: currentColor;
  font-size: 14px;
}

.top-streams-heading .section-link:hover,
.top-streams-heading .section-link:focus-visible {
  color: #ffffff;
  text-decoration: none;
}

.top-streams-wrapper {
  margin: 0 -10px 0 -16px;
  padding: 0 10px;
  overflow-x: auto;
  overflow-y: hidden;
}

.top-streams {
  gap: 12px;
  min-width: max-content;
  padding: 0 0 10px;
}

.top-stream {
  width: 100px;
  margin: 0 24px 0 0;
  color: #f1f1f1;
}

.top-stream-container {
  position: relative;
  width: 100px;
  height: 100px;
}

.top-streams .top-stream-image-container {
  width: 100px;
  height: 100px;
  border: 2px solid #5c5c5c;
  border-radius: 50%;
  background: #181818;
  box-shadow: none;
}

.top-streams .top-stream-image-container:hover,
.top-streams .top-stream:hover .top-stream-image-container,
.top-streams .top-stream-image-container:focus {
  border-color: #36d36a;
  box-shadow: 0 0 0 2px rgba(54, 211, 106, 0.2);
}

.top-streams .add-stream-btn {
  top: -2px;
  right: -3px;
  display: inline-grid;
  width: 26px;
  height: 26px;
  padding: 0;
  place-items: center;
  border: 2px solid #4b4b4b;
  border-radius: 50%;
  background: #31d566;
  color: #ffffff;
  font-family: Arial, sans-serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.58);
}

.top-streams .add-stream-btn:hover,
.top-streams .add-stream-btn:focus-visible {
  background: #48e67b;
  transform: scale(1.08);
}

.top-stream-info {
  margin-top: 5px;
  padding: 0 4px;
  color: #f1f1f1;
}

.top-streams .top-stream-info h3 {
  margin: 0 0 4px;
  color: #f1f1f1 !important;
  font-size: 14px;
  font-weight: 600;
  line-height: 17px;
}

.top-streams .top-stream-info p {
  margin: 0;
  color: #a6a6a6 !important;
  font-size: 14px;
  font-weight: 500;
  line-height: 17px;
}

.top-streams-wrapper::-webkit-scrollbar {
  height: 7px;
}

.top-streams-wrapper::-webkit-scrollbar-track {
  border: 0;
  border-radius: 0;
  background: #151515;
}

.top-streams-wrapper::-webkit-scrollbar-thumb {
  border: 0;
  border-radius: 999px;
  background: #4a4a4a;
}

.top-streams-wrapper::-webkit-scrollbar-thumb:hover {
  background: #626262;
}

.top-streams-wrapper {
  scrollbar-color: #4a4a4a #151515;
  scrollbar-width: thin;
}

@media (max-width: 760px) {
  .top-streams-container {
    margin-top: 12px;
  }

  .top-streams-heading {
    min-height: 34px;
  }
}

/* Responsive cover ratio and viewport-aware category density. */

#twitchCategories {
  --category-card-width: clamp(176px, 13.5vw, 200px);
  --category-cover-ratio: 3 / 4;
  grid-template-rows: max-content !important;
  grid-auto-rows: max-content !important;
  grid-auto-columns: var(--category-card-width) !important;
  height: auto !important;
  min-height: 0;
  align-items: start;
}

#twitchCategories .category-card,
#twitchCategories .category-card[data-carousel-active="true"],
#twitchCategories .category-card[data-carousel-active="true"]:hover,
#twitchCategories .category-card[data-carousel-active="true"]:focus-visible,
#twitchCategories .category-card[data-carousel-active="true"]:focus-within,
#twitchCategories .category-card[data-carousel-active="true"].is-selected {
  width: 100% !important;
  height: auto !important;
  min-height: 0;
  max-height: none;
  aspect-ratio: auto;
}

#twitchCategories .category-card-media {
  flex: 0 0 auto;
  width: 100%;
  height: auto;
  min-height: 0;
  aspect-ratio: var(--category-cover-ratio);
}

#twitchCategories .category-card-media img {
  aspect-ratio: var(--category-cover-ratio);
  object-fit: cover;
}

#twitchCategories .category-card-body {
  flex: 0 0 105px;
  height: 105px;
  min-height: 105px;
  box-sizing: border-box;
  overflow: hidden;
  padding-bottom: 6px;
}

#twitchCategories .category-card-body h2 {
  display: -webkit-box;
  min-height: 40px;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

/* Launch Center mode switch */

.launch-center {
  position: relative;
  display: inline-flex;
  align-items: stretch;
  min-width: 256px;
}

.launch-center .launch-button {
  min-width: 0;
  flex: 1 1 auto;
  justify-content: flex-start;
  gap: 12px;
  padding-right: 14px;
  padding-left: 18px;
  border-radius: 15px 0 0 15px;
}

.launch-center .launch-button .fa-play,
.launch-center .launch-button .fa-crosshairs {
  flex: 0 0 16px;
  font-size: 14px;
  text-align: center;
}

.launch-mode-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  flex: 0 0 44px;
  padding: 0;
  border: 1px solid #6f9bf1;
  border-left: 1px solid #dfe6f1;
  border-radius: 0 15px 15px 0;
  background: var(--daylight-surface);
  color: var(--daylight-primary);
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.launch-mode-toggle:hover,
.launch-mode-toggle:focus-visible,
.launch-mode-toggle.is-open {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
  outline: none;
}

.launch-mode-toggle.is-open .fa-chevron-down {
  transform: rotate(180deg);
}

.launch-mode-toggle .fa-chevron-down {
  font-size: 12px;
  transition: transform 160ms ease;
}

.launch-mode-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 1100;
  display: grid;
  width: min(330px, calc(100vw - 32px));
  max-height: min(360px, calc(100vh - 32px));
  padding: 7px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--daylight-border);
  border-radius: 12px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  box-shadow: 0 15px 34px rgba(31, 61, 113, 0.16);
}

.launch-mode-menu[hidden] {
  display: none;
}

.launch-mode-option {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--daylight-ink);
  text-align: left;
  cursor: pointer;
}

.launch-mode-option:hover,
.launch-mode-option:focus-visible,
.launch-mode-option.is-selected {
  border-color: var(--daylight-border-soft);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
  outline: none;
}

.launch-mode-option > i:first-child {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 7px;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-primary);
  font-size: 12px;
}

.launch-mode-option span {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.launch-mode-option strong {
  color: var(--daylight-ink-strong);
  font-size: 13px;
  font-weight: 700;
}

.launch-mode-option small {
  overflow: hidden;
  color: var(--daylight-muted);
  font-size: 11px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.launch-mode-option > i:last-child {
  color: transparent;
  font-size: 12px;
}

.launch-mode-option.is-selected > i:last-child {
  color: var(--daylight-primary);
}

body[data-theme="dark"] .launch-mode-toggle {
  border-color: #5a5a5a;
  border-left-color: var(--daylight-border);
  background: var(--daylight-surface);
  color: #f2f2f2;
}

body[data-theme="dark"] .launch-mode-toggle:hover,
body[data-theme="dark"] .launch-mode-toggle:focus-visible,
body[data-theme="dark"] .launch-mode-toggle.is-open {
  border-color: #858585;
  background: var(--daylight-surface-subtle);
  color: #ffffff;
}

body[data-theme="dark"] .launch-mode-menu {
  border-color: var(--daylight-border);
  background: var(--daylight-surface);
  box-shadow: 0 15px 34px rgba(0, 0, 0, 0.34);
}

body[data-theme="dark"] .launch-mode-option:hover,
body[data-theme="dark"] .launch-mode-option:focus-visible,
body[data-theme="dark"] .launch-mode-option.is-selected {
  background: var(--daylight-surface-blue);
}

body[data-theme="dark"] .launch-mode-option strong {
  color: #f4f4f4;
}

body[data-theme="dark"] .launch-mode-option small {
  color: #a4a4a4;
}

@media (max-width: 760px) {
  .launch-center {
    width: 100%;
    min-width: 0;
  }
}

/* Horizontal rail controls and pointer-drag affordances. */

.twitch-categories-shell,
.top-streams-scroll-rail {
  position: relative;
}

.twitch-categories-container,
.top-streams-wrapper {
  touch-action: pan-y;
  cursor: grab;
  overscroll-behavior-x: contain;
}

.twitch-categories-container.dragging,
.top-streams-wrapper.dragging {
  cursor: grabbing;
  user-select: none;
}

.twitch-categories-container.dragging *,
.top-streams-wrapper.dragging * {
  user-select: none;
}

.category-picker-control,
.horizontal-scroll-control {
  position: absolute;
  z-index: 20;
  display: grid !important;
  width: 36px;
  height: 36px;
  padding: 0;
  place-items: center;
  border: 1px solid var(--mono-border);
  border-radius: 50%;
  background: var(--mono-panel);
  box-shadow: 0 5px 16px rgba(0, 0, 0, 0.24);
  color: var(--mono-text);
  font: inherit;
  cursor: pointer;
  opacity: 0.96;
  transform: translateY(-50%);
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease,
    opacity 160ms ease, transform 160ms ease;
}

.category-picker-control:hover,
.category-picker-control:focus-visible,
.horizontal-scroll-control:hover,
.horizontal-scroll-control:focus-visible {
  border-color: var(--mono-text);
  background: var(--mono-card-raised);
  color: var(--mono-text);
  outline: none;
  transform: translateY(-50%) scale(1.05);
}

.category-picker-control:focus-visible,
.horizontal-scroll-control:focus-visible {
  box-shadow: 0 0 0 3px rgba(125, 155, 255, 0.28),
    0 5px 16px rgba(0, 0, 0, 0.24);
}

.category-picker-control:disabled,
.horizontal-scroll-control:disabled {
  cursor: default;
  opacity: 0.28;
  pointer-events: none;
  transform: translateY(-50%);
}

.category-picker-control--prev {
  top: 50%;
  left: 6px;
}

.category-picker-control--next {
  top: 50%;
  right: 6px;
}

.top-streams-scroll-rail .top-streams-wrapper {
  margin: 0;
  padding-right: 42px;
  padding-left: 42px;
}

.top-streams-scroll-rail .horizontal-scroll-control--prev {
  top: 44%;
  left: 0;
}

.top-streams-scroll-rail .horizontal-scroll-control--next {
  top: 44%;
  right: 0;
}

@media (max-width: 760px) {
  .category-picker-control,
  .horizontal-scroll-control {
    width: 32px;
    height: 32px;
  }

  .category-picker-control--prev {
    left: 2px;
  }

  .category-picker-control--next {
    right: 2px;
  }

  .top-streams-scroll-rail .top-streams-wrapper {
    padding-right: 36px;
    padding-left: 36px;
  }
}

/* Keep the concurrent carousel controls available without adding controls to
 * the compact reference state. They reveal themselves when keyboard-focused. */
.top-streams-scroll-rail .top-streams-wrapper {
  margin: 0 -10px 0 -16px;
  padding: 0 10px;
}

.top-streams-scroll-rail .horizontal-scroll-control {
  opacity: 0;
  pointer-events: none;
}

.top-streams-scroll-rail .horizontal-scroll-control:focus-visible {
  opacity: 0.96;
  pointer-events: auto;
}

/* Match the discovery rail to the active daylight surface. The dark theme
 * keeps the compact neutral-black treatment defined above. */
body[data-theme="light"] .top-streams-container {
  color: var(--daylight-ink);
  background: var(--daylight-surface);
  border: 1px solid var(--daylight-border);
  border-radius: 9px;
  box-shadow: var(--daylight-shadow);
}

body[data-theme="light"] .top-streams-title {
  color: var(--daylight-ink-strong) !important;
  text-shadow: none;
}

body[data-theme="light"] .top-streams-heading .section-link {
  color: var(--daylight-muted);
}

body[data-theme="light"] .top-streams-heading .section-link:hover,
body[data-theme="light"] .top-streams-heading .section-link:focus-visible {
  color: var(--daylight-primary);
}

body[data-theme="light"] .top-stream {
  color: var(--daylight-ink);
}

body[data-theme="light"] .top-streams .top-stream-image-container {
  border-color: #c7d2e3;
  background: var(--daylight-surface-subtle);
  box-shadow: none;
}

body[data-theme="light"] .top-streams .top-stream-image-container:hover,
body[data-theme="light"]
  .top-streams .top-stream:hover .top-stream-image-container,
body[data-theme="light"] .top-streams .top-stream-image-container:focus {
  border-color: var(--daylight-online);
  box-shadow: 0 0 0 2px rgba(25, 183, 124, 0.16);
}

body[data-theme="light"] .top-streams .add-stream-btn {
  border-color: #ffffff;
  background: var(--daylight-online);
  color: #ffffff;
  box-shadow: 0 0 0 1px rgba(19, 46, 98, 0.18);
}

body[data-theme="light"] .top-streams .add-stream-btn:hover,
body[data-theme="light"] .top-streams .add-stream-btn:focus-visible {
  background: #13a96f;
}

body[data-theme="light"] .top-streams .top-stream-info h3 {
  color: var(--daylight-ink-strong) !important;
}

body[data-theme="light"] .top-streams .top-stream-info p {
  color: var(--daylight-muted) !important;
}

body[data-theme="light"] .top-streams-wrapper {
  scrollbar-color: #b9c5d6 #eef2f7;
}

body[data-theme="light"] .top-streams-wrapper::-webkit-scrollbar-track {
  background: #eef2f7;
}

body[data-theme="light"] .top-streams-wrapper::-webkit-scrollbar-thumb {
  background: #b9c5d6;
}

body[data-theme="light"] .top-streams-wrapper::-webkit-scrollbar-thumb:hover {
  background: #91a2bb;
}

.top-stream,
.top-stream-info {
  cursor: pointer;
}

/* Category discovery feedback: both carousel copies reflect the same queue
 * state so avatar clicks and green Add buttons visibly confirm their result. */
.top-streams .top-stream.is-adding .top-stream-image-container {
  border-color: #f1b94c;
  box-shadow: 0 0 0 3px rgba(241, 185, 76, 0.2);
}

.top-streams .top-stream.is-added .top-stream-image-container,
body[data-theme="light"]
  .top-streams
  .top-stream.is-added
  .top-stream-image-container {
  border-color: var(--daylight-online, #19b77c);
  box-shadow: 0 0 0 3px rgba(25, 183, 124, 0.2);
}

.top-streams .top-stream .add-stream-btn.is-adding,
.top-streams .top-stream .add-stream-btn.is-added,
body[data-theme="light"]
  .top-streams
  .top-stream
  .add-stream-btn.is-adding,
body[data-theme="light"]
  .top-streams
  .top-stream
  .add-stream-btn.is-added {
  cursor: default;
  opacity: 1;
  transform: none;
}

.top-streams .top-stream .add-stream-btn.is-adding,
body[data-theme="light"]
  .top-streams
  .top-stream
  .add-stream-btn.is-adding {
  background: #d79522;
}

.top-streams .top-stream .add-stream-btn.is-added,
body[data-theme="light"]
  .top-streams
  .top-stream
  .add-stream-btn.is-added {
  background: #138a61;
  font-size: 16px;
  font-weight: 700;
}

.top-streams .top-stream.is-exiting {
  pointer-events: none;
  transform-origin: center top;
  will-change: transform, opacity;
  animation: category-top-stream-slide-down-out 460ms
    cubic-bezier(0.4, 0, 0.8, 0.2) forwards;
}

.top-streams .top-stream.is-filtered {
  display: none;
}

@keyframes category-top-stream-slide-down-out {
  0% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
  70% {
    opacity: 0.12;
    transform: translate3d(0, 48px, 0) scale(0.94);
  }
  100% {
    opacity: 0;
    transform: translate3d(0, 64px, 0) scale(0.9);
  }
}

.artist.queue-stream-just-added {
  animation: queue-stream-added-pulse 1.2s ease-out;
}

@keyframes queue-stream-added-pulse {
  0% {
    opacity: 0.35;
    transform: translateY(20px);
    border-color: rgba(25, 183, 124, 0.9);
    box-shadow: 0 0 0 4px rgba(25, 183, 124, 0.22);
  }
  36% {
    opacity: 1;
    transform: translateY(0);
    border-color: rgba(25, 183, 124, 0.9);
    box-shadow: 0 0 0 4px rgba(25, 183, 124, 0.18);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    border-color: var(--daylight-border, rgba(255, 255, 255, 0.12));
    box-shadow: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .top-streams .top-stream.is-exiting {
    animation: none;
    opacity: 0;
  }

  .artist.queue-stream-just-added {
    animation: none;
  }
}

/* Category discovery search */
.category-search {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  min-width: 0;
  margin: -2px 1px 14px;
}

.section-heading--categories .category-search-control {
  flex: 0 1 286px;
}

.category-search-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.category-search-control {
  display: flex;
  align-items: center;
  width: min(100%, 286px);
  min-height: 36px;
  padding: 0 8px 0 12px;
  border: 1px solid var(--mono-border);
  border-radius: 8px;
  background: var(--mono-card);
  color: var(--mono-muted);
  transition: border-color 160ms ease, box-shadow 160ms ease,
    background 160ms ease;
}

.category-search-control:focus-within {
  border-color: var(--daylight-primary, #7d9cff);
  background: var(--mono-card-raised);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.category-search-control > i {
  flex: 0 0 auto;
  margin-right: 9px;
  font-size: 13px;
}

.category-search-control input {
  min-width: 0;
  flex: 1 1 auto;
  height: 34px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--mono-text);
  font: inherit;
  font-size: 13px;
}

.category-search-control input::placeholder {
  color: var(--mono-muted);
  opacity: 0.9;
}

.category-search-control input::-webkit-search-cancel-button {
  display: none;
}

.category-search-clear {
  display: inline-grid;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--mono-muted);
  cursor: pointer;
}

.category-search-clear:hover,
.category-search-clear:focus-visible {
  background: var(--daylight-surface-blue, rgba(255, 255, 255, 0.1));
  color: var(--mono-text);
  outline: none;
}

.category-search-clear[hidden] {
  display: none;
}

.category-search-status {
  flex: 0 1 auto;
  min-width: 0;
  margin: 0;
  color: var(--mono-muted);
  font-size: 12px;
  white-space: nowrap;
}

@media (max-width: 560px) {
  .section-heading--categories {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .section-heading--categories .category-search {
    flex: 1 1 100%;
    width: 100%;
  }

  .section-heading--categories .category-search-control {
    flex: 1 1 100%;
  }

  .category-search {
    align-items: stretch;
    flex-wrap: wrap;
    justify-content: stretch;
  }

  .category-search-control {
    width: 100%;
  }

  .category-search-status {
    width: 100%;
  }
}

/* Horizontal scrolling clips vertical overflow. Keep enough inset above the
   stream avatars for the add/check control to complete its hover scale. */
.top-streams-container .top-streams-wrapper {
  padding: 7px 10px 0;
}

/* Launch control refinement: keep the action and mode picker visually
   connected while allowing the menu to extend beyond the control. */
.launch-center {
  min-width: 300px;
  border-radius: 15px;
  box-shadow: 0 1px 2px rgba(31, 61, 113, 0.04);
}

.launch-center .launch-button,
.launch-center .launch-mode-toggle {
  height: 48px;
  transform: none !important;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    box-shadow 160ms ease;
}

.launch-center .launch-button,
.launch-center #launchWatchParty.launch-button {
  border-right: 0 !important;
  border-radius: 15px 0 0 15px;
}

.launch-center .launch-mode-toggle {
  border-left-color: #6f9bf1;
  border-radius: 0 15px 15px 0;
}

.launch-center:hover .launch-button,
.launch-center:hover .launch-mode-toggle,
.launch-center:focus-within .launch-button,
.launch-center:focus-within .launch-mode-toggle {
  background: var(--daylight-surface-blue) !important;
  border-color: var(--daylight-primary) !important;
  color: var(--daylight-primary-hover) !important;
}

.launch-center .launch-button:focus-visible,
.launch-center .launch-mode-toggle:focus-visible {
  outline: none;
}

.launch-center:focus-within {
  z-index: 1000;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

body[data-theme="dark"] .launch-center {
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .launch-center .launch-mode-toggle {
  border-left-color: #5a5a5a;
}

body[data-theme="dark"] .launch-center:hover .launch-button,
body[data-theme="dark"] .launch-center:hover .launch-mode-toggle,
body[data-theme="dark"] .launch-center:focus-within .launch-button,
body[data-theme="dark"] .launch-center:focus-within .launch-mode-toggle {
  background: var(--daylight-surface-subtle) !important;
  border-color: #858585 !important;
  color: #ffffff !important;
}

body[data-theme="dark"] .launch-center:focus-within {
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.07);
}

@media (max-width: 760px) {
  .launch-center {
    min-width: 0;
  }
}

.queue-reorder-status {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  border: 0;
  white-space: nowrap;
}

#initialStreams.queue-stream-reordering,
#backupStreams.queue-stream-reordering {
  cursor: grabbing;
}

.queue-stream-handle {
  touch-action: none;
  user-select: none;
}

#initialStreams.queue-stream-reordering > .artist:not(.queue-stream-dragging),
#backupStreams.queue-stream-reordering > .backup-stream:not(.queue-stream-dragging) {
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.artist.queue-stream-dragging,
.backup-stream.queue-stream-dragging {
  z-index: 12;
  opacity: 0.72 !important;
  border-color: #6f9bf1 !important;
  background: var(--daylight-surface-blue) !important;
  box-shadow: 0 16px 34px rgba(31, 61, 113, 0.22) !important;
  cursor: grabbing;
  transform: scale(1.025) rotate(0.35deg) !important;
}

.artist.queue-stream-dragging::after,
.backup-stream.queue-stream-dragging::after {
  content: "Moving";
  position: absolute;
  top: 6px;
  right: 6px;
  padding: 3px 7px;
  border-radius: 999px;
  background: var(--daylight-primary);
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.03em;
  line-height: 1.2;
  text-transform: uppercase;
}

.artist.queue-stream-dragging-pointer,
.backup-stream.queue-stream-dragging-pointer {
  display: none !important;
}

.queue-stream-dragging .queue-stream-actions {
  display: none !important;
}

#initialStreams.queue-stream-reordering .queue-stream-actions,
#backupStreams.queue-stream-reordering .queue-stream-actions {
  display: none !important;
}

.queue-stream-drag-preview {
  position: fixed !important;
  z-index: 1000 !important;
  display: flex !important;
  box-sizing: border-box;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 3px;
  margin: 0 !important;
  opacity: 0.96 !important;
  overflow: visible !important;
  padding: 6px;
  border: 1px solid #6f9bf1 !important;
  border-color: #6f9bf1 !important;
  border-radius: 18px !important;
  background: var(--daylight-surface) !important;
  box-shadow: 0 20px 44px rgba(31, 61, 113, 0.3) !important;
  pointer-events: none !important;
  transform: scale(1.035) rotate(0.5deg) !important;
}

.queue-stream-drag-preview-avatar {
  flex: 0 0 auto !important;
  width: 56px !important;
  height: 56px !important;
  margin: 0 !important;
  border: 2px solid rgba(255, 255, 255, 0.78) !important;
  border-radius: 50% !important;
  box-shadow:
    0 0 0 2px rgba(111, 155, 241, 0.3),
    0 8px 16px rgba(31, 61, 113, 0.28) !important;
}

.queue-stream-drag-preview-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.queue-stream-drag-preview-name {
  display: block;
  max-width: 72px;
  overflow: hidden;
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-stream-drag-image {
  position: fixed;
  top: -1000px;
  left: -1000px;
  z-index: -1;
  display: grid;
  width: 64px;
  height: 64px;
  box-sizing: border-box;
  place-items: center;
  padding: 3px;
  border: 1px solid rgba(111, 155, 241, 0.9);
  border-radius: 50%;
  background: #24292f;
  box-shadow: 0 8px 18px rgba(31, 61, 113, 0.3);
  pointer-events: none;
}

.queue-stream-drag-image .queue-stream-drag-preview-avatar {
  width: 56px !important;
  height: 56px !important;
}

.queue-stream-drag-preview.queue-stream-drag-preview-grouping {
  opacity: 0.56 !important;
  border-color: #46b7ec !important;
  box-shadow:
    0 0 0 3px rgba(70, 183, 236, 0.16),
    0 20px 44px rgba(31, 104, 137, 0.28) !important;
  transform: scale(0.92) rotate(0.5deg) !important;
}

.queue-stream-drag-preview.queue-stream-drag-preview-pair {
  width: 178px !important;
  height: 118px !important;
  box-sizing: border-box;
  gap: 0;
  padding: 12px 10px 10px;
  border-color: #e0b65c !important;
  border-radius: 20px !important;
  background:
    linear-gradient(135deg, rgba(224, 182, 92, 0.18), transparent 68%),
    var(--daylight-surface) !important;
  box-shadow:
    0 0 0 3px rgba(224, 182, 92, 0.16),
    0 18px 36px rgba(124, 88, 25, 0.3) !important;
  opacity: 0.98 !important;
  transform: scale(0.96) rotate(0.35deg) !important;
}

.queue-stream-drag-preview-pair-avatars {
  display: flex;
  width: 100%;
  height: 94px;
  align-items: flex-start;
  justify-content: center;
}

.queue-stream-drag-preview-pair-item {
  position: relative;
  display: flex;
  flex: 0 0 78px;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}

.queue-stream-drag-preview-pair-item-source {
  z-index: 2;
  transform: translateX(-12px);
}

.queue-stream-drag-preview-pair-item-target {
  z-index: 1;
  transform: translateX(12px);
}

.queue-stream-drag-preview-pair .queue-stream-drag-preview-avatar {
  width: 58px !important;
  height: 58px !important;
  border-width: 2px !important;
}

.queue-stream-drag-preview-pair-item-source .queue-stream-drag-preview-avatar {
  border-color: #69d1ff !important;
  box-shadow:
    0 0 0 2px rgba(105, 209, 255, 0.28),
    0 7px 15px rgba(31, 104, 137, 0.3) !important;
}

.queue-stream-drag-preview-pair-item-target .queue-stream-drag-preview-avatar {
  border-color: #f2ca70 !important;
  box-shadow:
    0 0 0 2px rgba(242, 202, 112, 0.28),
    0 7px 15px rgba(124, 88, 25, 0.3) !important;
}

.queue-stream-drag-preview-pair-label {
  display: block;
  max-width: 76px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.92);
  font-size: 10px;
  font-weight: 850;
  line-height: 1.1;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-stream-drag-preview .queue-stream-actions {
  display: none !important;
}

.queue-stream-drag-preview::after {
  content: "Moving";
  position: absolute;
  top: 6px;
  right: 6px;
  padding: 3px 7px;
  border-radius: 999px;
  background: var(--daylight-primary);
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.03em;
  line-height: 1.2;
  text-transform: uppercase;
}

.queue-stream-drag-preview.queue-stream-drag-preview-grouping::after {
  content: attr(data-queue-group-source-label);
  background: #2b8eb9;
  color: #ffffff;
  letter-spacing: 0.04em;
}

.queue-stream-drag-preview.queue-stream-drag-preview-pair::after {
  content: attr(data-queue-group-action-label);
  top: -14px;
  right: 50%;
  left: auto;
  padding: 3px 8px;
  transform: translateX(50%);
  background: #b4872e;
  color: #ffffff;
  white-space: nowrap;
}

.queue-stream-drag-preview.queue-stream-drag-preview-pair.queue-stream-drag-preview-limit {
  border-color: #df6670 !important;
  background:
    linear-gradient(135deg, rgba(199, 66, 78, 0.22), transparent 68%),
    var(--daylight-surface) !important;
  box-shadow:
    0 0 0 3px rgba(223, 102, 112, 0.2),
    0 18px 36px rgba(116, 28, 37, 0.34) !important;
}

.queue-stream-drag-preview.queue-stream-drag-preview-pair.queue-stream-drag-preview-limit::after {
  background: #9d303a;
  color: #fff4f5;
}

.queue-stream-drop-placeholder {
  position: relative;
  display: flex;
  min-width: 0;
  height: 74px;
  box-sizing: border-box;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 2px dashed var(--daylight-primary);
  border-radius: 10px;
  background: rgba(37, 99, 235, 0.08);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.06);
  color: var(--daylight-primary);
  font-size: 13px;
  font-weight: 750;
  pointer-events: auto;
  user-select: none;
  animation: queue-drop-target-enter 140ms ease-out both;
}

.queue-stream-drop-placeholder i {
  font-size: 14px;
}

.artist.queue-stream-drop-target,
.backup-stream.queue-stream-drop-target {
  border-color: #6f9bf1 !important;
  background: var(--daylight-surface-blue) !important;
}

.artist.queue-stream-group-source {
  z-index: 1002 !important;
  opacity: 0.98 !important;
  border: 2px solid #46b7ec !important;
  background:
    linear-gradient(135deg, rgba(70, 183, 236, 0.17), transparent 62%),
    var(--daylight-surface-blue) !important;
  box-shadow:
    0 0 0 3px rgba(70, 183, 236, 0.2),
    0 12px 28px rgba(31, 104, 137, 0.26) !important;
  transform: translateY(-2px) scale(1.015) !important;
}

.artist.queue-stream-group-source::before {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 6;
  padding: 3px 7px;
  border: 1px solid rgba(70, 183, 236, 0.78);
  border-radius: 999px;
  background: rgba(24, 83, 111, 0.94);
  color: #ffffff;
  content: "SOURCE";
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 1.1;
  pointer-events: none;
}

.artist.queue-stream-group-source::after {
  position: absolute;
  right: 12px;
  bottom: 10px;
  left: 12px;
  z-index: 6;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.92);
  content: attr(data-queue-group-source-label);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.2;
  pointer-events: none;
  text-align: center;
  text-overflow: ellipsis;
  text-transform: none;
  white-space: nowrap;
}

.artist.queue-stream-group-target {
  z-index: 1001 !important;
  border: 2px solid #e0b65c !important;
  background:
    repeating-linear-gradient(
      135deg,
      rgba(224, 182, 92, 0.2) 0,
      rgba(224, 182, 92, 0.2) 10px,
      rgba(224, 182, 92, 0.08) 10px,
      rgba(224, 182, 92, 0.08) 20px
    ) !important;
  box-shadow:
    inset 0 0 0 1px rgba(224, 182, 92, 0.36),
    0 10px 24px rgba(124, 88, 25, 0.28) !important;
}

.artist.queue-stream-group-target::before {
  content: attr(data-queue-group-label);
  position: absolute;
  inset: 7px;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(224, 182, 92, 0.76);
  border-radius: 9px;
  background: rgba(72, 52, 17, 0.93);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.07em;
  overflow: hidden;
  pointer-events: none;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.artist.queue-stream-group-target::after {
  content: attr(data-queue-group-hint);
  position: absolute;
  right: 14px;
  bottom: 12px;
  left: 14px;
  z-index: 5;
  color: rgba(255, 255, 255, 0.9);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1.2;
  overflow: hidden;
  pointer-events: none;
  text-align: center;
  text-overflow: ellipsis;
  text-transform: none;
  white-space: nowrap;
}

.artist.queue-stream-group-target.queue-stream-group-limit-target {
  border-color: #df6670 !important;
  background:
    repeating-linear-gradient(
      135deg,
      rgba(199, 66, 78, 0.24) 0,
      rgba(199, 66, 78, 0.24) 10px,
      rgba(199, 66, 78, 0.09) 10px,
      rgba(199, 66, 78, 0.09) 20px
    ) !important;
  box-shadow:
    inset 0 0 0 1px rgba(223, 102, 112, 0.42),
    0 10px 24px rgba(116, 28, 37, 0.3) !important;
}

.artist.queue-stream-group-target.queue-stream-group-limit-target::before {
  border-color: rgba(243, 132, 141, 0.9);
  background: rgba(104, 29, 37, 0.96);
  color: #fff4f5;
}

.artist.queue-stream-group-target.queue-stream-group-limit-target::after {
  color: rgba(255, 232, 235, 0.95);
}

.queue-stream-group-target-pair {
  position: absolute;
  inset: 25px 7px 20px;
  z-index: 7;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.queue-stream-group-target-pair
  .queue-stream-drag-preview-pair-avatars {
  width: 136px;
  height: 78px;
  transform: scale(0.82);
  transform-origin: center;
}

.queue-stream-group-target-pair .queue-stream-drag-preview-pair-item {
  flex-basis: 64px;
}

.queue-stream-group-target-pair .queue-stream-drag-preview-avatar {
  width: 48px !important;
  height: 48px !important;
}

.queue-stream-group-target-pair .queue-stream-drag-preview-pair-label {
  max-width: 60px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 8px;
}

.artist.queue-stream-drop-before,
.backup-stream.queue-stream-drop-before {
  box-shadow: inset 4px 0 0 var(--daylight-primary), var(--daylight-shadow) !important;
}

.artist.queue-stream-drop-after,
.backup-stream.queue-stream-drop-after {
  box-shadow: inset -4px 0 0 var(--daylight-primary), var(--daylight-shadow) !important;
}

.artist.queue-stream-reordered,
.backup-stream.queue-stream-reordered {
  animation: queue-reorder-settle 650ms ease-out;
}

@keyframes queue-drop-target-enter {
  from {
    opacity: 0.55;
  }
  to {
    opacity: 1;
  }
}

@keyframes queue-reorder-settle {
  0% {
    transform: scale(0.975);
  }
  45% {
    border-color: #6f9bf1;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.14);
    transform: scale(1.012);
  }
  100% {
    transform: scale(1);
  }
}

body[data-theme="dark"] .artist.queue-stream-dragging,
body[data-theme="dark"] .backup-stream.queue-stream-dragging {
  border-color: #858585 !important;
  background: #282828 !important;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.42) !important;
}

body[data-theme="dark"] .queue-stream-drag-preview {
  border-color: #858585 !important;
  background: #282828 !important;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.5) !important;
}

body[data-theme="dark"] .queue-stream-drag-preview::after {
  background: #eeeeee;
  color: #171717;
}

body[data-theme="dark"] .queue-stream-drag-preview.queue-stream-drag-preview-grouping {
  border-color: #69d1ff !important;
  box-shadow:
    0 0 0 3px rgba(105, 209, 255, 0.18),
    0 20px 44px rgba(0, 0, 0, 0.5) !important;
}

body[data-theme="dark"]
  .queue-stream-drag-preview.queue-stream-drag-preview-grouping::after {
  background: #1d789f;
  color: #ffffff;
}

body[data-theme="dark"] .queue-stream-drag-preview.queue-stream-drag-preview-pair {
  border-color: #f2ca70 !important;
  background:
    linear-gradient(135deg, rgba(242, 202, 112, 0.16), transparent 68%),
    #282828 !important;
  box-shadow:
    0 0 0 3px rgba(242, 202, 112, 0.18),
    0 18px 36px rgba(0, 0, 0, 0.54) !important;
}

body[data-theme="dark"]
  .queue-stream-drag-preview.queue-stream-drag-preview-pair::after {
  background: #b4872e;
  color: #fff9e9;
}

body[data-theme="dark"]
  .queue-stream-drag-preview.queue-stream-drag-preview-pair.queue-stream-drag-preview-limit {
  border-color: #f07883 !important;
  background:
    linear-gradient(135deg, rgba(240, 120, 131, 0.2), transparent 68%),
    #282828 !important;
  box-shadow:
    0 0 0 3px rgba(240, 120, 131, 0.2),
    0 18px 36px rgba(0, 0, 0, 0.54) !important;
}

body[data-theme="dark"]
  .queue-stream-drag-preview.queue-stream-drag-preview-pair.queue-stream-drag-preview-limit::after {
  background: #a93440;
  color: #fff5f6;
}

body[data-theme="dark"] .artist.queue-stream-dragging::after,
body[data-theme="dark"] .backup-stream.queue-stream-dragging::after {
  background: #eeeeee;
  color: #171717;
}

body[data-theme="dark"] .queue-stream-drop-placeholder {
  border-color: #858585;
  background: #282828;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  color: #f1f1f1;
}

body[data-theme="dark"] .artist.queue-stream-drop-target,
body[data-theme="dark"] .backup-stream.queue-stream-drop-target {
  border-color: #858585 !important;
  background: #282828 !important;
}

body[data-theme="dark"] .artist.queue-stream-group-source {
  border-color: #69d1ff !important;
  background:
    linear-gradient(135deg, rgba(105, 209, 255, 0.16), transparent 62%),
    #282828 !important;
  box-shadow:
    0 0 0 3px rgba(105, 209, 255, 0.2),
    0 12px 28px rgba(0, 0, 0, 0.42) !important;
}

body[data-theme="dark"] .artist.queue-stream-group-source::before {
  border-color: rgba(105, 209, 255, 0.82);
  background: rgba(22, 91, 121, 0.96);
  color: #f5fcff;
}

body[data-theme="dark"] .artist.queue-stream-group-source::after {
  color: rgba(245, 252, 255, 0.94);
}

body[data-theme="dark"] .artist.queue-stream-group-target {
  z-index: 1001 !important;
  border-color: #f2ca70 !important;
  background:
    repeating-linear-gradient(
      135deg,
      rgba(242, 202, 112, 0.24) 0,
      rgba(242, 202, 112, 0.24) 10px,
      rgba(242, 202, 112, 0.1) 10px,
      rgba(242, 202, 112, 0.1) 20px
    ) !important;
  box-shadow:
    inset 0 0 0 1px rgba(242, 202, 112, 0.46),
    0 10px 24px rgba(0, 0, 0, 0.48) !important;
}

body[data-theme="dark"] .artist.queue-stream-group-target::before {
  border-color: rgba(242, 202, 112, 0.88);
  background: rgba(74, 53, 17, 0.94);
  color: #fff9e9;
}

body[data-theme="dark"] .artist.queue-stream-group-target::after {
  color: rgba(255, 249, 233, 0.92);
}

body[data-theme="dark"]
  .artist.queue-stream-group-target.queue-stream-group-limit-target {
  border-color: #f07883 !important;
  background:
    repeating-linear-gradient(
      135deg,
      rgba(240, 120, 131, 0.25) 0,
      rgba(240, 120, 131, 0.25) 10px,
      rgba(240, 120, 131, 0.1) 10px,
      rgba(240, 120, 131, 0.1) 20px
    ) !important;
  box-shadow:
    inset 0 0 0 1px rgba(240, 120, 131, 0.48),
    0 10px 24px rgba(0, 0, 0, 0.48) !important;
}

body[data-theme="dark"]
  .artist.queue-stream-group-target.queue-stream-group-limit-target::before {
  border-color: rgba(255, 160, 169, 0.92);
  background: rgba(105, 30, 39, 0.97);
  color: #fff5f6;
}

body[data-theme="dark"]
  .artist.queue-stream-group-target.queue-stream-group-limit-target::after {
  color: rgba(255, 232, 235, 0.95);
}

body[data-theme="dark"] .artist.queue-stream-drop-before,
body[data-theme="dark"] .backup-stream.queue-stream-drop-before {
  box-shadow: inset 4px 0 0 #cfcfcf, 0 5px 12px rgba(0, 0, 0, 0.18) !important;
}

body[data-theme="dark"] .artist.queue-stream-drop-after,
body[data-theme="dark"] .backup-stream.queue-stream-drop-after {
  box-shadow: inset -4px 0 0 #cfcfcf, 0 5px 12px rgba(0, 0, 0, 0.18) !important;
}

@media (max-width: 760px) {
  .artist.queue-stream-drop-before,
  .backup-stream.queue-stream-drop-before {
    box-shadow: inset 0 4px 0 var(--daylight-primary), var(--daylight-shadow) !important;
  }

  .artist.queue-stream-drop-after,
  .backup-stream.queue-stream-drop-after {
    box-shadow: inset 0 -4px 0 var(--daylight-primary), var(--daylight-shadow) !important;
  }

  body[data-theme="dark"] .artist.queue-stream-drop-before,
  body[data-theme="dark"] .backup-stream.queue-stream-drop-before {
    box-shadow: inset 0 4px 0 #cfcfcf, 0 5px 12px rgba(0, 0, 0, 0.18) !important;
  }

  body[data-theme="dark"] .artist.queue-stream-drop-after,
  body[data-theme="dark"] .backup-stream.queue-stream-drop-after {
    box-shadow: inset 0 -4px 0 #cfcfcf, 0 5px 12px rgba(0, 0, 0, 0.18) !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .queue-stream-drop-placeholder,
  .artist.queue-stream-reordered,
  .backup-stream.queue-stream-reordered {
    animation: none;
  }
}

/* Streamer discovery: keep the add flow close to the queue and make results
   useful before a channel has to be typed perfectly. */

#queueBuilder.streamer-search-panel {
  display: grid;
  gap: 13px;
  margin: 4px 0 20px;
  padding: 16px;
  border: 1px solid var(--daylight-border);
  border-radius: 12px;
  background: var(--daylight-surface);
  box-shadow: var(--daylight-shadow);
}

.streamer-search-heading {
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.streamer-search-heading-icon {
  display: inline-grid;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--daylight-border);
  border-radius: 9px;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
  font-size: 14px;
}

.streamer-search-heading h3 {
  margin: 0;
  color: var(--daylight-ink-strong);
  font-size: 15px;
  line-height: 1.3;
}

.streamer-search-heading p {
  margin: 3px 0 0;
  color: var(--daylight-muted);
  font-size: 12px;
  line-height: 1.4;
}

.streamer-search-control {
  position: relative;
  display: flex;
  align-items: center;
}

.streamer-search-control > .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.streamer-search-control > i {
  position: absolute;
  left: 14px;
  z-index: 1;
  color: var(--daylight-muted);
  font-size: 13px;
  pointer-events: none;
}

.streamer-search-control input {
  width: 100%;
  height: 44px;
  padding: 0 42px 0 38px;
  border: 1px solid var(--daylight-border);
  border-radius: 9px;
  outline: 0;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-ink);
  font: inherit;
  font-size: 13px;
  transition: border-color 160ms ease, box-shadow 160ms ease,
    background 160ms ease;
}

.streamer-search-control input::placeholder {
  color: var(--daylight-dim);
}

.streamer-search-control input:focus {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--daylight-primary) 18%, transparent);
}

.streamer-search-clear {
  position: absolute;
  right: 8px;
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--daylight-muted);
  cursor: pointer;
}

.streamer-search-clear:hover,
.streamer-search-clear:focus-visible {
  background: var(--daylight-surface-blue);
  color: var(--daylight-ink);
}

.streamer-search-clear[hidden] {
  display: none;
}

.streamer-search-status {
  min-height: 17px;
  margin: -2px 0 0;
  color: var(--daylight-muted);
  font-size: 12px;
}

.streamer-search-results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.streamer-search-results:empty {
  display: none;
}

.streamer-search-loading {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  color: var(--daylight-muted);
  font-size: 12px;
}

.streamer-search-result {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
  padding: 9px;
  border: 1px solid var(--daylight-border);
  border-radius: 9px;
  background: var(--daylight-surface-subtle);
  transition: border-color 160ms ease, background 160ms ease,
    transform 160ms ease;
}

.streamer-search-result:hover {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  transform: translateY(-1px);
}

.streamer-search-result.is-added {
  border-color: var(--daylight-online);
}

.streamer-search-result-avatar {
  display: grid;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  overflow: hidden;
  place-items: center;
  border: 1px solid var(--daylight-border);
  border-radius: 50%;
  background: var(--daylight-surface-blue);
  color: var(--daylight-muted);
}

.streamer-search-result-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.streamer-search-result-copy {
  min-width: 0;
  flex: 1 1 auto;
}

.streamer-search-result-name {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 5px;
  line-height: 1.2;
}

.streamer-search-result-name strong,
.streamer-search-result-name > span:not(.streamer-search-live-badge) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.streamer-search-result-name strong {
  color: var(--daylight-ink-strong);
  font-size: 13px;
}

.streamer-search-result-name > span:not(.streamer-search-live-badge) {
  color: var(--daylight-muted);
  font-size: 11px;
}

.streamer-search-live-badge {
  flex: 0 0 auto;
  padding: 2px 5px;
  border-radius: 4px;
  background: var(--daylight-online);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.streamer-search-result-category,
.streamer-search-result-title {
  overflow: hidden;
  margin: 3px 0 0;
  color: var(--daylight-muted);
  font-size: 11px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.streamer-search-result-title {
  color: var(--daylight-dim);
}

.streamer-search-result-add {
  flex: 0 0 auto;
  min-width: 52px;
  height: 30px;
  padding: 0 9px;
  border: 1px solid var(--daylight-border);
  border-radius: 7px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.streamer-search-result-add:hover,
.streamer-search-result-add:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-primary);
  color: #fff;
}

.streamer-search-result-add.is-added,
.streamer-search-result-add:disabled {
  border-color: var(--daylight-online);
  background: color-mix(in srgb, var(--daylight-online) 13%, transparent);
  color: var(--daylight-online);
  cursor: default;
}

.queue-group-heading {
  justify-content: space-between;
  gap: 12px;
}

.queue-group-heading > div {
  min-width: 0;
}

.queue-group-heading #clearInitialStreams {
  flex: 0 0 auto;
  min-height: 34px;
  margin: 0 0 0 auto;
  padding: 0 12px;
  border-radius: 6px;
  font-size: 12px;
}

.queue-group-heading #clearBackupStreams {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  margin: 0 0 0 auto;
  padding: 0;
  border-radius: 6px;
}

.queue-group-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-left: auto;
}

.queue-group-actions .queue-group-action {
  margin: 0 !important;
}

@media (max-width: 760px) {
  .streamer-search-results {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  #queueBuilder.streamer-search-panel {
    padding: 13px;
  }

}

/* Match streamer discovery to the compact category search treatment. */

#queueBuilder.streamer-search-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  min-width: 0;
  margin: -2px 1px 14px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.streamer-search-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.streamer-search-control {
  position: static;
  display: flex;
  align-items: center;
  width: min(100%, 286px);
  min-height: 36px;
  padding: 0 8px 0 12px;
  border: 1px solid var(--mono-border);
  border-radius: 8px;
  background: var(--mono-card);
  color: var(--mono-muted);
  transition: border-color 160ms ease, box-shadow 160ms ease,
    background 160ms ease;
}

.streamer-search-control:focus-within {
  border-color: var(--daylight-primary, #7d9cff);
  background: var(--mono-card-raised);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.streamer-search-control > i {
  position: static;
  flex: 0 0 auto;
  margin-right: 9px;
  font-size: 13px;
  pointer-events: auto;
}

.streamer-search-control input {
  min-width: 0;
  flex: 1 1 auto;
  width: auto;
  height: 34px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--mono-text);
  font: inherit;
  font-size: 13px;
  box-shadow: none;
}

/* The legacy queue input rules target #streamSearch directly, so they outrank
   the shared class styles above. Reset those properties at the component
   boundary to keep this control visually identical to category search. */
.streamer-search-control #streamSearch {
  min-width: 0;
  flex: 1 1 auto;
  width: auto;
  height: 34px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  outline: 0;
  background: transparent;
  color: var(--mono-text);
  font: inherit;
  font-size: 13px;
  box-shadow: none;
}

.streamer-search-control #streamSearch:focus {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.streamer-search-control input::placeholder {
  color: var(--mono-muted);
  opacity: 0.9;
}

.streamer-search-control #streamSearch::placeholder {
  color: var(--mono-muted);
  opacity: 0.9;
}

.streamer-search-control input::-webkit-search-cancel-button {
  display: none;
}

.streamer-search-clear {
  position: static;
  display: inline-grid;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--mono-muted);
  cursor: pointer;
}

.streamer-search-clear:hover,
.streamer-search-clear:focus-visible {
  background: var(--daylight-surface-blue, rgba(255, 255, 255, 0.1));
  color: var(--mono-text);
  outline: none;
}

.streamer-search-clear[hidden] {
  display: none;
}

.streamer-search-status {
  flex: 0 1 auto;
  min-width: 0;
  min-height: 0;
  margin: 0;
  color: var(--mono-muted);
  font-size: 12px;
  white-space: nowrap;
}

.streamer-search-status:empty {
  display: none;
}

.streamer-search-results {
  flex: 0 0 100%;
  width: 100%;
}

@media (max-width: 560px) {
  #queueBuilder.streamer-search-panel {
    align-items: stretch;
    justify-content: stretch;
  }

  .streamer-search-control {
    width: 100%;
  }

  .streamer-search-status {
    width: 100%;
  }
}

/* -------------------------------------------------------------------------- */
/* PCL Season 3 Lobby 1 preset                                               */
/* -------------------------------------------------------------------------- */

.live48-preset-card {
  border-color: #8fcfb3;
  background: #f6fffa;
  box-shadow: 0 3px 10px rgba(28, 123, 79, 0.08);
}

.live48-preset-card:hover,
.live48-preset-card:focus-within {
  border-color: #2b9b67;
  background: #effcf5;
  box-shadow: 0 5px 15px rgba(28, 123, 79, 0.14);
}

.live48-preset-icon.group-icon {
  border-color: #9ed8ba;
  background: #e3f7eb;
  color: #1d8254;
}

.live48-preset-card .pcl-preset-card-badges span {
  border-color: #b7dfc7;
  color: #1d8254;
}

.live48-preset-card .pcl-preset-card-action,
.live48-preset-footer .primary-button {
  border-color: #27875b;
  background: #27875b;
}

.live48-preset-card .pcl-preset-card-action {
  gap: 6px;
}

.live48-preset-card .pcl-preset-card-action i {
  font-size: 10px;
}

.live48-preset-content {
  display: grid;
  align-content: start;
  gap: 20px;
  min-height: 0;
  flex: 1 1 auto;
  padding: 30px 28px;
  overflow: auto;
  background: #f8fbfa;
}

.live48-preset-callout {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: start;
  gap: 16px;
  padding: 20px;
  border: 1px solid #b9e3c9;
  border-radius: 12px;
  background: #ffffff;
}

.live48-preset-callout-icon {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border-radius: 12px;
  background: #e3f7eb;
  color: #1d8254;
  font-size: 22px;
}

.live48-preset-callout h3 {
  margin: 0;
  color: #182d22;
  font-size: 19px;
}

.live48-preset-callout p {
  max-width: 760px;
  margin: 6px 0 0;
  color: #52665a;
  font-size: 15px;
  line-height: 1.55;
}

.live48-preset-status {
  margin: 0;
  padding: 14px 16px;
  border: 1px solid #d8e5dd;
  border-radius: 9px;
  background: #ffffff;
  color: #53655a;
  font-size: 14px;
  line-height: 1.4;
}

.live48-preset-status[data-state="loading"] {
  border-color: #b8d5e7;
  background: #f3f9fd;
  color: #28607e;
}

.live48-preset-status[data-state="success"] {
  border-color: #a9d9bc;
  background: #f0fbf4;
  color: #197044;
}

.live48-preset-status[data-state="error"] {
  border-color: #ecc1bc;
  background: #fff6f5;
  color: #a33128;
}

body[data-theme="dark"] .live48-preset-card {
  border-color: #3d775a;
  background: #111d17;
  box-shadow: none;
}

body[data-theme="dark"] .live48-preset-card:hover,
body[data-theme="dark"] .live48-preset-card:focus-within {
  border-color: #5cae7c;
  background: #15251b;
}

body[data-theme="dark"] .live48-preset-icon.group-icon {
  border-color: #3c7959;
  background: #1b3827;
  color: #8ee0aa;
}

body[data-theme="dark"] .live48-preset-card .pcl-preset-card-badges span {
  border-color: #356447;
  color: #91dca9;
}

body[data-theme="dark"] .live48-preset-card .pcl-preset-card-action,
body[data-theme="dark"] .live48-preset-footer .primary-button {
  border-color: #36845a;
  background: #2f754f;
}

body[data-theme="dark"] .live48-preset-content {
  background: #101613;
}

body[data-theme="dark"] .live48-preset-callout {
  border-color: #31583f;
  background: #171f1a;
}

body[data-theme="dark"] .live48-preset-callout-icon {
  background: #1b3827;
  color: #8ee0aa;
}

body[data-theme="dark"] .live48-preset-callout h3 {
  color: #e3f5e8;
}

body[data-theme="dark"] .live48-preset-callout p,
body[data-theme="dark"] .live48-preset-status {
  color: #a8bdb0;
}

body[data-theme="dark"] .live48-preset-status {
  border-color: #35493c;
  background: #171f1a;
}

body[data-theme="dark"] .live48-preset-status[data-state="loading"] {
  border-color: #31566c;
  background: #15232b;
  color: #9bc9e1;
}

body[data-theme="dark"] .live48-preset-status[data-state="success"] {
  border-color: #356b49;
  background: #142a1c;
  color: #9bd7ad;
}

body[data-theme="dark"] .live48-preset-status[data-state="error"] {
  border-color: #6c3d38;
  background: #2b1918;
  color: #f0aaa3;
}

.pcl-preset-card {
  position: relative;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #b9a2ef;
  border-radius: 8px;
  background: #fbf9ff;
  box-shadow: 0 3px 10px rgba(73, 42, 130, 0.08);
}

.pcl-preset-open-hitbox {
  display: grid;
  grid-template-columns: 49px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 84px;
  padding: 10px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.pcl-preset-card:hover,
.pcl-preset-card:focus-within {
  border-color: #805ad5;
  background: #f7f3ff;
  box-shadow: 0 5px 15px rgba(73, 42, 130, 0.13);
}

.pcl-preset-open-hitbox:focus-visible {
  outline: 3px solid rgba(128, 90, 213, 0.28);
  outline-offset: -3px;
}

.pcl-preset-icon.group-icon {
  border-color: #c7b5ef;
  background: #eee8fb;
  color: #6f42c1;
}

.pcl-preset-card-title {
  display: block;
  overflow: hidden;
  color: var(--daylight-ink-strong, #162033);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pcl-preset-card-summary {
  display: block;
  margin-top: 3px;
  color: var(--daylight-muted, #657087);
  font-size: 11px;
  line-height: 1.25;
}

.pcl-preset-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
}

.pcl-preset-card-badges span {
  padding: 2px 5px;
  border: 1px solid #d8cdf0;
  border-radius: 4px;
  color: #6f42a8;
  font-size: 9px;
  font-weight: 650;
  line-height: 1;
}

.pcl-preset-card-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid #7d56c2;
  border-radius: 7px;
  background: #7650b8;
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
}

.pcl-preset-dialog {
  width: calc(100vw - 24px);
  height: calc(100vh - 24px);
  height: calc(100dvh - 24px);
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: var(--daylight-ink, #263249);
  box-shadow: 0 28px 80px rgba(12, 17, 28, 0.32);
}

.pcl-preset-dialog::backdrop {
  background: rgba(11, 16, 25, 0.72);
  backdrop-filter: blur(4px);
}

.pcl-preset-shell {
  display: flex;
  width: 100%;
  height: 100%;
  min-height: 0;
  max-height: none;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #cbd5e6;
  border-radius: 16px;
  background: #f5f7fb;
}

.pcl-preset-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px;
  padding: 24px 28px 20px;
  border-bottom: 1px solid #dce3ee;
  background: #ffffff;
}

.pcl-preset-heading {
  min-width: 0;
  flex: 1 1 auto;
}

.pcl-preset-kicker {
  display: block;
  margin-bottom: 7px;
  color: #7650b8;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.pcl-preset-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.pcl-preset-title-row h2 {
  margin: 0;
  color: #141b2b;
  font-size: clamp(30px, 3vw, 42px);
  line-height: 1.12;
}

.pcl-preset-header-totals {
  display: grid;
  min-width: 250px;
  flex: 0 0 auto;
  align-self: center;
  gap: 6px;
  margin-left: auto;
}

.pcl-preset-totals-label {
  color: #778399;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-align: right;
  text-transform: uppercase;
}

.pcl-preset-totals-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.pcl-preset-total {
  display: flex;
  min-width: 116px;
  align-items: baseline;
  justify-content: flex-end;
  gap: 7px;
  padding: 9px 12px;
  border: 1px solid #d7e0eb;
  border-radius: 9px;
  background: #f8fafc;
  color: #68758a;
}

.pcl-preset-total strong {
  color: #1a2436;
  font-size: 28px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.pcl-preset-total small {
  font-size: 12px;
  font-weight: 750;
}

.pcl-preset-mode {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #b8e3cb;
  border-radius: 5px;
  background: #edf9f2;
  color: #187247;
  font-size: 13px;
  font-weight: 750;
}

.pcl-preset-mode.is-editing {
  border-color: #d4c1f6;
  background: #f3edff;
  color: #6f42a8;
}

.pcl-preset-close {
  display: grid;
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  place-items: center;
  padding: 0;
  border: 1px solid #d5ddea;
  border-radius: 10px;
  background: #f8fafc;
  color: #566176;
  font-size: 20px;
  cursor: pointer;
}

.pcl-preset-close:hover,
.pcl-preset-close:focus-visible {
  border-color: #9eabc0;
  background: #eef2f7;
  color: #172033;
}

.pcl-preset-scroll-controls {
  display: grid;
  min-height: 0;
  flex: 0 0 auto;
  grid-template-rows: minmax(0, 1fr);
  overflow: hidden;
  opacity: 1;
  transform: translateY(0);
  transition:
    grid-template-rows 120ms ease-out,
    opacity 90ms ease-out,
    transform 120ms ease-out;
}

.pcl-preset-scroll-controls-inner {
  min-height: 0;
  overflow: hidden;
}

.pcl-preset-dialog.is-roster-controls-collapsed .pcl-preset-scroll-controls {
  grid-template-rows: minmax(0, 0fr);
  pointer-events: none;
  opacity: 0;
  transform: translateY(-14px);
  transition-duration: 220ms, 150ms, 220ms;
}

.pcl-preset-overview {
  display: grid;
  grid-template-columns: repeat(3, minmax(190px, 0.72fr)) minmax(320px, 1.5fr);
  align-items: stretch;
  gap: 12px;
  padding: 16px 28px;
  border-bottom: 1px solid #dce3ee;
  background: #f9fbfd;
}

.pcl-preset-stat {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 11px;
  padding: 11px 13px;
  border: 1px solid #d7e0eb;
  border-radius: 9px;
  background: #ffffff;
  color: #58657a;
  font-size: 14px;
  font-weight: 650;
}

.pcl-preset-stat.is-confirmed {
  border-color: #bfe4ce;
}

.pcl-preset-stat.is-teams {
  border-color: #d7c7f3;
}

.pcl-preset-stat.is-missing {
  border-color: #ead6ae;
}

.pcl-preset-stat-value {
  color: #151d2e;
  font-size: 30px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.pcl-preset-stat.is-confirmed .pcl-preset-stat-value {
  color: #198050;
}

.pcl-preset-stat.is-teams .pcl-preset-stat-value {
  color: #7650b8;
}

.pcl-preset-stat.is-missing .pcl-preset-stat-value {
  color: #9a6513;
}

.pcl-preset-overview > p {
  align-self: center;
  margin: 0;
  color: #667287;
  font-size: 15px;
  line-height: 1.5;
}

.pcl-preset-toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 28px;
  border-bottom: 1px solid #dce3ee;
  background: #ffffff;
}

.pcl-preset-search {
  display: flex;
  min-width: 220px;
  flex: 1 1 auto;
  align-items: center;
  gap: 11px;
  height: 50px;
  padding: 0 15px;
  border: 1px solid #cbd5e4;
  border-radius: 9px;
  background: #f8fafc;
  color: #778399;
}

.pcl-preset-search:focus-within {
  border-color: #805ad5;
  box-shadow: 0 0 0 3px rgba(128, 90, 213, 0.13);
}

.pcl-preset-search input {
  min-width: 0;
  flex: 1 1 auto;
  height: 46px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #1f293b;
  font: inherit;
  font-size: 16px;
  box-shadow: none;
}

.pcl-preset-filter {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
  color: #69758a;
  font-size: 15px;
  font-weight: 650;
}

.pcl-preset-filter select {
  height: 50px;
  min-width: 210px;
  padding: 0 38px 0 14px;
  border: 1px solid #cbd5e4;
  border-radius: 9px;
  background-color: #f8fafc;
  color: #1f293b;
  font: inherit;
  font-size: 15px;
  cursor: pointer;
}

.pcl-unlock-panel {
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(360px, 1.2fr);
  gap: 24px;
  padding: 18px 28px;
  border-bottom: 1px solid #d7c7f3;
  background: #f7f2ff;
}

.pcl-unlock-panel[hidden] {
  display: none;
}

.pcl-unlock-copy {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  color: #68439b;
}

.pcl-unlock-copy > i {
  margin-top: 3px;
}

.pcl-unlock-copy h3 {
  margin: 0;
  color: #302044;
  font-size: 16px;
}

.pcl-unlock-copy p {
  margin: 3px 0 0;
  color: #755e92;
  font-size: 13px;
  line-height: 1.4;
}

.pcl-unlock-form label {
  display: block;
  margin-bottom: 5px;
  color: #51366f;
  font-size: 13px;
  font-weight: 700;
}

.pcl-unlock-row {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) auto auto;
  gap: 8px;
}

.pcl-unlock-row input {
  min-width: 0;
  height: 44px;
  padding: 0 12px;
  border: 1px solid #baa5db;
  border-radius: 7px;
  background: #ffffff;
  color: #231933;
  font: inherit;
}

.pcl-unlock-row input:focus {
  border-color: #7650b8;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(118, 80, 184, 0.14);
}

.pcl-password-error {
  margin: 5px 0 0;
  color: #b42318;
  font-size: 13px;
}

.pcl-preset-roster {
  min-height: 0;
  flex: 1 1 auto;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 18px 28px 24px;
}

.pcl-team-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.pcl-team-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #d7dfeb;
  border-radius: 10px;
  background: #ffffff;
}

.pcl-team-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
  padding: 9px 14px;
  border-bottom: 1px solid #e2e8f0;
  background: #f5f7fa;
}

.pcl-team-number {
  color: #252e40;
  font-size: 16px;
  font-weight: 800;
}

.pcl-team-count {
  color: #7a8599;
  font-size: 14px;
  font-weight: 650;
}

.pcl-team-players {
  margin: 0;
  padding: 0;
  list-style: none;
}

.pcl-player-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(200px, 0.82fr);
  align-items: center;
  gap: 16px;
  min-height: 74px;
  padding: 11px 14px;
  border-bottom: 1px solid #edf0f5;
}

.pcl-player-row:last-child {
  border-bottom: 0;
}

.pcl-player-identity,
.pcl-player-meta {
  min-width: 0;
}

.pcl-player-name {
  display: block;
  overflow: hidden;
  color: #20293a;
  font-size: 16px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pcl-player-twitch {
  display: block;
  overflow: hidden;
  margin-top: 5px;
  color: #7142bd;
  font-size: 14px;
  line-height: 1.2;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pcl-player-twitch:hover,
.pcl-player-twitch:focus-visible {
  color: #4d268d;
  text-decoration: underline;
}

.pcl-player-twitch.is-missing {
  color: #929bad;
}

.pcl-player-meta {
  text-align: right;
}

.pcl-player-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #69758a;
  font-size: 14px;
  font-weight: 750;
}

.pcl-player-status.is-verified {
  color: #147b4a;
}

.pcl-player-status.is-missing {
  color: #9a681d;
}

.pcl-player-method {
  display: block;
  overflow: hidden;
  margin-top: 5px;
  color: #929bad;
  font-size: 13px;
  line-height: 1.35;
  text-overflow: clip;
  white-space: normal;
}

.pcl-player-row--editing {
  grid-template-columns: minmax(110px, 0.8fr) minmax(135px, 1fr) auto;
  align-items: end;
  gap: 8px;
  padding-block: 9px;
  background: #fdfcff;
}

.pcl-edit-field,
.pcl-confirm-toggle {
  min-width: 0;
}

.pcl-edit-label {
  display: block;
  margin-bottom: 4px;
  color: #788398;
  font-size: 11px;
  font-weight: 750;
  text-transform: uppercase;
}

.pcl-edit-field input {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0 10px;
  border: 1px solid #cbd5e4;
  border-radius: 6px;
  background: #ffffff;
  color: #1f293b;
  font: inherit;
  font-size: 13px;
}

.pcl-edit-field input:focus {
  border-color: #7650b8;
  outline: 0;
  box-shadow: 0 0 0 2px rgba(118, 80, 184, 0.13);
}

.pcl-confirm-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  color: #58657a;
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
  cursor: pointer;
}

.pcl-confirm-toggle input {
  accent-color: #7650b8;
}

.pcl-preset-empty {
  margin: 40px 0;
  color: #758197;
  font-size: 15px;
  text-align: center;
}

.pcl-preset-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 16px 28px;
  border-top: 1px solid #dce3ee;
  background: #ffffff;
}

.pcl-preset-footer > p {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: #69758b;
  font-size: 13px;
  line-height: 1.35;
}

.pcl-preset-footer > p > span {
  display: grid;
  gap: 2px;
}

.pcl-preset-footer > p strong {
  color: inherit;
  font-size: 13px;
}

.pcl-preset-footer > p small {
  color: #8791a3;
  font-size: 12px;
}

.pcl-preset-footer > p i {
  color: #198050;
}

.pcl-preset-footer-actions,
.pcl-editor-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pcl-preset-footer-actions button,
.pcl-unlock-row button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0;
  padding: 0 18px;
  border-radius: 9px;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
}

.pcl-preset-footer-actions .primary-button,
.pcl-unlock-row .primary-button {
  border-color: #7650b8;
  background: #7650b8;
  color: #ffffff;
}

.pcl-preset-footer-actions .primary-button:hover,
.pcl-preset-footer-actions .primary-button:focus-visible,
.pcl-unlock-row .primary-button:hover,
.pcl-unlock-row .primary-button:focus-visible {
  border-color: #623da4;
  background: #623da4;
}

.pcl-preset-footer-actions button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.pcl-editor-actions[hidden] {
  display: none !important;
}

.pcl-preset-footer-actions > [hidden] {
  display: none !important;
}

body[data-theme="dark"] .pcl-preset-card {
  border-color: #5c477e;
  background: #17131d;
  box-shadow: none;
}

body[data-theme="dark"] .pcl-preset-card:hover,
body[data-theme="dark"] .pcl-preset-card:focus-within {
  border-color: #8c68ca;
  background: #1d1725;
}

body[data-theme="dark"] .pcl-preset-icon.group-icon {
  border-color: #5f477e;
  background: #291f36;
  color: #c8a7ff;
}

body[data-theme="dark"] .pcl-preset-card-title {
  color: #f3eff8;
}

body[data-theme="dark"] .pcl-preset-card-summary {
  color: #aaa1b5;
}

body[data-theme="dark"] .pcl-preset-card-badges span {
  border-color: #503e67;
  color: #c6a9eb;
}

body[data-theme="dark"] .pcl-preset-shell {
  border-color: #35323b;
  background: #111315;
  color: #e6e2ea;
}

body[data-theme="dark"] .pcl-preset-header,
body[data-theme="dark"] .pcl-preset-toolbar,
body[data-theme="dark"] .pcl-preset-footer {
  border-color: #33373d;
  background: #181a1d;
}

body[data-theme="dark"] .pcl-preset-title-row h2,
body[data-theme="dark"] .pcl-preset-stat-value,
body[data-theme="dark"] .pcl-team-number,
body[data-theme="dark"] .pcl-player-name {
  color: #f0edf3;
}

body[data-theme="dark"] .pcl-preset-overview > p,
body[data-theme="dark"] .pcl-preset-footer > p {
  color: #a4a8b1;
}

body[data-theme="dark"] .pcl-preset-totals-label,
body[data-theme="dark"] .pcl-preset-total {
  color: #a4a8b1;
}

body[data-theme="dark"] .pcl-preset-total {
  border-color: #41464e;
  background: #222529;
}

body[data-theme="dark"] .pcl-preset-total strong {
  color: #f0edf3;
}

body[data-theme="dark"] .pcl-preset-footer > p small {
  color: #8f949e;
}

body[data-theme="dark"] .pcl-preset-overview {
  border-color: #33373d;
  background: #141619;
}

body[data-theme="dark"] .pcl-preset-stat,
body[data-theme="dark"] .pcl-team-card {
  border-color: #34383f;
  background: #1a1d20;
  color: #b2b6bf;
}

body[data-theme="dark"] .pcl-team-header {
  border-color: #34383f;
  background: #202327;
}

body[data-theme="dark"] .pcl-player-row {
  border-color: #2c3035;
}

body[data-theme="dark"] .pcl-player-row--editing {
  background: #17141c;
}

body[data-theme="dark"] .pcl-preset-search,
body[data-theme="dark"] .pcl-preset-filter select,
body[data-theme="dark"] .pcl-edit-field input,
body[data-theme="dark"] .pcl-unlock-row input {
  border-color: #41464e;
  background: #222529;
  color: #f0edf3;
}

body[data-theme="dark"] .pcl-preset-close {
  border-color: #41464e;
  background: #222529;
  color: #c7cbd2;
}

body[data-theme="dark"] .pcl-unlock-panel {
  border-color: #4e3c68;
  background: #201829;
}

body[data-theme="dark"] .pcl-unlock-copy h3 {
  color: #efe7f9;
}

body[data-theme="dark"] .pcl-unlock-copy p,
body[data-theme="dark"] .pcl-unlock-form label {
  color: #c3afd9;
}

@media (max-width: 1200px) {
  .pcl-preset-overview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .pcl-preset-overview > p {
    grid-column: 1 / -1;
  }
}

@media (max-width: 900px) {
  .pcl-preset-header {
    gap: 18px;
  }

  .pcl-preset-header-totals {
    min-width: 218px;
  }

  .pcl-preset-total {
    min-width: 101px;
    padding-inline: 9px;
  }

  .pcl-preset-total strong {
    font-size: 25px;
  }

  .pcl-preset-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pcl-preset-overview > p {
    grid-column: 1 / -1;
  }

  .pcl-team-grid {
    grid-template-columns: 1fr;
  }

  .pcl-unlock-panel {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

@media (max-width: 660px) {
  .pcl-preset-dialog {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    max-height: none;
    margin: 0;
    border-radius: 0;
  }

  .pcl-preset-shell {
    height: 100%;
    min-height: 0;
    max-height: none;
    border: 0;
    border-radius: 0;
  }

  .pcl-preset-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 48px;
    gap: 12px;
    padding-block: 16px 12px;
  }

  .pcl-preset-heading {
    align-self: center;
  }

  .pcl-preset-close {
    grid-column: 2;
    grid-row: 1;
  }

  .pcl-preset-header-totals {
    width: 100%;
    min-width: 0;
    grid-column: 1 / -1;
    grid-row: 2;
    gap: 5px;
    margin-left: 0;
  }

  .pcl-preset-totals-label {
    text-align: left;
  }

  .pcl-preset-total {
    min-width: 0;
    justify-content: flex-start;
    padding: 7px 10px;
  }

  .pcl-preset-total strong {
    font-size: 23px;
  }

  .pcl-preset-header,
  .pcl-preset-overview,
  .pcl-preset-toolbar,
  .pcl-unlock-panel,
  .pcl-preset-footer {
    padding-inline: 15px;
  }

  .pcl-preset-title-row h2 {
    font-size: clamp(25px, 7vw, 30px);
  }

  .pcl-preset-overview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    padding-block: 10px;
  }

  .pcl-preset-overview > p {
    display: none;
  }

  .pcl-preset-stat {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
    padding: 8px;
    font-size: 11px;
    line-height: 1.2;
  }

  .pcl-preset-stat-value {
    font-size: 24px;
  }

  .pcl-preset-roster {
    padding: 12px 15px 18px;
  }

  .pcl-preset-toolbar,
  .pcl-preset-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .pcl-preset-filter {
    justify-content: space-between;
  }

  .pcl-preset-filter select {
    min-width: 180px;
  }

  .pcl-preset-footer-actions,
  .pcl-editor-actions {
    width: 100%;
  }

  .pcl-preset-footer-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pcl-preset-footer-actions > button {
    width: 100%;
    min-width: 0;
    padding-inline: 8px;
    font-size: 12px;
  }

  .pcl-preset-footer-actions > #pclPresetEdit,
  .pcl-preset-footer-actions > .pcl-editor-actions {
    grid-column: 1 / -1;
  }

  .pcl-editor-actions > button {
    flex: 1 1 auto;
  }

  .pcl-preset-footer > p {
    justify-content: center;
    font-size: 12px;
  }

  .pcl-preset-footer > p small {
    display: none;
  }

  .pcl-player-row,
  .pcl-player-row--editing {
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 7px;
  }

  .pcl-player-meta {
    text-align: left;
  }

  .pcl-unlock-row {
    grid-template-columns: 1fr 1fr;
  }

  .pcl-unlock-row input {
    grid-column: 1 / -1;
  }
}

@media (max-width: 420px) {
  .pcl-preset-card-action {
    padding-inline: 8px;
    font-size: 0;
  }

  .pcl-preset-card-action i {
    font-size: 11px;
  }

  .pcl-preset-overview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .pcl-preset-overview > p {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pcl-preset-scroll-controls,
  .pcl-preset-dialog.is-roster-controls-collapsed .pcl-preset-scroll-controls {
    transform: none;
    transition: none;
  }
}

/* -------------------------------------------------------------------------- */
/* Saved lobby launch controls                                                */
/* -------------------------------------------------------------------------- */

.launch-lobby-context {
  position: relative;
  display: inline-flex;
  height: 48px;
  min-width: 300px;
  max-width: min(360px, 100%);
  align-items: stretch;
  isolation: isolate;
}

.launch-lobby-context[hidden] {
  display: none;
}

.launch-lobby-context.is-open {
  z-index: 1000;
}

.launch-lobby-picker {
  position: relative;
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
}

.launch-lobby-toggle {
  display: grid;
  width: 100%;
  min-width: 0;
  height: 48px;
  grid-template-columns: 18px minmax(0, 1fr) 12px;
  align-items: center;
  gap: 9px;
  padding: 6px 10px 6px 12px;
  border: 1px solid var(--daylight-border);
  border-right: 0;
  border-radius: 12px 0 0 12px;
  background: var(--daylight-surface);
  color: var(--daylight-muted);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.launch-lobby-toggle:hover,
.launch-lobby-toggle:focus-visible,
.launch-lobby-toggle.is-open {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
  outline: 0;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.launch-lobby-toggle > i:first-child {
  color: var(--daylight-primary);
  font-size: 14px;
}

.launch-lobby-toggle > .fa-chevron-down {
  justify-self: end;
  color: currentColor;
  font-size: 10px;
  transition: transform 160ms ease;
}

.launch-lobby-toggle.is-open > .fa-chevron-down {
  transform: rotate(180deg);
}

.launch-lobby-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.launch-lobby-copy small {
  color: var(--daylight-muted);
  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
}

.launch-lobby-copy strong {
  display: block;
  min-width: 0;
  overflow: hidden;
  color: var(--daylight-ink-strong);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.launch-lobby-picker > select[hidden] {
  display: none !important;
}

.launch-lobby-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 1100;
  display: grid;
  width: min(360px, calc(100vw - 32px));
  max-height: min(360px, calc(100vh - 32px));
  gap: 4px;
  padding: 7px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--daylight-border);
  border-radius: 12px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  box-shadow: 0 18px 42px rgba(31, 61, 113, 0.22);
}

.launch-lobby-menu[hidden] {
  display: none;
}

.launch-lobby-option {
  display: grid;
  width: 100%;
  min-width: 0;
  grid-template-columns: 30px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--daylight-ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.launch-lobby-option:hover,
.launch-lobby-option:focus-visible,
.launch-lobby-option.is-selected {
  border-color: var(--daylight-border-soft);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
  outline: none;
}

.launch-lobby-option > i:first-child {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid var(--daylight-border-soft);
  border-radius: 7px;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-primary);
  font-size: 12px;
}

.launch-lobby-option > span {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.launch-lobby-option strong,
.launch-lobby-option small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.launch-lobby-option strong {
  color: var(--daylight-ink-strong);
  font-size: 13px;
  line-height: 1.3;
}

.launch-lobby-option small {
  color: var(--daylight-muted);
  font-size: 11px;
  line-height: 1.35;
}

.launch-lobby-option > i:last-child {
  color: transparent;
  font-size: 11px;
}

.launch-lobby-option.is-selected > i:last-child {
  color: var(--daylight-primary);
}

.launch-lobby-create {
  display: grid;
  flex: 0 0 42px;
  width: 42px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--daylight-border);
  border-radius: 0 12px 12px 0;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-primary);
  font: inherit;
  cursor: pointer;
}

.launch-lobby-create:hover,
.launch-lobby-create:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary-hover);
}

.dashboard-lobby-dialog {
  width: min(510px, calc(100vw - 28px));
  max-width: none;
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--daylight-border);
  border-radius: 14px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  box-shadow: 0 28px 80px rgba(31, 61, 113, 0.24);
}

.dashboard-lobby-dialog::backdrop {
  background: rgba(10, 17, 29, 0.66);
  backdrop-filter: blur(4px);
}

.dashboard-lobby-form {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.dashboard-lobby-header {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 38px;
  align-items: start;
  gap: 12px;
}

.dashboard-lobby-icon,
.dashboard-lobby-close {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-primary);
}

.dashboard-lobby-icon {
  width: 42px;
  height: 42px;
}

.dashboard-lobby-close {
  padding: 0;
  color: var(--daylight-muted);
  font: inherit;
  cursor: pointer;
}

.dashboard-lobby-close:hover,
.dashboard-lobby-close:focus-visible {
  border-color: var(--daylight-border-strong);
  color: var(--daylight-ink-strong);
}

.dashboard-lobby-header h2 {
  margin: 0;
  color: var(--daylight-ink-strong);
  font-size: 22px;
  line-height: 1.15;
}

.dashboard-lobby-header p {
  margin: 5px 0 0;
  color: var(--daylight-muted);
  font-size: 12px;
  line-height: 1.45;
}

.dashboard-lobby-field {
  display: grid;
  gap: 7px;
  color: var(--daylight-ink);
  font-size: 12px;
  font-weight: 700;
}

.dashboard-lobby-field input {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  border: 1px solid var(--daylight-border);
  border-radius: 8px;
  outline: 0;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-ink-strong);
  font: inherit;
  font-size: 15px;
}

.dashboard-lobby-field input:focus {
  border-color: var(--daylight-primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.11);
}

.dashboard-lobby-status {
  min-height: 16px;
  margin: -7px 0 0;
  color: #b42318;
  font-size: 11px;
}

.dashboard-lobby-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.dashboard-lobby-actions button {
  min-height: 40px;
  margin: 0;
  border-radius: 8px;
  font-size: 12px;
}

body[data-theme="dark"] .launch-lobby-toggle,
body[data-theme="dark"] .launch-lobby-create,
body[data-theme="dark"] .launch-lobby-menu,
body[data-theme="dark"] .dashboard-lobby-dialog {
  border-color: var(--daylight-border);
  background: var(--daylight-surface);
}

body[data-theme="dark"] .launch-lobby-toggle > i:first-child,
body[data-theme="dark"] .launch-lobby-create,
body[data-theme="dark"] .dashboard-lobby-icon {
  color: #dddddf;
}

body[data-theme="dark"] .launch-lobby-copy strong,
body[data-theme="dark"] .launch-lobby-option strong,
body[data-theme="dark"] .dashboard-lobby-header h2,
body[data-theme="dark"] .dashboard-lobby-field input {
  color: #f1f1f2;
}

body[data-theme="dark"] .launch-lobby-toggle:hover,
body[data-theme="dark"] .launch-lobby-toggle:focus-visible,
body[data-theme="dark"] .launch-lobby-toggle.is-open,
body[data-theme="dark"] .launch-lobby-option:hover,
body[data-theme="dark"] .launch-lobby-option:focus-visible,
body[data-theme="dark"] .launch-lobby-option.is-selected {
  border-color: #555555;
  background: var(--daylight-surface-subtle);
}

body[data-theme="dark"] .launch-lobby-menu {
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.52);
}

body[data-theme="dark"] .launch-lobby-option > i:first-child {
  border-color: #414141;
  background: #2d2d2d;
  color: #eeeeee;
}

body[data-theme="dark"] .launch-lobby-option small {
  color: #a4a4a4;
}

body[data-theme="dark"] .launch-lobby-option.is-selected > i:last-child {
  color: #f1f1f2;
}

body[data-theme="dark"] .launch-lobby-create,
body[data-theme="dark"] .dashboard-lobby-icon,
body[data-theme="dark"] .dashboard-lobby-close,
body[data-theme="dark"] .dashboard-lobby-field input {
  background: var(--daylight-surface-subtle);
}

body[data-theme="dark"] .dashboard-lobby-dialog {
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.52);
}

.pcl-preset-footer-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

@media (max-width: 1080px) {
  .dashboard-header-actions {
    flex-wrap: wrap;
  }

  .launch-lobby-context {
    min-width: 260px;
  }
}

@media (max-width: 760px) {
  .dashboard-header-actions {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .dashboard-remote-button {
    width: 100%;
    min-width: 0;
    grid-column: 2;
  }

  .launch-lobby-context,
  .launch-center {
    grid-column: 1 / -1;
    width: 100%;
  }

  .party-queue-header {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .queue-header-actions {
    display: grid;
    width: 100%;
    grid-template-columns: minmax(0, 1fr) auto auto;
  }

  .dashboard-header-actions .theme-toggle {
    grid-column: 1;
  }

  .pcl-preset-footer-actions > button,
  .pcl-preset-footer-actions > .pcl-editor-actions {
    flex: 1 1 100%;
  }

  .pcl-preset-footer-actions > .pcl-editor-actions > button {
    flex: 1 1 0;
  }
}

@media (max-width: 520px) {
  .queue-header-actions {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .launch-lobby-context {
    grid-column: 1 / -1;
    min-width: 0;
    max-width: none;
  }

  .dashboard-lobby-form {
    gap: 15px;
    padding: 18px;
  }

  .dashboard-lobby-actions button {
    flex: 1 1 0;
  }
}

/* Dashboard Team creation and grouped queue slots */
.dashboard-team-create-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  border: 1px solid #aeb4b8;
  border-radius: 9px;
  background: linear-gradient(180deg, #ffffff 0%, #e8eaeb 100%);
  box-shadow:
    0 5px 12px rgba(47, 52, 56, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.82);
  color: #353a3e;
  font-size: 14px;
  font-weight: 700;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
  white-space: nowrap;
}

.dashboard-team-create-button i {
  width: 16px;
  color: #5f6469;
  font-size: 14px;
}

.dashboard-team-create-button:hover,
.dashboard-team-create-button:focus-visible {
  border-color: #7d8489;
  background: linear-gradient(180deg, #ffffff 0%, #dfe2e3 100%);
  box-shadow:
    0 8px 17px rgba(47, 52, 56, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: #202428;
  transform: translateY(-1px);
}

.dashboard-team-create-button:active {
  box-shadow:
    0 3px 7px rgba(47, 52, 56, 0.16),
    inset 0 1px 2px rgba(47, 52, 56, 0.12);
  transform: translateY(0);
}

.artist.queue-team-card {
  --daylight-surface: #fbfbfb;
  --daylight-surface-subtle: #f1f2f2;
  --daylight-surface-blue: #eceeef;
  --daylight-ink: #353a3e;
  --daylight-ink-strong: #202428;
  --daylight-muted: #6c7379;
  --daylight-border: #dce0e3;
  --daylight-border-soft: #e9ebed;
  --daylight-border-strong: #b9bec2;
  border-color: rgba(92, 98, 103, 0.5);
  background:
    linear-gradient(135deg, rgba(92, 98, 103, 0.12), transparent 58%),
    var(--daylight-surface);
}

.artist.queue-team-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  border-radius: 8px 0 0 8px;
  background: linear-gradient(180deg, #7f868b, #c4c8cb);
  content: "";
}

.artist.queue-team-card:hover,
.artist.queue-team-card:focus-within,
.artist.queue-team-card.queue-stream-drop-target {
  border-color: rgba(70, 76, 81, 0.72);
  background:
    linear-gradient(135deg, rgba(92, 98, 103, 0.16), transparent 58%),
    var(--daylight-surface-blue);
}

.artist-img-container.queue-stream-avatar.queue-team-avatar {
  position: relative;
  overflow: visible;
  border: 0;
  background: transparent;
}

.queue-team-avatar-member {
  position: absolute;
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  overflow: hidden;
  border: 2px solid var(--daylight-surface);
  border-radius: 50%;
  background: #34383b;
  color: #f4f4f4;
  font-size: 10px;
  font-weight: 800;
}

.queue-team-avatar[data-member-count="2"] .queue-team-avatar-member {
  top: 50%;
  bottom: auto;
  width: clamp(30px, 44%, 34px);
  height: clamp(30px, 44%, 34px);
  transform: translateY(-50%);
}

.queue-team-avatar[data-member-count="2"]
  .queue-team-avatar-member:nth-child(1) {
  right: auto;
  left: 2%;
  z-index: 3;
}

.queue-team-avatar[data-member-count="2"]
  .queue-team-avatar-member:nth-child(2) {
  right: 2%;
  left: auto;
  z-index: 2;
}

.queue-team-avatar[data-member-count="3"]
  .queue-team-avatar-member:nth-child(1) {
  top: 0;
  right: auto;
  bottom: auto;
  left: 3%;
  z-index: 3;
}

.queue-team-avatar[data-member-count="3"]
  .queue-team-avatar-member:nth-child(2) {
  top: 0;
  right: 3%;
  bottom: auto;
  left: auto;
  z-index: 2;
}

.queue-team-avatar[data-member-count="3"]
  .queue-team-avatar-member:nth-child(3) {
  top: auto;
  right: auto;
  bottom: 0;
  left: 50%;
  z-index: 4;
  transform: translateX(-50%);
}

.queue-team-avatar[data-member-count="4"] .queue-team-avatar-member {
  width: clamp(24px, 36%, 27px);
  height: clamp(24px, 36%, 27px);
}

.queue-team-avatar[data-member-count="4"]
  .queue-team-avatar-member:nth-child(1) {
  top: 0;
  right: auto;
  bottom: auto;
  left: 2%;
  z-index: 3;
}

.queue-team-avatar[data-member-count="4"]
  .queue-team-avatar-member:nth-child(2) {
  top: 0;
  right: 2%;
  bottom: auto;
  left: auto;
  z-index: 2;
}

.queue-team-avatar[data-member-count="4"]
  .queue-team-avatar-member:nth-child(3) {
  top: auto;
  right: auto;
  bottom: 0;
  left: 2%;
  z-index: 4;
}

.queue-team-avatar[data-member-count="4"]
  .queue-team-avatar-member:nth-child(4) {
  top: auto;
  right: 2%;
  bottom: 0;
  left: auto;
  z-index: 3;
}

.queue-team-avatar[data-member-count="5"] .queue-team-avatar-member {
  width: clamp(24px, 36%, 26px);
  height: clamp(24px, 36%, 26px);
  font-size: 9px;
}

.queue-team-avatar[data-member-count="5"]
  .queue-team-avatar-member:nth-child(1) {
  top: 4%;
  right: auto;
  bottom: auto;
  left: 50%;
  z-index: 5;
  transform: translateX(-50%);
}

.queue-team-avatar[data-member-count="5"]
  .queue-team-avatar-member:nth-child(2) {
  top: 24%;
  right: 6%;
  bottom: auto;
  left: auto;
  z-index: 4;
  transform: none;
}

.queue-team-avatar[data-member-count="5"]
  .queue-team-avatar-member:nth-child(3) {
  top: auto;
  right: 16%;
  bottom: 10%;
  left: auto;
  z-index: 3;
  transform: none;
}

.queue-team-avatar[data-member-count="5"]
  .queue-team-avatar-member:nth-child(4) {
  top: auto;
  right: auto;
  bottom: 10%;
  left: 16%;
  z-index: 3;
  transform: none;
}

.queue-team-avatar[data-member-count="5"]
  .queue-team-avatar-member:nth-child(5) {
  top: 24%;
  right: auto;
  bottom: auto;
  left: 6%;
  z-index: 4;
  transform: none;
}

.artist-img-container.queue-team-avatar .queue-team-avatar-member img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.queue-team-card .queue-stream-name {
  color: var(--daylight-ink-strong);
}

.queue-team-card .edit-team-btn {
  color: #62686d;
}

.dashboard-team-dialog {
  --daylight-surface: #fbfbfb;
  --daylight-surface-subtle: #f1f2f2;
  --daylight-surface-blue: #eceeef;
  --daylight-ink: #353a3e;
  --daylight-ink-strong: #202428;
  --daylight-muted: #6c7379;
  --daylight-border: #dce0e3;
  --daylight-border-soft: #e9ebed;
  --daylight-border-strong: #b9bec2;
  width: min(570px, calc(100vw - 28px));
  max-width: none;
  max-height: calc(100dvh - 28px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--daylight-border);
  border-radius: 16px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  box-shadow: 0 30px 90px rgba(31, 42, 78, 0.34);
}

.dashboard-team-dialog::backdrop {
  background: rgba(7, 12, 23, 0.7);
  backdrop-filter: blur(5px);
}

.dashboard-team-form {
  display: grid;
  max-height: calc(100dvh - 28px);
  gap: 18px;
  padding: 22px;
  overflow: auto;
}

.dashboard-team-header {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 38px;
  align-items: start;
  gap: 12px;
}

.dashboard-team-icon,
.dashboard-team-close {
  display: grid;
  place-items: center;
  border: 1px solid var(--daylight-border);
  border-radius: 9px;
  background: var(--daylight-surface-subtle);
}

.dashboard-team-icon {
  width: 44px;
  height: 44px;
  color: #5f6469;
}

.dashboard-team-close {
  width: 38px;
  height: 38px;
  padding: 0;
  color: var(--daylight-muted);
  font: inherit;
  cursor: pointer;
}

.dashboard-team-close:hover,
.dashboard-team-close:focus-visible {
  border-color: var(--daylight-border-strong);
  color: var(--daylight-ink-strong);
  outline: 0;
}

.dashboard-team-kicker {
  margin: 0 0 3px;
  color: #5f6469;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.dashboard-team-header h2 {
  margin: 0;
  color: var(--daylight-ink-strong);
  font-size: 22px;
  line-height: 1.15;
}

.dashboard-team-header #dashboardTeamHelp {
  margin: 5px 0 0;
  color: var(--daylight-muted);
  font-size: 12px;
  line-height: 1.45;
}

.dashboard-team-field {
  display: grid;
  gap: 7px;
  color: var(--daylight-ink);
  font-size: 12px;
  font-weight: 700;
}

.dashboard-team-field input,
.dashboard-team-member-row input {
  width: 100%;
  min-width: 0;
  height: 44px;
  padding: 0 13px;
  border: 1px solid var(--daylight-border);
  border-radius: 8px;
  outline: 0;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-ink-strong);
  font: inherit;
  font-size: 14px;
}

.dashboard-team-field input:focus,
.dashboard-team-member-row input:focus {
  border-color: #7f868b;
  box-shadow: 0 0 0 3px rgba(92, 98, 103, 0.16);
}

.dashboard-team-members {
  display: grid;
  min-width: 0;
  gap: 10px;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--daylight-border);
  border-radius: 11px;
  background: color-mix(in srgb, var(--daylight-surface-subtle) 62%, transparent);
}

.dashboard-team-members legend {
  padding: 0 6px;
  color: var(--daylight-ink-strong);
  font-size: 12px;
  font-weight: 800;
}

.dashboard-team-members > p {
  margin: -2px 0 1px;
  color: var(--daylight-muted);
  font-size: 11px;
  line-height: 1.45;
}

.dashboard-team-stream-search {
  display: grid;
  gap: 6px;
}

.dashboard-team-stream-search[hidden] {
  display: none !important;
}

.dashboard-team-stream-search > label {
  color: var(--daylight-ink);
  font-size: 11px;
  font-weight: 800;
}

.dashboard-team-stream-search-control {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 7px 0 12px;
  border: 1px solid var(--daylight-border);
  border-radius: 8px;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-muted);
  transition: border-color 160ms ease, box-shadow 160ms ease,
    background 160ms ease;
}

.dashboard-team-stream-search-control:focus-within {
  border-color: #7f868b;
  background: var(--daylight-surface);
  box-shadow: 0 0 0 3px rgba(92, 98, 103, 0.16);
}

.dashboard-team-stream-search-control > i {
  font-size: 12px;
  text-align: center;
}

.dashboard-team-stream-search-control input {
  min-width: 0;
  width: 100%;
  height: 38px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--daylight-ink-strong);
  font: inherit;
  font-size: 13px;
}

.dashboard-team-stream-search-control input::placeholder {
  color: var(--daylight-muted);
}

.dashboard-team-stream-search-control input::-webkit-search-cancel-button {
  display: none;
}

.dashboard-team-stream-search-control button {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--daylight-muted);
  cursor: pointer;
}

.dashboard-team-stream-search-control button:hover,
.dashboard-team-stream-search-control button:focus-visible {
  background: var(--daylight-surface-blue);
  color: var(--daylight-ink-strong);
  outline: 0;
}

.dashboard-team-stream-search-control button[hidden] {
  display: block;
  visibility: hidden;
  pointer-events: none;
}

.dashboard-team-stream-search-status {
  min-height: 15px;
  margin: 0;
  color: var(--daylight-muted);
  font-size: 10px;
  line-height: 1.4;
}

.dashboard-team-member-rows {
  display: grid;
  gap: 8px;
}

.dashboard-team-member-rows[hidden],
.dashboard-team-add-member[hidden] {
  display: none !important;
}

.dashboard-team-member-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  gap: 8px;
}

.dashboard-team-member-marker,
.dashboard-team-remove-member {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
}

.dashboard-team-member-marker {
  background: rgba(92, 98, 103, 0.12);
  color: #5f6469;
  font-size: 16px;
}

.dashboard-team-remove-member {
  padding: 0;
  border: 1px solid transparent;
  background: transparent;
  color: var(--daylight-muted);
  cursor: pointer;
}

.dashboard-team-remove-member:hover,
.dashboard-team-remove-member:focus-visible {
  border-color: rgba(180, 35, 24, 0.25);
  background: rgba(180, 35, 24, 0.08);
  color: #b42318;
  outline: 0;
}

.dashboard-team-remove-member[hidden] {
  display: block;
  visibility: hidden;
}

.dashboard-team-add-member {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  justify-self: start;
  padding: 0 12px;
  border: 1px dashed var(--daylight-border-strong);
  border-radius: 8px;
  background: transparent;
  color: #5f6469;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.dashboard-team-add-member:hover,
.dashboard-team-add-member:focus-visible {
  border-style: solid;
  background: rgba(92, 98, 103, 0.08);
  outline: 0;
}

.dashboard-team-add-member:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.dashboard-team-stream-options {
  display: grid;
  max-height: 286px;
  gap: 8px;
  overflow-y: auto;
}

.dashboard-team-stream-option {
  position: relative;
  display: grid;
  grid-template-columns: 22px 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 7px 10px;
  border: 1px solid var(--daylight-border);
  border-radius: 9px;
  background: var(--daylight-surface);
  color: var(--daylight-ink);
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease,
    transform 160ms ease;
}

.dashboard-team-stream-option[hidden],
.dashboard-team-stream-options-empty[hidden] {
  display: none !important;
}

.dashboard-team-stream-option:hover,
.dashboard-team-stream-option:focus-within {
  border-color: #9aa0a5;
  background: var(--daylight-surface-blue);
}

.dashboard-team-stream-option:active {
  transform: translateY(1px);
}

.dashboard-team-stream-option > input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.dashboard-team-stream-check {
  display: grid;
  width: 20px;
  height: 20px;
  place-items: center;
  border: 1px solid var(--daylight-border-strong);
  border-radius: 6px;
  color: transparent;
  font-size: 11px;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.dashboard-team-stream-option > input:checked ~ .dashboard-team-stream-check {
  border-color: #5f6469;
  background: #5f6469;
  color: #fff;
}

.dashboard-team-stream-option > input:focus-visible ~ .dashboard-team-stream-check {
  outline: 3px solid rgba(92, 98, 103, 0.24);
  outline-offset: 2px;
}

.dashboard-team-stream-avatar {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--daylight-border);
  border-radius: 50%;
  background: var(--daylight-surface-subtle);
  color: var(--daylight-muted);
  font-size: 13px;
  font-weight: 800;
}

.dashboard-team-stream-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dashboard-team-stream-details {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.dashboard-team-stream-details strong,
.dashboard-team-stream-details small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-team-stream-details strong {
  color: var(--daylight-ink-strong);
  font-size: 12px;
}

.dashboard-team-stream-details small {
  color: var(--daylight-muted);
  font-size: 11px;
}

.dashboard-team-stream-state {
  color: var(--daylight-muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.dashboard-team-stream-options-empty {
  margin: 0;
  padding: 16px 10px;
  border: 1px dashed var(--daylight-border-strong);
  border-radius: 8px;
  color: var(--daylight-muted);
  font-size: 12px;
  text-align: center;
}

.dashboard-team-status {
  min-height: 17px;
  margin: -7px 0 0;
  color: var(--daylight-muted);
  font-size: 11px;
}

.dashboard-team-status[data-state="error"] {
  color: #b42318;
}

.dashboard-team-status[data-state="loading"] {
  color: #5f6469;
}

.dashboard-team-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.dashboard-team-actions button {
  min-height: 40px;
  margin: 0;
  border-radius: 8px;
  font-size: 12px;
}

.dashboard-team-actions .primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 112px;
  padding: 0 15px;
  border: 1px solid #5f6469;
  background: #5f6469;
  color: #ffffff;
  box-shadow: 0 5px 12px rgba(47, 52, 56, 0.2);
  font-weight: 700;
  white-space: nowrap;
}

.dashboard-team-actions .primary-button:hover,
.dashboard-team-actions .primary-button:focus-visible {
  border-color: #4d5358;
  background: #4d5358;
  color: #ffffff;
  box-shadow: 0 7px 16px rgba(47, 52, 56, 0.28);
}

.dashboard-team-actions .primary-button:focus-visible {
  outline: 3px solid rgba(92, 98, 103, 0.28);
  outline-offset: 2px;
}

.dashboard-team-actions .primary-button:disabled {
  cursor: wait;
  opacity: 0.68;
}

body[data-theme="dark"] .dashboard-team-actions .primary-button {
  border-color: #d7d9da;
  background: #7e8387;
  color: #ffffff;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.28);
}

body[data-theme="dark"] .dashboard-team-create-button {
  border-color: #686d71;
  background: linear-gradient(180deg, #3d4143 0%, #27292a 100%);
  box-shadow:
    0 6px 15px rgba(0, 0, 0, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: #f1f2f2;
}

body[data-theme="dark"] .dashboard-team-create-button i {
  color: #c8cbcd;
}

body[data-theme="dark"] .dashboard-team-create-button:hover,
body[data-theme="dark"] .dashboard-team-create-button:focus-visible {
  border-color: #999ea2;
  background: linear-gradient(180deg, #4b4f51 0%, #303335 100%);
  box-shadow:
    0 9px 20px rgba(0, 0, 0, 0.48),
    inset 0 1px 0 rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

body[data-theme="dark"] .dashboard-team-create-button:active {
  box-shadow:
    0 3px 8px rgba(0, 0, 0, 0.34),
    inset 0 1px 2px rgba(0, 0, 0, 0.32);
}

body[data-theme="dark"] .dashboard-team-actions .primary-button:hover,
body[data-theme="dark"] .dashboard-team-actions .primary-button:focus-visible {
  border-color: #f1f1f1;
  background: #9a9fa3;
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.36);
}

body[data-theme="dark"] .dashboard-team-dialog {
  --daylight-surface: #202020;
  --daylight-surface-subtle: #262626;
  --daylight-surface-blue: #2c2c2c;
  --daylight-ink: #e7e7e7;
  --daylight-ink-strong: #f4f4f4;
  --daylight-muted: #a4a4a4;
  --daylight-border: #404040;
  --daylight-border-soft: #303030;
  --daylight-border-strong: #646464;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.58);
}

body[data-theme="dark"] .artist.queue-team-card {
  --daylight-surface: #202020;
  --daylight-surface-subtle: #262626;
  --daylight-surface-blue: #2c2c2c;
  --daylight-ink: #e7e7e7;
  --daylight-ink-strong: #f4f4f4;
  --daylight-muted: #a4a4a4;
  --daylight-border: #404040;
  --daylight-border-soft: #303030;
  --daylight-border-strong: #646464;
  border-color: rgba(214, 216, 218, 0.5);
  background:
    linear-gradient(135deg, rgba(214, 216, 218, 0.13), transparent 58%),
    var(--daylight-surface-subtle);
}

body[data-theme="dark"] .artist.queue-team-card:hover,
body[data-theme="dark"] .artist.queue-team-card:focus-within,
body[data-theme="dark"] .artist.queue-team-card.queue-stream-drop-target {
  border-color: rgba(236, 237, 238, 0.7);
  background:
    linear-gradient(135deg, rgba(214, 216, 218, 0.18), transparent 58%),
    var(--daylight-surface-blue);
}

body[data-theme="dark"] .queue-team-avatar-member {
  border-color: var(--daylight-surface-subtle);
}

body[data-theme="dark"] .dashboard-team-icon,
body[data-theme="dark"] .dashboard-team-kicker,
body[data-theme="dark"] .dashboard-team-add-member,
body[data-theme="dark"] .dashboard-team-status[data-state="loading"] {
  color: #d8dadd;
}

body[data-theme="dark"] .dashboard-team-member-marker {
  background: rgba(214, 216, 218, 0.16);
  color: #d8dadd;
}

body[data-theme="dark"] .dashboard-team-stream-option:hover,
body[data-theme="dark"] .dashboard-team-stream-option:focus-within {
  border-color: rgba(236, 237, 238, 0.64);
  background: rgba(214, 216, 218, 0.12);
}

body[data-theme="dark"] .dashboard-team-stream-avatar {
  border-color: rgba(236, 237, 238, 0.42);
  background: rgba(214, 216, 218, 0.12);
}

@media (max-width: 760px) {
  .queue-header-actions {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  }

  .queue-header-actions > .dashboard-team-create-button {
    width: 100%;
  }
}

@media (max-width: 520px) {
  .dashboard-team-form {
    gap: 15px;
    padding: 18px;
  }

  .dashboard-team-member-row {
    grid-template-columns: 30px minmax(0, 1fr) 30px;
    gap: 6px;
  }

  .dashboard-team-member-marker,
  .dashboard-team-remove-member {
    width: 30px;
    height: 30px;
  }

  .dashboard-team-actions button {
    flex: 1 1 0;
  }

  .queue-group-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .queue-group-actions .queue-group-action {
    width: 100%;
  }
}

/* Queue toolbar: keep the title, search, and actions in one predictable row
   on desktop, then let the tools wrap beneath the title on smaller screens. */
.party-queue-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  margin-bottom: 4px;
}

.party-queue-header .section-heading-label {
  flex: 0 0 auto;
  min-width: max-content;
  white-space: nowrap;
}

.party-queue-header .queue-count {
  flex: 0 0 auto;
}

.queue-group--initial {
  padding-top: 4px;
}

.queue-group--secondary {
  padding-top: 14px;
}

.queue-group-heading--secondary {
  align-items: center;
  min-height: 44px;
  margin-bottom: 4px;
}

.queue-group-heading--secondary .section-heading-label {
  min-width: 0;
}

.queue-group-heading--secondary h3 {
  color: var(--daylight-ink-strong);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.2;
}

.queue-group-heading--secondary .queue-count {
  flex: 0 0 auto;
}

.secondary-streams-help {
  margin: 0 0 12px 38px;
  color: var(--daylight-dim);
  font-size: 12px;
  line-height: 1.4;
}

#backupStreams:not(:has(> .backup-stream))::before {
  display: grid;
  min-height: 74px;
  padding: 14px;
  place-items: center;
  grid-column: 1 / -1;
  border: 1px dashed var(--daylight-border-soft);
  border-radius: 9px;
  color: var(--daylight-dim);
  content: "No secondary streams yet.";
  font-size: 12px;
  text-align: center;
}

.queue-header-tools {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.queue-header-actions {
  gap: 6px;
}

.queue-header-search {
  min-width: 0;
}

.queue-header-search .streamer-search-control {
  width: min(286px, 26vw);
  min-width: 190px;
}

#queueBuilder.streamer-search-panel {
  display: grid;
  gap: 6px;
  margin: 0 1px 8px;
  padding: 0;
}

#queueBuilder.streamer-search-panel:has(.streamer-search-status:empty):has(
    .streamer-search-results:empty
  ) {
  display: none;
}

#queueBuilder .streamer-search-status {
  min-height: 0;
  margin: 0;
}

#queueBuilder .streamer-search-results {
  width: 100%;
}

.queue-header-actions .dashboard-team-create-button {
  min-height: 34px;
  height: 34px;
  padding: 0 11px;
  border-radius: 7px;
  box-shadow: 0 2px 6px rgba(31, 42, 78, 0.12);
  font-size: 12px;
}

.queue-header-actions .queue-clear-button {
  display: inline-flex;
  min-height: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 11px;
  border-color: #c28b92;
  border-radius: 7px;
  background: linear-gradient(180deg, #fff7f8 0%, #f2e3e5 100%);
  box-shadow: 0 2px 6px rgba(81, 38, 44, 0.12);
  color: #9e3744;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.queue-header-actions .queue-clear-button i {
  width: 15px;
  color: currentColor;
  font-size: 12px;
  text-align: center;
}

.queue-header-actions .queue-clear-button:hover,
.queue-header-actions .queue-clear-button:focus-visible {
  border-color: #a9505c;
  background: linear-gradient(180deg, #fffafb 0%, #efd1d5 100%);
  box-shadow:
    0 5px 12px rgba(81, 38, 44, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
  color: #812732;
  outline: none;
  transform: translateY(-1px);
}

body[data-theme="dark"] .queue-header-actions .queue-clear-button {
  border-color: #75444a;
  background: linear-gradient(180deg, #3f292d 0%, #2b1d20 100%);
  box-shadow:
    0 2px 7px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  color: #ff9da8;
}

body[data-theme="dark"] .queue-header-actions .queue-clear-button:hover,
body[data-theme="dark"] .queue-header-actions .queue-clear-button:focus-visible {
  border-color: #b76773;
  background: linear-gradient(180deg, #553237 0%, #392126 100%);
  box-shadow:
    0 6px 14px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: #ffd8dc;
}

body[data-theme="dark"] .queue-header-actions .dashboard-team-create-button {
  box-shadow:
    0 2px 7px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.quick-add-card .group-copy h3 {
  white-space: normal;
}

.quick-add-card .group-icon {
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.quick-add-card .quick-add-action {
  min-width: 78px;
  border-color: #9ebcf7;
  background: var(--daylight-surface-blue);
  color: var(--daylight-primary);
}

.quick-add-card .quick-add-action:hover,
.quick-add-card .quick-add-action:focus-visible {
  border-color: var(--daylight-primary);
  background: var(--daylight-primary);
  color: #ffffff;
}

.quick-add-card .quick-add-action:disabled {
  opacity: 0.7;
  cursor: progress;
}

body[data-theme="dark"] .quick-add-card .group-icon,
body[data-theme="dark"] .quick-add-card .quick-add-action {
  border-color: #5b75a8;
  background: #202d45;
  color: #8fb2ff;
}

body[data-theme="dark"] .quick-add-card .quick-add-action:hover,
body[data-theme="dark"] .quick-add-card .quick-add-action:focus-visible {
  border-color: #8fb2ff;
  background: #344d78;
  color: #b0c7ff;
}

@media (max-width: 960px) {
  .party-queue-header {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .queue-header-tools {
    width: 100%;
    justify-content: flex-start;
  }

  .queue-header-search {
    flex: 1 1 260px;
  }

  .queue-header-search .streamer-search-control {
    width: 100%;
  }
}

@media (max-width: 760px) {
  .queue-header-tools,
  .queue-header-actions {
    display: flex;
    width: 100%;
    flex-wrap: wrap;
    grid-template-columns: none;
  }

  .queue-header-search {
    flex: 1 1 100%;
  }

  .queue-header-actions > .dashboard-team-create-button,
  .queue-header-actions > .queue-clear-button {
    flex: 1 1 auto;
  }
}

@media (max-width: 520px) {
  .party-queue-header {
    gap: 10px;
  }

  .secondary-streams-help {
    margin-left: 0;
  }

  .queue-header-tools {
    gap: 8px;
  }

  .queue-header-actions > .dashboard-team-create-button,
  .queue-header-actions > .queue-clear-button {
    flex: 1 1 auto;
  }
}

/* Keep the queue toolbar compact while the main column still has room for a
   single line. The search field gives up width before the whole toolbar wraps. */
@container dashboard-main (max-width: 1180px) {
  .party-queue-header {
    grid-template-columns: max-content minmax(0, 1fr);
    align-items: center;
    gap: 10px;
  }

  .queue-header-tools {
    width: auto;
    justify-content: flex-end;
    flex-wrap: nowrap;
    gap: 6px;
  }

  .queue-header-search {
    flex: 0 1 204px;
    min-width: 0;
  }

  .queue-header-search .streamer-search-control {
    width: clamp(160px, 20cqw, 224px);
    min-width: 160px;
  }
}

@container dashboard-main (max-width: 940px) {
  .party-queue-header {
    grid-template-columns: minmax(0, 1fr);
    align-items: flex-start;
  }

  .queue-header-tools {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    row-gap: 10px;
  }

  .queue-header-search {
    flex: 1 1 220px;
  }

  .queue-header-search .streamer-search-control {
    width: 100%;
  }
}

@container dashboard-main (max-width: 760px) {
  .queue-header-tools,
  .queue-header-actions {
    width: 100%;
  }

  .queue-header-search {
    flex: 1 1 100%;
  }

  .queue-header-actions {
    flex-wrap: wrap;
  }

  .queue-header-actions > .dashboard-team-create-button,
  .queue-header-actions > .queue-clear-button {
    flex: 1 1 auto;
  }
}

/* Watch Party roster import */
.queue-header-actions .watch-party-import-open {
  display: inline-flex;
  min-height: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 11px;
  border-radius: 7px;
  box-shadow: 0 2px 6px rgba(31, 42, 78, 0.12);
  font-size: 12px;
  white-space: nowrap;
}

.queue-header-actions .watch-party-import-open i {
  width: 15px;
  font-size: 12px;
  text-align: center;
}

.watch-party-import-dialog {
  --import-surface: #fbfbfb;
  --import-surface-subtle: #f3f5f6;
  --import-surface-emphasis: #e9edef;
  --import-ink: #343a3f;
  --import-ink-strong: #202428;
  --import-muted: #6b7379;
  --import-border: #d9dee1;
  --import-border-strong: #aeb5ba;
  width: min(720px, calc(100vw - 28px));
  max-width: none;
  max-height: calc(100dvh - 28px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--import-border);
  border-radius: 16px;
  background: var(--import-surface);
  color: var(--import-ink);
  box-shadow: 0 30px 90px rgba(31, 42, 78, 0.34);
}

.watch-party-import-dialog::backdrop {
  background: rgba(7, 12, 23, 0.7);
  backdrop-filter: blur(5px);
}

.watch-party-import-shell {
  display: grid;
  max-height: calc(100dvh - 28px);
  gap: 16px;
  padding: 22px;
  overflow-y: auto;
}

.watch-party-import-header {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 38px;
  align-items: start;
  gap: 12px;
}

.watch-party-import-icon,
.watch-party-import-close {
  display: grid;
  place-items: center;
  border: 1px solid var(--import-border);
  border-radius: 9px;
  background: var(--import-surface-subtle);
}

.watch-party-import-icon {
  width: 44px;
  height: 44px;
  color: #5f686f;
}

.watch-party-import-close {
  width: 38px;
  height: 38px;
  padding: 0;
  color: var(--import-muted);
  font: inherit;
  cursor: pointer;
}

.watch-party-import-close:hover,
.watch-party-import-close:focus-visible {
  border-color: var(--import-border-strong);
  color: var(--import-ink-strong);
  outline: 0;
}

.watch-party-import-close:disabled {
  cursor: wait;
  opacity: 0.5;
}

.watch-party-import-kicker {
  margin: 0 0 3px;
  color: #5f686f;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.watch-party-import-header h2 {
  margin: 0;
  color: var(--import-ink-strong);
  font-size: 22px;
  line-height: 1.15;
}

.watch-party-import-header #watchPartyImportHelp {
  margin: 5px 0 0;
  color: var(--import-muted);
  font-size: 12px;
  line-height: 1.45;
}

.watch-party-import-template {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px;
  border: 1px solid var(--import-border);
  border-radius: 11px;
  background: var(--import-surface-subtle);
}

.watch-party-import-template strong {
  display: block;
  color: var(--import-ink-strong);
  font-size: 12px;
}

.watch-party-import-template p {
  max-width: 390px;
  margin: 4px 0 0;
  color: var(--import-muted);
  font-size: 11px;
  line-height: 1.45;
}

.watch-party-import-template-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: stretch;
  gap: 6px;
}

.watch-party-template-link {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 11px;
  border: 1px solid var(--import-border-strong);
  border-radius: 8px;
  background: var(--import-surface);
  color: var(--import-ink-strong);
  font-size: 11px;
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
}

.watch-party-template-link--quiet {
  border-color: transparent;
  background: transparent;
  color: var(--import-muted);
}

.watch-party-template-link:hover,
.watch-party-template-link:focus-visible {
  border-color: #747d84;
  background: var(--import-surface-emphasis);
  color: var(--import-ink-strong);
  outline: 0;
}

.watch-party-import-dropzone {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 86px;
  padding: 14px 16px;
  border: 1px dashed var(--import-border-strong);
  border-radius: 11px;
  background: color-mix(in srgb, var(--import-surface-subtle) 58%, transparent);
  color: var(--import-ink);
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.watch-party-import-dropzone:hover,
.watch-party-import-dropzone:focus-visible,
.watch-party-import-dropzone.is-dragging {
  border-color: #69737a;
  background: var(--import-surface-emphasis);
  outline: 0;
}

.watch-party-import-dropzone.is-dragging {
  transform: translateY(-1px);
}

.watch-party-import-dialog.is-busy .watch-party-import-dropzone {
  cursor: wait;
  opacity: 0.64;
}

.watch-party-import-file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.watch-party-import-dropzone-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 10px;
  background: var(--import-surface-emphasis);
  color: #5f686f;
  font-size: 17px;
}

.watch-party-import-dropzone-copy {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.watch-party-import-dropzone-copy strong {
  color: var(--import-ink-strong);
  font-size: 13px;
}

.watch-party-import-dropzone-copy small {
  color: var(--import-muted);
  font-size: 11px;
}

.watch-party-import-browse {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--import-border);
  border-radius: 8px;
  background: var(--import-surface);
  color: var(--import-ink-strong);
  font-size: 11px;
  font-weight: 750;
}

.watch-party-import-status {
  min-height: 16px;
  margin: -5px 1px 0;
  color: var(--import-muted);
  font-size: 11px;
  line-height: 1.45;
}

.watch-party-import-status[data-state="loading"] {
  color: #59636a;
}

.watch-party-import-status[data-state="ready"] {
  color: #24744e;
}

.watch-party-import-status[data-state="error"] {
  color: #b42318;
}

.watch-party-import-preview {
  overflow: hidden;
  border: 1px solid var(--import-border);
  border-radius: 11px;
  background: var(--import-surface-subtle);
}

.watch-party-import-preview[hidden] {
  display: none !important;
}

.watch-party-import-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--import-border);
  background: var(--import-surface);
}

.watch-party-import-preview-header > div {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.watch-party-import-preview-header strong,
.watch-party-import-preview-header span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.watch-party-import-preview-header strong {
  color: var(--import-ink-strong);
  font-size: 12px;
}

.watch-party-import-preview-header #watchPartyImportSummary {
  color: var(--import-muted);
  font-size: 10px;
}

.watch-party-import-format {
  flex: 0 0 auto;
  padding: 4px 7px;
  border: 1px solid var(--import-border);
  border-radius: 999px;
  color: var(--import-muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.watch-party-import-slots {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-height: 286px;
  gap: 7px;
  margin: 0;
  padding: 12px;
  overflow-y: auto;
  list-style: none;
}

.watch-party-import-slot {
  display: grid;
  grid-template-columns: 24px 30px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-width: 0;
  min-height: 48px;
  padding: 6px 9px;
  border: 1px solid var(--import-border);
  border-radius: 8px;
  background: var(--import-surface);
}

.watch-party-import-slot-position {
  color: var(--import-muted);
  font-size: 10px;
  font-weight: 800;
  text-align: center;
}

.watch-party-import-slot-icon {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: var(--import-surface-emphasis);
  color: #606a71;
  font-size: 11px;
}

.watch-party-import-slot-icon img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: contain;
}

.watch-party-import-slot-copy {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.watch-party-import-slot-copy strong,
.watch-party-import-slot-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.watch-party-import-slot-copy strong {
  color: var(--import-ink-strong);
  font-size: 11px;
}

.watch-party-import-slot-copy small {
  color: var(--import-muted);
  font-size: 9px;
}

.watch-party-import-slot-more {
  grid-column: 1 / -1;
  padding: 7px;
  color: var(--import-muted);
  font-size: 10px;
  font-weight: 700;
  text-align: center;
}

.watch-party-import-issues {
  padding: 11px 14px 12px;
  border-top: 1px solid var(--import-border);
  background: var(--import-surface);
}

.watch-party-import-issues[hidden] {
  display: none !important;
}

.watch-party-import-issues > strong {
  color: var(--import-ink-strong);
  font-size: 10px;
}

.watch-party-import-issues ul {
  display: grid;
  gap: 4px;
  margin: 7px 0 0;
  padding-left: 18px;
  color: var(--import-muted);
  font-size: 10px;
  line-height: 1.4;
}

.watch-party-import-issues li[data-state="error"] {
  color: #b42318;
}

.watch-party-import-issues li[data-state="warning"] {
  color: #8a5a16;
}

.watch-party-import-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.watch-party-import-actions > p {
  max-width: 390px;
  margin: 0;
  color: var(--import-muted);
  font-size: 10px;
  line-height: 1.45;
}

.watch-party-import-actions > div {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

.watch-party-import-actions button {
  min-height: 40px;
  margin: 0;
  border-radius: 8px;
  font-size: 12px;
}

.watch-party-import-actions .primary-button {
  display: inline-flex;
  min-width: 146px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 15px;
  border: 1px solid #5f686f;
  background: #5f686f;
  color: #ffffff;
  box-shadow: 0 5px 12px rgba(47, 52, 56, 0.2);
  font-weight: 700;
  white-space: nowrap;
}

.watch-party-import-actions .primary-button:hover,
.watch-party-import-actions .primary-button:focus-visible {
  border-color: #4d565c;
  background: #4d565c;
  color: #ffffff;
  outline: 0;
}

.watch-party-import-actions .primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.watch-party-import-dialog.is-busy .watch-party-import-actions .primary-button:disabled {
  cursor: wait;
  opacity: 0.68;
}

body[data-theme="dark"] .watch-party-import-dialog {
  --import-surface: #202020;
  --import-surface-subtle: #272727;
  --import-surface-emphasis: #303030;
  --import-ink: #e7e7e7;
  --import-ink-strong: #f4f4f4;
  --import-muted: #a6a6a6;
  --import-border: #414141;
  --import-border-strong: #686868;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.58);
}

body[data-theme="dark"] .watch-party-import-status[data-state="ready"] {
  color: #79d2a4;
}

body[data-theme="dark"] .watch-party-import-status[data-state="error"],
body[data-theme="dark"] .watch-party-import-issues li[data-state="error"] {
  color: #ff9c95;
}

body[data-theme="dark"] .watch-party-import-issues li[data-state="warning"] {
  color: #e9bd78;
}

body[data-theme="dark"] .queue-header-actions .watch-party-import-open {
  border-color: #686d71;
  background: linear-gradient(180deg, #3d4143 0%, #27292a 100%);
  color: #f1f2f2;
  box-shadow:
    0 2px 7px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

body[data-theme="dark"] .queue-header-actions .watch-party-import-open:hover,
body[data-theme="dark"] .queue-header-actions .watch-party-import-open:focus-visible {
  border-color: #999ea2;
  background: linear-gradient(180deg, #4b4f51 0%, #303335 100%);
  color: #ffffff;
}

@media (max-width: 760px) {
  .queue-header-actions > .watch-party-import-open {
    flex: 1 1 auto;
  }

  .watch-party-import-template,
  .watch-party-import-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .watch-party-import-template-actions,
  .watch-party-import-actions > div {
    width: 100%;
  }

  .watch-party-template-link,
  .watch-party-import-actions button {
    flex: 1 1 0;
  }
}

@media (max-width: 560px) {
  .watch-party-import-shell {
    gap: 14px;
    padding: 18px;
  }

  .watch-party-import-template-actions {
    flex-direction: column;
  }

  .watch-party-import-dropzone {
    grid-template-columns: 38px minmax(0, 1fr);
    padding: 13px;
  }

  .watch-party-import-dropzone-icon {
    width: 38px;
    height: 38px;
  }

  .watch-party-import-browse {
    display: none;
  }

  .watch-party-import-slots {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* -------------------- Selected channel tile layout -------------------- */

/*
 * The queue keeps its existing DOM and drag/drop behavior, but presents each
 * channel as a compact identity tile: index + handle in the top rail, avatar
 * above the name, and a centered live-status footer.  The min-width is tuned
 * so the main workspace can show substantially more channels per row while
 * still giving names and viewer counts room to breathe.
 */
#initialStreams,
#backupStreams {
  grid-template-columns: repeat(auto-fill, minmax(126px, 1fr));
  align-items: stretch;
  gap: 10px;
}

#initialStreams > .artist,
#backupStreams > .backup-stream {
  --channel-tile-surface: #242424;
  --channel-tile-surface-hover: #2c2c2c;
  --channel-tile-border: #444;
  --channel-tile-border-hover: #6a6a6a;
  --channel-tile-ink: #f4f5f5;
  --channel-tile-muted: #a9adae;
  --channel-tile-live: #55e795;
  --channel-tile-offline: #f15b63;
  display: flex;
  width: 100% !important;
  min-width: 0;
  min-height: 148px;
  height: auto;
  aspect-ratio: 0.93 / 1;
  flex: 0 0 auto !important;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  padding: 28px 10px 9px;
  overflow: hidden;
  border: 1px solid var(--channel-tile-border);
  border-radius: 9px;
  background: var(--channel-tile-surface);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.035) inset;
  text-align: center;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

#initialStreams > .artist:hover,
#initialStreams > .artist:focus-within,
#backupStreams > .backup-stream:hover,
#backupStreams > .backup-stream:focus-within {
  border-color: var(--channel-tile-border-hover);
  background: var(--channel-tile-surface-hover);
  box-shadow:
    0 7px 16px rgba(0, 0, 0, 0.2),
    0 1px 0 rgba(255, 255, 255, 0.06) inset;
  transform: translateY(-2px);
}

body[data-theme="light"] #initialStreams > .artist,
body[data-theme="light"] #backupStreams > .backup-stream {
  --channel-tile-surface: #fbfbfb;
  --channel-tile-surface-hover: #f1f4f6;
  --channel-tile-border: #d4d9de;
  --channel-tile-border-hover: #9ebcf7;
  --channel-tile-ink: #202428;
  --channel-tile-muted: #697178;
  --channel-tile-live: #19b77c;
  --channel-tile-offline: #d9485f;
  box-shadow: 0 4px 14px rgba(47, 52, 56, 0.08);
}

#initialStreams > .artist .queue-stream-order,
#backupStreams > .backup-stream .queue-stream-order {
  position: absolute;
  top: 9px;
  left: 10px;
  z-index: 2;
  color: var(--channel-tile-ink);
  font-size: 15px;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  line-height: 1;
  transition:
    opacity 120ms ease,
    transform 120ms ease;
}

#initialStreams > .artist .queue-stream-handle,
#backupStreams > .backup-stream .queue-stream-handle {
  position: absolute;
  top: auto;
  right: 0;
  bottom: 0;
  z-index: 6;
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  padding: 0;
  border: 1px solid #ffe58a;
  border-radius: 8px 0 0 0;
  background: linear-gradient(180deg, #ffe27a 0%, #f2c94c 100%);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.45);
  color: #201a06 !important;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(3px) scale(0.94);
  transition:
    opacity 150ms ease,
    background 150ms ease,
    border-color 150ms ease,
    box-shadow 150ms ease,
    transform 180ms cubic-bezier(0.22, 1, 0.36, 1);
}

#initialStreams > .artist .queue-stream-handle:hover,
#initialStreams > .artist .queue-stream-handle:focus-visible,
#backupStreams > .backup-stream .queue-stream-handle:hover,
#backupStreams > .backup-stream .queue-stream-handle:focus-visible {
  border-color: #fff4bf;
  background: linear-gradient(180deg, #ffed9d 0%, #ffe27a 100%);
  box-shadow:
    0 7px 16px rgba(0, 0, 0, 0.42),
    0 0 0 2px rgba(255, 226, 122, 0.2);
  outline: none;
}

#initialStreams > .artist:hover .queue-stream-handle,
#initialStreams > .artist:focus-within .queue-stream-handle,
#backupStreams > .backup-stream:hover .queue-stream-handle,
#backupStreams > .backup-stream:focus-within .queue-stream-handle {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

#initialStreams > .artist:hover .queue-stream-order,
#initialStreams > .artist:focus-within .queue-stream-order,
#backupStreams > .backup-stream:hover .queue-stream-order,
#backupStreams > .backup-stream:focus-within .queue-stream-order {
  opacity: 0;
  transform: scale(0.86);
}

#initialStreams > .artist .queue-stream-avatar,
#backupStreams > .backup-stream .queue-stream-avatar {
  flex: 0 0 auto;
  width: min(68px, 58%);
  height: auto;
  aspect-ratio: 1;
  margin: 5px auto 7px;
  border: 1px solid #777e7f;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04);
}

#initialStreams
  > .artist.queue-team-card
  .queue-stream-avatar.queue-team-avatar {
  width: min(74px, 64%);
  margin: 2px auto 5px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

#initialStreams > .artist .queue-stream-copy,
#backupStreams > .backup-stream .queue-stream-copy {
  display: flex;
  width: 100%;
  min-width: 0;
  min-height: 18px;
  align-items: center;
  justify-content: flex-start;
  flex-direction: column;
}

#initialStreams > .artist .queue-stream-name,
#backupStreams > .backup-stream .queue-stream-name {
  display: -webkit-box;
  width: 100%;
  overflow: hidden;
  margin: 0;
  color: var(--channel-tile-ink) !important;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.18;
  text-align: center;
  text-overflow: ellipsis;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

/* The status subtitle remains available to assistive technology; the visual
   footer uses the live signal and viewer count as the primary status cue. */
#initialStreams > .artist .queue-stream-subtitle,
#backupStreams > .backup-stream .queue-stream-subtitle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  clip-path: inset(50%);
}

#initialStreams > .artist .queue-stream-signal,
#backupStreams > .backup-stream .queue-stream-signal {
  display: inline-flex;
  width: 100%;
  min-width: 0;
  min-height: 18px;
  margin-top: auto;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding-top: 8px;
  color: var(--channel-tile-muted);
  font-size: 12px;
  line-height: 1;
  text-align: center;
}

#initialStreams > .artist .queue-stream-live-dot,
#backupStreams > .backup-stream .queue-stream-live-dot {
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
}

#initialStreams > .artist .queue-stream-live-dot.is-live,
#backupStreams > .backup-stream .queue-stream-live-dot.is-live {
  background: var(--channel-tile-live);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--channel-tile-live) 16%, transparent);
}

#initialStreams > .artist .queue-stream-viewers,
#backupStreams > .backup-stream .queue-stream-viewers {
  max-width: 100%;
  color: var(--channel-tile-live) !important;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

#initialStreams > .artist .queue-stream-offline-label,
#backupStreams > .backup-stream .queue-stream-offline-label {
  color: var(--channel-tile-offline);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

#initialStreams > .artist .queue-stream-actions,
#backupStreams > .backup-stream .queue-stream-actions {
  inset: 0;
  z-index: 5;
  display: none;
  width: 100%;
  height: 100%;
  pointer-events: none;
  transform: none;
}

#initialStreams > .artist:hover .queue-stream-actions,
#initialStreams > .artist:focus-within .queue-stream-actions,
#backupStreams > .backup-stream:hover .queue-stream-actions,
#backupStreams > .backup-stream:focus-within .queue-stream-actions {
  display: block;
}

#initialStreams > .artist .queue-stream-actions button,
#backupStreams > .backup-stream .queue-stream-actions button {
  position: absolute;
  width: 28px;
  height: 28px;
  border: 1px solid var(--channel-tile-border-hover);
  border-radius: 0;
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  font-size: 12px;
  opacity: 1;
  pointer-events: auto;
  transform: none !important;
}

#initialStreams > .artist .queue-stream-actions .remove-stream-btn,
#backupStreams > .backup-stream .queue-stream-actions .remove-stream-btn {
  inset: 0 auto auto 0;
  border-color: #9c4851;
  border-radius: 0 0 8px 0;
  background: linear-gradient(180deg, #7c3039 0%, #65242c 100%);
  color: #fff;
}

#initialStreams > .artist .queue-stream-actions .edit-team-btn,
#initialStreams > .artist .queue-stream-actions .move-stream-btn,
#backupStreams > .backup-stream .queue-stream-actions .move-stream-btn {
  inset: 0 0 auto auto;
  border-color: var(--channel-tile-border-hover);
  border-radius: 0 0 0 8px;
  background: linear-gradient(180deg, #3b3f40 0%, #2b2e2f 100%);
  color: var(--channel-tile-ink);
}

#initialStreams > .artist .queue-stream-actions .remove-stream-btn:hover,
#initialStreams > .artist .queue-stream-actions .remove-stream-btn:focus-visible,
#backupStreams > .backup-stream .queue-stream-actions .remove-stream-btn:hover,
#backupStreams > .backup-stream .queue-stream-actions .remove-stream-btn:focus-visible {
  border-color: #d06a75;
  background: linear-gradient(180deg, #a43f4b 0%, #7c3039 100%);
  outline: none;
}

#initialStreams > .artist .queue-stream-actions .edit-team-btn:hover,
#initialStreams > .artist .queue-stream-actions .edit-team-btn:focus-visible,
#initialStreams > .artist .queue-stream-actions .move-stream-btn:hover,
#initialStreams > .artist .queue-stream-actions .move-stream-btn:focus-visible,
#backupStreams > .backup-stream .queue-stream-actions .move-stream-btn:hover,
#backupStreams > .backup-stream .queue-stream-actions .move-stream-btn:focus-visible {
  border-color: #858b8d;
  background: linear-gradient(180deg, #505556 0%, #373b3c 100%);
  color: #fff;
  outline: none;
}

#initialStreams > .artist.queue-stream-dragging,
#backupStreams > .backup-stream.queue-stream-dragging {
  transform: scale(0.985);
}

@media (max-width: 720px) {
  #initialStreams,
  #backupStreams {
    grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
    gap: 8px;
  }

  #initialStreams > .artist,
  #backupStreams > .backup-stream {
    min-height: 136px;
    padding-right: 8px;
    padding-left: 8px;
  }

  #initialStreams > .artist .queue-stream-avatar,
  #backupStreams > .backup-stream .queue-stream-avatar {
    width: min(60px, 58%);
  }

  #initialStreams
    > .artist.queue-team-card
    .queue-stream-avatar.queue-team-avatar {
    width: min(68px, 64%);
  }
}

@media (hover: none), (pointer: coarse) {
  #initialStreams > .artist .queue-stream-handle,
  #backupStreams > .backup-stream .queue-stream-handle {
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }

  #initialStreams > .artist .queue-stream-actions,
  #backupStreams > .backup-stream .queue-stream-actions {
    display: block;
  }

  #initialStreams > .artist .queue-stream-order,
  #backupStreams > .backup-stream .queue-stream-order {
    opacity: 0;
  }
}

@media (max-width: 420px) {
  #initialStreams,
  #backupStreams {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
