/* Generated by scripts/build-js.mjs. */
:root {
  --bg: #0b0c10;
  --bg-elevated: #12141a;
  --bg-soft: #181b24;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f2f4f7;
  --text-dim: #9aa3b2;
  --text-mute: #6b7380;
  --brand: #00cc4c;
  --brand-dim: #00a83e;
  --brand-glow: rgba(0, 204, 76, 0.35);
  --danger: #ff4d6a;
  --radius: 10px;
  --nav-h: 64px;
  --nav-iq: 104px;
  --max: 1280px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  font-family: 'Noto Sans SC', system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

img {
  display: block;
  max-width: 100%;
}

.container {
  width: min(100% - 48px, var(--max));
  margin-inline: auto;
}

/* —— Top Nav —— */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(11, 12, 16, 0.72);
  backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s;
}

.topbar.is-scrolled {
  border-bottom-color: var(--line);
  background: rgba(11, 12, 16, 0.92);
}

.topbar__inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 28px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo__mark {
  width: 32px;
  height: 32px;
  background: url('../assets/qingmang-logo.png') center / contain no-repeat;
}

.logo__text {
  font-family: 'Outfit', 'Noto Sans SC', sans-serif;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: 0.02em;
}

.logo__text span {
  color: var(--brand);
}

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

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

.nav a {
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--text-dim);
  font-size: 0.92rem;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s;
}

.nav a:hover,
.nav a.is-active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.nav a.is-active {
  color: var(--brand);
}

.search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(280px, 28vw);
  height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  transition: border-color 0.2s, background 0.2s;
}

.search:focus-within {
  border-color: #909090;
  background: #242424;
}

.search svg {
  width: 16px;
  height: 16px;
  opacity: 0.55;
  flex-shrink: 0;
}

.search input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  color: #d4d4d4;
  font-size: 0.88rem;
}

.search input::placeholder {
  color: #a3a3a3;
}

.search input::-webkit-search-cancel-button,
.list-toolbar__search input::-webkit-search-cancel-button {
  filter: brightness(0) invert(0.68);
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.btn-ghost {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-dim);
  font-size: 0.86rem;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.btn-ghost:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.04);
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: clamp(420px, 62vh, 640px);
  overflow: hidden;
  isolation: isolate;
}

.hero__slides {
  position: absolute;
  inset: 0;
}

.hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s var(--ease), visibility 0.8s;
}

.hero__slide.is-active {
  opacity: 1;
  visibility: visible;
}

.hero__bg {
  position: absolute;
  inset: 0;
  transform: scale(1.06);
  transition: transform 6s linear;
}

.hero__slide.is-active .hero__bg {
  transform: scale(1);
}

.hero__bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background: inherit;
}

.hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 80% at 75% 40%, transparent 0%, rgba(11, 12, 16, 0.15) 50%, rgba(11, 12, 16, 0.92) 100%),
    linear-gradient(90deg, rgba(11, 12, 16, 0.95) 0%, rgba(11, 12, 16, 0.55) 42%, rgba(11, 12, 16, 0.25) 70%, rgba(11, 12, 16, 0.7) 100%),
    linear-gradient(180deg, transparent 55%, var(--bg) 100%);
}

.hero__content {
  position: relative;
  z-index: 2;
  height: 100%;
  min-height: inherit;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 0 72px;
}

.hero__brand {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 14px;
  opacity: 0;
  transform: translateY(12px);
}

.hero__slide.is-active .hero__brand,
.hero__slide.is-active .hero__title,
.hero__slide.is-active .hero__meta,
.hero__slide.is-active .hero__desc,
.hero__slide.is-active .hero__cta {
  opacity: 1;
  transform: none;
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.hero__slide.is-active .hero__title { transition-delay: 0.08s; }
.hero__slide.is-active .hero__meta { transition-delay: 0.14s; }
.hero__slide.is-active .hero__desc { transition-delay: 0.2s; }
.hero__slide.is-active .hero__cta { transition-delay: 0.28s; }

.hero__title {
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 1.1;
  margin-bottom: 12px;
  opacity: 0;
  transform: translateY(16px);
}

.hero__title .tag {
  display: inline-block;
  margin-left: 12px;
  vertical-align: middle;
  padding: 4px 10px;
  border-radius: 6px;
  background: var(--danger);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0;
}

.hero__meta {
  color: var(--text-dim);
  font-size: 0.95rem;
  margin-bottom: 14px;
  opacity: 0;
  transform: translateY(12px);
}

.hero__desc {
  max-width: 480px;
  color: var(--text-dim);
  font-size: 1rem;
  margin-bottom: 22px;
  opacity: 0;
  transform: translateY(12px);
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  opacity: 0;
  transform: translateY(12px);
}

.btn-play {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--brand);
  color: #04140a;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.2s var(--ease), box-shadow 0.2s, background 0.2s;
}

.btn-play:hover {
  background: #19e063;
  transform: translateY(-2px);
  box-shadow: 0 12px 28px var(--brand-glow);
}

.btn-play svg {
  width: 18px;
  height: 18px;
}

.btn-follow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-weight: 500;
  transition: background 0.2s, border-color 0.2s;
}

.btn-follow:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.28);
}

.hero__dots {
  position: absolute;
  right: max(24px, calc((100% - var(--max)) / 2 + 24px));
  bottom: 88px;
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hero__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.28);
  transition: transform 0.25s, background 0.25s, height 0.25s;
}

.hero__dot.is-active {
  height: 22px;
  border-radius: 6px;
  background: var(--brand);
}

.hero__tip {
  position: absolute;
  left: max(24px, calc((100% - var(--max)) / 2 + 24px));
  bottom: 28px;
  z-index: 3;
  display: flex;
  gap: 10px;
  align-items: center;
  color: var(--text-mute);
  font-size: 0.82rem;
}

.hero__tip .badge {
  padding: 3px 8px;
  border-radius: 4px;
  background: rgba(0, 204, 76, 0.15);
  color: var(--brand);
  font-weight: 600;
}


.search { position: relative; }
.search-suggestions[hidden] { display: none; }
.search-suggestions {
  position: absolute;
  z-index: 20;
  inset: calc(100% + 6px) 0 auto;
  max-height: min(62vh, 30rem);
  overflow: auto;
  padding: 8px;
  background: var(--bg-soft, #17191e);
  border: 1px solid #ffffff30;
  border-radius: 10px;
  box-shadow: 0 10px 25px #0006;
}
.search-suggestions__heading { display: flex; justify-content: space-between; align-items: center; padding: 6px 8px; color: var(--text-dim); }
.search-suggestions button { text-align: start; white-space: normal; overflow-wrap: anywhere; }
.search-suggestions > button { display: block; width: 100%; padding: 8px; border-radius: 6px; }
.search-suggestions button:hover, .search-suggestions button:focus-visible { background: #ffffff12; }

.search-suggestions > .search-suggestions__hot { color: #ffd166; }

.search-suggestions__flame { margin-inline-start: 5px; font-size: 0.9em; }


.app-download { position: relative; }
.app-download > summary { list-style: none; cursor: pointer; white-space: nowrap; }
.app-download > summary::-webkit-details-marker { display: none; }
.app-download__options {
  position: absolute;
  z-index: 12;
  right: 0;
  top: calc(100% + 8px);
  display: flex;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg-elevated);
}
.app-download__platform { display: grid; gap: 8px; justify-items: center; }
.app-download__platform a { padding: 4px 8px; white-space: nowrap; }
.app-download__platform img { width: 116px; height: 116px; object-fit: contain; }
@media (max-width: 720px), (hover: none) and (pointer: coarse) {
  .app-download__platform img { display: none; }
}

.app-download:not([open]) > .app-download__options { display: none; }

/* —— Sections —— */
.home-intro {
  padding-top: 30px;
}

.home-intro h1 {
  border-left: 3px solid var(--brand);
  padding-left: 14px;
  color: var(--text);
  font-size: clamp(1.1rem, 1.8vw, 1.45rem);
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: 0.01em;
}

.section {
  padding: 36px 0 8px;
}

.section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.section__title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.section__more {
  color: var(--text-mute);
  font-size: 0.88rem;
  transition: color 0.2s;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font: inherit;
}

.section__more:hover {
  color: var(--brand);
}

.tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.tabs button {
  padding: 6px 14px;
  border-radius: 999px;
  color: var(--text-mute);
  font-size: 0.88rem;
  transition: color 0.2s, background 0.2s;
}

.tabs button.is-active,
.tabs button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
}

.tabs button.is-active {
  color: var(--brand);
}

/* —— Poster grid / rail —— */
.rail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 148px;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  padding-bottom: 12px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.rail::-webkit-scrollbar {
  height: 6px;
}

.rail::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
}

.poster {
  scroll-snap-align: start;
  group: poster;
}

.poster__cover {
  position: relative;
  aspect-ratio: 3 / 4.15;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-soft);
  transition: transform 0.35s var(--ease), box-shadow 0.35s;
}

.poster:hover .poster__cover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.poster__art {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: end start;
  padding: 14px;
}

.poster__art::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.12), transparent 45%),
    linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, 0.75) 100%);
}

.poster__glyph {
  position: relative;
  font-family: 'Outfit', sans-serif;
  font-size: 2.4rem;
  font-weight: 800;
  opacity: 0.18;
  line-height: 1;
}

