/*自定义样式*/

/* 移动端自适应换行导航 */
.mobile-nav-wrap {
	flex: 1;
	min-width: 0;
}
.mobile-nav-scroll {
	width: 100%;
}
.mobile-nav-scroll .navbar-nav {
	flex-wrap: wrap !important;
}
.mobile-nav-scroll .nav-item {
	white-space: nowrap;
}
.mobile-nav-scroll .nav-link {
	padding: 0.35rem 0.55rem;
	font-size: 0.85rem;
	color: #333;
}
.mobile-nav-scroll .nav-item.active-mobile .nav-link {
	color: #007bff;
	font-weight: 600;
}

/* ============================================================
   现代化详情页样式 (products_show / article_show)
   ============================================================ */

/* 页面背景微调 */
body.nzcms {
    background: #f3f4f8;
}

/* 面包屑简化 */
.ms-breadcrumb {
    background: transparent !important;
    box-shadow: none !important;
    padding: 0.5rem 0;
    margin-bottom: 0;
    font-size: 0.82rem;
    border-radius: 0;
}
.ms-breadcrumb .breadcrumb-item a {
    color: #8b95a5;
}
.ms-breadcrumb .breadcrumb-item a:hover {
    color: #667eea;
}
.ms-breadcrumb .breadcrumb-item.active {
    color: #c0c6cf;
}
.ms-breadcrumb-item + .breadcrumb-item::before {
    color: #c0c6cf;
}

/* 标题区 */
.ms-title-section {
    padding: 1.5rem 0 1rem;
}
.ms-title-section h1 {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.5;
    color: #1a1a2e;
    margin-bottom: 0;
    letter-spacing: 0.01em;
}

/* 元信息药丸条 */
.ms-meta-pills {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    padding: 0;
    margin: 0;
}
.ms-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.3rem 0.7rem;
    background: #f3f1ff;
    border: 1px solid #e8e4ff;
    border-radius: 20px;
    font-size: 0.78rem;
    color: #5a6577;
    line-height: 1.3;
    white-space: nowrap;
}
.ms-pill i {
    font-size: 0.78rem;
    color: #667eea;
    opacity: 0.75;
}
.ms-pill a {
    color: #667eea;
    text-decoration: none;
}
.ms-pill a:hover {
    text-decoration: underline;
}

/* 提示框 */
.ms-tip-box {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    padding: 0.6rem 0.85rem;
    margin: 0.75rem 0 0;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    font-size: 0.78rem;
    color: #0369a1;
    line-height: 1.5;
}
.ms-tip-box i {
    font-size: 0.88rem;
    margin-top: 0.1rem;
    flex-shrink: 0;
    color: #0ea5e9;
}

/* 资源信息卡片 */
.ms-resource-card {
    background: #fff;
    border-radius: 14px;
    padding: 1.25rem;
    margin: 0.5rem 0 1.25rem;
    border: 1px solid #eef0f5;
    box-shadow: 0 2px 12px rgba(0,0,0,0.03);
}
.ms-cover-wrap {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.07);
    background: #f8f9fc;
}
.ms-cover-wrap img {
    width: 100%;
    display: block;
    transition: transform 0.35s ease;
}
.ms-cover-wrap:hover img {
    transform: scale(1.03);
}

/* 价格 */
.ms-price-row {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.ms-price {
    font-size: 2rem;
    font-weight: 800;
    color: #f97316;
    line-height: 1;
}
.ms-price.free {
    color: #10b981;
}
.ms-price-old {
    font-size: 0.95rem;
    color: #b0b8c5;
    text-decoration: line-through;
}
.ms-price-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, #f97316, #ef4444);
    border-radius: 6px;
    margin-left: 0.25rem;
}

