/* 小说框架子主题 - 作品详情页通用样式（.novel-frame-*，桌面双列，响应式 + 深色模式） */

/* 顶层双列布局 */
.novel-frame-story-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 20px;
    align-items: start;
    margin-top: 14px;
}

.novel-frame-story-body {
    min-width: 0;
}

/* 清除父主题 .box-body 默认 15px padding，内部区块（cover/pricing-card/chapter-list）各自管理 padding */
.novel-frame-story-article.box-body {
    padding: 0;
}

.novel-frame-story-sidebar {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    position: sticky;
    top: 80px;
}

/* 作品头部：封面 + 元信息。桌面与移动端共享渐变蓝顶 + 径向高光 + 模糊封面氛围；移动端 ≤640px 重定义为全屏沼浸版本 */
.novel-frame-story-cover {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 28px 28px 24px;
    align-items: stretch;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(191, 238, 255, .55) 0%, rgba(234, 248, 255, .3) 32%, transparent 65%);
}

/* 桌面顶部径向高光（桃色），与移动端使用同一调色 token */
.novel-frame-story-cover::after {
    content: "";
    position: absolute;
    top: -40px;
    right: -60px;
    width: 360px;
    height: 240px;
    background: radial-gradient(circle at center, rgba(248, 202, 193, .35), rgba(255, 255, 255, 0) 60%);
    pointer-events: none;
    z-index: 0;
}

/* 模糊封面背景：桌面默认启用，hero 右侧小块；移动端 ≤640 会覆盖为另一份设计 */
.novel-frame-story-mobile-bg {
    display: block;
    position: absolute;
    top: 0;
    right: 24px;
    width: 280px;
    height: 200px;
    background-position: center;
    background-size: cover;
    filter: blur(36px);
    opacity: .18;
    transform: scale(1.1);
    pointer-events: none;
    z-index: 0;
}

.novel-frame-story-hero,
.novel-frame-story-detail {
    position: relative;
    z-index: 1;
}

.novel-frame-story-hero {
    display: flex;
    gap: 22px;
    align-items: stretch; /* 让 meta 区高度撑满封面，避免右侧大空白 */
}

.novel-frame-story-detail {
    min-width: 0;
}

.novel-frame-story-thumb {
    flex: 0 0 160px;
    width: 160px;
    aspect-ratio: 3 / 4;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .12), 0 2px 6px rgba(0, 0, 0, .06);
    background: rgba(0, 0, 0, .05);
    position: relative;
}

.novel-frame-story-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.novel-frame-story-thumb-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    font-weight: 600;
    opacity: .35;
}

.novel-frame-story-meta {
    flex: 1 1 auto;
    min-width: 0;
    padding-top: 4px;
    display: flex;
    flex-direction: column;
    align-self: stretch;
}

/* 主标题：与移动端基线一致 #111827 / 800 强对比 */
.novel-frame-story-title {
    font-size: 26px;
    margin: 0 0 10px;
    line-height: 1.25;
    font-weight: 800;
    letter-spacing: .2px;
    color: #111827;
}

/* 分类徽章 */
.novel-frame-story-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 18px;
}

.novel-frame-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    line-height: 1.5;
    background: rgba(0, 0, 0, .06);
    color: inherit;
    text-decoration: none;
    transition: background .15s ease;
}

.novel-frame-badge-cat:hover {
    background: rgba(0, 0, 0, .12);
}