.poster__score {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.55);
  color: #ffd166;
  font-size: 0.78rem;
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
}

.poster__tag {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--brand);
  color: #04140a;
  font-size: 0.72rem;
  font-weight: 700;
}

.poster__tag.is-new { background: #3b82f6; color: #fff; }

.poster__tag--bottom { top: auto; bottom: 10px; }
.poster__tag[style] {
  background: var(--poster-badge-color);
  color: white;
  text-shadow: 0 1px 2px #000, 0 0 2px #000;
}

.poster__play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.35);
  opacity: 0;
  transition: opacity 0.25s;
  z-index: 2;
}

.poster:hover .poster__play {
  opacity: 1;
}

.poster__play span {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--brand);
  display: grid;
  place-items: center;
  box-shadow: 0 8px 24px var(--brand-glow);
  transform: scale(0.9);
  transition: transform 0.25s var(--ease);
}

.poster:hover .poster__play span {
  transform: scale(1);
}

.poster__play svg {
  width: 18px;
  height: 18px;
  margin-left: 2px;
  color: #04140a;
}

.poster__body {
  padding-top: 10px;
}

.poster__title {
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.poster__tip {
  margin-top: 4px;
  font-size: 0.78rem;
  color: var(--text-mute);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.poster__ep {
  margin-top: 2px;
  font-size: 0.75rem;
  color: var(--brand-dim);
}

/* —— Split: rail + rank —— */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 28px;
  align-items: start;
  width: 100%;
  max-width: 100%;
}

.split > * {
  min-width: 0;
  max-width: 100%;
}

.rank-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 16px;
  position: sticky;
  top: calc(var(--nav-h) + 16px);
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

/* 锚点避开 sticky 顶栏 */
#tv,
#movie,
#anime,
#variety,
#like,
#rank,
#doc,
#kids {
  scroll-margin-top: calc(var(--nav-h) + 16px);
}

.rank-section {
  width: 100%;
}

.rank-board {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 16px;
}

.rank-panel__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  font-size: 1.05rem;
  font-weight: 700;
}

.rank-panel__title a {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-mute);
}

.rank-panel__title a:hover {
  color: var(--brand);
}

.rank-item {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 8px;
  border-radius: 8px;
  transition: background 0.2s;
}

.rank-item > div:nth-child(2) {
  min-width: 0;
}

.rank-item:hover {
  background: rgba(255, 255, 255, 0.04);
}

.rank-item__n {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--text-mute);
  text-align: center;
}

.rank-item:nth-child(-n + 3) .rank-item__n {
  color: var(--brand);
}

.rank-item__title {
  font-size: 0.9rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-item__heat {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  color: var(--text-mute);
}

/* —— Banner strip —— */
.promo {
  margin: 28px 0 8px;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  min-height: 88px;
  display: flex;
  align-items: center;
  padding: 20px 28px;
  background: linear-gradient(105deg, #12301c 0%, #0d1a14 40%, #1a1520 100%);
  border: 1px solid rgba(0, 204, 76, 0.2);
}

.promo::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 90% 50%, rgba(0, 204, 76, 0.18), transparent 55%);
  pointer-events: none;
}

.promo__text {
  position: relative;
  z-index: 1;
}

.promo__text strong {
  display: block;
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.promo__text span {
  color: var(--text-dim);
  font-size: 0.88rem;
}

/* —— Footer —— */
.footer {
  position: relative;
  margin-top: 72px;
  border-top: 1px solid rgba(0, 204, 76, 0.18);
  background: radial-gradient(ellipse at 3% 0%, rgba(0, 204, 76, 0.08), transparent 35%), #0b0f0e;
  color: var(--text-dim);
}

.footer::before {
  content: '';
  position: absolute;
  top: -1px;
  left: max(24px, calc((100% - var(--max)) / 2));
  width: 80px;
  height: 2px;
  background: var(--brand);
}

.footer__top {
  display: grid;
  grid-template-columns: minmax(220px, 1.1fr) minmax(0, 3fr);
  gap: clamp(28px, 6vw, 88px);
  padding: 54px 0 48px;
}

.footer__identity { max-width: 270px; }

.footer__eyebrow {
  margin-bottom: 12px;
  color: var(--brand);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.22em;
}

.footer__brand {
  display: inline-block;
  font-family: 'Outfit', 'Noto Sans SC', sans-serif;
  font-size: 1.55rem;
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
}

.footer__brand span {
  color: var(--brand);
}

.footer__tagline {
  margin-top: 16px;
  color: var(--text-dim);
  font-size: 0.84rem;
  line-height: 1.8;
}

.footer__nav {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
  min-width: 0;
}

.footer__section h2 {
  margin-bottom: 16px;
  color: var(--text);
  font-size: 0.81rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.footer__section ul {
  list-style: none;
  display: grid;
  gap: 6px;
}

.footer__section a {
  display: inline-block;
  min-height: 32px;
  padding: 5px 0;
  color: var(--text-dim);
  font-size: 0.81rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
  transition: color 0.2s ease;
}

.footer a:hover {
  color: var(--brand);
}

.footer a:focus-visible {
  color: var(--brand);
  outline: 2px solid var(--brand);
  outline-offset: 4px;
  border-radius: 2px;
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
  padding: 20px 0 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-dim);
  font-size: 0.73rem;
}

/* Keep direct-file previews readable; live pages use the shared footer above. */
.footer__grid {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 1fr);
  gap: 28px;
  padding: 40px 0 28px;
}

.footer__grid h4 { margin-bottom: 12px; color: var(--text); }
.footer__grid ul { list-style: none; display: grid; gap: 8px; }
.footer__copy {
  padding: 18px 0 28px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 0.73rem;
}


.poster { position: relative; }
.poster__link { display: block; color: inherit; text-decoration: none; }
.poster__actions {
  position: absolute;
  inset: 0 0 auto;
  aspect-ratio: 3 / 4.15;
  padding: 8px;
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  pointer-events: none;
  gap: 6px;
  z-index: 2;
}
.poster__action {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #ffffff44;
  border-radius: 50%;
  background: #14171eee;
  color: #fff;
  cursor: pointer;
  pointer-events: auto;
}
.poster__action svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.poster__action--follow[aria-pressed="true"] { color: #45e486; }
.poster__action--like[aria-pressed="true"] { color: #ff74ac; }
.poster__action[aria-pressed="true"] svg { fill: currentColor; }
.poster__action:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
@media (hover: hover) and (pointer: fine) {
  .poster__action { width: 30px; height: 30px; }
  .poster__action svg { width: 16px; height: 16px; }
}

@media (hover: none) and (pointer: coarse) {
  .poster__actions { gap: 2px; padding: 5px; }

  .poster__action {
    position: relative;
    border: 0;
    background: transparent;
  }

  .poster__action::before {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid #ffffff44;
    border-radius: 50%;
    background: #14171eee;
  }

  .poster__action svg { position: relative; width: 14px; height: 14px; }
}

.home-rank__head { flex-wrap: wrap; gap: 8px 16px; }
.home-rank__tabs { display: flex; align-items: center; gap: 6px; }
.home-rank__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(235px, 28%); align-items: start; gap: 20px; }
.home-rank__cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 140px), 1fr)); gap: 12px; }
.home-rank__layout #rank-board { grid-template-columns: minmax(0, 1fr); }
.home-rank__layout [hidden] { display: none; }
@media (max-width: 720px) {
  .home-rank__layout { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .home-rank__cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* —— Detail page —— */
.detail-hero {
  position: relative;
  min-height: 420px;
  padding: 48px 0 40px;
  overflow: hidden;
}
.detail-hero.is-coverless {
  min-height: 0;
  padding: 38px 0 28px;
}
.detail-hero.is-coverless .detail-layout {
  grid-template-columns: minmax(0, 1fr);
}
.detail-cover[hidden], #related-section[hidden], #related-rail .poster[hidden] { display: none; }

.detail-hero__bg {
  position: absolute;
  inset: 0;
  filter: blur(0);
}

.detail-hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(11, 12, 16, 0.97) 0%, rgba(11, 12, 16, 0.75) 45%, rgba(11, 12, 16, 0.55) 100%),
    linear-gradient(180deg, transparent 60%, var(--bg) 100%);
}

.detail-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 32px;
  align-items: end;
}

.detail-cover {
  position: relative;
  aspect-ratio: 3 / 4.15;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.detail-info h1 {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 900;
  margin-bottom: 10px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--text-dim);
  font-size: 0.9rem;
  margin-bottom: 14px;
}

.detail-meta .score {
  color: #ffd166;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
}

.detail-desc {
  color: var(--text-dim);
  margin: 16px 0 0;
}

.detail-desc:empty { display: none; }

.detail-info .hero__cta {
  opacity: 1;
  transform: none;
}

@media (max-width: 720px) {
  .detail-hero, .detail-hero.is-coverless {
    min-height: 0;
    padding: 20px 0 10px;
  }
  .detail-info .hero__cta { gap: 8px; }
  .detail-info .hero__cta > * { padding: 7px 12px; font-size: 0.82rem; }
  #detail-page .player { margin-top: 0; }
}

.player {
  margin-top: 8px;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  position: relative;
}

.player__placeholder {
  text-align: center;
  color: var(--text-dim);
}

