/**
 * QMT 首页 / 列表轮播（替代旧 3D anim 样式）
 */
.qmt-hero {
  --qmt-hero-radius: 12px;
  --qmt-hero-ratio: 21 / 9;
  position: relative;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  border-radius: var(--qmt-hero-radius);
  overflow: hidden;
  border: 1px solid var(--qmt-border-strong, rgba(255, 255, 255, 0.14));
  background: var(--qmt-surface, #12151c);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(56, 189, 248, 0.06) inset;
}

.qmt-hero--list {
  --qmt-hero-ratio: 4.8 / 1;
  --qmt-hero-radius: 8px;
  max-width: 100%;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.28);
}

.qmt-hero--empty {
  aspect-ratio: var(--qmt-hero-ratio);
  min-height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-style: dashed;
  border-color: var(--qmt-border, rgba(255, 255, 255, 0.08));
  background: rgba(18, 21, 28, 0.75);
}

.qmt-hero__empty-text {
  margin: 0;
  padding: 16px 24px;
  color: var(--qmt-muted, #9aa3b2);
  font-size: 14px;
  text-align: center;
}

.qmt-hero__viewport {
  position: relative;
  width: 100%;
  aspect-ratio: var(--qmt-hero-ratio);
  background: #0a0e14;
}

.qmt-hero--list .qmt-hero__viewport {
  aspect-ratio: var(--qmt-hero-ratio);
  max-height: 168px;
}

.qmt-hero__slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.65s ease, visibility 0.65s ease;
  z-index: 0;
}

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

.qmt-hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transform: scale(1.02);
  transition: transform 6s ease-out;
}

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

.qmt-hero__overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(5, 10, 16, 0.15) 0%,
    rgba(5, 10, 16, 0.05) 35%,
    rgba(5, 10, 16, 0.55) 78%,
    rgba(5, 10, 16, 0.88) 100%
  );
}

.qmt-hero--list .qmt-hero__overlay {
  background: linear-gradient(
    90deg,
    rgba(5, 10, 16, 0.75) 0%,
    rgba(5, 10, 16, 0.2) 45%,
    rgba(5, 10, 16, 0.65) 100%
  );
}

.qmt-hero__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  margin: 0;
  padding: 20px 24px 18px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  pointer-events: none;
}

.qmt-hero--list .qmt-hero__caption {
  padding: 10px 16px;
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

.qmt-hero__tag {
  display: inline-block;
  padding: 3px 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #a5f3fc;
  background: rgba(56, 189, 248, 0.18);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 999px;
}

.qmt-hero__title {
  font-size: clamp(18px, 2.4vw, 26px);
  font-weight: 700;
  line-height: 1.25;
  color: #f1f5f9;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.65);
  max-width: 90%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.qmt-hero--list .qmt-hero__title {
  font-size: 15px;
  font-weight: 600;
  max-width: 70%;
}

/* 箭头 */
.qmt-hero__arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  background: rgba(15, 23, 32, 0.55);
  color: #e2e8f0;
  cursor: pointer;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.25s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.qmt-hero:hover .qmt-hero__arrow,
.qmt-hero:focus-within .qmt-hero__arrow,
.qmt-hero:focus .qmt-hero__arrow {
  opacity: 1;
}

.qmt-hero:focus {
  outline: none;
}

.qmt-hero:focus-visible {
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.35),
    0 0 0 2px rgba(56, 189, 248, 0.45);
}

.qmt-hero__arrow:hover {
  background: rgba(56, 189, 248, 0.22);
  border-color: rgba(56, 189, 248, 0.45);
  color: #fff;
}

.qmt-hero__arrow--prev {
  left: 14px;
}

.qmt-hero__arrow--next {
  right: 14px;
}

.qmt-hero--list .qmt-hero__arrow {
  width: 32px;
  height: 32px;
  opacity: 0.85;
}

.qmt-hero--list .qmt-hero__arrow--prev {
  left: 8px;
}

.qmt-hero--list .qmt-hero__arrow--next {
  right: 8px;
}

/* 指示点 */
.qmt-hero__dots {
  position: absolute;
  left: 50%;
  bottom: 12px;
  z-index: 4;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(8, 12, 18, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.qmt-hero--list .qmt-hero__dots {
  bottom: 8px;
  gap: 6px;
  padding: 4px 8px;
}

.qmt-hero__dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.45);
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, width 0.2s ease;
}

.qmt-hero__dot.is-active {
  width: 22px;
  border-radius: 4px;
  background: linear-gradient(90deg, #38bdf8, #34d399);
}

.qmt-hero__dot:hover {
  background: rgba(148, 163, 184, 0.75);
}

/* 自动播放进度条 */
.qmt-hero__progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
}

.qmt-hero__progress-bar {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #38bdf8, #34d399);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.45);
}

.qmt-hero.is-paused .qmt-hero__progress-bar {
  animation-play-state: paused !important;
}

/* 首页 · 最近基准日严守纪律卡片 */
.qmt-home-fy-discipline {
  padding: 0 0 20px;
}

.qmt-home-fy-discipline .container {
  width: min(1180px, 94%);
  max-width: 1180px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
}

.qmt-home-fy-discipline__card {
  padding: 20px 22px 18px;
  border-radius: 12px;
  border: 1px solid rgba(124, 58, 237, 0.22);
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.97) 0%,
    rgba(248, 250, 252, 0.94) 55%,
    rgba(237, 233, 254, 0.35) 100%
  );
  box-shadow:
    0 4px 22px rgba(15, 23, 42, 0.08),
    0 0 0 1px rgba(255, 255, 255, 0.65) inset;
}

