/* ============================================================================
   newportal 主题 - 海报信息图风格
   核心：固定顶吸导航 + 固定底部快捷栏 + 友情链接 + 后台功能宣传
   设计语言：大号装饰数字、渐变色块、几何线条、紧凑信息列表
   ============================================================================ */

/* ============ 设计令牌 ============ */
:root {
    --np-primary: #059669;
    --np-primary-dark: #047857;
    --np-primary-light: #34d399;
    --np-primary-bg: #ecfdf5;
    --np-accent: #fbbf24;
    --np-bg: #ffffff;
    --np-bg-alt: #f8fafc;
    --np-bg-dark: #0f172a;
    --np-bg-deeper: #020617;
    --np-text: #1e293b;
    --np-text-2: #475569;
    --np-text-3: #94a3b8;
    --np-border: #e2e8f0;
    --np-radius: 12px;
    --np-radius-lg: 20px;
    --np-shadow: 0 4px 12px rgba(5, 150, 105, 0.08);
    --np-shadow-lg: 0 20px 40px rgba(5, 150, 105, 0.12);
    --np-nav-h: 64px;
    --np-footer-h: 120px;
}

/* ============ 基础重置 ============ */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    color: var(--np-text);
    background: var(--np-bg);
    line-height: 1.6;
    overflow-x: hidden;
    padding-top: var(--np-nav-h);
    padding-bottom: var(--np-footer-h);
}
a { text-decoration: none; color: inherit; }
::selection { background: var(--np-primary); color: #fff; }
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: var(--np-primary-light); border-radius: 4px; }

/* ============ 固定顶吸导航 ============ */
.np-nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--np-nav-h);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(5, 150, 105, 0.08);
    z-index: 1000;
    transition: box-shadow 0.3s, background 0.3s;
}
.np-nav.is-scrolled {
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 0.96);
}
.np-nav-inner {
    max-width: 1280px;
    margin: 0 auto;
    height: 100%;
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 32px;
}
.np-nav-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 20px;
    font-weight: 800;
    color: var(--np-text);
    flex-shrink: 0;
}
.np-nav-logo img { height: 32px; max-width: 160px; object-fit: contain; }
.np-nav-logo-mark {
    width: 32px; height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--np-primary), var(--np-primary-light));
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 16px;
}
.np-nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    overflow: visible;
}
.np-nav-item {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 14px;
    font-size: 14px;
    font-weight: 500;
    color: var(--np-text-2);
    border-radius: 8px;
    transition: all 0.2s;
    white-space: nowrap;
}
.np-nav-item:hover { color: var(--np-primary); background: var(--np-primary-bg); }
.np-nav-item.np-active { color: var(--np-primary); }
.np-nav-item.np-active::after {
    content: '';
    position: absolute;
    bottom: -1px; left: 50%;
    transform: translateX(-50%);
    width: 24px; height: 2px;
    background: var(--np-primary);
    border-radius: 1px;
}
.np-nav-arrow { font-size: 10px; opacity: 0.6; transition: transform 0.2s; }
.np-nav-has-dropdown { position: relative; }
.np-nav-has-dropdown:hover .np-nav-arrow { transform: rotate(180deg); }
.np-nav-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 200px;
    background: #fff;
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: all 0.2s;
}
.np-nav-has-dropdown:hover .np-nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.np-nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    font-size: 13px;
    color: var(--np-text-2);
    border-radius: 6px;
    transition: all 0.15s;
}
.np-nav-dropdown-item:hover { color: var(--np-primary); background: var(--np-primary-bg); }
.np-nav-dropdown-item i { width: 16px; opacity: 0.6; }
.np-nav-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.np-nav-search {
    width: 36px; height: 36px;
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: var(--np-text-2);
    background: var(--np-bg-alt);
    border: none; cursor: pointer;
    transition: all 0.2s;
}
.np-nav-search:hover { background: var(--np-primary-bg); color: var(--np-primary); }
.np-nav-toggle {
    display: none;
    width: 36px; height: 36px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    background: var(--np-bg-alt);
    border: none;
    border-radius: 8px;
}
.np-nav-toggle span { width: 18px; height: 2px; background: var(--np-text); border-radius: 1px; transition: all 0.2s; }

