/* NavSide Template - 全新侧边导航模板，完全不同的代码结构 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --ns-color-bg: #f5f7fa;
    --ns-color-panel: #ffffff;
    --ns-color-panel-dark: #1e293b;
    --ns-color-text: #1e293b;
    --ns-color-text-muted: #64748b;
    --ns-color-text-light: #94a3b8;
    --ns-color-primary: #3b82f6;
    --ns-color-primary-dark: #2563eb;
    --ns-color-accent: #f59e0b;
    --ns-color-border: #e2e8f0;
    --ns-color-shadow: rgba(0, 0, 0, 0.08);
    --ns-panel-width: 260px;
    --ns-panel-width-collapsed: 72px;
    --ns-transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

body.ns-body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: var(--ns-color-bg);
    color: var(--ns-color-text);
    line-height: 1.6;
    min-height: 100vh;
}

/* 主容器 */
.ns-wrapper {
    display: flex;
    min-height: 100vh;
    position: relative;
}

/* 左侧导航面板 */
.ns-panel {
    width: var(--ns-panel-width);
    background: var(--ns-color-panel-dark);
    color: #ffffff;
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    z-index: 1000;
    transition: var(--ns-transition);
    overflow: hidden;
    box-shadow: 2px 0 12px rgba(0, 0, 0, 0.1);
}

.ns-panel.is-collapsed {
    width: var(--ns-panel-width-collapsed);
}

.ns-panel-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px 0;
}

/* 站点标识 */
.ns-site {
    padding: 0 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
    position: relative;
}

.ns-site-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    transition: var(--ns-transition);
}

.ns-site-link:hover {
    opacity: 0.9;
}

.ns-site-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--ns-color-primary), var(--ns-color-accent));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-weight: 700;
    font-size: 18px;
    color: white;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.ns-site-info {
    flex: 1;
    min-width: 0;
    transition: var(--ns-transition);
}

.ns-panel.is-collapsed .ns-site-info {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.ns-site-name {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ns-site-desc {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ns-panel-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--ns-transition);
}

.ns-panel-toggle:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
}

.ns-panel.is-collapsed .ns-panel-toggle svg {
    transform: rotate(180deg);
}

/* 搜索区域 */
.ns-search-area {
    padding: 0 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

.ns-search-form {
    width: 100%;
}

.ns-search-field {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    transition: var(--ns-transition);
}

.ns-search-field:focus-within {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--ns-color-primary);
}

.ns-search-input {
    flex: 1;
    border: none;
    background: transparent;
    color: white;
    padding: 10px 12px;
    font-size: 13px;
    outline: none;
}

.ns-search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.ns-search-submit {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--ns-color-primary);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--ns-transition);
    flex-shrink: 0;
}

.ns-search-submit:hover {
    background: var(--ns-color-primary-dark);
}

.ns-panel.is-collapsed .ns-search-area {
    padding: 0 12px 20px;
}

.ns-panel.is-collapsed .ns-search-input {
    display: none;
}

.ns-panel.is-collapsed .ns-search-submit {
    width: 100%;
    border-radius: 8px;
}

/* 导航菜单 */
.ns-menu {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0 12px;
}

.ns-menu::-webkit-scrollbar {
    width: 4px;
}

.ns-menu::-webkit-scrollbar-track {
    background: transparent;
}

.ns-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}

.ns-menu-group {
    margin-bottom: 24px;
}

.ns-menu-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.5);
    padding: 0 8px 8px;
    font-weight: 600;
}

.ns-panel.is-collapsed .ns-menu-label {
    display: none;
}

.ns-menu-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ns-menu-item {
    position: relative;
}

.ns-menu-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    border-radius: 8px;
    transition: var(--ns-transition);
    position: relative;
    overflow: hidden;
}

.ns-menu-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--ns-color-primary);
    transform: scaleY(0);
    transition: transform 0.2s;
    border-radius: 0 3px 3px 0;
}

.ns-menu-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: white;
}

.ns-menu-link.is-active {
    background: rgba(59, 130, 246, 0.15);
    color: white;
}