/* 下载按钮 */
.ms-btn-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1.75rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 10px;
    border: none;
    color: #fff;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 4px 14px rgba(102,126,234,0.3);
    transition: all 0.25s ease;
    text-decoration: none;
    cursor: pointer;
}
.ms-btn-download:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102,126,234,0.4);
    color: #fff;
    text-decoration: none;
}
.ms-btn-download.btn-lg {
    padding: 0.8rem 2rem;
    font-size: 1rem;
}
.ms-btn-download.btn-block {
    width: 100%;
}
.ms-btn-download.btn-outline {
    background: #fff;
    color: #667eea;
    border: 1.5px solid #667eea;
    box-shadow: none;
}
.ms-btn-download.btn-outline:hover {
    background: #667eea;
    color: #fff;
}
.ms-btn-download.btn-success-gradient {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    box-shadow: 0 4px 14px rgba(16,185,129,0.3);
}
.ms-btn-download.btn-warning-gradient {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    box-shadow: 0 4px 14px rgba(245,158,11,0.3);
}
.ms-btn-download.btn-primary-gradient {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    box-shadow: 0 4px 14px rgba(79,172,254,0.3);
}

/* 信息网格 */
.ms-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem 1.25rem;
    margin: 1rem 0;
}
.ms-info-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.84rem;
    color: #5a6577;
    padding: 0.35rem 0;
}
.ms-info-item .ms-info-icon {
    width: 28px;
    height: 28px;
    border-radius: 7px;
    background: #f0f2f8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.ms-info-item .ms-info-icon i {
    font-size: 0.82rem;
    color: #8b95a5;
}
.ms-info-item .ms-info-label {
    color: #a0aab8;
    margin-right: 0.15rem;
}

/* 标签 - pill 样式 */
.ms-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 1rem 0;
}
.ms-tags a {
    display: inline-block;
    padding: 0.28rem 0.85rem;
    font-size: 0.78rem;
    color: #5a6577;
    background: #f0f2f8;
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}
.ms-tags a:hover {
    background: #f0edff;
    color: #667eea;
    border-color: #d8d2ff;
}

/* 现代卡片容器 */
.ms-card {
    background: #fff;
    border-radius: 14px;
    padding: 1.5rem;
    margin-bottom: 1.25rem;
    border: 1px solid #eef0f5;
    box-shadow: 0 1px 4px rgba(0,0,0,0.03);
}

/* 内容区排版 */
.ms-content {
    font-size: 0.98rem;
    line-height: 1.85;
    color: #374151;
    word-break: break-word;
}
.ms-content p {
    margin-bottom: 1.15rem;
}
.ms-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 0.75rem 0;
}
.ms-content h2, .ms-content h3, .ms-content h4 {
    color: #1a1a2e;
    font-weight: 700;
    margin: 1.5rem 0 0.75rem;
}
.ms-content a {
    color: #667eea;
    text-decoration: underline;
    text-decoration-color: rgba(102,126,234,0.3);
    text-underline-offset: 2px;
}
.ms-content a:hover {
    text-decoration-color: #667eea;
}
.ms-content blockquote {
    border-left: 3px solid #667eea;
    background: #f8f7ff;
    padding: 1rem 1.25rem;
    border-radius: 0 10px 10px 0;
    margin: 1.25rem 0;
    color: #5a6577;
}
.ms-content pre, .ms-content code {
    border-radius: 8px;
}

/* 上下篇导航 */
.ms-pn-nav {
    display: flex;
    gap: 1rem;
}
.ms-pn-link {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.85rem 1rem;
    background: #fafbfd;
    border-radius: 12px;
    border: 1px solid #eef0f5;
    text-decoration: none;
    transition: all 0.2s ease;
    overflow: hidden;
}
.ms-pn-link:hover {
    border-color: #667eea;
    background: #f8f7ff;
    text-decoration: none;
}
.ms-pn-link img {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}
.ms-pn-link .ms-pn-info {
    min-width: 0;
    flex: 1;
}
.ms-pn-link .ms-pn-label {
    font-size: 0.72rem;
    color: #a0aab8;
    margin-bottom: 0.2rem;
    font-weight: 500;
}
.ms-pn-link .ms-pn-title {
    font-size: 0.84rem;
    color: #374151;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.ms-pn-link.is-next {
    text-align: right;
    flex-direction: row-reverse;
}

/* 分享按钮组 */
.ms-share-bar {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    padding: 1rem 0 0;
}
.ms-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.9rem;
    font-size: 0.78rem;
    border-radius: 8px;
    border: 1px solid #e0e4ea;
    background: #fff;
    color: #5a6577;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}
.ms-share-btn:hover {
    border-color: #667eea;
    color: #667eea;
    background: #f8f7ff;
}