/* 移动端菜单 */
.np-mobile-menu {
    position: fixed;
    top: var(--np-nav-h);
    left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--np-border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
    z-index: 999;
}
.np-mobile-menu.is-open { max-height: calc(100vh - var(--np-nav-h)); overflow-y: auto; }
.np-mobile-menu a {
    display: block;
    padding: 14px 24px;
    border-bottom: 1px solid var(--np-bg-alt);
    color: var(--np-text);
    font-size: 15px;
}
.np-mobile-menu a:hover { background: var(--np-primary-bg); color: var(--np-primary); }

/* ============ 通用容器 ============ */
.np-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ============ 区域1：封面（Hero 海报） ============ */
.np-cover {
    position: relative;
    min-height: 540px;
    background: linear-gradient(135deg, #064e3b 0%, #065f46 40%, #047857 80%, #059669 100%);
    overflow: hidden;
    color: #fff;
    display: flex;
    align-items: center;
    padding: 80px 0;
}
.np-cover::before {
    content: '';
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 48px 48px;
}
.np-cover-glow {
    position: absolute;
    width: 500px; height: 500px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.35;
}
.np-cover-glow-1 { top: -200px; left: -100px; background: var(--np-primary-light); animation: npFloat1 8s ease-in-out infinite; }
.np-cover-glow-2 { bottom: -200px; right: -100px; background: var(--np-accent); animation: npFloat2 10s ease-in-out infinite; }
@keyframes npFloat1 { 0%, 100% { transform: translate(0,0); } 50% { transform: translate(40px, 30px); } }
@keyframes npFloat2 { 0%, 100% { transform: translate(0,0); } 50% { transform: translate(-30px, -40px); } }

.np-cover-inner { position: relative; z-index: 2; width: 100%; }
.np-cover-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 100px;
    color: #a7f3d0;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 20px;
    backdrop-filter: blur(10px);
}
.np-cover-title {
    font-size: 64px;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -2px;
    margin-bottom: 16px;
}
.np-cover-title .np-accent {
    background: linear-gradient(135deg, #6ee7b7, var(--np-primary-light), var(--np-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.np-cover-subtitle {
    font-size: 18px;
    color: rgba(255,255,255,0.85);
    line-height: 1.7;
    max-width: 720px;
    margin-bottom: 32px;
}
.np-cover-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 48px; }
.np-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
}
.np-btn-primary { background: #fff; color: var(--np-primary); }
.np-btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(0,0,0,0.2); }
.np-btn-ghost {
    background: rgba(255,255,255,0.1);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(10px);
}
.np-btn-ghost:hover { background: rgba(255,255,255,0.2); transform: translateY(-2px); }

.np-cover-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 32px;
    max-width: 720px;
}
.np-cover-stat { padding: 0 16px; border-right: 1px solid rgba(255,255,255,0.1); }
.np-cover-stat:last-child { border-right: none; }
.np-cover-stat-num {
    font-size: 32px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    margin-bottom: 6px;
}
.np-cover-stat-label {
    font-size: 12px;
    color: rgba(255,255,255,0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============ 通用 section 标题 ============ */
.np-section { padding: 80px 0; }
.np-section-num {
    font-size: 100px;
    font-weight: 900;
    line-height: 1;
    color: var(--np-primary-bg);
    letter-spacing: -4px;
    margin-bottom: 8px;
    display: block;
}
.np-section-tag {
    display: inline-block;
    padding: 4px 12px;
    background: var(--np-primary-bg);
    color: var(--np-primary);
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 12px;
}
.np-section-title {
    font-size: 40px;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1.2;
    color: var(--np-text);
    margin-bottom: 12px;
}
.np-section-desc {
    font-size: 16px;
    color: var(--np-text-2);
    max-width: 640px;
    line-height: 1.7;
}
.np-section-head-center { text-align: center; }
.np-section-head-center .np-section-desc { margin-left: auto; margin-right: auto; }

/* ============ 区域2：核心能力 ============ */
.np-capabilities {
    background: var(--np-bg);
    border-bottom: 1px solid var(--np-border);
}
.np-cap-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-top: 48px;
}
.np-cap-card {
    position: relative;
    background: #fff;
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius);
    padding: 24px;
    transition: all 0.3s;
    overflow: hidden;
}
.np-cap-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--np-primary), var(--np-primary-light));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s;
}
.np-cap-card:hover { border-color: var(--np-primary-light); box-shadow: var(--np-shadow); transform: translateY(-2px); }
.np-cap-card:hover::before { transform: scaleX(1); }
.np-cap-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    background: var(--np-primary-bg);
    color: var(--np-primary);
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    margin-bottom: 14px;
}
.np-cap-name { font-size: 15px; font-weight: 700; color: var(--np-text); margin-bottom: 4px; }
.np-cap-desc { font-size: 13px; color: var(--np-text-2); line-height: 1.6; }

