/* ---------- Asiaflix custom player skin ---------- */

.af-player-wrap {
  position: relative;
  width: 100%;
  background: #000;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
}
#afPlayer { width: 100%; aspect-ratio: 16/9; background: #000; }
.af-player-wrap .jw-controls,
.af-player-wrap .jw-controlbar { display: none !important; }

/* Big center play/pause button -- visible while paused/idle/ended, fades
   out once playback starts (driven by the .af-playing class player.js
   already toggles). */
.af-center-play {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 68px; height: 68px;
  border-radius: 50%;
  background: rgba(229, 9, 20, 0.92);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  z-index: 3;
  box-shadow: 0 10px 28px rgba(229, 9, 20, 0.45);
  transition: opacity .18s ease, transform .18s ease, background-color .18s ease;
}
.af-center-play:hover { background: var(--accent, #3d5afe); transform: translate(-50%, -50%) scale(1.08); }
.af-player-wrap.af-playing .af-center-play { opacity: 0; pointer-events: none; }

.af-controlbar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  background: linear-gradient(to top, rgba(0,0,0,.92) 0%, rgba(0,0,0,.55) 55%, rgba(0,0,0,0) 100%);
  padding: 30px 12px 10px;
  opacity: 1;
  transition: opacity .2s ease;
}
.af-player-wrap:not(:hover) .af-controlbar.af-idle { opacity: 0; }

.af-progress {
  position: relative;
  height: 4px;
  background: rgba(255,255,255,.22);
  border-radius: 3px;
  cursor: pointer;
  margin-bottom: 10px;
  transition: height .12s ease;
}
.af-progress:hover { height: 6px; }
.af-progress-buffer { position: absolute; left:0; top:0; height:100%; background: rgba(255,255,255,.35); border-radius: 3px; width: 0%; }
.af-progress-played {
  position: absolute; left:0; top:0; height:100%;
  background: var(--accent, #3d5afe);
  border-radius: 3px; width: 0%;
  box-shadow: 0 0 8px rgba(229,9,20,.7);
}
.af-progress-handle {
  position: absolute; top: 50%; left: 0%;
  width: 13px; height: 13px; margin-left: -6px; margin-top: -6px;
  background: var(--accent, #3d5afe);
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(229,9,20,.22);
  opacity: 0;
  transition: opacity .12s ease;
}
.af-progress:hover .af-progress-handle { opacity: 1; }
.af-progress-hover {
  position: absolute; bottom: 16px; transform: translateX(-50%);
  background: rgba(15,15,20,.95); color: #fff; font-size: 11px;
  padding: 3px 7px; border-radius: 4px; display: none; pointer-events: none;
  white-space: nowrap; font-weight: 600;
}

.af-controls-row { display: flex; align-items: center; gap: 2px; }
.af-btn {
  background: none; border: none; color: #fff; cursor: pointer;
  font-size: 15px; padding: 8px 9px; border-radius: 50%; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background-color .15s ease, transform .1s ease;
}
.af-btn:hover { background: rgba(255,255,255,.14); }
.af-btn:active { transform: scale(0.92); }

.af-volume { display: flex; align-items: center; gap: 4px; }
.af-volume input[type="range"] { width: 72px; accent-color: var(--accent, #3d5afe); cursor: pointer; }

.af-time { color: #ddd; font-size: 12px; margin: 0 8px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.af-title-inline { color: #9ca3af; font-size: 12px; margin-left: 10px; display: none; font-weight: 600; }
@media (min-width: 720px) { .af-title-inline { display: inline; } }
.af-spacer { flex: 1; }

.af-menu { position: relative; }
.af-menu-btn { display: flex; align-items: center; gap: 6px; font-size: 12px; white-space: nowrap; border-radius: 16px !important; padding: 8px 12px !important; }
.af-menu-list {
  position: absolute; bottom: 42px; right: 0;
  background: rgba(18,18,26,.98);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px; min-width: 140px; padding: 5px;
  display: none; flex-direction: column; max-height: 220px; overflow-y: auto;
  z-index: 5;
  box-shadow: 0 12px 30px rgba(0,0,0,.5);
}
.af-menu:hover .af-menu-list,
.af-menu:focus-within .af-menu-list { display: flex; }
.af-menu-list button {
  background: none; border: none; color: #eee; text-align: left;
  padding: 8px 10px; font-size: 12.5px; border-radius: 5px; cursor: pointer;
}
.af-menu-list button:hover { background: rgba(255,255,255,.1); }
.af-menu-list button.af-active { color: var(--accent, #3d5afe); font-weight: 700; }

.af-player-wrap.af-playing .af-controlbar { opacity: 0; }
.af-player-wrap.af-playing:hover .af-controlbar,
.af-player-wrap.af-playing .af-controlbar:focus-within { opacity: 1; }