.ns-menu-link.is-active::before {
    transform: scaleY(1);
}

.ns-menu-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 16px;
}

.ns-menu-label-text {
    flex: 1;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ns-panel.is-collapsed .ns-menu-label-text {
    display: none;
}

.ns-menu-badge {
    width: 6px;
    height: 6px;
    background: var(--ns-color-accent);
    border-radius: 50%;
    opacity: 0;
    transition: var(--ns-transition);
}

.ns-menu-link.is-active .ns-menu-badge {
    opacity: 1;
}

/* 面板底部 */
.ns-panel-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: auto;
}

.ns-footer-info {
    text-align: center;
}

.ns-footer-copyright {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 4px;
}

.ns-footer-site {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.ns-panel.is-collapsed .ns-panel-footer {
    padding: 20px 12px;
}

.ns-panel.is-collapsed .ns-footer-info {
    display: none;
}

/* 主内容区域 */
.ns-main {
    flex: 1;
    margin-left: var(--ns-panel-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: var(--ns-transition);
}

.ns-panel.is-collapsed ~ .ns-main {
    margin-left: var(--ns-panel-width-collapsed);
}

/* 顶部栏 */
.ns-header {
    background: var(--ns-color-panel);
    border-bottom: 1px solid var(--ns-color-border);
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px var(--ns-color-shadow);
}

.ns-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.ns-mobile-toggle {
    display: none;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--ns-color-border);
    border-radius: 8px;
    color: var(--ns-color-text);
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: var(--ns-transition);
}

.ns-mobile-toggle:hover {
    background: var(--ns-color-bg);
    border-color: var(--ns-color-primary);
}

.ns-header-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--ns-color-text);
}

.ns-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* 页面内容 */
.ns-page {
    flex: 1;
    padding: 24px;
}

.ns-container {
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    padding: 24px;
}

.ns-container p {
    text-align: center;
    padding: 40px 20px;
    color: var(--ns-color-text-muted);
    font-size: 16px;
}

/* ========== 首页样式 ========== */

/* 焦点推荐 */
.ns-featured {
    position: relative;
    height: 500px;
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.ns-featured-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: brightness(0.5);
    transition: transform 0.3s;
}

.ns-featured-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.85) 0%, rgba(30, 41, 59, 0.6) 100%);
}

.ns-featured-content {
    position: relative;
    z-index: 1;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 60px 40px;
    max-width: 700px;
}

.ns-featured-badge {
    display: inline-block;
    padding: 6px 14px;
    background: var(--ns-color-primary);
    color: white;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 20px;
    width: fit-content;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.ns-featured-title {
    font-size: 42px;
    font-weight: 700;
    color: white;
    margin-bottom: 20px;
    line-height: 1.2;
}

.ns-featured-meta {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.ns-featured-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    font-size: 13px;
    color: white;
    font-weight: 500;
}

.ns-featured-meta-item svg {
    width: 16px;
    height: 16px;
}

.ns-featured-desc {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    margin-bottom: 28px;
    max-width: 600px;
}

.ns-featured-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    background: var(--ns-color-primary);
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    transition: var(--ns-transition);
    width: fit-content;
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.4);
}

.ns-featured-btn:hover {
    background: var(--ns-color-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
}

/* 内容区块 */
.ns-blocks {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.ns-block {
    background: var(--ns-color-panel);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-block-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--ns-color-border);
}

.ns-block-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--ns-color-text);
    display: flex;
    align-items: center;
    gap: 12px;
}

.ns-block-title::before {
    content: '';
    width: 4px;
    height: 22px;
    background: linear-gradient(135deg, var(--ns-color-primary), var(--ns-color-accent));
    border-radius: 2px;
}

.ns-block-more {
    color: var(--ns-color-primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--ns-transition);
    display: flex;
    align-items: center;
    gap: 4px;
}

.ns-block-more:hover {
    color: var(--ns-color-primary-dark);
    gap: 8px;
}

.ns-block-content {
    width: 100%;
}

/* 内容项网格 */
.ns-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.ns-item {
    background: var(--ns-color-panel);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--ns-transition);
    border: 1px solid var(--ns-color-border);
}

