:root {
  --bg: #0b0c10;
  --bg-elev: #14161d;
  --bg-card: #191c26;
  --bg-glass: rgba(15, 17, 24, 0.82);
  --fg: #f3f4f6;
  --fg-2: #cbd5e1;
  --fg-3: #8b95a5;
  --accent: #ff2a5f;
  --accent-hover: #ff4775;
  --accent-soft: rgba(255, 42, 95, 0.16);
  --border: rgba(255, 255, 255, 0.08);
  --radius: 12px;
  --radius-sm: 8px;
  --hdr-h: 64px;
  --max-w: 1240px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body.player-open {
  overflow: hidden;
  touch-action: none;
}

a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
img { display: block; max-width: 100%; }
#app:focus { outline: none; }

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 20px 16px 88px;
}

.hdr {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--hdr-h);
  background: rgba(11, 13, 19, 0.84);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transition: border-color 0.25s, background 0.25s, box-shadow 0.25s;
}

.hdr.scrolled {
  background: rgba(9, 11, 16, 0.96);
  border-bottom-color: rgba(255, 42, 95, 0.24);
  box-shadow: 0 6px 28px rgba(0, 0, 0, 0.55);
}

.hdr-inner {
  max-width: var(--max-w);
  height: 100%;
  margin: 0 auto;
  padding: 0 18px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
  cursor: pointer;
  user-select: none;
}

.brand:hover .brand-logo {
  transform: scale(1.06);
  box-shadow: 0 6px 22px rgba(255, 42, 95, 0.55);
}

.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #ff2a5f 0%, #ff6b4a 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(255, 42, 95, 0.4);
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease;
}