.player__placeholder strong {
  display: block;
  color: var(--text);
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.player__locked {
  margin: 0;
  padding: 1.25rem;
  color: var(--text);
  line-height: 1.6;
}

.episodes {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.episodes button {
  min-width: 48px;
  height: 40px;
  padding: 0 12px;
  border-radius: 8px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  color: var(--text-dim);
  transition: all 0.2s;
}

.episodes button:hover,
.episodes button.is-active {
  border-color: var(--brand);
  color: var(--brand);
  background: rgba(0, 204, 76, 0.08);
}

/* —— Responsive —— */
@media (max-width: 1280px) {
  .topbar__inner {
    gap: 14px;
  }

  .nav a {
    padding: 8px 8px;
  }

  .search {
    width: min(200px, 22vw);
  }
}

@media (max-width: 1024px) {
  .split {
    grid-template-columns: minmax(0, 1fr);
  }

  .rank-panel {
    position: static;
  }

  .rank-board {
    grid-template-columns: minmax(0, 1fr);
  }

  .search {
    display: none;
  }

  #list-page .topbar__actions .btn-ghost[href="index.html"] {
    display: none;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer__top {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 44px 0 36px;
  }

  .footer__identity { max-width: 520px; }

  .footer__nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 32px;
  }
}

@media (max-width: 720px) {
  .container {
    width: min(100% - 28px, var(--max));
  }

  .nav {
    display: none;
  }

  .topbar__actions .btn-ghost {
    display: none;
  }

  .hero {
    min-height: 480px;
  }

  .hero__dots {
    flex-direction: row;
    right: 24px;
    bottom: 24px;
  }

  .hero__dot.is-active {
    width: 22px;
    height: 8px;
  }

  .hero__tip {
    display: none;
  }

  .rail {
    grid-auto-columns: 132px;
    gap: 12px;
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-cover {
    max-width: 180px;
  }

  .footer {
    margin-top: 32px;
  }

  .footer__top { padding: 36px 0 30px; gap: 28px; }
  .footer__eyebrow { margin-bottom: 9px; }
  .footer__brand { font-size: 1.35rem; }
  .footer__tagline { margin-top: 10px; }
  .footer__nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 20px; }
  .footer__section h2 { margin-bottom: 9px; }
  .footer__section a { min-height: 40px; padding: 9px 0; }
  .footer__bottom { flex-direction: column; padding: 18px 0 24px; }

  .footer__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px 10px;
    margin-bottom: 14px;
  }

  .footer__grid > :first-child {
    grid-column: 1 / -1;
  }

  .footer__grid > :first-child p {
    margin: 0;
    line-height: 1.45;
  }

  .footer h4 {
    margin-bottom: 8px;
    font-size: 0.8rem;
  }

  .footer ul {
    gap: 5px;
  }

  .footer__copy {
    padding-top: 12px;
    font-size: 0.75rem;
  }
}

/* entrance */
@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.section {
  animation: rise-in 0.6s var(--ease) both;
}

.section:nth-of-type(2) { animation-delay: 0.05s; }
.section:nth-of-type(3) { animation-delay: 0.1s; }
.section:nth-of-type(4) { animation-delay: 0.15s; }

/* —— List page —— */
.list-page {
  padding: 28px 0 48px;
  min-height: 60vh;
}

.list-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
  padding-top: 12px;
}

.list-hero__eyebrow {
  font-family: 'Outfit', sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 8px;
}

.list-hero__title {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 900;
}

.list-hero__desc {
  margin-top: 6px;
  color: var(--text-mute);
  font-size: 0.92rem;
}

.list-hero__stat {
  text-align: right;
  color: var(--text-mute);
  font-size: 0.82rem;
}

.list-hero__stat strong {
  display: block;
  font-family: 'Outfit', sans-serif;
  font-size: 1.8rem;
  color: var(--text);
  line-height: 1.1;
}

.filter-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0;
  margin-bottom: 18px;
  overflow: hidden;
}

.filter-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
}

.filter-panel__title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 12px;
  min-width: 0;
}

.filter-panel__title strong {
  font-size: 0.92rem;
}

.filter-panel__summary {
  color: var(--text-mute);
  font-size: 0.82rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: min(100%, 52vw);
}

.filter-panel__toggle {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-dim);
  font-size: 0.82rem;
  background: rgba(255, 255, 255, 0.03);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.filter-panel__toggle:hover {
  color: var(--brand);
  border-color: rgba(0, 204, 76, 0.35);
  background: rgba(0, 204, 76, 0.08);
}

.filter-panel__chevron {
  display: inline-block;
  font-size: 0.75rem;
  line-height: 1;
  transition: transform 0.2s var(--ease);
}

.filter-panel.is-collapsed .filter-panel__chevron {
  transform: rotate(180deg);
}

.filter-panel__body {
  padding: 0 16px 12px;
  border-top: 1px solid transparent;
  transition: opacity 0.2s;
}

.filter-panel:not(.is-collapsed) .filter-panel__body {
  border-top-color: var(--line);
}

.filter-panel.is-collapsed .filter-panel__body {
  display: none;
}

.filter-row {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 12px;
  align-items: start;
  padding: 8px 0;
}

.filter-row + .filter-row {
  border-top: 1px solid var(--line);
}

.filter-row__label {
  color: var(--text-mute);
  font-size: 0.86rem;
  padding-top: 6px;
}

.filter-row__opts {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  align-items: center;
  min-width: 0;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.filter-row__opts::-webkit-scrollbar {
  height: 3px;
}

.filter-row__opts::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
}

.filter-row__opts button {
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: 999px;
  color: var(--text-dim);
  font-size: 0.84rem;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.filter-row__opts button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.filter-row__opts button.is-active {
  color: var(--brand);
  background: rgba(0, 204, 76, 0.1);
  border-color: rgba(0, 204, 76, 0.28);
}

.list-toolbar {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 16px;
}

.list-toolbar__hint {
  color: var(--text-mute);
  font-size: 0.86rem;
  overflow-wrap: anywhere;
}

.list-toolbar__search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(100%, 260px);
}

.list-toolbar__search input {
  flex: 1;
  min-width: 0;
  height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid #454545;
  background: #1e1e1e;
  color: #d4d4d4;
  font-size: 0.84rem;
}

.list-toolbar__search button {
  height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid rgba(0, 204, 76, 0.35);
  background: rgba(0, 204, 76, 0.1);
  color: var(--brand);
  font-size: 0.82rem;
  cursor: pointer;
  white-space: nowrap;
}

.poster-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px 14px;
}


.list-empty {
  text-align: center;
  color: var(--text-mute);
  padding: 48px 16px;
}

.pager {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 28px;
}

.pager button {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  color: var(--text-dim);
  background: var(--bg-soft);
}

.pager button.pager__nav {
  min-width: 72px;
}

.pager button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.pager button.is-active,
.pager button:hover:not(:disabled) {
  color: var(--brand);
  border-color: rgba(0, 204, 76, 0.35);
}

.pager__ellipsis {
  color: var(--text-mute);
  padding: 0 2px;
  user-select: none;
}

.pager__meta {
  width: 100%;
  text-align: center;
  margin-top: 4px;
  font-size: 13px;
  color: var(--text-mute);
}

@media (max-width: 1100px) {
  .poster-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .list-hero { align-items: flex-start; flex-direction: column; }
  .list-hero__stat { text-align: left; }
  .filter-row { grid-template-columns: 1fr; gap: 8px; }
  .poster-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}