.ns-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border-color: var(--ns-color-primary);
}

.ns-item-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.ns-item-cover {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--ns-color-bg);
}

.ns-item-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.ns-item:hover .ns-item-cover img {
    transform: scale(1.08);
}

.ns-item-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.ns-item:hover .ns-item-overlay {
    opacity: 1;
}

.ns-item-play {
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: scale(0.9);
    transition: transform 0.3s;
}

.ns-item:hover .ns-item-play {
    transform: scale(1);
}

.ns-item-tag {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 10px;
    background: var(--ns-color-primary);
    color: white;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    z-index: 2;
}

.ns-item-info {
    padding: 14px;
}

.ns-item-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--ns-color-text);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ns-item-details {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 12px;
    color: var(--ns-color-text-muted);
}

.ns-item-detail {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 响应式 */
@media (max-width: 1024px) {
    .ns-panel {
        transform: translateX(-100%);
    }

    .ns-panel.is-open {
        transform: translateX(0);
    }

    .ns-main {
        margin-left: 0;
    }

    .ns-mobile-toggle {
        display: flex;
    }

    .ns-items {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .ns-page {
        padding: 16px;
    }

    .ns-featured {
        height: 400px;
    }

    .ns-featured-content {
        padding: 40px 24px;
    }

    .ns-featured-title {
        font-size: 28px;
    }

    .ns-featured-desc {
        font-size: 14px;
    }

    .ns-block {
        padding: 20px;
    }

    .ns-items {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

/* 遮罩层 */
.ns-mask {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 999;
}

.ns-mask.is-active {
    display: block;
}

/* 页面Footer */
.ns-page-footer {
    background: var(--ns-color-panel);
    border-top: 1px solid var(--ns-color-border);
    padding: 40px 0 24px;
    margin-top: 60px;
}

.ns-page-footer-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

.ns-page-footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
    margin-bottom: 32px;
}

.ns-page-footer-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ns-page-footer-heading {
    font-size: 16px;
    font-weight: 600;
    color: var(--ns-color-text);
    margin-bottom: 8px;
}

.ns-page-footer-text {
    font-size: 14px;
    color: var(--ns-color-text-muted);
    line-height: 1.6;
}

.ns-page-footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ns-page-footer-links a {
    color: var(--ns-color-text-muted);
    text-decoration: none;
    font-size: 14px;
    transition: var(--ns-transition);
}

.ns-page-footer-links a:hover {
    color: var(--ns-color-primary);
    padding-left: 4px;
}

.ns-page-footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--ns-color-border);
    font-size: 12px;
    color: var(--ns-color-text-light);
}

/* ========== 详情页样式 ========== */
.ns-detail-page {
    width: 100%;
    padding: 0;
}

.ns-detail-container {
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

/* 导航路径 */
.ns-path {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    font-size: 14px;
    color: var(--ns-color-text-muted);
}

.ns-path-link {
    color: var(--ns-color-primary);
    text-decoration: none;
    transition: var(--ns-transition);
}

.ns-path-link:hover {
    color: var(--ns-color-primary-dark);
    text-decoration: underline;
}

.ns-path-sep {
    color: var(--ns-color-text-light);
}

.ns-path-current {
    color: var(--ns-color-text);
    font-weight: 500;
}

/* 详情主体 */
.ns-detail-main {
    margin-bottom: 32px;
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
    position: relative;
    overflow: hidden;
}

.ns-detail-left {
    float: left;
    width: 280px;
    margin-right: 32px;
    margin-bottom: 20px;
}

.ns-detail-poster {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transition: var(--ns-transition);
}

.ns-detail-poster:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.ns-detail-poster img {
    width: 100%;
    height: auto;
    display: block;
}

.ns-detail-right {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-height: 400px;
}

/* 清除浮动 */
.ns-detail-main::after {
    content: '';
    display: table;
    clear: both;
}

.ns-detail-name {
    font-size: 32px;
    font-weight: 700;
    color: var(--ns-color-text);
    line-height: 1.3;
    margin: 0;
}

/* 数据指标 */
.ns-detail-metrics {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    padding: 20px 0;
    border-top: 1px solid var(--ns-color-border);
    border-bottom: 1px solid var(--ns-color-border);
}

.ns-metric {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 20px;
    background: var(--ns-color-bg);
    border-radius: 10px;
    border: 1px solid var(--ns-color-border);
    transition: var(--ns-transition);
}

.ns-metric:hover {
    border-color: var(--ns-color-primary);
    background: rgba(59, 130, 246, 0.05);
    transform: translateY(-2px);
}

.ns-metric-label {
    font-size: 12px;
    color: var(--ns-color-text-muted);
    font-weight: 500;
}

.ns-metric-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--ns-color-primary);
}