.qmt-home-fy-discipline__eyebrow {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #d4af37;
}

.qmt-home-fy-discipline__title {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.35;
}

.qmt-home-fy-discipline__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 16px 24px;
  margin-top: 16px;
  align-items: start;
}

.qmt-home-fy-discipline__label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 4px;
}

.qmt-home-fy-discipline__date {
  font-size: 15px;
  font-weight: 700;
  color: #334155;
  background: rgba(15, 23, 42, 0.06);
  border: 0;
  padding: 4px 10px;
  border-radius: 6px;
}

.qmt-home-fy-discipline__value {
  margin: 0;
  font-size: clamp(26px, 5vw, 34px);
  font-weight: 800;
  line-height: 1.2;
  color: #b8962e;
  word-break: break-word;
}

.qmt-home-fy-discipline__value--empty {
  color: #94a3b8;
  font-weight: 700;
}

.qmt-home-fy-discipline__stats {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin: 0;
  padding: 12px 14px;
  list-style: none;
  border-radius: 8px;
  background: rgba(124, 58, 237, 0.06);
  border: 1px solid rgba(124, 58, 237, 0.12);
}

.qmt-home-fy-discipline__stats li {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-size: 13px;
  color: #475569;
}

.qmt-home-fy-discipline__stats .k {
  font-weight: 600;
}

.qmt-home-fy-discipline__stats strong {
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
  font-variant-numeric: tabular-nums;
}

.qmt-home-fy-discipline__stats .u {
  font-size: 12px;
  color: #64748b;
}

.qmt-home-fy-discipline__meta {
  grid-column: 1 / -1;
  margin: -4px 0 0;
  font-size: 12px;
  color: #64748b;
}

.qmt-home-fy-discipline__empty {
  margin: 14px 0 0;
  font-size: 13px;
  line-height: 1.6;
  color: #475569;
}

.qmt-home-fy-discipline__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.qmt-home-fy-discipline__link {
  display: inline-flex;
  align-items: center;
  padding: 7px 16px;
  font-size: 13px;
  font-weight: 700;
  color: #fff !important;
  text-decoration: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #d4af37 0%, #c9a84c 100%);
  box-shadow: 0 3px 12px rgba(124, 58, 237, 0.25);
}

.qmt-home-fy-discipline__link:hover,
.qmt-home-fy-discipline__link:focus {
  color: #fff !important;
  background: linear-gradient(135deg, #c9a84c 0%, #b8962e 100%);
  text-decoration: none;
}

.qmt-home-fy-discipline__link--secondary {
  color: #b8962e !important;
  background: rgba(124, 58, 237, 0.1);
  box-shadow: none;
  border: 1px solid rgba(124, 58, 237, 0.28);
}

.qmt-home-fy-discipline__link--secondary:hover,
.qmt-home-fy-discipline__link--secondary:focus {
  color: #4c1d95 !important;
  background: rgba(124, 58, 237, 0.16);
}

@media (max-width: 640px) {
  .qmt-home-fy-discipline__body {
    grid-template-columns: 1fr;
  }
}

/* 首页区块间距 */
body.qmt-theme-openclaw.qmt-page-home #hotmovie.qmt-hotmovie-home {
  padding: 16px 0 20px !important;
  margin: 0;
  background: transparent;
}

body.qmt-theme-openclaw.qmt-page-home #hotmovie.qmt-hotmovie-home .container {
  width: min(1180px, 94%);
  max-width: 1180px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
}

body.qmt-theme-openclaw.qmt-page-home .qmt-home-admin-entry {
  margin-top: 14px;
}

body.qmt-theme-openclaw.qmt-page-home .qmt-home-admin-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  font-size: 14px;
  font-weight: 700;
  color: #fff !important;
  background: linear-gradient(135deg, #d4af37 0%, #c9a84c 100%);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.28);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

body.qmt-theme-openclaw.qmt-page-home .qmt-home-admin-btn:hover,
body.qmt-theme-openclaw.qmt-page-home .qmt-home-admin-btn:focus {
  color: #fff !important;
  background: linear-gradient(135deg, #c9a84c 0%, #b8962e 100%);
  box-shadow: 0 6px 18px rgba(91, 33, 182, 0.34);
  transform: translateY(-1px);
  text-decoration: none;
}

body.qmt-theme-openclaw.qmt-page-home .qmt-main {
  min-height: 0;
  padding-top: calc(var(--qmt-nav-h) + 12px);
  padding-bottom: 24px;
}

body.qmt-theme-openclaw.qmt-page-home .qmt-home-fy-discipline {
  padding-top: 4px;
}

/* 列表 iframe 内嵌页 */
html.anim-root.anim-list,
.anim-body--list {
  margin: 0;
  padding: 0;
  background: transparent;
}

.anim-body--list {
  padding: 4px 0;
}

@media (max-width: 767px) {
  .qmt-hero {
    --qmt-hero-ratio: 16 / 10;
    border-radius: 10px;
  }

  .qmt-hero__arrow {
    opacity: 0.92;
    width: 36px;
    height: 36px;
  }

  .qmt-hero__arrow--prev {
    left: 8px;
  }

  .qmt-hero__arrow--next {
    right: 8px;
  }

  .qmt-hero__caption {
    padding: 14px 16px 12px;
  }

  .qmt-hero__title {
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .qmt-hero__slide,
  .qmt-hero__img {
    transition: none;
  }

  .qmt-hero__progress-bar {
    animation: none !important;
  }
}
