﻿:root {
  color-scheme: dark;
  --bg: #090a0f;
  --panel: #14151c;
  --panel-2: #1b1d26;
  --soft: #252834;
  --line: rgba(255, 255, 255, .08);
  --muted: #9a9dab;
  --text: #f6f7fb;
  --text-soft: rgba(255, 255, 255, .72);
  --red: #ef4e5d;
  --red-2: #8f2133;
  --glass: rgba(255, 255, 255, .07);
  --glass-strong: rgba(255, 255, 255, .1);
}

* {
  -webkit-tap-highlight-color: transparent;
}

html {
  min-height: 100%;
  background: #000;
}

body {
  min-height: 100%;
  margin: 0;
  background:
    radial-gradient(circle at 20% 0, rgba(239, 78, 93, .14), transparent 28rem),
    radial-gradient(circle at 100% 8%, rgba(112, 132, 255, .08), transparent 26rem),
    linear-gradient(180deg, #101118 0, #0c0d13 18rem, var(--bg) 42rem, #07080c 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

.app-shell {
  position: relative;
  width: 100%;
  max-width: 450px;
  min-height: 100vh;
  margin: 0 auto;
  overflow-x: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .03), transparent 18rem),
    var(--bg);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .04), 0 24px 80px rgba(0, 0, 0, .45);
}

.safe-page {
  padding: 18px 16px 104px;
}

.safe-top {
  padding-top: max(16px, env(safe-area-inset-top));
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 28px 0 14px;
}

.section-title {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -.03em;
}

.section-more {
  position: relative;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, .72);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  padding: 0 12px 0 0;
  letter-spacing: .02em;
}

.section-more::after {
  position: absolute;
  top: 50%;
  right: 0;
  width: 6px;
  height: 6px;
  border-top: 1.5px solid currentColor;
  border-right: 1.5px solid currentColor;
  content: "";
  transform: translateY(-50%) rotate(45deg);
}

.section-actions {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  display: inline-grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 13px;
  background: linear-gradient(135deg, #ff314d, #8b1326);
  color: #fff;
  font-size: 19px;
  font-weight: 900;
  box-shadow: 0 12px 30px rgba(239, 78, 93, .2);
}

.glass-input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, .07);
  color: #fff;
  outline: 0;
  padding: 0 14px;
}

.glass-input::placeholder {
  color: rgba(255, 255, 255, .42);
}

.search-form {
  display: flex;
  align-items: center;
  gap: 10px;
}

.search-form .glass-input {
  flex: 1 1 auto;
}

.search-panel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, .075);
  padding: 0 8px 0 14px;
}

.search-panel-icon {
  color: rgba(255, 255, 255, .5);
  font-size: 19px;
  font-weight: 900;
  line-height: 1;
}

.search-panel-input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  color: #fff;
  outline: 0;
  font-size: 14px;
  font-weight: 700;
}

.search-panel-input::placeholder {
  color: rgba(255, 255, 255, .42);
}

.search-panel-submit {
  height: 34px;
  border: 0;
  border-radius: 10px;
  background: var(--red);
  color: #fff;
  cursor: pointer;
  padding: 0 14px;
  font-size: 12px;
  font-weight: 900;
}

.search-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.search-tag {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, .07);
  color: rgba(255, 255, 255, .82);
  padding: 0 14px;
  font-size: 12px;
  font-weight: 800;
}

.search-tag.active {
  border-color: rgba(255, 39, 56, .55);
  background: rgba(255, 39, 56, .12);
  color: var(--red);
}

.search-result-list .media-row {
  border-color: transparent;
  background: transparent;
  padding: 0;
}

.search-result-list .media-row + .media-row {
  margin-top: 14px;
}

.search-result-list .media-row-poster,
.search-result-list .media-row-poster img {
  width: 76px;
}

.search-result-list .media-row-poster {
  flex-basis: 76px;
}

.search-result-list .media-row-poster img {
  border-radius: 10px;
}

.icon-button {
  position: relative;
  display: inline-grid;
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 14px;
  background: rgba(255, 255, 255, .08);
  backdrop-filter: blur(16px);
  color: #fff;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
}

.button-glyph {
  position: relative;
  z-index: 1;
  display: inline-grid;
  place-items: center;
  color: currentColor;
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
}

.topbar-actions {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
}

.search-btn,
.filter-btn {
  position: relative;
}

.search-btn .button-glyph,
.filter-btn .button-glyph {
  opacity: 1;
}

.search-btn::before,
.search-btn::after,
.filter-btn::before,
.filter-btn::after {
  position: absolute;
  content: "";
  box-sizing: border-box;
}

.search-btn::before {
  top: 10px;
  left: 10px;
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.search-btn::after {
  right: 10px;
  bottom: 10px;
  width: 9px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transform: rotate(45deg);
}

.filter-btn::before {
  top: 10px;
  left: 10px;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 8px 0 currentColor, 0 16px 0 currentColor;
}

.filter-btn::after {
  top: 7px;
  left: 13px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 8px 8px 0 var(--red), -1px 16px 0 var(--red);
}

.search-btn::before,
.search-btn::after,
.filter-btn::before,
.filter-btn::after {
  display: none;
}

.hero-wrap {
  position: relative;
  min-height: 540px;
  padding: max(16px, env(safe-area-inset-top)) 16px 0;
  overflow: hidden;
}

.hero-topbar {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: max(16px, env(safe-area-inset-top)) 16px 0;
}

.hero-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 100%;
  gap: 16px;
  height: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.hero-track::-webkit-scrollbar {
  display: none;
}

.hero-slide {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .05);
  border-radius: 0 0 34px 34px;
  scroll-snap-align: start;
  background: #14151b;
  box-shadow: 0 22px 44px rgba(0, 0, 0, .28);
}

.hero-slide::before {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(180deg, rgba(8, 8, 12, .04), rgba(8, 8, 12, .18) 28%, rgba(8, 8, 12, .74) 66%, rgba(8, 8, 12, .96) 100%),
    linear-gradient(90deg, rgba(7, 8, 10, .56), rgba(7, 8, 10, .18) 44%, transparent 74%),
    linear-gradient(0deg, rgba(239, 78, 93, .08), rgba(239, 78, 93, 0));
  z-index: 1;
}