/* m5 player styles, adapted to the existing stage. */
.custom-video button { border: 0; background: none; padding: 0; }
.video-stage{position:relative;aspect-ratio:16/9;max-height:78svh;min-height:260px;border:1px solid #ffffff1b;border-radius:16px;overflow:hidden;background:#050508;margin:auto;display:grid;place-items:center}.video-stage video{display:block;width:100%;height:100%;max-height:78svh;object-fit:contain}.video-status{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:14px;background:#08091096;color:var(--text-dim);font-size:13px;pointer-events:none}.video-status h2{font-size:22px;margin:6px 0;font-weight:500}.video-status p{font-size:12px;margin:0 20px 15px;text-align:center}.video-error{background:#101018ed;pointer-events:auto}.video-error .primary-button{font-size:12px}.loading-ring{width:26px;height:26px;border:2px solid #ffffff20;border-top-color:var(--brand);border-radius:50%;animation:loading-spin 1s linear infinite}@keyframes loading-spin{to{transform:rotate(360deg)}}
.custom-video.video-stage{position:relative;width:100%;height:clamp(420px,calc(100svh - var(--header-h) - 114px),720px);aspect-ratio:auto;border-radius:16px;background:#000;overflow:hidden;isolation:isolate}
.custom-video.video-stage video{display:block;width:100%;height:100%;max-height:none;object-fit:contain;background:#000}
.custom-video button{display:inline-flex;align-items:center;justify-content:center;min-width:44px;min-height:44px;border-radius:8px;color:var(--brand)}.custom-video button:disabled{color:#827987;opacity:.55;cursor:not-allowed;background:#25212a44}.player-return{position:absolute;left:14px;top:14px;z-index:5;background:#262329bb;border-radius:50%!important}.player-episode-nav{position:absolute;right:12px;top:42%;display:flex;flex-direction:column;gap:10px;z-index:5}.player-episode-nav button{background:#262329bb;border-radius:50%}.player-center-play{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);border-radius:50%!important;width:60px;height:60px;background:rgba(0,204,76,.24);z-index:2}.player-controls{position:absolute;bottom:0;left:0;right:0;z-index:4;padding:10px 12px 4px;background:linear-gradient(transparent,#060407ef 25%)}.player-controls input[type=range]{accent-color:var(--brand);cursor:pointer;min-width:0}.player-seek{display:block;width:100%;height:28px;margin:0}.player-toolbar{display:flex;align-items:center;gap:4px}.player-time{font-size:12px;font-variant-numeric:tabular-nums;white-space:nowrap;margin-right:auto}.player-volume{display:flex;align-items:center}.player-volume input{width:70px;height:44px;margin:0 6px 0 0}.player-toolbar select{background:#10251a;color:var(--brand);border:1px solid rgba(0,204,76,.35);border-radius:6px;height:30px;width:56px;max-width:56px;min-width:0;padding:0 3px;font-size:11px}.custom-video .video-status{position:absolute;inset:60px 64px 90px;z-index:3;pointer-events:none;font-size:13px;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;background:#0009}.custom-video .video-error{pointer-events:auto;inset:70px 12px 92px}.video-error h2{font-size:18px}.custom-video .video-error p{font-size:12px}.custom-video .video-error button{gap:8px;padding:0 14px}.player-notice{position:absolute;left:12px;right:12px;top:65px;z-index:6;background:#10251a;padding:10px;font-size:12px;color:var(--text);border-radius:8px}.custom-video:fullscreen{width:100%;height:100%;border-radius:0;max-height:none}.custom-video:fullscreen video{height:100%;width:100%}

.qm-player .custom-video{--control-height:86px}.qm-player .custom-video.video-stage{display:block;width:100%;height:100%;min-height:0;max-height:none}.qm-player .custom-video.video-stage video{height:calc(100% - var(--control-height));max-height:none;margin:0}.qm-player .player-center-play{top:calc((100% - var(--control-height))/2)}
.player:has(.video-stage[data-orientation="portrait"]){height:min(80svh,760px);aspect-ratio:auto;display:flex;justify-content:center;align-items:stretch;background:#080b0b}
.player:has(.video-stage[data-orientation="portrait"]) .player__placeholder.qm-player{width:min(100%,420px);flex:none}
.qm-player .custom-video.video-stage video{object-fit:contain}
@media(max-width:540px){.qm-player .player-volume input{width:40px}.qm-player .player-toolbar{flex-wrap:wrap;gap:0}.qm-player .player-time{font-size:11px}}
.qm-player .video-slow button{pointer-events:auto}.qm-player .primary-button{background:var(--brand);padding:10px 14px;border-radius:8px;color:white}.player{scroll-margin-top:80px}.player__placeholder.qm-player{width:100%;height:100%;display:block}
.qm-player .custom-video:fullscreen{height:100vh;width:100vw}

.growth-page{max-width:900px;padding-block:36px;line-height:1.9}.growth-page h1{font-size:clamp(24px,4vw,36px);line-height:1.4}.growth-page p{margin-block:20px}.growth-editorial,.growth-app{max-width:1200px;margin:24px auto;padding:24px;border:1px solid var(--line);border-radius:14px}.growth-editorial a,.growth-page a{color:#68de9b}.growth-button{display:inline-block;background:#176d3c;color:white!important;border-radius:8px;padding:10px 16px;margin:8px 8px 0 0}.growth-app p{color:var(--text-dim)}

/* Match the player controls to Qingmang on desktop, mobile and fullscreen. */
.player-toolbar select:focus-visible,
.custom-video button:focus-visible,
.player-controls input[type=range]:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}
.player-toolbar select option { background: #10251a; color: var(--brand); }
.custom-video button:not(:disabled):hover { color: var(--brand); background-color: rgba(0, 204, 76, .14); }
@media (max-width: 540px) {
  .qm-player .player-controls { padding-inline: 8px; }
  .qm-player .player-volume input { width: 28px; margin-right: 2px; }
  .qm-player .player-toolbar { flex-wrap: nowrap; }
  .qm-player .player-toolbar select { flex: 0 0 52px; width: 52px; }
}

.pager__numbers { display: inline-flex; align-items: center; gap: 8px; }
.pager__numbers--mobile { display: none; }
@media (max-width: 540px) {
  .pager { column-gap: 4px; row-gap: 6px; }
  .pager__numbers--desktop { display: none; }
  .pager__numbers--mobile { display: inline-flex; gap: 4px; }
  .pager button { min-width: 30px; height: 34px; padding: 0 5px; border-radius: 7px; font-size: 12px; white-space: nowrap; }
  .pager button.pager__nav { min-width: 50px; padding-inline: 5px; }
  .pager__ellipsis { padding: 0; font-size: 12px; }
  .pager__meta { margin-top: 0; font-size: 11px; }
}

.list-toolbar__search input::placeholder { color: #a3a3a3; }
.list-toolbar__search input:focus-visible {
  outline: 2px solid #909090;
  outline-offset: 2px;
  border-color: #909090;
}

.list-empty__icon { width: min(220px, 70%); height: auto; margin: 0 auto 16px; }
.list-empty__home { display: inline-flex; align-items: center; justify-content: center; margin-top: 18px; min-height: 40px; padding: 8px 20px; border: 1px solid rgba(0, 204, 76, .35); border-radius: 8px; color: var(--brand); background: rgba(0, 204, 76, .08); }
.list-empty__home:hover { background: rgba(0, 204, 76, .16); }
.list-empty__home:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
@media (max-width: 720px) {
  .list-empty { padding: 28px 12px; }
  .list-empty__icon { width: 180px; max-width: 65%; margin-bottom: 12px; }
}

#list-page.is-search-results #filter-panel,
#list-page.is-search-results .list-toolbar,
#list-page.is-search-results .list-empty__home[href],
#list-page:not(.is-search-results) #edit-search { display: none; }

/* Work ratings */
.poster__rating { right: auto; left: 10px; }
.poster__rating[hidden], #video-rating [hidden] { display: none; }

#video-rating { margin-block: 4px 8px; }
.video-rating__summary { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 4px; font-size: .95rem; }
.video-rating__summary [data-rating-platform] { color: #ffd166; }
#video-rating form:not([hidden]) { display: flex; flex-wrap: wrap; align-items: end; gap: 4px 12px; }
#video-rating fieldset { border: 0; padding: 0; margin: 4px 0 0; }
#video-rating legend { font-size: .82rem; color: var(--text-dim); }
.video-rating__stars { display: flex; flex-wrap: wrap; width: fit-content; }
.video-rating__star {
  --rating-fill: 0%;
  position: relative;
  display: inline-flex;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-size: 30px;
  line-height: 1;
}
.video-rating__star::before, .video-rating__star::after {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}
.video-rating__star::before { content: '☆'; }
.video-rating__star::after {
  content: '★';
  color: #ffd166;
  clip-path: inset(0 calc(100% - var(--rating-fill)) 0 0);
}
.video-rating__star label { display: block; position: relative; width: 50%; height: 100%; cursor: pointer; }
.video-rating__star input { position: absolute; inset: 0; opacity: 0; margin: 0; width: 100%; height: 100%; cursor: inherit; }
.video-rating__star label:has(input:focus-visible) { outline: 2px solid var(--brand); outline-offset: -1px; }

.split--iq.split--iq--single { grid-template-columns: minmax(0, 1fr); }
.period-rank-group { margin-block: 24px; }
.period-rank-group h2 { margin-bottom: 12px; }
.period-rank-board { margin-bottom: 16px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; }
.period-rank-board h3 { margin: 0 0 12px; }
.period-rank-board ol { list-style: none; margin: 0; padding: 0; }
.period-rank-board li + li { border-top: 1px solid var(--line); }
.period-rank-board li a { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 8px 0; color: inherit; }
.period-rank-board li a:hover strong { color: var(--brand); }
.period-rank-board img, .period-rank-cover { width: 58px; height: 78px; flex: 0 0 58px; border-radius: 6px; background: var(--bg-soft); object-fit: cover; }
.period-rank-number { min-width: 2ch; text-align: center; font-variant-numeric: tabular-nums; color: var(--brand); font-weight: 700; }
.period-rank-board small { display: block; margin-top: 4px; color: var(--text-dim); }
.period-rank-board strong { overflow-wrap: anywhere; }

.qm-share-entry:not([data-share-web="true"]) { display: none !important; }
.qm-share-entry[hidden], .detail-share-dialog [hidden] { display: none !important; }
@media (max-width: 720px) {
  .qm-share-entry:not([data-share-h5="true"]) { display: none !important; }
  .qm-share-entry[data-share-h5="true"]:not([hidden]) { display: inline-flex !important; }
}
.custom-video .player-share { position: absolute; right: 14px; top: 14px; z-index: 5; background: #262329bb; }
.detail-share-dialog {
  position: fixed;
  inset: auto;
  top: 50vh;
  top: 50dvh;
  left: 50vw;
  transform: translate(-50%, -50%);
  margin: 0;
  box-sizing: border-box;
  max-height: calc(100% - 32px);
  overflow: auto;
  width: min(480px, calc(100% - 32px));
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-soft, #17191e);
  color: var(--text, #fff);
}
.detail-share-dialog::backdrop { background: rgb(0 0 0 / 65%); }
.detail-share-dialog h2 { margin-bottom: 12px; }
.detail-share-dialog input { width: 100%; padding: 9px 10px; border: 1px solid var(--line); border-radius: 6px; color: inherit; background: transparent; }
.detail-share-dialog__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.detail-share-dialog [role="status"]:empty { display: none; }

.playback-feedback-dialog form, .playback-feedback-dialog label {
  display: grid;
  gap: 8px;
}
.playback-feedback-dialog select, .playback-feedback-dialog textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--bg-elevated);
  color: inherit;
  font: inherit;
}
.playback-feedback-dialog [data-feedback-status]:empty { display: none; }
[data-playback-feedback-open][hidden] { display: none; }

/* —— Auth pages —— */
.auth-body {
  min-height: 100vh;
  background: #07080c;
}

.auth-shell {
  min-height: calc(100vh - 220px);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
}

.auth-body .footer {
  margin-top: 0;
}

.auth-visual {
  position: relative;
  overflow: hidden;
  padding: 36px 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(ellipse 70% 60% at 20% 20%, rgba(0, 204, 76, 0.18), transparent 55%),
    linear-gradient(160deg, #10151a 0%, #0b0c10 45%, #141018 100%);
  border-right: 1px solid var(--line);
}

.auth-visual--register {
  background:
    radial-gradient(ellipse 70% 60% at 70% 30%, rgba(0, 168, 62, 0.2), transparent 55%),
    linear-gradient(160deg, #0e1612 0%, #0b0c10 50%, #12141a 100%);
}

.auth-visual__glow {
  position: absolute;
  width: 420px;
  height: 420px;
  right: -80px;
  bottom: -60px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 204, 76, 0.22), transparent 68%);
  pointer-events: none;
  animation: auth-pulse 5s ease-in-out infinite;
}

@keyframes auth-pulse {
  0%, 100% { transform: scale(1); opacity: 0.85; }
  50% { transform: scale(1.08); opacity: 1; }
}

.auth-visual__logo {
  position: relative;
  z-index: 1;
  width: fit-content;
}

.auth-visual__copy {
  position: relative;
  z-index: 1;
  max-width: 420px;
  padding-bottom: 24px;
}

.auth-visual__eyebrow {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 16px;
}

.auth-visual__copy h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
}

.auth-visual__copy p:last-child {
  color: var(--text-dim);
  font-size: 1rem;
  max-width: 36ch;
}

.auth-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 40px 48px;
  background: var(--bg);
}

.auth-back {
  align-self: flex-start;
  margin-bottom: 24px;
  color: var(--text-mute);
  font-size: 0.9rem;
  transition: color 0.2s;
}

.auth-back:hover {
  color: var(--brand);
}

.auth-card {
  width: min(100%, 420px);
  margin: 0 auto;
}

.auth-card h2 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.auth-card__sub {
  color: var(--text-mute);
  margin-bottom: 22px;
  font-size: 0.92rem;
}

.auth-demo {
  margin-bottom: 18px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(0, 204, 76, 0.06);
  border: 1px solid rgba(0, 204, 76, 0.2);
  display: grid;
  gap: 8px;
}

.auth-demo__title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--brand);
}

.auth-demo__item {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border-radius: 8px;
  text-align: left;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid transparent;
  color: var(--text);
  transition: border-color 0.2s, background 0.2s;
}

.auth-demo__item:hover {
  border-color: rgba(0, 204, 76, 0.35);
  background: rgba(0, 204, 76, 0.08);
}

.auth-demo__item strong {
  font-size: 0.92rem;
}

.auth-demo__item span {
  font-size: 0.78rem;
  color: var(--text-mute);
}

.auth-demo__tip {
  font-size: 0.78rem;
  color: var(--text-mute);
}

.auth-demo__tip b {
  color: var(--brand);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 4px;
  margin-bottom: 20px;
  border-radius: 12px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
}

.auth-tabs button {
  height: 38px;
  border-radius: 9px;
  color: var(--text-mute);
  font-size: 0.9rem;
  font-weight: 500;
}

.auth-tabs button.is-active {
  color: var(--text);
  background: rgba(0, 204, 76, 0.14);
  color: var(--brand);
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-field {
  display: grid;
  gap: 8px;
}

.auth-field > span {
  font-size: 0.84rem;
  color: var(--text-dim);
}

.auth-field input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-field input:focus {
  border-color: rgba(0, 204, 76, 0.45);
  box-shadow: 0 0 0 3px rgba(0, 204, 76, 0.12);
}

.auth-field input::placeholder {
  color: var(--text-mute);
}

.auth-field__row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}

.auth-eye,
.auth-code-btn {
  height: 46px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-soft);
  color: var(--text-dim);
  white-space: nowrap;
  font-size: 0.84rem;
}

.auth-eye:hover,
.auth-code-btn:hover:not(:disabled) {
  color: var(--brand);
  border-color: rgba(0, 204, 76, 0.35);
}

.auth-code-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.auth-form__extra {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.86rem;
  color: var(--text-mute);
}

.auth-form__extra a:hover {
  color: var(--brand);
}

.auth-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}

.auth-check--block {
  align-items: flex-start;
  font-size: 0.86rem;
  color: var(--text-mute);
  line-height: 1.45;
}

.auth-check input {
  margin-top: 2px;
  accent-color: var(--brand);
}

.auth-check a {
  color: var(--brand);
}

.auth-error {
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 77, 106, 0.1);
  border: 1px solid rgba(255, 77, 106, 0.28);
  color: #ff8da0;
  font-size: 0.86rem;
}

.auth-submit {
  height: 48px;
  border-radius: 999px;
  background: var(--brand);
  color: #04140a;
  font-weight: 700;
  font-size: 0.98rem;
  transition: transform 0.2s var(--ease), box-shadow 0.2s, background 0.2s;
}

.auth-submit:hover {
  background: #19e063;
  transform: translateY(-1px);
  box-shadow: 0 12px 28px var(--brand-glow);
}

.auth-agree {
  margin-top: 18px;
  text-align: center;
  color: var(--text-mute);
  font-size: 0.84rem;
}

.auth-agree a {
  color: var(--brand);
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  transition: border-color 0.2s, background 0.2s;
}

.user-chip:hover {
  border-color: rgba(0, 204, 76, 0.35);
  background: rgba(0, 204, 76, 0.08);
}

.btn-follow.is-followed {
  border-color: rgba(0, 204, 76, 0.4);
  color: var(--brand);
  background: rgba(0, 204, 76, 0.12);
}

.btn-share {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-weight: 500;
  transition: background 0.2s, border-color 0.2s;
}

.btn-share:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.28);
}