/* 基本信息 */
.ns-detail-base {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ns-base-row {
    display: flex;
    gap: 12px;
    font-size: 14px;
    line-height: 1.8;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.ns-base-row:last-child {
    border-bottom: none;
}

.ns-base-key {
    color: var(--ns-color-text-muted);
    min-width: 70px;
    font-weight: 500;
    flex-shrink: 0;
}

.ns-base-val {
    color: var(--ns-color-text);
    flex: 1;
    word-break: break-word;
}

/* 简介 */
.ns-detail-intro {
    padding-top: 24px;
    border-top: 1px solid var(--ns-color-border);
    margin-top: 20px;
}

.ns-intro-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--ns-color-text);
    margin: 0 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--ns-color-border);
    display: flex;
    align-items: center;
    gap: 8px;
}

.ns-intro-title::before {
    content: '';
    width: 3px;
    height: 18px;
    background: var(--ns-color-primary);
    border-radius: 2px;
}

.ns-intro-text {
    font-size: 15px;
    color: var(--ns-color-text);
    line-height: 1.9;
    text-align: justify;
    word-wrap: break-word;
    word-break: break-word;
    margin: 0;
    padding: 16px 0 0 0;
    display: block;
    white-space: pre-line;
}

.ns-intro-text br {
    line-height: 1.9;
}

.ns-intro-text p {
    margin: 0 0 1em 0;
    text-indent: 2em;
    line-height: inherit;
}

.ns-intro-text p:first-child {
    text-indent: 0;
    margin-top: 0;
}

.ns-intro-text p:last-child {
    margin-bottom: 0;
}

/* 播放器区域 */
.ns-detail-player-area {
    margin: 32px 0;
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-player-container {
    width: 100%;
    position: relative;
}

.ns-player-inner {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    background: #000;
}

.ns-player-inner > div {
    width: 100% !important;
    aspect-ratio: 16/9;
}

/* 播放列表 */
.ns-detail-playlist {
    margin-top: 32px;
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-playlist-group {
    margin-bottom: 24px;
}

.ns-playlist-group:last-child {
    margin-bottom: 0;
}

.ns-playlist-group-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--ns-color-primary);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--ns-color-border);
}

.ns-playlist-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.ns-playlist-item {
    padding: 10px 18px;
    background: var(--ns-color-bg);
    border: 1px solid var(--ns-color-border);
    border-radius: 8px;
    color: var(--ns-color-text);
    text-decoration: none;
    font-size: 14px;
    transition: var(--ns-transition);
    display: inline-block;
}