.brand-logo svg {
  width: 18px;
  height: 18px;
  fill: #fff;
  margin-left: 2px;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

.brand-words {
  display: flex;
  flex-direction: column;
  line-height: 1.12;
}

.brand-text {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.4px;
  color: #fff;
}

.brand-text b {
  color: #ff2a5f;
  background: linear-gradient(135deg, #ff2a5f 20%, #ff7e5f 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-sub {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 1px;
}

.nav { display: flex; align-items: center; gap: 6px; }
.nav--desktop { display: flex; align-items: center; gap: 8px; }
.nav--mobile { display: none; }
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 15px;
  border-radius: 99px;
  font-size: 14px;
  font-weight: 600;
  color: var(--fg-3);
  border: 1px solid transparent;
  transition: color 0.18s, background 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.nav-link svg { width: 18px; height: 18px; fill: currentColor; }
.nav-link:hover {
  color: var(--fg);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.09);
}
.nav-link.active {
  background: rgba(255, 42, 95, 0.14);
  color: #ff3b6d;
  border-color: rgba(255, 42, 95, 0.28);
  box-shadow: 0 2px 12px rgba(255, 42, 95, 0.15);
}

.searchwrap { position: relative; margin-left: auto; width: 100%; max-width: 340px; }
.search-form { position: relative; display: flex; align-items: center; }
.search-ic {
  position: absolute;
  left: 14px;
  width: 17px;
  height: 17px;
  fill: none;
  stroke: var(--fg-3);
  stroke-width: 2.2;
  stroke-linecap: round;
  pointer-events: none;
  transition: stroke 0.2s;
}
.search-input {
  width: 100%;
  height: 40px;
  padding: 0 36px 0 40px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 99px;
  font-size: 13.5px;
  color: var(--fg);
  outline: none;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.search-input:focus {
  border-color: var(--accent);
  background: rgba(24, 27, 36, 0.95);
  box-shadow: 0 0 0 3px rgba(255, 42, 95, 0.18);
}
.search-form:focus-within .search-ic {
  stroke: var(--accent);
}
.search-input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
.search-clear {
  position: absolute;
  right: 8px;
  width: 24px;
  height: 24px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--fg-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.search-clear[hidden] { display: none !important; }
.search-clear svg { width: 13px; height: 13px; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }

.recent-pop {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  z-index: 120;
}
.recent-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--fg-3);
}
.recent-clear { background: none; border: 0; color: var(--accent); font-size: 12px; cursor: pointer; }
.recent-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  font-size: 13.5px;
  cursor: pointer;
  transition: background 0.15s;
}
.recent-row:hover, .recent-row:focus { background: rgba(255, 255, 255, 0.05); outline: none; }
.recent-row > svg { width: 15px; height: 15px; fill: none; stroke: var(--fg-3); stroke-width: 2; flex-shrink: 0; }
.recent-row .q { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent-row .x {
  width: 22px;
  height: 22px;
  border: 0;
  background: transparent;
  color: var(--fg-3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
}
.recent-row .x:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.recent-row .x svg { width: 12px; height: 12px; stroke: currentColor; stroke-width: 2; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 20px;
  border-radius: 99px;
  border: 0;
  background: var(--accent);
  color: #fff;
  font-size: 14.5px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s, background 0.15s;
}
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: scale(0.97); }
.btn svg { width: 18px; height: 18px; fill: currentColor; }
.btn svg.icon-stroke { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.btn--ghost { background: rgba(255, 255, 255, 0.1); color: var(--fg); border: 1px solid rgba(255, 255, 255, 0.12); }
.btn--ghost:hover { background: rgba(255, 255, 255, 0.16); }
.btn--on { background: var(--accent-soft); color: var(--accent); border-color: rgba(255, 42, 95, 0.4); }
.btn--icon { width: 44px; padding: 0; }
.btn--sm { height: 36px; padding: 0 15px; font-size: 13px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips--scroll { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chips--scroll::-webkit-scrollbar { display: none; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  border-radius: 99px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  font-size: 13px;
  font-weight: 600;
  color: var(--fg-2);
  white-space: nowrap;
  transition: all 0.15s;
}
.chip:hover { border-color: rgba(255, 255, 255, 0.22); color: #fff; }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.chip .n { font-size: 11px; opacity: 0.75; background: rgba(0, 0, 0, 0.25); padding: 1px 6px; border-radius: 99px; }

.hero {
  position: relative;
  min-height: 390px;
  max-width: var(--max-w);
  margin: 12px auto 8px;
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  background: var(--bg-card);
}
.hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  filter: brightness(0.65);
  transform: scale(1.03);
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--bg) 4%, rgba(11, 12, 16, 0.65) 55%, rgba(11, 12, 16, 0.2) 100%),
              linear-gradient(90deg, rgba(11, 12, 16, 0.92) 0%, rgba(11, 12, 16, 0.2) 70%);
}
.hero-body { position: relative; z-index: 2; padding: 28px 24px; max-width: 620px; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 99px;
  background: rgba(255, 42, 95, 0.22);
  border: 1px solid rgba(255, 42, 95, 0.45);
  color: #ff6b8e;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 10px;
}
.badge svg { width: 13px; height: 13px; fill: currentColor; }
.hero-body h1 { font-size: clamp(22px, 3.5vw, 34px); font-weight: 800; line-height: 1.18; margin-bottom: 8px; }
.hero-body .sub { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 13.5px; color: var(--fg-2); margin-bottom: 12px; }
.hero-body .sub i { width: 4px; height: 4px; border-radius: 50%; background: var(--fg-3); }
.hero-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.hero-chips:empty { display: none; }
.hero-chips span { font-size: 11.5px; padding: 3px 9px; border-radius: 6px; background: rgba(255, 255, 255, 0.1); color: var(--fg-2); }
.hero-body .row { display: flex; align-items: center; gap: 10px; }

.sec { margin-top: 28px; }
.sec-hd { display: flex; align-items: baseline; gap: 10px; margin-bottom: 14px; }
.sec-hd h2 { font-size: 18px; font-weight: 800; letter-spacing: -0.2px; }
.sec-hd .meta { font-size: 12.5px; color: var(--fg-3); }
.sec-more { margin-left: auto; font-size: 13px; font-weight: 600; color: var(--accent); }

.hrow { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.hrow::-webkit-scrollbar { display: none; }
.hrow > * { scroll-snap-align: start; flex-shrink: 0; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 16px 12px; }
.card { display: flex; flex-direction: column; width: 100%; }
.hrow .card { width: 142px; }
.card-poster {
  position: relative;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-card);
  margin-bottom: 7px;
  border: 1px solid var(--border);
}
.card-poster img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.card:hover .card-poster img { transform: scale(1.05); }
.card-ep, .poster-ep {
  position: absolute;
  bottom: 6px;
  right: 6px;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(11, 12, 16, 0.82);
  backdrop-filter: blur(4px);
  font-size: 11px;
  font-weight: 700;
  color: #fff;
}
.card-src-badge {
  position: absolute;
  top: 6px;
  left: 6px;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--accent);
  font-size: 10.5px;
  font-weight: 700;
  color: #fff;
}
.card-title {
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-src { font-size: 11.5px; color: var(--fg-3); margin-top: 2px; text-transform: capitalize; }

.wcard {
  width: 220px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.wcard-thumb { position: relative; aspect-ratio: 16 / 9; background: var(--bg-card); overflow: hidden; }
.wcard-thumb img { width: 100%; height: 100%; object-fit: cover; }
.wcard-play { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.35); display: flex; align-items: center; justify-content: center; }
.wcard-play i { width: 38px; height: 38px; border-radius: 50%; background: rgba(255, 42, 95, 0.9); display: flex; align-items: center; justify-content: center; }
.wcard-play svg { width: 18px; height: 18px; fill: #fff; margin-left: 2px; }
.wcard-bar { height: 3px; background: rgba(255, 255, 255, 0.12); }
.wcard-bar i { display: block; height: 100%; background: var(--accent); }
.wcard-cap { padding: 9px 11px; font-size: 12px; color: var(--fg-3); display: flex; flex-direction: column; gap: 2px; }
.wcard-cap b { font-size: 13px; color: var(--fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.rcard { width: 162px; display: flex; flex-direction: column; }
.rcard-top { position: relative; display: flex; align-items: flex-end; margin-bottom: 7px; }
.rcard .rank {
  font-size: 56px;
  font-weight: 900;
  line-height: 0.85;
  letter-spacing: -3px;
  color: transparent;
  -webkit-text-stroke: 2px rgba(255, 255, 255, 0.35);
  margin-right: -12px;
  z-index: 2;
  user-select: none;
}
.rcard .poster { position: relative; flex: 1; aspect-ratio: 2 / 3; border-radius: var(--radius); overflow: hidden; background: var(--bg-card); border: 1px solid var(--border); }
.rcard .poster img { width: 100%; height: 100%; object-fit: cover; }
.rcard-sub { font-size: 11px; color: var(--accent); font-weight: 600; text-transform: capitalize; }
.rcard-cap { font-size: 13.5px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.note { margin-top: 36px; text-align: center; font-size: 12px; color: var(--fg-3); line-height: 1.6; }

.dtl { position: relative; border-radius: 18px; background: var(--bg-elev); border: 1px solid var(--border); padding: 24px; overflow: hidden; }
.dtl-bg { position: absolute; inset: 0; opacity: 0.16; filter: blur(28px); pointer-events: none; }
.dtl-bg img { width: 100%; height: 100%; object-fit: cover; }
.dtl-top { position: relative; z-index: 1; display: flex; gap: 22px; align-items: flex-start; }
.dtl-poster { width: 150px; aspect-ratio: 2 / 3; border-radius: var(--radius); overflow: hidden; flex-shrink: 0; background: var(--bg-card); box-shadow: 0 10px 28px rgba(0, 0, 0, 0.5); }
.dtl-poster img { width: 100%; height: 100%; object-fit: cover; }
.dtl-info { flex: 1; min-width: 0; }
.dtl-info h1 { font-size: clamp(20px, 3vw, 28px); font-weight: 800; line-height: 1.25; margin-bottom: 8px; }
.dtl-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--fg-2); margin-bottom: 12px; text-transform: capitalize; }
.dtl-meta i { width: 4px; height: 4px; border-radius: 50%; background: var(--fg-3); }
.dtl-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.dtl-actions { display: flex; align-items: center; gap: 10px; }
.syn { position: relative; z-index: 1; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--border); font-size: 14px; color: var(--fg-2); }
.syn p.clamped { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.syn-more { margin-top: 6px; background: none; border: 0; color: var(--accent); font-size: 13px; font-weight: 600; cursor: pointer; }

.eps { display: grid; grid-template-columns: repeat(auto-fill, minmax(54px, 1fr)); gap: 8px; }
.ep { height: 44px; border-radius: var(--radius-sm); background: var(--bg-elev); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 600; transition: all 0.15s; }
.ep:hover { border-color: var(--accent); color: #fff; }
.ep--seen { opacity: 0.55; }
.ep--now { background: var(--accent); border-color: var(--accent); color: #fff; }
.ep--locked::after { content: "🔒"; font-size: 10px; position: absolute; top: 3px; right: 4px; }
.eps-foot { margin-top: 16px; }

.pl { position: fixed; inset: 0; z-index: 500; background: #000; display: flex; align-items: center; justify-content: center; user-select: none; }
.pl video {
  width: 100%;
  height: 100%;
  max-width: 540px;
  object-fit: contain;
  background: #000;
  transform: translateZ(0);
  will-change: transform;
}
.pl-scrim { position: absolute; left: 0; right: 0; pointer-events: none; transition: opacity 0.25s; }
.pl-scrim--top { top: 0; height: 110px; background: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent); }
.pl-scrim--bot { bottom: 0; height: 160px; background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), transparent); }
.pl-ui { position: absolute; inset: 0; pointer-events: none; transition: opacity 0.25s; }
.pl.chrome-hidden .pl-ui, .pl.chrome-hidden .pl-scrim { opacity: 0; }
.pl-ui button, .pl-ui [role="slider"] { pointer-events: auto; }
.pl-top { position: absolute; top: env(safe-area-inset-top, 12px); left: 12px; right: 12px; display: flex; align-items: center; gap: 10px; padding-top: 8px; }
.pl-btn, .pl-nav { width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, 0.45); backdrop-filter: blur(8px); color: #fff; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.pl-btn.active { background: var(--accent); color: #fff; }
.pl-btn[hidden] { display: none !important; }
.pl-ic, .pl-nav svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.pl-ic--play, .pl-ic--pause { fill: currentColor; stroke: none; }
.pl.playing .pl-ic--play { display: none; }
.pl:not(.playing) .pl-ic--pause { display: none; }
.pl.muted .pl-ic--vol { display: none; }
.pl:not(.muted) .pl-ic--muted { display: none; }
.pl-head { min-width: 0; flex: 1; }
.pl-title { font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 4px rgba(0,0,0,0.8); }
.pl-ep { font-size: 12.5px; color: var(--fg-2); }
.pl-rail { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 12px; }
.pl-center { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 64px; height: 64px; border-radius: 50%; border: 0; background: rgba(255, 42, 95, 0.88); color: #fff; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: opacity 0.2s, transform 0.2s; }
.pl.playing .pl-center { opacity: 0; pointer-events: none; }
.pl-bottom { position: absolute; left: 14px; right: 14px; bottom: calc(env(safe-area-inset-bottom, 0px) + 14px); max-width: 680px; margin: 0 auto; }
.pl-seek { padding: 10px 0; cursor: pointer; touch-action: none; }
.pl-seek-track { position: relative; height: 4px; border-radius: 99px; background: rgba(255, 255, 255, 0.24); }
.pl-seek-buf { position: absolute; left: 0; top: 0; bottom: 0; width: 0%; background: rgba(255, 255, 255, 0.4); border-radius: 99px; }
.pl-seek-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0%; background: var(--accent); border-radius: 99px; }
.pl-seek-knob { position: absolute; top: 50%; left: 0%; width: 13px; height: 13px; border-radius: 50%; background: #fff; transform: translate(-50%, -50%); box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5); }
.pl-ctrls { display: flex; align-items: center; gap: 10px; }
.pl-time { font-size: 13px; color: var(--fg-2); font-variant-numeric: tabular-nums; }
.pl-grow { flex: 1; }
.pl-unmute { position: absolute; top: 76px; left: 50%; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 99px; border: 0; background: rgba(0, 0, 0, 0.78); color: #fff; font-size: 13px; font-weight: 600; cursor: pointer; }
.pl-unmute[hidden], .pl-nextup[hidden], .pl-sheet[hidden], .pl-status[hidden] { display: none !important; }
.pl-unmute svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; }
.pl-flash { position: absolute; top: 50%; transform: translateY(-50%); padding: 8px 14px; border-radius: 99px; background: rgba(0, 0, 0, 0.65); font-size: 13px; font-weight: 700; opacity: 0; transition: opacity 0.2s; pointer-events: none; }
#pl-flash-l { left: 24px; }
#pl-flash-r { right: 24px; }
.pl-flash.show { opacity: 1; }
.pl-status { position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; background: rgba(0, 0, 0, 0.55); text-align: center; padding: 20px; }
.spinner { width: 38px; height: 38px; border: 3px solid rgba(255, 255, 255, 0.2); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.75s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.pl-nextup { position: absolute; bottom: 96px; right: 16px; z-index: 15; padding: 10px 18px; border-radius: 99px; border: 0; background: var(--accent); color: #fff; font-weight: 700; font-size: 13.5px; cursor: pointer; box-shadow: 0 6px 20px rgba(255, 42, 95, 0.45); }
.pl-sheet { position: absolute; inset: 0; z-index: 30; background: rgba(0, 0, 0, 0.6); display: flex; align-items: flex-end; justify-content: center; }
.pl-sheet-panel { width: 100%; max-width: 560px; max-height: 70vh; background: var(--bg-elev); border-radius: 20px 20px 0 0; display: flex; flex-direction: column; overflow: hidden; }
.pl-sheet-hd { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-bottom: 1px solid var(--border); }
.pl-sheet-title { font-size: 16px; font-weight: 700; }
.pl-sheet-meta { font-size: 12.5px; color: var(--fg-3); }
.pl-sheet-close { margin-left: auto; width: 32px; height: 32px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, 0.08); color: #fff; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.pl-sheet-close svg { width: 16px; height: 16px; stroke: currentColor; stroke-width: 2; }
.pl-sheet-body { padding: 16px 18px 28px; overflow-y: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 8px; }
.pl-epick { height: 42px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--bg-card); font-weight: 600; cursor: pointer; }
.pl-epick.is-now { background: var(--accent); border-color: var(--accent); color: #fff; }
.pl-epick.is-locked { opacity: 0.45; cursor: not-allowed; }

.pl-subtitle {
  position: absolute;
  bottom: 185px;
  left: 16px;
  right: 16px;
  display: flex;
  justify-content: center;
  text-align: center;
  pointer-events: none;
  z-index: 25;
  transition: bottom 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateZ(0);
  will-change: transform, bottom;
  contain: layout style;
}
.pl.chrome-hidden .pl-subtitle {
  bottom: 130px;
}
.pl-subtitle-cue {
  display: inline-block;
  max-width: 90%;
  padding: 5px 13px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-size: clamp(16px, 3.2vw, 21px);
  font-weight: 600;
  line-height: 1.4;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.95), 0 0 2px #000;
  white-space: pre-line;
  word-break: break-word;
  transform: translateZ(0);
  contain: paint;
}

.pl-sub-list {
  padding: 14px 18px 28px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 52vh;
}
.pl-sub-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--fg);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.pl-sub-item:hover {
  border-color: var(--accent);
}
.pl-sub-item.is-active {
  background: rgba(255, 42, 95, 0.12);
  border-color: var(--accent);
  color: var(--accent);
}
.pl-sub-item svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2.2;
  fill: none;
}

/* Download Sheet & Cards */
.pl-sheet-panel--dl { max-width: 520px; }
.pl-dl-list { padding: 16px 18px 24px; display: flex; flex-direction: column; gap: 10px; max-height: 65vh; overflow-y: auto; }
.pl-dl-loading { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 0; gap: 12px; color: var(--fg-2); font-size: 13.5px; }
.pl-dl-err { padding: 20px 0; text-align: center; color: var(--fg-2); font-size: 13.5px; }
.pl-dl-err p { margin-bottom: 12px; color: #ff5252; }

.pl-dl-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  width: 100%;
  padding: 14px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--fg);
  text-align: left;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}
.pl-dl-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}
.pl-dl-card--prime {
  background: linear-gradient(135deg, rgba(230, 29, 57, 0.12), rgba(15, 17, 24, 0.8));
  border-color: rgba(230, 29, 57, 0.35);
}
.pl-dl-card--prime:hover {
  background: linear-gradient(135deg, rgba(230, 29, 57, 0.2), rgba(15, 17, 24, 0.9));
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(230, 29, 57, 0.2);
}

.pl-dl-card-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}
.pl-dl-card--prime .pl-dl-card-icon {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 2px 10px rgba(230, 29, 57, 0.4);
}
.pl-dl-card-icon svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 2; }