.qm-toast {
  position: fixed;
  left: 50%;
  bottom: 36px;
  transform: translateX(-50%);
  z-index: 9999;
  display: grid;
  gap: 8px;
  pointer-events: none;
}

.qm-toast__item {
  min-width: 160px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(20, 24, 32, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text);
  font-size: 0.88rem;
  text-align: center;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.25s, transform 0.25s;
}

.qm-toast__item.is-show {
  opacity: 1;
  transform: none;
}

.qm-toast__item.is-ok {
  border-color: rgba(0, 204, 76, 0.35);
}

.qm-toast__item.is-mute {
  border-color: rgba(255, 255, 255, 0.12);
}

.user-chip__name {
  font-size: 0.86rem;
  color: var(--text-dim);
  max-width: 88px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-chip__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #00e65a, #009c38);
  color: #04140a;
  font-size: 0.78rem;
  font-weight: 800;
}

.user-chip__logout {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  color: var(--text-mute);
}

.user-chip__logout:hover {
  color: var(--danger);
}

@media (max-width: 900px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-visual {
    min-height: 220px;
    padding: 24px;
    border-right: none;
    border-bottom: 1px solid var(--line);
  }

  .auth-visual__copy h1 {
    font-size: 1.8rem;
  }

  .auth-panel {
    padding: 28px 20px 40px;
  }
}


/* Keep mobile account pages focused on the form. */
@media (max-width: 720px) {
  .auth-body .auth-visual { display: none; }
}

/* ============================================
   爱奇艺风格首页布局（home-iq）
   ============================================ */
.home-iq,
.site-shell {
  --nav-h: var(--nav-iq);
}

.topbar--iq {
  height: auto;
  background: #0b0c10;
  border-bottom: 1px solid var(--line);
}

.topbar--iq .topbar__row {
  height: 60px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.search--center {
  flex: 1;
  max-width: 520px;
  margin: 0 auto;
  width: auto;
  height: 40px;
  /* 按钮上下与右侧留白统一为 4px */
  padding: 4px 4px 4px 12px;
  gap: 8px;
  border-radius: 8px;
  background: #1e1e1e;
  border: 1px solid #454545;
  align-items: stretch;
  cursor: text;
}

.search__btn {
  height: auto;
  align-self: stretch;
  margin: 0;
  padding: 0 14px;
  border-radius: 6px;
  background: var(--brand);
  color: #04140a;
  font-size: 0.84rem;
  font-weight: 700;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.search--center svg {
  align-self: center;
}

.search--center input {
  align-self: stretch;
  padding: 0;
}

.btn-link {
  padding: 6px 8px;
  color: var(--text-dim);
  font-size: 0.88rem;
  background: none;
  border: none;
}

.btn-link:hover {
  color: var(--brand);
}

.channel-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  background: #0e1016;
}

.channel-bar__inner {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 44px;
  overflow-x: auto;
  scrollbar-width: none;
}

.channel-bar__inner::-webkit-scrollbar {
  display: none;
}

.channel-bar__inner a {
  flex-shrink: 0;
  padding: 6px 12px;
  color: var(--text-dim);
  font-size: 0.92rem;
  font-weight: 500;
  border-radius: 4px;
  white-space: nowrap;
}

.channel-bar__inner a:hover,
.channel-bar__inner a.is-active {
  color: var(--brand);
}

/* 焦点区：主视觉 + 右侧列表 */
.focus {
  position: relative;
  padding-top: 16px;
  background: linear-gradient(180deg, #12141c 0%, var(--bg) 100%);
}

.focus__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 14px;
  align-items: stretch;
  min-height: 360px;
}

.focus__main {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  min-height: 360px;
  background: #151820;
}

.focus__slides {
  position: absolute;
  inset: 0;
}

.focus__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s var(--ease), visibility 0.45s;
}