.novel-frame-badge-type-novel {
    background: linear-gradient(135deg, #e6f4ff 0%, #cfe7ff 100%);
    color: #0469d0;
}

.novel-frame-badge-type-comic {
    background: linear-gradient(135deg, #ffefe6 0%, #ffd9c4 100%);
    color: #d0581b;
}

/* 副标题 / 原名（标题下方小字） */
.novel-frame-story-subtitle {
    margin: -4px 0 14px;
    padding: 0;
    font-size: 13px;
    line-height: 1.5;
    color: rgba(17, 24, 39, .55);
    font-weight: 400;
}

/* 评分区（5 星点击 + score + count） */
.novel-frame-story-rating {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    margin: 10px 0 14px;
}

/* 5 颗星 */
.novel-frame-story-rating-stars {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin-right: 4px;
}

.novel-frame-story-rating-star {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #d1d5db;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    transition: color .12s ease, transform .12s ease;
}

.novel-frame-story-rating-star i {
    font-size: 18px;
}

.novel-frame-story-rating-star.is-filled {
    color: #f59e0b;
}

/* 未评分 + 登录态：hover stars 容器时整行先变金，再让 hover 元素后的兄弟变灰
   达成"点亮当前及左侧"的视觉效果 */
.novel-frame-story-rating:not(.is-rated):not(.is-guest) .novel-frame-story-rating-stars:hover .novel-frame-story-rating-star {
    color: #f59e0b;
}

.novel-frame-story-rating:not(.is-rated):not(.is-guest) .novel-frame-story-rating-stars:hover .novel-frame-story-rating-star:hover ~ .novel-frame-story-rating-star {
    color: #d1d5db;
}

.novel-frame-story-rating:not(.is-rated):not(.is-guest) .novel-frame-story-rating-star:hover {
    transform: scale(1.08);
}

/* 已评分态：星星不可点击，保持金色 */
.novel-frame-story-rating.is-rated .novel-frame-story-rating-star {
    cursor: default;
}

.novel-frame-story-rating.is-rated .novel-frame-story-rating-star.is-filled {
    color: #f59e0b;
}

/* 游客态：灰色不可交互（点击仍触发父主题 signin-loader 弹登录 modal） */
.novel-frame-story-rating.is-guest .novel-frame-story-rating-star {
    color: #d1d5db;
}

.novel-frame-story-rating.is-guest .novel-frame-story-rating-star:hover {
    color: #9ca3af;
}

/* loading 中（ajax 提交期间） */
.novel-frame-story-rating.is-loading {
    pointer-events: none;
    opacity: .7;
}

.novel-frame-story-rating-score {
    font-size: 22px;
    font-weight: 700;
    color: #0469d0;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.novel-frame-story-rating-count {
    font-size: 13px;
    color: rgba(17, 24, 39, .55);
    line-height: 1.4;
}

/* 三栏图标信息卡（作者 / 章节 / 类型）：桌面端承担作者展示，移动端与作者行并存；桌面端用 margin-top:auto 把卡片推到 meta 底部，与 thumb 底部对齐，填补封面右侧评分下方空白 */
.novel-frame-story-info-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: auto 0 0;
}

.novel-frame-story-info-card {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    padding: 12px 14px;
    background: rgba(0, 0, 0, .03);
    border: 1px solid rgba(0, 0, 0, .04);
    border-radius: 12px;
}

.novel-frame-story-info-icon {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    overflow: hidden;
    background: #fff;
    color: rgba(17, 24, 39, .55);
    font-size: 14px;
}

.novel-frame-story-info-card--author .novel-frame-story-info-icon {
    background: linear-gradient(135deg, #3b82f6, #0ea5e9);
    color: #fff;
}

/* 作者卡接入后台 _story_author_avatar：has-avatar 时图片占满圆形容器，覆盖默认渐变蓝底；
   选择器与 .novel-frame-story-info-card--author .novel-frame-story-info-icon 同特异性，需放后面赢 source order；
   dark-theme 同款再覆盖一次（dark 段特异性更高） */
.novel-frame-story-info-card--author .novel-frame-story-info-icon.has-avatar {
    background: transparent;
    border: 1px solid rgba(0, 0, 0, .06);
}

.novel-frame-story-info-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.novel-frame-story-info-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.novel-frame-story-info-label {
    font-size: 12px;
    color: rgba(17, 24, 39, .55);
    line-height: 1;
}

.novel-frame-story-info-value {
    font-size: 14px;
    font-weight: 600;
    color: #111827;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 元数据行（地区/语言/年龄分级 + 版权/出版社） */
.novel-frame-story-meta-list {
    margin: 0 0 18px;
    padding: 12px 14px;
    background: rgba(0, 0, 0, .025);
    border-radius: 8px;
}

.novel-frame-story-meta-line {
    margin: 0;
    padding: 0;
    font-size: 13px;
    line-height: 1.9;
    color: rgba(17, 24, 39, .72);
}

.novel-frame-story-meta-line + .novel-frame-story-meta-line {
    margin-top: 2px;
}

.novel-frame-story-meta-item {
    display: inline-block;
    margin-right: 18px;
    white-space: nowrap;
}

.novel-frame-story-meta-item:last-child {
    margin-right: 0;
}

.novel-frame-story-meta-label {
    color: rgba(17, 24, 39, .55);
    margin-right: 2px;
}

/* 作者行（头像 + 名字）：桌面端默认隐藏（作者位置交给三栏图标信息卡），移动端 ≤640 显示 */
.novel-frame-story-author-row {
    display: none;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 13px;
    color: rgba(17, 24, 39, .72);
}

.novel-frame-story-author-label {
    flex: 0 0 auto;
}

.novel-frame-story-author-avatar {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(135deg, #3b82f6, #0ea5e9);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}

.novel-frame-story-author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.novel-frame-story-author-name {
    min-width: 0;
    color: rgba(17, 24, 39, .85);
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 作品简介容器（标题 + 开放式截断，与移动端同语感） */
.novel-frame-story-intro-wrap {
    margin-top: 4px;
}

.novel-frame-story-public-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 14px;
    color: rgba(17, 24, 39, .55);
    font-size: 13px;
    line-height: 1.6;
}

/* 简介标题：去蓝竖线，与移动端一致的粗黑大字 */
.novel-frame-story-intro-title {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-size: 18px;
    font-weight: 800;
    color: #111827;
    margin: 0 0 12px;
    padding-left: 0;
}

/* 展开/收起按钮：桌面端与移动端都启用（取代旧的虚线滚动框），胶囊居中 */
.novel-frame-story-intro-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    width: max-content;
    max-width: 100%;
    margin: 12px auto 0;
    padding: 4px 10px;
    border: 0;
    background: transparent;
    color: #0469d0;
    font-size: 13.5px;
    font-weight: 500;
    cursor: pointer;
}

.novel-frame-story-intro-toggle i {
    font-size: 13px;
}

.novel-frame-story-intro-toggle-open {
    display: none;
}

.novel-frame-story-intro-wrap.is-open .novel-frame-story-intro-toggle-closed {
    display: none;
}

.novel-frame-story-intro-wrap.is-open .novel-frame-story-intro-toggle-open {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* 简介正文：去虚线边框 / 灰底 / 滚动框，改为 6 行截断（移动端 ≤640 会收为 3 行） */
.novel-frame-story-intro {
    display: -webkit-box;
    overflow: hidden;
    color: rgba(17, 24, 39, .78);
    font-size: 14.5px;
    line-height: 1.8;
    -webkit-line-clamp: 6;
    line-clamp: 6;
    -webkit-box-orient: vertical;
}

.novel-frame-story-intro-wrap.is-open .novel-frame-story-intro {
    display: block;
    -webkit-line-clamp: unset;
    line-clamp: unset;
    color: rgba(17, 24, 39, .85);
}

.novel-frame-story-intro p {
    margin: 0 0 8px;
}

.novel-frame-story-intro p:last-child {
    margin-bottom: 0;
}

/* 定价信息卡 */
.novel-frame-pricing-card {
    padding: 20px 28px 24px;
    border-top: 1px solid rgba(0, 0, 0, .05);
}

.novel-frame-pricing-head {
    margin: 0 0 14px;
    display: flex;
    align-items: center;
}

/* 定价卡标题：去蓝竖线，与移动端 / 简介 / 章节一致的 #111827 800 粗黑字 */
.novel-frame-pricing-title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 800;
    color: #111827;
    margin: 0;
    padding: 0;
    border: none;
}

.novel-frame-pricing-title i {
    font-size: 16px;
    color: #0469d0;
}

/* 章节统计三栏（总章节 / 免费预览 / 付费章节） */
.novel-frame-pricing-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
    padding: 14px 20px;
    background: linear-gradient(135deg, rgba(4, 105, 208, .05) 0%, rgba(4, 105, 208, .01) 100%);
    border: 1px solid rgba(4, 105, 208, .14);
    border-radius: 10px;
}

.novel-frame-pricing-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.novel-frame-pricing-stat-label {
    font-size: 12px;
    opacity: .65;
    line-height: 1;
}

.novel-frame-pricing-stat-value {
    font-size: 18px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1.2;
    color: inherit;
}

.novel-frame-pricing-stat.is-free .novel-frame-pricing-stat-value {
    color: #2d8a4d;
}

.novel-frame-pricing-stat.is-paid .novel-frame-pricing-stat-value {
    color: #e67300;
}

/* 整本购买条 */
.novel-frame-pricing-whole {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: rgba(255, 255, 255, .6);
    border: 1px solid rgba(4, 105, 208, .3);
    border-radius: 10px;
}

.novel-frame-pricing-whole.is-unlocked {
    border-color: rgba(45, 138, 77, .35);
    background: rgba(45, 138, 77, .04);
}

.novel-frame-pricing-whole-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
    flex: 1 1 auto;
}

.novel-frame-pricing-whole-title {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    opacity: .7;
}

.novel-frame-pricing-whole-title i {
    font-size: 13px;
    color: #0469d0;
}

.novel-frame-pricing-price-wrap {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 10px;
}

.novel-frame-pricing-price-original {
    font-size: 12.5px;
    opacity: .5;
    text-decoration: line-through;
    order: 1;
}

.novel-frame-pricing-price {
    font-size: 26px;
    font-weight: 700;
    color: #0469d0;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    order: 0;
}

.novel-frame-pricing-price-sign {
    font-size: 18px;
    font-weight: 600;
    margin-right: 2px;
}

.novel-frame-pricing-price-free {
    color: #2d8a4d;
}

/* 购买按钮（蓝色渐变主按钮） */
.novel-frame-pricing-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 140px;
    padding: 10px 22px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    background: linear-gradient(135deg, #0469d0 0%, #0a82f0 100%);
    color: #fff !important;
    border: none;
    box-shadow: 0 4px 12px rgba(4, 105, 208, .28);
    transition: transform .15s ease, box-shadow .15s ease, opacity .15s ease;
}

.novel-frame-pricing-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(4, 105, 208, .38);
    color: #fff !important;
}

.novel-frame-pricing-btn.is-done {
    background: linear-gradient(135deg, #2d8a4d 0%, #3aa35e 100%);
    opacity: .9;
    cursor: default;
    box-shadow: none;
}

.novel-frame-pricing-btn.is-done:hover {
    transform: none;
    box-shadow: none;
}

.novel-frame-pricing-btn i {
    font-size: 14px;
    margin-right: 0;
}

/* 提示 */
.novel-frame-pricing-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 10px 0 0;
    padding: 0 4px;
    font-size: 12px;
}

.novel-frame-pricing-hint i {
    opacity: .6;
}

/* 会员特权 */
.novel-frame-pricing-vip {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid rgba(0, 0, 0, .05);
}

.novel-frame-pricing-vip-title {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 10px;
    opacity: .75;
}

.novel-frame-pricing-vip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 10px;
}