.pl-dl-card-info { flex: 1; min-width: 0; }
.pl-dl-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 700;
  margin-bottom: 4px;
}
.pl-dl-badge {
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--fg-2);
}
.pl-dl-badge--prime {
  background: var(--accent);
  color: #fff;
}
.pl-dl-card-desc {
  font-size: 12px;
  color: var(--fg-3);
  line-height: 1.45;
}
.pl-dl-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.25);
  color: #ffd54f;
  font-size: 12px;
  line-height: 1.4;
  margin-top: 4px;
}
.pl-dl-note svg { width: 16px; height: 16px; stroke: currentColor; fill: none; flex-shrink: 0; margin-top: 1px; }

.state { max-width: 380px; margin: 64px auto; text-align: center; padding: 24px; }
.state svg { width: 48px; height: 48px; fill: none; stroke: var(--fg-3); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; margin: 0 auto 12px; }
.state h3 { font-size: 18px; margin-bottom: 6px; }
.state p { font-size: 13.5px; color: var(--fg-3); margin-bottom: 18px; }
.sk { background: linear-gradient(90deg, #181b24 25%, #232734 50%, #181b24 75%); background-size: 200% 100%; animation: shimmer 1.4s infinite; border-radius: var(--radius-sm); }
.sk-poster { aspect-ratio: 2 / 3; border-radius: var(--radius); margin-bottom: 8px; }
.sk-line { height: 14px; margin-bottom: 6px; }
.sk-line.short { width: 60%; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.ad-slot--empty, .pl-ad:has(.ad-slot--empty) { display: none !important; }
.ad-slot--native { margin: 24px 0; text-align: center; }
.pl-ad { position: absolute; bottom: 82px; left: 50%; transform: translateX(-50%); z-index: 12; }
.toast { position: fixed; bottom: 80px; left: 50%; transform: translate(-50%, 14px); z-index: 900; background: #fff; color: #0b0c10; padding: 10px 18px; border-radius: 99px; font-size: 13.5px; font-weight: 700; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45); opacity: 0; transition: opacity 0.2s, transform 0.2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 720px) {
  .hdr-inner { gap: 12px; padding: 0 12px; }
  .brand-sub { display: none; }
  .brand-text { display: inline-block; font-size: 17px; }
  .brand-logo { width: 32px; height: 32px; }
  .brand-logo svg { width: 16px; height: 16px; }
  .searchwrap { max-width: none; }
  .nav--desktop { display: none !important; }
  .nav--mobile {
    display: flex !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: rgba(15, 17, 24, 0.96);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--border);
    justify-content: space-around;
    align-items: center;
    z-index: 95;
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .nav--mobile .nav-link {
    flex-direction: column;
    gap: 3px;
    padding: 6px 16px;
    font-size: 11px;
    border-radius: 10px;
  }
  body:not(.player-open) {
    padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px));
  }
  body.player-open .nav--mobile {
    display: none !important;
  }
  .dtl-top { flex-direction: column; align-items: center; text-align: center; }
  .dtl-meta, .dtl-chips, .dtl-actions { justify-content: center; }
}

@media (max-width: 480px) {
  .pl-ctrls { gap: 6px; }
  .pl-btn { width: 38px; height: 38px; }
  .pl-ic { width: 20px; height: 20px; }
  .pl-time { font-size: 11.5px; }
}
/* Footer legal (2026-10-29, tautan Terms/Privacy untuk TikTok Developer) */
.site-footer{text-align:center;padding:18px 12px 84px;font-size:13px;color:#888}
.site-footer a{color:#888;text-decoration:none}
.site-footer a:hover{color:#eee;text-decoration:underline}
.site-footer span{margin:0 8px}

/* Batch download + modal progres render (2026-10-29) */
.eps--picking .ep { cursor: pointer; }
.ep--sel { outline: 2px solid #7dd87d !important; outline-offset: 1px; background: rgba(125,216,125,.18) !important; }
.eps-batchbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 12px 0 4px; padding: 10px 12px; background: #17181d; border: 1px solid #2a2c33; border-radius: 10px; font-size: 13px; }
.eps-batchbar[hidden] { display: none; }
.eps-batchbar-count { color: #ccc; }
.eps-batchbar-type { background: #0b0c10; color: #eee; border: 1px solid #2a2c33; border-radius: 8px; padding: 6px 8px; font-size: 13px; }
.eps-batchbar-merge { display: flex; align-items: center; gap: 6px; color: #ccc; cursor: pointer; }
.eps-batchbar-merge[hidden] { display: none; }
.dl-modal { position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.72); display: flex; align-items: flex-end; justify-content: center; padding: 12px; }
.dl-modal-panel { width: 100%; max-width: 520px; max-height: 82vh; overflow-y: auto; background: #121318; border: 1px solid #2a2c33; border-radius: 16px; padding: 16px; }
.dl-modal-hd { display: flex; justify-content: space-between; align-items: center; font-size: 16px; }
.dl-modal-close { background: none; border: none; color: #888; font-size: 18px; cursor: pointer; }
.dl-modal-note { font-size: 12.5px; color: #999; margin: 8px 0 12px; line-height: 1.5; }
.dl-modal-list { display: flex; flex-direction: column; gap: 12px; }
.dl-row-top { display: flex; align-items: center; gap: 8px; font-size: 13px; margin-bottom: 5px; }
.dl-row-ep { font-weight: 700; }
.dl-row-st { color: #bbb; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dl-track { height: 8px; background: #22242b; border-radius: 99px; overflow: hidden; }
.dl-bar { height: 100%; background: #7dd87d; border-radius: 99px; transition: width .5s; }
.dl-bar--ind { width: 40% !important; animation: dlind 1.2s ease-in-out infinite alternate; }
@keyframes dlind { from { margin-left: 0; } to { margin-left: 60%; } }
.dl-modal-foot { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }

/* Gate "lanjut episode" (Adsterra Direct Link): modal tengah, bukan
   bottom-sheet seperti modal unduhan. */
.adgate-modal { position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.72); display: flex; align-items: center; justify-content: center; padding: 16px; }
.adgate-panel { width: 100%; max-width: 420px; background: #121318; border: 1px solid #2a2c33; border-radius: 16px; padding: 20px; text-align: center; }
.adgate-hd { display: flex; justify-content: space-between; align-items: center; font-size: 16px; margin-bottom: 8px; }
.adgate-close { background: none; border: none; color: #888; font-size: 18px; cursor: pointer; }
.adgate-note { font-size: 13px; color: #999; line-height: 1.5; margin: 0 0 16px; }
.adgate-adbtn { width: 100%; height: 48px; border: none; border-radius: 12px; background: var(--accent); color: #fff; font-size: 15px; font-weight: 700; cursor: pointer; margin-bottom: 10px; }
.adgate-go { width: 100%; height: 48px; border-radius: 12px; border: 1px solid rgba(255,255,255,.12); background: rgba(255,255,255,.1); color: var(--fg); font-size: 15px; font-weight: 700; cursor: pointer; }
.adgate-go:disabled { opacity: .55; cursor: not-allowed; }
.adgate-cancel { background: none; border: none; color: #888; font-size: 13px; cursor: pointer; margin-top: 12px; }
