/* Stream Wrapper - Desktop default (1000x553) */
.stream-wrapper {
  width: 100%;
  max-width: 1000px;
  height: 553px;
  background-color: #000;
  position: relative;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 0.5rem;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
}

/* Player video element */
.stream-wrapper video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background-color: #000;
}

/* Quality badge (top-left corner) */
#qualityBadge {
  z-index: 11;
  font-size: 0.9rem;
  padding: 0.4em 0.6em;
}

/* Floating controls (bottom-right) */
.floating-controls {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  z-index: 10;
  display: flex;
  gap: 0.5rem;
  transition: opacity 0.3s ease;
}

/* Shortcut button (bottom-left) */
.floating-shortcut {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  z-index: 10;
}

/* Arrows (middle left/right) */
.navigation-arrow {
  font-size: 1.5rem;
  padding: 0.5rem 0.75rem;
}

/* Toast animation */
.toast.fade-custom {
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.toast.fade-custom.show {
  opacity: 1;
  transform: translateY(0);
}

/* RESPONSIVE: Mobile & Tablet */
@media (max-width: 991px) {
  .stream-wrapper {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }

  .stream-wrapper video {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
  }

  .floating-controls,
  .floating-shortcut {
    bottom: 0.5rem !important;
    transform: translateX(0) !important;
  }

  .floating-controls {
    right: 0.5rem !important;
    left: auto !important;
    flex-direction: row;
    gap: 0.5rem;
  }

  .floating-shortcut {
    left: 0.5rem !important;
  }

  .navigation-arrow {
    font-size: 1.25rem;
    padding: 0.3rem 0.6rem;
  }

  /* Auto-hide controls after 4s no interaction */
  .auto-hide {
    opacity: 0;
    pointer-events: none;
  }
}

/* RESPONSIVE: Ultra-wide screens (TVs / Consoles) */
@media (min-width: 1920px) and (orientation: landscape) {
  .stream-wrapper {
    width: 80%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}