.novel-frame-pricing-vip-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 16px 14px;
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: 10px;
    background: rgba(0, 0, 0, .02);
    transition: transform .15s ease, box-shadow .15s ease;
}

.novel-frame-pricing-vip-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .06);
}

.novel-frame-pricing-vip-card.is-vip-1 {
    background: linear-gradient(135deg, #fff8e1 0%, #fff3d6 100%);
    border-color: rgba(255, 187, 0, .3);
}

.novel-frame-pricing-vip-card.is-vip-2 {
    background: linear-gradient(135deg, #f3e8ff 0%, #ebd9ff 100%);
    border-color: rgba(147, 51, 234, .3);
}

.novel-frame-pricing-vip-card.is-active {
    box-shadow: 0 0 0 2px rgba(4, 105, 208, .5);
}

.novel-frame-pricing-vip-card.is-active:hover {
    box-shadow: 0 0 0 2px rgba(4, 105, 208, .5), 0 4px 12px rgba(0, 0, 0, .06);
}

.novel-frame-pricing-vip-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .85);
    font-size: 12.5px;
    font-weight: 600;
}

.novel-frame-pricing-vip-card.is-vip-1 .novel-frame-pricing-vip-badge {
    color: #b68100;
}

.novel-frame-pricing-vip-card.is-vip-2 .novel-frame-pricing-vip-badge {
    color: #7e22ce;
}

.novel-frame-pricing-vip-icon {
    width: 14px;
    height: 14px;
    flex: 0 0 auto;
}

.novel-frame-pricing-vip-price-text {
    font-size: 18px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.novel-frame-pricing-vip-card.is-vip-1 .novel-frame-pricing-vip-price-text {
    color: #b68100;
}

.novel-frame-pricing-vip-card.is-vip-2 .novel-frame-pricing-vip-price-text {
    color: #7e22ce;
}

.novel-frame-pricing-vip-price-sign {
    font-size: 13px;
    margin-right: 2px;
    opacity: .8;
}

.novel-frame-pricing-vip-free {
    color: #2d8a4d !important;
}

/* 章节目录 */
.novel-frame-chapter-list {
    padding: 20px 28px 28px;
    border-top: 1px solid rgba(0, 0, 0, .05);
}

/* 章节列表头部：标题 + 共 N 章 */
.novel-frame-chapter-list-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 10px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(0, 0, 0, .06);
}

/* 章节列表标题：去蓝竖线，与移动端一致 */
.novel-frame-chapter-list-title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 800;
    color: #111827;
    margin: 0;
    padding: 0;
    border: none;
}

.novel-frame-chapter-list-title i {
    font-size: 16px;
    color: #0469d0;
}

.novel-frame-chapter-list-total {
    font-size: 13px;
    opacity: .55;
    flex: 0 0 auto;
}

.novel-frame-chapter-list-more {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-size: 13px;
    color: rgba(17, 24, 39, .55);
    text-decoration: none;
    transition: color .15s ease;
}

.novel-frame-chapter-list-more i {
    font-size: 13px;
}

.novel-frame-chapter-list-more:hover {
    color: #0469d0;
}

/* 章节列表头部右侧工具区：方向 chip 组 + "更新至 N 话" 链接横排
   父 .novel-frame-chapter-list-head 是 align-items: baseline；chip 比文本高（26px），
   显式 align-self: center 让整组工具相对父容器整体中心对齐，避免基线对齐出现视觉错位 */
.novel-frame-chapter-list-tools {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
    align-self: center;
}

.novel-frame-chapter-list-order {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* chip：与 list.css 的 .novel-frame-filter-chip 视觉同步（单作品页未入队 list.css，
   作品列表方向 chip 与本处保持视觉一致；list.css 同段如有调整请同步此处） */
.novel-frame-filter-chip {
    display: inline-flex;
    align-items: center;
    height: 26px;
    padding: 0 12px;
    font-size: 12.5px;
    color: inherit;
    background: rgba(0, 0, 0, .04);
    border: 1px solid transparent;
    border-radius: 999px;
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
    transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
}

.novel-frame-filter-chip:hover {
    background: rgba(4, 105, 208, .08);
    color: #0469d0;
    text-decoration: none;
    transform: translateY(-1px);
}

.novel-frame-filter-chip.is-active,
.novel-frame-filter-chip.is-active:hover {
    background: #0469d0;
    color: #fff;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(4, 105, 208, .28);
    transform: none;
}

.novel-frame-filter-chip > i {
    margin-right: 4px;
    font-size: 11px;
}

.novel-frame-chapter-list-ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.novel-frame-chapter-item {
    border-bottom: 1px solid rgba(0, 0, 0, .05);
}

.novel-frame-chapter-item:last-child {
    border-bottom: none;
}

.novel-frame-chapter-link {
    display: grid;
    grid-template-columns: 36px 1fr auto auto;
    align-items: center;
    gap: 14px;
    padding: 12px 10px;
    color: inherit;
    text-decoration: none;
    border-radius: 6px;
    transition: background .15s ease;
}

.novel-frame-chapter-link:hover {
    background: rgba(4, 105, 208, .05);
    color: inherit;
}

.novel-frame-chapter-index {
    font-size: 12px;
    opacity: .45;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

.novel-frame-chapter-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
}

.novel-frame-chapter-link:hover .novel-frame-chapter-name {
    color: #0469d0;
}

.novel-frame-chapter-flags {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 6px;
}

.novel-frame-chapter-flag {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    line-height: 1.5;
    white-space: nowrap;
}

.novel-frame-chapter-flag.is-free {
    background: #e8f6ed;
    color: #2d8a4d;
}

.novel-frame-chapter-flag.is-paid {
    background: #fde9e7;
    color: #c0392b;
}

.novel-frame-chapter-flag.is-vip {
    background: #fff3d6;
    color: #b68100;
}

.novel-frame-chapter-flag.is-preview {
    background: #e8f1ff;
    color: #0469d0;
}

.novel-frame-chapter-date {
    font-size: 12px;
    opacity: .5;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* 作品话题区（讨论区入口卡片） */
.novel-frame-story-discuss {
    margin: 0;
    padding: 16px 28px;
    border-top: 1px solid rgba(0, 0, 0, .05);
}

.novel-frame-story-discuss-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: inherit;
    text-decoration: none;
    transition: color .15s ease;
}

.novel-frame-story-discuss-inner:hover {
    color: #0469d0;
}

.novel-frame-story-discuss-topic {
    display: inline-flex;
    align-items: baseline;
    gap: 2px;
    font-size: 15px;
    font-weight: 600;
    min-width: 0;
}

.novel-frame-story-discuss-hash {
    color: #0469d0;
    font-weight: 800;
}

.novel-frame-story-discuss-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.novel-frame-story-discuss-meta {
    flex: 0 0 auto;
    font-size: 13px;
    color: rgba(17, 24, 39, .5);
}

/* 移动端底部固定操作栏（桌面端隐藏） */
.novel-frame-mobile-bar {
    display: none;
}

/* 侧边栏 · 互动栏（点赞 / 收藏 / 分享） */
.novel-frame-interact {
    display: flex;
    align-items: stretch;
    gap: 8px;
    padding: 12px;
    background: var(--main-bg-color, #fff);
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
}

.novel-frame-interact-btn {
    flex: 1 1 0;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 10px 6px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: rgba(0, 0, 0, .03);
    color: inherit;
    font-size: 13px;
    text-decoration: none;
    cursor: pointer;
    transition: all .15s ease;
}

.novel-frame-interact-btn:hover,
.novel-frame-interact-btn:focus {
    background: rgba(4, 105, 208, .08);
    border-color: rgba(4, 105, 208, .15);
    color: #0469d0;
    text-decoration: none;
}

/* 父主题 main.js 通过 actived class 切换激活态；is-active 保留兼容 */
.novel-frame-interact-btn.is-active,
.novel-frame-interact-btn.actived {
    background: rgba(4, 105, 208, .1);
    color: #0469d0;
    border-color: rgba(4, 105, 208, .25);
}

/* 父主题 svg.icon / fa 图标统一尺寸；用直接子选择器避免命中 svg 内部可能的 text */
.novel-frame-interact-btn > .icon,
.novel-frame-interact-btn > svg,
.novel-frame-interact-btn > i {
    width: 16px;
    height: 16px;
    font-size: 16px;
    line-height: 1;
}

/* 父主题约定的 <text>（标签）/ <count>（计数）自定义元素 */
.novel-frame-interact-btn > text {
    display: block;
    font-size: 12px;
    opacity: .75;
    line-height: 1.3;
}

.novel-frame-interact-btn > count {
    display: block;
    font-size: 12px;
    font-weight: 600;
    opacity: .85;
    line-height: 1.3;
    font-variant-numeric: tabular-nums;
}

/* 加载中动效（父主题 ajax beforeSend 把 <count> 内容替换为 <i class="loading zts">） */
.novel-frame-interact-btn > count .loading {
    display: inline-block;
}

/* 侧边栏 · 相关推荐（2 列窄卡片） */
.novel-frame-related {
    padding: 16px;
    background: var(--main-bg-color, #fff);
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
}

.novel-frame-related-head {
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, .06);
}

/* 侧边栏「相关推荐」标题：与主体一致的粗黑字（但依侧边栏体量字号略小） */
.novel-frame-related-title {
    font-size: 16px;
    font-weight: 800;
    color: #111827;
    margin: 0;
    padding: 0;
}

.novel-frame-related-grid {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.novel-frame-related-item {
    min-width: 0;
}

.novel-frame-related-link {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 8px;
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: 8px;
    color: inherit;
    text-decoration: none;
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.novel-frame-related-link:hover {
    border-color: rgba(4, 105, 208, .35);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .06);
    transform: translateY(-1px);
    color: inherit;
}

.novel-frame-related-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 4;
    border-radius: 6px;
    overflow: hidden;
    background: rgba(0, 0, 0, .05);
}

.novel-frame-related-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .35s ease;
}

.novel-frame-related-link:hover .novel-frame-related-thumb img {
    transform: scale(1.05);
}

.novel-frame-related-thumb-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    opacity: .4;
}