.hero-slide::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(255, 255, 255, .1), transparent 22%);
  mix-blend-mode: soft-light;
  opacity: .45;
  z-index: 1;
}

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.98) contrast(1.06);
}

.hero-content {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 38px;
  z-index: 2;
}

.hero-kicker {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  padding: 0 10px;
  color: rgba(255, 255, 255, .78);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  backdrop-filter: blur(12px);
}

.hero-title {
  max-width: 82%;
  margin-top: 14px;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -.04em;
  text-shadow: 0 8px 26px rgba(0, 0, 0, .42);
}

.hero-meta {
  margin-top: 10px;
  color: rgba(255, 255, 255, .76);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .01em;
}

.hero-desc {
  display: -webkit-box;
  max-width: 82%;
  margin-top: 10px;
  overflow: hidden;
  color: rgba(255, 255, 255, .62);
  font-size: 12px;
  line-height: 1.5;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.primary-btn,
.ghost-btn,
.danger-outline-btn {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: 16px;
  padding: 0 18px;
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.primary-btn {
  border: 1px solid rgba(255, 255, 255, .22);
  background: linear-gradient(180deg, rgba(255, 255, 255, .96), rgba(242, 243, 247, .9));
  color: #11131a;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .24);
}

.ghost-btn {
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(16, 17, 22, .3);
  color: #fff;
  backdrop-filter: blur(14px);
}

.ghost-btn[disabled] {
  opacity: .6;
  cursor: default;
  pointer-events: none;
}

.ghost-btn.is-added,
.ghost-btn.disabled {
  border-color: rgba(239, 78, 93, .22);
  background: rgba(239, 78, 93, .14);
  color: rgba(255, 255, 255, .92);
}

.danger-outline-btn {
  border: 1px solid rgba(239, 78, 93, .42);
  color: var(--red);
}

.play-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  background: currentColor;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

.slider-dots {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-dots {
  position: absolute;
  right: 20px;
  bottom: 18px;
  z-index: 3;
  margin-top: 0;
}

.slider-dots span {
  width: 7px;
  height: 6px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .24);
  transition: width .2s ease, background .2s ease, opacity .2s ease;
}

.slider-dots span.active {
  width: 24px;
  background: rgba(255, 255, 255, .96);
}

.chip-row {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 0 8px;
  scrollbar-width: none;
}

.chip-row::-webkit-scrollbar {
  display: none;
}

.category-tabs {
  display: flex;
  align-items: center;
  gap: 28px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  padding: 0 0 12px;
  scrollbar-width: none;
}

.category-tabs::-webkit-scrollbar {
  display: none;
}

.category-tab {
  position: relative;
  flex: 0 0 auto;
  color: rgba(255, 255, 255, .7);
  font-size: 15px;
  font-weight: 850;
  line-height: 1.2;
  white-space: nowrap;
}

.category-tab::after {
  position: absolute;
  right: 18%;
  bottom: -13px;
  left: 18%;
  height: 3px;
  border-radius: 999px;
  background: transparent;
  content: "";
}

.category-tab.active {
  color: #fff;
}

.category-tab.active::after {
  background: var(--red);
}

.chip,
.filter-chip {
  display: inline-flex;
  min-width: max-content;
  height: 36px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 999px;
  background: rgba(255, 255, 255, .05);
  color: rgba(255, 255, 255, .76);
  padding: 0 14px;
  font-size: 12px;
  font-weight: 700;
  backdrop-filter: blur(12px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .02);
}

.chip.active,
.filter-chip.active,
.chip:hover,
.filter-chip:hover {
  border-color: rgba(239, 78, 93, .28);
  background: rgba(239, 78, 93, .16);
  color: #fff;
  box-shadow: 0 10px 24px rgba(239, 78, 93, .12);
}

.poster-rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 34.5%;
  gap: 14px;
  overflow-x: auto;
  padding: 4px 0 10px;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.poster-rail::-webkit-scrollbar {
  display: none;
}

.poster-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 12px;
}

.waterfall {
  column-count: 2;
  column-gap: 12px;
}

.waterfall .vod-card {
  display: inline-block;
  width: 100%;
  margin: 0 0 14px;
  break-inside: avoid;
}

.vod-card {
  position: relative;
  display: block;
  min-width: 0;
  overflow: hidden;
  transition: transform .2s ease, opacity .2s ease;
}

.vod-poster {
  display: block;
  width: 100%;
  aspect-ratio: 2 / 3;
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 16px;
  object-fit: cover;
  background: #1b1c24;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .24);
}

.vod-score,
.vod-note {
  position: absolute;
  z-index: 2;
  top: 10px;
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 999px;
  padding: 0 8px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  backdrop-filter: blur(10px);
}

.vod-score {
  left: 10px;
  background: rgba(12, 13, 17, .72);
  color: rgba(255, 255, 255, .92);
}

.vod-note {
  right: 10px;
  max-width: calc(100% - 54px);
  overflow: hidden;
  background: rgba(10, 11, 15, .62);
  color: rgba(255, 255, 255, .8);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vod-title {
  display: block;
  margin-top: 10px;
  overflow: hidden;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vod-meta {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .01em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-section + .content-section {
  margin-top: 8px;
}

.mobile-tabbar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 50;
  display: grid;
  width: min(100%, 450px);
  grid-template-columns: repeat(5, 1fr);
  margin: 0 auto;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(255, 255, 255, .06);
  background: rgba(9, 10, 14, .82);
  backdrop-filter: blur(24px);
  box-shadow: 0 -18px 36px rgba(0, 0, 0, .34);
}

.tabbar-item {
  display: grid;
  place-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, .52);
  font-size: 10px;
  font-weight: 700;
  transition: color .2s ease;
}

.tabbar-item.active {
  color: rgba(255, 255, 255, .96);
}

.tabbar-icon {
  position: relative;
  display: block;
  width: 26px;
  height: 26px;
  border-radius: 10px;
  transition: background .2s ease, box-shadow .2s ease;
}

.tabbar-item.active .tabbar-icon {
  background: rgba(239, 78, 93, .14);
  box-shadow: inset 0 0 0 1px rgba(239, 78, 93, .18);
}

.tabbar-item span:last-child {
  transition: color .2s ease;
}

.tabbar-item.active span:last-child {
  color: rgba(255, 255, 255, .96);
}

.tabbar-icon::before,
.tabbar-icon::after {
  position: absolute;
  content: "";
  box-sizing: border-box;
}

.icon-home::before {
  inset: 5px 3px 3px;
  border: 2px solid currentColor;
  border-top: 0;
  border-radius: 3px;
}

.icon-home::after {
  top: 2px;
  left: 5px;
  width: 12px;
  height: 12px;
  border-top: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: rotate(45deg);
}

.icon-compass::before {
  inset: 3px;
  border: 2px solid currentColor;
  border-radius: 99px;
}

.icon-compass::after {
  top: 7px;
  left: 9px;
  width: 5px;
  height: 9px;
  border-radius: 5px 5px 1px 1px;
  background: currentColor;
  transform: rotate(35deg);
}

.icon-bookmark::before {
  inset: 3px 6px;
  border: 2px solid currentColor;
  border-radius: 3px 3px 1px 1px;
}

.icon-bookmark::after {
  left: 8px;
  bottom: 3px;
  width: 6px;
  height: 6px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

.icon-download::before {
  left: 5px;
  right: 5px;
  bottom: 3px;
  height: 6px;
  border: 2px solid currentColor;
  border-top: 0;
  border-radius: 0 0 4px 4px;
}

.icon-download::after {
  top: 3px;
  left: 10px;
  width: 2px;
  height: 12px;
  background: currentColor;
  box-shadow: -4px 7px 0 -1px currentColor, 4px 7px 0 -1px currentColor;
}

.icon-user::before {
  top: 3px;
  left: 7px;
  width: 8px;
  height: 8px;
  border: 2px solid currentColor;
  border-radius: 99px;
}

.icon-user::after {
  left: 4px;
  right: 4px;
  bottom: 3px;
  height: 8px;
  border: 2px solid currentColor;
  border-radius: 9px 9px 4px 4px;
}

.app-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: max(16px, env(safe-area-inset-top)) 16px 10px;
}

.page-title {
  font-size: 21px;
  font-weight: 900;
}

.cache-overview {
  display: grid;
  gap: 12px;
}

.cache-overview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.cache-overview-clear {
  flex: 0 0 auto;
  min-height: 30px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--red);
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.cache-overview-tips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cache-overview-tip {
  margin: 0;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 999px;
  background: rgba(255, 255, 255, .04);
  color: rgba(255, 255, 255, .55);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.back-btn,
.share-btn {
  position: relative;
}

.back-btn::before,
.share-btn::before,
.share-btn::after {
  position: absolute;
  content: "";
  box-sizing: border-box;
}

.back-btn::before {
  top: 13px;
  left: 15px;
  width: 10px;
  height: 10px;
  border-bottom: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: rotate(45deg);
}

.share-btn::before {
  top: 12px;
  left: 10px;
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-radius: 5px;
}

.share-btn::after {
  top: 8px;
  left: 11px;
  width: 7px;
  height: 7px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: rotate(-45deg);
}

.media-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .045);
}

.media-row + .media-row {
  margin-top: 10px;
}

.media-row-poster {
  width: 58px;
  flex: 0 0 58px;
}

.media-row-poster img {
  display: block;
  width: 58px;
  aspect-ratio: 2 / 3;
  border-radius: 9px;
  object-fit: cover;
}

.media-row-title {
  display: block;
  overflow: hidden;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.media-row-meta,
.media-row-desc {
  overflow: hidden;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.round-play {
  position: relative;
  display: inline-grid;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 99px;
}

.round-play::before {
  width: 0;
  height: 0;
  margin-left: 2px;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 8px solid #fff;
  content: "";
}

.detail-hero {
  position: relative;
  min-height: 430px;
  padding: max(14px, env(safe-area-inset-top)) 16px 22px;
  overflow: hidden;
}

.detail-hero::before {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, .1), var(--bg) 92%),
    linear-gradient(90deg, rgba(0, 0, 0, .8), rgba(0, 0, 0, .18));
  content: "";
  z-index: 1;
}

.detail-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .72;
  filter: blur(1px) saturate(1.08);
  transform: scale(1.02);
}

