.novel-comic-detail-page .main {
  width: 100%;
  max-width: 1380px;
  margin: 0 auto;
  padding: 0 50px 24px;
  box-sizing: border-box;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.novel-comic-detail-page .noval-advListHorizontal {
  margin-top: 32px;
}
.novel-comic-detail-page .advListHorizontal {
  padding: 0px;
}
.chapter-popup {
  display: none;
}
.novel-comic-detail-page .advListHorizontal__title {
  color: #fff;

  /* 30 */
  font-family: 'PingFang SC';
  font-size: 30px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
}

.comic-meta {
  margin: 16px 0;
}

.novel-comic-detail-page .pageTitle {
  color: #fff;
  font-family:
    'PingFang SC',
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    'Microsoft YaHei',
    sans-serif;
  /* 24 */
  font-size: 24px;
  font-style: normal;
  font-weight: 400;
  line-height: 32px; /* 133.333% */
  margin: 24px 0 16px;
}

.novel-comic-detail-page .detail-meta {
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: 18px;
  color: rgba(255, 255, 255, 0.6);
  font-family:
    'PingFang SC',
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    'Microsoft YaHei',
    sans-serif;
  font-size: 16px;
  line-height: 18px;
  max-width: 70%;
}

.novel-comic-detail-page .detail-meta__item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.novel-comic-detail-page .detail-meta__item img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.novel-comic-detail-page .detail-meta__text {
  white-space: nowrap;
}

.novel-comic-detail-page .detail-content {
  color: #fff;
  font-family:
    'PingFang SC',
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    'Microsoft YaHei',
    sans-serif;
  /* Medium */
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 22px; /* 137.5% */
}

/* 漫画章节图片样式 */
.comic-chapter-content {
  margin-bottom: 24px;
}

.comic-image-container {
  text-align: center;
}

.comic-image-container .comic-image {
  width: auto;
  height: auto;
  margin: auto;
  max-width: 100%;
  background-color: #292929;
}

.content-text p {
  margin-bottom: 18px;
}

/* Start reading button - use theme(primary) color */
.novel-comic-detail-page .start-btn {
  display: inline-block;
  padding: 10px 18px;
  background-color: var(--bs-primary);
  color: #fff;
  border: none;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
}
.novel-comic-detail-page .start-btn:hover {
  background-color: rgb(var(--bs-primary-rgb));
  opacity: 0.95;
  color: #fff;
}
.novel-comic-detail-page .start-btn.disabled,
.novel-comic-detail-page .start-btn[disabled] {
  opacity: 0.5;
  pointer-events: none;
}

.novel-comic-detail-page .btn-primary {
  background: var(---500, #3E7DFF);
  color: #000;
  border-color: transparent;
  box-shadow: none;
}
.novel-comic-detail-page .btn-primary:hover,
.novel-comic-detail-page .btn-primary:focus {
  background: color-mix(in srgb, var(---500, #3E7DFF) 85%, #000 15%);
  color: #000;
  text-decoration: none;
}

/* ensure start-btn uses the same primary style */
.novel-comic-detail-page .start-btn {
  background: var(---500, #3E7DFF);
  color: #000;
  border-color: transparent;
}
.novel-comic-detail-page .start-btn:hover {
  background: color-mix(in srgb, var(---500, #3E7DFF) 85%, #000 15%);
  color: #000;
}

.novel-comic-detail-page .detail-meta__line {
  display: block;
}
.novel-comic-detail-page .detail-meta__text {
  color: var(---, #ffffff99);
  display: block;
  white-space: normal;
}

.novel-comic-detail-page .detail-meta__stats {
  display: flex;
  gap: 18px;
  align-items: center;
}
.novel-comic-detail-page .detail-meta__stats .meta-stat {
  color: var(---, #ffffff99);
  display: inline-block;
  white-space: nowrap;
}

/* Novel tags container */
.novel-tags-container {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.novel-tags-label {
  color: var(---, rgba(255, 255, 255, 0.6));
  flex-shrink: 0;
}

.novel-tags-container .tag {
  display: inline-block;
  background: rgba(255, 255, 255, 0.1);
  padding: 6px 12px;
  border-radius: 4px;
  color: inherit;
  white-space: nowrap;
  flex-shrink: 0;
}

.novel-chapters-grid .chapters-title {
  color: #fff;
  font-size: 24px;
  border-bottom: 1px solid #3E7DFF;
  padding-bottom: 14px;
}
.novel-chapters-grid .chapter-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px 18px;
  align-items: start;
  padding: 12px 0;
}
.novel-chapters-grid .chapter-item {
  display: block;
  padding: 8px 12px;
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  font-size: 16px;
  border-radius: 4px;
  transition:
    color 180ms ease,
    transform 180ms ease;
  cursor: pointer;
  display: flex;
  justify-content: start;
  align-items: center;
}
.novel-chapters-grid .chapter-item:hover {
  color: var(---500, #3E7DFF);
  transform: translateY(-1px);
}
.novel-chapters-grid .chapter-item .chapter-num {
  font-weight: 600;
  display: none;
}
.novel-chapters-grid .chapter-item .chapter-title {
  display: inline;
  font-family: PingFang SC;
  font-weight: 400;
  font-style: Medium;
  font-size: 16px;
  leading-trim: NONE;
  line-height: 22px;
  letter-spacing: 0%;
  vertical-align: middle;
}
.chapters-header {
  display: none;
}

@media screen and (max-width: 824px) {
  .novel-chapters-grid .chapters-title {
    display: none;
  }
  .novel-chapters-grid .chapters-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
  }
  .novel-chapters-grid .chapters-header .left {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
  }
  .novel-chapters-grid .chapters-header .right {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #cfcfcf;
    cursor: pointer;
    font-size: 14px;
  }
  .novel-chapters-grid .chapters-header .right img.icon-rot {
    width: 18px;
    height: 18px;
    transform: rotate(-90deg);
    display: inline-block;
  }
  .novel-chapters-grid .chapter-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    padding: 8px 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .novel-chapters-grid .chapter-item {
    flex: 0 0 64px;
    width: 64px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid var(---, #1c1c1c);
    color: #ffffff;
    text-decoration: none;
    box-sizing: border-box;
  }
  .novel-chapters-grid .chapter-item .chapter-num {
    display: inline;
    font-size: 16px;
    font-weight: 600;
    color: #ffffff;
  }
  .novel-chapters-grid .chapter-item .label-pc,
  .novel-chapters-grid .chapter-item .label-mobile,
  .novel-chapters-grid .chapter-item .chapter-title {
    display: none;
  }
  .novel-chapters-grid .chapter-item:active,
  .novel-chapters-grid .chapter-item.active {
    border-color: #e5365c;
    color: #e5365c;
  }
  .novel-chapters-grid .chapter-item:active .chapter-num,
  .novel-chapters-grid .chapter-item.active .chapter-num {
    color: #e5365c;
  }
  .start-read {
    display: none;
  }

  .novel-chapters-grid .chapter-popup {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    top: 0;
    display: none;
    z-index: 1200;
  }
  .novel-chapters-grid .chapter-popup.open {
    display: block;
  }
  .novel-chapters-grid .chapter-popup .backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
  }
  .novel-chapters-grid .chapter-popup .sheet {
    position: absolute;
    bottom: 0px;
    background: #121217;
    border-radius: 16px 16px 0px 0px;
    max-height: 70vh;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
    padding: 12px;
    box-sizing: border-box;
    margin: 0 auto;
    max-width: calc(100%);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .novel-chapters-grid .chapter-popup .sheet .handle {
    width: 36px;
    height: 4px;
    background: #3a3a3a;
    border-radius: 4px;
    margin: 6px auto;
  }
  .novel-chapters-grid .chapter-popup .sheet .sheet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    margin-bottom: 6px;
    color: #fff;
    position: sticky;
    top: 0;
    z-index: 3;
    background: #121217;
  }
  .novel-chapters-grid .chapter-popup .sheet .sheet-header .sheet-title {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    margin-right: 8px;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-list {
    margin-top: 6px;
    overflow: auto;
    flex: 1 1 auto;
    -webkit-overflow-scrolling: touch;
    padding-right: 6px;
  }
  .novel-chapters-grid .chapter-popup .sheet .sheet-order {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    white-space: nowrap;
  }
  .novel-chapters-grid .chapter-popup .sheet .sheet-order .order-option {
    background: transparent;
    border: 0;
    color: #cfcfcf;
    font-size: 13px;
    padding: 0 4px;
    cursor: pointer;
    white-space: nowrap;
  }
  .novel-chapters-grid .chapter-popup .sheet .sheet-order .order-option.active {
    color: #3E7DFF;
    font-weight: 600;
  }
  .novel-chapters-grid .chapter-popup .sheet .sheet-order .order-sep {
    color: #666;
    padding: 0 2px;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 6px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    color: #ffffff99;
    text-decoration: none;
    flex-wrap: nowrap;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-item.active {
    color: #3E7DFF;
    font-weight: 600;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-item > div:first-child {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-item .popup-text {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    max-width: 80%;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-item > .popup-text {
    margin: 0;
    flex: 1 1 90% !important;
    max-width: 90% !important;
    min-width: 0 !important;
    overflow: hidden !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
  }
  .novel-chapters-grid .chapter-popup .sheet .popup-item .arrow {
    width: 12px;
    height: 12px;
    opacity: 0.6;
    flex: 0 0 auto;
    margin-left: 8px;
  }
}
.novel-chapter-header {
  gap: 14px;
  display: flex;
  flex-direction: column;
  margin-top: 14px;
}

/* 布局：左侧广�?正文 + 右侧列表 */
.novel-main-layout {
  display: flex;
  gap: 16px;
  margin-top: 8px;
}
.novel-title-detail {
  color: #fff;

  /* 24 */
  font-family: 'PingFang SC';
  font-size: 24px;
  font-style: normal;
  font-weight: 400;
  line-height: 32px; /* 133.333% */
}

.novel-main-layout__left {
  flex: 1 1 auto;
  min-width: 0;
}

.novel-main-layout__right {
  width: 320px;
  flex: 0 0 320px;
}
.h5-ad {
  display: none;
}
@media screen and (max-width: 824px) {
  .novel-comic-detail-page .main {
    padding: 0 16px 24px;
  }
  .h5-ad {
    display: block;
  }
  .h5-ad .advList {
    margin-top: 12px;
    padding: 0 !important;
  }
  .novel-comic-detail-page .pageTitle {
    font-size: 16px;
    line-height: 24px;
    margin: 16px 0 12px;
  }

  .novel-main-layout {
    flex-direction: column;
  }
  .detail-meta__text {
    color: #c6c6c6;
    font-family: 'PingFang SC';
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 21px; /* 150% */
  }

  .novel-main-layout__right {
    width: 100%;
    flex: 0 0 auto;
  }
  .detail-meta {
    display: none !important;
  }
}

.novel-comic-detail-page .detail-meta-h5 {
  display: none;
}
@media screen and (max-width: 824px) {
  .novel-title-detail {
    color: #fff;

    /* Medium */
    font-family: 'PingFang SC';
    font-size: 16px;
    font-style: normal;
    font-weight: 400;
    line-height: 22px; /* 137.5% */
  }
  .content-text {
    font-size: 14px;
  }
  .novel-comic-detail-page .detail-meta-h5 {
    display: block;
    margin-top: 12px;
  }
  .novel-comic-detail-page .detail-meta-h5 .pageTitle-h5 {
    font-size: 1.1rem;
    margin: 0 0 6px;
    font-weight: 600;
    color: #ffffff;
  }
  .novel-comic-detail-page .detail-meta-h5 .meta-row-h5 {
    color: #c6c6c6;
    font-size: 0.85rem;
    display: flex;
    gap: 14px;
    align-items: center;
    flex-wrap: wrap;
  }
}

.novel-comic-detail-page .detail-meta-h5 {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 10px;
}
.novel-comic-detail-page .detail-meta-h5 .meta-icon {
  width: 16px;
  height: 16px;
  object-fit: contain;
  display: inline-block;
  vertical-align: middle;
  margin-right: 6px;
  opacity: 0.9;
}
.novel-comic-detail-page .detail-meta-h5 .meta-row-h5 > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1;
  vertical-align: middle;
}
.novel-comic-detail-page .detail-meta-h5 .meta-row-h5 .author,
.novel-comic-detail-page .detail-meta-h5 .meta-row-h5 .added {
  color: #c6c6c6;
  display: inline-flex;
  align-items: center;
  gap: 0px;
}
.comic-info-h5 {
  display: none;
}
.pc-comments {
  display: block;
}
@media screen and (max-width: 824px) {
  .novel-chapters-grid .chapter-popup .popup-list.popup-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
    padding: 12px;
    box-sizing: border-box;
  }
  .pc-comments {
    display: none;
  }
  .novel-chapters-grid .chapter-popup .popup-item.comic-popup-item {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    color: #ffffff;
    text-decoration: none;
    box-sizing: border-box;
    border: 1px solid rgba(255, 255, 255, 0.03);
    padding: 6px;
    line-height: 36px;
  }
  .novel-chapters-grid .chapter-popup .popup-item.comic-popup-item .popup-number {
    font-weight: 600;
    font-size: 14px;
    color: #ffffff;
  }
  .novel-chapters-grid .chapter-popup .popup-item.comic-popup-item .popup-title {
    display: none;
  }
  .novel-chapters-grid .chapter-popup .sheet-header .range-buttons {
    display: flex;
    gap: 8px;
    padding: 8px 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .novel-chapters-grid .chapter-popup .sheet-header .range-buttons .range-option {
    background: transparent;
    border: 0;
    color: #cfcfcf;
    padding: 6px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    position: relative;
  }
  .novel-chapters-grid .chapter-popup .sheet-header .range-buttons .range-option.active {
    background: transparent;
    color: #fff;
    font-weight: 600;
    padding-bottom: 8px;
  }
  .novel-chapters-grid .chapter-popup .sheet-header .range-buttons .range-option.active::after {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 2px;
    width: 12px;
    height: 4px;
    background: #ffcc00;
    border-radius: 2px;
  }

  .novel-chapters-grid .chapter-popup .sheet {
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100%;
    margin: 0;
    border-radius: 16px 16px 0 0;
    box-sizing: border-box;
    padding: 12px;
  }

  .novel-comic-detail-page .comic-meta {
    display: none !important;
  }

  .comic-info-h5 {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
    margin: 16px auto;
    display: flex !important;
    flex-direction: column;
  }
  .comic-cover-h5 {
    position: relative;
    background: linear-gradient(180deg, #000000 0%, rgba(102, 102, 102, 0) 100%);
    overflow: hidden;
    font-size: 14px;
  }
  .comic-cover-h5 img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
  }
  .comic-cover-h5 > div {
    position: absolute;
    bottom: 0px;
    z-index: 2;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
  }
  .comic-cover-h5 strong {
    font-family: PingFang SC;
    font-weight: 400;
    font-style: Regular;
    font-size: 12px;
    line-height: 18px;
    letter-spacing: 0px;
  }

  .comic-info-h5 .comic-desc {
    margin-top: 8px;
    color: #c6c6c6;
  }
  .comic-info-h5 h1 {
    font-family: PingFang SC;
    font-weight: 400;
    font-style: Medium;
    font-size: 16px;
    leading-trim: NONE;
    line-height: 22px;
    letter-spacing: 0%;
  }
  .comic-info-h5 .tag {
    display: inline-block;
    padding: 4px 8px;
    border: 1px solid #35debc;
    color: #35debc;
    border-radius: 6px;
    font-size: 12px;
    margin-right: 8px;
    text-decoration: none;
    background: rgba(53, 222, 188, 0.03);
    line-height: 1;
    font-size: 14px;
  }
  .comic-info-h5 .tag:hover {
    background: rgba(53, 222, 188, 0.06);
  }
  .comic-info-h5-bg {
    width: 100%;
    padding: 12px;
    background: linear-gradient(0deg, #000000 0%, rgba(102, 102, 102, 0) 100%);
  }
}
