* { box-sizing:border-box; }

body.embed-body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  margin:0;
  padding:0;
  align-items:center;
  justify-content:center;
  color:#fff;
}

/* Rahmen um den Player */
.player-shell {
  width:100%;
  max-width:960px;
}
.player-card {
  background:#000;
  overflow:hidden;
}

/* Header */
.player-header {
  padding:10px 14px;
  font-size:14px;
  border-bottom:1px solid #111827;
  background: #222;
}
.player-header strong {
  font-size:15px;
  color:#f9fafb;
}
.player-header span {
  color:#9ca3af;
}

/* Video-Bereich */
.player-video-wrapper {
  position:relative;
  background:#000;
}
.player-video-wrapper video {
  width:100%;
  height:auto;

  display:block;
  background:#000;
}

/* YouTube-artige Controls */
.player-controls {
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  padding:6px 10px 10px;
  background:linear-gradient(to top, rgba(0,0,0,0.75), rgba(0,0,0,0.0));
  opacity:0;
  pointer-events:none;
  transition:opacity 0.2s ease;
}

/* Controls sichtbar, wenn Wrapper die Klasse .show-controls hat */
.player-video-wrapper.show-controls .player-controls {
  opacity:1;
  pointer-events:auto;
}

/* Wenn NICHT playing (also pausiert/noch nicht gestartet) → immer sichtbar */
.player-video-wrapper:not(.is-playing) .player-controls {
  opacity:1;
  pointer-events:auto;
}


/* Progressbar */
.player-progress {
  width:100%;
  margin-bottom:6px;
}
.player-progress input[type="range"] {
  -webkit-appearance:none;
  appearance:none;
  width:100%;
  height:4px;
  border-radius:999px;
  background:rgba(255,255,255,0.25);
  cursor:pointer;
}
.player-progress input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance:none;
  appearance:none;
  width:12px;
  height:12px;
  border-radius:50%;
  background:#fff;
  margin-top:-2px;
}
.player-progress input[type="range"]::-moz-range-thumb {
  width:12px;
  height:12px;
  border-radius:50%;
  background:#fff;
  border:none;
}

/* untere Leiste */
.player-controls-row {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  font-size:12px;
  color:#e5e7eb;
}
.player-controls-left,
.player-controls-right {
  display:flex;
  align-items:center;
  gap:8px;
}

/* Buttons */
.yt-btn {
  border:none;
  background:transparent;
  color:#f9fafb;
  cursor:pointer;
  font-size:16px;
  padding:4px 6px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:4px;
}
.yt-btn:hover {
  background:rgba(255,255,255,0.1);
}

/* Zeit */
.time-display {
  display:inline-flex;
  align-items:center;
  gap:2px;
  font-variant-numeric:tabular-nums;
}

/* Volume */
.volume-wrapper {
  display:inline-flex;
  align-items:center;
  gap:4px;
}
.volume-wrapper input[type="range"] {
  -webkit-appearance:none;
  appearance:none;
  width:80px;
  height:3px;
  border-radius:999px;
  background:rgba(255,255,255,0.25);
  cursor:pointer;
}
.volume-wrapper input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance:none;
  appearance:none;
  width:10px;
  height:10px;
  border-radius:50%;
  background:#fff;
  margin-top:-1px;
}
.volume-wrapper input[type="range"]::-moz-range-thumb {
  width:10px;
  height:10px;
  border-radius:50%;
  background:#fff;
  border:none;
}

/* Settings / Qualität */
.yt-settings {
  position:relative;
}
.yt-settings-menu {
  position:absolute;
  right:0;
  bottom:32px;
  min-width:180px;
  background: #222;
  border-radius:8px;
  border: 1px solid #2c2c2c;
  box-shadow:0 12px 40px rgba(0,0,0,0.6);
  padding:8px 10px;
  display:none;
  z-index:20;
}
.yt-settings-menu.open,
.yt-settings-menu.open + .dummy { /* fallback falls per JS Class gesetzt */
  display:block;
}
.yt-settings-menu.open {
  display:block;
}
.yt-settings-section {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  font-size:13px;
  color:#e5e7eb;
}
.yt-settings-label {
  white-space:nowrap;
}
.yt-settings select {
  background:#222;
  color:#f9fafb;
  border-radius:4px;
  border:1px solid #2c2c2c;
  padding:4px 6px;
  font-size:12px;
}
.yt-settings select:focus {
  outline:none;
}

/* Footer */
.player-footer {
  padding:8px 14px 10px;
  font-size:12px;
  color:#9ca3af;
  background: #222;
}

/* kleine Screens */
@media (max-width: 600px) {
  .volume-wrapper input[type="range"] {
    width:60px;
  }
  .player-controls-row {
    font-size:11px;
  }
}

/* Fullscreen-Optimierung */
.player-shell:fullscreen {
  width: 100%;
  height: 100%;
  padding: 0;
}

.player-card:fullscreen {
  width: 100%;
  height: 100%;
  border-radius: 0;
}

.player-video-wrapper:fullscreen {
  height: 100%;
}

.player-video-wrapper video:fullscreen {
  max-height: none;
  height: 100%;
}