.focus__slide.is-active {
  opacity: 1;
  visibility: visible;
}

.focus__bg {
  position: absolute;
  inset: 0;
}

.focus__art {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.focus__art::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 10, 14, 0.92) 0%, rgba(8, 10, 14, 0.45) 48%, rgba(8, 10, 14, 0.2) 100%),
    linear-gradient(180deg, transparent 50%, rgba(8, 10, 14, 0.85) 100%);
}

.focus__glyph {
  position: relative;
  z-index: 1;
  font-family: 'Outfit', sans-serif;
  font-size: 8rem;
  font-weight: 800;
  opacity: 0.12;
  color: #fff;
}

.focus__info {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
  z-index: 2;
  max-width: 520px;
}

.focus__badges {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.focus__tag {
  padding: 2px 8px;
  border-radius: 3px;
  background: var(--danger);
  font-size: 0.75rem;
  font-weight: 700;
}

.focus__tip {
  color: var(--text-dim);
  font-size: 0.84rem;
}

.focus__title {
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
  font-weight: 900;
  letter-spacing: 0.04em;
  margin-bottom: 8px;
  line-height: 1.15;
}

.focus__meta {
  color: var(--text-dim);
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.focus__desc {
  color: rgba(242, 244, 247, 0.78);
  font-size: 0.92rem;
  margin-bottom: 16px;
  max-width: 42ch;
}

.focus__cta {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

.focus__badge-line span {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 3px;
  background: rgba(0, 204, 76, 0.15);
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 600;
}

.focus__list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.focus-item {
  display: grid;
  grid-template-columns: 22px 48px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 8px;
  border-radius: 6px;
  text-align: left;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid transparent;
  transition: background 0.2s, border-color 0.2s;
}

.focus-item:hover,
.focus-item.is-active {
  background: rgba(0, 204, 76, 0.08);
  border-color: rgba(0, 204, 76, 0.25);
}

.focus-item__n {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  color: var(--text-mute);
  text-align: center;
}

.focus-item:nth-child(-n + 3) .focus-item__n,
.focus-item.is-active .focus-item__n {
  color: var(--brand);
}

.focus-item__thumb {
  width: 48px;
  height: 64px;
  border-radius: 4px;
  background-size: cover;
}

.focus-item__body {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.focus-item__title {
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.focus-item__tip {
  font-size: 0.72rem;
  color: var(--text-mute);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.focus-item__tag {
  font-size: 0.7rem;
  color: var(--danger);
  font-weight: 700;
}

/* 收藏条：仅在有已收藏海报时显示，轨道内横向滚动 */
.follow-strip {
  width: 100%;
  margin-top: 10px;
  padding: 12px 0 10px;
  background: rgba(0, 0, 0, 0.22);
  border-top: 1px solid var(--line);
  overflow: hidden;
}

.follow-strip__inner {
  display: flex;
  align-items: stretch;
  gap: 12px;
  width: min(100% - 48px, var(--max));
  margin-inline: auto;
  min-width: 0;
  overflow: hidden;
  box-sizing: border-box;
}

.follow-strip__side {
  flex: 0 0 84px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 4px 0;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.15s var(--ease);
}

.follow-strip__side:hover {
  background: rgba(0, 204, 76, 0.08);
}

.follow-strip__label {
  letter-spacing: 0.04em;
  color: var(--brand);
  font-size: 0.88rem;
  font-weight: 800;
  line-height: 1;
}

.follow-strip__more {
  letter-spacing: 0.02em;
  font-size: 0.68rem;
  color: var(--text-mute);
  line-height: 1;
}

.follow-strip__side:hover .follow-strip__more {
  color: var(--brand);
}

.follow-strip__rail {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0 0 6px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
}

.follow-strip__rail::-webkit-scrollbar {
  height: 3px;
}

.follow-strip__rail::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
}

@media (max-width: 720px) {
  .follow-strip__inner {
    width: min(100% - 28px, var(--max));
  }
}

.follow-card {
  flex: 0 0 88px;
  width: 88px;
  max-width: 88px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: none;
  box-sizing: border-box;
}

.follow-card.is-followed .follow-card__btn {
  border-color: rgba(0, 204, 76, 0.4);
  background: rgba(0, 204, 76, 0.12);
}

.follow-card__cover {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 100%;
  height: 112px;
  border-radius: 6px;
  overflow: hidden;
  text-decoration: none;
}

.follow-card__cover span {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  opacity: 0.28;
  color: #fff;
}

.follow-card__title {
  display: block;
  font-size: 0.74rem;
  line-height: 1.25;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
}

.follow-card__title:hover {
  color: var(--brand);
}

.follow-card__btn {
  flex: 0 0 auto;
  height: 26px;
  width: 100%;
  border-radius: 6px;
  border: 1px solid var(--line);
  color: var(--text-dim);
  font-size: 0.7rem;
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
}

.follow-card__btn:hover {
  color: var(--brand);
  border-color: rgba(0, 204, 76, 0.35);
}

.follow-card__btn.is-followed,
.follow-card__btn.is-followed:hover {
  color: var(--brand);
  border-color: rgba(0, 204, 76, 0.4);
  background: rgba(0, 204, 76, 0.12);
}

.follow-card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.follow-card-actions .btn-play {
  justify-content: center;
  padding: 8px 10px;
  font-size: 0.78rem;
}

/* Hide home modules that are disabled in the published CMS layout. */
.home-intro ~ [hidden], .rank-panel[hidden] { display: none; }
.split--iq:has(.rank-panel[hidden]) { grid-template-columns: minmax(0, 1fr); }
.home-intro ~ #home-promo { max-width: min(var(--container, 1440px), 100%); margin-inline: auto; }

.section--dense {
  padding: 22px 0 6px;
}

.section--dense .section__head {
  margin-bottom: 12px;
  align-items: center;
}

.tabs--inline {
  margin: 0 auto 0 12px;
}

.split--iq {
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 20px;
}

.min0 {
  min-width: 0;
}

.poster-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px 12px;
}

.poster-row .poster__cover {
  aspect-ratio: 3 / 4;
  border-radius: 6px;
}

.poster-row .poster__title {
  font-size: 0.88rem;
}

.rank-panel--iq {
  position: sticky;
  top: calc(var(--nav-iq) + 12px);
  padding: 12px;
  border-radius: 8px;
}

.home-hot-rank .home-rank__tabs {
  justify-content: flex-end;
  margin-bottom: 6px;
}

.rank-panel--iq .rank-item {
  padding: 8px 6px;
}

.poster-grid--home {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px 12px;
}

.poster-grid--home .poster__cover {
  border-radius: 6px;
}

.promo--slim {
  min-height: 48px;
  margin: 0 0 14px;
  padding: 12px 18px;
  border-radius: 8px;
  justify-content: space-between;
  gap: 12px;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
}

a.promo--slim:hover {
  border-color: rgba(0, 204, 76, 0.45);
  background: linear-gradient(105deg, #174028 0%, #10241a 40%, #22182a 100%);
}

a.promo--slim:active {
  transform: scale(0.995);
}

.promo--slim strong {
  font-size: 0.92rem;
  font-weight: 700;
}

.promo__arrow {
  flex-shrink: 0;
  color: var(--brand);
  font-size: 1.25rem;
  line-height: 1;
  opacity: 0.85;
}

a.promo--slim:hover .promo__arrow {
  opacity: 1;
  transform: translateX(2px);
}

.dual-rank {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

#hero[hidden], .follow-strip[hidden], #like[hidden], #movie[hidden], #anime[hidden], #variety[hidden], #rank[hidden],
.dual-rank > .rank-board-wrap[hidden] { display: none; }

.dual-rank:has(> .rank-board-wrap[hidden]) { grid-template-columns: minmax(0, 1fr); }

.rank-board--compact {
  grid-template-columns: 1fr;
  gap: 0;
  padding: 8px 10px;
}

.rank-board--compact .rank-item {
  padding: 9px 6px;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
}

.rank-board--compact .rank-item:last-child {
  border-bottom: none;
}

@media (max-width: 1100px) {
  .focus__layout {
    grid-template-columns: 1fr;
  }

  .focus__list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .poster-row,
  .poster-grid--home {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .split--iq {
    grid-template-columns: minmax(0, 1fr);
  }

  .rank-panel--iq {
    position: static;
  }
}


#highlights[data-cover-ratio="16:9"] { --highlight-cover-ratio: 16 / 9; }
#highlights[data-cover-ratio="3:4"] { --highlight-cover-ratio: 3 / 4; }
#highlights[data-cover-ratio="1:1"] { --highlight-cover-ratio: 1; }
#highlights :is(.poster__cover, .poster__actions) { aspect-ratio: var(--highlight-cover-ratio, 3 / 4); }
#highlights .poster__art { padding: 0; }
#highlights .poster__art img { object-fit: cover; }

/* —— 榜单详情页 —— */
.rank-page {
  padding: 28px 0 48px;
}

.rank-page__hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.rank-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  padding: 10px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
}

.rank-tabs__btn {
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--text-dim);
  font-size: 0.88rem;
  border: 1px solid transparent;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.rank-tabs__btn:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.rank-tabs__btn.is-active {
  color: var(--brand);
  background: rgba(0, 204, 76, 0.12);
  border-color: rgba(0, 204, 76, 0.28);
}

.rank-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: -6px 0 18px;
}

.rank-tags[hidden] {
  display: none;
}

.rank-tabs__more {
  color: var(--brand);
}

.rank-tags__btn {
  padding: 6px 12px;
  border-radius: 999px;
  color: var(--text-mute);
  font-size: 0.8rem;
  border: 1px solid var(--line);
  background: transparent;
}

.rank-tags__btn:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.18);
}

.rank-tags__btn.is-active {
  color: var(--brand);
  border-color: rgba(0, 204, 76, 0.35);
  background: rgba(0, 204, 76, 0.1);
}

.rank-chip {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.72rem;
  color: var(--brand);
  background: rgba(0, 204, 76, 0.1);
  border: 1px solid rgba(0, 204, 76, 0.22);
}

.rank-detail {
  display: grid;
  gap: 10px;
}

.rank-detail__item {
  display: grid;
  grid-template-columns: 48px 72px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
}

.rank-detail__n {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  text-align: center;
  color: var(--text-mute);
}

.rank-detail__item.is-top1 .rank-detail__n { color: #ffd166; }
.rank-detail__item.is-top2 .rank-detail__n { color: #c0c7d4; }
.rank-detail__item.is-top3 .rank-detail__n { color: #d4a574; }

.rank-detail__cover {
  width: 72px;
  height: 96px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.rank-detail__cover span {
  font-family: 'Outfit', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  opacity: 0.3;
}

.rank-detail__body {
  min-width: 0;
}

.rank-detail__body h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-detail__body h3 a:hover {
  color: var(--brand);
}

.rank-detail__body p {
  color: var(--text-mute);
  font-size: 0.86rem;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-detail__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--text-mute);
}

.rank-detail__meta .score {
  color: #ffd166;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
}

.rank-detail__actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rank-detail__actions .btn-play {
  justify-content: center;
  padding: 10px 16px;
  font-size: 0.86rem;
}

@media (max-width: 720px) {
  .rank-page__hero {
    flex-direction: column;
    align-items: stretch;
  }

  .rank-detail__item {
    grid-template-columns: 36px 56px 1fr;
  }

  .rank-detail__actions {
    grid-column: 2 / -1;
    flex-direction: row;
  }

  .rank-detail__cover {
    width: 56px;
    height: 74px;
  }
}

/* —— 个人中心 —— */
.user-page {
  padding: 28px 0 48px;
}

.user-hero {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 24px;
  border-radius: 16px;
  background:
    radial-gradient(ellipse at 0% 0%, rgba(0, 204, 76, 0.16), transparent 55%),
    var(--bg-elevated);
  border: 1px solid var(--line);
  margin-bottom: 18px;
}

.user-hero__avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 2rem;
  font-weight: 800;
  color: #04140a;
  background: linear-gradient(145deg, #00e65a, #009c38);
  box-shadow: 0 10px 28px var(--brand-glow);
}

.user-hero__info h1 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.user-hero__info p {
  color: var(--text-mute);
  font-size: 0.9rem;
  margin-bottom: 10px;
}

.user-hero__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.user-hero__tags span {
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-dim);
  font-size: 0.78rem;
}

.user-hero__actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.user-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.user-stat {
  display: grid;
  gap: 4px;
  padding: 18px 16px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  text-align: center;
  transition: border-color 0.2s, transform 0.2s;
}

a.user-stat:hover {
  border-color: rgba(0, 204, 76, 0.35);
  transform: translateY(-2px);
}

.user-stat strong {
  font-family: 'Outfit', sans-serif;
  font-size: 1.6rem;
  color: var(--text);
}

.user-stat span {
  color: var(--text-mute);
  font-size: 0.84rem;
}

.user-menu {
  display: grid;
  gap: 10px;
  margin-bottom: 8px;
}

.user-menu__item {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  text-align: left;
  width: 100%;
  color: inherit;
  transition: border-color 0.2s, background 0.2s;
}

.user-menu__item:hover {
  border-color: rgba(0, 204, 76, 0.3);
  background: rgba(0, 204, 76, 0.05);
}

.user-menu__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(0, 204, 76, 0.12);
  color: var(--brand);
  font-weight: 700;
}

.user-menu__item strong {
  display: block;
  font-size: 0.98rem;
  margin-bottom: 2px;
}

.user-menu__item small {
  color: var(--text-mute);
  font-size: 0.8rem;
}

.user-menu__arrow {
  color: var(--text-mute);
  font-size: 1.2rem;
}

.poster--follow {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
  gap: 8px;
}

.follow-remove {
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--line);
  color: var(--text-mute);
  font-size: 0.8rem;
}

.follow-remove:hover {
  color: var(--danger);
  border-color: rgba(255, 77, 106, 0.35);
}

@media (max-width: 720px) {
  .user-hero {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  #user-account {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .user-hero__avatar {
    width: 72px;
    height: 72px;
    font-size: 1.6rem;
  }

  .user-hero__actions {
    grid-column: 1 / -1;
    flex-direction: row;
  }

  .user-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  .user-stat { min-width: 0; padding: 14px 6px; }
  .user-stat strong { font-size: 1.4rem; }
  .user-stat span { font-size: 0.75rem; white-space: nowrap; }
}


.rank-page__hero > div:first-child { min-width: 0; flex: 1; }
.detail-info { min-width: 0; }
.compact-description { display: flex; align-items: flex-start; gap: 8px; min-width: 0; margin-bottom: 10px; }
.compact-description__text { min-width: 0; flex: 1; margin-bottom: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.compact-description.is-expanded .compact-description__text { white-space: normal; overflow-wrap: anywhere; }
.compact-expand { flex: none; color: var(--brand); font-size: 0.82rem; line-height: 1.5; padding: 1px 4px; }
.compact-expand[hidden] { display: none; }
.compact-expand:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.compact-categories { position: relative; align-content: flex-start; }
.compact-categories:not(.is-expanded) { max-height: var(--compact-height, 104px); overflow: hidden; }
.compact-categories .rank-tabs__btn { line-height: 20px; white-space: nowrap; }
.compact-categories__toggle { display: block; margin: -10px 0 16px auto; }

/* Browsing pages show their title without generic instructional subtitles. */
.page-intro--removed { display: none; }

/* —— 观看历史 —— */
.history-list {
  display: grid;
  gap: 12px;
}

.history-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
}

.history-item__link {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 14px;
  align-items: center;
  min-width: 0;
}

.history-item__cover {
  width: 72px;
  height: 96px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.history-item__cover span {
  font-family: 'Outfit', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  opacity: 0.35;
}

.history-item__body {
  min-width: 0;
}

.history-item__body h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-item__body p {
  color: var(--text-mute);
  font-size: 0.86rem;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-item__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--text-mute);
  font-size: 0.78rem;
}

.history-item__meta span:first-child {
  color: var(--brand);
}

.history-item__actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: stretch;
}

.history-item__actions .btn-play {
  justify-content: center;
  padding: 10px 16px;
  font-size: 0.86rem;
}

.help-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 400px);
  gap: 28px;
  align-items: start;
}