/* Section 标题 */
.ms-section-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.ms-section-title .ms-accent {
    width: 4px;
    height: 18px;
    border-radius: 2px;
    background: linear-gradient(180deg, #667eea, #764ba2);
    flex-shrink: 0;
}
.ms-section-title .ms-count {
    font-size: 0.8rem;
    font-weight: 400;
    color: #a0aab8;
    margin-left: 0.25rem;
}

/* 推荐网格 */
.ms-related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}
.ms-related-card {
    border-radius: 12px;
    overflow: hidden;
    background: #fafbfd;
    border: 1px solid #eef0f5;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
}
.ms-related-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.07);
    text-decoration: none;
    border-color: transparent;
}
.ms-related-card .ms-rel-img {
    position: relative;
    padding-top: 62%;
    overflow: hidden;
    background: #f0f2f8;
}
.ms-related-card .ms-rel-img img {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}
.ms-related-card:hover .ms-rel-img img {
    transform: scale(1.06);
}
.ms-related-card .ms-rel-title {
    padding: 0.7rem 0.75rem;
    font-size: 0.82rem;
    color: #374151;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
    font-weight: 500;
}

/* 评论区 */
.ms-comments .media {
    padding: 1.15rem 0;
    border-bottom: 1px solid #f0f2f5;
}
.ms-comments .media:last-child {
    border-bottom: none;
}
.ms-comments .media img {
    border-radius: 50%;
}
.ms-comments .media .media-body h6 {
    font-size: 0.88rem;
    font-weight: 600;
    color: #374151;
}
.ms-comments .media .media-body p {
    font-size: 0.9rem;
    color: #4b5563;
    line-height: 1.6;
}
.ms-comments .reply-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: #667eea;
    background: #f0edff;
    border-radius: 5px;
    margin-right: 0.5rem;
}

/* 侧边栏现代化 */
.ms-sidebar-card {
    background: #fff;
    border-radius: 14px;
    padding: 1.25rem;
    margin-bottom: 1.25rem;
    border: 1px solid #eef0f5;
    box-shadow: 0 1px 4px rgba(0,0,0,0.03);
}
.ms-sidebar-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #eef0f5;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.ms-sidebar-title .ms-accent {
    width: 4px;
    height: 16px;
    border-radius: 2px;
    background: linear-gradient(180deg, #667eea, #764ba2);
    flex-shrink: 0;
}
.ms-sidebar-title a {
    margin-left: auto;
    font-size: 0.78rem;
    font-weight: 400;
    color: #a0aab8;
}
.ms-sidebar-title a:hover {
    color: #667eea;
}

/* 作者卡片 */
.ms-author-card {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eef0f5;
    margin-bottom: 1rem;
}
.ms-author-card img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}
.ms-author-card .ms-author-name {
    font-weight: 600;
    color: #1a1a2e;
    font-size: 0.9rem;
}
.ms-author-card .ms-author-actions {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.35rem;
}
.ms-author-card .ms-author-actions a {
    font-size: 0.72rem;
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    background: #f0f2f8;
    color: #5a6577;
    text-decoration: none;
    transition: all 0.2s;
}
.ms-author-card .ms-author-actions a:hover {
    background: #667eea;
    color: #fff;
}

/* 侧边栏列表 */
.ms-sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.ms-sidebar-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid #f5f7fa;
}
.ms-sidebar-list li:last-child {
    border-bottom: none;
}
.ms-sidebar-list li img {
    width: 52px;
    height: 52px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}
.ms-sidebar-list li a {
    font-size: 0.82rem;
    color: #374151;
    text-decoration: none;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.ms-sidebar-list li a:hover {
    color: #667eea;
}
.ms-sidebar-list .ms-list-meta {
    font-size: 0.72rem;
    color: #a0aab8;
    margin-top: 0.15rem;
    display: flex;
    gap: 0.75rem;
}

/* 简单链接列表（侧边栏文章列表） */
.ms-link-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.ms-link-list li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f5f7fa;
}
.ms-link-list li:last-child {
    border-bottom: none;
}
.ms-link-list li a {
    font-size: 0.84rem;
    color: #374151;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: color 0.2s;
}
.ms-link-list li a::before {
    content: '';
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #d0d5dd;
    flex-shrink: 0;
}
.ms-link-list li a:hover {
    color: #667eea;
}
.ms-link-list li a:hover::before {
    background: #667eea;
}