.detail-content {
  position: relative;
  z-index: 2;
}

.rating-stars {
  color: var(--red);
  font-size: 13px;
  letter-spacing: 1px;
}

.panel-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .035));
}

.episode-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.episode-list {
  display: grid;
  gap: 8px;
}

.episode-list.is-compact {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.episode-list.is-balanced {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.episode-list.is-long {
  grid-template-columns: 1fr;
}

.episode-link {
  display: grid;
  min-height: 38px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .82);
  font-size: 12px;
  font-weight: 800;
  overflow: hidden;
  padding: 0 6px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.episode-list.is-balanced .episode-link {
  min-height: 40px;
  padding: 0 10px;
}

.episode-list.is-long .episode-link {
  min-height: 44px;
  place-items: center start;
  padding: 0 12px;
  overflow: hidden;
  line-height: 1.35;
  text-align: left;
  text-overflow: ellipsis;
  white-space: normal;
}

.download-list .episode-link {
  position: relative;
  padding-right: 48px;
}

.download-list .episode-link::after {
  position: absolute;
  top: 50%;
  right: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
  color: rgba(255, 255, 255, .68);
  content: "涓嬭浇";
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  padding: 4px 6px;
  transform: translateY(-50%);
}

#m3u8Download .download-list .episode-link::after {
  content: "m3u8";
}

.cache-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.cache-list .episode-link {
  width: 100%;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  place-items: center start;
  padding: 0 12px;
}

.cache-link {
  cursor: pointer;
}

.cache-link[disabled] {
  cursor: not-allowed;
  opacity: .52;
}

.cache-link span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cache-link small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  height: 22px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .07);
  color: rgba(255, 255, 255, .72);
  font-size: 11px;
  font-weight: 800;
  padding: 0 10px;
}

.cache-link.is-ready {
  border-color: rgba(255, 39, 56, .7);
  background: rgba(255, 39, 56, .14);
  color: var(--red);
}

.cache-link.is-ready small {
  background: rgba(255, 39, 56, .16);
  color: var(--red);
}

.cache-link.is-loading small,
.cache-link.is-queued small {
  background: rgba(255, 255, 255, .1);
  color: #fff;
}