.help-layout > * {
  min-width: 0;
}

.help-block__title {
  font-size: 1.05rem;
  margin-bottom: 12px;
  line-height: 1.4;
}

.help-faq-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.help-faq {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 16px;
}

.help-faq summary {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  font-weight: 650;
  line-height: 1.5;
  list-style: none;
}

.help-faq summary::-webkit-details-marker {
  display: none;
}

.help-faq summary::marker {
  content: '';
}

.help-faq summary span {
  min-width: 0;
  flex: 1;
}

.help-faq summary::after {
  content: '';
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-right: 1.5px solid var(--text-dim);
  border-bottom: 1.5px solid var(--text-dim);
  transform: rotate(45deg) translateY(-2px);
}

.help-faq[open] summary::after {
  transform: rotate(-135deg) translateY(-2px);
}

.help-faq p {
  margin: 0 0 14px;
  padding-top: 2px;
  color: var(--text-dim);
  line-height: 1.7;
  font-size: 0.92rem;
  overflow-wrap: anywhere;
}

#help-page .list-hero > * {
  min-width: 0;
}

.help-empty {
  color: var(--text-mute);
}

.help-side {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px 18px 18px;
  position: sticky;
  top: calc(var(--nav-h) + 16px);
}

.help-contact {
  display: grid;
  gap: 4px;
}