.ns-playlist-item:hover {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.ns-playlist-item.is-current {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* 相关推荐 */
.ns-detail-related {
    margin-top: 40px;
}

.ns-related-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--ns-color-text);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.ns-related-title::before {
    content: '';
    width: 4px;
    height: 22px;
    background: linear-gradient(135deg, var(--ns-color-primary), var(--ns-color-accent));
    border-radius: 2px;
}

/* ========== 列表页样式 ========== */
.ns-list-page {
    padding: 24px;
}

.ns-list-container {
    max-width: 1400px;
    margin: 0 auto;
}

.ns-list-header {
    margin-bottom: 24px;
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-list-title-area {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ns-list-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--ns-color-text);
    margin: 0;
}

.ns-list-count {
    font-size: 14px;
    color: var(--ns-color-text-muted);
    margin: 0;
}

.ns-list-count strong {
    color: var(--ns-color-primary);
    font-weight: 600;
}

.ns-list-content {
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-list-empty {
    text-align: center;
    padding: 80px 20px;
    background: var(--ns-color-panel);
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.ns-empty-text {
    font-size: 16px;
    color: var(--ns-color-text-muted);
}

/* 分页 */
.ns-pager {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 32px;
    flex-wrap: wrap;
}

.ns-pager-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--ns-color-panel);
    border: 1px solid var(--ns-color-border);
    border-radius: 8px;
    color: var(--ns-color-text);
    text-decoration: none;
    font-size: 14px;
    transition: var(--ns-transition);
}

.ns-pager-btn:hover {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    transform: translateY(-2px);
}

.ns-pager-numbers {
    display: flex;
    gap: 6px;
    align-items: center;
}

.ns-pager-num {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: var(--ns-color-panel);
    border: 1px solid var(--ns-color-border);
    border-radius: 8px;
    color: var(--ns-color-text);
    text-decoration: none;
    font-size: 14px;
    transition: var(--ns-transition);
}

.ns-pager-num:hover {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    transform: translateY(-2px);
}

.ns-pager-num.is-active {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    font-weight: 600;
}

.ns-pager-dots {
    padding: 0 8px;
    color: var(--ns-color-text-light);
}

/* ========== 播放页样式 ========== */
.ns-play-page {
    padding: 24px;
}

.ns-play-container {
    max-width: 1400px;
    margin: 0 auto;
}

.ns-play-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding: 20px 24px;
    background: var(--ns-color-panel);
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
    flex-wrap: wrap;
    gap: 16px;
}

.ns-play-header-left {
    flex: 1;
    min-width: 0;
}

.ns-play-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--ns-color-text);
    margin: 0;
    line-height: 1.3;
}

.ns-play-header-right {
    flex-shrink: 0;
}

.ns-play-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--ns-color-bg);
    border: 1px solid var(--ns-color-border);
    border-radius: 8px;
    color: var(--ns-color-text);
    text-decoration: none;
    font-size: 14px;
    transition: var(--ns-transition);
}

.ns-play-back:hover {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    transform: translateX(-4px);
}

.ns-play-area {
    margin-bottom: 32px;
}

.ns-play-empty {
    text-align: center;
    padding: 80px 20px;
    background: var(--ns-color-panel);
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-player-box {
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
    margin-bottom: 24px;
}

.ns-player-wrapper {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

/* 限制广告层大小 */
.ns-player-wrapper .player-ad-layer {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    z-index: 10 !important;
}

.ns-player-wrapper .player-ad-content {
    max-width: 100% !important;
    max-height: 100% !important;
    overflow: hidden !important;
}

.ns-player-wrapper .player-ad-content :where(img, iframe, video) {
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
}

.ns-play-sources {
    background: var(--ns-color-panel);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 8px var(--ns-color-shadow);
}

.ns-play-source-group {
    margin-bottom: 24px;
}

.ns-play-source-group:last-child {
    margin-bottom: 0;
}

.ns-play-source-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--ns-color-primary);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--ns-color-border);
}