.cache-link.is-error small {
  background: rgba(255, 90, 90, .14);
  color: #ff9fa8;
}

.cache-page-hero {
  overflow: hidden;
}

.cache-page-cover {
  width: 88px;
  height: 124px;
  flex: 0 0 88px;
  border-radius: 14px;
  object-fit: cover;
}

.cache-page-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.cache-stat {
  display: grid;
  gap: 4px;
  min-height: 68px;
  align-content: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, .04);
  text-align: center;
}

.cache-stat strong {
  color: #fff;
  font-size: 18px;
  font-weight: 900;
}

.cache-stat span {
  color: rgba(255, 255, 255, .52);
  font-size: 11px;
  font-weight: 700;
}

.cache-toolbar-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.cache-toolbar-mini {
  min-height: 36px;
  padding: 0 14px;
}

.cache-page-list {
  overflow: hidden;
}

.cache-page-content {
  max-height: min(62vh, 720px);
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-color: rgba(255, 255, 255, .26) transparent;
  scrollbar-width: thin;
}

.cache-page-content::-webkit-scrollbar {
  width: 4px;
}

.cache-page-content::-webkit-scrollbar-thumb {
  border-radius: 99px;
  background: rgba(255, 255, 255, .26);
}

.cache-select-list {
  grid-template-columns: 1fr;
}

.cache-select-link {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  place-items: stretch;
  min-height: 48px;
  padding: 8px 12px;
}

.cache-select-link.is-selected {
  border-color: rgba(255, 39, 56, .7);
  background: rgba(255, 39, 56, .12);
}

.cache-select-link.is-current {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18);
}

.cache-select-link.is-disabled {
  opacity: .74;
}

.cache-select-main {
  appearance: none;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 32px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}

.cache-select-main[disabled] {
  cursor: default;
}

.cache-select-check {
  position: relative;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 5px;
  background: rgba(255, 255, 255, .05);
}

.cache-select-check::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 3px;
  background: transparent;
  transition: background .18s ease;
}

.cache-select-link.is-selected .cache-select-check {
  border-color: rgba(255, 39, 56, .78);
  background: rgba(255, 39, 56, .18);
}

.cache-select-link.is-selected .cache-select-check::after {
  background: var(--red);
}

.cache-select-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cache-select-action {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .78);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.cache-select-action[disabled] {
  opacity: .7;
  cursor: default;
}

.cache-select-link.is-ready .cache-select-action {
  border-color: rgba(255, 39, 56, .35);
  background: rgba(255, 39, 56, .12);
  color: var(--red);
}

.cache-select-link.is-loading .cache-select-action,
.cache-select-link.is-queued .cache-select-action {
  color: #fff;
}

.cache-select-link.is-error .cache-select-action,
.cache-select-link.is-stopped .cache-select-action {
  border-color: rgba(255, 159, 168, .28);
  color: #ffb2bb;
}

.cache-group {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, .03);
}

.cache-group + .cache-group {
  margin-top: 12px;
}

.cache-group-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  cursor: pointer;
  list-style: none;
}

.cache-group-summary::-webkit-details-marker,
.cache-group-summary::marker {
  display: none;
  content: "";
}

.cache-group-summary::after {
  margin-left: auto;
  color: rgba(255, 255, 255, .42);
  content: "灞曞紑";
  font-size: 11px;
  font-weight: 800;
}

.cache-group[open] .cache-group-summary::after {
  content: "鏀惰捣";
}

.cache-group-body {
  padding: 0 12px 12px;
  border-top: 1px solid var(--line);
}

.cache-group-item + .cache-group-item {
  margin-top: 8px;
}

.local-cache-actions {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.cache-mini-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 30px;
  padding: 0 9px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 10px;
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .74);
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}

.cache-mini-btn.is-danger {
  color: #ff9fa8;
}

.cache-mini-btn.is-wide {
  min-width: 44px;
}

.line-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 0 0 14px;
  scrollbar-color: rgba(255, 255, 255, .32) transparent;
  scrollbar-width: thin;
}

.line-tabs::-webkit-scrollbar {
  height: 4px;
}

.line-tabs::-webkit-scrollbar-track {
  background: transparent;
}

.line-tabs::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(255, 255, 255, .32);
}

.line-tab {
  appearance: none;
  display: inline-flex;
  min-width: max-content;
  height: 34px;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .76);
  padding: 0 12px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}

.line-tab small {
  color: rgba(255, 255, 255, .42);
  font-size: 10px;
}

.line-tab.active {
  border-color: rgba(255, 39, 56, .9);
  background: var(--red);
  color: #fff;
}

.line-tab.active span {
  color: #fff;
}

.line-tab.active small {
  color: rgba(255, 255, 255, .86);
}

.player-playlist {
  margin-top: 16px;
  overflow: hidden;
}

.download-panel {
  overflow: hidden;
}

.download-verify-frame {
  min-height: 220px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(0, 0, 0, .22);
}

.download-verify-frame iframe {
  width: 100%;
  min-height: 220px;
  border: 0;
}

.player-playlist .section-head {
  margin: 0 0 13px;
}

.player-playlist-content,
.episode-collapse-content {
  position: relative;
  transition: max-height .22s ease;
}

.player-playlist[data-overflow="true"] .player-playlist-content,
.episode-collapse[data-overflow="true"] .episode-collapse-content {
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-color: rgba(255, 255, 255, .26) transparent;
  scrollbar-width: thin;
}

.player-playlist-content::-webkit-scrollbar,
.episode-collapse-content::-webkit-scrollbar {
  width: 4px;
}

.player-playlist-content::-webkit-scrollbar-thumb,
.episode-collapse-content::-webkit-scrollbar-thumb {
  border-radius: 99px;
  background: rgba(255, 255, 255, .26);
}

.player-playlist.is-collapsed .player-playlist-content,
.episode-collapse.is-collapsed .episode-collapse-content {
  max-height: var(--collapse-height, 340px);
  overflow: hidden;
}

.player-playlist.is-expanded .player-playlist-content,
.episode-collapse.is-expanded .episode-collapse-content {
  max-height: var(--collapse-expanded-height, 520px);
  overflow-y: auto;
}