/* ============ 区域3：后台模块矩阵 ============ */
.np-modules {
    background: var(--np-bg-alt);
    border-bottom: 1px solid var(--np-border);
}
.np-module-list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--np-border);
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius);
    overflow: hidden;
    margin-top: 48px;
}
.np-module-item {
    background: #fff;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: all 0.2s;
    cursor: pointer;
    position: relative;
}
.np-module-item:hover { background: var(--np-primary-bg); }
.np-module-item::after {
    content: '\f061';
    font-family: 'Font Awesome 5 Free', 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 16px; right: 16px;
    color: var(--np-text-3);
    opacity: 0;
    transition: all 0.2s;
}
.np-module-item:hover::after { opacity: 1; right: 12px; color: var(--np-primary); }
.np-module-num {
    font-size: 11px;
    font-weight: 700;
    color: var(--np-text-3);
    letter-spacing: 1px;
}
.np-module-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--np-text);
    display: flex;
    align-items: center;
    gap: 8px;
}
.np-module-name i { color: var(--np-primary); font-size: 14px; }
.np-module-desc { font-size: 12px; color: var(--np-text-2); line-height: 1.5; }

/* ============ 区域4：作者信息 ============ */
.np-author {
    background: var(--np-bg-dark);
    color: #fff;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}
.np-author::before {
    content: '';
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 48px 48px;
}
.np-author-inner { position: relative; z-index: 2; display: flex; gap: 48px; align-items: center; }
.np-author-avatar-wrap { flex-shrink: 0; position: relative; }
.np-author-avatar {
    width: 160px; height: 160px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--np-primary), var(--np-primary-light));
    display: flex; align-items: center; justify-content: center;
    font-size: 64px; color: #fff;
    position: relative;
    box-shadow: 0 20px 50px rgba(5, 150, 105, 0.4);
}
.np-author-avatar::before {
    content: '';
    position: absolute; inset: -8px;
    border-radius: 50%;
    border: 2px dashed var(--np-primary-light);
    opacity: 0.5;
    animation: npSpin 20s linear infinite;
}
@keyframes npSpin { to { transform: rotate(360deg); } }
.np-author-info { flex: 1; }
.np-author-info h3 {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #fff, #a7f3d0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.np-author-role {
    font-size: 14px;
    color: var(--np-primary-light);
    font-weight: 600;
    margin-bottom: 16px;
}
.np-author-bio {
    font-size: 15px;
    color: rgba(255,255,255,0.75);
    line-height: 1.8;
    margin-bottom: 20px;
}
.np-author-contacts { display: flex; flex-wrap: wrap; gap: 12px; }
.np-author-contact {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    color: rgba(255,255,255,0.85);
    font-size: 13px;
    transition: all 0.2s;
}
.np-author-contact:hover { background: rgba(5, 150, 105, 0.2); border-color: var(--np-primary-light); color: #fff; }

/* ============ 区域5：栏目导航（数据驱动） ============ */
.np-categories {
    background: #fff;
    border-bottom: 1px solid var(--np-border);
}
.np-cat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 48px;
}
.np-cat-card {
    position: relative;
    display: block;
    background: #fff;
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius);
    padding: 24px;
    overflow: hidden;
    transition: all 0.3s;
}
.np-cat-card:hover { border-color: var(--np-primary); box-shadow: var(--np-shadow-lg); transform: translateY(-4px); }
.np-cat-card-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 12px; }
.np-cat-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    background: var(--np-primary-bg);
    color: var(--np-primary);
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.np-cat-type {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--np-bg-alt);
    color: var(--np-text-2);
    font-weight: 600;
}
.np-cat-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--np-text);
    margin-bottom: 6px;
}
.np-cat-desc {
    font-size: 13px;
    color: var(--np-text-2);
    line-height: 1.6;
    margin-bottom: 12px;
    min-height: 40px;
}
.np-cat-arrow {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: var(--np-primary);
    font-weight: 600;
}
.np-cat-arrow i { transition: transform 0.2s; }
.np-cat-card:hover .np-cat-arrow i { transform: translateX(4px); }