/* 隐藏原始 article_show 的旧样式元素 */
.ms-hide-original .article_show,
.ms-hide-original .card.shadow-sm,
.ms-hide-original .card.mb-md-4 {
    display: none;
}

/* FAQ 现代化 */
.ms-faq-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.ms-faq-list li {
    border-bottom: 1px solid #f0f2f5;
}
.ms-faq-list li:last-child {
    border-bottom: none;
}
.ms-faq-list li a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 0;
    font-size: 0.88rem;
    color: #374151;
    text-decoration: none;
    transition: color 0.2s;
}
.ms-faq-list li a:hover {
    color: #667eea;
}
.ms-faq-list li a i {
    color: #a0aab8;
    font-size: 0.8rem;
}

/* ============================================================
   移动端适配
   ============================================================ */
@media (max-width: 767.98px) {
    .ms-title-section {
        padding: 1rem 0.75rem 0.6rem;
    }
    .ms-title-section h1 {
        font-size: 1.3rem;
        margin-bottom: 0;
        line-height: 1.5;
    }
    .ms-meta-pills {
        gap: 0.35rem;
    }
    .ms-pill {
        padding: 0.25rem 0.55rem;
        font-size: 0.72rem;
    }
    .ms-card {
        padding: 1.15rem;
        margin-left: 0.75rem;
        margin-right: 0.75rem;
        border-radius: 12px;
    }
    .ms-resource-card {
        padding: 1rem 0.75rem;
        margin: 0.25rem 0.75rem 1rem;
        border-radius: 12px;
    }
    .ms-related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.65rem;
    }
    .ms-pn-nav {
        flex-direction: column;
        gap: 0.65rem;
    }
    /* 信息网格：手机端保持2列紧凑布局 */
    .ms-info-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0.4rem 0.8rem;
        margin: 0.75rem 0;
    }
    .ms-info-item {
        font-size: 0.76rem;
        padding: 0.25rem 0;
        gap: 0.3rem;
    }
    .ms-info-item .ms-info-icon {
        width: 24px;
        height: 24px;
        border-radius: 6px;
    }
    .ms-info-item .ms-info-icon i {
        font-size: 0.72rem;
    }
    .ms-info-item .ms-info-label {
        font-size: 0.72rem;
    }
    /* 价格区紧凑化 */
    .ms-price-row {
        margin-bottom: 0.75rem;
    }
    .ms-price {
        font-size: 1.6rem;
    }
    .ms-pn-link img {
        width: 48px;
        height: 48px;
    }
    /* 封面图下方间距 */
    .ms-cover-wrap {
        margin-bottom: 0.75rem;
    }
    /* 下载按钮紧凑化 */
    .ms-btn-download {
        padding: 0.6rem 1.25rem;
        font-size: 0.88rem;
    }
    .ms-btn-download.btn-lg {
        padding: 0.65rem 1.5rem;
        font-size: 0.92rem;
    }
    /* 提示框紧凑化 */
    .ms-tip-box {
        padding: 0.5rem 0.7rem;
        margin: 0.5rem 0 0;
        font-size: 0.72rem;
    }
}

/* ============================================================
   会员中心宫格样式
   ============================================================ */
.ms-member-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.6rem;
    padding: 0.6rem 0.75rem;
    background: #fff;
    margin: 0;
}
.ms-member-grid.ms-grid-nav {
    border-bottom: 1px solid #f0f0f0;
    border-radius: 0;
    box-shadow: none;
}
.ms-grid-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #374151;
    transition: all 0.2s;
    padding: 0.3rem 0;
    border-radius: 8px;
}
.ms-grid-item:active {
    transform: scale(0.95);
}
.ms-grid-item.ms-grid-active {
    background: rgba(102, 126, 234, 0.08);
}
.ms-grid-item.ms-grid-active span {
    color: #667eea;
    font-weight: 600;
}
.ms-grid-icon {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.3rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.ms-grid-icon i {
    font-size: 1.2rem;
    color: #fff;
}
.ms-grid-item span {
    font-size: 0.7rem;
    color: #4b5563;
    text-align: center;
    line-height: 1.2;
}
