/* EDL video player — extends walkthrough chrome tokens (P1–P3) */

.edl-player-root {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
}

.edl-player-shell {
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface, #121826);
  box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.16), 0 24px 80px rgba(0, 0, 0, 0.45);
}

.edl-player-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}

.edl-video-stack {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.12s ease-out;
  will-change: transform;
}

.edl-video-stack.is-vertical {
  transform-origin: center center;
}

.edl-video-stack.is-vertical .edl-player-video {
  object-fit: cover;
  width: auto;
  height: 100%;
  max-width: none;
  aspect-ratio: 9 / 16;
}

.edl-video-stack.is-square .edl-player-video {
  object-fit: cover;
  width: 100%;
  height: 100%;
}

.edl-player-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: #000;
  opacity: 0;
  transition: opacity 0.05s linear;
}

.edl-player-video.is-active {
  opacity: 1;
  z-index: 1;
}

.edl-player-video.is-crossfading-in {
  z-index: 2;
}

.edl-overlay-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 5;
}

.edl-overlay-card {
  position: absolute;
  left: 14px;
  bottom: 14px;
  max-width: min(340px, calc(100% - 28px));
  z-index: 6;
}

.edl-overlay-card h2 {
  font-size: clamp(13px, 2.8vw, 17px);
}

.edl-overlay-card p {
  font-size: clamp(12px, 2.4vw, 14px);
}

.edl-overlay-caption {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  max-width: calc(100% - 32px);
  padding: 8px 14px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.72);
  color: #f8fafc;
  font-size: clamp(13px, 2.6vw, 16px);
  line-height: 1.4;
  text-align: center;
  z-index: 6;
}

.edl-overlay-spotlight {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at var(--spot-x, 50%) var(--spot-y, 50%),
    transparent 0,
    transparent var(--spot-r, 18%),
    rgba(0, 0, 0, 0.55) calc(var(--spot-r, 18%) + 2%)
  );
  z-index: 4;
}

.edl-player-caption {
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 6px 10px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.65);
  color: #e8ecf4;
  font-size: 13px;
  pointer-events: none;
  max-width: calc(100% - 24px);
  z-index: 7;
}

.edl-player-caption:empty {
  display: none;
}

.edl-player-caption.is-error {
  background: rgba(127, 29, 29, 0.85);
  color: #fecaca;
}

.edl-player-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: rgba(6, 8, 13, 0.92);
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  flex-wrap: wrap;
}

.edl-btn {
  appearance: none;
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(255, 255, 255, 0.06);
  color: #e8ecf4;
  border-radius: 8px;
  width: 36px;
  height: 32px;
  cursor: pointer;
  font-size: 14px;
}

.edl-btn:hover {
  background: rgba(20, 184, 166, 0.18);
  border-color: rgba(20, 184, 166, 0.45);
}

.edl-time {
  font-size: 13px;
  color: #94a3b8;
  font-variant-numeric: tabular-nums;
  min-width: 88px;
}

.edl-chapter {
  flex: 1;
  font-size: 13px;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 120px;
}

.edl-btn-download {
  width: auto;
  min-width: 36px;
  padding: 0 8px;
  font-size: 13px;
}

.edl-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.edl-bake-status {
  font-size: 12px;
  color: #5eead4;
  min-width: 80px;
  flex: 0 1 auto;
}

.edl-bake-status[hidden] {
  display: none;
}

.edl-scrub {
  flex: 1 1 160px;
  min-width: 120px;
  accent-color: #14b8a6;
}

body.embed-mode .edl-page-header {
  display: none;
}

.edl-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 16px 40px;
}

.edl-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.edl-note {
  margin-top: 14px;
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.5;
}

.edl-note code {
  font-size: 12px;
  background: rgba(255, 255, 255, 0.06);
  padding: 2px 6px;
  border-radius: 4px;
}

.edl-fixture-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.edl-fixture-links a {
  font-size: 12px;
  color: #5eead4;
  text-decoration: none;
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid rgba(94, 234, 212, 0.25);
}

.edl-overlay-caption--vo {
  font-size: clamp(14px, 3vw, 18px);
  font-weight: 600;
  background: rgba(0, 0, 0, 0.78);
  border: 1px solid rgba(94, 234, 212, 0.35);
}

.edl-audio-track {
  display: none;
}