/* ============ 区域6：内容列表 ============ */
.np-content-list {
    background: var(--np-bg-alt);
    border-bottom: 1px solid var(--np-border);
}
.np-list-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-top: 48px;
}
.np-article-list { display: flex; flex-direction: column; gap: 12px; }
.np-article-item {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: #fff;
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius);
    transition: all 0.2s;
}
.np-article-item:hover { border-color: var(--np-primary-light); box-shadow: var(--np-shadow); transform: translateX(4px); }
.np-article-cover {
    width: 140px; height: 100px;
    border-radius: 8px;
    background: var(--np-primary-bg);
    flex-shrink: 0;
    overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    color: var(--np-primary);
    font-size: 28px;
}
.np-article-cover img { width: 100%; height: 100%; object-fit: cover; }
.np-article-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.np-article-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--np-text);
    margin-bottom: 6px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}
.np-article-excerpt {
    font-size: 13px;
    color: var(--np-text-2);
    line-height: 1.5;
    margin-bottom: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.np-article-meta {
    display: flex;
    gap: 12px;
    font-size: 12px;
    color: var(--np-text-3);
    margin-top: auto;
}
.np-article-meta span { display: inline-flex; align-items: center; gap: 4px; }
.np-article-top {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 4px;
    background: var(--np-primary);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    margin-right: 6px;
    vertical-align: middle;
}
.np-sidebar { display: flex; flex-direction: column; gap: 16px; }
.np-side-card {
    background: #fff;
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius);
    padding: 20px;
}
.np-side-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--np-text);
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--np-border);
    display: flex; align-items: center; gap: 6px;
}
.np-side-title i { color: var(--np-primary); }
.np-rank-list { list-style: none; padding: 0; }
.np-rank-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 13px;
    color: var(--np-text-2);
    border-bottom: 1px solid var(--np-bg-alt);
}
.np-rank-item:last-child { border-bottom: none; }
.np-rank-num {
    width: 20px; height: 20px;
    border-radius: 4px;
    background: var(--np-bg-alt);
    color: var(--np-text-3);
    display: flex; align-items: center; justify-content: center;
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}
.np-rank-item:nth-child(1) .np-rank-num { background: var(--np-accent); color: #fff; }
.np-rank-item:nth-child(2) .np-rank-num { background: var(--np-primary-light); color: #fff; }
.np-rank-item:nth-child(3) .np-rank-num { background: var(--np-primary); color: #fff; }
.np-rank-item a { color: var(--np-text-2); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-rank-item a:hover { color: var(--np-primary); }

/* ============ 区域7：技术栈 ============ */
.np-tech {
    background: var(--np-bg-dark);
    color: #fff;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}
.np-tech::before {
    content: '';
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 48px 48px;
}
.np-tech .np-section-num { color: rgba(5, 150, 105, 0.3); }
.np-tech .np-section-title { color: #fff; }
.np-tech .np-section-desc { color: rgba(255,255,255,0.6); }
.np-tech-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-top: 48px;
    position: relative; z-index: 2;
}
.np-tech-item {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--np-radius);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s;
}
.np-tech-item:hover { background: rgba(5, 150, 105, 0.1); border-color: rgba(5, 150, 105, 0.4); transform: translateY(-2px); }
.np-tech-icon {
    width: 40px; height: 40px;
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}
.np-tech-name { font-size: 14px; font-weight: 700; color: #fff; }
.np-tech-ver { font-size: 11px; color: rgba(255,255,255,0.5); }

/* ============ 区域8：双端架构 ============ */
.np-endpoints {
    background: var(--np-bg-alt);
    border-bottom: 1px solid var(--np-border);
}
.np-endpoint-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-top: 48px;
}
.np-endpoint-card {
    background: #fff;
    border: 1px solid var(--np-border);
    border-radius: var(--np-radius-lg);
    padding: 32px;
    position: relative;
    overflow: hidden;
}
.np-endpoint-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
}
.np-endpoint-card.np-endpoint-control::before { background: linear-gradient(90deg, var(--np-primary), var(--np-primary-light)); }
.np-endpoint-card.np-endpoint-pure::before { background: linear-gradient(90deg, #3b82f6, #60a5fa); }
.np-endpoint-header { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.np-endpoint-icon {
    width: 56px; height: 56px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px;
    color: #fff;
    flex-shrink: 0;
}
.np-endpoint-control .np-endpoint-icon { background: linear-gradient(135deg, var(--np-primary), var(--np-primary-light)); }
.np-endpoint-pure .np-endpoint-icon { background: linear-gradient(135deg, #3b82f6, #60a5fa); }
.np-endpoint-title { font-size: 20px; font-weight: 800; color: var(--np-text); margin-bottom: 4px; }
.np-endpoint-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
}
.np-endpoint-control .np-endpoint-tag { background: var(--np-primary-bg); color: var(--np-primary); }
.np-endpoint-pure .np-endpoint-tag { background: #dbeafe; color: #2563eb; }
.np-endpoint-desc { font-size: 13px; color: var(--np-text-2); margin-bottom: 16px; }
.np-endpoint-list { list-style: none; padding: 0; }
.np-endpoint-list li {
    display: flex; align-items: center; gap: 8px;
    padding: 6px 0;
    font-size: 13px;
    color: var(--np-text-2);
}
.np-endpoint-list li i { color: var(--np-primary); font-size: 11px; }
.np-endpoint-pure .np-endpoint-list li i { color: #3b82f6; }

/* ============ 区域9：CTA ============ */
.np-cta {
    background: linear-gradient(135deg, #064e3b 0%, #047857 100%);
    color: #fff;
    padding: 60px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.np-cta::before {
    content: '';
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 48px 48px;
}
.np-cta-inner { position: relative; z-index: 2; }
.np-cta h2 { font-size: 36px; font-weight: 800; color: #fff; margin-bottom: 12px; }
.np-cta p { font-size: 16px; color: rgba(255,255,255,0.85); margin-bottom: 28px; }
.np-cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ============ 固定底部快捷栏 ============ */
.np-footer {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: #fff;
    border-top: 1px solid var(--np-border);
    box-shadow: 0 -4px 16px rgba(0,0,0,0.04);
    z-index: 999;
}
.np-footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 56px;
    flex-wrap: wrap;
}
.np-footer-brand {
    display: flex; align-items: center; gap: 8px;
    font-size: 14px; font-weight: 700;
    color: var(--np-text);
    flex-shrink: 0;
}
.np-footer-brand i { color: var(--np-primary); }
.np-footer-divider { width: 1px; height: 20px; background: var(--np-border); flex-shrink: 0; }
.np-footer-quick {
    display: flex; align-items: center; gap: 4px;
    flex: 1; overflow-x: auto;
    scrollbar-width: none;
}
.np-footer-quick::-webkit-scrollbar { display: none; }
.np-footer-link {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 6px 12px;
    font-size: 13px;
    color: var(--np-text-2);
    border-radius: 6px;
    white-space: nowrap;
    transition: all 0.2s;
    flex-shrink: 0;
}
.np-footer-link:hover { color: var(--np-primary); background: var(--np-primary-bg); }
.np-footer-link i { font-size: 11px; opacity: 0.6; }
.np-footer-friends {
    display: flex; align-items: center; gap: 6px;
    flex-shrink: 0;
}
.np-footer-friends-label {
    font-size: 12px;
    color: var(--np-text-3);
    font-weight: 600;
    flex-shrink: 0;
}
.np-footer-friends-link {
    font-size: 12px;
    color: var(--np-text-2);
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s;
    white-space: nowrap;
}
.np-footer-friends-link:hover { color: var(--np-primary); background: var(--np-primary-bg); }
.np-footer-friends-more {
    font-size: 12px;
    color: var(--np-primary);
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    white-space: nowrap;
}
.np-footer-copy {
    font-size: 11px;
    color: var(--np-text-3);
    flex-shrink: 0;
}

/* ============ 列表页/详情页通用样式 ============ */
.np-banner {
    background: linear-gradient(135deg, var(--np-primary-bg) 0%, #fff 100%);
    padding: 48px 0;
    border-bottom: 1px solid var(--np-border);
}
.np-banner-title {
    font-size: 32px;
    font-weight: 800;
    color: var(--np-text);
    margin-bottom: 8px;
}
.np-banner-desc {
    font-size: 14px;
    color: var(--np-text-2);
    max-width: 640px;
}
.np-breadcrumb {
    display: flex; align-items: center; gap: 6px;
    font-size: 13px;
    color: var(--np-text-2);
    margin-bottom: 16px;
}
.np-breadcrumb a { color: var(--np-text-2); transition: color 0.2s; }
.np-breadcrumb a:hover { color: var(--np-primary); }
.np-breadcrumb i { font-size: 10px; color: var(--np-text-3); }
.np-breadcrumb span { color: var(--np-text); font-weight: 600; }

.np-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    margin-top: 32px;
    padding: 16px 0;
}
.np-pagination a, .np-pagination span {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 36px; height: 36px;
    padding: 0 12px;
    border-radius: 8px;
    font-size: 13px;
    color: var(--np-text-2);
    background: #fff;
    border: 1px solid var(--np-border);
    transition: all 0.2s;
}
.np-pagination a:hover { color: var(--np-primary); border-color: var(--np-primary); }
.np-pagination .np-current { color: #fff; background: var(--np-primary); border-color: var(--np-primary); }
.np-pagination .np-disabled { color: var(--np-text-3); cursor: not-allowed; }

/* 详情页 */
.np-article-detail { max-width: 860px; margin: 0 auto; padding: 48px 24px; }
.np-article-header { margin-bottom: 24px; padding-bottom: 20px; border-bottom: 1px solid var(--np-border); }
.np-article-h1 {
    font-size: 32px; font-weight: 800;
    color: var(--np-text);
    line-height: 1.3;
    margin-bottom: 16px;
}
.np-article-info {
    display: flex; flex-wrap: wrap; gap: 16px;
    font-size: 13px;
    color: var(--np-text-2);
}
.np-article-info span { display: inline-flex; align-items: center; gap: 4px; }
.np-article-content {
    font-size: 15px;
    line-height: 1.9;
    color: var(--np-text);
}
.np-article-content h1, .np-article-content h2, .np-article-content h3 { margin: 24px 0 12px; font-weight: 700; }
.np-article-content h2 { font-size: 22px; }
.np-article-content h3 { font-size: 18px; }
.np-article-content p { margin-bottom: 16px; }
.np-article-content img { max-width: 100%; border-radius: 8px; }
.np-article-content code { background: var(--np-primary-bg); color: var(--np-primary); padding: 2px 6px; border-radius: 4px; font-size: 13px; }
.np-article-content pre { background: var(--np-bg-dark); color: #e2e8f0; padding: 16px; border-radius: 8px; overflow-x: auto; margin: 16px 0; }
.np-article-content pre code { background: transparent; color: inherit; padding: 0; }
.np-article-content blockquote {
    border-left: 4px solid var(--np-primary);
    background: var(--np-primary-bg);
    padding: 12px 16px;
    margin: 16px 0;
    border-radius: 0 8px 8px 0;
    color: var(--np-text-2);
}

/* ============ 响应式 ============ */
@media (max-width: 1024px) {
    .np-cover-title { font-size: 48px; }
    .np-section-title { font-size: 32px; }
    .np-cap-grid { grid-template-columns: repeat(2, 1fr); }
    .np-module-list { grid-template-columns: repeat(2, 1fr); }
    .np-cat-grid { grid-template-columns: repeat(2, 1fr); }
    .np-list-grid { grid-template-columns: 1fr; }
    .np-tech-grid { grid-template-columns: repeat(2, 1fr); }
    .np-endpoint-grid { grid-template-columns: 1fr; }
    .np-cover-stats { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .np-cover-stat:nth-child(2) { border-right: none; }
    .np-author-inner { flex-direction: column; text-align: center; }
}
@media (max-width: 768px) {
    :root { --np-nav-h: 56px; }
    body { padding-bottom: var(--np-footer-h); }
    .np-cover { min-height: auto; padding: 48px 0; }
    .np-cover-title { font-size: 36px; }
    .np-section { padding: 48px 0; }
    .np-section-title { font-size: 28px; }
    .np-section-num { font-size: 64px; }
    .np-nav-links, .np-nav-actions .np-btn { display: none; }
    .np-nav-toggle { display: flex; }
    .np-cap-grid { grid-template-columns: 1fr; }
    .np-module-list { grid-template-columns: 1fr; }
    .np-cat-grid { grid-template-columns: 1fr; }
    .np-tech-grid { grid-template-columns: 1fr; }
    .np-cover-stats { grid-template-columns: 1fr 1fr; }
    .np-article-item { flex-direction: column; }
    .np-article-cover { width: 100%; height: 160px; }
    .np-footer-inner { padding: 8px 12px; }
    .np-footer-quick { order: 3; flex-basis: 100%; }
    .np-footer-friends { display: none; }
}

/* ============ 入场动画（默认可见，JS 接管后启用） ============ */
.np-fade { opacity: 1; transform: none; transition: opacity 0.6s ease, transform 0.6s ease; }
.np-js-ready .np-fade { opacity: 0; transform: translateY(24px); }
.np-js-ready .np-fade.np-in { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
    .np-js-ready .np-fade { opacity: 1; transform: none; }
}