.player-playlist.is-collapsed .player-playlist-content::after,
.episode-collapse.is-collapsed .episode-collapse-content::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 64px;
  background: linear-gradient(180deg, rgba(15, 15, 19, 0), rgba(15, 15, 19, .96));
  content: "";
  pointer-events: none;
}

.episode-source + .episode-source {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

@media (max-width: 360px) {
  .episode-list.is-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.episode-link.active,
.episode-link:hover {
  border-color: rgba(255, 39, 56, .8);
  background: rgba(255, 39, 56, .16);
  color: var(--red);
}

.player-shell {
  position: relative;
  width: 100%;
  background: #000;
}

.player-box {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
}

.player-box .MacPlayer,
.player-box iframe,
.player-box video,
.player-box embed,
.player-box object {
  width: 100% !important;
  height: 100% !important;
}

.control-pill {
  display: inline-flex;
  min-width: 54px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .08);
  color: rgba(255, 255, 255, .82);
  font-size: 11px;
  font-weight: 800;
}

[data-tab-group].active {
  color: var(--red) !important;
}

.profile-card {
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(255, 39, 56, .9), rgba(124, 7, 20, .88));
  box-shadow: 0 18px 40px rgba(255, 39, 56, .18);
}

.menu-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  border-bottom: 1px solid var(--line);
  color: rgba(255, 255, 255, .88);
  font-size: 14px;
  font-weight: 700;
}

.menu-link:last-child {
  border-bottom: 0;
}

.menu-link::after {
  width: 8px;
  height: 8px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  content: "";
  opacity: .55;
  transform: rotate(45deg);
}

.setting-row {
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--line);
}

.setting-row:last-child {
  border-bottom: 0;
}

.switch {
  position: relative;
  width: 44px;
  height: 26px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .16);
}

.switch::before {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  content: "";
  transition: transform .2s ease;
}

.switch.active,
.switch.is-on {
  background: var(--red);
}

.switch.active::before,
.switch.is-on::before {
  transform: translateX(18px);
}

.bottom-sheet {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 80;
  width: min(100%, 450px);
  max-height: 78vh;
  overflow-y: auto;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 20px 20px 0 0;
  background: rgba(20, 20, 25, .96);
  box-shadow: 0 -24px 60px rgba(0, 0, 0, .44);
  transform: translateY(105%);
  transition: transform .24s ease;
  backdrop-filter: blur(20px);
}

.bottom-sheet.open {
  transform: translateY(0);
}

.sheet-lock {
  overflow: hidden;
}

.page-pill,
.page-count {
  display: inline-flex;
  height: 36px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 14px;
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .85);
  font-size: 12px;
  font-weight: 800;
}

.page-pill.disabled {
  pointer-events: none;
  opacity: .42;
}

.empty-state {
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 240px;
  color: var(--muted);
  text-align: center;
}

.empty-state p {
  margin: 0;
  color: #fff;
  font-size: 15px;
  font-weight: 900;
}

.empty-state span {
  font-size: 12px;
}

.empty-icon {
  width: 54px;
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(255, 39, 56, .35), rgba(255, 255, 255, .04));
}

.app-toast {
  position: fixed;
  left: 50%;
  bottom: calc(86px + env(safe-area-inset-bottom));
  z-index: 120;
  max-width: min(330px, calc(100vw - 48px));
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 999px;
  background: rgba(18, 18, 23, .94);
  color: #fff;
  box-shadow: 0 18px 44px rgba(0, 0, 0, .42);
  font-size: 13px;
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
  transition: opacity .2s ease, transform .2s ease;
  backdrop-filter: blur(16px);
}

.app-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.record-check {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .06);
}

.record-check input {
  width: 14px;
  height: 14px;
  accent-color: var(--red);
}

[data-local-cache-empty][hidden],
[data-local-cache-clear][hidden],
[data-server-download-empty][hidden] {
  display: none !important;
}

.avatar-edit {
  position: relative;
  display: block;
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
}

.avatar-edit img {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  object-fit: cover;
}