.help-contact span {
  display: block;
  overflow-wrap: anywhere;
}

.help-contact,
.help-form-hint,
.help-form-msg {
  color: var(--text-mute);
  font-size: 0.86rem;
  line-height: 1.6;
  margin-bottom: 10px;
  overflow-wrap: anywhere;
}

.help-form-msg {
  color: var(--brand);
  margin: 10px 0 0;
}

.help-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.help-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--text-mute);
}

.help-form input,
.help-form select,
.help-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text);
  color-scheme: dark;
  border-radius: 8px;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.92rem;
}

.help-form textarea {
  resize: vertical;
  min-height: 110px;
}

.help-form .btn-play {
  width: 100%;
  justify-content: center;
  border: 0;
  cursor: pointer;
  margin-top: 4px;
}

@media (max-width: 1024px) {
  .help-layout {
    grid-template-columns: 1fr;
  }

  .help-side {
    position: static;
  }
}

.help-form .btn-play:disabled {
  opacity: 0.6;
  cursor: wait;
}

@media (max-width: 720px) {
  .history-item {
    grid-template-columns: 1fr;
  }

  .history-item__actions {
    flex-direction: row;
  }

  .home-iq, .site-shell { --nav-iq: 148px; }

  .topbar--iq .topbar__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    height: auto;
    gap: 8px;
    padding-block: 8px;
  }

  .topbar--iq .logo, .topbar--iq .topbar__actions { min-height: 44px; }

  .topbar--iq .search--center {
    display: flex;
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
    max-width: none;
    min-width: 0;
    height: 44px;
    margin: 0;
  }

  .topbar--iq .search--center input { min-width: 0; width: 100%; }
  .topbar--iq .search__btn { padding-inline: 12px; }

  .focus__list {
    grid-template-columns: 1fr 1fr;
  }

  .poster-row,
  .poster-grid--home {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dual-rank {
    grid-template-columns: 1fr;
  }
}

.qm-privacy-menu { display: flex; align-items: stretch; gap: 8px; }
.qm-privacy-menu > a { flex: 1; min-width: 0; }
.qm-privacy-toggle {
  display: grid;
  place-items: center;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--brand);
  background: var(--bg-elevated);
  cursor: pointer;
}
.qm-privacy-toggle[data-locked="true"] { color: var(--text-mute); }
.qm-privacy-toggle[hidden], .qm-privacy-settings[hidden] { display: none; }
.qm-privacy-notice { display: inline-flex; align-items: center; gap: 8px; width: max-content; max-width: 100%; grid-column: 1 / -1; }
.qm-privacy-settings { display: flex; flex-wrap: wrap; gap: 8px; }
.qm-privacy-form, .qm-privacy-form label { display: grid; gap: 8px; }
.qm-privacy-form .qm-privacy-both { display: flex; align-items: center; }
.qm-privacy-form .qm-privacy-both input { width: auto; }

@media (max-width: 480px) {
  .topbar--iq .topbar__row { gap: 6px; }
  .topbar--iq .logo { gap: 6px; white-space: nowrap; }
  .topbar--iq .logo__mark { width: 26px; height: 26px; flex: 0 0 26px; }
  .topbar--iq .logo__text { font-size: 1.05rem; }
  .topbar--iq .topbar__actions { gap: 6px; }
  .topbar--iq .app-download > summary { padding-inline: 4px; font-size: .8rem; }
  .topbar--iq .user-chip__name { max-width: clamp(2em, 13vw, 4em); }

  #tv .section__head { gap: 6px; }
  #tv .section__title {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: clamp(.95rem, 4.6vw, 1.15rem);
  }
  #tv .tabs--inline { flex-shrink: 0; gap: 2px; margin: 0 auto 0 2px; }
  #tv .tabs--inline button { padding: 5px 7px; white-space: nowrap; font-size: .8rem; }
  #tv .section__more { flex-shrink: 0; white-space: nowrap; font-size: .8rem; }
}


.qm-privacy-page-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.qm-privacy-form .qm-privacy-rule { color: var(--text-mute); margin: 0; }
.qm-privacy-form .qm-privacy-error { color: var(--danger, #e65a68); }
.qm-privacy-page-actions > [hidden] { display: none; }

body[data-qm-cms-navigation] .channel-bar__inner {
  /* Nested menus extend below the channel bar. */
  overflow: visible;
}

.qm-nav-group {
  position: relative;
  display: flex;
  align-items: center;
  color: inherit;
}

.qm-nav-group > a { padding-inline-end: 4px; }
.qm-nav-group > details > summary {
  display: grid;
  place-items: center;
  width: 22px;
  min-height: 30px;
  cursor: pointer;
  list-style: none;
  color: var(--text-dim);
}

.qm-nav-group > details > summary::-webkit-details-marker { display: none; }
.qm-nav-group > details > summary::after {
  content: '';
  width: 5px;
  height: 5px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(45deg);
  margin-top: -3px;
}

.qm-nav-group > details > summary:hover,
.qm-nav-group > details[open] > summary { color: var(--brand); }

.qm-nav-group > details > div {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 180px;
  z-index: 25;
  background: #161a20;
  border: 1px solid #303640;
  padding: 12px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.qm-nav-group > details > div .qm-nav-group { flex-wrap: wrap; }
.qm-nav-group > details > div .qm-nav-group > details[open] { display: contents; }
.qm-nav-group > details > div .qm-nav-group > details > div { position: static; flex-basis: 100%; }
.qm-nav-group > details > div a { display: block; padding: 6px; }
.qm-home-menus, .qm-breadcrumb { display: flex; flex-wrap: wrap; gap: 14px; padding-block: 18px; }
.qm-home-menus a { padding: 8px 16px; border: 1px solid #303640; border-radius: 8px; }
.qm-breadcrumb { font-size: 14px; color: #929bab; }

@media (max-width: 760px) {
  body[data-qm-cms-navigation] .channel-bar__inner {
    height: auto;
    min-height: 44px;
    flex-wrap: wrap;
    white-space: normal;
    gap: 8px;
  }

  .qm-nav-group > details > div { max-width: 70vw; }
  .qm-home-menus { gap: 8px; }
}

.theme-toggle {
  display: grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: var(--text-dim);
}

.theme-toggle svg { width: 19px; height: 19px; }
.theme-toggle:hover { background: var(--bg-soft); color: var(--text); }
.theme-toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #fff;
  --bg-elevated: #f6f7f8;
  --bg-soft: #edf0f2;
  --line: #151e311e;
  --text: #171d28;
  --text-dim: #343f51;
  --text-mute: #505d6f;
  --brand: #087837;
  --brand-dim: #096e35;
  --brand-glow: #09783733;
  --danger: #b4173d;
}

[data-theme="light"] .topbar,
[data-theme="light"] .topbar.is-scrolled,
[data-theme="light"] .auth-body { background: var(--bg); }
[data-theme="light"] .channel-bar,
[data-theme="light"] .search,
[data-theme="light"] .list-toolbar__search input,
[data-theme="light"] .auth-demo__item,
[data-theme="light"] .follow-strip,
[data-theme="light"] .qm-toast__item { background: var(--bg-elevated); color: var(--text); border-color: var(--line); }
[data-theme="light"] .search:focus-within { background: var(--bg); border-color: var(--text-mute); }
[data-theme="light"] .search input,
[data-theme="light"] .search input::placeholder,
[data-theme="light"] .list-toolbar__search input::placeholder { color: var(--text-mute); }
[data-theme="light"] .search input::-webkit-search-cancel-button,
[data-theme="light"] .list-toolbar__search input::-webkit-search-cancel-button { filter: none; }
[data-theme="light"] .qm-nav-group > details > div,
[data-theme="light"] .search-suggestions { background: var(--bg); border-color: var(--line); }
[data-theme="light"] .search-suggestions button:hover,
[data-theme="light"] .search-suggestions button:focus-visible { background: var(--bg-soft); }
[data-theme="light"] .search-suggestions > .search-suggestions__hot { color: #785400; }
[data-theme="light"] .qm-breadcrumb { color: var(--text-mute); }
[data-theme="light"] .qm-home-menus a { border-color: var(--line); }
[data-theme="light"] .focus { background: var(--bg); }
[data-theme="light"] .detail-hero__bg::after {
  background: linear-gradient(90deg, #fffffff5, #ffffffd6), linear-gradient(180deg, transparent 60%, var(--bg));
}
[data-theme="light"] .detail-meta .score,
[data-theme="light"] .rank-detail__meta .score,
[data-theme="light"] .rank-detail__item.is-top1 .rank-detail__n { color: #785400; }
[data-theme="light"] .rank-detail__item.is-top2 .rank-detail__n { color: var(--text-mute); }
[data-theme="light"] .rank-detail__item.is-top3 .rank-detail__n { color: #874d25; }
[data-theme="light"] .auth-error { color: var(--danger); }
[data-theme="light"] :is(.btn-play,.search__btn,.auth-submit,.poster__play span,.poster__tag:not(.is-hot,.is-new,[style])) { background: #23ce65; }
[data-theme="light"] :is(.player,.focus__main) {
  color-scheme: dark;
  --text: #f2f4f7;
  --text-dim: #c8d0db;
  --text-mute: #a7afbc;
  --brand: #00cc4c;
}

@media (max-width: 600px) {
  .theme-toggle { width: 32px; height: 32px; }
}