.ns-play-episodes {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.ns-play-episode {
    padding: 10px 18px;
    background: var(--ns-color-bg);
    border: 1px solid var(--ns-color-border);
    border-radius: 8px;
    color: var(--ns-color-text);
    text-decoration: none;
    font-size: 14px;
    transition: var(--ns-transition);
    display: inline-block;
}

.ns-play-episode:hover {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.ns-play-episode.is-current {
    background: var(--ns-color-primary);
    color: white;
    border-color: var(--ns-color-primary);
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.ns-play-recommend {
    margin-top: 40px;
}

.ns-recommend-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--ns-color-text);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.ns-recommend-title::before {
    content: '';
    width: 4px;
    height: 22px;
    background: linear-gradient(135deg, var(--ns-color-primary), var(--ns-color-accent));
    border-radius: 2px;
}

/* ========== 移动端响应式 ========== */
@media (max-width: 1024px) {
    .ns-panel {
        transform: translateX(-100%);
    }

    .ns-panel.is-open {
        transform: translateX(0);
    }

    .ns-main {
        margin-left: 0;
    }

    .ns-mobile-toggle {
        display: flex;
    }

    .ns-detail-main {
        padding: 20px;
    }

    .ns-detail-left {
        float: none;
        width: 100%;
        max-width: 300px;
        margin: 0 auto 24px auto;
    }

    .ns-detail-right {
        min-height: auto;
    }

    .ns-detail-poster {
        width: 100%;
    }

    .ns-detail-player-area {
        padding: 20px;
        margin: 24px 0;
    }

    .ns-detail-playlist {
        padding: 20px;
        margin-top: 24px;
    }

    .ns-playlist-items {
        gap: 8px;
    }

    .ns-playlist-item {
        font-size: 13px;
        padding: 8px 14px;
    }

    .ns-items {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .ns-page {
        padding: 16px;
    }

    .ns-header {
        padding: 12px 16px;
    }

    .ns-featured {
        height: 400px;
    }

    .ns-featured-content {
        padding: 40px 24px;
    }

    .ns-featured-title {
        font-size: 28px;
    }

    .ns-featured-desc {
        font-size: 14px;
    }

    .ns-block {
        padding: 20px;
    }

    .ns-items {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .ns-detail-page,
    .ns-list-page,
    .ns-play-page {
        padding: 16px;
    }

    .ns-detail-main {
        padding: 20px;
    }

    .ns-detail-name {
        font-size: 24px;
    }

    .ns-detail-metrics {
        gap: 12px;
        padding: 16px 0;
    }

    .ns-metric {
        padding: 10px 16px;
        flex: 1;
        min-width: calc(50% - 6px);
    }

    .ns-metric-value {
        font-size: 16px;
    }

    .ns-detail-base {
        gap: 10px;
    }

    .ns-base-row {
        font-size: 13px;
        flex-direction: column;
        gap: 4px;
    }

    .ns-base-key {
        min-width: auto;
    }

    .ns-detail-intro {
        padding-top: 20px;
        margin-top: 16px;
    }

    .ns-intro-title {
        font-size: 16px;
        margin-bottom: 12px;
        padding-bottom: 10px;
    }

    .ns-intro-text {
        font-size: 14px;
        line-height: 1.8;
        text-align: left;
    }

    .ns-intro-text p {
        text-indent: 1.5em;
    }

    .ns-detail-player-area {
        padding: 16px;
        margin: 24px 0;
    }

    .ns-detail-playlist {
        padding: 20px;
    }

    .ns-detail-related {
        margin-top: 32px;
    }

    .ns-related-title {
        font-size: 20px;
        margin-bottom: 20px;
    }

    .ns-list-title {
        font-size: 22px;
    }

    .ns-play-title {
        font-size: 20px;
    }

    .ns-play-header {
        padding: 16px;
    }

    .ns-play-back {
        width: 100%;
        justify-content: center;
    }

    .ns-player-box {
        padding: 16px;
    }

    .ns-play-sources {
        padding: 20px;
    }

    .ns-play-episodes {
        gap: 8px;
    }

    .ns-play-episode {
        font-size: 12px;
        padding: 8px 14px;
    }

    .ns-pager {
        gap: 8px;
    }

    .ns-pager-btn {
        padding: 8px 16px;
        font-size: 13px;
    }

    .ns-pager-num {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .ns-items {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .ns-item-info {
        padding: 12px;
    }

    .ns-item-name {
        font-size: 13px;
    }

    .ns-item-details {
        font-size: 11px;
    }

    .ns-featured {
        height: 350px;
    }

    .ns-featured-title {
        font-size: 24px;
    }

    .ns-featured-meta {
        gap: 8px;
    }

    .ns-featured-meta-item {
        font-size: 11px;
        padding: 4px 10px;
    }

    .ns-detail-main {
        padding: 20px;
    }

    .ns-detail-name {
        font-size: 20px;
    }

    .ns-list-header {
        padding: 20px;
    }

    .ns-list-title {
        font-size: 20px;
    }
}