.avatar-edit span {
  position: absolute;
  right: -2px;
  bottom: -2px;
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border: 2px solid var(--bg);
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.avatar-edit input {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.line-clamp-2 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

@media (max-width: 374px) {
  .poster-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .poster-rail {
    grid-auto-columns: 38%;
  }

  .episode-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.desktop-only {
  display: none;
}

@media (min-width: 992px) {
  :root {
    --desktop-shell: #0d0f14;
    --desktop-panel: #12161f;
    --desktop-panel-2: #181d28;
    --desktop-line: rgba(255, 255, 255, .08);
    --desktop-soft: rgba(255, 255, 255, .05);
    --desktop-shadow: 0 24px 80px rgba(0, 0, 0, .35);
  }

  body {
    background:
      radial-gradient(circle at 10% 0, rgba(255, 39, 56, .12), transparent 28rem),
      radial-gradient(circle at 100% 0, rgba(67, 103, 255, .08), transparent 30rem),
      linear-gradient(180deg, #07090d 0, #0b0f15 100%);
  }

  .mobile-only {
    display: none !important;
  }

  .desktop-only {
    display: block;
  }

  .app-shell {
    max-width: none;
    min-height: 100vh;
    margin: 0;
    background: transparent;
    box-shadow: none;
  }

  .safe-page {
    padding: 0;
  }

  .app-toast {
    bottom: 28px;
  }

  .desktop-shell {
    display: flex;
    min-height: 100vh;
  }

  .desktop-shell-single {
    align-items: stretch;
  }

  .desktop-sidebar {
    position: sticky;
    top: 0;
    display: flex;
    width: 240px;
    min-width: 240px;
    height: 100vh;
    flex-direction: column;
    gap: 18px;
    border-right: 1px solid var(--desktop-line);
    background: linear-gradient(180deg, rgba(7, 10, 16, .96), rgba(10, 12, 18, .94));
    padding: 22px 16px 24px;
    box-sizing: border-box;
    backdrop-filter: blur(18px);
  }

  .desktop-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 20px;
    padding: 8px 10px;
  }

  .desktop-brand-mark {
    display: inline-grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 13px;
    background: linear-gradient(135deg, #ff3045, #7f0c19);
    color: #fff;
    font-size: 22px;
    font-weight: 900;
    box-shadow: 0 18px 36px rgba(255, 39, 56, .28);
  }

  .desktop-brand-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 4px;
  }

  .desktop-brand-copy strong {
    font-size: 18px;
    font-weight: 900;
    line-height: 1.1;
  }

  .desktop-brand-copy small {
    color: rgba(255, 255, 255, .42);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
  }

  .desktop-sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .desktop-side-link,
  .desktop-side-sub {
    display: flex;
    min-height: 46px;
    align-items: center;
    gap: 12px;
    border: 1px solid transparent;
    border-radius: 16px;
    color: rgba(255, 255, 255, .78);
    padding: 0 14px;
    transition: .2s ease;
  }

  .desktop-side-link:hover,
  .desktop-side-sub:hover,
  .desktop-top-link:hover,
  .desktop-icon-button:hover,
  .desktop-vip-link:hover,
  .desktop-filter-chip:hover,
  .desktop-tag-pill:hover {
    border-color: rgba(255, 255, 255, .1);
    background: rgba(255, 255, 255, .04);
    color: #fff;
  }

  .desktop-side-link.active {
    border-color: rgba(255, 39, 56, .3);
    background: linear-gradient(180deg, rgba(255, 39, 56, .16), rgba(255, 39, 56, .08));
    color: #fff;
  }

  .desktop-side-icon {
    display: inline-grid;
    width: 18px;
    place-items: center;
    color: rgba(255, 255, 255, .72);
    font-size: 14px;
    font-weight: 900;
  }

  .desktop-side-group {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
    border-top: 1px solid var(--desktop-line);
    padding-top: 18px;
  }

  .desktop-side-group-title {
    padding: 0 14px;
    color: rgba(255, 255, 255, .38);
    font-size: 12px;
    font-weight: 800;
  }

  .desktop-side-sub {
    min-height: 40px;
    color: rgba(255, 255, 255, .58);
    font-size: 13px;
  }

  .desktop-workspace {
    display: flex;
    min-width: 0;
    flex: 1;
    flex-direction: column;
    padding: 20px 22px 32px;
  }

  .desktop-topbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 380px) auto;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--desktop-line);
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(16, 19, 27, .95), rgba(11, 14, 21, .92));
    padding: 12px 16px;
    box-shadow: var(--desktop-shadow);
  }

  .desktop-topbar-nav {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .desktop-topbar-nav::-webkit-scrollbar {
    display: none;
  }

  .desktop-top-link {
    position: relative;
    display: inline-flex;
    height: 40px;
    flex: 0 0 auto;
    align-items: center;
    border-radius: 12px;
    color: rgba(255, 255, 255, .74);
    padding: 0 14px;
    font-size: 14px;
    font-weight: 800;
  }

  .desktop-top-link.active {
    color: #fff;
  }

  .desktop-top-link.active::after {
    position: absolute;
    right: 12px;
    bottom: 6px;
    left: 12px;
    height: 2px;
    border-radius: 999px;
    background: var(--red);
    content: "";
  }

  .desktop-search-form {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    height: 44px;
    border: 1px solid var(--desktop-line);
    border-radius: 14px;
    background: rgba(255, 255, 255, .04);
    padding: 0 10px 0 14px;
  }

  .desktop-search-icon {
    color: rgba(255, 255, 255, .45);
    font-size: 16px;
    font-weight: 900;
  }

  .desktop-search-input,
  .desktop-search-hero-input {
    width: 100%;
    min-width: 0;
    border: 0;
    background: transparent;
    color: #fff;
    outline: 0;
    font-size: 14px;
    font-weight: 700;
  }

  .desktop-search-input::placeholder,
  .desktop-search-hero-input::placeholder {
    color: rgba(255, 255, 255, .38);
  }

  .desktop-search-submit {
    height: 32px;
    border: 0;
    border-radius: 10px;
    background: rgba(255, 255, 255, .08);
    color: rgba(255, 255, 255, .88);
    cursor: pointer;
    padding: 0 12px;
    font-size: 12px;
    font-weight: 800;
  }

  .desktop-top-actions {
    display: inline-flex;
    align-items: center;
    gap: 10px;
  }

  .desktop-vip-link,
  .desktop-icon-button,
  .desktop-avatar {
    display: inline-flex;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--desktop-line);
    border-radius: 14px;
    background: rgba(255, 255, 255, .04);
    color: #fff;
  }

  .desktop-vip-link {
    padding: 0 16px;
    color: #ffd56c;
    font-size: 13px;
    font-weight: 900;
  }

  .desktop-icon-button {
    width: 40px;
    font-size: 15px;
    font-weight: 900;
  }

  .desktop-avatar {
    width: 40px;
    overflow: hidden;
  }

  .desktop-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .desktop-avatar-text {
    width: auto;
    padding: 0 14px;
    font-size: 13px;
    font-weight: 800;
  }

  .desktop-page {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 20px;
    padding-top: 18px;
  }

  .desktop-panel {
    border: 1px solid var(--desktop-line);
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(20, 24, 34, .96), rgba(15, 18, 26, .94));
    box-shadow: var(--desktop-shadow);
    overflow: hidden;
  }

  .desktop-tight-panel {
    padding: 18px;
  }

  .desktop-home-layout,
  .desktop-detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 20px;
  }

  .desktop-home-main,
  .desktop-detail-main,
  .desktop-show-main {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 20px;
  }

  .desktop-home-side,
  .desktop-detail-side {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 20px;
  }

  .desktop-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
  }

  .desktop-section-head h2,
  .desktop-section-head span,
  .desktop-page-banner h1,
  .desktop-search-hero h1 {
    margin: 0;
  }

  .desktop-section-head h2 {
    font-size: 22px;
    font-weight: 900;
    line-height: 1.1;
  }

  .desktop-section-head a,
  .desktop-section-head span {
    color: rgba(255, 255, 255, .46);
    font-size: 13px;
    font-weight: 800;
  }

  .desktop-kicker {
    display: inline-flex;
    height: 28px;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 999px;
    background: rgba(255, 255, 255, .05);
    color: rgba(255, 255, 255, .66);
    padding: 0 12px;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
  }

  .desktop-hero-panel,
  .desktop-page-banner,
  .desktop-search-hero {
    padding: 18px;
  }

  .desktop-hero-track {
    display: grid;
    grid-auto-columns: 100%;
    grid-auto-flow: column;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .desktop-hero-track::-webkit-scrollbar {
    display: none;
  }

  .desktop-hero-slide {
    position: relative;
    min-width: 0;
    scroll-snap-align: start;
  }

  .desktop-hero-image {
    width: 100%;
    height: 420px;
    border-radius: 22px;
    object-fit: cover;
  }

  .desktop-hero-overlay,
  .desktop-detail-mask {
    position: absolute;
    inset: 0;
    background:
      linear-gradient(90deg, rgba(5, 6, 9, .85) 0, rgba(5, 6, 9, .32) 45%, rgba(5, 6, 9, .6) 100%),
      linear-gradient(180deg, rgba(5, 6, 9, .08), rgba(5, 6, 9, .62));
  }

  .desktop-hero-copy {
    position: absolute;
    bottom: 36px;
    left: 36px;
    z-index: 1;
    max-width: 520px;
  }

  .desktop-hero-copy h1,
  .desktop-detail-copy h1 {
    margin: 14px 0 10px;
    font-size: 42px;
    font-weight: 900;
    line-height: 1.08;
  }

  .desktop-hero-meta,
  .desktop-detail-meta,
  .desktop-player-meta,
  .desktop-update-copy small,
  .desktop-rank-copy small,
  .desktop-vod-meta {
    color: rgba(255, 255, 255, .58);
    font-size: 13px;
    line-height: 1.7;
  }

  .desktop-hero-desc,
  .desktop-detail-desc,
  .desktop-copy-block p,
  .desktop-note-box p,
  .desktop-note-box small,
  .desktop-page-banner p,
  .desktop-search-hero p {
    color: rgba(255, 255, 255, .64);
    font-size: 14px;
    line-height: 1.85;
  }

  .desktop-hero-actions,
  .desktop-player-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
  }

  .desktop-primary-btn,
  .desktop-ghost-btn {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    padding: 0 18px;
    font-size: 14px;
    font-weight: 900;
    transition: .2s ease;
    cursor: pointer;
  }

  .desktop-primary-btn {
    border: 1px solid rgba(255, 39, 56, .5);
    background: linear-gradient(180deg, #ff3347, #d7172a);
    color: #fff;
    box-shadow: 0 18px 40px rgba(255, 39, 56, .18);
  }

  .desktop-ghost-btn {
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .05);
    color: rgba(255, 255, 255, .88);
  }

  .desktop-slider-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 14px 0 4px;
  }

  .desktop-slider-dots span {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .18);
  }

  .desktop-slider-dots span.active {
    background: var(--red);
    transform: scale(1.15);
  }

  .desktop-card-row,
  .desktop-card-grid,
  .desktop-search-grid {
    display: grid;
    gap: 16px;
  }

  .desktop-card-row,
  .desktop-search-grid {
    grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
  }

  .desktop-card-grid {
    grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  }

  .desktop-card-grid-six {
    grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
  }

  .desktop-vod-card {
    position: relative;
    display: block;
    border-radius: 18px;
    background: rgba(255, 255, 255, .03);
    padding: 10px;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
  }

  .desktop-vod-card:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, .05);
    box-shadow: 0 18px 36px rgba(0, 0, 0, .22);
  }

  .desktop-vod-poster {
    width: 100%;
    aspect-ratio: 0.72;
    border-radius: 14px;
    object-fit: cover;
  }

  .desktop-vod-score,
  .desktop-vod-note {
    position: absolute;
    z-index: 1;
    top: 16px;
    display: inline-flex;
    min-height: 24px;
    align-items: center;
    border-radius: 999px;
    padding: 0 8px;
    font-size: 11px;
    font-weight: 900;
  }

  .desktop-vod-score {
    left: 16px;
    background: #ff2f45;
    color: #fff;
  }

  .desktop-vod-note {
    right: 16px;
    max-width: calc(100% - 72px);
    overflow: hidden;
    background: rgba(6, 6, 8, .62);
    color: rgba(255, 255, 255, .86);
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .desktop-vod-title {
    display: block;
    margin-top: 12px;
    font-size: 15px;
    font-weight: 900;
    line-height: 1.4;
  }

  .desktop-vod-meta {
    display: block;
    margin-top: 6px;
  }

  .desktop-discover-stack,
  .desktop-content-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 20px;
  }

  .desktop-filter-board {
    padding: 20px;
  }

  .desktop-filter-row {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    border-top: 1px solid rgba(255, 255, 255, .06);
    padding: 14px 0;
  }

  .desktop-filter-row:first-of-type {
    padding-top: 0;
    border-top: 0;
  }

  .desktop-filter-label {
    color: rgba(255, 255, 255, .38);
    font-size: 13px;
    font-weight: 800;
    line-height: 36px;
  }

  .desktop-filter-chips,
  .desktop-tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
  }

  .desktop-filter-chip,
  .desktop-tag-pill {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 12px;
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .76);
    padding: 0 14px;
    font-size: 13px;
    font-weight: 800;
  }

  .desktop-filter-chip.active,
  .desktop-tag-pill.active,
  .desktop-tab.active,
  .desktop-episode-link.active {
    border-color: rgba(255, 39, 56, .42);
    background: rgba(255, 39, 56, .12);
    color: #fff;
  }

  .desktop-feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .desktop-feature-card {
    display: flex;
    min-height: 134px;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--desktop-line);
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(20, 24, 34, .96), rgba(15, 18, 26, .94));
    padding: 18px;
    box-shadow: var(--desktop-shadow);
  }

  .desktop-feature-icon {
    display: inline-grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 12px;
    background: rgba(255, 39, 56, .14);
    color: var(--red);
    font-size: 16px;
    font-weight: 900;
  }

  .desktop-feature-card strong {
    margin-top: 20px;
    font-size: 18px;
    font-weight: 900;
  }

  .desktop-feature-card small {
    margin-top: 8px;
    color: rgba(255, 255, 255, .5);
    font-size: 12px;
    line-height: 1.7;
  }

  .desktop-rank-list,
  .desktop-update-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .desktop-rank-item,
  .desktop-update-item {
    display: grid;
    align-items: center;
    gap: 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, .035);
    padding: 10px;
  }

  .desktop-rank-item {
    grid-template-columns: 26px 68px minmax(0, 1fr) auto;
  }

  .desktop-rank-num {
    color: var(--red);
    font-size: 18px;
    font-weight: 900;
    text-align: center;
  }

  .desktop-rank-thumb,
  .desktop-update-thumb {
    width: 68px;
    height: 42px;
    border-radius: 10px;
    object-fit: cover;
  }

  .desktop-rank-copy,
  .desktop-update-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 4px;
  }

  .desktop-rank-copy strong,
  .desktop-update-copy strong {
    overflow: hidden;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.45;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .desktop-rank-score {
    color: #ff5b68;
    font-size: 18px;
    font-weight: 900;
  }

  .desktop-update-item {
    grid-template-columns: 56px minmax(0, 1fr) auto;
  }

  .desktop-update-thumb {
    width: 56px;
    height: 56px;
    border-radius: 14px;
  }

  .desktop-update-badge {
    display: inline-flex;
    min-height: 22px;
    align-items: center;
    border-radius: 999px;
    background: rgba(255, 39, 56, .14);
    color: #ff6773;
    padding: 0 8px;
    font-size: 10px;
    font-weight: 900;
  }

  .desktop-note-box {
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-radius: 18px;
    background: rgba(255, 255, 255, .035);
    padding: 16px;
  }

  .desktop-detail-hero {
    position: relative;
    min-height: 360px;
    padding: 24px;
  }

  .desktop-detail-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .desktop-detail-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 26px;
    align-items: end;
  }

  .desktop-detail-poster {
    width: 240px;
    aspect-ratio: 0.72;
    border-radius: 22px;
    object-fit: cover;
    box-shadow: 0 24px 54px rgba(0, 0, 0, .34);
  }

  .desktop-detail-score {
    display: inline-flex;
    align-items: baseline;
    gap: 10px;
    margin-top: 10px;
  }

  .desktop-detail-score strong {
    color: #ff5c67;
    font-size: 40px;
    font-weight: 900;
  }

  .desktop-detail-score span {
    color: rgba(255, 255, 255, .46);
    font-size: 14px;
    font-weight: 700;
  }

  .desktop-tabbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
  }

  .desktop-tab {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 13px;
    background: rgba(255, 255, 255, .04);
    color: rgba(255, 255, 255, .76);
    padding: 0 14px;
    font-size: 13px;
    font-weight: 800;
  }

  .desktop-tab small {
    color: rgba(255, 255, 255, .4);
  }

  .desktop-episode-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(98px, 1fr));
    gap: 12px;
  }

  .desktop-episode-link {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 13px;
    background: rgba(255, 255, 255, .03);
    color: rgba(255, 255, 255, .8);
    padding: 0 10px;
    font-size: 13px;
    font-weight: 800;
  }

  .desktop-copy-block {
    color: rgba(255, 255, 255, .7);
    font-size: 14px;
    line-height: 1.9;
  }

  .desktop-meta-stack {
    display: grid;
    gap: 12px;
  }

  .desktop-meta-stack div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    padding-bottom: 12px;
  }

  .desktop-meta-stack div:last-child {
    border-bottom: 0;
    padding-bottom: 0;
  }

  .desktop-meta-stack span {
    color: rgba(255, 255, 255, .42);
    font-size: 13px;
    font-weight: 800;
  }

  .desktop-meta-stack strong {
    text-align: right;
    font-size: 14px;
    font-weight: 800;
  }

  .desktop-player-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) 380px;
    gap: 20px;
  }

  .desktop-player-stage,
  .desktop-player-side {
    padding: 18px;
  }

  .desktop-player-shell {
    padding-top: 0;
  }

  .desktop-player-box {
    overflow: hidden;
    border-radius: 20px;
    background: #000;
  }

  .desktop-player-box iframe,
  .desktop-player-box video,
  .desktop-player-box object,
  .desktop-player-box embed {
    width: 100% !important;
    min-height: 620px !important;
  }

  .desktop-player-summary {
    padding: 18px 6px 4px;
  }

  .desktop-player-title {
    margin: 16px 0 0;
    font-size: 28px;
    font-weight: 900;
    line-height: 1.15;
  }

  .desktop-player-side-scroll {
    max-height: 700px;
    overflow: auto;
    padding-right: 4px;
  }

  .desktop-page-banner,
  .desktop-search-hero {
    display: flex;
    flex-direction: column;
    gap: 14px;
  }

  .desktop-page-banner h1,
  .desktop-search-hero h1 {
    font-size: 34px;
    font-weight: 900;
    line-height: 1.1;
  }

  .desktop-search-hero-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    margin-top: 6px;
  }

  .desktop-search-hero-input {
    height: 52px;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 16px;
    background: rgba(255, 255, 255, .04);
    padding: 0 16px;
  }

  .desktop-search-hero-compact {
    padding-bottom: 20px;
  }

  .desktop-side-spacer {
    height: 20px;
  }

  .desktop-footer {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(0, 2fr);
    gap: 28px;
    margin-top: 24px;
    border: 1px solid var(--desktop-line);
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(16, 19, 27, .95), rgba(11, 14, 21, .92));
    padding: 24px;
    box-shadow: var(--desktop-shadow);
  }

  .desktop-footer-brand {
    display: flex;
    align-items: flex-start;
    gap: 14px;
  }

  .desktop-footer-brand strong {
    display: block;
    margin-bottom: 8px;
    font-size: 18px;
    font-weight: 900;
  }

  .desktop-footer-brand p,
  .desktop-footer-links a {
    color: rgba(255, 255, 255, .56);
    font-size: 13px;
    line-height: 1.8;
  }

  .desktop-footer-links {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
  }

  .desktop-footer-links h4 {
    margin: 0 0 10px;
    font-size: 14px;
    font-weight: 900;
  }

  .desktop-footer-links a {
    display: block;
    margin-bottom: 6px;
  }

  .mobile-tabbar {
    display: none !important;
  }
}

@media (min-width: 992px) and (max-width: 1460px) {
  .desktop-home-layout,
  .desktop-detail-layout,
  .desktop-content-split,
  .desktop-player-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
  }

  .desktop-hero-copy h1,
  .desktop-detail-copy h1 {
    font-size: 34px;
  }

  .desktop-hero-image {
    height: 380px;
  }
}

