/* Shared stream player overlay controls */

/* Overlay */
.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0.7) 0%,
    transparent 20%,
    transparent 80%,
    rgba(0,0,0,0.8) 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  z-index: 10;
}

.video-container:hover .video-overlay,
.video-player-container:hover .video-overlay {
  opacity: 1;
}

/* Top controls */
.top-controls {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 15px 20px;
  pointer-events: auto;
}

.stream-info-top { flex: 1; }

.stream-title {
  color: #fff;
  font-weight: 600;
  text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.stream-viewers {
  color: #fff;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(0,0,0,0.5);
  padding: 4px 8px;
  border-radius: 15px;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
}

.top-right-controls { display: flex; gap: 10px; }

/* Center controls */
.center-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  pointer-events: auto;
}

.play-pause-btn {
  background: rgba(0,0,0,0.8);
  border: 2px solid rgba(255,255,255,0.3);
  color: #fff;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.play-pause-btn:hover {
  background: rgba(0,0,0,0.9);
  border-color: rgba(255,255,255,0.6);
  transform: scale(1.08);
}

/* Bottom controls */
.bottom-controls { padding: 10px 20px; pointer-events: auto; }
.progress-container { margin-bottom: 10px; }

.progress-bar {
  width: 100%;
  height: 4px;
  background: rgba(255,255,255,0.3);
  border-radius: 3px;
  position: relative;
  cursor: pointer;
}

.progress-filled {
  height: 100%;
  background: linear-gradient(90deg, #ff6b6b, #4ecdc4);
  border-radius: 3px;
  width: 0%;
  transition: width 0.2s ease;
}

.progress-handle {
  position: absolute;
  top: 50%;
  left: 0%;
  width: 14px;
  height: 14px;
  background: #fff;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.progress-bar:hover .progress-handle { opacity: 1; }

.bottom-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.time-display {
  color: #fff;
  font-weight: 600;
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 15px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

.quality-selector { display: flex; align-items: center; gap: 10px; position: relative; }
.bottom-info .section-logo { height: 40px; margin: 0 10px; border-radius: 4px; }

/* Responsive: mobile alignment fixes */
@media (max-width: 768px) {
  .top-controls {
    padding: 10px 12px;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .stream-title { font-size: 16px; }
  .stream-viewers { font-size: 12px; }

  .center-controls { margin: 6px 0; }
  .play-pause-btn { width: 60px; height: 60px; font-size: 24px; }

  .bottom-controls { padding: 10px 12px; }
  .progress-container { margin-bottom: 8px; }
  .progress-bar { height: 6px; }
  .progress-handle { width: 12px; height: 12px; }

  .bottom-info {
    flex-wrap: wrap;
    gap: 8px;
  }
  .bottom-info .section-logo { height: 28px; margin: 4px 8px; }
  .time-display { font-size: 11px; padding: 4px 10px; }
  .quality-selector { gap: 8px; }
}