.novel-frame-related-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.novel-frame-related-name {
    font-size: 13px;
    font-weight: 500;
    margin: 0;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.novel-frame-related-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.novel-frame-chip {
    display: inline-block;
    padding: 1px 7px;
    font-size: 11px;
    line-height: 1.5;
    border-radius: 10px;
    background: rgba(0, 0, 0, .06);
    color: inherit;
    white-space: nowrap;
}

.novel-frame-chip-novel {
    background: rgba(4, 105, 208, .1);
    color: #0469d0;
}

.novel-frame-chip-comic {
    background: rgba(208, 88, 27, .1);
    color: #d0581b;
}

.novel-frame-story-card__stats {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    color: rgba(17, 24, 39, .48);
    font-size: 11px;
    line-height: 1.2;
}

.novel-frame-story-card__stat {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    min-width: 0;
    font-variant-numeric: tabular-nums;
}

.novel-frame-story-card__stat i {
    font-size: 11px;
    line-height: 1;
    opacity: .78;
}

/* 响应式 */
@media (max-width: 1200px) {
    .novel-frame-story-layout {
        grid-template-columns: minmax(0, 1fr) 300px;
    }
}

@media (max-width: 991px) {
    /* 双列 → 单列堆叠，侧边栏移到底部 */
    .novel-frame-story-layout {
        grid-template-columns: 1fr;
    }

    .novel-frame-story-sidebar {
        position: static;
    }

    .novel-frame-related-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .novel-frame-chapter-link {
        grid-template-columns: 32px 1fr auto auto;
        gap: 10px;
    }

    /* 中屏 hero 变窄，模糊封面背景容易裁切丑陋 → 隐藏（仅桌面 ≥992 启用） */
    .novel-frame-story-mobile-bg {
        display: none;
    }
}

@media (max-width: 768px) {
    /* 中屏 hero 紧凑化：保持封面左 + meta 右的横排，让封面更小、padding 更紧 */
    .novel-frame-story-cover {
        padding: 18px 18px 16px;
        gap: 16px;
    }

    .novel-frame-story-hero {
        gap: 18px;
    }

    .novel-frame-pricing-whole {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .novel-frame-pricing-btn {
        width: 100%;
    }

    .novel-frame-story-thumb {
        flex: 0 0 140px;
        width: 140px;
    }

    .novel-frame-story-badges {
        justify-content: flex-start;
    }

    .novel-frame-pricing-card {
        padding: 18px 20px 20px;
    }

    .novel-frame-pricing-stats {
        padding: 12px 16px;
    }

    .novel-frame-pricing-stat-value {
        font-size: 16px;
    }

    .novel-frame-pricing-vip-grid {
        grid-template-columns: 1fr;
    }

    .novel-frame-chapter-list {
        padding: 18px 16px 18px;
    }

    .novel-frame-chapter-link {
        grid-template-columns: 28px 1fr auto;
        gap: 8px;
        padding: 10px 6px;
    }

    .novel-frame-chapter-date {
        display: none;
    }

    .novel-frame-chapter-list-head {
        flex-wrap: wrap;
    }

    .novel-frame-chapter-list-tools {
        gap: 8px;
    }

    .novel-frame-filter-chip {
        height: 24px;
        padding: 0 10px;
        font-size: 12px;
    }

    .novel-frame-related-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

    .novel-frame-related-name {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .novel-frame-related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .novel-frame-story-title {
        font-size: 20px;
    }

    .novel-frame-pricing-price {
        font-size: 22px;
    }

    .novel-frame-interact {
        padding: 10px 8px;
    }

    .novel-frame-interact-btn {
        font-size: 12px;
    }
}

@media (max-width: 640px) {
    /* 与父主题导航栏无缝衔接：父主题 body 给 main 上方留 ~20px spacer，移动端用负 margin 抵消，
       让 hero 浅蓝渐变直接贴住 header 底；header 自身固定 / 半透明，浅蓝色会自然透出 */
    main.novel-frame-story {
        margin-top: -20px;
    }

    .novel-frame-story {
        padding: 0 0 76px;
        background: #fff;
    }

    .novel-frame-story-layout {
        gap: 0;
        margin-top: 0;
    }

    .novel-frame-story-article.box-body {
        overflow: hidden;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    .novel-frame-story-cover {
        position: relative;
        align-items: stretch;
        gap: 0;
        padding: 22px 10px 14px;
        overflow: hidden;
        text-align: left;
        background: linear-gradient(180deg, #bfeeff 0%, #eaf8ff 38%, #fff 70%, #fff 100%);
    }

    .novel-frame-story-cover::after {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient(circle at 62% 24%, rgba(248, 202, 193, .5), rgba(255, 255, 255, 0) 42%);
        pointer-events: none;
    }

    /* 模糊装饰背景：移动端 hero 高度低，模糊块视觉收益小（与桌面端启用形成有意差异） */
    .novel-frame-story-mobile-bg {
        display: none;
    }

    .novel-frame-story-hero,
    .novel-frame-story-detail {
        position: relative;
        z-index: 1;
    }

    .novel-frame-story-hero {
        display: flex;
        align-items: stretch;
        gap: 20px;
        margin-bottom: 24px;
    }

    .novel-frame-story-thumb {
        flex: 0 0 122px;
        width: 122px;
        border-radius: 6px;
        box-shadow: 0 8px 22px rgba(15, 23, 42, .18);
    }

    .novel-frame-story-thumb img {
        border-radius: 0;
    }

    .novel-frame-story-meta {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        padding-top: 4px;
    }

    .novel-frame-story-title {
        margin: 0 0 6px;
        color: #111827;
        font-size: 23px;
        line-height: 1.25;
        font-weight: 800;
    }

    .novel-frame-story-subtitle {
        margin: 0 0 12px;
        color: rgba(17, 24, 39, .6);
        font-size: 12.5px;
        line-height: 1.5;
    }

    /* 分类 chip：单行灰底胶囊，只展示第一个，溢出隐藏 */
    .novel-frame-story-badges {
        display: flex;
        flex-wrap: nowrap;
        justify-content: flex-start;
        gap: 6px;
        max-height: 26px;
        margin: 0 0 10px;
        overflow: hidden;
    }

    .novel-frame-story-badges .novel-frame-badge {
        flex: 0 0 auto;
        max-width: 104px;
        padding: 3px 10px;
        overflow: hidden;
        background: rgba(17, 24, 39, .06);
        color: rgba(17, 24, 39, .85);
        font-size: 12px;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .novel-frame-badge-status {
        background: rgba(255, 255, 255, .88);
        color: #111827;
    }

    /* 评分区：score 大字蓝色，count 灰字（移动端紧凑：星 / score / count 全部缩一档） */
    .novel-frame-story-rating {
        display: flex;
        align-items: baseline;
        gap: 8px;
        margin: 0 0 2px;
    }

    .novel-frame-story-rating-stars {
        gap: 1px;
        margin-right: 2px;
    }

    .novel-frame-story-rating-star {
        width: 18px;
        height: 18px;
        font-size: 13px;
    }

    .novel-frame-story-rating-score {
        font-size: 17px;
        font-weight: 700;
        color: #0469d0;
    }

    .novel-frame-story-rating-count {
        font-size: 12px;
        color: rgba(17, 24, 39, .55);
    }

    .novel-frame-story-detail {
        padding: 0;
    }

    /* 元数据行：浅灰底卡片，两行 pipe 分隔 */
    .novel-frame-story-meta-list {
        margin: 0 0 18px;
        padding: 0;
        background: transparent;
        color: rgba(17, 24, 39, .72);
    }

    .novel-frame-story-meta-line {
        font-size: 13px;
        line-height: 1.9;
        color: rgba(17, 24, 39, .72);
    }

    .novel-frame-story-meta-line + .novel-frame-story-meta-line {
        margin-top: 4px;
    }

    .novel-frame-story-meta-item {
        margin-right: 14px;
    }

    .novel-frame-story-meta-label {
        color: rgba(17, 24, 39, .55);
    }

    /* 简介标题：粗体黑字，左对齐 */
    .novel-frame-story-intro-title {
        display: flex;
        align-items: baseline;
        justify-content: flex-start;
        margin: 0 0 10px;
        padding-left: 0;
        color: #111827;
        font-size: 19px;
        font-weight: 800;
    }

    .novel-frame-story-intro-title::before {
        display: none;
    }

    .novel-frame-story-intro-wrap {
        margin: 0 0 18px;
    }

    .novel-frame-story-intro {
        display: -webkit-box;
        max-height: none;
        padding: 0;
        overflow: hidden;
        border: 0;
        background: transparent;
        color: rgba(17, 24, 39, .72);
        font-size: 14.5px;
        line-height: 1.8;
        opacity: 1;
        -webkit-line-clamp: 3;
        line-clamp: 3;
        -webkit-box-orient: vertical;
    }

    /* 展开后取消行截断 */
    .novel-frame-story-intro-wrap.is-open .novel-frame-story-intro {
        display: block;
        -webkit-line-clamp: unset;
        line-clamp: unset;
        color: rgba(17, 24, 39, .82);
    }

    /* 展开按钮：独立一行，居中在简介下方
       inline-flex 不能 margin:auto 水平居中；改用 flex + width:max-content + 左右 margin:auto */
    .novel-frame-story-intro-toggle {
        display: flex;
        align-items: center;
        gap: 4px;
        width: max-content;
        max-width: 100%;
        margin: 10px auto 0;
        padding: 4px 10px;
        font-size: 13.5px;
        font-weight: 500;
        color: #0469d0;
        background: transparent;
        border: 0;
        cursor: pointer;
    }

    .novel-frame-story-public-stats {
        gap: 14px;
        margin-top: 0;
        margin-bottom: 14px;
        color: rgba(17, 24, 39, .58);
        font-size: 13px;
    }

    /* 作者行：移动端不再展示（信息已聚合到上方三栏卡所属位置；避免与上方信息重复） */
    .novel-frame-story-author-row {
        display: none;
    }

    /* 三栏图标信息卡：移动端只保留 章节 / 类型 两张（作者卡隐藏），
       2 列布局对齐到 meta 列起点，不再 -142px 跨出 thumb 列 —— 避免 2 栏跨整宽时章节卡左边缘
       压到 thumb 下方与评分行错位。整体卡片缩小（icon/padding/字号 一致下调一档）。 */
    .novel-frame-story-info-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
        margin: auto 0 0;
    }

    .novel-frame-story-info-card--author {
        display: none;
    }

    .novel-frame-story-info-card {
        gap: 6px;
        padding: 7px 9px;
        border-radius: 10px;
    }

    .novel-frame-story-info-icon {
        width: 24px;
        height: 24px;
        font-size: 11px;
    }

    .novel-frame-story-info-label {
        font-size: 10.5px;
    }

    .novel-frame-story-info-value {
        font-size: 12.5px;
    }

    .novel-frame-pricing-card {
        display: none;
    }

    .novel-frame-pricing-head {
        margin-bottom: 10px;
    }

    .novel-frame-pricing-title {
        padding-left: 0;
        font-size: 16px;
    }

    .novel-frame-pricing-title::before {
        display: none;
    }

    .novel-frame-pricing-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 10px;
        padding: 10px;
        border-radius: 12px;
    }

    .novel-frame-pricing-stat {
        align-items: center;
        gap: 3px;
        text-align: center;
    }

    .novel-frame-pricing-stat-label {
        font-size: 11px;
    }

    .novel-frame-pricing-stat-value {
        font-size: 15px;
    }

    .novel-frame-pricing-whole {
        flex-direction: row;
        align-items: center;
        gap: 10px;
        padding: 12px;
        border-radius: 14px;
    }

    .novel-frame-pricing-whole-title {
        font-size: 11.5px;
    }

    .novel-frame-pricing-price {
        font-size: 21px;
    }

    .novel-frame-pricing-price-sign {
        font-size: 15px;
    }

    .novel-frame-pricing-btn {
        width: auto;
        min-width: 104px;
        padding: 9px 12px;
        border-radius: 999px;
        font-size: 13px;
    }

    .novel-frame-pricing-hint {
        font-size: 11.5px;
        line-height: 1.6;
    }

    .novel-frame-pricing-vip {
        margin-top: 14px;
        padding-top: 14px;
    }

    .novel-frame-pricing-vip-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .novel-frame-pricing-vip-card {
        padding: 12px 8px;
    }

    .novel-frame-chapter-list {
        padding: 14px 10px 18px;
        border-top: 0;
    }

    .novel-frame-chapter-list-head {
        flex-wrap: nowrap;
        align-items: center;
        margin-bottom: 14px;
        padding-bottom: 0;
        border-bottom: 0;
    }

    .novel-frame-chapter-list-title {
        padding-left: 0;
        color: #111827;
        font-size: 18px;
        font-weight: 800;
    }

    .novel-frame-chapter-list-title::before {
        display: none;
    }

    .novel-frame-chapter-list-total {
        color: rgba(17, 24, 39, .5);
        font-size: 14px;
    }

    /* "更新至 N 话 >" 链接 */
    .novel-frame-chapter-list-more {
        color: rgba(17, 24, 39, .5);
        font-size: 14px;
    }

    .novel-frame-chapter-list-more i {
        margin-left: 2px;
        font-size: 14px;
    }

    .novel-frame-story-sidebar {
        gap: 0;
    }

    /* 移动端不再渲染侧边栏点赞/收藏/分享 —— 互动下沉到底部 mobile-bar 4 按钮 */
    .novel-frame-interact {
        display: none;
    }

    /* 作品话题区（讨论入口卡片） */
    .novel-frame-story-discuss {
        padding: 14px 16px;
        margin: 4px 0 0;
        border-top: 0;
    }

    .novel-frame-story-discuss-topic {
        font-size: 15px;
    }

    .novel-frame-story-discuss-hash {
        color: #0469d0;
        font-weight: 800;
        margin-right: 2px;
    }

    .novel-frame-story-discuss-meta {
        font-size: 13px;
        color: rgba(17, 24, 39, .5);
    }

    .novel-frame-story-discuss-meta::after {
        content: "\f105"; /* fa-angle-right */
        font-family: FontAwesome;
        margin-left: 4px;
    }

    /* 移动端底部固定操作栏（4 按钮） */
    .novel-frame-mobile-bar {
        display: flex;
        position: fixed;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 50;
        align-items: center;
        gap: 6px;
        padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
        background: #fff;
        box-shadow: 0 -4px 14px rgba(15, 23, 42, .08);
    }

    .novel-frame-mobile-bar-btn {
        flex: 1 1 0;
        display: inline-flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2px;
        padding: 4px 6px;
        border: 0;
        background: transparent;
        color: rgba(17, 24, 39, .8);
        font-size: 11px;
        line-height: 1.3;
        text-decoration: none;
        cursor: pointer;
        transition: color .15s ease;
    }

    .novel-frame-mobile-bar-btn i {
        font-size: 18px;
        line-height: 1;
    }

    .novel-frame-mobile-bar-btn:hover,
    .novel-frame-mobile-bar-btn:focus {
        color: #0469d0;
        text-decoration: none;
    }

    .novel-frame-mobile-bar-btn.actived,
    .novel-frame-mobile-bar-btn.actived:hover {
        color: #f59e0b;
    }

    .novel-frame-mobile-bar-label {
        font-size: 11px;
        line-height: 1.3;
    }

    .novel-frame-mobile-bar-cta {
        flex: 0 0 auto;
        margin-left: 6px;
        display: inline-flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 1px;
        min-width: 120px;
        padding: 8px 20px;
        border-radius: 999px;
        background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
        color: #fff;
        text-decoration: none;
        box-shadow: 0 4px 12px rgba(15, 23, 42, .22);
    }

    .novel-frame-mobile-bar-cta:hover {
        color: #fff;
        text-decoration: none;
    }

    .novel-frame-mobile-bar-cta.is-disabled {
        opacity: .6;
        pointer-events: none;
    }

    .novel-frame-mobile-bar-cta-main {
        font-size: 14px;
        font-weight: 700;
        line-height: 1.2;
    }

    .novel-frame-mobile-bar-cta-sub {
        font-size: 11px;
        opacity: .75;
        line-height: 1.2;
    }

    .novel-frame-related {
        display: none;
    }

    .novel-frame-related-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
    }

    .novel-frame-related-link {
        padding: 0;
        border: 0;
        background: transparent;
    }

    .novel-frame-related-thumb {
        border-radius: 10px;
    }

    .novel-frame-related-chips {
        display: none;
    }
}

@media (max-width: 360px) {
    .novel-frame-pricing-whole {
        flex-direction: column;
        align-items: stretch;
    }

    .novel-frame-pricing-btn {
        width: 100%;
    }

    .novel-frame-related-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* 深色模式（依赖父主题 body.dark-theme） */

/* 桌面默认 cover 区氛围层的深色适配（移动端 ≤640 下方会独立覆盖） */
body.dark-theme .novel-frame-story-cover {
    background: linear-gradient(180deg, rgba(94, 168, 255, .12) 0%, rgba(94, 168, 255, .04) 32%, transparent 65%);
}

body.dark-theme .novel-frame-story-cover::after {
    background: radial-gradient(circle at center, rgba(248, 202, 193, .14), rgba(255, 255, 255, 0) 60%);
}

body.dark-theme .novel-frame-story-intro {
    color: rgba(255, 255, 255, .72);
}

body.dark-theme .novel-frame-story-intro-wrap.is-open .novel-frame-story-intro {
    color: rgba(255, 255, 255, .82);
}

/* 主体各区块标题 与 侧边栏推荐标题：深色模式下高对比白字 */
body.dark-theme .novel-frame-story-intro-title,
body.dark-theme .novel-frame-pricing-title,
body.dark-theme .novel-frame-chapter-list-title,
body.dark-theme .novel-frame-related-title {
    color: rgba(255, 255, 255, .92);
}

body.dark-theme .novel-frame-badge {
    background: rgba(255, 255, 255, .08);
}

body.dark-theme .novel-frame-badge-cat:hover {
    background: rgba(255, 255, 255, .14);
}

body.dark-theme .novel-frame-pricing-card,
body.dark-theme .novel-frame-chapter-list {
    border-top-color: rgba(255, 255, 255, .06);
}

body.dark-theme .novel-frame-pricing-stats {
    background: linear-gradient(135deg, rgba(4, 105, 208, .12) 0%, rgba(4, 105, 208, .03) 100%);
    border-color: rgba(4, 105, 208, .28);
}

body.dark-theme .novel-frame-pricing-whole {
    background: rgba(255, 255, 255, .02);
    border-color: rgba(4, 105, 208, .4);
}

body.dark-theme .novel-frame-pricing-whole.is-unlocked {
    background: rgba(45, 138, 77, .08);
    border-color: rgba(45, 138, 77, .45);
}

body.dark-theme .novel-frame-pricing-vip {
    border-top-color: rgba(255, 255, 255, .08);
}

body.dark-theme .novel-frame-pricing-vip-card {
    background: rgba(255, 255, 255, .04);
    border-color: rgba(255, 255, 255, .08);
}

body.dark-theme .novel-frame-pricing-vip-card.is-vip-1 {
    background: linear-gradient(135deg, rgba(255, 187, 0, .18) 0%, rgba(255, 187, 0, .06) 100%);
    border-color: rgba(255, 187, 0, .35);
}

body.dark-theme .novel-frame-pricing-vip-card.is-vip-2 {
    background: linear-gradient(135deg, rgba(147, 51, 234, .18) 0%, rgba(147, 51, 234, .06) 100%);
    border-color: rgba(147, 51, 234, .35);
}

body.dark-theme .novel-frame-pricing-vip-badge {
    background: rgba(0, 0, 0, .25);
}

body.dark-theme .novel-frame-chapter-link:hover {
    background: rgba(4, 105, 208, .12);
}

body.dark-theme .novel-frame-chapter-item {
    border-bottom-color: rgba(255, 255, 255, .06);
}

body.dark-theme .novel-frame-chapter-list-head,
body.dark-theme .novel-frame-related-head {
    border-bottom-color: rgba(255, 255, 255, .1);
}

body.dark-theme .novel-frame-interact,
body.dark-theme .novel-frame-related {
    background: rgba(255, 255, 255, .02);
    box-shadow: none;
}

body.dark-theme .novel-frame-interact-btn {
    background: rgba(255, 255, 255, .04);
}

@media (max-width: 640px) {
    /* 亮色态 .novel-frame-story 强写 #fff（让 main 容器整体变白，覆盖父主题 body 灰底）；
       夜间态需透回父主题 body 暗色，否则 cover 之后的 chapter-list / discuss / 评论区
       仍坐在 #fff 上，叠加 dark 下的浅色文字 → 文字不可读 */
    body.dark-theme .novel-frame-story {
        background: transparent;
    }

    /* 与亮色版"上方蓝氛围 → 向下透明过渡"对偶：上方淡蓝 token → 中段衰减 → 完全透明
       让 body 暗底从底部自然托起，避免 135deg + 重黑色渐变造成"右下角整片纯黑"突兀感 */
    body.dark-theme .novel-frame-story-cover {
        background: linear-gradient(180deg, rgba(94, 168, 255, .14) 0%, rgba(94, 168, 255, .05) 38%, transparent 70%);
    }

    /* ::after 高光：亮色版用桃色径向，dark 下改为蓝色径向轻 tint —— 不再叠第二层黑色 */
    body.dark-theme .novel-frame-story-cover::after {
        background: radial-gradient(circle at 62% 24%, rgba(94, 168, 255, .18), rgba(255, 255, 255, 0) 42%);
    }

    body.dark-theme .novel-frame-interact {
        background: rgba(26, 28, 32, .9);
    }
}

body.dark-theme .novel-frame-interact-btn:hover,
body.dark-theme .novel-frame-interact-btn:focus,
body.dark-theme .novel-frame-interact-btn.is-active,
body.dark-theme .novel-frame-interact-btn.actived {
    background: rgba(4, 105, 208, .2);
}

body.dark-theme .novel-frame-related-link {
    border-color: rgba(255, 255, 255, .08);
}

body.dark-theme .novel-frame-related-link:hover {
    border-color: rgba(4, 105, 208, .5);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .3);
}

body.dark-theme .novel-frame-chip {
    background: rgba(255, 255, 255, .08);
}

body.dark-theme .novel-frame-story-card__stats {
    color: rgba(255, 255, 255, .48);
}

/* 新增元素（副标题 / 评分 / 元数据 / 作者行 / 讨论区 / 底部栏）的深色模式 */
body.dark-theme .novel-frame-story-subtitle {
    color: rgba(255, 255, 255, .55);
}

body.dark-theme .novel-frame-story-rating-score {
    color: #60a5fa;
}

body.dark-theme .novel-frame-story-rating-count {
    color: rgba(255, 255, 255, .55);
}

body.dark-theme .novel-frame-story-meta-list {
    background: rgba(255, 255, 255, .04);
}

body.dark-theme .novel-frame-story-meta-line {
    color: rgba(255, 255, 255, .72);
}

body.dark-theme .novel-frame-story-meta-label {
    color: rgba(255, 255, 255, .48);
}

body.dark-theme .novel-frame-story-info-card {
    background: rgba(255, 255, 255, .04);
    border-color: rgba(255, 255, 255, .06);
}

body.dark-theme .novel-frame-story-info-icon {
    background: rgba(255, 255, 255, .08);
    color: rgba(255, 255, 255, .68);
}

body.dark-theme .novel-frame-story-info-card--author .novel-frame-story-info-icon {
    background: linear-gradient(135deg, #3b82f6, #0ea5e9);
    color: #fff;
}

/* 暗色主题下作者卡接入头像：透明底 + 浅色细边，与亮色主题对应 */
body.dark-theme .novel-frame-story-info-card--author .novel-frame-story-info-icon.has-avatar {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, .12);
}

body.dark-theme .novel-frame-story-info-label {
    color: rgba(255, 255, 255, .55);
}

body.dark-theme .novel-frame-story-info-value {
    color: rgba(255, 255, 255, .92);
}

body.dark-theme .novel-frame-story-author-row {
    color: rgba(255, 255, 255, .7);
}

body.dark-theme .novel-frame-story-author-name {
    color: rgba(255, 255, 255, .88);
}

body.dark-theme .novel-frame-story-discuss {
    border-top-color: rgba(255, 255, 255, .06);
}

body.dark-theme .novel-frame-story-discuss-meta {
    color: rgba(255, 255, 255, .5);
}

body.dark-theme .novel-frame-chapter-list-more {
    color: rgba(255, 255, 255, .5);
}

/* 方向 chip 暗色：与 list.css 暗色段同步 */
body.dark-theme .novel-frame-filter-chip {
    background: rgba(255, 255, 255, .06);
}

body.dark-theme .novel-frame-filter-chip:hover {
    background: rgba(94, 168, 255, .18);
    color: #9ec5ff;
}

body.dark-theme .novel-frame-filter-chip.is-active,
body.dark-theme .novel-frame-filter-chip.is-active:hover {
    background: #1f6fd8;
    box-shadow: 0 2px 8px rgba(31, 111, 216, .4);
}

body.dark-theme .novel-frame-story-intro-toggle {
    color: #60a5fa;
}

@media (max-width: 640px) {
    body.dark-theme .novel-frame-mobile-bar {
        background: rgba(26, 28, 32, .96);
        box-shadow: 0 -4px 14px rgba(0, 0, 0, .35);
    }

    body.dark-theme .novel-frame-mobile-bar-btn {
        color: rgba(255, 255, 255, .78);
    }

    body.dark-theme .novel-frame-mobile-bar-btn:hover,
    body.dark-theme .novel-frame-mobile-bar-btn:focus {
        color: #60a5fa;
    }

    body.dark-theme .novel-frame-mobile-bar-cta {
        background: linear-gradient(135deg, #4b5563 0%, #1f2937 100%);
    }

    body.dark-theme .novel-frame-story-meta-list {
        background: transparent;
    }
}

/* 侧边栏 · 人气榜（template-parts/story/hot-rank.php + assets/js/story.js）
   每项同构嵌入 .normal（简约层）+ .detail（大卡层）双层，.is-active 互斥切換；
   JS 仅 mouseenter 时切 class，无 DOM 替换 / data-* 契约。≤640px 整模块 display:none。
   勿改名 .novel-frame-hot-rank-* 前缀，PHP / CSS / JS 三方严格绑定。 */

.novel-frame-hot-rank {
    padding: 16px;
    background: var(--main-bg-color, #fff);
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
    margin-bottom: 16px;
}

.novel-frame-hot-rank-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, .06);
}

.novel-frame-hot-rank-title {
    margin: 0;
    padding: 0;
    font-size: 18px;
    font-weight: 800;
    color: #111827;
    line-height: 1.4;
}

.novel-frame-hot-rank-more {
    flex: 0 0 auto;
    padding: 4px 12px;
    border: 1px solid rgba(0, 0, 0, .12);
    border-radius: 4px;
    font-size: 12px;
    line-height: 1.5;
    color: rgba(17, 24, 39, .6);
    text-decoration: none;
    transition: color .15s ease, border-color .15s ease, background-color .15s ease;
}

.novel-frame-hot-rank-more:hover {
    color: #0469d0;
    border-color: rgba(4, 105, 208, .35);
    background: rgba(4, 105, 208, .04);
    text-decoration: none;
}

.novel-frame-hot-rank-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* 列表项容器：内嵌 .normal + .detail 双层，is-active 互斥显示 */
.novel-frame-hot-rank-item {
    margin: 0;
    padding: 0;
    list-style: none;
}

/* 默认显示简约层、隐藏大卡层 */
.novel-frame-hot-rank-normal { display: flex; }
.novel-frame-hot-rank-detail { display: none; }

/* 激活态反转：仅大卡层可见 */
.novel-frame-hot-rank-item.is-active .novel-frame-hot-rank-normal { display: none; }
.novel-frame-hot-rank-item.is-active .novel-frame-hot-rank-detail {
    display: grid;
    grid-template-columns: 88px 1fr;
    gap: 12px;
}

/* 简约层：序号 / 标题 / 作者 横向单行 */
.novel-frame-hot-rank-normal {
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    margin: 0 -10px;
    border-radius: 4px;
    transition: background-color .15s ease;
}

.novel-frame-hot-rank-normal:hover {
    background: rgba(4, 105, 208, .04);
}

/* 简约序号：等宽数字，1-3 高亮金色 */
.novel-frame-hot-rank-num {
    flex: 0 0 22px;
    text-align: center;
    font-size: 14px;
    font-weight: 700;
    color: rgba(17, 24, 39, .35);
    font-variant-numeric: tabular-nums;
    line-height: 1.4;
}

.novel-frame-hot-rank-num.is-top {
    color: #f59e0b;
}

/* 简约标题：弹性主导宽度，单行 ellipsis */
.novel-frame-hot-rank-title-mini {
    flex: 1 1 auto;
    min-width: 0;
    color: #1f2937;
    font-size: 13.5px;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color .15s ease;
}

.novel-frame-hot-rank-title-mini:hover {
    color: #0469d0;
    text-decoration: none;
}

/* 简约作者：右侧灰色淡化 */
.novel-frame-hot-rank-author {
    flex: 0 0 auto;
    max-width: 40%;
    font-size: 12px;
    color: rgba(17, 24, 39, .42);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 大卡层：封面左 + 信息区右（仅 is-active 时显示） */
.novel-frame-hot-rank-detail {
    align-items: start;
    padding: 10px 0 14px;
}

/* 封面 88×118，hover 缓慢放大 */
.novel-frame-hot-rank-thumb {
    position: relative;
    display: block;
    width: 88px;
    height: 118px;
    overflow: hidden;
    background: rgba(0, 0, 0, .04);
    text-decoration: none;
}

.novel-frame-hot-rank-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .35s cubic-bezier(.2, 0, .2, 1);
}

.novel-frame-hot-rank-thumb:hover img {
    transform: scale(1.05);
}

.novel-frame-hot-rank-thumb-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(17, 24, 39, .4);
    font-size: 13px;
    letter-spacing: 2px;
}

/* 大卡 info 列：标题头 / 作者 / 简介 / 更新至 纵向 */
.novel-frame-hot-rank-detail-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

/* 大卡顶部：序号方块 + 大标题 */
.novel-frame-hot-rank-detail-head {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

/* 序号方块：默认灰色（4-10），1-3 切金色渐变 */
.novel-frame-hot-rank-num-block {
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(17, 24, 39, .35);
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    border-radius: 2px;
    font-variant-numeric: tabular-nums;
}

.novel-frame-hot-rank-num-block.is-top {
    background: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
    box-shadow: 0 1px 3px rgba(234, 88, 12, .3);
}

/* 大卡标题：粗大字号 */
.novel-frame-hot-rank-title-large {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 15px;
    font-weight: 700;
    color: #111827;
    line-height: 1.3;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color .15s ease;
}

.novel-frame-hot-rank-title-large:hover {
    color: #0469d0;
    text-decoration: none;
}

/* 大卡作者：蓝色（与简约态作者灰色区分，参考快看视觉强调） */
.novel-frame-hot-rank-detail-author {
    margin: 0;
    font-size: 12px;
    color: rgba(4, 105, 208, .75);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 大卡简介：2 行截断 */
.novel-frame-hot-rank-detail-excerpt {
    margin: 0;
    font-size: 12px;
    line-height: 1.55;
    color: rgba(17, 24, 39, .55);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

/* 更新至：单行 */
.novel-frame-hot-rank-detail-update {
    margin: 0;
    font-size: 12px;
    line-height: 1.5;
    color: rgba(17, 24, 39, .55);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.novel-frame-hot-rank-update-label {
    color: rgba(17, 24, 39, .42);
}

.novel-frame-hot-rank-chapter {
    color: #d05727;
    text-decoration: none;
    transition: color .15s ease;
}

.novel-frame-hot-rank-chapter:hover {
    color: #b54614;
    text-decoration: none;
}

/* 移动端隐藏整模块（桌面独占，移动端空间让给 mobile-bar / 内容） */
@media (max-width: 640px) {
    .novel-frame-hot-rank {
        display: none;
    }
}

/* 暗色 */
body.dark-theme .novel-frame-hot-rank {
    background: rgba(255, 255, 255, .03);
    box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
}

body.dark-theme .novel-frame-hot-rank-head {
    border-bottom-color: rgba(255, 255, 255, .08);
}

body.dark-theme .novel-frame-hot-rank-title {
    color: rgba(255, 255, 255, .92);
}

body.dark-theme .novel-frame-hot-rank-more {
    border-color: rgba(255, 255, 255, .14);
    color: rgba(255, 255, 255, .65);
}

body.dark-theme .novel-frame-hot-rank-more:hover {
    color: #5ea8ff;
    border-color: rgba(94, 168, 255, .35);
    background: rgba(94, 168, 255, .08);
}

body.dark-theme .novel-frame-hot-rank-num {
    color: rgba(255, 255, 255, .38);
}

body.dark-theme .novel-frame-hot-rank-num.is-top {
    color: #fbbf24;
}

body.dark-theme .novel-frame-hot-rank-title-mini {
    color: rgba(255, 255, 255, .85);
}

body.dark-theme .novel-frame-hot-rank-title-mini:hover {
    color: #5ea8ff;
}

body.dark-theme .novel-frame-hot-rank-author {
    color: rgba(255, 255, 255, .42);
}

body.dark-theme .novel-frame-hot-rank-normal:hover {
    background: rgba(94, 168, 255, .06);
}

body.dark-theme .novel-frame-hot-rank-thumb {
    background: rgba(255, 255, 255, .06);
}

body.dark-theme .novel-frame-hot-rank-thumb-placeholder {
    color: rgba(255, 255, 255, .45);
}

body.dark-theme .novel-frame-hot-rank-num-block {
    background: rgba(255, 255, 255, .2);
}

body.dark-theme .novel-frame-hot-rank-title-large {
    color: rgba(255, 255, 255, .95);
}

body.dark-theme .novel-frame-hot-rank-title-large:hover {
    color: #5ea8ff;
}

body.dark-theme .novel-frame-hot-rank-detail-author {
    color: rgba(94, 168, 255, .75);
}

body.dark-theme .novel-frame-hot-rank-detail-excerpt,
body.dark-theme .novel-frame-hot-rank-detail-update {
    color: rgba(255, 255, 255, .55);
}

body.dark-theme .novel-frame-hot-rank-update-label {
    color: rgba(255, 255, 255, .4);
}

body.dark-theme .novel-frame-hot-rank-chapter {
    color: #f97316;
}

body.dark-theme .novel-frame-hot-rank-chapter:hover {
    color: #fb923c;
}
