.player-overlay {
  z-index: 20;
  padding: 0;
  overflow: hidden;
  background: #08090b;
  place-items: stretch center;
}

.player-v2 {
  position: relative;
  width: min(520px, 100%);
  height: 100dvh;
  overflow: auto;
  background: #fff;
}

.player-stage {
  position: relative;
  height: min(72dvh, 760px);
  min-height: 500px;
  overflow: hidden;
  background: #08090b;
  color: #fff;
}

.player-stage video,
.player-poster {
  width: 100%;
  height: 100%;
}

.player-stage video { display: block; object-fit: contain; background: #08090b; }
.player-poster { background-position: center; background-size: cover; }
.stage-shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(0deg, rgba(7, 8, 11, 0.92), transparent 48%, rgba(7, 8, 11, 0.3)); }

.player-v2 .player-close {
  position: absolute;
  z-index: 4;
  top: calc(16px + env(safe-area-inset-top));
  left: 16px;
  display: grid;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 50%;
  background: rgba(0,0,0,.38);
  color: #fff;
  place-items: center;
}

.stage-title { position: absolute; z-index: 2; right: 18px; bottom: 142px; left: 18px; }
.stage-title span { color: #ffd0df; font-size: 12px; font-weight: 700; }
.stage-title h2 { margin: 6px 0 0; font-size: 22px; }

.transport {
  position: absolute;
  z-index: 3;
  right: 0;
  bottom: 116px;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 34px;
}

.transport button {
  display: flex;
  align-items: center;
  gap: 3px;
  border: 0;
  background: transparent;
  color: #fff;
}

.transport button:disabled { opacity: .36; }
.transport small { font-size: 10px; }
.transport .play-main { display: grid; width: 58px; height: 58px; border: 1px solid rgba(255,255,255,.35); border-radius: 50%; background: rgba(255,255,255,.18); backdrop-filter: blur(10px); place-items: center; }

.player-progress {
  position: absolute;
  z-index: 4;
  right: 78px;
  bottom: 62px;
  left: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 26px;
}
.player-progress input {
  flex: 1;
  min-width: 0;
  height: 26px;
  margin: 0;
  appearance: none;
  outline: 0;
  background: transparent;
  cursor: pointer;
  --progress: 0%;
}
.player-progress input::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, #ff75a6 0 var(--progress), rgba(255,255,255,.34) var(--progress) 100%);
}
.player-progress input::-moz-range-track {
  height: 4px;
  border-radius: 4px;
  background: rgba(255,255,255,.34);
}
.player-progress input::-moz-range-progress { height: 4px; border-radius: 4px; background: #ff75a6; }
.player-progress input::-webkit-slider-thumb {
  width: 13px;
  height: 13px;
  margin-top: -4.5px;
  appearance: none;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #ff75a6;
  box-shadow: 0 1px 5px rgba(0,0,0,.32);
}
.player-progress input::-moz-range-thumb {
  width: 9px;
  height: 9px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #ff75a6;
  box-shadow: 0 1px 5px rgba(0,0,0,.32);
}
.player-progress input:disabled { cursor: default; opacity: .35; }
.player-time { display: inline-flex; flex: 0 0 70px; align-items: center; justify-content: flex-end; gap: 3px; color: rgba(255,255,255,.8); font-size: 10px; font-variant-numeric: tabular-nums; text-shadow: 0 1px 3px rgba(0,0,0,.65); }
.player-time b { color: #fff; font-weight: 600; }
.player-time i { color: rgba(255,255,255,.45); font-style: normal; }

.stage-bottom {
  position: absolute;
  z-index: 3;
  right: 15px;
  bottom: calc(15px + env(safe-area-inset-bottom));
  left: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.episode-picker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 5px;
  background: rgba(0,0,0,.4);
  color: #fff;
  font-size: 12px;
}

.auto-next { display: inline-flex; align-items: center; gap: 5px; color: #d4d5d8; font-size: 10px; }
.player-meta-v2 { display: flex; gap: 18px; padding: 18px 16px 24px; }
.player-meta-v2 > div { flex: 1; min-width: 0; }
.player-meta-v2 h3 { margin: 7px 0; font-size: 18px; }
.player-meta-v2 p { margin: 0; color: #777b84; font-size: 12px; line-height: 1.6; }
.player-meta-v2 .favorite { flex: 0 0 auto; }
.player-social { flex: 0 0 auto; display: flex; align-items: flex-start; gap: 5px; }
.player-social button { display: grid; min-width: 34px; min-height: 38px; padding: 4px; border: 0; border-radius: 5px; background: #f5f5f7; color: #777b84; place-items: center; }
.player-social button.active { background: #fff0f5; color: var(--rose); }
.player-social small { font-size: 8px; line-height: 1; }
.player-comments { padding: 0 16px 24px; border-top: 8px solid #f6f6f7; }
.player-comments > header { min-height: 54px; display: flex; align-items: center; justify-content: space-between; }
.player-comments h3 { margin: 0; font-size: 15px; }
.player-comments > header button { display: grid; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 50%; background: #f1f2f4; color: #757983; place-items: center; }
#drama-comment { display: grid; grid-template-columns: minmax(0,1fr) 40px; gap: 7px; margin-bottom: 10px; }
#drama-comment input { min-width: 0; height: 40px; padding: 0 10px; border: 1px solid #dedfe3; border-radius: 5px; outline: 0; font: inherit; font-size: 12px; }
#drama-comment input:focus { border-color: #ff9cbd; box-shadow: 0 0 0 3px #fff0f5; }
#drama-comment button { display: grid; border: 0; border-radius: 5px; background: var(--rose); color: #fff; place-items: center; }
.comment-login { width: 100%; min-height: 40px; margin-bottom: 10px; border: 1px solid #e2e3e7; border-radius: 5px; background: #fff; color: #555a64; font-size: 12px; }
.comment-list { display: grid; }
.comment-list article { display: grid; grid-template-columns: 32px minmax(0,1fr); gap: 9px; padding: 11px 0; border-bottom: 1px solid #eceef1; }
.comment-list article > span { display: grid; width: 32px; height: 32px; border-radius: 50%; background: #fff0f5; color: #bd3e6c; font-size: 11px; font-weight: 700; place-items: center; }
.comment-list article > div { min-width: 0; }
.comment-list article header { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.comment-list article b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.comment-list article small { flex: 0 0 auto; color: #a0a3aa; font-size: 8px; }
.comment-list article p { margin: 5px 0 0; color: #5f636d; font-size: 11px; line-height: 1.55; overflow-wrap: anywhere; }
.no-comments { margin: 0; padding: 24px 0; color: #92969f; font-size: 11px; text-align: center; }

.episode-drawer {
  position: fixed;
  z-index: 7;
  right: 0;
  bottom: 0;
  left: 50%;
  width: min(520px, 100%);
  max-height: 58dvh;
  padding: 18px 16px calc(22px + env(safe-area-inset-bottom));
  overflow: auto;
  border-radius: 8px 8px 0 0;
  background: #fff;
  box-shadow: 0 -16px 50px rgba(0,0,0,.28);
  transform: translate(-50%, 105%);
  transition: transform .22s ease;
}

.episode-drawer.open { transform: translate(-50%, 0); }
.episode-drawer header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.episode-drawer header div { display: grid; gap: 4px; }
.episode-drawer header span { color: #90949d; font-size: 11px; }
.episode-drawer header button { display: grid; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; background: #f1f2f4; place-items: center; }
.episode-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 9px; }
.episode-grid button { display: grid; min-width: 0; height: 55px; padding: 7px 3px; border: 1px solid #e7e8eb; border-radius: 5px; background: #fafbfc; color: #333740; place-items: center; }
.episode-grid button.current { border-color: #fe86ae; background: #fff0f5; color: var(--rose); }
.episode-grid button.locked { color: #6f737d; }
.episode-grid b { font-size: 13px; }
.episode-grid span { display: flex; align-items: center; gap: 3px; color: #9397a0; font-size: 8px; }
.empty-episodes { grid-column: 1 / -1; padding: 26px 0; color: #8b8f98; text-align: center; font-size: 12px; }

.player-loading { display: grid; background: #101116; color: #fff; place-content: center; justify-items: center; }
.player-loading p { color: #b9bbc2; font-size: 12px; }
.loading-ring { width: 34px; height: 34px; border: 3px solid rgba(255,255,255,.18); border-top-color: var(--rose); border-radius: 50%; animation: spin .8s linear infinite; }

.unlock-overlay { z-index: 30; }
.unlock-modal { text-align: center; }
.unlock-icon { display: grid; width: 52px; height: 52px; margin: 0 auto 14px; border-radius: 50%; background: #fff0f5; color: var(--rose); place-items: center; }
.unlock-modal h2 { margin: 0 0 8px; }
.unlock-modal > p { margin: 0 0 18px; color: #777b84; font-size: 12px; line-height: 1.6; }
.unlock-balance { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; padding: 13px 14px; border: 1px solid #eceef1; border-radius: 6px; background: #fafbfc; font-size: 12px; }
.unlock-balance b { color: var(--rose); }
.secondary-pay { width: 100%; min-height: 42px; margin-top: 9px; border: 1px solid #e1e3e7; border-radius: 6px; background: #fff; color: #4c5059; }

@keyframes spin { to { transform: rotate(360deg); } }

@media (max-height: 680px) {
  .player-stage { min-height: 440px; height: 72dvh; }
}

/* Immersive short-video controls */
.shell { position: relative; }
.topbar { padding-right: 84px; }
.global-language {
  position: absolute;
  z-index: 9;
  top: calc(15px + env(safe-area-inset-top));
  right: 16px;
  display: flex;
  height: 31px;
  padding: 3px;
  border: 1px solid #e4e5e9;
  border-radius: 16px;
  background: rgba(255,255,255,.94);
  box-shadow: 0 4px 14px rgba(24,25,31,.08);
  backdrop-filter: blur(12px);
}
.global-language button {
  min-width: 31px;
  padding: 0 7px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: #858993;
  font-size: 10px;
  font-weight: 700;
}
.global-language button.selected { background: #20232d; color: #fff; }
.language-row { display: none; }

.player-social {
  position: absolute;
  z-index: 5;
  top: 45%;
  right: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 13px;
  transform: translateY(-22%);
}
.player-social button {
  display: grid;
  width: 48px;
  min-width: 48px;
  height: 48px;
  min-height: 48px;
  padding: 5px;
  border: 0;
  border-radius: 50%;
  background: rgba(12,13,17,.36);
  color: #fff;
  box-shadow: 0 3px 16px rgba(0,0,0,.18);
  text-shadow: 0 1px 4px rgba(0,0,0,.8);
  backdrop-filter: blur(8px);
  place-items: center;
}
.player-social button.active { background: rgba(254,91,146,.9); color: #fff; }
.player-social small { color: inherit; font-size: 9px; line-height: 1; }
.stage-title { right: 76px; }
.player-meta-v2 { min-height: 122px; }
.player-meta-v2 > div:first-child { padding-right: 0; }
.player-stage.is-playing .transport { opacity: 0; pointer-events: none; }
.transport { transition: opacity .2s ease; }
.play-hint {
  position: absolute;
  z-index: 6;
  top: 50%;
  left: 50%;
  display: grid;
  width: 72px;
  height: 72px;
  border: 1px solid rgba(255,255,255,.3);
  border-radius: 50%;
  background: rgba(10,11,14,.48);
  color: #fff;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%,-50%) scale(.72);
  backdrop-filter: blur(8px);
  place-items: center;
}
.play-hint.show { animation: player-hint .65s ease both; }
.player-stage.video-landscape video,
.player-stage.video-portrait video,
.player-stage.video-square video { object-fit: contain; object-position: center; }
.player-v2:fullscreen,
.player-v2:-webkit-full-screen { width: 100%; height: 100%; overflow: hidden; background: #08090b; }
.player-v2:fullscreen .player-stage,
.player-v2:-webkit-full-screen .player-stage { width: 100%; height: 100dvh; min-height: 100dvh; max-height: none; }
.player-v2:fullscreen .player-comments,
.player-v2:-webkit-full-screen .player-comments { display: none; }
.player-v2:fullscreen .player-meta-v2 > div:first-child,
.player-v2:-webkit-full-screen .player-meta-v2 > div:first-child { display: none; }
@keyframes player-hint {
  0% { opacity: 0; transform: translate(-50%,-50%) scale(.72); }
  20% { opacity: 1; transform: translate(-50%,-50%) scale(1); }
  72% { opacity: 1; transform: translate(-50%,-50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%,-50%) scale(1.12); }
}
@media (max-width: 420px) {
  .player-social { right: 8px; }
  .player-social button { width: 44px; min-width: 44px; height: 44px; min-height: 44px; }
  .stage-title { right: 64px; }
  .player-progress { right: 72px; left: 12px; gap: 7px; }
  .player-time { flex-basis: 64px; font-size: 9px; }
}
